/* ═══════════════════════════════════════════════════════════════
   MARSY LEAGUE – Stylesheet
   Design Tokens (deep violet + gold) – ML Logo
   Layout: Sidebar 12.5% (left) | Content 87.5% (right, scrollable)
   ═══════════════════════════════════════════════════════════════ */

:root {
  /* Backgrounds – deep violet (logo palette) */
  --bg-void:       #0C0715;
  --bg-deep:       #100B1E;
  --bg-panel:      #140E24;
  --bg-card:       #1A1030;
  --bg-hover:      #221440;
  --border:        rgba(255,185,80,0.08);
  --border-glow:   rgba(255,160,50,0.25);

  /* Gold palette */
  --gold-light:    #FFD27A;
  --gold-main:     #FFAA44;
  --gold-deep:     #E07A10;
  --gold-glow:     rgba(255,170,68,0.35);

  /* Accents */
  --accent-violet: #7B4FD4;
  --accent-red:    #FF4560;
  --accent-teal:   #30D5C8;
  --accent-pink:   #E63B7A;

  --text-primary:  #F5EED8;
  --text-secondary:#9A8B70;
  --text-muted:    #4A3E5A;

  --font-display:  'Bebas Neue', sans-serif;
  --font-heading:  'Barlow Condensed', sans-serif;
  --font-body:     'Rajdhani', sans-serif;

  --sidebar-w: 12.5vw;
  --content-w: 87.5vw;
  --shell-pad: 3%;
}

/* ─── RESET ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { min-height: 100%; }

body {
  background: var(--bg-void);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 14px;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ─── AMBIENT GLOW ─── */
body::before {
  content: '';
  position: fixed; inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 50% -10%, rgba(123,79,212,0.18) 0%, transparent 65%),
    radial-gradient(ellipse 40% 30% at 10% 60%, rgba(255,170,68,0.06) 0%, transparent 55%),
    radial-gradient(ellipse 30% 40% at 90% 80%, rgba(48,213,200,0.05) 0%, transparent 55%);
  pointer-events: none; z-index: 0;
}

/* ─── NOISE OVERLAY ─── */
body::after {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  pointer-events: none; z-index: 0; opacity: 0.5;
}

/* ═══════════════════════════════════════════════════════════════
   SIDEBAR NAVIGATION (left, fixed, 12.5% width)
   ═══════════════════════════════════════════════════════════════ */
.sidebar {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: var(--sidebar-w);
  min-width: 180px;
  /* Higher contrast: nearly black base + warm gold edge */
  background:
    linear-gradient(180deg, #06030C 0%, #0A0518 60%, #06030C 100%);
  border-right: 2px solid rgba(255,170,68,0.35);
  box-shadow:
    4px 0 24px rgba(0,0,0,0.55),
    inset -1px 0 0 rgba(255,210,122,0.08);
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 32px 12px 64px;
  overflow: hidden;
}
/* subtle inner gold gradient stripe on the right edge for depth */
.sidebar::after {
  content: '';
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom,
    transparent 0%,
    rgba(255,170,68,0.5) 30%,
    rgba(255,170,68,0.5) 70%,
    transparent 100%);
  pointer-events: none;
}

.sidebar-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  gap: 24px;
}

.sidebar-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.logo-img-wrap {
  width: 70%;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  overflow: hidden;
  border: 2px solid var(--gold-deep);
  box-shadow: 0 0 22px var(--gold-glow), inset 0 0 12px rgba(255,170,68,0.12);
  flex-shrink: 0;
}
.logo-img-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}

.logo-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.1;
  text-align: center;
  gap: 4px;
}
.logo-text span:first-child {
  font-family: var(--font-display);
  font-size: clamp(14px, 1.1vw, 20px);
  letter-spacing: 2.5px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
}
.logo-text span:last-child {
  font-family: var(--font-heading);
  font-size: clamp(8px, 0.6vw, 10px);
  letter-spacing: 3px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
}

.sidebar-links {
  display: flex;
  flex-direction: column;
  width: 100%;
  gap: 4px;
}

.sidebar-login {
  width: 80%;
  padding: 16px 12px;
  font-size: 13px;
  flex-shrink: 0;
}

.nav-link {
  width: 100%;
  padding: 12px 14px;
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #B8A89A;       /* brighter inactive than before for legibility */
  border-radius: 4px;
  cursor: pointer;
  transition: color .2s, background .2s, transform .15s, box-shadow .2s;
  border-left: 3px solid transparent;
  user-select: none;
  text-align: left;
  position: relative;
}
.nav-link:hover {
  color: var(--text-primary);
  background: rgba(255,170,68,0.08);
  border-left-color: rgba(255,170,68,0.45);
  transform: translateX(2px);
}
.nav-link.active {
  background: linear-gradient(90deg,
    rgba(255,170,68,0.22) 0%,
    rgba(255,170,68,0.05) 100%);
  border-left-color: var(--gold-light);
  color: var(--gold-light);
  box-shadow:
    inset 0 0 0 1px rgba(255,210,122,0.18),
    0 0 14px rgba(255,170,68,0.18);
}

/* ═══════════════════════════════════════════════════════════════
   MOBILE NAV (top bar, hidden on desktop)
   ═══════════════════════════════════════════════════════════════ */
.mobile-nav {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0;
  background:
    linear-gradient(180deg, #06030C 0%, #0A0518 100%);
  border-bottom: 2px solid rgba(255,170,68,0.35);
  box-shadow: 0 4px 18px rgba(0,0,0,0.55);
  z-index: 100;
  flex-direction: column;
}
.mobile-logo {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 14px;
}
.mobile-logo img {
  width: 32px; height: 32px;
  border-radius: 6px;
  border: 1px solid var(--gold-deep);
}
.mobile-logo span {
  font-family: var(--font-display);
  font-size: 16px; letter-spacing: 2px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
}
.mobile-tabs {
  display: flex;
  gap: 0;
  overflow-x: auto;
  border-top: 1px solid var(--border);
}
.nav-link-m {
  flex: 0 0 auto;
  padding: 10px 14px;
  font-family: var(--font-heading);
  font-size: 12px; font-weight: 700;
  letter-spacing: 1.5px; text-transform: uppercase;
  color: var(--text-secondary);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: color .15s, border-color .15s;
  white-space: nowrap;
}
.nav-link-m.active {
  color: var(--gold-main);
  border-bottom-color: var(--gold-main);
}

/* ═══════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════ */
.btn {
  padding: 8px 16px;
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  border-radius: 4px;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
}
.btn-ghost {
  background: transparent; color: var(--text-secondary);
  border: 1px solid rgba(255,170,68,0.2);
}
.btn-ghost:hover { color: var(--gold-main); border-color: var(--gold-main); }
.btn-primary {
  background: linear-gradient(135deg, var(--gold-deep), var(--gold-main));
  color: var(--bg-void);
  box-shadow: 0 0 18px var(--gold-glow);
  font-weight: 800;
}
.btn-primary:hover {
  box-shadow: 0 0 28px var(--gold-glow);
  transform: translateY(-1px);
}

/* ═══════════════════════════════════════════════════════════════
   CONTENT AREA (right of sidebar, scrollable)
   ═══════════════════════════════════════════════════════════════ */
.content-area {
  margin-left: var(--sidebar-w);
  width: var(--content-w);
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* sidebar min-width fallback */
@media (min-width: 901px) and (max-width: 1440px) {
  .content-area { margin-left: max(var(--sidebar-w), 180px); width: calc(100vw - max(var(--sidebar-w), 180px)); }
}

.tab-page {
  display: none;
  min-height: 100vh;
}
.tab-page.active { display: block; }

/* ═══════════════════════════════════════════════════════════════
   PAGE BANNER (top of every tab-page except profile)
   ═══════════════════════════════════════════════════════════════ */
.page-banner {
  position: relative;
  height: 22vh;
  min-height: 170px;
  background: linear-gradient(90deg, var(--bg-void) 0%, var(--bg-card) 100%);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}
.page-banner::after {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 60% 80% at 70% 50%, rgba(255,170,68,0.08) 0%, transparent 60%);
  pointer-events: none;
}

.banner-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  z-index: 1;
  width: max-content;
  max-width: 90%;
}
.banner-title {
  font-family: var(--font-display);
  font-size: clamp(34px, 5vw, 68px);
  letter-spacing: 5px;
  line-height: 1;
  background: linear-gradient(135deg, var(--gold-light) 20%, var(--gold-main) 60%, var(--gold-deep));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
}
.banner-sub {
  font-family: var(--font-heading);
  font-size: clamp(13px, 1.7vw, 20px);
  font-weight: 700;
  letter-spacing: 4px;
  color: var(--text-secondary);
  text-transform: uppercase;
  line-height: 1.3;
}
.banner-sub-small {
  display: block;
  font-size: clamp(10px, 1vw, 13px);
  letter-spacing: 2px;
  color: var(--gold-main);
  font-weight: 600;
  margin-top: 4px;
}

