/* =================================================================
   FastEMI — Customer QR Eligibility Checker
   Brand system + components
   Palette derived from the FastEMI logo: red "Fast", navy "EMI".
   ================================================================= */

:root {
  /* Brand */
  --fe-red:        #E1251B;
  --fe-red-dark:   #B81B13;
  --fe-navy:       #1B2A6B;
  --fe-navy-dark:  #16225A;
  --fe-navy-soft:  #EEF1FB;

  /* Status */
  --fe-green:      #16A34A;
  --fe-green-soft: #E9F8EF;
  --fe-green-line: #BBE7CB;

  /* Neutrals */
  --fe-ink:        #0F172A;
  --fe-muted:      #5B6577;
  --fe-faint:      #94A0B3;
  --fe-line:       #E4E8F0;
  --fe-surface:    #FFFFFF;
  --fe-bg:         #F3F5FB;

  /* System */
  --fe-radius:     16px;
  --fe-radius-sm:  11px;
  --fe-shadow:     0 18px 48px -22px rgba(27, 42, 107, .35);
  --fe-shadow-sm:  0 6px 18px -10px rgba(15, 23, 42, .25);
  --fe-ring:       0 0 0 4px rgba(27, 42, 107, .18);
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--fe-ink);
  /* Flat, uniform background — no scroll seam on long pages.
     The subtle brand tint lives only in the (short) header. */
  background: var(--fe-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, .display {
  font-family: "Plus Jakarta Sans", "Inter", system-ui, sans-serif;
  letter-spacing: -.015em;
}

/* ---------- App shell ---------- */
.fe-shell {
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

.fe-main {
  flex: 1;
  display: flex;
  justify-content: center;
  padding: 26px 16px 56px;
}

.fe-stage { width: 100%; max-width: 560px; }

/* ---------- Header ---------- */
.fe-header {
  background:
    radial-gradient(420px 180px at 100% 0%, rgba(225,37,27,.05), transparent 70%),
    radial-gradient(520px 200px at 0% 0%, rgba(27,42,107,.05), transparent 70%),
    rgba(255,255,255,.9);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--fe-line);
  position: sticky;
  top: 0;
  z-index: 20;
}
.fe-header-inner {
  max-width: 980px;
  margin: 0 auto;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}
.fe-logo { display: flex; align-items: center; }
.fe-logo img { height: 38px; width: auto; display: block; }

/* ---------- Progress (signature element) ---------- */
.fe-progress { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.fe-steps {
  display: flex;
  gap: 7px;
  align-items: center;
}
.fe-step {
  width: 40px;
  height: 6px;
  border-radius: 999px;
  background: var(--fe-line);
  position: relative;
  overflow: hidden;
  transition: background .35s ease;
}
.fe-step::after {
  content: "";
  position: absolute; inset: 0;
  transform: translateX(-101%);
  transition: transform .5s cubic-bezier(.4,0,.2,1);
}
.fe-step.is-done   { background: var(--fe-green); }
.fe-step.is-active { background: var(--fe-line); }
.fe-step.is-active::after { background: var(--fe-navy); transform: translateX(0); }
.fe-progress-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--fe-muted);
  text-align: right;
  letter-spacing: .01em;
}
.fe-progress-label b { color: var(--fe-navy); font-weight: 700; }

