/* MashKhv — Midnight / Electric Violet */
:root {
  --bg: #0a0b10;
  --bg-2: #12131b;
  --glass: rgba(255, 255, 255, 0.04);
  --glass-strong: rgba(255, 255, 255, 0.075);
  --border: rgba(255, 255, 255, 0.08);
  --border-hi: rgba(255, 255, 255, 0.16);
  --text: #edeef4;
  --muted: #8b8fa3;
  --accent: #7c6cf6;          /* электрик-индиго */
  --accent-ink: #06040f;      /* текст на акценте */
  --accent-2: #29e0b4;        /* мятный — подсветки/успех */
  --sale: #ff4d6d;
  --gold: #f5a623;
  --ok: #29e0b4;
  --grad: linear-gradient(120deg, #7c6cf6, #a78bfa 60%, #29e0b4);
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 12px 44px -14px rgba(0, 0, 0, 0.6);
  --glow: 0 8px 28px -8px rgba(124, 108, 246, 0.55);
  --header-h: 60px;
  --maxw: 1180px;
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 15px; line-height: 1.6; font-weight: 500;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  min-height: 100vh;
}
h1, h2, h3, .logo, .foot-brand { font-family: "Unbounded", "Manrope", sans-serif; letter-spacing: -0.02em; }

/* inline SVG icons */
.ic { width: 1.25em; height: 1.25em; display: inline-block; vertical-align: -0.22em; }
[data-ic] { display: inline-flex; }
.desktop-only { display: flex; }
.mobile-only { display: none; }
body::before {
  content: "";
  position: fixed; inset: -20%; z-index: -1; pointer-events: none;
  background:
    radial-gradient(720px 520px at 8% -6%, rgba(124, 108, 246, 0.16), transparent 62%),
    radial-gradient(680px 520px at 96% 2%, rgba(41, 224, 180, 0.12), transparent 58%),
    radial-gradient(520px 420px at 60% 100%, rgba(167, 139, 250, 0.10), transparent 60%);
  filter: blur(10px);
  animation: drift 26s ease-in-out infinite alternate;
}
@keyframes drift {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  50%  { transform: translate3d(2%, -1.5%, 0) scale(1.06); }
  100% { transform: translate3d(-1.5%, 2%, 0) scale(1.03); }
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; border: none; background: none; }
img { max-width: 100%; display: block; }
input, select, textarea { font: inherit; }
::selection { background: var(--accent); color: #fff; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 18px; }
.muted { color: var(--muted); }
.accent { color: var(--accent); }
[hidden] { display: none !important; }

/* ---------- glass primitives ---------- */
.glass {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 13px; border-radius: 999px;
  background: var(--glass); border: 1px solid var(--border);
  font-size: 13px; white-space: nowrap; transition: 0.18s;
}
.chip:hover { border-color: var(--border-hi); }
.chip.active {
  background: rgba(124, 108, 246, 0.14);
  border-color: rgba(124, 108, 246, 0.5);
  color: var(--accent);
  box-shadow: 0 0 16px -4px rgba(124, 108, 246, 0.4);
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 20px; border-radius: var(--radius-sm); position: relative; overflow: hidden;
  background: var(--accent); color: #fff; font-weight: 650;
  transition: transform 0.16s cubic-bezier(0.3, 1.4, 0.5, 1), box-shadow 0.18s, opacity 0.15s, filter 0.18s;
}
.btn:hover { box-shadow: var(--glow); transform: translateY(-2px); filter: brightness(1.06); }
.btn:active { transform: translateY(0) scale(0.97); }
.btn.ghost { background: var(--glass); color: var(--text); border: 1px solid var(--border-hi); }
.btn.ghost:hover { box-shadow: none; background: var(--glass-strong); filter: none; border-color: var(--accent); }
.btn.full { width: 100%; }
.btn.sm { padding: 9px 14px; font-size: 13px; border-radius: 10px; }
.btn:disabled { opacity: 0.5; pointer-events: none; }
.btn.added { background: var(--ok); color: #fff; }
/* блик по кнопке */
.btn:not(.ghost)::after {
  content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-18deg); transition: left 0.5s;
}
.btn:not(.ghost):hover::after { left: 130%; }

.badge {
  position: absolute; top: 9px; left: 9px; z-index: 3;
  display: flex; flex-direction: column; align-items: flex-start; gap: 5px;
  max-width: calc(100% - 54px); pointer-events: none;
}
.tag {
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.02em; line-height: 1.35;
  padding: 3px 7px; border-radius: 6px; max-width: 100%;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  background: rgba(0, 0, 0, 0.62); backdrop-filter: blur(4px); color: #fff;
}
.tag.sale { background: var(--sale); color: #fff; }
.tag.hit { background: var(--gold); color: #241300; }
.tag.new { background: var(--accent); color: #fff; }

.stars { display: inline-flex; gap: 1px; color: var(--gold); font-size: 13px; letter-spacing: 1px; }
.stars .off { color: rgba(255, 255, 255, 0.18); }

/* ---------- header ---------- */
.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 11, 16, 0.82);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(18px);
}
.header .wrap { display: flex; align-items: center; gap: 16px; height: var(--header-h); }
.logo { font-weight: 700; font-size: 17px; flex: none; }
.logo .dot { color: var(--accent); }
.search-box { flex: 1; position: relative; max-width: 480px; }
.search-box input {
  width: 100%; padding: 10px 14px 10px 40px; border-radius: 12px;
  background: var(--glass); border: 1px solid var(--border); color: var(--text);
  outline: none; transition: 0.18s; font-size: 14px;
}
.search-box input:focus { border-color: rgba(124, 108, 246, 0.55); background: var(--glass-strong); }
.search-box .ico { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); opacity: 0.5; }
.search-row { padding: 0 0 10px; }
.search-row .search-box { max-width: none; }
.search-row .wrap, .header .wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 18px; }
.search-drop {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 60;
  max-height: 62vh; overflow-y: auto; padding: 6px;
}
.search-drop a { display: flex; gap: 11px; align-items: center; padding: 9px; border-radius: 10px; }
.search-drop a:hover { background: var(--glass-strong); }
.search-drop img { width: 42px; height: 42px; border-radius: 9px; object-fit: cover; flex: none; background: var(--bg-2); }
.search-drop .sd-t { font-size: 13.5px; }
.search-drop .sd-p { font-size: 12px; }
.header-actions { display: flex; align-items: center; gap: 4px; flex: none; }
.icon-btn {
  position: relative; width: 40px; height: 40px; border-radius: 11px;
  display: grid; place-items: center; transition: 0.18s; color: var(--text);
}
.icon-btn:hover { background: var(--glass); }
.icon-btn .count {
  position: absolute; top: 2px; right: 2px; min-width: 17px; height: 17px; padding: 0 4px;
  background: var(--accent); color: #fff; font-size: 11px; font-weight: 800;
  border-radius: 999px; display: grid; place-items: center;
  transform: scale(0); transition: transform 0.25s cubic-bezier(0.5, 1.6, 0.5, 1);
}
.icon-btn .count.show { transform: scale(1); }

/* ---------- layout ---------- */
main { padding: 26px 0 90px; min-height: 60vh; }
.screen { animation: fade 0.3s ease both; }
/* только opacity — transform на .screen ломает position:fixed у вложенных панелей */
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.tab-body { animation: fade 0.25s both; }
.section { margin-bottom: 40px; }

/* появление секций/карточек (transform только на листовых элементах — не ломает fixed) */
@media (prefers-reduced-motion: no-preference) {
  .screen > .section { animation: fadein 0.5s ease both; }
  .screen > .section:nth-child(2) { animation-delay: 0.07s; }
  .screen > .section:nth-child(3) { animation-delay: 0.14s; }
  .screen > .section:nth-child(4) { animation-delay: 0.21s; }
  .screen > .section:nth-child(5) { animation-delay: 0.28s; }
  .screen > .section:nth-child(6) { animation-delay: 0.35s; }
  .cat-grid .cat-tile { animation: rise 0.5s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
  .cat-grid .cat-tile:nth-child(2) { animation-delay: 0.05s; }
  .cat-grid .cat-tile:nth-child(3) { animation-delay: 0.1s; }
  .cat-grid .cat-tile:nth-child(4) { animation-delay: 0.15s; }
  .cat-grid .cat-tile:nth-child(5) { animation-delay: 0.2s; }
  .carousel .pcard, .grid .pcard { animation: rise 0.45s ease both; }
  .grid .pcard:nth-child(3n+2) { animation-delay: 0.05s; }
  .grid .pcard:nth-child(3n) { animation-delay: 0.1s; }
}
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.section-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 16px; }
.section-head h2 { font-size: 20px; letter-spacing: -0.01em; }
.section-head > a { margin-left: auto; font-size: 13px; color: var(--muted); white-space: nowrap; }
.section-head > a:hover { color: var(--accent); }

/* ---------- hero slider ---------- */
.hero { position: relative; border-radius: 22px; overflow: hidden; height: 340px; border: 1px solid var(--border); }
.hero-track { display: flex; height: 100%; transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1); }
.hero-slide {
  min-width: 100%; position: relative; display: flex; flex-direction: column;
  justify-content: center; padding: 44px; color: #fff; gap: 14px;
}
.hero-slide .h-btn {
  position: relative; z-index: 2; align-self: flex-start; margin-top: 6px;
  padding: 12px 24px; border-radius: 12px; background: #fff; color: #0a0b10; font-weight: 700;
  transition: transform 0.16s, box-shadow 0.18s;
}
.hero-slide:hover .h-btn { transform: translateY(-2px); box-shadow: 0 12px 30px -10px rgba(255, 255, 255, 0.4); }
.hero-slide::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(90deg, rgba(7, 8, 12, 0.86) 0%, rgba(7, 8, 12, 0.42) 46%, rgba(7, 8, 12, 0.08) 78%),
    linear-gradient(0deg, rgba(7, 8, 12, 0.4), transparent 42%);
}
/* аврора-подсветка поверх фото */
.hero::before {
  content: ""; position: absolute; inset: -30%; z-index: 1; pointer-events: none;
  background:
    radial-gradient(340px 260px at 20% 30%, rgba(124, 108, 246, 0.35), transparent 60%),
    radial-gradient(300px 240px at 78% 70%, rgba(41, 224, 180, 0.28), transparent 60%);
  filter: blur(30px); mix-blend-mode: screen;
  animation: heroAurora 18s ease-in-out infinite alternate;
}
@keyframes heroAurora {
  0%   { transform: translate3d(0, 0, 0) rotate(0deg); }
  100% { transform: translate3d(6%, -4%, 0) rotate(8deg); }
}
.hero-slide img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  animation: kenburns 20s ease-in-out infinite alternate;
}
@keyframes kenburns {
  0%   { transform: scale(1) translate(0, 0); }
  100% { transform: scale(1.12) translate(-2%, 1%); }
}
.hero-slide h3 { animation: rise 0.6s 0.1s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.hero-slide p { animation: rise 0.6s 0.2s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.hero-slide .h-btn { animation: rise 0.6s 0.3s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
@media (prefers-reduced-motion: reduce) {
  .hero::before, .hero-slide img, body::before { animation: none; }
}
.hero-slide h3, .hero-slide p { position: relative; z-index: 2; }
.hero-slide h3 { font-size: 34px; line-height: 1.1; letter-spacing: -0.03em; text-wrap: balance; max-width: 60%; }
.hero-slide p { color: rgba(255, 255, 255, 0.85); max-width: 52%; font-size: 15px; }
.hero-dots { position: absolute; bottom: 16px; right: 24px; z-index: 3; display: flex; gap: 7px; }
.hero-dots i {
  width: 7px; height: 7px; border-radius: 999px; background: rgba(255, 255, 255, 0.35); cursor: pointer;
}
.hero-dots i.on { background: #fff; width: 20px; }

/* ---------- trust bar ---------- */
.trust { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 18px 0 6px; }
.trust .t { display: flex; gap: 10px; align-items: center; padding: 12px 14px; }
.trust .t .ic { width: 20px; height: 20px; color: var(--accent); flex: none; }
.trust .t b { font-size: 13px; display: block; }
.trust .t span { font-size: 11.5px; color: var(--muted); }

/* ---------- category tiles ---------- */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; }
.cat-tile {
  display: block; padding: 20px 16px; text-align: center;
  transition: transform 0.22s, box-shadow 0.22s, border-color 0.22s;
}
.cat-tile:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--border-hi); }
.cat-tile .emo { display: inline-flex; }
.cat-tile .emo .ic { width: 30px; height: 30px; color: var(--accent); }
.cat-tile span { display: block; margin-top: 10px; font-weight: 600; font-size: 14px; }

/* ---------- product grid & card ---------- */
.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.pcard { position: relative; overflow: hidden; transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s; display: flex; flex-direction: column; }
.pcard:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--border-hi); }
.pcard .thumb { display: block; position: relative; aspect-ratio: 1; width: 100%; overflow: hidden; background: var(--bg-2); }
.pcard .thumb img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity 0.4s, transform 0.4s;
}
.pcard .thumb img.hover { opacity: 0; }
.pcard:hover .thumb img.base { opacity: 0; }
.pcard:hover .thumb img.hover { opacity: 1; transform: scale(1.04); }
.pcard .quick {
  position: absolute; right: 10px; bottom: 10px; z-index: 3;
  width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center;
  background: rgba(0, 0, 0, 0.55); backdrop-filter: blur(6px); opacity: 0; transform: translateY(6px);
  transition: 0.2s;
}
.pcard:hover .quick { opacity: 1; transform: none; }
.pcard .fav {
  position: absolute; top: 9px; right: 9px; z-index: 4; font-size: 16px;
  width: 32px; height: 32px; border-radius: 999px; display: grid; place-items: center;
  background: rgba(0, 0, 0, 0.5); backdrop-filter: blur(6px); transition: 0.18s; color: #fff;
}
.pcard .fav.on { color: var(--sale); }
.pcard .fav.on .ic { fill: currentColor; }
.pcard .body { padding: 13px 14px 15px; display: flex; flex-direction: column; flex: 1; }
.pcard .name {
  font-size: 13.5px; line-height: 1.4; margin-bottom: 7px; color: var(--text);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  min-height: 2.8em;
}
.pcard .meta { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); margin-bottom: 9px; }
.price-row { display: flex; align-items: baseline; gap: 8px; margin-bottom: 11px; margin-top: auto; }
.price { font-size: 17px; font-weight: 800; letter-spacing: -0.01em; }
.price.old { font-size: 12.5px; font-weight: 500; color: var(--muted); text-decoration: line-through; }