/* ═══════════════════════════════════════════════════════════════
   PAGE SHELL (3% padding to navbar, banner, screen border)
   ═══════════════════════════════════════════════════════════════ */
.page-shell {
  padding: var(--shell-pad);
}

/* On the home tab the gap between the banner and the About / Roadmap
   block is tightened by ~40% — keeps everything closer to the banner
   and makes the page feel more cohesive on first paint. */
#tab-home .page-shell {
  padding-top: calc(var(--shell-pad) * 0.6);
}

/* ═══════════════════════════════════════════════════════════════
   GENERIC PANELS
   ═══════════════════════════════════════════════════════════════ */
.panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 22px;
  transition: border-color .2s, transform .2s, background .2s;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}
.panel::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--gold-main);
  opacity: 0;
  transition: opacity .2s;
}
.panel:hover {
  border-color: var(--border-glow);
  transform: translateY(-2px);
}
.panel:hover::before { opacity: 1; }

.panel-eyebrow {
  font-family: var(--font-heading);
  font-size: 10px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.panel-title {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--text-primary);
  margin-bottom: 12px;
  text-transform: uppercase;
}
.panel-btn { align-self: flex-start; }

/* ═══════════════════════════════════════════════════════════════
   HOME LAYOUT
   ═══════════════════════════════════════════════════════════════ */
/* About section: transparent background, white-text for contrast
   against the dark void background. Center-aligned, near-full
   shell width so it reads as a hero statement. */
.home-about {
  background: transparent;
  border: none;
  padding: 14px 0 24px;
  margin: 0 auto 8px;
  color: #FFFFFF;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  width: 96%;
  max-width: 1100px;
}
.home-about-eyebrow {
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold-main);
}
.home-about-title {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-size: 34px;
  letter-spacing: 2.5px;
  color: #FFFFFF;
  text-transform: uppercase;
}
.home-about-text {
  margin: 0 auto;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: #FFFFFF;
  opacity: 0.92;
  max-width: 880px;
}
.home-about-text strong {
  color: var(--gold-light);
  font-weight: 700;
}

/* Bullet list inside the About section. Centered as a block but
   each bullet is left-aligned for readability. Gold marker dots. */
.home-about-list {
  list-style: none;
  margin: 4px auto 4px;
  padding: 0;
  display: grid;
  gap: 10px;
  text-align: left;
  max-width: 820px;
  width: 100%;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  color: #FFFFFF;
}
.home-about-list li {
  position: relative;
  padding-left: 26px;
  opacity: 0.95;
}
.home-about-list li::before {
  content: '';
  position: absolute;
  left: 6px; top: 0.65em;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--gold-main);
  box-shadow: 0 0 8px rgba(255,170,68,0.5);
}
.home-about-list strong {
  color: var(--gold-light);
  font-weight: 700;
}

@media (max-width: 720px) {
  .home-about-title { font-size: 26px; }
  .home-about-text  { font-size: 15px; }
  .home-about-list  { font-size: 14px; }
}

/* Roadmap panel: container itself is transparent (no card bg or
   border). The roadmap elements (months + bars) carry slim light
   borders for contrast against the void background. */
.panel-roadmap {
  margin-bottom: 26px;
  background: transparent;
  border: none;
  padding: 22px 0 32px;
}
.panel-roadmap::before { display: none; }
.panel-roadmap:hover {
  border-color: transparent;
  transform: none;
  background: transparent;
}
.panel-roadmap:hover::before { opacity: 0; }
.panel-roadmap .panel-eyebrow,
.panel-roadmap .panel-title { padding-left: 0; }

.home-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.home-split-left {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.panel-stat { padding: 18px; }

/* Each stat panel is now a link to its tab.
   Reset anchor defaults and add a small hint of interactivity. */
.stat-link {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
.stat-link:hover .big-number {
  text-shadow: 0 0 16px rgba(255,170,68,0.35);
}
.stat-link:focus-visible {
  outline: 2px solid var(--gold-main);
  outline-offset: 2px;
}

.panel-tournaments,
.panel-seasoninfo {
  height: 100%;
}

/* Season-Info card */
.countdown-block {
  margin: 8px 0 18px;
}
.countdown-label {
  font-family: var(--font-heading);
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.countdown-value {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.2vw, 32px);
  letter-spacing: 1.5px;
  line-height: 1.1;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Stat-Cards */
.big-number {
  font-family: var(--font-display);
  font-size: 38px;
  letter-spacing: 2px;
  line-height: 1;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 4px 0 8px;
}
.big-number.live-pulse {
  background: linear-gradient(135deg, var(--accent-red), #FF8090);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: pulse 1.6s infinite;
}
.stat-trend {
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--text-secondary);
}
.stat-trend.up        { color: #44FF88; }
.stat-trend.live-text { color: var(--accent-red); }

/* ═══════════════════════════════════════════════════════════════
   AVAILABLE TOURNAMENTS – Game-Buttons (home right column)
   ═══════════════════════════════════════════════════════════════ */
.gamebutton-list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.gamebutton {
  position: relative;
  width: 100%;
  height: 96px;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0;
  margin-bottom: 8px;
  cursor: pointer;
  transition: width .2s ease, border-color .2s, transform .2s, box-shadow .2s;
  overflow: hidden;
}
.gamebutton:hover {
  width: 95%;
  border-color: var(--border-glow);
  transform: translateY(-1px);
  box-shadow: 0 4px 18px rgba(0,0,0,0.4), 0 0 14px rgba(255,170,68,0.08);
}

.gamebutton-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top,
  rgba(12,7,21,0.25) 0%,
  rgba(12,7,21,0)    100%);
  pointer-events: none;
}

.gamebutton-name {
  position: absolute;
  left: 14px;
  bottom: 10px;
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-primary);
  text-shadow: 0 1px 6px rgba(0,0,0,0.85), 0 0 10px rgba(0,0,0,0.6);
}

/* ═══════════════════════════════════════════════════════════════
   ROADMAP
   ═══════════════════════════════════════════════════════════════ */
.panel-roadmap .panel-title {
  background: linear-gradient(135deg, var(--gold-light) 20%, var(--gold-main) 60%, var(--gold-deep));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: 28px;
  letter-spacing: 2px;
  margin-bottom: 18px;
}

.roadmap-loading {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 0;
  color: var(--text-secondary);
  font-family: var(--font-heading); font-size: 12px;
}

.roadmap-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
}

