/* ============== Core Layout ============== */
:root {
  --card-max: 720px;
  --pad: clamp(16px, 2.5vw, 28px);
  --radius: 20px;
  --glass-bg: rgba(10, 10, 20, 0.60);
  --glass-stroke: rgba(255, 255, 255, 0.12);
  --shadow: 0 10px 30px rgba(0,0,0,0.35);
}

html, body {
  height: 100%;
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
}

body {
  min-height: 100%;
  min-height: 100dvh;
  background: #0b0b0b;
  color: #eee;
}

.container {
  min-height: 100%;
  min-height: 100dvh;
  padding-bottom: env(safe-area-inset-bottom);
  display: flex;
  flex-direction: column;
  overflow: visible;
}

.actions {
  position: sticky;
  top: env(safe-area-inset-top, 0);
  z-index: 10;
  overflow: visible;
}

.participants-box {
  overflow: visible;
}

body, .container {
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

button { touch-action: manipulation; }

/* Title: readable horror vibe (outline to pop on bright image) */
.condor-title {
  font-family: "Creepster", cursive;
  font-weight: 400;
  letter-spacing: .5px;
  text-shadow: 0 3px 16px rgba(0,0,0,.55), 0 1px 0 rgba(0,0,0,.9);
  -webkit-text-stroke: 1px rgba(0,0,0,.55); /* subtle edge for contrast */
  color: #fff;
}
.subtext {
  color: #e9ecff;
  text-shadow: 0 2px 8px rgba(0,0,0,.6);
}

/* Stronger legibility where text sits (top-left) */
.vignette {
  position: absolute; inset: 0;
  background:
    radial-gradient(1100px 650px at 24% 18%, rgba(0,0,0,.55) 0%, rgba(0,0,0,.25) 45%, transparent 70%),
    linear-gradient(180deg, rgba(0,0,0,.12) 0%, rgba(0,0,0,.78) 100%);
}

/* Buttons: brighter on dark */
button {
  color: #f7f9ff;
  border-color: rgba(255,255,255,.22);
  background: rgba(255,255,255,.10);
}
button:hover:not(:disabled), button:focus-visible:not(:disabled) {
  background: rgba(255,255,255,.18);
}

/* ===== Eye glint (reduced + calibratable) ===== */
.eye-layer {
  position: absolute; inset: 0; pointer-events: none; z-index: 1;

  /* Calibrate these 2 values to move the glint if your crop changes */
  --eye-base-x: 43%; /* ← move left/right */
  --eye-base-y: 24%; /* ← move up/down */

  /* live offsets from JS get added; leave these alone */
  --eye-left: var(--eye-base-x);
  --eye-top:  var(--eye-base-y);
}

/* Use the computed --eye-left / --eye-top from JS */
.eye-layer .glint,
.eye-layer .halo {
  position: absolute;
  left: var(--eye-left); top: var(--eye-top);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  mix-blend-mode: screen;
  pointer-events: none;
}

.btn { opacity:1; }
.btn[disabled] { opacity:.55; cursor:not-allowed; }

.btn-primary, .btn-secondary, .btn-admin {
  font-weight: 700;
  padding: .65rem .9rem;
  border-radius: .5rem;
  border: 1px solid rgba(0,0,0,.15);
  background: #fff;
  color: #111;
}
.btn-primary { background: #4ade80; border-color: #16a34a; }

.hint { color: #555; margin-top: .35rem; min-height: 1.2em; }
.error { color: #b91c1c; }
.success { color: #166534; }
.status-line { margin-top: .5rem; font-size: .9rem; opacity: .9; }
.status-line::before { content: "• "; }

.admin-panel {
  margin-top: 1rem; padding: .9rem; border: 1px solid #d9d9d9; border-radius: .6rem;
  background: #fff; color: #111;
}
.admin-panel .label { font-weight: 700; color: #111; }
.admin-panel .helper { color: #333; margin:.25rem 0 .5rem; }
.admin-panel input { color: #111; background:#fff; border:1px solid #cfcfcf; border-radius:.4rem; padding:.45rem .6rem; }

.timer { margin-top: .75rem; font-variant-numeric: tabular-nums; }

/* Smaller, softer glint */
.eye-layer .glint {
  width: 22px; height: 22px;
  background: radial-gradient(circle at 42% 42%,
              rgba(255,255,255,.92) 0 4px,
              rgba(255,255,255,.24) 6px,
              rgba(255,210,60,.10) 10px,
              transparent 16px);
  filter: blur(.4px);
  opacity: .85;
}
.eye-layer .halo {
  width: 66px; height: 66px;
  background: radial-gradient(circle,
              rgba(255,170,0,.18) 0 14px,
              rgba(255,0,0,.08) 28px,
              transparent 50px);
  animation: eye-simmer 2.6s ease-in-out infinite alternate;
}

/* Optional: hide glint on small screens if it ever feels too bright */
@media (max-width: 480px) 
 {}
  .eye-layer { display:none; } 

.stage {
  position: relative;
  min-height: 100%;
  min-height: 100dvh;
  display: grid;
  grid-template-rows: 1fr auto;
  padding-bottom: env(safe-area-inset-bottom);
  overflow: visible;
}

/* Full-screen poster */
.poster { position: absolute; inset: 0; margin: 0; overflow: hidden; }
#freakyPoster {
  width: 100%; height: 100%; object-fit: cover; will-change: transform, filter;
  transform-origin: 50% 40%;                 /* anchor near the eyes */
  animation: condor-breathe 7s ease-in-out infinite;
  filter: url(#condorWiggle);
}
.vignette {
  position: absolute; inset: 0;
  background:
    radial-gradient(1200px 700px at 35% 30%, transparent 0%, rgba(0,0,0,.55) 70%),
    linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,.75) 100%);
}

/* Film grain / flicker overlay */
.poster::after {
  content: "";
  position: absolute; inset: -10%;
  background:
    radial-gradient(transparent 60%, rgba(0,0,0,.25) 100%),
    repeating-linear-gradient(0deg, rgba(255,255,255,.02) 0 2px, rgba(0,0,0,.02) 2px 4px);
  mix-blend-mode: overlay;
  pointer-events: none;
  animation: film-flicker 3.5s steps(60) infinite;
  opacity: .9;
}

/* Floating title */
.heroTitle {
  position: relative; z-index: 1;
  padding: clamp(16px, 3vw, 28px);
  color: #f3f3f3;
  text-shadow: 0 2px 10px rgba(0,0,0,.7);
}
.condor-title { font-family: "Creepster", cursive; font-size: clamp(28px, 4vw, 44px); margin: 0 0 6px; }
.subtext { margin: 0; opacity: .95; }

/* Right dock */
.dock {
  position: fixed; right: 16px; top: 16px; bottom: 110px;
  width: min(360px, 92vw);
  z-index: 2;
  border-radius: 18px;
  background: rgba(10,10,20,.55);
  border: 1px solid rgba(255,255,255,.12);
  backdrop-filter: blur(12px) saturate(1.1);
  -webkit-backdrop-filter: blur(12px) saturate(1.1);
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  transition: transform .25s ease, background .25s ease;
  overflow: hidden;
}
@media (hover: hover) and (pointer: fine) {
  .dock:hover, .dock:focus-within { background: rgba(10,10,20,.68); }
}
.dock-inner { padding: 14px 16px; height: 100%; overflow: auto; }
.deeplink { color: #00ff88; font-weight: 700; }

.round-state { margin:.5rem 0; opacity:.9; }

/* Sticky bottom connect button */
.connect-sticky {
  position: sticky; /* sits just above the bottom safe area */
  bottom: env(safe-area-inset-bottom, 12px);
  left: 0; right: 0;
  margin: 16px auto;
  display: block;
  width: min(640px, 92%);
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 18px;
  background: #0f0f0f;
  color: #fff;
  border: 1px solid #444;
  box-shadow: 0 8px 24px rgba(0,0,0,.35);
  z-index: 50;
}
.connect-sticky:disabled {
  opacity: .6;
}

.mm-hint {
  position: sticky;
  bottom: calc(env(safe-area-inset-bottom, 12px) + 68px);
  width: min(640px, 92%);
  margin: 0 auto 8px;
  background: #1d2a22;
  color: #b6ffd0;
  border: 1px solid #2b6349;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 14px;
  z-index: 51;
}

/* Ensure the main card doesn’t block scroll on Android */
.container {
  overflow-x: hidden;
}

/* Top deeplink button styling */
.mobile-open-bar {
  display: flex;
  justify-content: center;
  margin: .5rem 0 1rem;
}
.deeplink-btn {
  background: #0d7a5b;
  color: #e7fff6;
  border: none;
  padding: 10px 14px;
  border-radius: 10px;
  font-weight: 700;
}

/* Participants bottom rail */
.participants {
  position: fixed;
  left: 16px; right: 16px; bottom: 20px;
  z-index: 1;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(0,0,0,.55);
  border: 1px solid rgba(255,255,255,.12);
  color: #e9e9e9;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.participants h4 { margin: 0 0 6px; }

/* Footer */
.footer { position: relative; z-index: 1; padding: 10px var(--pad) 20px; text-align: center; }

/* Buttons quick polish (optional) */
button {
  appearance: none; border: 1px solid rgba(255,255,255,.15);
  background: rgba(255,255,255,.06); color: #f3f3f3;
  border-radius: 10px; padding: 10px 12px; font-weight: 600;
  cursor: pointer; transition: transform .1s ease, background .2s ease, border-color .2s ease;
}
button:disabled { opacity: .55; cursor: not-allowed; }
button:hover:not(:disabled), button:focus-visible:not(:disabled) {
  background: rgba(255,255,255,.12); transform: translateY(-1px);
}

/* Spinner (basic) */
#loader { position: fixed; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.45); z-index: 9; }
#loader.hidden { display: none !important; pointer-events: none !important; opacity: 0 !important; }
.spinner { width:54px;height:54px;border-radius:50%;border:6px solid #ffffff66;border-top-color:#fff;animation:spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Drawer shell */
.drawer {
  position: fixed;
  top: 0;
  right: -360px;                 /* hidden */
  width: 320px;                  /* narrow so it never covers timer */
  height: 100vh;
  background: #121113;           /* dark panel for contrast */
  color: #f5f5f7;
  box-shadow: -8px 0 24px rgba(0,0,0,.45);
  border-left: 1px solid rgba(255,255,255,.08);
  transition: right .28s ease;
  z-index: 60;                   /* below wallet modals if they use 100+ */
  display: flex; flex-direction: column;
}
.drawer.open { right: 0; }

.drawer-title {
  margin: 14px 16px 8px;
  font-weight: 700;
}

.drawer-body { padding: 0 16px 16px; overflow-y: auto; }
.lr-row { margin: 8px 0; color: #e9e9ee; }
.lr-error { margin-top: 8px; color: #ff6b6b; font-size: .9rem; }

.btn-claim {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid #4ade80;
  background: #1a1f1a;
  color: #eaffea;
  font-weight: 700;
  cursor: pointer;
}
.btn-claim:disabled { opacity: .6; cursor: not-allowed; }

.drawer-close {
  position: absolute; top: 8px; left: 8px;
  width: 32px; height: 32px; border-radius: 6px;
  border: 1px solid rgba(255,255,255,.15);
  background: transparent; color: #fff; font-size: 20px; line-height: 30px;
}

/* Pull tab — matches Rules pattern, placed on right */
.drawer-tab {
  position: fixed;
  right: 12px; bottom: 120px;         /* above footer buttons & timer */
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.15);
  background: rgba(18,17,19,.75);
  color: #fff; font-weight: 700;
  backdrop-filter: blur(6px);
  z-index: 61;                        /* above drawer */
}
.drawer-tab-right { /* reserved for future variants */ }

/* Light theme safety (if any) */
body:not(.freaky-mode) .drawer { background: #ffffff; color: #171717; }
body:not(.freaky-mode) .lr-row { color: #202022; }
body:not(.freaky-mode) .btn-claim { background: #f7fff7; color: #0d3b0d; border-color:#16a34a; }
body:not(.freaky-mode) .drawer-close { color: #111; border-color: #e5e7eb; }
body:not(.freaky-mode) .drawer-tab { background: rgba(255,255,255,.9); color: #111; border-color:#e5e7eb; }

/* Ensure it never hides the in‑card countdown bar */
#timerContainer { z-index: 30; }  /* timer stays visible over page, below tabs */


/* ============== Dynamic Poster FX ============== */
@keyframes condor-breathe {
  0%   { transform: scale(1.04) translateZ(0); }
  50%  { transform: scale(1.07) translateZ(0); }
  100% { transform: scale(1.04) translateZ(0); }
}
@keyframes film-flicker {
  0% { transform: translate3d(0,0,0); }
  100% { transform: translate3d(0,-2%,0); }
}

/* Eye glint */
.eye-layer {
  position: absolute; inset: 0; pointer-events: none; z-index: 1;
  --eye-left: 46%;
  --eye-top: 27%;
}
.eye-layer .glint,
.eye-layer .halo {
  position: absolute; left: var(--eye-left); top: var(--eye-top);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  mix-blend-mode: screen;
  pointer-events: none;
}
.eye-layer .glint {
  width: 32px; height: 32px;
  background: radial-gradient(circle at 40% 40%, rgba(255,255,255,.95) 0 6px, rgba(255,255,255,.25) 9px, rgba(255,200,0,.12) 14px, transparent 22px);
  filter: blur(.6px);
}
.eye-layer .halo {
  width: 84px; height: 84px;
  background: radial-gradient(circle, rgba(255,170,0,.22) 0 18px, rgba(255,0,0,.10) 35px, transparent 60px);
  animation: eye-simmer 2.6s ease-in-out infinite alternate;
}
@keyframes eye-simmer {
  from { opacity: .75; transform: translate(-50%,-50%) scale(0.97); }
  to   { opacity: 1;    transform: translate(-50%,-50%) scale(1.03); }
}

/* Heartbeat state (added by JS when countdown <= 60s) */
.heartbeat #freakyPoster {
  animation: condor-breathe 7s ease-in-out infinite, heart-pulse 1.05s ease-in-out infinite;
  filter: url(#condorWiggle) brightness(1.03) contrast(1.03);
}
.heartbeat .vignette {
  background:
    radial-gradient(1200px 700px at 35% 30%, rgba(180,0,0,.18) 0%, rgba(0,0,0,.55) 70%),
    linear-gradient(180deg, rgba(60,0,0,.25) 0%, rgba(0,0,0,.8) 100%);
}
@keyframes heart-pulse {
  0%   { transform: scale(1.070); }
  20%  { transform: scale(1.090); }
  35%  { transform: scale(1.075); }
  60%  { transform: scale(1.095); }
  100% { transform: scale(1.070); }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  #freakyPoster, .poster::after { animation: none !important; }
  #freakyPoster { transform: none; filter: none; }
  .heartbeat .vignette { background: none; }
}

/* Mobile tweaks */
@media (max-width: 768px) {
  .dock {
    left: 16px; right: 16px; top: auto; bottom: 96px;
    width: auto; height: auto;
  }
}
/* ==== Dock “tab” control ==== */
.dock {
  /* existing styles… */
  transition: transform .25s ease, background .25s ease, top .25s ease, bottom .25s ease;
}

/* Handle strip at the top of the dock */
.dock-handle {
  display: grid; grid-template-columns: 24px 1fr 18px; align-items: center;
  width: 100%;
  margin: -2px 0 10px;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  color: #f6f7ff; font-weight: 700; letter-spacing: .2px;
  cursor: pointer;
}
.dock-handle .grip { opacity: .7; }
.dock-handle .chev { opacity: .85; transition: transform .25s ease; }
.dock.collapsed .dock-handle .chev { transform: rotate(-180deg); }

/* Collapsed (tab-only) state */
.dock.collapsed {
  height: 56px; overflow: hidden;
}

/* Snap positions (desktop default: right side). Use one of these classes */
.dock.pos-top    { top: 16px;  bottom: auto; }
.dock.pos-bottom { top: auto;  bottom: 16px; }

/* Auto-hide on scroll (slides off-screen slightly) */
.dock.autohide.hide {
  transform: translateY(12px) translateX(0) translateZ(0);
  opacity: .96;
}

/* Mobile defaults: bottom & full width */
@media (max-width: 768px) {
  .dock { left: 16px; right: 16px; width: auto; }
  .dock.pos-top    { top: auto; bottom: 96px; }   /* keep it out of notch area */
  .dock.pos-bottom { bottom: 96px; top: auto; }
}

/* Optional: subtle grab cursor while dragging */
.dock.grabbing, .dock-handle:active { cursor: grabbing; }

/* Buttons & chips */
.ff-btn{padding:.6rem .9rem;border-radius:12px;background:#1f8bff;color:#fff;border:0}
.ff-btn:hover{filter:brightness(.95)}
.ff-btn-secondary{padding:.55rem .85rem;border-radius:10px;background:#23262f;color:#e7e9ee;border:1px solid #343845}
.ff-chip{margin-left:.4rem;background:#2a3040;color:#b9c2d0;padding:.1rem .45rem;border-radius:999px;font-size:.8rem}

/* Friendlier 'Already joined' badge */
.ff-joined-badge{display:inline-flex;align-items:center;gap:.4rem;background:#133621;border:1px solid #1b4b2c;
  color:#a8f0c4;border-radius:999px;padding:.25rem .6rem;font-weight:600}

/* Participants drawer (left) */
.ff-drawer{position:fixed;inset:0 auto 0 0;width:min(92vw,420px);background:#0e1117;color:#e7e9ee;
  transform:translateX(-100%);transition:transform .28s ease;z-index:60;display:flex;flex-direction:column;border-right:1px solid #1c2230}
.ff-drawer.open{transform:translateX(0)}
.ff-drawer-header{display:flex;align-items:center;justify-content:space-between;padding:14px 16px;border-bottom:1px solid #1c2230}
.ff-icon-btn{background:transparent;border:0;color:#9aa5b1;font-size:1rem}
.ff-icon-btn:hover{color:#fff}
.ff-drawer-footer{padding:12px 16px;border-top:1px solid #1c2230}

/* Overlay behind drawer */
.ff-drawer-overlay{position:fixed;inset:0;background:rgba(0,0,0,.45);opacity:0;pointer-events:none;transition:opacity .25s ease;z-index:50}
.ff-drawer-overlay.show{opacity:1;pointer-events:auto}

/* Participant list */
.ff-participants{padding:10px 8px 80px;overflow:auto;flex:1;list-style:none;margin:0}
.ff-row{display:flex;align-items:center;gap:10px;padding:10px;border-radius:12px;background:#121722;border:1px solid #1c2230;margin:6px 8px}
.ff-ava{width:28px;height:28px;border-radius:8px;background:#20293a;display:grid;place-items:center;color:#9fb3ff;font-weight:700}
.ff-addr{font-family:ui-monospace, SFMono-Regular, Menlo, monospace;font-size:.92rem;color:#dbe3f3;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1}
.ff-badge{font-size:.72rem;background:#20324a;color:#9cc6ff;border:1px solid #2a3e5e;border-radius:999px;padding:.1rem .45rem}
.ff-copy{background:#1e2430;border:1px solid #2c3546;color:#b7c1d8;border-radius:10px;padding:.25rem .5rem}

.ff-copy:hover{background:#263146}

/* Player count & link */
.ff-stats{display:flex;gap:10px;align-items:center;margin:.5rem 0 0}
.ff-pill{background:#1a2130;color:#cfe0ff;border:1px solid #233047;border-radius:999px;padding:.2rem .6rem;font-weight:600}
.ff-link{background:transparent;border:0;color:#79a8ff;text-decoration:underline}

/* Timer & progress bar */
.ff-timer{margin:.6rem 0 0}
.ff-timer-row{display:flex;justify-content:space-between;align-items:center;margin-bottom:.35rem}
.ff-progress{height:8px;background:#1b2332;border-radius:999px;overflow:hidden;border:1px solid #243149}
#ff-progress-bar{height:100%;width:0%;background:linear-gradient(90deg,#1f8bff,#6dd5fa)}
.ff-join-disabled{opacity:.6;pointer-events:none}

/* Floating tab */
#rulesTab{
  position: fixed;
  left: 0;
  top: 40%;
  transform: translateY(-50%);
  padding: .6rem .9rem;
  border-radius: 0 6px 6px 0;
  background: rgba(0,0,0,.65);
  color: #fff; border: 1px solid rgba(255,255,255,.2);
  z-index: 1100;
}
@media (max-width: 640px){
  #rulesTab{ left: auto; right: 12px; bottom: 12px; top: auto; transform:none; border-radius: 24px; padding:.8rem 1rem; }
}

#openLastRound{
  position: fixed;
  left: 0;
  top: 55%;
  transform: translateY(-50%);
  padding: .6rem .9rem;
  border-radius: 0 6px 6px 0;
  background: rgba(0,0,0,.65);
  color: #fff; border: 1px solid rgba(255,255,255,.2);
  z-index: 1100;
}
@media (max-width: 640px){
  #openLastRound{ left: auto; right: 12px; bottom: 64px; top: auto; transform:none; border-radius: 24px; padding:.8rem 1rem; }
}

/* Backdrop */
#rulesBackdrop{
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 1090;
}

/* Drawer */
#rulesDrawer{
  position: fixed; top:0; right:0; height:100vh; width:min(480px, 92vw);
  background: #121212; color:#fff;
  transform: translateX(100%);
  transition: transform .28s ease-out;
  z-index: 1110; display:flex; flex-direction:column;
  box-shadow: -6px 0 24px rgba(0,0,0,.45);
}
#rulesDrawer.open{ transform: translateX(0); }
@media (max-width: 480px){
  #rulesDrawer{ left:0; right:0; bottom:0; top:auto; height:70vh; width:100%; transform: translateY(100%); }
  #rulesDrawer.open{ transform: translateY(0); }
}



.rules__header{
  display:flex; align-items:center; justify-content:space-between;
  padding: 1rem 1rem; border-bottom: 1px solid rgba(255,255,255,.08);
}
.rules__body{ padding: 1rem 1rem 1.25rem; overflow:auto; line-height:1.5; gap:.5rem; display:flex; flex-direction:column; }
.rules__body h3{ margin:.5rem 0; }
.rules__footer{ padding: .75rem 1rem; border-top: 1px solid rgba(255,255,255,.08); }
.rules__link{ color:#71e0a9; text-decoration: underline; }
#rulesClose{ background:transparent; color:#fff; border:none; font-size:1.2rem; }

/* Freaky site-wide theme toggled on <body class="freaky-mode"> */
body.freaky-mode {
  --brand-bg: #0a0014;
  --brand-accent: #7b00ff;
  --brand-accent-2: #e4007c;
  background: radial-gradient(1200px 800px at 50% -20%, #1c0038, #0a0014 60%);
  color: #f5f0ff;
}
body.freaky-mode .mode-badge { background: linear-gradient(90deg, #7b00ff, #e4007c); }
body.freaky-mode .button, body.freaky-mode button {
  border-color:#7b00ff; color:#fff; background:#1c0038;
}
body.freaky-mode a { color:#e6b3ff; }

@media (prefers-reduced-motion: no-preference) {
  body.freaky-mode {
    animation: subtlePulse 8s ease-in-out infinite;
  }
  @keyframes subtlePulse {
    0%,100% { filter:saturate(1); }
    50%     { filter:saturate(1.15); }
  }
}

/* Mode badge */
.mode-badge {
  display:inline-block; padding:.25rem .6rem; border-radius:.5rem;
  font-weight:600; background:#ececec; color:#333;
}

/* Admin panel */
.admin-panel {
  margin-top:1rem; padding:.75rem; border:1px solid #ddd; border-radius:.5rem; background:#fff;
}
.admin-panel input,
.admin-panel .label,
.admin-panel .helper {
  color: #111;
}
.admin-panel .hint {
  color: #555;
}
.admin-actions { display:flex; gap:.5rem; }
.admin-status { margin-top:.5rem; min-height:1.2em; }
.btn-admin {
  padding: .5rem .75rem;
  border: 1px solid #999;
  border-radius: .4rem;
  background: #fff;
  font-weight: 600;
  cursor: pointer;
}
.btn-admin:disabled { opacity:.55; cursor:not-allowed; }
.btn-admin.danger { border-color:#7b1d6b; color:#7b1d6b; }
.admin-card { border:1px solid #ddd; border-radius:.5rem; padding:.75rem; margin:.75rem 0; background:#fafafa; }
.admin-card-header { font-weight:700; margin-bottom:.5rem; }
.sr-only { position:absolute; left:-9999px; }

/* Freaky theme */
body.freaky-mode {
  background: radial-gradient(1200px 600px at 50% -10%, #2a002e 0%, #0f0011 60%, #050007 100%);
  color: #f3f2f4;
}
body.freaky-mode .mode-badge {
  background:#2c0a2f; color:#f7d1f7; box-shadow:0 0 12px rgba(251,98,255,.35);
}
body.freaky-mode .btn-admin {
  border-color: #f06;
  color: #f7d1f7;
}
body.freaky-mode .btn-admin.danger {
  background: #3a003f;
  border-color: #ff4db3;
}

/* One-click join helpers */
.cta:disabled { opacity:.6; cursor:not-allowed; }

.overlay {
  position: fixed; inset: 0; display: grid; place-items: center;
  background: rgba(0,0,0,.55); z-index: 9999;
}
.overlay-inner { background:#111; color:#fff; padding:1rem 1.25rem; border-radius:.75rem; }
.spinner {
  width: 28px; height: 28px; border-radius: 50%;
  border: 3px solid #999; border-top-color: transparent;
  animation: spin 0.75s linear infinite; margin: 0 auto .5rem;
}
@keyframes spin { to { transform: rotate(360deg); } }

