:root {
    --black: #1d1d1f;
    --white: #ffffff;
    --gray-light: #f5f5f7;
    --gray-mid: #86868b;
    --gray-line: #d2d2d7;
    --accent: #3a6b4f;
    --accent-dark: #274a37;
    --gold: #b08d4a;
    --max-w: 1200px;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: env(safe-area-inset-top, 0px);
}

/* ---------- Body & Page Grid ---------- */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--black);
    background-color: var(--gray-light);
    -webkit-font-smoothing: antialiased;
    line-height: 1.5;

    /* 3-Column Grid: [Left Ad (160px)] [Main Content] [Right Ad (160px)] */
    display: grid;
    grid-template-columns: 160px minmax(0, var(--max-w)) 160px;
    justify-content: center;
    gap: 24px;
    padding: 0 16px;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ---------- Header & Nav ---------- */
header {
    grid-column: 1 / -1; /* Spans full grid width */
}

nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding-top: env(safe-area-inset-top, 0px);
    height: calc(56px + env(safe-area-inset-top, 0px));
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

nav ul {
    display: flex;
    gap: 28px;
    list-style: none;
    font-size: 13px;
    font-weight: 500;
    color: var(--black);
    flex-wrap: wrap;
    justify-content: center;
    padding: 0 16px;
}

nav ul li a {
    opacity: 0.85;
    transition: opacity 0.2s ease;
}

nav ul li a:hover {
    opacity: 1;
}

/* ---------- Main Content Container ---------- */
.main-content {
    grid-column: 2;
    background: var(--white);
    padding: 32px 24px;
    min-height: 100vh;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

/* ---------- Sticky Side Ad Banners ---------- */
.side-ad {
    width: 160px;
    position: sticky;
    top: 80px; /* Offset below fixed navbar */
    height: fit-content;
}

.left-ad {
    grid-column: 1;
}

.right-ad {
    grid-column: 3;
}

/* ---------- Sections ---------- */
section {
    padding: 80px 0;
    text-align: center;
    overflow-x: hidden;
}

.section-inner {
    max-width: var(--max-w);
    margin: 0 auto;
}

.eyebrow {
    font-size: 19px;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 8px;
}

h1 {
    font-size: clamp(40px, 7vw, 88px);
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.05;
    margin-bottom: 16px;
}

h2 {
    font-size: clamp(32px, 5vw, 56px);
    font-weight: 600;
    letter-spacing: -0.015em;
    line-height: 1.08;
    margin-bottom: 16px;
}

h3.section-title {
    font-size: clamp(26px, 3.6vw, 40px);
    font-weight: 600;
    letter-spacing: -0.01em;
    margin-bottom: 12px;
}

.subhead {
    font-size: clamp(18px, 2.4vw, 28px);
    font-weight: 400;
    color: var(--gray-mid);
    max-width: 680px;
    margin: 0 auto 40px;
}

.body-text {
    font-size: 17px;
    color: var(--gray-mid);
    max-width: 720px;
    margin: 0 auto;
    text-align: left;
}

.body-text + .body-text {
    margin-top: 16px;
}

/* ---------- Buttons ---------- */
.btn-row {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    font-size: 17px;
    font-weight: 400;
    padding: 12px 22px;
    border-radius: 980px;
    transition: all 0.2s ease;
}

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

.btn-primary:hover {
    background: var(--accent-dark);
}

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

.btn-secondary:hover {
    text-decoration: underline;
}

/* ---------- Hero ---------- */
.hero {
    padding-top: calc(80px + env(safe-area-inset-top, 0px));
    background: var(--white);
}

.hero-visual {
    margin-top: 64px;
    border-radius: 24px;
    aspect-ratio: 16/7;
    overflow: hidden;
    width: 100%;
}

.flag-svg {
    width: 100%;
    height: 100%;
    display: block;
}

/* ---------- Dark Section ---------- */
.dark {
    background: var(--black);
    color: var(--white);
}

.dark .subhead {
    color: #a1a1a6;
}

.dates-row {
    display: flex;
    gap: 60px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 56px;
}

.date-item .num {
    font-size: clamp(28px, 4vw, 44px);
    font-weight: 600;
    color: var(--gold);
}

.date-item .label {
    font-size: 14px;
    color: #a1a1a6;
    margin-top: 4px;
}

/* ---------- Feature Grid ---------- */
.grid {
    background: var(--gray-light);
}

.grid-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2px;
    margin-top: 60px;
    text-align: left;
    background: var(--gray-line);
    border-radius: 18px;
    overflow: hidden;
}

.card {
    background: var(--white);
    padding: 32px 28px;
}

.card .role {
    font-size: 13px;
    font-weight: 600;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin-bottom: 6px;
}

.card h3 {
    font-size: 21px;
    font-weight: 600;
}

/* ---------- Constitution ---------- */
.constitution {
    background: var(--white);
}

.article-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
    margin-top: 56px;
    text-align: left;
}

.article {
    padding: 28px;
    border: 1px solid var(--gray-line);
    border-radius: 18px;
}

.article .num {
    font-size: 13px;
    font-weight: 600;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 8px;
}

.article h4 {
    font-size: 19px;
    font-weight: 600;
    margin-bottom: 8px;
}

.article p {
    font-size: 15px;
    color: var(--gray-mid);
}

/* ---------- Scroll Reveal Animations ---------- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* ---------- Footer ---------- */
footer {
    grid-column: 1 / -1;
    padding: 40px 24px;
    text-align: center;
    font-size: 12px;
    color: var(--gray-mid);
    border-top: 1px solid var(--gray-line);
}

/* ---------- Responsive Layout ---------- */
@media screen and (max-width: 1100px) {
    body {
        grid-template-columns: 1fr;
        padding: 0 16px;
    }

    .side-ad {
        display: none; /* Collapses side skyscrapers on smaller screens */
    }

    .main-content {
        grid-column: 1;
        padding: 20px 16px;
    }
}
