/* ============================================================
   TERRANOVA — BASE CSS
   Design Tokens, Typography, Resets
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800;900&family=Inter:wght@300;400;500;600;700&display=swap');

/* ── Design Tokens ───────────────────────────────────────── */
:root {
  /* Colors */
  --bg-deep:        #070B18;
  --bg-surface:     #0D1220;
  --bg-card:        #111827;
  --bg-card-hover:  #172031;
  --bg-glass:       rgba(13, 18, 32, 0.75);
  --bg-glass-light: rgba(255,255,255,0.05);

  --gold:           #C9A84C;
  --gold-light:     #E8C96A;
  --gold-muted:     rgba(201, 168, 76, 0.15);
  --gold-glow:      0 0 30px rgba(201, 168, 76, 0.25);

  --text-primary:   #F0EFEA;
  --text-secondary: #A8AABB;
  --text-muted:     #5A6070;
  --text-gold:      #C9A84C;

  --accent-green:   #22C55E;
  --accent-red:     #EF4444;
  --accent-blue:    #3B82F6;
  --accent-amber:   #F59E0B;
  --whatsapp:       #25D366;

  --border:         rgba(255,255,255,0.07);
  --border-gold:    rgba(201, 168, 76, 0.3);

  /* Spacing */
  --space-xs:  4px;
  --space-sm:  8px;
  --space-md:  16px;
  --space-lg:  24px;
  --space-xl:  32px;
  --space-2xl: 48px;
  --space-3xl: 64px;
  --space-4xl: 96px;

  /* Radius */
  --radius-sm:   6px;
  --radius-md:   12px;
  --radius-lg:   20px;
  --radius-xl:   28px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm:   0 2px 8px rgba(0,0,0,0.4);
  --shadow-md:   0 8px 32px rgba(0,0,0,0.5);
  --shadow-lg:   0 20px 60px rgba(0,0,0,0.6);
  --shadow-gold: 0 0 40px rgba(201, 168, 76, 0.2);

  /* Typography */
  --font-display: 'Outfit', sans-serif;
  --font-body:    'Inter', sans-serif;

  /* Transitions */
  --transition-fast:   150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow:   500ms cubic-bezier(0.4, 0, 0.2, 1);

  /* Z-index layers */
  --z-base:    1;
  --z-card:    10;
  --z-nav:     100;
  --z-modal:   200;
  --z-fab:     300;
  --z-tooltip: 400;
}

/* ── CSS Reset ───────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-deep);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

img, video {
  max-width: 100%;
  display: block;
}

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

ul, ol {
  list-style: none;
}

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

button {
  cursor: pointer;
  border: none;
  background: none;
}

/* ── Typography Scale ────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.display-xl { font-size: clamp(2.5rem, 7vw, 5rem);   font-weight: 800; }
.display-lg { font-size: clamp(2rem, 5vw, 3.5rem);   font-weight: 700; }
.display-md { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 700; }
.display-sm { font-size: clamp(1.25rem, 2vw, 1.75rem); font-weight: 600; }

.text-lg  { font-size: 1.125rem; }
.text-md  { font-size: 1rem; }
.text-sm  { font-size: 0.875rem; }
.text-xs  { font-size: 0.75rem; }

.text-gold    { color: var(--gold); }
.text-muted   { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-green   { color: var(--accent-green); }
.text-red     { color: var(--accent-red); }

.font-display { font-family: var(--font-display); }
.font-body    { font-family: var(--font-body); }

/* ── Utility Classes ─────────────────────────────────────── */
.flex        { display: flex; }
.flex-col    { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-sm      { gap: var(--space-sm); }
.gap-md      { gap: var(--space-md); }
.gap-lg      { gap: var(--space-lg); }

.w-full  { width: 100%; }
.h-full  { height: 100%; }

.hidden  { display: none !important; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
}

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

@media (min-width: 768px) {
  .container { padding: 0 var(--space-xl); }
}

/* ── Scrollbar ───────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-surface); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: var(--radius-full); }
::-webkit-scrollbar-thumb:hover { background: var(--gold-muted); }

/* ── Selection ───────────────────────────────────────────── */
::selection {
  background: var(--gold-muted);
  color: var(--gold-light);
}
