/* Karaoke Triario - tema Triario (manual de marca, skill triario-html) + capa de Halloween.
   Fondo "Dark Primary" de la marca como noche; rojo/violeta/amarillo oficiales como acentos. */
:root {
  --bg: #1E0C21;
  --bg-2: #361133;
  --card: rgba(255, 248, 248, .045);
  --card-line: rgba(255, 233, 233, .12);
  --text: #FFF8F8;
  --muted: rgba(255, 233, 233, .68);
  --red: #EF2222;
  --red-dark: #EF2222;
  --cyan: #8A86FF;      /* tinte del secundario #534DFF, legible sobre oscuro */
  --magenta: #534DFF;
  --gold: #F8D53C;
  --font-heading: 'Gabarito', sans-serif;
  --font-body: 'Plus Jakarta Sans', Arial, sans-serif;
  --shadow-brand: 0 20px 60px rgba(239, 34, 34, .2);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: linear-gradient(160deg, var(--bg-2) 0%, var(--bg) 62%) fixed;
  color: var(--text);
  font-family: var(--font-body);
  min-height: 100vh;
  overflow-x: hidden;
}

.glow { position: fixed; border-radius: 50%; filter: blur(90px); opacity: .35; z-index: 0; pointer-events: none; }
.glow-a { width: 420px; height: 420px; background: var(--magenta); top: -120px; right: -80px; animation: float 14s ease-in-out infinite; }
.glow-b { width: 380px; height: 380px; background: var(--cyan); bottom: -140px; left: -90px; animation: float 18s ease-in-out infinite reverse; }
@keyframes float { 50% { transform: translate3d(40px, 30px, 0) scale(1.1); } }

header, nav, main { position: relative; z-index: 1; }

