
/* ═══ The keyframe registry — all 16, verbatim per spec §0.2 ═══════════════
   Every animated graphic on the site draws from this one block. Stagger with
   per-path delays — synchronised pulses read as one blinking object (rule 1).
   Animating r on a <circle> (ripple/spark/coreRing/coreBeat) is intentional:
   r is a CSS-animatable SVG geometry property; converting to transform:scale
   would scale the stroke width too (§0.2 gotcha 1). Any transform-animated
   SVG child needs transform-box:fill-box + transform-origin on the element
   (§0.2 gotcha 2) — set inline where used. */
@keyframes flow      { to { stroke-dashoffset: -48; } }
@keyframes bcFlow    { to { stroke-dashoffset: -95; } }
@keyframes spin      { to { transform: rotate(360deg); } }
@keyframes railPulse { 0% { left:3%; opacity:0; } 10% { opacity:1; } 90% { opacity:1; } 100% { left:97%; opacity:0; } }
@keyframes ripple    { 0% { r:10; opacity:.5; } 100% { r:132; opacity:0; } }
@keyframes breathe   { 0%,100% { opacity:.55; transform:scale(1); } 50% { opacity:1; transform:scale(1.06); } }
@keyframes netdraw   { 0% { stroke-dashoffset:420; opacity:0; } 5% { opacity:.9; } 32% { stroke-dashoffset:0; } 90% { stroke-dashoffset:0; opacity:.9; } 100% { stroke-dashoffset:0; opacity:0; } }
@keyframes nodepop   { 0%,6% { transform:scale(0); opacity:0; } 20% { transform:scale(1.4); opacity:1; } 28% { transform:scale(1); opacity:1; } 90% { transform:scale(1); opacity:1; } 100% { transform:scale(1); opacity:0; } }
@keyframes spark     { 0%,8% { r:2; opacity:0; } 18% { r:13; opacity:.7; } 34% { r:26; opacity:0; } 100% { r:2; opacity:0; } }
@keyframes coreBeat  { 0%,100% { r:7; opacity:1; } 50% { r:9.5; opacity:.8; } }
@keyframes coreRing  { 0% { r:9; opacity:.55; } 100% { r:44; opacity:0; } }
@keyframes barGrow   { 0% { transform:scaleY(.12); opacity:.35; } 55%,100% { transform:scaleY(1); opacity:1; } }
@keyframes trendDraw { 0% { stroke-dashoffset:340; } 65%,100% { stroke-dashoffset:0; } }
@keyframes floatY    { 0%,100% { transform:translateY(0); } 50% { transform:translateY(-5px); } }
@keyframes seedPulse { 0%,100% { transform:scale(1); opacity:1; } 50% { transform:scale(1.12); opacity:.82; } }
@keyframes sheen     { 0% { transform:translateX(-120%); } 100% { transform:translateX(220%); } }
@keyframes bcHub     { 0%,100% { opacity:.25; } 50% { opacity:.5; } }

/* ═══ 1. Hero wash ═══════════════════════════════════════════════════════
   Three stops give the wash its direction; two large blurred RADIALS (never
   blurred solid discs — those keep a visible edge on light backgrounds,
   guide rule 8) add corner depth; a bottom-to-white overlay dissolves the
   band into the page so there is no hard seam.
   Amber is deliberately absent — amber into indigo/sky goes olive. */
