/* HẢI TRÌNH DMOBIN 2026 — dashboard style (tham chiếu fintech dashboard).
   Màu theo logo Dmobin: cam lửa #FBAE17→#F1592A · xanh nước #2BA9E2/#1B75BC.
   Light mặc định, .dark trên <html> bật dark mode. */

:root {
  --font: 'Be Vietnam Pro', system-ui, -apple-system, sans-serif;
  --font-head: var(--font);
  --font-body: var(--font);

  --bg: #F3F5FA;
  --bg-2: #E9EDF5;
  --card: #FFFFFF;
  --text: #1B2A4A;
  --text-2: #5D6C8B;
  --text-3: #94A0B8;
  --line: #E7EBF3;
  --line-2: #D8DFEB;

  --orange: #F7941D;
  --orange-2: #F1592A;
  --blue: #2BA9E2;
  --blue-2: #1B75BC;
  --live: #17A673;
  --warn: #E5484D;

  --grad: linear-gradient(115deg, #FBAE17, #F1592A);
  --shadow-card: 0 6px 22px rgba(27, 42, 74, 0.06);
  --shadow-pop: 0 14px 34px rgba(27, 42, 74, 0.14);
  --shadow-orange: 0 8px 18px rgba(241, 89, 42, 0.28);
  --r: 16px;
}

.dark {
  --bg: #121419;
  --bg-2: #1A1D24;
  --card: #1C2028;
  --text: #F1F4F9;
  --text-2: #A8B0C2;
  --text-3: #667089;
  --line: #262B36;
  --line-2: #343B49;
  --blue-2: #55B9EC;
  --live: #3DD68C;
  --warn: #F2635F;
  --shadow-card: 0 6px 22px rgba(0, 0, 0, 0.28);
  --shadow-pop: 0 14px 34px rgba(0, 0, 0, 0.45);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.55;
  min-height: 100vh;
  transition: background 0.2s, color 0.2s;
}

::selection { background: rgba(247, 148, 29, 0.3); }
h1, h2, h3 { font-weight: 800; letter-spacing: -0.01em; }
a { color: inherit; text-decoration: none; }
button { font-family: var(--font); cursor: pointer; color: inherit; }

input, select, textarea {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--line-2);
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 13.5px;
  width: 100%;
  transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(247, 148, 29, 0.15);
}
select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%);
  background-position: calc(100% - 16px) 55%, calc(100% - 11px) 55%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
  padding-right: 32px;
}
label { font-size: 12px; color: var(--text-2); display: block; margin-bottom: 5px; font-weight: 500; }

/* ── Layout: sidebar + main ──────────────────────────────────────────────── */

.sidebar {
  position: fixed; inset: 0 auto 0 0; width: 236px; z-index: 50;
  background: var(--card);
  border-right: 1px solid var(--line);
  padding: 22px 14px 18px;
  display: none; flex-direction: column; gap: 3px;
}
@media (min-width: 1024px) { .sidebar { display: flex; } }

.side-logo { display: flex; align-items: center; gap: 10px; padding: 0 10px 20px; }
.logo-word { font-weight: 800; font-size: 16.5px; letter-spacing: 0.04em; }
.logo-word .b { color: var(--blue-2); }
.logo-word .o { color: var(--orange-2); }
.side-logo .sub { display: block; font-size: 10.5px; color: var(--text-3); font-weight: 600; letter-spacing: 0.08em; margin-top: -2px; }

