/* ==========================================================================
   home-2026.css — homepage layout.

   Written as a replacement for home.css on the homepage ONLY. The other six
   pages that link home.css are untouched, so this can be reviewed live without
   a site-wide diff, and rolled out page by page afterwards.

   The brief was "it looks like an AI built it". The copy was never the problem;
   the LAYOUT GRAMMAR was. Every section was a centred h2, a centred subtitle,
   and a symmetric grid of equal cards with an icon in each. Six sections of
   that in a row is the tell, far more than any colour choice.

   So the rules here are:
     - almost nothing is centred
     - no section repeats the previous section's structure
     - the reading column never has the same width twice in a row
     - counts of things are 2, 3, 4 — never three-across every time
   ========================================================================== */

.wrap {
    max-width: var(--measure);
    margin: 0 auto;
    padding-inline: var(--gutter);
}

.wrap--narrow {
    max-width: 820px;
}

/* ==========================================================================
   HERO — asymmetric, dark, product on the right
   ========================================================================== */
.hero {
    background: var(--v-950);
    color: var(--on-dark);
    position: relative;
    overflow: hidden;
    padding: clamp(56px, 8vw, 104px) 0 clamp(52px, 7vw, 88px);
}

/* Two soft light sources rather than a flat fill. A single linear-gradient
   background is the other half of the generated-page look. */
.hero::before,
.hero::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.hero::before {
    width: 780px;
    height: 780px;
    top: -420px;
    left: -220px;
    background: radial-gradient(
        circle,
        rgba(124, 58, 237, 0.5) 0%,
        transparent 68%
    );
}

.hero::after {
    width: 620px;
    height: 620px;
    right: -240px;
    bottom: -360px;
    background: radial-gradient(
        circle,
        rgba(232, 121, 249, 0.28) 0%,
        transparent 68%
    );
}

.hero-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.94fr);
    gap: clamp(36px, 5vw, 72px);
    align-items: center;
}

.hero-eyebrow {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 26px;
}

.hero h1 {
    font-size: clamp(2.35rem, 5.1vw, 4.05rem);
    line-height: 0.99;
    letter-spacing: -0.038em;
    color: #fff;
    margin-bottom: 22px;
    max-width: 15ch;
}

.hero h1 em {
    font-style: normal;
    color: var(--orchid);
}

.hero-sub {
    font-size: clamp(1.02rem, 1.5vw, 1.18rem);
    line-height: 1.62;
    color: var(--on-dark-muted);
    max-width: 46ch;
    margin-bottom: 30px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    margin-bottom: 26px;
}

.hero-meta {
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.08em;
    color: var(--on-dark-faint);
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
}

.hero-meta strong {
    color: var(--cyan);
    font-weight: 500;
}

/* ---- the record inspector -------------------------------------------------
   Shows one generated row field by field instead of describing the product.
   Styled as an inspector pane, not a marketing card. */
.record {
    background: rgba(10, 4, 16, 0.72);
    border: 1px solid rgba(168, 85, 247, 0.34);
    box-shadow: 14px 14px 0 rgba(124, 58, 237, 0.16);
    font-family: var(--font-mono);
    font-size: 12.5px;
}

.record-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    border-bottom: 1px solid rgba(168, 85, 247, 0.26);
    color: var(--on-dark-muted);
    font-size: 11.5px;
    letter-spacing: 0.02em;
}

.record-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--orchid);
    flex: none;
}

.record-dot:nth-child(2) {
    background: var(--v-500);
}

.record-dot:nth-child(3) {
    background: var(--cyan);
}

.record-bar span:last-child {
    margin-left: auto;
    color: var(--on-dark-faint);
}

.record-body {
    padding: 6px 0;
}

.record-row {
    display: grid;
    grid-template-columns: minmax(0, 148px) minmax(0, 1fr);
    gap: 12px;
    padding: 6px 14px;
    align-items: baseline;
}

.record-row:nth-child(odd) {
    background: rgba(168, 85, 247, 0.055);
}

