:root {
  --bg: #0b0f17; --panel: #121826; --panel2: #182033; --line: #263049; --text: #e7ebf3; --muted: #97a3b8;
  --accent: #e0384f; --ok: #2fbf71; --bad: #ef5350; --az: #3b8eea; --aws: #ff9900; --code: #0f1420;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: #8fc1ff; }
code, pre { font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; font-size: .86em; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.top { position: sticky; top: 0; z-index: 5; background: rgba(11,15,23,.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.top-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 56px; flex-wrap: wrap; }
.brand { color: var(--text); text-decoration: none; font-weight: 700; display: flex; align-items: center; gap: 10px; }
.mark { background: var(--accent); color: #fff; border-radius: 6px; padding: 2px 7px; font-size: 13px; letter-spacing: .5px; }
nav { display: flex; gap: 14px; flex-wrap: wrap; font-size: 14px; }
nav a { color: var(--muted); text-decoration: none; }
nav a:hover { color: var(--text); }
section { padding: 56px 0; }
.band { background: var(--panel); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.hero { padding-top: 64px; }
.eyebrow { color: var(--accent); font-weight: 600; text-transform: uppercase; letter-spacing: 1.2px; font-size: 13px; margin: 0 0 10px; }
h1 { font-size: clamp(28px, 4.4vw, 46px); line-height: 1.12; margin: 0 0 18px; max-width: 900px; }
h2 { font-size: 28px; margin: 0 0 6px; }
h3 { font-size: 17px; margin: 0 0 12px; }
.mt { margin-top: 32px; }
.lede { color: #c6cedc; font-size: 18px; max-width: 860px; }
.sub { color: var(--muted); max-width: 860px; margin: 0 0 22px; }
.by { color: var(--muted); margin-top: 22px; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.pill { border: 1px solid var(--line); background: var(--panel2); border-radius: 999px; padding: 5px 12px; font-size: 14px; display: inline-flex; gap: 8px; align-items: center; }
.pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.pill.ok::before { background: var(--ok); box-shadow: 0 0 8px var(--ok); }
.pill.bad::before { background: var(--bad); }
.pill.az { border-color: rgba(59,142,234,.5); }
.pill.aws { border-color: rgba(255,153,0,.5); }
.video { aspect-ratio: 16/9; background: #000; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); }
.video video { width: 100%; height: 100%; display: block; }
.note, .fine { color: var(--muted); font-size: 14px; }
.console { display: grid; grid-template-columns: minmax(240px, 320px) 1fr; gap: 16px; }
.scenarios { display: flex; flex-direction: column; gap: 8px; }
.scn { text-align: left; background: var(--panel); color: var(--text); border: 1px solid var(--line); border-left: 4px solid var(--ok); border-radius: 8px; padding: 10px 12px; cursor: pointer; font: inherit; font-size: 15px; }
.scn.deny { border-left-color: var(--bad); }
.scn:hover, .scn.on { background: var(--panel2); border-color: #3a4768; }
.scn small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.scn-search { display: flex; gap: 6px; margin-top: 6px; }
.scn-search input { flex: 1; min-width: 0; }
input, select { background: var(--code); color: var(--text); border: 1px solid var(--line); border-radius: 8px; padding: 9px 10px; font: inherit; font-size: 15px; }
button[type=submit], .ask button { background: var(--accent); color: #fff; border: 0; border-radius: 8px; padding: 9px 16px; font: inherit; font-weight: 600; cursor: pointer; }
button:disabled { opacity: .6; cursor: wait; }
.trace { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; min-height: 360px; min-width: 0; }
.empty { color: var(--muted); }
.verdict { display: flex; align-items: center; gap: 10px; font-weight: 600; margin-bottom: 4px; }
.verdict .tag { font-size: 12px; padding: 2px 8px; border-radius: 6px; background: var(--ok); color: #04170c; }
.verdict .tag.deny { background: var(--bad); color: #fff; }
.expect { color: var(--muted); font-size: 14px; margin: 0 0 14px; }
.hops { list-style: none; padding: 0; margin: 0 0 14px; display: grid; gap: 6px; }
.hops li { display: grid; grid-template-columns: 20px 1fr auto; gap: 10px; align-items: baseline; font-size: 14.5px; }
.hops li .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--az); margin-top: 5px; }
.hops li.aws .dot { background: var(--aws); }
.hops li.stop .dot { background: var(--bad); }
.hops li .ms { color: var(--muted); font-variant-numeric: tabular-nums; }
.hops li .d { color: var(--muted); font-size: 13px; }
pre { background: var(--code); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; overflow: auto; max-height: 340px; margin: 6px 0 0; white-space: pre-wrap; word-break: break-word; }
details { margin-top: 10px; }
summary { cursor: pointer; color: #b8c3d8; font-size: 14px; }
.rows { width: 100%; border-collapse: collapse; font-size: 14px; }
.rows td, .rows th { border-bottom: 1px solid var(--line); padding: 6px 8px; text-align: left; vertical-align: top; }
.rows th { color: var(--muted); font-weight: 600; }
.ask { display: grid; grid-template-columns: minmax(180px, 260px) 1fr auto; gap: 8px; }
.examples { color: var(--muted); font-size: 14px; margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.examples button { background: transparent; border: 1px solid var(--line); color: #c6cedc; border-radius: 999px; padding: 3px 10px; cursor: pointer; font: inherit; font-size: 13px; }
.agent-out { margin-top: 18px; }
.answer { background: var(--panel2); border: 1px solid var(--line); border-radius: 12px; padding: 16px; white-space: pre-wrap; }
.step { font-size: 14px; color: #c6cedc; margin: 4px 0; }
.step code { color: #ffd38a; }
.where-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; min-width: 0; }
.card.map { margin-top: 16px; }
.diagram { margin: 16px 0 0; }
.diagram img { display: block; width: 100%; height: auto; border-radius: 8px; background: #0b0f17; }
.diagram figcaption { color: var(--muted); font-size: 13.5px; margin-top: 10px; }
dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0; font-size: 14.5px; }
dt { color: var(--muted); }
dd { margin: 0; overflow-wrap: anywhere; }
.path { list-style: none; padding: 0; margin: 0 0 12px; display: flex; flex-wrap: wrap; gap: 8px; }
.path li { background: var(--panel2); border: 1px solid var(--line); border-top: 3px solid var(--muted); border-radius: 8px; padding: 8px 10px; display: flex; flex-direction: column; min-width: 120px; flex: 1; }
.path li.az { border-top-color: var(--az); }
.path li.aws { border-top-color: var(--aws); }
.path li span { color: var(--muted); font-size: 12.5px; }
.table { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { color: var(--muted); font-weight: 600; }
td:first-child { color: #c6cedc; width: 36%; }
.checks { padding-left: 20px; }
.checks li { margin: 4px 0; }
.links { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.big { display: flex; flex-direction: column; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; text-decoration: none; color: var(--text); }
.big:hover { border-color: #3a4768; }
.big span { color: var(--muted); font-size: 14px; }
.foot { border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; padding: 24px 0 40px; }
.status-sec { padding-top: 24px; }
.status-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.status-all { font-size: 14px; color: var(--muted); }
.status-all.ok { color: var(--ok); }
.status-all.bad { color: var(--bad); }
.cloud-label { font-size: 13px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; margin: 18px 0 8px; }
.cloud-label.az { color: var(--az); }
.cloud-label.aws { color: var(--aws); }
.lights { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; }
.light { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 12px; min-width: 0; }
.light-top { display: flex; align-items: center; gap: 10px; }
.lamp { width: 14px; height: 14px; border-radius: 50%; flex: none; background: #5b6476; }
.lamp.ok { background: var(--ok); box-shadow: 0 0 10px var(--ok); animation: glow 2.4s ease-in-out infinite; }
.lamp.bad { background: var(--bad); box-shadow: 0 0 10px var(--bad); }
.lamp.wait { background: #c9a227; }
@keyframes glow { 50% { box-shadow: 0 0 3px var(--ok); } }
@media (prefers-reduced-motion: reduce) { .lamp.ok { animation: none; } }
.light-name { font-weight: 600; font-size: 15px; overflow-wrap: anywhere; min-width: 0; }
.light-what { color: var(--muted); font-size: 12.5px; margin: 2px 0 0 24px; }
.light-last { font-size: 13px; margin: 8px 0 0 24px; color: #c6cedc; overflow-wrap: anywhere; }
.light-meta { font-size: 12px; margin: 4px 0 0 24px; color: var(--muted); }
.spark { display: flex; gap: 2px; margin: 6px 0 0 24px; }
.spark i { width: 5px; height: 10px; border-radius: 1px; background: var(--ok); opacity: .8; }
.spark i.f { background: var(--bad); }
.sow-grid { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(300px, 520px); gap: 40px; align-items: center; }
.sow-toc { list-style: none; padding: 0; margin: 18px 0; display: grid; gap: 6px; }
.sow-toc li { display: grid; grid-template-columns: 56px 1fr; gap: 10px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 8px; cursor: pointer; color: #c6cedc; font-size: 15px; transition: border-color .2s, background .2s; }
.sow-toc li span { color: var(--accent); font-weight: 700; font-variant-numeric: tabular-nums; }
.sow-toc li:hover, .sow-toc li.on { background: var(--panel2); border-color: #3a4768; color: var(--text); }
.sow-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn { display: inline-block; background: var(--accent); color: #fff; text-decoration: none; font-weight: 600; border-radius: 8px; padding: 10px 18px; }
.btn.ghost { background: transparent; border: 1px solid var(--line); color: var(--text); }
.btn:hover { filter: brightness(1.08); }
.sow { overflow-x: clip; }
.sow-viewer { position: relative; outline: none; padding: 30px 44px 0 0; }
.sheets { position: relative; aspect-ratio: 8.5 / 11; perspective: 1600px; container-type: inline-size; }
.sheet { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #fff; border-radius: 4px;
  box-shadow: 0 30px 60px -20px rgba(0,0,0,.7), 0 0 0 1px rgba(255,255,255,.06);
  transition: transform .55s cubic-bezier(.2,.7,.2,1), opacity .45s, filter .45s; transform-origin: 50% 100%; cursor: zoom-in; }
.sheet.on { z-index: 4; transform: none; opacity: 1; }
.sheet.next1 { z-index: 3; transform: translate(14px, -10px) rotate(2.2deg) scale(.985); filter: brightness(.82); }
.sheet.next2 { z-index: 2; transform: translate(26px, -18px) rotate(4deg) scale(.97); filter: brightness(.66); }
.sheet.next3 { z-index: 1; transform: translate(36px, -24px) rotate(5.6deg) scale(.955); filter: brightness(.5); }
.sheet.gone { z-index: 5; transform: translate(-70%, 6%) rotate(-14deg); opacity: 0; pointer-events: none; }
/* "EXAMPLE ONLY" watermark over the page viewer and the full-screen view: large, diagonal, faint, click-through */
.sheets::after, .lightbox .lb-page::after {
  content: "EXAMPLE ONLY"; position: absolute; inset: 0; z-index: 10; pointer-events: none;
  display: flex; align-items: center; justify-content: center; text-align: center;
  font: 800 13.5cqw/1 Inter, system-ui, sans-serif; letter-spacing: .04em;
  color: rgba(224, 56, 79, .16); transform: rotate(-52deg); white-space: nowrap;   /* 52deg: the page's diagonal */
  -webkit-text-stroke: 1.5px rgba(224, 56, 79, .28);
}
.lightbox .lb-page { position: relative; display: flex; container-type: inline-size; max-width: min(100%, 980px); max-height: 100%; }
.sow-viewer:focus-visible .sheet.on { box-shadow: 0 0 0 3px var(--accent), 0 30px 60px -20px rgba(0,0,0,.7); }
.pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 22px; }
.pager button { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: var(--panel); color: var(--text); font-size: 20px; cursor: pointer; line-height: 1; }
.pager button:hover:not(:disabled) { border-color: #3a4768; background: var(--panel2); }
.pager button:disabled { opacity: .35; cursor: default; }
.pager .zoom { font-size: 16px; margin-left: 6px; }
.dots { display: flex; gap: 6px; }
.dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--line); cursor: pointer; transition: background .2s, transform .2s; }
.dots i.on { background: var(--accent); transform: scale(1.25); }
.pno { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; min-width: 40px; text-align: center; }
.lightbox { position: fixed; inset: 0; z-index: 50; background: rgba(5,8,14,.92); display: flex; align-items: center; justify-content: center; padding: 16px; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 32px); object-fit: contain; background: #fff; border-radius: 4px; box-shadow: 0 20px 60px rgba(0,0,0,.6); cursor: zoom-out; }
.lightbox .lb-nav { position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); display: flex; gap: 10px; }
.lightbox button { width: 42px; height: 42px; border-radius: 50%; border: 1px solid #3a4768; background: var(--panel); color: var(--text); font-size: 20px; cursor: pointer; }
@media (prefers-reduced-motion: reduce) { .sheet { transition: none; } }
.repo { display: block; margin-top: 26px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; color: var(--text); text-decoration: none; transition: border-color .2s, transform .2s; max-width: 980px; }
.repo:hover { border-color: #4a5a85; transform: translateY(-1px); }
.repo-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.gh { width: 30px; height: 30px; color: var(--text); flex: none; }
.repo-title { font-size: 20px; }
.repo-title .owner { color: var(--muted); }
.repo-title b { color: #8fc1ff; }
.vis { border: 1px solid var(--line); border-radius: 999px; font-size: 12px; padding: 1px 8px; color: var(--muted); margin-left: 6px; vertical-align: middle; }
.ci { margin-left: auto; font-size: 13px; border-radius: 999px; padding: 3px 10px; background: var(--panel2); border: 1px solid var(--line); color: var(--muted); }
.ci.ok { color: #04170c; background: var(--ok); border-color: var(--ok); font-weight: 600; }
.ci.bad { color: #fff; background: var(--bad); border-color: var(--bad); }
.repo-desc { color: #c6cedc; margin: 10px 0; }
.repo-topics { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.repo-topics span { background: rgba(56,139,253,.15); color: #79b8ff; border-radius: 999px; padding: 2px 10px; font-size: 12.5px; }
.repo-body { display: grid; grid-template-columns: minmax(200px, 300px) 1fr; gap: 16px; }
.repo-tree { list-style: none; margin: 0; padding: 8px 0; border: 1px solid var(--line); border-radius: 8px; columns: 2; column-gap: 8px; font-size: 13.5px; }
.repo-tree li { padding: 3px 12px; color: #c6cedc; break-inside: avoid; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.repo-tree li::before { content: "📄 "; font-size: 12px; }
.repo-tree li.dir::before { content: "📁 "; }
.repo-label { color: var(--muted); font-size: 12.5px; text-transform: uppercase; letter-spacing: .8px; margin-bottom: 6px; }
.repo-commits ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.repo-commits li { font-size: 14px; display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: baseline; }
.repo-commits code { color: #8fc1ff; }
.repo-commits .when { color: var(--muted); font-size: 12.5px; white-space: nowrap; }
.repo-commits .msg { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.repo-foot { display: flex; align-items: center; gap: 12px; margin-top: 14px; color: var(--muted); font-size: 13px; flex-wrap: wrap; }
.langbar { display: flex; width: 160px; height: 8px; border-radius: 4px; overflow: hidden; background: var(--line); }
.langbar i { display: block; height: 100%; }
.repo-foot .open { margin-left: auto; color: #8fc1ff; font-weight: 600; }
.muted { color: var(--muted); }
@media (max-width: 820px) {
  .console, .where-grid, .sow-grid { grid-template-columns: 1fr; }
  .sow-grid { gap: 24px; }
  .repo-body { grid-template-columns: 1fr; }
  .repo-commits li { grid-template-columns: auto 1fr; }
  .repo-commits .when { display: none; }
  .sow-viewer { padding: 14px 14px 0 0; }
  .sheet.next1, .sheet.next2, .sheet.next3 { transform: translate(6px, -6px) rotate(1.5deg) scale(.985); }
  .ask { grid-template-columns: 1fr; }
  nav { display: none; }
  section { padding: 40px 0; }
}
