/* creel.css — the stylesheet. Colours come from css/tokens.css, which is
   GENERATED by tools/palette.mjs and proved pair by pair. Nothing chromatic is
   ever typed here: tools/validate.mjs refuses a chromatic literal in this file,
   because a brand hue typed into a stylesheet is the thing that drifts.

   THE SURFACE DIVISION, obeyed everywhere below and re-checked on the built
   pages by tools/contrast.mjs, which reads every text node's PAINTED pixels:

     .sheet   — thin glass (54%). Display type and graphic panels only. The
                darkest ink may carry small type on it; nothing else may.
     .card    — body glass (66%). Every paragraph, label and number.
     .slab    — dense glass (82%). Figures, tables, anything set small.

   A section wash is NOT a surface. `background: var(--wash)` over a photograph
   IS the photograph, and every contrast failure in this family of sites has
   been a sentence standing on a picture. */

/* ── the ground ─────────────────────────────────────────────────────────── */
.ground {
  position: fixed; inset: 0; z-index: -2;
  background: var(--ground-fill) url(/img/ground.jpg) center 42% / cover no-repeat;
}
.scrim {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(120% 80% at 50% 0%, rgba(var(--glass), .30), rgba(var(--glass), 0) 60%),
    linear-gradient(180deg, rgba(var(--glass), .22), rgba(var(--glass), 0) 22%, rgba(var(--glass), 0) 72%, rgba(var(--glass), .26));
}
@media (max-width: 760px) { .ground { background-image: url(/img/ground-m.jpg); background-position: center 38%; } }

/* ── type ───────────────────────────────────────────────────────────────── */
:root {
  --serif: "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans: "Figtree", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "DM Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --wrap: 1180px;
  --r: 18px;
  --r-lg: 26px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 92px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--sans); color: var(--ink);
  font-size: 16.5px; line-height: 1.62; letter-spacing: -.003em;
  background: var(--ground-fill);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .wordmark { font-family: var(--serif); font-weight: 600; letter-spacing: -.022em; line-height: 1.06; margin: 0; }
