/* ==========================================================================
   Dr. Jairo Sánchez — Tokens, reset y tipografía
   Fuente de verdad: base.css (valores Figma @1183px) + design_system.css.
   Los tamaños decimales de Figma se convierten a clamp() entre 375px y 1183px:
   en desktop coinciden al píxel con el diseño, en móvil escalan.
   ========================================================================== */

:root {
  /* ---------- Color: marca ---------- */
  --c-primary: #005293;
  --c-primary-rgb: 0, 82, 147;
  --c-primary-hover: #003e70;
  --c-primary-active: #002c50;
  --c-navy: #06375c;
  --c-navy-card: #07375b;

  /* ---------- Color: texto ---------- */
  --c-heading: #17313d;
  --c-body: #5c6f76;
  --c-muted: #637276;
  --c-placeholder: #757575;
  --c-checkbox-border: #767676;
  --c-error: #b42318;
  --c-success: #067647;

  /* ---------- Color: superficies ---------- */
  --c-white: #ffffff;
  --c-surface: #f5f5f5;
  --c-header-bg: rgba(255, 255, 255, 0.92);

  /* ---------- Alphas de marca ---------- */
  --c-primary-8: rgba(var(--c-primary-rgb), 0.08);
  --c-primary-10: rgba(var(--c-primary-rgb), 0.10);
  --c-primary-14: rgba(var(--c-primary-rgb), 0.14);
  --c-input-border: rgba(99, 114, 118, 0.35);

  /* ---------- Blancos translúcidos (fondos oscuros) ---------- */
  --c-white-6: rgba(255, 255, 255, 0.06);
  --c-white-8: rgba(255, 255, 255, 0.08);
  --c-white-9: rgba(255, 255, 255, 0.09);
  --c-white-10: rgba(255, 255, 255, 0.10);
  --c-white-14: rgba(255, 255, 255, 0.14);
  --c-white-18: rgba(255, 255, 255, 0.18);
  --c-white-62: rgba(255, 255, 255, 0.62);
  --c-white-72: rgba(255, 255, 255, 0.72);
  --c-white-78: rgba(255, 255, 255, 0.78);
  --c-white-86: rgba(255, 255, 255, 0.86);
  --c-white-90: rgba(255, 255, 255, 0.90);

  /* ---------- Gradientes ---------- */
  --g-navy: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0) 100%), var(--c-navy);
  --g-form-section: radial-gradient(60% 55% at 12% 20%, rgba(var(--c-primary-rgb), 0.09) 0%, rgba(var(--c-primary-rgb), 0) 70%), var(--c-white);

  /* ---------- Tipografía ---------- */
  --ff-heading: "Montserrat", system-ui, -apple-system, sans-serif;
  --ff-body: "Open Sans", system-ui, -apple-system, sans-serif;
  --fw-regular: 400;
  --fw-semibold: 600;
  --fw-bold: 700;

  /* Escala fluida (min @375px → max @1183px = valor Figma) */
  --fs-h1: clamp(2.25rem, 1.476rem + 3.304vw, 3.919rem);     /* 36 → 62.7 */
  --lh-h1: 0.96;
  --ls-h1: -0.055em;
  --fs-h2: clamp(1.875rem, 1.236rem + 2.729vw, 3.253rem);    /* 30 → 52.05 */
  --lh-h2: 1.08;
  --ls-h2: -0.04em;
  --fs-h3: clamp(1.25rem, 1.171rem + 0.337vw, 1.42rem);      /* 20 → 22.72 */
  --lh-h3: 1.25;
  --ls-h3: -0.02em;
  --fs-card-lg: clamp(1.25rem, 1.105rem + 0.619vw, 1.5625rem); /* 20 → 25 */
  --fs-lead-xl: clamp(1rem, 0.88rem + 0.51vw, 1.256rem);     /* 16 → 20.09 */
  --fs-lead-card: clamp(1rem, 0.884rem + 0.495vw, 1.25rem);  /* 16 → 20 */
  --fs-lead: clamp(1rem, 0.96rem + 0.17vw, 1.08rem);         /* 16 → 17.28 */
  --fs-body: 1rem;
  --lh-body: 1.7;
  --fs-nav: 0.9rem;          /* 14.4 */
  --fs-btn-sm: 0.88rem;      /* 14.08 */
  --fs-note: 0.86rem;        /* 13.76 */
  --fs-helper: 0.85rem;      /* 13.6 */
  --fs-card-link: 0.833rem;  /* 13.33 */
  --fs-chip: 0.82rem;        /* 13.12 */
  --fs-eyebrow: 0.78rem;     /* 12.48 */
  --ls-eyebrow: 0.12em;
  --fs-eyebrow-hero: 0.77rem;/* 12.32 */
  --ls-eyebrow-hero: 0.14em;

  /* ---------- Layout ---------- */
  --container: 1041px;
  --gutter-x: clamp(20px, 5vw, 71px);   /* margen lateral de la página */
  --gap-cols: clamp(32px, 6vw, 71px);   /* separación entre columnas de 2-col */
  --measure-heading: 760px;
  --header-h: 118px;
  --header-h-compact: 78px;

  --section-py: clamp(44px, 5vw, 50px);

  /* ---------- Espaciado ---------- */
  --space-7: 7px;
  --space-11: 11px;
  --space-12: 12px;
  --space-14: 14px;
  --space-16: 16px;
  --space-17: 17px;
  --space-24: 24px;
  --space-26: 26px;
  --space-28: 28px;
  --space-30: 30px;
  --space-34: 34px;
  --space-56: clamp(32px, 5vw, 56px);

  /* ---------- Radios ---------- */
  --r-pill: 999px;
  --r-xl: 28px;
  --r-lg: 24px;
  --r-md: 14px;
  --r-sm: 11px;
  --r-checkbox: 3px;

  /* ---------- Sombras ---------- */
  --sh-header: 0 10px 30px rgba(20, 51, 68, 0.07);
  --sh-card: 0 18px 48px rgba(14, 49, 70, 0.08);
  --sh-card-hover: 0 24px 60px rgba(14, 49, 70, 0.13);
  --sh-elevated: 0 24px 70px rgba(20, 51, 68, 0.12);
  --sh-btn-primary: 0 12px 25px rgba(var(--c-primary-rgb), 0.2);
  --sh-btn-white-hero: 0 16px 34px rgba(0, 0, 0, 0.2);
  --sh-whatsapp: 0 0 0 5.18px rgba(var(--c-primary-rgb), 0.125), 0 12px 28px rgba(var(--c-primary-rgb), 0.28);
  --sh-focus: 0 0 0 3px rgba(var(--c-primary-rgb), 0.28);

  /* ---------- Bordes ---------- */
  --b-hairline: 1px solid var(--c-primary-14);
  --b-card: 1px solid var(--c-primary-10);
  --b-input: 1px solid var(--c-input-border);

  /* ---------- Movimiento ---------- */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --t-fast: 0.18s ease;
  --t-base: 0.3s var(--ease-out);
}

