/* Дизайн в стиле дороги-мои.рф: белый воздух, шрифт Unbounded, чёрно-синие
   пилюли, коралловый акцент, крупные скругления. */
:root {
  --ink: #0e0e12; --ink2: #3c3c44; --muted: #7c7c86; --faint: #a6a6b0;
  --page: #f7f7f8; --surface: #ffffff; --surface2: #f4f4f6;
  --line: #ececef; --line2: #f2f2f4;
  --blue: #007eff; --blue-dark: #0067d6; --blue-soft: #e8f2ff;
  --coral: #ff8562; --coral-dark: #f2683f; --coral-soft: #fff0ea;
  --ok: #12a150; --debt: #e5484d;
  --r: 12px; --r-md: 10px; --r-sm: 8px; --pill: 999px;
  /* без теней и свечений: разделяем блоки рамкой и отступами */
  --sh-sm: none; --sh-md: none; --sh-lg: none;
}
* { box-sizing: border-box; }
/* display:flex у .tabs перебивал скрытие через атрибут hidden, и сопровождающий
 * видел админские вкладки. Ставим явное правило. */
[hidden] { display: none !important; }
html, body { min-height: 100%; }
body {
  margin: 0; color: var(--ink); background: var(--page);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 15px; line-height: 1.55; -webkit-font-smoothing: antialiased;
}
h1, h2, .brand-sub, .dir, .stat .n, .detail-head h1, .section-title, .detail-stats .s b, .login-card h1 {
  font-family: "Unbounded", "Inter", sans-serif;
}
.muted { color: var(--muted); }
a { color: var(--blue); text-decoration: none; }
button { font: inherit; cursor: pointer; }
::selection { background: #cfe6ff; }

/* ── topbar ── */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 30px; background: rgba(255,255,255,.86);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-logo { height: 42px; width: auto; display: block; }
.brand-sub { font-size: 12px; color: var(--faint); font-weight: 500; letter-spacing: 1.5px; text-transform: uppercase; align-self: center; padding-left: 12px; border-left: 1px solid var(--line); }
.topbar-right { display: flex; align-items: center; gap: 12px; }
.tabs { display: flex; gap: 4px; margin-right: auto; margin-left: 28px; }
.tabs a { color: var(--ink2); font-weight: 600; padding: 9px 16px; border-radius: var(--r-sm); }
.tabs a:hover { background: var(--surface2); color: var(--ink); }
.tabs a.active { background: var(--ink); color: #fff; }
.head-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ── расписание: шапка и переключатели ── */
.sch-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.sch-head h1 { margin: 0; font-family: "Unbounded", sans-serif; font-weight: 500; font-size: 26px; }
.sch-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-bottom: 8px; }
.sch-month { display: flex; align-items: center; gap: 8px; }
.sch-month-title { font-family: "Unbounded", sans-serif; font-weight: 500; font-size: 16px; min-width: 150px; text-align: center; }
.sch-navbtn { width: 36px; height: 36px; border: 1.5px solid var(--line); background: #fff; border-radius: var(--r-sm); display: grid; place-items: center; color: var(--ink2); }
.sch-navbtn:hover { border-color: var(--ink); color: var(--ink); }
.sch-navbtn svg { width: 16px; height: 16px; }
.seg { display: inline-flex; background: var(--surface2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 3px; }
.seg button { border: none; background: none; padding: 7px 14px; border-radius: 6px; font-weight: 600; font-size: 13.5px; color: var(--muted); }
.seg button:hover { color: var(--ink); }
.seg button.active { background: #fff; color: var(--ink); box-shadow: var(--sh-sm); }
.sch-hint { color: var(--muted); font-size: 13px; margin: 6px 0 16px; }
.sch-warn { background: var(--coral-soft); border: 1px solid #ffd3c4; border-radius: var(--r-sm); padding: 10px 14px; font-size: 13px; color: var(--ink2); margin-bottom: 14px; line-height: 1.6; }
.sch-warn a { color: var(--coral-dark); font-weight: 600; }
.sch-prob { list-style: none; margin: 8px 0 6px; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.sch-prob li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; }
.sch-prob .pn { font-weight: 600; color: var(--ink); min-width: 210px; }
.sch-prob .pw { color: var(--coral-dark); font-weight: 600; }
.sch-prob-tip { display: block; color: var(--muted); font-size: 12.5px; }
.sch-warn summary { cursor: pointer; font-weight: 500; }
.sch-warn summary::marker { color: var(--coral-dark); }
.sch-warn b { color: var(--ink); }
.sch-block { margin-top: 12px; padding-top: 10px; border-top: 1px solid #ffd3c4; }
.sch-block:first-of-type { margin-top: 10px; }
.sch-tip { position: fixed; z-index: 60; pointer-events: none; background: var(--ink); color: #fff; font-size: 12.5px; line-height: 1.45; padding: 8px 11px; border-radius: var(--r-sm); white-space: pre-line; max-width: 300px; box-shadow: var(--sh-md); }

/* ── расписание: лента (таймлайн) ── */
.tl-scroll { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.tl { display: grid; min-width: 900px; position: relative; }
.tl-corner { position: sticky; left: 0; z-index: 3; background: var(--surface); padding: 8px 14px; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; align-items: center; }
.tl-corner-load { text-transform: none; letter-spacing: 0; font-size: 12.5px; color: var(--ink2); }
.tl-day { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 12px; }
.tl-day b { font-size: 13px; color: var(--ink); font-variant-numeric: tabular-nums; }
.tl-day span { font-size: 10.5px; color: var(--faint); }
.tl-day.we span, .tl-day.we b { color: var(--coral-dark); }
.tl-day.today { background: var(--blue); }
.tl-day.today b, .tl-day.today span { color: #fff; }
.tl-load { display: grid; place-items: center; font-size: 12.5px; font-weight: 600; font-variant-numeric: tabular-nums; border-bottom: 1px solid var(--line); border-right: 2px solid var(--surface); cursor: default; }
.tl-load:focus { outline: 2px solid var(--ink); outline-offset: -2px; }
.tl-todaycol { background: rgba(0, 126, 255, .07); pointer-events: none; }
.tl-label { position: sticky; left: 0; z-index: 2; background: var(--surface); padding: 4px 14px; display: flex; flex-direction: column; justify-content: center; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line2); min-width: 0; color: var(--ink); }
.tl-label:hover { background: var(--surface2); }
.tl-dir { font-weight: 600; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tl-meta { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tl-rowbg { border-bottom: 1px solid var(--line2); background-image: linear-gradient(to right, var(--line2) 1px, transparent 1px); pointer-events: none; }
.tl-bar { align-self: center; height: 22px; margin: 0 2px; border-radius: 4px; background: #007eff; color: #fff; font-size: 11.5px; font-weight: 600; display: flex; align-items: center; padding: 0 8px; white-space: nowrap; overflow: hidden; z-index: 1; }
.tl-bar:hover { outline: 2px solid var(--ink); outline-offset: -2px; }
.tl-bar.past { background: #80b5ff; color: var(--ink); }

.tl-bar.cut-l { border-top-left-radius: 0; border-bottom-left-radius: 0; margin-left: 0; }
.tl-bar.cut-r { border-top-right-radius: 0; border-bottom-right-radius: 0; margin-right: 0; }
.sch-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin-top: 12px; font-size: 12.5px; color: var(--muted); }
.lg-item { display: inline-flex; align-items: center; gap: 6px; }
.lg-ramp { display: inline-flex; gap: 2px; }
.lg-ramp i, .lg-sw { display: inline-block; width: 14px; height: 10px; border-radius: 2px; }

/* ── расписание: календарь месяца ── */
.mc { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.mc-wd { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); padding: 0 4px 2px; }
.mc-cell { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); min-height: 104px; padding: 8px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.mc-cell.out { background: transparent; border-color: transparent; }
.mc-cell.today { border: 2px solid var(--blue); padding: 7px; }
.mc-cell.past .mc-num { color: var(--faint); }
.mc-cell:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
.mc-top { display: flex; justify-content: space-between; align-items: center; gap: 4px; margin-bottom: 2px; }
.mc-num { font-weight: 700; font-variant-numeric: tabular-nums; }
.mc-bus { font-size: 11.5px; font-weight: 700; padding: 2px 7px; border-radius: 4px; white-space: nowrap; }
.mc-start { font-size: 12px; color: var(--ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-left: 10px; position: relative; }
.mc-start::before { content: ""; position: absolute; left: 0; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: var(--blue); }
.mc-start:hover { color: var(--blue); }
.mc-more { font-size: 11.5px; color: var(--faint); }

/* ── расписание: график загрузки ── */
.lc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px 20px 14px 46px; }
.lc-title { font-weight: 600; margin: 0 0 16px -26px; }
.lc-plot { position: relative; height: 260px; }
.lc-grid { position: absolute; left: 0; right: 0; height: 0; border-top: 1px solid var(--line2); }
.lc-grid span { position: absolute; left: -32px; top: -8px; width: 24px; text-align: right; font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; }
.lc-cols { position: absolute; inset: 0; display: flex; gap: 2px; align-items: flex-end; }
.lc-col { flex: 1; height: 100%; position: relative; display: flex; align-items: flex-end; justify-content: center; }
.lc-col:hover, .lc-col:focus { background: rgba(14, 14, 18, .04); outline: none; }
.lc-col.today { background: rgba(0, 126, 255, .07); }
.lc-bar { width: 100%; max-width: 24px; background: #007eff; border-radius: 4px 4px 0 0; }
.lc-bar.past { background: #80b5ff; }
.lc-peak { position: absolute; font-size: 12px; font-weight: 700; color: var(--ink); }
.lc-x { display: flex; gap: 2px; margin-top: 6px; border-top: 1px solid var(--line); padding-top: 6px; }
.lc-x span { flex: 1; text-align: center; font-size: 10.5px; color: var(--faint); font-variant-numeric: tabular-nums; }
.lc-x span.today { color: var(--blue); font-weight: 700; }
.lc-table { margin-top: 14px; }
.lc-table summary { cursor: pointer; font-weight: 600; color: var(--ink2); padding: 6px 0; }
.lc-table td { white-space: normal; }

/* ── расписание: список по неделям ── */
.ag-week { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); margin: 18px 0 8px; }
.ag-week:first-child { margin-top: 0; }
.ag-row { display: grid; grid-template-columns: 130px minmax(0, 1fr) 90px 90px 190px; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 12px 16px; margin-bottom: 6px; color: var(--ink); }
.ag-row:hover { border-color: var(--ink); }
.ag-row.past { opacity: .72; }
.ag-date b { display: block; font-variant-numeric: tabular-nums; }
.ag-date span, .ag-num span { font-size: 12px; color: var(--muted); }
.ag-dir { font-weight: 600; }
.ag-cities { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.ag-num b { display: block; font-size: 17px; }

/* ── страница тура ── */
.kicker { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 1.2px; color: var(--faint); margin-bottom: 4px; }
.dep-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.dep-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; display: flex; flex-direction: column; gap: 12px; color: var(--ink); }
.dep-card:hover { border-color: var(--ink); }
.dep-card .top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.dep-card .dir { font-family: "Unbounded", sans-serif; font-weight: 500; font-size: 17px; }

@media (max-width: 820px) {
  .mc { gap: 3px; }
  .mc-cell { min-height: 64px; padding: 5px; }
  .mc-start, .mc-more { display: none; }
  .mc-bus { font-size: 10.5px; padding: 1px 4px; }
  .ag-row { grid-template-columns: 1fr auto; }
  .ag-date { grid-column: 1 / -1; }
  .ag-fill { grid-column: 1 / -1; }
  .lc { padding-left: 38px; }
  .lc-x span:nth-child(even) { visibility: hidden; }
}

/* ── шеринг ── */
.share-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; }
.chk { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink2); cursor: pointer; text-transform: none; letter-spacing: 0; font-weight: 500; }
.chk input { width: 16px; height: 16px; accent-color: var(--blue); margin: 0; }
.share-result { margin-top: 6px; padding: 14px; border-radius: var(--r-md); background: var(--blue-soft); }
.share-result input { font-size: 13px; background: #fff; }
.share-send { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.share-list-title { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); margin: 22px 0 8px; }
.share-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line2); }
.share-item-act { display: flex; gap: 6px; }
.share-item-act svg { width: 15px; height: 15px; }
@media (max-width: 720px) { .tabs { margin-left: 8px; } .tabs a { padding: 8px 10px; } .share-fields { grid-template-columns: 1fr; } }
.btn-ghost { background: var(--ink); border: none; border-radius: var(--pill); padding: 10px 20px; color: #fff; font-weight: 600; transition: transform .1s, background .15s; }
.btn-ghost:hover { background: #26262e; }
.chip-status { font-size: 12px; padding: 7px 13px; border-radius: var(--r-sm); font-weight: 600; }
.chip-status.off { background: var(--coral-soft); color: var(--coral-dark); }
.chip-status.on { background: #e7f7ee; color: var(--ok); }

main { width: 100%; margin: 0 auto; padding: 28px 40px 90px; }
.loader { text-align: center; color: var(--muted); padding: 90px; font-size: 16px; }

/* ── stats ── */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 30px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 24px 26px; box-shadow: var(--sh-sm); min-width: 0; }
.stat .l, .detail-stats .s span { overflow-wrap: anywhere; }
.stat .n { font-size: 32px; font-weight: 600; letter-spacing: -.5px; line-height: 1.05; color: var(--ink); }
.stat .l { font-size: 13.5px; color: var(--muted); margin-top: 10px; }
.stat:nth-child(3) .n { color: var(--blue); }
.stat:nth-child(4) .n { color: var(--coral-dark); }

/* ── panel / filters ── */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--sh-sm); padding: 22px 24px; margin-bottom: 26px; }
.searchbox { position: relative; margin-bottom: 20px; }
.searchbox input {
  width: 100%; font: inherit; font-size: 16px; padding: 14px 18px 14px 50px;
  border: 1.5px solid var(--line); border-radius: var(--r); background: var(--surface2); color: var(--ink);
  transition: border-color .15s, box-shadow .15s, background .15s;
}
.searchbox input::placeholder { color: var(--faint); }
.searchbox input:focus { outline: none; border-color: var(--blue); background: #fff;  }
.searchbox .ic { position: absolute; left: 17px; top: 50%; transform: translateY(-50%); display: flex; color: var(--faint); }
.searchbox .ic svg { width: 19px; height: 19px; }

/* иконки (SVG, без эмодзи) */
svg.i { stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; display: inline-block; vertical-align: -.15em; }

.frow { display: flex; flex-wrap: wrap; gap: 20px 30px; align-items: flex-start; }
.filters-row { display: flex; gap: 32px; align-items: flex-start; }
.filters-left { flex: 0 0 auto; }
.filters-right { flex: 1 1 320px; min-width: 280px; display: flex; flex-direction: column; }
@media (max-width: 820px) { .filters-row { flex-direction: column; gap: 20px; } }
.fgroup { display: flex; flex-direction: column; gap: 11px; min-width: 0; }
.fgroup > .lbl { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 1.4px; color: var(--faint); }
.chips { display: flex; flex-wrap: wrap; gap: 9px; }
.chip {
  border: 1.5px solid var(--line); background: #fff; color: var(--ink2);
  padding: 8px 14px; border-radius: var(--r-sm); font-size: 13.5px; font-weight: 500;
  transition: all .13s ease; white-space: nowrap;
}
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip.all.active { background: var(--blue); border-color: var(--blue); }

.linkbtn { background: none; border: none; color: var(--blue); font-weight: 600; font-size: 13px; padding: 4px 2px; }
.linkbtn:hover { text-decoration: underline; }

/* ── встроенный календарь ── */
.cal { border: 1.5px solid var(--line); border-radius: var(--r); padding: 14px 16px; background: var(--surface2); display: inline-block; }
.cal-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.cal-title { font-weight: 600; font-size: 14px; flex: 1; }
.cal-nav { display: flex; gap: 6px; }
.cal-nav button { width: 28px; height: 28px; border: 1.5px solid var(--line); background: #fff; border-radius: var(--r-sm); display: grid; place-items: center; color: var(--ink2); }
.cal-nav button:hover { border-color: var(--ink); color: var(--ink); }
.cal-nav button svg { width: 15px; height: 15px; }
.cal-months { display: flex; gap: 26px; }
.cal-wds, .cal-grid { display: grid; grid-template-columns: repeat(7, 30px); gap: 3px; }
.cal-wd { font-size: 10.5px; color: var(--faint); text-align: center; font-weight: 600; padding-bottom: 4px; }
.cal-day { height: 30px; display: grid; place-items: center; font-size: 12.5px; border-radius: var(--r-sm); cursor: pointer; color: var(--ink2); user-select: none; font-variant-numeric: tabular-nums; }
.cal-day:hover { background: #e9edf2; }
.cal-day.out { color: transparent; cursor: default; }
.cal-day.out:hover { background: none; }
.cal-day.inrange { background: var(--blue-soft); color: var(--blue-dark); border-radius: 0; }
.cal-day.sel { background: var(--blue); color: #fff; font-weight: 700; }
.cal-day.sel.start { border-radius: var(--r-sm) 0 0 var(--r-sm); }
.cal-day.sel.end { border-radius: 0 var(--r-sm) var(--r-sm) 0; }
.cal-day.sel.one { border-radius: var(--r-sm); }
.cal-month.second { display: none; }
@media (min-width: 640px) { .cal-month.second { display: block; } }
.result-count { color: var(--muted); font-size: 13.5px; margin: 2px 0 16px; }

/* ── people search ── */
.people { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px,1fr)); gap: 12px; margin-bottom: 30px; }
.person { display: flex; justify-content: space-between; gap: 12px; align-items: center;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-sm); padding: 13px 16px; cursor: pointer; transition: border-color .12s; }
.person:hover { border-color: var(--ink); }
.person .nm { font-weight: 600; }
.person .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.person .to { font-size: 12px; color: var(--blue); font-weight: 600; text-align: right; white-space: nowrap; }

/* ── reis grid ── */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }
.reis {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: 22px 22px 20px; box-shadow: var(--sh-sm); cursor: pointer;
  transition: transform .12s ease, box-shadow .18s ease, border-color .15s;
  display: flex; flex-direction: column; gap: 14px;
}
.reis:hover { border-color: var(--ink); }
.reis .top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.reis .dir { font-weight: 500; font-size: 19px; letter-spacing: -.3px; line-height: 1.15; }
.reis .pill-city { font-size: 12px; font-weight: 600; color: var(--blue); background: var(--blue-soft); border-radius: var(--pill); padding: 5px 12px; white-space: nowrap; }
.reis .meta { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.mtag { font-size: 13px; color: var(--muted); font-weight: 500; display: inline-flex; align-items: center; gap: 5px; }
.mtag.wish { color: var(--coral-dark); font-weight: 600; }
.mtag svg { width: 15px; height: 15px; }
.btn svg { width: 17px; height: 17px; }
.back svg { width: 16px; height: 16px; }

.fill { display: flex; align-items: center; gap: 13px; margin-top: 2px; }
.fill-bar { flex: 1; height: 8px; background: #eeeef1; border-radius: var(--pill); overflow: hidden; }
.fill-bar > i { display: block; height: 100%; border-radius: var(--pill); transition: width .3s ease; }
.fill-num { font-size: 13.5px; font-weight: 700; white-space: nowrap; color: var(--ink); font-variant-numeric: tabular-nums; }
.g, .b { background: var(--blue); }
.a { background: var(--coral); }
.r { background: var(--coral-dark); }

.reis.past { opacity: .72; }
.reis.past:hover { opacity: 1; }
.mtag.past-tag { color: var(--faint); background: var(--surface2); border-radius: var(--pill); padding: 2px 9px; font-size: 12px; font-weight: 600; }

/* ── «показать ещё» ── */
.pager { display: flex; justify-content: center; margin-top: 30px; }
.show-more { background: #fff; border: 1.5px solid var(--line); color: var(--ink); border-radius: var(--pill); padding: 13px 28px; font-weight: 600; font-size: 15px; transition: all .13s; }
.show-more:hover { border-color: var(--ink); box-shadow: var(--sh-md); }
.show-more span { color: var(--faint); font-weight: 500; }

/* ── detail ── */
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); margin-bottom: 18px; font-weight: 500; }
.back:hover { color: var(--ink); }
.detail-hero { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--sh-sm); padding: 28px 30px; margin-bottom: 22px; }
.detail-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.detail-head h1 { margin: 0; font-size: 30px; font-weight: 500; letter-spacing: -.5px; }
.detail-head .sub { color: var(--muted); margin-top: 8px; }
.btn { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; background: var(--ink); color: #fff; border: none; border-radius: var(--pill); padding: 13px 22px; font-weight: 600; transition: transform .1s, background .15s; }
.btn:hover { background: #26262e; }
.btn-x { background: var(--blue); }
.btn-x:hover { background: var(--blue-dark); }
.btn-pdf { background: #c0392b; }
.btn-pdf:hover { background: #a93226; }
.btn-icon { width: 34px; height: 34px; border: 1.5px solid var(--line); background: #fff; border-radius: var(--r-sm); display: grid; place-items: center; color: var(--muted); flex: 0 0 auto; }
.btn-icon:hover { border-color: var(--ink); color: var(--ink); }
.btn-icon svg { width: 17px; height: 17px; }

/* публичная ссылка в карточке выезда */
.pub-link { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line2); }
.pl-label { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); }
.pub-link input { flex: 1; min-width: 220px; font: inherit; font-size: 13px; padding: 9px 12px; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface2); color: var(--ink2); }
.pl-exp { font-size: 12.5px; color: var(--muted); }
.help-box { margin-top: 10px; background: var(--blue-soft); border-radius: var(--r-sm); padding: 12px 14px; font-size: 13px; line-height: 1.6; color: var(--ink2); }
.detail-stats .s.s-warn { background: var(--coral-soft); border-color: #ffd3c4; }
.detail-stats .s.s-warn b { color: var(--coral-dark); }

.detail-stats { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 22px; }
.detail-stats .s { background: var(--surface2); border: 1px solid var(--line2); border-radius: var(--r-md); padding: 14px 20px; min-width: 100px; }
.detail-stats .s b { display: block; font-size: 24px; font-weight: 600; letter-spacing: -.5px; }
.detail-stats .s span { font-size: 12.5px; color: var(--muted); }

.table-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--sh-sm); overflow-x: auto; }
table { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 14px; }
th, td { padding: 13px 16px; text-align: left; border-bottom: 1px solid var(--line2); white-space: nowrap; }
th { background: #fbfbfc; font-size: 11px; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); font-weight: 600; position: sticky; top: 0; z-index: 1; }
tbody tr { transition: background .1s; }
tbody tr:hover { background: #fafafb; }
tbody tr:last-child td { border-bottom: none; }
td.num { color: var(--faint); text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; }
td.fio { font-weight: 600; }
td.money { text-align: right; font-variant-numeric: tabular-nums; }
tr.head-row td { border-top: 2px solid var(--line); }
tr.seatwish { background: var(--coral-soft); }
tr.seatwish:hover { background: #ffe8de; }
.badge-seat { background: var(--coral); color: #fff; border-radius: var(--pill); padding: 2px 9px; font-size: 11px; font-weight: 600; margin-right: 5px; }
.badge-ta { background: var(--blue-soft); color: var(--blue-dark); border-radius: var(--pill); padding: 2px 9px; font-size: 11px; font-weight: 600; margin-right: 5px; }
.badge-crm { background: var(--blue-soft); color: var(--blue-dark); border-radius: 5px; padding: 1px 6px; font-size: 10.5px; font-weight: 700; margin-left: 6px; letter-spacing: .3px; }
.badge-pick { background: #fff3e8; color: #b5580f; border-radius: 5px; padding: 2px 8px; font-size: 12px; font-weight: 600; }
/* турист добавлен вручную (турагентство) и оплата, поправленная в пульте */
.badge-ag { background: var(--surface2); color: var(--ink2); border: 1px solid var(--line); border-radius: 5px; padding: 0 6px; font-size: 10.5px; font-weight: 600; margin-left: 6px; }
.badge-hand { background: var(--surface2); color: var(--ink2); border: 1px solid var(--line); border-radius: 5px; padding: 0 6px; font-size: 10.5px; font-weight: 600; margin-right: 6px; }
tr.editable { cursor: pointer; }
.pax-pick { font-size: 13px; color: #b5580f; font-weight: 600; margin-top: 3px; display: flex; align-items: center; gap: 5px; }
.pax-pick svg { width: 14px; height: 14px; }
.paid { color: var(--ok); font-weight: 600; }
.debt { color: var(--debt); font-weight: 600; }

/* ── автобусы в карточке рейса ── */
.buses { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.bus { background: var(--surface2); border: 1px solid var(--line2); border-radius: var(--r-md); padding: 12px 16px; min-width: 190px; }
.bus .bh { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 8px; }
.bus .bn { font-weight: 600; }
.bus .bc { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.bus .fill-bar { height: 7px; }
.bus-add { border: 1.5px dashed var(--line); background: #fff; border-radius: var(--r-md); padding: 12px 16px; min-width: 150px; color: var(--blue); font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 6px; }
.bus-add:hover { border-color: var(--blue); background: var(--blue-soft); }

/* ── кнопки-действия ── */
.btn-sm { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; background: #fff; border: 1.5px solid var(--line); color: var(--ink2); border-radius: var(--r-sm); padding: 8px 14px; font-weight: 600; font-size: 13.5px; }
.btn-sm:hover { border-color: var(--ink); color: var(--ink); }
.btn-sm.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-sm.primary:hover { background: var(--blue-dark); }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 2px 0 16px; flex-wrap: wrap; }

/* ── модалка ── */
.modal-bg { position: fixed; inset: 0; background: rgba(15,15,25,.45); display: flex; align-items: center; justify-content: center; z-index: 50; padding: 20px; }
.modal { background: #fff; border-radius: var(--r); box-shadow: var(--sh-lg); width: 440px; max-width: 100%; max-height: 90vh; overflow-y: auto; padding: 26px 28px; }
.modal h2 { margin: 0 0 18px; font-size: 20px; font-weight: 500; }
.modal .fld { margin-bottom: 14px; }
.modal .fld > label { display: block; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); margin-bottom: 6px; }
.modal input, .modal select, .modal textarea { width: 100%; font: inherit; padding: 11px 14px; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface2); }
.modal textarea { resize: vertical; min-height: 64px; }
.modal input:focus, .modal select:focus, .modal textarea:focus { outline: none; border-color: var(--blue);  }
.modal input.invalid { border-color: var(--red); }
.modal .fld-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.modal .modal-lead { font-size: 13px; margin: -8px 0 16px; line-height: 1.5; }
.modal .check-row { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; line-height: 1.45; margin-bottom: 16px; cursor: pointer; }
.modal .check-row input { width: 18px; height: 18px; flex: 0 0 18px; margin: 2px 0 0; padding: 0; accent-color: var(--blue); }
.modal .check-row .muted { font-size: 12.5px; }
.modal-actions .spacer { flex: 1; }
.btn-sm.danger { color: var(--debt); }
.btn-sm.danger:hover { border-color: var(--debt); color: var(--debt); }
@media (max-width: 420px) { .modal .fld-row { grid-template-columns: 1fr; } }
.bus-edit { display: flex; gap: 8px; margin-bottom: 8px; align-items: center; }
.bus-edit input.bname { flex: 1; }
.bus-edit input.bcap { width: 84px; }
.bus-edit .del { border: none; background: none; color: var(--red); font-size: 18px; cursor: pointer; padding: 0 4px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }

/* ── сопровождающий в карточке рейса (админ) ── */
/* отменённые туристы выезда */
.cancel-list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); }
.cancel-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 12px 16px; border-bottom: 1px solid var(--line2); }
.cancel-row:last-child { border-bottom: none; }
.cancel-main { min-width: 0; flex: 1 1 260px; }
.cancel-name { font-weight: 600; color: var(--ink2); text-decoration: line-through; text-decoration-color: var(--faint); }
.cancel-name .badge-crm, .cancel-name .badge-ag { text-decoration: none; display: inline-block; }
.cancel-sub { font-size: 13px; color: var(--muted); margin-top: 2px; overflow-wrap: anywhere; }
.cancel-act { display: flex; gap: 8px; flex-wrap: wrap; }
.cancel-note { font-size: 12.5px; margin: 10px 0 0; }
/* общий автобус на все города тура */
.shared-box { margin-top: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 16px; }
.shared-cities { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.shared-city { font-size: 13px; font-weight: 600; color: var(--blue-dark); background: var(--blue-soft); border-radius: var(--r-sm); padding: 5px 10px; }
.shared-city.cur { background: var(--ink); color: #fff; }
.shared-note { font-size: 12.5px; margin: 10px 0 0; }
.escort-box { margin-top: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 18px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.escort-box .e-name { font-weight: 600; }
.escort-box .e-code { margin-left: auto; font-size: 13px; color: var(--muted); background: var(--blue-soft); padding: 4px 10px; border-radius: var(--r-sm); }
.escort-box .e-code b { color: var(--blue-dark); letter-spacing: 1px; }

/* ── экран «Сопровождающие» (админ) ── */
.esc-admin { display: flex; flex-direction: column; gap: 10px; }
.esc-row { display: grid; grid-template-columns: minmax(0,1.4fr) auto minmax(0,1.6fr) auto; align-items: center; gap: 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; box-shadow: var(--sh-sm); }
.esc-nm { font-weight: 600; font-size: 16px; }
.esc-sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.esc-code { display: flex; align-items: center; gap: 8px; background: var(--surface2); border-radius: var(--r-sm); padding: 8px 12px; }
.esc-code span { font-size: 11px; text-transform: uppercase; letter-spacing: .6px; color: var(--faint); }
.esc-code b { font-family: ui-monospace, Menlo, monospace; font-size: 15px; letter-spacing: 1px; color: var(--blue-dark); }
.esc-trips { display: flex; flex-wrap: wrap; gap: 6px; font-size: 13px; }
.esc-trips a { background: var(--blue-soft); color: var(--blue-dark); border-radius: var(--r-sm); padding: 4px 10px; font-weight: 500; }
.esc-act { display: flex; gap: 8px; }
@media (max-width: 900px) { .esc-row { grid-template-columns: 1fr; gap: 10px; } }

/* ── экран сопровождающего (mobile-first) ── */
.esc-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.esc-head h1 { margin: 0; font-family: "Unbounded", sans-serif; font-weight: 500; font-size: 24px; }
.esc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.esc-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; box-shadow: var(--sh-sm); display: flex; flex-direction: column; gap: 12px; cursor: pointer; }

.esc-card.past { opacity: .7; }
.esc-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.esc-dir { font-family: "Unbounded", sans-serif; font-weight: 500; font-size: 18px; }

.esc-hero { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; margin-bottom: 20px; }
.esc-hero h1 { margin: 0; font-family: "Unbounded", sans-serif; font-weight: 500; font-size: 24px; }
.esc-hero .sub { color: var(--muted); margin-top: 6px; }
.esc-hero-stats { margin-top: 14px; font-size: 15px; color: var(--ink2); }
.esc-hero-stats b { font-family: "Unbounded", sans-serif; font-size: 22px; color: var(--blue); }

.pax-list { display: flex; flex-direction: column; gap: 8px; }
.pax { display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: 12px 12px 12px 14px; transition: background .15s, border-color .15s; }
.pax.present { background: #eefaf3; border-color: #bfe9d0; }
.pax-seat { flex: 0 0 34px; height: 34px; border-radius: var(--r-sm); background: var(--surface2); display: grid; place-items: center; font-weight: 700; color: var(--ink2); font-variant-numeric: tabular-nums; }
.pax.present .pax-seat { background: var(--ok); color: #fff; }
.pax-info { flex: 1; min-width: 0; }
.pax-name { font-weight: 600; line-height: 1.3; }
.pax-cmt { font-size: 13px; color: var(--muted); margin-top: 3px; }
.pax-cmt.wish { color: var(--coral-dark); font-weight: 600; }
.pax-cmt svg { width: 14px; height: 14px; }
.pax-act { display: flex; gap: 8px; flex: 0 0 auto; }
.pax-call, .pax-check { width: 44px; height: 44px; border-radius: var(--r-sm); display: grid; place-items: center; border: 1.5px solid var(--line); background: #fff; }
.pax-call { color: var(--blue); }
.pax-call svg, .pax-check svg { width: 20px; height: 20px; }
.pax-check { color: #d3d3da; }
.pax.present .pax-check { background: var(--ok); border-color: var(--ok); color: #fff; }

@media (max-width: 720px) {
  .esc-grid { grid-template-columns: 1fr; }
  .escort-box .e-code { margin-left: 0; }
}

/* ── список пассажиров карточками (узкий экран) ── */
.pax-cards { display: flex; flex-direction: column; gap: 8px; }
.pcard { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm); overflow: hidden; }
.pcard-mark { display: block; margin-top: 3px; font-size: 12px; font-weight: 600; color: var(--coral-dark); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* В раскрытой карточке пожелание видно в поле «Комментарий» — в шапке не дублируем. */
.pcard.open .pcard-mark { display: none; }
.pcard.open { border-color: var(--ink); }
.pcard-head { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px 14px; background: none; border: none; text-align: left; }
.pcard-seat { flex: 0 0 32px; height: 32px; border-radius: var(--r-sm); background: var(--surface2); display: grid; place-items: center; font-weight: 700; font-size: 13px; color: var(--ink2); font-variant-numeric: tabular-nums; }
.pcard.open .pcard-seat { background: var(--blue); color: #fff; }
.pcard-main { flex: 1; min-width: 0; }
.pcard-name { display: block; font-weight: 600; font-size: 15px; line-height: 1.3; }
.pcard-sub { display: block; font-size: 12.5px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pcard-right { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; font-size: 12.5px; white-space: nowrap; }
.pcard-right .chev { width: 18px; height: 18px; color: var(--faint); transition: transform .15s ease; }
.pcard.open .pcard-right .chev { transform: rotate(180deg); }
.pcard-body { padding: 2px 14px 12px 58px; border-top: 1px solid var(--line2); }
.pf { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; padding: 8px 0; border-bottom: 1px solid var(--line2); font-size: 14px; }
.pf:last-child { border-bottom: none; }
.pf-actions { display: flex; justify-content: flex-end; padding: 10px 0 2px; }
.pf > span { color: var(--muted); font-size: 13px; flex: 0 0 auto; }
.pf > div { text-align: right; min-width: 0; overflow-wrap: anywhere; }

@media (max-width: 900px) {
  .detail-hero { padding: 18px 16px; }
  .detail-head h1 { font-size: 22px; }
  .head-actions { width: 100%; }
  .head-actions .btn { flex: 1; justify-content: center; padding: 12px 10px; }
  .detail-stats { gap: 8px; }
  .detail-stats .s { flex: 1 1 calc(50% - 8px); min-width: 0; padding: 12px 14px; }
  .detail-stats .s b { font-size: 20px; }
  .pub-link { gap: 8px; }
  .pl-label { order: 0; width: 100%; }
  .pub-link input { order: 1; flex: 1 0 100%; min-width: 0; }
  .pub-link .btn-sm { order: 2; }
  .pub-link .btn-icon { order: 3; }
  .pl-exp { order: 4; margin-left: auto; }
  .pcard-body { padding-left: 14px; }
  .toolbar { gap: 8px; }
}
@media (max-width: 420px) {
  .pcard-head { padding: 11px 12px; gap: 10px; }
  .pcard-name { font-size: 14.5px; }
  .pf { font-size: 13.5px; }
  /* на узких телефонах (320 px) плитки и переключатели месяца не помещались */
  .stats { gap: 12px; }
  .stat { padding: 16px 14px; }
  .stat .n { font-size: 26px; }
  .sch-month { flex-wrap: wrap; justify-content: center; }
  .sch-month-title { min-width: 108px; font-size: 15px; }
  .seg button { padding: 7px 9px; font-size: 12.5px; }
}

.empty-note { text-align: center; color: var(--muted); padding: 56px; }
.section-title { font-size: 13px; font-weight: 500; text-transform: uppercase; letter-spacing: 1px; color: var(--ink2); margin: 6px 0 14px; }

/* ── login ── */
.login-body { display: flex; min-height: 100vh; align-items: center; justify-content: center; padding: 20px; background: var(--page); }
.login-card { background: var(--surface); border: 1px solid var(--line); border-radius: 28px; box-shadow: var(--sh-lg); padding: 44px 38px; width: 360px; text-align: center; display: flex; flex-direction: column; gap: 14px; }
.login-logo { height: 72px; width: auto; margin: 0 auto 4px; }
.login-card h1 { margin: 0; font-size: 24px; font-weight: 500; letter-spacing: -.3px; }
.login-card p { margin: -4px 0 8px; }
.login-card input { font: inherit; padding: 14px 18px; border: 1.5px solid var(--line); border-radius: var(--pill); background: var(--surface2); }
.login-card input:focus { outline: none; border-color: var(--blue);  }
.login-card button { background: var(--ink); color: #fff; border: none; border-radius: var(--pill); padding: 14px; font-weight: 600; font-size: 15px; transition: background .15s; }
.login-card button:hover { background: #26262e; }
.login-err { color: var(--debt); font-size: 14px; font-weight: 600; }

@media (max-width: 720px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  main { padding: 20px 15px 60px; }
  .brand-sub { display: none; }
  /* На телефоне шапка в одну строку не влезает и страница едет вбок.
   * Разносим: логотип и правый блок — первая строка, вкладки — вторая. */
  /* blur на телефонах даёт артефакты перерисовки — делаем шапку простой белой */
  .topbar { padding: 10px 14px; flex-wrap: wrap; row-gap: 8px; column-gap: 10px;
            background: #fff; backdrop-filter: none; }
  .brand-logo { height: 34px; }
  .topbar-right { gap: 8px; }
  .chip-status { white-space: nowrap; padding: 6px 10px; font-size: 11.5px; }
  .btn-ghost { padding: 8px 14px; font-size: 13.5px; }
  /* Длинные заголовки («Сопровождающие») вместе с кнопкой не помещались в строку */
  .sch-head h1, .esc-head h1, .esc-hero h1 { font-size: 21px; overflow-wrap: anywhere; }
  .detail-head h1 { overflow-wrap: anywhere; }
  .tabs { order: 3; width: 100%; margin: 0; gap: 4px; }
  .tabs { justify-content: space-between; }
  .tabs a { flex: 0 1 auto; text-align: center; padding: 8px 8px; font-size: 13px; }
}
@media (max-width: 380px) {
  .tabs { gap: 0; }
  .tabs a { font-size: 11.5px; padding: 8px 4px; letter-spacing: -.1px; }
  .chip-status { font-size: 11px; padding: 6px 8px; }
}

/* ── отчёты ── */
.rep-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.rep-dates { display: flex; align-items: center; gap: 8px; }
.rep-dates input { font: inherit; font-size: 14px; padding: 8px 10px; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface2); color: var(--ink); min-width: 0; }
.rep-dates input:focus { outline: none; border-color: var(--blue); }
.rep-presets { margin-top: 14px; }
.rep-table td { vertical-align: middle; }
.rep-name { font-weight: 600; }
.rep-bar { height: 4px; background: var(--surface2); border-radius: 2px; margin-top: 6px; min-width: 120px; }
.rep-bar i { display: block; height: 100%; background: var(--blue); border-radius: 2px; }
.rep-table tfoot td { font-weight: 700; background: #fbfbfc; border-bottom: none; }
.rep-hint { margin-top: 18px; }
@media (max-width: 720px) {
  .rep-dates { width: 100%; }
  .rep-dates input { flex: 1; }
  .rep-table th, .rep-table td { padding: 11px 10px; }
  .rep-bar { min-width: 70px; }
}
.rep-table th.money { text-align: right; }
@media (max-width: 720px) {
  .rep-table table { font-size: 13px; }
  .rep-table th { font-size: 10px; letter-spacing: .3px; }
  .rep-table td:first-child { white-space: normal; }
  .rep-table th, .rep-table td { padding: 10px 8px; }
  .rep-table th:first-child, .rep-table td:first-child { padding-left: 12px; }
  .rep-bar { min-width: 0; }
}
@media (max-width: 380px) {
  .rep-table table { font-size: 12px; }
  .rep-table th { letter-spacing: 0; }
  .rep-table th, .rep-table td { padding: 9px 5px; }
  .rep-table th:first-child, .rep-table td:first-child { padding-left: 10px; }
}
@media (max-width: 380px) {
  .rep-dates { gap: 4px; }
  .rep-dates input { font-size: 12.5px; padding: 8px 4px; }
}
.zero { color: var(--muted); font-weight: 600; }
/* ── отчёты: переключатель и сводка по турам ── */
.rep-views { margin-bottom: 18px; }
.rep-months { margin-bottom: 8px; }
.rep-month { margin-top: 22px; }
.rep-sum td:first-child { white-space: normal; }
.rep-sum tr.rep-empty td { color: var(--muted); }
.rep-lines { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); }
.rep-line { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px; padding: 10px 14px; border-bottom: 1px solid var(--line2); font-size: 14px; }
.rep-line:last-child { border-bottom: none; }
.rep-line-n { color: var(--ink2); font-variant-numeric: tabular-nums; }
.rep-line.rep-empty { color: var(--muted); }
@media (max-width: 720px) { .rep-views { display: flex; } .rep-views button { flex: 1; padding: 7px 6px; } }
/* сделка названа одним направлением, а записана в другое — повод проверить */
.badge-check { background: var(--coral-soft); color: var(--coral-dark); border-radius: 5px; padding: 1px 7px; font-size: 10.5px; font-weight: 700; margin-left: 6px; letter-spacing: .2px; cursor: help; }
