/* ============================================================
   CSS custom properties — light / dark theming
   ============================================================ */
:root {
  --bg:            #ffffff;
  --bg-secondary:  #f5f7fa;
  --bg-card:       #ffffff;
  --text:          #1a1a2e;
  --text-muted:    #6b7280;
  --border:        #e5e7eb;
  --primary:       #2563eb;
  --primary-hover: #1d4ed8;
  --success:       #16a34a;
  --danger:        #dc2626;
  --warning:       #d97706;
  --info:          #0284c7;
  --shadow:        0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
  --radius:        8px;
  --nav-bg:        #1e3a5f;
  --nav-text:      #e2e8f0;
}

[data-theme="dark"] {
  --bg:            #0f172a;
  --bg-secondary:  #1e293b;
  --bg-card:       #1e293b;
  --text:          #e2e8f0;
  --text-muted:    #94a3b8;
  --border:        #334155;
  --primary:       #3b82f6;
  --primary-hover: #2563eb;
  --success:       #22c55e;
  --danger:        #ef4444;
  --warning:       #f59e0b;
  --info:          #38bdf8;
  --shadow:        0 1px 3px rgba(0,0,0,.4), 0 1px 2px rgba(0,0,0,.3);
  --nav-bg:        #0f172a;
  --nav-text:      #e2e8f0;
}

/* ============================================================
   Reset & Base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; height: auto; }

/* ============================================================
   Layout
   ============================================================ */
.container { width: 100%; max-width: 1100px; margin: 0 auto; padding: 0 1rem; }

.main-content { flex: 1; padding: 1.5rem 1rem; }

/* ============================================================
   Navbar
   ============================================================ */
.navbar {
  background: var(--nav-bg);
  color: var(--nav-text);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 4px rgba(0,0,0,.2);
}

.navbar-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  height: 56px;
}

.brand {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--nav-text);
  text-decoration: none;
  white-space: nowrap;
}
.brand:hover { text-decoration: none; color: #fff; }

.nav-links {
  display: flex;
  align-items: center;
  gap: .25rem;
  margin-left: auto;
  flex-wrap: nowrap;
}

.nav-links a, .nav-links .btn-link {
  color: var(--nav-text);
  opacity: .85;
  padding: .35rem .65rem;
  border-radius: 5px;
  font-size: .9rem;
  transition: opacity .15s, background .15s;
}
.nav-links a:hover, .nav-links .btn-link:hover { opacity: 1; background: rgba(255,255,255,.12); text-decoration: none; }
.nav-links a.active { opacity: 1; background: rgba(255,255,255,.18); font-weight: 600; }

.btn-icon {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.2rem;
  padding: .3rem;
  border-radius: 4px;
  color: var(--nav-text);
  transition: background .15s;
  line-height: 1;
}
.btn-icon:hover { background: rgba(255,255,255,.15); }

.hamburger {
  display: none;
  background: none;
  border: none;
  color: var(--nav-text);
  font-size: 1.4rem;
  cursor: pointer;
  padding: .3rem;
}

.mobile-menu {
  display: none;
  flex-direction: column;
  background: var(--nav-bg);
  padding: .5rem 1rem 1rem;
  gap: .25rem;
}
.mobile-menu a, .mobile-menu .btn-link {
  color: var(--nav-text);
  padding: .5rem;
  border-radius: 4px;
  font-size: 1rem;
}
.mobile-menu.open { display: flex; }

/* ============================================================
   Footer
   ============================================================ */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 1rem;
  text-align: center;
  color: var(--text-muted);
  font-size: .85rem;
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .3rem;
  padding: .5rem 1.1rem;
  border-radius: var(--radius);
  font-size: .95rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: background .15s, opacity .15s;
  text-decoration: none;
  line-height: 1.4;
}
.btn:hover { text-decoration: none; }

