:root {
  /* Tokenurile vin din docs/brand.md (sursa de adevăr). Numele vechi (--ritm, --gold) rămân ca alias-uri. */
  --cobalt: #2F5BFF;
  --cobalt-deep: #1D3FD1;
  --cobalt-soft: #E6ECFF;
  --ink: #0D1830;
  --puls: #C8F04B;
  --puls-ink: #1B2A05;
  --puls-soft: #F3FBD9;
  --paper: #F5F7FB;
  --surface: #FFFFFF;
  --surface-2: #EDF1F9;
  --line: #DDE3EE;
  --band: #0D1830;
  --band-fg: #F5F7FB;
  --muted: #5B6680;
  --ok: #14A37F;
  --ok-soft: #DCF3EA;
  --warn: #E39A1B;
  --warn-soft: #FDF0D8;
  --bad: #E5484D;
  --bad-soft: #FCE4E5;
  /* text în culoare de semnal: aceeași nuanță, mai închisă, ca să se citească pe alb și pe fundalul „soft” (≥ 4,5:1) */
  --ok-ink: #0F7A5F;
  --warn-ink: #936412;
  --bad-ink: #CE1D23;
  --shadow: 0 1px 2px rgba(13, 24, 48, .06), 0 4px 12px rgba(13, 24, 48, .05);
  --r-s: 8px;
  --r-m: 14px;
  --r-l: 28px;
  --display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --body: "Geist", "Segoe UI", system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, Consolas, monospace;
  --nav-h: 64px;
  /* alias-uri folosite în codul existent */
  --ritm: var(--cobalt); --ritm-deep: var(--cobalt-deep); --ritm-soft: var(--cobalt-soft); --ritm-ink: #FFFFFF;
  --gold: var(--puls); --gold-ink: var(--puls-ink); --gold-soft: var(--puls-soft);
  --r-sm: var(--r-s); --r: var(--r-m); --r-lg: var(--r-l);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --cobalt: #6F8DFF; --cobalt-deep: #4F70FF; --cobalt-soft: #18264A; --ink: #EEF2FA; --paper: #0A1222; --surface: #111C33; --surface-2: #17223D;
    --line: #22304D; --band: #050B18; --band-fg: #EEF2FA; --muted: #9AA6C2; --ritm-ink: #0D1830; --puls-soft: #26301A;
    --ok-soft: #0E3229; --warn-soft: #3A2A10; --bad-soft: #3D1A1D; --ok-ink: #2CC79B; --warn-ink: #F0B24A; --bad-ink: #FF6B70; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 4px 12px rgba(0,0,0,.25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
    --cobalt: #6F8DFF; --cobalt-deep: #4F70FF; --cobalt-soft: #18264A; --ink: #EEF2FA; --paper: #0A1222; --surface: #111C33; --surface-2: #17223D;
    --line: #22304D; --band: #050B18; --band-fg: #EEF2FA; --muted: #9AA6C2; --ritm-ink: #0D1830; --puls-soft: #26301A;
    --ok-soft: #0E3229; --warn-soft: #3A2A10; --bad-soft: #3D1A1D; --ok-ink: #2CC79B; --warn-ink: #F0B24A; --bad-ink: #FF6B70; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 4px 12px rgba(0,0,0,.25);
    color-scheme: dark;
}
:root[data-theme="light"] { color-scheme: light; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { height: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 15px/1.45 var(--body); font-feature-settings: "tnum" 1;
  padding-top: env(safe-area-inset-top, 0px);
}
h1, h2, h3 { font-family: var(--display); line-height: 1.15; margin: 0; letter-spacing: -.01em; }
h1 { font-size: 26px; font-weight: 700; }
h2 { font-size: 19px; font-weight: 650; }
h3 { font-size: 16px; font-weight: 650; }
a { color: var(--ritm); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--ritm) 55%, transparent); outline-offset: 2px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.hidden { display: none !important; }

/* ---------- layout ---------- */
.shell { display: grid; grid-template-columns: 236px 1fr; min-height: 100vh; }
.side {
  position: sticky; top: 0; height: 100vh; overflow: auto; padding: 18px 12px 24px;
  background: var(--surface); border-right: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 18px; }
.brand-mark { width: 34px; height: 34px; }
.brand-name { font-family: var(--display); font-weight: 800; font-size: 22px; letter-spacing: .04em; }
.brand-sub { font-size: 12px; color: var(--muted); margin-top: -2px; }
.nav-group { margin: 14px 10px 6px; font-size: 12px; color: var(--muted); }
.nav a {
  display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 10px;
  color: var(--ink); text-decoration: none; font-weight: 500;
}
.nav a svg { width: 19px; height: 19px; flex: none; color: var(--muted); }
.nav a:hover { background: var(--surface-2); }
.nav a.active { background: var(--ritm-soft); color: var(--ritm-deep); font-weight: 650; }
.nav a.active svg { color: var(--ritm); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .nav a.active { color: var(--ink); } }
:root[data-theme="dark"] .nav a.active { color: var(--ink); }
.nav .badge { margin-left: auto; }
.side-foot { margin: 20px 10px 0; padding-top: 14px; border-top: 1px solid var(--line); font-size: 13px; }

.main { min-width: 0; padding: 22px 28px 60px; max-width: 1280px; width: 100%; }
.topbar { display: none; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.page-head p { margin: 4px 0 0; color: var(--muted); }
.bottom-nav { display: none; }

@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { display: none; }
  .side.open {
    display: block; position: fixed; inset: 0; z-index: 60; height: 100%;
    padding-top: calc(18px + env(safe-area-inset-top, 0px)); padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  }
  .topbar {
    display: flex; align-items: center; gap: 10px; position: sticky; top: env(safe-area-inset-top, 0px); z-index: 30;
    padding: 10px 14px; background: var(--surface); border-bottom: 1px solid var(--line);
  }
  body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 31; background: var(--surface); }
  .topbar .title { font-family: var(--display); font-weight: 700; font-size: 18px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .main { padding: 14px 14px calc(var(--nav-h) + 90px + env(safe-area-inset-bottom, 0px)); }
  .page-head h1 { display: none; }
  .page-head { margin-bottom: 12px; }
  .bottom-nav {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    background: var(--surface); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .bottom-nav a {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; height: var(--nav-h);
    font-size: 11.5px; color: var(--muted); text-decoration: none; font-weight: 600;
  }
  .bottom-nav a svg { width: 23px; height: 23px; }
  .bottom-nav a.active { color: var(--ritm); }
  .bottom-nav a.scan-tab span.dot {
    display: grid; place-items: center; width: 46px; height: 46px; margin-top: -18px; border-radius: 50%;
    background: var(--ritm); color: var(--ritm-ink); box-shadow: 0 4px 14px color-mix(in srgb, var(--ritm) 45%, transparent);
  }
  .bottom-nav a.scan-tab.active span.dot { background: var(--ritm-deep); }
}

/* ---------- elemente ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; }
.card + .card, .stack > * + * { margin-top: 14px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.grid { display: grid; gap: 14px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1100px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .g2, .g3 { grid-template-columns: 1fr; } }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.row.tight { gap: 6px; }
.spacer { flex: 1; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 16px;
  border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; touch-action: manipulation;
}
.btn svg { width: 18px; height: 18px; }
.btn:hover { background: var(--surface-2); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.primary { background: var(--ritm); color: var(--ritm-ink); border-color: var(--ritm); }
.btn.primary:hover { background: var(--ritm-deep); }
.btn.gold { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); }
.btn.danger { color: var(--bad-ink); border-color: color-mix(in srgb, var(--bad) 40%, var(--line)); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.sm { min-height: 34px; padding: 0 11px; border-radius: 10px; font-size: 14px; }
.btn.lg { min-height: 54px; font-size: 17px; border-radius: 16px; padding: 0 22px; }
.btn.block { width: 100%; }
.icon-btn { min-width: 42px; padding: 0; }
.icon-btn.sm { min-width: 34px; }

label.field { display: block; }
label.field > span, .field.init-qty > span { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 5px; }
.input, select.input, textarea.input {
  width: 100%; min-height: 44px; padding: 10px 12px; border-radius: 11px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
}
textarea.input { min-height: 80px; resize: vertical; }
.input:focus { border-color: var(--ritm); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--ritm) 22%, transparent); }
.input.sm { min-height: 36px; padding: 6px 10px; }
.check { display: flex; align-items: center; gap: 9px; min-height: 36px; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--ritm); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }

.seg { display: inline-flex; background: var(--surface-2); border-radius: 12px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; padding: 7px 12px; border-radius: 9px; font-weight: 600; color: var(--muted); cursor: pointer; min-height: 34px; }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.08); }

.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 99px; font-size: 12px; font-weight: 700; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.badge.ritm { background: var(--ritm-soft); color: var(--ritm); }
.badge.ok { background: var(--ok-soft); color: var(--ok-ink); }
.badge.warn { background: var(--warn-soft); color: var(--warn-ink); }
.badge.bad { background: var(--bad-soft); color: var(--bad-ink); }
.badge.gold { background: var(--gold-soft); color: var(--warn-ink); }
.dot-c { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }

/* tabele */
.table-wrap { overflow-x: auto; margin: 0 -16px; padding: 0 16px; }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
table.t th { text-align: left; font-size: 12.5px; color: var(--muted); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.t td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.t tr:last-child td { border-bottom: 0; }
table.t td.r, table.t th.r { text-align: right; }
table.t tr.click { cursor: pointer; }
table.t tr.click:hover td { background: var(--surface-2); }
table.t tr.cancelled td { opacity: .5; text-decoration: line-through; }
.empty { padding: 28px 12px; text-align: center; color: var(--muted); }

/* KPI */
.kpi { padding: 14px 16px; }
.kpi .k-label { font-size: 13px; color: var(--muted); font-weight: 600; }
.kpi .k-val { font-family: var(--mono); font-size: 26px; font-weight: 700; margin-top: 2px; letter-spacing: -.01em; }
.kpi .k-sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.delta-up { color: var(--ok-ink); font-weight: 700; }
.delta-down { color: var(--bad-ink); font-weight: 700; }

.hero-total {
  background: var(--ritm); color: var(--ritm-ink); border-radius: var(--r-lg); padding: 20px 22px;
  position: relative; overflow: hidden;
}
.hero-total .k-label { opacity: .85; font-weight: 600; }
.hero-total .k-val { font-family: var(--mono); font-size: 44px; font-weight: 800; line-height: 1.05; letter-spacing: -.02em; }
.hero-total .k-sub { opacity: .85; margin-top: 6px; }
.hero-total::after {
  /* simbolul ritm (docs/brand.md): trei bare crescătoare și punctul Puls = „live” */
  content: ""; position: absolute; right: 18px; top: 50%; width: 92px; height: 92px; transform: translateY(-50%);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 52 52'%3E%3Cg fill='%23fff' fill-opacity='.24'%3E%3Crect x='13' y='26' width='6' height='14' rx='3'/%3E%3Crect x='23' y='18' width='6' height='22' rx='3'/%3E%3Crect x='33' y='11' width='6' height='29' rx='3'/%3E%3C/g%3E%3Ccircle cx='36' cy='10' r='4.6' fill='%23C8F04B'/%3E%3C/svg%3E") center / contain no-repeat;
}
.hero-total > * { position: relative; z-index: 1; }

.progress { height: 10px; background: var(--surface-2); border-radius: 99px; overflow: hidden; }
.progress > div { height: 100%; background: var(--ritm); border-radius: 99px; }
.progress.done > div { background: var(--ok); }

/* lista mobilă */
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }
.list li.click { cursor: pointer; }
.list .main-txt { flex: 1; min-width: 0; }
.list .main-txt b { display: block; font-weight: 650; overflow: hidden; text-overflow: ellipsis; }
.list .main-txt span { font-size: 13px; color: var(--muted); }

/* ---------- vânzare ---------- */
.pos { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; align-items: start; }
@media (max-width: 1000px) { .pos { grid-template-columns: 1fr; } }
.scan-bar { display: flex; gap: 8px; }
.scan-bar .input { flex: 1; }
.quick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; }
.balloon {
  position: relative; border: 0; cursor: pointer; padding: 12px 8px 10px; min-height: 92px; border-radius: 48% 48% 44% 44% / 52% 52% 40% 40%;
  background: var(--b);
  color: #fff; font-weight: 700; font-size: 13px; line-height: 1.2; text-shadow: 0 1px 2px rgba(0,0,0,.25);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; touch-action: manipulation;
}
.balloon::after { content: ""; position: absolute; bottom: -7px; left: 50%; width: 10px; height: 8px; transform: translateX(-50%); background: var(--b); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.balloon .p { font-family: var(--mono); font-size: 14px; opacity: .95; }
.balloon:active { transform: scale(.96); }
.search-results { margin-top: 8px; }
.cart { position: sticky; top: 16px; }
.cart-line { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cart-line .nm { font-weight: 650; }
.cart-line .meta { font-size: 13px; color: var(--muted); }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 11px; overflow: hidden; }
.qty button { width: 38px; height: 36px; border: 0; background: var(--surface-2); font-size: 18px; font-weight: 700; cursor: pointer; }
.qty input { width: 46px; height: 36px; border: 0; text-align: center; background: var(--surface); font-weight: 700; }
.pay-bar {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--r-lg);
  background: var(--band); color: var(--band-fg);
}
.pay-bar .tot { font-family: var(--mono); font-size: 30px; font-weight: 800; letter-spacing: -.02em; line-height: 1; }
.pay-bar .lbl { font-size: 12.5px; opacity: .75; }
@media (max-width: 1000px) {
  .cart { position: static; }
  .pay-bar { position: fixed; left: 10px; right: 10px; bottom: calc(var(--nav-h) + 8px + env(safe-area-inset-bottom, 0px)); z-index: 35; box-shadow: 0 10px 30px rgba(0,0,0,.25); }
}

