/* ============================================================
   МиниЛапки — дизайн-система «Milk & Biscuit»
   Тёплый кремовый фон, стикер-карточки, дудлы, крупная типографика
   ============================================================ */

:root {
  /* Палитра */
  --cream: #FBF3E4;
  --cream-2: #FFF9EE;
  --terra: #E06B33;
  --terra-dark: #C4532A;
  --terra-soft: #F3D5C0;
  --choco: #33241A;
  --choco-70: rgba(51, 36, 26, .7);
  --choco-50: rgba(51, 36, 26, .5);
  --choco-10: rgba(51, 36, 26, .1);
  --sage: #8FA382;
  --sage-soft: #DCE4D3;
  --sunny: #F4B942;
  --sunny-soft: #FBE7B8;
  --sos: #C24A33;
  --white: #FFFDF8;

  /* Типографика */
  --font-display: 'Unbounded', system-ui, sans-serif;
  --font-body: 'Nunito', system-ui, sans-serif;
  --font-hand: 'Caveat', cursive;

  /* Форма */
  --line: 2px solid var(--choco);
  --r-lg: 28px;
  --r-md: 20px;
  --r-sm: 14px;
  --shadow-sticker: 5px 5px 0 var(--choco);
  --shadow-sticker-hover: 8px 8px 0 var(--choco);
  --shadow-soft: 0 24px 48px rgba(51, 36, 26, .10);

  /* Ритм */
  --container: 1200px;
  --section-y: clamp(72px, 10vw, 128px);
}

/* ---------- База ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17.5px;
  line-height: 1.65;
  color: var(--choco);
  background-color: var(--cream);
  /* зернистость + точки-следы */
  background-image:
    radial-gradient(rgba(51,36,26,.045) 1.2px, transparent 1.2px);
  background-size: 26px 26px;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { color: var(--terra-dark); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--terra); }

h1, h2, h3, .display {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin: 0 0 .5em;
}

h1 { font-size: clamp(2.3rem, 5.6vw, 4.3rem); font-weight: 900; }
h2 { font-size: clamp(1.8rem, 3.8vw, 2.9rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.5rem); }

p { margin: 0 0 1em; }

.lead { font-size: clamp(1.1rem, 1.6vw, 1.3rem); color: var(--choco-70); max-width: 62ch; }

.hand {
  font-family: var(--font-hand);
  font-weight: 600;
  font-size: 1.5em;
  color: var(--terra-dark);
}

::selection { background: var(--sunny); color: var(--choco); }

:focus-visible {
  outline: 3px solid var(--terra);
  outline-offset: 3px;
  border-radius: 6px;
}

.container {
  width: min(var(--container), 92vw);
  margin-inline: auto;
}

.section { padding-block: var(--section-y); position: relative; }

.section--tint { background: var(--cream-2); border-block: var(--line); }
.section--peach { background: var(--terra-soft); border-block: var(--line); }
.section--sage  { background: var(--sage-soft); border-block: var(--line); }

.section-head { max-width: 720px; margin-bottom: clamp(36px, 5vw, 64px); }
.section-head .hand { display: block; margin-bottom: .2em; }

/* ---------- Кнопки-стикеры ---------- */
.btn {
  --btn-bg: var(--terra);
  --btn-color: var(--white);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 28px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .95rem;
  color: var(--btn-color);
  background: var(--btn-bg);
  border: var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow-sticker);
  cursor: pointer;
  text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
  will-change: transform;
}
.btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: var(--shadow-sticker-hover);
  color: var(--btn-color);
  background: var(--terra-dark);
}
.btn:active { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--choco); }

