:root{
  --bg:#050509;
  --red:#ff1236;
  --red-soft:#ff3355;
  --text:#f5f5f7;
  --muted:#8b8daa;
}

*,
*::before,
*::after{ box-sizing:border-box; margin:0; padding:0; }

html,body{ height:100%; }

body{
  background:#050509;
  color:var(--text);
  font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  overflow-x:hidden;
padding-bottom: 140px;
}

html, body{
  height: 100%;
}

body{
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Your main page content wrapper (see Step 3) */
.page-wrap{
  flex: 1 0 auto;
}

/* Footer stays pushed down when page is short */
.site-footer{
  margin-top: auto;
  position: relative; /* keep your relative if you want */
}


a{ color:inherit; text-decoration:none; }

/* ===== Background FX (nebula + grid) ===== */
.bg-fx{
  position:fixed;
  inset:0;
  z-index:-3;
  pointer-events:none;
  overflow:hidden;
  background:
    radial-gradient(circle at 50% 20%, rgba(255,18,54,0.08), transparent 60%),
    radial-gradient(circle at 20% 80%, rgba(255,18,54,0.06), transparent 60%),
    #050509;
}

.nebula{
  position:absolute;
  width:620px;
  height:620px;
  border-radius:999px;
  filter:blur(48px);
  opacity:0.55;
  mix-blend-mode:screen;
  transform:translate3d(0,0,0);
  animation:floatNebula 10s ease-in-out infinite alternate;
  background: radial-gradient(circle at 30% 30%,
    rgba(255,18,54,0.35),
    rgba(255,18,54,0.10) 45%,
    rgba(0,0,0,0) 70%);
}

.nebula.n1{ left:-140px; top:-160px; animation-duration:12s; }
.nebula.n2{ right:-220px; top:20%; animation-duration:15s; opacity:0.45; }
.nebula.n3{ left:18%; bottom:-260px; animation-duration:18s; opacity:0.40; }

@keyframes floatNebula{
  from{ transform:translate3d(0,0,0) scale(1); }
  to{ transform:translate3d(40px,-30px,0) scale(1.07); }
}

.gridfx{
  position:absolute;
  inset:0;
  opacity:0.16;
  background-image:
    linear-gradient(rgba(255,255,255,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size:60px 60px;
  mask-image: radial-gradient(circle at 50% 40%, rgba(0,0,0,1), rgba(0,0,0,0) 70%);
}

/* ===== Starfield ===== */
.starfield{
  position:fixed;
  inset:0;
  z-index:-2;
  pointer-events:none;
  background:transparent;
}

.star{
  position:absolute;
  width:2px;
  height:2px;
  border-radius:999px;
  background:#fff;
  opacity:0.8;
  box-shadow:0 0 8px rgba(255,255,255,0.9), 0 0 18px rgba(255,18,54,0.55);
  will-change:transform,filter;
  transform:translate3d(0,0,0);
}

/* ===== Nav ===== */
.nav{
  position:fixed;
  top:0;
  inset-inline:0;
  padding:18px clamp(24px,6vw,80px);
  display:flex;
  align-items:center;
  justify-content:space-between;
  z-index:20;
  background:linear-gradient(to bottom, rgba(5,5,9,0.92), rgba(5,5,9,0));
  backdrop-filter:blur(14px);
  opacity:0;
}

.logo{
  font-weight:800;
  letter-spacing:0.32em;
  font-size:18px;
}

.nav-links{
  display: grid !important;
  grid-auto-flow: column !important;
  grid-auto-columns: max-content !important;
  column-gap: 28px !important;
  gap:32px;
  list-style:none;
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:0.15em;
  color:var(--muted);
}

.nav-links li{ position:relative; }
.nav-links li::after{
  content:"";
  position:absolute;
  left:0;
  bottom:-6px;
  width:0;
  height:2px;
  background:var(--red);
  transition:width .25s ease;
  
}

.nav-links li:hover,
.nav-links li.active{ color:var(--text); }

.nav-links li:hover::after,
.nav-links li.active::after{ width:100%; }

.nav-right{ display:flex; align-items:center; gap:12px; }

.nav-user{
  font-size:12px;
  color:#cfd0ea;
  opacity:0.9;
  padding:8px 12px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,0.12);
  background:rgba(255,255,255,0.03);
}

.nav-cta{
  border:none;
  padding:10px 20px;
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:0.16em;
  background:linear-gradient(120deg, var(--red), var(--red-soft));
  color:#fff;
  border-radius:999px;
  box-shadow:0 0 18px rgba(255,18,54,0.55);
  cursor:pointer;
  transition:transform .25s ease;
  display:inline-block;
}

.nav-cta:hover{ transform:scale(1.08); }

.btn-ghost{
  display:inline-block;
  padding:10px 18px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,0.16);
  background:rgba(255,255,255,0.03);
  font-size:12px;
  letter-spacing:0.14em;
  text-transform:uppercase;
  color:rgba(255,255,255,0.85);
  transition:transform .25s ease, border-color .25s ease;
}

.btn-ghost:hover{
  transform:scale(1.06);
  border-color:rgba(255,18,54,0.35);
}

/* ===== Sections ===== */
.section{
  min-height:100vh;
  padding:120px clamp(24px,6vw,80px);
  display:flex;
  align-items:center;
  position:relative;
  overflow:hidden;
  background:transparent;
}

.section-content{
  max-width:640px;
  opacity:0;
  transform:translateY(40px);
}

.section-content.wide{ max-width:980px; }

.eyebrow{
  font-size:11px;
  letter-spacing:0.22em;
  text-transform:uppercase;
  color:var(--muted);
  margin-bottom:16px;
}

.headline{
  font-size:clamp(36px,5vw,60px);
  line-height:1.05;
  margin-bottom:14px;
}

.subcopy{
  font-size:15px;
  color:#a0a2bf;
  max-width:520px;
}

.hero-actions{
  display:flex;
  gap:12px;
  margin-top:22px;
  flex-wrap:wrap;
}

.hud-hint{
  margin-top:14px;
  font-size:11px;
  letter-spacing:0.18em;
  text-transform:uppercase;
  color:rgba(255,255,255,0.55);
}

/* ===== Cards / mocks / FAQ ===== */
.grid-cards{
  display:grid;
  grid-template-columns:repeat(3, minmax(0,1fr));
  gap:16px;
  margin-top:22px;
}

.grid-cards.two{ grid-template-columns:repeat(2, minmax(0,1fr)); }

.card{
  border-radius:18px;
  padding:18px;
  background:rgba(255,255,255,0.03);
  border:1px solid rgba(255,255,255,0.08);
  box-shadow:0 0 30px rgba(255,18,54,0.08);
  position:relative;
  overflow:hidden;
}

.card-title{
  font-weight:700;
  letter-spacing:0.05em;
  margin-bottom:8px;
}

.card-text{
  color:#a0a2bf;
  font-size:14px;
  line-height:1.5;
}

.mock{
  height:110px;
  border-radius:14px;
  margin-top:14px;
  background:rgba(0,0,0,0.35);
  border:1px solid rgba(255,255,255,0.06);
  position:relative;
}

.mock::after{
  content:"";
  position:absolute;
  inset:12px;
  border-radius:10px;
  border:1px dashed rgba(255,255,255,0.18);
}

.mock-1{ box-shadow:inset 0 0 0 1px rgba(255,18,54,0.25); }
.mock-2{ box-shadow:inset 0 0 0 1px rgba(255,18,54,0.18); }
.mock-3{ box-shadow:inset 0 0 0 1px rgba(255,18,54,0.12); }

.faq{
  margin-top:18px;
  display:grid;
  gap:12px;
}

details{
  border-radius:16px;
  padding:14px 16px;
  background:rgba(255,255,255,0.02);
  border:1px solid rgba(255,255,255,0.08);
}

summary{
  cursor:pointer;
  font-weight:650;
}

details p{
  margin-top:10px;
  color:#a0a2bf;
  font-size:14px;
  line-height:1.6;
}

/* ===== Leaderboard ===== */
.page-leaderboard .lb-main{ padding-top:90px; }

.lb-hero{ padding:60px clamp(24px,6vw,80px) 20px; }

.lb-table-section{ padding:0 clamp(24px,6vw,80px) 80px; }

.lb-table{
  border-radius:18px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,0.08);
  background:rgba(5,5,11,0.96);
}

