/* Layout: one phone column; screens scroll above a fixed tab bar, sheets slide over it. */
:root {
  --bg: #F1F2F4; --surface: #FFFFFF; --ink: #18203A; --muted: #5B6378; --line: rgba(24, 32, 58, .10);
  --accent: #3341A6; --accent-ink: #FFFFFF; --accent-soft: #E4E7F7; --accent-text: #26318A;
  --warn: #E9A21B; --warn-soft: #FCEFD2; --warn-text: #7A4B00;
  --ok: #2E7D5B; --ok-soft: #DDF0E6; --ok-text: #1F5C42;
  --danger: #B4432F; --danger-soft: #F8E1DC; --danger-text: #8E3322;
  --off: #E8EAEE; --off-text: #4A5163; --disabled: #D5D9E2; --disabled-text: #626A7E;
  --night: #18203A; --night-text: #FFFFFF; --night-sub: #C9CEE6; --scrim: rgba(24, 32, 58, .45);
  --font-ui: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-num: "Unbounded", "Onest", system-ui, sans-serif;
  --wheel-row: 40px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0F1424; --surface: #1A2036; --ink: #E8EBF5; --muted: #A2A9BE; --line: rgba(232, 235, 245, .12);
    --accent: #8C97F2; --accent-ink: #0F1424; --accent-soft: #262E5C; --accent-text: #C9CEFB;
    --warn: #F0B640; --warn-soft: #3D2E0A; --warn-text: #F3C76A;
    --ok: #5CC495; --ok-soft: #15372A; --ok-text: #9BE0BE;
    --danger: #E9846F; --danger-soft: #3E1C17; --danger-text: #F5B0A1;
    --off: #252B40; --off-text: #B4BACB; --disabled: #2B3148; --disabled-text: #9298AD;
    --night: #070A14; --night-text: #FFFFFF; --night-sub: #A9B0D0; --scrim: rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0F1424; --surface: #1A2036; --ink: #E8EBF5; --muted: #A2A9BE; --line: rgba(232, 235, 245, .12);
  --accent: #8C97F2; --accent-ink: #0F1424; --accent-soft: #262E5C; --accent-text: #C9CEFB;
  --warn: #F0B640; --warn-soft: #3D2E0A; --warn-text: #F3C76A;
  --ok: #5CC495; --ok-soft: #15372A; --ok-text: #9BE0BE;
  --danger: #E9846F; --danger-soft: #3E1C17; --danger-text: #F5B0A1;
  --off: #252B40; --off-text: #B4BACB; --disabled: #2B3148; --disabled-text: #9298AD;
  --night: #070A14; --night-text: #FFFFFF; --night-sub: #A9B0D0; --scrim: rgba(0, 0, 0, .6);
  color-scheme: dark;
}
/* The page itself never scrolls: only the screens inside do. Otherwise a drag moves the whole page (or Telegram's sheet) instead of the list. */
html, body { height: 100%; overflow: hidden; overscroll-behavior: none; }
/* The browser's own 8px body margin made the page 8px taller than the window, so it scrolled by itself. The same 8px rim is kept as padding inside the height. */
body { margin: 0; padding: 8px; }
body { background: var(--bg); color: var(--ink); font: 15px/1.4 var(--font-ui); font-variant-numeric: tabular-nums; -webkit-tap-highlight-color: transparent; }
* { box-sizing: border-box; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; touch-action: manipulation; }
button:disabled { cursor: default; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 2px; }
h1, h2, h3 { margin: 0; text-wrap: balance; }
p { margin: 0; }

