/* Лендінг chepeti.com. Кольори, шрифт і скруглення — з токенів застосунку (chepeti-app/src/theme/tokens.ts, акцент sage),
   щоб сайт і застосунок виглядали одним продуктом. Радіуси: кнопки — pill, картки й рамки — 22px, телефон — 38px. */
@font-face { font-family: Mulish; src: url(fonts/Mulish_400Regular.ttf) format('truetype'); font-weight: 400; font-display: swap; }
@font-face { font-family: Mulish; src: url(fonts/Mulish_600SemiBold.ttf) format('truetype'); font-weight: 600; font-display: swap; }
@font-face { font-family: Mulish; src: url(fonts/Mulish_700Bold.ttf) format('truetype'); font-weight: 700; font-display: swap; }
/* Заголовки h1–h3 — Shantell Sans 600 (власник 18.11), лежить на сайті, не з Google Fonts: щоб Google не бачив відвідувачів. Ліцензія OFL. */
@font-face { font-family: 'Shantell Sans'; src: url(fonts/ShantellSans_600_cyrillic.woff2) format('woff2'); font-weight: 600; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Shantell Sans'; src: url(fonts/ShantellSans_600_latin.woff2) format('woff2'); font-weight: 600; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --paper: #FAF8F5; --paper2: #F3ECE1; --surface: #FFFFFF; --surface2: #F6F0E7;
  --ink: #2C2722; --ink2: #6E655B; --ink3: #8F8579;
  --line: rgba(44, 39, 34, .08);
  --accent: #5E7E6B; --accent-deep: #3F5A4A; --accent-on: #FFFFFF; --accent-tint: #E1E4DF;
  --danger: #BD4F32; --danger-tint: #FAE7DE;
  --ill-paper: #FFFFFF; --ill-cream: #F6F0E7; --ill-ink: #2C2722; --ill-tint: #E1E4DF;
  --shadow: 0 24px 60px -24px rgba(63, 90, 74, .35);
  --r: 22px; --r-phone: 38px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #19120E; --paper2: #221913; --surface: #241B14; --surface2: #2E241B;
    --ink: #F3EBE0; --ink2: #B7AB9C; --ink3: #9A8F81;
    --line: rgba(243, 235, 224, .09);
    --accent: #82A88E; --accent-deep: #A9C7B2; --accent-on: #16221A; --accent-tint: #30332A;
    --danger: #E07A5F; --danger-tint: #3A231A;
    --ill-paper: #E2D5C4; --ill-cream: #5E4D3F; --ill-ink: #241A13; --ill-tint: rgba(48, 51, 42, .55);
    --shadow: 0 24px 60px -24px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
    --paper: #19120E; --paper2: #221913; --surface: #241B14; --surface2: #2E241B;
    --ink: #F3EBE0; --ink2: #B7AB9C; --ink3: #9A8F81;
    --line: rgba(243, 235, 224, .09);
    --accent: #82A88E; --accent-deep: #A9C7B2; --accent-on: #16221A; --accent-tint: #30332A;
    --danger: #E07A5F; --danger-tint: #3A231A;
    --ill-paper: #E2D5C4; --ill-cream: #5E4D3F; --ill-ink: #241A13; --ill-tint: rgba(48, 51, 42, .55);
    --shadow: 0 24px 60px -24px rgba(0, 0, 0, .6);
    color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.6 Mulish, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--accent-deep); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
.wrap { width: min(1160px, 100% - 40px); margin-inline: auto; }
h1, h2, h3 { text-wrap: balance; margin: 0; font-weight: 700; letter-spacing: -.02em; line-height: 1.12; }
h1, h2, h3 { font-family: 'Shantell Sans', Mulish, sans-serif; font-weight: 600; letter-spacing: -.01em; }
h1 { font-size: clamp(2.3rem, 4.4vw, 3.5rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); }
h3 { font-size: 1.25rem; letter-spacing: -.01em; }
p { margin: 0; }
.lead { text-wrap: balance; color: var(--ink2); font-size: 1.15rem; max-width: 34ch; }
.sub { color: var(--ink2); max-width: 46ch; }
.eyebrow { font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }

/* Шапка */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--paper) 88%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid transparent; transition: border-color .3s; }
.top.scrolled { border-bottom-color: var(--line); }
.top .wrap { display: flex; align-items: center; gap: 28px; height: 68px; }
.brand { display: flex; align-items: center; color: var(--accent); text-decoration: none; }
.brand svg { height: 30px; width: auto; display: block; }
.top nav { display: flex; gap: 24px; margin-left: auto; }
.top nav a { color: var(--ink2); text-decoration: none; font-weight: 600; font-size: .95rem; }
.top nav a:hover { color: var(--ink); }
.lang { font-weight: 700; font-size: .85rem; color: var(--ink2); text-decoration: none; border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; }

