/* ==========================================================================
   IIS Debate Hub — visual identity
   Forest green + champagne gold (from the club emblem), ivory paper,
   Fraunces (display serif) + Plus Jakarta Sans (text).
   ========================================================================== */

:root {
  --forest-950: #07150f;
  --forest-900: #0c2219;
  --forest-800: #123326;
  --forest-700: #1a4533;
  --forest-600: #245a43;
  --gold-300: #ead7a8;
  --gold-400: #dcc085;
  --gold-500: #c9a45c;
  --gold-600: #a9843f;

  --bg: #f7f3ea;
  --bg-soft: #efe9dc;
  --surface: #fffdf8;
  --surface-2: #f8f4ec;
  --ink: #14231c;
  --ink-2: #3d4d45;
  --muted: #6b7a72;
  --line: #e3dccb;
  --line-strong: #d3c9b2;
  --accent: var(--forest-700);
  --accent-ink: #fffdf8;
  --gold: var(--gold-600);
  --focus: #c9a45c;
  --danger: #b4412f;
  --danger-bg: #fbe9e4;
  --ok: #2f7a4f;
  --ok-bg: #e5f3ea;

  --lv-elementary: #2f7a4f;
  --lv-intermediate: #2c5f8a;
  --lv-advanced: #8a3f5c;

  --shadow-sm: 0 1px 2px rgba(20, 35, 28, .06), 0 1px 1px rgba(20, 35, 28, .04);
  --shadow: 0 10px 30px -12px rgba(20, 35, 28, .18), 0 2px 6px rgba(20, 35, 28, .05);
  --shadow-lg: 0 30px 60px -20px rgba(7, 21, 15, .35);

  --radius: 18px;
  --radius-sm: 12px;
  --display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --text: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --max: 1180px;
  --gutter: clamp(16px, 4vw, 32px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #08140f; --bg-soft: #0c1c15; --surface: #0f221a; --surface-2: #132a20;
    --ink: #eee8da; --ink-2: #c9c4b6; --muted: #8f9a92; --line: #1f3a2e; --line-strong: #2b4a3c;
    --accent: var(--gold-400); --accent-ink: #0c2219; --gold: var(--gold-400);
    --danger: #f08a75; --danger-bg: #3a1a14; --ok: #7fd3a0; --ok-bg: #12301f;
    --lv-elementary: #7fd3a0; --lv-intermediate: #8cc2ef; --lv-advanced: #eda3c1;
    --shadow: 0 10px 30px -12px rgba(0, 0, 0, .6); --shadow-lg: 0 30px 60px -20px rgba(0, 0, 0, .7);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #08140f; --bg-soft: #0c1c15; --surface: #0f221a; --surface-2: #132a20;
  --ink: #eee8da; --ink-2: #c9c4b6; --muted: #8f9a92; --line: #1f3a2e; --line-strong: #2b4a3c;
  --accent: var(--gold-400); --accent-ink: #0c2219; --gold: var(--gold-400);
  --danger: #f08a75; --danger-bg: #3a1a14; --ok: #7fd3a0; --ok-bg: #12301f;
  --lv-elementary: #7fd3a0; --lv-intermediate: #8cc2ef; --lv-advanced: #eda3c1;
  --shadow: 0 10px 30px -12px rgba(0, 0, 0, .6); --shadow-lg: 0 30px 60px -20px rgba(0, 0, 0, .7);
  color-scheme: dark;
}

/* ───────────── base ───────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--ink); font: 400 16px/1.65 var(--text);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
main { flex: 1; outline: none; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 600; line-height: 1.12; letter-spacing: -.015em; margin: 0 0 .5em; text-wrap: balance; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--gold-300); color: var(--forest-900); }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--surface); padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: clamp(56px, 8vw, 104px) 0; }
.section-tight { padding: clamp(36px, 5vw, 56px) 0; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font: 600 12px/1 var(--text); letter-spacing: .18em; text-transform: uppercase; color: var(--gold); margin-bottom: 16px; }
.eyebrow::before { content: ''; width: 28px; height: 1px; background: currentColor; }
.h-xl { font-size: clamp(38px, 6.2vw, 74px); }
.h-lg { font-size: clamp(30px, 4.2vw, 48px); }
.h-md { font-size: clamp(22px, 2.6vw, 30px); }
.lead { font-size: clamp(17px, 1.6vw, 19px); color: var(--ink-2); max-width: 62ch; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }
.stack > * + * { margin-top: 16px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }

/* ───────────── buttons & inputs ───────────── */
.btn {
  --b: var(--accent); --c: var(--accent-ink);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 0 22px; border-radius: 999px; border: 1px solid var(--b);
  background: var(--b); color: var(--c); font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.btn:active { transform: none; }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-gold { --b: var(--gold-500); --c: var(--forest-900); }
.btn-gold:hover { --b: var(--gold-400); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-danger { --b: var(--danger); --c: #fff; }
.btn-quiet { background: transparent; border-color: transparent; color: var(--ink-2); padding: 0 12px; }
.btn-quiet:hover { background: var(--surface-2); box-shadow: none; }
.btn-sm { min-height: 38px; padding: 0 16px; font-size: 14px; }
.btn-xs { min-height: 32px; padding: 0 12px; font-size: 13px; }
.btn-lg { min-height: 54px; padding: 0 28px; font-size: 16px; }
.btn-block { width: 100%; }
.on-dark .btn-ghost { color: #f3ecdc; border-color: rgba(234, 215, 168, .35); }
.on-dark .btn-ghost:hover { border-color: var(--gold-300); }

.icon-btn { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; font-size: 18px; color: var(--ink); }
.icon-btn:hover { border-color: var(--line-strong); }

.field { display: grid; gap: 7px; }
.field > span, .label { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.field small { color: var(--muted); font-size: 13px; }
.input, .select, .textarea {
  width: 100%; min-height: 48px; padding: 11px 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); transition: border-color .15s, box-shadow .15s;
}
.textarea { min-height: 110px; resize: vertical; line-height: 1.55; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--gold-500); box-shadow: 0 0 0 4px rgba(201, 164, 92, .18); }
.select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 21px, calc(100% - 15px) 21px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 38px; }
.form-grid { display: grid; gap: 18px; }
.form-grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-error { color: var(--danger); background: var(--danger-bg); border-radius: var(--radius-sm); padding: 10px 14px; font-size: 14px; }
.form-error:empty { display: none; }

/* level picker (registration) */
.level-pick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.level-pick label { position: relative; cursor: pointer; }
.level-pick input { position: absolute; opacity: 0; inset: 0; }
.level-pick .lp { display: grid; gap: 4px; padding: 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--line-strong); background: var(--surface); transition: .15s; height: 100%; }
.level-pick .lp strong { font-size: 15px; }
.level-pick .lp span { font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.level-pick input:checked + .lp { border-color: var(--gold-500); background: color-mix(in srgb, var(--gold-500) 9%, var(--surface)); box-shadow: 0 0 0 3px rgba(201, 164, 92, .18); }
.level-pick input:focus-visible + .lp { outline: 2px solid var(--focus); outline-offset: 2px; }

/* ───────────── navigation ───────────── */
.nav { position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid transparent; transition: border-color .2s, background .2s; }
.nav.scrolled { border-bottom-color: var(--line); }
.nav.over-hero:not(.scrolled) { background: transparent; }
.nav.over-hero:not(.scrolled) .nav-links a, .nav.over-hero:not(.scrolled) .brand { color: #f3ecdc; }
.nav.over-hero:not(.scrolled) .icon-btn { background: rgba(255, 255, 255, .06); border-color: rgba(234, 215, 168, .25); color: #f3ecdc; }
.nav.over-hero:not(.scrolled) .account-pill { background: rgba(255, 255, 255, .06); border-color: rgba(234, 215, 168, .25); color: #f3ecdc; }
.nav-inner { max-width: var(--max); margin: 0 auto; padding: 12px var(--gutter); display: flex; align-items: center; gap: 20px; }
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink); }
.brand img { width: 40px; height: 40px; border-radius: 50%; box-shadow: 0 0 0 1px rgba(201, 164, 92, .45); }
.brand-text { display: flex; align-items: baseline; gap: 5px; font-family: var(--display); font-size: 19px; letter-spacing: -.01em; }
.brand-text em { font-style: italic; color: var(--gold-500); font-weight: 500; }
.nav-links { display: flex; gap: 4px; margin-left: auto; }
.nav-links a { padding: 8px 14px; border-radius: 999px; text-decoration: none; font-weight: 500; font-size: 15px; color: var(--ink-2); transition: background .15s, color .15s; }
.nav-links a:hover { color: var(--ink); background: color-mix(in srgb, var(--ink) 6%, transparent); }
.nav-links a.active { color: var(--ink); background: color-mix(in srgb, var(--gold-500) 16%, transparent); }
.nav.over-hero:not(.scrolled) .nav-links a.active { background: rgba(234, 215, 168, .14); }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.menu-btn { display: none; }
.i-sun { display: none; }
:root[data-theme="dark"] .i-sun { display: block; } :root[data-theme="dark"] .i-moon { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .i-sun { display: block; } :root:not([data-theme="light"]) .i-moon { display: none; } }
.account-pill { display: inline-flex; align-items: center; gap: 8px; padding: 4px 14px 4px 4px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); text-decoration: none; font-weight: 600; font-size: 14px; color: var(--ink); max-width: 210px; }
.account-pill .av { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--forest-700); color: var(--gold-300); font-family: var(--display); font-size: 14px; flex: none; }
.account-pill span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 880px) {
  .menu-btn { display: grid; }
  .nav-links { position: fixed; inset: 64px 12px auto 12px; flex-direction: column; gap: 2px; padding: 10px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg); transform-origin: top; transform: scaleY(.96); opacity: 0; pointer-events: none; transition: .18s ease; }
  .nav-links.open { opacity: 1; transform: none; pointer-events: auto; }
  .nav-links a, .nav.over-hero:not(.scrolled) .nav-links a { color: var(--ink); padding: 13px 16px; font-size: 16px; }
  .nav-actions { margin-left: auto; }
  .brand-text { font-size: 17px; }
}
@media (max-width: 520px) {
  .brand-text em { display: none; }
  #account-slot .btn { padding: 0 14px; }
  .account-pill span:last-child { display: none; }
  .account-pill { padding: 4px; }
}

