/**
 * Zapp Challan Results — v4 "Clear Blue Glass"
 * Matches the landing page: transparent background, frosted glass
 * cards, Barlow Condensed display, electric blue accents.
 */

.zc-results-app,
.zc-results-app *,
.zc-results-app *::before,
.zc-results-app *::after { box-sizing: border-box; margin: 0; padding: 0; }

.zc-results-app {
  --blue: #2563eb;
  --blue-2: #1d4ed8;
  --sky: #60a5fa;
  --ink: #0f172a;
  --muted: rgba(15, 23, 42, 0.55);
  --green: #15803d;
  --g-bg: linear-gradient(135deg, rgba(255,255,255,0.66), rgba(255,255,255,0.34));
  --g-border: rgba(255,255,255,0.7);
  --g-shadow: 0 8px 32px rgba(37,99,235,0.1);
  --f-disp: 'Barlow Condensed', sans-serif;
  --f-body: 'DM Sans', sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  font-family: var(--f-body);
  color: var(--ink);
  background: transparent;
  min-height: 100vh;
  padding-bottom: 140px;
  -webkit-font-smoothing: antialiased;
}
.zc-results-app ::selection { background: var(--blue); color: #fff; }

/* ===== TOP BAR — dark glass ===== */
.top-bar {
  position: sticky;
  top: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem clamp(1rem, 4vw, 2.4rem);
  background: linear-gradient(180deg, rgba(15,23,42,0.88), rgba(15,23,42,0.78));
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  border-bottom: 1px solid rgba(96,165,250,0.22);
}
.top-bar-left { display: flex; align-items: center; gap: 0.9rem; }
.top-bar-logo {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: 0.04em;
  color: #fff;
  text-decoration: none;
}
.top-bar-logo span { color: var(--sky); }
.top-bar-divider { width: 1px; height: 18px; background: rgba(148,163,184,0.35); }
.top-bar-label {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(148,163,184,0.85);
}
.top-bar-back {
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(226,232,240,0.85);
  text-decoration: none;
  padding: 0.4rem 0.9rem;
  border: 1px solid rgba(148,163,184,0.3);
  border-radius: 100px;
  transition: background 0.2s, color 0.2s;
}
.top-bar-back:hover { background: rgba(255,255,255,0.1); color: #fff; }

/* ===== VEHICLE HEADER ===== */
.vehicle-header {
  max-width: 860px;
  margin: 0 auto;
  padding: clamp(1.8rem, 4vw, 2.8rem) 1.25rem 0.6rem;
}
.vh-plate {
  display: inline-flex;
  align-items: stretch;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255,255,255,0.75);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1.5px solid rgba(37,99,235,0.3);
  box-shadow: var(--g-shadow);
  margin-bottom: 1rem;
}
.vh-plate-flag {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 0.45rem 0.6rem;
  background: linear-gradient(160deg, #1e40af, #2563eb);
}
.vh-plate-flag .bar {
  display: block;
  width: 12px; height: 2px;
  border-radius: 2px;
  background: rgba(255,255,255,0.85);
}
.vh-plate-flag .bar:nth-child(2) { background: rgba(255,255,255,0.55); }
.vh-plate-flag small {
  color: #fff;
  font-size: 0.5rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}
.vh-plate-num {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  letter-spacing: 0.14em;
  padding: 0.45rem 1rem;
  color: var(--ink);
}
.vh-title {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: clamp(2.1rem, 5.5vw, 3.4rem);
  line-height: 0.95;
  text-transform: uppercase;
}
.vh-sub {
  margin-top: 0.4rem;
  font-size: 0.92rem;
  color: var(--muted);
}

/* ===== MAIN COLUMN ===== */
#mainContent {
  max-width: 860px;
  margin: 0 auto;
  padding: 1rem 1.25rem 2rem;
}

/* loading */
.loading-state {
  text-align: center;
  padding: 4rem 1rem;
}
.loading-spinner {
  width: 44px; height: 44px;
  margin: 0 auto 1rem;
  border: 4px solid rgba(37,99,235,0.15);
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: zrSpin 0.8s linear infinite;
}
@keyframes zrSpin { to { transform: rotate(360deg); } }
.loading-text { color: var(--muted); font-size: 0.92rem; }

/* counts bar */
.counts-bar {
  background: var(--g-bg);
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  border: 1px solid var(--g-border);
  border-radius: 18px;
  box-shadow: var(--g-shadow), inset 0 1px 0 rgba(255,255,255,0.75);
  margin-bottom: 0.9rem;
}
.counts-inner {
  display: flex;
  flex-wrap: wrap;
}
.count-cell {
  flex: 1 1 0;
  min-width: 110px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
  padding: 1rem 0.6rem;
  position: relative;
}
.count-cell + .count-cell { border-left: 1px solid rgba(37,99,235,0.1); }
.count-dot { width: 8px; height: 8px; border-radius: 50%; margin-bottom: 2px; }
.count-num {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.7rem;
  line-height: 1;
}
.count-label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

/* AI report */
.ai-report { margin-bottom: 0.9rem; }
.ai-report-card {
  background: linear-gradient(135deg, rgba(37,99,235,0.1), rgba(96,165,250,0.06));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(37,99,235,0.22);
  border-radius: 18px;
  padding: 1.1rem 1.3rem;
}
.ai-report-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--blue-2);
  margin-bottom: 0.5rem;
}
.ai-report-badge svg { width: 15px; height: 15px; }
.ai-report-loading {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.85rem;
  color: var(--muted);
}
.ai-dot-pulse { display: inline-flex; gap: 4px; }
.ai-dot-pulse span {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--blue);
  animation: zrPulse 1.2s ease-in-out infinite;
}
.ai-dot-pulse span:nth-child(2) { animation-delay: 0.2s; }
.ai-dot-pulse span:nth-child(3) { animation-delay: 0.4s; }
@keyframes zrPulse { 0%, 100% { opacity: 0.25; } 50% { opacity: 1; } }
.ai-report-text {
  font-size: 0.9rem;
  line-height: 1.6;
  color: rgba(15,23,42,0.8);
}

