:root {
  /* FocusTik palette (22.11.2026) – navy + gold. Every colour in the app should come from these tokens. */
  --navy: #1f3b63; --navy-2: #2c4f82; --navy-dark: #172d4c; --navy-soft: #e8eef6; --navy-ring: #c9d6ea;
  --gold: #8a6a2a; --gold-light: #d4b06a; --gold-soft: #f6efe1;
  --bg: #f5f7fa; --panel: #ffffff; --ink: #1e2433; --muted: #6b7385; --line: #e9ecf1; --field: #dde2e9;
  --brand: var(--navy); --brand-soft: var(--navy-soft); --accent: var(--navy-2);
  --ok: #157347; --ok-soft: #e6f4ec; --warn: #b54708; --warn-soft: #fff4e5; --bad: #b42318; --bad-soft: #fdecea;
  --radius: 10px; --gap: 16px;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 -apple-system, "Segoe UI", Arial, "Noto Sans Hebrew", sans-serif; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 23px; margin: 0 0 4px; font-weight: 600; }
h3 { font-size: 16px; margin: 0 0 12px; font-weight: 600; }
.mt { margin-top: 20px; }
.muted { color: var(--muted); }
.small, small { font-size: 13px; }
.nowrap { white-space: nowrap; }
.pre { white-space: pre-wrap; }
.hidden { display: none !important; }
.right { text-align: left; margin-bottom: 8px; }

