/**
 * themes.css
 * 
 * Estilos base para o sistema de temas
 * Sistema de Análise The Tower
 * 
 * @author Dudu Lima
 * @version 1.0.0
 * @since 2025-01-08
 */

/* =============================================
   VARIÁVEIS CSS BASE
   ============================================= */

:root {
  /* ⚠️ CORES REMOVIDAS - Vêm de api/themes-css.php
     Cores definidas dinamicamente via html[data-theme="..."]
     Fonte única: config/theme_manager.php */
  
  /* Transições */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
  
  /* Sombras */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  
  /* Bordas */
  --border-radius-sm: 0.25rem;
  --border-radius-md: 0.5rem;
  --border-radius-lg: 0.75rem;
  --border-radius-xl: 1rem;
  
  /* Espaçamentos */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  
  /* Tipografia - Tamanhos */
  --font-size-base: 16px;
  --font-size-small: 14px;
  --font-size-medium: 16px;
  --font-size-large: 18px;
  --font-size-xlarge: 20px;
  
  /* Tipografia - Famílias */
  --font-family-system: 'Sofia Sans Condensed', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-family-serif: 'Georgia', 'Times New Roman', 'Times', serif;
  --font-family-monospace: 'Courier New', 'Courier', monospace, 'Monaco', 'Menlo', 'Consolas';
  --font-family-custom: 'Sofia Sans Condensed', sans-serif;
}

/* =============================================
   TEMAS VIA DATA-THEME - DESATIVADO
   ============================================= 
   
   As cores dos temas agora vêm de /api/themes-css.php
   que gera CSS dinamicamente de config/theme_manager.php
   
   FONTE ÚNICA: config/theme_manager.php
   NÃO edite aqui - edite theme_manager.php
   ============================================= */

/* ⚠️ TODOS OS TEMAS DESATIVADOS - Cores vêm de api/themes-css.php
   
   FONTE ÚNICA: config/theme_manager.php → api/themes-css.php
   NÃO edite aqui - todas as cores são geradas dinamicamente
   
html[data-theme="dark"] {
  --color-primary: #3b82f6;
  --color-secondary: #64748b;
  --color-background: #0f172a;
  --color-surface: #1e293b;
  --color-text: #f1f5f9;
  --color-text-muted: #94a3b8;
  --color-border: #334155;
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-info: #06b6d4;
}

html[data-theme="light"] {
  --color-primary: #3b82f6;
  --color-secondary: #64748b;
  --color-background: #ffffff;
  --color-surface: #f8fafc;
  --color-text: #0f172a;
  --color-text-muted: #64748b;
  --color-border: #e2e8f0;
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-info: #06b6d4;
}

html[data-theme="turquesa"] {
  --color-primary: #06b6d4;
  --color-secondary: #0891b2;
  --color-background: #0c1621;
  --color-surface: #1a2332;
  --color-text: #e0f2fe;
  --color-text-muted: #7dd3fc;
  --color-border: #164e63;
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-info: #06b6d4;
}

html[data-theme="monolux"] {
  --color-primary: #6b7280;
  --color-secondary: #9ca3af;
  --color-background: #111827;
  --color-surface: #1f2937;
  --color-text: #f9fafb;
  --color-text-muted: #d1d5db;
  --color-border: #374151;
  --color-success: #34d399;
  --color-warning: #fbbf24;
  --color-error: #f87171;
  --color-info: #60a5fa;
}

html[data-theme="neon-skate"] {
  --color-primary: #8b5cf6;
  --color-secondary: #ec4899;
  --color-background: #0f0a1e;
  --color-surface: #1e1533;
  --color-text: #faf5ff;
  --color-text-muted: #d8b4fe;
  --color-border: #6b21a8;
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-info: #06b6d4;
}

html[data-theme="bordeaux"] {
  --color-primary: #dc2626;
  --color-secondary: #991b1b;
  --color-background: #1c0a0a;
  --color-surface: #3f1515;
  --color-text: #fef2f2;
  --color-text-muted: #fca5a5;
  --color-border: #7f1d1d;
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-info: #06b6d4;
}

html[data-theme="terra-urbana"] {
  --color-primary: #f97316;
  --color-secondary: #78350f;
  --color-background: #1c1410;
  --color-surface: #292218;
  --color-text: #fef3c7;
  --color-text-muted: #fcd34d;
  --color-border: #78350f;
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-info: #06b6d4;
}

FIM DO BLOCO DESATIVADO - Todas as cores vêm de api/themes-css.php */

/* =============================================
   ⚠️ TODOS OS TEMAS SÃO GERADOS AUTOMATICAMENTE
   ============================================= */

/* 
   🎯 FONTE ÚNICA DE VERDADE: config/theme_manager.php
   
   O CSS de TODOS os temas é gerado dinamicamente por:
   config/theme_manager.php → api/themes-css.php
   
   Os estilos são aplicados via:
   html[data-theme="nome-do-tema"] { ... }
   
   ❌ NÃO adicione classes .theme-* hardcoded neste arquivo
   ❌ NÃO defina cores de temas manualmente aqui
   
   ✅ Para editar/criar temas:
   1. Abra config/theme_manager.php
   2. Edite/adicione no array AVAILABLE_THEMES
   3. Salve - o CSS será gerado automaticamente
   4. Limpe cache do navegador (Ctrl+Shift+R)
   
   📋 Temas disponíveis:
   - dark (escuro padrão)
   - light (claro)
   - turquesa (turquesa profundo)
   - monolux (monocromático cinza)
   - neon-skate (neon vibrante)
   - bordeaux (vermelho vinho)
   - terra-urbana (laranja terroso)
   - hotel (hotel california - neutro elegante)
   
   🔍 Para ver o CSS gerado:
   https://thetower.dudulima.com.br/api/themes-css.php
*/

