/* ═══════════════════════════════════════════════════════
   CHECKOUT — Rockabilly Rebel Bar
   Hereda tokens de style.css. Solo overrides + nuevo.
   ═══════════════════════════════════════════════════════ */

.checkout-body { min-height: 100vh; }

/* BG always visible on checkout */
.bg-video { opacity: 0; }
.bg-video.is-visible { opacity: .55; }
@media (max-width: 820px) {
  .bg-video.is-visible { opacity: .45; }
}

/* ─── TOP BAR ─── */
.co-top {
  position: sticky; top: 0;
  z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 22px;
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  background: rgba(10,6,6,.55);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.co-top__brand {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: 'Bebas Neue', sans-serif;
  letter-spacing: .08em; text-transform: uppercase;
}
.co-top__brand .brand__mark {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--red), var(--red-deep));
  color: var(--cream);
  font-size: 16px; font-weight: 700;
  border-radius: 10px;
  box-shadow: 0 6px 20px -6px rgba(209,26,42,.55);
}
.co-top__brand .brand__text { font-size: 18px; }
.co-top__back {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--glass-stroke);
  background: rgba(255,255,255,.04);
  font-size: 14px;
  transition: background .25s var(--ease), transform .25s var(--ease);
}
.co-top__back:hover { background: rgba(255,255,255,.09); transform: translateX(-2px); }
.co-top__back svg { width: 16px; height: 16px; }
@media (max-width: 640px) {
  .co-top { padding: 10px 14px; }
  .co-top__brand .brand__text { display: none; }
  .co-top__back span { display: none; }
  .co-top__back { padding: 8px; }
}

/* ─── MAIN ─── */
.co-main { padding: 60px 0 80px; position: relative; }
.co-container { max-width: 1180px; }
.co-head { text-align: center; margin: 0 auto 40px; max-width: 720px; }
.co-title {
  font-size: clamp(40px, 6vw, 76px);
  margin: 12px 0 14px;
}
.co-sub {
  color: var(--ink-muted);
  font-size: clamp(15px, 1.4vw, 17px);
}

/* ─── STEPPER ─── */
.stepper {
  display: flex; align-items: center; justify-content: center;
  gap: 10px;
  padding: 0; margin: 0 auto 40px;
  list-style: none;
  max-width: 560px;
}
.stepper__item {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 10px 16px 10px 10px;
  border-radius: 999px;
  border: 1px solid var(--glass-stroke);
  background: rgba(255,255,255,.04);
  color: var(--ink-muted);
  font-size: 13px; font-weight: 600;
  transition: all .35s var(--ease);
  white-space: nowrap;
}
.stepper__num {
  width: 26px; height: 26px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,.06);
  font-family: 'Bebas Neue', sans-serif;
  font-size: 14px;
  border: 1px solid var(--glass-stroke);
}
.stepper__item.is-active {
  background: linear-gradient(135deg, rgba(209,26,42,.18), rgba(209,26,42,.06));
  border-color: rgba(209,26,42,.55);
  color: var(--ink);
  box-shadow: 0 8px 30px -10px rgba(209,26,42,.45);
}
.stepper__item.is-active .stepper__num {
  background: var(--red); color: var(--cream); border-color: var(--red-glow);
}
.stepper__item.is-done {
  color: var(--ink);
  border-color: rgba(255,255,255,.18);
}
.stepper__item.is-done .stepper__num {
  background: rgba(245,237,225,.9); color: var(--bg);
}
.stepper__bar {
  flex: 1 1 auto; max-width: 60px;
  height: 1px;
  background: linear-gradient(90deg, var(--glass-stroke), rgba(255,255,255,.04));
}
@media (max-width: 640px) {
  .stepper__label { display: none; }
  .stepper__item { padding: 6px; }
  .stepper__bar { max-width: 30px; }
}

/* ─── GRID ─── */
.co-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 30px;
  align-items: start;
}
@media (max-width: 980px) {
  .co-grid { grid-template-columns: 1fr; }
  .co-summary { order: -1; }
}