/* Кнопки */
.btn { display: inline-flex; align-items: center; gap: 10px; border-radius: 999px; padding: 14px 24px; font: 700 1rem Mulish, sans-serif; text-decoration: none; white-space: nowrap; transition: transform .2s cubic-bezier(.16,1,.3,1), background .2s; }
.btn:active { transform: scale(.98); }
.btn img { width: 20px; height: 20px; }
.btn-primary { background: var(--accent); color: var(--accent-on); }
.btn-primary:hover { background: var(--accent-deep); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn img.mono { filter: invert(1); } }
:root[data-theme="dark"] .btn img.mono { filter: invert(1); }
.btn-soon { background: var(--surface2); color: var(--ink2); cursor: default; }
.btn-soon small { font-weight: 600; color: var(--ink3); }
.btn-sm { padding: 9px 18px; font-size: .9rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Телефон: справжній скриншот у рамці */
.phone { position: relative; width: 100%; max-width: 300px; aspect-ratio: 1080 / 2400; border-radius: var(--r-phone); padding: 9px; background: #1E1915; box-shadow: var(--shadow); }
.phone img { width: 100%; height: 100%; object-fit: cover; border-radius: calc(var(--r-phone) - 9px); }

/* 1. Перший екран */
.hero { padding: clamp(32px, 6vw, 72px) 0 clamp(48px, 7vw, 96px); }
.hero .wrap { display: grid; grid-template-columns: 1.15fr .85fr; align-items: center; gap: 48px; }
.hero h1 { max-width: 17ch; }
.hero .lead { margin: 20px 0 32px; }
.hero-art { position: relative; justify-self: center; width: min(100%, 440px); }
.hero-art .ill { position: absolute; left: -26%; bottom: -4%; width: 62%; }
.hero-art .phone { margin-left: auto; max-width: 268px; }

/* 2. Загубився: суцільна тонована смуга */
.lost { background: var(--accent-tint); padding: clamp(56px, 8vw, 112px) 0; }
.lost .wrap { display: grid; grid-template-columns: .85fr 1.15fr; gap: 56px; align-items: center; }
.lost h2 { max-width: 16ch; }
.lost .sub { margin: 18px 0 28px; }
.steps { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 14px; counter-reset: s; }
.steps li { display: grid; grid-template-columns: 34px 1fr; gap: 12px; align-items: start; counter-increment: s; }
.steps li::before { content: counter(s); display: grid; place-items: center; width: 34px; height: 34px; border-radius: 999px; background: var(--surface); color: var(--accent-deep); font-weight: 700; }

/* 3. Ліки: два телефони внахльост */
.meds { padding: clamp(64px, 9vw, 128px) 0; }
.meds .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.pair { position: relative; height: clamp(440px, 52vw, 600px); }
.pair .phone { position: absolute; max-width: 250px; }
.pair .phone:first-child { left: 0; top: 0; }
.pair .phone:last-child { right: 4%; bottom: 0; }
.meds h2 { max-width: 15ch; }
.meds .sub { margin: 18px 0 24px; }
.note { color: var(--ink2); font-size: .95rem; max-width: 44ch; padding: 14px 18px; background: var(--surface2); border-radius: 16px; }
.note b { color: var(--ink); }

/* 4. Аналізи: текст зверху, кадр графіка по центру */
.tests { padding: clamp(56px, 8vw, 104px) 0; background: var(--paper2); }
.tests .wrap { display: grid; justify-items: center; text-align: center; gap: 18px; }
.tests .sub { margin-inline: auto; }
.tests .phone { max-width: 290px; margin-top: 20px; }

/* 5. Разом з сімʼєю: ілюстрація власника */
.family { padding: clamp(64px, 9vw, 120px) 0; }
.family .wrap { display: grid; grid-template-columns: .9fr 1.1fr; gap: 48px; align-items: center; }
.family .ill { width: min(100%, 460px); }
.family .sub { margin: 18px 0 0; }

/* 6. Решта: бенто з 6 клітинок (6 тем — 6 клітинок) */
.more { padding: clamp(48px, 7vw, 96px) 0; }
.more h2 { max-width: 18ch; margin-bottom: 32px; }
.bento { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: minmax(150px, auto); gap: 16px; }
.cell { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 24px; display: flex; flex-direction: column; gap: 8px; overflow: hidden; }
.cell p { color: var(--ink2); font-size: .95rem; }
.cell.shot { grid-row: span 2; padding-bottom: 0; }
.cell.shot img { margin-top: auto; width: 100%; border-radius: 16px 16px 0 0; border: 1px solid var(--line); border-bottom: 0; }
.cell.tint { background: var(--accent-tint); border-color: transparent; }
.cell.wide { grid-column: span 2; }

/* 7. Приватність */
.privacy { padding: clamp(56px, 8vw, 104px) 0; border-top: 1px solid var(--line); }
.privacy .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.privacy .ill { width: min(100%, 400px); justify-self: end; }
.facts { margin-top: 28px; display: grid; gap: 22px; }
.facts div { padding-left: 18px; border-left: 3px solid var(--accent); }
.facts p { color: var(--ink2); font-size: .97rem; margin-top: 4px; }

/* 8. Безкоштовно і Premium */
.plans { padding: clamp(56px, 8vw, 104px) 0; background: var(--paper2); }
.plans h2 { text-align: center; }
.plans .sub { text-align: center; margin: 14px auto 40px; }
.cols { display: grid; grid-template-columns: 1fr 1.25fr; gap: 20px; max-width: 900px; margin-inline: auto; }
.plan { background: var(--surface); border-radius: var(--r); padding: 32px; border: 1px solid var(--line); }
.plan.premium { border: 2px solid var(--accent); }
.plan h3 { font-size: 1.4rem; }
.plan .price { color: var(--ink2); margin: 6px 0 20px; font-weight: 600; }
.plan ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.plan li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; }
.plan li::before { content: ""; width: 6px; height: 11px; margin: 5px 0 0 6px; border: solid var(--accent); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }

/* 9. Питання */
.faq { padding: clamp(56px, 8vw, 104px) 0; }
.faq .wrap { max-width: 760px; }
.faq h2 { margin-bottom: 28px; }
details { border-bottom: 1px solid var(--line); }
summary { cursor: pointer; list-style: none; padding: 20px 40px 20px 0; font-weight: 700; font-size: 1.08rem; position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 4px; top: 16px; font-size: 1.5rem; font-weight: 400; color: var(--accent); transition: transform .25s; }
details[open] summary::after { transform: rotate(45deg); }
details p { color: var(--ink2); padding-bottom: 22px; max-width: 62ch; }

/* 10. Фінал і підвал */
.final { padding: clamp(56px, 8vw, 96px) 0; }
.final .wrap { background: var(--accent); color: var(--accent-on); border-radius: calc(var(--r) + 10px); padding: clamp(36px, 6vw, 64px); display: grid; grid-template-columns: 1fr auto; gap: 32px; align-items: center; }
.final p { opacity: .9; margin-top: 10px; max-width: 40ch; }
.final .btn-primary { background: var(--accent-on); color: var(--accent-deep); }
.final .btn-primary:hover { background: var(--paper); }
.final .btn img.mono { filter: none; }
:root .final .btn img.mono { filter: none; }
footer { padding: 40px 0 56px; color: var(--ink2); font-size: .92rem; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; }
footer a { color: var(--ink2); }
footer .copy { margin-left: auto; }

/* Поява блоків під час прокрутки: лише transform і opacity; без «зменшити рух» — одразу видно */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s cubic-bezier(.16,1,.3,1), transform .8s cubic-bezier(.16,1,.3,1); transition-delay: calc(var(--i, 0) * 90ms); }
  .js .reveal.in { opacity: 1; transform: none; }
}

/* Телефон: одна колонка */
@media (max-width: 860px) {
  body { font-size: 16px; }
  .top nav { display: none; }
  .top .btn-sm { margin-left: auto; }
  .hero .wrap, .lost .wrap, .meds .wrap, .family .wrap, .privacy .wrap, .cols, .final .wrap { grid-template-columns: 1fr; }
  .hero-art { width: min(100%, 340px); }
  .lost-visual { order: 2; justify-content: center; }
  .pair { height: 470px; max-width: 380px; margin-inline: auto; order: 2; }
  .pair .phone { max-width: 210px; }
  .family .ill, .privacy .ill { justify-self: center; width: min(100%, 320px); }
  .bento { grid-template-columns: 1fr 1fr; }
  .cell.wide { grid-column: span 2; }
  .final .wrap { text-align: left; }
  footer .copy { margin-left: 0; width: 100%; }
}
@media (max-width: 520px) {
  .bento { grid-template-columns: 1fr; }
  .cell.wide { grid-column: auto; }
  .cell.shot { grid-row: auto; }
  .btn { padding: 13px 20px; }
}

/* Перемикач теми */
.theme { width: 38px; height: 38px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--ink2); display: grid; place-items: center; cursor: pointer; }
.theme:hover { color: var(--ink); }
.theme i { width: 18px; height: 18px; background: currentColor; -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat; }
.theme .sun { --ic: url(/assets/icons/sun.svg); }
.theme .moon { --ic: url(/assets/icons/moon.svg); }
.theme .moon { display: none; }
:root[data-theme="dark"] .theme .sun { display: none; }
:root[data-theme="dark"] .theme .moon { display: block; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .theme .sun { display: none; } :root:not([data-theme="light"]) .theme .moon { display: block; } }

/* Тур застосунком: перший екран + картка з телефоном, екрани міняються під час прокрутки (GSAP, tour.js).
   Без JS чи з «зменшити рух» — статичний варіант нижче: заголовок, потім картка з першим кадром і списком підписів. */
