/* ==========================================================
   AbuXay Football League — Luxury Black & Gold Admin Dashboard
   ========================================================== */

:root {
  --admin-bg: #07080c;
  --admin-sidebar: #0d0f17;
  --admin-card: rgba(18, 21, 31, 0.85);
  --admin-card-hover: rgba(25, 30, 45, 0.95);
  --admin-border: rgba(212, 175, 55, 0.22);
  --admin-border-subtle: rgba(255, 255, 255, 0.08);

  --gold-primary: #d4af37;
  --gold-secondary: #f39c12;
  --gold-light: #fbe285;
  --gold-gradient: linear-gradient(135deg, #fce074 0%, #dfb235 50%, #a47c1a 100%);
  --gold-glow: 0 0 20px rgba(212, 175, 55, 0.25);

  --accent-green: #10b981;
  --accent-red: #ef4444;
  --accent-blue: #3b82f6;

  --text-primary: #ffffff;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --transition: all 0.25s ease;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Outfit', 'Inter', -apple-system, sans-serif;
  background-color: var(--admin-bg);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
}

/* ================= LOGIN SCREEN ================= */
.login-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(circle at center, #151824 0%, #06070a 100%);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.login-card {
  width: 100%;
  max-width: 420px;
  background: var(--admin-card);
  border: 1px solid var(--admin-border);
  border-radius: var(--radius-lg);
  padding: 36px 30px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.9), var(--gold-glow);
  text-align: center;
}

.login-logo {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 2px solid var(--gold-primary);
  box-shadow: 0 0 15px rgba(212, 175, 55, 0.5);
  margin-bottom: 16px;
  object-fit: cover;
}

.login-card h2 {
  font-size: 1.5rem;
  font-weight: 800;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 6px;
}

.login-card p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

/* ================= SIDEBAR ================= */
.admin-sidebar {
  width: 260px;
  background: var(--admin-sidebar);
  border-right: 1px solid var(--admin-border-subtle);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; bottom: 0; left: 0;
  z-index: 100;
}

.sidebar-header {
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--admin-border-subtle);
}

.sidebar-logo {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--gold-primary);
  object-fit: cover;
}

.sidebar-header h3 {
  font-size: 1.05rem;
  font-weight: 800;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.sidebar-nav {
  padding: 16px 12px;
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.nav-link:hover {
  background: rgba(212, 175, 55, 0.1);
  color: #fff;
}

.nav-link.active {
  background: var(--gold-gradient);
  color: #0b0c10;
  font-weight: 800;
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.3);
}

.sidebar-footer {
  padding: 16px;
  border-top: 1px solid var(--admin-border-subtle);
}

/* ================= MAIN CONTENT ================= */
.admin-main {
  margin-left: 260px;
  flex: 1;
  padding: 24px 32px;
  min-height: 100vh;
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--admin-border-subtle);
}

.page-title h2 {
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
}

.page-title p {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.admin-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid var(--admin-border);
  padding: 8px 16px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--gold-light);
}

/* ================= KPI STATS GRID ================= */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}

.kpi-card {
  background: var(--admin-card);
  border: 1px solid var(--admin-border-subtle);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: var(--transition);
}

.kpi-card:hover {
  border-color: var(--admin-border);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
}

.kpi-num {
  font-size: 2rem;
  font-weight: 800;
  color: var(--gold-light);
  line-height: 1.1;
}

.kpi-label {
  font-size: 0.78rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  margin-top: 4px;
}

.kpi-icon {
  font-size: 2.2rem;
  opacity: 0.8;
}

/* ================= CONTENT SECTIONS & TABS ================= */
.admin-section {
  display: none;
}

