/* Laxis Apps: one stylesheet for the landing, signup and every store's app.
   Layout: single column, phone first; content max 34rem, centered on bigger screens.
   Store pages set --brand/--accent (and their ink colors) inline from the tenant's colors.
   System fonts only: fast on budget phones, no data cost, works offline. */

:root {
  color-scheme: light;
  --brand: #17324D;
  --brand-ink: #FFFFFF;
  --accent: #F2B134;
  --accent-ink: #14181F;

  --bg: #F6F5F1;
  --surface: #FFFFFF;
  --ink: #1B1F24;
  --ink-2: #5A6370;
  --line: #E3E1DA;
  --danger: #B42318;
  --danger-bg: #FDECEA;
  --ok: #157347;
  --ok-bg: #E7F5EE;
  --warn-bg: #FFF6DB;

  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --r: 14px;
  --r-sm: 10px;
  --tap: 48px;
}

/* Dark mode (store apps): Settings → Display → Auto / Light / Dark. dash.js sets data-theme on <html> and the
   brand-derived colors (--brand-text, --chart-*). Neutral near-black grays (no store tint), so it reads calm and
   professional. Light is the default (dash.js loadTheme); dark only applies once JS sets data-theme. Keep these
   numbers in step with brandTokens() in dash.js (its dark surface is #141416). */
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0B0B0C;
  --surface: #141416;
  --surface-2: #1C1C1F;
  --ink: #F4F4F5;
  --ink-2: #A1A1AA;
  --line: #27272A;
  --danger: #FF8E84;
  --danger-bg: #3B1E1C;
  --ok: #6FDDA2;
  --ok-bg: #12301F;
  --warn-bg: #2E2715;
}
:root[data-theme="dark"] .appbar, :root[data-theme="dark"] body.tenant::before { background: var(--bg); color: var(--ink); border-bottom: 1px solid var(--line); }
:root[data-theme="dark"] .appbar .btn, :root[data-theme="dark"] .appbar-back, :root[data-theme="dark"] .appbar-bell { color: var(--ink); border-color: var(--line); }
:root[data-theme="dark"] a:not(.btn):not(.pill-btn), :root[data-theme="dark"] .link { color: var(--brand-text, var(--ink)); }
:root[data-theme="dark"] .banner { background: var(--warn-bg); border-color: color-mix(in srgb, #F3E2A9 30%, transparent); color: var(--ink); }
:root[data-theme="dark"] .banner.install, :root[data-theme="dark"] .banner.trial, :root[data-theme="dark"] .banner.renew { background: var(--surface-2); border-color: var(--line); }
:root[data-theme="dark"] .toast { background: var(--ink); color: var(--bg); }

/* ---------- Wallpaper + Glass (wallpaper.js; Settings → Display → Background) ---------- */
#lx-wall { position: fixed; inset: 0; z-index: -1; background-size: cover; background-position: center; pointer-events: none; }
/* A soft veil so text that sits right on the wallpaper (headings, hints) stays readable. */
#lx-wall::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(255,255,255,.28), rgba(255,255,255,.12) 40%, rgba(255,255,255,.22)); }
:root[data-theme="dark"] #lx-wall::after { background: linear-gradient(180deg, rgba(0,0,0,.55), rgba(0,0,0,.35) 40%, rgba(0,0,0,.5)); }
/* A dark scene (night, space, deep sea) under the LIGHT theme: a stronger light veil so dark text stays readable. */
:root.lx-wall[data-wall-tone="dark"]:not([data-theme="dark"]) #lx-wall::after { background: linear-gradient(180deg, rgba(255,255,255,.62), rgba(255,255,255,.45) 40%, rgba(255,255,255,.58)); }
:root.lx-wall body.tenant { background: transparent; }
/* Buttons with no fill would vanish into the picture: give them a frosted surface. */
:root.lx-wall .btn-ghost { background: var(--surface); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
:root.lx-wall .appbar { background: color-mix(in srgb, var(--brand) 82%, transparent); -webkit-backdrop-filter: blur(16px) saturate(1.3); backdrop-filter: blur(16px) saturate(1.3); }
:root.lx-wall[data-theme="dark"] .appbar { background: rgba(8,10,10,.62); }
/* Glass: see-through cards that blur the scene behind them. */
:root.lx-glass {
  --surface: rgba(255,255,255,.68);
  --surface-2: rgba(255,255,255,.5);
  --line: rgba(255,255,255,.65);
}
:root.lx-glass[data-theme="dark"] {
  --surface: rgba(14,18,17,.6);
  --surface-2: rgba(28,33,32,.62);
  --line: rgba(255,255,255,.12);
}
:root.lx-glass .card, :root.lx-glass .kpi, :root.lx-glass .tile, :root.lx-glass .d-card, :root.lx-glass .d-stat, :root.lx-glass .d-tile,
:root.lx-glass .banner, :root.lx-glass .side-nav, :root.lx-glass .sheet, :root.lx-glass .d-banner {
  -webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4);
  box-shadow: 0 8px 30px -12px rgba(0,0,0,.25), inset 0 1px 0 rgba(255,255,255,.35);
}
:root.lx-glass[data-theme="dark"] .card, :root.lx-glass[data-theme="dark"] .kpi, :root.lx-glass[data-theme="dark"] .d-card, :root.lx-glass[data-theme="dark"] .d-stat { box-shadow: 0 8px 30px -12px rgba(0,0,0,.6), inset 0 1px 0 rgba(255,255,255,.06); }
:root.lx-glass .banner { background: rgba(255,246,219,.78); }
:root.lx-glass[data-theme="dark"] .banner { background: rgba(58,47,18,.62); }
/* Headings that sit directly on the wallpaper get a faint shadow for contrast. */
:root.lx-wall .screen > h1, :root.lx-wall .screen > h2, :root.lx-wall .dash-top h1, :root.lx-wall .powered { text-shadow: 0 1px 12px rgba(255,255,255,.7); }
:root.lx-wall[data-theme="dark"] .screen > h1, :root.lx-wall[data-theme="dark"] .screen > h2, :root.lx-wall[data-theme="dark"] .dash-top h1, :root.lx-wall[data-theme="dark"] .powered { text-shadow: 0 1px 12px rgba(0,0,0,.8); }
/* Settings → Background picker */
.wall-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: .6rem; }
.wall-opt { display: grid; gap: .3rem; padding: 0; border: 0; background: none; color: var(--ink); font: inherit; font-size: .78rem; font-weight: 600; text-align: center; cursor: pointer; }
.wall-thumb { aspect-ratio: 3 / 4; border-radius: 12px; background-size: cover; background-position: center; border: 2px solid var(--line); display: grid; place-items: center; color: var(--ink-2); font-size: 1.2rem; background-color: var(--bg); }
.wall-opt[aria-checked="true"] .wall-thumb { border-color: var(--accent-ui, var(--brand)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-ui, var(--brand)) 30%, transparent); }
.wall-style[hidden] { display: none; }
:root[data-theme="dark"] .chip-btn.on, :root[data-theme="dark"] .tabs button.on, :root[data-theme="dark"] .tabs a.on,
:root[data-theme="dark"] .btn-primary { background: var(--accent-ui, var(--accent)); color: var(--accent-ui-ink, var(--accent-ink)); border-color: var(--accent-ui, var(--accent)); }

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.45;
  background: var(--bg);
  color: var(--ink);
  -webkit-tap-highlight-color: transparent;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
img { max-width: 100%; display: block; }
h1, h2, h3 { line-height: 1.2; text-wrap: balance; margin: 0; }
p { margin: 0; }
a { color: var(--brand); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }
.num { font-variant-numeric: tabular-nums; }

/* ---------- Buttons and fields ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: var(--tap); padding: 0 1.1rem;
  border: 1.5px solid var(--line); border-radius: var(--r-sm);
  background: var(--surface); color: var(--ink);
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
}
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.btn-accent { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-ghost { background: transparent; }
.btn-danger { color: var(--danger); border-color: #F1C5C0; }
.btn-block { width: 100%; }
.btn-sm { min-height: 38px; padding: 0 .8rem; font-size: .92rem; }
.link { background: none; border: 0; padding: .25rem 0; color: var(--brand); font: inherit; font-weight: 600; text-decoration: underline; cursor: pointer; }

.field { display: grid; gap: .4rem; margin: 0; border: 0; padding: 0; min-width: 0; }
.field > label, .field > legend, .label { font-weight: 600; font-size: .95rem; padding: 0; }
.optional { font-weight: 400; color: var(--ink-2); }
.field-pair { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
input, select, textarea {
  width: 100%; min-height: var(--tap); padding: .6rem .8rem;
  border: 1.5px solid var(--line); border-radius: var(--r-sm);
  background: var(--surface); color: var(--ink); font: inherit;
}
input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 18%, transparent); }
input[aria-invalid="true"] { border-color: var(--danger); }
.hint { font-size: .88rem; color: var(--ink-2); }
.hint.ok { color: var(--ok); }
.hint.bad { color: var(--danger); }
.form-error { background: var(--danger-bg); color: var(--danger); padding: .75rem .9rem; border-radius: var(--r-sm); font-weight: 600; }
.fine { font-size: .82rem; color: var(--ink-2); text-align: center; }

.slug-row, .phone-row { display: flex; align-items: stretch; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); overflow: hidden; min-width: 0; }
.slug-row:focus-within, .phone-row:focus-within { border-color: var(--brand); }
.slug-row input, .phone-row input { border: 0; border-radius: 0; min-width: 0; flex: 1; box-shadow: none !important; }
.slug-prefix, .phone-prefix { display: flex; align-items: center; padding: 0 .1rem 0 .8rem; color: var(--ink-2); white-space: nowrap; font-size: .92rem; max-width: 55%; overflow: hidden; text-overflow: ellipsis; }
.phone-prefix { padding-right: .4rem; font-weight: 600; color: var(--ink); }
.slug-row .btn { border: 0; border-radius: 0; border-left: 1.5px solid var(--line); }

/* ---------- Landing (Laxis brand) ---------- */
.landing, .signup, .error-page { max-width: 34rem; margin: 0 auto; padding: 1.25rem max(16px, env(safe-area-inset-right, 0px)) 2.5rem max(16px, env(safe-area-inset-left, 0px)); display: grid; gap: 1.75rem; }
.wordmark { font-weight: 800; font-size: 1.15rem; letter-spacing: -.01em; color: var(--brand); }
.wordmark span { color: var(--ink-2); font-weight: 600; margin-left: .3rem; }
.landing-hero h1 { font-size: clamp(2rem, 8vw, 2.6rem); letter-spacing: -.02em; }
.landing-hero p { margin-top: .6rem; color: var(--ink-2); font-size: 1.05rem; max-width: 30rem; }
.type-list { display: grid; gap: .75rem; }
.type-card {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 1rem;
  padding: 1rem; border-radius: var(--r); background: var(--surface); border: 1.5px solid var(--line);
  color: var(--ink); text-decoration: none;
}
.type-card:hover { border-color: var(--brand); }
.type-icon { width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 30%, #fff); color: var(--brand); }
.type-icon svg { width: 30px; height: 30px; }
.type-text { display: grid; gap: .15rem; min-width: 0; }
.type-text strong { font-size: 1.15rem; }
.type-text span { color: var(--ink-2); font-size: .92rem; }
.type-go { font-size: 1.8rem; color: var(--ink-2); line-height: 1; }
.landing-how h2 { font-size: 1.05rem; margin-bottom: .6rem; }
.landing-how ol { margin: 0; padding-left: 1.25rem; display: grid; gap: .4rem; color: var(--ink-2); }
.landing-how strong { color: var(--ink); }
.landing-open { display: grid; gap: .5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
.landing-open label { font-weight: 600; font-size: .95rem; }

/* "What you get" and FAQ */
.landing-what { display: grid; gap: .9rem; padding: 1.1rem; border-radius: var(--r); background: var(--surface); border: 1.5px solid var(--line); }
.landing-what h2, .landing-faq h2 { font-size: 1.2rem; letter-spacing: -.01em; }
.hl-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .85rem; }
.hl { display: grid; grid-template-columns: 2.4rem 1fr; gap: .7rem; align-items: start; }
.hl-icon { width: 2.4rem; height: 2.4rem; border-radius: 10px; display: grid; place-items: center; font-size: 1.25rem; background: color-mix(in srgb, var(--accent) 25%, #fff); }
.hl strong { display: block; font-size: 1rem; }
.hl-text { display: block; color: var(--ink-2); font-size: .92rem; margin-top: .1rem; }
.hl-list.compact { gap: .5rem; }
.hl-list.compact .hl { grid-template-columns: 1.9rem 1fr; align-items: center; }
.hl-list.compact .hl-icon { width: 1.9rem; height: 1.9rem; font-size: 1rem; border-radius: 8px; }
.hl-list.compact strong { font-weight: 600; font-size: .95rem; }
.hl-note { font-size: .82rem; }
.landing-faq { display: grid; gap: .5rem; }
.faq { border: 1.5px solid var(--line); border-radius: var(--r); background: var(--surface); padding: 0 1rem; }
.faq summary { cursor: pointer; font-weight: 600; padding: .85rem 0; min-height: 44px; list-style-position: outside; }
.faq p { margin: 0 0 .9rem; color: var(--ink-2); }
.landing-faq .btn { margin-top: .5rem; }
/* FAQ grouped by app: chips (scroll sideways inside the bar only), one group showing at a time */
.faq-groups { display: grid; gap: .6rem; min-width: 0; }
.faq-tabs { display: flex; gap: .4rem; overflow-x: auto; scrollbar-width: none; scroll-padding-inline: 1.5rem; padding: .1rem 0 .2rem; margin: 0 -.1rem; -webkit-overflow-scrolling: touch; }
.faq-tabs::-webkit-scrollbar { display: none; }
.faq-tab { flex: 0 0 auto; display: inline-flex; align-items: center; gap: .4rem; min-height: 44px; padding: .35rem .85rem; white-space: nowrap; }
.faq-tab:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand) 45%, transparent); outline-offset: 2px; }
.faq-tab-icon { display: inline-grid; width: 1.15rem; height: 1.15rem; }
.faq-tab-icon svg { width: 100%; height: 100%; }
.faq-count { font-size: .75rem; font-weight: 700; padding: 0 .4rem; border-radius: 999px; background: color-mix(in srgb, currentColor 14%, transparent); }
.faq-panel { display: grid; gap: .5rem; }
.faq-panel[hidden] { display: none; }
.signup-faq { margin-top: 1.5rem; }

/* Date range picker + sort (daterange.js), shared by every dashboard and list */
.dr { min-width: 0; }
.dr-button { display: flex; align-items: center; gap: .6rem; width: 100%; min-height: 52px; padding: .45rem .85rem; border-radius: 999px;
  border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.dr-button:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand) 45%, transparent); outline-offset: 2px; }
.dr-icon { font-size: 1.1rem; }
.dr-text { display: grid; flex: 1; min-width: 0; line-height: 1.2; }
.dr-text strong, .dr-text small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dr-text small { color: var(--ink-2); font-size: .8rem; }
.dr-caret { color: var(--ink-2); }
.dr-panel { display: grid; gap: .55rem; }
.dr-panel .section-title { margin: .4rem 0 0; }
.dr-chips { gap: .45rem; }
.dr-chip { min-height: 44px; }
.dr-row { display: flex; gap: .5rem; align-items: stretch; flex-wrap: wrap; }
.dr-row select { flex: 1 1 7rem; min-height: 44px; min-width: 0; }
.dr-row .btn { min-height: 44px; }
.dr-bar { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.dr-bar .dr { flex: 1 1 14rem; }
.dr-sort-wrap { display: flex; align-items: center; gap: .4rem; flex: 1 1 15rem; min-width: 0; }
.dr-sort { min-height: 44px; flex: 1; min-width: 0; }
.dr-compare { font-size: .8rem; font-weight: 700; }
.dr-compare.up { color: var(--ok); }
.dr-compare.down { color: var(--danger); }
.list-head { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.list-head h2 { flex: 1 1 auto; margin: 0; }
.signup-what { border: 1.5px solid var(--line); border-radius: var(--r); background: var(--surface); padding: 0 1rem; }
.signup-what summary { cursor: pointer; font-weight: 700; padding: .85rem 0; min-height: 44px; }
.signup-what .hl-list { padding-bottom: .5rem; }

/* ---------- Signup ---------- */
.back { color: var(--ink-2); text-decoration: none; font-weight: 600; justify-self: start; min-height: 36px; display: inline-flex; align-items: center; }
.signup-head { display: flex; gap: .9rem; align-items: center; }
.signup-head h1 { font-size: 1.55rem; letter-spacing: -.01em; }
.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
#signup { display: grid; gap: 1.15rem; }
.palettes { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.palette { position: relative; display: grid; gap: .35rem; justify-items: center; padding: .6rem .3rem; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); cursor: pointer; font-size: .85rem; font-weight: 600; }
.palette input { position: absolute; opacity: 0; inset: 0; cursor: pointer; min-height: 0; }
.palette:has(input:checked) { border-color: var(--ink); box-shadow: 0 0 0 2px var(--ink) inset; }
.palette:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 2px; }
.swatch { display: flex; width: 44px; height: 28px; border-radius: 8px; overflow: hidden; box-shadow: 0 0 0 1px rgb(0 0 0 / .08); }
.swatch i { flex: 2; } .swatch i + i { flex: 1; }
.custom-colors { display: none; grid-column: 1 / -1; grid-template-columns: 1fr 1fr; gap: .5rem; }
.palettes:has(#palette-custom:checked) .custom-colors { display: grid; }
.custom-colors label { display: grid; gap: .25rem; font-size: .85rem; color: var(--ink-2); }
.custom-colors input[type="color"] { padding: .2rem; height: var(--tap); }
.logo-pick { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; }
.logo-preview { width: 64px; height: 64px; border-radius: 16px; display: grid; place-items: center; background: var(--brand); color: var(--brand-ink); font-weight: 800; font-size: 1.4rem; overflow: hidden; flex: none; }
.logo-preview img { width: 100%; height: 100%; object-fit: cover; }
.error-page h1 { font-size: 1.5rem; }

/* ---------- Store app ---------- */
body.tenant { background: var(--bg); }
.boot { min-height: 80vh; display: grid; place-items: center; }
.boot-mark { width: 72px; height: 72px; border-radius: 20px; display: grid; place-items: center; background: var(--brand); color: var(--brand-ink); font-weight: 800; font-size: 1.6rem; }
.screen { max-width: 34rem; margin: 0 auto; padding: 1rem max(16px, env(safe-area-inset-right, 0px)) 2rem max(16px, env(safe-area-inset-left, 0px)); display: grid; gap: 1.25rem; }
.screen-narrow { max-width: 24rem; }

.appbar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--brand); color: var(--brand-ink); }
body.tenant::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); background: var(--brand); z-index: 10; }
.appbar-inner { max-width: 34rem; margin: 0 auto; padding: .6rem max(16px, env(safe-area-inset-right, 0px)) .6rem max(16px, env(safe-area-inset-left, 0px)); display: flex; align-items: center; gap: .7rem; min-height: 58px; }
.appbar h1 { font-size: 1.1rem; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.appbar .btn { background: transparent; color: var(--brand-ink); border-color: color-mix(in srgb, var(--brand-ink) 35%, transparent); }
.appbar-back { background: none; border: 0; color: var(--brand-ink); font-size: 1.6rem; width: 44px; height: 44px; margin-left: -10px; cursor: pointer; }
.brand-mark { width: 38px; height: 38px; border-radius: 10px; flex: none; display: grid; place-items: center; overflow: hidden; background: var(--brand-ink); color: var(--brand); font-weight: 800; font-size: .95rem; }
.brand-mark img { width: 100%; height: 100%; object-fit: cover; }
.brand-mark.lg { width: 84px; height: 84px; border-radius: 22px; font-size: 1.9rem; background: var(--brand); color: var(--brand-ink); }

.card { background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--r); padding: 1rem; display: grid; gap: .8rem; min-width: 0; }
.card h2 { font-size: 1.05rem; }
.section-title { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }

/* Login */
.login-head { display: grid; justify-items: center; gap: .7rem; text-align: center; padding-top: 1.5rem; }
.login-head h1 { font-size: 1.5rem; }
.who-list { display: grid; gap: .5rem; }
.who { display: flex; align-items: center; gap: .8rem; min-height: 60px; padding: .5rem .9rem; border: 1.5px solid var(--line); border-radius: var(--r); background: var(--surface); font: inherit; text-align: left; cursor: pointer; color: var(--ink); }
.who:hover { border-color: var(--brand); }
.who .avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--brand) 14%, #fff); color: var(--brand); font-weight: 700; flex: none; }
.who strong { display: block; }
.who small { color: var(--ink-2); }

.pin-dots { display: flex; justify-content: center; gap: .8rem; min-height: 24px; }
.pin-dots i { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--ink-2); }
.pin-dots i.on { background: var(--ink); border-color: var(--ink); }
.pinpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; max-width: 20rem; margin: 0 auto; width: 100%; }
.pinpad button { min-height: 64px; border-radius: var(--r); border: 1.5px solid var(--line); background: var(--surface); font: inherit; font-size: 1.5rem; font-weight: 600; color: var(--ink); cursor: pointer; font-variant-numeric: tabular-nums; }
.pinpad button:active { background: color-mix(in srgb, var(--brand) 10%, #fff); }
.pinpad .pin-go { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); font-size: 1.05rem; }
.pinpad .pin-del { font-size: 1.05rem; }
.pin-error { text-align: center; color: var(--danger); font-weight: 600; min-height: 1.4em; }

/* Banners */
.banner { display: flex; gap: .8rem; align-items: center; padding: .8rem .9rem; border-radius: var(--r); background: var(--warn-bg); border: 1.5px solid #F3E2A9; }
.banner p { flex: 1; font-size: .95rem; }
.banner.install { background: color-mix(in srgb, var(--brand) 8%, #fff); border-color: color-mix(in srgb, var(--brand) 25%, #fff); }

.banner.trial, .banner.renew { background: color-mix(in srgb, var(--accent) 22%, #fff); border-color: color-mix(in srgb, var(--accent) 55%, #fff); }
.banner-sub { color: var(--ink-2); font-size: .88rem; }

/* Plans and paywall */
.plans { display: grid; gap: .75rem; }
.plan { display: grid; gap: .7rem; padding: 1rem; border-radius: var(--r); border: 1.5px solid var(--line); background: var(--surface); }
.plan.current { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand) inset; }
.plan-head { display: flex; justify-content: space-between; align-items: baseline; gap: .75rem; flex-wrap: wrap; }
.plan-head h3 { font-size: 1.15rem; }
.plan-price strong { font-size: 1.4rem; }
.plan-price span { color: var(--ink-2); }
.plan-features { margin: 0; padding-left: 1.2rem; display: grid; gap: .25rem; color: var(--ink-2); font-size: .95rem; }
.paywall-actions { display: grid; gap: .5rem; }
.login-head h1 { max-width: 22rem; }

/* ---------- Login screen: the store's logo comes in (app.js loginStage; Settings → Login screen) ---------- */
.lg { display: grid; justify-items: center; gap: .6rem; }
.lg-stage { position: relative; width: 190px; height: 150px; display: grid; place-items: center; }
.lg-logo { position: relative; z-index: 2; display: grid; }
.lg-logo .brand-mark.lg { box-shadow: 0 14px 30px -12px color-mix(in srgb, var(--brand) 70%, transparent); }
.lg-name { margin: 0; font-size: 1.5rem; letter-spacing: -.02em; animation: lgFade .6s .35s both; }
.lg-welcome { margin: 0; color: var(--ink-2); font-size: .92rem; animation: lgFade .6s .55s both; }
@keyframes lgFade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* 1. Roll in */
.lg-roll .lg-logo { animation: lgRoll 1.1s cubic-bezier(.2,.9,.25,1.15) both; }
@keyframes lgRoll { from { transform: translateX(-160px) rotate(-360deg); opacity: 0; } 60% { opacity: 1; } to { transform: none; } }
/* 2. Hanging sign: two strings from a nail, swings and settles, then sways gently */
.lg-hang .lg-stage { height: 175px; }
.lg-hang .lg-nail { position: absolute; top: 2px; left: 50%; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: var(--ink-2); box-shadow: 0 2px 0 rgba(0,0,0,.2); z-index: 3; }
.lg-hang .lg-swing { position: absolute; inset: 0; transform-origin: 50% 8px; animation: lgSwing 2.6s ease-out both, lgSway 4s 2.6s ease-in-out infinite; }
.lg-hang .lg-string { position: absolute; top: 8px; left: 50%; width: 2px; height: 88px; margin-left: -1px; background: var(--ink-2); transform-origin: top center; }
.lg-hang .lg-string.l { transform: rotate(27deg); } .lg-hang .lg-string.r { transform: rotate(-27deg); }
.lg-hang .lg-logo { position: absolute; left: 50%; bottom: 4px; margin-left: -42px; }
@keyframes lgSwing { 0% { transform: rotate(-24deg); } 20% { transform: rotate(18deg); } 40% { transform: rotate(-11deg); } 60% { transform: rotate(6deg); } 80% { transform: rotate(-3deg); } 100% { transform: rotate(0); } }
@keyframes lgSway { 50% { transform: rotate(1.5deg); } }
/* 3. Bounce */
.lg-bounce .lg-logo { animation: lgBounce 1.2s both; }
@keyframes lgBounce { 0% { transform: translateY(-140px); animation-timing-function: ease-in; opacity: 0; } 40% { transform: translateY(0) scale(1.08, .9); animation-timing-function: ease-out; opacity: 1; } 60% { transform: translateY(-36px); animation-timing-function: ease-in; } 78% { transform: translateY(0) scale(1.04, .96); } 90% { transform: translateY(-8px); } 100% { transform: none; } }
/* 4. Flip */
.lg-flip .lg-stage { perspective: 600px; }
.lg-flip .lg-logo { animation: lgFlip 1.3s cubic-bezier(.3,1.4,.5,1) both; }
@keyframes lgFlip { from { transform: rotateY(-540deg) scale(.6); opacity: 0; } 40% { opacity: 1; } to { transform: none; } }
/* 5. Swoosh: an arc draws over the logo (like an airline logo) */
.lg-swoosh .lg-logo { animation: lgPop .7s .25s cubic-bezier(.2,1.4,.4,1) both; }
.lg-swoosh .lg-swoosh { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.lg-swoosh .lg-swoosh svg { width: 100%; height: 100%; }
.lg-swoosh .lg-swoosh path { fill: none; stroke: var(--accent); stroke-width: 6; stroke-linecap: round; stroke-dasharray: 200; stroke-dashoffset: 200; animation: lgDraw 1s .55s ease-out forwards; }
@keyframes lgPop { from { transform: scale(.3); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes lgDraw { to { stroke-dashoffset: 0; } }
/* 6. Orbit: three dots circle the logo */
.lg-orbit .lg-logo { animation: lgPop .7s cubic-bezier(.2,1.4,.4,1) both; }
.lg-orbit .lg-orb { position: absolute; top: 50%; left: 50%; width: 12px; height: 12px; margin: -6px; border-radius: 50%; background: var(--accent); animation: lgOrbit 3s linear infinite; }
.lg-orbit .lg-orb.b { animation-delay: -1s; background: var(--brand); } .lg-orbit .lg-orb.c { animation-delay: -2s; opacity: .6; }
@keyframes lgOrbit { from { transform: rotate(0) translateX(70px) rotate(0); } to { transform: rotate(360deg) translateX(70px) rotate(-360deg); } }
/* 7. Float: bobs gently, its shadow breathes */
.lg-float .lg-logo { animation: lgPop .7s both, lgBob 3s .7s ease-in-out infinite; }
.lg-float .lg-ripple { position: absolute; bottom: 8px; left: 50%; width: 90px; height: 14px; margin-left: -45px; border-radius: 50%; background: color-mix(in srgb, var(--ink) 18%, transparent); filter: blur(3px); animation: lgShadow 3s .7s ease-in-out infinite; }
@keyframes lgBob { 50% { transform: translateY(-14px); } }
@keyframes lgShadow { 50% { transform: scale(.7); opacity: .5; } }
/* 8. Glow: a soft halo in the store's colour pulses behind */
.lg-glow .lg-logo { animation: lgPop .8s cubic-bezier(.2,1.4,.4,1) both; }
.lg-glow .lg-halo { position: absolute; top: 50%; left: 50%; width: 120px; height: 120px; margin: -60px; border-radius: 50%; background: radial-gradient(color-mix(in srgb, var(--accent) 70%, transparent), transparent 70%); animation: lgHalo 2.4s ease-in-out infinite; }
@keyframes lgHalo { 50% { transform: scale(1.35); opacity: .55; } }
/* 9. Curtain: two panels slide apart */
.lg-curtain .lg-stage { overflow: hidden; border-radius: 24px; }
.lg-curtain .lg-cur { position: absolute; top: 0; bottom: 0; width: 50%; background: var(--brand); z-index: 3; animation: lgCurL 1s .3s cubic-bezier(.7,0,.2,1) forwards; }
.lg-curtain .lg-cur.l { left: 0; } .lg-curtain .lg-cur.r { right: 0; animation-name: lgCurR; }
@keyframes lgCurL { to { transform: translateX(-101%); } } @keyframes lgCurR { to { transform: translateX(101%); } }
/* 10. Typewriter: the logo pops, then the name types out */
.lg-type .lg-logo { animation: lgPop .6s cubic-bezier(.2,1.4,.4,1) both; }
.lg-type .lg-name { animation: none; min-height: 1.9rem; }
.lg-type .lg-name.typing::after { content: "|"; margin-left: 2px; color: var(--accent); animation: lgCaret .8s steps(1) infinite; }
@keyframes lgCaret { 50% { opacity: 0; } }
/* Settings preview */
.lg-preview { display: grid; place-items: center; padding: 1rem 0 .5rem; border-radius: var(--r); background: color-mix(in srgb, var(--brand) 6%, var(--bg)); overflow: hidden; }
.lg-chips { flex-wrap: wrap; }

/* "Logging you in" */
.logging-in { position: fixed; inset: 0; z-index: 90; display: grid; place-content: center; justify-items: center; gap: 1rem; background: var(--bg); animation: lgFade .25s both; }
.logging-in.out { opacity: 0; transition: opacity .3s; }
.logging-in p { margin: 0; color: var(--ink-2); font-weight: 600; }
.li-stage { position: relative; width: 140px; height: 140px; display: grid; place-items: center; }
.li-ring { position: absolute; inset: 0; animation: lgSpin 1.1s linear infinite; }
.li-ring svg { width: 100%; height: 100%; }
.li-ring circle { fill: none; stroke: var(--accent); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 90 240; }
@keyframes lgSpin { to { transform: rotate(360deg); } }
:root.lx-wall .logging-in { background: color-mix(in srgb, var(--bg) 70%, transparent); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
@media (prefers-reduced-motion: reduce) {
  .lg *, .lg-name, .lg-welcome, .logging-in, .li-ring { animation: none !important; }
  .lg-curtain .lg-cur { display: none; }
  .lg-swoosh .lg-swoosh path { stroke-dashoffset: 0; }
}

/* Home tiles */
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.tile { display: grid; gap: .35rem; align-content: start; min-height: 112px; padding: 1rem; border-radius: var(--r); border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); text-align: left; font: inherit; cursor: pointer; }
.tile strong { font-size: 1.05rem; }
.tile span { color: var(--ink-2); font-size: .88rem; }
.tile.primary { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); grid-column: 1 / -1; }
.tile.primary span { color: color-mix(in srgb, var(--brand-ink) 80%, transparent); }
.tile[disabled] { cursor: default; opacity: 1; }
.pill { display: inline-block; justify-self: start; padding: .1rem .55rem; border-radius: 999px; font-size: .75rem; font-weight: 700; background: var(--accent); color: var(--accent-ink); }

/* Products */
.progress { height: 10px; border-radius: 999px; background: var(--line); overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--accent); border-radius: 999px; transition: width .3s; }
.progress-label { display: flex; justify-content: space-between; font-size: .9rem; color: var(--ink-2); }
.product-form { display: grid; gap: .9rem; }
.photo-pick { display: grid; grid-template-columns: 96px 1fr; gap: .8rem; align-items: center; }
.photo-box { width: 96px; height: 96px; border-radius: var(--r-sm); border: 1.5px dashed var(--line); display: grid; place-items: center; overflow: hidden; background: var(--bg); color: var(--ink-2); font-size: .8rem; text-align: center; cursor: pointer; }
.photo-box img { width: 100%; height: 100%; object-fit: cover; }
.price-row { display: flex; align-items: stretch; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); overflow: hidden; }
.price-row:focus-within { border-color: var(--brand); }
.price-row span { display: flex; align-items: center; padding-left: .8rem; font-weight: 700; }
.price-row input { border: 0; box-shadow: none !important; }
.product-list { display: grid; gap: .5rem; }
.product { display: grid; grid-template-columns: 56px 1fr auto; gap: .75rem; align-items: center; padding: .5rem; border-radius: var(--r-sm); background: var(--surface); border: 1.5px solid var(--line); min-width: 0; }
.product .thumb { width: 56px; height: 56px; border-radius: 8px; overflow: hidden; background: color-mix(in srgb, var(--brand) 10%, #fff); display: grid; place-items: center; color: var(--brand); font-weight: 700; }
.product .thumb img { width: 100%; height: 100%; object-fit: cover; }
.product .meta { min-width: 0; }
.product .meta strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.product .meta small { color: var(--ink-2); }
.product .price { font-weight: 700; font-variant-numeric: tabular-nums; }
.product.off { opacity: .55; }
.empty { text-align: center; color: var(--ink-2); padding: 1.5rem .5rem; }

/* Settings */
.settings-list { display: grid; gap: 1rem; }
.row { display: flex; align-items: center; gap: .75rem; min-width: 0; }
.row > .grow { flex: 1; min-width: 0; }
.user-row { display: flex; align-items: center; gap: .75rem; padding: .55rem 0; border-top: 1px solid var(--line); }
.user-row:first-child { border-top: 0; }
.user-row .grow small { color: var(--ink-2); display: block; }
.badge-off { font-size: .75rem; font-weight: 700; color: var(--danger); }
.powered { text-align: center; font-size: .78rem; color: var(--ink-2); padding-top: .5rem; }

/* Sheet (iPhone install guide, forms) */
.sheet-backdrop { position: fixed; inset: 0; background: rgb(0 0 0 / .4); z-index: 20; display: flex; align-items: flex-end; justify-content: center; }
.sheet { background: var(--surface); width: 100%; max-width: 34rem; border-radius: 20px 20px 0 0; padding: 1.25rem max(16px, env(safe-area-inset-right, 0px)) calc(1.25rem + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); display: grid; gap: 1rem; max-height: 90vh; overflow: auto; }
.sheet h2 { font-size: 1.2rem; }
.steps { margin: 0; padding-left: 1.3rem; display: grid; gap: .6rem; }
.steps svg { width: 20px; height: 20px; vertical-align: -4px; }
/* Install from inside Messenger/Facebook: open in Safari/Chrome first */
.install-inapp { display: grid; gap: .8rem; }
.install-inapp p { margin: 0; }
.install-inapp .dots { letter-spacing: .1em; padding: 0 .3rem; border: 1px solid var(--line); border-radius: 6px; }
.install-inapp .row { gap: .5rem; }
.copy-link { flex: 1; min-width: 0; font-size: .9rem; }

/* ---------- /start: app picker, same look as the marketing homepage (black + Laxis yellow) ---------- */
body.st-page { margin: 0; min-height: 100vh; background: #09090A; color: #F4F4F5; font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased;
  background-image: radial-gradient(800px 500px at 85% -5%, rgba(255,201,60,.10), transparent 60%), radial-gradient(600px 400px at 0% 40%, rgba(255,255,255,.04), transparent 60%); }
.st { max-width: 760px; margin: 0 auto; padding: 18px 16px calc(110px + env(safe-area-inset-bottom)); }
.st a { color: inherit; }
.st-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 56px; }
.st-logo { display: flex; align-items: center; gap: 10px; font-weight: 800; letter-spacing: .32em; font-size: 15px; text-decoration: none; }
.st-logo i { width: 28px; height: 28px; border-radius: 8px; background: #FFC93C; color: #141006; display: grid; place-items: center; font-style: normal; letter-spacing: 0; font-size: 15px; }
.st-la { width: 46px; height: 28px; display: block; }
.st-top select { background: #141416; color: #F4F4F5; border: 1px solid #2A2A31; border-radius: 10px; padding: 6px 10px; font: inherit; font-size: 13px; }
.st-hero { padding: 44px 0 26px; }
.st-eyebrow { margin: 0 0 14px; font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: #FFC93C; font-weight: 700; }
.st-hero h1 { margin: 0; font-size: clamp(38px, 8vw, 64px); line-height: 1.02; letter-spacing: -.045em; font-weight: 800; }
.st-dot { color: #FFC93C; }
.st-lead { margin: 14px 0 0; color: #A1A1AA; font-size: 17px; max-width: 480px; }
.st-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.st-card { display: flex; align-items: center; gap: 14px; padding: 18px; border-radius: 18px; text-decoration: none; background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  border: 1px solid rgba(255,255,255,.09); transition: border-color .2s, transform .2s, background .2s; }
.st-card:hover, .st-card:focus-visible { border-color: #FFC93C; transform: translateY(-2px); background: linear-gradient(180deg, rgba(255,201,60,.10), rgba(255,255,255,.02)); outline: none; }
.st-icon { width: 48px; height: 48px; flex: none; border-radius: 14px; background: #FFC93C; color: #141006; display: grid; place-items: center; }
.st-icon svg { width: 26px; height: 26px; }
.st-text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.st-text strong { font-size: 18px; letter-spacing: -.01em; }
.st-text span { color: #A1A1AA; font-size: 13.5px; line-height: 1.35; }
.st-go { color: #FFC93C; font-size: 20px; font-weight: 700; transition: transform .2s; }
.st-card:hover .st-go { transform: translateX(3px); }
.st-checks { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 20px; padding: 0; margin: 18px 0 30px; color: #A1A1AA; font-size: 14px; }
.st-checks li::before { content: "✓"; color: #FFC93C; font-weight: 800; margin-right: 7px; }
.st-login { padding: 18px; border-radius: 18px; border: 1px solid rgba(255,255,255,.09); background: rgba(255,255,255,.03); display: grid; gap: 10px; }
.st-login label { font-size: 14px; color: #A1A1AA; }
.st-login label strong { color: #F4F4F5; }
.st-slug { display: flex; align-items: center; border: 1px solid #2A2A31; border-radius: 12px; background: #0B0B0D; overflow: hidden; }
.st-slug:focus-within { border-color: #FFC93C; }
.st-prefix { padding-left: 12px; color: #71717A; font-size: 14px; white-space: nowrap; }
.st-slug input { flex: 1; min-width: 0; border: 0; background: transparent; color: #F4F4F5; font: inherit; font-size: 16px; padding: 12px 6px; outline: none; }
.st-slug button { border: 0; background: #FFC93C; color: #141006; font: inherit; font-weight: 700; padding: 0 18px; align-self: stretch; cursor: pointer; }
.st-foot { margin-top: 30px; display: grid; gap: 10px; font-size: 13px; color: #71717A; }
.st-foot a { color: #D4D4D8; }
.st-foot > a { text-decoration: none; font-weight: 600; }
/* Signup pages: the same black + yellow look. Most signup styles read these variables, so this re-themes the page. */
body.su-page {
  color-scheme: dark;
  --bg: #09090A; --surface: #141416; --surface-2: #1B1B20; --ink: #F4F4F5; --ink-2: #A1A1AA; --line: #2A2A31;
  --brand: #FFC93C; --brand-ink: #141006; --accent: #FFC93C; --accent-ink: #141006; --accent-ui: #FFC93C; --accent-ui-ink: #141006; --brand-text: #FFC93C;
  --danger: #FF8E84; --danger-bg: #3B1E1C; --ok: #6FDDA2; --ok-bg: #12301F; --warn-bg: #3A2F12;
  background: #09090A; color: var(--ink);
  background-image: radial-gradient(800px 500px at 85% -5%, rgba(255,201,60,.10), transparent 60%);
}
.su-page .su-top { height: 56px; align-items: center; }
.su-page .st-logo { color: var(--ink); }
.su-page .su-back { display: inline-block; margin: 4px 0 6px; color: var(--ink-2); text-decoration: none; font-weight: 600; }
.su-page a:not(.btn):not(.st-logo) { color: var(--brand-text); }
.su-page .signup-head h1 { letter-spacing: -.03em; }
.su-page .eyebrow { color: #FFC93C; }
.su-page .type-icon { background: #FFC93C; color: #141006; }
.su-page input, .su-page select, .su-page textarea { background: #0B0B0D; color: var(--ink); border-color: var(--line); }
.su-page input:focus, .su-page select:focus { border-color: #FFC93C; outline: 2px solid rgba(255,201,60,.35); }
.su-page .slug-prefix, .su-page .phone-prefix { background: #1B1B20; color: var(--ink-2); border-color: var(--line); }
.su-page .btn-primary { box-shadow: 0 0 0 4px rgba(255,201,60,.14), 0 10px 30px -10px rgba(255,201,60,.5); }
.su-page details.signup-what, .su-page .landing-faq details.faq { background: var(--surface); border-color: var(--line); }
.su-page .chip-btn.on, .su-page .faq-tab.on { background: #FFC93C; color: #141006; border-color: #FFC93C; }
/* Signup steps: 1 Business → 2 Account → 3 Look */
.su-progress { display: grid; gap: .6rem; margin: .4rem 0 .2rem; }
.su-dots { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.su-dots li { display: flex; align-items: center; gap: .5rem; color: var(--ink-2); font-size: .85rem; font-weight: 600; }
.su-dots b { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: .8rem; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink-2); flex: none; transition: .25s; }
.su-dots li.on b { background: #FFC93C; border-color: #FFC93C; color: #141006; }
.su-dots li.on { color: var(--ink); }
.su-dots li.now b { box-shadow: 0 0 0 4px rgba(255,201,60,.22); }
.su-bar { height: 4px; border-radius: 99px; background: var(--line); overflow: hidden; }
.su-bar i { display: block; height: 100%; width: 33.4%; background: linear-gradient(90deg, #FFC93C, #FFD666); border-radius: inherit; transition: width .35s ease; }
.su-step { display: grid; gap: 1rem; padding: 1.2rem; border-radius: 18px; border: 1px solid var(--line); background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.015)); animation: lgFade .35s both; }
.su-step[hidden] { display: none; }
.su-h { margin: 0; font-size: 1.35rem; letter-spacing: -.02em; }
.su-sub { margin: -.6rem 0 0; }
.su-nav { display: flex; gap: .6rem; margin-top: .2rem; }
.su-nav .btn { flex: 1; }
.su-nav .btn[data-back] { flex: 0 0 auto; }
.su-page #signup { display: grid; gap: 1rem; }
.su-page .signup-what { margin-bottom: .2rem; }

@media (max-width: 600px) {
  .st-hero { padding-top: 28px; }
  .st-grid { grid-template-columns: 1fr; }
  .st-prefix { display: none; }
}

.toast { position: fixed; left: 50%; bottom: calc(1rem + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--ink); color: #fff; padding: .7rem 1rem; border-radius: 999px; font-weight: 600; z-index: 30; max-width: calc(100% - 32px); }

/* ---------- Payment screen (store app) ---------- */
.pay-amount { font-size: 2rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.code-box { display: flex; align-items: center; gap: .6rem; padding: .7rem .9rem; border: 2px dashed var(--brand); border-radius: var(--r-sm); background: color-mix(in srgb, var(--brand) 6%, #fff); }
.code-box strong { flex: 1; font-size: 1.35rem; letter-spacing: .06em; font-variant-numeric: tabular-nums; }
.qr { width: 220px; max-width: 100%; aspect-ratio: 1; object-fit: contain; margin: 0 auto; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: #fff; }
.pay-dest { display: grid; gap: .2rem; }
.status-card.pending_review { background: var(--ok-bg); border-color: #BFE3CF; }
.status-card.rejected { background: var(--danger-bg); border-color: #F1C5C0; }

/* ---------- POS ---------- */
.screen.pos { padding-bottom: 6rem; }
.pos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(7.25rem, 1fr)); gap: .6rem; }
.pos-tile { position: relative; display: grid; gap: .2rem; align-content: start; padding: .5rem; border: 1.5px solid var(--line); border-radius: var(--r); background: var(--surface); font: inherit; text-align: left; cursor: pointer; color: var(--ink); min-width: 0; }
.pos-tile:active { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 6%, #fff); }
.pos-tile.out { opacity: .6; }
.tile-img { aspect-ratio: 1; border-radius: var(--r-sm); overflow: hidden; display: grid; place-items: center; background: color-mix(in srgb, var(--brand) 10%, #fff); color: var(--brand); font-weight: 800; font-size: 1.3rem; }
.tile-img img { width: 100%; height: 100%; object-fit: cover; }
.tile-name { font-weight: 600; font-size: .9rem; line-height: 1.25; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.tile-price { font-weight: 800; }
.tile-stock { font-size: .75rem; color: var(--ink-2); }
.qty-badge { position: absolute; top: .3rem; right: .3rem; min-width: 1.7rem; height: 1.7rem; padding: 0 .35rem; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-weight: 800; display: grid; place-items: center; font-variant-numeric: tabular-nums; }
.cart-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 8; display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 64px; padding: .6rem max(16px, env(safe-area-inset-right, 0px)) calc(.6rem + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); background: var(--brand); color: var(--brand-ink); border: 0; font: inherit; font-weight: 700; font-size: 1.05rem; cursor: pointer; }
.cart-bar strong { font-size: 1.3rem; }
.co-lines { display: grid; gap: .4rem; }
.co-line { display: flex; align-items: center; gap: .5rem; padding: .35rem 0; border-bottom: 1px solid var(--line); }
.co-line .grow { flex: 1; min-width: 0; }
.co-line strong { min-width: 1.5rem; text-align: center; }
.co-sub { min-width: 4.5rem; text-align: right; font-weight: 600; }
.co-total { display: flex; justify-content: space-between; font-size: 1.3rem; font-weight: 800; }
.quick-cash { display: flex; flex-wrap: wrap; gap: .4rem; }
.change { font-size: 1.6rem; font-weight: 800; text-align: center; min-height: 2rem; font-variant-numeric: tabular-nums; }
.change.ok { color: var(--ok); }
.change.short { color: var(--danger); font-size: 1.15rem; }

/* Receipt: on screen as a card, printed at 58mm */
.receipt { width: 100%; max-width: 58mm; margin: 0 auto; padding: .6rem; background: #fff; color: #000; border: 1px dashed var(--line); font-family: ui-monospace, "Courier New", monospace; font-size: 12px; line-height: 1.35; }
.receipt hr { border: 0; border-top: 1px dashed #000; margin: .35rem 0; }
.r-store { font-weight: 700; text-align: center; font-size: 14px; }
.r-small { text-align: center; font-size: 11px; }
.r-line { display: flex; justify-content: space-between; gap: .5rem; }
.r-total { font-weight: 700; }
.r-thanks { margin-top: .4rem; }
.receipt-text { white-space: pre-wrap; text-align: left; }

/* ---------- Professional receipt (receipt.js): every business type ---------- */
.rdoc { --rd-ink: #18181b; --rd-mute: #71717a; --rd-line: #e4e4e7; background: #fff; color: var(--rd-ink); width: 100%; max-width: 560px; margin: 0 auto;
  padding: 1.4rem 1.3rem 1.1rem; border-radius: 10px; border-top: 6px solid var(--rd-brand, #111); box-shadow: 0 1px 2px rgba(0,0,0,.06), 0 8px 24px -12px rgba(0,0,0,.25);
  font-size: 13px; line-height: 1.4; font-variant-numeric: tabular-nums; text-align: left; }
.rd-head { display: flex; gap: .8rem; align-items: center; padding-bottom: .9rem; border-bottom: 2.5px solid var(--rd-ink); }
.rd-logo { width: 46px; height: 46px; border-radius: 11px; flex: none; display: grid; place-items: center; font-weight: 800; font-size: 1.3rem; object-fit: cover; }
.rd-biz { min-width: 0; flex: 1; }
.rd-biz b { display: block; font-size: 1.05rem; line-height: 1.2; overflow-wrap: anywhere; }
.rd-biz span { display: block; color: var(--rd-mute); font-size: 11.5px; }
.rd-no { text-align: right; flex: none; }
.rd-no span { display: block; font-size: 10px; letter-spacing: .12em; color: var(--rd-mute); font-weight: 700; }
.rd-no b { font-size: 1.2rem; letter-spacing: .02em; }
.rd-meta { display: grid; grid-template-columns: 1fr 1fr; gap: .65rem 1rem; padding: .9rem 0; }
.rd-meta span { display: block; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: #8a8a92; }
.rd-meta b { font-size: 13.5px; overflow-wrap: anywhere; }
.rd-items { width: 100%; border-collapse: collapse; margin-top: .2rem; }
.rd-items th { font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: #8a8a92; font-weight: 600; text-align: left; padding: .45rem 0; border-bottom: 1px solid #d4d4d8; }
.rd-items td { padding: .5rem 0; border-bottom: 1px solid #f0f0f2; vertical-align: top; }
.rd-items td small { display: block; color: var(--rd-mute); font-size: 11.5px; }
.rd-items th:not(:first-child), .rd-items td:not(:first-child) { text-align: right; white-space: nowrap; padding-left: .8rem; }
.rd-items td:last-child { font-weight: 600; }
.rd-totals { margin: .8rem 0 0 auto; width: min(100%, 300px); display: grid; gap: .3rem; }
.rd-totals div { display: flex; justify-content: space-between; gap: 1rem; }
.rd-totals span { color: #52525b; }
.rd-totals .rd-total { font-size: 14.5px; }
.rd-totals .rd-total span, .rd-totals .rd-balance span { color: var(--rd-ink); font-weight: 700; }
.rd-totals .rd-balance { border-top: 2.5px solid var(--rd-ink); padding-top: .4rem; margin-top: .15rem; font-size: 15px; }
.rd-totals .rd-balance b, .rd-totals .rd-total b { font-weight: 800; }
.rd-notes { margin-top: .9rem; padding: .6rem .75rem; border-radius: 8px; background: #f4f4f5; display: grid; gap: .25rem; }
.rd-notes p { margin: 0; font-size: 12px; color: #3f3f46; }
.rd-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; margin-top: 1.2rem; }
.rd-stamp { border: 2.5px solid currentColor; color: var(--rd-ink); font-weight: 800; letter-spacing: .14em; padding: .2rem .6rem; border-radius: 4px; transform: rotate(-6deg); font-size: 13px; white-space: nowrap; }
.rd-stamp.ok { color: #15803d; } .rd-stamp.warn { color: #b45309; } .rd-stamp.bad { color: #b91c1c; }
.rd-sig { display: grid; justify-items: center; gap: .25rem; color: #52525b; font-size: 11px; min-width: 150px; }
.rd-sig i { display: block; width: 100%; border-top: 1px solid var(--rd-ink); }
.rd-thanks { text-align: center; font-weight: 600; margin: 1rem 0 0; }
.rd-legal { text-align: center; color: #8a8a92; font-size: 10.5px; margin: .35rem 0 0; }
.rd-actions { margin-top: .75rem; }
/* 58mm thermal: one column, no frills */
.rdoc.rd-58 { max-width: 58mm; padding: .5rem .4rem; border-top: 0; box-shadow: none; border-radius: 0; font-size: 11px; }
.rd-58 .rd-head { flex-direction: column; text-align: center; gap: .3rem; padding-bottom: .4rem; border-bottom-width: 1.5px; }
.rd-58 .rd-logo { width: 30px; height: 30px; font-size: .9rem; border-radius: 6px; }
.rd-58 .rd-no { text-align: center; }
.rd-58 .rd-meta { grid-template-columns: 1fr; gap: .2rem; padding: .4rem 0; }
.rd-58 .rd-meta div { display: flex; justify-content: space-between; gap: .4rem; }
.rd-58 .rd-meta span { font-size: 9px; }
.rd-58 .rd-meta b { font-size: 11px; text-align: right; }
.rd-58 .rd-items th { display: none; }
.rd-58 .rd-items tr { display: grid; grid-template-columns: 1fr auto; column-gap: .4rem; border-bottom: 1px dashed #d4d4d8; padding: .2rem 0; }
.rd-58 .rd-items td { padding: 0; border: 0; }
.rd-58 .rd-items td:first-child { grid-column: 1 / -1; }
.rd-58 .rd-items td:nth-child(2) { text-align: left !important; padding-left: 0 !important; color: var(--rd-mute); white-space: normal; }
.rd-58 .rd-totals { width: 100%; }
.rd-58 .rd-foot { flex-direction: column; align-items: center; margin-top: .6rem; }
.rd-58 .rd-stamp { transform: none; font-size: 11px; }
#print-area { display: none; }
@media print {
  @page { size: 58mm auto; margin: 2mm; }
  /* Only while a receipt is being printed (POS); other print pages (contract, lesson plans) print the screen. */
  body:has(> #print-area) > *:not(#print-area) { display: none !important; }
  body::before { display: none !important; }
  #print-area { display: block !important; }
  #print-area .receipt { border: 0; max-width: none; width: 54mm; padding: 0; }
  #print-area .rdoc { box-shadow: none; border-radius: 0; max-width: none; padding: 0; border-top-width: 4px; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  #print-area .rdoc.rd-58 { width: 54mm; border-top: 0; }
}

/* ---------- Inventory ---------- */
.inv-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: .45rem; }
.inv-card { display: grid; gap: .1rem; justify-items: center; padding: .6rem .2rem; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--surface); font: inherit; cursor: pointer; color: var(--ink); }
.inv-card strong { font-size: 1.35rem; }
.inv-card span { font-size: .8rem; font-weight: 600; }
.inv-card.safe { border-color: #BFE3CF; } .inv-card.safe strong { color: var(--ok); }
.inv-card.low { border-color: #F3E2A9; } .inv-card.low strong { color: #8A5A00; }
.inv-card.critical { border-color: #F1C5C0; } .inv-card.critical strong { color: var(--danger); }
.inv-card.on { box-shadow: 0 0 0 2px var(--ink) inset; }
.inv-row { display: grid; grid-template-columns: 52px 1fr auto; gap: .7rem; align-items: center; padding: .5rem; border-radius: var(--r-sm); background: var(--surface); border: 1.5px solid var(--line); min-width: 0; }
.inv-row .thumb, .restock-card .thumb { width: 52px; height: 52px; border-radius: 8px; overflow: hidden; display: grid; place-items: center; background: color-mix(in srgb, var(--brand) 10%, #fff); color: var(--brand); font-weight: 700; flex: none; }
.inv-row .thumb img, .restock-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.inv-row .meta, .restock-card .meta { display: grid; gap: .15rem; min-width: 0; }
.inv-row .meta strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inv-row small { color: var(--ink-2); }

/* ---------- Utang ---------- */
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: .4rem; }
.seg-btn { min-height: 48px; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--surface); font-weight: 700; font-size: 1rem; color: var(--ink); cursor: pointer; }
.seg-btn.on { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 10%, #fff); color: var(--brand); }
.utang-pick { display: grid; gap: .5rem; }
.utang-list { display: grid; gap: .35rem; }
.utang-opt { display: flex; align-items: center; gap: .5rem; min-height: 46px; padding: .4rem .8rem; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font-size: .98rem; text-align: left; cursor: pointer; }
.utang-opt.new { border-style: dashed; color: var(--brand); font-weight: 600; }
.utang-opt .owes, .utang-bal.owes, .utang-head .owes { color: var(--danger); font-weight: 700; }
.utang-chosen { display: flex; align-items: center; gap: .6rem; padding: .6rem .8rem; border-radius: var(--r-sm); border: 1.5px solid var(--brand); background: color-mix(in srgb, var(--brand) 6%, #fff); }
.utang-chosen .grow { display: grid; gap: .1rem; }
.utang-summary .big { font-size: 2rem; font-weight: 800; }
.list { display: grid; gap: .5rem; }
.row-card { display: flex; align-items: center; gap: .7rem; width: 100%; padding: .6rem .7rem; border-radius: var(--r-sm); background: var(--surface); border: 1.5px solid var(--line); color: var(--ink); text-align: left; cursor: pointer; font: inherit; }
.row-card .grow, .utang-entry .grow, .utang-opt .grow, .utang-chosen .grow { flex: 1 1 auto; }
.row-card .grow { display: grid; gap: .1rem; min-width: 0; }
.row-card.over { border-color: color-mix(in srgb, var(--danger) 55%, var(--line)); }
.avatar { width: 42px; height: 42px; flex: none; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--brand) 12%, #fff); color: var(--brand); font-weight: 700; }
.utang-bal { white-space: nowrap; }
.utang-head { display: grid; gap: .15rem; justify-items: start; }
.utang-head .big { font-size: 2rem; }
.utang-history { display: grid; gap: .4rem; }
.utang-entry { display: flex; gap: .6rem; align-items: flex-start; padding: .5rem .6rem; border-radius: var(--r-sm); border: 1px solid var(--line); }
.utang-entry .grow { display: grid; gap: .1rem; min-width: 0; }
.utang-entry.charge .num { color: var(--danger); font-weight: 700; }
.utang-entry.payment .num { color: #1F7A4D; font-weight: 700; }
.utang-entry.voided { opacity: .55; }
.utang-entry.voided .num { text-decoration: line-through; }
.stock-badge { justify-self: start; display: inline-block; padding: .1rem .5rem; border-radius: 999px; font-size: .75rem; font-weight: 700; white-space: nowrap; }
.stock-badge.safe, .stock-badge.safe_no_sales { background: var(--ok-bg); color: var(--ok); }
.stock-badge.low { background: var(--warn-bg); color: #8A5A00; }
.stock-badge.critical, .stock-badge.out { background: var(--danger-bg); color: var(--danger); }
.btn.plus { width: 48px; padding: 0; font-size: 1.5rem; background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.batches { display: grid; gap: .8rem; }
.batch-day { display: grid; gap: .4rem; }
.batch { display: grid; gap: .3rem; padding: .5rem; border: 1px solid var(--line); border-radius: var(--r-sm); }
.batch input { width: 6rem; flex: 0 1 auto; }
details.more summary { cursor: pointer; color: var(--brand); font-weight: 600; padding: .25rem 0; }
.summary-card .big { font-size: 1.6rem; }
.admin-list li.voided { opacity: .55; text-decoration: line-through; }

/* ---------- Restock Checklist ---------- */
.screen.restock { padding-bottom: 9rem; }
.restock-list { display: grid; gap: .6rem; }
.restock-card { display: grid; gap: .5rem; padding: .7rem; border-radius: var(--r); background: var(--surface); border: 1.5px solid var(--line); }
.restock-card.off { opacity: .6; }
.restock-card input[type="checkbox"] { width: 1.4rem; height: 1.4rem; min-height: 0; flex: none; }
.restock-card .kv { display: flex; flex-wrap: wrap; align-items: baseline; gap: .15rem .35rem; font-size: .88rem; }
.restock-card .kv dt::after { content: ":"; }
.restock-card .kv dd { margin-right: .7rem; white-space: nowrap; font-weight: 700; }
.cost-alert { background: var(--warn-bg); border-radius: var(--r-sm); padding: .45rem .6rem; font-size: .88rem; }
.budget { grid-template-columns: auto 1fr; align-items: center; }
.budget input { max-width: 10rem; }
.budget small { grid-column: 1 / -1; }
.restock-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 8; display: grid; gap: .5rem; padding: .6rem max(16px, env(safe-area-inset-right, 0px)) calc(.6rem + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); background: var(--surface); border-top: 1.5px solid var(--line); box-shadow: 0 -4px 16px rgb(0 0 0 / .06); }
.restock-bar .row { max-width: 34rem; margin: 0 auto; width: 100%; }
.restock-bar > .btn { max-width: 34rem; margin: 0 auto; }
.check-list { display: grid; gap: .3rem; max-height: 55vh; overflow: auto; }
.check-row { display: flex; align-items: center; gap: .6rem; padding: .45rem .2rem; border-bottom: 1px solid var(--line); }
.check-row input { width: 1.3rem; height: 1.3rem; min-height: 0; }
td.bad { color: var(--danger); }
.tabs button { padding: .45rem .9rem; border-radius: 999px; border: 1.5px solid var(--line); color: var(--ink); font: inherit; font-weight: 600; background: var(--surface); cursor: pointer; }
.tabs button.on { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }

/* ---------- Languages, help, reminders, expiry ---------- */
.lang-picker { width: auto; min-height: 40px; padding: .35rem .6rem; font-size: .9rem; }
.lang-picker.compact { max-width: 11rem; }
.landing-top { display: flex; align-items: center; gap: .5rem; }
.landing-top .grow, .row .grow { flex: 1; }
.login-top { width: 100%; }
.help-btn { justify-self: center; }
.appbar-bell { position: relative; background: none; border: 0; font-size: 1.25rem; width: 40px; height: 40px; cursor: pointer; color: var(--brand-ink); }
.appbar-bell .badge { position: absolute; top: 2px; right: 0; }
.notif-list { display: grid; gap: .4rem; }
.notif { display: grid; gap: .15rem; text-align: left; padding: .6rem .7rem; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--surface); font: inherit; color: var(--ink); cursor: pointer; }
.notif.unread { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 6%, #fff); }
.push-card { gap: .5rem; }
.hint.ok { color: var(--ok); font-weight: 700; }
.renew-card { background: color-mix(in srgb, var(--accent) 14%, #fff); border-color: color-mix(in srgb, var(--accent) 45%, #fff); }
.inv-cards { grid-template-columns: repeat(5, 1fr); }
.inv-card.expiring { border-color: #F5C9A8; } .inv-card.expiring strong { color: #B4530A; }
.badges { gap: .3rem; }
.expiry-badge { display: inline-block; align-self: flex-start; justify-self: start; width: fit-content; padding: .1rem .5rem; border-radius: 999px; font-size: .75rem; font-weight: 700; white-space: nowrap; }
.expiry-badge.expiring { background: #FFEBD9; color: #B4530A; }
.expiry-badge.expired { background: var(--danger); color: #fff; }
.expiring-row.expired { border-color: #F1C5C0; }
.expiry-btn { color: #B4530A; border-color: #F5C9A8; }
.batch input[type="date"] { width: auto; }
@media (max-width: 420px) {
  .inv-cards { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- Super-admin console ---------- */
body.admin { background: var(--bg); }
.boot-text { padding: 2rem; color: var(--ink-2); }
.admin-auth-wrap { min-height: 100vh; display: grid; place-items: center; padding: 1rem max(16px, env(safe-area-inset-right, 0px)) 1rem max(16px, env(safe-area-inset-left, 0px)); }
.admin-auth { width: 100%; max-width: 24rem; }
.admin-auth h1 { font-size: 1.3rem; }
.admin-top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: .75rem; padding: .6rem max(16px, env(safe-area-inset-right, 0px)) .6rem max(16px, env(safe-area-inset-left, 0px)); background: var(--surface); border-bottom: 1px solid var(--line); }
.admin-top .grow { flex: 1; }
.admin-body { display: grid; grid-template-columns: 12rem 1fr; min-height: calc(100vh - 56px); }
.admin-nav { display: grid; align-content: start; gap: .2rem; padding: 1rem .6rem; border-right: 1px solid var(--line); background: var(--surface); }
.admin-nav a { display: flex; align-items: center; justify-content: space-between; min-height: 44px; padding: .6rem .75rem; border-radius: 12px; color: var(--ink) !important; text-decoration: none; font-weight: 600; }
.admin-nav a.on { background: var(--accent-ui, var(--brand)); color: var(--accent-ui-ink, #fff) !important; }
.admin-main:has(.admin-dash) { max-width: 76rem; }
.badge { background: var(--danger); color: #fff; border-radius: 999px; font-size: .75rem; padding: .05rem .45rem; font-variant-numeric: tabular-nums; }
.admin-main { padding: 1.25rem max(16px, env(safe-area-inset-right, 0px)) 3rem 1.25rem; display: grid; gap: 1rem; align-content: start; min-width: 0; max-width: 64rem; }
.admin-main h1 { font-size: 1.5rem; }
.admin-grid { display: grid; gap: 1rem; min-width: 0; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: .75rem; }
.kpi { display: grid; gap: .2rem; padding: 1rem; border: 1.5px solid var(--line); border-radius: var(--r); background: var(--surface); }
.kpi-label { font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); }
.kpi strong { font-size: 1.6rem; }
.admin-list { list-style: none; margin: 0; padding: 0; display: grid; }
.admin-list li { display: flex; justify-content: space-between; align-items: center; gap: .75rem; flex-wrap: wrap; padding: .55rem 0; border-top: 1px solid var(--line); }
.admin-list li:first-child { border-top: 0; }
.admin-list li.unread strong { color: var(--brand); }
.bars { display: flex; align-items: flex-end; gap: .4rem; height: 9rem; overflow-x: auto; }
.bar { flex: 1 0 2rem; max-width: 3.5rem; height: 100%; display: grid; grid-template-rows: auto 1fr auto; justify-items: center; font-size: .75rem; }
.bar i { align-self: end; width: 70%; min-height: 3px; background: var(--brand); border-radius: 4px 4px 0 0; }
.bar small { color: var(--ink-2); }
/* Admin → Messages (live chat inbox) */
.badge[hidden] { display: none; }
.chat-list { display: grid; gap: .6rem; margin-top: 1rem; max-width: 760px; }
.chat-row { display: grid; gap: .25rem; text-decoration: none; color: var(--ink) !important; }
.chat-row.unread { border-left: 4px solid var(--danger); }
.chat-row.unread strong { font-weight: 800; }
.chat-last { margin: 0; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-head h1 { margin: 0; }
.chat-thread { display: flex; flex-direction: column; gap: .5rem; max-width: 760px; max-height: 60vh; overflow-y: auto; padding: 1rem; margin: .8rem 0; border: 1px solid var(--line); border-radius: 16px; background: var(--bg); }
.chat-msg { max-width: 80%; padding: .55rem .8rem; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); }
.chat-msg p { margin: .15rem 0 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.chat-msg.chat-admin { align-self: flex-end; background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.chat-msg.chat-admin .hint { color: inherit; opacity: .8; }
.chat-msg.chat-bot { opacity: .8; font-size: .92rem; }
.chat-reply { display: grid; gap: .6rem; max-width: 760px; }
.chat-reply textarea { width: 100%; }
.landing-email { text-align: center; margin-top: .8rem; }
.tabs { display: flex; gap: .4rem; }
.tabs a { padding: .45rem .9rem; border-radius: 999px; border: 1.5px solid var(--line); text-decoration: none; color: var(--ink); font-weight: 600; background: var(--surface); }
.tabs a.on { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.pay-list { display: grid; gap: .75rem; }
.pay-card { grid-template-columns: 9rem 1fr; align-items: start; }
.shot { display: block; width: 9rem; aspect-ratio: 9 / 16; border-radius: var(--r-sm); overflow: hidden; background: var(--bg); border: 1.5px solid var(--line); }
.shot img { width: 100%; height: 100%; object-fit: cover; }
.empty-shot { display: grid; place-items: center; text-align: center; font-size: .8rem; color: var(--ink-2); padding: .5rem; }
.pay-info { display: grid; gap: .5rem; min-width: 0; }
.pay-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.pay-actions .row { flex-basis: 100%; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: .3rem .9rem; margin: 0; }
.kv dt { color: var(--ink-2); }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.chip { display: inline-block; padding: .1rem .55rem; border-radius: 999px; font-size: .78rem; font-weight: 700; background: var(--line); color: var(--ink); white-space: nowrap; }
.chip-trial, .chip-awaiting_payment { background: #E8EEF8; color: #1D4ED8; }
.chip-active, .chip-approved { background: var(--ok-bg); color: var(--ok); }
.chip-expired, .chip-rejected { background: var(--danger-bg); color: var(--danger); }
.chip-suspended { background: #2B2F36; color: #fff; }
.chip-pending_review { background: var(--warn-bg); color: #8A5A00; }
.filters { display: flex; flex-wrap: wrap; gap: .5rem; }
.filters input { flex: 1 1 14rem; }
.filters select { width: auto; }
.table-wrap { overflow-x: auto; background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--r); }
.admin-table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.admin-table th, .admin-table td { padding: .6rem .8rem; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.admin-table th { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); }
.row.wrap { flex-wrap: wrap; }
.days { width: 5.5rem; }
.check { display: inline-flex; align-items: center; gap: .4rem; font-weight: 500; }
.check input { width: auto; min-height: 0; }
.features { display: flex; flex-wrap: wrap; gap: .4rem 1rem; }
.plan-edit input:not([type]), .plan-edit input[inputmode] { width: auto; flex: 1 1 8rem; }
.danger-zone summary { cursor: pointer; color: var(--danger); font-weight: 600; }
.settings-form { display: grid; gap: .7rem; }
.settings-form h3 { font-size: .95rem; margin-top: .4rem; }
.qr-preview { width: 10rem; aspect-ratio: 1; object-fit: contain; border: 1.5px solid var(--line); border-radius: var(--r-sm); }
@media (max-width: 720px) {
  .admin-body { grid-template-columns: 1fr; }
  .admin-nav { display: flex; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--line); padding: .4rem; }
  .admin-nav a { white-space: nowrap; }
  .admin-main { padding-left: max(16px, env(safe-area-inset-left, 0px)); }
  .pay-card { grid-template-columns: 1fr; }
  .shot { width: 100%; max-width: 14rem; }
}

@media (min-width: 640px) {
  .tiles { grid-template-columns: repeat(3, 1fr); }
  .tile.primary { grid-column: span 3; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* ---------- Guro (teachers) ---------- */
.chips { display: flex; flex-wrap: wrap; gap: .4rem; }
.chip-btn { min-height: 40px; min-width: 44px; padding: .3rem .75rem; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-weight: 600; cursor: pointer; }
.chip-btn.on { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.sched-rows { display: grid; gap: .6rem; }
.sched-row { display: grid; gap: .4rem; padding: .6rem; border: 1.5px dashed var(--line); border-radius: var(--r-sm); }
.sched-row .row input[type="time"] { flex: 1 1 0; min-width: 0; }
.plain-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .25rem; }
.plain-list li.on { font-weight: 700; }
.row-card.off { opacity: .6; }
.row-card .counts { display: grid; justify-items: end; gap: .05rem; }
.ml-row { padding: .45rem .7rem; }
.ml-no { min-width: 1.6rem; color: var(--ink-2); text-align: right; }
.map-list { display: grid; gap: .5rem; }
.map-row { display: flex; align-items: center; gap: .6rem; }
.map-row .grow { flex: 1 1 auto; display: grid; min-width: 0; }
.map-row .grow small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.map-row select { width: 46%; flex: 0 0 auto; }
.preview-list { max-height: 55vh; overflow: auto; }
.pv { display: flex; align-items: center; gap: .6rem; padding: .45rem .6rem; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--surface); }
.pv .grow { flex: 1 1 auto; display: grid; min-width: 0; }
.pv small { color: var(--ink-2); }
.pv-row { min-width: 3.6rem; color: var(--ink-2); font-size: .8rem; }
.pv-add { border-left: 4px solid var(--ok); }
.pv-link, .pv-update { border-left: 4px solid var(--brand); }
.pv-skip { border-left: 4px solid var(--danger); background: var(--danger-bg); }
.note { border-top: 1px solid var(--line); padding-top: .5rem; display: grid; gap: .2rem; }
.note p { margin: 0; white-space: pre-wrap; }

/* Guro attendance */
.rollcall { padding-bottom: 6rem; }
.att-counts { display: flex; flex-wrap: wrap; gap: .35rem; margin: 0; }
.mk { display: inline-block; padding: .15rem .55rem; border-radius: 999px; font-size: .8rem; font-weight: 700; background: var(--line); }
.mk.ok { background: var(--ok-bg); color: var(--ok); }
.mk-P { --mk: var(--ok); } .mk-A { --mk: var(--danger); } .mk-L { --mk: #B54708; } .mk-E { --mk: #3B5BA9; }
.att-counts .mk-P, .att-counts .mk-A, .att-counts .mk-L, .att-counts .mk-E { color: var(--mk); background: color-mix(in srgb, var(--mk) 12%, #fff); }
.att-list { display: grid; gap: .35rem; }
.att-row { display: flex; align-items: center; gap: .5rem; padding: .35rem .5rem; border-radius: var(--r-sm); background: var(--surface); border: 1.5px solid var(--line); }
.att-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; font-size: .95rem; }
.mk-btns { display: flex; gap: .25rem; flex: 0 0 auto; }
.mk-btn { width: 40px; height: 40px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--surface); font: inherit; font-weight: 800; color: var(--ink-2); cursor: pointer; }
.mk-btn.on { background: var(--mk); border-color: var(--mk); color: #fff; }
.att-foot { display: grid; gap: .6rem; justify-items: center; margin-top: .5rem; }
.att-foot .btn { width: 100%; }
.today-row { display: flex; align-items: center; gap: .6rem; padding: .45rem .6rem; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--surface); }
.today-row.on { border-color: var(--brand); }
.today-row .grow { display: grid; min-width: 0; }
.today-row > .num { min-width: 4.2rem; color: var(--ink-2); font-size: .85rem; }
.alert-card { border-color: var(--danger); background: var(--danger-bg); }
.month-nav h2 { margin: 0; }
.sf2-wrap { overflow-x: auto; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
table.sf2 { border-collapse: collapse; font-size: .8rem; }
.sf2 th, .sf2 td { border: 1px solid var(--line); padding: .2rem .25rem; text-align: center; min-width: 1.7rem; }
.sf2 .sticky { position: sticky; left: 0; background: var(--surface); text-align: left; min-width: 9.5rem; max-width: 11rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; z-index: 1; }
.sf2 .sticky .chip { margin-left: .3rem; }
.sf2 td.mk-A, .sf2 td.mk-E { color: var(--danger); font-weight: 800; }
.sf2 td.mk-L { color: #B54708; font-weight: 800; }
.sf2 td.mk-P { color: var(--ok); }
.sf2 .nc { background: #EEECE6; color: var(--ink-2); }
.sf2 tr.flag td.sticky { color: var(--danger); font-weight: 700; }
.sf2 tr.tot td { font-weight: 700; background: #F3F2EC; }
.sf2 tr.tot td.sticky { background: #F3F2EC; }
.day-btn { display: grid; border: 0; background: none; font: inherit; color: inherit; cursor: pointer; padding: 0; line-height: 1.1; width: 100%; }
.day-btn small { color: var(--ink-2); font-size: .65rem; }
.bad { color: var(--danger); }
.rollcall > * { min-width: 0; }
.rollcall > .row input[type="date"] { width: auto; flex: 0 1 11rem; min-width: 0; }
.att-list, .rollcall { grid-template-columns: minmax(0, 1fr); }
.att-row .att-name { flex: 1 1 auto; white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.2; }
.kv dd.num { white-space: nowrap; text-align: right; }

/* Guro class record */
.record > * { min-width: 0; }
.record { grid-template-columns: minmax(0, 1fr); }
.record-tabs { flex-wrap: wrap; }
.add-cols { flex-wrap: wrap; gap: .4rem; }
.grid-wrap { overflow-x: auto; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); max-height: 70vh; }
table.grid { border-collapse: collapse; font-size: .85rem; }
.grid th, .grid td { border: 1px solid var(--line); padding: 0; text-align: center; }
.grid thead th { position: sticky; top: 0; background: var(--surface); z-index: 2; padding: .2rem; }
.grid .sticky { position: sticky; left: 0; background: var(--surface); text-align: left; padding: .25rem .4rem; min-width: 8.5rem; max-width: 10rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; z-index: 1; }
.grid thead th.sticky { z-index: 3; }
.grid td.num { padding: .25rem .4rem; min-width: 2.8rem; font-weight: 700; }
.grid td.low, .grid .low { color: var(--danger); }
.grid th.col-WW { background: #EEF4FF; } .grid th.col-PT { background: #EFF8F1; } .grid th.col-EX { background: #FFF6E6; }
.col-btn { display: grid; gap: 0; border: 0; background: none; font: inherit; color: inherit; cursor: pointer; min-width: 3.2rem; max-width: 6rem; padding: .1rem; line-height: 1.15; }
.col-btn span { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.col-btn small { color: var(--ink-2); font-size: .68rem; }
input.sc { width: 3.4rem; min-height: 40px; border: 0; border-radius: 0; text-align: center; padding: 0 .2rem; font: inherit; font-variant-numeric: tabular-nums; background: transparent; }
input.sc:focus { outline: 2px solid var(--brand); outline-offset: -2px; background: color-mix(in srgb, var(--brand) 8%, #fff); }
input.sc.blank { background: #FAF8F2; }
input.sc.bad { background: var(--danger-bg); color: var(--danger); }
.dist { display: grid; gap: .3rem; margin-top: .5rem; }
.dist-row { display: grid; grid-template-columns: 9.5rem 1fr 2rem; gap: .4rem; align-items: center; font-size: .85rem; }
.dist-bar { height: .7rem; background: var(--line); border-radius: 999px; overflow: hidden; }
.dist-bar i { display: block; height: 100%; background: var(--brand); }

/* Guro tasks */
.tasks-card { display: grid; gap: .5rem; }
.task-counts { display: flex; flex-wrap: wrap; gap: .4rem; }
.task-counts .chip { border: 0; cursor: pointer; font: inherit; font-size: .8rem; font-weight: 700; }
.task-row { display: flex; align-items: center; gap: .6rem; padding: .35rem .6rem; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--surface); }
.task-row.prio-high { border-left: 4px solid var(--danger); }
.task-row.is-done .task-open strong { text-decoration: line-through; color: var(--ink-2); }
.task-check { width: 24px; height: 24px; min-height: 0; flex: 0 0 auto; accent-color: var(--brand); }
.task-open { flex: 1 1 auto; min-width: 0; display: grid; gap: .1rem; text-align: left; border: 0; background: none; font: inherit; color: inherit; cursor: pointer; padding: .25rem 0; }
.task-open strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-meta { color: var(--ink-2); }
.task-meta .due-overdue { color: var(--danger); font-weight: 700; }
.task-meta .due-today { color: var(--brand); font-weight: 700; }
.check-item input[type="checkbox"] { width: 20px; height: 20px; min-height: 0; }
.struck { text-decoration: line-through; color: var(--ink-2); }

/* Guro schedule and lesson plans */
.day-card.is-today { border-color: var(--brand); }
.sched-time { min-width: 6.5rem; color: var(--ink-2); font-size: .8rem; }
.plan-slot { display: block; }
.plan-link { font-size: .85rem; padding: 0; }
.plan-link.ok { color: var(--ok); text-decoration: none; font-weight: 700; }
.plan-peek { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.plan-form textarea { resize: vertical; min-height: 4.5rem; line-height: 1.4; }
.plan-save { position: sticky; bottom: .5rem; z-index: 2; box-shadow: 0 4px 14px rgba(0,0,0,.12); }
.dll-head { display: grid; gap: .15rem; text-align: center; }
.dll-head h1 { margin: 0; font-size: 1.2rem; }
.dll-head p { margin: 0; }
table.dll { border-collapse: collapse; width: 100%; font-size: .85rem; }
.dll th, .dll td { border: 1px solid #999; padding: .35rem .45rem; vertical-align: top; text-align: left; }
.dll thead th { background: #F3F2EC; }
.dll tbody th { width: 8rem; background: #FAF9F5; }
.dll .pre { white-space: pre-wrap; min-width: 10rem; }
@media print {
  @page { size: landscape; margin: 12mm; }
  body, .tenant { background: #fff !important; }
  .appbar, .no-print, .banner, .toast, .sheet-backdrop { display: none !important; }
  .screen { padding: 0 !important; max-width: none !important; }
  .table-wrap { overflow: visible !important; border: 0 !important; }
  .dll { font-size: 10pt; }
  .dll th, .dll td { border-color: #000; }
}

/* Guro dashboard and reports */
.quick-row { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: .5rem; }
.quick-row:empty { display: none; }
.quick-btn { display: grid; justify-items: center; gap: .15rem; padding: .55rem .3rem; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-size: .82rem; font-weight: 700; cursor: pointer; min-height: 64px; }
.quick-btn span { font-size: 1.3rem; }
.risk-card { display: grid; gap: .5rem; border-color: color-mix(in srgb, var(--danger) 35%, var(--line)); }
.risk-row { display: flex; gap: .5rem; align-items: flex-start; padding: .5rem .6rem; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.risk-row .grow { flex: 1 1 auto; min-width: 0; display: grid; gap: .15rem; }
.risk-reasons { margin: 0; padding-left: 1rem; font-size: .85rem; }
.risk-actions { display: grid; gap: .3rem; flex: 0 0 auto; }
.period-row { gap: .35rem; }
.period-row input { flex: 1 1 0; min-width: 0; }
.report-table td.name { white-space: nowrap; }
.report-table tr.grp td { background: #F3F2EC; font-weight: 700; }
.report-table td.bad { color: var(--danger); font-weight: 700; }
@media print { .report-summary { border: 0 !important; padding: 0 !important; } }

/* Guro upload */
.kind-icon { font-size: 1.5rem; flex: 0 0 auto; }
.upload-row { align-items: center; padding: .4rem 0; border-top: 1px solid var(--line); }
.upload-row .grow { display: grid; gap: .1rem; min-width: 0; }

/* ---------- Guro calendar (G7.1) ---------- */
.banner.stack { flex-direction: column; align-items: flex-start; gap: .2rem; }
.banner.stack p { margin: 0; }
.upcoming-card { display: grid; gap: .5rem; }
.cal { padding: .6rem; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
.cal-head span { text-align: center; font-size: .75rem; font-weight: 600; opacity: .7; padding: .2rem 0; }
.cal-cell { position: relative; min-height: 46px; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 3px;
  padding: .35rem 0 .25rem; border: 1px solid transparent; border-radius: var(--r-sm); background: none; color: var(--ink); font: inherit; cursor: pointer; }
.cal-cell.empty { cursor: default; }
.cal-cell .n { font-size: .95rem; font-variant-numeric: tabular-nums; }
.cal-cell.wkend .n { opacity: .6; }
.cal-cell.off { background: var(--danger-bg); }
.cal-cell.off .n { color: var(--danger); font-weight: 700; opacity: 1; }
.cal-cell.today { border-color: var(--brand); }
.cal-cell.today .n { font-weight: 800; }
.cal-cell.on { background: var(--brand); }
.cal-cell.on .n { color: var(--brand-ink); opacity: 1; }
.cal-cell .dots { display: flex; gap: 2px; }
.cal-cell .dots i, .cal-legend i { display: inline-block; width: 6px; height: 6px; border-radius: 50%; }
.cal-legend { display: flex; flex-wrap: wrap; gap: .35rem .9rem; font-size: .8rem; opacity: .85; }
.cal-legend span { display: inline-flex; align-items: center; gap: .3rem; }
.cal-legend i { width: 9px; height: 9px; }
.cal-item { display: flex; align-items: center; gap: .6rem; width: 100%; text-align: left; padding: .6rem .7rem; border: 1px solid var(--line);
  border-radius: var(--r-sm); background: var(--surface); color: var(--ink); font: inherit; }
button.cal-item { cursor: pointer; min-height: var(--tap); }
.cal-item .grow { display: grid; gap: .1rem; min-width: 0; }
.cal-bar { align-self: stretch; width: 4px; border-radius: 2px; flex: none; }
.k-regular { background: #B42318; }
.k-special { background: #E8590C; }
.k-special_working { background: #868E96; }
.k-school_break { background: #7048E8; }
.k-school_event { background: #1971C2; }
.k-no_class { background: #C2255C; }
.k-event { background: #2B8A3E; }
/* ---------- Requests to Laxis (G7.2) ---------- */
.request-card { display: grid; gap: .4rem; }
.request-text { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.request-reply { margin: 0; padding: .5rem .7rem; border-radius: var(--r-sm); background: var(--ok-bg); white-space: pre-wrap; overflow-wrap: anywhere; }
.request-chip.st-new { background: var(--warn-bg); }
.request-chip.st-planned { background: #E7F0FD; color: #1864AB; }
.request-chip.st-done { background: var(--ok-bg); color: var(--ok); }
.request-chip.st-declined { background: var(--bg); color: #6B7280; }
/* ---------- Guro levels and college grading (G7.3) ---------- */
.level-picks { display: grid; gap: .6rem; }
.level-pick { display: grid; gap: .3rem; }
.level-name { font-weight: 600; opacity: .75; }
.cg-rows { display: grid; gap: .4rem; }
.cg-row { gap: .4rem; align-items: center; }
.cg-row > input:not(.num-in) { flex: 1 1 auto; min-width: 0; }
.cg-row .num-in { width: 4.6rem; flex: none; text-align: right; }
/* ---------- What needs your attention (G8) ---------- */
.attn-card { display: grid; gap: .5rem; border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.attn-item { display: flex; gap: .6rem; align-items: flex-start; padding: .7rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.attn-item.k-urgent { border-left: 4px solid var(--danger); }
.attn-item.k-warn { border-left: 4px solid #E8590C; }
.attn-item.k-todo { border-left: 4px solid #1971C2; }
.attn-item.k-info { border-left: 4px solid #868E96; }
.attn-item.k-good { border-left: 4px solid var(--ok); background: var(--ok-bg); }
.attn-icon { font-size: 1.1rem; line-height: 1.4; }
.attn-body { display: grid; gap: .25rem; min-width: 0; overflow-wrap: anywhere; }
.attn-actions { display: flex; flex-wrap: wrap; gap: .3rem .9rem; align-items: center; margin-top: .2rem; }
.contact-row { gap: .4rem; }
/* ---------- Paupahan: spaces grid (P1) ---------- */
.pau-counts { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: .35rem; text-align: center; }
.pau-counts > div { display: grid; gap: .1rem; padding: .45rem .2rem; border-radius: var(--r-sm); background: var(--bg); min-width: 0; }
.pau-counts strong { font-size: 1.25rem; }
.pau-counts span { font-size: .72rem; color: var(--ink-2); overflow-wrap: anywhere; }
.pau-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: .5rem; }
.pau-unit { display: grid; gap: .1rem; align-content: start; min-height: 74px; padding: .5rem .55rem; border-radius: var(--r-sm); border: 1.5px solid var(--line);
  background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; min-width: 0; }
.pau-unit strong { font-size: .92rem; line-height: 1.2; overflow-wrap: anywhere; }
.pau-unit small { font-size: .74rem; color: var(--ink-2); }
.pau-unit .pau-st { font-weight: 700; }
.pau-unit.bed { min-height: 52px; padding: .4rem .45rem; }
.st-vacant { border-style: dashed; border-color: #ADB5BD; }
.pau-unit.st-vacant .pau-st, .pau-count.st-vacant strong { color: #495057; }
.st-occupied { background: var(--ok-bg); border-color: color-mix(in srgb, var(--ok) 45%, var(--line)); }
.pau-unit.st-occupied .pau-st, .pau-count.st-occupied strong { color: var(--ok); }
.st-reserved { background: #E7F0FD; border-color: #A5C8F5; }
.pau-unit.st-reserved .pau-st, .pau-count.st-reserved strong { color: #1864AB; }
.st-repair { background: var(--warn-bg); border-color: #F3D27A; }
.pau-unit.st-repair .pau-st, .pau-count.st-repair strong { color: #8A5A00; }
.pau-counts .pau-count { border: 0; }
.pau-room { grid-column: 1 / -1; display: grid; gap: .45rem; padding: .55rem; border: 1.5px solid var(--line); border-radius: var(--r-sm); }
.pau-room-head { display: flex; flex-wrap: wrap; gap: .2rem .6rem; align-items: baseline; text-decoration: none; color: var(--ink); text-align: left; }
.pau-beds { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: .4rem; }
.pau-badge { justify-self: start; padding: .15rem .6rem; border-radius: 999px; border: 1.5px solid var(--line); font-weight: 700; font-size: .85rem; }
.pau-preview { margin: 0; padding: .55rem .7rem; border-radius: var(--r-sm); background: var(--bg); font-weight: 600; }
.pau-preview:empty { display: none; }
@media (max-width: 360px) { .pau-counts { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* ---------- Paupahan: renters, move-in, contract (P2) ---------- */
.pau-warn { border-color: #F3D27A; }
.pau-warn-list { margin: 0; padding-left: 1.1rem; display: grid; gap: .35rem; }
.pau-held { display: grid; gap: .3rem; padding: .6rem .7rem; border-radius: var(--r-sm); background: var(--bg); }
.pau-held .r-line, .pau-summary-list .r-line, .pau-entry .r-line { display: flex; justify-content: space-between; gap: .75rem; }
.pau-summary-list .r-line span { color: var(--ink-2); }
.pau-summary-list .r-line strong { text-align: right; overflow-wrap: anywhere; }
.pau-entry { display: grid; gap: .15rem; padding: .5rem 0; border-bottom: 1px solid var(--line); }
.pau-entry.voided .r-line { text-decoration: line-through; opacity: .6; }
.pau-past { opacity: .8; }
.pau-sample { margin: 0; padding: .55rem .7rem; border-radius: var(--r-sm); background: var(--warn-bg); font-weight: 700; font-size: .9rem; }
.pau-sample.small { background: none; padding: 0; font-weight: 500; font-size: .75rem; color: var(--ink-2); }
.pau-paper { background: #fff; color: #111; border: 1.5px solid var(--line); border-radius: var(--r-sm); padding: 1.2rem; display: grid; gap: .7rem; line-height: 1.5; }
.pau-paper h1 { font-size: 1.25rem; text-align: center; margin: 0; }
.pau-paper h2 { font-size: 1rem; margin: 0; }
.pau-paper ol { margin: 0; padding-left: 1.2rem; display: grid; gap: .45rem; }
.pau-pre { white-space: pre-wrap; margin: 0; }
.pau-sign { display: grid; grid-template-columns: 1fr 1fr; gap: 1.6rem 1rem; margin-top: 1.4rem; }
.pau-sign > div { display: grid; gap: .2rem; }
.pau-line { display: block; border-bottom: 1px solid #111; height: 1.8rem; }
.pau-sign small { font-size: .75rem; }
/* ---------- Paupahan: bills and payments (P3) ---------- */
.pau-unit.pay-paid { background: var(--ok-bg); border-color: color-mix(in srgb, var(--ok) 45%, var(--line)); }
.pau-unit.pay-due { background: #FFF4E0; border-color: #F0C36D; }
.pau-unit.pay-overdue { background: var(--danger-bg); border-color: color-mix(in srgb, var(--danger) 45%, var(--line)); }
.pau-unit .pau-payword { font-weight: 700; }
.pau-unit.pay-paid .pau-payword { color: var(--ok); }
.pau-unit.pay-due .pau-payword { color: #8A5A00; }
.pau-unit.pay-overdue .pau-payword { color: var(--danger); }
.pau-unit.pay-paid .pau-st, .pau-unit.pay-due .pau-st, .pau-unit.pay-overdue .pau-st { color: var(--ink); font-weight: 600; }
.pau-legend { display: flex; flex-wrap: wrap; gap: .3rem .9rem; margin: 0; font-size: .78rem; color: var(--ink-2); }
.pau-legend span { display: inline-flex; align-items: center; gap: .3rem; }
.pau-legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; border: 1.5px solid var(--line); }
.pau-legend i.pay-paid { background: var(--ok-bg); border-color: var(--ok); }
.pau-legend i.pay-due { background: #FFF4E0; border-color: #F0C36D; }
.pau-legend i.pay-overdue { background: var(--danger-bg); border-color: var(--danger); }
.pau-legend i.st-vacant { background: var(--surface); border-style: dashed; border-color: #ADB5BD; }
.pau-pay { display: inline-block; justify-self: start; padding: .1rem .5rem; border-radius: 999px; font-size: .78rem; font-weight: 700; white-space: nowrap; }
.pau-pay.pay-paid { background: var(--ok-bg); color: var(--ok); }
.pau-pay.pay-due { background: #FFF4E0; color: #8A5A00; }
.pau-pay.pay-overdue { background: var(--danger-bg); color: var(--danger); }
.pau-total .big, .card .big { font-size: 1.6rem; font-weight: 800; }
.pau-owe .r-line, .card > .r-line, .pau-lines .r-line { display: flex; justify-content: space-between; gap: .75rem; align-items: baseline; }
.pau-legal { display: grid; gap: .3rem; padding: .6rem .7rem; border-radius: var(--r-sm); background: var(--bg); border-left: 4px solid #868E96; }
.pau-legal p { margin: 0; font-size: .88rem; }
.pau-bill { border: 1.5px solid var(--line); border-radius: var(--r-sm); padding: .1rem .6rem; }
.pau-bill summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: .2rem .6rem; padding: .5rem 0; cursor: pointer; min-height: 44px; }
.pau-bill summary .grow { flex: 1 1 12rem; min-width: 0; }
.pau-lines { display: grid; gap: .35rem; padding: 0 0 .6rem; }
.pau-receipt { margin: 0; padding: .8rem; background: #fff; color: #111; border: 1px dashed var(--line); border-radius: var(--r-sm); white-space: pre-wrap; font-family: ui-monospace, "Courier New", monospace; font-size: .85rem; line-height: 1.45; overflow-wrap: anywhere; }
/* ---------- Paupahan: kuryente and tubig (P4) ---------- */
.pau-bignum { font-size: 1.6rem; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: .02em; min-height: 56px; text-align: right; flex: 1 1 auto; min-width: 0; }
.pau-unitlabel { font-weight: 700; color: var(--ink-2); min-width: 2.6rem; }
.pau-usage { margin: 0; font-weight: 600; font-size: .92rem; }
.pau-usage.ok { color: var(--ok); }
.pau-usage.warn { color: #8A5A00; }
.pau-usage.bad { color: var(--danger); }
.pau-read .row { gap: .5rem; }
.pau-util { display: grid; gap: .35rem; padding: .6rem 0; border-top: 1px solid var(--line); }
.pau-util:first-of-type { border-top: 0; }
.pau-meter-row { display: flex; align-items: center; gap: .4rem; padding: .45rem 0; border-bottom: 1px solid var(--line); }
.pau-meter-row .grow { flex: 1; min-width: 0; }
.pau-meter-row .chip-btn { min-width: 56px; }
.num-in { width: 4.6rem; flex: none; text-align: right; }
/* ---------- Paupahan: move-out (P5) ---------- */
.pau-check { display: grid; gap: .35rem; padding: .45rem 0; border-bottom: 1px solid var(--line); }
.pau-check .row { gap: .35rem; }
.pau-check .chip-btn { min-height: 36px; padding: .2rem .6rem; }
.pau-refund { display: flex; justify-content: space-between; align-items: baseline; gap: .75rem; padding: .7rem .8rem; border-radius: var(--r-sm); background: var(--ok-bg); }
.pau-refund strong { font-size: 1.4rem; color: var(--ok); }
.pau-checklist { margin: 0; padding-left: 1.1rem; display: grid; gap: .25rem; }
.r-line.bad strong { color: var(--danger); }
/* ---------- Paupahan: reports (P6) ---------- */
.pau-kpi { display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; }
.pau-kpi .big { font-size: 2rem; }
.pau-refund.neg { background: var(--danger-bg); }
.pau-refund.neg strong { color: var(--danger); }
/* ---------- Paupahan: listings (P7) ---------- */
.pau-photos { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .4rem; }
.pau-photo { position: relative; aspect-ratio: 1; border-radius: var(--r-sm); overflow: hidden; border: 1.5px dashed var(--line); background: var(--bg); display: grid; place-items: center; font: inherit; color: var(--ink-2); cursor: pointer; }
.pau-photo img { width: 100%; height: 100%; object-fit: cover; }
.pau-photo .btn { position: absolute; top: 4px; right: 4px; min-height: 28px; padding: 0 .45rem; }
.pau-card-preview { width: 100%; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--bg); aspect-ratio: 4 / 5; object-fit: contain; }
@page contract { size: A4 portrait; margin: 16mm; }
@media print {
  .pau-contract { page: contract; padding: 0 !important; max-width: none !important; }
  .pau-contract .pau-paper { border: 0; padding: 0; font-size: 11pt; }
  .pau-contract .pau-sample:not(.small) { background: none; border: 1px solid #000; }
}

/* ---------- Dashboard kit (dash.js): same pieces for every business type and /admin ----------
   Phone: one column in this order: banner → quote → stats (2 per row) → insights → charts → quick actions →
   notifications → lists → snapshot. Laptop: banner + quote on top, stats across, main column + side column. */
.screen.dash-screen { max-width: 74rem; }
.dash { display: grid; gap: 1rem; min-width: 0; }
.dash-col { display: contents; }
.dash > *, .dash-col > * { min-width: 0; }
.dash [data-area="banner"] { order: 1; } .dash [data-area="quote"] { order: 2; } .dash [data-area="stats"] { order: 3; }
.dash [data-area="insights"] { order: 4; } .dash [data-area="charts"] { order: 5; } .dash [data-area="actions"] { order: 6; }
.dash [data-area="notifications"] { order: 7; } .dash [data-area="lists"] { order: 8; } .dash [data-area="snapshot"] { order: 9; }
.dash [data-area="extra"] { order: 10; } .dash [data-area="top"] { order: 0; }
.dash-top { display: grid; gap: .6rem; }
@media (min-width: 900px) {
  .dash { grid-template-columns: minmax(0, 1fr) minmax(17rem, 22rem); grid-template-areas: "banner quote" "stats stats" "main side"; align-items: start; }
  .dash.has-top { grid-template-areas: "top top" "banner quote" "stats stats" "main side"; }
  .dash.no-quote { grid-template-areas: "banner banner" "stats stats" "main side"; }
  .dash.no-quote.has-top { grid-template-areas: "top top" "banner banner" "stats stats" "main side"; }
  .dash .dash-top { grid-area: top; }
  .dash [data-area="banner"] { grid-area: banner; } .dash [data-area="quote"] { grid-area: quote; } .dash [data-area="stats"] { grid-area: stats; }
  .dash-col { display: grid; gap: 1rem; align-content: start; }
  .dash-main { grid-area: main; } .dash-side { grid-area: side; }
  .dash [data-area] { order: 0; }
}
.d-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 1rem; display: grid; gap: .75rem; min-width: 0; }
.d-card h2 { font-size: 1.02rem; margin: 0; }
.d-head { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.d-head h2 { flex: 1 1 auto; }
.d-link { background: none; border: 0; color: var(--brand-text, var(--brand)); font: inherit; font-weight: 700; font-size: .9rem; cursor: pointer; min-height: 44px; padding: 0 .3rem; }
.pill-btn { display: inline-flex; align-items: center; justify-content: center; gap: .35rem; min-height: 44px; padding: 0 1rem; border-radius: 999px; border: 1px solid var(--line); background: var(--surface-2, var(--surface)); color: var(--ink); font: inherit; font-weight: 700; font-size: .92rem; cursor: pointer; text-decoration: none; white-space: nowrap; }
.pill-btn.primary { background: var(--accent-ui, var(--accent)); color: var(--accent-ui-ink, var(--accent-ink)); border-color: transparent; }
.pill-btn.sm { min-height: 44px; padding: 0 .9rem; font-size: .88rem; }
.d-dot { display: inline-block; width: .65rem; height: .65rem; border-radius: 999px; margin-right: .3rem; vertical-align: middle; }

/* Banner */
.d-banner { position: relative; overflow: hidden; border-radius: 18px; padding: 1.2rem; display: grid; gap: .6rem; color: var(--banner-ink, var(--brand-ink));
  background: linear-gradient(135deg, var(--brand), color-mix(in srgb, var(--brand) 62%, #000)); }
:root[data-theme="dark"] .d-banner { color: var(--ink); border: 1px solid var(--line);
  background: radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--brand-text, var(--brand)) 34%, transparent), transparent 60%), var(--surface); }
.d-eyebrow { font-size: .74rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; opacity: .85; }
.d-banner h1 { font-size: clamp(1.3rem, 5.4vw, 1.9rem); line-height: 1.15; }
.d-banner p { opacity: .92; }
.d-banner .d-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.d-banner .pill-btn:not(.primary) { background: color-mix(in srgb, currentColor 12%, transparent); color: inherit; border-color: color-mix(in srgb, currentColor 28%, transparent); }

/* Quote of the day */
.d-quote blockquote { margin: 0; font-size: 1.05rem; font-weight: 600; line-height: 1.4; }
.d-quote figcaption { color: var(--ink-2); font-size: .9rem; }
.d-quote .d-date { color: var(--ink-2); font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }

/* Stat cards: 2 per row on a phone, 4 across on a laptop */
.d-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
@media (min-width: 900px) { .d-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.d-stat { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: .85rem; display: grid; gap: .3rem; align-content: start; min-width: 0; }
.d-stat-top { display: flex; align-items: flex-start; gap: .4rem; }
.d-stat-title { flex: 1; font-size: .82rem; font-weight: 700; color: var(--ink-2); line-height: 1.25; }
.d-icon { flex: none; width: 2rem; height: 2rem; border-radius: 999px; display: grid; place-items: center; font-size: 1rem;
  background: color-mix(in srgb, var(--brand-text, var(--brand)) 16%, transparent); }
.d-stat-value { font-size: clamp(1.15rem, 5.2vw, 1.6rem); font-weight: 800; letter-spacing: -.01em; overflow-wrap: anywhere; line-height: 1.15; }
.d-stat-sub { color: var(--ink-2); font-size: .8rem; line-height: 1.3; }
.d-spark { width: 100%; height: 28px; display: block; }

/* Charts */
.d-chart svg { width: 100%; height: auto; display: block; overflow: visible; touch-action: manipulation; }
.d-chart svg:focus-visible { outline: 3px solid var(--accent-ui, var(--accent)); outline-offset: 2px; border-radius: 8px; }
.d-readout { min-height: 2.6rem; font-size: .9rem; display: flex; flex-wrap: wrap; gap: .15rem .8rem; align-items: center; }
.d-readout strong { font-weight: 800; }
.d-legend { display: flex; flex-wrap: wrap; gap: .3rem .9rem; font-size: .85rem; color: var(--ink-2); list-style: none; margin: 0; padding: 0; }
.d-legend li { display: inline-flex; align-items: center; gap: .35rem; }
.d-legend i { width: .75rem; height: .75rem; border-radius: 3px; display: inline-block; }
.d-axis { font-size: 10px; fill: var(--ink-2); }
.d-grid { stroke: var(--line); stroke-width: 1; }
.d-numbers summary { cursor: pointer; color: var(--ink-2); font-size: .85rem; font-weight: 700; min-height: 36px; display: flex; align-items: center; }
.d-numbers table { width: 100%; border-collapse: collapse; font-size: .85rem; }
.d-numbers td, .d-numbers th { padding: .3rem .2rem; border-bottom: 1px solid var(--line); text-align: right; }
.d-numbers td:first-child, .d-numbers th:first-child { text-align: left; }
.d-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.d-donut-wrap { display: grid; grid-template-columns: minmax(7rem, 9.5rem) 1fr; gap: 1rem; align-items: center; }
.d-donut-wrap .d-legend { display: grid; gap: .35rem; }
.d-donut-wrap .d-legend li { justify-content: space-between; gap: .6rem; color: var(--ink); }
.d-donut-wrap .d-legend span { color: var(--ink-2); }
.d-charts { display: grid; gap: 1rem; }
@media (min-width: 1000px) { .d-charts.two { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.d-chart svg { max-height: 360px; }

/* Insights */
.d-insights { display: grid; gap: .6rem; }
.d-insight { display: flex; gap: .7rem; align-items: flex-start; padding: .8rem .9rem; border-radius: 14px; background: color-mix(in srgb, var(--brand-text, var(--brand)) 10%, var(--surface)); border: 1px solid color-mix(in srgb, var(--brand-text, var(--brand)) 26%, var(--line)); font-weight: 600; line-height: 1.35; }
.d-insight.warn { background: var(--warn-bg); border-color: color-mix(in srgb, #E0A82E 45%, var(--line)); }
.d-insight.bad { background: var(--danger-bg); border-color: color-mix(in srgb, var(--danger) 40%, var(--line)); }
.d-insight.good { background: var(--ok-bg); border-color: color-mix(in srgb, var(--ok) 40%, var(--line)); }
.d-insight-icon { font-size: 1.2rem; line-height: 1.2; }

/* Quick actions 2×2, notifications, snapshot */
.d-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.d-tile { display: grid; justify-items: center; align-content: center; gap: .35rem; min-height: 84px; padding: .6rem .4rem; border-radius: 14px; border: 1px solid var(--line); background: var(--surface-2, var(--bg)); color: var(--ink); font: inherit; font-weight: 700; font-size: .88rem; text-align: center; cursor: pointer; }
.d-tile span:first-child { font-size: 1.4rem; }
.d-count { background: var(--accent-ui, var(--accent)); color: var(--accent-ui-ink, var(--accent-ink)); border-radius: 999px; font-size: .75rem; font-weight: 800; padding: .05rem .5rem; }
.d-note { display: grid; gap: .15rem; padding: .6rem 0; border-top: 1px solid var(--line); text-align: left; background: none; border-left: 0; border-right: 0; border-bottom: 0; color: var(--ink); font: inherit; cursor: pointer; width: 100%; }
.d-note:first-of-type { border-top: 0; }
.d-note small { color: var(--ink-2); }
.d-snap { display: grid; margin: 0; }
.d-snap div { display: flex; justify-content: space-between; gap: .8rem; padding: .5rem 0; border-top: 1px solid var(--line); }
.d-snap div:first-child { border-top: 0; }
.d-snap dt { color: var(--ink-2); }
.d-snap dd { margin: 0; font-weight: 800; font-variant-numeric: tabular-nums; text-align: right; }

/* Status pills */
.pill { display: inline-block; padding: .15rem .6rem; border-radius: 999px; font-size: .78rem; font-weight: 800; white-space: nowrap; background: var(--surface-2, var(--line)); color: var(--ink); }
.pill.ok { background: var(--ok-bg); color: var(--ok); }
.pill.warn { background: var(--warn-bg); color: #8A5A00; }
:root[data-theme="dark"] .pill.warn { color: #F2C66D; }
.pill.bad { background: var(--danger-bg); color: var(--danger); }
.pill.info { background: color-mix(in srgb, var(--brand-text, var(--brand)) 16%, transparent); color: var(--brand-text, var(--brand)); }

/* Table → stacked cards on a phone (no sideways page scroll) */
.d-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.d-table th { text-align: left; color: var(--ink-2); font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; padding: .5rem .4rem; border-bottom: 1px solid var(--line); }
.d-table td { padding: .6rem .4rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.d-table .r { text-align: right; font-variant-numeric: tabular-nums; }
@media (max-width: 640px) {
  .d-table thead { display: none; }
  .d-table, .d-table tbody { display: grid; gap: .5rem; }
  .d-table tr { display: grid; grid-template-columns: 1fr auto; gap: .2rem .8rem; padding: .7rem .8rem; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-2, var(--bg)); }
  .d-table td { border: 0; padding: 0; display: flex; justify-content: space-between; gap: .6rem; grid-column: 1 / -1; }
  .d-table td[data-label]::before { content: attr(data-label); color: var(--ink-2); font-size: .82rem; }
  .d-table td.primary { font-weight: 800; }
  .d-table td.primary::before { content: none; }
  .d-table td.act { justify-content: flex-end; }
}

/* Empty, loading, offline */
.d-empty { text-align: center; color: var(--ink-2); padding: 1.2rem .5rem; display: grid; gap: .3rem; justify-items: center; }
.d-empty span:first-child { font-size: 1.6rem; }
.d-skel { border-radius: 16px; background: linear-gradient(90deg, var(--surface) 25%, var(--surface-2, var(--line)) 50%, var(--surface) 75%); background-size: 200% 100%; animation: d-shimmer 1.4s infinite linear; }
@keyframes d-shimmer { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .d-skel { animation: none; } }
.d-offline { display: flex; gap: .6rem; align-items: center; padding: .7rem .9rem; border-radius: 14px; background: var(--warn-bg); border: 1px solid color-mix(in srgb, #E0A82E 45%, var(--line)); font-size: .92rem; }

/* Left menu on a laptop (dash.js sideNav). Phones keep the top bar and Home tiles. */
.side-nav { display: none; }
@media (min-width: 1000px) {
  body.has-side .side-nav { display: flex; flex-direction: column; gap: 1rem; position: fixed; inset: 0 auto 0 0; width: 15rem; z-index: 6; overflow-y: auto;
    padding: 1rem .7rem; background: var(--surface); border-right: 1px solid var(--line); }
  body.has-side #app { margin-left: 15rem; }
  body.has-side::before { left: 15rem; }
}
.side-brand { display: flex; align-items: center; gap: .6rem; padding: .3rem .4rem; min-width: 0; }
.side-brand strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .2rem; }
.side-nav li button { display: flex; align-items: center; gap: .65rem; width: 100%; min-height: 44px; padding: 0 .75rem; border: 0; border-radius: 12px;
  background: none; color: var(--ink); font: inherit; font-weight: 600; text-align: left; cursor: pointer; }
.side-nav li button:hover { background: var(--surface-2, var(--bg)); }
.side-nav li button.on { background: var(--accent-ui, var(--brand)); color: var(--accent-ui-ink, var(--brand-ink)); }
.side-label { flex: 1; }
.side-icon { width: 1.4rem; text-align: center; }

/* Older status colors, readable in dark mode too */
:root[data-theme="dark"] .stock-badge.low, :root[data-theme="dark"] .pau-pay.pay-due, :root[data-theme="dark"] .chip-pending_review { background: var(--warn-bg); color: #F2C66D; }
:root[data-theme="dark"] .expiry-badge.expiring { background: #3A2412; color: #F5B27A; }
:root[data-theme="dark"] .pau-unit.pay-due, :root[data-theme="dark"] .pau-legend i.pay-due { background: #3A2E14; border-color: #7A5B1E; }
:root[data-theme="dark"] .pau-unit.pay-due .pau-payword, :root[data-theme="dark"] .pau-usage.warn, :root[data-theme="dark"] .inv-card.low strong { color: #F2C66D; }
:root[data-theme="dark"] .inv-card.expiring strong, :root[data-theme="dark"] .expiry-btn { color: #F5B27A; }
:root[data-theme="dark"] .st-reserved, :root[data-theme="dark"] .chip-trial, :root[data-theme="dark"] .request-chip.st-planned { background: #16263D; border-color: #2D4D78; color: #9CC3F5; }
:root[data-theme="dark"] .pau-unit.st-reserved .pau-st, :root[data-theme="dark"] .pau-count.st-reserved strong { color: #9CC3F5; }
:root[data-theme="dark"] .st-repair { background: var(--warn-bg); border-color: #7A5B1E; }
:root[data-theme="dark"] .pau-unit.st-repair .pau-st, :root[data-theme="dark"] .pau-count.st-repair strong { color: #F2C66D; }
:root[data-theme="dark"] .pau-unit.st-vacant .pau-st, :root[data-theme="dark"] .pau-count.st-vacant strong { color: var(--ink-2); }
:root[data-theme="dark"] .inv-card.safe, :root[data-theme="dark"] .inv-card.low, :root[data-theme="dark"] .inv-card.critical, :root[data-theme="dark"] .inv-card.expiring { border-color: var(--line); }
:root[data-theme="dark"] .btn-danger { border-color: color-mix(in srgb, var(--danger) 45%, transparent); }
:root[data-theme="dark"] input.sc.blank { background: var(--surface-2); }
:root[data-theme="dark"] .status-card.pending_review, :root[data-theme="dark"] .status-card.rejected { border-color: var(--line); }
:root[data-theme="dark"] .utang-entry.payment .num { color: var(--ok); }

/* Settings → Display */
.theme-choice { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .4rem; }
.theme-choice .chip-btn { min-height: 48px; }

/* Labahan: list rows (price list, machines) and the setup wizard's price picker */
.lab-row { display: flex; gap: .6rem; align-items: center; width: 100%; min-height: 52px; padding: .6rem .75rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); color: var(--ink); font: inherit; text-align: left; }
button.lab-row { cursor: pointer; }
.lab-row > .grow { display: grid; gap: .15rem; min-width: 0; overflow-wrap: anywhere; }
.lab-pick { display: grid; grid-template-columns: auto 1fr auto 5.2rem; grid-template-areas: "c n p i" ". u u u"; gap: .2rem .5rem; align-items: center; padding: .55rem .6rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.lab-pick > input[type="checkbox"] { grid-area: c; width: 22px; height: 22px; }
.lab-pick > .grow { grid-area: n; font-weight: 600; }
.lab-pick > .lab-peso { grid-area: p; color: var(--ink-2); }
.lab-pick > .num-in { grid-area: i; width: 100%; text-align: right; }
.lab-pick > small { grid-area: u; }
.btn.danger { color: var(--danger); }
/* Labahan order screen: the big number pad, steppers, the live total */
.lab-pad-wrap { display: grid; gap: .5rem; }
.lab-pad-display { display: block; padding: .4rem .8rem; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); font-size: 2.4rem; font-weight: 800; text-align: right; min-height: 3.6rem; }
.lab-pad { display: grid; grid-template-columns: repeat(3, 1fr); gap: .45rem; }
.lab-key { min-height: 56px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--surface-2, var(--surface)); color: var(--ink); font: inherit; font-size: 1.5rem; font-weight: 700; cursor: pointer; touch-action: manipulation; }
.lab-key:active { background: var(--brand); color: var(--brand-ink); }
.lab-key.sm { min-height: 44px; min-width: 44px; font-size: 1.3rem; }
.lab-step { display: flex; align-items: center; gap: .5rem; padding: .35rem 0; }
.lab-step > .grow { display: grid; min-width: 0; flex: 1 1 auto; }
.lab-step-n { min-width: 2ch; text-align: center; font-size: 1.2rem; }
.lab-total { display: grid; gap: .3rem; }
.lab-total .r-line { display: flex; justify-content: space-between; gap: .5rem; }
.lab-total .r-total { font-size: 1.25rem; border-top: 1px solid var(--line); padding-top: .35rem; }
.lab-save { min-height: 56px; font-size: 1.1rem; }
.lab-stub-no { font-size: 1.8rem; letter-spacing: .04em; }
/* Labahan leak check: the day picker */
.lab-daynav { align-items: center; gap: .5rem; }
.lab-daynav .btn { min-width: 44px; min-height: 44px; font-size: 1.2rem; }
.lab-daynav strong { text-align: center; }
/* Labahan shift close: the cash count and the result */
.lab-denoms { display: grid; gap: .4rem; }
.lab-denom { display: grid; grid-template-columns: 4.5rem auto 6rem 1fr; align-items: center; gap: .5rem; }
.lab-denom-label { font-weight: 800; font-size: 1.05rem; }
.lab-denom .num-in { width: 100%; min-height: 44px; text-align: right; font-size: 1.1rem; }
.lab-denom-sub { text-align: right; }
.lab-cash-total { font-size: 1.5rem; }
.lab-result.ok { border-left: 4px solid var(--ok); }
.lab-result.check { border-left: 4px solid #E8590C; }
/* Labahan order board: one column at a time on a phone (tabs), all columns on a laptop */
.lab-board-screen { display: grid; gap: .75rem; }
.screen.lab-board-screen { max-width: 90rem; }
.lab-tabs { flex-wrap: nowrap; overflow-x: auto; padding-bottom: .2rem; scrollbar-width: thin; }
.lab-tabs .chip-btn { flex: none; }
.lab-col { display: none; }
.lab-col.on { display: grid; gap: .5rem; }
.lab-col-title { display: none; }
.lab-card { display: grid; gap: .35rem; padding: .75rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.lab-card.overdue { border-left: 4px solid var(--danger); }
.lab-card-head { display: flex; align-items: baseline; gap: .6rem; padding: 0; border: 0; background: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer; min-height: 44px; }
.lab-card-stub { font-size: 1.5rem; letter-spacing: .03em; white-space: nowrap; }
.lab-card-name { font-weight: 600; overflow-wrap: anywhere; }
.lab-pills:empty { display: none; }
.lab-next { min-height: 48px; }
.lab-machine-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.lab-due { font-size: 1.3rem; font-weight: 800; }
@media (min-width: 900px) {
  .lab-tabs { display: none; }
  .lab-board { display: grid; grid-template-columns: repeat(6, minmax(190px, 1fr)); gap: .75rem; overflow-x: auto; align-items: start; }
  .lab-col, .lab-col.on { display: grid; gap: .5rem; align-content: start; }
  .lab-col-title { display: block; }
}
/* Labahan L7: suki stamp card, voided statement lines */
.lab-stamps { display: grid; grid-template-columns: repeat(5, 1fr); gap: .4rem; margin: .5rem 0; }
.lab-stamp { aspect-ratio: 1; display: grid; place-items: center; border: 2px dashed var(--line, #ccc); border-radius: 50%; font-size: .85rem; color: var(--muted, #777); }
.lab-stamp.on { border-style: solid; border-color: var(--ok, #2e7d32); background: var(--ok-bg, #e8f5e9); color: var(--ok, #2e7d32); font-weight: 700; }
.strike { text-decoration: line-through; opacity: .7; }
.lab-row .num { white-space: nowrap; }
.lab-pills { display: flex; flex-direction: column; align-items: flex-end; gap: .25rem; flex-shrink: 0; }

/* Booking B1: the setup wizard's "make N units" cards */
.bk-group { display: grid; gap: .6rem; }
.bk-group-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.bk-group-grid .num-in, .bk-group-grid select { width: 100%; min-height: 44px; text-align: left; }
@media (min-width: 640px) { .bk-group-grid { grid-template-columns: repeat(4, 1fr); } }

/* Booking B2–B8: calendar grid, booking screen, reports */
.bk-cal-wrap { overflow-x: auto; max-width: 100%; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.bk-cal { border-collapse: separate; border-spacing: 0; font-size: .8rem; min-width: max-content; }
.bk-cal th, .bk-cal td { padding: 0; border-bottom: 1px solid var(--line); }
.bk-cal-unit { position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: left; padding: .35rem .5rem !important; min-width: 5.5rem; max-width: 7rem; border-right: 1px solid var(--line); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bk-cal-day { width: 2.6rem; padding: .3rem 0 !important; text-align: center; font-weight: 400; line-height: 1.15; }
.bk-cal-day small, .bk-cal-day strong { display: block; }
.bk-cal-day.wkend { background: var(--warn-bg); }
.bk-cal-day.hol strong { color: var(--danger); }
.bk-cal-day.today { box-shadow: inset 0 -3px 0 var(--accent-ui, var(--brand, #333)); }
.bk-cal-cell { height: 2.4rem; }
.bk-cal-cell button { all: unset; box-sizing: border-box; display: block; width: 100%; height: 2.4rem; cursor: pointer; font-size: .72rem; font-weight: 600; padding: 0 .2rem; white-space: nowrap; overflow: hidden; text-overflow: clip; line-height: 2.4rem; }
.bk-cal-cell.free button:hover, .bk-cal-cell.free button:focus-visible { background: color-mix(in srgb, var(--ok) 15%, transparent); outline: 2px solid var(--ok); outline-offset: -2px; }
.bk-cal-cell.st-reserved button, .bk-cal-key.st-reserved { background: var(--ok-bg); color: var(--ok); }
.bk-cal-cell.st-hold button, .bk-cal-key.st-hold { background: var(--warn-bg); color: #8A5A00; }
.bk-cal-cell.st-checked_in button, .bk-cal-key.st-checked_in { background: var(--ok); color: #fff; }
.bk-cal-cell.st-checked_out button, .bk-cal-key.st-checked_out { background: var(--line); color: var(--ink-2); }
.bk-cal-cell.imported button, .bk-cal-key.imported { background-image: repeating-linear-gradient(135deg, transparent 0 6px, color-mix(in srgb, #1971C2 18%, transparent) 6px 9px); }
.bk-legend { gap: .35rem; }
.bk-cal-key { padding: .2rem .55rem; border-radius: 999px; font-size: .78rem; border: 1px solid var(--line); }
.bk-total { font-weight: 700; font-size: 1.05rem; margin: .4rem 0 0; }
.bk-tier { gap: .5rem; align-items: center; flex-wrap: wrap; }
.bk-tier .num-in { width: 4.2rem; min-height: 40px; }
.lab-row.muted, .lab-row:disabled { opacity: .55; }
.lab-row.stack { flex-direction: column; align-items: stretch; }
.tile.danger strong, .link.danger, .btn-ghost.danger { color: var(--danger); }
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem; }
.stat-grid .stat { display: grid; gap: .1rem; }
.stat-grid .stat strong { font-size: 1.25rem; }
@media (min-width: 640px) { .stat-grid { grid-template-columns: repeat(4, 1fr); } }

/* =====================================================================================================
   CLEAN LOOK (Dec 2026): matches the marketing homepage. White surfaces on a soft warm gray, thin #EAEAEA
   borders, 20px cards, pill buttons, tighter headings, more room. Laxis pages (/start, signup) use the
   homepage's yellow; store apps keep their own brand colors. Dark mode and wallpapers still win where set.
   ===================================================================================================== */
:root {
  --bg: #F6F6F4; --surface: #FFFFFF; --ink: #0A0A0A; --ink-2: #5F5F5F; --line: #EAEAEA;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --r: 20px; --r-sm: 14px;
  --shadow-soft: 0 1px 2px rgba(10,10,10,.04), 0 12px 32px -14px rgba(10,10,10,.12);
}
body { line-height: 1.55; -webkit-font-smoothing: antialiased; }
h1, h2, h3 { letter-spacing: -.02em; }

/* Buttons and fields: pills, 1px borders */
.btn { border-width: 1px; border-radius: 9999px; padding: 0 1.3rem; transition: background .2s, box-shadow .2s, transform .1s; }
.btn-primary:hover { box-shadow: 0 8px 20px -10px color-mix(in srgb, var(--brand) 70%, transparent); }
.btn-ghost:hover { background: var(--surface); }
input, select, textarea { border-width: 1px; border-radius: var(--r-sm); }
.slug-row, .phone-row, .price-row { border-width: 1px; border-radius: var(--r-sm); }
.slug-row .btn { border-left-width: 1px; border-radius: 0; }
.palette { border-width: 1px; border-radius: var(--r-sm); }
.chip-btn { border-radius: 9999px; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
:root[data-theme="dark"] :focus-visible { outline-color: var(--ink); }

/* Cards and lists: white, thin border, soft shadow */
.card, .tile, .plan, .who, .product, .faq, .signup-what, .landing-what, .banner, .d-card, .d-stat { border-width: 1px; }
.card { border-radius: var(--r); padding: 1.25rem; gap: .9rem; }
.card, .d-card, .d-stat, .tile, .who { box-shadow: var(--shadow-soft); }
:root[data-theme="dark"] .card, :root[data-theme="dark"] .d-card, :root[data-theme="dark"] .d-stat, :root[data-theme="dark"] .tile, :root[data-theme="dark"] .who { box-shadow: none; }
.section-title { font-size: .75rem; font-weight: 600; letter-spacing: .14em; color: var(--ink-2); }
.screen { gap: 1.4rem; padding-top: 1.4rem; padding-bottom: 2.5rem; }
.banner { border-radius: var(--r); padding: .9rem 1rem; }

/* Top bar: white with a hairline instead of a solid brand-colored bar. The store's color stays in its logo. */
.appbar { background: color-mix(in srgb, var(--surface) 92%, transparent); color: var(--ink); border-bottom: 1px solid var(--line);
  -webkit-backdrop-filter: saturate(1.4) blur(14px); backdrop-filter: saturate(1.4) blur(14px); }
body.tenant::before { background: var(--surface); }
.appbar h1 { font-size: 1.05rem; font-weight: 700; letter-spacing: -.01em; }
.appbar .btn { color: var(--ink); border-color: var(--line); background: var(--surface); }
.appbar-back, .appbar-bell { color: var(--ink); }
.brand-mark { background: var(--brand); color: var(--brand-ink); border-radius: 12px; }
:root.lx-wall .appbar { background: color-mix(in srgb, var(--surface) 72%, transparent); }
:root.lx-wall[data-theme="dark"] .appbar { background: rgba(8,10,10,.62); }

/* Home tiles */
.tile { border-radius: var(--r); padding: 1.1rem; min-height: 116px; transition: transform .2s, box-shadow .2s; }
.tile:hover { transform: translateY(-2px); }
.tile strong { font-size: 1.05rem; letter-spacing: -.01em; }
.pill { font-weight: 700; }

/* Store login */
.login-head { gap: .8rem; padding-top: 1rem; }
.login-top { width: 100%; }
.lg-name { font-weight: 700; letter-spacing: -.03em; font-size: 1.65rem; }
.lg-welcome { font-size: .98rem; max-width: 18rem; }
.brand-mark.lg { border-radius: 24px; }
.who { border-radius: var(--r); min-height: 64px; padding: .6rem 1rem; transition: border-color .2s, transform .2s; }
.who:hover { transform: translateY(-1px); }
.pin-dots { gap: 1rem; margin: .2rem 0; }
.pin-dots i { width: 14px; height: 14px; border: 1.5px solid #BDBDBD; transition: background .15s, transform .15s; }
.pin-dots i.on { background: var(--ink); border-color: var(--ink); transform: scale(1.08); }
.pinpad { gap: .75rem; max-width: 19rem; }
.pinpad button { min-height: 66px; border-radius: 9999px; border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(10,10,10,.04); transition: background .12s, transform .08s; }
.pinpad button:hover { background: color-mix(in srgb, var(--ink) 3%, var(--surface)); }
.pinpad button:active { transform: scale(.96); }
.pinpad .pin-del { background: transparent; border-color: transparent; box-shadow: none; color: var(--ink-2); }
.pinpad .pin-go { font-weight: 700; box-shadow: 0 8px 20px -10px color-mix(in srgb, var(--brand) 70%, transparent); }
:root[data-theme="dark"] .pinpad button:not(.pin-go):not(.pin-del) { box-shadow: none; }

/* Dashboard kit */
.dash { gap: 1.25rem; }
@media (min-width: 900px) { .dash-col { gap: 1.25rem; } }
.d-card { border-radius: var(--r); padding: 1.25rem; gap: .9rem; }
.d-card h2 { font-size: 1rem; font-weight: 700; letter-spacing: -.01em; }
.d-banner { border-radius: 24px; padding: 1.5rem; gap: .7rem;
  background: radial-gradient(120% 160% at 100% 0%, color-mix(in srgb, #fff 14%, transparent), transparent 55%), var(--brand); }
.d-banner h1 { font-weight: 700; letter-spacing: -.03em; }
.d-eyebrow { font-weight: 600; letter-spacing: .14em; }
.d-stats { gap: .9rem; }
.d-stat { border-radius: var(--r); padding: 1.05rem; gap: .4rem; }
.d-stat-title { font-weight: 600; font-size: .8rem; }
.d-stat-value { font-weight: 700; letter-spacing: -.03em; }
.d-icon { background: var(--bg); border: 1px solid var(--line); }
.d-insight { border-radius: var(--r-sm); font-weight: 500; }
.d-tile { border-radius: var(--r-sm); background: var(--surface); transition: transform .2s, border-color .2s; }
.d-tile:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--ink) 18%, var(--line)); }
.d-snap dd { font-weight: 700; }
.pill-btn { font-weight: 600; }
.d-table th { font-weight: 600; letter-spacing: .08em; }
@media (max-width: 640px) { .d-table tr { border-radius: var(--r-sm); background: var(--surface); } }
@media (min-width: 1000px) {
  body.has-side .side-nav { padding: 1.25rem .8rem; gap: 1.25rem; }
  .side-nav li button { border-radius: 9999px; padding: 0 1rem; }
}
.side-nav li button.on { font-weight: 700; }
.toast { border-radius: 9999px; box-shadow: 0 14px 30px -12px rgba(10,10,10,.35); }
.sheet { border-radius: 24px 24px 0 0; }

/* ---------- /start: light, like the homepage ---------- */
body.st-page { background: #fff; background-image: none; color: #0A0A0A; font-family: var(--font); }
.st { max-width: 720px; padding-top: 0; }
.st-top { height: 72px; border-bottom: 1px solid transparent; }
.st-logo { color: #0A0A0A; letter-spacing: -.02em; font-weight: 700; font-size: 18px; gap: 10px; }
.st-la { width: 40px; height: 24px; }
.st-top select { background: #fff; color: #0A0A0A; border: 1px solid #EAEAEA; border-radius: 9999px; padding: 8px 14px; min-height: 40px; width: auto; }
.st-hero { padding: 56px 0 36px; text-align: center; }
.st-eyebrow { display: inline-flex; align-items: center; gap: 8px; color: #444; font-size: 13px; font-weight: 500; letter-spacing: 0; text-transform: none;
  padding: 6px 14px 6px 10px; border: 1px solid #EAEAEA; border-radius: 9999px; margin-bottom: 22px; }
.st-eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #1F9D55; box-shadow: 0 0 0 3px rgba(31,157,85,.15); }
.st-hero h1 { font-weight: 700; letter-spacing: -2px; font-size: clamp(38px, 8vw, 64px); }
.st-dot { color: #0A0A0A; }
.st-hero h1 > span:first-child { background: linear-gradient(transparent 62%, #FFC93C 62%, #FFC93C 92%, transparent 92%); padding: 0 .06em; }
.st-lead { color: #444; font-size: 18px; margin: 18px auto 0; }
.st-grid { gap: 14px; }
.st-card { background: #fff; border: 1px solid #EAEAEA; border-radius: 20px; padding: 20px; color: #0A0A0A; box-shadow: var(--shadow-soft); }
.st-card:hover, .st-card:focus-visible { background: #fff; border-color: #0A0A0A; transform: translateY(-2px); }
.st-card:focus-visible { outline: 2px solid #0A0A0A; outline-offset: 3px; }
.st-icon { background: #F6F6F4; border: 1px solid #EAEAEA; color: #0A0A0A; }
.st-text strong { font-weight: 700; letter-spacing: -.02em; }
.st-text span { color: #5F5F5F; font-size: 14px; }
.st-go { color: #0A0A0A; }
.st-checks { justify-content: center; color: #444; margin: 24px 0 40px; }
.st-checks li::before { content: ""; display: inline-block; width: 18px; height: 18px; margin-right: 8px; vertical-align: -4px; border-radius: 50%;
  background: #FFC93C url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M6 10.5l2.5 2.5L14 7.5' fill='none' stroke='%230a0a0a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat; }
.st-login { background: #F6F6F4; border: 1px solid #EAEAEA; border-radius: 20px; padding: 22px; gap: 12px; }
.st-login label { color: #444; font-size: 15px; }
.st-login label strong { color: #0A0A0A; }
.st-slug { background: #fff; border: 1px solid #EAEAEA; border-radius: 9999px; padding: 4px; }
.st-slug:focus-within { border-color: #0A0A0A; }
.st-prefix { color: #5F5F5F; padding-left: 14px; }
.st-slug input { color: #0A0A0A; min-height: 44px; }
.st-slug button { background: #FFC93C; color: #0A0A0A; border-radius: 9999px; min-height: 44px; padding: 0 22px; }
.st-slug button:hover { background: #FFD45E; }
.st-foot { color: #5F5F5F; font-size: 14px; text-align: center; justify-items: center; margin-top: 40px; }
.st-foot a { color: #0A0A0A; }

/* ---------- Signup: light, like the homepage ---------- */
body.su-page {
  color-scheme: light;
  --bg: #FFFFFF; --surface: #FFFFFF; --surface-2: #F6F6F4; --ink: #0A0A0A; --ink-2: #5F5F5F; --line: #EAEAEA;
  --brand: #FFC93C; --brand-ink: #0A0A0A; --accent: #FFC93C; --accent-ink: #0A0A0A; --accent-ui: #FFC93C; --accent-ui-ink: #0A0A0A; --brand-text: #0A0A0A;
  --danger: #B42318; --danger-bg: #FDECEA; --ok: #157347; --ok-bg: #E7F5EE; --warn-bg: #FFF6DB;
  background: #fff; background-image: none; color: #0A0A0A; font-family: var(--font);
}
.su-page .signup { max-width: 34rem; gap: 1.5rem; }
.su-page .su-top { height: 72px; }
.su-page .st-logo { color: #0A0A0A; }
.su-page .eyebrow { color: #5F5F5F; letter-spacing: .14em; font-weight: 600; }
.su-page .type-icon { background: #F6F6F4; border: 1px solid #EAEAEA; color: #0A0A0A; border-radius: 14px; }
.su-page .signup-head h1 { font-weight: 700; letter-spacing: -1px; font-size: clamp(1.7rem, 6vw, 2.1rem); }
.su-page input, .su-page select, .su-page textarea { background: #fff; color: #0A0A0A; border-color: #EAEAEA; }
.su-page input:focus, .su-page select:focus { border-color: #0A0A0A; outline: none; box-shadow: 0 0 0 3px rgba(255,201,60,.45); }
.su-page .slug-row:focus-within, .su-page .phone-row:focus-within { border-color: #0A0A0A; }
.su-page .slug-prefix, .su-page .phone-prefix { background: #F6F6F4; color: #444; }
.su-page .btn-primary { box-shadow: none; }
.su-page .btn-primary:hover { background: #FFD45E; border-color: #FFD45E; }
.su-page .btn:not(.btn-primary) { background: #fff; border-color: #0A0A0A; }
.su-page details.signup-what, .su-page .landing-faq details.faq { background: #fff; border-color: #EAEAEA; border-radius: 20px; }
.su-page .chip-btn.on, .su-page .faq-tab.on { background: #0A0A0A; color: #fff; border-color: #0A0A0A; }
.su-page .su-step { background: #fff; border: 1px solid #EAEAEA; border-radius: 24px; padding: 1.5rem; box-shadow: var(--shadow-soft); }
.su-page .su-h { font-weight: 700; letter-spacing: -.03em; }
.su-page .su-dots li.on b { background: #FFC93C; border-color: #FFC93C; color: #0A0A0A; }
.su-page .su-dots li.now b { box-shadow: 0 0 0 4px rgba(255,201,60,.3); }
.su-page .su-bar { background: #EAEAEA; }
.su-page .su-bar i { background: #FFC93C; }
.su-page .palette:has(input:checked) { border-color: #0A0A0A; box-shadow: 0 0 0 1px #0A0A0A inset; }
.su-page .logo-preview { border: 1px solid #EAEAEA; }
@media (max-width: 600px) { .su-page .su-step { padding: 1.15rem; border-radius: 20px; } .st-hero { padding-top: 36px; } }
@media (prefers-reduced-motion: reduce) { .tile, .who, .d-tile, .st-card, .pinpad button, .btn { transition: none; } .tile:hover, .who:hover, .d-tile:hover, .st-card:hover { transform: none; } }

/* ---------- Simpler, calmer screens (Dec 2026): one accent per screen, no colored card borders ---------- */
/* Greeting */
.screen > h2:first-of-type { font-size: clamp(1.45rem, 6vw, 1.8rem); font-weight: 700; letter-spacing: -.03em; }
/* Plan / install banners: white card with a hairline, the button carries the color */
.banner.trial, .banner.renew, .banner.install { background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-soft); }
.banner p { font-size: .92rem; line-height: 1.45; }
:root[data-theme="dark"] .banner.trial, :root[data-theme="dark"] .banner.renew, :root[data-theme="dark"] .banner.install { background: var(--surface); box-shadow: none; }
/* "What needs your attention", learners at risk: no colored outline; "all caught up" is a quiet line */
.attn-card, .risk-card { border-color: var(--line); }
.attn-card .hint.ok, .risk-card .hint.ok { color: var(--ink-2); font-weight: 500; }
.attn-item { border-width: 1px; border-left-width: 3px; }
/* Quick actions: small pills in a row instead of big boxes */
.quick-row { display: flex; flex-wrap: wrap; gap: .5rem; }
.quick-btn { display: inline-flex; align-items: center; gap: .45rem; min-height: 44px; padding: 0 1rem; border-radius: 9999px; border: 1px solid var(--line);
  background: var(--surface); font-size: .9rem; font-weight: 600; box-shadow: 0 1px 2px rgba(10,10,10,.04); }
.quick-btn span { font-size: 1rem; filter: grayscale(1); opacity: .85; }
.quick-btn:hover { border-color: color-mix(in srgb, var(--ink) 25%, var(--line)); }
/* Lists inside cards */
.row-card, .today-row { border-width: 1px; border-radius: var(--r-sm); }
.today-row { padding: .65rem .8rem; }
.today-row.on { border-color: var(--ink); }
.today-row .grow { flex: 1; justify-items: start; text-align: left; gap: .1rem; }
.today-row > .num:empty { display: none; }
.today-row .grow .link { text-align: left; padding-left: 0; padding-right: 0; justify-content: flex-start; }
.today-row > .btn { flex: none; white-space: nowrap; }
.chip { font-weight: 600; background: var(--surface-2, #F2F2F0); }
:root:not([data-theme="dark"]) .chip:not([class*="chip-"]) { background: #F2F2F0; }
/* Main home tile: the store's color, but flatter */
.tile.primary { box-shadow: 0 10px 24px -14px color-mix(in srgb, var(--brand) 80%, transparent); }
/* Dark mode: neutral, no orange blocks. Primary actions are a light pill; the store color stays in the logo and charts. */
:root[data-theme="dark"] .btn-primary, :root[data-theme="dark"] .pinpad .pin-go, :root[data-theme="dark"] .chip-btn.on,
:root[data-theme="dark"] .tabs button.on, :root[data-theme="dark"] .tabs a.on, :root[data-theme="dark"] .pill-btn.primary {
  background: #F4F4F5; color: #0A0A0A; border-color: #F4F4F5; box-shadow: none; }
:root[data-theme="dark"] .tile.primary { background: var(--surface-2); color: var(--ink); border-color: var(--line); box-shadow: none; }
:root[data-theme="dark"] .tile.primary span { color: var(--ink-2); }
:root[data-theme="dark"] .side-nav li button.on { background: var(--surface-2); color: var(--ink); }
:root[data-theme="dark"] .appbar { background: color-mix(in srgb, var(--bg) 90%, transparent); }
/* Phones: a little tighter, still roomy */
@media (max-width: 480px) {
  .screen { gap: 1.1rem; padding-top: 1.1rem; }
  .card, .d-card { padding: 1.05rem; border-radius: 18px; }
  .appbar-inner { min-height: 56px; }
  .appbar h1 { font-size: 1rem; }
  .appbar .btn { min-height: 38px; padding: 0 .9rem; font-size: .9rem; }
  .tiles { gap: .6rem; }
  .tile { min-height: 100px; padding: .95rem; }
}
/* Kasama Moo logo on /start and /signup */
.st-la.st-moo { width: 36px; height: 36px; border-radius: 50%; }