.side-label {
  font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--text-3); font-weight: 700; padding: 10px 12px 7px;
}
.side-item {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 13px; border-radius: 12px;
  color: var(--text-2); font-size: 13.5px; font-weight: 600;
  transition: background 0.15s, color 0.15s;
}
.side-item svg { flex-shrink: 0; opacity: 0.85; }
.side-item:hover { background: var(--bg); color: var(--text); }
.side-item.active { background: var(--grad); color: #fff; box-shadow: var(--shadow-orange); }
.side-item.active svg { opacity: 1; }
.side-item .chev { margin-left: auto; opacity: 0; transition: opacity 0.15s; }
.side-item.active .chev { opacity: 0.9; }

.side-foot { margin-top: auto; padding: 12px; font-size: 11.5px; color: var(--text-3); line-height: 1.6; }

.app-main { min-width: 0; padding: 0 16px 108px; }
@media (min-width: 1024px) { .app-main { margin-left: 236px; padding: 0 30px 56px; } }
.main-inner { max-width: 1020px; margin: 0 auto; }

/* ── Topbar ──────────────────────────────────────────────────────────────── */

.topbar { display: flex; align-items: center; gap: 12px; padding: 16px 0 8px; }
.mobile-logo { display: flex; align-items: center; gap: 9px; }
@media (min-width: 1024px) { .mobile-logo { display: none; } }

.search { position: relative; flex: 1; max-width: 430px; display: none; }
@media (min-width: 900px) { .search { display: block; } }
.search > svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--text-3); pointer-events: none; }
.search input {
  background: var(--card); border-color: transparent;
  box-shadow: var(--shadow-card);
  padding-left: 40px; border-radius: 12px;
}
.search input:focus { border-color: var(--orange); }
.search-pop {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 60;
  background: var(--card); border: 1px solid var(--line);
  border-radius: 14px; box-shadow: var(--shadow-pop); overflow: hidden;
  padding: 6px;
}
.search-pop button {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 9px 11px; border: none; background: none; border-radius: 9px;
  font-size: 13px; color: var(--text-2); text-align: left; font-weight: 500;
}
.search-pop button:hover { background: var(--bg); color: var(--text); }
.search-pop .kind { margin-left: auto; font-size: 11px; color: var(--text-3); }

.tb-right { margin-left: auto; display: flex; gap: 9px; align-items: center; }
.tb-chip {
  display: none; font-size: 12px; font-weight: 600; color: var(--text-2);
  background: var(--card); box-shadow: var(--shadow-card);
  padding: 8px 14px; border-radius: 999px; white-space: nowrap;
}
@media (min-width: 720px) { .tb-chip { display: inline-flex; } }
.icon-btn {
  width: 36px; height: 36px; border-radius: 11px; border: none;
  background: var(--card); color: var(--text-2);
  box-shadow: var(--shadow-card);
  display: grid; place-items: center; font-size: 13px;
  transition: color 0.15s, transform 0.15s;
}
.icon-btn:hover { color: var(--orange-2); }

/* ── Page head ───────────────────────────────────────────────────────────── */

.page-head { margin: 18px 0 18px; }
.page-head h1 { font-size: clamp(21px, 3.4vw, 27px); }
.page-sub { color: var(--text-2); font-size: 13px; margin-top: 4px; }
.demo-line { font-size: 12px; color: var(--text-3); margin-top: 8px; }
.demo-line a { color: var(--orange-2); font-weight: 600; }
.back-link {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12.5px; font-weight: 600; color: var(--text-3); margin-top: 20px;
}
.back-link:hover { color: var(--orange-2); }

/* ── Cards ───────────────────────────────────────────────────────────────── */

.card {
  background: var(--card);
  border-radius: var(--r);
  box-shadow: var(--shadow-card);
  padding: 20px;
}
.card + .card { margin-top: 16px; }
/* card nằm cạnh nhau trong grid: bỏ margin xếp chồng để các khung cao bằng nhau */
.grid-2 > .card + .card,
.stat-cards > .card + .card,
.form-grid > .card + .card { margin-top: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2 { font-size: 15.5px; }
.card-head-extra { display: flex; gap: 10px; align-items: center; }
.kicker { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-3); font-weight: 700; margin-bottom: 3px; }

.empty-line { color: var(--text-3); font-size: 13px; padding: 14px 0; }
.hint { font-size: 12px; color: var(--text-3); margin-top: 6px; line-height: 1.55; }
.ok-line { font-size: 12.5px; color: var(--live); margin-top: 10px; font-weight: 600; }

.grid-2 { display: grid; gap: 16px; }
@media (min-width: 760px) { .grid-2 { grid-template-columns: 1fr 1fr; } }

/* ── Pills (tabs trong card) ─────────────────────────────────────────────── */