.roadmap-months {
  display: grid;
  grid-template-columns: repeat(12, minmax(72px, 1fr));
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 4px;
  overflow: hidden;
  min-width: 900px;
}
.roadmap-month {
  padding: 10px 6px;
  text-align: center;
  font-family: var(--font-heading);
  font-size: 11px; font-weight: 700;
  letter-spacing: 2px; text-transform: uppercase;
  color: var(--gold-main);
  border-right: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.02);
}
.roadmap-month:last-child { border-right: none; }

.roadmap-tracks {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 6px;
  min-width: 900px;
}
.roadmap-track {
  display: grid;
  grid-template-columns: repeat(12, minmax(72px, 1fr));
  gap: 4px;
  position: relative;
  height: 50px;
  align-items: stretch;
}

.roadmap-bar {
  border-radius: 4px;
  border: 1px solid rgba(255,255,255,0.30);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 13px; font-weight: 800;
  letter-spacing: 1.5px; text-transform: uppercase;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0,0,0,0.6);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, border-color .15s;
}
.roadmap-bar:hover {
  transform: translateY(-1px);
  border-color: rgba(255,255,255,0.55);
  box-shadow: 0 4px 14px rgba(0,0,0,0.5), 0 0 20px rgba(255,170,68,0.2);
}
.roadmap-bar:focus-visible {
  outline: 2px solid var(--gold-main);
  outline-offset: 2px;
}
.roadmap-bar::after {
  content: '';
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: 22px;
  background: rgba(0,0,0,0.45);
}
.roadmap-bar .bar-label {
  position: relative;
  z-index: 1;
  padding: 0 24px 0 12px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
}
.roadmap-bar .bar-finals {
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: 22px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-heading);
  font-size: 8px; font-weight: 700; letter-spacing: 1px;
  color: rgba(255,255,255,0.85);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  z-index: 1;
}

.bar-brawlhalla   { background: linear-gradient(90deg, #F26B3A 0%, #C73838 100%); }
.bar-valorant     { background: linear-gradient(90deg, #7B2CD4 0%, #C737B0 100%); }
.bar-rocketleague { background: linear-gradient(90deg, #1B6CFF 0%, #4DCBFF 100%); }
.bar-fortnite     { background: linear-gradient(90deg, #E63B7A 0%, #FF6BAB 100%); }
.bar-multigame    { background: linear-gradient(90deg, #FFAA44 0%, #FFD27A 100%); color: var(--bg-void); text-shadow: none; }
.bar-vote {
  background: linear-gradient(90deg, #2C2348 0%, #3A2D63 100%);
  border: 1px solid rgba(255,170,68,0.25);
  font-size: 11px;
}
.bar-vote::after { display: none; }
.bar-pokal {
  background: #0E0814;
  border: 1px solid var(--gold-deep);
  box-shadow: inset 0 0 24px rgba(255,170,68,0.08);
}

/* ═══════════════════════════════════════════════════════════════
   FILTER CONTAINER (Play & Ladder)
   100% shell width, ~20% shell height
   ═══════════════════════════════════════════════════════════════ */
.filter-container {
  width: 100%;
  display: flex;
  gap: 12px;
  margin-bottom: 22px;
  align-items: stretch;
}

.filter-buttons {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
}

.filter-btn {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: var(--bg-card);
  background-size: cover;
  background-position: center;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0;
  cursor: pointer;
  transition: border-color .2s, transform .15s, box-shadow .2s;
  overflow: hidden;
}
.filter-btn:hover {
  border-color: var(--border-glow);
  transform: translateY(-2px);
  box-shadow: 0 4px 18px rgba(0,0,0,0.4), 0 0 14px rgba(255,170,68,0.1);
}
.filter-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(12,7,21,0.55) 0%, rgba(12,7,21,0.1) 100%);
  pointer-events: none;
  transition: background .2s, opacity .2s;
}
.filter-name {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-primary);
  text-shadow: 0 1px 6px rgba(0,0,0,0.85), 0 0 10px rgba(0,0,0,0.6);
  white-space: nowrap;
  z-index: 2;
}

/* All Games button (no image, gold styling when selected) */
.filter-btn-all {
  background: var(--bg-card);
  border: 1px solid rgba(255,170,68,0.2);
}
.filter-btn-all .filter-name {
  position: static;
  transform: none;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 2.5px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: none;
}
.filter-btn-all {
  display: flex;
  align-items: center;
  justify-content: center;
}
.filter-btn-all.active {
  background: linear-gradient(135deg, rgba(255,210,122,0.15), rgba(255,170,68,0.08));
  border-color: var(--gold-main);
  box-shadow: 0 0 20px rgba(255,170,68,0.18);
}

/* Game image buttons – 40% gold overlay when selected */
.filter-btn-game.active {
  border-color: var(--gold-main);
  box-shadow: 0 0 22px rgba(255,170,68,0.28);
}
.filter-btn-game.active .filter-overlay {
  background:
    linear-gradient(to top, rgba(12,7,21,0.45) 0%, rgba(12,7,21,0.1) 100%),
    rgba(255,170,68,0.40);
}

/* Vote button – fits the height of the other filter buttons */
.vote-btn {
  flex: 0 0 auto;
  align-self: stretch;
  width: clamp(140px, 14vw, 220px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  padding: 14px 12px;
  background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-hover) 100%);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  transition: transform .2s, border-color .2s, box-shadow .2s, background .2s;
  position: relative;
  overflow: hidden;
}
.vote-btn::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--gold-main);
  opacity: 0;
  transition: opacity .2s;
}
.vote-btn:hover {
  border-color: var(--border-glow);
  transform: translateY(-2px);
  box-shadow: 0 4px 18px rgba(0,0,0,0.4), 0 0 14px rgba(255,170,68,0.1);
}
.vote-btn:hover::before { opacity: 1; }

.vote-eyebrow {
  font-family: var(--font-heading);
  font-size: 9px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
}
.vote-title {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-primary);
  text-align: center;
  line-height: 1.15;
}
.vote-arrow {
  font-family: var(--font-heading);
  font-size: 18px;
  color: var(--gold-main);
  transition: transform .2s;
}
.vote-btn:hover .vote-arrow { transform: translateX(4px); }

/* ═══════════════════════════════════════════════════════════════
   GAMECARD GRID (Play tournaments + Profile My Tournaments)
   ═══════════════════════════════════════════════════════════════ */
.gamecard-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.gamecard {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform .2s, border-color .2s, box-shadow .2s;
  display: flex;
  flex-direction: column;
}
.gamecard:hover {
  transform: translateY(-3px);
  border-color: var(--border-glow);
  box-shadow: 0 6px 24px rgba(0,0,0,0.5), 0 0 18px rgba(255,170,68,0.1);
}

.gamecard-image {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-deep);
  border-bottom: 1px solid var(--border);
}
.gamecard-tier-badge {
  position: absolute;
  left: 10px; bottom: 10px;
  padding: 3px 10px;
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  border-radius: 3px;
  z-index: 2;
}

.gamecard-body {
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.gamecard-name {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--text-primary);
  line-height: 1.2;
}
.gamecard-game {
  font-family: var(--font-heading);
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold-main);
  font-weight: 700;
}
.gamecard-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 4px;
}
.gamecard-meta-row {
  display: flex;
  align-items: center;
  gap: 6px;
}
.gamecard-meta-icon { color: var(--text-muted); font-size: 11px; }

/* ═══════════════════════════════════════════════════════════════
   LADDER TABLE
   ═══════════════════════════════════════════════════════════════ */
.ladder-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  overflow-x: auto;
}

