/* Formulario público de compra de boletos (ticketeria/comprar.html).
   Misma estética que el formulario de CIMA: indicador de pasos, una tarjeta
   de 700 px y Anterior/Siguiente debajo. Viene de la maqueta aprobada el
   09/10/2026. */
:root {
  --primary: #111827;
  --primary-dark: #0a0f1a;
  --primary-light: #f3f4f6;
  --text-dark: #111827;
  --text-gray: #6b7280;
  --gris-claro: #9ca3af;
  --border: #e5e7eb;
  --bg-light: #fafbfc;
  --bg-white: #ffffff;
  --success: #059669;
  --success-soft: #ecfdf5;
  --danger: #dc2626;
  --danger-soft: #fef2f2;
  --warning: #b45309;
  --warning-soft: #fffbeb;
  --yappy: #0a4a9b;
  --yappy-naranja: #f7941d;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.04);
  --shadow-md: 0 4px 12px rgba(0,0,0,.08);
  --f-display: "Poppins", "Segoe UI", system-ui, sans-serif;
  --f-body: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --f-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  color-scheme: light;
}
* { box-sizing: border-box; }
/* `.btn` y `.tipo` llevan display propio, que le gana al atributo hidden. */
[hidden] { display: none !important; }
body {
  margin: 0; font-family: var(--f-body); color: var(--text-dark); line-height: 1.6;
  background: linear-gradient(135deg, var(--bg-light) 0%, #f3f4f6 100%);
  -webkit-font-smoothing: antialiased; min-height: 100%;
}
.registro-container { min-height: 100%; display: flex; flex-direction: column; padding-inline: 20px; padding-block: 20px 48px; }

/* La cabecera del evento es un componente: css/components/cabecera-evento.css. */

/* Indicador de pasos */
.progress-indicator { position: relative; margin-bottom: 50px; }
/* Del mismo ancho que la cabecera y la tarjeta (700 px). */
.steps-container { position: relative; display: flex; justify-content: space-between; max-width: 700px; margin: 0 auto; }
.steps-container::before { content: ""; position: absolute; top: 20px; left: 40px; right: 40px; height: 2px; background: var(--border); }
.progress-bar { position: absolute; top: 20px; left: 40px; height: 2px; background: var(--primary); width: 0; transition: width .5s ease-out; }
.step { position: relative; display: flex; flex-direction: column; align-items: center; gap: 8px; width: 96px; opacity: .4; transition: opacity .3s; }
.step.active, .step.done { opacity: 1; }
.step-number {
  width: 40px; height: 40px; border-radius: 50%; background: var(--bg-white); border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--text-gray); box-shadow: var(--shadow-sm);
}
.step.active .step-number { background: var(--primary); color: #fff; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(17,24,39,.08); }
.step.done .step-number { background: var(--primary); color: #fff; border-color: var(--primary); }
.step-label { font-size: .8rem; font-weight: 500; color: var(--text-gray); text-align: center; }
.step.active .step-label { color: var(--primary); }

/* Tarjeta del paso */
.registro-content { max-width: 700px; margin: 0 auto; width: 100%; min-width: 0; }
.paso { background: var(--bg-white); border-radius: 12px; padding: 40px; box-shadow: var(--shadow-md); animation: fadeInUp .45s ease-out; }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.paso-header { margin-bottom: 32px; }
.paso-header h2 { font-family: var(--f-display); font-size: 1.8rem; font-weight: 700; letter-spacing: -.5px; margin: 0 0 8px; }
.paso-descripcion { font-size: 1rem; color: var(--text-gray); margin: 0; }

/* Campos */
.paso-form { display: flex; flex-direction: column; gap: 24px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.form-group label { font-weight: 500; font-size: .95rem; }
.required { color: var(--danger); }
.form-group input, .form-group select {
  height: 48px; border: 1.5px solid var(--border); border-radius: 8px; padding: 0 14px;
  font: inherit; font-size: .95rem; color: var(--text-dark); background: var(--bg-white); width: 100%; min-width: 0;
}
.form-group input:focus, .form-group select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(17,24,39,.08); }
.form-group.is-error input, .form-group.is-error .tel { border-color: var(--danger); }
.error-message { font-size: .85rem; color: var(--danger); }
.error-message:empty { display: none; }
.ayuda { font-size: .85rem; color: var(--text-gray); }
.tel { display: flex; height: 48px; border: 1.5px solid var(--border); border-radius: 8px; overflow: hidden; }
.tel:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(17,24,39,.08); }
.form-group .tel select { width: auto; flex: 0 0 auto; height: 100%; border: 0; border-right: 1.5px solid var(--border); border-radius: 0; padding: 0 8px; background: var(--primary-light); }
.form-group .tel input { height: 100%; border: 0; border-radius: 0; flex: 1; box-shadow: none; }

/* Paso 2: boletos */
.boletos { display: flex; flex-direction: column; gap: 12px; }
.tipo { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 14px; align-items: center; border: 1.5px solid var(--border); border-radius: 12px; padding: 16px 18px; transition: border-color .2s; }
.tipo.is-elegido { border-color: var(--primary); }
.tipo.is-agotado { opacity: .55; background: var(--primary-light); }
.tipo__cab { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tipo__nombre { font-family: var(--f-display); font-weight: 600; font-size: 1.05rem; }
.tipo__inc { color: var(--text-gray); font-size: .9rem; margin-top: 2px; }
.tipo__precio { margin-top: 6px; font-weight: 700; font-variant-numeric: tabular-nums; }
.tipo__antes { color: var(--gris-claro); text-decoration: line-through; font-weight: 500; font-size: .9rem; margin-left: 6px; }
.chip { font-size: 11.5px; font-weight: 600; padding: 2px 9px; border-radius: 999px; }
.chip--promo { background: var(--success-soft); color: var(--success); }
.chip--quedan { background: var(--warning-soft); color: var(--warning); }
.chip--agotado { background: var(--danger-soft); color: var(--danger); }
.contador { display: flex; align-items: center; border: 1.5px solid var(--border); border-radius: 10px; overflow: hidden; }
.contador button { width: 42px; height: 42px; border: 0; background: transparent; font-size: 20px; color: var(--text-dark); cursor: pointer; font-family: inherit; }
.contador button:hover:not(:disabled) { background: var(--primary-light); }
.contador button:disabled { color: #d1d5db; cursor: not-allowed; }
.contador output { min-width: 34px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }
.tope { font-size: .85rem; color: var(--text-gray); }
.tope.is-limite { color: var(--warning); font-weight: 600; }
.subtotal { display: flex; justify-content: space-between; align-items: baseline; padding-top: 18px; border-top: 1px solid var(--border); font-variant-numeric: tabular-nums; }
.subtotal span { color: var(--text-gray); }
.subtotal strong { font-size: 1.25rem; }
.cupon { display: flex; gap: 8px; }
.cupon input { text-transform: uppercase; }
.cupon-ok { display: flex; gap: 8px; align-items: center; color: var(--success); background: var(--success-soft); border-radius: 8px; padding: 10px 14px; font-size: .9rem; font-weight: 500; }

/* Paso 3: términos */
.terminos-texto { border: 1.5px solid var(--border); border-radius: 10px; padding: 20px 22px; max-height: 320px; overflow-y: auto; font-size: .93rem; color: #374151; background: var(--bg-light); }
.terminos-texto h4 { margin: 18px 0 6px; font-size: .95rem; color: var(--text-dark); }
.terminos-texto h4:first-child { margin-top: 0; }
.terminos-texto p { margin: 0 0 8px; }
.acepto { display: flex; gap: 12px; align-items: flex-start; font-size: .95rem; cursor: pointer; }
.acepto input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--primary); flex-shrink: 0; }

/* Paso 4: resumen y pago */
.bloque-titulo { font-family: var(--f-display); font-weight: 600; font-size: 1.05rem; margin: 0 0 12px; }
.resumen { border: 1.5px solid var(--border); border-radius: 12px; padding: 18px 20px; }
.linea { display: flex; justify-content: space-between; gap: 12px; padding: 5px 0; font-size: .95rem; font-variant-numeric: tabular-nums; }
.linea__txt { color: #374151; min-width: 0; }
.linea--desc { color: var(--success); }
.linea--total { border-top: 1px solid var(--border); margin-top: 10px; padding-top: 12px; font-weight: 700; font-size: 1.15rem; }
.datos { display: grid; grid-template-columns: auto 1fr; gap: 4px 18px; margin: 0; font-size: .93rem; }
.datos dt { color: var(--text-gray); }
.datos dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }
.apartado { display: flex; gap: 10px; align-items: center; color: var(--warning); background: var(--warning-soft); border-radius: 10px; padding: 12px 16px; font-size: .93rem; }
.apartado strong { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
.metodos { display: grid; grid-template-columns: minmax(0,1fr); gap: 12px; }
.metodo { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; border: 1.5px solid var(--border); border-radius: 12px; padding: 16px 18px; background: var(--bg-white); font: inherit; color: inherit; cursor: pointer; transition: border-color .2s; }
.metodo:hover { border-color: var(--primary); }
.metodo__txt { flex: 1; min-width: 0; }
.metodo__nombre { font-weight: 600; display: block; }
.metodo__det { font-size: .85rem; color: var(--text-gray); }
.procesando { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 24px 0 8px; text-align: center; color: var(--text-gray); }
.procesando strong { color: var(--text-dark); }
.giro { width: 38px; height: 38px; border-radius: 50%; border: 3px solid var(--border); border-top-color: var(--primary); animation: giro .9s linear infinite; }
@keyframes giro { to { transform: rotate(360deg); } }

/* Fin: boletos */
.hecho { text-align: center; }
.hecho__sello { width: 64px; height: 64px; border-radius: 50%; background: var(--success-soft); color: var(--success); display: grid; place-items: center; margin: 0 auto 16px; }
.hecho h2 { font-family: var(--f-display); font-size: 1.8rem; letter-spacing: -.5px; margin: 0 0 8px; }
.hecho p { color: var(--text-gray); margin: 0 auto; max-width: 46ch; }
.codigo { display: inline-flex; flex-direction: column; gap: 2px; margin-top: 22px; padding: 12px 22px; border: 1.5px dashed #d1d5db; border-radius: 10px; }
.codigo span { font-size: 12px; color: var(--text-gray); text-transform: uppercase; letter-spacing: .8px; }
.codigo strong { font-family: var(--f-mono); font-size: 1.2rem; letter-spacing: 1.5px; }
.acciones { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 24px; }
.cuidado { display: flex; gap: 14px; align-items: flex-start; text-align: left; margin-top: 32px; padding: 18px 20px; border-radius: 12px; background: var(--warning-soft); border: 1px solid #fde68a; color: #78350f; }
.cuidado svg { flex-shrink: 0; color: var(--warning); margin-top: 2px; }
.cuidado strong { display: block; font-family: var(--f-display); font-weight: 600; color: #78350f; margin-bottom: 4px; }
.cuidado ul { margin: 6px 0 0; padding-left: 18px; font-size: .93rem; }
.cuidado li + li { margin-top: 4px; }

/* Botones (los de CIMA) */
.registro-footer { display: flex; gap: 12px; justify-content: flex-end; max-width: 700px; margin: 40px auto 0; width: 100%; }
.btn { text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 13px 24px; border-radius: 8px; border: 0; font: inherit; font-size: .95rem; font-weight: 600; cursor: pointer; transition: all .3s cubic-bezier(.4,0,.2,1); }
.btn:focus-visible, .metodo:focus-visible, .contador button:focus-visible, .enlace:focus-visible { outline: 3px solid rgba(17,24,39,.35); outline-offset: 2px; }
.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-md); }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); }
.btn-secondary { background: var(--bg-light); color: var(--text-dark); border: 1.5px solid var(--border); }
.btn-secondary:hover { background: var(--bg-white); border-color: var(--primary); }
.enlace { background: none; border: 0; padding: 0; font: inherit; color: var(--text-dark); font-weight: 600; text-decoration: underline; cursor: pointer; }

/* Pie: el de CIMA (logo + políticas), con los términos generales de KODAsys */
.content-footer { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 40px 20px 8px; margin-top: 48px; border-top: 1px solid var(--border); text-align: center; max-width: 1060px; width: 100%; margin-inline: auto; }
.footer-logo { font-family: var(--f-display); font-weight: 700; font-size: 1.15rem; letter-spacing: -.3px; color: var(--text-dark); opacity: .75; }
.footer-logo span { font-weight: 500; color: var(--text-gray); }
.footer-credit { font-size: .85rem; color: var(--text-gray); margin: 0; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; font-size: .85rem; }
.footer-link { background: none; border: 0; padding: 0; font: inherit; color: var(--primary); font-weight: 600; cursor: pointer; text-decoration: none; }
.footer-link:hover { text-decoration: underline; }
.footer-link:focus-visible { outline: 3px solid rgba(17,24,39,.35); outline-offset: 2px; border-radius: 4px; }

.aviso-flotante { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--primary); color: #fff; padding: 12px 18px; border-radius: 10px; font-size: 14px; z-index: 60; box-shadow: 0 10px 30px rgba(0,0,0,.2); max-width: calc(100% - 32px); text-align: center; }

@media (max-width: 640px) {
  .registro-container { padding-inline: 16px; }
  .paso { padding: 24px 18px; }
  .paso-header h2 { font-size: 1.45rem; }
  .form-row { grid-template-columns: minmax(0,1fr); }
  .step { width: 70px; }
  .step-label { font-size: .72rem; }
  /* Contador a la derecha del nombre también en el teléfono: debajo, cada
     tipo ocupaba un bloque alto y el plano de butacas quedaba muy abajo. */
  .tipo { padding: 14px 14px 14px 16px; gap: 10px; }
  .contador button { width: 38px; }
  .registro-footer { flex-direction: column-reverse; }
  .registro-footer .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation-duration: .01ms !important; } }

.footer-logo-img { height: 32px; opacity: .7; }
.cerrada { text-align: center; }
.cerrada h2 { font-family: var(--f-display); font-size: 1.5rem; margin: 0 0 8px; }
.cerrada p { color: var(--text-gray); margin: 0; }
.pago-pendiente { display: flex; gap: 10px; align-items: flex-start; color: #1e3a8a; background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 10px; padding: 12px 16px; font-size: .93rem; }
.metodo[disabled] { opacity: .55; cursor: not-allowed; }
.metodo[disabled]:hover { border-color: var(--border); }

/* ---------- Métodos de pago con sus logos oficiales ---------- */
.metodo { min-height: 76px; }
.metodo:not([disabled]):hover { border-color: var(--yappy); box-shadow: 0 0 0 3px rgba(10,74,155,.08); }
.metodo__marca { width: 108px; height: 44px; flex-shrink: 0; display: grid; place-items: center; border: 1px solid var(--border); border-radius: 10px; background: #fff; }
.metodo__marca img { max-width: 86px; height: auto; display: block; }
.metodo__ir { color: var(--yappy); flex-shrink: 0; }
.metodo__tarjetas { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.metodo__tarjetas img { opacity: .7; }
.metodo[disabled] { opacity: 1; background: var(--bg-light); }
.seguro { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: .84rem; color: var(--text-gray); }
.seguro li { display: flex; align-items: center; gap: 6px; }
.seguro svg { color: var(--success); flex-shrink: 0; }
.seguro strong { color: var(--text-dark); font-weight: 600; }

/* ---------- Modal de Yappy (pago simulado) ---------- */
body.yp-abierto { overflow: hidden; }
.yp-capa { position: fixed; inset: 0; z-index: 80; background: rgba(10,15,26,.55); backdrop-filter: blur(3px); display: grid; place-items: center; padding: 16px; box-sizing: border-box; animation: fadeIn .2s ease-out; }
.yp { width: 100%; max-width: 400px; max-height: calc(100dvh - 32px); overflow-y: auto; background: #fff; border-radius: 18px; box-shadow: 0 24px 60px rgba(0,0,0,.25); animation: fadeInUp .3s ease-out; }
.yp__cab { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 0; }
.yp__cerrar { width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--primary-light); color: var(--text-gray); display: grid; place-items: center; cursor: pointer; }
.yp__cerrar:hover { color: var(--text-dark); }
.yp__monto { margin: 16px 20px 0; padding: 16px; border-radius: 14px; text-align: center; background: linear-gradient(135deg, #eef5ff, #fff6ec); display: flex; flex-direction: column; gap: 2px; }
.yp__monto span { font-size: .8rem; color: var(--text-gray); text-transform: uppercase; letter-spacing: .6px; }
.yp__monto strong { font-family: var(--f-display); font-size: 2rem; color: var(--yappy); line-height: 1.2; font-variant-numeric: tabular-nums; }
.yp__monto small { color: var(--text-gray); font-size: .82rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.yp__cuerpo { padding: 20px; display: flex; flex-direction: column; gap: 8px; }
.yp__cuerpo h3 { font-family: var(--f-display); font-size: 1.15rem; margin: 0 0 4px; }
.yp__cuerpo label { font-size: .88rem; font-weight: 600; }
.yp__tel { display: flex; height: 50px; border: 1.5px solid var(--border); border-radius: 10px; overflow: hidden; }
.yp__tel:focus-within { border-color: var(--yappy); box-shadow: 0 0 0 3px rgba(10,74,155,.12); }
.yp__tel span { display: grid; place-items: center; padding: 0 12px; background: var(--primary-light); border-right: 1.5px solid var(--border); font-weight: 600; font-size: .95rem; white-space: nowrap; }
.yp__tel input { flex: 1; min-width: 0; border: 0; outline: 0; padding: 0 14px; font: inherit; font-size: 1.1rem; letter-spacing: 1px; font-variant-numeric: tabular-nums; }
.yp__ayuda { margin: 4px 0 8px; font-size: .86rem; color: var(--text-gray); }
.yp__btn { height: 50px; border: 0; border-radius: 12px; background: var(--yappy); color: #fff; font: inherit; font-weight: 600; font-size: 1rem; cursor: pointer; transition: background .2s; }
.yp__btn:hover { background: #083b7c; }
.yp__btn:focus-visible, .yp__cerrar:focus-visible { outline: 3px solid rgba(10,74,155,.4); outline-offset: 2px; }
.yp__espera { align-items: center; text-align: center; }
.yp__espera p { margin: 0; color: var(--text-gray); font-size: .92rem; }
.yp__espera p strong { color: var(--text-dark); }
.yp__movil { position: relative; width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; color: var(--yappy); background: #eef5ff; margin-bottom: 8px; }
.yp__pulso { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--yappy-naranja); animation: ypPulso 1.6s ease-out infinite; }
@keyframes ypPulso { from { transform: scale(1); opacity: .9; } to { transform: scale(1.45); opacity: 0; } }
.yp__estado { display: flex; align-items: center; gap: 10px; margin-top: 10px; padding: 10px 14px; border-radius: 10px; background: var(--bg-light); font-size: .9rem; font-weight: 500; }
.giro--sm { width: 18px; height: 18px; border-width: 2px; border-top-color: var(--yappy); }
.is-aprobado .yp__estado { background: var(--success-soft); color: var(--success); }
.is-aprobado .giro--sm { border-top-color: var(--success); }
.is-aprobado .yp__movil { color: var(--success); background: var(--success-soft); }
.is-aprobado .yp__pulso { border-color: var(--success); }
.yp__vence { font-size: .82rem !important; }
.yp__pie { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 12px 20px; border-top: 1px solid var(--border); font-size: .8rem; color: var(--text-gray); }
.yp__pie svg { color: var(--success); }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@media (max-width: 640px) {
  .yp-capa { place-items: end center; padding: 0; }
  .yp { max-width: none; border-radius: 18px 18px 0 0; max-height: 92dvh; padding-bottom: env(safe-area-inset-bottom, 0px); }
  .metodo { gap: 12px; padding: 14px; }
  .metodo__marca { width: 84px; height: 40px; }
  .metodo__marca img { max-width: 68px; }
}
.yp__espera p strong { white-space: nowrap; }
@media (max-width: 640px) {
  .metodo { flex-wrap: wrap; row-gap: 6px; }
}


/* Fin: aviso de que los boletos se enviaron por correo */
.enviado { display: flex; gap: 10px; align-items: flex-start; text-align: left; max-width: 520px; margin: 20px auto 0; padding: 12px 16px; border-radius: 10px; background: var(--success-soft); color: #065f46; font-size: .93rem; }
.enviado svg { flex-shrink: 0; color: var(--success); margin-top: 1px; }
.enviado strong { overflow-wrap: anywhere; }

/* ---------- Pago en línea: el cobro de verdad (PagueloFacil o PayPal) ---------- */
/* El color de la marca se queda en el logo: en el borde se leería como un error. */
.metodo--linea:not([disabled]):hover { border-color: var(--text-dark); box-shadow: 0 0 0 3px rgba(17,24,39,.08); }
.metodo--linea .metodo__ir { color: var(--text-dark); }
.metodo--linea[aria-busy="true"] { cursor: progress; }
.metodo--linea[aria-busy="true"] .metodo__ir { display: none; }
.metodo__error { display: block; margin-top: 8px; color: var(--danger); font-size: .88rem; }
.metodo__error:empty { display: none; }

/* Vuelta de la pasarela (pago_resultado.html) */
/* Sin animación de entrada: «confirmando» se recarga cada 5 s y parpadearía. */
.resultado { display: flex; flex-direction: column; align-items: center; gap: 4px; animation: none; }
.resultado p { max-width: 46ch; }
.resultado__giro { margin-bottom: 14px; }
.resultado__icono { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; margin-bottom: 14px; background: var(--danger-soft); color: var(--danger); }
.resultado__icono--aviso { background: var(--warning-soft); color: var(--warning); }
.resultado__contacto { margin-top: 10px !important; }

/* ---------- Butacas (módulo Teatro): resumen en el paso 2 ---------- */
.butacas { margin-top: 20px; display: flex; flex-direction: column; gap: 10px; padding: 16px; border: 1.5px dashed var(--border); border-radius: 12px; }
.butacas.is-completo { border-style: solid; border-color: var(--success); background: var(--success-soft); }
.butacas .bloque-titulo { margin: 0; }
.butacas__cuenta { display: flex; flex-direction: column; gap: 6px; }
.butacas__fila { display: flex; flex-direction: column; gap: 2px; }
.butacas__tipo { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.butacas__tipo i { width: 10px; height: 10px; border-radius: 50%; }
.butacas__tipo strong { color: var(--warning); font-weight: 700; }
.butacas__fila.is-completo .butacas__tipo strong { color: var(--success); }
.butacas__donde { font-size: .9rem; color: var(--text-gray); }
.butacas__btn { height: 48px; border-radius: 10px; border: 0; background: var(--text-dark); color: #fff; font: inherit; font-weight: 600; font-size: 1rem; cursor: pointer; }
.butacas__btn.is-secundario { background: #fff; color: var(--text-dark); border: 1.5px solid var(--border); }
.butacas__btn:focus-visible { outline: 3px solid rgba(17,24,39,.35); outline-offset: 2px; }
.butacas__nota { margin: 0; font-size: .84rem; color: var(--text-gray); }
.butacas.is-completo .butacas__nota { display: none; }

/* ---------- Selector de butacas a pantalla completa (selector-butacas.js) ---------- */
html.sb-abierto, html.sb-abierto body { overflow: hidden; }
.sb { position: fixed; inset: 0; z-index: 90; background: #fff; display: flex; align-items: center; justify-content: center; }
.sb[hidden] { display: none; }
.sb__caja { display: flex; flex-direction: column; width: 100%; height: 100%; background: #fff; }
.sb__cab { display: flex; align-items: center; gap: 12px; padding: 12px 12px 12px 18px; border-bottom: 1px solid var(--border); }
.sb__cab-txt { flex: 1; min-width: 0; }
.sb__titulo { margin: 0; font-family: var(--f-display); font-size: 1.1rem; }
.sb__sub { margin: 2px 0 0; font-size: .88rem; color: var(--text-gray); }
.sb__cerrar { width: 44px; height: 44px; flex-shrink: 0; border-radius: 50%; border: 0; background: var(--primary-light); color: var(--text-dark); display: grid; place-items: center; cursor: pointer; }
.sb__lienzo { position: relative; flex: 1; min-height: 0; overflow: hidden; background: #f6f7f9; touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.sb__lienzo:active { cursor: grabbing; }
.sb__lienzo > svg { position: absolute; inset: 0; width: 100%; height: 100%; transform-origin: 0 0; will-change: transform; }
.sb__lienzo > svg.sb-anim { transition: transform .28s ease; }
.sb__lienzo .pb-butaca.is-libre, .sb__lienzo .pb-butaca.is-tuya { cursor: pointer; }
.sb__zoom { position: absolute; right: 12px; top: 12px; display: flex; flex-direction: column; gap: 8px; }
.sb__zoom button { width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--border); background: #fff; color: var(--text-dark); font: inherit; font-size: 1.4rem; font-weight: 600; line-height: 1; display: grid; place-items: center; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.1); }
.sb__zoom button:disabled { color: #d1d5db; box-shadow: none; cursor: default; }
.sb__aviso { position: absolute; left: 50%; bottom: 14px; transform: translate(-50%, 8px); max-width: calc(100% - 32px); padding: 9px 16px; border-radius: 999px; background: rgba(17,24,39,.9); color: #fff; font-size: .88rem; text-align: center; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; }
.sb__aviso.is-visible { opacity: 1; transform: translate(-50%, 0); }
.sb__leyenda { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px 18px; padding: 8px 12px; font-size: .82rem; color: var(--text-gray); border-top: 1px solid var(--border); }
.sb__leyenda span { display: inline-flex; align-items: center; gap: 6px; }
.sbl { width: 12px; height: 12px; border-radius: 50%; display: inline-block; }
.sbl--libre { background: #fff; box-shadow: inset 0 0 0 2px var(--text-gray); }
.sbl--tuya { background: var(--text-dark); }
.sbl--ocupada { background: #e5e7eb; }
.sb__pie { display: flex; flex-direction: column; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--border); box-shadow: 0 -4px 16px rgba(0,0,0,.05); }
.sb__elegidas { display: flex; flex-wrap: wrap; gap: 6px; min-height: 34px; align-items: center; }
.sb__chip { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 10px 0 12px; border-radius: 999px; border: 1.5px solid var(--border); background: #fff; font: inherit; font-size: .88rem; font-weight: 600; color: var(--text-dark); cursor: pointer; }
.sb__chip i { width: 10px; height: 10px; border-radius: 50%; }
.sb__chip span { color: var(--text-gray); font-size: 1.05rem; margin-left: 2px; }
.sb__vacio { font-size: .88rem; color: var(--text-gray); }
.sb__acciones { display: flex; gap: 10px; }
.sb__sugerir { height: 50px; padding: 0 16px; border-radius: 12px; border: 1.5px solid var(--border); background: #fff; font: inherit; font-weight: 600; color: var(--text-dark); cursor: pointer; white-space: nowrap; }
.sb__listo { flex: 1; height: 50px; border-radius: 12px; border: 0; background: #9ca3af; color: #fff; font: inherit; font-weight: 700; font-size: 1rem; cursor: pointer; }
.sb__listo.is-completo { background: var(--text-dark); }
.sb button:focus-visible { outline: 3px solid rgba(17,24,39,.35); outline-offset: 2px; }
/* En pantallas grandes es una ventana, no toda la pantalla. */
@media (min-width: 760px) {
  .sb { background: rgba(10,15,26,.6); }
  .sb__caja { width: min(1000px, calc(100% - 48px)); height: min(820px, calc(100% - 48px)); border-radius: 16px; overflow: hidden; box-shadow: 0 24px 60px rgba(0,0,0,.3); }
  .sb__pie { flex-direction: row; align-items: center; }
  .sb__elegidas { flex: 1; }
  .sb__acciones { flex-shrink: 0; }
  .sb__listo { flex: 0 0 auto; padding: 0 28px; }
}
.linea__butacas { display: block; margin-top: 2px; font-size: .84rem; color: var(--text-gray); }
.metodo__logos { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }

@media (max-width: 340px) {
  .tipo { grid-template-columns: minmax(0,1fr); }
  .tipo .contador { justify-self: start; }
}

/* Volvió de la pasarela sin pagar: el paso 4 dice qué pasó y que puede reintentar. */
.pago-aviso { background: #fffbeb; border: 1px solid #fcd34d; color: #78350f; border-radius: 10px; padding: 10px 14px; font-size: 14px; line-height: 1.45; }
.pago-aviso strong { color: #92400e; }

/* Cuenta atrás del apartado. Ocupa el hueco que deja el indicador de pasos
   (su margin-bottom), así que no empuja la tarjeta; al bajar se queda pegada
   arriba. Una línea de texto y una raya de 2 px que se vacía. */
.progress-indicator:has(+ .apartado:not([hidden])) { margin-bottom: 14px; }
.apartado {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%; max-width: 700px; margin: 0 auto 12px; box-sizing: border-box;
  padding: 6px 2px 8px; font-size: 13px; line-height: 1.3; color: var(--text-gray);
  background: rgba(246, 247, 249, .94); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.apartado__reloj { font-variant-numeric: tabular-nums; font-weight: 600; font-size: 14px; color: var(--text-dark); letter-spacing: .02em; }
.apartado__linea { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--border); overflow: hidden; }
.apartado__linea i { display: block; height: 100%; background: var(--primary); transform-origin: left center; transition: transform 1s linear; }
.apartado.is-poco, .apartado.is-poco .apartado__reloj { color: var(--warning); }
.apartado.is-poco .apartado__linea i { background: var(--warning); }

/* Tiempo agotado: el modal de Yappy (.yp-capa/.yp) con un solo botón. */
#tiempoAgotado { z-index: 100; }   /* por encima del selector de butacas (90) si estaba abierto */
.tiempo { max-width: 380px; }
.tiempo__cuerpo { align-items: center; text-align: center; padding: 28px 24px 24px; }
.tiempo__cuerpo p { margin: 0 0 12px; color: var(--text-gray); font-size: .95rem; }
.tiempo__icono { color: var(--text-dark); margin-bottom: 4px; }
.tiempo__btn { width: 100%; height: 50px; border: 0; border-radius: 12px; background: var(--primary); color: #fff; font: inherit; font-weight: 600; font-size: 1rem; cursor: pointer; transition: background .2s; }
.tiempo__btn:hover { background: var(--primary-dark); }
.tiempo__btn:focus-visible { outline: 3px solid rgba(17,24,39,.35); outline-offset: 2px; }