header {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 24px 8px; flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: 14px; }
.logo { width: 44px; height: 44px; flex: none; object-fit: contain; filter: drop-shadow(0 0 14px rgba(239, 34, 34, .55)); }
h1 { margin: 0; font-size: 26px; letter-spacing: .5px; }
h1 span { color: var(--red); text-shadow: 0 0 18px rgba(239, 34, 34, .6); }
.tagline { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.header-right { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.pill {
  padding: 6px 12px; border-radius: 999px; font-size: 12px;
  background: rgba(138, 134, 255, .12); border: 1px solid rgba(138, 134, 255, .35); color: var(--cyan);
}

button, .btn {
  font: inherit; cursor: pointer; border-radius: 10px; padding: 9px 14px; text-decoration: none;
  border: 1px solid var(--card-line); background: rgba(255, 255, 255, .06); color: var(--text);
  transition: transform .08s ease, box-shadow .2s ease, background .2s ease;
  display: inline-block;
}
button:hover, .btn:hover { background: rgba(255, 255, 255, .12); color: var(--text); }
button:active { transform: translateY(1px); }
button.primary {
  background: linear-gradient(135deg, var(--red), var(--magenta)); border: none; font-weight: bold;
  box-shadow: 0 6px 22px rgba(239, 34, 34, .35);
}
button.primary:hover { box-shadow: 0 8px 30px rgba(83, 77, 255, .5); }
button.big { width: 100%; padding: 14px; font-size: 17px; letter-spacing: .5px; }
button.tiny, .btn.tiny { padding: 5px 10px; font-size: 12px; }
button:disabled { opacity: .45; cursor: not-allowed; }

.tabs { display: flex; gap: 6px; padding: 8px 24px 0; flex-wrap: wrap; }
.tab { background: transparent; border: none; color: var(--muted); padding: 10px 14px; border-radius: 10px 10px 0 0; }
.tab:hover { background: rgba(255, 255, 255, .04); }
.tab.active { color: var(--text); background: var(--card); border: 1px solid var(--card-line); border-bottom-color: transparent; }

main { padding: 12px 24px 90px; max-width: 1180px; margin: 0 auto; }
.panel { display: none; }
.panel.active { display: block; }

.card {
  background: var(--card); border: 1px solid var(--card-line); border-radius: 16px;
  padding: 20px 20px 22px; margin-bottom: 16px; backdrop-filter: blur(8px);
}
.card h2 { margin: 0 0 6px; font-size: 17px; }
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.counter { color: var(--muted); font-size: 13px; }
.hint { color: var(--muted); font-size: 13px; margin: 6px 0 12px; }
.err { color: var(--red); font-size: 13px; min-height: 18px; }
.card .row + .row { margin-top: 12px; }
h2 + .row { margin-top: 12px; }

.stage-grid { display: grid; grid-template-columns: minmax(280px, 380px) 1fr; gap: 16px; }
.stage-grid.solo { grid-template-columns: 1fr; }
@media (max-width: 860px) { .stage-grid { grid-template-columns: 1fr; } }

/* ---------- ruleta ---------- */
.wheel-wrap { position: relative; width: 100%; aspect-ratio: 1; margin: 6px auto 14px; max-width: 340px; }
.wheel {
  position: absolute; inset: 0; border-radius: 50%;
  border: 6px solid rgba(255, 255, 255, .12);
  box-shadow: 0 0 40px rgba(83, 77, 255, .30), inset 0 0 40px rgba(0, 0, 0, .55);
  background: #2a0f2b;
  transition: transform 4.2s cubic-bezier(.12, .72, .06, 1);
}
.wheel-hub {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 74px; height: 74px; border-radius: 50%; display: grid; place-items: center;
  background: #1E0C21; border: 2px solid rgba(255, 255, 255, .18); font-size: 12px; letter-spacing: 1px;
  color: var(--muted); text-align: center; pointer-events: none;
}
.pointer {
  position: absolute; left: 50%; top: -14px; transform: translateX(-50%);
  width: 0; height: 0; border-left: 12px solid transparent; border-right: 12px solid transparent;
  border-top: 22px solid var(--gold); z-index: 3;
  filter: drop-shadow(0 0 8px rgba(248, 213, 60, .9));
}
.wheel-labels { position: absolute; inset: 0; pointer-events: none; }

/* Las fichas de la ruleta muestran la FOTO de quien canta, no el nombre (pedido 2026-08-26).
   El slot coloca el sector (transform inline desde app.js) y la cara contra-rota para que
   la foto quede derecha; la transicion es la MISMA que .wheel para que no se incline al girar. */
.wheel-slot { position: absolute; left: 50%; top: 50%; transform-origin: 0 0; }
.wheel-face {
  display: flex; align-items: center; justify-content: center; pointer-events: auto;
  transition: transform 4.2s cubic-bezier(.12, .72, .06, 1);
}
.wheel-av {
  width: var(--wheel-av, 44px); height: var(--wheel-av, 44px); border-radius: 50%;
  overflow: hidden; flex: none; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--red-dark), var(--magenta));
  color: #fff; font-weight: bold; font-size: calc(var(--wheel-av, 44px) * .34);
  border: 2px solid rgba(30, 12, 33, .85); box-shadow: 0 2px 10px rgba(0, 0, 0, .55);
}
.wheel-av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.wheel-av + .wheel-av { margin-left: calc(var(--wheel-av, 44px) * -.42); }
.wheel-av.more { font-size: calc(var(--wheel-av, 44px) * .3); }
#spinBtn { margin-top: 6px; }
#wheelHint { margin: 10px 0 0; }

/* ---------- ganador ---------- */
.winner-card .empty { color: var(--muted); padding: 26px 0; text-align: center; }
.winner {
  display: flex; gap: 20px; align-items: center; flex-wrap: wrap; padding: 4px 0 2px;
  animation: pop .5s cubic-bezier(.2, 1.6, .4, 1);
}
@keyframes pop { from { transform: scale(.85); opacity: 0; } }
.winner .who { font-size: 22px; font-weight: bold; }
.winner .song { font-size: 16px; color: var(--cyan); margin-top: 2px; }
.winner .artist { color: var(--muted); font-size: 14px; }
.kind {
  display: inline-block; margin-left: 8px; font-size: 11px; text-transform: uppercase;
  letter-spacing: 1px; padding: 3px 8px; border-radius: 999px;
  background: rgba(248, 213, 60, .16); color: var(--gold); border: 1px solid rgba(248, 213, 60, .35);
}
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; align-items: center; }

