/* style.css — OAKSL Design System: Navy/Gold/White Custom Palette */

/* ── Type Scale ─────────────────────────────────── */
:root {
  --text-xs:   clamp(0.75rem,  0.7rem  + 0.25vw, 0.875rem);
  --text-sm:   clamp(0.875rem, 0.8rem  + 0.35vw, 1rem);
  --text-base: clamp(1rem,     0.9rem  + 0.5vw,  1.125rem);
  --text-lg:   clamp(1.125rem, 0.95rem + 0.85vw, 1.5rem);
  --text-xl:   clamp(1.5rem,   1rem    + 1.5vw,  2.25rem);
  --text-2xl:  clamp(2rem,     1.2rem  + 2.5vw,  3.5rem);
  --text-3xl:  clamp(2.5rem,   1rem    + 4vw,    5rem);
  --text-hero: clamp(3rem,     0.5rem  + 7vw,    8rem);

  /* ── Spacing (4px base) ────────────────────────── */
  --space-1:  0.25rem;
  --space-2:  0.5rem;
  --space-3:  0.75rem;
  --space-4:  1rem;
  --space-5:  1.25rem;
  --space-6:  1.5rem;
  --space-8:  2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* ── Typography ────────────────────────────────── */
  --font-display: 'Plus Jakarta Sans', 'Inter', sans-serif;
  --font-body: 'Plus Jakarta Sans', 'Inter', sans-serif;

  /* ── Radius ────────────────────────────────────── */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-full: 9999px;

  /* ── Transitions ───────────────────────────────── */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);

  /* ── Content widths ────────────────────────────── */
  --content-narrow: 640px;
  --content-default: 960px;
  --content-wide: 1200px;
  --content-full: 100%;
}

/* ── LIGHT MODE (Navy/Gold/White) ─────────────────── */
:root, [data-theme="light"] {
  /* Surfaces */
  --color-bg:               #FFFFFF;
  --color-surface:          #F5F7FA;
  --color-surface-2:        #EEF1F6;
  --color-surface-offset:   #E8ECF1;
  --color-surface-offset-2: #DFE4EB;
  --color-surface-dynamic:  #D5DAE3;
  --color-divider:          #D0D5DE;
  --color-border:           #C5CBD6;

  /* Text */
  --color-text:           #1A1A2E;
  --color-text-muted:     #6B7280;
  --color-text-faint:     #9CA3AF;
  --color-text-inverse:   #FFFFFF;

  /* Primary Accent (Gold) */
  --color-primary:         #C8A45C;
  --color-primary-hover:   #D4B76A;
  --color-primary-active:  #B8944C;
  --color-primary-highlight: #F5F0E2;

  /* Navy (used for dark sections, headers, cards) */
  --color-navy:            #0F2847;
  --color-navy-deep:       #0A1628;
  --color-navy-light:      #1A3A5C;

  /* Semantic */
  --color-error:           #DC2626;
  --color-success:         #16A34A;
  --color-warning:         #D97706;

  /* Shadows */
  --shadow-sm: 0 1px 2px oklch(0.2 0.02 250 / 0.06);
  --shadow-md: 0 4px 12px oklch(0.2 0.02 250 / 0.08);
  --shadow-lg: 0 12px 32px oklch(0.2 0.02 250 / 0.12);
}

/* ── DARK MODE (Deep Navy) ────────────────────────── */
[data-theme="dark"] {
  /* Surfaces */
  --color-bg:               #0A1628;
  --color-surface:          #0F2847;
  --color-surface-2:        #142F52;
  --color-surface-offset:   #1A3A5C;
  --color-surface-offset-2: #204567;
  --color-surface-dynamic:  #2A5070;
  --color-divider:          #1E3B5E;
  --color-border:           #2A4A6E;

  /* Text */
  --color-text:           #E8ECF1;
  --color-text-muted:     #9CA3AF;
  --color-text-faint:     #6B7280;
  --color-text-inverse:   #0A1628;

  /* Primary Accent (Gold — consistent across modes) */
  --color-primary:         #C8A45C;
  --color-primary-hover:   #D4B76A;
  --color-primary-active:  #B8944C;
  --color-primary-highlight: #1E2A3A;

  /* Navy */
  --color-navy:            #0F2847;
  --color-navy-deep:       #0A1628;
  --color-navy-light:      #1A3A5C;

  /* Semantic */
  --color-error:           #EF4444;
  --color-success:         #22C55E;
  --color-warning:         #F59E0B;

  /* Shadows */
  --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.2);
  --shadow-md: 0 4px 12px oklch(0 0 0 / 0.3);
  --shadow-lg: 0 12px 32px oklch(0 0 0 / 0.4);
}

/* System preference fallback */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg:               #0A1628;
    --color-surface:          #0F2847;
    --color-surface-2:        #142F52;
    --color-surface-offset:   #1A3A5C;
    --color-surface-offset-2: #204567;
    --color-surface-dynamic:  #2A5070;
    --color-divider:          #1E3B5E;
    --color-border:           #2A4A6E;
    --color-text:           #E8ECF1;
    --color-text-muted:     #9CA3AF;
    --color-text-faint:     #6B7280;
    --color-text-inverse:   #0A1628;
    --color-primary:         #C8A45C;
    --color-primary-hover:   #D4B76A;
    --color-primary-active:  #B8944C;
    --color-primary-highlight: #1E2A3A;
    --color-navy:            #0F2847;
    --color-navy-deep:       #0A1628;
    --color-navy-light:      #1A3A5C;
    --color-error:           #EF4444;
    --color-success:         #22C55E;
    --color-warning:         #F59E0B;
    --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.2);
    --shadow-md: 0 4px 12px oklch(0 0 0 / 0.3);
    --shadow-lg: 0 12px 32px oklch(0 0 0 / 0.4);
  }
}

/* ── Headings ─────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
}

h1 { font-size: var(--text-2xl); font-weight: 700; }
h2 { font-size: var(--text-xl); font-weight: 700; }
h3 { font-size: var(--text-lg); font-weight: 600; }
h4 { font-size: var(--text-base); font-weight: 600; }

/* ── Links ────────────────────────────────────────── */
a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-interactive);
}
a:hover {
  color: var(--color-primary-hover);
}