#app { position: relative; max-width: 440px; height: 100%; margin: 0 auto; overflow: hidden; background: var(--bg); }
.screen { position: absolute; inset: 0 0 calc(76px + env(safe-area-inset-bottom, 0px)); overflow-y: auto; overscroll-behavior: contain; padding: 18px 16px 32px; display: flex; flex-direction: column; gap: 22px; }
.demo { font-size: 12px; color: var(--muted); }
.big-title { font: 600 26px/1.15 var(--font-num); }
.h2 { font-size: 18px; font-weight: 700; }
.h3 { font-size: 15px; font-weight: 700; }
.sub { font-size: 13px; color: var(--muted); }
.section { display: flex; flex-direction: column; gap: 8px; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

.clocks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.clock { border-radius: 20px; padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; background: var(--surface); border: 0; text-align: left; }
.clock--night { background: var(--night); color: var(--night-text); }
.clock--night .clock__label { color: var(--night-sub); }
.clock__label { font-size: 13px; color: var(--muted); }
.clock__time { font: 600 34px/1.1 var(--font-num); }

.row-btn { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 10px 14px; border: 0; border-radius: 14px; background: var(--surface); text-align: left; }
.row-btn__main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.row-btn__title { font-weight: 600; }
.mark { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.chev { width: 18px; height: 18px; flex: none; color: var(--muted); }
.ico { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.undated { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: var(--accent-soft); }
.undated__open { flex: 1; min-width: 0; border: 0; background: transparent; padding: 0; text-align: left; display: flex; flex-direction: column; }
.undated .sub { color: var(--accent-text); }

.strip { display: flex; gap: 6px; overflow-x: auto; margin: 0 -16px; padding: 0 16px 2px; scrollbar-width: none; scroll-snap-type: x proximity; }
.strip::-webkit-scrollbar { display: none; }
.strip > * { scroll-snap-align: start; }
.day-chip { flex: none; width: 48px; height: 64px; border-radius: 14px; border: 0; padding: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; background: var(--surface); }
.day-chip b { font-size: 18px; }
.day-chip small { font-size: 12px; }
.day-chip__bar { width: 14px; height: 3px; border-radius: 2px; }
.is-sel { background: var(--accent) !important; color: var(--accent-ink) !important; border-color: transparent !important; }
.is-off { background: var(--off) !important; color: var(--off-text) !important; border: 1px dashed var(--line) !important; }
.is-past { color: var(--muted); background: transparent; }

.agenda { display: flex; flex-direction: column; }
.slot-row { display: grid; grid-template-columns: 62px 14px minmax(0, 1fr); gap: 10px; width: 100%; border: 0; background: transparent; padding: 0; text-align: left; }
.slot-row__time { padding-top: 12px; display: flex; flex-direction: column; }
.slot-row__time b { font: 600 17px var(--font-num); }
.slot-row__rail { display: flex; flex-direction: column; align-items: center; }
.slot-row__rail i { width: 2px; background: var(--line); }
.slot-row__rail i:first-child { height: 16px; }
.slot-row__rail i:last-child { flex: 1; }
.slot-row__body { margin: 6px 0; padding: 12px 14px; border-radius: 16px; background: var(--surface); display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.slot-row__top { display: flex; justify-content: space-between; gap: 8px; }
.slot-row__name { font-weight: 600; font-size: 16px; overflow-wrap: anywhere; }
.slot-row--dead { opacity: .6; }
.slot-row--dead .slot-row__name { text-decoration: line-through; }
.status { font-size: 13px; font-weight: 600; }
.t-warn { color: var(--warn-text); } .t-ok { color: var(--ok); } .t-acc { color: var(--accent); } .t-muted { color: var(--muted); } .t-danger { color: var(--danger); }
.m-warn { background: var(--warn); } .m-ok { background: var(--ok); } .m-acc { background: var(--accent); } .m-muted { background: var(--disabled); } .m-danger { background: var(--danger); }
.chip { font-size: 12px; font-weight: 700; padding: 5px 10px; border-radius: 8px; white-space: nowrap; }
.c-warn { background: var(--warn-soft); color: var(--warn-text); } .c-ok { background: var(--ok-soft); color: var(--ok-text); }
.c-acc { background: var(--accent-soft); color: var(--accent-text); } .c-muted { background: var(--off); color: var(--off-text); } .c-danger { background: var(--danger-soft); color: var(--danger-text); }

.dashed-btn { min-height: 56px; border: 1.5px dashed color-mix(in srgb, var(--accent) 45%, transparent); border-radius: 16px; background: transparent; color: var(--accent); font-weight: 600; }
.note { padding: 12px 14px; border-radius: 14px; font-size: 14px; }
.note--off { background: var(--off); color: var(--off-text); }
.note--warn { background: var(--warn-soft); color: var(--warn-text); }
.dup { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.dup > span { flex: 1; min-width: 0; }
.note--acc { background: var(--accent-soft); color: var(--accent-text); }
.note--ok { background: var(--ok-soft); color: var(--ok-text); }
.note--danger { background: var(--danger-soft); color: var(--danger-text); }

.cal { background: var(--surface); border-radius: 20px; padding: 12px; }
.cal__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.cal__title { font-weight: 700; font-size: 17px; }
.cal__nav { display: flex; gap: 6px; }
.icon-btn { width: 44px; height: 44px; border: 0; border-radius: 12px; background: var(--bg); display: flex; align-items: center; justify-content: center; flex: none; }
.icon-btn:disabled { opacity: .4; }
.cal__wd, .cal__grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cal__wd { font-size: 12px; color: var(--muted); text-align: center; margin-bottom: 4px; }
.cal__cell { height: 46px; border: 0; border-radius: 12px; padding: 0; background: transparent; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; }
.cal__cell b { font-size: 15px; font-weight: 600; }
.cal__cell i { height: 4px; border-radius: 2px; }
.cal__cell--today { background: var(--accent-soft); }
.cal__cell--past { color: var(--muted); }
.cal__cell--trip { box-shadow: inset 0 -3px 0 var(--warn); }
.cal__cell:disabled { opacity: .4; }
.cal__legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--muted); padding: 10px 4px 2px; }
.cal__legend span { display: flex; align-items: center; gap: 6px; }
.lg { display: inline-block; width: 14px; height: 4px; border-radius: 2px; }
.bar-acc { background: var(--accent); } .bar-off { background: repeating-linear-gradient(90deg, var(--muted) 0 3px, transparent 3px 5px); } .bar-trip { background: var(--warn); }
.small-btn { min-height: 40px; padding: 0 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); font-weight: 600; font-size: 13px; flex: none; }
.list-row { display: flex; gap: 12px; align-items: center; width: 100%; padding: 12px 14px; border: 0; border-radius: 14px; background: var(--surface); text-align: left; }
.list-row--dead { opacity: .6; }
.list-row--dead .list-row__name { text-decoration: line-through; }

.search { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 14px; border-radius: 14px; background: var(--surface); }
.search input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; font-size: 15px; }
.av { width: 42px; height: 42px; border-radius: 12px; flex: none; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; color: #18203A; }
.channel { font-size: 11px; font-weight: 700; padding: 2px 6px; border-radius: 6px; background: var(--off); color: var(--off-text); margin-left: 6px; vertical-align: 1px; }

.tabbar { position: absolute; left: 0; right: 0; bottom: 0; height: calc(76px + env(safe-area-inset-bottom, 0px)); padding: 8px 4px env(safe-area-inset-bottom, 0px); background: var(--surface); border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: start; }
.tab { height: 58px; border: 0; background: transparent; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 11px; font-weight: 600; color: var(--muted); padding: 0 2px; }
.tab[aria-current="page"] { color: var(--accent); }
.tab--cta { margin: 0 2px; border-radius: 16px; background: var(--accent); color: var(--accent-ink); font-weight: 700; }

.layer { position: absolute; inset: 0; }
.scrim { position: absolute; inset: 0; border: 0; padding: 0; background: var(--scrim); }
.sheet { position: absolute; left: 0; right: 0; bottom: 0; max-height: 93%; overflow-y: auto; overscroll-behavior: contain; background: var(--bg); border-radius: 24px 24px 0 0; padding: 10px 16px calc(24px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 12px; }
.dialog { position: absolute; left: 10px; right: 10px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); max-height: 88%; overflow-y: auto; overscroll-behavior: contain; background: var(--surface); border-radius: 22px; padding: 20px; display: flex; flex-direction: column; gap: 12px; }
@media (prefers-reduced-motion: no-preference) { .sheet, .dialog { animation: up .2s ease-out; } }
@keyframes up { from { transform: translateY(20px); opacity: .6; } to { transform: none; opacity: 1; } }
.grab { align-self: center; width: 40px; height: 4px; border-radius: 2px; background: var(--disabled); }
.panel { background: var(--surface); border-radius: 18px; padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.panel--list { padding: 4px 16px; gap: 0; }
.fact { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.fact:last-child { border-bottom: 0; }
.fact > span:first-child { color: var(--muted); }
.times { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.times b { font: 600 19px var(--font-num); }
.stages { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
.stage { display: flex; flex-direction: column; gap: 5px; font-size: 11px; font-weight: 600; color: var(--muted); }
.stage i { height: 5px; border-radius: 3px; background: var(--disabled); }
.stage--on { color: var(--ink); } .stage--on i { background: var(--accent); }
.btn { min-height: 52px; border: 0; border-radius: 16px; font-weight: 700; font-size: 16px; padding: 0 16px; }
.btn--primary { background: var(--accent); color: var(--accent-ink); }
.btn--outline { background: transparent; border: 1.5px solid var(--accent); color: var(--accent); }
.btn--plain { background: var(--surface); color: var(--ink); font-weight: 600; font-size: 15px; }
.btn--danger { background: var(--danger); color: #fff; }
.btn:disabled { background: var(--disabled); color: var(--disabled-text); border-color: transparent; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.act { min-height: 48px; border: 0; border-radius: 12px; background: var(--surface); font-weight: 600; font-size: 14px; padding: 0 8px; }
.act--danger { color: var(--danger); }
.list-row--done { background: var(--done-bg, var(--accent-soft)) !important; }
.zoom-row { display: flex; gap: 8px; padding-top: 4px; }
.zoom-open { flex: 1; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border-radius: 14px; background: #0B5CFF; color: #fff; font-weight: 700; text-decoration: none; }
.zoom-open .ico { width: 20px; height: 20px; }
.dialog .opt .ico { width: 18px; height: 18px; color: var(--muted); flex: none; }
.act--pink { background: var(--accent-soft) !important; color: var(--accent-text) !important; }
.card-who { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.card-who b { font-size: 20px; line-height: 1.2; }
.dm-btn { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 12px 0 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-text); font-size: 13px; font-weight: 700; text-decoration: none; margin-top: 4px; }
.dm-btn .ico { width: 16px; height: 16px; }
.hist-toggle { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 44px; padding: 0; border: 0; background: transparent; color: var(--ink); font: inherit; text-align: left; }
.hist-toggle .sub { font-weight: 500; }
.hist-toggle .ico { margin-left: auto; width: 18px; height: 18px; color: var(--muted); transition: transform .2s; }
.hist-toggle[aria-expanded="true"] .ico { transform: rotate(90deg); }
.history__list { display: flex; flex-direction: column; gap: 6px; }
.act--wide { grid-column: 1 / -1; }
.history { display: flex; flex-direction: column; gap: 6px; }
.history__list div { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 10px; font-size: 13px; }
.history span:first-child { color: var(--muted); }
.lock { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--off-text); background: var(--off); padding: 6px 10px; border-radius: 8px; }

.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 700; }
.field input, .field textarea, .field select { min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font-size: 16px; font-weight: 400; width: 100%; }
.field textarea { padding: 12px 14px; resize: none; }
.err { font-size: 13px; color: var(--danger); }
.opt { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1px solid transparent; background: var(--surface); text-align: left; width: 100%; }
.opt--sel { border: 2px solid var(--accent); }
.opt__text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.radio { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--disabled); flex: none; background: var(--surface); }
.opt--sel .radio { border: 7px solid var(--accent); }
.seg { display: grid; gap: 6px; }
.seg--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.seg--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.seg--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.seg--7 { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.seg button { min-height: 44px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: 13px; padding: 0 4px; }
.pillbar { display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 14px; background: var(--off); gap: 4px; }
.pillbar button { min-height: 40px; border: 0; border-radius: 10px; background: transparent; font-weight: 600; font-size: 14px; color: var(--off-text); }
.pillbar button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(24, 32, 58, .12); }
.toggle { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); text-align: left; width: 100%; }
.toggle__track { width: 44px; height: 26px; border-radius: 13px; background: var(--disabled); position: relative; flex: none; }
.toggle__track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: left .15s; }
.toggle[aria-pressed="true"] .toggle__track { background: var(--accent); }
.toggle[aria-pressed="true"] .toggle__track::after { left: 21px; }
.stepper { display: flex; align-items: center; gap: 8px; }
.stepper b { min-width: 64px; text-align: center; font: 600 17px var(--font-num); }

/* iOS-style wheels: scroll-snap columns with a selection band */
.wheels { position: relative; display: grid; gap: 4px; background: var(--surface); border-radius: 18px; padding: 8px; }
.wheels--3 { grid-template-columns: 1.7fr 1fr 1fr; }
.wheels--2 { grid-template-columns: 1fr 1fr; }
.wheels::before { content: ""; position: absolute; left: 8px; right: 8px; top: calc(8px + var(--wheel-row) * 2); height: var(--wheel-row); border-radius: 10px; background: var(--off); pointer-events: none; }
.wheel { position: relative; height: calc(var(--wheel-row) * 5); overflow-y: auto; scroll-snap-type: y mandatory; scrollbar-width: none; overscroll-behavior: contain;
  -webkit-mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent); mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent); border-radius: 10px; }
.wheel::-webkit-scrollbar { display: none; }
.wheel__pad { height: calc(var(--wheel-row) * 2); }
.wheel__item { display: flex; align-items: center; justify-content: center; height: var(--wheel-row); width: 100%; border: 0; background: transparent; padding: 0; scroll-snap-align: center; font-size: 18px; color: var(--muted); white-space: nowrap; }
.wheel__item[aria-selected="true"] { color: var(--ink); font-weight: 700; }
.wheel__item--busy { text-decoration: line-through; opacity: .55; }
.wheel__item--off { opacity: .4; }
.wheels__label { position: absolute; top: calc(8px + var(--wheel-row) * 2); height: var(--wheel-row); display: flex; align-items: center; pointer-events: none; font-size: 13px; color: var(--muted); }
.free-chip { flex: none; min-height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font-weight: 700; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.1; }
.free-chip small { font-size: 11px; font-weight: 500; color: var(--muted); }
.free-chip.is-sel small { color: inherit; }
.jump { flex: none; min-height: 40px; padding: 0 12px; border-radius: 20px; border: 1px solid var(--line); background: var(--surface); font-size: 13px; font-weight: 600; }

.picked { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 12px 14px; border-radius: 14px; background: var(--night); color: var(--night-text); }
.picked small { font-size: 12px; color: var(--night-sub); display: block; }
.picked b { font: 600 17px var(--font-num); }
.picked__wide { grid-column: 1 / -1; font-size: 14px; }
.prices { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.price { min-height: 60px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0; }
.price b { font-size: 17px; }
.price small { font-size: 12px; }
.msg { background: var(--surface); border-radius: 16px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.msg p { white-space: pre-line; font-size: 14px; overflow-wrap: anywhere; }
.preview { border-left: 3px solid var(--accent); padding: 4px 0 4px 12px; font-size: 13px; white-space: pre-line; }
.toast { position: absolute; left: 12px; right: 12px; bottom: calc(88px + env(safe-area-inset-bottom, 0px)); z-index: 50; background: var(--night); color: var(--night-text); padding: 12px 16px; border-radius: 14px; font-size: 14px; max-width: 416px; margin: 0 auto; }
.toast[hidden] { display: none; }

.wiz { position: absolute; inset: 0; background: var(--bg); display: flex; flex-direction: column; }
.wiz__head { display: flex; align-items: center; gap: 8px; padding: 12px 12px 6px; }
.wiz__title { flex: 1; min-width: 0; text-align: center; }
.wiz__title h2 { font-size: 19px; font-weight: 700; }
.progress { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 4px 16px 6px; }
.progress i { height: 4px; border-radius: 2px; background: var(--disabled); }
.progress i.on { background: var(--accent); }
.wiz__body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 12px 16px 24px; display: flex; flex-direction: column; gap: 14px; }
/* Scrollable rows inside column layouts must keep their height instead of shrinking to a sliver. */
.wiz__body > *, .screen > *, .section > *, .sheet > * { flex-shrink: 0; }
.wiz__foot { padding: 12px 16px calc(16px + env(safe-area-inset-bottom, 0px)); background: var(--surface); display: flex; flex-direction: column; gap: 8px; }
.wiz__foot .sub { text-align: center; }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(104px, 1fr)); gap: 8px; }
.tile { background: var(--surface); border-radius: 16px; padding: 12px 10px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tile .sub { font-size: 12px; overflow-wrap: anywhere; }
.tile b { font-size: 15px; line-height: 1.25; white-space: nowrap; }
.row--wrap { flex-wrap: wrap; row-gap: 6px; }
.tile b { font-size: 17px; }
.trip { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; background: var(--surface); }
.trip__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }

/* ===== Shared iOS-style pieces (step «Когда» in both variants) ===== */
.ios-h { margin: 6px 4px -6px; font-size: 13px; color: var(--muted); display: flex; justify-content: space-between; gap: 8px; }
.ios-card { background: var(--surface); border-radius: 14px; overflow: hidden; }
.ios-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; padding: 8px 16px; border-bottom: 1px solid var(--line); width: 100%; background: transparent; border-left: 0; border-right: 0; border-top: 0; text-align: left; font-size: 16px; }
.ios-card > .ios-row:last-child, .ios-card > .lc-row:last-child { border-bottom: 0; }
.ios-row--nav { min-height: 58px; }
.ios-val { color: var(--muted); text-align: right; }
.ios-chev { color: var(--disabled-text); font-size: 22px; }
.time-pill { background: var(--off); color: var(--accent-text); border-radius: 8px; padding: 6px 12px; font-size: 17px; font-weight: 600; }
.wheels--ios { border-radius: 0; background: transparent; padding: 4px 8px 8px; }
.wheels--ios .wheel__item { font-size: 21px; }
.ios-link { border: 0; background: transparent; color: var(--accent); font-weight: 600; font-size: 15px; min-height: 44px; padding: 0 8px; }
.lc-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 60px; padding: 10px 14px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; }
.lc-row--dead { opacity: .55; }
.lc-row--dead .lc-name { text-decoration: line-through; }
.lc-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.lc-open { border: 0; background: transparent; padding: 0; text-align: left; min-height: 44px; justify-content: center; }
.lc-time { width: 54px; flex: none; display: flex; flex-direction: column; }
.lc-time b { font-size: 16px; } .lc-time small { font-size: 12px; color: var(--muted); }
.lc-right { font-size: 15px; white-space: nowrap; }
.small-btn--acc { background: var(--accent-soft); color: var(--accent-text); border: 0; }
.itile, .tgtile { width: 38px; height: 38px; border-radius: 12px; flex: none; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 12px; }
.tile--warn { background: var(--warn-soft); color: var(--warn-text); } .tile--acc { background: var(--accent-soft); color: var(--accent-text); }
.tile--danger { background: var(--danger-soft); color: var(--danger-text); } .tile--ok { background: var(--ok-soft); color: var(--ok-text); } .tile--muted { background: var(--off); color: var(--off-text); }

