/* ---------- Colour tokens (defaults; the admin page can change them) ---------- */
:root {
  --bg: #0E0B1F;
  --band: #151129;
  --card: #1A1533;
  --line: #2A2350;
  --text: #F4F1FF;
  --muted: #C9C2E8;
  --accent: #B69CFF;
  --on-accent: #0E0B1F;
  --danger: #FF8F8F;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
html { scroll-padding-top: env(safe-area-inset-top, 0px); scroll-behavior: smooth; }
*, *::before, *::after { box-sizing: inherit; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.5;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; }
.display { font-family: Bungee, Impact, "Arial Black", sans-serif; font-weight: 400; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 14px 28px; border-radius: 999px;
  font: inherit; font-weight: 700; font-size: 17px; cursor: pointer;
  border: 2px solid transparent; transition: transform .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-accent { background: var(--accent); color: var(--on-accent); }
.btn-outline { border-color: var(--text); color: var(--text); background: transparent; }
.btn-dark { background: var(--bg); color: var(--text); }
.btn-small { min-height: 40px; padding: 8px 18px; font-size: 15px; }

/* ---------- Layout ---------- */
.wrap { max-width: 1280px; margin: 0 auto; padding: 0 clamp(20px, 5vw, 64px); }
.section { padding: clamp(64px, 9vw, 112px) 0; }
.section.alt { background: var(--band); }
.eyebrow { font-size: 14px; font-weight: 700; letter-spacing: 3px; color: var(--accent); text-transform: uppercase; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 40px; }
.section-head h2 { font-size: clamp(36px, 5vw, 56px); margin-top: 10px; }
.link-accent { color: var(--accent); font-weight: 700; }
.grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 24px; padding: 32px; }
.muted { color: var(--muted); }

/* ---------- Nav ---------- */
.nav { position: sticky; top: 0; z-index: 10; background: var(--bg); border-bottom: 1px solid var(--line); }
.nav .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 76px; }
.logo { font-size: 24px; letter-spacing: 1px; }
.logo span { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 24px; font-weight: 500; }
@media (max-width: 860px) { .nav-links a:not(.btn) { display: none; } }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; }
.hero .wrap { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 48px; min-height: 680px; padding-top: 64px; padding-bottom: 64px; }
.star { position: absolute; border-radius: 50%; background: var(--text); }
.hero-text { position: relative; flex: 1 1 0; min-width: 0; max-width: 660px; display: flex; flex-direction: column; gap: 24px; }
.hero-text h1 { font-size: clamp(64px, 11vw, 120px); line-height: .9; white-space: pre-line; overflow-wrap: anywhere; }
.hero-text p { font-size: clamp(18px, 2vw, 22px); color: var(--muted); }
.hero-buttons { display: flex; gap: 16px; flex-wrap: wrap; }
.moon {
  position: relative; flex-shrink: 0; width: min(460px, 38vw); aspect-ratio: 1;
  border-radius: 50%; border: 8px solid var(--text); overflow: hidden;
  box-shadow: 0 0 140px 24px var(--accent); background: var(--card);
}
.moon img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 860px) {
  .hero .wrap { flex-direction: column-reverse; align-items: flex-start; min-height: 0; }
  .moon { width: min(300px, 70vw); }
}

