/* ==========================================================================
   Pinkie Promise Wiki - Sugarcube Corner scrapbook theme (v2 UI refresh)
   ========================================================================== */
:root {
  --bg: #fff7fb;
  --card: #ffffff;
  --text: #3b1d3a;
  --plum: #2a1229;
  --muted: #6a4a67;
  --muted-soft: #8a6a86;
  --primary: #ff5c8a;
  --primary-ink: #b51b50;
  --primary-ink-hover: #8f123e;
  --accent: #ffc542;
  --accent-soft: #fff3cc;
  --tint: #fdeaf3;
  --line: #ebd2e2;
  --line-strong: #dcb6cc;
  --ok: #12795a;
  --ok-soft: #e2f5ec;
  --on-dark: #e8cfdf;
  --glass: rgba(255, 255, 255, .92);
  --glass-dark: rgba(255, 255, 255, .1);
  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 3px rgba(59, 29, 58, .06);
  --shadow-md: 0 6px 18px -6px rgba(59, 29, 58, .14);
  --shadow-lg: 0 18px 40px -16px rgba(59, 29, 58, .22);
  --font-display: 'Baloo 2', system-ui, -apple-system, sans-serif;
  --font-body: 'Nunito', system-ui, -apple-system, sans-serif;
  --header-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.65;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

[hidden] { display: none !important; }

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--primary-ink);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

a:hover { color: var(--primary-ink-hover); }

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

::selection { background: var(--tint); color: var(--plum); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.18;
  color: var(--text);
  margin: 0 0 12px;
  font-weight: 700;
  text-wrap: balance;
}

h1 { font-size: clamp(34px, 4.6vw, 54px); font-weight: 800; letter-spacing: -0.015em; }
h2 { font-size: clamp(24px, 2.6vw, 31px); letter-spacing: -0.005em; }
h3 { font-size: 21px; }
h4 { font-size: 18px; }

h2[id], h3[id], [data-toc-source] h2, [data-toc-source] h3 { scroll-margin-top: calc(var(--header-h) + 20px); }

p { margin: 0 0 16px; max-width: 72ch; }

ul, ol { margin: 0 0 16px; padding-left: 24px; max-width: 72ch; }

li { margin-bottom: 8px; }

strong { font-weight: 800; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.86em;
  background: var(--tint);
  color: var(--plum);
  padding: 2px 6px;
  border-radius: 6px;
  border: 1px solid var(--line);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 8px;
  background: var(--text);
  color: var(--card);
  padding: 8px 16px;
  border-radius: var(--radius);
  z-index: 100;
}

.skip-link:focus { left: 16px; }

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px;
}

.wrap-narrow { max-width: 900px; }

/* ---------- Reading progress ---------- */
.read-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 60;
  pointer-events: none;
}

.read-progress span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transition: width .08s linear;
}

/* ---------- Signature motif: bakery awning stripe ---------- */
.bunting-bar {
  height: 8px;
  background: repeating-linear-gradient(90deg,
    var(--primary) 0 28px,
    var(--accent) 28px 44px,
    var(--text) 44px 56px,
    var(--card) 56px 72px);
  border-bottom: 2px solid var(--text);
}

/* ---------- Announcement bar ---------- */
.announce {
  background: var(--plum);
  color: var(--on-dark);
  font-size: 14px;
}

.announce-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 42px;
  padding-top: 6px;
  padding-bottom: 6px;
}

.announce-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--glass-dark);
  flex-shrink: 0;
}

.announce-text {
  margin: 0;
  max-width: none;
  flex: 1;
  min-width: 0;
}

.announce-text strong { color: var(--card); }
.announce-sub { color: var(--on-dark); }

.announce-link {
  flex-shrink: 0;
  color: var(--plum);
  background: var(--accent);
  font-weight: 800;
  font-size: 13px;
  text-decoration: none;
  padding: 5px 12px;
  border-radius: 999px;
}

.announce-link:hover { background: var(--accent-soft); color: var(--plum); }

/* ---------- Header ---------- */
.site-header {
  background: var(--glass);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 40;
  transition: box-shadow .2s ease;
}

.site-header.is-scrolled { box-shadow: 0 6px 20px -12px rgba(59, 29, 58, .22); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  line-height: 1.1;
  flex-shrink: 0;
}

.brand:hover { color: var(--primary-ink); }

.brand-mark {
  display: inline-flex;
  flex-shrink: 0;
  transition: transform .25s ease;
}

.brand:hover .brand-mark { transform: rotate(-8deg) scale(1.05); }

.site-nav {
  display: flex;
  align-items: center;
  gap: 2px;
}

.site-nav a {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 42px;
  padding: 8px 12px;
  border-radius: 999px;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
  transition: background-color .15s ease, color .15s ease;
}

.site-nav a:hover { background: var(--tint); color: var(--primary-ink); }

.site-nav a[aria-current="page"] {
  background: var(--tint);
  color: var(--primary-ink);
  box-shadow: inset 0 0 0 1.5px var(--line-strong);
}

.nav-count {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--ok);
  color: var(--card);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}

.site-nav .nav-cta {
  margin-left: 8px;
  background: var(--primary-ink);
  color: var(--card);
  padding: 8px 16px;
}

