/* The Big Tent: game-night ballot box and upcoming nights. Built on /styles.css tokens: crimson, gold, bone on night ground. */
.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding-block: 28px; color: var(--muted); font-size: 14px; }
.gn { padding-block: 56px 80px; display: grid; gap: 28px; max-width: 1040px; }
.gn-head { text-align: center; }
.gn-head h1 { font-family: var(--display); font-weight: 900; font-size: clamp(40px, 7vw, 76px); line-height: 1.05; margin: 6px 0 0; }
.gn-head .lede { margin: 18px auto 0; }

.gn-app { display: grid; gap: 20px; }
.gn-note { text-align: center; color: var(--muted); }
.panel { background: var(--band); border: 1px solid var(--line); border-radius: 10px; padding: clamp(18px, 3vw, 28px); display: grid; gap: 16px; }
.panel h2 { margin: 0; font-size: clamp(24px, 3vw, 32px); }
.panel h2::after { display: none; }
.panel-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 16px; }
.meta { color: var(--muted); font-size: 14px; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; letter-spacing: .04em; border: 1px solid var(--line-strong); color: var(--text-soft); }
.pill.open { border-color: #4F9E6A; color: #9FE0B4; }
.pill.closed { border-color: var(--gold); color: var(--gold); }
.pill.scheduled { border-color: var(--gold); background: var(--gold); color: var(--ink); }
.msg { margin: 0; padding: 10px 14px; border-radius: 6px; border: 1px solid var(--line-strong); color: var(--text); }
.msg.error { border-color: #C8364E; }
.msg.ok { border-color: #4F9E6A; }

.btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
button.btn { border: 0; cursor: pointer; font: inherit; font-weight: 600; }
button.btn:disabled { opacity: .5; cursor: not-allowed; }
button.btn-ghost { border: 1px solid var(--line-strong); }
button.btn-ghost:hover { border-color: var(--gold); }
.btn-danger { border: 1px solid #C8364E; color: #F2B6C0; background: transparent; }
.btn-danger:hover { background: rgba(200, 54, 78, .15); color: #F2B6C0; }
.linklike { background: none; border: 0; padding: 10px 4px; min-height: 44px; font: inherit; color: var(--gold); text-decoration: underline; cursor: pointer; }

/* Ballot: four ticket slots + the candidate board */
.ballot { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 20px; align-items: start; }
.slots { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.slot { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 12px; min-height: 60px; padding: 8px 10px 8px 8px; border: 1px dashed var(--gold); border-radius: 8px; background: var(--ground); }
.slot.empty { border-color: var(--line-strong); color: var(--muted); }
.slot .rank { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 6px; background: var(--crimson); color: #F4ECE0; font-family: var(--serif); font-weight: 700; font-size: 18px; }
.slot.empty .rank { background: var(--raised); color: var(--muted); }
.slot .name { font-weight: 600; overflow-wrap: anywhere; }
.slot .pts { display: block; font-size: 12.5px; color: var(--muted); font-weight: 500; }
.slot-tools { display: flex; gap: 4px; }
.icon-btn { width: 40px; height: 40px; border-radius: 6px; border: 1px solid var(--line-strong); background: transparent; color: var(--text); font-size: 18px; cursor: pointer; }
.icon-btn:hover { border-color: var(--gold); }
.icon-btn:disabled { opacity: .35; cursor: not-allowed; }

.board { display: grid; gap: 8px; }
.board-filter { min-height: 44px; padding: 8px 14px; border-radius: 6px; border: 1px solid var(--line-strong); background: var(--raised); color: var(--text); font: inherit; }
.board-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; max-height: 520px; overflow-y: auto; }
.cand { width: 100%; min-height: 48px; text-align: left; padding: 10px 12px; border-radius: 6px; border: 1px solid var(--line); background: var(--raised); color: var(--text); font: inherit; font-weight: 500; cursor: pointer; display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.cand:hover { border-color: var(--gold); }
.cand[aria-pressed="true"] { border-color: var(--gold); background: rgba(217, 178, 106, .12); }
.cand .tag { font-family: var(--serif); font-size: 12px; color: var(--gold); white-space: nowrap; }

/* Results */
.results { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.result { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 14px; border-radius: 8px; border: 1px solid var(--line); background: var(--ground); }
.result.win { border-color: var(--gold); box-shadow: 0 0 0 1px rgba(217, 178, 106, .25), 0 0 22px rgba(217, 178, 106, .12); }
.result .place { font-family: var(--serif); font-weight: 700; font-size: 18px; color: var(--gold); text-align: center; }
.result:not(.win) .place { color: var(--muted); }
.result .score { font-variant-numeric: tabular-nums; color: var(--text-soft); font-size: 14px; text-align: right; }
.result .score b { color: var(--text); font-size: 16px; }

/* Forms */
.field { display: grid; gap: 6px; }
.field label, .field .label { font-family: var(--serif); letter-spacing: .12em; font-size: 12.5px; color: var(--muted); text-transform: uppercase; }
.field input { min-height: 44px; padding: 8px 12px; border-radius: 6px; border: 1px solid var(--line-strong); background: var(--raised); color: var(--text); font: inherit; color-scheme: dark; }
.field input:focus, .board-filter:focus { outline: 2px solid var(--gold); outline-offset: 2px; }
.when { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; align-items: end; }
.picklist { display: grid; gap: 16px; }
.picklist h3 { margin: 0; font-family: var(--serif); font-size: 15px; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); }
.checks { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px; max-height: 360px; overflow-y: auto; }
.checks label { display: flex; gap: 10px; align-items: center; min-height: 40px; padding: 6px 10px; border-radius: 6px; border: 1px solid var(--line); background: var(--raised); cursor: pointer; }
.checks input { width: 18px; height: 18px; accent-color: var(--gold); }
.checks label:has(input:checked) { border-color: var(--gold); }

.event-card { display: grid; gap: 10px; padding: 20px; border: 1px dashed var(--gold); border-radius: 10px; background: var(--ground); text-align: center; }
.event-card .when-big { font-family: var(--display); font-weight: 700; font-size: clamp(22px, 3.2vw, 32px); }
.event-card ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 18px; }

.who { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px 10px; color: var(--muted); font-size: 14px; }
.gn-how { max-width: 720px; margin: 0 auto; color: var(--text-soft); }
.gn-how summary { cursor: pointer; color: var(--gold); font-weight: 600; min-height: 44px; display: flex; align-items: center; }

@media (max-width: 760px) {
  .ballot { grid-template-columns: 1fr; }
  .board-list { max-height: none; }
}

.gn-upcoming { display: grid; gap: 14px; }
.gn-upcoming h2 { margin: 0; }
.gn-upcoming .night-game { display: grid; gap: 2px; flex: 1 1 260px; min-width: 0; }
.gn-upcoming .lineup { color: var(--text-soft); font-weight: 400; font-size: 15.5px; }

/* ---------- Cover thumbnails ---------- */
.thumb { width: 64px; height: 30px; flex: 0 0 auto; border-radius: 4px; object-fit: cover; background: var(--raised); display: inline-grid; place-items: center; }
.thumb-sm { width: 46px; height: 21px; }
.thumb-none { font-family: var(--serif); font-weight: 700; font-size: 12px; color: var(--gold); border: 1px solid var(--line-strong); }
.cand { justify-content: flex-start; }
.cand-name { flex: 1; min-width: 0; }
.slot { grid-template-columns: 44px auto minmax(0, 1fr) auto; }
.result { grid-template-columns: 40px minmax(0, 1fr) auto; }
.result-name { display: flex; align-items: center; gap: 12px; min-width: 0; }

/* ---------- Wheel of Doom: offer ---------- */
.doom-offer { border-color: #7A1625; background: radial-gradient(ellipse at 50% 0%, rgba(200, 54, 78, .18), transparent 70%), var(--band); text-align: center; justify-items: center; }
.doom-offer p { max-width: 60ch; margin: 0; color: var(--text-soft); }
.doom-kicker { font-family: var(--serif); letter-spacing: .3em; text-transform: uppercase; font-size: 13px; color: #F2B6C0 !important; }
.doom-btn { background: linear-gradient(180deg, #C8364E, #7A1625); color: #FFF1E6; border: 1px solid #F2B6C0; box-shadow: 0 0 22px rgba(200, 54, 78, .45); }
.doom-btn:hover { color: #FFF1E6; box-shadow: 0 0 34px rgba(200, 54, 78, .7); }
.doom-btn[data-armed] { animation: armed .5s ease-in-out infinite alternate; }
@keyframes armed { to { box-shadow: 0 0 46px rgba(255, 79, 99, .95); } }
.doom-locked { border-color: #7A1625; }
.slot.doomed { border-style: solid; border-color: #C8364E; }

/* ---------- Wheel of Doom: the show ---------- */
.doom-dialog { width: min(720px, calc(100vw - 32px)); max-height: calc(100vh - 32px); overflow-y: auto; padding: clamp(20px, 4vw, 36px); border: 1px solid #C8364E; border-radius: 16px; color: var(--text); text-align: center;
  background: radial-gradient(ellipse at 50% 0%, rgba(200, 54, 78, .28), transparent 65%), #0B080C; box-shadow: 0 0 0 1px rgba(217, 178, 106, .25), 0 0 80px rgba(200, 54, 78, .45); }
.doom-dialog::backdrop { background: radial-gradient(circle at 50% 40%, rgba(122, 22, 37, .55), rgba(5, 3, 6, .92) 70%); backdrop-filter: blur(4px); }
.doom-dialog[open] { animation: doom-in .55s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes doom-in { from { transform: scale(.6) rotate(-4deg); opacity: 0; } to { transform: none; opacity: 1; } }

.doom-intro { display: grid; gap: 14px; padding-block: 24px; }
.doom-intro.leaving { animation: doom-out .45s ease-in forwards; }
@keyframes doom-out { to { transform: scale(1.3); opacity: 0; filter: blur(6px); } }
.doom-small { margin: 0; font-family: var(--serif); letter-spacing: .4em; text-transform: uppercase; color: var(--muted); animation: fade-up .6s .1s both; }
.doom-title { position: relative; margin: 0; font-family: var(--display); font-weight: 900; font-size: clamp(34px, 7vw, 62px); line-height: 1.05; color: #FFE3E3;
  text-shadow: 0 0 8px rgba(255, 79, 99, .9), 0 0 28px rgba(200, 54, 78, .8), 0 0 60px rgba(200, 54, 78, .5);
  animation: slam .7s .25s cubic-bezier(.2, 1.6, .4, 1) both, shake .5s 1s 2, flicker 2.4s 1.6s infinite; }
.doom-title.small { font-size: clamp(24px, 4.4vw, 38px); animation: slam .6s cubic-bezier(.2, 1.6, .4, 1) both; }
.doom-quip { margin: 0 auto; max-width: 44ch; font-size: 18px; font-style: italic; color: var(--gold); animation: fade-up .6s 1.1s both; }
@keyframes slam { from { transform: scale(2.4); opacity: 0; letter-spacing: .3em; } to { transform: none; opacity: 1; } }
@keyframes shake { 0%, 100% { transform: translate(0); } 20% { transform: translate(-6px, 2px) rotate(-1deg); } 40% { transform: translate(5px, -2px) rotate(1deg); } 60% { transform: translate(-4px, 1px); } 80% { transform: translate(3px, -1px); } }
@keyframes flicker { 0%, 88%, 100% { opacity: 1; } 90% { opacity: .55; } 92% { opacity: 1; } 95% { opacity: .7; } }
@keyframes fade-up { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }

.doom-show { display: grid; gap: 16px; justify-items: center; }
.wheel-holder { width: min(380px, 78vw); max-width: 100%; aspect-ratio: 1; }
.wheel { width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 0 24px rgba(200, 54, 78, .5)); }
.wheel-label { fill: #F4ECE0; font-family: 'Barlow', sans-serif; font-weight: 600; }
.wheel-bulbs { animation: bulbs-spin 2s linear infinite; transform-box: view-box; transform-origin: 0 0; }
@keyframes bulbs-spin { to { stroke-dashoffset: -16.4; } }
.doom-status { margin: 0; min-height: 1.5em; font-family: var(--serif); letter-spacing: .08em; font-size: 18px; color: var(--gold); }

.doom-cards { list-style: none; margin: 0; padding: 0; width: 100%; display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; perspective: 900px; }
.doom-card { height: 132px; }
.doom-card-inner { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .8s cubic-bezier(.3, 1.4, .5, 1); }
.doom-card.flipped .doom-card-inner { transform: rotateY(180deg); }
.doom-face { position: absolute; inset: 0; border-radius: 10px; backface-visibility: hidden; display: grid; place-items: center; align-content: center; gap: 6px; padding: 10px; }
.doom-back { background: repeating-linear-gradient(45deg, #7A1625 0 10px, #4A0C17 10px 20px); border: 2px solid var(--gold); }
.doom-back span { font-family: var(--display); font-size: 42px; color: var(--gold); text-shadow: 0 0 12px rgba(217, 178, 106, .7); }
.doom-front { transform: rotateY(180deg); background: #140E12; border: 2px solid var(--gold); box-shadow: 0 0 24px rgba(217, 178, 106, .35); }
.doom-front .rank { font-family: var(--serif); font-weight: 700; color: var(--gold); }
.doom-front .name { font-weight: 600; font-size: 14px; line-height: 1.25; }
.thumb.doom-art { width: 100px; height: 47px; }

.doom-verdict { display: grid; gap: 18px; justify-items: center; margin-top: 6px; }
.doom-stamp { margin: 0; padding: 6px 18px; border: 4px solid #C8364E; border-radius: 8px; color: #FF7A8C; font-family: var(--display); font-weight: 900; font-size: 30px; letter-spacing: .12em; transform: rotate(-8deg);
  animation: stamp .45s .35s cubic-bezier(.2, 1.8, .4, 1) both; }
@keyframes stamp { from { transform: scale(3) rotate(-20deg); opacity: 0; } to { transform: rotate(-8deg); opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .doom-dialog[open], .doom-intro.leaving, .doom-small, .doom-title, .doom-title.small, .doom-quip, .doom-stamp, .wheel-bulbs, .doom-btn[data-armed] { animation: none !important; }
  .doom-card-inner { transition: none; }
}
.slot.empty > span:last-child { justify-self: start; }
.doom-sound { justify-self: end; font-size: 14px; padding: 4px 8px; min-height: 36px; }

/* Discord connection check (Ringleaders) */
.discord-check summary { cursor: pointer; font-family: var(--serif); font-weight: 700; letter-spacing: .06em; min-height: 44px; display: flex; align-items: center; color: var(--gold); }
.checks-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.check { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 10px; align-items: start; padding: 10px 12px; border-radius: 6px; border: 1px solid var(--line); background: var(--ground); }
.check .mark { font-weight: 700; text-align: center; }
.check.good .mark { color: #7FD69B; }
.check.bad { border-color: #C8364E; }
.check.bad .mark { color: #FF7A8C; }
.check .fix { display: block; margin-top: 2px; font-size: 14px; color: var(--text-soft); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
