:root {
    color-scheme: dark;
    --bg: #101214;
    --panel: #171c20;
    --panel-strong: #20272d;
    --text: #f3f0e8;
    --muted: #b8c0bd;
    --line: #354149;
    --green: #8bd17c;
    --amber: #f1b84b;
    --cyan: #76c7d5;
    --coral: #ef8f78;
    --ink: #0b0d0e;
    --max: 1160px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    overflow-x: hidden;
}

a {
    color: inherit;
}

.site-header {
    position: fixed;
    z-index: 10;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 18px clamp(18px, 5vw, 64px);
    background: rgba(16, 18, 20, 0.86);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(14px);
}

.brand {
    font-size: 1rem;
    font-weight: 800;
    text-decoration: none;
    letter-spacing: 0;
}

.nav {
    display: flex;
    align-items: center;
    gap: clamp(12px, 3vw, 28px);
    color: var(--muted);
    font-size: 0.92rem;
}

.nav a {
    text-decoration: none;
}

.nav a:hover {
    color: var(--text);
}

.hero {
    position: relative;
    min-height: 78vh;
    display: grid;
    align-items: end;
    padding: 104px clamp(18px, 5vw, 64px) 34px;
    overflow: hidden;
    background:
        linear-gradient(180deg, rgba(16, 18, 20, 0.42), rgba(16, 18, 20, 0.96)),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 80px),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 80px),
        #14181b;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(110deg, rgba(139, 209, 124, 0.18), transparent 38%),
        linear-gradient(265deg, rgba(118, 199, 213, 0.18), transparent 44%),
        linear-gradient(22deg, transparent 55%, rgba(239, 143, 120, 0.16));
    opacity: 0.9;
}

.hero::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 20vh;
    background: linear-gradient(180deg, transparent, var(--bg));
}

.hero-visual {
    position: absolute;
    inset: 82px 0 0;
    pointer-events: none;
    opacity: 0.9;
}

.trace {
    position: absolute;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--green), var(--amber), transparent);
    box-shadow: 0 0 24px rgba(139, 209, 124, 0.28);
}

.trace::before,
.trace::after {
    content: "";
    position: absolute;
    width: 10px;
    height: 10px;
    top: -4px;
    border-radius: 2px;
    background: currentColor;
}

.trace::before {
    left: 18%;
}

.trace::after {
    right: 22%;
}

.trace-a {
    color: var(--green);
    width: 70vw;
    top: 21%;
    left: 7vw;
    transform: rotate(-3deg);
}

.trace-b {
    color: var(--cyan);
    width: 58vw;
    top: 43%;
    right: -5vw;
    transform: rotate(5deg);
}

.trace-c {
    color: var(--coral);
    width: 42vw;
    bottom: 28%;
    left: 20vw;
    transform: rotate(2deg);
}

.spectrum {
    position: absolute;
    right: clamp(24px, 7vw, 96px);
    bottom: 26vh;
    display: grid;
    grid-template-columns: repeat(12, 9px);
    align-items: end;
    gap: 8px;
    height: 150px;
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(11, 13, 14, 0.38);
}

.spectrum span {
    display: block;
    height: var(--level);
    background: linear-gradient(180deg, var(--amber), var(--green));
}

.hero-content {
    position: relative;
    z-index: 1;
    width: 100%;
    min-width: 0;
    max-width: 820px;
}

.eyebrow,
.card-kicker {
    margin: 0 0 14px;
    color: var(--green);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    max-width: 920px;
    margin-bottom: 22px;
    font-size: 6.2rem;
    line-height: 0.94;
    letter-spacing: 0;
    overflow-wrap: break-word;
}

.hero-copy {
    max-width: 680px;
    margin-bottom: 30px;
    color: var(--muted);
    font-size: 1.28rem;
}

.hero-link {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 18px;
    color: var(--ink);
    background: var(--amber);
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    font-weight: 800;
    text-decoration: none;
}

.hero-link:hover {
    background: #ffd06d;
}

.hero-facts {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    width: min(100%, var(--max));
    margin: 36px 0 0;
    background: var(--line);
    border: 1px solid var(--line);
}

.hero-facts div {
    padding: 18px;
    background: rgba(23, 28, 32, 0.82);
}

dt {
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
}

dd {
    margin: 5px 0 0;
    font-weight: 800;
}

.section {
    width: min(100% - 36px, var(--max));
    margin: 0 auto;
    padding: 86px 0;
}

.intro {
    padding-top: 50px;
}

.section-heading {
    min-width: 0;
    max-width: 780px;
    margin-bottom: 34px;
}

.section-heading.compact {
    margin-bottom: 0;
}

h2 {
    margin-bottom: 16px;
    font-size: 3.75rem;
    line-height: 1.04;
    letter-spacing: 0;
    overflow-wrap: break-word;
}

.section-heading p:not(.eyebrow),
.note-columns p,
.findings-grid p,
.lab-note li {
    color: var(--muted);
}

.findings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.findings-grid article,
.note-columns article,
.lab-note {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
}

.findings-grid article {
    min-width: 0;
    padding: 24px;
}

