/* ==========================================================================
   Drop Board — gradient / glass theme, light and dark.

   Theme is driven by data-theme on <html>. A small script in the <head> sets it
   before first paint so there is no flash. Everything below reads from the two
   token blocks, so nothing needs a .dark or .light selector further down.
   ========================================================================== */

/* --- dark (default) ------------------------------------------------------ */
:root,
:root[data-theme='dark'] {
  --bg:        #08080f;
  --bg-2:      #101021;
  --surface:   rgba(255, 255, 255, .045);
  --surface-2: rgba(255, 255, 255, .075);
  --border:    rgba(255, 255, 255, .10);
  --border-2:  rgba(255, 255, 255, .18);

  --text:  #f2f2f9;
  --muted: #a5a5c2;
  --faint: #74748f;

  --aurora-1: rgba(124, 58, 237, .30);
  --aurora-2: rgba(217, 70, 239, .22);
  --aurora-3: rgba(56, 189, 248, .18);

  --glow:      0 12px 40px -12px rgba(124, 58, 237, .55);
  --glow-hard: 0 18px 60px -18px rgba(168, 85, 247, .75);
  --shadow:    0 20px 50px -24px rgba(0, 0, 0, .85);

  --input-bg: rgba(255, 255, 255, .05);
  color-scheme: dark;
}

/* --- light --------------------------------------------------------------- */
:root[data-theme='light'] {
  /* Warm paper rather than cold lavender, with genuinely readable ink. */
  --bg:        #faf7f2;
  --bg-2:      #ffffff;
  --surface:   #ffffff;
  --surface-2: #ffffff;
  --border:    rgba(40, 30, 20, .12);
  --border-2:  rgba(40, 30, 20, .22);

  --text:  #211d2e;   /* 15:1 on the paper */
  --muted: #5c5468;   /*  6.7:1 */
  --faint: #837b90;   /*  3.8:1, used only for tiny incidental labels */

  --aurora-1: rgba(139, 92, 246, .14);
  --aurora-2: rgba(236, 72, 153, .10);
  --aurora-3: rgba(56, 189, 248, .10);

  --glow:      0 10px 26px -16px rgba(124, 58, 237, .30);
  --glow-hard: 0 16px 40px -20px rgba(168, 85, 247, .38);
  --shadow:    0 14px 40px -24px rgba(60, 45, 30, .22);

  --input-bg: #ffffff;
  color-scheme: light;
}

