/* ============================================================
   /watch — public spectator page. Polished esport front-end.
   Loaded AFTER dashboard.css (reuses its vars + bracket styles).
   ============================================================ */

:root {
  --w-accent: #ff4d1c;
  --w-accent-2: #ff8a3d;
  --w-ink-900: #0b0a0d;
  --w-ink-800: #121016;
  --w-card: #16141b;
  --w-card-2: #1d1a23;
  --w-border: #2a2733;
  --w-discord: #5865f2;
}

body.watch {
  margin: 0;
  background: var(--w-ink-900);
  color: #ececf1;
  font-family: 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
}
body.watch a { color: inherit; }

/* ---------------- HERO ---------------- */
.watch-hero {
  position: relative;
  overflow: hidden;
  padding: 64px 24px 52px;
  text-align: center;
  background:
    radial-gradient(1200px 420px at 50% -10%, rgba(255, 77, 28, 0.28), transparent 60%),
    radial-gradient(900px 500px at 50% 120%, rgba(255, 138, 61, 0.08), transparent 60%),
    linear-gradient(180deg, #1a1310 0%, var(--w-ink-900) 78%);
  border-bottom: 1px solid var(--w-border);
}
.watch-hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(circle at 50% 30%, #000 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(circle at 50% 30%, #000 0%, transparent 70%);
  pointer-events: none;
}
.watch-hero-corner {
  position: absolute;
  width: 46px;
  height: 46px;
  border: 3px solid var(--w-accent);
  opacity: 0.8;
}
.watch-hero-corner.tl { top: 22px; left: 22px; border-right: none; border-bottom: none; }
.watch-hero-corner.tr { top: 22px; right: 22px; border-left: none; border-bottom: none; }

.watch-hero-inner { position: relative; max-width: 1200px; margin: 0 auto; }
.watch-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--w-accent-2);
}
.watch-hero-eyebrow .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--w-accent);
  box-shadow: 0 0 12px var(--w-accent);
}
.watch-hero-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(46px, 8vw, 108px);
  line-height: 0.95;
  letter-spacing: 2px;
  margin: 12px 0 6px;
  color: #fff;
  text-shadow: 0 6px 40px rgba(255, 77, 28, 0.25);
}
.watch-hero-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 22px;
}

/* live status pill (bracket.js toggles .connected / .disconnected) */
.watch .ws-status {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--w-border);
  color: #b9b9c6;
}
.watch .ws-status::before {
  content: '';
  width: 8px; height: 8px; border-radius: 50%;
  background: #7a7a88;
}
.watch .ws-status.connected { color: #57f2a0; border-color: rgba(87, 242, 160, 0.35); }
.watch .ws-status.connected::before { background: #37d67a; box-shadow: 0 0 10px #37d67a; animation: watchPulse 1.8s infinite; }
.watch .ws-status.disconnected { color: #ff8a8a; border-color: rgba(255, 90, 90, 0.35); }
.watch .ws-status.disconnected::before { background: #ff5a5a; }
@keyframes watchPulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

.watch-discord-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  color: #fff;
  padding: 11px 22px;
  border-radius: 999px;
  background: var(--w-discord);
  box-shadow: 0 8px 24px rgba(88, 101, 242, 0.4);
  transition: transform 0.15s ease, filter 0.15s ease;
}
.watch-discord-btn:hover { transform: translateY(-2px); filter: brightness(1.1); }

/* ---------------- MAIN / SECTIONS ---------------- */
.watch-main { max-width: 1200px; margin: 0 auto; padding: 40px 24px 20px; }
.watch-section { margin-bottom: 52px; }
.watch-section-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
}
.watch-section-head h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 34px;
  letter-spacing: 1px;
  margin: 0;
  color: #fff;
}
.watch-kicker {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--w-accent);
  background: rgba(255, 77, 28, 0.12);
  border: 1px solid rgba(255, 77, 28, 0.3);
  padding: 5px 10px;
  border-radius: 6px;
}
.watch-badge {
  margin-left: auto;
  font-size: 12px;
  font-weight: 600;
  color: #57f2a0;
  border: 1px solid rgba(87, 242, 160, 0.3);
  background: rgba(87, 242, 160, 0.08);
  border-radius: 999px;
  padding: 5px 14px;
}