/* ---------- carousel ---------- */
.carousel { display: flex; gap: 16px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; }
.carousel::-webkit-scrollbar { height: 6px; }
.carousel::-webkit-scrollbar-thumb { background: var(--border-hi); border-radius: 999px; }
.carousel .pcard { min-width: 230px; scroll-snap-align: start; }

/* ---------- catalog ---------- */
.catalog { display: grid; grid-template-columns: 250px 1fr; gap: 26px; align-items: start; }
.sidebar { position: sticky; top: calc(var(--header-h) + 20px); padding: 18px; }
.sb-head { display: none; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.filter-backdrop { display: none; }
.js-fopen { display: none; }
.sidebar h4 { font-size: 13px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin: 18px 0 10px; }
.sidebar h4:first-child { margin-top: 0; }
.range-row { display: flex; gap: 8px; }
.range-row input {
  width: 100%; padding: 8px 10px; border-radius: 9px; background: var(--glass);
  border: 1px solid var(--border); color: var(--text); outline: none;
}
.check { display: flex; align-items: center; gap: 9px; padding: 6px 0; font-size: 13.5px; cursor: pointer; }
.check input { accent-color: var(--accent); width: 15px; height: 15px; }
.toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; gap: 12px; flex-wrap: wrap; }
.toolbar select {
  padding: 9px 12px; border-radius: 10px; background: var(--glass); border: 1px solid var(--border); color: var(--text); outline: none;
}
.tagbar { display: flex; gap: 9px; overflow-x: auto; padding-bottom: 10px; margin-bottom: 6px; }

