/* ==========================================================================
   Tradify · Hoja de estilos
   Mobile-first. Espaciado en múltiplos de 8 px.
   ========================================================================== */

/* ---------- 1. Tokens de marca ---------- */
:root {
  /* Colores */
  --night: #14213D;        /* Azul noche: principal, textos y logo */
  --action: #2F6FE0;       /* Azul acción: botones y enlaces */
  --action-hover: #1F55B8;
  --signal: #3D8BFF;       /* Azul señal: solo detalle del logo */
  --ink: #0B1226;          /* Tinta: texto principal */
  --slate: #5B6478;        /* Gris pizarra: texto secundario */
  --line: #E3E6EE;         /* Línea: bordes */
  --mist: #F5F6FA;         /* Niebla: fondos de sección */
  --white: #FFFFFF;
  --error: #C4253A;
  --error-light: #FFB3BE;  /* errores sobre fondos oscuros */
  --success: #1A7F4B;
  --whatsapp: #189D4E;

  /* Degradado aurora */
  --aurora:
    radial-gradient(ellipse 80% 90% at 10% 80%, #1D3B8C 0%, rgba(29, 59, 140, 0) 70%),
    radial-gradient(ellipse 70% 80% at 90% 20%, #3A1F8F 0%, rgba(58, 31, 143, 0) 70%),
    radial-gradient(ellipse 60% 60% at 100% 100%, #7A1680 0%, rgba(122, 22, 128, 0) 75%),
    #101A3A;

  /* Tipografía */
  --font-display: "Sora", system-ui, sans-serif;
  --font-body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;

  /* Radios */
  --r-control: 12px;
  --r-btn: 14px;
  --r-card: 24px;

  /* Sombras */
  --shadow-sm: 0 1px 2px rgba(11, 18, 38, .06), 0 2px 8px rgba(11, 18, 38, .04);
  --shadow-md: 0 8px 24px rgba(11, 18, 38, .08), 0 2px 8px rgba(11, 18, 38, .04);
  --shadow-lg: 0 24px 64px rgba(11, 18, 38, .12);

  --header-h: 72px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--night);
  margin: 0;
  line-height: 1.12;
  letter-spacing: -0.03em;
}
h1 { font-size: clamp(2.5rem, 7vw, 3.5rem); letter-spacing: -0.04em; line-height: 1.05; }
h2 { font-size: clamp(2rem, 5vw, 2.5rem); }
h3 { font-size: 1.375rem; }

p { margin: 0; }
a { color: var(--action); }
a:hover { color: var(--action-hover); }
img, svg { display: block; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }

/* Foco visible en todos los controles */
:focus-visible {
  outline: 3px solid var(--action);
  outline-offset: 3px;
  border-radius: 6px;
}
.aurora :focus-visible,
.site-header :focus-visible { outline-color: var(--white); }

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute;
  left: 16px; top: -64px;
  z-index: 100;
  padding: 8px 16px;
  background: var(--white);
  color: var(--night);
  border-radius: var(--r-control);
  font-weight: 600;
  text-decoration: none;
  transition: top .2s;
}
.skip-link:focus { top: 16px; }

.container {
  width: 100%;
  max-width: 1184px;
  margin-inline: auto;
  padding-inline: 20px;
}
.container--narrow { max-width: 816px; }

.icon {
  width: 24px; height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

/* ---------- 3. Fondos: aurora y cristal ---------- */
.aurora {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--aurora);
  color: var(--white);
}
.aurora h1, .aurora h2, .aurora h3 { color: var(--white); }

.glass {
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .28);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}

/* "t" gigante del logo como marca de agua */
.watermark {
  position: absolute;
  z-index: -1;
  right: -14%;
  top: 50%;
  width: min(110vw, 760px);
  height: auto;
  aspect-ratio: 58 / 70;
  color: rgba(255, 255, 255, .09);
  transform: translateY(-46%);
  pointer-events: none;
}
.watermark--final { right: -8%; width: min(90vw, 600px); transform: translateY(-50%); }