/* ───────────── hero ───────────── */
.hero {
  position: relative; overflow: hidden; color: #f3ecdc; margin-top: -65px; padding: 140px 0 88px;
  background:
    radial-gradient(900px 520px at 78% 30%, rgba(201, 164, 92, .20), transparent 60%),
    radial-gradient(700px 500px at 8% 100%, rgba(36, 90, 67, .55), transparent 65%),
    linear-gradient(180deg, var(--forest-950), var(--forest-900) 55%, var(--forest-800));
}
.hero::after { content: ''; position: absolute; inset: 0; background-image: radial-gradient(rgba(234, 215, 168, .10) 1px, transparent 1px); background-size: 26px 26px; mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent); pointer-events: none; }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.hero h1 { color: #fbf6ea; font-weight: 500; }
.hero h1 em { font-style: italic; color: var(--gold-400); font-weight: 400; }
.hero .lead { color: rgba(243, 236, 220, .78); }
.hero .eyebrow { color: var(--gold-400); }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 30px; }
.hero-emblem { position: relative; justify-self: center; width: min(420px, 80vw); aspect-ratio: 1; }
.hero-emblem img { position: relative; z-index: 2; width: 100%; height: 100%; border-radius: 50%; box-shadow: 0 0 0 1px rgba(201, 164, 92, .5), 0 40px 80px -20px rgba(0, 0, 0, .7); animation: float 7s ease-in-out infinite; }
.hero-emblem::before, .hero-emblem::after { content: ''; position: absolute; inset: -22px; border-radius: 50%; border: 1px solid rgba(201, 164, 92, .28); }
.hero-emblem::after { inset: -52px; border-style: dashed; border-color: rgba(201, 164, 92, .16); animation: spin 80s linear infinite; }
.hero-stats { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-top: 64px; border-radius: var(--radius); overflow: hidden; background: rgba(234, 215, 168, .14); border: 1px solid rgba(234, 215, 168, .14); }
.hero-stats div { padding: 22px 24px; background: rgba(7, 21, 15, .55); }
.hero-stats strong { display: block; font-family: var(--display); font-size: clamp(26px, 3vw, 36px); font-weight: 500; color: var(--gold-300); line-height: 1.1; }
.hero-stats span { font-size: 13.5px; color: rgba(243, 236, 220, .65); }
@keyframes float { 50% { transform: translateY(-10px); } }
@keyframes spin { to { transform: rotate(360deg); } }
@media (max-width: 880px) {
  .hero { padding-top: 112px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-emblem { order: -1; width: min(220px, 56vw); }
  .hero-emblem::after { inset: -34px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); margin-top: 44px; }
}