.admin-section.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ================= TABLES ================= */
.panel-card {
  background: var(--admin-card);
  border: 1px solid var(--admin-border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 28px;
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.panel-header h3 {
  font-size: 1.2rem;
  font-weight: 800;
  color: #fff;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.data-table th {
  background: rgba(13, 15, 23, 0.8);
  padding: 12px 14px;
  text-align: left;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--admin-border);
}

.data-table td {
  padding: 14px;
  border-bottom: 1px solid var(--admin-border-subtle);
  vertical-align: middle;
}

.data-table tr:hover {
  background: rgba(212, 175, 55, 0.04);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 9999px;
  text-transform: uppercase;
}

.status-pending {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.status-approved {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-rejected {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

/* ================= BUTTONS ================= */
.btn-gold {
  background: var(--gold-gradient);
  color: #0b0c10;
  font-weight: 800;
  font-size: 0.88rem;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
}

.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(212, 175, 55, 0.4);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.78rem;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: 1px solid var(--admin-border-subtle);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
}

.btn-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
  background: #ef4444;
  color: #fff;
}

/* ================= FORMS & INPUTS ================= */
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
}

.form-input, .form-textarea, .form-select {
  width: 100%;
  background: rgba(9, 11, 16, 0.85);
  border: 1px solid var(--admin-border-subtle);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  color: #fff;
  font-family: inherit;
  font-size: 0.9rem;
  transition: var(--transition);
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none;
  border-color: var(--gold-primary);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

/* ================= MODAL DIALOG ================= */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  z-index: 5000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-overlay.open {
  display: flex;
}

.modal-box {
  background: #11141f;
  border: 1px solid var(--admin-border);
  border-radius: var(--radius-lg);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 28px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.modal-header h3 {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--gold-light);
}

.btn-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.4rem;
  cursor: pointer;
}

.btn-close:hover {
  color: #fff;
}

/* Toast */
.admin-toast {
  position: fixed;
  top: 24px;
  right: 24px;
  background: #181c2b;
  border: 1px solid var(--gold-primary);
  color: #fff;
  padding: 14px 22px;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: 0 10px 25px rgba(0,0,0,0.8);
  transform: translateY(-40px);
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
  z-index: 10000;
}

.admin-toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* ================= 3X4 PHOTO UPLOAD & MEDIA STYLES ================= */
.upload-box-wrapper {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(0, 0, 0, 0.4);
  border: 1.5px dashed var(--gold-primary);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 16px;
}

.photo-preview-3x4 {
  width: 90px;
  height: 120px;
  border-radius: 8px;
  border: 2px solid var(--gold-primary);
  object-fit: cover;
  background: #0d0f17;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
}

.photo-preview-logo {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  border: 2px solid var(--gold-primary);
  object-fit: cover;
  background: #0d0f17;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
}

.upload-info-col {
  flex: 1;
}

.upload-info-col h5 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--gold-light);
  margin-bottom: 4px;
}

.upload-info-col p {
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 10px;
  line-height: 1.3;
}

.custom-file-input {
  display: none;
}

.btn-file-select {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--gold-gradient);
  color: #000;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}

.btn-file-select:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
}

/* ================= LIVE STREAM CONTROLS ================= */
.live-control-card {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(17, 20, 31, 0.9) 100%);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
}

.live-indicator-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
  border: 1px solid #ef4444;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.live-dot-pulse {
  width: 8px;
  height: 8px;
  background: #ef4444;
  border-radius: 50%;
  animation: pulseDot 1.4s infinite;
}

@keyframes pulseDot {
  0% { transform: scale(0.9); opacity: 0.6; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.6; }
}

/* ================= GALLERY & STORE GRIDS ================= */
.media-admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.media-admin-card {
  background: var(--admin-card);
  border: 1px solid var(--admin-border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: var(--transition);
  position: relative;
}

.media-admin-card:hover {
  border-color: var(--gold-primary);
  transform: translateY(-3px);
}

.media-admin-card img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  display: block;
}

.media-admin-card .content-box {
  padding: 12px;
}

.media-admin-card h5 {
  font-size: 0.9rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}

.media-admin-card p {
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.3;
  margin-bottom: 8px;
}

/* Team player card */
.player-admin-card {
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--admin-border-subtle);
  border-radius: 12px;
  padding: 12px;
  text-align: center;
  transition: var(--transition);
  position: relative;
}

.player-admin-card:hover {
  border-color: var(--gold-primary);
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.2);
}

.player-3x4-img {
  width: 72px;
  height: 96px;
  border-radius: 8px;
  border: 2px solid var(--gold-primary);
  object-fit: cover;
  margin: 0 auto 8px auto;
  display: block;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
}

.ovr-pill {
  display: inline-block;
  background: var(--gold-gradient);
  color: #000;
  font-weight: 900;
  font-size: 0.75rem;
  padding: 2px 8px;
  border-radius: 12px;
  margin-bottom: 6px;
}

