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

:root {
  --bg:         #07080f;
  --bg2:        #0d0f1c;
  --surface:    #111427;
  --surface2:   #161929;
  --surface3:   #1c2035;
  --border:     #252a45;
  --border2:    #333a60;
  --primary:    #7c3aed;
  --primary2:   #9d5bf4;
  --primary3:   #5b21b6;
  --cyan:       #06b6d4;
  --cyan2:      #22d3ee;
  --gold:       #f59e0b;
  --text:       #e2e8f0;
  --text-dim:   #94a3b8;
  --text-muted: #4a5568;
  --success:    #22c55e;
  --error:      #ef4444;
  --warning:    #f59e0b;
  --radius:     12px;
  --radius-sm:  8px;
  --sidebar-w:  240px;
  --nav-h:      64px;
  --glow-p:     0 0 24px rgba(124,58,237,.3), 0 0 48px rgba(124,58,237,.12);
  --glow-c:     0 0 24px rgba(6,182,212,.25), 0 0 48px rgba(6,182,212,.1);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font-family: inherit; }

/* ─── Scrollbar ────────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 3px; }

/* ─── Navbar ───────────────────────────────────────────────────────────────── */
.navbar {
  position: sticky; top: 0; z-index: 100;
  height: var(--nav-h);
  background: rgba(7,8,15,0.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center;
  padding: 0 28px;
  gap: 8px;
}
.nav-logo {
  font-size: 1.35rem; font-weight: 800;
  background: linear-gradient(135deg, #fff 20%, var(--cyan2) 60%, var(--primary2) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px; white-space: nowrap; margin-right: 16px;
}
.nav-logo span { -webkit-text-fill-color: var(--primary2); }
.nav-links {
  display: flex; align-items: center; gap: 2px; flex: 1;
  overflow-x: auto; scrollbar-width: none;
}
.nav-links::-webkit-scrollbar { display: none; }
.nav-links a {
  padding: 6px 14px; border-radius: var(--radius-sm);
  font-size: 0.875rem; color: var(--text-dim); white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}
.nav-links a:hover { background: var(--surface3); color: var(--text); }
.nav-links a.active {
  background: rgba(124,58,237,0.15);
  color: var(--primary2); font-weight: 500;
}

/* ─── Hero Banner ──────────────────────────────────────────────────────────── */
.hero {
  text-align: center;
  padding: 64px 24px 48px;
  background: radial-gradient(ellipse 80% 50% at 50% -10%, rgba(124,58,237,.18) 0%, transparent 70%);
  position: relative; overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 40% 30% at 80% 50%, rgba(6,182,212,.06) 0%, transparent 60%);
  pointer-events: none;
}
.hero-title {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 900; line-height: 1.1; margin-bottom: 14px;
  background: linear-gradient(135deg, #ffffff 0%, var(--cyan2) 40%, var(--primary2) 80%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-title span {
  background: linear-gradient(135deg, var(--cyan) 0%, var(--primary2) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-sub {
  color: var(--text-dim); font-size: 1.05rem; margin-bottom: 32px; max-width: 520px; margin-inline: auto;
}
.hero-search {
  display: flex; gap: 10px; max-width: 480px; margin: 0 auto 40px;
}
.hero-search input {
  flex: 1; padding: 12px 18px;
  background: var(--surface2); border: 1px solid var(--border2);
  border-radius: var(--radius); color: var(--text); font-size: 0.95rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.hero-search input:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.15);
}
.hero-search button {
  padding: 12px 22px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  color: #fff; border: none; border-radius: var(--radius);
  font-weight: 600; font-size: 0.9rem; cursor: pointer;
  transition: opacity 0.15s, transform 0.15s;
}
.hero-search button:hover { opacity: 0.88; transform: translateY(-1px); }

/* ─── Page Layout ──────────────────────────────────────────────────────────── */
.page { max-width: 1320px; margin: 0 auto; padding: 32px 24px; }
.page-header { display: flex; align-items: center; gap: 16px; margin-bottom: 28px; flex-wrap: wrap; }
.page-header h1 { font-size: 1.7rem; font-weight: 700; }

/* ─── Category Pills ───────────────────────────────────────────────────────── */
.category-filter {
  display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 32px;
}
.cat-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 16px; border-radius: 24px;
  background: var(--surface2); border: 1px solid var(--border);
  font-size: 0.85rem; color: var(--text-dim);
  transition: all 0.15s; cursor: pointer;
}
.cat-pill:hover { border-color: var(--primary); color: var(--text); }
.cat-pill.active {
  background: linear-gradient(135deg, var(--primary3), var(--primary));
  border-color: var(--primary); color: #fff;
  box-shadow: 0 4px 12px rgba(124,58,237,0.35);
}

/* ─── Games Grid ───────────────────────────────────────────────────────────── */
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px;
}
.games-empty {
  grid-column: 1/-1; text-align: center;
  padding: 80px 20px; color: var(--text-muted);
}
.games-empty .empty-icon { font-size: 3rem; margin-bottom: 16px; }
.games-empty p { font-size: 1.05rem; }

/* ─── Game Card ────────────────────────────────────────────────────────────── */
.game-card {
  display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  transition: transform 0.22s, border-color 0.22s, box-shadow 0.22s;
}
.game-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary);
  box-shadow: var(--glow-p);
}
.game-card-img {
  position: relative; aspect-ratio: 16/9;
  background: var(--surface2); overflow: hidden;
}
.game-card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.game-card:hover .game-card-img img { transform: scale(1.04); }
.game-card-no-thumb {
  width: 100%; height: 100%; display: flex;
  align-items: center; justify-content: center;
  font-size: 3rem; color: var(--text-muted);
  background: linear-gradient(135deg, var(--surface2), var(--surface3));
}
.game-card-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.2) 60%, transparent 100%);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity 0.22s;
}
.game-card:hover .game-card-overlay { opacity: 1; }
.play-btn {
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  color: #fff; padding: 11px 26px; border-radius: 28px;
  font-size: 0.95rem; font-weight: 700;
  box-shadow: 0 4px 20px rgba(124,58,237,0.5);
  transform: translateY(6px); transition: transform 0.22s;
}
.game-card:hover .play-btn { transform: translateY(0); }
.game-card-body { padding: 14px 16px; flex: 1; display: flex; flex-direction: column; gap: 8px; }
.cat-badge-sm {
  display: inline-flex; align-items: center;
  padding: 3px 10px; border-radius: 12px;
  font-size: 0.72rem; font-weight: 600; color: #fff;
  text-shadow: 0 1px 2px rgba(0,0,0,0.35);
}
.game-card-title { font-size: 1rem; font-weight: 600; line-height: 1.3; }
.game-card-desc { font-size: 0.82rem; color: var(--text-dim); line-height: 1.5; flex: 1; }