/* ---------------- INFO CARDS ---------------- */
.watch-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.watch-info-card {
  position: relative;
  background: linear-gradient(160deg, var(--w-card-2), var(--w-card));
  border: 1px solid var(--w-border);
  border-radius: 14px;
  padding: 22px 20px;
  overflow: hidden;
  transition: transform 0.15s ease, border-color 0.15s ease;
}
.watch-info-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(var(--w-accent), var(--w-accent-2));
}
.watch-info-card:hover { transform: translateY(-3px); border-color: rgba(255, 77, 28, 0.4); }
.watch-info-card .wic-icon { font-size: 26px; margin-bottom: 10px; }
.watch-info-card h3 {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 700;
  color: #fff;
}
.watch-info-card p { margin: 0; font-size: 14px; line-height: 1.55; color: #c3c3ce; }
.watch-info-card strong { color: #fff; }
.watch-info-card.is-important { border-color: rgba(255, 176, 58, 0.45); }
.watch-info-card.is-important::before { background: linear-gradient(#ffb03a, #ff7a1f); }

a.wic-cta {
  text-decoration: none;
  background: linear-gradient(160deg, rgba(88, 101, 242, 0.25), rgba(88, 101, 242, 0.08));
  border-color: rgba(88, 101, 242, 0.5);
}
a.wic-cta::before { background: linear-gradient(#7d87ff, #5865f2); }
a.wic-cta:hover { border-color: #7d87ff; }

/* ---------------- BRACKET FRAME ---------------- */
.watch-bracket {
  background:
    radial-gradient(700px 300px at 50% 0%, rgba(255, 77, 28, 0.06), transparent 70%),
    var(--w-ink-800);
  border: 1px solid var(--w-border);
  border-radius: 16px;
  padding: 10px;
}
.watch-empty {
  background: var(--w-card);
  border: 1px dashed var(--w-border);
  border-radius: 14px;
  padding: 34px 24px;
  text-align: center;
  color: #9a9aa8;
  font-size: 15px;
}

/* ---------------- TEAMS GRID ---------------- */
.watch .watch-teams-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px;
  margin: 0;
}
.watch .watch-team-card {
  background: linear-gradient(160deg, var(--w-card-2), var(--w-card));
  border: 1px solid var(--w-border);
  border-top: 3px solid var(--row-color, var(--w-accent));
  border-radius: 12px;
  padding: 14px 15px;
  transition: transform 0.15s ease;
}
.watch .watch-team-card:hover { transform: translateY(-3px); }
.watch .watch-team-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.watch .watch-team-logo {
  width: 40px; height: 40px;
  border-radius: 8px;
  background-color: rgba(255, 255, 255, 0.06);
  background-size: cover; background-position: center;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 15px;
  color: var(--row-color, var(--w-accent));
  flex-shrink: 0;
}
.watch .watch-team-name { font-weight: 700; font-size: 16px; color: #fff; }
.watch .watch-team-tag { font-size: 12px; color: #9a9aa8; }
.watch .watch-players { display: flex; flex-wrap: wrap; gap: 6px; }
.watch .watch-player {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  padding: 4px 10px;
  font-size: 13px;
  font-weight: 500;
  color: #eaeaf0;
}
.watch .watch-players-empty { font-size: 12px; color: #7a7a88; font-style: italic; }

/* ---------------- FOOTER ---------------- */
.watch-footer {
  border-top: 1px solid var(--w-border);
  padding: 26px 24px 40px;
  text-align: center;
  color: #8a8a96;
  font-size: 13px;
}
.watch-footer .brand { font-family: 'Bebas Neue', sans-serif; font-size: 18px; letter-spacing: 1px; }
.watch-footer .brand-accent { color: var(--w-accent); }
.watch-footer-sep { margin: 0 8px; opacity: 0.5; }
.watch-footer a { color: var(--w-accent-2); text-decoration: none; }
.watch-footer a:hover { text-decoration: underline; }

/* ---------------- RESPONSIVE ---------------- */
@media (max-width: 640px) {
  .watch-hero { padding: 44px 18px 38px; }
  .watch-main { padding: 28px 16px 12px; }
  .watch-section-head { flex-wrap: wrap; gap: 10px; }
  .watch-badge { margin-left: 0; }
}