/* =============================================
   COMPONENTES BASE
   ============================================= */

/* Cards */
.card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--border-radius-lg);
  padding: var(--spacing-lg);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-normal);
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.card__header {
  border-bottom: 1px solid var(--color-border);
  padding-bottom: var(--spacing-md);
  margin-bottom: var(--spacing-md);
}

.card__title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-text);
  margin: 0;
}

.card__subtitle {
  font-size: 0.875rem;
  color: var(--color-text-muted);
  margin: var(--spacing-xs) 0 0 0;
}

/* Botões */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  border: 1px solid transparent;
  border-radius: var(--border-radius-md);
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn--primary {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
  color: white;
}

.btn--primary:hover:not(:disabled) {
  background-color: #2563eb;
  border-color: #2563eb;
}

.btn--secondary {
  background-color: var(--color-secondary);
  border-color: var(--color-secondary);
  color: white;
}

.btn--secondary:hover:not(:disabled) {
  background-color: #475569;
  border-color: #475569;
}

.btn--outline {
  background-color: transparent;
  border-color: var(--color-border);
  color: var(--color-text);
}

.btn--outline:hover:not(:disabled) {
  background-color: var(--color-surface);
}

.btn--small {
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: 0.75rem;
}

.btn--large {
  padding: var(--spacing-md) var(--spacing-lg);
  font-size: 1rem;
}

/* Formulários */
.form-group {
  margin-bottom: var(--spacing-md);
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: var(--spacing-xs);
}

.form-input {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
  border: 1px solid var(--color-border);
  border-radius: var(--border-radius-md);
  background-color: var(--color-surface);
  color: var(--color-text);
  font-size: 0.875rem;
  transition: border-color var(--transition-fast);
}

.form-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-input::placeholder {
  color: var(--color-text-muted);
}

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right var(--spacing-sm) center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  padding-right: var(--spacing-xl);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: var(--border-radius-sm);
  background-color: var(--color-secondary);
  color: white;
}

.badge--success {
  background-color: var(--color-success);
}

.badge--warning {
  background-color: var(--color-warning);
}

.badge--error {
  background-color: var(--color-error);
}

.badge--info {
  background-color: var(--color-info);
}

.badge--primary {
  background-color: var(--color-primary);
}

/* Alertas */
.alert {
  padding: var(--spacing-md);
  border-radius: var(--border-radius-md);
  border: 1px solid;
  margin-bottom: var(--spacing-md);
}

.alert--success {
  background-color: rgba(16, 185, 129, 0.1);
  border-color: var(--color-success);
  color: var(--color-success);
}

.alert--warning {
  background-color: rgba(245, 158, 11, 0.1);
  border-color: var(--color-warning);
  color: var(--color-warning);
}

.alert--error {
  background-color: rgba(239, 68, 68, 0.1);
  border-color: var(--color-error);
  color: var(--color-error);
}

.alert--info {
  background-color: rgba(6, 182, 212, 0.1);
  border-color: var(--color-info);
  color: var(--color-info);
}

/* =============================================
   UTILITÁRIOS
   ============================================= */

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-muted { color: var(--color-text-muted); }
.text-primary { color: var(--color-primary); }
.text-success { color: var(--color-success); }
.text-warning { color: var(--color-warning); }
.text-error { color: var(--color-error); }
.text-info { color: var(--color-info); }

.bg-primary { background-color: var(--color-primary); }
.bg-secondary { background-color: var(--color-secondary); }
.bg-success { background-color: var(--color-success); }
.bg-warning { background-color: var(--color-warning); }
.bg-error { background-color: var(--color-error); }
.bg-info { background-color: var(--color-info); }

.border { border: 1px solid var(--color-border); }
.border-top { border-top: 1px solid var(--color-border); }
.border-bottom { border-bottom: 1px solid var(--color-border); }
.border-left { border-left: 1px solid var(--color-border); }
.border-right { border-right: 1px solid var(--color-border); }

.rounded { border-radius: var(--border-radius-md); }
.rounded-sm { border-radius: var(--border-radius-sm); }
.rounded-lg { border-radius: var(--border-radius-lg); }
.rounded-xl { border-radius: var(--border-radius-xl); }
.rounded-full { border-radius: 9999px; }

.shadow { box-shadow: var(--shadow-md); }
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }

/* Espaçamentos */
.p-0 { padding: 0; }
.p-1 { padding: var(--spacing-xs); }
.p-2 { padding: var(--spacing-sm); }
.p-3 { padding: var(--spacing-md); }
.p-4 { padding: var(--spacing-lg); }
.p-5 { padding: var(--spacing-xl); }

.m-0 { margin: 0; }
.m-1 { margin: var(--spacing-xs); }
.m-2 { margin: var(--spacing-sm); }
.m-3 { margin: var(--spacing-md); }
.m-4 { margin: var(--spacing-lg); }
.m-5 { margin: var(--spacing-xl); }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: var(--spacing-xs); }
.mt-2 { margin-top: var(--spacing-sm); }
.mt-3 { margin-top: var(--spacing-md); }
.mt-4 { margin-top: var(--spacing-lg); }
.mt-5 { margin-top: var(--spacing-xl); }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: var(--spacing-xs); }
.mb-2 { margin-bottom: var(--spacing-sm); }
.mb-3 { margin-bottom: var(--spacing-md); }
.mb-4 { margin-bottom: var(--spacing-lg); }
.mb-5 { margin-bottom: var(--spacing-xl); }