/* ---------- Retailer chip ---------- */
.fe-retailer {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 16px;
  border: 1px solid var(--fe-green-line);
  background: var(--fe-green-soft);
  border-radius: var(--fe-radius-sm);
  margin-bottom: 18px;
}
.fe-retailer .fe-store-ic {
  width: 30px; height: 30px; flex: none;
  display: grid; place-items: center;
  background: #fff; border-radius: 8px;
  border: 1px solid var(--fe-green-line);
  font-size: 16px;
}
.fe-retailer .fe-store-meta { line-height: 1.2; min-width: 0; }
.fe-retailer .fe-store-eyebrow {
  font-size: 10.5px; font-weight: 700; letter-spacing: .09em;
  text-transform: uppercase; color: var(--fe-green);
}
.fe-retailer .fe-store-name {
  font-weight: 700; color: #0d5a2c; font-size: 15px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* ---------- Card ---------- */
.fe-card {
  background: var(--fe-surface);
  border: 1px solid var(--fe-line);
  border-radius: var(--fe-radius);
  box-shadow: var(--fe-shadow);
  padding: 30px 28px 28px;
}
.fe-card-title { font-size: 25px; font-weight: 800; margin: 0 0 6px; }
.fe-card-sub   { color: var(--fe-muted); font-size: 14.5px; margin: 0 0 22px; line-height: 1.55; }

.fe-section-head {
  display: flex; align-items: center; gap: 10px;
  margin: 26px 0 16px;
  color: var(--fe-navy);
  font-family: "Plus Jakarta Sans", sans-serif;
  font-weight: 700; font-size: 14px;
  letter-spacing: .02em; text-transform: uppercase;
}
.fe-section-head::after { content: ""; flex: 1; height: 1px; background: var(--fe-line); }

/* ---------- Forms ---------- */
.fe-field { margin-bottom: 18px; }
.fe-label {
  display: block; font-weight: 700; font-size: 13.5px;
  margin-bottom: 8px; color: var(--fe-ink);
}
.fe-label .req { color: var(--fe-red); margin-left: 2px; }
.fe-hint { font-size: 12px; color: var(--fe-faint); margin-top: 6px; }

.fe-input, .form-control, .form-select {
  width: 100%;
  border: 1.5px solid var(--fe-line);
  border-radius: var(--fe-radius-sm);
  padding: 13px 15px;
  font-size: 15.5px;
  color: var(--fe-ink);
  background: #fff;
  transition: border-color .18s, box-shadow .18s;
}
.fe-input::placeholder, .form-control::placeholder { color: var(--fe-faint); }
.fe-input:focus, .form-control:focus, .form-select:focus {
  outline: none;
  border-color: var(--fe-navy);
  box-shadow: var(--fe-ring);
}
.fe-input.is-invalid, .form-control.is-invalid {
  border-color: var(--fe-red);
  box-shadow: 0 0 0 4px rgba(225,37,27,.12);
}
.fe-error { color: var(--fe-red); font-size: 12.5px; margin-top: 6px; display: none; }
.fe-input.is-invalid ~ .fe-error { display: block; }

.fe-input-group { position: relative; display: flex; align-items: stretch; }
.fe-input-group .fe-prefix {
  display: grid; place-items: center;
  padding: 0 14px;
  border: 1.5px solid var(--fe-line);
  border-right: none;
  border-radius: var(--fe-radius-sm) 0 0 var(--fe-radius-sm);
  background: #F8FAFE;
  color: var(--fe-muted); font-weight: 600; font-size: 15px;
}
.fe-input-group .fe-prefix + .fe-input { border-radius: 0 var(--fe-radius-sm) var(--fe-radius-sm) 0; }
.fe-input-group:focus-within .fe-prefix { border-color: var(--fe-navy); }

.fe-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.fe-grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }

/* Select */
.fe-select {
  width: 100%;
  border: 1.5px solid var(--fe-line);
  border-radius: var(--fe-radius-sm);
  padding: 13px 15px;
  font-size: 15.5px;
  color: var(--fe-ink);
  background: #fff;
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235B6577' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
  transition: border-color .18s, box-shadow .18s;
}
.fe-select:focus { outline: none; border-color: var(--fe-navy); box-shadow: var(--fe-ring); }
.fe-select.is-invalid { border-color: var(--fe-red); box-shadow: 0 0 0 4px rgba(225,37,27,.12); }
.fe-select:invalid, .fe-select option[value=""] { color: var(--fe-faint); }

/* PAN field (plain input; encryption handled server-side) */
.fe-pan-input { letter-spacing: .06em; text-transform: uppercase; }

/* Prominent mobile row on step 1 */
.fe-mobile-lead .fe-label { font-size: 14.5px; }
.fe-mobile-lead .fe-prefix { font-size: 16px; }
.fe-mobile-lead .fe-input { font-size: 17px; font-weight: 600; padding-top: 15px; padding-bottom: 15px; }