/* ---------- cola / equipos / resultados ---------- */
.queue, .teams, .results { display: grid; gap: 10px; margin-top: 4px; }
.results { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.item {
  display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 12px;
  background: rgba(255, 255, 255, .04); border: 1px solid var(--card-line);
}
.item.stage { border-color: rgba(248, 213, 60, .55); box-shadow: 0 0 22px rgba(248, 213, 60, .18); }
.item.done { opacity: .55; }
.item .grow { flex: 1; min-width: 0; }
.item .t {
  display: block; max-width: 100%; font-weight: bold; font-size: 14px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.item .s { color: var(--muted); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item .t + .s, .item .s + .s { margin-top: 3px; }
.badge { font-size: 11px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--card-line); color: var(--muted); }
.badge.pendiente { color: var(--cyan); border-color: rgba(138, 134, 255, .4); }
.badge.en_escena { color: var(--gold); border-color: rgba(248, 213, 60, .5); }
.badge.cantada { color: #FFE9E9; border-color: rgba(255, 233, 233, .4); }
.badge.saltada { color: var(--red); border-color: rgba(239, 34, 34, .4); }

/* ---------- portada (con respaldo si la cancion no trae imagen) ---------- */
.cover {
  position: relative; width: 52px; height: 52px; border-radius: 10px; flex: none; overflow: hidden;
  background: linear-gradient(135deg, #4a1846, #1E0C21); display: grid; place-items: center;
  color: #FFE9E9; font-weight: bold; font-size: 18px;
}
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.cover.big { width: 130px; height: 130px; border-radius: 14px; font-size: 42px; }
.cover.sm { width: 46px; height: 46px; font-size: 16px; }

label { display: grid; gap: 6px; font-size: 13px; color: var(--muted); margin-top: 14px; }
.card label:first-of-type { margin-top: 6px; }
label small { color: rgba(255, 233, 233, .5); }
input, select {
  font: inherit; padding: 10px 12px; border-radius: 10px; color: var(--text);
  background: rgba(0, 0, 0, .35); border: 1px solid var(--card-line);
}
input:focus, select:focus { outline: 2px solid rgba(83, 77, 255, .5); }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row input { flex: 1; min-width: 180px; }
#membersBox { display: grid; gap: 8px; margin: 12px 0 10px; }
.member-row { display: flex; gap: 8px; }
summary { cursor: pointer; }
details { margin: 6px 0 4px; }
details[open] { margin-bottom: 12px; }
#results { margin-top: 18px; }
#summaryBox { margin: 10px 0 16px; line-height: 1.5; }
.pager { margin-top: 14px; justify-content: center; }

.modal { position: fixed; inset: 0; background: rgba(30, 12, 33, .8); display: none; place-items: center; z-index: 20; }
.modal.open { display: grid; }
.modal-box {
  background: #1E0C21; border: 1px solid var(--card-line); border-radius: 16px; padding: 22px;
  width: min(420px, 92vw); display: grid; gap: 14px;
}

.admin-bar {
  position: fixed; bottom: 0; left: 0; right: 0; display: none; gap: 10px; align-items: center;
  padding: 12px 18px; background: rgba(54, 17, 51, .82); backdrop-filter: blur(10px);
  border-top: 1px solid rgba(239, 34, 34, .45); z-index: 15; flex-wrap: wrap;
}
.admin-bar.on { display: flex; }
.tag { font-size: 12px; letter-spacing: 1px; text-transform: uppercase; color: var(--gold); }

.toast {
  position: fixed; left: 50%; bottom: 70px; transform: translate(-50%, 20px);
  background: #1E0C21; border: 1px solid var(--card-line); border-radius: 12px;
  padding: 12px 18px; opacity: 0; pointer-events: none; transition: .25s; z-index: 30; max-width: 90vw;
}
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- fichas de personas (roster del chat de Teams) ---------- */
.people-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; margin: 14px 0 16px; }
.person {
  display: grid; justify-items: center; gap: 6px; padding: 10px 6px; border-radius: 14px; cursor: pointer;
  background: rgba(255, 255, 255, .04); border: 1px solid var(--card-line); text-align: center;
  transition: transform .1s ease, border-color .2s ease, box-shadow .2s ease;
}
.person:hover { transform: translateY(-2px); border-color: rgba(83, 77, 255, .5); }
.person.sel { border-color: var(--gold); box-shadow: 0 0 20px rgba(248, 213, 60, .3); background: rgba(248, 213, 60, .10); }
.person .nm { font-size: 11.5px; line-height: 1.2; color: var(--text); }
.person .guest { font-size: 10px; color: var(--muted); }

/* avatares: reglas globales (valen dentro y fuera de las fichas) */
.av {
  width: 54px; height: 54px; border-radius: 50%; overflow: hidden; flex: none;
  background: linear-gradient(135deg, var(--red-dark), var(--magenta));
  display: grid; place-items: center; font-weight: bold; font-size: 17px; color: #fff;
}
.av img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }
.avatars { display: flex; }
.avatars .mini {
  width: 26px; height: 26px; border-radius: 50%; margin-right: -8px; border: 2px solid #1E0C21;
  background: linear-gradient(135deg, var(--red-dark), var(--magenta)); display: grid; place-items: center;
  font-size: 10px; font-weight: bold; overflow: hidden; flex: none; color: #fff;
}
.avatars .mini img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- desplegables de la lista de inscritos ---------- */
.person-card {
  background: rgba(255, 255, 255, .04); border: 1px solid var(--card-line); border-radius: 12px;
  overflow: hidden; margin: 0;
}
.person-card summary {
  display: flex; align-items: center; gap: 10px; padding: 12px 14px; cursor: pointer;
  list-style: none; flex-wrap: wrap;
}
.person-card summary::-webkit-details-marker { display: none; }
.person-card summary::after { content: "+"; margin-left: auto; color: var(--muted); font-size: 16px; transition: transform .42s ease; }
.person-card[open] summary::after { content: "-"; transform: rotate(180deg); }
.person-card summary:hover { background: rgba(255, 255, 255, .05); }
.person-card .who-name {
  font-weight: bold; font-size: 14.5px; max-width: 46vw;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.person-card summary .av { width: 40px; height: 40px; font-size: 13px; }
.person-body { padding: 4px 14px 14px; display: grid; gap: 12px; }
.person-card[open].anim .person-body { animation: reveal .42s cubic-bezier(.2, .7, .2, 1); }
@keyframes reveal {
  from { opacity: 0; transform: translateY(-4px); max-height: 0; }
  to   { opacity: 1; transform: translateY(0); max-height: 600px; }
}
.team-row { border-left: 2px solid rgba(83, 77, 255, .35); padding-left: 12px; display: grid; gap: 6px; }
.team-line { font-size: 13.5px; }
.team-line .kind { margin-left: 0; margin-right: 6px; }
.song-line { font-size: 13px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.song-line .grow { flex: 1; min-width: 0; }
.song-line .by { color: var(--muted); }

/* ---------- resultados de busqueda: no desbordar con titulos largos ---------- */
.item.result { display: grid; gap: 10px; min-width: 0; overflow: hidden; align-items: stretch; padding: 12px; }
.item.result .row { min-width: 0; justify-content: space-between; }
.item.result .grow { min-width: 0; overflow: hidden; }
.item.result .t, .item.result .s { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }

/* ---------- estado vacio con llamado a la accion ---------- */
.empty-cta {
  text-align: center; padding: 28px 18px; border: 1px dashed rgba(83, 77, 255, .35);
  border-radius: 14px; background: rgba(83, 77, 255, .05);
}
.empty-cta .big-line { font-size: 18px; font-weight: bold; margin-bottom: 6px; }
.empty-cta .hint { margin: 0 auto 16px; max-width: 460px; }

/* ---------- edicion del turno (solo modo Carlos) ---------- */
.modal-box.wide { width: min(680px, 94vw); max-height: 88vh; overflow-y: auto; }
.people-grid.compact { grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; margin: 0 0 10px; }
.people-grid.compact .av { width: 42px; height: 42px; font-size: 14px; }
.people-grid.compact .person { padding: 8px 4px; }
#editMembersBox { display: grid; gap: 8px; margin: 10px 0; }
#editResults { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); margin-top: 12px; max-height: 260px; overflow-y: auto; }
#editSummary { line-height: 1.5; padding: 12px 14px; border-radius: 12px;
  background: rgba(255, 255, 255, .04); border: 1px solid var(--card-line); }
#editSummary .s { color: var(--muted); font-size: 13px; margin-top: 4px; }

/* ---------- reproductor flotante (fijo, sigue a la pantalla) ---------- */
.now-playing {
  position: fixed; right: 18px; bottom: 18px; z-index: 26; display: none;
  align-items: center; gap: 12px; padding: 10px 12px 12px;
  width: min(360px, calc(100vw - 36px));
  background: rgba(30, 12, 33, .93); border: 1px solid var(--card-line); border-radius: 14px;
  box-shadow: 0 12px 44px rgba(0, 0, 0, .55), 0 0 26px rgba(83, 77, 255, .18);
  backdrop-filter: blur(10px); overflow: hidden;
}
.now-playing.on { display: flex; animation: npIn .25s cubic-bezier(.2, .9, .3, 1); }
@keyframes npIn { from { opacity: 0; transform: translateY(12px); } }
.now-playing .grow { flex: 1; min-width: 0; }
.now-playing .t { font-weight: bold; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.now-playing .s { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.now-playing .cover.sm { width: 40px; height: 40px; font-size: 14px; }
.np-btn { padding: 6px 10px; font-size: 12px; flex: none; }
.np-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(255, 255, 255, .10); }
.np-bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--red), var(--magenta)); }
/* con la barra de admin abierta, el reproductor y el toast se suben */
.admin-bar.on ~ .now-playing { bottom: 74px; }
.now-playing.on ~ .toast { bottom: 108px; }
.admin-bar.on ~ .now-playing.on ~ .toast { bottom: 164px; }

/* ---------- celular (solo <=640px; el desktop queda igual) ---------- */
@media (max-width: 640px) {
  header { padding: 14px 14px 6px; gap: 10px; }
  .brand { gap: 10px; }
  .logo { width: 36px; height: 36px; }
  h1 { font-size: 21px; }
  .pill { font-size: 11px; padding: 5px 10px; }
  #adminBtn { padding: 7px 11px; font-size: 13px; }

  .tabs { padding: 6px 10px 0; gap: 4px; }
  .tab { padding: 9px 11px; font-size: 13px; }

  main { padding: 10px 12px 130px; }
  .card { padding: 14px 14px 16px; border-radius: 14px; margin-bottom: 12px; }
  .card h2 { font-size: 16px; }
  .card-head { flex-wrap: wrap; gap: 4px; }

  /* dedo, no mouse: los botones chicos crecen */
  button, .btn { padding: 9px 12px; }
  button.tiny, .btn.tiny { padding: 7px 11px; font-size: 12px; }
  button.big { padding: 13px; font-size: 16px; }
  .row input { min-width: 140px; }

  /* cada fila se parte igual siempre: portada + texto arriba, estado y acciones abajo */
  .item { flex-wrap: wrap; row-gap: 8px; padding: 11px 12px; }
  .item .grow { flex: 1 1 calc(100% - 80px); }
  .item .t { font-size: 13.5px; white-space: normal; }
  .item .s { white-space: normal; }
  .item > .badge { align-self: center; }

  .results { grid-template-columns: 1fr; }
  #editResults { grid-template-columns: 1fr; max-height: 220px; }

  .people-grid { grid-template-columns: repeat(auto-fill, minmax(82px, 1fr)); gap: 8px; }
  .people-grid .av { width: 46px; height: 46px; font-size: 15px; }
  .people-grid .nm { font-size: 11px; }
  .people-grid.compact { grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); gap: 6px; }
  .people-grid.compact .av { width: 38px; height: 38px; font-size: 13px; }

  .wheel-wrap { max-width: 270px; }
  .cover.big { width: 96px; height: 96px; font-size: 30px; border-radius: 12px; }
  .winner { gap: 14px; }
  .winner .who { font-size: 19px; }
  .actions { gap: 8px; margin-top: 12px; }

  .modal-box, .modal-box.wide { width: calc(100vw - 20px); max-height: 92vh; padding: 16px; gap: 12px; }
  .person-card summary { padding: 10px 12px; }
  .person-card .who-name { max-width: 52vw; }
  .empty-cta { padding: 22px 14px; }

  /* la barra de admin tiene que caber en UNA linea: si se parte, tapa contenido y el
     reproductor flotante queda encima. El "Admin activo" ya lo dice el boton del header. */
  .admin-bar { padding: 8px 10px; gap: 6px; flex-wrap: nowrap; justify-content: space-between; }
  .admin-bar .tag { display: none; }
  .admin-bar button { padding: 7px 9px; font-size: 12px; }

  .now-playing { left: 10px; right: 10px; bottom: 12px; width: auto; padding: 8px 10px 10px; }
  .now-playing .cover.sm { width: 36px; height: 36px; }
  .admin-bar.on ~ .now-playing { bottom: 64px; }
  .toast { bottom: 70px; }
  .now-playing.on ~ .toast { bottom: 92px; }
  .admin-bar.on ~ .now-playing.on ~ .toast { bottom: 138px; }
}


