/* Родной Код — веб-версия для ПК. Стиль презентации: крафтовая бумага, завитки, PT Serif. */
@font-face { font-family: "PT Serif"; src: url(/assets/fonts/PT_Serif-Web-Regular.woff) format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "PT Serif"; src: url(/assets/fonts/PT_Serif-Web-Bold.woff) format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: "PT Sans"; src: url(/assets/fonts/PT_Sans-Web-Regular.woff) format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "PT Sans"; src: url(/assets/fonts/PT_Sans-Web-Bold.woff) format("woff"); font-weight: 700; font-display: swap; }

:root {
  --cream: #F9F5EA;
  --paper: #F6F0E2;
  --green: #274E13;
  --green-dark: #1B3A0C;
  --burgundy: #6C0000;
  --beige: #E2D3BC;
  --card: #F1E8D8;
  --card-light: #FBF7EE;
  --tan: #CBA980;
  --sage: #8F9E7F;
  --sage-light: #E4E8DB;
  --ochre: #D5975F;
  --text: #222;
  --muted: #5d5a52;
  --line: #E0D4BF;
  --error: #9A1B1B;
  --radius: 22px;
  --shadow: 0 10px 30px rgba(60, 45, 20, .10);
  --serif: "PT Serif", Georgia, serif;
  --sans: "PT Sans", "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--sans);
  color: var(--text);
  font-size: 16px;
  line-height: 1.45;
  background: var(--cream) url(/assets/img/paper.jpg) center / cover fixed;
  min-width: 720px;
}
a { color: var(--green); }
img { display: block; }
button, input, textarea, select { font: inherit; color: inherit; }
h1, h2, h3, h4 { font-family: var(--serif); color: var(--green); margin: 0; font-weight: 700; line-height: 1.15; }
h1 { font-size: 44px; }
h2 { font-size: 32px; }
h3 { font-size: 22px; }
p { margin: 0; }

/* Декоративные завитки из презентации */
.decor { position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background: url(/assets/img/decor-a.webp) center / 100% 100% no-repeat; opacity: .45; }
body.page-landing .decor { opacity: .6; }
#app { position: relative; z-index: 1; min-height: 100vh; display: flex; flex-direction: column; }

.boot { margin: auto; display: flex; flex-direction: column; align-items: center; gap: 24px; padding-top: 30vh; }
.boot-bar { width: 180px; height: 4px; border-radius: 2px; background: var(--beige); overflow: hidden; }
.boot-bar i { display: block; width: 40%; height: 100%; background: var(--green); animation: slide 1.2s ease-in-out infinite; }
@keyframes slide { from { transform: translateX(-100%); } to { transform: translateX(250%); } }

.wrap { width: min(1320px, calc(100% - 96px)); margin: 0 auto; }