/* select bar */
.select-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 1.1rem;
  background: rgba(255,255,255,0.45);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.6);
  border-radius: 14px;
  margin-bottom: 0.9rem;
}
.select-bar-left { display: flex; align-items: center; gap: 0.55rem; }
.select-all-cb {
  width: 18px; height: 18px;
  accent-color: var(--blue);
  cursor: pointer;
}
.select-all-label {
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
}
.selected-count {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ===== CHALLAN RECEIPTS — paper e-challan documents ===== */
.cards-container { display: flex; flex-direction: column; gap: 1.4rem; }

.rcpt {
  --pc: #2563eb;
  --paper: #fdfcf7;
  position: relative;
  background: transparent;
  border: 0;
  padding: 0;
  filter: drop-shadow(0 16px 28px rgba(15,23,42,0.16));
  transition: transform 0.35s var(--ease), filter 0.35s, opacity 0.3s;
}
.rcpt:hover {
  transform: translateY(-3px);
  filter: drop-shadow(0 22px 40px rgba(37,99,235,0.22));
}
.challan-card.rcpt.deselected {
  opacity: 0.5;
  filter: drop-shadow(0 10px 18px rgba(15,23,42,0.1)) grayscale(0.75);
}
.challan-card[data-path="A"] { --pc: #16a34a; }
.challan-card[data-path="B"] { --pc: #2563eb; }
.challan-card[data-path="C"] { --pc: #d97706; }
.challan-card[data-path="D"] { --pc: #dc2626; }

/* perforated receipt edges */
.rcpt-edge {
  height: 10px;
  background-color: transparent;
}
.rcpt-edge-top {
  background-image: radial-gradient(circle at 7px 0, transparent 5px, var(--paper) 5.5px);
  background-size: 14px 10px;
}
.rcpt-edge-bot {
  background-image: radial-gradient(circle at 7px 10px, transparent 5px, var(--paper) 5.5px);
  background-size: 14px 10px;
}

.rcpt-body {
  position: relative;
  background: var(--paper);
  padding: 1.1rem 1.35rem 1rem;
  overflow: hidden;
}
/* faint PENDING watermark */
.rcpt-body::after {
  content: 'PENDING';
  position: absolute;
  top: 36%;
  right: 4%;
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 4.4rem;
  letter-spacing: 0.12em;
  color: rgba(220,38,38,0.05);
  transform: rotate(-16deg);
  pointer-events: none;
  white-space: nowrap;
}

/* header */
.rcpt-head {
  display: flex;
  align-items: center;
  gap: 0.95rem;
}
.rcpt-select {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 0.4rem 0.6rem;
  border: 1.5px dashed rgba(37,99,235,0.4);
  border-radius: 10px;
  background: rgba(37,99,235,0.05);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s, border-color 0.2s;
}
.rcpt-select:hover { background: rgba(37,99,235,0.1); }
.rcpt-select span {
  font-size: 0.54rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1.2;
  color: var(--blue-2);
}
.cc-checkbox {
  width: 19px; height: 19px;
  accent-color: var(--blue);
  cursor: pointer;
}
.rcpt-head-mid { flex: 1; min-width: 0; }
.rcpt-doc-title {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: 0.12em;
  line-height: 1;
  color: var(--ink);
}
.rcpt-doc-sub {
  margin-top: 2px;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(15,23,42,0.45);
}
.rcpt-no { text-align: right; max-width: 46%; }
.rcpt-no span {
  display: block;
  font-size: 0.54rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(15,23,42,0.45);
}
.rcpt-no strong {
  font-family: 'Share Tech Mono', monospace;
  font-weight: 400;
  font-size: 0.88rem;
  color: var(--ink);
  word-break: break-all;
  line-height: 1.3;
}

/* separators */
.rcpt-sep {
  border-top: 1px solid rgba(15,23,42,0.08);
  margin: 0.8rem 0;
}
.rcpt-sep.rcpt-dashed {
  border-top: 1.5px dashed rgba(15,23,42,0.2);
}

/* offence + rotated path stamp */
.rcpt-offense { position: relative; padding-right: 175px; min-height: 52px; }
.rcpt-offense-label {
  font-size: 0.56rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(15,23,42,0.45);
  margin-bottom: 2px;
}
.rcpt-offense-main {
  font-size: 1.04rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--ink);
}
.rcpt-offense-list {
  margin: 0.4rem 0 0 1.1rem;
  font-size: 0.8rem;
  color: rgba(15,23,42,0.7);
}
.rcpt-offense-list li { padding: 0.08rem 0; }
.rcpt-stamp {
  position: absolute;
  top: 4px; right: 0;
  max-width: 165px;
  transform: rotate(5deg);
  border: 2.5px solid var(--pc);
  color: var(--pc);
  border-radius: 9px;
  padding: 0.32rem 0.7rem;
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1.1;
  background: rgba(255,255,255,0.55);
  box-shadow: inset 0 0 12px rgba(15,23,42,0.06);
  opacity: 0.92;
}

/* details grid */
.rcpt-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.7rem 1rem;
}
.rcpt-cell span {
  display: block;
  font-size: 0.56rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: rgba(15,23,42,0.42);
  margin-bottom: 1px;
}
.rcpt-cell strong {
  font-size: 0.83rem;
  font-weight: 600;
  line-height: 1.35;
  color: rgba(15,23,42,0.88);
  word-break: break-word;
}
.rcpt-wide { grid-column: 1 / -1; }
.rcpt-status {
  font-style: normal;
  font-weight: 800;
  color: #b91c1c;
}

/* amounts — bill style */
.rcpt-amt-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.18rem 0;
}
.rcpt-amt-row span {
  font-size: 0.82rem;
  color: rgba(15,23,42,0.6);
}
.rcpt-amt-row strong.rcpt-amt {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--ink);
}
.rcpt-struck {
  font-family: var(--f-disp);
  font-weight: 700;
  font-size: 1.1rem;
  color: rgba(15,23,42,0.38);
  text-decoration: line-through;
}
.rcpt-pay span { font-weight: 700; color: var(--ink); }
.rcpt-pay strong {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.65rem;
  color: var(--green);
}
.rcpt-save-row {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.25rem;
}
.rcpt-off-tag {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 0.68rem;
  letter-spacing: 0.07em;
  color: #fff;
  background: linear-gradient(135deg, #22c55e, #15803d);
  border-radius: 100px;
  padding: 0.18rem 0.6rem;
}
.rcpt-save-chip {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--green);
  background: rgba(34,197,94,0.1);
  border: 1px dashed rgba(34,197,94,0.45);
  border-radius: 8px;
  padding: 0.28rem 0.6rem;
}
.rcpt-route {
  margin-top: 0.6rem;
  font-size: 0.74rem;
  font-style: italic;
  color: rgba(15,23,42,0.5);
}

/* barcode footer */
.rcpt-foot {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-top: 0.85rem;
  padding-top: 0.7rem;
  border-top: 1px solid rgba(15,23,42,0.08);
}
.rcpt-barcode {
  flex: 0 0 140px;
  height: 26px;
  background: repeating-linear-gradient(90deg,
    #0f172a 0 2px, transparent 2px 5px,
    #0f172a 5px 6px, transparent 6px 8px,
    #0f172a 8px 11px, transparent 11px 13px);
  opacity: 0.82;
}
.rcpt-barcode-num {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  color: rgba(15,23,42,0.55);
  word-break: break-all;
}
.rcpt-foot-brand {
  margin-left: auto;
  font-size: 0.56rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(15,23,42,0.35);
  white-space: nowrap;
}

/* ===== SETTLED / PAID receipts ===== */
.settled-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.2rem;
  padding: 0.85rem 1.15rem;
  background: rgba(34,197,94,0.09);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(34,197,94,0.3);
  border-radius: 14px;
  cursor: pointer;
  user-select: none;
  transition: background 0.2s, transform 0.25s var(--ease);
}
.settled-toggle:hover { background: rgba(34,197,94,0.15); transform: translateY(-1px); }
.settled-toggle-left {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.87rem;
  font-weight: 700;
  color: #15803d;
}
.settled-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #22c55e, #15803d);
  color: #fff;
  font-size: 0.62rem;
  font-weight: 800;
  font-style: normal;
  flex-shrink: 0;
}
.settled-toggle-arrow {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #15803d;
  white-space: nowrap;
}
.settled-container {
  margin-top: 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
}
.rcpt-paid { --paper: #f7faf4; }
.rcpt-paid:hover { filter: drop-shadow(0 22px 40px rgba(34,197,94,0.22)); }
.rcpt-paid .rcpt-stamp {
  border-color: #15803d;
  color: #15803d;
}
.rcpt-paid .rcpt-body::after {
  content: 'PAID';
  color: rgba(21,128,61,0.06);
}
.rcpt-paid-stub {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 0.45rem 0.75rem;
  border-radius: 10px;
  background: linear-gradient(135deg, #22c55e, #15803d);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 800;
  flex-shrink: 0;
  box-shadow: 0 6px 16px rgba(34,197,94,0.3);
}
.rcpt-paid-stub span {
  font-size: 0.54rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.rcpt-status-ok { color: #15803d !important; }

.skipped-note {
  text-align: center;
  font-size: 0.78rem;
  font-style: italic;
  color: var(--muted);
  margin-top: 1rem;
}
.disclaimer {
  margin-top: 1.2rem;
  padding: 0.9rem 1.1rem;
  font-size: 0.72rem;
  line-height: 1.55;
  color: rgba(15,23,42,0.5);
  background: rgba(255,255,255,0.4);
  border: 1px solid rgba(255,255,255,0.55);
  border-radius: 12px;
}

/* empty / error states */
.empty-state, .error-state {
  text-align: center;
  padding: 3rem 1.4rem;
  background: var(--g-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--g-border);
  border-radius: 20px;
  box-shadow: var(--g-shadow);
}
.empty-icon, .error-icon {
  width: 60px; height: 60px;
  margin: 0 auto 1rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 1.5rem;
  font-weight: 800;
}
.empty-icon { background: rgba(34,197,94,0.14); color: var(--green); }
.error-icon { background: rgba(220,38,38,0.1); color: #dc2626; }
.empty-title {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.8rem;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}
.empty-desc { color: var(--muted); max-width: 40ch; margin: 0 auto 1.2rem; }
.error-msg { font-weight: 700; font-size: 1.05rem; margin-bottom: 0.4rem; }
.error-hint { color: var(--muted); font-size: 0.85rem; margin-bottom: 1.2rem; }
.error-btn {
  display: inline-block;
  color: #fff;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  padding: 0.8rem 1.7rem;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(37,99,235,0.3);
  transition: transform 0.25s var(--ease);
}
.error-btn:hover { transform: translateY(-2px); }

/* ===== STICKY BOTTOM BAR — dark glass ===== */
.sticky-bar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 600;
  transform: translateY(110%);
  transition: transform 0.5s var(--ease);
  background: linear-gradient(180deg, rgba(15,23,42,0.92), rgba(15,23,42,0.88));
  backdrop-filter: blur(20px) saturate(1.4);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
  border-top: 1px solid rgba(96,165,250,0.25);
  box-shadow: 0 -12px 44px rgba(15,23,42,0.35);
}
.sticky-bar.visible { transform: translateY(0); }
.sticky-inner {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: clamp(1rem, 4vw, 2.5rem);
  padding: 0.9rem 1.25rem;
}
.sticky-col { display: flex; flex-direction: column; }
.sticky-label {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(148,163,184,0.8);
}
.sticky-fine-row { display: flex; align-items: baseline; gap: 0.5rem; }
.sticky-fine-struck {
  font-family: var(--f-disp);
  font-size: 0.95rem;
  color: rgba(148,163,184,0.6);
  text-decoration: line-through;
}
.sticky-amount {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.6rem;
  line-height: 1.1;
  color: #fff;
}
.sticky-saving { color: #4ade80; }
.sticky-pct {
  display: inline-block;
  font-family: var(--f-body);
  font-size: 0.62rem;
  font-weight: 800;
  color: #fff;
  background: rgba(34,197,94,0.35);
  border-radius: 6px;
  padding: 0.1rem 0.4rem;
  vertical-align: middle;
}
.sticky-challan-count {
  font-size: 0.68rem;
  color: rgba(148,163,184,0.75);
}
.sticky-cta {
  margin-left: auto;
  border: 0;
  cursor: pointer;
  font-family: var(--f-body);
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  background: linear-gradient(135deg, #22c55e, #15803d);
  padding: 0.95rem 1.8rem;
  border-radius: 14px;
  box-shadow: 0 8px 28px rgba(34,197,94,0.35);
  transition: transform 0.25s var(--ease), filter 0.2s;
  white-space: nowrap;
}
.sticky-cta:hover { transform: translateY(-2px); filter: brightness(1.07); }

/* ===== CHECKOUT OVERLAY ===== */
.checkout-overlay {
  position: fixed;
  inset: 0;
  z-index: 900;
  display: none;
  align-items: flex-end;
  justify-content: center;
  background: rgba(15,23,42,0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.checkout-overlay.visible { display: flex; }
.checkout-sheet {
  width: 100%;
  max-width: 480px;
  max-height: 92vh;
  overflow-y: auto;
  background: linear-gradient(160deg, rgba(255,255,255,0.96), rgba(240,246,255,0.94));
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255,255,255,0.9);
  border-bottom: 0;
  border-radius: 26px 26px 0 0;
  box-shadow: 0 -20px 70px rgba(15,23,42,0.4);
  animation: zrSheetUp 0.45s var(--ease) both;
}
@keyframes zrSheetUp {
  from { transform: translateY(60px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}
@media (min-width: 640px) {
  .checkout-overlay { align-items: center; padding: 1.5rem; }
  .checkout-sheet { border-radius: 26px; border-bottom: 1px solid rgba(255,255,255,0.9); }
}
.checkout-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 1.4rem 0.8rem;
}
.checkout-title {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.45rem;
  text-transform: uppercase;
}
.checkout-close {
  border: 0;
  background: rgba(15,23,42,0.06);
  color: rgba(15,23,42,0.55);
  width: 32px; height: 32px;
  border-radius: 50%;
  font-size: 1.1rem;
  cursor: pointer;
  line-height: 1;
}
.checkout-body { padding: 0 1.4rem 1.5rem; }
.checkout-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.85rem 1rem;
  background: rgba(37,99,235,0.08);
  border: 1px solid rgba(37,99,235,0.18);
  border-radius: 14px;
  margin-bottom: 1.1rem;
}
.checkout-summary-left { display: flex; flex-direction: column; }
.checkout-summary-left span { font-size: 0.72rem; color: var(--muted); }
.checkout-summary-left strong {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.6rem;
  color: var(--ink);
}
.checkout-summary-saving {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--green);
  text-align: right;
}
.form-group { margin-bottom: 0.85rem; }
.form-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.3rem;
}
.form-input {
  width: 100%;
  border: 1.5px solid rgba(37,99,235,0.22);
  border-radius: 12px;
  background: rgba(255,255,255,0.85);
  padding: 0.8rem 0.95rem;
  font-family: var(--f-body);
  font-size: 0.95rem;
  color: var(--ink);
  outline: 0;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-input:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(37,99,235,0.1); }
.form-input.error { border-color: #dc2626; box-shadow: 0 0 0 4px rgba(220,38,38,0.1); }
.form-terms {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
  margin: 0.9rem 0 1rem;
  cursor: pointer;
}
.form-terms input {
  width: 17px; height: 17px;
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--blue);
}
.form-terms-text { font-size: 0.76rem; color: var(--muted); line-height: 1.45; }
.form-terms-text a { color: var(--blue); }
.pay-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  border: 0;
  cursor: pointer;
  font-family: var(--f-body);
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  padding: 1rem 1.4rem;
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(37,99,235,0.32);
  transition: transform 0.25s var(--ease), filter 0.2s, opacity 0.2s;
}
.pay-btn svg { width: 18px; height: 18px; }
.pay-btn:hover { transform: translateY(-2px); filter: brightness(1.07); }
.pay-btn:disabled { opacity: 0.5; pointer-events: none; }
.form-error {
  display: none;
  margin-top: 0.8rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #dc2626;
  background: rgba(220,38,38,0.07);
  border: 1px solid rgba(220,38,38,0.2);
  border-radius: 10px;
  padding: 0.55rem 0.8rem;
}
.form-error.visible { display: block; }
.form-or {
  text-align: center;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(15,23,42,0.35);
  margin: 0.9rem 0;
}
.wa-alt-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--green);
  text-decoration: none;
  background: rgba(34,197,94,0.08);
  border: 1.5px solid rgba(34,197,94,0.35);
  border-radius: 14px;
  padding: 0.9rem 1.2rem;
  transition: background 0.2s, transform 0.25s var(--ease);
}
.wa-alt-btn svg { width: 18px; height: 18px; }
.wa-alt-btn:hover { background: rgba(34,197,94,0.14); transform: translateY(-1px); }

/* ===== CONFIRMATION ===== */
.confirmation-overlay {
  position: fixed;
  inset: 0;
  z-index: 950;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
  background: rgba(15,23,42,0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.confirmation-overlay.visible { display: flex; }
.confirmation-card {
  width: 100%;
  max-width: 420px;
  text-align: center;
  background: linear-gradient(160deg, rgba(255,255,255,0.96), rgba(240,255,246,0.94));
  border: 1px solid rgba(255,255,255,0.9);
  border-radius: 24px;
  box-shadow: 0 24px 80px rgba(15,23,42,0.4);
  padding: 2rem 1.6rem 1.5rem;
  animation: zrSheetUp 0.45s var(--ease) both;
}
.conf-check {
  width: 64px; height: 64px;
  margin: 0 auto 1rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, #22c55e, #15803d);
  box-shadow: 0 12px 32px rgba(34,197,94,0.4);
}
.conf-check svg { width: 30px; height: 30px; }
.conf-title {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.8rem;
  text-transform: uppercase;
}
.conf-order {
  font-family: var(--f-disp);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  color: var(--blue-2);
  margin: 0.2rem 0 0.6rem;
}
.conf-desc {
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.5;
  max-width: 36ch;
  margin: 0 auto 1.1rem;
}
.conf-details {
  text-align: left;
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(255,255,255,0.8);
  border-radius: 14px;
  padding: 0.4rem 1rem;
  margin-bottom: 1.2rem;
}
.conf-detail-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.82rem;
  padding: 0.5rem 0;
  border-bottom: 1px dashed rgba(15,23,42,0.08);
}
.conf-detail-row:last-child { border-bottom: 0; }
.conf-detail-row span:first-child { color: var(--muted); }
.conf-detail-row span:last-child { font-weight: 700; }
.conf-done-btn {
  width: 100%;
  border: 0;
  cursor: pointer;
  font-family: var(--f-body);
  font-weight: 800;
  font-size: 0.95rem;
  border-radius: 14px;
  padding: 0.95rem 1.2rem;
  transition: transform 0.25s var(--ease), filter 0.2s;
}
.conf-done-btn:hover { transform: translateY(-1px); filter: brightness(1.05); }

/* ===== SPIN WHEEL ===== */
.spin-overlay {
  position: fixed;
  inset: 0;
  z-index: 980;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1.2rem;
  overflow-y: auto;
  background: rgba(8,12,24,0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.spin-overlay.visible { display: flex; }
.spin-header { text-align: center; }
.spin-header-badge {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #fbbf24;
  background: rgba(251,191,36,0.12);
  border: 1px solid rgba(251,191,36,0.35);
  border-radius: 100px;
  padding: 0.35rem 0.9rem;
  margin-bottom: 0.6rem;
}
.spin-header-title {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  text-transform: uppercase;
  color: #fff;
  line-height: 1;
}
.spin-header-sub {
  margin-top: 0.4rem;
  font-size: 0.82rem;
  color: rgba(226,232,240,0.7);
}
.spin-container { position: relative; }
.spin-canvas-wrap {
  position: relative;
  width: min(74vw, 340px);
  height: min(74vw, 340px);
}
.spin-canvas-wrap canvas {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  box-shadow: 0 0 0 8px rgba(255,255,255,0.06), 0 24px 80px rgba(37,99,235,0.3);
}
.spin-pointer {
  position: absolute;
  top: -14px; left: 50%;
  transform: translateX(-50%);
  width: 0; height: 0;
  border-left: 14px solid transparent;
  border-right: 14px solid transparent;
  border-top: 22px solid #fbbf24;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.4));
  z-index: 3;
}
.spin-hub {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 64px; height: 64px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #1e40af, #2563eb);
  border: 3px solid rgba(255,255,255,0.85);
  box-shadow: 0 6px 20px rgba(0,0,0,0.4);
  z-index: 2;
}
.spin-hub-text {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  color: #fff;
}
.spin-btn {
  border: 0;
  cursor: pointer;
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: 0.1em;
  color: #0f172a;
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  padding: 0.95rem 2.6rem;
  border-radius: 100px;
  box-shadow: 0 12px 36px rgba(251,191,36,0.35);
  transition: transform 0.25s var(--ease), filter 0.2s;
}
.spin-btn:hover { transform: translateY(-2px) scale(1.02); }
.spin-btn.spinning { opacity: 0.6; pointer-events: none; }
.spin-result {
  display: none;
  text-align: center;
  max-width: 380px;
}
.spin-result.visible { display: block; animation: zrSheetUp 0.5s var(--ease) both; }
.spin-result-emoji { font-size: 3rem; }
.spin-result-title {
  font-family: var(--f-disp);
  font-weight: 800;
  font-size: 1.7rem;
  text-transform: uppercase;
  color: #fbbf24;
  margin-top: 0.3rem;
}
.spin-result-desc {
  margin-top: 0.4rem;
  font-size: 0.88rem;
  color: rgba(226,232,240,0.85);
  line-height: 1.5;
}
.spin-result-actions {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-top: 1.1rem;
}
.spin-claim-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 800;
  font-size: 0.95rem;
  color: #fff;
  text-decoration: none;
  background: linear-gradient(135deg, #22c55e, #15803d);
  border-radius: 14px;
  padding: 0.95rem 1.4rem;
  box-shadow: 0 10px 30px rgba(34,197,94,0.35);
}
.spin-claim-btn svg { width: 18px; height: 18px; }
.spin-done-btn {
  cursor: pointer;
  font-weight: 700;
  font-size: 0.85rem;
  color: rgba(226,232,240,0.8);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 14px;
  padding: 0.8rem 1.2rem;
}

/* confetti */
.confetti-piece {
  position: fixed;
  top: -10px;
  z-index: 1000;
  pointer-events: none;
  animation: zrConfettiFall linear forwards;
}
@keyframes zrConfettiFall {
  to { transform: translateY(105vh) rotate(720deg); opacity: 0.2; }
}

/* ===== MOBILE ===== */
@media (max-width: 640px) {
  .top-bar-label { display: none; }
  .vh-title { font-size: 2rem; }
  .count-cell { min-width: 88px; padding: 0.8rem 0.4rem; }
  .count-num { font-size: 1.4rem; }
  .rcpt-body { padding: 1rem 1rem 0.9rem; }
  .rcpt-head { flex-wrap: wrap; gap: 0.7rem; }
  .rcpt-no { max-width: 100%; text-align: left; flex-basis: 100%; }
  .rcpt-offense { padding-right: 0; min-height: 0; }
  .rcpt-stamp {
    position: static;
    display: inline-block;
    margin-top: 0.5rem;
    transform: rotate(-2deg);
    font-size: 0.72rem;
  }
  .rcpt-grid { grid-template-columns: 1fr 1fr; gap: 0.6rem 0.8rem; }
  .rcpt-pay strong { font-size: 1.45rem; }
  .rcpt-barcode { flex-basis: 100px; }
  .rcpt-foot-brand { display: none; }
  .rcpt-body::after { font-size: 3rem; }
  .sticky-inner { flex-wrap: wrap; gap: 0.5rem 1.2rem; padding: 0.75rem 1rem; }
  .sticky-amount { font-size: 1.3rem; }
  .sticky-cta { width: 100%; margin-left: 0; order: 9; padding: 0.85rem 1.2rem; }
  .zc-results-app { padding-bottom: 180px; }
}