/* ─── Game Player ──────────────────────────────────────────────────────────── */
.player-page { padding: 24px; max-width: 1320px; margin: 0 auto; }
.player-container {
  position: relative; width: 100%; aspect-ratio: 16/9;
  background: #000; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--glow-p);
}
.game-iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: none; display: block; }
.player-loading {
  position: absolute; inset: 0; display: flex;
  align-items: center; justify-content: center;
  flex-direction: column; gap: 16px; color: var(--text-dim);
  background: var(--bg);
}
.spinner {
  width: 42px; height: 42px; border: 3px solid var(--border2);
  border-top-color: var(--primary2); border-radius: 50%;
  animation: spin 0.75s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.player-details { margin-top: 24px; }

.player-title-row {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 20px;
}
.player-title-left { display: flex; flex-direction: column; gap: 8px; }
.player-game-title { font-size: 1.6rem; font-weight: 800; line-height: 1.2; margin: 0; }
.player-title-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; flex-shrink: 0; }

.player-body {
  display: grid; grid-template-columns: 1fr 260px; gap: 20px; align-items: start;
}
.player-desc-col {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px;
}
.player-section-label {
  font-size: 0.72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--text-dim); margin: 0 0 12px;
}
.player-desc {
  color: var(--text-dim); font-size: 0.93rem; line-height: 1.75; margin: 0;
  white-space: pre-line;
}
.player-meta-col {}
.player-meta-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px;
  display: flex; flex-direction: column; gap: 0;
}
.player-meta-row {
  display: flex; flex-direction: column; gap: 3px;
  padding: 10px 0; border-bottom: 1px solid var(--border);
}
.player-meta-row:last-child { border-bottom: none; padding-bottom: 0; }
.player-meta-row:first-child { padding-top: 0; }
.meta-label {
  font-size: 0.7rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.07em; color: var(--text-dim);
}
.meta-value { font-size: 0.9rem; font-weight: 500; color: var(--text); }
.meta-link { color: var(--primary2); }
.meta-link:hover { color: var(--cyan); }
.btn-youtube {
  display: inline-flex; align-items: center; gap: 8px;
  background: #dc2626; color: #fff;
  padding: 10px 20px; border-radius: var(--radius-sm);
  font-size: 0.9rem; font-weight: 600;
  transition: background 0.15s, transform 0.15s;
}
.btn-youtube:hover { background: #b91c1c; transform: translateY(-1px); }

/* ─── Alerts ───────────────────────────────────────────────────────────────── */
.alert {
  padding: 13px 18px; border-radius: var(--radius-sm); margin-bottom: 18px;
  font-size: 0.9rem; display: flex; align-items: flex-start; gap: 8px;
}
.alert-success { background: rgba(34,197,94,0.08); border: 1px solid rgba(34,197,94,0.25); color: var(--success); }
.alert-error   { background: rgba(239,68,68,0.08);  border: 1px solid rgba(239,68,68,0.25);  color: var(--error); }
.alert-warning { background: rgba(245,158,11,0.08); border: 1px solid rgba(245,158,11,0.25); color: var(--warning); }

/* ─── Buttons ──────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 20px; border-radius: var(--radius-sm); border: none;
  font-size: 0.9rem; font-weight: 500; cursor: pointer;
  transition: all 0.15s; text-decoration: none; white-space: nowrap;
}
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  color: #fff; box-shadow: 0 2px 12px rgba(124,58,237,0.35);
}
.btn-primary:hover:not(:disabled) {
  box-shadow: 0 4px 20px rgba(124,58,237,0.55); transform: translateY(-1px);
}
.btn-danger   { background: #dc2626; color: #fff; }
.btn-danger:hover:not(:disabled) { background: #b91c1c; transform: translateY(-1px); }
.btn-ghost    { background: transparent; color: var(--text-dim); border: 1px solid var(--border); }
.btn-ghost:hover:not(:disabled) { border-color: var(--border2); color: var(--text); background: var(--surface2); }
.btn-sm   { padding: 6px 12px; font-size: 0.8rem; }
.btn-lg   { padding: 13px 30px; font-size: 1rem; font-weight: 600; }
.btn-block { width: 100%; }

/* ─── Badges ───────────────────────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center;
  padding: 4px 10px; border-radius: 20px;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
}
.badge-draft       { background: rgba(245,158,11,0.12); color: var(--warning); border: 1px solid rgba(245,158,11,0.3); }
.badge-published   { background: rgba(34,197,94,0.12);  color: var(--success); border: 1px solid rgba(34,197,94,0.3); }
.badge-unpublished { background: rgba(148,163,184,0.1); color: #64748b;        border: 1px solid rgba(148,163,184,0.2); }

/* ─── Card ─────────────────────────────────────────────────────────────────── */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.card-pad { padding: 24px; }

/* ─── Count Badge ──────────────────────────────────────────────────────────── */
.count-badge {
  background: var(--surface3); border: 1px solid var(--border);
  padding: 4px 12px; border-radius: 20px; font-size: 0.8rem; color: var(--text-dim);
}

/* ─── Game Modal ────────────────────────────────────────────────────────────── */
.game-modal {
  display: none;
  position: fixed; inset: 0; z-index: 9999;
  background: var(--bg);
  flex-direction: column;
}
.game-modal.open { display: flex; }
.game-modal-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 14px; flex-shrink: 0;
  background: var(--surface2);
  border-bottom: 1px solid var(--border2);
}
.game-modal-title {
  flex: 1; font-weight: 600; font-size: 0.9rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  color: var(--text);
}
.modal-close-btn {
  background: #ef4444; color: #fff; border: none;
  padding: 6px 14px; border-radius: 6px;
  cursor: pointer; font-size: 0.82rem; font-weight: 600;
  transition: opacity 0.15s;
}
.modal-close-btn:hover { opacity: 0.82; }