/* page header for inner pages */
.page-head { position: relative; overflow: hidden; color: #f3ecdc; margin-top: -65px; padding: 120px 0 48px; background: radial-gradient(700px 300px at 85% 0%, rgba(201, 164, 92, .18), transparent 60%), linear-gradient(180deg, var(--forest-950), var(--forest-900)); }
.page-head h1 { color: #fbf6ea; font-weight: 500; }
.page-head .lead { color: rgba(243, 236, 220, .75); }
.page-head .eyebrow { color: var(--gold-400); }
.crumbs { display: flex; gap: 8px; font-size: 14px; color: rgba(243, 236, 220, .6); margin-bottom: 18px; flex-wrap: wrap; }
.crumbs a { color: var(--gold-300); text-decoration: none; }

/* ───────────── cards & surfaces ───────────── */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 3vw, 30px); box-shadow: var(--shadow-sm); }
.card-hover { transition: transform .2s ease, box-shadow .25s ease, border-color .2s; }
.card-hover:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--line-strong); }
.grid { display: grid; gap: clamp(14px, 2vw, 22px); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 960px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4, .form-grid.cols-2 { grid-template-columns: 1fr; } }

.badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px; font-size: 12.5px; font-weight: 600; letter-spacing: .02em; background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); white-space: nowrap; }
.badge::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .85; }
.badge.plain::before { display: none; }
.lv-Elementary { color: var(--lv-elementary); background: color-mix(in srgb, var(--lv-elementary) 10%, var(--surface)); border-color: color-mix(in srgb, var(--lv-elementary) 25%, transparent); }
.lv-Intermediate { color: var(--lv-intermediate); background: color-mix(in srgb, var(--lv-intermediate) 10%, var(--surface)); border-color: color-mix(in srgb, var(--lv-intermediate) 25%, transparent); }
.lv-Advanced { color: var(--lv-advanced); background: color-mix(in srgb, var(--lv-advanced) 10%, var(--surface)); border-color: color-mix(in srgb, var(--lv-advanced) 25%, transparent); }
.badge.ok { color: var(--ok); background: var(--ok-bg); border-color: transparent; }
.badge.warn { color: var(--gold-600); background: color-mix(in srgb, var(--gold-500) 14%, var(--surface)); border-color: transparent; }
.badge.danger { color: var(--danger); background: var(--danger-bg); border-color: transparent; }

