/* Layout: help-centre shell. Series nav on the left, one reading column, screenshots break out wider than the text. */
:root {
  --bg: #F6F5FA;
  --surface: #FFFFFF;
  --slab: #EEECF4;
  --fg: #0B0A12;
  --muted: #6A6582;
  --line: #DEDBE8;
  --av: #0E8CA8;          /* Resolved: the AV product hue */
  --process: #6E2FD9;     /* Process */
  --intake: #C4006F;      /* Intake */
  --apex: #1FB6D6;
  --av-soft: #E3F5F9;
  --process-soft: #EFE8FC;
  --warn: #8A4B00;
  --warn-soft: #FFF3DF;
  --shadow: 0 1px 2px rgba(11,10,18,.06), 0 8px 24px rgba(11,10,18,.07);

  --f-display: "Space Grotesk", "Segoe UI", system-ui, sans-serif;
  --f-body: "IBM Plex Sans", "Segoe UI", system-ui, sans-serif;
  --f-mono: "Space Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --measure: 42rem;
  --wide: 60rem;
}

* { box-sizing: border-box; }
body {
  background: var(--bg); color: var(--fg);
  font-family: var(--f-body); font-size: 1rem; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--av); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--av); outline-offset: 3px; border-radius: 4px; }

/* Top bar */
.top {
  border-bottom: 1px solid var(--line); background: var(--surface);
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.top-in { max-width: 82rem; margin: 0 auto; display: flex; align-items: center; gap: 1.25rem; padding-block: .9rem; flex-wrap: wrap; }
.top img { height: 26px; width: auto; }
.top .section-name { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding-left: 1.25rem; border-left: 1px solid var(--line); }
.draft {
  margin-left: auto; font-family: var(--f-mono); font-size: .72rem; letter-spacing: .04em;
  color: var(--warn); background: var(--warn-soft); padding: .3rem .6rem; border-radius: 4px;
}

/* Shell */
.shell {
  max-width: 82rem; margin: 0 auto; display: grid; grid-template-columns: 15rem minmax(0, 1fr); gap: 3rem;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-block: 2.5rem 5rem;
}
@media (max-width: 960px) { .shell { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; } }

/* Series nav */
.series { font-size: .9rem; }
.series h2 { font-family: var(--f-mono); font-size: .72rem; font-weight: 400; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0 0 .6rem; }
.series ol { list-style: none; margin: 0 0 1.8rem; padding: 0; display: grid; gap: 2px; }
.series a { display: grid; grid-template-columns: 1.6rem 1fr; gap: .4rem; padding: .45rem .6rem; border-radius: 6px; color: var(--fg); text-decoration: none; line-height: 1.35; }
.series a:hover { background: var(--slab); }
.series a .g { font-family: var(--f-mono); font-size: .75rem; color: var(--muted); padding-top: .1rem; }
.series a[aria-current="page"] { background: var(--av-soft); color: var(--fg); font-weight: 600; }
.series a[aria-current="page"] .g { color: var(--av); }
.series .lvl { display: block; font-weight: 400; font-size: .78rem; color: var(--muted); }
@media (min-width: 961px) { .series-in { position: sticky; top: 1.5rem; } }
.series summary { display: none; }
@media (max-width: 960px) {
  .series ol { grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)); }
  .series details { border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
  .series summary {
    display: flex; justify-content: space-between; align-items: center; gap: 1rem; cursor: pointer; list-style: none;
    padding: .75rem 1rem; font-family: var(--f-mono); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
  }
  .series summary::-webkit-details-marker { display: none; }
  .series summary::after { content: "+"; font-size: 1.1rem; color: var(--av); }
  .series details[open] summary::after { content: "2"; }
  .series summary b { color: var(--fg); font-weight: 700; }
  .series .series-body { padding: .25rem 1rem .5rem; }
}