.lb-row{
  display:grid;
  grid-template-columns:60px 1.5fr 1fr;
  padding:12px 18px;
  font-size:13px;
}

.lb-head{
  background:rgba(255,255,255,0.04);
  text-transform:uppercase;
  letter-spacing:0.16em;
  font-size:10px;
  color:var(--muted);
}

.lb-row:not(.lb-head):nth-child(even){ background:rgba(255,255,255,0.02); }

/* ===== Auth ===== */
.auth-page{
  min-height:100vh;
  display:flex;
  flex-direction:column;
}

.auth-shell{
  flex: 1 0 auto;
  display:flex;
  align-items:center;
  justify-content:center;
  padding: 96px 16px 40px; /* nav-safe + breathing room */
}

.auth-box{
  width:380px;
  padding:32px;
  border-radius:18px;
  background:rgba(5,5,11,0.94);
  border:1px solid rgba(255,255,255,0.10);
  box-shadow:0 0 50px rgba(255,18,54,0.18);
  position:relative;
}

.auth-hud{
  border:1px solid rgba(255,18,54,0.22);
  box-shadow:0 0 50px rgba(255,18,54,0.18);
}

.auth-hud::before{
  content:"";
  position:absolute;
  inset:-2px;
  border-radius:20px;
  pointer-events:none;
  background: radial-gradient(circle at top left, rgba(255,18,54,0.18), transparent 55%);
}