/* Scrollable content area */
.game-modal-scroll { flex: 1; overflow-y: auto; }

/* Game iframe fixed-height area */
.game-modal-frame-wrap {
  position: relative; width: 100%;
  aspect-ratio: 16/9; max-height: 70vh;
  background: #000; overflow: hidden;
}
.game-modal-frame-wrap iframe {
  position: absolute; inset: 0; width: 100%; height: 100%; border: none; display: block;
}

/* Details below game */
.game-modal-details {
  display: grid; grid-template-columns: 1fr 240px; gap: 24px;
  padding: 24px; max-width: 1320px; margin: 0 auto; width: 100%; box-sizing: border-box;
}
.modal-details-left {}
.modal-game-title { font-size: 1.5rem; font-weight: 800; margin: 8px 0 0; line-height: 1.2; }
.modal-detail-desc {
  color: var(--text-dim); font-size: 0.92rem; line-height: 1.75;
  margin: 0; white-space: pre-line;
}
.modal-details-right {}
.modal-meta-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px;
  display: flex; flex-direction: column;
}

/* ─── Footer ───────────────────────────────────────────────────────────────── */
.footer {
  margin-top: 80px; padding: 32px 24px;
  border-top: 1px solid var(--border);
  text-align: center; color: var(--text-muted); font-size: 0.85rem;
  background: var(--bg2);
}