/* layout */
main { flex: 1; padding: 20px 28px 60px; min-width: 0; }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); align-items: start; }
.cols.wide-first { grid-template-columns: minmax(0, 2.2fr) minmax(240px, 1fr); }
.head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.sub { color: var(--muted); }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* cards & grid */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin-bottom: var(--gap); }
.card.danger { border-color: #f3c7c3; }
.card-head { display: flex; justify-content: space-between; align-items: center; }
.title-group { display: flex; align-items: center; gap: 8px; }
/* home screen: draggable sections (home.html) – two free-standing columns, each a vertical drop zone */
.home-col { display: flex; flex-direction: column; gap: var(--gap); min-height: 48px; min-width: 0; }
/* the two home columns stay 50/50 – long one-line task titles are cut with "…" instead of widening their column */
.cols.hm-cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.drag-handle { cursor: grab; color: var(--muted); font-size: 17px; line-height: 1; user-select: none; }
.home-sec { margin-bottom: 0; }
.home-sec.dragging { opacity: .4; }
.collapsible h3 { cursor: pointer; }
.collapsible h3::after { content: " ▾"; color: var(--muted); }
.collapsible.closed > :not(h3) { display: none; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px 18px; }
.fld, .fv { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.fld.wide, .fv.wide { grid-column: 1 / -1; }
.lbl { font-size: 13px; color: var(--muted); }
.val { word-break: break-word; }
.val.empty { color: #b8bec6; }
.hint { color: var(--muted); }
input, select, textarea { font: inherit; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); width: 100%; }
/* תוכן שנשאר LTR לקריאה נכונה של הספרות/האותיות עצמן (טלפון, אימייל, ת"ז, מספרים, תאריכים, אנגלית) עדיין
   מיושר לימין בתוך השדה/התא שלו, בדיוק כמו כל שאר העמודה – dir="ltr" קובע רק את כיוון התווים, לא איפה
   הם יושבים בתוך הקופסה (ברירת המחדל text-align:start מתפרשת כ-left על אלמנט עם dir="ltr"). אינו משפיע
   על dir="ltr" מוטבע כ-inline בתוך משפט עברי (שם המיקום כבר נכון ממקומו במשפט, לא מ-text-align). */
input[dir="ltr"], td[dir="ltr"], th[dir="ltr"], .val[dir="ltr"],
input[type="number"], input[type="date"], input[type="time"], input[type="datetime-local"],
input[type="tel"], input[type="email"], input[type="url"] { text-align: right; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--navy-ring); border-color: var(--accent); }
select[multiple] { padding: 4px; }
.chk { display: inline-flex; align-items: center; gap: 6px; }
.chk input { width: auto; }
.chips { display: flex; gap: 14px; flex-wrap: wrap; }
.full { width: 100%; }

/* buttons */
.btn { display: inline-block; padding: 8px 14px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: var(--ink); cursor: pointer; font: inherit; }
.btn:hover { background: var(--bg); text-decoration: none; }
.btn.primary { background: linear-gradient(180deg, var(--navy-2), var(--navy)); border-color: var(--navy); color: #fff; }
.btn.primary:hover { background: var(--navy-dark); }
.btn.danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.btn.small { padding: 4px 10px; font-size: 13px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.loading { display: inline-flex; align-items: center; gap: 6px; }
button.loading { pointer-events: none; }
a.btn.loading { pointer-events: none; opacity: .6; cursor: wait; }
nav.tabs a.loading, nav.subtabs a.loading { opacity: .6; cursor: wait; }
nav.tabs.loading a, nav.subtabs.loading a { pointer-events: none; }   /* blocks every tab, not just the clicked one, until the page loads */
.spin { width: 13px; height: 13px; flex: none; border: 2px solid rgba(127,127,127,.35); border-top-color: currentColor; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
button.link { background: none; border: 0; color: var(--accent); padding: 0; cursor: pointer; font: inherit; }
.savebar { position: sticky; bottom: 0; background: linear-gradient(transparent, var(--page, var(--bg)) 30%); padding: 14px 0 4px; display: flex; gap: 8px; }

/* tables & lists */
.tbl { width: 100%; border-collapse: collapse; }
.tbl th { text-align: right; font-weight: 600; font-size: 13px; color: var(--muted); border-bottom: 1px solid var(--line); padding: 8px 6px; }
.tbl td { border-bottom: 1px solid var(--line); padding: 8px 6px; vertical-align: top; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tr.late td { background: var(--bad-soft); }
.tbl tr.today td { background: var(--warn-soft); }
.tbl tr.off td { color: var(--muted); }
.list { list-style: none; margin: 0; padding: 0; }
.list li { padding: 8px 0; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; }
.list li:last-child { border-bottom: 0; }
.case-line { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }   /* client card: case name + status tag on one line */
.tag { display: inline-block; font-size: 12px; padding: 1px 8px; border-radius: 999px; background: var(--brand-soft); color: var(--brand); vertical-align: middle; }
.tag.warn { background: var(--warn-soft); color: var(--warn); }
.tag.ok { background: var(--ok-soft); color: var(--ok); }
.tag.soft { background: #eef0f3; color: var(--muted); }
.tag.bad { background: var(--bad-soft, #fdecec); color: var(--bad); }
.filters { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 12px 14px; }
.filters select { width: auto; }

/* stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); margin: 14px 0 var(--gap); }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; color: var(--ink); display: flex; flex-direction: column; }
.stat b { font-size: 25px; font-weight: 600; }
.stat span { color: var(--muted); font-size: 13px; }
a.stat:hover { text-decoration: none; border-color: #c9d4e3; }

/* tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: var(--gap); overflow-x: auto; }
.tabs a { padding: 8px 14px; color: var(--muted); border-bottom: 2px solid transparent; white-space: nowrap; }
.tabs a.on { color: var(--brand); border-bottom-color: var(--brand); font-weight: 600; }
.tabs a:hover { text-decoration: none; color: var(--ink); }

/* tasks & gorms */
/* task row (case tasks, lead tasks, collection): text | ✓ button on top, the "עדכון / מה הלאה" form on its own full-width row
   below – so a narrow screen never squeezes the task text into a thin column (task-actions is display:contents) */
.task { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 14px; row-gap: 8px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.task:last-child { border-bottom: 0; }
.task.done .pre { color: var(--muted); text-decoration: line-through; }
.task-main { grid-column: 1; grid-row: 1; min-width: 0; overflow-wrap: anywhere; }
.task-actions { display: contents; }
.task-actions > form:not(.inline-note) { grid-column: 2; grid-row: 1; align-self: start; }
.task-actions > form:not(.inline-note) .btn { white-space: nowrap; }
.task-actions > .inline-note { grid-column: 1 / -1; grid-row: 2; }
.note { margin-top: 4px; padding-right: 10px; border-right: 2px solid var(--line); }
.inline-note { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.inline-note input { padding: 4px 8px; font-size: 13px; }
.inline-note input[type=date] { width: 120px; }
.task .inline-note > input[name=note] { flex: 1 1 240px; min-width: 0; }
.task .inline-note .datefld { flex: 0 0 auto; width: 165px; min-width: 0; }
.task-edit summary { cursor: pointer; color: var(--muted); font-size: 13px; margin-top: 4px; }
.task-edit[open] summary { margin-bottom: 6px; }
.task-edit form { margin-top: 4px; }
.mine-row { gap: 6px; }
.mine-row .postpone { margin-top: 2px; flex-wrap: wrap; }
.mine-row .postpone input[name=note] { flex: 1; min-width: 100px; }
.sub-actions { display: flex; gap: 10px; align-items: center; margin-top: 2px; }
.sub-actions form.inline { display: inline; }
.done-text { color: var(--muted); text-decoration: line-through; }
.gorm { padding: 8px 0; border-bottom: 1px solid var(--line); }
.gorm:last-child { border-bottom: 0; }
.gorm-c { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 4px; font-size: 14px; }
.gorm-add { margin-top: 10px; }
.gorm-add summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.gorm-add form { margin-top: 8px; }
.row-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }

/* flash & auth */
.flash { padding: 10px 14px; border-radius: 8px; margin-bottom: 14px; }
.flash.ok { background: var(--ok-soft); color: var(--ok); }
.flash.err { background: var(--bad-soft); color: var(--bad); }
.flash.warn { background: var(--warn-soft); color: var(--warn); }
.auth { max-width: 420px; margin: 8vh auto; padding: 0 16px; }
.auth-card { display: flex; flex-direction: column; gap: 14px; }
.auth-card h2 { margin: 0; font-size: 21px; }
.qr { display: flex; justify-content: center; }
.steps { margin: 0; padding-right: 18px; }
code { background: var(--bg); padding: 2px 6px; border-radius: 4px; }

@media (max-width: 900px) {
  main { padding: 14px 16px 40px; }
  .cols, .cols.wide-first, .cols.hm-cols { grid-template-columns: minmax(0, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .task .inline-note > input[name=note] { flex-basis: 100%; padding: 8px 10px; font-size: 15px; }
  .task .inline-note .datefld { flex: 1 1 140px; width: auto; }
  .task .inline-note .btn { padding: 8px 14px; }
}

/* finance */
.fin-stats { margin: 0 0 14px; }
.stat.due b { color: var(--bad); }
.stat.ok b { color: var(--ok); }
.tbl.num td:not(:first-child), .tbl.num th:not(:first-child) { white-space: nowrap; }
.tbl tr.sum td { font-weight: 600; border-top: 2px solid var(--line); }
.sub-form { background: var(--bg); border-radius: 8px; padding: 12px; margin: 10px 0; }
.row-tools td { background: #fafbfc; }
.row-actions form { display: inline-flex; gap: 6px; align-items: center; }
.bar { height: 8px; background: var(--brand); border-radius: 4px; }
.confirm-box { border: 2px solid var(--warn); background: var(--warn-soft); }
.warn-box { border: 2px solid var(--warn); background: var(--warn-soft); }

/* message menu */
details.menu { position: relative; }
details.menu summary { list-style: none; }
details.menu summary::-webkit-details-marker { display: none; }
.menu-list { position: absolute; left: 0; top: 110%; background: #fff; border: 1px solid var(--line); border-radius: 8px; min-width: 220px; z-index: 10; box-shadow: 0 6px 24px rgba(0,0,0,.08); padding: 4px; }
.menu-list a { display: block; padding: 8px 10px; border-radius: 6px; color: var(--ink); }
.menu-list a:hover { background: var(--bg); text-decoration: none; }
.actions form { display: inline; }
.status-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #c4c9d0; margin-left: 6px; }
.status-dot.on { background: var(--ok); }
.req { color: var(--bad); }
.card.gaps { border-color: #f5d29a; background: var(--warn-soft); }
.card.gaps ul { margin: 0 0 10px; padding-right: 18px; }

/* history log */
.hist { list-style: none; margin: 0; padding: 0; }
.hist li { border-bottom: 1px solid var(--line); padding: 8px 0; }
.hist li:last-child { border-bottom: 0; }
.hist-top { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.hist-what { font-weight: 500; }
.hist-val { margin-top: 2px; font-size: 14px; overflow-wrap: anywhere; }
.hist-val s { color: var(--muted); }
.hist.compact li { padding: 6px 0; font-size: 14px; }
.chips.small { gap: 6px; font-size: 14px; }
.chips.small a { padding: 2px 10px; border-radius: 999px; background: #eef0f3; color: var(--muted); text-decoration: none; }
.chips.small a.on { background: var(--brand-soft); color: var(--brand); }

/* documents */
form.inline { display: inline; }
details.menu.inline { display: inline-block; }
details.menu.inline .menu-list { padding: 10px; display: flex; flex-direction: column; gap: 8px; min-width: 240px; }

.sub.dates { font-size: 13px; color: var(--muted); margin-top: 2px; }

/* case deadlines */
.tbl.dl tr.past td { color: var(--muted); }
.tbl.dl input[type=date], .tbl.dl input[type=datetime-local] { max-width: 220px; }

/* case mail tab */
.tbl.mails tr { cursor: pointer; }
.tbl.mails tr.unread td { font-weight: 600; }
.mailmsg { border-bottom: 1px solid var(--line); padding: 12px 0; }
.mailmsg:last-child { border-bottom: 0; }
.mailmsg.mine { background: #f7f9fc; padding-inline: 10px; border-radius: 8px; }
.mail-head { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.mail-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.6; }
textarea.full { width: 100%; }

.subtabs { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.subtabs a { padding: 6px 14px; border-radius: 999px; background: #eef0f3; color: var(--muted); text-decoration: none; font-size: 15px; }
.subtabs a.on { background: var(--brand); color: #fff; }
.subtabs .muted { margin-inline-start: auto; }
textarea.rtl { direction: rtl; text-align: right; }
.sigprev { white-space: pre-wrap; direction: rtl; text-align: right; color: var(--muted); font-size: 14px; border-inline-start: 3px solid var(--line); padding: 6px 10px; margin-top: 8px; }
.sigprev::before { content: "החתימה תתווסף אוטומטית:"; display: block; font-size: 12px; margin-bottom: 4px; }

.copyline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.copyline code { background: #f2f4f7; padding: 6px 10px; border-radius: 6px; font-size: 14px; direction: ltr; overflow-wrap: anywhere; }

/* data completeness report */
.quality .issues { margin: 0; padding-inline-start: 16px; }
.quality .issues li { margin: 2px 0; }
@media print {
  .side, .appbar, .noprint, .flash { display: none !important; }
  main { padding: 0; }
  .card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }
  a { color: inherit; text-decoration: none; }
}

/* notifications */
.notif-bar { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.notif-list li.unread { background: var(--brand-soft); margin: 0 -12px; padding-inline: 12px; }
.notif-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.notif-prefs td.c, .notif-prefs th.c { text-align: center; width: 80px; }
.notif-prefs tr.grp td { font-weight: 600; background: var(--bg); }
.notif-prefs input { width: auto; }
.sub-title { font-size: 14px; color: var(--muted); margin: 10px 0 4px; font-weight: 600; }

/* deadline status (בוטל / התקיים / בוצע) */
.tbl.dl tr.cancelled td { background: #fafafa; }
.tbl.dl .dl-why { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; margin-top: 6px; }
.tbl.dl .dl-why[hidden], .tbl.dl .dl-note[hidden] { display: none; }
.tbl.dl .dl-note { flex-basis: 100%; max-width: 320px; }
.tbl.dl td.right .menu-list { text-align: right; }

/* home: "זימונים ביומן" – invitations waiting to be linked to a case (prominent) */
.flash.cal-banner { display: block; font-size: 1.05em; padding: 12px 16px; border-inline-start: 5px solid #d97706; text-decoration: none; }
.flash.cal-banner:hover { filter: brightness(.97); }

/* "+ ערך חדש…" in a select that can grow (שם השופט, בית משפט) */
input.new-choice { margin-top: 6px; }
.new-choice-hint { display: block; margin-top: 4px; color: #92400e; }

/* "נתבעים ומסירות" grid (court tab) */
.tbl td.svc-delivered { color: #15803d; font-weight: 700; }
.tbl td.svc-late { color: #b45309; }
.tbl td.svc-none { color: #b91c1c; }

/* top search – live suggestions */
/* the form stays flex:1 (as before) so the bar keeps its place on the right; the list is as wide as the input (max 560px) */
.search { position: relative; }
.search-sug { position: absolute; top: calc(100% + 4px); inset-inline-start: 0; width: 100%; max-width: 560px; z-index: 50; background: var(--panel);
  border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,.08); overflow: hidden; }
.search-sug .sug-row { display: flex; align-items: center; gap: 8px; padding: 8px 12px; color: var(--ink); }
.search-sug .sug-row:hover, .search-sug .sug-row.on { background: var(--brand-soft); }
.search-sug .sug-name { font-weight: 600; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-sug .sug-extra { font-size: 13px; }
.search-sug .sug-none { padding: 8px 12px; color: var(--muted); font-size: 14px; }
.search-sug .sug-all { display: block; padding: 8px 12px; border-top: 1px solid var(--line); font-size: 14px; }

/* flexible "התיק" card – per-case extra rows (app/casecard.py) */
.card-rm button { color: var(--muted); padding: 0 4px; }
.card-rm button:hover { color: #d92d20; }
.card-add { margin-top: 12px; border-top: 1px dashed var(--line); padding-top: 10px; }
.card-add summary { cursor: pointer; color: var(--accent); font-size: 14px; }
.card-add form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 8px; }
.card-add select { width: auto; flex: 1; min-width: 200px; max-width: 320px; }
.fv-tools { display: flex; gap: 12px; align-items: center; }

/* long text in view mode (e.g. "הערות משרד"): first ~9 lines, "הצג עוד" opens the rest (app.js) */
.val.clamp { display: block; line-height: 1.5; max-height: calc(1.5em * 9); overflow: hidden; }
.val.clamp.open { max-height: none; }
.clamp-more { display: block; align-self: flex-start; margin: 4px 0 0; padding: 0; text-align: start; }

/* "סטטוס תיק" pill – color = the option's color in Airtable (status_cls() in main.py). Light2 = soft, Light1 = medium,
   Bright / Dark1 = solid with white text. */
.st { display: inline-block; font-size: 13px; line-height: 1.5; padding: 1px 10px; border-radius: 999px; vertical-align: middle;
      background: color-mix(in srgb, var(--st) 16%, white); color: color-mix(in srgb, var(--st) 75%, black);
      border: 1px solid color-mix(in srgb, var(--st) 30%, white); white-space: nowrap; }
.st.st-l1 { background: color-mix(in srgb, var(--st) 32%, white); }
.st.st-b, .st.st-d { background: var(--st); color: #fff; border-color: var(--st); }
.st.st-d { background: color-mix(in srgb, var(--st) 80%, black); }
select.st-sel.st { font-size: 14px; padding: 3px 10px; cursor: pointer; }
.st-blue { --st: #2d7ff9; } .st-cyan { --st: #18bfff; } .st-teal { --st: #20c9a7; } .st-green { --st: #20c933; }
.st-yellow { --st: #e0a800; } .st-orange { --st: #ff6f2c; } .st-red { --st: #f82b60; } .st-pink { --st: #ff08c2; }
.st-purple { --st: #8b46ff; } .st-gray { --st: #666; }

/* smart case status (app/smartstatus.py): suggestion / undo strip under the case header */
.smart-status { display: flex; flex-direction: column; gap: 6px; margin: 0 0 10px; padding: 8px 12px;
                background: #fffbea; border: 1px solid #f3e3a1; border-radius: 8px; font-size: 15px; }
.smart-status form { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }

/* home screen: late tasks – a thin colored edge + small tag; 1–2 days orange, more red (days_late() in main.py) */
.mine-row.late-warn, .mine-row.late-bad { border-inline-start: 3px solid; padding-inline-start: 8px; }
.mine-row.late-warn { border-inline-start-color: #f0a35e; }
.mine-row.late-bad { border-inline-start-color: #e07a72; }
.late-tag { display: inline-block; font-size: 12px; padding: 0 7px; border-radius: 999px; margin-inline-start: 6px; vertical-align: middle; }
.late-warn .late-tag { background: var(--warn-soft); color: var(--warn); }
.late-bad .late-tag { background: var(--bad-soft); color: var(--bad); }

/* case header: the client name is the title and a link – same look as the title, underline on hover */
h1 a.h1-link { color: inherit; text-decoration: none; }
h1 a.h1-link:hover { text-decoration: underline; }

/* date fields: dd/mm/yyyy text box + 📅 in front of the real (hidden) date input – see the end of app.js */
.datefld { display: inline-flex; align-items: center; gap: 4px; min-width: 140px; vertical-align: middle; }
.datefld.full { display: flex; width: 100%; }
.datefld .date-txt { flex: 1; min-width: 0; text-align: right; }
.datefld .date-txt:invalid { border-color: var(--bad); }
.date-btn { border: 1px solid var(--line); background: #fff; border-radius: 8px; padding: 6px 8px; cursor: pointer; line-height: 1; }
.date-btn:hover { background: var(--bg); }
input.date-native { width: 0; height: 0; min-width: 0; padding: 0; margin: 0; border: 0; opacity: 0; pointer-events: none; }   /* stays in place: other scripts use its parentNode */
.card-add .card-opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 4px 12px; margin: 8px 0; }

/* "סידור שדות" – global field order in the case "פרטים" tab */
.arr-item { position: relative; border: 1px dashed var(--line, #ccc); border-radius: 6px; padding: 6px 26px 6px 8px; background: var(--card, #fff); cursor: grab; }
.arr-item.wide { grid-column: 1 / -1; }
.arr-item.dragging { opacity: .4; }
.arr-item .arr-h { position: absolute; top: 6px; right: 6px; color: var(--muted, #888); font-size: 17px; line-height: 1; }
.arr-item.dim { opacity: .55; border-style: dotted; }
.edit-bar { text-align: right; margin-bottom: 8px; }
/* "שיחות הכנה": the public booking page (/book/<code>) and the card in the deadlines tab */
.auth-card.book { max-width: 560px; }
.book-day { margin: 10px 0; }
.book-date { font-weight: 600; margin-bottom: 6px; }
.book-slots { display: flex; flex-wrap: wrap; gap: 6px; }
.slot { position: relative; }
.slot input { position: absolute; inset: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; margin: 0; }
.slot span { display: inline-block; padding: 6px 12px; border: 1px solid var(--line, #ccc); border-radius: 8px; cursor: pointer; direction: ltr; }
.slot input:checked + span { background: var(--accent); color: #fff; border-color: var(--accent); }
.slot input:focus-visible + span { outline: 2px solid var(--accent); }
.booked { font-size: 1.05em; }
tr.prep-actions td { border-top: 0; padding-top: 0; }
.prep-send .chips { margin: 6px 0; }
.book-submit { position: sticky; bottom: 0; background: var(--panel, #fff); padding: 10px 0; }

/* ---------------------------------------------------------------- settings center (November 2026)
   /settings/* + users / document templates / audit log: a side menu next to the page (settings_layout.html).
   Existing palette; sizes: page title 22, card title 16, body 14, hint 13, label 12. */
.set-shell { display: flex; gap: 24px; align-items: flex-start; }
.set-nav { width: 220px; flex-shrink: 0; position: sticky; top: 12px; display: flex; flex-direction: column; gap: 1px; }
.set-nav a { padding: 6px 10px; border-radius: 8px; color: var(--ink); }
.set-nav a:hover { background: var(--panel); text-decoration: none; }
.set-nav a.on { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.set-nav .set-home { font-size: 19px; font-weight: 600; padding: 4px 10px 8px; }
.set-nav .set-group { font-size: 13px; font-weight: 600; color: var(--muted); padding: 12px 10px 4px; }
.set-main { flex: 1; min-width: 0; max-width: 980px; }
.set-head { margin-bottom: 14px; }
.set-crumb { font-size: 13px; color: var(--muted); }
.set-lead { margin: 2px 0 0; }
.set-h2 { font-size: 17px; font-weight: 600; margin: 0 0 10px; }
.set-main .card .hint, .set-main .card .small { font-size: 14px; }
.set-main .lbl { font-size: 13px; }
.set-toc { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; }
.set-toc a { font-size: 14px; padding: 2px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--panel); color: var(--ink); }
.set-toc a:hover { border-color: var(--brand); color: var(--brand); text-decoration: none; }
.set-main section[id] { scroll-margin-top: 12px; }
.set-narrow { max-width: 520px; }
/* home: tiles */
.set-tiles-group { margin-bottom: 20px; }
.set-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.set-tile { display: flex; flex-direction: column; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; color: var(--ink); min-height: 92px; }
.set-tile:hover { border-color: var(--brand); text-decoration: none; }
.set-tile-title { font-weight: 600; display: flex; justify-content: space-between; gap: 6px; align-items: center; }
/* connections: one card per service */
.set-svc { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; margin-bottom: 16px; }
.set-svc a { display: flex; justify-content: space-between; align-items: center; gap: 6px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; color: var(--ink); }
.set-svc a:hover { text-decoration: none; border-color: var(--brand); }
.set-svc a.on { border-color: var(--brand); background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand); }
.set-rows .set-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 10px 0; border-top: 1px solid var(--line); }
.set-rows .set-row:first-child { border-top: 0; padding-top: 0; }
.set-rows .set-row form { margin: 0; }
.set-meter { height: 8px; border-radius: 999px; background: #eef0f3; overflow: hidden; }
.set-meter span { display: block; height: 100%; background: var(--brand); }
.set-meter span.bad { background: var(--bad); }
/* save bar: "יש שינויים שלא נשמרו" appears once a field of the form changed (app.js) */
.set-savebar { align-items: center; }
.set-dirty { display: none; font-size: 14px; color: var(--warn); }
.set-form.dirty .set-dirty { display: inline; }
.set-form.dirty .set-savebar { background: linear-gradient(transparent, var(--page, var(--bg)) 20%); }
@media (max-width: 900px) {
  .set-shell { flex-direction: column; gap: 12px; }
  .set-nav { position: static; width: 100%; flex-direction: row; flex-wrap: wrap; gap: 4px; }
  .set-nav .set-group { display: none; }
  .set-nav .set-home { font-size: 15px; padding: 6px 10px; }
}
/* chip lists (settings) */
.chips-edit { display: flex; flex-direction: column; gap: 8px; }
.chips-list { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-item { display: inline-flex; align-items: center; gap: 6px; padding: 3px 4px 3px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--panel); font-size: 14px; }
.chip-item button { border: 0; background: none; color: var(--muted); cursor: pointer; font: inherit; padding: 0 6px; border-radius: 999px; }
.chip-item button:hover { background: var(--bad-soft); color: var(--bad); }
.chip-item.bad { border-color: var(--bad); color: var(--bad); }
.chips-add { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.chips-add input { width: auto; flex: 1; min-width: 160px; max-width: 280px; padding: 6px 10px; }
.chips-msg { font-size: 13px; color: var(--bad); }
.set-tile-now { margin-top: auto; padding-top: 6px; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink); }
/* settings search + tabs */
.set-search { position: relative; margin: 0 4px 6px; }
.set-search input { padding: 6px 12px; border-radius: 999px; font-size: 14px; }
.set-search-res { position: absolute; top: calc(100% + 4px); right: 0; left: 0; z-index: 20; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 4px 16px rgba(24, 33, 43, .12); padding: 4px; min-width: 260px; }
.set-search-res a { display: flex; flex-direction: column; padding: 6px 10px; border-radius: 8px; color: var(--ink); }
.set-search-res a small { color: var(--muted); font-size: 13px; }
.set-search-res a:hover, .set-search-res a.on { background: var(--brand-soft); text-decoration: none; }
.set-search-none { padding: 8px 10px; font-size: 14px; color: var(--muted); }
nav.set-tabs { gap: 0; border-bottom: 1px solid var(--line); }
nav.set-tabs a { border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: none; padding: 8px 14px; font-size: 15px; color: var(--muted); margin-bottom: -1px; }
nav.set-tabs a.on { color: var(--brand); border-bottom-color: var(--brand); font-weight: 600; }
nav.set-tabs a:hover { color: var(--ink); }

/* ---- home screen (Nov 2026 redesign – same look as the settings center) ---- */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 1px 8px; border-radius: 4px; font-size: 13px; line-height: 18px; font-weight: 500; white-space: nowrap; background: #eef0f3; color: var(--muted); text-decoration: none; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
a.badge:hover { text-decoration: none; filter: brightness(.97); }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.bad { background: var(--bad-soft); color: var(--bad); }
.badge.info { background: var(--brand-soft); color: var(--accent); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--brand); }
.btn.ghost:hover { background: var(--brand-soft); }
.hm { display: flex; flex-direction: column; gap: var(--gap); }
.hm .card { margin-bottom: 0; }
.hm-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.hm-title { display: flex; flex-direction: column; gap: 2px; }
.hm-title h1 { margin: 0; line-height: 30px; }
.hm-crumb { font-size: 13px; line-height: 16px; font-weight: 500; color: var(--muted); }
.hm-lead { margin: 0; color: var(--muted); }
.hm-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.hm-tile { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--ink); }
.hm-tile > span { display: flex; flex-direction: column; min-width: 0; }
.hm-tile b { font-size: 27px; line-height: 32px; font-weight: 600; font-variant-numeric: tabular-nums; }
.hm-tile i { font-style: normal; color: var(--muted); }
a.hm-tile:hover { text-decoration: none; border-color: #c4c9d0; }
.hm .lbl, .hm-tile .lbl { font-size: 13px; line-height: 16px; font-weight: 500; color: var(--muted); }
.hm-cnt { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 20px; padding: 0 6px; border-radius: 999px; background: #eef0f3; color: var(--muted); font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; flex: none; }
.hm-cnt.warn { background: var(--warn-soft); color: var(--warn); }
.hm-h2 { margin: 0; font-size: 17px; line-height: 24px; font-weight: 600; }
.hm-sec-h { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding-bottom: 6px; }
.hm-sec-h .title-group { flex-wrap: wrap; }
.hm-sec-acts { display: flex; align-items: center; gap: 6px; }
.hm-phone-only { display: none; }   /* phone: "+ לקוח חדש" moves from the page header into "לקוחות חדשים" */
.hm-attn-card { display: flex; flex-direction: column; gap: 4px; }
.hm-attn { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 28px; }
.hm-attn .wide { grid-column: 1 / -1; }
.hm-arow { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); color: var(--ink); cursor: pointer; list-style: none; }
.hm-arow::-webkit-details-marker { display: none; }
.hm-arow:hover { text-decoration: none; }
.hm-arow:hover .txt { color: var(--brand); }
.hm-arow .txt { flex: 1; min-width: 0; }
.hm-arow .go { color: var(--brand); font-size: 14px; font-weight: 500; white-space: nowrap; }
.hm-arow-d[open] .go { visibility: hidden; }
.hm-mails { display: flex; flex-direction: column; margin: 0 0 6px; padding: 4px 12px; background: #eef0f3; border-radius: 8px; }
.hm-mails a { display: flex; flex-direction: column; padding: 6px 0; color: var(--ink); }
.hm-mails a + a { border-top: 1px solid var(--line); }
.hm-mails a.hm-mails-all { color: var(--brand); font-size: 14px; }
.hm-sec { display: flex; flex-direction: column; }
.hm-seg { display: inline-flex; padding: 2px; gap: 2px; background: #eef0f3; border-radius: 8px; }
.hm-seg a { font-size: 14px; line-height: 20px; color: var(--muted); padding: 3px 10px; border-radius: 6px; white-space: nowrap; }
.hm-seg a:hover { color: var(--ink); text-decoration: none; }
.hm-seg a.on { background: var(--panel); color: var(--ink); font-weight: 500; box-shadow: 0 1px 2px rgba(27, 34, 48, .12); }
.hm-rows { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.hm-row { display: flex; align-items: flex-start; flex-wrap: wrap; gap: 4px 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.hm-rows > .hm-row:first-child, .hm-grp + .hm-row { border-top: 0; }
.hm-row[hidden], .hm-grp[hidden] { display: none; }
.hm-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.hm-ttl { color: var(--ink); font-weight: 500; }
a.hm-ttl:hover { color: var(--brand); }
.hm-meta { font-size: 14px; line-height: 18px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; }
.hm-meta a { color: var(--muted); text-decoration: underline; text-decoration-color: var(--line); }
.hm-meta a:hover { color: var(--brand); }
.hm-meta .due-warn { color: var(--warn); }
.hm-meta .due-bad { color: var(--bad); }
/* task rows (המשימות שלי / משימות גבייה, Nov 2026): every row the same height – one line for the title, one for
   the details (cut with "…", full text on hover); a sub-task row is marked softly, the parent shows "↳ N" */
.hm-task > .hm-t { flex: 1 1 0; min-width: 0; }
.hm-task .hm-ttl { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hm-task .hm-meta { flex-wrap: nowrap; white-space: nowrap; overflow: hidden; }
.hm-task .hm-meta > * { flex: none; }
.hm-task .hm-meta > a:first-child { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.hm-task .hm-acts { flex: none; width: auto; min-width: 0; }   /* also on phone: the late badge stays on the row, not a line of its own */
.hm-task .hm-ttl .sub-arrow { color: var(--accent, var(--brand)); opacity: .55; margin-inline-end: 4px; }
.hm-task.is-sub .hm-ttl { font-weight: 400; }
.sub-hint { color: var(--brand); background: var(--brand-soft); border-radius: 999px; padding: 0 8px; font-size: 13px; }
.hm-acts { flex: none; display: flex; align-items: center; gap: 6px; }
.hm-pp { flex: none; }
.hm-pp > summary { list-style: none; }
.hm-pp > summary::-webkit-details-marker { display: none; }
.hm-pp[open] { flex-basis: 100%; padding: 8px 10px; background: #eef0f3; border-radius: 8px; }
.hm-pp[open] > summary { display: none; }
.hm-pp form.postpone { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.hm-pp form.postpone input[name=note] { width: auto; flex: 1 1 140px; min-width: 120px; padding: 5px 8px; font-size: 14px; }
.hm-pp-date { display: inline-flex; align-items: center; gap: 6px; flex: none; }
.hm-pp-date .datefld { width: 150px; min-width: 0; }
.inline-note input.date-native { width: 0; padding: 0; }   /* .inline-note input[type=date] (more specific) would give the hidden native field 120px */
.hm-grp { display: flex; justify-content: space-between; align-items: baseline; padding: 12px 0 4px; font-size: 13px; line-height: 16px; font-weight: 600; color: var(--muted); border-top: 1px solid var(--line); }
.hm-rows > .hm-grp:first-child, .hm-sec-h + .hm-grp { border-top: 0; padding-top: 2px; }
.hm-grp.today { color: var(--brand); }
.hm-grp.past { color: var(--bad); }
.hm-when { flex: none; width: 46px; font-size: 14px; line-height: 22px; color: var(--muted); font-variant-numeric: tabular-nums; }
.hm-prep { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 4px; }
.hm-prep form.inline { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.money { font-weight: 600; font-variant-numeric: tabular-nums; unicode-bidi: isolate; }
.hm-more { padding-top: 6px; border-top: 1px solid var(--line); }
.hm-empty { margin: 0; padding: 4px 0; color: var(--muted); }
.drag-handle { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 24px; color: #c4c9d0; border-radius: 4px; }
.drag-handle:hover { color: var(--muted); background: #eef0f3; }
#home-grid.is-dragging .home-col { outline: 2px dashed var(--navy-ring); outline-offset: 4px; border-radius: var(--radius); }
.home-sec.dragging { opacity: .4; }
@media (max-width: 900px) {
  .hm-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .hm-tile { padding: 10px 12px; }
  .hm-tile b { font-size: 23px; line-height: 28px; }
  .hm-attn { grid-template-columns: minmax(0, 1fr); }
  .hm-arow { min-height: 44px; padding: 4px 0; }
  .hm-seg { display: flex; width: 100%; }
  .hm-seg a { flex: 1; text-align: center; padding: 6px 4px; }
  .hm-acts { width: 100%; }
  .hm-acts:empty { display: none; }
  .hm-pp { flex-basis: 100%; }
  .hm-desk-only { display: none; }
  .hm-phone-only { display: inline-block; }
  .hm .btn.small { padding: 7px 12px; font-size: 14px; }
  .drag-handle { display: none; }
}


/* ---- "ההגדרות שלי" (Nov 2026 redesign – same look as the settings center) ---- */
.me-page { display: flex; flex-direction: column; gap: var(--gap); }
.me-page .card { margin-bottom: 0; }
.me-who { display: flex; align-items: center; gap: 14px; }
.me-avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 19px; flex: none; }
.me-title { display: flex; flex-direction: column; gap: 2px; }
.me-title h1 { margin: 0; line-height: 30px; }
.me-shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); gap: 24px; align-items: start; }
.me-nav { display: flex; flex-direction: column; gap: 2px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; position: sticky; top: 12px; }
.me-nav a { display: grid; grid-template-columns: 1fr auto; column-gap: 8px; padding: 8px 12px; border-radius: 8px; color: var(--ink); }
.me-nav a:hover { background: #eef0f3; text-decoration: none; }
.me-nav a[aria-current="page"] { background: var(--brand-soft); }
.me-nav .t { font-weight: 500; }
.me-nav a[aria-current="page"] .t { color: var(--brand); font-weight: 600; }
.me-nav .s { grid-column: 1; font-size: 13px; line-height: 16px; color: var(--muted); }
.me-nav .s.warn { color: var(--warn); }
.me-nav i { grid-column: 2; grid-row: 1 / 3; align-self: center; font-style: normal; color: var(--muted); display: none; }
.me-col { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.me-back { display: none; }
.me-h2 { margin: 0 0 4px; font-size: 17px; line-height: 24px; font-weight: 600; }
.me-sec .hint { font-size: 14px; line-height: 18px; color: var(--muted); }
.me-sec p.hint { margin: 4px 0; }
.me-row { display: flex; justify-content: space-between; align-items: center; gap: 8px 20px; padding: 10px 0; border-top: 1px solid var(--line); flex-wrap: wrap; margin: 0; }
.me-h2 + .me-row, .me-sec > input[type=hidden] + .me-h2 + .me-row { border-top: 0; }
label.me-row { cursor: pointer; }
.me-row .txt { display: flex; flex-direction: column; min-width: 0; flex: 1 1 260px; }
.me-row .acts { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.me-row form.inline { display: inline; }
.me-row input.me-in-s { width: 150px; }
.me-row input.me-in-m { width: 240px; }
.me-save { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 0; margin-top: 4px; border-top: 1px solid var(--line); flex-wrap: wrap; position: sticky; bottom: 0; background: var(--panel); }   /* long lists (התראות): the save button stays in view */
.me-how { margin-top: 6px; }
.me-how > summary { cursor: pointer; font-size: 14px; color: var(--muted); }
.me-how p { font-size: 14px; line-height: 20px; color: var(--muted); margin: 6px 0 0; }
.me-os { display: flex; align-items: center; justify-content: space-between; gap: 8px 14px; flex-wrap: wrap; padding: 12px 14px; margin: 8px 0; border: 1px solid var(--line); border-radius: 8px; background: #f7f8fa; }
.me-os .txt { display: flex; flex-direction: column; flex: 1 1 240px; }
.me-os .copyline { flex: 1 1 100%; }
.me-phone-note { display: none; }
/* switches (real checkboxes – the form posts exactly as before) */
input.switch { appearance: none; -webkit-appearance: none; position: relative; width: 36px; height: 20px; margin: 0; border-radius: 999px; background: #c4c9d0; cursor: pointer; flex: none; transition: background .15s; vertical-align: middle; }
input.switch::after { content: ""; position: absolute; top: 2px; right: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .2); transition: right .15s; }
input.switch:checked { background: var(--brand); }
input.switch:checked::after { right: 18px; }
input.switch:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* segmented choice (real radio buttons) */
.seg-radio { display: inline-flex; padding: 2px; gap: 2px; background: #eef0f3; border-radius: 8px; flex-wrap: wrap; }
.seg-radio label { margin: 0; cursor: pointer; }
.seg-radio input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg-radio span { display: inline-block; font-size: 14px; line-height: 20px; color: var(--muted); padding: 3px 12px; border-radius: 6px; }
.seg-radio input:checked + span { background: var(--panel); color: var(--ink); font-weight: 500; box-shadow: 0 1px 2px rgba(27, 34, 48, .12); }
.seg-radio input:focus-visible + span { outline: 2px solid var(--accent); }
.me-ntbl { width: 100%; border-collapse: collapse; }
.me-ntbl th { font-size: 13px; font-weight: 600; color: var(--muted); text-align: right; padding: 6px 0; }
.me-ntbl th.c, .me-ntbl td.c { text-align: center; width: 84px; }
.me-ntbl td { padding: 9px 0; border-top: 1px solid var(--line); }
.me-ntbl tr.g td { font-size: 13px; font-weight: 600; color: var(--muted); padding-top: 14px; border-top: 0; }
@media (max-width: 900px) {
  .me-shell { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .me-nav { position: static; padding: 0; overflow: hidden; }
  .me-nav a { min-height: 60px; align-content: center; padding: 10px 14px; border-top: 1px solid var(--line); border-radius: 0; }
  .me-nav a:first-child { border-top: 0; }
  .me-nav a[aria-current="page"] { background: transparent; }
  .me-nav i { display: block; }
  /* with JS: the list alone, or one topic with a back link */
  .me-js:not(.me-list) .me-nav, .me-js:not(.me-list) .me-who { display: none; }
  .me-js:not(.me-list) .me-back { display: inline-flex; align-items: center; min-height: 44px; font-weight: 500; }
  .me-js.me-list .me-col { display: none; }
  .me-row .acts, .me-row .acts input { width: 100%; }
  .me-row .acts input { flex: 1; width: auto; min-height: 40px; }
  .me-row .seg-radio { display: flex; width: 100%; }
  .me-row .seg-radio label { flex: 1; text-align: center; }
  .me-row .seg-radio span { display: block; padding: 7px 4px; }
  .me-save .btn { flex: 1; text-align: center; }
  .me-ntbl th.c, .me-ntbl td.c { width: 64px; }
  #pc .me-phone-note { display: block; color: var(--warn); }
}

/* ---- finance (Nov 2026 redesign – /finance and the case "כספים" tab, same look as the home screen) ---- */
.fin-tiles { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.hm-tile b.bad, .fin b.bad, .fcase b.bad { color: var(--bad); }
.hm-tile small { font-size: 13px; line-height: 16px; }
.fin-tabs { align-self: flex-start; }
.fin-tab-bad { color: var(--bad); }
.fin-pane[hidden] { display: none; }
.fin-pane { display: flex; flex-direction: column; gap: var(--gap); }
.fin-pane > .card { margin-bottom: 0; }
.fin-cols { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: var(--gap); align-items: start; }
.fin-col { display: flex; flex-direction: column; gap: var(--gap); min-width: 0; }
.fin-col > .card { margin-bottom: 0; }
.fin-tbl th { font-size: 13px; font-weight: 600; color: var(--muted); }
.fin-tbl tr.off td { color: var(--muted); }
.fin-search { width: 180px; padding: 5px 10px; font-size: 14px; }
.fin-bars { display: flex; flex-direction: column; }
.fin-bar { display: grid; grid-template-columns: minmax(110px, 1.1fr) minmax(0, 1fr) 92px; gap: 10px; align-items: center; padding: 7px 0; border-top: 1px solid var(--line); }
.fin-bar:first-child { border-top: 0; }
.fin-bar .bar { height: 10px; border-radius: 999px; background: #eef0f3; overflow: hidden; }
.fin-bar .bar i { display: block; height: 100%; border-radius: 999px; background: var(--brand); }
.fin-bar .bar i.bad { background: var(--bad); }
.fin-bar .bar i.mute { background: #c4c9d0; }
.fin-bar b { text-align: left; font-weight: 500; font-variant-numeric: tabular-nums; }
.fin-bar.sum { border-top: 2px solid var(--line); }
.fin-bar.sum b, .fin-bar.sum span { font-weight: 600; }
.fin-note { margin: 8px 0 0; }
.fin-note > summary { cursor: pointer; }
.fin-cols12 { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 6px; align-items: end; height: 110px; padding-top: 8px; }
.fin-cols12 .col { height: 100%; display: flex; align-items: flex-end; }
.fin-cols12 i { display: block; width: 100%; background: var(--brand); opacity: .8; border-radius: 4px 4px 0 0; min-height: 2px; }
.fin-cols12 i.cur { background: var(--accent); opacity: 1; }
.fin-lbl12 { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 6px; font-size: 12px; color: var(--muted); text-align: center; padding-top: 4px; }
.fin-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 20px; padding: 10px 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.fin-strip .k { font-size: 13px; color: var(--muted); }
.fin-strip-act { margin-inline-start: auto; }
.fin-wide { flex-basis: 100%; margin: 0; }
.fin-client { border: 1px solid var(--line); border-radius: 8px; padding: 0 12px 8px; margin-top: 10px; }
.fin-client-h { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; }
.fin-client .tbl { margin: 0; }
.fin-sum { display: flex; align-items: center; gap: 8px; cursor: pointer; }
/* case finance tab */
.fcase { display: flex; flex-direction: column; gap: var(--gap); margin-top: var(--gap); min-width: 0; }
.fcase .card { margin-bottom: 0; }
.fin-top { display: grid; grid-template-columns: minmax(170px, 1fr) minmax(0, 2.2fr) auto; gap: 8px 24px; align-items: center; }
.fin-top-bal { display: flex; flex-direction: column; }
.fin-top-bal > .lbl { font-size: 13px; font-weight: 500; color: var(--muted); }
.fin-top-kv { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.fin-top-kv .fin-kv { flex-direction: column; justify-content: flex-start; gap: 2px; border-top: 0; border-inline-start: 1px solid var(--line); padding: 2px 12px; }
.fin-top-kv .fin-kv .k { font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.fin-top-kv .fin-kv .v { font-weight: 600; white-space: nowrap; }
.fin-top-kv .fin-kv .v small { font-weight: 400; }
.fin-top .fin-acts { flex-direction: column; margin-top: 0; }
.fin-top + .fin-notebox { margin-bottom: var(--gap); }
.fin-big { font-size: 31px; line-height: 38px; font-weight: 700; font-variant-numeric: tabular-nums; }
.fin-big.due { color: var(--bad); }
.fin-big.ok { color: var(--ok); }
.fin-prog { height: 8px; border-radius: 999px; background: #eef0f3; overflow: hidden; margin: 6px 0 8px; }
.fin-prog i { display: block; height: 100%; background: var(--ok); border-radius: 999px; }
.fin-kv { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-top: 1px solid var(--line); color: var(--ink); font-variant-numeric: tabular-nums; }
.fin-kv .k { color: var(--muted); }
.fin-kv .k small { font-size: 12px; }
a.fin-kv:hover { text-decoration: none; background: #f7f8fa; }
.fin-kv.sum { border-top: 2px solid var(--line); font-weight: 600; }
.fin-kv.sum .k { color: var(--ink); }
.hm-sec-h + .fin-kv { border-top: 0; }
.fin-acts { display: flex; gap: 8px; margin-top: 10px; }
.fin-acts .btn { flex: 1; text-align: center; }
.fin-notebox { padding: 10px 12px; border-radius: 8px; background: var(--brand-soft); font-size: 14px; line-height: 20px; }
.fin-gap { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; margin-bottom: 8px; border-radius: 8px; background: var(--warn-soft); color: var(--warn); font-size: 14px; }
.btn.fin-danger { color: var(--bad); }
.hm-sec-h .actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.hm-sec-h .actions form { display: inline; margin: 0; }
@media (max-width: 1100px) {
  .fin-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .fin-cols { grid-template-columns: minmax(0, 1fr); }
  .fin-top { grid-template-columns: minmax(0, 1fr); }
  .fin-top .fin-acts { flex-direction: row; }
}
@media (max-width: 900px) {
  .fin-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fin-tabs { align-self: stretch; flex-wrap: wrap; }
  .fin-tabs a { flex: 1 1 auto; }
  .fin-tbl { display: block; overflow-x: auto; max-width: calc(100vw - 70px); }
  .fin-bar { grid-template-columns: 80px minmax(0, 1fr) 84px; }
  .fin-bar small { display: none; }
  .fin-search { width: 100%; }
  .fin-acts .btn { padding: 10px 12px; }
  .fin-top-kv { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .fin-top-kv .fin-kv { flex-direction: row; justify-content: space-between; border-inline-start: 0; border-top: 1px solid var(--line); padding: 7px 0; }
}

/* institution mail – attachments menu, floating folder explorer (Nov 2026) */
.att-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.att-menu { position: relative; }
.att-menu > summary { list-style: none; cursor: pointer; padding: 4px 10px; border: 1px solid var(--line, #ddd); border-radius: 8px; font-size: 14px; }
.att-menu > summary::-webkit-details-marker { display: none; }
.att-menu[open] > summary { background: var(--soft, #f3f4f6); }
.att-opts { position: absolute; z-index: 20; top: calc(100% + 4px); right: 0; min-width: 190px; background: var(--card, #fff);
  border: 1px solid var(--line, #ddd); border-radius: 8px; box-shadow: 0 6px 20px rgba(0,0,0,.12); padding: 6px; display: flex; flex-direction: column; gap: 2px; }
.att-opts a, .att-opts button.link { display: block; text-align: right; padding: 6px 8px; border-radius: 6px; text-decoration: none; }
.att-opts a:hover, .att-opts button.link:hover { background: var(--soft, #f3f4f6); }
.warn-text { color: #b45309; }
dialog.explorer { width: min(560px, calc(100vw - 32px)); border: 1px solid var(--line, #ddd); border-radius: 12px; padding: 16px; direction: rtl;
  background: var(--card, #fff); color: inherit; }
dialog.explorer::backdrop { background: rgba(0,0,0,.35); }
dialog.explorer form { display: flex; flex-direction: column; gap: 10px; }
.ex-head, .ex-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.ex-crumbs { font-size: 14px; }
.ex-list { max-height: 45vh; overflow: auto; border: 1px solid var(--line, #ddd); border-radius: 8px; padding: 6px; display: flex; flex-direction: column; gap: 2px; }
.ex-dir { text-align: right; background: none; border: 0; padding: 7px 8px; border-radius: 6px; cursor: pointer; font: inherit; color: inherit; }
.ex-dir:hover { background: var(--soft, #f3f4f6); }
.ex-file { padding: 4px 8px; font-size: 14px; }
.ex-new { display: flex; gap: 6px; }
.ex-new input { flex: 1; }
/* built-in attachment viewer (institution mail, Nov 2026) */
dialog.viewer { width: min(1100px, calc(100vw - 24px)); height: calc(100vh - 40px); max-height: none; padding: 0; border: 1px solid var(--line, #ddd);
  border-radius: 12px; direction: rtl; background: var(--card, #fff); color: inherit; overflow: hidden; }
dialog.viewer[open] { display: flex; flex-direction: column; }
dialog.viewer::backdrop { background: rgba(0,0,0,.55); }
.vw-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 14px; border-bottom: 1px solid var(--line, #ddd); }
.vw-head b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 50%; }
.vw-acts { display: flex; gap: 6px; flex-wrap: wrap; }
.vw-body { flex: 1; min-height: 0; background: #525659; display: flex; align-items: safe center; justify-content: safe center; overflow: auto; }
.vw-body img { max-width: 100%; max-height: 100%; object-fit: contain; }
.vw-pages { align-self: flex-start; margin: 0 auto; padding: 16px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.vw-pages canvas { background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.35); max-width: none; }
.vw-text { align-self: stretch; margin: 0; padding: 16px; background: #fff; white-space: pre-wrap; overflow-wrap: anywhere; width: 100%; }
.vw-msg { color: #fff; padding: 24px; text-align: center; }
.vw-msg.err { color: #fecaca; }
.vw-zoom { display: inline-flex; align-items: center; gap: 4px; }
.vw-zoom[hidden] { display: none; }
@media (max-width: 900px) { dialog.viewer { width: 100vw; height: 100vh; max-width: 100vw; border-radius: 0; } .vw-head b { max-width: 100%; } }
/* attachments of an outgoing mail (case mail / institution mail reply, Nov 2026) */
.att-box { border: 1px dashed var(--line, #cbd5e1); border-radius: 10px; padding: 10px 12px; margin: 8px 0; }
.att-box.drag { border-color: var(--accent); background: rgba(44, 79, 130, .06); }
.att-drop { font-size: 15px; }
.att-pc { cursor: pointer; position: relative; color: var(--accent); }
.att-pc input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.att-chosen { list-style: none; margin: 6px 0 0; padding: 0; font-size: 14px; }
.att-chosen li { padding: 2px 0; overflow-wrap: anywhere; }
.att-limit.err { color: #b91c1c; font-weight: 600; }
.ex-pick { display: flex; align-items: center; gap: 6px; cursor: pointer; color: inherit; }
.ex-pick input { width: auto; }
dialog.explorer .ex-form { display: flex; flex-direction: column; gap: 10px; }

/* ---- cases list on the phone (Nov 2026): each case is a small card – name, topic, status + next deadline.
   "מטפל" and "נפתח" are hidden there (desktop unchanged); a "מיון" select replaces the hidden column titles. ---- */
.cs-msort { display: none; }
@media (max-width: 900px) {
  .filters { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  .filters select { width: 100%; min-height: 40px; }
  .filters .muted { grid-column: 1 / -1; font-size: 14px; }
  .cs-msort { display: block; }
  #cases-tbl { display: block; padding: 0; }
  #cases-tbl thead { display: none; }
  #cases-tbl tbody { display: block; }
  #cases-tbl tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--line); }
  #cases-tbl tr:last-child { border-bottom: 0; }
  #cases-tbl td { display: block; padding: 0; border: 0; min-width: 0; }
  #cases-tbl .c-name { grid-column: 1 / -1; font-size: 17px; font-weight: 600; }
  #cases-tbl .c-name a { color: var(--ink); }
  #cases-tbl .c-topic { grid-column: 1 / -1; font-size: 14px; color: var(--muted); margin-top: -2px; }
  #cases-tbl .c-topic:empty, #cases-tbl .c-topic.dup { display: none; }   /* dup = already part of the case name */
  #cases-tbl .c-status select { width: auto; max-width: 100%; min-height: 36px; font-size: 14px; }
  #cases-tbl .c-next { text-align: left; font-size: 14px; display: flex; flex-direction: column; align-items: flex-end; line-height: 1.3; white-space: normal; }
  #cases-tbl .c-next .c-date { font-weight: 600; }
  #cases-tbl .c-handler, #cases-tbl .c-opened { display: none; }
}

/* ---- case screen (Nov 2026 redesign – header with "⋯", small tiles, per-card edit, grouped deadlines, folded
   גורמים, two-pane mail, day timeline; the finance tab has its own .fin-* rules) ---- */
.chead { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 14px; }
.chead .who { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.chead .who h1 { margin: 0; }
.chead .crumb { font-size: 13px; color: var(--muted); }
.chead .crumb a { color: inherit; }
.chead .subl { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; color: var(--muted); font-size: 14px; }
.cacts { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.cacts form { margin: 0; }
.cacts .ph-only { display: none; }
.cmore .menu-list { padding: 6px; min-width: 240px; display: flex; flex-direction: column; }
.cmore .menu-list form { margin: 0; }
.cmore .mi, .cmore .menu-list a { display: block; width: 100%; text-align: right; font: inherit; font-size: 15px; border: 0; background: transparent; padding: 8px 10px; border-radius: 6px; color: var(--ink); cursor: pointer; text-decoration: none; }
.cmore .mi:hover, .cmore .menu-list a:hover { background: var(--bg); }
.cmore .mi-del summary { list-style: none; }
.cmore .mi-del summary::-webkit-details-marker { display: none; }
.cmore .danger-text { color: var(--bad); }
.cmore .mi-form { display: flex; flex-direction: column; gap: 8px; padding: 6px 10px 10px; }
.cstrip { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-bottom: 14px; }
.cs { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; display: flex; flex-direction: column; gap: 1px; color: var(--ink); text-decoration: none; min-width: 0; }
.cs:hover { text-decoration: none; border-color: #c4c9d0; }
.cs .lbl { font-size: 13px; color: var(--muted); }
.cs .v { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs .v.dim { color: #b3b9c2; font-weight: 500; }
.cs .s { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs.bad .v { color: var(--bad); }
nav.tabs.ctabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
nav.tabs.ctabs::-webkit-scrollbar { display: none; }
nav.tabs.ctabs a { white-space: nowrap; }
.tcnt { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px; box-sizing: border-box; border-radius: 999px; background: #eef0f3; color: var(--muted); font-size: 12px; font-weight: 600; vertical-align: middle; }
.tcnt.bad { background: var(--bad-soft, #fdecec); color: var(--bad); }
.edit-bar { display: flex; gap: 6px; justify-content: flex-start; margin-bottom: 10px; }
.card-editing { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.card .card-head h3 { margin: 0; }
.card .card-head { margin-bottom: 10px; gap: 8px; }
.hd-acts { display: flex; gap: 6px; align-items: center; }
.h3-sum { cursor: pointer; font-weight: 600; font-size: 17px; }
details.card[open] > .h3-sum { margin-bottom: 10px; }
/* rows (deadlines, side) */
.dl-rows .grp-h, .cside .grp-h { display: flex; justify-content: space-between; padding: 12px 0 4px; font-size: 13px; font-weight: 600; color: var(--muted); border-top: 1px solid var(--line); }
.dl-rows .grp-h:first-child { border-top: 0; padding-top: 0; }
.dl-rows .grp-h.warn { color: var(--warn); }
.dl-rows .grp-h.today { color: var(--brand); }
.dl-rows .hrow, .cside .hrow { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.dl-rows .grp-h + .hrow, .cside .rows > .hrow:first-child { border-top: 0; }
.dl-rows .hrow .t, .cside .hrow .t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.dl-rows .ttl, .cside .ttl { font-weight: 500; }
.dl-rows .meta, .cside .meta { font-size: 14px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; }
.dl-rows .acts { flex: none; display: flex; gap: 6px; align-items: center; }
.dl-rows .acts form { margin: 0; }
.dl-rows .done .ttl, .dl-rows .cancel .ttl { color: var(--muted); }
.dbox { flex: none; width: 44px; height: 44px; border-radius: 8px; background: #eef0f3; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.1; font-variant-numeric: tabular-nums; }
.dbox b { font-size: 16px; }
.dbox span { font-size: 12px; color: var(--muted); }
.dbox.today { background: var(--brand-soft); color: var(--brand); }
.dbox.today span { color: var(--brand); }
.dbox.past { background: var(--warn-soft); color: var(--warn); }
.dbox.past span { color: var(--warn); }
.dbox.done { opacity: .55; }
/* tasks */
form.quick-add { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 10px 12px; border-style: dashed; }
form.quick-add .grow { flex: 1; min-width: 200px; }
form.quick-add select, form.quick-add input[type=date] { width: auto; }
.task-card h3 { display: flex; align-items: center; gap: 8px; }
/* side */
.cside .card h3 { margin-top: 0; }
.kvr { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-top: 1px solid var(--line); font-size: 15px; }
.side-contact h3 + .kvr { border-top: 0; }
/* גורמים */
.ggrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); align-items: start; }
.ggrid .card { margin-bottom: 0; }
.ggrid:not(:empty) { margin-bottom: var(--gap); }
.unl-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.g-chip summary { list-style: none; }
.g-chip summary::-webkit-details-marker { display: none; }
.chipbtn { display: inline-block; font-size: 14px; border: 1px dashed #c4c9d0; border-radius: 999px; padding: 3px 12px; cursor: pointer; color: var(--ink); background: #fff; }
.g-chip[open] { flex-basis: 100%; }
.g-chip[open] .chipbtn { border-style: solid; background: var(--brand-soft); color: var(--brand); }
.g-chip-body { margin-top: 8px; padding: 10px 12px; background: var(--bg); border-radius: 8px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.g-chip-body form { width: 100%; }
/* mail */
.mtools { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; }
.mtools .subtabs { margin: 0; }
.mchips a { padding: 4px 12px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); text-decoration: none; font-size: 14px; }
.mchips a.on { background: var(--brand-soft); border-color: transparent; color: var(--brand); font-weight: 600; }
.mailw { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: var(--gap); align-items: start; margin-top: 10px; }
.mlist { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; max-height: 75vh; overflow-y: auto; }
.mitem { display: flex; flex-direction: column; gap: 1px; padding: 10px 12px; border-top: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.mitem:first-child { border-top: 0; }
.mitem:hover { background: var(--bg); text-decoration: none; }
.mitem.on { background: var(--brand-soft); }
.mitem.unread .s, .mitem.unread .sj { font-weight: 700; }
.mitem .top2 { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; }
.mitem .s { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mitem .sj { font-size: 15px; }
.mitem .p { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mempty { padding: 12px; margin: 0; }
.mread { min-width: 0; }
.mread .m-back { display: none; }
/* history */
.tl { display: flex; flex-direction: column; }
.tl .grp-h { padding: 12px 0 4px; font-size: 13px; font-weight: 600; color: var(--muted); border-top: 1px solid var(--line); }
.tl .grp-h:first-child { border-top: 0; padding-top: 0; }
.tli { display: grid; grid-template-columns: 44px 70px minmax(0, 1fr); gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); align-items: baseline; }
.tl .grp-h + .tli { border-top: 0; }
.tli .tm { font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; direction: ltr; text-align: right; }
.tli .tw { min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 1100px) {
  .ggrid { grid-template-columns: minmax(0, 1fr); }
  .mailw { grid-template-columns: 240px minmax(0, 1fr); }
}
@media (max-width: 900px) {
  .chead { flex-direction: column; gap: 10px; }
  .cacts { justify-content: flex-start; width: 100%; }
  .cacts .ph-only { display: inline-block; }
  .cacts > .btn, .cacts > details > summary.btn { padding: 9px 12px; }
  .cmore .menu-list { left: auto; right: 0; }
  .cstrip { display: flex; overflow-x: auto; gap: 8px; scrollbar-width: none; margin: 0 -14px 12px; padding: 0 14px; }
  .cstrip .cs { flex: 0 0 auto; min-width: 150px; max-width: 70vw; }
  nav.tabs.ctabs { position: sticky; top: 0; z-index: 5; background: var(--page, var(--bg)); margin: 0 -14px; padding: 0 10px; }
  nav.tabs.ctabs a { padding-top: 12px; padding-bottom: 12px; }
  .dl-rows .hrow { flex-wrap: wrap; }
  .dl-rows .acts { width: 100%; padding-inline-start: 56px; }
  form.quick-add > * { flex: 1 1 100%; }
  form.quick-add select, form.quick-add input[type=date] { width: 100%; }
  .mailw { grid-template-columns: minmax(0, 1fr); }
  .mailw.has-thread .mlist { display: none; }
  .mread .m-back { display: inline-block; }
  .tli { grid-template-columns: 40px minmax(0, 1fr); }
  .tli .ty { display: none; }
  .cside { order: 2; }
}

/* "stay in place" toast – the save message when the page came back scrolled (app.js, kadlaw-keep-scroll) */
.flash.toast { position: fixed; z-index: 60; bottom: 20px; inset-inline-start: 50%; transform: translateX(50%); margin: 0; max-width: min(520px, calc(100vw - 32px)); box-shadow: 0 8px 24px rgba(27,34,48,.18); cursor: pointer; transition: opacity .35s; }
.flash.toast.out { opacity: 0; }
@media (max-width: 900px) { .flash.toast { bottom: 12px; inset-inline-start: 16px; inset-inline-end: 16px; transform: none; max-width: none; } }

/* finance → morning: filters above the unlinked payers lists (letter / text / only linkable) */
.ul-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-bottom: 10px; }
.ul-bar input[type=search] { flex: 1 1 220px; max-width: 340px; }
.ul-letters { display: flex; flex-wrap: wrap; gap: 4px; }
.ul-letters button { min-width: 30px; padding: 4px 8px; border: 1px solid var(--line); background: var(--panel); border-radius: 6px; cursor: pointer; font: inherit; font-size: 14px; color: var(--ink); }
.ul-letters button.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.ul-letters button:disabled { opacity: .35; cursor: default; }
tr.ul-row[hidden] { display: none; }

/* ---- WhatsApp (Nov 2026): the chat tab, the inbox, the floating "הודעה חדשה", the QR card */
.waw { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: var(--gap); align-items: start; margin-top: 10px; }
.waw.inbox { grid-template-columns: 320px minmax(0, 1fr); }
.wa-thread { max-height: 60vh; overflow-y: auto; padding: 8px 4px; background: #f3f6f4; border-radius: 10px; display: flex; flex-direction: column; gap: 6px; }
.wa-thread.tall { max-height: 70vh; }
.wa-day { align-self: center; margin: 6px 0 2px; }
.wa-day span { background: #e2e8e4; color: #456; font-size: .78rem; padding: 2px 10px; border-radius: 999px; }
.wa-msg { max-width: 78%; padding: 6px 10px; border-radius: 12px; background: #fff; box-shadow: 0 1px 1px rgba(0,0,0,.06); font-size: .95rem; }
.wa-msg.in { align-self: flex-start; border-start-start-radius: 2px; }
.wa-msg.out { align-self: flex-end; background: #dcf4d6; border-start-end-radius: 2px; }
.wa-text { white-space: pre-wrap; word-break: break-word; }
.wa-who { font-size: .78rem; font-weight: 600; color: #2a7; margin-bottom: 2px; }   /* who wrote it, in a work group */
.chips-pick { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 4px 0; }
.chips-pick .chk { background: #f4f7f9; border: 1px solid #dfe6ea; border-radius: 14px; padding: 3px 10px; }

.wa-meta { display: flex; gap: 8px; justify-content: flex-end; font-size: .72rem; color: #678; margin-top: 2px; }
.wa-file img { max-width: 260px; max-height: 260px; border-radius: 8px; display: block; }
.wa-file .att-menu summary { cursor: pointer; }
.wa-reply { margin-top: 10px; }
.wa-reply .row, .wa-draft .row { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 6px; flex-wrap: wrap; }
.wa-reply textarea { min-height: 54px; }
.wa-draft { border: 1px dashed var(--line); border-radius: 10px; padding: 8px 10px; margin-top: 8px; background: #fffbe8; }
.wa-unfiled li { display: flex; align-items: center; gap: 8px; justify-content: space-between; flex-wrap: wrap; }
.wa-tools { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.wa-list .mitem { display: block; }
.wa-unm { flex-wrap: wrap; }
.wa-unm-acts { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.wa-qr { text-align: center; padding: 10px; }
.wa-qr img { width: 260px; height: 260px; image-rendering: pixelated; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
#wa-toasts { position: fixed; bottom: 16px; left: 16px; z-index: 1200; display: flex; flex-direction: column; gap: 8px; max-width: min(360px, 90vw); }
.wa-toast { display: flex; gap: 10px; align-items: center; background: #1f6f4a; color: #fff; padding: 10px 12px; border-radius: 12px; box-shadow: 0 6px 20px rgba(0,0,0,.25); text-decoration: none; animation: wa-in .25s ease-out; }
.wa-toast:hover { background: #185a3c; color: #fff; }
.wa-toast-ic { font-size: 1.4rem; }
.wa-toast-b { display: flex; flex-direction: column; min-width: 0; }
.wa-toast-b small { opacity: .9; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }
.wa-toast-x { background: transparent; border: 0; color: #fff; cursor: pointer; font-size: 1rem; margin-inline-start: auto; }
@keyframes wa-in { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
@media (max-width: 900px) {
  .waw, .waw.inbox { grid-template-columns: minmax(0, 1fr); }
  .wa-msg { max-width: 92%; }
  #wa-toasts { left: 8px; right: 8px; bottom: 70px; max-width: none; }
}
/* נט המשפט (Nov 2026): the home banner, the case card and the waiting list */
.flash.court-banner { font-size: 1.05em; padding: 12px 16px; border-inline-start: 5px solid currentColor; }
.flash.court-banner a { margin-inline-start: 8px; }
.flash.court-banner.court-fleet { transition: opacity .8s ease, max-height .8s ease, margin .8s ease, padding .8s ease; max-height: 300px; overflow: hidden; }
.flash.court-banner.court-fade { opacity: 0; max-height: 0; margin: 0; padding-top: 0; padding-bottom: 0; }
.court-ok { margin: -4px 0 12px; }
tr.court-new td { background: var(--ok-soft); }
.court-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; padding: 10px 0; border-top: 1px solid var(--line); }
.court-row:first-of-type { border-top: 0; }
.court-code { font-size: 1.6em; letter-spacing: .12em; font-weight: 700; direction: ltr; display: inline-block; padding: 6px 14px; border: 2px dashed var(--line); border-radius: 8px; }
pre.court-cmd { direction: ltr; text-align: left; background: #f4f5f7; padding: 10px 12px; border-radius: 8px; overflow-x: auto; font-size: .85em; }

.court-up input[type=file] { max-width: 150px; font-size: .82em; }
tr.court-wait td { background: var(--warn-soft); }

/* time tracking (Nov 2026): the running-timer chip in the top bar, the subtle "start timer" pulse in a case, the "שעות" tab */
.timer-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 6px 4px 10px; border: 1px solid #b7dfc4; background: #eefaf2; border-radius: 999px; font-size: 14px; max-width: min(520px, 60vw); }
.timer-chip .tc-dot { width: 8px; height: 8px; border-radius: 50%; background: #1f9d55; animation: tc-blink 1.6s ease-in-out infinite; flex: none; }
.timer-chip .tc-el { font-variant-numeric: tabular-nums; }
.timer-chip .tc-lbl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; color: inherit; }
.timer-chip .tc-menu { position: relative; flex: none; }
.timer-chip .tc-form { padding: 10px; min-width: 260px; display: flex; flex-direction: column; gap: 8px; }
.timer-chip .tc-stop { display: flex; flex-direction: column; gap: 8px; }
@keyframes tc-blink { 50% { opacity: .35; } }
.btn.timer-cta { animation: tt-pulse 1.4s ease-in-out 3; }
@keyframes tt-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(31,157,85,0); } 50% { box-shadow: 0 0 0 5px rgba(31,157,85,.22); border-color: #1f9d55; } }
.btn.timer-on { border-color: #b7dfc4; background: #eefaf2; }
.tt-sum { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 10px; }
.tt-sum > div { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 2px; }
.tt-sum > div.est { background: var(--bg); }
.tt-sum b { font-size: 23px; font-variant-numeric: tabular-nums; }
.tt-sum small { color: var(--muted); }
.tt-add { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.tt-add .grow { flex: 1 1 200px; min-width: 0; }
.tt-add select, .tt-add input[type=date] { width: auto; }
.tt-add .tt-min { width: 140px; }
.tt-wrap { overflow-x: auto; max-width: 100%; }
.tt-tbl td { vertical-align: top; }
.hm-head-acts { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tt-arow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 6px 0; border-top: 1px solid var(--line); }
.tt-arow:first-child { border-top: 0; }
.tt-arow .tt-what { flex: 1 1 200px; min-width: 0; }
.tt-assign { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.tt-assign select { max-width: 280px; }
@media (max-width: 900px) {
  .timer-chip { max-width: 100%; }
  .timer-chip .tc-form { position: fixed; left: 12px; right: 12px; top: auto; min-width: 0; }
  .tt-add > *, .tt-add .tt-min, .tt-add select { flex: 1 1 100%; width: 100%; }
  .tt-assign select { max-width: 100%; flex: 1 1 100%; }
}

/* קליטת לידים – /settings/leads */
.inb-copy { display: flex; gap: 8px; align-items: center; margin: 6px 0 10px; }
.inb-copy .inb-key { flex: 1; min-width: 0; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; }
.inb-h3 { font-size: 16px; margin: 18px 0 8px; }
.inb-form { border: 1px solid var(--line, #e5e7eb); border-radius: 10px; padding: 10px 12px; margin: 10px 0; }
.inb-form .card-head { gap: 8px; flex-wrap: wrap; }
.inb-row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; margin-top: 10px; }
.inb-row .fld { flex: 1 1 220px; margin: 0; }
@media (max-width: 900px) { .inb-copy { flex-wrap: wrap; } .inb-copy .btn { width: 100%; } }

/* "שכחתי סיסמה" (Nov 2026) */
.auth-forgot { align-self: center; }
.auth-links { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 10px; margin-top: 12px; }
.auth-links .inline-note { margin: 0; }
.auth-alt { margin-top: 12px; gap: 8px; }
.auth-alt p { margin: 0; }

/* eye button inside password fields (app.js) */
.pw-wrap { position: relative; display: block; }
.pw-wrap > input { width: 100%; padding-left: 40px; }
.pw-eye { position: absolute; left: 4px; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; display: grid; place-items: center;
  border: 0; background: transparent; color: var(--muted); border-radius: 6px; cursor: pointer; padding: 0; }
.pw-eye:hover { color: var(--ink); background: #eef0f3; }
.pw-eye:focus-visible { outline: 2px solid var(--accent); }

/* search box in long dropdowns (app.js) */
.ssel-pop { position: fixed; z-index: 3000; background: var(--panel); color: var(--ink); border: 1px solid var(--line);
  border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.18); display: flex; flex-direction: column; overflow: hidden; }
.ssel-q { margin: 8px; width: auto !important; box-sizing: border-box; }
.ssel-list { overflow-y: auto; padding: 0 4px 6px; flex: 1; min-height: 0; }
.ssel-opt { padding: 7px 10px; border-radius: 6px; cursor: pointer; text-align: right; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ssel-opt:hover, .ssel-opt.act { background: var(--brand-soft); }
.ssel-opt.sel { font-weight: 600; }
.ssel-opt.sel::before { content: '✓ '; }
.ssel-opt.ph { color: var(--muted, #667085); }
.ssel-opt.dis { opacity: .45; cursor: default; }
.ssel-grp { padding: 8px 10px 4px; font-size: .82em; color: var(--muted, #667085); font-weight: 600; }
.ssel-empty { padding: 10px; color: var(--muted, #667085); text-align: center; }
.ssel-mf { display: block; width: 100%; box-sizing: border-box; margin-bottom: 4px; }
@media (max-width: 900px) { .ssel-opt { padding: 11px 12px; } }

/* WhatsApp inbox (/wa, 19.11.2026 – canvas page "WhatsApp"): list next to the open conversation, like WhatsApp Web */
.wahead .badge::before { display: none; }
.wab { display: grid; grid-template-columns: 340px minmax(0, 1fr); border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); overflow: hidden; height: calc(100vh - 190px); min-height: 520px; }
.walist { border-left: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; }
.walist .lh { padding: 12px; display: flex; flex-direction: column; gap: 10px; border-bottom: 1px solid var(--line); }
.wa-search input { width: 100%; }
.fchips { display: flex; gap: 6px; flex-wrap: wrap; }
.fchip { font-size: 14px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); border-radius: 999px; padding: 3px 10px; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.fchip:hover { text-decoration: none; background: var(--bg); }
.fchip[aria-current="true"] { background: var(--brand-soft); border-color: transparent; color: var(--brand); font-weight: 600; }
.fchip .n { font-size: 12px; font-weight: 600; min-width: 18px; height: 18px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; background: #eef0f3; color: var(--muted); padding: 0 5px; }
.fchip .n.g { background: #25a35a; color: #fff; }
.fchip .n.w { background: var(--warn-soft); color: var(--warn); }
.witems { overflow-y: auto; flex: 1; }
.witem { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 10px; padding: 10px 12px; border-top: 1px solid var(--line); align-items: center; color: var(--ink); }
.witem:first-child { border-top: 0; }
.witem:hover { background: var(--bg); text-decoration: none; }
.witem.on { background: var(--brand-soft); }
.wab .av { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 15px; background: #dcefe3; color: #1f6f4a; flex: none; }
.wab .av.lead { background: var(--brand-soft); color: var(--accent); }
.wab .av.unk { background: var(--warn-soft); color: var(--warn); }
.wab .av.sm { width: 36px; height: 36px; font-size: 14px; }
.witem .b { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.witem .l1, .witem .l2 { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.witem .nm { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.witem.unread .nm { font-weight: 700; }
.witem .tm { font-size: 13px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.witem.unread .tm { color: #1f8a4c; font-weight: 600; }
.witem .pv { font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.witem.unread .pv { color: var(--ink); }
.witem .l3 { display: flex; gap: 6px; align-items: center; white-space: nowrap; overflow: hidden; min-height: 16px; }
.ucnt { min-width: 20px; height: 20px; border-radius: 10px; background: #25a35a; color: #fff; font-size: 12px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; padding: 0 6px; flex: none; }
.wab .pill { font-size: 12px; line-height: 16px; padding: 0 7px; border-radius: 999px; background: #eef0f3; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wab .pill.lead { background: var(--brand-soft); color: var(--accent); }
.wab .pill.unk { background: var(--warn-soft); color: var(--warn); }
.wab .pill.draft { background: #fff4c2; color: #8a6100; }
.wa-none { padding: 16px; }

.wachat { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.wch { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--line); }
.wch .who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.wch .who b { font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wch .who b a { color: var(--ink); }
.wch .who .s { font-size: 13px; color: var(--muted); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.wch .acts { display: flex; gap: 6px; align-items: center; flex: none; }
.wch .back { display: none; font-size: 25px; line-height: 1; color: var(--brand); padding: 0 4px; }
.wch .back:hover { text-decoration: none; }
.wa-casebtn { background: #e7f6ec; border-color: #bfe3cb; color: #1f6f4a; font-weight: 600; }
.wa-casebtn:hover { background: #d6efdf; text-decoration: none; }
.wa-more .menu-list { min-width: 200px; }

.wbody { display: flex; flex: 1; min-height: 0; }
.wmain { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.wthread { flex: 1; overflow-y: auto; padding: 16px 24px; background: #efeae2; display: flex; flex-direction: column; gap: 6px; }
.wday { align-self: center; background: #fff; color: #54656f; font-size: 13px; padding: 3px 12px; border-radius: 8px; box-shadow: 0 1px 1px rgba(0,0,0,.06); margin: 8px 0 4px; }
.bub { max-width: 62%; padding: 6px 10px 4px; border-radius: 10px; background: #fff; box-shadow: 0 1px 1px rgba(0,0,0,.08); font-size: 15px; line-height: 20px; }
.bub.in { align-self: flex-start; border-top-right-radius: 2px; }
.bub.out { align-self: flex-end; background: #d9fdd3; border-top-left-radius: 2px; }
.bub .wtext { white-space: pre-wrap; word-break: break-word; }
.bub .bmeta { display: flex; gap: 6px; justify-content: flex-end; font-size: 12px; color: #667781; margin-top: 2px; align-items: center; }
.bub .ck.read { color: #53bdeb; }
.bub .ck.fail { color: var(--bad); }
.bub .wimg img { max-width: 260px; max-height: 260px; border-radius: 8px; display: block; margin-bottom: 4px; }
.fbox { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 8px; background: rgba(0,0,0,.04); margin-bottom: 4px; }
.fbox .ic { min-width: 34px; height: 40px; border-radius: 4px; background: #e9584f; color: #fff; font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex: none; padding: 0 3px; }
.fbox .fn { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.fbox .fn b { font-weight: 500; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fbox .fn span { font-size: 12px; color: #667781; }
.fbox .fa { display: flex; gap: 4px; flex: none; }
.fbox .fa a { font-size: 13px; padding: 2px 6px; border-radius: 6px; background: #fff; border: 1px solid var(--line); color: var(--brand); white-space: nowrap; }
.fbox .fa a:hover { text-decoration: none; background: var(--bg); }
.bub .filed { font-size: 12px; color: var(--ok); margin-bottom: 2px; }

.wcomp { border-top: 1px solid var(--line); padding: 10px 16px 12px; background: #f7f8f9; }
.wcomp .box { display: flex; gap: 8px; align-items: flex-end; }
.wcomp textarea { flex: 1; resize: none; min-height: 44px; max-height: 160px; padding: 10px 14px; border: 1px solid #c4c9d0; border-radius: 20px; font: inherit; background: #fff; }
.wcomp .send { width: 44px; height: 44px; border-radius: 50%; border: 0; background: #1f8a4c; color: #fff; font-size: 19px; cursor: pointer; flex: none; }
.wcomp .send:hover { background: #18703d; }
.wcomp .send[disabled] { background: #c4c9d0; cursor: default; }
.wcomp .tools { display: flex; gap: 14px; align-items: center; font-size: 14px; color: var(--muted); margin-top: 8px; flex-wrap: wrap; }
.wcomp .tools .grow { flex: 1; }
.wcomp .tools select { font-size: 13px; }
.wcomp .tools input[type=file] { display: none; }

.linkbox { margin: 12px 16px; border: 1px solid #f3d19e; background: #fffaf0; border-radius: var(--radius); padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.linkbox .row2 { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.linkbox .row2 select { flex: 1; min-width: 220px; }
.draftbox { align-self: flex-end; width: 62%; border: 1.5px dashed #d4a72c; background: #fffbe6; border-radius: 10px; padding: 8px 10px; display: flex; flex-direction: column; gap: 6px; }
.draftbox .dh { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; color: #8a6100; }
.draftbox textarea { border: 1px solid #ecd692; border-radius: 8px; padding: 6px 8px; font: inherit; resize: vertical; background: #fff; width: 100%; }
.draftbox .da { display: flex; gap: 6px; justify-content: flex-end; }
.emptychat { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--muted); background: #f7f8f9; text-align: center; padding: 20px; }
.emptychat .big { font-size: 41px; }

.wside { width: 260px; flex: none; border-right: 1px solid var(--line); padding: 14px; display: flex; flex-direction: column; gap: 16px; overflow-y: auto; }
.wside h3 { margin: 0 0 4px; font-size: 15px; display: flex; gap: 6px; align-items: center; }
.wside .blk { display: flex; flex-direction: column; gap: 6px; }
.wside .kv { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; }
.wside .kv span:first-child { color: var(--muted); }
.wside .fl { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wside select { width: 100%; }

@media (max-width: 1200px) { .wside { display: none; } }
@media (max-width: 900px) {
  .wab { grid-template-columns: minmax(0, 1fr); height: auto; min-height: 0; border-radius: var(--radius); }
  .wab.has-one .walist { display: none; }
  .wab:not(.has-one) .wachat { display: none; }
  .walist { border-left: 0; }
  .fchips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 -12px; padding: 0 12px; }
  .witem { padding: 12px; }
  .wab.has-one { margin: 0 -16px; border-radius: 0; border-left: 0; border-right: 0; }
  .wab.has-one .wachat { height: calc(100vh - 120px); height: calc(100dvh - 120px); }
  .wch { padding: 8px 10px; gap: 8px; position: sticky; top: 0; z-index: 3; background: var(--panel); }
  .wch .back { display: inline-block; }
  .wch .d-only, .wcomp .d-only { display: none; }
  .wa-casebtn { padding: 6px 10px; }
  .wthread { padding: 12px; }
  .bub, .draftbox { max-width: 84%; }
  .draftbox { width: 84%; }
  .wcomp { padding: 8px 10px 10px; }
  .wcomp .send { width: 46px; height: 46px; }
  .linkbox { margin: 10px; }
  .linkbox .row2 select { min-width: 0; width: 100%; }
  .wahead .cacts { display: none; }
  .wahead.wa-open { display: none; }
}

/* ---------------------------------------------------------------- remote signing (esign, Nov 2026) */
.es-st { background: var(--brand-soft); color: var(--brand); }
.es-st-done { background: var(--ok-soft); color: var(--ok); }
.es-st-cancelled { background: #eee; color: var(--muted); }
.es-st-final, .es-st-partial { background: var(--warn-soft); color: var(--warn); }
.es-ss-signed { background: var(--ok-soft); color: var(--ok); }
.es-ss-skipped { background: #eee; color: var(--muted); }
.es-ss-opened { background: var(--brand-soft); color: var(--brand); }
.es-signers tr.es-fin td { background: #fafbfd; }
.es-signers details.task-edit form { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.es-signers details.task-edit form.grid { display: grid; }
.es-menu { display: inline-block; }
.es-done { background: var(--ok-soft); border-radius: var(--radius); padding: 10px 12px; margin: 8px 0; }
.es-save { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.es-save .grow { min-width: 200px; flex: 1; }
.es-log { margin-top: 8px; }
.es-cancel { margin-top: 8px; }
.es-picker { border: 0; border-radius: var(--radius); padding: 0; width: min(560px, 94vw); box-shadow: 0 10px 40px rgba(0,0,0,.25); }
.es-picker-in { padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.es-dirs { max-height: 50vh; overflow: auto; border: 1px solid var(--line); border-radius: 8px; padding: 4px 10px; margin: 0; }
.es-dirs li { padding: 5px 0; list-style: none; }
.es-docs { margin: 10px 0; padding: 0; }
.es-doc { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; margin-bottom: 6px; list-style: none; background: var(--panel); }
.es-doc .grow { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.es-doc .es-n { color: var(--muted); width: 1.6em; }
.es-signer { border: 1px solid var(--line); border-radius: 8px; padding: 10px; margin-bottom: 8px; }
.es-opts { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin-top: 14px; }
.es-opts .lbl { display: block; margin-bottom: 4px; }
.es-bar { position: sticky; bottom: 0; display: flex; justify-content: flex-end; gap: 8px; padding: 12px 0; background: var(--page, var(--bg)); }

/* editor */
.es-editor { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: var(--gap); align-items: start; }
.es-tools { position: sticky; top: 12px; display: flex; flex-direction: column; gap: 10px; }
.es-kinds { display: flex; flex-wrap: wrap; gap: 6px; }
.es-sel { border-top: 1px solid var(--line); padding-top: 8px; }
.es-sel h4 { margin: 0 0 6px; font-size: 14px; }
.es-legend { font-size: 13px; line-height: 1.9; }
.es-dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-left: 6px; vertical-align: -1px; }
.btn.wide { width: 100%; justify-content: center; }
.es-pages { display: flex; flex-direction: column; align-items: center; gap: 14px; min-width: 0; }
.es-page { position: relative; background: #fff; box-shadow: 0 1px 6px rgba(0,0,0,.15); max-width: 100%; }
.es-page canvas { width: 100%; height: 100%; display: block; }
.es-ov { position: absolute; inset: 0; }
.es-pages.adding .es-ov { cursor: crosshair; }
.es-box { position: absolute; border: 2px solid; border-radius: 4px; display: flex; align-items: center; justify-content: center; font-size: 12px; cursor: move; touch-action: none; overflow: hidden; }
.es-box .es-lbl { pointer-events: none; padding: 0 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.es-box.on { box-shadow: 0 0 0 3px rgba(37,99,235,.35); }
.es-box.ghost { opacity: .45; }
.es-rs { position: absolute; left: -1px; bottom: -1px; width: 12px; height: 12px; background: currentColor; cursor: nesw-resize; border-radius: 0 3px 0 3px; }
.es-c0 { border-color: #2563eb; color: #2563eb; background: rgba(37,99,235,.12); } .es-dot.es-c0 { background: #2563eb; }
.es-c1 { border-color: #db2777; color: #db2777; background: rgba(219,39,119,.12); } .es-dot.es-c1 { background: #db2777; }
.es-c2 { border-color: #059669; color: #059669; background: rgba(5,150,105,.12); } .es-dot.es-c2 { background: #059669; }
.es-c3 { border-color: #d97706; color: #d97706; background: rgba(217,119,6,.12); } .es-dot.es-c3 { background: #d97706; }
.es-c4 { border-color: #7c3aed; color: #7c3aed; background: rgba(124,58,237,.12); } .es-dot.es-c4 { background: #7c3aed; }
.es-c5 { border-color: #0891b2; color: #0891b2; background: rgba(8,145,178,.12); } .es-dot.es-c5 { background: #0891b2; }
@media (max-width: 900px) { .es-editor { grid-template-columns: 1fr; } .es-tools { position: static; } }

/* public signing page */
.auth:has(.es-sign) { max-width: 940px; margin-top: 2vh; }
.es-sign { display: flex; flex-direction: column; gap: 12px; padding-bottom: 80px; }
.es-sign-head { display: flex; align-items: center; justify-content: center; gap: 10px; font-weight: 600; }
.es-sign-head img { height: auto; }
.es-otp { background: var(--brand-soft); border-radius: var(--radius); padding: 10px 12px; }
.es-otp.flash-me { box-shadow: 0 0 0 3px var(--accent); }
.es-otp-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.es-otp-row input { width: 9em; font-size: 19px; letter-spacing: 3px; text-align: center; }
.ok-text { color: var(--ok); font-weight: 600; margin: 0; }
.es-box.es-mine { border-color: #2d4bd8; background: rgba(45,75,216,.10); color: #2d4bd8; cursor: pointer; }
.es-box.es-mine.done { background: transparent; border-style: dashed; border-color: rgba(45,75,216,.35); }
.es-box.es-mine img { max-width: 100%; max-height: 100%; }
.es-box.es-mine.done .es-lbl { display: none; }
.es-box.es-mine input:not([type=checkbox]) { width: 100%; height: 100%; border: 0; background: rgba(255,255,255,.7); padding: 0 3px; text-align: right; }
.es-box.pulse { animation: es-pulse 1.1s ease-out; }
@keyframes es-pulse { 0% { box-shadow: 0 0 0 0 rgba(45,75,216,.7); } 100% { box-shadow: 0 0 0 14px rgba(45,75,216,0); } }
.es-sign-bar { position: fixed; bottom: 0; left: 0; right: 0; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 10px 16px; background: var(--panel); box-shadow: 0 -2px 12px rgba(0,0,0,.12); z-index: 5; }
.es-sign-bar .btn { min-width: 220px; justify-content: center; font-size: 17px; padding: 10px 18px; }
.es-pad, .es-finish { border: 0; border-radius: var(--radius); padding: 0; width: min(620px, 96vw); box-shadow: 0 10px 40px rgba(0,0,0,.3); }
.es-pad-in { padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.es-canvas { width: 100%; aspect-ratio: 3 / 1; border: 2px solid #2d4bd8; border-radius: 6px; touch-action: none; background: #fff; }
.es-pad-in .actions { display: flex; gap: 8px; align-items: center; }
.es-pad-in .grow { flex: 1; }
.es-thanks h2 { color: var(--ok); }
.es-copy { display: flex; flex-direction: column; gap: 8px; }
.es-foot { text-align: center; }

/* remote signing – fixes (Nov 2026): ✕ on the selected box, the finisher banner, the per-signer "no SMS" line */
.es-box .es-x { position: absolute; top: -10px; left: -10px; width: 20px; height: 20px; border-radius: 50%; border: 0;
  background: #c0392b; color: #fff; font-size: 12px; line-height: 20px; padding: 0; cursor: pointer; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.es-box { overflow: visible; }
.flash.es-wait { background: #fff4d6; border: 1px solid #e8b931; color: #5c4400; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.es-wait-i { display: inline-flex; align-items: center; gap: 6px; }
.es-nosms-l { grid-column: 1 / -1; }

/* ---- work modes (Nov 2026): selector in the top bar, a colored band with a countdown, mode home screens, the queue */
.mode-menu { position: relative; }
.mode-menu .mode-sum.on { background: var(--accent); color: #fff; border-color: transparent; }
.mode-list { min-width: 300px; padding: 10px; display: grid; gap: 10px; right: 0; left: auto; }
.mode-opt { display: grid; gap: 4px; padding-bottom: 8px; border-bottom: 1px solid var(--line, #e5e7eb); }
.mode-quick { display: flex; flex-wrap: wrap; gap: 4px; }
.mode-band { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; padding: 8px 14px; border-radius: 8px; margin-bottom: 14px;
  background: #eef2ff; color: #1e3a8a; border-inline-start: 5px solid #4f46e5; }
.mode-band.mb-collection { background: #ecfdf5; color: #065f46; border-inline-start-color: #059669; }
.mode-band .mb-name { font-weight: 700; }
.mode-band .mb-left { font-variant-numeric: tabular-nums; }
.mode-band .mb-acts { margin-inline-start: auto; display: flex; gap: 6px; }
.mode-summary div { margin-top: 2px; }
.mode-form { display: grid; gap: 12px; max-width: 620px; padding: 16px; }
.mode-tasks { display: grid; gap: 4px; max-height: 280px; overflow: auto; }
.hm-mode .is-done .hm-ttl { text-decoration: line-through; color: var(--muted, #6b7280); }
.btn.big { font-size: 1.05em; padding: 10px 16px; }
.coll-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.coll-tiles b, .cq-nums b { font-size: 1.5em; }
.bad-text { color: var(--bad, #b91c1c); }
.ok-text { color: var(--ok, #047857); }
body.mode-collection .fin #late, body.mode-collection .fin #balances { font-size: 1.12em; }
body.mode-collection .fin #late { outline: 2px solid #059669; outline-offset: 2px; }
.cq-bar { height: 6px; background: var(--line, #e5e7eb); border-radius: 3px; overflow: hidden; margin-bottom: 14px; }
.cq-bar span { display: block; height: 100%; background: #059669; }
.cq-card { padding: 18px; display: grid; gap: 14px; font-size: 1.05em; }
.cq-who { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }
.cq-who h2 { margin: 0; font-size: 1.4em; }
.cq-nums { display: flex; gap: 22px; }
.cq-nums > div { display: grid; }
.cq-contact, .cq-acts { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-start; }
.cq-list { margin: 0; padding-inline-start: 18px; }
.cq-act > summary { list-style: none; cursor: pointer; }
.cq-act > summary::-webkit-details-marker { display: none; }
.cq-form { display: grid; gap: 8px; margin-top: 8px; min-width: 260px; }
@media (max-width: 900px) {
  .coll-tiles { grid-template-columns: 1fr; }
  .mode-band .mb-acts { margin-inline-start: 0; }
  .mode-list { min-width: 0; width: min(92vw, 340px); }
}

/* draft of a morning document before it is issued (invoice_confirm.html) */
.inv-draft { position: relative; max-width: 760px; margin: 12px auto; padding: 28px 28px 20px; background: #fff;
  border: 1px solid var(--line); border-radius: 6px; box-shadow: 0 2px 10px rgba(0,0,0,.06); overflow: hidden; }
.inv-draft-mark { margin: -28px -28px 16px; padding: 5px; text-align: center; background: var(--warn-soft); color: var(--warn);
  font-weight: 600; font-size: 13px; letter-spacing: .5px; }
.inv-draft-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; border-bottom: 2px solid var(--ink); padding-bottom: 10px; }
.inv-draft-type { font-size: 21px; font-weight: 700; }
.inv-draft-date { display: flex; flex-direction: column; align-items: flex-end; }
.inv-draft-to { display: flex; flex-direction: column; gap: 2px; margin: 14px 0; }
.inv-draft-to b { font-size: 17px; }
.inv-draft-tbl { margin-top: 10px; }
.inv-draft-tbl tfoot td { border-top: 1px solid var(--line); }
.inv-draft-total td { font-weight: 700; font-size: 16px; }
.inv-draft-desc { margin: 10px 0; }
.inv-draft-rem { margin-top: 14px; padding-top: 10px; border-top: 1px dashed var(--line); }
@media (max-width: 900px) { .inv-draft { padding: 22px 12px 14px; } .inv-draft-mark { margin: -22px -12px 12px; } }

/* case → כספים → יומן תשלומים: three buttons, each opens its form/panel below (one at a time) */
.fin-pick .btn.on { box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px var(--ink); }
.mc-panel .mc-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.mc-panel .mc-head .btn { margin-inline-start: auto; }
.mc-panel section.card { background: var(--panel); box-shadow: none; border: 1px solid var(--line); margin: 10px 0; }
.mc-panel h3 { margin-top: 0; }
.mc-panel .tbl { display: block; overflow-x: auto; }

/* ---- reports (Nov 2026) */
.rep-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.rep-tile { display: grid; gap: 4px; padding: 12px 14px; border: 1px solid var(--line, #e5e7eb); border-radius: 10px; color: var(--ink); background: #fff; }
.rep-tile:hover { border-color: var(--accent); text-decoration: none; }
.rep-quality .tbl { margin-top: 8px; }
.rep-h3 { margin: 14px 0 6px; font-size: 1em; }

/* ---------------------------------------------------------------- FocusTik login shell (Nov 2026) */
@font-face { font-family: "Rubik"; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url(/static/vendor/rubik/rubik-hebrew-wght-normal.woff2) format("woff2");
  unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: "Rubik"; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url(/static/vendor/rubik/rubik-latin-wght-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
.ft-shell { --ft-navy: var(--navy); --ft-gold: var(--gold); --ft-line: var(--line); --ft-muted: var(--muted); --ft-text: var(--ink);
  min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--ft-text);
  font-family: "Rubik", Arial, sans-serif; font-size: 16px; }
.ft-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; }
.ft-logo img { display: block; height: 58px; width: auto; }
.ft-switch { font-size: 15px; color: var(--ft-navy); text-decoration: none; }
.ft-switch:hover { text-decoration: underline; }
.ft-main { flex: 1; display: flex; justify-content: center; align-items: flex-start; padding: 32px 16px; }
.ft-card { width: 100%; max-width: 450px; background: #fff; border: 1px solid var(--ft-line); border-radius: 18px;
  padding: 44px 50px 50px; box-shadow: 0 10px 30px -18px rgba(31, 59, 99, .35); }
.ft-card .flash { margin: 0 0 18px; }
.ft-foot { text-align: center; font-size: 14px; color: var(--ft-muted); padding: 18px; }
.ft-mark { display: flex; justify-content: center; margin-bottom: 22px; }
.ft-mark img { border-radius: 13px; box-shadow: 0 4px 12px rgba(31, 59, 99, .18); }
.ft-h1 { font-size: 23px; font-weight: 700; text-align: center; margin: 0 0 30px; }
.ft-lbl { display: block; font-size: 16px; margin: 14px 0 6px; }
.ft-in, .ft-card .auth-card input:not([type=checkbox]):not([type=radio]) { width: 100%; height: 44px; border: 1px solid #cfd6e2; border-radius: 7px;
  padding: 0 12px; font: inherit; font-size: 16px; color: var(--ft-text); background: #fff; box-sizing: border-box; }
.ft-in:focus, .ft-card .auth-card input:focus { outline: none; border-color: #7f97bd; box-shadow: 0 0 0 3px var(--navy-ring); }
.ft-err { color: #c62828; font-size: 14px; margin-top: 6px; }
.ft-hint { display: inline-block; margin-top: 10px; font-size: 15px; color: var(--ft-navy); text-decoration: none; }
.ft-hint:hover { text-decoration: underline; }
.ft-btn, .ft-card .auth-card .btn.primary { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; height: 42px;
  margin-top: 24px; border: 0; border-radius: 8px; color: #fff; font: inherit; font-size: 16px; font-weight: 500; cursor: pointer;
  background: linear-gradient(180deg, var(--navy-2), var(--navy)); box-shadow: 0 1px 2px rgba(31, 58, 99, .35); }
.ft-btn:hover, .ft-card .auth-card .btn.primary:hover { filter: brightness(1.07); }
.ft-chip { display: table; margin: -12px auto 26px; padding: 9px 16px; border: 1px solid var(--ft-line); border-radius: 22px;
  background: #f5f7fb; font-size: 15px; color: #333; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* two steps with JS; without JS both are shown (and the "next" button / greeting are hidden) */
.ft-login:not(.js) .ft-next, .ft-login:not(.js) .ft-s2 .ft-h1, .ft-login:not(.js) .ft-chip { display: none; }
.ft-login.js .ft-s2, .ft-login.js.at-pw .ft-s1 { display: none; }
.ft-login.js.at-pw .ft-s2 { display: block; animation: ftfade .25s ease; }
@keyframes ftfade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
/* the other sign-in pages (2FA, forgot password, change password) inside the same card */
.ft-card .auth-card { border: 0; padding: 0; margin: 0; box-shadow: none; background: none; gap: 12px; }
.ft-card .auth-card h2 { font-size: 23px; font-weight: 700; text-align: center; margin: 0 0 10px; }
.ft-card .auth-card + .auth-card { border-top: 1px solid var(--ft-line); padding-top: 20px; margin-top: 22px; }
.ft-card .auth-card .btn.primary { margin-top: 10px; }
.ft-card a { color: var(--ft-navy); }
@media (max-width: 520px) {
  .ft-head { padding: 14px 16px; }
  .ft-logo img { height: 46px; }
  .ft-main { padding: 12px 16px 24px; }
  .ft-card { padding: 32px 22px 36px; border-radius: 16px; }
}
.ft-card .pw-wrap > input { padding-left: 42px !important; }

/* ================================================================ app shell & controls (22.11.2026)
   ClickPress-style: full-width white top bar, icon side menu, soft 1px frames, pill tabs, quiet hovers.
   Colours only from the :root tokens (navy / gold). */
.auth-brand { text-align: center; margin-bottom: 8px; }
.auth-brand img { max-width: 100%; height: auto; }
.auth-brand div { font-size: 14px; font-weight: 600; color: var(--gold); }
body { background: var(--page, #ffffff); font-family: "Rubik", -apple-system, "Segoe UI", Arial, "Noto Sans Hebrew", sans-serif; }
.ic { display: block; flex: none; }

/* top bar */
.appbar { position: sticky; top: 0; z-index: 40; height: 60px; display: flex; align-items: center; gap: 16px; padding: 0 20px;
  background: var(--panel); border-bottom: 1px solid var(--line); }
.ab-logo img { display: block; height: 40px; width: auto; }
.ab-search { flex: 1; max-width: 520px; display: flex; align-items: center; margin-inline-start: 24px; }
.ab-search .ic { position: absolute; inset-inline-start: 12px; color: var(--muted); pointer-events: none; }
.ab-search input { height: 38px; padding-inline-start: 38px; border-radius: 10px; background: var(--panel); }
.ab-tools { display: flex; align-items: center; gap: 6px; margin-inline-start: auto; }
.ib, .bell { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px;
  border-radius: 10px; border: 0; background: transparent; color: var(--muted); cursor: pointer; transition: background .15s, color .15s; }
.ib:hover, .bell:hover { background: var(--bg); color: var(--ink); text-decoration: none; }
.bell b { position: absolute; top: 3px; inset-inline-end: 2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px;
  background: var(--bad); color: #fff; font-size: 11.5px; font-weight: 600; line-height: 17px; text-align: center; box-shadow: 0 0 0 2px var(--panel); }
.mode-menu .mode-sum { display: inline-flex; align-items: center; gap: 6px; height: 34px; border-color: transparent; color: var(--muted); background: transparent; }
.mode-menu .mode-sum:hover { background: var(--bg); color: var(--ink); }
.mode-menu summary::-webkit-details-marker { display: none; }
/* account chip + menu */
.acct { position: relative; margin-inline-start: 6px; }
.acct > summary { list-style: none; }
.acct > summary::-webkit-details-marker { display: none; }
.acct-chip { display: flex; align-items: center; gap: 10px; padding: 4px 8px 4px 10px; border-radius: 12px; cursor: pointer; color: var(--muted); transition: background .15s; }
.acct-chip:hover, .acct[open] .acct-chip { background: var(--bg); }
.acct-av { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: none;
  background: var(--navy); color: #fff; font-size: 14px; font-weight: 600; letter-spacing: .3px; }
.acct-txt { display: flex; flex-direction: column; line-height: 1.2; }
.acct-txt b { color: var(--ink); font-size: 14.5px; font-weight: 600; }
.acct-txt small { font-size: 12.5px; color: var(--muted); }
.acct[open] .acct-chip > .ic { transform: rotate(180deg); }
.acct-chip > .ic { transition: transform .15s; }
.acct-list { left: 0; right: auto; min-width: 250px; }
.ph-search { display: none; }
.acct-head { display: flex; align-items: center; gap: 10px; padding: 10px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.acct-head > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.acct-head small { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; }
.acct-list a, .acct-list button.link { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border-radius: 8px;
  color: var(--ink); font: inherit; font-size: 15px; text-align: start; text-decoration: none; transition: background .15s; }
.acct-list a .ic, .acct-list button .ic { color: var(--muted); }
.acct-list a:hover, .acct-list button.link:hover { background: var(--bg); text-decoration: none; }

/* layout + side menu */
.shell { display: flex; min-height: calc(100vh - 60px); }
.side { width: var(--side-w, 228px); flex-shrink: 0; background: var(--panel); border-left: 1px solid var(--line); padding: 16px 12px;
  display: flex; flex-direction: column; position: sticky; top: 60px; height: calc(100vh - 60px); overflow-y: auto; }
.side nav a { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 10px; color: var(--ink); margin-bottom: 2px;
  font-size: 15.5px; white-space: nowrap; overflow: hidden; transition: background .15s, color .15s; }
.side nav a span { overflow: hidden; text-overflow: ellipsis; }
.side nav a .ic { color: var(--muted); transition: color .15s; }
.side nav a:hover { background: var(--bg); text-decoration: none; }
.side nav a:hover .ic { color: var(--ink); }
.side nav a.on { background: var(--navy-soft); color: var(--navy); font-weight: 600; }
.side nav a.on .ic { color: var(--navy); }
.side .sep { font-size: 12.5px; color: var(--muted); padding: 16px 12px 6px; }
.side-office { margin-top: auto; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 8px 4px; border-top: 1px solid var(--line); text-align: center; }
.side-office img { max-width: 120px; max-height: 56px; width: auto; height: auto; opacity: .9; }
.side-office span { font-size: 12.5px; color: var(--muted); line-height: 1.3; }
.side-office:hover { text-decoration: none; }
main { padding: 24px 32px 60px; }

/* controls: soft frames, quiet hovers */
.card { border-color: var(--line); border-radius: 12px; box-shadow: none; transition: border-color .18s, box-shadow .18s, background-color .18s; }
/* hover lights the box up (22.11.2026): cards get a soft frame + glow; tiles also get a light navy fill */
.card:hover { border-color: var(--navy-ring); box-shadow: 0 2px 10px rgba(31, 59, 99, .06); }
.stat, .hm-tile, .set-tile, .rep-tile, .cs { transition: border-color .18s, box-shadow .18s, background-color .18s; }
.stat:hover, .hm-tile:hover, .set-tile:hover, .rep-tile:hover, .cs:hover {
  border-color: var(--navy-ring); background: #f7f9fd; box-shadow: 0 2px 10px rgba(31, 59, 99, .07); text-decoration: none; }
.card.gaps:hover { background: var(--warn-soft); }
@media (hover: none) { .card:hover, .stat:hover, .hm-tile:hover, .set-tile:hover, .rep-tile:hover, .cs:hover { box-shadow: none; } }
input, select, textarea { border-color: var(--field); border-radius: 8px; transition: border-color .15s, box-shadow .15s; }
input:hover, select:hover, textarea:hover { border-color: #b9c3d3; }
input:focus, select:focus, textarea:focus { outline: none; border-color: #7f97bd; box-shadow: 0 0 0 3px var(--navy-ring); }
input[type=checkbox], input[type=radio] { accent-color: var(--navy); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border-color: var(--field); border-radius: 8px; font-weight: 500;
  transition: background .15s, border-color .15s, color .15s, box-shadow .15s, filter .15s; }
.btn:hover { background: #f5f7fb; border-color: #b9c3d3; }
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--navy-ring); }
.btn.primary { border-color: var(--navy); box-shadow: 0 1px 2px rgba(31, 59, 99, .3); }
.btn.primary:hover { background: linear-gradient(180deg, var(--navy-2), var(--navy)); filter: brightness(1.08); }
.btn.danger:hover { filter: brightness(1.08); background: var(--bad); }
.btn.ghost { border-color: transparent; }
/* tabs: pill on the active one, soft grey on hover (ClickPress) */
.tabs { gap: 4px; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.tabs a { padding: 7px 14px; border-radius: 8px; border-bottom: 0; color: var(--ink); transition: background .15s, color .15s; }
.tabs a:hover { background: var(--bg); color: var(--ink); }
.tabs a.on { background: var(--navy-soft); color: var(--navy); border-bottom: 0; }
.subtabs a { background: transparent; color: var(--ink); border-radius: 8px; transition: background .15s, color .15s; }
.subtabs a:hover { background: var(--bg); }
.subtabs a.on { background: var(--navy-soft); color: var(--navy); font-weight: 600; }
/* tables: light header row, hairline rows */
table th { background: #f7f9fc; color: var(--muted); font-weight: 500; }
table td, table th { border-color: var(--line); }
tbody tr { transition: background .12s; }
tbody tr:hover { background: #fafbfd; }
/* drop-down menus */
.menu-list { border-color: var(--line); border-radius: 12px; box-shadow: 0 10px 30px -12px rgba(31, 59, 99, .25); padding: 6px; }
.menu-list a { transition: background .15s; }
h1 { font-weight: 700; letter-spacing: -.2px; }

/* phone */
.side-toggle { display: none; }
@media (max-width: 900px) {
  .appbar { height: 56px; gap: 8px; padding: 0 8px; }
  .ab-logo img { height: 32px; }
  .side-toggle { display: inline-flex; }
  .ab-search { display: none; }
  .ph-search { display: inline-flex; }
  /* the search icon opens the same search bar under the top bar (24.11.2026 – before, it only linked to an
     empty /search page with no input, so on a phone there was nowhere to type) */
  .appbar.ph-open .ab-search { display: flex; position: absolute; top: calc(100% + 6px); left: 8px; right: 8px; max-width: none; margin: 0;
    z-index: 45; border-radius: 12px; box-shadow: 0 10px 30px -12px rgba(31, 59, 99, .35); }
  .appbar.ph-open .ab-search input { height: 46px; font-size: 16px; }   /* 16px: iOS doesn't zoom the page on focus */
  .appbar.ph-open .ph-search { background: var(--navy-soft); color: var(--navy); }
  .search-sug { max-width: none; }
  .acct-txt, .acct-chip > .ic, .mode-menu .mode-sum span { display: none; }
  .acct-chip { padding: 2px; }
  .shell { flex-direction: column; min-height: 0; }
  .side { display: none; width: 100%; height: auto; position: sticky; top: 56px; z-index: 35; border-left: 0; border-bottom: 1px solid var(--line); padding: 8px; }
  .side.open { display: flex; }
  .side nav a { padding: 12px; }
  .side-office { display: none; }
  main { padding: 14px 16px 40px; }
}

/* ================================================================ reports (23.11.2026, after the FocusTik design)
   command bar · entity pills · collapsible filter workspace in three groups with chips · KPI strip · table. */
.rp { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.rp .card { margin: 0; border-radius: 16px; }
.rp-btn { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; border-radius: 12px; padding: 9px 14px; }
.rp-btn.small, .btn.small.rp-btn { padding: 6px 11px; }
.rp-soft { background: var(--navy-soft); border-color: var(--navy-ring); color: var(--navy); font-weight: 600; }
.rp-soft:hover { background: #dfe7f2; }
.rp-n { display: inline-block; min-width: 20px; padding: 1px 7px; border-radius: 999px; background: var(--navy); color: #fff; font-size: 12px; font-weight: 700; line-height: 18px; text-align: center; }
.rp-n.soft { background: var(--navy-soft); color: var(--navy); }
.linklike { background: none; border: 0; padding: 0; color: var(--navy-2); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.linklike:hover { text-decoration: underline; }

/* 1. command bar */
.rp-cmd { padding: 18px 20px; }
.rp-cmd-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.rp-crumb { display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; color: var(--navy-2); margin-bottom: 3px; }
.rp-crumb a { color: inherit; }
.rp-badge { background: var(--navy-soft); color: var(--navy); border: 1px solid var(--navy-ring); padding: 1px 8px; border-radius: 7px; max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-title { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.rp-title h1 { margin: 0; font-size: 25px; font-weight: 800; color: var(--ink); }
.rp-count { font-size: 15px; font-weight: 600; color: var(--muted); }
.rp-lead { margin: 4px 0 0; color: var(--muted); font-size: 14px; }
.rp-acts { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.rp-cmd-bottom { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding-top: 13px; }
.rp-ents { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.rp-ents a { flex: none; padding: 6px 14px; border-radius: 12px; font-size: 14px; font-weight: 600; color: var(--muted); transition: background .15s, color .15s; }
.rp-ents a:hover { background: var(--bg); color: var(--ink); text-decoration: none; }
.rp-ents a.on { background: var(--navy); color: #fff; font-weight: 700; }
.rp-quick { display: flex; align-items: center; gap: 6px; overflow-x: auto; scrollbar-width: none; font-size: 13px; }
.rp-quick-l { color: var(--muted); font-weight: 600; flex: none; font-size: 13px; }
.rp-pill { flex: none; padding: 3px 11px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink); background: #fff; max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; transition: border-color .15s, background .15s; }
.rp-pill:hover { border-color: var(--navy-ring); background: var(--navy-soft); text-decoration: none; }
.rp-pill.on { background: var(--navy-soft); border-color: var(--navy-ring); color: var(--navy); font-weight: 700; }

/* dropdown panels (templates, columns, multi-selects) */
details.rp-dd { position: relative; }
details.rp-dd > summary { list-style: none; cursor: pointer; }
details.rp-dd > summary::-webkit-details-marker { display: none; }
details.rp-dd[open] > summary .ic:last-child { transform: rotate(180deg); }
.rp-pop, .rms-panel { position: absolute; top: calc(100% + 6px); z-index: 30; background: #fff; border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, .12), 0 8px 10px -6px rgba(15, 23, 42, .08); padding: 12px; animation: rp-in .16s ease-out; }
@keyframes rp-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.rp-tpl-pop { inset-inline-start: 0; width: 460px; max-width: calc(100vw - 32px); }
.rp-tpl-q, .rms-q { width: 100%; background: var(--bg); border-radius: 10px; margin-bottom: 10px; font-size: 14px; }
.rp-tpl-body { max-height: 360px; overflow-y: auto; display: grid; gap: 14px; }
.rp-tpl-sec + .rp-tpl-sec { padding-top: 12px; border-top: 1px solid var(--line); }
.rp-tpl-h { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 7px; }
.rp-tpl-h small { font-weight: 400; }
.rp-tpl-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.rp-tpl-list li { display: flex; align-items: center; gap: 4px; }
.rp-tpl-a, .rp-tpl-p { flex: 1; min-width: 0; display: grid; gap: 1px; padding: 7px 10px; border-radius: 10px; border: 1px solid transparent; color: var(--ink); transition: background .15s, border-color .15s; }
.rp-tpl-a:hover, .rp-tpl-p:hover { background: var(--navy-soft); border-color: var(--navy-ring); text-decoration: none; }
.rp-tpl-a.on { background: var(--navy-soft); border-color: var(--navy-ring); }
.rp-tpl-a b, .rp-tpl-p b { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-tpl-a small, .rp-tpl-p small { font-size: 12px; color: var(--muted); }
.rp-tpl-x { flex: none; display: inline-flex; padding: 7px; border-radius: 9px; color: var(--muted); }
.rp-tpl-x:hover { background: var(--bg); color: var(--navy); }
.rp-tpl-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.rp-tpl-p { border-color: var(--line); }
.rp-tpl-empty { margin: 0; color: var(--muted); font-size: 13px; }
[data-q][hidden] { display: none !important; }

/* 2. filter workspace */
.rp-filters { padding: 0; }
.rp-fbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 16px; background: #f8fafc; border-bottom: 1px solid var(--line); border-radius: 16px 16px 0 0; }
.rp-filters.closed .rp-fbar { border-bottom: 0; border-radius: 16px; }
.rp-ftoggle { display: inline-flex; align-items: center; gap: 7px; background: none; border: 0; padding: 4px 2px; font: inherit; font-weight: 700; color: var(--ink); cursor: pointer; }
.rp-ftoggle:hover { color: var(--navy); }
.rp-ftoggle .ic:first-child { color: var(--navy-2); }
.rp-ftoggle .rp-n { background: var(--navy-soft); color: var(--navy); }
.rp-chev { display: inline-flex; color: var(--muted); transition: transform .2s; transform: rotate(180deg); }
.rp-filters.closed .rp-chev { transform: none; }
.rp-chips { display: flex; flex-wrap: wrap; gap: 6px; flex: 1; min-width: 200px; padding-inline-start: 10px; border-inline-start: 1px solid var(--line); }
.rp-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 4px 2px 10px; border-radius: 999px; background: #fff; border: 1px solid var(--navy-ring); color: var(--navy); font-size: 13px; font-weight: 600; max-width: 320px; }
.rp-chip-x { border: 0; background: none; width: 20px; height: 20px; border-radius: 50%; color: var(--muted); font-size: 16px; line-height: 1; cursor: pointer; padding: 0; flex: none; }
.rp-chip-x:hover { background: var(--bad-soft); color: var(--bad); }
.rp-nochips { color: var(--muted); font-size: 13px; }
.rp-fbar-end { display: flex; align-items: center; gap: 8px; margin-inline-start: auto; }
.rp-text { position: relative; display: flex; align-items: center; }
.rp-text .ic { position: absolute; inset-inline-start: 10px; color: var(--muted); pointer-events: none; }
.rp-text input { width: 230px; padding-inline-start: 32px; border-radius: 10px; background: #fff; font-size: 14px; }
.rp-cols-pop { inset-inline-end: 0; width: 270px; }
.rp-pop-h { display: flex; justify-content: space-between; align-items: center; padding-bottom: 8px; margin-bottom: 8px; border-bottom: 1px solid var(--line); font-size: 13px; font-weight: 700; }
.rp-clear { font-size: 13px; font-weight: 600; color: var(--muted); padding: 5px 10px; border-radius: 10px; }
.rp-clear:hover { color: var(--bad); background: var(--bad-soft); text-decoration: none; }
.rp-fbody { padding: 16px; display: grid; gap: 14px; }
.rp-fbody[hidden] { display: none; }
.rp-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; align-items: start; }
.rp-group { background: #f8fafc; border: 1px solid var(--line); border-radius: 16px; padding: 14px; display: grid; gap: 11px; min-width: 0; }
.rp-gh { margin: 0; display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 800; color: var(--navy); }
.rp-gh .dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot.d1 { background: var(--navy-2); } .dot.d2 { background: #0f766e; } .dot.d3 { background: var(--gold-light); }
.rp-ggrid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.rp-ggrid .fld { display: grid; gap: 4px; min-width: 0; }
.rp-ggrid .lbl { font-size: 13px; font-weight: 600; color: var(--muted); }
.rp-ggrid input, .rp-ggrid select { background: #fff; border-radius: 10px; font-size: 14px; }
.rp-span2 { grid-column: 1 / -1; }
.rp-row { display: flex; gap: 6px; align-items: center; }
.rp-row > * { flex: 1; min-width: 0; }
.rp-row[hidden] { display: none; }
.rp-fixed { font-size: 14px; color: var(--muted); }
.rms-sum { display: flex; align-items: center; justify-content: space-between; gap: 6px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 8px 11px; font-size: 14px; transition: border-color .15s; }
.rms-sum:hover, details.rms[open] .rms-sum { border-color: var(--navy-ring); }
.rms-l { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.rms-l b { color: var(--ink); font-weight: 600; }
details.rms:has(input:checked) .rms-sum { border-color: var(--navy-ring); background: var(--navy-soft); }
details.rms:has(input:checked) .rms-l b { color: var(--navy); }
.rms-sum .ic { color: var(--muted); flex: none; transition: transform .15s; }
.rms-panel { inset-inline-start: 0; width: 300px; max-width: calc(100vw - 32px); padding: 10px; }
.rms-opts { display: grid; gap: 1px; max-height: 240px; overflow-y: auto; }
.rms-opts .chk { padding: 5px 7px; border-radius: 8px; font-size: 14px; cursor: pointer; }
.rms-opts .chk:hover { background: var(--bg); }
.rms-opts .chk[hidden] { display: none; }
.rp-apply { display: flex; align-items: center; gap: 12px; }
.rp-apply .btn { border-radius: 12px; font-weight: 700; }
.rp-apply .btn.pulse { box-shadow: 0 0 0 4px var(--navy-ring); }
.rp-dirty { color: var(--warn); font-size: 13px; font-weight: 600; }

/* 3. KPI strip */
.rp-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; }
.rp-kpi { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 13px 10px; text-align: center; display: grid; gap: 3px; transition: border-color .18s, box-shadow .18s, background-color .18s; }
.rp-kpi:hover { border-color: var(--navy-ring); background: #f7f9fd; box-shadow: 0 2px 10px rgba(31, 59, 99, .07); }
.rp-kpi span { font-size: 13px; font-weight: 600; color: var(--muted); }
.rp-kpi b { font-size: 24px; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }
.rp-kpi b.acc { color: var(--navy-2); } .rp-kpi b.warn { color: var(--warn); } .rp-kpi b.bad { color: var(--bad); }

/* sections on the reports home / duplicates */
.rp-sec { padding: 18px 20px; }
.rp-h2 { margin: 0 0 12px; font-size: 17px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.rp-views { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.rp-views li { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 12px; transition: border-color .15s, background .15s; }
.rp-views li:hover { border-color: var(--navy-ring); background: #f7f9fd; }
.rp-views-a { flex: 1; min-width: 0; display: grid; gap: 1px; color: var(--ink); }
.rp-views-a:hover { text-decoration: none; }
.rp-views-a small { color: var(--muted); font-size: 13px; }
.rp-links a { margin-inline-end: 10px; }
.rp-empty-line { margin: 0; color: var(--muted); }

/* 4. table */
.rp-table { padding: 0; overflow: hidden; }
.rp-table .tbl-wrap { overflow: auto; max-height: 70vh; }
.rp-table .tbl th { position: sticky; top: 0; z-index: 1; background: #f8fafc; white-space: nowrap; padding: 11px 12px; font-size: 13px; font-weight: 700; border-bottom: 1px solid var(--line); }
.rp-table .tbl td { white-space: nowrap; padding: 10px 12px; font-size: 14px; border-bottom-color: #f1f4f8; }
.rp-table .tbl tbody tr { transition: background .12s; }
.rp-table .tbl tbody tr:hover td { background: #f7f9fd; }
.rp-table th a { color: inherit; display: inline-flex; align-items: center; gap: 5px; }
.rp-table th a:hover { color: var(--navy); text-decoration: none; }
.rp-table th a.on { color: var(--navy); }
.rp-sort { font-style: normal; font-size: 11px; color: #b6bfcc; }
.rp-table th a.on .rp-sort { color: var(--navy); }
.rp-tfoot { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 11px 16px; background: #f8fafc; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.rp-tfoot-e { display: flex; align-items: center; gap: 14px; }
.rp-tfoot-e a { display: inline-flex; align-items: center; gap: 5px; font-weight: 700; color: var(--navy); }
.rp-empty { padding: 48px 16px; text-align: center; display: grid; justify-items: center; gap: 6px; }
.rp-empty-i { width: 48px; height: 48px; border-radius: 16px; background: var(--bg); color: var(--muted); display: flex; align-items: center; justify-content: center; margin-bottom: 4px; }
.rp-empty h3 { margin: 0; font-size: 17px; }
.rp-empty p { margin: 0 0 8px; color: var(--muted); font-size: 14px; }

/* save-as-view dialog */
.rp-modal { border: 1px solid var(--line); border-radius: 18px; padding: 22px; width: 460px; max-width: calc(100vw - 32px); box-shadow: 0 25px 50px -12px rgba(15, 23, 42, .3); }
.rp-modal::backdrop { background: rgba(15, 23, 42, .45); backdrop-filter: blur(2px); }
.rp-modal[open] { animation: rp-in .18s ease-out; }
.rp-modal form { display: grid; gap: 14px; }
.rp-modal-h { display: flex; align-items: flex-start; gap: 11px; }
.rp-modal-h h3 { margin: 0; font-size: 18px; }
.rp-modal-h p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.rp-modal-h > div { flex: 1; }
.rp-modal-i { width: 38px; height: 38px; border-radius: 12px; background: var(--navy-soft); color: var(--navy); display: flex; align-items: center; justify-content: center; flex: none; }
.rp-x { border: 0; background: none; color: var(--muted); padding: 5px; border-radius: 9px; cursor: pointer; display: inline-flex; }
.rp-x:hover { background: var(--bg); color: var(--ink); }
.rp-modal .fld { display: grid; gap: 5px; }
.rp-modal .fld .lbl { font-size: 14px; font-weight: 600; }
.rp-modal input[name=name] { border-radius: 12px; padding: 10px 13px; }
.rp-modal-sum { background: #f8fafc; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font-size: 13px; color: var(--muted); line-height: 1.6; }
.rp-modal-sum b { color: var(--ink); }
.rp-modal-sum small { display: block; margin-top: 4px; font-size: 12px; }
.rp-modal-f { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding-top: 12px; border-top: 1px solid var(--line); }
.rp-modal-f .sp { flex: 1; }
.rp-modal-f .btn { border-radius: 12px; }

@media (max-width: 900px) {
  .rp-cmd, .rp-sec { padding: 14px; }
  .rp-title h1 { font-size: 21px; }
  .rp-acts { width: 100%; }
  .rp-acts > * { flex: 1 1 auto; }
  .rp-acts .rp-btn { justify-content: center; }
  .rp-tpl-pop { width: calc(100vw - 32px); }
  .rp-tpl-grid { grid-template-columns: 1fr; }
  .rp-fbar-end { width: 100%; margin: 0; }
  .rp-text { flex: 1; } .rp-text input { width: 100%; }
  .rp-chips { order: 3; flex-basis: 100%; border: 0; padding: 0; }
  .rp-ggrid { grid-template-columns: 1fr 1fr; }
  .rp-kpis { grid-template-columns: repeat(2, 1fr); }
  .rp-kpi b { font-size: 20px; }
  .rp-tfoot-e .muted { display: none; }
}
@media (max-width: 520px) { .rp-ggrid { grid-template-columns: 1fr; } .rp-groups { grid-template-columns: 1fr; } }
@media print { .rp-filters, .rp-acts, .rp-cmd-bottom, .rp-tfoot-e { display: none !important; } }

/* ---- home screen (23.11.2026, after the Gemini design): 7/5 grid, "דורש טיפול" with tabs, soft-tinted icons ---- */
/* soft icon tints – one muted family instead of bright blue / amber / indigo / emerald */
:root { --tn-navy: #eef2f8; --tn-navy-fg: #4d6489; --tn-gold: #f7f2e6; --tn-gold-fg: #957a43; --tn-plum: #f2f0f7;
  --tn-plum-fg: #6c6390; --tn-sage: #edf4f0; --tn-sage-fg: #50786a; --tn-rose: #f9efef; --tn-rose-fg: #a0565a; }
.t-navy { background: var(--tn-navy); color: var(--tn-navy-fg); }
.t-gold { background: var(--tn-gold); color: var(--tn-gold-fg); }
.t-plum { background: var(--tn-plum); color: var(--tn-plum-fg); }
.t-sage { background: var(--tn-sage); color: var(--tn-sage-fg); }
.t-rose { background: var(--tn-rose); color: var(--tn-rose-fg); }
.side nav a .ic { color: #8d96a6; }
.side nav a .ic path, .side nav a .ic rect, .side nav a .ic circle, .side nav a .ic polygon { stroke-width: 1.6; }

.hm2 .hm-head { align-items: center; }
.hm2 .hm-title h1 { font-size: 27px; line-height: 34px; }
.hm2 .hm-lead { align-self: flex-start; margin-top: 4px; padding: 1px 10px; border-radius: 999px; background: #fff; border: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.hm2 .hm-lead[data-warn] { background: var(--tn-gold); color: var(--tn-gold-fg); }
.hm2 .hm-head-acts { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hm2 .hm-head-acts .btn { display: inline-flex; align-items: center; gap: 6px; }
.hm-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--muted); font-size: 14px; white-space: nowrap; }
a.hm-chip:hover { text-decoration: none; border-color: var(--navy-ring); color: var(--ink); }
.hm-chip .dot { width: 8px; height: 8px; border-radius: 50%; background: #6ba58a; flex: none; }
.hm-chip.court-yellow .dot { background: #d4a24c; }
.hm-chip.court-red { color: var(--tn-rose-fg); border-color: #efd3d4; background: var(--tn-rose); }
.hm-chip.court-red .dot { background: #c8696d; }

.hm2 .hm-tile { padding: 16px 18px; }
.hm2 .hm-tile b { font-size: 29px; line-height: 34px; margin-top: 2px; }
.kp-ic { width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex: none; }

@media (min-width: 901px) { .cols.hm-cols.hm2-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); } }
.hm2-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.hm2-card > .hm-rows, .hm2-card > .hm-grp, .hm2-card > .hm-empty, .hm2-card > .hm-more,
.hm2-card .hm-pane > .hm-rows, .hm2-card .hm-pane > .hm-empty, .hm2-card .hm-pane > .hm-more { margin-inline: 18px; }
.hm2-card > .hm-rows:last-child, .hm2-card .hm-pane > .hm-rows:last-child { margin-bottom: 4px; }
.hm2-card .hm-empty { padding: 14px 0; margin-block: 0; }
.hm2-card .hm-more { padding-bottom: 10px; }
.hm2-h { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.hm2-h .title-group { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hm2-link { font-size: 14px; font-weight: 500; color: var(--navy-2); white-space: nowrap; }
.hm2-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 18px; border-top: 1px solid var(--line); background: #fafbfc; font-size: 14px; color: var(--muted); margin-top: auto; }
.hm2-foot b { color: var(--ink); }

/* "דורש טיפול" */
.at-tabs { display: flex; gap: 6px; padding: 10px 18px; border-bottom: 1px solid var(--line); background: #fafbfc; overflow-x: auto; scrollbar-width: none; }
.at-tabs button { font: inherit; font-size: 14px; border: 1px solid transparent; background: transparent; color: var(--muted); padding: 4px 12px; border-radius: 999px; cursor: pointer; white-space: nowrap; display: inline-flex; gap: 6px; align-items: center; }
.at-tabs button span { font-size: 12px; font-weight: 600; color: var(--muted); background: #eef0f3; border-radius: 999px; padding: 0 6px; }
.at-tabs button:hover { color: var(--ink); background: #f1f4f8; }
.at-tabs button.on { background: var(--navy-soft); color: var(--navy); font-weight: 600; }
.at-tabs button.on span { background: #fff; color: var(--navy); }
.at-list { display: flex; flex-direction: column; }
.at-grp { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 12px 18px 4px; font-size: 13px; font-weight: 600; color: var(--muted); }
.at-grp a { font-weight: 500; color: var(--navy-2); }
.at-grp[hidden], .at-row[hidden] { display: none; }
.at-row { display: flex; align-items: center; gap: 12px; padding: 10px 18px; color: var(--ink); border-top: 1px solid var(--line); transition: background .12s; }
.at-grp + .at-row { border-top: 0; }
.at-list > .at-row:first-child { border-top: 0; }
a.at-row:hover { text-decoration: none; background: #f8fafc; }
a.at-row:hover .at-go { color: var(--navy); }
.at-ic { width: 36px; height: 36px; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex: none; }
.at-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.at-t { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.at-t b { font-weight: 600; }
.at-sub { font-size: 14px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.at-meta { flex: none; font-size: 13px; color: var(--muted); white-space: nowrap; }
.at-go { flex: none; font-size: 14px; font-weight: 500; color: var(--navy-2); white-space: nowrap; padding: 4px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.at-empty { margin: 0; padding: 18px; color: var(--muted); text-align: center; }
.at-row.tt-arow { flex-wrap: wrap; }
.at-row.tt-arow .tt-assign { display: flex; gap: 6px; align-items: center; }
.at-row.tt-arow select { width: auto; max-width: 220px; }

/* tasks card: two panes behind a segmented switch */
.hm-tabseg { display: inline-flex; padding: 3px; gap: 2px; background: #f1f4f8; border: 1px solid var(--line); border-radius: 10px; }
.hm-tabseg button { font: inherit; font-size: 15px; border: 0; background: transparent; color: var(--muted); padding: 5px 12px; border-radius: 8px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.hm-tabseg button.on { background: #fff; color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgba(27, 34, 48, .1); }
.hm-tabseg .n { font-size: 12px; font-weight: 600; background: #e9edf2; color: var(--muted); border-radius: 999px; padding: 0 7px; }
.hm-tabseg .n.bad { background: var(--tn-rose); color: var(--tn-rose-fg); }
.hm-pane[hidden] { display: none; }
.hm2 .hm-task { align-items: center; }
.hm-done { flex: none; display: flex; }
.hm-check { width: 22px; height: 22px; padding: 0; border: 1.5px solid #c9d0da; border-radius: 6px; background: #fff; color: transparent; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all .15s; }
.hm-check:hover { border-color: var(--tn-sage-fg); color: var(--tn-sage-fg); background: var(--tn-sage); }
.hm-check .ic path { stroke-width: 2.4; }

/* deadlines: past meetings / filings with one-click status */
.dl-pend { margin: 12px 18px 4px; padding: 4px 12px; border: 1px solid #efe3c8; background: #fcf9f2; border-radius: 12px; }
.dl-pend-h { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; padding: 8px 0 4px; font-size: 13px; font-weight: 600; color: var(--tn-gold-fg); }
.dl-pend-h a { font-weight: 500; color: var(--navy-2); }
.dl-pend-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 0; border-top: 1px solid #efe3c8; }
.dl-pend-h + .dl-pend-row { border-top: 0; }
.dl-pend-acts { display: flex; gap: 6px; flex: none; }
.dl-pend-acts .btn { display: inline-flex; align-items: center; gap: 4px; }
.dl-pend-acts .btn.ok { background: var(--tn-sage); border-color: #cfe1d7; color: #2f6150; }
.dl-pend-acts .btn.ok:hover { background: #e2efe8; }

/* payments + leads */
.pay-amt { display: flex; align-items: center; gap: 8px; }
.pay-row .money { font-size: 18px; color: var(--ink); }
.lead-av { width: 32px; height: 32px; border-radius: 50%; background: var(--tn-navy); color: var(--tn-navy-fg); display: flex; align-items: center; justify-content: center; font-weight: 600; flex: none; }
.hm2 .lead-row { align-items: center; }

@media (max-width: 900px) {
  .hm2 .hm-head-acts { width: 100%; }
  .at-meta { display: none; }
  .at-go { padding: 3px 8px; }
  .hm2-h .hm-seg { width: 100%; overflow-x: auto; }
  .hm-tabseg { width: 100%; }
  .hm-tabseg button { flex: 1; justify-content: center; font-size: 14px; padding: 5px 6px; }
  .dl-pend-acts { width: 100%; }
  .dl-pend-acts .btn { flex: 1; justify-content: center; }
  .kp-ic { width: 34px; height: 34px; border-radius: 10px; }
  .hm-tabseg .n.bad { display: none; }          /* the late count stays on the rows (badges) – the switch fits the width */
  .at-t, .at-sub { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
}

/* search page field (24.11.2026) */
.search-page { display: flex; gap: 8px; max-width: 560px; margin: 0 0 16px; }
.search-page input { flex: 1; min-width: 0; height: 42px; font-size: 16px; }

/* ================================================================ task board (24.11.2026, after the Gemini design)
   _tasks.html – case tasks, מעקב גבייה, lead tasks. Quick-add bar · a card per task (round check, chips, inline edit)
   · a thread of steps with its own checks · "add next step" row · "בוצעו" folded. */
.tk { display: flex; flex-direction: column; gap: 12px; }
.tk .card { margin: 0; }
.tk-sec > .hm-sec-h { margin-bottom: 10px; }
.tk-add { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 16px; transition: border-color .15s, box-shadow .15s; }
.tk-add:focus-within { border-color: var(--navy-2); box-shadow: 0 0 0 3px var(--navy-ring); }
.tk-plus { width: 28px; height: 28px; border-radius: 8px; background: var(--navy-soft); color: var(--navy); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 18px; flex: none; }
.tk-add-text { flex: 1 1 260px; min-width: 0; border: 0 !important; outline: 0 !important; box-shadow: none !important; background: transparent; font-size: 16px; font-weight: 500; padding: 6px 2px; }
.tk-add-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-inline-start: auto; }
.tk-add-tools > select { width: auto; max-width: 190px; border-radius: 10px; background: var(--bg); }
.tk-when { display: inline-flex; align-items: center; gap: 4px; padding: 3px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.tk-when .datefld { width: 150px; }
.tk-when .date-txt { border: 0; background: transparent; padding: 4px 6px; font-size: 14px; }
.tk-q { border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 13px; font-weight: 500; padding: 4px 9px; border-radius: 7px; cursor: pointer; }
.tk-q:hover, .tk-q.on { background: var(--panel); color: var(--navy); box-shadow: 0 1px 2px rgba(31, 59, 99, .12); }
.tk-add .btn.primary { border-radius: 10px; padding: 8px 18px; }

.tk-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 4px 4px 0; }
.tk-head .hm-h2 { display: flex; align-items: center; gap: 8px; }
.tk-n { display: inline-block; min-width: 22px; padding: 0 8px; border-radius: 999px; background: var(--navy-soft); color: var(--navy); font-size: 13px; font-weight: 700; line-height: 21px; text-align: center; }
.tk-n.soft { background: var(--bg); color: var(--muted); }
.tk-empty { color: var(--muted); text-align: center; border-style: dashed; }

/* a task card */
.task.tk-card { display: block; padding: 0; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); overflow: hidden; }
.task.tk-card:last-child { border-bottom: 1px solid var(--line); }
.tk-card.done { background: #fbfcfd; }
.tk-top { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; }
.tk-chk-f { margin: 0; flex: none; }
.tk-chk { width: 24px; height: 24px; border-radius: 50%; border: 2px solid #c3cad5; background: var(--panel); color: #fff; display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; padding: 0; cursor: pointer; transition: border-color .15s, background .15s; margin-top: 1px; }
.tk-chk:hover { border-color: var(--ok); background: var(--ok-soft); }
.tk-chk.on { background: var(--ok); border-color: var(--ok); }
.tk-chk.on:hover { background: #10603a; }
.tk-chk.sm { width: 18px; height: 18px; font-size: 11px; border-width: 1.5px; margin-top: 2px; }
.tk-chk.ro { cursor: default; }
.tk-chk.loading .spin { display: none; }
.tk-body { flex: 1; min-width: 0; }
.tk-title { display: block; width: 100%; text-align: right; background: none; border: 0; padding: 0; font: inherit; font-size: 16.5px; font-weight: 700; color: var(--ink); line-height: 1.4; overflow-wrap: anywhere; }
.tk-title[data-edit] { cursor: pointer; }
.tk-title[data-edit]:hover { color: var(--navy-2); }
.tk-card.done .tk-title { color: var(--muted); text-decoration: line-through; font-weight: 600; }
.tk-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.tk-chip { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 7px; background: var(--bg); color: var(--ink); font-size: 13px; font-weight: 500; line-height: 21px; }
.tk-chip.due { background: var(--gold-soft); color: #6b5220; }
.tk-chip.due.warn { background: var(--warn-soft); color: var(--warn); }
.tk-chip.due.bad { background: var(--bad-soft); color: var(--bad); }
.tk-chip.ok { background: var(--ok-soft); color: var(--ok); }
.tk-chip.sm { font-size: 12px; padding: 0 6px; line-height: 19px; }
.tk-meta .badge { font-size: 12px; }
/* inline edit (a <details>; the title click opens it) */
.tk-edit > summary { list-style: none; display: inline-flex; }
.tk-edit > summary::-webkit-details-marker { display: none; }
.tk-edit-btn { cursor: pointer; font-size: 13px; color: var(--muted); padding: 2px 8px; border-radius: 7px; margin-top: 6px; }
.tk-edit-btn:hover { background: var(--navy-soft); color: var(--navy); }
.tk-edit[open] > .tk-edit-btn { display: none; }
.tk-edit-f { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin-top: 8px; padding: 12px; border: 1px solid var(--navy-ring); border-radius: 12px; background: #f7f9fd; }
.tk-edit-f .wide { grid-column: 1 / -1; }
.tk-edit-act { display: flex; gap: 6px; align-items: end; }
@media (hover: hover) { .tk-top > .tk-body > .tk-edit:not([open]) > .tk-edit-btn { opacity: 0; transition: opacity .15s; }
  .tk-card:hover .tk-top > .tk-body > .tk-edit > .tk-edit-btn, .tk-edit-btn:focus { opacity: 1; } }

/* the thread: steps / updates, then "add the next step" */
.tk-thread { background: #f8f9fb; border-top: 1px solid var(--line); padding: 12px 16px 12px; padding-inline-start: 52px; display: flex; flex-direction: column; gap: 10px; }
.tk-subs { border-inline-start: 2px solid #dfe3ea; padding-inline-start: 12px; display: flex; flex-direction: column; gap: 6px; }
.tk-sub { display: flex; align-items: flex-start; gap: 8px; padding: 6px 10px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); }
.tk-sub.done { background: transparent; border-color: transparent; padding-block: 3px; }
.tk-sub-body { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 14.5px; }
.tk-sub-text { font-weight: 600; overflow-wrap: anywhere; }
.tk-sub-text[data-edit] { cursor: pointer; }
.tk-sub.done .tk-sub-text { font-weight: 400; color: var(--muted); text-decoration: line-through; }
.tk-edit.sub { display: contents; }
.tk-edit.sub > .tk-edit-btn { margin: 0; padding: 0 6px; }
.tk-edit.sub[open] > .tk-edit-f { flex-basis: 100%; }
@media (hover: hover) { .tk-edit.sub:not([open]) > .tk-edit-btn { opacity: 0; } .tk-sub:hover .tk-edit.sub > .tk-edit-btn { opacity: 1; } }
.tk-next { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.task .tk-next > input[name=note] { flex: 1 1 260px; min-width: 0; padding: 7px 10px; border-radius: 10px; font-size: 14px; }
.tk-next-ic { color: var(--muted); font-size: 14px; }
.tk-next .btn { border-radius: 10px; }

/* "בוצעו" folded */
.tk-done { padding: 0; border-radius: 16px; overflow: hidden; }
.tk-done > summary { list-style: none; cursor: pointer; padding: 13px 16px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.tk-done > summary::-webkit-details-marker { display: none; }
.tk-done > summary:hover { background: #fafbfd; }
.tk-arrow { font-size: 11px; color: var(--muted); transition: transform .2s; }
.tk-done[open] .tk-arrow { transform: rotate(-90deg); }
.tk-done-list { border-top: 1px solid var(--line); padding: 12px; background: #fafbfc; display: flex; flex-direction: column; gap: 10px; }

@media (max-width: 900px) {
  .tk-add-tools { width: 100%; margin: 0; }
  .tk-add-tools > select { flex: 1 1 140px; max-width: none; }
  .tk-tip { display: none; }
  .tk-top { padding: 12px; gap: 10px; }
  .tk-thread { padding: 10px 12px; padding-inline-start: 18px; }
  .task .tk-next > input[name=note] { flex-basis: 100%; font-size: 16px; }
  .tk-next .datefld { flex: 1 1 140px; width: auto; }
}
.tk-next .datefld { width: 150px; }
@media (max-width: 900px) {
  .tk-when { flex: 1 1 100%; }
  .tk-when .datefld { flex: 1; width: auto; }
  .tk-next-ic { display: none; }
}
.task .tk-next .datefld { flex: 0 0 165px; width: 165px; }
.tk-top .tk-edit-btn { margin-top: 2px; }
@media (max-width: 900px) { .task .tk-next .datefld { flex: 1 1 140px; width: auto; } }

/* ---- case "גורמים" tab (24.11.2026, after the Gemini design) – app/templates/_gormim.html ---- */
.gx-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 440px), 1fr)); gap: var(--gap); align-items: start; }
.gx-grid .card { margin-bottom: 0; }
.gx-card, .gx-editbox { scroll-margin-top: 84px; }
.gx-card { padding: 16px 18px; transition: border-color .15s, box-shadow .15s; }
.gx-card.is-open { border-color: var(--navy-ring); box-shadow: 0 2px 10px rgba(31, 59, 99, .06); }
.gx-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding-bottom: 12px; margin-bottom: 10px; border-bottom: 1px solid var(--line); }
.gx-title { display: flex; align-items: center; gap: 8px; min-width: 0; }
.gx-title .hm-h2 { margin: 0; font-size: 16px; }
.gx-n { font-size: 12px; font-weight: 600; color: var(--muted); background: var(--bg); padding: 1px 8px; border-radius: 99px; }
.gx-tools { display: flex; gap: 6px; }
.gx-btn { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 500; padding: 5px 10px; border-radius: 8px;
  border: 1px solid var(--field); background: var(--bg); color: var(--ink); text-decoration: none; transition: background .15s, border-color .15s, color .15s; }
.gx-btn:hover { background: #eef1f5; text-decoration: none; }
.gx-btn.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.gx-btn.new { background: var(--navy-soft); border-color: var(--navy-ring); color: var(--navy); }
.gx-btn.new:hover { background: #dce5f1; }
.gx-btn.new.on { background: var(--navy); border-color: var(--navy); color: #fff; }

.gx-panel { margin-bottom: 12px; padding: 12px 14px; background: var(--bg); border: 1px solid var(--navy-ring); border-radius: 12px; animation: gxIn .18s ease-out; }
.gx-panel[hidden] { display: none; }
@keyframes gxIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.gx-panel-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; font-size: 14px; }
.gx-x { display: inline-flex; padding: 4px; border-radius: 6px; color: var(--muted); }
.gx-x:hover { background: #fff; color: var(--ink); }
.gx-new-f { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 10px; }
.gx-new-f .wide { grid-column: 1 / -1; }
.gx-new-f input[type=text], .gx-new-f input[type=tel], .gx-new-f input[type=email] { width: 100%; background: #fff; }
.gx-types { display: flex; flex-wrap: wrap; gap: 6px; }
.gx-type { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border: 1px solid var(--field); border-radius: 99px; background: #fff; font-size: 13px; cursor: pointer; }
.gx-type:has(input:checked) { background: var(--navy-soft); border-color: var(--navy-ring); color: var(--navy); font-weight: 600; }
.gx-type input { margin: 0; }
.gx-act { display: flex; justify-content: flex-end; gap: 6px; margin-top: 4px; }
.gx-q { width: 100%; background: #fff; margin-bottom: 8px; }
.gx-opts { max-height: 260px; overflow-y: auto; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 4px; }
.gx-opt { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 8px; border-radius: 8px; }
.gx-opt[hidden] { display: none; }
.gx-opt:hover { background: var(--navy-soft); }
.gx-opt-t { display: flex; flex-direction: column; min-width: 0; font-size: 14px; }
.gx-opt-t b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gx-add { flex: none; font: inherit; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 6px; border: 0; background: var(--navy-soft); color: var(--navy); cursor: pointer; }
.gx-opt:hover .gx-add, .gx-add:focus-visible { background: var(--navy); color: #fff; }
.gx-tag { flex: none; display: inline-flex; align-items: center; gap: 3px; font-size: 12px; color: var(--ok); }
.gx-opt.linked { opacity: .75; }
.gx-none { padding: 10px; text-align: center; margin: 0; }

.gx-list .gx-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 10px; margin: 0 -10px; border-radius: 10px; border-bottom: 0; transition: background .15s; }
.gx-list .gx-row + .gx-row { border-top: 1px solid var(--line); }
.gx-list .gx-row:hover { background: #f8fafc; }
.gx-row-b { min-width: 0; }
.gx-name { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; }
.gx-name b { font-size: 15px; }
.gx-row .gorm-c { gap: 3px 14px; margin-top: 5px; font-size: 13px; color: #475066; }
.gx-row .gorm-c svg { vertical-align: -2px; }
.gx-row .gorm-c a { overflow-wrap: anywhere; }
.gx-row-act { flex: none; display: flex; align-items: center; gap: 4px; }
.gx-row-act form { margin: 0; }
.gx-ic { display: inline-flex; align-items: center; gap: 3px; font: inherit; font-size: 12px; font-weight: 500; padding: 3px 8px; border-radius: 6px;
  border: 1px solid var(--line); background: #fff; color: var(--muted); cursor: pointer; text-decoration: none; transition: all .15s; }
.gx-ic:hover { color: var(--navy); border-color: var(--navy-ring); background: var(--navy-soft); text-decoration: none; }
.gx-ic.rm:hover { color: var(--bad); border-color: #f0c9c9; background: var(--bad-soft); }
@media (hover: hover) {
  .gx-row-act { opacity: 0; transition: opacity .15s; }
  .gx-row:hover .gx-row-act, .gx-row:focus-within .gx-row-act { opacity: 1; }
}
.gx-empty { margin: 0; padding: 12px 0 4px; text-align: center; font-size: 13px; color: var(--muted); }
.gx-editbox { padding: 12px 14px; margin: 4px 0; background: #fffaf0; border: 1px solid #ecd9ad; border-radius: 12px; }
.gx-editbox.card { margin-bottom: var(--gap); }
.gx-edit-h { font-size: 13px; font-weight: 700; color: #6b5220; margin-bottom: 8px; }
.gx-edit-f .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gx-edit-f textarea { height: 42px; min-height: 42px; resize: vertical; }
.gx-edit-f .fld:last-child textarea { height: 72px; }
@media (max-width: 600px) {
  .gx-card { padding: 14px; }
  .gx-tools { width: 100%; }
  .gx-btn { flex: 1; justify-content: center; padding: 8px 10px; }
  .gx-new-f, .gx-edit-f .grid { grid-template-columns: minmax(0, 1fr); }
  .gx-new-f input { font-size: 16px; }
  .gx-row .gorm-c { flex-direction: column; }
}

/* ---- page background behind the white cards (24.11.2026) – office default in "כללי ותצוגה", per user in "ההגדרות שלי".
   Colours = store.PAGE_BG. Anything sitting on the page itself (not in a card) and meant to blend in uses var(--page). */
body.bg-white { --page: #ffffff; }
body.bg-a { --page: #f7f9fb; }
body.bg-b { --page: #f1f4f8; }
.bg-pick { display: flex; flex-wrap: wrap; gap: 10px; }
.bg-pick label { display: flex; flex-direction: column; align-items: center; gap: 6px; cursor: pointer; font-size: 13px; color: var(--muted); }
.bg-pick input { position: absolute; opacity: 0; pointer-events: none; }
.bg-sw { width: 112px; height: 72px; border-radius: 10px; border: 2px solid var(--line); display: grid; place-items: center; transition: border-color .15s, box-shadow .15s; }
.bg-sw i { width: 64px; height: 34px; border-radius: 6px; background: #fff; border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(31,59,99,.06); }
.bg-sw.follow { background: repeating-linear-gradient(135deg, #fff 0 10px, #f1f4f8 10px 20px); }
.bg-pick input:checked + .bg-sw { border-color: var(--navy); box-shadow: 0 0 0 3px var(--navy-ring); }
.bg-pick input:checked ~ span { color: var(--navy); font-weight: 600; }
.bg-pick input:focus-visible + .bg-sw { box-shadow: 0 0 0 3px var(--navy-ring); }

/* ---- case "מיילים" tab (24.11.2026, after the Gemini design) – app/templates/_casemail.html ---- */
.cm-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-bottom: 10px; }
.cm-top-r { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; min-width: 0; }
.cm-new { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; flex: none; padding: 7px 16px; border-radius: 999px; font-weight: 600; font-size: 14px;
  color: #fff; background: linear-gradient(180deg, var(--navy-2), var(--navy)); text-decoration: none; box-shadow: 0 1px 2px rgba(31,59,99,.2); transition: filter .15s; }
.cm-new:hover { filter: brightness(1.08); text-decoration: none; color: #fff; }
.cm-sep { width: 1px; height: 20px; background: var(--field); margin: 0 2px; }
.cm-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.cm-pills a { padding: 5px 13px; border-radius: 999px; border: 1px solid var(--field); background: #fff; color: var(--ink); font-size: 14px; text-decoration: none; transition: background .15s, border-color .15s; }
.cm-pills a:hover { background: var(--bg); text-decoration: none; }
.cm-pills a.on { background: var(--navy-soft); border-color: var(--navy-ring); color: var(--navy); font-weight: 600; }
.cm-seg { display: inline-flex; gap: 3px; padding: 3px; background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.cm-seg a { display: inline-flex; align-items: center; gap: 5px; padding: 5px 12px; border-radius: 9px; color: var(--muted); font-size: 14px; text-decoration: none; }
.cm-seg a:hover { background: var(--bg); color: var(--ink); text-decoration: none; }
.cm-seg a.on { background: var(--navy-soft); color: var(--navy); font-weight: 600; }
.cm-note { margin: 0 0 8px; }

.cm-compose { border: 1px solid var(--navy-ring); box-shadow: 0 4px 16px rgba(31,59,99,.07); animation: gxIn .2s ease-out; scroll-margin-top: 84px; }
.cm-compose[hidden] { display: none; }
.cm-c-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding-bottom: 12px; margin-bottom: 14px; border-bottom: 1px solid var(--line); }
.cm-c-title { display: flex; align-items: center; gap: 10px; }
.cm-c-title .hm-h2 { margin: 0; }
.cm-c-ic { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: var(--navy-soft); color: var(--navy); }
.cm-c-tools { display: flex; align-items: center; gap: 8px; }
.cm-from { font-size: 13px; color: var(--muted); background: var(--bg); border: 1px solid var(--line); padding: 4px 10px; border-radius: 8px; }
.cm-from b { color: var(--ink); font-weight: 600; }
.cm-x { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; color: var(--muted); }
.cm-x:hover { background: var(--bg); color: var(--ink); }
.cm-c-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 18px; }
.cm-c-main { display: grid; gap: 12px; align-content: start; }
.cm-c-main textarea { width: 100%; }
.cm-c-side { display: flex; flex-direction: column; gap: 8px; }
.cm-c-side .att-box { flex: 1; }
.cm-c-act { display: flex; justify-content: flex-end; align-items: center; gap: 8px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }
.cm-c-act .btn.primary { display: inline-flex; align-items: center; gap: 6px; }
.cm-replyf .cm-c-act { justify-content: space-between; }
.cm-to { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-height: 44px; padding: 5px 8px; border: 1px solid var(--field);
  border-radius: 10px; background: #fff; cursor: text; transition: border-color .15s, box-shadow .15s; }
.cm-to:focus-within { border-color: var(--navy-2); box-shadow: 0 0 0 3px var(--navy-ring); }
.cm-chips { display: contents; }
.cm-chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 4px 3px 9px; border-radius: 8px; background: var(--navy-soft); border: 1px solid var(--navy-ring); color: var(--navy); font-size: 13px; font-weight: 500; animation: gxIn .15s ease-out; }
.cm-chip button { border: 0; background: none; color: var(--navy); font-size: 16px; line-height: 1; cursor: pointer; padding: 0 4px; border-radius: 6px; }
.cm-chip button:hover { background: var(--navy-ring); }
.cm-to-in { flex: 1; min-width: 150px; border: 0 !important; box-shadow: none !important; padding: 4px !important; background: transparent; }
.cm-add { margin-inline-start: auto; }
.cm-add > summary { list-style: none; display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg);
  font-size: 13px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.cm-add > summary::-webkit-details-marker { display: none; }
.cm-add > summary:hover { background: #eef1f5; }
.cm-add-list { position: absolute; z-index: 30; inset-inline-end: 0; top: calc(100% + 6px); width: min(320px, 92vw); max-height: 280px; overflow-y: auto;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 10px 30px rgba(15,23,42,.14); padding: 6px; }
.cm-add-h { font-size: 12px; font-weight: 700; color: var(--muted); padding: 4px 8px 6px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.cm-opt { display: flex; align-items: flex-start; gap: 8px; padding: 7px 8px; border-radius: 8px; cursor: pointer; }
.cm-opt:hover { background: var(--navy-soft); }
.cm-opt input { margin-top: 3px; flex: 0 0 auto; width: auto; }
.cm-opt-t { display: flex; flex-direction: column; flex: 1 1 auto; min-width: 0; font-size: 13px; text-align: right; }
.cm-opt-t span { color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: right; }

.cm-w { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); margin-top: 0; }
.cm-list { padding: 0; }
.cm-list-h { position: sticky; top: 0; z-index: 1; display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 11px 14px; background: #fafbfd; border-bottom: 1px solid var(--line); font-size: 14px; }
.cm-item { padding: 12px 14px; border-inline-start: 3px solid transparent; }
.cm-item.on { border-inline-start-color: var(--navy); }
.cm-who { display: flex; align-items: center; gap: 6px; min-width: 0; }
.cm-dir { flex: none; font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 5px; border: 1px solid; }
.cm-dir.in { color: var(--ok); background: var(--ok-soft); border-color: #bfe3cd; }
.cm-dir.out { color: #4a43a8; background: #eeedfb; border-color: #d4d1f3; }
.cm-dir.big { font-size: 12px; padding: 2px 8px; border: 0; }
.cm-pane { padding: 0; overflow: hidden; }
.cm-pane-h { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 10px 16px; padding: 14px 18px; background: #fafbfd; border-bottom: 1px solid var(--line); }
.cm-pane-t { min-width: 0; flex: 1; display: grid; gap: 4px; }
.cm-pane-t h3 { margin: 0; font-size: 18px; line-height: 1.35; }
.cm-pane-meta { display: flex; align-items: center; gap: 8px; }
.cm-pane-who { display: flex; flex-wrap: wrap; gap: 2px 14px; color: var(--muted); overflow-wrap: anywhere; }
.cm-pane-act { display: flex; flex-wrap: wrap; gap: 6px; }
.cm-reply-btn { background: var(--navy-soft); border-color: var(--navy-ring); color: var(--navy); font-weight: 600; }
.cm-msgs { padding: 4px 18px 10px; max-height: 60vh; overflow-y: auto; }
.cm-replyf { scroll-margin-top: 84px; }
.cm-replyf h3 { margin-top: 0; }
.cm-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 10px; min-height: 320px; color: var(--muted); }
.cm-empty-ic { color: #c7cfdb; }
.cm-empty p { margin: 0; font-weight: 500; }
@media (max-width: 1100px) { .cm-c-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 900px) {
  .cm-w { grid-template-columns: minmax(0, 1fr); }
  .cm-top { align-items: stretch; }
  .cm-pills { flex-wrap: nowrap; overflow-x: auto; max-width: 100%; padding-bottom: 2px; }
  .cm-pills a { white-space: nowrap; }
  .cm-top-r { flex-wrap: nowrap; max-width: 100%; }
  .cm-seg { width: 100%; justify-content: space-between; }
  .cm-seg a { flex: 1; justify-content: center; }
  .cm-msgs { max-height: none; }
  .cm-to-in { font-size: 16px; }
}

/* ---- /mail – the user's own Gmail in the case-mail design (24.11.2026) – app/templates/mailbox.html ---- */
.mbx-search { position: relative; display: flex; align-items: center; gap: 6px; margin: 0 0 12px; }
.mbx-search input[type=search] { flex: 1; min-width: 0; padding-inline-start: 34px; border-radius: 999px; }
.mbx-search-ic { position: absolute; inset-inline-start: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); display: flex; pointer-events: none; }
.mbx-n { display: inline-block; min-width: 18px; padding: 0 5px; margin-inline-start: 3px; border-radius: 999px; background: var(--navy); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.cm-pills a:not(.on) .mbx-n { background: var(--bg); color: var(--ink); border: 1px solid var(--line); line-height: 16px; }
.mbx-item { position: relative; cursor: pointer; }
.mbx-hit { position: absolute; inset: 0; z-index: 0; }
.mbx-item > :not(.mbx-hit) { position: relative; z-index: 1; pointer-events: none; }
.mbx-tags { margin-top: 3px; }
.mbx-tags a { pointer-events: auto; }
.mbx .cm-compose .cm-c-main { margin-bottom: 4px; }
.mbx .cm-compose .cm-c-act { margin-top: 12px; }
@media (max-width: 900px) {
  .mbx-search input[type=search] { font-size: 16px; }
}

/* ---- case "נתבעים ומסירות" card (24.11.2026, after the Gemini design) – app/templates/_defendants.html ---- */
.dx-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.dx-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dx-title .hm-h2 { margin: 0; }
.dx-count { padding: 2px 11px; border-radius: 999px; font-size: 13px; font-weight: 700; background: var(--bg); color: var(--ink); border: 1px solid var(--line); }
.dx-count.all { background: var(--ok-soft); color: var(--ok); border-color: #bfe3cd; }
.dx-tools { display: flex; gap: 8px; flex-wrap: wrap; }
.dx-tools .btn { display: inline-flex; align-items: center; gap: 5px; }
.dx-alert { display: flex; align-items: center; gap: 8px; padding: 8px 12px; margin-bottom: 12px; border-radius: 10px;
  background: var(--warn-soft); border: 1px solid #f6d7a8; color: #7a3e06; font-size: 14px; min-width: 0; }
.dx-alert svg { flex: none; color: var(--warn); }
.dx-alert b { flex: none; }
.dx-alert-t { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dx-alert-h { flex: none; font-size: 12px; opacity: .8; }
.dx-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.dx-tbl { width: 100%; border-collapse: collapse; min-width: 560px; }
.dx-tbl th { background: var(--bg); color: var(--muted); font-size: 13px; font-weight: 700; text-align: right; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.dx-tbl td { padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.dx-tbl tbody tr:last-child td { border-bottom: 0; }
.dx-tbl tbody tr:hover td { background: #fafbfd; }
.dx-th-def { width: 34%; }
.dx-th-x, .dx-td-x { width: 44px; text-align: center; }
.dx-def { display: table-cell; }
.dx-def > .dx-n { display: inline-block; width: 20px; color: var(--muted); font-size: 13px; font-weight: 700; vertical-align: top; padding-top: 2px; }
.dx-def-b { display: inline-block; max-width: calc(100% - 24px); vertical-align: top; }
.dx-def-l { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.dx-name { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; color: var(--ink); cursor: pointer; text-align: right; }
.dx-name:hover { color: var(--navy-2); text-decoration: underline; }
.dx-rep { font-size: 13px; color: var(--muted); background: var(--bg); border: 1px solid var(--line); padding: 1px 7px; border-radius: 6px; }
.dx-sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.dx-cell { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 6px; text-align: right; padding: 7px 10px;
  border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); font: inherit; transition: border-color .15s, background .15s; }
button.dx-cell { cursor: pointer; }
.dx-cell-b { display: flex; flex-direction: column; min-width: 0; }
.dx-l { display: flex; align-items: center; gap: 6px; font-weight: 700; font-size: 13px; white-space: nowrap; }
.dx-s { font-size: 12px; opacity: .8; margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dx-dot { width: 8px; height: 8px; border-radius: 50%; flex: none; display: inline-block; background: #c4cbd6; }
.dx-pen { opacity: 0; color: var(--muted); flex: none; transition: opacity .15s; }
button.dx-cell:hover .dx-pen, button.dx-cell:focus-visible .dx-pen { opacity: 1; }
.dx-cell.st-delivered { background: var(--ok-soft); border-color: #bfe3cd; color: #0f5132; }
.dx-cell.st-delivered .dx-dot, .dx-dot.d-delivered { background: #22a35a; }
.dx-cell.st-sent { background: var(--navy-soft); border-color: var(--navy-ring); color: var(--navy); }
.dx-cell.st-sent .dx-dot, .dx-dot.d-sent { background: var(--navy-2); }
.dx-cell.st-late { background: var(--bad-soft); border-color: #f2c2bd; color: var(--bad); }
.dx-cell.st-late .dx-dot, .dx-dot.d-late { background: #d9443a; }
.dx-cell.st-none { color: var(--muted); }
.dx-dot.d-none { background: #c4cbd6; }
button.dx-cell:hover { border-color: var(--navy-ring); }
button.dx-cell.st-delivered:hover { border-color: #86cfa3; }
button.dx-cell.st-late:hover { border-color: #e79a92; }
.dx-track { display: inline-block; font-size: 12px; margin-top: 3px; }
.dx-gear { background: none; border: 0; padding: 6px; border-radius: 8px; color: var(--muted); cursor: pointer; }
.dx-gear:hover { background: var(--bg); color: var(--ink); }
.dx-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; font-size: 13px; color: var(--muted); padding: 10px 2px 0; }
.dx-legend span { display: inline-flex; align-items: center; gap: 6px; }
.dx-legend-h { margin-inline-start: auto; }
.dx-empty { color: var(--muted); padding: 18px 0; text-align: center; }
.dx-log { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 8px; }
.dx-log > summary { cursor: pointer; color: var(--navy-2); font-size: 14px; }
.dx-log-d { padding: 10px 0; border-bottom: 1px solid var(--line); }
.dx-log-d:last-child { border-bottom: 0; }
.dx-log-d .list { margin: 6px 0 0; }
/* dialogs */
dialog.dx-dlg { width: min(480px, calc(100vw - 32px)); border: 1px solid var(--line); border-radius: 16px; padding: 18px; direction: rtl;
  box-shadow: 0 20px 50px rgba(20, 30, 50, .18); color: var(--ink); }
dialog.dx-dlg[open] { animation: dxIn .16s cubic-bezier(.16, 1, .3, 1); }
@keyframes dxIn { from { opacity: 0; transform: translateY(-6px) scale(.98); } to { opacity: 1; transform: none; } }
dialog.dx-dlg::backdrop { background: rgba(20, 30, 50, .35); }
.dx-f { display: flex; flex-direction: column; gap: 12px; }
.dx-f .fld { margin: 0; }
.dx-f input:not([type=checkbox]), .dx-f select { width: 100%; }
.dx-dh { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.dx-dh b { font-size: 17px; display: block; }
.dx-dh small { display: block; margin-top: 2px; }
.dx-x { background: none; border: 0; padding: 5px; border-radius: 8px; color: var(--muted); cursor: pointer; }
.dx-x:hover { background: var(--bg); color: var(--ink); }
.dx-quick { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; border-radius: 10px;
  background: var(--ok-soft); border: 1px solid #bfe3cd; color: #0f5132; font-size: 13px; font-weight: 600; }
.dx-quick .btn { background: #22a35a; border-color: #22a35a; color: #fff; }
.dx-quick .btn:hover { background: #1a8a4b; }
.dx-g2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 12px; }
.dx-fa { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
.dx-fa-r { display: flex; gap: 8px; margin-inline-start: auto; }
.dx-del { background: none; border: 0; color: var(--bad); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; padding: 4px; }
.dx-del:hover { text-decoration: underline; }
.dx-lbl-row { display: flex; justify-content: space-between; align-items: center; }
.dx-link { background: none; border: 0; padding: 0; font: inherit; font-size: 13px; color: var(--navy-2); cursor: pointer; }
.dx-link:hover { text-decoration: underline; }
.dx-pick { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px; border: 1px solid var(--line); background: var(--bg); border-radius: 10px; max-height: 140px; overflow-y: auto; }
.dx-pick-i { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; background: #fff; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; cursor: pointer; }
.dx-pick-i:has(input:checked) { border-color: var(--navy-ring); background: var(--navy-soft); }
@media (max-width: 900px) {
  .dx-alert-h, .dx-legend .dx-legend-h { display: none; }
  /* phone: every defendant is a small card – name on top, one cell per document under it (labelled) */
  .dx-wrap { border: 0; overflow: visible; }
  .dx-tbl, .dx-tbl tbody { display: block; min-width: 0; }
  .dx-tbl thead { display: none; }
  .dx-tbl tr { display: grid; grid-template-columns: 1fr auto; gap: 8px; border: 1px solid var(--line); border-radius: 12px; padding: 10px; margin-bottom: 10px; }
  .dx-tbl td { display: block; padding: 0; border: 0; }
  .dx-tbl tbody tr:hover td { background: none; }
  .dx-tbl td.dx-def { grid-column: 1; }
  .dx-tbl td.dx-td-x { grid-column: 2; grid-row: 1; width: auto; }
  .dx-tbl td.dx-td { grid-column: 1 / -1; }
  .dx-tbl td.dx-td::before { content: attr(data-label); display: block; font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 3px; }
  .dx-pen { opacity: .6; }
  .dx-g2 { grid-template-columns: 1fr; }
  dialog.dx-dlg { width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 16px 16px 0 0; max-height: 92vh; overflow-y: auto; }
}

/* ---- the bell's summary panel (24.11.2026, per Tamir's sample): one row per record, unread first ---- */
.bell-menu { position: relative; }
.bell-menu > summary { list-style: none; }
.bell-menu > summary::-webkit-details-marker { display: none; }
.bell-menu[open] > summary { background: var(--bg); color: var(--ink); }
.bell-panel { position: absolute; top: calc(100% + 8px); left: 0; z-index: 50; width: 400px; max-width: calc(100vw - 24px);
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 12px 36px rgba(20, 32, 56, .14);
  overflow: hidden; animation: bpIn .14s ease-out; }
@keyframes bpIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.bell-panel.loading { min-height: 120px; opacity: .7; }
.bp-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.bp-title { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 16px; color: var(--ink); }
.bp-title .ic { color: var(--gold); }
.bp-total { font-size: 13px; font-weight: 600; color: var(--muted); background: var(--bg); border-radius: 999px; padding: 3px 10px; }
.bp-list { list-style: none; margin: 0; padding: 0; max-height: min(60vh, 440px); overflow-y: auto; }
.bp-list li + li { border-top: 1px solid var(--line); }
.bp-row { display: flex; align-items: flex-start; gap: 12px; padding: 12px 16px; color: var(--ink); text-decoration: none; transition: background .12s; }
.bp-row:hover { background: #f7f9fd; text-decoration: none; }
.bp-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.bp-t { display: flex; align-items: center; gap: 7px; font-size: 15px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bp-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--navy-2); }
.bp-x { font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bp-side { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; padding-top: 1px; }
.bp-side small { font-size: 12.5px; color: var(--muted); }
.bp-n { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--navy-2); color: #fff;
  font-size: 12px; font-weight: 600; line-height: 22px; text-align: center; }
.bp-list li.read .bp-t { font-weight: 500; color: var(--muted); }
.bp-empty { margin: 0; padding: 22px 16px; text-align: center; color: var(--muted); }
.bp-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; border-top: 1px solid var(--line); background: var(--panel); }
.bp-foot form { margin: 0; }
.bp-link { background: none; border: 0; padding: 0; font: inherit; font-size: 14px; color: var(--navy-2); cursor: pointer; text-decoration: none; }
.bp-link:hover { text-decoration: underline; }
.bp-link.muted { color: var(--muted); }
@media (max-width: 900px) {
  .bell-panel { position: fixed; top: 64px; left: 12px; right: 12px; width: auto; max-width: none; }
}

/* ---- work-mode drop-down (24.11.2026, per Tamir's sample): two mode cards, run-now segment, advanced panels ---- */
.mode-menu .mode-list { width: 380px; max-width: calc(100vw - 24px); min-width: 0; padding: 0; display: block; border-radius: 16px;
  border: 1px solid var(--line); box-shadow: 0 12px 36px rgba(20, 32, 56, .14); overflow: hidden; --mm-green: #1f7a55; --mm-green-soft: #edf7f2; }
.mm-pane { padding: 14px 16px 16px; }
.mm-h { font-size: 13.5px; color: var(--muted); margin-bottom: 10px; }
.mm-quick { display: grid; gap: 10px; margin: 0; }
.mm-card { display: block; border: 1px solid var(--line); border-radius: 14px; padding: 14px 14px 0; cursor: pointer; background: var(--panel);
  transition: border-color .15s, background .15s, box-shadow .15s; }
.mm-card:hover { border-color: var(--navy-ring); }
.mm-card > input { position: absolute; opacity: 0; pointer-events: none; }
.mm-top { display: flex; align-items: center; gap: 12px; padding-bottom: 12px; }
.mm-ic { flex: none; width: 42px; height: 42px; border-radius: 11px; display: inline-flex; align-items: center; justify-content: center; }
.mm-focus .mm-ic { background: var(--ink); color: #fff; }
.mm-collection .mm-ic { background: var(--mm-green-soft); color: var(--mm-green); }
.mm-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mm-txt b { font-size: 16px; color: var(--ink); }
.mm-txt small { font-size: 13.5px; color: var(--muted); }
.mm-dot { flex: none; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid #c9d0db; background: #fff; }
.mode-list .mm-more { display: flex; border-radius: 0; background: none; align-items: center; gap: 4px; padding: 10px 0 12px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--ink); text-decoration: none; }
.mode-list .mm-more:hover { color: var(--navy); text-decoration: none; background: none; }
.mm-more .ic { color: var(--muted); }
.mm-card:has(input:checked) { border-width: 1.5px; padding: 13.5px 13.5px 0; }
.mm-focus:has(input:checked) { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(30, 36, 51, .06); }
.mm-collection:has(input:checked) { border-color: var(--mm-green); background: #f7fbf9; box-shadow: 0 0 0 3px rgba(31, 122, 85, .08); }
.mm-card:has(input:checked) .mm-dot { border: 5px solid var(--ink); }
.mm-collection:has(input:checked) .mm-dot { border-color: var(--mm-green); }
.mm-card:has(input:focus-visible) { outline: 2px solid var(--navy-ring); outline-offset: 2px; }
.mm-run { border-top: 1px solid var(--line); margin: 4px -16px 0; padding: 12px 16px 0; }
.mm-run-h { display: flex; justify-content: space-between; align-items: baseline; font-size: 13.5px; color: var(--muted); margin-bottom: 8px; }
.mm-run-name { font-size: 13.5px; color: var(--ink); }
.mode-menu[data-mode="collection"] .mm-run-name { color: var(--mm-green); }
.mm-seg { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; background: #f1f4f8; border-radius: 12px; padding: 4px; }
.mm-seg button { border: 0; background: transparent; border-radius: 9px; padding: 9px 4px; font: inherit; font-size: 14px; font-weight: 600; color: var(--ink);
  cursor: pointer; white-space: nowrap; transition: background .12s, color .12s; }
.mm-seg button:hover { background: #fff; box-shadow: 0 1px 2px rgba(20, 32, 56, .08); }
.mode-menu[data-mode="collection"] .mm-seg button:hover { color: var(--mm-green); }
.mm-exit { margin: 12px 0 0; text-align: center; }
.mm-exit .btn { width: 100%; }
/* advanced panels */
.mm-back { display: flex; align-items: center; gap: 6px; width: 100%; border: 0; background: none; padding: 2px 0 12px; margin-bottom: 4px; border-bottom: 1px solid var(--line);
  font: inherit; font-size: 15.5px; font-weight: 700; color: var(--ink); cursor: pointer; text-align: start; }
.mm-back .ic { color: var(--muted); }
.mm-adv { display: grid; gap: 14px; margin: 12px 0 0; }
.mm-f { display: grid; gap: 6px; }
.mm-f > span { font-size: 13.5px; color: var(--muted); }
.mm-adv select, .mm-adv input[type=number] { height: 44px; border-radius: 12px; }
.mm-chks { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.mm-chk { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font-size: 14px; cursor: pointer; }
.mm-chk input { width: 18px; height: 18px; margin: 0; accent-color: var(--navy-2); flex: none; }
.mm-go { display: grid; grid-template-columns: 96px 1fr; gap: 10px; }
.mm-go input { text-align: center !important; }
.mm-btn { height: 44px; border-radius: 12px; border: 0; background: var(--ink); color: #fff; font-weight: 600; }
.mm-btn:hover { background: #2b3347; color: #fff; }
.mm-btn.mm-green { background: var(--mm-green); }
.mm-btn.mm-green:hover { background: #18654a; }
.mm-adv .mm-chk:has(input[name=queue]) { border: 0; padding: 0; }
.mode-list .mm-link { display: inline; padding: 0; font-size: 13.5px; color: var(--muted); }
.mode-list .mm-link:hover { background: none; }
@media (max-width: 900px) {
  .mode-menu .mode-list { position: fixed; top: 64px; left: 12px; right: 12px; width: auto; max-width: none; max-height: calc(100vh - 80px); overflow-y: auto; }
}
/* the panel opens towards the page (left edge on the button), never off the screen's left side (24.11.2026 fix) */
.mode-menu .mode-list { left: 0; right: auto; }

/* ===== settings → "ניהול רשימות" (25.11.2026) ===== */
.lst { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 16px; align-items: start; }
.lst-nav { padding: 10px; max-height: 75vh; overflow: auto; position: sticky; top: 76px; }
.lst-find { width: 100%; margin-bottom: 8px; }
.lst-grp { margin-bottom: 10px; }
.lst-grp > b { display: block; padding: 4px 8px; }
.lst-item { display: flex; justify-content: space-between; gap: 8px; padding: 5px 8px; border-radius: 8px; color: var(--ink); text-decoration: none; }
.lst-item:hover { background: var(--bg); }
.lst-item.on { background: var(--navy-soft); color: var(--navy); font-weight: 600; }
.lst-rows { list-style: none; margin: 0; padding: 0; }
.lst-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 8px 4px; border-bottom: 1px solid var(--line); }
.lst-pos { width: 22px; text-align: center; }
.lst-acts { display: flex; flex-wrap: wrap; gap: 6px; margin-inline-start: auto; align-items: flex-start; }
.lst-pop { position: relative; }
.lst-pop > summary { list-style: none; cursor: pointer; }
.lst-pop > summary::-webkit-details-marker { display: none; }
.lst-panel { position: absolute; inset-inline-end: 0; top: calc(100% + 6px); z-index: 20; background: #fff; border: 1px solid var(--line);
  border-radius: 12px; box-shadow: 0 8px 24px rgba(20, 30, 50, .12); padding: 12px; width: 300px; }
.lst-colors { width: 250px; }
.lst-crow { display: flex; gap: 6px; margin-bottom: 6px; }
.lst-crow label { cursor: pointer; }
.lst-crow input { position: absolute; opacity: 0; pointer-events: none; }
.lst-crow input:checked + .st { outline: 2px solid var(--navy); outline-offset: 2px; }
.lst-add { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; margin-top: 14px; }
@media (max-width: 900px) {
  .lst { grid-template-columns: 1fr; }
  .lst-nav { position: static; max-height: 260px; }
  .lst-acts { margin-inline-start: 0; width: 100%; }
  .lst-panel { inset-inline-end: auto; inset-inline-start: 0; }
}

/* ===== staging band + "קריאה בלבד" (migration phases 6–7, 25.11.2026) ===== */
.staging-band { position: sticky; top: 0; z-index: 200; background: #fde68a; color: #5b4300; border-bottom: 1px solid #f2c94c;
  padding: 7px 14px; font-size: 14px; text-align: center; }
.staging-band a { color: #5b4300; text-decoration: underline; }
.freeze-band { font-size: 15px; }