.tour { position: relative; }
.tour-stage { position: relative; }
.tour-intro { padding: clamp(40px, 7vw, 88px) 0 clamp(32px, 5vw, 56px); text-align: center; }
.tour-intro h1 { max-width: 20ch; margin-inline: auto; font-size: clamp(2.3rem, 5vw, 4.2rem); }
.tour-intro .lead { margin: 20px auto 32px; text-align: center; max-width: 56ch; }
.tour-intro .cta-row { justify-content: center; }
.cta-note { margin: 12px 0 0; font-size: .85rem; color: var(--ink3); }
.tour-intro .ill { width: min(60vw, 230px); margin: 28px auto 0; }
.tour-card { margin: 0 auto clamp(48px, 7vw, 96px); width: min(1160px, 100% - 40px); border-radius: 40px; overflow: hidden; color: #F4F1EC;
  background: radial-gradient(120% 90% at 85% 0%, #7C9C88 0%, transparent 55%), linear-gradient(150deg, #5E7E6B 0%, #3F5A4A 70%, #34503F 100%);
  box-shadow: 0 50px 100px -40px rgba(40, 60, 48, .55); }
:root[data-theme="dark"] .tour-card { background: radial-gradient(120% 90% at 85% 0%, #3E5547 0%, transparent 55%), linear-gradient(150deg, #2C3E33 0%, #1D2A22 100%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tour-card { background: radial-gradient(120% 90% at 85% 0%, #3E5547 0%, transparent 55%), linear-gradient(150deg, #2C3E33 0%, #1D2A22 100%); } }
.tour-grid { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 40px; padding: clamp(32px, 5vw, 64px); min-height: 100%; }
.tour-texts { display: grid; gap: 28px; }
.tour-texts h3 { font-size: clamp(1.5rem, 2.6vw, 2.2rem); color: #fff; }
.tour-texts p { color: rgba(244, 241, 236, .78); margin-top: 10px; max-width: 30ch; }
.tour-phone { position: relative; width: min(clamp(220px, 22vw, 290px), (100svh - 68px - 4vh - 80px) * .45); aspect-ratio: 1080 / 2400; border-radius: 40px; padding: 9px; background: #14110E;
  box-shadow: inset 0 0 0 1.5px #4A443D, 0 40px 80px -20px rgba(0,0,0,.6), 0 12px 24px -8px rgba(0,0,0,.4); transform-style: preserve-3d; will-change: transform; }
.tour-phone .screens { position: relative; width: 100%; height: 100%; border-radius: 31px; overflow: hidden; background: #FAF8F5; }
.tour-phone img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.tour-phone img + img { opacity: 0; }
.tour-phone::after { content: ""; position: absolute; inset: 9px; border-radius: 31px; pointer-events: none; background: linear-gradient(115deg, rgba(255,255,255,.12) 0%, rgba(255,255,255,0) 40%); }
.tour-badges { position: relative; align-self: stretch; }
.badge-set { display: grid; grid-template-columns: max-content; justify-items: start; gap: 12px; align-content: center; height: 100%; }
.badge-set .badge:nth-child(even) { margin-left: 48px; }
.badge { display: flex; align-items: center; gap: 12px; padding: 12px 16px 12px 12px; border-radius: 18px; color: #fff;
  /* Без backdrop-filter (17.11): під плашками рівний градієнт картки, розмиття там не видно, а на ПК воно перемальовувалось
     на кожному кадрі прокрутки й гальмувало тур. */
  background: linear-gradient(135deg, rgba(255,255,255,.17), rgba(255,255,255,.05));
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.17), 0 20px 40px -14px rgba(0,0,0,.45); }
.badge b { font-size: .95rem; font-weight: 700; line-height: 1.25; white-space: nowrap; }
.badge > i { flex: none; width: 38px; height: 38px; border-radius: 12px; background: rgba(255,255,255,.15); position: relative; }
.badge > i::after { content: ""; position: absolute; inset: 9px; background: #fff; -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat; }


.tour-steps { position: absolute; top: 26px; left: 0; right: 0; display: flex; justify-content: center; gap: 8px; z-index: 2; }
.tour-steps span { width: 22px; height: 4px; border-radius: 4px; background: rgba(255,255,255,.25); }
.tour-steps span.on { background: #fff; }
.tour-card { position: relative; }
.tour:not(.anim) .badge-set:not(:first-child) { display: none; }
.tour:not(.anim) .tour-steps { display: none; }

/* Анімований режим (клас .anim ставить tour.js): сцена на весь екран, картка й тексти керуються GSAP */
.tour.anim .tour-stage { height: 100svh; overflow: hidden; display: grid; place-items: center; }
.tour.anim .tour-intro { position: absolute; inset: 0; display: grid; align-content: center; padding-top: 68px; }
.tour.anim .tour-card { position: absolute; inset: 68px 0 0; margin: auto; width: 90vw; height: calc(100svh - 68px - 4vh); }
.tour.anim .tour-grid { height: 100%; }
.tour.anim .tour-texts { position: relative; height: 220px; }
.tour.anim .tour-texts > div { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; opacity: 0; }
.tour.anim .badge-set { position: absolute; inset: 0; }
.tour.anim .badge { opacity: 0; }

@media (max-width: 860px) {
  .tour-grid { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: 22px; padding: 28px 20px; }
  .tour-texts p { margin-inline: auto; }
  .tour-phone { width: min(56vw, 230px); }
  .tour-tilt { order: 2; }
  .tour-texts { order: 1; width: 100%; }
  .tour-badges { order: 3; min-height: 96px; width: 100%; }
  .badge-set { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; align-content: start; }
  .badge-set .badge:nth-child(even) { margin-left: 0; }
    .badge { padding: 8px 10px; gap: 8px; border-radius: 14px; max-width: none; }
  .badge > i { width: 28px; height: 28px; border-radius: 9px; } .badge > i::after { inset: 6px; }
  .badge b { font-size: .8rem; text-align: left; white-space: normal; }
  .badge-set .badge:nth-child(n+5) { display: none; }
  .tour:not(.anim) .tour-grid { grid-template-columns: 1fr; }
  .tour.anim .tour-texts { height: 130px; }
  .tour.anim .tour-texts h3 { font-size: 1.35rem; }
  .tour.anim .tour-card { width: 94vw; height: calc(100svh - 68px - 3vh); border-radius: 28px; }
  .tour-phone { width: min(56vw, 230px, (100svh - 68px - 3vh - 360px) * .45); }
  .tour-steps { top: 14px; }
}

.tour-tilt { transform-style: preserve-3d; }

/* Аналізи: телефон зі списком і картка графіка поруч (як QR у «Якщо загубився») */
.tests2 { padding: clamp(64px, 9vw, 120px) 0; }
.tests2 .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.tests2 .sub { margin: 18px 0 0; }
.tests-visual { position: relative; display: flex; justify-content: center; }
.tests-visual .phone { max-width: 260px; }
.chart-card { position: absolute; right: -2%; bottom: 8%; width: min(62%, 320px); margin: 0; background: #fff; border-radius: var(--r); padding: 10px 10px 14px; box-shadow: var(--shadow); }
.chart-card img { width: 100%; border-radius: 14px; }
.chart-card figcaption { margin-top: 8px; text-align: center; font-size: .82rem; color: #6E655B; font-weight: 600; }
@media (max-width: 860px) { .tests2 .wrap { grid-template-columns: 1fr; } .tests-visual .phone { max-width: 210px; margin-right: 30%; } .chart-card { width: 62%; right: 0; } }

/* «Документи»: віяло білих квадратів зі значками форматів (ті самі, що в застосунку) */
.cell.docs { position: relative; }
.formats { margin-top: auto; padding-top: 24px; display: flex; justify-content: center; align-items: flex-end; }
.formats span { width: 84px; height: 84px; border-radius: 22px; background: #fff; display: grid; place-items: center;
  box-shadow: 0 14px 30px -12px rgba(44, 39, 34, .35), 0 0 0 1px rgba(44, 39, 34, .05); margin: 0 -8px; transition: transform .3s cubic-bezier(.16,1,.3,1); }
.formats span:nth-child(1) { transform: rotate(-8deg) translateY(6px); }
.formats span:nth-child(2) { transform: translateY(-10px); z-index: 1; }
.formats span:nth-child(3) { transform: rotate(8deg) translateY(6px); }
.formats img { width: 56px; height: 56px; }
.cell.docs:hover .formats span:nth-child(1) { transform: rotate(-12deg) translate(-6px, 4px); }
.cell.docs:hover .formats span:nth-child(3) { transform: rotate(12deg) translate(6px, 4px); }

/* Аналізи: зони на рядках скриншота й підказка з графіком (analyses.js) */
.an-visual { flex-direction: column; align-items: flex-start; }
.an-visual .phone { position: relative; }
.an-spot { position: absolute; left: 5%; right: 5%; border: 0; padding: 0; background: transparent; border-radius: 16px; cursor: pointer;
  box-shadow: inset 0 0 0 2px transparent; transition: box-shadow .2s; }
.an-spot.on, .an-spot:hover, .an-spot:focus-visible { box-shadow: inset 0 0 0 2.5px var(--accent); }
.an-tip { position: absolute; left: 200px; top: calc(var(--top, 32%) - 2%); width: min(330px, calc(100% - 200px)); background: var(--surface); color: var(--ink);
  border-radius: var(--r); padding: 16px 16px 14px; box-shadow: var(--shadow), 0 0 0 1px var(--line); z-index: 2;
  transition: top .35s cubic-bezier(.16,1,.3,1); }
.an-tip.pop { animation: an-pop .35s cubic-bezier(.16,1,.3,1); }
@keyframes an-pop { from { opacity: 0; transform: translateY(6px) scale(.98); } }
@media (prefers-reduced-motion: reduce) { .an-tip, .an-tip.pop { animation: none; transition: none; } }
.an-title { font-weight: 700; display: flex; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.an-title span { font-weight: 400; color: var(--ink2); font-size: .85rem; }
.an-tabs { display: flex; gap: 6px; margin-bottom: 10px; }
.an-tabs button { border: 1px solid var(--line); background: transparent; color: var(--ink2); border-radius: 999px; padding: 5px 11px; font: 600 .8rem Mulish, sans-serif; cursor: pointer; }
.an-tabs button[aria-selected="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-on); }
.an-now { margin-bottom: 4px; color: var(--ink2); font-size: .9rem; }
.an-now b { font-size: 1.5rem; color: var(--ink); margin-right: 2px; }
.an-now span { margin-left: 10px; font-size: .8rem; }
.an-tip svg { width: 100%; height: auto; display: block; }
.an-tip svg text { font: 600 9px Mulish, sans-serif; fill: var(--ink3); }
.an-line { stroke-dasharray: 1; stroke-dashoffset: 1; animation: an-draw .8s .1s cubic-bezier(.16,1,.3,1) forwards; }
@keyframes an-draw { to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) { .an-line { animation: none; stroke-dashoffset: 0; } }
.an-norm, .an-note { color: var(--ink2); font-size: .82rem; margin-top: 6px; }
.an-vals { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.an-vals li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 12px; background: var(--surface2); border-radius: 12px; }
.an-vals b { color: #8A5A12; }
.an-hint { margin-top: 18px; color: var(--ink3); font-size: .85rem; }
@media (max-width: 860px) { .an-tip { position: relative; left: auto; top: auto; width: 100%; margin-top: -40px; transition: none; } .an-visual .phone { margin-right: 0; } }
.an-hint { align-self: flex-start; padding-left: 60px; }
@media (max-width: 860px) { .an-visual { align-items: center; } .an-hint { align-self: center; padding-left: 0; } }

/* Аналізи — на зеленій картці, як продовження туру (логіка та сама, analyses.js) */
.tests2 { padding: 0 0 clamp(48px, 7vw, 96px); }
.tests2 > .wrap { border-radius: 40px; padding: clamp(32px, 5vw, 64px); color: #F4F1EC;
  background: radial-gradient(120% 90% at 15% 0%, #7C9C88 0%, transparent 55%), linear-gradient(150deg, #5E7E6B 0%, #3F5A4A 70%, #34503F 100%);
  box-shadow: 0 50px 100px -40px rgba(40, 60, 48, .55); }
:root[data-theme="dark"] .tests2 > .wrap { background: radial-gradient(120% 90% at 15% 0%, #3E5547 0%, transparent 55%), linear-gradient(150deg, #2C3E33 0%, #1D2A22 100%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tests2 > .wrap { background: radial-gradient(120% 90% at 15% 0%, #3E5547 0%, transparent 55%), linear-gradient(150deg, #2C3E33 0%, #1D2A22 100%); } }
.tests2 h2 { color: #fff; }
.tests2 .sub { color: rgba(244, 241, 236, .78); }
.tests2 .who span { background: linear-gradient(135deg, rgba(255,255,255,.17), rgba(255,255,255,.05)); border: 0; color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.17); }
.tests2 .an-hint { color: rgba(244, 241, 236, .7); }
.tests2 .an-spot.on, .tests2 .an-spot:hover, .tests2 .an-spot:focus-visible { box-shadow: inset 0 0 0 2.5px #5E7E6B; }
.tests2 .phone { box-shadow: 0 40px 80px -20px rgba(0,0,0,.6); }
@media (max-width: 860px) { .tests2 > .wrap { width: calc(100% - 24px); border-radius: 28px; padding: 28px 18px; } }

/* Аналізи — 5-й крок туру: зони на рядках телефона активні лише на цьому кроці, підказка — на місці плашок */
.tour .screens { position: relative; }
.tour .an-spot { pointer-events: none; opacity: 0; }
.tour[data-step="4"] .an-spot { pointer-events: auto; opacity: 1; z-index: 2; }
.tour .an-set { grid-template-columns: minmax(0, 330px); }
.tour .an-tip { position: static; width: 100%; transition: none; }
.tour .an-hint { color: rgba(244, 241, 236, .75); margin-top: 4px; padding-left: 4px; }
.tour .an-spot.on, .tour .an-spot:hover { box-shadow: inset 0 0 0 2.5px #5E7E6B; }
@media (max-width: 860px) {
  .tour .an-set { grid-template-columns: 1fr; }
  .tour .an-tip { padding: 10px 12px; }
  .tour .an-tip svg { max-height: 54px; }
  .tour .an-tabs { margin-bottom: 6px; } .tour .an-tabs button { padding: 3px 9px; font-size: .75rem; }
  .tour .an-now { margin-bottom: 0; } .tour .an-now b { font-size: 1.15rem; }
  .tour .an-vals { gap: 4px; } .tour .an-vals li { padding: 6px 10px; }
  .tour .an-norm, .tour .an-hint, .tour .an-note { display: none; }
  .tour .an-title { margin-bottom: 6px; }
}
/* Активний рядок — не обводка, а точка біля краю телефона (власник 13.11) */
.an-spot, .an-spot.on, .an-spot:hover, .an-spot:focus-visible, .tour .an-spot.on, .tour .an-spot:hover { box-shadow: none; }
.an-spot::after { content: ""; position: absolute; right: -11px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 999px;
  background: #5E7E6B; box-shadow: 0 0 0 2px #fff; opacity: 0; transform: scale(.4); transition: opacity .2s, transform .25s cubic-bezier(.16,1,.3,1); }
.an-spot.on::after { opacity: 1; transform: none; }
.an-spot:hover::after { opacity: .6; transform: none; }
.an-spot:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
/* Тінь зеленої картки туру лягає на наступний блок; його тло проявляється з фону сторінки плавно, без різкого краю */
.tour { position: relative; z-index: 1; }
.lost { background: linear-gradient(to bottom, var(--paper) 0, var(--accent-tint) 220px); }
.tour.anim .tour-stage { overflow-x: clip; overflow-y: visible; }

/* Песик на першому екрані: голова поверх, очі під нею (видно крізь отвори), рухає їх dog.js */
.dog { position: relative; width: min(46vw, 500px); aspect-ratio: 1; margin: 18px auto 0; }
.dog img { position: absolute; display: block; }
.dog .head { inset: 0; width: 100%; height: 100%; z-index: 2; -webkit-mask-image: linear-gradient(#000 80%, transparent 93%); mask-image: linear-gradient(#000 80%, transparent 93%); } /* низ бороди тане в груди тулуба, щоб не видно було шва */
.dog .eye { width: 18.02%; height: 18.02%; z-index: 1; will-change: transform; }
.dog .eye-l { left: 30.30%; top: 32.86%; }
.dog .eye-r { left: 50.40%; top: 33.33%; }
.tour.anim .tour-intro { align-content: start; padding-top: calc(68px + clamp(16px, 5vh, 56px)); }
@media (max-width: 860px) { .dog { width: min(78vw, 360px); } }

/* «Якщо загубився»: лапа тримає нашийник, жетон зі справжнім QR гойдається на кільці.
   Шари на одному полотні 600×884 (лапа долонею до нас, власник 18.11): лапа, жетон (+QR), ланка зверху — так вона проходить крізь вушко.
   Точка підвісу — центр вушка (453, 402). Жетон уже великий, без збільшення. */
.lost-visual { display: block; align-self: end; margin-bottom: calc(-1 * clamp(56px, 8vw, 112px)); }
.paw { position: relative; display: block; width: min(100%, 440px); aspect-ratio: 600 / 884; margin: 0 auto; }
.paw > img, .paw-tag, .paw-tag > img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.paw-tag { transform-origin: 75.58% 45.48%; }
.paw-qr { position: absolute; left: 60.5%; top: 50.34%; width: 30.17%; aspect-ratio: 1; }
.paw-qr img { display: block; width: 100%; height: 100%; }
.paw-ring { z-index: 1; pointer-events: none; } /* кільце накриває все полотно — інакше перехоплює тап по QR */
.paw-cap { position: absolute; left: 50%; top: 88%; transform: translateX(-50%); white-space: nowrap; z-index: 2;
  background: #fff; color: #6E655B; font-size: .8rem; padding: 6px 12px; border-radius: 999px; box-shadow: var(--shadow); }
@media (prefers-reduced-motion: no-preference) {
  .paw-tag { animation: tag-swing 5s ease-in-out infinite; }
  @keyframes tag-swing { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(3deg); } }
}
@media (max-width: 860px) { .paw { width: min(78vw, 340px); } }

/* «Доглядайте разом»: ролі — картки 2×2, різниця в одному реченні й чіпі рівня */
.family .wrap { grid-template-columns: minmax(0, 560px) auto; justify-content: center; gap: clamp(32px, 7vw, 112px); align-items: center; }
.fam-visual { order: 2; } /* телефон праворуч: у блоці вище ліворуч уже лапа (власник 14.11) */
.fam-visual .phone { max-width: 260px; }
.roles { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; max-width: 540px; }
.roles li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; }
.roles b { display: block; font-size: 1.05rem; }
.roles span { white-space: nowrap; display: inline-flex; align-items: center; gap: 5px; margin-top: 6px; padding: 3px 10px 3px 8px; border-radius: 999px; font-size: .8rem; font-weight: 600; }
.roles .lv0 { background: var(--accent-tint); color: var(--accent-deep); }
.roles .lv1 { background: var(--surface2); color: var(--ink2); }
.roles i { width: 14px; height: 14px; background: currentColor; -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat; }
.roles p { margin: 10px 0 0; color: var(--ink2); font-size: .93rem; line-height: 1.4; }
.fam-facts { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 6px; max-width: 540px; }
.fam-facts li { position: relative; padding-left: 20px; color: var(--ink2); font-size: .95rem; line-height: 1.45; }
.fam-facts li::before { content: ""; position: absolute; left: 3px; top: .55em; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.fam-prem { margin-top: 12px; font-size: .9rem; color: var(--ink3); max-width: 540px; }
@media (max-width: 860px) {
  .family .wrap { grid-template-columns: 1fr; }
  .fam-visual { order: 2; }
  .fam-visual .phone { max-width: 240px; margin: 0 auto; }
}
@media (max-width: 520px) { .roles { gap: 8px; } .roles li { padding: 12px 12px 14px; } .roles b { font-size: .95rem; } .roles p { font-size: .85rem; } .roles span { font-size: .74rem; padding: 3px 8px 3px 6px; } }
@media (max-width: 330px) { .roles { grid-template-columns: 1fr; } }

/* Можливості: один перелік, Premium-пункти з чіпом у куті (замість двох тарифних карток) */
.feats { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; max-width: 1040px; margin-inline: auto; }
.feats li { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px 20px 22px; }
.feats li > i { display: block; width: 40px; height: 40px; border-radius: 12px; background: var(--accent-tint); position: relative; }
.feats li > i::after { content: ""; position: absolute; inset: 10px; background: var(--accent-deep); -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat; }
.feats b { display: block; margin-top: 14px; font-size: 1.05rem; }
.feats p { margin: 4px 0 0; color: var(--ink2); font-size: .93rem; line-height: 1.45; }
.pro-chip { position: absolute; top: 20px; right: 18px; display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px 3px 7px; border-radius: 999px;
  background: #F3E3C0; color: #7A5418; font-size: .75rem; font-weight: 700; }
.pro-chip i { width: 13px; height: 13px; background: currentColor; -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .pro-chip { background: #4A3A1C; color: #F1D28E; } }
:root[data-theme="dark"] .pro-chip { background: #4A3A1C; color: #F1D28E; }
@media (max-width: 860px) { .feats { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .feats { gap: 8px; } .feats li { padding: 14px 12px 16px; } .feats b { font-size: .95rem; } .feats p { font-size: .85rem; }
  .pro-chip { top: 14px; right: 10px; padding: 2px 7px 2px 5px; font-size: .68rem; } }

/* Підвал: заклик завантажити й посилання на одній зеленій картці, праворуч песик «клас» стоїть на лінії посилань */
.foot { padding: clamp(40px, 6vw, 80px) 0 20px; }
.foot-card { width: min(1160px, 100% - 40px); margin: 0 auto; border-radius: 40px; overflow: hidden; color: #F4F1EC;
  background: radial-gradient(120% 90% at 85% 0%, #7C9C88 0%, transparent 55%), linear-gradient(150deg, #5E7E6B 0%, #3F5A4A 70%, #34503F 100%); }
:root[data-theme="dark"] .foot-card { background: radial-gradient(120% 90% at 85% 0%, #3E5547 0%, transparent 55%), linear-gradient(150deg, #2C3E33 0%, #1D2A22 100%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .foot-card { background: radial-gradient(120% 90% at 85% 0%, #3E5547 0%, transparent 55%), linear-gradient(150deg, #2C3E33 0%, #1D2A22 100%); } }
.foot-cta { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 24px; padding: clamp(36px, 6vw, 72px) clamp(28px, 6vw, 72px) 0; }
.foot-text { align-self: center; padding-bottom: clamp(28px, 4vw, 56px); }
.foot-text h2 { color: #fff; }
.foot-text p { margin-top: 12px; max-width: 40ch; color: rgba(244, 241, 236, .85); }
.foot-text .cta-row { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px; }
.foot .btn-primary { background: #fff; color: #3F5A4A; }
.foot .btn-primary:hover { background: #F4F1EC; }
.foot .btn img.mono { filter: brightness(0) saturate(100%) invert(31%) sepia(14%) saturate(800%) hue-rotate(95deg); }
.foot .btn-soon { background: rgba(255, 255, 255, .12); color: rgba(244, 241, 236, .85); }
.foot .btn-soon small { color: rgba(244, 241, 236, .6); }
.foot .btn-soon img { filter: brightness(0) invert(1); opacity: .7; }
.foot-dog { display: block; width: clamp(200px, 26vw, 300px); height: auto; margin-bottom: -2px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: center; padding: 22px clamp(28px, 6vw, 72px) 26px;
  border-top: 1px solid rgba(244, 241, 236, .18); font-size: .92rem; }
.foot-links a { color: rgba(244, 241, 236, .85); }
.foot-links a:hover { color: #fff; }
.foot-links .copy { margin-left: auto; color: rgba(244, 241, 236, .6); }
@media (max-width: 860px) {
  .foot-card { border-radius: 28px; width: calc(100% - 24px); }
  .foot-cta { grid-template-columns: 1fr; }
  .foot-text { padding-bottom: 8px; }
  .foot-dog { width: min(56vw, 220px); justify-self: center; }
  .foot-links .copy { margin-left: 0; width: 100%; }
}
.lost { overflow-x: clip; } /* збільшене прозоре полотно жетона виступало за край на телефоні */
/* Підвал на всю ширину (власник 14.11): фон від краю до краю, вміст — по ширині .wrap */
.foot { padding-bottom: 0; }
.foot-card { width: 100%; border-radius: 0; }
.foot-cta, .foot-links { padding-inline: max(20px, (100% - 1160px) / 2); }
@media (max-width: 860px) { .foot-card { width: 100%; border-radius: 0; } }
/* Голова песика виглядає над зеленим на світлий фон; сам він не торкається лінії посилань (власник 14.11) */
.foot { padding-top: clamp(120px, 12vw, 170px); }
.foot-card { overflow: visible; }
.foot-cta { padding-top: clamp(28px, 4vw, 48px); }
.foot-dog { margin-top: calc(-1 * clamp(90px, 9vw, 130px)); margin-bottom: 22px; }
@media (max-width: 860px) {
  .foot { padding-top: 40px; }
  .foot-dog { margin-top: 0; margin-bottom: 16px; }
}
/* Песик «клас» більший (власник 14.11): нова версія з тінню */
.foot-dog { width: clamp(260px, 30vw, 380px); margin-top: calc(-1 * clamp(110px, 11vw, 160px)); }
@media (max-width: 860px) { .foot-dog { width: min(64vw, 260px); margin-top: 0; } }
/* Сітка-слід під усією сторінкою (ідея — InteractiveGrid, переписано без React): клітинка під курсором спалахує й повільно гасне.
   Лежить під вмістом; зелена картка туру й підвал мають свій фон і накривають її. На першому екрані шлейф показує, за чим стежить песик (власник 14.11). Лише з мишею. */
.grid-bg { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; color: var(--ink); display: none; }
.has-grid .grid-bg { display: block; }
.has-grid main, .has-grid .foot { position: relative; z-index: 1; }
.grid-bg rect { fill: currentColor; fill-opacity: 0; stroke: none; transition: fill-opacity 1s ease-out; }
.grid-bg rect.on { fill-opacity: .07; transition: none; }
@media (prefers-reduced-motion: reduce) { .grid-bg rect { transition: none; } }
/* Подяка півколом над головою песика «клас» (власник 14.11): дуга на світлому тлі над зеленим */
.foot-dog { position: relative; }
.foot-dog img { display: block; width: 100%; height: auto; }
.foot-arc { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.foot-arc text { fill: var(--ink2); font: 700 22px Mulish, sans-serif; letter-spacing: .14em; text-transform: uppercase; }
@media (max-width: 860px) { .foot-dog { margin-top: 36px; } .foot-arc text { fill: rgba(244, 241, 236, .8); } } /* на телефоні песик увесь на зеленому — текст світлий, зверху місце для дуги */
@media (max-width: 420px) { .tour-intro h1 { font-size: clamp(1.6rem, 7.6vw, 2.1rem); } } /* на 375 px заголовок у два рядки (Shantell Sans ширший за Mulish) */
@media (max-width: 860px) { .tour.anim .tour-texts p { font-size: .9rem; line-height: 1.45; max-width: 36ch; margin-top: 6px; } } /* довший опис першого кроку вилазив за верх картки */
/* Легкий режим туру на телефоні (клас .lite ставить tour.js): без розмиття під плашками й шапкою — щільний фон замість скла */
.tour.lite .badge { backdrop-filter: none; -webkit-backdrop-filter: none; background: rgba(255, 255, 255, .13); }
@media (pointer: coarse), (max-width: 860px) { .top { backdrop-filter: none; -webkit-backdrop-filter: none; background: color-mix(in srgb, var(--paper) 97%, transparent); } }
/* svh у турі: висота екрана з видимим адресним рядком — не змінюється, коли рядок ховається, тож сцена й картка не розʼїжджаються (власник 14.11) */
/* Тур на телефоні (власник 14.11): телефон більший і обрізається низом картки, плашки лежать поверх нього внизу,
   під ними темний перехід, щоб білий текст читався на світлому скріні */
@media (max-width: 860px) {
  .tour.anim .tour-grid { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 16px; padding: 34px 16px 0; }
  .tour.anim .tour-phone { width: min(76vw, 330px); flex: none; }
  .tour.anim .tour-badges { position: absolute; left: 12px; right: 12px; bottom: 14px; width: auto; min-height: 0; z-index: 3; }
  .tour.anim .badge-set { inset: auto 0 0 0; height: auto; }
  .tour.anim .tour-card::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 34%; z-index: 2; pointer-events: none;
    background: linear-gradient(to top, rgba(28, 42, 34, .92) 30%, rgba(28, 42, 34, 0)); }
}
/* Тур на телефоні: текст від верху (не по центру — довгий опис вилазив над карткою під крапки), телефон нижче (власник 14.11) */
@media (max-width: 860px) {
  .tour.anim .tour-grid { padding-top: 40px; gap: 18px; }
  .tour.anim .tour-texts { height: 150px; flex: none; }
  .tour.anim .tour-texts > div { justify-content: flex-start; }
}
/* Шапка (власник 14.11): «Завантажити» відкриває віконце з Google Play і App Store; на телефоні тема й мова — праворуч біля кнопки */
.dl { position: relative; }
.dl { border-bottom: 0; } /* роздільник питань FAQ (details) не для кнопки «Завантажити» в шапці — лінія під нею, 17.11 */
.dl summary { list-style: none; cursor: pointer; }
.dl summary::-webkit-details-marker { display: none; }
.dl-menu { position: absolute; right: 0; top: calc(100% + 10px); display: grid; gap: 8px; padding: 10px; border-radius: 22px; background: var(--surface);
  border: 1px solid var(--line); box-shadow: 0 24px 48px -16px rgba(0, 0, 0, .28); z-index: 30; }
.dl-menu .btn { justify-content: flex-start; }
@media (max-width: 860px) {
  .top .wrap { gap: 10px; }
  .top .theme { margin-left: auto; }
  .top .btn-sm { margin-left: 0; }
}
/* Легкий тур: без важких тіней на плашках і телефоні — їх перемальовує кожен кадр прокрутки */
.tour.lite .badge { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .17); }
.tour.lite .tour-phone { box-shadow: inset 0 0 0 1.5px #4A443D; }
/* Плашки туру на телефоні: дві рівні колонки на всю ширину — довгі не вилазять за край, короткі не «танцюють» (власник 14.11) */
@media (max-width: 860px) {
  .tour .badge-set { justify-items: stretch; }
  .tour .badge { min-width: 0; width: 100%; }
  .tour .badge b { min-width: 0; overflow-wrap: anywhere; }
}
/* «Завантажити»: без «+» від стилю FAQ (він повертався у «×» на кнопці); закривається тапом повз (власник 14.11).
   Ширина за вмістом: інакше віконце стискалось до ширини кнопки, і «скоро» впиралось у край */
.dl summary::after { content: none; display: none; }
.dl-menu { width: max-content; }

/* Поява першого екрана, як у застосунку (Stagger: блоки по черзі піднімаються на 14 px із проявленням, 0,42 с, крок 50 мс,
   крива 0.22, .9, .3, 1). Песик виринає знизу трохи довше. Лише CSS — стартує до завантаження скриптів; текст не ховається
   довше за мить (власник 17.11). Анімуємо дітей .tour-intro, не сам блок: ним керує тур (GSAP). */
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes dog-rise { from { opacity: 0; transform: translateY(60px) scale(.94); } }
@media (prefers-reduced-motion: no-preference) {
  .top .wrap > * { animation: rise .42s cubic-bezier(.22,.9,.3,1) both; animation-delay: .02s; }
  .tour-intro h1 { animation: rise .42s cubic-bezier(.22,.9,.3,1) .07s both; }
  .tour-intro .lead { animation: rise .42s cubic-bezier(.22,.9,.3,1) .12s both; }
  .tour-intro .cta-row { animation: rise .42s cubic-bezier(.22,.9,.3,1) .17s both; }
  .tour-intro .dog { animation: dog-rise .7s cubic-bezier(.22,.9,.3,1) .22s both; }
}

/* Тур на телефоні без «прибивання» (tour.js → .flow, власник 18.11): кроки один під одним, сторінка гортається звичайно. */
.tour.flow .tour-card { margin: 8px auto 40px; width: calc(100% - 24px); border-radius: 28px; }
.tour.flow .tour-grid { display: flex; flex-direction: column; gap: 56px; padding: 40px 18px 44px; }
.flow-step { display: flex; flex-direction: column; align-items: center; gap: 18px; text-align: center; }
.flow-step > div:first-child h3 { font-size: 1.45rem; color: #fff; }
.flow-step > div:first-child p { color: rgba(244, 241, 236, .82); margin: 8px auto 0; max-width: 34ch; font-size: .95rem; }
/* Повний скрін, плашки поверх низу телефона (власник 18.11); фон плашок щільний — скрін під ними не просвічує. */
.flow-media { position: relative; width: min(78vw, 310px); }
.flow-phone { width: 100%; aspect-ratio: 1080 / 2400; border-radius: 36px; padding: 8px; background: #14110E;
  box-shadow: inset 0 0 0 1.5px #4A443D, 0 24px 48px -18px rgba(0,0,0,.55); }
.flow-phone .screens { position: relative; width: 100%; height: 100%; border-radius: 29px; overflow: hidden; background: #FAF8F5; }
.flow-phone img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.tour.flow .flow-media > .badge-set.badge-set { display: flex; flex-direction: column; gap: 8px; position: absolute; left: 0; right: 0; bottom: 18px; height: auto; z-index: 2; }
/* Плашки по боках, наїжджають на скрін (власник 18.11): непарні — зліва з виступом за телефон, парні — справа. */
.tour.flow .flow-media > .badge-set > .badge:nth-child(odd) { align-self: flex-start; margin-left: -19px; }
.tour.flow .flow-media > .badge-set > .badge:nth-child(even) { align-self: flex-end; margin-right: -19px; } /* сильніше за «:not(.anim) лише перший набір» */
.tour.flow .badge-set .badge:nth-child(even) { margin-left: 0; }
.tour.flow .badge { padding: 8px 12px 8px 8px; border-radius: 14px; background: rgba(52, 76, 62, .84); box-shadow: inset 0 0 0 1px rgba(255,255,255,.2), 0 10px 24px -10px rgba(0,0,0,.5); }
.tour.flow .badge b { font-size: .85rem; white-space: normal; text-align: left; }
.tour.flow .badge > i { width: 30px; height: 30px; border-radius: 9px; }
.tour.flow .badge > i::after { inset: 7px; }
.tour.flow .flow-media > .an-set.badge-set { display: block; left: -10px; right: -10px; }
.tour.flow .flow-step .badge { width: auto; flex: 0 0 auto; max-width: 88%; }

/* Тулуб песика (власник 18.11): окремий шар позаду голови (очі лишаються на своїх місцях), у 2,2 раза ширший за голову —
   за макетом власника (18.11, поміряно за очима й подушечками лап): лапи стирчать з боків над вухами; нижня частина ховається під зеленою карткою туру. */
.dog .body { left: -56%; top: 3%; width: 220%; max-width: none; height: auto; z-index: 0; }
/* Телефон (тур без «прибивання»): зелена картка наїжджає на низ песика, тулуб ховається під нею. */
.tour.flow .tour-intro { position: relative; z-index: 0; }
.tour.flow .tour-card { position: relative; z-index: 1; margin-top: -36px; }
/* З тулубом лапи виходять за голову на ~30% з кожного боку: на телефоні песик менший, щоб лапи вмістились у ширину екрана. */
@media (max-width: 860px) { .dog { width: min(56vw, 300px); } }
.tour-intro { overflow-x: clip; }

/* Підвал, варіант А (власник 18.11): заокруглена зелена картка, як тур; песик «клас» сидить у ній, голова визирає над верхнім
   краєм; службові посилання — окремим тихим рядком на фоні сторінки під карткою. Скасовує «на всю ширину» від 14.11. */
.foot { padding-top: clamp(110px, 11vw, 150px); padding-bottom: 0; }
.foot-card { width: min(1160px, 100% - 40px); margin: 0 auto; border-radius: 40px; overflow: visible; }
.foot-cta { padding: clamp(36px, 5vw, 64px) clamp(28px, 6vw, 72px) 0; }
.foot-dog { width: clamp(240px, 26vw, 330px); margin-top: calc(-1 * clamp(100px, 10vw, 140px)); margin-bottom: clamp(20px, 3vw, 36px); }
.foot-links { width: min(1160px, 100% - 40px); margin: 0 auto; padding: 22px clamp(28px, 6vw, 72px) 30px; border-top: 0; color: var(--ink2); }
.foot-links a { color: var(--ink2); }
.foot-links a:hover { color: var(--ink); }
.foot-links .copy { color: var(--ink3); }
@media (max-width: 860px) {
  .foot { padding-top: 120px; }
  .foot-card { width: calc(100% - 24px); border-radius: 28px; }
  .foot-cta { padding: 0 22px; justify-items: center; text-align: center; }
  .foot-dog { order: -1; width: min(58vw, 230px); margin-top: -96px; }
  .foot-arc text { fill: var(--ink2); }
  .foot-text .cta-row { justify-content: center; }
  .foot-text p { margin-inline: auto; }
  .foot-links { width: calc(100% - 24px); padding: 20px 10px 28px; justify-content: center; text-align: center; }
}

/* Підвал: коробка, з якої визирає улюбленець (власник 18.11). Три шари на одному полотні 640×640: задня частина коробки,
   тварина в «ямі» (обрізана по низу коробки, щоб, ховаючись, не вилазила знизу), передні стінки. */
.foot { padding-top: clamp(40px, 6vw, 80px); }
.foot-cta { align-items: end; }
.pb { width: min(100%, 400px); display: grid; justify-items: center; gap: 10px; margin-bottom: clamp(28px, 4vw, 48px); }
.pb-box { position: relative; width: 100%; aspect-ratio: 1; margin: -12% 0 -14%; cursor: pointer; transform-origin: 50% 85%; }
.pb-box > img, .pb-pit, .pb-cast { position: absolute; inset: 0; width: 100%; height: 100%; }
/* Яма: видно лише над вінцем коробки й усередині її силуету, тож тварина, пірнаючи, не вилазить знизу чи збоку. */
.pb-pit { clip-path: polygon(0 -20%, 100% -20%, 100% 40%, 77% 40%, 77% 84.5%, 23% 84.5%, 23% 40%, 0 40%); }
.pb-mv { position: absolute; left: 12%; top: 0%; width: 74%; height: auto; aspect-ratio: 1; transition: transform .3s cubic-bezier(.5,0,.75,0); }
/* Підгонка висоти під вид (власник 18.11): кіт трохи нижче, кролик вище. */
.pb-box[data-sp="cat"] .pb-mv { top: 3%; }
.pb-box[data-sp="rabbit"] .pb-mv { top: -3.5%; }
.pb-box.down .pb-mv { transform: translateY(78%); }
.pb-box.up .pb-mv { transition: transform .55s cubic-bezier(.3,1.5,.5,1); }
/* Тінь коробки на тварині: темніє донизу до вінця, по силуету самої тварини. */
.pb-shade { -webkit-mask: var(--src) center / 100% no-repeat; mask: var(--src) center / 100% no-repeat;
  background: linear-gradient(to bottom, transparent 38%, rgba(60, 36, 12, .35) 56%); }
/* Тінь тварини на коробці ззаду: силует, зсунутий назад-праворуч, лише там, де є коробка. */
.pb-cast { -webkit-mask: url(box/back.webp) center / 100% no-repeat; mask: url(box/back.webp) center / 100% no-repeat; }
.pb-cast .pb-mv { filter: brightness(0) blur(5px); opacity: .22; translate: 6% -4%; }
/* Кільце зірочок довкола коробки (власник 18.11): дві «комети» по нахиленому еліпсу; задня половина за коробкою, передня — перед. */
.pb-box { isolation: isolate; }
.pb-back { z-index: 1; } .pb-cast { z-index: 2; } .pb-pit { z-index: 3; } .pb-front { z-index: 4; }
.pb-orbit { position: absolute; inset: 0; pointer-events: none; filter: drop-shadow(0 0 3px rgba(255, 232, 160, .9)); }
.pb-orbit.back { z-index: 0; } .pb-orbit.front { z-index: 5; }
.pb-star { position: absolute; width: var(--s); height: var(--s); margin: calc(var(--s) / -2) 0 0 calc(var(--s) / -2); background: #FFF1C4;
  clip-path: polygon(50% 0, 60% 40%, 100% 50%, 60% 60%, 50% 100%, 40% 60%, 0 50%, 40% 40%); }
.pb-star.dot { clip-path: circle(30%); }
.pb-box.wob { animation: pb-wob .5s ease-in-out; }
@keyframes pb-wob { 25% { transform: rotate(-2.5deg); } 60% { transform: rotate(2deg); } 85% { transform: rotate(-.8deg); } }
/* Тінь коробки на «підлозі». Коробка хитається навколо низу, тінь — ні: гасить поворот і лише зсувається та стискається в такт. */
.pb-ground { position: absolute; left: 11%; width: 78%; top: 78%; height: 14%; z-index: 0; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(5, 12, 8, .7), rgba(5, 12, 8, .3) 60%, transparent); transform-origin: 50% 50%; }
.pb-box.wob .pb-ground { animation: pb-shwob .5s ease-in-out; }
@keyframes pb-shwob { 25% { transform: rotate(2.5deg) translateX(-3%) scaleX(.93); } 60% { transform: rotate(-2deg) translateX(2.5%) scaleX(.95); }
  85% { transform: rotate(.8deg) translateX(-1%) scaleX(.98); } }
.pb-q { margin: 18px 0 8px; color: #fff; font-weight: 700; font-size: 1.05rem; }
.pb-kinds { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.pb-kinds button { font: 600 .85rem Mulish, sans-serif; color: rgba(244, 241, 236, .9); background: rgba(255,255,255,.1); border: 0; border-radius: 999px;
  padding: 7px 12px; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(255,255,255,.14); transition: background .2s, color .2s; }
.pb-kinds button[aria-checked="true"] { background: #fff; color: #3F5A4A; }
@media (max-width: 860px) {
  .foot { padding-top: 40px; }
  .foot-cta { padding: 32px 18px 0; }
  .pb { margin: 0 auto 28px; width: min(100%, 340px); }
}
@media (prefers-reduced-motion: reduce) { .pb-mv, .pb-box.up .pb-mv { transition: none; } .pb-box.wob, .pb-box.wob .pb-ground { animation: none; } }