/* Flexbox */
.d-flex { display: flex; }
.flex-column { flex-direction: column; }
.flex-row { flex-direction: row; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-around { justify-content: space-around; }
.align-center { align-items: center; }
.align-start { align-items: flex-start; }
.align-end { align-items: flex-end; }

/* Grid */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, 1fr); }
.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
.gap-1 { gap: var(--spacing-xs); }
.gap-2 { gap: var(--spacing-sm); }
.gap-3 { gap: var(--spacing-md); }
.gap-4 { gap: var(--spacing-lg); }
.gap-5 { gap: var(--spacing-xl); }

/* Responsividade */
@media (max-width: 768px) {
  .grid-cols-2 { grid-template-columns: 1fr; }
  .grid-cols-3 { grid-template-columns: 1fr; }
  .grid-cols-4 { grid-template-columns: repeat(2, 1fr); }
  
  .btn {
    padding: var(--spacing-sm) var(--spacing-md);
    font-size: 0.875rem;
  }
  
  .card {
    padding: var(--spacing-md);
  }
}

@media (max-width: 480px) {
  .grid-cols-4 { grid-template-columns: 1fr; }
  
  .btn {
    padding: var(--spacing-xs) var(--spacing-sm);
    font-size: 0.75rem;
  }
  
  .card {
    padding: var(--spacing-sm);
  }
}

/* =============================================
   ANIMAÇÕES
   ============================================= */

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideIn {
  from { transform: translateY(-10px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.animate-fade-in {
  animation: fadeIn var(--transition-normal);
}

.animate-slide-in {
  animation: slideIn var(--transition-normal);
}

.animate-pulse {
  animation: pulse 2s infinite;
}

/* =============================================
   ESTADOS DE LOADING
   ============================================= */

.is-loading {
  position: relative;
  pointer-events: none;
}

.is-loading::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(255, 255, 255, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.theme-dark .is-loading::after {
  background-color: rgba(0, 0, 0, 0.8);
}

.loading-spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid var(--color-border);
  border-radius: 50%;
  border-top-color: var(--color-primary);
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* =============================================
   CAMPOS FAVORITOS DESTACADOS
   ============================================= */

.favorite-fields-highlight {
  background: var(--color-surface);
  border: 2px solid var(--color-border);
  border-radius: 16px;
  padding: var(--spacing-lg);
  margin: var(--spacing-lg) 0;
  animation: slideIn var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.favorite-fields-highlight::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-info), var(--color-success));
  animation: shimmer 3s infinite;
}

@keyframes shimmer {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.favorite-fields-highlight__header {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-sm);
  border-bottom: 1px solid var(--color-border);
}

.favorite-fields-highlight__header i {
  font-size: 1.3rem;
  color: var(--color-primary);
  animation: pulse 2s infinite;
  filter: drop-shadow(0 2px 4px rgba(59, 130, 246, 0.3));
}

.favorite-fields-highlight__header span {
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.favorite-fields-highlight__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--spacing-md);
}

.favorite-field-card {
  position: relative;
  background: linear-gradient(135deg, var(--color-background), var(--color-surface));
  border: 2px solid var(--color-border);
  border-radius: 14px;
  padding: 20px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  cursor: default;
  min-height: 140px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.favorite-field-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100%;
  background: linear-gradient(135deg, 
    rgba(59, 130, 246, 0.1) 0%, 
    rgba(16, 185, 129, 0.05) 50%, 
    rgba(99, 102, 241, 0.1) 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.favorite-field-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transition: left 0.5s ease;
}

.favorite-field-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15), 0 0 0 1px var(--color-primary);
  border-color: var(--color-primary);
}

.favorite-field-card:hover::before {
  opacity: 1;
}

.favorite-field-card:hover::after {
  left: 100%;
}

.favorite-field-card__label {
  position: relative;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: var(--spacing-sm);
  display: flex;
  align-items: center;
  gap: 6px;
}

.favorite-field-card__label::before {
  content: '●';
  color: var(--color-primary);
  font-size: 0.6rem;
  animation: pulse 2s infinite;
}

.favorite-field-card__value {
  position: relative;
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.2;
  letter-spacing: -0.5px;
  margin-bottom: var(--spacing-md);
  background: linear-gradient(135deg, var(--color-text) 0%, var(--color-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-fill-color: transparent;
}

/* Fallback para navegadores que não suportam background-clip */
@supports not (-webkit-background-clip: text) {
  .favorite-field-card__value {
    color: var(--color-primary);
  }
}

.favorite-field-card__derived {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text-muted);
  font-family: 'SF Mono', 'Roboto Mono', 'Courier New', monospace;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: var(--spacing-xs) var(--spacing-sm);
  background: rgba(59, 130, 246, 0.08);
  border-radius: 8px;
  transition: all 0.2s ease;
}

.favorite-field-card:hover .favorite-field-card__derived {
  background: rgba(59, 130, 246, 0.15);
  color: var(--color-primary);
  transform: translateX(2px);
}

/* Responsividade para campos favoritos */
@media (max-width: 768px) {
  .favorite-fields-highlight {
    padding: var(--spacing-md);
    margin: var(--spacing-md) 0;
  }
  
  .favorite-fields-highlight__grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: var(--spacing-md);
  }
  
  .favorite-field-card {
    padding: var(--spacing-md);
  }
  
  .favorite-field-card:hover {
    transform: translateY(-4px) scale(1.01);
  }
  
  .favorite-field-card__label {
    font-size: 0.7rem;
  }
  
  .favorite-field-card__value {
    font-size: 1.6rem;
    margin-bottom: var(--spacing-sm);
  }
  
  .favorite-field-card__derived {
    font-size: 0.8rem;
    padding: 6px 10px;
  }
}