/* ---------- 4. Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 24px;
  border: 1px solid transparent;
  border-radius: var(--r-btn);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .2s, color .2s, border-color .2s, transform .2s var(--ease), box-shadow .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn .icon { width: 20px; height: 20px; }

.btn--primary { background: var(--action); color: var(--white); box-shadow: 0 8px 24px rgba(47, 111, 224, .32); }
.btn--primary:hover { background: var(--action-hover); color: var(--white); }

.btn--white { background: var(--white); color: var(--night); }
.btn--white:hover { background: #E9EEFB; color: var(--night); }

.btn--glass {
  background: rgba(255, 255, 255, .1);
  border-color: rgba(255, 255, 255, .36);
  color: var(--white);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}
.btn--glass:hover { background: rgba(255, 255, 255, .18); color: var(--white); }

.btn--outline { background: var(--white); border-color: var(--line); color: var(--night); }
.btn--outline:hover { border-color: var(--action); color: var(--action-hover); }

.btn--sm { min-height: 40px; padding: 8px 16px; font-size: .9375rem; border-radius: var(--r-control); }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .75; cursor: progress; transform: none; }

/* ---------- 5. Navegación ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  padding: 12px 12px 0;
  transition: padding .3s var(--ease);
}
.nav {
  position: relative;
  max-width: 1184px;
  margin-inline: auto;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 8px 8px 8px 16px;
  border-radius: 18px;
  color: var(--white);
  transition: background-color .3s, box-shadow .3s;
}
/* Al bajar de la portada, el cristal se oscurece para leerse sobre fondos claros */
.site-header.is-scrolled .nav {
  background: rgba(16, 26, 58, .78);
  box-shadow: 0 12px 32px rgba(11, 18, 38, .18);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--white);
  text-decoration: none;
}
.brand:hover { color: var(--white); }
.brand__icon { width: 36px; height: 36px; }
.brand__word {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: -0.04em;
  line-height: 1;
  padding-bottom: 2px;
}
.brand--dark, .brand--dark:hover { color: var(--night); }

.nav__tools { display: flex; align-items: center; gap: 8px; }

.lang-switch {
  display: inline-flex;
  padding: 3px;
  border-radius: var(--r-control);
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .24);
}
.lang-switch button {
  min-width: 40px;
  min-height: 34px;
  padding: 4px 8px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: rgba(255, 255, 255, .85);
  font-weight: 600;
  font-size: .875rem;
  letter-spacing: .02em;
  transition: background-color .2s, color .2s;
}
.lang-switch button:hover { color: var(--white); background: rgba(255, 255, 255, .1); }
.lang-switch button[aria-pressed="true"] { background: var(--white); color: var(--night); }

/* Botón hamburguesa */
.nav__toggle {
  width: 44px; height: 44px;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: var(--r-control);
  background: rgba(255, 255, 255, .08);
}
.nav__toggle span {
  width: 18px; height: 2px;
  border-radius: 2px;
  background: var(--white);
  transition: transform .25s var(--ease), opacity .2s;
}
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Menú móvil */
.nav__menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0; right: 0;
  display: none;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border-radius: 18px;
  background: rgba(16, 26, 58, .94);
  border: 1px solid rgba(255, 255, 255, .2);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow-lg);
}
.nav__menu.is-open { display: flex; }
.nav__links { display: flex; flex-direction: column; }
.nav__links a {
  display: block;
  padding: 12px 8px;
  color: var(--white);
  text-decoration: none;
  font-weight: 500;
  font-size: 1.0625rem;
  border-radius: 10px;
}
.nav__links a:hover { background: rgba(255, 255, 255, .08); color: var(--white); }
.nav__cta { margin-top: 8px; }

