/* Parody Vlad · tracking the Vladness. Chalkboard navy + chalk + warm gold (never a brand green). Light + dark.
   Text colours meet WCAG AA (4.5:1) on their backgrounds; --accent-fill is the brighter gold for graphics only.
   No web fonts (nothing is downloaded): the chalk face is a system handwriting font, else plain sans-serif. */
:root {
  --bg: #f5f0e4;
  --bg-2: #ede5d3;
  --surface: #fffdf7;
  --surface-2: #f3ecdc;
  --ink: #15213d;
  --muted: #5a6478;
  --line: #e1d7c2;
  --field-line: #9a8f78;
  --accent: #8a5a0c;
  --accent-fill: #a26d16;
  --accent-ink: #ffffff;
  --accent-soft: rgba(162, 109, 22, 0.12);
  --note-bg: #15213d;
  --note-ink: #f5ebd6;
  --board: #16264a;
  --board-2: #1d3160;
  --wood: #8a6430;
  --chalk: #efe8d8;
  --chalk-dim: rgba(239, 232, 216, 0.72);
  --chalk-gold: #e4b24f;
  --hm0: #e8e0cf;
  --hm1: #e9cf98;
  --hm2: #dcae55;
  --hm3: #b98326;
  --hm4: #7d5510;
  --radius: 16px;
  --shadow: 0 1px 0 rgba(21, 33, 61, 0.04), 0 8px 24px -12px rgba(21, 33, 61, 0.18);
  --font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --chalk-font: "Chalkboard SE", "Segoe Print", "Bradley Hand", "Comic Neue", "Comic Sans MS", var(--font);
  --dust: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c1530;
    --bg-2: #0f1a38;
    --surface: #13213f;
    --surface-2: #192a50;
    --ink: #f2ead9;
    --muted: #a8b0c2;
    --line: #243a68;
    --field-line: #8a94a8;
    --accent: #e4b24f;
    --accent-fill: #e4b24f;
    --accent-ink: #0c1530;
    --accent-soft: rgba(228, 178, 79, 0.14);
    --note-bg: #e4b24f;
    --note-ink: #0c1530;
    --board: #0f1c3a;
    --board-2: #142449;
    --hm0: #182a52;
    --hm1: #5e4a26;
    --hm2: #8f6d33;
    --hm3: #c4923a;
    --hm4: #f2c766;
    --shadow: 0 1px 0 rgba(0, 0, 0, 0.2), 0 10px 30px -14px rgba(0, 0, 0, 0.6);
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  background-image: radial-gradient(circle at 20% -10%, var(--accent-soft), transparent 40%), radial-gradient(circle at 110% 20%, var(--accent-soft), transparent 35%);
  background-attachment: fixed;
  color: var(--ink);
  font: 400 17px/1.6 var(--font);
  overflow-x: hidden;
}
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
h1, h2, h3, h4 { line-height: 1.15; margin: 0; }
h2 { font-size: 24px; letter-spacing: -0.2px; }
main h2::after { content: ""; display: block; width: 52px; height: 4px; margin-top: 9px; border-radius: 3px; background: var(--accent-fill); opacity: 0.55; transform: rotate(-1.2deg); }
h3 { font-size: 16px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.6px; }
.small { font-size: 14px; }
.sub { color: var(--muted); margin: 6px 0 16px; }
.empty { color: var(--muted); font-style: italic; margin: 8px 0 0; }
.chalk { font-family: var(--chalk-font); color: var(--chalk); }
/* visually hidden, still read aloud */
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -80px; z-index: 20; background: var(--accent); color: var(--accent-ink); padding: 12px 16px; border-radius: 10px; font-weight: 700; }
.skip:focus { top: 12px; }

/* ---- top note + nav ---- */
.note { background: var(--note-bg); color: var(--note-ink); text-align: center; padding: 7px 16px; font-size: 14px; }
.nav {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 18px; justify-content: space-between;
  padding: 4px max(16px, calc((100vw - 1120px) / 2));
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; min-height: 44px; color: var(--ink); text-decoration: none; font-weight: 700; white-space: nowrap; }
.brand img { border-radius: 50%; border: 2px solid var(--accent-fill); }
.nav nav { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.nav nav::-webkit-scrollbar { display: none; }
.nav nav a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); text-decoration: none; padding: 0 12px; border-radius: 999px; font-size: 14px; white-space: nowrap; }
.nav nav a:hover { color: var(--ink); background: var(--surface-2); }
.nav nav a.here { color: var(--ink); font-weight: 700; background: var(--accent-soft); }
.nav nav a:focus-visible { outline-offset: -3px; }