.site-nav .nav-cta:hover { background: var(--primary-ink-hover); color: var(--card); }

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 8px 14px;
  border: 2px solid var(--text);
  border-radius: 999px;
  background: var(--card);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 14px;
  cursor: pointer;
}

.nav-toggle-bars {
  display: inline-grid;
  gap: 3px;
  width: 16px;
}

.nav-toggle-bars span {
  display: block;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform .2s ease, opacity .2s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

/* ---------- Main spacing ---------- */
.site-main { padding-bottom: 72px; }

.section { padding: 72px 0 0; }

.section-head { margin-bottom: 28px; max-width: 760px; }

.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary-ink);
  background: var(--tint);
  border: 1px solid var(--line);
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 12px;
}

.section-sub {
  color: var(--muted);
  font-size: 17px;
  margin: 0;
}

/* ---------- Buttons ---------- */
.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 11px 22px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  border: 2px solid transparent;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}

.btn:active { transform: translateY(1px); }

.btn-lg { min-height: 52px; padding: 13px 26px; font-size: 16.5px; }

.btn-block { width: 100%; }

.btn-primary {
  background: var(--primary-ink);
  color: var(--card);
  border-color: var(--primary-ink);
  box-shadow: 0 4px 0 var(--plum);
}

.btn-primary:hover {
  background: var(--primary-ink-hover);
  border-color: var(--primary-ink-hover);
  color: var(--card);
  transform: translateY(-1px);
  box-shadow: 0 5px 0 var(--plum);
}

.btn-primary:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--plum); }

.btn-secondary {
  background: var(--card);
  color: var(--text);
  border-color: var(--text);
}

.btn-secondary:hover { background: var(--tint); color: var(--text); }

.btn-small {
  min-height: 36px;
  padding: 6px 14px;
  font-size: 14px;
}

/* ---------- Hero ---------- */
.hero-section {
  position: relative;
  padding: 48px 0 56px;
  background:
    radial-gradient(900px 420px at 0% 0%, var(--tint) 0%, transparent 70%),
    radial-gradient(700px 380px at 100% 10%, var(--accent-soft) 0%, transparent 70%),
    var(--bg);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.hero-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(var(--line-strong) 1.2px, transparent 1.2px);
  background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 75%);
  mask-image: linear-gradient(180deg, #000, transparent 75%);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: 56px;
  align-items: center;
}

.hero-badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 800;
  background: var(--accent);
  color: var(--plum);
  border: 1.5px solid var(--plum);
}

.status-pill-soft {
  background: var(--glass);
  color: var(--text);
  border: 1px solid var(--line-strong);
}

.pulse-dot, .live-dot {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--primary-ink);
  flex-shrink: 0;
}

.live-dot { background: var(--ok); display: inline-block; }

.pulse-dot::after, .live-dot::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid currentColor;
  color: inherit;
  opacity: 0;
  animation: pulse 1.8s ease-out infinite;
}

.pulse-dot::after { border-color: var(--primary-ink); }
.live-dot::after { border-color: var(--ok); }

@keyframes pulse {
  0% { transform: scale(.6); opacity: .9; }
  100% { transform: scale(1.6); opacity: 0; }
}

.hero-copy h1 {
  margin-bottom: 16px;
  background: linear-gradient(92deg, var(--plum) 0%, var(--primary-ink) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead {
  font-size: 18.5px;
  color: var(--muted);
  margin-bottom: 4px;
  max-width: 60ch;
}

.hero-btns { margin-top: 26px; }

.stat-strip {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1fr) minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 0;
  margin-top: 32px;
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.stat-cell {
  display: flex;
  flex-direction: column-reverse;
  justify-content: flex-end;
  gap: 2px;
  padding: 14px 16px;
  border-left: 1px solid var(--line);
}

.stat-cell:first-child { border-left: 0; }

.stat-label {
  display: block;
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.stat-value {
  display: block;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.2;
  color: var(--text);
}

.hero-visual {
  position: relative;
  display: grid;
  gap: 0;
}

.hero-polaroid {
  transform: rotate(1.6deg);
  z-index: 1;
}

.hero-polaroid { padding-bottom: 54px; }

.hero-polaroid figcaption { padding-right: 8px; }

.codes-ticket.codes-panel {
  position: relative;
  z-index: 2;
  margin: -26px 18px 0 -18px;
}

/* ---------- Codes panel ---------- */
.codes-panel {
  background: var(--card);
  border: 2px solid var(--text);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: 6px 6px 0 var(--plum);
}

.codes-ticket.codes-page-panel { margin: 0 0 28px; }

.codes-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-bottom: 12px;
}

.codes-panel-title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  margin: 0;
}

.codes-panel-date {
  font-size: 12px;
  font-weight: 800;
  color: var(--ok);
  background: var(--ok-soft);
  padding: 3px 10px;
  border-radius: 999px;
}

.code-chip-list { display: grid; gap: 8px; }

.code-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 10px 10px 12px;
  background: var(--bg);
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius-sm);
}

.code-chip-main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
  min-width: 0;
}

.code-token {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--plum);
  background: var(--accent-soft);
  padding: 3px 9px;
  border-radius: 7px;
  border: 1.5px solid var(--accent);
}

.code-reward {
  font-size: 14px;
  color: var(--muted);
  font-weight: 700;
}

.copy-code-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 38px;
  padding: 6px 16px;
  border-radius: 999px;
  border: 2px solid var(--primary-ink);
  background: var(--card);
  color: var(--primary-ink);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  flex-shrink: 0;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}