.ladder-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 900px;
}
.ladder-table thead th {
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  text-align: left;
  padding: 14px 12px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-panel);
  white-space: nowrap;
}
.ladder-table thead th.col-pts { text-align: right; }
.ladder-table thead th.sorted-by {
  color: var(--gold-main);
}

.ladder-row {
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}
.ladder-row:hover { background: var(--bg-hover); }
.ladder-row.me    { background: rgba(123,79,212,0.08); }
.ladder-row td {
  padding: 11px 12px;
  vertical-align: middle;
}
.ladder-row td.col-pts {
  text-align: right;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
}
.ladder-row td.col-pts.zero { color: var(--text-muted); font-weight: 400; }
.ladder-row td.col-pts.total {
  color: var(--gold-main);
  font-size: 15px;
  font-weight: 800;
}
.ladder-row td.col-pts.sorted-by {
  color: var(--gold-light);
  background: rgba(255,170,68,0.04);
}

.rank-num {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--text-muted);
  width: 44px;
  display: inline-block;
  text-align: center;
}
.rank-gold {
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
}

.player-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}
.avatar-sm {
  width: 32px; height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 12px;
  border: 1px solid var(--border);
  flex-shrink: 0;
  overflow: hidden;
}
.avatar-sm img {
  width: 100%; height: 100%; object-fit: cover;
}
.player-row-name {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
}