/* ---------- Шапка ---------- */
.topbar { position: sticky; top: 0; z-index: 50; background: rgba(249, 245, 234, .88); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar .wrap { display: flex; align-items: center; gap: 36px; height: 84px; }
.topbar .logo img { height: 58px; width: auto; }
.nav { display: flex; gap: 6px; flex: 1; }
.nav a { text-decoration: none; color: var(--muted); font-weight: 700; padding: 10px 18px; border-radius: 999px; transition: .15s; display: inline-flex; align-items: center; gap: 8px; }
.nav a:hover { background: var(--card); color: var(--green); }
.nav a.active { background: var(--green); color: #fff; }
.nav a svg { width: 18px; height: 18px; }
.top-right { display: flex; align-items: center; gap: 14px; }
.chip-gen { display: inline-flex; align-items: center; gap: 8px; background: var(--sage-light); color: var(--green); font-weight: 700; padding: 8px 14px; border-radius: 999px; font-size: 14px; }
.chip-gen svg { width: 16px; height: 16px; }
.avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--green); color: #fff; font-family: var(--serif); font-weight: 700; font-size: 19px; display: grid; place-items: center; cursor: pointer; border: 0; }

/* ---------- Подвал ---------- */
.footer { margin-top: auto; border-top: 1px solid var(--line); background: rgba(241, 232, 216, .7); }
.footer .wrap { display: flex; align-items: center; gap: 28px; padding: 26px 0; }
.footer img.h { height: 64px; width: auto; }
.footer .motto { font-family: var(--serif); font-weight: 700; color: var(--burgundy); font-size: 18px; }
.footer .links { margin-left: auto; display: flex; gap: 22px; font-size: 14px; }
.footer .links a { color: var(--muted); }
.footer small { color: var(--muted); display: block; }

/* ---------- Общие элементы ---------- */
.main { flex: 1; padding: 44px 0 64px; }
.title-u { position: relative; display: inline-block; padding-bottom: 8px; }
.title-u::after { content: ""; position: absolute; left: 0; right: 12%; bottom: 0; height: 3px; border-radius: 3px; background: var(--green); opacity: .85; }
.lead { color: var(--muted); font-size: 18px; margin-top: 10px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.pill { background: rgba(226, 211, 188, .72); border-radius: 28px; padding: 16px 22px; }
.card { background: var(--card); border-radius: var(--radius); }
.card-w { background: var(--card-light); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.section { margin-top: 48px; }
.row { display: flex; gap: 16px; align-items: center; }
.grow { flex: 1; }
.hidden { display: none !important; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; border: 0; cursor: pointer; font-weight: 700; border-radius: 14px; padding: 14px 26px; text-decoration: none; transition: .15s; font-size: 16px; white-space: nowrap; }
.btn svg { width: 19px; height: 19px; }
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-dark); }
.btn-primary:disabled { background: var(--beige); color: var(--muted); cursor: default; }
.btn-light { background: #fff; color: var(--green); }
.btn-outline { background: transparent; color: var(--green); border: 1.5px solid var(--green); }
.btn-outline:hover { background: var(--sage-light); }
.btn-ghost { background: transparent; color: var(--green); padding: 10px 14px; }
.btn-ghost:hover { background: var(--card); }
.btn-danger { background: transparent; color: var(--error); border: 1.5px solid #d9b3ad; }
.btn-lg { padding: 18px 34px; font-size: 18px; border-radius: 16px; }
.btn-sm { padding: 9px 16px; font-size: 14px; border-radius: 12px; }
.btn-block { width: 100%; }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.field label { font-weight: 700; font-size: 14px; color: var(--green); }
.input, textarea.input, select.input { width: 100%; border: 1.5px solid var(--line); background: #fff; border-radius: 14px; padding: 13px 16px; outline: none; transition: .15s; }
.input:focus { border-color: var(--sage); box-shadow: 0 0 0 4px rgba(143, 158, 127, .18); }
textarea.input { resize: vertical; min-height: 96px; }
.hint { font-size: 13px; color: var(--muted); }
.error-box { background: #F4DDD6; color: #5A0B0B; padding: 12px 16px; border-radius: 12px; font-size: 14px; margin-bottom: 14px; }

.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { border: 1.5px solid var(--sage); background: rgba(255, 255, 255, .55); color: var(--green); border-radius: 999px; padding: 9px 16px; cursor: pointer; font-weight: 700; font-size: 15px; display: inline-flex; align-items: center; gap: 8px; transition: .12s; }
.chip:hover { background: var(--sage-light); }
.chip.on { background: var(--green); border-color: var(--green); color: #fff; }
.chip svg { width: 18px; height: 18px; }

.check { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--line); background: #fff; cursor: pointer; font-weight: 700; color: var(--text); transition: .12s; }
.check:hover { border-color: var(--sage); }
.check .box { width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--sage); display: grid; place-items: center; flex: none; }
.check.on { border-color: var(--green); background: var(--sage-light); }
.check.on .box { background: var(--green); border-color: var(--green); }
.check.on .box::after { content: ""; width: 10px; height: 5px; border: 2.5px solid #fff; border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }
.check svg { width: 22px; height: 22px; color: var(--green); }

.seg { display: inline-flex; background: var(--card); border-radius: 14px; padding: 4px; gap: 4px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; padding: 10px 16px; border-radius: 11px; cursor: pointer; font-weight: 700; color: var(--muted); }
.seg button.on { background: #fff; color: var(--green); box-shadow: 0 2px 8px rgba(0, 0, 0, .06); }

.spinner { width: 28px; height: 28px; border: 3px solid var(--beige); border-top-color: var(--green); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.center-box { display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 60px 0; color: var(--muted); }

/* ---------- Лендинг / вход ---------- */
.landing-hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; padding: 36px 0 20px; }
.landing-hero .logo-big { width: 300px; }
.landing-hero .mission { margin-top: 24px; font-size: 19px; color: var(--green); max-width: 560px; }
.landing-hero .mission b { color: var(--burgundy); }
.tags { margin-top: 18px; color: var(--burgundy); font-weight: 700; letter-spacing: .02em; }
.auth-card { position: relative; border-radius: 28px; overflow: hidden; min-height: 600px; box-shadow: var(--shadow); color: #fff; display: flex; flex-direction: column; }
.auth-card .bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.auth-card .bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 35, 10, .55) 0%, rgba(20, 35, 10, .15) 40%, rgba(20, 35, 10, .78) 100%); }
.auth-card .inner { position: relative; padding: 38px 40px; display: flex; flex-direction: column; height: 100%; flex: 1; }
.auth-card h2 { color: #fff; font-size: 34px; text-align: center; }
.auth-card .sub { text-align: center; margin-top: 8px; opacity: .92; }
.auth-card form { margin-top: auto; }
.auth-card .input { background: rgba(255, 255, 255, .96); border-color: transparent; }
.auth-card .links { display: flex; justify-content: center; gap: 18px; margin-top: 14px; font-size: 14px; }
.auth-card .links a { color: #fff; }
.auth-card .error-box { background: rgba(244, 221, 214, .95); }
.auth-card .tabs { display: flex; background: rgba(255, 255, 255, .18); border-radius: 14px; padding: 4px; margin-bottom: 18px; }
.auth-card .tabs button { flex: 1; border: 0; background: transparent; color: #fff; padding: 10px; border-radius: 11px; cursor: pointer; font-weight: 700; }
.auth-card .tabs button.on { background: #fff; color: var(--green); }

.solution { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; margin-top: 30px; }
.sol { display: flex; gap: 16px; align-items: center; }
.sol .ic { position: relative; flex: none; }
.sol .ic img { width: 92px; height: 92px; object-fit: contain; }
.sol .num { position: absolute; top: -6px; right: -6px; }
.num { width: 34px; height: 34px; border-radius: 50%; background: #C08A7E; color: #fff; display: grid; place-items: center; font-family: var(--serif); font-weight: 700; font-size: 17px; box-shadow: 0 0 0 4px rgba(249, 245, 234, .9); }
.sol p { color: var(--burgundy); font-size: 15px; }

.compare { display: flex; align-items: center; gap: 26px; margin-top: 34px; }
.compare .box { background: rgba(226, 211, 188, .75); border-radius: 26px; padding: 18px 28px; }
.compare .box.g { background: rgba(228, 232, 219, .9); }
.compare .big { font-family: var(--serif); font-weight: 700; font-size: 54px; line-height: 1; color: var(--burgundy); }
.compare .box.g .big { color: var(--green); }
.compare .big small { font-size: 22px; }
.compare .cap { color: var(--ochre); font-size: 14px; margin-top: 4px; max-width: 210px; }
.compare .mid { text-align: center; color: var(--burgundy); font-weight: 700; }
.compare .mid .arrow { width: 90px; height: 16px; background: var(--sage); clip-path: polygon(0 30%, 80% 30%, 80% 0, 100% 50%, 80% 100%, 80% 70%, 0 70%); margin: 6px auto; }

/* Путь из 5 шагов (слайд «Продукт») */
.path { position: relative; display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-top: 34px; }
.path::before { content: ""; position: absolute; left: 10%; right: 10%; top: 78px; border-top: 3px dashed var(--burgundy); opacity: .55; }
.path .step { text-align: center; position: relative; }
.path .step .lbl { font-weight: 700; color: var(--burgundy); min-height: 50px; display: flex; align-items: flex-end; justify-content: center; font-size: 16px; }
.path .step .num { margin: 12px auto 0; width: 42px; height: 42px; font-size: 20px; }
.path .step .txt { color: var(--muted); font-size: 14px; margin-top: 12px; padding: 0 8px; }
.path-end { display: flex; align-items: center; gap: 22px; justify-content: center; margin-top: 30px; }
.path-end .pill { font-family: var(--serif); font-weight: 700; color: var(--green); font-size: 22px; text-align: center; }
.path-end img { height: 120px; }

.regions-strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 18px; margin-top: 24px; }

/* ---------- Стeppers в мастере ---------- */
.stepper { display: flex; align-items: flex-start; gap: 0; margin: 8px 0 34px; }
.stepper .s { display: flex; flex-direction: column; align-items: center; flex: 1; position: relative; text-align: center; }
.stepper .s:not(:last-child)::after { content: ""; position: absolute; top: 19px; left: calc(50% + 26px); right: calc(-50% + 26px); border-top: 3px dashed var(--beige); }
.stepper .s.done:not(:last-child)::after { border-color: var(--sage); }
.stepper .dot { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--beige); color: var(--muted); font-family: var(--serif); font-weight: 700; font-size: 18px; }
.stepper .s.done .dot { background: var(--sage); color: #fff; }
.stepper .s.cur .dot { background: var(--burgundy); color: #fff; box-shadow: 0 0 0 5px rgba(108, 0, 0, .12); }
.stepper .s span { margin-top: 8px; font-size: 14px; font-weight: 700; color: var(--muted); max-width: 150px; }
.stepper .s.cur span { color: var(--burgundy); }
.stepper .dot svg { width: 20px; height: 20px; }

/* ---------- Главная ---------- */
.home-hero { display: grid; grid-template-columns: 1fr 480px; gap: 40px; align-items: stretch; }
.new-trip { background: var(--green); color: #fff; border-radius: 28px; padding: 32px 34px; position: relative; overflow: hidden; display: flex; flex-direction: column; }
.new-trip h3 { color: #fff; font-size: 28px; }
.new-trip p { opacity: .9; margin-top: 8px; }
.new-trip .btn { margin-top: auto; }
.new-trip .gen { font-size: 14px; opacity: .85; margin-top: 12px; text-align: center; }
.new-trip::after { content: ""; position: absolute; right: -70px; bottom: -90px; width: 170px; height: 170px; border: 3px solid var(--ochre); border-radius: 50%; opacity: .5; }
.hello h1 { color: var(--burgundy); }

.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.route-card { background: var(--card); border-radius: var(--radius); overflow: hidden; cursor: pointer; transition: .18s; text-decoration: none; color: inherit; display: flex; flex-direction: column; }
.route-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.route-card .ph { height: 190px; background: var(--beige) center / cover; position: relative; }
.route-card .badge { position: absolute; left: 14px; top: 14px; background: #fff; color: var(--green); border-radius: 999px; padding: 5px 12px; font-size: 13px; font-weight: 700; display: inline-flex; gap: 6px; align-items: center; }
.route-card .badge svg { width: 14px; height: 14px; }
.route-card .body { padding: 18px 20px 20px; }
.route-card h4 { font-size: 20px; }
.meta { display: flex; flex-wrap: wrap; gap: 14px; color: var(--muted); font-size: 14px; margin-top: 8px; }
.meta span { display: inline-flex; align-items: center; gap: 6px; }
.meta svg { width: 16px; height: 16px; color: var(--sage); }
.price { color: var(--burgundy); font-weight: 700; font-size: 15px; margin-top: 10px; }
.empty { text-align: center; padding: 50px 30px; }
.empty img { height: 150px; margin: 0 auto 16px; }

/* ---------- Новый маршрут ---------- */
.two-col { display: grid; grid-template-columns: 1fr 420px; gap: 40px; align-items: start; }
.side { position: sticky; top: 108px; }
.side-panel { padding: 26px 26px 22px; }
.side-panel h4 { font-size: 19px; margin: 18px 0 10px; }
.side-panel h4:first-child { margin-top: 0; }
.dest { display: flex; gap: 14px; align-items: center; background: #fff; border-radius: 16px; padding: 12px; border: 1.5px solid var(--line); }
.dest .ph { width: 64px; height: 64px; border-radius: 12px; background: var(--beige) center / cover; flex: none; display: grid; place-items: center; color: var(--sage); }
.dest b { font-family: var(--serif); color: var(--green); font-size: 18px; display: block; }
.dates { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.city-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.city { position: relative; height: 200px; border-radius: 20px; overflow: hidden; cursor: pointer; background: var(--beige) center / cover; border: 0; padding: 0; text-align: left; box-shadow: 0 0 0 0 var(--green); transition: .15s; }
.city::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 40%, rgba(15, 30, 5, .78)); }
.city .t { position: absolute; left: 16px; bottom: 14px; right: 16px; z-index: 1; color: #fff; }
.city .t b { font-family: var(--serif); font-size: 22px; display: block; }
.city .t small { opacity: .9; }
.city:hover { transform: translateY(-2px); }
.city.on { box-shadow: 0 0 0 4px var(--green); }
.city.on::before { content: "✓"; position: absolute; top: 12px; right: 12px; z-index: 2; width: 32px; height: 32px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; font-weight: 700; }
.region-desc { margin-top: 18px; padding: 18px 22px; }
.toggle-row { display: flex; align-items: center; gap: 12px; cursor: pointer; margin-top: 14px; font-weight: 700; color: var(--green); }
.switch { width: 46px; height: 26px; border-radius: 13px; background: var(--beige); position: relative; transition: .15s; flex: none; }
.switch::after { content: ""; position: absolute; left: 3px; top: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: .15s; }
.switch.on { background: var(--green); }
.switch.on::after { left: 23px; }

/* ---------- Генерация ---------- */
.gen-screen { max-width: 780px; margin: 30px auto; padding: 50px 56px; text-align: center; }
.gen-screen h2 { color: var(--text); font-size: 30px; }
.progress { height: 8px; background: var(--beige); border-radius: 4px; overflow: hidden; margin: 26px auto; max-width: 520px; }
.progress i { display: block; height: 100%; background: var(--green); border-radius: 4px; transition: width .5s; }
.stages { display: flex; justify-content: center; align-items: center; gap: 14px; margin: 28px 0 10px; flex-wrap: wrap; }
.stage { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-weight: 700; }
.stage .ok { width: 26px; height: 26px; border-radius: 50%; background: var(--beige); display: grid; place-items: center; color: #fff; }
.stage.done .ok { background: var(--sage); }
.stage.cur .ok { background: transparent; border: 3px solid var(--beige); border-top-color: var(--green); animation: spin 1s linear infinite; }
.stage.done, .stage.cur { color: var(--green); }
.stages .sep { width: 36px; height: 2px; background: var(--beige); }
.gen-screen .hiker { height: 130px; margin: 26px auto 0; opacity: .9; }

/* ---------- Маршрут ---------- */
.route-head { display: flex; align-items: flex-end; gap: 20px; }
.route-head h1 { color: var(--burgundy); font-size: 40px; }
.route-head .sub { font-family: var(--serif); color: var(--green); font-size: 22px; margin-top: 6px; font-weight: 700; }
.route-head .actions { margin-left: auto; display: flex; gap: 10px; }
.info-strip { display: flex; flex-wrap: wrap; gap: 26px; align-items: center; padding: 18px 26px; margin-top: 22px; }
.info-strip .it { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); }
.info-strip .it b { color: var(--text); }
.info-strip .it svg { width: 19px; height: 19px; color: var(--sage); }
.info-strip .cost { margin-left: auto; font-family: var(--serif); font-size: 26px; font-weight: 700; color: var(--burgundy); }
.summary { margin-top: 14px; color: var(--muted); max-width: 900px; }
.day-tabs { display: flex; gap: 10px; margin: 30px 0 20px; flex-wrap: wrap; }
.day-head { margin-bottom: 18px; }
.day-head h3 { font-size: 28px; }
.route-layout { display: grid; grid-template-columns: 1fr 440px; gap: 34px; align-items: start; }
.stops { display: flex; flex-direction: column; gap: 16px; }
.stop { display: grid; grid-template-columns: 250px 1fr; background: var(--card); border-radius: var(--radius); overflow: hidden; min-height: 176px; }
.stop .ph { background: var(--beige) center / cover; position: relative; display: grid; place-items: center; color: var(--sage); }
.stop .ph svg { width: 48px; height: 48px; }
.stop .ph .num { position: absolute; left: 14px; top: 14px; background: var(--green); width: 36px; height: 36px; box-shadow: 0 0 0 3px #fff; }
.stop .body { padding: 18px 22px; display: flex; flex-direction: column; gap: 6px; }
.stop .cat { display: inline-flex; gap: 6px; align-items: center; color: var(--sage); font-size: 13px; font-weight: 700; text-transform: none; }
.stop .cat svg { width: 16px; height: 16px; }
.stop h4 { font-size: 21px; }
.stop .time { margin-left: auto; background: #fff; color: var(--burgundy); border-radius: 999px; padding: 5px 12px; font-size: 13px; font-weight: 700; display: inline-flex; gap: 6px; align-items: center; }
.stop .time svg { width: 14px; height: 14px; }
.stop .note { color: var(--muted); font-size: 15px; }
.stop .btns { display: flex; gap: 6px; margin-top: auto; padding-top: 6px; }
.stop .edit { display: flex; gap: 4px; margin-left: auto; }
.icon-btn { width: 36px; height: 36px; border-radius: 10px; border: 0; background: #fff; color: var(--green); cursor: pointer; display: grid; place-items: center; }
.icon-btn:hover { background: var(--sage-light); }
.icon-btn:disabled { opacity: .35; cursor: default; }
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn.del { color: var(--error); }
.break { display: flex; align-items: center; gap: 14px; padding: 12px 22px; border: 2px dashed var(--beige); border-radius: 18px; color: var(--muted); }
.break svg { width: 22px; height: 22px; color: var(--ochre); }
.break b { color: var(--text); }
.map-box { height: 460px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: #e8e4da; }
.tips { padding: 22px 24px; margin-top: 18px; }
.tips h3 { margin-bottom: 12px; }
.tips ul { margin: 0; padding-left: 20px; }
.tips li { margin: 8px 0; color: var(--text); }
.tips li::marker { color: var(--ochre); }
.map-pin { width: 32px; height: 32px; border-radius: 50%; background: var(--green); color: #fff; font-weight: 700; display: grid; place-items: center; border: 3px solid #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, .3); font-family: var(--sans); font-size: 14px; }

/* ---------- Каталог ---------- */
.catalog { display: grid; grid-template-columns: 300px 1fr; gap: 34px; align-items: start; }
.filters { padding: 22px; position: sticky; top: 108px; max-height: calc(100vh - 130px); overflow: auto; }
.filters h4 { font-size: 17px; margin: 18px 0 10px; }
.filters h4:first-child { margin-top: 0; }
.flist { display: flex; flex-direction: column; gap: 4px; }
.flist button { text-align: left; border: 0; background: transparent; padding: 9px 12px; border-radius: 11px; cursor: pointer; display: flex; align-items: center; gap: 10px; color: var(--text); }
.flist button:hover { background: var(--card); }
.flist button.on { background: var(--green); color: #fff; }
.flist button svg { width: 18px; height: 18px; color: var(--sage); flex: none; }
.flist button.on svg { color: #fff; }
.flist button small { margin-left: auto; opacity: .7; }
.flist .grp { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 10px 12px 4px; }
.place-card { background: var(--card); border-radius: var(--radius); overflow: hidden; cursor: pointer; transition: .18s; display: flex; flex-direction: column; }
.place-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.place-card .ph { height: 180px; background: var(--beige) center / cover; display: grid; place-items: center; color: var(--sage); }
.place-card .ph svg { width: 46px; height: 46px; }
.place-card .body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.place-card h4 { font-size: 18px; }
.place-card p { color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.place-card .foot { margin-top: auto; color: var(--burgundy); font-weight: 700; font-size: 13px; padding-top: 6px; }

/* ---------- Профиль ---------- */
.profile { display: grid; grid-template-columns: 380px 1fr; gap: 30px; align-items: start; }
.profile .who { padding: 30px; text-align: center; }
.profile .who .avatar { width: 96px; height: 96px; font-size: 40px; margin: 0 auto 14px; cursor: default; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 18px 0; }
.stats div { background: #fff; border-radius: 16px; padding: 14px 8px; text-align: center; }
.stats b { font-family: var(--serif); font-size: 30px; color: var(--burgundy); display: block; }
.stats small { color: var(--muted); }
.kv { display: grid; grid-template-columns: 180px 1fr; gap: 12px 20px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 700; }
.q-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }

/* ---------- Модальные окна ---------- */
.overlay { position: fixed; inset: 0; background: rgba(30, 25, 15, .45); z-index: 100; display: grid; place-items: center; padding: 30px; animation: fade .15s; }
@keyframes fade { from { opacity: 0; } }
.modal { background: var(--cream); border-radius: 26px; width: min(720px, 100%); max-height: calc(100vh - 60px); overflow: auto; box-shadow: 0 30px 80px rgba(0, 0, 0, .3); position: relative; }
.modal.sm { width: min(480px, 100%); }
.modal .mbody { padding: 30px 34px; }
.modal .close { position: absolute; right: 16px; top: 16px; z-index: 3; width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .9); cursor: pointer; display: grid; place-items: center; }
.modal .close svg { width: 20px; height: 20px; }
.modal .hero { height: 300px; background: var(--beige) center / cover; }
.modal .mfoot { display: flex; gap: 10px; justify-content: flex-end; margin-top: 22px; }
.place-info { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 24px; margin: 18px 0; }
.place-info div { display: flex; gap: 10px; color: var(--muted); font-size: 15px; }
.place-info svg { width: 19px; height: 19px; color: var(--sage); flex: none; margin-top: 2px; }
.mini-map { height: 220px; border-radius: 16px; overflow: hidden; margin-top: 16px; }

#toast-root { position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast { background: var(--green-dark); color: #fff; padding: 13px 22px; border-radius: 14px; box-shadow: var(--shadow); animation: fade .2s; }
.toast.err { background: var(--error); }

.leaflet-container { font-family: var(--sans); }
.leaflet-div-icon { background: transparent; border: 0; }

@media (max-width: 1240px) {
  .grid-4 { grid-template-columns: repeat(3, 1fr); }
  .route-layout { grid-template-columns: 1fr 380px; }
  .stop { grid-template-columns: 200px 1fr; }
  .city-grid { grid-template-columns: repeat(2, 1fr); }
  .home-hero { grid-template-columns: 1fr 420px; }
}

/* Небольшие окна на ПК и планшеты */
@media (max-width: 1100px) {
  .wrap { width: calc(100% - 48px); }
  .topbar .wrap { gap: 18px; }
  .nav a { padding: 10px 12px; }
  .chip-gen { display: none; }
  .landing-hero { grid-template-columns: 1fr; }
  .auth-card { min-height: 520px; max-width: 620px; width: 100%; margin: 0 auto; }
  .home-hero { grid-template-columns: 1fr; }
  .two-col, .route-layout, .profile { grid-template-columns: 1fr; }
  .side { position: static; }
  .catalog { grid-template-columns: 240px 1fr; gap: 20px; }
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .solution { grid-template-columns: 1fr; }
  .q-grid { grid-template-columns: repeat(2, 1fr); }
  .path { grid-template-columns: repeat(5, 1fr); }
  .footer .wrap { flex-wrap: wrap; }
  .footer .links { margin-left: 0; flex-wrap: wrap; }
  h1 { font-size: 36px; }
}
@media (max-width: 860px) {
  .nav a svg { display: none; }
  .catalog { grid-template-columns: 1fr; }
  .filters { position: static; max-height: none; }
  .stop { grid-template-columns: 170px 1fr; }
  .city-grid { grid-template-columns: repeat(2, 1fr); }
}

.map-locate { position: absolute; right: 12px; bottom: 28px; z-index: 500; width: 42px; height: 42px; border-radius: 50%; border: 0; background: #fff; color: var(--green); box-shadow: 0 2px 10px rgba(0,0,0,.2); cursor: pointer; display: grid; place-items: center; }
.map-locate:hover { background: var(--sage-light); }
.me-dot { width: 40px; height: 40px; border-radius: 50%; background: rgba(47,128,237,.18); display: grid; place-items: center; }
.me-dot::after { content: ""; width: 16px; height: 16px; border-radius: 50%; background: #2F80ED; border: 3px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.35); }