/* ---------- Band ---------- */
.band { background: var(--accent); color: var(--on-accent); }
.band { overflow: hidden; }
.band-track { display: flex; width: max-content; animation: band-scroll 40s linear infinite; }
.band:hover .band-track { animation-play-state: paused; }
.band-group { display: flex; align-items: center; gap: 28px; padding: 20px 14px; font-size: 20px; letter-spacing: 2px; white-space: nowrap; }
.band-group svg { animation: claw-wiggle 2.4s ease-in-out infinite; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Schedule ---------- */
.slot { display: flex; align-items: center; gap: 24px; border: 2px solid var(--accent); }
.slot-time { font-size: 40px; font-weight: 700; line-height: 1.1; }
.note { margin-top: 24px; }

/* ---------- Games / videos / about ---------- */
.game-number { font-size: 60px; line-height: 1; color: var(--accent); margin-bottom: 16px; }
.card h3 { font-size: 26px; margin-bottom: 10px; }
.video { display: flex; flex-direction: column; justify-content: space-between; gap: 24px; min-height: 240px; }
.video-title { font-size: 22px; font-weight: 700; line-height: 1.3; }
.video.channel { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.about { display: flex; gap: clamp(32px, 6vw, 72px); align-items: center; }
.about img { width: min(380px, 80vw); aspect-ratio: 1; object-fit: cover; border-radius: 50%; border: 6px solid var(--accent); flex-shrink: 0; }
.about-text { display: flex; flex-direction: column; gap: 18px; font-size: 18px; }
.about-text h2 { font-size: clamp(36px, 5vw, 56px); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.fact { background: var(--bg); border-radius: 14px; padding: 14px 18px; font-size: 16px; }
.fact b { color: var(--accent); margin-right: 6px; }
@media (max-width: 860px) { .about { flex-direction: column; align-items: flex-start; } }

/* ---------- Socials / business / footer ---------- */
.social { display: flex; flex-direction: column; gap: 6px; transition: border-color .15s; }
.social:hover { border-color: var(--accent); }
.social strong { font-size: 22px; }
.business { background: var(--accent); color: var(--on-accent); border-radius: 32px; padding: clamp(32px, 6vw, 72px); display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap; }
.business h2 { font-size: clamp(32px, 4vw, 48px); margin-bottom: 8px; }
.footer { border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.footer .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-top: 32px; padding-bottom: 32px; }
.footer-links { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-links a:hover { color: var(--text); }

/* ---------- Admin ---------- */
.admin-bar { position: sticky; top: 0; z-index: 10; background: var(--band); border-bottom: 1px solid var(--line); padding-top: env(safe-area-inset-top, 0px); }
.admin-bar .wrap { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; min-height: 72px; }
.admin-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.status { font-size: 14px; color: var(--muted); }
.status.error { color: var(--danger); }
.admin { max-width: 880px; margin: 0 auto; padding: 32px clamp(16px, 4vw, 32px) 96px; display: flex; flex-direction: column; gap: 24px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.panel h2 { font-size: 20px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 700; color: var(--muted); }
.field input, .field textarea {
  font: inherit; font-weight: 400; font-size: 16px; color: var(--text);
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 12px;
  min-height: 44px; width: 100%;
}
.field textarea { min-height: 96px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.field input[type="color"] { padding: 4px; width: 96px; }
.row { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.list-item { border: 1px solid var(--line); border-radius: 14px; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.list-item-head { display: flex; justify-content: space-between; align-items: center; font-size: 14px; color: var(--muted); }
.btn-remove { background: transparent; color: var(--danger); border: 1px solid var(--danger); }
.btn-add { align-self: flex-start; background: transparent; color: var(--accent); border: 1px dashed var(--accent); }
.avatar-edit { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.avatar-edit img { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; border: 3px solid var(--accent); }
.preview-bar { position: sticky; top: 0; z-index: 20; background: var(--accent); color: var(--on-accent); padding: 10px 16px; display: flex; justify-content: center; align-items: center; gap: 16px; font-weight: 700; }

/* ---------- Colour editor ---------- */
.color-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.color-field { display: flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 500; color: var(--text); }
.color-field input { width: 56px; height: 44px; padding: 2px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); cursor: pointer; flex-shrink: 0; }
.contrast-ok { color: var(--muted); font-size: 14px; }
.contrast-warnings { margin: 0; padding: 12px 16px 12px 32px; border: 1px solid var(--danger); border-radius: 12px; color: var(--text); font-size: 14px; }
.contrast-warnings li + li { margin-top: 4px; }

/* ---------- Animations ---------- */

/* Band: scrolls from left to right, pauses on hover */
@keyframes band-scroll {
  from { transform: translateX(-50%); }
  to   { transform: translateX(0); }
}
@keyframes claw-wiggle {
  0%, 100% { transform: rotate(0deg); }
  50%      { transform: rotate(-12deg) scale(1.1); }
}

/* Stars twinkle */
.star { animation: twinkle 3s ease-in-out infinite alternate; }
@keyframes twinkle {
  from { opacity: .15; }
  to   { opacity: 1; }
}

/* The moon floats and its glow breathes */
.moon { animation: moon-float 7s ease-in-out infinite, moon-glow 4s ease-in-out infinite alternate; }
@keyframes moon-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-14px); }
}
@keyframes moon-glow {
  from { box-shadow: 0 0 90px 12px var(--accent); }
  to   { box-shadow: 0 0 170px 36px var(--accent); }
}

/* Hero text slides in one line after another */
.hero-text > * { animation: rise .8s ease-out both; }
.hero-text > :nth-child(2) { animation-delay: .1s; }
.hero-text > :nth-child(3) { animation-delay: .2s; }
.hero-text > :nth-child(4) { animation-delay: .3s; }
@keyframes rise {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Cards lift a little on hover */
.card { transition: transform .2s ease, border-color .2s ease; }
.card:hover { transform: translateY(-6px); }
.game-number { transition: transform .3s ease; display: inline-block; }
.card:hover .game-number { transform: rotate(-6deg) scale(1.1); }

/* Sections fade in while scrolling (site.js adds these classes) */
.animate .reveal:not(.visible) { opacity: 0; }
.animate .reveal.visible { animation: rise .7s ease-out backwards; animation-delay: var(--delay, 0s); }

/* Visitors who asked their device for less motion get a still page */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .animate .reveal:not(.visible) { opacity: 1; }
}

/* ---------- Show/hide switches in the admin page ---------- */
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.toggle { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; cursor: pointer; font-size: 15px; font-weight: 700; color: var(--text); }
.toggle input { width: 22px; height: 22px; accent-color: var(--accent); cursor: pointer; }
.panel.is-hidden { border-style: dashed; }
.panel.is-hidden > :not(.panel-head) { opacity: .55; }
.panel.is-hidden .toggle span { color: var(--danger); }

/* ---------- Video thumbnails ---------- */
.video-thumb { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 14px; background: var(--bg); }
