/*
 * Cotivala · estilos del sitio
 * Basado en docs/GUIA_WEB.md (sección 7). Sin dependencias ni paso de compilación.
 */

:root {
  --brand-navy: #0a2f61;
  --brand-navy-strong: #082650;
  --brand-teal: #00b9c4;
  --brand-teal-hover: #00a8b2;
  --brand-symbol: #0b3b71;
  --text: #18364f;
  --text-muted: #587080;
  --surface: #fff;
  --background: #f5f7fa;
  --surface-assist: #edf8f8;
  --border: #dce6eb;
  --control-border: #587080;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(10, 47, 97, 0.06), 0 8px 24px rgba(10, 47, 97, 0.08);
  --font: "DejaVu Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --header-h: 72px;
}

/* ---------- Base ---------- */

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

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

body {
  margin: 0;
  font: 400 1rem/1.5 var(--font);
  color: var(--text);
  background: var(--surface);
  overflow-wrap: break-word;
}

img, svg { display: block; max-width: 100%; }
img { height: auto; }

h1, h2, h3, h4 {
  margin: 0 0 16px;
  color: var(--brand-navy);
  font-weight: 700;
  line-height: 1.2;
}
h1 { font-size: clamp(2rem, 5vw, 3.5rem); line-height: 1.15; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.25; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.0625rem; }

p { margin: 0 0 16px; }
p:last-child { margin-bottom: 0; }

a { color: var(--brand-navy); text-underline-offset: 0.2em; }
a:hover { color: var(--brand-symbol); }

ul { margin: 0; padding: 0; list-style: none; }