main { max-width: 1120px; margin: 0 auto; padding: 28px 16px 40px; display: grid; gap: 22px; }

/* ---- hero ---- */
.hero { display: grid; grid-template-columns: 1.35fr 1fr; gap: 28px; align-items: center; padding: 20px 0 8px; }
.kicker { color: var(--accent); font-weight: 700; text-transform: uppercase; letter-spacing: 1.2px; font-size: 13px; margin: 0 0 10px; }
.hero h1 { font-size: clamp(44px, 7vw, 76px); letter-spacing: -1.5px; }
.lede { font-size: 19px; margin: 16px 0 18px; max-width: 34em; }
.lede em { font-style: normal; font-weight: 600; background: linear-gradient(transparent 58%, color-mix(in srgb, var(--accent-fill) 30%, transparent) 58%); }
.pills { list-style: none; padding: 0; margin: 0 0 20px; display: flex; flex-wrap: wrap; gap: 8px; }
.pills li { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 3px 12px; font-size: 14px; font-weight: 600; }
.cta { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px;
  background: var(--accent); color: var(--accent-ink); border: 2px solid var(--accent);
  font: 700 15px/1 var(--font); text-decoration: none; padding: 0 20px; border-radius: 999px; cursor: pointer;
  transition: transform 0.12s ease, filter 0.12s ease;
}
.btn:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn:focus-visible, .nav a:focus-visible, select:focus-visible, a:focus-visible, .skip:focus { outline: 3px solid var(--accent); outline-offset: 2px; }
.nav nav a:focus-visible { outline-offset: -3px; }
.btn.ghost { background: transparent; color: var(--accent); }
.btn.disabled { background: transparent; border: 2px dashed var(--field-line); color: var(--muted); cursor: default; transform: none; filter: none; }
.hero-card {
  justify-self: center; text-align: center; padding: 26px 26px 20px; border-radius: 28px;
  background: var(--dust), radial-gradient(circle at 50% 35%, var(--board-2), var(--board));
  box-shadow: var(--shadow); border: 1px solid var(--line); width: min(100%, 360px);
}
.avatar { width: 220px; height: 220px; border-radius: 50%; border: 4px solid var(--accent-fill); display: block; margin: 0 auto 16px; }
.uptime { display: grid; gap: 2px; color: var(--chalk); }
.u-label { font-size: 13px; text-transform: uppercase; letter-spacing: 1px; color: var(--chalk-dim); }
.u-val { font-family: var(--chalk-font); font-size: 24px; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ---- cards + grids ---- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; box-shadow: var(--shadow); min-width: 0; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }

/* ---- meter ---- */
.meter .sub { max-width: 32em; }
.gauge { width: min(100%, 340px); height: auto; display: block; margin: 0 auto; }
.g-track { fill: none; stroke: var(--surface-2); stroke-width: 18; stroke-linecap: round; }
.g-fill { fill: none; stroke: var(--accent-fill); stroke-width: 18; stroke-linecap: butt; }
.g-tick { stroke: var(--muted); stroke-width: 2; opacity: 0.5; }
.g-num { font: 800 46px/1 var(--font); fill: var(--ink); }
.g-sub { font: 500 12px/1 var(--font); fill: var(--muted); }
.tier { font-size: 30px; margin: 4px 0 10px; color: var(--accent); text-align: center; }
.spark-wrap { border-top: 1px dashed var(--line); padding-top: 12px; text-align: center; }
.spark { width: 100%; max-width: 360px; height: auto; display: block; margin: 0 auto; }
.sp-base { stroke: var(--line); stroke-width: 1; }
.sp-line { fill: none; stroke: var(--accent-fill); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.sp-dot { fill: var(--surface); stroke: var(--accent-fill); stroke-width: 2; }
.sp-dot:last-of-type { fill: var(--accent-fill); }

/* ---- the running bits + the tier ladder ---- */
.bits { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.bits li { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; align-items: baseline; }
.bit-l { font-weight: 600; font-size: 15px; }
.bit-n { font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; }
.bit-bar { grid-column: 1 / -1; display: block; }
.b-track { fill: var(--surface-2); }
.b-fill { fill: var(--accent-fill); }
.ladder-h { margin: 22px 0 10px; font-size: 13px; }
.tiers { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tiers li { display: inline-flex; align-items: baseline; gap: 6px; border: 1px solid var(--line); border-radius: 999px; padding: 3px 11px; font-size: 13px; color: var(--muted); }
.tiers b { color: var(--ink); font-variant-numeric: tabular-nums; }
.tiers li.on { border-color: var(--accent); background: var(--accent-soft); color: var(--ink); font-weight: 600; }

/* ---- tiles (3 across; a lone last tile spans the row) ---- */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tiles > .tile:last-child:nth-child(3n + 1) { grid-column: 1 / -1; }
.tiles > .tile:last-child:nth-child(3n + 2) { grid-column: span 2; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; box-shadow: var(--shadow); }
.t-num { font: 800 34px/1.05 var(--font); letter-spacing: -0.5px; font-variant-numeric: tabular-nums; }
.t-label { font-weight: 600; margin-top: 4px; }
.t-sub { color: var(--muted); font-size: 13px; margin-top: 2px; }
.tiles.small { margin-top: 18px; }
.tiles.small .tile { box-shadow: none; background: var(--surface-2); }
.tiles.small .t-num { font-size: 26px; }

/* ---- peak bit of the week ---- */
.peak { display: grid; grid-template-columns: auto 1fr; gap: 24px; align-items: center; background: linear-gradient(135deg, var(--surface), var(--surface-2)); }
.peak-score { width: 120px; height: 120px; border-radius: 50%; display: grid; place-content: center; text-align: center; background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 0 8px var(--accent-soft); }
.ps-num { font: 800 44px/1 var(--font); }
.ps-label { font: 700 12px/1.2 var(--font); text-transform: uppercase; letter-spacing: 1px; }
.peak blockquote { margin: 10px 0 12px; font-size: 21px; line-height: 1.45; font-weight: 500; overflow-wrap: anywhere; }
.peak-meta { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin: 0; color: var(--muted); font-size: 13px; }
.motif-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.motif-chips span { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 2px 10px; color: var(--ink); font-weight: 600; }

/* ---- chips (the wall) ---- */
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 6px 14px; border-radius: 12px;
  background: var(--dust), var(--board); color: var(--chalk); font-family: var(--chalk-font); font-size: 17px; text-decoration: none;
  border: 2px solid var(--wood); transform: rotate(-0.6deg);
}
.chip:nth-child(3n) { transform: rotate(0.8deg); }
.chip:nth-child(4n) { transform: rotate(-1.2deg); }
.chip b { font-family: var(--font); font-size: 13px; color: var(--chalk-gold); }
a.chip:hover { background: var(--dust), var(--board-2); }
.chips.ghost .chip { opacity: 0.45; }

/* ---- lists ---- */
.list { margin: 0; padding-left: 22px; display: grid; gap: 10px; }
.list li::marker { color: var(--accent); font-weight: 800; }
.list li { padding-left: 4px; }
.it-text { display: block; font-weight: 600; overflow-wrap: anywhere; }
.it-meta { display: block; color: var(--muted); font-size: 13px; }

/* small links get a 44px-tall hit area without moving the layout */
.it-meta a, .meta a, .board figcaption a, .best a, .peak-meta a, .foot a, .more a { display: inline-block; padding: 12px 6px; margin: -12px -6px; }

/* ---- theorem boards ---- */
.boards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.board {
  margin: 0; padding: 18px 20px; border-radius: 12px; min-height: 120px; display: flex; flex-direction: column; justify-content: space-between;
  background: var(--dust), linear-gradient(160deg, var(--board-2), var(--board)); border: 6px solid #6b4a1e; box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.35);
}
.board blockquote, .board p.chalk { margin: 0; font-size: 19px; line-height: 1.45; overflow-wrap: anywhere; }
.board p.chalk.small { font-size: 15px; color: var(--chalk-dim); margin-top: 8px; }
.board figcaption { color: var(--chalk-dim); font-size: 13px; margin-top: 12px; }
.board figcaption a { color: var(--chalk); }

/* ---- activity ---- */
.heat-wrap { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 18px; position: relative; }
.heat { width: min(100%, 250px); height: auto; }
.hm { fill: var(--hm0); }
.hm.l1 { fill: var(--hm1); } .hm.l2 { fill: var(--hm2); } .hm.l3 { fill: var(--hm3); } .hm.l4 { fill: var(--hm4); }
.hm-l { font: 600 13px/1 var(--font); fill: var(--muted); }
.legend { display: flex; align-items: center; gap: 5px; color: var(--muted); font-size: 13px; }
.legend i { display: inline-block; width: 14px; height: 14px; border-radius: 4px; background: var(--hm0); }
.legend i.l1 { background: var(--hm1); } .legend i.l2 { background: var(--hm2); } .legend i.l3 { background: var(--hm3); } .legend i.l4 { background: var(--hm4); }
.best { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-top: 20px; border-top: 1px dashed var(--line); padding-top: 16px; }
.best p { margin: 6px 0 0; overflow-wrap: anywhere; }
@media (min-width: 761px) {
  #activity { display: grid; grid-template-columns: auto 1fr; column-gap: 32px; align-items: start; }
  #activity > h2, #activity > .sub { grid-column: 1 / -1; }
  #activity .best { margin: 0; border-top: 0; padding: 0 0 0 28px; border-left: 1px dashed var(--line); }
}

/* ---- feeds ---- */
.feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.feed-item { border: 1px solid var(--line); background: var(--surface-2); border-radius: 12px; padding: 12px 14px; }
.feed-item h3 { font-size: 17px; color: var(--ink); text-transform: none; letter-spacing: 0; margin-bottom: 4px; overflow-wrap: anywhere; }
.feed-item p { margin: 0 0 8px; overflow-wrap: anywhere; }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; color: var(--muted); font-size: 13px; }
.vb { display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 22px; padding: 0 7px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-weight: 800; font-size: 12px; }
.more { margin: 14px 0 0; font-weight: 600; font-size: 15px; }

/* ---- launch-o-matic ---- */
.lm-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 16px; }
.lm-controls label { font-weight: 600; }
select {
  min-height: 44px; padding: 0 38px 0 14px; border-radius: 12px; border: 1px solid var(--field-line); background: var(--surface-2); color: var(--ink);
  font: 600 15px/1 var(--font); max-width: 100%;
}
.lm-board { min-height: 170px; position: relative; justify-content: flex-start; gap: 12px; }
.lm-board blockquote { font-size: 24px; }
.stamp {
  align-self: flex-end; border: 2px solid var(--chalk-gold); color: var(--chalk-gold) !important; padding: 3px 10px; border-radius: 6px; margin: 0 !important;
  font: 800 12px/1.2 var(--font); text-transform: uppercase; letter-spacing: 1.4px; transform: rotate(-3deg);
}