.auth-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:16px;
}

.auth-back{
  font-size:12px;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:rgba(255,255,255,0.78);
  padding:8px 12px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,0.14);
  background:rgba(255,255,255,0.03);
  transition:transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.auth-back:hover{
  transform:scale(1.05);
  border-color:rgba(255,18,54,0.35);
  box-shadow:0 0 18px rgba(255,18,54,0.18);
}

.auth-box h1{ margin:0; }

.auth-box input{
  width:100%;
  padding:12px;
  margin-bottom:14px;
  background:#0b0b12;
  border:1px solid rgba(255,255,255,0.10);
  color:#fff;
  border-radius:10px;
}

.auth-box button{
  width:100%;
  padding:12px;
  border-radius:999px;
  border:none;
  background:linear-gradient(120deg, var(--red), var(--red-soft));
  color:#fff;
  font-weight:700;
  cursor:pointer;
}

.auth-error{ color:#ff4d6d; font-size:13px; margin-bottom:12px; }

.auth-alt{
  margin-top:14px;
  font-size:13px;
  color:#aaa;
  text-align:center;
}

/* ===== Responsive ===== */
@media (max-width: 980px){
  .grid-cards{ grid-template-columns:1fr; }
  .grid-cards.two{ grid-template-columns:1fr; }
}

@media (max-width: 768px){
  .nav-links{ display:none; }
  .section{ padding:110px 20px 72px; }
  .headline{ font-size:clamp(30px,8vw,42px); }
  .subcopy{ max-width:100%; }
}

/* ===== App UI (Panels, Forms, Tables, Badges) ===== */
.page{
  /* Pages that use the main top nav (nav is fixed) */
  padding-top:96px;
  padding-inline: clamp(24px,6vw,80px);
  padding-bottom:80px;
}

.page-hero{
  padding:32px 0 22px;
}

.app-main{
  padding-top:96px;
  padding-inline: clamp(24px,6vw,80px);
  padding-bottom:80px;
}

.app-hero{
  padding:32px 0 22px;
}

.app-grid{
  display:grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap:18px;
}

.panel, .app-card{
  border-radius:18px;
  padding:18px;
  background:rgba(255,255,255,0.03);
  border:1px solid rgba(255,255,255,0.08);
  box-shadow:0 0 30px rgba(255,18,54,0.08);
}

.panel-title{
  font-weight:800;
  letter-spacing:0.08em;
  text-transform:uppercase;
  font-size:11px;
  color:rgba(255,255,255,0.78);
  margin-bottom:10px;
}

.form-row{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:12px;
}

.input, .select{
  width:100%;
  padding:12px;
  background:#0b0b12;
  border:1px solid rgba(255,255,255,0.10);
  color:#fff;
  border-radius:12px;
  outline:none;
}

.input:focus, .select:focus{
  border-color: rgba(255,18,54,0.35);
  box-shadow:0 0 18px rgba(255,18,54,0.14);
}

.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  padding:12px 16px;
  border:none;
  border-radius:999px;
  background:linear-gradient(120deg, var(--red), var(--red-soft));
  color:#fff;
  font-weight:800;
  letter-spacing:0.08em;
  text-transform:uppercase;
  font-size:12px;
  cursor:pointer;
  box-shadow:0 0 18px rgba(255,18,54,0.45);
  transition:transform .2s ease;
}

