/* ═══════════════════════════════════════════════════════════════
   SHARED TOKENS · Atelier + Terminal
   Used by all 14 pages of Prashant Kashyap's portfolio.
   Theme switching via [data-theme="terminal"] on <html>.
   ═══════════════════════════════════════════════════════════════ */

/* DEFAULT — Atelier theme */
:root {
  /* Surfaces */
  --plastic-cream: #FAF7F0;
  --plastic-cream-deep: #F2EEE4;
  --plastic-charcoal: #1A1814;

  /* Text */
  --ink-mid: #4A4640;
  --ink-muted: #6F6A63;
  --ink-faint: #6E6B62;
  --ink-hairline: rgba(26, 24, 20, 0.10);
  --ink-rule: rgba(26, 24, 20, 0.06);

  /* Accent */
  --pixel-red: #E8513D;
  --pixel-red-soft: rgba(232, 81, 61, 0.06);
  /* Darker red for TEXT only — passes WCAG AA (>=4.5:1) on cream + cream-deep.
     --pixel-red stays bright for non-text accents (dots, borders, hover). */
  --pixel-red-ink: #BB4131;

  /* Fonts */
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Spacing (unchanged between themes) */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px;
  --s-5: 24px; --s-6: 32px; --s-7: 48px; --s-8: 64px;
  --s-9: 96px; --s-10: 128px; --s-11: 160px; --s-12: 192px;

  /* Scanline layer (invisible in Atelier) */
  --scanline-opacity: 0;
}

/* TERMINAL theme — triggered by [data-theme="terminal"] on <html> */
html[data-theme="terminal"] {
  /* Surfaces — deep phosphor-tube black */
  --plastic-cream: #0A0E0B;
  --plastic-cream-deep: #12181A;
  --plastic-charcoal: #C8E6D0;

  /* Text — phosphor green family */
  --ink-mid: #7FDBA8;
  --ink-muted: #5A9873;
  --ink-faint: #5A8A70;
  --ink-hairline: rgba(127, 219, 168, 0.15);
  --ink-rule: rgba(127, 219, 168, 0.08);

  /* Accent — terminal red */
  --pixel-red: #FF5F5F;
  --pixel-red-soft: rgba(255, 95, 95, 0.1);
  /* Terminal text-red stays bright — high contrast on the dark phosphor bg. */
  --pixel-red-ink: #FF5F5F;

  /* Fonts — mono-first */
  --font-display: 'JetBrains Mono', 'Courier New', monospace;
  --font-body: 'JetBrains Mono', 'Courier New', monospace;
  --font-mono: 'JetBrains Mono', 'Courier New', monospace;

  /* CRT scanline */
  --scanline-opacity: 0.03;
}

/* THEME TRANSITION — smooth swap */
html {
  transition: background-color 0.4s ease;
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
}

/* Large / 4K monitors: type is fixed-px, so on very wide displays the reading
   text shrinks and gets hard to read. Scale the reading type up. Container
   widths are intentionally per-page, so they're left as-is.
   NOTE: selectors are prefixed with `html ` to raise specificity above each
   page's inline `.prose p { font-size: 18px }` rule, which loads after this
   file and would otherwise win at equal specificity (media queries add none). */
@media (min-width: 1920px) {
  html .prose p, html .tldr__body, html .decision__body, html .change__body { font-size: 19px; line-height: 1.72; }
  html .prose p.lead { font-size: 22px; }
}
@media (min-width: 2560px) {
  html .prose p, html .tldr__body, html .decision__body, html .change__body { font-size: 21px; line-height: 1.75; }
  html .prose p.lead { font-size: 24px; }
}

/* The body has overflow-x:hidden on each page, which makes the BODY the
   scroll container (not html). So the scrollbar-gutter must be reserved on
   the body too, or the scrollbar appearing/disappearing between pages of
   different heights shifts the centered layout (nav jitter). */