.delta {
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.delta.up   { color: #44FF88; }
.delta.down { color: var(--accent-red); }
.delta.same { color: var(--text-muted); }

/* ═══════════════════════════════════════════════════════════════
   TIER BADGES
   ═══════════════════════════════════════════════════════════════ */
.tier-badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 3px;
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  white-space: nowrap;
}
.tier-iron     { background: rgba(120,120,140,0.10); color: #9090A0;     border: 1px solid rgba(120,120,140,0.25); }
.tier-bronze   { background: rgba(184,115,51,0.12);  color: #CD8B5C;     border: 1px solid rgba(184,115,51,0.30); }
.tier-silber,
.tier-silver   { background: rgba(200,200,210,0.08); color: #C0C0D0;     border: 1px solid rgba(200,200,210,0.20); }
.tier-gold-t   {
  background: linear-gradient(135deg, rgba(255,210,122,0.15), rgba(255,170,68,0.10));
  border: 1px solid rgba(255,170,68,0.30);
  color: var(--gold-main);
}
.tier-platin   { background: rgba(160,210,230,0.10); color: #A0E0F0;     border: 1px solid rgba(160,210,230,0.30); }
.tier-diamond  { background: rgba(48,213,200,0.10);  color: var(--accent-teal); border: 1px solid rgba(48,213,200,0.25); }
.tier-pro      { background: rgba(255,69,96,0.15);   color: var(--accent-red);  border: 1px solid rgba(255,69,96,0.30); }
.tier-champ    {
  background: linear-gradient(135deg, rgba(123,79,212,0.18), rgba(230,59,122,0.15));
  color: #D8A8FF;
  border: 1px solid rgba(123,79,212,0.40);
}

/* Gamecard tier-badge variants */
.gamecard-tier-badge.tier-iron     { background: #2A2A35; color: #9090A0; }
.gamecard-tier-badge.tier-bronze   { background: #4A2E18; color: #FFD2A0; }
.gamecard-tier-badge.tier-silber,
.gamecard-tier-badge.tier-silver   { background: #2A2A30; color: #DCDCE5; }
.gamecard-tier-badge.tier-gold-t   { background: linear-gradient(135deg, var(--gold-deep), var(--gold-main)); color: var(--bg-void); }
.gamecard-tier-badge.tier-platin   { background: #1F3540; color: #B0E5F5; }
.gamecard-tier-badge.tier-diamond  { background: #133838; color: #80F0E0; }
.gamecard-tier-badge.tier-pro      { background: #4A1A20; color: #FFB0BC; }
.gamecard-tier-badge.tier-champ    { background: linear-gradient(135deg, #5A2A8A, #8A2A5A); color: #FFE0F5; }

/* ═══════════════════════════════════════════════════════════════
   TEAMFINDER
   ═══════════════════════════════════════════════════════════════ */
/* ═══════════════════════════════════════════════════════════════
   TEAMCARD GRID (Profile → My Teams)
   ═══════════════════════════════════════════════════════════════ */
.teamcard-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

/* Profile "My Teams" card — visually matches the teamfinder
   tf-team-card: game banner on top, body below with meta pills
   and the players / tournaments lists side by side. */
.teamcard {
  background: linear-gradient(135deg, var(--bg-card) 0%, rgba(26,16,48,0.7) 100%);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0;
  display: flex;
  flex-direction: column;
  transition: border-color .2s, box-shadow .2s, transform .15s;
  position: relative;
  overflow: hidden;
}
.teamcard:hover {
  border-color: var(--border-glow);
  box-shadow: 0 4px 24px rgba(0,0,0,0.4), 0 0 18px rgba(255,170,68,0.1);
  transform: translateY(-2px);
}

.teamcard-banner {
  height: 110px;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-deep);
  position: relative;
  border-bottom: 1px solid var(--border);
}
.teamcard-banner::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(12,7,21,0.75) 0%, rgba(12,7,21,0.1) 70%);
}
.teamcard-banner-title {
  position: absolute;
  left: 16px; bottom: 12px;
  z-index: 1;
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: 2px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
}
.teamcard-banner-tag {
  position: absolute;
  right: 14px; top: 14px;
  z-index: 1;
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 2px;
  padding: 3px 8px;
  background: rgba(12,7,21,0.7);
  color: var(--gold-light);
  border: 1px solid var(--gold-deep);
  border-radius: 3px;
}

.teamcard-body {
  padding: 14px 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.teamcard-meta {
  display: flex; flex-wrap: wrap; gap: 6px;
}
.teamcard-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.teamcard-col-label {
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold-main);
  margin-bottom: 8px;
}
.teamcard-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.teamcard-list-item {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  padding: 6px 10px;
  background: rgba(255,255,255,0.03);
  border-left: 2px solid var(--gold-deep);
  border-radius: 0 4px 4px 0;
}
.teamcard-list-item.is-me {
  background: rgba(255,170,68,0.08);
  border-left-color: var(--gold-main);
  color: var(--gold-light);
}

@media (max-width: 900px) {
  .teamcard-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .teamcard-cols { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════════
   PROFILE PAGE
   ═══════════════════════════════════════════════════════════════ */
.profile-shell {
  padding: var(--shell-pad) var(--shell-pad) 60px;
}

.profile-page-title {
  font-family: var(--font-display);
  font-size: clamp(38px, 4.5vw, 56px);
  letter-spacing: 4px;
  line-height: 1;
  color: var(--text-primary);
  margin-bottom: 24px;
}

.profile-header {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-bottom: 8px;
}

.avatar-frame {
  width: 140px; height: 140px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--gold-light);
  box-shadow:
    0 0 0 6px rgba(255,210,122,0.06),
    0 0 30px rgba(255,210,122,0.25),
    inset 0 0 20px rgba(0,0,0,0.4);
  position: relative;
  background: var(--bg-card);
  flex-shrink: 0;
}
.avatar-frame::after {
  content: '';
  position: absolute; inset: -1px;
  border-radius: 50%;
  pointer-events: none;
  box-shadow: inset 0 0 12px rgba(255,210,122,0.15);
}
.avatar-img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}

.profile-header-info {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.profile-name {
  font-family: var(--font-heading);
  font-size: 36px;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--text-primary);
  line-height: 1;
}
.profile-header-info .tier-badge {
  align-self: flex-start;
  padding: 5px 12px;
  font-size: 12px;
}

.profile-divider {
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    var(--accent-red) 50%,
    transparent 100%);
  opacity: 0.5;
  margin: 28px 0;
}

.profile-section {
  margin-bottom: 8px;
}
.profile-section-title {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.stats-table {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 18px 20px;
}
.stats-head,
.stats-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
  align-items: center;
}
.stats-head {
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 14px;
}
.stats-row { padding: 6px 0; }
.stats-row > div {
  font-family: var(--font-heading);
  white-space: nowrap;
}
.stats-row-points > div {
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: 1px;
  color: var(--text-primary);
}
.stats-row-points > div:first-child {
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 800;
}
.stats-row-wl > div {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* ═══════════════════════════════════════════════════════════════
   PLACEHOLDER (Streams)
   ═══════════════════════════════════════════════════════════════ */
.placeholder-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 80px 32px;
  text-align: center;
}
.placeholder-eyebrow {
  font-family: var(--font-heading);
  font-size: 11px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.placeholder-body {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 520px;
  margin: 0 auto;
}

/* ═══════════════════════════════════════════════════════════════
   GENERIC: Loading / Spinner
   ═══════════════════════════════════════════════════════════════ */
.spinner {
  width: 16px; height: 16px;
  border: 2px solid var(--border);
  border-top-color: var(--gold-main);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.3; }
}

/* ═══════════════════════════════════════════════════════════════
   SCROLLBAR
   ═══════════════════════════════════════════════════════════════ */
::-webkit-scrollbar       { width: 3px; height: 3px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--gold-deep); border-radius: 2px; }

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 1280px) {
  .gamecard-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1100px) {
  .home-split { grid-template-columns: 1fr; }
  .gamecard-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Mobile: switch to top tabs */
@media (max-width: 900px) {
  .sidebar { display: none; }
  .mobile-nav { display: flex; }
  .content-area {
    margin-left: 0;
    width: 100%;
    padding-top: 96px; /* mobile-nav height */
  }
  .home-split { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .gamecard-grid { grid-template-columns: repeat(2, 1fr); }

  .filter-container { flex-direction: column; }
  .filter-buttons { grid-template-columns: repeat(3, 1fr); }
  .vote-btn { width: 100%; min-height: 70px; flex-direction: row; }

  /* hide low-priority ladder columns on mobile */
  .ladder-table thead th:nth-child(3),
  .ladder-table tbody td:nth-child(3) { display: none; }

  .stats-head, .stats-row {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
  .stats-head > div:nth-child(n+4),
  .stats-row > div:nth-child(n+4) { display: none; }

  .profile-header { gap: 18px; }
  .avatar-frame { width: 110px; height: 110px; }
  .profile-name { font-size: 28px; }
}

@media (max-width: 560px) {
  .stat-grid { grid-template-columns: 1fr; }
  .gamecard-grid { grid-template-columns: 1fr; }
  .filter-buttons { grid-template-columns: repeat(2, 1fr); }
  .banner-title { font-size: 32px; letter-spacing: 3px; }
  .banner-sub { font-size: 12px; letter-spacing: 2px; }
}

/* ═══════════════════════════════════════════════════════════════
   STREAMS PAGE – tall banner, two-section scrollable layout,
   stream cards w/ thumbnail / live dot / fallback gradient art.
   Banner button is vertically centered with the title block.
   ═══════════════════════════════════════════════════════════════ */
.streams-banner-tall {
  height: 34vh;
  min-height: 280px;
}
.streams-banner-tall .banner-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.banner-btn {
  margin-top: 18px;          /* breathing room from subtitle */
  padding: 12px 28px;
  font-size: 13px;
  letter-spacing: 2px;
  align-self: center;         /* explicit center inside flex column */
}

.streams-shell {
  display: flex;
  flex-direction: column;
  gap: 36px;
  /* IMPORTANT: no max-height + own overflow-y here.
     Banner + content must scroll together as ONE layer. */
}

.streams-section { display: flex; flex-direction: column; gap: 14px; }
.streams-section-head {
  display: flex; align-items: center; gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.streams-section-title {
  font-family: var(--font-display);
  font-size: 26px;
  letter-spacing: 3px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
}
.streams-section-title-muted {
  background: none;
  -webkit-text-fill-color: var(--text-secondary);
  color: var(--text-secondary);
}
.streams-section-count {
  font-family: var(--font-heading);
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-left: auto;
}
.live-dot {
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--accent-red);
  box-shadow: 0 0 10px rgba(255,69,96,0.7);
  animation: livepulse 1.4s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes livepulse {
  0%, 100% { transform: scale(1);   opacity: 1;   box-shadow: 0 0 10px rgba(255,69,96,0.7); }
  50%      { transform: scale(1.4); opacity: 0.55; box-shadow: 0 0 18px rgba(255,69,96,0.95); }
}

.stream-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}

.stream-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  transition: transform .2s, border-color .2s, box-shadow .2s;
  position: relative;
}
.stream-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-glow);
  box-shadow: 0 6px 26px rgba(0,0,0,0.55), 0 0 18px rgba(255,170,68,0.1);
}
.stream-card.is-offline { opacity: 0.86; }
.stream-card.is-offline:hover { opacity: 1; }

/* ── Preview frame ─────────────────────────────────────────────── */
.stream-preview {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: var(--bg-deep);
  overflow: hidden;
}
.stream-preview-img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}

/* Fallback art (live "watch now" gradient and offline "currently
   offline" gradient). Bebas Neue display font, gold palette from
   IMG_8030 + IMG_8031. */
.stream-preview-fallback {
  position: absolute; inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: linear-gradient(135deg,
              var(--gold-deep) 0%,
              var(--gold-main) 45%,
              #FFC066 100%);
  color: var(--bg-void);
  text-align: center;
  padding: 12px;
}
.stream-preview-fallback.offline {
  background: linear-gradient(135deg,
              #1A1030 0%,
              #2A1A48 50%,
              #3B2766 100%);
  color: var(--gold-light);
}
.stream-preview-fallback-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 38px);
  letter-spacing: 3px;
  line-height: 1;
}
.stream-preview-fallback-sub {
  font-family: var(--font-heading);
  font-size: 11px;
  letter-spacing: 3px;
  text-transform: uppercase;
  font-weight: 700;
  opacity: 0.85;
}
.stream-preview-fallback.offline .stream-preview-fallback-title {
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Live badge */
.stream-live-badge {
  position: absolute;
  top: 10px; left: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px 4px 8px;
  background: var(--accent-red);
  color: #fff;
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  border-radius: 3px;
  box-shadow: 0 2px 10px rgba(255,69,96,0.45);
  z-index: 2;
}
.stream-live-badge::before {
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #fff;
  animation: livepulse 1.4s ease-in-out infinite;
}
.stream-viewers {
  position: absolute;
  bottom: 8px; right: 8px;
  background: rgba(12,7,21,0.75);
  color: var(--text-primary);
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 3px 8px;
  border-radius: 3px;
  z-index: 2;
}

/* ── Body ─────────────────────────────────────────────────────── */
.stream-body {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 12px;
  padding: 14px 14px 16px;
}
.stream-avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 2px solid var(--gold-deep);
  background: var(--bg-deep);
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 0 12px rgba(255,170,68,0.18);
}
.stream-avatar img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.stream-info { min-width: 0; }
.stream-title {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: var(--text-primary);
  line-height: 1.3;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  margin-bottom: 4px;
}
.stream-title-offline {
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-size: 12px;
}
.stream-streamer {
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--gold-main);
}
.stream-game {
  font-family: var(--font-heading);
  font-size: 11px;
  color: var(--text-secondary);
  letter-spacing: 0.5px;
  margin-top: 2px;
}

.streams-loading {
  grid-column: 1 / -1;
  display: flex; align-items: center; justify-content: center;
  gap: 12px;
  padding: 40px 0;
  color: var(--text-secondary);
  font-family: var(--font-heading);
  font-size: 12px;
  letter-spacing: 1.5px;
}
.streams-empty {
  grid-column: 1 / -1;
  padding: 32px;
  text-align: center;
  color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 13px;
  border: 1px dashed var(--border);
  border-radius: 8px;
}

/* ═══════════════════════════════════════════════════════════════
   TEAMFINDER – toolbar, mode toggle, LFT cards, team cards
   ═══════════════════════════════════════════════════════════════ */

.tf-toolbar {
  display: grid;
  grid-template-columns: minmax(360px, 1.4fr) minmax(220px, 1fr) auto;
  gap: 14px;
  align-items: stretch;
  margin-bottom: 22px;
}

.tf-mode-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.tf-mode-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 10px 16px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 2px;
  color: var(--text-secondary);
  transition: background .15s, color .15s;
  border-right: 1px solid var(--border);
}
.tf-mode-btn:last-child { border-right: none; }
.tf-mode-btn:hover { background: rgba(255,170,68,0.04); color: var(--text-primary); }
.tf-mode-btn.active {
  background: linear-gradient(135deg, rgba(255,210,122,0.12), rgba(255,170,68,0.06));
  color: var(--gold-light);
}
.tf-mode-eyebrow {
  font-family: var(--font-heading);
  font-size: 9px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--text-muted);
}
.tf-mode-btn.active .tf-mode-eyebrow { color: var(--gold-main); }
.tf-mode-title {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.tf-search-wrap {
  position: relative;
  display: flex; align-items: center;
}
.tf-search-icon {
  position: absolute;
  left: 14px;
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--gold-main);
  pointer-events: none;
}
.tf-search-input {
  width: 100%;
  height: 100%;
  padding: 12px 14px 12px 38px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-primary);
  transition: border-color .15s, box-shadow .15s;
}
.tf-search-input::placeholder { color: var(--text-muted); }
.tf-search-input:focus {
  outline: none;
  border-color: var(--gold-main);
  box-shadow: 0 0 14px rgba(255,170,68,0.18);
}

.tf-actions { display: flex; gap: 10px; }
.tf-action-btn {
  display: flex; flex-direction: column; gap: 2px;
  align-items: flex-start;
  padding: 10px 18px;
  text-transform: none;
  letter-spacing: normal;
  min-width: 170px;
  text-align: left;
}
.tf-action-eyebrow {
  font-family: var(--font-heading);
  font-size: 9px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  opacity: 0.75;
}
.tf-action-title {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.5px;
}
.btn-primary.tf-action-btn .tf-action-eyebrow { color: rgba(12,7,21,0.7); }

/* ── Results grids ───────────────────────────────────────────── */
.tf-results { width: 100%; }
.tf-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}
.tf-empty {
  padding: 40px 24px;
  text-align: center;
  background: var(--bg-card);
  border: 1px dashed var(--border);
  border-radius: 8px;
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: 13px;
}
.tf-empty-eyebrow {
  font-family: var(--font-heading);
  font-size: 11px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}

/* ── LFT list (player looking for team) ─────────────────────── */
/* One-column list, each card spans 100% of the shell width.
   Game-image thumb on the left in 16:9, container height is
   driven by the content (head + body), and the thumb fills the
   left edge of that height exactly. */
.tf-lft-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.tf-lft-card {
  background: linear-gradient(135deg, var(--bg-card), rgba(26,16,48,0.7));
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 0;
  position: relative;
  overflow: hidden;
  width: 100%;
  transition: border-color .2s, transform .15s, box-shadow .2s;
}
.tf-lft-card::before {
  content: '';
  position: absolute; left: 0; top: 0; bottom: 0;
  width: 3px;
  background: linear-gradient(to bottom, var(--gold-light), var(--gold-deep));
  opacity: 0.7;
  z-index: 2;
}
.tf-lft-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-glow);
  box-shadow: 0 4px 22px rgba(0,0,0,0.45), 0 0 18px rgba(255,170,68,0.08);
}

