/* EURO-TOUR B2B
   Layout: рабочий кабинет — узкая шапка, широкая рабочая область, таблицы как «табло вылетов».
   Цвета взяты из логотипа: синий EURO TOUR, солнечный жёлтый, голубой глобус.
   Чтобы сменить фирменные цвета — поменяйте токены ниже. */
:root {
  --brand: #2045a1;        /* синий логотипа */
  --brand-ink: #16337a;
  --sun: #fcc900;          /* солнце */
  --sky: #52b3d0;          /* глобус */
  --bg: #f3f5fa;
  --surface: #ffffff;
  --surface-2: #eef1f8;
  --fg: #141b2d;
  --muted: #5d6680;
  --line: #dde2ee;
  --on-brand: #ffffff;
  --panel: #2045a1;
  --ok: #138a5a; --ok-bg: #e2f5ec;
  --warn: #9a6b00; --warn-bg: #fff4cc;
  --bad: #c0352b; --bad-bg: #fde8e6;
  --info: #1d63c4; --info-bg: #e3edfc;
  --off: #6b7286; --off-bg: #eceef3;
  --shadow: 0 1px 2px rgba(20, 30, 70, .06), 0 4px 16px rgba(20, 30, 70, .05);
  --f-display: "Unbounded", "Onest", system-ui, sans-serif;
  --f-body: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --r: 10px; --r-sm: 7px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #5b82e6; --brand-ink: #8fa9f0; --sun: #ffd23a; --sky: #6cc6e2;
    --bg: #0d1325; --surface: #151d36; --surface-2: #1c2645; --fg: #e8ecf6; --muted: #9aa5c2; --line: #2a3557; --on-brand: #ffffff; --panel: #1a3580;
    --ok: #4fd39a; --ok-bg: #123527; --warn: #f1c34b; --warn-bg: #3a2f0e; --bad: #ff8a7f; --bad-bg: #3d1b1a;
    --info: #85b2ff; --info-bg: #182c52; --off: #a0a7b9; --off-bg: #262d42;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --brand: #5b82e6; --brand-ink: #8fa9f0; --sun: #ffd23a; --sky: #6cc6e2;
  --bg: #0d1325; --surface: #151d36; --surface-2: #1c2645; --fg: #e8ecf6; --muted: #9aa5c2; --line: #2a3557; --on-brand: #ffffff; --panel: #1a3580;
  --ok: #4fd39a; --ok-bg: #123527; --warn: #f1c34b; --warn-bg: #3a2f0e; --bad: #ff8a7f; --bad-bg: #3d1b1a;
  --info: #85b2ff; --info-bg: #182c52; --off: #a0a7b9; --off-bg: #262d42;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 15px/1.5 var(--f-body); min-height: 100vh; display: flex; flex-direction: column; }
#app { flex: 1; display: flex; flex-direction: column; }
[hidden] { display: none !important; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0; line-height: 1.2; text-wrap: balance; }
h1 { font: 600 clamp(22px, 2.6vw, 30px)/1.2 var(--f-display); letter-spacing: -.01em; }
h2 { font-size: 17px; font-weight: 650; }
h3 { font-size: 14px; font-weight: 650; }
p { margin: 0; }
img { max-width: 100%; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.block { display: block; }
.nowrap { white-space: nowrap; }
.mono { font-family: var(--f-mono); font-size: .92em; letter-spacing: .01em; }
.num { font-variant-numeric: tabular-nums; }
.r { text-align: right; }

.wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.main { padding-block: 24px 48px; display: flex; flex-direction: column; gap: 18px; flex: 1; }
.main:not(.wide) { max-width: 980px; }

/* ---------- шапка ---------- */
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 30; background: var(--surface); }
.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--surface); border-bottom: 1px solid var(--line); }
.top-in { display: flex; align-items: center; gap: 20px; min-height: 64px; flex-wrap: wrap; padding-block: 6px; }
.logo { display: flex; align-items: center; gap: 8px; text-decoration: none !important; }
.logo img { height: 46px; width: auto; display: block; }
.logo .logo-d { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .logo .logo-l { display: none; } :root:not([data-theme="light"]) .logo .logo-d { display: block; } }
:root[data-theme="dark"] .logo .logo-l { display: none; }
:root[data-theme="dark"] .logo .logo-d { display: block; }
.logo-b2b { font: 700 11px/1 var(--f-mono); letter-spacing: .12em; color: var(--brand); border: 1.5px solid var(--brand); border-radius: 5px; padding: 4px 5px 3px; }
.nav { display: flex; gap: 2px; flex: 1; flex-wrap: wrap; min-width: 0; }
.nav a { color: var(--muted); font-weight: 550; padding: 8px 12px; border-radius: 8px; text-decoration: none; }
.nav a:hover { background: var(--surface-2); color: var(--fg); }
.nav a.on { color: var(--brand); background: var(--surface-2); box-shadow: inset 0 -2px 0 var(--sun); }
.top-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-left: auto; }
.cur-sel select { font: 600 13px var(--f-mono); padding: 6px 8px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); }
.langs { display: flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.langs button { font: 600 12px var(--f-mono); padding: 7px 9px; border: 0; background: transparent; color: var(--muted); cursor: pointer; }
.langs button.on { background: var(--brand); color: var(--on-brand); }
.who { font-size: 13px; font-weight: 600; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- кнопки и поля ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: 600 14px/1 var(--f-body); padding: 11px 18px; border-radius: 9px; border: 1px solid transparent; cursor: pointer; text-decoration: none !important; white-space: nowrap; transition: background .15s, border-color .15s; }
.btn.sm { padding: 7px 12px; font-size: 13px; }
.btn.block { width: 100%; }
.btn.primary { background: var(--brand); color: var(--on-brand); }
.btn.primary:hover { background: var(--brand-ink); }
.btn.ghost { background: var(--surface); color: var(--fg); border-color: var(--line); }
.btn.ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn.danger { background: var(--bad); color: #fff; }
.btn.danger-ghost { background: transparent; color: var(--bad); border-color: color-mix(in srgb, var(--bad) 40%, transparent); }
.btn.danger-ghost:hover { background: var(--bad-bg); }
.btn:disabled { opacity: .55; cursor: progress; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; }

.fld { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.fld > span { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.req { color: var(--bad); font-weight: 700; }
input, select, textarea { font: 15px/1.3 var(--f-body); color: var(--fg); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px 11px; width: 100%; min-width: 0; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 18%, transparent); }
input.bad { border-color: var(--bad); background: var(--bad-bg); }
input[type=file] { padding: 8px; font-size: 13px; }
.fld.file small { color: var(--muted); font-size: 12px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; cursor: pointer; }
.check input { width: 18px; height: 18px; margin-top: 2px; flex: none; accent-color: var(--brand); }
.form-err { color: var(--bad); background: var(--bad-bg); padding: 9px 12px; border-radius: var(--r-sm); font-size: 14px; font-weight: 550; }
.hint { font: 12px var(--f-mono); color: var(--muted); text-align: center; }
.grid { display: grid; gap: 14px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.s2 { grid-column: span 2; } .s3 { grid-column: span 3; }
.form-actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }

/* ---------- карточки и общие блоки ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.card.flush { padding: 0; gap: 0; }
.pad { padding: 16px 20px; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.back { font-size: 14px; font-weight: 600; color: var(--muted); align-self: flex-start; }
.lead { color: var(--muted); max-width: 62ch; }
.empty { color: var(--muted); padding: 28px 20px; text-align: center; }
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.kv { display: grid; grid-template-columns: minmax(120px, 38%) minmax(0, 1fr); gap: 8px 14px; margin: 0; }
.kv dt { color: var(--muted); font-size: 13px; }
.kv dd { margin: 0; font-weight: 550; overflow-wrap: anywhere; }
.big-num { font: 600 22px var(--f-display); color: var(--brand); }
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; padding: 4px 9px 4px 8px; border-radius: 99px; white-space: nowrap; }
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.st-new { color: var(--info); background: var(--info-bg); }
.st-confirmed { color: var(--brand-ink); background: color-mix(in srgb, var(--sky) 24%, var(--surface)); }
.st-paid, .st-approved { color: var(--ok); background: var(--ok-bg); }
.st-cancelled { color: var(--off); background: var(--off-bg); }
.st-rejected, .st-blocked { color: var(--bad); background: var(--bad-bg); }
.st-pending { color: var(--warn); background: var(--warn-bg); }
.tag { align-self: flex-start; display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 3px 7px; border-radius: 5px; background: var(--surface-2); color: var(--brand); }
.tag.ty-inbound { background: color-mix(in srgb, var(--sun) 30%, var(--surface)); color: var(--fg); }
.tag.ty-excursion { background: color-mix(in srgb, var(--sky) 22%, var(--surface)); color: var(--fg); }
.tag.ty-ground { background: var(--off-bg); color: var(--fg); }
.ok-tag { color: var(--ok); font-weight: 650; font-size: 13px; }
.confirm-inline { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 6px 8px 6px 12px; border-radius: 9px; background: var(--bad-bg); font-size: 14px; font-weight: 550; }

/* ---------- таблицы ---------- */
.tbl-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--surface-2); white-space: nowrap; }
.tbl th.r { text-align: right; }
.tbl td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl.clickable tbody tr[data-href] { cursor: pointer; }
.tbl.clickable tbody tr[data-href]:hover { background: var(--surface-2); }
.tbl .clip { max-width: 320px; }
.tbl tr.dim { opacity: .55; }
.board td:first-child b { font-family: var(--f-mono); font-weight: 600; }
.board .nn { display: inline-block; margin-left: 8px; font: 600 11px var(--f-mono); color: var(--brand); background: var(--surface-2); border-radius: 4px; padding: 2px 5px; }
.orig { display: block; font-size: 11.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.seats { display: flex; align-items: center; gap: 8px; min-width: 110px; }
.seats-bar { flex: 1; height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; min-width: 50px; }
.seats-bar i { display: block; height: 100%; background: var(--sky); border-radius: 3px; }
.seats.low .seats-bar i { background: var(--sun); }
.seats.full .seats-bar i { background: var(--bad); }
.seats .num { font: 600 13px var(--f-mono); white-space: nowrap; }
.seats small { color: var(--muted); font-weight: 400; }
.w-seats { width: 160px; }

/* ---------- вход и регистрация ---------- */
.auth { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 0; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); background: var(--surface); margin-top: 12px; }
.auth-brand { background: var(--panel); color: #fff; padding: 40px; display: flex; flex-direction: column; gap: 18px; position: relative; overflow: hidden; }
.auth-brand::after { content: ""; position: absolute; right: -90px; bottom: -90px; width: 260px; height: 260px; border-radius: 50%; border: 22px solid var(--sun); opacity: .9; }
.auth-logo { width: 170px; }
.auth-brand h1 { color: #fff; max-width: 18ch; }
.auth-brand p { opacity: .88; max-width: 46ch; }
.auth-points { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; position: relative; z-index: 1; }
.auth-points li { padding-left: 26px; position: relative; font-weight: 550; }
.auth-points li::before { content: ""; position: absolute; left: 0; top: 7px; width: 12px; height: 12px; border-radius: 50%; background: var(--sun); }
.auth-form { border: 0; border-radius: 0; padding: 40px; justify-content: center; gap: 16px; }
.auth-alt { font-size: 14px; color: var(--muted); text-align: center; }
.reg { display: flex; flex-direction: column; gap: 14px; }
.form-sections fieldset { border: 0; padding: 0 0 18px; margin: 0; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.form-sections legend { font: 600 14px var(--f-display); color: var(--brand); padding: 0 0 12px; }
.state { align-items: center; text-align: center; padding: 40px 24px; gap: 14px; max-width: 640px; margin: 20px auto 0; width: 100%; }
.state p { max-width: 52ch; }
.state .kv { text-align: left; width: 100%; max-width: 440px; }
.state-ico { width: 64px; height: 64px; border-radius: 50%; border: 6px solid var(--sun); position: relative; }
.state-ico.st-rejected, .state-ico.st-blocked { border-color: var(--bad); }
.docs { display: flex; flex-direction: column; gap: 8px; width: 100%; text-align: left; }
.doc-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; background: var(--surface-2); border-radius: var(--r-sm); font-size: 14px; flex-wrap: wrap; }
.doc-row > span:first-child { flex: 1; min-width: 160px; }
.upl { cursor: pointer; }

/* ---------- каталог ---------- */
.filters { gap: 14px; }
.type-chips, .seg { display: flex; flex-wrap: wrap; gap: 6px; }
.type-chips button, .seg button { font: 600 13.5px var(--f-body); padding: 8px 14px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); cursor: pointer; display: inline-flex; gap: 7px; align-items: center; }
.type-chips button.on, .seg button.on { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.seg .cnt { font: 600 11px var(--f-mono); opacity: .7; }
.f-row { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) 90px auto; gap: 12px; align-items: end; }
.f-btns { display: flex; gap: 8px; }
.tour-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 18px; }
.tour-card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; color: var(--fg); text-decoration: none !important; transition: border-color .15s, transform .15s, box-shadow .15s; }
.tour-card:hover { border-color: var(--brand); box-shadow: var(--shadow); transform: translateY(-2px); }
.tc-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.tc-body h3 { font-size: 17px; line-height: 1.3; }
.tc-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; font-size: 13px; color: var(--muted); }
.tc-route { font: 500 12.5px var(--f-mono); color: var(--muted); }
.tc-route.big { font-size: 14px; }
.tc-dates { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.lbl { font-size: 11px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); }
.tc-dates .lbl { width: 100%; }
.chip { font: 600 12px var(--f-mono); background: var(--surface-2); border-radius: 5px; padding: 4px 7px; }
.chip.more { color: var(--brand); }
.tc-price { margin-top: auto; padding-top: 10px; border-top: 1px dashed var(--line); display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; }
.tc-price .num { font: 600 22px var(--f-display); color: var(--brand); }
.tc-price .orig { display: inline; }
.tc-price small { width: 100%; color: var(--muted); font-size: 12px; }

