/* CARCAR — стилі за дизайном CARCAR_Screens (Onest, кораловий + темно-синій, світла тема). */

/* Onest (SIL OFL 1.1, fonts/OFL.txt) лежить у застосунку, щоб працювати без мережі. */
@font-face {
  font-family: Onest; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url("fonts/onest-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
@font-face {
  font-family: Onest; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url("fonts/onest-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Onest; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url("fonts/onest-latin.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+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #ffffff;
  --soft: #f3f5f8;
  --line: #e2e6ec;
  --text: #17202e;
  --muted: #5e6878;
  --faint: #8a93a3;
  --box: #b7bfcb;
  --accent: #c8402b;
  --accent-hover: #a8341f;
  --on-accent: #ffffff;
  --accent-soft: #fdecea;
  --navy: #1e3a5f;
  --on-navy: #ffffff;
  --ok: #137a3f;
  --ok-soft: #e3f5ea;
  --warn: #9a5b00;
  --warn-soft: #fff3dc;
  --danger: #b42318;
  --dim: rgb(23 32 46 / 32%);
  --tabs-h: 64px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #10151c;
    --soft: #1a212b;
    --line: #2a3140;
    --text: #e8ecf3;
    --muted: #a3acbd;
    --faint: #7d8798;
    --box: #5b6577;
    --accent: #ff7a66;
    --accent-hover: #ff9585;
    --on-accent: #10151c;
    --accent-soft: #3a1d18;
    --navy: #9db8dc;
    --on-navy: #10151c;
    --ok: #5fd48f;
    --ok-soft: #15301f;
    --warn: #f3b850;
    --warn-soft: #33270f;
    --danger: #ff8a80;
    --dim: rgb(0 0 0 / 55%);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
    --bg: #10151c;
    --soft: #1a212b;
    --line: #2a3140;
    --text: #e8ecf3;
    --muted: #a3acbd;
    --faint: #7d8798;
    --box: #5b6577;
    --accent: #ff7a66;
    --accent-hover: #ff9585;
    --on-accent: #10151c;
    --accent-soft: #3a1d18;
    --navy: #9db8dc;
    --on-navy: #10151c;
    --ok: #5fd48f;
    --ok-soft: #15301f;
    --warn: #f3b850;
    --warn-soft: #33270f;
    --danger: #ff8a80;
    --dim: rgb(0 0 0 / 55%);
    color-scheme: dark;
  }

* { box-sizing: border-box; }
html, body { margin: 0; }

body {
  background: var(--bg);
  color: var(--text);
  font: 16px/1.45 Onest, system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom) + 16px);
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
p a:not(.btn) { text-decoration: underline; text-underline-offset: 2px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
svg.ic { flex: none; display: block; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ---------- шапка й навігація ---------- */

.top {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 16px 12px; background: var(--bg);
}
.brand { display: inline-flex; align-items: center; gap: 8px; font-size: 20px; font-weight: 800; letter-spacing: .5px; color: var(--text); }
.brand:hover { color: var(--text); }
.brand .c1 { color: var(--accent); }
.brand .c2 { color: var(--navy); margin-left: -8px; }
.city { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; font-size: 15px; color: var(--muted); }

main { max-width: 720px; margin: 0 auto; padding: 0 16px; outline: none; }

.tabs {
  position: fixed; inset: auto 0 0 0; z-index: 7;
  display: grid; grid-template-columns: repeat(4, 1fr);
  height: calc(var(--tabs-h) + env(safe-area-inset-bottom));
  padding: 8px 0 env(safe-area-inset-bottom);
  background: var(--bg); border-top: 1px solid var(--line);
}
.tabs a { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 12px; font-weight: 500; color: var(--muted); }
.tabs a[aria-current="page"] { color: var(--accent); font-weight: 700; }
.tab-ic { position: relative; height: 24px; }
.tabs a[data-badge] .tab-ic::after {
  content: ""; position: absolute; top: -2px; right: -5px;
  width: 9px; height: 9px; border-radius: 50%; background: var(--accent); border: 2px solid var(--bg);
}

/* ---------- типографіка ---------- */

h1 { font-size: 28px; font-weight: 800; line-height: 1.15; letter-spacing: -.3px; margin: 8px 0 12px; text-wrap: pretty; }
h1.catalog-title { font-size: 26px; margin: 14px 0; }
h2 { font-size: 17px; font-weight: 700; margin: 20px 0 10px; }
h2.big { font-size: 20px; }
.lead { font-size: 15px; color: var(--muted); margin: 0 0 14px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.note { font-size: 13px; color: var(--muted); text-align: center; margin: 24px 0 8px; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.grid2 .full { grid-column: 1 / -1; }
.grid2 .btn { padding: 0 4px; }
.grid2 .btn.primary { font-size: 15px; }

/* ---------- кнопки ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 44px; padding: 0 14px; border-radius: 12px;
  border: 1.5px solid var(--navy); background: var(--bg); color: var(--navy);
  font-size: 15px; font-weight: 600; text-align: center; line-height: 1.2;
}
.btn:hover { color: var(--navy); background: var(--soft); }
.btn.primary { min-height: 52px; border-radius: 14px; border-color: var(--accent); background: var(--accent); color: var(--on-accent); font-size: 16px; font-weight: 700; }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--on-accent); }
.btn.navy { border-color: var(--navy); background: var(--navy); color: var(--on-navy); border-radius: 10px; font-size: 14px; }
.btn.navy:hover { opacity: .92; color: var(--on-navy); background: var(--navy); }
.btn.soft { border-color: var(--soft); background: var(--soft); color: var(--navy); }
.btn.text-danger { border-color: transparent; background: transparent; color: var(--danger); }
.btn.text-danger:hover { background: var(--soft); color: var(--danger); }
.btn.line-danger { border-color: var(--line); color: var(--danger); min-height: 52px; border-radius: 14px; font-size: 16px; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .45; cursor: not-allowed; }

.back { display: inline-flex; align-items: center; gap: 2px; min-height: 44px; margin-left: -6px; font-size: 15px; font-weight: 500; color: var(--navy); }
.back:hover { color: var(--navy); }
.topbar { display: flex; align-items: center; justify-content: space-between; }

.fav { width: 44px; height: 44px; margin: -8px -8px 0 0; border: 0; background: none; color: var(--muted); display: flex; align-items: center; justify-content: center; flex: none; }
.fav[aria-pressed="true"] { color: var(--accent); }
.topbar .fav { margin: 0 -8px 0 0; }

/* ---------- поля ---------- */

.field { display: block; }
.field > span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.field textarea { width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); font: inherit; font-size: 16px; resize: vertical; }
.field input, .field select, .select {
  width: 100%; height: 48px; padding: 0 14px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--bg); font-size: 16px;
}
.field select, .select, .pill-select {
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235e6878' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; background-size: 18px; padding-right: 38px;
}
.form-box { background: var(--soft); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 12px; }
.form-box input, .form-box select { background-color: var(--bg); }

/* ---------- каталог ---------- */

.banner { display: flex; align-items: center; gap: 12px; background: var(--warn-soft); border-radius: 16px; padding: 12px 14px; color: var(--text); margin-top: 4px; }
.banner:hover { color: var(--text); }
.banner-ic { width: 40px; height: 40px; border-radius: 12px; background: var(--bg); color: var(--warn); display: flex; align-items: center; justify-content: center; flex: none; }
.banner b { display: block; font-size: 15px; }
.banner .small { color: var(--muted); line-height: 1.35; display: block; margin-top: 2px; }
.banner > .ic:last-child { color: var(--muted); margin-left: auto; }

.search { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 14px; border-radius: 14px; background: var(--soft); color: var(--muted); }
.search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 16px; color: var(--text); }
.search:focus-within { outline: 3px solid var(--accent); outline-offset: 2px; }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 12px 16px 2px; margin: 0 -16px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px;
  border-radius: 999px; border: 1px solid var(--line); background: var(--bg); font-size: 14px; font-weight: 500; white-space: nowrap;
}
.chip[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: var(--on-navy); }

.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; padding: 12px 0 10px; }
.toolbar .row { flex-wrap: nowrap; gap: 6px; }
.pill-select {
  height: 32px; padding: 0 28px 0 10px; border: 0; border-radius: 10px; background-color: var(--soft);
  font-size: 13px; font-weight: 500; background-position: right 8px center; background-size: 14px;
}

.card { border: 1px solid var(--line); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--bg); }
.place { color: inherit; }
.place:hover { color: inherit; }
.head { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.pc-title { font-size: 17px; font-weight: 700; margin: 0; }
.pc-cat { display: flex; align-items: center; gap: 5px; font-size: 13px; color: var(--muted); margin-top: 3px; }

.meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 13px; color: var(--muted); }
.meta.lg { font-size: 14px; gap: 4px 14px; }
.rating { display: inline-flex; align-items: center; gap: 3px; color: var(--text); font-weight: 600; }
.rating .ic { color: var(--accent); }

.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; padding: 4px 9px; border-radius: 999px; background: var(--soft); color: var(--text); }
.badges.lg .badge { padding: 5px 10px; }
.badge.open { background: var(--ok-soft); color: var(--ok); }
.badge.closed { color: var(--muted); }
.badge.personal { background: var(--accent-soft); color: var(--text); padding: 2px 7px; font-size: 11px; vertical-align: 1px; }
.hours-list .item { padding: 10px 14px; font-size: 15px; }
.hours-list .item.today { font-weight: 700; }
.profile-card { gap: 12px; }
.sheet .pf .field input { height: 44px; }

.empty { text-align: center; padding: 32px 16px; color: var(--muted); }
.empty-ic { width: 64px; height: 64px; margin: 0 auto 8px; border-radius: 50%; background: var(--soft); color: var(--navy); display: flex; align-items: center; justify-content: center; }

/* ---------- картка точки ---------- */

.infobox { background: var(--soft); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 12px; margin-top: 12px; }
.infobox .addr { display: flex; align-items: center; gap: 8px; font-size: 15px; }
.cat-label { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .6px; margin: 16px 0 8px; }
.list { border: 1px solid var(--line); border-radius: 16px; }
.item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; }
.item + .item { border-top: 1px solid var(--line); }
.item .name { flex: 1; font-size: 15px; }
.item .name small { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }
.item .price { font-size: 15px; font-weight: 700; white-space: nowrap; }
label.item { cursor: pointer; padding: 10px 14px; }