/* ─── STEPS ─── */
.co-step { display: none; animation: stepIn .5s var(--ease); }
.co-step.is-active { display: block; }
@keyframes stepIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─── CARDS ─── */
.co-card { padding: 32px; }
.co-card--summary { padding: 28px; position: sticky; top: 88px; }
.co-card--success { text-align: center; padding: 44px 32px; }
.co-card__head { margin-bottom: 24px; }
.co-card__title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(26px, 2.6vw, 34px);
  letter-spacing: .02em;
  margin: 0 0 6px;
  text-transform: uppercase;
}
.co-card__title--big { font-size: clamp(36px, 4vw, 50px); margin-top: 18px; }
.co-card__sub { color: var(--ink-muted); font-size: 14px; margin: 0; }

/* ─── FIELDS ─── */
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; position: relative; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 540px) { .field-row { grid-template-columns: 1fr; } }

.field label {
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-muted); font-weight: 600;
}
.field input, .field select {
  appearance: none; -webkit-appearance: none;
  width: 100%;
  padding: 14px 16px;
  font: inherit; font-size: 15px; color: var(--ink);
  background: rgba(255,255,255,.04);
  border: 1px solid var(--glass-stroke);
  border-radius: 14px;
  transition: border-color .25s var(--ease), background .25s var(--ease), box-shadow .25s var(--ease);
}
.field input::placeholder { color: rgba(245,237,225,.35); }
.field input:focus, .field select:focus {
  outline: none;
  border-color: var(--red-glow);
  background: rgba(255,255,255,.06);
  box-shadow: 0 0 0 4px rgba(209,26,42,.18);
}
.field select {
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-muted) 50%),
                    linear-gradient(135deg, var(--ink-muted) 50%, transparent 50%);
  background-position: calc(100% - 22px) center, calc(100% - 16px) center;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 42px;
}
.field select option { background: #1a0c0c; color: var(--ink); }
.field__hint { font-size: 12px; color: var(--ink-muted); }
.field input.is-invalid, .field select.is-invalid {
  border-color: #ff5b6e;
  box-shadow: 0 0 0 4px rgba(255,91,110,.15);
}

/* ─── QTY ─── */
.qty {
  display: inline-grid;
  grid-template-columns: 44px 70px 44px;
  align-items: stretch;
  border: 1px solid var(--glass-stroke);
  border-radius: 14px;
  overflow: hidden;
  background: rgba(255,255,255,.04);
  width: max-content;
}
.qty__btn {
  font-size: 20px; line-height: 1;
  color: var(--ink);
  transition: background .2s;
}
.qty__btn:hover { background: rgba(255,255,255,.08); }
.qty input {
  border: 0; border-radius: 0;
  text-align: center; font-weight: 600;
  background: transparent;
  -moz-appearance: textfield;
}
.qty input::-webkit-outer-spin-button,
.qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty input:focus { box-shadow: none; background: transparent; }

/* ─── PAYMETHODS TABS ─── */
.paymethods {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 10px; margin-bottom: 22px;
}
.paymethod {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 14px 10px;
  border: 1px solid var(--glass-stroke);
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  font-size: 13px; font-weight: 600;
  color: var(--ink-muted);
  transition: all .25s var(--ease);
}
.paymethod svg { width: 24px; height: 24px; }
.paymethod:hover { background: rgba(255,255,255,.06); color: var(--ink); }
.paymethod.is-active {
  background: linear-gradient(135deg, rgba(209,26,42,.18), rgba(209,26,42,.04));
  border-color: rgba(209,26,42,.55);
  color: var(--ink);
  box-shadow: 0 6px 24px -10px rgba(209,26,42,.45);
}

/* ─── PAY PANELS ─── */
.paypanel { display: none; animation: stepIn .35s var(--ease); }
.paypanel.is-active { display: block; }

/* ─── CARD PREVIEW ─── */
.cardpreview {
  position: relative;
  height: 200px;
  border-radius: 22px;
  padding: 22px 24px;
  margin-bottom: 24px;
  background:
    radial-gradient(120% 80% at 0% 0%, rgba(209,26,42,.55), transparent 55%),
    radial-gradient(120% 80% at 100% 100%, rgba(212,175,55,.18), transparent 55%),
    linear-gradient(135deg, #1a0a0d 0%, #0a0606 60%, #1a0c0c 100%);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow:
    0 30px 60px -25px rgba(0,0,0,.7),
    inset 0 1px 0 rgba(255,255,255,.08);
  overflow: hidden;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 14px;
  color: var(--cream);
  font-family: 'Inter', sans-serif;
}
.cardpreview__brand { display: flex; justify-content: flex-end; opacity: .85; }
.cardpreview__brand svg { width: 38px; height: 38px; }
.cardpreview__chip {
  width: 42px; height: 32px;
  border-radius: 6px;
  background:
    linear-gradient(135deg, #d4af37, #8c6f1c 50%, #d4af37);
  position: relative;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.25);
}
.cardpreview__chip::before, .cardpreview__chip::after {
  content: ""; position: absolute; left: 6px; right: 6px;
  height: 1px; background: rgba(0,0,0,.35);
}
.cardpreview__chip::before { top: 10px; }
.cardpreview__chip::after  { bottom: 10px; }
.cardpreview__num {
  font-size: clamp(18px, 3vw, 22px);
  letter-spacing: .15em;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
  align-self: end;
}
.cardpreview__row {
  display: flex; justify-content: space-between; gap: 20px;
  font-size: 12px;
}
.cardpreview__lbl {
  display: block;
  font-size: 9px; letter-spacing: .2em; text-transform: uppercase;
  opacity: .55; margin-bottom: 3px;
}
.cardpreview__val {
  font-size: 14px; font-weight: 600; letter-spacing: .05em;
  text-transform: uppercase;
}
.cardpreview__shine {
  position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.1) 50%, transparent 70%);
  transform: translateX(-100%);
  animation: cardshine 6s var(--ease) infinite;
  pointer-events: none;
}
@keyframes cardshine {
  0%, 100% { transform: translateX(-100%); }
  40%, 60% { transform: translateX(100%); }
}