body {
  scrollbar-gutter: stable;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

html[data-theme="terminal"] body,
html:not([data-theme="terminal"]) body {
  transition: background-color 0.4s ease, color 0.4s ease;
}

/* CRT SCANLINE OVERLAY — only visible in Terminal theme */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: repeating-linear-gradient(
    0deg,
    rgba(0, 0, 0, var(--scanline-opacity)) 0px,
    rgba(0, 0, 0, var(--scanline-opacity)) 1px,
    transparent 1px,
    transparent 3px
  );
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: multiply;
  opacity: 1;
  transition: opacity 0.4s ease;
}

/* Terminal theme — additional aesthetic tweaks */
html[data-theme="terminal"] body {
  text-shadow: 0 0 6px rgba(127, 219, 168, 0.15);
}

/* Terminal theme — accent text glow */
html[data-theme="terminal"] [class*="breadcrumb-status"],
html[data-theme="terminal"] [class*="status--active"]::before {
  text-shadow: 0 0 12px rgba(255, 95, 95, 0.6);
}

/* Terminal theme — dashed borders get slightly warmer */
html[data-theme="terminal"] .image-slot__frame,
html[data-theme="terminal"] .photo-slot__frame,
html[data-theme="terminal"] .before-after__frame,
html[data-theme="terminal"] .draft-wrap {
  border-color: rgba(127, 219, 168, 0.25);
}

html[data-theme="terminal"] .image-slot__frame::before,
html[data-theme="terminal"] .photo-slot__frame::before,
html[data-theme="terminal"] .photo-slot__frame::after {
  background-image: linear-gradient(45deg, rgba(127, 219, 168, 0.15) 25%, transparent 25%, transparent 75%, rgba(127, 219, 168, 0.15) 75%, rgba(127, 219, 168, 0.15)),
                    linear-gradient(45deg, rgba(127, 219, 168, 0.15) 25%, transparent 25%, transparent 75%, rgba(127, 219, 168, 0.15) 75%, rgba(127, 219, 168, 0.15));
}

/* Terminal theme — nav backdrop stays dark */
html[data-theme="terminal"] .nav {
  background: rgba(10, 14, 11, 0.85);
}

/* Terminal theme — dark CTAs invert (since they were already dark) */
html[data-theme="terminal"] .deep-cta {
  background: var(--plastic-cream-deep);
  color: var(--ink-mid);
  border: 1px solid var(--ink-hairline);
}
html[data-theme="terminal"] .deep-cta__title,
html[data-theme="terminal"] .deep-cta__arrow {
  color: var(--plastic-charcoal);
}
html[data-theme="terminal"] .deep-cta__label,
html[data-theme="terminal"] .deep-cta__subtitle {
  color: var(--ink-muted);
}

/* Terminal theme — header action buttons adjust */
html[data-theme="terminal"] .header-btn--primary {
  background: var(--pixel-red);
  color: var(--plastic-cream);
  border-color: var(--pixel-red);
}

/* Terminal theme — pulsing dots glow */
html[data-theme="terminal"] .meta-cell__value--status::before,
html[data-theme="terminal"] .status-label__dot--active {
  box-shadow: 0 0 8px rgba(255, 95, 95, 0.6);
}

/* Respect user preference for reduced motion */
@media (prefers-reduced-motion: reduce) {
  html { transition: none; }
  body, html[data-theme="terminal"] body { transition: none; }
  body::before { display: none; }
}

/* ═══════════════════════════════════════════════════════════════
   THEME TOGGLE BUTTON — blinking cursor on locked state
   ═══════════════════════════════════════════════════════════════ */
.theme-toggle__blink {
  color: var(--pixel-red-ink);
  display: inline-block;
  animation: terminal-blink 1.1s step-end infinite;
  font-family: var(--font-mono);
  line-height: 1;
  margin-right: 2px;
}

@keyframes terminal-blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

.theme-toggle--locked:hover .theme-toggle__blink {
  color: var(--pixel-red-ink);
}

