:root {
    --bg: #f5f7fb;
    --bg-alt: #eef5f5;
    --surface: #ffffff;
    --surface-strong: #f8fafc;
    --ink: #17202a;
    --muted: #627184;
    --line: #d9e2ea;
    --teal: #0f766e;
    --teal-dark: #0b4f4a;
    --navy: #1f3a5f;
    --coral: #c2410c;
    --amber: #b45309;
    --shadow: 0 18px 50px rgba(27, 39, 52, 0.1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Inter", Arial, sans-serif;
    background: var(--bg);
    color: var(--ink);
    line-height: 1.65;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 14px 32px;
    background: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(16px);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 15px;
    font-weight: 800;
}

.brand-mark {
    display: inline-grid;
    place-items: center;
    width: 38px;
    height: 38px;
    background: var(--ink);
    color: #ffffff;
    border-radius: 8px;
    font-size: 12px;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 6px;
}

.site-nav a {
    padding: 8px 12px;
    border-radius: 8px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 700;
}

.site-nav a:hover,
.site-nav a:focus-visible {
    background: var(--surface-strong);
    color: var(--teal-dark);
}

.hero {
    max-width: 1240px;
    margin: 0 auto;
    padding: 72px 32px 56px;
    scroll-margin-top: 84px;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(360px, 0.9fr);
    gap: 32px;
    align-items: stretch;
}

.hero-copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 520px;
    padding: 54px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow);
    min-width: 0;
}

.eyebrow {
    margin-bottom: 14px;
    color: var(--teal);
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
}

.hero h1 {
    max-width: 780px;
    margin-bottom: 24px;
    color: var(--ink);
    font-size: 68px;
    font-weight: 800;
    line-height: 1.02;
}

.lead {
    max-width: 660px;
    color: var(--muted);
    font-size: 22px;
    line-height: 1.55;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 36px;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 11px 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 14px;
    font-weight: 800;
}

.button.primary {
    background: var(--teal);
    border-color: var(--teal);
    color: #ffffff;
}

.button.secondary {
    background: #ffffff;
    color: var(--navy);
}

.button:hover,
.button:focus-visible {
    transform: translateY(-1px);
}

.hero-panel {
    min-height: 520px;
    padding: 34px;
    background: #132231;
    color: #ffffff;
    border-radius: 8px;
    box-shadow: var(--shadow);
    min-width: 0;
}

.panel-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 28px;
}

.panel-kicker,
.metric-card span,
.chart-meta span,
.insight-box span {
    color: var(--teal);
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.hero-panel .panel-kicker {
    color: #80d6cf;
}

.panel-heading strong {
    font-size: 18px;
}

.hero-stat {
    display: flex;
    align-items: baseline;
    gap: 12px;
    padding-bottom: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}

.stat-value {
    color: #ffffff;
    font-size: 88px;
    font-weight: 800;
    line-height: 0.95;
}

.stat-unit {
    max-width: 120px;
    color: #c9d7e3;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.3;
}

.hero-panel p {
    margin: 24px 0 28px;
    color: #c9d7e3;
    font-size: 17px;
}

.rank-bars {
    display: grid;
    gap: 14px;
}

.rank-row {
    display: grid;
    grid-template-columns: 84px 1fr 62px;
    gap: 12px;
    align-items: center;
    color: #d8e4ee;
    font-size: 13px;
    font-weight: 700;
}

.rank-row strong {
    color: #ffffff;
    font-size: 13px;
    text-align: right;
}

.rank-track {
    height: 8px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.13);
    border-radius: 999px;
}

.rank-track span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, #80d6cf, #f59e0b);
    border-radius: inherit;
}

.metric-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.metric-card {
    padding: 22px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    min-width: 0;
}

.metric-card strong {
    display: block;
    margin: 8px 0 4px;
    color: var(--navy);
    font-size: 30px;
    line-height: 1;
}

.metric-card p {
    color: var(--muted);
    font-size: 14px;
}

.story-section,
.conclusion {
    scroll-margin-top: 84px;
}

.story-section {
    padding: 82px 32px;
}