.btn--ghost { --btn-bg: var(--white); --btn-color: var(--choco); }
.btn--ghost:hover { background: var(--sunny-soft); }
.btn--sage { --btn-bg: var(--sage); }
.btn--sage:hover { background: #7c9170; }
.btn--sos { --btn-bg: var(--sos); }
.btn--sos:hover { background: #a93e2b; }
.btn--lg { padding: 19px 36px; font-size: 1.05rem; }
.btn--sm { padding: 10px 18px; font-size: .8rem; }

.btn .btn__paw { width: 20px; height: 20px; flex: none; }

/* ---------- Хедер ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(251, 243, 228, .92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: var(--line);
  transition: box-shadow .25s ease;
}
.header.is-scrolled { box-shadow: 0 6px 0 rgba(51,36,26,.06); }

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 14px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.25rem;
  color: var(--choco);
  text-decoration: none;
}
.logo:hover { color: var(--choco); }
.logo__mark { width: 40px; height: 40px; flex: none; }
.logo__mark .tail { transform-origin: 90% 60%; animation: wag 1.6s ease-in-out infinite; }
@keyframes wag {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(-14deg); }
}
.logo em { font-style: normal; color: var(--terra); }

.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  font-weight: 700;
  font-size: .9rem;
  white-space: nowrap;
  color: var(--choco);
  text-decoration: none;
  padding: 8px 11px;
  border-radius: 999px;
  border: 2px solid transparent;
  transition: all .15s ease;
}
.nav a:hover { background: var(--sunny-soft); border-color: var(--choco); }
.nav a.is-active { background: var(--choco); color: var(--cream); }

.header__cta { white-space: nowrap; }

.burger {
  display: none;
  width: 48px; height: 48px;
  background: var(--white);
  border: var(--line);
  border-radius: 14px;
  box-shadow: 3px 3px 0 var(--choco);
  cursor: pointer;
  padding: 11px;
}
.burger span {
  display: block;
  height: 3px;
  background: var(--choco);
  border-radius: 3px;
  margin: 5px 0;
  transition: transform .25s ease, opacity .2s ease;
}
.burger.is-open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.burger.is-open span:nth-child(2) { opacity: 0; }
.burger.is-open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 89;
  background: var(--cream);
  padding: 110px 6vw 40px;
  flex-direction: column;
  gap: 6px;
}
.mobile-menu.is-open { display: flex; }
.mobile-menu a {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.4rem, 6vw, 2rem);
  color: var(--choco);
  text-decoration: none;
  padding: 12px 0;
  border-bottom: 2px dashed var(--choco-10);
}
.mobile-menu a:hover { color: var(--terra); }

/* ---------- Герой ---------- */
.hero { position: relative; padding: clamp(56px, 8vw, 110px) 0 clamp(64px, 8vw, 120px); overflow: hidden; }

.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}

.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-hand);
  font-size: 1.6rem;
  color: var(--terra-dark);
  transform: rotate(-2deg);
  margin-bottom: 10px;
}

.hero__title .accent { position: relative; white-space: nowrap; color: var(--terra); }
.hero__title .accent svg {
  position: absolute;
  left: 0; right: 0; bottom: -12px;
  width: 100%; height: 14px;
}

.hero__actions { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 34px; }

.hero__note {
  margin-top: 26px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: .95rem;
  color: var(--choco-70);
}
.hero__note .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--sage); box-shadow: 0 0 0 5px var(--sage-soft); flex: none; }

.hero__art { position: relative; }
.hero__art img { position: relative; z-index: 2; filter: drop-shadow(0 24px 32px rgba(51,36,26,.18)); }

.blob {
  position: absolute;
  border-radius: 50% 45% 55% 48% / 55% 50% 52% 46%;
  z-index: 1;
  animation: blobFloat 9s ease-in-out infinite;
}
.blob--1 { width: 78%; height: 78%; background: var(--sunny-soft); top: 6%; left: 4%; }
.blob--2 { width: 44%; height: 44%; background: var(--terra-soft); bottom: -4%; right: 0; animation-delay: -3s; }
.blob--3 { width: 22%; height: 22%; background: var(--sage-soft); top: 0; right: 8%; animation-delay: -6s; }
@keyframes blobFloat {
  0%, 100% { transform: translateY(0) rotate(0deg) scale(1); }
  50% { transform: translateY(-16px) rotate(4deg) scale(1.04); }
}

.hero__sticker {
  position: absolute;
  z-index: 3;
}

/* ---------- Наклейки ---------- */
.sticker {
  display: inline-block;
  font-family: var(--font-hand);
  font-weight: 700;
  font-size: 1.35rem;
  line-height: 1.1;
  padding: 10px 18px;
  background: var(--sunny);
  color: var(--choco);
  border: var(--line);
  border-radius: var(--r-sm);
  box-shadow: 4px 4px 0 var(--choco);
  transform: rotate(-3deg);
}
.sticker--peach { background: var(--terra-soft); transform: rotate(2.5deg); }
.sticker--sage { background: var(--sage-soft); transform: rotate(-2deg); }
.sticker--display { font-family: var(--font-display); font-size: .85rem; font-weight: 700; }