@media (min-width: 900px) {
  .site-header { padding: 16px 24px 0; }
  .nav { padding: 8px 8px 8px 20px; }
  .nav__toggle { display: none; }
  .nav__menu,
  .nav__menu.is-open {
    position: static;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 24px;
    margin-left: auto;
    padding: 0;
    background: none;
    border: 0;
    box-shadow: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .nav__links { flex-direction: row; gap: 4px; }
  .nav__links a { padding: 8px 12px; font-size: .9875rem; color: rgba(255, 255, 255, .88); }
  .nav__links a:hover { color: var(--white); }
  .nav__cta { margin-top: 0; order: 2; }
  .nav__tools { order: 3; }
}

/* ---------- 6. Hero ---------- */
.hero {
  padding: calc(var(--header-h) + 56px) 0 64px;
}
.hero__grid {
  display: grid;
  gap: 48px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  margin-bottom: 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .26);
  font-size: .875rem;
  font-weight: 500;
  color: rgba(255, 255, 255, .92);
}
.eyebrow::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 0 4px rgba(61, 139, 255, .25);
}
.hero__lead {
  margin-top: 24px;
  max-width: 34rem;
  font-size: 1.125rem;
  color: rgba(255, 255, 255, .84);
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
.hero__actions .btn { flex: 1 1 200px; }

/* Tarjeta de cotización rápida (cristal) */
.quick-quote {
  display: grid;
  gap: 16px;
  padding: 24px;
  border-radius: var(--r-card);
  background: rgba(255, 255, 255, .12);
  border-color: rgba(255, 255, 255, .32);
  box-shadow: 0 24px 64px rgba(5, 8, 30, .28);
}
.quick-quote__title { font-size: 1.375rem; }
.quick-quote__text { color: rgba(255, 255, 255, .8); font-size: .9375rem; margin-top: -8px; }
.quick-quote__pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

@media (min-width: 600px) {
  .container { padding-inline: 32px; }
  .hero__actions .btn { flex: 0 0 auto; }
}
@media (min-width: 960px) {
  .hero { padding: calc(var(--header-h) + 96px) 0 112px; }
  .hero__grid { grid-template-columns: 1.25fr .85fr; gap: 64px; }
  .quick-quote { padding: 32px; }
}

/* ---------- 7. Franja de idiomas ---------- */
.langs { border-bottom: 1px solid var(--line); background: var(--white); }
.langs__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px 24px;
  padding-block: 24px;
}
.langs__pair {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--night);
}
.langs__pair .icon { color: var(--action); }
.tag {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--mist);
  border: 1px solid var(--line);
  color: var(--slate);
  font-size: .875rem;
  font-weight: 500;
}

/* ---------- 8. Secciones ---------- */
.section { padding-block: 72px; }
.section--mist { background: var(--mist); }
.section__head { max-width: 640px; margin-bottom: 40px; }
.kicker {
  margin-bottom: 12px;
  color: var(--action);
  font-weight: 600;
  font-size: .875rem;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.section__lead { margin-top: 16px; color: var(--slate); font-size: 1.0625rem; }

@media (min-width: 960px) {
  .section { padding-block: 112px; }
  .section__head { margin-bottom: 56px; }
  .section__lead { font-size: 1.125rem; }
}

/* Tarjetas de servicios */
.cards { display: grid; gap: 16px; }
.card {
  padding: 32px 24px;
  border-radius: var(--r-card);
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease), box-shadow .3s, border-color .3s;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #CDD3E1;
}
.card__icon {
  display: grid;
  place-items: center;
  width: 56px; height: 56px;
  margin-bottom: 24px;
  border-radius: 16px;
  background: #EEF3FD;
  color: var(--action);
}
.card__icon .icon { width: 28px; height: 28px; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--slate); }

@media (min-width: 768px) {
  .cards { grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .card { padding: 40px 32px; }
}

/* Pasos */
.steps { display: grid; gap: 16px; counter-reset: none; }
.step {
  position: relative;
  padding: 32px 24px;
  border-radius: var(--r-card);
  background: var(--white);
  border: 1px solid var(--line);
}
.step__num {
  display: block;
  margin-bottom: 24px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 2.5rem;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--action);
}
.step h3 { margin-bottom: 8px; }
.step p { color: var(--slate); }

