:root{--brand:#4850B2;--brand-deep:#363c8a;--bg:#FAF7FE;--surface:#fff;--ink:#1c1b22;--muted:#5a5666;--faint:#9a95a6;--line:rgba(72,80,178,0.14);--tint:#eceef8;--serif:"Fraunces",Georgia,serif;--sans:"Instrument Sans",system-ui,sans-serif;}
*{box-sizing:border-box;margin:0;padding:0;}
body{background:var(--bg);color:var(--ink);font-family:var(--sans);font-size:16.5px;line-height:1.7;-webkit-font-smoothing:antialiased;}
::selection{background:var(--brand);color:#fff;}
a{color:var(--brand);text-decoration:none;border-bottom:1px solid var(--line);}
a:hover{border-color:var(--brand);}
.wrap{max-width:760px;margin:0 auto;padding:0 26px;}
.topbar{border-bottom:1px solid var(--line);padding:22px 0;position:sticky;top:0;background:rgba(250,247,254,0.9);backdrop-filter:blur(8px);z-index:10;}
.topbar .wrap{display:flex;justify-content:space-between;align-items:center;}
.home{font-family:var(--serif);font-weight:600;color:var(--brand);font-size:1.15rem;border:none;}
.back{font-size:0.9rem;color:var(--muted);border:none;}
header.doc{padding:64px 0 30px;}
.eyebrow{font-size:12px;letter-spacing:0.2em;text-transform:uppercase;color:var(--brand);font-weight:600;}
h1{font-family:var(--serif);font-weight:600;font-size:clamp(2.1rem,5vw,3rem);letter-spacing:-0.02em;margin:14px 0 10px;line-height:1.05;}
.updated{color:var(--faint);font-size:0.9rem;}
.intro{background:var(--surface);border:1px solid var(--line);border-left:4px solid var(--brand);border-radius:12px;padding:20px 22px;margin:28px 0;color:var(--muted);}
.intro strong{color:var(--ink);}
main{padding-bottom:70px;}
h2{font-family:var(--serif);font-weight:600;font-size:1.4rem;color:var(--brand);margin:38px 0 10px;}
p{margin:12px 0;color:var(--muted);}
p strong,li strong{color:var(--ink);font-weight:600;}
ul{margin:12px 0 12px 4px;padding-left:22px;color:var(--muted);}
li{margin:7px 0;}
table{width:100%;border-collapse:collapse;margin:18px 0;font-size:0.95rem;}
th,td{text-align:left;padding:11px 12px;border-bottom:1px solid var(--line);color:var(--muted);}
th{color:var(--brand-deep);font-weight:600;font-size:0.82rem;letter-spacing:0.04em;text-transform:uppercase;}
footer{border-top:1px solid var(--line);padding:36px 0 60px;font-size:0.86rem;color:var(--faint);}
footer .wrap{display:flex;flex-wrap:wrap;gap:18px;justify-content:space-between;}
footer a{color:var(--muted);font-size:0.78rem;}
.tm{font-size:0.7em;vertical-align:super;}
.home [data-scramble]{display:inline-block;min-width:9.4em;}
/* white reading cards over the constellation (matches the homepage). Body text on white; headings/title stay CLEAR so the stars show behind them; gaps between cards reveal the constellation. */
main p,main ul,main table{background:#fff;border-radius:14px;box-shadow:0 2px 30px rgba(72,80,178,0.07);margin:16px 0;}
main p{padding:15px 20px;}
main ul{padding:14px 22px 14px 42px;}
main table{padding:6px 12px;}
main h1,main h2{background:transparent;}
main h2{margin:44px 0 14px;}
/* full-page interactive constellation — fixed canvas behind ALL content */
.stars{position:fixed;inset:0;width:100%;height:100%;z-index:-1;display:block;pointer-events:none;}

/* ---- dark-mode toggle (beside "Back to home") ---- */
.topbar-actions{display:inline-flex;align-items:center;gap:14px;}
.theme-toggle{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;border-radius:50%;color:var(--brand);border:1.5px solid var(--brand);background:#fff;cursor:pointer;box-shadow:0 0 0 1px rgba(72,80,178,0.10),0 0 11px rgba(72,80,178,0.45);transition:box-shadow .25s,transform .2s;}
.theme-toggle:hover{transform:translateY(-1px);box-shadow:0 0 0 1px rgba(72,80,178,0.18),0 0 18px rgba(72,80,178,0.7);}
.theme-toggle svg{width:15px;height:15px;display:block;}
.theme-toggle .sun{display:none;}
html[data-theme="dark"] .theme-toggle .moon{display:none;}
html[data-theme="dark"] .theme-toggle .sun{display:block;}

/* ================= DARK MODE ================= (Blueprint §Web Presence, Roadmap 1) */
html[data-theme="dark"]{
  --bg:#000; --ink:#eef0f7; --muted:#c4c7d4; --faint:#8b8ea0;
  --line:rgba(255,255,255,0.16); --accent:#aab4ff;
  --glass-bg:rgba(0,0,0,0.4);
  --darkborder:linear-gradient(125deg,#6b73c9,#ffffff,#6b73c9);
}
html[data-theme="dark"] .topbar{background:rgba(6,7,12,0.6);}
html[data-theme="dark"] .home{color:#fff;}
html[data-theme="dark"] .eyebrow,
html[data-theme="dark"] h1,html[data-theme="dark"] h2,
html[data-theme="dark"] th{color:#fff;text-shadow:0 0 26px rgba(120,130,255,0.45);}
html[data-theme="dark"] a{color:var(--accent);}
html[data-theme="dark"] .back,html[data-theme="dark"] footer a{color:var(--faint);}
html[data-theme="dark"] .intro strong,html[data-theme="dark"] p strong,html[data-theme="dark"] li strong{color:#fff;}
/* reading cards → transparent 40% black, awaken-DarkBorder as a masked 1px outline only */
html[data-theme="dark"] main p,
html[data-theme="dark"] main ul,
html[data-theme="dark"] .intro{
  background:var(--glass-bg);border:none;position:relative;
  -webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);box-shadow:none;color:var(--muted);
}
html[data-theme="dark"] main p::before,
html[data-theme="dark"] main ul::before,
html[data-theme="dark"] .intro::before{
  content:"";position:absolute;inset:0;border-radius:inherit;padding:1px;
  background:var(--darkborder);
  -webkit-mask:linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite:xor;mask-composite:exclude;pointer-events:none;
}
html[data-theme="dark"] main table{background:var(--glass-bg);border:1px solid rgba(160,170,255,0.4);color:var(--muted);}
