/* ============================================================
   Чемодан — магазин чемоданов. Дизайн-система.
   Палитра путешествий: глубокий синий + бирюза + дорожный зелёный
   + тёплый оранжевый (акцент) на песочных нейтралах.
   Редакционная подача: засечный display, воздух, мягкие тени.
   ============================================================ */

:root {
  /* нейтрали — тёплый песок, но приглушённый, не «крем» */
  --ink:       #17262e;
  --ink-soft:  #495a62;
  --muted:     #5f655e;   /* тёмный тёплый серый: ≥4.5:1 и на белом, и на песке --sand/--sand-2 (WCAG AA) */
  --line:      #e7e0d3;
  --line-2:    #d8cebd;
  --surface:   #ffffff;
  --sand:      #f4efe4;   /* фон страницы */
  --sand-2:    #ece4d4;   /* приглушённые секции */

  /* фирменные цвета */
  --blue:      #123a5f;   /* глубокий синий — основной */
  --blue-ink:  #0d2c48;
  --turq:      #159a92;   /* бирюза — второй акцент, теги, «в наличии» */
  --green:     #3c8a63;   /* дорожный зелёный — статусы */
  --orange:    #e8801f;   /* тёплый оранжевый — CTA-выделения, цена, рейтинг */
  --orange-ink:#cf6d13;

  --sale:      #c0532a;   /* скидка — приглушённый терракотово-оранжевый, не кричит */
  --star:      #e8801f;
  --ok:        #2f7a54;   /* затемнён для контраста ≥4.5:1 на белом (статус «в наличии») */

  --shadow:    0 1px 2px rgba(20,40,50,.04), 0 6px 18px rgba(20,40,50,.05);
  --shadow-md: 0 6px 22px rgba(20,40,50,.08);
  --shadow-lg: 0 22px 54px rgba(20,40,50,.15);

  --radius:    16px;
  --radius-sm: 10px;
  --maxw:      1240px;

  --font:      "Segoe UI", system-ui, -apple-system, "Helvetica Neue", "PT Sans", Roboto, Arial, sans-serif;
  --font-head: "Georgia", "Iowan Old Style", "Palatino Linotype", "Times New Roman", "PT Serif", serif;
}

:root[data-theme="dark"] {
  --ink:       #e9f0f0;
  --ink-soft:  #aebcbd;
  --muted:     #7c8888;
  --line:      #223037;
  --line-2:    #2e3d44;
  --surface:   #16232a;
  --sand:      #0e171c;
  --sand-2:    #131f25;

  --blue:      #4f9bcf;
  --blue-ink:  #6fb0dc;
  --turq:      #2fc0b5;
  --green:     #57b083;
  --orange:    #f0954a;
  --orange-ink:#f7a866;

  --sale:      #de7a52;
  --star:      #f0954a;
  --ok:        #57b083;

  --shadow:    0 1px 2px rgba(0,0,0,.35), 0 8px 22px rgba(0,0,0,.4);
  --shadow-md: 0 8px 26px rgba(0,0,0,.45);
  --shadow-lg: 0 24px 58px rgba(0,0,0,.55);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--sand);
  line-height: 1.6;
  font-size: 16.5px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0 0 .5em; font-weight: 700; line-height: 1.18; letter-spacing: -.01em; }