:focus-visible { outline: 3px solid var(--brand-navy); outline-offset: 3px; }
.on-dark :focus-visible { outline-color: #fff; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  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: 12px 16px;
  background: var(--brand-navy);
  color: #fff;
  border-radius: var(--radius-sm);
  font-weight: 700;
}
.skip-link:focus { top: 16px; color: #fff; }

.container { width: min(100% - 32px, 1200px); margin-inline: auto; }

.amount { font-variant-numeric: tabular-nums; }

/* ---------- Botones ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 20px;
  border: 2px solid transparent;
  border-radius: var(--radius-sm);
  font: 700 1rem/1.25 var(--font);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.button--primary { background: var(--brand-teal); color: var(--brand-navy); }
.button--primary:hover { background: var(--brand-teal-hover); color: var(--brand-navy); }
.button--secondary { background: #fff; color: var(--brand-navy); border-color: var(--brand-navy); }
.button--secondary:hover { background: var(--surface-assist); color: var(--brand-navy); }
.button--ghost { background: transparent; color: var(--brand-navy); }
.button--ghost:hover { background: var(--background); color: var(--brand-navy); }
.button--block { width: 100%; }
.button--sm { min-height: 44px; padding: 8px 16px; white-space: nowrap; }
.button:disabled { cursor: not-allowed; opacity: 0.55; }

/* ---------- Encabezado ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--border);
  backdrop-filter: saturate(1.4) blur(8px);
}

.site-header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: var(--header-h);
}

.brand { display: inline-flex; flex-shrink: 0; padding: 8px 0; border-radius: var(--radius-sm); }
.brand__logo { width: 180px; height: auto; }

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--brand-navy);
  cursor: pointer;
}
.nav-toggle svg { width: 24px; height: 24px; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

.site-nav {
  display: none;
  position: absolute;
  inset: 100% 0 auto 0;
  padding: 16px 16px 24px;
  background: #fff;
  border-bottom: 1px solid var(--border);
  box-shadow: 0 16px 24px rgba(10, 47, 97, 0.08);
}
.site-nav.is-open { display: block; }

.site-nav__links { display: grid; gap: 4px; margin-bottom: 16px; }
.site-nav__links a {
  display: flex;
  white-space: nowrap;
  align-items: center;
  min-height: 48px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  text-decoration: none;
}
.site-nav__links a:hover { background: var(--background); }

.site-nav__actions { display: grid; gap: 8px; }

.lang-switch {
  display: inline-flex;
  padding: 4px;
  gap: 4px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--background);
}
.lang-switch button {
  min-width: 44px;
  min-height: 44px;
  padding: 4px 8px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--text-muted);
  font: 700 0.875rem/1 var(--font);
  cursor: pointer;
}
.lang-switch button:hover { color: var(--brand-navy); }
.lang-switch button[aria-pressed="true"] {
  background: #fff;
  color: var(--brand-navy);
  box-shadow: 0 1px 2px rgba(10, 47, 97, 0.12);
}

/* Selector de idioma: desplegable nativo, compacto */
.lang-select { position: relative; display: inline-flex; }
.lang-select select {
  min-height: 44px;
  padding: 4px 32px 4px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--background) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' fill='none' stroke='%230a2f61' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 12px center;
  color: var(--brand-navy);
  font: 700 0.875rem/1 var(--font);
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
.lang-select select:hover { border-color: var(--brand-navy); }
.site-nav .lang-select { justify-self: start; margin-top: 8px; }

/* Selector de moneda (MXN / USD): mismo control que el de idioma */
.currency-toggle {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 12px;
  margin-top: 16px;
}
.currency-toggle--start { justify-content: flex-start; margin: 0 0 16px; }
.currency-toggle__label { color: var(--text-muted); font-size: 0.9375rem; font-weight: 600; }
.currency-switch { background: #fff; }
.currency-switch button[aria-pressed="true"] { background: var(--brand-navy); color: #fff; }
/* Sin JavaScript (sin data-currency) se ven los montos en MXN. */
html[data-currency="usd"] [data-currency-only="mxn"],
html:not([data-currency="usd"]) [data-currency-only="usd"] { display: none !important; }

/* ---------- Secciones ---------- */

.section { padding-block: 64px; }
.section--muted { background: var(--background); }
.section--tight { padding-block: 48px; }

.section-head { max-width: 720px; margin: 0 auto 40px; text-align: center; }
.section-head p { color: var(--text-muted); font-size: 1.0625rem; }

.eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  color: var(--brand-navy);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 8px;
  border-radius: 0 10px 0 10px;
  background: var(--brand-teal);
  vertical-align: 1px;
}

.grid { display: grid; gap: 16px; }

/* ---------- Portada ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding-block: 48px 64px;
  background: var(--background);
}
.hero::before,
.hero::after {
  content: "";
  position: absolute;
  z-index: 0;
  pointer-events: none;
  border-radius: 0 100% 0 100%;
}
.hero::before {
  width: 360px; height: 180px;
  right: -120px; top: -40px;
  background: var(--brand-teal);
  opacity: 0.12;
  transform: rotate(-24deg);
}
.hero::after {
  width: 220px; height: 120px;
  left: -90px; bottom: -30px;
  background: var(--brand-symbol);
  opacity: 0.08;
  transform: rotate(36deg);
}

.hero__inner { position: relative; z-index: 1; display: grid; gap: 40px; align-items: center; }

.hero .eyebrow { display: block; }

.hero__lead { max-width: 560px; font-size: 1.125rem; color: var(--text); }
.hero__for { margin: 16px 0 0; font-weight: 700; color: var(--brand-navy); }
.hero__actions { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 12px 16px; margin-top: 24px; }
.hero__support { margin: 8px 0 0; color: var(--text-muted); font-size: 0.875rem; }

@media (max-width: 559px) {
  .hero { padding-block: 32px 48px; }
  .hero__lead { font-size: 1rem; }
  .hero__for { margin-top: 12px; }
  .hero__actions { margin-top: 16px; }
}

/* Tarjeta de asistencia */
.assist-card {
  margin: 0;
  padding: 24px;
  background: #fff;
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.assist-card__label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--brand-navy);
  font-size: 0.875rem;
  font-weight: 700;
}
.assist-card__label img { width: 32px; height: 32px; }
.assist-card__question { margin-bottom: 12px; font-size: 1.125rem; }
.bubble {
  padding: 16px;
  border-radius: var(--radius);
  font-size: 1rem;
}
.bubble--user { background: var(--brand-navy); color: #fff; }
.bubble--user .bubble__who { color: #8fe6eb; }
.bubble--assist { background: var(--surface-assist); color: var(--text); }
.bubble__who {
  display: block;
  margin-bottom: 4px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand-navy);
}
.bubble + .bubble { margin-top: 12px; }

.draft {
  margin-top: 16px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.draft__head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.draft__title { margin: 0; font-size: 0.9375rem; font-weight: 700; color: var(--brand-navy); }
.draft__row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-block: 8px;
  border-top: 1px solid var(--border);
  font-size: 0.9375rem;
}
.draft__row span:last-child { color: var(--text-muted); text-align: right; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.6;
}
.status svg { width: 14px; height: 14px; }
.status--draft { background: var(--background); color: var(--brand-navy); border: 1px solid var(--border); }

/* ---------- Tarjetas ---------- */

.card {
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.card--muted { background: var(--background); border-color: transparent; }
.card--assist { background: var(--surface-assist); border-color: transparent; }
.card p { color: var(--text); }
.card__num { display: block; margin-bottom: 8px; color: var(--brand-navy); font-size: 0.875rem; font-weight: 700; }

.icon-tile {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 16px;
  border-radius: 12px 4px 12px 4px;
  background: var(--surface-assist);
  color: var(--brand-navy);
}
.icon-tile svg { width: 24px; height: 24px; }
.icon-tile--navy { background: var(--brand-navy); color: #fff; }

/* ---------- Precios ---------- */

.pricing { display: grid; gap: 24px; align-items: stretch; }

.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 24px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.plan--featured { border: 2px solid var(--brand-navy); box-shadow: var(--shadow); }
.plan__badge {
  position: absolute;
  top: -14px;
  left: 24px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--brand-navy);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 700;
}
.plan__name { margin-bottom: 4px; font-size: 1.25rem; }
.plan__desc { color: var(--text-muted); font-size: 0.875rem; }
.plan__price {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin: 16px 0 4px;
  color: var(--brand-navy);
}
.plan__amount { font-size: 2rem; font-weight: 700; line-height: 1.2; }
.plan__currency { font-size: 0.875rem; font-weight: 700; }
.plan__period { color: var(--text-muted); font-size: 0.875rem; }
.plan__tax { color: var(--text-muted); font-size: 0.875rem; font-weight: 700; }
.plan__note { margin-bottom: 16px; color: var(--text-muted); font-size: 0.875rem; }
.plan__features { display: grid; gap: 8px; font-size: 0.9375rem; }
.compare summary {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  color: var(--brand-navy);
  font-size: 0.9375rem;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  cursor: pointer;
  list-style: none;
}
.compare summary::-webkit-details-marker { display: none; }
.compare summary::after {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform 0.15s ease;
}
.compare[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.plan__features li { display: flex; gap: 8px; align-items: flex-start; }
.plan__features svg { flex-shrink: 0; width: 18px; height: 18px; margin-top: 3px; color: var(--brand-teal); }
.plan__features strong { color: var(--brand-navy); }
.plan__features { margin-bottom: 24px; }
.plan__aside { display: block; margin-top: 2px; color: var(--text-muted); font-size: 0.875rem; }
.plan__cta { margin-top: auto; }

.pricing-extras { margin-top: 24px; }
.pricing-extras .button { margin-top: 8px; }
.pricing-extras > .card { min-width: 0; }
.pricing-extras .table-scroll { margin: 16px 0; }
.compare__table.compare__table--compact { min-width: 0; }
.compare__table.compare__table--compact th,
.compare__table.compare__table--compact td { padding: 10px 12px; }
.compare__table--compact .table-sub { display: block; margin-top: 2px; color: var(--text-muted); font-size: 0.875rem; font-weight: 400; }
@media (max-width: 559px) {
  .compare__table.compare__table--compact th,
  .compare__table.compare__table--compact td { padding: 10px 8px; }
}

/* Niveles de Conor AI por plan */
.levels { margin-top: 64px; }
.section-head--sub { margin-bottom: 24px; }
.section-head--sub h3 { font-size: clamp(1.375rem, 2.5vw, 1.75rem); }
.level { display: flex; flex-direction: column; gap: 16px; }
.level__plan { margin: 0; color: var(--brand-navy); font-size: 0.875rem; font-weight: 700; }
.level__text { margin: 0; font-size: 0.9375rem; }
.levels .section-foot { margin-top: 24px; font-size: 1rem; }
.footnote { max-width: 880px; margin: 24px auto 0; color: var(--text-muted); font-size: 0.9375rem; }

/* Comparador de capacidades */
.compare { margin-top: 24px; }
.compare summary { justify-content: center; }
.table-scroll {
  margin-top: 16px;
  overflow-x: auto;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.compare__table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 0.9375rem; }
.compare__table th,
.compare__table td { padding: 12px 16px; border-top: 1px solid var(--border); text-align: left; vertical-align: top; }
.compare__table thead th { border-top: 0; color: var(--brand-navy); background: var(--surface-assist); }
.compare__table tbody th { color: var(--brand-navy); font-weight: 700; }
.compare__table th:first-child { position: sticky; left: 0; z-index: 1; background: #fff; }
.compare__table thead th:first-child { background: var(--surface-assist); }

/* En móvil la comparación se apila: cada capacidad es un bloque con Free / Pro / Max (H-12), tomados de data-label (texto alternativo vacío: el lector de pantalla ya anuncia el plan por el encabezado de columna).
   Los roles ARIA del HTML conservan la semántica de tabla. */
@media (max-width: 559px) {
  .compare__table:not(.compare__table--compact) { min-width: 0; font-size: 0.9375rem; }
  .compare__table:not(.compare__table--compact),
  .compare__table:not(.compare__table--compact) tbody,
  .compare__table:not(.compare__table--compact) tr { display: block; }
  .compare__table:not(.compare__table--compact) thead {
    position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0);
  }
  .compare__table:not(.compare__table--compact) tbody tr { padding: 12px 16px; border-top: 1px solid var(--border); }
  .compare__table:not(.compare__table--compact) tbody tr:first-child { border-top: 0; }
  .compare__table:not(.compare__table--compact) th,
  .compare__table:not(.compare__table--compact) td { display: block; padding: 0; border: 0; }
  .compare__table:not(.compare__table--compact) tbody th { position: static; margin-bottom: 6px; }
  .compare__table:not(.compare__table--compact) td {
    display: flex; justify-content: space-between; gap: 16px; padding-block: 3px; text-align: right;
  }
  .compare__table:not(.compare__table--compact) td::before { color: var(--text-muted); font-weight: 700; text-align: left; }
  .compare__table:not(.compare__table--compact) td::before { content: attr(data-label); content: attr(data-label) / ""; }
}

/* ---------- Pasos ---------- */

.steps { margin: 0; padding: 0; list-style: none; }

/* ---------- Funciones ---------- */

.feature__title { font-size: clamp(1.375rem, 2.5vw, 1.75rem); }

.feature { display: grid; gap: 32px; align-items: center; }
.feature + .feature { margin-top: 64px; }
.feature__text p { color: var(--text); font-size: 1.0625rem; }

.mock {
  position: relative;
  padding: 24px;
  border-radius: 16px;
  background: var(--background);
  overflow: hidden;
}
.mock::after {
  content: "";
  position: absolute;
  right: -40px; bottom: -40px;
  width: 160px; height: 90px;
  border-radius: 0 100% 0 100%;
  background: var(--brand-teal);
  opacity: 0.14;
  transform: rotate(-24deg);
}
.mock__panel {
  position: relative;
  z-index: 1;
  padding: 16px;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.mock__panel + .mock__panel { margin-top: 12px; }
.mock__title { margin: 0 0 12px; color: var(--brand-navy); font-size: 0.9375rem; font-weight: 700; }
.mock__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-block: 10px;
  border-top: 1px solid var(--border);
  font-size: 0.9375rem;
}
.mock__row:first-of-type { border-top: 0; }
.mock__label { display: inline-flex; align-items: center; }
.mock__icon { flex-shrink: 0; width: 20px; height: 20px; margin-right: 10px; color: var(--brand-navy); }
/* ---------- Segmentos ---------- */

.segment h3 { margin: 0; font-size: 1.0625rem; }
.segment h3 a { color: inherit; text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 3px; }
.segment h3 a:hover, .segment h3 a:focus-visible { text-decoration-color: currentColor; }

.section-foot { max-width: 720px; margin: 32px auto 0; text-align: center; color: var(--text); font-size: 1.0625rem; }

.note {
  padding: 16px;
  border-left: 4px solid var(--brand-teal);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--surface-assist);
}
.feature__text .note { font-size: 1rem; }
.feature__text .button { margin-top: 8px; }

/* ---------- Preguntas frecuentes ---------- */

.faq { max-width: 820px; margin-inline: auto; border-top: 1px solid var(--border); }
.faq__item { border-bottom: 1px solid var(--border); }
.faq__item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 56px;
  padding: 16px 0;
  color: var(--brand-navy);
  font-size: 1.0625rem;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: "";
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-3px) rotate(45deg);
  transition: transform 0.15s ease;
}
.faq__item[open] summary::after { transform: translateY(3px) rotate(-135deg); }
.faq__answer { padding-bottom: 20px; color: var(--text); }

/* ---------- Banda de llamada a la acción ---------- */

.cta-band {
  position: relative;
  overflow: hidden;
  padding: 40px 24px;
  border-radius: 16px;
  background: var(--brand-navy);
  color: #fff;
  text-align: center;
}
.cta-band::before {
  content: "";
  position: absolute;
  right: -60px; top: -50px;
  width: 260px; height: 130px;
  border-radius: 0 100% 0 100%;
  background: var(--brand-teal);
  opacity: 0.25;
  transform: rotate(-24deg);
}
.cta-band > * { position: relative; }
.cta-band h2 { color: #fff; }
.cta-band p { max-width: 560px; margin-inline: auto; color: #d6e3ef; font-size: 1.0625rem; }
.cta-band .button { margin-top: 24px; }
.cta-band a:not(.button) { color: #fff; }
.cta-band__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 16px; }
.cta-band__fine { margin-top: 16px; font-size: 0.875rem !important; }

/* Variante en dos columnas: oferta de negocios fundadores */
.cta-band--split { display: grid; gap: 32px; align-items: center; text-align: left; }
.cta-band--split p { margin-inline: 0; }
.cta-band__panel { padding: 24px; border-radius: var(--radius); background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.2); }
.cta-band__panel-title { color: #fff !important; font-weight: 700; }
.cta-band__panel .plan__features { margin: 0; font-size: 1.0625rem; color: #fff; }
.cta-band__panel .plan__features svg { color: #8fe6eb; }
.cta-band__panel-value { margin: 16px 0 0; }
.cta-band__panel .cta-band__panel-title:not(:first-child) { margin: 24px 0 12px; font-size: 1.0625rem; }
.link-block,
.pricing-extras .card > a:not(.button),
.site-footer__bottom a,
.form-card__alt a { display: inline-flex; align-items: center; min-height: 44px; }
.pricing-extras .card > a:not(.button) { display: flex; width: fit-content; }
.form-card__alt a { display: flex; width: fit-content; }

/* ---------- Pie de página ---------- */

/* El espacio inferior extra evita que el botón flotante de WhatsApp tape el pie al final de la página. */
.site-footer {
  padding-block: 48px 96px;
  background: var(--background);
  border-top: 1px solid var(--border);
  font-size: 0.9375rem;
}
.site-footer__grid { display: grid; gap: 32px; }
.site-footer__about p { margin-top: 12px; color: var(--text-muted); }
.site-footer h2 {
  margin-bottom: 12px;
  font-size: 0.875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.site-footer ul { display: grid; gap: 4px; }
.site-footer li a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.site-footer li a:hover { text-decoration: underline; }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.875rem;
}

/* Redes sociales: iconos de 22 px con área táctil de 44 px. */
.site-footer .social-links { display: flex; flex-wrap: wrap; gap: 4px; }
.site-footer__about .social-links { margin: 16px 0 0 -11px; }
.site-footer__links .social-links { margin-inline: -11px; }
.site-footer .social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  min-height: 44px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
}
.site-footer .social-links a:hover { color: var(--brand-navy); background: var(--surface-assist); }
.site-footer .social-links svg { width: 22px; height: 22px; }
.site-footer__links { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; }

.site-footer--compact { padding-block: 24px 96px; }
.site-footer--compact .site-footer__bottom { margin-top: 0; padding-top: 0; border-top: 0; }

/* ---------- Formularios (páginas de espacio) ---------- */

.page-main { padding-block: 48px 64px; background: var(--background); min-height: 60vh; }

.form-card {
  max-width: 520px;
  margin-inline: auto;
  padding: 24px;
  background: #fff;
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.form-card h1 { font-size: clamp(1.5rem, 4vw, 2rem); }
.form-card__intro { color: var(--text-muted); }

.field { margin-block: 24px; }
.field label { display: block; margin-bottom: 8px; color: var(--brand-navy); font-size: 0.875rem; font-weight: 700; line-height: 1.4; }
.field__help { margin: 8px 0 0; color: var(--text-muted); font-size: 0.875rem; }

input, textarea, select {
  width: 100%;
  min-height: 48px;
  padding: 12px;
  border: 1px solid var(--control-border);
  border-radius: var(--radius-sm);
  font: inherit;
  color: var(--text);
  background: #fff;
}
input::placeholder { color: var(--text-muted); }

.input-group { display: flex; align-items: stretch; }
.input-group input { min-width: 0; border-radius: var(--radius-sm) 0 0 var(--radius-sm); }
.input-group__addon {
  display: flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--control-border);
  border-left: 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--background);
  color: var(--text-muted);
  font-size: 0.875rem;
  white-space: nowrap;
}

.form-card__privacy { margin: 16px 0 0; color: var(--text-muted); font-size: 0.875rem; }
.form-card__privacy a { display: inline-block; padding-block: 12px; margin-block: -12px; }

.form-card__alt {
  margin-top: 24px;
  padding: 16px;
  border-radius: var(--radius);
  background: var(--surface-assist);
  font-size: 0.9375rem;
}

/* ---------- Términos ---------- */

.legal {
  max-width: 820px;
  margin-inline: auto;
  padding: 24px;
  background: #fff;
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.legal h1 { font-size: clamp(1.75rem, 4vw, 2.5rem); }
.legal__intro { color: var(--text-muted); font-size: 1.0625rem; }
.legal__toc { margin-block: 24px 8px; padding: 16px 24px; border-radius: var(--radius); background: var(--background); }
.legal__toc h2 { margin-bottom: 8px; font-size: 1rem; }
.legal__toc ol { margin: 0; padding-left: 20px; }
.legal__toc li { padding-block: 4px; }
.legal section { padding-top: 24px; }
.legal section h2 { font-size: 1.375rem; }
.legal section ul { list-style: disc; padding-left: 20px; }
.legal section h3 { margin: 16px 0 8px; font-size: 1.125rem; }
.legal section li + li { margin-top: 8px; }
.legal section .button { margin-top: 24px; }
.legal section p + p, .legal section ul + p, .legal section p + ul { margin-top: 12px; }
.legal__updated { color: var(--text-muted); font-size: 0.9375rem; }
.legal__lang-note { padding: 12px 16px; border-left: 4px solid var(--brand-teal); border-radius: var(--radius-sm); background: var(--surface-assist); }
html[lang="es"] .legal__lang-note { display: none; }
/* Datos del responsable por completar antes de publicar (ver README). */
.legal .pending { padding: 0 4px; border-radius: 4px; background: #fff1b8; color: #5a4300; font-weight: 700; }

/* ---------- Pantallas medianas ---------- */

@media (min-width: 560px) {
  .grid--2, .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 768px) {
  .container { width: min(100% - 64px, 1200px); }
  .brand__logo { width: 200px; }
  .section { padding-block: 96px; }
  .hero { padding-block: 72px 96px; }
  .site-footer__grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
  .cta-band { padding: 64px 48px; }
  .form-card { padding: 40px; }
  .legal { padding: 48px; }
  .cta-band--split { grid-template-columns: 1.4fr 1fr; gap: 48px; padding: 56px; }
  .feature { grid-template-columns: 1fr 1fr; gap: 64px; }
  .feature--reverse .feature__text { order: 2; }
}

@media (min-width: 900px) {
  .pricing { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- Escritorio ---------- */

@media (min-width: 1024px) {
  .brand__logo { width: 220px; }
  .hero__inner { grid-template-columns: 1.1fr 0.9fr; gap: 64px; }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
}

/* Menú desplegable: el botón "Iniciar sesión" necesita borde visible (H-19). */
@media (max-width: 1279px) {
  .site-nav .button--ghost { border-color: var(--control-border); }
}

/* La navegación completa necesita más ancho (sobre todo en español y francés). */
@media (min-width: 1280px) {
  .nav-toggle { display: none; }
  .site-nav {
    display: flex;
    position: static;
    align-items: center;
    gap: 16px;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
  }
  .site-nav__links { display: flex; gap: 0; margin: 0; }
  .site-header .brand__logo { width: 180px; }
  .site-nav__links a { min-height: 44px; padding: 8px 6px; font-size: 0.9375rem; }
  .site-nav__actions { display: flex; align-items: center; gap: 8px; }
  .site-nav__actions .button--sm { padding-inline: 12px; font-size: 0.9375rem; }
  .site-nav .lang-select { margin-top: 0; }
  /* En el menú en línea la etiqueta Beta no cabe (en francés desborda la cabecera en todas las páginas), así que solo se muestra en el menú desplegable.
     El estado beta queda visible en el contenido: portada (tarjeta, sección Conor AI, planes, comparación y FAQ) y Términos (primer punto de «IA y resultados generados»). */
  .site-nav__links .badge-beta { display: none; }
}

/* ---------- Botón flotante de WhatsApp ---------- */
/* Verde de WhatsApp con texto azul marino (contraste 6.6:1). Bajo el encabezado (z-index 50) para que el menú desplegable lo cubra. */
.wa-float {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 40;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 56px;
  min-height: 56px;
  padding: 0 20px 0 16px;
  border-radius: 999px;
  background: #25d366;
  color: var(--brand-navy);
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 2px 4px rgba(10, 47, 97, 0.16), 0 8px 24px rgba(10, 47, 97, 0.2);
}
.wa-float:hover { color: var(--brand-navy); background: #3ee07a; }
.wa-float svg { flex-shrink: 0; width: 26px; height: 26px; }
@media (max-width: 559px) {
  .wa-float { padding: 0; }
  .wa-float__text {
    position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
  }
}
@media print { .wa-float { display: none; } }

/* Oculta la página hasta aplicar el idioma (script en el <head>; H-17). */
html.i18n-pending body { visibility: hidden; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* Etiqueta «Beta» de Conor AI */
/* Separada del texto por un espacio en el HTML (nombre accesible «Conor AI Beta»); en contenedores flex el espacio no se dibuja y se usa margen. */
.badge-beta {
  display: inline-flex;
  align-items: center;
  flex: none;
  padding: 2px 7px;
  border: 1px solid var(--brand-teal);
  border-radius: 999px;
  background: var(--surface-assist);
  color: var(--brand-navy);
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  vertical-align: middle;
  white-space: nowrap;
}
.site-nav__links .badge-beta { margin-left: 6px; }
.eyebrow + .badge-beta { margin-bottom: 12px; vertical-align: 1px; }
h3 .badge-beta { vertical-align: 4px; }