/* ─── PAY MSG (oxxo / spei) ─── */
.paymsg {
  padding: 24px;
  border-radius: 16px;
  background: rgba(255,255,255,.04);
  border: 1px dashed var(--glass-stroke);
  margin-bottom: 8px;
}
.paymsg strong { display: block; font-family: 'Bebas Neue', sans-serif; font-size: 20px; letter-spacing: .04em; margin-bottom: 8px; }
.paymsg p { margin: 0; color: var(--ink-muted); font-size: 14px; }

/* ─── CHECKBOX ─── */
.checkfield {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px 0;
  font-size: 13px; color: var(--ink-muted);
  cursor: pointer;
  user-select: none;
}
.checkfield input { position: absolute; opacity: 0; pointer-events: none; }
.checkfield__box {
  flex: 0 0 auto;
  width: 20px; height: 20px;
  border-radius: 6px;
  border: 1.5px solid var(--glass-stroke);
  background: rgba(255,255,255,.04);
  display: grid; place-items: center;
  transition: all .2s var(--ease);
  margin-top: 1px;
}
.checkfield input:checked + .checkfield__box {
  background: var(--red);
  border-color: var(--red-glow);
}
.checkfield input:checked + .checkfield__box::after {
  content: ""; width: 10px; height: 6px;
  border-left: 2px solid var(--cream);
  border-bottom: 2px solid var(--cream);
  transform: rotate(-45deg) translate(1px, -1px);
}

/* ─── ACTIONS ─── */
.co-actions { display: flex; justify-content: flex-end; margin-top: 22px; }
.co-actions--split { justify-content: space-between; }
@media (max-width: 480px) {
  .co-actions, .co-actions--split { flex-direction: column-reverse; gap: 10px; }
  .co-actions .btn, .co-actions--split .btn { width: 100%; justify-content: center; }
}

/* ─── PAY BUTTON LOADER ─── */
#co-pay { position: relative; min-width: 200px; justify-content: center; }
#co-pay.is-loading .btn__label { opacity: 0; }
#co-pay .btn__loader { display: none; }
#co-pay.is-loading .btn__loader {
  display: block;
  position: absolute; left: 50%; top: 50%;
  width: 22px; height: 22px;
  margin: -11px 0 0 -11px;
  border-radius: 50%;
  border: 2.5px solid rgba(255,255,255,.25);
  border-top-color: var(--cream);
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.trust {
  display: flex; align-items: center; gap: 8px;
  font-size: 12px; color: var(--ink-muted);
  margin: 16px 0 0;
}
.trust svg { width: 14px; height: 14px; }

