/* ============================================================
   EVALUACIÓN EB-1
   ------------------------------------------------------------
   Sólo la carga la página de EB-1. Vive en la capa compartida y
   resuelve TODO el color por token (`--navy`, `--blue`, `--wash`,
   `--line`, `--muted`, `--success`, `--error`), así que si algún
   día Green North monta su evaluación, se pinta con su paleta sin
   tocar una regla.
   ============================================================ */

.eb1-seccion {
  background: linear-gradient(180deg, var(--bg), var(--band));
}

.eb1-grid {
  display: grid;
  gap: 28px;
  margin-top: 32px;
  align-items: start;
}

/* En móvil la columna de apoyo va DEBAJO del cuestionario: quien llega al
   ancla tiene que ver la primera pregunta, no tres argumentos más. */
.eb1-isla { order: 1; }
.eb1-aside { order: 2; }

@media (min-width: 900px) {
  .eb1-grid {
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
    gap: 40px;
  }
  .eb1-aside { order: 1; position: sticky; top: calc(var(--header-h, 72px) + 24px); }
  .eb1-isla { order: 2; }
}

/* ---------- columna de apoyo ---------- */
.eb1-entregables { display: grid; gap: 18px; }
.eb1-entregables li { display: flex; gap: 12px; align-items: flex-start; }
.eb1-entregables .qstar { width: 20px; height: 20px; flex: none; margin-top: 2px; color: var(--blue); }
.eb1-entregables strong {
  display: block;
  font-family: var(--font-serif, inherit);
  font-size: 17px;
  color: var(--navy);
  line-height: 1.3;
}
.eb1-entregables span { display: block; color: var(--muted); font-size: 15px; margin-top: 2px; }

.eb1-notas {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line-soft, var(--line));
  display: grid;
  gap: 10px;
}
.eb1-notas li {
  position: relative;
  padding-left: 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}
.eb1-notas li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--blue);
}

/* ---------- la tarjeta ---------- */
.eb1-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 22px;
  box-shadow: 0 18px 44px -28px rgba(0, 0, 0, .35);
}
@media (min-width: 560px) { .eb1-card { padding: 30px; } }

.eb1-top { display: grid; gap: 12px; margin-bottom: 22px; }

.eb1-pasos { display: flex; gap: 6px; }
.eb1-pip {
  height: 4px;
  flex: 1;
  border-radius: 999px;
  background: var(--line);
  transition: background .2s ease;
}
.eb1-pip.hecho { background: var(--blue); }
.eb1-pip.actual { background: var(--blue); opacity: .55; }

.eb1-progreso { display: flex; align-items: center; gap: 12px; }
.eb1-barra {
  flex: 1;
  height: 6px;
  border-radius: 999px;
  background: var(--line);
  overflow: hidden;
}
.eb1-barra > span {
  display: block;
  height: 100%;
  background: var(--blue);
  border-radius: 999px;
  transition: width .28s cubic-bezier(.3, .8, .3, 1);
}
.eb1-progreso-txt {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}

/* ---------- el paso ---------- */
.eb1-eyebrow {
  display: block;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--blue);
}
.eb1-titulo {
  font-family: var(--font-serif, inherit);
  font-weight: 600;
  font-size: clamp(22px, 3vw, 28px);
  line-height: 1.18;
  color: var(--navy);
  margin-top: 6px;
  text-wrap: balance;
}
/* El título recibe el foco al cambiar de paso; el anillo del sitio ya es
   visible, pero un `outline` alrededor de un titular queda raro pegado. */
.eb1-titulo:focus-visible { outline-offset: 6px; }
.eb1-paso-ayuda { color: var(--muted); font-size: 15px; margin-top: 8px; }

.eb1-campo { margin-top: 26px; }
.eb1-fs { border: 0; padding: 0; margin: 0; min-width: 0; }
.eb1-label {
  padding: 0;
  font-weight: 700;
  font-size: 16.5px;
  color: var(--navy);
  line-height: 1.35;
}
.eb1-opcional { font-weight: 500; color: var(--muted); }
.eb1-ayuda { color: var(--muted); font-size: 14px; margin-top: 5px; line-height: 1.5; }