/* ---------- product page ---------- */
.product { display: grid; grid-template-columns: 1fr 1fr; gap: 34px; margin-bottom: 44px; }
.gallery .main {
  position: relative; aspect-ratio: 1; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--border); cursor: zoom-in;
}
.gallery .main img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.gallery .thumbs { display: flex; gap: 10px; margin-top: 12px; }
.gallery .thumbs img {
  width: 66px; height: 66px; border-radius: 10px; object-fit: cover; cursor: pointer;
  border: 1px solid var(--border); opacity: 0.6; transition: 0.18s;
}
.gallery .thumbs img.on { opacity: 1; border-color: var(--accent); }
.p-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.p-tags .tag { position: static; font-size: 11px; padding: 4px 9px; }
.pinfo h1 { font-size: 25px; letter-spacing: -0.02em; margin-bottom: 8px; text-wrap: balance; }
.pinfo .sku { font-size: 12px; color: var(--muted); margin-bottom: 14px; }
.pinfo .big-price { display: flex; align-items: baseline; gap: 12px; margin: 18px 0; }
.pinfo .big-price .now { font-size: 30px; font-weight: 800; }
.pinfo .big-price .was { font-size: 16px; color: var(--muted); text-decoration: line-through; }
.pinfo .big-price .save { font-size: 12px; color: var(--sale); background: rgba(255,92,124,0.14); padding: 3px 8px; border-radius: 7px; }
.variant-group { margin: 16px 0; }
.variant-group .lbl { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.variant-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.vopt {
  min-width: 46px; padding: 9px 13px; border-radius: 10px; text-align: center;
  background: var(--glass); border: 1px solid var(--border); font-size: 13px; transition: 0.16s;
}
.vopt.on { border-color: var(--accent); color: var(--accent); background: rgba(75,214,196,0.12); }
.vopt.dis { opacity: 0.3; text-decoration: line-through; pointer-events: none; }
.stock-bar { height: 5px; border-radius: 999px; background: var(--glass-strong); margin: 14px 0 6px; overflow: hidden; }
.stock-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--sale), var(--gold)); }
.buy-row { display: flex; gap: 12px; margin-top: 18px; }

