/* Shared UI components for the merchant dashboard and the player site. */
:root {
  --bg: #f5f6fa;
  --surface: #ffffff;
  --surface-2: #f0f2f7;
  --border: #e2e5ee;
  --text: #1b1f2a;
  --muted: #687087;
  --brand: #5b4cf0;
  --brand-ink: #ffffff;
  --ok: #138a52;
  --ok-bg: #e3f6ec;
  --warn: #9a6200;
  --warn-bg: #fff3d6;
  --bad: #c42b3c;
  --bad-bg: #fde7ea;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.06), 0 4px 16px rgba(16, 24, 40, 0.06);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1117; --surface: #171a23; --surface-2: #1e2230; --border: #2a2f40; --text: #e8eaf2; --muted: #8b93a9;
    --brand: #8577ff; --ok: #3ecf8e; --ok-bg: #12301f; --warn: #f0b44c; --warn-bg: #352812; --bad: #ff6b7b; --bad-bg: #3a1820;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1117; --surface: #171a23; --surface-2: #1e2230; --border: #2a2f40; --text: #e8eaf2; --muted: #8b93a9;
  --brand: #8577ff; --ok: #3ecf8e; --ok-bg: #12301f; --warn: #f0b44c; --warn-bg: #352812; --bad: #ff6b7b; --bad-bg: #3a1820;
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body { font: 14px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; background: var(--bg); color: var(--text); }
a { color: var(--brand); }
.tick, .cross { display: inline-flex; align-items: center; justify-content: center; width: 1.25em; height: 1.25em; border-radius: 50%; font-size: 0.8em; font-weight: 800; line-height: 1; flex: none; }
.tick { color: var(--ok); background: var(--ok-bg); }
.cross { color: var(--bad); background: var(--bad-bg); }

/* scrollbars: thin and themed everywhere */
* { scrollbar-width: thin; scrollbar-color: color-mix(in srgb, var(--muted) 40%, transparent) transparent; }
*:hover { scrollbar-color: color-mix(in srgb, var(--muted) 65%, transparent) transparent; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 12px; }
h1 { font-size: 1.6rem; } h2 { font-size: 1.25rem; } h3 { font-size: 1.05rem; }
.muted { color: var(--muted); }
.mono { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.right { text-align: right; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }
.grid-2 { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); align-items: start; }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card + .card, .card + .grid-2, .grid-2 + .card, .grid-2 + .grid-2 { margin-top: 16px; }
.stats > .card, .grid-2 > .card, .games > * { margin-top: 0; }
td.date { white-space: nowrap; }
.card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2, .card-head h3 { margin: 0; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 14px; border-radius: 9px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font: inherit; font-weight: 600; cursor: pointer; text-decoration: none;
  white-space: nowrap;
}
.btn:hover:not(:disabled) { background: var(--surface-2); }
.btn:disabled { opacity: 0.5; cursor: default; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.btn.primary:hover:not(:disabled) { filter: brightness(1.08); background: var(--brand); }
.btn.ok { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 40%, var(--border)); }
.btn.bad { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 40%, var(--border)); }
.btn.sm { padding: 4px 10px; font-size: 0.85rem; }
.btn.block { width: 100%; }
.link { background: none; border: none; color: var(--brand); cursor: pointer; font: inherit; padding: 0; }