@media (max-width: 480px) {
  .favorite-fields-highlight {
    padding: var(--spacing-md);
    border-radius: 12px;
    margin: var(--spacing-md) 0;
  }
  
  .favorite-fields-highlight__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-sm);
  }
  
  .favorite-field-card {
    padding: var(--spacing-md);
    min-height: 80px;
  }
  
  .favorite-field-card__label {
    font-size: 0.65rem;
    margin-bottom: var(--spacing-xs);
  }
  
  .favorite-field-card__value {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-sm);
  }
  
  .favorite-field-card__derived {
    font-size: 0.75rem;
    padding: 4px 8px;
  }
}

/* =============================================
   SEÇÃO DE EVOLUÇÃO
   ============================================= */

.evolution-section {
  background: var(--color-surface);
  border: 2px solid var(--color-border);
  border-radius: 16px;
  padding: var(--spacing-lg);
  margin: var(--spacing-lg) 0;
  position: relative;
  overflow: hidden;
}

.evolution-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--color-success), var(--color-warning), var(--color-error));
  animation: shimmer 3s infinite;
}

.evolution-section__header {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-sm);
  border-bottom: 1px solid var(--color-border);
}

.evolution-section__header i {
  font-size: 1.3rem;
  color: var(--color-success);
  animation: pulse 2s infinite;
  filter: drop-shadow(0 2px 4px rgba(16, 185, 129, 0.3));
}

.evolution-section__header span {
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.evolution-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--spacing-md);
}

.evolution-card {
  position: relative;
  background: linear-gradient(135deg, var(--color-background), var(--color-surface));
  border: 2px solid var(--color-border);
  border-radius: 14px;
  padding: var(--spacing-lg);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.evolution-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100%;
  background: linear-gradient(135deg, 
    rgba(16, 185, 129, 0.1) 0%, 
    rgba(245, 158, 11, 0.05) 50%, 
    rgba(239, 68, 68, 0.1) 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.evolution-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transition: left 0.5s ease;
}

.evolution-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15), 0 0 0 1px var(--color-success);
  border-color: var(--color-success);
}

.evolution-card:hover::before {
  opacity: 1;
}

.evolution-card:hover::after {
  left: 100%;
}

.evolution-card__label {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: var(--spacing-sm);
  display: flex;
  align-items: center;
  gap: 6px;
}

.evolution-card__label::before {
  content: '▲';
  color: var(--color-success);
  font-size: 0.8rem;
}

.evolution-card--negative .evolution-card__label::before {
  content: '▼';
  color: var(--color-error);
}

.evolution-card--neutral .evolution-card__label::before {
  content: '●';
  color: var(--color-info);
}

.evolution-card__value {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-text);
  line-height: 1.2;
  letter-spacing: -0.5px;
  margin-bottom: var(--spacing-xs);
}

.evolution-card__diff {
  font-size: 0.9rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

.evolution-card__diff--positive {
  color: var(--color-success);
}

.evolution-card__diff--negative {
  color: var(--color-error);
}

.evolution-card__diff--neutral {
  color: var(--color-text-muted);
}

.evolution-card__diff i {
  font-size: 0.8rem;
}

/* Responsividade evolução */
@media (max-width: 768px) {
  .evolution-section {
    padding: var(--spacing-md);
  }
  
  .evolution-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: var(--spacing-sm);
  }
  
  .evolution-card {
    padding: var(--spacing-md);
  }
  
  .evolution-card:hover {
    transform: translateY(-4px) scale(1.01);
  }
}

@media (max-width: 480px) {
  .evolution-section {
    padding: var(--spacing-sm);
    border-radius: 12px;
  }
  
  .evolution-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-xs);
  }
  
  .evolution-card {
    padding: var(--spacing-sm);
  }
  
  .evolution-card__value {
    font-size: 1.2rem;
  }
  
  .evolution-card__diff {
    font-size: 0.8rem;
  }
}

/* =============================================
   HEADER UNIFICADO
   ============================================= */

/* Espaçamento para compensar header fixo */
body {
  padding-top: 72px;
}

@media (max-width: 768px) {
  body {
    padding-top: 60px;
  }
}

.unified-header {
  background: var(--color-surface, #1e293b);
  border-bottom: 1px solid var(--color-border, #334155);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  width: 100vw;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  transition: all 0.3s ease;
  /* Preparar para glass effect */
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
}

/* Efeito glass quando rolado - Inspirado em css.glass */
.unified-header.is-scrolled {
  background: rgba(30, 41, 59, 0.29) !important;
  backdrop-filter: blur(3px) saturate(100%) !important;
  -webkit-backdrop-filter: blur(3px) saturate(100%) !important;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3) !important;
  border-bottom: 1px solid rgba(30, 41, 59, 0.05) !important;
}

/* Para tema claro */
.theme-light .unified-header {
  background: rgba(248, 250, 252, 1);
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
}

.theme-light .unified-header.is-scrolled {
  background: rgba(255, 255, 255, 0.29) !important;
  backdrop-filter: blur(3px) saturate(100%) !important;
  -webkit-backdrop-filter: blur(3px) saturate(100%) !important;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}

/* Card flutuante - Tema Light */
.theme-light .user-floating-card {
  background: linear-gradient(135deg, #ffffff, rgba(59, 130, 246, 0.05));
  border-color: var(--color-primary);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15), 0 0 20px rgba(59, 130, 246, 0.15);
}

.theme-light .user-floating-card__name {
  color: #1e293b;
}

.theme-light .user-floating-card__stats {
  color: #64748b;
}

/* Garantir que hambúrguer desapareça quando menu está aberto */
.unified-header.menu-is-open .unified-header__hamburger {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.unified-header__container {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  box-sizing: border-box;
}

.unified-header__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  transition: transform 0.2s;
}

.unified-header__brand:hover {
  transform: scale(1.02);
}

.unified-header__logo {
  height: 40px;
  width: auto;
}

.unified-header__title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-text, #f1f5f9);
}

