/* ==========================================================================
   BASE.CSS · Tokens, reset, tipografía base, utilidades comunes
   ==========================================================================
   - Variables CSS (paleta, tipografía, layout)
   - Reset y normalización
   - Tipografía base (h1-h4, body)
   - Container, sections, eyebrow
   
   Cargado por TODAS las páginas del sitio.
   No tocar a la ligera: cambios aquí afectan a todas las páginas.
   ========================================================================== */

/* ==========================================================================
   FUENTES LOCALES · Hanken Grotesk + JetBrains Mono
   ==========================================================================
   Fuentes autohospedadas para que la web funcione sin conexión a Google Fonts.
   Beneficios: doble click funciona, mejor rendimiento, GDPR-friendly.
   Subset: latin solo (sin cyrillic, vietnamese, etc. — ahorra 80% de peso).
   Origen: Google Fonts vía @fontsource (mismo woff2, mismo glyph coverage).
   ========================================================================== */

/* === Hanken Grotesk · pesos normal === */
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('../fonts/hanken/300.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/hanken/400.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/hanken/500.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/hanken/600.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/hanken/700.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url('../fonts/hanken/800.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: normal;
  font-weight: 900;
  font-display: swap;
  src: url('../fonts/hanken/900.woff2') format('woff2');
}

/* === Hanken Grotesk · pesos italic === */
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/hanken/400-italic.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: italic;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/hanken/500-italic.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: italic;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/hanken/600-italic.woff2') format('woff2');
}
@font-face {
  font-family: 'Hanken Grotesk';
  font-style: italic;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/hanken/700-italic.woff2') format('woff2');
}

/* === JetBrains Mono === */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/jetbrains/400.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/jetbrains/500.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/jetbrains/600.woff2') format('woff2');
}

:root {
  --c-deep: #021519;
  --c-ink: #032128;
  --c-ink-2: #073038;
  --c-ink-3: #0d4048;
  --c-mint: #C9A84C;
  --c-mint-soft: #E2C97E;
  --c-mint-mid: #D4B65F;
  --c-mint-deep: #A8862E;
  --c-mint-glow: rgba(201, 168, 76, 0.5);
  --c-paper: #f4faf6;
  --c-bone: #ecf3ee;
  --c-grey-100: #c8d2cd;
  --c-grey-300: #8a9d97;
  --c-grey-500: #5a6e68;
  --c-grey-700: #2e423d;
  --ff-sans: 'Hanken Grotesk', system-ui, -apple-system, sans-serif;
  --ff-mono: 'JetBrains Mono', ui-monospace, monospace;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --container: 1320px;
  --gutter: clamp(20px, 4vw, 56px);
  --r-md: 12px;
  --r-lg: 18px;
  --r-xl: 24px;
  --r-2xl: 32px;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--ff-sans);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  color: var(--c-bone);
  background: var(--c-ink);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul { list-style: none; }
input, textarea { font: inherit; }
::selection { background: var(--c-mint); color: var(--c-ink); }

body::after {
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 9990; opacity: .025;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .9 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.section { position: relative; padding: clamp(80px, 11vh, 140px) 0; }
.section--paper { background: var(--c-paper); color: var(--c-ink); }
.section--mint { background: var(--c-mint); color: var(--c-ink); }
.section--bone { background: var(--c-bone); color: var(--c-ink); }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--ff-mono); font-weight: 500; font-size: 11px;
  letter-spacing: .12em; text-transform: uppercase; color: var(--c-mint);
}
.eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--c-mint);
  box-shadow: 0 0 10px var(--c-mint), 0 0 4px var(--c-mint);
  animation: pulse 2s ease-in-out infinite;
}
.section--paper .eyebrow, .section--bone .eyebrow { color: var(--c-mint-deep); }
.section--paper .eyebrow .dot, .section--bone .eyebrow .dot { background: var(--c-mint-deep); box-shadow: 0 0 8px var(--c-mint-deep); }
.section--mint .eyebrow { color: var(--c-ink); }
.section--mint .eyebrow .dot { background: var(--c-ink); box-shadow: none; }
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .4; transform: scale(.65); }
}

h1, h2, h3, h4 {
  font-family: var(--ff-sans); font-weight: 700;
  letter-spacing: -.02em; line-height: 1; color: var(--c-bone);
}
.section--paper h1, .section--paper h2, .section--paper h3, .section--paper h4,
.section--bone h1, .section--bone h2, .section--bone h3, .section--bone h4 { color: var(--c-ink); }
.section--mint h1, .section--mint h2, .section--mint h3, .section--mint h4 { color: var(--c-ink); }
.italic { font-style: italic; font-weight: 600; }

.section-head { display: grid; grid-template-columns: 1fr; gap: 28px; margin-bottom: 56px; }
@media (min-width: 1024px) { .section-head { grid-template-columns: 1.4fr 1fr; gap: 64px; align-items: end; } }
.section-head h2 {
  font-family: var(--ff-sans); font-weight: 700;
  font-size: clamp(40px, 5.4vw, 80px); line-height: 1; letter-spacing: -.035em;
}
.section-head h2 .italic { color: var(--c-mint); font-style: italic; font-weight: 600; }
.section--paper .section-head h2 .italic, .section--bone .section-head h2 .italic { color: var(--c-mint-deep); }
.section--mint .section-head h2 .italic { color: var(--c-ink); }
.section-head .lede { font-size: 17px; line-height: 1.55; color: var(--c-grey-100); max-width: 520px; }
.section-head .lede strong { color: var(--c-bone); font-weight: 600; }
.section--paper .section-head .lede, .section--bone .section-head .lede { color: var(--c-grey-700); }
.section--paper .section-head .lede strong, .section--bone .section-head .lede strong { color: var(--c-ink); }
.section--mint .section-head .lede { color: var(--c-ink); opacity: .8; }
.section--mint .section-head .lede strong { color: var(--c-ink); opacity: 1; }