.record-key {
    color: var(--v-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.record-val {
    color: var(--on-dark);
}

.record-val.is-num {
    color: var(--cyan);
}

.record-foot {
    border-top: 1px solid rgba(168, 85, 247, 0.26);
    padding: 11px 14px;
    font-size: 11px;
    letter-spacing: 0.04em;
    color: var(--on-dark-faint);
    display: flex;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

/* ==========================================================================
   STAT BAR — one horizontal strip, not three cards
   ========================================================================== */
.statbar {
    background: var(--v-900);
    color: var(--on-dark);
    border-top: 1px solid rgba(232, 121, 249, 0.2);
}

.statbar-inner {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.stat {
    padding: 26px var(--gutter);
    border-left: 1px solid rgba(232, 121, 249, 0.16);
}

.stat:first-child {
    border-left: none;
}

.stat-value {
    font-size: clamp(1.7rem, 3vw, 2.35rem);
    font-weight: 700;
    letter-spacing: -0.035em;
    line-height: 1;
    color: #fff;
}

.stat-label {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--on-dark-muted);
    margin-top: 9px;
}

/* ==========================================================================
   FAILURES — sticky heading on the left, numbered entries on the right
   ========================================================================== */
.failures {
    padding: clamp(64px, 8vw, 108px) 0;
}

.split {
    display: grid;
    grid-template-columns: minmax(0, 0.72fr) minmax(0, 1.28fr);
    gap: clamp(32px, 6vw, 88px);
    align-items: start;
}

.split-head {
    position: sticky;
    top: 116px;
}

.split-head .motif {
    margin-bottom: 22px;
}

.split-head h2 {
    margin: 14px 0 16px;
    max-width: 12ch;
}

.split-head p {
    color: var(--ink-muted);
    font-size: 1.02rem;
    max-width: 32ch;
}

.entry {
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr);
    gap: 8px;
    padding: 30px 0;
    border-top: 1px solid var(--rule);
}

.entry:first-child {
    border-top: none;
    padding-top: 0;
}

.entry-num {
    font-family: var(--font-mono);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--v-500);
    padding-top: 5px;
}

.entry h3 {
    margin-bottom: 10px;
}

.entry p {
    color: var(--ink-muted);
    max-width: 58ch;
}

.entry p b {
    color: var(--ink);
    font-weight: 600;
}

.failures-cta {
    margin-top: 36px;
    padding-left: 74px;
}

/* ==========================================================================
   ANATOMY — the sample table as a real data grid
   ========================================================================== */
.anatomy {
    background: var(--paper-2);
    border-block: 1px solid var(--rule);
    padding: clamp(56px, 7vw, 92px) 0;
}

.anatomy-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 24px;
    flex-wrap: wrap;
    margin-bottom: 28px;
}

.anatomy-head h2 {
    max-width: 16ch;
}

.anatomy-head p {
    color: var(--ink-muted);
    max-width: 40ch;
    font-size: 1rem;
}

.grid-scroll {
    overflow-x: auto;
    background: var(--paper);
    border: 1px solid var(--rule-strong);
    box-shadow: 10px 10px 0 rgba(76, 29, 149, 0.08);
}

.data-grid {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--font-mono);
    font-size: 12.5px;
    white-space: nowrap;
}

.data-grid th {
    text-align: left;
    font-weight: 600;
    font-size: 10.5px;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--v-700);
    background: var(--paper-3);
    padding: 12px 16px;
    border-bottom: 1px solid var(--rule-strong);
}

.data-grid td {
    padding: 11px 16px;
    border-bottom: 1px solid var(--rule);
    color: var(--ink-muted);
}

.data-grid tbody tr:hover td {
    background: rgba(232, 121, 249, 0.07);
    color: var(--ink);
}

.data-grid .col-idx {
    color: var(--ink-faint);
    width: 1%;
    background: var(--paper-2);
    text-align: right;
}

.data-grid .col-name {
    color: var(--ink);
    font-weight: 500;
}

.data-grid .col-num {
    text-align: right;
}

.field-strip {
    margin-top: 22px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.field-strip-label {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-faint);
    margin-right: 6px;
}

.chip {
    font-family: var(--font-mono);
    font-size: 11.5px;
    padding: 5px 10px;
    color: var(--v-800);
    background: var(--paper);
    border: 1px solid var(--rule-strong);
}

.chip--more {
    color: var(--ink-faint);
    border-style: dashed;
}

/* ==========================================================================
   SAMPLES band
   ========================================================================== */
.samples {
    background: var(--v-950);
    color: var(--on-dark);
    padding: clamp(56px, 7vw, 88px) 0;
}

.samples-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
    gap: clamp(28px, 5vw, 64px);
    align-items: center;
}

.samples h2 {
    color: #fff;
    margin: 16px 0 14px;
    max-width: 18ch;
}

.samples p {
    color: var(--on-dark-muted);
    max-width: 48ch;
    margin-bottom: 26px;
}