h1 { font-size: clamp(33px, 4.3vw, 52px); }
h2 { font-size: clamp(30px, 3.9vw, 45px); }
h3 { font-size: 19.5px; letter-spacing: -.012em; line-height: 1.25; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
em { font-style: italic; color: var(--russet); }
a { color: var(--russet); text-decoration-color: rgba(var(--russet-rgb), .38); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
code, .mono, .num { font-family: var(--mono); font-size: .92em; letter-spacing: -.01em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }
.muted { color: var(--ink-3); }
.small { font-size: 13.5px; line-height: 1.5; }
.eyebrow {
  display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--clay-ink); margin-bottom: 12px;
}

/* ── surfaces ───────────────────────────────────────────────────────────── */
.sheet, .card, .slab {
  border-radius: var(--r); border: 1px solid var(--line);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
}
.sheet { background: var(--surface); box-shadow: var(--shadow-sm); }
.card  { background: var(--surface-2); box-shadow: var(--shadow-sm); }
.slab  { background: var(--surface-3); box-shadow: var(--shadow-sm); }
.pad   { padding: 24px; }
.pad-lg { padding: clamp(22px, 3.2vw, 38px); }

/* ── nav ────────────────────────────────────────────────────────────────── */
.head { position: sticky; top: 0; z-index: 40; padding: 14px 0; }
.head-inner {
  display: flex; align-items: center; gap: 18px;
  padding: 8px 8px 8px 16px; border-radius: 99px;
  /* The nav pill sits over the TOP of the photograph, which is its brightest
     part. Solved against the painted pixels: at the palette's 46% head glass the
     links measured 3.61:1 there. Thickened to the body card's glass. */
  background: var(--surface-2); border: 1px solid var(--line);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  box-shadow: var(--shadow-sm);
}
.brand { display: flex; align-items: center; gap: 9px; color: var(--ink); text-decoration: none; flex: none; }
.brand svg { width: 26px; height: 26px; display: block; }
.brand b { font-family: var(--serif); font-size: 25px; font-weight: 600; letter-spacing: -.02em; }
.nav-links { display: flex; gap: 4px; margin-left: auto; }
.nav-links a {
  color: var(--ink); text-decoration: none; font-size: 14.5px; font-weight: 600;
  padding: 7px 11px; border-radius: 99px;
}
.nav-links a:hover { background: var(--wash); color: var(--ink); }
.nav-right { display: flex; align-items: center; gap: 8px; }
/* A cascade rule written for links WILL hit the buttons inside them: WICK
   shipped ink-on-ember at 2.08:1 this exact way. Buttons set their own colour
   and this file never sets colour on `.head a` as a group. */
.icon-btn {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 99px;
  color: var(--ink-2); background: var(--wash); text-decoration: none;
}
.icon-btn:hover { color: var(--ink); background: var(--wash-2); }
.burger { display: none; width: 36px; height: 36px; border: 0; border-radius: 99px; background: var(--wash); color: var(--ink); }

/* ── buttons ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px; justify-content: center;
  font-family: var(--sans); font-weight: 600; font-size: 15px; line-height: 1;
  padding: 12px 18px; border-radius: 99px; border: 1px solid transparent;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform .12s ease, box-shadow .12s ease, background .12s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--russet); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--russet-2); }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: var(--ink-2); }
.btn-glass { background: var(--surface-3); color: var(--ink); border-color: var(--line); }
.btn-glass:hover { background: rgba(var(--glass), .94); }
.btn-lg { padding: 15px 24px; font-size: 16px; }
.btn-sm { padding: 8px 13px; font-size: 13.5px; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; pointer-events: none; }
.arrow { transition: transform .14s ease; }
.btn:hover .arrow { transform: translateX(3px); }

/* ── chips ──────────────────────────────────────────────────────────────── */
.chip {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 6px 12px; border-radius: 99px; font-size: 13px; font-weight: 600;
  background: var(--surface-3); border: 1px solid var(--line); color: var(--ink);
}
.chip-clay { background: var(--clay); color: var(--clay-ink); border-color: rgba(var(--russet-rgb), .18); }
.chip-gold { background: var(--gold); color: var(--gold-ink); border-color: rgba(var(--gold-rgb), .5); }
.chip-haze { background: var(--haze); color: var(--indigo); border-color: rgba(var(--indigo-rgb), .16); }
.chip-sage { background: var(--sage); color: var(--ink); border-color: rgba(var(--up-rgb), .2); }
.dot { width: 7px; height: 7px; border-radius: 99px; background: var(--up); flex: none; }
.dot-live { box-shadow: 0 0 0 0 rgba(var(--up-rgb), .5); animation: pulse 2.4s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 7px rgba(var(--up-rgb), 0); } 100% { box-shadow: 0 0 0 0 rgba(var(--up-rgb), 0); } }

/* ── hero ───────────────────────────────────────────────────────────────── */
.hero { padding: 20px 0 34px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr); gap: 22px; align-items: start; }
.hero-card { padding: clamp(24px, 3vw, 38px); }
.wordmark { display: flex; align-items: center; gap: 12px; font-size: clamp(40px, 5.1vw, 60px); color: var(--ink); margin: 12px 0 10px; }
.wordmark svg { width: .82em; height: .82em; flex: none; }
.hero h1 { margin: 0 0 14px; }
.lede { font-size: 16.5px; line-height: 1.55; color: var(--ink-2); max-width: 46ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 11px; margin-top: 22px; }
.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 24px; }
.stat { padding: 14px 15px; border-radius: 14px; background: var(--surface-3); border: 1px solid var(--line-2); }
.stat .k { font-size: 10px; font-weight: 700; letter-spacing: .085em; text-transform: uppercase; color: var(--ink-3); }
.stat .v { font-family: var(--serif); font-size: 31px; font-weight: 600; line-height: 1.1; margin: 3px 0 2px; color: var(--ink); }
.stat .s { font-size: 12px; line-height: 1.35; color: var(--ink-3); }

