/* Global Settings & Typography */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;700;900&display=swap');

:root {
    --primary-blue: #002E5D;
    --accent-yellow: #FFB800;
    --text-dark: #212529;
    --text-light: #FFFFFF;
    --bg-light: #F8F9FA;
    --bg-mesh: linear-gradient(135deg, #F8F9FA 0%, #E9ECEF 100%);
    --spacing-1: 8px;
    --spacing-2: 16px;
    --spacing-3: 24px;
    --spacing-4: 32px;
    --spacing-8: 64px;
    --spacing-16: 128px;
    --font-main: 'Montserrat', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background: var(--bg-light);
    color: var(--text-dark);
    font-family: var(--font-main);
    overflow-x: hidden;
}

/* 12-Column Grid System */
.grid-container {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 24px;
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 48px;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -1px;
    line-height: 1.1;
    color: var(--primary-blue);
}

p {
    font-weight: 500;
    line-height: 1.6;
    color: #333333;
}

/* Utility Spacers */
.mt-32 {
    margin-top: 32px;
}

.mt-64 {
    margin-top: 64px;
}

.mb-32 {
    margin-bottom: 32px;
}

.mb-64 {
    margin-bottom: 64px;
}

.py-64 {
    padding-top: 64px;
    padding-bottom: 64px;
}

.py-128 {
    padding-top: 128px;
    padding-bottom: 128px;
}

/* Navigation */
.navbar {
    background: #FFFFFF;
    border-bottom: 4px solid var(--accent-yellow);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 9999;
}

.nav-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    align-items: center;
    height: 80px;
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 48px;
}

.nav-brand {
    grid-column: span 3;
    font-size: 28px;
    font-weight: 900;
    color: var(--primary-blue);
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.nav-links {
    grid-column: span 9;
    display: flex;
    justify-content: flex-end;
    gap: 32px;
}

.hamburger {
    display: none;
}

.nav-item {
    font-weight: 700;
    color: var(--primary-blue);
    cursor: pointer;
    position: relative;
    padding: 28px 0;
    transition: all 0.2s;
    text-decoration: none;
    font-size: 14px;
    border-bottom: 4px solid transparent;
    /* Prepare for hover */
}

/* FIXED: Hover contrast issue. Instead of yellow text, we use blue text + yellow border */
.nav-item:hover {
    color: var(--primary-blue);
    border-bottom: 4px solid var(--accent-yellow);
    background: rgba(255, 184, 0, 0.05);
    /* Very subtle tint */
}

/* Dropdown */
.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: -20px;
    background: #FFFFFF;
    border-top: 4px solid var(--primary-blue);
    box-shadow: 0 16px 40px rgba(0, 46, 93, 0.15);
    min-width: 360px;
    z-index: 10000;
    border-radius: 0 0 8px 8px;
}

.nav-item:hover .dropdown-menu {
    display: block;
    animation: fadeIn 0.2s ease-out;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s;
    text-decoration: none;
    color: var(--text-dark);
}

.dropdown-item:hover {
    background: #f8fcfd;
    padding-left: 32px;
}

.dropdown-icon {
    font-size: 24px;
    color: var(--accent-yellow);
    /* Icons inside dropdown are fine on white/grey? Wait, checking. */
}

/* Hero Section */
.hero-section {
    position: relative;
    background: #000;
    color: #fff;
    min-height: 80vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.6;
    z-index: 0;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(0, 46, 93, 0.9) 0%, rgba(0, 46, 93, 0.4) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    grid-column: span 12;
}

.hero-title {
    font-size: 80px;
    color: white;
    margin-bottom: 24px;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Live Stats */
.live-stats-bar {
    background: var(--primary-blue);
    color: white;
    padding: 48px 0;
    margin-top: -60px;
    position: relative;
    z-index: 10;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
}

.stat-item {
    grid-column: span 3;
    text-align: center;
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item:last-child {
    border-right: none;
}

.stat-value {
    font-size: 48px;
    font-weight: 900;
    color: var(--accent-yellow);
    display: block;
}

.stat-label {
    font-size: 14px;
    font-weight: 700;
    opacity: 0.8;
    letter-spacing: 1px;
}

/* 3D Buttons */
.btn-kor-3d {
    display: inline-block;
    padding: 24px 48px;
    font-size: 20px;
    font-weight: 900;
    text-transform: uppercase;
    color: var(--primary-blue);
    background: var(--accent-yellow);
    border: none;
    box-shadow: 0 8px 0 #cc9300, 0 16px 24px rgba(0, 0, 0, 0.2);
    transition: all 0.1s;
    border-radius: 4px;
    text-decoration: none;
    margin-top: 32px;
}

.btn-kor-3d:active {
    transform: translateY(4px);
    box-shadow: 0 4px 0 #cc9300, 0 8px 12px rgba(0, 0, 0, 0.2);
}

.btn-kor-secondary {
    display: inline-block;
    padding: 24px 48px;
    font-size: 20px;
    font-weight: 900;
    text-transform: uppercase;
    color: white;
    background: var(--primary-blue);
    border: none;
    box-shadow: 0 8px 0 #001a35, 0 16px 24px rgba(0, 0, 0, 0.2);
    transition: all 0.1s;
    border-radius: 4px;
    text-decoration: none;
    margin-top: 32px;
}

.btn-kor-secondary:active {
    transform: translateY(4px);
    box-shadow: 0 4px 0 #001a35, 0 8px 12px rgba(0, 0, 0, 0.2);
}

/* Cards & Sections */
.news-card {
    background: white;
    padding: 32px;
    border-left: 8px solid var(--accent-yellow);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s;
    grid-column: span 4;
}

.news-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.1);
}