.btn:hover{ transform:scale(1.04); }

.btn-ghost2{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:10px 14px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,0.16);
  background:rgba(255,255,255,0.03);
  font-size:12px;
  letter-spacing:0.12em;
  text-transform:uppercase;
  color:rgba(255,255,255,0.85);
  cursor:pointer;
}

.table{
  border-radius:18px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,0.08);
  background:rgba(5,5,11,0.92);
}

.trow{
  display:grid;
  grid-template-columns: 1.2fr .7fr .5fr .8fr;
  gap:12px;
  padding:12px 16px;
  font-size:13px;
}

.trow.head{
  background:rgba(255,255,255,0.04);
  text-transform:uppercase;
  letter-spacing:0.16em;
  font-size:10px;
  color:var(--muted);
}

.trow:not(.head):nth-child(even){ background:rgba(255,255,255,0.02); }

.badge{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:6px 10px;
  border-radius:999px;
  font-size:11px;
  letter-spacing:0.12em;
  text-transform:uppercase;
  border:1px solid rgba(255,255,255,0.12);
  background:rgba(255,255,255,0.03);
  color:rgba(255,255,255,0.85);
}

.badge.red{
  border-color: rgba(255,18,54,0.35);
  box-shadow:0 0 18px rgba(255,18,54,0.14);
}

.kpi{
  display:grid;
  grid-template-columns:repeat(3, 1fr);
  gap:12px;
  margin-top:12px;
}

.kpi .app-card strong{
  font-size:24px;
  letter-spacing:0.02em;
}

.muted{ color:#a0a2bf; }

@media (max-width: 980px){
  .app-grid{ grid-template-columns:1fr; }
  .form-row{ grid-template-columns:1fr; }
  .kpi{ grid-template-columns:1fr; }
  .trow{ grid-template-columns: 1fr; }
}

/* =========================
   BURGER MENU (FINAL - FIXED)
========================= */

/* Burger button - hard reset */
.burger{
  all: unset;
  width: 44px;
  height: 40px;
  display: none; /* desktop hidden */
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;

  border-radius: 14px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.burger span{
  all: unset;
  display: block;
  width: 18px;
  height: 2px;
  background: rgba(255,255,255,.95);
  border-radius: 2px;
  transition: transform .18s ease, opacity .18s ease;
}

/* Mobile Menu wrapper */
.mobile-menu{
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  pointer-events: none;
}

/* Backdrop only (blur only here) */
.mobile-menu__backdrop{
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(0,0,0,.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  transition: opacity .2s ease;
}

/* Panel stays sharp */
.mobile-menu__panel{
  position: absolute;
  top: 0;
  right: 0;
  z-index: 2;

  width: min(88vw, 360px);
  height: 100%;
  padding: 18px;

  background: rgba(12,10,18,.96);
  border-left: 1px solid rgba(255,255,255,.12);
  box-shadow: -20px 0 60px rgba(0,0,0,.65);

  transform: translateX(100%);
  transition: transform .25s ease;
}

/* Open */
.mobile-menu.is-open{
  display: block;
  pointer-events: auto;
}
.mobile-menu.is-open .mobile-menu__backdrop{
  opacity: 1;
}
.mobile-menu.is-open .mobile-menu__panel{
  transform: translateX(0);
}

/* Panel UI */
.mobile-menu__top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding-bottom:12px;
  border-bottom:1px solid rgba(255,255,255,.10);
}
.mobile-menu__title{
  letter-spacing:.22em;
  font-size:12px;
  opacity:.9;
}
.mobile-close{
  all: unset;
  width:42px;
  height:38px;
  border-radius:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.92);
  cursor:pointer;
}
.mobile-menu__links{
  display:grid;
  gap:10px;
  padding:14px 0;
}
.mobile-menu__links a{
  padding:12px 12px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.04);
  letter-spacing:.18em;
  font-size:12px;
  text-decoration:none;
  color: rgba(255,255,255,.92);
}
.mobile-menu__actions{
  margin-top:8px;
  padding-top:14px;
  border-top:1px solid rgba(255,255,255,.10);
  display:grid;
  gap:10px;
}

/* Mobile nav layout */
@media (max-width: 720px){
  .burger{ display: flex; }
  .nav-links{ display: none !important; }

  .nav{
    padding: 10px 14px;
    gap: 10px;
  }
  .logo{
    font-size: 13px;
    letter-spacing: .18em;
  }
}

