/* tillcat Shop: modern, phone-first. Deep teal brand, soft cards, icon tiles, floating bottom bar. */
:root {
  --brand: #5B4BE8; --brand-strong: #5B4BE8; --brand-deep: #1E1B4B; --brand-soft: #EEEBFF;
  --ink: #1E1B4B; --muted: #5B5880; --line: #E2E0F0; --bg: #F4F3FB; --surface: #fff;
  --ok: #15803d; --ok-bg: #dcfce7; --bad: #b91c1c; --bad-bg: #fee2e2; --warn: #92400e; --warn-bg: #fef3c7;
  --c-received: #64748b; --c-diagnosing: #2563eb; --c-waiting_parts: #d97706; --c-repairing: #7c3aed; --c-ready: #15803d; --c-collected: #475569; --c-cancelled: #b91c1c;
  --radius: 18px; --radius-sm: 12px; --tap: 2.75rem; --bar-h: 4.5rem;
  --shadow: 0 1px 2px rgb(30 27 75 / .05), 0 8px 24px rgb(30 27 75 / .06);
  --ring: 0 0 0 3px rgb(91 75 232 / .3);
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Noto Sans', sans-serif; color: var(--ink); line-height: 1.45; -webkit-text-size-adjust: 100%;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); -webkit-tap-highlight-color: transparent; }
h1 { font-size: 1.3rem; margin: 0; letter-spacing: -.02em; }
h2 { font-size: 1.1rem; margin: .25rem 0 .6rem; letter-spacing: -.01em; }
h3 { font-size: 1rem; margin: .2rem 0 .5rem; }
p { margin: .4rem 0; }
.muted, small { color: var(--muted); }
.grow { flex: 1 1 auto; min-inline-size: 0; }
.right { text-align: end; flex: none; }
.err { color: var(--bad); font-weight: 600; }
.flag { color: var(--warn); font-weight: 600; }

.shell { max-width: 40rem; margin: 0 auto; padding: 0 .9rem calc(var(--bar-h) + 2rem + env(safe-area-inset-bottom)); }
main { padding-block-start: .75rem; animation: rise .22s ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { main { animation: none; } * { transition: none !important; } }
.card { background: var(--surface); border-radius: var(--radius); padding: 1rem; margin: .8rem 0; border: 1px solid var(--line); box-shadow: var(--shadow); }
.row { display: flex; align-items: center; justify-content: space-between; gap: .5rem; flex-wrap: wrap; }
.daybar { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin: .5rem 0; }

/* Header */
header { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: .35rem; margin-inline: -.9rem; padding: calc(.55rem + env(safe-area-inset-top)) .9rem .55rem; background: rgb(242 246 246 / .88); backdrop-filter: blur(10px); }
.brand { display: flex; align-items: center; gap: .55rem; padding: 0; min-block-size: 0; border: 0; background: none; font-weight: 700; font-size: 1.05rem; }
.logo { display: inline-grid; place-items: center; inline-size: 2rem; block-size: 2rem; border-radius: .7rem; background: linear-gradient(135deg, var(--brand), var(--brand-deep)); color: #fff; font-weight: 800; }
.shopname { max-inline-size: 11rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.icon-btn { position: relative; display: inline-grid; place-items: center; inline-size: 2.6rem; block-size: 2.6rem; min-block-size: 0; padding: 0; border-radius: 50%; border: 0; background: #fff; box-shadow: var(--shadow); color: var(--ink); }
.badge { position: absolute; inset-block-start: -.2rem; inset-inline-end: -.2rem; min-inline-size: 1.15rem; block-size: 1.15rem; padding: 0 .25rem; border-radius: 99px; background: #ef4444; color: #fff; font-size: .68rem; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--bg); }

/* Forms */
label { display: block; margin: .75rem 0; font-size: .82rem; font-weight: 600; color: var(--muted); }
input, select, textarea { display: block; width: 100%; min-block-size: var(--tap); padding: .6rem .8rem; margin-top: .25rem; font: inherit; font-size: 1rem; font-weight: 400; color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; }
input:focus, select:focus, textarea:focus, button:focus-visible, a:focus-visible { outline: none; border-color: var(--brand); box-shadow: var(--ring); }
input[type='checkbox'] { display: inline-block; inline-size: 1.2rem; min-block-size: 0; block-size: 1.2rem; margin-inline-end: .5rem; vertical-align: middle; accent-color: var(--brand); }
button, .btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; min-block-size: var(--tap); padding: .5rem 1rem; margin: .2rem .25rem .2rem 0; font: inherit; font-weight: 600; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; color: var(--ink); cursor: pointer; text-decoration: none; touch-action: manipulation; }
button:active, .btn:active { transform: scale(.98); }
button.primary, .btn.primary { background: linear-gradient(135deg, var(--brand), var(--brand-strong)); border-color: transparent; color: #fff; box-shadow: 0 4px 14px rgb(91 75 232 / .3); }
button.big, .btn.big { width: 100%; min-block-size: 3.3rem; font-size: 1.05rem; margin-inline: 0; }
button:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; }
button.link { border: 0; background: none; min-block-size: 0; padding: .2rem; color: var(--brand-strong); }
.item:disabled { opacity: .5; }

/* Login */
.login { max-width: 26rem; margin: 0 auto; padding: 2.5rem 1rem 2rem; }
.login-brand { text-align: center; margin-bottom: 1rem; }
.logo-img { display: inline-block; flex: none; inline-size: 2rem; block-size: 2rem; border-radius: .7rem; }
.login-brand .logo-img { inline-size: 3.6rem; block-size: 3.6rem; border-radius: 1.1rem; }
.login-brand .logo { inline-size: 3.6rem; block-size: 3.6rem; font-size: 1.7rem; border-radius: 1.1rem; }
.login .card > h1 { text-align: center; font-size: 1.1rem; margin: .25rem 0 .75rem; }
.login-logo { display: block; inline-size: min(100%, 22rem); block-size: auto; margin: 0 auto 0.5rem; }
.login-brand p { color: var(--muted); }

/* Home */
.hero { position: relative; overflow: hidden; margin: .25rem 0 1rem; padding: 1.2rem 1.2rem 1.3rem; border-radius: 22px; color: #fff; background: radial-gradient(120% 140% at 100% 0%, #8B7DFF 0%, transparent 55%), linear-gradient(135deg, #5B4BE8, var(--brand-deep)); box-shadow: 0 12px 30px rgb(11 59 67 / .28); }
.hero small { color: rgb(255 255 255 / .8); font-size: .9rem; }
.hero-num { margin-top: .3rem; font-size: 2.3rem; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.hero-sub { color: rgb(255 255 255 / .85); }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: .65rem; }
.action { flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: .1rem; margin: 0; padding: .9rem; min-block-size: 7rem; text-align: start; border-radius: var(--radius); box-shadow: var(--shadow); }
.action small { font-weight: 400; }
.tile-icon { flex: none; display: inline-grid; place-items: center; inline-size: 2.6rem; block-size: 2.6rem; margin-bottom: .35rem; border-radius: .85rem; background: var(--brand-soft); color: var(--brand-strong); }
.item .tile-icon { margin-bottom: 0; }
.tile-icon.ok { background: var(--ok-bg); color: var(--ok); }
.section-head { display: flex; align-items: center; justify-content: space-between; margin: 1.3rem 0 .4rem; }
.section-head h2 { margin: 0; }
.pipeline { display: grid; grid-template-columns: repeat(5, 1fr); gap: .4rem; }
.stage { flex-direction: column; gap: 0; min-block-size: 4.4rem; margin: 0; padding: .55rem .2rem; border-radius: 14px; border: 0; border-block-end: 4px solid var(--c); background: #fff; box-shadow: var(--shadow); }
.stage b { font-size: 1.4rem; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stage span { font-size: .66rem; font-weight: 600; color: var(--muted); text-align: center; line-height: 1.15; }
.s-received { --c: var(--c-received); } .s-diagnosing { --c: var(--c-diagnosing); } .s-waiting_parts { --c: var(--c-waiting_parts); } .s-repairing { --c: var(--c-repairing); } .s-ready { --c: var(--c-ready); }
.empty { display: flex; flex-direction: column; align-items: center; gap: .2rem; padding: 1.2rem; color: var(--muted); text-align: center; background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); }
.empty p { margin: 0; }

/* Lists */
.item, .note { display: flex; align-items: center; justify-content: flex-start; gap: .75rem; width: 100%; min-block-size: 3.6rem; margin: .5rem 0; padding: .7rem .85rem; text-align: start; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); font-weight: 400; }
.item.static { justify-content: space-between; }
.item strong, .note strong { font-weight: 650; }
.note { border-inline-start: 4px solid #cbd5d5; }
.note.high { border-inline-start-color: #f59e0b; background: #fffbeb; }
.note-icon { flex: none; display: grid; place-items: center; inline-size: 2.4rem; block-size: 2.4rem; border-radius: 50%; background: var(--brand-soft); color: var(--brand-strong); }
.note.high .note-icon { background: var(--warn-bg); color: var(--warn); }
.pill, .tag { display: inline-block; padding: .12rem .65rem; border-radius: 99px; font-size: .72rem; font-weight: 700; background: #e8eded; color: #3f4f4f; white-space: nowrap; }
.tag.paid { background: var(--ok-bg); color: var(--ok); } .tag.overdue { background: var(--bad-bg); color: var(--bad); } .tag.open { background: var(--warn-bg); color: var(--warn); }
.pill.st-received { background: #e2e8f0; color: #334155; } .pill.st-diagnosing { background: #dbeafe; color: #1d4ed8; } .pill.st-waiting_parts { background: var(--warn-bg); color: var(--warn); }
.pill.st-repairing { background: #ede9fe; color: #6d28d9; } .pill.st-ready { background: var(--ok-bg); color: var(--ok); } .pill.st-collected, .pill.st-cancelled { background: #e8eded; color: #475569; }
.tile-icon.st-received { background: #e2e8f0; color: #334155; } .tile-icon.st-diagnosing { background: #dbeafe; color: #1d4ed8; } .tile-icon.st-waiting_parts { background: var(--warn-bg); color: var(--warn); }
.tile-icon.st-repairing { background: #ede9fe; color: #6d28d9; } .tile-icon.st-ready { background: var(--ok-bg); color: var(--ok); }
.warn { background: var(--warn-bg); border: 1px solid #f59e0b; border-radius: var(--radius-sm); padding: .7rem; margin: .6rem 0; }

.chips { display: flex; gap: .4rem; flex-wrap: wrap; margin: .5rem 0; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; margin-inline: -.9rem; padding: .2rem .9rem .5rem; scrollbar-width: none; }
.chips button { flex: none; min-block-size: 2.4rem; margin: 0; padding: .3rem .85rem; border-radius: 99px; font-size: .88rem; }
.chips button.on { background: var(--brand-deep); border-color: var(--brand-deep); color: #fff; }
.count { display: inline-grid; place-items: center; min-inline-size: 1.3rem; block-size: 1.3rem; padding: 0 .3rem; border-radius: 99px; background: rgb(0 0 0 / .08); font-size: .72rem; }
.chips button.on .count { background: rgb(255 255 255 / .25); }

/* Repair progress steps */
.steps { display: flex; justify-content: space-between; margin: .4rem 0 .2rem; padding: 0; list-style: none; position: relative; }
.steps::before { content: ''; position: absolute; inset-inline: 8%; inset-block-start: .85rem; block-size: 3px; background: var(--line); }
.steps li { position: relative; z-index: 1; flex: 1; display: flex; flex-direction: column; align-items: center; gap: .3rem; font-size: .68rem; font-weight: 600; color: var(--muted); text-align: center; }
.steps .dot { display: grid; place-items: center; inline-size: 1.75rem; block-size: 1.75rem; border-radius: 50%; background: #fff; border: 2px solid var(--line); font-size: .75rem; }
.steps li.done .dot { background: var(--brand); border-color: var(--brand); color: #fff; }
.steps li.now .dot { border-color: var(--brand); color: var(--brand-strong); box-shadow: 0 0 0 4px rgb(91 75 232 / .18); }
.steps li.now { color: var(--ink); }

/* Cart, tables */
.cartline { display: flex; align-items: center; gap: .5rem; padding: .55rem 0; border-block-end: 1px solid var(--line); }
.stepper { display: inline-flex; align-items: center; gap: .4rem; }
.stepper button { min-inline-size: var(--tap); padding: 0; margin: 0; }
.priceinput { inline-size: 6rem; margin: 0; text-align: end; }
.totalrow { font-size: 1.2rem; }
.grid2 { display: grid; grid-template-columns: 1fr; gap: 0 .75rem; }
@media (min-width: 30rem) { .grid2 { grid-template-columns: 1fr 1fr; } }
table { width: 100%; border-collapse: collapse; font-size: .88rem; margin: .5rem 0; }
th, td { padding: .5rem .4rem; border-block-end: 1px solid var(--line); text-align: start; }
.num { text-align: end; white-space: nowrap; font-variant-numeric: tabular-nums; }
.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: .65rem; margin: .75rem 0; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem; box-shadow: var(--shadow); color: var(--muted); font-size: .85rem; }
.tile b { display: block; margin-block-start: .2rem; color: var(--ink); font-size: 1.35rem; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }

/* Bottom bar */
.tabs { position: fixed; z-index: 30; inset-inline: .75rem; inset-block-end: calc(.6rem + env(safe-area-inset-bottom)); display: flex; max-width: 38rem; margin-inline: auto; padding: .3rem; background: rgb(255 255 255 / .94); backdrop-filter: blur(12px); border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 10px 30px rgb(30 27 75 / .16); }
.tabs button { flex: 1 1 0; min-inline-size: 0; flex-direction: column; gap: .1rem; min-block-size: 3.4rem; margin: 0; padding: .35rem .1rem; border: 0; border-radius: 16px; background: transparent; color: var(--muted); font-size: .7rem; }
.tabs button.on { background: var(--brand-soft); color: var(--brand-strong); }
.tabs button span { max-inline-size: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* The menu behind "More" on a phone or tablet: the pages that do not fit in the bottom bar */
.more-back, .more-back:hover { position: fixed; inset: 0; z-index: 28; inline-size: 100%; block-size: 100%; min-block-size: 0; margin: 0; padding: 0; border: 0; border-radius: 0; background: rgb(30 27 75 / .35); box-shadow: none; }
.more-menu { position: fixed; z-index: 29; inset-inline: .75rem; inset-block-end: calc(var(--bar-h) + 1.4rem + env(safe-area-inset-bottom)); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .3rem; max-width: 38rem; max-block-size: 65vh; overflow-y: auto; margin-inline: auto; padding: .6rem; background: #fff; border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 10px 30px rgb(30 27 75 / .22); }
.more-menu button { flex-direction: column; gap: .3rem; min-inline-size: 0; min-block-size: 4.4rem; margin: 0; padding: .4rem .2rem; border: 0; border-radius: 16px; background: transparent; color: var(--muted); font-size: .8rem; text-align: center; overflow-wrap: anywhere; box-shadow: none; }
.more-menu button.on { background: var(--brand-soft); color: var(--brand-strong); }

/* Notifications sheet */
.sheet-back { position: fixed; inset: 0; z-index: 50; background: rgb(10 25 24 / .45); display: flex; align-items: flex-end; justify-content: center; }
.sheet { width: 100%; max-width: 40rem; max-height: 85vh; overflow-y: auto; padding: 1rem .9rem calc(1rem + env(safe-area-inset-bottom)); border-radius: 24px 24px 0 0; background: var(--bg); animation: slide .22s ease-out; }
@keyframes slide { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.sheet-head { display: flex; align-items: center; justify-content: space-between; }

/* Customer tracking page */
.track { max-width: 28rem; margin: 0 auto; padding: 0 .9rem 2rem; }
.track-hero { margin: 0 -.9rem .5rem; padding: 2rem 1.4rem 2.4rem; color: #fff; background: radial-gradient(120% 140% at 100% 0%, #8B7DFF, transparent 55%), linear-gradient(135deg, #5B4BE8, var(--brand-deep)); border-radius: 0 0 28px 28px; }
.track-hero h1 { margin: .3rem 0; font-size: 2rem; }
.track-hero small, .track-hero p { color: rgb(255 255 255 / .88); }

.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: .5rem; }
.product-grid .item { margin: 0; flex-direction: column; align-items: flex-start; justify-content: space-between; gap: .3rem; min-block-size: 5rem; }
.pos { display: block; } .pos-cart .card { margin-block-start: .8rem; }
@media (min-width: 64rem) { .pos { display: grid; grid-template-columns: 1fr 24rem; gap: 1.2rem; align-items: start; } .pos-cart { position: sticky; top: 1rem; } .pos-cart .card { margin-block-start: 0; max-block-size: calc(100vh - 2rem); overflow-y: auto; } }
.paylater { margin-block: .4rem; padding: .6rem .7rem; border: 1px solid #fcd34d; border-radius: 12px; background: #fffbeb; } .paylater .warn { margin-block: 0 .5rem; }

/* Dashboard */
.dash { display: grid; gap: .8rem; }
.dash > * { min-inline-size: 0; }
.dash .hero, .dash .card { margin: 0; }
.section-head { margin-block-start: .6rem; }
.chart-card h3 { margin: 0; }
.chart { display: flex; align-items: flex-end; gap: .5rem; block-size: 8.5rem; margin-block-start: .6rem; }
.bar { flex: 1 1 0; min-inline-size: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; block-size: 100%; gap: .2rem; }
.bar small { font-size: .68rem; line-height: 1; white-space: nowrap; }
.bar-val { max-inline-size: 100%; overflow: hidden; text-overflow: ellipsis; color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; min-block-size: .7rem; }
.bar-fill { display: block; inline-size: 100%; max-inline-size: 2.6rem; border-radius: 8px 8px 3px 3px; background: #99d6cf; flex: 0 0 auto; }
.bar.today .bar-fill { background: linear-gradient(180deg, var(--brand), var(--brand-strong)); }
.bar.today small:last-child { color: var(--brand-strong); font-weight: 700; }
.kpis { display: grid; grid-template-columns: repeat(2, 1fr); gap: .65rem; }
.kpis .tile { margin: 0; text-align: start; display: block; min-block-size: 0; font-weight: 400; }
.side-brand, .tabs .desk { display: none; }

/* Wide screens: sidebar and a filled dashboard */
@media (min-width: 64rem) {
  .shell { max-width: none; margin: 0; margin-inline-start: 15.5rem; padding: 0 2rem 2rem; }
  header { margin-inline: -2rem; padding-inline: 2rem; }
  header .brand { visibility: hidden; }
  .tabs { inset: 0 auto 0 0; inline-size: 15.5rem; max-width: none; margin: 0; flex-direction: column; gap: .2rem; padding: 1rem .8rem; border-radius: 0; border-width: 0 1px 0 0; background: #fff; backdrop-filter: none; box-shadow: none; }
  .side-brand { display: flex; align-items: center; gap: .6rem; padding: .2rem .6rem 1.1rem; font-weight: 800; font-size: 1.15rem; }
  .tabs .desk { display: flex; }
  .tabs .morebtn, .more-menu, .more-back, .more-back:hover { display: none; } /* the side bar shows every page */
  .tabs button { flex: none; flex-direction: row; justify-content: flex-start; gap: .75rem; min-block-size: 2.9rem; padding: .5rem .8rem; font-size: .95rem; text-align: start; }
  main.wide, main { max-width: 78rem; }
  main:not(.wide) { max-width: 60rem; }
  .dash { grid-template-columns: repeat(12, 1fr); gap: 1rem; align-items: stretch; }
  .dash .hero { grid-column: span 5; display: flex; flex-direction: column; justify-content: center; }
  .dash .hero-num { font-size: 3rem; }
  .dash .chart-card { grid-column: span 7; }
  .dash .chart { block-size: 9.5rem; }
  .dash .kpis { grid-column: span 12; grid-template-columns: repeat(4, 1fr); }
  .dash .actions { grid-column: span 12; }
  .dash .pipe-sec { grid-column: span 12; }
  .dash .ready-sec, .dash .attn-sec { grid-column: span 6; }
  .pipeline { gap: .8rem; } .stage { min-block-size: 5.6rem; } .stage b { font-size: 1.8rem; } .stage span { font-size: .8rem; }
}

/* Tablets: roomier page, same floating bar */
@media (min-width: 48rem) {
  .shell { max-width: 56rem; }
  .kpis { grid-template-columns: repeat(4, 1fr); }
  .actions { grid-template-columns: repeat(4, 1fr); }
  .tiles { grid-template-columns: repeat(4, 1fr); }
  .sheet { border-radius: 24px; margin-block-end: 2rem; }
  .sheet-back { align-items: center; }
}
.printbar { display: inline-flex; align-items: center; gap: .4rem; }
.printbar select { inline-size: auto; margin: 0; min-block-size: var(--tap); }
.label { margin: .75rem 0 .2rem; font-size: .82rem; font-weight: 600; color: var(--muted); }
.printdoc { display: none; }
/* Printed documents. The shop's own colour (--brand, chosen in Settings) is used for the letterhead rule, headings and the total; everything else stays neutral. */
.printdoc { display: none; }
.pd { --b: var(--brand, #1f3a5f); --b-soft: color-mix(in srgb, var(--b) 7%, #fff); --b-line: color-mix(in srgb, var(--b) 26%, #fff); color: #1b1f24; font-family: system-ui, 'Segoe UI', Arial, sans-serif; line-height: 1.4; background: #fff; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.pd h1 { font-size: 1.5em; margin: 0; letter-spacing: -.01em; } .pd h4 { margin: 0 0 .3em; font-size: .7em; text-transform: uppercase; letter-spacing: .1em; color: var(--b); } .pd p { margin: .12em 0; }
/* letterhead */
.lh { display: flex; align-items: center; gap: 1em; padding: .2em 0 .9em; border-block-end: 3px solid var(--b); }
.lh-mark { display: grid; place-items: center; flex: none; inline-size: 3.9em; block-size: 3.9em; border-radius: .85em; background: var(--b); color: #fff; font-weight: 800; letter-spacing: .03em; overflow: hidden; }
.lh-mark.has-logo { background: none; inline-size: auto; border-radius: 0; } .lh-logo { display: block; block-size: 3.9em; inline-size: auto; max-inline-size: 11em; object-fit: contain; }
.lh-id { min-inline-size: 0; } .lh-id h1 { color: var(--b); font-weight: 800; }
.lh-id p { font-size: .8em; color: #4b5563; margin: .12em 0 0; } .lh-id p span + span::before { content: ' \00b7  '; color: #9ca3af; }
.lh-doc { margin-inline-start: auto; text-align: end; flex: none; } .lh-doc strong { display: block; font-size: 1.05em; font-weight: 800; letter-spacing: .18em; color: var(--b); } .lh-doc span { display: block; margin-block-start: .15em; font-size: .95em; font-weight: 700; } .lh-doc em { display: block; margin-block-start: .1em; font-size: .72em; font-style: normal; color: #6b7280; }
.pd-body { padding: .9em 0 .3em; }
.pd-cards { display: grid; grid-template-columns: 1fr 1fr; gap: .7em; margin-block-end: .7em; }
.pd-card { background: var(--b-soft); border-radius: .5em; border-inline-start: 3px solid var(--b); padding: .6em .85em; } .pd-card.wide { margin-block-end: .6em; }
.pd-overdue { color: #b91c1c; font-weight: 800; }
.pd-small { font-size: .82em; color: #4b5563; } .pd-mono { font-family: ui-monospace, Consolas, monospace; font-size: .9em; } .center { text-align: center; }
.pd-checks { display: flex; flex-wrap: wrap; gap: .3em 1.2em; }
.pd-items { width: 100%; border-collapse: collapse; margin: .5em 0; }
.pd-items th { text-align: start; padding: .45em .5em; font-size: .74em; text-transform: uppercase; letter-spacing: .07em; color: var(--b); background: var(--b-soft); border-block-end: 2px solid var(--b); }
.pd-items td { padding: .5em; border-block-end: 1px solid #e5e7eb; vertical-align: top; }
.pd-items .num { text-align: end; white-space: nowrap; }
.pd-after { display: flex; justify-content: space-between; align-items: flex-start; gap: 1em; }
.pd-totals { inline-size: 52%; margin-inline-start: auto; border-collapse: collapse; margin-block: .5em; }
.pd-totals td { padding: .3em .6em; } .pd-totals .num { text-align: end; white-space: nowrap; }
.pd-totals tr.grand td { background: var(--b); color: #fff; font-weight: 800; font-size: 1.08em; } .pd-totals tr.due td { font-weight: 800; color: #b91c1c; border-block-start: 2px solid #b91c1c; }
.pd-stamp { display: inline-block; margin: .5em 0; padding: .12em .85em; border: 2px solid; border-radius: 99px; font-weight: 800; letter-spacing: .12em; font-size: .85em; }
.pd-stamp.ok { color: #15803d; } .pd-stamp.warn { color: #b45309; } .pd-stamp.bad { color: #b91c1c; }
.pd-terms { margin: .8em 0 .4em; padding: .6em .85em; border: 1px solid var(--b-line); border-radius: .5em; font-size: .82em; color: #374151; }
.pd-track { word-break: break-all; }
.pd-sign { display: flex; justify-content: space-between; gap: 2.5em; margin-block-start: 2.6em; } .pd-sign span { flex: 1; border-block-start: 1px solid #111; padding-block-start: .25em; text-align: center; font-size: .82em; }
.pd-credit { margin: .35em 0 0; text-align: center; font-size: .7em; color: #777; }
.pd-foot-bar { margin: .9em 0 0; padding: .7em 1em .2em; text-align: center; font-size: .85em; color: #4b5563; border-block-start: 1px solid var(--b-line); }
.pd.preview { margin: .5rem 0; padding: 1em 1.2em .4em; font-size: .85rem; border: 1px solid var(--line); border-radius: .7em; overflow: hidden; }
.docview .pd:not(.sw):not(.till):not(.preview) { padding: 1.1em 1.3em .5em; } /* on paper the page margin does this */
/* till receipt: narrow and centred; the item name has the whole line, the amounts sit under it */
.pd.till { padding: .6em .7em .3em; }
.pd.till .lh { flex-direction: column; text-align: center; gap: .45em; padding-block-end: .7em; border-block-end: 1px dashed #9ca3af; }
.pd.till .lh-mark { inline-size: 3em; block-size: 3em; font-size: .9em; border-radius: .7em; } .pd.till .lh-mark.has-logo { inline-size: auto; }
.pd.till .lh-id h1 { font-size: 1.2em; color: #111; } .pd.till .lh-id p span { display: block; } .pd.till .lh-id p span + span::before { content: none; }
.pd.till .lh-doc { margin: 0; text-align: center; } .pd.till .lh-doc strong { letter-spacing: .3em; }
.rc-meta { text-align: center; font-size: .78em; color: #4b5563; margin: .15em 0; }
.rc-items { list-style: none; margin: .5em 0 .3em; padding: 0; } .rc-items li { padding: .5em 0; border-block-end: 1px dotted #cbd5e1; }
.rc-name { font-weight: 600; line-height: 1.25; } .rc-sub { display: flex; justify-content: space-between; gap: .6em; font-size: .92em; color: #374151; margin-block-start: .1em; }
.rc-items small { display: block; color: #6b7280; font-size: .76em; margin-block-start: .1em; }
.rc-sum > div { display: flex; justify-content: space-between; gap: .6em; padding: .14em 0; } .rc-sum > div.due { font-weight: 800; color: #b91c1c; }
.rc-total { display: flex; justify-content: space-between; align-items: baseline; margin: .5em 0; padding: .55em .7em; background: var(--b); color: #fff; border-radius: .5em; font-weight: 800; font-size: 1.18em; }
.rc-tax { inline-size: 100%; border-collapse: collapse; font-size: .76em; color: #374151; margin: .3em 0 .5em; } .rc-tax th { text-align: end; font-weight: 600; color: #6b7280; padding: .15em 0; border-block-end: 1px solid #e5e7eb; } .rc-tax td { text-align: end; padding: .15em 0; } .rc-tax th:first-child, .rc-tax td:first-child { text-align: start; }
.rc-status { text-align: center; margin: .4em 0; font-size: .8em; font-weight: 800; letter-spacing: .2em; } .rc-status.ok { color: #15803d; } .rc-status.warn { color: #b45309; } .rc-status.bad { color: #b91c1c; }
.pd.till .pd-foot-bar { border-block-start: 1px dashed #9ca3af; padding-block-start: .6em; }
@media print {
  body[data-print] .shell, body[data-print] .sheet-back { display: none !important; }
  body[data-print] .printdoc { display: block; }
  body.paper-80 .shell, body.paper-a5 .shell, body.paper-a4 .shell { margin: 0; max-width: none; }
  body.paper-80 { font-size: 11px; } body.paper-80 h2 { font-size: 14px; } body.paper-80 .pd-cards { grid-template-columns: 1fr; } body.paper-80 .lh { flex-direction: column; text-align: center; } body.paper-80 .lh-doc { margin-inline-start: 0; text-align: center; } body.paper-80 .pd-totals { inline-size: 100%; } body.paper-80 .pd-after { display: block; } body.paper-80 .pd-sign { margin-block-start: 2em; }
  body.paper-a5 { font-size: 13px; } body.paper-a4 { font-size: 15px; }
}
@media print { body { background: #fff; } .noprint, .tabs, header { display: none !important; } .card { border: 0; box-shadow: none; } .shell { padding: 0; } }

.logo-pick { display: flex; align-items: center; gap: .8rem; margin: .5rem 0; } .logo-pick img { inline-size: 4rem; block-size: 4rem; object-fit: contain; border: 1px solid var(--line); border-radius: 12px; background: #fff; padding: .2rem; }

.docview { margin: .6rem 0; font-size: .9rem; border: 1px solid var(--line); border-radius: .7em; overflow: hidden; box-shadow: var(--shadow); background: #fff; padding-block-end: .3rem; } .docview.narrow { max-inline-size: 24rem; margin-inline: auto; font-size: .85rem; }
.pd-addr { white-space: pre-line; }
.receipt-screen > .row { margin-block-start: .6rem; }

.toast { position: fixed; z-index: 60; inset-inline: 1rem; inset-block-start: 4.2rem; margin-inline: auto; max-inline-size: 28rem; padding: .8rem 1rem; border-radius: 14px; background: var(--ok-bg); color: var(--ok); border: 1px solid #86efac; font-weight: 600; box-shadow: 0 10px 30px rgb(30 27 75 / .2); text-align: center; } .toast.bad { background: var(--bad-bg); color: var(--bad); border-color: #fca5a5; }

.pd-qrbox { display: flex; gap: 0.75rem; align-items: center; border: 1px solid #ccc; border-radius: 6px; padding: 0.5rem 0.65rem; margin-block: 0.6rem; break-inside: avoid; }
.pd-qrbox .qr { width: 26mm; height: 26mm; flex: none; }
.pd-qrbox h4 { margin: 0 0 0.15rem; }
.pd-qrbox p { margin: 0 0 0.15rem; font-size: 0.8em; }
body.paper-80 .pd-qrbox { flex-direction: column; text-align: center; }
body.paper-80 .pd-qrbox .qr { width: 38mm; height: 38mm; }

/* Live effects on the customer tracking page (switched off for people who prefer less motion) */
.steps::after { content: ''; position: absolute; inset-block-start: .85rem; inset-inline-start: 10%; inline-size: calc(var(--p, 0) * 20%); block-size: 3px; background: var(--brand); transition: inline-size .8s ease; }
.steps li.now .dot { position: relative; }
.steps li.now .dot::before { content: ''; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid var(--brand); opacity: 0; }
.steps.s-received li.now .dot::before, .steps.s-diagnosing li.now .dot::before, .steps.s-ready li.now .dot::before { animation: track-ping 1.8s ease-out infinite; }
.steps.s-repairing li.now .dot::before { border-style: dashed; opacity: .9; animation: track-spin 2.4s linear infinite; }
.steps.s-waiting_parts li.now .dot { animation: track-blink 2s ease-in-out infinite; }
.steps.s-ready li.now .dot { animation: track-bob 1.4s ease-in-out infinite; }
.steps.s-collected li.done:last-child .dot { animation: track-pop .5s ease-out 1; }
.live { display: inline-flex; align-items: center; gap: .4rem; margin: .1rem 0 .3rem; padding: .15rem .6rem; border-radius: 99px; background: rgb(255 255 255 / .18); color: #fff; font-size: .75rem; font-weight: 600; }
.live i { inline-size: .5rem; block-size: .5rem; border-radius: 50%; background: #86efac; animation: track-blink 1.4s ease-in-out infinite; }
@keyframes track-ping { 0% { transform: scale(.8); opacity: .8; } 100% { transform: scale(1.5); opacity: 0; } }
@keyframes track-spin { to { transform: rotate(360deg); } }
@keyframes track-blink { 50% { opacity: .45; } }
@keyframes track-bob { 50% { transform: translateY(-3px); } }
@keyframes track-pop { 0% { transform: scale(.6); } 70% { transform: scale(1.2); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .steps *, .steps li .dot, .steps li .dot::before, .live i { animation: none !important; } .steps::after { transition: none; } }

.lic-banner { padding: .55rem 1rem; font-size: .85rem; font-weight: 600; text-align: center; }
.lic-banner.grace { background: #fef3c7; color: #92400e; }
.lic-banner.expired { background: #fee2e2; color: #991b1b; }

.langpick { inline-size: auto; min-inline-size: 0; padding: .35em .5em; border-radius: .5em; font-size: .85rem; }
.login-brand .langpick { margin-block-start: .6em; }
.offlinebar { padding: .55rem 1rem; font-size: .85rem; font-weight: 600; text-align: center; background: #ecfdf5; color: #065f46; display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; align-items: center; }
.offlinebar.down { background: #fef3c7; color: #92400e; }
.offlinebar .card { flex-basis: 100%; text-align: start; font-weight: 400; }
.scanner { position: fixed; inset: 0; z-index: 50; background: #000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; padding: 1rem; }
.scanner video { width: 100%; max-height: 70vh; object-fit: cover; border-radius: .75rem; background: #111; }
.scanner .scanhint { color: #fff; text-align: center; margin: 0; }
.pair-qr { max-width: 220px; } .pair-qr .qr { width: 100%; height: auto; display: block; }

/* Swiss QR-bill payment slip: receipt 62 mm, payment part, QR code 46 mm. Printed under invoices with an open balance. */
.qrb { display: flex; inline-size: 100%; block-size: 105mm; margin-block-start: 6mm; border-block-start: 1px dashed #000; break-inside: avoid; color: #000; font-family: Arial, Helvetica, sans-serif; }
.qrb h5 { margin: 0 0 3mm; font-size: 11pt; font-weight: 700; }
.qrb h6 { margin: 2.5mm 0 .5mm; font-size: 6pt; font-weight: 700; }
.qrb p { margin: 0; font-size: 8pt; line-height: 1.2; }
.qrb-receipt { inline-size: 62mm; padding: 5mm; border-inline-end: 1px dashed #000; display: flex; flex-direction: column; box-sizing: border-box; }
.qrb-receipt p { font-size: 8pt; }
.qrb-part { flex: 1; padding: 5mm; box-sizing: border-box; }
.qrb-main { display: flex; gap: 5mm; }
.qrb-code svg { display: block; inline-size: 46mm; block-size: 46mm; }
.qrb-info { flex: 1; min-inline-size: 0; }
.qrb-info p { font-size: 10pt; }
.qrb-amt { display: flex; gap: 6mm; margin-block-start: 3mm; }
.qrb-amt p { font-size: 10pt; }
.qrb-receipt .qrb-amt p { font-size: 8pt; }
.qrb-box { inline-size: 65mm; block-size: 20mm; border: .3mm solid #000; }
.qrb-receipt .qrb-box { inline-size: 52mm; block-size: 20mm; }
.qrb-accept { margin-block-start: auto; text-align: end; font-size: 6pt; font-weight: 700; }
body.paper-80 .qrb, body.paper-a5 .qrb { display: none; }

/* Spain: the tax office QR, 34 mm (the rules allow 30 to 40 mm) with a white margin. */
.fiscal-qr { margin-block-start: 3mm; text-align: center; }
.fiscal-qr p { margin: 0 0 1mm; font-size: 8pt; font-weight: 700; }
.fiscal-qr .qr { inline-size: 34mm; block-size: 34mm; }

/* Invoice in the Swiss style (SN 010130 letter layout): plain black on white, thin rules, QR payment slip at the foot of the A4 page. */
.pd.sw { display: flex; flex-direction: column; font: 10pt/1.35 Arial, Helvetica, sans-serif; color: #000; background: #fff; }
.sw-main { flex: 1; display: flex; flex-direction: column; padding: 8mm 10mm 4mm; }
.sw-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8mm; }
.sw-sender, .sw-contact { display: flex; flex-direction: column; font-size: 9pt; } .sw-contact { text-align: end; color: #333; }
.sw-sender .sw-name { font-size: 14pt; margin-block-end: 1mm; color: var(--b); } .sw-mark.lh-mark { inline-size: 14mm; block-size: 14mm; font-size: 11pt; border-radius: 3mm; margin-block-end: 2mm; } .sw-mark.has-logo { inline-size: auto; block-size: auto; } .sw-mark .lh-logo { block-size: 16mm; max-inline-size: 48mm; } .sw-mark { align-self: flex-start; } .sw-logo { max-block-size: 16mm; max-inline-size: 48mm; object-fit: contain; align-self: flex-start; margin-block-end: 2mm; }
.sw-window { margin-block: 14mm 0; margin-inline-start: 57%; min-block-size: 28mm; } .sw-window p { margin: 0; }
.sw-return { font-size: 6.5pt; color: #444; border-block-end: .2mm solid #444; padding-block-end: .6mm; margin-block-end: 2.5mm !important; }
.sw-place { margin: 10mm 0 0 !important; }
.sw-title { color: var(--b); font-size: 14pt; margin: 6mm 0 3mm; font-weight: 700; display: flex; align-items: baseline; gap: 4mm; }
.sw-status { font-size: 9pt; font-weight: 700; letter-spacing: .08em; border: .3mm solid; padding: 0 2mm; border-radius: 1mm; } .sw-status.ok { color: #15803d; } .sw-status.warn { color: #b45309; } .sw-status.bad { color: #b91c1c; }
.sw-meta { display: grid; grid-template-columns: repeat(auto-fill, minmax(42mm, 1fr)); gap: 2mm 6mm; margin: 0 0 6mm; padding-block: 2.5mm; border-block: .3mm solid var(--b-line); }
.sw-meta div { min-inline-size: 0; } .sw-meta dt { font-size: 7pt; color: #555; } .sw-meta dd { margin: 0; font-weight: 600; font-size: 9.5pt; }
.sw-items { inline-size: 100%; border-collapse: collapse; } .sw-items th { text-align: start; font-size: 8pt; font-weight: 700; padding: 1mm 1.5mm; color: var(--b); border-block-end: .5mm solid var(--b); } .sw-items td { padding: 1.6mm 1.5mm; vertical-align: top; border-block-end: .15mm solid #ccc; } .sw-items small { color: #555; font-size: 7.5pt; }
.sw-items .num, .sw-totals .num { text-align: end; white-space: nowrap; }
.sw-totals { margin-inline-start: auto; margin-block: 3mm 0; min-inline-size: 78mm; border-collapse: collapse; } .sw-totals td { padding: .9mm 1.5mm; }
.sw-totals tr.grand td { font-weight: 700; border-block: .4mm solid var(--b); background: var(--b-soft); padding-block: 1.6mm; } .sw-totals tr.due td { font-weight: 700; }
.sw-text { margin-block-start: 6mm; } .sw-text p { margin: 0 0 2mm; } .sw-small { font-size: 8pt; color: #444; } .sw-regards { margin-block-start: 5mm !important; }
.sw-foot { margin: auto 0 0; padding-block-start: 3mm; font-size: 7pt; color: #555; text-align: center; border-block-start: .2mm solid #999; }
.sw-main > .sw-text { margin-block-end: 6mm; }
.docview .pd.sw { padding: 0; } .docview .pd.sw .qrb { margin-block-start: 4mm; }
.pd.sw .qrb { margin-block-start: 0; }
.qrb-box { font-size: 8pt; line-height: 1.25; padding: 1mm 1.5mm; overflow: hidden; box-sizing: border-box; }
@media print {
  body.paper-a4 .pd.sw { min-block-size: 297mm; font-size: 10pt; }
  body.paper-a4 .sw-main { padding: 12mm 20mm 4mm; }
  body.paper-a4 .sw-window { margin-inline-start: 98mm; }
  body.paper-a4 .qrb { margin-block-start: 0; border-block-start: 0; }
  body.paper-a5 .pd.sw, body.paper-80 .pd.sw { font-size: 9pt; } body.paper-a5 .sw-window, body.paper-80 .sw-window { margin-inline-start: 0; } body.paper-80 .sw-top { flex-direction: column; }
}


.qrb-samplebar { margin: 4mm 10mm 0; padding: 1.5mm 3mm; border: .3mm solid #b91c1c; border-radius: 1mm; color: #b91c1c; font: 8pt Arial, Helvetica, sans-serif; text-align: center; }
/* The address window sits at 45 mm from the top of the sheet on paper; on screen it only needs a little air. */
.sw-window { margin-block: 6mm 0; min-block-size: 0; } .sw-place { margin-block-start: 6mm !important; }
@media print { body.paper-a4 .sw-window { margin-block-start: 14mm; min-block-size: 28mm; } body.paper-a4 .sw-place { margin-block-start: 10mm !important; } body.paper-a4 .qrb-samplebar { margin-inline: 20mm; } }

/* A4 Swiss invoice whose slip does not fit under the invoice: page 1 is the invoice with its footer at the bottom, the slip sits at the bottom of the next page. */
@media print {
  body.paper-a4 .pd.sw.sw-slip-apart { min-block-size: 0; }
  body.paper-a4 .pd.sw.sw-slip-apart .sw-main { min-block-size: 296mm; }
  body.paper-a4 .pd.sw.sw-slip-apart .qrb-sheet { break-before: page; block-size: 296.5mm; display: flex; flex-direction: column; justify-content: flex-end; }
}
/* A hidden copy of the invoice laid out like an A4 print, to measure whether the slip fits beneath it (see slipFitsBeneath). Keep in step with the A4 print rules above. */
.sw-measure { position: absolute; inset-inline-start: -10000px; inset-block-start: 0; inline-size: 210mm; visibility: hidden; }
.sw-measure .pd.sw { min-block-size: 0; }
.sw-measure .sw-main { flex: none; }
.sw-measure .qrb-samplebar { margin-inline: 20mm; }
.sw-measure .noprint { display: none !important; }

/*
 * A4 Swiss invoice, compact: the reference data (dates, terms, payment method) stands left of the address window instead of below it,
 * and spacing is tighter, so that an invoice of up to 3 items still leaves the 105 mm for the payment slip on the same page.
 * The window itself stays at 42 mm from the top of the sheet, where a window envelope expects it.
 * The same rules apply to the print (body.paper-a4, set only while printing) and to the hidden copy that measures it (.sw-measure).
 */
body.paper-a4 .pd.sw, .sw-measure .pd.sw { font-size: 9pt; }
body.paper-a4 .sw-main, .sw-measure .sw-main { display: grid; grid-template-columns: 92mm 1fr; column-gap: 6mm; grid-template-rows: repeat(7, auto) 1fr; padding: 12mm 20mm 2mm; }
body.paper-a4 .sw-top, .sw-measure .sw-top { grid-column: 1 / -1; grid-row: 1; }
body.paper-a4 .sw-meta, .sw-measure .sw-meta { grid-column: 1; grid-row: 2; align-self: start; display: block; margin: 14mm 0 0; padding-block: .8mm; }
body.paper-a4 .sw-meta div, .sw-measure .sw-meta div { display: flex; justify-content: space-between; gap: 3mm; padding-block: 0; line-height: 1.25; }
body.paper-a4 .sw-meta dd, .sw-measure .sw-meta dd { font-size: 8.5pt; text-align: end; }
body.paper-a4 .sw-window, .sw-measure .sw-window { grid-column: 2; grid-row: 2; margin: 14mm 0 0; min-block-size: 24mm; }
body.paper-a4 .sw-place, .sw-measure .sw-place { grid-column: 1 / -1; grid-row: 3; margin: 3mm 0 0 !important; }
body.paper-a4 .sw-title, .sw-measure .sw-title { grid-column: 1 / -1; grid-row: 4; margin: 3mm 0 2mm; }
body.paper-a4 .sw-items, .sw-measure .sw-items { grid-column: 1 / -1; grid-row: 5; }
body.paper-a4 .sw-items td, .sw-measure .sw-items td { padding-block: .8mm; }
body.paper-a4 .sw-totals, .sw-measure .sw-totals { grid-column: 1 / -1; grid-row: 6; justify-self: end; margin-block-start: 2mm; }
body.paper-a4 .sw-totals td, .sw-measure .sw-totals td { padding-block: .5mm; }
body.paper-a4 .sw-totals tr.grand td, .sw-measure .sw-totals tr.grand td { padding-block: 1mm; }
body.paper-a4 .sw-text, .sw-measure .sw-text { grid-column: 1 / -1; grid-row: 7; margin-block-start: 3mm; }
body.paper-a4 .sw-text p, .sw-measure .sw-text p { margin-block-end: .6mm; }
body.paper-a4 .sw-regards, .sw-measure .sw-regards { margin-block-start: 2mm !important; }
body.paper-a4 .sw-main > .sw-text, .sw-measure .sw-main > .sw-text { margin-block-end: 3mm; }
body.paper-a4 .sw-foot, .sw-measure .sw-foot { grid-column: 1 / -1; grid-row: 8; align-self: end; margin: 0; padding-block-start: 2mm; }

/* colour choice in Settings */
.swatches { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin-block-start: .3rem; } .swatch { inline-size: 2rem; block-size: 2rem; padding: 0; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1px #cbd5e1; cursor: pointer; } .swatch.on { box-shadow: 0 0 0 3px #111; } .swatches input[type=color] { inline-size: 2.4rem; block-size: 2.4rem; padding: 0; border: 0; background: none; }

/* tillcat Business: accounting tables */
table.rep { width: 100%; border-collapse: collapse; margin: .4rem 0; font-size: .95rem; }
table.rep th { text-align: start; font-size: .8rem; color: var(--muted); border-block-end: 1px solid var(--line); padding: .35rem .3rem; }
table.rep td { padding: .35rem .3rem; border-block-end: 1px solid var(--line); vertical-align: top; }
table.rep .num { text-align: end; white-space: nowrap; font-variant-numeric: tabular-nums; }
table.rep tr.head td { font-weight: 700; background: var(--brand-soft); border-block-end: 0; }
table.rep tr.total td { font-weight: 700; border-block-start: 2px solid var(--ink); }
label.check { display: flex; align-items: center; gap: .5rem; font-weight: 400; color: var(--ink); }
@media print { .noprint, header, nav.tabs { display: none !important; } body { background: #fff; } .shell { max-width: none; padding: 0; } .card { box-shadow: none; border: 0; } }

/* Swiss QR-bill payment slip: receipt 62 mm, payment part, QR code 46 mm. Printed at the foot of an invoice with an open balance. */
.qrb { display: flex; inline-size: 100%; block-size: 105mm; margin-block-start: 6mm; border-block-start: 1px dashed #000; break-inside: avoid; color: #000; font-family: Arial, Helvetica, sans-serif; background: #fff; }
.qrb h5 { margin: 0 0 3mm; font-size: 11pt; font-weight: 700; }
.qrb h6 { margin: 2.5mm 0 .5mm; font-size: 6pt; font-weight: 700; }
.qrb p { margin: 0; font-size: 8pt; line-height: 1.2; }
.qrb-receipt { inline-size: 62mm; padding: 5mm; border-inline-end: 1px dashed #000; display: flex; flex-direction: column; box-sizing: border-box; }
.qrb-receipt p { font-size: 8pt; }
.qrb-part { flex: 1; padding: 5mm; box-sizing: border-box; }
.qrb-main { display: flex; gap: 5mm; }
.qrb-code svg { display: block; inline-size: 46mm; block-size: 46mm; }
.qrb-info { flex: 1; min-inline-size: 0; }
.qrb-info p { font-size: 10pt; }
.qrb-amt { display: flex; gap: 6mm; margin-block-start: 3mm; }
.qrb-amt p { font-size: 10pt; }
.qrb-receipt .qrb-amt p { font-size: 8pt; }
.qrb-box { inline-size: 65mm; block-size: 20mm; border: .3mm solid #000; font-size: 8pt; line-height: 1.25; padding: 1mm 1.5mm; overflow: hidden; box-sizing: border-box; }
.qrb-receipt .qrb-box { inline-size: 52mm; block-size: 20mm; }
.qrb-accept { margin-block-start: auto; text-align: end; font-size: 6pt; font-weight: 700; }
.qrb-sheet { overflow-x: auto; }

/* The invoice on an A4 sheet with the payment slip at the foot of the page (the page has no margin so the slip has its full 210 mm). */
@page invoice { size: A4 portrait; margin: 0; }
.invoice-page { page: invoice; }
@media print {
  .invoice-page { display: flex !important; flex-direction: column; min-block-size: 297mm; padding: 0 !important; margin: 0 !important; border-radius: 0 !important; }
  .invoice-page .invoice-body { flex: 1; padding: 12mm 20mm 4mm; }
  .invoice-page .qrb-sheet { margin-block-start: auto; overflow: visible; }
  .invoice-page .qrb { margin-block-start: 0; border-block-start: 0; }
}

/* Computer layout: pick by typing, the lines as a table, the list beside the open document, a fuller overview */
.combo { position: relative; }
.combo ul { position: absolute; z-index: 20; inset-inline: 0; inset-block-start: 100%; margin: .15rem 0 0; padding: .25rem; list-style: none; max-block-size: 18rem; overflow-y: auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: 0 10px 30px rgb(30 27 75 / .18); }
.combo li { display: flex; justify-content: space-between; gap: .75rem; padding: .5rem .6rem; border-radius: .5rem; cursor: pointer; font-weight: 500; color: var(--ink); }
.combo li small { color: var(--muted); font-weight: 400; white-space: nowrap; }
.combo li.hi { background: var(--brand-soft); }
.combo li.none { color: var(--muted); cursor: default; }
.combo-x { position: absolute; inset-inline-end: .4rem; inset-block-start: .7rem; min-block-size: 0; margin: 0; padding: .1rem .5rem; }
.topgrid { display: grid; grid-template-columns: 1fr; gap: 0 .75rem; }
.topgrid > label { min-inline-size: 0; }
.editor { max-width: 90rem; }
@media (min-width: 40rem) { .topgrid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 64rem) { .topgrid { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.3fr); } }
.addbar { display: flex; flex-wrap: wrap; align-items: end; gap: .25rem 1rem; margin: .5rem 0; }
.addbar .grow { flex: 1 1 18rem; margin: .5rem 0 0; }
.addbar .check { margin: 0 0 .65rem; white-space: nowrap; }
.addbar > button { margin-block-end: .35rem; }
.tablewrap { overflow-x: auto; margin: .5rem 0; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; }
table.lines { width: 100%; border-collapse: collapse; min-width: 38rem; }
table.lines th { padding: .45rem .5rem; text-align: start; font-size: .75rem; color: var(--muted); background: #faf9ff; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.lines td { padding: .3rem .35rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.lines tr:last-child td { border-bottom: 0; }
table.lines th.num, table.lines td.num { text-align: end; }
table.lines input, table.lines select { margin: 0; min-block-size: 2.3rem; padding: .3rem .5rem; font-size: .92rem; }
table.lines input.n { text-align: end; inline-size: 4.8rem; }
table.lines input.u { inline-size: 3.8rem; }
table.lines input.d { min-inline-size: 10rem; }
table.lines select { inline-size: 5.2rem; }
table.lines .pos { color: var(--muted); text-align: center; inline-size: 1.6rem; }
table.lines .amt { font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
table.lines button.x { min-block-size: 2rem; margin: 0; padding: .1rem .6rem; font-size: 1.2rem; line-height: 1; }
.foot { display: grid; grid-template-columns: 1fr; gap: 0 1.5rem; align-items: start; }
@media (min-width: 48rem) { .foot { grid-template-columns: 1fr 22rem; } }
.item.sel { border-color: var(--brand); background: var(--brand-soft); }
p.empty { display: block; }
@media (min-width: 64rem) { main.wide { max-width: 100rem; } }
@media (min-width: 80rem) {
  .split { display: grid; grid-template-columns: 20rem minmax(0, 1fr); gap: 1.25rem; align-items: start; }
  .split > aside { position: sticky; inset-block-start: .5rem; max-block-size: calc(100vh - 6rem); overflow-y: auto; padding-inline-end: .25rem; }
  .split > section > .card:first-child { margin-block-start: 0; }
  .split > section > .row.noprint:first-child { margin-block-start: 0; }
}
.dashgrid { display: grid; grid-template-columns: 1fr; gap: 1rem; margin-block-start: 1rem; }
@media (min-width: 64rem) { .dashgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 100rem) { .dashgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.dashgrid > .card { margin: 0; }
.dashgrid .item { margin: .3rem 0; min-block-size: 3rem; }
@media (min-width: 100rem) { .split { grid-template-columns: 24rem minmax(0, 1fr); } }
@media print { .split { display: block; } .split > aside { display: none; } }
/* the tablet rule above caps the page at 56rem; on a computer the page uses the whole window next to the side menu */
@media (min-width: 64rem) { .shell { max-width: none; } }

/* weights in g or kg; the sample slip under an invoice that has none yet */
.wf { display: flex; gap: .25rem; align-items: stretch; }
.wf input { flex: 1 1 auto; min-inline-size: 0; }
.wf select { flex: none; inline-size: 4.4rem; }
table.lines .wf input { inline-size: 4.6rem; text-align: end; }
table.lines .wf select { inline-size: 4.2rem; }
.demo-slip { margin-block-start: 1rem; opacity: .85; }
.topgrid label button.link { display: block; margin: .1rem 0 0; padding: 0; font-size: .78rem; min-block-size: 0; }

/* quantity with + and -, short headings, no sideways scrolling for the line table */
.qty { display: flex; align-items: stretch; gap: .15rem; }
.qty button { flex: none; min-block-size: 2.3rem; inline-size: 1.9rem; margin: 0; padding: 0; font-size: 1.1rem; line-height: 1; }
table.lines .qty input.n { inline-size: 3.9rem; text-align: center; }
table.lines { min-width: 0; table-layout: auto; }
table.lines th { white-space: nowrap; }
table.lines td { padding: .25rem .25rem; }
table.lines input.d { min-inline-size: 8rem; inline-size: 100%; }
table.lines input.n { inline-size: 5.4rem; }
table.lines input.u { inline-size: 4.8rem; }
table.lines select { inline-size: 4.8rem; }
table.lines .wf input { inline-size: 4.4rem; }
table.lines .wf select { inline-size: 3.9rem; }
.sortsel { margin: .5rem 0 .65rem; }
.sortsel select { margin-top: .15rem; min-block-size: 2.4rem; }
.stockbox { margin: .75rem 0; padding: .6rem .9rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #faf9ff; }
.stockbox h3 { margin: 0 0 .25rem; }

/* the invoice on screen: a Swiss business letter */
.invoice-page .inv-head { display: flex; justify-content: space-between; gap: 1rem; padding-bottom: .6rem; border-bottom: 2px solid var(--brand-deep); }
.invoice-page .inv-head h3 { margin: 0 0 .2rem; font-size: 1.25rem; }
.invoice-page .inv-head p { margin: 0; }
.invoice-page .inv-contact { text-align: end; font-size: .85rem; }
.invoice-page .inv-addr { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; margin: 1.1rem 0 .6rem; }
.invoice-page .inv-meta { display: grid; grid-template-columns: auto 1fr; gap: .2rem 1rem; margin: 0; align-content: start; }
.invoice-page .inv-meta dt { color: var(--muted); font-size: .85rem; }
.invoice-page .inv-meta dd { margin: 0; font-weight: 650; }
.invoice-page address { font-style: normal; line-height: 1.45; }
.invoice-page .inv-title { margin: .8rem 0 .6rem; font-size: 1.5rem; letter-spacing: .02em; }
.invoice-page table.rep thead th { background: #eceef5; padding-block: .4rem; }
.invoice-page table.rep td { border-bottom: 1px solid #e3e5ee; }

.addrs { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem 2rem; margin: .5rem 0 .8rem; padding: .7rem .9rem; background: var(--brand-soft); border-radius: var(--radius-sm); align-items: start; }
.addrs address { font-style: normal; line-height: 1.45; }
.addrs textarea { inline-size: 100%; }
@media (max-width: 40rem) { .addrs { grid-template-columns: 1fr; } }
.inv-rcpt address { margin: 0 0 .5rem; }
.inv-rcpt small { display: block; }

.invoice-page .inv-head { border-block-start: 6px solid var(--brand-deep); padding-block-start: .9rem; align-items: flex-start; }
.invoice-page .inv-head .mono { flex: none; display: grid; place-items: center; inline-size: 2.8rem; block-size: 2.8rem; border-radius: .6rem; background: var(--brand-deep); color: #fff; font-weight: 800; font-size: 1.1rem; }
.invoice-page .inv-head h3 { color: var(--brand-deep); }

/* The sidebar has many entries: on a low window it scrolls, so Settings (the last one) can always be reached */
@media (min-width: 64rem) {
  .tabs { overflow-y: auto; overscroll-behavior: contain; }
  .tabs button { min-block-size: 2.6rem; }
}
@media (min-width: 64rem) and (max-height: 50rem) {
  .tabs button { min-block-size: 2.3rem; padding-block: .3rem; }
  .side-brand { padding-block-end: .6rem; }
}

/* the invoice on a phone: the head and the addresses stack, the table scrolls inside the sheet */
@media (max-width: 40rem) {
  .invoice-page .inv-head { flex-wrap: wrap; }
  .invoice-page .inv-contact { text-align: start; inline-size: 100%; }
  .invoice-page .inv-addr { grid-template-columns: 1fr; gap: 1rem; }
  .invoice-body { overflow-x: auto; }
}

.logofield { margin-block-end: .8rem; }
.logobox { display: grid; place-items: center; min-block-size: 5rem; max-inline-size: 22rem; padding: .6rem; margin-block-end: .5rem; background: #fff; border: 1px dashed var(--line); border-radius: var(--radius-sm); }
.logobox img { max-inline-size: 100%; max-block-size: 6rem; object-fit: contain; }
.filebtn { display: inline-flex; align-items: center; justify-content: center; min-block-size: 2.75rem; padding: .5rem 1rem; border-radius: var(--radius-sm); background: var(--brand-soft); color: var(--brand-deep); font-weight: 600; cursor: pointer; }
.filebtn input { position: absolute; inline-size: 1px; block-size: 1px; opacity: 0; }
.filebtn:focus-within { outline: 2px solid var(--brand); outline-offset: 2px; }
/* not .logo: that class is the app's own 2 rem brand icon */
.invoice-page .inv-head img.co-logo { flex: none; inline-size: auto; block-size: 3.4rem; max-inline-size: 10rem; object-fit: contain; align-self: center; }

.itemgroup { margin-block: .6rem; padding: .5rem .6rem .2rem; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.itemgroup > .row { align-items: baseline; gap: .6rem; margin-block-end: .3rem; }
.itemgroup > .row .link { margin-inline-start: auto; }
.item.sub { margin-block: .25rem; box-shadow: none; border-radius: .6rem; background: var(--brand-soft); }

.discskonto { align-items: end; margin-block: .6rem; }
.skontorow { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }

/* Invoices: the filters sit in the title row; an open invoice has the whole page with the invoices of the filter in a strip above it */
.topbar { align-items: center; flex-wrap: wrap; gap: .5rem 1rem; }
.topbar h2 { margin: 0; }
.topbar .chips { flex: 1 1 auto; margin: 0; }
.topbar > .primary { margin-inline-start: auto; }
.strip { display: flex; gap: .6rem; overflow-x: auto; padding-block: .2rem .7rem; margin-block-end: .4rem; }
.strip .item { flex: 0 0 17rem; margin: 0; }
.fullpane { max-inline-size: 68rem; margin-inline: auto; }
@media (min-width: 64rem) { .cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(22rem, 1fr)); gap: .6rem; } .cards .item { margin: 0; } }
@media print { .topbar, .strip { display: none; } .fullpane { max-inline-size: none; } }

/* an invoice, quote or delivery note on the page is a document, not a pop-up sheet: the page width, scrolling with the page */
.card.sheet.invoice-page { max-inline-size: none; max-block-size: none; overflow: visible; animation: none; }

/* the strip above an open invoice is a compact row of small cards: number and customer, amount and status */
.strip { gap: .4rem; padding-block: .1rem .5rem; }
.strip .item { flex: 0 0 13rem; min-block-size: 0; padding: .3rem .6rem; gap: .5rem; font-size: .82rem; border-radius: .6rem; box-shadow: none; }
.strip .item .grow { min-inline-size: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.strip .item .grow small { display: none; }
.strip .item .right { flex: none; font-size: .82rem; line-height: 1.25; }
.strip .item .right small { font-size: .7rem; }
.strip .item { min-inline-size: 0; max-inline-size: 13rem; overflow: hidden; }

.topbar .topbtns { display: flex; gap: .5rem; margin-inline-start: auto; flex: none; }
.topbar .topbtns button { margin: 0; }

/* Printable pages (reports, statements, supplier invoices, the driver sheet) are "card sheet": a whole page, not the pop-up that ".sheet" is. */
.card.sheet { max-width: none; max-height: none; overflow: visible; border-radius: var(--radius); animation: none; }
.card.sheet:not(.invoice-page) { background: var(--surface); }
@media print { .card.sheet:not(.invoice-page) { padding: 0; margin: 0; border: 0; border-radius: 0; box-shadow: none; background: #fff; } main { animation: none; } .shell { margin: 0; max-width: none; } }

/* Side menu: groups, compact rows */
.nav-group { display: none; }
@media (min-width: 64rem) {
  .tabs { gap: .1rem; padding: .8rem .7rem; }
  .side-brand { padding-block-end: .5rem; }
  .nav-group { display: block; margin: .55rem 0 .1rem; padding-inline: .8rem; font-size: .68rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: #8b88ad; }
  .nav-group:empty { block-size: 1px; margin: .5rem .8rem .3rem; padding: 0; background: var(--line); }
  .tabs button { min-block-size: 2.15rem; padding: .3rem .8rem; border-radius: 10px; font-size: .92rem; }
  .tabs button.on { box-shadow: inset 3px 0 0 var(--brand); }
}

/* The driver sheet (A4) */
@page drv { size: A4 portrait; margin: 11mm 12mm; }
.drv { page: drv; color: #111; max-inline-size: 52rem !important; }
.drv h1, .drv h2, .drv p, .drv dl, .drv dd { margin: 0; }
.drv-head { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-end; padding-block-end: .6rem; border-block-end: 3px solid var(--brand-deep); }
.drv-head p { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.drv-head h1 { font-size: 1.6rem; color: var(--brand-deep); }
.drv-head dl { display: grid; grid-template-columns: auto auto; gap: .05rem .8rem; font-size: .9rem; } .drv-head dt { color: var(--muted); } .drv-head dd { font-weight: 700; text-align: end; }
.drv-sum { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; margin-block: .7rem; }
.drv-sum div { border: 1px solid #c9c7db; border-radius: 8px; padding: .4rem .6rem; } .drv-sum span { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); } .drv-sum b { font-size: 1.25rem; margin-inline-end: .35rem; }
.drv h2 { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--brand-deep); margin-block: .8rem .35rem; }
.drv table { inline-size: 100%; border-collapse: collapse; font-size: .88rem; }
.drv th { text-align: start; font-size: .72rem; color: var(--muted); border-block-end: 1px solid #555; padding: .15rem .35rem; }
.drv td { padding: .16rem .35rem; border-block-end: 1px solid #e4e3ee; vertical-align: top; }
.drv .num { text-align: end; white-space: nowrap; inline-size: 4.5rem; font-variant-numeric: tabular-nums; } .drv td:nth-child(2):not(.num) { inline-size: 5rem; } .drv .tick { inline-size: 2rem; }
.drv .box { display: inline-block; inline-size: .95rem; block-size: .95rem; border: 1.5px solid #222; border-radius: 3px; vertical-align: -.15rem; }
.drv-stop { display: grid; grid-template-columns: 2.4rem 1fr; gap: .6rem; border: 1px solid #b9b7cf; border-radius: 10px; padding: .55rem .7rem; margin-block-end: .55rem; break-inside: avoid; page-break-inside: avoid; }
.drv-no { display: grid; place-items: center; inline-size: 2.1rem; block-size: 2.1rem; border-radius: 50%; background: var(--brand-deep); color: #fff; font-weight: 800; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.drv-top { display: flex; justify-content: space-between; gap: .6rem; } .drv-top strong { font-size: 1.05rem; } .drv-top span { color: var(--muted); white-space: nowrap; font-size: .85rem; }
.drv-addr { font-size: .98rem; } .drv-phone { font-size: .85rem; color: var(--muted); }
.drv-body table { margin-block: .3rem; } .drv-body td:first-child { inline-size: 3.5rem; text-align: end; }
.drv-money { display: flex; flex-wrap: wrap; gap: .2rem 1.1rem; font-size: .84rem; }
.drv-fill, .drv-foot { display: flex; align-items: flex-end; gap: 1rem; margin-block-start: .45rem; font-size: .8rem; }
.drv .line { flex: 1; border-block-end: 1px solid #333; padding-block-start: 1.1rem; } .drv .line.wide { flex: 2.2; }
.drv-foot { margin-block-start: 1.4rem; break-inside: avoid; }
@media (max-width: 40rem) { .drv-head { flex-direction: column; align-items: stretch; } .drv-sum { grid-template-columns: 1fr; } .drv-fill, .drv-foot { flex-wrap: wrap; } }
@media print { .drv { font-size: 12px; max-inline-size: none !important; } .drv-sum b { font-size: 1.1rem; } }

/* The first screen (Overview) */
.ov { --rev: #5B4BE8; --exp: #D9730D; }
.ov button { box-shadow: none; }
.ov-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: .8rem; margin-block: .2rem 1rem; }
.ov-head h2 { margin: 0; font-size: 1.6rem; letter-spacing: -.025em; } .ov-date { margin: 0 0 .1rem; font-size: .8rem; color: var(--muted); }
.ov-actions { display: flex; flex-wrap: wrap; gap: .5rem; } .ov-actions button { display: inline-flex; align-items: center; gap: .4rem; margin: 0; min-block-size: 2.5rem; border-radius: 12px; font-size: .9rem; }
.ov-top { display: grid; gap: .9rem; }
.ov-hero { display: flex; flex-direction: column; gap: .2rem; padding: 1.4rem 1.5rem; border-radius: 22px; color: #fff; background: radial-gradient(110% 130% at 100% 0%, rgb(139 125 255 / .65), transparent 55%), linear-gradient(150deg, #2B2570, #17143A 75%); box-shadow: 0 18px 40px rgb(30 27 75 / .22); }
.ov-hero > span { font-size: .8rem; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; color: rgb(255 255 255 / .72); }
.ov-hero > b { font-size: 2.7rem; font-weight: 750; letter-spacing: -.035em; line-height: 1.15; overflow-wrap: anywhere; } .ov-hero > b small { margin-inline-end: .4rem; font-size: 1rem; font-weight: 600; color: rgb(255 255 255 / .7); letter-spacing: 0; }
.ov-hero p { margin: 0; font-size: .82rem; color: rgb(255 255 255 / .62); }
.ov-hero dl { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; margin: auto 0 0; padding-block-start: 1.1rem; border-block-start: 1px solid rgb(255 255 255 / .14); } .ov-hero dt { font-size: .76rem; color: rgb(255 255 255 / .65); } .ov-hero dd { margin: 0; font-size: 1.2rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.ov .card { margin: 0; }
.ov-chart { padding: 1.1rem 1.2rem; min-inline-size: 0; }
.ov-chart-head { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1rem; } .ov-chart-head h3 { margin: 0; flex: 1 1 auto; } .ov-chart-head .link { margin: 0; min-block-size: 0; font-size: .8rem; }
.ov-legend { display: flex; flex-direction: column; gap: .25rem; margin: .6rem 0; padding: 0; list-style: none; font-size: .82rem; color: var(--muted); } .ov-legend li { display: flex; align-items: center; gap: .45rem; } .ov-legend li b { margin-inline-start: auto; color: var(--ink); font-variant-numeric: tabular-nums; }
.ov-legend.inline { flex-direction: row; gap: .9rem; margin: 0; }
.ov-legend i, .ov-tip i { flex: none; inline-size: .65rem; block-size: .65rem; border-radius: 3px; } .ov i.rev { background: var(--rev); } .ov i.exp { background: var(--exp); }
.ov-plot { position: relative; display: flex; gap: .5rem; block-size: 13rem; margin-block-start: 1rem; }
.ov-axis { display: flex; flex-direction: column; justify-content: space-between; inline-size: 2.5rem; padding-block-end: 1.35rem; font-size: .7rem; text-align: end; color: var(--muted); font-variant-numeric: tabular-nums; } .ov-axis span { line-height: 0; }
.ov-cols12 { position: relative; flex: 1; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); background: linear-gradient(var(--line), var(--line)) 0 0 / 100% 1px no-repeat, linear-gradient(var(--line), var(--line)) 0 calc((100% - 1.35rem) / 2) / 100% 1px no-repeat; }
.ov .ov-month { display: flex; flex-direction: column; min-inline-size: 0; min-block-size: 0; margin: 0; padding: 0; border: 0; border-radius: 8px; background: transparent; gap: 0; } .ov .ov-month.on { background: rgb(91 75 232 / .07); }
.ov-bars { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 2px; inline-size: 100%; padding-inline: 12%; border-block-end: 1px solid #b9b6d3; }
.ov-bars span { flex: 1; max-inline-size: .85rem; border-radius: 4px 4px 0 0; } .ov-bars .rev { background: var(--rev); } .ov-bars .exp { background: var(--exp); }
.ov-mname { block-size: 1.35rem; line-height: 1.5rem; font-size: .68rem; font-weight: 500; color: var(--muted); white-space: nowrap; overflow: hidden; }
.ov-tip { position: absolute; inset-block-start: -.4rem; z-index: 5; display: grid; gap: .15rem; min-inline-size: 12rem; padding: .55rem .7rem; border-radius: 12px; background: #fff; border: 1px solid var(--line); box-shadow: 0 10px 28px rgb(30 27 75 / .18); font-size: .8rem; pointer-events: none; } .ov-tip span { display: flex; align-items: center; gap: .4rem; color: var(--muted); } .ov-tip b { margin-inline-start: auto; padding-inline-start: .8rem; color: var(--ink); font-variant-numeric: tabular-nums; }
.ov-money { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem; margin-block: .9rem; }
.ov .ov-kpi { display: grid; grid-template-columns: auto 1fr; align-content: start; align-items: center; justify-items: start; gap: .1rem .6rem; margin: 0; padding: 1rem 1.1rem; text-align: start; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); font-weight: 400; transition: transform .15s ease, box-shadow .15s ease; }
.ov .ov-kpi:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgb(30 27 75 / .12); }
.ov-kpi i { display: grid; place-items: center; inline-size: 2.2rem; block-size: 2.2rem; border-radius: 11px; background: var(--brand-soft); color: var(--brand-strong); font-style: normal; }
.ov-kpi span { font-size: .8rem; color: var(--muted); } .ov-kpi b { grid-column: 1 / -1; margin-block-start: .5rem; font-size: 1.55rem; letter-spacing: -.02em; color: var(--ink); font-variant-numeric: tabular-nums; } .ov-kpi em { grid-column: 1 / -1; font-size: .78rem; font-style: normal; font-weight: 600; } .ov-kpi em.bad { color: var(--bad); }
.ov-cols { display: grid; gap: .9rem; } .ov-cols > div { display: flex; flex-direction: column; gap: .9rem; min-inline-size: 0; }
.ov-card { padding: .9rem 1.1rem .6rem; } .ov-title { display: flex; align-items: center; justify-content: space-between; gap: .6rem; margin-block-end: .2rem; } .ov-title h3 { margin: 0; } .ov-title .link { margin: 0; min-block-size: 0; font-size: .82rem; }
.ov .ov-line { display: flex; align-items: center; gap: .7rem; inline-size: 100%; min-block-size: 3.3rem; margin: 0; padding: .45rem .2rem; border: 0; border-block-start: 1px solid #eeecf7; border-radius: 0; background: transparent; color: var(--ink); text-align: start; font-weight: 400; } .ov .ov-title + .ov-line { border-block-start: 0; }
.ov button.ov-line:hover { background: #f8f7fe; }
.ov-line .grow strong { display: block; font-size: .93rem; font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .ov-line .grow small { display: block; font-size: .78rem; }
.ov-amt { flex: none; min-inline-size: 5.5rem; text-align: end; font-weight: 700; font-variant-numeric: tabular-nums; }
.ov-badge { flex: none; padding: .15rem .55rem; border-radius: 999px; font-size: .7rem; font-weight: 700; white-space: nowrap; } .ov-badge.is-bad { background: var(--bad-bg); color: var(--bad); } .ov-badge.is-warn { background: var(--warn-bg); color: var(--warn); } .ov-badge.is-good { background: var(--ok-bg); color: var(--ok); }
.ov-ico { flex: none; display: grid; place-items: center; inline-size: 2.2rem; block-size: 2.2rem; border-radius: 11px; font-style: normal; background: var(--brand-soft); color: var(--brand-strong); } .ov-ico.is-bad { background: var(--bad-bg); color: var(--bad); } .ov-ico.is-warn { background: var(--warn-bg); color: var(--warn); }
.ov-clear { display: flex; align-items: center; gap: .5rem; color: var(--ok); font-weight: 600; }
.ov-age { display: flex; gap: 2px; block-size: .7rem; margin-block-start: .5rem; border-radius: 999px; overflow: hidden; } .ov-age span { flex-basis: 0; min-inline-size: 4px; }
.ov-foot { font-size: .76rem; }
@media (min-width: 64rem) { .ov-money { grid-template-columns: repeat(4, minmax(0, 1fr)); } .ov-cols { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: start; } }
@media (min-width: 75rem) { .ov-top { grid-template-columns: minmax(0, 1fr) minmax(0, 2.1fr); } }
@media (max-width: 30rem) { .ov-hero > b { font-size: 2.1rem; } .ov-kpi b { font-size: 1.25rem; } .ov-month:nth-child(odd) .ov-mname { visibility: hidden; } .ov-badge { display: none; } }
@media (min-width: 64rem) and (max-height: 48rem) { .tabs { padding-block: .4rem; } .side-brand { padding-block: 0 .2rem; } .nav-group { margin-block: .3rem 0; } .tabs button { min-block-size: 1.95rem; padding-block: .15rem; font-size: .88rem; } }
.drv-load th:nth-child(3), .drv-load td:nth-child(3), .drv-body td:nth-child(2) { inline-size: 6rem; white-space: nowrap; } .drv-load th:last-child, .drv-load td:last-child, .drv-body td:last-child { inline-size: auto; } .drv-load table, .drv-body table { table-layout: auto; } .drv td:last-child { width: 100%; }
/* on a phone what needs doing comes first */
@media (max-width: 63.99rem) { .ov-cols > div { display: contents; } .ov-cols .ov-todo { order: -1; } }
@media print { .drv { font-size: 11px; line-height: 1.3; } .drv h1 { font-size: 1.4rem; } .drv-sum { margin-block: .45rem; } .drv h2 { margin-block: .45rem .2rem; } .drv-stop { padding: .3rem .55rem; margin-block-end: .35rem; gap: .5rem; border-radius: 7px; } .drv-no { inline-size: 1.6rem; block-size: 1.6rem; font-size: .8rem; } .drv-top strong { font-size: .98rem; } .drv-addr { font-size: .9rem; } .drv table { font-size: .82rem; } .drv td { padding-block: .06rem; } .drv-body table { margin-block: .15rem; } .drv-fill { margin-block-start: .15rem; } .drv-fill .line { padding-block-start: .85rem; } .drv-foot { margin-block-start: .9rem; } }
/* on paper only the document: no screen padding, strips or tinted background; an invoice with its payment slip fits one page */
@media print { main { padding: 0; } .topbar, .strip { display: none !important; } .fullpane { margin: 0; padding: 0; } .card.sheet.invoice-page { background: #fff; margin: 0 !important; } .invoice-page { min-block-size: 296mm !important; } }

/* Deliveries: the day's board and the drivers */
.dv button { box-shadow: none; margin: 0; }
.dv h3 { display: flex; align-items: center; gap: .5rem; margin: 0 0 .6rem; }
.dv small { display: block; font-size: .78rem; }
.dv-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1rem; margin-block: .3rem .9rem; }
.dv-date { display: flex; align-items: center; gap: .35rem; } .dv-date input { margin: 0; inline-size: auto; min-block-size: 2.5rem; } .dv-date button { min-block-size: 2.5rem; min-inline-size: 2.5rem; padding-inline: .6rem; } .dv-date .next svg { transform: scaleX(-1); }
.dv-day { flex: 1 1 auto; font-size: 1.05rem; }
.dv-actions { display: flex; flex-wrap: wrap; gap: .5rem; } .dv-actions button { display: inline-flex; align-items: center; gap: .35rem; min-block-size: 2.5rem; } .dv-actions .dv-confirm { border-color: var(--warn); color: var(--warn); }
.dv-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; margin-block-end: .9rem; }
.dv-stats > div { padding: .8rem 1rem; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); }
.dv-stats > div > span:first-child { display: block; font-size: .76rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.dv-stats b { font-size: 1.7rem; letter-spacing: -.02em; font-variant-numeric: tabular-nums; } .dv-stats b em { font-size: 1rem; font-style: normal; color: var(--muted); } .dv-stats > div.attention { border-color: #f1c27a; background: #fffaf0; } .dv-stats > div.attention b { color: var(--warn); }
.dv-meter { display: block; block-size: .4rem; margin-block-start: .35rem; border-radius: 999px; background: #e8e6f5; overflow: hidden; } .dv-meter i { display: block; block-size: 100%; background: var(--ok); }
.dv-banner { display: flex; flex-wrap: wrap; align-items: center; gap: .7rem; padding: .7rem 1rem; margin-block-end: .9rem; border-radius: 14px; background: var(--ok-bg); color: #0f5c2e; font-weight: 600; } .dv-banner button { background: #fff; }
.dv-note { display: flex; align-items: center; gap: .5rem; padding: .6rem .9rem; border-radius: 12px; background: var(--brand-soft); color: var(--brand-deep); font-weight: 600; } .dv-note.warnish, .dv-tag.warnish { background: var(--warn-bg); color: var(--warn); }
.dv-cols { display: grid; gap: 1rem; align-items: start; } .dv-cols > section { min-inline-size: 0; }
.dv-count { padding: .05rem .55rem; border-radius: 999px; background: var(--brand-soft); color: var(--brand-strong); font-size: .78rem; font-weight: 700; }
.dv-empty { padding: 1.4rem; border: 1px dashed #c9c6e0; border-radius: 16px; text-align: center; color: var(--muted); }
.dv-group, .dv-driver { background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); margin-block-end: .8rem; }
.dv-group { overflow: hidden; }
.dv-ghead { display: flex; align-items: center; gap: .7rem; padding: .7rem .9rem; background: #f8f7fe; border-block-end: 1px solid var(--line); } .dv-ghead strong { font-size: .98rem; }
.dv input[type=checkbox] { flex: none; inline-size: 1.15rem; block-size: 1.15rem; margin: 0; accent-color: var(--brand); }
.dv-sum { text-align: end; font-weight: 700; font-size: .88rem; white-space: nowrap; }
.dv-tag { margin: .5rem .9rem 0; padding: .35rem .6rem; border-radius: 8px; font-size: .8rem; font-weight: 600; } .dv-tag.bad { background: var(--bad-bg); color: var(--bad); }
.dv-group ul, .dv-driver ol { margin: 0; padding: 0; list-style: none; }
.dv-group li { border-block-start: 1px solid #f0eef9; } .dv-group li:first-child { border-block-start: 0; } .dv-group li.on { background: var(--brand-soft); }
.dv-group li label { display: flex; align-items: center; gap: .7rem; margin: 0; padding: .55rem .9rem; font-weight: 400; color: var(--ink); cursor: pointer; } .dv-group li strong { display: block; font-size: .92rem; font-weight: 650; }
.dv-nums { flex: none; text-align: end; font-variant-numeric: tabular-nums; } .dv-nums b { display: block; font-size: .92rem; }
.dv-group > select { display: block; inline-size: calc(100% - 1.8rem); margin: .3rem .9rem .8rem; min-block-size: 2.4rem; }
.dv-driver { padding: .85rem .95rem; }
.dv-dhead { display: flex; align-items: center; gap: .7rem; } .dv-dhead strong { font-size: 1.02rem; }
.dv-avatar { flex: none; display: grid; place-items: center; inline-size: 2.5rem; block-size: 2.5rem; border-radius: 50%; background: var(--brand-deep); color: #fff; font-weight: 800; }
.dv-state { flex: none; padding: .2rem .6rem; border-radius: 999px; background: #efeef8; color: var(--muted); font-size: .74rem; font-weight: 700; white-space: nowrap; } .dv-state.good, .dv-chip.good { background: var(--ok-bg); color: var(--ok); }
.dv-load { block-size: .55rem; margin-block: .7rem .3rem; border-radius: 999px; background: #e8e6f5; overflow: hidden; } .dv-load i { display: block; block-size: 100%; border-radius: 999px; background: var(--brand); } .dv-load.high i { background: #d9730d; } .dv-load.over i { background: var(--bad); }
.dv-loadtext { display: flex; gap: .35rem; margin: 0; font-size: .84rem; color: var(--muted); } .dv-loadtext b { color: var(--ink); } .dv-loadtext span { margin-inline-start: auto; }
.dv-driver ol { margin-block-start: .6rem; }
.dv-driver li { display: flex; align-items: center; gap: .65rem; padding-block: .55rem; border-block-start: 1px solid #f0eef9; } .dv-driver li strong { display: block; font-size: .92rem; font-weight: 650; } .dv-driver li small.bad { color: var(--bad); } .dv-driver li small.good { color: var(--ok); font-weight: 600; }
.dv-no { flex: none; display: grid; place-items: center; inline-size: 1.7rem; block-size: 1.7rem; border-radius: 50%; border: 2px solid var(--brand); color: var(--brand-strong); font-size: .78rem; font-weight: 800; } .dv-driver li.delivered .dv-no { border-color: var(--ok); background: var(--ok); color: #fff; } .dv-driver li.failed .dv-no { border-color: var(--bad); color: var(--bad); }
.dv-chip { flex: none; padding: .15rem .55rem; border-radius: 999px; font-size: .74rem; font-weight: 700; } .dv-chip.bad { background: var(--bad-bg); color: var(--bad); }
.dv select.dv-move { flex: none; inline-size: 7.8rem; margin: 0; min-block-size: 2.1rem; padding-block: .2rem; font-size: .82rem; }
.dv-driver .link { min-block-size: 0; padding: .1rem .2rem; font-size: .82rem; }
.dv-dfoot { display: flex; flex-wrap: wrap; gap: .5rem; margin-block-start: .7rem; } .dv-dfoot button { display: inline-flex; align-items: center; gap: .35rem; min-block-size: 2.3rem; font-size: .86rem; }
.dv-picked { position: sticky; inset-block-end: calc(var(--bar-h) + 1.4rem + env(safe-area-inset-bottom)); z-index: 20; display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; margin-block-start: .6rem; padding: .7rem 1rem; border-radius: 16px; background: var(--brand-deep); color: #fff; box-shadow: 0 16px 40px rgb(30 27 75 / .35); } .dv-picked small { color: rgb(255 255 255 / .75); } .dv-picked select { margin: 0; inline-size: auto; flex: 1 1 12rem; min-block-size: 2.5rem; } .dv-picked button { min-block-size: 2.5rem; background: transparent; color: #fff; border-color: rgb(255 255 255 / .4); }
.dv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr)); gap: .8rem; margin-block-end: .8rem; } .dv-grid .dv-driver { margin: 0; } .dv-driver.off { opacity: .65; }
.dv-driver dl { display: grid; grid-template-columns: auto 1fr; gap: .15rem .8rem; margin: .7rem 0 0; font-size: .86rem; } .dv-driver dt { color: var(--muted); } .dv-driver dd { margin: 0; text-align: end; font-weight: 600; }
.dv-routerow { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; padding-block: .5rem; border-block-start: 1px solid #f0eef9; } .dv-routerow select { margin: 0; inline-size: auto; min-inline-size: 12rem; }
@media (min-width: 64rem) { .dv-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } .dv-picked { inset-block-end: 1rem; } }
@media (min-width: 72rem) { .dv-cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); } }

/* WhatsApp: the linked phone, the figures, the messages, routes, customers, promotions, texts */
.wa button { box-shadow: none; margin: 0; }
.wa h3 { display: flex; align-items: center; gap: .5rem; margin: 0 0 .6rem; }
.wa h4 { margin: .9rem 0 0; font-size: .76rem; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.wa small { display: block; font-size: .78rem; }
.wa-hero { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem; padding: .85rem 1rem; margin-block-end: .8rem; border: 1px solid #f1c27a; border-radius: 18px; background: #fffaf0; box-shadow: var(--shadow); } .wa-hero.good { border-color: #a7e3bd; background: #f0fdf4; }
.wa .topbar { margin-block-end: .6rem; } .wa-hero > div { flex: 1 1 14rem; } .wa-hero strong { display: block; font-size: 1.05rem; }
.wa-hero-icon { flex: none; display: grid; place-items: center; inline-size: 3rem; block-size: 3rem; border-radius: 50%; background: var(--warn-bg); color: var(--warn); } .wa-hero.good .wa-hero-icon { background: var(--ok); color: #fff; }
.wa-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; margin-block-end: .8rem; }
.wa .wa-stats button { display: block; padding: .75rem 1rem; text-align: start; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); }
.wa-stats span { display: block; font-size: .74rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); } .wa-stats b { font-size: 1.6rem; letter-spacing: -.02em; font-variant-numeric: tabular-nums; } .wa-stats em { font-size: 1rem; font-style: normal; color: var(--muted); }
.wa .wa-stats button.attention { border-color: #f1c27a; background: #fffaf0; } .wa-stats .attention b { color: var(--warn); }
.wa-steps { display: grid; gap: .5rem; margin: 0 0 .8rem; padding: 0; list-style: none; }
.wa-steps li { display: flex; align-items: center; gap: .6rem; padding: .55rem .8rem; border: 1px dashed #c9c6e0; border-radius: 14px; font-size: .9rem; font-weight: 600; } .wa-steps li.done { border-style: solid; border-color: var(--line); background: #fff; color: var(--muted); font-weight: 500; }
.wa-steps button { flex: none; min-block-size: 2.2rem; font-size: .82rem; }
.wa-no { flex: none; display: grid; place-items: center; inline-size: 1.6rem; block-size: 1.6rem; border-radius: 50%; background: var(--brand-soft); color: var(--brand-strong); font-size: .8rem; font-weight: 800; } .wa-steps li.done .wa-no { background: var(--ok); color: #fff; }
.wa-tabs { display: flex; gap: .15rem; overflow-x: auto; margin-block-end: .9rem; border-block-end: 1px solid var(--line); scrollbar-width: none; }
.wa .wa-tabs button { flex: none; min-block-size: 2.7rem; padding: .4rem .8rem; border: 0; border-block-end: 3px solid transparent; border-radius: 0; background: none; color: var(--muted); font-size: .9rem; } .wa .wa-tabs button.on { border-block-end-color: var(--brand); color: var(--brand-deep); }
.wa-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; margin-block-end: .7rem; } .wa-bar .chips { flex: 1 1 auto; margin: 0; } .wa-bar p { margin: 0; flex-basis: 20rem; } .wa-bar input[type=search] { margin: 0; flex: 1 1 14rem; min-block-size: 2.5rem; }
.wa-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; } .wa-actions button { min-block-size: 2.4rem; font-size: .88rem; }
.wa .wa-danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.wa-note { padding: .6rem .9rem; border-radius: 12px; background: var(--ok-bg); color: #0f5c2e; font-weight: 600; }
.wa-empty { display: flex; flex-direction: column; align-items: center; gap: .35rem; padding: 2rem 1.2rem; border: 1px dashed #c9c6e0; border-radius: 18px; text-align: center; color: var(--muted); } .wa-empty strong { color: var(--ink); } .wa-empty small { max-inline-size: 34rem; }
.wa-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: .8rem; align-items: start; }
.wa-msg, .wa-route, .wa-item, .wa-panel { min-inline-size: 0; padding: .9rem 1rem; background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); }
.wa-head { display: flex; align-items: center; gap: .65rem; } .wa-head strong { display: block; overflow-wrap: anywhere; }
.wa-avatar { flex: none; display: grid; place-items: center; inline-size: 2.4rem; block-size: 2.4rem; border-radius: 50%; background: var(--brand-deep); color: #fff; font-weight: 800; }
.wa-tag { flex: none; padding: .2rem .6rem; border-radius: 999px; background: #efeef8; color: var(--muted); font-size: .74rem; font-weight: 700; }
.wa-tag.s-pending, .wa-tag.g-no_mobile { background: var(--warn-bg); color: var(--warn); } .wa-tag.s-approved { background: var(--brand-soft); color: var(--brand-strong); } .wa-tag.s-sent, .wa-tag.g-ready { background: var(--ok-bg); color: var(--ok); } .wa-tag.s-failed, .wa-tag.g-stopped { background: var(--bad-bg); color: var(--bad); }
.wa-bubble { position: relative; margin-block: .7rem .35rem; padding: .65rem .85rem; border-radius: 4px 14px 14px 14px; background: #e7f8e0; color: #14230f; font-size: .9rem; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.wa-bubble.short { max-block-size: 9.8rem; overflow: hidden; } .wa-bubble.short::after { content: ''; position: absolute; inset-inline: 0; inset-block-end: 0; block-size: 3rem; background: linear-gradient(rgb(231 248 224 / 0), #e7f8e0); }
.wa-msg > .link, .wa-actions .link { min-block-size: 0; padding: .2rem; font-size: .82rem; }
.wa-msg textarea { margin-block: .7rem .5rem; font-size: .9rem; }
.wa-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; margin-block-start: .5rem; } .wa-foot small.bad { color: var(--bad); font-weight: 600; } .wa-foot .wa-actions { margin-inline-start: auto; }
.wa-day { flex: none; display: grid; place-items: center; inline-size: 2.9rem; block-size: 2.9rem; border-radius: 14px; background: var(--brand-soft); color: var(--brand-strong); font-size: .82rem; font-weight: 800; text-transform: uppercase; }
.wa-route.paused { opacity: .7; } .wa-facts { display: flex; flex-wrap: wrap; gap: .35rem 1rem; margin-block: .65rem; font-size: .82rem; color: var(--muted); } .wa-facts span { display: inline-flex; align-items: center; gap: .3rem; }
.wa-preview { margin-block-start: .8rem; padding-block-start: .5rem; border-block-start: 1px solid #f0eef9; font-size: .9rem; }
.wa-preview .wa-bubble { max-inline-size: 42rem; }
.wa-people { display: flex; flex-wrap: wrap; gap: .35rem; max-block-size: 9rem; overflow-y: auto; } .wa-people span { padding: .25rem .6rem; border-radius: 10px; background: #f4f3fb; font-size: .82rem; } .wa-people small { display: inline; }
.wa-label { margin: .7rem 0 .35rem; font-size: .82rem; font-weight: 600; color: var(--muted); } .wa-panel > .chips { margin: 0; }
.wa-panel { margin-block-end: .8rem; }
.wa-list { margin: 0; padding: 0; list-style: none; background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); }
.wa-cust { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; padding: .65rem .9rem; border-block-start: 1px solid #f0eef9; } .wa-cust:first-child { border-block-start: 0; }
.wa-who { flex: 1 1 14rem; min-inline-size: 0; } .wa-who strong { display: block; font-size: .94rem; font-weight: 650; }
.wa-cust input[inputmode=tel] { flex: 0 1 11rem; margin: 0; min-block-size: 2.4rem; } .wa-cust input.invalid { border-color: var(--warn); background: #fffaf0; } .wa-cust .wa-tag { min-inline-size: 9.5rem; text-align: center; }
.wa label.wa-switch { display: flex; align-items: center; gap: .5rem; margin: .45rem 0; font-size: .86rem; font-weight: 600; color: var(--ink); cursor: pointer; } .wa .wa-cust label.wa-switch { margin: 0; }
.wa .wa-switch input { appearance: none; flex: none; position: relative; inline-size: 2.5rem; block-size: 1.45rem; min-block-size: 0; margin: 0; padding: 0; border: 0; border-radius: 999px; background: #cfcde0; cursor: pointer; transition: background .15s; }
.wa .wa-switch input::after { content: ''; position: absolute; inset-block-start: .18rem; inset-inline-start: .18rem; inline-size: 1.09rem; block-size: 1.09rem; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgb(30 27 75 / .35); transition: inset-inline-start .15s; }
.wa .wa-switch input:checked { background: var(--ok); } .wa .wa-switch input:checked::after { inset-inline-start: 1.23rem; } .wa .wa-switch input:focus-visible { box-shadow: var(--ring); } .wa .wa-switch input:disabled { opacity: .5; cursor: not-allowed; }
.wa-item.open { border-color: #a7e3bd; } .wa-price { flex: none; font-variant-numeric: tabular-nums; }
.wa-cols { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 .9rem; align-items: start; }
.wa-link { display: flex; flex-wrap: wrap; gap: 1rem 1.2rem; align-items: flex-start; }
.wa-qrbox { flex: 0 0 17rem; max-inline-size: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem; min-block-size: 17rem; margin-inline: auto; padding: 1rem; border: 2px dashed #c9c6e0; border-radius: 18px; text-align: center; color: var(--muted); } .wa-qrbox strong { color: var(--ink); } .wa-qrbox.scan { border-style: solid; background: #fff; } .wa-qrbox.connected { border-style: solid; border-color: #a7e3bd; background: #f0fdf4; } .wa-qrbox img { inline-size: 15rem; block-size: 15rem; max-inline-size: 100%; }
.wa-bigcheck { display: grid; place-items: center; inline-size: 4.5rem; block-size: 4.5rem; border-radius: 50%; background: var(--ok); color: #fff; }
.wa-spin { inline-size: 2.5rem; block-size: 2.5rem; border-radius: 50%; border: 4px solid var(--brand-soft); border-block-start-color: var(--brand); animation: wa-turn 1s linear infinite; } @keyframes wa-turn { to { transform: rotate(360deg); } }
.wa-how { flex: 1 1 14rem; margin: 0; padding-inline-start: 1.3rem; font-size: .92rem; } .wa-how li { margin-block-end: .6rem; } .wa-how li.plain { list-style: none; margin-inline-start: -1.3rem; font-size: .82rem; color: var(--muted); }
.wa-test { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .5rem; margin-block: .8rem .4rem; padding-block-start: .5rem; border-block-start: 1px solid #f0eef9; } .wa-test label { flex: 1 1 12rem; margin: 0; } .wa-test button { min-block-size: var(--tap); }
.wa-caution { display: flex; gap: .55rem; margin-block: .9rem 0; padding: .65rem .8rem; border-radius: 12px; background: var(--warn-bg); color: var(--warn); font-size: .84rem; } .wa-caution svg { flex: none; }
.wa-holders { display: flex; flex-wrap: wrap; gap: .35rem; } .wa-holders button { min-block-size: 2rem; padding: .15rem .6rem; border-radius: 999px; background: var(--brand-soft); border-color: transparent; color: var(--brand-strong); font-size: .8rem; }
.wa-chat { padding: .2rem .8rem .5rem; border-radius: 14px; background: #efeae2; min-block-size: 8rem; } .wa-chat .wa-bubble { background: #fff; }
@media (min-width: 48rem) { .wa-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 40rem) { .wa-hero-icon { display: none; } .wa .wa-stats button { padding: .45rem .75rem; } .wa-stats b { font-size: 1.25rem; } .wa-stats { gap: .45rem; } }
@media (min-width: 64rem) { .wa-bar input[type=search] { flex: 0 1 18rem; } .wa-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } .wa-cols { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); } .wa-sticky { position: sticky; top: 5rem; } }
@media (min-width: 72rem) { .wa-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .wa-route.open { grid-column: 1 / -1; } }

/* Delivery day activity, the cash received form and the end-of-day sheet */
.dv-driver li small.due { color: var(--warn); font-weight: 600; }
.da-undo { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin-block-start: .35rem; } .da-undo small { flex-basis: 100%; color: var(--ink); } .da-undo button { min-block-size: 2.1rem; font-size: .82rem; } .dv .da-danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.da-cash { margin-block-end: .9rem; padding: .9rem 1.1rem; background: #fff; border: 2px solid var(--brand); border-radius: 18px; box-shadow: var(--shadow); }
.da-cash ul { margin: 0; padding: 0; list-style: none; } .da-cash li { padding-block: .6rem; border-block-start: 1px solid #f0eef9; }
.da-cashrow { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; } .da-cashrow > div { flex: 1 1 14rem; } .da-cashrow strong { display: block; }
.da-cashrow label { display: flex; align-items: center; gap: .5rem; margin: 0; } .da-cashrow input { margin: 0; inline-size: 8rem; min-block-size: 2.5rem; text-align: end; font-variant-numeric: tabular-nums; } .da-cashrow input.invalid { border-color: var(--bad); }
.da-choice { display: flex; flex-wrap: wrap; gap: .2rem 1.2rem; margin-block-start: .35rem; } .dv .da-choice label.check { margin: 0; font-size: .86rem; } .da-choice input { display: inline-block; inline-size: 1.1rem; min-block-size: 0; block-size: 1.1rem; margin: 0; accent-color: var(--brand); }
.da-pays, .da-warn { margin: .3rem 0 0; font-size: .84rem; color: var(--ok); font-weight: 600; } .da-warn { color: var(--warn); }
.da-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-block-start: .5rem; } .da-actions button { display: inline-flex; align-items: center; gap: .35rem; }
.da-updated { align-self: center; font-size: .82rem; color: var(--muted); }
.da-cols { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1rem; align-items: start; } .da-cols > section { min-inline-size: 0; }
.da-progress { display: flex; block-size: .55rem; margin-block: .7rem .2rem; border-radius: 999px; background: #e8e6f5; overflow: hidden; } .da-progress i { display: block; block-size: 100%; } .da-progress .done { background: var(--ok); } .da-progress .bad { background: var(--bad); }
.dv-driver dd.da-due { color: var(--warn); }
.da-line { margin: 0; padding: .3rem .9rem; list-style: none; background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); }
.da-line li { display: flex; align-items: flex-start; gap: .7rem; padding-block: .6rem; border-block-start: 1px solid #f0eef9; } .da-line li:first-child { border-block-start: 0; }
.da-line time { flex: none; inline-size: 3.1rem; font-weight: 700; font-size: .86rem; font-variant-numeric: tabular-nums; } .da-line time small { font-weight: 400; font-size: .68rem; }
.da-line strong { display: block; font-size: .92rem; font-weight: 650; overflow-wrap: anywhere; } .da-line small { overflow-wrap: anywhere; }
.da-dot { flex: none; display: grid; place-items: center; inline-size: 1.6rem; block-size: 1.6rem; border-radius: 50%; background: #efeef8; color: var(--muted); } .da-line li.good .da-dot { background: var(--ok); color: #fff; } .da-line li.bad .da-dot { background: var(--bad-bg); color: var(--bad); } .da-line li.money .da-dot { background: var(--brand-soft); color: var(--brand-strong); }
.eod-driver { margin-block-start: 1rem; } .eod-driver h2 { margin-block-end: .2rem; } .eod-driver h2 small { font-weight: 400; }
.drv.eod table { inline-size: 100%; table-layout: auto; } .drv.eod th, .drv.eod td { inline-size: auto; width: auto; padding: .25rem .35rem; vertical-align: top; text-align: start; } .drv.eod .num { text-align: end; white-space: nowrap; } .drv.eod td:nth-child(3), .drv.eod th:nth-child(3) { inline-size: 100%; } .drv.eod td small { display: block; } .drv.eod .eod-total td { font-weight: 700; border-block-start: 2px solid var(--ink); }
.eod-driver .drv-foot { margin-block-start: .5rem; } .eod-driver .drv-foot .line { padding-block-start: 1.4rem; }
@media (max-width: 40rem) { .drv.eod { overflow-x: auto; } }
@media print { .eod-driver { break-inside: avoid; } .drv.eod { overflow: visible; } }
@media (min-width: 72rem) { .da-cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); } }

/* What happened after a click on the delivery board: always on the screen */
.dv-toast { position: fixed; inset-inline: .9rem; inset-block-end: calc(var(--bar-h) + 1.4rem + env(safe-area-inset-bottom)); z-index: 30; display: flex; align-items: center; gap: .7rem; max-inline-size: 38rem; margin-inline: auto; padding: .8rem 1rem; border-radius: 14px; background: #0f5c2e; color: #fff; font-weight: 600; box-shadow: 0 16px 40px rgb(30 27 75 / .35); }
.dv-toast.is-warn { background: var(--bad); } .dv-toast.raised { inset-block-end: calc(var(--bar-h) + 6.5rem); } .dv-toast svg { flex: none; }
.dv .dv-toast button { flex: none; min-block-size: 2rem; min-inline-size: 2rem; padding: 0; background: transparent; border-color: rgb(255 255 255 / .45); color: #fff; }
.dv-spin { flex: none; inline-size: 1.2rem; block-size: 1.2rem; border-radius: 50%; border: 3px solid rgb(255 255 255 / .35); border-block-start-color: #fff; animation: dv-turn .8s linear infinite; } @keyframes dv-turn { to { transform: rotate(360deg); } }
.dv-driver .dv-gone { margin-block-start: .15rem; }
@media (min-width: 64rem) { .dv-toast { inset-block-end: 1rem; } .dv-toast.raised { inset-block-end: 6rem; } }

/* A driver card that opens the driver's history: the name's button covers the whole card, the other buttons lie above it */
.dv-driver.dv-open { position: relative; cursor: pointer; } .dv-driver.dv-open:hover { border-color: var(--brand); }
.dv button.dv-name { display: block; min-block-size: 0; margin: 0; padding: 0; border: 0; border-radius: 0; background: none; color: var(--ink); font-size: 1.02rem; font-weight: 700; text-align: start; }
.dv button.dv-name::after { content: ''; position: absolute; inset: 0; border-radius: 18px; } .dv button.dv-name:focus-visible { box-shadow: none; } .dv button.dv-name:focus-visible::after { box-shadow: var(--ring); } .dv button.dv-name:active { transform: none; }
.dv-open .dv-dfoot { position: relative; z-index: 1; }
/* The history of a driver: the days, each opening its stops */
.dh-head { display: flex; flex-wrap: wrap; align-items: center; gap: .7rem 1rem; margin-block: .7rem .9rem; } .dh-head > button { display: inline-flex; align-items: center; gap: .3rem; } .dh-head h3 { margin: 0; } .dh-head .grow { min-inline-size: 12rem; }
.dh-dates { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; } .dh-dates label { display: flex; align-items: center; gap: .4rem; margin: 0; } .dh-dates input { margin: 0; inline-size: auto; min-block-size: 2.4rem; }
.dh-tiles.dv-stats b { font-size: 1.45rem; }
.dh-day { margin-block-end: .6rem; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); overflow: hidden; }
.dv button.dh-row { display: flex; flex-wrap: wrap; justify-content: flex-start; align-items: center; gap: .4rem 1rem; inline-size: 100%; padding: .75rem 1rem; border: 0; border-radius: 0; background: none; text-align: start; font-weight: 400; } .dv button.dh-row:active { transform: none; }
.dh-row strong { flex: 1 1 11rem; font-size: .96rem; } .dh-row span { font-size: .86rem; color: var(--muted); white-space: nowrap; } .dh-row span.bad { color: var(--bad); font-weight: 600; } .dh-row span.due { color: var(--warn); font-weight: 600; } .dh-row svg { flex: none; transform: rotate(-90deg); transition: transform .15s; } .dh-row[aria-expanded=true] svg { transform: rotate(90deg); }
.dh-body { padding: 0 1rem .7rem; border-block-start: 1px solid #f0eef9; } .dh-body ol { margin: 0; padding: 0; list-style: none; }
.dh-body li { display: flex; align-items: center; gap: .65rem; padding-block: .55rem; border-block-end: 1px solid #f0eef9; } .dh-body li strong { display: block; font-size: .92rem; font-weight: 650; } .dh-body li small.bad { color: var(--bad); } .dh-body li small.due { color: var(--warn); font-weight: 600; } .dh-body li small.good { color: var(--ok); font-weight: 600; }
.dh-body li.delivered .dv-no { border-color: var(--ok); background: var(--ok); color: #fff; } .dh-body li.failed .dv-no { border-color: var(--bad); color: var(--bad); }
.dh-body > button { margin-block-start: .6rem; }

/* The driver's phone: the next stop on top, then the others, done at the end */
.dm a { text-decoration: none; }
.dm-progress { position: relative; block-size: 1.6rem; margin-block: .4rem .9rem; border-radius: 999px; background: #e8e6f5; overflow: hidden; } .dm-progress i { display: block; block-size: 100%; background: #bfe8cd; } .dm-progress span { position: absolute; inset: 0; display: grid; place-items: center; font-size: .82rem; font-weight: 700; }
.dm-next { margin-block-end: .8rem; padding: .8rem 1rem 1rem; background: #fff; border: 2px solid var(--brand); border-radius: 20px; box-shadow: var(--shadow); } .dm-next h3 { margin: 0 0 .2rem; font-size: 1.25rem; }
.dm-label { margin: 0 0 .2rem; font-size: .74rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--brand-strong); }
.dm-address { margin-block: .2rem .6rem; font-size: 1.05rem; } .dm-address small { display: block; }
.dm-go { display: flex; gap: .6rem; } .dm-go a { flex: 1; display: flex; align-items: center; justify-content: center; gap: .45rem; min-block-size: 3.2rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; color: var(--ink); font-weight: 700; } .dm-go a.dm-navigate { flex: 2; background: var(--brand-deep); border-color: transparent; color: #fff; }
.dm ul.dm-goods { margin: .7rem 0 .3rem; padding: 0; list-style: none; } .dm-goods li { padding-block: .2rem; border-block-end: 1px solid #f0eef9; }
.dm-answer { display: flex; gap: .6rem; margin-block-start: .5rem; } .dm-answer button { min-block-size: 3.2rem; margin: 0; } .dm-answer button.primary { flex: 1; }
.dm-whole { display: flex; align-items: center; justify-content: center; gap: .5rem; min-block-size: 3rem; margin-block-end: 1rem; padding: .4rem .8rem; border: 1px solid var(--brand); border-radius: var(--radius-sm); background: var(--brand-soft); color: var(--brand-deep); font-weight: 700; text-align: center; }
.dm-list { margin: 0 0 1rem; padding: 0; list-style: none; } .dm-list > li { margin-block-end: .5rem; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); overflow: hidden; }
.dm button.dm-row { display: flex; align-items: center; gap: .7rem; inline-size: 100%; margin: 0; padding: .7rem .85rem; border: 0; border-radius: 0; background: none; box-shadow: none; text-align: start; font-weight: 400; } .dm-row strong { display: block; } .dm-row svg { flex: none; transform: rotate(-90deg); } .dm-row[aria-expanded=true] > svg { transform: rotate(90deg); } .dm-row .dm-no svg { transform: none; }
.dm-no { flex: none; display: grid; place-items: center; inline-size: 2rem; block-size: 2rem; border-radius: 50%; border: 2px solid var(--brand); color: var(--brand-strong); font-weight: 800; font-size: .85rem; } li.delivered .dm-no { background: var(--ok); border-color: var(--ok); color: #fff; } li.failed .dm-no { border-color: var(--bad); color: var(--bad); }
.dm-list .dm-stop { padding: 0 .85rem .85rem; border-block-start: 1px solid #f0eef9; } .dm-done { opacity: .8; } .dm-time { flex: none; font-weight: 700; }
.dm-finished { display: flex; align-items: center; gap: .6rem; padding: .9rem 1rem; border-radius: 16px; background: var(--ok-bg); color: #0f5c2e; font-weight: 700; }

/* The first screen: one day at a glance */
.da-who { margin-block-start: .5rem; padding-block-start: .6rem; border-block-start: 1px solid #f0eef9; } .da-who label { margin: 0; max-inline-size: 22rem; } .da-who p { margin: .3rem 0 .2rem; font-size: .82rem; }
.ovt { margin-block-end: 1.1rem; } .ovt small { display: block; font-size: .78rem; }
.ovt button { box-shadow: none; margin: 0; }
.ovt-head { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .8rem; margin-block-end: .6rem; } .ovt-head h3 { margin: 0; font-size: 1.15rem; } .ovt-head > small { flex: 1 1 auto; } .ovt-head .chips { margin: 0; } .ovt-head input { inline-size: auto; margin: 0; min-block-size: 2.4rem; }
.ovt-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.ovt .ovt-tiles button { display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: .1rem; padding: .75rem .9rem; text-align: start; font-weight: 400; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); }
.ovt-tiles span { font-size: .74rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); } .ovt-tiles b { font-size: 1.6rem; letter-spacing: -.02em; font-variant-numeric: tabular-nums; } .ovt-tiles em { font-size: 1rem; font-style: normal; color: var(--muted); }
.ovt .ovt-tiles button.attention { border-color: #f1c27a; background: #fffaf0; } .ovt .ovt-tiles button[aria-expanded=true] { border-color: var(--brand); box-shadow: var(--ring); }
.ovt small.due, .ovt span.due { color: var(--warn); font-weight: 700; }
.ovt-list, .ovt-drivers { margin-block-start: .6rem; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); overflow: hidden; } .ovt-list { max-block-size: 22rem; overflow-y: auto; } .ovt-list p { padding: 0 .9rem; }
.ovt .ovt-list button, .ovt .ovt-drivers button { display: flex; align-items: center; justify-content: flex-start; gap: .4rem .9rem; inline-size: 100%; padding: .55rem .9rem; border: 0; border-block-end: 1px solid #f0eef9; border-radius: 0; background: none; text-align: start; font-weight: 400; }
.ovt-list strong { display: block; font-size: .92rem; } .ovt-list b { flex: none; font-variant-numeric: tabular-nums; }
.ovt .ovt-drivers button { flex-wrap: wrap; } .ovt-drivers svg { flex: none; color: var(--brand-strong); } .ovt-drivers strong { flex: 1 1 8rem; } .ovt-drivers span { font-size: .86rem; color: var(--muted); font-variant-numeric: tabular-nums; }
@media (min-width: 64rem) { .ovt-tiles { grid-template-columns: repeat(5, minmax(0, 1fr)); } }

/* The Overview: two pages, the daily summary of orders, deliveries and cash first */
.ds-tabs { display: flex; gap: .2rem; margin-block-end: .9rem; border-block-end: 1px solid var(--line); }
.ov .ds-tabs button { min-block-size: 2.7rem; margin: 0; padding: .4rem .9rem; border: 0; border-block-end: 3px solid transparent; border-radius: 0; background: none; box-shadow: none; color: var(--muted); } .ov .ds-tabs button.on { border-block-end-color: var(--brand); color: var(--brand-deep); }
.ds button { box-shadow: none; margin: 0; } .ds small { display: block; font-size: .8rem; } .ds h3 { margin: 0 0 .5rem; }
.ds-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .9rem; margin-block-end: .9rem; } .ds-bar .chips { margin: 0; } .ds-bar > input { inline-size: auto; margin: 0; min-block-size: 2.5rem; } .ds-bar > small { margin-inline-start: auto; }
.ds-nav { display: flex; align-items: center; gap: .45rem; } .ds-nav strong { min-inline-size: 11rem; text-align: center; } .ds-nav button { min-block-size: 2.5rem; min-inline-size: 2.5rem; padding-inline: .6rem; } .ds-nav .next svg { transform: scaleX(-1); }
.ds-main { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; } .ds-more { display: grid; grid-template-columns: minmax(0, 1fr); gap: .7rem; margin-block: .2rem .9rem; }
.ds .ds-main button, .ds .ds-more button { display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: .15rem; padding: .9rem 1.05rem; text-align: start; font-weight: 400; background: #fff; border: 1px solid var(--line); border-block-start: 4px solid var(--brand); border-radius: 16px; box-shadow: var(--shadow); }
.ds-main span, .ds-more span { font-size: .74rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); } .ds-move span { font-size: inherit; font-weight: 400; letter-spacing: 0; text-transform: none; }
.ds-main b { font-size: 1.45rem; letter-spacing: -.02em; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; } .ds-more b { font-size: 1.3rem; font-variant-numeric: tabular-nums; } .ds b em { margin-inline-end: .3rem; font-size: .8rem; font-style: normal; font-weight: 600; color: var(--muted); }
.ds .ds-main button.good, .ds .ds-more button.good { border-block-start-color: var(--ok); } .ds .ds-main button.attention, .ds .ds-more button.attention { border-block-start-color: #d9730d; background: #fffaf0; } .ds .ds-main button[aria-expanded=true], .ds .ds-more button[aria-expanded=true] { border-color: var(--brand); box-shadow: var(--ring); }
.ds small.ds-move { margin-block-start: .15rem; font-weight: 700; } .ds .ds-move.none { font-weight: 400; } .ds-move.good { color: var(--ok); } .ds-move.bad { color: var(--bad); }
.ds-progress { display: flex; gap: 2px; block-size: .8rem; margin-block: .9rem .35rem; border-radius: 999px; background: #e8e6f5; overflow: hidden; } .ds-progress i { flex-basis: 0; } .ds-progress .done, .ds-legend .done { background: var(--ok); } .ds-progress .bad, .ds-legend .bad { background: var(--bad); } .ds-progress .open, .ds-legend .open { background: #c9c6e0; }
.ds-legend { display: flex; flex-wrap: wrap; gap: .2rem 1.2rem; margin: 0 0 .8rem; padding: 0; list-style: none; font-size: .8rem; color: var(--muted); } .ds-legend i { display: inline-block; inline-size: .65rem; block-size: .65rem; margin-inline-end: .35rem; border-radius: 3px; }
.ds-list, .ds-table > div { background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); } .ds-list { max-block-size: 24rem; margin-block-end: .9rem; overflow-y: auto; } .ds-list p { padding: 0 1rem; }
.ds .ds-list button { display: flex; align-items: center; justify-content: flex-start; gap: .9rem; inline-size: 100%; padding: .55rem 1rem; border: 0; border-block-end: 1px solid #f0eef9; border-radius: 0; background: none; text-align: start; font-weight: 400; } .ds-list strong { display: block; font-size: .92rem; } .ds-list b { flex: none; font-variant-numeric: tabular-nums; }
.ds-empty { padding: 1.3rem; border: 1px dashed #c9c6e0; border-radius: 16px; text-align: center; color: var(--muted); }
.ds-table { margin-block-end: 1rem; } .ds-table > div { overflow-x: auto; } .ds-table table { margin: 0; min-inline-size: 36rem; } .ds-table th, .ds-table td { padding: .55rem .8rem; vertical-align: middle; } .ds-table thead th { font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); } .ds-table td small { display: inline; } .ds-table .num { text-align: end; } .ds-table td.due { color: var(--warn); font-weight: 700; } .ds .ds-table button.link { min-block-size: 0; padding: 0; font-weight: 700; text-align: start; }
@media (min-width: 48rem) { .ds-more { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 70rem) { .ds-main { grid-template-columns: repeat(4, minmax(0, 1fr)); } .ds-main b { font-size: 1.75rem; } }
@media (max-width: 40rem) {
  .ds-table > div { border: 0; background: none; box-shadow: none; overflow: visible; } .ds-table table, .ds-table tbody { display: block; min-inline-size: 0; } .ds-table thead { display: none; }
  .ds-table tbody tr { display: block; margin-block-end: .6rem; padding: .5rem .9rem; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); }
  .ds-table tbody th { display: block; padding: .25rem 0; border: 0; } .ds-table tbody td { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding: .18rem 0; border: 0; } .ds-table tbody td::before { content: attr(data-label); margin-inline-end: auto; font-size: .8rem; font-weight: 400; color: var(--muted); }
}