.unified-header__player {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--color-surface, rgba(255, 255, 255, 0.05));
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--color-accent, #60a5fa);
  margin-left: auto !important;
  order: 10;
}

.unified-header__player i {
  font-size: 1.1rem;
  opacity: 0.8;
}

/* Dev Mode Badge */
.unified-header__dev-badge {
  display: flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
  padding: 0.5rem 1rem !important;
  background: linear-gradient(135deg, #ff6b00, #ff8800) !important;
  border-radius: 8px !important;
  font-size: 0.85rem !important;
  font-weight: 700 !important;
  color: white !important;
  margin-left: 1rem !important;
  box-shadow: 0 0 20px rgba(255, 107, 0, 0.3) !important;
  animation: pulse-warning 2s ease-in-out infinite !important;
  cursor: help !important;
  position: relative !important;
  z-index: 100 !important;
  white-space: nowrap !important;
}

.unified-header__dev-badge i {
  font-size: 1rem !important;
  animation: shake 0.5s ease-in-out infinite !important;
  color: white !important;
}

.unified-header__dev-text {
  letter-spacing: 0.5px !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2) !important;
  color: white !important;
  font-weight: 700 !important;
}

@keyframes pulse-warning {
  0%, 100% {
    box-shadow: 0 0 20px rgba(255, 107, 0, 0.3);
  }
  50% {
    box-shadow: 0 0 30px rgba(255, 107, 0, 0.6);
  }
}

@keyframes shake {
  0%, 100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-2px) rotate(-5deg);
  }
  75% {
    transform: translateX(2px) rotate(5deg);
  }
}

