/* Checkout visual (sin backend): pago-1, pago-2, pago-3 y gracias. */

body.checkout-page { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }

.checkout { flex: 1; width: 100%; max-width: 620px; margin: 0 auto; padding: 148px 32px 96px; }
.checkout--amplio { max-width: 1060px; display: grid; grid-template-columns: minmax(0, 1fr) 396px; gap: 72px; align-items: start; }

.paso-eyebrow {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  font: 500 10px/1.35 "Vivita Bashan", sans-serif;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
}
.paso-eyebrow::before { content: ""; width: 24px; height: 2px; background: var(--red); flex: none; }
.checkout h1 {
  margin: 16px 0 0;
  font-family: "Vivita Bashan", sans-serif;
  font-weight: 500;
  font-size: var(--fl-h1);
  line-height: 1.05;
  letter-spacing: -.022em;
}
.evento-resumen { margin: 20px 0 0; font-size: 15.5px; line-height: 1.55; color: var(--muted); }
.evento-resumen strong { color: var(--ink); font-weight: 600; }

/* ---------- Paso 1: stepper ---------- */
.stepper-zona { margin-top: 52px; }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; background: var(--white); }
.stepper button {
  width: 56px;
  height: 56px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  font: 500 24px/1 "Vivita Bashan", sans-serif;
  color: var(--ink);
  cursor: pointer;
  transition: background 150ms var(--ease-out), transform 100ms var(--ease-out);
}
.stepper button:hover:not(:disabled) { background: rgba(221, 186, 132, .18); }
.stepper button:active:not(:disabled) { transform: scale(.96); }
.stepper button:disabled { opacity: .35; cursor: not-allowed; }
.stepper .valor { min-width: 72px; text-align: center; font: 500 24px/1 "Vivita Bashan", sans-serif; font-variant-numeric: tabular-nums; }
.stepper-nota { margin: 20px 0 0; font-size: 14.5px; line-height: 1.5; color: var(--muted); }
.stepper-nota strong { color: var(--ink); font-weight: 600; }
.total-vivo { margin: 36px 0 0; padding: 24px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.total-vivo .total-label { font: 500 12px/1 "Vivita Bashan", sans-serif; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.total-vivo .total-cifra { font: 500 34px/1 "Vivita Bashan", sans-serif; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }

/* ---------- Campos ---------- */
.campos { margin-top: 40px; display: grid; grid-template-columns: 1fr 1fr; gap: 24px 20px; }
.campo { display: flex; flex-direction: column; gap: 8px; }
.campo--full { grid-column: 1 / -1; }
.campo label {
  font: 500 10px/1.3 "Vivita Bashan", sans-serif;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--muted);
}
.campo input, .campo select {
  height: 52px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
  font: 16px/normal "Source Serif 4 Bashan", Georgia, serif;
  transition: border-color 140ms var(--ease-out), box-shadow 140ms var(--ease-out);
  appearance: none;
}
.campo input:focus, .campo select:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(221, 186, 132, .35); }
/* Con ratón basta el borde y el halo; el anillo rojo global queda para teclado. */
.campo input:focus:not(:focus-visible), .campo select:focus:not(:focus-visible) { outline: none; }
.campo input::placeholder { color: rgba(98, 94, 87, .55); }
.campo input[aria-invalid="true"] { border-color: var(--red); }
.campo-error { margin: 0; font-size: 12.5px; line-height: 1.35; color: var(--red); }
.campo--select { position: relative; }
.campo--select::after {
  content: "";
  position: absolute;
  right: 18px;
  bottom: 22px;
  width: 8px;
  height: 8px;
  border-right: 1.5px solid var(--muted);
  border-bottom: 1.5px solid var(--muted);
  transform: rotate(45deg);
  pointer-events: none;
}

/* ---------- Consentimientos ---------- */
.consentimientos { margin: 36px 0 0; display: grid; gap: 16px; }
.check { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; font-size: 14.5px; line-height: 1.45; color: var(--muted); }
.check strong { color: var(--ink); font-weight: 600; }
.check input { width: 18px; height: 18px; margin: 1px 0 0; flex: none; accent-color: var(--red); cursor: pointer; }