/* Calendar as iOS inline picker: circles instead of tiles */
.v-calm .cal__cell, .v-tg .cal__cell { height: 44px; gap: 1px; }
.v-calm .cal__cell b, .v-tg .cal__cell b { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 500; }
.v-calm .cal__cell.is-sel, .v-tg .cal__cell.is-sel { background: transparent !important; color: inherit !important; }
.v-calm .cal__cell.is-sel b, .v-tg .cal__cell.is-sel b { background: var(--accent); color: var(--accent-ink); font-weight: 700; }
.v-calm .cal__cell--today, .v-tg .cal__cell--today { background: transparent; }
.v-calm .cal__cell--today b, .v-tg .cal__cell--today b { color: var(--accent); font-weight: 700; }
.v-calm .cal__cell i, .v-tg .cal__cell i { height: 3px; margin-top: -2px; }
.v-calm .cal__cell--trip, .v-tg .cal__cell--trip { box-shadow: none; }
.v-calm .cal__cell--trip b, .v-tg .cal__cell--trip b { box-shadow: inset 0 -2px 0 var(--warn); }

/* ===== Variant accents: Telegram blue ===== */
.v-calm, .v-tg { --font-num: var(--font-ui); --accent: #1677C8; --accent-ink: #FFFFFF; --accent-soft: #E3F1FC; --accent-text: #0F5A99; --tg-blue: #1D8FD8; }
.v-tg { --bg: #EFEFF4; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .v-calm:not(.v-min), :root:not([data-theme="light"]) .v-tg { --accent: #5DB8F2; --accent-ink: #06121D; --accent-soft: #12324A; --accent-text: #BFE3FA; } :root:not([data-theme="light"]) .v-tg { --bg: #0F1424; } }
:root[data-theme="dark"] .v-calm:not(.v-min), :root[data-theme="dark"] .v-tg { --accent: #5DB8F2; --accent-ink: #06121D; --accent-soft: #12324A; --accent-text: #BFE3FA; }
:root[data-theme="dark"] .v-tg { --bg: #0F1424; }

/* ===== Variant 1: calm bank, blue ===== */
.v-calm .screen { bottom: calc(72px + env(safe-area-inset-bottom, 0px)); padding-bottom: 88px; gap: 18px; }
.hello { display: flex; align-items: center; gap: 12px; }
.has-photo { padding: 0; overflow: hidden; position: relative; }
/* A photo sits over the initials (or Kristina's letter) and stays transparent until it has loaded:
   while it loads, or if there is none, the letters show; a broken picture never does. */
.has-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; border-radius: inherit; }
.av__img { opacity: 0; transition: opacity .2s ease; }
.av__img.is-on { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .av__img { transition: none; } }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.me { display: flex; align-items: center; gap: 16px; }
.me__photo { position: relative; cursor: pointer; flex: none; border-radius: 50%; }
.me__av { width: 84px; height: 84px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-size: 30px; box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--accent); }
.me__cam { position: absolute; right: -2px; bottom: -2px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); color: var(--ink); box-shadow: 0 2px 8px rgba(0, 0, 0, .15); }
.me__cam .ico { width: 16px; height: 16px; }
#me-photo:focus-visible + .me__text, .me__photo:focus-within { outline: 2px solid var(--accent); outline-offset: 4px; }
.me__text .big-title { font-size: 26px; margin: 0; }
.tgline { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: var(--surface); color: var(--ink); text-decoration: none; min-height: 56px; }
.tgline__ico { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: #1D8FD8; color: #fff; flex: none; }
.tgline__ico .ico { width: 20px; height: 20px; }
.tgline__text { flex: 1; display: grid; gap: 2px; min-width: 0; }
.place { display: flex; align-items: center; gap: 12px; }
.place__text { flex: 1; display: grid; gap: 2px; min-width: 0; }
.places { display: grid; gap: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-btn { border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 999px; padding: 8px 14px; font: inherit; font-size: 14px; min-height: 40px; }
.panel--soft { box-shadow: none; }
#trip-form .grid2 > * { min-width: 0; }
#trip-form input[type=date] { min-width: 0; padding: 0 10px; }
#trip-q::-webkit-search-cancel-button { -webkit-appearance: none; }
.places { gap: 0; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
#trip-form .places .opt { min-height: 52px; padding: 8px 14px; border: 0; border-radius: 0; box-shadow: none; margin: 0; }
#trip-form .places .opt + .opt { border-top: 1px solid var(--line); }
.field select { font: inherit; }
.hello__av { width: 44px; height: 44px; border-radius: 50%; background: var(--surface); color: var(--ink); }
.hello__text { flex: 1; min-width: 0; }
.hello__text h1 { font-size: 18px; font-weight: 700; }
.round-btn { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--surface); display: flex; align-items: center; justify-content: center; flex: none; }
.hero { background: var(--surface); border-radius: 26px; padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.hero__time { font-size: 60px; font-weight: 800; letter-spacing: -0.04em; line-height: 1; }
.hero__time span { font-size: 18px; font-weight: 600; letter-spacing: 0; color: var(--muted); }
.hero__stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); background: var(--bg); border-radius: 16px; padding: 10px 4px; text-align: center; }
.hero__stats span { display: flex; flex-direction: column; }
.hero__stats span + span { border-left: 1px solid var(--line); }
.hero__stats small { font-size: 11px; color: var(--muted); }
.hero__stats b { font-size: 14px; }
.quick { background: var(--surface); border-radius: 26px; padding: 12px 6px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.quick__btn { border: 0; background: transparent; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; min-height: 64px; }
.quick__ico { width: 42px; height: 42px; border-radius: 13px; background: var(--accent-soft); color: var(--accent); display: flex; align-items: center; justify-content: center; }
.list-card { background: var(--surface); border-radius: 22px; overflow: hidden; }
.list-card > .lc-row:last-child { border-bottom: 0; }
.v-calm .day-chip { border-radius: 16px; }
.navbar { position: absolute; left: 0; right: 0; bottom: 0; height: calc(72px + env(safe-area-inset-bottom, 0px)); padding: 6px 8px env(safe-area-inset-bottom, 0px); background: var(--surface); border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: start; z-index: 5; }
.navbar .tab { height: 58px; font-size: 12px; gap: 3px; border-radius: 14px; }
.navbar .tab .ico { width: 23px; height: 23px; }
.navbar .tab[aria-current="page"] { color: var(--accent); font-weight: 700; }
.fab { position: absolute; right: 16px; bottom: calc(88px + env(safe-area-inset-bottom, 0px)); height: 58px; padding: 0 22px 0 18px; border-radius: 29px; border: 0; background: var(--accent); color: var(--accent-ink); display: flex; align-items: center; gap: 8px; font-size: 17px; font-weight: 700; box-shadow: 0 10px 26px color-mix(in srgb, var(--accent) 40%, transparent); z-index: 6; }
.fab .ico { width: 24px; height: 24px; stroke-width: 2.4; }
@media (prefers-reduced-motion: no-preference) { .fab:active { transform: scale(.96); } }
.v-calm .toast { bottom: calc(160px + env(safe-area-inset-bottom, 0px)); }

/* On a computer, show the app inside a phone-sized frame so its edges are visible. */
@media (min-width: 600px) and (min-height: 700px) {
  body { display: grid; place-items: center; min-height: 100%; background: color-mix(in srgb, var(--bg) 70%, #8A93A6); }
  #app { width: 390px; height: min(844px, calc(100vh - 32px)); border-radius: 40px; box-shadow: 0 0 0 10px #111622, 0 30px 60px rgba(0, 0, 0, .25); }
  .toast { position: fixed; left: 50%; right: auto; width: 360px; transform: translateX(-50%); }
}
.v-calm .btn { border-radius: 26px; }
.v-calm .wiz__foot { background: transparent; }

/* ===================== Minimal looks ===================== */
body.v-min { color-scheme: light; --font-num: var(--font-ui); --scrim: rgba(20, 20, 24, .35); --done-bg: rgba(194, 54, 107, .07);
  --warn: #D9892B; --warn-soft: #FBEEDB; --warn-text: #7A4A00; --ok: #2F7A57; --ok-soft: #E1F1E8; --ok-text: #1F5A3F;
  --danger: #B23B3B; --danger-soft: #F8E2E2; --danger-text: #8A2525; --night: #16161A; }
body.m-marble { --font-ui: "Inter Tight", system-ui, sans-serif; --bg: #FAFAF8; --surface: #FFFFFF; --ink: #121214; --muted: #66666E; --line: rgba(18, 18, 20, .08);
  --accent: #C2366B; --accent-2: #F08A5D; --accent-ink: #FFFFFF; --accent-soft: #FBE7EE; --accent-text: #8F1E4B; --off: #F1F1EE; --off-text: #55555C; --disabled: #E6E6E2; --disabled-text: #6A6A70;
  --r1: #F08A5D; --r2: #C2366B; --track: #EDEDEA; --desk: #E8E8E4; --done-bg: rgba(194, 54, 107, .07); }
body.m-graphite { --font-ui: "Onest", system-ui, sans-serif; color-scheme: dark; --bg: #111114; --surface: #1B1B20; --ink: #F2F1F4; --muted: #A3A1AB; --line: rgba(255, 255, 255, .08);
  --accent: #FF6F91; --accent-2: #FFB36B; --accent-ink: #1A0D12; --accent-soft: #3A2129; --accent-text: #FFB3C6; --off: #26262C; --off-text: #C9C7CF; --disabled: #2C2C33; --disabled-text: #9C9AA4;
  --warn: #F2B35B; --warn-soft: #3A2C17; --warn-text: #F7CB85; --ok: #6BD3A0; --ok-soft: #173327; --ok-text: #9FE5C1; --danger: #FF8A8A; --danger-soft: #3B1D1D; --danger-text: #FFB0B0;
  --night: #000; --scrim: rgba(0, 0, 0, .6); --r1: #FFB36B; --r2: #FF5C8A; --track: #26262C; --desk: #0B0B0D; --done-bg: rgba(255, 111, 145, .11); }
@media (min-width: 600px) and (min-height: 700px) { body.v-min { background: var(--desk); } }
.v-min .screen { gap: 22px; }
.mhead { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.mhead__date { font-size: 13px; color: var(--muted); }
.mhead h1 { font-size: 30px; font-weight: 700; letter-spacing: -0.03em; }
.mhead__av { width: 44px; height: 44px; border-radius: 50%; border: 0; background: linear-gradient(135deg, var(--r1), var(--r2)); color: #fff; font-weight: 800; font-size: 17px; flex: none; }
.v-min .day-chip { width: 44px; height: 64px; border-radius: 22px; background: transparent; color: var(--muted); }
.v-min .day-chip b { font-size: 18px; font-weight: 700; color: var(--ink); }
.v-min .day-chip.is-past b { color: var(--muted); }
.v-min .day-chip.is-sel { background: var(--ink) !important; color: var(--bg) !important; }
.v-min .day-chip.is-sel b { color: var(--bg); }
.v-min .day-chip.is-closed .day-chip__bar { width: 18px; height: 4px; background: linear-gradient(90deg, var(--r1), var(--r2)) !important; }
.mclock { display: flex; justify-content: center; gap: 18px; font-size: 13px; color: var(--muted); }
.mclock b { color: var(--ink); font-size: 15px; font-weight: 700; }
.mpills { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.mpill { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 14px 6px 6px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface); text-align: left; }
.mpill__mark { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--track); display: grid; place-items: center; color: #fff; flex: none; }
.mpill__mark .ico { width: 16px; height: 16px; stroke-width: 3; }
.mpill--done .mpill__mark { border: 0; background: linear-gradient(135deg, var(--r1), var(--r2)); }
.mpill--due .mpill__mark { border-color: var(--warn); border-style: dashed; }
.mpill__text { display: flex; flex-direction: column; line-height: 1.1; }
.mpill__text b { font-size: 14px; } .mpill__text small { font-size: 12px; color: var(--muted); }
.mpill--done .mpill__text b { text-decoration: line-through; text-decoration-color: var(--muted); }
.mstats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.mstat { border: 1px solid var(--line); background: var(--surface); border-radius: 18px; padding: 12px 14px; text-align: left; display: flex; flex-direction: column; gap: 2px; }
.mstat small { font-size: 12px; color: var(--muted); } .mstat b { font-size: 18px; }
.mlist { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.mlist .lc-row { padding-left: 2px; padding-right: 2px; }
.mtodo { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 64px; padding: 10px 2px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; }
.mtodo__box { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--muted); flex: none; }
.mtodo__box--warn { border-color: var(--warn); } .mtodo__box--acc { border-color: var(--accent); } .mtodo__box--danger { border-color: var(--danger); }
.mtodo__sum { font-weight: 700; font-size: 14px; white-space: nowrap; }
.v-min .h2 { font-size: 19px; font-weight: 700; }
.v-min .note { background: var(--surface); border: 1px solid var(--line); color: var(--muted); }
.v-min :is(.cal, .panel, .opt, .search, .list-row, .tile, .trip, .ios-card, .free-chip, .price, .msg, .toggle, .row-btn) { box-shadow: none; border: 1px solid var(--line); }
.v-min .navbar { background: var(--surface); border-top: 1px solid var(--line); }
.v-min .navbar .tab { color: var(--muted); } .v-min .navbar .tab[aria-current="page"] { color: var(--ink); background: transparent; }
.v-min .fab { background: var(--accent); color: var(--accent-ink); box-shadow: 0 12px 28px rgba(194, 54, 107, .32); border-radius: 999px; }
.m-graphite .fab { background: #F2F1F4; color: #111114; box-shadow: 0 12px 28px rgba(0, 0, 0, .5); }
.v-min .sheet { background: var(--bg); }
.v-min .dialog { background: var(--surface); border: 1px solid var(--line); }
.v-min .btn--primary { background: var(--accent); color: var(--accent-ink); }
.v-lg .btn--primary { background: linear-gradient(135deg, #D6467A, #B22E62); color: #fff; border: 1px solid rgba(255, 255, 255, .45); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 8px 22px rgba(194, 54, 107, .25); }
.v-lg.m-graphite .btn--primary { background: linear-gradient(135deg, #FF86A3, #FF5C8A); color: #1A0D12; }
.v-min .btn:disabled { background: var(--disabled); color: var(--disabled-text); }
.v-min .cal__cell.is-sel b { background: var(--ink); color: var(--bg); }
.v-min .free-chip.is-sel, .v-min .price.is-sel, .v-min .seg .is-sel { background: var(--ink) !important; color: var(--bg) !important; }
.v-min .progress i.on, .v-min .stage--on i { background: linear-gradient(90deg, var(--r1), var(--r2)); }
.v-min .toast { background: var(--ink); color: var(--bg); border-radius: 18px; }
.m-graphite .itile, .m-graphite .av { color: #1A0D12; }
.m-graphite .chip.c-acc, .m-graphite .lock { color: var(--accent-text); }

/* Minimal «Сегодня»: avatar, bell, session list */
.mhead__text { flex: 1; min-width: 0; }
.mhead h1 { font-size: 26px; }
.mbell { position: relative; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); display: grid; place-items: center; flex: none; }
.mbell .ico { width: 22px; height: 22px; }
.mbell__n { position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: linear-gradient(135deg, var(--r1), var(--r2)); color: #fff; font-size: 12px; font-weight: 800; display: grid; place-items: center; box-shadow: 0 0 0 2px var(--bg); }
.slist { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
/* a day without sessions: one calm line where the list would be */
.day-empty { gap: 12px; }
.day-empty__t { padding: 20px 0 4px; text-align: center; font-size: 16px; color: var(--muted); }
.sitem { display: flex; align-items: center; gap: 10px; padding: 8px; border-bottom: 1px solid var(--line); color: var(--ink); }
.sitem__av { position: relative; flex: none; padding: 2px; border: 0; border-radius: 50%; background: transparent; display: block; }
.sitem__av .cav { display: grid; box-shadow: 0 0 0 2px var(--bg); }
button.sitem__av { cursor: pointer; }
.sitem__av.ring-done { background: linear-gradient(135deg, var(--r1), var(--r2)); }
.sitem__av.ring-due { box-shadow: 0 0 0 2px var(--warn); }
.sitem__badge { position: absolute; right: -2px; bottom: -2px; width: 19px; height: 19px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--r1), var(--r2)); box-shadow: 0 0 0 2px var(--bg); }
.sitem__badge .ico { width: 11px; height: 11px; stroke-width: 3.2; }
.sitem__open { flex: 1; min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 4px 0; border: 0; background: transparent; text-align: left; color: inherit; }
.sitem__mid { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.sitem__name { font-weight: 700; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sitem__time { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.15; }
.sitem__time b { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; }
.sitem__time small { font-size: 12px; color: var(--muted); white-space: nowrap; }
.sitem--done { background: var(--done-bg); border-radius: 20px; border-bottom-color: transparent; margin-bottom: 4px; }
.sitem--dead .sitem__name { text-decoration: line-through; color: var(--muted); }
.sitem--dead .sitem__av { opacity: .55; }
@media (prefers-reduced-motion: no-preference) {
  .sitem--new { animation: rowdone .8s cubic-bezier(.23, 1, .32, 1) both; }
  .sitem--new .sitem__badge { animation: pop .5s cubic-bezier(.23, 1, .32, 1) both; }
  @keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }
  @keyframes rowdone { from { background: transparent; } to { background: var(--done-bg); } }
}
.sicons { display: flex; gap: 6px; }
/* Option 2 rows: time on a day line, one card per session */
.slist--tl { border-top: 0; padding: 6px 10px 6px 4px; }
.slist--tl .sitem { display: grid; grid-template-columns: 62px 14px minmax(0, 1fr); gap: 6px; align-items: stretch; padding: 0; border-bottom: 0; background: transparent; border-radius: 0; margin: 0; }
.tl-time { display: flex; flex-direction: column; align-items: flex-end; justify-content: center; line-height: 1.15; cursor: pointer; }
.tl-time b { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; }
.tl-time small { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.tl-rail { display: flex; flex-direction: column; align-items: center; }
.tl-rail i { width: 2px; flex: 1; background: var(--line); }
.slist--tl .sitem:first-child .tl-rail i:first-child, .slist--tl .sitem:last-child .tl-rail i:last-child { background: transparent; }
.tl-dot { width: 12px; height: 12px; flex: none; border-radius: 50%; border: 2px solid var(--muted); box-sizing: border-box; opacity: .7; }
.sitem--done .tl-dot { border: 0; opacity: 1; background: linear-gradient(135deg, var(--r1), var(--r2)); }
.sitem--due .tl-dot { border-color: var(--warn); border-style: dashed; opacity: 1; }
.tl-card { margin: 4px 0; padding: 8px 10px 8px 8px; border-radius: 20px; display: flex; align-items: center; gap: 10px; min-width: 0; background: var(--surface); border: 1px solid var(--line); }
.tl-card .sitem__open { align-self: stretch; padding: 2px 0; }
.slist--tl .sitem--done .tl-card { background: var(--done-bg); border-color: transparent; }
.slist--tl .sitem--dead .tl-card { opacity: .7; }
.sitem__badge--due { background: var(--surface); color: var(--warn); box-shadow: 0 0 0 2px var(--warn); }
@media (prefers-reduced-motion: no-preference) {
  .slist--tl .sitem--new { animation: none; }
  .slist--tl .sitem--new .tl-card { animation: rowdone .8s cubic-bezier(.23, 1, .32, 1) both; }
}
.sic { width: 26px; height: 26px; border-radius: 9px; display: grid; place-items: center; flex: none; }
.sic .ico { width: 15px; height: 15px; }
.sic--ok { color: var(--ok-text); background: var(--ok-soft); } .sic--bad { color: var(--danger-text); background: var(--danger-soft); }
.sic--off { color: var(--muted); background: var(--off); } .sic--ink { color: var(--ink); background: var(--off); }
.shint { display: inline-flex; align-items: flex-start; gap: 4px; font-size: 12.5px; font-weight: 600; line-height: 1.3; text-wrap: balance; }
.shint .ico { flex: none; margin-top: 1px; }
.shint .ico { width: 14px; height: 14px; stroke-width: 2.6; }
.shint--acc { color: var(--accent-text); } .shint--warn { color: var(--warn-text); } .shint--bad { color: var(--danger-text); } .shint--muted { color: var(--muted); }
.cstrip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.cst { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; min-width: 0; }
.cst .sic { width: 44px; height: 44px; border-radius: 15px; }
.cst .sic .ico { width: 20px; height: 20px; }
.cst b { font-size: 11.5px; font-weight: 650; line-height: 1.2; }
.cst--ok b { color: var(--ok-text); } .cst--bad b { color: var(--danger-text); } .cst--off b { color: var(--muted); } .cst--ink b { color: var(--ink); }
.tags { display: flex; flex-wrap: wrap; gap: 4px 10px; }
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.tag::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.tag--ok { color: var(--ok-text); } .tag--warn { color: var(--warn-text); } .tag--muted { color: var(--muted); } .tag--ink { color: var(--ink); } .tag--danger { color: var(--danger-text); }
.cav { color: #fff; font-weight: 700; letter-spacing: .01em; border-radius: 50%; }
.m-graphite .cav { color: #fff; } /* white initials in both themes, as in Telegram */
/* Compact theme switch under the name in «Кабинет» */
.tswitch { display: inline-flex; gap: 2px; margin-top: 10px; padding: 3px; border-radius: 999px; background: var(--off); }
.tswitch__opt { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 0 12px 0 8px; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font-size: 13px; font-weight: 600; }
.tswitch__opt.is-on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.tswitch__sw { width: 14px; height: 14px; border-radius: 50%; border: 1px solid rgba(127, 127, 127, .45); }
.tswitch__sw--light { background: linear-gradient(135deg, #FFFFFF 50%, #F08A5D 50%, #C2366B); }
.tswitch__sw--dark { background: linear-gradient(135deg, #111114 50%, #FFB36B 50%, #FF5C8A); }
.mtodo .ico { width: 18px; height: 18px; color: var(--muted); flex: none; }
/* Theme picker */
.themes { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.theme-opt { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 10px 10px 12px; border-radius: 20px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-align: left; }
.themes .theme-opt.is-sel { background: var(--surface) !important; color: var(--ink) !important; border-color: var(--ink) !important; box-shadow: inset 0 0 0 1px var(--ink); }
.theme-opt b { font-size: 15px; margin-top: 6px; }
.theme-opt__pv { width: 100%; height: 72px; border-radius: 14px; display: grid; place-items: center; border: 1px solid rgba(127, 127, 127, .25); }
.theme-opt__pv--light { background: #FAFAF8; } .theme-opt__pv--dark { background: #111114; }
.theme-opt__pv i { width: 40px; height: 40px; border-radius: 50%; -webkit-mask: radial-gradient(circle, transparent 13px, #000 14px); mask: radial-gradient(circle, transparent 13px, #000 14px); }
.theme-opt__pv--light i { background: conic-gradient(#F08A5D, #C2366B 62%, #EDEDEA 0); }
.theme-opt__pv--dark i { background: conic-gradient(#FFB36B, #FF5C8A 62%, #26262C 0); }

/* Month ring in «Кабинет» (all looks) */
.mring-card { display: flex; flex-direction: column; gap: 16px; padding: 16px; border-radius: 26px; background: var(--surface); border: 1px solid var(--line); }
.mring-top { display: flex; align-items: center; gap: 18px; }
.mring__month { font-size: 22px; font-weight: 700; letter-spacing: -0.01em; }
.mtiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.mtile { display: flex; flex-direction: column; gap: 2px; padding: 10px 8px 12px; border-radius: 16px; background: var(--bg); border: 0; text-align: left; color: var(--ink); min-width: 0; }
.mtile .sub { font-size: 12px; display: flex; align-items: center; justify-content: space-between; gap: 2px; }
.mtile .sub .ico { width: 14px; height: 14px; }
.mtile b { font-size: 14px; letter-spacing: -0.01em; white-space: nowrap; }
@media (max-width: 360px) { .mtiles { grid-template-columns: 1fr 1fr; } .mtile--btn { grid-column: span 2; } }
.mtile--btn { box-shadow: inset 0 0 0 1px var(--line); }
.mring { position: relative; width: 150px; height: 150px; flex: none; }
.mring__svg { width: 100%; height: 100%; display: block; }
.mring__track { fill: none; stroke: var(--track, var(--off)); stroke-width: 13; }
.mring__bar { fill: none; stroke: url(#mgrad); stroke-width: 13; stroke-linecap: round; }
.mg1 { stop-color: var(--r1, var(--accent-2, var(--accent))); } .mg2 { stop-color: var(--r2, var(--accent)); }
.mring__tick { stroke: var(--line); stroke-width: 2; stroke-linecap: round; }
.mring__tick--past { stroke: var(--muted); opacity: .55; }
.mring__center { position: absolute; inset: 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.mring__num { font-size: 34px; font-weight: 800; letter-spacing: -0.04em; line-height: 1; }
.mring__num span { font-size: 18px; color: var(--muted); font-weight: 600; }
.mring__cap { font-size: 11px; color: var(--muted); margin-top: 2px; }
.mring__side { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
@media (max-width: 360px) { .mring { width: 128px; height: 128px; } .mring__num { font-size: 28px; } .mring-top { gap: 12px; } }
/* ===================== «Жидкое стекло»: marble / graphite under frosted glass ===================== */
body.v-lg { --lg-base: #F6F1EF; --lg-b1: #FFD2C0; --lg-b2: #F8BFD6; --lg-b3: #DCD2FF; --lg-b4: #FFE3CF;
  --lg-fill: rgba(255, 255, 255, .5); --lg-strong: rgba(255, 255, 255, .66); --lg-edge: rgba(255, 255, 255, .85); --lg-line: rgba(30, 20, 30, .07);
  --lg-hi: inset 0 1px 0 rgba(255, 255, 255, .95), inset 0 -1px 0 rgba(255, 255, 255, .3); --lg-shadow: 0 10px 30px rgba(70, 25, 50, .07);
  --lg-lens: rgba(255, 255, 255, .85); --lg-sheet: rgba(250, 247, 246, .9); --track: rgba(255, 255, 255, .7); --desk: #E9DEDD; --done-bg: rgba(194, 54, 107, .09); }
body.v-lg.m-graphite { --lg-base: #0E0D12; --lg-b1: rgba(150, 50, 90, .55); --lg-b2: rgba(90, 60, 170, .45); --lg-b3: rgba(170, 80, 40, .35); --lg-b4: rgba(60, 40, 110, .45);
  --lg-fill: rgba(255, 255, 255, .06); --lg-strong: rgba(36, 34, 44, .55); --lg-edge: rgba(255, 255, 255, .13); --lg-line: rgba(255, 255, 255, .08);
  --lg-hi: inset 0 1px 0 rgba(255, 255, 255, .16); --lg-shadow: 0 12px 30px rgba(0, 0, 0, .35);
  --lg-lens: rgba(255, 255, 255, .14); --lg-sheet: rgba(26, 25, 32, .9); --track: rgba(255, 255, 255, .09); --desk: #050507; --done-bg: rgba(255, 111, 145, .13); }
.v-lg #app { background: var(--lg-base); isolation: isolate; overflow: clip; }
.v-lg #app::before { content: ""; position: absolute; inset: -20%; z-index: 0; pointer-events: none;
  background: radial-gradient(36% 26% at 14% 10%, var(--lg-b1), transparent 70%), radial-gradient(40% 28% at 92% 26%, var(--lg-b2), transparent 70%),
    radial-gradient(44% 30% at 22% 66%, var(--lg-b3), transparent 70%), radial-gradient(40% 30% at 86% 90%, var(--lg-b4), transparent 70%); }
@media (prefers-reduced-motion: no-preference) { .v-lg #app::before { animation: drift 30s ease-in-out infinite alternate; } }
@media (min-width: 600px) and (min-height: 700px) { body.v-lg { background: var(--desk); } }
/* glass material */
.v-lg :is(.mbell, .mring-card, .mtile, .tswitch, .panel, .trip, .opt, .search, .list-row, .list-card, .small-btn, .icon-btn, .act, .btn--plain, .btn--outline, .cal, .free-chip, .price, .msg, .toggle, .chip-btn, .tile, .row-btn, .jump, .slist, .note, .theme-opt) {
  background: var(--lg-fill); -webkit-backdrop-filter: blur(22px) saturate(180%); backdrop-filter: blur(22px) saturate(180%);
  border: 1px solid var(--lg-edge); box-shadow: var(--lg-hi), var(--lg-shadow); }
.v-lg .seg button { background: var(--lg-fill); border: 1px solid var(--lg-edge); }
.v-lg .mring-card, .v-lg .panel, .v-lg .list-card { border-radius: 28px; }
.v-lg .mtile { box-shadow: var(--lg-hi); }
.v-lg .tswitch { padding: 3px; }
.v-lg .tswitch__opt.is-on { background: var(--lg-lens); box-shadow: var(--lg-hi), 0 2px 8px rgba(0, 0, 0, .08); }
.v-lg .mbell { background: var(--lg-strong); }
.v-lg .slist { border-radius: 26px; padding: 4px 6px; }
.v-lg .sitem { border-bottom-color: var(--lg-line); }
.v-lg .sitem:last-child { border-bottom-color: transparent; }
.v-lg .sitem--done { border-radius: 20px; }
.v-lg .slist--tl { padding: 6px 10px 6px 4px; }
.v-lg .tl-card { background: var(--lg-strong); border-color: var(--lg-edge); box-shadow: var(--lg-hi); }
.v-lg .slist--tl .sitem--done .tl-card { background: var(--done-bg); border-color: transparent; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 18%, transparent); }
.v-lg .tl-rail i { background: var(--lg-line); }
.v-lg .day-chip:not(.is-sel) { background: transparent; }
.v-lg .mring__track { stroke: var(--track); }
.v-lg .lc-row { border-bottom-color: var(--lg-line); }
/* floating capsule menu (as in Telegram) and a glass «Записать» above it */
.v-lg .screen { bottom: 0; padding-bottom: calc(176px + env(safe-area-inset-bottom, 0px)); }
.v-lg .navbar { left: 14px; right: 14px; bottom: calc(14px + env(safe-area-inset-bottom, 0px)); height: 64px; padding: 4px; border-radius: 32px; border: 1px solid var(--lg-edge);
  background: var(--lg-strong); -webkit-backdrop-filter: blur(30px) saturate(200%); backdrop-filter: blur(30px) saturate(200%);
  box-shadow: var(--lg-hi), 0 14px 38px rgba(40, 10, 30, .16); align-items: center; }
.v-lg.m-graphite .navbar { box-shadow: var(--lg-hi), 0 14px 38px rgba(0, 0, 0, .55); }
.v-lg .navbar .tab { height: 54px; border-radius: 27px; color: var(--ink); font-size: 11px; }
.v-lg .navbar .tab[aria-current="page"] { background: var(--lg-lens); color: var(--accent-text); box-shadow: var(--lg-hi), 0 2px 10px rgba(0, 0, 0, .06); }
.v-lg .fab { right: 16px; bottom: calc(92px + env(safe-area-inset-bottom, 0px)); height: 56px; padding: 0 22px 0 18px; font-size: 18px; font-weight: 750;
  background: linear-gradient(135deg, rgba(255, 228, 236, .72), rgba(250, 205, 222, .62)); color: var(--accent-text); border: 1px solid rgba(255, 255, 255, .9);
  -webkit-backdrop-filter: blur(24px) saturate(200%); backdrop-filter: blur(24px) saturate(200%);
  box-shadow: inset 0 1px 0 #fff, inset 0 -1px 0 rgba(255, 255, 255, .4), 0 10px 28px rgba(194, 54, 107, .18); }
.v-lg.m-marble .fab { background: linear-gradient(135deg, rgba(34, 32, 38, .92), rgba(10, 10, 12, .88)); color: #FFFFFF; border-color: rgba(255, 255, 255, .22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), 0 12px 30px rgba(18, 18, 20, .30); }
.v-lg.m-graphite .fab { background: linear-gradient(135deg, rgba(255, 255, 255, .97), rgba(232, 230, 236, .93)); color: #111114; border-color: rgba(255, 255, 255, .7);
  box-shadow: inset 0 1px 0 #FFFFFF, 0 12px 30px rgba(0, 0, 0, .45); }
.v-lg .toast { bottom: calc(164px + env(safe-area-inset-bottom, 0px)); background: rgba(24, 18, 24, .82); color: #fff; -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); border-radius: 20px; }
.v-lg.m-graphite .toast { background: rgba(245, 243, 247, .9); color: #111114; }
/* sheets and dialogs as frosted panes */
.v-lg :is(.sheet, .dialog) { background: var(--lg-sheet); -webkit-backdrop-filter: blur(40px) saturate(180%); backdrop-filter: blur(40px) saturate(180%); border: 1px solid var(--lg-edge); }
.v-lg .sheet { border-bottom: 0; border-radius: 30px 30px 0 0; }
.v-lg .dialog { border-radius: 30px; }
.v-lg .wiz { background: var(--lg-sheet); -webkit-backdrop-filter: blur(40px) saturate(180%); backdrop-filter: blur(40px) saturate(180%); }
.v-lg .wiz__foot { background: transparent; }
.v-lg .btn { border-radius: 30px; }
.v-lg .field :is(input, textarea, select) { background: var(--lg-fill); border-color: var(--lg-edge); }

/* Month card: counts instead of a percent */
.mring__stat { display: flex; align-items: baseline; gap: 6px; font-size: 15px; font-weight: 600; color: var(--muted); }
.mring__stat b { font-size: 40px; line-height: 1; letter-spacing: -0.04em; font-weight: 800; background: linear-gradient(120deg, var(--r1, var(--accent)), var(--r2, var(--accent))); -webkit-background-clip: text; background-clip: text; color: transparent; }
.mtiles--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* Example rows under «Значки в списке сессий» */
.icoex__cap { margin-top: 2px; }
.icoex { display: flex; flex-direction: column; padding: 4px 14px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.icoex__row { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 8px 0; }
.icoex__row + .icoex__row { border-top: 1px solid var(--line); }
.icoex__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.icoex__main b { font-size: 15px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icoex__note { flex: none; max-width: 38%; text-align: right; font-size: 12px; color: var(--muted); line-height: 1.3; }
.v-lg .icoex { background: var(--lg-fill); border-color: var(--lg-edge); box-shadow: var(--lg-hi), var(--lg-shadow); -webkit-backdrop-filter: blur(22px) saturate(180%); backdrop-filter: blur(22px) saturate(180%); }
.v-lg .icoex__row + .icoex__row { border-top-color: var(--lg-line); }
/* History: delivery facts marked green or red */
.history__list .h-ok span:last-child::before { content: "✓"; color: var(--ok-text); font-weight: 800; margin-right: 6px; }
.history__list .h-bad span:last-child { color: var(--danger-text); }
.history__list .h-bad span:last-child::before { content: "!"; display: inline-grid; place-items: center; width: 15px; height: 15px; margin-right: 6px; border-radius: 50%; background: var(--danger-soft); color: var(--danger-text); font-size: 11px; font-weight: 800; }
/* Zoom recording */
.rec { gap: 10px; }
.rec__head { display: inline-flex; align-items: center; gap: 8px; }
.rec__head .ico { width: 18px; height: 18px; color: var(--accent-text); }
.rec__rows { display: flex; flex-direction: column; }
.rec__rows .fact { grid-template-columns: 64px minmax(0, 1fr); }
.rec__rows .fact:last-child { border-bottom: 0; }
.rec__url { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.rec__code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 15px; letter-spacing: .02em; }
a.act { display: grid; place-items: center; text-decoration: none; color: var(--ink); }
.recrow { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.recrow:last-child { border-bottom: 0; }
.recrow__main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.recrow--gone { color: var(--muted); }
/* Payment providers */
.paym2 { padding: 6px; gap: 0; }
.payrow { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 60px; padding: 8px 10px; border: 0; border-radius: 20px; background: transparent; color: var(--ink); text-align: left; font: inherit; }
.payrow + .payrow { border-top: 1px solid var(--line); border-radius: 0 0 20px 20px; }
.payrow__ico { width: 38px; height: 38px; border-radius: 13px; display: grid; place-items: center; flex: none; background: var(--accent-soft); color: var(--accent-text); }
.payrow__ico .ico { width: 19px; height: 19px; }
.payrow__text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.payrow__text b { font-size: 15px; font-weight: 650; }
.payrow__text .sub { font-size: 12.5px; }
.payrow__val { display: inline-flex; align-items: center; gap: 2px; padding: 6px 6px 6px 12px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-text); font-size: 14px; font-weight: 700; white-space: nowrap; }
.payrow__val .chev { width: 16px; height: 16px; transform: rotate(90deg); transition: transform .2s; }
.payrow[aria-expanded="true"] .payrow__val .chev { transform: rotate(-90deg); }
.payrow__val--fixed { padding: 6px 12px; background: transparent; color: var(--muted); }
.paypick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; padding: 2px 2px 4px; }
.paypick button { min-height: 54px; padding: 6px 2px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-width: 0; }
.paypick b { font-size: 13.5px; font-weight: 700; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.paypick small { font-size: 11px; color: var(--muted); }
.paypick button.is-sel { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.paypick button.is-sel small { color: inherit; opacity: .75; }
.paypick button:disabled { opacity: .5; }
.v-lg .paypick button:not(.is-sel) { background: var(--lg-fill); border-color: var(--lg-edge); box-shadow: var(--lg-hi); }
.v-lg .payrow + .payrow { border-top-color: var(--lg-line); }
.opt:disabled { opacity: .55; }
.tagline { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; font-size: 11px; font-weight: 700; background: var(--danger-soft); color: var(--danger-text); vertical-align: 1px; }
.tagline--soon { background: var(--off); color: var(--off-text); }
.seg button.is-sel { font-weight: 700; }
.calrow { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

/* ===================== Кабинет: статистика (дизайн 1 «Как в Telegram») ===================== */
body.v-min { --st-s1: #C2366B; --st-s2: #6E62D9; }
body.m-graphite { --st-s1: #E85A7B; --st-s2: #8B7CF5; }
.stats { display: flex; flex-direction: column; gap: 10px; }
.stats__head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.stats__head .sub { font-size: 15px; font-weight: 600; }
.stats__vs { margin: -2px 2px 0; }
.st-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.st-tile { display: flex; flex-direction: column; gap: 3px; padding: 12px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); min-width: 0; }
.st-tile .sub { font-size: 12.5px; }
.st-tile b { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; white-space: nowrap; }
.st-tile b small { font-size: 14px; font-weight: 600; color: var(--muted); letter-spacing: 0; }
.st-delta { align-self: flex-start; display: inline-flex; gap: 3px; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.st-delta--up { background: var(--ok-soft); color: var(--ok-text); } .st-delta--down { background: var(--danger-soft); color: var(--danger-text); } .st-delta--flat { background: var(--off); color: var(--off-text); }
.st-wait { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 48px; padding: 0 14px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); color: var(--ink); font: inherit; cursor: pointer; text-align: left; }
.st-wait b { display: inline-flex; align-items: center; gap: 4px; font-size: 16px; }
.st-wait .ico { width: 16px; height: 16px; color: var(--muted); }
.st-card { display: flex; flex-direction: column; gap: 8px; padding: 14px 14px 12px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); min-width: 0; }
.st-card h3 { margin: 0; font-size: 16px; font-weight: 700; display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.st-card h3 span { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.st-tiles--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.st-tiles--3 .st-tile b { font-size: 22px; }
.st-tiles--3 .st-delta { font-size: 11.5px; padding: 2px 7px; }
.st-per { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.st-per b { flex: 1; text-align: center; font-size: 16px; font-weight: 700; }
.st-dates { gap: 8px; }
.st-sub { margin: 4px 0 -2px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.st-rows { display: flex; flex-direction: column; }
.st-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.st-row:last-child { border-bottom: 0; }
.st-row > span { min-width: 0; }
.st-row > span .sub { font-size: 12.5px; margin-left: 4px; }
.st-row b { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.st-row b small { font-size: 12px; font-weight: 600; color: var(--muted); }
.st-row--total b { font-size: 18px; font-weight: 800; }
.st-row--sub { padding: 5px 0 5px 12px; font-size: 13px; }
.st-row--sub b { font-weight: 600; }
.st-row--range b { line-height: 1.35; }
.st-row--zero { color: var(--muted); }
.st-deltarow { margin: -4px 0 0; text-align: right; }
.st-prov { display: flex; flex-direction: column; gap: 2px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.st-prov:last-of-type { border-bottom: 0; }
.st-prov__top { display: flex; align-items: baseline; gap: 8px; font-size: 14px; }
.st-prov__top .sub { flex: 1; font-size: 12.5px; }
.st-prov__net { font-variant-numeric: tabular-nums; white-space: nowrap; }
.st-prov .sub { font-size: 12.5px; }
.st-prov--zero { color: var(--muted); }
.st-loading { opacity: .55; transition: opacity .2s; }
.seg--5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
/* «Ожидаем деньги»: each line is a button that opens its list */
.ex-row { display: grid; grid-template-columns: minmax(0, 1fr) auto 16px; align-items: center; column-gap: 8px; width: 100%; min-height: 48px; padding: 8px 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--ink); font: inherit; font-size: 14px; text-align: left; cursor: pointer; }
.st-rows > .ex-row:last-child { border-bottom: 0; }
.ex-row__label { min-width: 0; }
.ex-row__note { grid-column: 1 / 3; margin-top: 1px; font-size: 12.5px; color: var(--muted); line-height: 1.3; }
.ex-row b { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.ex-row .chev { width: 16px; height: 16px; }
.ex-row:disabled { color: var(--muted); cursor: default; }
.ex-row:disabled .chev { visibility: hidden; }
.ex-row--total { border-top: 1px solid var(--line); margin-top: 2px; }
.ex-row--total .ex-row__label { font-weight: 700; font-size: 15px; }
.ex-row--total b { font-size: 17px; font-weight: 800; line-height: 1.35; }
.v-lg .ex-row { border-bottom-color: var(--lg-line); }
.v-lg .ex-row--total { border-top-color: var(--lg-line); }
/* «Общие ссылки на оплату» in the cabinet */
.glink { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.glink:last-child { border-bottom: 0; }
.glink__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.glink__main b { font-size: 15px; }
.glink__url { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.v-lg .glink { border-bottom-color: var(--lg-line); }
.money-facts .fact b { font-variant-numeric: tabular-nums; }
/* «Задачи»: a full page from the bell. Category tiles two per row, the chosen category's list below. */
.tpage { position: absolute; inset: 0; background: var(--bg); display: flex; flex-direction: column; }
.wiz__pad { width: 44px; flex: none; }
.tpage .wiz__title h2 { font-size: 20px; }
.tpage .wiz__title h2:focus { outline: none; }
.tpage .wiz__body { gap: 18px; padding-top: 8px; padding-bottom: calc(28px + env(safe-area-inset-bottom, 0px)); }
.tgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ttile { position: relative; display: flex; flex-direction: column; align-items: flex-start; min-width: 0; min-height: 118px; padding: 12px 14px 13px; border-radius: 24px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-align: left; font: inherit; cursor: pointer; }
.ttile__ico { width: 36px; height: 36px; border-radius: 13px; display: grid; place-items: center; background: var(--off); color: var(--ink); margin-bottom: auto; }
.ttile__ico .ico { width: 19px; height: 19px; }
.ttile__n { position: absolute; top: 8px; right: 14px; font-size: 32px; line-height: 1.15; font-weight: 800; letter-spacing: -0.03em; }
.ttile__name { margin-top: 12px; font-size: 15px; font-weight: 700; line-height: 1.2; overflow-wrap: anywhere; }
.ttile__sub { margin-top: 2px; font-size: 12.5px; line-height: 1.25; color: var(--muted); }
.ttile--urgent { border-color: color-mix(in srgb, var(--danger) 38%, transparent); }
.ttile--urgent .ttile__ico { background: var(--danger-soft); color: var(--danger-text); }
.ttile[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--ink); }
.ttile:disabled { opacity: .5; cursor: default; }
.tsec { display: flex; flex-direction: column; gap: 8px; }
.tlist { display: flex; flex-direction: column; padding: 2px 12px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.trow { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 66px; padding: 10px 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--ink); text-align: left; font: inherit; cursor: pointer; }
.trow:last-child { border-bottom: 0; }
.trow .cav { flex: none; border-radius: 50%; }
.trow__mid { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.trow__name { font-size: 16px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trow__what { font-size: 13px; line-height: 1.3; color: var(--muted); }
.trow__what--bad { color: var(--danger); font-weight: 600; }
.trow__when { flex: none; display: flex; flex-direction: column; align-items: flex-end; line-height: 1.15; }
.trow__when b { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; }
.trow__when small { font-size: 12px; color: var(--muted); white-space: nowrap; }
.tpage__empty { text-align: center; padding: 8px 0; }
@media (max-width: 360px) {
  .tgrid { gap: 8px; }
  .ttile { min-height: 104px; padding: 10px 12px 11px; }
  .ttile__ico { width: 32px; height: 32px; border-radius: 11px; }
  .ttile__n { top: 6px; right: 12px; font-size: 28px; }
  .ttile__name { margin-top: 10px; font-size: 14px; }
  .ttile__sub { font-size: 12px; }
  .trow { gap: 10px; }
  .trow__when b { font-size: 18px; }
}
/* the page is opaque, with its own soft colour under the glass tiles, so «Сегодня» does not show through */
.v-lg .tpage { background: var(--lg-base); isolation: isolate; overflow: hidden; }
.v-lg .tpage::before { content: ""; position: absolute; inset: -20%; z-index: -1; pointer-events: none;
  background: radial-gradient(36% 26% at 14% 10%, var(--lg-b1), transparent 70%), radial-gradient(40% 28% at 92% 26%, var(--lg-b2), transparent 70%),
    radial-gradient(44% 30% at 22% 66%, var(--lg-b3), transparent 70%), radial-gradient(40% 30% at 86% 90%, var(--lg-b4), transparent 70%); }
.v-lg :is(.ttile, .tlist) { background: var(--lg-fill); -webkit-backdrop-filter: blur(22px) saturate(180%); backdrop-filter: blur(22px) saturate(180%); border: 1px solid var(--lg-edge); box-shadow: var(--lg-hi), var(--lg-shadow); }
.v-lg .ttile { border-radius: 26px; }
.v-lg .ttile--urgent { border-color: color-mix(in srgb, var(--danger) 40%, var(--lg-edge)); }
.v-lg .ttile[aria-pressed="true"] { background: var(--lg-lens); box-shadow: var(--lg-hi), inset 0 0 0 2px var(--ink), var(--lg-shadow); }
.v-lg .ttile:disabled { box-shadow: none; }
.v-lg .tlist { border-radius: 26px; }
.v-lg .trow { border-bottom-color: var(--lg-line); }
.v-lg :is(.st-tile, .st-card, .st-wait) { background: var(--lg-fill); -webkit-backdrop-filter: blur(22px) saturate(180%); backdrop-filter: blur(22px) saturate(180%); border: 1px solid var(--lg-edge); box-shadow: var(--lg-hi), var(--lg-shadow); }
.v-lg .st-tile { box-shadow: var(--lg-hi); }
.v-lg .st-card { border-radius: 26px; }

/* ===== November 2026: five tabs, «Настройки» pages, «Кабинет» switch, «Уточнить» and «Чеки» ===== */
.navbar--5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.navbar--5 .tab { padding: 0 1px; min-width: 0; }
.navbar--5 .tab { white-space: nowrap; letter-spacing: -0.01em; }
@media (max-width: 374px) {
  .navbar--5 .tab, .v-lg .navbar--5 .tab { font-size: 10px; gap: 2px; }
  .navbar--5 .tab .ico { width: 21px; height: 21px; }
  .v-lg .navbar--5 { left: 8px; right: 8px; padding: 3px; }
}
.cab-seg button { min-height: 46px; font-size: 15px; }
.st-period-h { margin-top: 6px; }
/* «Настройки»: a grouped list (iOS style); every row opens its own page with a back button */
.sgroup { display: flex; flex-direction: column; gap: 8px; }
.sgroup__title { margin: 0 4px; font-size: 13px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; color: var(--muted); }
.sgroup__foot { text-align: center; }
.srow { min-height: 64px; color: var(--ink); font: inherit; cursor: pointer; }
.srow .lc-main b { font-size: 16px; }
.srow .lc-main .sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srow__ico { width: 36px; height: 36px; flex: none; border-radius: 11px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-text); }
.srow__ico .ico { width: 20px; height: 20px; }
.srow .chev { color: var(--disabled-text, var(--muted)); flex: none; }
.spage__head { display: flex; align-items: center; gap: 12px; }
.spage__head .big-title { margin: 0; font-size: 24px; min-width: 0; }
.spage__head .icon-btn { flex: none; }
.prof { flex-direction: row; align-items: center; gap: 16px; }
.prof .me__av { width: 72px; height: 72px; font-size: 26px; }
.prof__text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.prof__text b { font-size: 18px; }
.prof__acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
/* «Уточнить» and «Чеки» rows carry their own buttons, so the row itself is not a button */
.trow--ask, .trow--split { cursor: default; align-items: flex-start; }
.trow__ico { width: 40px; height: 40px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-text); }
.trow__ico .ico { width: 21px; height: 21px; }
.trow__acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.trow__acts .small-btn { min-height: 44px; }
.small-btn--danger { background: var(--danger-soft) !important; color: var(--danger-text) !important; border-color: transparent !important; }
.trow--split { flex-direction: column; gap: 6px; }
.trow__open { display: flex; align-items: center; gap: 12px; width: 100%; padding: 0; border: 0; background: transparent; color: var(--ink); text-align: left; font: inherit; cursor: pointer; }
.trow__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; padding-left: 52px; }
.trow__note { font-size: 12.5px; line-height: 1.3; color: var(--muted); min-width: 0; }
.trow__note--bad { color: var(--danger); font-weight: 600; }
.trow__foot .small-btn { min-height: 44px; white-space: nowrap; }
.trow__foot .small-btn:disabled { opacity: .6; }
/* the pairs of cards that may be one person */
.pair { gap: 8px; }
.pair__cards { display: flex; flex-direction: column; gap: 8px; }
.pair__who { display: flex; flex-direction: column; gap: 2px; }
.pair__who b { font-size: 16px; }
.pair .grid2 .act, .pair__one .act { min-height: 44px; }
.pair__one { display: grid; }
.ptag { display: inline-block; margin-left: 6px; font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 999px; background: var(--ok-soft); color: var(--ok-text); vertical-align: 1px; }
@media (max-width: 360px) {
  .trow__foot { padding-left: 0; flex-wrap: wrap; }
  .trow__acts .small-btn { padding: 0 10px; }
}
.v-lg .srow__ico, .v-lg .trow__ico { background: var(--lg-lens, var(--accent-soft)); box-shadow: var(--lg-hi); }

/* Card: «Ссылки на оплату» — the history of payment links; the old ones are quiet. */
#card-links .h3 { margin: 8px 0 2px; }
#card-links .small-btn { margin: 10px 0 12px; align-self: flex-start; }
.plink--paid > span:last-child { color: var(--ok-text); }
.plink--failed > span:last-child { color: var(--danger-text); }
.plink--replaced > span { color: var(--muted); }
/* «Деньги»: the Lava card and its sheet. */
#st-lava .small-btn { margin-top: 10px; }
.lava-acts { display: flex; flex-wrap: wrap; gap: 8px; }
#lava-all { align-self: flex-start; }
#lava-sheet .seg { margin-bottom: 4px; }

/* «Ссылка на оплату»: one screen; «Старая цена» chip; where to send the ready message */
.price--old small { color: var(--accent-text); font-weight: 600; }
.link-who { cursor: default; }
.link-who .small-btn { margin-left: auto; }
.share { display: flex; flex-direction: column; gap: 10px; }
#new-choice .opt { width: 100%; }
#new-choice .opt .ico:last-child { width: 18px; height: 18px; color: var(--muted); flex: none; }