/* Article */
article { min-width: 0; }
.col { max-width: var(--measure); }
.crumbs { font-family: var(--f-mono); font-size: .75rem; color: var(--muted); margin: 0 0 1rem; }
.crumbs a { color: var(--muted); }
h1, h2, h3 { font-family: var(--f-display); font-weight: 600; letter-spacing: -.02em; text-wrap: balance; line-height: 1.15; }
h1 { font-size: clamp(2rem, 4.2vw, 2.9rem); margin: 0 0 1rem; }
h1 .ai, .brand .ai { color: var(--av); }
.lede { font-size: 1.15rem; color: var(--fg); margin: 0 0 1.5rem; }
.meta { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 2rem; padding: 0; list-style: none; }
.meta li { font-family: var(--f-mono); font-size: .75rem; padding: .3rem .65rem; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: var(--surface); }
.meta li.level { color: var(--process); border-color: color-mix(in srgb, var(--process) 40%, var(--line)); background: var(--process-soft); }

.need { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 1.1rem 1.3rem; margin: 0 0 2rem; }
.need h2 { font-size: 1rem; margin: 0 0 .5rem; }
.need ul { margin: 0; padding-left: 1.2rem; }
.need li + li { margin-top: .25rem; }

.toc { display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: .75rem; margin: 0 0 3rem; }
.toc a { display: block; padding: 1rem 1.1rem; border-radius: 10px; background: var(--slab); color: var(--fg); text-decoration: none; }
.toc a:hover { background: var(--av-soft); }
.toc .k { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--av); display: block; margin-bottom: .2rem; }
.toc .t { font-family: var(--f-display); font-weight: 600; font-size: 1.1rem; }
.toc .d { display: block; color: var(--muted); font-size: .88rem; margin-top: .2rem; }

/* Parts */
.part { margin-top: 3.5rem; scroll-margin-top: 1.5rem; }
.part-head { display: flex; align-items: baseline; gap: .9rem; border-top: 2px solid var(--fg); padding-top: 1rem; margin-bottom: 1.25rem; }
.part-head .k { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; color: var(--av); white-space: nowrap; }
.part-head h2 { font-size: 1.9rem; margin: 0; }