/* ---------- Acciones ---------- */
.acciones { margin-top: 40px; display: flex; flex-direction: column; gap: 20px; align-items: stretch; }
.btn-pagar {
  width: 100%;
  min-height: 60px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--red);
  border-radius: 999px;
  background: var(--red);
  color: var(--white);
  text-decoration: none;
  font: 500 15px/1 "Vivita Bashan", sans-serif;
  letter-spacing: .04em;
  cursor: pointer;
  transition: background 160ms var(--ease-out), transform 100ms var(--ease-out);
}
.btn-pagar:hover { background: #8F101F; border-color: #8F101F; }
.btn-pagar:active { transform: scale(.99); }
.volver {
  align-self: flex-start;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  color: var(--muted);
  text-decoration: none;
  font: 500 12px/1 "Vivita Bashan", sans-serif;
  letter-spacing: .05em;
  transition: color 150ms var(--ease-out);
}
.volver:hover { color: var(--ink); }

/* ---------- Método de pago ---------- */
.metodos { margin-top: 40px; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.metodo { position: relative; }
.metodo input { position: absolute; opacity: 0; pointer-events: none; }
.metodo .tarjeta-metodo {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 60px;
  padding: 0 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  cursor: pointer;
  font: 500 14px/1.2 "Vivita Bashan", sans-serif;
  letter-spacing: .02em;
  transition: border-color 140ms var(--ease-out), box-shadow 140ms var(--ease-out);
}
.metodo .tarjeta-metodo:hover { border-color: rgba(221, 186, 132, .9); }
.metodo .punto { width: 16px; height: 16px; flex: none; border: 1.5px solid var(--line); border-radius: 50%; display: inline-block; }
.metodo input:checked + .tarjeta-metodo { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(221, 186, 132, .28); }
.metodo input:checked + .tarjeta-metodo .punto { border-color: var(--gold); background: var(--gold); box-shadow: inset 0 0 0 3px var(--white); }
/* El anillo de foco sigue el patrón global en rojo: el dorado sobre blanco no contrasta. */
.metodo input:focus-visible + .tarjeta-metodo { outline: 3px solid var(--red); outline-offset: 2px; }

.nota-clave { margin: 24px 0 0; display: flex; gap: 12px; align-items: flex-start; font-size: 14.5px; line-height: 1.45; color: var(--muted); }
.nota-clave svg { flex: none; margin-top: 2px; }

/* ---------- Resumen ---------- */
.resumen {
  position: sticky;
  top: 110px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 32px 28px;
}
.resumen h2 { margin: 0; font-family: "Vivita Bashan", sans-serif; font-weight: 500; font-size: var(--fl-h3); letter-spacing: -.015em; }
.resumen-meta { margin: 12px 0 0; font-size: 14.5px; line-height: 1.6; color: var(--muted); }
.resumen-sep { height: 1px; background: var(--line); margin: 24px 0; }
.resumen-fila { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; font-size: 15.5px; }
.resumen-fila span:last-child { font-variant-numeric: tabular-nums; white-space: nowrap; }
.resumen-total { margin-top: 16px; display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.resumen-total > span:first-child { font: 500 13px/1 "Vivita Bashan", sans-serif; letter-spacing: .1em; text-transform: uppercase; }
/* El total es el elemento más grande del resumen (display Vivita, 40px). */
.resumen-total .total-flip { font: 500 40px/1.02 "Vivita Bashan", sans-serif; letter-spacing: -.025em; font-variant-numeric: tabular-nums; }
/* Total que alterna entre bolívares y dólares: flip vertical suave.
   La fuente la fija el contenedor de cada página; los montos heredan. */
.total-flip { display: inline-grid; overflow: hidden; text-align: right; }
.total-flip .total-monto { grid-area: 1 / 1; font: inherit; white-space: nowrap; transition: transform 550ms var(--ease-in-out), opacity 550ms var(--ease-out); }
.total-flip .total-monto.fuera-arriba { transform: translateY(-115%); opacity: 0; }
.total-flip .total-monto.fuera-abajo { transform: translateY(115%); opacity: 0; }
.total-flip .total-monto.sin-transicion { transition: none; }
/* Con movimiento reducido: ambos valores quietos, uno debajo del otro. */
.total-flip.total-flip--estatico { overflow: visible; }
.total-flip.total-flip--estatico .total-monto { grid-area: auto; transform: none; opacity: 1; transition: none; }
.total-flip.total-flip--estatico .total-monto--bs { margin-top: 4px; font-size: .45em; letter-spacing: 0; color: var(--muted); }
/* Píldora de tasa: «Tasa BCV · Bs 896,12» en letra de marca. */
.resumen-bcv { margin: 20px 0 0; padding: 12px 16px; border-radius: 12px; background: rgba(221, 186, 132, .14); font: 500 11px/1.4 "Vivita Bashan", sans-serif; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.resumen-bcv strong { color: var(--ink); font-weight: 500; }
.resumen-bcv .bcv-sep { color: var(--gold); }
.resumen-seguro { margin: 24px 0 0; display: flex; align-items: center; gap: 8px; font: 500 10.5px/1.4 "Vivita Bashan", sans-serif; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.resumen-seguro svg { flex: none; }

/* ---------- Gracias ---------- */
.gracias-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 148px 24px 72px;
}
.sello {
  width: 124px;
  height: 124px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(221, 186, 132, .75);
  border-radius: 50%;
  background: radial-gradient(circle at 50% 35%, rgba(221, 186, 132, .16), rgba(221, 186, 132, 0) 68%);
}
.sello img { height: 56px; width: auto; }
.gracias-main h1 { margin: 36px 0 0; max-width: 640px; font-family: "Vivita Bashan", sans-serif; font-weight: 500; font-size: var(--fl-h1); line-height: 1.05; letter-spacing: -.022em; }
.gracias-texto { margin: 24px 0 0; max-width: 500px; font-size: 17.5px; line-height: 1.6; color: var(--muted); }
.gracias-texto strong { color: var(--ink); font-weight: 600; }
.btn-oro-grande {
  margin-top: 40px;
  min-height: 56px;
  padding: 0 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--gold);
  border-radius: 999px;
  background: var(--gold);
  color: var(--ink);
  text-decoration: none;
  font: 500 13px/1.2 "Vivita Bashan", sans-serif;
  letter-spacing: .045em;
  transition: box-shadow 160ms var(--ease-out), transform 100ms var(--ease-out);
}
.btn-oro-grande:hover { box-shadow: 0 8px 24px rgba(221, 186, 132, .45); }
.btn-oro-grande:active { transform: scale(.98); }

/* ---------- Pie de las páginas de compra ---------- */
.pie {
  border-top: 1px solid var(--line);
  padding: 28px 32px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}
.pie-logos { display: flex; align-items: center; gap: 16px; }
.pie-logos a { min-height: 44px; display: inline-flex; align-items: center; transition: opacity 150ms var(--ease-out); }
.pie-logos a:hover { opacity: .72; }
.pie-logos .pie-bashan { height: 17px; width: auto; display: block; }
.pie-logos .pie-x { color: rgba(98, 94, 87, .5); font-size: 12px; }
.pie-logos .pie-onset-claro { height: 14px; width: auto; display: block; }
.pie-powered { margin: 0; font: 500 10px/1 "Vivita Bashan", sans-serif; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.pie-legal { margin: 4px 0 0; font-size: 12.5px; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .total-flip .total-monto { transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .checkout { padding: 120px 24px 80px; }
  .checkout--amplio { grid-template-columns: 1fr; gap: 48px; }
  .resumen { position: static; order: -1; padding: 24px 20px; }
  .campos { grid-template-columns: 1fr; }
  .metodos { grid-template-columns: 1fr; }
  .stepper button { width: 52px; height: 52px; }
  .gracias-main { padding-top: 132px; }
  .sello { width: 108px; height: 108px; }
  .sello img { height: 48px; }
  .gracias-texto { font-size: 15.5px; }
  .btn-oro-grande { width: 100%; max-width: 320px; }
  .pie { padding: 24px 20px 32px; }
}


/* ---------- Paso 2 reestructurado ---------- */
.compra-resumen { margin: 16px 0 0; font-size: 14.5px; line-height: 1.5; color: var(--muted); }
.compra-resumen strong { color: var(--ink); font-weight: 600; }
#form-datos { margin-top: 12px; }
.grupo { margin-top: 40px; }
.grupo-titulo {
  margin: 0 0 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  font: 500 11px/1.3 "Vivita Bashan", sans-serif;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}
.grupo .campos { margin-top: 0; }
.check a { color: var(--ink); text-decoration: underline; text-decoration-color: rgba(168, 20, 36, .5); text-underline-offset: 3px; }
.check a:hover { text-decoration-color: var(--red); }
.consentimientos .campo-error { margin: 4px 0 0 30px; }

/* Botón apagado mientras falta algo: se ve deshabilitado y avisa al intentar. */
.btn-pagar[aria-disabled="true"] { opacity: .45; cursor: not-allowed; }
.btn-pagar[aria-disabled="true"]:hover { background: var(--red); border-color: var(--red); }
.btn-pagar[aria-disabled="true"]:active { transform: none; }

/* ---------- Dropdown de bancos propio (sin picker nativo) ---------- */
.select-oculto { display: none; }
html.js .campo--select::after { display: none; }
.campo-banco { position: relative; }
.combo { position: relative; }
.combo-boton {
  width: 100%;
  height: 52px;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--muted);
  font: 16px/1 "Source Serif 4 Bashan", Georgia, serif;
  cursor: pointer;
  transition: border-color 140ms var(--ease-out), transform 100ms var(--ease-out);
}
.combo-boton.con-valor { color: var(--ink); }
.combo-boton:hover { border-color: rgba(221, 186, 132, .9); }
.combo-boton:active { transform: scale(.99); }
.combo-boton:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
.combo-boton svg { flex: none; color: var(--muted); transition: transform 200ms var(--ease-out); }
.combo-boton[aria-expanded="true"] { border-color: var(--gold); }
.combo-boton[aria-expanded="true"] svg { transform: rotate(180deg); }
.combo-lista {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 40;
  margin: 0;
  padding: 6px;
  max-height: 264px;
  overflow-y: auto;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  box-shadow: 0 18px 44px rgba(22, 22, 22, .14);
  scrollbar-width: thin;
  scrollbar-color: rgba(221, 186, 132, .8) transparent;
}
.combo-lista::-webkit-scrollbar { width: 8px; }
.combo-lista::-webkit-scrollbar-thumb { background: rgba(221, 186, 132, .8); border-radius: 8px; }
.combo-lista::-webkit-scrollbar-track { background: transparent; }
.combo-lista:focus { outline: none; }
.combo-opcion {
  padding: 12px;
  border-radius: 8px;
  font: 15px/1.3 "Source Serif 4 Bashan", Georgia, serif;
  color: var(--ink);
  cursor: pointer;
  transition: background 120ms var(--ease-out);
}
.combo-opcion:hover { background: rgba(221, 186, 132, .12); }
.combo-opcion.activa { background: rgba(221, 186, 132, .18); }
.combo-opcion[aria-selected="true"] { background: rgba(221, 186, 132, .32); font-weight: 600; }

/* ---------- Clave de autorización (débito inmediato) ---------- */
.campo-clave { margin-top: 20px; max-width: 240px; }
.campo-clave input { letter-spacing: .35em; font-variant-numeric: tabular-nums; }
.campo-clave input::placeholder { letter-spacing: .35em; }

/* ---------- Imagen de la entrada en el resumen ---------- */
.resumen-entrada {
  position: relative;
  margin: 20px 0 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--ivory);
}
.resumen-entrada img { display: block; width: 100%; height: auto; }
.resumen-rotulo {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 36px 16px 12px;
  background: linear-gradient(180deg, rgba(248, 248, 248, 0) 0%, rgba(248, 248, 248, .88) 45%, rgba(248, 248, 248, .97) 100%);
  font: 500 10px/1.55 "Vivita Bashan", sans-serif;
  letter-spacing: .11em;
  text-transform: uppercase;
  color: var(--ink);
}
.resumen-rotulo small { display: block; font-size: 9px; color: var(--muted); }

/* ---------- Páginas legales ---------- */
.legal { max-width: 720px; }
.legal-fecha { margin: 16px 0 0; font-size: 13.5px; color: var(--muted); }
.legal h2 {
  margin: 40px 0 0;
  font-family: "Vivita Bashan", sans-serif;
  font-weight: 500;
  font-size: var(--fl-h3);
  letter-spacing: -.01em;
  color: var(--ink);
}
.legal p { margin: 12px 0 0; font-size: 16px; line-height: 1.7; }
.legal ul { margin: 12px 0 0; padding-left: 24px; font-size: 16px; line-height: 1.7; }
.legal li { margin-top: 8px; }
.legal a { color: var(--ink); text-decoration: underline; text-decoration-color: rgba(168, 20, 36, .5); text-underline-offset: 3px; }
.legal a:hover { text-decoration-color: var(--red); }
.legal .volver { margin-top: 44px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .combo-lista { max-height: 40vh; }
  .campo-clave { max-width: none; }
  .resumen-total .total-flip { font-size: 36px; }
}