@media (prefers-reduced-motion: reduce) {
  .theme-toggle__blink { animation: none; opacity: 1; }
}

/* ═══════════════════════════════════════════════════════════════
   LOAD ANIMATION STAGE PALETTES (Atelier + Terminal)
   ═══════════════════════════════════════════════════════════════ */

:root {
  /* Atelier load journey — warm-earth gradient to plastic-cream */
  --a-stage-0-bg: #1A1410;
  --a-stage-0-dot: #E8513D;
  --a-stage-1-bg: #2D1B13;
  --a-stage-1-dot: #C95A3C;
  --a-stage-2-bg: #5A3A28;
  --a-stage-2-dot: #E8513D;
  --a-stage-3-bg: #FAF7F0;
  --a-stage-3-dot: #E8513D;

  /* Terminal load journey — phosphor + warm red */
  --t-stage-0-bg: #0A0E0B;
  --t-stage-0-dot: #7FDBA8;
  --t-stage-1-bg: #0F1A14;
  --t-stage-1-dot: #5A9873;
  --t-stage-2-bg: #1A2B22;
  --t-stage-2-dot: #7FDBA8;
  --t-stage-3-bg: #0A0E0B;
  --t-stage-3-dot: #FF5F5F;
}

/* ═══════════════════════════════════════════════════════════════
   LOAD OVERLAY
   ═══════════════════════════════════════════════════════════════ */

.load-overlay {
  position: fixed;
  inset: 0;
  background: var(--a-stage-0-bg);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: background-color 220ms ease-out, opacity 600ms cubic-bezier(0.65, 0, 0.35, 1);
}

.load-overlay[data-palette="atelier"][data-stage="0"] { background: var(--a-stage-0-bg); }
.load-overlay[data-palette="atelier"][data-stage="1"] { background: var(--a-stage-1-bg); }
.load-overlay[data-palette="atelier"][data-stage="2"] { background: var(--a-stage-2-bg); }
.load-overlay[data-palette="atelier"][data-stage="3"] { background: var(--a-stage-3-bg); }
.load-overlay[data-palette="atelier"][data-stage="reveal"] {
  background: var(--a-stage-3-bg);
  transition: background-color 700ms cubic-bezier(0.65, 0, 0.35, 1), opacity 600ms cubic-bezier(0.65, 0, 0.35, 1);
}

.load-overlay[data-palette="terminal"][data-stage="0"] { background: var(--t-stage-0-bg); }
.load-overlay[data-palette="terminal"][data-stage="1"] { background: var(--t-stage-1-bg); }
.load-overlay[data-palette="terminal"][data-stage="2"] { background: var(--t-stage-2-bg); }
.load-overlay[data-palette="terminal"][data-stage="3"] { background: var(--t-stage-3-bg); }
.load-overlay[data-palette="terminal"][data-stage="reveal"] {
  background: var(--t-stage-0-bg);
  transition: background-color 700ms cubic-bezier(0.65, 0, 0.35, 1), opacity 600ms cubic-bezier(0.65, 0, 0.35, 1);
}

.load-overlay.hidden { opacity: 0; pointer-events: none; }

.load-overlay__vignette {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 40%, rgba(0, 0, 0, 0.35) 100%);
  opacity: 0; transition: opacity 400ms ease-out; z-index: 1;
}
.load-overlay.bouncing .load-overlay__vignette { opacity: 1; }

.load-stage {
  position: relative; z-index: 2;
  display: inline-flex; align-items: baseline;
  transform-origin: 0 100%;
  will-change: transform;
}

.load-name {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 500;
  font-size: clamp(40px, 7vw, 96px);
  letter-spacing: -0.02em;
  color: #FAF7F0;
  line-height: 1;
  white-space: nowrap;
  display: inline-flex; align-items: baseline;
  position: relative;
}

.load-overlay[data-palette="terminal"] .load-name {
  font-family: 'JetBrains Mono', 'Courier New', monospace;
  font-weight: 500;
}

