/* ====================================================================
   HERA FIGHTWEAR — DESIGN SYSTEM & TOKENS
   Inspirado na força, disciplina e movimento do grappling e No-Gi
   ==================================================================== */

:root {
  /* Tipografia */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', Menlo, Monaco, Consolas, monospace;

  /* Espaçamentos (Base 4px / 8px) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;

  /* Estrutura responsiva */
  --sidebar-width: 272px;
  --header-height: 72px;
  --content-max-width: 1920px;

  /* Raios de Borda */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-full: 9999px;

  /* Transições Suaves */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
  --transition-slow: 0.4s ease;

  /* Cores Globais da Marca HERA */
  --hera-gold: #d7a83f;
  --hera-gold-hover: #e7bc61;
  --hera-gold-dark: #97691c;
  --hera-gold-light: #fbf0d1;
  --hera-gold-glow: rgba(215, 168, 63, 0.24);
  --hera-obsidian: #08090b;
  
  --color-success: #10b981;
  --color-success-bg: rgba(16, 185, 129, 0.12);
  --color-danger: #ef4444;
  --color-danger-bg: rgba(239, 68, 68, 0.12);
  --color-warning: #f59e0b;
  --color-warning-bg: rgba(245, 158, 11, 0.12);
  --color-info: #3b82f6;
  --color-info-bg: rgba(59, 130, 246, 0.12);
}

/* ====================================================================
   TEMA ESCURO (PADRÃO PRINCIPAL DA HERA — TATAME NOTURNO)
   ==================================================================== */
[data-theme="dark"],
:root:not([data-theme="light"]) {
  --bg-page: #0a0b0e;
  --bg-surface: #121318;
  --bg-surface-elevated: #1a1b21;
  --bg-input: #0e0f13;
  --bg-sidebar: #08090b;
  --bg-header: rgba(10, 11, 14, 0.88);

  --border-color: #292a31;
  --border-color-subtle: #1d1e24;
  --border-focus: var(--hera-gold);

  --text-primary: #f6f3ed;
  --text-secondary: #aaa7a0;
  --text-muted: #6f7078;
  --text-inverse: #0c0d10;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.6);

  --accent-primary: var(--hera-gold);
  --accent-hover: var(--hera-gold-hover);
  --accent-contrast: #0c0d10;
}

/* ====================================================================
   TEMA CLARO (PREMIUM DAYLIGHT)
   ==================================================================== */
[data-theme="light"] {
  --bg-page: #f7f5f0;
  --bg-surface: #ffffff;
  --bg-surface-elevated: #f1f5f9;
  --bg-input: #f8fafc;
  --bg-sidebar: #0f172a;
  --bg-header: rgba(255, 255, 255, 0.9);

  --border-color: #e2e8f0;
  --border-color-subtle: #edf2f7;
  --border-focus: #b77a17;

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --text-inverse: #ffffff;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.12);

  --accent-primary: #b77a17;
  --accent-hover: #8f5d11;
  --accent-contrast: #ffffff;
}

/* Reset Básico & Estilos Gerais */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  height: 100%;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-page);
  color: var(--text-primary);
  line-height: 1.5;
  min-height: 100%;
  transition: background-color var(--transition-normal), color var(--transition-normal);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection {
  background: var(--hera-gold);
  color: #0c0d10;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid var(--hera-gold-glow);
  outline-offset: 2px;
}

button:disabled,
input:disabled,
select:disabled,
textarea:disabled {
  cursor: not-allowed;
}

img,
svg {
  max-width: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