/* ---------- Buttons ---------- */
.fe-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  width: 100%;
  border: none; cursor: pointer;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-weight: 700; font-size: 16px;
  padding: 15px 20px;
  border-radius: var(--fe-radius-sm);
  transition: transform .12s, box-shadow .2s, background .2s;
}
.fe-btn:active { transform: translateY(1px); }
.fe-btn-primary {
  background: var(--fe-navy); color: #fff;
  box-shadow: 0 10px 22px -10px rgba(27,42,107,.7);
}
.fe-btn-primary:hover { background: var(--fe-navy-dark); }
.fe-btn-whatsapp { background: #1FA855; color: #fff; box-shadow: 0 10px 22px -10px rgba(31,168,85,.65); }
.fe-btn-whatsapp:hover { background: #178a45; }
.fe-btn-ghost {
  background: #fff; color: var(--fe-navy);
  border: 1.5px solid var(--fe-line); box-shadow: none;
}
.fe-btn-ghost:hover { border-color: var(--fe-navy); background: var(--fe-navy-soft); }
.fe-btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; }
.fe-btn .arrow { transition: transform .2s; }
.fe-btn:hover .arrow { transform: translateX(3px); }

.fe-btn-row { display: flex; gap: 12px; margin-top: 4px; }
.fe-btn-row .fe-btn { width: auto; flex: 1; }

/* ---------- Trust strip ---------- */
.fe-trust {
  display: flex; align-items: center; justify-content: center;
  gap: 7px; flex-wrap: wrap;
  margin-top: 16px; font-size: 12.5px; color: var(--fe-muted);
}
.fe-trust .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--fe-faint); }
.fe-trust b { color: var(--fe-ink); font-weight: 600; }

