/* ---------------------------------------------------------------------------
   Cobrança — creditor console. One stylesheet, explicit light and dark tokens.
   Status is never colour alone: every .chip carries an icon and a word.
   --------------------------------------------------------------------------- */

:root {
  color-scheme: light;
  --primary: #0e7c86;
  --primary-dark: #0b5c63;
  --primary-soft: #e6f4f4;
  --primary-softer: #f2f9f9;
  --on-primary: #ffffff;
  --on-color: #ffffff;
  --brand: #0e7c86;

  --bg: #f4f7f7;
  --card: #ffffff;
  --card-2: #f8fafa;
  --text: #10262a;
  --text-2: #3f5559;
  --muted: #5b6f72;
  --border: #dbe5e6;
  --border-strong: #c3d2d4;
  --focus: #0b5c63;
  --overlay: rgba(9, 28, 31, .45);

  --red: #b42318;    --red-bg: #fdecea;
  --blue: #1f5fb8;   --blue-bg: #e8f0fc;
  --green: #17763a;  --green-bg: #e5f5eb;
  --purple: #6a3fb0; --purple-bg: #f0eafb;
  --amber: #8a5300;  --amber-bg: #fff3d6;
  --grey: #4f5d60;   --grey-bg: #eef2f2;

  --shadow-sm: 0 1px 2px rgba(16, 38, 42, .06);
  --shadow: 0 1px 2px rgba(16, 38, 42, .05), 0 6px 20px rgba(16, 38, 42, .06);
  --shadow-lg: 0 12px 40px rgba(16, 38, 42, .18);
  --radius: 12px;
  --radius-sm: 8px;
  --side: 248px;
  --side-collapsed: 76px;
  --t: 150ms;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --primary: #3fb3bd; --primary-dark: #7fd0d7; --primary-soft: #133a3e; --primary-softer: #102b2e;
    --on-primary: #04191b; --on-color: #04191b;
    --bg: #0b1719; --card: #132326; --card-2: #172b2e;
    --text: #e7f0f1; --text-2: #b6c8ca; --muted: #93a8ab;
    --border: #25393c; --border-strong: #33494c; --focus: #7fd0d7; --overlay: rgba(0,0,0,.6);
    --red: #ff8f84;    --red-bg: #3d1714;
    --blue: #8db8ff;   --blue-bg: #14264a;
    --green: #6fd394;  --green-bg: #11331f;
    --purple: #c4a6ff; --purple-bg: #2a1c47;
    --amber: #ffc561;  --amber-bg: #3a2a08;
    --grey: #b6c3c5;   --grey-bg: #223336;
    --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 6px 20px rgba(0,0,0,.3);
    --shadow-lg: 0 12px 40px rgba(0,0,0,.6);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --primary: #3fb3bd; --primary-dark: #7fd0d7; --primary-soft: #133a3e; --primary-softer: #102b2e;
  --on-primary: #04191b; --on-color: #04191b;
  --bg: #0b1719; --card: #132326; --card-2: #172b2e;
  --text: #e7f0f1; --text-2: #b6c8ca; --muted: #93a8ab;
  --border: #25393c; --border-strong: #33494c; --focus: #7fd0d7; --overlay: rgba(0,0,0,.6);
  --red: #ff8f84; --red-bg: #3d1714; --blue: #8db8ff; --blue-bg: #14264a;
  --green: #6fd394; --green-bg: #11331f; --purple: #c4a6ff; --purple-bg: #2a1c47;
  --amber: #ffc561; --amber-bg: #3a2a08; --grey: #b6c3c5; --grey-bg: #223336;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.5 var(--font); -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, h4 { margin: 0; line-height: 1.25; font-weight: 650; letter-spacing: -.01em; }
h1 { font-size: 24px; }
h2 { font-size: 18px; }
h3 { font-size: 15px; }
p { margin: 0; }
a { color: var(--primary-dark); }
:root[data-theme="dark"] a { color: var(--primary); }
button, input, select, textarea { font: inherit; color: inherit; }
img, svg { max-width: 100%; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 999; background: var(--card); padding: 10px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }
.noscript { padding: 24px; }
.ic { width: 20px; height: 20px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; vertical-align: middle; }
.ic-sm { width: 16px; height: 16px; }
.ic-lg { width: 28px; height: 28px; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.strong { font-weight: 600; }
.nowrap { white-space: nowrap; }
.break { overflow-wrap: anywhere; }
.right { text-align: right; }
.mt { margin-top: 16px; } .mt-s { margin-top: 8px; } .mt-l { margin-top: 24px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.row-between { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.stack > * + * { margin-top: 12px; }
.stack-l > * + * { margin-top: 20px; }
.grow { flex: 1 1 auto; min-width: 0; }

/* ---------- boot ---------- */
.boot { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 14px; color: var(--muted); }
.boot-logo, .logo-mark {
  width: 44px; height: 44px; border-radius: 12px; background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  position: relative; flex: none;
}
.boot-logo::after, .logo-mark::after {
  content: ""; position: absolute; inset: 12px 11px; border: 3px solid #fff; border-right-color: transparent; border-radius: 50%;
}
.boot-logo { animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .55; } }

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: var(--side) minmax(0, 1fr); min-height: 100vh; transition: grid-template-columns var(--t); }
.shell.collapsed { grid-template-columns: var(--side-collapsed) minmax(0, 1fr); }
.side {
  position: sticky; top: 0; height: 100vh; overflow-y: auto; overflow-x: hidden;
  background: var(--card); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; padding: 14px 12px; gap: 4px; z-index: 30;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 6px 14px; min-height: 52px; }
.brand-name { font-weight: 700; font-size: 17px; letter-spacing: -.02em; white-space: nowrap; }
.brand-sub { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 150px; }
.logo-mark { width: 36px; height: 36px; border-radius: 10px; }
.logo-mark::after { inset: 9px 9px; border-width: 2.5px; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a {
  display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 12px; border-radius: 10px;
  color: var(--text-2); text-decoration: none; font-weight: 500; white-space: nowrap; transition: background var(--t), color var(--t);
}
.nav a:hover { background: var(--primary-softer); color: var(--text); }
.nav a[aria-current="page"] { background: var(--primary-soft); color: var(--primary-dark); font-weight: 600; }
:root[data-theme="dark"] .nav a[aria-current="page"] { color: var(--primary-dark); }
.nav .badge { margin-left: auto; }
.side-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 6px; }
.side-btn {
  display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 12px; border-radius: 10px; border: 0;
  background: none; color: var(--text-2); cursor: pointer; text-align: left; width: 100%; white-space: nowrap;
}
.side-btn:hover { background: var(--primary-softer); color: var(--text); }
.who { font-size: 12px; color: var(--muted); padding: 0 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.collapsed .nav-label, .collapsed .brand-text, .collapsed .who, .collapsed .nav .badge, .collapsed .tenant-pick { display: none; }
.collapsed .nav a, .collapsed .side-btn { justify-content: center; padding: 0; }
.tenant-pick select { width: 100%; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { display: none; }
.view { padding: 28px 32px 64px; max-width: 1280px; width: 100%; margin: 0 auto; outline: none; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head p { color: var(--muted); margin-top: 4px; max-width: 70ch; }
.page-head .actions { display: flex; gap: 8px; flex-wrap: wrap; }
.backdrop-nav { display: none; }

@media (max-width: 899px) {
  .shell, .shell.collapsed { grid-template-columns: minmax(0, 1fr); }
  .side {
    position: fixed; left: 0; top: 0; bottom: 0; width: 284px; max-width: 86vw; transform: translateX(-102%);
    transition: transform var(--t) ease-out; box-shadow: var(--shadow-lg); z-index: 60;
  }
  .shell.menu-open .side { transform: none; }
  .shell.menu-open .backdrop-nav { display: block; position: fixed; inset: 0; background: var(--overlay); z-index: 55; }
  .collapsed .nav-label, .collapsed .brand-text, .collapsed .who, .collapsed .nav .badge, .collapsed .tenant-pick { display: initial; }
  .collapsed .nav a, .collapsed .side-btn { justify-content: flex-start; padding: 0 12px; }
  .side .collapse-btn { display: none; }
  .topbar {
    display: flex; align-items: center; gap: 8px; position: sticky; top: 0; z-index: 40; height: 56px; padding: 0 8px 0 4px;
    background: var(--card); border-bottom: 1px solid var(--border);
  }
  .topbar .title { font-weight: 650; font-size: 16px; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .view { padding: 18px 16px 72px; }
  h1 { font-size: 21px; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 16px;
  border-radius: 10px; border: 1px solid var(--border-strong); background: var(--card); color: var(--text);
  font-weight: 600; font-size: 14.5px; cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: background var(--t), border-color var(--t), transform var(--t), box-shadow var(--t);
}
.btn:hover { background: var(--card-2); border-color: var(--primary); }
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: var(--on-primary); }
:root[data-theme="dark"] .btn-primary:hover { color: #04191b; }
.btn-soft { background: var(--primary-soft); border-color: transparent; color: var(--primary-dark); }
.btn-soft:hover { background: var(--primary-soft); border-color: var(--primary); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--primary-dark); }
.btn-ghost:hover { background: var(--primary-softer); border-color: transparent; }
.btn-danger { color: var(--red); border-color: var(--border-strong); }
.btn-danger:hover { border-color: var(--red); background: var(--red-bg); }
.btn-danger-solid { background: var(--red); border-color: var(--red); color: var(--on-color); }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 13.5px; }
.btn-block { width: 100%; }
.btn-icon { width: 44px; padding: 0; }
.btn.busy { position: relative; color: transparent !important; pointer-events: none; }
.btn.busy::after {
  content: ""; position: absolute; width: 18px; height: 18px; border-radius: 50%;
  border: 2.5px solid currentColor; border-color: var(--muted) transparent var(--muted) transparent; animation: spin .7s linear infinite;
}
.btn-primary.busy::after { border-color: var(--on-primary) transparent var(--on-primary) transparent; }
@keyframes spin { to { transform: rotate(360deg); } }
.link-btn { background: none; border: 0; padding: 0; color: var(--primary-dark); font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; min-height: 32px; }
:root[data-theme="dark"] .link-btn { color: var(--primary); }
@media (max-width: 899px) { .btn-sm { min-height: 44px; } }

/* ---------- cards ---------- */
.card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; min-width: 0; }
.card-flat { box-shadow: none; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2 { font-size: 16px; display: flex; align-items: center; gap: 8px; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-auto { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
@media (max-width: 1100px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) { .grid-2, .grid-3 { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 420px) { .grid-4 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; } .grid-auto { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 899px) { .card { padding: 16px; } }

/* KPI tiles */
.kpi { text-align: left; cursor: pointer; display: flex; flex-direction: column; gap: 4px; border: 1px solid var(--border); transition: border-color var(--t), transform var(--t); font: inherit; color: inherit; width: 100%; }
.kpi:hover { border-color: var(--primary); }
.kpi .label { color: var(--muted); font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.kpi .value { font-size: 24px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.kpi .hint { color: var(--muted); font-size: 12.5px; }
.kpi .go { color: var(--primary-dark); font-size: 12.5px; font-weight: 600; margin-top: auto; display: flex; align-items: center; gap: 4px; }
:root[data-theme="dark"] .kpi .go { color: var(--primary); }
@media (max-width: 420px) { .kpi .value { font-size: 19px; } .kpi .hint { display: none; } .kpi { padding: 14px; } }

/* ---------- chips ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 5px; padding: 2px 10px 2px 7px; border-radius: 999px; font-size: 12.5px; font-weight: 600;
  white-space: nowrap; line-height: 22px; background: var(--grey-bg); color: var(--grey);
}
.chip .ic { width: 14px; height: 14px; stroke-width: 2.2; }
.chip-red { background: var(--red-bg); color: var(--red); }
.chip-blue { background: var(--blue-bg); color: var(--blue); }
.chip-green { background: var(--green-bg); color: var(--green); }
.chip-purple { background: var(--purple-bg); color: var(--purple); }
.chip-amber { background: var(--amber-bg); color: var(--amber); }
.chip-teal { background: var(--primary-soft); color: var(--primary-dark); }
:root[data-theme="dark"] .chip-teal { color: var(--primary-dark); }
.chip-outline { background: transparent; border: 1px solid var(--border-strong); color: var(--text-2); }
.badge { display: inline-flex; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; background: var(--grey-bg); color: var(--text-2); font-variant-numeric: tabular-nums; }
.badge-red { background: var(--red-bg); color: var(--red); }

/* ---------- tabs ---------- */
.tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: thin; padding-bottom: 4px; margin-bottom: 14px; -webkit-overflow-scrolling: touch; }
.tab {
  display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--card); color: var(--text-2); font-weight: 600; font-size: 14px; cursor: pointer; white-space: nowrap; flex: none;
}
.tab:hover { border-color: var(--primary); }
.tab[aria-selected="true"] { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.tab[aria-selected="true"] .badge { background: rgba(255,255,255,.22); color: inherit; }
@media (max-width: 899px) { .tab { min-height: 44px; } }

/* ---------- toolbar / search ---------- */
.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.search { position: relative; flex: 1 1 260px; min-width: 0; }
.search .ic { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search input[type] { padding-left: 40px; }
.search-xl input[type] { min-height: 56px; font-size: 17px; border-radius: 14px; padding-left: 46px; }
.search-xl .ic { left: 14px; width: 22px; height: 22px; }

/* ---------- forms ---------- */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label, .label { font-weight: 600; font-size: 14px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.opt { font-weight: 400; color: var(--muted); font-size: 13px; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number], input[type=tel], input[type=search], input[type=url], select, textarea, .input {
  width: 100%; min-height: 44px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--border-strong);
  background: var(--card); color: var(--text); transition: border-color var(--t), box-shadow var(--t); min-width: 0;
}
textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 25%, transparent); }
input[aria-invalid="true"], select[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--red); }
input[type=color] { width: 56px; height: 44px; padding: 3px; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--card); cursor: pointer; }
.hint { font-size: 13px; color: var(--muted); }
.hint.ok { color: var(--green); }
.hint.bad { color: var(--red); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 560px) { .form-grid { grid-template-columns: minmax(0, 1fr); } }
.check { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding: 10px 0; cursor: pointer; font-weight: 500; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--primary); flex: none; }
.checks-inline { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; min-height: 44px; font-weight: 600; }
.switch input { appearance: none; -webkit-appearance: none; width: 44px; height: 26px; border-radius: 999px; background: var(--border-strong); position: relative; cursor: pointer; transition: background var(--t); margin: 0; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform var(--t); box-shadow: var(--shadow-sm); }
.switch input:checked { background: var(--primary); }
.switch input:checked::after { transform: translateX(18px); }
.form-error { border-radius: 10px; padding: 12px 14px; background: var(--red-bg); color: var(--red); font-weight: 500; display: flex; gap: 10px; align-items: flex-start; }
.form-error .ic { margin-top: 1px; }
.notice { border-radius: 10px; padding: 12px 14px; background: var(--primary-softer); border: 1px solid var(--primary-soft); color: var(--text-2); display: flex; gap: 10px; align-items: flex-start; font-size: 14px; }
.notice .ic { color: var(--primary); margin-top: 1px; }
.notice-amber { background: var(--amber-bg); border-color: transparent; color: var(--amber); }
.notice-amber .ic { color: var(--amber); }
.notice-red { background: var(--red-bg); border-color: transparent; color: var(--red); }
.notice-red .ic { color: var(--red); }
.notice-green { background: var(--green-bg); border-color: transparent; color: var(--green); }
.notice-green .ic { color: var(--green); }
details.more { border-top: 1px solid var(--border); padding-top: 6px; }
details.more > summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--primary-dark); list-style: none; }
:root[data-theme="dark"] details.more > summary { color: var(--primary); }
details.more > summary::-webkit-details-marker { display: none; }
details.more > summary .ic { transition: transform var(--t); }
details.more[open] > summary .ic { transform: rotate(90deg); }
.rules { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; }
.rules li { display: flex; gap: 8px; align-items: center; color: var(--muted); }
.rules li.ok { color: var(--green); }
.rules li .ic { width: 16px; height: 16px; }

/* combobox */
.combo { position: relative; }
.combo-list {
  position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 20; background: var(--card); border: 1px solid var(--border-strong);
  border-radius: 10px; box-shadow: var(--shadow-lg); max-height: 260px; overflow-y: auto; padding: 4px; margin: 0; list-style: none;
}
.combo-list li { padding: 10px 12px; border-radius: 8px; cursor: pointer; min-height: 44px; display: flex; flex-direction: column; justify-content: center; }
.combo-list li[aria-selected="true"], .combo-list li:hover { background: var(--primary-soft); }
.combo-list li .small { color: var(--muted); }
.picked { display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 12px; border: 1px solid var(--primary); background: var(--primary-softer); border-radius: 10px; min-height: 44px; }

/* ---------- lists (rows -> cards on phones) ---------- */
.list { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); overflow: hidden; }
.list-head, .lrow { display: grid; grid-template-columns: var(--cols, 2fr 1.4fr 1fr 1fr 1fr); gap: 12px; align-items: center; padding: 12px 16px; }
.list-head { font-size: 12.5px; font-weight: 600; color: var(--muted); background: var(--card-2); border-bottom: 1px solid var(--border); text-transform: none; }
.lrow { border-bottom: 1px solid var(--border); min-height: 60px; text-align: left; width: 100%; background: none; border-left: 0; border-right: 0; border-top: 0; font: inherit; color: inherit; transition: background var(--t); }
.lrow:last-child { border-bottom: 0; }
button.lrow, a.lrow, .lrow.click { cursor: pointer; text-decoration: none; }
button.lrow:hover, a.lrow:hover, .lrow.click:hover { background: var(--primary-softer); }
.lrow .cell { min-width: 0; }
.lrow .title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lrow .sub { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lrow .amount { font-weight: 650; font-variant-numeric: tabular-nums; text-align: right; }
.lrow .lbl { display: none; }
.list-foot { padding: 12px 16px; font-size: 13px; color: var(--muted); background: var(--card-2); border-top: 1px solid var(--border); display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
@media (max-width: 760px) {
  .list-head { display: none; }
  .lrow { grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 14px 16px; }
  .lrow .cell.wide { grid-column: 1 / -1; }
  .lrow .cell.hide-sm { display: none; }
  .lrow .amount { text-align: right; }
  .lrow .cell.st { grid-column: 1 / -1; order: 5; }
  .lrow .cell.amount { grid-column: 2; }
  .lrow .lbl { display: inline; color: var(--muted); font-size: 12px; font-weight: 500; margin-right: 4px; }
}
.mini-list { list-style: none; padding: 0; margin: 0; }
.mini-list > li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); min-height: 56px; }
.mini-list > li:last-child { border-bottom: 0; }
.mini-list .grow .title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-list .grow .sub { font-size: 13px; color: var(--muted); }
.mini-list button.grow { background: none; border: 0; text-align: left; padding: 0; cursor: pointer; min-height: 44px; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--primary-soft); color: var(--primary-dark); display: grid; place-items: center; font-weight: 700; font-size: 14px; flex: none; }
:root[data-theme="dark"] .avatar { color: var(--primary-dark); }

/* ---------- empty / skeleton / error ---------- */
.empty { text-align: center; padding: 40px 20px; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.empty .ic-lg { width: 44px; height: 44px; color: var(--primary); background: var(--primary-soft); border-radius: 14px; padding: 9px; }
.empty h3 { color: var(--text); font-size: 16px; }
.empty p { max-width: 46ch; }
.skel { display: block; border-radius: 8px; background: linear-gradient(90deg, var(--card-2) 0%, var(--border) 50%, var(--card-2) 100%); background-size: 200% 100%; animation: shimmer 1.2s linear infinite; }
.skel-line { height: 14px; margin: 8px 0; }
.skel-block { height: 96px; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.err-block { padding: 24px; display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }

/* ---------- drawer / modal ---------- */
.overlay { position: fixed; inset: 0; background: var(--overlay); z-index: 80; opacity: 0; transition: opacity var(--t); }
.overlay.in { opacity: 1; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: 560px; max-width: 100vw; background: var(--bg); z-index: 81; box-shadow: var(--shadow-lg);
  display: flex; flex-direction: column; transform: translateX(24px); opacity: 0; transition: transform var(--t) ease-out, opacity var(--t);
}
.drawer.wide { width: 760px; }
.drawer.in { transform: none; opacity: 1; }
.drawer-head { display: flex; align-items: center; gap: 10px; padding: 12px 12px 12px 20px; background: var(--card); border-bottom: 1px solid var(--border); min-height: 64px; }
.drawer-head h2 { flex: 1; min-width: 0; font-size: 17px; overflow: hidden; text-overflow: ellipsis; }
.drawer-body { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 20px; }
.drawer-foot { padding: 12px 20px; background: var(--card); border-top: 1px solid var(--border); display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
.drawer-foot .btn { flex: 0 1 auto; }
@media (max-width: 640px) {
  .drawer, .drawer.wide { width: 100vw; }
  .drawer-body { padding: 16px; }
  .drawer-foot { padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); }
  .drawer-foot .btn { flex: 1 1 auto; }
}
.modal {
  position: fixed; left: 50%; top: 50%; transform: translate(-50%, -48%); opacity: 0; z-index: 91; width: 440px; max-width: calc(100vw - 32px);
  max-height: calc(100vh - 32px); overflow-y: auto; background: var(--card); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 22px;
  transition: transform var(--t), opacity var(--t);
}
.modal.in { opacity: 1; transform: translate(-50%, -50%); }
.modal-overlay { z-index: 90; }
.modal h2 { margin-bottom: 8px; }
.modal .row { justify-content: flex-end; margin-top: 18px; }

/* ---------- toasts ---------- */
.toasts { position: fixed; right: 20px; bottom: 20px; z-index: 120; display: flex; flex-direction: column; gap: 8px; width: 380px; max-width: calc(100vw - 32px); pointer-events: none; }
.toast {
  pointer-events: auto; display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: #10262a; color: #fff;
  box-shadow: var(--shadow-lg); font-weight: 500; font-size: 14px; animation: toastin var(--t) ease-out;
}
:root[data-theme="dark"] .toast { background: #e7f0f1; color: #10262a; }
.toast .ic { margin-top: 1px; }
.toast-ok .ic { color: #6fd394; } .toast-err .ic { color: #ff8f84; }
:root[data-theme="dark"] .toast-ok .ic { color: var(--green); }
.toast button { margin-left: auto; background: none; border: 0; color: inherit; cursor: pointer; padding: 0 2px; min-height: 24px; opacity: .8; }
@keyframes toastin { from { transform: translateY(8px); opacity: 0; } }
@media (max-width: 640px) { .toasts { left: 16px; right: 16px; bottom: 16px; width: auto; } }

/* ---------- help tooltip ---------- */
.help { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--border-strong); background: var(--card); color: var(--primary-dark); font-size: 12px; font-weight: 700; cursor: help; padding: 0; vertical-align: middle; position: relative; flex: none; line-height: 1; }
:root[data-theme="dark"] .help { color: var(--primary); }
.help::before { content: ""; position: absolute; inset: -11px; }
.tip { position: absolute; z-index: 130; max-width: 300px; background: #10262a; color: #fff; padding: 10px 12px; border-radius: 10px; font-size: 13px; line-height: 1.45; font-weight: 400; box-shadow: var(--shadow-lg); }
:root[data-theme="dark"] .tip { background: #e7f0f1; color: #10262a; }
.tip strong { display: block; margin-bottom: 2px; }

/* ---------- auth ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); }
.auth-side { background: linear-gradient(160deg, #0e7c86, #0b5c63 70%); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-side h2 { font-size: 30px; line-height: 1.2; max-width: 16ch; }
.auth-side ul { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-direction: column; gap: 14px; }
.auth-side li { display: flex; gap: 10px; align-items: flex-start; opacity: .95; }
.auth-side .brand-name { color: #fff; }
.auth-main { display: grid; place-items: center; padding: 32px 20px; }
.auth-card { width: 100%; max-width: 420px; }
.auth-card h1 { margin-bottom: 6px; }
.auth-card .lead { color: var(--muted); margin-bottom: 22px; }
.auth-card form > * + * { margin-top: 14px; }
.auth-links { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-top: 18px; font-size: 14px; }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 52px; }
.pw-wrap .btn-icon { position: absolute; right: 0; top: 0; border: 0; background: none; }
.qr-box { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.qr-box .qr { background: #fff; padding: 10px; border-radius: 12px; border: 1px solid var(--border); width: 180px; height: 180px; flex: none; }
.qr-box .qr svg, .qr-box .qr img { width: 100%; height: 100%; display: block; }
.secret { font-family: ui-monospace, Consolas, monospace; font-size: 14px; background: var(--card-2); border: 1px dashed var(--border-strong); padding: 8px 10px; border-radius: 8px; overflow-wrap: anywhere; letter-spacing: .06em; }
.code-input { letter-spacing: .4em; font-size: 22px !important; text-align: center; font-variant-numeric: tabular-nums; }
@media (max-width: 899px) { .auth { grid-template-columns: minmax(0, 1fr); } .auth-side { display: none; } .auth-main { place-items: start center; padding-top: 28px; } }
.auth-mobile-brand { display: none; align-items: center; gap: 10px; margin-bottom: 24px; }
@media (max-width: 899px) { .auth-mobile-brand { display: flex; } }

/* ---------- home ---------- */
.hello { margin-bottom: 18px; }
.hello p { color: var(--muted); }
.action-card { display: flex; flex-direction: column; gap: 10px; }
.action-card .amt { font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }
.action-card p { color: var(--text-2); font-size: 14px; }
.action-card .btn { align-self: flex-start; margin-top: auto; }
.steps { list-style: none; margin: 0; padding: 0; }
.steps li { display: flex; align-items: center; gap: 10px; padding: 8px 0; min-height: 44px; }
.steps li .dot { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--border-strong); display: grid; place-items: center; flex: none; }
.steps li.done .dot { background: var(--green); border-color: var(--green); color: var(--on-color); }
.steps li.done .label-t { color: var(--muted); text-decoration: line-through; }
.progress { height: 8px; background: var(--card-2); border-radius: 999px; overflow: hidden; border: 1px solid var(--border); }
.progress > span { display: block; height: 100%; background: var(--primary); border-radius: 999px; transition: width 300ms; }

/* ---------- charge detail ---------- */
.summary-box { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 12px; font-variant-numeric: tabular-nums; }
.summary-box .total { font-weight: 700; font-size: 18px; border-top: 1px solid var(--border); padding-top: 8px; }
.summary-box .v { text-align: right; }
.pay-art { display: flex; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.pay-art .qr { background: #fff; padding: 8px; border-radius: 12px; border: 1px solid var(--border); width: 196px; height: 196px; flex: none; }
.pay-art .qr svg { width: 100%; height: 100%; display: block; }
.copybox { display: flex; gap: 8px; align-items: stretch; }
.copybox input { font-family: ui-monospace, Consolas, monospace; font-size: 13px; }
.barcode { background: #fff; border-radius: 8px; padding: 8px; border: 1px solid var(--border); height: 64px; }
.barcode svg { width: 100%; height: 100%; display: block; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 4px; }
.timeline li { position: relative; padding: 0 0 14px 24px; }
.timeline li::before { content: ""; position: absolute; left: 5px; top: 8px; bottom: -4px; width: 2px; background: var(--border); }
.timeline li:last-child::before { display: none; }
.timeline li::after { content: ""; position: absolute; left: 0; top: 5px; width: 12px; height: 12px; border-radius: 50%; background: var(--card); border: 2px solid var(--primary); }
.timeline .t { font-weight: 600; font-size: 14px; }
.timeline .s { font-size: 12.5px; color: var(--muted); }
.action-bar { display: flex; gap: 8px; flex-wrap: wrap; }
.action-bar .btn { flex: 0 1 auto; }
@media (max-width: 560px) { .action-bar .btn { flex: 1 1 calc(50% - 8px); } }
.kv { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 6px 14px; font-size: 14px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }

/* ---------- cockpit ---------- */
.cockpit { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; align-items: start; }
@media (max-width: 1100px) { .cockpit { grid-template-columns: minmax(0, 1fr); } }
.results { margin-top: 8px; }
.title-row { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 4px; border-bottom: 1px solid var(--border); min-height: 56px; }
.title-row:last-child { border-bottom: 0; }
.title-row input { width: 20px; height: 20px; accent-color: var(--primary); margin: 0 auto; }
.title-row label { cursor: pointer; min-width: 0; }
.sel-bar { position: sticky; bottom: 0; background: var(--card); border-top: 1px solid var(--border); padding: 12px 0 0; margin-top: 8px; }
.opt-card { display: flex; gap: 12px; align-items: center; padding: 14px; border: 1.5px solid var(--border); border-radius: 12px; cursor: pointer; background: var(--card); min-height: 64px; transition: border-color var(--t), background var(--t); }
.opt-card:hover { border-color: var(--primary); }
.opt-card input { width: 20px; height: 20px; accent-color: var(--primary); flex: none; }
.opt-card:has(input:checked) { border-color: var(--primary); background: var(--primary-softer); }
.opt-card .big { font-weight: 700; font-size: 16px; font-variant-numeric: tabular-nums; }
.part-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 44px; gap: 8px; align-items: end; }

/* ---------- agreements ---------- */
.ag-card .figures { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 12px 0; }
.ag-card .fig { background: var(--card-2); border-radius: 10px; padding: 10px 12px; min-width: 0; }
.ag-card .fig .l { font-size: 12px; color: var(--muted); }
.ag-card .fig .v { font-weight: 700; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.ag-card .fig.hl { background: var(--primary-soft); }
.ag-card .chosen { font-size: 15px; }
@media (max-width: 760px) { .ag-card .figures { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.parcels { list-style: none; padding: 0; margin: 0; }
.parcels li { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto auto; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px dashed var(--border); font-size: 14px; }
.parcels li:last-child { border-bottom: 0; }
@media (max-width: 480px) { .parcels li { grid-template-columns: 44px minmax(0, 1fr) auto; } .parcels li .chip { grid-column: 2 / -1; justify-self: start; } }

/* ---------- campaigns ---------- */
.preset { display: flex; flex-direction: column; gap: 10px; }
.preset p { color: var(--text-2); font-size: 14px; }
.preset .btn { margin-top: auto; align-self: flex-start; }
.preset.hl { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft), var(--shadow); }
.countdown { font-variant-numeric: tabular-nums; font-weight: 600; }

/* ---------- régua ---------- */
.cadence { position: relative; display: flex; gap: 16px; overflow-x: auto; padding: 34px 4px 12px; scroll-snap-type: x proximity; }
.cadence::before { content: ""; position: absolute; left: 20px; right: 20px; top: 52px; height: 3px; background: var(--primary-soft); border-radius: 3px; }
.cstep { position: relative; flex: 0 0 200px; scroll-snap-align: start; }
.cstep .day { position: relative; z-index: 1; display: inline-flex; align-items: center; justify-content: center; min-width: 58px; height: 36px; padding: 0 10px; border-radius: 999px; background: var(--primary); color: var(--on-primary); font-weight: 700; font-size: 14px; box-shadow: 0 0 0 5px var(--card); }
.cstep .day.before { background: var(--blue); color: var(--on-color); }
.cstep .day.zero { background: var(--primary-dark); color: var(--on-color); }
.cstep .box { margin-top: 12px; background: var(--card); border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow); padding: 8px; display: flex; flex-direction: column; gap: 6px; min-height: 96px; width: 100%; font: inherit; color: inherit; }
.cstep-item { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left; width: 100%; padding: 10px; border-radius: 10px; border: 1px solid transparent; background: var(--card-2); cursor: pointer; font: inherit; color: inherit; transition: border-color var(--t); min-height: 44px; }
.cstep-item:hover { border-color: var(--primary); }
.cstep .ch { display: flex; align-items: center; gap: 8px; font-weight: 600; width: 100%; }
.cstep .ch .ic { color: var(--primary); }
.cstep.add .box { border-style: dashed; align-items: center; justify-content: center; color: var(--primary-dark); font-weight: 600; box-shadow: none; cursor: pointer; flex-direction: row; }
.cstep.add .box:hover { border-color: var(--primary); }
@media (max-width: 760px) {
  .cadence { flex-direction: column; overflow: visible; padding: 4px 0 0 0; gap: 12px; }
  .cadence::before { left: 28px; right: auto; top: 10px; bottom: 10px; width: 3px; height: auto; }
  .cstep { flex: none; display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 10px; align-items: start; }
  .cstep .box { margin-top: 0; min-height: 0; }
  .cstep.add .box { min-height: 52px; }
}
.tone-amigavel { background: var(--green-bg); color: var(--green); }
.tone-lembrete { background: var(--blue-bg); color: var(--blue); }
.tone-firme { background: var(--amber-bg); color: var(--amber); }
.var-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.var-chips button { border: 1px dashed var(--border-strong); background: var(--card-2); border-radius: 999px; padding: 4px 10px; font-size: 13px; cursor: pointer; min-height: 32px; font-family: ui-monospace, Consolas, monospace; }
.var-chips button:hover { border-color: var(--primary); }
.msg-preview { background: var(--card-2); border: 1px solid var(--border); border-radius: 14px 14px 14px 4px; padding: 12px 14px; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; }
.msg-preview .subj { font-weight: 700; margin-bottom: 6px; }

/* ---------- jurídico ---------- */
.kanban { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; align-items: start; }
.kcol { background: var(--card-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; min-width: 0; }
.kcol-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; font-weight: 650; }
.kcard { display: block; width: 100%; text-align: left; font: inherit; color: inherit; background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 12px; box-shadow: var(--shadow-sm); cursor: pointer; transition: border-color var(--t); }
.kcard + .kcard { margin-top: 8px; }
.kcard:hover { border-color: var(--primary); }
.kcard .title { font-weight: 600; overflow-wrap: anywhere; }
.kcard .sub { font-size: 13px; color: var(--muted); }
@media (max-width: 1100px) { .kanban { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .kanban { grid-template-columns: minmax(0, 1fr); } }
.cand.hl { background: var(--amber-bg); border-radius: 8px; }

/* ---------- payments ---------- */
.prov { display: flex; flex-direction: column; gap: 10px; }
.prov-logo { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; color: var(--on-primary); background: var(--primary); flex: none; letter-spacing: -.02em; }
.prov p { font-size: 14px; color: var(--text-2); }

/* ---------- brand preview ---------- */
.phone { width: 260px; max-width: 100%; border: 10px solid #10262a; border-radius: 34px; background: #f4f7f7; overflow: hidden; box-shadow: var(--shadow-lg); margin: 0 auto; }
.phone .ph-head { padding: 22px 16px 16px; color: #fff; display: flex; align-items: center; gap: 10px; min-height: 76px; }
.phone .ph-head img { max-height: 34px; max-width: 110px; background: #fff; border-radius: 6px; padding: 2px; }
.phone .ph-body { padding: 14px; color: #10262a; display: flex; flex-direction: column; gap: 10px; }
.phone .ph-card { background: #fff; border-radius: 12px; padding: 12px; box-shadow: 0 1px 3px rgba(0,0,0,.08); font-size: 13px; }
.phone .ph-btn { color: #fff; border-radius: 10px; padding: 10px; text-align: center; font-weight: 700; font-size: 13px; }

/* ---------- settings ---------- */
.settings { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 20px; align-items: start; }
.settings nav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 16px; }
.settings nav button { text-align: left; border: 0; background: none; padding: 0 12px; min-height: 44px; border-radius: 10px; cursor: pointer; color: var(--text-2); font-weight: 500; display: flex; align-items: center; gap: 10px; }
.settings nav button[aria-selected="true"] { background: var(--primary-soft); color: var(--primary-dark); font-weight: 600; }
:root[data-theme="dark"] .settings nav button[aria-selected="true"] { color: var(--primary-dark); }
@media (max-width: 899px) {
  .settings { grid-template-columns: minmax(0, 1fr); }
  .settings nav { flex-direction: row; overflow-x: auto; position: static; gap: 6px; padding-bottom: 4px; }
  .settings nav button { white-space: nowrap; flex: none; border: 1px solid var(--border); background: var(--card); }
}

/* ---------- print sheet ---------- */
.sheet { background: #fff; color: #111; padding: 32px; border-radius: 8px; font: 14px/1.6 Georgia, "Times New Roman", serif; white-space: pre-wrap; overflow-wrap: anywhere; }
.sheet table { width: 100%; border-collapse: collapse; font: 12.5px/1.4 var(--font); white-space: normal; }
.sheet th, .sheet td { border-bottom: 1px solid #ddd; padding: 6px 6px; text-align: right; }
.sheet th:first-child, .sheet td:first-child, .sheet th:nth-child(2), .sheet td:nth-child(2) { text-align: left; }
.sheet .sheet-h { font: 600 16px/1.3 var(--font); margin-bottom: 4px; white-space: normal; }
.sheet .sheet-p { font: 13px/1.5 var(--font); white-space: normal; color: #333; }
.sheet-scroll { overflow-x: auto; }
@media (max-width: 640px) { .sheet { padding: 16px; } }
@media print {
  body.printing > *:not(#layer) { display: none !important; }
  body.printing #layer > *:not(.print-root) { display: none !important; }
  body.printing .print-root { position: static !important; width: auto !important; box-shadow: none !important; transform: none !important; background: #fff !important; }
  body.printing .print-root .drawer-head, body.printing .print-root .drawer-foot, body.printing .no-print { display: none !important; }
  body.printing .print-root .drawer-body { overflow: visible; padding: 0; }
  body.printing .sheet { padding: 0; }
}

/* ---------- celebration ---------- */
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 140; overflow: hidden; }
.confetti i { position: absolute; top: 40%; left: 50%; width: 9px; height: 14px; border-radius: 2px; opacity: 0; animation: burst 700ms ease-out forwards; }
@keyframes burst {
  0% { transform: translate(0, 0) rotate(0); opacity: 1; }
  100% { transform: translate(var(--dx), var(--dy)) rotate(var(--r)); opacity: 0; }
}
.paid-pop { animation: pop 180ms ease-out; }
@keyframes pop { 50% { transform: scale(1.12); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
  .confetti { display: none; }
}

/* cockpit on phones: the action bar must never cover the list it acts on */
.stats3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 760px) {
  .sel-bar { position: static; }
  .stats3 .strong { font-size: 15px !important; }
}
