/* ==========================================================================
   PLAYERSPRO PANEL - SISTEMA DE DISEÑO PROFESIONAL UNIFICADO
   ========================================================================== */

:root {
  --bg-body: #0a0914;
  --bg-surface-1: #131122;
  --bg-surface-2: #1b1830;
  --bg-surface-3: #242040;
  --border-subtle: rgba(255, 255, 255, 0.07);
  --border-card: rgba(168, 139, 255, 0.15);
  --border-focus: #9d74ff;
  
  --primary: #8b5cf6;
  --primary-hover: #7c3aed;
  --primary-glow: rgba(139, 92, 246, 0.25);
  --secondary: #06b6d4;
  --accent-tv: #f43f5e;
  --accent-radio: #8b5cf6;
  
  --text-main: #f8f7ff;
  --text-muted: #a69fc2;
  --text-dim: #736c92;
  
  --success: #10b981;
  --success-bg: rgba(16, 185, 129, 0.12);
  --success-border: rgba(16, 185, 129, 0.35);
  --error: #f43f5e;
  --error-bg: rgba(244, 63, 94, 0.12);
  --error-border: rgba(244, 63, 94, 0.35);
  --warning: #f59e0b;
  --warning-bg: rgba(245, 158, 11, 0.12);
  --warning-border: rgba(245, 158, 11, 0.35);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.5);
  
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

body {
  font-family: var(--font-family);
  background-color: var(--bg-body);
  background-image: 
    radial-gradient(circle at 10% 0%, rgba(139, 92, 246, 0.15), transparent 45%),
    radial-gradient(circle at 90% 15%, rgba(6, 182, 212, 0.10), transparent 40%),
    radial-gradient(circle at 50% 100%, rgba(20, 15, 38, 0.8), transparent 60%);
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.18s ease;
}

a:hover {
  color: #c4b5fd;
}

/* --------------------------------------------------------------------------
   HEADER & NAVEGACIÓN UNIFICADA
   -------------------------------------------------------------------------- */
.panel-header {
  background: rgba(19, 17, 34, 0.82);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 100;
}

.panel-header-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.panel-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-main);
}

.panel-brand-logo {
  max-height: 38px;
  max-width: 160px;
  object-fit: contain;
}

.panel-brand-fallback {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  color: #fff;
}

.panel-brand-title {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  display: flex;
  flex-direction: column;
}

.panel-brand-title span {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.panel-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.panel-nav a {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 600;
  transition: all 0.18s ease;
  border: 1px solid transparent;
}

.panel-nav a:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.05);
}

.panel-nav a.active {
  color: #fff;
  background: rgba(139, 92, 246, 0.18);
  border-color: rgba(139, 92, 246, 0.35);
}

.panel-nav-btn {
  background: linear-gradient(135deg, var(--primary), #7044d6) !important;
  color: #fff !important;
  box-shadow: 0 4px 14px var(--primary-glow);
}

.panel-user-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-left: 14px;
  border-left: 1px solid var(--border-subtle);
  font-size: 0.82rem;
}

.user-role-tag {
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: rgba(139, 92, 246, 0.2);
  color: #c4b5fd;
  border: 1px solid rgba(139, 92, 246, 0.4);
}

/* --------------------------------------------------------------------------
   CONTENEDOR PRINCIPAL & ESTRUCTURA
   -------------------------------------------------------------------------- */
.dashboard-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 32px 24px 72px;
}

.page-header {
  margin-bottom: 28px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
}

.eyebrow {
  color: #c4b5fd;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.page-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #fff;
}

.page-subtitle {
  color: var(--text-muted);
  font-size: 0.94rem;
  margin-top: 4px;
}

/* --------------------------------------------------------------------------
   TARJETAS DE MÉTRICAS & RESUMEN
   -------------------------------------------------------------------------- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

.stat-card {
  background: var(--bg-surface-1);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-2px);
  border-color: rgba(168, 139, 255, 0.35);
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  background: rgba(255, 255, 255, 0.05);
  flex-shrink: 0;
}

.stat-icon.radio { background: rgba(139, 92, 246, 0.18); color: #c4b5fd; }
.stat-icon.tv { background: rgba(244, 63, 94, 0.18); color: #fda4af; }
.stat-icon.public { background: rgba(16, 185, 129, 0.18); color: #6ee7b7; }
.stat-icon.quota { background: rgba(6, 182, 212, 0.18); color: #67e8f9; }

.stat-info small {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.stat-info strong {
  display: block;
  font-size: 1.7rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
  margin-top: 2px;
}

/* --------------------------------------------------------------------------
   ACCIONES RÁPIDAS
   -------------------------------------------------------------------------- */