/* Left-side game image, 16:9 aspect ratio.
   Container height is determined by content; aspect-ratio gives
   the thumb its width automatically. min-height keeps the image
   readable when the content is sparse. */
.tf-lft-thumb {
  flex: 0 0 auto;
  align-self: stretch;
  aspect-ratio: 16 / 9;
  min-height: 130px;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-deep);
  border-right: 1px solid var(--border);
  position: relative;
}
.tf-lft-thumb::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to right, rgba(12,7,21,0) 60%, rgba(12,7,21,0.55) 100%);
}

.tf-lft-content {
  flex: 1 1 auto;
  min-width: 0;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tf-lft-head {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 12px;
  align-items: center;
}
.tf-lft-ident { min-width: 0; }
.tf-lft-avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(255,170,68,0.10);
  color: var(--gold-main);
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.5px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--gold-deep);
  flex-shrink: 0;
}
.tf-lft-name {
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: 0.4px;
  line-height: 1.1;
  text-decoration: none;
}
.tf-lft-name:hover { color: var(--gold-light); }
.tf-lft-meta-row {
  display: flex; gap: 8px; align-items: center;
  margin-top: 4px;
  font-family: var(--font-heading);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 1px;
}
.tf-lft-points {
  font-family: var(--font-heading);
  font-size: 11px;
  color: var(--gold-main);
  font-weight: 700;
  letter-spacing: 1px;
  white-space: nowrap;
}