/* Video slot */
.video {
  max-width: var(--wide); aspect-ratio: 16 / 9; border-radius: 12px; margin: 0 0 2rem;
  background:
    radial-gradient(120% 90% at 85% 10%, color-mix(in srgb, var(--av) 28%, transparent), transparent 60%),
    radial-gradient(90% 80% at 10% 100%, color-mix(in srgb, var(--process) 26%, transparent), transparent 60%),
    #0B0A12;
  color: #EFEDF6; display: grid; place-items: center; position: relative; overflow: hidden;
}
.video .play { width: 4.2rem; height: 4.2rem; border-radius: 50%; background: rgba(239,237,246,.12); border: 1px solid rgba(239,237,246,.35); display: grid; place-items: center; }
.video .play::after { content: ""; border-left: 18px solid #EFEDF6; border-top: 11px solid transparent; border-bottom: 11px solid transparent; margin-left: 5px; }
.video .cap { position: absolute; left: 1.2rem; bottom: 1rem; right: 1.2rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-family: var(--f-mono); font-size: .78rem; }
.video .cap b { font-family: var(--f-display); font-size: 1.05rem; font-weight: 600; display: block; }
.video .ph { color: #9BF0FA; }

/* Concept panels (Part 1) */
.compare { display: grid; grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr)); gap: 1rem; max-width: var(--wide); margin: 1.5rem 0 2rem; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 1.3rem 1.4rem; min-width: 0; }
.panel h3 { margin: 0 0 .2rem; font-size: 1.25rem; }
.panel .sub { color: var(--muted); margin: 0 0 1rem; font-size: .92rem; }
.panel.accent { border-color: color-mix(in srgb, var(--av) 50%, var(--line)); }
dl.rows { margin: 0; display: grid; gap: .8rem; }
dl.rows div { display: grid; gap: .1rem; }
dl.rows dt { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
dl.rows dd { margin: 0; }

.trade { max-width: var(--wide); display: grid; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; margin: 1rem 0 2rem; }
.trade div { background: var(--surface); padding: 1rem 1.1rem; }
.trade b { font-family: var(--f-display); font-weight: 600; display: block; margin-bottom: .2rem; }

.note { max-width: var(--measure); border-radius: 10px; padding: .95rem 1.15rem; margin: 1.25rem 0; display: grid; grid-template-columns: auto 1fr; gap: .8rem; align-items: start; }
.note .tag { font-family: var(--f-mono); font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: .15rem .45rem; border-radius: 4px; margin-top: .2rem; }
.note.warn { background: var(--warn-soft); }
.note.warn .tag { background: var(--warn); color: var(--warn-soft); }
.note.info { background: var(--av-soft); }
.note.info .tag { background: var(--av); color: var(--surface); }
.note p { margin: 0; }

/* Stages and steps */
.stage { margin-top: 2.5rem; }
.stage > h3 { font-size: 1.35rem; margin: 0 0 .3rem; }
.stage > h3 + .steps, .stage > h3 + .summary { margin-top: 1rem; }
.stage > .intro { color: var(--muted); margin: 0 0 1.25rem; max-width: var(--measure); }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: step var(--start, 0); display: grid; gap: 2.25rem; }
.step { counter-increment: step; display: grid; grid-template-columns: 2.6rem minmax(0, 1fr); gap: 0 1rem; }
.step::before {
  content: counter(step); font-family: var(--f-mono); font-weight: 700; font-size: .95rem;
  width: 2.2rem; height: 2.2rem; border-radius: 50%; display: grid; place-items: center;
  border: 1.5px solid var(--av); color: var(--av); background: var(--surface);
}
.step h4 { font-family: var(--f-display); font-weight: 600; font-size: 1.12rem; letter-spacing: -.01em; margin: .25rem 0 .35rem; }
.step p { margin: 0 0 .9rem; max-width: var(--measure); }
.ui { font-weight: 600; background: var(--slab); border: 1px solid var(--line); border-radius: 4px; padding: 0 .3rem; white-space: nowrap; font-size: .95em; }
kbd { font-family: var(--f-mono); font-size: .82em; padding: .05rem .35rem; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; background: var(--surface); white-space: nowrap; }
code { font-family: var(--f-mono); font-size: .88em; background: var(--slab); padding: 0 .3rem; border-radius: 4px; }

figure.shot { margin: 0; max-width: var(--wide); }
figure.shot button { all: unset; display: block; cursor: zoom-in; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); background: var(--surface); max-width: 100%; }
figure.shot button:focus-visible { outline: 2px solid var(--av); outline-offset: 3px; }
figure.shot img { display: block; width: 100%; height: auto; }
figure.shot figcaption { font-family: var(--f-mono); font-size: .72rem; color: var(--muted); margin-top: .5rem; display: flex; gap: .8rem; flex-wrap: wrap; }

/* The cold-start states, using the brand ramp as its legend */
.states { list-style: none; margin: .5rem 0 1.1rem; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; max-width: var(--wide); }
.states li { font-family: var(--f-mono); font-size: .75rem; padding: .35rem .65rem; border-radius: 6px; background: var(--process-soft); color: var(--process); }
.states li.done { background: var(--av-soft); color: var(--av); font-weight: 700; }
.states li.arrow { background: none; color: var(--muted); padding: 0; }
.states li small { display: block; font-size: .68rem; opacity: .8; }
@media (max-width: 560px) {
  .states { flex-direction: column; align-items: flex-start; gap: .25rem; }
  .states li.arrow { transform: rotate(90deg); padding-left: .9rem; line-height: 1; }
}

/* Summary */
.summary { max-width: var(--wide); background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; margin-top: 1.25rem; }
.summary div { display: grid; grid-template-columns: 7rem minmax(0, 1fr); gap: 1rem; padding: .85rem 1.2rem; border-top: 1px solid var(--line); }
.summary div:first-child { border-top: 0; }
.summary dt { font-family: var(--f-mono); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--av); padding-top: .15rem; }
.summary dd { margin: 0; }