@media (min-width: 768px) {
  .steps { grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .step { padding: 40px 32px; }
}

/* ---------- 9. Cotización ---------- */
.quote { display: grid; gap: 40px; align-items: start; }
.checklist { display: grid; gap: 12px; margin-top: 32px; }
.checklist li {
  position: relative;
  padding-left: 32px;
  color: var(--ink);
  font-weight: 500;
}
.checklist li::before {
  content: "";
  position: absolute;
  left: 0; top: 2px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: #EEF3FD url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232F6FE0' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 12.5l3.2 3.2L17 9'/%3E%3C/svg%3E") center / 16px no-repeat;
}
.quote__card {
  padding: 24px 20px;
  border-radius: var(--r-card);
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
}

@media (min-width: 600px) { .quote__card { padding: 40px; } }
@media (min-width: 1024px) {
  .quote { grid-template-columns: .8fr 1.2fr; gap: 64px; }
  .quote__intro { position: sticky; top: calc(var(--header-h) + 48px); }
}

/* Campos de formulario */
.form__grid { display: grid; gap: 20px; }
@media (min-width: 600px) {
  .form__grid { grid-template-columns: 1fr 1fr; gap: 20px 16px; }
  .field--full { grid-column: 1 / -1; }
}

.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field > label, .label {
  font-weight: 600;
  font-size: .9375rem;
  color: var(--night);
}
.req { color: var(--error); }
.optional { font-weight: 400; color: var(--slate); }

.field input:not([type="checkbox"]):not([type="file"]),
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid #C9CFDC;
  border-radius: var(--r-control);
  background: var(--white);
  color: var(--ink);
  font-size: 1rem;
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 120px; }
.field select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235B6478' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px;
}
.field input::placeholder, .field textarea::placeholder { color: #8189A0; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #A9B1C4; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--action);
  box-shadow: 0 0 0 4px rgba(47, 111, 224, .2);
}
.field [aria-invalid="true"] { border-color: var(--error) !important; }
.field [aria-invalid="true"]:focus { box-shadow: 0 0 0 4px rgba(196, 37, 58, .18); }