/* ---------- Eligible banner (step 3) ---------- */
.fe-result {
  border: 1.5px solid var(--fe-green-line);
  background: linear-gradient(180deg, #F2FCF6, var(--fe-green-soft));
  border-radius: var(--fe-radius-sm);
  padding: 30px 26px;
  margin-bottom: 22px;
  text-align: left;
}
.fe-result .burst { font-size: 46px; line-height: 1; margin-bottom: 14px; }
.fe-result h2 { color: var(--fe-green); font-size: 30px; font-weight: 800; margin: 0 0 8px; }
.fe-result p  { color: #2c6a44; font-size: 15px; margin: 0; }
.fe-result-meta {
  display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px;
}
.fe-pill {
  background: #fff; border: 1px solid var(--fe-green-line);
  border-radius: 999px; padding: 8px 14px; font-size: 13px; color: #2c6a44;
}
.fe-pill b { color: #0d5a2c; }

/* ---------- Success (step 5) ---------- */
.fe-success { text-align: center; padding: 14px 8px 6px; }
.fe-success .burst { font-size: 56px; line-height: 1; }
.fe-success h2 { font-size: 26px; font-weight: 800; margin: 16px 0 8px; }
.fe-success p { color: var(--fe-muted); font-size: 15px; margin: 0 auto 22px; max-width: 420px; line-height: 1.55; }
.fe-appid {
  display: inline-flex; flex-direction: column; gap: 4px;
  padding: 16px 26px;
  border: 1px dashed #C5CEEC;
  background: var(--fe-navy-soft);
  border-radius: var(--fe-radius-sm);
}
.fe-appid .lbl { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--fe-navy); }
.fe-appid .val { font-size: 19px; font-weight: 800; color: var(--fe-navy-dark); font-family: "Plus Jakarta Sans", sans-serif; letter-spacing: .02em; }
.fe-success .fe-foot { margin-top: 22px; font-size: 13px; color: var(--fe-faint); }
.fe-redirect { margin-top: 10px; font-size: 13px; color: var(--fe-muted); }

/* ---------- OTP inputs ---------- */
.fe-otp { display: flex; gap: 10px; justify-content: space-between; margin: 4px 0 6px; }
.fe-otp input {
  width: 100%; aspect-ratio: 1 / 1; max-width: 58px;
  text-align: center; font-size: 22px; font-weight: 700;
  border: 1.5px solid var(--fe-line); border-radius: var(--fe-radius-sm);
  color: var(--fe-ink); background: #fff;
  transition: border-color .18s, box-shadow .18s;
}
.fe-otp input:focus { outline: none; border-color: var(--fe-navy); box-shadow: var(--fe-ring); }
.fe-otp input.filled { border-color: var(--fe-navy); background: var(--fe-navy-soft); }
.fe-otp-meta {
  display: flex; align-items: center; justify-content: space-between;
  margin: 18px 0 22px; font-size: 13.5px; color: var(--fe-muted);
}
.fe-link { background: none; border: none; color: var(--fe-navy); font-weight: 700; cursor: pointer; padding: 0; font-size: 13.5px; }
.fe-link:disabled { color: var(--fe-faint); cursor: not-allowed; }
.fe-sent-to { background: var(--fe-navy-soft); border-radius: var(--fe-radius-sm); padding: 12px 15px; font-size: 13.5px; color: var(--fe-muted); margin-bottom: 20px; }
.fe-sent-to b { color: var(--fe-ink); }

/* ---------- Footer ---------- */
.fe-footer {
  text-align: center; padding: 22px 16px 28px;
  font-size: 12px; color: var(--fe-faint);
}
.fe-footer b { color: var(--fe-muted); font-weight: 600; }

/* ---------- Reveal animation ---------- */
.fe-reveal { opacity: 0; transform: translateY(10px); animation: feRise .5s cubic-bezier(.2,.7,.2,1) forwards; }
@keyframes feRise { to { opacity: 1; transform: none; } }

/* ---------- Mobile ---------- */
@media (max-width: 640px) {
  .fe-header-inner { flex-direction: column; gap: 12px; padding: 14px 16px 12px; }
  .fe-logo img { height: 34px; }
  .fe-progress { width: 100%; align-items: stretch; }
  .fe-progress-label { text-align: center; }
  .fe-steps { width: 100%; justify-content: center; }
  .fe-step { flex: 1 1 0; width: auto; min-width: 0; max-width: 56px; }
  .fe-card { padding: 24px 20px 22px; border-radius: 14px; }
  .fe-card-title { font-size: 22px; }
  .fe-grid-3 { grid-template-columns: 1fr 1fr; }
  .fe-result h2 { font-size: 26px; }
}
@media (max-width: 380px) {
  .fe-grid-2, .fe-grid-3 { grid-template-columns: 1fr; }
}

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



/* =================================================================
   CHECKOUT PAGE (checkout.php)
   Merged from style-checkout.css + responsive-checkout.css.
   Scoped under .checkout (the <main> wrapper on checkout.php) so
   these tokens/rules never leak onto index/otp/result/success pages.
   Component classes below (.surface-card, .address, .pay*, .btn-pay,
   .order-summary*, .totals*, .product*, .pay-accordion, .reveal, etc.)
   are only ever used inside checkout.php, so they're safe to keep
   as their original top-level selectors — no renaming needed.
   Unused legacy blocks from the source files (topbar, site-header,
   checkout-steps, trust-footer/trust-bar) were left out since
   checkout.php doesn't render that markup — it uses the shared
   .fe-header / .fe-steps header already in this file.
   ================================================================= */

.checkout {
  /* Design tokens — scoped to checkout so they don't collide with
     the --fe-* tokens used by the rest of the app. */
  --c-primary: #2563EB;
  --c-primary-dark: #1D4ED8;
  --c-primary-soft: #EFF4FF;
  --c-secondary: #0F172A;
  --c-success: #16A34A;
  --c-success-soft: #ECFDF3;
  --c-border: #E5E7EB;
  --c-card: #FFFFFF;
  --c-ink: #0F172A;
  --c-ink-2: #475569;
  --c-ink-3: #94A3B8;

  --radius-card: 16px;
  --radius-btn: 12px;
  --radius-pill: 12px;

  --shadow-card: 0 10px 30px rgba(15, 23, 42, .08);
  --shadow-card-hover: 0 18px 44px rgba(15, 23, 42, .12);
  --shadow-pop: 0 8px 24px rgba(37, 99, 235, .18);

  --font-display: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, sans-serif;
  --ease: cubic-bezier(.4, 0, .2, 1);
  --header-h: 76px;

  padding: 32px 12px 48px;
  font-family: var(--font-body);
  color: var(--c-ink);
}

.checkout h1, .checkout h2, .checkout h3 { font-family: var(--font-display); color: var(--c-secondary); }

/* ---------- Cards / section heads ---------- */
.surface-card {
  background: var(--c-card);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  margin-bottom: 24px;
  overflow: hidden;
}
.surface-card .card-body { padding: 24px; }

.section-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px;
}
.section-head__title { font-size: 18px; font-weight: 700; margin: 0; }
.section-head__action { font-weight: 600; font-size: 14px; padding: 0; }
.section-head__note {
  font-size: 12px; font-weight: 600; color: var(--c-success);
  display: inline-flex; align-items: center; gap: 5px;
}

/* ---------- Address ---------- */
.address {
  display: flex; gap: 14px;
  border: 1.5px solid var(--c-border);
  border-radius: 14px;
  padding: 18px;
  transition: border-color .35s var(--ease), background .35s var(--ease), box-shadow .35s var(--ease);
}
.address.is-selected {
  border-color: var(--c-success);
  background: var(--c-success-soft);
  box-shadow: inset 0 0 0 1px rgba(22, 163, 74, .25);
}
.address__check {
  flex: 0 0 auto; width: 30px; height: 30px; border-radius: 50%;
  background: var(--c-success); color: #fff;
  display: grid; place-items: center; font-size: 16px;
}
.address__name { font-family: var(--font-display); font-weight: 700; font-size: 15px; margin: 0 0 4px; }
.address__tag {
  font-family: var(--font-body); font-size: 11px; font-weight: 600;
  background: #fff; color: var(--c-ink-2); border: 1px solid var(--c-border);
  border-radius: 6px; padding: 1px 8px; margin-left: 6px; vertical-align: middle;
}
.address__line { margin: 0 0 2px; color: var(--c-ink-2); font-size: 14px; }
.address__meta { margin: 8px 0 0; color: var(--c-ink-2); font-size: 13px; }
.address__meta i { color: var(--c-ink-3); }

/* ---------- Payment layout ---------- */
.pay { display: grid; grid-template-columns: 220px 1fr; gap: 20px; }
.pay__nav, .pay__panes { min-width: 0; }
.pay__nav .nav-pills { gap: 6px; }

.pay__nav .nav-link {
  display: flex; align-items: center; gap: 10px;
  text-align: left; width: 100%;
  color: var(--c-ink-2); font-weight: 600; font-size: 14px;
  background: transparent; border: 1px solid transparent;
  border-radius: var(--radius-pill); padding: 11px 13px;
  transition: all .25s var(--ease);
}
.pay__nav .nav-link i { font-size: 17px; color: var(--c-ink-3); transition: color .25s var(--ease); flex: 0 0 auto; }
.pay__nav .nav-link:hover { background: var(--c-bg, #F8FAFC); color: var(--c-ink); }
.pay__nav .nav-link.active {
  background: var(--c-primary-soft);
  color: var(--c-primary-dark);
  border-color: rgba(37, 99, 235, .25);
  box-shadow: inset 3px 0 0 var(--c-primary);
}
.pay__nav .nav-link.active i { color: var(--c-primary); }

.pay__panes {
  border: 1px solid var(--c-border);
  border-radius: 14px;
  padding: 18px;
  min-height: 320px;
  background: #fff;
}
.pay__pane-title {
  font-family: var(--font-display); font-weight: 700; font-size: 15px;
  color: var(--c-secondary); margin: 0 0 14px;
}

.checkout .tab-pane.fade { transition: opacity .25s var(--ease), transform .25s var(--ease); }
.checkout .tab-pane.fade:not(.show) { transform: translateY(6px); }

/* ---------- Payment options ---------- */
.pay-options { display: grid; gap: 12px; }
.pay-option {
  position: relative; display: flex; align-items: center; gap: 14px;
  border: 1.5px solid var(--c-border); border-radius: 13px;
  padding: 14px 16px; cursor: pointer; margin: 0;
  background: #fff;
  transition: border-color .3s var(--ease), background .3s var(--ease), box-shadow .3s var(--ease), transform .2s var(--ease);
}
.pay-option:hover { border-color: #CBD5E1; box-shadow: var(--shadow-card); }
.pay-option__radio {
  appearance: none; -webkit-appearance: none;
  width: 20px; height: 20px; flex: 0 0 auto; margin: 0;
  border: 2px solid var(--c-border); border-radius: 50%;
  position: relative; cursor: pointer;
  transition: border-color .25s var(--ease);
}
.pay-option__radio::after {
  content: ""; position: absolute; inset: 3px; border-radius: 50%;
  background: var(--c-primary); transform: scale(0);
  transition: transform .25s var(--ease);
}
.pay-option__text { display: flex; flex-direction: column; gap: 2px; flex: 1 1 auto; min-width: 0; }
.pay-option__name { font-family: var(--font-display); font-weight: 700; font-size: 15px; color: var(--c-secondary); }
.pay-option__desc { font-size: 12.5px; color: var(--c-ink-3); }
.pay-option__logo { width: 30px; height: 30px; flex: 0 0 auto; object-fit: contain; }
.pay-option__tick {
  width: 24px; height: 24px; border-radius: 50%; flex: 0 0 auto;
  display: grid; place-items: center; color: #fff; font-size: 14px;
  background: var(--c-primary); opacity: 0; transform: scale(.6);
  transition: opacity .25s var(--ease), transform .25s var(--ease);
}

/* selected state */
.pay-option:has(.pay-option__radio:checked) {
  border-color: var(--c-primary);
  background: var(--c-primary-soft);
  box-shadow: 0 0 0 1px rgba(37, 99, 235, .25), var(--shadow-pop);
}
.pay-option:has(.pay-option__radio:checked) .pay-option__radio { border-color: var(--c-primary); }
.pay-option:has(.pay-option__radio:checked) .pay-option__radio::after { transform: scale(1); }
.pay-option:has(.pay-option__radio:checked) .pay-option__tick { opacity: 1; transform: scale(1); }
/* JS fallback class for browsers without :has() */
.pay-option.is-checked {
  border-color: var(--c-primary); background: var(--c-primary-soft);
  box-shadow: 0 0 0 1px rgba(37, 99, 235, .25), var(--shadow-pop);
}
.pay-option.is-checked .pay-option__radio { border-color: var(--c-primary); }
.pay-option.is-checked .pay-option__radio::after { transform: scale(1); }
.pay-option.is-checked .pay-option__tick { opacity: 1; transform: scale(1); }

.pay-option__radio:focus-visible { outline: 3px solid rgba(37, 99, 235, .35); outline-offset: 2px; }

/* ---------- Inline option forms (OneCard card entry, UPI ID) ---------- */
.pay-option-form { display: none; padding: 6px 2px 2px; }
.pay-option-form.is-open { display: block; animation: feCheckoutOptionFormIn .25s var(--ease); }
@keyframes feCheckoutOptionFormIn {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: none; }
}
.pay-option-form .form-label { font-size: 12px; font-weight: 600; color: var(--c-ink-2); margin-bottom: 5px; }
.pay-option-form .form-control,
.pay-option-form .form-select {
  border: 1.5px solid var(--c-border); border-radius: 10px;
  padding: 10px 12px; font-size: 14px; color: var(--c-ink);
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.pay-option-form .form-control:focus,
.pay-option-form .form-select:focus {
  border-color: var(--c-primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .14);
}
.upi-entry { display: flex; gap: 10px; align-items: stretch; }
.upi-entry .form-control { flex: 1 1 auto; }
.upi-entry .upi-verify { flex: 0 0 auto; padding: 10px 18px; }
.form-hint { font-size: 12px; color: var(--c-ink-3); margin: 8px 0 0; }

/* ---------- Continue button ---------- */
.btn-pay {
  --bs-btn-focus-shadow-rgb: 37, 99, 235;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--c-primary); color: #fff;
  font-family: var(--font-display); font-weight: 700; font-size: 16px;
  border: none; border-radius: var(--radius-btn); padding: 15px 24px;
  transition: transform .2s var(--ease), background .2s var(--ease), box-shadow .2s var(--ease);
  box-shadow: 0 6px 18px rgba(37, 99, 235, .28);
}
.btn-pay:hover:not(:disabled) {
  background: var(--c-primary-dark); color: #fff;
  transform: translateY(-2px); box-shadow: 0 12px 26px rgba(37, 99, 235, .35);
}
.btn-pay:active:not(:disabled) { transform: translateY(0); }
.btn-pay:disabled, .btn-pay.disabled {
  background: #E2E8F0; color: #94A3B8; box-shadow: none; cursor: not-allowed;
}
.btn-pay .btn-pay__arrow { transition: transform .2s var(--ease); display: inline-flex; }
.btn-pay:hover:not(:disabled) .btn-pay__arrow { transform: translateX(4px); }
.btn-pay .btn-pay__spinner { display: none; }
.btn-pay.is-loading .btn-pay__arrow,
.btn-pay.is-loading .btn-pay__label { display: none; }
.btn-pay.is-loading .btn-pay__spinner { display: inline-block; }
.btn-pay.is-loading::before { content: "Processing"; font-weight: 700; }

.continue-desktop { margin-top: 4px; }
.continue-note {
  text-align: center; font-size: 13px; color: var(--c-ink-3);
  margin: 12px 0 0; display: flex; align-items: center; justify-content: center; gap: 6px;
}
.continue-note i { color: var(--c-success); }

/* ---------- Order Summary ---------- */
.order-summary__card { margin-bottom: 24px; }
.order-summary__title { font-size: 16px; font-weight: 700; margin: 0 0 18px; }

.product { margin-bottom: 18px; }
.product__name { font-family: var(--font-display); font-weight: 700; font-size: 15px; margin: 0 0 3px; color: var(--c-secondary); }
.product__price { font-family: var(--font-display); font-weight: 700; font-size: 15px; color: var(--c-primary); margin: 0 0 8px; }
.product__loan { display: flex; align-items: baseline; gap: 8px; margin: 0; }
.product__loan-label { font-size: 12px; color: var(--c-ink-2); }
.product__loan-value { font-family: var(--font-display); font-weight: 700; font-size: 14px; color: var(--c-secondary); }

.totals { margin: 0; }
.totals__row { display: flex; justify-content: space-between; font-size: 14px; color: var(--c-ink-2); margin-bottom: 6px; }
.totals__row dt { font-weight: 500; margin: 0; }
.totals__row dd { margin: 0; font-weight: 600; color: var(--c-secondary); }
.totals__divider { border-color: var(--c-border); opacity: 1; margin: 14px 0; }
.totals__grand { display: flex; align-items: baseline; justify-content: space-between; }
.totals__grand-label { font-family: var(--font-display); font-weight: 700; font-size: 15px; color: var(--c-secondary); }
.totals__grand-value { font-family: var(--font-display); font-weight: 800; font-size: 24px; color: var(--c-primary); }

.order-summary__trust {
  margin: 16px 0 0; padding-top: 14px; border-top: 1px solid var(--c-border);
  font-size: 12px; color: var(--c-ink-3); display: flex; align-items: center; gap: 6px;
}
.order-summary__trust i { color: var(--c-success); }

/* ---------- Mobile sticky bar (kept for parity with the source
   stylesheet; checkout.php doesn't render this markup yet, so it's
   a harmless no-op until/unless the .mobile-bar block is added). ---------- */
.mobile-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 1040;
  display: none; align-items: center; gap: 14px;
  background: #fff; border-top: 1px solid var(--c-border);
  padding: 12px 16px; box-shadow: 0 -8px 24px rgba(15, 23, 42, .08);
}
.mobile-bar__total { display: flex; flex-direction: column; line-height: 1.1; }
.mobile-bar__label { font-size: 11px; color: var(--c-ink-3); text-transform: uppercase; letter-spacing: .04em; }
.mobile-bar__value { font-family: var(--font-display); font-weight: 800; font-size: 19px; color: var(--c-secondary); }
.mobile-bar .btn-pay { flex: 1 1 auto; padding: 13px 18px; }

/* ---------- Mobile payment accordion ---------- */
.pay-accordion {
  --bs-accordion-border-color: var(--c-border);
  --bs-accordion-btn-color: var(--c-secondary);
  --bs-accordion-btn-bg: #fff;
  --bs-accordion-active-color: var(--c-primary-dark);
  --bs-accordion-active-bg: var(--c-primary-soft);
  --bs-accordion-btn-focus-box-shadow: 0 0 0 4px rgba(37, 99, 235, .14);
  --bs-accordion-btn-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%2394a3b8'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
  --bs-accordion-btn-active-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%232563eb'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
  display: grid;
  gap: 10px;
}
.pay-accordion .accordion-item {
  border: 1px solid var(--c-border);
  border-radius: 13px;
  overflow: hidden;
  background: #fff;
}
.pay-accordion .accordion-header { margin: 0; }
.pay-accordion .accordion-button {
  font-family: var(--font-display); font-weight: 700; font-size: 15px;
  display: flex; align-items: center; gap: 10px;
  padding: 15px 16px; border-radius: 0;
  transition: background .25s var(--ease), color .25s var(--ease);
}
.pay-accordion .accordion-button:focus { z-index: 1; }
.pay-accordion .accordion-button i { font-size: 18px; color: var(--c-ink-3); transition: color .25s var(--ease); }
.pay-accordion .accordion-button:not(.collapsed) { box-shadow: inset 0 -1px 0 rgba(37, 99, 235, .14); }
.pay-accordion .accordion-button:not(.collapsed) i { color: var(--c-primary); }
.pay-accordion .accordion-button span { flex: 1 1 auto; }
.pay-accordion .accordion-body { padding: 6px 14px 16px; }
.pay-accordion .accordion-body .pay__pane-title { margin: 4px 0 12px; }

/* ---------- Address modal (referenced by the merged JS: #addressModal,
   #addressForm — add the modal markup in checkout.php to use it) ---------- */
.addr-modal {
  border: none; border-radius: var(--radius-card);
  box-shadow: 0 30px 70px rgba(15, 23, 42, .22);
}
.addr-modal .modal-header { border-bottom: 1px solid var(--c-border); padding: 20px 24px; }
.addr-modal .modal-title { font-family: var(--font-display); font-weight: 700; color: var(--c-secondary); }
.addr-modal .modal-body { padding: 22px 24px; }
.addr-modal .modal-footer { border-top: 1px solid var(--c-border); padding: 16px 24px; }
.addr-modal .form-label { font-size: 13px; font-weight: 600; color: var(--c-ink-2); margin-bottom: 6px; }
.addr-modal .form-control,
.addr-modal .form-select {
  border: 1.5px solid var(--c-border); border-radius: 10px;
  padding: 10px 13px; font-size: 14px; color: var(--c-ink);
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.addr-modal .form-control:focus,
.addr-modal .form-select:focus {
  border-color: var(--c-primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .14);
}
.btn-modal-save { padding: 11px 22px; font-size: 15px; }
.btn-ghost {
  font-family: var(--font-display); font-weight: 600; font-size: 15px;
  color: var(--c-ink-2); background: #fff;
  border: 1.5px solid var(--c-border); border-radius: var(--radius-btn);
  padding: 10px 20px; transition: all .2s var(--ease);
}
.btn-ghost:hover { background: #F8FAFC; color: var(--c-ink); border-color: #CBD5E1; }

/* ---------- Reveal animation (checkout cards fade in on scroll) ---------- */
.reveal { opacity: 0; transform: translateY(14px); }
.reveal.is-visible {
  opacity: 1; transform: none;
  transition: opacity .3s var(--ease), transform .3s var(--ease);
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}

/* =================================================================
   CHECKOUT — responsive (merged from responsive-checkout.css)
   ================================================================= */

/* Desktop (lg+): sticky order summary */
@media (min-width: 992px) {
  .order-summary { position: sticky; top: calc(var(--header-h) + 24px); }
}

/* Tablet & below (< 992px) */
@media (max-width: 991.98px) {
  .pay { grid-template-columns: 200px 1fr; gap: 16px; }
  .checkout { padding-bottom: 96px; }
  .mobile-bar { display: flex; }
}

/* Mobile (< 768px) */
@media (max-width: 767.98px) {
  .checkout { font-size: 14.5px; }
  .surface-card .card-body { padding: 18px; }
  .address { padding: 14px; }
  .address__meta { font-size: 12px; }
  .totals__grand-value { font-size: 22px; }
}

/* Small mobile (< 576px) */
@media (max-width: 575.98px) {
  .checkout .section-head__title { font-size: 16px; }
  .pay-option { padding: 12px 13px; gap: 12px; }
  .pay-option__logo { width: 36px; height: 36px; }
  .mobile-bar__value { font-size: 17px; }
  .mobile-bar .btn-pay { font-size: 15px; padding: 12px 14px; }
}

/* Tablet portrait fine-tune (768px–991px): keep pills vertical when there's room */
@media (min-width: 768px) and (max-width: 991.98px) {
  .pay { grid-template-columns: 210px 1fr; }
}