/* HAVAIA app: brand tokens from HAVAIA-brand-guidelines.md. No inline styles anywhere (CSP). */
:root {
  --ink: #1B1F3B;
  --ink-2: #2A3060;
  --ink-3: #454C80;
  --coral: #FF6A4D;
  --coral-text: #C93A22;
  --coral-soft: #FFE3DC;
  --cream: #FFF6EE;
  --bg: #FBF8F4;
  --card: #FFFFFF;
  --muted: #5B6078;
  --line: #E8E4EE;
  --good: #1F7A4D;
  --good-soft: #DDF3E7;
  --mid: #8A5A00;
  --mid-soft: #FFF0D1;
  --bad: #B42318;
  --bad-soft: #FEE4E2;
  --radius: 16px;
  --shadow: 0 12px 32px -20px rgba(27, 31, 59, .35);
  --font-head: "Rubik", "Heebo", system-ui, sans-serif;
  --font-body: "Heebo", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  /* One height for every field and button, so anything placed side by side lines up. */
  --control-h: 44px;
  --control-h-sm: 36px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font-body); color: var(--ink); background: var(--bg);
  font-size: 15px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--font-head); line-height: 1.25; margin: 0 0 .5em; }
h1 { font-size: 1.6rem; font-weight: 700; }
h2 { font-size: 1.15rem; font-weight: 600; }
h3 { font-size: 1rem; font-weight: 600; }
p { margin: 0 0 1em; }
a { color: var(--coral-text); }
small, .muted { color: var(--muted); }
.ltr { direction: ltr; unicode-bidi: embed; display: inline-block; }
.nowrap { white-space: nowrap; }
:focus-visible { outline: 3px solid var(--coral); outline-offset: 2px; border-radius: 6px; }
/* !important: form rules such as input[type=email] { width: 100% } are more specific and would undo it. */
.show-sm { display: none; }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; border: 0 !important; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- app shell ---------- */
.shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); min-height: 100vh; }
.side {
  background: var(--ink); color: #fff; display: flex; flex-direction: column;
  padding: 22px 16px; position: sticky; top: 0; height: 100vh;
}
.side-logo { display: block; padding: 6px 10px 22px; }
.side-logo img { height: 38px; width: auto; max-width: 100%; display: block; }
.tenant-chip {
  background: rgba(255, 255, 255, .08); border-radius: 12px; padding: 10px 12px; margin-bottom: 18px;
  font-size: .85rem; line-height: 1.4;
}
.tenant-chip b { display: block; font-family: var(--font-head); font-weight: 600; font-size: .95rem; }
.tenant-chip span { opacity: .7; }
.side nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.side nav a {
  color: rgba(255, 255, 255, .78); text-decoration: none; padding: 9px 12px; border-radius: 10px;
  display: flex; align-items: center; gap: 10px; font-weight: 500;
}
.side nav a:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.side nav a .icon { flex: 0 0 auto; opacity: .85; }
.side nav a[aria-current="page"] .icon { opacity: 1; }
.side nav a[aria-current="page"] { background: var(--coral); color: var(--ink); }
.side nav a .badge { margin-inline-start: auto; }
.side nav .nav-label { font-size: .72rem; letter-spacing: .04em; color: rgba(255,255,255,.45); padding: 14px 12px 4px; }
.side-foot { border-top: 1px solid rgba(255, 255, 255, .12); padding-top: 14px; font-size: .85rem; }
.side-foot .who b { display: block; font-weight: 600; }
.side-foot .who span { opacity: .7; }
.side-foot .row { display: flex; gap: 10px; align-items: center; margin-top: 10px; flex-wrap: wrap; }
.side-foot a, .side-foot button.link { color: rgba(255,255,255,.8); }

.main { padding: 28px 36px 60px; min-width: 0; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.topbar h1 { margin: 0; }
.topbar .sub { color: var(--muted); font-size: .92rem; margin-top: 2px; }

/* Phones and tablets: a bar with a menu button, and the side menu slides in from the side over the page
   (owner 2026-10-25). No script: the button is the label of a checkbox, and the dimmed page behind is its
   label too, so a tap outside closes it. */
.nav-toggle, .mobile-bar, .nav-close, .nav-backdrop { display: none; }
@media (max-width: 900px) {
  .shell { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; }
  .nav-toggle { display: block; }
  .mobile-bar {
    display: flex; align-items: center; gap: 12px; position: sticky; top: 0; z-index: 30;
    background: var(--ink); color: #fff; padding: 8px 12px; min-height: 56px;
  }
  .platform .mobile-bar { background: #0F1226; }
  .mobile-bar img { height: 26px; width: auto; display: block; }
  .mobile-bar .tenant-name {
    margin-inline-start: auto; font-size: .85rem; opacity: .8; min-width: 0;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  }
  .burger, .nav-close {
    display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto;
    width: 44px; height: 44px; border-radius: 10px; color: #fff; cursor: pointer;
  }
  .burger:hover, .nav-close:hover { background: rgba(255, 255, 255, .08); }
  .burger .icon, .nav-close .icon { width: 24px; height: 24px; }
  .nav-toggle:focus-visible ~ .mobile-bar .burger { outline: 3px solid var(--coral); outline-offset: 2px; }
  .side {
    position: fixed; top: 0; bottom: 0; inset-inline-start: 0; z-index: 50;
    width: min(300px, 86vw); height: 100vh; height: 100dvh; overflow-y: auto; overscroll-behavior: contain;
    padding: 12px 16px 22px; box-shadow: 0 0 40px rgba(0, 0, 0, .35);
    transform: translateX(105%); visibility: hidden; transition: transform .25s ease, visibility 0s linear .25s;
  }
  .nav-close { align-self: flex-end; margin-bottom: 4px; }
  .side-logo { padding-top: 0; }
  .nav-backdrop {
    display: block; position: fixed; inset: 0; z-index: 40; background: rgba(27, 31, 59, .5);
    opacity: 0; pointer-events: none; transition: opacity .25s ease;
  }
  .nav-toggle:checked ~ .side { transform: none; visibility: visible; transition: transform .25s ease; }
  .nav-toggle:checked ~ .nav-backdrop { opacity: 1; pointer-events: auto; }
  body:has(.nav-toggle:checked) { overflow: hidden; }
  .main { padding: 20px 16px 48px; }
}
/* Fixed, so that focusing it when the menu opens never scrolls the page to the top. */
.nav-toggle.sr-only { position: fixed !important; top: 0; }
@media (max-width: 900px) and (prefers-reduced-motion: reduce) {
  .side, .nav-toggle:checked ~ .side, .nav-backdrop { transition: none; }
}

/* Tables marked .cards become one card per row on phones; td[data-label] shows its column name. */
@media (max-width: 640px) {
  table.cards thead { display: none; }
  table.cards, table.cards tbody, table.cards tr, table.cards td { display: block; width: 100%; }
  table.cards tr { padding: 12px 0; border-bottom: 1px solid var(--line); }
  table.cards tr:last-child { border-bottom: 0; }
  table.cards td { border: 0; padding: 3px 0; }
  table.cards td.nowrap { white-space: normal; }
  table.cards td.inline { display: inline-block; width: auto; margin-inline-end: 10px; vertical-align: middle; }
  table.cards .clip { min-width: 0; max-width: none; -webkit-line-clamp: 3; }
  table.cards td[data-label] > .clip { display: inline; }
  table.cards td[data-label]:empty, table.cards td.hide-sm { display: none; }
  table.cards td.num { text-align: start; }
  table.cards td[data-label]::before { content: attr(data-label) ": "; color: var(--muted); font-size: .82rem; }
  table.cards tbody tr:hover td { background: none; }
  table.cards td.row-actions { text-align: start; padding-top: 8px; }
  .table-wrap:has(table.cards) { overflow-x: visible; }
  .hide-sm { display: none; }
  .show-sm { display: inline; }
  /* A form's own buttons span the card, the same width as its fields (not inline, rename or filter rows). */
  .card form:not(.rename):not(.filters):not(.inline):not(.cal-jump):not(.cal-search) > .btn,
  .card form:not(.rename):not(.filters):not(.inline):not(.cal-jump):not(.cal-search) > .actions > .btn { width: 100%; }
  /* Comfortable finger targets. */
  :root { --control-h-sm: 40px; }
  .btn-sm { font-size: .85rem; }
  button.link { padding: 6px 0; }
  main .support-bar { font-size: .85rem; padding: 8px 12px; }
  /* The chart's SVG scales down to the card: larger text in its own units stays readable. */
  .chart text { font-size: 22px; }
  .chart text.lbl { font-size: 17px; }
  .topbar { margin-bottom: 16px; }
  h1 { font-size: 1.4rem; }
}

/* ---------- cards & grids ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; box-shadow: var(--shadow); }
.card + .card { margin-top: 18px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2 { margin: 0; }
.grid { display: grid; gap: 18px; }
.grid > * { min-width: 0; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: 2fr 1fr; }
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin-bottom: 18px; }
@media (max-width: 1100px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-3 { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 720px) { .grid-2 { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 480px) { .kpis { grid-template-columns: minmax(0, 1fr); } }
/* «סקרי שירות» (staff): three tiles, then one row per organization with its limit and its months. */
.sv-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 720px) { .sv-kpis { grid-template-columns: minmax(0, 1fr); } }
.sv-table td { vertical-align: middle; }
.sv-limit input { width: 110px; height: var(--control-h-sm); min-height: 0; padding-block: 0; text-align: center; }
@media (max-width: 640px) {
  .sv-limit input { width: 100%; margin-top: 4px; }
}
.stack > * + * { margin-top: 18px; }

.kpi { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow); }
.kpi .label { color: var(--muted); font-size: .88rem; }
.kpi .value { font-family: var(--font-head); font-weight: 700; font-size: 2rem; line-height: 1.15; margin-top: 4px; }
.kpi .delta { font-size: .85rem; font-weight: 500; }
.kpi.accent { background: var(--ink); color: #fff; border-color: var(--ink); }
.kpi.accent .label { color: rgba(255,255,255,.7); }
.up { color: var(--good); } .down { color: var(--bad); }
.kpi.accent .up { color: #7FE0AE; } .kpi.accent .down { color: #FFB4A6; }

/* ---------- chart ---------- */
.chart { width: 100%; height: auto; display: block; }
.chart .bar { fill: var(--ink); }
.chart .bar.hl { fill: var(--coral); }
.chart .axis { stroke: var(--line); stroke-width: 1; }
.chart text { font-family: var(--font-body); font-size: 12px; fill: var(--muted); }
.chart .val { fill: var(--ink); font-weight: 600; }

.hbar { display: grid; grid-template-columns: minmax(90px, 140px) minmax(0, 1fr) 44px; align-items: center; gap: 10px; margin: 8px 0; font-size: .92rem; }
.hbar svg { width: 100%; height: 10px; display: block; }
.hbar .track { fill: var(--cream); }
.hbar .fill { fill: var(--coral); }
.hbar .fill.ink { fill: var(--ink); }
.hbar .n { text-align: end; font-weight: 600; font-variant-numeric: tabular-nums; }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; margin: 0 -22px; padding: 0 22px; }
table { width: 100%; border-collapse: collapse; font-size: .93rem; }
th { text-align: start; font-weight: 600; color: var(--muted); font-size: .82rem; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 11px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: #FDFBF8; }
td.num, th.num { text-align: end; font-variant-numeric: tabular-nums; }
.row-link { color: inherit; text-decoration: none; font-weight: 500; }
.row-link:hover { color: var(--coral-text); text-decoration: underline; }
/* A secondary link in a row (a customer's name): quiet until hovered. */
.quiet-link { color: inherit; text-decoration: none; }
.quiet-link:hover { color: var(--coral-text); text-decoration: underline; }
/* A row with a button: every cell centred on it. */
tr:has(> td.row-actions) > td { vertical-align: middle; }
td.row-actions { text-align: end; white-space: nowrap; }
/* Long text in a table cell: wraps anywhere, at most two lines, so the table never outgrows its card. */
.clip { min-width: 140px; max-width: 280px; overflow: hidden; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }

/* ---------- badges ---------- */
.badge { display: inline-block; font-size: .78rem; font-weight: 600; padding: 2px 10px; border-radius: 99px; background: var(--cream); color: var(--ink); white-space: nowrap; }
.badge.good { background: var(--good-soft); color: var(--good); }
.badge.mid { background: var(--mid-soft); color: var(--mid); }
.badge.bad { background: var(--bad-soft); color: var(--bad); }
.badge.coral { background: var(--coral); color: var(--ink); }
.badge.ink { background: var(--ink); color: #fff; }
.score { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; font-family: var(--font-head); font-weight: 700; }
.score.good { background: var(--good-soft); color: var(--good); }
.score.mid { background: var(--mid-soft); color: var(--mid); }
.score.bad { background: var(--bad-soft); color: var(--bad); }
.chip { display: inline-block; background: var(--cream); border: 1px solid var(--line); border-radius: 99px; padding: 1px 10px; font-size: .8rem; margin: 2px 0 2px 4px; }

/* ---------- forms ---------- */
label, .field-label { display: block; font-weight: 500; font-size: .9rem; margin-bottom: 6px; }
/* A mandatory field (the "required" attribute) gets an orange asterisk by its label; others get nothing, and no words. */
.field:has(> :is(input, select, textarea)[required]) > label:not(.check)::after,
form.rename:has(> input[required]) > label::after,
.bc-media > label::after { content: " *"; content: " *" / ""; color: var(--coral); font-weight: 700; }
.field { margin-bottom: 16px; }
.field small { display: block; margin-top: 4px; }
/* Every field the same (owner 2026-10-25: «שכולם נראים טוב בעיצוב אחיד»): one height, border, corner and font, a field
   written without a type included. */
input:not([type]), input[type=text], input[type=email], input[type=password], input[type=tel], input[type=number], input[type=url],
input[type=time], input[type=date], input[type=datetime-local], input[type=search], select, textarea {
  width: 100%; font: inherit; font-size: 15px; color: var(--ink); background: #fff; border: 1.5px solid var(--line);
  border-radius: 10px; padding: 0 12px; height: var(--control-h); transition: border-color .15s;
}
textarea { height: auto; padding: 10px 12px; }
input[type=file] { display: block; width: 100%; font: inherit; color: var(--ink); background: #fff; border: 1.5px dashed var(--line); border-radius: 10px; padding: 10px 12px; }
/* An organization's logo on its staff card and settings: kept small, never stretched. */
.org-logo { display: block; max-width: 160px; max-height: 80px; width: auto; height: auto; object-fit: contain; margin-bottom: 12px; }
input:focus, select:focus, textarea:focus { border-color: var(--ink-3); outline: none; box-shadow: 0 0 0 3px var(--coral-soft); }
/* 16px in a field on a phone: it never zooms the page in when one is tapped. */
@media (max-width: 640px) {
  input:not([type]), input[type=text], input[type=email], input[type=password], input[type=tel], input[type=number], input[type=url],
  input[type=time], input[type=date], input[type=datetime-local], input[type=search], select, textarea { font-size: 16px; }
}
input.code { font-family: var(--font-head); font-size: 1.6rem; letter-spacing: .4em; text-align: center; direction: ltr; height: 56px; }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0 16px; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; margin-bottom: 16px; }
.filters .field { margin: 0; min-width: 140px; }
.filters .field.grow { flex: 1 1 150px; max-width: 420px; }
.filters .check { min-height: var(--control-h); margin: 0; }
/* Summary tiles: four equal boxes, two by two on phones. */
.stat-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
@media (max-width: 640px) { .stat-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; } }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; box-shadow: var(--shadow); }
.stat b { display: block; font-family: var(--font-head); font-size: 1.7rem; line-height: 1.2; }
.stat > span { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: .88rem; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--line); flex: 0 0 auto; }
.dot.good { background: var(--good); }
.dot.mid { background: #D9A300; }
.dot.bad { background: var(--bad); }
.stat-row.stat-row-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 520px; }
.plain-list { list-style: none; margin: 0; padding: 0; }
.plain-list li { padding: 6px 0; border-bottom: 1px solid var(--line); }
.plain-list li:last-child { border-bottom: 0; }
/* Labor lines marked "X" are free-text notes, not billable work. */
tr.note-row td { color: var(--muted); font-style: italic; }

