/* TPAY-NEW-WEBAPP — one deliberate look taken from the TPay logo: deep navy, gold, silver. */
:root {
  color-scheme: dark;
  --bg: #070c24;
  --surface: #0e1638;
  --surface-2: #16204a;
  --line: #27346c;
  --text: #eef1f8;
  --muted: #a3aecd;
  --gold: #e6ba4c;
  --gold-deep: #b8892a;
  --gold-ink: #1a1203;
  --silver: #dde2ee;
  --violet: #7b6cf6;
  --ok: #45c088;
  --ok-soft: rgba(69, 192, 136, .14);
  --wait: #e9a73f;
  --wait-soft: rgba(233, 167, 63, .14);
  --bad: #ec6b66;
  --bad-soft: rgba(236, 107, 102, .14);
  --radius: 14px;
  --display: "Archivo", "Arial Narrow", Arial, sans-serif;
  --body: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", Consolas, "Courier New", monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
html { background: var(--bg); }
body {
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(123, 108, 246, .18), transparent 60%),
    var(--bg);
  color: var(--text);
  font: 17px/1.55 var(--body);
  min-height: 100%;
}
img { max-width: 100%; }
[hidden] { display: none !important; }
a { color: var(--gold); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding-inline: 20px; }

/* ---------- prototype bar ---------- */
.proto-bar {
  background: repeating-linear-gradient(135deg, #2a2208 0 12px, #231c06 12px 24px);
  color: var(--gold);
  font-size: 13px;
  letter-spacing: .02em;
  text-align: center;
  padding: 6px 16px;
  border-bottom: 1px solid #4a3a0e;
}

/* ---------- masthead ---------- */
.masthead {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 5;
  background: rgba(7, 12, 36, .88);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.masthead-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 10px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand img { width: 44px; height: 44px; }
.brand-name { font: 800 24px/1 var(--display); font-stretch: 112%; letter-spacing: .01em; }
.nav { display: flex; gap: 4px; }
.nav a {
  color: var(--muted); text-decoration: none; font-weight: 600;
  padding: 8px 12px; border-radius: 999px; display: inline-flex; align-items: center; gap: 6px;
}
.nav a:hover { color: var(--text); }
.nav a[aria-current="page"] { color: var(--text); background: var(--surface-2); }
.count {
  background: var(--gold); color: var(--gold-ink); font-size: 12px; font-weight: 700;
  min-width: 20px; height: 20px; border-radius: 999px; display: inline-grid; place-items: center; padding-inline: 6px;
}

main { padding-block: 32px 48px; outline: none; }

/* ---------- type ---------- */
h1, h2, h3 { font-family: var(--display); text-wrap: balance; margin: 0; }
h1 { font-size: clamp(30px, 5vw, 46px); font-weight: 800; font-stretch: 110%; line-height: 1.08; }
h2 { font-size: 24px; font-weight: 700; font-stretch: 106%; }
h3 { font-size: 19px; font-weight: 700; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
.lede { color: var(--muted); font-size: 19px; max-width: 58ch; margin: 0; }
.muted { color: var(--muted); }
.price { font: 800 28px/1 var(--display); font-stretch: 108%; color: var(--silver); font-variant-numeric: tabular-nums; }
.price-big { font-size: 44px; }

/* ---------- home ---------- */
.banner {
  display: block; width: 100%; height: auto; aspect-ratio: 2172 / 724; object-fit: cover;
  border-radius: var(--radius); border: 1px solid rgba(230, 186, 76, .35); margin-bottom: 28px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .45);
}
.hero { margin-bottom: 36px; }
.hero-copy { display: grid; gap: 14px; }
.steps { list-style: none; padding: 0; margin: 6px 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; max-width: 720px; }
.steps li { display: flex; gap: 10px; align-items: flex-start; color: var(--muted); font-size: 15px; line-height: 1.4; }
.steps b { color: var(--text); display: block; }
.step-n {
  flex: none; width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--gold);
  color: var(--gold); font: 700 14px/25px var(--display); text-align: center;
}

.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 8px 0 14px; flex-wrap: wrap; }