.hero {
  position: relative; overflow: hidden;
  background: linear-gradient(165deg, #F6F8FF 0%, #EDF2FE 46%, #E3EFFC 100%);
  padding: 64px 0 56px;   /* N-12: was 76/88 */
}

/* The three band washes — pick one per page, never invent a fourth (§0.4).
   Wash A (above) = "calm": home, services, contact, FAQ, legal.
   Wash B = "catalog": marketplace, software, portfolio, about, build, billing,
   development, blog, dreamboard, cart. The amber stop sits at 120% ON PURPOSE —
   only the very corner of the band picks up warmth; pull it to 100% and the
   whole band goes olive.
   SpamSky variant: green mid-stop for the anti-abuse product (the only local
   variant the spec allows). Wash C (dark) lives on .band--dark in daylight.css
   and is reserved for the domain listing. */
.hero--catalog { background: linear-gradient(115deg, #EEF2FF 0%, #E0F2FE 60%, #FEF3C7 120%); }
.hero--spamsky { background: linear-gradient(115deg, #EEF2FF 0%, #DCFCE7 55%, #E0F2FE 120%); }
.hero > .shell { position: relative; z-index: 2; }
.hero-glow { position: absolute; width: 520px; height: 520px; border-radius: 50%; filter: blur(90px); opacity: .55; pointer-events: none; z-index: 0; }
.hero-glow--a { left: -140px; top: -160px; background: radial-gradient(circle, rgba(67,56,202,.16), rgba(67,56,202,0) 70%); }
.hero-glow--b { right: -170px; top: -90px;  background: radial-gradient(circle, rgba(2,132,199,.18), rgba(2,132,199,0) 70%); }
.hero-seam { position: absolute; inset: auto 0 0 0; height: 80px; z-index: 1; pointer-events: none;
             background: linear-gradient(to bottom, rgba(255,255,255,0), #FFFFFF); }

/* the gradient headline word */
.grad {
  background: linear-gradient(115deg, var(--indigo), var(--sky));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* Hero art slot: operator-uploaded background. When the slot is empty the
   band stays on the gradient wash and NOTHING shifts — the art is additive.
   (Page Hero Manager ships in phase 4; this is the receiving surface.) */
.hero--art { background-size: cover; background-position: center; }
.hero-scrim { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.hero-scrim--light { background: linear-gradient(100deg, rgba(255,255,255,.96) 0%, rgba(255,255,255,.90) 38%, rgba(255,255,255,.55) 62%, rgba(255,255,255,.18) 100%); }
.hero-scrim--dark  { background: linear-gradient(100deg, rgba(11,18,32,.88) 0%, rgba(11,18,32,.74) 42%, rgba(11,18,32,.40) 70%, rgba(11,18,32,.12) 100%); }
.hero--dark, .hero--dark h1 { color: #fff; }
.hero--dark .lede { color: var(--dark-body); }

/* ── 1b. The 404 / 500 hero ───────────────────────────────────────────────
   Served for BOTH handlers (app.py binds them to the same template), so
   nothing here may imply "you mistyped the URL".

   Three deliberate departures from the generic .hero--art:

   1. background-position is `center bottom`, not `center`. The plate's whole
      subject — skyline, lake, palms — sits along its lower edge; centring it
      crops the horizon out on short viewports and leaves an empty sky.
   2. min-height buys enough band to actually show that horizon. Without it the
      hero collapses to the height of four lines of copy and the art is a
      sliver.
   3. The seam is taller and opaque at its base. The generic 80px fade is tuned
      for a flat gradient wash; over photographic detail it lets the skyline
      bleed into the card grid underneath. */
.hero--404 {
  min-height: 600px;
  padding: 104px 0 128px;
  background-position: center bottom;
  background-repeat: no-repeat;
}
.hero--404 .hero-seam {
  height: 110px;
  background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,.88) 74%, #fff);
}
@media (max-width: 720px) {
  /* Portrait viewports crop the plate hard. Shorten the band and let the scrim
     do more of the work rather than showing a random slice of sky. */
  .hero--404 { min-height: 440px; padding: 64px 0 84px; }
}

/* The signal read-out. A terminal, because that is this design system's
   existing vocabulary for "the machine is telling you something", and it gives
   the band a dark anchor against a very pale photograph.

   It says NOTHING about the requested path, and it cannot be made to: scaffold
   Rule 23(e) forbids this page from echoing the request URL, because a probe
   against a URL containing the admin slug pattern would reflect the slug
   straight back to an unauthenticated client. The copy here is fixed. */
.sigbox {
  background: rgba(11,18,32,.94);
  border: 1px solid var(--term-line);
  border-radius: var(--r-lg);
  padding: 14px 16px;
  font-family: var(--mono);
  font-size: var(--fs-mono);
  line-height: 2;
  max-width: 520px;
  box-shadow: var(--sh-lift);
}
.sigbox .s { color: var(--term-warn); }
.sigbox .n { color: var(--term-err); }
.sigbox .o { color: var(--term-ok); }
.sigbox .c { color: var(--term-comment); }
.sigbox .v { color: var(--term-value); }
.err-code {
  font-family: var(--mono); font-size: var(--fs-micro); font-weight: 600;
  letter-spacing: .14em; color: var(--ink-soft);
}

/* ═══ 2. Network console — browser chrome + data heatmap ═════════════════
   Each cell is one real record. Positions are shuffled server-side with a
   seeded PRNG so the map looks organic but never churns between renders. */
.heat { display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px; }
@media (max-width: 900px) { .heat { grid-template-columns: repeat(10, 1fr); } }
@media (max-width: 560px) { .heat { grid-template-columns: repeat(8, 1fr); } }
.heat i, .heat a {
  display: block; aspect-ratio: 1; border-radius: 6px;      /* square by ratio */
  background: var(--cell); border: 1px solid var(--cell);
  cursor: pointer;
  transition: transform .14s ease, box-shadow .14s ease;
}
.heat i { cursor: default; }   /* held padding is not a link */
/* Spec §1.2 hover: scale + ring + lift above neighbours. */
.heat i, .heat a { display: block; }
.heat a { cursor: pointer; }
.heat i:hover, .heat a:hover, .heat a:focus-visible {
  transform: scale(1.16); box-shadow: 0 0 0 2px rgba(67,56,202,.18); position: relative; z-index: 2;
}
.heat a:focus-visible { outline: none; box-shadow: var(--focus); }
.heat .is-live { --cell: var(--ok);   box-shadow: 0 0 0 3px var(--ok-bg); }
.heat .is-build{ --cell: var(--amber); }
.heat .is-sale { --cell: var(--sky); opacity: .85; }
.heat .is-top  { --cell: var(--indigo); }
.heat .is-held { --cell: var(--bg-track); border-color: var(--line); }
.heat-legend { display: flex; flex-wrap: wrap; gap: 14px; font-family: var(--mono); font-size: var(--fs-mono); color: var(--ink-faint); }
.heat-legend span { display: inline-flex; align-items: center; gap: 6px; }
.heat-legend i { width: 8px; height: 8px; border-radius: 2px; }
.heat-foot { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(120px,100%),1fr)); border-top: 1px solid var(--line); }
.heat-foot > div { padding: 13px 16px; border-right: 1px solid var(--line); }
.heat-foot > div:last-child { border-right: 0; }
.heat-foot b { display: block; font-size: var(--fs-lg); font-weight: 700; color: var(--ink); }
.heat-foot span { font-family: var(--mono); font-size: var(--fs-mono); color: var(--ink-faint); }

/* ═══ 3 & 4. SVG diagrams — hub-and-spoke, license-key flow ══════════════
   Scaling is the viewBox plus these two lines only. Crop the viewBox to the
   drawing's real bounds: slack is why SVG diagrams look lost in their card.
   (Guide rule 7.) */
.diagram { display: block; width: 100%; height: auto; }
.diagram-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-2xl); padding: 26px; box-shadow: var(--sh-card); }
.diagram-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }

/* ═══ 5. Circuit CTA band ════════════════════════════════════════════════
   Full-bleed indigo→sky panel, one S-curve trace stretched edge to edge
   (preserveAspectRatio="none"), a pulse riding it, and — the part everyone
   forgets — a copy scrim with MID-STOPS. A two-stop scrim bands visibly
   across the paragraph. (Guide rule 3.) */
.circuit {
  position: relative; overflow: hidden; color: #fff;
  background: linear-gradient(115deg, var(--indigo) 0%, var(--sky) 100%);
  border-radius: var(--r-4xl); padding: 60px 56px;
}
.circuit-trace { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .35; pointer-events: none; }
.circuit-scrim {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(100deg, rgba(67,56,202,.92) 0%, rgba(67,56,202,.74) 34%, rgba(67,56,202,.34) 58%, rgba(67,56,202,0) 78%);
}
.circuit > * { position: relative; z-index: 1; }   /* every text child needs this */
.circuit > .circuit-scrim { position: absolute; inset: 0; }
.circuit h2 { color: #fff; }
.circuit p  { color: rgba(255,255,255,.86); max-width: 54ch; margin-top: 10px; }
@media (max-width: 640px) { .circuit { padding: 40px 26px; } }

/* ═══ 2b. Domain listing card — category art header (spec §2) ═════════════
   The card body is the shared .card; this header sits above it, flush to the
   card edges. Wash/dot/ink come inline from the route's CATEGORY_WASHES. */
.dcard { padding: 0; overflow: hidden; }
.dcard > .chip-row, .dcard > h3, .dcard > p { margin-left: 22px; margin-right: 22px; }
.dcard > h3 { margin-top: 14px; }
.dcard > p { margin-top: 6px; }
.dcard > .card-foot { margin: 18px 22px 22px; }
.dcard-head { position: relative; height: 84px; border-bottom: 1px solid var(--line); margin-bottom: 16px; }
.dcard-tex { position: absolute; inset: 0; opacity: .05; background-image: radial-gradient(#0F172A 1px, transparent 1px); background-size: 20px 20px; }
.dcard-fade { position: absolute; inset: auto 0 0 0; height: 34px; background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,.55)); }
.dcard-cat {
  position: absolute; left: 14px; bottom: 10px; display: inline-flex; align-items: center; gap: 6px;
  font-size: var(--fs-xs); font-weight: 600; background: rgba(255,255,255,.92);
  border-radius: var(--r-pill); padding: 3px 10px;
}
.dcard-cat i { width: 6px; height: 6px; border-radius: 50%; flex: none; }

/* ═══ 7. Property card — tinted wash, sheen, monogram, art fallback ══════
   Cards must look complete before any screenshot exists. When the operator
   drops real art in the admin it covers the wash and the fallback label
   hides itself — the layout never moves. */
.pcard { background: #fff; border: 1px solid var(--line); border-radius: var(--r-xl); overflow: hidden; box-shadow: var(--sh-card); display: block; color: inherit; transition: border-color .15s, box-shadow .15s; }
.pcard:hover { border-color: var(--indigo-200); box-shadow: var(--sh-lift); text-decoration: none; }
.pcard-head {
  position: relative; height: 78px; overflow: hidden;   /* spec §5: 78px, not a taller invented band */
  background: linear-gradient(135deg, var(--wash-a, #EEF2FF), var(--wash-b, #E0E7FF));
  background-size: cover; background-position: center;
}
.pcard-tex { position: absolute; inset: 0; opacity: .05; background-image: radial-gradient(#0F172A 1px, transparent 1px); background-size: 20px 20px; }
.pcard-fade { position: absolute; inset: auto 0 0 0; height: 34px; background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,.55)); }
.pcard-sheen { position: absolute; inset: 0 auto 0 0; width: 40%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.55), transparent); animation: sheen 5.5s ease-in-out infinite; pointer-events: none; }
.pcard--art .pcard-tex, .pcard--art .pcard-label { display: none; }
.pcard-label { position: absolute; left: 16px; bottom: 10px; font-family: var(--mono); font-size: var(--fs-mono); color: var(--ink-faint); }
.pcard-status { position: absolute; top: 12px; right: 12px; }
.pcard-body { padding: 0 18px 18px; }
.pcard-mono {
  width: 40px; height: 40px; margin-top: -20px; border-radius: var(--r-md);
  border: 2px solid #fff; box-shadow: var(--sh-mono);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: var(--fs-sm); color: #fff; position: relative; z-index: 1;
}
.pcard h3 { margin: 12px 0 6px; font-size: var(--fs-md); }
.pcard p { font-size: var(--fs-sm); color: var(--ink-muted); }
.pcard-foot { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); font-family: var(--mono); font-size: var(--fs-mono); color: var(--ink-faint); }

/* ═══ 8. Terminal panel — the one place mono stays ═══════════════════════
   Daylight keeps exactly one terminal idiom, boxed as an artifact. Top and
   bottom fades so lines enter and leave rather than being guillotined. */
.term { background: var(--term-bg); border: 1px solid var(--term-line); border-radius: var(--r-2xl); overflow: hidden; box-shadow: var(--sh-pop); }
.term-bar { display: flex; align-items: center; gap: 7px; padding: 10px 14px; background: var(--term-bar); border-bottom: 1px solid var(--term-line); }
.term-bar .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--term-dot); }
/* N-4/N-6 (operator): the chrome dots carry the macOS trio on every terminal. */
.term-bar .dot:nth-of-type(1) { background: #F87171; }
.term-bar .dot:nth-of-type(2) { background: #FBBF24; }
.term-bar .dot:nth-of-type(3) { background: #34D399; }
.term-bar .path { margin-left: 6px; font-family: var(--mono); font-size: var(--fs-mono); color: var(--term-path); }
.term-bar .live { margin-left: auto; font-family: var(--mono); font-size: 10px; color: var(--term-ok); }
.term-body { position: relative; padding: 16px 18px; font-family: var(--mono); font-size: var(--fs-mono); line-height: 1.85; min-height: 190px; }
.term-body::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 26px; background: linear-gradient(var(--term-bg), rgba(11,18,32,0)); pointer-events: none; }
.term-body::after  { content: ""; position: absolute; inset: auto 0 0 0; height: 34px; background: linear-gradient(rgba(11,18,32,0), var(--term-bg)); pointer-events: none; }
.term-prompt  { color: var(--term-prompt); }
/* N-4: build-summary rows — roomier rhythm, brighter keys, semantic values. */
.term-kv { display: flex; justify-content: space-between; gap: 12px; align-items: baseline;
           border-bottom: 1px dashed rgba(30,41,59,.7); padding: 6px 0; line-height: 1.75; }
.term-kv .k { color: var(--term-path); }
.term-kv .v { text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 70%; }
.term-kv .v--info { color: var(--term-value); } .term-kv .v--ok { color: var(--term-ok); }
.term-kv .v--neutral { color: var(--term-command); } .term-kv .v--empty { color: var(--term-comment); }
.term-kv--wrap { align-items: flex-start; }
.term-kv--wrap .v { white-space: normal; overflow: visible; text-overflow: clip;
                    max-width: 74%; line-height: 1.6; }
@media (max-width: 620px) {
  .term-kv--wrap { flex-direction: column; gap: 2px; }
  .term-kv--wrap .v { max-width: 100%; text-align: left; }
}

.term-command { color: var(--term-command); }
.term-value   { color: var(--term-value); }
.term-ok      { color: var(--term-ok); }
.term-warn    { color: var(--term-warn); }
.term-err     { color: var(--term-err); }
.term-comment { color: var(--term-comment); }

.term-log { display: block; padding: 5px 0; line-height: 1.7;
  border-bottom: 1px dashed rgba(30,41,59,.7); }
.term-log:last-child { border-bottom: 0; }
.term-log > span { margin-right: 8px; }
.term-log .term-command { display: inline; word-break: break-word; }
.term-log .term-note { display: block; margin: 2px 0 0 26px; color: var(--term-comment); }

/* Stage cards (domain listing, spec §3.3) — hover lift ported from the
   mockup's style-hover. */
.stagecard { transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.stagecard:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(15,23,42,.08), 0 28px 56px rgba(15,23,42,.14); }

/* ═══ Rail / pipeline / gauge — supporting marks ═════════════════════════ */
.rail { position: relative; height: 2px; background: var(--line); border-radius: var(--r-pill); }
.rail > i { position: absolute; top: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--sky); }

/* SpamSky lifecycle rail (spec §9.2) — 5-step rail with a travelling dot.
   railPulse animates `left` 3%→97% with fades at both ends so the dot never
   pops in at a step marker. The wrapper is position:relative; the step tiles
   grid sits under it. Hide .liferail-track/.liferail-dot below the width where
   the step grid stacks, or the line floats across nothing. */
.liferail { position: relative; padding-top: 54px; }
.liferail-track {
  position: absolute; left: 6%; right: 6%; top: 27px; height: 2px;
  background: linear-gradient(90deg, #E2E8F0, #C7D2FE, #DCFCE7);
}
.liferail-dot {
  position: absolute; top: 24px; width: 8px; height: 8px; border-radius: 50%;
  background: var(--ok); box-shadow: 0 0 10px 3px rgba(21,128,61,.45);
  animation: railPulse 4.6s cubic-bezier(.6,.05,.4,.95) infinite;
}
.liferail-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(150px,100%),1fr)); gap: 14px; }
.liferail-steps .tile {
  width: 56px; height: 56px; border-radius: var(--r-xl); margin: 0 auto 10px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--mono); font-size: var(--fs-md); font-weight: 600;
}
@media (max-width: 760px) { .liferail { padding-top: 0; } .liferail-track, .liferail-dot { display: none; } }

/* Verdict legend dots (spec §9.2): glow shadow carries the verdict colour. */
.verdict-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.verdict-dot--allow  { background: var(--ok);     box-shadow: 0 0 8px rgba(21,128,61,.45); }
.verdict-dot--review { background: var(--amber);  box-shadow: 0 0 8px rgba(217,119,6,.45); }
.verdict-dot--block  { background: var(--danger); box-shadow: 0 0 8px rgba(220,38,38,.45); }
.pipe { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(180px,100%),1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--r-xl); overflow: hidden; background: #fff; }
.pipe-step { padding: 20px; border-right: 1px solid var(--line); position: relative; }
.pipe-step:last-child { border-right: 0; }
.pipe-step b { display: block; font-family: var(--mono); font-size: var(--fs-mono); color: var(--indigo); margin-bottom: 8px; }
.pipe-step h4 { font-size: var(--fs-sm); margin-bottom: 5px; }
.pipe-step p { font-size: var(--fs-xs); color: var(--ink-muted); }

.term--feed .term-feed-body { padding: 0; min-height: 0; height: 232px; overflow: hidden; }
.term-feed-track { animation: termFeed 26s linear infinite; will-change: transform; }
.term--feed:hover .term-feed-track,
.term--feed:focus-within .term-feed-track { animation-play-state: paused; }
.term-feed-row {
  display: grid; grid-template-columns: 62px 148px 1fr; gap: 12px; align-items: baseline;
  padding: 9px 18px; border-bottom: 1px dashed rgba(148,163,184,.16);
  font-family: var(--mono); font-size: var(--fs-mono); line-height: 1.6;
}
.term-feed-row .term-value { font-weight: 600; }
@keyframes termFeed { from { transform: translateY(0); } to { transform: translateY(-50%); } }
@media (max-width: 640px) {
  .term-feed-row { grid-template-columns: 54px 1fr; }
  .term-feed-row .term-command { grid-column: 1 / -1; padding-left: 66px; }
  .term--feed .term-feed-body { height: 300px; }
}
/* Nothing here is animation-dependent: freeze the track and show the set. */
@media (prefers-reduced-motion: reduce) {
  .term-feed-track { animation: none; }
  .term--feed .term-feed-body { height: auto; overflow: visible; }
}

/* page rule — the section divider used on /about (v5 N-9) */
.page-rule { height: 3px; border-radius: var(--r-pill); margin: 6px 0;
  background: linear-gradient(90deg, var(--indigo), var(--sky)); }

/* v5 N-16 — a diagram is a FIGURE, not prose: let it run wider than the
   reading column so the viewBox renders near 1:1 and its labels are legible.
   Capped so it never exceeds the viewport. */
.diagram--wide { width: 100%; }
@media (min-width: 1100px) {
  /* break the figure out of the reading column: the shell caps at --shell,
     the diagram may use up to 96vw. Negative margins keep it centred. */
  .diagram-bleed {
    width: min(96vw, 1600px);
    margin-left: calc(50% - min(48vw, 800px));
    margin-right: calc(50% - min(48vw, 800px));
  }
}


.card--art { padding: 0; overflow: hidden; }
.card--art .card-body { padding: 18px 22px 22px; }
.card--art .card-foot { margin-top: 16px; }

.dcard-img-wrap {
  position: relative; overflow: hidden;
  background: var(--surface-sunken);
  border-bottom: 1px solid var(--line);
}
.domain-visual-art {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; display: block;
}
/* The shade is what makes overlaid text legible on ANY art — without it the
   copy is only readable on the themes that happen to be dark. */
.domain-visual-shade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(8,12,28,.06) 0%, rgba(8,12,28,.22) 45%,
                              rgba(8,12,28,.72) 100%);
}
.domain-visual-mark {
  position: absolute; top: 12px; left: 14px;
  display: grid; place-items: center; width: 34px; height: 34px;
  border-radius: var(--r-md);
  background: rgba(255,255,255,.92); color: var(--indigo);
  font-family: var(--mono); font-size: 13px; font-weight: 700;
  letter-spacing: .02em; box-shadow: var(--sh-card);
}
.domain-visual-copy {
  position: absolute; left: 16px; right: 16px; bottom: 12px; color: #fff;
}
.domain-visual-copy span {
  display: block; font-family: var(--mono); font-size: var(--fs-micro);
  text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.82);
}
.domain-visual-copy strong {
  display: block; margin-top: 2px; font-size: var(--fs-lg);
  font-weight: 800; letter-spacing: -.02em; text-shadow: 0 1px 12px rgba(8,12,28,.5);
}
.domain-visual-copy em { font-style: normal; color: rgba(255,255,255,.72); font-weight: 600; }