/* the live card on the right of the hero */
.live-card { padding: 20px 20px 16px; overflow: hidden; }
.live-top { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 14px; }
.live-top h3 { font-size: 27px; }
.live-top .sub { font-size: 13.5px; color: var(--ink-3); margin-top: 4px; }
.seg { display: flex; gap: 2px; padding: 3px; border-radius: 99px; background: var(--wash); margin-top: 11px; overflow-x: auto; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg button { flex: none; }
.seg button {
  border: 0; background: transparent; font: 600 12.5px var(--sans); color: var(--ink-2);
  padding: 6px 11px; border-radius: 99px; cursor: pointer;
}
.seg button[aria-selected="true"] { background: rgba(var(--glass), .96); color: var(--ink); box-shadow: var(--shadow-sm); }
.legs { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; }
.legs li {
  display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 11px;
  padding: 8px 10px; border-radius: 11px;
}
/* Zebra rows: a list of identical pale rows is ONE pane, and one pane is a
   fill. Alternating lets the photograph show between them. */
.legs li:nth-child(odd) { background: rgba(var(--glass), .42); }
.tk { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; font: 700 10px var(--sans); color: #fff; letter-spacing: .02em; }
.legs .n { font-weight: 600; font-size: 14.5px; }
.legs .n i { display: block; font-style: normal; font-size: 12px; color: var(--ink-3); font-weight: 500; }
.legs .v { text-align: right; font-family: var(--mono); font-size: 13.5px; }
.legs .v i { display: block; font-style: normal; font-size: 11.5px; color: var(--ink-3); }
.live-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 13px; font-size: 12.5px; color: var(--ink-3); }
.skel { display: block; height: 12px; border-radius: 6px; background: var(--wash-2); animation: sk 1.3s ease-in-out infinite; }
@keyframes sk { 50% { opacity: .45; } }

/* ── strip ──────────────────────────────────────────────────────────────── */
.strip { padding: 4px 0 30px; }
.strip-inner { display: flex; flex-wrap: wrap; gap: 9px; justify-content: center; }

/* ── sections ───────────────────────────────────────────────────────────── */
.section { padding: 46px 0; }
.section-head { max-width: 62ch; margin-bottom: 26px; padding: 22px 26px; }
.section-head p { color: var(--ink-2); margin-top: 10px; }
.trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.duo { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.step .n {
  font-family: var(--mono); font-size: 12px; font-weight: 500; color: var(--clay-ink);
  background: var(--clay); display: inline-block; padding: 3px 9px; border-radius: 99px; margin-bottom: 12px;
}
.step h3 { margin-bottom: 8px; }
.step p { font-size: 15px; color: var(--ink-2); }
.what { margin-top: 13px; padding-top: 12px; border-top: 1px solid var(--line-2); font-size: 12.5px; color: var(--ink-3); }

/* the dark band. It has TWO surfaces: the band, and the card ON the band.
   No word ever sits on the band itself. */
.band {
  /* Not opaque: a viewport-sized block of solid ink measured 13.8% flat where
     the reference's worst frame is 12.5%. At 88% the weave reads through it.
     The inks on it are proved against the card ON the band by
     tools/palette.mjs and re-checked on painted pixels by tools/contrast.mjs,
     which is what says whether 88% is still legible. */
  background: rgba(var(--ink-rgb), .88);
  -webkit-backdrop-filter: saturate(140%) blur(1.5px); backdrop-filter: saturate(140%) blur(1.5px);
  border-radius: var(--r-lg); padding: clamp(24px, 3.4vw, 42px); color: var(--bright); }
.band h2 { color: var(--bright); }
.band .eyebrow { color: var(--clay); }
.band-card { background: rgba(255, 255, 255, .10); border: 1px solid rgba(255, 255, 255, .13); border-radius: 15px; padding: 20px; }
.band-card h3 { color: var(--bright); }
.band-card p { color: var(--gold); font-size: 14.5px; }
.band-card .k { font-size: 10.5px; font-weight: 700; letter-spacing: .085em; text-transform: uppercase; color: var(--clay); }
.band-card .v { font-family: var(--serif); font-size: 30px; color: var(--bright); line-height: 1.1; margin: 4px 0 3px; }

/* ── tables ─────────────────────────────────────────────────────────────── */
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th {
  text-align: left; font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-3); padding: 0 12px 9px; white-space: nowrap;
}
.tbl td { padding: 9px 12px; border-top: 1px solid var(--line-2); }
.tbl tbody tr:nth-child(even) { background: rgba(var(--glass), .38); }
.tbl .r { text-align: right; font-family: var(--mono); font-size: 13px; }
.tbl-wrap { overflow-x: auto; }
/* A long table on dense glass is ONE pane, and one pane is a fill: the market
   table on the 82% slab painted the page's flattest frame. Thin card, the type
   on alternating row surfaces of its own, and the photograph between them. */
.slab.thin { background: var(--surface); }
.slab.thin .tbl th, .slab.thin > .small { color: var(--ink); }   /* thin pane: darkest ink only */
.slab.thin .tbl tbody tr { background: rgba(var(--glass), .64); }
.slab.thin .tbl tbody tr:nth-child(even) { background: rgba(var(--glass), .84); }
.more { display: flex; justify-content: center; margin-top: 14px; }

/* ── faq ────────────────────────────────────────────────────────────────── */
details.faq { padding: 16px 20px; margin-bottom: 10px; }
details.faq summary { cursor: pointer; font-weight: 600; font-size: 16px; list-style: none; display: flex; gap: 12px; align-items: baseline; }
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after { content: "+"; margin-left: auto; color: var(--ink-3); font-family: var(--mono); }
details.faq[open] summary::after { content: "–"; }
details.faq p { margin-top: 11px; font-size: 15px; color: var(--ink-2); }

/* ── footer ─────────────────────────────────────────────────────────────── */
.foot { padding: 40px 0 54px; }
.foot-inner { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 26px; padding: 30px; }
.foot h4 { font-size: 10.5px; font-weight: 700; letter-spacing: .085em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 11px; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.foot a { color: var(--ink-2); text-decoration: none; font-size: 14px; }
.foot a:hover { color: var(--russet); }
.foot-note { margin-top: 18px; padding: 15px 18px; font-size: 12.5px; color: var(--ink); } /* the thin pane: only the darkest ink is proved for small type on it */

[hidden] { display: none !important; }

/* ── misc ───────────────────────────────────────────────────────────────── */
.rise { opacity: 0; transform: translateY(14px); }
.js .rise { transition: opacity .55s ease, transform .55s ease; }
.js .rise.in { opacity: 1; transform: none; }
html:not(.js) .rise { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .rise, .js .rise { opacity: 1 !important; transform: none !important; transition: none !important; } html { scroll-behavior: auto; } }
.warn { border-left: 3px solid var(--down); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 14px; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; font-family: var(--mono); font-size: 13px; word-break: break-all; }
.hr { height: 1px; background: var(--line); margin: 22px 0; border: 0; }

/* ── mobile ─────────────────────────────────────────────────────────────── */
@media (max-width: 980px) {
  .hero-grid, .trio, .duo, .foot-inner { grid-template-columns: 1fr; }
  .foot-inner { gap: 20px; }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .wrap { padding: 0 16px; }
  .nav-links { display: none; }
  .burger { display: grid; place-items: center; }
  .head-inner.open { border-radius: var(--r); flex-wrap: wrap; }
  .head-inner.open .nav-links { display: grid; width: 100%; order: 9; padding: 6px 0 4px; }
  .hero-stats { grid-template-columns: 1fr; }
  .section { padding: 34px 0; }
}