/* tabs */
.tabs { border-top: 1px solid var(--border); }
.tab-heads { display: flex; gap: 4px; flex-wrap: wrap; margin: 4px 0 0; }
.tab-heads button {
  padding: 14px 16px; font-size: 14px; color: var(--muted); position: relative; transition: color 0.18s;
}
.tab-heads button.on { color: var(--text); }
.tab-heads button.on::after {
  content: ""; position: absolute; left: 16px; right: 16px; bottom: 0; height: 2px;
  background: var(--accent); border-radius: 2px;
}
.tab-body { padding: 20px 2px; animation: fade 0.3s both; }
.spec-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.spec-table tr:nth-child(odd) { background: var(--glass); }
.spec-table td { padding: 10px 14px; }
.spec-table td:first-child { color: var(--muted); width: 42%; }

/* reviews */
.rev-summary { display: flex; gap: 26px; align-items: center; margin-bottom: 22px; flex-wrap: wrap; }
.rev-big { font-size: 44px; font-weight: 800; line-height: 1; }
.rev-bars { flex: 1; min-width: 200px; }
.rev-bar { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.rev-bar .track { flex: 1; height: 6px; background: var(--glass-strong); border-radius: 999px; overflow: hidden; }
.rev-bar .track i { display: block; height: 100%; background: var(--gold); }
.review { padding: 16px 0; border-top: 1px solid var(--border); }
.review .top { display: flex; justify-content: space-between; margin-bottom: 6px; }
.review .who { font-weight: 600; font-size: 13.5px; }
.review .date { font-size: 12px; color: var(--muted); }

/* ---------- cart drawer ---------- */
.overlay {
  position: fixed; inset: 0; z-index: 90; background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(3px); opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.overlay.show { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 100; width: 400px; max-width: 92vw;
  background: var(--bg-2); border-left: 1px solid var(--border);
  transform: translateX(100%); transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex; flex-direction: column;
}
.drawer.show { transform: none; }
.drawer .d-head { display: flex; justify-content: space-between; align-items: center; padding: 18px; border-bottom: 1px solid var(--border); }
.drawer .d-body { flex: 1; overflow-y: auto; padding: 12px 18px; }
.drawer .d-foot { padding: 18px; border-top: 1px solid var(--border); }
.citem { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.citem img { width: 66px; height: 66px; border-radius: 10px; object-fit: cover; flex: none; }
.citem .c-mid { flex: 1; min-width: 0; }
.citem .c-name { font-size: 13px; line-height: 1.4; margin-bottom: 4px; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--border); border-radius: 9px; overflow: hidden; }
.qty button { width: 28px; height: 28px; display: grid; place-items: center; }
.qty span { width: 30px; text-align: center; font-size: 13px; }
.sum-row { display: flex; justify-content: space-between; margin-bottom: 8px; font-size: 14px; }
.sum-row.total { font-size: 18px; font-weight: 750; margin: 12px 0 16px; }

/* ---------- modal ---------- */
.modal-wrap {
  position: fixed; inset: 0; z-index: 110; display: grid; place-items: center; padding: 20px;
  background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(6px);
  opacity: 0; pointer-events: none; transition: opacity 0.22s;
}
.modal-wrap.show { opacity: 1; pointer-events: auto; }
.modal {
  width: 100%; max-width: 460px; padding: 24px; max-height: 88vh; overflow-y: auto;
  transform: scale(0.94); transition: transform 0.24s;
}
.modal-wrap.show .modal { transform: none; }
.modal h3 { margin-bottom: 14px; font-size: 19px; }
.field { margin-bottom: 13px; }
.field label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 5px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 11px 13px; border-radius: 10px;
  background: var(--glass); border: 1px solid var(--border); color: var(--text); outline: none;
}
.field input:focus, .field textarea:focus { border-color: rgba(124, 108, 246, 0.5); }
.field label input[type="checkbox"] {
  width: auto; padding: 0; margin-right: 8px; accent-color: var(--accent);
  vertical-align: -2px;
}
.field label:has(input[type="checkbox"]) {
  display: flex; align-items: center; color: var(--text); font-size: 13.5px; margin-bottom: 0;
}
.field input:disabled { opacity: 0.5; }
.pick-stars { font-size: 26px; color: rgba(255,255,255,0.2); display: flex; gap: 4px; }
.pick-stars i { cursor: pointer; transition: 0.12s; }
.pick-stars i.on, .pick-stars i:hover { color: var(--gold); }

/* ---------- офлайн-плашка ---------- */
#offline-bar {
  position: sticky; top: 0; z-index: 55;
  background: var(--gold); color: #241300; font-size: 12.5px; font-weight: 600;
  text-align: center; padding: 7px 12px; line-height: 1.4;
}