/* ---------- opciones ---------- */
.eb1-opts { display: grid; gap: 9px; margin-top: 12px; }
.eb1-opt {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  text-align: left;
  padding: 14px 15px;
  border: 2px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  transition: border-color .16s ease, background .16s ease;
  font-family: inherit;
}
.eb1-opt:hover { border-color: var(--blue); background: var(--wash); }
.eb1-opt.sel { border-color: var(--blue); background: var(--wash); }

.eb1-marca {
  position: relative;
  width: 22px;
  height: 22px;
  flex: none;
  margin-top: 1px;
  border: 2px solid var(--line);
  border-radius: 50%;
  transition: background .16s ease, border-color .16s ease;
}
.eb1-opt.multi .eb1-marca { border-radius: 7px; }
.eb1-opt.sel .eb1-marca { background: var(--blue); border-color: var(--blue); }
/* El check se dibuja con dos bordes girados: sin SVG, sin fuente de iconos y
   sin una petición más. */
.eb1-opt.sel .eb1-marca::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 2px;
  width: 5px;
  height: 10px;
  border: solid var(--surface);
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(45deg);
}

.eb1-opt-txt { font-weight: 600; font-size: 15.5px; color: var(--navy); line-height: 1.4; }
.eb1-opt-help {
  display: block;
  font-weight: 500;
  font-size: 13px;
  color: var(--muted);
  margin-top: 3px;
  line-height: 1.45;
}

/* ---------- campos de texto ---------- */
.eb1-input {
  width: 100%;
  margin-top: 10px;
  padding: 13px 14px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  font: inherit;
  font-size: 16px; /* 16px o iOS hace zoom al enfocar */
  color: var(--navy);
}
.eb1-input::placeholder { color: var(--muted); opacity: .75; }
.eb1-input:focus { border-color: var(--blue); outline-offset: 1px; }

.eb1-pais { margin-top: 10px; }
/* El selector de país trae su propia hoja (`country-select.css`) y deja alto,
   borde y radio al campo que lo contiene: así el mismo widget entra aquí y en
   `consulta` sin dos estilos compitiendo. */
.eb1-pais .cs-field,
.eb1-pais .cs-control,
.eb1-pais button[aria-haspopup="listbox"] {
  border-radius: 12px;
  border-width: 2px;
  min-height: 50px;
  font-size: 16px;
}

.eb1-consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 15px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--band);
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.5;
  cursor: pointer;
}
.eb1-consent input { margin-top: 2px; width: 18px; height: 18px; flex: none; accent-color: var(--blue); }

.eb1-campo-err .eb1-input,
.eb1-campo-err .eb1-consent { border-color: var(--error); }
.eb1-error { color: var(--error); font-size: 13.5px; font-weight: 600; margin-top: 8px; }
.eb1-aviso {
  margin-top: 18px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--wash);
  color: var(--navy);
  font-size: 14px;
  font-weight: 600;
}

/* El honeypot no se oculta con `display:none`: hay bots que lo detectan y lo
   saltan. Se saca de la pantalla y se retira del árbol de accesibilidad. */
.eb1-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

/* ---------- pie del cuestionario ---------- */
.eb1-foot {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
}
.eb1-atras {
  font-weight: 600;
  font-size: 15px;
  color: var(--muted);
  padding: 10px 4px;
}
.eb1-atras:hover { color: var(--navy); }
.eb1-next { margin-left: auto; }
@media (max-width: 559px) {
  .eb1-next { flex: 1; text-align: center; }
}
.eb1-reassure {
  margin-top: 14px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

/* ---------- resultado ---------- */
.eb1-res-eyebrow {
  display: block;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--success);
}
.eb1-res-h {
  font-family: var(--font-serif, inherit);
  font-weight: 600;
  font-size: clamp(23px, 3.2vw, 31px);
  line-height: 1.16;
  color: var(--navy);
  margin-top: 8px;
  text-wrap: balance;
}
.eb1-res-lead { color: var(--muted); font-size: 15.5px; margin-top: 12px; line-height: 1.6; }
.eb1-res-lead strong { color: var(--navy); }

