/* ================================
   KUWASA Website Styles
   ================================ */

/* CSS Variables */
:root {
    --primary-color: #0066b3;
    --primary-dark: #004d86;
    --secondary-color: #00a651;
    --secondary-dark: #008542;
    --accent-color: #f7941d;
    --text-color: #333333;
    --text-light: #666666;
    --bg-light: #f5f7fa;
    --bg-gray: #e9ecef;
    --white: #ffffff;
    --shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 5px 25px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s ease;
    --border-radius: 8px;
}

/* Reset */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Open Sans', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--white);
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    line-height: 1.3;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-secondary:hover {
    background-color: var(--secondary-dark);
    transform: translateY(-2px);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* ================================
   Top Bar
   ================================ */
.top-bar {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    color: var(--white);
    padding: 8px 0;
    font-size: 13px;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.government-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.emblem {
    width: 45px;
    height: auto;
}

.gov-text {
    display: flex;
    flex-direction: column;
}

.gov-title {
    font-weight: 600;
    font-size: 14px;
}

.ministry {
    font-size: 12px;
    opacity: 0.9;
}

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 25px;
}

.language-switcher a {
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    opacity: 0.8;
}

.language-switcher a.active {
    background-color: rgba(255, 255, 255, 0.2);
    opacity: 1;
}

.language-switcher a:hover {
    opacity: 1;
}

.social-links a {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    margin-left: 8px;
    font-size: 12px;
}

.social-links a:hover {
    background-color: var(--accent-color);
    transform: translateY(-2px);
}

/* ================================
   Header
   ================================ */
.main-header {
    background-color: var(--white);
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo {
    width: 70px;
    height: auto;
}

.logo-text h1 {
    font-size: 18px;
    color: var(--primary-color);
    line-height: 1.3;
}

.logo-text .acronym {
    font-size: 24px;
    font-weight: 700;
    color: var(--secondary-color);
}

.header-contact {
    display: flex;
    gap: 30px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-color);
}

.contact-item i {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    font-size: 16px;
}

.contact-item span {
    font-size: 14px;
    font-weight: 600;
}

/* ================================
   Navigation
   ================================ */
.main-nav {
    background-color: var(--primary-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
}

.hamburger {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--white);
    position: relative;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background-color: var(--white);
    left: 0;
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    top: 8px;
}

.nav-menu {
    display: flex;
    justify-content: center;
}

.nav-menu > li {
    position: relative;
}

.nav-menu > li > a {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 15px 20px;
    color: var(--white);
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
}

.nav-menu > li > a:hover,
.nav-menu > li > a.active {
    background-color: rgba(0, 0, 0, 0.15);
}

.nav-menu > li > a i.fa-chevron-down {
    font-size: 10px;
    transition: var(--transition);
}

/* Dropdown */
.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background-color: var(--white);
    box-shadow: var(--shadow);
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    z-index: 100;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown:hover > a i.fa-chevron-down {
    transform: rotate(180deg);
}

.dropdown-menu li a {
    display: block;
    padding: 12px 20px;
    color: var(--text-color);
    font-size: 14px;
    border-bottom: 1px solid var(--bg-gray);
}

.dropdown-menu li:last-child a {
    border-bottom: none;
}

.dropdown-menu li a:hover {
    background-color: var(--bg-light);
    color: var(--primary-color);
    padding-left: 25px;
}

/* ================================
   Hero Slider
   ================================ */
.hero-slider {
    position: relative;
    height: 500px;
    overflow: hidden;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.slide.active {
    opacity: 1;
}

.slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 102, 179, 0.85) 0%, rgba(0, 166, 81, 0.75) 100%);
}

.slide-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: var(--white);
    max-width: 700px;
    padding: 0 20px;
}

.slide-content h2 {
    font-size: 48px;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.slide-content p {
    font-size: 20px;
    margin-bottom: 30px;
    opacity: 0.95;
}

.slider-controls {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    pointer-events: none;
}

.slider-controls button {
    width: 50px;
    height: 50px;
    border: none;
    background-color: rgba(255, 255, 255, 0.2);
    color: var(--white);
    font-size: 20px;
    cursor: pointer;
    border-radius: 50%;
    transition: var(--transition);
    pointer-events: auto;
}

.slider-controls button:hover {
    background-color: var(--primary-color);
}

.slider-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
}