#announce-bar {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  color: var(--accent-ink); font-size: 12.5px; font-weight: 600;
  text-align: center; padding: 8px 14px; line-height: 1.45;
}

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 150; display: grid; place-items: center;
  background: rgba(6, 8, 10, 0.94); backdrop-filter: blur(4px); padding: 20px;
  animation: fade 0.2s both;
}
.lightbox .lb-img { max-width: 92vw; max-height: 86vh; border-radius: 10px; object-fit: contain; }
.lightbox .lb-x {
  position: absolute; top: 16px; right: 16px; width: 42px; height: 42px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.12); color: #fff; display: grid; place-items: center;
}
.lightbox .lb-x:hover { background: rgba(255, 255, 255, 0.25); }
.lightbox .lb-nav {
  position: absolute; top: 50%; transform: translateY(-50%); width: 46px; height: 46px;
  border-radius: 999px; background: rgba(255, 255, 255, 0.12); color: #fff; font-size: 26px;
  display: grid; place-items: center;
}
.lightbox .lb-prev { left: 12px; }
.lightbox .lb-next { right: 12px; }
.lightbox .lb-nav:hover { background: rgba(255, 255, 255, 0.25); }
.lightbox .lb-dots { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; }
.lightbox .lb-dots i { width: 7px; height: 7px; border-radius: 999px; background: rgba(255, 255, 255, 0.35); }
.lightbox .lb-dots i.on { background: #fff; width: 18px; }
.gallery .main { cursor: zoom-in; }
@media (max-width: 640px) { .lightbox .lb-nav { width: 38px; height: 38px; font-size: 22px; } }

/* ---------- countdown / акции ---------- */
.cd {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: "IBM Plex Mono", ui-monospace, monospace; font-size: 12px;
}
.cd .cd-v { font-weight: 700; color: var(--sale); letter-spacing: .02em; }
.cd-head { color: var(--muted); white-space: nowrap; }
.cd-prod {
  margin: 10px 0 4px; padding: 9px 12px; border-radius: 10px;
  background: rgba(255, 92, 124, 0.1); border: 1px solid rgba(255, 92, 124, 0.28);
  color: var(--muted); font-size: 12px;
}
.cd-prod .ic { width: 15px; height: 15px; color: var(--sale); }
.cd-lbl { color: var(--muted); }

/* ---------- sticky buy bar (mobile) ---------- */
.buy-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
  background: rgba(10, 11, 16, 0.94); border-top: 1px solid var(--border);
  backdrop-filter: blur(16px); align-items: center; gap: 12px;
}
.buy-bar .bb-price { font-size: 18px; font-weight: 800; }
.buy-bar .bb-old { font-size: 12px; color: var(--muted); margin-left: 6px; }
.buy-bar .btn { flex: 1; margin-left: auto; max-width: 220px; }