/* --- shared -------------------------------------------------------------- */
:root {
  --brand:      linear-gradient(135deg, #8b5cf6 0%, #d946ef 55%, #f472b6 100%);
  --brand-soft: linear-gradient(135deg, rgba(139, 92, 246, .9), rgba(217, 70, 239, .85));
  --brand-text: linear-gradient(115deg, #a78bfa 0%, #f0abfc 45%, #7dd3fc 100%);

  --live:  #34d399;
  --warn:  #fbbf24;
  --ended: #fb7185;

  --display: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 26px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; max-width: 100%; overflow-x: hidden; }
/* Long unbroken words (URLs, ref codes) wrap instead of stretching a card. */
h3, .desc, .ref, .member-name, .member-sub, .row-title { overflow-wrap: anywhere; word-break: break-word; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 15.5px;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  position: relative;
  overflow-x: hidden;
  transition: background .35s ease, color .35s ease;
}

/* drifting aurora behind everything */
body::before {
  content: '';
  position: fixed;
  inset: -20%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(42% 38% at 12% 8%,  var(--aurora-1), transparent 62%),
    radial-gradient(38% 34% at 88% 12%, var(--aurora-2), transparent 62%),
    radial-gradient(46% 40% at 55% 96%, var(--aurora-3), transparent 62%);
  /* Deliberately static. An animated gradient sitting behind backdrop-filter
     panels forces the browser to recompute every blur on every frame, which
     shows up as a shimmer on the cards. If you want it moving and your machine
     can take it, add:  animation: drift 26s ease-in-out infinite alternate;
     and uncomment the keyframes below. */
}
/*
@keyframes drift {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  50%  { transform: translate3d(2%, -2%, 0) scale(1.06); }
  100% { transform: translate3d(-2%, 2%, 0) scale(1.02); }
}
*/

a { color: #c4b5fd; }
:root[data-theme='light'] a { color: #6d28d9; }

:focus-visible {
  outline: 2px solid #c084fc;
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap { width: min(1220px, 92vw); margin: 0 auto; }

/* reusable pieces --------------------------------------------------------- */
.glass {
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
}
:root[data-theme='light'] .glass { backdrop-filter: none; -webkit-backdrop-filter: none; }

.gradient-text {
  background: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
:root[data-theme='light'] .gradient-text {
  background: linear-gradient(115deg, #6d28d9 0%, #a21caf 55%, #0369a1 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border-bottom: 1px solid var(--border);
}
.topbar-in {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 62px;
}

.mark {
  font-family: var(--display);
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -.03em;
  margin: 0;
  background: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
:root[data-theme='light'] .mark {
  background: linear-gradient(115deg, #7c3aed, #c026d3);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.mark span { display: none; }

.status {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--mono);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--faint);
}

.pulse {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px 5px 9px;
  border-radius: 100px;
  background: color-mix(in srgb, var(--live) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--live) 35%, transparent);
  color: var(--live);
  font-weight: 600;
}
.pulse::before {
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--live);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 60%, transparent);
  animation: ping 2.2s cubic-bezier(0, 0, .2, 1) infinite;
}
@keyframes ping {
  0%   { box-shadow: 0 0 0 0 color-mix(in srgb, var(--live) 55%, transparent); }
  70%  { box-shadow: 0 0 0 8px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.pulse.off {
  background: var(--surface);
  border-color: var(--border);
  color: var(--faint);
}
.pulse.off::before { background: var(--faint); animation: none; box-shadow: none; }

.ghost-link,
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  text-decoration: none;
  font-family: var(--body);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 15px;
  cursor: pointer;
  transition: border-color .2s, color .2s, transform .15s, box-shadow .2s;
}
.ghost-link:hover,
.theme-toggle:hover {
  border-color: var(--border-2);
  color: var(--text);
  transform: translateY(-1px);
  box-shadow: var(--glow);
}
.theme-toggle { width: 38px; height: 38px; padding: 0; flex: none; }
.theme-toggle svg { width: 17px; height: 17px; }
.theme-toggle .icon-sun { display: none; }
:root[data-theme='light'] .theme-toggle .icon-sun { display: block; }
:root[data-theme='light'] .theme-toggle .icon-moon { display: none; }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */
.hero { padding: 84px 0 34px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 7px 14px;
  border-radius: 100px;
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  margin: 0 0 24px;
  background-image: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
:root[data-theme='light'] .eyebrow {
  background-image: linear-gradient(115deg, #7c3aed, #c026d3);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(44px, 8vw, 88px);
  line-height: 1.02;
  letter-spacing: -.045em;
  margin: 0;
  background: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  max-width: 16ch;
}
:root[data-theme='light'] .hero h1 {
  background: linear-gradient(115deg, #6d28d9 0%, #a21caf 55%, #0369a1 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero > p:not(.eyebrow) {
  color: var(--muted);
  font-size: 17.5px;
  max-width: 50ch;
  margin: 22px 0 0;
}

.notice {
  margin-top: 28px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  border-radius: var(--r-md);
  padding: 14px 18px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.6;
  max-width: 68ch;
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.notice svg { flex: none; margin-top: 3px; color: #c084fc; }

/* --------------------------------------------------------------------------
   Board
   -------------------------------------------------------------------------- */
.board-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 48px 0 20px;
}
.board-head h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -.03em;
  margin: 0;
}
.board-head .count {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
  color: var(--faint);
  padding: 6px 12px;
  border-radius: 100px;
  background: var(--surface);
  border: 1px solid var(--border);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 22px;
  padding-bottom: 100px;
  align-items: start;
}

/* --------------------------------------------------------------------------
   Drop card
   -------------------------------------------------------------------------- */
.ticket {
  position: relative;
  border-radius: var(--r-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  box-shadow: var(--shadow);
  transition: transform .3s cubic-bezier(.2, .8, .3, 1), box-shadow .3s, border-color .3s;
  animation: rise .5s cubic-bezier(.2, .8, .3, 1) backwards;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(18px) scale(.985); }
  to   { opacity: 1; transform: none; }
}
.ticket:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow), var(--glow);
  border-color: var(--border-2);
}

/* gradient edge that lights up on hover */
.ticket::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(167, 139, 250, .85), rgba(240, 171, 252, .5) 45%, transparent 75%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  opacity: 0;
  transition: opacity .3s;
  pointer-events: none;
}
.ticket:hover::after { opacity: 1; }

.ticket-media {
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, rgba(139, 92, 246, .22), rgba(217, 70, 239, .12));
  position: relative;
  overflow: hidden;
}
.ticket-media img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  -webkit-user-drag: none;
  user-select: none;
  pointer-events: none;
  transition: transform .5s cubic-bezier(.2, .8, .3, 1);
}
.ticket:hover .ticket-media img { transform: scale(1.04); }
.ticket-media.empty::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(60% 80% at 30% 20%, rgba(167, 139, 250, .35), transparent 70%),
    radial-gradient(60% 80% at 80% 80%, rgba(240, 171, 252, .28), transparent 70%);
}

/* soft divider where the old ticket perforation used to be */
.perf {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-2), transparent);
}

.ticket-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 13px;
  flex: 1;
}