.copy-code-btn:hover { background: var(--primary-ink); color: var(--card); }

.copy-code-btn.is-copied {
  background: var(--ok);
  border-color: var(--ok);
  color: var(--card);
}

.codes-panel-foot {
  font-size: 14px;
  color: var(--muted);
  margin: 12px 0 0;
}

/* ---------- Polaroid frames ---------- */
.polaroid {
  position: relative;
  background: var(--card);
  border: 2px solid var(--text);
  border-radius: var(--radius);
  padding: 12px 12px 14px;
  box-shadow: var(--shadow-lg);
  margin: 0;
}

.polaroid::before,
.polaroid::after {
  content: "";
  position: absolute;
  top: -10px;
  width: 58px;
  height: 18px;
  background: var(--accent);
  border: 1px solid var(--line-strong);
  border-radius: 3px;
}

.polaroid::before { left: 22px; transform: rotate(-6deg); }
.polaroid::after { right: 22px; transform: rotate(6deg); }

.polaroid img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--tint);
}

.polaroid figcaption {
  margin-top: 10px;
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.45;
}

.tilt-left { transform: rotate(-1.4deg); }

/* ---------- Quick facts ---------- */
.facts-band { padding: 0; margin-top: -1px; }

.quick-facts {
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 5px solid var(--primary);
  border-radius: var(--radius);
  padding: 18px 22px;
  margin: 0 0 28px;
  box-shadow: var(--shadow-sm);
}

.quick-facts-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary-ink);
  margin: 0 0 10px;
}

.quick-facts-title::before {
  content: "";
  width: 18px;
  height: 18px;
  border-radius: 6px;
  background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232a1229' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M13 2 4 14h7l-1 8 9-12h-7z'/%3E%3C/svg%3E") center / 12px no-repeat;
}

.quick-facts-list {
  margin: 0 0 12px;
  padding-left: 20px;
  max-width: none;
}

.quick-facts-list li {
  margin-bottom: 6px;
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--text);
}

.quick-facts-list li::marker { color: var(--primary); }

.quick-facts-list li:last-child { margin-bottom: 0; }

.quick-facts-meta {
  margin: 0;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  max-width: none;
}

/* Home variant: horizontal 4-up fact grid that overlaps the hero edge */
.quick-facts-hero {
  position: relative;
  margin: -28px 0 0;
  padding: 20px 22px 16px;
  border-left: 1px solid var(--line);
  border-top: 5px solid var(--primary);
  box-shadow: var(--shadow-md);
}

.quick-facts-hero .quick-facts-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 0;
  list-style: none;
}

.quick-facts-hero .quick-facts-list li {
  margin: 0;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 14.5px;
}

.quick-facts-hero .quick-facts-list li > strong:first-child {
  display: block;
  color: var(--primary-ink);
  font-family: var(--font-display);
  font-size: 15.5px;
  line-height: 1.25;
  margin-bottom: 4px;
}

/* ---------- Hub (bento) ---------- */
.hub-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.hub-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.hub-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: var(--line-strong);
}

.hub-card:focus-within { border-color: var(--primary-ink); }

.hub-icon {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--tint);
  color: var(--primary-ink);
  margin-bottom: 14px;
}

.hub-icon svg { width: 22px; height: 22px; }

.hub-card-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted-soft);
  margin-bottom: 6px;
}

.hub-card h3 {
  font-size: 20px;
  margin: 0 0 8px;
}

.hub-card-link {
  color: var(--text);
  text-decoration: none;
}

.hub-card-link::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.hub-card:hover .hub-card-link { color: var(--primary-ink); }

.hub-card p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.hub-go {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  padding-top: 16px;
  font-weight: 800;
  font-size: 14px;
}

.hub-go::after {
  content: "";
  width: 16px;
  height: 16px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform .18s ease;
}

.hub-card:hover .hub-go::after { transform: translateX(4px); }

.hub-card-feature {
  grid-column: span 2;
  background:
    radial-gradient(520px 280px at 100% 0%, var(--primary-ink-hover), transparent 72%),
    linear-gradient(135deg, var(--text) 0%, var(--plum) 100%);
  border-color: var(--plum);
  color: var(--on-dark);
  padding: 28px;
}

.hub-card-feature .hub-icon { background: var(--glass-dark); color: var(--accent); }
.hub-card-feature .hub-card-tag { color: var(--accent); }
.hub-card-feature h3 { font-size: 26px; }
.hub-card-feature .hub-card-link { color: var(--card); }
.hub-card-feature:hover .hub-card-link { color: var(--tint); }
.hub-card-feature p { color: var(--on-dark); font-size: 16px; max-width: 56ch; }
.hub-card-feature .hub-go { color: var(--accent); }
.hub-card-feature:hover { border-color: var(--plum); }

.hub-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
  max-width: none;
}

.hub-chips li {
  margin: 0;
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--glass-dark);
  background: var(--glass-dark);
  color: var(--card);
  font-size: 13px;
  font-weight: 700;
}

.hub-card-codes {
  background: linear-gradient(160deg, var(--accent-soft) 0%, var(--card) 70%);
  border-color: var(--accent);
}

.hub-card-codes .hub-icon { background: var(--accent); color: var(--plum); }
.hub-card-codes .hub-go { color: var(--primary-ink); }