.dots { display: inline-flex; gap: 4px; vertical-align: middle; }
.dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--line-strong); }
.dots i.on { background: var(--gold-500); }

/* levels section */
.levels .card { position: relative; overflow: hidden; }
.levels .card::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--c); }
.levels .num { font-family: var(--display); font-size: 54px; font-weight: 400; line-height: 1; color: var(--c); opacity: .9; }
.levels .card h3 { font-size: 26px; margin-top: 18px; }

/* steps */
.steps { counter-reset: s; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.steps li { list-style: none; position: relative; padding-top: 56px; }
.steps li::before { counter-increment: s; content: counter(s, decimal-leading-zero); position: absolute; top: 0; left: 0; font-family: var(--display); font-size: 34px; color: var(--gold); }
.steps li::after { content: ''; position: absolute; top: 22px; left: 60px; right: -6px; height: 1px; background: var(--line-strong); }
.steps li:last-child::after { display: none; }
.steps h3 { font-size: 20px; }
.steps p { color: var(--muted); font-size: 15px; }
.steps { padding: 0; margin: 0; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr 1fr; } .steps li::after { display: none; } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

/* split feature */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }
.quote { font-family: var(--display); font-size: clamp(22px, 2.6vw, 30px); line-height: 1.35; font-style: italic; font-weight: 400; color: var(--ink); border-left: 2px solid var(--gold-500); padding-left: 22px; }