.check { display: flex; gap: 8px; align-items: center; font-weight: 400; }
.check input { width: auto; }
/* «זכור אותי»: a HAVAIA checkbox — a soft rounded box that fills coral with a white tick. */
.login-remember { margin: 2px 0 18px; gap: 10px; cursor: pointer; user-select: none; font-size: .95rem; color: var(--ink); width: fit-content; }
.login-remember input[type=checkbox] {
  appearance: none; -webkit-appearance: none; margin: 0; flex: 0 0 auto;
  width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--line); background: var(--card);
  display: grid; place-items: center; cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.login-remember input[type=checkbox]::after {
  content: ""; width: 12px; height: 12px; transform: scale(0); transition: transform .15s ease;
  background: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E");
}
.login-remember:hover input[type=checkbox] { border-color: var(--coral); box-shadow: 0 0 0 4px var(--coral-soft); }
.login-remember input[type=checkbox]:checked { background: var(--coral); border-color: var(--coral); }
.login-remember input[type=checkbox]:checked::after { transform: scale(1); }
.login-remember input[type=checkbox]:focus-visible { outline: 3px solid var(--coral); outline-offset: 2px; }
.validation, .field-validation-error { color: var(--bad); font-size: .85rem; }
.validation-summary-errors ul, .errors { margin: 0; padding-inline-start: 18px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-family: var(--font-head);
  font-weight: 600; font-size: .95rem; min-height: var(--control-h); padding: 0 20px; border-radius: 99px; border: 2px solid transparent;
  cursor: pointer; text-decoration: none; transition: background .15s, transform .15s; line-height: 1.2;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--coral); color: var(--ink); }
