﻿/* MSC 2026 â€” Mising Sports Carnival Â· TMPK design system */
:root {
  --r: #E10600;
  --r-hover: #B80500;
  --r-dark: #8B0000;
  --ink: #1A1A1A;
  --ink-2: #333;
  --muted: #6b7280;
  --line: #e5e7eb;
  --bg: #f6f7f9;
  --card: #fff;
  --ok: #15803d;
  --warn: #b45309;
  --bad: #b91c1c;
  --blue: #1d4ed8;
  --radius: 8px;
  --shadow: 0 1px 3px rgba(16,24,40,.06), 0 1px 2px rgba(16,24,40,.04);
  --shadow-lg: 0 12px 32px rgba(16,24,40,.12);
  --grad: linear-gradient(135deg, var(--r) 0%, var(--r-dark) 100%);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg);
  font-size: 15px; line-height: 1.55; -webkit-font-smoothing: antialiased;
}
a { color: var(--r); text-decoration: none; }
a:hover { color: var(--r-hover); }
img { max-width: 100%; }
.container { max-width: 1160px; margin: 0 auto; padding: 0 20px; }

/* ---------- Header ---------- */
.site-header { background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 20px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand img { border-radius: 8px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { font-size: 1.02rem; font-weight: 800; letter-spacing: -.01em; }
.brand-text small { font-size: .72rem; color: var(--muted); font-weight: 500; }
.nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nav > a { padding: 8px 12px; border-radius: 6px; font-weight: 600; font-size: .875rem; color: var(--ink-2); }
.nav > a:hover { background: #f3f4f6; color: var(--ink); }
.nav > a.active { color: var(--r); }
.nav-user { font-size: .8rem; color: var(--muted) !important; margin-left: 4px; }
.accent-bar { height: 4px; background: var(--grad); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 20px; border-radius: var(--radius); border: 1px solid transparent;
  font-family: inherit; font-size: .875rem; font-weight: 600; cursor: pointer;
  transition: all .15s ease; text-decoration: none !important; line-height: 1.3;
}
.btn--red { background: var(--r); color: #fff !important; }
.btn--red:hover { background: var(--r-hover); color: #fff; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(225,6,0,.3); }
.btn--dark { background: var(--ink); color: #fff !important; }
.btn--dark:hover { background: #000; color: #fff; }
.btn--ghost { background: transparent; border-color: var(--line); color: var(--ink-2) !important; }
.btn--ghost:hover { border-color: var(--r); color: var(--r) !important; }
.btn--sm { padding: 7px 14px; font-size: .8rem; }
.btn--xs { padding: 4px 10px; font-size: .72rem; border-radius: 5px; }
.btn--danger { background: #fef2f2; color: var(--bad) !important; border-color: #fecaca; }
.btn--danger:hover { background: var(--bad); color: #fff !important; border-color: var(--bad); }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none !important; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- Hero ---------- */
.hero {
  background: var(--grad); color: #fff; padding: 64px 0 56px; position: relative; overflow: hidden;
}
.hero::after {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 80% 20%, rgba(255,255,255,.10), transparent 55%);
  pointer-events: none;
}
.hero-inner { position: relative; z-index: 1; max-width: 820px; }
.hero-eyebrow {
  display: inline-block; background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.25);
  padding: 5px 14px; border-radius: 999px; font-size: .75rem; font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase; margin-bottom: 18px;
}
.hero h1 { margin: 0 0 12px; font-size: clamp(1.9rem, 4.5vw, 3rem); font-weight: 800; letter-spacing: -.02em; line-height: 1.12; }
.hero p { margin: 0 0 26px; font-size: 1.08rem; opacity: .92; max-width: 640px; }
.hero-meta { display: flex; gap: 22px; flex-wrap: wrap; margin-bottom: 28px; }
.hero-meta div { display: flex; flex-direction: column; }
.hero-meta b { font-size: 1.25rem; font-weight: 800; }
.hero-meta span { font-size: .78rem; opacity: .8; text-transform: uppercase; letter-spacing: .06em; }
.hero .btn--ghost { border-color: rgba(255,255,255,.45); color: #fff !important; }
.hero .btn--ghost:hover { background: rgba(255,255,255,.12); color: #fff !important; }
.hero .btn--white { background: #fff; color: var(--r) !important; }
.hero .btn--white:hover { background: #f3f4f6; color: var(--r-hover) !important; }

/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section--alt { background: var(--card); }
.sec-head { margin-bottom: 30px; }
.sec-eyebrow {
  font-size: .72rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  color: var(--r); margin-bottom: 6px;
}
.sec-head h2 { margin: 0 0 6px; font-size: 1.65rem; font-weight: 800; letter-spacing: -.02em; }
.sec-head p { margin: 0; color: var(--muted); max-width: 640px; }

/* ---------- Cards / grids ---------- */
.grid { display: grid; gap: 18px; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 900px) { .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; } }

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow);
}
.card h3 { margin: 0 0 8px; font-size: 1rem; font-weight: 700; }
.card p { margin: 0; color: var(--muted); font-size: .875rem; }
.card-icon {
  width: 42px; height: 42px; border-radius: 10px; background: linear-gradient(135deg, rgba(225,6,0,.1), rgba(139,0,0,.14));
  display: flex; align-items: center; justify-content: center; margin-bottom: 14px; font-size: 1.2rem;
}

.stat-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 22px; box-shadow: var(--shadow);
}
.stat-card .num { font-size: 2rem; font-weight: 800; color: var(--r); line-height: 1.1; }
.stat-card .label { font-size: .78rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin-top: 4px; }

/* ---------- Panels (dashboard) ---------- */
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.panel-head {
  padding: 16px 22px; border-bottom: 1px solid var(--line); display: flex;
  align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; background: #fafafa;
}
.panel-head h2, .panel-head h3 { margin: 0; font-size: 1.05rem; font-weight: 700; }
.panel-body { padding: 22px; }

/* ---------- Forms ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: .8rem; font-weight: 600; color: var(--ink); }
.field .req { color: var(--r); }
.field input, .field select, .field textarea {
  width: 100%; padding: 10px 13px; border: 1px solid var(--line); border-radius: var(--radius);
  font-family: inherit; font-size: .875rem; background: #fff; color: var(--ink); transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--r); box-shadow: 0 0 0 3px rgba(225,6,0,.1);
}
.field .help { font-size: .74rem; color: var(--muted); }
.field select[multiple] { min-height: 220px; padding: 6px; }
.field select[multiple] optgroup { font-weight: 700; color: var(--ink); font-style: normal; }
.field select[multiple] option { padding: 6px 8px; border-radius: 4px; }
.age-live {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px;
  background: #fef2f2; color: var(--r); font-size: .78rem; font-weight: 700;
}
.age-live.ok { background: #f0fdf4; color: var(--ok); }
fieldset.fs { border: none; padding: 0; margin: 0 0 8px; }
fieldset.fs legend {
  font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .1em;
  color: var(--muted); padding: 0 0 8px; margin-bottom: 16px; border-bottom: 1px solid var(--line); width: 100%;
}

/* ---------- Alerts ---------- */
.alert { padding: 12px 16px; border-radius: var(--radius); margin-bottom: 16px; font-size: .875rem; font-weight: 500; border: 1px solid; }
.alert--success { background: #f0fdf4; border-color: #bbf7d0; color: var(--ok); }
.alert--error { background: #fef2f2; border-color: #fecaca; color: var(--bad); }
.alert--info { background: #eff6ff; border-color: #bfdbfe; color: var(--blue); }
.alert--warn { background: #fffbeb; border-color: #fde68a; color: var(--warn); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: .84rem; }
table.data th {
  text-align: left; padding: 11px 14px; background: #f9fafb; border-bottom: 2px solid var(--line);
  font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); white-space: nowrap;
}
table.data td { padding: 11px 14px; border-bottom: 1px solid #f1f2f4; vertical-align: middle; }
table.data tr:hover td { background: #fafafa; }
table.data .actions { display: flex; gap: 6px; white-space: nowrap; }
.cell-name { font-weight: 600; color: var(--ink); }
.cell-sub { font-size: .74rem; color: var(--muted); }
.age-pill {
  display: inline-block; min-width: 34px; text-align: center; padding: 2px 8px; border-radius: 999px;
  background: #f3f4f6; font-weight: 700; font-size: .8rem; color: var(--ink);
}
.age-pill.warn { background: #fffbeb; color: var(--warn); }
.badge { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .7rem; font-weight: 700; }
.badge--ok { background: #f0fdf4; color: var(--ok); }
.badge--warn { background: #fffbeb; color: var(--warn); }
.badge--bad { background: #fef2f2; color: var(--bad); }
.badge--muted { background: #f3f4f6; color: var(--muted); }
.badge--red { background: linear-gradient(135deg, var(--r), var(--r-dark)); color: #fff; }

/* ---------- Event chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 5px; }
.chip {
  display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: .68rem; font-weight: 600;
  background: #f3f4f6; color: var(--ink-2); border: 1px solid var(--line);
}
.chip--red { background: #fef2f2; color: var(--r); border-color: #fecaca; }

/* ---------- Filters bar ---------- */
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: end; }
.filters .field { min-width: 150px; }
.filters input, .filters select { padding: 8px 11px; font-size: .82rem; }

/* ---------- Auth card ---------- */
.auth-wrap { max-width: 440px; margin: 56px auto; padding: 0 20px; }
.auth-card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); overflow: hidden; }
.auth-head { background: var(--grad); color: #fff; padding: 26px 28px; text-align: center; }
.auth-head img { width: 52px; height: 52px; margin-bottom: 10px; border-radius: 10px; background: #fff; padding: 4px; }
.auth-head h1 { margin: 0 0 4px; font-size: 1.2rem; font-weight: 800; }
.auth-head p { margin: 0; font-size: .8rem; opacity: .9; }
.auth-body { padding: 28px; }
.otp-box {
  width: 100%; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius);
  font-size: 1.5rem; font-weight: 800; text-align: center; letter-spacing: .45em; font-family: inherit;
}
.otp-box:focus { outline: none; border-color: var(--r); box-shadow: 0 0 0 3px rgba(225,6,0,.1); }
.countdown { font-size: .8rem; color: var(--muted); text-align: center; margin-top: 10px; }

/* ---------- Events page ---------- */
.sport-group { margin-bottom: 34px; }
.sport-group h3 {
  margin: 0 0 12px; font-size: 1.05rem; font-weight: 800; display: flex; align-items: center; gap: 10px;
}
.sport-group h3 .n {
  width: 26px; height: 26px; border-radius: 7px; background: var(--grad); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-size: .75rem; font-weight: 800;
}
table.events-table td .w { font-weight: 700; color: var(--r); }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #d1d5db; margin-top: 64px; font-size: .85rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 30px; padding: 44px 20px 34px; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { color: #fff; margin: 0 0 12px; font-size: .85rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 7px; }
.site-footer a { color: #9ca3af; }
.site-footer a:hover { color: #fff; }
.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.footer-brand img { border-radius: 8px; }
.footer-brand strong { display: block; color: #fff; font-size: .95rem; }
.footer-brand small { color: #9ca3af; font-size: .72rem; }
.footer-bottom { border-top: 1px solid #2d2d2d; padding: 16px 0; font-size: .75rem; color: #9ca3af; text-align: center; }

/* ---------- Pagination ---------- */
.pager { display: flex; gap: 6px; align-items: center; justify-content: center; padding: 18px 0 4px; flex-wrap: wrap; }
.pager a, .pager span {
  padding: 7px 13px; border-radius: 6px; border: 1px solid var(--line); font-size: .8rem; font-weight: 600; color: var(--ink-2);
}
.pager .current { background: var(--r); border-color: var(--r); color: #fff; }

/* ---------- Utilities ---------- */
.mt-0 { margin-top: 0; } .mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; }
.mb-0 { margin-bottom: 0; } .mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; } .mb-24 { margin-bottom: 24px; }
.text-muted { color: var(--muted); }
.text-center { text-align: center; }
.text-right { text-align: right; }
.small { font-size: .78rem; }
.w-100 { width: 100%; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.nowrap { white-space: nowrap; }
.empty { text-align: center; padding: 48px 20px; color: var(--muted); }
.empty b { display: block; color: var(--ink); font-size: 1.05rem; margin-bottom: 6px; }

@media (max-width: 720px) {
  .brand-text strong { font-size: .88rem; }
  .brand-text small { display: none; }
  .nav > a { padding: 7px 9px; font-size: .78rem; }
  .hero { padding: 44px 0 40px; }
  .section { padding: 40px 0; }
}

/* ============================================================
   PANEL LAYOUT (sidebar + topbar)
   ============================================================ */
.panel-page { background: var(--bg); }
.panel-shell { display: flex; min-height: 100vh; }

.sidebar {
  width: 256px; flex-shrink: 0; background: #141414; color: #d1d5db;
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
  border-right: 1px solid #262626;
}
.sidebar-brand {
  display: flex; align-items: center; gap: 11px; padding: 18px 18px 16px;
  border-bottom: 1px solid #262626; position: relative;
}
.sidebar-brand img { border-radius: 8px; background: #fff; padding: 3px; }
.sidebar-brand strong { display: block; color: #fff; font-size: .98rem; font-weight: 800; letter-spacing: -.01em; }
.sidebar-brand small { color: #8b8f98; font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.sidebar-close {
  display: none; position: absolute; right: 12px; top: 14px; background: none; border: none;
  color: #9ca3af; font-size: 1rem; cursor: pointer; padding: 4px 8px;
}
.side-nav { flex: 1; overflow-y: auto; padding: 10px 0 18px; }
.side-nav a {
  display: flex; align-items: center; gap: 11px; padding: 10.5px 20px;
  color: #9ca3af; font-weight: 600; font-size: .865rem; text-decoration: none !important;
  border-left: 3px solid transparent; transition: background .12s, color .12s;
}
.side-nav a:hover { background: #1e1e1e; color: #fff; }
.side-nav a.active {
  background: linear-gradient(90deg, rgba(225,6,0,.18), rgba(225,6,0,.04));
  color: #fff; border-left-color: var(--r);
}
.side-icon { width: 20px; text-align: center; font-size: .95rem; opacity: .9; }
.side-section {
  padding: 16px 20px 7px; font-size: .65rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: .12em; color: #5b6069;
}
.sidebar-foot { border-top: 1px solid #262626; padding: 10px; }
.side-logout {
  display: block; padding: 10px 14px; border-radius: 7px; color: #9ca3af !important;
  font-weight: 600; font-size: .84rem; text-decoration: none !important;
}
.side-logout:hover { background: #1e1e1e; color: #fff !important; }

.panel-main { flex: 1; display: flex; flex-direction: column; min-width: 0; background: var(--bg); }

.topbar {
  background: #fff; border-bottom: 1px solid var(--line); padding: 13px 26px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  position: sticky; top: 0; z-index: 40;
}
.topbar-left { display: flex; align-items: center; gap: 14px; min-width: 0; }
.topbar-left h1 { margin: 0; font-size: 1.12rem; font-weight: 800; letter-spacing: -.01em; }
.topbar-left p { margin: 1px 0 0; font-size: .78rem; color: var(--muted); }
.topbar-right { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.topbar-user { display: flex; align-items: center; gap: 10px; }
.topbar-user-meta { text-align: right; line-height: 1.25; }
.topbar-user-meta b { display: block; font-size: .82rem; font-weight: 700; }
.topbar-user-meta small { font-size: .68rem; color: var(--muted); }
.topbar-avatar {
  width: 38px; height: 38px; border-radius: 50%; background: var(--grad); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: .95rem;
}
.side-toggle {
  display: none; background: #fff; border: 1px solid var(--line); border-radius: 7px;
  padding: 7px 11px; font-size: 1rem; cursor: pointer; color: var(--ink);
}
.content-wrap { padding: 26px; max-width: 1320px; width: 100%; margin: 0 auto; }
.panel-footer {
  padding: 16px 26px; border-top: 1px solid var(--line); color: var(--muted);
  font-size: .74rem; text-align: center; background: #fff;
}
.panel-overlay {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 90;
}

/* quick action tiles */
.qa-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.qa-tile {
  display: flex; flex-direction: column; gap: 4px; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px; text-decoration: none !important; box-shadow: var(--shadow);
  transition: transform .12s, box-shadow .12s, border-color .12s;
}
.qa-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); border-color: #fca5a5; }
.qa-tile .qa-ic { font-size: 1.35rem; margin-bottom: 6px; }
.qa-tile b { color: var(--ink); font-size: .92rem; font-weight: 700; }
.qa-tile span { color: var(--muted); font-size: .76rem; }

/* settings form */
.set-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 22px; }
@media (max-width: 800px) { .set-grid { grid-template-columns: 1fr; } }
.set-row-full { grid-column: 1 / -1; }
.switch-row { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: #f9fafb; border: 1px solid var(--line); border-radius: var(--radius); }
.switch-row input { width: 18px; height: 18px; accent-color: var(--r); }
.switch-row label { font-weight: 700; font-size: .875rem; cursor: pointer; }
.switch-row .help { display: block; font-weight: 400; font-size: .74rem; color: var(--muted); }

@media (max-width: 980px) {
  .sidebar { position: fixed; left: -270px; top: 0; z-index: 100; transition: left .2s ease; height: 100vh; }
  .sidebar.open { left: 0; box-shadow: 8px 0 32px rgba(0,0,0,.35); }
  .sidebar-close { display: block; }
  .side-toggle { display: inline-flex; }
  .panel-overlay.show { display: block; }
  .content-wrap { padding: 18px 14px; }
  .topbar { padding: 12px 14px; }
  .topbar-user-meta { display: none; }
}

/* ============================================================
   PWA INSTALL BANNER
   ============================================================ */
.pwa-install {
  position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  z-index: 300; display: flex; align-items: center; gap: 12px;
  background: linear-gradient(135deg, #1a1a1a, #2b2b2b); color: #fff;
  border: 1px solid #3a3a3a; border-radius: 14px; padding: 12px 14px;
  box-shadow: 0 12px 40px rgba(0,0,0,.35); animation: pwaSlideUp .35s ease;
}
@keyframes pwaSlideUp { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }
.pwa-install-txt { flex: 1; font-size: .8rem; line-height: 1.4; color: #d1d5db; }
.pwa-install-txt b { display: block; color: #fff; font-size: .88rem; margin-bottom: 2px; }
.pwa-install-txt b + * { display: inline; }
.pwa-install-btn {
  background: var(--r); color: #fff; border: none; border-radius: 9px;
  padding: 10px 18px; font-weight: 800; font-size: .85rem; cursor: pointer; flex-shrink: 0;
}
.pwa-install-btn:hover { background: var(--r-hover); }
.pwa-install-x { background: none; border: none; color: #9ca3af; font-size: 1.4rem; cursor: pointer; padding: 0 4px; line-height: 1; }
.ios-share { display: inline-block; font-weight: 800; color: #fff; transform: translateY(2px); }
@media (max-width: 480px) {
  .pwa-install { flex-wrap: wrap; }
  .pwa-install-txt { flex: 1 1 100%; }
  .pwa-install-btn { flex: 1; }
}

/* ============================================================
   EVENT PICKER ï¿½ checkbox cards (mobile first)
   ============================================================ */
.ev-toolbar {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  flex-wrap: wrap; margin-bottom: 12px;
}
.ev-toolbar-title { font-size: .85rem; font-weight: 700; color: var(--ink); }
.ev-counter {
  display: inline-block; margin-left: 6px; background: #fef2f2; color: var(--r);
  border-radius: 999px; padding: 3px 10px; font-size: .74rem; font-weight: 800;
}
.ev-toolbar-actions { display: flex; gap: 6px; }
.ev-picker { display: grid; gap: 16px; }
.ev-group { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: #fafafa; }
.ev-group.is-hidden { display: none; }
.ev-group-h {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 9px 13px; background: #f3f4f6; border-bottom: 1px solid var(--line);
  font-size: .82rem; color: var(--ink);
}
.ev-group-h .ev-count { font-size: .7rem; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.ev-opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 8px; padding: 10px; }
.ev-opt {
  display: flex; align-items: center; gap: 10px; min-height: 48px;
  background: #fff; border: 1.5px solid var(--line); border-radius: 9px;
  padding: 9px 12px; cursor: pointer; transition: border-color .12s, background .12s, transform .06s;
  -webkit-tap-highlight-color: rgba(225,6,0,.15);
}
.ev-opt:hover { border-color: #fca5a5; }
.ev-opt:active { transform: scale(.99); }
.ev-opt input { width: 20px; height: 20px; accent-color: var(--r); flex-shrink: 0; margin: 0; cursor: pointer; }
.ev-opt-t { font-size: .82rem; font-weight: 600; line-height: 1.35; color: var(--ink); }
.ev-opt.is-checked { background: #fff1f1; border-color: var(--r); box-shadow: 0 0 0 1px rgba(225,6,0,.25); }
.ev-opt.is-checked .ev-opt-t { color: var(--r-dark); }
.ev-opt.is-hidden { display: none; }
.ev-opt input:disabled + .ev-opt-t { color: var(--muted); }
#eventsHint.error { color: var(--bad); font-weight: 700; }
@media (max-width: 640px) {
  .ev-opts { grid-template-columns: 1fr; padding: 8px; gap: 7px; }
  .ev-toolbar-actions .btn { min-height: 40px; }
}

/* ============================================================
   INLINE ROW FORMS (admin tables) ï¿½ desktop grid, mobile stack
   ============================================================ */
.row-form {
  display: grid; gap: 12px; align-items: end;
  border-bottom: 1px solid var(--line); padding: 16px 22px;
}
.row-form--users { grid-template-columns: 1.6fr 1fr .9fr 1.3fr .5fr auto; }
.row-form--districts { grid-template-columns: 2fr .6fr .8fr .8fr .6fr auto; }
.row-form--events { grid-template-columns: 1fr 1.2fr .8fr .8fr .5fr .5fr 1fr .5fr auto; gap: 8px; padding: 14px 22px; }
.row-form .actions { display: flex; gap: 6px; flex-wrap: wrap; }
@media (max-width: 1200px) {
  .row-form--events { grid-template-columns: repeat(4, 1fr); }
  .row-form--users { grid-template-columns: repeat(3, 1fr); }
  .row-form--districts { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 760px) {
  .row-form,
  .row-form--users, .row-form--districts, .row-form--events {
    grid-template-columns: 1fr !important; padding: 14px 14px; gap: 10px;
  }
  .row-form .field label { font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; }
  .row-form .actions .btn { flex: 1; min-height: 44px; font-size: .88rem; }
  .row-form .field > div:has(> input[type="checkbox"]) { padding-bottom: 4px !important; }
}

/* ============================================================
   MOBILE / TOUCH OVERRIDE ï¿½ highly responsive pass
   ============================================================ */
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { -webkit-font-smoothing: antialiased; overscroll-behavior-y: none; }

/* notch / safe areas */
.site-header { padding-top: env(safe-area-inset-top, 0px); }
.topbar { padding-top: calc(13px + env(safe-area-inset-top, 0px)); }
.content-wrap { padding-bottom: calc(26px + env(safe-area-inset-bottom, 0px)); }
.site-footer, .panel-footer { padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }

/* prevent iOS zoom on focus */
@media (max-width: 760px) {
  .field input, .field select, .field textarea, .otp-box, .filters input, .filters select {
    font-size: 16px !important;
  }
  /* bigger touch targets */
  .btn { min-height: 44px; padding-top: 11px; padding-bottom: 11px; }
  .btn--sm { min-height: 40px; }
  .btn--xs { min-height: 36px; padding: 7px 12px; }
  .nav > a { padding: 11px 10px; }
  .side-nav a { padding: 13px 20px; }
}

/* public header on small screens */
@media (max-width: 720px) {
  .header-inner { flex-wrap: wrap; gap: 8px; padding: 9px 14px; }
  .brand img { width: 42px; height: 42px; }
  .brand-text strong { font-size: .88rem; }
  .brand-text small { font-size: .64rem; }
  .nav { width: 100%; justify-content: flex-start; gap: 4px; order: 3; border-top: 1px solid var(--line); padding-top: 7px; }
  .nav > a { font-size: .82rem; padding: 9px 10px; }
  .nav .btn--sm { padding: 9px 14px; }
  .nav-user { flex-basis: 100%; text-align: left; padding: 4px 10px 6px; }
  .site-header { position: sticky; }

  .hero { padding: 44px 0 38px; }
  .hero h1 { font-size: clamp(1.6rem, 8vw, 2.2rem); }
  .hero p { font-size: .95rem; }
  .hero-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
  .hero-meta b { font-size: 1.1rem; }
  .hero .btn-row .btn { flex: 1 1 100%; }
  .section { padding: 38px 0; }
  .sec-head h2 { font-size: 1.35rem; }

  .btn-row .btn { flex: 1 1 auto; justify-content: center; }
  .auth-wrap { padding: 18px 14px calc(30px + env(safe-area-inset-bottom, 0px)); }
  .auth-card { border-radius: 14px; }
  .otp-box { letter-spacing: .3em; text-align: center; }

  .filters .field { min-width: calc(50% - 6px); flex: 1 1 calc(50% - 6px); }
  .filters .field:first-child { flex-basis: 100%; min-width: 100%; }
  .filters .btn { width: 100%; }

  .card, .panel { border-radius: 12px; }
  .panel-head { flex-wrap: wrap; gap: 8px; }
  .panel-body { padding: 14px; }
  .table-wrap { -webkit-overflow-scrolling: touch; margin: 0 -2px; }
  .data { font-size: .82rem; }
  .data th, .data td { padding: 9px 10px; }

  .grid { gap: 12px; }
  .stat-card { padding: 16px 14px; }
  .stat-card .num { font-size: 1.7rem; }

  .form-grid { gap: 13px; }
  fieldset.fs legend { font-size: .68rem; }

  footer .footer-grid { gap: 22px; }
}
@media (max-width: 400px) {
  .brand-text small { display: none; }
  .hero-meta { gap: 10px; }
  .filters .field { min-width: 100%; flex-basis: 100%; }
}

/* panel topbar on mobile */
@media (max-width: 980px) {
  .topbar-left h1 { font-size: .98rem; }
  .topbar-left p { font-size: .72rem; }
  .topbar-right { gap: 8px; }
  .topbar-right .badge { display: none; }
  .content-wrap { padding: 16px 12px; }
}
@media (max-width: 640px) {
  .topbar-left p { display: none; }
  .topbar-right .badge { display: inline-block; font-size: .62rem; padding: 4px 8px; }
}

/* hover-less devices: no transform surprises */
@media (hover: none) {
  .qa-tile:hover, .btn:hover { transform: none; }
  .btn:active { transform: scale(.98); }
  .qa-tile:active { transform: scale(.98); }
  .seg a:active { transform: scale(.97); }
  .side-nav a:active { background: #1e1e1e; color: #fff; }
  .ev-group-h:active { background: #e9ebee; }
  .st-btn:not(:disabled):active .st-num { transform: scale(.94); }
  .pill:active span { transform: scale(.99); }
}

/* desktop: wider event cards use space */
@media (min-width: 1100px) {
  .ev-opts { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
}

/* ---- phone input with +91 prefix ---- */
.phone-row { display: flex; gap: 8px; align-items: stretch; }
.phone-prefix {
  display: flex; align-items: center; padding: 0 13px;
  background: #f3f4f6; border: 1px solid var(--line); border-radius: var(--radius);
  font-weight: 800; font-size: .9rem; color: var(--ink); letter-spacing: .02em; user-select: none;
}
.phone-row input { flex: 1; min-width: 0; }

/* ---- card-like stat/quick tiles: consistent tap feel ---- */
.qa-tile, .ev-opt, .side-nav a, .pwa-install-btn { -webkit-tap-highlight-color: rgba(225,6,0,.18); }

/* ---- autofill: keep brand colors ---- */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #fff inset;
  -webkit-text-fill-color: var(--ink);
  caret-color: var(--ink);
}

/* ---- wide data tables on phones: sticky first column for context ---- */
@media (max-width: 760px) {
  .table-wrap { position: relative; }
  .data th:first-child, .data td:first-child {
    position: sticky; left: 0; z-index: 2;
    background: #fff; box-shadow: 1px 0 0 var(--line);
  }
  .data thead th:first-child { background: #f9fafb; z-index: 3; }
  .table-wrap::after {
    content: ""; position: absolute; top: 0; right: 0; bottom: 0; width: 26px;
    background: linear-gradient(90deg, rgba(255,255,255,0), rgba(255,255,255,.95));
    pointer-events: none; border-radius: 0 8px 8px 0;
  }
}

/* ============================================================
   MOBILE APP SHELL ï¿½ app bar, drawer, bottom tab bar
   ============================================================ */
.drawer-toggle { display: none; }
.nav-mobile-head, .nav-note { display: none; }
.drawer-overlay {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 115;
}
.tabbar { display: none; }

@media (max-width: 760px) {
  /* ---------- single-row app bar ---------- */
  .header-inner { flex-wrap: nowrap; justify-content: space-between; gap: 8px; padding: 8px 14px; }
  .brand { min-width: 0; gap: 10px; }
  .brand img { width: 38px; height: 38px; border-radius: 9px; }
  .brand-text { min-width: 0; }
  .brand-text strong {
    display: block; font-size: .92rem; white-space: nowrap; overflow: hidden;
    text-overflow: ellipsis; max-width: 56vw; letter-spacing: -.01em;
  }
  .brand-text small { display: none; }
  .drawer-toggle {
    display: flex; align-items: center; justify-content: center;
    width: 42px; height: 42px; flex-shrink: 0;
    background: #fff; border: 1px solid var(--line); border-radius: 11px;
    font-size: 1.1rem; color: var(--ink); cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .drawer-toggle:active { background: #f3f4f6; }

  /* ---------- nav becomes right-side drawer ---------- */
  .nav {
    position: fixed; top: 0; right: 0; z-index: 120;
    width: min(84vw, 320px); height: 100%;
    height: 100dvh;
    flex-direction: column; align-items: stretch; gap: 3px;
    background: #fff; border-left: 1px solid var(--line);
    padding: calc(14px + env(safe-area-inset-top, 0px)) 14px calc(20px + env(safe-area-inset-bottom, 0px));
    overflow-y: auto; box-shadow: -12px 0 44px rgba(0,0,0,.22);
    transform: translateX(108%); transition: transform .24s ease;
    border-top: none;
  }
  .nav.open { transform: translateX(0); }
  .nav-mobile-head {
    display: flex; align-items: center; justify-content: space-between;
    font-size: 1rem; font-weight: 800; color: var(--ink);
    padding: 4px 4px 12px; margin-bottom: 6px; border-bottom: 1px solid var(--line);
  }
  .nav-close {
    width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line);
    background: #fff; font-size: 1rem; color: var(--ink); cursor: pointer;
  }
  .nav > a {
    display: flex; align-items: center; min-height: 52px; padding: 0 12px;
    font-size: .95rem; border-radius: 11px; background: #f8f9fb;
    border-bottom: none !important; margin: 0;
  }
  .nav > a + a { margin-top: 2px; }
  .nav > a.active { background: #fff1f1; color: var(--r) !important; font-weight: 800; }
  .nav > a.btn { justify-content: center; margin-top: 10px; background: none; }
  .nav .btn--red { background: var(--grad) !important; color: #fff !important; min-height: 50px; font-size: .95rem; }
  .nav .btn--dark { background: var(--ink) !important; color: #fff !important; min-height: 50px; font-size: .95rem; }
  .nav-user { margin-left: 0 !important; color: var(--bad) !important; font-weight: 700; }
  .nav-note {
    display: block; font-size: .76rem; line-height: 1.55; color: var(--muted);
    padding: 12px 10px 4px;
  }
  .drawer-overlay.show { display: block; }
  body.nav-open { overflow: hidden; }

  /* ---------- bottom tab bar ---------- */
  .tabbar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 110;
    background: rgba(255,255,255,.94);
    -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    border-top: 1px solid var(--line);
    box-shadow: 0 -8px 30px rgba(16,24,40,.10);
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .tab {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 3px; min-height: 58px; padding: 8px 2px 7px;
    color: var(--muted); text-decoration: none !important;
    font-size: .6rem; font-weight: 800; letter-spacing: .03em; text-transform: uppercase;
    background: none; border: none; font-family: inherit; cursor: pointer;
    position: relative; -webkit-tap-highlight-color: transparent;
  }
  .tab-ic { font-size: 1.3rem; line-height: 1; font-weight: 400; }
  .tab.active { color: var(--r); }
  .tab.active::after {
    content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
    width: 36px; height: 3px; border-radius: 0 0 4px 4px; background: var(--r);
  }
  .tab:active { background: rgba(225,6,0,.06); }
  body { padding-bottom: calc(58px + env(safe-area-inset-bottom, 0px)); }
  .pwa-install { bottom: calc(66px + env(safe-area-inset-bottom, 0px)); }

  /* panel sidebar sits above tab bar */
  .sidebar { z-index: 125; }
  .panel-overlay { z-index: 118; }

  /* ---------- app-screen spacing ---------- */
  .container { padding: 0 14px; }
  .section { padding: 26px 0; }
  .sec-head { margin-bottom: 18px; }
  .sec-head h2 { font-size: 1.22rem; }
  .sec-eyebrow { font-size: .66rem; }
  main { overflow-x: hidden; }
}

/* ============================================================
   TABLES BECOME CARDS ON MOBILE (=760px)
   ============================================================ */
@media (max-width: 760px) {
  .table-wrap { overflow: visible; position: static; -webkit-overflow-scrolling: auto; }
  .table-wrap::after { display: none !important; }

  .data { display: block; width: 100%; border: none !important; }
  .data thead { display: none !important; }
  .data tbody { display: block; }

  .data tr {
    display: block; background: #fff;
    border: 1px solid var(--line); border-radius: 14px;
    padding: 13px 15px; margin-bottom: 11px;
    box-shadow: 0 1px 3px rgba(16,24,40,.06);
  }

  .data td {
    display: flex; justify-content: space-between; align-items: center;
    gap: 14px; position: static !important; box-shadow: none !important;
    width: auto !important; text-align: right !important;
    padding: 6px 0 !important; border: none !important;
    font-size: .85rem; line-height: 1.5; background: transparent !important;
    min-height: 0;
  }
  .data td + td { border-top: none !important; }
  .data td[data-label]::before {
    content: attr(data-label);
    flex: 0 0 auto; order: -1;
    font-size: .62rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
    color: var(--muted); background: #f1f2f4; border-radius: 6px; padding: 3px 8px; margin-top: 1px;
  }
  .data td:not([data-label])::before { content: none; }

  /* card title (first identity cell) */
  .data .c-title {
    display: block !important; text-align: left !important;
    font-size: 1.02rem; font-weight: 800; color: var(--ink); letter-spacing: -.01em;
    padding: 0 0 9px !important; margin-bottom: 7px;
    border-bottom: 1.5px solid #f1f2f4;
  }
  .data .c-title .cell-sub { font-weight: 500; font-size: .76rem; margin-top: 2px; }

  /* small kicker line above the title (reg no chips etc.) */
  .data .c-kicker {
    display: block !important; text-align: left !important;
    padding: 0 0 5px !important; font-size: .74rem;
  }

  /* action row at the bottom of the card */
  .data .c-actions {
    display: flex !important; justify-content: stretch !important; align-items: center;
    gap: 8px; padding: 11px 0 0 !important; margin-top: 9px;
    border-top: 1.5px solid #f1f2f4 !important;
  }
  .data .c-actions .actions { display: flex; gap: 8px; width: 100%; }
  .data .c-actions .actions .btn { flex: 1; min-height: 44px; font-size: .88rem; justify-content: center; }
  .data .c-actions form { flex: 1; display: flex; }
  .data .c-actions form .btn { flex: 1; min-height: 44px; }

  /* pair-style tables (label | value) */
  .data--pairs tr {
    padding: 4px 15px; border: none !important; box-shadow: none !important;
    background: transparent !important; margin-bottom: 0;
  }
  .data--pairs tbody { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 6px 0; }
  .data--pairs td:first-child {
    justify-content: flex-start !important; text-align: left !important;
    color: var(--muted); font-weight: 600; font-size: .8rem; padding: 8px 15px !important;
  }
  .data--pairs td:first-child::before { content: none !important; }
  .data--pairs td:not(:first-child) {
    justify-content: flex-end !important; font-weight: 800; color: var(--ink);
    padding: 8px 15px !important;
  }
  .data--pairs td + td { border-top: 1px dashed #eceef1 !important; }
  .data--pairs tr:first-child td:first-child { padding-top: 12px !important; }
  .data--pairs tr:last-child td:last-child { padding-bottom: 12px !important; }
}
@media (max-width: 760px) {
  .data td.cell-full {
    display: block !important; text-align: center !important;
    padding: 14px 4px 8px !important; color: var(--muted);
    font-size: .88rem; font-weight: 600;
  }
  .data td.cell-full::before { content: none !important; }
}

/* ============================================================
   APP-SCREEN POLISH (=760px) ï¿½ compact native-feeling screens
   ============================================================ */
@media (max-width: 760px) {
  .hero { padding: 32px 0 28px; }
  .hero h1 { font-size: 1.62rem; line-height: 1.18; letter-spacing: -.02em; }
  .hero p { font-size: .92rem; margin-bottom: 18px; }
  .hero-eyebrow { font-size: .66rem; letter-spacing: .1em; }
  .hero-meta { gap: 14px 20px; margin-bottom: 20px; }
  .hero-meta b { font-size: 1.05rem; }
  .hero-meta span { font-size: .66rem; }
  .hero .container > .hero-inner .btn { flex: 1 1 100%; }

  .stat-card { padding: 14px 14px; }
  .stat-card .num { font-size: 1.55rem; }
  .stat-card .label { font-size: .66rem; }

  .panel { border-radius: 12px; }
  .panel-head { padding: 13px 15px; flex-wrap: wrap; gap: 8px; }
  .panel-head h2, .panel-head h3 { font-size: .93rem; }
  .panel-body { padding: 15px; }

  .auth-wrap { margin: 24px auto; padding: 0 14px; }
  .auth-head { padding: 20px 16px; }
  .auth-head h1 { font-size: 1.08rem; }
  .auth-head img { width: 44px; height: 44px; }
  .auth-body { padding: 20px 16px; }

  .qa-tile { padding: 14px; }
  .qa-tile b { font-size: .87rem; }
  .qa-tile span { font-size: .71rem; }

  .sport-group { margin-bottom: 24px; }
  .sport-group h3 { font-size: .95rem; }
  .sport-group h3 .n { width: 26px; height: 26px; font-size: .78rem; flex-shrink: 0; }

  .alert { padding: 13px 14px; font-size: .83rem; border-radius: 12px; }
  .pager a, .pager span { min-width: 40px; min-height: 40px; display: inline-flex; align-items: center; justify-content: center; }

  .site-footer { margin-top: 40px; font-size: .78rem; text-align: center; padding: 22px 16px calc(30px + env(safe-area-inset-bottom, 0px)); }
  .site-footer h4 { text-align: center; }
  .site-footer ul { display: inline-block; text-align: left; }
  .panel-footer { font-size: .7rem; text-align: center; line-height: 1.5; }

  .page-title { font-size: 1.02rem; }
  .page-sub { font-size: .78rem; }
  .panel-topbar { padding: 10px 14px; flex-wrap: wrap; gap: 8px; }
  .btn--sm { min-height: 38px; }
}

/* ============================================================
   SEGMENTED TABS + QUOTA BARS
   ============================================================ */
.seg {
  display: flex; gap: 6px; background: #eceef1; padding: 5px;
  border-radius: 12px; margin-bottom: 20px; flex-wrap: wrap;
}
.seg a {
  flex: 1; min-width: 100px; text-align: center;
  padding: 11px 10px; border-radius: 9px;
  font-size: .84rem; font-weight: 700; color: var(--muted);
  text-decoration: none !important; transition: all .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.seg a.active { background: #fff; color: var(--r); box-shadow: var(--shadow); }
.seg a:not(.active):hover { color: var(--ink); }

.quota-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px 28px;
}
@media (max-width: 760px) { .quota-grid { grid-template-columns: 1fr; gap: 14px; } }

.quota { min-width: 0; }
.quota-row {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 10px; margin-bottom: 6px;
  font-size: .8rem; font-weight: 700; color: var(--ink-2);
}
.quota-row b { font-size: .82rem; color: var(--ink); white-space: nowrap; }
.bar {
  height: 9px; background: #eceef1; border-radius: 99px; overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(16,24,40,.06);
}
.bar > i {
  display: block; height: 100%; border-radius: 99px;
  background: var(--grad); transition: width .3s ease;
}
.bar.warn > i { background: linear-gradient(135deg, #f59e0b, #b45309); }
.bar.full > i { background: linear-gradient(135deg, #ef4444, var(--bad)); }
.quota-note {
  margin-top: 5px; font-size: .71rem; font-weight: 600; color: var(--muted);
}
.quota-note--full { color: var(--bad); font-weight: 800; }

/* ---------- app-only auth shell (login / OTP) â€” styles in NATIVE AUTH APP below ---------- */

/* ============================================================
   REGISTRATION WIZARD â€” stepper, steps, review, pills
   ============================================================ */
.reg-wrap { max-width: 880px; margin: 0 auto; }
.reg-card { box-shadow: var(--shadow-lg); }
.reg-head { align-items: flex-start; }
.reg-head h3 { font-size: 1.1rem; }
.reg-sub { margin: 4px 0 0; font-size: .78rem; color: var(--muted); }

/* ---------- stepper ---------- */
.stepper {
  list-style: none; display: flex; margin: 4px 0 6px; padding: 0;
  counter-reset: none;
}
.st { flex: 1; text-align: center; position: relative; }
.st::before {
  content: ""; position: absolute; top: 17px; right: 50%; width: 100%; height: 3px;
  background: #e8eaed; z-index: 0; transition: background .25s;
}
.st:first-child::before { content: none; }
.st.is-done::before, .st.is-active::before { background: var(--r); }
.st-btn {
  position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center;
  gap: 6px; width: 100%; padding: 0; background: none; border: none;
  font-family: inherit; cursor: default; -webkit-tap-highlight-color: transparent;
}
.st-btn:not(:disabled) { cursor: pointer; }
.st-num {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 50%;
  background: #fff; border: 3px solid #e8eaed;
  font-size: .85rem; font-weight: 800; color: var(--muted);
  transition: all .25s ease;
}
.st.is-active .st-num {
  background: var(--grad); border-color: var(--r); color: #fff;
  box-shadow: 0 4px 14px rgba(225, 6, 0, .35); transform: scale(1.08);
}
.st.is-done .st-num {
  background: #ecfdf5; border-color: var(--ok); color: var(--ok);
}
.st.is-done .st-num::before { content: "?"; font-size: .95rem; }
.st.is-done .st-num { font-size: 0; }
.st-lb {
  font-size: .68rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
  color: var(--muted);
}
.st.is-active .st-lb { color: var(--r); }
.st.is-done .st-lb { color: var(--ok); }
.stepper-bar {
  height: 4px; background: #eef0f2; border-radius: 99px; margin: 4px 8% 22px; overflow: hidden;
}
.stepper-bar > i {
  display: block; height: 100%; width: 0; border-radius: 99px;
  background: var(--grad); transition: width .3s ease;
}

/* ---------- step panels ---------- */
.step-panel { animation: stepIn .22s ease; }
html.js .step-panel { display: none; }
html.js .step-panel.is-active { display: block; }
@keyframes stepIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}
.step-head { margin-bottom: 18px; }
.step-head h4 { margin: 0 0 3px; font-size: 1.02rem; font-weight: 800; letter-spacing: -.01em; }
.step-head p { margin: 0; font-size: .82rem; color: var(--muted); }

.step-msg {
  margin-top: 14px; padding: 11px 14px; border-radius: 10px;
  background: #fef2f2; border: 1px solid #fecaca; color: var(--bad);
  font-size: .84rem; font-weight: 600;
}
.step-msg.shake { animation: shake .3s ease; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

/* ---------- gender pills ---------- */
.pill-group { display: flex; gap: 10px; }
.pill { flex: 1; position: relative; cursor: pointer; }
.pill input { position: absolute; opacity: 0; pointer-events: none; }
.pill span {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 10px 14px;
  background: #fff; border: 2px solid var(--line); border-radius: 12px;
  font-size: .92rem; font-weight: 700; color: var(--ink-2);
  transition: all .15s ease; text-align: center;
}
.pill input:checked + span {
  border-color: var(--r); background: #fff5f5; color: var(--r);
  box-shadow: 0 2px 10px rgba(225, 6, 0, .12);
}
.pill input:focus-visible + span { outline: 2px solid var(--r); outline-offset: 2px; }

/* ---------- +91 prefix ---------- */
.input-prefix {
  display: flex; align-items: stretch;
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  background: #fff;
}
.input-prefix > span {
  display: flex; align-items: center; padding: 0 12px;
  background: #f3f4f6; border-right: 1px solid var(--line);
  font-size: .88rem; font-weight: 700; color: var(--muted);
}
.input-prefix input { border: none !important; border-radius: 0; background: transparent; }
.input-prefix:focus-within { border-color: var(--r); }
.input-prefix input:focus { box-shadow: none; }

/* ---------- age live chip ---------- */
.age-live {
  display: inline-flex; margin-top: 6px;
}
.age-live.ok {
  background: #ecfdf5; color: var(--ok); border: 1px solid #bbf7d0;
  border-radius: 99px; padding: 4px 12px; font-weight: 700; font-size: .8rem;
}

/* ---------- quota embed in step ---------- */
.quota-embed {
  margin-top: 18px; padding: 14px 16px;
  background: #fafbfc; border: 1px solid var(--line); border-radius: 12px;
}
.quota-embed-h {
  font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 10px;
}
.quota-embed--info { font-size: .84rem; color: var(--ink-2); line-height: 1.55; }

/* ---------- event search ---------- */
.ev-search {
  flex: 1; min-width: 140px; min-height: 36px; padding: 6px 12px;
  font-size: .84rem; border: 1px solid var(--line); border-radius: 8px;
}
.ev-chev {
  margin-left: auto; color: var(--muted); font-size: .8rem;
  transition: transform .2s ease;
}
.ev-group.is-collapsed .ev-opts { display: none; }
.ev-group.is-collapsed .ev-chev { transform: rotate(-90deg); }
.ev-group-h { cursor: pointer; user-select: none; }

/* ---------- review ---------- */
.review {
  border: 1px solid var(--line); border-radius: 14px; overflow: hidden;
  background: #fff;
}
.review-h {
  padding: 11px 18px; background: #fafbfc; border-bottom: 1.5px solid var(--line);
  font-size: .72rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase;
  color: var(--muted);
  display: flex; justify-content: space-between; align-items: center;
}
.review-h button {
  background: none; border: none; color: var(--r); font-weight: 700;
  font-size: .78rem; cursor: pointer; font-family: inherit; text-transform: none; letter-spacing: 0;
}
.review-row {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  padding: 11px 18px; border-bottom: 1px dashed #eef0f2; font-size: .88rem;
}
.review-row:last-child { border-bottom: none; }
.review-row dt { color: var(--muted); font-weight: 600; flex-shrink: 0; }
.review-row dd { margin: 0; font-weight: 700; color: var(--ink); text-align: right; }
.review-row dd.empty { color: #c0c4c9; font-weight: 500; }
.review-ev { padding: 14px 18px; border-top: 1.5px solid var(--line); }
.review-ev-h {
  font-size: .72rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 10px;
  display: flex; justify-content: space-between; align-items: center;
}
.review-ev .chips { margin: 0; }
.review-empty { padding: 26px 18px; text-align: center; color: var(--muted); font-size: .86rem; }

/* ---------- form nav ---------- */
.form-nav {
  display: flex; align-items: center; gap: 10px;
  margin-top: 24px; padding-top: 20px; border-top: 1.5px solid #f1f2f4;
}
.form-nav-gap { flex: 1; }
.form-nav .btn { min-height: 48px; padding: 0 30px; font-size: .95rem; border-radius: 12px; }
.form-nav .btn[hidden] { display: none !important; }
.form-foot {
  margin: 14px 0 0; text-align: center; font-size: .76rem; color: var(--muted);
}
.form-foot a { color: var(--r); font-weight: 700; }

/* ---------- draft note ---------- */
.draft-note {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-bottom: 16px; padding: 10px 14px;
  background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 10px;
  font-size: .82rem; color: var(--blue); font-weight: 600;
}
.draft-note button {
  background: none; border: none; color: var(--bad); font-weight: 800;
  font-size: .8rem; cursor: pointer; font-family: inherit; white-space: nowrap;
}

/* ---------- mobile ---------- */
@media (max-width: 760px) {
  .reg-head { flex-wrap: wrap; gap: 8px; }
  .st-num { width: 32px; height: 32px; font-size: .78rem; border-width: 2.5px; }
  .st::before { top: 15px; }
  .st-lb { font-size: .56rem; letter-spacing: .03em; }
  .stepper-bar { margin: 4px 4% 18px; }
  .pill span { font-size: .84rem; min-height: 48px; padding: 8px 10px; }
  .ev-toolbar { flex-wrap: wrap; }
  .ev-search { order: 3; flex-basis: 100%; min-height: 42px; }
  .form-nav .btn { flex: 1; padding: 0 14px; }
  .form-nav-gap { display: none; }
  .review-row { flex-direction: column; gap: 2px; align-items: flex-start; padding: 10px 14px; }
  .review-row dd { text-align: left; font-size: .92rem; }
  .review-h, .review-ev { padding-left: 14px; padding-right: 14px; }
}

/* ============================================================
   NATIVE DESKTOP APP FRAME (>=981px) ï¿½ fixed chrome, scrolling workspace
   ============================================================ */
@media (min-width: 981px) {
  html, body { height: 100%; }
  body.panel-page { overflow: hidden; }
  body.panel-page .panel-shell { height: 100vh; height: 100dvh; }
  body.panel-page .sidebar { height: 100vh; height: 100dvh; }
  body.panel-page .panel-main { overflow-y: auto; overscroll-behavior-y: contain; }
  body.panel-page .content-wrap { padding: 28px 30px 48px; }
}

/* slim native scrollbars on desktop pointing devices */
@media (min-width: 981px) {
  body.panel-page .panel-main { scrollbar-width: thin; scrollbar-color: #c9ccd1 transparent; }
  body.panel-page .panel-main::-webkit-scrollbar { width: 10px; }
  body.panel-page .panel-main::-webkit-scrollbar-thumb { background: #c9ccd1; border-radius: 99px; border: 3px solid var(--bg); }
  body.panel-page .side-nav { scrollbar-width: thin; scrollbar-color: #3a3a3a transparent; }
  body.panel-page .side-nav::-webkit-scrollbar { width: 8px; }
  body.panel-page .side-nav::-webkit-scrollbar-thumb { background: #3a3a3a; border-radius: 99px; }
}

/* keyboard-first focus ring (desktop app feel, all pointers) */
:focus-visible { outline: 2px solid var(--r); outline-offset: 2px; border-radius: 6px; }
::selection { background: rgba(225, 6, 0, .16); }

/* desktop auth stage handled in NATIVE AUTH APP block */

/* reduced motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ============================================================
   NATIVE MOBILE APP BEHAVIORS (<=760px)
   ============================================================ */
@media (max-width: 760px) {
  body.auth-shell { padding-bottom: 0; }

  /* sticky bottom action bar (wizards + payment), docks above the tab bar */
  .form-nav {
    position: -webkit-sticky; position: sticky;
    bottom: calc(64px + env(safe-area-inset-bottom, 0px)); z-index: 60;
    margin: 22px -15px -15px;
    padding: 12px 15px calc(12px + env(safe-area-inset-bottom, 0px));
    background: rgba(255, 255, 255, .96);
    -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    border-top: 1px solid var(--line);
  }
  .form-nav .btn { min-height: 50px; font-size: .98rem; }
  .form-foot { padding-bottom: 6px; }

  /* auth sheet handled in NATIVE AUTH APP block */

  /* denser app feel for steps */
  .quota-embed { padding: 12px 14px; }
  .step-head { margin-bottom: 14px; }
}


/* ============================================================
   NATIVE AUTH APP — brand panel + form panel (login / OTP)
   ============================================================ */
.auth-shell { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: #f2f3f5; }
.auth-stage { flex: 1; display: flex; flex-direction: column; min-height: 0; }

/* ---- brand panel ---- */
.auth-brand {
  background: var(--grad);
  color: #fff;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; position: relative; overflow: hidden;
  padding: calc(30px + env(safe-area-inset-top, 0px)) 24px 30px;
}
.auth-brand::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(420px 260px at 18% -40px, rgba(255, 255, 255, .18), transparent 70%),
    radial-gradient(520px 320px at 92% 110%, rgba(0, 0, 0, .18), transparent 70%);
  pointer-events: none;
}
.auth-brand > * { position: relative; }
.auth-logo {
  width: 84px; height: 84px; border-radius: 22px;
  background: #fff; padding: 7px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, .28);
}
.auth-brand-text { margin-top: 16px; }
.auth-brand-text h1 { margin: 0; font-size: 1.55rem; font-weight: 800; letter-spacing: -.01em; }
.auth-brand-sub { margin: 6px 0 0; font-size: .84rem; font-weight: 600; color: rgba(255, 255, 255, .9); }
.auth-brand-meta { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 16px; }
.auth-chip {
  font-size: .68rem; font-weight: 700; letter-spacing: .02em;
  padding: 5px 11px; border-radius: 99px;
  background: rgba(255, 255, 255, .16); color: #fff;
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}

/* ---- form panel ---- */
.auth-main { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.auth-wrap { width: 100%; max-width: 460px; margin: 0 auto; padding: 0 16px; flex: 1; display: flex; flex-direction: column; justify-content: center; }
.auth-card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg); overflow: hidden; }
/* reset the legacy gradient header — the card head sits on white */
.auth-head { background: none; color: inherit; padding: 28px 28px 0; text-align: center; }
.auth-head h1 { margin: 0 0 5px; font-size: 1.28rem; font-weight: 800; letter-spacing: -.01em; }
.auth-head p { margin: 0; font-size: .84rem; color: var(--muted); font-weight: 500; }
.auth-body { padding: 20px 28px 28px; }
.auth-foot {
  margin: 22px 0 0; padding: 0 16px calc(18px + env(safe-area-inset-bottom, 0px));
  text-align: center; font-size: .74rem; color: #8a8f98;
}
/* roomier controls on auth screens (all sizes) */
.auth-shell .field input { min-height: 50px; font-size: .95rem; }
.auth-shell .field .help { font-size: .76rem; line-height: 1.5; }
.auth-shell .btn { min-height: 52px; font-size: .98rem; border-radius: 12px; }
.auth-shell .phone-prefix { min-height: 50px; font-size: .95rem; }

/* ---- mobile: compact splash + floating sign-in card ---- */
@media (max-width: 760px) {
  .auth-shell { background: var(--grad); }
  /* one continuous gradient: shell paints it, brand is transparent on top */
  .auth-brand { background: transparent; padding: calc(18px + env(safe-area-inset-top, 0px)) 20px 42px; }
  .auth-logo { width: 60px; height: 60px; border-radius: 16px; padding: 5px; }
  .auth-brand-text { margin-top: 12px; }
  .auth-brand-text h1 { font-size: 1.18rem; }
  .auth-brand-sub { font-size: .74rem; margin-top: 4px; }
  .auth-brand-meta { display: none; } /* chips clutter a login screen — desktop only */
  .auth-main { margin-top: -26px; padding-bottom: 4px; }
  .auth-wrap { max-width: none; padding: 0 14px; justify-content: flex-start; flex: 0 0 auto; }
  .auth-card {
    border: none; border-radius: 22px;
    box-shadow: 0 -10px 34px rgba(0, 0, 0, .16), 0 18px 50px rgba(0, 0, 0, .18);
  }
  .auth-card::before {
    content: ""; display: block; width: 40px; height: 4px; border-radius: 99px;
    background: #d8dce2; margin: 12px auto 0;
  }
  .auth-head { padding: 14px 22px 0; }
  .auth-head h1 { font-size: 1.16rem; }
  .auth-head p { font-size: .8rem; }
  .auth-body { padding: 16px 22px 24px; }
  .auth-foot {
    margin: auto 0 0; padding: 20px 16px calc(16px + env(safe-area-inset-bottom, 0px));
    color: rgba(255, 255, 255, .88); font-size: .72rem;
  }
  .auth-shell .field input, .auth-shell .otp-box { font-size: 16px; }
  .auth-shell .field input { min-height: 52px; }
  .auth-shell .btn { min-height: 52px; font-size: 1rem; border-radius: 13px; }
  .auth-shell .phone-prefix { min-height: 52px; border-radius: 13px; font-size: 1rem; padding: 0 14px; }
  .auth-shell .otp-box { letter-spacing: .3em; padding: 13px; }
}

/* ---- desktop: split-screen with an oversized sign-in card ---- */
@media (min-width: 761px) {
  .auth-stage { flex-direction: row; align-items: stretch; }
  .auth-brand {
    flex: 0 0 44%; max-width: 560px;
    padding: 56px;
  }
  .auth-logo { width: 112px; height: 112px; border-radius: 28px; padding: 8px; }
  .auth-brand-text h1 { font-size: 2rem; }
  .auth-brand-sub { font-size: 1rem; }
  .auth-brand-meta { margin-top: 22px; gap: 10px; }
  .auth-chip { font-size: .72rem; padding: 6px 13px; }
  .auth-main {
    flex: 1; align-items: center; justify-content: center;
    padding: 44px 32px;
  }
  .auth-wrap { flex: 0 1 auto; margin: 0; max-width: 520px; }
  .auth-card { border-radius: 20px; box-shadow: 0 28px 80px rgba(139, 0, 0, .16), var(--shadow-lg); }
  .auth-head { padding: 38px 42px 0; }
  .auth-head h1 { font-size: 1.6rem; }
  .auth-head p { font-size: .92rem; }
  .auth-body { padding: 26px 42px 38px; }
  .auth-shell .field input { min-height: 54px; font-size: 1rem; }
  .auth-shell .btn { min-height: 54px; font-size: 1.02rem; }
  .auth-shell .phone-prefix { min-height: 54px; font-size: 1rem; padding: 0 16px; }
  .auth-main { padding-bottom: 20px; }
}


/* ============================================================
   NATIVE DASHBOARD — admin home as an app screen
   ============================================================ */
.dash { display: flex; flex-direction: column; gap: 18px; }

/* hero card */
.dash-hero {
  position: relative; overflow: hidden;
  background: var(--grad); color: #fff;
  border-radius: 20px; padding: 22px 22px 18px;
  box-shadow: 0 14px 34px rgba(139, 0, 0, .22);
}
.dash-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 85% 15%, rgba(255,255,255,.12), transparent 55%);
  pointer-events: none;
}
.dash-hero > * { position: relative; }
.dash-hero-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.dash-greet {
  margin: 0; font-size: .74rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: rgba(255,255,255,.75);
}
.dash-hero h2 {
  margin: 7px 0 4px; font-size: 2rem; font-weight: 800;
  letter-spacing: -.02em; line-height: 1.08;
}
.dash-hero h2 span { font-size: .92rem; font-weight: 600; color: rgba(255,255,255,.85); }
.dash-hero-sub { margin: 0; font-size: .86rem; font-weight: 600; color: rgba(255,255,255,.88); }
.dash-status {
  flex-shrink: 0; display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 13px; border-radius: 999px;
  font-size: .7rem; font-weight: 800; letter-spacing: .06em;
  background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.32); color: #fff;
  backdrop-filter: blur(6px);
}
.dash-status::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #fff; }
.dash-status--open::before { box-shadow: 0 0 0 3px rgba(255,255,255,.28); }
.dash-status--closed { background: rgba(0,0,0,.25); }
.dash-hero-meta {
  display: flex; flex-wrap: wrap; gap: 8px 18px;
  margin-top: 16px; padding-top: 13px;
  border-top: 1px solid rgba(255,255,255,.22);
  font-size: .78rem; font-weight: 600; color: rgba(255,255,255,.92);
}

/* key-number tiles */
.dash-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.dash-stat {
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  padding: 15px; display: flex; flex-direction: column; gap: 10px;
  box-shadow: var(--shadow);
}
.dash-stat .num { font-size: 1.55rem; font-weight: 800; color: var(--ink); line-height: 1; }
.dash-stat .label {
  font-size: .68rem; font-weight: 700; color: var(--muted);
  text-transform: uppercase; letter-spacing: .06em;
}
.sq {
  width: 36px; height: 36px; border-radius: 11px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: .98rem; font-weight: 800; flex-shrink: 0;
}
.sq--red { background: #fef2f2; color: var(--r); }
.sq--amber { background: #fffbeb; color: var(--warn); }
.sq--green { background: #f0fdf4; color: var(--ok); }
.sq--blue { background: #eff6ff; color: var(--blue); }
.sq--violet { background: #f5f3ff; color: #6d28d9; }
.sq--slate { background: #f3f4f6; color: #475569; }

/* quick actions — app-shortcut tiles */
.dash-panel .panel-body { padding: 18px; }
.dash-qa { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.dash-qa .qa-tile {
  display: flex; flex-direction: column; align-items: flex-start; gap: 9px;
  padding: 15px; min-height: 118px; border-radius: 16px;
}
.qa-sq {
  width: 42px; height: 42px; border-radius: 13px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1.12rem; font-weight: 800;
  transition: transform .15s ease;
}
.qa-sq--red { background: linear-gradient(135deg, #fee2e2, #fecaca); color: var(--r); }
.qa-sq--amber { background: linear-gradient(135deg, #fef3c7, #fde68a); color: var(--warn); }
.qa-sq--green { background: linear-gradient(135deg, #dcfce7, #bbf7d0); color: var(--ok); }
.qa-sq--blue { background: linear-gradient(135deg, #dbeafe, #bfdbfe); color: var(--blue); }
.qa-sq--violet { background: linear-gradient(135deg, #ede9fe, #ddd6fe); color: #6d28d9; }
.qa-sq--slate { background: linear-gradient(135deg, #e5e7eb, #d1d5db); color: #374151; }
.dash-qa .qa-tile:hover .qa-sq { transform: scale(1.06) rotate(-3deg); }

/* two-up section (config + popular events) */
.dash-duo { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }

/* popular events ranked list */
.pop-list { list-style: none; margin: 0; padding: 0; }
.pop-list li {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 0; border-bottom: 1px dashed #eef0f2;
}
.pop-list li:last-child { border-bottom: none; padding-bottom: 0; }
.pop-list li:first-child { padding-top: 0; }
.pop-rank {
  width: 30px; height: 30px; border-radius: 10px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: #fef2f2; color: var(--r); font-weight: 800; font-size: .8rem;
}
.pop-list li:nth-child(1) .pop-rank { background: var(--grad); color: #fff; }
.pop-main { min-width: 0; flex: 1; }
.pop-main b { display: block; font-size: .88rem; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pop-main small { color: var(--muted); font-size: .74rem; }
.pop-n {
  flex-shrink: 0; margin-left: auto; font-weight: 800; font-size: .8rem;
  color: var(--r); background: #fef2f2; border-radius: 999px; padding: 4px 10px;
}

/* district rows with fill bars */
.dist-list { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; }
.dist-row {
  background: #fafbfc; border: 1px solid var(--line); border-radius: 14px;
  padding: 12px 14px;
}
.dist-row-h { display: flex; align-items: center; gap: 9px; }
.dist-name { font-size: .92rem; font-weight: 800; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dist-count {
  margin-left: auto; flex-shrink: 0; font-size: 1rem; font-weight: 800; color: var(--r);
}
.dist-sub { margin: 5px 0 9px; font-size: .74rem; font-weight: 600; color: var(--muted); }
.dist-bar { height: 7px; background: #e9ebee; border-radius: 999px; overflow: hidden; }
.dist-bar > i { display: block; height: 100%; background: var(--grad); border-radius: 999px; min-width: 4px; }

/* recent-players feed */
.feed-list { list-style: none; margin: 0; padding: 0; }
.feed-row {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 0; border-bottom: 1px dashed #eef0f2;
}
.feed-row:first-child { padding-top: 0; }
.feed-row:last-child { border-bottom: none; padding-bottom: 0; }
.feed-av {
  width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: #fef2f2; color: var(--r); font-weight: 800; font-size: .95rem;
}
.feed-main { flex: 1; min-width: 0; }
.feed-main b {
  display: block; font-size: .9rem; font-weight: 700; color: var(--ink);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.feed-main small { color: var(--muted); font-size: .74rem; }
.feed-side { flex-shrink: 0; text-align: right; }
.feed-time { margin-top: 3px; font-size: .68rem; color: var(--muted); white-space: nowrap; }
.dash-empty { margin: 0; padding: 12px 4px; color: var(--muted); font-size: .88rem; font-weight: 600; text-align: center; }

/* ---- mobile: native app screen ---- */
@media (max-width: 760px) {
  .dash { gap: 14px; }
  .dash-hero { border-radius: 18px; padding: 18px 16px 15px; }
  .dash-hero h2 { font-size: 1.68rem; margin-top: 5px; }
  .dash-hero h2 span { display: block; font-size: .8rem; margin-top: 2px; }
  .dash-hero-sub { font-size: .8rem; }
  .dash-status { padding: 5px 11px; font-size: .66rem; }
  .dash-hero-meta { gap: 6px 14px; margin-top: 13px; padding-top: 11px; font-size: .72rem; }

  .dash-stats { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .dash-stat { padding: 13px; border-radius: 14px; min-height: 98px; gap: 8px; }
  .dash-stat .num { font-size: 1.42rem; }
  .dash-stat .label { font-size: .64rem; }
  .sq { width: 33px; height: 33px; border-radius: 10px; font-size: .9rem; }

  .dash-panel .panel-body { padding: 14px; }
  .dash-qa { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .dash-qa .qa-tile { min-height: 108px; padding: 14px; border-radius: 15px; gap: 8px; }
  .qa-sq { width: 40px; height: 40px; border-radius: 12px; font-size: 1.05rem; }

  .dash-duo { grid-template-columns: 1fr; gap: 14px; }
  .dist-list { grid-template-columns: 1fr; gap: 8px; }

  .feed-av { width: 40px; height: 40px; font-size: .9rem; }
  .feed-main b { font-size: .88rem; }
  .pop-main b { font-size: .86rem; }
}

/* ---- desktop: calmer grid, roomier hero ---- */
@media (min-width: 761px) {
  .dash-hero { padding: 26px 28px 22px; }
  .dash-hero h2 { font-size: 2.2rem; }
}


/* ============================================================
   NATIVE ADMIN SCREENS — list/manage pages as app screens
   ============================================================ */
.lp { display: flex; flex-direction: column; gap: 16px; }

/* page summary strip */
.lp-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.lp-stat {
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  padding: 14px; display: flex; flex-direction: column; gap: 9px; box-shadow: var(--shadow);
}
.lp-stat .num { font-size: 1.45rem; font-weight: 800; color: var(--ink); line-height: 1; }
.lp-stat .num small { font-size: .8rem; font-weight: 700; color: var(--muted); }
.lp-stat .label { font-size: .66rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.lp-stat--ok .num { color: var(--ok); }
.lp-stat--bad .num { color: var(--bad); }
.lp-stat--warn .num { color: var(--warn); }

/* action row */
.lp-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.lp-actions .spacer { flex: 1; }

/* filter/search toolbar */
.lp-bar {
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  padding: 13px 15px; box-shadow: var(--shadow);
}
.lp-bar .filters { gap: 10px 12px; }
.lp-bar .filters .field { min-width: 130px; margin: 0; }
.lp-bar .filters .field label {
  display: block; margin-bottom: 4px;
  font-size: .64rem; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; color: var(--muted);
}
.lp-bar .filters input, .lp-bar .filters select {
  width: 100%; min-height: 42px; border-radius: 11px; border: 1px solid var(--line);
  background: #fafbfc; padding: 0 12px; font-size: .86rem; font-weight: 600; color: var(--ink);
}
.lp-bar .filters input:focus, .lp-bar .filters select:focus { background: #fff; border-color: #fca5a5; outline: none; }
.lp-bar .filters .btn { min-height: 42px; align-self: end; }

/* segmented control (status tabs etc.) */
.seg {
  display: inline-flex; gap: 2px; padding: 4px;
  background: #eef0f3; border-radius: 13px;
}
.seg a {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 15px; border-radius: 10px;
  font-size: .8rem; font-weight: 700; color: var(--muted); white-space: nowrap;
  transition: all .15s ease;
}
.seg a:hover { color: var(--ink); }
.seg a.active { background: #fff; color: var(--r); box-shadow: 0 1px 4px rgba(16,24,40,.12); }
.seg .seg-n { font-size: .68rem; opacity: .75; }

/* inline avatar in list cells */
.av-sm {
  width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: #fef2f2; color: var(--r); font-weight: 800; font-size: .74rem;
  margin-right: 8px; vertical-align: middle;
}
.cell-name-wrap { display: flex; align-items: center; gap: 0; min-width: 0; }

/* edit-card heads (row forms: districts / users / events) */
.rf-head {
  grid-column: 1 / -1; display: flex; align-items: center; gap: 10px;
  padding-bottom: 10px; margin-bottom: 2px;
  border-bottom: 1.5px dashed #eceef1;
}
.rf-head .rf-av {
  width: 38px; height: 38px; border-radius: 12px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--grad); color: #fff; font-weight: 800; font-size: .86rem;
}
.rf-head .rf-av--round { border-radius: 50%; }
.rf-head b { display: block; font-size: .92rem; font-weight: 800; color: var(--ink); }
.rf-head small { display: block; font-size: .72rem; color: var(--muted); font-weight: 600; }
.rf-head .rf-meta { flex: 1; min-width: 0; }
.rf-head .rf-pills { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.rf-pill {
  display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 999px;
  font-size: .68rem; font-weight: 800; background: #f3f4f6; color: var(--ink-2);
}
.rf-pill--red { background: #fef2f2; color: var(--r); }
.rf-pill--ok { background: #f0fdf4; color: var(--ok); }
.rf-pill--bad { background: #fef2f2; color: var(--bad); }

/* officials quota rows with mini bars */
.qta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; }
.qta-row { background: #fafbfc; border: 1px solid var(--line); border-radius: 14px; padding: 13px 14px; }
.qta-row-h { display: flex; align-items: center; gap: 9px; margin-bottom: 9px; }
.qta-row-h .dist-name { flex: 1; min-width: 0; }
.qta-bars { display: grid; grid-template-columns: 1fr 1fr; gap: 7px 14px; }
.qta-item { min-width: 0; }
.qta-item-l { display: flex; justify-content: space-between; font-size: .68rem; font-weight: 700; color: var(--muted); margin-bottom: 3px; }
.qta-item-l b { color: var(--ink); }
.qta-bar { height: 6px; background: #e9ebee; border-radius: 999px; overflow: hidden; }
.qta-bar > i { display: block; height: 100%; background: var(--grad); border-radius: 999px; min-width: 3px; }
.qta-bar.qta-bar--ok > i { background: linear-gradient(135deg, #22c55e, #15803d); }
.qta-bar.qta-bar--bad > i { background: linear-gradient(135deg, #ef4444, #b91c1c); }

/* settings: section chips + gateway blocks + save bar */
.set-nav { display: flex; gap: 8px; flex-wrap: wrap; }
.set-nav a {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 15px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--line);
  font-size: .8rem; font-weight: 700; color: var(--ink-2);
  box-shadow: var(--shadow); white-space: nowrap;
  transition: all .15s ease;
}
.set-nav a:hover, .set-nav a:focus { border-color: #fca5a5; color: var(--r); }
.set-nav .set-nav-ic { font-size: .92rem; }
.gw-block {
  border: 1px solid var(--line); border-left: 4px solid var(--r);
  border-radius: 14px; padding: 16px 16px 6px; margin-top: 16px;
  background: #fff;
}
.gw-block h4 { margin: 0 0 12px; font-size: .92rem; font-weight: 800; display: flex; align-items: center; gap: 8px; }
.gw-block h4 .sq { width: 30px; height: 30px; border-radius: 9px; font-size: .82rem; }
.set-savebar {
  position: sticky; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); z-index: 40;
  display: flex; gap: 10px;
  background: rgba(255,255,255,.92); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border: 1px solid var(--line); border-radius: 16px; padding: 12px;
  box-shadow: 0 10px 34px rgba(16,24,40,.14);
}
.set-savebar .btn { flex: 1; min-height: 48px; font-size: .95rem; }
.set-nav-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.set-nav-scroll::-webkit-scrollbar { display: none; }

/* desktop: table polish */
@media (min-width: 761px) {
  .lp-bar .filters input, .lp-bar .filters select { background: #fff; }
  .data tbody tr { transition: background .12s ease; }
  .data tbody tr:hover { background: #fafbfc; }
  .data tbody tr:nth-child(even) { background: #fcfcfd; }
  .data tbody tr:nth-child(even):hover { background: #f7f8fa; }
  table.data th { position: sticky; top: 0; background: #f8f9fb; z-index: 2; }
  .row-form { align-items: end; }
  .lp-actions .btn { min-height: 42px; }
}

/* mobile: native app screens */
@media (max-width: 760px) {
  .lp { gap: 13px; }

  .lp-stats { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .lp-stat { padding: 12px; border-radius: 14px; min-height: 84px; gap: 7px; }
  .lp-stat .num { font-size: 1.3rem; }
  .lp-stat .label { font-size: .62rem; }

  .lp-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
  .lp-actions .btn { width: 100%; min-height: 48px; }
  .lp-actions .btn:only-child { grid-column: 1 / -1; }
  .lp-actions .spacer { display: none; }

  .lp-bar { border-radius: 15px; padding: 12px; }
  .lp-bar .filters { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
  .lp-bar .filters .field { min-width: 0; }
  .lp-bar .filters .field:first-child { grid-column: 1 / -1; }
  .lp-bar .filters .field--full { grid-column: 1 / -1; }
  .lp-bar .filters input, .lp-bar .filters select { min-height: 48px; font-size: 16px; border-radius: 12px; }
  .lp-bar .filters .btn { grid-column: 1 / -1; width: 100%; min-height: 48px; }

  .seg { display: flex; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; width: 100%; }
  .seg::-webkit-scrollbar { display: none; }
  .seg a { flex: 1 0 auto; min-height: 40px; padding: 8px 14px; }

  .qta-grid { grid-template-columns: 1fr; gap: 8px; }
  .qta-bars { grid-template-columns: 1fr 1fr; }

  .rf-head { gap: 9px; }
  .rf-head .rf-av { width: 36px; height: 36px; border-radius: 11px; }
  .rf-head .rf-pills { flex: 0 0 auto; }

  .set-nav { flex-wrap: nowrap; padding-bottom: 2px; }
  .set-nav a { padding: 8px 13px; font-size: .76rem; }
  .gw-block { border-radius: 14px; padding: 14px 13px 4px; }
  .set-savebar { bottom: calc(66px + env(safe-area-inset-bottom, 0px)); border-radius: 15px; padding: 10px; }
}


/* ---- hide panel copyright on mobile only ---- */
@media (max-width: 760px) {
  .panel-footer { display: none !important; }
}


/* ---- games list on register-coach ---- */
.games-panel { margin-top: 16px; }
.games-chips { gap: 8px; }
.games-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 999px;
  background: #fef2f2; border: 1px solid #fecaca; color: var(--ink-2);
  font-size: .84rem; font-weight: 700;
}
.games-chip b {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px;
  background: var(--grad); color: #fff; font-size: .66rem; font-weight: 800;
}
@media (max-width: 760px) {
  .games-chip { font-size: .8rem; padding: 7px 12px; }
}


/* ============================================================
   SETTINGS PAGE — grouped sidebar + navy section cards
   (reference: eservices.bkwac.in/admin/settings)
   ============================================================ */
.crumb { display: inline-flex; align-items: center; gap: 7px; font-size: .78rem; font-weight: 600; color: var(--muted); }
.crumb a { color: var(--ink-2); text-decoration: none; transition: color .15s ease; }
.crumb a:hover { color: var(--r); }
.crumb i { font-style: normal; color: #c3cad6; }

.lp.st { gap: 16px; }
.st-shell { display: flex; gap: 18px; align-items: flex-start; }

.st-nav {
  width: 246px; flex: 0 0 246px; align-self: flex-start;
  position: sticky; top: 14px;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  padding: 10px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 2px;
}
.st-nav-grp {
  font-size: .63rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase;
  color: #97a2b4; padding: 15px 12px 7px;
}
.st-nav-grp:first-child { padding-top: 5px; }
.st-nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 13px; border-radius: 11px;
  font-size: .9rem; font-weight: 700; color: #344054;
  text-decoration: none; transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}
.st-nav-item:hover { background: #eef3fb; color: #0c3f92; }
.st-nav-item.active {
  background: linear-gradient(180deg, #0d439c 0%, #0a3274 100%);
  color: #fff; box-shadow: 0 8px 18px rgba(11, 61, 142, .30);
}
.st-nav-item.active:hover { color: #fff; }
.st-nav-ic { width: 22px; text-align: center; font-size: .98rem; flex: 0 0 22px; }

.st-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.st-card {
  display: none;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  overflow: hidden; box-shadow: var(--shadow);
}
.st-card--on { display: block; }
.st-card-head {
  display: flex; align-items: center; gap: 14px;
  padding: 19px 22px; color: #fff;
  background: linear-gradient(135deg, #0d439c 0%, #0a2f6e 100%);
}
.st-card-ic {
  width: 44px; height: 44px; flex: 0 0 44px;
  display: grid; place-items: center; font-size: 1.32rem;
  background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 12px;
}
.st-card-tt { min-width: 0; }
.st-card-tt h3 { margin: 0; font-size: 1.2rem; font-weight: 800; letter-spacing: -.01em; color: #fff; }
.st-card-tt p { margin: 3px 0 0; font-size: .82rem; font-weight: 500; color: #a8c3ee; }
.st-card-save {
  margin-left: auto; flex: 0 0 auto;
  background: #fff; color: #0a2f6e !important; border: none;
  padding: 9px 20px; border-radius: 10px; font-weight: 800; font-size: .87rem;
}
.st-card-save:hover { background: #e7eefb; transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0, 0, 0, .18); }
.st-card-body { padding: 22px; }

.st-sec {
  display: flex; align-items: center; gap: 9px;
  margin: 0 0 18px; padding-bottom: 11px;
  font-size: 1.02rem; font-weight: 800; color: #0d439c;
  border-bottom: 1px solid #e4e9f2;
}
.st-card-body .st-sec:not(:first-child) { margin-top: 28px; }
.st-sec-ic { font-size: 1rem; line-height: 1; }

.st-card .field label { font-size: .85rem; font-weight: 700; color: #1e293b; }
.st-card .field input, .st-card .field select, .st-card .field textarea {
  background: #fff; border: 1.5px solid #dce3ec; border-radius: 10px;
  padding: 11px 13px; min-height: 44px; font-size: .92rem; color: var(--ink);
}
.st-card .field textarea { min-height: 0; resize: vertical; }
.st-card .field input:focus, .st-card .field select:focus, .st-card .field textarea:focus {
  background: #fff; border-color: #0d439c; box-shadow: 0 0 0 3px rgba(13, 67, 156, .13);
}
.st-card .field .help { font-size: .76rem; color: #6b7a90; }
.st-card .set-grid { gap: 18px 24px; }

.st-card .switch-row { background: #f5f8fd; border-color: #dce6f5; }
.st-card .switch-row input { accent-color: #0d439c; }
.st-card .gw-block { background: #f8fafd; border: 1px solid #e2e8f2; border-left: 4px solid #0d439c; }
.st-card .gw-block h4 { color: #0a2f6e; }
.st-card .alert code { background: rgba(13, 67, 156, .07); }

.st-save-main { background: #0d439c; color: #fff !important; border: none; }
.st-save-main:hover { background: #0a3274; transform: translateY(-1px); box-shadow: 0 6px 16px rgba(11, 61, 142, .32); }

@media (max-width: 980px) {
  .st-shell { flex-direction: column; gap: 13px; }
  .st-nav {
    position: static; width: auto; flex: none; align-self: stretch;
    flex-direction: row; gap: 6px; padding: 8px;
    overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
  }
  .st-nav::-webkit-scrollbar { display: none; }
  .st-nav-grp { display: none; }
  .st-nav-item { white-space: nowrap; flex: 0 0 auto; padding: 9px 14px; font-size: .82rem; background: #fff; border: 1px solid var(--line); }
  .st-nav-item.active { border-color: transparent; }
}
@media (max-width: 760px) {
  .st-card-head { padding: 15px 14px; gap: 11px; flex-wrap: wrap; }
  .st-card-ic { width: 38px; height: 38px; flex-basis: 38px; font-size: 1.12rem; border-radius: 10px; }
  .st-card-tt h3 { font-size: 1.04rem; }
  .st-card-tt p { font-size: .75rem; }
  .st-card-save { padding: 8px 15px; min-height: 40px; }
  .st-card-body { padding: 15px 13px; }
  .st-sec { font-size: .95rem; margin-bottom: 15px; }
  .st-card .field input, .st-card .field select { min-height: 48px; font-size: 16px; border-radius: 12px; }
}