.check {
  appearance: none; -webkit-appearance: none; flex: none; width: 22px; height: 22px; margin: 0;
  border: 1.5px solid var(--box); border-radius: 6px; background: var(--bg) center / 14px no-repeat;
}
.check:checked {
  border-color: var(--accent); background-color: var(--accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.5 4.5L19 7.5'/%3E%3C/svg%3E");
}

/* нижня панель над навігацією */
.dock {
  position: fixed; left: 0; right: 0; z-index: 4;
  bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom));
  background: var(--bg); border-top: 1px solid var(--line); padding: 12px 16px;
}
.dock > * { max-width: 688px; margin-left: auto; margin-right: auto; }
.dock .total { display: flex; justify-content: space-between; font-size: 15px; font-weight: 600; margin-bottom: 10px; }
.dock-space { height: 96px; }
.dock-space.tall { height: 128px; }

/* ---------- запис ---------- */

.days { display: flex; gap: 8px; overflow-x: auto; margin-right: -16px; padding-right: 16px; scrollbar-width: none; }
.days::-webkit-scrollbar { display: none; }
.day {
  flex: none; width: 76px; height: 68px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg);
  display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 12px; color: var(--muted); line-height: 1.25;
}
.day b { font-size: 18px; color: var(--text); }
.day[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: var(--on-navy); }
.day[aria-pressed="true"] b { color: var(--on-navy); }
.day.closed { background: var(--soft); border-color: var(--soft); cursor: not-allowed; }
.day.closed b { color: var(--muted); }

.slots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 10px; }
.slot { height: 44px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); font-size: 15px; font-weight: 500; }
.slot:disabled { border-color: var(--soft); background: var(--soft); color: var(--muted); text-decoration: line-through; cursor: not-allowed; }
.slot[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: var(--on-navy); font-weight: 700; }

.sheet-dim { position: fixed; inset: 0; z-index: 5; background: var(--dim); }
.sheet {
  position: fixed; left: 0; right: 0; z-index: 6; bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom));
  max-width: 720px; margin: 0 auto; background: var(--bg); border-radius: 24px 24px 0 0;
  box-shadow: 0 -8px 24px rgb(16 24 40 / 8%);
  padding: 8px 16px 14px; display: flex; flex-direction: column; gap: 14px;
}
.handle { width: 36px; height: 5px; border-radius: 3px; background: var(--line); align-self: center; }
.sheet-total { display: flex; justify-content: space-between; align-items: baseline; }
.sheet-total span { font-size: 15px; color: var(--muted); }
.sheet-total b { font-size: 28px; font-weight: 800; }
.perks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; font-size: 15px; }
.perks li { display: flex; align-items: center; gap: 12px; }
.perk-ic { width: 36px; height: 36px; border-radius: 10px; background: var(--soft); color: var(--navy); display: flex; align-items: center; justify-content: center; flex: none; }
.perk-ic.ok { background: var(--ok-soft); color: var(--ok); }
.sheet .demo { font-size: 13px; color: var(--muted); text-align: center; margin: 0; }

/* ---------- рейтинг і відгуки ---------- */

.stars { display: inline-flex; gap: 1px; color: var(--line); vertical-align: middle; }
.stars .on { color: var(--accent); }
.jump { display: flex; gap: 8px; margin-top: 16px; }
.jump a { flex: 1; display: flex; align-items: center; justify-content: center; min-height: 40px; border-radius: 10px; background: var(--soft); color: var(--navy); font-size: 14px; font-weight: 600; }
.jump a:hover { color: var(--navy); background: var(--line); }