/* Заголовок для скринридеров без визуального веса (чтобы не пропускать уровни). */
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--turq); outline-offset: 2px; border-radius: 4px; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  padding: .72em 1.4em; border-radius: 999px; border: 1.5px solid transparent;
  font: inherit; font-weight: 600; cursor: pointer; transition: transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s;
  background: var(--surface); color: var(--ink); border-color: var(--line-2);
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn--primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn--primary:hover { background: var(--blue-ink); border-color: var(--blue-ink); }
.btn--accent { background: var(--orange); border-color: var(--orange); color: #fff; }
.btn--accent:hover { background: var(--orange-ink); border-color: var(--orange-ink); }
.btn--ghost { background: transparent; }
.btn--ghost:hover { border-color: var(--ink); }
.btn--lg { padding: .9em 1.8em; font-size: 1.03rem; }
.btn--block { width: 100%; }

/* ---------- Топбар ---------- */
.topbar { background: var(--blue); color: #dfe8ee; font-size: .82rem; }
:root[data-theme="dark"] .topbar { background: #0b1418; }
.topbar__inner { display: flex; align-items: center; gap: 22px; height: 40px; }
.topbar__spacer { flex: 1; }
.topbar__city { font-weight: 600; color: #fff; display: flex; align-items: center; gap: 6px; }
.topbar__item { color: #cfdae1; transition: color .15s; }
.topbar__item:hover { color: #fff; }
.topbar__rating { color: #fff; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.topbar__rating .stars { color: var(--orange); }

/* ---------- Шапка ---------- */
.masthead { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 40; }
.masthead__inner { display: flex; align-items: center; gap: 28px; height: 86px; }

.brand { display: flex; align-items: center; gap: 13px; color: var(--ink); flex-shrink: 0; }
.brand__mark { color: var(--blue); display: flex; }
:root[data-theme="dark"] .brand__mark { color: var(--turq); }
.brand__text { display: flex; flex-direction: column; }
.brand__name { font-family: var(--font-head); font-size: 1.65rem; font-weight: 700; letter-spacing: -.01em; line-height: 1; }
.brand__sub { font-size: .68rem; color: var(--muted); letter-spacing: .07em; text-transform: uppercase; margin-top: 4px; }

.searchbar { flex: 1; max-width: 480px; display: flex; align-items: center;
  background: var(--sand); border: 1.5px solid var(--line-2); border-radius: 999px; padding: 4px 5px 4px 20px; transition: border-color .15s, background .15s; }
.searchbar:focus-within { border-color: var(--turq); background: var(--surface); }
.searchbar input { flex: 1; border: 0; background: transparent; font: inherit; color: var(--ink); padding: 9px 0; outline: none; }
.searchbar button { width: 42px; height: 42px; border: 0; border-radius: 999px; background: var(--blue); color: #fff; cursor: pointer; display: grid; place-items: center; flex-shrink: 0; transition: background .15s; }
.searchbar button:hover { background: var(--blue-ink); }

.masthead__actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.phone { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.15; }
.phone__num { font-weight: 700; font-size: 1.03rem; white-space: nowrap; }
.phone__hint { font-size: .68rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
/* Anti-scrape контакты: телефон/почта собираются JS из base64; текст не выделяется
   и не копируется. cursor:pointer — чтобы выглядели как ссылка ещё до сборки. */
.c-contact { cursor: pointer; }
.c-contact__val { -webkit-user-select: none; -moz-user-select: none; user-select: none; }
.icon-btn { width: 46px; height: 46px; border: 1.5px solid var(--line-2); background: var(--surface); border-radius: 12px;
  display: grid; place-items: center; cursor: pointer; color: var(--ink); position: relative; transition: border-color .15s, color .15s; }
.icon-btn:hover { border-color: var(--turq); color: var(--turq); }
.cart-count { position: absolute; top: -7px; right: -7px; min-width: 20px; height: 20px; padding: 0 5px;
  background: var(--orange); color: #fff; border-radius: 999px; font-size: .72rem; font-weight: 700; display: grid; place-items: center; }
.theme-toggle .i-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .i-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .i-moon { display: block; }
.nav-toggle { display: none; }

/* ---------- Основное меню ---------- */
.mainnav { border-top: 1px solid var(--line); background: var(--surface); }
.mainnav__inner { display: flex; gap: 2px; height: 52px; align-items: center; overflow-x: auto; scrollbar-width: none; }
.mainnav__inner::-webkit-scrollbar { display: none; }
.mainnav__item { padding: 9px 15px; border-radius: 8px; font-weight: 500; font-size: .95rem; color: var(--ink-soft); white-space: nowrap; transition: color .14s, background .14s; position: relative; }
.mainnav__item:hover { color: var(--ink); }
.mainnav__item.is-active { color: var(--blue); }
:root[data-theme="dark"] .mainnav__item.is-active { color: var(--turq); }
.mainnav__item.is-active::after { content: ""; position: absolute; left: 15px; right: 15px; bottom: -1px; height: 2px; background: var(--orange); border-radius: 2px; }
.mainnav__item--accent { color: var(--sale); font-weight: 600; }  /* терракота: контраст ≥4.5:1 на белом */

/* ---------- Секции ---------- */
.site-main { min-height: 60vh; }
.section { padding: 60px 0; }
.section--muted { background: var(--sand-2); }
.section__head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 30px; gap: 16px; }
.section__title { font-family: var(--font-head); font-size: 2rem; font-weight: 700; margin: 0; text-wrap: balance; }
.section__title--center { text-align: center; margin-bottom: 34px; }
.section__more { color: var(--blue); font-weight: 600; white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; transition: gap .15s, color .15s; }
:root[data-theme="dark"] .section__more { color: var(--turq); }
.section__more:hover { gap: 9px; color: var(--sale); }
.eyebrow { color: #0e6f68; font-weight: 700; font-size: .8rem; text-transform: uppercase; letter-spacing: .12em; margin-bottom: 12px; }
:root[data-theme="dark"] .eyebrow { color: var(--turq); }

/* ---------- Герой (редакционный, без вращений) ---------- */
.hero { padding: 64px 0 56px; }
.hero__inner { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.hero__eyebrow { color: #0e6f68; font-weight: 700; font-size: .82rem; text-transform: uppercase; letter-spacing: .12em; margin-bottom: 18px; }
:root[data-theme="dark"] .hero__eyebrow { color: var(--turq); }  /* на тёмном фоне светлая бирюза уже контрастна */
.hero__title { font-family: var(--font-head); font-size: clamp(2.3rem, 4.6vw, 3.7rem); font-weight: 700; letter-spacing: -.02em; line-height: 1.08; margin-bottom: 22px; text-wrap: balance; }
.hero__lead { font-size: 1.12rem; color: var(--ink-soft); max-width: 32em; line-height: 1.65; }
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; margin: 30px 0 34px; }
.hero__facts { list-style: none; padding: 0; margin: 0; display: flex; gap: 36px; flex-wrap: wrap; }
.hero__facts li { font-size: .9rem; color: var(--muted); }
.hero__facts strong { display: block; font-family: var(--font-head); font-size: 1.7rem; color: var(--ink); font-weight: 700; }

/* большое фото товара как герой-образ, без вращений и градиентов */
.hero__media { position: relative; }
.hero__photo { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-lg); }
.hero__photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: center; }
.hero__photo--contain { background: #fff; }
.hero__photo--contain img { object-fit: contain; padding: 20px; mix-blend-mode: multiply; }
.hero__caption { position: absolute; left: 18px; bottom: 18px; right: 18px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(8px); border: 1px solid var(--line);
  border-radius: 14px; padding: 12px 16px; }
.hero__caption b { display: block; font-size: .95rem; }
.hero__caption span { font-size: .78rem; color: var(--muted); }
.hero__caption .price__now { font-family: var(--font-head); font-size: 1.3rem; }
.hero__thumb { position: absolute; top: -22px; right: -18px; width: 128px; background: var(--surface); border: 1px solid var(--line);
  border-radius: 16px; padding: 10px; box-shadow: var(--shadow-lg); }
.hero__thumb img { aspect-ratio: 1; object-fit: contain; mix-blend-mode: multiply; }

/* ---------- Плитки категорий ---------- */
.cats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.cat { border-radius: var(--radius); padding: 24px; min-height: 150px; display: flex; flex-direction: column; justify-content: flex-end;
  border: 1px solid var(--line); background: var(--surface); transition: transform .18s, box-shadow .18s, border-color .18s; position: relative; overflow: hidden; }
.cat:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; }
.cat__tag { position: absolute; top: 18px; left: 18px; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: #fff; }
.cat__label { font-family: var(--font-head); font-size: 1.28rem; font-weight: 700; }
.cat__desc { font-size: .86rem; color: var(--muted); }
.cat--s .cat__tag { background: var(--turq); }
.cat--m .cat__tag { background: var(--blue); }
.cat--l .cat__tag { background: var(--green); }
.cat--sale .cat__tag { background: var(--orange); }
.cat--sale .cat__label { color: var(--sale); }

/* ---------- Сетка товаров ---------- */
.grid { display: grid; gap: 22px; }
.grid--cards { grid-template-columns: repeat(4, 1fr); }

.pcard { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  display: flex; flex-direction: column; transition: transform .2s, box-shadow .2s, border-color .2s; }
.pcard:hover { border-color: transparent; box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.pcard__media { position: relative; display: block; aspect-ratio: 1; background: #fff; overflow: hidden; }
.pcard__media img { width: 100%; height: 100%; object-fit: contain; padding: 16px; mix-blend-mode: multiply; transition: transform .35s ease; }
.pcard:hover .pcard__media img { transform: scale(1.05); }
.pcard__badge { position: absolute; top: 12px; left: 12px; background: var(--sale); color: #fff; font-weight: 700; font-size: .76rem; padding: 4px 9px; border-radius: 8px; z-index: 2; }
.pcard__noimg { display: grid; place-items: center; height: 100%; color: var(--line-2); }
.pcard__body { padding: 16px 17px 18px; display: flex; flex-direction: column; flex: 1; }
.pcard__brand { font-size: .73rem; text-transform: uppercase; letter-spacing: .06em; color: #0e6f68; font-weight: 700; }
:root[data-theme="dark"] .pcard__brand { color: var(--turq); }  /* на тёмной карточке светлая бирюза контрастна */
.pcard__name { font-size: .97rem; font-weight: 600; margin: 5px 0 9px; line-height: 1.34; }
.pcard__name a { transition: color .15s; }
.pcard__name a:hover { color: var(--blue); }
:root[data-theme="dark"] .pcard__name a:hover { color: var(--turq); }
.pcard__meta { display: flex; gap: 11px; flex-wrap: wrap; font-size: .78rem; color: var(--muted); margin-bottom: 14px; }
.pcard__meta span { position: relative; }
.pcard__meta span + span::before { content: ""; position: absolute; left: -6px; top: 50%; width: 3px; height: 3px; background: var(--line-2); border-radius: 50%; transform: translateY(-50%); }
.pcard__foot { margin-top: auto; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; }
.price__now { font-family: var(--font-head); font-size: 1.28rem; font-weight: 700; }
.price__old { display: block; font-size: .82rem; color: var(--muted); text-decoration: line-through; }
.btn-cart { width: 46px; height: 46px; flex-shrink: 0; border: 1.5px solid var(--line-2); color: var(--blue);
  background: transparent; border-radius: 12px; cursor: pointer; display: grid; place-items: center; transition: background .15s, color .15s, border-color .15s; }
:root[data-theme="dark"] .btn-cart { color: var(--turq); }
.btn-cart:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-cart.is-added { background: var(--ok); border-color: var(--ok); color: #fff; }

/* ---------- Рейтинг ---------- */
.stars { display: inline-flex; gap: 1px; color: var(--star); line-height: 1; letter-spacing: 1px; }
.stars--muted { color: var(--line-2); }

/* ---------- Trust-полоса ---------- */
.trust { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.trust__item { display: flex; gap: 14px; align-items: flex-start; }
.trust__ic { flex-shrink: 0; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--sand-2); color: var(--blue); }
:root[data-theme="dark"] .trust__ic { color: var(--turq); }
.trust__item h3 { font-size: 1rem; margin: 2px 0 3px; }
.trust__item p { font-size: .87rem; color: var(--muted); margin: 0; }

/* ---------- Бренды ---------- */
.brands { display: flex; flex-wrap: wrap; gap: 11px; justify-content: center; }
.brands__item { display: flex; align-items: center; gap: 9px; padding: 11px 18px; border: 1px solid var(--line);
  border-radius: 999px; background: var(--surface); font-weight: 600; transition: border-color .15s, color .15s, transform .15s; }
.brands__item:hover { border-color: var(--turq); color: var(--turq); transform: translateY(-2px); }
.brands__count { font-size: .78rem; color: var(--muted); font-weight: 500; }

/* ---------- Преимущества ---------- */
.benefits { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.benefit { padding: 26px 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: box-shadow .18s, transform .18s; }
.benefit:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.benefit__n { font-family: var(--font-head); font-size: 1.1rem; color: var(--sale); font-weight: 700; margin-bottom: 10px; }
.benefit h3 { font-size: 1.08rem; }
.benefit p { font-size: .9rem; color: var(--ink-soft); margin: 0; }

.about-snippet { max-width: 780px; }
.about-snippet h2 { font-family: var(--font-head); font-size: 1.9rem; }
.about-snippet p { color: var(--ink-soft); font-size: 1.02rem; }
.about-snippet a { color: var(--blue); font-weight: 600; }
:root[data-theme="dark"] .about-snippet a { color: var(--turq); }

/* ---------- Отзывы ---------- */
.reviews { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.review { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; display: flex; flex-direction: column; }
.review__stars { margin-bottom: 12px; }
.review__text { color: var(--ink-soft); font-size: .95rem; line-height: 1.62; margin: 0 0 18px; }
.review__foot { margin-top: auto; display: flex; align-items: center; gap: 12px; }
.review__ava { width: 42px; height: 42px; border-radius: 50%; background: var(--sand-2); color: var(--blue); display: grid; place-items: center; font-weight: 700; font-family: var(--font-head); flex-shrink: 0; }
:root[data-theme="dark"] .review__ava { color: var(--turq); }
.review__who b { display: block; font-size: .92rem; }
.review__who span { font-size: .78rem; color: var(--muted); }
.reviews-head { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 30px; }
.reviews-head .section__title { margin: 0; }
.reviews-score { display: flex; align-items: center; gap: 12px; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.reviews-score b { font-family: var(--font-head); font-size: 1.5rem; }
.reviews-score span { font-size: .82rem; color: var(--muted); }

/* ---------- Хлебные крошки ---------- */
.crumbs { padding: 22px 0 4px; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 9px; padding: 0; margin: 0; font-size: .84rem; color: var(--muted); }
.crumbs li { display: flex; gap: 9px; align-items: center; }
.crumbs li::after { content: "→"; color: var(--line-2); }
.crumbs li:last-child::after { display: none; }
.crumbs a { transition: color .15s; }
.crumbs a:hover { color: var(--blue); }
:root[data-theme="dark"] .crumbs a:hover { color: var(--turq); }

/* ---------- Каталог ---------- */
.cat-head { padding: 12px 0 24px; display: flex; align-items: baseline; gap: 15px; flex-wrap: wrap; }
.cat-head__title { font-family: var(--font-head); font-size: 2.2rem; margin: 0; }
.cat-head__count { color: var(--muted); }

.catalog { display: grid; grid-template-columns: 258px 1fr; gap: 32px; align-items: start; padding-bottom: 60px; }
.filters { position: sticky; top: 104px; }
.filters__form { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; max-height: calc(100vh - 124px); }
.filters__scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; margin: 0 -20px; padding: 0 20px; }
.filters__head { display: flex; justify-content: space-between; align-items: center; font-weight: 700; margin-bottom: 12px; font-family: var(--font-head); font-size: 1.15rem; }
.filters__reset { font-size: .82rem; color: var(--sale); font-weight: 600; font-family: var(--font); }
.filters__group { border: 0; border-top: 1px solid var(--line); padding: 18px 0 6px; margin: 0; }
.filters__group legend { font-weight: 600; font-size: .9rem; padding: 0; margin-bottom: 12px; }
.filters__group--scroll { max-height: none; overflow: visible; }
.filters__price { display: flex; align-items: center; gap: 8px; }
.filters__price input { width: 100%; padding: 10px 11px; border: 1.5px solid var(--line-2); border-radius: 9px; background: var(--sand); color: var(--ink); font: inherit; }
.filters__price input:focus { border-color: var(--turq); outline: none; background: var(--surface); }
.filters__apply { width: 100%; margin-top: 16px; flex-shrink: 0; }
.check { display: flex; align-items: center; gap: 10px; padding: 6px 0; cursor: pointer; font-size: .9rem; }
.check input { width: 17px; height: 17px; accent-color: var(--blue); cursor: pointer; }
.check span:first-of-type { flex: 1; }
.check__n { color: var(--muted); font-size: .78rem; }
.check--switch { justify-content: space-between; }

.catalog__main { min-width: 0; }
.sortbar { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; flex-wrap: wrap; }
.sortbar__label { color: var(--muted); font-size: .88rem; }
.sortbar__opts { display: flex; gap: 6px; flex-wrap: wrap; }
.sortbar__opt { padding: 6px 14px; border-radius: 999px; font-size: .86rem; color: var(--ink-soft); border: 1px solid var(--line); background: var(--surface); transition: border-color .14s, color .14s; }
.sortbar__opt:hover { border-color: var(--turq); color: var(--turq); }
.sortbar__opt.is-active { background: var(--blue); border-color: var(--blue); color: #fff; }
.filters-toggle { display: none; }

.empty { text-align: center; padding: 60px 20px; color: var(--ink-soft); }
.empty .btn { margin-top: 16px; }

/* ---------- Пагинация ---------- */
.pager { display: flex; gap: 7px; justify-content: center; align-items: center; margin: 40px 0 4px; flex-wrap: wrap; }
.pager__btn { min-width: 44px; height: 44px; padding: 0 13px; display: grid; place-items: center; border: 1px solid var(--line-2);
  border-radius: 12px; background: var(--surface); font-weight: 600; transition: border-color .14s, color .14s; }
.pager__btn:hover { border-color: var(--turq); color: var(--turq); }
.pager__btn.is-current { background: var(--blue); border-color: var(--blue); color: #fff; }
.pager__gap { color: var(--muted); padding: 0 4px; }

/* ---------- SEO-текст ---------- */
.seo-text { max-width: 840px; }
.seo-text h2 { font-family: var(--font-head); font-size: 1.55rem; }
.seo-text p { color: var(--ink-soft); font-size: .98rem; }

/* ---------- Карточка товара ---------- */
.product { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 46px; padding: 10px 0 24px; align-items: start; }
.product__gallery { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 20px;
  padding: 34px; position: sticky; top: 104px; }
.product__gallery img { width: 100%; aspect-ratio: 1; object-fit: contain; mix-blend-mode: multiply; }
.product__badge { position: absolute; top: 18px; left: 18px; background: var(--sale); color: #fff; font-weight: 700; padding: 5px 12px; border-radius: 9px; }
.product__noimg { display: grid; place-items: center; aspect-ratio: 1; color: var(--line-2); }

.product__brand { text-transform: uppercase; letter-spacing: .07em; font-size: .82rem; color: #0e6f68; font-weight: 700; }
:root[data-theme="dark"] .product__brand { color: var(--turq); }
.product__title { font-family: var(--font-head); font-size: clamp(1.6rem, 3vw, 2.3rem); margin: 8px 0 14px; text-wrap: balance; }
.product__sub { display: flex; gap: 18px; flex-wrap: wrap; align-items: center; font-size: .86rem; color: var(--muted); margin-bottom: 24px; }
.product__stock { color: var(--ok); font-weight: 600; }

.product__buy { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; margin-bottom: 24px; box-shadow: var(--shadow); }
.product__price { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 20px; }
.product__price-now { font-family: var(--font-head); font-size: 2.3rem; font-weight: 700; }
.product__price-old { font-size: 1.1rem; color: var(--muted); text-decoration: line-through; }
.product__price-save { font-size: .84rem; color: var(--sale); font-weight: 600; background: color-mix(in srgb, var(--sale) 12%, transparent); padding: 4px 10px; border-radius: 8px; }
.product__actions { display: flex; gap: 12px; }
.qty { display: flex; align-items: center; border: 1.5px solid var(--line-2); border-radius: var(--radius-sm); overflow: hidden; }
.qty__btn { width: 46px; height: 50px; border: 0; background: var(--sand); font-size: 1.3rem; cursor: pointer; color: var(--ink); transition: background .14s; }
.qty__btn:hover { background: var(--sand-2); }
.qty__val { width: 48px; height: 50px; text-align: center; border: 0; background: transparent; font: inherit; font-weight: 700; color: var(--ink); }
.product__actions .btn { flex: 1; }
.product__hint { font-size: .84rem; color: var(--muted); margin: 18px 0 0; }
.product__hint a { color: var(--blue); font-weight: 600; }
:root[data-theme="dark"] .product__hint a { color: var(--turq); }

/* Галерея: превью-полоса */
.gallery__thumbs { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.gallery__thumb { width: 66px; height: 66px; padding: 5px; flex: 0 0 auto; cursor: pointer;
  background: #fff; border: 1.5px solid var(--line); border-radius: 11px; transition: border-color .14s; }
.gallery__thumb:hover { border-color: var(--line-2); }
.gallery__thumb.is-active { border-color: var(--turq); }
.gallery__thumb img { width: 100%; height: 100%; aspect-ratio: 1; object-fit: contain; mix-blend-mode: multiply; }

/* Варианты: другие размеры / цвета */
.variants { display: flex; align-items: center; gap: 12px 16px; flex-wrap: wrap; margin-bottom: 18px; }
.variants__label { font-size: .86rem; color: var(--muted); font-weight: 600; }
.variants__items { display: flex; gap: 10px; flex-wrap: wrap; }
.variant { display: inline-flex; align-items: center; gap: 9px; padding: 6px 13px 6px 6px;
  background: var(--surface); border: 1.5px solid var(--line-2); border-radius: 11px;
  font-size: .9rem; font-weight: 600; color: var(--ink); transition: border-color .14s, box-shadow .14s; }
.variant:hover { border-color: var(--turq); box-shadow: var(--shadow); }
.variant img { width: 42px; height: 42px; object-fit: contain; mix-blend-mode: multiply; border-radius: 7px; background: #fff; }
.variant--color { padding: 4px; }
.variant--color img { width: 50px; height: 50px; }

.specs { display: grid; gap: 0; margin: 0; }
.specs > div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 2px; border-bottom: 1px solid var(--line); }
.specs dt { color: var(--muted); margin: 0; }
.specs dd { margin: 0; font-weight: 600; text-align: right; }

.product-desc { max-width: 780px; padding: 10px 0 12px; }
.product-desc h2 { font-family: var(--font-head); font-size: 1.5rem; }
.product-desc p { color: var(--ink-soft); font-size: 1.02rem; line-height: 1.7; }

.delivery-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 24px 0 10px; }
.delivery-strip > div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.delivery-strip strong { display: block; margin-bottom: 4px; }
.delivery-strip span { font-size: .86rem; color: var(--muted); }

/* ---------- Корзина ---------- */
.cart__grid { display: grid; grid-template-columns: 1fr 370px; gap: 28px; align-items: start; padding-bottom: 60px; }
.cart__items { display: flex; flex-direction: column; gap: 14px; }
.cart-item { display: grid; grid-template-columns: 80px 1fr auto; gap: 16px; align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.cart-item__img { width: 80px; height: 80px; object-fit: contain; background: #fff; border-radius: 10px; padding: 5px; mix-blend-mode: multiply; }
.cart-item__name { font-weight: 600; font-size: .95rem; }
.cart-item__name a:hover { color: var(--blue); }
.cart-item__price { color: var(--muted); font-size: .86rem; margin-top: 3px; }
.cart-item__right { display: flex; flex-direction: column; align-items: flex-end; gap: 9px; }
.cart-item__sum { font-family: var(--font-head); font-weight: 700; white-space: nowrap; }
.cart-item__remove { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: .82rem; }
.cart-item__remove:hover { color: var(--sale); }
.cart-item .qty { transform: scale(.85); transform-origin: right; }

.cart__summary { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; position: sticky; top: 104px; box-shadow: var(--shadow); }
.cart__summary h2 { font-family: var(--font-head); font-size: 1.3rem; }
.cart__total-row { display: flex; justify-content: space-between; padding: 8px 0; color: var(--ink-soft); }
.cart__total-row--big { font-family: var(--font-head); font-size: 1.35rem; font-weight: 700; color: var(--ink); border-top: 1px solid var(--line); margin-top: 6px; padding-top: 16px; }
.order-form { margin-top: 20px; display: flex; flex-direction: column; gap: 13px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: .86rem; font-weight: 600; }
.field small { color: var(--muted); font-weight: 400; }
.field input, .field select, .field textarea { padding: 12px; border: 1.5px solid var(--line-2); border-radius: 10px;
  background: var(--sand); color: var(--ink); font: inherit; font-weight: 400; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--turq); outline: none; background: var(--surface); }
.order-form__policy { font-size: .76rem; color: var(--muted); margin: 2px 0 0; }
.order-form__policy a { color: var(--blue); }
:root[data-theme="dark"] .order-form__policy a { color: var(--turq); }

.cart__done { text-align: center; padding: 64px 20px; max-width: 540px; margin: 0 auto; }
.cart__done-icon { width: 66px; height: 66px; margin: 0 auto 20px; border-radius: 999px; background: var(--ok); color: #fff;
  font-size: 2rem; display: grid; place-items: center; }
.cart__done h2 { font-family: var(--font-head); }
.cart__done p { color: var(--ink-soft); }

/* ---------- Текстовые страницы ---------- */
.page { max-width: 800px; padding: 10px 0 56px; }
.page h1 { font-family: var(--font-head); font-size: 2.3rem; text-wrap: balance; }
.page__lead { font-size: 1.15rem; color: var(--ink-soft); line-height: 1.65; }
.page h2 { font-family: var(--font-head); font-size: 1.45rem; margin-top: 1.7em; }
.page p, .page li { color: var(--ink-soft); }
.page a:not(.btn) { color: var(--blue); font-weight: 500; }
:root[data-theme="dark"] .page a { color: var(--turq); }
.page__list { padding-left: 1.2em; }
.page__list li { margin-bottom: .45em; }
.page__muted { color: var(--muted); font-size: .92rem; }
.page__cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin: 20px 0; }
.page__card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.page__card h3 { font-size: 1.08rem; }
.page__card p { font-size: .9rem; margin: 0; }
.page__cta { display: flex; gap: 14px; margin-top: 30px; flex-wrap: wrap; }

.contacts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; margin: 22px 0 30px; }
.contacts__block { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.contacts__block h2 { font-family: var(--font-head); margin-top: 0; }
.contacts__phone { font-family: var(--font-head); font-size: 1.6rem; font-weight: 700; color: var(--ink); }
.contacts__phone:hover { color: var(--blue); }
.contacts__muted { color: var(--muted); }
.contacts__social { display: flex; gap: 14px; margin-top: 10px; }
.contacts__social a { color: var(--blue); font-weight: 600; }
:root[data-theme="dark"] .contacts__social a { color: var(--turq); }

/* ---------- Карта ---------- */
.map { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin: 8px 0 10px; box-shadow: var(--shadow); }
.map iframe { display: block; width: 100%; height: 380px; border: 0; }
.map__static { position: relative; height: 320px; background:
  repeating-linear-gradient(0deg, var(--sand-2) 0 39px, var(--line) 39px 40px),
  repeating-linear-gradient(90deg, var(--sand-2) 0 39px, var(--line) 39px 40px); }
.map__pin { position: absolute; top: 46%; left: 50%; transform: translate(-50%, -100%); color: var(--sale); }
.map__road { position: absolute; background: var(--line-2); }
.map__road--h { left: 0; right: 0; top: 46%; height: 8px; }
.map__road--v { top: 0; bottom: 0; left: 50%; width: 8px; transform: translateX(-50%); }
.map__label { position: absolute; top: calc(46% + 14px); left: 50%; transform: translateX(-50%); background: var(--surface);
  border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: .82rem; font-weight: 600; box-shadow: var(--shadow); white-space: nowrap; }

/* ---------- Страницы ошибок ---------- */
.errpage { text-align: center; padding: 90px 20px; }
.errpage__code { font-family: var(--font-head); font-size: 5.5rem; font-weight: 700; color: var(--blue); letter-spacing: -.03em; line-height: 1; }
:root[data-theme="dark"] .errpage__code { color: var(--turq); }
.errpage h1 { font-family: var(--font-head); font-size: 1.8rem; margin-top: 12px; }
.errpage p { color: var(--ink-soft); max-width: 34em; margin: 0 auto 26px; }
.errpage__actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Подвал ---------- */
.footer { background: var(--surface); border-top: 1px solid var(--line); margin-top: 48px; }
.footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 32px; padding: 52px 24px 38px; }
.footer__col h2 { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 16px; }
.footer__col a { display: block; color: var(--ink-soft); padding: 4px 0; font-size: .92rem; transition: color .14s; }
.footer__col a:hover { color: var(--blue); }
:root[data-theme="dark"] .footer__col a:hover { color: var(--turq); }
.footer__note { color: var(--ink-soft); font-size: .9rem; max-width: 30em; margin: 16px 0; }
.brand--footer .brand__name { font-size: 1.4rem; }
.footer__social { display: flex; gap: 14px; }
.footer__social a { color: var(--blue); font-weight: 600; font-size: .9rem; }
:root[data-theme="dark"] .footer__social a { color: var(--turq); }
.footer__contacts p { color: var(--ink-soft); font-size: .9rem; margin: 2px 0; }
.footer__phone { font-family: var(--font-head); font-size: 1.25rem; font-weight: 700; display: block; margin-bottom: 6px; }
.footer__bottom { border-top: 1px solid var(--line); }
.footer__bottom-inner { display: flex; justify-content: space-between; gap: 16px; padding: 18px 0; flex-wrap: wrap; }
.footer__bottom p { margin: 0; font-size: .82rem; color: var(--muted); }

/* ---------- Тост ---------- */
.toast { position: fixed; bottom: 26px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--blue); color: #fff; padding: 13px 24px; border-radius: 999px; box-shadow: var(--shadow-lg);
  opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; z-index: 100; font-weight: 600; font-size: .9rem; }
.toast.is-visible { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ============================================================
   Адаптив
   ============================================================ */
@media (max-width: 1080px) {
  .grid--cards { grid-template-columns: repeat(3, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .reviews { grid-template-columns: repeat(2, 1fr); }
  .trust { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .hero__inner { grid-template-columns: 1fr; gap: 36px; }
  .hero__thumb { display: none; }
  .benefits { grid-template-columns: repeat(2, 1fr); }
  .cats { grid-template-columns: repeat(2, 1fr); }
  .product { grid-template-columns: 1fr; }
  .product__gallery { position: static; max-width: 460px; margin: 0 auto; }
  .cart__grid { grid-template-columns: 1fr; }
  .cart__summary { position: static; }
}
@media (max-width: 820px) {
  .masthead__inner { height: auto; min-height: 68px; gap: 14px 14px; flex-wrap: wrap; padding-top: 10px; }
  .searchbar { order: 5; flex-basis: 100%; max-width: none; margin-bottom: 12px; }

  /* Компактная шапка при прокрутке: имя меньше, подпись и поиск скрыты, один ряд.
     Без анимаций — мгновенное переключение, чтобы высота не «плавала». */
  .masthead.is-compact .masthead__inner { min-height: 58px; padding-top: 0; flex-wrap: nowrap; }
  .masthead.is-compact .searchbar { display: none; }
  .masthead.is-compact .brand__sub { display: none; }
  .masthead.is-compact .brand__name { font-size: 1.25rem; }
  .phone { display: none; }
  .nav-toggle { display: grid; place-items: center; gap: 4px; width: 46px; height: 46px; border: 1.5px solid var(--line-2);
    border-radius: 12px; background: var(--surface); cursor: pointer; }
  .nav-toggle span { display: block; width: 18px; height: 2px; background: var(--ink); border-radius: 2px; }
  .mainnav { display: none; }
  .mainnav.is-open { display: block; position: absolute; left: 0; right: 0; box-shadow: var(--shadow-lg); }
  .mainnav.is-open .mainnav__inner { flex-direction: column; height: auto; align-items: stretch; padding: 10px 24px 16px; }
  .catalog { grid-template-columns: 1fr; }
  .filters { position: fixed; inset: 0; z-index: 60; background: var(--sand); overflow-y: auto; padding: 20px; display: none; }
  .filters.is-open { display: block; }
  .filters__form { max-height: none; }
  .filters__scroll { overflow: visible; }
  .filters__apply { position: sticky; bottom: 0; box-shadow: 0 -8px 16px -8px rgba(0,0,0,.25); }
  .filters-toggle { display: inline-flex; margin-bottom: 16px; }
  .page__cards, .contacts, .delivery-strip { grid-template-columns: 1fr; }
  .reviews { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .grid--cards { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .container { padding: 0 16px; }
  .topbar__item:not(.topbar__city), .topbar__rating { display: none; }
  .topbar__city { font-size: .78rem; }
  .benefits, .cats, .trust { grid-template-columns: 1fr; }
  .section { padding: 42px 0; }
  .footer__grid { grid-template-columns: 1fr; gap: 24px; }
  .hero__facts { gap: 20px; }
  .product__price-now { font-size: 1.9rem; }
  .pcard__media img { padding: 12px; }
}

/* Кнопка выбора города в топбаре (открывает модалку) */
.city-switch__btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: none; border: 0; cursor: pointer; padding: 0;
  color: #fff; font: inherit; font-weight: 600;
}
.city-switch__caret { font-size: .7em; opacity: .8; }

/* Модалка «Выберите город» */
.modal__dialog--wide { max-width: 640px; }
.city-search {
  display: flex; align-items: center; gap: 8px; margin-top: 4px; padding: 0 12px;
  border: 1.5px solid var(--line-2); border-radius: 10px; background: var(--sand); color: var(--ink-soft);
}
.city-search:focus-within { border-color: var(--turq); background: var(--surface); }
.city-search input { flex: 1; border: 0; background: transparent; font: inherit; color: var(--ink); padding: 11px 0; outline: none; }
.city-list { columns: 3; column-gap: 20px; list-style: none; margin: 18px 0 0; padding: 0; }
.city-list__row { break-inside: avoid; }
.city-list__item { display: block; padding: 5px 8px; border-radius: 7px; color: var(--ink); font-size: .95rem; }
.city-list__item:hover { background: var(--sand-2); }
.city-list__item.is-major { font-weight: 700; }
.city-list__item.is-current { color: var(--sale); font-weight: 700; }
.city-list__empty { color: var(--muted); padding: 12px 8px; margin: 0; }
@media (max-width: 560px) { .city-list { columns: 2; } }

/* Гео-подсказка над топбаром */
.geo-banner { background: var(--orange); color: #fff; }
.geo-banner__inner {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  min-height: 44px; padding-top: 8px; padding-bottom: 8px; font-size: .9rem;
}
.geo-banner__text { margin-right: auto; }
.geo-banner__yes {
  color: #fff; font-weight: 700; text-decoration: underline;
}
.geo-banner__no {
  background: rgba(255,255,255,.18); border: 0; color: #fff; cursor: pointer;
  padding: 6px 12px; border-radius: 7px; font: inherit;
}
.geo-banner__no:hover { background: rgba(255,255,255,.28); }

/* Блок «в городе пока нет магазина» */
.no-shop { max-width: 760px; }
.no-shop h2 { margin-bottom: .5em; }
.no-shop__cities { line-height: 2; }
.no-shop__cities a { color: var(--blue); font-weight: 600; white-space: nowrap; }
.no-shop__cities a:hover { text-decoration: underline; }
.hero__inner--single { display: block; }

/* Ссылка «Добавить адрес» в топбаре (город без своей точки) */
.topbar__addlink {
  background: none; border: 0; padding: 0; cursor: pointer; font: inherit;
  color: #f0a34d; font-weight: 600; text-decoration: underline; text-underline-offset: 2px;
}
.topbar__addlink:hover { color: #fff; }

/* Модалка (заявка «предложить магазин») */
.modal { position: fixed; inset: 0; z-index: 120; display: grid; place-items: center; padding: 20px; }
.modal[hidden] { display: none; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(10,18,22,.55); backdrop-filter: blur(2px); }
.modal__dialog {
  position: relative; z-index: 1; width: 100%; max-width: 440px;
  max-height: calc(100vh - 40px); overflow-y: auto;
  background: var(--surface); color: var(--ink); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 28px 26px;
}
.modal__x {
  position: absolute; top: 12px; right: 14px; width: 34px; height: 34px;
  border: 0; background: none; font-size: 1.5rem; line-height: 1; cursor: pointer;
  color: var(--ink-soft); border-radius: 8px;
}
.modal__x:hover { color: var(--ink); }
.modal__title { margin: 0 0 8px; font-size: 1.3rem; }
.modal__lead { color: var(--ink-soft); font-size: .95rem; margin: 0 0 18px; }
.modal__done { text-align: center; padding: 10px 0; }
.modal__done h3 { margin: 0 0 8px; }
.modal__done p { color: var(--ink-soft); margin: 0; }

/* ---------- Каталог продавцов (/magaziny/) ---------- */
.page__head { max-width: 760px; padding: 6px 0 4px; }
.page__head h1 { font-family: var(--font-head); font-size: 2.3rem; text-wrap: balance; }

.shops { display: grid; gap: 18px; }
.shop {
  display: flex; gap: 24px; align-items: center; flex-wrap: wrap;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px 24px; box-shadow: var(--shadow);
}
.shop__body { flex: 1 1 320px; }
.shop__name { font-family: var(--font-head); font-size: 1.3rem; margin: 0 0 8px; }
.shop__name a { color: var(--ink); }
.shop__name a:hover { color: var(--blue); }
:root[data-theme="dark"] .shop__name a:hover { color: var(--turq); }
.shop__addr { display: flex; align-items: center; gap: 7px; margin: 0 0 4px; color: var(--ink-soft); }
.shop__addr svg { flex: none; color: var(--sale); }
.shop__meta { margin: 0 0 4px; color: var(--muted); font-size: .92rem; }
.shop__count { margin: 8px 0 0; font-size: .92rem; color: var(--ink-soft); }
.shop__actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

.shop-cities { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.shop-cities__item {
  display: flex; flex-direction: column; gap: 2px; padding: 12px 20px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.shop-cities__item:hover { border-color: var(--turq); transform: translateY(-2px); }
.shop-cities__name { font-weight: 600; color: var(--ink); }
.shop-cities__count { font-size: .82rem; color: var(--muted); }

/* Страница магазина */
.shop-head { display: grid; grid-template-columns: 1fr 340px; gap: 32px; align-items: start; padding: 8px 0 10px; }
.shop-head h1 { font-family: var(--font-head); font-size: 2.2rem; text-wrap: balance; margin-bottom: 12px; }
.shop-head__card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow);
}
.shop-head__card .btn { width: 100%; justify-content: center; margin-top: 18px; }
.shop-facts { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 0; }
.shop-facts dt { color: var(--muted); font-size: .86rem; }
.shop-facts dd { margin: 0; color: var(--ink); font-size: .95rem; }

@media (max-width: 900px) {
  .shop-head { grid-template-columns: 1fr; }
}

/* ---------- Журнал (/zhurnal/) ---------- */
.grid--articles { grid-template-columns: repeat(3, 1fr); }
.acard {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); transition: transform .15s, border-color .15s;
}
.acard:hover { transform: translateY(-3px); border-color: var(--turq); }
.acard__link { display: flex; flex-direction: column; height: 100%; color: var(--ink); }
.acard__media { display: block; aspect-ratio: 16 / 9; background: var(--sand-2); }
.acard__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.acard__body { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px 20px; flex: 1; }
.acard__tag {
  align-self: flex-start; font-size: .72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .08em; color: #0e6f68;
}
:root[data-theme="dark"] .acard__tag { color: var(--turq); }
.acard__title { font-family: var(--font-head); font-size: 1.12rem; font-weight: 700; line-height: 1.3; }
.acard__excerpt { color: var(--ink-soft); font-size: .92rem; line-height: 1.55; flex: 1; }
.acard__meta { color: var(--muted); font-size: .8rem; }

.article { max-width: 720px; }
.article__meta { color: var(--muted); font-size: .88rem; margin-bottom: 1.2em; }
.article__cover img { width: 100%; height: auto; border-radius: var(--radius); display: block; }
.article h2 { margin-top: 1.8em; }
.article h3 { font-family: var(--font-head); font-size: 1.15rem; margin-top: 1.5em; }
/* Таблицы в статьях: на узких экранах прокручиваются внутри своей обёртки,
   страница по горизонтали не едет. */
.table-wrap { overflow-x: auto; margin: 1.5em 0; -webkit-overflow-scrolling: touch; }
.article table { width: 100%; border-collapse: collapse; font-size: .93rem; min-width: 420px; }
.article th, .article td {
  padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.article th { background: var(--sand-2); font-weight: 700; color: var(--ink); white-space: nowrap; }
.article td { color: var(--ink-soft); }
.article tbody tr:last-child td { border-bottom: 0; }
.article blockquote {
  margin: 1.4em 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--turq);
  color: var(--ink-soft); font-style: italic;
}
.article__author { color: var(--ink-soft); font-weight: 600; }

/* Подпись автора под статьёй */
.author-card {
  display: flex; gap: 14px; align-items: flex-start; margin-top: 2.4em;
  padding: 18px; background: var(--sand-2); border: 1px solid var(--line);
  border-radius: var(--radius);
}
.author-card__ava {
  flex: 0 0 auto; width: 44px; height: 44px; border-radius: 50%;
  /* color через --surface: в светлой теме белые буквы на синем, в тёмной — тёмные
     на светло-синем, контраст сохраняется в обеих. */
  display: grid; place-items: center; background: var(--blue); color: var(--surface);
  font-family: var(--font-head); font-weight: 700; font-size: .95rem;
}
.author-card__name { font-family: var(--font-head); font-weight: 700; margin: 0 0 4px; }
.author-card__role { margin: 0; color: var(--ink-soft); font-size: .92rem; line-height: 1.6; }

@media (max-width: 900px) { .grid--articles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid--articles { grid-template-columns: 1fr; } }

/* ---------- Плитки брендов (/brendy/) ---------- */
.brand-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.brand-tile {
  display: flex; flex-direction: column; gap: 4px; padding: 20px 22px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  transition: transform .15s, border-color .15s;
}
.brand-tile:hover { transform: translateY(-3px); border-color: var(--turq); }
.brand-tile__name { font-family: var(--font-head); font-size: 1.1rem; font-weight: 700; color: var(--ink); }
.brand-tile__meta { color: var(--muted); font-size: .84rem; }

@media (max-width: 900px) { .brand-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 620px) { .brand-grid { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Счётчики каталога на главной ---------- */
.stats {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px;
  padding: 22px 24px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.stats__item { display: flex; flex-direction: column; gap: 2px; text-align: center; }
.stats__item b { font-family: var(--font-head); font-size: 1.7rem; line-height: 1.1; color: var(--ink); }
.stats__item span { color: var(--muted); font-size: .82rem; }

@media (max-width: 860px) { .stats { grid-template-columns: repeat(3, 1fr); row-gap: 20px; } }
@media (max-width: 520px) { .stats { grid-template-columns: repeat(2, 1fr); } }

/* Характеристики в карточке товара (заполнены не у всех доноров) */
.pcard__specs { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 4px; font-size: .8rem; color: var(--muted); }

/* ---------- Блок журнала на главной ---------- */
.journal { display: grid; grid-template-columns: 1.15fr 1fr; gap: 22px; align-items: stretch; }
.jrn-lead {
  display: flex; flex-direction: column; gap: 10px; padding: 30px 32px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); transition: transform .15s, border-color .15s;
}
.jrn-lead:hover { transform: translateY(-3px); border-color: var(--turq); }
.jrn-lead__tag {
  font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em;
  color: #0e6f68;
}
:root[data-theme="dark"] .jrn-lead__tag { color: var(--turq); }
.jrn-lead__title {
  font-family: var(--font-head); font-size: 1.75rem; font-weight: 700;
  line-height: 1.22; color: var(--ink); text-wrap: balance;
}
.jrn-lead__excerpt { color: var(--ink-soft); line-height: 1.6; flex: 1; }
.jrn-lead__meta { color: var(--muted); font-size: .82rem; }
.jrn-lead__more { color: var(--blue); font-weight: 600; }
:root[data-theme="dark"] .jrn-lead__more { color: var(--turq); }

.jrn-list { display: grid; gap: 12px; align-content: start; }
.jrn-item {
  display: flex; flex-direction: column; gap: 4px; padding: 16px 20px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  transition: border-color .15s, transform .15s;
}
.jrn-item:hover { border-color: var(--turq); transform: translateX(3px); }
.jrn-item__title { font-weight: 600; color: var(--ink); line-height: 1.35; }
.jrn-item__meta { color: var(--muted); font-size: .8rem; }

@media (max-width: 900px) { .journal { grid-template-columns: 1fr; } }

/* ---------- Гиды и FAQ на главной ---------- */
.guides { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.guide {
  display: flex; flex-direction: column; gap: 8px; padding: 22px 20px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  transition: transform .15s, border-color .15s;
}
.guide:hover { transform: translateY(-3px); border-color: var(--turq); }
.guide__title { font-family: var(--font-head); font-weight: 700; color: var(--ink); }
.guide__desc { color: var(--ink-soft); font-size: .9rem; line-height: 1.5; }

.faq { max-width: 800px; margin: 0 auto; display: grid; gap: 12px; }
.faq__item {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 20px;
}
.faq__item summary {
  cursor: pointer; font-weight: 600; color: var(--ink); list-style: none;
  display: flex; justify-content: space-between; gap: 16px;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: '+'; color: var(--muted); font-size: 1.3rem; line-height: 1; }
.faq__item[open] summary::after { content: '−'; }
.faq__item p { margin: 12px 0 0; color: var(--ink-soft); font-size: .95rem; line-height: 1.65; }

@media (max-width: 900px) { .guides { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .guides { grid-template-columns: 1fr; } }