.tf-target-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  background: rgba(123,79,212,0.10);
  border: 1px solid rgba(123,79,212,0.3);
  border-radius: 4px;
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #C8A8FF;
  white-space: nowrap;
  max-width: 100%;
}
.tf-target-chip.kind-game {
  background: rgba(255,170,68,0.10);
  border-color: rgba(255,170,68,0.30);
  color: var(--gold-main);
}
.tf-target-chip-eyebrow {
  font-size: 9px;
  opacity: 0.7;
  letter-spacing: 2px;
}

.tf-lft-body {
  display: flex; flex-direction: column;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}
.tf-lft-tags {
  display: flex; flex-wrap: wrap; gap: 6px;
}
.tf-lft-comment {
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.45;
  color: var(--text-secondary);
}
.tf-lft-comment-empty { color: var(--text-muted); font-style: italic; }

/* ── Team card (team recruiting players) ─────────────────────── */
.tf-team-card {
  background: linear-gradient(135deg, var(--bg-card), rgba(26,16,48,0.6));
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: border-color .2s, transform .15s, box-shadow .2s;
  position: relative;
}
.tf-team-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-glow);
  box-shadow: 0 4px 22px rgba(0,0,0,0.45), 0 0 18px rgba(255,170,68,0.08);
}
.tf-team-banner {
  height: 96px;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-deep);
  position: relative;
  border-bottom: 1px solid var(--border);
}
.tf-team-banner::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(12,7,21,0.7) 0%, rgba(12,7,21,0.1) 70%);
}
.tf-team-banner-title {
  position: absolute;
  left: 14px; bottom: 10px;
  z-index: 1;
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: 2px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
}
.tf-team-banner-tag {
  position: absolute;
  right: 12px; top: 12px;
  z-index: 1;
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 2px;
  padding: 3px 8px;
  background: rgba(12,7,21,0.7);
  color: var(--gold-light);
  border: 1px solid var(--gold-deep);
  border-radius: 3px;
}
.tf-team-body {
  padding: 14px 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.tf-team-meta {
  display: flex; flex-wrap: wrap; gap: 6px;
}
.tf-team-note {
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.4;
  color: var(--text-secondary);
}
.tf-team-note-empty { color: var(--text-muted); font-style: italic; }
.tf-team-slots {
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold-main);
  padding: 6px 0 0;
}
.tf-team-tags {
  display: flex; flex-wrap: wrap; gap: 6px;
}

/* Small reusable pill */
.tf-pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 9px;
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  border-radius: 3px;
  background: rgba(255,255,255,0.04);
  color: var(--text-secondary);
  border: 1px solid var(--border);
  white-space: nowrap;
}
.tf-pill.pill-game { background: rgba(255,170,68,0.10); color: var(--gold-main); border-color: rgba(255,170,68,0.3); }
.tf-pill.pill-tier { background: rgba(123,79,212,0.10); color: #C8A8FF;        border-color: rgba(123,79,212,0.3); }
.tf-pill.pill-role { background: rgba(48,213,200,0.10); color: var(--accent-teal); border-color: rgba(48,213,200,0.25); }

/* ═══════════════════════════════════════════════════════════════
   TF MODALS (LFT + Create Team)
   ═══════════════════════════════════════════════════════════════ */
.tf-modal {
  position: fixed; inset: 0;
  z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
}
.tf-modal[hidden] { display: none; }

.tf-modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(8,5,16,0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.tf-modal-card {
  position: relative;
  width: min(560px, 100%);
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  background: var(--bg-panel);
  border: 1px solid var(--gold-deep);
  border-radius: 12px;
  padding: 28px 28px 24px;
  box-shadow: 0 24px 60px rgba(0,0,0,0.7), 0 0 40px rgba(255,170,68,0.12);
  animation: tfModalIn 0.18s ease-out;
}
@keyframes tfModalIn {
  from { transform: translateY(8px); opacity: 0; }
  to   { transform: translateY(0);   opacity: 1; }
}

.tf-modal-close {
  position: absolute;
  top: 12px; right: 14px;
  background: transparent;
  border: none;
  font-size: 26px;
  color: var(--text-muted);
  cursor: pointer;
  line-height: 1;
  width: 32px; height: 32px;
  border-radius: 4px;
  transition: color .15s, background .15s;
}
.tf-modal-close:hover { color: var(--gold-main); background: rgba(255,170,68,0.06); }

.tf-modal-eyebrow {
  font-family: var(--font-heading);
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.tf-modal-title {
  font-family: var(--font-display);
  font-size: 28px;
  letter-spacing: 2.5px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 20px;
}

/* Segmented control inside modals */
.tf-segments {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: 6px;
  margin-bottom: 16px;
}
.tf-segment {
  background: transparent;
  border: none;
  padding: 8px 10px;
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-secondary);
  cursor: pointer;
  border-radius: 4px;
  transition: background .15s, color .15s;
}
.tf-segment:hover { color: var(--text-primary); }
.tf-segment.active {
  background: linear-gradient(135deg, var(--gold-deep), var(--gold-main));
  color: var(--bg-void);
}

.tf-form-block { margin-bottom: 16px; }
.tf-form-block[hidden] { display: none; }

.tf-form-row {
  display: grid;
  grid-template-columns: 1fr 120px;
  gap: 12px;
  margin-bottom: 14px;
}
.tf-form-col-narrow { /* keyword col */ }

.tf-label {
  display: block;
  font-family: var(--font-heading);
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold-main);
  margin-bottom: 6px;
}
.tf-input,
.tf-textarea,
.tf-select {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-primary);
  transition: border-color .15s, box-shadow .15s;
}
.tf-textarea { min-height: 84px; resize: vertical; }
.tf-input:focus,
.tf-textarea:focus,
.tf-select:focus {
  outline: none;
  border-color: var(--gold-main);
  box-shadow: 0 0 14px rgba(255,170,68,0.15);
}
.tf-select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--gold-main) 50%),
                    linear-gradient(135deg, var(--gold-main) 50%, transparent 50%);
  background-position: calc(100% - 16px) 50%, calc(100% - 10px) 50%;
  background-size: 6px 6px;
  background-repeat: no-repeat;
  padding-right: 32px;
}
.tf-select option { background: var(--bg-deep); color: var(--text-primary); }