.findings-grid article:nth-child(2) {
    border-top-color: rgba(118, 199, 213, 0.65);
}

.findings-grid article:nth-child(3) {
    border-top-color: rgba(239, 143, 120, 0.65);
}

.findings-grid article:nth-child(4) {
    border-top-color: rgba(241, 184, 75, 0.65);
}

h3 {
    margin-bottom: 10px;
    font-size: 1.25rem;
    line-height: 1.22;
}

.lab-note {
    margin-top: 18px;
    padding: 26px;
    background: var(--panel-strong);
}

.lab-note ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 28px;
    margin: 16px 0 0;
    padding-left: 20px;
}

.lab-note li::marker {
    color: var(--amber);
}

.note-columns {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    align-items: stretch;
    padding-top: 42px;
}

.note-columns .section-heading {
    grid-column: 1 / -1;
}

.note-columns article {
    min-width: 0;
    padding: 22px;
}

.text-link {
    display: inline-flex;
    margin-top: 4px;
    color: var(--amber);
    font-weight: 800;
    text-decoration: none;
}

.text-link:hover {
    color: #ffd06d;
}

.article-page {
    background:
        linear-gradient(180deg, rgba(118, 199, 213, 0.08), transparent 340px),
        var(--bg);
}

.article-main {
    width: calc(100% - 36px);
    max-width: 880px;
    margin: 0 auto;
    padding: 132px 0 70px;
}

.article {
    min-width: 0;
}

.article-hero {
    padding-bottom: 34px;
    border-bottom: 1px solid var(--line);
}

.article-hero h1 {
    max-width: 760px;
    font-size: 5rem;
}

.article-hero .hero-copy {
    max-width: 100%;
}

.article-body {
    padding-top: 38px;
}

.article-body h2 {
    margin: 42px 0 14px;
    font-size: 2rem;
    line-height: 1.14;
}

.article-body h3 {
    margin-bottom: 8px;
}

.article-body p,
.article-body li {
    color: var(--muted);
}

.callout {
    padding: 24px;
    border: 1px solid var(--line);
    border-left: 4px solid var(--amber);
    border-radius: 8px;
    background: var(--panel);
}

.callout h2 {
    margin-top: 0;
}

.callout p {
    margin-bottom: 0;
}

.steps {
    display: grid;
    gap: 18px;
    margin: 0;
    padding-left: 24px;
}

.steps li {
    padding-left: 6px;
}

.steps li::marker {
    color: var(--amber);
    font-weight: 800;
}

pre {
    max-width: 100%;
    margin: 14px 0 0;
    padding: 16px;
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #0b0d0e;
}

code {
    color: var(--text);
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
    font-size: 0.92rem;
}

.article-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.article-grid section {
    min-width: 0;
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
}

.site-footer {
    width: min(100% - 36px, var(--max));
    margin: 0 auto;
    padding: 34px 0 44px;
    border-top: 1px solid var(--line);
    color: var(--muted);
}

.site-footer p {
    margin: 0;
}

@media (max-width: 860px) {
    .hero {
        min-height: auto;
        padding-top: 112px;
    }

    .spectrum {
        right: 18px;
        bottom: 20vh;
        opacity: 0.42;
    }

    .hero-facts,
    .findings-grid,
    .lab-note ul,
    .note-columns,
    .article-grid {
        grid-template-columns: 1fr;
    }

    .note-columns {
        padding-top: 18px;
    }

    h1 {
        font-size: 4.7rem;
    }

    h2 {
        font-size: 3rem;
    }
}

@media (max-width: 640px) {
    .site-header {
        position: static;
        flex-direction: column;
        align-items: flex-start;
        padding: 16px 18px;
    }

    .nav {
        width: 100%;
        flex-wrap: wrap;
        justify-content: flex-start;
        gap: 8px 22px;
        font-size: 0.86rem;
    }

    .hero {
        padding: 74px 18px 30px;
    }

    h1 {
        font-size: 2.35rem;
        line-height: 1.08;
    }

    h2 {
        font-size: 1.85rem;
        line-height: 1.1;
    }

    .hero-copy {
        font-size: 1rem;
    }

    .hero-content,
    .section-heading {
        width: min(100%, 340px);
        max-width: 340px;
    }

    .hero-visual {
        opacity: 0.32;
    }

    .trace-a {
        width: 140vw;
        top: 26%;
        left: -20vw;
    }

    .trace-b,
    .trace-c {
        display: none;
    }

    .spectrum {
        display: none;
    }

    .hero-facts {
        display: none;
    }

    .section {
        width: min(100% - 28px, var(--max));
        padding: 58px 0;
    }

    .findings-grid article,
    .note-columns article,
    .lab-note,
    .article-grid section,
    .callout {
        padding: 20px;
    }

    .article-main {
        width: 360px;
        max-width: 92vw;
        margin-left: 14px;
        margin-right: 14px;
        padding-top: 78px;
    }

    .article-hero .hero-copy {
        width: 100%;
        max-width: 360px;
    }

    .article-hero h1 {
        font-size: 2.18rem;
        line-height: 1.08;
    }

    .article-body h2 {
        font-size: 1.6rem;
    }
}
