:root {
  --bg: #0b1120;
  --panel: #111a2e;
  --panel-2: #16223c;
  --line: #223154;
  --text: #e5e7eb;
  --muted: #93a4c3;
  /* futsal.lk brand red */
  --brand: #d81f26;
  --brand-2: #b0161c;
  --brand-ink: #ffffff;
  --accent: #38bdf8;
  --danger: #f87171;
  --warn: #fbbf24;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(0,0,0,.35);
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, system-ui, sans-serif;
  --font-head: 'Sora', 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  background: radial-gradient(1200px 600px at 80% -10%, #16233f 0%, var(--bg) 60%);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .brand, .sb-score, .sb-team-name { font-family: var(--font-head); }

/* ---------- top bar ---------- */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20;
  background: rgba(11,18,32,.82); backdrop-filter: blur(10px);
}
.brand { font-weight: 800; font-size: 20px; color: var(--text); text-decoration: none; letter-spacing: -.02em; }
.brand span { color: var(--brand); }
.brand img { height: 30px; display: block; }
.topnav { display: flex; gap: 12px; align-items: center; }
/* main nav as an iconed pill group */
.navgroup { display: flex; gap: 2px; align-items: center; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 4px; }
.navpill {
  display: inline-flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 600;
  color: var(--muted); text-decoration: none; cursor: pointer; padding: 8px 13px; border-radius: 10px;
  border: 0; background: none; transition: color .12s ease, background .12s ease;
}
.navpill:hover { color: var(--text); background: var(--panel-2); }
.navpill.active { color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-2)); box-shadow: 0 4px 14px rgba(216,31,38,.32); }
.navpill.active .ico { color: #fff; }
.topnav .btn { padding: 9px 16px; }
/* avatar + user menu */
.useracct { position: relative; }
.avatar-btn { width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: linear-gradient(135deg, #202b47, #16223c);
  color: var(--text); font-weight: 800; font-family: var(--font-head); cursor: pointer; font-size: 14px; }
.avatar-btn:hover { border-color: #33477a; }
.usermenu { position: absolute; right: 0; top: 50px; min-width: 220px; background: var(--panel); border: 1px solid var(--line);
  border-radius: 14px; box-shadow: var(--shadow); padding: 8px; z-index: 60; display: none; }
.useracct.open .usermenu { display: block; }
.usermenu-head { padding: 8px 10px 10px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.usermenu-item { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 10px 10px; border-radius: 10px;
  color: var(--text); background: none; border: 0; cursor: pointer; font: inherit; font-size: 14px; text-decoration: none; }
.usermenu-item:hover { background: var(--panel-2); }
.usermenu-item.danger { color: var(--danger); }
@media (max-width: 720px) { .navgroup { display: none; } }

main { max-width: 1000px; margin: 0 auto; padding: 22px 18px 40px; min-height: 60vh; }

/* ---------- maintenance / coming-soon ---------- */
.maint { min-height: calc(100vh - 120px); display: grid; place-items: center; padding: 20px 0; }
.maint-card { max-width: 600px; margin: 0 auto; padding: 20px; text-align: center;
  display: flex; flex-direction: column; align-items: center; }
.maint-logo { height: 46px; width: auto; margin-bottom: 20px; }
.maint-title { font-family: var(--font-head); font-size: clamp(32px, 6vw, 52px); letter-spacing: -.02em; margin: 6px 0 12px; }
.maint-sub { color: var(--muted); font-size: 17px; line-height: 1.6; margin: 0 auto 26px; max-width: 460px; }
.maint-feats { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 30px; }
.maint-feat { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 600; color: var(--text);
  background: var(--panel); border: 1px solid var(--line); padding: 9px 14px; border-radius: 999px; }
.maint-feat .ico { color: var(--brand); }
.maint-admin { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); text-decoration: none; font-size: 13px; }
.maint-admin:hover { color: var(--text); }

/* ---------- site footer ---------- */
.site-footer { border-top: 1px solid var(--line); margin-top: 20px; padding: 26px 18px calc(30px + env(safe-area-inset-bottom)); background: #0c1424; }
.footer-inner { max-width: 1000px; margin: 0 auto; display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.footer-brand { font-family: var(--font-head); font-weight: 800; font-size: 18px; color: var(--brand); }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; }
.footer-links a { color: var(--muted); text-decoration: none; font-size: 14px; }
.footer-links a:hover { color: var(--text); }
.footer-copy { max-width: 1000px; margin: 18px auto 0; }
@media (max-width: 720px) { .site-footer { padding-bottom: calc(96px + env(safe-area-inset-bottom)); } }

/* ---------- prose (info / legal pages) ---------- */
.prose { line-height: 1.6; }
.prose h3 { margin-top: 22px; }
.prose-p { color: var(--text); }
.loading { color: var(--muted); text-align: center; padding: 60px 0; }

/* ---------- generic ---------- */
h1 { font-size: 26px; margin: 6px 0 2px; letter-spacing: -.02em; }
h2 { font-size: 20px; margin: 20px 0 10px; }
h3 { font-size: 16px; margin: 0 0 10px; }
.sub { color: var(--muted); margin: 0 0 18px; }
a { color: var(--accent); }

.card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px; box-shadow: var(--shadow);
}
.grid { display: grid; gap: 14px; }
@media (min-width: 640px) { .grid.cols-2 { grid-template-columns: 1fr 1fr; } .grid.cols-3 { grid-template-columns: 1fr 1fr 1fr; } }

.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spread { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.pill { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--panel-2); color: var(--muted); }
.pill.ok { background: rgba(34,197,94,.15); color: #86efac; }
.pill.warn { background: rgba(251,191,36,.15); color: var(--warn); }
.pill.bad { background: rgba(248,113,113,.15); color: var(--danger); }

/* ---------- buttons ---------- */
.btn {
  font: inherit; font-weight: 700; cursor: pointer; border: 0; border-radius: 12px;
  padding: 12px 16px; background: var(--panel-2); color: var(--text); border: 1px solid var(--line);
}
.btn:hover { border-color: #33477a; }
.btn.primary { background: linear-gradient(90deg,var(--brand),var(--brand-2)); color: var(--brand-ink); border: 0; }
.btn.accent { background: linear-gradient(90deg,var(--accent),#0ea5e9); color: #04121c; border: 0; }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--danger); }
.btn.sm { padding: 7px 11px; font-size: 13px; border-radius: 10px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.block { width: 100%; display: block; text-align: center; }

/* ---------- forms ---------- */
label.field { display: block; margin: 10px 0; }
label.field > span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
input, select, textarea {
  font: inherit; width: 100%; padding: 11px 12px; border-radius: 10px;
  background: var(--bg); color: var(--text); border: 1px solid var(--line);
}
input:focus, select:focus, textarea:focus { outline: 2px solid rgba(56,189,248,.4); border-color: var(--accent); }
.inline-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* ---------- landing hero ---------- */
.hero {
  position: relative; overflow: hidden; border-radius: 22px; margin-bottom: 20px;
  padding: 44px 28px; border: 1px solid var(--line);
  background:
    radial-gradient(900px 400px at 85% -20%, rgba(216,31,38,.35), transparent 60%),
    radial-gradient(700px 500px at 0% 120%, rgba(56,189,248,.14), transparent 55%),
    linear-gradient(180deg, #141d33, #0d1526);
}
.hero::after {
  content: ""; position: absolute; right: -40px; top: -40px; width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(216,31,38,.25), transparent 70%); filter: blur(10px); pointer-events: none;
}
.hero-inner { position: relative; max-width: 640px; }
.hero-badge { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; color: #fca5a5;
  background: rgba(216,31,38,.14); border: 1px solid rgba(216,31,38,.3); padding: 6px 12px; border-radius: 999px; }
.hero-title { font-family: var(--font-head); font-size: clamp(34px, 6vw, 56px); line-height: 1.02; letter-spacing: -.03em; margin: 16px 0 10px; }
.hero-sub { color: var(--muted); font-size: clamp(15px, 2vw, 18px); max-width: 540px; margin: 0 0 22px; }
.hero-search-wrap { display: flex; align-items: center; gap: 8px; background: var(--bg); border: 1px solid var(--line);
  border-radius: 14px; padding: 6px 6px 6px 14px; max-width: 520px; color: var(--muted); }
.hero-search { flex: 1; border: 0; background: transparent; padding: 10px 4px; color: var(--text); }
.hero-search:focus { outline: none; }
.hero-cta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.hero-cta .btn { background: rgba(255,255,255,.06); border: 1px solid var(--line); }

/* ---------- feature strip ---------- */
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 26px; }
@media (max-width: 760px) { .features { grid-template-columns: 1fr 1fr; } }
.feature { display: flex; gap: 12px; align-items: flex-start; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.feature-ico { width: 40px; height: 40px; border-radius: 11px; flex: none; display: grid; place-items: center;
  color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-2)); }
.feature-title { font-weight: 700; font-size: 15px; }

/* ---------- rich venue cards ---------- */
.venue-card.v2 { padding: 0; overflow: hidden; cursor: pointer; transition: transform .12s ease, border-color .12s ease; }
.venue-card.v2:hover { transform: translateY(-3px); border-color: #33477a; }
.venue-banner { position: relative; height: 96px; display: grid; place-items: center;
  background: linear-gradient(135deg, #202b47, #16223c);
  border-bottom: 1px solid var(--line); overflow: hidden; }
.venue-banner::before { content: ""; position: absolute; inset: 0;
  background: radial-gradient(60px 60px at 20% 30%, rgba(216,31,38,.35), transparent 70%),
    radial-gradient(80px 80px at 85% 80%, rgba(56,189,248,.2), transparent 70%); }
.venue-banner.has-photo { height: 150px; }
.venue-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.venue-banner.has-photo::before { z-index: 1; background: linear-gradient(180deg, transparent 55%, rgba(11,17,32,.55)); }
.venue-initials { position: relative; font-family: var(--font-head); font-weight: 800; font-size: 34px; color: rgba(255,255,255,.85); letter-spacing: .04em; }
.venue-count { position: absolute; z-index: 2; top: 10px; right: 10px; background: rgba(0,0,0,.55); border: 1px solid var(--line);
  color: var(--text); font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; }
.venue-body { padding: 14px 16px 16px; }
.venue-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); flex-wrap: wrap; }

/* ---------- mobile bottom tab bar ---------- */
.tabbar { display: none; }
@media (max-width: 720px) {
  .tabbar { display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 40;
    background: rgba(10,15,28,.96); backdrop-filter: blur(14px); border-top: 1px solid var(--line);
    padding: 8px 6px calc(8px + env(safe-area-inset-bottom)); }
  .tabbar a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 4px 0;
    color: var(--muted); text-decoration: none; font-size: 11px; font-weight: 600; }
  .tabbar a .ico { padding: 5px 16px; border-radius: 12px; transition: background .15s ease, color .15s ease; }
  .tabbar a.active { color: var(--brand); }
  .tabbar a.active .ico { background: rgba(216,31,38,.16); color: var(--brand); }
  /* Clear the fixed bar (bar height ~52px + the phone's home-indicator area). */
  main { padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
}

/* ---------- legacy venue / court cards ---------- */
.venue-card h3 { margin-bottom: 2px; }
.court-line { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.price { font-weight: 800; color: var(--brand); }

/* ---------- slot grid ---------- */
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); gap: 8px; }
.slot { padding: 12px 6px; text-align: center; border-radius: 10px; border: 1px solid var(--line); background: var(--panel-2); cursor: pointer; font-weight: 600; font-size: 14px; }
.slot.booked { opacity: .35; cursor: not-allowed; text-decoration: line-through; }
.slot.sel { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }

/* ---------- toast / modal ---------- */
.toast {
  position: fixed; bottom: calc(24px + env(safe-area-inset-bottom)); left: 50%; z-index: 100;
  display: flex; align-items: center; gap: 11px;
  background: rgba(17, 26, 46, .94); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--line); border-left: 3px solid var(--muted);
  padding: 12px 18px 12px 14px; border-radius: 14px;
  box-shadow: 0 14px 44px rgba(0, 0, 0, .55), 0 2px 8px rgba(0, 0, 0, .3);
  max-width: min(92vw, 440px); font-size: 14.5px; font-weight: 500; line-height: 1.45;
  color: var(--text); cursor: pointer;
  animation: toastIn .3s cubic-bezier(.2, 1.15, .4, 1) both;
}
.toast-ico { width: 26px; height: 26px; border-radius: 8px; flex: none; display: grid; place-items: center; }
.toast-ico svg { display: block; }
.toast-msg { min-width: 0; }
.toast-ok { border-left-color: #22c55e; }
.toast-ok .toast-ico { background: rgba(34, 197, 94, .16); color: #86efac; }
.toast-error { border-left-color: var(--danger); }
.toast-error .toast-ico { background: rgba(248, 113, 113, .16); color: var(--danger); }
.toast-info { border-left-color: var(--accent); }
.toast-info .toast-ico { background: rgba(56, 189, 248, .16); color: var(--accent); }
.toast.toast-out { animation: toastOut .22s ease forwards; }
@keyframes toastIn {
  from { opacity: 0; transform: translate(-50%, 18px) scale(.96); }
  to   { opacity: 1; transform: translate(-50%, 0) scale(1); }
}
@keyframes toastOut {
  from { opacity: 1; transform: translate(-50%, 0) scale(1); }
  to   { opacity: 0; transform: translate(-50%, 12px) scale(.97); }
}
/* Clear the mobile bottom tab bar so the toast never sits on top of it. */
@media (max-width: 720px) { .toast { bottom: calc(78px + env(safe-area-inset-bottom)); max-width: 92vw; } }
@media (prefers-reduced-motion: reduce) { .toast { animation: none; transform: translate(-50%, 0); } }
.modal-back { position: fixed; inset: 0; background: rgba(0,0,0,.55); display: flex; align-items: flex-end; justify-content: center; z-index: 60; }
.modal { background: var(--panel); border: 1px solid var(--line); border-radius: 18px 18px 0 0; padding: 20px; width: 100%; max-width: 520px; box-shadow: var(--shadow); }
@media (min-width: 640px) { .modal-back { align-items: center; } .modal { border-radius: 18px; } }

/* ---------- connection dot ---------- */
.conn { position: fixed; bottom: 10px; right: 12px; z-index: 30; }
.status-dot { width: 10px; height: 10px; border-radius: 50%; background: #22c55e; display: inline-block; box-shadow: 0 0 8px #22c55e; }
.status-dot.off { background: var(--danger); box-shadow: 0 0 8px var(--danger); }

/* ======================================================================
   SCOREBOARD (scorer + display)
   ====================================================================== */
.scoreboard { text-align: center; }
.sb-teams { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; }
.sb-team-name { font-size: 18px; font-weight: 700; }
.sb-score { font-size: clamp(56px, 18vw, 150px); font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.sb-colon { font-size: clamp(40px, 10vw, 90px); color: var(--muted); font-weight: 800; }
.sb-clock { font-size: clamp(30px, 9vw, 64px); font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: .04em; }
.sb-meta { display: flex; justify-content: center; gap: 18px; color: var(--muted); margin-top: 8px; flex-wrap: wrap; }
.sb-fouls { display: flex; gap: 6px; justify-content: center; }
.dot { width: 12px; height: 12px; border-radius: 50%; background: var(--line); }
.dot.on { background: var(--warn); }
.dot.over { background: var(--danger); }

.display-full { min-height: 78vh; display: flex; flex-direction: column; justify-content: center; }
.display-full .sb-score { font-size: clamp(80px, 26vw, 320px); }
.display-full .sb-clock { font-size: clamp(44px, 14vw, 120px); }
.display-full .sb-team-name { font-size: clamp(20px, 5vw, 44px); }

/* scorer control grid */
.score-controls { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 16px; }
.team-panel { border: 1px solid var(--line); border-radius: 14px; padding: 12px; }
.team-panel h4 { margin: 0 0 10px; font-size: 15px; }
.btn-goal { font-size: 22px; padding: 18px; }
.ctrl-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.ctrl-row .btn { flex: 1; }

.timeline { margin-top: 16px; text-align: left; }
.timeline .ev { padding: 6px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }

.center { text-align: center; }
.mt { margin-top: 16px; }
.mono { font-variant-numeric: tabular-nums; }
.hint { background: var(--panel-2); border: 1px dashed var(--line); border-radius: 12px; padding: 12px; color: var(--muted); font-size: 13px; }
.codebox { font-size: 28px; font-weight: 800; letter-spacing: .18em; text-align: center; padding: 12px; background: var(--panel-2); border-radius: 12px; }

/* ---------- svg icons ---------- */
.ico { display: inline-flex; align-items: center; justify-content: center; vertical-align: -0.15em; line-height: 0; color: inherit; }
.ico svg { display: block; }
.btn .ico { margin-right: 6px; vertical-align: -0.18em; }
.btn.sm .ico, .btn.icon-only .ico { margin-right: 4px; }
.btn.icon-only { margin-right: 0; }
.btn.icon-only .ico { margin: 0; }

/* ============================ OWNER DASHBOARD ============================ */
.dash { display: grid; grid-template-columns: 236px 1fr; gap: 0; min-height: calc(100vh - 58px); margin: -20px -16px 0; }
.dash-side { background: #0c1424; border-right: 1px solid var(--line); padding: 16px 12px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 58px; align-self: start; height: calc(100vh - 58px); overflow-y: auto; }
.dash-venue { display: flex; gap: 10px; align-items: center; padding: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px; }
.dash-venue .avatar { width: 38px; height: 38px; border-radius: 9px; background: linear-gradient(135deg,var(--brand),var(--brand-2)); display: grid; place-items: center; color: #fff; flex: none; }
.dash-nav { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 10px; color: var(--muted); cursor: pointer; font-size: 14px; font-weight: 500; border: 0; background: none; text-align: left; width: 100%; }
.dash-nav:hover { background: var(--panel-2); color: var(--text); }
.dash-nav.active { background: var(--brand); color: #fff; }
.dash-nav .ico { color: inherit; }
.dash-main { padding: 22px 24px 90px; min-width: 0; }
.dash-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }

/* stat tiles */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
@media (max-width: 1000px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .tiles { grid-template-columns: 1fr 1fr; } }
.tile { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.tile-top { display: flex; justify-content: space-between; align-items: center; color: var(--muted); font-size: 13px; }
.tile-ico { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: #fff; }
.tile-val { font-family: var(--font-head); font-size: 26px; font-weight: 800; margin: 8px 0 4px; letter-spacing: -.02em; }
.delta { font-size: 12px; font-weight: 600; }
.delta.up { color: #4ade80; } .delta.down { color: var(--danger); }

/* dashboard cards + charts */
.dash-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; margin-top: 16px; }
@media (max-width: 900px) { .dash-grid { grid-template-columns: 1fr; } }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.panel-head h3 { margin: 0; }
.area-chart, .bar-chart, .donut { width: 100%; display: block; }
.mini-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
@media (max-width: 700px) { .mini-2 { grid-template-columns: 1fr; } }
.legend { display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.legend-row { display: flex; align-items: center; gap: 8px; }
.legend-dot { width: 10px; height: 10px; border-radius: 3px; }

/* upcoming list */
.up-row { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.up-row:first-child { border-top: 0; }
.up-date { text-align: center; min-width: 42px; }
.up-date .d { font-family: var(--font-head); font-weight: 800; font-size: 18px; line-height: 1; }
.up-date .m { font-size: 11px; color: var(--muted); text-transform: uppercase; }

/* quick actions */
.qa-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
@media (max-width: 900px) { .qa-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 520px) { .qa-grid { grid-template-columns: repeat(2, 1fr); } }
.qa { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 14px; text-align: center; cursor: pointer; color: var(--text); }
.qa:hover { border-color: var(--brand); }
.qa .ico { color: var(--brand); }
.qa-label { font-size: 13px; font-weight: 600; margin-top: 6px; }

/* reviews */
.review { display: flex; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.review:first-child { border-top: 0; }
.stars { display: inline-flex; gap: 1px; color: var(--warn); }
.rating-badge { background: rgba(34,197,94,.15); color: #86efac; font-weight: 700; border-radius: 8px; padding: 2px 8px; font-size: 13px; }

/* simple data table */
.dtable { width: 100%; border-collapse: collapse; font-size: 14px; }
.dtable th { text-align: left; color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; padding: 8px 10px; border-bottom: 1px solid var(--line); }
.dtable td { padding: 10px; border-bottom: 1px solid var(--line); }
.dtable tr:hover td { background: rgba(255,255,255,.02); }
.table-scroll { overflow-x: auto; }

/* gauge */
.gauge-num { font-family: var(--font-head); font-size: 30px; font-weight: 800; }

.book-banner { height: 200px; border-radius: 16px; background: #0c1424 center/cover no-repeat; border: 1px solid var(--line); margin: 12px 0 8px; }

/* venue photo upload preview */
.photo-preview { height: 160px; border-radius: 12px; border: 1px solid var(--line); background: #0c1424 center/cover no-repeat; margin-top: 6px; position: relative; }
.photo-preview.empty::after, .photo-preview.checking::after { content: "No photo yet"; position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: 13px; }
.photo-preview.checking::after { content: ""; }

/* dashboard - mobile: single column, sidebar becomes a horizontal scroll strip.
   Placed after the base rules so these overrides win the source-order tie. */
@media (max-width: 860px) {
  .dash { grid-template-columns: 1fr; }
  .dash-main { padding: 16px 14px 90px; }
  .dash-side { flex-direction: row; height: auto; position: sticky; top: 58px; overflow-x: auto; overflow-y: hidden; gap: 6px; padding: 10px 12px; border-right: 0; border-bottom: 1px solid var(--line); z-index: 10; }
  .dash-side .dash-venue, .dash-side > div:last-child { display: none; }
  .dash-nav { width: auto; white-space: nowrap; flex: none; padding: 8px 12px; }
}

/* ---------- goal celebration ---------- */
.celebrate { position: fixed; inset: 0; z-index: 200; pointer-events: none; display: flex; flex-direction: column; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 45%, rgba(0,0,0,.35), rgba(0,0,0,.72)); opacity: 1; transition: opacity .5s ease; }
.celebrate.cel-out { opacity: 0; }
.cel-text { font-family: var(--font-head); font-weight: 800; font-size: clamp(60px, 18vw, 220px); letter-spacing: -.02em; line-height: 1; text-shadow: 0 6px 40px rgba(0,0,0,.5); animation: celPop .5s cubic-bezier(.2,1.3,.4,1) both; }
.cel-sub { font-family: var(--font-head); font-weight: 700; font-size: clamp(20px, 5vw, 48px); color: #fff; margin-top: 8px; animation: celPop .5s .12s both; }
@keyframes celPop { from { transform: scale(.3); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.cf-wrap { position: absolute; inset: 0; overflow: hidden; }
.cf { position: absolute; top: -20px; width: 12px; height: 16px; border-radius: 2px; animation-name: celFall; animation-timing-function: linear; animation-iteration-count: 1; }
@keyframes celFall { 0% { transform: translateY(-20px) rotate(0); opacity: 1; } 100% { transform: translateY(105vh) rotate(540deg); opacity: .9; } }

/* ---------- tournament bracket ---------- */
.champion { border-color: var(--warn); background: linear-gradient(180deg, rgba(251,191,36,.12), var(--panel)); }
.bracket-scroll { overflow-x: auto; padding: 8px 2px 16px; }
.bracket { display: flex; gap: 26px; min-width: min-content; align-items: stretch; }
.bracket-round { display: flex; flex-direction: column; min-width: 210px; }
.bracket-round-name { font-size: 13px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 10px; text-align: center; }
.bracket-fixtures { display: flex; flex-direction: column; justify-content: space-around; flex: 1; gap: 14px; }
.bx-wrap { display: flex; flex-direction: column; gap: 4px; }
.bx-fixture { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.bx-fixture.live { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.bx-team { display: flex; justify-content: space-between; align-items: center; padding: 9px 11px; font-size: 14px; }
.bx-team:first-child { border-bottom: 1px solid var(--line); }
.bx-team.win { color: #86efac; font-weight: 700; }
.bx-team.lost { color: var(--muted); }
.bx-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 140px; }
.bx-score { font-variant-numeric: tabular-nums; font-weight: 700; }
.bx-actions { display: flex; gap: 6px; justify-content: flex-end; }

/* admin console */
.tiny { font-size: 12px; }
.role-select { padding: 6px 8px; font-size: 13px; min-width: 130px; }
.card .spread input[type="search"], .card .spread input[type="text"] { max-width: 220px; margin: 0; }

/* newsletter (footer) + email verification banner */
.footer-news { margin-top: 8px; }
.footer-news label { display: block; margin-bottom: 6px; }
.footer-news-row { display: flex; gap: 8px; max-width: 340px; }
.footer-news-row input { flex: 1; margin: 0; }
.footer-news-row button { background: var(--brand); color: #fff; border: 0; border-radius: 10px; padding: 0 16px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.footer-news-row button:hover { filter: brightness(1.05); }
.footer-news-msg { margin-top: 6px; min-height: 16px; }
.verify-banner { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap;
  background: rgba(251,191,36,.14); color: var(--warn); border-bottom: 1px solid rgba(251,191,36,.3);
  padding: 10px 16px; font-size: 14px; font-weight: 500; }
.verify-banner .btn { background: var(--warn); color: #1a1300; border: 0; }