.tf-helper {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}
.tf-char-count {
  font-family: var(--font-heading);
  font-size: 10px;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  text-align: right;
  margin-top: 4px;
  margin-bottom: 14px;
}

/* Game picker in modals */
.tf-game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 8px;
}
.tf-game-btn {
  position: relative;
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: 5px;
  cursor: pointer;
  overflow: hidden;
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.tf-game-btn::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(12,7,21,0.65) 0%, rgba(12,7,21,0.1) 100%);
  pointer-events: none;
}
.tf-game-btn-label {
  position: absolute;
  left: 0; right: 0; bottom: 8px;
  text-align: center;
  font-family: var(--font-heading);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.5px;
  color: var(--text-primary);
  text-transform: uppercase;
  text-shadow: 0 1px 4px rgba(0,0,0,0.9);
  z-index: 1;
}
.tf-game-btn:hover {
  transform: translateY(-1px);
  border-color: var(--border-glow);
}
.tf-game-btn.selected {
  border-color: var(--gold-main);
  box-shadow: 0 0 14px rgba(255,170,68,0.3);
}
.tf-game-btn.selected::after {
  background: linear-gradient(to top, rgba(12,7,21,0.45) 0%, rgba(12,7,21,0.1) 100%),
              rgba(255,170,68,0.30);
}
.tf-game-grid-multi .tf-game-btn.selected::before {
  content: '✓';
  position: absolute;
  top: 6px; right: 8px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--gold-main);
  color: var(--bg-void);
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 13px;
  display: flex; align-items: center; justify-content: center;
  z-index: 2;
}

.tf-modal-footer {
  display: flex; justify-content: flex-end;
  gap: 10px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  margin-top: 8px;
}

/* ── Toast notifications (re-used for tf actions) ───────────── */
.tf-toast-wrap {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 250;
  display: flex; flex-direction: column;
  gap: 8px;
  pointer-events: none;
}
.tf-toast {
  background: var(--bg-panel);
  border: 1px solid var(--gold-deep);
  border-radius: 8px;
  padding: 12px 18px;
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  box-shadow: 0 8px 32px rgba(0,0,0,0.6);
  animation: tfToastIn .25s ease-out;
  max-width: 340px;
}
.tf-toast.is-error {
  border-color: var(--accent-red);
  color: #FFB0BC;
}
@keyframes tfToastIn {
  from { transform: translateX(20px); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE OVERRIDES for new sections
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 1100px) {
  .tf-toolbar {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "mode mode"
      "search search"
      "actions actions";
  }
  .tf-mode-toggle { grid-area: mode; }
  .tf-search-wrap { grid-area: search; }
  .tf-actions     { grid-area: actions; }
  .tf-actions .tf-action-btn { flex: 1; }
}
@media (max-width: 900px) {
  .streams-banner-tall { height: auto; padding: 32px 0 28px; }
  .streams-shell { padding-right: var(--shell-pad); }

  .tf-mode-toggle { grid-template-columns: 1fr; }
  .tf-mode-btn { border-right: none; border-bottom: 1px solid var(--border); }
  .tf-mode-btn:last-child { border-bottom: none; }
  .tf-action-btn { min-width: 0; }
  .tf-form-row { grid-template-columns: 1fr; }
  .stream-grid { grid-template-columns: 1fr; }
  .tf-card-grid { grid-template-columns: 1fr; }

  /* On narrow screens the 16:9 thumb gets too wide if kept on the
     left — collapse the LFT card to a stacked layout, with the thumb
     across the top (still 16:9, capped height). */
  .tf-lft-card { flex-direction: column; }
  .tf-lft-thumb {
    width: 100%;
    aspect-ratio: 16 / 9;
    max-height: 140px;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .tf-lft-thumb::after {
    background: linear-gradient(to top, rgba(12,7,21,0.55) 0%, rgba(12,7,21,0) 60%);
  }
  .tf-lft-head { grid-template-columns: 44px 1fr; }
  .tf-lft-head .tf-target-chip {
    grid-column: 1 / -1;
    justify-self: start;
  }
}

/* ═══════════════════════════════════════════════════════════════
   TOURNAMENT DETAIL PAGE
   Banner uses the game banner as background, deep tint over it.
   Below: info grid, about + apply split, lists.
   ═══════════════════════════════════════════════════════════════ */
.tournament-banner {
  height: 38vh;
  min-height: 320px;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-card);
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.tournament-banner .banner-tint {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(12,7,21,0.55) 0%, rgba(12,7,21,0.85) 100%),
    radial-gradient(ellipse 70% 80% at 50% 50%, rgba(255,170,68,0.18) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}
.tournament-banner .banner-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: max-content;
  max-width: 92%;
  z-index: 1;
}
.tournament-banner-eyebrow {
  font-family: var(--font-heading);
  font-size: 11px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--gold-main);
  margin-bottom: 6px;
}
.tournament-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  justify-content: center;
}
.tournament-banner-actions .banner-btn {
  margin-top: 0;
  align-self: auto;
}

/* Info grid ------------------------------------------------------- */
.tournament-info-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 22px;
}
.tournament-info-card {
  padding: 16px 18px;
}
.tournament-info-value {
  font-family: var(--font-display);
  font-size: clamp(20px, 2vw, 28px);
  letter-spacing: 1.5px;
  line-height: 1.1;
  background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* About + Apply split -------------------------------------------- */
.tournament-detail-split {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 18px;
  margin-bottom: 22px;
}
.panel-tournament-about,
.panel-tournament-apply,
.panel-tournament-teams {
  padding: 22px 24px;
}
.tournament-about-text {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-secondary);
  margin-bottom: 18px;
}
.tournament-format {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.tournament-format-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-family: var(--font-heading);
  font-size: 12px;
  letter-spacing: 1px;
}
.tournament-format-label {
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 2px;
  font-size: 11px;
}
.tournament-format-value {
  color: var(--gold-light);
  font-weight: 700;
}

.tournament-apply-text {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-secondary);
  margin-bottom: 18px;
}
.tournament-apply-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.tournament-apply-buttons .btn {
  padding: 12px 18px;
  font-size: 13px;
  letter-spacing: 1.5px;
}

.panel-tournament-teams { margin-bottom: 18px; }
.tournament-empty {
  padding: 28px 24px;
  text-align: center;
  background: var(--bg-deep);
  border: 1px dashed var(--border);
  border-radius: 8px;
  color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 13px;
  margin-top: 12px;
}

@media (max-width: 1100px) {
  .tournament-info-grid { grid-template-columns: repeat(2, 1fr); }
  .tournament-detail-split { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .tournament-info-grid { grid-template-columns: 1fr; }
  .tournament-banner { height: auto; min-height: 0; padding: 36px 0 28px; }
}