/* ---------- Split feature ---------- */
.split-feature {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 56px;
  align-items: center;
}

.promise-card {
  position: relative;
  background: var(--card);
  border: 2px dashed var(--primary-ink);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin-top: 20px;
}

.promise-card h3 { margin-bottom: 8px; color: var(--primary-ink); }

.promise-rules {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: rule;
}

.promise-rules li {
  position: relative;
  padding: 10px 0 10px 40px;
  border-bottom: 1px solid var(--line);
  margin: 0;
  font-size: 15.5px;
}

.promise-rules li::before {
  counter-increment: rule;
  content: counter(rule);
  position: absolute;
  left: 0;
  top: 11px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--primary-ink);
  color: var(--card);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 15px;
}

.promise-rules li:last-child { border-bottom: 0; padding-bottom: 0; }

/* ---------- Tables ---------- */
.table-wrap {
  overflow-x: auto;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  margin: 16px 0 24px;
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 15.5px;
}

th, td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

thead th {
  background: var(--tint);
  color: var(--text);
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
  position: sticky;
  top: 0;
}

tbody tr:last-child td { border-bottom: 0; }

tbody tr:nth-child(even) { background: var(--bg); }

tbody tr:hover { background: var(--tint); }

.robux {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 800;
  white-space: nowrap;
}

.robux::before {
  content: "";
  width: 14px;
  height: 14px;
  border-radius: 4px;
  border: 2.5px solid var(--text);
  transform: rotate(15deg);
}

.verdict-pill {
  display: inline-block;
  padding: 3px 11px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 800;
  background: var(--accent-soft);
  color: var(--text);
  border: 1px solid var(--accent);
  white-space: nowrap;
}

.verdict-good { background: var(--ok-soft); border-color: var(--ok); color: var(--ok); }

.verdict-wait {
  background: var(--tint);
  border-color: var(--primary);
  color: var(--primary-ink);
}

/* ---------- Roadmap timeline ---------- */
.roadmap {
  position: relative;
  list-style: none;
  padding: 0;
  margin: 0;
  max-width: none;
  display: grid;
  gap: 14px;
}

.roadmap::before {
  content: "";
  position: absolute;
  left: 25px;
  top: 24px;
  bottom: 24px;
  width: 3px;
  background: repeating-linear-gradient(180deg, var(--line-strong) 0 8px, transparent 8px 14px);
}

.roadmap-step {
  position: relative;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
  margin: 0;
}

.roadmap-num {
  position: relative;
  z-index: 1;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: var(--text);
  color: var(--accent);
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 6px var(--bg);
}

.roadmap-step-ch2 .roadmap-num { background: var(--primary-ink); color: var(--card); }

.roadmap-body {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 22px;
  box-shadow: var(--shadow-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}

.roadmap-step:hover .roadmap-body { border-color: var(--line-strong); box-shadow: var(--shadow-md); }

.roadmap-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted-soft);
  margin-bottom: 2px;
}

.roadmap-step-ch2 .roadmap-tag { color: var(--primary-ink); }

.roadmap-body h3 { margin-bottom: 6px; font-size: 20px; }

.roadmap-body p { color: var(--muted); }

.roadmap-body p:last-child { margin-bottom: 0; }

/* ---------- Prose ---------- */
.prose-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 36px 40px;
  box-shadow: var(--shadow-sm);
  min-width: 0;
}

.prose-card > *:last-child { margin-bottom: 0; }

.prose-card h2 {
  margin-top: 40px;
  padding-top: 8px;
  position: relative;
}

.prose-card h2::before {
  content: "";
  display: block;
  width: 40px;
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  margin-bottom: 14px;
}

.prose-card h2:first-child { margin-top: 0; }

.prose-card h3 { margin-top: 28px; }

.prose-card li::marker { color: var(--primary-ink); font-weight: 800; }

.prose-card ol > li { padding-left: 4px; }

.prose-card blockquote {
  margin: 20px 0;
  padding: 16px 20px;
  background: var(--accent-soft);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--text);
  max-width: 72ch;
}

.prose-card blockquote p:last-child { margin-bottom: 0; }

.prose-card img {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  margin: 8px 0 20px;
}

.prose-card hr {
  border: 0;
  height: 1px;
  background: var(--line);
  margin: 32px 0;
}

.prose-card .faq-list { margin: 20px 0 24px; }

.prose-card-feature {
  column-count: 2;
  column-gap: 56px;
  column-rule: 1px dashed var(--line);
}

.prose-card-feature > h2 { column-span: all; margin-bottom: 20px; }

.prose-card-feature h3 {
  margin-top: 24px;
  font-size: 19px;
  break-after: avoid;
  color: var(--primary-ink);
}

.prose-card-feature > h3:first-of-type { margin-top: 0; }

.prose-card-feature li,
.prose-card-feature p { break-inside: avoid; }

.prose-card-tables { margin-bottom: 32px; }

/* ---------- FAQ ---------- */
.faq-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.6fr);
  gap: 48px;
  align-items: start;
}

.faq-intro {
  position: sticky;
  top: calc(var(--header-h) + 24px);
}

.faq-ask { margin-top: 20px; }

.faq-list { display: grid; gap: 10px; }

.faq-item {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}

.faq-item[open] { border-color: var(--line-strong); box-shadow: var(--shadow-md); }