/* ─── SUMMARY ─── */
.co-summary__title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 22px; letter-spacing: .06em;
  text-transform: uppercase;
  margin: 0 0 22px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--glass-stroke);
}
.co-line {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 12px; align-items: center;
  padding: 12px 0;
}
.co-line__main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.co-line__name { font-weight: 600; font-size: 15px; }
.co-line__meta { font-size: 12px; color: var(--ink-muted); }
.co-line__qty { font-size: 13px; color: var(--ink-muted); }
.co-line__price { font-weight: 600; font-variant-numeric: tabular-nums; }

.co-perks {
  list-style: none; padding: 14px 0; margin: 0;
  border-top: 1px dashed var(--glass-stroke);
  border-bottom: 1px dashed var(--glass-stroke);
}
.co-perks li {
  position: relative; padding-left: 22px;
  font-size: 13px; color: var(--ink-muted);
  margin: 6px 0;
}
.co-perks li::before {
  content: ""; position: absolute; left: 0; top: 7px;
  width: 6px; height: 6px;
  background: var(--red-glow);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--red-glow);
}

.co-totals { padding-top: 16px; }
.co-total {
  display: flex; justify-content: space-between;
  margin: 8px 0;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.co-total--muted { color: var(--ink-muted); font-size: 13px; }
.co-total--big {
  margin-top: 14px; padding-top: 14px;
  border-top: 1px solid var(--glass-stroke);
  font-family: 'Bebas Neue', sans-serif;
  font-size: 24px; letter-spacing: .04em;
}
.co-total--big span:last-child { color: var(--red-glow); }

.co-promo {
  display: grid; grid-template-columns: 1fr auto;
  gap: 8px; margin-top: 18px;
}
.co-promo input {
  padding: 11px 14px;
  background: rgba(255,255,255,.04);
  border: 1px solid var(--glass-stroke);
  border-radius: 12px;
  color: var(--ink); font-size: 14px;
}
.co-promo input:focus {
  outline: none; border-color: var(--red-glow);
  box-shadow: 0 0 0 3px rgba(209,26,42,.18);
}
.co-promo button {
  padding: 11px 18px;
  border-radius: 12px;
  background: rgba(255,255,255,.06);
  border: 1px solid var(--glass-stroke);
  font-weight: 600; font-size: 13px;
  color: var(--ink);
  transition: background .2s;
}
.co-promo button:hover { background: rgba(255,255,255,.12); }
.co-promo__hint { font-size: 11px; color: var(--ink-muted); margin: 8px 0 0; }
.co-promo__hint code {
  background: rgba(209,26,42,.15);
  padding: 2px 6px; border-radius: 4px;
  color: var(--red-glow); font-size: 11px;
}
.co-promo__hint.is-applied { color: #5fd97a; }
.co-trust {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; color: var(--ink-muted);
  margin: 18px 0 0;
}
.co-trust svg { width: 13px; height: 13px; }

/* ─── SUCCESS ─── */
.success-mark { display: grid; place-items: center; margin: 0 auto 12px; }
.success-mark svg { width: 88px; height: 88px; color: #5fd97a; }
.success-circle {
  stroke-dasharray: 170; stroke-dashoffset: 170;
  animation: drawCircle .7s var(--ease) forwards;
}
.success-check {
  stroke-dasharray: 60; stroke-dashoffset: 60;
  animation: drawCheck .4s var(--ease) .6s forwards;
}
@keyframes drawCircle { to { stroke-dashoffset: 0; } }
@keyframes drawCheck  { to { stroke-dashoffset: 0; } }

.qr--success { margin: 24px auto; max-width: 220px; }
.co-card--success .ticket__stub { margin: 8px auto 24px; max-width: 320px; }

/* ─── FOOT ─── */
.co-foot {
  text-align: center;
  padding: 30px 20px;
  font-size: 12px;
  color: var(--ink-muted);
  border-top: 1px solid rgba(255,255,255,.04);
  position: relative; z-index: 2;
}

/* ─── MOBILE TWEAKS ─── */
@media (max-width: 640px) {
  .co-main { padding: 30px 0 60px; }
  .co-card { padding: 22px 18px; }
  .co-card--success { padding: 32px 20px; }
  .stepper { margin-bottom: 26px; }
  .co-head { margin-bottom: 26px; }
  .cardpreview { height: 180px; padding: 18px 20px; }
}
