/* prism documentation styles (docs/plans/2026-09-28-docs.md). One stylesheet for every page. */
:root {
  --bg: #111312; --panel: #1a1d1b; --panel2: #202421; --line: #2f3531; --text: #e8ebe6;
  --muted: #a3aaa2; --faint: #7a8279; --lime: #e4ff3a; --lime-dim: rgba(228,255,58,.12);
  --coral: #ff7a66; --amber: #ffb547; --good: #7ee08a; --radius: 10px;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.6 "Segoe UI", system-ui, -apple-system, sans-serif; }
.wrap { max-width: 880px; margin: 0 auto; padding: 32px 16px 80px; }
.crumbs { color: var(--faint); font-size: 13px; letter-spacing: .02em; }
.crumbs b { color: var(--muted); font-weight: 600; }
h1 { font-size: 40px; line-height: 1.1; margin: 10px 0 12px; letter-spacing: -.02em; }
h1 .mark { color: var(--lime); }
.lead { font-size: 19px; color: #cfd5cd; max-width: 720px; }
h2 { font-size: 26px; margin: 48px 0 10px; letter-spacing: -.01em; padding-top: 8px; border-top: 1px solid var(--line); }
h2 .n { color: var(--lime); font-variant-numeric: tabular-nums; margin-right: 8px; }
h3 { font-size: 18px; margin: 26px 0 6px; }
p, li { color: #d6dbd4; }
a { color: var(--lime); }
kbd { font: 600 12px/1 ui-monospace, Consolas, monospace; background: var(--panel2); border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 3px 6px; color: var(--text); white-space: nowrap; }
.ui { font-weight: 600; color: var(--text); background: var(--panel2); border: 1px solid var(--line); border-radius: 6px; padding: 1px 7px; white-space: nowrap; }
.glance { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; margin: 26px 0 8px; }
.glance div { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.glance b { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); margin-bottom: 4px; }
.toc { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin: 18px 0; columns: 2; column-gap: 28px; font-size: 15px; }
.toc a { color: var(--text); text-decoration: none; display: block; padding: 2px 0; break-inside: avoid; }
.toc a:hover { color: var(--lime); }
ol.steps { counter-reset: s; list-style: none; padding-left: 0; }
ol.steps > li { counter-increment: s; position: relative; padding-left: 44px; margin: 12px 0; }
ol.steps > li::before { content: counter(s); position: absolute; left: 0; top: 1px; width: 28px; height: 28px; border-radius: 50%; background: var(--lime); color: #111; font-weight: 800; font-size: 14px; display: grid; place-items: center; }
figure { margin: 22px 0; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
figure img { display: block; width: 100%; height: auto; }
figcaption { padding: 10px 14px; font-size: 14px; color: var(--muted); border-top: 1px solid var(--line); }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pair figure { margin: 10px 0; }
.tip, .note, .warn { border-radius: var(--radius); padding: 12px 16px 12px 46px; margin: 18px 0; position: relative; border: 1px solid; }
.tip { background: var(--lime-dim); border-color: rgba(228,255,58,.35); }
.note { background: rgba(126,224,138,.08); border-color: rgba(126,224,138,.3); }
.warn { background: rgba(255,181,71,.08); border-color: rgba(255,181,71,.35); }
.tip::before, .note::before, .warn::before { position: absolute; left: 14px; top: 11px; font-weight: 800; font-size: 17px; }
.tip::before { content: "✦"; color: var(--lime); }
.note::before { content: "i"; color: var(--good); font-family: Georgia, serif; font-style: italic; left: 19px; }
.warn::before { content: "!"; color: var(--amber); left: 19px; }
.tip b:first-child, .note b:first-child, .warn b:first-child { color: var(--text); }
table { width: 100%; border-collapse: collapse; margin: 14px 0; font-size: 15px; }
th, td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--faint); font-size: 12px; text-transform: uppercase; letter-spacing: .07em; font-weight: 700; }
td:first-child { white-space: nowrap; }
.badge { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; border-radius: 99px; padding: 2px 8px; vertical-align: middle; }
.b-simple { background: var(--lime-dim); color: var(--lime); border: 1px solid rgba(228,255,58,.35); }
.b-adv { background: rgba(255,122,102,.1); color: var(--coral); border: 1px solid rgba(255,122,102,.35); }
.ring { display: inline-block; width: 11px; height: 11px; border-radius: 50%; border: 3px solid; vertical-align: -1px; }
.related { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.related a { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; text-decoration: none; color: var(--text); }
.related a span { display: block; color: var(--muted); font-size: 13px; }
.foot { margin-top: 56px; color: var(--faint); font-size: 13px; border-top: 1px solid var(--line); padding-top: 14px; }
/* A screenshot still to take: <figure data-todo-shot="what it will show"><figcaption>…</figcaption></figure> (no <img>) shows a "Screenshot coming" box. The viewer and the export turn an <img data-todo-shot> into this too. */
figure[data-todo-shot] { display: flex; flex-direction: column; }
figure[data-todo-shot] img, figure[data-todo-shot] picture { display: none; }
figure[data-todo-shot]::before, figure[data-todo-shot]::after { margin: 0 12px; text-align: center; background-color: var(--panel2); border: 1px dashed #4a524c; }
figure[data-todo-shot]::before { order: -2; content: "Screenshot coming"; margin-top: 12px; padding: 60px 18px 2px; border-bottom: 0; border-radius: 8px 8px 0 0; font-weight: 700; color: var(--text); background: var(--panel2) url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a3aaa2' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'><path d='M3.5 8.5h3.2l1.8-2.7h7l1.8 2.7h3.2v10.2h-17z'/><circle cx='12' cy='13.3' r='3.4'/></svg>") center 20px / 30px no-repeat; }
figure[data-todo-shot]::after { order: -1; content: attr(data-todo-shot); margin-bottom: 12px; padding: 0 18px 24px; border-top: 0; border-radius: 0 0 8px 8px; font-size: 14px; color: var(--muted); }
figure[data-todo-shot=""]::after { content: none; }
figure[data-todo-shot=""]::before { margin-bottom: 12px; padding-bottom: 24px; border-bottom: 1px dashed #4a524c; border-radius: 8px; }
/* Tables the viewer and the export wrap, so a wide one scrolls sideways on a phone. */
.table-scroll { overflow-x: auto; margin: 14px 0; }
.table-scroll > table { margin: 0; }
@media (max-width: 640px) { h1 { font-size: 32px; } .pair { grid-template-columns: 1fr; } .toc { columns: 1; } td:first-child { white-space: normal; } }

/* long button chips may wrap on phones (tables stay inside the page) */
@media (max-width: 640px) { td .ui { white-space: normal; } }

/* the 3D object rings: X red, Y green, Z blue, the outer ring ivory */
.ring.x { border-color: #ef4a4a; } .ring.y { border-color: #3cc46b; } .ring.z { border-color: #4a8ff0; } .ring.o { border-color: #e9e4d4; }

/* Lesson recordings remain readable in the standalone and shadow-root viewers. */
video { display: block; width: 100%; max-width: 100%; border-radius: 8px; background: #111713; }
code { overflow-wrap: anywhere; }