/* ═══════════════════════════════════════════════════════════════════════════ */
/*  ADMIN PANEL                                                               */
/* ═══════════════════════════════════════════════════════════════════════════ */

.admin-wrap { display: flex; min-height: 100vh; }

/* ── Sidebar ─────────────────────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w); min-height: 100vh;
  background: var(--bg2); border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  position: sticky; top: 0; height: 100vh; overflow-y: auto; flex-shrink: 0;
}
.sidebar-logo {
  padding: 22px 20px 16px;
  font-size: 1.2rem; font-weight: 800;
  background: linear-gradient(135deg, var(--primary2), var(--cyan));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  border-bottom: 1px solid var(--border);
}
.sidebar-logo small {
  display: block; font-size: 0.68rem; font-weight: 400;
  color: var(--text-muted); margin-top: 2px;
  -webkit-text-fill-color: var(--text-muted);
}
.sidebar-nav { flex: 1; padding: 12px 8px; display: flex; flex-direction: column; gap: 2px; }
.sidebar-nav a {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: var(--radius-sm);
  color: var(--text-dim); font-size: 0.875rem;
  transition: background 0.15s, color 0.15s;
}
.sidebar-nav a:hover   { background: var(--surface3); color: var(--text); }
.sidebar-nav a.active  {
  background: rgba(124,58,237,0.15);
  color: var(--primary2); font-weight: 500;
  border-left: 2px solid var(--primary);
  padding-left: 12px;
}
.sidebar-nav .nav-icon { font-size: 1.05rem; width: 20px; text-align: center; }
.sidebar-section {
  padding: 8px 14px 4px;
  font-size: 0.68rem; font-weight: 600; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.1em; margin-top: 6px;
}
.sidebar-footer { padding: 14px 8px; border-top: 1px solid var(--border); }
.sidebar-user {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: var(--radius-sm);
}
.sidebar-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 700; color: #fff; flex-shrink: 0;
}
.sidebar-user-info { flex: 1; min-width: 0; }
.sidebar-user-name { font-size: 0.85rem; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user-role { font-size: 0.72rem; color: var(--text-muted); }
.sidebar-logout {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: var(--radius-sm);
  color: var(--error); font-size: 0.85rem; cursor: pointer;
  background: none; border: none; width: 100%;
  transition: background 0.15s;
}
.sidebar-logout:hover { background: rgba(239,68,68,0.08); }

/* ── Admin Main ──────────────────────────────────────────────────────────── */
.admin-main { flex: 1; min-width: 0; padding: 32px; background: var(--bg); }
.admin-page-header {
  display: flex; align-items: center; gap: 16px;
  margin-bottom: 28px; flex-wrap: wrap;
}
.admin-page-header h2 { font-size: 1.5rem; font-weight: 700; }
.header-actions { margin-left: auto; display: flex; gap: 10px; }

/* ── Stats Grid ──────────────────────────────────────────────────────────── */
.stats-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px; margin-bottom: 28px;
}
.stat-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 22px;
  display: flex; flex-direction: column; gap: 8px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.stat-card:hover { border-color: var(--primary); box-shadow: 0 4px 16px rgba(124,58,237,0.15); }