.samples-side {
    font-family: var(--font-mono);
    font-size: 12px;
    line-height: 2.1;
    letter-spacing: 0.04em;
    color: var(--on-dark-muted);
    border-left: 1px solid rgba(232, 121, 249, 0.3);
    padding-left: 26px;
}

.samples-side b {
    color: var(--cyan);
    font-weight: 500;
}

/* ==========================================================================
   PERSONAS — two panels, deliberately offset and unequal
   ========================================================================== */
.personas {
    padding: clamp(64px, 8vw, 104px) 0;
}

.personas-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
    margin-bottom: 44px;
}

.personas-head h2 {
    max-width: 14ch;
}

/* A left rule, the same annotation device used by .samples-side and
   .quote-body. Bottom-aligned text with a wide gap and no rule just floats. */
.personas-head p {
    color: var(--ink-muted);
    max-width: 30ch;
    border-left: 2px solid var(--orchid);
    padding: 2px 0 2px 18px;
}

/* Equal columns. Asymmetry here is carried by TREATMENT alone -- one panel is
   light, one is inverted -- and by nothing structural.

   Two earlier attempts got this wrong in the same direction. The first pushed
   the second panel down 56px; the second made the columns 1.08fr / 0.92fr.
   Both were deliberate, and both read as sloppiness rather than as intent,
   because a reader cannot tell a 4% width difference from a mistake. Unequal
   geometry only reads as a choice when it is unmistakably large; anything
   subtle just looks like it failed to line up. The variety this page needs
   comes from sections not repeating each other, not from pairs being slightly
   off. */
.persona-pair {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(20px, 3vw, 40px);
    align-items: stretch;
}

.persona {
    padding: 34px 32px 30px;
    border: 1px solid var(--rule-strong);
    background: var(--paper-2);
    display: flex;
    flex-direction: column;
}

/* push the CTA to the bottom edge so both panels end on the same line */
.persona-cta {
    margin-top: auto;
    align-self: flex-start;
}

.persona:nth-child(2) {
    background: var(--v-950);
    color: var(--on-dark);
    border-color: var(--v-800);
}

.persona-tag {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--v-700);
}

.persona:nth-child(2) .persona-tag {
    color: var(--cyan);
}

.persona h3 {
    margin: 12px 0 8px;
    font-size: 1.5rem;
}

.persona:nth-child(2) h3 {
    color: #fff;
}

.persona-line {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.1rem;
    color: var(--v-700);
    margin-bottom: 14px;
}

.persona:nth-child(2) .persona-line {
    color: var(--orchid);
}

.persona > p {
    color: var(--ink-muted);
    margin-bottom: 20px;
}

.persona:nth-child(2) > p {
    color: var(--on-dark-muted);
}

.persona ul {
    list-style: none;
    margin-bottom: 24px;
}

.persona li {
    position: relative;
    padding-left: 22px;
    padding-block: 6px;
    font-size: 15px;
    color: var(--ink-muted);
    border-top: 1px solid var(--rule);
}

.persona:nth-child(2) li {
    color: var(--on-dark-muted);
    border-top-color: rgba(232, 121, 249, 0.18);
}

.persona li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 15px;
    width: 11px;
    height: 2px;
    transform: skewX(var(--slant));
    background: var(--v-500);
}

.persona:nth-child(2) li::before {
    background: var(--cyan);
}

.persona-cta {
    font-family: var(--font-mono);
    font-size: 12.5px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--v-800);
    text-decoration: none;
    border-bottom: 2px solid var(--orchid);
    padding-bottom: 3px;
}

.persona:nth-child(2) .persona-cta {
    color: var(--orchid-pale);
}

.persona-cta:hover {
    border-bottom-color: var(--v-700);
}

/* ==========================================================================
   LEDGER — the two-option comparison, with a real centre rule
   ========================================================================== */
.ledger {
    background: var(--paper-2);
    border-block: 1px solid var(--rule);
    padding: clamp(56px, 7vw, 92px) 0;
}

.ledger h2 {
    max-width: 18ch;
    margin: 14px 0 14px;
}

.ledger > .wrap > p {
    color: var(--ink-muted);
    max-width: 52ch;
    margin-bottom: 38px;
}

.ledger-pair {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0;
    background: var(--paper);
    border: 1px solid var(--rule-strong);
}

.ledger-col {
    padding: 28px 30px 32px;
}

.ledger-col + .ledger-col {
    border-left: 1px solid var(--rule-strong);
    background: rgba(232, 121, 249, 0.05);
}