.faq-item summary {
  padding: 16px 20px;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.faq-item summary:hover { color: var(--primary-ink); }

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: "";
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--tint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b51b50' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 14px no-repeat;
  transition: transform .2s ease, background-color .2s ease;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
  background-color: var(--accent-soft);
}

.faq-answer {
  padding: 0 20px 18px;
  color: var(--muted);
}

.faq-answer p:last-child { margin-bottom: 0; }

/* ---------- Inner page ---------- */
.breadcrumb {
  padding: 22px 0 6px;
  font-size: 14px;
  color: var(--muted);
}

.breadcrumb ol {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: none;
}

.breadcrumb li {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.breadcrumb li + li::before {
  content: "";
  width: 6px;
  height: 6px;
  border-right: 2px solid var(--muted-soft);
  border-top: 2px solid var(--muted-soft);
  transform: rotate(45deg);
}

.breadcrumb a { font-weight: 700; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb [aria-current] { font-weight: 700; color: var(--text); }

.page-head {
  padding: 12px 0 28px;
  margin-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.page-head h1 {
  font-size: clamp(32px, 3.8vw, 46px);
  margin-bottom: 12px;
}

.page-lead {
  font-size: 18.5px;
  color: var(--muted);
  margin-bottom: 14px;
}

.page-meta {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  color: var(--ok);
  font-weight: 700;
  margin: 0;
  padding: 6px 12px;
  background: var(--ok-soft);
  border-radius: 10px;
  max-width: 100%;
}

.page-head-media {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  gap: 48px;
  align-items: center;
}

.page-hero-figure { transform: rotate(1.4deg); }

/* Two-column article layout */
.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 36px;
  align-items: start;
}

.article-main { min-width: 0; }

.article-side { min-width: 0; height: 100%; }

.side-sticky {
  position: sticky;
  top: calc(var(--header-h) + 20px);
  display: grid;
  gap: 16px;
}

.toc-card,
.side-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 16px 14px;
  box-shadow: var(--shadow-sm);
}

.toc-title,
.side-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--primary-ink);
  margin: 0 0 8px;
}

.toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
  max-width: none;
  max-height: calc(100vh - 360px);
  overflow-y: auto;
}

.toc-list li { margin: 0; }

.toc-list a {
  display: block;
  padding: 6px 10px;
  border-left: 3px solid var(--line);
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
  transition: color .15s ease, border-color .15s ease, background-color .15s ease;
}

.toc-list a:hover { color: var(--primary-ink); background: var(--bg); }

.toc-list a.is-active {
  color: var(--primary-ink);
  border-left-color: var(--primary-ink);
  background: var(--tint);
}

.toc-mobile {
  display: none;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin: 0 0 20px;
  box-shadow: var(--shadow-sm);
}

.toc-mobile summary {
  padding: 14px 16px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 16px;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.toc-mobile summary::-webkit-details-marker { display: none; }

.toc-mobile summary::after {
  content: "";
  width: 10px;
  height: 10px;
  border-right: 2.5px solid var(--primary-ink);
  border-bottom: 2.5px solid var(--primary-ink);
  transform: rotate(45deg) translateY(-3px);
  transition: transform .2s ease;
}

.toc-mobile[open] summary::after { transform: rotate(-135deg) translateY(-3px); }

.toc-mobile .toc-list { padding: 0 12px 12px; max-height: none; }

.side-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--line);
}

.side-code .code-token { font-size: 13.5px; padding: 2px 7px; }

.copy-mini { min-height: 32px; padding: 4px 12px; font-size: 13px; }

.side-more {
  display: inline-block;
  margin-top: 10px;
  font-size: 14px;
  font-weight: 800;
}

/* ---------- Badge tracker ---------- */
.tracker-panel {
  position: sticky;
  top: calc(var(--header-h) + 10px);
  z-index: 20;
  background: var(--glass);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 2px solid var(--text);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin: 0 0 24px;
  box-shadow: 6px 6px 0 var(--plum);
}

.tracker-stats {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  margin-bottom: 14px;
}

.tracker-heading { margin: 0; font-size: 15px; letter-spacing: .06em; text-transform: uppercase; color: var(--primary-ink); }

.tracker-count {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  line-height: 1.2;
}

.tracker-bars {
  display: grid;
  grid-template-columns: repeat(2, minmax(140px, 1fr));
  gap: 14px;
  flex: 1;
  min-width: 260px;
  max-width: 460px;
}

.tracker-bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 12.5px;
  font-weight: 800;
  color: var(--muted);
  margin-bottom: 4px;
}

.tracker-bar-label b { color: var(--text); }

.bar {
  display: block;
  height: 10px;
  border-radius: 999px;
  background: var(--tint);
  border: 1px solid var(--line);
  overflow: hidden;
}

.bar-fill {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--primary), var(--primary-ink));
  transition: width .35s ease;
}

.bar-fill-alt { background: linear-gradient(90deg, var(--accent-soft), var(--accent)); }

.tracker-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.filter-btn {
  min-height: 36px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1.5px solid var(--line-strong);
  background: var(--card);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease;
}

.filter-btn:hover { border-color: var(--text); }

.filter-btn.is-active {
  background: var(--text);
  border-color: var(--text);
  color: var(--card);
}