.foot { margin-top: 3.5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .88rem; max-width: var(--wide); }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; margin: 1.5rem 0 0; max-width: var(--wide); }
.pager a { display: block; padding: .9rem 1.1rem; border: 1px solid var(--line); border-radius: 10px; text-decoration: none; color: var(--fg); background: var(--surface); }
.pager a:hover { border-color: var(--av); }
.pager .k { font-family: var(--f-mono); font-size: .72rem; color: var(--muted); display: block; }
.pager .next { text-align: right; }
@media (max-width: 560px) { .pager { grid-template-columns: 1fr; } .pager .next { text-align: left; } .step { grid-template-columns: minmax(0, 1fr); } .step::before { margin-bottom: .4rem; } .summary div { grid-template-columns: minmax(0, 1fr); gap: .2rem; } }

/* Lightbox */
dialog.zoom { border: 0; padding: 0; background: transparent; max-width: 96vw; max-height: 94vh; }
dialog.zoom::backdrop { background: rgba(11,10,18,.82); }
dialog.zoom img { display: block; max-width: 96vw; max-height: 88vh; width: auto; height: auto; border-radius: 8px; }
dialog.zoom p { color: #EFEDF6; font-family: var(--f-mono); font-size: .78rem; margin: .6rem 0 0; display: flex; justify-content: space-between; gap: 1rem; }
dialog.zoom button { all: unset; cursor: pointer; color: #9BF0FA; }
@media (prefers-reduced-motion: no-preference) { figure.shot button { transition: transform .15s ease, box-shadow .15s ease; } figure.shot button:hover { transform: translateY(-2px); } }

/* Generated pages (2026-11-06) */
.top .back { margin-left: auto; font-family: var(--f-mono); font-size: .8rem; color: var(--muted); text-decoration: none; }
.top .back:hover { color: var(--av); }
.series ol a .t { display: block; }
video.guide-video { display: block; width: 100%; max-width: var(--wide); aspect-ratio: 1602 / 1032; height: auto;
  border-radius: 12px; background: #0B0A12; box-shadow: var(--shadow); margin: 0 0 1.25rem; }
.chapters { max-width: var(--wide); list-style: none; margin: .5rem 0 1rem; padding: 0; display: grid; gap: 2px; }
.chapters button { all: unset; box-sizing: border-box; cursor: pointer; display: grid; grid-template-columns: 3.4rem minmax(0, 1fr);
  gap: .6rem; width: 100%; padding: .45rem .6rem; border-radius: 6px; line-height: 1.45; }
.chapters button:hover { background: var(--slab); }
.chapters button:focus-visible { outline: 2px solid var(--av); outline-offset: 2px; }
.chapters .ts { font-family: var(--f-mono); font-size: .8rem; color: var(--av); padding-top: .12rem; }
.chapters h3 { font-size: 1rem; margin: 1.2rem 0 .3rem; }
.vsum { max-width: var(--measure); margin: 0 0 .75rem; }
.part > .steps { margin-top: 1rem; }
figure.shot button.watch { all: unset; cursor: pointer; font-family: var(--f-mono); font-size: .78rem; color: var(--av);
  padding: .15rem 0; border-radius: 4px; }
figure.shot button.watch:hover { text-decoration: underline; }
figure.shot button.watch:focus-visible { outline: 2px solid var(--av); outline-offset: 2px; }
figure.shot button.watch .ts { color: var(--muted); margin-left: .35rem; }
.groups { display: grid; gap: 2.5rem; margin-top: 2rem; }
.group h2 { font-size: 1.35rem; margin: 0 0 .9rem; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: .9rem; }
.card { display: grid; grid-template-rows: auto 1fr auto; gap: .35rem; padding: 1.1rem 1.2rem; background: var(--surface);
  border: 1px solid var(--line); border-radius: 12px; color: var(--fg); text-decoration: none; }
.card:hover { border-color: var(--av); }
.card .k { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--av); }
.card .t { font-family: var(--f-display); font-weight: 600; font-size: 1.12rem; line-height: 1.25; }
.card .d { color: var(--muted); font-size: .9rem; }
.card .m { font-family: var(--f-mono); font-size: .72rem; color: var(--muted); }