/* ---------- Бегущая строка ---------- */
.marquee {
  overflow: hidden;
  border-block: var(--line);
  background: var(--choco);
  color: var(--cream);
  padding: 14px 0;
  transform: rotate(-1deg) scale(1.02);
}
.marquee--sunny { background: var(--sunny); color: var(--choco); transform: rotate(1deg) scale(1.02); }
.marquee__track {
  display: flex;
  gap: 48px;
  width: max-content;
  animation: marquee 36s linear infinite;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__item {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .95rem;
  white-space: nowrap;
}
.marquee__item svg { width: 18px; height: 18px; flex: none; }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- Карточки ---------- */
.grid { display: grid; gap: clamp(20px, 2.6vw, 32px); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--white);
  border: var(--line);
  border-radius: var(--r-lg);
  padding: clamp(22px, 3vw, 34px);
  box-shadow: var(--shadow-sticker);
  transition: transform .22s ease, box-shadow .22s ease;
  position: relative;
}
.card:hover {
  transform: translate(-3px, -3px) rotate(-.6deg);
  box-shadow: var(--shadow-sticker-hover);
}

.card__icon {
  width: 60px; height: 60px;
  display: grid;
  place-items: center;
  background: var(--sunny-soft);
  border: var(--line);
  border-radius: 18px;
  margin-bottom: 18px;
  font-size: 1.6rem;
}
.card__icon svg { width: 30px; height: 30px; }

.card--peach { background: #FBE9DB; }
.card--sage { background: #EDF2E6; }
.card--sunny { background: #FDF3DA; }

/* ---------- Чипы ---------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  font-size: .85rem;
  font-weight: 800;
  color: var(--choco);
  background: var(--cream-2);
  border: var(--line);
  border-radius: 999px;
}
.chip--terra { background: var(--terra-soft); }
.chip--sage { background: var(--sage-soft); }
.chip--sunny { background: var(--sunny-soft); }

/* ---------- Статистика ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(16px, 2.4vw, 28px); }
.stat {
  text-align: center;
  padding: clamp(22px, 3vw, 36px) 16px;
  background: var(--white);
  border: var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sticker);
}
.stat__num {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2rem, 4vw, 3.2rem);
  color: var(--terra);
  line-height: 1;
}
.stat__num sup { font-size: .45em; color: var(--choco-50); }
.stat__label { margin-top: 10px; font-weight: 700; font-size: .95rem; color: var(--choco-70); }

/* ---------- Лапометр (шкала риска) ---------- */
.lapometr { display: inline-flex; gap: 4px; }
.lapometr svg { width: 22px; height: 22px; }
.lapometr .off { opacity: .22; }

/* ---------- Бейдж ветеринара ---------- */
.badge-vet {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 10px 18px 10px 10px;
  background: var(--sage-soft);
  border: var(--line);
  border-radius: 999px;
  font-size: .9rem;
  font-weight: 700;
}
.badge-vet img { width: 42px; height: 42px; border-radius: 50%; border: var(--line); background: var(--white); object-fit: cover; }
.badge-vet svg { width: 18px; height: 18px; flex: none; }

/* ---------- SOS-баннер ---------- */
.sos-banner {
  background: var(--sos);
  color: var(--white);
  border-block: var(--line);
}
.sos-banner__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 26px;
  flex-wrap: wrap;
}
.sos-banner__title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(1.15rem, 2.4vw, 1.7rem);
  margin: 0;
}
.sos-banner p { margin: 6px 0 0; opacity: .92; max-width: 56ch; }
.sos-banner .btn { flex: none; }

/* ---------- FAQ ---------- */
.faq { border: var(--line); border-radius: var(--r-md); background: var(--white); overflow: hidden; }
.faq + .faq { margin-top: 14px; }
.faq__q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  background: none;
  border: none;
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--choco);
  text-align: left;
  cursor: pointer;
}
.faq__q .faq__chev {
  flex: none;
  width: 34px; height: 34px;
  display: grid;
  place-items: center;
  border: var(--line);
  border-radius: 10px;
  background: var(--sunny-soft);
  transition: transform .25s ease;
}
.faq.is-open .faq__chev { transform: rotate(45deg); background: var(--terra-soft); }
.faq__a { max-height: 0; overflow: hidden; transition: max-height .35s ease; }
.faq__a-inner { padding: 0 24px 22px; color: var(--choco-70); }

/* ---------- Формы ---------- */
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 800; margin-bottom: 8px; font-size: .95rem; }
.input, select.input, textarea.input {
  width: 100%;
  padding: 14px 18px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  color: var(--choco);
  background: var(--white);
  border: var(--line);
  border-radius: var(--r-sm);
  transition: box-shadow .15s ease, border-color .15s ease;
}
.input:focus { outline: none; border-color: var(--terra); box-shadow: 4px 4px 0 var(--terra-soft); }