.tracker-search {
  min-height: 40px;
  padding: 8px 14px 8px 38px;
  border-radius: 999px;
  border: 1.5px solid var(--line-strong);
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--text);
  background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236a4a67' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") 13px center / 16px no-repeat;
  min-width: 200px;
  flex: 1;
}

.badge-check {
  width: 22px;
  height: 22px;
  accent-color: var(--primary-ink);
  cursor: pointer;
}

tr.is-done td { opacity: 0.55; }
tr.is-done td strong { text-decoration: line-through; text-decoration-color: var(--primary); }

.jump-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  padding: 12px 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.jump-nav-label {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
  margin-right: 4px;
}

.jump-nav a,
.filter-jump {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--bg);
  border: 1.5px solid var(--line-strong);
  color: var(--primary-ink);
  font-size: 13.5px;
  font-weight: 800;
  text-decoration: none;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}

.jump-nav a:hover,
.filter-jump:hover {
  background: var(--primary-ink);
  border-color: var(--primary-ink);
  color: var(--card);
}

.filter-jump {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--text);
}

.endings-guide.is-ending-focus {
  padding: 16px 18px;
  margin: -16px -18px 24px;
  border-radius: var(--radius);
  background: var(--bg);
  border: 2px solid var(--primary);
}

/* ---------- Related guides ---------- */
.related-strip {
  margin-top: 56px;
  padding-top: 36px;
  border-top: 1px solid var(--line);
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.related-card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 44px 16px 18px;
  box-shadow: var(--shadow-sm);
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}

.related-card::after {
  content: "";
  position: absolute;
  right: 16px;
  top: 20px;
  width: 18px;
  height: 18px;
  background: var(--primary-ink);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform .15s ease;
}

.related-card a {
  font-family: var(--font-display);
  font-size: 17.5px;
  font-weight: 700;
  line-height: 1.25;
  color: var(--text);
  text-decoration: none;
}

.related-card a::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.related-card:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}

.related-card:hover::after { transform: translateX(3px); }
.related-card:hover a { color: var(--primary-ink); }

.related-card p {
  font-size: 14px;
  color: var(--muted);
  margin: 6px 0 0;
  line-height: 1.5;
}

/* ---------- Community ---------- */
.engage-section {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
}

.engage-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 20px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--line);
}

.engage-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.engage-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1.5px solid var(--line-strong);
  background: var(--card);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: border-color .15s ease, color .15s ease, background-color .15s ease;
}

.engage-btn:hover { border-color: var(--primary-ink); color: var(--primary-ink); }

.engage-btn[data-gf-liked],
.engage-btn[aria-pressed="true"] {
  background: var(--primary-ink);
  border-color: var(--primary-ink);
  color: var(--card);
}

.engage-msg {
  font-size: 14px;
  color: var(--primary-ink);
  font-weight: 800;
}

.comment-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 12px 16px;
  margin-bottom: 24px;
}

.comment-form > .reply-banner,
.comment-form > div:last-child { grid-column: 1 / -1; }

.comment-form label {
  display: block;
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 4px;
}

.comment-form input,
.comment-form textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--line-strong);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  transition: border-color .15s ease, background-color .15s ease;
}

.comment-form input:focus,
.comment-form textarea:focus { border-color: var(--primary-ink); background: var(--card); }

.comment-form textarea { min-height: 96px; resize: vertical; }

.reply-banner {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  background: var(--accent-soft);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 800;
}

.comment-form[data-gf-replying] .reply-banner { display: flex; }

.comment-list { display: grid; gap: 12px; }

.comment-list[data-gf-empty]::before {
  content: "No notes posted yet. Found a new Chapter 2 secret or want to share your fastest fuse route? Drop a tip above.";
  display: block;
  padding: 16px;
  background: var(--bg);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 15px;
}

.comment-item {
  padding: 16px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

.comment-item[data-gf-owner] { background: var(--accent-soft); border-color: var(--accent); }

.comment-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 14px;
}

.comment-name { font-weight: 800; color: var(--text); }

.comment-owner-tag {
  background: var(--text);
  color: var(--accent);
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
}

.comment-time { color: var(--muted); font-size: 12px; }

.comment-text { margin: 0 0 8px; }

.comment-reply-btn {
  background: none;
  border: 0;
  padding: 4px 0;
  color: var(--primary-ink);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.comment-replies {
  margin-top: 12px;
  padding-left: 16px;
  border-left: 3px solid var(--primary);
  display: grid;
  gap: 8px;
}

/* ---------- Ads (Strictly outside first screen, CLS-safe) ---------- */
.ad-slot {
  margin: 28px 0 0;
  padding: 12px 14px 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  text-align: center;
  overflow: hidden;
}

.article-main .ad-slot {
  margin: 24px 0 0;
}

.ad-label {
  margin: 0 0 8px;
  max-width: none;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-soft);
}

.ad-frame-banner,
.ad-frame-rect,
.ad-frame-native {
  margin: 0 auto;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.ad-frame-banner { width: 320px; min-height: 50px; }
.ad-frame-rect { width: 300px; min-height: 250px; }
.ad-frame-native { width: 100%; min-height: 120px; }

.ad-slot iframe {
  border: 0;
  display: block;
  margin: 0 auto;
  max-width: 100%;
}

/* ---------- Footer ---------- */
.site-footer {
  position: relative;
  background: var(--plum);
  color: var(--on-dark);
  padding: 56px 0 32px;
  margin-top: 56px;
}

.site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: repeating-linear-gradient(90deg,
    var(--primary) 0 28px,
    var(--accent) 28px 44px,
    var(--bg) 44px 60px);
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 40px;
}