/* ---------- review filters / photos ---------- */
.rev-bar { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; background: none; padding: 3px 4px; border-radius: 6px; }
.rev-bar:hover { background: var(--glass); }
.rev-bar.on { background: rgba(124, 108, 246, 0.14); }
.rev-filters { display: flex; gap: 8px; align-items: center; margin: 4px 0 14px; flex-wrap: wrap; }
.rev-filters select { padding: 8px 10px; border-radius: 9px; background: var(--glass); border: 1px solid var(--border); color: var(--text); font-size: 13px; margin-left: auto; }
.rev-photos { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.rev-photos img { width: 64px; height: 64px; border-radius: 8px; object-fit: cover; cursor: zoom-in; }

/* ---------- документы / правила ---------- */
.doc-body { font-size: 14.5px; line-height: 1.75; color: var(--text); }
.doc-body h3 { font-size: 16px; margin: 22px 0 8px; }
.doc-body p, .doc-body ul, .doc-body ol { margin: 10px 0; }
.doc-body ul, .doc-body ol { padding-left: 1.3rem; }
.doc-body li { margin: 4px 0; }
.doc-body a { color: var(--accent); }
.terms-check {
  display: flex; gap: 9px; align-items: flex-start; font-size: 12px; color: var(--muted);
  line-height: 1.5; margin-top: 14px; cursor: pointer;
}
.terms-check input { margin-top: 2px; accent-color: var(--accent); width: 16px; height: 16px; flex: none; }
.terms-check a { color: var(--accent); }
.terms-check.shake { animation: shake 0.4s; }
@keyframes shake { 0%,100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
.foot-links { flex-wrap: wrap; }

/* ---------- auth ---------- */
.auth-tabs { display: flex; gap: 4px; background: var(--glass); border-radius: 10px; padding: 3px; }
.auth-tabs button { flex: 1; padding: 8px 4px; border-radius: 8px; font-size: 12.5px; color: var(--muted); transition: 0.15s; }
.auth-tabs button.on { background: var(--glass-strong); color: var(--text); }

/* ---------- delivery options ---------- */
.del-list { display: flex; flex-direction: column; gap: 8px; }
.del-opt {
  display: flex; align-items: center; gap: 10px; padding: 11px 13px;
  border: 1px solid var(--border); border-radius: 11px; background: var(--glass); cursor: pointer;
  transition: 0.15s;
}
.del-opt.on { border-color: var(--accent); background: rgba(124, 108, 246, 0.08); }
.del-opt input { accent-color: var(--accent); flex: none; }
.del-opt .d-mid { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.del-opt .d-mid b { font-size: 13.5px; }
.del-opt .d-mid span { font-size: 11.5px; }
.del-opt .d-price { font-weight: 650; font-size: 13.5px; white-space: nowrap; }

/* ---------- order tracking ---------- */
.track-line { display: flex; justify-content: space-between; margin: 6px 0 16px; position: relative; }
.track-line::before {
  content: ""; position: absolute; left: 8%; right: 8%; top: 6px; height: 2px; background: var(--glass-strong); z-index: 0;
}
.track-line .ts { display: flex; flex-direction: column; align-items: center; gap: 6px; z-index: 1; flex: 1; }
.track-line .ts i { width: 13px; height: 13px; border-radius: 999px; background: var(--surface-2); border: 2px solid var(--line-strong, var(--border-hi)); }
.track-line .ts.done i { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 10px -2px var(--accent); }
.track-line .ts span { font-size: 10.5px; color: var(--muted); text-align: center; }
.track-line .ts.done span { color: var(--text); }
.eta-badge {
  background: rgba(124, 108, 246, 0.1); border: 1px solid rgba(124, 108, 246, 0.3);
  border-radius: 10px; padding: 9px 12px; font-size: 13px; margin: 4px 0;
}
.delivery-hint { font-size: 12px; color: var(--muted); margin-top: 10px; display: flex; gap: 6px; align-items: center; }

/* ---------- skeleton ---------- */
.skel { background: linear-gradient(90deg, var(--glass) 25%, var(--glass-strong) 37%, var(--glass) 63%); background-size: 400% 100%; animation: shimmer 1.3s infinite; border-radius: 8px; }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
.skel-card { border-radius: var(--radius); overflow: hidden; }
.skel-card .s-img { aspect-ratio: 1; }
.skel-card .s-line { height: 12px; margin: 12px 14px; }

/* ---------- empty / toast ---------- */
.empty { text-align: center; padding: 60px 20px; color: var(--muted); }
.empty .emo { font-size: 46px; margin-bottom: 12px; }
.toast-host { position: fixed; left: 50%; bottom: 90px; z-index: 200; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  padding: 11px 18px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--border-hi);
  font-size: 13.5px; box-shadow: var(--shadow); animation: toastIn 0.3s both;
}
@keyframes toastIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ---------- footer ---------- */
footer { border-top: 1px solid var(--border); padding: 40px 0 44px; margin-top: 56px; }
.foot-brand { font-size: 20px; font-weight: 700; margin-bottom: 10px; }
.foot-brand .dot { color: var(--accent); }
.foot-about { font-size: 13px; max-width: 34rem; line-height: 1.7; }
.foot-links { display: flex; gap: 18px; margin: 16px 0 14px; font-size: 13.5px; }
.foot-links a:hover { color: var(--accent); }
.foot-copy { font-size: 12px; }

/* ---------- support fab ---------- */
.fab {
  position: fixed; right: 20px; bottom: 20px; z-index: 80;
  width: 52px; height: 52px; border-radius: 999px; display: grid; place-items: center;
  background: var(--accent); color: #fff; box-shadow: 0 10px 30px -8px rgba(124, 108, 246, 0.55);
  transition: transform 0.18s;
}
.fab .ic { width: 22px; height: 22px; }
.fab:hover { transform: scale(1.08); }

/* ---------- bottom nav (mini app) ---------- */
.bottom-nav { display: none; }
body.tg .desktop-only, body.tg .mobile-only, body.tg .search-row { display: none !important; }
body.tg .fab { bottom: 84px; }
body.tg .bottom-nav {
  display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 70;
  background: rgba(10, 11, 16, 0.92); border-top: 1px solid var(--border);
  backdrop-filter: blur(18px); padding: 7px 4px calc(7px + env(safe-area-inset-bottom));
}
.bottom-nav button {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 6px 0; font-size: 10px; color: var(--muted); position: relative;
}
.bottom-nav button .ic { width: 21px; height: 21px; }
.bottom-nav button.on { color: var(--accent); }
.bottom-nav button .count {
  position: absolute; top: 2px; right: 50%; margin-right: -22px;
  min-width: 15px; height: 15px; padding: 0 3px; background: var(--sale); color: #fff;
  font-size: 10px; font-weight: 700; border-radius: 999px; display: grid; place-items: center;
}

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .grid { grid-template-columns: repeat(3, 1fr); }
  .catalog { grid-template-columns: 1fr; display: block; }
  .js-fopen { display: inline-flex; }
  .sb-head { display: flex; }
  .sidebar {
    position: fixed; left: 0; bottom: 0; right: 0; top: auto; z-index: 105;
    max-height: 82vh; overflow-y: auto; border-radius: 20px 20px 0 0;
    transform: translateY(101%); transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 18px 18px calc(18px + env(safe-area-inset-bottom));
    background: var(--bg-2); backdrop-filter: none;
    box-shadow: 0 -20px 50px -10px rgba(0, 0, 0, 0.6);
  }
  .filters-open .sidebar { transform: none; }
  .filter-backdrop {
    position: fixed; inset: 0; z-index: 104; background: rgba(0, 0, 0, 0.72);
    opacity: 0; pointer-events: none; transition: opacity 0.25s;
  }
  .filters-open .filter-backdrop { display: block; opacity: 1; pointer-events: auto; }
  .product { grid-template-columns: 1fr; gap: 22px; }
}
@media (max-width: 860px) {
  .desktop-only { display: none !important; }
  .mobile-only { display: block !important; }
  .buy-bar.mobile-only { display: flex !important; }
  .trust { grid-template-columns: 1fr; gap: 8px; }
  .product-wrap { padding-bottom: 74px; }
}
@media (min-width: 861px) { .buy-bar { display: none !important; } }
@media (max-width: 640px) {
  .wrap { padding: 0 14px; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 11px; }
  .hero { height: 250px; border-radius: 18px; }
  .hero-slide { padding: 26px; }
  .hero-slide h3 { font-size: 24px; max-width: 100%; }
  .hero-slide p { max-width: 92%; font-size: 13px; }
  .hero-slide .h-btn { padding: 9px 18px; font-size: 14px; }
  .section-head h2 { font-size: 18px; }
  main { padding: 16px 0 100px; }
  .pcard .name { font-size: 12.5px; }
  .drawer { width: 100%; }
  footer { margin-top: 36px; padding: 30px 0 34px; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