/* forms */
.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 14px; }
.field label { font-weight: 600; font-size: 0.85rem; }
.field .hint { font-size: 0.8rem; color: var(--muted); }
input, select, textarea {
  font: inherit; color: var(--text); background: var(--surface); width: 100%;
  border: 1px solid var(--border); border-radius: 9px; padding: 9px 11px;
}
input:focus, select:focus, textarea:focus { outline: 2px solid color-mix(in srgb, var(--brand) 50%, transparent); border-color: var(--brand); }
input[type="checkbox"] { width: auto; }
input[type="color"] { padding: 2px; height: 38px; }
.check { display: flex; gap: 8px; align-items: center; font-weight: 500; margin-bottom: 14px; }
.form-grid { display: grid; gap: 0 14px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.error-text { color: var(--bad); font-size: 0.85rem; min-height: 1.2em; }

/* tables */
.table-wrap { overflow-x: auto; margin: 0 -20px; padding: 0 20px; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 10px 10px; text-align: left; border-bottom: 1px solid var(--border); vertical-align: middle; }
th { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); font-weight: 700; }
tr:last-child td { border-bottom: none; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pos { color: var(--ok); } .neg { color: var(--bad); }
.empty { text-align: center; color: var(--muted); padding: 30px; }

.badge { display: inline-block; padding: 2px 9px; border-radius: 99px; font-size: 0.75rem; font-weight: 700; text-transform: capitalize; background: var(--surface-2); color: var(--muted); }
.badge.pending { background: var(--warn-bg); color: var(--warn); }
.badge.approved, .badge.active, .badge.on { background: var(--ok-bg); color: var(--ok); }
.badge.rejected, .badge.suspended, .badge.off { background: var(--bad-bg); color: var(--bad); }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 16px; overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.tabs a, .tabs button { padding: 9px 14px; border: none; background: none; color: var(--muted); font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs .active { color: var(--brand); border-bottom-color: var(--brand); }

.pager { display: flex; gap: 8px; align-items: center; justify-content: flex-end; margin-top: 12px; }

/* modal */
dialog.modal { border: none; border-radius: 16px; padding: 0; width: min(480px, calc(100vw - 32px)); background: var(--surface); color: var(--text); box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35); }
dialog.modal.wide { width: min(820px, calc(100vw - 32px)); }
dialog.modal::backdrop { background: rgba(10, 12, 20, 0.55); }
.modal-head { display: flex; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.modal-head h3 { margin: 0; flex: 1; }
.modal-body { padding: 20px; max-height: 70vh; overflow: auto; }
.modal-foot { display: flex; gap: 8px; justify-content: flex-end; padding: 14px 20px; border-top: 1px solid var(--border); }

/* toasts */
.toasts { position: fixed; right: 16px; bottom: 16px; display: flex; flex-direction: column; gap: 8px; z-index: 1000; max-width: calc(100vw - 32px); }
.toast { padding: 12px 16px; border-radius: 10px; background: var(--text); color: var(--bg); box-shadow: var(--shadow); font-weight: 600; transition: opacity 0.4s, transform 0.4s; }
.toast.error { background: var(--bad); color: #fff; }
.toast.success { background: var(--ok); color: #fff; }
.toast.out { opacity: 0; transform: translateY(8px); }

.stat { display: flex; flex-direction: column; gap: 4px; }
.stat .label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 700; }
.stat .value { font-size: 1.6rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.stats { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); margin-bottom: 16px; }

.copy { font-family: ui-monospace, Consolas, monospace; background: var(--surface-2); padding: 2px 8px; border-radius: 6px; cursor: pointer; border: 1px dashed var(--border); }
.copy:hover { border-color: var(--brand); }

/* data tables */
.dt-bar { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; margin-bottom: 12px; }
.dt-bar .filters { display: flex; gap: 8px; flex-wrap: wrap; margin: 0; }
.dt-bar .filters input, .dt-bar .filters select { width: auto; min-width: 150px; padding: 7px 10px; }
.dt-bar .filters input[type="search"] { min-width: 210px; }
.date-f { display: flex; align-items: center; gap: 6px; font-size: 0.8rem; color: var(--muted); }
.date-f input { min-width: 0 !important; }
.dt-body { transition: opacity 0.15s; min-height: 60px; }
.dt-body.loading { opacity: 0.5; }
.dt-size { display: flex; align-items: center; gap: 6px; font-size: 0.85rem; }
.dt-size select { width: auto; padding: 4px 8px; }
.card-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.chips { display: flex; gap: 4px; flex-wrap: wrap; }
.chip { display: inline-block; padding: 1px 8px; border-radius: 99px; font-size: 0.75rem; font-weight: 700; background: var(--surface-2); border: 1px solid var(--border); white-space: nowrap; }
.chip.on { background: color-mix(in srgb, var(--brand) 15%, transparent); border-color: color-mix(in srgb, var(--brand) 40%, transparent); color: var(--brand); }
.swatch { display: inline-block; width: 14px; height: 14px; border-radius: 4px; vertical-align: middle; border: 1px solid var(--border); }
.perm-group { border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; }
.perm-group h4 { margin: 0 0 6px; font-size: 0.85rem; display: flex; align-items: center; gap: 8px; }
.perm-group .check { margin-bottom: 4px; font-size: 0.9rem; }

/* Translation editor */
.tr-en { max-width: 46ch; white-space: pre-wrap; }
.tr-base { max-width: 40ch; color: var(--muted); white-space: pre-wrap; }
.tr-input { width: 100%; min-width: 260px; resize: vertical; font: inherit; }
.tr-state { display: block; font-size: 0.78rem; min-height: 1em; }
.lang-select { width: auto; padding: 4px 8px; font: inherit; font-size: 0.85rem; }
.lang-select.block { width: 100%; margin-bottom: 6px; }
.check input[type=radio], .check input[type=checkbox] { width: auto; flex: 0 0 auto; margin: 0; }

/* Per-item translations (game / category / brand / role names) */
.item-i18n { border: 1px solid var(--border); border-radius: 10px; padding: 8px 12px; margin: 4px 0 14px; }
.item-i18n summary { cursor: pointer; font-weight: 700; }
.item-i18n-grid { display: grid; gap: 6px 10px; align-items: center; margin-top: 6px; }
.item-i18n-grid input { width: 100%; }
.item-i18n-lang { font-size: 0.9rem; }
@media (max-width: 640px) { .item-i18n-grid { grid-template-columns: 1fr !important; } }

/* ---------- admin: landing page builder ---------- */
.lp-list { list-style: none; padding: 0; margin: 12px 0 0; display: flex; flex-direction: column; gap: 8px; }
.lp-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); }
.lp-row.static { padding: 0; border: 0; background: none; }
.lp-row.off { opacity: 0.6; }
.lp-row.dragging { opacity: 0.4; }
.lp-row.drop-before { box-shadow: 0 -3px 0 var(--brand); }
.lp-row.drop-after { box-shadow: 0 3px 0 var(--brand); }
.lp-grip { cursor: grab; color: var(--muted); font-weight: 900; letter-spacing: -2px; user-select: none; }
.lp-icon { font-size: 1.4rem; width: 32px; text-align: center; flex: 0 0 auto; }
.lp-main { flex: 1; min-width: 0; }
.lp-main > .muted { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: inline-block; max-width: 100%; vertical-align: bottom; }
.lp-meta { font-size: 0.82rem; color: var(--muted); margin-top: 2px; }
.lp-actions { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.lp-on { margin: 0 6px 0 0; font-size: 0.85rem; }
.lp-tr { color: var(--muted); }
.lp-tr.ok { color: var(--ok, #22c55e); }
.lp-page-card { padding: 12px 14px; }
.lp-types { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.lp-type { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; padding: 14px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2, var(--surface)); color: inherit; font: inherit; text-align: left; cursor: pointer; }
.lp-type:hover { border-color: var(--brand); }
.lp-type .muted { font-size: 0.85rem; }
dialog.modal.lp-modal { width: min(1000px, calc(100vw - 32px)); }
dialog.modal.lp-modal .modal-body { max-height: 72vh; }
.lp-tabs { margin: 0; padding: 0 20px; }
.lp-tokens code, .lp-secbits code { font-size: 0.8rem; }
.lp-secbits { margin-bottom: 4px; }
.lp-listfield { margin: 6px 0 16px; padding: 12px; border-radius: 12px; border: 1px dashed var(--border); }
.lp-listhead { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
.lp-item { border: 1px solid var(--border); border-radius: 10px; margin-bottom: 8px; background: var(--surface); }
.lp-item > summary { display: flex; align-items: center; gap: 6px; padding: 8px 10px; cursor: pointer; list-style: none; }
.lp-item > summary::-webkit-details-marker { display: none; }
.lp-item[open] > summary { border-bottom: 1px solid var(--border); }
.lp-item-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.lp-num { display: inline-grid; place-items: center; min-width: 22px; height: 22px; border-radius: 99px; background: var(--surface-2, var(--border)); font-size: 0.75rem; font-weight: 800; }
.lp-item-body { padding: 12px; }
.btn.xs { padding: 2px 7px; font-size: 0.78rem; }
.lp-none { margin: 0; }
.lp-image { display: flex; gap: 12px; align-items: flex-start; }
.lp-image img, .lp-noimg { width: 120px; height: 68px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border); background: #000; flex: 0 0 auto; }
.lp-noimg { display: grid; place-items: center; font-size: 0.8rem; color: var(--muted); background: var(--surface-2, transparent); }
.lp-image-ctl { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.lp-icon-field input { max-width: 120px; }
.lp-labels { margin-top: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--border); }
.lp-labels > summary { cursor: pointer; margin-bottom: 8px; }
.lp-trbar { gap: 12px; margin-bottom: 6px; }
.lp-trbar select { width: auto; max-width: 100%; }
.lp-trlist { display: flex; flex-direction: column; gap: 10px; }
.lp-tr-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; align-items: start; padding-bottom: 10px; border-bottom: 1px solid var(--border); }
.lp-tr-en { display: flex; flex-direction: column; gap: 2px; }
.lp-tr-label { font-size: 0.75rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.lp-tr-text { white-space: pre-wrap; }
dialog.modal.lp-preview-modal { width: calc(100vw - 32px); max-width: 1400px; }
.lp-preview { display: block; width: 100%; height: 78vh; border: 0; background: #000; border-radius: 0 0 16px 16px; }
@media (max-width: 700px) {
  .lp-row { flex-wrap: wrap; }
  .lp-actions { width: 100%; justify-content: flex-start; }
  .lp-tr-row { grid-template-columns: 1fr; }
  .lp-image { flex-direction: column; }
}
.lp-colours { display: grid; gap: 0 16px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.lp-color { display: flex; gap: 8px; align-items: center; }
.lp-color input[type=color] { width: 44px; height: 38px; padding: 2px; flex: 0 0 auto; cursor: pointer; border-radius: 8px; }
.lp-color input[type=color].unset { opacity: 0.35; }
.lp-color input[data-p] { font-family: ui-monospace, monospace; min-width: 0; }
.lp-presets { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 0 0 12px; }
.lp-preset { display: inline-flex; align-items: center; gap: 6px; }
.lp-swatch { width: 14px; height: 14px; border-radius: 50%; background: var(--sw); box-shadow: 0 0 0 3px var(--sb), 0 0 0 4px var(--border); }

/* ---------- merchant: jackpot ---------- */
.jp-live { display: flex; flex-wrap: wrap; gap: 20px; align-items: center; background: linear-gradient(120deg, color-mix(in srgb, #f5b301 18%, var(--surface)), var(--surface) 60%); }
.jp-live-main { flex: 1 1 320px; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.jp-pool .jp-live { margin: -4px 0 14px; padding: 14px; border-radius: 12px; }
.jp-live-name { font-weight: 900; letter-spacing: 0.08em; text-transform: uppercase; }
.jp-warn { color: #e0a100; font-size: 0.85rem; }
.jp-live-amount { font-size: clamp(2rem, 5vw, 3rem); font-weight: 900; font-variant-numeric: tabular-nums; color: #f5b301; }
.jp-live-stats { flex: 1 1 320px; display: grid; gap: 10px; }
.jp-live-stats > div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); }
.banner-prev { display: grid; place-items: center; height: 90px; margin-bottom: 8px; border-radius: 10px; border: 1px dashed var(--border); background: center / cover no-repeat var(--surface-2); }

/* game editor: layout artwork */
.deco-slots { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.deco-slot { display: flex; gap: 12px; padding: 12px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2); }
.deco-prev { width: 96px; height: 96px; flex: none; display: grid; place-items: center; border-radius: 10px; background: repeating-conic-gradient(rgba(127, 127, 127, 0.18) 0 25%, transparent 0 50%) 0 0 / 16px 16px; overflow: hidden; font-size: 0.75rem; }
.deco-prev { position: relative; }
.deco-prev img { width: 100%; height: 100%; object-fit: contain; }
.deco-slot.off .deco-prev { opacity: 0.35; filter: grayscale(1); }
.deco-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.deco-head .piece-on { margin: 0; font-size: 0.85rem; }
.screen-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(400px, 44%); gap: 16px; align-items: start; }
.screen-layout .deco-slots { grid-template-columns: 1fr; }
.screen-preview { position: sticky; top: 72px; padding: 12px; }
@media (max-width: 1180px) { .screen-layout { grid-template-columns: 1fr; } .screen-preview { position: static; } .preview-slot { order: -1; } .screen-layout .deco-slots { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); } }
.preview-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.preview-stage { position: relative; overflow: hidden; border-radius: 10px; background: #000; }
.preview-stage.phone { display: flex; justify-content: center; background: repeating-conic-gradient(rgba(127, 127, 127, 0.12) 0 25%, transparent 0 50%) 0 0 / 16px 16px; }
.preview-stage iframe { display: block; border: 0; transform-origin: 0 0; }
.preview-stage.phone iframe { transform-origin: 50% 0; flex: none; border-radius: 18px; }
.preview-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
details.screen-group { margin: 10px 0; border: 1px solid var(--border); border-radius: 12px; padding: 0 12px; }
details.screen-group > summary { cursor: pointer; padding: 12px 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; font-weight: 700; }
details.screen-group > summary .muted { font-weight: 400; font-size: 0.8rem; flex-basis: 100%; }
details.screen-group[open] > summary { border-bottom: 1px solid var(--border); margin-bottom: 12px; }
details.screen-group .deco-slots { padding-bottom: 12px; }
.adjust { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px 12px; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); align-items: end; }
.adjust label { display: flex; flex-direction: column; gap: 4px; font-size: 0.78rem; font-weight: 600; }
.adjust label output { font-weight: 400; color: var(--muted); }
.adjust input[type=range] { width: 100%; padding: 0; }
.adjust .btn { justify-self: start; }
.style-picks { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 8px; }
.style-pick { width: 44px; height: 44px; padding: 3px; border-radius: 8px; border: 2px solid var(--border); background: repeating-conic-gradient(rgba(127, 127, 127, 0.18) 0 25%, transparent 0 50%) 0 0 / 10px 10px; cursor: pointer; }
.style-pick img { width: 100%; height: 100%; object-fit: contain; display: block; }
.style-pick.on { border-color: var(--brand); box-shadow: 0 0 0 2px color-mix(in srgb, var(--brand) 30%, transparent); }
.wide .deco-prev img, .wide .style-pick img { width: 100%; height: 60%; object-fit: fill; }
.style-pick:disabled { cursor: default; }
.deco-tag { position: absolute; left: 4px; bottom: 4px; padding: 1px 6px; border-radius: 6px; font-size: 0.65rem; font-weight: 700; background: rgba(0, 0, 0, 0.65); color: #fff; }
.deco-info { min-width: 0; }
.deco-info p { margin: 4px 0 8px; font-size: 0.82rem; }

/* game editor: win messages */
.msg-style-grid { border-top: 0; margin-top: 0; padding-top: 4px; padding-bottom: 12px; }
.msg-colour { display: flex; align-items: center; gap: 8px; }
.msg-colour input[type=color] { width: 44px; height: 32px; padding: 2px; }
.msg-colour .check { margin: 0; font-weight: 500; font-size: 0.78rem; }
.msg-fields { border-top: 0; padding-top: 0; }
.msg-prev { background: #111; }
.msg-sample { padding: 4px; font-weight: 900; font-size: 0.78rem; line-height: 1.1; text-align: center; color: #ffd23f; word-break: break-word; }
.preview-slot { min-width: 0; align-self: stretch; } /* full column height, so the preview inside can stay in view */
.tb-fields { border-top: 0; padding-top: 0; }
.adjust .tb-check { flex-direction: row; align-items: center; margin: 0; align-self: end; padding-bottom: 8px; font-size: 0.85rem; }

/* platform logo on the admin / merchant sign-in screens */
.login-logo { display: block; width: 200px; max-width: 70%; height: auto; margin: 0 auto 14px; filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.35)); }

/* Admin and merchant sign-in screens in the platform's own colours — black and gold, like the logo and the landing
   page — whatever the dashboard's accent colour or light / dark mode. */
#login.login-screen {
  color-scheme: dark;
  --brand: #d4af37; --bg: #0a0907; --surface: #15120c; --surface-2: #1d1911; --border: rgba(212, 175, 55, 0.28); --text: #f3ead2; --muted: #a89f86;
  background: radial-gradient(900px 520px at 85% -120px, rgba(212, 175, 55, 0.22), transparent),
    radial-gradient(700px 420px at -5% 25%, rgba(156, 116, 25, 0.16), transparent), #0a0907;
  color: var(--text);
}
#login .login-card { background: rgba(21, 18, 12, 0.92); border-color: rgba(212, 175, 55, 0.35); box-shadow: 0 24px 70px rgba(0, 0, 0, 0.65), 0 0 40px rgba(212, 175, 55, 0.08); color: var(--text); }
#login .login-card h1 { color: #f6dc83; }
#login input, #login select, #login textarea { background: #0f0d09; color: var(--text); border-color: rgba(212, 175, 55, 0.25); }
#login input:focus, #login select:focus, #login textarea:focus { border-color: #d4af37; outline: none; box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.22); }
#login .btn.primary { background: linear-gradient(135deg, #f6dc83, #d4af37 55%, #9c7419); color: #0a0907; border: 0; font-weight: 800; }
#login .btn.primary:hover { filter: brightness(1.08); }
#login .tabs { border-color: rgba(212, 175, 55, 0.2); }
#login .tabs .active { color: #f6dc83; border-bottom-color: #d4af37; }
#login a { color: #e8c55a; }
#login a:hover { color: #f6dc83; }