.field__error {
  display: none;
  align-items: flex-start;
  gap: 6px;
  color: var(--error);
  font-size: .875rem;
  font-weight: 500;
}
.field__error:not(:empty) { display: flex; }
.field__error:not(:empty)::before {
  content: "";
  flex-shrink: 0;
  width: 16px; height: 16px;
  margin-top: 2px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23C4253A' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7.5v5.5M12 16.5v.01'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* Campos sobre cristal (tarjeta rápida del hero) */
.field--glass > label { color: rgba(255, 255, 255, .9); font-weight: 500; font-size: .875rem; }
.field--glass select {
  background-color: rgba(255, 255, 255, .1) !important;
  border-color: rgba(255, 255, 255, .3) !important;
  color: var(--white) !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23FFFFFF' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") !important;
}
.field--glass select:focus { border-color: var(--white) !important; box-shadow: 0 0 0 4px rgba(255, 255, 255, .22) !important; }
.field--glass option { color: var(--ink); background: var(--white); }

/* Adjuntar archivo */
.file {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border: 1.5px dashed #C3CADA;
  border-radius: var(--r-control);
  background: var(--mist);
  cursor: pointer;
  transition: border-color .2s, background-color .2s;
}
.file:hover { border-color: var(--action); background: #EEF3FD; }
.file .icon {
  width: 40px; height: 40px;
  padding: 8px;
  border-radius: 10px;
  background: var(--white);
  color: var(--action);
  border: 1px solid var(--line);
}
.file__text { display: flex; flex-direction: column; min-width: 0; }
.file__name {
  font-weight: 600;
  color: var(--night);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.file__hint { font-size: .875rem; color: var(--slate); }
.file__input {
  position: absolute;
  width: 1px; height: 1px;
  opacity: 0;
  overflow: hidden;
}
.field:has(.file__input:focus-visible) .file {
  outline: 3px solid var(--action);
  outline-offset: 3px;
}
.field.is-focus-file .file { outline: 3px solid var(--action); outline-offset: 3px; }
.file.is-invalid { border-color: var(--error); }
.file.has-file { border-style: solid; border-color: var(--action); background: #EEF3FD; }

/* Casilla de verificación */
.check { display: flex; align-items: flex-start; gap: 12px; }
.check input {
  flex-shrink: 0;
  width: 22px; height: 22px;
  margin: 1px 0 0;
  accent-color: var(--action);
  cursor: pointer;
}
.check label { font-size: .9375rem; color: var(--ink); cursor: pointer; }
.check input[aria-invalid="true"] { outline: 2px solid var(--error); outline-offset: 2px; }

/* Honeypot: oculto para personas, visible para bots */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Envío */
.form__submit { margin-top: 32px; min-height: 56px; font-size: 1.0625rem; }
.form__note { margin-top: 12px; text-align: center; font-size: .875rem; color: var(--slate); }

.spinner {
  display: none;
  width: 18px; height: 18px;
  border: 2.5px solid rgba(255, 255, 255, .4);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
.form__submit.is-loading .spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

.form__alert {
  display: grid;
  gap: 12px;
  justify-items: start;
  margin-top: 24px;
  padding: 16px;
  border-radius: var(--r-control);
  background: #FDECEE;
  border: 1px solid #F3C2C9;
  color: #8E1527;
  font-weight: 500;
}
.form__alert[hidden] { display: none; }

.form-success {
  display: grid;
  justify-items: center;
  gap: 16px;
  padding: 32px 8px;
  text-align: center;
}
.form-success[hidden] { display: none; }
.form-success:focus { outline: none; }
.form-success__icon {
  display: grid;
  place-items: center;
  width: 72px; height: 72px;
  border-radius: 50%;
  background: #E7F5EE;
  color: var(--success);
}
.form-success__icon .icon { width: 40px; height: 40px; }
.form-success h3 { max-width: 28rem; }
.form-success p { max-width: 28rem; color: var(--slate); }
.form-success .btn { margin-top: 8px; }

/* ---------- 10. Preguntas frecuentes ---------- */
.faq { display: grid; gap: 12px; }
.faq__item {
  border-radius: 18px;
  background: var(--white);
  border: 1px solid var(--line);
  transition: border-color .2s, box-shadow .2s;
}
.faq__item:hover { border-color: #CDD3E1; }
.faq__item.is-open { box-shadow: var(--shadow-sm); }
.faq h3 { font-size: 1.0625rem; letter-spacing: -0.02em; }
.faq__q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border: 0;
  border-radius: 18px;
  background: none;
  color: var(--night);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: inherit;
  letter-spacing: inherit;
  line-height: 1.35;
  text-align: left;
}
.faq__q .icon {
  width: 32px; height: 32px;
  padding: 6px;
  border-radius: 50%;
  background: var(--mist);
  color: var(--action);
  transition: transform .3s var(--ease), background-color .2s;
}
.faq__q:hover .icon { background: #EEF3FD; }
.faq__q[aria-expanded="true"] .icon { transform: rotate(180deg); }
.faq__a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .3s var(--ease);
}
.faq__a > div { overflow: hidden; }
.faq__a.is-open { grid-template-rows: 1fr; }
.faq__a p { padding: 0 24px 24px; color: var(--slate); max-width: 44rem; }

/* ---------- 10b. Aliados: lista de idiomas, especialidades y cita ---------- */
.partners__count {
  margin-top: 32px;
  padding: 16px 20px;
  border-radius: 18px;
  background: var(--mist);
  border: 1px solid var(--line);
  color: var(--slate);
}
.partners__count strong {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: -0.03em;
  color: var(--night);
}

.field__hint { font-size: .875rem; color: var(--slate); margin-top: -4px; }
.sublabel { margin-top: 8px; font-weight: 500; font-size: .9375rem; color: var(--night); }

/* Fieldsets sin estilo de navegador */
.fieldset, .appt { margin: 0; padding: 0; border: 0; min-width: 0; }
.fieldset legend, .appt__title {
  padding: 0;
  margin-bottom: 8px;
  font-weight: 600;
  font-size: .9375rem;
  color: var(--night);
}

/* Buscador y lista de idiomas */
.picker {
  border: 1px solid #C9CFDC;
  border-radius: var(--r-control);
  background: var(--white);
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
}
.picker:focus-within { border-color: var(--action); box-shadow: 0 0 0 4px rgba(47, 111, 224, .2); }
.field:has(#p-lang-search[aria-invalid="true"]) .picker { border-color: var(--error); }
.picker__search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
}
.picker__search .icon { width: 20px; height: 20px; color: var(--slate); }
.field .picker__search input {
  flex: 1;
  min-width: 0;
  min-height: 48px;
  padding: 12px 0;
  border: 0 !important;
  box-shadow: none !important;
  background: transparent;
  outline: none;
}
.picker__selected {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--mist);
}
.picker__selected[hidden] { display: none; }
.picker__chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 4px 4px 12px;
  border-radius: 999px;
  background: var(--night);
  color: var(--white);
  font-size: .875rem;
  font-weight: 500;
}
.picker__chip button {
  display: grid;
  place-items: center;
  width: 24px; height: 24px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .14);
  color: var(--white);
}
.picker__chip button:hover { background: rgba(255, 255, 255, .28); }
.picker__chip button:focus-visible { outline-color: var(--signal); outline-offset: 1px; }
.picker__chip .icon { width: 14px; height: 14px; stroke-width: 2.2; }
.picker__list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
  max-height: 264px;
  overflow-y: auto;
  margin: 0;
  padding: 8px;
  border: 0;
  overscroll-behavior: contain;
}
@media (min-width: 480px) { .picker__list { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .picker__list { grid-template-columns: repeat(3, 1fr); } }
.picker__option {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 6px 8px;
  border-radius: 8px;
  font-size: .9375rem;
  cursor: pointer;
  min-width: 0;
}
.picker__option[hidden] { display: none; }
.picker__option:hover { background: var(--mist); }
.picker__option input { flex-shrink: 0; width: 18px; height: 18px; margin: 0; accent-color: var(--action); cursor: pointer; }
.picker__option:has(input:checked) { background: #EEF3FD; color: var(--night); font-weight: 600; }
.picker__empty { padding: 16px; color: var(--slate); font-size: .9375rem; }
.picker__empty[hidden] { display: none; }

/* Especialidades como etiquetas seleccionables */
.chips-check { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-check { position: relative; cursor: pointer; }
.chip-check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chip-check span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 8px 16px;
  border: 1px solid #C9CFDC;
  border-radius: 999px;
  background: var(--white);
  font-size: .9375rem;
  font-weight: 500;
  transition: background-color .2s, border-color .2s, color .2s;
}
.chip-check:hover span { border-color: var(--action); }
.chip-check input:checked + span { background: var(--night); border-color: var(--night); color: var(--white); }
.chip-check input:checked + span::before {
  content: "";
  width: 14px; height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23FFFFFF' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / contain no-repeat;
}
.chip-check input:focus-visible + span { outline: 3px solid var(--action); outline-offset: 3px; }

/* Preferencia de contacto */
.choices { display: grid; gap: 8px; }
@media (min-width: 600px) { .choices { grid-template-columns: repeat(3, 1fr); } }
.choice { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choice__box {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 100%;
  min-height: 56px;
  padding: 12px 14px;
  border: 1px solid #C9CFDC;
  border-radius: var(--r-control);
  background: var(--white);
  font-weight: 500;
  font-size: .9375rem;
  line-height: 1.3;
  transition: border-color .2s, background-color .2s, box-shadow .2s;
}
.choice__box .icon { width: 22px; height: 22px; color: var(--slate); }
.choice:hover .choice__box { border-color: var(--action); }
.choice input:checked + .choice__box { border-color: var(--action); background: #EEF3FD; box-shadow: inset 0 0 0 1px var(--action); color: var(--night); }
.choice input:checked + .choice__box .icon { color: var(--action); }
.choice input:focus-visible + .choice__box { outline: 3px solid var(--action); outline-offset: 3px; }

/* Campos de la cita */
.appt {
  display: grid;
  gap: 12px;
  padding: 20px;
  border-radius: 18px;
  background: var(--mist);
  border: 1px solid var(--line);
}
.appt[hidden] { display: none; }
.appt__title { margin-bottom: 0; float: left; width: 100%; }
.appt__grid { display: grid; gap: 16px; }
.appt__grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }

.file--compact { padding: 12px; gap: 12px; }
.file--compact .icon { width: 36px; height: 36px; padding: 7px; }

.footer__partners {
  display: inline-block;
  margin-top: 16px;
  font-size: .8125rem;
  color: var(--slate);
  text-decoration: underline;
  text-decoration-color: var(--line);
  text-underline-offset: 3px;
}
.footer__partners:hover { color: var(--night); text-decoration-color: currentColor; }

/* Página de aliados: cabecera compacta con aurora */
.page-hero { padding: calc(var(--header-h) + 56px) 0 56px; }
.page-hero h1 { font-size: clamp(2.25rem, 6vw, 3.25rem); text-wrap: balance; }
@media (min-width: 960px) { .page-hero { padding: calc(var(--header-h) + 88px) 0 88px; } }
.page-hero__inner { margin-inline: auto; max-width: 1184px; }
.page-hero__inner > * { max-width: 760px; }
.nav__back .icon { width: 18px; height: 18px; }
/* En pantallas angostas el botón "Inicio" muestra solo la flecha */
@media (max-width: 479px) {
  .nav__back { width: 44px; min-height: 44px; padding: 0; }
  .nav__back span {
    position: absolute; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap;
  }
}

/* ---------- 11. Bloque final ---------- */
.final { padding-block: 96px; text-align: center; }
.final__inner { display: grid; justify-items: center; gap: 16px; }
.final h2 { font-size: clamp(2rem, 6vw, 3rem); letter-spacing: -0.04em; max-width: 16ch; }
.final p { max-width: 32rem; color: rgba(255, 255, 255, .84); font-size: 1.125rem; }
.final .btn { margin-top: 16px; }
@media (min-width: 960px) { .final { padding-block: 128px; } }

/* ---------- 12. Pie de página ---------- */
.footer { padding-top: 56px; background: var(--white); border-top: 1px solid var(--line); }
.footer__grid { display: grid; gap: 32px; padding-bottom: 40px; }
.footer__brand p { margin-top: 12px; color: var(--slate); }
.footer__contact { display: grid; gap: 14px; }
.footer__contact li { display: flex; align-items: center; gap: 12px; color: var(--ink); min-width: 0; }
.footer__contact .icon { width: 20px; height: 20px; color: var(--action); }
.footer__contact a { color: var(--ink); text-decoration: none; overflow-wrap: anywhere; }
.footer__contact a:hover { color: var(--action); text-decoration: underline; }
.footer__bottom {
  padding-block: 24px;
  border-top: 1px solid var(--line);
  font-size: .875rem;
  color: var(--slate);
}
@media (min-width: 768px) {
  .footer__grid { grid-template-columns: 1fr auto; align-items: start; }
  .footer__contact { grid-template-columns: repeat(2, auto); gap: 14px 40px; }
}

/* ---------- 13. Botón flotante de WhatsApp ---------- */
.whatsapp-float {
  position: fixed;
  right: 16px; bottom: 16px;
  z-index: 40;
  display: grid;
  place-items: center;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--whatsapp);
  color: var(--white);
  box-shadow: 0 12px 32px rgba(11, 18, 38, .24);
  transition: transform .25s var(--ease), box-shadow .25s;
}
.whatsapp-float:hover { color: var(--white); transform: translateY(-3px) scale(1.04); box-shadow: 0 16px 40px rgba(11, 18, 38, .3); }
.whatsapp-float:focus-visible { outline-color: var(--night); border-radius: 50%; }
.whatsapp-float svg { width: 30px; height: 30px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
@media (min-width: 768px) { .whatsapp-float { right: 24px; bottom: 24px; width: 60px; height: 60px; } }

/* ---------- 14. Animaciones de aparición ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.js .reveal.is-visible { opacity: 1; transform: none; }
.cards .reveal:nth-child(2), .steps .reveal:nth-child(2) { transition-delay: .08s; }
.cards .reveal:nth-child(3), .steps .reveal:nth-child(3) { transition-delay: .16s; }

/* Movimiento reducido: sin animaciones */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    transition-delay: 0s !important;
  }
  .js .reveal { opacity: 1; transform: none; }
  .btn:hover, .card:hover, .whatsapp-float:hover { transform: none; }
}