/* ===================== tipografia de marca ===================== */
h1, h2, .tab, button, .btn, .winner .who, .big-line, .wheel-hub { font-family: var(--font-heading); }
h1 { font-size: 30px; font-weight: 700; letter-spacing: 0; line-height: 1.05; }
h1 span { color: var(--red); text-shadow: 0 0 22px rgba(239, 34, 34, .55); }
.card h2 { font-size: 19px; font-weight: 700; }
.tagline { font-family: var(--font-body); color: var(--gold); letter-spacing: 2px; text-transform: uppercase; font-size: 11.5px; font-weight: 700; margin-top: 4px; }
.logo { width: auto; height: 30px; filter: drop-shadow(0 0 12px rgba(239, 34, 34, .5)); }
.card { box-shadow: 0 18px 50px rgba(30, 12, 33, .45); }
button.primary { background: linear-gradient(135deg, #EF2222 0%, #534DFF 100%); box-shadow: var(--shadow-brand); }
button.primary:hover { box-shadow: 0 14px 40px rgba(83, 77, 255, .45); }

/* ===================== capa de Halloween ===================== */
/* La luna reemplaza al glow magenta; la niebla violeta al cian. */
.glow-a {
  width: 150px; height: 150px; top: 78px; right: 2.5%; filter: none; opacity: .55;
  background: radial-gradient(circle at 38% 36%, #FFF8F8 0%, #FBE88E 34%, #F8D53C 62%, rgba(248, 213, 60, 0) 72%);
  box-shadow: 0 0 120px 30px rgba(248, 213, 60, .18);
  animation: moon 9s ease-in-out infinite;
}
.glow-a::after {   /* crateres */
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background:
    radial-gradient(circle at 62% 58%, rgba(54, 17, 51, .14) 0 9%, transparent 10%),
    radial-gradient(circle at 34% 66%, rgba(54, 17, 51, .10) 0 6%, transparent 7%),
    radial-gradient(circle at 56% 30%, rgba(54, 17, 51, .09) 0 5%, transparent 6%);
}
@keyframes moon { 50% { transform: translateY(8px); box-shadow: 0 0 150px 40px rgba(248, 213, 60, .24); } }
.glow-b { background: var(--magenta); opacity: .28; }
.glow-c {
  width: 520px; height: 260px; background: var(--red); opacity: .14; bottom: -120px; right: 10%;
  animation: float 22s ease-in-out infinite;
}

.spooky { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.web { position: absolute; top: -6px; left: -6px; width: 210px; height: 210px; opacity: .2; }
.web.r { left: auto; right: -6px; transform: scaleX(-1); width: 150px; height: 150px; opacity: .12; }
.bat { position: absolute; width: 46px; fill: #0d040e; filter: drop-shadow(0 0 6px rgba(248, 213, 60, .25)); }
.bat path { transform-origin: 50% 40%; animation: flap .32s ease-in-out infinite alternate; }
@keyframes flap { to { transform: scaleY(.45); } }
.bat.b1 { top: 70px; animation: fly 26s linear infinite; }
.bat.b2 { top: 190px; width: 32px; animation: fly 34s linear -11s infinite; }
.bat.b3 { top: 120px; width: 24px; animation: fly 41s linear -24s infinite; opacity: .8; }
@keyframes fly {
  0%   { transform: translate(-80px, 0) rotate(-4deg); }
  25%  { transform: translate(28vw, -30px) rotate(6deg); }
  50%  { transform: translate(55vw, 25px) rotate(-6deg); }
  75%  { transform: translate(80vw, -20px) rotate(5deg); }
  100% { transform: translate(calc(100vw + 80px), 10px) rotate(-4deg); }
}
.ghost {
  position: absolute; bottom: 9%; left: 4%; width: 62px; opacity: .12;
  animation: haunt 7s ease-in-out infinite;
}
@keyframes haunt { 50% { transform: translateY(-16px); opacity: .2; } }

.halloween-tag {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px;
  font-size: 12px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
  color: var(--bg); background: var(--gold); box-shadow: 0 0 22px rgba(248, 213, 60, .35);
}
.halloween-tag svg { width: 14px; height: 14px; }

/* La ruleta es una calabaza: centro naranja-rojo de la marca con tallo y cara. */
.wheel { border-color: rgba(248, 213, 60, .35); box-shadow: 0 0 50px rgba(239, 34, 34, .28), 0 0 90px rgba(248, 213, 60, .10), inset 0 0 40px rgba(0, 0, 0, .55); }
.wheel-hub {
  width: 84px; height: 76px; border-radius: 46% 46% 44% 44%;
  background: radial-gradient(circle at 50% 40%, #F8D53C 0%, #EF2222 78%);
  border: 2px solid rgba(30, 12, 33, .7); color: #1E0C21; font-weight: 700; font-size: 13px;
  box-shadow: inset -8px 0 0 rgba(30, 12, 33, .12), inset 8px 0 0 rgba(30, 12, 33, .12), 0 6px 18px rgba(0, 0, 0, .5);
}
.wheel-hub::before {   /* tallo */
  content: ""; position: absolute; top: -9px; left: 50%; width: 10px; height: 12px;
  transform: translateX(-50%) rotate(8deg); border-radius: 3px 3px 1px 1px; background: #361133;
}
.pointer { border-top-color: var(--gold); }

.item.stage { box-shadow: 0 0 26px rgba(248, 213, 60, .22), inset 0 0 0 1px rgba(239, 34, 34, .15); }

.site-foot {
  position: relative; z-index: 1; text-align: center; padding: 8px 24px 96px;
  color: var(--muted); font-size: 12.5px; display: grid; gap: 6px; justify-items: center;
}
.site-foot .slogan { font-family: var(--font-heading); font-size: 15px; color: var(--text); }
.site-foot .slogan b { color: var(--red); }
.site-foot a { color: var(--muted); text-decoration: none; }
.site-foot a:hover { color: var(--text); }

@media (max-width: 640px) {
  h1 { font-size: 23px; }
  .logo { height: 24px; }
  .glow-a { width: 120px; height: 120px; top: 64px; right: -20px; }
  .web { width: 130px; height: 130px; }
  .web.r, .bat.b3, .ghost { display: none; }
  .halloween-tag { font-size: 10.5px; padding: 5px 9px; }
  .site-foot { padding-bottom: 130px; }
}
@media (prefers-reduced-motion: reduce) {
  .bat, .bat path, .glow, .ghost { animation: none !important; }
  .bat { display: none; }
}