.cover { aspect-ratio: 16 / 7; max-width: 100%; background: var(--surface-2); position: relative; overflow: hidden; }
.cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cover.big { aspect-ratio: auto; height: 100%; min-height: 240px; border-radius: var(--r); }
.cover.art { background: linear-gradient(120deg, var(--brand) 0%, color-mix(in srgb, var(--brand) 55%, var(--sky)) 100%); color: #fff; }
.cover.art.ty-inbound { background: linear-gradient(120deg, #1a3b8e 0%, #2a7aa0 100%); }
.cover.art.ty-excursion { background: linear-gradient(120deg, #264aa8 0%, #3f9fc4 100%); }
.cover.art.ty-ground { background: linear-gradient(120deg, #23376f 0%, #4a6fb8 100%); }
.art-sun { position: absolute; right: 22px; top: 50%; width: 92px; height: 92px; margin-top: -46px; border-radius: 50%; border: 12px solid var(--sun); }
.art-sun::before { content: ""; position: absolute; left: 50%; top: -48px; width: 10px; height: 28px; margin-left: -5px; border-radius: 6px; background: var(--sun); box-shadow: 46px 20px 0 var(--sun), -46px 20px 0 var(--sun); }
.cover.big .art-sun { width: 140px; height: 140px; margin-top: -70px; border-width: 16px; right: 40px; }
.art-txt { position: absolute; left: 20px; bottom: 16px; right: 140px; display: flex; flex-direction: column; gap: 4px; }
.art-country { font: 600 12px var(--f-body); letter-spacing: .14em; text-transform: uppercase; opacity: .85; }
.art-route { font: 600 20px var(--f-mono); letter-spacing: .04em; display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.art-route i { font-style: normal; color: var(--sun); font-size: 15px; }
.art-route.small { font-size: 14px; font-family: var(--f-body); }
.cover.big .art-txt { left: 28px; bottom: 26px; right: 200px; }
.cover.big .art-route { font-size: 26px; }

.tour { display: flex; flex-direction: column; gap: 18px; }
.tour-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; align-items: stretch; }
.tour-head { display: flex; flex-direction: column; gap: 12px; justify-content: center; }
.desc { color: var(--fg); max-width: 60ch; }
.tour-cols { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
.incl { display: flex; flex-direction: column; gap: 10px; padding-top: 6px; }
.incl h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }
.board td:first-child, .board td:nth-child(2) { white-space: nowrap; }
.incl ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 7px; font-size: 14px; }
.incl li { padding-left: 22px; position: relative; }
.incl li::before { content: ""; position: absolute; left: 2px; top: 6px; width: 10px; height: 6px; border-left: 2px solid var(--ok); border-bottom: 2px solid var(--ok); transform: rotate(-45deg); }
.deps { padding-bottom: 6px; }

/* ---------- бронирование ---------- */
.book-summary { flex-direction: row; justify-content: space-between; align-items: center; flex-wrap: wrap; }
.book-summary > div:first-child { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.book-summary .seats { min-width: 180px; }
.book-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 18px; align-items: start; }
.book-main { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.sticky { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 84px); }
.t-row { display: grid; grid-template-columns: 74px repeat(2, minmax(0, 1.2fr)) 64px repeat(3, minmax(0, 1fr)) 92px; gap: 10px; align-items: end; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.t-row:last-child { border-bottom: 0; }
.t-n { display: flex; flex-direction: column; gap: 2px; padding-bottom: 8px; }
.t-n b { font: 600 18px var(--f-display); color: var(--brand); }
.t-n span { font-size: 11px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.t-row input, .t-row select { padding: 9px 9px; font-size: 14px; }
.money { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.money > div { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; font-size: 14px; }
.money dt { color: var(--muted); }
.money dd { margin: 0; text-align: right; font-weight: 650; font-variant-numeric: tabular-nums; }
.money dd small { display: block; font-weight: 500; color: var(--muted); font-size: 12px; }
.money .big dd { font: 600 22px var(--f-display); color: var(--fg); }
.money .net { padding-top: 10px; border-top: 1px solid var(--line); }
.money .net dd { color: var(--brand); font-size: 17px; }
.money .due dd { color: var(--bad); }
.money .zero dd { color: var(--ok); }

/* ---------- бронь ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; }
.search input { min-width: 240px; }
.bk-head { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: flex-end; }
.bk-head > div:first-child { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.bk-no { font-size: 14px; font-weight: 700; color: var(--brand); }
.bk-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.bk-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 18px; align-items: start; }
.bk-main { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.timeline { list-style: none; margin: 0; padding: 0; display: flex; gap: 0; }
.timeline li { flex: 1; display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--muted); position: relative; padding-right: 12px; }
.timeline li::after { content: ""; flex: 1; height: 2px; background: var(--line); }
.timeline li:last-child::after { display: none; }
.timeline li span { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--line); background: var(--surface); flex: none; }
.timeline li.done { color: var(--fg); }
.timeline li.done span { background: var(--brand); border-color: var(--brand); }
.timeline li.done::after { background: var(--brand); }
.timeline li.cur span { box-shadow: 0 0 0 4px color-mix(in srgb, var(--sun) 55%, transparent); }
.timeline.stopped { display: flex; }
.note h3 { color: var(--muted); }
.note.op { border-color: var(--sky); }
.admin-act { border-color: color-mix(in srgb, var(--brand) 35%, var(--line)); }
.pay-form, #acForm { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.pay-form .fld, #acForm .fld { flex: 1; min-width: 200px; }

/* ---------- админка ---------- */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; display: flex; flex-direction: column; gap: 8px; color: var(--fg); text-decoration: none !important; }
a.stat:hover { border-color: var(--brand); }
.stat b { font: 600 28px/1.1 var(--f-display); }
.stat b small { font-size: 15px; color: var(--muted); }
.stat .money-s { font-size: 19px; line-height: 1.35; }
.stat.hot { border-color: var(--sun); box-shadow: inset 4px 0 0 var(--sun); }
.act-list { list-style: none; margin: 0; padding: 0; }
.act-list a { display: grid; grid-template-columns: 80px minmax(0, 1fr) auto; grid-template-areas: "no title pill" "no meta pill"; gap: 2px 12px; align-items: center; padding: 11px 20px; border-top: 1px solid var(--line); color: var(--fg); text-decoration: none; }
.act-list a:hover { background: var(--surface-2); }
.act-list .mono { grid-area: no; color: var(--brand); font-weight: 600; font-size: 12.5px; }
.act-list .clip { grid-area: title; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.act-list .small { grid-area: meta; }
.act-list .pill { grid-area: pill; }
.head-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.lang-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); }
.lang-tabs button { font: 600 13px var(--f-mono); padding: 8px 14px; background: transparent; border: 0; border-bottom: 2px solid transparent; color: var(--muted); cursor: pointer; margin-bottom: -1px; }
.lang-tabs button.on { color: var(--brand); border-bottom-color: var(--brand); }
.lang-pane { display: flex; flex-direction: column; gap: 12px; }
.dep-tbl td { padding: 8px 6px; }
.dep-tbl td:first-child { padding-left: 14px; }
.dep-tbl input, .dep-tbl select { padding: 7px 8px; font-size: 13.5px; }
.dep-tbl input[type=date] { min-width: 136px; }
.w-xs { width: 74px; } .w-sm { width: 100px; } .w-md { min-width: 170px; }
.series { border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 12px; background: var(--surface-2); }
.status-btns { margin-top: -6px; }

/* ---------- ваучер ---------- */
.vc-tools { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.voucher { background: #fff; color: #141b2d; border: 1px solid var(--line); border-radius: var(--r); padding: 36px 40px; display: flex; flex-direction: column; gap: 18px; max-width: 820px; width: 100%; margin: 0 auto; }
.vc-head { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding-bottom: 16px; border-bottom: 3px solid #2045a1; flex-wrap: wrap; }
.vc-head img { height: 74px; }
.vc-co { display: flex; flex-direction: column; text-align: right; font-size: 13px; gap: 2px; }
.vc-co b { font-size: 15px; }
.vc-title { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.vc-title h1 { color: #2045a1; text-transform: uppercase; letter-spacing: .06em; }
.vc-title .mono { font-size: 18px; font-weight: 700; }
.voucher h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: #5d6680; }
.vc-kv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 24px; margin: 0; }
.vc-kv dt { font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: #5d6680; font-weight: 700; }
.vc-kv dd { margin: 2px 0 0; font-weight: 600; }
.vc-tbl th { background: #eef1f8; color: #5d6680; border-color: #dde2ee; }
.vc-tbl td { border-color: #dde2ee; color: #141b2d; }
.vc-incl { margin: 0; padding-left: 18px; display: grid; gap: 4px; font-size: 14px; }
.vc-foot { display: flex; justify-content: space-between; font-size: 12px; color: #5d6680; border-top: 1px solid #dde2ee; padding-top: 12px; }

/* ---------- прочее ---------- */
.foot { border-top: 1px solid var(--line); font-size: 12.5px; color: var(--muted); }
.foot-in { display: flex; justify-content: space-between; gap: 10px; padding-block: 16px 70px; flex-wrap: wrap; }
.loading { display: flex; gap: 8px; justify-content: center; padding: 60px 0; }
.loading span { width: 10px; height: 10px; border-radius: 50%; background: var(--sun); animation: bob 1s infinite ease-in-out; }
.loading span:nth-child(2) { animation-delay: .15s; background: var(--sky); }
.loading span:nth-child(3) { animation-delay: .3s; background: var(--brand); }
@keyframes bob { 0%, 100% { transform: translateY(0); opacity: .5; } 50% { transform: translateY(-8px); opacity: 1; } }
#toasts { position: fixed; z-index: 50; right: max(16px, env(safe-area-inset-right, 0px)); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 8px; max-width: calc(100vw - 32px); }
.toast { background: var(--fg); color: var(--bg); padding: 12px 16px; border-radius: 10px; font-weight: 600; font-size: 14px; box-shadow: var(--shadow); border-left: 4px solid var(--sun); transition: opacity .3s, transform .3s; }
.toast.err { border-left-color: var(--bad); }
.toast.out { opacity: 0; transform: translateY(8px); }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---------- адаптив ---------- */
@media (max-width: 1000px) {
  .f-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .f-btns { grid-column: 1 / -1; }
  .tour-hero, .tour-cols, .book-grid, .bk-grid, .two-col { grid-template-columns: minmax(0, 1fr); }
  .cover.big { min-height: 200px; }
  .sticky { position: static; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .t-row { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .t-n { grid-column: 1 / -1; flex-direction: row; gap: 10px; align-items: baseline; padding-bottom: 0; }
}
@media (max-width: 720px) {
  .auth { grid-template-columns: minmax(0, 1fr); }
  .auth-brand, .auth-form { padding: 26px 22px; }
  .auth-brand::after { width: 180px; height: 180px; right: -70px; bottom: -70px; border-width: 16px; }
  .g2, .g3, .g4 { grid-template-columns: minmax(0, 1fr); }
  .s2, .s3 { grid-column: auto; }
  .t-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tour-grid { grid-template-columns: minmax(0, 1fr); }
  .top-in { gap: 10px; }
  .logo img { height: 38px; }
  .nav { order: 3; flex-basis: 100%; overflow-x: auto; flex-wrap: nowrap; }
  .who { display: none; }
  .search input { min-width: 0; }
  .search { flex: 1; }
  /* таблицы превращаются в карточки */
  .tbl:not(.vc-tbl) thead { display: none; }
  .tbl:not(.vc-tbl) tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 6px 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
  .tbl:not(.vc-tbl) td { border: 0; padding: 0; text-align: left; }
  .tbl:not(.vc-tbl) td[data-l]::before { content: attr(data-l); display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
  .tbl:not(.vc-tbl) td.r { text-align: left; }
  .tbl:not(.vc-tbl) td:not([data-l]) { grid-column: 1 / -1; }
  .tbl .clip { max-width: none; }
  .dep-tbl input, .dep-tbl select, .w-xs, .w-sm, .w-md { width: 100%; min-width: 0; }
  .dep-tbl td:first-child { padding-left: 0; }
  .stats { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .stat b { font-size: 22px; }
  .voucher { padding: 22px 18px; }
  .vc-kv { grid-template-columns: minmax(0, 1fr); }
  .vc-co { text-align: left; }
  .cover.big .art-txt { right: 130px; left: 20px; }
  .cover.big .art-sun { width: 100px; height: 100px; margin-top: -50px; right: 22px; border-width: 12px; }
  .timeline li { font-size: 12px; }
}

@media print {
  body { background: #fff; }
  .demo-fab, .top, .foot, .no-print, #toasts { display: none !important; }
  .main { padding: 0; }
  .voucher { border: 0; padding: 0; max-width: none; }
}

/* ================= v2: сайт для туристов + CRM ================= */
.who { display: flex; flex-direction: column; line-height: 1.15; }
.who small { font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--brand); }
.top.is-crm { box-shadow: inset 0 -3px 0 var(--sun); }
.btn.sun { background: var(--sun); color: #2a2100; }
.btn.sun:hover { background: color-mix(in srgb, var(--sun) 85%, #000); }
.stack { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.narrow { max-width: 720px; }
.banner { background: var(--info-bg); color: var(--fg); border-radius: var(--r-sm); padding: 10px 14px; font-size: 14px; font-weight: 550; }
.banner.warn { background: var(--warn-bg); }
.fld.inline { flex-direction: row; align-items: center; gap: 8px; }
.fld.inline > span { white-space: nowrap; }
.fld.inline select, .fld.inline input { width: auto; padding: 7px 9px; font-size: 14px; }
.warn-t { color: var(--warn); }

/* hero */
.hero { background: var(--panel); color: #fff; border-radius: 16px; overflow: hidden; position: relative; }
.hero-in { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 24px; padding: 40px 44px; align-items: center; }
.hero-txt { display: flex; flex-direction: column; gap: 14px; position: relative; z-index: 1; }
.hero h1 { font-size: clamp(26px, 3.6vw, 42px); color: #fff; max-width: 16ch; }
.hero p { max-width: 58ch; opacity: .9; font-size: 16px; }
.hero-points, .partner .hero-points { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; }
.hero-points li { padding-left: 20px; position: relative; font-weight: 600; font-size: 14px; }
.hero-points li::before { content: ""; position: absolute; left: 0; top: 5px; width: 10px; height: 10px; border-radius: 50%; background: var(--sun); }
.hero-sun { width: 220px; height: 220px; border-radius: 50%; border: 26px solid var(--sun); justify-self: end; position: relative; }
.hero-sun::before { content: ""; position: absolute; left: 50%; top: -96px; width: 18px; height: 52px; margin-left: -9px; border-radius: 10px; background: var(--sun); box-shadow: 92px 30px 0 var(--sun), -92px 30px 0 var(--sun); }
.partner { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--line); border-left: 6px solid var(--sun); border-radius: var(--r); padding: 24px 28px; }
.partner > div { display: flex; flex-direction: column; gap: 6px; max-width: 70ch; }
.partner h2 { font: 600 20px var(--f-display); }
.partner p { color: var(--muted); }
.partner.intro { border-left-color: var(--brand); }
.partner.intro h1 { font-size: 26px; }
.partner.intro .hero-points li { color: var(--fg); }
.who-seg { align-self: flex-start; }
.staff-login, .reg-t { max-width: 460px; }
.staff-login .stack, .reg-t .stack { width: 100%; text-align: left; }
.staff-logo { height: 70px; }
.staff-login .logo-d { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .staff-login .logo-l { display: none; } :root:not([data-theme="light"]) .staff-login .logo-d { display: block; } }
:root[data-theme="dark"] .staff-login .logo-l { display: none; }
:root[data-theme="dark"] .staff-login .logo-d { display: block; }
.state-banner { display: flex; gap: 16px; align-items: center; background: var(--warn-bg); border-radius: var(--r); padding: 16px 20px; }
.state-banner.st-rejected, .state-banner.st-blocked { background: var(--bad-bg); }
.state-banner .state-ico { width: 44px; height: 44px; border-width: 5px; flex: none; }
.state-banner p { color: var(--muted); }

/* demo switcher */
.demo-fab { position: fixed; z-index: 40; left: max(16px, env(safe-area-inset-left, 0px)); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
.demo-fab summary { list-style: none; cursor: pointer; font: 700 12px var(--f-mono); letter-spacing: .08em; text-transform: uppercase; background: var(--sun); color: #2a2100; border-radius: 99px; padding: 9px 14px; box-shadow: var(--shadow); }
.demo-fab summary::-webkit-details-marker { display: none; }
.demo-pop { position: absolute; left: 0; bottom: calc(100% + 8px); background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 12px; display: flex; flex-direction: column; gap: 6px; width: 230px; }
.demo-pop b { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.demo-pop button { font: 600 14px var(--f-body); text-align: left; padding: 8px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); cursor: pointer; }
.demo-pop button.on { border-color: var(--brand); color: var(--brand); background: var(--surface-2); }
.demo-pop button.rst { color: var(--bad); }
.demo-pop small { color: var(--muted); font-size: 11.5px; }

/* каналы, менеджеры */
.chan { display: inline-block; font-size: 10.5px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; padding: 2px 6px; border-radius: 4px; }
.chan.ch-agency { background: var(--surface-2); color: var(--brand); }
.chan.ch-direct { background: color-mix(in srgb, var(--sun) 35%, var(--surface)); color: var(--fg); }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 4px; vertical-align: 1px; }
.dot.ch-agency, .split .ch-agency { background: var(--brand); }
.dot.ch-direct, .split .ch-direct { background: var(--sun); }
.split { display: flex; height: 8px; border-radius: 4px; overflow: hidden; background: var(--surface-2); }
.split i { display: block; height: 100%; }
.stat small { color: var(--muted); font-size: 12px; line-height: 1.5; }
.tb-right { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.tb-right select { width: auto; padding: 8px 10px; font-size: 13.5px; }
.client-card { gap: 10px; }
.cc-row { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; }

/* заметки и задачи */
.note-form { display: flex; flex-direction: column; gap: 8px; }
.note-opts { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; }
.notes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.note-item { display: flex; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); align-items: flex-start; }
.note-item:first-child { border-top: 0; }
.note-item p { white-space: pre-wrap; overflow-wrap: anywhere; }
.nbody { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.nmeta { font-size: 12px; color: var(--muted); }
.nchk input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--ok); }
.ndot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); margin: 7px 5px 0; flex: none; }
.note-item.over .ndue { color: var(--bad); }
.note-item.today .ndue { color: var(--warn); }
.note-item.is-done p { text-decoration: line-through; color: var(--muted); }
.task-grp h2 { display: flex; gap: 8px; align-items: baseline; }
.task-grp.over { border-left: 4px solid var(--bad); }
.task-grp.today { border-left: 4px solid var(--sun); }
.task-grp.done { opacity: .75; }

@media (max-width: 1000px) {
  .hero-in { grid-template-columns: minmax(0, 1fr); padding: 28px 24px; }
  .hero-sun { display: none; }
}
@media (max-width: 720px) {
  .top-tools .btn { padding: 7px 10px; }
  .who small { display: none; }
  .tb-right { width: 100%; }
  .tb-right select, .tb-right .search { flex: 1; min-width: 0; }
  .partner { padding: 20px; }
}

/* ================= поиск туров ================= */
.hero.compact .hero-in { padding: 34px 40px 64px; grid-template-columns: minmax(0, 1fr) 180px; }
.hero.compact h1 { max-width: none; }
.hero.compact .hero-sun { width: 150px; height: 150px; border-width: 18px; }
.hero.compact .hero-sun::before { top: -70px; width: 14px; height: 40px; margin-left: -7px; box-shadow: 64px 22px 0 var(--sun), -64px 22px 0 var(--sun); }
.search-wrap.over { margin-top: -54px; position: relative; z-index: 2; padding-inline: 20px; }
.sbar { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.6fr) minmax(0, .9fr) minmax(0, 1fr) auto; gap: 0; background: var(--surface); border: 2px solid var(--sun); border-radius: 14px; box-shadow: var(--shadow); align-items: stretch; }
.sf { display: flex; flex-direction: column; gap: 3px; padding: 10px 14px; border-right: 1px solid var(--line); min-width: 0; position: relative; }
.sf > span, .sf summary > span { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.sf input, .sf select { border: 0; padding: 4px 0; font-size: 15.5px; font-weight: 600; background: transparent; box-shadow: none !important; }
.sf-row { display: flex; align-items: center; gap: 6px; min-width: 0; }
.sf-row i { color: var(--muted); font-style: normal; }
.sf-row input, .sf-row select { min-width: 0; flex: 1; }
.s-pax summary { list-style: none; cursor: pointer; display: flex; flex-direction: column; gap: 3px; }
.s-pax summary::-webkit-details-marker { display: none; }
.s-pax summary b { font-size: 15.5px; padding: 4px 0; white-space: nowrap; }
.pax-pop { position: absolute; top: calc(100% + 8px); right: 0; width: 290px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 14px; display: flex; flex-direction: column; gap: 10px; z-index: 30; }
.pax-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-weight: 600; font-size: 14px; }
.stepper { display: flex; align-items: center; gap: 10px; }
.stepper button, .kid .x { width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--fg); font-size: 18px; line-height: 1; cursor: pointer; }
.stepper button:hover { border-color: var(--brand); color: var(--brand); }
.stepper b { min-width: 18px; text-align: center; font-size: 16px; }
.kid { display: flex; gap: 6px; align-items: center; }
.kid select { width: 76px; padding: 6px 8px; }
.s-go { border-radius: 0 11px 11px 0; padding-inline: 26px; font-size: 15px; }

.pcal { gap: 10px; padding: 16px 18px; }
.pcal-head { display: flex; gap: 12px; align-items: baseline; flex-wrap: wrap; }
.pcal-head h2 { font-size: 15px; }
.pcal-head .btn { margin-left: auto; }
.pcal-strip { display: flex; gap: 4px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.pday { flex: none; width: 58px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; border-radius: 8px; border: 1px solid transparent; background: transparent; color: var(--fg); cursor: pointer; font: inherit; }
.pday:hover { background: var(--surface-2); }
.pday.on { border-color: var(--brand); background: var(--surface-2); }
.pbar { height: 82px; display: flex; align-items: flex-end; }
.pbar i { display: block; width: 26px; border-radius: 5px 5px 2px 2px; background: color-mix(in srgb, var(--sky) 55%, var(--surface)); }
.pday.best .pbar i { background: var(--sun); }
.pday.on .pbar i { background: var(--brand); }
.pv { font: 600 11px var(--f-mono); white-space: nowrap; }
.pday.best .pv { color: var(--ok); }
.pd { font-weight: 700; font-size: 14px; }
.pw { font-size: 11px; color: var(--muted); }

.sres { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 18px; align-items: start; }
.sfilters { gap: 10px; position: sticky; top: calc(env(safe-area-inset-top, 0px) + 84px); }
.sfilters h3 { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-top: 6px; }
.sfilters h3 small { text-transform: none; letter-spacing: 0; font-weight: 500; }
.chips-col { display: flex; flex-wrap: wrap; gap: 6px; }
.chips-col button { font: 600 13px var(--f-body); padding: 6px 10px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); cursor: pointer; }
.chips-col button.on { background: var(--brand); color: var(--on-brand); border-color: var(--brand); }
.slist { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.sort-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.sort-bar select { width: auto; }
.res { display: grid; grid-template-columns: 220px minmax(0, 1fr) 190px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; transition: border-color .15s, box-shadow .15s; }
.res:hover { border-color: color-mix(in srgb, var(--brand) 50%, var(--line)); box-shadow: var(--shadow); }
.res-cover .cover { height: 100%; aspect-ratio: auto; min-height: 170px; }
.res-cover .art-sun { width: 64px; height: 64px; margin-top: -32px; border-width: 9px; right: 14px; }
.res-cover .art-sun::before { top: -36px; width: 8px; height: 20px; margin-left: -4px; box-shadow: 32px 14px 0 var(--sun), -32px 14px 0 var(--sun); }
.res-cover .art-txt { right: 90px; left: 14px; bottom: 12px; }
.res-cover .art-route { font-size: 15px; }
.res-body { padding: 14px 18px; display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.res-body h3 { font-size: 17px; line-height: 1.3; }
.res-body h3 a { color: var(--fg); }
.res-incl { font-size: 13px; color: var(--muted); }
.res-dates { display: flex; flex-direction: column; gap: 6px; margin-top: 2px; }
.dchips { display: flex; flex-wrap: wrap; gap: 6px; }
.dchip { display: flex; flex-direction: column; gap: 1px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 8px; color: var(--fg); text-decoration: none !important; min-width: 92px; }
.dchip:hover { border-color: var(--brand); background: var(--surface-2); }
.dchip .dd { font-weight: 700; font-size: 13px; }
.dchip .dn { font-size: 11.5px; color: var(--muted); }
.dchip .dn .hot { color: var(--bad); font-weight: 700; }
.dchip .dp { font: 600 13px var(--f-mono); color: var(--brand); }
.dchip.best { border-color: var(--sun); box-shadow: inset 0 0 0 1px var(--sun); }
.dchip.best .dp { color: var(--ok); }
.dchip.more { justify-content: center; align-items: center; color: var(--brand); font-weight: 600; font-size: 13px; }
.res-price { border-left: 1px dashed var(--line); padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; justify-content: center; align-items: stretch; text-align: right; }
.res-price b { font: 600 24px var(--f-display); color: var(--brand); }
.res-price small { color: var(--muted); font-size: 12px; }
.res-price .com { color: var(--ok); font-weight: 600; }
.res-price .btn { margin-top: 4px; }

@media (max-width: 1100px) {
  .sbar { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .sf { border-bottom: 1px solid var(--line); }
  .s-go { grid-column: 1 / -1; border-radius: 0 0 11px 11px; padding-block: 14px; }
  .res { grid-template-columns: 180px minmax(0, 1fr); }
  .res-price { grid-column: 1 / -1; border-left: 0; border-top: 1px dashed var(--line); flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: flex-end; text-align: left; }
}
@media (max-width: 860px) {
  .sres { grid-template-columns: minmax(0, 1fr); }
  .sfilters { position: static; flex-direction: row; flex-wrap: wrap; align-items: center; }
  .sfilters h3 { width: 100%; margin-top: 0; }
}
@media (max-width: 720px) {
  .hero.compact .hero-in { padding: 24px 20px 58px; }
  .search-wrap.over { padding-inline: 0; }
  .sbar { grid-template-columns: minmax(0, 1fr); }
  .sf { border-right: 0; }
  .pax-pop { left: 0; right: auto; width: 100%; }
  .res { grid-template-columns: minmax(0, 1fr); }
  .res-cover .cover { min-height: 120px; aspect-ratio: 16 / 6; }
  .res-price { justify-content: space-between; }
}
@media (max-width: 1000px) {
  .hero.compact .hero-in { grid-template-columns: minmax(0, 1fr); }
  .hero.compact .hero-sun { display: none; }
}

/* модуль Tourvisor */
.tv-box { min-height: 260px; }
.tv-cta { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; background: var(--surface); border: 1px dashed color-mix(in srgb, var(--brand) 45%, var(--line)); border-radius: var(--r); padding: 18px 22px; color: var(--fg); text-decoration: none !important; }
.tv-cta div { display: flex; flex-direction: column; gap: 3px; }
.tv-cta span { color: var(--muted); }
.tv-cta:hover { border-color: var(--brand); }

/* ================= простая главная с фото ================= */
.main.wide { gap: 28px; }
.hero2 { border-radius: 22px; background-size: cover; background-position: center; color: #fff; min-height: 460px; display: flex; align-items: flex-end; overflow: visible; position: relative; }
.hero2-in { padding: 48px 44px 40px; display: flex; flex-direction: column; gap: 14px; width: 100%; }
.hero2 h1 { color: #fff; font-size: clamp(30px, 5vw, 56px); line-height: 1.05; max-width: 14ch; text-shadow: 0 2px 24px rgba(0, 0, 0, .25); }
.hero2 p { font-size: clamp(15px, 1.6vw, 19px); max-width: 46ch; opacity: .95; text-shadow: 0 1px 12px rgba(0, 0, 0, .3); }
.qs { margin-top: 10px; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, .8fr) auto; background: #fff; border-radius: 16px; padding: 6px; gap: 0; box-shadow: 0 10px 40px rgba(8, 24, 60, .25); max-width: 860px; }
.qf { display: flex; flex-direction: column; gap: 2px; padding: 8px 16px; border-right: 1px solid #e3e7f0; min-width: 0; }
.qf:nth-child(3) { border-right: 0; }
.qf span { font-size: 11px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: #6b7590; }
.qf select { border: 0; padding: 3px 0; font-size: 16px; font-weight: 600; color: #141b2d; background: transparent; box-shadow: none !important; cursor: pointer; }
.qs-go { border-radius: 12px; padding: 0 28px; font-size: 16px; }
.sec { display: flex; flex-direction: column; gap: 16px; }
.sec-title { font: 600 clamp(20px, 2.4vw, 28px) var(--f-display); }
.sec-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.link-btn { background: none; border: 0; color: var(--brand); font: 600 15px var(--f-body); cursor: pointer; padding: 4px 0; }
.link-btn:hover { text-decoration: underline; }
.ph { background-size: cover; background-position: center; background-color: var(--surface-2); position: relative; overflow: hidden; }
.ph > .cover { position: absolute; inset: 0; aspect-ratio: auto; height: 100%; }
.dest-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.dest { position: relative; border: 0; padding: 0; border-radius: 18px; overflow: hidden; cursor: pointer; aspect-ratio: 4 / 5; max-width: 100%; background: var(--surface-2); text-align: left; }
.dest-ph { position: absolute; inset: 0; transition: transform .5s ease; }
.dest:hover .dest-ph { transform: scale(1.06); }
.dest::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(8, 24, 60, .75)); }
.dest-txt { position: absolute; left: 16px; right: 16px; bottom: 14px; z-index: 1; color: #fff; display: flex; flex-direction: column; gap: 2px; }
.dest-txt b { font: 600 20px var(--f-display); }
.dest-txt small { font-size: 14px; font-weight: 600; color: var(--sun); }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 20px; }
.tcard { position: relative; display: flex; flex-direction: column; background: var(--surface); border-radius: 18px; overflow: hidden; color: var(--fg); text-decoration: none !important; box-shadow: 0 1px 3px rgba(20, 30, 70, .06); transition: transform .2s, box-shadow .2s; }
.tcard:hover { transform: translateY(-4px); box-shadow: 0 14px 36px rgba(20, 30, 70, .14); }
.tcard-ph { aspect-ratio: 4 / 3; max-width: 100%; }
.tcard-country { position: absolute; top: 14px; left: 14px; background: rgba(255, 255, 255, .92); color: #141b2d; font-size: 12.5px; font-weight: 700; padding: 5px 11px; border-radius: 99px; }
.tcard-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.tcard-body h3 { font-size: 18px; line-height: 1.3; }
.tcard-meta { color: var(--muted); font-size: 14px; }
.tcard-price { margin-top: auto; display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; padding-top: 6px; }
.tcard-price span, .tcard-price small { color: var(--muted); font-size: 14px; }
.tcard-price b { font: 600 24px var(--f-display); color: var(--brand); }
.tcard-price em { font-style: normal; font-size: 12.5px; font-weight: 700; color: var(--ok); width: 100%; }
.why { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; background: var(--surface); border-radius: 18px; padding: 26px; }
.why > div { display: flex; flex-direction: column; gap: 6px; }
.why b { font-size: 16px; }
.why span { color: var(--muted); font-size: 14.5px; }
.ico { width: 44px; height: 44px; border-radius: 12px; background: color-mix(in srgb, var(--sun) 28%, var(--surface)); display: block; position: relative; margin-bottom: 4px; }
.ico::before { content: ""; position: absolute; inset: 11px; background: var(--brand); -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.ico-plane { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M21 16v-2l-8-5V3.5a1.5 1.5 0 0 0-3 0V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5z'/%3E%3C/svg%3E"); }
.ico-click { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 2a7 7 0 0 0-4.9 12l1.4-1.4A5 5 0 1 1 14 9h2a7 7 0 0 0-7-7zm0 4a3 3 0 0 0-3 3v.2l9.5 13.3 2-3.6 4 .1L9.7 6.1A3 3 0 0 0 9 6z'/%3E%3C/svg%3E"); }
.ico-chat { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 3h16a2 2 0 0 1 2 2v11a2 2 0 0 1-2 2H9l-5 4v-4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z'/%3E%3C/svg%3E"); }

/* страница тура */
.t-hero { border-radius: 22px; min-height: 380px; background-size: cover; background-position: center; position: relative; display: flex; align-items: flex-end; overflow: hidden; color: #fff; }
.t-hero.noimg > .cover { position: absolute; inset: 0; min-height: 0; border-radius: 0; }
.t-hero-in { position: relative; z-index: 1; padding: 28px 34px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.t-hero.noimg .t-hero-in { background: linear-gradient(180deg, transparent, rgba(8, 24, 60, .6)); width: 100%; }
.t-back { color: #fff; font-weight: 600; font-size: 14px; background: rgba(0, 0, 0, .25); padding: 6px 12px; border-radius: 99px; }
.t-chip { background: var(--sun); color: #2a2100; font-weight: 700; font-size: 13px; padding: 5px 12px; border-radius: 99px; }
.t-hero h1 { color: #fff; font-size: clamp(26px, 4vw, 44px); max-width: 22ch; text-shadow: 0 2px 20px rgba(0, 0, 0, .3); }
.t-body { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; align-items: start; }
.t-main { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.t-desc { font-size: 17px; line-height: 1.65; max-width: 65ch; }
.t-main h2 { font: 600 19px var(--f-display); margin-top: 8px; }
.t-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.t-list li { padding-left: 30px; position: relative; font-size: 15.5px; }
.t-list li::before { content: ""; position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border-radius: 50%; background: var(--ok-bg); }
.t-list.yes li::after { content: ""; position: absolute; left: 6px; top: 7px; width: 8px; height: 5px; border-left: 2px solid var(--ok); border-bottom: 2px solid var(--ok); transform: rotate(-45deg); }
.t-list.no li::before { background: var(--off-bg); }
.t-list.no li::after { content: "×"; position: absolute; left: 6px; top: 0; color: var(--off); font-weight: 700; }
.t-book { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 84px); gap: 12px; border-radius: 18px; border: 0; box-shadow: 0 10px 34px rgba(20, 30, 70, .12); }
.t-book h3 { font-size: 16px; }
.t-dates { display: flex; flex-direction: column; gap: 8px; max-height: 340px; overflow-y: auto; }
.dbtn { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "d p" "m p"; gap: 2px 10px; text-align: left; padding: 10px 14px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); color: var(--fg); cursor: pointer; font: inherit; }
.dbtn:hover { border-color: var(--brand); }
.dbtn.on { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 7%, var(--surface)); box-shadow: inset 0 0 0 1px var(--brand); }
.dbtn:disabled { opacity: .45; cursor: not-allowed; }
.dbtn-d { grid-area: d; font-weight: 700; }
.dbtn-m { grid-area: m; font-size: 12.5px; color: var(--muted); }
.dbtn-m .hot { color: var(--bad); }
.dbtn-p { grid-area: p; align-self: center; font: 600 16px var(--f-mono); color: var(--brand); }
.t-sum { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; padding-top: 6px; border-top: 1px solid var(--line); }
.t-sum span, .t-sum small { color: var(--muted); }
.t-sum b { font: 600 28px var(--f-display); color: var(--brand); }
.btn.big { padding: 15px 20px; font-size: 16px; border-radius: 12px; }

@media (max-width: 1000px) {
  .t-body { grid-template-columns: minmax(0, 1fr); }
  .t-book { position: static; }
}
@media (max-width: 720px) {
  .hero2 { min-height: 0; border-radius: 18px; }
  .hero2-in { padding: 34px 18px 20px; }
  .qs { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); padding: 8px; gap: 4px; }
  .qf { border-right: 0; background: #f3f5fa; border-radius: 10px; padding: 8px 12px; }
  .qf:first-child { grid-column: 1 / -1; }
  .qs-go { grid-column: 1 / -1; padding: 14px; }
  .dest-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .dest-txt b { font-size: 16px; }
  .why { grid-template-columns: minmax(0, 1fr); padding: 20px; }
  .t-hero { min-height: 280px; border-radius: 18px; }
  .t-hero-in { padding: 20px; }
}

.tv-hot { min-height: 180px; }

.tv-box.tv-demo { min-height: 0; flex-direction: row; align-items: center; gap: 14px; background: color-mix(in srgb, var(--sun) 14%, var(--surface)); border: 1px dashed color-mix(in srgb, var(--sun) 70%, var(--line)); }
.tv-box.tv-demo::before { content: "🔥"; font-size: 28px; }
.tv-box.tv-demo .tv-fallback { font-size: 14.5px; color: var(--fg); }

/* v8: поиск Турвизора прямо в обложке */
.hero2 { min-height: 520px; }
.hero-search { margin-top: 12px; width: 100%; max-width: 1100px; }
.hero-search .tv-box.tv-hero { min-height: 0; background: rgba(255,255,255,.97); border: 0; border-radius: 18px; padding: 14px 16px; box-shadow: 0 14px 44px rgba(8,24,60,.28); color: #0d1b3a; }
.hero-search .tv-box.tv-hero p { color: inherit; text-shadow: none; max-width: none; font-size: 14.5px; }
.hero-search .tv-box.tv-demo { background: rgba(255,255,255,.95); border: 0; }
@media (max-width: 720px) { .hero2 { min-height: 0; } .hero-search .tv-box.tv-hero { padding: 10px; border-radius: 14px; } }

/* v9: вкладки «Подбор тура» */
.tv-tabs { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 18px; }
.tv-tabs button { font: 600 15px var(--f-body, inherit); padding: 13px 20px; border-radius: 12px; border: 0; background: #eef1f6; color: #1d2b4f; cursor: pointer; transition: background .15s, color .15s, transform .15s; }
.tv-tabs button:hover { background: #e2e8f3; }
.tv-tabs button.on { background: var(--brand, #2045a1); color: #fff; box-shadow: 0 6px 18px rgba(32,69,161,.28); }
.tv-panels { position: relative; }
.tv-panel:not(.on) { position: absolute; left: 0; right: 0; top: 0; visibility: hidden; pointer-events: none; height: 0; overflow: hidden; }
.tv-panel .tv-box { min-height: 320px; }
@media (max-width: 720px) {
  .tv-tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: -16px; margin-right: -16px; padding: 0 16px 4px; }
  .tv-tabs::-webkit-scrollbar { display: none; }
  .tv-tabs button { flex: 0 0 auto; padding: 11px 16px; font-size: 14px; }
}

/* v10: слайдер, история, кнопка, сезонность */
.tv-box.tv-bare { min-height: 0; background: transparent; border: 0; box-shadow: none; padding: 0; }
.tv-box.tv-bare.tv-demo { background: color-mix(in srgb, var(--sun) 14%, var(--surface)); border: 1px dashed color-mix(in srgb, var(--sun) 70%, var(--line)); padding: 16px 20px; }
.tv-slider-sec { margin-top: 8px; }
.sec-title.small-t { font-size: 18px; }
.help-cta { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 30px 34px; border-radius: 22px; color: #fff;
  background: radial-gradient(120% 140% at 100% 0%, #3a6fe0 0%, #2045a1 55%, #142f73 100%); box-shadow: 0 16px 40px rgba(32,69,161,.25); }
.help-cta h2 { color: #fff; margin: 0 0 6px; font-size: clamp(20px, 2.4vw, 28px); }
.help-cta p { margin: 0; opacity: .9; max-width: 52ch; }
.help-btn { flex: 0 0 auto; }
.help-btn .tv-box.tv-demo { color: var(--fg); }
.s-mini { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; }
.s-mini-c { display: flex; flex-direction: column; border-radius: 16px; overflow: hidden; background: var(--surface); text-decoration: none; color: inherit; box-shadow: 0 4px 18px rgba(8,24,60,.07); transition: transform .15s, box-shadow .15s; }
.s-mini-c:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(8,24,60,.13); }
.s-mini-c > div:last-child { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 2px; }
.s-mini-c small { color: var(--muted); }
.s-ph { background-size: cover; background-position: center; position: relative; aspect-ratio: 16 / 10; display: flex; align-items: flex-end; }
.s-mini-ph { aspect-ratio: 4 / 3; }
.s-ph-n { font: 600 clamp(16px, 2vw, 22px) var(--f-display, inherit); color: rgba(255,255,255,.95); padding: 12px 14px; text-shadow: 0 2px 14px rgba(0,0,0,.2); }
.s-mini-ph .s-ph-n { font-size: 15px; }
.s-months { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 22px; }
.s-months button { font: 600 14px var(--f-body, inherit); padding: 10px 14px; border-radius: 12px; border: 0; background: #eef1f6; color: #1d2b4f; cursor: pointer; min-width: 58px; }
.s-months button.on { background: var(--brand, #2045a1); color: #fff; box-shadow: 0 6px 18px rgba(32,69,161,.28); }
.s-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.s-card { position: relative; background: var(--surface); border-radius: 20px; overflow: hidden; box-shadow: 0 6px 22px rgba(8,24,60,.08); display: flex; flex-direction: column; }
.s-card.r0 { opacity: .72; }
.s-badge { position: absolute; top: 12px; left: 12px; font: 700 12px var(--f-body, inherit); padding: 6px 10px; border-radius: 999px; background: #fff; color: #1d2b4f; }
.s-badge.r2 { background: var(--sun, #fcc900); color: #0d1b3a; }
.s-badge.r1 { background: #fff; color: var(--brand, #2045a1); }
.s-badge.r0 { background: rgba(255,255,255,.85); color: #6b7489; }
.s-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.s-body h3 { margin: 0; font-size: 20px; }
.s-body p { margin: 0; color: var(--muted); font-size: 14.5px; flex: 1; }
.s-body .btn { align-self: flex-start; }
.s-temps { display: flex; flex-wrap: wrap; gap: 8px; }
.s-temps span { font: 600 13.5px var(--f-body, inherit); background: #f1f4f9; color: #1d2b4f; padding: 6px 10px; border-radius: 10px; }
.s-legend { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 12px; font-size: 13.5px; }
.s-legend span::before { content: ""; display: inline-block; width: 12px; height: 12px; border-radius: 4px; margin-right: 6px; vertical-align: -1px; }
.s-legend .r2::before, .s-table td.r2 { background: #ffe680; }
.s-legend .r1::before, .s-table td.r1 { background: #dbe6fb; }
.s-legend .r0::before, .s-table td.r0 { background: #eef0f4; }
.s-table-wrap { overflow-x: auto; border-radius: 16px; background: var(--surface); box-shadow: 0 4px 18px rgba(8,24,60,.06); }
.s-table { border-collapse: separate; border-spacing: 4px; width: 100%; min-width: 760px; font-size: 13px; }
.s-table th { font-weight: 600; color: var(--muted); padding: 6px 4px; text-align: center; }
.s-table tbody th { text-align: left; color: var(--fg); white-space: nowrap; padding-left: 10px; position: sticky; left: 0; background: var(--surface); }
.s-table td { text-align: center; border-radius: 8px; padding: 8px 2px; color: #1d2b4f; font-weight: 600; }
.s-table td.r0 { color: #8a92a6; font-weight: 500; }
@media (max-width: 980px) { .s-mini { grid-template-columns: repeat(3, minmax(0, 1fr)); } .s-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  .help-cta { flex-direction: column; align-items: flex-start; padding: 22px 20px; }
  .s-mini { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .s-grid { grid-template-columns: minmax(0, 1fr); }
  .s-months { flex-wrap: nowrap; overflow-x: auto; margin-left: -16px; margin-right: -16px; padding: 0 16px 4px; scrollbar-width: none; }
  .s-months button { flex: 0 0 auto; }
}
.tv-hist-sec:has(.tv-history:empty) { display: none; }