.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.card {
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; display: grid; gap: 12px; grid-template-rows: auto auto 1fr auto;
}
.card.is-soon { background: var(--surface); }
.card-top { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.card-app { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.card-name { margin-top: 2px; }
.card p { margin: 0; color: var(--muted); font-size: 15.5px; }
.receive { font-size: 15px; color: var(--text); border-top: 1px dashed var(--line); padding-top: 10px; }
.receive span { color: var(--muted); display: block; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 2px; }
.card-cal { font-size: 13.5px; font-weight: 600; color: var(--gold); }
.validity-line { margin: 0 0 4px; }
.cal-note {
  margin-top: 10px; border: 1px solid rgba(230, 186, 76, .35); border-radius: 10px;
  background: rgba(230, 186, 76, .06); padding: 10px 12px; display: grid; gap: 6px; font-size: 15px;
  font-variant-numeric: tabular-nums;
}
.cal-row { display: flex; justify-content: space-between; gap: 6px 12px; flex-wrap: wrap; }
.cal-row span { color: var(--muted); }
.cal-row b { color: var(--text); font-weight: 600; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ---------- status pills ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px;
}
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.pill.ok { color: var(--ok); background: var(--ok-soft); }
.pill.wait { color: var(--wait); background: var(--wait-soft); }
.pill.bad { color: var(--bad); background: var(--bad-soft); }

/* ---------- buttons ---------- */
.btn {
  appearance: none; border: 0; cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 700 16px/1 var(--body); padding: 13px 20px; border-radius: 10px; min-height: 46px;
}
.btn-gold { background: linear-gradient(180deg, #f2cd6c, var(--gold) 55%, var(--gold-deep)); color: var(--gold-ink); box-shadow: 0 6px 20px rgba(230, 186, 76, .22); }
.btn-gold:hover { filter: brightness(1.06); }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--muted); }
.btn[disabled] { cursor: not-allowed; opacity: .55; box-shadow: none; filter: grayscale(.4); }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }
.back { display: inline-flex; gap: 6px; color: var(--muted); text-decoration: none; font-weight: 600; margin-bottom: 18px; }
.back:hover { color: var(--text); }
.linkish { background: none; border: 0; color: var(--gold); cursor: pointer; font: inherit; padding: 0; text-decoration: underline; }

/* ---------- detail / checkout layout ---------- */
.split { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; display: grid; gap: 16px; }
.panel-gold { border-color: rgba(230, 186, 76, .45); background: linear-gradient(180deg, #151b40, var(--surface)); }
.facts { display: grid; gap: 14px; margin: 0; }
.facts div { display: grid; gap: 2px; }
.facts dt { font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 0; }
.howto { margin: 0; padding-left: 22px; display: grid; gap: 4px; }
.notice { border-radius: 10px; padding: 14px 16px; font-size: 15.5px; }
.notice.wait { background: var(--wait-soft); color: #f5cf8f; border: 1px solid rgba(233, 167, 63, .35); }
.notice.bad { background: var(--bad-soft); color: #f6b3b0; border: 1px solid rgba(236, 107, 102, .35); }
.notice.ok { background: var(--ok-soft); color: #a6e5c6; border: 1px solid rgba(69, 192, 136, .35); }
.notice b { color: var(--text); }

.summary-row { display: flex; justify-content: space-between; gap: 12px; font-variant-numeric: tabular-nums; }
.summary-row.total { border-top: 1px solid var(--line); padding-top: 12px; font-weight: 700; font-size: 19px; }

label { font-weight: 600; font-size: 15px; display: grid; gap: 6px; }
input[type="email"] {
  font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 14px; width: 100%;
}
input[type="email"]:focus { border-color: var(--gold); outline: none; }
.field-hint { font-weight: 400; color: var(--muted); font-size: 14px; }
.field-error { color: var(--bad); font-weight: 600; font-size: 14px; }

.mock-pay { border: 1px dashed #6a5a22; border-radius: 12px; padding: 14px 16px; display: grid; gap: 10px; background: rgba(42, 34, 8, .45); }
.mock-pay legend { padding: 0 6px; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.mock-pay label { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.mock-pay input { accent-color: var(--gold); width: 18px; height: 18px; }

/* ---------- processing ---------- */
.processing { display: grid; place-items: center; gap: 18px; text-align: center; padding-block: 60px; }
.spinner { width: 54px; height: 54px; border-radius: 50%; border: 4px solid var(--surface-2); border-top-color: var(--gold); animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- result ---------- */
.result-head { display: flex; gap: 16px; align-items: center; margin-bottom: 22px; }
.result-icon { flex: none; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font: 800 28px/1 var(--display); }
.result-icon.ok { background: var(--ok-soft); color: var(--ok); border: 2px solid var(--ok); }
.result-icon.bad { background: var(--bad-soft); color: var(--bad); border: 2px solid var(--bad); }

/* ---------- voucher ticket ---------- */
.ticket {
  position: relative; border-radius: 16px; overflow: hidden;
  background: linear-gradient(135deg, #1b2663 0%, #111a47 55%, #0c1336 100%);
  border: 1.5px solid var(--gold);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .45), inset 0 0 0 4px rgba(230, 186, 76, .08);
}
.ticket-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 18px 22px; }
.ticket-brand { display: flex; align-items: center; gap: 10px; }
.ticket-brand img { width: 36px; height: 36px; }
.ticket-brand span { font: 800 18px/1 var(--display); font-stretch: 112%; }
.ticket-code-wrap { padding: 6px 22px 20px; display: grid; gap: 8px; }
.ticket-code {
  font: 700 clamp(20px, 4.6vw, 30px)/1.2 var(--mono); letter-spacing: .08em; color: var(--gold);
  word-break: break-all;
}
.ticket-tear { border-top: 2px dashed rgba(230, 186, 76, .4); margin-inline: 14px; }
.ticket-body { padding: 18px 22px 22px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.ticket-body dt { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.ticket-body dd { margin: 2px 0 0; font-variant-numeric: tabular-nums; }
.sample-tag { font-size: 12.5px; color: var(--muted); }

/* ---------- vouchers list ---------- */
.vlist { display: grid; gap: 12px; }
.vrow {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 16px; align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px;
  color: var(--text); text-decoration: none;
}
.vrow:hover { border-color: var(--gold-deep); }
.vrow-code { font: 700 16px/1.3 var(--mono); color: var(--gold); letter-spacing: .05em; }
.vrow-meta { color: var(--muted); font-size: 14.5px; }

.empty { text-align: center; display: grid; justify-items: center; gap: 14px; padding: 56px 20px; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }
.empty-mark { width: 64px; height: 64px; opacity: .55; filter: grayscale(.4); }

/* ---------- footer ---------- */
.footer { padding-block: 22px 40px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14.5px; display: grid; gap: 14px; }
.footer p { margin: 0; max-width: 70ch; }
.reviewer { border: 1px dashed #6a5a22; border-radius: 12px; padding: 12px 14px; background: rgba(42, 34, 8, .35); }
.reviewer summary { cursor: pointer; color: var(--gold); font-weight: 700; }
.reviewer-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; margin: 12px 0; }
.reviewer-grid button {
  font: 600 14px/1.2 var(--body); color: var(--text); background: var(--surface-2);
  border: 1px solid var(--line); border-radius: 8px; padding: 10px; cursor: pointer; text-align: left;
}
.reviewer-grid button:hover { border-color: var(--gold-deep); }

.toast {
  position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%);
  background: var(--silver); color: #0b1030; font-weight: 700; padding: 10px 16px; border-radius: 10px; z-index: 10;
}

/* ---------- phone ---------- */
@media (max-width: 760px) {
  .wrap { padding-inline: 16px; }
  .banner { aspect-ratio: 16 / 7; margin-bottom: 20px; }
  .steps { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; }
  .split > aside { order: -1; }
  .ticket-body { grid-template-columns: 1fr 1fr; }
  .brand-name { font-size: 20px; }
  .brand img { width: 36px; height: 36px; }
  .nav a { padding: 8px 10px; font-size: 15px; }
  .price-big { font-size: 36px; }
  .products { grid-template-columns: 1fr; }
  .card-foot .btn { flex: 1; }
  .vrow { grid-template-columns: 1fr; }
  .vrow .pill { justify-self: start; }
  .btn-row .btn { flex: 1 1 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .spinner { animation-duration: 3s; }
}

/* =====================================================================
   Data-driven components (categories, voucher options, partners, links)
   ===================================================================== */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.small { font-size: 14px; }
.empty-line { padding: 14px 0; margin: 0; }
.pill.muted { color: var(--muted); background: rgba(163, 174, 205, .12); }
.btn-sm { min-height: 38px; padding: 9px 14px; font-size: 14.5px; border-radius: 9px; }
.btn-danger { color: #f6b3b0; border-color: rgba(236, 107, 102, .45); }
.btn-danger-solid { background: var(--bad); color: #1d0605; border: 0; }

/* category cards */
.cats { display: grid; gap: 12px; }
.cat { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.cat.is-open { border-color: rgba(230, 186, 76, .5); background: linear-gradient(180deg, #121a44, var(--surface)); }
.cat-head {
  all: unset; box-sizing: border-box; cursor: pointer; width: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 20px;
}
.cat-head:focus-visible { outline: 2px solid var(--gold); outline-offset: -4px; border-radius: var(--radius); }
.cat-titles { display: grid; gap: 2px; }
.cat-name { font: 800 21px/1.15 var(--display); font-stretch: 108%; text-transform: uppercase; letter-spacing: .02em; color: var(--text); }
.cat-sub { color: var(--gold); font-weight: 600; font-size: 15px; }
.cat-chev {
  flex: none; width: 36px; height: 36px; border-radius: 50%; border: 1.5px solid var(--gold);
  color: var(--gold); display: grid; place-items: center; font: 700 22px/1 var(--display);
}
.cat-body { padding: 0 20px 20px; display: grid; gap: 14px; }
.cat-desc { margin: 0; color: var(--muted); max-width: 64ch; }
.vendor { display: grid; gap: 12px; }
.vendor-note { margin: 0; max-width: 64ch; }

/* voucher options */
.vgroup { display: grid; gap: 8px; }
.vgroup + .vgroup { margin-top: 10px; }
.vgroup-h { margin: 0; font: 700 13px/1.3 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.vopt {
  display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 12px 16px;
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg);
}
.vopt.is-soon { opacity: .75; }
.vopt-main { display: grid; gap: 2px; }
.vopt-label { font-weight: 700; font-size: 17px; }
.vopt-meta { color: var(--muted); font-size: 14px; }
.vopt-price { font: 800 22px/1 var(--display); color: var(--silver); font-variant-numeric: tabular-nums; }

/* search */
.search input {
  font: inherit; color: var(--text); background-color: var(--bg); border: 1.5px solid var(--gold-deep);
  border-radius: 12px; padding: 13px 16px 13px 44px; width: 100%;
  background-image: radial-gradient(circle at 20px 50%, transparent 6px, var(--gold) 6.5px, var(--gold) 8px, transparent 8.5px);
}
.search input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(230, 186, 76, .2); }
.results { display: grid; gap: 12px; }
.result-count { margin: 0; }

/* partner / group card */
.entry { border: 1px solid var(--line); border-radius: 12px; padding: 16px; background: var(--surface-2); display: grid; gap: 12px; }
.entry-head { display: flex; align-items: center; gap: 12px; }
.entry-id { flex: 1; min-width: 0; }
.entry-id h3 { font-size: 20px; }
.entry-desc { margin: 0; color: var(--muted); }
.avatar { flex: none; border-radius: 50%; object-fit: cover; border: 1.5px solid var(--gold-deep); }
.avatar-ph {
  display: inline-grid; place-items: center; font-family: var(--display); font-weight: 800; color: var(--gold);
  background: radial-gradient(circle at 30% 25%, #26357d, #0d1438);
}

/* direct link box */
.linkbox { border: 1px dashed rgba(230, 186, 76, .45); border-radius: 10px; padding: 12px 14px; display: grid; gap: 6px; background: rgba(230, 186, 76, .05); }
.linkbox-label { font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.linkbox-url { font: 600 14.5px/1.4 var(--mono); color: var(--silver); word-break: break-all; }
.linkbox-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.linkbox-note { font-size: 12.5px; color: var(--muted); }

/* direct purchase page */
.direct { display: grid; gap: 18px; max-width: 760px; }
.direct-head { display: flex; align-items: center; gap: 16px; }

/* checkout extras */
.facts-mini { border-top: 1px solid var(--line); padding-top: 10px; font-size: 15px; }
.facts-mini b { display: block; font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.facts-mini p { margin: 0 0 4px; }

/* =====================================================================
   Mock Admin Control
   ===================================================================== */
.admin-badge { display: none; font: 700 11.5px/1 var(--body); letter-spacing: .08em; text-transform: uppercase;
  color: #1d0605; background: var(--wait); padding: 5px 8px; border-radius: 6px; }
body[data-mode="admin"] .admin-badge { display: inline-block; }
body[data-mode="admin"] .masthead { background: rgba(26, 18, 4, .92); border-bottom-color: #4a3a0e; }
.nav-admin { border: 1px dashed #6a5a22; }

.admin-top { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px 24px; flex-wrap: wrap; margin-bottom: 14px; }
.admin-h1 { font-size: clamp(26px, 4vw, 36px); }
.admin-h2 { font-size: 26px; margin-bottom: 18px; }
.admin-note { max-width: 46ch; font-size: 14px; color: #f5cf8f; background: var(--wait-soft); border: 1px solid rgba(233, 167, 63, .35); border-radius: 10px; padding: 10px 12px; }
.atabs { display: flex; gap: 6px; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.atab { color: var(--muted); text-decoration: none; font-weight: 700; padding: 10px 14px; border-bottom: 2px solid transparent; }
.atab[aria-current="page"] { color: var(--text); border-bottom-color: var(--gold); }
.atab-btn { background: none; border: 0; border-bottom: 2px solid transparent; cursor: pointer; font: inherit; font-weight: 700; margin-left: auto; color: var(--bad); }
.saved-banner { margin-bottom: 16px; }

.admin-bar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.admin-bar input, .admin-bar select, .admin-form input, .admin-form select, .admin-form textarea, .cat-add input, .crow input {
  font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; width: 100%;
}
.admin-bar input { flex: 1 1 240px; width: auto; }
.admin-bar select { flex: 0 1 260px; width: auto; }
.admin-form input:focus, .admin-form select:focus, .admin-form textarea:focus, .admin-bar input:focus, .crow input:focus, .cat-add input:focus { outline: none; border-color: var(--gold); }

.arows { display: grid; gap: 10px; }
.arow {
  display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) auto; gap: 10px 16px; align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px;
}
.arow-id { display: flex; gap: 12px; align-items: center; min-width: 0; }
.arow-id b { display: block; }
.arow-id div > span { display: block; }
.arow-link code { font: 500 13.5px/1.3 var(--mono); color: var(--silver); word-break: break-all; }
.arow-status { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.arow-actions { grid-column: 1 / -1; display: flex; gap: 8px; flex-wrap: wrap; }
.arow-confirm { grid-column: 1 / -1; background: var(--bad-soft); border: 1px solid rgba(236, 107, 102, .35); border-radius: 10px; padding: 10px 12px; font-size: 15px; }

.admin-split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.admin-preview { position: sticky; top: calc(84px + env(safe-area-inset-top, 0px)); display: grid; gap: 14px; }
.small-h { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); font-family: var(--body); }
.preview-frame { border: 1px solid var(--line); border-radius: 12px; padding: 16px; background: var(--bg); }
.preview-frame h1 { font-size: 28px; }
.admin-form { gap: 18px; }
.fs { border: 0; padding: 0; margin: 0; display: grid; gap: 12px; min-width: 0; }
.fs legend { font: 700 13px/1.3 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--gold); margin-bottom: 8px; }
.field { display: grid; gap: 6px; }
.field > label, .field .label { font-weight: 600; font-size: 15px; }
.field.check label { display: flex; gap: 10px; align-items: center; }
.field.check input { width: 18px; height: 18px; accent-color: var(--gold); }
.logo-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 6px; }
.form-actions .field-error { flex-basis: 100%; }

.vedit { border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: var(--bg); display: grid; gap: 10px; margin-bottom: 10px; }
.vedit-top { display: flex; justify-content: space-between; align-items: center; }
.vedit-tools { display: flex; gap: 6px; }
.vedit-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.vedit-grid label { font-size: 13.5px; font-weight: 600; color: var(--muted); display: grid; gap: 4px; }
.vedit-grid .span2 { grid-column: 1 / -1; }
.icon-btn { width: 34px; height: 34px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); cursor: pointer; font-size: 15px; }
.icon-btn:disabled { opacity: .35; cursor: default; }

.crow { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; }
.crow-order { display: flex; flex-direction: column; gap: 4px; }
.crow-main { display: grid; gap: 4px; }
.crow-state { display: flex; gap: 8px; align-items: center; }
.cat-add { margin: 14px 0; gap: 8px; }
.cat-add-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.cat-add-row input { flex: 1 1 220px; width: auto; }
.inline-check { display: flex; gap: 8px; align-items: center; font-weight: 600; font-size: 15px; }

@media (max-width: 760px) {
  .vopt { grid-template-columns: minmax(0, 1fr) auto; }
  .vopt .btn { grid-column: 1 / -1; }
  .cat-head { padding: 16px; }
  .cat-body { padding: 0 16px 16px; }
  .cat-name { font-size: 18px; }
  .admin-split { grid-template-columns: 1fr; }
  .admin-preview { position: static; }
  .arow { grid-template-columns: 1fr; }
  .arow-status { justify-content: flex-start; }
  .vedit-grid { grid-template-columns: 1fr; }
  .crow { grid-template-columns: auto minmax(0, 1fr); }
  .crow-state { grid-column: 1 / -1; }
  .atab-btn { margin-left: 0; }
  .direct-head .avatar { width: 56px; height: 56px; }
  .nav a { padding: 8px 8px; font-size: 14.5px; }
}
.facts-mini .cal-row b { display: inline; font-size: inherit; letter-spacing: 0; text-transform: none; color: var(--text); margin: 0; }
.admin-form input.sr { width: 1px; height: 1px; padding: 0; border: 0; }
@media (max-width: 520px) {
  .masthead-row { flex-wrap: wrap; row-gap: 6px; }
  .nav { margin-left: auto; }
  body[data-mode="admin"] .brand-name { display: none; }
}

/* =====================================================================
   Step flow: Apps → app → Direct / Partnerships → type → group
   ===================================================================== */
.step-h { margin: 6px 0 14px; }
.step-title { margin: 2px 0 20px; }
.choices { display: grid; gap: 10px; max-width: 640px; }
.choice {
  display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--text);
  background: linear-gradient(180deg, var(--surface-2), var(--surface)); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 18px; min-height: 64px;
}
.choice:hover { border-color: var(--gold-deep); }
.choice:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.choice-text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.choice-title { font: 800 20px/1.2 var(--display); font-stretch: 106%; }
.choice-sub { color: var(--gold); font-weight: 600; font-size: 15px; }
.choice-go {
  flex: none; width: 34px; height: 34px; border-radius: 50%; border: 1.5px solid var(--gold);
  color: var(--gold); display: grid; place-items: center; font: 700 22px/1 var(--display);
}
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-bottom: 18px; font-size: 15px; }
.crumbs a { color: var(--muted); text-decoration: none; font-weight: 600; }
.crumbs a:hover { color: var(--text); text-decoration: underline; }
.crumbs [aria-current] { color: var(--text); font-weight: 700; }
.crumb-sep { color: var(--line); }
.results .choices { max-width: none; }
.through { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 14px; padding: 6px 12px 6px 6px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); font-size: 15px; }
.through b { color: var(--gold); }

/* =====================================================================
   Mock sign-in, Screen 0 and My account
   ===================================================================== */
.proto-bar a { color: var(--gold); font-weight: 700; }
.nav-btn { background: none; border: 0; color: var(--muted); font: inherit; font-weight: 600; padding: 8px 12px; border-radius: 999px; cursor: pointer; }
.nav-btn:hover { color: var(--text); }

.entry-screen { display: grid; justify-items: center; text-align: center; gap: 14px; padding-block: 28px 20px; max-width: 460px; margin: 0 auto; }
.entry-logo { width: 120px; height: 120px; filter: drop-shadow(0 10px 40px rgba(230, 186, 76, .25)); }
.entry-screen h1 { font-size: clamp(40px, 8vw, 56px); }
.entry-screen .lede { font-size: 17px; }
.entry-actions { display: grid; gap: 10px; width: 100%; margin-top: 8px; }
.entry-actions .btn { width: 100%; min-height: 54px; font-size: 17px; }

.auth { max-width: 440px; margin: 0 auto; display: grid; gap: 14px; }
.auth h1 { margin-bottom: 4px; }
.auth form { gap: 14px; }
.auth input {
  font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 14px; width: 100%;
}
.auth input:focus { border-color: var(--gold); outline: none; }
.auth .btn { width: 100%; }
.auth-switch { text-align: center; color: var(--muted); margin: 0; }

.account-head { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; }
.account-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.account-grid .span2 { grid-column: 1 / -1; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.plain { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.plain li { display: grid; gap: 2px; }
.plain a { color: var(--text); font-weight: 600; text-decoration: none; }
.plain a:hover { color: var(--gold); }
.history { display: grid; gap: 8px; }
.hrow { display: grid; grid-template-columns: 110px minmax(0, 1fr) auto auto; gap: 8px 14px; align-items: center; font-size: 15px; padding-bottom: 8px; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.hrow:last-child { border-bottom: 0; padding-bottom: 0; }

@media (max-width: 760px) {
  .account-grid { grid-template-columns: 1fr; }
  .hrow { grid-template-columns: minmax(0, 1fr) auto; }
  .hrow > :nth-child(2) { grid-column: 1 / -1; order: -1; font-weight: 600; }
  .nav-btn { padding: 8px 8px; font-size: 14.5px; }
}
.pw-field { display: grid; gap: 6px; font-weight: 600; font-size: 15px; }
.pw-wrap { display: flex; align-items: stretch; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); overflow: hidden; }
.pw-wrap:focus-within { border-color: var(--gold); }
.auth .pw-wrap input { border: 0; border-radius: 0; background: transparent; flex: 1; min-width: 0; }
.pw-toggle { flex: none; min-width: 72px; border: 0; border-left: 1px solid var(--line); background: var(--surface-2); color: var(--gold); font: 700 15px/1 var(--body); cursor: pointer; padding: 0 14px; }
.pw-toggle:hover { background: var(--line); }
.pw-toggle:focus-visible { outline: 2px solid var(--gold); outline-offset: -2px; border-radius: 0; }

/* Help / Live Chat mock: css/help.css (canonical, unedited) reads --accent and --tint from the app. */
:root { --accent: #e6ba4c; --tint: rgba(230, 186, 76, .12); }
.help-mount { margin-left: auto; display: flex; align-items: center; }
@media (max-width: 520px) { .help-mount { margin-left: 0; order: 3; flex-basis: 100%; justify-content: flex-end; } .nav { order: 2; } }

/* =====================================================================
   Mock Admin — Partnerships form
   ===================================================================== */
.fs-n { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: 8px; border-radius: 50%;
  border: 1.5px solid var(--gold); color: var(--gold); font: 700 12px/1 var(--body); letter-spacing: 0; vertical-align: 1px; }
.type-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.type-opt { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 999px;
  padding: 8px 14px; cursor: pointer; font-weight: 600; font-size: 15px; background: var(--bg); }
.type-opt input { accent-color: var(--gold); width: 16px; height: 16px; margin: 0; }
.type-opt:has(input:checked) { border-color: var(--gold); background: rgba(230, 186, 76, .1); }
.slug-row { display: flex; align-items: stretch; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--bg); }
.slug-row:focus-within { border-color: var(--gold); }
.slug-pre { padding: 10px 4px 10px 12px; color: var(--muted); font: 500 15px/1.4 var(--mono); }
.admin-form .slug-row input { border: 0; border-radius: 0; padding-left: 0; font-family: var(--mono); }
.split-row { display: flex; gap: 18px 28px; flex-wrap: wrap; align-items: flex-end; }
.split-row label, .split-row .label { display: grid; gap: 6px; font-weight: 600; font-size: 15px; }
.pct { display: inline-flex; align-items: center; gap: 6px; }
.admin-form .pct input { width: 90px; }
.pct-out { font: 800 22px/1.2 var(--display); color: var(--silver); }
.section-path { margin: 0; font-weight: 700; color: var(--text); }
.code-id { font-family: var(--mono); letter-spacing: .04em; color: var(--gold); }
.arow-preview { grid-column: 1 / -1; display: grid; gap: 8px; }
.preview-list { display: grid; gap: 10px; }
.preview-type { margin: 0; font-size: 22px; }
.preview-frame a, .preview-frame button { pointer-events: none; }

/* =====================================================================
   Revenue splits + Events (mock)
   ===================================================================== */
.srow { display: grid; grid-template-columns: minmax(0, 1.4fr) auto auto minmax(0, 1fr) auto; gap: 8px 14px; align-items: end;
  border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--bg); margin-bottom: 8px; }
.srow label { display: grid; gap: 4px; font-size: 13.5px; font-weight: 600; color: var(--muted); }
.admin-form .srow .pct input { width: 76px; }
.srow-total { font-size: 13.5px; font-weight: 700; padding-bottom: 10px; }
.srow-total.ok { color: var(--ok); }
.srow-total.bad { color: var(--bad); }
.srow-fixed { align-items: center; color: var(--muted); font-size: 14.5px; }
.srow-fixed b { color: var(--text); }
.srow-key { font-weight: 700; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.event-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0; }
.event-facts dt { font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.event-facts dd { margin: 2px 0 0; font-weight: 600; }
.event-banner { width: 100%; max-height: 260px; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--line); }
.event-thumb { width: 120px; height: 68px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); display: block; }
.img-ph { display: inline-grid; place-items: center; width: 120px; height: 68px; border-radius: 8px; border: 1px dashed var(--line); color: var(--muted); font-size: 13px; }
.admin-form input[type="date"], .admin-form input[type="time"], .admin-form input[type="datetime-local"] { color-scheme: dark; }
@media (max-width: 760px) {
  .srow { grid-template-columns: 1fr 1fr; }
  .srow .srow-key { grid-column: 1 / -1; }
  .grid2, .grid3, .event-facts { grid-template-columns: 1fr; }
}
.srow { grid-template-columns: auto auto minmax(0, 1fr) auto; }
.srow > .srow-key { grid-column: 1 / -1; }
.srow-fixed { display: flex; flex-wrap: wrap; gap: 6px 18px; }

ul.section-path { margin: 0; padding-left: 18px; display: grid; gap: 4px; }

/* =====================================================================
   Value vouchers (mock wallet)
   ===================================================================== */
.pay-vouchers { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: grid; gap: 10px; margin: 0; }
.pay-vouchers legend { padding: 0 6px; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.wopts { display: grid; gap: 8px; }
.wopt { display: grid; grid-template-columns: auto auto minmax(0, 1fr); gap: 4px 12px; align-items: center; cursor: pointer;
  border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--bg); font-weight: 600; }
.wopt input { accent-color: var(--gold); width: 18px; height: 18px; margin: 0; }
.wopt.is-on { border-color: var(--gold); background: rgba(230, 186, 76, .08); }
.wopt-face { font: 800 19px/1 var(--display); color: var(--silver); font-variant-numeric: tabular-nums; }
.wopt-meta { color: var(--muted); font-size: 13.5px; font-weight: 500; min-width: 0; overflow-wrap: anywhere; }
.wopt-meta code { font-family: var(--mono); font-size: 12.5px; }
.pay-sum { display: grid; gap: 6px; border-top: 1px solid var(--line); padding-top: 10px; }
.wallet-face { font: 800 44px/1 var(--display); color: var(--silver); font-variant-numeric: tabular-nums; }
.wallet-card.is-spent { opacity: .72; border-style: dashed; }
.wallet-detail { max-width: 560px; }
@media (max-width: 760px) { .wopt { grid-template-columns: auto auto; } .wopt-meta { grid-column: 1 / -1; } }

/* [ Mock Admin ] header button — prototype only (V16) */
.nav a.mock-admin-btn { border: 1.5px dashed var(--gold, #e8b64c); color: var(--gold, #e8b64c); font-weight: 700; }
.nav a.mock-admin-btn:hover { background: rgba(232, 182, 76, .12); color: var(--gold, #e8b64c); }
/* lounge 28-day detail, closed by default */
.cal-more { margin-top: 8px; }
.cal-more > summary { cursor: pointer; font-weight: 600; font-size: 14.5px; color: var(--gold, #e8b64c); }
.cal-more > .cal-note { margin-top: 8px; }
/* Admin: lounge pricing & rewards */
.rule-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.rule-card h3 { margin: 0; display: flex; gap: 10px; align-items: baseline; }
.rule-tag { font-family: "JetBrains Mono", monospace; font-size: 13px; color: var(--gold, #e8b64c); }
.rule-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; font-size: 15px; }
.rule-table th, .rule-table td { text-align: left; padding: 7px 8px; border-bottom: 1px solid rgba(255,255,255,.08); vertical-align: top; }
.rule-table th { font-size: 12.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 700; }
.rule-scroll { overflow-x: auto; }
.calc-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; }
.calc-row label { display: grid; gap: 4px; }
/* Contracts (V17) */
.alist { display: grid; gap: 10px; }
.admin-h3 { margin: 0; font-size: 19px; }
.contract-block .section-head { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; margin-bottom: 6px; }

/* ---------- TASK 001 (Debut Authors, approved mock-up 7 Oct 2026) ---------- */
.codes-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.codes-list li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 14px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; }
.codes-list code { font-size: 17px; letter-spacing: .04em; overflow-wrap: anywhere; }
.inline-check.tickrow { align-items: flex-start; margin: 4px 0 12px; }
.inline-check.tickrow input { margin-top: 4px; width: 18px; height: 18px; flex: none; }
/* The same bar at the bottom of every customer screen: Back · Live chat · Log in/out · Purchase · Partner admin */
.bottombar { position: sticky; bottom: 0; z-index: 20; background: var(--bg); border-top: 1px solid var(--line); padding-block: 10px calc(10px + env(safe-area-inset-bottom, 0px)); }
.bottombar .grp { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; max-width: 640px; margin: 0 auto; }
.bottombar .btn { padding: 8px 2px; font-size: 13px; text-align: center; white-space: normal; line-height: 1.2; min-width: 0; }
.chat-choice-note { margin: 0; }

/* ---------- TASK 001: customer screens match the approved mock-up (Jacqui, 8 Oct 2026) ----------
   A phone-sized web app: every customer screen is drawn at phone width, centred on a computer. Nothing that isn't in
   the mock-up: no test bar, no Admin button, no Help / Live Chat header button (Live chat is in the bottom bar),
   no footer text or test-jump box. TPay Admin keeps its own wide layout and still opens at #admin. */
body:not([data-mode="admin"]) .proto-bar,
body:not([data-mode="admin"]) .mock-admin-btn,
body:not([data-mode="admin"]) .help-mount,
body:not([data-mode="admin"]) .tphelp-panel,
body:not([data-mode="admin"]) .footer,
body:not([data-mode="admin"]) .nav a[data-auth="out"] { display: none !important; }
body:not([data-mode="admin"]) .wrap { max-width: 420px; padding-inline: 16px; }
body:not([data-mode="admin"]) main.wrap { border-inline: 1px solid rgba(255,255,255,.1); min-height: calc(100vh - 140px); padding-block: 18px; }
body:not([data-mode="admin"]) .masthead .brand-name { font-size: 22px; }
body:not([data-mode="admin"]) .masthead .brand img { width: 34px; height: 34px; }
body:not([data-mode="admin"]) .nav a, body:not([data-mode="admin"]) .nav .nav-btn { padding: 6px 8px; font-size: 14px; }
body:not([data-mode="admin"]) .split, body:not([data-mode="admin"]) .steps, body:not([data-mode="admin"]) .products,
body:not([data-mode="admin"]) .account-grid { grid-template-columns: 1fr !important; }
body:not([data-mode="admin"]) .split { gap: 16px; }
body:not([data-mode="admin"]) .ticket-body { grid-template-columns: 1fr 1fr; }
body:not([data-mode="admin"]) .vopt { grid-template-columns: minmax(0, 1fr) auto; }
body:not([data-mode="admin"]) .vopt .btn { grid-column: 1 / -1; justify-self: start; }
body:not([data-mode="admin"]) .vrow { grid-template-columns: 1fr; }
body:not([data-mode="admin"]) #view h1 { font-size: 30px; }
body:not([data-mode="admin"]) .entry-screen h1 { font-size: 40px; }
body:not([data-mode="admin"]) .choice-title { font-size: 18px; }
body:not([data-mode="admin"]) .bottombar .grp { max-width: 420px; padding-inline: 16px; }
body:not([data-mode="admin"]) .bottombar .btn { font-size: 12px; }

/* TASK 001: Issue voucher — "What it opens" (approved mock-up D1) */
.opt-grid { display: grid; gap: 8px; }
.admin-form label.opt { display: flex !important; flex-direction: row; justify-content: flex-start; align-items: flex-start; gap: 10px; text-align: left; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; cursor: pointer; }
.admin-form label.opt:has(input:checked) { border-color: var(--gold); background: rgba(230, 186, 76, .1); }
.admin-form label.opt input { width: 16px !important; height: 16px; flex: none; padding: 0; margin-top: 4px; accent-color: var(--gold); }
.admin-form label.opt > span { flex: 1; } .opt b { display: block; } .opt .small { display: block; opacity: .75; }

/* TASK 001 care@home (approved mock-up E1, D4) */
.care-day { display: grid; gap: 6px; margin-bottom: 12px; }
.care-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-weight: 700; }
.care-row { display: grid; grid-template-columns: auto 1fr auto 1fr auto; gap: 6px; align-items: center; font-size: 15px; }
.care-row b { font-family: var(--mono, "JetBrains Mono", monospace); font-weight: 700; }
.care-row input, .care-head input { width: 100%; min-width: 0; padding: 6px 8px; font: inherit; font-size: 14px; }
.care-head input { width: 120px; }
.care-grand { font-size: 20px; }
a.care-link { color: inherit; text-decoration: none; } a.care-link:hover span { color: var(--gold); }