.btn-primary:hover { background: #ff7c62; }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: var(--ink-2); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-outline { background: transparent; border-color: var(--coral); color: var(--ink); }
.btn-outline:hover { background: var(--coral-soft); }
.btn-danger { background: transparent; border-color: var(--bad-soft); color: var(--bad); }
.btn-danger:hover { background: var(--bad-soft); }
.btn-sm { min-height: var(--control-h-sm); padding: 0 14px; font-size: .82rem; }
.btn-block { width: 100%; }
button.link { background: none; border: 0; padding: 0; font: inherit; color: var(--coral-text); text-decoration: underline; cursor: pointer; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
form.inline { display: inline; }

/* ---------- notices ---------- */
.notice { border-radius: 12px; padding: 12px 16px; margin-bottom: 18px; font-size: .93rem; border: 1px solid transparent; }
.notice.info { background: var(--cream); border-color: #F3E3D3; }
.notice.ok { background: var(--good-soft); color: #145536; }
.notice.error { background: var(--bad-soft); color: #7A1A12; }
.notice.warn { background: var(--mid-soft); color: #5E3D00; }
.secret {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 1.15rem; direction: ltr;
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; display: inline-block; letter-spacing: .06em;
  user-select: all;
}
.secret.link { display: block; font-size: .82rem; letter-spacing: 0; word-break: break-all; margin: 0; }

/* ---------- lists ---------- */
.alert-item { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.alert-item:last-child { border-bottom: 0; }
.alert-item .dot { width: 10px; height: 10px; border-radius: 50%; margin-top: 7px; flex: 0 0 auto; background: var(--mid); }
.alert-item .dot.High { background: var(--bad); }
.alert-item .body { flex: 1; min-width: 0; }
.alert-item .meta { font-size: .82rem; color: var(--muted); }
.empty { text-align: center; color: var(--muted); padding: 28px 10px; }
dl.props { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 18px; margin: 0; }
dl.props dt { color: var(--muted); }
dl.props dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.transcript { white-space: pre-line; background: var(--cream); border-radius: 12px; padding: 14px 16px; font-size: .93rem; }
.pager { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; align-items: center; margin-top: 16px; }
/* As tall as a small button, so tabs and the button beside them line up. */
.seg { display: inline-flex; background: #fff; border: 1px solid var(--line); border-radius: 99px; padding: 3px; height: var(--control-h-sm); }
.seg a { display: flex; align-items: center; padding: 0 14px; border-radius: 99px; text-decoration: none; color: var(--muted); font-weight: 500; font-size: .88rem; }
.seg a[aria-current="true"] { background: var(--ink); color: #fff; }
details.more summary { cursor: pointer; color: var(--coral-text); font-weight: 500; }
details.more[open] summary { margin-bottom: 12px; }
form.rename { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
form.rename label { flex: 0 0 100%; margin: 0; }
form.rename input { flex: 1 1 160px; min-width: 0; }
/* Integrations: equal cards, each logo centred in a tile of the same size. */
.integrations { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 18px; }
.integration { display: flex; flex-direction: column; gap: 16px; }
.integrations .card + .card { margin-top: 0; }
.logo-tile { height: 112px; display: grid; place-items: center; padding: 16px 24px; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; }
/* The same box for every logo, scaled to fit: logos of different shapes come out the same visual size. */
.logo-tile img { display: block; width: 100%; max-width: 240px; height: 52px; object-fit: contain; }
/* The badge sits on the name's line, so a vendor name that wraps doesn't move it. */
.integration-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.integration-head h2 { margin: 0; line-height: 1.6rem; }
.integration-head small { display: block; line-height: 1.4; }
.integration-head .badge { margin-top: .2rem; }
/* Actions sit at the bottom of every card, so the buttons line up across cards of different heights. */
.integration-actions { margin-top: auto; display: grid; gap: 10px; }
.integration .props { font-size: .9rem; gap: 6px 14px; }
details.confirm summary { list-style: none; }
details.confirm summary::-webkit-details-marker { display: none; }
details.confirm[open] summary { display: none; }
details.confirm p { font-size: .88rem; color: var(--bad); margin: 0 0 10px; }
.credentials .secret.link { user-select: all; }
.key-list { display: grid; gap: 10px; }
.key-list .field-label { margin: 0; }
.key-row { display: grid; gap: 6px; }
.key-row code { display: block; font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: .8rem; background: var(--bg);
  border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; text-align: left; overflow-wrap: anywhere; }
/* The key's dates on one side, its revoke button on the other, centred on each other. */
.key-meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.key-meta small { display: block; line-height: 1.5; }
.integration form.rename { margin: 0; }
.danger-zone { border: 1.5px solid var(--bad-soft); }
.danger-zone h2 { color: var(--bad); }
.danger-list { padding-inline-start: 20px; margin: 0 0 18px; overflow-wrap: anywhere; }
.danger-list .ltr { word-break: break-all; }

/* ---------- auth pages ---------- */
.auth {
  min-height: 100vh; display: grid; place-items: center; padding: 32px 16px;
  background: radial-gradient(900px 420px at 85% -10%, var(--coral-soft), transparent 60%), var(--cream);
}
.auth-card { width: min(440px, 100%); background: #fff; border-radius: 24px; padding: 34px 32px 28px; box-shadow: 0 24px 60px -28px rgba(27,31,59,.45); }
.auth-card .logo { display: block; margin: 0 auto 24px; height: 34px; width: auto; }
.auth-card h1 { font-size: 1.35rem; text-align: center; }
.auth-card .lead { text-align: center; color: var(--muted); margin-bottom: 22px; }
.auth-foot { text-align: center; color: var(--muted); font-size: .82rem; margin-top: 18px; }
.auth-foot .lock { display: inline-flex; gap: 6px; align-items: center; }
.qr { display: block; margin: 0 auto 14px; width: 200px; height: 200px; border: 8px solid #fff; border-radius: 12px; box-shadow: 0 0 0 1px var(--line); }
.qr svg { width: 100%; height: 100%; display: block; }
.steps { padding-inline-start: 20px; margin: 0 0 18px; color: var(--muted); font-size: .92rem; }

/* ---------- platform admin ---------- */
.platform .side { background: #0F1226; }
.platform .side nav a[aria-current="page"] { background: #fff; color: var(--ink); }
.support-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  background: var(--coral-soft); border: 1px solid var(--coral); border-radius: 12px; padding: 10px 16px; margin-bottom: 18px; font-size: .92rem;
}
.platform-tag { font-size: .72rem; font-weight: 600; letter-spacing: .06em; color: var(--coral); padding: 0 10px 14px; }

@media (prefers-reduced-motion: reduce) { .btn { transition: none; } .btn:hover { transform: none; } }

/* ---------- the diary ---------- */
.cal-head { display: flex; justify-content: space-between; align-items: center; gap: 10px 16px; flex-wrap: wrap; }
.cal-head h2 { margin: 0; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
/* View, date and search on one row; the fields and their buttons as tall as every other field. */
.cal-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 16px; }
.cal-jump, .cal-search { display: flex; align-items: center; gap: 8px; margin: 0; }
.cal-jump input { width: auto; }
.cal-search { flex: 1 1 260px; max-width: 420px; }
.cal-search input { flex: 1 1 auto; min-width: 0; }
/* The week: hours down the side, days across, single lines between cells. */
.cal-grid, .cal-month { display: grid; border-top: 1px solid var(--line); border-inline-start: 1px solid var(--line); }
.cal-grid { grid-template-columns: 52px repeat(7, minmax(0, 1fr)); }
.cal-grid > *, .cal-month > * { border-bottom: 1px solid var(--line); border-inline-end: 1px solid var(--line); min-width: 0; }
.cal-corner, .cal-hour, .cal-wd { background: var(--bg); }
.cal-colhead { display: flex; flex-direction: column; align-items: center; padding: 8px 4px; text-decoration: none; color: var(--ink); line-height: 1.3; background: var(--bg); }
.cal-colhead span { font-size: .8rem; color: var(--muted); }
.cal-colhead b { font-family: var(--font-head); font-size: 1.05rem; }
.cal-colhead small { font-size: .75rem; }
.cal-colhead:hover b { color: var(--coral-text); }
.cal-colhead.today { background: var(--coral-soft); }
.cal-hour { font-size: .75rem; color: var(--muted); padding: 6px 4px; text-align: center; }
.cal-cell { padding: 4px; min-height: 46px; display: flex; flex-direction: column; gap: 4px; }
.cal-cell.today { background: #FFF9F6; }
.cal-cell.nodata { background: #F7F5F9; }
/* An appointment: a coloured dot by its time for its status, as in the legend (no side edge: owner 2026-10-25,
   «אני לא אוהב את המסגרת הזו מהצד, תסיר אותה מכל המקומות»). */
.appt {
  display: block; text-decoration: none; color: var(--ink); background: #fff; border: 1px solid var(--line);
  border-radius: 8px; padding: 3px 6px; font-size: .78rem; line-height: 1.35; overflow: hidden;
  --appt-dot: var(--ink);
}
.appt b { font-weight: 700; margin-inline-end: 4px; }
.appt > b:first-child::before {
  content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--appt-dot);
  margin-inline-end: 5px; vertical-align: 1px;
}
.appt .ltr { font-size: .74rem; }
.appt small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--muted); font-size: .74rem; }
a.appt:hover { border-color: var(--ink-3); }
.appt.s-in { --appt-dot: #D9A300; background: var(--mid-soft); }
.appt.s-done { --appt-dot: var(--good); background: var(--good-soft); }
.appt.s-other { --appt-dot: var(--line); }
.appt.s-off { --appt-dot: var(--bad); }
.cal-legend { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 12px; font-size: .82rem; color: var(--muted); }
.cal-legend > span { display: inline-flex; align-items: center; gap: 6px; }
.dot.ink { background: var(--ink); }
/* The month: a day's number, how many, and its first appointments. */
.cal-month { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-wd { text-align: center; font-size: .8rem; color: var(--muted); padding: 6px 2px; }
.cal-mday { display: flex; flex-direction: column; gap: 3px; min-height: 112px; padding: 6px; text-decoration: none; color: var(--ink); }
.cal-mday:hover { background: #FDFBF8; }
.cal-mday.out { background: var(--bg); }
.cal-mday.out .cal-n, .cal-mday.nodata .cal-n { color: var(--muted); }
.cal-n { font-family: var(--font-head); font-weight: 600; align-self: flex-start; padding: 0 7px; border-radius: 99px; }
.cal-mday.today .cal-n { background: var(--coral); color: var(--ink); }
.cal-count { font-size: .75rem; color: var(--muted); }
.cal-mlist { display: grid; gap: 3px; }
.cal-mlist .appt { white-space: nowrap; text-overflow: ellipsis; }
.cal-mlist small { font-size: .74rem; color: var(--muted); }
/* The week on phones: a list of days. */
.only-sm { display: none; }
.cal-agenda { padding: 14px 16px; }
.card.cal-agenda + .card.cal-agenda { margin-top: 10px; }
.cal-agenda.today { border-color: var(--coral); }
.cal-agenda-head { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--ink); margin-bottom: 8px; }
.cal-agenda-head span:not(.badge) { color: var(--muted); font-size: .88rem; }
.cal-agenda-head .badge { margin-inline-start: auto; }
.cal-agenda-list { display: grid; gap: 6px; }
.cal-agenda .appt { font-size: .88rem; padding: 6px 10px; }
.cal-agenda p { margin: 0; }
/* An hour's (or a day's) heading inside a list of appointments. */
tr.hour-row td { background: var(--bg); color: var(--muted); font-size: .82rem; font-weight: 600; padding: 6px 10px; }
tbody tr.hour-row:hover td { background: var(--bg); }
@media (max-width: 640px) {
  .only-sm { display: block; }
  tr.hour-row td { padding: 6px 10px; border-radius: 8px; }
  table.cards tr.hour-row { padding: 0; border-bottom: 0; margin-top: 10px; }
  .cal-head .actions { width: 100%; }
  .cal-head .actions .btn { flex: 1 1 0; padding: 0 8px; }
  .cal-tools > * { width: 100%; max-width: none; flex: 1 1 100%; }
  .cal-tools .seg { display: flex; }
  .cal-tools .seg a { flex: 1 1 0; justify-content: center; }
  .cal-jump input { flex: 1 1 auto; min-width: 0; }
  .cal-mday { min-height: 54px; padding: 4px 2px; align-items: center; }
  .cal-mday .cal-n { align-self: center; padding: 0 5px; font-size: .9rem; }
  .cal-mlist { display: none; }
  .cal-count { background: var(--ink); color: #fff; border-radius: 99px; padding: 0 6px; font-weight: 600; font-size: .7rem; }
  /* Tabs that fill the row, each as wide as its words (shorter words on phones). */
  .seg-fill { display: flex; width: 100%; }
  .seg-fill a { flex: 1 1 auto; justify-content: center; white-space: nowrap; padding: 0 8px; }
}
.stack-top { margin-top: 18px; }
.stack-bottom { margin-bottom: 18px; }
.narrow { max-width: 520px; }
.hbar .badge { margin-inline-start: 4px; font-size: .72rem; padding: 0 7px; }
.hbar svg { transform: scaleX(-1); } /* bars grow from the right, as Hebrew reads */

/* ---------- WhatsApp conversations (/chat) ----------
   The list beside the open thread, as KINETIQ's own screen draws them. The thread opens on its newest
   line with no script: its scroller is a reversed column holding ONE child, so it starts at the bottom
   while the lines inside read top to bottom. */
.wa {
  display: grid; grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
  height: calc(100vh - 150px); min-height: 460px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden;
}
.wa-list { display: flex; flex-direction: column; min-height: 0; border-inline-end: 1px solid var(--line); }
.wa-search { display: flex; gap: 8px; padding: 12px; border-bottom: 1px solid var(--line); }
.wa-search input { flex: 1; min-width: 0; }
.wa-items { list-style: none; margin: 0; padding: 0; overflow-y: auto; flex: 1; }
.wa-item { display: flex; gap: 12px; align-items: center; padding: 10px 14px; text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--line); }
.wa-item:hover { background: var(--bg); }
.wa-item.is-active { background: var(--cream); }
.wa-avatar {
  flex: 0 0 auto; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: var(--ink); color: #fff; font-family: var(--font-head); font-weight: 600; font-size: .85rem;
}
.wa-item-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.wa-item-top, .wa-item-bottom { display: flex; align-items: center; gap: 8px; min-width: 0; }
.wa-item-name { flex: 1; min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wa-item-time { flex: 0 0 auto; font-size: .78rem; color: var(--muted); }
.wa-item-time.is-waiting { color: var(--good); font-weight: 600; }
.wa-item-preview { flex: 1; min-width: 0; font-size: .86rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wa-count { flex: 0 0 auto; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 99px; background: var(--good); color: #fff; font-size: .75rem; font-weight: 700; display: grid; place-items: center; }
.wa-tick { display: inline-flex; vertical-align: -3px; color: var(--good); }
.wa-tick .icon { width: 15px; height: 15px; }
.wa-tick.is-failed { color: var(--bad); }
/* With the script the list grows as it is scrolled (chat.js), and the page links are not needed. */
.chat-js .wa-pager { display: none; }
.wa-pager { display: flex; justify-content: space-between; gap: 10px; padding: 10px 14px; font-size: .88rem; }
.wa-list .empty { padding: 28px 16px; }

.wa-thread { display: flex; flex-direction: column; min-height: 0; background: var(--bg); }
.wa-pick { margin: auto; }
.wa-head { display: flex; align-items: center; gap: 12px; padding: 10px 16px; background: var(--card); border-bottom: 1px solid var(--line); }
.wa-head-who { display: flex; flex-direction: column; min-width: 0; line-height: 1.35; }
.wa-head-who .muted { font-size: .82rem; }
.wa-scroll { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column-reverse; }
.wa-lines { list-style: none; margin: 0; padding: 14px 18px 18px; display: flex; flex-direction: column; gap: 3px; }
.wa-reply { display: flex; align-items: flex-end; gap: 8px; margin: 0; padding: 10px 12px; background: var(--card); border-top: 1px solid var(--line); }
.wa-input { position: relative; flex: 1; min-width: 0; display: flex; }
.wa-reply textarea { flex: 1; min-width: 0; height: var(--control-h); min-height: var(--control-h); max-height: 160px; resize: none; line-height: 1.4; padding-inline-end: 44px; }
.wa-reply .btn { height: var(--control-h); flex: none; }
.wa-msg.is-pending { opacity: .6; }
.wa-reply-off { justify-content: center; font-size: .88rem; }
.wa-emoji { position: static; }
.wa-emoji > summary {
  position: absolute; inset-inline-end: 4px; bottom: 4px;
  list-style: none; display: grid; place-items: center; width: 36px; height: calc(var(--control-h) - 8px);
  border-radius: 8px; font-size: 1.2rem; cursor: pointer; user-select: none;
}
.wa-emoji > summary::-webkit-details-marker { display: none; }
.wa-emoji > summary:hover, .wa-emoji[open] > summary { background: var(--bg); }
.wa-emoji-list {
  position: absolute; bottom: calc(100% + 8px); inset-inline-end: 0; z-index: 20; box-sizing: border-box;
  width: min(268px, 100%); display: grid; grid-template-columns: repeat(auto-fill, 40px); justify-content: center; gap: 2px; padding: 8px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
}
/* A narrow screen: the list opens from the box's right edge, over the send button, and keeps six columns. */
@media (max-width: 560px) {
  .wa-emoji-list { inset-inline-end: auto; inset-inline-start: 0; width: 268px; }
}
.wa-emoji-item { width: 40px; height: 40px; border: 0; border-radius: 8px; background: transparent; font-size: 1.3rem; cursor: pointer; padding: 0; }
.wa-emoji-item:hover, .wa-emoji-item:focus-visible { background: var(--bg); outline: none; }
.wa-older { text-align: center; font-size: .8rem; padding: 4px 0 10px; }
.wa-day { align-self: center; margin: 10px 0 6px; }
.wa-day span { background: var(--card); border: 1px solid var(--line); border-radius: 99px; padding: 2px 12px; font-size: .78rem; color: var(--muted); }
.wa-msg { display: flex; flex-direction: column; max-width: min(75%, 560px); }
.wa-msg.is-first { margin-top: 6px; }
/* In Hebrew the customer is on the right (the line's start) and the business on the left. */
.wa-msg-in { align-self: flex-start; align-items: flex-start; }
.wa-msg-out { align-self: flex-end; align-items: flex-end; }
.wa-bubble { padding: 7px 11px 5px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 2px; }
.wa-msg-out .wa-bubble { background: var(--good-soft); border-color: #C5E8D4; }
.wa-from { font-size: .78rem; font-weight: 600; color: var(--ink-3); }
.wa-from-person { color: var(--coral-text); }
.wa-text { white-space: pre-wrap; overflow-wrap: anywhere; }
.wa-kind { font-style: italic; color: var(--muted); }
.wa-meta { align-self: flex-end; display: inline-flex; align-items: center; gap: 4px; font-size: .72rem; color: var(--muted); }
.wa-ending { font-size: .75rem; color: var(--muted); padding: 2px 4px 0; }

/* Phones and tablets: one pane at a time — the list, or the open thread with its way back. */
@media (max-width: 900px) {
  .wa { grid-template-columns: minmax(0, 1fr); height: calc(100vh - 190px); }
  .wa--open .wa-list { display: none; }
  .wa:not(.wa--open) .wa-thread { display: none; }
  .wa-list { border-inline-end: 0; }
  .wa-back { display: inline; white-space: nowrap; font-size: .88rem; }
  .wa-msg { max-width: 88%; }
}

/* ---------- WhatsApp message templates ---------- */
.tpl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 18px; }
.tpl-grid .card + .card { margin-top: 0; }
.tpl-card { display: flex; flex-direction: column; gap: 10px; }
.tpl-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.tpl-card-head h2 { margin: 0; font-size: 1.05rem; }
.tpl-meta { font-size: .82rem; }
.tpl-reason { margin: 0; }
.tpl-actions { margin-top: auto; }
.tpl-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.tpl-phone { background: #ECE5DD; border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 4px; }
.tpl-bubble { background: #fff; border-radius: 10px; padding: 8px 11px; box-shadow: 0 1px 1px rgba(0,0,0,.08); overflow-wrap: anywhere; }
.tpl-header { font-weight: 700; margin-bottom: 4px; }
.tpl-body { white-space: pre-wrap; font-size: .93rem; line-height: 1.5; }
.tpl-footer { font-size: .78rem; color: var(--muted); margin-top: 6px; }
.tpl-media { font-style: italic; margin-bottom: 4px; }
.tpl-btn { background: #fff; border-radius: 10px; padding: 8px; text-align: center; color: #027EB5; font-weight: 500; font-size: .9rem; box-shadow: 0 1px 1px rgba(0,0,0,.08); }
mark.tpl-var { background: var(--coral-soft); color: inherit; border-radius: 4px; padding: 0 3px; white-space: nowrap; }
.tpl-edit { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 18px; align-items: start; }
.tpl-edit .card + .card { margin-top: 0; }
.tpl-preview { position: sticky; top: 18px; }
.tpl-preview h2 { margin-top: 0; }
.tpl-fieldset { border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px 0; margin: 0 0 16px; }
.tpl-fieldset legend { font-weight: 600; font-size: .9rem; padding: 0 6px; }
/* A value's button: a chip that puts its value into the text. */
button.tpl-insert { font: inherit; font-size: .8rem; color: inherit; cursor: pointer; line-height: 1.5; }
button.tpl-insert:hover { border-color: var(--ink-3); background: var(--coral-soft); }
/* «שיוך להודעות»: one row per kind of message. */
.tpl-choices .card h2 { margin-top: 0; }
/* The same columns in every card, so the groups line up one under the other. */
.tpl-choices table { table-layout: fixed; }
.tpl-choices th:nth-child(1) { width: 27%; }
.tpl-choices th:nth-child(2) { width: 39%; }
.tpl-choices th:nth-child(3) { width: 20%; }
.tpl-choices th:nth-child(4) { width: 14%; }
.tpl-choices td { vertical-align: middle; }
.tpl-choices .badge { white-space: normal; }
.tpl-choice-title { margin: 0; font-weight: 600; }
.tpl-choice-select select { width: 100%; }
@media (max-width: 900px) {
  .tpl-edit { grid-template-columns: minmax(0, 1fr); }
  .tpl-preview { position: static; }
}
@media (max-width: 640px) {
  .tpl-choices table.cards td.tpl-choice-select { padding: 6px 0; }
}

/* ---------- חוויות (experiences) ---------- */
.face { display: block; flex: 0 0 auto; }
.face .f-bg { stroke-width: 0; }
.face .f-line { fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.face .f-line.f-thin { stroke-width: 2.4; }
.face.happy .f-bg { fill: #CFF1DE; } .face.happy .f-line, .face.happy .f-dot { stroke: var(--good); fill: var(--good); }
.face.happy .f-line { fill: none; }
.face.unhappy .f-bg { fill: #FDD9D5; } .face.unhappy .f-line { stroke: var(--bad); } .face.unhappy .f-dot { fill: var(--bad); }
.face.neutral .f-bg { fill: var(--mid-soft); } .face.neutral .f-line { stroke: var(--mid); } .face.neutral .f-dot { fill: var(--mid); }
.face.waiting .f-bg { fill: #EEEBF3; } .face.waiting .f-line { stroke: var(--muted); } .face.waiting .f-dot { fill: var(--muted); }


.xp-hero { display: grid; grid-template-columns: minmax(280px, 1fr) minmax(0, 2fr); gap: 18px; margin-bottom: 18px; }
.xp-score { display: flex; align-items: center; gap: 22px; }
.ring { width: 150px; height: 150px; flex: 0 0 auto; }
.ring-track { fill: none; stroke: #EEEBF3; stroke-width: 11; }
.ring-fill { fill: none; stroke-width: 11; stroke-linecap: round; }
.ring.happy .ring-fill { stroke: var(--good); }
.ring.neutral .ring-fill { stroke: #D9A300; }
.ring.unhappy .ring-fill { stroke: var(--bad); }
.xp-big { font-family: var(--font-head); font-weight: 700; font-size: 3rem; line-height: 1; }
.xp-big-label { font-family: var(--font-head); font-weight: 600; font-size: 1.1rem; margin: 2px 0 8px; }
.xp-score .delta { font-size: .88rem; font-weight: 500; margin-bottom: 4px; }
.xp-kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.xp-kpi { display: flex; align-items: center; gap: 14px; text-decoration: none; color: inherit; }
a.xp-kpi { transition: transform .15s ease, box-shadow .15s ease; }
a.xp-kpi:hover { transform: translateY(-2px); box-shadow: 0 16px 34px -20px rgba(27, 31, 59, .5); }
.xp-kpi .value { font-size: 1.8rem; }
.xp-kpi.happy .value { color: var(--good); }
.xp-kpi.unhappy .value { color: var(--bad); }
.xp-kpi.alert { border-color: #F5B8B1; background: #FFF7F6; }
.xp-kpi.alert .value { color: var(--bad); }
.xp-kpi-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--cream); color: var(--ink); flex: 0 0 auto; }
.xp-kpi.alert .xp-kpi-icon { background: var(--bad-soft); color: var(--bad); }

.xp-legend { display: flex; gap: 14px; align-items: center; font-size: .85rem; color: var(--muted); flex-wrap: wrap; }
.xp-legend span { display: inline-flex; align-items: center; gap: 6px; }
.trend .bar-happy { fill: var(--good); }
.trend .bar-unhappy { fill: var(--bad); }
.trend .bar-none { fill: var(--line); }
.monthly .grid { stroke: var(--line); stroke-dasharray: 3 4; }
.monthly .base { stroke: var(--line); }
.monthly .axis-lbl { font-size: 11px; }
.monthly .line { fill: none; stroke: var(--ink); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.monthly .dot { stroke: #fff; stroke-width: 2; }
.monthly .dot.happy { fill: var(--good); } .monthly .dot.neutral { fill: #D9A300; } .monthly .dot.unhappy { fill: var(--bad); }
.monthly .bar-happy { fill: var(--good); opacity: .85; } .monthly .bar-unhappy { fill: var(--bad); opacity: .85; }
.monthly .hit { fill: transparent; }
.monthly .col:hover .hit { fill: var(--cream); }
.monthly .cnt { font-size: 13px; font-weight: 700; opacity: 0; pointer-events: none; fill: var(--ink); }
.monthly .cnt .good { fill: var(--good); } .monthly .cnt .bad { fill: var(--bad); }
.monthly .col:hover .cnt { opacity: 1; }
.trend .hit { fill: transparent; }
.trend .col:hover .hit { fill: var(--cream); }
.trend .cnt { font-size: 13px; font-weight: 700; opacity: 0; pointer-events: none; }
.trend .cnt.good { fill: var(--good); } .trend .cnt.bad { fill: var(--bad); }
.trend .col:hover .cnt { opacity: 1; }
.xp-why { display: flex; align-items: center; gap: 8px; margin: 6px 0 8px; font-size: .95rem; }
.xp-why small { font-family: var(--font-body, inherit); font-weight: 400; color: var(--muted); font-size: .8rem; }
.xp-topic { display: grid; grid-template-columns: minmax(90px, 130px) minmax(0, 1fr) 28px; align-items: center; gap: 12px; margin: 9px 0; font-size: .92rem; }
.xp-topic .n { text-align: end; font-weight: 600; font-variant-numeric: tabular-nums; }
.xp-why.happy { color: var(--good); } .xp-why.unhappy { color: var(--bad); margin-top: 18px; }
.pbar { display: block; height: 10px; border-radius: 99px; background: var(--cream); overflow: hidden; }
.pbar-fill { display: block; height: 100%; border-radius: 99px; background: var(--coral); }
.pbar-fill.good, .pbar-fill.happy { background: var(--good); }
.pbar-fill.bad, .pbar-fill.unhappy { background: var(--bad); }
.pbar-fill.neutral { background: #D9A300; }
.pbar-fill.ink { background: var(--ink); }
.pbar-fill.w0 { width: 0%; } .pbar-fill.w5 { width: 5%; } .pbar-fill.w10 { width: 10%; } .pbar-fill.w15 { width: 15%; } .pbar-fill.w20 { width: 20%; } .pbar-fill.w25 { width: 25%; } .pbar-fill.w30 { width: 30%; } .pbar-fill.w35 { width: 35%; } .pbar-fill.w40 { width: 40%; } .pbar-fill.w45 { width: 45%; } .pbar-fill.w50 { width: 50%; } .pbar-fill.w55 { width: 55%; } .pbar-fill.w60 { width: 60%; } .pbar-fill.w65 { width: 65%; } .pbar-fill.w70 { width: 70%; } .pbar-fill.w75 { width: 75%; } .pbar-fill.w80 { width: 80%; } .pbar-fill.w85 { width: 85%; } .pbar-fill.w90 { width: 90%; } .pbar-fill.w95 { width: 95%; } .pbar-fill.w100 { width: 100%; } 
.hbar .fill.good, .hbar .fill.happy { fill: var(--good); }
.hbar .fill.bad, .hbar .fill.unhappy { fill: var(--bad); }
.hbar .fill.neutral { fill: #D9A300; }

.xp-advisors { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 28px; }
.xp-advisor { display: grid; grid-template-columns: auto minmax(90px, 160px) minmax(0, 1fr) 48px; align-items: center; gap: 12px; padding: 6px 0; }
.xp-advisor-name { display: flex; flex-direction: column; line-height: 1.3; min-width: 0; }
.xp-advisor-name b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.xp-advisor-bar { display: block; margin: 0; }
.xp-advisor-pct { font-family: var(--font-head); font-weight: 700; text-align: end; }
.xp-advisor-pct.happy { color: var(--good); } .xp-advisor-pct.neutral { color: var(--mid); } .xp-advisor-pct.unhappy { color: var(--bad); }

.xp-since { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 24px; align-items: center; margin-bottom: 18px; }
.xp-since h2 { margin: 0 0 12px; }
.xp-since-pair { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.xp-since-cell { display: flex; align-items: center; gap: 12px; }
.xp-since-val { font-family: var(--font-head); font-weight: 700; font-size: 2.3rem; line-height: 1; }
.xp-since-arrow { font-size: 1.6rem; color: var(--muted); }
.xp-since-delta { margin-top: 12px; font-weight: 600; }
.xp-since-kpis { margin: 0; display: grid; gap: 10px; border-inline-start: 1px solid var(--line); padding-inline-start: 22px; }
.xp-since-kpis div { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.xp-since-kpis dt { color: var(--muted); }
.xp-since-kpis dd { margin: 0; }
.xp-pct { font-weight: 700; }
.xp-pct.happy { color: var(--good); } .xp-pct.neutral { color: #B58800; } .xp-pct.unhappy { color: var(--bad); }
.xp-months td, .xp-months th { white-space: nowrap; }
.xp-side { display: flex; flex-direction: column; gap: 18px; }
.xp-side .card { margin: 0; }
.xp-years { display: flex; flex-direction: column; }
.xp-year { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.xp-year + .xp-year { border-top: 1px solid var(--line); }
.xp-year-main { display: flex; flex-direction: column; flex: 1 1 auto; line-height: 1.3; }
.xp-year-main b { font-family: var(--font-head); font-size: 1.1rem; }
.xp-year-main small { color: var(--muted); }
.xp-year-val { display: flex; flex-direction: column; align-items: flex-end; font-size: 1.1rem; }
.xp-year-val .delta { font-size: .8rem; }
.xp-changes { list-style: none; margin: 0; padding: 0; }
.xp-changes li { display: grid; grid-template-columns: minmax(0, 1fr) auto 80px; gap: 12px; align-items: center; padding: 8px 0; }
.xp-changes li + li { border-top: 1px solid var(--line); }
.xp-changes .delta { font-size: .85rem; font-weight: 600; text-align: end; }
.xp-tools { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.xp-tools .filters { margin: 0; flex: 1 1 260px; justify-content: flex-end; }
.xp-verdict { font-size: .82rem; font-weight: 600; padding: 1px 10px; border-radius: 99px; background: #EEEBF3; color: var(--muted); }
.xp-verdict.happy { background: var(--good-soft); color: var(--good); }
.xp-verdict.unhappy { background: var(--bad-soft); color: var(--bad); }
.xp-time { margin-inline-start: auto; color: var(--muted); font-size: .85rem; white-space: nowrap; }
.xp-quote { display: table; max-width: 100%; margin: 10px 0 4px; padding: 10px 14px; background: var(--cream); border-radius: 4px 14px 14px 14px; font-size: .97rem; white-space: pre-line; }
.xp-chips { margin-top: 4px; }
.xp-follow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 10px; }
.xp-follow .badge .icon { width: 13px; height: 13px; vertical-align: -2px; }
.xp-note { flex-basis: 100%; margin: 0; font-size: .9rem; }
.xp-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.xp-empty p { margin: 0; }

@media (max-width: 1100px) {
  .xp-hero { grid-template-columns: minmax(0, 1fr); }
  .xp-advisors { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .xp-score { flex-direction: column; text-align: center; gap: 12px; }
  .ring { width: 130px; height: 130px; }
  .xp-kpis { gap: 12px; }
  .xp-kpi { flex-direction: column; align-items: flex-start; gap: 8px; padding: 14px; }
  .xp-kpi .value { font-size: 1.5rem; }
  .xp-advisor { grid-template-columns: auto minmax(0, 1fr) 44px; }
  .xp-advisor-bar { grid-column: 2 / 4; grid-row: 2; }
  .xp-tools .filters { justify-content: stretch; }
}
/* חוויות: the tabs, the overview's rows, the list, the customer's page, the settings */
.xp-tab-count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; margin-inline-start: 6px; border-radius: 99px; background: var(--bad); color: #fff; font-size: .75rem; font-weight: 700; }
.xp-state { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.xp-row2 { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 18px; margin-bottom: 18px; align-items: start; }
.xp-row2 .card, .xp-row3 .card { margin: 0; }
.xp-row3 { align-items: start; }
.xp-row3 .xp-advisors { grid-template-columns: minmax(0, 1fr); }
.xp-open { list-style: none; margin: 0; padding: 0; }
.xp-open li + li { border-top: 1px solid var(--line); }
.xp-open a { display: flex; align-items: center; gap: 12px; padding: 10px 2px; color: inherit; text-decoration: none; }
.xp-open a:hover b { color: var(--coral-text); }
.xp-open-main { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; line-height: 1.35; }
.xp-open-main small { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.xp-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 12px 0; }
.xp-empty p { margin: 0; }

.xp-count { margin: 0 0 6px; }
.xp-rows { list-style: none; margin: 0; padding: 0; }
.xp-rows li + li { border-top: 1px solid var(--line); }
.xp-line { display: flex; align-items: flex-start; gap: 14px; padding: 14px 6px; color: inherit; text-decoration: none; border-radius: 10px; }
.xp-line:hover { background: var(--cream); }
.xp-line:focus-visible { outline: 2px solid var(--coral); outline-offset: 2px; }
.xp-line-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1 1 auto; }
.xp-line-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.xp-line-top b { font-family: var(--font-head); font-weight: 600; font-size: 1.02rem; }
.xp-line-meta { display: flex; flex-wrap: wrap; gap: 2px 14px; color: var(--muted); font-size: .86rem; }
.xp-line-meta .icon { width: 13px; height: 13px; vertical-align: -2px; }
.xp-line-quote::before, .xp-line-quote::after, .xp-quote::before, .xp-quote::after { content: '"'; color: var(--muted); font-weight: 700; }
.xp-line-quote::before, .xp-quote::before { margin-inline-end: 2px; }
.xp-line-quote::after, .xp-quote::after { margin-inline-start: 2px; }
.xp-line-quote { color: var(--ink); font-size: .95rem; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; }
.xp-channel { display: inline-flex; align-items: center; gap: 4px; font-size: .8rem; font-weight: 600; color: var(--ink); background: var(--cream); border: 1px solid var(--line); border-radius: 99px; padding: 1px 9px; }
.xp-channel .icon { width: 13px; height: 13px; }
/* «שיחת ניסיון»: the form, and the call beside it. */
.demo-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 18px; align-items: start; }
.demo-grid .card { margin: 0; }
@media (max-width: 1000px) { .demo-grid { grid-template-columns: minmax(0, 1fr); } }
/* An experience's history: one line per step, an icon on a thin line down the side. */
.xp-history { list-style: none; margin: 0 0 16px; padding: 0; position: relative; }
.xp-history::before { content: ""; position: absolute; inset-block: 14px; inset-inline-start: 13px; width: 1px; background: var(--line); }
.xp-history li { display: flex; gap: 12px; align-items: flex-start; padding: 6px 0; position: relative; }
.xp-history-icon { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--cream); color: var(--ink-2); flex: 0 0 auto; }
.xp-history-icon .icon { width: 14px; height: 14px; }
.xp-history-text { display: flex; flex-direction: column; min-width: 0; padding-top: 3px; }
.xp-history-text b { font-weight: 600; font-size: .92rem; }
.xp-history-text small { color: var(--muted); font-size: .8rem; }
.xp-history li.good .xp-history-icon { background: var(--good-soft); color: var(--good); }
.xp-history li.bad .xp-history-icon { background: var(--bad-soft); color: var(--bad); }
.xp-history li.planned { opacity: .7; }
.xp-history li.planned .xp-history-icon { background: #fff; border: 1px dashed var(--line); }
/* The customer list's side: the time, and under it how they answered. */
.xp-side { margin-inline-start: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex: 0 0 auto; }
.xp-side .xp-time { margin: 0; }
.xp-answered { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; }
.xp-answered .icon { width: 16px; height: 16px; }
.xp-answered.by-wa { background: var(--good-soft); color: var(--good); }
.xp-answered.by-call { background: #E6E8F5; color: var(--ink-2); }
/* A complaint: waiting for the garage, or handled. */
.xp-handle { display: inline-flex; align-items: center; gap: 5px; font-size: .82rem; font-weight: 700; border-radius: 99px; padding: 2px 10px 2px 11px; }
.xp-handle .icon { width: 14px; height: 14px; }
.xp-handle.open { background: var(--bad); color: #fff; }
.xp-handle.done { background: var(--good-soft); color: var(--good); border: 1px solid #B9E3CB; }
.xp-line.xp-open { background: #FFF5F4; }
.xp-line.xp-open:hover { background: var(--bad-soft); }

.xp-item-grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 18px; align-items: start; }
.xp-item-grid .card { margin: 0; }
.xp-item-grid .xp-call { grid-column: 1 / -1; }
.xp-verdict-head { display: flex; align-items: center; gap: 16px; margin-bottom: 6px; }
.xp-verdict-big { font-family: var(--font-head); font-weight: 700; font-size: 1.6rem; line-height: 1.2; }
.xp-verdict-big.happy { color: var(--good); } .xp-verdict-big.unhappy { color: var(--bad); } .xp-verdict-big.waiting { color: var(--muted); }
.xp-verdict-sub { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 4px; font-size: .9rem; }
.xp-verdict-card.happy .xp-quote { background: #F2FBF6; }
.xp-verdict-card.unhappy .xp-quote { background: #FFF6F5; }
.xp-follow { flex-direction: column; align-items: stretch; border-top: 1px solid var(--line); padding-top: 14px; margin-top: 16px; }
.xp-follow-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.xp-follow form { max-width: 520px; }
.xp-sub { font-size: .95rem; margin: 18px 0 8px; }
.xp-call h2 { display: flex; align-items: center; gap: 8px; }
.xp-audio { display: block; width: 100%; max-width: 560px; margin: 4px 0 14px; }
.xp-summary { margin: 0 0 14px; }
.xp-transcript summary { cursor: pointer; font-weight: 600; margin-bottom: 10px; }
.xp-turns { display: flex; flex-direction: column; gap: 8px; max-height: 460px; overflow-y: auto; padding: 4px; }
.xp-turn { max-width: 78%; padding: 8px 12px; border-radius: 14px; background: var(--cream); }
.xp-turn p { margin: 2px 0 0; white-space: pre-line; }
.xp-turn.agent { align-self: flex-start; border-start-start-radius: 4px; }
.xp-turn.customer { align-self: flex-end; background: #E9F2FF; border-start-end-radius: 4px; }
.xp-turn-who { font-size: .75rem; font-weight: 600; color: var(--muted); }

.xp-settings-form { max-width: 820px; }
.xp-set { margin-bottom: 18px; }
.xp-set-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 14px; }
.xp-set-head h2 { margin: 0 0 2px; }
.xp-set-head p { margin: 0; }
.xp-set-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--cream); flex: 0 0 auto; }
.xp-set .check { margin-bottom: 14px; font-weight: 500; }
.xp-set-fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 16px; }
.xp-set-wide { max-width: 560px; }
#delay { max-width: 160px; }
.xp-days { display: flex; flex-direction: column; gap: 8px; margin-bottom: 4px; }
.xp-day { display: grid; grid-template-columns: 96px 124px max-content 124px; justify-content: start; align-items: center; gap: 10px; }
.xp-day .check { margin: 0; }
.xp-day input[type="time"] { direction: ltr; }
.xp-set-actions { margin-top: 4px; }
.xp-recipients { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.xp-recipient .field { margin-bottom: 0; }
.xp-replies { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.xp-replies-part { border-top: 1px solid var(--line); margin-top: 18px; }
.xp-reply-head { font-size: .9rem; color: var(--ink-3); margin: 0 0 8px; }
.xp-reply { margin-bottom: 14px; }
.xp-reply-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; min-height: var(--control-h-sm, 32px); }
.xp-reply-label { font-weight: 500; font-size: .9rem; }
.xp-reply-phone { padding: 10px; }
/* The reply's own page: its emojis and values under the text. */
.xp-reply-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; }
.xp-reply-tools .chip { margin: 0; height: 30px; display: inline-flex; align-items: center; justify-content: center; }
/* Bold and the emojis at the far left, under the text. */
.xp-reply-format { display: flex; gap: 6px; margin-inline-start: auto; }
.xp-reply-tools .xp-tool { width: 36px; padding: 0; font-size: .95rem; }
.xp-emoji { position: relative; }
.xp-emoji > summary { list-style: none; cursor: pointer; user-select: none; }
.xp-emoji > summary::-webkit-details-marker { display: none; }
.xp-emoji > summary:hover, .xp-emoji[open] > summary { border-color: var(--ink-3); background: var(--coral-soft); }
.xp-emoji .wa-emoji-list { top: calc(100% + 6px); bottom: auto; inset-inline-start: auto; inset-inline-end: 0; width: 268px; }
/* One thanks for a satisfied customer shows: the one with the Google review while it is on, the plain one otherwise. */
.xp-settings-form:has(#reviewOn:checked) .xp-thanks-plain,
.xp-settings-form:not(:has(#reviewOn:checked)) .xp-thanks-review { display: none; }
.xp-settings-form .xp-set-head { align-items: center; }
.xp-advanced { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.xp-advanced .xp-sub { margin-top: 0; }
.xp-rule-add { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 220px) auto; gap: 0 12px; align-items: end; }
.xp-rule-add .field { margin-bottom: 0; }
/* רשימת הסרה: phone and name side by side, the same width. */
.xp-optout-add { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; }
.optout-add-actions { display: flex; gap: 8px; }
.optout-why { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; vertical-align: middle; }
.optout-via { flex: 0 0 auto; }
@media (max-width: 640px) { .optout-add-actions > .btn { flex: 1 1 0; } }
.xp-optouts .clip { max-width: 360px; }
.xp-advanced .table-wrap { margin-top: 14px; }
.xp-rules td:first-child { width: 120px; }
/* ביקורות בגוגל: the period's figures beside the chart of links sent and tapped. */
.xp-rv { margin-bottom: 18px; }
.xp-rv-body { display: grid; grid-template-columns: minmax(170px, 1fr) minmax(0, 4fr); gap: 24px; align-items: center; }
.xp-rv-stats { margin: 0; display: grid; gap: 14px; }
.xp-rv-stats div { display: flex; flex-direction: column; justify-content: space-between; }
.xp-rv-stats dt { color: var(--muted); font-size: .88rem; }
.xp-rv-stats dd { margin: 0; font-family: var(--font-head); font-weight: 700; font-size: 1.6rem; line-height: 1.2; font-variant-numeric: tabular-nums; }
.xp-rv-stats dd.click { color: var(--coral-text); }
.xp-rv-stats dd.written { color: var(--good); }
.xp-rv-place { font-family: var(--font-body); font-weight: 500; font-size: .85rem; color: var(--muted); margin-inline-start: 8px; white-space: nowrap; }
.dot.sent { background: #D5D3E2; }
.dot.click { background: var(--coral); }
.dot.written { background: var(--good); }
.reviews .bar-written { fill: var(--good); }
.reviews .cnt .written { fill: var(--good); }
.xp-stars { color: #E3A008; letter-spacing: 1px; white-space: nowrap; }
.xp-greviews { list-style: none; margin: 14px 0 0; padding: 0; }
.xp-greviews > li + li { border-top: 1px solid var(--line); }
.xp-greviews .xp-greview { padding: 14px 0; }
.xp-greview p { margin: 6px 0 0; white-space: pre-line; overflow-wrap: anywhere; }
.xp-greview-head { display: flex; align-items: center; gap: 4px 12px; flex-wrap: wrap; }
.xp-greview-match { display: flex; align-items: center; gap: 8px 12px; flex-wrap: wrap; margin-top: 10px; }
form.xp-greview-link { display: flex; gap: 8px; align-items: center; width: min(100%, 360px); }
.xp-greview-link select { height: var(--control-h-sm); min-height: 0; padding-block: 0; flex: 1 1 auto; min-width: 0; width: auto; }
.xp-greview-link .btn { flex: 0 0 auto; }
.xp-tools .xp-rv-place { margin: 0; }
.xp-gconnect .xp-sub { margin: 4px 0 10px; }
.xp-gconnect-row { display: flex; align-items: center; gap: 8px 12px; flex-wrap: wrap; }
.xp-gconnect-row select { height: var(--control-h-sm); min-height: 0; padding-block: 0; width: auto; flex: 1 1 200px; min-width: 0; }
.xp-gconnect .notice { margin: 10px 0 0; }
.xp-gconnect .badge { display: inline-flex; align-items: center; gap: 4px; }
.xp-gconnect .badge svg { width: 14px; height: 14px; }
.reviews .base { stroke: var(--line); }
.reviews .bar-sent { fill: #D5D3E2; }
.reviews .bar-click { fill: var(--coral); }
.reviews .bar-none { fill: var(--line); }
.reviews .hit { fill: transparent; }
.reviews .col:hover .hit { fill: var(--cream); }
.reviews .cnt { font-size: 13px; font-weight: 700; fill: var(--muted); opacity: 0; pointer-events: none; }
.reviews .cnt .click { fill: var(--coral-text); }
.reviews .col:hover .cnt { opacity: 1; }
@media (max-width: 900px) {
  .xp-rv-body { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .xp-rv-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
  .xp-rv-stats dt { font-size: .8rem; }
  .xp-rv-stats dd { font-size: 1.35rem; }
}

@media (max-width: 1100px) {
  .xp-row2, .xp-item-grid, .xp-since { grid-template-columns: minmax(0, 1fr); }
  .xp-since-kpis { border-inline-start: 0; padding-inline-start: 0; border-top: 1px solid var(--line); padding-top: 14px; }
}
@media (max-width: 640px) {
  .xp-set-fields, .xp-recipients { grid-template-columns: minmax(0, 1fr); }
  .xp-recipient + .xp-recipient { margin-top: 18px; }
  .xp-replies { grid-template-columns: minmax(0, 1fr); }
  .xp-reply-col + .xp-reply-col { margin-top: 6px; }
  .xp-rule-add { grid-template-columns: minmax(0, 1fr); gap: 12px 0; }
  .xp-rules td:first-child { width: auto; }
  .xp-day { grid-template-columns: 1fr 1fr; }
  .xp-day .check { grid-column: 1 / -1; }
  .xp-day > span { display: none; }
  .xp-line { gap: 10px; padding: 12px 2px; }
  .xp-line .face { width: 34px; height: 34px; }
  .xp-line .xp-time { display: none; }
  .xp-answered { width: 26px; height: 26px; }
  .xp-turn { max-width: 92%; }
}
@media (prefers-reduced-motion: reduce) { a.xp-kpi { transition: none; } a.xp-kpi:hover { transform: none; } }

/* ---------- נתוני המוסך: לוח בקרה ותזכורות ---------- */
.columns .base { stroke: var(--line); }
.columns .bar { fill: var(--ink); opacity: .82; }
.columns .bar.now { fill: var(--coral); opacity: 1; }
.columns .hit { fill: transparent; }
.columns .col:hover .hit { fill: var(--cream); }
.columns .col:hover .bar { opacity: 1; }
.columns .cnt { font-size: 15px; font-weight: 700; fill: var(--ink); opacity: 0; pointer-events: none; }
.columns .col:hover .cnt { opacity: 1; }
.columns text.lbl { font-size: 14px; }
/* ---------- «לוח בקרה» of the garage (owner 2026-10-25, design «סבב 2 ב'»): the year's chart, four numbers with
   their trend, the advisors and what is coming. Drawn in SVG with classes only: the page carries no inline style. */
.yr-hero { padding: 24px 26px 18px; }
.yr-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.yr-total { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.yr-big { font-family: var(--font-head); font-weight: 700; font-size: 3rem; line-height: 1.1; }
.yr-delta { font-size: .88rem; font-weight: 600; }
.yr-delta.up { color: var(--good); }
.yr-delta.down { color: var(--bad); }
.yr-chart { background: var(--bg); border-radius: 18px; padding: 14px 18px 10px; }
.yr-now { display: flex; justify-content: flex-start; margin-bottom: 6px; }
.yr-chip { display: inline-flex; flex-direction: column; background: var(--ink); color: #fff; border-radius: 12px; padding: 7px 12px; font-size: .85rem; }
.yr-chip small { color: #FFB4A6; font-size: .75rem; }
.yr-svg { display: block; width: 100%; height: auto; }
.yr-grid { stroke: var(--line); stroke-width: 1; }
.yr-base { stroke: #D9D4E0; stroke-width: 1.5; }
.yr-area { fill: var(--coral-soft); }
.yr-line { fill: none; stroke: var(--coral); stroke-width: 4; stroke-linejoin: round; stroke-linecap: round; }
.yr-now-line { stroke: var(--ink); stroke-width: 1.5; stroke-dasharray: 5 5; }
/* The hover, as in the experiences' trends: the strip under the mouse shows its point, its guide and its value. */
.yr-hit { fill: transparent; }
.yr-pt:hover .yr-hit { fill: rgba(27, 31, 59, .04); }
.yr-guide { stroke: var(--ink); stroke-width: 1.5; opacity: 0; }
.yr-dot { fill: var(--coral); stroke: #fff; stroke-width: 3; opacity: 0; }
.yr-pt.now .yr-dot { fill: var(--ink); opacity: 1; }
.yr-bubble { opacity: 0; pointer-events: none; }
.yr-bubble rect { fill: var(--ink); }
.yr-bubble text { fill: #fff; font-size: 16px; font-weight: 600; font-family: var(--font-body); }
.yr-pt:hover .yr-guide, .yr-pt:hover .yr-dot, .yr-pt:hover .yr-bubble { opacity: 1; }
.yr-lbl { fill: var(--muted); font-size: 14px; font-family: var(--font-body); }
.yr-pt:hover .yr-lbl { fill: var(--ink); font-weight: 700; }
.yr-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 18px 0; }
.yr-tile { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; min-width: 0; color: inherit; text-decoration: none; }
a.yr-tile:hover { box-shadow: 0 16px 34px -20px rgba(27, 31, 59, .5); }
.yr-tile .muted { font-size: .85rem; }
.yr-tile-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 10px; }
.yr-num { font-family: var(--font-head); font-weight: 700; font-size: 1.9rem; line-height: 1.1; }
.yr-spark { width: 110px; height: 38px; flex: 0 1 auto; }
.yr-spark polyline { fill: none; stroke: var(--ink); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.yr-spark.coral polyline { stroke: var(--coral); }
.yr-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.yr-row > .card { margin: 0; }
.yr-adv { display: grid; grid-template-columns: minmax(110px, 150px) minmax(0, 1fr) 96px; align-items: center; gap: 12px; margin: 12px 0; }
.yr-adv > span { display: flex; flex-direction: column; line-height: 1.3; }
.yr-adv small { font-size: .8rem; }
.yr-adv .pbar { height: 14px; }
.yr-adv-sum { text-align: end; font-variant-numeric: tabular-nums; }
.yr-stack { display: block; width: 100%; height: 34px; margin: 4px 0 12px; }
.yr-seg.service { fill: var(--ink); }
.yr-seg.test { fill: var(--coral); }
.yr-seg.late { fill: var(--bad); }
.yr-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-bottom: 14px; font-size: .9rem; }
.yr-legend > * { display: inline-flex; align-items: center; gap: 6px; color: inherit; text-decoration: none; }
.yr-legend a:hover { text-decoration: underline; }
.yr-legend .late { color: var(--bad); }
.yr-legend b { font-family: var(--font-head); font-size: 1.1rem; }
.yr-key { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }
.yr-key.service { background: var(--ink); }
.yr-key.test { background: var(--coral); }
.yr-key.late { background: var(--bad); }
.yr-good { color: var(--good); }
.gd-funnel { display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--line); padding-top: 14px; }
.gd-funnel b { font-family: var(--font-head); font-size: 1.2rem; margin-inline-end: 4px; }
.gd-funnel b.gd-state-text { font-size: 1rem; margin: 0; }
.gd-failed { color: var(--bad); }
.gd-settings fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.gd-checks { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
/* One reminder kind, or the booking switch, per block: a line between them. */
.gd-kind + .gd-kind { border-top: 1px solid var(--line); padding-top: 16px; margin-top: 4px; }
.gd-kind .xp-set-fields { margin-bottom: 4px; }
.gd-kind > p { margin: -8px 0 0; }
.gd-wide { grid-column: span 2; }
/* «קביעה ביומן» shows only while «כולל קביעה ביומן» is ticked; its fields are still sent, so nothing is lost. */
.gd-settings:has(input[name="input.BookingEnabled"]:not(:checked)) .gd-booking { display: none; }
/* «הודעות על תורים ביומן»: each message's options show while it is ticked, the address while a Waze button is asked for. */
.gd-appt-sub { display: flex; flex-direction: column; gap: 10px; margin-inline-start: 28px; margin-top: 10px; }
.gd-appt-sub .xp-set-fields { margin: 0; }
.gd-settings:has(input[name="input.ApptConfirmEnabled"]:not(:checked)) .gd-appt-confirm,
.gd-settings:has(input[name="input.ApptReminderEnabled"]:not(:checked)) .gd-appt-reminder,
.gd-settings:has(input[name="input.ApptConfirmEnabled"]:not(:checked)):has(input[name="input.ApptReminderEnabled"]:not(:checked)) .gd-appt-address,
.gd-settings:has(input[name="input.ApptConfirmEnabled"]:not(:checked)):has(input[name="input.ApptReminderWaze"]:not(:checked)) .gd-appt-address,
.gd-settings:has(input[name="input.ApptConfirmWaze"]:not(:checked)):has(input[name="input.ApptReminderEnabled"]:not(:checked)) .gd-appt-address,
.gd-settings:has(input[name="input.ApptConfirmWaze"]:not(:checked)):has(input[name="input.ApptReminderWaze"]:not(:checked)) .gd-appt-address { display: none; }
@media (max-width: 640px) { .gd-wide { grid-column: auto; } }
@media (max-width: 1100px) {
  .yr-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .yr-row { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .yr-big { font-size: 2.2rem; }
  .yr-tiles { gap: 10px; }
  .yr-num { font-size: 1.4rem; }
  .yr-spark { width: 70px; }
  .yr-adv { grid-template-columns: minmax(90px, 120px) minmax(0, 1fr) 80px; }
}
.due-kind { display: inline-block; font-size: .82rem; font-weight: 600; padding: 1px 10px; border-radius: 99px; }
.due-kind.service { background: var(--cream); color: var(--ink); }
.due-kind.test { background: #E9F2FF; color: #1E4FA8; }
.due-sent { color: var(--good); }
.due-sent .icon { width: 13px; height: 13px; vertical-align: -2px; }
.due-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.due-stats a.stat { color: inherit; text-decoration: none; }
.due-stats a.stat:hover { box-shadow: 0 16px 34px -20px rgba(27, 31, 59, .5); }
.due-sent-list { display: flex; flex-direction: column; gap: 2px; margin-top: 4px; font-size: .82rem; }
.due-refused { color: var(--bad); }
@media (max-width: 640px) { .due-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* ---------- משתמשים ---------- */
.users-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr); gap: 18px; align-items: start; }
.users-grid .card { margin: 0; }
@media (max-width: 1000px) { .users-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- הדף הציבורי של המוסך: קביעת תור ---------- */
body.pub { background: var(--cream); }
.pub-main { max-width: 560px; margin: 0 auto; padding: 28px 16px 24px; display: flex; flex-direction: column; gap: 18px; min-height: 100vh; }
.pub-head { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.pub-logo { max-width: 180px; max-height: 90px; width: auto; height: auto; object-fit: contain; }
.pub-garage { font-family: var(--font-head); font-weight: 600; font-size: 1.1rem; }
.pub-card { background: var(--card); border-radius: 22px; padding: 24px 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 14px; }
.pub-card p { margin: 0; }
.pub-title { font-size: 1.45rem; margin: 0; text-wrap: balance; }
.pub-sub { color: var(--muted); }
.pub-done { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; background: var(--good-soft); color: var(--good); font-weight: 700; padding: 6px 14px; border-radius: 99px; }
.pub-booking { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 18px; margin: 0; padding: 16px; background: var(--cream); border-radius: 14px; }
.pub-booking dt { color: var(--muted); }
.pub-booking dd { margin: 0; }
.pub-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.pub-confirm { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; padding: 16px; border-radius: 14px; background: var(--coral-soft); }
.pub-tel { font-weight: 700; color: var(--ink); }

/* «ביטול התור»: the question opens in place, no trip to the server. */
.pub-cancel > summary { list-style: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pub-cancel > summary::-webkit-details-marker { display: none; }
.pub-cancel-closed { width: 100%; }
.pub-cancel-open { display: none; }
.pub-cancel[open] { flex-basis: 100%; padding: 16px; border-radius: 14px; background: var(--coral-soft); }
.pub-cancel[open] .pub-cancel-closed { display: none; }
.pub-cancel[open] .pub-cancel-open { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pub-cancel-back { color: var(--muted); font-size: .9rem; text-decoration: underline; }
.pub-cancel form { margin-top: 12px; }
.pub-cancel-yes { width: 100%; background: var(--bad); color: #fff; }
.pub-cancel-yes:hover { filter: brightness(.95); }

/* The calendar, chosen with no script (owner 2026-10-27): radios shown by CSS — one month at a time, a day's times
   right under its week (grid «dense» puts the rest of the week back beside the day), the chosen time marked. */
.pub-pick { display: flex; flex-direction: column; gap: 10px; }
.pub-step { color: var(--muted); font-size: .9rem; }
.pub-mradio, .pub-dradio, .pub-slot input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }
.pub-mradio + .pub-cal { display: none; }
.pub-mradio:checked + .pub-cal { display: block; }
.pub-cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.pub-cal-head b { font-family: var(--font-head); font-size: 1.05rem; }
.pub-nav { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); color: var(--ink); font-size: 1.1rem; cursor: pointer; user-select: none; -webkit-tap-highlight-color: transparent; }
.pub-nav:hover { border-color: var(--ink); }
.pub-nav.off { opacity: .3; cursor: default; }
.pub-grid { position: relative; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); grid-auto-flow: row dense; gap: 6px; }
.pub-dow { text-align: center; font-size: .78rem; color: var(--muted); font-weight: 600; padding-bottom: 2px; }
.pub-dayitem { display: contents; }
.pub-day { display: grid; place-items: center; aspect-ratio: 1; min-height: 36px; border-radius: 12px; font-variant-numeric: tabular-nums; color: #B3B0BD; font-size: .95rem; }
.pub-day.empty { visibility: hidden; }
.pub-day.today { outline: 1px dashed var(--line); }
.pub-day.free { color: var(--ink); background: var(--good-soft); font-weight: 700; cursor: pointer; -webkit-tap-highlight-color: transparent; transition: background .12s, color .12s; }
.pub-day.free:hover { outline: 2px solid var(--good); }
.pub-dradio:checked + .pub-day { background: var(--ink); color: #fff; outline: 0; }
.pub-dradio:focus-visible + .pub-day { outline: 2px solid var(--coral); outline-offset: 2px; }
.pub-times { display: none; grid-column: 1 / -1; margin: 2px 0 6px; padding: 14px; border-radius: 16px; background: var(--cream); }
.pub-dradio:checked ~ .pub-times { display: flex; flex-direction: column; gap: 12px; }
.pub-times-head { font-family: var(--font-head); font-weight: 600; }
.pub-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.pub-slot { position: relative; display: block; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pub-slot span { display: flex; align-items: center; justify-content: center; min-height: 44px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; transition: background .12s, color .12s; }
.pub-slot:hover span { border-color: var(--ink); }
.pub-slot input:checked + span { background: var(--ink); color: #fff; border-color: var(--ink); }
.pub-slot input:focus-visible + span { outline: 2px solid var(--coral); outline-offset: 2px; }
.pub-go { align-self: stretch; }

@media (max-width: 420px) {
  .pub-main { padding: 18px 12px 18px; gap: 14px; }
  .pub-card { padding: 20px 14px; border-radius: 18px; }
  .pub-title { font-size: 1.3rem; }
  .pub-grid { gap: 4px; }
  .pub-day { border-radius: 10px; font-size: .9rem; }
  .pub-times { padding: 12px 10px; }
  .pub-slots { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pub-actions > .btn, .pub-cancel { flex: 1 1 100%; }
  .pub-booking { gap: 6px 12px; padding: 14px; }
}
.pub-foot { margin-top: auto; display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--muted); font-size: .82rem; padding-top: 8px; }
.pub-foot img { height: 18px; width: auto; }

/* ---------- «תפוצה» (owner 2026-10-26): a template to a list of customers or of uploaded numbers. */
.bc-filters { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 16px; align-items: end; }
.bc-filters .bc-wide { grid-column: 1 / -1; margin-bottom: 12px; }
.bc-upload { max-width: 640px; }
.bc-invalid { margin-top: 12px; }
.bc-invalid summary { cursor: pointer; font-weight: 600; color: var(--bad); margin-bottom: 10px; }
.bc-tpl { cursor: pointer; border: 1.5px solid var(--line); }
.bc-tpl:has(input:checked) { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(27, 31, 59, .12); }
.bc-off { margin-top: 16px; }
.bc-off summary { cursor: pointer; color: var(--muted); }
.bc-off ul { margin: 8px 0 0; padding-inline-start: 20px; }
.bc-tpl .tpl-phone, .bc-tpl .tpl-bubble, .bc-tpl .tpl-body, .bc-tpl .tpl-header, .bc-tpl .tpl-footer, .bc-tpl .tpl-btn { display: block; }
.bc-tpl .tpl-phone { display: flex; }
.bc-tpl-name { display: inline-flex; align-items: center; gap: 8px; }
.bc-tpl-name input { width: 18px; height: 18px; margin: 0; }
.bc-send { max-width: 640px; }
/* A template whose header is a file (owner 2026-12-03): its place in the preview, and the file field, shown only while
   such a template is chosen. */
.bc-media-box { display: flex; align-items: center; justify-content: center; min-height: 96px; margin-bottom: 6px; padding: 8px;
  border-radius: 8px; background: #DFE5E7; color: var(--muted); font-size: .9rem; overflow-wrap: anywhere; text-align: center; }
a.bc-media-box { color: #027EB5; text-decoration: none; }
.bc-media-shown { display: block; width: 100%; max-height: 320px; object-fit: contain; border-radius: 8px; margin-bottom: 6px; background: #DFE5E7; }
.bc-media { display: none; }
form:has(.bc-tpl[data-media="image"] input:checked) .bc-media-image,
form:has(.bc-tpl[data-media="video"] input:checked) .bc-media-video,
form:has(.bc-tpl[data-media="document"] input:checked) .bc-media-document { display: block; }
.bc-delete { margin-top: 14px; }
.bc-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: 12px 24px; margin: 0; }
.bc-facts dt { color: var(--muted); font-size: .85rem; }
.bc-facts dd { margin: 2px 0 0; }
.bc-message { margin-top: 16px; max-width: 420px; }
.bc-message summary { cursor: pointer; font-weight: 600; margin-bottom: 10px; }
@media (max-width: 900px) {
  .bc-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .bc-filters { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- «חוויות» → «שליחה מקובץ» (owner 2026-11-29): a survey to an uploaded file, now or at a time ahead. */
.xp-up-cols { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin-bottom: 14px; }
.xp-up-cols .chip { margin: 0; }
.xp-up-must { border-color: var(--coral); }
.xp-up-star { color: var(--coral); font-weight: 700; }
.xp-up-send { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
.xp-up-send > .card { margin: 0; display: flex; flex-direction: column; }
.xp-up-send > .card > form { margin-top: auto; }
.xp-up-when { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 0 12px; }
.xp-up-when .field { flex: 1 1 150px; min-width: 0; }
.xp-up-when .field input { width: 100%; }
.xp-up-when > .btn { margin-bottom: 16px; }
.xp-up-move { margin-top: 16px; max-width: 560px; }
.xp-up-skipped summary { color: var(--muted); }
@media (max-width: 640px) {
  .xp-up-send { grid-template-columns: minmax(0, 1fr); }
  .xp-up-when > .btn { flex: 1 1 100%; }
}
@media (max-width: 360px) {
  .seg-fill a { padding: 0 6px; }
}