.story-section.alt {
    background: var(--bg-alt);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.section-header,
.chart-stack,
.story-section > .chart-card,
.insight-box,
.conclusion {
    max-width: 1180px;
    margin-right: auto;
    margin-left: auto;
}

.section-header {
    display: grid;
    grid-template-columns: 76px minmax(0, 900px);
    gap: 28px;
    margin-bottom: 34px;
}

.section-number {
    display: inline-grid;
    place-items: center;
    width: 58px;
    height: 58px;
    color: var(--teal-dark);
    background: #d7efec;
    border: 1px solid #b6ddd8;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 800;
}

.section-header h2,
.conclusion h2 {
    max-width: 840px;
    margin-bottom: 14px;
    font-size: 46px;
    font-weight: 800;
    line-height: 1.12;
}

.section-header p,
.conclusion p {
    max-width: 880px;
    color: var(--muted);
    font-size: 19px;
}

.chart-stack {
    display: grid;
    gap: 24px;
}

.chart-card {
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(27, 39, 52, 0.07);
    min-width: 0;
}

.chart-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 20px 24px;
    background: var(--surface-strong);
    border-bottom: 1px solid var(--line);
}

.chart-meta p {
    max-width: 680px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.5;
    text-align: right;
}

.chart-viewport {
    overflow-x: auto;
    padding: 24px;
    max-width: 100%;
}

.viz {
    min-width: 1040px;
}

.viz canvas,
.viz svg {
    display: block;
    max-width: none;
}

.insight-box {
    margin-top: 28px;
    padding: 28px 32px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    border-left: 7px solid var(--coral);
    border-radius: 8px;
}

.insight-box span {
    color: var(--coral);
}

.insight-box h3 {
    max-width: 840px;
    margin: 8px 0 8px;
    color: #8f2d0d;
    font-size: 28px;
    line-height: 1.2;
}

.insight-box p {
    max-width: 840px;
    color: #75451f;
    font-size: 17px;
}

.conclusion {
    margin-top: 74px;
    margin-bottom: 74px;
    padding: 48px;
    background: #132231;
    color: #ffffff;
    border-radius: 8px;
}

.conclusion .eyebrow {
    color: #80d6cf;
}

.conclusion h2 {
    color: #ffffff;
}

.conclusion p {
    color: #d0dbe5;
}

footer {
    display: flex;
    justify-content: space-between;
    gap: 28px;
    padding: 34px 32px;
    background: #0c131b;
    color: #d7e0ea;
}

footer div {
    display: grid;
    gap: 4px;
}

footer strong {
    color: #ffffff;
    font-size: 15px;
}

footer span,
footer p {
    color: #a7b5c3;
    font-size: 14px;
}

footer p {
    max-width: 720px;
}

@media (max-width: 980px) {
    .topbar {
        align-items: flex-start;
        flex-direction: column;
        padding: 14px 20px;
    }

    .site-nav {
        width: 100%;
        overflow-x: auto;
        padding-bottom: 2px;
    }

    .hero {
        padding: 36px 20px 46px;
    }

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

    .hero-copy,
    .hero-panel {
        min-height: auto;
    }

    .hero h1 {
        font-size: 50px;
    }

    .lead {
        font-size: 20px;
    }

    .metric-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .story-section {
        padding: 64px 20px;
    }

    .section-header {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .section-header h2,
    .conclusion h2 {
        font-size: 38px;
    }

    .chart-meta {
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }

    .chart-meta p {
        text-align: left;
    }

    footer {
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    .hero-copy,
    .hero-panel,
    .conclusion {
        padding: 28px;
    }

    .hero h1 {
        font-size: 34px;
        line-height: 1.08;
    }

    .lead,
    .section-header p,
    .conclusion p {
        font-size: 16px;
    }

    .hero-actions {
        flex-direction: column;
    }

    .button {
        width: 100%;
    }

    .metric-strip {
        grid-template-columns: 1fr;
    }

    .stat-value {
        font-size: 58px;
    }

    .panel-heading,
    .hero-stat {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
    }

    .stat-unit {
        max-width: none;
    }

    .rank-row {
        grid-template-columns: 70px minmax(84px, 1fr) 56px;
        gap: 8px;
    }

    .section-header h2,
    .conclusion h2 {
        font-size: 31px;
    }

    .chart-viewport {
        padding: 18px;
    }

    .insight-box {
        padding: 24px;
    }
}