.stat-icon { font-size: 1.6rem; }
.stat-value {
  font-size: 2.2rem; font-weight: 800; line-height: 1;
  background: linear-gradient(135deg, var(--text) 0%, var(--primary2) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.stat-label { font-size: 0.78rem; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 500; }

/* ── Table ───────────────────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.data-table thead tr { border-bottom: 2px solid var(--border); }
.data-table th { padding: 10px 16px; text-align: left; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-muted); font-weight: 600; }
.data-table td { padding: 13px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.data-table tbody tr:hover { background: rgba(255,255,255,0.02); }
.data-table tbody tr:last-child td { border-bottom: none; }
.empty-row { text-align: center; color: var(--text-muted); padding: 56px !important; }

/* Game row */
.game-row { display: flex; align-items: center; gap: 12px; }
.game-thumb { width: 60px; height: 34px; object-fit: cover; border-radius: 4px; flex-shrink: 0; }
.game-row strong { display: block; font-size: 0.9rem; }
.game-slug { font-size: 0.75rem; color: var(--text-muted); }
.cat-badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 12px; font-size: 0.75rem; font-weight: 600; color: #fff; }
.action-btns { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }

/* ── Forms ───────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 7px; font-size: 0.875rem; color: var(--text-dim); font-weight: 500; }
.form-group input[type=text],
.form-group input[type=url],
.form-group input[type=password],
.form-group input[type=number],
.form-group select,
.form-group textarea {
  width: 100%; padding: 10px 14px;
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text); font-size: 0.9rem;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.12);
}
.form-group textarea { resize: vertical; }
.form-group small { display: block; margin-top: 5px; font-size: 0.78rem; color: var(--text-muted); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-actions { display: flex; gap: 12px; margin-top: 26px; }
.optional { font-size: 0.72rem; color: var(--text-muted); font-weight: 400; margin-left: 4px; }

/* Slug row */
.slug-row { display: flex; align-items: center; background: var(--surface2); border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.slug-row:focus-within { border-color: var(--primary); }
.slug-prefix { padding: 0 12px; color: var(--text-muted); font-size: 0.85rem; white-space: nowrap; border-right: 1px solid var(--border); height: 42px; display: flex; align-items: center; }
.slug-row input { border: none; background: transparent; flex: 1; border-radius: 0; }
.slug-row input:focus { outline: none; border: none; box-shadow: none; }

/* YouTube */
.yt-wrap { display: flex; align-items: center; background: var(--surface2); border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.yt-wrap:focus-within { border-color: #ef4444; }
.yt-icon { padding: 0 12px; color: #ef4444; font-size: 1.1rem; border-right: 1px solid var(--border); height: 42px; display: flex; align-items: center; }
.yt-wrap input { border: none; background: transparent; flex: 1; border-radius: 0; }
.yt-wrap input:focus { outline: none; border: none; box-shadow: none; }

/* File drop */
.file-drop {
  border: 2px dashed var(--border2); border-radius: var(--radius);
  padding: 28px 20px; text-align: center; cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  min-height: 120px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 6px;
}
.file-drop:hover { border-color: var(--primary); background: rgba(124,58,237,0.04); }
.file-drop.has-file { border-color: var(--success); background: rgba(34,197,94,0.04); }
.file-drop-icon { font-size: 2rem; }
.file-drop span { font-size: 0.9rem; color: var(--text-dim); }
.file-drop small { font-size: 0.78rem; color: var(--text-muted); }

/* Upload progress */
.upload-progress { margin: 20px 0; }
.progress-label { display: flex; justify-content: space-between; margin-bottom: 8px; font-size: 0.85rem; color: var(--text-dim); }
.progress-bar { height: 6px; background: var(--surface3); border-radius: 3px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--primary), var(--cyan)); border-radius: 3px; transition: width 0.3s; }

/* ── Admin Login ─────────────────────────────────────────────────────────── */
.login-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; background: var(--bg); }
.login-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 40px; width: 100%; max-width: 400px;
  position: relative; overflow: hidden;
}
.login-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--cyan));
}
.login-logo {
  font-size: 1.5rem; font-weight: 800; margin-bottom: 6px;
  background: linear-gradient(135deg, var(--text) 0%, var(--primary2) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.login-sub { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 30px; }

/* ── Recent List ─────────────────────────────────────────────────────────── */
.recent-list { display: flex; flex-direction: column; }
.recent-item { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.recent-item:last-child { border-bottom: none; }
.recent-thumb { width: 48px; height: 27px; object-fit: cover; border-radius: 4px; background: var(--surface3); flex-shrink: 0; }
.recent-info { flex: 1; min-width: 0; }
.recent-name { font-size: 0.9rem; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent-date { font-size: 0.75rem; color: var(--text-muted); }

/* ─── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .sidebar { display: none; }
  .admin-main { padding: 20px; }
  .form-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .games-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 14px; }
  .hero { padding: 40px 20px 32px; }
  .hero-title { font-size: 1.8rem; }
  .data-table th:nth-child(4), .data-table td:nth-child(4) { display: none; }
  .player-body { grid-template-columns: 1fr; }
  .player-title-row { flex-direction: column; }
  .player-title-actions { width: 100%; }
  .game-modal-details { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}
@media (max-width: 480px) {
  .page { padding: 16px; }
  .navbar { padding: 0 16px; }
  .admin-page-header { flex-direction: column; align-items: flex-start; }
  .header-actions { margin-left: 0; }
}