/* ---------- scanner ---------- */
.scanner { position: fixed; inset: 0; z-index: 90; background: #05040c; color: #fff; display: flex; flex-direction: column; }
.scan-view { position: relative; flex: 1; min-height: 0; overflow: hidden; }
.scanner.with-panel .scan-view { flex: 0 0 46%; }
.scan-view video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.scan-frame { position: absolute; left: 7%; right: 7%; top: 50%; height: min(42%, 220px); transform: translateY(-50%); border-radius: 18px; box-shadow: 0 0 0 100vmax rgba(5, 4, 12, .45); }
.scan-frame i { position: absolute; width: 28px; height: 28px; border: 4px solid #fff; }
.scan-frame i:nth-child(1) { left: -2px; top: -2px; border-right: 0; border-bottom: 0; border-radius: 16px 0 0 0; }
.scan-frame i:nth-child(2) { right: -2px; top: -2px; border-left: 0; border-bottom: 0; border-radius: 0 16px 0 0; }
.scan-frame i:nth-child(3) { left: -2px; bottom: -2px; border-right: 0; border-top: 0; border-radius: 0 0 0 16px; }
.scan-frame i:nth-child(4) { right: -2px; bottom: -2px; border-left: 0; border-top: 0; border-radius: 0 0 16px 0; }
.scan-line { position: absolute; left: 6%; right: 6%; top: 50%; height: 2px; background: #ff4d6d; box-shadow: 0 0 10px #ff4d6d; opacity: .8; animation: scanl 1.8s ease-in-out infinite alternate; }
@keyframes scanl { from { transform: translateY(-60px); } to { transform: translateY(60px); } }
@media (prefers-reduced-motion: reduce) { .scan-line { animation: none; } }
.scanner.flash-ok .scan-frame i { border-color: #3CCB8E; }
.scanner.flash-ok .scan-frame { animation: okflash .45s ease-out; }
.scanner.flash-bad .scan-frame i { border-color: #FF6B86; }
@keyframes okflash { 0% { box-shadow: 0 0 0 100vmax rgba(30, 158, 106, .55); } 100% { box-shadow: 0 0 0 100vmax rgba(5, 4, 12, .45); } }
.scan-top { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; gap: 10px; padding: calc(10px + env(safe-area-inset-top, 0px)) 12px 10px; background: linear-gradient(rgba(0,0,0,.55), transparent); }
.scan-title { flex: 1; font-weight: 700; font-size: 16px; text-align: center; }
.scan-title span { font-weight: 500; opacity: .8; }
.scan-round { width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255,255,255,.16); color: #fff; display: grid; place-items: center; cursor: pointer; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.scan-round svg { width: 22px; height: 22px; }
.scan-round.on { background: #F2C94C; color: #1f1b3a; }
.scan-zoom { position: absolute; left: 50%; transform: translateX(-50%); bottom: 64px; display: flex; align-items: center; gap: 8px; font-size: 12px; background: rgba(0,0,0,.4); padding: 6px 12px; border-radius: 99px; }
.scan-zoom input { width: 150px; accent-color: #fff; }
.scan-msg { position: absolute; left: 12px; right: 12px; bottom: 12px; min-height: 44px; display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 14px; background: rgba(0,0,0,.55); font-weight: 600; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.scan-msg svg { width: 20px; height: 20px; flex: none; }
.scan-diag { position: absolute; left: 8px; right: 8px; top: calc(64px + env(safe-area-inset-top, 0px)); display: flex; gap: 8px; align-items: flex-start; padding: 8px 10px; border-radius: 10px; background: rgba(13, 24, 48, .78); color: #fff; z-index: 2; }
.scan-diag pre { flex: 1; margin: 0; font: 11px/1.45 "Geist Mono", ui-monospace, monospace; white-space: pre-wrap; word-break: break-word; }
.scan-diag .btn { flex: none; }
.scan-msg span { flex: 1; }
.scan-msg.ok { background: rgba(30, 158, 106, .92); }
.scan-msg.bad { background: rgba(217, 61, 91, .92); }
.scan-bottom { background: var(--paper); color: var(--ink); padding: 12px 14px calc(12px + env(safe-area-inset-bottom, 0px)); overflow: auto; }
.scanner.with-panel .scan-bottom { flex: 1; min-height: 0; border-radius: 20px 20px 0 0; margin-top: -16px; position: relative; }
.scanner:not(.with-panel) .scan-bottom { background: #05040c; color: #fff; }
.scanner:not(.with-panel) .scan-manual summary { color: rgba(255,255,255,.8); }
.scan-manual summary { cursor: pointer; font-size: 14px; color: var(--muted); padding: 6px 0; }
.sp-head { display: flex; align-items: center; gap: 8px; padding-bottom: 6px; border-bottom: 1px solid var(--line); }
.sp-tot { font-size: 20px; }

/* ---------- vânzare (v1.4) ---------- */
.scan-cta { display: flex; align-items: center; gap: 14px; width: 100%; padding: 18px; border: 0; border-radius: var(--r-lg); cursor: pointer; text-align: left;
  background: var(--cobalt); color: var(--ritm-ink); }
.scan-cta > svg { width: 44px; height: 44px; flex: none; padding: 9px; border-radius: 14px; background: rgba(255,255,255,.18); }
.scan-cta b { display: block; font-family: var(--display); font-size: 20px; }
.scan-cta small { display: block; opacity: .85; font-size: 13px; margin-top: 2px; }
.scan-cta.slim { padding: 12px 16px; }
.scan-cta.slim small { display: none; }
.scan-cta.slim > svg { width: 36px; height: 36px; padding: 7px; }
.scan-cta.slim b { font-size: 17px; }
.cline { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cline:last-child { border-bottom: 0; }
.cline.fresh { animation: fresh 1.2s ease-out; border-radius: 10px; }
@keyframes fresh { from { background: var(--ok-soft); } to { background: transparent; } }
@media (prefers-reduced-motion: reduce) { .cline.fresh { animation: none; } }
.cline .nm { font-weight: 650; line-height: 1.3; }
.cline .meta { font-size: 13px; color: var(--muted); margin-top: 2px; }
.cline-tot { font-weight: 800; font-size: 16px; text-align: right; white-space: nowrap; }
.cline-ctrl { grid-column: 1 / -1; display: flex; align-items: center; gap: 6px; }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface); }
.stepper button { width: 42px; height: 40px; border: 0; background: var(--surface-2); color: var(--ink); display: grid; place-items: center; cursor: pointer; touch-action: manipulation; }
.stepper button svg { width: 18px; height: 18px; }
.stepper button:active { background: var(--ritm-soft); }
.stepper input { width: 54px; height: 40px; border: 0; text-align: center; font-weight: 800; font-size: 16px; background: transparent; color: var(--ink); }
.cline-ctrl .btn:first-of-type { margin-left: auto; }
.cline-ctrl .stepper + .btn { margin-left: auto; }
.empty-cart { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 26px 10px; color: var(--muted); text-align: center; }
.empty-cart svg { width: 34px; height: 34px; opacity: .5; margin-bottom: 4px; }
.empty-cart b { color: var(--ink); }

/* ---------- finisaje generale (v1.4) ---------- */
.card { box-shadow: 0 1px 2px rgba(31, 27, 58, .04); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .card { box-shadow: none; } }
:root[data-theme="dark"] .card { box-shadow: none; }
.btn { transition: background-color .12s, transform .06s; }
.btn:active { transform: scale(.98); }
@media (prefers-reduced-motion: reduce) { .btn { transition: none; } .btn:active { transform: none; } }
.page-head p { max-width: 70ch; }
@media (max-width: 900px) {
  .page-head { justify-content: flex-end; }
  .page-head > div:first-child:empty { display: none; }
  .page-head p { display: none; }
  .card { border-radius: 16px; }
  .pos .card-head h3 { font-size: 17px; }
}
.cost-vat-toggle { display: inline-flex; margin-left: 6px; vertical-align: middle; }
.cost-vat-toggle button { padding: 2px 8px; min-height: 24px; font-size: 12px; }
.lbl-opts { display: flex; flex-wrap: wrap; gap: 8px; }
/* ---------- modale ---------- */
.modal-bg { position: fixed; inset: 0; z-index: 80; background: rgba(18, 14, 40, .45); display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal {
  background: var(--surface); border-radius: var(--r-lg); width: min(560px, 100%); max-height: calc(100vh - 32px); overflow: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,.3);
}
.modal.wide { width: min(860px, 100%); }
.modal-head { display: flex; align-items: center; gap: 10px; padding: 16px 18px 6px; position: sticky; top: 0; background: var(--surface); z-index: 2; }
.modal-head h2 { flex: 1; }
.modal-body { padding: 10px 18px 18px; }
.modal-foot { display: flex; gap: 10px; justify-content: flex-end; padding: 12px 18px 18px; flex-wrap: wrap; position: sticky; bottom: 0; background: var(--surface); }
@media (max-width: 640px) {
  .modal-bg { align-items: flex-end; padding: 0; }
  .modal, .modal.wide { width: 100%; border-radius: 22px 22px 0 0; max-height: 92vh; padding-bottom: env(safe-area-inset-bottom, 0px); }
  .modal-foot .btn { flex: 1; }
}

.toasts { position: fixed; z-index: 100; left: 50%; transform: translateX(-50%); top: calc(14px + env(safe-area-inset-top, 0px)); display: grid; gap: 8px; width: min(420px, calc(100% - 24px)); }
.toast { padding: 12px 14px; border-radius: 12px; background: var(--ink); color: var(--paper); font-weight: 600; box-shadow: var(--shadow); animation: tin .18s ease-out; }
.toast.ok { background: var(--ok-ink); color: #fff; }
.toast.bad { background: var(--bad-ink); color: #fff; }
@keyframes tin { from { transform: translateY(-8px); opacity: 0; } }
/* „Anulează” după o modificare: jos, mic, nu blochează atingerile (doar butonul) */
.undo-toast { position: fixed; z-index: 70; left: 50%; transform: translateX(-50%); width: max-content; max-width: min(440px, calc(100% - 24px));
  display: flex; align-items: center; gap: 4px; padding: 4px 4px 4px 12px; border-radius: 12px; background: var(--band); color: var(--band-fg); border: 1px solid rgba(255, 255, 255, .08);
  font-size: 13.5px; font-weight: 500; box-shadow: 0 6px 18px rgba(13, 24, 48, .22); pointer-events: none; animation: uin .16s ease-out; }
.undo-toast .ut-msg { display: flex; align-items: center; gap: 6px; min-width: 0; flex: 1; }
.undo-toast .ut-msg span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.undo-toast .ut-msg svg { width: 15px; height: 15px; flex: none; color: var(--ok); }
.undo-toast button { pointer-events: auto; flex: none; display: inline-flex; align-items: center; gap: 4px; min-height: 34px; padding: 0 10px; border: 0; border-radius: 9px;
  background: transparent; color: #6F8DFF; font: inherit; font-weight: 700; cursor: pointer; }
.undo-toast button svg { width: 15px; height: 15px; }
.undo-toast button:active { background: rgba(255, 255, 255, .12); }
@media (max-width: 900px) { .undo-toast { transform: none; } }
@keyframes uin { from { opacity: 0; translate: 0 6px; } }
@media (prefers-reduced-motion: reduce) { .undo-toast { animation: none; } }
@media (prefers-reduced-motion: reduce) { .toast { animation: none; } }

.offline-pill { background: var(--warn-soft); color: var(--warn-ink); }

/* ---------- calendar ---------- */
.roster-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
table.roster { border-collapse: separate; border-spacing: 0; font-size: 13px; min-width: 100%; }
table.roster th, table.roster td { border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); padding: 0; text-align: center; }
table.roster th { padding: 6px 2px; font-weight: 600; color: var(--muted); min-width: 40px; background: var(--surface); }
table.roster th.today { color: var(--ritm); }
table.roster th.wkend { background: var(--surface-2); }
table.roster .who { position: sticky; left: 0; z-index: 2; background: var(--surface); text-align: left; padding: 8px 10px; min-width: 130px; font-weight: 600; white-space: nowrap; }
table.roster td .cell { height: 44px; display: flex; flex-direction: column; align-items: center; justify-content: center; font-weight: 700; cursor: default; font-size: 12px; line-height: 1.1; }
table.roster td .cell small { font-weight: 500; font-size: 10px; opacity: .85; }
table.roster td.edit .cell { cursor: pointer; }
table.roster td.today { box-shadow: inset 0 0 0 2px var(--ritm); }
.k-tura { background: var(--ritm-soft); color: var(--ritm); }
.k-liber { color: var(--muted); }
.k-concediu { background: var(--gold-soft); color: var(--warn-ink); }
.k-medical { background: var(--bad-soft); color: var(--bad-ink); }
.k-cerere { background: repeating-linear-gradient(45deg, var(--gold-soft), var(--gold-soft) 4px, transparent 4px, transparent 8px); color: var(--warn-ink); }
.legend { display: flex; gap: 12px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 16px; height: 16px; border-radius: 5px; display: inline-block; border: 1px solid var(--line); }

/* heatmap */
.heat { display: grid; grid-template-columns: 34px repeat(24, minmax(16px, 1fr)); gap: 2px; font-size: 11px; color: var(--muted); min-width: 560px; }
.heat div { height: 22px; border-radius: 4px; display: flex; align-items: center; justify-content: center; }

/* etichete — previzualizare */
.label-sheet { display: flex; flex-wrap: wrap; gap: 8px; background: var(--surface-2); padding: 12px; border-radius: var(--r); max-height: 520px; overflow: auto; }
.lbl { background: #fff; color: #000; border: 1px dashed #bbb; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 1.2mm; text-align: center; font-family: Arial, sans-serif; }
.lbl .ln { font-size: 7.5pt; font-weight: 700; line-height: 1.1; max-height: 2.3em; overflow: hidden; width: 100%; }
.lbl .lp { font-size: 11pt; font-weight: 800; line-height: 1.1; }
.lbl .ls { font-size: 6pt; color: #333; }
.lbl svg { max-width: 100%; display: block; flex: none; }
.lbl .ln, .lbl .lp, .lbl .ls { flex: none; }
#print-area { display: none; }
@media print {
  body > *:not(#print-area) { display: none !important; }
  body { background: #fff; padding: 0; }
  body::before { display: none; }
  #print-area { display: block; }
  #print-area .lbl { border: 0; }
}

.chart-box { position: relative; height: 280px; }
.chart-box.sm { height: 220px; }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 14px; overflow-x: auto; }
.tabs button { border: 0; background: transparent; padding: 10px 14px; font-weight: 650; color: var(--muted); border-bottom: 2px solid transparent; cursor: pointer; white-space: nowrap; }
.tabs button.on { color: var(--ritm); border-bottom-color: var(--ritm); }

.clock-btn { min-height: 64px; font-size: 18px; border-radius: 18px; }
.clock-live { font-family: var(--mono); font-size: 34px; font-weight: 800; letter-spacing: -.01em; }
.stockpair { display: inline-flex; gap: 6px; }
.pill-loc { font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 8px; background: var(--surface-2); white-space: nowrap; }
.pill-loc.zero { background: var(--bad-soft); color: var(--bad-ink); }
.pill-loc.low { background: var(--warn-soft); color: var(--warn-ink); }
.code-chip { font-size: 12px; padding: 2px 7px; border-radius: 6px; background: var(--surface-2); font-variant-numeric: tabular-nums; }
.json { font-size: 12px; color: var(--muted); word-break: break-word; }
.loading { padding: 40px; text-align: center; color: var(--muted); }

/* corecturi v1.0.1 */
.grid > .card, .grid > .stack { margin-top: 0; }
[data-close-side] { display: none; }
@media (max-width: 900px) { .side.open [data-close-side] { display: inline-flex; } }

/* ---------- manual și ajutor (v1.3) ---------- */
.help-btn { min-width: 34px; padding: 0; border-radius: 50%; font-family: var(--display); font-weight: 800; font-size: 16px; color: var(--ritm); border-color: color-mix(in srgb, var(--ritm) 35%, var(--line)); }
.ui-chip { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); font-weight: 650; font-size: .92em; white-space: nowrap; vertical-align: baseline; line-height: 1.5; }
.ui-chip svg { width: 14px; height: 14px; }
.ui-chip.primary { background: var(--ritm); color: var(--ritm-ink); border-color: var(--ritm); }
.ui-chip.gold { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); }
.ui-chip.ok { background: var(--ok-soft); color: var(--ok-ink); border-color: transparent; }
.ui-chip.warn { background: var(--warn-soft); color: var(--warn-ink); border-color: transparent; }
.ui-chip.bad { background: var(--bad-soft); color: var(--bad-ink); border-color: transparent; }
.ui-ic { display: inline-grid; place-items: center; width: 20px; height: 20px; color: var(--ritm); vertical-align: middle; }
.ui-ic svg { width: 100%; height: 100%; }
.help-gt { font-size: 15px; color: var(--muted); font-family: var(--body); font-weight: 650; margin: 18px 2px 8px; }
.help-sec { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 8px; }
.help-sec > summary { list-style: none; display: flex; align-items: center; gap: 12px; padding: 14px 16px; cursor: pointer; }
.help-sec > summary::-webkit-details-marker { display: none; }
.help-sec > summary::after { content: ""; width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); margin-left: auto; flex: none; transition: transform .15s; }
.help-sec[open] > summary::after { transform: rotate(225deg); }
@media (prefers-reduced-motion: reduce) { .help-sec > summary::after { transition: none; } }
.help-ic { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--ritm-soft); color: var(--ritm); flex: none; }
.help-ic svg { width: 21px; height: 21px; }
.help-t { display: flex; flex-direction: column; min-width: 0; }
.help-t span { font-size: 13.5px; color: var(--muted); }
.help-body { padding: 0 16px 16px 68px; max-width: 760px; }
@media (max-width: 640px) { .help-body { padding-left: 16px; } }
.help-steps { counter-reset: st; list-style: none; padding: 0; margin: 4px 0 12px; }
.help-steps li { counter-increment: st; position: relative; padding: 2px 0 10px 38px; line-height: 1.6; }
.help-steps li::before { content: counter(st); position: absolute; left: 0; top: 1px; width: 26px; height: 26px; border-radius: 50%; background: var(--ritm); color: var(--ritm-ink); font-family: var(--display); font-weight: 800; font-size: 13px; display: grid; place-items: center; }
.help-steps li:not(:last-child)::after { content: ""; position: absolute; left: 12px; top: 30px; bottom: 2px; width: 2px; background: var(--ritm-soft); }
.help-tips, .help-admin { border-radius: 12px; padding: 10px 14px; margin: 8px 0 12px; font-size: 14px; line-height: 1.6; }
.help-tips { background: var(--surface-2); }
.help-admin { background: var(--gold-soft); }
.help-admin b { display: inline-flex; align-items: center; gap: 6px; }
.help-admin b svg { width: 16px; height: 16px; }
.help-tips ul, .help-admin ul { margin: 6px 0 0; padding-left: 18px; }
.help-faq { border-top: 1px solid var(--line); padding: 10px 0; }
.help-faq p { margin: 4px 0 0; color: var(--muted); line-height: 1.55; }
.help-visual { margin: 2px 0 14px; }
.flow { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.flow-step { display: inline-flex; align-items: center; gap: 6px; padding: 7px 11px; border-radius: 10px; background: var(--ritm-soft); color: var(--ritm-deep); font-weight: 650; font-size: 13.5px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .flow-step { color: var(--ink); } }
:root[data-theme="dark"] .flow-step { color: var(--ink); }
.flow-step svg { width: 16px; height: 16px; }
.flow-arrow { color: var(--muted); font-weight: 700; }
.help-modal .help-sec { border: 0; margin: 0; }
.help-modal .help-sec > summary { padding-left: 0; cursor: default; }
.help-modal .help-sec > summary::after { display: none; }
.help-modal .help-body { padding: 0; }
.legend-row { display: flex; align-items: center; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.legend-row:last-child { border-bottom: 0; }
.legend-vis { width: 150px; flex: none; display: flex; align-items: center; }
.help-news ul { margin: 0; padding-left: 18px; line-height: 1.6; }
.help-news li { margin-bottom: 6px; }
.help-news + .help-news { margin-top: 12px; }
.welcome-step { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--line); }
.welcome-step:last-child { border-bottom: 0; }
.welcome-step p { margin: 3px 0 0; color: var(--muted); line-height: 1.55; }

.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-bottom: 14px; }
.tile { display: flex; flex-direction: column; gap: 2px; padding: 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); color: var(--ink); text-decoration: none; min-height: 104px; transition: transform .08s; }
.tile:active { transform: scale(.98); }
@media (prefers-reduced-motion: reduce) { .tile { transition: none; } .tile:active { transform: none; } }
.tile b { font-size: 15px; margin-top: auto; }
.tile small { color: var(--muted); font-size: 12.5px; }
.tile-ic { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: var(--ritm-soft); color: var(--ritm); margin-bottom: 8px; }
.tile-ic svg { width: 21px; height: 21px; }
.tile.primary { background: var(--cobalt); color: var(--ritm-ink); border-color: transparent; }
.tile.primary small { color: inherit; opacity: .85; }
.tile.primary .tile-ic { background: rgba(255,255,255,.2); color: inherit; }
@media (max-width: 640px) { .tiles { grid-template-columns: repeat(2, 1fr); } .tile { min-height: 92px; } }

.scan-mode { height: 34px; padding: 0 12px; border-radius: 99px; border: 1px solid rgba(255,255,255,.35); background: rgba(0,0,0,.35); color: #fff; font-weight: 700; font-size: 13px; cursor: pointer; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }

/* ---------- transfer marfă (v1.5) ---------- */
.dir-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.dir-switch button { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 700; cursor: pointer; padding: 0 10px; }
.dir-switch button svg { width: 20px; height: 20px; flex: none; }
.dir-switch button.on { background: var(--ritm); color: var(--ritm-ink); border-color: var(--ritm); }
.chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 10px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.chips::-webkit-scrollbar { display: none; }
.chips button { flex: none; height: 34px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap; }
.chips button span { color: var(--muted); font-weight: 700; margin-left: 2px; }
.chips button.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.chips button.on span { color: inherit; opacity: .75; }
.chip-sel { flex: none; width: auto !important; height: 34px; min-height: 34px !important; border-radius: 99px !important; padding: 0 12px !important; font-size: 13px; }
.pick-card { padding: 4px 12px; }
.pick { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.pick:last-child { border-bottom: 0; }
.pick.on .nm { color: var(--ritm-deep); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .pick.on .nm { color: var(--ink); } }
:root[data-theme="dark"] .pick.on .nm { color: var(--ink); }
.pick-check input { width: 22px; height: 22px; accent-color: var(--ritm); display: block; }
.pick-main { flex: 1; min-width: 0; }
.pick-main .nm { font-weight: 650; line-height: 1.25; }
.pick-st { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.pick-st .neg { color: var(--bad-ink); font-weight: 700; }
.pick-st .low { color: var(--warn-ink); font-weight: 700; }
.pick-warn { font-size: 12px; color: var(--warn-ink); font-weight: 600; margin-top: 2px; }
.pick-add { min-width: 40px; padding: 0; }
.stepper.sm button { width: 34px; height: 34px; }
.stepper.sm input { width: 44px; height: 34px; font-size: 15px; }
.move-bar { position: sticky; bottom: 10px; z-index: 20; display: flex; align-items: center; gap: 10px; margin-top: 12px; padding: 10px 10px 10px 16px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 8px 24px rgba(31, 27, 58, .12); }
.move-bar.has { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.move-bar.has .btn.ghost { color: var(--paper); }
.mb-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.mb-txt span { font-size: 12.5px; opacity: .75; }
.tight-tabs { margin-bottom: 10px; }
@media (max-width: 900px) {
  .move-bar { position: fixed; left: 10px; right: 10px; bottom: calc(var(--nav-h) + 8px + env(safe-area-inset-bottom, 0px)); margin: 0; }
}

/* ---------- mai compact pe telefon (v1.5) ---------- */
@media (max-width: 640px) {
  body { font-size: 14.5px; }
  .main { padding-left: 10px; padding-right: 10px; }
  .card { padding: 12px; border-radius: 14px; }
  .card + .card, .stack > * + * { margin-top: 10px; }
  .grid { gap: 10px; }
  .card-head { margin-bottom: 8px; }
  .list li { padding: 10px 0; gap: 10px; }
  .kpi { padding: 10px 12px; }
  .kpi .k-val { font-size: 21px; }
  .hero-total { padding: 16px; border-radius: 18px; }
  .hero-total .k-val { font-size: 34px; }
  .tabs button { padding: 9px 11px; }
  .btn { min-height: 40px; }
  .input { min-height: 42px; }
  .modal-body { padding: 8px 14px 14px; }
  .modal-head { padding: 14px 14px 4px; }
  .modal-foot { padding: 10px 14px 14px; }
  .table-wrap { margin: 0 -12px; padding: 0 12px; }
  .page-head { margin-bottom: 8px; }
  .tile { padding: 12px; min-height: 84px; }
  .tile-ic { width: 34px; height: 34px; margin-bottom: 6px; }
}

/* categorie și preț sub denumire (v1.5.1) */
.p-meta { color: var(--muted); font-size: 13px; }
.list .main-txt .p-meta { display: block; }
.p-cat { color: var(--muted); }
.p-price { color: var(--ink); font-weight: 750; }

/* ---------- vânzare compactă (v1.5.3) ---------- */
.pos2 { gap: 12px; }
.pos-left { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.pos-find { display: flex; gap: 8px; }
.pos-search { flex: 1; display: flex; align-items: center; gap: 8px; height: 50px; padding: 0 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); }
.pos-search:focus-within { border-color: var(--ritm); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ritm) 20%, transparent); }
.pos-search svg { width: 18px; height: 18px; color: var(--muted); flex: none; }
.pos-search input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; font-size: 16px; color: var(--ink); height: 100%; }
.pos-scan { height: 50px; min-height: 50px; border-radius: 14px; padding: 0 16px; font-size: 15px; box-shadow: 0 6px 16px color-mix(in srgb, var(--ritm) 28%, transparent); }
.pos-scan svg { width: 20px; height: 20px; }
.res-list { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow); }
.res { display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 12px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--ink); text-align: left; cursor: pointer; font: inherit; }
.res:last-child { border-bottom: 0; }
.res:active { background: var(--ritm-soft); }
.res-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.res-main b { font-weight: 650; line-height: 1.25; }
.res-add { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; background: var(--ritm-soft); color: var(--ritm); flex: none; }
.res-add svg { width: 18px; height: 18px; }
.res-empty { padding: 12px; color: var(--muted); font-size: 14px; }
.quick-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.quick-title { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; flex: none; }
.quick-strip { display: flex; gap: 8px; overflow-x: auto; padding: 2px 0 4px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.quick-strip::-webkit-scrollbar { display: none; }
.qchip { flex: none; display: inline-flex; align-items: center; gap: 7px; height: 40px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 650; font-size: 13.5px; cursor: pointer; touch-action: manipulation; }
.qchip i { width: 12px; height: 14px; border-radius: 50% 50% 45% 45%; background: var(--b); flex: none; }
.qchip b { color: var(--muted); font-weight: 700; }
.qchip:active { transform: scale(.97); }
.cart-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 4px 14px 6px; }
.cart-head { display: flex; align-items: center; gap: 8px; padding: 10px 0 8px; border-bottom: 1px solid var(--line); }
.cart-head b { font-size: 15px; }
.pos2 .cline { padding: 10px 0; gap: 4px 10px; }
.pos2 .cline .nm { font-size: 15px; }
.pos2 .cline-ctrl { margin-top: 2px; }
.pos2 .stepper button { width: 38px; height: 36px; }
.pos2 .stepper input { width: 48px; height: 36px; }
.empty-cart { width: 100%; border: 0; background: transparent; cursor: pointer; font: inherit; }
.empty-cart svg { width: 40px; height: 40px; opacity: 1; color: var(--ritm); padding: 8px; border-radius: 14px; background: var(--ritm-soft); }
.empty-cart span { max-width: 32ch; font-size: 13.5px; }
.pb-lbl { font-size: 12.5px; opacity: .75; }
.pay-bar { margin-top: 10px; }
.topbar [data-tactions]:empty { display: none; }
.topbar .help-btn { min-height: 32px; min-width: 32px; }
.topbar [data-tactions] .btn.sm { min-height: 32px; }
@media (max-width: 1000px) {
  .pos2 .cart { padding-bottom: 76px; }
  .pay-bar { padding: 10px 10px 10px 16px; }
  .pay-bar .tot { font-size: 26px; }
  .pay-bar .btn.lg { min-height: 50px; padding: 0 20px; }
}

/* ---------- adaptare la orice telefon (v1.5.4) ---------- */
/* nimic nu mai poate ieși peste lățimea ecranului: fără mișcare stânga-dreapta */
html, body { max-width: 100%; overflow-x: hidden; overflow-x: clip; overscroll-behavior-x: none; }
body { overflow-wrap: break-word; -webkit-tap-highlight-color: transparent; touch-action: pan-y pinch-zoom; }
.shell, .shell > div, .main, .card, .stack, .pos-left, .cart { min-width: 0; max-width: 100%; }
img, svg, video, canvas { max-width: 100%; }
.dir-switch { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.dir-switch button span { white-space: normal; line-height: 1.15; text-align: left; }
.tiles { grid-template-columns: repeat(auto-fill, minmax(min(150px, 100%), 1fr)); }
.res-main b, .pick-main .nm, .cline .nm, .list .main-txt b { overflow-wrap: anywhere; }
@media (max-width: 900px) {
  :root { --nav-h: 56px; }
  /* inputuri de 16px: telefonul nu mai face zoom când scrii (zoom-ul era ce muta pagina) */
  .input, input, select, textarea, .pos-search input { font-size: 16px; }
  .main { padding-bottom: calc(var(--nav-h) + 96px + env(safe-area-inset-bottom, 0px)); }
  /* bara de jos: mereu lipită jos, mai joasă */
  .bottom-nav { position: fixed; left: 0; right: 0; bottom: 0; transform: translateZ(0); -webkit-transform: translateZ(0); will-change: transform;
    background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); box-shadow: 0 -4px 18px rgba(31, 27, 58, .06); }
  .bottom-nav a { height: var(--nav-h); gap: 1px; font-size: 10.5px; }
  .bottom-nav a svg { width: 21px; height: 21px; }
  .bottom-nav a.scan-tab span.dot { width: 40px; height: 40px; margin-top: -12px; }
  .bottom-nav a.scan-tab span.dot svg { width: 20px; height: 20px; }
  .topbar { padding: 8px 12px; }
  .topbar .title { font-size: 17px; }
  .pay-bar, .move-bar { bottom: calc(var(--nav-h) + 6px + env(safe-area-inset-bottom, 0px)); }
  /* cât timp scrii, barele de jos se ascund ca să nu acopere tastatura */
  body.typing .bottom-nav, body.typing .pay-bar, body.typing .move-bar { display: none; }
  body.typing .main { padding-bottom: 24px; }
}
@media (max-width: 360px) {
  .main { padding-left: 8px; padding-right: 8px; }
  .bottom-nav a { font-size: 9.5px; }
  .pay-bar .tot { font-size: 22px; }
  .pos-scan span { display: none; }
  .pos-scan { padding: 0 14px; }
}
.scanner { height: 100vh; height: 100dvh; }

/* ---------- calendar: ture în culoarea fiecăruia (v1.6) ---------- */
.cal-tools { margin: 0 0 10px; gap: 10px; }
.cal-tools .muted { flex: 1; min-width: 200px; }
table.roster td .cell.k-on { background: var(--uc); color: #fff; border-radius: 6px; margin: 3px; height: 38px; }
table.roster td .cell.k-on small { color: #fff; opacity: .95; font-weight: 700; }
table.roster td .cell.pend { box-shadow: inset 0 0 0 2px rgba(255,255,255,.85); background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.18) 0 6px, transparent 6px 12px); }
table.roster td .cell.k-del { margin: 3px; height: 38px; border-radius: 6px; border: 2px dashed var(--uc); opacity: .7; background: repeating-linear-gradient(45deg, color-mix(in srgb, var(--uc) 18%, transparent) 0 6px, transparent 6px 12px); }
table.roster td.edit .cell { user-select: none; -webkit-user-select: none; }
table.roster td.edit:active .cell { transform: scale(.94); }
table.roster th.who { z-index: 3; }
.cal-bar { margin-top: 12px; }
@media (max-width: 900px) { table.roster td .cell { height: 40px; } table.roster th { min-width: 38px; } .cal-tools .muted { font-size: 12.5px; } }

/* ---------- consumabile și cheltuieli (v1.7) ---------- */
.sup-add { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr) auto auto; gap: 8px; align-items: center; }
@media (max-width: 640px) { .sup-add { grid-template-columns: minmax(0, 1fr) 90px; } .sup-add [data-name] { grid-column: 1 / -1; } .sup-add .btn { grid-column: 1 / -1; } }
.sup-price { width: 92px; flex: none; }
.sup-price .input, .sup-price-in { min-height: 38px; padding: 6px 8px; text-align: right; }
.sup-price-in { width: 92px; }
.exp-row { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.exp-name { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.exp-in-name { flex: 1; min-width: 0; }
.exp-in-qty { width: 70px; flex: none; }
.exp-price { width: 100px; flex: none; }
.exp-price .input { text-align: right; }
.exp-total { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; padding: 12px 14px; border-radius: 12px; background: var(--ritm-soft); font-weight: 700; }
.exp-total b { font-family: var(--mono); font-size: 22px; }
.day-card { padding: 4px 14px 6px; margin-bottom: 10px; }
.day-head { display: flex; align-items: center; gap: 8px; padding: 10px 0 8px; border-bottom: 1px solid var(--line); }
.exp-line { display: flex; align-items: center; gap: 8px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.exp-line:last-child { border-bottom: 0; }
.mbars { display: flex; align-items: flex-end; gap: 6px; height: 110px; margin-top: 10px; }
.mbar { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 4px; font-size: 11px; color: var(--muted); }
.mbar i { width: 100%; max-width: 34px; background: var(--ritm-soft); border-radius: 6px 6px 2px 2px; }
.mbar.on i { background: var(--ritm); }
.mbar.on span { color: var(--ink); font-weight: 700; }

/* ---------- praguri target și bonus (v1.8) ---------- */
.tier-bar { position: relative; height: 12px; background: var(--surface-2); border-radius: 99px; margin: 14px 0 6px; }
.tier-fill { position: absolute; inset: 0 auto 0 0; background: var(--ritm); border-radius: 99px; }
.tier-mark { position: absolute; top: -6px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; }
.tier-mark i { width: 4px; height: 24px; border-radius: 2px; background: var(--muted); opacity: .6; }
.tier-mark.on i { background: var(--ok); opacity: 1; }
.tier-mark em { font-style: normal; font-size: 10px; font-weight: 800; color: var(--muted); margin-top: 1px; }
.tier-mark.on em { color: var(--ok-ink); }
.tier-labels { display: flex; flex-direction: column; gap: 2px; margin-top: 14px; font-size: 12.5px; color: var(--muted); }
.tier-labels .on { color: var(--ok-ink); font-weight: 650; }
.bonus-sum { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.bonus-sum b { color: var(--ink); }
.tier-ed { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.tier-row { display: grid; grid-template-columns: 26px minmax(0, .7fr) minmax(0, 1.1fr) minmax(0, 1.6fr) minmax(0, .8fr) auto; gap: 8px; align-items: end; }
.tier-base { min-height: 44px; display: flex; align-items: center; font-size: 13px; color: var(--muted); }
.tier-n { width: 26px; height: 26px; border-radius: 50%; background: var(--ritm); color: var(--ritm-ink); display: grid; place-items: center; font-weight: 800; font-size: 13px; margin-bottom: 9px; }
@media (max-width: 640px) { .tier-row { grid-template-columns: 26px minmax(0, .8fr) minmax(0, 1.2fr) minmax(0, .8fr) auto; padding-bottom: 8px; border-bottom: 1px solid var(--line); } .tier-row .tier-type { grid-column: 2 / 6; grid-row: 2; } .tier-row .field > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } }
.ladder { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.ladder-step { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; background: var(--surface-2); }
.ladder-step > div { flex: 1; min-width: 0; }
.ladder-step .ls-n { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); border: 2px solid var(--line); font-weight: 800; font-size: 13px; flex: none; }
.ladder-step .ls-n svg { width: 16px; height: 16px; }
.ladder-step.on { background: var(--ok-soft); }
.ladder-step.on .ls-n { background: var(--ok); border-color: var(--ok); color: #fff; }
.ladder-step.next { box-shadow: inset 0 0 0 2px var(--ritm); }

/* ---------- ecranul de pornire a turei (v1.9) ---------- */
.gate { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 24px 16px calc(24px + env(safe-area-inset-bottom, 0px)); background: var(--paper); }
.gate-card { width: min(420px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 28px 22px; text-align: center; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 10px; align-items: center; }
.gate-card img { border-radius: 16px; margin-bottom: 4px; }
.gate-card h1 { font-size: 26px; }
.gate-card p { margin: 0 0 8px; }
.gate-card .btn.lg { min-height: 60px; font-size: 18px; }

/* ---------- tablou bonus: listă / grilă, compact / extins (v1.10) ---------- */
.emp-money { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.emp-money b { color: var(--ink); }
.bonus-sum em { font-style: normal; font-size: 11px; color: var(--muted); font-weight: 600; }
.emp-card.compact { padding: 10px 12px; }
.emp-card.compact .tier-bar { margin: 10px 0 12px; height: 8px; }
.emp-card.compact .tier-mark i { height: 18px; }
.emp-table td, .emp-table th { white-space: nowrap; }
.emp-table tr.emp-total td { border-top: 2px solid var(--line); background: var(--surface-2); }

/* ---------- profit și cheltuieli (v1.11) ---------- */
.pl { display: flex; flex-direction: column; margin-top: 8px; }
.pl-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.pl-row span { display: flex; flex-direction: column; }
.pl-row small { color: var(--muted); font-size: 11.5px; }
.pl-row.muted { color: var(--muted); }
.pl-row.pl-sub { padding-left: 12px; }
.pl-row.pl-strong { font-weight: 700; border-bottom-style: solid; }
.pl-row.pl-total { font-weight: 800; font-size: 16px; border-bottom: 0; border-top: 2px solid var(--ink); margin-top: 4px; padding-top: 10px; }
.pl-row.pos b { color: var(--ok-ink); } .pl-row.neg b { color: var(--bad-ink); }
.pl-sec { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 12px 0 2px; }
.kpi-pos .k-val { color: var(--ok-ink); } .kpi-neg .k-val { color: var(--bad-ink); }
.ord-q { width: 96px; flex: none; }
.ord-q span { font-size: 11px !important; margin-bottom: 2px !important; }
.ord-q .input { min-height: 36px; padding: 6px 8px; text-align: right; }

/* ---------- profit editabil (v1.12) ---------- */
.pl-row[data-k] { cursor: pointer; position: relative; padding-right: 26px; border-radius: 6px; }
.pl-row[data-k]:hover { background: var(--surface-2); }
.pl-row .pl-ed { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--muted); opacity: .45; }
.pl-row[data-k]:hover .pl-ed { opacity: 1; }
.pl-row .pl-ed svg { width: 16px; height: 16px; }
.pl-row.is-manual b { color: var(--warn-ink); }
.mtag { font-style: normal; font-size: 10.5px; font-weight: 700; padding: 1px 6px; border-radius: 6px; background: var(--gold-soft); color: var(--warn-ink); margin-left: 4px; vertical-align: 1px; }
.mtag.x { background: var(--ritm-soft); color: var(--ritm); }
.pl-add { display: inline-flex; align-items: center; gap: 6px; margin: 6px 0 4px 12px; padding: 4px 8px; border: 1px dashed var(--line); border-radius: 8px; background: transparent; color: var(--muted); font: inherit; font-size: 13px; cursor: pointer; }
.pl-add:hover { color: var(--ritm); border-color: var(--ritm); }
.pl-add svg { width: 14px; height: 14px; }
.pl-parts { font-size: 12px; color: var(--muted); padding: 2px 0 6px 12px; }

/* ---------- defecte (v1.14) ---------- */
.dir-switch.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ret-dest { margin-top: 6px; }
.ret-dest button { padding: 5px 10px; min-height: 30px; font-size: 13px; }

/* ---------- v1.15: mărime text, căutare globală, avizier, checklist, vânzare pe calculator ---------- */
html { zoom: var(--fs, 1); }
.side-search { display: flex; align-items: center; gap: 8px; width: calc(100% - 20px); margin: 4px 10px 8px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); color: var(--muted); font: inherit; font-size: 13.5px; cursor: pointer; }
.side-search svg { width: 16px; height: 16px; }
.side-search span { flex: 1; text-align: left; }
.side-search kbd { font: 11px var(--body); padding: 1px 5px; border-radius: 5px; border: 1px solid var(--line); background: var(--surface); }
.topbar [data-gsearch] { margin-left: 2px; }
.gs-res { max-height: 60vh; overflow: auto; }
.gs-group { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin: 10px 4px 4px; }
.gs-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border: 0; border-radius: 10px; background: transparent; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.gs-item svg { width: 18px; height: 18px; color: var(--muted); flex: none; }
.gs-item span { display: flex; flex-direction: column; min-width: 0; }
.gs-item small { color: var(--muted); font-size: 12.5px; }
.gs-item.on, .gs-item:hover { background: var(--ritm-soft); }
.notice-strip { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--nc, var(--ritm)); }
.notice .n-main { flex: 1; min-width: 0; }
.notice .n-main b { display: block; }
.notice .n-main p { margin: 2px 0 0; font-size: 13.5px; color: var(--muted); white-space: pre-line; }
.notice.unread { background: color-mix(in srgb, var(--nc, var(--ritm)) 8%, var(--surface)); }
.notice .n-meta { font-size: 11.5px; color: var(--muted); margin-top: 4px; }
.cl-status { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cl-box { padding: 10px 12px; border-radius: 12px; background: var(--surface-2); }
.cl-box b { display: flex; justify-content: space-between; }
.cl-box .progress { margin: 6px 0 4px; height: 8px; }
.cl-item { display: flex; align-items: center; gap: 12px; padding: 12px 4px; border-bottom: 1px solid var(--line); cursor: pointer; }
.cl-item:last-child { border-bottom: 0; }
.cl-item .cl-box2 { width: 26px; height: 26px; border-radius: 8px; border: 2px solid var(--line); display: grid; place-items: center; flex: none; }
.cl-item.done .cl-box2 { background: var(--ok); border-color: var(--ok); color: #fff; }
.cl-item .cl-box2 svg { width: 16px; height: 16px; }
.cl-item .cl-t { flex: 1; min-width: 0; }
.cl-item.done .cl-t b { text-decoration: line-through; opacity: .6; }
.cl-item small { display: block; color: var(--muted); font-size: 12px; }
.swap-card .list li { align-items: center; }
.home-edit { display: flex; flex-direction: column; gap: 6px; }
.home-edit .he-row { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 10px; background: var(--surface-2); }
.home-edit .he-row span { flex: 1; }
.pos-browse { display: none; }
@media (min-width: 1000px) {
  .pos-browse { display: block; }
  .pb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; max-height: calc(100vh - 290px); overflow: auto; padding: 2px; }
  .pb-card { display: flex; flex-direction: column; gap: 4px; padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; min-height: 84px; }
  .pb-card:hover { border-color: var(--ritm); }
  .pb-card b { font-size: 13.5px; line-height: 1.25; flex: 1; }
  .pb-card .p-price { font-size: 14px; }
  .pb-card small { color: var(--muted); font-size: 11.5px; }
  .pb-card.low small { color: var(--bad-ink); }
  .pos2 .cart { position: sticky; top: 12px; align-self: start; }
  .pos2 .cart-card { max-height: calc(100vh - 170px); overflow: auto; }
}
.cost-hist { display: flex; flex-direction: column; gap: 2px; }
.ch-row { display: flex; align-items: baseline; gap: 10px; padding: 7px 0; border-bottom: 1px dashed var(--line); font-size: 13.5px; }
.ch-row .ch-d { width: 86px; color: var(--muted); flex: none; }
.ch-row .ch-v { flex: 1; }
.abc { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; font-weight: 800; font-size: 12px; }
.abc.A { background: var(--ok-soft); color: var(--ok-ink); } .abc.B { background: var(--gold-soft); color: var(--warn-ink); } .abc.C { background: var(--bad-soft); color: var(--bad-ink); }
.cmp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(220px, 100%), 1fr)); gap: 10px; }
.cmp { padding: 12px 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); }
.cmp .k-label { font-size: 12.5px; color: var(--muted); }
.cmp .cv { display: flex; align-items: baseline; gap: 8px; margin-top: 4px; }
.cmp .cv b { font-family: var(--mono); font-size: 20px; }
.cmp .cv small { color: var(--muted); }

@media (max-width: 640px) { .hide-sm { display: none; } }
.perm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 2px 10px; }

/* ---------- poze la produse (v1.16) ---------- */
.thumb { width: 40px; height: 40px; border-radius: 10px; object-fit: cover; flex: none; background: var(--surface-2); }
.thumb.ph { display: grid; place-items: center; color: var(--muted); opacity: .55; }
.thumb.ph svg { width: 18px; height: 18px; }
.thumb.ph.lg { width: 100%; height: 120px; border-radius: 14px; }
.thumb.ph.lg svg { width: 34px; height: 34px; }
.list li .thumb { margin-right: 2px; }
.res .thumb { width: 44px; height: 44px; }
.pd-photo { position: relative; margin-bottom: 12px; }
.pd-photo img { display: block; width: 100%; max-height: 260px; object-fit: contain; border-radius: 14px; background: var(--surface-2); cursor: zoom-in; }
.pd-ph-act { position: absolute; right: 8px; bottom: 8px; display: flex; gap: 6px; }
.pd-ph-act .btn { background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(6px); }
.pb-img { width: 100%; height: 90px; object-fit: cover; border-radius: 8px; margin-bottom: 2px; background: var(--surface-2); }
.st-thumb { display: flex; align-items: center; gap: 10px; }

/* ---------- cifre care se potrivesc singure în spațiu (v1.17) ---------- */
.kpi, .cmp, .hero-total, .card.kpi { min-width: 0; container-type: inline-size; }
.kpi .k-val, .hero-total .k-val, .cmp .cv b, .exp-total b, .stat-big {
  display: block; white-space: nowrap; overflow: hidden; text-overflow: clip; font-variant-numeric: tabular-nums; min-width: 0; }
.kpi .k-val { font-size: clamp(16px, 13cqi, 26px); line-height: 1.15; letter-spacing: -.02em; }
.hero-total .k-val { font-size: clamp(26px, 11cqi, 44px); }
.cmp .cv { min-width: 0; flex-wrap: wrap; }
.cmp .cv b { font-size: clamp(16px, 10cqi, 22px); }
.unit { font-size: .58em; font-weight: 600; opacity: .7; margin-left: .22em; letter-spacing: 0; }
.kpi .k-label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi .k-sub { font-size: 12.5px; }
/* grilele de indicatori se aranjează după spațiul disponibil */
.grid.g4 { grid-template-columns: repeat(auto-fit, minmax(min(190px, 100%), 1fr)); }
.grid.g3 { grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); }
@media (max-width: 640px) { .grid.g4, .grid.g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid.g4 > :last-child:nth-child(odd), .grid.g3 > :last-child:nth-child(odd) { grid-column: 1 / -1; } }
/* carduri de valoare pe locații: o cifră mare + rânduri compacte */
.loc-card { container-type: inline-size; }
.loc-card .stat-big { font-family: var(--mono); font-weight: 750; font-size: clamp(20px, 11cqi, 30px); letter-spacing: -.02em; margin: 4px 0 2px; }
.loc-card .stat-cap { color: var(--muted); font-size: 12.5px; }
.stat-rows { margin-top: 10px; border-top: 1px solid var(--line); }
.stat-row { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px dashed var(--line); font-size: 13.5px; }
.stat-row:last-child { border-bottom: 0; }
.stat-row span { color: var(--muted); }
.stat-row b { font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ---------- previzualizare ca angajat (v1.18) ---------- */
.viewas-bar { position: sticky; top: 0; z-index: 60; display: flex; align-items: center; gap: 10px; padding: 8px 14px; padding-top: calc(8px + env(safe-area-inset-top, 0px)); background: var(--band); color: var(--band-fg); font-size: 13.5px; font-weight: 600; }
.viewas-bar svg { width: 18px; height: 18px; flex: none; }
.viewas-bar span { flex: 1; min-width: 0; }
.viewas-bar .btn { background: var(--puls); color: var(--puls-ink); border-color: var(--puls); white-space: nowrap; }
body.viewing-as .topbar { top: calc(42px + env(safe-area-inset-top, 0px)); }

/* ---------- v1.19: target zilnic, prognoză, sugestii, ore de vârf, notificări, instruire, prețuri ---------- */
.target-card { display: flex; flex-direction: column; gap: 12px; }
.tc-day .progress { height: 12px; margin: 6px 0 4px; }
.tc-month .progress.thin { height: 6px; margin: 6px 0 4px; }
.tc-num { font-family: var(--mono); font-weight: 750; font-size: 18px; font-variant-numeric: tabular-nums; }
.tc-num small { font-size: 13px; font-weight: 600; color: var(--muted); }
.tc-month .tc-num { font-size: 15px; }
.fc-big { font-family: var(--mono); font-weight: 800; font-size: clamp(24px, 6vw, 32px); margin: 2px 0; }
.pairs { margin: 8px 0 4px; padding-top: 8px; border-top: 1px dashed var(--line); }
.pairs-t { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin-bottom: 6px; }
.pairs-t svg { width: 14px; height: 14px; }
.pairs-row { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.pairs-row::-webkit-scrollbar { display: none; }
.pair { flex: none; display: flex; align-items: center; gap: 8px; max-width: 230px; padding: 6px 8px 6px 6px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.pair .thumb { width: 34px; height: 34px; }
.pair span { display: flex; flex-direction: column; min-width: 0; }
.pair b { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pair small { font-size: 11.5px; color: var(--muted); }
.pair > svg { width: 18px; height: 18px; color: var(--ritm); flex: none; }
.pair:hover { border-color: var(--ritm); }
table.heat { border-collapse: separate; border-spacing: 3px; width: 100%; font-size: 12px; }
table.heat th { font-weight: 600; color: var(--muted); padding: 2px 4px; text-align: center; }
table.heat td { position: relative; min-width: 38px; height: 34px; text-align: center; border-radius: 6px; font-variant-numeric: tabular-nums; font-weight: 600; }
table.heat td.r { background: none; text-align: right; padding-left: 8px; }
.two { position: absolute; top: 1px; right: 2px; font-style: normal; font-size: 9px; font-weight: 800; background: var(--gold); color: var(--gold-ink); border-radius: 4px; padding: 0 3px; line-height: 13px; }
.notif-state { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 14px; background: var(--surface-2); flex-wrap: wrap; }
.notif-state > svg { width: 24px; height: 24px; color: var(--muted); flex: none; }
.notif-state > div { flex: 1; min-width: 180px; display: flex; flex-direction: column; }
.notif-state.on > svg { color: var(--ok-ink); }
.nc-group { margin-top: 14px; }
.nc-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 4px; }
.nc-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.nc-row:last-child { border-bottom: 0; }
input.switch { appearance: none; -webkit-appearance: none; width: 42px; height: 24px; border-radius: 99px; background: var(--line); position: relative; cursor: pointer; flex: none; transition: background .15s; margin: 0; }
input.switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: left .15s; }
input.switch:checked { background: var(--ok); }
input.switch:checked::after { left: 21px; }
.train-cta { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; color: var(--ink); text-decoration: none; background: var(--ritm-soft); border-color: transparent; }
.train-cta > svg { width: 28px; height: 28px; color: var(--ritm); flex: none; }
.train-cta > div { flex: 1; display: flex; flex-direction: column; }
.tr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); gap: 10px; margin: 12px 0; }
.tr-card { display: flex; align-items: center; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.tr-card span:last-child { display: flex; flex-direction: column; }
.tr-card small { color: var(--muted); }
.tr-card.done { border-color: var(--ok); }
.tr-card.done .tile-ic { background: var(--ok); color: #fff; }
.tr-steps { margin: 10px 0 0; padding-left: 22px; line-height: 1.6; }
.tr-steps li { margin-bottom: 6px; }
.tr-opts { display: flex; flex-direction: column; gap: 8px; }
.tr-opt { padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.tr-opt:hover:not(:disabled) { border-color: var(--ritm); }
.tr-opt.right { border-color: var(--ok); background: var(--ok-soft); }
.tr-opt.wrong { border-color: var(--bad); background: var(--bad-soft); }
.bp-prev { margin-top: 10px; }
tr.bp-bad td { color: var(--bad-ink); }

/* ---------- două prețuri (v1.21) ---------- */
.alt-box { margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--line); }
.alt-row { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.alt-row .input { flex: 1; min-width: 0; }
.alt-row .alt-price { flex: none; width: 110px; text-align: right; }
.alt-row span.alt-price { font-weight: 700; }
.price-choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.pc-opt { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 18px 12px; border: 2px solid var(--line); border-radius: 16px; background: var(--surface); color: var(--ink); font: inherit; cursor: pointer; }
.pc-opt span { font-weight: 650; }
.pc-opt b { font-family: var(--mono); font-size: 24px; }
.pc-opt:hover, .pc-opt:focus { border-color: var(--ritm); background: var(--ritm-soft); }
.modal-bg.modal-top, .modal-top { z-index: 400 !important; }

/* ---------- v1.23: vânzare mai fluentă ---------- */
.pay-bar { gap: 10px; }
.pay-bar .pb-mid { flex: 1; min-width: 0; }
.pay-scan { min-height: 50px; border-radius: 14px; padding: 0 14px; gap: 6px; }
.pay-scan svg { width: 22px; height: 22px; }
@media (max-width: 999px) { .pos-find .pos-scan { display: none; } .pay-scan span { display: none; } .pay-scan { width: 54px; padding: 0; justify-content: center; } }
@media (min-width: 1000px) { .pay-scan { display: none; } }
.pb-head { display: flex; align-items: flex-start; gap: 6px; }
.pb-head .chips { flex: 1; min-width: 0; }
.pos-browse { display: block; padding: 10px; }
.pos-browse.hidden { display: none; }
.show-grid { align-self: flex-start; }
.pb-card { display: flex; flex-direction: column; gap: 3px; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.pb-card b { font-size: 13px; line-height: 1.2; }
.pb-card small { color: var(--muted); font-size: 11px; }
.pb-card.low small { color: var(--bad-ink); }
.pb-card:active { transform: scale(.97); }
@media (max-width: 999px) {
  .pb-grid { display: grid; grid-auto-flow: column; grid-template-rows: repeat(2, auto); grid-auto-columns: 112px; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
  .pb-grid::-webkit-scrollbar { display: none; }
  .pb-img { height: 64px; }
}
/* glisare în bon */
.cline { position: relative; touch-action: pan-y; transition: transform .18s ease; background: var(--surface); }
.cline.sw-l, .cline.sw-r { transition: none; }
.cline.sw-l::after, .cline.sw-r::after { content: attr(data-swl); position: absolute; top: 0; bottom: 0; display: flex; align-items: center; padding: 0 14px; font-weight: 700; font-size: 13px; white-space: nowrap; border-radius: 10px; }
.cline.sw-l::after { left: 100%; background: var(--bad-soft); color: var(--bad-ink); margin-left: 8px; }
.cline.sw-r::after { right: 100%; background: var(--ok-soft); color: var(--ok-ink); margin-right: 8px; }
.cline.sw-go.sw-l::after { background: var(--bad-ink); color: #fff; }
.cline.sw-go.sw-r::after { background: var(--ok-ink); color: #fff; }
.cart-card { overflow: hidden; }
/* calculator de rest */
.cash-btns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 6px 0 8px; }
.cash-btns button { min-height: 48px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); font: inherit; font-weight: 700; font-size: 15px; cursor: pointer; }
.cash-btns button.on { border-color: var(--ritm); background: var(--ritm-soft); color: var(--ritm); }
.rest-box { display: flex; align-items: baseline; justify-content: space-between; padding: 14px 16px; border-radius: 14px; background: var(--ok-soft); }
.rest-box span { font-weight: 700; color: var(--ok-ink); }
.rest-box b { font-family: var(--mono); font-size: 32px; color: var(--ok-ink); font-variant-numeric: tabular-nums; }
.rest-box.short { background: var(--bad-soft); } .rest-box.short span, .rest-box.short b { color: var(--bad-ink); }
/* bandă offline */
.net-bar { position: sticky; top: 0; z-index: 70; display: flex; align-items: center; gap: 10px; padding: 9px 14px; padding-top: calc(9px + env(safe-area-inset-top, 0px)); font-size: 13.5px; }
.net-bar svg { width: 18px; height: 18px; flex: none; }
.net-bar.off { background: var(--bad-ink); color: #fff; }
.net-bar.sync { background: var(--ritm); color: #fff; }
/* buton flotant de scanare */
.fab-scan { position: fixed; right: 16px; bottom: calc(var(--nav-h, 0px) + 18px + env(safe-area-inset-bottom, 0px)); z-index: 55; width: 56px; height: 56px; border-radius: 50%; border: 0; background: var(--ritm); color: #fff; box-shadow: 0 8px 22px color-mix(in srgb, var(--ritm) 45%, transparent); display: grid; place-items: center; cursor: pointer; }
.fab-scan svg { width: 26px; height: 26px; }
@media (min-width: 901px) { .fab-scan { bottom: 22px; right: 22px; } }
body[data-page="vanzare"] .fab-scan, body[data-page="retur"] .fab-scan, body:has(.gate) .fab-scan, body.typing .fab-scan, body:has(.move-bar.has) .fab-scan { display: none; }
.fab-acts { display: flex; flex-direction: column; gap: 8px; }
.fab-act { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.fab-act svg { width: 22px; height: 22px; color: var(--ritm); flex: none; }
.fab-act span { display: flex; flex-direction: column; }
.fab-act small { color: var(--muted); }
.input.lg-num { font-size: 28px; font-weight: 800; text-align: center; min-height: 60px; }
.notice.handover { border-left-color: var(--gold); background: var(--gold-soft); }
/* mod o mână (telefon) */
@media (max-width: 900px) {
  body.one-hand .pos2 { display: flex; flex-direction: column-reverse; }
  body.one-hand .modal-bg { align-items: flex-end; }
  body.one-hand .modal { border-radius: 22px 22px 0 0; max-height: 88vh; }
  body.one-hand .modal-foot .btn { min-height: 52px; flex: 1; }
  body.one-hand .topbar [data-tactions] { display: none; }
}

/* ---------- selecție multiplă în Stoc (v1.24) ---------- */
.sel-head { padding: 4px 4px 8px; border-bottom: 1px solid var(--line); }
.sel-list li { gap: 10px; }
.sel-list li input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--ritm); flex: none; }
.sel-list li.on { background: var(--ritm-soft); border-radius: 10px; }
.sel-bar { position: sticky; bottom: 12px; margin-top: 12px; }
.del-sample { margin: 0 0 6px; padding-left: 20px; line-height: 1.6; }

/* ---------- import: ce există deja (v1.25) ---------- */
.imp-check { margin: 4px 0 10px; }
.imp-stats { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13.5px; color: var(--ink); }
.imp-del { margin-top: 10px; padding: 12px; border-radius: 12px; background: var(--warn-soft); color: var(--ink); font-size: 13.5px; }
.imp-del .check { align-items: flex-start; margin-top: 8px; min-height: 0; }

.purge-force { align-items: flex-start; padding: 10px 12px; border-radius: 12px; background: var(--bad-soft); margin: 8px 0; min-height: 0; }

.imp-dup { margin-top: 10px; padding: 10px 12px; border-radius: 12px; background: var(--gold-soft); color: var(--ink); font-size: 13.5px; }
.imp-dup svg { width: 16px; height: 16px; vertical-align: -3px; color: var(--warn-ink); }

.dup-row { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-top: 1px dashed color-mix(in srgb, var(--warn) 30%, transparent); flex-wrap: wrap; }
.dup-row > div:first-child { flex: 1; min-width: 200px; }
.seg.sm button { padding: 5px 10px; font-size: 12.5px; min-height: 30px; }

/* ---------- etichete optimizate pentru scanare (v1.28) ---------- */
.lbl { justify-content: flex-start !important; gap: 0.3mm; box-sizing: border-box; }
.lbl .ltop { display: flex; align-items: baseline; justify-content: space-between; gap: 1mm; width: 100%; flex: none; line-height: 1.05; }
.lbl .lk { font-weight: 800; letter-spacing: .02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lbl .lp { font-weight: 800; white-space: nowrap; margin-left: auto; }
.lbl .lp small { font-size: .62em; font-weight: 700; }
.lbl .ln { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; font-weight: 700; line-height: 1.12; width: 100%; text-align: left; flex: none; }
.lbl .lstore { font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.lbl .lcode { flex: 1; min-height: 0; width: 100%; display: flex; align-items: center; justify-content: center; }
.lbl .ldig { font: 600 6pt/1 Arial, sans-serif; letter-spacing: .12em; color: #000; flex: none; }
.lbl svg.bc { background: #fff; }
@media print { .lbl, .lbl * { -webkit-print-color-adjust: exact; print-color-adjust: exact; } }

/* ---------- câmpuri numerice fără săgeți și ferestre mai sigure (v1.31) ---------- */
input[type=number] { -moz-appearance: textfield; appearance: textfield; }
input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.field > span svg, label > span > svg { width: 14px; height: 14px; vertical-align: -2px; flex: none; }
.modal-body svg:not([class]):not([width]) { max-width: 100%; }
.modal.nudge { animation: nudge .28s ease; }
@keyframes nudge { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }

/* câmpul de alertă stoc: chenar roșu discret, ca să iasă în evidență fără să încarce pagina (v1.31.1) */
.alert-field > span { color: color-mix(in srgb, var(--bad) 75%, var(--muted)); }
.alert-field .input { border-color: color-mix(in srgb, var(--bad) 45%, var(--line)); background: color-mix(in srgb, var(--bad) 3%, var(--surface)); }
.alert-field .input:focus { border-color: var(--bad); box-shadow: 0 0 0 3px color-mix(in srgb, var(--bad) 14%, transparent); outline: none; }

/* ---------- brand ritm (v1.32): cifrele mari în Geist Mono, mai strânse ---------- */
.hero-total .k-val, .kpi .k-val, .pay-bar .tot, .clock-live, .fc-big, .rest-box b, .loc-card .stat-big { letter-spacing: -.05em; }

/* brand v0.1 (docs/brand.md): Încasează e butonul principal Cobalt; Scanează e secundar pe banda întunecată */
.pay-bar .pay-scan { background: color-mix(in srgb, var(--band-fg) 14%, transparent); color: var(--band-fg); border-color: transparent; }

/* rezultatul comparației din pagina Platformă (v1.33) */
.notice.ok { --nc: var(--ok); background: var(--ok-soft); color: var(--ok-ink); }
.notice.bad { --nc: var(--bad); background: var(--bad-soft); color: var(--bad-ink); }
.notice.warn { --nc: var(--warn); background: var(--warn-soft); color: var(--warn-ink); margin-top: 10px; }
.notice.warn ul { margin: 6px 0; padding-left: 18px; }

/* Consola ritm: stilul ei e la finalul fișierului (C1, v1.68) */
.grid.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }

/* ---------- logare ritm: email + PIN (v1.35) ---------- */
.login-form { display: flex; flex-direction: column; gap: 10px; width: 100%; text-align: left; }
.pin-input { font-family: var(--mono); letter-spacing: .35em; font-size: 20px; text-align: center; }
.login-err { color: var(--bad-ink); font-size: 13.5px; min-height: 1em; margin: 0; }

/* ---------- logo spre Acasă, Consola ritm sus (v1.36) ---------- */
.brand-link { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; min-width: 0; }
.brand-link:hover .brand-name { color: var(--cobalt); }
.console-btn { margin: 0 10px 12px; width: calc(100% - 20px); justify-content: center; }
.topbar-logo { display: none; flex: none; }
.topbar-logo img { display: block; border-radius: 8px; }
@media (max-width: 999px) { .topbar-logo { display: block; } }

/* ---------- telefon întâi: bară de sus, secțiuni pliabile, Acasă compactă (v1.38) ---------- */
:root { interpolate-size: allow-keywords; }
/* iconițele din titlurile cardurilor au mereu mărimea textului (înainte, unele se întindeau pe tot cardul) */
.card-head h3, .fold-t { display: flex; align-items: center; gap: 8px; min-width: 0; }
.card-head h3 svg, .fold-t svg { width: 18px; height: 18px; flex: none; color: var(--ritm); }

/* bara de sus pe telefon: titlul rămâne vizibil; butoanele care nu încap intră în „⋯” */
.topbar .tactions { display: flex; align-items: center; gap: 6px; position: relative; flex: none; }
.topbar .tactions:empty { display: none; }
.topbar .tact-list { display: flex; align-items: center; gap: 6px; flex-wrap: nowrap; }
.topbar .tact-list:empty { display: none; }
.topbar .tactions .btn.sm { min-height: 36px; }
.topbar .tactions .icon-btn.sm, .topbar .help-btn { min-width: 36px; min-height: 36px; }
.topbar .tmore[hidden] { display: none; }
.topbar .tact-over { display: none; }
.topbar .tactions.over.open .tact-over {
  display: flex; position: absolute; top: calc(100% + 8px); right: 0; z-index: 70; min-width: 230px; max-width: calc(100vw - 24px);
  flex-direction: column; align-items: stretch; gap: 2px; padding: 6px; border-radius: var(--r); background: var(--surface);
  border: 1px solid var(--line); box-shadow: 0 12px 32px rgba(13, 24, 48, .16); animation: pop-in .14s ease-out;
}
.topbar .tact-over > .btn { justify-content: flex-start; width: 100%; min-height: 44px; padding: 0 12px; border-color: transparent; background: transparent; color: var(--ink); font-size: 15px; }
.topbar .tact-over > .btn:hover { background: var(--surface-2); }
.topbar .tact-over > .btn.primary { color: var(--ritm); }
.topbar .tact-over .hide-sm { display: inline; }
/* butoanele doar cu iconiță primesc, în meniu, și numele lor */
.topbar .tact-over > .icon-btn::after { content: attr(aria-label); font-weight: 600; }
.topbar .tactions.over.open .tmore { background: var(--surface-2); }
@keyframes pop-in { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }

/* secțiuni pliabile: închise arată titlul și o cifră; săgeata arată că se deschid */
.fold { padding: 0; }
.fold > summary { display: flex; align-items: center; gap: 10px; padding: 14px 16px; min-height: 56px; cursor: pointer; list-style: none; border-radius: var(--r); -webkit-tap-highlight-color: transparent; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary:hover { background: color-mix(in srgb, var(--surface-2) 55%, transparent); }
.fold > summary:active { background: var(--surface-2); }
.fold-t b { font-family: var(--display); font-size: 16px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fold-peek { margin-left: auto; display: flex; align-items: center; gap: 6px; min-width: 0; white-space: nowrap; overflow: hidden; }
.fold-peek .num { font-family: var(--mono); font-weight: 700; }
.fold-chev { display: grid; place-items: center; width: 28px; height: 28px; flex: none; border-radius: 50%; background: var(--surface-2); color: var(--muted); transition: transform .22s ease, background-color .15s; }
.fold-chev svg { width: 16px; height: 16px; }
.fold[open] > summary .fold-chev { transform: rotate(180deg); background: var(--ritm-soft); color: var(--ritm); }
.fold-body { padding: 0 16px 16px; }
.fold::details-content { block-size: 0; overflow: hidden; transition: block-size .22s ease, content-visibility .22s allow-discrete; }
.fold[open]::details-content { block-size: auto; }
.fold[open] .fold-body { animation: fold-in .22s ease-out; }
@keyframes fold-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.fold-nudge .fold:not([open]) .fold-chev { animation: nudge 1s ease-in-out .4s 2; }
@keyframes nudge { 0%, 100% { transform: none; } 40% { transform: translateY(3px); background: var(--ritm-soft); color: var(--ritm); } }
.peek-pill { position: relative; overflow: hidden; padding: 3px 8px; border-radius: 99px; font-size: 12px; font-weight: 700; background: var(--surface-2); color: var(--muted); }
.peek-pill::before { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--p); background: color-mix(in srgb, var(--ritm) 18%, transparent); }
.peek-pill.done { background: var(--ok-soft); color: var(--ok-ink); }
.peek-pill.done::before { display: none; }
.peek-dots { display: flex; }
.peek-dot { display: grid; place-items: center; width: 24px; height: 24px; margin-left: -6px; border-radius: 50%; border: 2px solid var(--surface); background: var(--uc); color: #fff; font-size: 11px; font-weight: 800; opacity: .45; }
.peek-dot:first-child { margin-left: 0; }
.peek-dot.on { opacity: 1; }

/* vânzările de azi: numerar, card și produse în același card */
.hero-mini { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 14px; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, .22); }
.hero-mini span { display: block; font-size: 12px; opacity: .8; font-weight: 600; }
.hero-mini b { font-size: 16px; white-space: nowrap; }
.hero-total::after { top: 18px; transform: none; width: 72px; height: 72px; }
.hero-delta { font-weight: 700; }

/* pontaj: „ești în tură” pe un singur rând, cu punct live */
.clock-card.on { display: flex; align-items: center; gap: 12px; padding: 12px 14px; }
.clock-card .cc-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.live-dot { width: 12px; height: 12px; flex: none; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 50%, transparent); animation: live 2s ease-out infinite; }
@keyframes live { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 45%, transparent); } 70%, 100% { box-shadow: 0 0 0 10px transparent; } }

/* scurtăturile de pe Acasă: pe telefon, 3 pe rând, doar iconiță și nume */
@media (max-width: 640px) {
  .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .tile { min-height: 84px; padding: 10px; border-radius: 14px; align-items: flex-start; }
  .tile small { display: none; }
  .tile b { font-size: 13.5px; line-height: 1.2; }
  .tile-ic { width: 34px; height: 34px; border-radius: 10px; margin-bottom: 6px; }
  .tile-ic svg { width: 19px; height: 19px; }
  .home-grid .stack > * + * { margin-top: 10px; }
  .home-grid { gap: 10px; }
  .hero-total .k-sub { font-size: 13px; }
}

/* telefon: butonul rotund de scanare dispare (Vânzare e în bara de jos, scanarea de produs e în Stoc) */
@media (max-width: 900px) { .fab-scan { display: none !important; } }

@media (prefers-reduced-motion: reduce) {
  .fold::details-content, .fold-chev { transition: none; }
  .fold[open] .fold-body, .fold-nudge .fold:not([open]) .fold-chev, .live-dot, .topbar .tactions.over.open .tact-over { animation: none; }
}
.fold-t { flex: none; max-width: 62%; }
.fold-peek { flex: 1 1 auto; justify-content: flex-end; }

/* calendar pe telefon: azi și mâine unul lângă altul, nume scurte, legendă mică */
.cal-leave { margin-top: 14px; }
@media (max-width: 640px) {
  .cal-now { grid-template-columns: 1fr 1fr; gap: 8px; }
  .cal-now .card { padding: 10px 12px; }
  .cal-now .card-head { margin-bottom: 6px; }
  .cal-now h3 { font-size: 14px; }
  .cal-now .row.tight { flex-wrap: wrap; row-gap: 0; font-size: 13.5px; }
  .cal-now .row.tight .muted.small { flex-basis: 100%; padding-left: 16px; font-size: 12px; margin-top: -2px; }
  .legend { gap: 4px 10px; font-size: 12px; }
  .legend i { width: 12px; height: 12px; border-radius: 4px; }
  table.roster .who { min-width: 0; max-width: 104px; padding: 8px 6px 8px 8px; }
  table.roster .who-nm { display: inline-block; max-width: 76px; overflow: hidden; text-overflow: ellipsis; vertical-align: bottom; }
  table.roster th { min-width: 42px; }
}

/* Stoc pe telefon: filtrele pe un singur rând, glisezi stânga-dreapta */
@media (max-width: 640px) {
  .stoc-filt { flex-wrap: nowrap; overflow-x: auto; gap: 8px; margin: 0; padding: 2px 0 4px; scrollbar-width: none; scroll-snap-type: x proximity; }
  .stoc-filt::-webkit-scrollbar { display: none; }
  .stoc-filt select { flex: none; max-width: 48vw; text-overflow: ellipsis; border-radius: 99px; scroll-snap-align: start; }
  .stoc-filt [data-count] { flex: none; padding-right: 8px; }
}

/* telefoane înguste (ex. 360 px): bara de sus mai strânsă, ca titlul și butonul principal să încapă */
@media (max-width: 380px) {
  .topbar { gap: 6px; padding: 8px 10px; }
  .topbar .title { font-size: 16px; }
  .topbar-logo img { width: 24px; height: 24px; }
  .topbar .tactions, .topbar .tact-list { gap: 4px; }
  .topbar .tact-list > .btn.sm:not(.icon-btn) { padding: 0 9px; gap: 5px; font-size: 13.5px; }
  .topbar .tactions .icon-btn.sm, .topbar .help-btn, .topbar [data-gsearch] { min-width: 34px; min-height: 34px; }
}

/* ---------- simetrie (v1.39) ---------- */
/* în grile, spațiul dintre carduri îl dă grila: fără margini moștenite (cardul „Mâine” stătea mai jos) */
.grid > .card, .grid > .stack, .grid > .hero-total { margin-top: 0; }
.cal-now { align-items: stretch; }
/* stocul pe locații: pe telefon, o coloană dreaptă cu pastile de aceeași lățime */
@media (max-width: 640px) {
  .stockpair { display: grid; gap: 4px; min-width: 96px; }
  .stockpair .pill-loc { display: flex; justify-content: space-between; gap: 6px; text-align: right; }
}

/* ---------- „Vânzări azi”, varianta 2: grafic pe ore + numerar/card (v1.39) ---------- */
.hero2 { padding: 18px 18px 16px; }
.hero2::after { display: none; }
.hero2.click { cursor: pointer; }
.hero2.click:active { transform: scale(.995); }
.hero-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.hero-chip { flex: none; padding: 3px 9px; border-radius: 99px; background: rgba(255, 255, 255, .18); font: 700 12.5px/1.3 var(--mono); }
.hero2 .k-val { margin-top: 4px; }
.hero2 .k-val .unit { font-size: .42em; margin-left: 6px; opacity: .85; font-weight: 600; }
.hero2 .k-sub { margin-top: 2px; font-size: 13px; }
.hero-chart { display: flex; align-items: flex-end; gap: 3px; height: 56px; margin-top: 12px; }
.hb { position: relative; flex: 1; height: 100%; min-width: 0; }
.hb i { position: absolute; left: 0; right: 0; bottom: 0; border-radius: 4px 4px 2px 2px; transform-origin: bottom; }
.hb-g { background: rgba(255, 255, 255, .16); border: 1px dashed rgba(255, 255, 255, .45); border-bottom: 0; }
.hb-t { left: 18% !important; right: 18% !important; background: rgba(255, 255, 255, .92); }
.hb.now .hb-t { background: var(--puls); }
.hb.now::after { content: ""; position: absolute; left: 50%; bottom: -7px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--puls); }
.hero-chart.grow .hb i { animation: bar-up .6s cubic-bezier(.2, .8, .2, 1) both; }
.hero-chart.grow .hb:nth-child(3n+1) i { animation-delay: .03s; } .hero-chart.grow .hb:nth-child(3n+2) i { animation-delay: .07s; } .hero-chart.grow .hb:nth-child(3n) i { animation-delay: .11s; }
@keyframes bar-up { from { transform: scaleY(0); } to { transform: none; } }
.hero-axis { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 9px; font: 600 11px/1 var(--mono); }
.hero-axis > span[aria-hidden] { opacity: .7; }
.hero-axis .hero-legend { opacity: .85; }
.hero-legend { display: flex; gap: 12px; font: 500 12px/1 var(--body); }
.hero-legend span, .split-lbl span { display: inline-flex; align-items: center; gap: 6px; }
.hero-legend i, .split-lbl i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; }
.lg-t { background: rgba(255, 255, 255, .92); }
.lg-g { background: rgba(255, 255, 255, .16); border: 1px dashed rgba(255, 255, 255, .6); }
.hero-split { margin-top: 14px; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, .22); }
.split-bar { height: 8px; border-radius: 99px; background: rgba(255, 255, 255, .28); overflow: hidden; }
.split-bar i { display: block; height: 100%; background: #fff; border-radius: 99px; transition: width .5s ease; }
.split-lbl { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 8px; font-size: 12.5px; }
.split-lbl b { font-size: 13.5px; }
.lg-cash { background: #fff; } .lg-card { background: rgba(255, 255, 255, .28); }
.split-items { margin-left: auto; opacity: .85; }
.hero2.bump { animation: bump .5s ease; }
@keyframes bump { 40% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--puls) 55%, transparent); } }
@media (max-width: 380px) { .split-items { margin-left: 0; } .hero-chart { gap: 2px; } }
@media (prefers-reduced-motion: reduce) { .hero-chart.grow .hb i, .hero2.bump { animation: none; } .split-bar i { transition: none; } }

/* „peek”: textul lung se taie cu „…”, cifrele rămân întregi */
.fold-peek > .muted { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.fold-peek > .num, .fold-peek > .badge, .fold-peek > .peek-pill, .fold-peek > .peek-dots { flex: none; }
@media (max-width: 380px) {
  .tile b { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
  .fold-peek:has(> .num) > .muted { display: none; }
}
.tile small { display: block; max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- meniul: grupuri pliabile pe telefon, „Deschizi des” sus (v1.39) ---------- */
.nav-sec > summary { list-style: none; display: flex; align-items: center; gap: 8px; }
.nav-sec > summary::-webkit-details-marker { display: none; }
.nav-sec > summary .nav-n, .nav-sec > summary svg { display: none; }
/* pe calculator grupurile se strâng și ele (din 1.54) */
@media (max-width: 900px) {
  .side.open { overflow-y: auto; }
  .nav-sec { border-bottom: 1px solid var(--line); }
  .nav-sec > summary { margin: 0; padding: 14px 10px; min-height: 50px; cursor: pointer; font-size: 13px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; color: var(--muted); }
  .nav-sec > summary .nav-n { display: inline-grid; place-items: center; min-width: 22px; height: 20px; padding: 0 6px; border-radius: 99px; background: var(--surface-2); font-size: 11.5px; letter-spacing: 0; }
  .nav-sec > summary svg { display: block; width: 18px; height: 18px; margin-left: auto; transition: transform .2s ease; }
  .nav-sec[open] > summary svg { transform: rotate(180deg); color: var(--ritm); }
  .nav-sec[open] > summary { color: var(--ink); }
  .nav-sec[open] { padding-bottom: 8px; }
  .nav-sec[open] > a { animation: fold-in .18s ease-out; }
  .nav a { min-height: 46px; }
  .nav-fav-t { margin: 4px 10px 8px; font-size: 13px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; color: var(--muted); }
  .nav-fav-g { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0 4px 14px; }
  .nav-fav-g a { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 10px 12px; border-radius: 14px; background: var(--surface-2); color: var(--ink); text-decoration: none; font-weight: 600; font-size: 14px; line-height: 1.2; }
  .nav-fav-g a svg { width: 20px; height: 20px; flex: none; color: var(--ritm); }
  .nav-fav-g a.active { background: var(--ritm-soft); color: var(--ritm-deep); }
}
@media (prefers-reduced-motion: reduce) { .nav-sec > summary svg { transition: none; } .nav-sec[open] > a { animation: none; } }

/* ---------- bonul pe 2 rânduri: nume + total / preț + cantitate (v1.39) ---------- */
.pos2 .cline { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; padding: 10px 0; }
.pos2 .cline-main { display: contents; }
.pos2 .cline .nm { order: 1; flex: 1 1 0; min-width: 58%; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pos2 .cline-tot { order: 2; flex: none; align-self: flex-start; }
.pos2 .cline .meta { order: 3; flex: 1 1 0; min-width: 92px; margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; white-space: nowrap; }
.pos2 .cline-ctrl { order: 4; flex: none; margin: 0 0 0 auto; gap: 2px; justify-content: flex-end; }
.pos2 .cline-ctrl .btn:first-of-type, .pos2 .cline-ctrl .stepper + .btn { margin-left: 0; }
.pos2 .cline-ctrl .stepper { margin-right: 4px; border-radius: 10px; }
.pos2 .stepper button { width: 36px; height: 36px; }
.pos2 .stepper input { width: 38px; height: 36px; font-size: 15px; }
.pos2 .cline-ctrl .btn.sm { min-height: 36px; min-width: 34px; padding: 0 6px; }
.pos2 .cline-ctrl .btn.sm svg { width: 17px; height: 17px; }
.swipe-hint { display: flex; justify-content: space-between; gap: 8px; margin-top: 8px; padding: 8px 10px; border-radius: 10px; background: var(--surface-2); color: var(--muted); font-size: 12.5px; }
.pay-bar .tot { white-space: nowrap; }
.pay-bar .pb-lbl { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pay-bar .pb-mid { min-width: 0; }
@media (max-width: 380px) { .pos2 .stepper button { width: 32px; } .pos2 .stepper input { width: 32px; } .pos2 .cline-ctrl .btn.sm { min-width: 30px; padding: 0 4px; } .pos2 .cline { gap: 4px 6px; } }

/* ---------- restul paginilor pe telefon (v1.40) ---------- */
/* perioade (Pontaj, Rapoarte…): un singur rând, glisabil */
@media (max-width: 640px) {
  .period { width: 100%; }
  .period .seg { flex-wrap: nowrap; overflow-x: auto; max-width: 100%; scrollbar-width: none; }
  .period .seg::-webkit-scrollbar { display: none; }
  .period .seg button { flex: none; }
}
/* Pontaj: totalul pe un rând */
.pt-total .row h3 { margin: 0; }
.pt-h { font-size: 24px; font-weight: 800; }
/* Target: luna cu săgeți, alături de persoană; cifrele câte două pe rând */
.month-nav { display: inline-flex; align-items: center; gap: 6px; }
.month-nav b { min-width: 0; padding: 0 2px; text-align: center; font-family: var(--display); font-size: 15.5px; white-space: nowrap; }
.filt-row { flex-wrap: nowrap; }
.filt-row select { min-width: 0; flex: 1 1 auto; max-width: 50%; margin-left: auto; }
@media (max-width: 640px) {
  .grid.kpi2 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .grid.kpi2 > :last-child:nth-child(odd) { grid-column: 1 / -1; }
  .kpi2 .kpi .k-sub { font-size: 12px; }
}
/* Transfer: direcțiile pe două rânduri scurte, fără iconiță pe telefon */
.ds-l > span { white-space: nowrap; }
@media (max-width: 480px) {
  .dir-switch.three button svg { display: none; }
  .dir-switch.three button { padding: 6px 6px; min-height: 52px; font-size: 13.5px; line-height: 1.2; }
  .dir-switch.three .ds-l { display: flex; flex-direction: column; align-items: center; }
  .move-bar:not(.has) .mb-txt span, .move-bar:not(.has) .btn.ghost { display: none; }
}
/* Recepție: furnizorul pe tot rândul, factura și data alături */
@media (max-width: 560px) {
  .rec-head { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .rec-head .rec-sup, .rec-head .full { grid-column: 1 / -1; }
  .rec-head .field > span { font-size: 12.5px; }
}
.rec-vat-note { display: block; margin-top: 6px; }

/* ---------- vânzări refuzate, pornire fără semnal (v1.41) ---------- */
.net-bar.bad { background: var(--warn-soft); color: var(--warn-ink); border-bottom: 1px solid color-mix(in srgb, var(--warn) 45%, transparent); }
.rj-why { display: block; margin-top: 4px; color: var(--bad-ink) !important; font-weight: 600; }
.offline-page { text-align: center; padding: 28px 18px; }
.offline-page svg { width: 40px; height: 40px; color: var(--muted); }
.offline-page h2 { margin: 10px 0 6px; }
.rj-li { flex-direction: column; align-items: stretch; gap: 8px; }
.rj-li .row { justify-content: flex-end; }
@media (max-width: 640px) { .topbar [data-queue] { display: none !important; } }
.rj-li .main-txt { flex: none; width: 100%; text-align: left; }
.rj-li .row { justify-content: flex-start; }
.rj-li > .row { width: 100%; justify-content: flex-start !important; }

/* ---------- siguranța datelor (v1.42) ---------- */
.safety-stat { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: var(--r-s); background: var(--surface-2); }
.safe-dot { width: 10px; height: 10px; flex: none; border-radius: 50%; background: var(--warn); }
.safe-dot.ok { background: var(--ok); }
.safety .fold { margin-top: 0; border-color: var(--line); }
.safety details.adv { margin-top: 12px; }
.safety details.adv > summary { cursor: pointer; }
/* orice iconiță din titluri are mărimea textului (nu doar în .card-head) */
h1 > svg, h2 > svg, h3 > svg { width: 1.05em; height: 1.05em; vertical-align: -.16em; margin-right: 6px; color: var(--ritm); flex: none; }

/* ---------- paginile de administrare pe telefon (v1.43) ---------- */
/* coloane ascunse pe telefon / doar pe telefon */
.only-m { display: none; }
@media (max-width: 640px) {
  .hide-m { display: none !important; }
  .only-m { display: revert; }
  .card.only-m, div.only-m { display: block; }
  span.only-m { display: inline; }
  .t td.clip-m { max-width: 46vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .t td.clip-m .muted { overflow: hidden; text-overflow: ellipsis; }
}
.t .nowrap, .nowrap { white-space: nowrap; }
/* secțiunile pliabile din grilă: aceeași înălțime cât sunt închise, pornesc de la aceeași linie */
.grid.rep-folds { margin-top: 10px; align-items: start; gap: 10px; }
.grid.rep-folds > .fold { margin-top: 0; }
.fold.rep-sec { margin-top: 10px; }
/* rânduri de comenzi (Ore de vârf, ABC): se așază pe două rânduri curate pe telefon */
.rep-ctl { flex-wrap: wrap; }
.thr-l { display: inline-flex; align-items: center; gap: 6px; flex-wrap: nowrap; }
.seg.seg-scroll { display: flex; flex-wrap: nowrap; overflow-x: auto; max-width: 100%; scrollbar-width: none; }
.seg.seg-scroll::-webkit-scrollbar { display: none; }
.seg.seg-scroll button { flex: none; white-space: nowrap; }
.cmp-pick { display: grid; grid-template-columns: auto 1fr 1fr; gap: 8px; align-items: center; }
.cmp-pick .btn { grid-column: 1 / -1; justify-self: start; }
@media (min-width: 900px) { .cmp-pick { display: flex; flex-wrap: wrap; } }
@media (max-width: 640px) {
  .card-head.wrap-m { flex-wrap: wrap; row-gap: 6px; }
  .tabs { scrollbar-width: none; margin-left: -4px; margin-right: -4px; }
  .tabs::-webkit-scrollbar { display: none; }
}
/* Profit și cheltuieli: luna cu săgeți pe un rând; sumele nu se rup pe două rânduri */
.fin-head { margin-bottom: 10px; gap: 8px; flex-wrap: nowrap; }
.fin-head .month-nav b { min-width: 128px; font-size: 17px; }
.fin-head .badge { white-space: nowrap; }
.pl-row > span { min-width: 0; }
.pl-row > b.num { white-space: nowrap; flex: none; }
.cost-head { margin-bottom: 10px; flex-wrap: nowrap; gap: 10px; }
.cost-sum { display: flex; flex-direction: column; min-width: 0; margin-right: auto; }
.cost-head .btn { flex: none; }
.pick-acts { display: inline-flex; flex: none; }
@media (max-width: 480px) {
  .pick-card .pick { flex-wrap: wrap; row-gap: 2px; }
  .pick-card .pick .pick-main { flex: 1 1 calc(100% - 110px); }
  .pick-card .pick .pick-acts { margin-left: auto; }
  .fin-head .month-nav b { min-width: 0; }
}
/* Echipa: pe telefon, listă în loc de tabel; sus, câți oameni sunt activi */
.team-sum { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin: 0 2px 10px; }
.team-sum b.num { font-family: var(--mono); font-size: 22px; font-weight: 700; }
.team-sum .badge { margin-left: auto; align-self: center; }
.team-cards { padding: 4px 14px; }
.team-cards .list li { min-height: 56px; }
.team-cards .main-txt { min-width: 0; }
.team-cards .main-txt b, .team-cards .main-txt span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fold.team-help { margin-top: 14px; }
@media (max-width: 420px) { .tact-list .btn .bl { display: none; } }
/* Setări: secțiuni pliabile, bara de salvare la vedere când ai modificat ceva */
.set-grid { align-items: start; }
.set-col > .fold + .fold, .set-form > .fold + .fold, .set-col > .set-form + .set-save, .set-col > .set-save + .fold { margin-top: 10px; }
.set-col > .set-form > .fold:first-child { margin-top: 0; }
.set-sub { border-top: 1px solid var(--line); padding-top: 10px; }
.set-sub span { font-weight: 600; }
.set-save { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: var(--r); background: var(--surface-2); }
.set-save .muted { min-width: 0; }
.set-save.dirty { position: sticky; bottom: 12px; z-index: 5; background: var(--surface); border: 1px solid var(--ritm); box-shadow: 0 6px 20px rgba(13, 24, 48, .12); }
.set-save.dirty [data-savehint] { color: var(--ritm-deep, var(--ritm)); font-weight: 600; }
@media (max-width: 900px) { .set-save.dirty { bottom: calc(72px + env(safe-area-inset-bottom, 0px)); } }
.safe-peek { display: inline-flex; align-items: center; gap: 6px; min-width: 0; overflow: hidden; }
.safe-peek .muted { overflow: hidden; text-overflow: ellipsis; }
.exp-btns { display: flex; flex-wrap: wrap; gap: 8px; }
@media (max-width: 480px) { .exp-btns .btn { flex: 1 1 calc(50% - 8px); justify-content: center; } }
/* 4 cifre pe un rând: 4 sau 2 coloane, niciodată 3 + 1 (tabletă) */
@media (min-width: 641px) and (max-width: 1100px) { .grid.g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 761px) and (max-width: 1100px) { .grid.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
/* Ore de vârf: tabelul nu mai moștenește grila hărții de pe fila Vânzări; ziua rămâne la vedere când derulezi orele */
table.heat { display: table; min-width: 0; }
table.heat tbody th, table.heat thead th:first-child { position: sticky; left: 0; z-index: 1; background: var(--surface); }
@media (max-width: 640px) {
  .t td.clip-m { max-width: 36vw; }
  .cmp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .cmp { padding: 10px 12px; }
  .cmp .cv small { display: block; }
  .loc-card .stat-row { font-size: 12.5px; gap: 6px; }
  .loc-card .stat-row span { min-width: 0; }
}
@media (max-width: 640px) { .cmp .cv { flex-direction: column; align-items: flex-start; gap: 0; } .cmp .cv b { font-size: 18px; max-width: 100%; } }

/* ---------- Jurnal și Necesar pe telefon (v1.44) ---------- */
/* Jurnal: pe telefon fiecare rând devine un card scurt: acțiunea și ora sus, cine dedesubt, detaliile pe toată lățimea */
@media (max-width: 640px) {
  .jr-filt { gap: 8px; }
  .jr-filt select { flex: 1 1 calc(50% - 8px); min-width: 0; width: auto !important; }
  .audit-t thead { display: none; }
  .audit-t, .audit-t tbody { display: block; }
  .audit-t tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "act ts" "who who" "data data"; gap: 2px 8px; padding: 10px 0; border-bottom: 1px solid var(--line); }
  .audit-t tr:last-child { border-bottom: 0; }
  .t.audit-t td { display: block; padding: 0; border: 0; }
  .audit-t .au-act { grid-area: act; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .audit-t .au-ts { grid-area: ts; font-size: 12.5px; color: var(--muted); align-self: center; }
  .audit-t .au-who { grid-area: who; font-size: 13px; font-weight: 600; }
  .audit-t .au-data { grid-area: data; font-size: 12.5px; color: var(--muted); overflow-wrap: anywhere; word-break: normal; }
  .audit-t .au-data:empty { display: none; }
  .card:has(> .table-wrap > .audit-t) { padding-top: 4px; padding-bottom: 4px; }
}
/* Necesar → Lista de comandat: numele pe tot rândul, cantitatea și butoanele dedesubt */
.ord-top { margin-bottom: 10px; flex-wrap: nowrap; }
.ord-ctl { display: flex; align-items: flex-end; gap: 8px; flex: none; }
@media (max-width: 640px) {
  .ord-pick { flex-wrap: wrap; row-gap: 8px; }
  .ord-pick .pick-main { flex: 1 1 100%; }
  .ord-pick .ord-ctl { flex: 1 1 100%; }
  .ord-pick .ord-ctl .ord-q { flex: 1 1 auto; width: auto; max-width: 140px; }
  .ord-pick .ord-ctl [data-done] { margin-left: auto; }
}
@media (max-width: 420px) { .ord-top .btn .bl { display: none; } }
/* Necesar → Sugestii: parametrii câte trei pe un rând, formula dedesubt; antetul furnizorului pe două rânduri curate */
.nec-formula { flex: 1; min-width: 220px; margin: 0; }
.sup-head { margin-bottom: 6px; flex-wrap: wrap; row-gap: 4px; }
@media (max-width: 640px) {
  .nec-par { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .nec-par .field input { width: 100% !important; }
  .nec-par .field > span { font-size: 11.5px; line-height: 1.2; min-height: 2.4em; display: flex; align-items: flex-end; }
  .nec-par .nec-formula { grid-column: 1 / -1; min-width: 0; }
  .sup-head h3 { flex: 1 1 auto; }
}

/* ---------- ferestre și preferințe (v1.46) ---------- */
/* Personalizează Acasă: iconița mică, textul pe un rând, săgețile la dreapta */
.home-edit { display: flex; flex-direction: column; gap: 6px; }
.home-edit .he-row { min-height: 48px; }
.home-edit .he-tile { flex: 1; min-width: 0; min-height: 0; display: flex; align-items: center; gap: 10px; }
.home-edit .he-row .he-ic { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 9px; background: var(--ritm-soft); color: var(--ritm); }
.home-edit .he-ic svg { width: 18px; height: 18px; }
.home-edit .he-row .he-l { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-edit .he-row .icon-btn { flex: none; }
/* Vezi aplicația ca…: numele pe un rând, ochiul mic */
.viewas-list li { min-height: 56px; }
.viewas-list .main-txt { flex: 1; min-width: 0; }
.viewas-list .main-txt b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.viewas-list .va-ic { display: grid; place-items: center; width: 32px; height: 32px; flex: none; color: var(--muted); }
.viewas-list .va-ic svg { width: 20px; height: 20px; }
/* Notificări: grupuri pliabile în cardul de notificări */
.notif-cats { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.fold.nc-fold { margin: 0; box-shadow: none; background: var(--surface-2); border-color: transparent; }
.fold.nc-fold > summary { min-height: 52px; padding: 10px 12px; }
.fold.nc-fold .fold-t b { font-size: 15px; }
.fold.nc-fold .fold-body { padding: 0 12px 6px; }
.fold.nc-fold .nc-row:last-child { border-bottom: 0; }
.nc-peek { display: inline-flex; align-items: center; gap: 6px; min-width: 0; }
.nc-peek .muted { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fold.nc-fold .fold-t { max-width: 66%; }
.fold.nc-fold .fold-t b { display: flex; flex-direction: column; min-width: 0; }
.nc-sub { font-family: var(--body); font-size: 12px; font-weight: 500; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fold.nc-fold[open] .nc-sub { display: none; }
@media (max-width: 380px) { .nc-peek .muted { display: none; } }

/* ---------- Pontaj pe zile (v1.47) ---------- */
.pt-people { margin-top: 8px; }
.pt-pbar { display: block; height: 4px; border-radius: 3px; background: var(--surface-2); margin-top: 5px; overflow: hidden; }
.pt-pbar > i { display: block; height: 100%; border-radius: 3px; opacity: .85; }
.pt-days { display: flex; flex-direction: column; gap: 2px; }
.pt-axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); font-family: var(--mono); padding: 0 2px; margin-bottom: -6px; }
.pt-day > header { display: flex; align-items: baseline; gap: 8px; padding: 4px 2px 6px; border-bottom: 1px solid var(--line); }
.pt-day > header b:first-child { font-family: var(--display); font-size: 15px; }
.pt-row { padding: 9px 2px 10px; border-bottom: 1px dashed var(--line); border-radius: 8px; }
.pt-row:last-child { border-bottom: 0; }
.pt-row.click { cursor: pointer; }
.pt-row.click:hover { background: color-mix(in srgb, var(--surface-2) 60%, transparent); }
.pt-row.click:active { background: var(--surface-2); }
.pt-top { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pt-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 650; }
.pt-time { white-space: nowrap; color: var(--muted); font-size: 13.5px; display: inline-flex; align-items: center; gap: 4px; }
.pt-hours { font-family: var(--mono); font-weight: 700; white-space: nowrap; }
.pt-bar { position: relative; height: 8px; margin-top: 7px; border-radius: 5px; background: repeating-linear-gradient(90deg, var(--surface-2) 0 calc(25% - 1px), var(--line) calc(25% - 1px) 25%); }
.pt-bar > i { position: absolute; top: 0; bottom: 0; border-radius: 5px; background: var(--c); }
.pt-bar > i.live { background: linear-gradient(90deg, var(--c), color-mix(in srgb, var(--c) 40%, transparent)); }
.pt-flags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
@media (prefers-reduced-motion: no-preference) { .pt-bar > i { animation: pt-grow .35s ease-out both; transform-origin: left; } @keyframes pt-grow { from { transform: scaleX(0); } } }

/* ---------- tabele care devin carduri pe telefon (.m-cards) ---------- */
/* c-main = textul principal, c-val = cifra din dreapta; restul celulelor (ora, cine, plata…) stau dedesubt, mărunt */
@media (max-width: 640px) {
  .t.m-cards thead { display: none; }
  .t.m-cards, .t.m-cards tbody { display: block; width: 100%; }
  .t.m-cards tr { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 6px; row-gap: 3px; padding: 10px 2px; border-bottom: 1px solid var(--line); }
  .t.m-cards tr:last-child { border-bottom: 0; }
  .t.m-cards td { display: block; padding: 0; border: 0 !important; text-align: left; }
  .t.m-cards td.c-main { order: 1; flex: 1 1 calc(100% - 120px); min-width: 0; font-weight: 600; line-height: 1.35; }
  .t.m-cards td.c-val { max-width: 112px; }
  .t.m-cards td.c-val { order: 2; flex: none; font-weight: 700; text-align: right; }
  .t.m-cards td:not(.c-main):not(.c-val) { order: 3; flex: none; font-size: 12.5px; color: var(--muted); white-space: nowrap; }
  .t.m-cards td:not(.c-main):not(.c-val):empty { display: none; }
  .t.m-cards td.c-who::before, .t.m-cards td.c-pay::before { content: "· "; }
  .t.m-cards td.c-what { white-space: normal; flex: 1 1 100%; order: 4; }
  .t.m-cards tr.cancelled td.c-main, .t.m-cards tr.cancelled td.c-val { text-decoration: line-through; opacity: .6; }
  .t.m-cards .c-main .badge { font-size: 11px; vertical-align: 1px; }
}

/* ---------- Calendar: concediile (v1.47) ---------- */
.lv-card { margin-top: 14px; }
.lv-card .card-head h3 { display: flex; align-items: center; gap: 8px; }
.lv-sub { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin: 2px 0 4px; }
.lv-list .lv-item { flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.lv-kind { flex: none; font-size: 11.5px; font-weight: 700; padding: 3px 8px; border-radius: 999px; color: var(--ink); background: color-mix(in srgb, var(--kc) 22%, transparent); }
.lv-item .main-txt { flex: 1 1 160px; min-width: 0; }
.lv-acts { display: flex; gap: 8px; margin-left: auto; }
@media (max-width: 480px) { .lv-acts { flex: 1 1 100%; } .lv-acts .btn { flex: 1; justify-content: center; } }
.fold.lv-hist { margin-top: 10px; box-shadow: none; background: var(--surface-2); border-color: transparent; }

/* ---------- Istoric modificări: cronologie compactă (v1.47) ---------- */
.rv-list { display: flex; flex-direction: column; }
.rv-day { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 12px 2px 4px; }
.rv-day:first-child { padding-top: 0; }
.rv { position: relative; display: flex; align-items: center; gap: 10px; padding: 8px 2px; min-height: 52px; }
.rv + .rv::before { content: ""; position: absolute; left: 17px; top: -8px; height: 16px; width: 2px; background: var(--line); }
.rv-ic { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 50%; color: var(--rc); background: color-mix(in srgb, var(--rc) 14%, transparent); }
.rv-ic svg { width: 16px; height: 16px; }
.rv-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.rv-main b { font-weight: 600; font-size: 14px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rv-main span { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rv-main em { font-style: normal; }
.rv.off .rv-main b { text-decoration: line-through; opacity: .55; }
.rv.off .rv-ic { filter: grayscale(1); opacity: .6; }
.rv-undo { flex: none; }
@media (max-width: 640px) { .rv-undo .bl { display: none; } .rv-undo { width: 40px; padding: 0; justify-content: center; } }

/* ---------- dispozitive conectate (v1.48) ---------- */
.sess-list li { min-height: 52px; }
.sess-ic { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 50%; background: var(--surface-2); color: var(--muted); }
.sess-ic svg { width: 16px; height: 16px; }
.sess-list .main-txt { min-width: 0; flex: 1; }
.sess-list .main-txt > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }

/* ---------- Pontaj compact + raport ore în program (v1.48) ---------- */
.pt-row { position: relative; display: flex; align-items: center; gap: 8px; padding: 9px 2px 11px; min-height: 44px; border-bottom: 1px dashed var(--line); }
.pt-row .pt-name { flex: 1 1 auto; min-width: 0; }
.pt-row .pt-time { flex: none; display: inline-flex; align-items: center; gap: 4px; font-size: 13px; }
.pt-row .pt-time small { font-size: 10px; vertical-align: super; }
.pt-row .pt-time .live-dot { width: 8px; height: 8px; margin-left: 3px; }
.pt-row .pt-hours { flex: none; min-width: 58px; text-align: right; }
.pt-row:not(:has(.pt-name)) .pt-time { flex: 1; }
.pt-line { position: absolute; bottom: 3px; height: 3px; border-radius: 2px; background: var(--c); opacity: .9; }
.pt-line.live { background: linear-gradient(90deg, var(--c), color-mix(in srgb, var(--c) 30%, transparent)); }
.pt-flag { flex: none; font-size: 10.5px; font-weight: 700; padding: 1px 6px; border-radius: 999px; background: var(--surface-2); color: var(--muted); }
.pt-flag.warn { background: var(--warn-soft, #fdf1dc); color: var(--warn-ink); }
.pt-axis { display: none; }
.pt-bar, .pt-flags { display: none; }
.pt-report .card-head h3 { display: flex; align-items: center; gap: 8px; }
.pt-rep-row { display: grid; grid-template-columns: 10px minmax(0, 1fr) minmax(50px, 32%) auto 64px; align-items: center; gap: 8px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.pt-rep-row:last-child { border-bottom: 0; }
.pt-rep-row .pt-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 650; }
.pt-rep-bar { height: 6px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
.pt-rep-bar > i { display: block; height: 100%; border-radius: 4px; }
.pt-rep-d { white-space: nowrap; }
.pt-rep-row .pt-hours { text-align: right; }
@media (max-width: 380px) { .pt-rep-row { grid-template-columns: 10px minmax(0, 1fr) 30% 58px; } .pt-rep-d { display: none; } }

/* ---------- Rapoarte PDF (v1.48): constructorul și documentul ---------- */
.rp-builder > .card + .card, .rp-builder > .card + .fold, .rp-builder > .fold { margin-top: 12px; }
.rp-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(240px, 100%), 1fr)); gap: 8px; margin-top: 10px; }
.rp-opt { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r); cursor: pointer; min-height: 56px; }
.rp-opt:has(input:checked) { border-color: var(--ritm); background: var(--ritm-soft); }
.rp-opt input { width: 20px; height: 20px; accent-color: var(--ritm); flex: none; }
.rp-opt-ic { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 9px; background: var(--surface-2); color: var(--ritm); }
.rp-opt-ic svg { width: 18px; height: 18px; }
.rp-opt b { display: block; font-size: 14.5px; }
.rp-opt small { display: block; color: var(--muted); font-size: 12px; line-height: 1.3; }
.rp-go { margin-top: 14px; gap: 8px; }
.rp-out { margin-top: 16px; }

.rp-doc { --c: #2F5BFF; --i: #0D1830; --m: #5B6B8C; --l: #DDE3EE; --p: #F5F7FB; --s: #E6ECFF; --puls: #C8F04B;
  color: var(--i); font-family: var(--body); font-size: 12.5px; line-height: 1.45; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.rp-page { background: #fff; color: var(--i); max-width: 794px; margin: 0 auto 18px; padding: 34px 38px 30px; border-radius: 14px; box-shadow: 0 1px 2px rgba(13,24,48,.06), 0 8px 30px rgba(13,24,48,.08); }
@media (max-width: 640px) { .rp-page { padding: 18px 16px; border-radius: 12px; } }
.rp-num { font-family: var(--mono); font-feature-settings: "tnum" 1; }
.rp-muted, .rp-cap { color: var(--m); font-size: 11.5px; }
.rp-cap { margin: 6px 0 0; }
.rp-band { display: flex; align-items: center; justify-content: space-between; background: var(--i); color: #F5F7FB; margin: -34px -38px 26px; padding: 18px 38px; border-radius: 14px 14px 0 0; }
@media (max-width: 640px) { .rp-band { margin: -18px -16px 18px; padding: 14px 16px; } }
.rp-brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 800; font-size: 24px; letter-spacing: -.02em; }
.rp-band-r { font-size: 12px; opacity: .8; text-align: right; }
.rp-kicker { display: inline-block; margin: 0 0 8px; padding: 3px 10px; border-radius: 999px; background: var(--puls); color: #1B2A05; font-weight: 700; font-size: 11.5px; }
.rp-hero h1 { font-family: var(--display); font-weight: 800; font-size: 34px; line-height: 1.05; letter-spacing: -.025em; margin: 0; }
.rp-sub { color: var(--m); margin: 8px 0 18px; }
.rp-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 6px 0 14px; }
.rp-kpi { background: var(--p); border-radius: 12px; padding: 12px 14px; break-inside: avoid; }
.rp-kpi > span { display: block; color: var(--m); font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.rp-kpi > b { display: block; font-size: 20px; font-weight: 700; margin-top: 4px; letter-spacing: -.02em; white-space: nowrap; }
.rp-kpi .rp-u { font-size: 11px; font-weight: 600; color: var(--m); margin-left: 3px; letter-spacing: 0; }
.rp-kpi > small { display: block; color: var(--m); font-size: 11px; margin-top: 2px; }
.rp-delta { font-family: var(--mono); font-weight: 700; font-size: 11px; padding: 1px 6px; border-radius: 999px; margin-right: 4px; }
.rp-delta.up { color: #0F7A5F; background: #E2F5EF; } .rp-delta.down { color: #CE1D23; background: #FDE8E9; }
.rp-ins { border-left: 3px solid var(--c); background: var(--s); border-radius: 0 12px 12px 0; padding: 12px 16px; margin: 0 0 14px; break-inside: avoid; }
.rp-ins h3, .rp-box h3, .rp-toc h3, .rp-note h3 { font-family: var(--display); font-size: 14px; font-weight: 700; margin: 0 0 6px; }
.rp-ins ul { margin: 0; padding-left: 18px; } .rp-ins li { margin: 3px 0; }
.rp-ins.big { margin-top: 6px; } .rp-ins.big li { font-size: 13.5px; }
.rp-note { border: 1px dashed var(--l); border-radius: 12px; padding: 12px 16px; margin-bottom: 14px; }
.rp-note p { margin: 0; }
.rp-toc ol { margin: 0; padding-left: 20px; } .rp-toc li { margin: 4px 0; } .rp-toc li span { color: var(--m); margin-left: 6px; font-size: 11.5px; }
.rp-foot { margin-top: 22px; padding-top: 10px; border-top: 1px solid var(--l); color: var(--m); font-size: 10.5px; }
.rp-sec-h { display: flex; align-items: center; gap: 12px; padding-bottom: 12px; margin-bottom: 14px; border-bottom: 2px solid var(--i); }
.rp-sec-h h2 { font-family: var(--display); font-weight: 800; font-size: 24px; margin: 0; letter-spacing: -.02em; }
.rp-sec-h p { margin: 2px 0 0; color: var(--m); font-size: 11.5px; }
.rp-ic { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--c); color: #fff; flex: none; }
.rp-ic svg { width: 20px; height: 20px; }
.rp-box { border: 1px solid var(--l); border-radius: 12px; padding: 12px 14px; margin-bottom: 12px; break-inside: avoid; }
.rp-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } .rp-2 > .rp-box { margin-bottom: 12px; }
@media (max-width: 640px) { .rp-2 { grid-template-columns: 1fr; gap: 0; } }
.rp-chart { width: 100%; height: auto; display: block; }
.rp-ax { font: 9.5px var(--mono); fill: #5B6B8C; }
.rp-hbars { display: flex; flex-direction: column; gap: 7px; }
.rp-hb { display: grid; grid-template-columns: minmax(90px, 34%) 1fr auto; align-items: center; gap: 10px; }
.rp-hb-l { min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-hb-l small { display: block; font-weight: 400; color: var(--m); font-size: 10.5px; overflow: hidden; text-overflow: ellipsis; }
.rp-hb-t { height: 10px; background: var(--p); border-radius: 6px; overflow: hidden; }
.rp-hb-t > i { display: block; height: 100%; border-radius: 6px; }
.rp-hb > b { font-size: 12px; min-width: 70px; text-align: right; }
.rp-donut { display: flex; align-items: center; gap: 14px; }
.rp-donut svg { flex: none; }
.rp-donut ul { list-style: none; margin: 0; padding: 0; flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.rp-donut li { display: grid; grid-template-columns: 10px 1fr auto; gap: 2px 8px; align-items: center; font-size: 11.5px; }
.rp-donut li i { width: 10px; height: 10px; border-radius: 3px; }
.rp-donut li span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-donut li small { grid-column: 2 / -1; color: var(--m); font-size: 10.5px; margin-top: -3px; }
.rp-tw { overflow-x: auto; margin: 0 -2px; }
.rp-t { width: 100%; border-collapse: collapse; font-size: 11.5px; }
@media (max-width: 640px) { .rp-t { font-size: 11px; } .rp-t th, .rp-t td { padding: 5px 4px; } }
.rp-t th { text-align: left; color: var(--m); font-weight: 600; font-size: 10.5px; text-transform: uppercase; letter-spacing: .03em; padding: 6px 6px; border-bottom: 1px solid var(--l); }
.rp-t td { padding: 6px; border-bottom: 1px solid #EEF1F6; }
.rp-t tr:nth-child(even) td { background: #FAFBFD; }
.rp-t .r { text-align: right; white-space: nowrap; }
.rp-heat { width: 100%; border-collapse: separate; border-spacing: 2px; font-size: 9.5px; color: var(--m); }
.rp-heat td { height: 16px; border-radius: 3px; }
.rp-heat th { font-weight: 600; }
.rp-prog { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; margin-top: 12px; font-size: 11.5px; }
.rp-prog > i { height: 10px; background: var(--p); border-radius: 6px; overflow: hidden; display: block; }
.rp-prog > i > b { display: block; height: 100%; background: var(--puls); }
@media print {
  #print-area .rp-page { box-shadow: none; border-radius: 0; max-width: none; margin: 0; padding: 0; }
  #print-area .rp-band { margin: 0 0 22px; border-radius: 12px; padding: 16px 22px; }
  #print-area .rp-sec { break-before: page; }
  #print-area .rp-2 { grid-template-columns: 1fr 1fr; gap: 12px; }
  #print-area .rp-doc { font-size: 11.5px; }
}

/* ---------- raportul lunar: exemplul într-o fereastră (v1.49) ---------- */
.mr-frame { width: 100%; height: 70vh; border: 0; border-radius: 12px; background: #F5F7FB; }

/* ---------- corectarea stocului și acțiunile la vedere din fișa produsului (1.51) ---------- */
.pd-quick { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.pd-quick .btn { justify-content: center; }
.adj-dir { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.adj-dir button { display: grid; justify-items: center; gap: 2px; padding: 12px 8px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; font: inherit; }
.adj-dir button b { font-size: 16px; }
.adj-dir button span { font-size: 12px; color: var(--muted); }
.adj-dir button svg { width: 22px; height: 22px; }
.adj-dir button[data-d="-1"].on { border-color: var(--bad); background: var(--bad-soft); color: var(--bad-ink); }
.adj-dir button[data-d="1"].on { border-color: var(--ok); background: var(--ok-soft); color: var(--ok-ink); }
.adj-dir button.on span { color: inherit; opacity: .8; }
.qty-step { display: grid; grid-template-columns: 56px 1fr 56px; gap: 8px; align-items: center; }
.qty-step .btn { height: 60px; justify-content: center; }
.qty-step .input { margin: 0; }
[data-chips].chips { flex-wrap: wrap; overflow: visible; margin-bottom: 0; }
.adj-sum { margin-top: 10px; padding: 10px 12px; border-radius: 12px; background: var(--ritm-soft); font-size: 14px; }
.adj-sum:empty { display: none; }
.close-cl { border: 1px solid var(--line); border-radius: 14px; padding: 4px 12px; background: var(--surface); }
.close-cl-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 0 4px; }
.close-cl .cl-item { padding: 10px 0; }

/* ---------- Pontaj: zilele se strâng (1.51); pe telefon, fără orele de început și sfârșit pe rând ---------- */
details.pt-day > summary { font-family: inherit; list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--line); }
details.pt-day > summary > b:first-child { font-family: var(--display); font-size: 15px; }
details.pt-day > summary::-webkit-details-marker { display: none; }
details.pt-day > summary .fold-chev { display: inline-grid; transition: transform .2s; color: var(--muted); }
details.pt-day > summary .fold-chev svg { width: 18px; height: 18px; }
details.pt-day[open] > summary .fold-chev { transform: rotate(180deg); }
details.pt-day:not([open]) > summary { border-bottom-style: dashed; }
@media (max-width: 900px) {
  .pt-row .pt-time { display: none; }
}
.pd-quick .btn svg { width: 18px; height: 18px; }
.adj-dir ~ .field { display: grid; gap: 6px; margin-bottom: 12px; }

/* Stoc → „Editează prețuri” / „Modifică stoc”: cifrele se scriu direct în tabel (1.52) */
.edit-hint { margin: 0 0 10px; }
.input.cell-in { width: 96px; min-height: 38px; padding: 6px 10px; text-align: right; font-family: var(--mono); font-size: 14px; font-weight: 600; }
.input.cell-in.edited { border-color: var(--cobalt); background: var(--cobalt-soft); box-shadow: inset 3px 0 0 var(--cobalt); }
.input.cell-in.bad { border-color: var(--bad); background: var(--bad-soft); }
.edit-t td { vertical-align: middle; }
.edit-list li { gap: 10px; }
.edit-cell { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex: none; }
.edit-cell > span { font-size: 11px; color: var(--muted); }
.edit-pair { display: flex; gap: 6px; flex: none; }
.edit-list .input.cell-in { width: 76px; min-height: 44px; font-size: 16px; }
.edit-pair .input.cell-in { width: 64px; }
.eb-lab { min-height: 0; font-size: 12.5px; gap: 6px; margin-top: 2px; opacity: .9; }
.eb-lab input { width: 16px; height: 16px; }
.edit-bar .eb-lab { white-space: nowrap; }
@media (max-width: 900px) {
  .move-bar.edit-bar { position: fixed; left: 10px; right: 10px; bottom: calc(var(--nav-h) + 6px + env(safe-area-inset-bottom, 0px)); margin: 0; }
  body:has(.edit-bar:not(.hidden)) .main { padding-bottom: calc(var(--nav-h) + 96px); }
  .move-bar.edit-bar .btn[data-ecancel] { display: inline-flex; }
  .edit-bar .btn { padding-left: 12px; padding-right: 12px; }
}

/* ---------- Aspect viu (1.53): mai multă culoare din paleta brandului, titluri mai mari, tranziții discrete ----------
   Reguli: Cobalt = primar; Cerneală pentru contrast; Puls doar „live / crește” (punctul live, Targetul); fără gradienturi
   și fără umbre grele. Mișcarea folosește doar opacitate și transform, și se oprește cu prefers-reduced-motion. */
:root { --tint-cobalt: color-mix(in srgb, var(--cobalt) 7%, var(--surface)); --tint-ink: color-mix(in srgb, var(--ink) 5%, var(--surface)); --tint-puls: color-mix(in srgb, var(--puls) 22%, var(--surface)); --ring: 0 0 0 1px var(--line); --lift: 0 1px 2px rgba(13, 24, 48, .05); }
.fold-ic { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 10px; background: var(--cobalt-soft); }
.fold-ic svg { width: 18px !important; height: 18px !important; color: var(--cobalt) !important; }
.puls-dot { display: inline-block; width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--puls); animation: puls-beat 2.4s ease-out infinite; }
@keyframes puls-beat { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--puls) 65%, transparent); } 70%, 100% { box-shadow: 0 0 0 7px transparent; } }

/* salutul de pe Acasă */
.home-hello { margin: 2px 2px 14px; }
.home-hello h2 { font-family: var(--display); font-weight: 800; font-size: 28px; line-height: 1.1; letter-spacing: -.025em; color: var(--ink); }
.home-hello p { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; margin: 4px 0 0; color: var(--muted); font-size: 14px; }
.hello-live { display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px 2px 7px; border-radius: 99px; background: var(--band); color: var(--band-fg); font: 600 12px/1.6 var(--mono); }

/* titluri mai mari, în Bricolage */
.topbar .title { font-size: 20px !important; font-weight: 800; letter-spacing: -.02em; }
.page-head h1 { font-size: 34px; font-weight: 800; letter-spacing: -.03em; }
.card-head h3 { font-size: 17px; font-weight: 700; letter-spacing: -.01em; gap: 10px; }
.fold-t { gap: 10px; }
.fold-t b { font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.fold-peek .num { font-size: 15.5px; }

/* carduri mai vii: margine fină în loc de chenar, ridicare ușoară la atingere / mouse */
.card { border-color: transparent; box-shadow: var(--lift), var(--ring); transition: box-shadow .18s ease, transform .18s ease; }
.hero-total, .move-bar.has { box-shadow: none; }
.card.click:hover, .card[onclick]:hover { box-shadow: 0 6px 18px rgba(13, 24, 48, .08), var(--ring); }
.fold[open] { box-shadow: 0 6px 18px rgba(13, 24, 48, .06), 0 0 0 1px color-mix(in srgb, var(--cobalt) 22%, var(--line)); }
/* iconițele secțiunilor pliabile: Cobalt deschis peste tot; pe Acasă, câteva în Cobalt și Cerneală */
[data-fold="prognoza"] .fold-ic, [data-fold="recente"] .fold-ic { background: var(--cobalt); }
[data-fold="prognoza"] .fold-ic svg, [data-fold="recente"] .fold-ic svg { color: #fff !important; }
[data-fold="rezolvat"] .fold-ic, [data-fold="vanzatori"] .fold-ic { background: var(--band); }
[data-fold="rezolvat"] .fold-ic svg, [data-fold="vanzatori"] .fold-ic svg { color: var(--band-fg) !important; }
[data-fold="echipa"] .fold-ic, [data-fold="checklist"] .fold-ic { background: var(--cobalt-soft); }
[data-fold="echipa"] .fold-ic svg, [data-fold="checklist"] .fold-ic svg { color: var(--cobalt) !important; }

/* scurtăturile: fundal colorat discret, iconiță plină, titlu în Bricolage */
.tile { border-color: transparent; box-shadow: var(--lift), var(--ring); transition: transform .12s ease, box-shadow .18s ease; }
.tile b { font-family: var(--display); font-weight: 700; letter-spacing: -.01em; }
.tile.tone-primary { box-shadow: 0 4px 14px color-mix(in srgb, var(--cobalt) 28%, transparent); }
.tile.tone-primary .tile-ic { background: rgba(255, 255, 255, .2); color: #fff; }
.tone-cobalt { background: var(--tint-cobalt); box-shadow: 0 0 0 1px color-mix(in srgb, var(--cobalt) 16%, transparent); }
.tone-cobalt .tile-ic { background: var(--cobalt); color: #fff; }
.tone-ink .tile-ic { background: var(--band); color: var(--band-fg); }
.tone-soft .tile-ic { background: var(--cobalt-soft); color: var(--cobalt); }
.tone-puls { background: var(--tint-puls); box-shadow: 0 0 0 1px color-mix(in srgb, var(--puls) 55%, transparent); }
.tone-puls .tile-ic { background: var(--puls); color: var(--puls-ink); }
@media (hover: hover) { .tile:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(13, 24, 48, .1), var(--ring); } }

/* cifrele mari (Rapoarte, Profit): un pătrățel de culoare lângă etichetă */
.kpi .k-label { display: flex; align-items: center; gap: 7px; }
.kpi .k-label::before { content: ""; width: 8px; height: 8px; flex: none; border-radius: 3px; background: var(--cobalt); }
.kpis > .kpi:nth-child(3n+2) .k-label::before, .grid > .kpi:nth-child(3n+2) .k-label::before { background: var(--band); }
.kpis > .kpi:nth-child(3n) .k-label::before, .grid > .kpi:nth-child(3n) .k-label::before { background: color-mix(in srgb, var(--cobalt) 45%, var(--surface)); }

/* eroul vânzărilor */
.hero2 .k-label { display: inline-flex; align-items: center; gap: 8px; }
.hero2 { border-radius: 22px; }
.hero2 .k-val { font-size: clamp(34px, 14cqi, 52px); }

/* meniul din stânga și bara de jos: elementul activ, mai clar */
.nav a { transition: background-color .15s ease, color .15s ease; }
.nav a.active { position: relative; background: var(--cobalt-soft); color: var(--cobalt); }
.nav a.active::before { content: ""; position: absolute; left: -10px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: var(--cobalt); }
.bottom-nav a svg { transition: transform .18s ease; }
.bottom-nav a.active svg { transform: translateY(-1px) scale(1.06); }
.seg button { transition: background-color .15s ease, color .15s ease; }
.seg button.on { color: var(--cobalt); }

/* tranziții: pagina intră lin, cardurile pe rând (doar la schimbarea paginii, nu la reîmprospătare) */
@keyframes rise-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.page-enter > *, .page-enter .home-grid > .stack > *, .page-enter .tiles > * { animation: rise-in .32s cubic-bezier(.2, .8, .2, 1) both; }
.page-enter > :nth-child(2), .page-enter .tiles > :nth-child(2) { animation-delay: .04s; }
.page-enter > :nth-child(3), .page-enter .tiles > :nth-child(3) { animation-delay: .08s; }
.page-enter > :nth-child(4), .page-enter .tiles > :nth-child(4), .page-enter .home-grid > .stack > :nth-child(1) { animation-delay: .12s; }
.page-enter > :nth-child(n+5), .page-enter .tiles > :nth-child(n+5), .page-enter .home-grid > .stack > :nth-child(2) { animation-delay: .16s; }
.page-enter .home-grid > .stack > :nth-child(n+3) { animation-delay: .2s; }
.page-enter .home-grid { animation: none; }
/* la Vânzare și Retur, pagina apare pe loc (bara de plată e fixă și nu trebuie să sară) */
body[data-page="vanzare"] .page-enter *, body[data-page="retur"] .page-enter * { animation: none !important; }
.fold > .fold-body { animation: none; }
.fold[open] > .fold-body { animation: rise-in .22s ease both; }

@media (prefers-reduced-motion: reduce) {
  .puls-dot, .page-enter *, .page-enter > *, .fold[open] > .fold-body { animation: none !important; }
  .tile, .card, .nav a, .bottom-nav a svg, .seg button { transition: none; }
  .tile:hover { transform: none; }
}
@media (max-width: 640px) {
  .home-hello h2 { font-size: 26px; }
  .tile { min-height: 96px; }
  .fold-ic { width: 28px; height: 28px; border-radius: 9px; }
  .fold-ic svg { width: 16px !important; height: 16px !important; }
  .fold-t b { font-size: 16px; }
  .fold > summary { gap: 8px; padding: 12px 12px 12px 14px; }
}

/* ---------- Aspect pentru calculator (1.54): meniu fix și îngustabil, pagini pe coloane ---------- */
.side-mini-btn { display: none; }
@media (min-width: 901px) {
  .shell { transition: grid-template-columns .22s ease; }
  .side { overflow-x: hidden; overflow-y: auto; scrollbar-width: thin; scrollbar-color: color-mix(in srgb, var(--muted) 35%, transparent) transparent; display: flex; flex-direction: column; }
  .side::-webkit-scrollbar { width: 6px; } .side::-webkit-scrollbar-thumb { background: color-mix(in srgb, var(--muted) 35%, transparent); border-radius: 6px; }
  .brand { position: sticky; top: -18px; z-index: 2; margin: -18px -12px 0; padding: 18px 22px 14px; background: var(--surface); }
  /* „Strânge meniul”: rând separat sub meniu, ca numele firmei de sus să aibă toată lățimea */
  .side-mini-btn { position: sticky; bottom: -24px; z-index: 2; box-shadow: 0 -10px 12px -6px var(--surface); display: flex; align-items: center; gap: 11px; width: 100%; margin: 10px 0 0; padding: 8px 10px; border: 0; border-radius: 10px; background: transparent; color: var(--muted); font: inherit; font-size: 13.5px; font-weight: 500; cursor: pointer; }
  .side-mini-btn { background: var(--surface) !important; }
  .side-mini-btn:hover { color: var(--ink); }
  .side-mini-btn svg { width: 18px; height: 18px; flex: none; transform: rotate(90deg); transition: transform .2s ease; }
  /* numele firmei: întreg; dacă e lung, pe cel mult două rânduri, cu litere puțin mai mici */
  .brand-link { flex: 1; } .brand-link > div { min-width: 0; }
  .brand-name { white-space: normal; overflow-wrap: anywhere; line-height: 1.1; font-size: clamp(16px, 1.5vw, 22px); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .brand-sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
  .nav a { padding: 8px 10px; }
  .nav a > span:first-of-type { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  /* grupurile se strâng și pe calculator (se ține minte); săgeata apare la trecerea cu mouse-ul */
  .nav-sec > summary { cursor: pointer; border-radius: 8px; padding: 2px 0; pointer-events: auto; }
  .nav-sec > summary svg { display: inline-block; width: 14px; height: 14px; margin-left: auto; opacity: 0; transition: transform .18s ease, opacity .15s ease; }
  .nav-sec:not([open]) > summary svg { transform: rotate(-90deg); opacity: .8; }
  .nav-sec > summary:hover svg { opacity: .8; }
  .nav-sec > summary:hover { color: var(--ink); }
  .side-foot { margin-top: auto; }
  /* paginile: lățime bună pe ecrane foarte late */
  .main { max-width: 1680px; }
  /* Acasă: scurtăturile umplu rândul */
  .tiles { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }

  /* meniul îngust: doar iconițe, cu numele la trecerea mouse-ului */
  body.side-mini .shell { grid-template-columns: 76px 1fr; }
  body.side-mini .side { padding-left: 10px; padding-right: 10px; }
  body.side-mini .brand { flex-direction: column; gap: 8px; padding: 18px 0 12px; margin: -18px -10px 0; align-items: center; }
  body.side-mini .brand-link > div, body.side-mini .side-search span, body.side-mini .side-search kbd, body.side-mini .nav a > span, body.side-mini .nav-group > span, body.side-mini .side-foot, body.side-mini .nav-fav { display: none; }
  body.side-mini .side-mini-btn { justify-content: center; padding: 10px 0; }
  body.side-mini .side-mini-btn span { display: none; }
  body.side-mini .side-mini-btn svg { transform: rotate(-90deg); }
  body.side-mini .side-search { width: 100%; margin: 4px 0 8px; justify-content: center; padding: 9px 0; }
  body.side-mini .console-btn { font-size: 0; gap: 0; padding: 0; min-height: 40px; }
  body.side-mini .console-btn svg { width: 18px; height: 18px; }
  body.side-mini .nav-group { margin: 10px 8px 6px; height: 1px; background: var(--line); }
  body.side-mini .nav-sec > summary { pointer-events: none; }
  body.side-mini .nav-sec > summary svg { display: none; }
  body.side-mini .nav a { justify-content: center; padding: 10px 0; }
  body.side-mini .nav a.active::before { left: -10px; }
  body.side-mini .nav .badge { position: absolute; top: 4px; right: 4px; }
}
@media (min-width: 1400px) {
  /* Acasă pe ecran lat: coloana cu vânzările zilei puțin mai lată */
  .home-grid.g2 { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) { .shell, .nav-sec > summary svg { transition: none; } }

/* Consola: lista backupurilor (1.55) */
.bk-h { font-size: 15px; margin: 14px 0 4px; }

/* Setări → Locații: locația dezactivată (1.57) */
.loc-off .main-txt b { color: var(--muted); }
/* Setări → Magazine și locații (Etapa 9) */
.shop-blk + .shop-blk { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.shop-head { display: flex; align-items: center; gap: 10px; margin-bottom: 2px; }
.shop-head .main-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.shop-head .main-txt span { font-size: 13px; color: var(--muted); }
.shop-ic { flex: none; width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: var(--cobalt-soft); color: var(--cobalt); }
.shop-ic svg { width: 16px; height: 16px; }
.loc-btns { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }

/* ---------- cine încasează bonul (M1, 1.62) ---------- */
.who-pick { margin-bottom: 14px; padding: 10px; border-radius: var(--r-m); background: var(--surface-2); }
.who-pick.need { box-shadow: inset 0 0 0 2px var(--bad); }
.who-pick .k-label { margin-bottom: 8px; }
.who-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
.who-list button { display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 8px 12px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-weight: 650; text-align: left; cursor: pointer; }
.who-list button.on { border-color: var(--cobalt); background: var(--cobalt-soft); color: var(--ink); }
.who-list .who-shared { grid-column: 1 / -1; border-style: dashed; color: var(--muted); }
.who-list .who-shared svg { width: 18px; height: 18px; flex: none; }
.who-list .who-shared.on { color: var(--ink); border-style: solid; }

/* ---------- dispozitivele magazinului (M7, 1.65) ---------- */
.dev-modes { display: flex; flex-direction: column; gap: 6px; }
.dev-modes.off { opacity: .55; }
.dev-mode { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; background: var(--surface); }
.dev-mode input { margin-top: 3px; accent-color: var(--cobalt); }
.dev-mode span { display: flex; flex-direction: column; gap: 2px; }
.dev-mode:has(input:checked) { border-color: var(--cobalt); background: var(--cobalt-soft); }

/* ---------- factura la recepție (M4, 1.67) ---------- */
.inv-btns { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.count-zones { display: flex; flex-direction: column; gap: 6px; margin-bottom: 10px; }
.count-zones .chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 0; overflow: visible; }
.count-zones .chip .num { margin-left: 4px; opacity: .75; }
.count-zones .chip.add { border-style: dashed; color: var(--cobalt); }
.count-zones .chip.add svg { width: 14px; height: 14px; vertical-align: -2px; }
.count-people .list li { gap: 10px; align-items: center; }
.dot-live { width: 9px; height: 9px; border-radius: 50%; background: var(--cobalt); flex: none; }
.dot-live.me { background: var(--puls); box-shadow: 0 0 0 2px var(--puls-soft, transparent); }
.count-diffs { max-height: 46vh; overflow: auto; }
.count-diffs li { gap: 10px; align-items: center; }
.sord-lines { display: flex; flex-direction: column; gap: 6px; }
.sord-line { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; }
.sord-line input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--cobalt); flex: none; }
.sord-line .main-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.sord-line input[type=number] { width: 84px; flex: none; text-align: right; }
.sord-text { white-space: pre-wrap; font-family: var(--mono); font-size: 12.5px; background: var(--surface-2); padding: 10px 12px; border-radius: 12px; max-height: 34vh; overflow: auto; margin: 0 0 12px; }
.sord { margin-bottom: 10px; }
.sord-acts { margin-top: 10px; flex-wrap: wrap; gap: 8px; }
.scan-ready { display: none; align-items: center; gap: 6px; margin-top: 8px; font-size: 12.5px; font-weight: 600; color: var(--ok-ink); }
.scan-ready svg { width: 15px; height: 15px; }
body.scan-hw .scan-ready { display: flex; }
/* doar scaner: butoanele de cameră pentru produse dispar (poza facturii rămâne) */
body.scan-hw-only .scan-bar [data-scan], body.scan-hw-only [data-bigscan], body.scan-hw-only [data-bigscan2], body.scan-hw-only .fab-scan { display: none !important; }
.scan-test { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 22px 12px; border: 2px dashed var(--line); border-radius: 14px; }
.scan-test svg { width: 34px; height: 34px; color: var(--cobalt); }
.scan-test.ok { border-style: solid; border-color: var(--ok); }
.scan-test.ok svg { color: var(--ok-ink); }
.push-card { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 12px; border-color: var(--cobalt-soft); background: color-mix(in srgb, var(--cobalt-soft) 45%, var(--surface)); }
.push-card .main-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.inv-check { display: flex; gap: 8px; align-items: flex-start; margin-top: 8px; padding: 8px 12px; border-radius: 12px; background: var(--surface-2); font-size: 13.5px; }
.inv-check svg { width: 17px; height: 17px; flex: none; margin-top: 1px; color: var(--muted); }
.inv-check.ok { background: color-mix(in srgb, var(--ok) 12%, var(--surface)); } .inv-check.ok svg { color: var(--ok-ink); }
.inv-check.warn { background: color-mix(in srgb, var(--warn) 14%, var(--surface)); } .inv-check.warn svg { color: var(--warn-ink); }
.inv-nr { font-family: var(--mono); font-weight: 500; color: var(--muted); }
.inv-totals { margin-top: 12px; padding: 12px; border-radius: 14px; background: var(--surface-2); }
.inv-tt { display: block; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.rec-totals { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px 14px; margin-top: 12px; }
.inv-totals .rec-totals { margin-top: 0; }
.rec-totals > div { display: flex; flex-direction: column; min-width: 0; }
.rec-totals span { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.rec-totals b { font-size: 16px; }
.rec-totals .tot b { font-size: 18px; color: var(--ink); }
.rec-totals small { font-size: 11.5px; }
.ok-txt { color: var(--ok-ink); } .bad-txt { color: var(--bad-ink); }
.inv-pages { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.inv-page { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--surface); font-size: 12.5px; font-weight: 600; }
.inv-page img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 8px; background: var(--surface-2); }
.inv-page .icon-btn { position: absolute; top: 2px; right: 2px; background: var(--surface); }
.inv-page.add { justify-content: center; min-height: 150px; border-style: dashed; color: var(--cobalt); cursor: pointer; font: inherit; font-weight: 600; }
.inv-page.add svg { width: 26px; height: 26px; }
.inv-head { display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); }
.inv-rows { display: flex; flex-direction: column; gap: 8px; }
.inv-row { display: flex; gap: 10px; align-items: flex-start; padding: 10px; border: 1.5px solid var(--line); border-radius: 12px; }
.inv-row.on { border-color: var(--cobalt); background: var(--cobalt-soft); }
.inv-ok input { width: 22px; height: 22px; margin-top: 2px; accent-color: var(--cobalt); }
.inv-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.inv-l { display: flex; flex-direction: column; }
.inv-m { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.inv-m select, .inv-m > input { width: 100%; }
.inv-new { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); gap: 6px; width: 100%; }
@media (max-width: 640px) { .inv-new { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .inv-new input:first-child { grid-column: 1 / -1; } }

/* ---------- Consola ritm (C1, v1.68; cadrul din 1.75): meniu în stânga pe calculator, bară jos și „Meniu” pe telefon ---------- */
.cshell { min-height: 100vh; min-height: 100dvh; background: var(--paper); }
.c-main { width: 100%; max-width: 1120px; margin: 0 auto; padding: 16px 16px 72px; }
.c-head { display: flex; align-items: flex-end; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.c-head > div:first-child { flex: 1; min-width: 0; }
.c-head h1 { margin: 0; font-family: var(--display); font-size: 23px; letter-spacing: -.01em; }
@media (min-width: 640px) { .c-head h1 { font-size: 27px; } }
.c-head-act { display: flex; gap: 8px; flex-wrap: wrap; }
.c-kpis { margin-bottom: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
.c-kpis .kpi .k-val { font-size: 24px; }
.c-cols { align-items: start; }
.c-cols h3, .c-sec h3 { margin: 0 0 10px; font-family: var(--display); font-size: 17px; }
.c-feed li { padding: 9px 0; }
.c-bar { display: flex; height: 12px; border-radius: 99px; overflow: hidden; background: var(--surface-2); }
.c-bar span { display: block; height: 100%; }
.c-bar-start { background: color-mix(in srgb, var(--cobalt) 35%, var(--surface)); }
.c-bar-echipa { background: color-mix(in srgb, var(--cobalt) 70%, var(--surface)); }
.c-bar-business { background: var(--cobalt); }
.c-bar-intern { background: var(--puls); }
.c-legend { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 10px; font-size: 13px; color: var(--muted); }
.c-legend span { display: inline-flex; align-items: center; gap: 6px; }
.c-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; }
.c-legend b { color: var(--ink); }
.c-filters { display: flex; flex-direction: column; gap: 10px; margin-bottom: 12px; }
.c-search { position: relative; display: block; }
.c-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); pointer-events: none; }
.c-search .input { padding-left: 40px; width: 100%; }
.c-filter-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.c-filter-row .input { width: 100%; }
.c-filter-row .input:last-child:nth-child(odd) { grid-column: 1 / -1; }
.c-table-card { padding: 4px 14px; }
.c-desk { display: none; }
.c-mob li { padding: 12px 0; }
.c-mob .c-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 4px; font-size: 13px; color: var(--muted); }
.c-pager { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 10px; }
.c-pager > span:first-child { margin-right: auto; }
.c-actions { display: flex; flex-direction: column; gap: 8px; }
.c-actions .btn { justify-content: flex-start; }
.btn.icon-only { padding-left: 8px; padding-right: 8px; }
@media (min-width: 640px) {
  .c-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
  .c-filters { flex-direction: row; align-items: center; flex-wrap: wrap; }
  .c-search { flex: 1 1 280px; }
  .c-filter-row { display: flex; flex-wrap: wrap; }
  .c-filter-row .input { width: auto; }
}
@media (min-width: 900px) {
  .c-main { padding: 26px 28px 60px; }
  .c-desk { display: block; }
  .c-mob { display: none; }
  .c-tbl td { vertical-align: middle; }
}

/* sănătatea firmelor (Consola C2) */
.hdot { display: inline-block; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--line); vertical-align: middle; }
.hdot.h-verde { background: var(--ok); }
.hdot.h-galben { background: var(--warn); }
.hdot.h-rosu { background: var(--bad); box-shadow: 0 0 0 3px var(--bad-soft); }
.hdot.h-nou { background: transparent; border: 2px solid var(--line); }
.hdot.h-off { background: transparent; }
.c-why { margin-top: 3px; }
.c-why.h-rosu { color: var(--bad-ink); }
.c-why.h-galben { color: var(--warn-ink); }
.c-health { margin-bottom: 14px; }
.c-hrow { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.c-hpill { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); color: var(--ink); text-decoration: none; font-size: 14px; }
.c-hpill b { margin-left: auto; font-size: 17px; }
.c-hpill:hover { background: var(--ritm-soft); }
.c-alerts { margin-top: 8px; }
.c-alerts li { padding: 10px 0; }
.c-alerts .main-txt span { display: block; }
.c-hline { display: flex; gap: 8px; align-items: baseline; padding: 10px 12px; margin-bottom: 12px; border-radius: 12px; background: var(--surface-2); font-size: 14px; }
.c-mob li { align-items: flex-start; }
.c-mob li > .hdot { margin-top: 6px; }
@media (min-width: 640px) { .c-hrow { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.c-audit li { align-items: flex-start; }
.c-audit .main-txt b a { color: inherit; text-decoration: none; }
.c-audit .main-txt b a:hover { color: var(--ritm); }
.c-det { margin-top: 3px; word-break: break-word; }

/* fișa firmei (Consola C3) */
.c-back { display: inline-flex; align-items: center; gap: 4px; margin-bottom: 6px; color: var(--muted); text-decoration: none; font-weight: 600; font-size: 14px; }
.c-back svg { width: 16px; height: 16px; }
.c-head h1 .hdot { width: 12px; height: 12px; vertical-align: 4px; }
.c-acts { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.c-card-grid { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); align-items: start; }
.c-card-grid > .card { margin: 0; }
.c-sec-h { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.c-sec-h h3 { flex: 1; display: flex; align-items: center; gap: 8px; margin: 0 !important; }
.c-sec-h h3 svg { width: 18px; height: 18px; color: var(--ritm); }
.c-card-grid .stat-row b { text-align: right; font-weight: 600; }
.c-note-add { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; margin-bottom: 6px; }
.c-note-add textarea { width: 100%; }
.c-note-body { white-space: pre-wrap; color: var(--ink); font-size: 14.5px; }
.c-notes li { align-items: flex-start; }
.c-tlink { color: inherit; text-decoration: none; }
.c-tlink:hover b { color: var(--ritm); }
.c-warn-t { display: inline !important; color: var(--warn-ink); font-weight: 600; }
@media (min-width: 1000px) {
  .c-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .c-card-notes, .c-card-audit { grid-row: span 2; }
}

/* suport (Consola C6 + aplicație) */
.c-tk li { align-items: flex-start; }
.c-tk-r { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.c-thread, .sup-thread { display: flex; flex-direction: column; gap: 10px; margin-bottom: 12px; }
.c-msg, .sup-msg { max-width: 640px; padding: 12px 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); }
.c-msg.me, .sup-msg.ritm { align-self: flex-end; background: var(--ritm-soft); border-color: transparent; }
.c-msg-h { display: flex; gap: 10px; justify-content: space-between; margin-bottom: 4px; font-size: 13.5px; }
.c-msg-b, .sup-msg-b { white-space: pre-wrap; word-break: break-word; font-size: 15px; }
.c-reply textarea { width: 100%; }
.c-sup-n { margin: 0 0 12px; text-decoration: none; align-items: center; }
.c-sup-n svg { width: 18px; height: 18px; flex: none; }
.sup-new textarea, .sup-new input { width: 100%; }
.c-more-err { margin-top: 10px; }
.c-more-err summary { cursor: pointer; color: var(--muted); }

/* ---------- cadrul Consolei (1.75): aspect „de panou”, tehnic, separat de aplicația magazinelor ---------- */
.cshell { --c-band: #0B1428; --c-band-2: #111D38; --c-line: color-mix(in srgb, #F5F7FB 12%, transparent); --c-fg: #EEF2FA; --c-fg-2: color-mix(in srgb, #EEF2FA 66%, transparent); --c-nav-h: 60px; }
.c-mono { font-family: var(--mono); letter-spacing: .02em; }
/* grilă discretă: semnul vizual că ești în panoul de administrare */
.c-grid-bg { background-color: var(--c-band); background-image: linear-gradient(var(--c-line) 1px, transparent 1px), linear-gradient(90deg, var(--c-line) 1px, transparent 1px); background-size: 22px 22px; background-position: -1px -1px; }
.c-live { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--puls); box-shadow: 0 0 0 3px color-mix(in srgb, var(--puls) 25%, transparent); flex: none; }
.c-count { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--bad); color: #fff; font: 700 11px/1 var(--mono); font-style: normal; }
.c-count.hidden { display: none; }
.c-count.sev-atentie { background: var(--warn); color: #1d1300; }
.c-count.sev-info { background: var(--cobalt); }

/* bara de sus (telefon și tabletă) */
.c-top { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 10px; padding: 9px 12px 10px; padding-top: calc(9px + env(safe-area-inset-top, 0px)); color: var(--c-fg); border-bottom: 1px solid var(--c-line); }
.c-top { background-color: var(--c-band); background-image: linear-gradient(var(--c-line) 1px, transparent 1px), linear-gradient(90deg, var(--c-line) 1px, transparent 1px); background-size: 22px 22px; }
.c-top-logo img { display: block; border-radius: 8px; }
.c-top-t { flex: 1; min-width: 0; }
.c-tag { display: flex; align-items: center; gap: 6px; font-size: 10.5px; font-weight: 600; color: var(--c-fg-2); }
.c-title { font-family: var(--display); font-weight: 700; font-size: 18px; line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-top-btn { color: var(--c-fg) !important; border: 1px solid var(--c-line) !important; background: color-mix(in srgb, #fff 6%, transparent) !important; }

/* bara de jos, lipită, ca în aplicație, dar închisă la culoare */
.c-bottom { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: grid; padding-bottom: env(safe-area-inset-bottom, 0px); background: color-mix(in srgb, var(--c-band) 94%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-top: 1px solid var(--c-line); box-shadow: 0 -6px 20px rgba(5, 11, 24, .18); transform: translateZ(0); }
.c-bn { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; height: var(--c-nav-h); color: var(--c-fg-2); text-decoration: none; font-size: 10.5px; font-weight: 600; }
.c-bn svg { width: 21px; height: 21px; transition: transform .18s ease; }
.c-bn.on { color: var(--c-fg); }
.c-bn.on::before { content: ""; position: absolute; top: 0; left: 28%; right: 28%; height: 2px; border-radius: 0 0 2px 2px; background: var(--cobalt); }
.c-bn.on svg { color: #8FA6FF; transform: translateY(-1px); }
.c-bn .c-count { position: absolute; top: 6px; left: calc(50% + 6px); }
.c-bn-search .dot { display: grid; place-items: center; width: 42px; height: 42px; margin-top: -14px; border-radius: 14px; background: var(--cobalt); color: #fff; box-shadow: 0 6px 16px color-mix(in srgb, var(--cobalt) 45%, transparent), inset 0 0 0 1px color-mix(in srgb, #fff 18%, transparent); }
.c-bn-search .dot svg { width: 20px; height: 20px; color: #fff !important; }
body.typing .c-bottom { display: none; }

.c-main { padding-bottom: calc(var(--c-nav-h) + 40px + env(safe-area-inset-bottom, 0px)); }
.c-head h1 { display: none; }
.c-head { margin-bottom: 12px; }
.c-head > div:first-child:empty { display: none; }
@media (max-width: 899px) {
  .c-hide-m { display: none !important; }
  .cshell .kpi .k-label { font-size: 10.5px; white-space: normal; overflow: visible; }
}

/* meniul: pe telefon pe tot ecranul (din „Meniu”), pe calculator în stânga */
.c-side { display: none; flex-direction: column; color: var(--c-fg); }
.c-side { background-color: var(--c-band); background-image: linear-gradient(var(--c-line) 1px, transparent 1px), linear-gradient(90deg, var(--c-line) 1px, transparent 1px); background-size: 22px 22px; }
.c-side.open { display: flex; position: fixed; inset: 0; z-index: 60; padding: calc(14px + env(safe-area-inset-top, 0px)) 14px calc(18px + env(safe-area-inset-bottom, 0px)); overflow-y: auto; }
body.c-menu-open { overflow: hidden; }
.c-side-head { display: flex; align-items: center; gap: 8px; }
.c-side-head .brand { flex: 1; padding: 4px 6px 14px; margin: 0; background: none; position: static; }
.c-side .brand-sub { color: var(--c-fg-2); font-size: 11.5px; margin-top: 0; }
.c-side-x { color: var(--c-fg) !important; }
.c-ngroup { margin: 14px 10px 6px; font: 600 11px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--c-fg-2); }
.c-nav { display: flex; flex-direction: column; gap: 2px; }
.c-link { display: flex; align-items: center; gap: 11px; padding: 12px 12px; border-radius: 10px; color: color-mix(in srgb, var(--c-fg) 82%, transparent); text-decoration: none; font-weight: 600; font-size: 15.5px; border: 1px solid transparent; }
.c-link svg { width: 19px; height: 19px; flex: none; }
.c-link span { flex: 1; }
.c-link:hover { background: color-mix(in srgb, #fff 6%, transparent); color: var(--c-fg); }
.c-link.on { background: color-mix(in srgb, var(--cobalt) 22%, transparent); border-color: color-mix(in srgb, var(--cobalt) 55%, transparent); color: #fff; }
.c-link.on svg { color: #8FA6FF; }
.c-side-foot { margin-top: auto; padding-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.c-who-card { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; background: color-mix(in srgb, #fff 5%, transparent); border: 1px solid var(--c-line); }
.c-avatar { display: grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: 10px; background: var(--cobalt); color: #fff; font: 700 15px/1 var(--mono); }
.c-who { color: var(--c-fg); font-weight: 600; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-role { color: var(--c-fg-2); font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; }
.c-side-btns { display: flex; flex-wrap: wrap; gap: 4px; }
.c-side-btns .btn.ghost { color: var(--c-fg); }
.c-status { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 11px; color: var(--c-fg-2); padding: 0 4px; }
.c-env { display: inline-flex; align-items: center; gap: 6px; }
.c-status .c-bad { color: #FF8A8E; }

/* pagina: titlurile secțiunilor un pic mai „tehnice” */
.cshell .card h3, .c-sec-h h3 { letter-spacing: -.005em; }
.cshell .kpi .k-label { font-family: var(--mono); font-size: 11.5px; letter-spacing: .03em; text-transform: uppercase; }

@media (min-width: 900px) {
  .cshell { display: grid; grid-template-columns: 248px minmax(0, 1fr); }
  .c-top, .c-bottom, .c-side-x { display: none !important; }
  .c-side { display: flex; position: sticky; top: 0; height: 100vh; height: 100dvh; padding: 16px 10px; overflow-y: auto; }
  .c-link { padding: 10px 12px; font-size: 14.5px; }
  .c-main { padding: 26px 28px 60px; }
  .c-head h1 { display: block; }
}

/* abonamentul firmei (Etapa 6): anunțul de sus */
.bill-bar { display: flex; align-items: center; gap: 10px; padding: 9px 14px; font-size: 13.5px; position: relative; z-index: 35; }
.bill-bar.hidden { display: none; }
.bill-bar svg { width: 18px; height: 18px; flex: none; }
.bill-bar span { flex: 1; }
.bill-bar.warn { background: var(--warn-soft); color: var(--warn-ink); }
.bill-bar.bad { background: var(--bad-soft); color: var(--bad-ink); }
.bill-bar .btn { flex: none; }
.c-seg-wrap { flex-wrap: wrap; }
.c-inl { display: inline !important; color: var(--ink); }
.c-plan-ed { padding: 10px 0; border-bottom: 1px dashed var(--line); }
.c-plan-ed:last-of-type { border-bottom: 0; }
.c-plan-ed .form-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 6px; }

/* înscrierea singur (Etapa 4) */
.hp-field { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }
.gate-sep { display: flex; align-items: center; gap: 10px; margin: 16px 0 10px; color: var(--muted); font-size: 13px; }
.gate-sep::before, .gate-sep::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.login-form .dev-mode { margin-top: 6px; }
/* ghidul de pornire */
.onb { position: fixed; inset: 0; z-index: 80; display: flex; flex-direction: column; background: var(--paper); overflow-y: auto; padding: calc(16px + env(safe-area-inset-top, 0px)) 16px calc(24px + env(safe-area-inset-bottom, 0px)); }
.onb-in { width: 100%; max-width: 560px; margin: 0 auto; }
.onb-steps { display: flex; gap: 6px; margin: 4px 0 18px; }
.onb-steps i { flex: 1; height: 4px; border-radius: 4px; background: var(--line); }
.onb-steps i.on { background: var(--ritm); }
.onb h1 { font-family: var(--display); font-size: 26px; margin: 0 0 6px; }
.onb .onb-k { font: 600 11.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.onb-choice { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px; margin-top: 10px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--ink); text-align: left; font: inherit; cursor: pointer; }
.onb-choice:hover { border-color: var(--ritm); }
.onb-choice .help-ic { flex: none; }
.onb-choice b { display: block; }
.onb-choice small { color: var(--muted); }
.onb-foot { display: flex; gap: 8px; justify-content: space-between; margin-top: 18px; }
.onb-team-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; margin-top: 8px; }
@media (max-width: 560px) { .onb-team-row { grid-template-columns: 1fr; padding-bottom: 8px; border-bottom: 1px dashed var(--line); } }

/* sigla firmei (Etapa 3) */
img.brand-mark.own, .topbar-logo img.own { object-fit: contain; background: #fff; border-radius: 8px; border: 1px solid var(--line); }
.logo-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.logo-prev { width: 64px; height: 64px; object-fit: contain; border-radius: 14px; background: #fff; border: 1px solid var(--line); padding: 4px; }
.logo-peek { width: 22px; height: 22px; object-fit: contain; border-radius: 6px; background: #fff; vertical-align: middle; }

/* ---------- vânzări salvate pe telefon: listă, copie, iPhone (v1.82) ---------- */
.net-bar .nb-more { margin-left: auto; flex: none; font-weight: 650; text-decoration: underline; text-underline-offset: 3px; }
.pq-sum { display: flex; justify-content: space-between; align-items: baseline; padding: 10px 12px; margin: 8px 0 10px; border-radius: 10px; background: var(--ritm-soft); color: var(--ritm-deep); font-size: 15px; }
.warn-txt { color: var(--warn-ink); display: flex; gap: 6px; align-items: flex-start; }
.warn-txt svg { width: 16px; height: 16px; flex: none; margin-top: 2px; }
.ios-tip { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; margin: 0 0 10px; border-radius: 12px; background: var(--ritm-soft); color: var(--ritm-deep); font-size: 13.5px; line-height: 1.4; }
.ios-tip > svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.ios-tip > span { flex: 1; }
.ios-tip .btn { flex: none; margin: -4px -6px 0 0; color: inherit; }

/* ---------- Consolă: firmele favorite (v1.83) ---------- */
.c-star { flex: none; display: inline-grid; place-items: center; width: 32px; height: 32px; margin: -4px 2px -4px -6px; border: 0; border-radius: 8px; background: transparent; color: var(--muted); cursor: pointer; }
.c-star svg { width: 18px; height: 18px; }
.c-star:hover { color: var(--warn-ink); background: var(--warn-soft); }
.c-star.on { color: var(--warn); }
.c-star.on svg { fill: currentColor; }
.c-namerow { display: flex; align-items: center; gap: 2px; }
.c-favs { margin: 0 0 12px; }
.c-favs-h { display: flex; align-items: center; gap: 8px; margin: 0 2px 8px; }
.c-favs-h svg { width: 16px; height: 16px; color: var(--warn); fill: currentColor; }
.c-favs-h .muted { margin-left: auto; }
.c-fav-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.c-fav { display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); cursor: pointer; }
.c-fav:hover { border-color: var(--ritm); }
.c-fav-t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.c-fav-t b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-fav .c-star { margin: 0 -4px 0 0; }
@media (max-width: 700px) { .c-favs-h .muted { display: none; } .c-fav-row { grid-template-columns: 1fr; } }

/* ---------- magazinul demo (v1.85) ---------- */
.demo-bar { position: sticky; top: 0; z-index: 69; display: flex; align-items: center; gap: 10px; padding: 8px 14px; padding-top: calc(8px + env(safe-area-inset-top, 0px)); background: var(--band); color: var(--band-fg); font-size: 13.5px; }
.demo-bar > svg { width: 18px; height: 18px; color: var(--puls); flex: none; }
.demo-bar > span { flex: 1; min-width: 0; }
.demo-bar .btn { flex: none; }
.demo-bar .btn:not(.primary) { background: transparent; color: var(--band-fg); border-color: rgba(255,255,255,.28); }
@media (max-width: 700px) { .demo-bar .demo-sub { display: none; } }
.demo-tour li { align-items: center; }
.demo-tour .main-txt b { display: flex; align-items: center; gap: 6px; }
.demo-tour .main-txt b svg { width: 16px; height: 16px; color: var(--ritm); }
.demo-n { flex: none; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--band); color: var(--band-fg); font: 600 12.5px var(--mono); }
.demo-tour li > svg:last-child { width: 18px; height: 18px; color: var(--muted); transform: rotate(-90deg); flex: none; }

/* Consolă: luni gratuite */
.c-free-opts { display: flex; gap: 6px; flex-wrap: wrap; }

/* ---------- Consolă: Planuri și funcții (v1.87) ---------- */
.c-plans { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin-bottom: 12px; }
.c-plan { display: flex; flex-direction: column; padding: 16px; }
.c-plan.rec { border-color: var(--ritm); box-shadow: 0 0 0 1px var(--ritm); }
.c-plan-h { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 17px; }
.c-plan-p { font: 700 22px var(--mono); margin: 6px 0 2px; }
.c-plan-p small { font: 500 12px var(--body); }
.c-plan-hl { margin: 8px 0 0; padding-left: 18px; color: var(--muted); }
.c-fmx th.c, .c-fmx td.c { text-align: center; width: 92px; }
.c-fmx .rec { background: color-mix(in srgb, var(--ritm) 7%, transparent); }
.c-fmx thead th { position: sticky; top: 0; background: var(--surface); z-index: 1; }
.c-fg td { background: var(--surface-2); }
.c-fg-row { display: flex; align-items: center; gap: 8px; }
.c-fg-row .muted { margin-right: auto; }
.c-fname { border: 0; background: none; padding: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.c-fname:hover { color: var(--ritm); text-decoration: underline; }
.c-chk { width: 20px; height: 20px; accent-color: var(--ritm); cursor: pointer; }
.c-chk:disabled { cursor: default; }
.c-fplans { display: flex; flex-wrap: wrap; gap: 6px 16px; }

/* funcție care nu e în pachetul firmei (1.88, featureCard în public/core.js) */
.feat-card { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; max-width: 640px; }
.feat-card .feat-ic { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--cobalt-soft); color: var(--cobalt); }
.feat-card .feat-ic svg { width: 20px; height: 20px; }
.feat-card .feat-txt { flex: 1 1 220px; min-width: 0; }
.feat-card .feat-txt p { margin: 4px 0 0; }
.feat-card.compact { max-width: none; padding: 12px 14px; margin: 10px 0; }
@media (max-width: 600px) { .feat-card .btn { width: 100%; justify-content: center; } }
.c-tplan { font-weight: 600; }
/* Consolă → Suport: cererea de alt pachet (1.89) */
.c-planreq { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; border-color: var(--cobalt); background: var(--cobalt-soft); }

/* Setări → Abonament: pachetele, cu „Vreau pachetul X” (1.89) */
.plan-pick { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; }
.plan-opt { display: flex; flex-direction: column; gap: 4px; padding: 12px; border: 1px solid var(--line, #dfe5f0); border-radius: 14px; background: var(--surface); }
.plan-opt.cur { border-color: var(--cobalt); background: var(--cobalt-soft); }
.plan-opt-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.plan-opt .btn, .plan-opt .badge { align-self: flex-start; margin-top: 6px; }

/* ---------- magazinul ales (Etapa 9): selectorul de sus, doar la firmele cu cel puțin 2 magazine ---------- */
.shop-pick { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; max-width: 100%; padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--cobalt-soft); color: var(--cobalt-deep); font: 600 13px/1.2 var(--body); cursor: pointer; }
.shop-pick > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.shop-pick svg { width: 16px; height: 16px; flex: none; }
.shop-pick .sp-chev { display: inline-flex; opacity: .7; }
.shop-pick .sp-chev svg { width: 14px; height: 14px; }
.shop-pick.side-shop { display: flex; width: 100%; margin: 0 0 10px; border-radius: var(--r-m, 10px); justify-content: flex-start; }
.shop-pick.side-shop > span { flex: 1; text-align: left; }
.shop-pick.top-shop { flex: 0 1 auto; max-width: 34vw; margin-right: 2px; padding: 4px 8px; font-size: 12px; gap: 4px; }
.shop-pick.top-shop .sp-chev { display: none; }
.shop-list li.on { background: var(--cobalt-soft); }
.shop-list li svg { flex: none; color: var(--cobalt); }
.shop-shared { display: flex; gap: 8px; align-items: flex-start; background: var(--cobalt-soft); border-color: transparent; margin: 0 0 12px; }
.shop-shared svg { flex: none; color: var(--cobalt); width: 18px; height: 18px; margin-top: 1px; }

/* Etapa 9, pasul 3: comparația între magazine, modul de bonus, partea din ce e comun în profit */
.shc-card h3 { margin: 0 0 8px; }
.shc-bars { display: flex; flex-direction: column; gap: 10px; }
.shc-row { display: grid; grid-template-columns: minmax(0, 38%) minmax(0, 1fr) auto; align-items: center; gap: 10px; min-height: 32px; }
.shc-name { min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shc-name small { display: block; font-weight: 400; color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; }
.shc-track { height: 10px; background: var(--cobalt-soft); border-radius: 6px; overflow: hidden; }
.shc-track > i { display: block; height: 100%; border-radius: 6px; background: var(--cobalt); opacity: .55; }
.shc-track > i.top { opacity: 1; }
.shc-track > i.neg { background: var(--bad); opacity: .85; }
.shc-row > b { font-size: 13px; min-width: 76px; text-align: right; }
.shc-ins { margin-bottom: 10px; border-left: 3px solid var(--cobalt); }
.shc-ins h3 { margin: 0 0 4px; }
.shc-ins ul { margin: 0; padding-left: 18px; } .shc-ins li { margin: 3px 0; }
.shc-grid { align-items: start; margin-bottom: 10px; }
.shop-bonus { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.shop-bonus p { margin: 0; }
.shop-parts { margin: 6px 0 4px; padding-left: 18px; }
.shop-parts li { margin: 2px 0; }
@media (max-width: 420px) { .shc-row { grid-template-columns: minmax(0, 1fr) auto; } .shc-track { grid-column: 1 / -1; grid-row: 2; } }
/* Setări → Magazine: pe telefon, butoanele unei locații trec sub nume (nu mai strivesc numele) */
.shop-blk .list li { flex-wrap: wrap; }
.shop-blk .list li .main-txt { min-width: 120px; flex: 1 1 120px; }
@media (max-width: 520px) { .shop-blk .list li .loc-btns { flex: 1 1 100%; } }

/* Etapa 9, pasul 4: prețurile pe magazin în fișa produsului */
.sp-box { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line); }
.sp-box .form-grid { margin-top: 6px; }

/* 1.94: suportul cu poze și butonul de pe Acasă */
.sup-kind { margin-top: 2px; }
.sup-kind button svg { width: 16px; height: 16px; vertical-align: -3px; }
.sup-photos { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; }
.sup-photos .btn svg { width: 16px; height: 16px; }
.sup-thumbs { display: flex; flex-wrap: wrap; gap: 8px; width: 100%; }
.sup-thumbs:empty { display: none; }
.sup-msg .sup-thumbs, .c-msg .sup-thumbs { margin-top: 8px; }
.sup-thumb { position: relative; width: 76px; height: 76px; border-radius: 10px; overflow: hidden; background: var(--cobalt-soft); border: 1px solid var(--line); }
.sup-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; cursor: zoom-in; }
.sup-x { position: absolute; top: 3px; right: 3px; width: 26px; height: 26px; border-radius: 50%; border: 0; background: rgba(13,24,48,.72); color: #fff; font-size: 16px; line-height: 1; cursor: pointer; }
.sup-big { display: block; max-width: 100%; max-height: 75vh; margin: 0 auto; border-radius: 10px; }
.sup-cta { display: flex; align-items: center; gap: 12px; margin: 0 0 12px; text-decoration: none; color: inherit; min-height: 56px; }
.sup-cta .main-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.sup-cta .main-txt span { font-size: 13px; color: var(--muted); }
.sup-cta-ic { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--cobalt-soft); color: var(--cobalt); flex: none; }
.sup-cta-ic svg { width: 20px; height: 20px; }
.sup-cta.new { border-color: var(--cobalt); }
.sup-cta.new .sup-cta-ic { background: var(--cobalt); color: #fff; }
/* butonul de suport din meniu (1.94): sub căutare, mereu la vedere */
.side-sup { display: flex; align-items: center; gap: 8px; width: calc(100% - 20px); margin: 0 10px 8px; padding: 9px 10px; border-radius: 10px; background: var(--cobalt-soft); color: var(--cobalt); font-weight: 600; font-size: 14px; text-decoration: none; min-height: 40px; }
.side-sup svg { width: 18px; height: 18px; flex: none; }
.side-sup:hover { background: var(--cobalt); color: #fff; }
body.side-mini .side-sup { width: 100%; margin: 0 0 8px; justify-content: center; padding: 9px 0; }
body.side-mini .side-sup span { display: none; }

/* Consola → Costuri (1.95) */
.cost-list li { align-items: center; }
.cost-list .main-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.cost-bar { height: 6px; border-radius: 4px; background: var(--cobalt-soft); overflow: hidden; margin-top: 4px; max-width: 360px; }
.cost-bar > i { display: block; height: 100%; background: var(--cobalt); border-radius: 4px; }
.cost-bar.warn > i { background: var(--warn); }
.cost-bar.over > i { background: var(--bad); }
.cost-pay { color: var(--warn-ink); }
.cost-ask { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; margin-bottom: 12px; }
.cost-ask .field { flex: 1 1 180px; margin: 0; }
.cost-ask p { flex-basis: 100%; }
.cost-t tr.cost-cur td { background: var(--cobalt-soft); }
.cost-t tr.cost-want td { box-shadow: inset 0 -2px 0 var(--cobalt); }
.cost-good { color: var(--ok-ink); font-weight: 600; }
.cost-bad { color: var(--bad-ink); font-weight: 600; }
.cost-pt input { width: 110px; text-align: right; }
.c-note { margin-top: 12px; }

/* Notificări (1.96): bulina după gravitate, subtilă */
.notif-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--cobalt); flex: none; }
.notif-dot.sev-atentie { background: var(--warn); }
.notif-dot.sev-urgent { background: var(--bad); box-shadow: 0 0 0 3px var(--bad-soft); }
.notif-dot.off { background: transparent; box-shadow: inset 0 0 0 1.5px var(--line); }
.notif-dot[hidden] { display: none; }
.bn-menu { position: relative; }
.bn-menu .notif-dot { position: absolute; top: 6px; left: calc(50% + 7px); width: 8px; height: 8px; border: 2px solid var(--surface); box-sizing: content-box; }
.side-notif { display: flex; align-items: center; gap: 8px; width: calc(100% - 20px); margin: 0 10px 8px; padding: 9px 10px; border-radius: 10px; border: 1px solid var(--line); color: inherit; font-size: 14px; font-weight: 600; text-decoration: none; min-height: 40px; }
.side-notif svg { width: 18px; height: 18px; flex: none; color: var(--muted); }
.side-notif span { flex: 1; }
.side-notif .notif-n { font: 600 12px var(--mono); color: var(--muted); }
body.side-mini .side-notif { width: 100%; margin: 0 0 8px; justify-content: center; padding: 9px 0; position: relative; }
body.side-mini .side-notif span, body.side-mini .side-notif .notif-n { display: none; }
body.side-mini .side-notif .notif-dot { position: absolute; top: 6px; right: 10px; }
.nt-head { justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.nt-legend { display: inline-flex; align-items: center; gap: 5px; flex-basis: 100%; }
.nt-legend .notif-dot { width: 7px; height: 7px; margin-left: 6px; }
.nt-cat { margin-bottom: 10px; }
.nt-cat-h { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.nt-cat-h h3 { margin: 0; flex: 1; }
.nt-ic { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; background: var(--cobalt-soft); color: var(--cobalt); }
.nt-ic svg { width: 17px; height: 17px; }
.nt-list li { align-items: flex-start; gap: 10px; min-height: 52px; }
.nt-list li .notif-dot { margin-top: 6px; }
.nt-list li > svg:last-child { transform: rotate(-90deg); width: 18px; height: 18px; flex: none; margin-top: 3px; color: var(--muted); }
.nt-list .main-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.nt-list .main-txt span { color: var(--muted); font-size: 13.5px; }
.nt-list .main-txt em { font-style: normal; }
.nt-list li.read b { font-weight: 500; color: var(--muted); }
.invite-row .row { gap: 10px; flex-wrap: wrap; align-items: center; }
.invite-acts { display: flex; flex-wrap: wrap; gap: 8px; }
.invite-acts .btn { flex: 1 1 180px; justify-content: center; }
.nt-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 28px 16px; }
.nt-empty svg { width: 28px; height: 28px; color: var(--ok); }
/* Consola → Costuri: consumul real (1.97) */
.cost-real { margin-bottom: 12px; }
.cost-steps { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.cost-steps code { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 12.5px; background: var(--cobalt-soft); padding: 1px 5px; border-radius: 4px; overflow-wrap: anywhere; }
.cost-src { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cost-src .small { flex: 1 1 200px; min-width: 0; }
.cost-tag { display: inline-block; font-family: 'Geist Mono', ui-monospace, monospace; font-size: 10.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; padding: 1px 6px; border-radius: 4px; vertical-align: middle; }
.cost-tag.real { background: var(--cobalt-soft); color: var(--cobalt); }
.cost-tag.est { background: transparent; color: var(--muted); border: 1px solid var(--line); }