/* Hover: the art drifts, the card lifts (.stagecard supplies the lift). */
.domain-visual-art { transition: transform .5s cubic-bezier(.22,.9,.3,1); }
.card--art:hover .domain-visual-art { transform: scale(1.055); }
@media (prefers-reduced-motion: reduce) {
  .domain-visual-art, .card--art:hover .domain-visual-art { transition: none; transform: none; }
}

.statstrip { display: flex; flex-wrap: wrap; gap: 26px; }
.statstrip .stat { display: flex; flex-direction: column; gap: 2px; }
.statstrip .stat b { font-size: clamp(22px, 2.4vw, 28px); font-weight: 800;
  letter-spacing: -.02em; color: var(--ink); }
.statstrip .stat span { font-family: var(--mono); font-size: var(--fs-micro);
  text-transform: uppercase; letter-spacing: .08em; color: var(--ink-soft); }

.netcard-h { display: flex; align-items: center; gap: 12px; }
.netcard-h h3 { margin: 0; font-size: var(--fs-md); }
.netcard-h .meta { margin: 2px 0 0; }
.netcard-mark {
  display: grid; place-items: center; flex: none; width: 40px; height: 40px;
  border-radius: var(--r-md); background: var(--indigo-50); color: var(--indigo);
  border: 1px solid var(--indigo-200);
  font-family: var(--mono); font-size: 14px; font-weight: 700;
}
.netcard-adj { font-size: var(--fs-xs); color: var(--ink-soft);
  padding-top: 10px; border-top: 1px dashed var(--line); }