.rating-box { display: flex; gap: 20px; align-items: center; border: 1px solid var(--line); border-radius: 16px; padding: 16px; }
.rating-main { display: flex; flex-direction: column; align-items: center; gap: 4px; flex: none; min-width: 96px; }
.rating-num { font-size: 40px; font-weight: 800; line-height: 1; }
.empty-rating p { margin: 0; color: var(--muted); font-size: 14px; }
.empty-rating .rating-num { color: var(--box); }
.bars { list-style: none; margin: 0; padding: 0; flex: 1; display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
.bars li { display: grid; grid-template-columns: 10px 1fr 20px; gap: 8px; align-items: center; }
.bars .bar { height: 6px; border-radius: 3px; background: var(--soft); overflow: hidden; }
.bars .bar span { display: block; height: 100%; background: var(--accent); border-radius: 3px; }
.bars .n { text-align: right; }

.review { border-top: 1px solid var(--line); padding-top: 12px; display: flex; flex-direction: column; gap: 6px; }
.review p { margin: 0; font-size: 15px; }
.review .small { display: flex; align-items: center; gap: 5px; }
.review .small .ic { color: var(--ok); }
.review .reply { background: var(--soft); border-radius: 12px; padding: 10px 12px; font-size: 14px; }
.review .reply b { display: block; font-size: 13px; margin-bottom: 2px; }
.my-review { background: var(--soft); border-radius: 14px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.my-review p { margin: 0; font-size: 14px; }

.review-form { display: flex; flex-direction: column; gap: 12px; border-top: 1px solid var(--line); padding-top: 14px; }
.star-input { border: 0; margin: 0; padding: 0; display: flex; gap: 4px; }
.star-input legend { font-size: 17px; font-weight: 700; padding: 0; margin-bottom: 8px; }
.star-input label { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; color: var(--line); cursor: pointer; border-radius: 10px; }
.star-input:has(input:checked) label { color: var(--accent); }
.star-input label:has(input:checked) ~ label { color: var(--line); }
.star-input:hover label { color: var(--accent); }
.star-input label:hover ~ label { color: var(--line); }
.star-input label:focus-within { outline: 3px solid var(--accent); outline-offset: 1px; }

/* ---------- мої записи ---------- */

.bk { border: 1px solid var(--line); border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.bk.hl { border: 1.5px solid var(--accent); }
.bk-status { font-size: 13px; font-weight: 600; color: var(--muted); }
.bk-status.go { color: var(--ok); }
.bk-status.warn { color: var(--warn); }
.bk-title { font-size: 18px; font-weight: 700; margin: 2px 0 0; }
.bk-title.sm { font-size: 17px; }
.bk-price { font-size: 18px; font-weight: 800; white-space: nowrap; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; list-style: none; margin: 0; padding: 0; font-size: 12px; font-weight: 500; text-align: center; color: var(--muted); }
.steps li::before { content: ""; display: block; height: 4px; border-radius: 2px; background: var(--line); margin-bottom: 6px; }
.steps li.on { color: var(--text); }
.steps li.on::before { background: var(--ok); }

.lines { display: flex; flex-direction: column; gap: 8px; font-size: 14px; color: var(--muted); }
.lines .il { display: flex; align-items: center; gap: 10px; }
.lines .il.strong { font-size: 15px; font-weight: 600; color: var(--text); }
.lines .svc { padding-left: 28px; }
.lines.tight { gap: 4px; }

.terms { font-size: 13px; color: var(--muted); text-align: center; margin: -6px 0 0; }

.notice { background: var(--soft); border-radius: 14px; padding: 12px 14px; font-size: 14px; line-height: 1.45; }
.notice b { display: block; font-size: 15px; margin-bottom: 2px; }
.notice.warn { background: var(--warn-soft); }
.notice.warn .label { color: var(--warn); }
.notice .label { font-size: 13px; font-weight: 600; margin-bottom: 4px; }
.notice.ok { background: var(--ok-soft); display: flex; gap: 10px; }
.notice.ok > .ic { color: var(--ok); }
.notice.ic-row { display: flex; gap: 10px; align-items: flex-start; }
.notice.ic-row > .ic { color: var(--ok); margin-top: 2px; }
.notice.ok b { font-size: 16px; }

.photos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.photos img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 12px; display: block; background: var(--soft); }
.thumbs { display: flex; gap: 6px; flex-wrap: wrap; }
.thumbs img { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; display: block; }
.facts { display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.facts .il { display: flex; align-items: flex-start; gap: 8px; }
.facts .il.muted { color: var(--muted); }

/* ---------- гараж ---------- */

.car-card { color: inherit; padding: 16px; gap: 12px; }
.car-card:hover { color: inherit; }
.car-top { display: flex; gap: 12px; align-items: center; }
.car-tile { width: 48px; height: 48px; border-radius: 14px; background: var(--soft); color: var(--navy); display: flex; align-items: center; justify-content: center; flex: none; }
.car-name { font-size: 18px; font-weight: 700; margin: 0; }
.car-sub { font-size: 14px; color: var(--muted); margin-top: 2px; }
.warn-pill { display: flex; align-items: center; gap: 8px; background: var(--warn-soft); color: var(--warn); border-radius: 10px; padding: 8px 10px; font-size: 13px; font-weight: 600; }
.card-foot { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 12px; font-size: 15px; font-weight: 600; color: var(--accent); }

.reminder { display: flex; align-items: center; gap: 10px; border-radius: 14px; padding: 6px 6px 6px 12px; min-height: 56px; font-size: 14px; line-height: 1.35; background: var(--soft); }
.reminder > span { flex: 1; }
.reminder.due { background: var(--warn-soft); }
.reminder.due > .ic { color: var(--warn); }
.reminder.ok { background: var(--ok-soft); padding-right: 12px; }
.reminder.ok > .ic { color: var(--ok); }
.reminder.info > .ic { color: var(--navy); }

.inline-form { display: flex; gap: 8px; align-items: flex-end; }
.inline-form .field { flex: 1; }
.inline-form .btn { min-height: 48px; padding: 0 18px; }

.history { padding: 14px; gap: 12px; }
.log-item { display: flex; flex-direction: column; gap: 6px; }
.log-item + .log-item { border-top: 1px solid var(--line); padding-top: 12px; }
.log-head { display: flex; justify-content: space-between; font-size: 15px; font-weight: 700; }
.log-meta { font-size: 13px; color: var(--muted); }

/* ---------- кабінет точки ---------- */

.balance-card { padding: 16px; gap: 14px; }
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tile { background: var(--soft); border-radius: 12px; padding: 12px; }
.tile span { display: block; font-size: 13px; font-weight: 600; color: var(--muted); line-height: 1.3; }
.tile b { display: block; font-size: 26px; font-weight: 800; margin-top: 6px; }
.tile.ok { background: var(--ok-soft); }
.tile.ok span { color: var(--ok); }
.fine { font-size: 13px; color: var(--muted); line-height: 1.45; margin: 0; }

.prow { flex-direction: row; justify-content: space-between; align-items: center; gap: 10px; color: inherit; }
.prow:hover { color: inherit; border-color: var(--box); }
.prow h3 { font-size: 15px; font-weight: 700; margin: 2px 0 0; }
.prow .price { font-size: 16px; font-weight: 800; white-space: nowrap; }

.dropzone {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  min-height: 88px; border: 1.5px dashed var(--box); border-radius: 14px; background: var(--soft);
  font-size: 15px; font-weight: 600; color: var(--navy); cursor: pointer; text-align: center; padding: 10px;
}
.dropzone:focus-within { outline: 3px solid var(--accent); outline-offset: 2px; }
.photo-count { font-size: 13px; font-weight: 500; color: var(--muted); }
.divider { border-top: 1px solid var(--line); padding-top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.link-card { flex-direction: row; align-items: center; gap: 12px; color: inherit; }
.link-card:hover { color: inherit; border-color: var(--box); }
.link-card > span { flex: 1; font-weight: 600; }
.link-card > .ic:first-child { color: var(--accent); }
.link-card .count { flex: none; min-width: 24px; height: 24px; padding: 0 7px; border-radius: 999px; background: var(--warn-soft); color: var(--warn); font-size: 13px; font-weight: 700; display: flex; align-items: center; justify-content: center; }

/* ---------- приведи друга ---------- */

.invite-card > span small { display: block; font-size: 13px; font-weight: 400; color: var(--muted); }
.invite-card > .ic:first-child { color: var(--accent); }
.bonus-banner { display: flex; align-items: center; gap: 10px; background: var(--ok-soft); color: var(--text); border-radius: 14px; padding: 10px 12px; font-size: 14px; margin-bottom: 10px; }
.bonus-banner:hover { color: var(--text); }
.bonus-banner > .ic { color: var(--ok); }
.invite-hero { display: flex; gap: 14px; align-items: center; background: var(--accent-soft); border-radius: 16px; padding: 16px; font-size: 14px; line-height: 1.45; }
.invite-hero b { display: block; font-size: 20px; margin-bottom: 4px; }
.invite-ic { width: 56px; height: 56px; border-radius: 16px; background: var(--accent); color: var(--on-accent); display: flex; align-items: center; justify-content: center; flex: none; }
.ref-code { font-size: 28px; font-weight: 800; letter-spacing: 2px; }
.ref-link { width: 100%; height: 44px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--soft); font-size: 14px; color: var(--muted); }
.how { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 8px; font-size: 15px; }
.bonus-sum { font-size: 24px; font-weight: 800; }
.ledger { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.ledger li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; font-size: 14px; }
.ledger li + li { border-top: 1px solid var(--line); }
.ledger small { display: block; font-size: 12px; color: var(--muted); }
.ledger b { white-space: nowrap; }
.ledger b.plus { color: var(--ok); }
.card.ledger { padding: 4px 14px; }
.bonus-line { display: flex; align-items: center; gap: 12px; background: var(--ok-soft); border-radius: 12px; padding: 10px 12px; font-size: 15px; cursor: pointer; }
.bonus-line span { flex: 1; }
.bonus-line small { display: block; font-size: 12px; color: var(--muted); }
.bonus-line b { color: var(--ok); white-space: nowrap; }
.my-review a { font-size: 14px; font-weight: 600; }

/* ---------- повідомлення ---------- */

.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom) + 20px); z-index: 20;
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none; max-width: calc(100% - 32px);
  background: var(--text); color: var(--bg); padding: 10px 16px; border-radius: 12px; font-size: 15px;
  transition: opacity .2s, transform .2s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* запити до точки */
.ask { display: grid; gap: 12px; }
.ask .req { display: grid; gap: 10px; }
.thread { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.thread .msg { max-width: 88%; padding: 9px 12px; border-radius: 14px; font-size: 15px; line-height: 1.4; background: var(--soft); white-space: pre-wrap; overflow-wrap: anywhere; }
.thread .msg.client { justify-self: end; background: var(--accent-soft); border-bottom-right-radius: 4px; }
.thread .msg.biz { justify-self: start; border-bottom-left-radius: 4px; }
.thread .who { display: block; font-size: 12px; color: var(--muted); margin-bottom: 2px; white-space: normal; }

/* повідомлення, гарячі вікна, черга, абонементи, акт приймання */
.badge.deal { background: var(--accent-soft); color: var(--text); }
.badge.power .ic, .badge.deal .ic { flex: none; }
.hot { margin-top: 14px; }
.hot-title { display: flex; align-items: center; gap: 6px; font-size: 17px; margin: 0 0 8px; }
.hot-title .ic { color: var(--accent); }
.hot-row { display: flex; gap: 10px; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 6px; scrollbar-width: none; }
.hot-row::-webkit-scrollbar { display: none; }
.hot-card { flex: 0 0 210px; display: flex; flex-direction: column; gap: 3px; text-decoration: none; color: var(--text); }
.hot-pct { align-self: flex-start; background: var(--accent); color: var(--on-accent); font-weight: 800; font-size: 14px; padding: 2px 8px; border-radius: 999px; margin-bottom: 4px; }
.slot { display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.1; }
.slot small { font-size: 11px; font-weight: 700; color: var(--accent); }
.slot.hot { border-color: var(--accent); }
.slot[aria-pressed="true"] small { color: var(--on-navy); }
.deal-note { display: flex; gap: 10px; align-items: flex-start; background: var(--accent-soft); margin-top: 14px; }
.deal-note > .ic { color: var(--accent); flex: none; margin-top: 2px; }
.queue-card { margin-top: 14px; display: grid; gap: 10px; }
.queue-card h2 { display: flex; align-items: center; gap: 8px; margin: 0; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--accent); text-decoration: underline; cursor: pointer; }
.cert-line { align-items: flex-end; }
.intake-card { margin-top: 10px; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.intake-card summary { cursor: pointer; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.msg-card.unread { border-color: var(--accent); }
.pass-item .btn { flex: none; }
.code { font-family: ui-monospace, monospace; letter-spacing: .5px; }
.notice > .ic { flex: none; }

[hidden] { display: none !important; }

/* знижки за годинами */
.deals-card { margin-top: 14px; display: grid; gap: 10px; background: linear-gradient(135deg, var(--accent-soft), var(--bg) 70%); }
.deals-card h2 { display: flex; align-items: center; gap: 8px; margin: 0; }
.deals-card h2 .ic { color: var(--accent); }
.deals-card ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.deals-card li { display: flex; align-items: center; gap: 12px; }
.deals-card li > span:last-child { display: flex; flex-direction: column; gap: 1px; }
.deals-card small { color: var(--muted); font-size: 13px; }
.dc-pct { flex: none; min-width: 54px; text-align: center; background: var(--accent); color: var(--on-accent); font-weight: 800; border-radius: 10px; padding: 6px 8px; }
.day { position: relative; }
.day.has-deal { border-color: var(--accent); }
.day-deal { display: block; margin-top: 3px; background: var(--accent); color: var(--on-accent) !important; font-size: 10px; font-weight: 800; padding: 1px 5px; border-radius: 999px; }
.day-deals { margin-top: 12px; }
.dd-track { position: relative; height: 26px; border-radius: 8px; background: var(--soft); margin-bottom: 18px; }
.dd-track b { position: absolute; top: 0; bottom: 0; border-radius: 8px; background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 800; display: flex; align-items: center; justify-content: center; overflow: hidden; white-space: nowrap; }
.dd-track i { position: absolute; top: 30px; font-style: normal; font-size: 11px; color: var(--muted); }
.dd-text { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 14px; font-weight: 600; }
.dd-text .ic { color: var(--accent); flex: none; }
.slot.hot { border-color: var(--accent); background: var(--accent-soft); height: 54px; }
.slot.hot small { font-size: 11px; }
.save-pill { display: flex; align-items: center; gap: 6px; margin: 0 0 8px; font-size: 13px; font-weight: 700; color: var(--accent); }

/* карта */
.seg-mini { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.seg-mini button { display: inline-flex; align-items: center; gap: 4px; border: 0; background: var(--bg); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; padding: 6px 10px; min-height: 34px; cursor: pointer; }
.seg-mini button[aria-pressed="true"] { background: var(--navy); color: var(--on-navy); }
.map { position: relative; height: min(62vh, 560px); border-radius: 16px; overflow: hidden; touch-action: none; cursor: grab; user-select: none; border: 1px solid var(--line); background: var(--map-out, #eef1f4); }
.map:active { cursor: grabbing; }
.map:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.map-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.map-land-out { fill: var(--map-out, #eef1f4); }
.map-city { fill: var(--map-land, #f9faf7); stroke: var(--map-edge, #c9d1db); stroke-width: 1.5; vector-effect: non-scaling-stroke; stroke-dasharray: 6 4; }
.map-water { fill: none; stroke: var(--map-water, #a9cdf0); stroke-width: 16; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.map-water.thin { stroke-width: 6; }
.map-label { font-size: calc(11px / var(--z, 1)); fill: var(--muted); text-anchor: middle; font-weight: 600; opacity: 0; transition: opacity .2s; pointer-events: none; }
.map.zoomed .map-label { opacity: .9; }
.map-pins { position: absolute; inset: 0; pointer-events: none; }
.pin { position: absolute; left: 0; top: 0; margin: -38px 0 0 -17px; width: 34px; height: 38px; border: 0; padding: 0; background: none; pointer-events: auto; cursor: pointer; }
.pin-shape { position: absolute; inset: 0; padding-bottom: 6px; display: flex; align-items: center; justify-content: center; color: #fff;
  background: #1e3a5f; clip-path: path('M17 38 L10 29 A15 15 0 1 1 24 29 Z'); filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .3)); }
.pin.c-wash .pin-shape { background: #2a78d6; }
.pin.c-tires .pin-shape { background: #1e3a5f; }
.pin.c-service .pin-shape { background: #6b4fd6; }
.pin.c-detailing .pin-shape { background: #b5361f; }
.pin.shut .pin-shape { background: #7b8494; }
.pin.sel, .pin:focus-visible { scale: 1.3; transform-origin: 17px 38px; z-index: 2; outline: none; }
.pin.sel .pin-shape, .pin:focus-visible .pin-shape { background: var(--accent); }
.pin-deal { position: absolute; top: -8px; left: 22px; background: var(--accent); color: var(--on-accent); font-size: 10px; font-weight: 800; padding: 1px 4px; border-radius: 999px; white-space: nowrap; box-shadow: 0 0 0 2px var(--bg); }
.pin-bolt { position: absolute; top: -6px; left: -8px; width: 16px; height: 16px; border-radius: 50%; background: #f3b850; color: #10151c; display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 2px var(--bg); }
.me-dot { position: absolute; left: 0; top: 0; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; background: #2a78d6; border: 3px solid #fff; box-shadow: 0 0 0 6px rgba(42, 120, 214, .25); }
.map-ctrl { position: absolute; right: 10px; top: 10px; display: grid; gap: 6px; }
.map-btn { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--text); font-size: 20px; font-weight: 700; cursor: pointer; box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.map-hint { position: absolute; left: 10px; bottom: 8px; margin: 0; font-size: 12px; color: var(--muted); background: color-mix(in srgb, var(--bg) 85%, transparent); padding: 2px 8px; border-radius: 6px; pointer-events: none; }
#map-card { margin-top: 12px; }
.map-empty { text-align: center; margin: 8px 0; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .map { --map-out: #141a22; --map-land: #1b222c; --map-edge: #3a4555; --map-water: #24476d; }
}
:root[data-theme="dark"] .map { --map-out: #141a22; --map-land: #1b222c; --map-edge: #3a4555; --map-water: #24476d; }
.slot.hot small { color: var(--accent-hover); }
.slot.hot[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: var(--on-navy); }
.slot.hot[aria-pressed="true"] small { color: var(--on-navy); }

/* детальна карта: тайли OpenStreetMap */
.map-tiles { position: absolute; inset: 0; overflow: hidden; background: #f2efe9; }
.map-tiles img { position: absolute; left: 0; top: 0; max-width: none; user-select: none; -webkit-user-drag: none; }
.map.detail .map-svg { display: none; }
.map:not(.detail) .map-tiles, .map:not(.detail) .map-attr { display: none; }
.map-layers { position: absolute; left: 10px; top: 10px; display: inline-flex; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.map-layers button { border: 0; background: var(--bg); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; padding: 8px 12px; min-height: 36px; cursor: pointer; }
.map-layers button[aria-pressed="true"] { background: var(--navy); color: var(--on-navy); }
.map-attr { position: absolute; right: 6px; bottom: 6px; font-size: 11px; background: color-mix(in srgb, var(--bg) 85%, transparent); color: var(--text); padding: 1px 6px; border-radius: 4px; text-decoration: underline; }
.map.detail .map-hint { bottom: 8px; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .map-tiles img { filter: invert(1) hue-rotate(180deg) brightness(.85) contrast(.9); }
}
:root[data-theme="dark"] .map-tiles img { filter: invert(1) hue-rotate(180deg) brightness(.85) contrast(.9); }

/* нагадування, регулярні записи, перевірка номера, фото у відгуках */
.visit-bar { display: grid; gap: 8px; margin-top: 10px; padding: 10px 12px; border-radius: 12px; background: var(--ok-soft); }
.visit-bar p { display: flex; align-items: center; gap: 6px; }
.btn.soft[aria-pressed="true"] { background: var(--ok-soft); border-color: var(--ok); color: var(--ok); }
.sub-form .grid2 .full { grid-column: 1 / -1; }
.plate-row { display: flex; gap: 8px; align-items: flex-end; }
.plate-row .field { flex: 1; }
.plate-row .btn { min-height: 48px; }
.plate-card { display: grid; gap: 6px; }
.plate-card ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 14px; }
.ok-text, .bad-text { display: inline-flex; align-items: center; gap: 6px; }
.ok-text { color: var(--ok); }
.bad-text { color: var(--danger); }
.review-photos img, .my-review .photos img { width: 84px; height: 64px; object-fit: cover; border-radius: 8px; }
.photos { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.check-row { display: flex; align-items: flex-start; gap: 10px; line-height: 1.4; cursor: pointer; }
.check-row .check { flex: none; margin-top: 1px; }
.visit-bar { margin-top: 0; }
.tab-count { position: absolute; top: -6px; left: 14px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; border: 2px solid var(--bg); box-sizing: content-box; }
.tab-count[hidden] { display: none; }

/* Виїзд до клієнта, перенесення, чат за записом, кошторис, промокоди й оплата частинами */
.ok-text, .bad-text { display: inline-flex; align-items: center; gap: 6px; }
.ok-text { color: var(--ok); }
.bad-text { color: var(--danger); }
.badge.mobile { background: var(--soft); color: var(--text); }
.mobile-card { flex-direction: row; align-items: flex-start; gap: 12px; margin-top: 14px; }
.mobile-card > .ic { flex: none; color: var(--accent); margin-top: 2px; }
.mobile-card b { display: block; margin-bottom: 2px; }
.mode-seg { margin-top: 2px; }
.mode-seg button { font-size: 14px; min-height: 40px; padding: 6px 14px; }
.map.pick-map { height: 260px; cursor: crosshair; }
.pick-dot { position: absolute; left: 0; top: 0; width: 22px; height: 22px; margin: -22px 0 0 -11px; border-radius: 50% 50% 50% 0; transform-origin: 0 0; background: var(--accent); border: 3px solid #fff; rotate: -45deg; box-shadow: 0 2px 6px rgba(0, 0, 0, .3); }
.promo-banner .banner-ic { background: var(--ok-soft); color: var(--ok); }
.promo-line { cursor: default; }
.promo-line .perk-ic { flex: none; }
.promo-form { align-items: flex-end; }
.parts { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; }
.parts legend { font-size: 14px; font-weight: 600; padding: 0 4px; }
.parts label { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; cursor: pointer; font-size: 14px; }
.parts label:has(input:checked) { border-color: var(--navy); background: var(--soft); font-weight: 600; }
.parts small { display: block; font-size: 12px; color: var(--muted); font-weight: 400; }
.parts .fine { grid-column: 1 / -1; margin: 0; }
.estimate { gap: 10px; }
.estimate summary { display: flex; align-items: center; gap: 8px; font-weight: 600; cursor: pointer; }
.est-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.est-item { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 15px; }
.est-item:first-child { border-top: 0; }
.est-item .name { flex: 1; min-width: 0; }
.est-item .name small { display: block; font-size: 12px; color: var(--muted); }
.est-item b { white-space: nowrap; }
.est-item.off .name, .est-item.off b { color: var(--muted); text-decoration: line-through; }
.chat-toggle { justify-content: flex-start; }
.chat-toggle .count { margin-left: auto; }
.bk-chat { display: flex; flex-direction: column; gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; }
.bk-chat .quick { display: flex; flex-wrap: wrap; gap: 6px; }
.bk-chat .quick .chip { font-size: 13px; padding: 6px 10px; min-height: 34px; }
.thread .msg.sys { justify-self: center; background: transparent; border: 1px dashed var(--line); font-size: 13px; color: var(--muted); }
.pill-s { font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 999px; background: var(--soft); white-space: nowrap; }
.pill-s.warn { background: var(--warn-soft); color: var(--warn); }
.pill-s.ok { background: var(--ok-soft); color: var(--ok); }
.pill-s.muted { color: var(--muted); }
.ticket.unread { border-color: var(--accent); }
.help-link { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }

/* ---------- рух і глибина ----------
   Анімації вмикаються лише для тих, хто не просив зменшити рух (prefers-reduced-motion). */
:root { --ease: cubic-bezier(.2, .8, .2, 1); --shadow-1: 0 1px 2px rgba(16, 21, 28, .05), 0 3px 10px rgba(16, 21, 28, .04); --shadow-2: 0 10px 28px rgba(16, 21, 28, .12); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --shadow-1: 0 1px 2px rgba(0, 0, 0, .4); --shadow-2: 0 10px 28px rgba(0, 0, 0, .5); }
}
:root[data-theme="dark"] { --shadow-1: 0 1px 2px rgba(0, 0, 0, .4); --shadow-2: 0 10px 28px rgba(0, 0, 0, .5); }
.card, .bk, .panel, .kpi { box-shadow: var(--shadow-1); }
.tabs { background: var(--bg); }
.promo-banner { background: linear-gradient(120deg, var(--ok-soft), var(--soft)); }
.btn, .chip, .slot, .day, .seg-mini button, .seg button, .radio-row label, .parts label { transition: transform .14s var(--ease), background-color .2s, border-color .2s, color .2s, box-shadow .2s; }

@media (prefers-reduced-motion: no-preference) {
  @keyframes cc-view { from { opacity: 0; transform: translateY(10px); } }
  @keyframes cc-rise { from { opacity: 0; transform: translateY(14px) scale(.985); } }
  @keyframes cc-fade { from { opacity: 0; } }
  @keyframes cc-sheet { from { transform: translateY(100%); } }
  @keyframes cc-drawer { from { transform: translateX(40px); opacity: 0; } }
  @keyframes cc-pop { 0% { transform: scale(.4); opacity: 0; } 60% { transform: scale(1.15); } 100% { transform: scale(1); } }
  @keyframes cc-bounce { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-4px); } }
  @keyframes cc-glow { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 45%, transparent); } 100% { box-shadow: 0 0 0 14px transparent; } }
  @keyframes cc-grow-x { from { transform: scaleX(0); } }
  @keyframes cc-grow-y { from { transform: scaleY(0); } }
  @keyframes cc-drop { from { transform: translateY(-14px); opacity: 0; } }
  @keyframes cc-shimmer { from { background-position: -200% 0; } to { background-position: 200% 0; } }

  .view-enter { animation: cc-view .3s var(--ease) both; }
  .view-enter > *, .view-enter .stack > *, .view-enter .kpis > *, .view-enter .grid-2 > * { animation: cc-rise .42s var(--ease) both; }
  .view-enter > :nth-child(2), .view-enter .stack > :nth-child(2), .view-enter .kpis > :nth-child(2), .view-enter .grid-2 > :nth-child(2) { animation-delay: 40ms; }
  .view-enter > :nth-child(3), .view-enter .stack > :nth-child(3), .view-enter .kpis > :nth-child(3) { animation-delay: 80ms; }
  .view-enter > :nth-child(4), .view-enter .stack > :nth-child(4), .view-enter .kpis > :nth-child(4) { animation-delay: 120ms; }
  .view-enter > :nth-child(5), .view-enter .stack > :nth-child(5) { animation-delay: 160ms; }
  .view-enter > :nth-child(6), .view-enter .stack > :nth-child(6) { animation-delay: 200ms; }
  .view-enter > :nth-child(n+7), .view-enter .stack > :nth-child(n+7) { animation-delay: 240ms; }

  .btn:active:not(:disabled), .chip:active, .slot:active:not(:disabled), .day:active:not(:disabled) { transform: scale(.96); }
  .slot[aria-pressed="true"], .day[aria-pressed="true"], .chip[aria-pressed="true"] { animation: cc-pop .3s var(--ease); }
  .sheet { animation: cc-sheet .34s var(--ease) both; }
  .sheet-dim, .drawer-dim { animation: cc-fade .22s both; }
  .drawer { animation: cc-drawer .3s var(--ease) both; }
  .tab-count:not([hidden]), .count, .tabs a[data-badge] .tab-ic::after { animation: cc-pop .4s var(--ease) both; }
  .tabs a[aria-current="page"] .tab-ic { animation: cc-bounce .45s var(--ease); }
  .bk.hl { animation: cc-glow 1.2s var(--ease) 2; }
  .hbars .fill, .mini-funnel .fill, .bars .bar span, .track .fill { transform-origin: left; animation: cc-grow-x .7s var(--ease) both; }
  svg .s1, svg .s2 { transform-box: fill-box; transform-origin: bottom; animation: cc-grow-y .6s var(--ease) both; }
  .pin-shape { animation: cc-drop .4s var(--ease) both; }
  .thread .msg { animation: cc-rise .3s var(--ease) both; }
  .notice.ok .ic, .ok-text .ic { animation: cc-pop .5s var(--ease) both; }
  .bk-chat, .estimate, .sub-form, #wait-form { animation: cc-rise .3s var(--ease) both; }

  @media (hover: hover) {
    a.card:hover, .link-card:hover, .hot-card:hover, article.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); }
    a.card, .link-card, .hot-card, article.card { transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s; }
    .btn.primary:hover { box-shadow: 0 6px 16px color-mix(in srgb, var(--accent) 35%, transparent); }
  }
}

/* Згорнуті другорядні блоки: графік, «не знайшли послугу», додати авто */
.fold { margin-top: 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--bg); box-shadow: var(--shadow-1); }
.fold > summary { display: flex; align-items: center; gap: 10px; padding: 14px 16px; min-height: 52px; font-weight: 700; font-size: 16px; cursor: pointer; list-style: none; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary::after { content: ""; margin-left: auto; width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .2s; }
.fold[open] > summary::after { transform: rotate(225deg); }
.fold > summary .ic { color: var(--accent); flex: none; }
.fold-note { font-weight: 500; font-size: 14px; color: var(--muted); margin-left: 4px; }
.fold > :not(summary) { margin-left: 16px; margin-right: 16px; }
.fold[open] > :last-child { margin-bottom: 16px; }
.fold .form-box { margin: 0 12px 12px; }
.promo-banner { margin-bottom: 12px; }

/* ---------- каталог: пошук із перемикачем вигляду й картки-обкладинки ---------- */
.search-row { display: flex; gap: 10px; align-items: center; margin-top: 14px; }
.search-row .search { flex: 1; }
.view-toggle { display: inline-flex; gap: 2px; padding: 3px; border-radius: 14px; background: var(--soft); flex: none; }
.view-toggle button { width: 42px; height: 42px; border: 0; border-radius: 11px; background: transparent; color: var(--muted); display: grid; place-items: center; cursor: pointer; }
.view-toggle button[aria-pressed="true"] { background: var(--bg); color: var(--accent); box-shadow: var(--shadow-1); }
.pcard { position: relative; border-radius: 22px; overflow: hidden; background: #1f2937; box-shadow: var(--shadow-2); isolation: isolate; }
.pc-cover { position: relative; aspect-ratio: 16 / 10; }
.pcard .pc-cover::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, rgba(0, 0, 0, .28) 0%, rgba(0, 0, 0, 0) 32%, rgba(0, 0, 0, .15) 50%, rgba(0, 0, 0, .78) 100%); }
.pc-slides { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.pc-slides::-webkit-scrollbar { display: none; }
.pc-slide { flex: 0 0 100%; scroll-snap-align: start; }
.pc-slide svg { display: block; width: 100%; height: 100%; }
.pc-dots { position: absolute; right: 16px; bottom: 16px; z-index: 2; display: flex; gap: 5px; pointer-events: none; }
.pc-dots i { width: 6px; height: 6px; border-radius: 3px; background: rgba(255, 255, 255, .55); transition: width .25s, background .25s; }
.pc-dots i.on { width: 16px; background: #fff; }
.pc-top { position: absolute; left: 12px; top: 12px; right: 56px; z-index: 2; display: flex; flex-wrap: wrap; gap: 6px; pointer-events: none; }
.pc-top .badge { background: rgba(255, 255, 255, .92); color: #10151c; backdrop-filter: blur(6px); }
.pc-top .badge.deal { background: var(--accent); color: var(--on-accent, #fff); }
.pcard > .fav { position: absolute; top: 8px; right: 8px; margin: 0; z-index: 3; color: #fff; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .5)); }
.pcard > .fav[aria-pressed="true"] { color: #ff8a7a; }
.pc-info { position: absolute; left: 16px; right: 70px; bottom: 14px; z-index: 2; display: flex; flex-direction: column; gap: 3px; color: #fff; pointer-events: none; text-shadow: 0 1px 3px rgba(0, 0, 0, .45); }
.pc-info .pc-title { margin: 0 0 2px; font-size: 21px; font-weight: 800; color: #fff; display: flex; align-items: center; gap: 8px; }
.pc-rate { display: inline-flex; align-items: center; gap: 3px; font-size: 14px; font-weight: 700; padding: 2px 7px; border-radius: 999px; background: rgba(0, 0, 0, .35); }
.pc-rate .ic { color: #ffc24b; }
.pc-line { display: flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 500; }
.pc-line .ic { flex: none; opacity: .95; }
.pc-line .badge.dist { background: rgba(0, 0, 0, .35); color: #fff; padding: 0 6px; font-size: 13px; }
#list.stack { gap: 14px; }
.pc-cover.hero { border-radius: 22px; overflow: hidden; margin: 6px 0 14px; box-shadow: var(--shadow-2); }
#map-card .pcard { margin-top: 10px; }

/* ---------- запис: основна послуга, додаткові, крок часу, чек ---------- */
.book-car { margin-top: 4px; }
.car-chip { display: inline-flex; align-items: center; gap: 8px; padding: 0 6px 0 14px; height: 44px; border-radius: 999px; background: var(--soft); color: var(--text); }
.car-chip select { border: 0; background: transparent; font: inherit; font-weight: 700; font-size: 16px; color: var(--text); padding-right: 6px; max-width: 70vw; }
.mode-seg { margin-top: 14px; }
.sec-h { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin: 22px 0 10px; }
.sec-h h2 { margin: 0; font-size: 22px; }
.sec-h span { font-size: 13px; color: var(--muted); }
.svc-cards { display: grid; gap: 10px; }
.svc-card { display: grid; gap: 8px; padding: 14px 16px; border-radius: 18px; border: 1.5px solid var(--line); background: var(--bg); box-shadow: var(--shadow-1); cursor: pointer; transition: border-color .2s, background-color .2s, transform .15s; }
.svc-card:focus-within { outline: 3px solid var(--accent); outline-offset: 2px; }
.svc-card.on { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 6%, var(--bg)); }
.svc-name { font-size: 17px; font-weight: 700; }
.svc-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.svc-tags span { font-size: 12px; padding: 3px 9px; border-radius: 999px; background: var(--soft); color: var(--muted); }
.svc-foot { display: flex; justify-content: space-between; align-items: baseline; font-size: 13px; color: var(--muted); }
.svc-foot b { font-size: 19px; color: var(--text); }
.svc-card.on .svc-foot b { color: var(--accent); }
.grp-h { margin: 16px 0 8px; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.svc-extra .price { color: var(--muted); font-weight: 600; }
.book-dock { border-radius: 22px 22px 0 0; border-top: 0; box-shadow: 0 -10px 30px rgb(16 24 40 / 10%); }
.book-dock .total { align-items: flex-start; }
.book-dock .total > span { display: flex; flex-direction: column; gap: 4px; }
.book-dock .total b { font-size: 24px; font-weight: 800; }
.dur-chip { align-self: flex-start; font-size: 12px; font-weight: 500; color: var(--muted); padding: 2px 9px; border-radius: 999px; background: var(--soft); }
.step-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 10px; }
.step-head h2 { margin: 0; font-size: 19px; flex: 1; text-align: center; padding-right: 44px; }
.step-head .icon-btn { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--soft); color: var(--text); display: grid; place-items: center; cursor: pointer; }
.step-note { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--accent); }
.day { height: 78px; position: relative; }
.load { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--line); margin-top: 3px; }
.load.high { background: #2fbf71; } .load.mid { background: #f59e0b; } .load.low { background: #e5484d; } .load.none { background: var(--line); }
.load-legend { display: flex; justify-content: center; gap: 14px; margin: 10px 0 0; font-size: 12px; color: var(--muted); }
.load-legend span { display: inline-flex; align-items: center; gap: 5px; }
.load-legend .load { margin: 0; }
.date-h { margin: 18px 0 2px; font-size: 19px; }
.date-h::first-letter { text-transform: uppercase; }
.slots { grid-template-columns: repeat(3, 1fr); }
.slot { height: 48px; border-radius: 14px; box-shadow: var(--shadow-1); }

.pay-screen.sheet { position: static; max-width: none; margin: 0; padding: 0; border-radius: 0; box-shadow: none; background: transparent; }
.receipt { position: relative; display: flex; flex-direction: column; gap: 8px; padding: 18px 16px 26px; background: #fffdf7; border-radius: 18px 18px 0 0; color: #10151c;
  -webkit-mask: linear-gradient(#000 0 0) top / 100% calc(100% - 10px) no-repeat, radial-gradient(circle 6px at 8px 100%, transparent 98%, #000) bottom / 16px 10px repeat-x;
          mask: linear-gradient(#000 0 0) top / 100% calc(100% - 10px) no-repeat, radial-gradient(circle 6px at 8px 100%, transparent 98%, #000) bottom / 16px 10px repeat-x; }
.receipt .muted, .receipt .fine, .receipt .sheet-total span { color: #5e6878; }
.rc-place { font-size: 19px; }
.rc-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13px; color: #5e6878; }
.rc-meta .ic { color: #2563eb; }
.rc-car { display: inline-flex; align-items: center; gap: 6px; margin-left: 12px; }
.rc-lines { list-style: none; margin: 8px 0 4px; padding: 0; display: grid; gap: 8px; font-size: 15px; }
.rc-lines li { display: flex; align-items: baseline; gap: 6px; }
.rc-lines li span:first-child { min-width: 0; overflow-wrap: anywhere; }
.rc-lines i { flex: 1; border-bottom: 2px dotted #cfd5de; transform: translateY(-4px); min-width: 16px; }
.rc-lines li span:last-child { white-space: nowrap; color: #3b4452; }
.methods { border: 0; margin: 0; padding: 4px; display: grid; gap: 4px; border-radius: 18px; background: var(--bg); box-shadow: var(--shadow-1); }
.methods legend { font-size: 14px; font-weight: 700; padding: 0 0 6px; }
.method { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 14px; border: 1.5px solid transparent; cursor: pointer; font-size: 15px; }
.method small { display: block; font-size: 12px; color: var(--muted); }
.method.on { border-color: #e9d96a; background: color-mix(in srgb, #fff7c2 55%, var(--bg)); }
.method:focus-within { outline: 3px solid var(--accent); outline-offset: 1px; }
.m-ic { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--soft); color: var(--text); font-weight: 800; flex: none; }
.m-ic.gpay { background: #fff; border: 1px solid var(--line); color: #4285f4; font-family: Arial, sans-serif; }
.m-ic.card { background: #e7f86b; color: #10151c; }
.pay-screen > * + * { margin-top: 14px; }
.pay-dock .btn.gpay { background: #10151c; border-color: #10151c; color: #fff; }
.g-mark { font-family: Arial, sans-serif; font-weight: 800; font-size: 20px; background: conic-gradient(from -45deg, #ea4335 0 25%, #fbbc05 0 50%, #34a853 0 75%, #4285f4 0); -webkit-background-clip: text; background-clip: text; color: transparent; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .receipt { background: #1b2230; color: #e8ecf2; }
  :root:not([data-theme="light"]) .receipt .rc-lines li span:last-child { color: #c9d1dc; }
}
:root[data-theme="dark"] .receipt { background: #1b2230; color: #e8ecf2; }
:root[data-theme="dark"] .receipt .rc-lines li span:last-child { color: #c9d1dc; }
/* Невидимий перемикач на всю картку: натиск будь-де по картці обирає її. */
.svc-card, .method { position: relative; }
.cover-input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; z-index: 1; appearance: none; }
#book[data-step] { margin-top: 4px; }
#view > h1 + #book .step-head { margin-top: -4px; }
.travel { display: inline-flex; align-items: center; gap: 6px; } .meta .badge.dist { background: none; padding: 0; font-size: inherit; color: inherit; }

/* Мої записи: дві вкладки замість довгого списку */
.book-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; margin: 4px 0 12px; border-radius: 16px; background: var(--soft); }
.book-tabs button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; border: 0; border-radius: 12px; background: transparent; font: inherit; font-size: 15px; font-weight: 600; color: var(--muted); cursor: pointer; }
.book-tabs button span { min-width: 22px; padding: 1px 7px; border-radius: 999px; background: var(--bg); font-size: 12px; color: var(--muted); }
.book-tabs button[aria-pressed="true"] { background: var(--bg); color: var(--text); box-shadow: var(--shadow-1); }
.book-tabs button[aria-pressed="true"] span { background: var(--accent); color: var(--on-accent); }

/* ---------- чат на весь екран і список переписок ---------- */
body.in-chat .top, body.in-chat .tabs { display: none; }
.chat-screen { position: fixed; inset: 0; z-index: 8; display: flex; flex-direction: column; background: var(--bg); max-width: 720px; margin: 0 auto; }
.chat-head { display: flex; align-items: center; gap: 10px; padding: calc(8px + env(safe-area-inset-top)) 10px 8px; border-bottom: 1px solid var(--line); background: var(--bg); }
.chat-head .icon-btn { width: 42px; height: 42px; border: 0; border-radius: 50%; background: transparent; color: var(--text); display: grid; place-items: center; cursor: pointer; flex: none; }
.chat-who { flex: 1; min-width: 0; }
.chat-who h1 { margin: 0; font-size: 16px; font-weight: 800; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-who small { display: block; font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.avatar { width: 40px; height: 40px; border-radius: 50%; flex: none; display: grid; place-items: center; font-weight: 800; font-size: 17px; color: #fff;
  background: linear-gradient(135deg, #f6a05a, var(--accent) 55%, #8f2414); box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px color-mix(in srgb, var(--accent) 35%, transparent); }
.avatar.support { background: linear-gradient(135deg, #3b82f6, var(--navy)); box-shadow: none; }
.chat-msgs { flex: 1; overflow-y: auto; list-style: none; margin: 0; padding: 14px 12px; display: flex; flex-direction: column; gap: 4px; overscroll-behavior: contain; }
.bubble { position: relative; max-width: 78%; padding: 9px 13px 18px; border-radius: 20px; font-size: 15px; line-height: 1.4; white-space: pre-wrap; overflow-wrap: anywhere; }
.bubble time { position: absolute; right: 12px; bottom: 4px; font-size: 10px; opacity: .7; }
.bubble.me { align-self: flex-end; background: linear-gradient(135deg, #e2553d, var(--accent)); color: #fff; border-bottom-right-radius: 6px; }
.bubble.them { align-self: flex-start; background: var(--soft); color: var(--text); border-bottom-left-radius: 6px; }
.bubble.me + .bubble.me, .bubble.them + .bubble.them { margin-top: -1px; }
.bubble.sys { align-self: center; max-width: 90%; padding: 6px 12px; border-radius: 999px; font-size: 12px; color: var(--muted); background: transparent; border: 1px dashed var(--line); text-align: center; }
.day-sep { align-self: center; margin: 10px 0 6px; font-size: 12px; font-weight: 600; color: var(--muted); }
.chat-empty { margin: auto; display: grid; justify-items: center; gap: 8px; text-align: center; color: var(--muted); max-width: 280px; }
.chat-empty .avatar { width: 72px; height: 72px; font-size: 30px; }
.chat-empty b { color: var(--text); font-size: 17px; }
.chat-compose { padding: 8px 10px calc(10px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--bg); display: grid; gap: 8px; }
.chat-compose .quick { display: flex; gap: 6px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 -10px; padding: 0 10px; }
.chat-compose .quick::-webkit-scrollbar { display: none; }
.chat-compose .quick .chip { flex: none; }
.chat-form { display: flex; align-items: center; gap: 8px; padding: 4px 4px 4px 16px; border-radius: 999px; background: var(--soft); }
.chat-form input { flex: 1; min-width: 0; height: 40px; border: 0; outline: 0; background: transparent; font: inherit; font-size: 16px; color: var(--text); }
.chat-form:focus-within { outline: 2px solid var(--accent); }
.send-btn { width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; cursor: pointer; flex: none; }
.chat-closed { margin: 0; padding: 12px; text-align: center; font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); }
.chat-link { justify-content: flex-start; gap: 8px; }
.chat-link .count { margin-left: auto; }
.convos { list-style: none; margin: 0; padding: 0; display: grid; }
.convo { display: flex; align-items: center; gap: 12px; padding: 10px 4px; color: var(--text); border-radius: 14px; }
.convo:hover { background: var(--soft); }
.convo .avatar { width: 52px; height: 52px; font-size: 20px; }
.convo-body { flex: 1; min-width: 0; display: grid; gap: 1px; }
.convo-top { display: flex; justify-content: space-between; gap: 8px; }
.convo-top b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.convo-top time { font-size: 12px; color: var(--muted); flex: none; }
.convo-text { font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.convo small { font-size: 12px; color: var(--muted); }
.convo.unread .convo-text { color: var(--text); font-weight: 600; }
.convo .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); flex: none; }

/* Позначки про хід запису в чаті: «Мийка завершила роботу», «Запис завершено», «Запис скасовано» */
.chat-mark { align-self: stretch; display: flex; align-items: center; gap: 8px; margin: 6px 0; font-size: 12px; color: var(--muted); }
.chat-mark::before, .chat-mark::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.chat-mark b { font-weight: 600; }
.chat-mark svg { flex: none; padding: 3px; border-radius: 50%; box-sizing: content-box; background: var(--soft); }
.chat-mark.end, .chat-mark.end svg { color: var(--ok); }
.chat-mark.end svg { background: var(--ok-soft); }
.chat-mark time { color: var(--muted); }
.thread .msg.sys.mark { border-style: solid; font-weight: 600; }

/* Чат «Не знайшли послугу?»: посилання на сторінці мийки, картка доданої послуги, контакти над полем */
.ask-link small { display: block; font-weight: 400; font-size: 13px; color: var(--muted); }
.svc-offer { align-self: flex-start; max-width: 86%; display: flex; gap: 10px; padding: 12px 14px; border-radius: 20px; border-bottom-left-radius: 6px; background: var(--ok-soft); color: var(--text); }
.svc-offer > svg { flex: none; color: var(--ok); }
.svc-offer div { display: grid; gap: 4px; }
.svc-offer span { font-size: 13px; color: var(--muted); }
.svc-offer .btn { justify-self: start; margin-top: 4px; }
.ask-form { display: grid; gap: 8px; }
.ask-contact { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ask-contact .field input { height: 40px; }

/* Завершені переписки й минулі сповіщення: приглушені й згорнуті окремо від актуальних */
.convo-state { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--muted); }
.convo-state.live { color: var(--ok); font-weight: 600; }
.convo.over .avatar { filter: grayscale(.85); opacity: .75; }
.convo.over .convo-top b { color: var(--muted); }
.convo-archive { margin-top: 8px; }

/* «Звільнився час» з листа очікування — єдине сповіщення в «Повідомленнях» */
.wait-offer { display: flex; align-items: center; gap: 12px; }
.wait-offer > svg { flex: none; color: var(--accent); }
.wait-offer > div { flex: 1; min-width: 0; display: grid; gap: 2px; }
.wait-offer.unread { border-color: var(--accent); }

/* Фото в чатах, галочки й «Прочитано», «у мережі» */
.avatar { position: relative; }
.avatar.on::after { content: ''; position: absolute; right: 0; bottom: 0; width: 28%; height: 28%; min-width: 10px; min-height: 10px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 2px var(--bg); }
.chat-presence.on { color: var(--ok); font-weight: 600; }
.chat-pin { display: flex; align-items: center; gap: 8px; padding: 8px 14px; font-size: 13px; color: var(--muted); background: var(--soft); border-bottom: 1px solid var(--line); }
.chat-pin span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
a.chat-pin { color: var(--muted); text-decoration: none; }
.bubble.has-photo { padding: 4px 4px 22px; max-width: min(78%, 252px); }
.bubble.has-photo .b-text { display: block; padding: 6px 9px 0; }
.chat-photo { display: block; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 16px; overflow: hidden; }
.chat-photo img { display: block; width: 100%; max-width: 240px; max-height: 320px; object-fit: cover; }
.bubble .ticks { margin-left: 4px; letter-spacing: -3px; }
.read-state { align-self: flex-end; margin: -2px 6px 4px; font-size: 11px; color: var(--muted); list-style: none; }
.read-state.read { color: var(--text); }
.thread .read-state { display: block; margin: 4px 0 0; text-align: right; }
.attach-btn { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; color: var(--muted); cursor: pointer; }
.attach-btn:focus-within { outline: 2px solid var(--accent); }
.chat-form { padding-left: 4px; }
.btn.attach-btn { width: auto; height: auto; border-radius: 12px; color: inherit; }
.msg-photo { display: block; margin: 4px 0; }
.msg-photo img { display: block; max-width: 220px; max-height: 260px; border-radius: 10px; object-fit: cover; }
.photo-view { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; background: rgb(0 0 0 / 92%); padding: 16px; }
.photo-view img { max-width: 100%; max-height: 100%; border-radius: 8px; }
.photo-view .icon-btn { position: absolute; top: calc(10px + env(safe-area-inset-top)); right: 10px; color: #fff; }

.rel-note { display: flex; gap: 10px; align-items: flex-start; }
.rel-note > svg { flex: none; margin-top: 2px; }

/* Вхід у гаманець з профілю */
.wallet-link { margin-top: 12px; }
.wallet-link small { display: block; font-size: 14px; font-weight: 400; color: var(--muted); }

/* Вибір авто з гаража на головній: ціни показуються для нього */
.car-pick { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 0 0 10px; border-radius: 10px; background: var(--accent-soft); color: var(--accent-hover); font-size: 13px; font-weight: 600; max-width: 60vw; }
.car-pick select { height: 32px; min-width: 0; max-width: 100%; padding: 0 28px 0 0; border: 0; background-color: transparent; background-position: right 8px center; background-size: 14px; font: inherit; color: inherit; text-overflow: ellipsis; }
.car-pick.add { padding: 0 12px 0 10px; text-decoration: none; }

/* Завершені записи: місяці з підсумком, кольорова смуга й плашка статусу, більше повітря */
.bk-status { display: inline-flex; align-items: center; gap: 5px; }
.done-month { margin-top: 18px; }
.month-h { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 0 4px 10px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.month-h h3 { margin: 0; font-size: 18px; font-weight: 800; }
.month-h span { font-size: 13px; color: var(--muted); }
.done-list { gap: 16px; }
.done-list .bk { position: relative; overflow: hidden; padding-left: 20px; box-shadow: 0 1px 2px rgb(16 24 40 / 5%); }
.done-list .bk::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--line); }
.done-list .bk-status { padding: 3px 10px 3px 8px; border-radius: 999px; background: var(--soft); color: var(--muted); }
.done-list .st-completed::before { background: var(--ok); }
.done-list .st-completed .bk-status { background: var(--ok-soft); color: var(--ok); }
.done-list .st-noshow::before, .done-list .st-dispute::before { background: var(--warn); }
.done-list .st-noshow .bk-status, .done-list .st-dispute .bk-status { background: var(--warn-soft); color: var(--warn); }
.done-list .st-cancelled, .done-list .st-refunded { background: color-mix(in srgb, var(--soft) 55%, var(--bg)); }
.done-list .st-cancelled::before, .done-list .st-refunded::before { background: var(--faint); }
.done-list .st-cancelled .bk-title, .done-list .st-refunded .bk-title { color: var(--muted); }

/* Завершені — компактні рядки, що розгортаються */
.done-list { display: grid; gap: 10px; }
.done-item { border: 1px solid var(--line); border-radius: 16px; background: var(--bg); overflow: hidden; box-shadow: 0 1px 2px rgb(16 24 40 / 5%); }
.done-item > summary { list-style: none; display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 12px; padding: 12px 14px; cursor: pointer; border-left: 5px solid var(--faint); }
.done-item > summary::-webkit-details-marker { display: none; }
.done-item[open] > summary { border-bottom: 1px solid var(--line); }
.di-ic { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--soft); color: var(--muted); }
.di-main { display: grid; min-width: 0; }
.di-main b { font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.di-main small, .di-side small { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.di-side { display: grid; justify-items: end; }
.di-chev { color: var(--faint); transition: transform .2s; }
.done-item[open] .di-chev { transform: rotate(90deg); }
.done-item.st-completed > summary { border-left-color: var(--ok); }
.done-item.st-completed .di-ic { background: var(--ok-soft); color: var(--ok); }
.done-item.st-noshow > summary, .done-item.st-dispute > summary { border-left-color: var(--warn); }
.done-item.st-noshow .di-ic, .done-item.st-dispute .di-ic { background: var(--warn-soft); color: var(--warn); }
.done-item.st-cancelled > summary b, .done-item.st-refunded > summary b { color: var(--muted); }
.done-item > .bk { border: 0; border-radius: 0; box-shadow: none; padding-left: 16px; }
.done-item > .bk::before { display: none; }
.done-more { margin-top: 14px; }
.steps.two { grid-template-columns: repeat(2, 1fr); }

/* Вибір авто з гаража під час запису — великі кнопки, видно всі одразу */
.car-choice { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 2px 16px 4px; }
.car-choice::-webkit-scrollbar { display: none; }
.car-opt { flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 52px; padding: 8px 14px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--bg); color: var(--text); font-weight: 600; cursor: pointer; text-decoration: none; }
.car-opt span { display: grid; line-height: 1.2; }
.car-opt small { font-size: 12px; font-weight: 500; color: var(--muted); }
.car-opt:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-hover); }
.car-opt:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.car-opt.add { border-style: dashed; color: var(--muted); }

/* ---------- вхід за номером телефону ---------- */
body.in-auth .top, body.in-auth .tabs { display: none; }
body.in-auth #view { padding: 0; max-width: none; }
.auth { min-height: 100dvh; display: flex; flex-direction: column; background: linear-gradient(170deg, #e2553d 0%, var(--accent) 38%, #8f2414 100%); }
.auth-hero { position: relative; flex: 1; min-height: 280px; display: grid; place-items: center; overflow: hidden; }
.auth-logo { position: relative; z-index: 2; border-radius: 24px; box-shadow: 0 18px 40px rgb(0 0 0 / 28%); }
.auth-car { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); opacity: .9; }
.auth-bubble { position: absolute; border-radius: 50%; background: radial-gradient(circle at 35% 30%, rgb(255 255 255 / 95%), rgb(255 255 255 / 25%) 45%, rgb(255 255 255 / 10%) 70%, rgb(255 255 255 / 45%)); }
.auth-bubble.b1 { width: 70px; height: 70px; left: 10%; top: 18%; }
.auth-bubble.b2 { width: 34px; height: 34px; left: 72%; top: 14%; }
.auth-bubble.b3 { width: 52px; height: 52px; left: 80%; top: 52%; }
.auth-bubble.b4 { width: 24px; height: 24px; left: 22%; top: 62%; }
.auth-bubble.b5 { width: 42px; height: 42px; left: 52%; top: 70%; }
.auth-shine { position: absolute; inset: 0; background: linear-gradient(115deg, transparent 35%, rgb(255 255 255 / 22%) 50%, transparent 65%); }
.auth-card { position: relative; z-index: 3; display: grid; gap: 14px; padding: 28px 20px calc(24px + env(safe-area-inset-bottom)); border-radius: 28px 28px 0 0; background: var(--bg); box-shadow: 0 -10px 40px rgb(0 0 0 / 18%); max-width: 520px; width: 100%; margin: 0 auto; }
.auth-card h1 { margin: 0; font-size: 28px; }
.auth-card p { margin: 0; color: var(--muted); }
.auth-phone { display: flex; align-items: center; gap: 10px; height: 60px; padding: 0 16px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--soft); font-size: 20px; font-weight: 600; }
.auth-phone:focus-within { border-color: var(--accent); background: var(--bg); }
.auth-phone .prefix { color: var(--muted); }
.auth-phone input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; font: inherit; color: var(--text); letter-spacing: .02em; }
.code-cells { display: flex; gap: 10px; justify-content: center; }
.code-cell { width: 60px; height: 68px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--soft); text-align: center; font: inherit; font-size: 28px; font-weight: 800; color: var(--text); }
.code-cell:focus { outline: 0; border-color: var(--accent); background: var(--bg); box-shadow: 0 0 0 4px var(--accent-soft); }
.auth-error { color: var(--danger) !important; font-weight: 600; }
.auth-card.done { justify-items: center; text-align: center; padding-top: 36px; }
.auth-check { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; background: var(--ok); color: #fff; }
.auth-card .fine { font-size: 13px; }
.auth-card .code { color: var(--text); letter-spacing: .12em; }

@media (prefers-reduced-motion: no-preference) {
  .auth-logo { animation: auth-pop .7s cubic-bezier(.2, 1.4, .4, 1) both, auth-float 4s 1s ease-in-out infinite; }
  .auth-car { animation: auth-drive 1.1s .2s cubic-bezier(.2, .8, .2, 1) both; }
  .auth-bubble { animation: auth-rise 6s ease-in-out infinite; }
  .auth-bubble.b2 { animation-delay: -1.5s; animation-duration: 5s; }
  .auth-bubble.b3 { animation-delay: -3s; animation-duration: 7s; }
  .auth-bubble.b4 { animation-delay: -.8s; animation-duration: 4.5s; }
  .auth-bubble.b5 { animation-delay: -2.2s; }
  .auth-shine { animation: auth-shine 3.6s 1s ease-in-out infinite; }
  .auth-card { animation: auth-card .55s .1s cubic-bezier(.2, .8, .2, 1) both; }
  .auth-card.done .auth-check { animation: auth-pop .6s cubic-bezier(.2, 1.4, .4, 1) both; }
  .auth-error { animation: auth-shake .4s both; }
}
@keyframes auth-pop { from { transform: scale(.4) rotate(-12deg); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes auth-float { 50% { transform: translateY(-8px); } }
@keyframes auth-drive { from { transform: translateX(-160%); opacity: 0; } to { transform: translateX(-50%); opacity: .9; } }
@keyframes auth-rise { 0%, 100% { transform: translateY(0) scale(1); } 50% { transform: translateY(-22px) scale(1.08); } }
@keyframes auth-shine { 0% { transform: translateX(-100%); } 60%, 100% { transform: translateX(100%); } }
@keyframes auth-card { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes auth-shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

/* «Для бізнесу»: умови, кроки, статус заявки */
.biz-terms { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.biz-terms li { display: flex; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 16px; }
.biz-terms li > svg { flex: none; color: var(--accent); margin-top: 2px; }
.biz-terms span { display: grid; gap: 4px; color: var(--muted); font-size: 14px; }
.biz-terms b { color: var(--text); font-size: 16px; }
.biz-need { margin: 0; padding-left: 20px; display: grid; gap: 6px; }
.biz-steps { margin: 0; padding: 0; list-style: none; counter-reset: st; display: grid; gap: 10px; }
.biz-steps li { counter-increment: st; display: flex; gap: 12px; align-items: center; }
.biz-steps li::before { content: counter(st); flex: none; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #fff; font-weight: 800; font-size: 14px; }
.biz-dock { display: grid; gap: 8px; }
.app-status { margin-top: 12px; }
.app-status.ok { border-color: var(--ok); }

/* Вибір міста в шапці */
.city-pick { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); }
.city-pick select { border: 0; background-color: transparent; padding: 4px 22px 4px 0; font: inherit; font-size: 16px; color: var(--text); font-weight: 600; background-position: right 2px center; background-size: 14px; max-width: 46vw; }
.city-empty { display: grid; justify-items: center; gap: 10px; text-align: center; padding: 32px 16px; color: var(--muted); }
.city-empty b { color: var(--text); font-size: 17px; }
.city-empty svg { color: var(--accent); }
.logout-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.auth-name input { width: 100%; height: 60px; padding: 0 16px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--soft); font: inherit; font-size: 19px; font-weight: 600; color: var(--text); }
.auth-name input:focus { outline: 0; border-color: var(--accent); background: var(--bg); }

/* Номер запису й фото у зверненнях */
.bk-no { display: inline-block; margin-top: 2px; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.ticket-photos { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.ticket-photos img { width: 96px; height: 96px; object-fit: cover; border-radius: 10px; display: block; }
.ticket-photos .chat-photo img { max-width: none; }
.dropzone.small-drop { padding: 12px; font-size: 14px; flex-direction: row; gap: 8px; }
.support-search { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 12px; }
.support-search .field { flex: 1 1 200px; }

/* Мийка підтвердила вільний час у CarCar Business */
.sched-ok { display: flex; align-items: center; gap: 6px; margin: 10px 0 0; font-size: 13px; font-weight: 600; color: var(--ok); }
.offer-box { display: grid; gap: 4px; }
.offer-when { display: inline; font-size: 16px; margin: 0; }
.offer-note { font-style: italic; }
.offer-due { font-size: 13px; color: var(--muted); }

/* Фото й аватар, які мийка завантажила в CarCar Business */
.pc-slide img { display: block; width: 100%; height: 100%; object-fit: cover; }
.place-h { display: flex; align-items: center; gap: 12px; }
.place-ava { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px var(--line); }
.place-about { margin: -4px 0 12px; font-size: 15px; line-height: 1.5; color: var(--text); white-space: pre-line; }

/* Час зі знижкою: стара ціна закреслена, відсоток у куточку */
.slot.hot { position: relative; height: 58px; display: grid; place-content: center; gap: 1px; font-weight: 700; }
.slot.hot small s { opacity: .7; font-weight: 400; }
.slot-pct { position: absolute; top: -8px; right: -6px; padding: 1px 6px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 10px; font-weight: 800; box-shadow: 0 0 0 2px var(--bg); }
.avatar.has-img { padding: 0; background: var(--surface-2, #eef2f6); }
.avatar.has-img img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }

/* Чат на телефоні: сторінка під ним не прокручується, коли відкривається клавіатура. */
html:has(body.in-chat), body.in-chat { overflow: hidden; overscroll-behavior: none; }
.chat-screen { will-change: transform; }
.biz-login { margin-top: 20px; }
body.guest .tabs { display: none; }
body.guest { --tabs-h: 0px; }

/* Очікування підтвердження мийкою */
.wait-box { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border-radius: 16px; background: var(--warn-soft, #fff4e5); }
.wait-box b { display: block; }
.wait-box small { display: block; margin-top: 2px; color: var(--muted); font-size: 13px; }
.wait-box .countdown { font-variant-numeric: tabular-nums; font-weight: 700; color: var(--text); }
.wait-dots { display: flex; gap: 4px; padding-top: 7px; flex: none; }
.wait-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: wait-dot 1.2s infinite ease-in-out; }
.wait-dots i:nth-child(2) { animation-delay: .15s; }
.wait-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes wait-dot { 0%, 80%, 100% { opacity: .25; transform: scale(.8); } 40% { opacity: 1; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .wait-dots i { animation: none; opacity: .7; } }
/* Мийка відповіла на запис */
.answer-banner { position: fixed; z-index: 60; left: 12px; right: 12px; top: calc(10px + env(safe-area-inset-top)); max-width: 560px; margin: 0 auto;
  display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 18px; background: var(--bg); color: var(--text); text-decoration: none;
  box-shadow: 0 10px 30px rgb(16 24 40 / 22%); border-left: 5px solid var(--ok); animation: banner-in .35s var(--ease, ease) both; }
.answer-banner.warn { border-left-color: var(--warn, #c77700); }
.answer-banner.bad { border-left-color: var(--bad, #c8402b); }
.answer-banner > svg { flex: none; color: var(--ok); margin-top: 1px; }
.answer-banner.warn > svg { color: var(--warn, #c77700); }
.answer-banner.bad > svg { color: var(--bad, #c8402b); }
.answer-banner span { display: grid; gap: 2px; font-size: 14px; color: var(--muted); }
.answer-banner b { color: var(--text); font-size: 16px; }
@keyframes banner-in { from { transform: translateY(-120%); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .answer-banner { animation: none; } }

/* Дзвінок через CARCAR (у застосунку клієнта й у CarCar Business) */
.call-screen { position: fixed; inset: 0; z-index: 90; display: flex; flex-direction: column; justify-content: space-between; align-items: center;
  padding: calc(48px + env(safe-area-inset-top)) 24px calc(40px + env(safe-area-inset-bottom)); color: #fff; text-align: center;
  background: radial-gradient(120% 80% at 50% 20%, #2b3a55, #10151c 70%); }
.call-who { display: grid; justify-items: center; gap: 10px; }
.call-ava { width: 112px; height: 112px; border-radius: 50%; display: grid; place-items: center; font-size: 46px; font-weight: 800;
  background: linear-gradient(135deg, #f6a05a, #c8402b 55%, #8f2414); box-shadow: 0 0 0 10px rgb(255 255 255 / 6%), 0 0 0 22px rgb(255 255 255 / 3%); }
.call-who h2 { margin: 8px 0 0; font-size: 26px; }
.call-status { margin: 0; font-size: 17px; opacity: .85; font-variant-numeric: tabular-nums; }
.call-note { display: inline-flex; align-items: center; gap: 6px; margin: 6px 0 0; font-size: 13px; opacity: .65; }
.call-actions { display: flex; gap: 40px; align-items: center; justify-content: center; flex-wrap: wrap; }
.call-actions .btn { min-width: 140px; }
.call-btn { width: 68px; height: 68px; border-radius: 50%; border: 0; display: grid; place-items: center; cursor: pointer; color: #fff; background: rgb(255 255 255 / 14%); }
.call-btn[aria-pressed="true"] { background: #fff; color: #10151c; }
.call-btn.ok { background: #22a95b; }
.call-btn.end { background: #e0402b; }
.call-btn.end svg { transform: rotate(135deg); }
.call-btn:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
@media (prefers-reduced-motion: no-preference) {
  .call-screen:has(.call-btn.ok) .call-ava { animation: call-ring 1.4s ease-in-out infinite; }
}
@keyframes call-ring { 50% { box-shadow: 0 0 0 16px rgb(255 255 255 / 10%), 0 0 0 34px rgb(255 255 255 / 4%); } }
.call-warn { margin: 0; min-height: 1em; font-size: 13px; color: #ffd28a; }

/* Дзвінки в списку повідомлень */
button.convo.call-row { width: 100%; border: 0; background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.call-text { display: flex; align-items: center; gap: 6px; }
.call-text svg { flex: none; color: var(--muted); }
.call-row.missed .call-text, .call-row.missed .call-text svg { color: var(--bad, #c8402b); font-weight: 600; }

/* Перемикач-сегменти (тема, оплата) і налаштування */
.lbl { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.seg-row { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; border-radius: 14px; background: var(--soft); }
.seg-row label { position: relative; }
.seg-row input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg-row span { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px; padding: 0 8px; border-radius: 10px; font-size: 14px; font-weight: 600; color: var(--muted); text-align: center; }
.seg-row input:checked + span { background: var(--bg); color: var(--text); box-shadow: 0 1px 3px rgb(16 24 40 / 12%); }
.seg-row input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.settings .check-row small { display: block; font-weight: 400; margin-top: 2px; }