/* ==========================================================================
   RESET
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h-compact) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--c-white);
  color: var(--c-body);
  font: var(--fw-regular) var(--fs-body)/var(--lh-body) var(--ff-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
p { margin: 0; }

h1, h2, h3 {
  margin: 0;
  font-family: var(--ff-heading);
  font-weight: var(--fw-semibold);
  color: var(--c-heading);
}
h1 { font-size: var(--fs-h1); line-height: var(--lh-h1); letter-spacing: var(--ls-h1); }
h2 { font-size: var(--fs-h2); line-height: var(--lh-h2); letter-spacing: var(--ls-h2); }
h3 { font-size: var(--fs-h3); line-height: var(--lh-h3); letter-spacing: var(--ls-h3); }

:focus-visible { outline: 2px solid var(--c-primary); outline-offset: 3px; }

.skip-link {
  position: fixed; top: 12px; left: 12px; z-index: 100;
  padding: 10px 16px; border-radius: var(--r-pill);
  background: var(--c-primary); color: var(--c-white); text-decoration: none;
  transform: translateY(-160%); transition: transform var(--t-fast);
}
.skip-link:focus { transform: none; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* ==========================================================================
   LAYOUT
   ========================================================================== */
.container {
  width: min(var(--container), 100% - 2 * var(--gutter-x));
  margin-inline: auto;
}

.section { padding-block: var(--section-py); overflow-x: clip; }
.section--surface { background: var(--c-surface); }
.section--navy { background: var(--g-navy); color: var(--c-white); }
.section--navy h2, .section--navy h3 { color: var(--c-white); }
.section--bordered { border-block: var(--b-hairline); }

.section-head { max-width: var(--measure-heading); }
.section-head .h2,
.section-head h2 { padding-top: var(--space-17); }
.section-head .lead { padding-top: var(--space-17); }
.section-head--wide { max-width: 930px; }

.lead { font-size: var(--fs-lead); line-height: 1.7; color: var(--c-body); }

.stack-center { display: flex; justify-content: center; }