/* Card Flutuante do Usuário */
.user-floating-card {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--color-surface, #1e293b), var(--color-primary, #3b82f6)15);
  border: 2px solid var(--color-primary, #3b82f6);
  border-radius: 16px;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(59, 130, 246, 0.2);
  backdrop-filter: blur(10px);
  min-width: 300px;
  z-index: 100000;
}

.user-floating-card__avatar {
  flex-shrink: 0;
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, var(--color-primary, #3b82f6), #2563eb);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.user-floating-card__avatar i {
  font-size: 2rem;
  color: white;
}

.user-floating-card__info {
  flex: 1;
  min-width: 0;
}

.user-floating-card__name {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-text, #f1f5f9);
  margin-bottom: 0.5rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-floating-card__stats {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--color-text-muted, #94a3b8);
}

.user-floating-card__stats i {
  font-size: 0.9rem;
  color: var(--color-primary, #3b82f6);
}

/* Animação slide-down */
.slide-down-enter-active {
  animation: slideDown 0.3s ease-out;
}

.slide-down-leave-active {
  animation: slideDown 0.3s ease-out reverse;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.unified-header__hamburger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  order: 11;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
  width: 40px;
  height: 40px;
  position: relative;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.unified-header__hamburger span {
  display: block;
  width: 25px;
  height: 3px;
  background: var(--color-text, #f1f5f9);
  border-radius: 2px;
  transition: all 0.3s ease;
  position: absolute;
}

.unified-header__hamburger span:nth-child(1) {
  top: 10px;
}

.unified-header__hamburger span:nth-child(2) {
  top: 18px;
}

.unified-header__hamburger span:nth-child(3) {
  top: 26px;
}

.unified-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 99998;
  display: flex;
  justify-content: flex-end;
}

.unified-menu__content {
  width: 100%;
  max-width: 350px;
  height: 100%;
  background: var(--color-surface, #1e293b);
  overflow-y: auto;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.3);
  position: relative;
  z-index: 99999;
}

.unified-menu__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem;
  border-bottom: 1px solid var(--color-border, #334155);
}

.unified-menu__header h3 {
  margin: 0;
  color: var(--color-text, #f1f5f9);
  font-size: 1.25rem;
}

.unified-menu__close {
  background: none;
  border: none;
  color: var(--color-text-muted, #94a3b8);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.25rem;
  transition: color 0.2s;
}

.unified-menu__close:hover {
  color: var(--color-text, #f1f5f9);
}

.unified-menu__section {
  padding: 1.5rem;
  border-bottom: 1px solid var(--color-border, #334155);
}

.unified-menu__section-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 1rem 0;
  color: var(--color-text-muted, #94a3b8);
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.unified-menu__select {
  width: 100%;
  padding: 0.75rem;
  background: var(--color-background, #0f172a);
  border: 1px solid var(--color-border, #334155);
  border-radius: 0.5rem;
  color: var(--color-text, #f1f5f9);
  font-size: 0.95rem;
  cursor: pointer;
  transition: border-color 0.2s;
}

.unified-menu__select:hover,
.unified-menu__select:focus {
  border-color: var(--color-primary, #3b82f6);
  outline: none;
}

.unified-menu__nav {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.unified-menu__link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: var(--color-background, #0f172a);
  border: 1px solid transparent;
  border-radius: 0.5rem;
  color: var(--color-text, #f1f5f9);
  text-decoration: none;
  font-size: 0.95rem;
  transition: all 0.2s;
}

.unified-menu__link:hover {
  background: var(--color-surface, #1e293b);
  border-color: var(--color-border, #334155);
  transform: translateX(4px);
}

.unified-menu__link.is-active {
  background: var(--color-primary, #3b82f6);
  color: white;
}

.unified-menu__link--danger {
  color: #ef4444 !important;
}

.unified-menu__link--danger:hover {
  background: rgba(239, 68, 68, 0.1) !important;
  border-color: #ef4444 !important;
}

.unified-menu__link i {
  width: 20px;
  text-align: center;
}

/* Animações Vue do menu */
.slide-menu-enter-active,
.slide-menu-leave-active {
  transition: opacity 0.3s;
}

.slide-menu-enter-from,
.slide-menu-leave-to {
  opacity: 0;
}

.slide-menu-enter-active .unified-menu__content,
.slide-menu-leave-active .unified-menu__content {
  transition: transform 0.3s;
}

.slide-menu-enter-from .unified-menu__content,
.slide-menu-leave-to .unified-menu__content {
  transform: translateX(100%);
}

/* Responsividade header unificado */
@media (max-width: 768px) {
  .unified-header__container {
    padding: 0.75rem 1rem;
  }
  
  .unified-header__title {
    font-size: 0.95rem;
  }
  
  .unified-header__logo {
    height: 28px;
  }
  
  .unified-header__player {
    font-size: 0.85rem;
    padding: 0.4rem 0.75rem;
    gap: 0.4rem;
  }
  
  /* Dev Mode Badge Mobile */
  .unified-header__dev-badge {
    padding: 0.4rem 0.75rem !important;
    font-size: 0.75rem !important;
    margin-left: 0.5rem !important;
  }
  
  .unified-header__dev-text {
    display: none !important; /* Mostra só o ícone no mobile */
  }
  
  .unified-header__dev-badge i {
    font-size: 0.9rem !important;
  }
  
  /* Card flutuante mobile - Design compacto */
  .user-floating-card {
    min-width: auto;
    max-width: calc(100vw - 1.5rem);
    width: auto;
    padding: 0.75rem 1rem;
    margin-top: 0.5rem;
    top: 60px;
    border-radius: 12px;
    gap: 0.75rem;
    left: 0.75rem;
    right: 0.75rem;
    transform: none;
  }
  
  .user-floating-card__avatar {
    width: 40px;
    height: 40px;
  }
  
  .user-floating-card__avatar i {
    font-size: 1.5rem;
  }
  
  .user-floating-card__name {
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
  }
  
  .user-floating-card__stats {
    font-size: 0.75rem;
  }
  
  .user-floating-card__stats i {
    font-size: 0.75rem;
  }
  
  .unified-header__hamburger {
    width: 32px;
    height: 32px;
    padding: 4px;
  }
  
  .unified-header__hamburger span {
    width: 20px;
    height: 2px;
  }
  
  .unified-header__hamburger span:nth-child(1) {
    top: 8px;
  }
  
  .unified-header__hamburger span:nth-child(2) {
    top: 15px;
  }
  
  .unified-header__hamburger span:nth-child(3) {
    top: 22px;
  }
  
  .unified-menu__content {
    max-width: 100%;
  }
}

/* =============================================
   CONFIGURAÇÕES DE TIPOGRAFIA
   ============================================= */

/* Font Size Classes */
body.font-size-small {
  font-size: var(--font-size-small) !important;
}

body.font-size-medium {
  font-size: var(--font-size-medium) !important;
}

body.font-size-large {
  font-size: var(--font-size-large) !important;
}

body.font-size-xlarge {
  font-size: var(--font-size-xlarge) !important;
}

/* Font Family Classes */
body.font-family-system {
  font-family: var(--font-family-system) !important;
}

body.font-family-serif {
  font-family: var(--font-family-serif) !important;
}

body.font-family-monospace {
  font-family: var(--font-family-monospace) !important;
}

body.font-family-custom {
  font-family: var(--font-family-custom) !important;
}

/* Animations Toggle */
body.animations-disabled * {
  animation: none !important;
  transition: none !important;
}

/* Compact Mode */
body.compact-mode {
  --spacing-xs: 0.125rem;
  --spacing-sm: 0.25rem;
  --spacing-md: 0.5rem;
  --spacing-lg: 0.75rem;
  --spacing-xl: 1rem;
  --spacing-2xl: 1.5rem;
}

body.compact-mode .container {
  padding: 10px !important;
}

body.compact-mode .card,
body.compact-mode .config-group,
body.compact-mode .favorite-field-card {
  padding: 12px !important;
  margin-bottom: 10px !important;
}

body.compact-mode .config-section {
  margin-bottom: 20px !important;
}

body.compact-mode h1, 
body.compact-mode h2, 
body.compact-mode h3 {
  margin-bottom: 10px !important;
}

body.compact-mode .evolution-card,
body.compact-mode .stat-card {
  padding: 15px !important;
}

body.compact-mode .config-grid {
  gap: 15px !important;
}

/* ========================================
   Debug Tools Styles
   ======================================== */

/* Debug Panel */
#debug-panel {
    position: fixed;
    top: 80px;
    right: 20px;
    width: 300px;
    background: rgba(0, 0, 0, 0.95);
    border: 1px solid #333;
    border-radius: 8px;
    z-index: 10000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    font-family: 'Courier New', monospace;
    font-size: 12px;
}

.debug-panel__header {
    padding: 10px 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px 8px 0 0;
    color: white;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.debug-panel__content {
    padding: 15px;
    max-height: 400px;
    overflow-y: auto;
}

.debug-item {
    padding: 8px 0;
    border-bottom: 1px solid #333;
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

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

.debug-item strong {
    color: #667eea;
}

.debug-item span {
    color: #10b981;
    word-break: break-all;
}

/* Performance Panel */
#performance-panel {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 250px;
    background: rgba(0, 0, 0, 0.95);
    border: 1px solid #333;
    border-radius: 8px;
    z-index: 10000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    font-family: 'Courier New', monospace;
    font-size: 12px;
}

.perf-panel__header {
    padding: 10px 15px;
    background: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
    border-radius: 8px 8px 0 0;
    color: white;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.perf-panel__content {
    padding: 15px;
}

.perf-item {
    padding: 6px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.perf-item strong {
    color: #f59e0b;
}

.perf-item span {
    color: white;
    font-weight: bold;
}

/* Error Notifications */
#error-notifications {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10001;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
}

.error-notification {
    background: rgba(239, 68, 68, 0.95);
    color: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    animation: slideInRight 0.3s ease;
    transition: opacity 0.3s ease;
}

.error-notification__icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.error-notification__message {
    flex: 1;
    font-size: 0.875rem;
    line-height: 1.4;
    word-break: break-word;
}

.error-notification__close {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 1.5rem;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    transition: opacity 0.2s;
    flex-shrink: 0;
}

.error-notification__close:hover {
    opacity: 1;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* =============================================
   TOURNAMENT BADGES
   ============================================= */

.tournament-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.8rem;
    border-radius: var(--border-radius-md);
    border: 2px solid;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all var(--transition-fast);
    margin-left: 0.5rem;
}

.tournament-badge i {
    font-size: 1rem;
}

.tournament-badge:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.tournament-tier {
    font-weight: 700;
    letter-spacing: 0.5px;
}

.tournament-category {
    text-transform: uppercase;
    font-size: 0.75rem;
    opacity: 0.9;
}

/* Badges por categoria */
.tournament-badge--copper {
    --tournament-color: #CD7F32;
}

.tournament-badge--silver {
    --tournament-color: #C0C0C0;
}

.tournament-badge--gold {
    --tournament-color: #FFD700;
}

.tournament-badge--platinum {
    --tournament-color: #E5E4E2;
}

.tournament-badge--champion {
    --tournament-color: #9966FF;
}

.tournament-badge--legend {
    --tournament-color: #FF4500;
}

/* Badge em cards */
.card-header .tournament-badge {
    float: right;
    margin: 0;
}

/* Badge em listagens */
.record-item .tournament-badge {
    margin-left: auto;
}

/* =============================================
   TOURNAMENT TABS
   ============================================= */

.tournament-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid var(--color-border);
}

.tournament-tab {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    color: var(--color-text-muted);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    position: relative;
    bottom: -2px;
}

.tournament-tab:hover {
    color: var(--color-text);
    background: var(--color-surface);
}

.tournament-tab.active {
    color: var(--color-primary);
    border-bottom-color: var(--color-primary);
}

.tournament-tab i {
    margin-right: 0.5rem;
}

.tournament-tab .badge {
    margin-left: 0.5rem;
    padding: 0.2rem 0.5rem;
    border-radius: var(--border-radius-sm);
    background: var(--color-surface);
    font-size: 0.75rem;
}

/* =============================================
   TOURNAMENT FILTERS
   ============================================= */

.tournament-filters {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: var(--color-surface);
    border-radius: var(--border-radius-md);
}

.tournament-filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.tournament-filter-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-text-muted);
}

.tournament-category-pills {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tournament-category-pill {
    padding: 0.5rem 1rem;
    border: 2px solid;
    background: transparent;
    border-radius: var(--border-radius-lg);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-weight: 600;
    font-size: 0.85rem;
}

.tournament-category-pill:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.tournament-category-pill.active {
    background: var(--tournament-color);
    color: white;
}

.tournament-category-pill--copper {
    --tournament-color: #CD7F32;
    border-color: #CD7F32;
    color: #CD7F32;
}

.tournament-category-pill--silver {
    --tournament-color: #C0C0C0;
    border-color: #C0C0C0;
    color: #C0C0C0;
}

.tournament-category-pill--gold {
    --tournament-color: #FFD700;
    border-color: #FFD700;
    color: #FFD700;
}

.tournament-category-pill--platinum {
    --tournament-color: #E5E4E2;
    border-color: #E5E4E2;
    color: #E5E4E2;
}

.tournament-category-pill--champion {
    --tournament-color: #9966FF;
    border-color: #9966FF;
    color: #9966FF;
}

.tournament-category-pill--legend {
    --tournament-color: #FF4500;
    border-color: #FF4500;
    color: #FF4500;
}

/* =============================================
   NOTA: Tema Hotel California
   ============================================= */
/* O tema 'hotel' é gerado AUTOMATICAMENTE por api/themes-css.php
   a partir de config/theme_manager.php (FONTE ÚNICA).
   NÃO adicione estilos hardcoded aqui. */

/* =============================================
   REGL-003: Classes Utilitárias
   Substituem CSS inline em todas páginas
   ============================================= */

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.2;
}

.badge--primary {
    color: var(--color-primary);
    background: color-mix(in srgb, var(--color-primary) 10%, transparent);
    border: 1px solid color-mix(in srgb, var(--color-primary) 30%, transparent);
}

.badge--success {
    color: var(--color-success);
    background: color-mix(in srgb, var(--color-success) 10%, transparent);
    border: 1px solid color-mix(in srgb, var(--color-success) 30%, transparent);
}

.badge--error, .badge--danger {
    color: var(--color-error);
    background: color-mix(in srgb, var(--color-error) 10%, transparent);
    border: 1px solid color-mix(in srgb, var(--color-error) 30%, transparent);
}

.badge--warning {
    color: var(--color-warning);
    background: color-mix(in srgb, var(--color-warning) 10%, transparent);
    border: 1px solid color-mix(in srgb, var(--color-warning) 30%, transparent);
}

.badge--info {
    color: var(--color-info);
    background: color-mix(in srgb, var(--color-info) 10%, transparent);
    border: 1px solid color-mix(in srgb, var(--color-info) 30%, transparent);
}

.badge--muted {
    color: var(--color-text-muted);
    background: color-mix(in srgb, var(--color-text-muted) 10%, transparent);
    border: 1px solid var(--color-border);
}

/* Textos */
.text-primary { color: var(--color-primary) !important; }
.text-secondary { color: var(--color-secondary) !important; }
.text-muted { color: var(--color-text-muted) !important; }
.text-success { color: var(--color-success) !important; }
.text-error, .text-danger { color: var(--color-error) !important; }
.text-warning { color: var(--color-warning) !important; }
.text-info { color: var(--color-info) !important; }

/* Backgrounds */
.bg-surface { background-color: var(--color-surface) !important; }
.bg-background { background-color: var(--color-background) !important; }
.bg-primary-subtle { background-color: color-mix(in srgb, var(--color-primary) 10%, transparent) !important; }
.bg-success-subtle { background-color: color-mix(in srgb, var(--color-success) 10%, transparent) !important; }
.bg-error-subtle, .bg-danger-subtle { background-color: color-mix(in srgb, var(--color-error) 10%, transparent) !important; }
.bg-warning-subtle { background-color: color-mix(in srgb, var(--color-warning) 10%, transparent) !important; }

/* Borders */
.border-primary { border-color: var(--color-primary) !important; }
.border-success { border-color: var(--color-success) !important; }
.border-error, .border-danger { border-color: var(--color-error) !important; }
.border-warning { border-color: var(--color-warning) !important; }
.border-muted { border-color: var(--color-border) !important; }

/* Status Indicators */
.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 6px;
}

.status-dot--success { background-color: var(--color-success); }
.status-dot--error, .status-dot--danger { background-color: var(--color-error); }
.status-dot--warning { background-color: var(--color-warning); }
.status-dot--info { background-color: var(--color-info); }
.status-dot--muted { background-color: var(--color-text-muted); }

/* Gradientes (para ícones/headers) */
.gradient-primary {
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
}

.gradient-success {
    background: linear-gradient(135deg, var(--color-success), #059669);
}

.gradient-warning {
    background: linear-gradient(135deg, var(--color-warning), #d97706);
}

.gradient-error, .gradient-danger {
    background: linear-gradient(135deg, var(--color-error), #dc2626);
}

/* Form Elements */
.form-input, .form-select {
    width: 100%;
    padding: 0.5rem;
    margin-bottom: 0.5rem;
    border: 1px solid var(--color-border);
    background: var(--color-background);
    color: var(--color-text);
    border-radius: 4px;
}

.form-select {
    cursor: pointer;
}

.form-input:focus, .form-select:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Utilitários de Display */
.d-flex { display: flex !important; }
.align-center { align-items: center !important; }
.justify-center { justify-content: center !important; }
.justify-between { justify-content: space-between !important; }

/* =============================================
   LANGUAGE SELECTOR
   ============================================= */

.language-selector {
    position: relative;
    display: inline-block;
}

.lang-button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: var(--color-card-bg);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    color: var(--color-text);
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.lang-button:hover {
    background: var(--color-hover-bg);
    border-color: var(--color-primary);
}

.lang-button .fa-globe {
    font-size: 1.1rem;
    color: var(--color-primary);
}

.lang-code {
    font-weight: 600;
    min-width: 35px;
}

.lang-button .fa-chevron-down {
    font-size: 0.75rem;
    transition: transform 0.2s ease;
}

.lang-button .fa-chevron-down.rotate {
    transform: rotate(180deg);
}

.lang-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--color-card-bg);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    min-width: 200px;
    z-index: 9999;
    overflow: hidden;
    animation: dropdownFadeIn 0.2s ease;
}

@keyframes dropdownFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.15s ease;
    border-bottom: 1px solid var(--color-border);
}

.lang-option:last-child {
    border-bottom: none;
}

.lang-option:hover {
    background: var(--color-hover-bg);
}

.lang-option.active {
    background: rgba(var(--color-primary-rgb), 0.1);
}

.lang-option .flag {
    font-size: 1.5rem;
    line-height: 1;
}

.lang-option .lang-name {
    flex: 1;
    font-size: 0.95rem;
    color: var(--color-text);
}

.lang-option .fa-check {
    color: var(--color-success);
    font-size: 0.9rem;
}
.gap-sm { gap: 0.5rem !important; }
.gap-md { gap: 1rem !important; }
.gap-lg { gap: 1.5rem !important; }

/* Fallback para navegadores sem color-mix */
@supports not (background: color-mix(in srgb, red 10%, transparent)) {
    .badge--primary { background: rgba(59, 130, 246, 0.1); border-color: rgba(59, 130, 246, 0.3); }
    .badge--success { background: rgba(16, 185, 129, 0.1); border-color: rgba(16, 185, 129, 0.3); }
    .badge--error, .badge--danger { background: rgba(239, 68, 68, 0.1); border-color: rgba(239, 68, 68, 0.3); }
    .badge--warning { background: rgba(245, 158, 11, 0.1); border-color: rgba(245, 158, 11, 0.3); }
    .bg-primary-subtle { background: rgba(59, 130, 246, 0.1); }
    .bg-success-subtle { background: rgba(16, 185, 129, 0.1); }
    .bg-error-subtle, .bg-danger-subtle { background: rgba(239, 68, 68, 0.1); }
    .bg-warning-subtle { background: rgba(245, 158, 11, 0.1); }
}