.news-date {
    font-size: 12px;
    font-weight: 700;
    color: #555;
    margin-bottom: 8px;
    display: block;
}

.news-title {
    font-size: 20px;
    margin-bottom: 16px;
    color: var(--primary-blue);
}

/* Map Section */
.map-visual {
    width: 100%;
    height: 400px;
    background: #e9ecef;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    color: #555;
    /* Darkened from #999 */
    font-size: 32px;
    background-image: radial-gradient(circle, #ddd 2px, transparent 2px);
    background-size: 20px 20px;
}

/* Footer - Standardized */
.footer {
    background: var(--primary-blue);
    color: white;
    padding-top: 96px;
    padding-bottom: 48px;
    border-top: 8px solid var(--accent-yellow);
    margin-top: 128px;
}

.footer-brand {
    font-size: 48px;
    font-weight: 900;
    color: white;
    margin-bottom: 24px;
    letter-spacing: -2px;
}

.footer h4 {
    font-size: 24px;
    font-weight: 900;
    margin-bottom: 32px;
    color: var(--accent-yellow);
}

.footer-link {
    color: rgba(255, 255, 255, 0.8);
    display: block;
    margin-bottom: 16px;
    text-decoration: none;
    font-weight: 700;
    font-size: 16px;
    transition: 0.2s;
}

.footer-link:hover {
    color: var(--accent-yellow);
    padding-left: 12px;
}

.footer p {
    font-weight: 500;
    font-size: 16px;
    color: rgba(255, 255, 255, 0.8);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 992px) {

    .grid-container,
    .nav-grid {
        display: flex;
        flex-direction: column;
        padding: 0 24px;
    }

    .nav-links {
        display: none;
    }

    .hero-title {
        font-size: 48px;
        text-align: center;
    }

    .stat-item {
        margin-bottom: 24px;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        padding-bottom: 24px;
    }

    .news-card {
        margin-bottom: 24px;
        grid-column: span 12;
    }

    .map-visual {
        grid-column: span 12;
    }
}

/* Mobile Responsive (Max-Width 768px) */
@media (max-width: 768px) {

    /* Global Container Stacking */
    .grid-container,
    .nav-grid {
        display: flex;
        flex-direction: column;
        padding: 0 24px;
        width: 100%;
    }

    /* Force all grid columns to span full width */
    [style*="grid-column: span"] {
        grid-column: span 12 !important;
        width: 100% !important;
    }

    /* Navbar Mobile */
    .navbar {
        position: relative;
        height: auto;
    }

    .nav-grid {
        height: auto;
        padding: 16px 24px;
        flex-direction: row;
        /* Keep row to put brand and hamburger side-by-side */
        flex-wrap: wrap;
        justify-content: space-between;
    }

    .nav-brand {
        justify-content: flex-start;
        margin-bottom: 0;
        width: auto;
    }

    .hamburger {
        display: block;
        /* Show on mobile */
        font-size: 28px;
        color: var(--primary-blue);
        cursor: pointer;
        align-self: center;
    }

    .nav-links {
        display: none;
        /* Hide by default */
        flex-direction: column;
        width: 100%;
        gap: 0;
        margin-top: 16px;
        border-top: 1px solid #eee;
        animation: fadeIn 0.3s ease;
    }

    .nav-links.active {
        display: flex !important;
        /* Show when active */
    }

    .nav-item {
        width: 100%;
        text-align: center;
        padding: 16px 0;
        border-bottom: 1px solid #eee;
    }

    /* Hide detailed dropdowns on mobile for simplicity, or make them static blocks */
    .dropdown-menu {
        position: static;
        box-shadow: none;
        border: none;
        background: #f8f9fa;
        min-width: 100%;
        padding: 0;
    }

    .dropdown-item {
        padding: 16px;
        border-bottom: 1px solid #e0e0e0;
    }

    /* Hero Section Overrides */
    .hero-content {
        height: auto !important;
        padding-top: 64px;
        padding-bottom: 64px;
        display: flex !important;
        flex-direction: column;
        align-items: center !important;
    }

    .hero-text {
        padding-right: 0 !important;
        margin-bottom: 48px;
        text-align: center;
    }

    .hero-title {
        font-size: 42px !important;
        line-height: 1.2 !important;
        margin-bottom: 24px !important;
        text-align: center;
    }

    .hero-text p {
        font-size: 18px !important;
        line-height: 1.6 !important;
        text-align: center;
        border-left: none !important;
        padding-left: 0 !important;
    }

    /* Hero Cards Column */
    .hero-cards {
        display: flex !important;
        flex-direction: column;
        gap: 24px !important;
        width: 100% !important;
        grid-template-columns: 1fr !important;
        /* Override inline grid */
    }

    /* Individual Cards */
    .hero-cards a {
        display: block;
        width: 100%;
    }

    .hero-cards a div {
        clip-path: none !important;
        height: auto !important;
        padding: 32px !important;
        border: 4px solid rgba(255, 255, 255, 0.1) !important;
        /* Ensure border is visible */
        transform: none !important;
    }

    /* General Typography Scaling */
    h1 {
        font-size: 32px !important;
    }

    h2 {
        font-size: 28px !important;
    }

    /* Map */
    .map-visual {
        height: 300px;
    }

    /* Footer */
    .footer {
        text-align: center;
    }

    .footer h4 {
        margin-top: 32px;
    }
}