/* ============================================================
   Витрина
   ============================================================ */

/* ---------- премиальный анимированный градиент-фон + фитнес-паттерн ---------- */
.bg-wash {
  position: fixed; inset: 0; z-index: -2; pointer-events: none; overflow: hidden;
  background:
    linear-gradient(130deg,
      color-mix(in oklab, var(--pg) 90%, var(--ac)) 0%,
      var(--pg) 24%,
      color-mix(in oklab, var(--pg) 93%, #7A2E8F) 50%,
      var(--pg) 76%,
      color-mix(in oklab, var(--pg) 88%, var(--ac)) 100%);
  background-size: 300% 300%;
  animation: bgShift 26s ease-in-out infinite;
}
.bg-wash::before, .bg-wash::after {
  content: ''; position: absolute; border-radius: 50%; filter: blur(75px); opacity: .55; will-change: transform;
}
.bg-wash::before {
  width: 62vw; height: 62vw; left: -12vw; top: -16vw;
  background: radial-gradient(circle, color-mix(in oklab, var(--ac) 42%, transparent), transparent 62%);
  animation: blobA 28s ease-in-out infinite;
}
.bg-wash::after {
  width: 56vw; height: 56vw; right: -12vw; bottom: -16vw;
  background: radial-gradient(circle, color-mix(in oklab, #7A2E8F 36%, transparent), transparent 62%);
  animation: blobB 32s ease-in-out infinite;
}
@keyframes bgShift { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes blobA {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(20vw, 12vh) scale(1.15); }
  66% { transform: translate(6vw, 26vh) scale(.92); }
}
@keyframes blobB {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-22vw, -14vh) scale(1.22); }
}
#bg-gym { position: fixed; inset: 0; z-index: -1; pointer-events: none; }

/* ---------- каркас: футер прижат к низу, без белой полосы на коротких страницах ---------- */
body { display: flex; flex-direction: column; min-height: 100vh; }
#view { flex: 1 0 auto; display: flex; flex-direction: column; }
#view > main { flex: 1; width: 100%; }
#footer { margin-top: auto; }

/* ---------- капсульный навбар ---------- */
.nav-wrap { position: fixed; top: 14px; left: 50%; transform: translateX(-50%); z-index: 50; max-width: calc(100vw - 16px); }
.nav-pill {
  position: relative; display: flex; align-items: stretch;
  border: 2px solid var(--ln); border-radius: var(--r-pill); overflow: hidden;
  box-shadow: 4px 4px 0 var(--ink-22), inset 0 -8px 14px rgba(0, 0, 0, .12), 0 14px 40px var(--ink-14);
}
.nav-gloss {
  position: absolute; top: 3px; left: 18px; right: 18px; height: 9px; border-radius: var(--r-pill);
  background: linear-gradient(180deg, rgba(255,255,255,.5), transparent); pointer-events: none; z-index: 2;
}
.nav-cap {
  display: flex; align-items: center; gap: 2px; border: none; cursor: pointer;
  padding: 8px 20px 8px 14px; border-right: 2px solid var(--ln);
  background: linear-gradient(180deg, color-mix(in oklab, var(--ac) 78%, #fff) 0%, var(--ac) 48%, color-mix(in oklab, var(--ac) 70%, #000) 100%);
}
.nav-logo { font-family: var(--f-display); font-size: 22px; color: #fff; line-height: 1; white-space: nowrap; letter-spacing: .03em; text-shadow: 1px 2px 0 rgba(0,0,0,.35); }
.nav-burger {
  display: none; place-items: center; width: 44px; border: none; cursor: pointer; color: #fff;
  padding-left: 4px;
  background: linear-gradient(180deg, color-mix(in oklab, var(--ac) 78%, #fff) 0%, var(--ac) 48%, color-mix(in oklab, var(--ac) 70%, #000) 100%);
}
/* когда виден бургер — убираем левый паддинг у плашки логотипа, чтобы синий был сплошным */
@media (max-width: 960px) { .nav-cap { padding-left: 4px; } }
.nav-body {
  display: flex; align-items: center; gap: 6px; padding: 6px 10px;
  background: var(--navbg); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.nav-link {
  border: none; border-radius: var(--r-pill); background: transparent; cursor: pointer;
  padding: 9px 14px; color: var(--mut); font-family: var(--f-body); font-weight: 600; font-size: 13.5px;
  white-space: nowrap; transition: background .15s ease, color .15s ease;
}
.nav-link:hover { background: rgba(127,127,127,.13); color: var(--tx); }
.nav-link.active { background: var(--ac); color: #fff; }
.nav-sep { width: 2px; align-self: stretch; margin: 6px 2px; background: var(--ln); opacity: .18; flex-shrink: 0; }
.nav-ico {
  width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--ln);
  display: grid; place-items: center; background: transparent; color: var(--tx); cursor: pointer; flex-shrink: 0;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.nav-ico:hover { transform: translateY(-1px); background: rgba(127,127,127,.1); }
.nav-ico.active { background: var(--ac); border-color: var(--ac); color: #fff; }
.nav-cart {
  display: flex; align-items: center; gap: 8px; border: 2px solid var(--ln); border-radius: var(--r-pill);
  background: transparent; color: var(--tx); cursor: pointer; padding: 6px 8px 6px 14px;
  font-weight: 700; font-size: 13px; transition: background .15s ease;
}
.nav-cart:hover { background: rgba(127,127,127,.12); }
.nav-cart.active { border-color: var(--ac); background: var(--ac-soft); }
.cart-badge {
  min-width: 22px; height: 22px; border-radius: var(--r-pill); padding: 0 6px;
  display: grid; place-items: center; font-family: var(--f-mono); font-size: 11.5px; font-weight: 700;
  background: rgba(127,127,127,.18); color: var(--mut); transition: background .2s ease, color .2s ease;
}
.cart-badge.on { background: var(--ac); color: #fff; }
.nav-menu {
  position: absolute; top: calc(100% + 10px); left: 0; min-width: 220px; z-index: 49;
  border: 2px solid var(--ln); border-radius: 16px; overflow: hidden;
  background: var(--cd); box-shadow: var(--sh-pop);
  display: flex; flex-direction: column; animation: fadeUp .18s ease both;
}
.nav-menu button {
  display: flex; align-items: center; gap: 10px; padding: 13px 18px; border: none; cursor: pointer;
  background: transparent; color: var(--tx); font-family: var(--f-body); font-weight: 600; font-size: 14px; text-align: left;
}
.nav-menu button:hover { background: rgba(127,127,127,.1); }
.nav-menu button + button { border-top: 1.5px solid var(--st2); }

@media (max-width: 960px) {
  .nav-link.desk { display: none; }
  .nav-burger { display: grid; }
}
@media (max-width: 430px) {
  .nav-logo { font-size: 18px; }
  .nav-cap { padding: 8px 14px 8px 10px; }
  .nav-cart span.txt { display: none; }
}
/* очень узкие экраны (≤360px): ужимаем навбар, чтобы кнопка корзины не обрезалась overflow:hidden */
@media (max-width: 360px) {
  .nav-body { gap: 2px; padding: 6px 6px; }
  .nav-logo { font-size: 16px; }
  .nav-cap { padding: 8px 8px 8px 6px; }
  .nav-ico { width: 30px; height: 30px; }
  .nav-cart { padding: 6px 8px; }
  .nav-sep { margin: 6px 1px; }
}

/* ---------- каркас страниц ---------- */
.page { animation: fadeUp .4s ease both; max-width: 1240px; margin: 0 auto; padding: 122px 24px 90px; }
.page-narrow { max-width: 900px; }
.section-head { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }
.section-num { font-family: var(--f-mono); font-size: 12px; color: var(--ac); font-weight: 700; }
.section-note { font-family: var(--f-mono); font-size: 11px; color: var(--mut2); }

/* ---------- hero (крупнее + живой градиент) ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(1000px 520px at 80% 26%, rgba(0,90,156,.32), transparent 66%),
    radial-gradient(760px 520px at 8% 96%, rgba(122,46,143,.28), transparent 62%),
    linear-gradient(135deg, #12151C 0%, #171B24 45%, #14171D 100%);
  background-size: 160% 160%, 160% 160%, 100% 100%;
  animation: heroGlow 20s ease-in-out infinite;
  color: #F2F3F0; padding: 160px 24px 0; border-bottom: 2px solid var(--ln);
}
@keyframes heroGlow { 0%, 100% { background-position: 0% 0%, 100% 100%, 0 0; } 50% { background-position: 100% 60%, 0% 30%, 0 0; } }
.hero-grid { position: relative; z-index: 1; max-width: 1240px; margin: 0 auto; display: grid; grid-template-columns: 1.05fr 1fr; gap: 52px; align-items: center; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; gap: 32px; } }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px; font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .18em;
  color: #10131A; background: #F2F3F0; padding: 7px 14px; border: 2px solid #10131A;
  border-radius: var(--r-chip); box-shadow: 3px 3px 0 var(--ac); margin-bottom: 30px;
}
.hero-badge::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--ac); box-shadow: 0 0 0 0 var(--ac); animation: pulseRing 2s ease-out infinite; }
.hero-name { font-family: var(--f-display); font-size: clamp(64px, 10vw, 140px); line-height: .92; color: #fff; text-shadow: 4px 5px 0 rgba(0,90,156,.5); }
.hero-title {
  margin: 20px 0 0; font-family: var(--f-head); font-weight: 900; font-size: clamp(20px, 2.8vw, 36px); letter-spacing: .02em; line-height: 1.12;
  background: linear-gradient(90deg, #4D9FDC, #8B5CF6, #FF3EA5, #FFD400, #4D9FDC);
  background-size: 300% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: hueSlide 6s linear infinite;
}
.hero-text { margin: 24px 0 34px; max-width: 560px; font-size: 17px; line-height: 1.7; color: #C3C7CD; text-wrap: pretty; }
/* hero-CTA: на пк — по контенту, рядом; на мобиле — делят строку, но остаются в ряд */
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.hero-cta .btn { flex: 0 0 auto; justify-content: center; white-space: nowrap; padding: 14px 26px; font-size: 13px; }
@media (max-width: 560px) {
  .hero-cta { flex-wrap: nowrap; }
  .hero-cta .btn { flex: 1 1 0; min-width: 0; white-space: normal; line-height: 1.15; padding: 12px 14px; font-size: 12px; }
}
/* «Кричащая» CTA: дышит, светится, по ней пробегает блик, стрелка подпрыгивает */
.hero-cta .btn-rainbow { padding: 16px 32px; font-size: 14.5px; }
.btn-rainbow {
  position: relative; overflow: hidden; border-radius: var(--r-btn);
  border: 2px solid #10131A; color: #fff; font-weight: 900; letter-spacing: .05em; text-shadow: 1px 1px 0 rgba(0,0,0,.55);
  background: linear-gradient(110deg, #FF3EA5, #FFD400, #3EE06B, #00C2FF, #FF3EA5);
  background-size: 300% 100%;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.6), 4px 4px 0 #10131A, 0 0 0 0 rgba(0,194,255,.55);
  animation: hueSlide 6s linear infinite, ctaPulse 1.9s ease-in-out infinite;
  transform-origin: center;
}
/* бегущий блик */
.btn-rainbow::after {
  content: ''; position: absolute; top: -20%; bottom: -20%; left: -60%; width: 38%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.8), transparent);
  transform: skewX(-18deg); animation: ctaShine 2.8s ease-in-out infinite; pointer-events: none;
}
.btn-rainbow .rb-label { position: relative; z-index: 1; }
.btn-rainbow .rb-arrow { position: relative; z-index: 1; display: inline-block; margin-left: 9px; font-weight: 900; animation: bobX .9s ease-in-out infinite; }
.btn-rainbow:hover {
  animation: hueSlide 3s linear infinite;
  transform: translate(-2px, -3px) scale(1.04);
  box-shadow: inset 0 0 0 2px #fff, 7px 8px 0 #10131A, 0 0 30px 6px rgba(0,194,255,.6);
}
.btn-rainbow:active { transform: translate(0, 0) scale(.99); }
@keyframes ctaPulse {
  0%, 100% { box-shadow: inset 0 0 0 2px rgba(255,255,255,.6), 4px 4px 0 #10131A, 0 0 0 0 rgba(0,194,255,.55); transform: translateY(0) scale(1); }
  50%      { box-shadow: inset 0 0 0 2px rgba(255,255,255,.9), 5px 6px 0 #10131A, 0 0 24px 5px rgba(0,194,255,.5); transform: translateY(-1px) scale(1.025); }
}
@keyframes ctaShine { 0% { left: -60%; } 55%, 100% { left: 130%; } }

.btn-hero-ghost { background: rgba(255,255,255,.04); color: #F2F3F0; border-color: #F2F3F0; box-shadow: none; }
.btn-hero-ghost:hover { background: #F2F3F0; color: #171A20; transform: translate(-2px,-2px); box-shadow: 4px 4px 0 rgba(0,0,0,.4); }
/* траст-строка под CTA */
.trust-row { display: flex; gap: 9px; flex-wrap: wrap; margin-bottom: 32px; }
.trust-chip { font-family: var(--f-mono); font-size: 11px; color: #C7CBD1;
  border: 1px solid rgba(255,255,255,.18); border-radius: var(--r-pill); padding: 6px 12px; background: rgba(255,255,255,.05); white-space: nowrap; }

/* контакты на главной */
.contacts-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 16px; }
.contact-tg { display: flex; align-items: center; gap: 14px; padding: 20px;
  border: 2px solid var(--ln); border-radius: var(--r-card); background: var(--cd); box-shadow: var(--sh-card);
  color: var(--tx); transition: transform .15s ease, box-shadow .15s ease; }
.contact-tg:hover { transform: translateY(-3px); box-shadow: var(--sh-card-hover); filter: none; }
.contact-tg.primary { background: linear-gradient(135deg, color-mix(in oklab, var(--ac) 88%, #fff), var(--ac)); color: #fff; border-color: #10131A; }
.contact-tg-ico { width: 46px; height: 46px; border-radius: var(--r-btn); flex-shrink: 0; display: grid; place-items: center;
  background: color-mix(in oklab, var(--ac) 14%, transparent); color: var(--ac); }
.contact-tg.primary .contact-tg-ico { background: rgba(255,255,255,.2); color: #fff; }
.contact-tg-ico svg { width: 24px; height: 24px; }
.contact-tg-title { display: block; font-family: var(--f-head); font-weight: 800; font-size: 17px; margin: 3px 0 4px; }
.contact-tg-sub { display: block; font-size: 13px; line-height: 1.45; color: var(--mut); }
.contact-tg.primary .contact-tg-sub { color: rgba(255,255,255,.85); }
.contact-tg-arrow { font-size: 22px; font-weight: 900; opacity: .5; flex-shrink: 0; }
.contact-tg:hover .contact-tg-arrow { opacity: 1; }
.contacts-hours { padding: 20px; }

/* наличие на карточке товара */
.stock-badge { font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .06em; border-radius: var(--r-pill);
  padding: 3px 9px; white-space: nowrap; display: inline-flex; align-items: center; gap: 5px; }
.stock-badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.stock-badge.ok { color: var(--ok); background: rgba(11,122,75,.12); }
.stock-badge.low { color: #B3541E; background: rgba(179,84,30,.14); }
.stock-badge.order { color: var(--mut2); background: rgba(127,127,127,.14); }
.hero-counters { display: grid; grid-template-columns: repeat(3, minmax(90px, 1fr)); gap: 12px; max-width: 460px; padding-bottom: 52px; }
/* на узких экранах убираем жёсткий минимум 90px, иначе 3 колонки вылезают за край */
@media (max-width: 380px) { .hero-counters { grid-template-columns: repeat(3, 1fr); gap: 8px; } .counter { padding: 10px 8px; } }
.counter { border: 2px solid #2A2E36; border-radius: 12px; background: rgba(26,30,37,.85); padding: 14px; }
.counter b { font-family: var(--f-head); font-weight: 800; font-size: clamp(17px, 2vw, 24px); color: #fff; white-space: nowrap; }
.counter span { display: block; font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .12em; color: #7C828B; margin-top: 5px; }

/* штанга */
.bar-stage-wrap { align-self: stretch; display: flex; flex-direction: column; padding-bottom: 52px; }
.bar-stage {
  position: relative; flex: 1; min-height: 400px; border: 2px solid #2A2E36; border-radius: var(--r-card);
  background: radial-gradient(ellipse at 50% 80%, #232833 0%, #171B22 70%);
  cursor: grab; user-select: none; touch-action: none; overflow: hidden;
}
.bar-stage canvas { border-radius: 12px; }
.bar-caption {
  position: absolute; left: 0; right: 0; bottom: 12px; text-align: center;
  font-family: var(--f-mono); font-size: 10px; letter-spacing: .16em; color: #7C828B; pointer-events: none;
}
.taunt-back { position: absolute; inset: 0; z-index: 3; display: grid; place-items: center; background: rgba(9,12,18,.6); backdrop-filter: blur(3px); border-radius: 12px; }
.taunt {
  position: relative; text-align: center; border: 2px solid #10131A; border-radius: 12px;
  background: var(--warn); color: #10131A; box-shadow: 5px 5px 0 rgba(0,0,0,.5);
  padding: 22px 24px 20px; max-width: 320px; margin: 0 16px; animation: fadeUp .3s ease both;
}
.taunt-close { position: absolute; top: 6px; right: 8px; border: none; background: transparent; font-weight: 900; font-size: 15px; cursor: pointer; color: #10131A; }
.taunt h3 { font-family: var(--f-head); font-weight: 900; font-size: 16px; line-height: 1.25; margin: 0; }
.taunt p { margin: 9px 0 15px; font-size: 13.5px; line-height: 1.5; font-weight: 500; }

/* ---------- бегущая строка ---------- */
.marquee { background: var(--ac); border-bottom: 2px solid var(--ln); overflow: hidden; padding: 10px 0; }
.marquee-inner { display: flex; width: max-content; animation: marquee 22s linear infinite; font-family: var(--f-mono); font-size: 12px; letter-spacing: .2em; color: #fff; white-space: nowrap; }
.marquee-inner span { padding-right: 40px; }

/* ---------- benefits / калькулятор ---------- */
.benefit { text-align: left; cursor: pointer; padding: 18px; font-family: var(--f-body); color: var(--tx); }
.benefit .idx { font-family: var(--f-mono); font-size: 11px; letter-spacing: .12em; color: var(--ac); font-weight: 700; }
.benefit .t { font-family: var(--f-head); font-weight: 700; font-size: 15px; display: block; margin-top: 10px; line-height: 1.3; }
.benefit .b { display: block; overflow: hidden; max-height: 0; transition: max-height .3s ease, margin .3s ease; font-size: 13px; line-height: 1.6; color: var(--mut); }
.benefit.open .b { max-height: 1000px; margin-top: 10px; }
.benefit .chev { display: block; margin-top: 8px; color: var(--mut2); transition: transform .25s ease; width: fit-content; }
.benefit.open .chev { transform: rotate(180deg); color: var(--ac); }

.calc-grid { display: grid; grid-template-columns: 1fr 1.4fr; border: 2px solid var(--ln); border-radius: var(--r-card); overflow: hidden; box-shadow: var(--sh-card); }
@media (max-width: 760px) { .calc-grid { grid-template-columns: 1fr; } }
.calc-left { padding: 26px; background: #14171D; color: #F2F3F0; display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.calc-cells { display: grid; grid-template-columns: repeat(3, 1fr); }
.calc-cell { padding: 22px 16px; background: var(--cd); }
.calc-cell + .calc-cell { border-left: 2px solid var(--ln); }
.calc-cell b { font-family: var(--f-head); font-weight: 900; font-size: clamp(18px, 2.4vw, 26px); color: var(--ac); white-space: nowrap; }
.calc-cell span { display: block; font-family: var(--f-mono); font-size: 10px; letter-spacing: .1em; color: var(--mut2); margin-top: 6px; }
input[type="range"] { -webkit-appearance: none; appearance: none; height: 12px; border-radius: 8px; background: #2A2E36; border: 2px solid #10131A; outline: none; padding: 0; width: 100%; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; border-radius: 50%; background: var(--ac); border: 2px solid #10131A; box-shadow: 2px 2px 0 rgba(0,0,0,.4); cursor: pointer; }
input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: var(--ac); border: 2px solid #10131A; box-shadow: 2px 2px 0 rgba(0,0,0,.4); cursor: pointer; }

/* ---------- ИИ-подбор питания: пошаговый визард с маскотом ---------- */
.consult { padding: 26px; overflow: hidden; position: relative;
  background: linear-gradient(180deg, color-mix(in oklab, var(--ac) 5%, var(--cd)), var(--cd)); }
.consult-top { display: flex; flex-direction: column; gap: 16px; margin-bottom: 22px; }
.consult-mascot-wrap { display: flex; align-items: center; gap: 16px; }
.mascot { width: 78px; height: 78px; flex-shrink: 0; animation: mascotBob 3s ease-in-out infinite; }
.mascot-svg { width: 100%; height: 100%; overflow: visible; }
@keyframes mascotBob { 0%, 100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-6px) rotate(2deg); } }
.mascot-speech {
  position: relative; background: var(--cd2); border: 2px solid var(--ln); border-radius: var(--r-card);
  padding: 12px 16px; font-size: 14.5px; font-weight: 600; line-height: 1.4; box-shadow: var(--sh-card); flex: 1;
}
.mascot-speech::before { content: ''; position: absolute; left: -9px; top: 50%; transform: translateY(-50%) rotate(45deg);
  width: 14px; height: 14px; background: var(--cd2); border-left: 2px solid var(--ln); border-bottom: 2px solid var(--ln); }
.consult-progress { height: 8px; border-radius: var(--r-pill); background: var(--st2); overflow: hidden; }
.consult-progress-fill { height: 100%; width: 0; border-radius: var(--r-pill);
  background: linear-gradient(90deg, var(--ac), color-mix(in oklab, var(--ac) 55%, #FF3EA5)); transition: width .4s cubic-bezier(.4,0,.2,1); }

.consult-step { animation: fadeUp .35s ease both; }
.consult-qhead { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; }
.consult-emoji { font-size: 30px; line-height: 1; flex-shrink: 0; }
.consult-qtitle { font-family: var(--f-head); font-weight: 800; font-size: 18px; line-height: 1.25; }
.consult-qhint { font-size: 12.5px; color: var(--mut2); margin-top: 4px; }
.opt-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 12px; }
.opt-chip {
  border: 2px solid var(--ln); border-radius: var(--r-btn); background: var(--cd); color: var(--tx);
  padding: 13px 16px; font-family: var(--f-body); font-weight: 600; font-size: 14px; cursor: pointer;
  text-align: left; transition: transform .12s ease, box-shadow .12s ease, background .15s ease, border-color .15s ease;
}
.opt-chip:hover { border-color: var(--ac); transform: translateY(-2px); box-shadow: var(--sh-btn); }
.opt-chip.on { background: var(--ac); border-color: var(--ac); color: #fff; box-shadow: var(--sh-btn); }
.opt-custom { margin-bottom: 12px; }
.consult-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 6px; }
.consult-result { margin-top: 22px; border-top: 2px dashed var(--ink-14); padding-top: 20px; }
.consult-loading { display: flex; align-items: center; gap: 10px; color: var(--mut); font-family: var(--f-mono); font-size: 13px; }
.consult-badge { display: inline-flex; align-items: center; gap: 7px; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .12em;
  color: var(--ac); border: 1.5px solid var(--ac-line); border-radius: var(--r-pill); padding: 5px 12px; margin-bottom: 14px; }
.consult-badge svg { width: 13px; height: 13px; }
.consult-err { color: var(--err); font-family: var(--f-mono); font-size: 12.5px; }
.consult .spin { border-color: color-mix(in oklab, var(--ac) 30%, transparent); border-top-color: var(--ac); }

/* ---------- каталог: тулбар ---------- */
.cat-toolbar {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  border: 2px solid var(--ln); border-radius: var(--r-card); background: var(--cd);
  box-shadow: var(--sh-card); padding: 10px 14px; margin-bottom: 22px;
}
.view-switch { display: flex; border: 2px solid var(--ln); border-radius: var(--r-btn); overflow: hidden; }
.view-switch button {
  border: none; background: transparent; color: var(--mut2); cursor: pointer;
  width: 38px; height: 32px; display: grid; place-items: center; transition: background .15s ease, color .15s ease;
}
.view-switch button + button { border-left: 2px solid var(--ln); }
.view-switch button.active { background: var(--ac); color: #fff; }
.sort-box { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.sort-box .sel { width: auto; min-width: 170px; padding-top: 8px; padding-bottom: 8px; font-size: 12px; }
.sort-ico { color: var(--ac); display: grid; place-items: center; }

.catalog-grid { display: grid; grid-template-columns: 280px 1fr; gap: 22px; align-items: start; }
@media (max-width: 900px) { .catalog-grid { grid-template-columns: 1fr; } }
.filters { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 96px; }
@media (max-width: 900px) { .filters { position: static; } }
.filter-check { display: flex; align-items: center; gap: 9px; border: none; background: transparent; cursor: pointer; padding: 5px 0; color: var(--tx); font-family: var(--f-body); font-size: 13.5px; text-align: left; }
.filter-check .box { width: 15px; height: 15px; border: 2px solid var(--ln); border-radius: 4px; flex-shrink: 0; background: transparent; transition: background .12s ease; }
.filter-check.on .box { background: var(--ac); border-color: var(--ac); box-shadow: inset 0 0 0 2.5px var(--cd); }
.filter-check.sub { padding-left: 22px; font-size: 12.5px; color: var(--mut); }

/* ---------- карточки товара ---------- */
.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 20px; }
.p-card { overflow: hidden; display: flex; flex-direction: column; border-radius: var(--r-card); }
.p-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 8px 12px; border-bottom: 2px solid var(--ln); color: #fff; }
.p-head .mono { font-size: 10px; letter-spacing: .12em; text-shadow: 0 1px 0 rgba(0,0,0,.4); }
.p-pill { width: 22px; height: 11px; border-radius: var(--r-pill); border: 2px solid #10131A; flex-shrink: 0;
  background: linear-gradient(90deg, #FF3EA5, #FFD400, #3EE06B, #00C2FF, #FF3EA5); background-size: 300% 100%; animation: hueSlide 2.6s linear infinite; }
.p-img { aspect-ratio: 4 / 3; background: repeating-linear-gradient(-45deg, var(--st1) 0 12px, var(--st2) 12px 24px); display: grid; place-items: center; border-bottom: 2px solid var(--ln); position: relative; overflow: hidden; }
.p-img img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.p-img .shine { position: absolute; inset: 0; background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.35) 45%, transparent 60%); pointer-events: none; }
.p-img .lbl { font-family: var(--f-mono); font-size: 10.5px; color: var(--mut2); position: relative; padding: 0 10px; text-align: center; }
/* заглушка «таблетка/виала» для товаров без фото */
.p-ph { position: relative; display: flex; flex-direction: column; align-items: center; gap: 8px; color: var(--phc, var(--ac)); }
.p-ph svg { width: 46px; height: 46px; opacity: .85; }
.p-ph-lbl { font-family: var(--f-mono); font-size: 9px; letter-spacing: .16em; color: var(--mut2); }
.cart-thumb.ph { display: grid; place-items: center; color: var(--phc, var(--ac)); background: var(--cd2); }
.cart-thumb.ph svg { width: 26px; height: 26px; opacity: .8; }
.p-body { padding: 16px; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.p-name { margin: 0; font-family: var(--f-head); font-weight: 600; font-size: 14.5px; line-height: 1.3; }
.p-meta { font-family: var(--f-mono); font-size: 10px; letter-spacing: .1em; color: var(--mut2); }
.p-desc { margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--mut); flex: 1; text-wrap: pretty; }
.p-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 4px; flex-wrap: wrap; }
.p-price { font-weight: 700; font-size: 18px; white-space: nowrap; }
/* круглая иконка «оформить» — заменяет широкую кнопку, когда товар уже в корзине */
.p-buy-ico {
  width: 36px; height: 36px; padding: 0; flex-shrink: 0; cursor: pointer;
  display: inline-grid; place-items: center; border: 2px solid var(--ln); border-radius: 50%;
  background: var(--ac); color: #fff; box-shadow: 2px 2px 0 var(--ln);
  transition: transform .13s ease, box-shadow .13s ease, filter .15s ease;
}
.p-buy-ico:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--ln); filter: brightness(1.08); }
.p-buy-ico:active { transform: none; box-shadow: 1px 1px 0 var(--ln); }
.p-price .old { font-size: 12px; color: var(--mut2); text-decoration: line-through; font-weight: 500; margin-right: 7px; }

/* list view */
.products.list { grid-template-columns: 1fr; }
.products.list .p-card { flex-direction: row; align-items: stretch; }
.products.list .p-head { display: none; }
.products.list .p-img { width: 190px; min-height: 130px; aspect-ratio: auto; border-bottom: none; border-right: 2px solid var(--ln); flex-shrink: 0; }
.products.list .p-body { padding: 16px 20px; }
@media (max-width: 620px) { .products.list .p-img { width: 110px; } }

.no-results { grid-column: 1 / -1; border: 2px dashed var(--mut2); border-radius: var(--r-card); padding: 50px 24px; text-align: center; font-family: var(--f-mono); font-size: 13px; color: var(--mut2); }

/* ---------- корзина / checkout ---------- */
.cart-grid { display: grid; grid-template-columns: 1fr 340px; gap: 22px; align-items: start; }
@media (max-width: 860px) { .cart-grid { grid-template-columns: 1fr; } }
.cart-item { display: flex; align-items: center; gap: 16px; padding: 16px 18px; flex-wrap: wrap; }
.cart-item + .cart-item { border-top: 2px solid var(--st2); }
.cart-thumb { width: 54px; height: 54px; border: 2px solid var(--ln); border-radius: var(--r-btn); background: repeating-linear-gradient(-45deg, var(--st1) 0 8px, var(--st2) 8px 16px); flex-shrink: 0; overflow: hidden; }
.cart-thumb img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.qty-box { display: flex; align-items: center; border: 2px solid var(--ln); border-radius: var(--r-btn); overflow: hidden; }
.qty-box button { width: 32px; height: 32px; border: none; background: var(--st2); color: var(--tx); font-weight: 900; font-size: 15px; cursor: pointer; }
.qty-box button:hover { filter: brightness(.93); }
.qty-box span { min-width: 36px; text-align: center; font-weight: 700; font-size: 14px; }
.cart-aside { border: 2px solid var(--ln); border-radius: var(--r-card); background: #14171D; color: #F2F3F0; box-shadow: var(--sh-card); padding: 22px; display: flex; flex-direction: column; gap: 15px; position: sticky; top: 96px; }
.sum-row { display: flex; justify-content: space-between; gap: 12px; color: #9AA0A6; font-size: 14px; }
.sum-row b { color: #F2F3F0; }
.sum-total { display: flex; justify-content: space-between; gap: 12px; font-weight: 900; font-size: 17px; border-top: 2px solid #2A2E36; padding-top: 12px; color: #fff; }
.sum-total b { color: #6FB6F0; }
.ship-note { display: flex; align-items: center; gap: 14px; border: 2px solid var(--ln); border-radius: 12px;
  background: repeating-linear-gradient(-45deg, #FFE9B8 0 14px, #FFF6E0 14px 28px); box-shadow: var(--sh-card);
  padding: 13px 18px; margin-bottom: 20px; color: #10131A; font-family: var(--f-mono); font-size: 12px; letter-spacing: .04em; }

.steps { display: flex; gap: 8px; margin-bottom: 26px; flex-wrap: wrap; }
.step { display: flex; align-items: center; gap: 8px; font-family: var(--f-mono); font-size: 11px; letter-spacing: .1em; color: var(--mut2); }
.step .n { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--ln); display: grid; place-items: center; font-weight: 700; }
.step.on { color: var(--ac); }
.step.on .n { background: var(--ac); border-color: var(--ac); color: #fff; }
.step .dash { width: 26px; height: 2px; background: var(--mut2); opacity: .4; }

.pay-card { border: 2px solid var(--ln); border-radius: var(--r-card); background: linear-gradient(135deg, #171B24, #10131A); color: #F2F3F0; box-shadow: var(--sh-card); padding: 22px; }
.pay-card .inp { background: rgba(255,255,255,.06); border-color: #2A2E36; color: #F2F3F0; }
.pay-card .inp:focus { border-color: var(--ac); }
.pay-note { font-family: var(--f-mono); font-size: 10.5px; color: var(--mut2); line-height: 1.6; }
.spin { display: inline-block; width: 14px; height: 14px; border: 2.5px solid rgba(255,255,255,.35); border-top-color: #fff; border-radius: 50%; animation: rot .7s linear infinite; }
@keyframes rot { to { transform: rotate(360deg); } }
.order-done { text-align: center; padding: 50px 24px; }
.order-done .big { font-size: 52px; }

/* ---------- статьи ---------- */
.article-card { text-align: left; display: block; width: 100%; cursor: pointer; padding: 22px; color: var(--tx); font-family: var(--f-body); }
.article-body p { margin: 0 0 16px; font-size: 15.5px; line-height: 1.75; text-wrap: pretty; }
.article-body a { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.article-cta { margin-top: 26px; border: 2px solid var(--ln); border-radius: 12px; background: repeating-linear-gradient(-45deg, var(--st1) 0 12px, var(--st2) 12px 24px); padding: 18px; display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }

/* ---------- faq ---------- */
.faq-item { overflow: hidden; }
.faq-q { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 17px 20px; background: transparent; border: none; color: var(--tx); font-family: var(--f-body); font-size: 15.5px; font-weight: 700; text-align: left; cursor: pointer; }
.faq-q .chev { color: var(--mut2); transition: transform .25s ease; flex-shrink: 0; }
.faq-item.open .faq-q .chev { transform: rotate(180deg); color: var(--ac); }
/* grid-трюк 0fr→1fr: раскрывается плавно и не обрезает длинные ответы (в отличие от max-height) */
.faq-a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .35s ease; }
.faq-a > div { overflow: hidden; min-height: 0; }
.faq-item.open .faq-a { grid-template-rows: 1fr; }
.faq-a p { margin: 0; padding: 0 20px 18px; font-size: 14px; line-height: 1.65; color: var(--mut); }

/* ---------- аккаунт ---------- */
.auth-grid { display: grid; grid-template-columns: 1fr 1.2fr; border: 2px solid var(--ln); border-radius: var(--r-card); overflow: hidden; box-shadow: var(--sh-card); }
@media (max-width: 720px) { .auth-grid { grid-template-columns: 1fr; } }
.auth-left { padding: 36px 34px; background: linear-gradient(160deg, #171B24, #10131A); color: #F2F3F0; display: flex; flex-direction: column; justify-content: space-between; gap: 30px; }
.auth-right { padding: 36px 34px; background: var(--cd); }
.tabs { display: flex; border: 2px solid var(--ln); border-radius: var(--r-btn); overflow: hidden; margin-bottom: 24px; }
.tabs button { flex: 1; padding: 12px; border: none; cursor: pointer; background: transparent; color: var(--mut2); font-family: var(--f-head); font-weight: 700; font-size: 12px; letter-spacing: .05em; }
.tabs button + button { border-left: 2px solid var(--ln); }
.tabs button.active { background: var(--ac); color: #fff; }
.form-err { font-family: var(--f-mono); font-size: 11.5px; color: var(--err); min-height: 16px; }

.table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.table th { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .12em; text-align: left; color: #F2F3F0; background: #171A20; padding: 12px 14px; }
.table td { padding: 12px 14px; border-top: 2px solid var(--st2); vertical-align: middle; }
.table-wrap { overflow-x: auto; border-radius: var(--r-card); }

.status-chip { font-family: var(--f-mono); font-size: 10px; letter-spacing: .1em; border-radius: var(--r-chip); padding: 3px 9px; display: inline-block; }
.st-paid { background: rgba(11,122,75,.15); color: var(--ok); }
.st-pending_payment { background: rgba(255,212,0,.2); color: #8a6d00; }
/* в тёмной теме тёмно-жёлтый #8a6d00 нечитаем на тёмном чипе — берём яркий warn */
[data-theme="dark"] .st-pending_payment { color: var(--warn); }
.st-shipped { background: var(--ac-soft); color: var(--ac); }
.st-done { background: rgba(127,127,127,.15); color: var(--mut); }
.st-cancelled { background: rgba(192,57,43,.14); color: var(--err); }

/* ---------- контакты ---------- */
.contact-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; margin-bottom: 24px; }

/* ---------- чат-виджет ---------- */
.chat-wrap { position: fixed; bottom: 20px; right: 20px; z-index: 60; display: flex; flex-direction: column; align-items: flex-end; gap: 14px; }
.chat-btn {
  display: flex; align-items: center; gap: 10px; padding: 14px 22px; cursor: pointer; white-space: nowrap;
  border: 2px solid var(--ln); border-radius: var(--r-pill); background: var(--ac); color: #fff;
  font-family: var(--f-head); font-weight: 800; font-size: 12px; letter-spacing: .04em;
  box-shadow: 3px 3px 0 var(--ink-22), 0 12px 30px var(--ink-14);
  animation: pulseRing 2.6s ease-out infinite; transition: transform .12s ease;
}
.chat-btn:hover { transform: translate(-1px, -1px); }
/* крупная панель, которую можно растянуть за угол */
.chat-panel {
  position: relative;
  display: flex; flex-direction: column;
  width: 400px; height: 540px;
  min-width: 320px; min-height: 360px;
  max-width: calc(100vw - 24px); max-height: calc(100vh - 120px);
  overflow: hidden;
  border: 2px solid var(--ln); border-radius: var(--r-card);
  background: var(--cd); box-shadow: var(--sh-pop); animation: fadeUp .3s ease both;
}
/* угол ресайза сверху-слева: панель растёт вверх-влево, от кнопки */
.chat-resize {
  position: absolute; top: 0; left: 0; width: 30px; height: 30px; z-index: 5;
  cursor: nwse-resize; display: grid; align-content: end; justify-content: start;
  gap: 2px; padding: 6px; touch-action: none;
}
.chat-resize span { display: block; height: 2px; border-radius: 2px; background: rgba(255,255,255,.85); }
.chat-resize span:nth-child(1) { width: 6px; } .chat-resize span:nth-child(2) { width: 10px; } .chat-resize span:nth-child(3) { width: 14px; }
.chat-resize:hover span { background: #fff; }
@media (max-width: 480px) { .chat-panel { width: calc(100vw - 24px); height: 72vh; } .chat-resize { display: none; } }
.chat-head {
  display: flex; align-items: center; gap: 11px; padding: 14px 18px; flex-shrink: 0; color: #fff;
  background: linear-gradient(135deg, color-mix(in oklab, var(--ac) 88%, #fff), var(--ac));
  border-bottom: 2px solid var(--ln);
}
.chat-head .chat-avatar {
  width: 34px; height: 34px; border-radius: var(--r-btn); flex-shrink: 0; display: grid; place-items: center;
  background: rgba(255,255,255,.18); color: #fff;
}
.chat-head .chat-avatar svg { width: 18px; height: 18px; }
.chat-grip { margin-left: auto; opacity: .55; font-size: 15px; cursor: default; user-select: none; letter-spacing: -2px; }
.chat-msgs { flex: 1; padding: 16px; display: flex; flex-direction: column; gap: 11px; overflow-y: auto; background: var(--cd2); }
.chat-msg { max-width: 86%; padding: 11px 15px; font-size: 14px; line-height: 1.55; border-radius: var(--r-card); overflow-wrap: anywhere; word-break: break-word; }
.chat-msg.user { align-self: flex-end; background: var(--ac); color: #fff; border-bottom-right-radius: 5px; font-weight: 500; }
.chat-msg.agent { align-self: flex-start; background: var(--cd); border: 1.5px solid var(--st2); color: var(--tx); border-bottom-left-radius: 5px; box-shadow: 0 2px 8px var(--ink-08); }
.chat-input { display: flex; gap: 8px; padding: 12px; flex-shrink: 0; border-top: 2px solid var(--ln); background: var(--cd); }
/* ИИ-ответчик */
.chat-ai-dot { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; background: #fff;
  box-shadow: 0 0 0 0 rgba(255,255,255,.7); animation: pulseRing 2s ease-out infinite; }
.chat-msg.agent a { color: var(--ac); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.chat-msg.agent p { margin: 0 0 7px; } .chat-msg.agent p:last-child { margin-bottom: 0; }
.chat-msg.agent ul { margin: 4px 0; padding-left: 18px; }
.chat-typing { display: inline-flex; gap: 4px; align-items: center; }
.chat-typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--mut2); animation: tdots 1.2s ease-in-out infinite; }
.chat-typing i:nth-child(2) { animation-delay: .18s; } .chat-typing i:nth-child(3) { animation-delay: .36s; }
@keyframes tdots { 0%, 60%, 100% { transform: translateY(0); opacity: .5; } 30% { transform: translateY(-4px); opacity: 1; } }

/* ---------- футер ---------- */
footer.site { background: #14171D; color: #F2F3F0; border-top: 2px solid var(--ln); padding: 54px 24px 30px; margin-top: 60px; }
.footer-grid { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: 1.3fr 1fr 1.3fr; gap: 40px; }
.footer-grid.two { grid-template-columns: 1.6fr 1fr; }
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-bottom { max-width: 1200px; margin: 40px auto 0; padding-top: 18px; border-top: 1px solid #2A2E36; display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .08em; color: #565B61; }
.footer-link { border: none; background: transparent; color: #C9CDD1; font-family: var(--f-body); font-size: 14px; cursor: pointer; padding: 0; text-align: left; transition: color .15s ease; }
.footer-link:hover { color: #4D9FDC; }

/* ---------- Пиллсик — маскот личного кабинета ---------- */
.pillsik-card { display: flex; align-items: center; gap: 20px; flex-wrap: wrap;
  background: linear-gradient(120deg, var(--cd) 60%, color-mix(in srgb, var(--ac) 14%, var(--cd))); }
.pillsik-body { border: none; background: transparent; padding: 0; cursor: pointer; width: 96px; flex-shrink: 0;
  animation: pillsikBob 2.6s ease-in-out infinite; transition: transform .15s ease; }
.pillsik-body:hover { transform: scale(1.07) rotate(-3deg); }
.pillsik-body:active { transform: scale(.94); }
.pillsik-body svg { width: 100%; height: auto; display: block; }
@keyframes pillsikBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.pillsik-bubble { position: relative; background: var(--cd2); border: 2px solid var(--ln); border-radius: 14px;
  padding: 12px 16px; font-size: 14px; line-height: 1.55; font-weight: 600; max-width: 440px; }
.pillsik-bubble::before { content: ''; position: absolute; left: -9px; top: 18px; width: 14px; height: 14px;
  background: var(--cd2); border-left: 2px solid var(--ln); border-bottom: 2px solid var(--ln); transform: rotate(45deg); }
.pillsik-balance { margin-left: auto; text-align: right; }
.pillsik-balance b { display: block; font-family: var(--f-head); font-size: clamp(20px, 3vw, 30px); color: var(--ac); white-space: nowrap; }
.pillsik-auth { width: 84px; }
.pillsik-auth svg { width: 100%; height: auto; }
@media (max-width: 640px) { .pillsik-balance { margin-left: 0; text-align: left; } }

/* ---------- вход через Telegram ---------- */
.tg-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  background: #229ED9; border-color: #229ED9; color: #fff; text-decoration: none; }
.tg-btn:hover { background: #1e8dc2; border-color: #1e8dc2; color: #fff; }
.auth-or { display: flex; align-items: center; gap: 12px; color: var(--mut2);
  font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; }
.auth-or::before, .auth-or::after { content: ''; flex: 1; height: 1.5px; background: var(--ln); }