.eb1-vias { display: grid; gap: 14px; margin-top: 26px; }
.eb1-via {
  border: 1px solid var(--line);
  border-left: 4px solid var(--line);
  border-radius: 14px;
  padding: 18px;
  background: var(--surface);
}
.eb1-via.alta { border-left-color: var(--success); background: var(--wash); }
.eb1-via.media { border-left-color: var(--blue); }
.eb1-via.baja { border-left-color: var(--line); }
.eb1-via.nula { opacity: .72; }

.eb1-via-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.eb1-via-cod { font-weight: 800; font-size: 13px; letter-spacing: .06em; color: var(--navy); }
.eb1-via-nivel {
  font-weight: 700;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--band);
  color: var(--muted);
}
.eb1-via-nivel.alta { background: var(--success); color: var(--surface); }
.eb1-via-nivel.media { background: var(--wash); color: var(--blue); }

.eb1-via-tit {
  font-family: var(--font-serif, inherit);
  font-weight: 600;
  font-size: 19px;
  color: var(--navy);
  margin-top: 8px;
}
.eb1-via-que { color: var(--muted); font-size: 14px; margin-top: 6px; line-height: 1.5; }
.eb1-via-sub {
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--muted);
  margin-top: 16px;
}

.eb1-lista { display: grid; gap: 7px; margin-top: 8px; }
.eb1-lista li {
  position: relative;
  padding-left: 22px;
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--navy);
}
.eb1-lista li::before {
  position: absolute;
  left: 0;
  top: 0;
  font-weight: 800;
}
/* Sin modificador, la viñeta es un guion: la lista de alternativas no afirma
   ni descarta nada, sólo enumera. */
.eb1-lista li::before { content: "–"; color: var(--muted); }
.eb1-lista.ok li::before { content: "✓"; color: var(--success); }
.eb1-lista.falta li::before { content: "?"; color: var(--blue); }
.eb1-lista.bloqueo li::before { content: "!"; color: var(--error); }
.eb1-lista.revisar li::before { content: "→"; color: var(--blue); }

.eb1-res-cols { display: grid; gap: 22px; margin-top: 28px; }
@media (min-width: 620px) { .eb1-res-cols { grid-template-columns: 1fr 1fr; } }
.eb1-res-col h4,
.eb1-revision h4,
.eb1-alternativas h4 {
  font-size: 15px;
  font-weight: 700;
  color: var(--navy);
}
.eb1-res-nota { color: var(--muted); font-size: 14px; margin-top: 6px; }
.eb1-revision, .eb1-alternativas { margin-top: 26px; }

.eb1-res-cta {
  margin-top: 30px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  text-align: center;
}
.eb1-res-cta-txt { color: var(--navy); font-size: 15.5px; line-height: 1.6; }
.eb1-res-cta .btn { margin-top: 16px; }
@media (max-width: 559px) { .eb1-res-cta .btn { display: block; width: 100%; } }
.eb1-legal { color: var(--muted); font-size: 12.5px; line-height: 1.55; margin-top: 16px; }

/* ---------- la barra fija de móvil cede el paso ---------- */
/* Mientras la evaluación está en pantalla, la barra inferior manda a donde ya
   estás y se come el «Continuar». La clase la pone la isla con un observador
   de intersección: el CSS no puede preguntar si algo está a la vista. Se
   anulan los TRES vectores —pintado, clic y árbol de accesibilidad—, porque
   con `opacity` sola queda un botón invisible que sigue recibiendo el toque. */
body.eb1-a-la-vista .mobile-cta {
  transform: translateY(120%);
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: transform .22s ease, opacity .22s ease;
}

/* Con movimiento reducido, las transiciones de la barra y de las opciones
   dejan de animar: el estado sigue siendo el mismo, sólo llega de golpe. */
@media (prefers-reduced-motion: reduce) {
  .eb1-barra > span, .eb1-opt, .eb1-pip { transition: none; }
  body.eb1-a-la-vista .mobile-cta { transition: none; }
}