.quick-creators {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px;
  margin-bottom: 32px;
}

.creator-card {
  padding: 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-card);
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  transition: all 0.22s ease;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}

.creator-card.radio {
  background: linear-gradient(135deg, #1b1532, #141125);
  border-color: rgba(139, 92, 246, 0.28);
}
.creator-card.radio:hover {
  transform: translateY(-3px);
  border-color: var(--primary);
  box-shadow: 0 12px 28px rgba(139, 92, 246, 0.25);
}

.creator-card.tv {
  background: linear-gradient(135deg, #2a1426, #1a1020);
  border-color: rgba(244, 63, 94, 0.28);
}
.creator-card.tv:hover {
  transform: translateY(-3px);
  border-color: var(--accent-tv);
  box-shadow: 0 12px 28px rgba(244, 63, 94, 0.25);
}

.creator-body h3 {
  font-size: 1.2rem;
  color: #fff;
  font-weight: 700;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.creator-body p {
  color: var(--text-muted);
  font-size: 0.86rem;
}

.creator-badge {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 5px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
}
.creator-card.radio .creator-badge { background: rgba(139, 92, 246, 0.25); color: #ddd6fe; }
.creator-card.tv .creator-badge { background: rgba(244, 63, 94, 0.25); color: #fecdd3; }

.creator-arrow {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  color: #fff;
  flex-shrink: 0;
  transition: transform 0.2s ease, background 0.2s ease;
}
.creator-card:hover .creator-arrow {
  transform: translateX(4px);
  background: rgba(255, 255, 255, 0.16);
}

/* --------------------------------------------------------------------------
   TARJETA CONTENEDORA & FORMULARIOS
   -------------------------------------------------------------------------- */
.panel-card {
  background: var(--bg-surface-1);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-md);
  margin-bottom: 24px;
  position: relative;
}

.card-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-subtle);
  flex-wrap: wrap;
  gap: 14px;
}

.card-title {
  font-size: 1.22rem;
  font-weight: 700;
  color: #fff;
}

/* Formularios en Grid */
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px 22px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: #e5e1f8;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.form-label small {
  font-weight: 400;
  color: var(--text-dim);
}

.form-input, 
.form-select, 
.form-textarea {
  min-height: 46px;
  padding: 10px 14px;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: inherit;
  font-size: 0.94rem;
  transition: all 0.18s ease;
  width: 100%;
}

.form-input:focus, 
.form-select:focus, 
.form-textarea:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--primary-glow);
  background: var(--bg-surface-3);
}

.form-input:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background: rgba(255, 255, 255, 0.03);
}

.form-help {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Prefijo de URL fijo (infraestructura) */
.input-prefix-wrap {
  display: flex;
  align-items: stretch;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg-surface-2);
  transition: border-color 0.18s ease;
}

.input-prefix-wrap:focus-within {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.input-prefix {
  background: rgba(255, 255, 255, 0.05);
  padding: 0 14px;
  display: flex;
  align-items: center;
  font-size: 0.86rem;
  font-weight: 600;
  color: #c4b5fd;
  border-right: 1px solid var(--border-subtle);
  user-select: none;
  white-space: nowrap;
}

.input-prefix.tv-prefix {
  color: #fda4af;
}

.input-prefix-wrap .form-input {
  border: none;
  border-radius: 0;
  background: transparent;
}

.input-prefix-wrap .form-input:focus {
  box-shadow: none;
}

.input-suffix {
  background: rgba(255, 255, 255, 0.05);
  padding: 0 14px;
  display: flex;
  align-items: center;
  font-size: 0.84rem;
  color: var(--text-dim);
  border-left: 1px solid var(--border-subtle);
  user-select: none;
  white-space: nowrap;
}

/* Indicador de Servidor Fijo */
.fixed-host-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  background: rgba(139, 92, 246, 0.10);
  border: 1px solid rgba(139, 92, 246, 0.25);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  color: #ddd6fe;
}
.fixed-host-pill.tv {
  background: rgba(244, 63, 94, 0.10);
  border-color: rgba(244, 63, 94, 0.25);
  color: #fecdd3;
}
.fixed-host-pill strong {
  color: #fff;
}