/* founders & certificates */
.band-dark { background: linear-gradient(180deg, var(--forest-900), var(--forest-950)); color: #f3ecdc; }
.band-dark h2 { color: #fbf6ea; font-weight: 500; }
.band-dark .lead, .band-dark .muted { color: rgba(243, 236, 220, .7); }
.band-dark .eyebrow { color: var(--gold-400); }
.founder { background: rgba(255, 255, 255, .035); border: 1px solid rgba(234, 215, 168, .16); border-radius: calc(var(--radius) + 4px); padding: clamp(20px, 3vw, 30px); display: grid; grid-template-columns: auto 1fr; gap: 26px; align-items: start; }
.founder h3 { color: #fbf6ea; font-size: 26px; margin-bottom: 2px; }
.founder .role { color: var(--gold-300); font-size: 14px; margin-bottom: 18px; }
.cert-thumb { position: relative; width: 150px; border-radius: 10px; overflow: hidden; border: 1px solid rgba(234, 215, 168, .3); background: #fff; cursor: zoom-in; padding: 0; box-shadow: 0 18px 40px -16px rgba(0, 0, 0, .8); transition: transform .2s; }
.cert-thumb:hover { transform: translateY(-3px) rotate(-1deg); }
.cert-thumb img { width: 100%; aspect-ratio: 1405 / 1989; object-fit: cover; }
.cert-thumb .zoom { position: absolute; right: 8px; bottom: 8px; background: rgba(7, 21, 15, .8); color: var(--gold-300); border-radius: 999px; padding: 4px 10px; font-size: 12px; }
.cert-pending { width: 150px; aspect-ratio: 1405 / 1989; border-radius: 10px; border: 1px dashed rgba(234, 215, 168, .35); display: grid; place-items: center; text-align: center; padding: 14px; color: rgba(243, 236, 220, .6); font-size: 13px; }
.overall { display: inline-flex; align-items: baseline; gap: 10px; margin-bottom: 14px; }
.overall strong { font-family: var(--display); font-size: 52px; font-weight: 500; color: var(--gold-300); line-height: 1; }
.overall span { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: rgba(243, 236, 220, .65); }
.bands { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.bands li { display: grid; grid-template-columns: 82px 1fr 34px; gap: 12px; align-items: center; font-size: 14px; color: rgba(243, 236, 220, .82); }
.bands .bar { height: 6px; border-radius: 999px; background: rgba(234, 215, 168, .14); overflow: hidden; }
.bands .bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--gold-600), var(--gold-300)); transform-origin: left; animation: grow 1.2s cubic-bezier(.2, .8, .2, 1) both; }
.bands b { font-weight: 600; color: #fbf6ea; text-align: right; }
.verify-note { margin-top: 16px; font-size: 12.5px; color: rgba(243, 236, 220, .5); }
@keyframes grow { from { transform: scaleX(0); } }
@media (max-width: 560px) { .founder { grid-template-columns: 1fr; } .cert-thumb, .cert-pending { width: 120px; } }

/* topic cards */
.filter-bar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 26px; }
.chip { min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--surface); cursor: pointer; font-weight: 600; font-size: 14px; color: var(--ink-2); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.topic-card { display: flex; flex-direction: column; gap: 12px; text-decoration: none; color: inherit; height: 100%; }
.topic-card h3 { font-size: 22px; margin: 0; }
.topic-card .motion { color: var(--ink-2); font-size: 15px; flex: 1; margin: 0; }
.topic-card .meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); padding-top: 12px; border-top: 1px solid var(--line); }
.topic-card .go { color: var(--gold); font-weight: 600; }