.pills { display: inline-flex; background: var(--bg); border-radius: 11px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.pills button {
  border: none; background: none; font-size: 12px; font-weight: 600;
  color: var(--text-2); padding: 6px 12px; border-radius: 8px; white-space: nowrap;
}
.pills button.active { background: var(--grad); color: #fff; box-shadow: 0 4px 10px rgba(241, 89, 42, 0.3); }

.admin-tabs { display: inline-flex; background: var(--card); box-shadow: var(--shadow-card); border-radius: 13px; padding: 4px; gap: 2px; margin: 16px 0 20px; flex-wrap: wrap; }
.admin-tabs button {
  border: none; background: none; font-size: 13px; font-weight: 600;
  color: var(--text-2); padding: 8px 15px; border-radius: 10px; white-space: nowrap;
}
.admin-tabs button.active { background: var(--grad); color: #fff; box-shadow: 0 4px 10px rgba(241, 89, 42, 0.3); }

/* ── Stat cards ──────────────────────────────────────────────────────────── */

.stat-cards { display: grid; gap: 14px; }
@media (min-width: 780px) { .stat-cards { grid-template-columns: 1.25fr 1fr 1fr; } }
.stat-label { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.stat-num { font-size: 26px; font-weight: 800; margin-top: 6px; letter-spacing: -0.02em; line-height: 1.15; }
.stat-num .unit { font-size: 14px; font-weight: 700; color: var(--text-3); margin-left: 3px; }
.stat-sub { font-size: 12px; color: var(--text-3); margin-top: 3px; }
.delta { color: var(--live); font-weight: 700; font-size: 12.5px; }
a.card { display: block; transition: transform 0.15s, box-shadow 0.15s; }
a.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-pop); }

.seg-bar { display: flex; height: 6px; border-radius: 99px; overflow: hidden; gap: 2px; margin-top: 14px; }
.seg-bar i { height: 100%; min-width: 3px; }
.seg-legend { display: flex; gap: 14px; margin-top: 10px; font-size: 11.5px; font-weight: 600; color: var(--text-2); flex-wrap: wrap; }
.seg-legend span { display: inline-flex; align-items: center; gap: 6px; }

.dot { display: inline-block; border-radius: 50%; flex-shrink: 0; }
.avatar { display: inline-grid; place-items: center; border-radius: 12px; font-weight: 800; flex-shrink: 0; }

/* ── Leaderboard rows ────────────────────────────────────────────────────── */

.board-row {
  display: grid; grid-template-columns: 32px 40px 1fr auto; gap: 12px; align-items: center;
  padding: 11px 10px 13px; border-radius: 13px; position: relative;
  transition: background 0.15s;
}
.board-row:hover { background: var(--bg); }
.rank-pill {
  width: 30px; height: 30px; border-radius: 10px;
  display: grid; place-items: center;
  font-weight: 800; font-size: 13px;
  background: var(--bg); color: var(--text-3);
}
.board-row:hover .rank-pill { background: var(--bg-2); }
.rank-pill.r1 { background: var(--grad); color: #fff; box-shadow: 0 4px 10px rgba(241, 89, 42, 0.3); }
.rank-pill.r2 { background: rgba(43, 169, 226, 0.16); color: var(--blue-2); }
.rank-pill.r3 { background: rgba(247, 148, 29, 0.16); color: #D97E12; }
.board-name { min-width: 0; }
.board-name .n { font-weight: 700; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.board-name .sub { font-size: 11.5px; color: var(--text-3); font-weight: 500; }
.board-pts { text-align: right; }
.board-pts .n { font-weight: 800; font-size: 15.5px; }
.board-pts .sub { font-size: 11px; color: var(--text-3); }
.row-bar { grid-column: 2 / -1; height: 4px; border-radius: 99px; background: var(--bg); overflow: hidden; }
.row-bar i { display: block; height: 100%; border-radius: 99px; }
.board-foot { font-size: 12px; color: var(--text-3); margin-top: 12px; line-height: 1.55; }

/* ── Status pill ─────────────────────────────────────────────────────────── */

.status {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11.5px; font-weight: 700; padding: 4px 11px; border-radius: 999px;
  white-space: nowrap;
}
.status i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.tone-live { color: #0E8A5F; background: rgba(23, 166, 115, 0.13); }
.tone-soon { color: var(--blue-2); background: rgba(43, 169, 226, 0.13); }
.tone-done { color: var(--text-3); background: var(--bg-2); }
.tone-warn { color: var(--warn); background: rgba(229, 72, 77, 0.12); }
.tone-muted { color: var(--text-3); background: var(--bg-2); }
.dark .tone-live { color: #3DD68C; }

/* ── Game cards ──────────────────────────────────────────────────────────── */

.stage-head { display: flex; align-items: baseline; gap: 10px; margin: 30px 0 12px; flex-wrap: wrap; }
.stage-head h2 { font-size: 15.5px; }
.stage-head .when { font-size: 12px; color: var(--text-3); font-weight: 500; }

.game-grid { display: grid; gap: 14px; }
@media (min-width: 640px) { .game-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .game-grid { grid-template-columns: 1fr 1fr 1fr; } }
.game-card {
  background: var(--card); border-radius: var(--r); box-shadow: var(--shadow-card);
  padding: 17px; display: flex; flex-direction: column; gap: 11px;
  transition: transform 0.15s, box-shadow 0.15s;
}
.game-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-pop); }
.gc-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.gc-icon { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; }
.gc-name { font-weight: 700; font-size: 14.5px; line-height: 1.3; }
.gc-loc { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.gc-foot { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 4px; }
.gc-max { font-size: 13px; font-weight: 800; }
.gc-max .u { font-size: 11px; color: var(--text-3); font-weight: 600; margin-left: 2px; }
.game-card.backup { opacity: 0.75; }

/* ── Detail pages ────────────────────────────────────────────────────────── */

.detail-head { margin: 12px 0 16px; }
.detail-kicker { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-3); font-weight: 700; }
.detail-head h1 { font-size: clamp(19px, 3.4vw, 25px); margin-top: 4px; line-height: 1.25; }
.detail-sub { color: var(--text-2); font-size: 12.5px; margin-top: 8px; display: flex; gap: 8px 14px; flex-wrap: wrap; align-items: center; font-weight: 500; }

.rule-list { list-style: none; }
.rule-list li { position: relative; padding: 5px 0 5px 20px; font-size: 13px; color: var(--text-2); }
.rule-list li::before { content: ''; position: absolute; left: 4px; top: 13px; width: 6px; height: 6px; border-radius: 50%; background: var(--blue); }
.rule-list.scoring li::before { background: var(--orange); }

.score-rows { display: flex; flex-direction: column; gap: 2px; }
.score-row { display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 11px; padding: 8px 6px; border-radius: 11px; }
.score-row:hover { background: var(--bg); }
.score-row .name { font-size: 13px; font-weight: 600; }
.score-row .pts { font-weight: 800; font-size: 13.5px; }
.score-row .bar { grid-column: 2 / 4; height: 4px; background: var(--bg); border-radius: 99px; overflow: hidden; }
.score-row .bar i { display: block; height: 100%; border-radius: 99px; }

.task-item { display: flex; gap: 13px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.task-item:last-child { border-bottom: none; padding-bottom: 4px; }
.task-no {
  width: 26px; height: 26px; border-radius: 9px; flex-shrink: 0;
  display: grid; place-items: center;
  background: var(--bg); color: var(--text-2); font-weight: 800; font-size: 12px;
}
.task-title { font-weight: 700; font-size: 13.5px; }
.task-title .tag { font-size: 11px; font-weight: 700; margin-left: 8px; }
.task-desc { font-size: 12.5px; color: var(--text-2); margin-top: 2px; }
.task-submit { font-size: 12px; color: var(--text-3); margin-top: 3px; }

/* ── Teams ───────────────────────────────────────────────────────────────── */

.team-grid { display: grid; gap: 14px; }
@media (min-width: 640px) { .team-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .team-grid { grid-template-columns: 1fr 1fr 1fr; } }
.team-card {
  background: var(--card); border-radius: var(--r); box-shadow: var(--shadow-card);
  padding: 17px; transition: transform 0.15s, box-shadow 0.15s;
  display: flex; flex-direction: column; gap: 12px;
}
.team-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-pop); }
.tc-top { display: flex; align-items: center; gap: 11px; }
.tc-name { font-weight: 700; font-size: 14.5px; }
.tc-sub { font-size: 12px; color: var(--text-3); }
.tc-foot { display: flex; align-items: center; justify-content: space-between; margin-top: auto; }
.tc-pts { font-weight: 800; font-size: 17px; }
.tc-pts .u { font-size: 11px; color: var(--text-3); font-weight: 600; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 600; color: var(--text-2);
  background: var(--bg); border-radius: 999px; padding: 6px 13px;
}
.chip.leader { background: rgba(247, 148, 29, 0.14); color: #C4720C; }
.dark .chip.leader { color: #FBAE17; }
.chip-wrap { display: flex; flex-wrap: wrap; gap: 8px; }

table.plain { width: 100%; border-collapse: collapse; font-size: 13px; }
table.plain th {
  text-align: left; font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-3); font-weight: 700; padding: 8px 8px 8px 0; border-bottom: 1px solid var(--line);
}
table.plain td { padding: 10px 8px 10px 0; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.plain tr:last-child td { border-bottom: none; }
table.plain .num { text-align: right; font-weight: 800; }
table.plain .dim { color: var(--text-3); font-weight: 500; }
table.plain a { font-weight: 600; }
table.plain a:hover { color: var(--orange-2); }
.mini-bar { height: 4px; background: var(--bg); border-radius: 99px; overflow: hidden; min-width: 56px; }
.mini-bar i { display: block; height: 100%; border-radius: 99px; }

/* ── Entry log ───────────────────────────────────────────────────────────── */

.entry-log { display: flex; flex-direction: column; }
.entry-row { display: flex; gap: 13px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13px; align-items: flex-start; }
.entry-row:last-child { border-bottom: none; }
.entry-row.voided .entry-note { text-decoration: line-through; color: var(--text-3); }
.entry-pts { font-weight: 800; min-width: 52px; font-size: 13px; }
.entry-pts.pos { color: var(--live); }
.entry-pts.neg { color: var(--warn); }
.entry-note { color: var(--text-2); font-weight: 500; }
.entry-meta { font-size: 11.5px; color: var(--text-3); margin-top: 2px; }
.void-reason { color: var(--warn); font-size: 11.5px; margin-top: 2px; font-weight: 600; }

/* ── Gallery ─────────────────────────────────────────────────────────────── */

.gallery-controls { display: flex; gap: 10px; margin: 4px 0 18px; flex-wrap: wrap; align-items: center; }
.gallery-controls select { width: auto; min-width: 150px; background: var(--card); border-color: transparent; box-shadow: var(--shadow-card); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
@media (min-width: 720px) { .photo-grid { grid-template-columns: repeat(auto-fill, minmax(185px, 1fr)); } }
.photo-cell { cursor: zoom-in; }
.photo-cell img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block;
  border-radius: 14px; box-shadow: var(--shadow-card);
  transition: transform 0.15s, box-shadow 0.15s;
}
.photo-cell:hover img { transform: translateY(-2px); box-shadow: var(--shadow-pop); }
.photo-cell .cap {
  font-size: 12px; color: var(--text-2); margin-top: 7px; font-weight: 500; line-height: 1.4;
  overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.photo-cell .meta { font-size: 11px; color: var(--text-3); margin-top: 2px; }
.photo-loading { aspect-ratio: 4 / 3; background: var(--bg-2); border-radius: 14px; }

.lightbox {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(10, 14, 22, 0.92);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 24px;
}
.lightbox img { max-width: min(94vw, 960px); max-height: 76vh; border-radius: 12px; object-fit: contain; }
.lightbox-cap { margin-top: 16px; text-align: center; max-width: 620px; color: #fff; }
.lightbox-cap .c-main { font-size: 14px; font-weight: 600; }
.lightbox-cap .c-sub { font-size: 12px; color: rgba(255, 255, 255, 0.55); margin-top: 3px; }
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 42px; height: 42px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.1); border: none; color: #fff; font-size: 17px;
}
.lightbox-nav:hover { background: rgba(255, 255, 255, 0.2); }
.lightbox-nav.prev { left: 14px; }
.lightbox-nav.next { right: 14px; }
.lightbox-close { position: absolute; top: 16px; right: 16px; background: rgba(255, 255, 255, 0.1); color: #fff; box-shadow: none; }

/* ── Buttons ─────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  border-radius: 11px; border: none;
  background: var(--card); color: var(--text);
  font-size: 13px; font-weight: 600; padding: 9px 16px;
  box-shadow: var(--shadow-card);
  transition: transform 0.15s, box-shadow 0.15s, color 0.15s, filter 0.15s;
}
.btn:hover { color: var(--orange-2); }
.btn.primary { background: var(--grad); color: #fff; box-shadow: var(--shadow-orange); }
.btn.primary:hover { color: #fff; filter: brightness(1.06); }
.btn.danger { color: var(--warn); }
.btn.danger:hover { color: var(--warn); filter: brightness(1.1); }
.btn.ghost { background: transparent; box-shadow: none; color: var(--text-2); }
.btn.ghost:hover { color: var(--orange-2); }
.btn.sm { font-size: 12px; padding: 6px 12px; border-radius: 9px; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }

/* ── Info boxes ──────────────────────────────────────────────────────────── */

.note-banner {
  font-size: 12.5px; color: var(--blue-2); font-weight: 500;
  background: rgba(43, 169, 226, 0.1); border-radius: 12px;
  padding: 11px 15px; margin: 14px 0 16px; line-height: 1.55;
}
.flag-box {
  font-size: 12.5px; color: var(--warn); font-weight: 500;
  background: rgba(229, 72, 77, 0.09); border-radius: 12px;
  padding: 10px 14px; margin-top: 10px;
  display: flex; gap: 10px; align-items: center; flex-wrap: wrap; line-height: 1.5;
}

/* ── Admin forms ─────────────────────────────────────────────────────────── */

.form-grid { display: grid; gap: 14px; }
@media (min-width: 640px) { .form-grid.cols-2f { grid-template-columns: 1fr 1fr; } .form-grid.cols-3f { grid-template-columns: 1fr 1fr 1fr; } }
.form-row { display: flex; flex-direction: column; }

.input-row {
  display: grid; grid-template-columns: minmax(110px, 1fr) auto; gap: 10px; align-items: center;
  padding: 8px 0; border-bottom: 1px solid var(--line);
}
.input-row:last-of-type { border-bottom: none; }
.input-row .who { display: flex; align-items: center; gap: 9px; min-width: 0; font-size: 13px; font-weight: 600; }
.input-row .who span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.input-row .fields { display: flex; gap: 8px; align-items: center; }
.input-row .fields label { margin: 0; font-size: 11px; white-space: nowrap; }
.input-row .calc { font-size: 12.5px; color: var(--text-3); min-width: 62px; text-align: right; font-weight: 700; }

.buzz-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
@media (min-width: 680px) { .buzz-grid { grid-template-columns: repeat(3, 1fr); } }
.buzz-team {
  border-radius: 12px; border: 1.5px solid var(--line-2); background: var(--bg);
  padding: 14px 10px; font-weight: 700; font-size: 13px;
  display: flex; align-items: center; justify-content: center; gap: 9px;
  transition: border-color 0.15s, background 0.15s;
}
.buzz-team.selected { border-color: var(--orange); background: rgba(247, 148, 29, 0.1); }
.buzz-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin-top: 14px; }
.buzz-actions .btn { padding: 13px 10px; background: var(--bg); box-shadow: none; }
.buzz-actions .btn.primary { background: var(--grad); box-shadow: var(--shadow-orange); }

/* ── Modal ───────────────────────────────────────────────────────────────── */

.modal-backdrop {
  position: fixed; inset: 0; z-index: 80;
  background: rgba(10, 14, 22, 0.55); backdrop-filter: blur(4px);
  display: flex; align-items: flex-end; justify-content: center;
}
@media (min-width: 640px) { .modal-backdrop { align-items: center; padding: 24px; } }
.modal {
  background: var(--card);
  border-radius: 18px 18px 0 0; width: 100%; max-width: 480px;
  max-height: 88vh; display: flex; flex-direction: column;
  box-shadow: var(--shadow-pop);
}
@media (min-width: 640px) { .modal { border-radius: 18px; } }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 12px; }
.modal-head h3 { font-size: 15.5px; }
.modal-body { padding: 4px 20px 20px; overflow-y: auto; }

/* ── Mobile bottom nav ───────────────────────────────────────────────────── */

.nav-mobile {
  position: fixed; bottom: 12px; left: 12px; right: 12px; z-index: 50;
  display: flex; justify-content: space-around;
  background: var(--card); border-radius: 18px;
  box-shadow: var(--shadow-pop);
  padding: 9px 4px calc(9px + env(safe-area-inset-bottom) / 2);
}
@media (min-width: 1024px) { .nav-mobile { display: none; } }
.nav-mobile a {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  font-size: 10.5px; font-weight: 600; color: var(--text-3); padding: 3px 10px;
  border-radius: 10px;
}
.nav-mobile a.active { color: var(--orange-2); }

/* ── Print ───────────────────────────────────────────────────────────────── */

@media print {
  body { background: #fff; color: #111; }
  .sidebar, .nav-mobile, .topbar, .no-print { display: none !important; }
  .app-main { margin: 0; padding: 0; }
  .card, .game-card, .team-card { box-shadow: none; border: 1px solid #ddd; }
}

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(120, 130, 150, 0.3); border-radius: 99px; }
::-webkit-scrollbar-track { background: transparent; }