.slider-dots .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: var(--transition);
}

.slider-dots .dot.active {
    background-color: var(--white);
    transform: scale(1.2);
}

/* ================================
   Quick Services
   ================================ */
.quick-services {
    padding: 60px 0;
    background-color: var(--bg-light);
    margin-top: -50px;
    position: relative;
    z-index: 10;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.service-card {
    background-color: var(--white);
    padding: 35px 25px;
    text-align: center;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.service-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 50%;
    color: var(--white);
    font-size: 32px;
}

.service-card h3 {
    font-size: 18px;
    margin-bottom: 12px;
    color: var(--primary-color);
}

.service-card p {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 20px;
}

/* ================================
   MD Welcome Section
   ================================ */
.md-welcome {
    padding: 80px 0;
}

.md-content {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 50px;
    align-items: start;
}

.md-image {
    text-align: center;
}

.md-image img {
    width: 100%;
    max-width: 280px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-bottom: 15px;
}

.md-info {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 15px;
    border-radius: var(--border-radius);
}

.md-info h4 {
    font-size: 16px;
    margin-bottom: 5px;
}

.md-info p {
    font-size: 14px;
    opacity: 0.9;
}

.md-message h2 {
    font-size: 32px;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.section-underline {
    width: 60px;
    height: 4px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    margin-bottom: 25px;
    border-radius: 2px;
}

.section-underline.center {
    margin-left: auto;
    margin-right: auto;
}

.md-message p {
    margin-bottom: 15px;
    color: var(--text-light);
    text-align: justify;
}

/* ================================
   Statistics Section
   ================================ */
.statistics {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    padding: 60px 0;
    color: var(--white);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    text-align: center;
}

.stat-item i {
    font-size: 40px;
    margin-bottom: 15px;
    opacity: 0.9;
}

.stat-number {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 10px;
}

.stat-item p {
    font-size: 16px;
    opacity: 0.9;
}

/* ================================
   News Section
   ================================ */
.news-section {
    padding: 80px 0;
    background-color: var(--bg-light);
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--primary-color);
}

.section-header h2 {
    font-size: 22px;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.view-all {
    font-size: 14px;
    color: var(--primary-color);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
}

.view-all:hover {
    color: var(--secondary-color);
}

/* News Items */
.news-item {
    display: flex;
    gap: 20px;
    padding: 20px;
    background-color: var(--white);
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    transition: var(--transition);
}

.news-item:hover {
    box-shadow: var(--shadow);
    transform: translateX(5px);
}

.news-date {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white);
    border-radius: var(--border-radius);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.news-date .day {
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
}

.news-date .month {
    font-size: 12px;
    text-transform: uppercase;
}

.news-content h4 {
    font-size: 16px;
    margin-bottom: 8px;
}

.news-content h4 a:hover {
    color: var(--primary-color);
}

.news-content p {
    font-size: 14px;
    color: var(--text-light);
}

/* Announcement Items */
.announcement-item {
    display: flex;
    gap: 15px;
    padding: 20px;
    background-color: var(--white);
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    border-left: 4px solid var(--accent-color);
    transition: var(--transition);
}

.announcement-item:hover {
    box-shadow: var(--shadow);
}

.announcement-icon {
    flex-shrink: 0;
    width: 45px;
    height: 45px;
    background-color: var(--accent-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.announcement-content h4 {
    font-size: 15px;
    margin-bottom: 6px;
}

.announcement-content h4 a:hover {
    color: var(--primary-color);
}

.announcement-content p {
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 8px;
}

.announcement-content .date {
    font-size: 12px;
    color: var(--accent-color);
    font-weight: 600;
}

/* ================================
   Projects Section
   ================================ */
.projects-section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 32px;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.section-title p {
    color: var(--text-light);
    max-width: 600px;
    margin: 15px auto 0;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.project-card {
    background-color: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.project-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 102, 179, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-info {
    padding: 25px;
}

.project-info h3 {
    font-size: 18px;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.project-info p {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 15px;
}

.project-progress {
    margin-top: 15px;
}

.progress-bar {
    height: 8px;
    background-color: var(--bg-gray);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress {
    height: 100%;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    border-radius: 4px;
    transition: width 1s ease;
}

.project-progress span {
    font-size: 12px;
    color: var(--text-light);
    font-weight: 600;
}

/* ================================
   Partners Section
   ================================ */
.partners-section {
    padding: 60px 0;
    background-color: var(--bg-light);
}

.partners-slider {
    overflow: hidden;
}

.partners-track {
    display: flex;
    gap: 50px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.partner-item {
    flex: 0 0 auto;
}

.partner-item img {
    height: 60px;
    width: auto;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: var(--transition);
}

.partner-item:hover img {
    filter: grayscale(0%);
    opacity: 1;
}

/* ================================
   Footer
   ================================ */
.main-footer {
    background-color: #1a1a2e;
    color: var(--white);
}

.footer-top {
    padding: 60px 0 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
}

.footer-column h3 {
    font-size: 18px;
    margin-bottom: 25px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary-color);
    display: inline-block;
}

.footer-contact li {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
    font-size: 14px;
}

.footer-contact i {
    width: 20px;
    color: var(--primary-color);
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    font-size: 14px;
    opacity: 0.8;
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-links a::before {
    content: '›';
    color: var(--primary-color);
}

.footer-links a:hover {
    opacity: 1;
    color: var(--primary-color);
    padding-left: 5px;
}

.visitor-stats li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 14px;
}

.visitor-stats i {
    color: var(--primary-color);
}

.footer-social {
    margin-top: 25px;
    display: flex;
    gap: 12px;
}

.footer-social a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    font-size: 16px;
}

.footer-social a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-bottom {
    background-color: rgba(0, 0, 0, 0.2);
    padding: 20px 0;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.footer-bottom p {
    font-size: 13px;
    opacity: 0.8;
}

.footer-bottom-links {
    display: flex;
    gap: 20px;
}

.footer-bottom-links a {
    font-size: 13px;
    opacity: 0.8;
}

.footer-bottom-links a:hover {
    opacity: 1;
    color: var(--primary-color);
}

/* ================================
   Back to Top Button
   ================================ */
#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white);
    border: none;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 1000;
    box-shadow: var(--shadow);
}

#back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

#back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

/* ================================
   Responsive Design
   ================================ */
@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .md-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .md-image {
        order: -1;
    }

    .section-underline {
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 768px) {
    .top-bar-content {
        justify-content: center;
    }

    .top-bar-right {
        display: none;
    }

    .header-content {
        justify-content: center;
        text-align: center;
    }

    .logo-section {
        flex-direction: column;
    }

    .header-contact {
        display: none;
    }

    .nav-toggle {
        display: block;
        position: absolute;
        right: 20px;
        top: 50%;
        transform: translateY(-50%);
    }

    .main-nav .container {
        position: relative;
        padding: 10px 20px;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--primary-dark);
        flex-direction: column;
        padding: 20px;
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-menu > li > a {
        padding: 12px 15px;
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        background-color: rgba(0, 0, 0, 0.1);
        display: none;
    }

    .dropdown.active .dropdown-menu {
        display: block;
    }

    .dropdown-menu li a {
        color: var(--white);
        border-bottom-color: rgba(255, 255, 255, 0.1);
    }

    .hero-slider {
        height: 400px;
    }

    .slide-content h2 {
        font-size: 32px;
    }

    .slide-content p {
        font-size: 16px;
    }

    .quick-services {
        margin-top: 0;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .stat-number {
        font-size: 36px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-contact li {
        justify-content: center;
    }

    .footer-links a {
        justify-content: center;
    }

    .visitor-stats li {
        justify-content: center;
    }

    .footer-social {
        justify-content: center;
    }

    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-slider {
        height: 350px;
    }

    .slide-content h2 {
        font-size: 26px;
    }

    .service-card {
        padding: 25px 20px;
    }

    .section-title h2 {
        font-size: 26px;
    }

    .md-message h2 {
        font-size: 26px;
    }

    #back-to-top {
        width: 40px;
        height: 40px;
        font-size: 16px;
        bottom: 20px;
        right: 20px;
    }
}