.btn-primary  { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); color: #fff; }
.btn-secondary { background: var(--bg-secondary); color: var(--text); border: 1px solid var(--border); }
.btn-secondary:hover { background: var(--border); }
.btn-success  { background: var(--success); color: #fff; }
.btn-link     { background: none; border: none; color: var(--primary); cursor: pointer; font-size: inherit; padding: 0; }
.btn-full     { width: 100%; }
.btn-sm       { padding: .3rem .7rem; font-size: .85rem; }

/* ============================================================
   Cards
   ============================================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow);
}
.card h3 { margin-bottom: .75rem; font-size: 1.1rem; }
.card h4 { margin: 1rem 0 .5rem; font-size: 1rem; }

/* ============================================================
   Flash messages
   ============================================================ */
.flash {
  padding: .75rem 1rem;
  border-radius: var(--radius);
  margin-bottom: 1rem;
  font-size: .95rem;
  border-left: 4px solid;
}
.flash-success { background: #dcfce7; color: #166534; border-color: var(--success); }
.flash-error   { background: #fee2e2; color: #991b1b; border-color: var(--danger); }
.flash-warning { background: #fef3c7; color: #92400e; border-color: var(--warning); }
.flash-info    { background: #e0f2fe; color: #075985; border-color: var(--info); }
[data-theme="dark"] .flash-success { background: #14532d; color: #86efac; }
[data-theme="dark"] .flash-error   { background: #7f1d1d; color: #fca5a5; }
[data-theme="dark"] .flash-warning { background: #78350f; color: #fcd34d; }
[data-theme="dark"] .flash-info    { background: #0c4a6e; color: #7dd3fc; }

/* ============================================================
   Forms
   ============================================================ */
.form-group { display: flex; flex-direction: column; gap: .3rem; }
.form-group label { font-size: .9rem; font-weight: 500; color: var(--text-muted); }
.form-group small  { color: var(--text-muted); font-size: .8rem; }

.form-row { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: .75rem; }
.form-row .form-group { flex: 1; min-width: 120px; }
.form-group-btn { justify-content: flex-end; align-items: flex-end; }

input[type="text"],
input[type="password"],
input[type="number"],
input[type="datetime-local"],
input[type="email"],
select,
textarea {
  width: 100%;
  padding: .5rem .75rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg);
  color: var(--text);
  font-size: .95rem;
  transition: border-color .15s;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(37,99,235,.2);
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: .5rem;
  cursor: pointer;
  font-size: .95rem;
}
.checkbox-label small { color: var(--text-muted); font-size: .8rem; }

.inline-form { display: flex; gap: .5rem; flex-wrap: wrap; align-items: flex-end; }
.inline-form input { flex: 1; min-width: 120px; }
.inline-form-small { display: flex; gap: .3rem; align-items: center; }

.help-text { font-size: .85rem; color: var(--text-muted); margin-top: .5rem; }

/* ============================================================
   Page header
   ============================================================ */
.page-header { margin-bottom: 1.25rem; }
.page-header h2 { font-size: 1.5rem; font-weight: 700; }
.back-link { color: var(--text-muted); font-size: .9rem; }
.subtitle { color: var(--text-muted); font-size: .95rem; margin-top: .25rem; }

/* ============================================================
   Tabs
   ============================================================ */
.tabs {
  display: flex;
  gap: .25rem;
  flex-wrap: wrap;
  border-bottom: 2px solid var(--border);
  margin-bottom: 1.25rem;
  padding-bottom: .25rem;
}
.tab {
  padding: .4rem .85rem;
  border-radius: 6px 6px 0 0;
  font-size: .9rem;
  color: var(--text-muted);
  transition: all .15s;
}
.tab:hover { background: var(--bg-secondary); text-decoration: none; color: var(--text); }
.tab.active { background: var(--primary); color: #fff; font-weight: 600; }

/* ============================================================
   Match cards
   ============================================================ */
.phase-section { margin-bottom: 2rem; }
.phase-title { font-size: 1rem; font-weight: 600; color: var(--text-muted); margin-bottom: .5rem; text-transform: uppercase; letter-spacing: .05em; }

.match-list { display: flex; flex-direction: column; gap: .5rem; }

.match-card {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  align-items: center;
  gap: .75rem;
  padding: .75rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text);
  transition: border-color .15s, box-shadow .15s;
}
.match-card:hover { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(37,99,235,.12); text-decoration: none; color: var(--text); }
.match-card.finished { border-left: 3px solid var(--success); }

.match-card-kickoff { font-size: .85rem; color: var(--text-muted); display: flex; align-items: center; gap: .3rem; }
.lock-icon { font-size: .85rem; }

.match-card-teams { display: flex; align-items: center; justify-content: center; gap: .75rem; font-weight: 500; }
.team { display: flex; align-items: center; gap: .3rem; }
.flag { border-radius: 2px; vertical-align: middle; display: inline-block; }
.flag-lg { border-radius: 3px; }

/* Placeholder for TBD / unknown team flags */
.flag-placeholder {
  display: inline-block;
  width: 20px;
  height: 15px;
  background: var(--border);
  border-radius: 2px;
  vertical-align: middle;
}
.flag-placeholder-lg {
  width: 40px;
  height: 30px;
  border-radius: 3px;
}
.vs { font-size: .9rem; color: var(--text-muted); font-weight: 400; }

.match-card-pred { text-align: right; min-width: 80px; }
.pred-badge { display: inline-flex; align-items: center; gap: .25rem; font-size: .9rem; font-weight: 600; padding: .2rem .5rem; border-radius: 4px; background: var(--bg-secondary); }
.pred-good { background: #dcfce7; color: #166534; }
.pred-bad  { background: #fee2e2; color: #991b1b; }
[data-theme="dark"] .pred-good { background: #14532d; color: #86efac; }
[data-theme="dark"] .pred-bad  { background: #7f1d1d; color: #fca5a5; }
.pred-missing { font-size: .85rem; color: var(--text-muted); }
.points-badge { font-size: .8rem; background: var(--primary); color: #fff; border-radius: 3px; padding: 0 .3rem; }
.joker-icon { font-size: .85rem; }

/* ============================================================
   Match detail
   ============================================================ */
.match-hero {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.25rem;
  text-align: center;
  box-shadow: var(--shadow);
}
.match-hero-phase { font-size: .85rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; margin-bottom: .5rem; }
.match-hero-teams {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: .75rem;
  width: 100%;
}
.hero-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .35rem;
  font-size: 1.1rem;
  font-weight: 600;
  word-break: break-word;
  text-align: center;
}
.hero-team:last-child { align-items: center; }
.hero-score { text-align: center; min-width: 90px; }
.final-score { font-size: 2.5rem; font-weight: 800; }
.final-label { font-size: .8rem; color: var(--text-muted); }
.kickoff-time { font-size: 1.1rem; font-weight: 600; display: block; }
.lock-status { font-size: .85rem; margin-top: .25rem; }
.lock-status.locked { color: var(--danger); }
.lock-status.open   { color: var(--success); }

/* ============================================================
   Prediction form — large, clear, accessible scoreboard layout
   ============================================================ */
.pred-form { display: flex; flex-direction: column; gap: 1rem; }

.pred-scoreboard {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 0;
  background: var(--bg-secondary);
  border: 2px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

.pred-team-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem .75rem .75rem;
  gap: .5rem;
}

.pred-team-name {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .95rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.3;
}

.goals-input {
  width: 100%;
  max-width: 110px;
  text-align: center;
  font-size: 2.8rem;
  font-weight: 800;
  padding: .5rem .25rem;
  border: 3px solid var(--primary);
  border-radius: 10px;
  background: var(--bg-card);
  color: var(--text);
  line-height: 1;
  /* Remove spinner arrows */
  -moz-appearance: textfield;
}
.goals-input::-webkit-outer-spin-button,
.goals-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.goals-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(59,130,246,.25);
  background: var(--bg-card);
}

/* Highlight when a value is entered */
.goals-input:not(:placeholder-shown) {
  border-color: var(--success);
  color: var(--text);
}

.pred-sep-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem .5rem;
  min-width: 44px;
}
.pred-sep-colon {
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--text-muted);
  line-height: 1;
  margin-top: 1.6rem; /* align with inputs */
}
.pred-sep-label {
  font-size: .7rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--text-muted);
  margin-top: .25rem;
}

.pred-hint {
  display: block;
  font-size: .78rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: .15rem;
}

/* Dark mode — stronger border on inputs */
[data-theme="dark"] .goals-input {
  border-color: #3b82f6;
  background: #0f172a;
}
[data-theme="dark"] .goals-input:not(:placeholder-shown) {
  border-color: #22c55e;
}
[data-theme="dark"] .pred-scoreboard {
  border-color: #334155;
  background: #1e293b;
}

/* Joker row */
.joker-row { padding: .65rem .9rem; background: var(--bg-secondary); border-radius: 8px; border: 1px solid var(--border); }
.joker-active { color: var(--warning); }
.joker-used   { color: var(--text-muted); font-size: .9rem; }

/* Submit button — full width, large */
.btn-predict {
  width: 100%;
  padding: .85rem;
  font-size: 1.1rem;
  font-weight: 700;
  border-radius: 10px;
  letter-spacing: .02em;
}

.pred-summary { display: flex; align-items: center; gap: 1rem; font-size: 1.1rem; }
.pred-score { font-size: 1.8rem; font-weight: 800; }
.points-big { font-size: 1.4rem; font-weight: 700; color: var(--primary); }

.joker-row { padding: .5rem .75rem; background: var(--bg-secondary); border-radius: 6px; border: 1px solid var(--border); }
.joker-active { color: var(--warning); }
.joker-used   { color: var(--text-muted); font-size: .9rem; }

.pred-summary { display: flex; align-items: center; gap: 1rem; font-size: 1.1rem; }
.pred-score { font-size: 1.8rem; font-weight: 800; }
.points-big { font-size: 1.4rem; font-weight: 700; color: var(--primary); }

/* Stats bars */
.stat-bars { display: flex; flex-direction: column; gap: .5rem; margin-bottom: 1rem; }
.stat-bar-row { display: grid; grid-template-columns: 140px 1fr 40px; align-items: center; gap: .5rem; }
.stat-label { font-size: .9rem; }
.stat-bar { background: var(--bg-secondary); border-radius: 20px; height: 14px; overflow: hidden; }
.stat-fill { height: 100%; border-radius: 20px; transition: width .3s; }
.stat-fill.home { background: var(--primary); }
.stat-fill.draw { background: var(--warning); }
.stat-fill.away { background: var(--danger); }
.stat-count { text-align: right; font-size: .85rem; color: var(--text-muted); }
.most-common { font-size: .95rem; color: var(--text-muted); }
.result-summary { display: flex; flex-direction: column; gap: .25rem; margin: .75rem 0; padding: .75rem; background: var(--bg-secondary); border-radius: 6px; }
.result-hit { font-weight: 600; }
.prophets { color: var(--text-muted); font-size: .9rem; }

/* Prediction table */
.pred-table-wrap { overflow-x: auto; }
.pred-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.pred-table th { background: var(--bg-secondary); padding: .5rem .75rem; text-align: left; font-weight: 600; border-bottom: 2px solid var(--border); }
.pred-table td { padding: .4rem .75rem; border-bottom: 1px solid var(--border); }

/* ============================================================
   Tables (general)
   ============================================================ */
.table-wrap { overflow-x: auto; }

.leaderboard-table, .admin-table, .pred-history-table, .rules-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .95rem;
}
.leaderboard-table th, .admin-table th, .pred-history-table th, .rules-table th {
  background: var(--bg-secondary);
  padding: .6rem .9rem;
  text-align: left;
  font-weight: 600;
  border-bottom: 2px solid var(--border);
  white-space: nowrap;
}
.leaderboard-table td, .admin-table td, .pred-history-table td, .rules-table td {
  padding: .55rem .9rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.row-good td { background: rgba(22,163,74,.08); }
.row-ok   td { background: rgba(37,99,235,.06); }
.row-bad  td { background: rgba(220,38,38,.08); }
.row-me   td { background: rgba(234,179,8,.08); font-weight: 600; }
.row-update td { background: rgba(234,179,8,.06); }
[data-theme="dark"] .row-good td { background: rgba(34,197,94,.1); }
[data-theme="dark"] .row-bad  td { background: rgba(239,68,68,.1); }
[data-theme="dark"] .row-me   td { background: rgba(250,204,21,.1); }

.rank-cell { text-align: center; font-size: 1.1rem; width: 40px; }
.points-cell { font-size: 1.1rem; }
.hide-sm { /* hidden on mobile, shown via media query below */ }
.player-link { color: var(--text); font-weight: 500; }
.player-link:hover { color: var(--primary); }
.you-tag { font-size: .8rem; color: var(--text-muted); font-weight: 400; }
.username-tag { font-size: .8rem; color: var(--text-muted); font-weight: 400; }
.settings-form { display: flex; flex-direction: column; gap: .9rem; max-width: 600px; }
.action-cell { white-space: nowrap; }

/* ============================================================
   Badges
   ============================================================ */
.badges-cell { white-space: nowrap; }
.badge-icon { font-size: 1.1rem; cursor: default; }
.badge-list { display: flex; flex-wrap: wrap; gap: .75rem; }
.badge-item { display: flex; align-items: center; gap: .5rem; padding: .5rem .75rem; background: var(--bg-secondary); border-radius: var(--radius); border: 1px solid var(--border); }
.badge-emoji { font-size: 1.5rem; }
.badge-info strong { display: block; font-size: .95rem; }
.badge-info small  { color: var(--text-muted); font-size: .8rem; }
.ranking-note { font-size: .85rem; color: var(--text-muted); margin-top: .75rem; }

/* League UI */
.league-banner {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: .5rem 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  font-size: .95rem;
}
.league-context-tag {
  font-size: .75rem;
  font-weight: 400;
  background: var(--primary);
  color: #fff;
  padding: .1rem .45rem;
  border-radius: 20px;
  vertical-align: middle;
  margin-left: .4rem;
}
.league-stat-tabs { display: flex; gap: .25rem; margin-bottom: .75rem; }
.tab-sm {
  padding: .25rem .65rem;
  font-size: .82rem;
  border-radius: 4px;
  color: var(--text-muted);
  border: 1px solid var(--border);
  transition: all .15s;
}
.tab-sm:hover { background: var(--bg-secondary); text-decoration: none; color: var(--text); }
.tab-sm.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.empty-league-card { text-align: center; padding: 2rem; }

/* Admin league management */
.league-card-header { display: flex; align-items: baseline; gap: .75rem; margin-bottom: .75rem; }
.league-card-header h3 { margin-bottom: 0; }
.member-list { display: flex; flex-direction: column; gap: .4rem; }
.member-row { display: flex; align-items: center; justify-content: space-between; padding: .35rem .5rem; background: var(--bg-secondary); border-radius: 5px; }
.admin-tag { background: var(--warning); color: #000; padding: .1rem .3rem; border-radius: 3px; font-size: .72rem; }
.league-tag { display: inline-block; background: var(--primary); color: #fff; font-size: .75rem; padding: .1rem .4rem; border-radius: 20px; margin: .1rem .1rem; }
.btn-danger-outline { border: 1px solid var(--danger); color: var(--danger); background: none; }
.btn-danger-outline:hover { background: var(--danger); color: #fff; }

/* Match visibility */
.bulk-actions { display: flex; gap: 1rem; flex-wrap: wrap; align-items: flex-end; margin-bottom: .5rem; }
.visibility-cell { width: 44px; text-align: center; }
.btn-visibility {
  background: none; border: none; cursor: pointer;
  font-size: 1.2rem; padding: .2rem; border-radius: 4px;
  transition: transform .1s;
}
.btn-visibility:hover { transform: scale(1.2); }
.vis-off { opacity: .35; }
.row-hidden td { opacity: .55; }

/* ============================================================
   Profile stats
   ============================================================ */
.profile-stats { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.stat-card { flex: 1; min-width: 100px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem; text-align: center; box-shadow: var(--shadow); }
.stat-value { font-size: 2rem; font-weight: 800; color: var(--primary); }
.stat-name  { font-size: .85rem; color: var(--text-muted); }

.phase-tag { display: inline-block; font-size: .75rem; color: var(--text-muted); margin-left: .25rem; }
.profile-meta { color: var(--text-muted); font-size: .9rem; }

/* ============================================================
   Rules page
   ============================================================ */
.rules-card { max-width: 780px; }
.rules-card p  { margin-bottom: .75rem; line-height: 1.7; }
.rules-card ol { padding-left: 1.5rem; }
.rules-card li { margin-bottom: .4rem; line-height: 1.7; }
.rule-note { font-size: .9rem; color: var(--text-muted); background: var(--bg-secondary); border-left: 3px solid var(--warning); padding: .5rem .75rem; border-radius: 0 4px 4px 0; margin-bottom: .75rem; }
.highlight-row td { font-weight: 700; background: rgba(37,99,235,.08); }
[data-theme="dark"] .highlight-row td { background: rgba(59,130,246,.15); }

/* ============================================================
   Login page
   ============================================================ */
.login-page { background: var(--bg-secondary); }
.login-wrapper { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.login-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 4px 24px rgba(0,0,0,.12); padding: 2rem; width: 100%; max-width: 380px; }
.login-header { text-align: center; margin-bottom: 1.5rem; }
.login-logo { font-size: 2.5rem; }
.login-header h1 { font-size: 1.4rem; margin: .5rem 0 .25rem; }
.login-header p { color: var(--text-muted); font-size: .9rem; }
.login-form { display: flex; flex-direction: column; gap: .9rem; margin-top: 1.25rem; }
.theme-toggle-login { position: fixed; top: 1rem; right: 1rem; }

/* ============================================================
   Admin forms
   ============================================================ */
.match-form { display: flex; flex-direction: column; gap: .75rem; }
.result-form { display: flex; flex-direction: column; gap: .75rem; margin-top: 1rem; }
.result-inputs { display: flex; align-items: center; gap: .75rem; }
.result-inputs .form-group { flex: 1; max-width: 120px; }
.match-hero-compact { margin-bottom: 1rem; line-height: 1.8; }
.current-result { padding: .5rem .75rem; background: var(--bg-secondary); border-radius: 6px; margin-bottom: .75rem; font-size: .95rem; }
.filter-card { padding: .75rem 1.25rem; }
.filter-form .form-row { margin-bottom: 0; }
.old-value { color: var(--text-muted); text-decoration: line-through; }
.create-tag { font-size: .8rem; background: var(--success); color: #fff; padding: .1rem .35rem; border-radius: 3px; font-weight: 600; }

/* ============================================================
   Empty state
   ============================================================ */
.empty-state { color: var(--text-muted); font-style: italic; text-align: center; padding: 2rem 0; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 680px) {
  .nav-links { display: none; }
  .hamburger { display: block; margin-left: auto; }

  .match-card {
    grid-template-columns: 80px 1fr;
    grid-template-rows: auto auto;
    gap: .35rem .5rem;
  }
  .match-card-kickoff { grid-column: 1; grid-row: 1; font-size: .8rem; }
  .match-card-teams   { grid-column: 2; grid-row: 1; }
  .match-card-pred    {
    grid-column: 2; grid-row: 2;
    text-align: right;
    display: block;
    font-size: .82rem;
    padding-bottom: .1rem;
  }

  .hide-sm { display: none; }
  .profile-stats .stat-card { min-width: 80px; }
  .stat-bar-row { grid-template-columns: 90px 1fr 30px; }
  .pred-inputs { flex-wrap: wrap; }
}