.ledger-col h3 {
    font-size: 1.1rem;
    margin-bottom: 18px;
}

.ledger-col--bad h3 {
    color: var(--ink-faint);
}

.ledger-col ul {
    list-style: none;
}

.ledger-col li {
    font-family: var(--font-mono);
    font-size: 13px;
    line-height: 1.55;
    padding: 11px 0 11px 26px;
    position: relative;
    border-top: 1px solid var(--rule);
    color: var(--ink-muted);
}

.ledger-col li::before {
    position: absolute;
    left: 0;
    top: 11px;
    font-size: 13px;
}

.ledger-col--bad li::before {
    content: '×';
    color: var(--ink-faint);
}

.ledger-col--good li::before {
    content: '→';
    color: var(--v-600);
}

/* ==========================================================================
   PULL QUOTE
   ========================================================================== */
.quote {
    padding: clamp(60px, 8vw, 100px) 0;
}

.quote blockquote {
    font-family: var(--font-serif);
    font-size: clamp(1.35rem, 2.6vw, 1.95rem);
    line-height: 1.42;
    letter-spacing: -0.01em;
    color: var(--ink);
    max-width: 26ch;
    margin: 0;
}

.quote-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    gap: clamp(28px, 5vw, 64px);
    align-items: start;
}

.quote-body {
    font-family: var(--font-serif);
    font-size: 1.14rem;
    line-height: 1.7;
    color: var(--ink-muted);
    border-left: 3px solid var(--orchid);
    padding-left: 26px;
}

.quote-attr {
    display: block;
    margin-top: 20px;
    font-family: var(--font-mono);
    font-style: normal;
    font-size: 11.5px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--ink-faint);
}

/* ==========================================================================
   CLOSING CTA
   ========================================================================== */
.closer {
    background: var(--v-950);
    color: var(--on-dark);
    padding: clamp(64px, 8vw, 104px) 0;
    position: relative;
    overflow: hidden;
}

.closer::after {
    content: '';
    position: absolute;
    width: 700px;
    height: 700px;
    right: -280px;
    top: -300px;
    border-radius: 50%;
    background: radial-gradient(
        circle,
        rgba(168, 85, 247, 0.32) 0%,
        transparent 68%
    );
    pointer-events: none;
}

.closer-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
    gap: clamp(28px, 5vw, 64px);
    align-items: center;
}

.closer h2 {
    color: #fff;
    font-size: clamp(2rem, 4.2vw, 3.2rem);
    max-width: 14ch;
    margin: 16px 0 18px;
}

.closer p {
    color: var(--on-dark-muted);
    max-width: 44ch;
}

.closer code {
    font-family: var(--font-mono);
    background: rgba(232, 121, 249, 0.16);
    border: 1px solid rgba(232, 121, 249, 0.34);
    color: var(--cyan);
    padding: 2px 8px;
    font-size: 0.92em;
}

.closer-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
}

/* ==========================================================================
   Post-download banner (kept — home.js toggles .visible on it)
   ========================================================================== */
.post-download-banner {
    display: none;
    margin-top: 20px;
    padding: 18px 20px;
    background: rgba(232, 121, 249, 0.1);
    border: 1px solid rgba(232, 121, 249, 0.38);
    font-size: 14.5px;
    color: var(--on-dark);
    max-width: 52ch;
}

.post-download-banner.visible {
    display: block;
}

.post-download-banner strong {
    color: var(--cyan);
}

.banner-actions {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    margin-top: 12px;
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.banner-actions a {
    color: var(--orchid-pale);
    text-decoration: none;
    border-bottom: 1px solid var(--orchid);
    padding-bottom: 2px;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 980px) {
    .hero-grid,
    .split,
    .samples-grid,
    .quote-grid,
    .closer-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .split-head {
        position: static;
    }

    .persona-pair,
    .ledger-pair {
        grid-template-columns: minmax(0, 1fr);
    }

    .ledger-col + .ledger-col {
        border-left: none;
        border-top: 1px solid var(--rule-strong);
    }

    .quote blockquote {
        max-width: 34ch;
    }
}

@media (max-width: 620px) {
    .entry {
        grid-template-columns: minmax(0, 1fr);
        gap: 4px;
    }

    .failures-cta {
        padding-left: 0;
    }

    .stat {
        border-left: none;
        border-top: 1px solid rgba(232, 121, 249, 0.16);
        padding-block: 20px;
    }

    .statbar-inner .stat:first-child {
        border-top: none;
    }
}