.ticket h3 {
  font-family: var(--display);
  font-weight: 800;
  font-size: 21px;
  line-height: 1.2;
  letter-spacing: -.03em;
  margin: 0;
}

.ticket .desc { color: var(--muted); font-size: 14px; margin: 0; }

.tags { display: flex; flex-wrap: wrap; gap: 6px; }

.tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  padding: 5px 11px;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.tag.live {
  color: var(--live);
  border-color: color-mix(in srgb, var(--live) 40%, transparent);
  background: color-mix(in srgb, var(--live) 13%, transparent);
}
.tag.live::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--live);
  box-shadow: 0 0 8px var(--live);
}
.tag.locked {
  color: #c084fc;
  border-color: rgba(192, 132, 252, .4);
  background: rgba(192, 132, 252, .12);
}
:root[data-theme='light'] .tag.locked { color: #9333ea; }
.tag.ended {
  color: var(--ended);
  border-color: color-mix(in srgb, var(--ended) 40%, transparent);
  background: color-mix(in srgb, var(--ended) 12%, transparent);
}

/* meters */
.meters {
  display: flex;
  gap: 16px;
  align-items: flex-end;
  margin-top: auto;
  padding-top: 15px;
  border-top: 1px solid var(--border);
}
.meter { flex: 1; min-width: 0; }
.meter .label {
  display: block;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: 6px;
}
.meter .value {
  font-family: var(--mono);
  font-size: 19px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  letter-spacing: -.02em;
}
.meter .value.urgent { color: var(--warn); }
.meter .value.dead { color: var(--faint); }

.pips {
  display: flex;
  gap: 3px;
  margin-top: 9px;
}
.pip {
  flex: 1 1 0;
  min-width: 0;
  height: 5px;
  border-radius: 100px;
  background: linear-gradient(90deg, #8b5cf6, #d946ef);
  transition: background .35s, opacity .35s;
}
.pip.spent { background: var(--border-2); opacity: .55; }

.barcode, .bar { display: none; }
.ref {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--faint);
  margin: 0;
  opacity: .75;
}

/* controls */
.claim {
  width: 100%;
  border: none;
  border-radius: var(--r-md);
  padding: 14px 18px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -.01em;
  color: #fff;
  background: var(--brand);
  background-size: 180% 180%;
  cursor: pointer;
  box-shadow: var(--glow);
  transition: transform .18s cubic-bezier(.2, .8, .3, 1), box-shadow .25s, background-position .5s, filter .2s;
}
.claim:hover {
  transform: translateY(-2px);
  box-shadow: var(--glow-hard);
  background-position: 100% 0;
}
.claim:active { transform: translateY(0); }
.claim[disabled] {
  background: var(--surface-2);
  color: var(--faint);
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
  border: 1px solid var(--border);
}

.lockbox { display: none; flex-direction: column; gap: 9px; }
.lockbox.open { display: flex; animation: rise .3s ease backwards; }
.lockbox input {
  width: 100%;
  background: var(--input-bg);
  border: 1px solid var(--border-2);
  border-radius: var(--r-md);
  padding: 13px 15px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 14px;
  letter-spacing: .1em;
  transition: border-color .2s, box-shadow .2s;
}
.lockbox input::placeholder { color: var(--faint); letter-spacing: normal; font-family: var(--body); }
.lockbox input:focus {
  border-color: #a78bfa;
  outline: none;
  box-shadow: 0 0 0 4px rgba(167, 139, 250, .18);
}

.msg {
  font-size: 12.5px;
  font-weight: 600;
  min-height: 16px;
  color: var(--ended);
  margin: 0;
}
.msg.good { color: var(--live); }

/* ended */
.ticket.ended { box-shadow: none; }
.ticket.ended:hover { transform: none; box-shadow: none; }
.ticket.ended::after { display: none; }
.ticket.ended .ticket-media,
.ticket.ended .ticket-body { opacity: .5; }
.ticket.ended .ticket-media img { filter: grayscale(.85); }
.ticket.ended:hover .ticket-media img { transform: none; }

.stamp {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  font-family: var(--display);
  font-weight: 800;
  font-size: 11px;
  letter-spacing: .12em;
  color: #fff;
  border-radius: 100px;
  padding: 7px 14px;
  background: linear-gradient(135deg, #fb7185, #e11d48);
  box-shadow: 0 8px 24px -8px rgba(225, 29, 72, .8);
  animation: pop .4s cubic-bezier(.2, 1.5, .4, 1);
  pointer-events: none;
}
@keyframes pop {
  from { transform: scale(1.7); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

/* empty state */
.empty-board {
  grid-column: 1 / -1;
  border-radius: var(--r-xl);
  padding: 150px 28px;
  min-height: 420px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--surface);
  border: 1px dashed var(--border-2);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.empty-board h3 {
  font-family: var(--display);
  font-weight: 800;
  font-size: 26px;
  letter-spacing: -.035em;
  margin: 0 0 10px;
}
.empty-board p { color: var(--muted); margin: 0; }

/* --------------------------------------------------------------------------
   Chrome
   -------------------------------------------------------------------------- */
.foot {
  border-top: 1px solid var(--border);
  padding: 26px 0 46px;
  color: var(--faint);
  font-size: 13px;
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  align-items: center;
}
.foot-end { margin-left: auto; }

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translate(-50%, 160%);
  border-radius: 100px;
  padding: 13px 24px;
  font-size: 13.5px;
  font-weight: 600;
  background: var(--surface-2);
  border: 1px solid var(--border-2);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow);
  transition: transform .35s cubic-bezier(.2, .9, .3, 1);
  z-index: 90;
  max-width: 90vw;
  text-align: center;
}
.toast.show { transform: translate(-50%, 0); }
.toast.err { border-color: color-mix(in srgb, var(--ended) 50%, transparent); color: var(--ended); }
.toast.ok  { border-color: color-mix(in srgb, var(--live) 50%, transparent); color: var(--live); }

.shield {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: color-mix(in srgb, var(--bg) 96%, transparent);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  display: none;
  place-items: center;
  text-align: center;
  padding: 30px;
}
.shield.on { display: grid; }
.shield h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(30px, 6vw, 54px);
  letter-spacing: -.04em;
  margin: 0 0 12px;
  background: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.shield p { color: var(--muted); max-width: 44ch; margin: 0 auto; }

.file-warning {
  background: linear-gradient(135deg, #fb7185, #e11d48);
  color: #fff;
  font-size: 13.5px;
  padding: 13px 18px;
  text-align: center;
}
.file-warning strong { display: block; margin-bottom: 2px; }

.gate { padding: 110px 0 140px; text-align: center; }
.gate h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(40px, 8vw, 76px);
  letter-spacing: -.045em;
  margin: 0 0 14px;
  background: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.gate p { color: var(--muted); margin: 0 auto 32px; max-width: 46ch; }
.gate .btn { display: inline-block; text-decoration: none; padding: 15px 32px; font-size: 16px; }

.boot { padding: 60px 24px; text-align: center; color: var(--muted); }

/* ==========================================================================
   Admin
   ========================================================================== */
.admin-body { padding-bottom: 90px; }

.login-shell { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card {
  width: min(420px, 100%);
  border-radius: var(--r-xl);
  padding: 38px 34px;
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  box-shadow: var(--shadow), var(--glow);
}
.login-card h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: 30px;
  letter-spacing: -.04em;
  margin: 0 0 6px;
  background: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
:root[data-theme='light'] .login-card h1,
:root[data-theme='light'] .gate h2,
:root[data-theme='light'] .shield h2 {
  background: linear-gradient(115deg, #6d28d9, #a21caf);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.login-card .sub { color: var(--muted); font-size: 14.5px; margin: 0 0 26px; }

.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .02em;
  color: var(--muted);
  margin-bottom: 7px;
}
.field input,
.field textarea,
.field select {
  width: 100%;
  background: var(--input-bg);
  border: 1px solid var(--border-2);
  border-radius: var(--r-md);
  padding: 12px 14px;
  color: var(--text);
  font-family: var(--body);
  font-size: 14.5px;
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 80px; }
.field input:focus, .field textarea:focus, .field select:focus {
  border-color: #a78bfa;
  outline: none;
  box-shadow: 0 0 0 4px rgba(167, 139, 250, .18);
}
.field input::placeholder, .field textarea::placeholder { color: var(--faint); }
.field .hint { font-size: 12.5px; color: var(--faint); margin-top: 6px; line-height: 1.5; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.btn {
  border: none;
  border-radius: var(--r-md);
  padding: 13px 20px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -.01em;
  color: #fff;
  background: var(--brand);
  background-size: 180% 180%;
  cursor: pointer;
  box-shadow: var(--glow);
  transition: transform .18s, box-shadow .25s, background-position .5s;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--glow-hard); background-position: 100% 0; }
.btn:active { transform: translateY(0); }
.btn.full { width: 100%; display: block; }

.btn.quiet {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 600;
  padding: 8px 14px;
  box-shadow: none;
}
.btn.quiet:hover {
  color: var(--text);
  border-color: var(--border-2);
  box-shadow: var(--glow);
  transform: translateY(-1px);
}
.btn.danger {
  background: color-mix(in srgb, var(--ended) 14%, transparent);
  border-color: color-mix(in srgb, var(--ended) 40%, transparent);
  color: var(--ended);
}
.btn.danger:hover {
  background: linear-gradient(135deg, #fb7185, #e11d48);
  color: #fff;
  border-color: transparent;
}

.check { display: flex; align-items: flex-start; gap: 11px; padding: 9px 0; cursor: pointer; font-size: 14.5px; }
.check input { margin-top: 3px; accent-color: #a855f7; width: 16px; height: 16px; flex: none; }
.check .ck-label { display: block; font-weight: 600; }
.check .ck-hint { display: block; color: var(--faint); font-size: 12.5px; font-weight: 400; line-height: 1.5; }

.admin-grid {
  display: grid;
  grid-template-columns: minmax(330px, 400px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  padding-top: 26px;
}
@media (max-width: 940px) { .admin-grid { grid-template-columns: 1fr; } }

.card {
  border-radius: var(--r-lg);
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  box-shadow: var(--shadow);
}
.card + .card { margin-top: 20px; }
.card > h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: 16px;
  letter-spacing: -.025em;
  margin: 0 0 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.tabs { display: flex; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; }
.tab-btn {
  border-radius: 100px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  padding: 8px 16px;
  font-family: var(--body);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: .2s;
}
.tab-btn:hover { color: var(--text); border-color: var(--border-2); }
.tab-btn.on {
  background: var(--brand);
  color: #fff;
  border-color: transparent;
  box-shadow: var(--glow);
}

.stat-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}
.stat {
  border-radius: var(--r-md);
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.stat .n {
  font-family: var(--mono);
  font-size: 26px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  letter-spacing: -.03em;
}
.stat .l { font-size: 12px; font-weight: 600; color: var(--faint); margin-top: 8px; }
.stat.live .n {
  background: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
:root[data-theme='light'] .stat.live .n {
  background: linear-gradient(115deg, #7c3aed, #c026d3);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.rows { display: flex; flex-direction: column; gap: 14px; }
.row {
  border-radius: var(--r-lg);
  padding: 17px 19px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: border-color .2s, transform .2s;
}
.row::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, #8b5cf6, #d946ef);
}
.row:hover { border-color: var(--border-2); transform: translateX(2px); }
.row.is-ended { opacity: .7; }
.row.is-ended::before { background: linear-gradient(180deg, #fb7185, #e11d48); }

.row-top { display: flex; align-items: flex-start; gap: 13px; }
.row-thumb { width: 64px; height: 44px; border-radius: var(--r-sm); object-fit: cover; background: var(--surface-2); flex: none; }
.row-title { font-family: var(--display); font-weight: 800; font-size: 17px; letter-spacing: -.025em; margin: 0 0 4px; }
.row-meta {
  font-family: var(--mono);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--faint);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.row-meta b { color: var(--warn); font-weight: 700; }
.row-meta .ended-txt { color: var(--ended); }

.copyline {
  display: flex;
  align-items: center;
  gap: 9px;
  border-radius: var(--r-sm);
  padding: 8px 8px 8px 13px;
  background: var(--input-bg);
  border: 1px solid var(--border);
  min-width: 0;
  max-width: 100%;
}
.copyline .k { font-size: 11px; font-weight: 700; color: var(--faint); flex: none; width: 42px; }
.copyline .v {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
}
.copyline button {
  flex: none;
  border-radius: 100px;
  border: 1px solid var(--border-2);
  background: var(--surface-2);
  color: var(--muted);
  font-family: var(--body);
  font-size: 11.5px;
  font-weight: 600;
  padding: 6px 13px;
  cursor: pointer;
  transition: .2s;
}
.copyline button:hover { color: var(--text); border-color: #a78bfa; }
.copyline button.done { color: var(--live); border-color: color-mix(in srgb, var(--live) 55%, transparent); }

.row-actions { display: flex; flex-wrap: wrap; gap: 8px; }

.divider { height: 1px; background: var(--border); margin: 20px 0; }

.inline-note { font-size: 12.5px; color: var(--faint); line-height: 1.65; }

.storage-warning {
  border-radius: var(--r-md);
  padding: 15px 18px;
  margin-top: 22px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ended);
  background: color-mix(in srgb, var(--ended) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--ended) 40%, transparent);
}

/* --------------------------------------------------------------------------
   Small screens
   -------------------------------------------------------------------------- */
@media (max-width: 620px) {
  .topbar-in { gap: 8px; height: 58px; }
  #clock { display: none; }
  .hero { padding: 52px 0 24px; }
  .board-head { padding-top: 34px; }
  .foot { flex-direction: column; align-items: flex-start; gap: 8px; }
  .foot-end { margin-left: 0; }
  .field-row { grid-template-columns: 1fr; }
  .ghost-link { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

/* ==========================================================================
   Link modes, members, Discord sign-in
   ========================================================================== */

.mode-pick { display: grid; gap: 9px; }

.mode-opt {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 13px 15px;
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  transition: border-color .2s, background .2s;
}
.mode-opt:hover { border-color: var(--border-2); }
.mode-opt input { margin-top: 3px; accent-color: #a855f7; width: 16px; height: 16px; flex: none; }
.mode-opt b { display: block; font-size: 14px; font-weight: 700; }
.mode-opt em { display: block; font-style: normal; color: var(--faint); font-size: 12.5px; line-height: 1.45; }
.mode-opt:has(input:checked) {
  border-color: #a78bfa;
  background: rgba(167, 139, 250, .1);
}

.links-box {
  min-height: 150px !important;
  font-family: var(--mono) !important;
  font-size: 12px !important;
  line-height: 1.6;
  white-space: pre;
  overflow-wrap: normal;
  overflow-x: auto;
}

/* members */
.member-row {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.member-row:last-child { border-bottom: none; }

.member-av {
  width: 38px; height: 38px;
  border-radius: 50%;
  flex: none;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: var(--brand);
  color: #fff;
  font-weight: 800;
  font-size: 15px;
}
.member-av img { width: 100%; height: 100%; object-fit: cover; display: block; }

.member-name { font-weight: 700; font-size: 14.5px; }
.member-sub {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.member-count {
  flex: none;
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
  padding: 5px 11px;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: var(--surface-2);
}

.log-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.log-row:last-child { border-bottom: none; }
.log-who { font-weight: 700; flex: none; }
.log-what { color: var(--muted); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.log-when { font-family: var(--mono); font-size: 10.5px; color: var(--faint); flex: none; }

/* signed-in badge */
.who {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  padding: 7px 13px;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: var(--surface);
  white-space: nowrap;
  max-width: 22ch;
  overflow: hidden;
  text-overflow: ellipsis;
}

.discord-btn {
  display: inline-flex !important;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #5865f2, #7b5cff) !important;
  color: #fff !important;
  -webkit-background-clip: border-box !important;
  background-clip: border-box !important;
  -webkit-text-fill-color: #fff !important;
}
.discord-btn svg { width: 21px; height: 21px; color: #fff; }

@media (max-width: 620px) {
  .who { display: none; }
  .member-sub { font-size: 10px; }
}

/* ==========================================================================
   Rules screen, item value, admin preview
   ========================================================================== */

.rules {
  max-width: 660px;
  padding: 76px 0 110px;
}
.rules h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(32px, 6vw, 52px);
  letter-spacing: -.04em;
  margin: 0 0 10px;
  background: var(--brand-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
:root[data-theme='light'] .rules h2 {
  background: linear-gradient(115deg, #6d28d9, #a21caf);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.rules-intro { color: var(--muted); margin: 0 0 28px; font-size: 16.5px; }

.rules-list {
  list-style: none;
  counter-reset: rule;
  margin: 0 0 26px;
  padding: 0;
  display: grid;
  gap: 12px;
}
.rules-list li {
  counter-increment: rule;
  position: relative;
  padding: 16px 20px 16px 58px;
  border-radius: var(--r-md);
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  font-size: 15px;
  line-height: 1.55;
}
.rules-list li::before {
  content: counter(rule);
  position: absolute;
  left: 18px;
  top: 15px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--brand);
  color: #fff;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
}

.rules-warn {
  border-radius: var(--r-md);
  padding: 15px 18px;
  margin: 0 0 26px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--ended);
  background: color-mix(in srgb, var(--ended) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--ended) 38%, transparent);
}

#rulesAccept { min-width: 260px; }
#rulesAccept[disabled] {
  background: var(--surface-2);
  color: var(--faint);
  border: 1px solid var(--border);
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}
.rules-note { color: var(--ended); font-size: 13px; min-height: 18px; margin: 12px 0 0; }

/* item value */
.tag.worth {
  color: #fbbf24;
  border-color: rgba(251, 191, 36, .42);
  background: rgba(251, 191, 36, .13);
}
:root[data-theme='light'] .tag.worth { color: #b45309; }

/* admin preview */
.preview-wrap { margin-bottom: 18px; }
.preview-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--faint);
  margin: 0 0 10px;
}
.preview-wrap .ticket { box-shadow: none; }
.preview-wrap .ticket:hover { transform: none; box-shadow: none; }
.preview-wrap .claim[disabled] { opacity: .85; }
.preview-note {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--faint);
  margin: 10px 0 0;
  text-align: center;
}

/* "One per person" — deliberately the quietest badge of the set */
.tag.once { color: var(--muted); border-color: var(--border-2); }

/* ==========================================================================
   Ban badges and the banned page
   ========================================================================== */
.member-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: none;
  margin-left: auto;
  flex-wrap: wrap;
  justify-content: flex-end;
}
/* the name/handle block: never let it collapse to zero and collide */
.member-row > div:not(.member-av):not(.member-right) { min-width: 140px; }

.member-badge {
  font-family: var(--mono);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 4px 9px;
  border-radius: 100px;
  border: 1px solid var(--border-2);
}
.member-badge.admin {
  color: #c084fc;
  border-color: rgba(192, 132, 252, .5);
  background: rgba(192, 132, 252, .12);
}
.member-badge.banned {
  color: var(--ended);
  border-color: color-mix(in srgb, var(--ended) 50%, transparent);
  background: color-mix(in srgb, var(--ended) 12%, transparent);
}

.banned-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 30px;
  text-align: center;
}
.banned-card {
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.banned-mark {
  width: 76px; height: 76px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--ended);
  background: color-mix(in srgb, var(--ended) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--ended) 40%, transparent);
  margin-bottom: 6px;
}
.banned-mark svg { width: 34px; height: 34px; }
.banned-card h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(32px, 6vw, 48px);
  letter-spacing: -.04em;
  margin: 0;
}
.banned-card p { color: var(--muted); margin: 0; font-size: 16px; line-height: 1.6; }
.banned-reason {
  font-family: var(--mono) !important;
  font-size: 13px !important;
  color: var(--ended) !important;
  padding: 10px 16px;
  border-radius: var(--r-md);
  background: color-mix(in srgb, var(--ended) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--ended) 34%, transparent);
}
.banned-card .btn { margin-top: 10px; text-decoration: none; padding: 14px 26px; }

/* ===== button text-fill guard ===== */

/* Buttons carry solid white text. Some browsers otherwise inherit the gradient
   text-clip used on headings, which turns button labels invisible. */
.btn, .claim, .discord-btn {
  -webkit-text-fill-color: #fff;
}
.btn.quiet {
  -webkit-text-fill-color: var(--muted);
}
.btn.quiet:hover { -webkit-text-fill-color: var(--stock, #fff); }
.btn.danger { -webkit-text-fill-color: var(--ended); }
.btn.danger:hover { -webkit-text-fill-color: #fff; }
:root[data-theme='light'] .btn.quiet:hover { -webkit-text-fill-color: #fff; }

/* ==========================================================================
   Light mode refinements — warmer, calmer, higher contrast
   ========================================================================== */
:root[data-theme='light'] body {
  /* a gentle warm wash instead of cold radial blobs */
  background: var(--bg);
}
:root[data-theme='light'] body::before {
  opacity: .6;
  background:
    radial-gradient(48% 42% at 15% 6%,  var(--aurora-1), transparent 60%),
    radial-gradient(42% 38% at 88% 10%, var(--aurora-2), transparent 60%),
    radial-gradient(50% 44% at 55% 98%, var(--aurora-3), transparent 60%);
}

/* solid cards read better than frosted glass on paper */
:root[data-theme='light'] .ticket,
:root[data-theme='light'] .card,
:root[data-theme='light'] .login-card,
:root[data-theme='light'] .stat,
:root[data-theme='light'] .row,
:root[data-theme='light'] .rules-list li,
:root[data-theme='light'] .notice,
:root[data-theme='light'] .empty-board {
  background: #ffffff;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow: 0 1px 2px rgba(40, 30, 20, .04), 0 8px 24px -16px rgba(60, 45, 30, .18);
}

:root[data-theme='light'] .topbar {
  background: rgba(250, 247, 242, .85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
}

/* pills and quiet controls: give them a real surface so they don't float */
:root[data-theme='light'] .pulse.off,
:root[data-theme='light'] .ghost-link,
:root[data-theme='light'] .theme-toggle,
:root[data-theme='light'] .who,
:root[data-theme='light'] .board-head .count,
:root[data-theme='light'] .tab-btn,
:root[data-theme='light'] .btn.quiet,
:root[data-theme='light'] .member-count,
:root[data-theme='light'] .copyline button {
  background: #ffffff;
  border-color: var(--border-2);
  color: var(--muted);
}

/* the "Live"/"Locked" status pill needs a legible tint */
:root[data-theme='light'] .pulse {
  background: rgba(16, 185, 129, .12);
  border-color: rgba(16, 185, 129, .4);
  color: #047857;
}
:root[data-theme='light'] .pulse::before { background: #059669; }

/* tags: solid, readable chips */
:root[data-theme='light'] .tag {
  background: #ffffff;
  border-color: var(--border-2);
  color: var(--muted);
}
:root[data-theme='light'] .tag.live {
  color: #047857;
  border-color: rgba(16, 185, 129, .45);
  background: rgba(16, 185, 129, .1);
}
:root[data-theme='light'] .tag.live::before { background: #059669; box-shadow: none; }
:root[data-theme='light'] .tag.worth {
  color: #b45309;
  border-color: rgba(180, 83, 9, .35);
  background: rgba(251, 191, 36, .14);
}
:root[data-theme='light'] .tag.ended {
  color: #be123c;
  border-color: rgba(190, 18, 60, .35);
  background: rgba(244, 63, 94, .08);
}

/* meters and numbers */
:root[data-theme='light'] .meter .value { color: var(--text); }
:root[data-theme='light'] .meter .value.urgent { color: #b45309; }
:root[data-theme='light'] .pip { background: linear-gradient(90deg, #7c3aed, #c026d3); }
:root[data-theme='light'] .pip.spent { background: #e4ddd2; opacity: 1; }

/* inputs: clear field on white */
:root[data-theme='light'] .field input,
:root[data-theme='light'] .field textarea,
:root[data-theme='light'] .field select,
:root[data-theme='light'] .lockbox input {
  background: #ffffff;
  border-color: var(--border-2);
  color: var(--text);
}

/* the clock and small mono labels were nearly invisible */
:root[data-theme='light'] .status { color: var(--muted); }

/* notice bar accent */
:root[data-theme='light'] .notice { border-color: var(--border-2); }
:root[data-theme='light'] .notice svg { color: #7c3aed; }

/* ended cards shouldn't turn to mud */
:root[data-theme='light'] .ticket.ended .ticket-media,
:root[data-theme='light'] .ticket.ended .ticket-body { opacity: .55; }

/* ==========================================================================
   Member search
   ========================================================================== */
.member-search {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--border-2);
  background: var(--input-bg);
  margin-bottom: 10px;
}
.member-search svg { width: 17px; height: 17px; color: var(--faint); flex: none; }
.member-search input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  outline: none;
  padding: 12px 0;
  color: var(--text);
  font-family: var(--body);
  font-size: 14.5px;
}
.member-search input::placeholder { color: var(--faint); }
.member-search:focus-within {
  border-color: #a78bfa;
  box-shadow: 0 0 0 4px rgba(167, 139, 250, .16);
}
:root[data-theme='light'] .member-search { background: #fff; }

.member-hint {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--faint);
  margin: 0 0 14px;
  min-height: 14px;
  line-height: 1.5;
}

/* admin panel shortcut in the public header */
.admin-link {
  color: #c084fc;
  border-color: rgba(192, 132, 252, .45);
  background: rgba(192, 132, 252, .1);
  font-weight: 700;
}
.admin-link:hover { color: #ddd6fe; border-color: rgba(192, 132, 252, .7); }
:root[data-theme='light'] .admin-link {
  color: #7c3aed;
  border-color: rgba(124, 58, 237, .4);
  background: rgba(124, 58, 237, .08);
}
:root[data-theme='light'] .admin-link:hover { color: #6d28d9; }

/* ==========================================================================
   Analytics tab
   ========================================================================== */
.chart {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  height: 180px;
  padding: 10px 4px 0;
}
.chart-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: 100%;
  gap: 6px;
  min-width: 0;
}
.chart-val {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.chart-bar {
  width: 100%;
  max-width: 46px;
  min-height: 4px;
  border-radius: 8px 8px 3px 3px;
  background: linear-gradient(180deg, #a855f7, #d946ef);
  transition: height .4s cubic-bezier(.2, .8, .3, 1);
}
.chart-bar.empty { background: var(--border-2); }
.chart-lbl {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--faint);
  white-space: nowrap;
}

.top-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--border);
}
.top-row:last-child { border-bottom: none; }
.top-title {
  font-weight: 600;
  font-size: 14.5px;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.top-claims {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  flex: none;
  padding: 5px 11px;
  border-radius: 100px;
  border: 1px solid var(--border-2);
  background: var(--surface-2);
}
:root[data-theme='light'] .top-claims { background: #fff; }

/* ==========================================================================
   Role-gated sections
   ========================================================================== */
.board-section { margin-bottom: 44px; }
.board-section:last-child { margin-bottom: 0; }

.section-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}
.section-head h2 {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--display);
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -.03em;
  margin: 0;
}
.section-count {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
  color: var(--faint);
  padding: 6px 12px;
  border-radius: 100px;
  background: var(--surface);
  border: 1px solid var(--border);
}
:root[data-theme='light'] .section-count { background: #fff; }

/* the two gated sections get a subtle tinted rail so they read as special */
.board-section.section-verified .section-head h2 { color: #38bdf8; }
.board-section.section-booster .section-head h2 { color: #f472b6; }
:root[data-theme='light'] .board-section.section-verified .section-head h2 { color: #0369a1; }
:root[data-theme='light'] .board-section.section-booster .section-head h2 { color: #be185d; }

/* section badges (on headings, admin rows, preview) */
.section-badge {
  font-family: var(--body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  padding: 4px 10px;
  border-radius: 100px;
  border: 1px solid var(--border-2);
  white-space: nowrap;
}
.section-badge.verified {
  color: #38bdf8;
  border-color: rgba(56, 189, 248, .5);
  background: rgba(56, 189, 248, .12);
}
.section-badge.booster {
  color: #f472b6;
  border-color: rgba(244, 114, 182, .5);
  background: rgba(244, 114, 182, .12);
}
:root[data-theme='light'] .section-badge.verified { color: #0369a1; }
:root[data-theme='light'] .section-badge.booster { color: #be185d; }

.row-title-line {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.row-title-line .row-title { margin: 0; }