/* ---------- Результат инструмента ---------- */
.result {
  margin-top: 20px;
  padding: 22px;
  border: var(--line);
  border-radius: var(--r-md);
  background: var(--sunny-soft);
  display: none;
}
.result.is-visible { display: block; animation: popIn .35s cubic-bezier(.34, 1.56, .64, 1); }
.result--ok { background: var(--sage-soft); }
.result--warn { background: var(--sunny-soft); }
.result--danger { background: #F2CFC5; }
@keyframes popIn {
  from { opacity: 0; transform: scale(.94) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

/* ---------- Футер ---------- */
.footer {
  background: var(--choco);
  color: var(--cream);
  padding: clamp(48px, 6vw, 80px) 0 32px;
  margin-top: var(--section-y);
}
.footer a { color: var(--sunny); }
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 2px dashed rgba(251,243,228,.2);
}
.footer__title { font-family: var(--font-display); font-size: 1rem; color: var(--sunny); margin-bottom: 16px; }
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer ul a { color: var(--cream); text-decoration: none; opacity: .85; }
.footer ul a:hover { opacity: 1; color: var(--sunny); }
.footer__disclaimer { margin-top: 28px; font-size: .88rem; opacity: .7; max-width: 78ch; }
.footer__bottom { margin-top: 22px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .88rem; opacity: .75; }

/* ---------- Paw-cursor ---------- */
.paw-trail {
  position: fixed;
  z-index: 9999;
  pointer-events: none;
  width: 26px; height: 26px;
  opacity: 0;
  transform: translate(-50%, -50%) rotate(var(--rot, 0deg)) scale(var(--s, 1));
}
.paw-trail svg { width: 100%; height: 100%; }

/* ---------- ИИ-помощник ---------- */
.assistant-fab {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 95;
  width: 74px; height: 74px;
  padding: 0;
  background: var(--white);
  border: var(--line);
  border-radius: 26px;
  box-shadow: var(--shadow-sticker);
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease;
  overflow: hidden;
}
.assistant-fab:hover { transform: translate(-2px,-2px) rotate(-3deg); box-shadow: var(--shadow-sticker-hover); }
.assistant-fab img { width: 100%; height: 100%; object-fit: cover; }
.assistant-fab__dot {
  position: absolute;
  top: 6px; right: 6px;
  width: 16px; height: 16px;
  background: var(--terra);
  border: 2px solid var(--choco);
  border-radius: 50%;
  animation: pulse 1.8s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.25); }
}

.assistant-panel {
  position: fixed;
  right: 22px;
  bottom: 110px;
  z-index: 95;
  width: min(380px, calc(100vw - 32px));
  max-height: min(560px, calc(100vh - 140px));
  display: flex;
  flex-direction: column;
  background: var(--cream-2);
  border: var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sticker-hover);
  opacity: 0;
  transform: translateY(20px) scale(.96);
  pointer-events: none;
  transition: opacity .25s ease, transform .25s cubic-bezier(.34,1.56,.64,1);
}
.assistant-panel.is-open { opacity: 1; transform: none; pointer-events: auto; }

.assistant-panel__head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: var(--terra);
  color: var(--white);
  border-bottom: var(--line);
  border-radius: calc(var(--r-lg) - 3px) calc(var(--r-lg) - 3px) 0 0;
}
.assistant-panel__head img { width: 44px; height: 44px; border-radius: 14px; border: var(--line); background: var(--white); object-fit: cover; }
.assistant-panel__name { font-family: var(--font-display); font-weight: 700; font-size: .95rem; }
.assistant-panel__status { font-size: .8rem; opacity: .9; }
.assistant-panel__close {
  margin-left: auto;
  width: 34px; height: 34px;
  background: var(--white);
  color: var(--choco);
  border: var(--line);
  border-radius: 10px;
  font-size: 1.1rem;
  font-weight: 900;
  cursor: pointer;
  line-height: 1;
}

.assistant-panel__body {
  flex: 1;
  overflow-y: auto;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.msg {
  max-width: 85%;
  padding: 12px 16px;
  border: var(--line);
  border-radius: 18px;
  font-size: .95rem;
  animation: popIn .3s cubic-bezier(.34,1.56,.64,1);
}
.msg--bot { align-self: flex-start; background: var(--white); border-bottom-left-radius: 6px; }
.msg--user { align-self: flex-end; background: var(--terra-soft); border-bottom-right-radius: 6px; }
.msg__chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.msg__chip {
  padding: 7px 12px;
  font-size: .82rem;
  font-weight: 800;
  font-family: var(--font-body);
  color: var(--choco);
  background: var(--sunny-soft);
  border: var(--line);
  border-radius: 999px;
  cursor: pointer;
  transition: background .15s ease;
}
.msg__chip:hover { background: var(--sunny); }

.assistant-panel__demo {
  padding: 8px 18px;
  font-size: .78rem;
  font-weight: 700;
  color: var(--choco-70);
  background: var(--sunny-soft);
  border-top: 2px dashed var(--choco-10);
}
.assistant-panel__form { display: flex; gap: 10px; padding: 14px 18px; border-top: var(--line); }
.assistant-panel__form .input { padding: 11px 14px; font-size: .92rem; }
.assistant-panel__form .btn { padding: 11px 16px; }

/* ---------- Reveal-анимации ---------- */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s cubic-bezier(.22,1,.36,1); transition-delay: var(--d, 0s); }
.reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Разделитель-следы ---------- */
.paw-divider { display: flex; justify-content: center; gap: clamp(18px, 4vw, 40px); padding: 8px 0; opacity: .5; }
.paw-divider svg { width: 26px; height: 26px; }
.paw-divider svg:nth-child(odd) { transform: rotate(-14deg) translateY(4px); }
.paw-divider svg:nth-child(even) { transform: rotate(14deg) translateY(-4px); }