/* topic detail */
.topic-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.toc { position: sticky; top: 88px; display: grid; gap: 2px; font-size: 14px; }
.toc a { padding: 8px 12px; border-radius: 10px; text-decoration: none; color: var(--muted); border-left: 2px solid transparent; }
.toc a:hover { color: var(--ink); background: var(--surface-2); }
.toc a.active { color: var(--ink); border-left-color: var(--gold-500); background: var(--surface-2); }
.brief section { scroll-margin-top: 90px; padding-bottom: 34px; margin-bottom: 34px; border-bottom: 1px solid var(--line); }
.brief section:last-child { border-bottom: 0; }
.brief h2 { font-size: clamp(24px, 2.6vw, 30px); display: flex; gap: 12px; align-items: baseline; }
.brief h2 .n { font-size: 14px; font-family: var(--text); color: var(--gold); font-weight: 700; letter-spacing: .1em; }
.motion-box { font-family: var(--display); font-size: clamp(24px, 3vw, 34px); line-height: 1.3; font-weight: 500; padding: clamp(22px, 3vw, 34px); border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); position: relative; }
.motion-box::before { content: '“'; position: absolute; top: -14px; left: 18px; font-size: 80px; color: var(--gold-500); line-height: 1; }
.arg-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; counter-reset: a; }
.arg-list li { counter-increment: a; display: grid; grid-template-columns: 34px 1fr; gap: 12px; padding: 16px 18px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); }
.arg-list li::before { content: counter(a); width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 13px; background: var(--c, var(--forest-700)); color: #fff; }
.for { --c: #2f7a4f; } .against { --c: #a5463a; }
.side-tag { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--c); margin-bottom: 12px; }
.rebuttal { padding: 18px 20px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--c); }
.rebuttal p { margin: 0; }
.rebuttal .claim { color: var(--muted); font-size: 14.5px; margin-bottom: 8px; font-style: italic; }
.vocab { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.vocab div { padding: 14px 16px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); }
.vocab dt { font-weight: 700; font-family: var(--display); font-size: 18px; }
.vocab dd { margin: 2px 0 0; color: var(--ink-2); font-size: 14.5px; }
.q-list { padding-left: 22px; margin: 0; display: grid; gap: 8px; }
.q-list li::marker { color: var(--gold); font-weight: 700; }
.difficulty { display: flex; gap: 20px; align-items: center; padding: 20px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.difficulty .score { font-family: var(--display); font-size: 44px; line-height: 1; }
.difficulty .score small { font-size: 18px; color: var(--muted); }
@media (max-width: 860px) { .topic-layout { grid-template-columns: 1fr; } .toc { position: static; display: flex; overflow-x: auto; gap: 6px; padding-bottom: 6px; } .toc a { white-space: nowrap; border: 1px solid var(--line); border-radius: 999px; } .toc a.active { border-color: var(--gold-500); } }
@media (max-width: 560px) { .vocab { grid-template-columns: 1fr; } }

/* auth pages */
.auth-wrap { display: grid; grid-template-columns: 1fr 1fr; min-height: calc(100vh - 65px); margin-top: -65px; }
.auth-side { position: relative; overflow: hidden; padding: 120px clamp(24px, 5vw, 64px) 48px; color: #f3ecdc; background: radial-gradient(600px 400px at 30% 20%, rgba(201, 164, 92, .22), transparent 60%), linear-gradient(160deg, var(--forest-950), var(--forest-800)); display: flex; flex-direction: column; justify-content: center; }
.auth-side h1 { color: #fbf6ea; font-weight: 500; }
.auth-side img { width: 120px; margin-bottom: 26px; border-radius: 50%; box-shadow: 0 0 0 1px rgba(201, 164, 92, .5); }
.auth-side ul { padding: 0; list-style: none; display: grid; gap: 12px; margin: 26px 0 0; color: rgba(243, 236, 220, .82); }
.auth-side li { display: flex; gap: 10px; align-items: flex-start; }
.auth-side li svg { color: var(--gold-400); flex: none; margin-top: 5px; }
.auth-main { padding: 110px clamp(20px, 5vw, 64px) 48px; display: flex; align-items: center; justify-content: center; }
.auth-card { width: 100%; max-width: 440px; }
.auth-card h2 { font-size: 34px; }
@media (max-width: 880px) { .auth-wrap { grid-template-columns: 1fr; } .auth-side { padding: 104px 20px 36px; } .auth-side ul { display: none; } .auth-side img { width: 72px; margin-bottom: 14px; } .auth-main { padding: 32px 16px 56px; } }

/* dashboard */
.dash-head { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.dash-head .av { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--gold-500); color: var(--forest-900); font-family: var(--display); font-size: 28px; flex: none; }
.debate-card { display: grid; gap: 16px; }
.debate-when { display: flex; gap: 18px; align-items: center; }
.datebox { width: 66px; flex: none; text-align: center; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: var(--surface-2); }
.datebox span { display: block; background: var(--forest-700); color: var(--gold-300); font-size: 11px; font-weight: 700; letter-spacing: .12em; padding: 4px 0; text-transform: uppercase; }
.datebox strong { display: block; font-family: var(--display); font-size: 28px; padding: 4px 0 6px; }
.team-box { border-radius: var(--radius-sm); padding: 16px; background: var(--surface-2); border: 1px solid var(--line); }
.versus { display: grid; grid-template-columns: 1fr auto 1fr; gap: 12px; align-items: start; }
.versus .vs { font-family: var(--display); font-style: italic; color: var(--gold); padding-top: 18px; }
.names { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 4px; font-size: 14.5px; }
@media (max-width: 560px) { .versus { grid-template-columns: 1fr; } .versus .vs { padding: 0; text-align: center; } }

/* empty states, skeletons */
.empty { text-align: center; padding: 48px 20px; border: 1px dashed var(--line-strong); border-radius: var(--radius); color: var(--muted); }
.empty h3 { color: var(--ink); }
.skeleton { border-radius: 10px; background: linear-gradient(90deg, var(--surface-2), var(--line), var(--surface-2)); background-size: 200% 100%; animation: shimmer 1.2s infinite; height: 18px; margin: 10px 0; }
.skeleton.h { height: 120px; border-radius: var(--radius); }
@keyframes shimmer { to { background-position: -200% 0; } }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .8, .2, 1); }
.reveal.in { opacity: 1; transform: none; }

/* ───────────── admin ───────────── */
.admin { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: calc(100vh - 65px); }
.admin-side { border-right: 1px solid var(--line); padding: 24px 14px; background: var(--bg-soft); position: sticky; top: 65px; height: calc(100vh - 65px); overflow: auto; }
.admin-side .who { padding: 10px 12px 18px; margin-bottom: 10px; border-bottom: 1px solid var(--line); font-size: 13px; color: var(--muted); word-break: break-all; }
.admin-side .who strong { display: block; color: var(--ink); font-family: var(--display); font-size: 18px; }
.admin-tabs { display: grid; gap: 2px; }
.admin-tabs a { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 10px; text-decoration: none; color: var(--ink-2); font-weight: 500; font-size: 15px; }
.admin-tabs a svg { font-size: 18px; color: var(--muted); }
.admin-tabs a:hover { background: var(--surface); }
.admin-tabs a.active { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.admin-tabs a.active svg { color: var(--gold); }
.admin-main { padding: clamp(20px, 3vw, 36px); min-width: 0; }
.admin-main h1 { font-size: clamp(26px, 3vw, 34px); }
.admin-top { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 22px; }
.admin-top h1 { margin: 0; }
@media (max-width: 860px) {
  .admin { grid-template-columns: 1fr; }
  .admin-side { position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--line); padding: 12px; }
  .admin-side .who { display: none; }
  .admin-tabs { display: flex; overflow-x: auto; gap: 6px; }
  .admin-tabs a { white-space: nowrap; border: 1px solid var(--line); }
}
.stat { padding: 20px; }
.stat .k { font-size: 13px; color: var(--muted); font-weight: 600; }
.stat .v { font-family: var(--display); font-size: 38px; line-height: 1.1; margin-top: 4px; }
.stat .s { font-size: 13px; color: var(--muted); }
.lvbar { display: grid; gap: 10px; }
.lvbar .r { display: grid; grid-template-columns: 110px 1fr 40px; gap: 12px; align-items: center; font-size: 14px; }
.lvbar .t { height: 10px; border-radius: 999px; background: var(--surface-2); overflow: hidden; border: 1px solid var(--line); }
.lvbar .t i { display: block; height: 100%; background: var(--c); border-radius: inherit; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
th, td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; background: var(--surface-2); white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
td .row { flex-wrap: nowrap; gap: 6px; }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
.toolbar .input, .toolbar .select { min-height: 42px; width: auto; }
.toolbar .input { flex: 1; min-width: 180px; }
.list-editor { display: grid; gap: 8px; }
.list-editor .item { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: start; }
.list-editor .item.pair { grid-template-columns: 1fr 1.6fr auto; }
.list-editor .item.reb { grid-template-columns: 130px 1fr 1.3fr auto; }
.list-editor .textarea { min-height: 64px; }
@media (max-width: 760px) { .list-editor .item.pair, .list-editor .item.reb { grid-template-columns: 1fr; } }
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.team-col { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); padding: 14px; min-height: 120px; }
.team-col.drop { border-color: var(--gold-500); box-shadow: 0 0 0 3px rgba(201, 164, 92, .2); }
.team-col header { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 10px; }
.team-col h4 { margin: 0; font-family: var(--text); font-size: 15px; }
.member { display: flex; justify-content: space-between; align-items: center; gap: 6px; padding: 8px 10px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--line); margin-bottom: 6px; font-size: 14px; cursor: grab; }
.member select { border: 0; background: transparent; font-size: 12px; color: var(--muted); max-width: 90px; }
details.box { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
details.box > summary { cursor: pointer; padding: 16px 20px; font-weight: 600; list-style: none; display: flex; justify-content: space-between; }
details.box > summary::after { content: '+'; color: var(--gold); font-size: 20px; line-height: 1; }
details.box[open] > summary::after { content: '–'; }
details.box > div { padding: 0 20px 20px; }
.json-out { font: 12.5px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px; max-height: 360px; overflow: auto; white-space: pre-wrap; }
.notice { padding: 14px 18px; border-radius: var(--radius-sm); background: color-mix(in srgb, var(--gold-500) 11%, var(--surface)); border: 1px solid color-mix(in srgb, var(--gold-500) 30%, transparent); font-size: 14.5px; }
.log { list-style: none; padding: 0; margin: 0; display: grid; gap: 0; }
.log li { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.log li:last-child { border-bottom: 0; }
.log time { color: var(--muted); white-space: nowrap; font-size: 13px; min-width: 110px; }

/* ───────────── toasts, dialog, lightbox ───────────── */
.toasts { position: fixed; z-index: 90; bottom: 20px; left: 50%; transform: translateX(-50%); display: grid; gap: 8px; width: min(440px, calc(100vw - 32px)); }
.toast { padding: 13px 18px; border-radius: 14px; background: var(--forest-900); color: #f3ecdc; box-shadow: var(--shadow-lg); font-size: 14.5px; animation: toast-in .25s ease; border: 1px solid rgba(234, 215, 168, .2); }
.toast.err { background: #5a1f17; }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } }
.dialog { border: 0; padding: 0; border-radius: var(--radius); background: var(--surface); color: var(--ink); width: min(480px, calc(100vw - 32px)); box-shadow: var(--shadow-lg); }
.dialog::backdrop { background: rgba(7, 21, 15, .6); backdrop-filter: blur(3px); }
.dialog .dlg { padding: 26px; }
.dialog .dlg h3 { font-size: 24px; }
.dialog .dlg .row { justify-content: flex-end; margin-top: 22px; }
.dialog.lightbox { width: min(820px, calc(100vw - 24px)); max-height: calc(100vh - 24px); background: #fff; }
.dialog.lightbox img { width: 100%; height: auto; }
.dialog.lightbox .close { position: sticky; top: 10px; float: right; margin: 10px 10px -50px 0; z-index: 2; background: var(--forest-900); color: var(--gold-300); border: 0; }
.dialog.lightbox p { color: #3d4d45; font-size: 13px; padding: 12px 18px; margin: 0; background: #f7f3ea; }

/* footer */
.footer { margin-top: auto; border-top: 1px solid var(--line); background: var(--bg-soft); }
.footer-inner { max-width: var(--max); margin: 0 auto; padding: 36px var(--gutter); display: flex; flex-wrap: wrap; gap: 20px 40px; align-items: center; justify-content: space-between; }
.footer-brand { display: flex; gap: 14px; align-items: center; }
.footer-brand img { border-radius: 50%; }
.footer-brand strong { font-family: var(--display); font-size: 19px; }
.footer-brand p { margin: 0; color: var(--muted); font-size: 14px; }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; }
.footer-links a { color: var(--ink-2); text-decoration: none; font-size: 14.5px; }
.footer-links a:hover { color: var(--gold); }
.footer-note { width: 100%; margin: 0; font-size: 13px; color: var(--muted); }

@media print {
  .nav, .footer, .toc, .no-print { display: none !important; }
  .page-head { margin: 0; padding: 20px 0; background: none; color: #000; }
  .page-head h1, .page-head .lead { color: #000; }
  .topic-layout { display: block; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