.prop-hero {
  display: grid; gap: 32px; align-items: center;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
}
.prop-art { overflow: hidden; }
.prop-art .dcard-img-wrap { border-bottom: 0; }
@media (max-width: 900px) {
  .prop-hero { grid-template-columns: 1fr; gap: 24px; }
  .prop-art { max-width: 460px; }
}

/* Capability cells — numbered, on the surface ladder, so "what it does" has
   the same weight as the spec terminal beside it. */
.capgrid { display: grid; gap: 10px; }
.capcell {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 13px 16px; border-radius: var(--r-lg);
  background: var(--surface-alt); border: 1px solid var(--line);
  font-size: var(--fs-md); color: var(--ink-body);
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.capcell:hover { transform: translateX(3px); border-color: var(--indigo-300);
  background: var(--surface-panel); }
.capcell-n {
  flex: none; display: grid; place-items: center; min-width: 26px; height: 22px;
  border-radius: var(--r-sm); background: var(--surface-head); color: #fff;
  font-family: var(--mono); font-size: var(--fs-micro); font-weight: 700;
}
@media (prefers-reduced-motion: reduce) { .capcell:hover { transform: none; } }


.term--day {
  background: var(--surface-panel);
  border: 1px solid var(--line-heavy);
  box-shadow: var(--sh-card);
}
.term--day .term-bar {
  background: var(--surface-sunken);
  border-bottom: 1px solid var(--line-heavy);
}
.term--day .term-bar .path  { color: var(--ink-body); font-weight: 600; }
.term--day .term-bar .live  { color: #15803D; }
.term--day .term-body       { color: var(--ink-body); min-height: 0; padding: 14px 16px; }
/* the dark terminal fades its body edges into the black; on a light panel
   that reads as a smudge, so the masks are off here. */
.term--day .term-body::before,
.term--day .term-body::after { display: none; }

.term--day .term-kv      { border-bottom: 1px dashed var(--line-heavy); padding: 6px 0; }
.term--day .term-kv:last-child { border-bottom: 0; }
.term--day .term-kv .k   { color: var(--ink-body); }

/* AA-checked inks for a light ground — NOT the --term-* set. */
.term--day .term-value,
.term--day .term-kv .v--info    { color: #4338CA; }   /* 8.1:1  */
.term--day .term-ok,
.term--day .term-kv .v--ok      { color: #15803D; }   /* 4.9:1  */
.term--day .term-warn           { color: #B45309; }   /* 4.6:1  */
.term--day .term-err            { color: #B91C1C; }   /* 6.0:1  */
.term--day .term-command,
.term--day .term-kv .v--neutral { color: var(--ink-body); }
.term--day .term-comment,
.term--day .term-kv .v--empty   { color: var(--ink-soft); }
.term--day .term-prompt         { color: #4338CA; }
.term--day .term-log            { border-bottom-color: var(--line); }
.term--day .term-note           { color: var(--ink-soft); }

.term--day .term-bar .dot:nth-of-type(1) { background: #EF4444; }
.term--day .term-bar .dot:nth-of-type(2) { background: #F59E0B; }
.term--day .term-bar .dot:nth-of-type(3) { background: #22C55E; }

/* network-value terminals sit in a card grid, so they need a card's rhythm */
.netterm .term-body { min-height: 0; }
.netterm .term-kv .v { max-width: 62%; }


.about-fig {
  display: block;
  border-radius: var(--r-2xl);
  box-shadow: var(--sh-pop);
}
.about-fig--round { border-radius: 50%; }
/* The logo mark sits on the page directly — no card, no lift. */
.about-fig--plain { border-radius: 0; box-shadow: none; }


.flowcard {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-2xl);
  padding: 30px 26px 22px; box-shadow: var(--sh-card);
}

.itable-wrap { max-width: 100%; overflow-x: auto; }
.itable { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.itable thead th {
  background: var(--surface-head); color: var(--surface-head-ink);
  font-family: var(--mono); font-size: var(--fs-mono); font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase; text-align: left; padding: 10px 14px;
}
.itable thead th:first-child { border-radius: var(--r-sm) 0 0 0; }
.itable thead th:last-child  { border-radius: 0 var(--r-sm) 0 0; text-align: right; }
.itable tbody tr { background: var(--surface-row); }
.itable tbody tr:nth-child(even) { background: var(--surface-row-alt); }
.itable td { padding: 11px 14px; border-bottom: 1px solid var(--line-cool); vertical-align: middle; }
.itable tbody tr:last-child td { border-bottom: 0; }
.itable td:last-child { text-align: right; }
.itable .svc { display: flex; align-items: center; gap: 10px; font-weight: 600; color: var(--ink); }
.itable .svc i {
  width: 26px; height: 26px; border-radius: var(--r-xs); flex: none;
  display: grid; place-items: center; background: var(--indigo-50); color: var(--indigo);
}
.itable .svc i svg { width: 14px; height: 14px; }
.itable .role { color: var(--ink-muted); }
.itable .own { font-family: var(--mono); font-size: var(--fs-mono); color: var(--ink-faint); }

.ocards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
@media (max-width: 860px) { .ocards { grid-template-columns: 1fr; } }

.ocard-live {
  background: linear-gradient(160deg, #1E293B 0%, #141C2B 100%);
  border: 1px solid #2A3648; border-radius: var(--r-xl); padding: 20px 22px 16px;
  color: #fff; position: relative; overflow: hidden;
}
.ocard-live::after {
  content: ""; position: absolute; inset: auto -40px -70px auto; width: 220px; height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(56,189,248,.16), rgba(56,189,248,0) 70%);
}
.ocard-live > * { position: relative; z-index: 1; }
.oc-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.oc-name { font-size: var(--fs-lg); font-weight: 700; letter-spacing: -.01em; color: #fff; }
.oc-name span { color: #64748B; font-weight: 500; }
.oc-sub { font-family: var(--mono); font-size: var(--fs-mono); color: #94A3B8; margin-top: 3px; }
.oc-live {
  display: inline-flex; align-items: center; gap: 6px; flex: none;
  font-family: var(--mono); font-size: var(--fs-micro); font-weight: 600; letter-spacing: .08em;
  color: #4ADE80; background: rgba(74,222,128,.12); border: 1px solid rgba(74,222,128,.28);
  border-radius: var(--r-pill); padding: 4px 10px;
}
.oc-live i { width: 6px; height: 6px; border-radius: 50%; background: #4ADE80;
  animation: breathe 2.4s ease-in-out infinite; }
.oc-body { font-size: var(--fs-sm); color: #CBD5E1; margin-top: 12px; line-height: 1.55; }
.oc-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; margin-top: 14px;
  border-top: 1px solid #2A3648; padding-top: 12px;
}
.oc-stats b { display: block; font-size: var(--fs-md); font-weight: 700; color: #fff; line-height: 1.25; }
.oc-stats span { font-family: var(--mono); font-size: var(--fs-micro); color: #64748B; }
.oc-stats .up { color: #4ADE80; }

/* The traffic slot. Renders only when a property actually carries a series —
   there is no per-property traffic history in this database yet, and a chart
   drawn from a projection would be a fabricated statistic on a public page. */
.oc-chart { margin: 16px -4px 0; position: relative; }
.oc-chart svg { display: block; width: 100%; height: auto; }
.oc-axis { display: flex; justify-content: space-between;
  font-family: var(--mono); font-size: var(--fs-micro); color: #64748B; margin-top: 8px; }
/* The empty state. The frame is real — axis, gridlines, baseline — so the cell
   holds its final shape and the series can drop straight in. The note says so
   in words rather than leaving a viewer to wonder whether the chart is broken
   or the property has no visitors. */
.oc-chart--empty { position: relative; }
.oc-chart--empty .oc-chart-note {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-family: var(--mono); font-size: var(--fs-micro); letter-spacing: .06em;
  color: #475569; text-transform: uppercase; pointer-events: none;
}

.ocard-build {
  background: var(--bg); border: 1px dashed var(--indigo-300); border-radius: var(--r-xl);
  padding: 20px 22px 16px; position: relative; overflow: hidden;
}
.ocard-build::before {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(var(--indigo) 1px, transparent 1px);
  background-size: 22px 22px; opacity: .045;
}
.ocard-build > * { position: relative; z-index: 1; }
.ocard-build .oc-name { color: var(--ink); }
.ocard-build .oc-name span { color: var(--ink-faint); }
.ocard-build .oc-sub { color: var(--ink-faint); }
.oc-soon {
  display: inline-flex; align-items: center; gap: 6px; flex: none;
  font-family: var(--mono); font-size: var(--fs-micro); font-weight: 600; letter-spacing: .08em;
  color: var(--ink-amber); background: var(--amber-100); border: 1px solid var(--amber-200);
  border-radius: var(--r-pill); padding: 4px 10px;
}
.oc-syn { font-size: var(--fs-sm); color: var(--ink-muted); margin-top: 12px; line-height: 1.55; }
.oc-steps { display: flex; align-items: center; gap: 0; margin-top: 16px; }
.oc-step { flex: 1; text-align: center; position: relative; }
.oc-step i {
  display: block; width: 11px; height: 11px; border-radius: 50%; margin: 0 auto 7px;
  background: var(--bg); border: 2px solid var(--indigo-200);
}
.oc-step.done i { background: var(--indigo); border-color: var(--indigo); }
.oc-step.now i {
  background: #fff; border-color: var(--indigo);
  box-shadow: 0 0 0 4px rgba(67,56,202,.16); animation: seedPulse 2.2s ease-in-out infinite;
}
.oc-step::after {
  content: ""; position: absolute; top: 5px; left: 50%; width: 100%; height: 2px;
  background: var(--indigo-100);
}
.oc-step.done::after { background: var(--indigo-200); }
.oc-step:last-child::after { display: none; }
.oc-step b {
  font-family: var(--mono); font-size: var(--fs-micro); font-weight: 600;
  color: var(--ink-faint); letter-spacing: .04em;
}
.oc-step.done b, .oc-step.now b { color: var(--indigo); }
.oc-eta {
  display: flex; align-items: center; justify-content: space-between; margin-top: 16px;
  border-top: 1px solid var(--line-strong); padding-top: 11px;
  font-family: var(--mono); font-size: var(--fs-mono); color: var(--ink-faint);
}
.oc-eta b { color: var(--ink-strong); font-weight: 600; }

.circuit--steps { padding: 54px 48px; }
.circuit--steps > .circuit-scrim {
  background: linear-gradient(100deg, rgba(55,48,190,.95) 0%, rgba(55,48,190,.82) 20%,
    rgba(50,60,190,.52) 31%, rgba(40,80,180,.50) 42%, rgba(28,96,175,.47) 100%);
}
.circuit--steps > svg { opacity: .5; }
.cta-in { display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr);
  gap: 44px; align-items: center; }
.circuit--steps h2 { font-size: var(--fs-2xl); line-height: 1.15; }
.circuit--steps p { margin-top: 9px; font-size: var(--fs-sm); max-width: 40ch; }
.cta-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; position: relative; }
.cta-step { position: relative; padding: 0 10px; }
.cta-step-ico {
  width: 38px; height: 38px; border-radius: var(--r-sm);
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.26);
  display: grid; place-items: center; color: #fff; margin-bottom: 10px;
}
.cta-step-ico svg { width: 18px; height: 18px; }
.cta-step b { display: block; color: #fff; font-size: var(--fs-sm); font-weight: 600;
  text-shadow: 0 1px 8px rgba(10,18,60,.55); }
.cta-step span { display: block; color: rgba(255,255,255,.80); font-size: var(--fs-xs);
  margin-top: 4px; line-height: 1.45; text-shadow: 0 1px 8px rgba(10,18,60,.55); }
.cta-step-arr { position: absolute; top: 19px; right: -9px; color: rgba(255,255,255,.42); }
.cta-step-arr svg { width: 18px; height: 18px; display: block; }
@media (max-width: 900px) {
  .cta-in { grid-template-columns: 1fr; gap: 30px; }
  .cta-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 0; }
  .cta-step-arr { display: none; }
}

.lc-panel, .lc-dot, .lc-label, .lc-row, .lc-arrow { opacity: 0; }
.lc-on .lc-panel, .lc-on .lc-dot, .lc-on .lc-label,
.lc-on .lc-row, .lc-on .lc-arrow { animation-fill-mode: both; }
.lc-on .lc-panel { animation: lcIn 11s ease-out infinite; }
.lc-on .lc-arrow { animation: lcIn 11s ease-out infinite; }
.lc-on .lc-dot   { animation: lcDot 11s ease-out infinite; }
.lc-on .lc-label { animation: lcIn 11s ease-out infinite; }
.lc-on .lc-row   { animation: lcRow 11s ease-out infinite; }

.lc-s1 { animation-delay: .2s; }
.lc-s2 { animation-delay: 1.5s; }
.lc-s3 { animation-delay: 2.8s; }
.lc-s4 { animation-delay: 4.1s; }
.lc-on .lc-r1 { animation-delay: 5.0s; }
.lc-on .lc-r2 { animation-delay: 5.6s; }
.lc-on .lc-r3 { animation-delay: 6.2s; }
.lc-on .lc-r4 { animation-delay: 6.8s; }

.lc-panel, .lc-row { transform-box: fill-box; transform-origin: center; }

@keyframes lcIn  { 0% { opacity: 0; transform: translateY(9px); }
                   9%, 100% { opacity: 1; transform: translateY(0); } }
@keyframes lcDot { 0% { opacity: 0; } 9%, 100% { opacity: 1; } }
@keyframes lcRow { 0% { opacity: 0; transform: translateX(-7px); }
                   6%, 100% { opacity: 1; transform: translateX(0); } }

/* The live pip is the one ambient loop in the figure. */
.lc-pip { animation: lcPip 2.2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes lcPip { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

@media (prefers-reduced-motion: reduce) {
  .lc-panel, .lc-dot, .lc-label, .lc-row, .lc-arrow { opacity: 1 !important; }
  .lc-on .lc-panel, .lc-on .lc-dot, .lc-on .lc-label,
  .lc-on .lc-row, .lc-on .lc-arrow, .lc-pip { animation: none !important; }
}

.sw-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); counter-reset: none; }
.sw-step { display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px;
  border-radius: var(--r-lg); background: var(--surface-alt); border: 1px solid var(--line); }
.sw-step-n { flex: none; display: grid; place-items: center; min-width: 30px; height: 24px;
  border-radius: var(--r-sm); background: var(--surface-head); color: #fff;
  font-family: var(--mono); font-size: var(--fs-micro); font-weight: 700; }
.sw-step > div > b { display: block; font-size: var(--fs-md); color: var(--ink); }
.sw-step > div > span { display: block; margin-top: 3px; font-size: var(--fs-sm); color: var(--ink-muted); }

.sw-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 22px; }
.sw-filter-label { font-family: var(--mono); font-size: var(--fs-micro); text-transform: uppercase;
  letter-spacing: .08em; color: var(--ink-soft); margin-right: 2px; }
.sw-filter-label:not(:first-child) { margin-left: 12px; }
.sw-filter button.chip { cursor: pointer; font: inherit; font-size: var(--fs-xs); }
.sw-filter-count { margin-left: auto; font-family: var(--mono); font-size: var(--fs-micro); color: var(--ink-soft); }
.sw-filter-empty { font-size: var(--fs-sm); color: var(--ink-muted); padding: 24px 0; }

.sw-card { padding: 0; overflow: hidden; }
.sw-card-body { padding: 20px; }
.sw-card-facts { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 5px;
  font-size: var(--fs-xs); color: var(--ink-soft); }
.sw-card-facts li::before { content: "\2713"; color: var(--ok); margin-right: 7px; font-weight: 700; }

.sw-hero { display: grid; gap: 44px; align-items: start;
  grid-template-columns: minmax(0, 1fr) minmax(0, 360px); }
.sw-buy { position: sticky; top: 84px; }
@media (max-width: 900px) {
  .sw-hero { grid-template-columns: 1fr; gap: 28px; }
  .sw-buy { position: static; }
}
.sw-box { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); }
.sw-box li { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px;
  border-radius: var(--r-lg); background: var(--surface-alt); border: 1px solid var(--line);
  font-size: var(--fs-sm); color: var(--ink-body); }
.sw-box li::before { content: "\2713"; color: var(--ok); font-weight: 700; flex: none; }