/* ---------- Врезки в статьях ---------- */
.prose { max-width: 72ch; }
.prose h2 { margin-top: 1.6em; }
.prose h3 { margin-top: 1.4em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: .5em; }

.callout {
  display: flex;
  gap: 16px;
  padding: 20px 24px;
  margin: 28px 0;
  border: var(--line);
  border-radius: var(--r-md);
  background: var(--sunny-soft);
  box-shadow: 4px 4px 0 var(--choco);
}
.callout--danger { background: #F2CFC5; }
.callout--sage { background: var(--sage-soft); }
.callout__icon { flex: none; width: 40px; height: 40px; display: grid; place-items: center; background: var(--white); border: var(--line); border-radius: 12px; font-size: 1.2rem; }
.callout p:last-child { margin-bottom: 0; }

/* ---------- Адаптив ---------- */
@media (max-width: 1080px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 900px) {
  .nav, .header__cta { display: none; }
  .burger { display: block; }
  .hero__grid { grid-template-columns: 1fr; }
  .hero__art { max-width: 560px; margin-inline: auto; }
}

@media (max-width: 720px) {
  .grid--3, .grid--2 { grid-template-columns: 1fr; }
  .sos-banner__inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 560px) {
  body { font-size: 16.5px; }
  .stats { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .hero__actions .btn { width: 100%; justify-content: center; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}

/* Аннотация проекта над шапкой: даёт читателю и краулеру суть страницы
   в первых же строках документа (canonical summary). */
.site-tagline {
  margin: 0;
  padding: 8px 20px;
  background: var(--cream-2, #FFF9EE);
  border-bottom: 1px solid rgba(51,36,26,.12);
  font-size: .82rem;
  line-height: 1.45;
  color: rgba(51,36,26,.72);
  text-align: center;
}
@media (max-width: 640px) { .site-tagline { font-size: .76rem; padding: 7px 14px; } }

/* ================= Мобильная адаптация и выравнивание (11.08.2026) =================
   Правки по инструментальному аудиту на 375 / 768 / 1280 px. */

/* Бегущая строка маскирует углы поворота через scale(1.02) и потому шире вьюпорта —
   на мобиле это давало горизонтальный скролл всей страницы.
   overflow-x: clip обрезает, НЕ создавая скролл-контейнер: в отличие от hidden
   он не ломает position: sticky у шапки. */
html { overflow-x: clip; }

/* Дети грида по умолчанию minmax(auto, 1fr): длинный заголовок или nowrap-контент
   раздувает колонку, и карточка вылезает за контейнер (ловилось на research 1280px
   и health 375px). min-width: 0 разрешает колонке сжиматься. */
.grid > *,
.hero__grid > *,
.form-grid > * { min-width: 0; }

/* Карточки в одном ряду — одной высоты: фон и рамка доходят до низа ряда,
   иначе соседние карточки «ступеньками». */
.grid { align-items: stretch; }
.grid > .card { height: 100%; }

@media (max-width: 720px) {
  /* .grid--4 оставался двухколоночным (177px + 222px + gap не влезали в 375px) */
  .grid--4 { grid-template-columns: 1fr; }

  /* Поворот и масштаб ленты на узком экране только мешают */
  .marquee,
  .marquee--sunny { transform: none; }

  /* Тач-цели: ссылки-CTA в карточках были 23px по высоте. Селектор берёт только
     прямых детей карточки (ссылок внутри абзацев на сайте нет — проверено),
     поэтому текстовый поток не ломается. */
  .card > a:not(.btn) {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }

  /* Аннотация над шапкой на узком экране — компактнее и по левому краю читается легче */
  .site-tagline { text-align: left; }
}