.brand-footer { color: var(--card); margin-bottom: 12px; }
.brand-footer:hover { color: var(--accent); }

.footer-note { color: var(--on-dark); font-size: 14px; margin-bottom: 12px; }

.footer-heading {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 800;
  color: var(--accent);
  margin: 0 0 12px;
}

.footer-links { list-style: none; padding: 0; margin: 0; }

.footer-links li { margin-bottom: 8px; }

.footer-links a {
  color: var(--card);
  text-decoration: none;
  font-size: 14.5px;
  font-weight: 700;
}

.footer-links a:hover { color: var(--accent); text-decoration: underline; }

.footer-bottom {
  margin-top: 36px;
  padding-top: 18px;
  border-top: 1px solid var(--glass-dark);
  font-size: 14px;
  color: var(--on-dark);
}

.footer-bottom p { margin: 0; max-width: none; }

/* ---------- Back to top ---------- */
.to-top {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 50;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--text);
  color: var(--card);
  border: 2px solid var(--card);
  box-shadow: var(--shadow-lg);
  cursor: pointer;
  transition: transform .15s ease, background-color .15s ease;
}

.to-top:hover { background: var(--primary-ink); transform: translateY(-2px); }

/* ---------- 404 ---------- */
.notfound-box {
  background: var(--card);
  border: 2px solid var(--text);
  border-radius: var(--radius-lg);
  padding: 40px;
  margin-top: 40px;
  box-shadow: 8px 8px 0 var(--plum);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1100px) {
  .site-nav a { padding: 8px 9px; font-size: 14.5px; }
  .site-nav .nav-cta { margin-left: 4px; }
}

