/* Gold shop — no build step needed. Brand colors come from the admin panel
   and are injected as --primary / --accent in layouts/base.blade.php. */

@font-face {
  font-family: "Vazirmatn";
  src: url("../fonts/Vazirmatn.woff2") format("woff2-variations"), url("../fonts/Vazirmatn.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --primary: #8F6B14;
  --accent: #C9A227;
  --gold-900: #5E450A;
  --gold-700: #8F6B14;
  --gold-500: #C9A227;
  --gold-300: #E8D28A;
  --gold-100: #FAF3DC;
  --ink: #2B2417;
  --muted: #7A6E55;
  --line: #EBDFC0;
  --surface: #FFFFFF;
  --page: #FCFAF4;
  --up: #1E7A4C;
  --down: #B3372F;
  --warn-bg: #FFF6E0;
  --warn-ink: #7A5300;
  --radius: 8px;
  --shadow: 0 1px 2px rgba(94, 69, 10, .07), 0 4px 16px rgba(94, 69, 10, .07);
  --step--1: .8125rem;
  --step-0: .9375rem;
  --step-1: 1.125rem;
  --step-2: 1.375rem;
  --step-3: 1.75rem;
  --step-4: 2.5rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-size: var(--step-0);
  line-height: 1.75;
  color: var(--ink);
  background: var(--page);
  font-feature-settings: "ss01";
}
img { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.35; margin: 0 0 .5em; font-weight: 800; }
h1 { font-size: var(--step-3); }
h2 { font-size: var(--step-2); }
h3 { font-size: var(--step-1); }
p { margin: 0 0 1em; }
.num { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }
.muted { color: var(--muted); }
.small { font-size: var(--step--1); }
.up { color: var(--up); }
.down { color: var(--down); }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 70%, transparent); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: 16px; }
.stack > * + * { margin-top: 16px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.grid { display: grid; gap: 16px; }
.grid.cols-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }

/* ── Rate board: the shop's price board, on every page ── */
.rateboard { background: var(--primary); color: #fff; }
.rateboard .container { display: flex; align-items: center; gap: 24px; min-height: 44px; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
.rateboard .container::-webkit-scrollbar { display: none; }
.rate { display: flex; align-items: baseline; gap: 8px; font-size: var(--step--1); }
.rate b { font-size: var(--step-0); font-weight: 700; }
.rate .lbl { opacity: .72; }
.rateboard .stamp { margin-inline-start: auto; opacity: .65; font-size: var(--step--1); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #4ADE80; display: inline-block; }
.dot.off { background: #F87171; }
.rate b.flash { animation: flash 1.2s ease-out; }
@keyframes flash { from { color: var(--accent); } to { color: inherit; } }

/* ── Header ── */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.site-header .container { display: flex; align-items: center; gap: 24px; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 800; font-size: var(--step-1); }
.brand:hover { text-decoration: none; }
.brand img { height: 40px; width: auto; }
.brand-mark { width: 36px; height: 36px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, color-mix(in srgb, var(--accent) 55%, #fff), var(--accent) 60%, color-mix(in srgb, var(--accent) 70%, #000)); }
.nav { display: flex; gap: 4px; }
.nav a { color: var(--ink); padding: 8px 12px; border-radius: 6px; }
.nav a:hover, .nav a[aria-current="page"] { background: var(--page); text-decoration: none; }
.header-actions { margin-inline-start: auto; display: flex; gap: 8px; align-items: center; }
.cart-link { position: relative; }
.badge { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 700; }
.menu-toggle { display: none; }
@media (max-width: 860px) {
  .menu-toggle { display: inline-flex; }
  .nav { display: none; position: absolute; inset-inline: 0; top: 100%; background: var(--surface); flex-direction: column; padding: 8px 16px 16px; border-bottom: 1px solid var(--line); }
  .nav.open { display: flex; }
  .header-actions .btn-label { display: none; }
}

/* ── Buttons & forms ── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: var(--radius); border: 1px solid transparent; font: inherit; font-weight: 700; cursor: pointer; background: var(--primary); color: #fff; text-decoration: none; transition: background-color .15s, border-color .15s; }
.btn:hover { text-decoration: none; background: color-mix(in srgb, var(--primary) 88%, #000); }
.btn.accent { background: var(--accent); }
.btn.accent:hover { background: color-mix(in srgb, var(--accent) 88%, #000); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { background: var(--page); }
.btn.danger { background: var(--down); }
.btn.sm { min-height: 34px; padding: 0 12px; font-size: var(--step--1); }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.icon-btn { width: 44px; height: 44px; padding: 0; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field label, .label { font-weight: 600; font-size: var(--step--1); }
.input, select.input, textarea.input { width: 100%; min-height: 44px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 6px; background: #fff; font: inherit; color: var(--ink); }
textarea.input { min-height: 110px; }
.input:focus { border-color: var(--primary); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.input.ltr { direction: ltr; text-align: left; }
.hint { color: var(--muted); font-size: var(--step--1); }
.error { color: var(--down); font-size: var(--step--1); }
.check { display: flex; gap: 8px; align-items: center; min-height: 32px; }
.check input { width: 18px; height: 18px; accent-color: var(--primary); }
.form-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.form-grid .full { grid-column: 1 / -1; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 0; }
legend { font-weight: 800; padding: 0 6px; }

.segmented { display: inline-flex; background: var(--page); border: 1px solid var(--line); border-radius: var(--radius); padding: 3px; }
.segmented a, .segmented label { padding: 6px 18px; border-radius: 6px; color: var(--muted); font-weight: 700; cursor: pointer; }
.segmented a:hover { text-decoration: none; }
.segmented .on, .segmented input:checked + span { background: #fff; color: var(--ink); box-shadow: var(--shadow); }
.segmented input { position: absolute; opacity: 0; }
.segmented label span { display: block; padding: 0; }

/* ── Surfaces ── */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.panel > h2:first-child, .panel > h3:first-child { margin-top: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.panel-head h2, .panel-head h3 { margin: 0; }
.alert { padding: 12px 16px; border-radius: var(--radius); border: 1px solid; margin-bottom: 16px; }
.alert.success { background: #EAF6EF; border-color: #BFE3CD; color: #14532D; }
.alert.error { background: #FCEDEC; border-color: #F1C4C0; color: #7F1D1D; }
.alert.warn { background: var(--warn-bg); border-color: #F2DDA6; color: var(--warn-ink); }

.stat { display: flex; flex-direction: column; gap: 2px; }
.stat .v { font-size: var(--step-2); font-weight: 800; }
.stat .k { color: var(--muted); font-size: var(--step--1); }

.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; font-size: var(--step--1); }
.table th, .table td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: start; vertical-align: middle; white-space: nowrap; }
.table th { color: var(--muted); font-weight: 600; background: #FAFBFC; }
.table tr:last-child td { border-bottom: 0; }
.table td.wrap { white-space: normal; min-width: 200px; }
.pill { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--page); color: var(--muted); }
.pill.ok { background: #E3F4EA; color: var(--up); }
.pill.bad { background: #FBE6E4; color: var(--down); }
.pill.wait { background: var(--warn-bg); color: var(--warn-ink); }
.pill.info { background: color-mix(in srgb, var(--primary) 12%, #fff); color: var(--primary); }
.empty { text-align: center; padding: 40px 16px; color: var(--muted); }
.empty .btn { margin-top: 12px; }

dl.kv { display: grid; grid-template-columns: max-content 1fr; gap: 8px 24px; margin: 0; }
dl.kv dt { color: var(--muted); }
dl.kv dd { margin: 0; font-weight: 600; }

/* ── Storefront ── */
.hero { padding: 40px 0 32px; }
.hero-grid { display: grid; gap: 24px; grid-template-columns: 1.15fr .85fr; align-items: stretch; }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; } }
.hero h1 { font-size: clamp(1.75rem, 4vw, 2.6rem); font-weight: 900; letter-spacing: -.01em; max-width: 18ch; }
.hero .lead { color: var(--muted); font-size: var(--step-1); max-width: 46ch; }

.ticket { background: var(--primary); color: #fff; border-radius: 14px; padding: 24px; display: flex; flex-direction: column; gap: 18px; position: relative; overflow: hidden; }
.ticket::after { content: ""; position: absolute; inset-inline-end: -60px; top: -60px; width: 200px; height: 200px; border-radius: 50%; border: 28px solid color-mix(in srgb, var(--accent) 35%, transparent); }
.ticket .base { font-size: clamp(2rem, 5vw, 2.75rem); font-weight: 900; line-height: 1.1; }
.ticket .unit { opacity: .7; font-size: var(--step--1); }
.ticket .pair { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: rgba(255,255,255,.18); border-radius: 10px; overflow: hidden; }
.ticket .pair > div { background: var(--primary); padding: 12px 14px; }
.ticket .pair .k { opacity: .7; font-size: var(--step--1); }
.ticket .pair .v { font-weight: 800; font-size: var(--step-1); }
.ticket .btn.accent { position: relative; z-index: 1; }
.ticket .meta { font-size: var(--step--1); opacity: .7; display: flex; gap: 8px; align-items: center; }

.cat-strip { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 4px; }
.cat-chip { flex: 0 0 auto; padding: 10px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; color: var(--ink); font-weight: 600; }
.cat-chip:hover, .cat-chip.on { border-color: var(--primary); color: var(--primary); text-decoration: none; }

.section { padding: 28px 0; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 16px; }
.section-head h2 { margin: 0; }

.product-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; color: var(--ink); }
.product-card:hover { text-decoration: none; border-color: color-mix(in srgb, var(--accent) 60%, var(--line)); }
.product-card .img { aspect-ratio: 1; background: #F0F1F4 center/cover no-repeat; display: grid; place-items: center; }
.product-card .img svg { width: 42%; opacity: .35; }
.product-card .body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.product-card .name { font-weight: 700; line-height: 1.5; }
.product-card .spec { color: var(--muted); font-size: var(--step--1); }
.product-card .price { margin-top: auto; padding-top: 8px; font-weight: 800; }
.product-card .soldout { color: var(--down); font-weight: 700; font-size: var(--step--1); }

.product-layout { display: grid; gap: 32px; grid-template-columns: 1fr 1fr; padding: 28px 0; }
@media (max-width: 860px) { .product-layout { grid-template-columns: 1fr; } }
.gallery .main { aspect-ratio: 1; border-radius: 12px; background: #F0F1F4 center/cover no-repeat; border: 1px solid var(--line); }
.gallery .thumbs { display: flex; gap: 8px; margin-top: 8px; }
.gallery .thumbs button { width: 64px; height: 64px; border-radius: 8px; border: 2px solid var(--line); background: #F0F1F4 center/cover; cursor: pointer; padding: 0; }
.gallery .thumbs button.on { border-color: var(--accent); }
.breakdown { width: 100%; border-collapse: collapse; }
.breakdown td { padding: 8px 0; border-bottom: 1px dashed var(--line); }
.breakdown td:last-child { text-align: left; font-weight: 600; }
.breakdown tr.total td { border-bottom: 0; font-size: var(--step-1); font-weight: 800; padding-top: 12px; }

.trust { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.trust > div { border-inline-start: 3px solid var(--accent); padding: 4px 14px; }
.trust b { display: block; }

.site-footer { background: var(--ink); color: #C9CED6; margin-top: 48px; padding: 40px 0 24px; font-size: var(--step--1); }
.site-footer a { color: #fff; }
.site-footer .cols { display: grid; gap: 24px; grid-template-columns: 2fr 1fr 1fr 1fr; }
@media (max-width: 860px) { .site-footer .cols { grid-template-columns: 1fr 1fr; } }
.site-footer h4 { color: #fff; font-size: var(--step-0); }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.site-footer .legal { border-top: 1px solid rgba(255,255,255,.1); margin-top: 24px; padding-top: 16px; }

/* ── Panels (customer & admin) ── */
.app { display: grid; grid-template-columns: 248px 1fr; min-height: calc(100vh - 44px); }
.sidebar { background: var(--surface); border-inline-end: 1px solid var(--line); padding: 20px 12px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.sidebar .brand { padding: 0 8px 16px; }
.side-nav { display: flex; flex-direction: column; gap: 2px; }
.side-nav a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 6px; color: var(--ink); }
.side-nav a:hover { background: var(--page); text-decoration: none; }
.side-nav a[aria-current="page"] { background: color-mix(in srgb, var(--primary) 10%, #fff); color: var(--primary); font-weight: 700; }
.side-nav svg { width: 18px; height: 18px; flex: 0 0 18px; }
.side-nav .group { margin: 14px 12px 4px; color: var(--muted); font-size: 12px; }
.side-nav .count { margin-inline-start: auto; }
.main { padding: 24px; min-width: 0; }
.main-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.main-head h1 { margin: 0; font-size: var(--step-2); }
.topbar { display: none; }
@media (max-width: 960px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; inset-block: 0; inset-inline-start: 0; width: 272px; z-index: 40; transform: translateX(100%); transition: transform .2s; box-shadow: var(--shadow); }
  .sidebar.open { transform: none; }
  .topbar { display: flex; align-items: center; gap: 12px; padding: 10px 16px; background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
  .main { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

.balance-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; }
.balance-card .k { color: var(--muted); font-size: var(--step--1); }
.balance-card .v { font-size: var(--step-3); font-weight: 900; line-height: 1.3; }
.balance-card .sub { color: var(--muted); font-size: var(--step--1); }
.balance-card.gold { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 7%, #fff), #fff); }

.quote { border: 2px solid var(--accent); border-radius: 12px; padding: 18px; background: color-mix(in srgb, var(--accent) 5%, #fff); }
.countdown { font-weight: 800; color: var(--accent); }

.pagination { display: flex; gap: 4px; justify-content: center; margin-top: 16px; flex-wrap: wrap; }
.pagination a, .pagination span { min-width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; border: 1px solid var(--line); background: #fff; color: var(--ink); padding: 0 8px; }
.pagination .on { background: var(--primary); color: #fff; border-color: var(--primary); }
.pagination .off { opacity: .4; }

.auth-wrap { min-height: calc(100vh - 44px); display: grid; place-items: center; padding: 24px 16px; }
.auth-card { width: 100%; max-width: 400px; }
.otp-input { letter-spacing: .6em; text-align: center; font-size: var(--step-2); font-weight: 800; direction: ltr; }


/* ══ White & gold theme ═══════════════════════════════════════
   Brand colors still come from the admin panel (--primary = deep gold,
   --accent = gold); this block turns the dark surfaces white. */
.rateboard { background: #fff; color: var(--ink); border-bottom: 2px solid var(--accent); }
.rateboard .rate b { color: var(--gold-700); }
.rateboard .rate .lbl { opacity: 1; color: var(--muted); }
.rateboard .stamp { opacity: 1; color: var(--muted); }
.rate b.flash { animation: flash-gold 1.2s ease-out; }
@keyframes flash-gold { from { color: var(--accent); background: var(--gold-100); } to { background: transparent; } }
.trend { font-size: 12px; font-weight: 700; }
.trend.up, .tr.up { color: var(--up); }
.trend.down, .tr.down { color: var(--down); }

.btn.accent { color: var(--gold-900); background: linear-gradient(180deg, #E3C25A, var(--accent)); }
.btn.accent:hover { background: linear-gradient(180deg, #D9B54A, #B8921F); }
.badge { background: var(--accent); color: var(--gold-900); }
.brand-mark { box-shadow: 0 0 0 2px var(--gold-300); }
.site-header { border-bottom: 2px solid var(--gold-300); }
.panel, .balance-card, .product-card { box-shadow: var(--shadow); }
.table th { background: var(--gold-100); color: var(--gold-900); }
.side-nav a[aria-current="page"] { background: var(--gold-100); color: var(--gold-900); border-inline-start: 3px solid var(--accent); }
.sidebar { border-inline-end: 1px solid var(--gold-300); }

.ticket { background: linear-gradient(160deg, #fff 55%, var(--gold-100)); color: var(--ink); border: 1px solid var(--gold-300); box-shadow: var(--shadow); }
.ticket::after { border-color: color-mix(in srgb, var(--accent) 22%, transparent); }
.ticket .unit, .ticket .meta, .ticket .pair .k { opacity: 1; color: var(--muted); }
.ticket .base { color: var(--gold-900); }
.ticket .pair { background: var(--line); }
.ticket .pair > div { background: #fff; }
.ticket .pair .v { color: var(--gold-700); }

.site-footer { background: #fff; color: var(--muted); border-top: 3px solid var(--accent); }
.site-footer a, .site-footer h4 { color: var(--gold-900); }
.site-footer .legal { border-top-color: var(--line); }

/* ── Price board (dashboard) ── */
.board-notice { background: #fff; border: 1px solid var(--line); border-inline-start: 4px solid var(--accent); border-radius: var(--radius); padding: 10px 14px; color: var(--gold-900); font-weight: 600; margin-bottom: 14px; }
.board-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin: 18px 0 8px; }
.board-title { margin: 0; font-size: var(--step-0); font-weight: 700; color: var(--ink); }
.board-updated { color: var(--muted); font-size: var(--step--1); }
.board-row { display: grid; grid-template-columns: 1.15fr 1fr 1fr; gap: 6px; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); padding: 6px; margin-bottom: 8px; }
.board-row .lbl { display: flex; align-items: center; padding: 0 10px; font-weight: 700; line-height: 1.5; }
.board-row .cell { border-radius: 6px; color: #fff; text-align: center; min-height: 58px; padding: 6px 4px; display: flex; flex-direction: column; justify-content: center; align-items: center; font-weight: 800; font-size: var(--step-1); }
.board-row .cell.sell { background: #2DC84D; }
.board-row .cell.buy { background: #E53935; }
.board-row .cell.none { font-size: var(--step-0); }
.board-row .cell .tr { font-size: 12px; font-weight: 600; min-height: 16px; line-height: 16px; color: #fff; opacity: .95; }
.board-row .cell .tr.up, .board-row .cell .tr.down { color: #fff; }
.board-row .cell.flash { animation: cell-flash 1s ease-out; }
@keyframes cell-flash { from { box-shadow: 0 0 0 3px var(--gold-300); } to { box-shadow: 0 0 0 0 transparent; } }
@media (max-width: 480px) {
  .board-row { grid-template-columns: 1fr 1fr 1fr; }
  .board-row .cell { font-size: var(--step-0); }
  .board-row .lbl { font-size: var(--step--1); padding: 0 6px; }
}


/* ── Home: melted gold first ── */
.hero-grid.melted-first { grid-template-columns: .95fr 1.05fr; }
@media (max-width: 860px) { .hero-grid.melted-first { grid-template-columns: 1fr; } }
.ticket .base .trend { font-size: 13px; }

/* ── Statement ── */
.statement-title { font-weight: 800; color: var(--gold-900); text-align: center; padding: 6px 0 12px; }
.statement-filter { align-items: end; gap: 12px; flex-wrap: wrap; }
.statement-table { font-size: 11px; min-width: 0; width: 100%; }
.statement-table th, .statement-table td { border: 1px solid var(--line); text-align: center; padding: 5px 2px; white-space: nowrap; }
.statement-table td.desc, .statement-table th.desc { white-space: normal; min-width: 110px; text-align: right; padding-inline: 4px; }
.statement-table td.neg { color: var(--down); }
.statement-table tr.opening td { background: var(--gold-100); font-weight: 700; }
.statement-table tfoot td { background: var(--gold-100); font-weight: 800; }
@media print {
  .rateboard, .topbar, .sidebar, .tabbar, .statement-filter, .main-head, .toasts, .site-footer { display: none !important; }
  .panel { box-shadow: none; border: 0; }
  .statement-table { min-width: 0; font-size: 10px; }
}

/* ── Bottom tab bar + balance popup (customer panel) ── */
.topbar-user { margin-inline-start: auto; color: var(--muted); font-weight: 600; font-size: var(--step--1); }
.tabbar { display: none; }
@media (max-width: 960px) {
  .tabbar { display: grid; grid-template-columns: repeat(3, 1fr); position: fixed; inset-inline: 0; bottom: 0; z-index: 40; background: #fff; border-top: 2px solid var(--accent); box-shadow: 0 -4px 16px rgba(94, 69, 10, .12); }
  .tabbar a, .tabbar button { padding: 14px 6px; text-align: center; font: inherit; font-weight: 700; color: var(--gold-900); background: #fff; border: 0; border-inline-start: 1px solid var(--line); cursor: pointer; }
  .tabbar a[aria-current="page"] { background: linear-gradient(180deg, #E3C25A, var(--accent)); }
  body { padding-bottom: 54px; }
}
.balance-dialog { border: 0; border-radius: 12px; padding: 0; width: min(520px, 94vw); box-shadow: 0 20px 60px rgba(0, 0, 0, .3); color: var(--ink); }
.balance-dialog::backdrop { background: rgba(43, 36, 23, .55); }
.bd-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px 8px 16px; border-bottom: 1px solid var(--line); }
.bd-head h2 { margin: 0; font-size: var(--step-1); }
.bd-body { padding: 14px; display: grid; gap: 8px; }
.bal-line { display: grid; grid-template-columns: 1.5fr 1.3fr auto; font-size: var(--step--1); gap: 8px; align-items: center; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; font-weight: 700; }
.bal-line .s { font-weight: 800; min-width: 62px; text-align: left; }
.bal-line.credit { color: var(--up); border-color: color-mix(in srgb, var(--up) 35%, transparent); }
.bal-line.debit { color: var(--down); border-color: color-mix(in srgb, var(--down) 35%, transparent); }

/* ── Admin live toasts ── */
.toasts { position: fixed; inset-block-start: 14px; inset-inline-end: 14px; z-index: 100; display: grid; gap: 8px; width: min(360px, calc(100vw - 28px)); }
.toast { display: grid; gap: 2px; background: #fff; color: var(--ink); text-decoration: none; border: 1px solid var(--line); border-inline-start: 5px solid var(--up); border-radius: 8px; padding: 10px 12px; box-shadow: 0 8px 28px rgba(0, 0, 0, .2); animation: toast-in .25s ease-out; transition: opacity .4s; }
.toast.bad { border-inline-start-color: var(--down); }
.toast.out { opacity: 0; }
.toast span { font-size: var(--step--1); color: var(--muted); }
@keyframes toast-in { from { transform: translateY(-8px); opacity: 0; } to { transform: none; opacity: 1; } }


/* ══ UI v2 ═════════════════════════════════════════════════════
   One bold thing: the price board. Everything else stays quiet.
   Tokens: ivory page, gold leaf accent, bronze ink, and a rise/fall
   pair (green/red) used only for price direction and balances. */
:root {
  --rise: #12794A; --rise-bg: #E8F6EE; --rise-line: #BFE3CF;
  --fall: #B3322A; --fall-bg: #FDEDEB; --fall-line: #F2C6C1;
}
body { background: var(--page); }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 70%, #fff); outline-offset: 2px; }

/* top strip: one calm line that scrolls, never wraps or clips */
.rateboard .container { gap: 22px; scroll-snap-type: x proximity; padding-block: 2px; }
.rateboard .rate { scroll-snap-align: start; }
.rateboard .rate b { font-size: var(--step-0); }
@media (max-width: 600px) { .rateboard .stamp { display: none; } }

/* ── price board ── */
.board { max-width: 780px; }
.board-notice { border-radius: 10px; background: var(--gold-100); border: 1px solid var(--gold-300); border-inline-start: 4px solid var(--accent); font-weight: 600; line-height: 1.8; font-size: var(--step--1); }
.board-keys { display: grid; grid-template-columns: minmax(0, 1.1fr) 1fr 1fr; gap: 6px; padding-inline: 6px; margin: 14px 0 -6px; color: var(--muted); font-size: 12px; font-weight: 700; text-align: center; }
.board-head { margin: 22px 0 8px; align-items: center; }
.board-title { display: flex; align-items: center; gap: 8px; font-size: var(--step-0); font-weight: 800; }
.board-title::before { content: ""; width: 4px; height: 1.1em; border-radius: 2px; background: var(--accent); }
.board-updated { font-size: 12px; }
.board-row { grid-template-columns: minmax(0, 1.1fr) 1fr 1fr; gap: 6px; border-radius: 12px; padding: 6px; box-shadow: none; border: 1px solid var(--line); background: #fff; }
.board-row .lbl { font-weight: 700; font-size: var(--step--1); padding-inline: 8px; }
.board-row .cell { border-radius: 8px; min-height: 60px; font-size: var(--step-1); font-weight: 800; letter-spacing: .01em; border: 1px solid transparent; }
.board-row .cell.sell { background: var(--rise-bg); color: var(--rise); border-color: var(--rise-line); }
.board-row .cell.buy { background: var(--fall-bg); color: var(--fall); border-color: var(--fall-line); }
.board-row .cell.none { background: var(--gold-100); color: var(--muted); border: 1px dashed var(--gold-300); font-weight: 700; }
.board-row .cell .tr { font-size: 11.5px; font-weight: 700; opacity: 1; min-height: 16px; color: var(--muted); }
.board-row .cell .tr { border-radius: 999px; padding: 0 8px; margin-top: 2px; }
.board-row .cell .tr.up { color: var(--rise); background: #fff; }
.board-row .cell .tr.down { color: var(--fall); background: #fff; }
.board-row .cell .tr.flat { color: var(--muted); }
.board-row .cell .tr:empty { padding: 0; }
@media (max-width: 480px) {
  .board-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr) minmax(0, 1.05fr); }
  .board-row .cell { font-size: 15px; min-height: 56px; }
  .board-keys { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr) minmax(0, 1.05fr); }
}

/* ── mobile header + tab bar ── */
.avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(160deg, #EBD389, var(--accent)); color: var(--gold-900); font-weight: 800; flex: 0 0 34px; }
.topbar-user { font-size: 13px; }
@media (max-width: 960px) {
  .topbar { padding-block: 8px; }
  .tabbar { border-top: 1px solid var(--gold-300); box-shadow: 0 -6px 20px rgba(94, 69, 10, .08); padding-bottom: env(safe-area-inset-bottom, 0px); }
  .tabbar a, .tabbar button { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 9px 4px 8px; font-size: 12px; font-weight: 700; color: var(--muted); background: #fff; border: 0; border-top: 3px solid transparent; }
  .tabbar svg { width: 22px; height: 22px; }
  .tabbar a[aria-current="page"] { background: #fff; color: var(--gold-900); border-top-color: var(--accent); }
  body { padding-bottom: calc(62px + env(safe-area-inset-bottom, 0px)); }
}

/* ── balance popup ── */
.bal-line { border-radius: 10px; background: #fff; }
.bal-line.credit { background: var(--rise-bg); color: var(--rise); border-color: var(--rise-line); }
.bal-line.debit { background: var(--fall-bg); color: var(--fall); border-color: var(--fall-line); }
.bal-line .k { color: var(--ink); }
.bal-line .s { font-size: 12px; }

/* ── statement: cards on phones ── */
@media (max-width: 720px) {
  .statement-table { min-width: 0; font-size: 13px; }
  .statement-table thead { display: none; }
  .statement-table, .statement-table tbody, .statement-table tfoot { display: block; width: 100%; }
  .statement-table tr { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 12px; background: #fff; margin-bottom: 10px; padding: 10px 12px; }
  .statement-table td, .statement-table td.desc { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; border: 0; padding: 4px 0; text-align: start; white-space: normal; min-width: 0; }
  .statement-table td:empty { display: none; }
  .statement-table td[data-label]::before { content: attr(data-label); color: var(--muted); font-weight: 600; font-size: 12px; flex: 0 0 auto; }
  .statement-table td.doc-type { order: -1; font-weight: 800; font-size: 15px; color: var(--gold-900); border-bottom: 1px solid var(--line); padding-bottom: 8px; margin-bottom: 4px; }
  .statement-table td.desc { order: 99; border-top: 1px dashed var(--line); margin-top: 4px; padding-top: 8px; color: var(--muted); }
  .statement-table td.desc::before, .statement-table td.doc-type::before { display: none; }
  .statement-table tr.opening, .statement-table tfoot tr { background: var(--gold-100); }
  .statement .table-wrap { overflow: visible; }
}

/* ── home hero: quieter ticket ── */
.ticket::after { display: none; }
.ticket { background: #fff; border: 1px solid var(--gold-300); border-top: 4px solid var(--accent); box-shadow: 0 12px 36px rgba(94, 69, 10, .10); }
.ticket .pair > div:first-child .v { color: var(--rise); }
.ticket .pair > div:last-child .v { color: var(--fall); }

.board-row .cell.none .tr { display: none; }
@media (max-width: 600px) {
  .rateboard .container { -webkit-mask-image: linear-gradient(to left, #000 88%, transparent); mask-image: linear-gradient(to left, #000 88%, transparent); }
}


/* ══ UI v3 — Gilded ═════════════════════════════════════════════
   Ivory page, espresso "bullion" surfaces, liquid-gold foil that
   moves slowly. Motion is decoration only and switches off under
   prefers-reduced-motion (global rule above). */
@property --ang { syntax: '<angle>'; initial-value: 0deg; inherits: false; }
:root {
  --espresso: #1A1306; --espresso-2: #2A1E0B; --glint: #FFF3C4;
  --foil: linear-gradient(105deg, #8F6B14 0%, #D9B54A 20%, #FFF3C4 36%, #D9B54A 50%, #8F6B14 68%, #E8CB6A 84%, #8F6B14 100%);
  --foil-dark: linear-gradient(100deg, #5E450A 0%, #A47E15 32%, #C9A227 50%, #A47E15 68%, #5E450A 100%);
  --ease: cubic-bezier(.2, .8, .2, 1);
}
@keyframes foil-move { to { background-position: -250% 0; } }
@keyframes spin-ang { to { --ang: 360deg; } }
@keyframes sweep { from { transform: translateX(120%); } to { transform: translateX(-120%); } }
@keyframes twinkle { 0%, 100% { opacity: 0; transform: scale(.3) rotate(0deg); } 50% { opacity: 1; transform: scale(1) rotate(45deg) translateY(-6px); } }
@keyframes drift { 0% { transform: translate(0, 0) scale(1); } 50% { transform: translate(-40px, 30px) scale(1.12); } 100% { transform: translate(30px, -20px) scale(.94); } }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(94, 226, 154, .55); } 80%, 100% { box-shadow: 0 0 0 8px rgba(94, 226, 154, 0); } }
@keyframes edge { from { background-position: -40% 0; } to { background-position: 140% 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(16px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes bar { to { background-position: 0 -250%; } }

.foil { background: var(--foil); background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; animation: foil-move 7s linear infinite; }

/* top strip becomes a dark bullion bar */
.rateboard { position: relative; background: linear-gradient(90deg, #140E04, #261A09 50%, #140E04); color: #E9D48B; border-bottom: 0; }
.rateboard::after { content: ""; position: absolute; inset: auto 0 0 0; height: 2px; background: linear-gradient(90deg, #8F6B14, #C9A227 50%, #8F6B14); }
.rateboard::before { content: ""; position: absolute; inset: auto 0 0 0; height: 2px; z-index: 1; background: linear-gradient(90deg, transparent, var(--glint), transparent) no-repeat; background-size: 40% 100%; animation: edge 5s linear infinite; }
.rateboard .rate b { color: #F6E3A0; }
.rateboard .rate .lbl, .rateboard .stamp { color: #B9A66B; }
.rateboard .trend.up { color: #5EE29A; }
.rateboard .trend.down { color: #FF8F86; }
.rateboard .dot { animation: ping 2s ease-out infinite; }
.rateboard .dot.off { animation: none; }

/* the coin: a slowly turning gold disc */
.brand-mark { background: conic-gradient(from var(--ang), #8F6B14, #F6E7A6, #C9A227, #5E450A, #F6E7A6, #8F6B14); animation: spin-ang 7s linear infinite; box-shadow: 0 0 0 2px var(--gold-300), 0 4px 12px rgba(143, 107, 20, .35); }

/* primary buttons: gold leaf with a glint */
.btn:not(.ghost):not(.danger) { position: relative; overflow: hidden; background: linear-gradient(180deg, #EACB63, #C9A227 55%, #B08718); color: #2A1D04; border: 0; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55), 0 6px 16px rgba(176, 135, 24, .28); transition: transform .2s var(--ease), box-shadow .2s var(--ease), filter .2s; }
.btn:not(.ghost):not(.danger)::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 36%, rgba(255, 255, 255, .6) 50%, transparent 64%); transform: translateX(120%); }
.btn:not(.ghost):not(.danger):hover { transform: translateY(-1px); filter: saturate(1.08); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .6), 0 10px 22px rgba(176, 135, 24, .38); background: linear-gradient(180deg, #EACB63, #C9A227 55%, #B08718); }
.btn:not(.ghost):not(.danger):hover::after { transform: translateX(-120%); transition: transform .8s var(--ease); }
.btn:not(.ghost):not(.danger):active { transform: translateY(0); }
.btn.accent::after, .ticket .btn::after { animation: sweep 5.5s var(--ease) 1.2s infinite; }
.btn.ghost { transition: border-color .2s, background-color .2s, transform .2s var(--ease); }
.btn.ghost:hover { border-color: var(--accent); background: var(--gold-100); transform: translateY(-1px); }

/* shared "bullion" surface: espresso with a turning gold edge and light that follows the pointer */
.ticket, .acct-card { position: relative; overflow: hidden; isolation: isolate; color: #F3E3AE; border: 0; border-radius: 20px; background: radial-gradient(420px 200px at 90% -10%, rgba(255, 226, 130, .22), transparent 60%), linear-gradient(160deg, var(--espresso-2), var(--espresso)); box-shadow: 0 22px 50px rgba(60, 40, 5, .30); }
.ticket::before, .acct-card::before { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1.5px; z-index: 2; pointer-events: none; background: conic-gradient(from var(--ang), #8F6B14, #F6E7A6, #C9A227, #5E450A, #F6E7A6, #8F6B14); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); animation: spin-ang 8s linear infinite; }
.ticket::after, .acct-card::after { content: ""; display: block !important; position: absolute; inset: 0; z-index: 1; pointer-events: none; border: 0; border-radius: inherit; background: radial-gradient(260px circle at var(--mx, 85%) var(--my, 0%), rgba(255, 236, 160, .20), transparent 62%); }
.ticket > *, .acct-card > * { position: relative; z-index: 3; }
.ticket .sparkles, .acct-card .sparkles { z-index: 1; }

.ticket .unit, .ticket .meta, .ticket .pair .k { color: #BDA96B; opacity: 1; }
.ticket .base { background: var(--foil); background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; animation: foil-move 7s linear infinite; font-weight: 900; }
.ticket .base .unit { -webkit-text-fill-color: #BDA96B; }
.ticket .base .trend { -webkit-text-fill-color: currentColor; }
.ticket .trend.up { color: #5EE29A; } .ticket .trend.down { color: #FF8F86; }
.ticket .pair { background: transparent; gap: 10px; }
.ticket .pair > div { background: rgba(255, 255, 255, .05); border: 1px solid rgba(233, 212, 139, .18); border-radius: 12px; }
.ticket .pair > div:first-child .v { color: #6FE3A3; }
.ticket .pair > div:last-child .v { color: #FF9A91; }
.ticket .meta { display: flex; align-items: center; gap: 8px; }

/* sparkles (inserted by app.js) */
.sparkles { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.sparkles i { position: absolute; left: var(--x); top: var(--y); width: var(--s); height: var(--s); opacity: 0; background: radial-gradient(circle, #fff 0 18%, #F6E7A6 40%, #D9B54A 100%); clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%); animation: twinkle var(--d) ease-in-out var(--delay) infinite; }

/* hero: molten gold drifting behind the page */
.hero { position: relative; overflow: hidden; isolation: isolate; background: radial-gradient(1100px 460px at 88% -12%, #FFF3C4 0, transparent 60%), radial-gradient(800px 420px at 0% 110%, #F6E7A6 0, transparent 58%), var(--page); }
.molten { position: absolute; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.molten i { position: absolute; border-radius: 50%; filter: blur(38px); opacity: .5; background: radial-gradient(circle at 30% 30%, #FFF3C4, #E3C25A 45%, #B8901F 100%); animation: drift 18s ease-in-out infinite alternate; }
.molten i:nth-child(1) { width: 340px; height: 340px; right: -70px; top: -90px; }
.molten i:nth-child(2) { width: 260px; height: 260px; left: 6%; bottom: -100px; animation-duration: 23s; animation-delay: -6s; }
.molten i:nth-child(3) { width: 170px; height: 170px; right: 40%; top: 42%; opacity: .32; animation-duration: 27s; animation-delay: -12s; }
.hero h1 { background: var(--foil-dark); background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; animation: foil-move 9s linear infinite; padding-bottom: .1em; }

/* account card (dashboard) */
.acct-card { padding: 18px 18px 16px; margin-bottom: 18px; max-width: 780px; }
.acct-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.acct-k { font-size: 13px; color: #C9B374; font-weight: 700; }
.acct-v { font-size: clamp(1.9rem, 8vw, 2.7rem); font-weight: 900; line-height: 1.2; margin: 2px 0 14px; }
.acct-more { font: inherit; font-size: 12px; font-weight: 700; color: #F3E3AE; background: rgba(255, 255, 255, .06); border: 1px solid rgba(233, 212, 139, .3); border-radius: 999px; padding: 5px 14px; cursor: pointer; transition: background-color .2s, border-color .2s; }
.acct-more:hover { background: rgba(233, 212, 139, .16); border-color: #E9D48B; }
.acct-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.acct-row > div { display: grid; gap: 2px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(233, 212, 139, .18); border-radius: 12px; padding: 10px 12px; }
.acct-row span { font-size: 12px; color: #B9A66B; }
.acct-row b { font-size: var(--step-0); }
.acct-row b.credit { color: #6FE3A3; } .acct-row b.debit { color: #FF9A91; }

/* price board: staggered entrance, glints on change */
.js .board-row, .js .board-head, .js .board-keys, .js .board-notice { opacity: 0; transform: translateY(14px); transition: opacity .55s var(--ease), transform .55s var(--ease), border-color .2s, box-shadow .2s; transition-delay: calc(var(--i, 0) * 50ms); }
.js .board-row.in, .js .board-head.in, .js .board-keys.in, .js .board-notice.in { opacity: 1; transform: none; }
.board-row { transition: border-color .2s, box-shadow .2s; }
.board-row:hover { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(201, 162, 39, .14), 0 10px 24px rgba(143, 107, 20, .10); }
.board-title::before { background: var(--foil); background-size: 100% 250%; animation: bar 4s linear infinite; }
.board-row .cell { position: relative; overflow: hidden; }
.board-row .cell.glint::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 30%, rgba(255, 243, 196, .95) 50%, transparent 70%); animation: sweep .9s var(--ease) 1; }
.board-row .cell .tr.up, .board-row .cell .tr.down { animation: none; }

/* tab bar + dialog + toasts */
.tabbar a[aria-current="page"] { background: linear-gradient(180deg, var(--gold-100), #fff); box-shadow: inset 0 3px 0 var(--accent); }
.balance-dialog[open] { animation: pop .35s var(--ease); }
.balance-dialog::backdrop { background: rgba(26, 19, 6, .6); backdrop-filter: blur(3px); }
.balance-dialog[open] .bal-line { animation: pop .45s var(--ease) both; }
.balance-dialog[open] .bal-line:nth-child(2) { animation-delay: .07s; } .balance-dialog[open] .bal-line:nth-child(3) { animation-delay: .14s; } .balance-dialog[open] .bal-line:nth-child(4) { animation-delay: .21s; }
.toast { position: relative; overflow: hidden; background: linear-gradient(160deg, var(--espresso-2), var(--espresso)); color: #F3E3AE; border: 1px solid rgba(233, 212, 139, .3); border-inline-start-width: 5px; }
.toast span { color: #BDA96B; }
.toast::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 35%, rgba(255, 243, 196, .35) 50%, transparent 65%); animation: sweep 1.1s var(--ease) .15s 1 both; }
.side-nav a[aria-current="page"] { box-shadow: inset -3px 0 0 var(--accent), 0 0 0 1px var(--gold-300); }
@media (max-width: 480px) { .acct-card { border-radius: 18px; } .acct-row { gap: 8px; } }

/* brighter foil on the dark surfaces so the digits never go dull */
:root { --foil-bright: linear-gradient(105deg, #D4AF37 0%, #F6E7A6 22%, #FFF8DC 38%, #F0D77A 52%, #D4AF37 70%, #F6E7A6 86%, #D4AF37 100%); }
.ticket .base, .acct-card .foil { background-image: var(--foil-bright); }
.sparkles i { width: calc(var(--s) * 1.25); height: calc(var(--s) * 1.25); }
@media (max-width: 480px) { .acct-row b { font-size: 14px; } }


/* ── access levels ── */
.perm-group { border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px 14px; margin: 0; display: grid; gap: 8px; }
.perm-group legend { padding-inline: 8px; font-weight: 800; color: var(--gold-900); }
.perm { display: flex; gap: 10px; align-items: flex-start; padding: 8px 10px; border-radius: 10px; cursor: pointer; transition: background-color .15s; }
.perm:hover { background: var(--gold-100); }
.perm input { margin-top: 5px; accent-color: var(--primary); }
.perm span { display: grid; gap: 2px; }
.perm small { color: var(--muted); }
[hidden] { display: none !important; }
.perm-group { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); align-items: start; }
.perm span { display: flex; flex-direction: column; gap: 2px; line-height: 1.45; }
.perm small { font-size: 12px; }


/* ══ Simple panel (like the reference dashboard) ═══════════════
   Flat, quiet, no motion: a coloured header, the notice, the price
   rows with solid green/red boxes, and three flat tabs. */
.panel-simple, .panel-simple body { background: #fff; }
.panel-simple *, .panel-simple *::before, .panel-simple *::after { animation: none !important; transition: none !important; }
.panel-simple .sparkles, .panel-simple .molten { display: none !important; }
.panel-simple .main { background: #fff; }

.panel-simple .topbar { background: linear-gradient(180deg, #9A7418, #7C5C10); color: #fff; border-bottom: 0; padding-block: 12px; gap: 12px; }
.panel-simple .topbar .brand { display: none; }
.panel-simple .topbar .btn.ghost { background: transparent; border-color: rgba(255, 255, 255, .5); color: #fff; box-shadow: none; }
.panel-simple .topbar-user { color: #fff; font-size: var(--step-0); font-weight: 600; margin-inline-start: auto; }
.panel-simple .avatar { background: transparent; border: 2px solid rgba(255, 255, 255, .85); color: #fff; width: 38px; height: 38px; flex-basis: 38px; }

.crumbs { display: flex; align-items: center; gap: 12px; padding: 12px 0 14px; color: var(--muted); }
.crumbs b { font-size: var(--step-2); font-weight: 900; color: var(--ink); }
.crumbs .sep { width: 1px; height: 28px; background: var(--line); }
.crumbs .here { display: flex; align-items: center; gap: 6px; }
.crumbs h1 { margin: 0; font-size: var(--step-0); font-weight: 600; color: var(--muted); }

.panel-simple .board { max-width: none; }
.panel-simple .board-notice { background: #fff; border: 0; border-inline-start: 4px solid var(--accent); border-radius: 4px; box-shadow: var(--shadow); font-weight: 500; color: var(--ink); }
.panel-simple .board-keys { display: none; }
.panel-simple .board-head { margin: 18px 0 8px; }
.panel-simple .board-title { font-weight: 600; font-size: var(--step-0); }
.panel-simple .board-title::before { display: none; }
.panel-simple .board-updated { color: var(--ink); font-size: var(--step--1); }
.js .panel-simple .board-row, .js .panel-simple .board-head, .js .panel-simple .board-keys, .js .panel-simple .board-notice { opacity: 1; transform: none; }
.panel-simple .board-row { border: 0; border-radius: 6px; box-shadow: 0 1px 4px rgba(0, 0, 0, .25); padding: 4px; gap: 5px; }
.panel-simple .board-row:hover { box-shadow: 0 1px 4px rgba(0, 0, 0, .25); }
.panel-simple .board-row .lbl { font-size: var(--step-0); font-weight: 600; }
.panel-simple .board-row .cell { border-radius: 3px; border: 0; color: #fff; min-height: 58px; font-size: var(--step-2); font-weight: 600; }
.panel-simple .board-row .cell.sell { background: #2ECC40; color: #fff; }
.panel-simple .board-row .cell.buy { background: #E53935; color: #fff; }
.panel-simple .board-row .cell.none { background: #E53935; color: #fff; border: 0; }
.panel-simple .board-row .cell.sell.none { background: #2ECC40; }
.panel-simple .board-row .cell .tr, .panel-simple .board-row .cell .tr.up, .panel-simple .board-row .cell .tr.down, .panel-simple .board-row .cell .tr.flat { background: transparent; color: rgba(255, 255, 255, .95); padding: 0; font-size: 12px; font-weight: 600; }
.panel-simple .board-row .cell.none .tr { display: none; }
.panel-simple .board-row .cell.glint::after { display: none; }
@media (max-width: 480px) { .panel-simple .board-row .cell { font-size: 19px; } }

.quick-actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 22px 0 8px; }
.quick-actions .btn { flex: 1 1 180px; justify-content: center; }
.panel-simple .btn:not(.ghost):not(.danger) { background: var(--primary); color: #fff; box-shadow: none; border-radius: 6px; }
.panel-simple .btn:not(.ghost):not(.danger)::after { display: none; }
.panel-simple .btn:not(.ghost):not(.danger):hover { transform: none; background: #7C5C10; box-shadow: none; }

/* three flat tabs, like the reference */
@media (max-width: 960px) {
  .panel-simple .tabbar { box-shadow: none; border-top: 0; padding-bottom: env(safe-area-inset-bottom, 0px); background: #7C5C10; }
  .panel-simple .tabbar a, .panel-simple .tabbar button { flex-direction: row; justify-content: center; border: 0; border-top: 0; border-radius: 0; padding: 14px 6px; font-size: var(--step-0); font-weight: 600; color: #fff; }
  .panel-simple .tabbar svg { display: none; }
  .panel-simple .tabbar a:nth-child(1) { background: #C9A227; color: #2A1D04; }
  .panel-simple .tabbar a:nth-child(2) { background: #7C5C10; }
  .panel-simple .tabbar button { background: #A47E15; }
  .panel-simple .tabbar a[aria-current="page"] { box-shadow: none; }
}

/* other customer pages in the simple style: flat white cards, no dark bullion surface */
.panel-simple .ticket { background: #fff; color: var(--ink); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: 8px; }
.panel-simple .ticket::before, .panel-simple .ticket::after { display: none !important; }
.panel-simple .ticket .base, .panel-simple .ticket .base .unit { background: none; -webkit-text-fill-color: currentColor; color: var(--ink); }
.panel-simple .ticket .unit, .panel-simple .ticket .meta, .panel-simple .ticket .pair .k { color: var(--muted); }
.panel-simple .ticket .pair > div { background: #fff; border: 1px solid var(--line); border-radius: 6px; }
.panel-simple .ticket .pair > div:first-child .v { color: #1E8E3E; }
.panel-simple .ticket .pair > div:last-child .v { color: #C62828; }
.panel-simple .foil, .panel-simple .acct-card { background: none; -webkit-text-fill-color: currentColor; }
.panel-simple { min-height: 100vh; }
.panel-simple .board-row .cell { letter-spacing: 0; font-weight: 500; }
@media (max-width: 480px) {
  .panel-simple .board-row, .panel-simple .board-keys { grid-template-columns: minmax(0, .8fr) minmax(0, 1.1fr) minmax(0, 1.1fr); }
  .panel-simple .board-row .cell { font-size: 15.5px; padding-inline: 2px; }
  .panel-simple .board-row .lbl { font-size: 14px; padding-inline: 4px; }
}