/* ---- pipeline ---- */
.pipeline { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; counter-reset: step; }
.pipeline li { position: relative; background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 14px; counter-increment: step; }
.pipeline li::before { content: counter(step); display: inline-flex; width: 26px; height: 26px; border-radius: 50%; align-items: center; justify-content: center; background: var(--accent); color: var(--accent-ink); font-weight: 800; font-size: 13px; margin-bottom: 8px; }
.pipeline b { display: block; font-size: 17px; }
.pipeline span { display: block; color: var(--muted); font-size: 14px; margin-top: 4px; }

/* ---- footer ---- */
.foot { max-width: 1120px; margin: 0 auto; padding: 22px 16px 46px; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); }
.foot img { vertical-align: middle; border-radius: 4px; box-shadow: 0 0 0 1px var(--field-line); }

/* ---- responsive ---- */
@media (max-width: 900px) {
  .pipeline { grid-template-columns: 1fr 1fr; }
  .pipeline li:last-child { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; text-align: left; }
  .hero-card { justify-self: stretch; width: 100%; display: grid; grid-template-columns: 96px 1fr; align-items: center; text-align: left; gap: 16px; padding: 16px; }
  .avatar { width: 96px; height: 96px; margin: 0; border-width: 3px; }
  .u-val { font-size: 20px; }
  .grid-2 { grid-template-columns: 1fr; }
  .card { padding: 18px 16px; }
  .brand span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .nav nav { -webkit-mask-image: linear-gradient(90deg, #000 80%, transparent); mask-image: linear-gradient(90deg, #000 80%, transparent); padding-right: 24px; }
  .lm-board blockquote { font-size: 20px; }
}
@media (max-width: 560px) {
  .peak { grid-template-columns: 1fr; text-align: left; }
  .peak-score { width: 88px; height: 88px; }
  .ps-num { font-size: 32px; }
  .boards { grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: 85%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; }
  .board { scroll-snap-align: start; }
  .feed-item:nth-child(n + 4) { display: none; }
}
@media (max-width: 480px) {
  .tiles { grid-template-columns: 1fr 1fr; }
  .tiles > .tile:last-child:nth-child(3n + 1), .tiles > .tile:last-child:nth-child(3n + 2) { grid-column: auto; }
  .tiles > .tile:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .tiles.small { grid-template-columns: 1fr 1fr 1fr; }
  .tiles.small > .tile:last-child:nth-child(odd) { grid-column: auto; }
  .tiles.small .t-num { font-size: 22px; }
  .tiles.small .t-label { font-size: 13px; }
  .t-num { font-size: 28px; }
  body { font-size: 16px; }
}

/* the Launch-o-matic's chalk "write" */
@keyframes chalkin { from { opacity: 0; transform: translateY(4px); filter: blur(1px); } to { opacity: 1; transform: none; filter: none; } }
.pop { animation: chalkin 0.35s ease-out; }
@media (prefers-reduced-motion: reduce) { .pop { animation: none; } .btn { transition: none; } }