@media (max-width: 1024px) {
  :root { --header-h: 62px; }

  .nav-toggle { display: inline-flex; }

  .site-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--card);
    border-bottom: 2px solid var(--text);
    box-shadow: 0 18px 30px -18px rgba(59, 29, 58, .22);
    padding: 10px 20px 18px;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
  }

  .site-nav.is-open { display: flex; }

  .site-nav a {
    min-height: 48px;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    font-size: 16px;
  }

  .site-nav .nav-cta {
    margin: 10px 0 0;
    justify-content: center;
    border-radius: 999px;
  }

  .article-layout { grid-template-columns: minmax(0, 1fr); }
  .article-side { display: none; }
  .toc-mobile { display: block; }
  .toc-mobile[hidden] { display: none !important; }

  .hub-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hub-card-codes { grid-column: span 2; }

  .quick-facts-hero .quick-facts-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  .section { padding-top: 56px; }

  .hero-section { padding: 32px 0 48px; }

  .hero-grid,
  .split-feature,
  .footer-grid,
  .faq-layout,
  .page-head-media {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }

  .hero-visual { max-width: 560px; }

  .faq-intro { position: static; }

  .page-head-media .page-hero-figure { max-width: 520px; }

  .prose-card-feature { column-count: 1; }

  .stat-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-cell:nth-child(3) { border-left: 0; }
  .stat-cell:nth-child(n+3) { border-top: 1px solid var(--line); }

  .tracker-panel { position: static; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }

  .wrap { padding: 0 16px; }

  .announce-sub { display: none; }
  .announce-inner { gap: 10px; font-size: 13px; }

  .brand { font-size: 19px; }
  .brand-mark svg { width: 30px; height: 30px; }
  .nav-toggle-label { display: none; }
  .nav-toggle { padding: 8px 12px; }

  .hero-lead, .page-lead { font-size: 17px; }

  .btn-row .btn { width: 100%; }

  .codes-ticket.codes-panel { order: -1; margin: 0 0 22px; box-shadow: 4px 4px 0 var(--plum); }
  .hero-polaroid { padding-bottom: 14px; }
  .hero-polaroid, .tilt-left, .page-hero-figure { transform: none; }

  .quick-facts-hero { margin-top: -20px; padding: 16px; }
  .quick-facts-hero .quick-facts-list { grid-template-columns: minmax(0, 1fr); }

  .hub-grid { grid-template-columns: minmax(0, 1fr); }
  .hub-card-feature, .hub-card-codes { grid-column: auto; }
  .hub-card-feature { padding: 22px; }
  .hub-card-feature h3 { font-size: 22px; }

  .roadmap::before { left: 19px; }
  .roadmap-step { grid-template-columns: 40px minmax(0, 1fr); gap: 12px; }
  .roadmap-num { width: 40px; height: 40px; font-size: 19px; border-radius: 12px; }
  .roadmap-body { padding: 16px; }

  .prose-card { padding: 22px 18px; border-radius: var(--radius); }

  .code-chip { flex-direction: column; align-items: stretch; }
  .copy-code-btn { width: 100%; }
  .copy-mini { width: auto; }

  .related-grid { grid-template-columns: minmax(0, 1fr); }

  .comment-form { grid-template-columns: minmax(0, 1fr); }
  .engage-section { padding: 20px 16px; }

  .tracker-bars { min-width: 0; max-width: none; grid-template-columns: minmax(0, 1fr); width: 100%; }

  /* Stacked "card" tables on phones (labels injected by script.js) */
  .table-stack table, .table-stack thead, .table-stack tbody, .table-stack tr, .table-stack td { display: block; width: 100%; }
  .table-stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .table-stack tr { padding: 12px 14px; border-bottom: 1px solid var(--line); }
  .table-stack tbody tr:last-child { border-bottom: 0; }
  .table-stack td { border: 0; padding: 4px 0; }
  .table-stack td[data-label]::before {
    content: attr(data-label);
    display: block;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--muted-soft);
    margin-bottom: 1px;
  }
  .table-stack td:first-child { font-size: 17px; }
  .table-stack tr { position: relative; }
  .table-stack td.td-primary { font-size: 17px; padding-top: 2px; }
  .table-stack td.td-primary::before,
  .table-stack td.td-check::before { display: none; }
  .table-stack td.td-num { display: none; }
  .table-stack td.td-short {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px;
    width: auto;
    margin-right: 14px;
    font-weight: 700;
  }
  .table-stack td.td-short::before { display: inline; margin: 0; }
  .table-stack tr:has(.td-check) { padding-right: 52px; }
  .table-stack td.td-check {
    position: absolute;
    top: 12px;
    right: 14px;
    width: auto;
    padding: 0;
  }
  .table-stack .badge-check { width: 26px; height: 26px; }

  .to-top { right: 14px; bottom: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- Live Roblox Telemetry ---------- */
.hero-live {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  min-height: 44px;
  margin: 14px 0 18px;
  padding: 10px 14px;
  background: var(--card);
  border: 2px solid var(--text);
  border-radius: var(--radius-sm);
  box-shadow: 4px 4px 0 var(--plum);
  font-size: 13px;
  color: var(--muted);
}
.hero-live-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}
.hero-live[data-live-ready="1"] .hero-live-dot,
.live-board[data-live-ready="1"] .hero-live-dot,
.side-live-card .hero-live-dot {
  background: var(--ok);
  box-shadow: 0 0 0 0 rgba(18, 121, 90, 0.45);
  animation: pp-live-pulse 2.1s infinite;
}
@keyframes pp-live-pulse {
  0% { box-shadow: 0 0 0 0 rgba(18, 121, 90, 0.45); }
  70% { box-shadow: 0 0 0 7px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.hero-live-main { flex: 1 1 200px; min-width: 0; line-height: 1.4; }
.hero-live-main strong { color: var(--primary-ink); font-weight: 800; }
.hero-live-spark { display: inline-flex; align-items: center; height: 18px; }
.hero-live-spark:empty { display: none; }
.hero-live-link {
  margin-left: auto;
  color: var(--primary-ink);
  font-weight: 800;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.side-live-card { margin-bottom: 14px; }
.side-live-count { font-size: 14px; margin: 0 0 6px; color: var(--muted); }
.side-live-count strong { color: var(--ok); font-size: 17px; font-weight: 800; }
.live-board {
  margin: 0 0 28px;
  padding: 20px;
  background: var(--bg);
  border: 2px solid var(--text);
  border-radius: var(--radius);
  box-shadow: 5px 5px 0 var(--plum);
}
.live-board-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.live-board-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--primary-ink);
  font-weight: 800;
}
.live-board-updated { font-size: 12px; color: var(--muted); font-weight: 700; }
.live-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}
.live-kpi {
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}
.live-kpi-label { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); margin: 0 0 4px; }
.live-kpi-val { font-family: var(--font-display); font-size: 24px; font-weight: 800; color: var(--text); line-height: 1.2; margin: 0; font-variant-numeric: tabular-nums; }
.live-kpi-val.is-accent { color: var(--primary-ink); }
.live-kpi-sub { font-size: 12px; color: var(--muted); margin: 4px 0 0; }
.live-chart-box {
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 14px;
}
.live-chart-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.live-chart-title { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text); margin: 0; }
.live-range-tabs { display: inline-flex; gap: 6px; }
.live-range-btn {
  font-size: 12px;
  font-weight: 800;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1.5px solid var(--line-strong);
  background: var(--bg);
  color: var(--muted);
  cursor: pointer;
}
.live-range-btn[aria-pressed="true"] {
  background: var(--primary-ink);
  border-color: var(--primary-ink);
  color: var(--card);
}
.live-chart-svg { width: 100%; height: 150px; display: block; }
.live-chart-foot {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}
@media (max-width: 720px) {
  .live-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* SSR live-stats snapshot summary & rolling 7-day UTC daily peak table */
.live-snapshot-note {
  font-size: 0.92rem;
  line-height: 1.55;
  margin: 0.85rem 0 1.4rem;
  padding: 11px 14px;
  background: color-mix(in srgb, currentColor 5%, transparent);
  border: 1px solid color-mix(in srgb, currentColor 16%, transparent);
  border-left: 3px solid currentColor;
  border-radius: 8px;
}
.live-table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 1rem 0 1.5rem;
}
.live-daily-table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
  margin: 0;
}
.live-daily-table th,
.live-daily-table td {
  border: 1px solid color-mix(in srgb, currentColor 18%, transparent);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}
.live-daily-table thead th {
  background: color-mix(in srgb, currentColor 7%, transparent);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.live-daily-table tbody tr:nth-child(even) {
  background: color-mix(in srgb, currentColor 3%, transparent);
}