/* Checkbox Toggle Moderno */
.toggle-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background: var(--bg-surface-2);
  cursor: pointer;
  user-select: none;
  transition: all 0.18s ease;
}

.toggle-item:hover {
  border-color: rgba(255, 255, 255, 0.14);
}

.toggle-item input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
  cursor: pointer;
}

.toggle-text {
  display: flex;
  flex-direction: column;
}

.toggle-text strong {
  font-size: 0.88rem;
  color: #fff;
}

.toggle-text small {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   SELECTOR VISUAL DE THEMES (18 HISTÓRICOS)
   -------------------------------------------------------------------------- */
.theme-selector-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.theme-card-option {
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 8px;
  background: var(--bg-surface-2);
  cursor: pointer;
  text-align: center;
  transition: all 0.18s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.theme-card-option:hover {
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
}

.theme-card-option.active {
  border-color: var(--primary);
  background: rgba(139, 92, 246, 0.14);
  box-shadow: 0 0 0 2px var(--primary-glow);
}

.theme-preview-orb {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.theme-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* --------------------------------------------------------------------------
   PESTAÑAS DE TIPO (RADIO / TV)
   -------------------------------------------------------------------------- */
.type-switcher {
  display: inline-flex;
  padding: 5px;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  gap: 4px;
  margin-bottom: 24px;
}

.type-tab-btn {
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.94rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.18s ease;
}

.type-tab-btn:hover {
  color: #fff;
}

.type-tab-btn.active.radio {
  background: linear-gradient(135deg, var(--primary), #6d28d9);
  color: #fff;
  box-shadow: 0 4px 14px var(--primary-glow);
}

.type-tab-btn.active.tv {
  background: linear-gradient(135deg, var(--accent-tv), #be123c);
  color: #fff;
  box-shadow: 0 4px 14px rgba(244, 63, 94, 0.3);
}

/* --------------------------------------------------------------------------
   TABLA / LISTA DE PLAYERS EN DASHBOARD
   -------------------------------------------------------------------------- */
.players-table-wrap {
  overflow-x: auto;
}

.players-list {
  display: grid;
  gap: 10px;
}

.player-item-row {
  background: var(--bg-surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  transition: all 0.18s ease;
}

.player-item-row:hover {
  border-color: rgba(168, 139, 255, 0.28);
  background: rgba(27, 24, 48, 0.9);
}

.player-main-info {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
  flex: 1;
}

.player-thumb {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface-3);
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: #fff;
}

.player-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.player-title-line {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.player-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
}

.player-url-link {
  font-size: 0.82rem;
  color: #a78bfa;
  font-family: monospace;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.player-badges {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge-radio { background: rgba(139, 92, 246, 0.2); color: #c4b5fd; border: 1px solid rgba(139, 92, 246, 0.35); }
.badge-tv { background: rgba(244, 63, 94, 0.2); color: #fda4af; border: 1px solid rgba(244, 63, 94, 0.35); }
.badge-managed { background: rgba(6, 182, 212, 0.18); color: #67e8f9; border: 1px solid rgba(6, 182, 212, 0.3); }
.badge-inherited { background: rgba(245, 158, 11, 0.18); color: #fcd34d; border: 1px solid rgba(245, 158, 11, 0.3); }
.badge-public { background: rgba(16, 185, 129, 0.18); color: #6ee7b7; border: 1px solid rgba(16, 185, 129, 0.3); }
.badge-hidden { background: rgba(255, 255, 255, 0.08); color: var(--text-muted); border: 1px solid rgba(255, 255, 255, 0.12); }

/* Acciones */
.player-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  flex-wrap: wrap;
}

.btn-action {
  padding: 7px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  color: #ddd;
  cursor: pointer;
  transition: all 0.16s ease;
  text-decoration: none;
}

.btn-action:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-action.btn-open {
  background: rgba(139, 92, 246, 0.14);
  border-color: rgba(139, 92, 246, 0.3);
  color: #c4b5fd;
}
.btn-action.btn-open:hover {
  background: var(--primary);
  color: #fff;
}

.btn-action.btn-toggle-pub {
  background: rgba(255, 255, 255, 0.04);
}

.btn-action.btn-delete {
  color: #fb7185;
  border-color: rgba(244, 63, 94, 0.3);
  background: rgba(244, 63, 94, 0.06);
}
.btn-action.btn-delete:hover {
  background: var(--error);
  border-color: var(--error);
  color: #ffffff;
}

/* --------------------------------------------------------------------------
   BOTONES PRIMARIOS & SECUNDARIOS
   -------------------------------------------------------------------------- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--primary), #6d28d9);
  color: #fff;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 16px var(--primary-glow);
  transition: all 0.18s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(139, 92, 246, 0.38);
  filter: brightness(1.06);
  color: #fff;
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: all 0.18s ease;
  text-decoration: none;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

/* --------------------------------------------------------------------------
   ALERTAS & MENSAJES
   -------------------------------------------------------------------------- */
.alert {
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  line-height: 1.4;
}

.alert-success {
  background: var(--success-bg);
  border: 1px solid var(--success-border);
  color: #6ee7b7;
}

.alert-error {
  background: var(--error-bg);
  border: 1px solid var(--error-border);
  color: #fca5a5;
}

.alert-warning {
  background: var(--warning-bg);
  border: 1px solid var(--warning-border);
  color: #fcd34d;
}

/* --------------------------------------------------------------------------
   MODO AUTH (LOGIN & INSTALL)
   -------------------------------------------------------------------------- */
.auth-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--bg-surface-1);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-xl);
  padding: 36px 32px;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.auth-header {
  text-align: center;
  margin-bottom: 28px;
}

.auth-header h1 {
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
  margin-top: 12px;
}

.auth-header p {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-top: 4px;
}

/* --------------------------------------------------------------------------
   RESPONSIVE QUERIES
   -------------------------------------------------------------------------- */
@media (max-width: 860px) {
  .panel-header-inner {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .panel-user-badge {
    border-left: none;
    padding-left: 0;
    margin-top: 8px;
  }
  
  .player-item-row {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .player-actions {
    width: 100%;
    padding-top: 10px;
    border-top: 1px solid var(--border-subtle);
  }
}

@media (max-width: 600px) {
  .dashboard-container {
    padding: 20px 14px 50px;
  }
  
  .form-grid {
    grid-template-columns: 1fr;
  }
  
  .theme-selector-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* --------------------------------------------------------------------------
   BRAND & IDENTITY STYLES
   -------------------------------------------------------------------------- */
.brand-preview-card {
  background: var(--bg-surface-2);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 12px;
}

.brand-preview-logo {
  max-width: 180px;
  max-height: 80px;
  object-fit: contain;
  background: rgba(0, 0, 0, 0.2);
  padding: 8px;
  border-radius: 8px;
}

.brand-color-swatches {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}

.color-swatch-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.swatch-circle {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.2);
}

/* --------------------------------------------------------------------------
   QUOTA PROGRESS BAR
   -------------------------------------------------------------------------- */
.quota-progress-container {
  width: 100%;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  height: 8px;
  overflow: hidden;
  margin-top: 6px;
}

.quota-progress-bar {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  transition: width 0.3s ease;
}

.quota-progress-bar.warning {
  background: #f59e0b;
}

.quota-progress-bar.danger {
  background: #ef4444;
}

/* --------------------------------------------------------------------------
   DIAGNOSTIC & STATS STYLES
   -------------------------------------------------------------------------- */
.diag-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}

.diag-card {
  background: var(--bg-surface-1);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 22px;
}

.diag-card h3 {
  font-size: 1rem;
  color: #fff;
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.diag-item {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-subtle);
  font-size: 0.88rem;
}

.diag-item:last-child {
  border-bottom: none;
}

.diag-item .label {
  color: var(--text-muted);
}

.diag-item .val {
  font-weight: 600;
  color: #fff;
}