.load-overlay[data-palette="atelier"][data-stage="3"] .load-name { color: #1A1814; }
.load-overlay[data-palette="atelier"][data-stage="reveal"] .load-name { color: #1A1814; }
.load-overlay[data-palette="terminal"] .load-name { color: #C8E6D0; }

.load-letter {
  display: inline-block;
  opacity: 0;
  will-change: opacity;
  transition: opacity 80ms ease-out;
}
.load-letter.visible { opacity: 1; }
.load-space { display: inline-block; width: 0.28em; }

.load-dot-wrap {
  position: absolute; left: 0; bottom: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}

.load-dot {
  position: absolute;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--a-stage-0-dot);
  left: 50%; top: -40px;
  transform: translateX(-50%);
  will-change: transform, top, left, background-color, border-radius, width, height, opacity;
  z-index: 2;
}

.load-dot.cursor-blink { animation: cursor-blink 0.85s step-end infinite; }
@keyframes cursor-blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

.load-dot-shadow {
  position: absolute;
  width: 22px; height: 5px;
  background: rgba(0, 0, 0, 0.35);
  border-radius: 50%;
  filter: blur(3px);
  left: 50%; top: 50%;
  transform: translate(-50%, 0);
  opacity: 0;
  will-change: transform, opacity, width;
  z-index: 1;
}

.load-dot.breathing { animation: period-breath 280ms cubic-bezier(0.4, 0, 0.6, 1) 1; }
@keyframes period-breath {
  0% { scale: 1 1; }
  45% { scale: 1.3 1.3; }
  100% { scale: 1 1; }
}

@media (prefers-reduced-motion: reduce) {
  .load-overlay { display: none !important; }
}

/* ═══════════════════════════════════════════════════════════════
   HERO CANVAS CONTAINER (Atelier dot field / Terminal threads)
   ═══════════════════════════════════════════════════════════════ */

.hero__canvas-container {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

/* ═══════════════════════════════════════════════════════════════
   TERMINAL THEME — hero title typography override
   JetBrains Mono is wider than Fraunces, so reduce size significantly
   to maintain the 2-line wrap and overall visual balance
   ═══════════════════════════════════════════════════════════════ */
html[data-theme="terminal"] .hero__title {
  font-size: clamp(36px, 5.5vw, 72px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  font-weight: 500;
}
html[data-theme="terminal"] .hero__title .em {
  font-style: normal;
  color: var(--terminal-red);
}

/* Case study + page heading overrides for Terminal to prevent wrapping */
html[data-theme="terminal"] .case-hero__title,
html[data-theme="terminal"] .case-study__title,
html[data-theme="terminal"] .page__title,
html[data-theme="terminal"] .also-hero__title {
  font-size: clamp(28px, 4.2vw, 56px);
  line-height: 1.15;
  letter-spacing: -0.01em;
  font-weight: 500;
}

html[data-theme="terminal"] h1,
html[data-theme="terminal"] h2 {
  letter-spacing: -0.005em;
}

/* ═══════════════════════════════════════════════════════════════
   NAV THEME BUTTON — consistent styling across all pages
   ═══════════════════════════════════════════════════════════════ */
.nav__theme-btn {
  background: transparent;
  border: 1px solid var(--ink-hairline);
  color: var(--ink-mid);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 6px 12px;
  cursor: pointer;
  border-radius: 2px;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  line-height: 1;
}
.nav__theme-btn:hover {
  border-color: var(--pixel-red);
  color: var(--pixel-red-ink);
}
.nav__theme-blink {
  color: var(--pixel-red-ink);
  animation: nav-blink 1s ease-in-out infinite !important;
  font-family: var(--font-mono);
  line-height: 1;
  font-size: 12px;
  display: inline-block;
  font-weight: 600;
}
@keyframes nav-blink {
  0%, 45% { opacity: 1; }
  55%, 95% { opacity: 0.15; }
  100% { opacity: 1; }
}

html[data-theme="terminal"] .nav__theme-btn {
  border-color: rgba(127, 219, 168, 0.3);
  color: var(--terminal-fg);
}
html[data-theme="terminal"] .nav__theme-btn:hover {
  border-color: var(--terminal-red);
  color: var(--terminal-red);
}
html[data-theme="terminal"] .nav__theme-blink {
  color: var(--terminal-red);
}

/* ═══════════════════════════════════════════════════════════════
   REMOVE TEMPLATE NOTES from final build
   ═══════════════════════════════════════════════════════════════ */
.template-note { display: none !important; }

/* ═══════════════════════════════════════════════════════════════
   NAV WORDMARK FONT — Fraunces in Atelier, Mono in Terminal
   Matches the load animation name so tuck visually merges
   ═══════════════════════════════════════════════════════════════ */
.nav__wordmark {
  font-family: 'Fraunces', Georgia, serif !important;
  font-weight: 500 !important;
  font-size: 16px !important;
  letter-spacing: -0.01em !important;
  font-variation-settings: "opsz" 48;
}
html[data-theme="terminal"] .nav__wordmark {
  font-family: 'JetBrains Mono', 'Courier New', monospace !important;
  font-weight: 500 !important;
  letter-spacing: -0.005em !important;
}

/* Some pages wrap nav links in <ul><li>, others use bare <a>. The <li>
   flex items center differently than bare <a>, shifting link text ~3px
   vertically between page types (nav jitter). This makes every <li> a
   transparent flex passthrough so links align identically everywhere. */
.nav__links li {
  display: flex;
  align-items: center;
}

/* ═══════════════════════════════════════════════════════════════
   ACCESSIBILITY — skip-to-content link + visible keyboard focus
   ═══════════════════════════════════════════════════════════════ */
.skip-link {
  position: absolute;
  left: 8px;
  top: -48px;
  z-index: 1000;
  background: var(--plastic-charcoal);
  color: var(--plastic-cream);
  padding: 10px 16px;
  border-radius: 2px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.05em;
  text-decoration: none;
  transition: top 0.15s ease;
}
.skip-link:focus {
  top: 8px;
}
/* Visible focus ring for keyboard users only (mouse clicks stay clean) */
a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible,
input:focus-visible,
[href]:focus-visible {
  outline: 2px solid var(--pixel-red);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ═══════════════════════════════════════════════════════════════
   TOUCH TARGETS — grow nav tap area to >=44px WITHOUT changing the
   rendered nav height. A transparent absolute ::after overlay expands
   the hit region; it is out of flow, so link/nav box sizes are untouched.
   ═══════════════════════════════════════════════════════════════ */
.nav__link,
.nav__back,
.nav__theme-btn,
.nav__wordmark {
  position: relative;
}
.nav__link::after,
.nav__back::after,
.nav__theme-btn::after,
.nav__wordmark::after {
  content: '';
  position: absolute;
  top: 50%;
  left: -8px;
  right: -8px;
  transform: translateY(-50%);
  height: 44px;
}

/* ═══════════════════════════════════════════════════════════════
   MOBILE NAV — links collapse into a hamburger below 720px.
   The theme button stays outside the panel, always visible.

   Selectors are prefixed with .nav to outrank the per-page inline
   <style> blocks, which load after this file. Colours use the base
   tokens, so Terminal adapts with no extra rules.
   ═══════════════════════════════════════════════════════════════ */

.nav .nav__wordmark { white-space: nowrap; }

.nav__actions {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}

/* Desktop: .nav__inner is justify-content:space-between, and .nav__actions
   adds a third child - without this the links drift to the middle instead of
   staying grouped at the right with the theme button, as they were when the
   button lived inside .nav__links. */
@media (min-width: 721px) {
  .nav .nav__links { margin-left: auto; }
  .nav .nav__actions { margin-left: var(--s-5); }
}

/* Hidden on desktop — links stay inline exactly as before. */
.nav .nav__toggle { display: none; }

@media (max-width: 720px) {
  .nav .nav__toggle {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    margin-right: -12px;
    padding: 0;
    background: transparent;
    border: 0;
    cursor: pointer;
    order: 2;
  }
  .nav .nav__toggle { gap: 6px; }
  .nav .nav__toggle span {
    display: block;
    width: 22px;
    height: 2px;
    margin: 0 auto;
    background: var(--plastic-charcoal);
    transition: transform 0.25s ease;
  }
  .nav .nav__toggle[aria-expanded="true"] span:first-child {
    transform: translateY(4px) rotate(45deg);
  }
  .nav .nav__toggle[aria-expanded="true"] span:last-child {
    transform: translateY(-4px) rotate(-45deg);
  }

  /* Panel drops from the bottom edge of the fixed nav. */
  .nav .nav__links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: var(--s-2) var(--s-5) var(--s-4);
    background: var(--plastic-cream);
    border-bottom: 1px solid var(--ink-hairline);
  }
  .nav .nav__links[data-open="true"] { display: flex; }
  .nav .nav__links li { display: block; width: 100%; }

  .nav .nav__link,
  .nav .nav__back {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 44px;
    font-size: 12px;
  }
  /* Rows are already 44px tall here, so the hit-area overlay would
     only overlap its neighbours. */
  .nav .nav__link::after,
  .nav .nav__back::after { content: none; }

  /* Icon-only theme button, sized to read at the same tier as body text
     rather than as a 10px chip. */
  .nav .nav__theme-label { display: none; }
  .nav .nav__theme-btn { padding: 9px 13px; }
  .nav .nav__theme-blink { font-size: 15px; }


  /* Align the nav gutter with .container, which drops to --s-5 here.
     Most pages already do this inline; index.html kept --s-8 and sat
     40px further in than its own hero text. */
  .nav .nav__inner {
    padding-left: var(--s-5);
    padding-right: var(--s-5);
  }
}

/* ═══════════════════════════════════════════════════════════════
   CASE STUDY DIAGRAMS
   Shared figure and diagram components used by the case studies.
   .figure     wraps a diagram with its caption underneath, matching
               the .image-slot pattern so captions sit outside frames.
   .diagram    the recessed frame every diagram sits in.
   .ia-*       before/after information-architecture flows.
   .arch-*     surface maps grouped by persona.

   Value ladder, quietest to loudest: transparent node (planned) ->
   cream node with solid border (in build) -> #B23A28 fill (shipped)
   -> charcoal fill (the layer spanning everything). Cream on
   --pixel-red is only 3.46:1, which is why shipped uses #B23A28.
   ═══════════════════════════════════════════════════════════════ */

.figure { margin: var(--s-8) 0; }
.figure__caption { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em; color: var(--ink-mid); margin-top: var(--s-3); line-height: 1.6; text-wrap: balance; }
.figure__caption .number { color: var(--pixel-red-ink); font-weight: 500; }

/* Numbered framework list - a sequence of questions or steps that would
   otherwise be a run-on sentence. */
.qlist { margin: var(--s-6) 0; border-top: 1px solid var(--ink-hairline); }
.qlist__row { display: grid; grid-template-columns: 32px 1fr 1fr; gap: var(--s-4); align-items: baseline; padding: var(--s-3) 0; border-bottom: 1px solid var(--ink-hairline); }
.qlist__num { font-family: var(--font-mono); font-size: 11px; color: var(--ink-faint); }
.qlist__q { font-family: var(--font-body); font-size: 15px; font-weight: 500; color: var(--plastic-charcoal); }
.qlist__a { font-family: var(--font-mono); font-size: 12px; color: var(--ink-mid); }
@media (max-width: 720px) { .qlist__row { grid-template-columns: 28px 1fr; } .qlist__a { grid-column: 2; } }

.diagram { border: 1px solid var(--ink-hairline); border-radius: 3px; padding: var(--s-7) var(--s-6); background: var(--plastic-cream-deep); }

.ia-band { margin-bottom: var(--s-6); }
.ia-band:last-child { margin-bottom: 0; }
.ia-band__label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em; color: var(--ink-mid); margin-bottom: var(--s-3); }
.ia-band__label b { color: var(--plastic-charcoal); font-weight: 500; }
.ia-row { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: stretch; }
.ia-chip { flex: 1 1 0; min-width: 88px; padding: var(--s-3) var(--s-2); border: 1px dashed rgba(26,24,20,0.22); border-radius: 2px; background: transparent; font-family: var(--font-mono); font-size: 12px; color: var(--ink-muted); text-align: center; }
.ia-step { flex: 1 1 0; min-width: 132px; padding: var(--s-4); border: 1px solid rgba(26,24,20,0.28); border-radius: 2px; background: var(--plastic-cream); text-align: center; }
.ia-step__name { font-family: var(--font-display); font-weight: 500; font-size: 16px; color: var(--plastic-charcoal); font-variation-settings: "opsz" 24; }
.ia-step__note { font-family: var(--font-mono); font-size: 11px; color: var(--ink-mid); margin-top: 4px; }
.ia-step--shipped { background: #B23A28; border-color: #B23A28; }
.ia-step--shipped .ia-step__name { color: var(--plastic-cream); }
.ia-step--shipped .ia-step__note { color: rgba(250,247,240,0.9); }
.ia-arrow { align-self: center; font-family: var(--font-mono); font-size: 14px; color: var(--ink-mid); }
.ia-aside { font-family: var(--font-mono); font-size: 11px; color: var(--ink-muted); margin-top: var(--s-3); line-height: 1.6; }

.arch__group { margin-bottom: var(--s-5); }
.arch__group:last-of-type { margin-bottom: var(--s-6); }
.arch__group-label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em; color: var(--ink-mid); margin-bottom: var(--s-3); padding-left: var(--s-3); border-left: 2px solid var(--plastic-charcoal); }
.arch__group-label b { color: var(--plastic-charcoal); font-weight: 500; }
.arch__row { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-2); }
.arch__row--pair { grid-template-columns: repeat(2, 1fr); }
.arch__node { padding: var(--s-4) var(--s-3); border: 1px solid var(--ink-hairline); border-radius: 2px; background: transparent; text-align: center; }
.arch__node-name { font-family: var(--font-display); font-weight: 500; font-size: 16px; line-height: 1.25; color: var(--ink-mid); font-variation-settings: "opsz" 24; }
.arch__node-status { font-family: var(--font-mono); font-size: 11px; color: var(--ink-muted); margin-top: 6px; }
.arch__node--build { background: var(--plastic-cream); border-color: rgba(26,24,20,0.28); }
.arch__node--build .arch__node-name { color: var(--plastic-charcoal); }
.arch__node--build .arch__node-status { color: var(--ink-mid); }
.arch__node--shipped { background: #B23A28; border-color: #B23A28; }
.arch__node--shipped .arch__node-name { color: var(--plastic-cream); }
.arch__node--shipped .arch__node-status { color: rgba(250,247,240,0.9); }
.arch__agentic { padding: var(--s-6) var(--s-5); border-radius: 3px; background: var(--plastic-charcoal); text-align: center; }
.arch__agentic-label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em; color: rgba(250,247,240,0.78); margin-bottom: 8px; }
.arch__agentic-name { font-family: var(--font-display); font-weight: 500; font-size: 22px; color: var(--plastic-cream); font-variation-settings: "opsz" 32; }
.arch__agentic-desc { font-family: var(--font-body); font-size: 13px; color: rgba(250,247,240,0.85); line-height: 1.5; margin-top: 8px; }
@media (max-width: 720px) { .ia-arrow { display: none; } .ia-step { min-width: 100%; } .diagram { padding: var(--s-5) var(--s-4); } .arch__row, .arch__row--pair { grid-template-columns: 1fr; } }