/* =========================
   MOBILE NAV: burger on right, hide logout/user
========================= */
@media (max-width: 720px){

  /* Keep nav as a single row */
  .nav{
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  /* Put burger on the far right */
  .burger{
    margin-left: auto;
  }

  /* Hide the right-side stuff (logout/user) on mobile */
  .nav-right{
    display: none !important;
  }

  /* Optional: make logo not shrink weirdly */
  .logo{
    flex: 0 0 auto;
  }
}

/* =========================
   INDEX – TOURNAMENT SECTION (BIGGER + CLEANER)
========================= */

.section-tournaments{
  align-items: flex-start;

}

/* Two strong columns */
.tournament-layout{
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;   /* equal power */
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

/* Left should not be constrained by .section-content max-width */
.tournament-left{
  max-width: none;
}

/* Make the right panel a real board */
.tournament-upcoming{
  margin-top: 0;                 /* align with headline */
  border-radius: 22px;
  padding: 18px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 0 40px rgba(255,18,54,0.10);
  min-height: 400px;             /* makes it feel “big” */
  display: flex;
  flex-direction: column;
}

/* Title spacing */
.tournament-upcoming .panel-title{
  margin-bottom: 15px;
}

/* Board/table should fill the card and look roomy */
.tournament-upcoming .table{
  background: rgba(5,5,11,0.65);
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.08);
}

/* Give rows more breathing room on desktop */
.tournament-upcoming .trow{
  padding: 14px 16px;
}

/* Wider columns so it doesn't feel cramped */
@media (min-width: 1200px){
  .tournament-upcoming .trow{
    grid-template-columns: 1.4fr .7fr .7fr .6fr;
  }
}

/* Responsive: stack on smaller screens */
@media (max-width: 980px){
  .tournament-layout{
    grid-template-columns: 1fr;
  }
  .tournament-upcoming{
    min-height: unset;
  }
}
/* =========================
   INDEX – LEADERBOARD SECTION (BIG + CLEAN)
========================= */

.section-leaderboard{
  align-items: flex-start;
}

.leaderboard-layout{
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

.leaderboard-left{
  max-width: none;
}

/* Preview board */
.leaderboard-preview{
  margin-top: 0;
  border-radius: 22px;
  padding: 18px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 0 40px rgba(255,18,54,0.10);
  min-height: 420px;
  display: flex;
  flex-direction: column;
}

/* Table styling */
.leaderboard-preview .table{
  margin-top: 8px;
  background: rgba(5,5,11,0.65);
  border-radius: 18px;
  overflow: hidden;
}

/* Tight but readable rows */
.leaderboard-preview .lb-row{
  padding: 14px 16px;
  font-size: 13px;
}

/* Wider spacing on large screens */
@media (min-width: 1200px){
  .leaderboard-preview .lb-row{
    grid-template-columns: 60px 1.4fr 1fr;
  }
}

/* Responsive stack */
@media (max-width: 980px){
  .leaderboard-layout{
    grid-template-columns: 1fr;
  }
  .leaderboard-preview{
    min-height: unset;
  }
}
/* =========================
   CENTERED SECTIONS (HOW / FEATURES / FAQ)
========================= */

/* Give these sections a centered “editorial” layout */
.section-how .section-content,
.section-features .section-content,
.section-faq .section-content{
  margin-inline: auto;
  text-align: center;
  max-width: 1100px; /* wider but still controlled */
}

/* Center the eyebrow + fix spacing */
.section-how .eyebrow,
.section-features .eyebrow,
.section-faq .eyebrow{
  margin-inline: auto;
}

/* Make subcopy centered and not too wide */
.section-how .subcopy,
.section-features .subcopy{
  margin-inline: auto;
  max-width: 720px;
}

/* Cards sit centered and look balanced */
.section-how .grid-cards,
.section-features .grid-cards{
  justify-content: center;
}

/* Improve how the cards look in centered layouts */
.section-how .card,
.section-features .card{
  text-align: left;               /* keep card text readable */
  max-width: 360px;               /* prevents super wide cards */
  margin-inline: auto;
}

/* Features 2-column layout should be centered */
.section-features .grid-cards.two{
  grid-template-columns: repeat(2, minmax(0, 420px));
  justify-content: center;
}

/* FAQ centered with readable width */
.section-faq .faq{
  max-width: 820px;
  margin: 18px auto 0;
  text-align: left;               /* FAQ reads better left aligned */
}

/* Make FAQ details look nicer */
.section-faq details{
  background: rgba(255,255,255,0.025);
  border: 1px solid rgba(255,255,255,0.10);
}

/* Responsive */
@media (max-width: 980px){
  .section-features .grid-cards.two{
    grid-template-columns: 1fr;
  }
  .section-how .card,
  .section-features .card{
    max-width: 520px;
  }
}
/* =========================
   FOOTER (CLEAN + FULL WIDTH + HORIZONTAL ON MOBILE)
========================= */

/* IMPORTANT: remove any old footer spacing hacks */
body{
  padding-bottom: 0 !important;
}

/* Footer background spans full width */
.site-footer{
  position: relative;
  width: 100%;
  margin-top: auto;

  padding: 56px 0 22px;
  border-top: 1px solid rgba(255,255,255,0.10);

  background: linear-gradient(to top, rgba(5,5,11,0.92), rgba(5,5,11,0.35), rgba(5,5,11,0));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* Inner footer container */
.site-footer .footer-inner,
.site-footer .footer-bottom{
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(16px, 5vw, 80px);
}

/* Keep footer layout horizontal by default */
.footer-inner{
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(18px, 3vw, 44px);
  align-items: start;
}

/* Brand */
.footer-logo{
  font-weight: 900;
  letter-spacing: .30em;
  font-size: 14px;
  margin-bottom: 10px;
}
.footer-tag{
  color: rgba(255,255,255,0.65);
  line-height: 1.6;
  max-width: 520px;
  font-size: 13px;
}

/* Links columns (horizontal even on mobile) */
.footer-cols{
  display: grid;
  grid-template-columns: repeat(3, minmax(140px, 1fr));
  gap: 16px;
}

/* Title + links */
.footer-title{
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.75);
  margin-bottom: 10px;
}
.footer-col a{
  display: block;
  padding: 6px 0;
  color: rgba(255,255,255,0.60);
  font-size: 13px;
  text-decoration: none;
  transition: color .18s ease, transform .18s ease;
  white-space: nowrap;
}
.footer-col a:hover{
  color: rgba(255,255,255,0.92);
  transform: translateX(2px);
}

/* Bottom row */
.footer-bottom{
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,0.08);

  display: flex;
  justify-content: space-between;
  gap: 12px;

  color: rgba(255,255,255,0.55);
  font-size: 12px;
}
.footer-muted{ color: rgba(255,255,255,0.45); }

/* ✅ MOBILE: keep it horizontal by allowing sideways scroll instead of stacking */
@media (max-width: 980px){

  /* keep brand + links on the same row */
  .footer-inner{
    grid-template-columns: 1fr 1fr;
  }

  /* if the 3 columns don't fit, allow horizontal scroll */
  .footer-cols{
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6px;
    scrollbar-width: thin;
  }

  /* prevent columns from shrinking too much */
  .footer-col{
    min-width: 150px;
  }

  /* bottom stays horizontal too */
  .footer-bottom{
    flex-direction: row;
    align-items: center;
  }
}

/* Extra small screens: still horizontal, but tighter */
@media (max-width: 520px){
  .site-footer{ padding-top: 44px; }
  .footer-logo{ font-size: 13px; }
  .footer-tag{ font-size: 12.5px; }

  .footer-inner{
    grid-template-columns: 1fr; /* brand on top */
  }

  /* links remain horizontal scroll */
  .footer-cols{
    grid-template-columns: repeat(3, minmax(160px, 1fr));
  }

  .footer-bottom{
    flex-direction: column;
    align-items: flex-start;
  }
}
/* Fix line cutting through tournament table (mobile) */
@media (max-width: 980px){
  .section-tournaments{
    overflow: visible;   /* stop section from slicing content */
  }

  .tournament-upcoming{
    overflow: hidden;    /* keep rounding clean on the panel */
  }

  .tournament-upcoming .table{
    border: none;        /* avoid double border line */
    background: rgba(5,5,11,0.65);
  }
}
/* =========================
   MOBILE: STOP SECTION OVERLAP
========================= */
@media (max-width: 980px){
  .section{
    align-items: flex-start;
    min-height: auto;
    overflow: visible;
    padding-bottom: 80px;
  }

  .tournament-upcoming,
  .leaderboard-preview{
    margin-top: 18px;
    position: relative;
    z-index: 1;
  }
}
