/* =====================================================================
   Сделано.dev — стили сайта
   Принципы: один шрифт с характером, тонкие линии вместо карточек-стекляшек,
   один акцентный цвет в малых дозах, настоящие превью вместо декора,
   движение только там, где оно что-то объясняет.
   ===================================================================== */

:root {
  /* Цвет */
  --bg: #0d0e0f;          /* фон страницы */
  --bg-2: #131416;        /* поверхности: карточки, поля */
  --bg-3: #1a1b1e;        /* наведение, выбранное */
  --line: rgba(255, 255, 255, .08);
  --line-2: rgba(255, 255, 255, .14);
  --text: #ecebe6;        /* тёплый белый, не #fff */
  --text-2: #a6a59f;
  --text-3: #75746f;
  --accent: #3ddbb3;      /* единственный акцент: бирюза */
  --accent-ink: #052019;
  --danger: #ff7a59;

  /* Типографика */
  --font: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  /* Форма */
  --r: 8px;
  --r-sm: 6px;
  --wrap: 1240px;
  --gutter: 32px;

  /* Движение */
  --ease-out: cubic-bezier(.23, 1, .32, 1);
  --ease-in-out: cubic-bezier(.77, 0, .175, 1);
  --ease-drawer: cubic-bezier(.32, .72, 0, 1);

  /* Совместимость со страницей preview.html */
  --paper: var(--bg); --paper-2: var(--bg-2); --card: var(--bg-2);
  --ink: var(--text); --ink-2: var(--text-2); --ink-3: var(--text-3);
  --font-display: var(--font); --font-body: var(--font);
  --shadow-lg: 0 30px 80px -30px rgba(0, 0, 0, .8);

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 400 16px/1.55 var(--font); letter-spacing: -.005em;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
img, svg, iframe { display: block; max-width: 100%; }
a { color: inherit; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -.03em; line-height: 1.05; text-wrap: balance; }
h2 { font-size: clamp(28px, 3.6vw, 44px); }
h3 { font-size: 18px; letter-spacing: -.015em; line-height: 1.25; }
p { margin: 0; text-wrap: pretty; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.muted { color: var(--text-2); }
.ico { width: 18px; height: 18px; flex: none; }
.num, .price, .mono { font-family: var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
@media (max-width: 700px) { :root { --gutter: 16px; } }

/* Подпись над заголовком: моно, без плашек и точек */
.label { display: inline-block; font: 500 12px/1 var(--mono); letter-spacing: .02em; color: var(--text-3); text-transform: uppercase; }

/* ---------------- Кнопки ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: var(--r-sm);
  border: 1px solid var(--line-2); background: transparent; color: var(--text);
  font-weight: 500; font-size: 15px; text-decoration: none; white-space: nowrap;
  transition: background-color .15s ease, border-color .15s ease, transform .16s var(--ease-out);
}
.btn:hover { background: var(--bg-3); border-color: rgba(255, 255, 255, .22); }
.btn:active { transform: scale(.97); }
.btn--accent, .btn--ink { background: var(--text); border-color: var(--text); color: var(--bg); }
.btn--accent:hover, .btn--ink:hover { background: #fff; border-color: #fff; }
.btn--ghost { border-color: transparent; color: var(--text-2); }
.btn--ghost:hover { background: transparent; color: var(--text); }
.btn--sm { height: 34px; padding: 0 12px; font-size: 14px; }
.btn--wide { width: 100%; }
.btn.in-cart { background: transparent; color: var(--accent); border-color: rgba(61, 219, 179, .4); }
.link-arrow { color: var(--text-2); text-decoration: none; font-size: 15px; white-space: nowrap; transition: color .15s ease; }
.link-arrow:hover { color: var(--text); }
.icon-btn {
  width: 34px; height: 34px; display: inline-grid; place-items: center; border-radius: var(--r-sm);
  color: var(--text-2); text-decoration: none; transition: background-color .15s ease, color .15s ease;
}
.icon-btn:hover { background: var(--bg-3); color: var(--text); }
.icon-btn svg { width: 16px; height: 16px; }

/* ---------------- Шапка ---------------- */
.header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(13, 14, 15, .86); -webkit-backdrop-filter: saturate(140%) blur(12px); backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header .wrap { display: flex; align-items: center; gap: 28px; height: 60px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 17px; letter-spacing: -.02em; text-decoration: none; }
.logo-mark { width: 10px; height: 10px; border-radius: 2px; background: var(--accent); font-size: 0; }
.logo small { font: 500 14px var(--mono); color: var(--text-3); margin-left: 1px; }
.nav { display: flex; gap: 2px; margin-right: auto; }
.nav a { padding: 6px 10px; border-radius: var(--r-sm); color: var(--text-2); text-decoration: none; font-size: 15px; transition: color .15s ease; }
.nav a:hover { color: var(--text); }
.nav a[aria-current="page"] { color: var(--text); }
.head-actions { display: flex; align-items: center; gap: 4px; }
.cart-btn { position: relative; height: 36px; padding: 0 10px; display: inline-flex; align-items: center; gap: 8px; border-radius: var(--r-sm); color: var(--text-2); transition: color .15s ease, background-color .15s ease; }
.cart-btn:hover { color: var(--text); background: var(--bg-3); }
.cart-btn svg { width: 18px; height: 18px; }
.cart-count { font: 500 13px var(--mono); color: var(--text-3); }
.cart-count.on { color: var(--accent); }
.cart-btn.bump svg { animation: bump .32s var(--ease-out); }
@keyframes bump { 40% { transform: scale(1.18); } }
.burger { display: none; width: 36px; height: 36px; place-items: center; border-radius: var(--r-sm); color: var(--text-2); }
@media (max-width: 860px) {
  .header .wrap { gap: 12px; }
  .logo { margin-right: auto; }
  .burger { display: inline-grid; }
  .nav {
    position: absolute; left: 0; right: 0; top: 60px; flex-direction: column; gap: 0; margin: 0;
    padding: 8px var(--gutter) 16px; background: var(--bg); border-bottom: 1px solid var(--line);
    opacity: 0; transform: translateY(-6px); pointer-events: none; visibility: hidden;
    transition: opacity .2s var(--ease-out), transform .2s var(--ease-out), visibility 0s .2s;
  }
  .nav.open { opacity: 1; transform: none; pointer-events: auto; visibility: visible; transition-delay: 0s; }
  .nav a { padding: 12px 0; font-size: 17px; border-bottom: 1px solid var(--line); border-radius: 0; }
}

/* ---------------- Секции ---------------- */
.section { padding: 112px 0 0; }
.section:last-of-type { padding-bottom: 112px; }
@media (max-width: 700px) { .section { padding-top: 80px; } .section:last-of-type { padding-bottom: 80px; } }
.sec-head { display: grid; grid-template-columns: 200px 1fr auto; gap: 24px; align-items: end; padding-bottom: 28px; margin-bottom: 32px; border-bottom: 1px solid var(--line); }
.sec-head .label { align-self: start; padding-top: 8px; }
.sec-head p { color: var(--text-2); max-width: 46ch; margin-top: 14px; }
@media (max-width: 860px) { .sec-head { grid-template-columns: 1fr; gap: 12px; } .sec-head .label { padding: 0; } }
/* старое имя, используется на странице товара */
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; padding-bottom: 20px; margin-bottom: 28px; border-bottom: 1px solid var(--line); }
.section-head h2 { margin-top: 10px; font-size: clamp(24px, 3vw, 32px); }

/* ---------------- Первый экран ---------------- */
.hero { padding: 56px 0 0; }
.hero-top { display: flex; justify-content: space-between; gap: 16px; font: 500 12px var(--mono); color: var(--text-3); text-transform: uppercase; letter-spacing: .02em; padding-bottom: 28px; }
.hero-top .live { color: var(--text-2); }
.hero-top .live::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-right: 8px; vertical-align: 1px; }
.hero h1 { font-size: clamp(38px, 5.6vw, 80px); letter-spacing: -.045em; line-height: 1; max-width: 17ch; }
.hero h1 .dim { color: var(--text-3); }
.hero-row { display: grid; grid-template-columns: 1fr minmax(0, 440px); gap: 48px; align-items: end; margin-top: 32px; }
.hero-lead { font-size: 18px; color: var(--text-2); max-width: 46ch; }
.hero-lead b { color: var(--text); font-weight: 500; }
.search-cta { display: flex; height: 48px; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg-2); overflow: hidden; transition: border-color .15s ease; }
.search-cta:focus-within { border-color: var(--text-3); }
.search-cta input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 0 16px; outline: none; }
.search-cta input::placeholder { color: var(--text-3); }
.search-cta button { padding: 0 18px; font-weight: 500; color: var(--bg); background: var(--text); transition: background-color .15s ease; }
.search-cta button:hover { background: #fff; }
.quick { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 12px; font-size: 14px; color: var(--text-3); }
.quick a { color: var(--text-2); text-decoration: none; }
.quick a:hover { color: var(--text); }
@media (max-width: 860px) { .hero { padding-top: 48px; } .hero-row { grid-template-columns: 1fr; gap: 28px; margin-top: 28px; } .hero-top .hide-sm { display: none; } }

/* Витрина: список слева, живое демо справа */
.showcase { display: grid; grid-template-columns: minmax(0, 380px) 1fr; margin-top: 56px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.sc-list { display: flex; flex-direction: column; border-right: 1px solid var(--line); padding: 8px 0; }
.sc-item {
  display: grid; grid-template-columns: 32px 1fr auto; align-items: baseline; gap: 12px; text-align: left;
  padding: 14px 20px 14px 0; border-bottom: 1px solid var(--line); color: var(--text-2);
  transition: color .15s ease;
}
.sc-item:last-of-type { border-bottom: 0; }
.sc-item .sc-n { font: 500 12px var(--mono); color: var(--text-3); }
.sc-item .sc-name { font-size: 17px; font-weight: 500; letter-spacing: -.015em; }
.sc-item .sc-name small { display: block; font-size: 13px; font-weight: 400; color: var(--text-3); letter-spacing: 0; margin-top: 2px; }
.sc-item .sc-price { font: 400 14px var(--mono); color: var(--text-3); }
.sc-item:hover, .sc-item[aria-selected="true"] { color: var(--text); }
.sc-item[aria-selected="true"] .sc-n { color: var(--accent); }
.sc-item[aria-selected="true"] .sc-price { color: var(--text); }
.sc-all { margin-top: auto; padding: 16px 20px 8px 44px; color: var(--text-2); font-size: 14px; text-decoration: none; }
.sc-all:hover { color: var(--text); }
.sc-view { padding: 20px 0 20px 20px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.sc-media { border-radius: var(--r); border: 1px solid var(--line); }
.sc-cap { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--text-3); }
.sc-cap span { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: .02em; }
.sc-cap a { color: var(--text-2); text-decoration: none; }
.sc-cap a:hover { color: var(--text); }
@media (max-width: 960px) {
  .showcase { grid-template-columns: 1fr; margin-top: 48px; }
  .sc-view { order: -1; padding: 16px 0; border-bottom: 1px solid var(--line); }
  .sc-list { border-right: 0; padding: 0; }
  .sc-item { padding-right: 0; }
  .sc-all { padding-left: 44px; padding-bottom: 16px; }
}

/* Строка фактов под витриной */
.facts-row { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--line); }
.facts-row div { padding: 20px 20px 22px 0; }
.facts-row div + div { padding-left: 20px; border-left: 1px solid var(--line); }
.facts-row b { display: block; font: 500 22px var(--mono); letter-spacing: -.03em; }
.facts-row span { color: var(--text-3); font-size: 14px; }
@media (max-width: 760px) {
  .facts-row { grid-template-columns: 1fr 1fr; }
  .facts-row div:nth-child(3) { padding-left: 0; border-left: 0; }
  .facts-row div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}

/* ---------------- Сетка товаров ---------------- */
.pgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 24px; }
@media (max-width: 960px) { .pgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .pgrid { grid-template-columns: 1fr; gap: 32px; } }

.pcard { position: relative; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.pmedia {
  position: relative; aspect-ratio: 16 / 10; overflow: hidden; border-radius: var(--r);
  background: var(--bg-2); border: 1px solid var(--line); transition: border-color .2s ease;
}
.pcard:hover .pmedia { border-color: var(--line-2); }
.pmedia img { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: opacity .3s ease; }
.pmedia iframe {
  position: absolute; top: 0; left: 0; width: 1200px; max-width: none; height: 750px; border: 0;
  transform-origin: 0 0; transform: scale(var(--s, .3)); opacity: 0; transition: opacity .3s ease; pointer-events: none;
}
.pmedia.playing iframe { opacity: 1; }
.pmedia.playing img { opacity: 0; }
.live-hint {
  position: absolute; left: 10px; bottom: 10px; z-index: 2; padding: 4px 8px; border-radius: 4px;
  font: 500 11px var(--mono); text-transform: uppercase; letter-spacing: .02em;
  background: rgba(13, 14, 15, .8); color: var(--text-2);
  opacity: 0; transform: translateY(4px); transition: opacity .2s var(--ease-out), transform .2s var(--ease-out);
}
.live-hint i { display: inline-block; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); margin-right: 6px; vertical-align: 1px; }
.pcard:hover .live-hint { opacity: 1; transform: none; }
.pmedia.playing .live-hint { opacity: 0; }
@media (hover: none) { .live-hint { display: none; } }

.pbody { display: flex; flex-direction: column; gap: 4px; }
.prow { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.pcard h3 { font-size: 17px; font-weight: 500; letter-spacing: -.015em; }
.pcard-link { text-decoration: none; }
.pcard-link::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.pcard p { color: var(--text-2); font-size: 14px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pmeta { display: flex; align-items: center; gap: 10px; margin-top: 6px; font: 400 12px var(--mono); color: var(--text-3); }
.pmeta .new { color: var(--accent); }
.pmeta .sp { flex: 1; }
.price { font-size: 15px; white-space: nowrap; color: var(--text); }
.price s { color: var(--text-3); font-size: 13px; margin-left: 6px; }
.price small { color: var(--text-3); font-size: 13px; }
.add-btn {
  position: relative; z-index: 2; height: 28px; padding: 0 10px; display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line-2); border-radius: var(--r-sm); font: 500 12px var(--mono); color: var(--text-2);
  transition: color .15s ease, border-color .15s ease, transform .16s var(--ease-out);
}
.add-btn svg { width: 12px; height: 12px; }
.add-btn:hover { color: var(--text); border-color: var(--text-3); }
.add-btn:active { transform: scale(.96); }
.add-btn.in-cart { color: var(--accent); border-color: rgba(61, 219, 179, .4); }
.pcard .btn { position: relative; z-index: 2; }

/* Крупные карточки шаблонов */
.pgrid--tpl { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pgrid--tpl .pmedia { aspect-ratio: 4 / 3; }

/* ---------------- Коллекции: таблица ---------------- */
.colls { display: flex; flex-direction: column; }
.coll {
  display: grid; grid-template-columns: 1fr 120px auto 24px; align-items: center; gap: 24px;
  padding: 18px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--text-2);
  transition: color .15s ease;
}
.coll:first-child { padding-top: 0; }
.coll b { font-weight: 500; font-size: clamp(20px, 2.4vw, 28px); letter-spacing: -.025em; color: var(--text); }
.coll .n { font: 400 14px var(--mono); color: var(--text-3); }
.coll-imgs { display: flex; gap: 6px; }
.coll-imgs img { width: 96px; height: 60px; object-fit: cover; object-position: top; border-radius: 4px; border: 1px solid var(--line); opacity: .55; transition: opacity .2s ease; }
.coll-arrow { color: var(--text-3); transition: transform .2s var(--ease-out), color .15s ease; }
.coll:hover .coll-imgs img { opacity: 1; }
.coll:hover .coll-arrow { color: var(--text); transform: translateX(3px); }
@media (max-width: 760px) {
  .coll { grid-template-columns: 1fr auto; gap: 12px; }
  .coll-imgs, .coll-arrow { display: none; }
}

/* ---------------- Как это работает ---------------- */
.how { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; }
.how > div { padding: 0 32px 0 0; }
.how > div + div { padding-left: 32px; border-left: 1px solid var(--line); }
.how .n { font: 500 12px var(--mono); color: var(--accent); display: block; margin-bottom: 40px; }
.how h3 { font-size: 22px; margin-bottom: 10px; }
.how p { color: var(--text-2); max-width: 34ch; }
@media (max-width: 800px) {
  .how { grid-template-columns: 1fr; }
  .how > div, .how > div + div { padding: 24px 0; border-left: 0; border-top: 1px solid var(--line); }
  .how > div:first-child { border-top: 0; padding-top: 0; }
  .how .n { margin-bottom: 12px; }
}

/* ---------------- Набор «Всё сразу» ---------------- */
.bundle { display: grid; grid-template-columns: 1fr minmax(0, 420px); gap: 48px; padding: 48px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line); }
.bundle h2 { margin: 14px 0 16px; }
.bundle > div { min-width: 0; }
.bundle > div > p { color: var(--text-2); max-width: 44ch; }
.bundle-strip { display: flex; gap: 6px; margin-top: 32px; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, #000 70%, transparent); mask-image: linear-gradient(90deg, #000 70%, transparent); }
.bundle-strip img { width: 104px; height: 65px; flex: none; object-fit: cover; object-position: top; border-radius: 4px; border: 1px solid var(--line); }
.bundle-box { display: flex; flex-direction: column; gap: 4px; padding-left: 48px; border-left: 1px solid var(--line); }
.bundle-box .old { color: var(--text-3); font-size: 14px; }
.bundle-box .old span { text-decoration: line-through; font-family: var(--mono); }
.bundle-box .new { font: 500 clamp(44px, 5vw, 64px)/1 var(--mono); letter-spacing: -.05em; margin: 6px 0 20px; }
.bundle-box ul { list-style: none; margin: 0 0 24px; padding: 0; color: var(--text-2); font-size: 15px; }
.bundle-box li { padding: 9px 0; border-top: 1px solid var(--line); }
.bundle-box li:last-child { border-bottom: 1px solid var(--line); }
@media (max-width: 860px) {
  .bundle { grid-template-columns: 1fr; padding: 28px 20px; gap: 32px; }
  .bundle-box { padding-left: 0; border-left: 0; }
}

/* ---------------- На заказ ---------------- */
.custom-grid { display: grid; grid-template-columns: minmax(0, 400px) 1fr; gap: 56px; align-items: start; }
@media (max-width: 900px) { .custom-grid { grid-template-columns: 1fr; gap: 40px; } }
.svc-list { display: flex; flex-direction: column; }
.svc-row { display: grid; grid-template-columns: 1fr auto; gap: 6px 24px; padding: 20px 0; border-bottom: 1px solid var(--line); }
.svc-row:first-child { padding-top: 0; }
.svc-row h3 { font-size: 20px; font-weight: 500; }
.svc-row p { grid-column: 1; color: var(--text-2); font-size: 15px; max-width: 48ch; }
.svc-row .from { grid-column: 2; grid-row: 1; font: 400 15px var(--mono); color: var(--text); white-space: nowrap; }
.svc-more { margin-top: 24px; }

/* ---------------- Вопросы ---------------- */
.faq { max-width: 860px; margin-left: 224px; }
@media (max-width: 860px) { .faq { margin-left: 0; } }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 20px 40px 20px 0; position: relative; font-size: 18px; font-weight: 500; letter-spacing: -.015em; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 10px; height: 10px; margin-top: -7px; border-right: 1.5px solid var(--text-3); border-bottom: 1.5px solid var(--text-3); transform: rotate(45deg); transition: transform .2s var(--ease-out); }
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq details p { color: var(--text-2); padding: 0 40px 22px 0; max-width: 65ch; }

/* ---------------- Контакты и форма ---------------- */
.contact { display: grid; grid-template-columns: 1fr minmax(0, 520px); gap: 64px; }
@media (max-width: 900px) { .contact { grid-template-columns: 1fr; gap: 40px; } }
.contact h2 { margin: 14px 0 16px; }
.contact-lead { color: var(--text-2); max-width: 40ch; }
.contact-links { display: flex; flex-direction: column; margin-top: 32px; max-width: 380px; }
.contact-links a { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-top: 1px solid var(--line); text-decoration: none; color: var(--text-2); transition: color .15s ease; }
.contact-links a:last-child { border-bottom: 1px solid var(--line); }
.contact-links a:hover { color: var(--text); }
.contact-links b { font-weight: 500; color: var(--text); }
.contact-links small { font: 400 14px var(--mono); }
.form { display: flex; flex-direction: column; gap: 16px; }
.form h3 { display: none; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 14px; color: var(--text-2); }
.field input, .field select, .field textarea {
  width: 100%; height: 44px; padding: 0 14px; border-radius: var(--r-sm);
  border: 1px solid var(--line-2); background: var(--bg-2); outline: none;
  transition: border-color .15s ease;
}
.field textarea { height: auto; min-height: 110px; padding: 12px 14px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--text-3); }
.field ::placeholder { color: var(--text-3); }
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%); background-position: calc(100% - 18px) 19px, calc(100% - 13px) 19px; background-size: 5px 5px; background-repeat: no-repeat; }
.form-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 520px) { .form-2 { grid-template-columns: 1fr; } }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 4px; }
.note { font-size: 13px; color: var(--text-3); }

/* ---------------- Подвал ---------------- */
.footer { border-top: 1px solid var(--line); padding: 56px 0 32px; color: var(--text-2); font-size: 14px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.2fr; gap: 32px; }
.footer-grid > div { display: flex; flex-direction: column; gap: 10px; }
.footer-grid b { font: 500 12px var(--mono); text-transform: uppercase; letter-spacing: .02em; color: var(--text-3); margin-bottom: 4px; }
.footer-grid a:not(.logo) { text-decoration: none; color: var(--text-2); }
.footer-grid a:not(.logo):hover { color: var(--text); }
.footer-grid .logo { color: var(--text); }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; margin-top: 56px; padding-top: 20px; border-top: 1px solid var(--line); font: 400 12px var(--mono); color: var(--text-3); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > div:first-child { grid-column: 1 / -1; } .footer-bottom { flex-direction: column; } }

/* ---------------- Корзина и оформление ---------------- */
.drawer-bg { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .55); opacity: 0; pointer-events: none; transition: opacity .3s ease; }
.drawer-bg.open { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 61; width: min(420px, 100%);
  display: flex; flex-direction: column; background: var(--bg); border-left: 1px solid var(--line);
  transform: translateX(100%); transition: transform .4s var(--ease-drawer); visibility: hidden;
}
.drawer.open { transform: none; visibility: visible; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h3 { font-size: 16px; font-weight: 500; }
.drawer-list { flex: 1; overflow: auto; padding: 8px 20px; }
.drawer-foot { padding: 16px 20px 20px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 12px; }
.ci { display: grid; grid-template-columns: 64px 1fr auto auto; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.ci-img { width: 64px; height: 40px; border-radius: 4px; object-fit: cover; object-position: top; border: 1px solid var(--line); background: var(--bg-2); }
.ci-bundle { display: grid; place-items: center; font: 500 11px var(--mono); color: var(--accent); }
.ci-body { min-width: 0; }
.ci-body b { display: block; font-weight: 500; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ci-body small { color: var(--text-3); font-size: 13px; }
.ci-price { font: 400 14px var(--mono); }
.co-total { display: flex; justify-content: space-between; align-items: baseline; font-size: 15px; color: var(--text-2); }
.co-total b { font: 500 22px var(--mono); color: var(--text); letter-spacing: -.03em; }
.bundle-hint { text-align: left; padding: 12px 14px; border-radius: var(--r-sm); border: 1px dashed var(--line-2); color: var(--text-2); font-size: 14px; transition: color .15s ease, border-color .15s ease; }
.bundle-hint:hover { color: var(--text); border-color: var(--text-3); }
.empty { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 40px 0; }
.empty.wide { grid-column: 1 / -1; padding: 64px 0; }
.empty-ic { color: var(--text-3); margin-bottom: 4px; }
.empty b { font-weight: 500; font-size: 17px; }
.empty .btn { margin-top: 8px; }

.modal { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 16px; background: rgba(0, 0, 0, .6); opacity: 0; pointer-events: none; transition: opacity .2s ease; }
.modal.open { opacity: 1; pointer-events: auto; }
.modal-box {
  position: relative; width: min(480px, 100%); max-height: calc(100vh - 32px); overflow: auto;
  padding: 28px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line-2);
  box-shadow: 0 40px 100px -30px rgba(0, 0, 0, .9);
  transform: scale(.97) translateY(6px); transition: transform .25s var(--ease-out);
}
.modal.open .modal-box { transform: none; }
.modal-box h3 { font-size: 24px; letter-spacing: -.025em; }
.modal-close { position: absolute; top: 16px; right: 16px; width: 32px; height: 32px; display: grid; place-items: center; border-radius: var(--r-sm); color: var(--text-3); }
.modal-close:hover { color: var(--text); background: var(--bg-3); }
.co-list { list-style: none; padding: 0; margin: 20px 0 16px; }
.co-list li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.co-list b { font: 400 14px var(--mono); }
.modal .co-total { margin-bottom: 20px; }
.notice { font-size: 14px; color: var(--text-2); padding: 14px 0 0; margin-bottom: 20px; border-top: 1px solid var(--line); }

.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 80; max-width: calc(100% - 32px);
  padding: 12px 16px; border-radius: var(--r-sm); background: var(--text); color: var(--bg); font-size: 14px; font-weight: 500;
  transform: translate(-50%, 12px); opacity: 0;
}
.toast.show { animation: toast-in .4s var(--ease-out) forwards; }
@keyframes toast-in { to { transform: translate(-50%, 0); opacity: 1; } }

/* ---------------- Каталог ---------------- */
.cat-head { padding: 72px 0 40px; }
.cat-head h1 { font-size: clamp(40px, 6vw, 72px); letter-spacing: -.045em; margin: 16px 0 16px; }
.cat-head p { color: var(--text-2); max-width: 56ch; }
.toolbar { position: sticky; top: 60px; z-index: 30; background: rgba(13, 14, 15, .92); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.toolbar .wrap { display: flex; align-items: center; gap: 12px; height: 60px; }
.segs { display: flex; gap: 2px; }
.seg { height: 34px; padding: 0 12px; border-radius: var(--r-sm); color: var(--text-2); font-size: 15px; display: inline-flex; align-items: center; gap: 8px; transition: color .15s ease, background-color .15s ease; }
.seg .n { font: 400 12px var(--mono); color: var(--text-3); }
.seg:hover { color: var(--text); }
.seg[aria-pressed="true"] { background: var(--bg-3); color: var(--text); }
.search { flex: 1; max-width: 360px; margin-left: auto; display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 10px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--bg-2); color: var(--text-3); }
.search:focus-within { border-color: var(--text-3); }
.search svg { width: 15px; height: 15px; flex: none; }
.search input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; color: var(--text); font-size: 15px; }
.search input::-webkit-search-cancel-button { display: none; }
.search kbd { font: 400 11px var(--mono); padding: 2px 6px; border: 1px solid var(--line-2); border-radius: 4px; }
.sort { height: 36px; padding: 0 28px 0 10px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--bg-2); font-size: 14px; appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%); background-position: calc(100% - 14px) 15px, calc(100% - 9px) 15px; background-size: 5px 5px; background-repeat: no-repeat; }
.cats-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 24px 0 32px; }
.filters { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { height: 30px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); color: var(--text-2); font-size: 14px; transition: color .15s ease, border-color .15s ease; }
.chip:hover { color: var(--text); border-color: var(--line-2); }
.chip[aria-pressed="true"] { color: var(--text); border-color: var(--text-3); }
#result-info { font: 400 13px var(--mono); color: var(--text-3); white-space: nowrap; }
@media (max-width: 860px) {
  .toolbar { position: static; }
  .toolbar .wrap { flex-wrap: wrap; height: auto; padding-top: 12px; padding-bottom: 12px; }
  .segs { width: 100%; overflow-x: auto; }
  .search { max-width: none; margin-left: 0; }
  .search kbd { display: none; }
  .cats-row { flex-direction: column; align-items: flex-start; }
  .filters { flex-wrap: nowrap; overflow-x: auto; max-width: 100%; padding-bottom: 4px; }
  .chip { flex: none; }
}

/* ---------------- Страница товара ---------------- */
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; padding: 28px 0 32px; font-size: 14px; color: var(--text-3); }
.crumbs a { color: var(--text-2); text-decoration: none; }
.crumbs a:hover { color: var(--text); }
.prod { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 48px; align-items: start; }
.prod > * { min-width: 0; }
.prod h1 { font-size: clamp(36px, 5vw, 64px); letter-spacing: -.045em; }
.prod-tagline { color: var(--text-2); font-size: 18px; margin: 14px 0 18px; max-width: 56ch; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 28px; }
.tag { font: 400 12px var(--mono); color: var(--text-3); padding: 4px 8px; border-radius: 4px; border: 1px solid var(--line); }
.tag--strong { color: var(--text-2); border-color: var(--line-2); }
.viewer { border-radius: var(--r); border: 1px solid var(--line); overflow: hidden; background: var(--bg-2); }
.viewer-bar { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-bottom: 1px solid var(--line); }
.dots3 { display: none; }
.dev-toggle { display: flex; gap: 2px; }
.dev-toggle button { height: 30px; padding: 0 10px; border-radius: var(--r-sm); font-size: 13px; color: var(--text-3); transition: color .15s ease, background-color .15s ease; }
.dev-toggle button:hover { color: var(--text); }
.dev-toggle button[aria-pressed="true"] { background: var(--bg-3); color: var(--text); }
.viewer-bar .sp { flex: 1; }
.stage { display: flex; justify-content: center; height: min(68vh, 640px); background: var(--bg); background-image: radial-gradient(var(--line) 1px, transparent 1px); background-size: 16px 16px; }
.stage iframe { width: var(--w, 100%); max-width: 100%; height: 100%; border: 0; background: #fff; transition: width .4s var(--ease-in-out); }
.stage[style*="390px"] iframe, .stage[style*="820px"] iframe { border-left: 1px solid var(--line-2); border-right: 1px solid var(--line-2); }
@media (max-width: 700px) { .dev-toggle { display: none; } .stage { height: 70vh; } }

.tabs-wrap { margin-top: 40px; }
.tabs-nav { display: flex; gap: 24px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tabs-nav button { position: relative; padding: 12px 0; font-size: 15px; color: var(--text-3); white-space: nowrap; transition: color .15s ease; }
.tabs-nav button:hover { color: var(--text); }
.tabs-nav button[aria-selected="true"] { color: var(--text); }
.tabs-nav button[aria-selected="true"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: var(--text); }
.tab-panel { padding: 24px 0; }
.feat-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; }
.feat-list li { padding: 12px 0 12px 22px; border-bottom: 1px solid var(--line); color: var(--text-2); position: relative; }
.feat-list li::before { content: ""; position: absolute; left: 2px; top: 21px; width: 8px; height: 1px; background: var(--accent); }
@media (max-width: 640px) { .feat-list { grid-template-columns: 1fr; } }
.steps-list { margin: 0 0 20px; padding: 0; list-style: none; counter-reset: s; }
.steps-list li { counter-increment: s; display: grid; grid-template-columns: 36px 1fr; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--text-2); }
.steps-list li::before { content: "0" counter(s); font: 500 12px/1.9 var(--mono); color: var(--text-3); }
code { font: 400 .9em var(--mono); padding: 1px 5px; border-radius: 4px; background: var(--bg-3); color: var(--text); }
.code { margin: 0; padding: 16px 18px; border-radius: var(--r); background: var(--bg-2); border: 1px solid var(--line); font: 400 13px/1.7 var(--mono); color: var(--text-2); overflow-x: auto; }
.code .c { color: var(--text-3); }
.tree { font: 400 14px/1 var(--mono); color: var(--text-2); }
.tree > div { display: flex; align-items: center; gap: 10px; padding: 10px 0 10px 24px; border-bottom: 1px solid var(--line); }
.tree .tree-root { padding-left: 0; color: var(--text); }
.tree .ico { width: 15px; height: 15px; color: var(--text-3); }
.rel { display: grid; grid-template-columns: 60px 1fr; gap: 4px 16px; }
.rel b { font: 500 14px var(--mono); }
.rel p { grid-column: 2; color: var(--text-2); }

.prod aside { position: sticky; top: 84px; display: flex; flex-direction: column; gap: 24px; }
.buy { display: flex; flex-direction: column; gap: 10px; padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.buy-price { font: 500 40px/1 var(--mono); letter-spacing: -.05em; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.buy-price s { font-size: 18px; color: var(--text-3); letter-spacing: -.02em; }
.buy-price small { font-size: 16px; color: var(--text-3); letter-spacing: 0; }
.buy-price .badge { font: 500 13px var(--mono); color: var(--accent); letter-spacing: 0; }
.buy > p { font-size: 14px; margin-bottom: 8px; }
.buy-incl { list-style: none; margin: 8px 0 0; padding: 0; font-size: 14px; color: var(--text-2); }
.buy-incl li { padding: 8px 0 8px 20px; position: relative; }
.buy-incl li::before { content: ""; position: absolute; left: 0; top: 13px; width: 9px; height: 5px; border-left: 1.5px solid var(--accent); border-bottom: 1.5px solid var(--accent); transform: rotate(-45deg); }
.bundle-mini { font-size: 14px; color: var(--text-2); text-decoration: none; margin-top: 4px; }
.bundle-mini:hover { color: var(--text); }
.facts { display: flex; flex-direction: column; }
.facts div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.facts span { color: var(--text-3); }
.facts b { font: 400 14px var(--mono); text-align: right; }
@media (max-width: 1000px) {
  .prod { display: flex; flex-direction: column; gap: 0; }
  .prod > div:first-child { display: contents; }
  .prod .tabs-wrap, .prod .viewer { order: 3; width: 100%; }
  .prod aside { position: static; order: 2; margin-bottom: 32px; width: 100%; }
}

/* ---------------- Лицензия ---------------- */
.doc { max-width: 720px; }
.doc h1 { letter-spacing: -.045em; }
.doc > p { color: var(--text-2); font-size: 17px; }
.doc h2 { font-size: 24px; margin: 48px 0 12px; padding-top: 24px; border-top: 1px solid var(--line); }
.yesno { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; margin: 40px 0 8px; }
.yesno h3 { font: 500 12px var(--mono); text-transform: uppercase; letter-spacing: .02em; margin-bottom: 12px; }
.yes h3 { color: var(--accent); }
.no h3 { color: var(--danger); }
.yesno ul { list-style: none; margin: 0; padding: 0; }
.yesno li { padding: 10px 0; border-top: 1px solid var(--line); color: var(--text-2); font-size: 15px; }
@media (max-width: 640px) { .yesno { grid-template-columns: 1fr; } }

/* ---------------- Появление при прокрутке ---------------- */
.reveal { opacity: 0; transform: translateY(8px); transition: opacity .5s var(--ease-out), transform .5s var(--ease-out); }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* Длинные названия не распирают карточку */
.prow h3 { min-width: 0; }
.pmeta { flex-wrap: wrap; row-gap: 6px; }
.custom-grid > *, .contact > * { min-width: 0; }

/* =====================================================================
   v4: больше энергии. Живые демо на виду, акцент крупными блоками,
   движение с целью: появление, автопрокрутка витрины, бегущая строка.
   ===================================================================== */

/* Первый экран: текст слева, живая стена справа */
.hero { padding-top: 48px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 56px; align-items: center; padding-bottom: 56px; }
.hero h1 { font-size: clamp(40px, 5.4vw, 84px); max-width: none; line-height: 1.06; letter-spacing: -.05em; }
.hero h1 .hl { color: var(--accent-ink); background: var(--accent); padding: 0 .12em; margin: 0 -.02em; border-radius: .12em; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.hero-copy .hero-lead { margin: 28px 0 28px; }
.hero-copy .search-cta { max-width: 520px; }
@media (max-width: 960px) { .hero-grid { grid-template-columns: 1fr; gap: 40px; } }

/* Слова заголовка поднимаются по очереди (один раз при загрузке) */
.split .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.split .w > span { display: inline-block; transform: translateY(105%); animation: rise .7s var(--ease-out) forwards; }
@keyframes rise { to { transform: none; } }

/* Живая стена */
.wall { display: grid; grid-template-columns: 1.15fr 1fr; grid-template-rows: 190px 150px 170px; gap: 12px; }
.wall-tile { position: relative; overflow: hidden; border-radius: 10px; border: 1px solid var(--line-2); background: var(--bg-2); opacity: 0; transform: translateY(16px) scale(.98); animation: tile-in .7s var(--ease-out) forwards; transition: border-color .2s ease; }
.wall-tile:nth-child(1) { animation-delay: .25s; } .wall-tile:nth-child(2) { animation-delay: .33s; }
.wall-tile:nth-child(3) { animation-delay: .41s; } .wall-tile:nth-child(4) { animation-delay: .49s; }
@keyframes tile-in { to { opacity: 1; transform: none; } }
.wall-tile:hover { border-color: var(--accent); }
.wall-tile img, .wall-tile iframe { position: absolute; top: 0; left: 0; border: 0; }
.wall-tile img { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: opacity .5s ease; }
.wall-tile iframe { width: calc(100% / .42); height: calc(100% / .42); max-width: none; transform-origin: 0 0; transform: scale(.42); opacity: 0; transition: opacity .5s ease; pointer-events: none; }
.wall-tile.ready img { opacity: 0; }
.wall-tile.ready iframe { opacity: 1; }
.wall-tile .tname { position: absolute; left: 10px; bottom: 10px; z-index: 2; padding: 5px 9px; border-radius: 5px; background: rgba(13, 14, 15, .86); font: 500 12px var(--mono); color: var(--text); }
.wall .t1 { grid-row: span 2; }
.wall .t4 { grid-column: span 2; }
@media (max-width: 520px) { .wall { grid-template-rows: 150px 120px 150px; gap: 8px; } }

.facts-row { border-top: 1px solid var(--line); }
.facts-row b { font-size: clamp(28px, 3.4vw, 44px); letter-spacing: -.05em; }

/* Бегущая строка: линейно, постоянно, останавливается при наведении */
.marquee { overflow: hidden; background: var(--accent); color: var(--accent-ink); padding: 14px 0; margin-top: 0; }
.marquee-track { display: flex; width: max-content; animation: marquee 38s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span { display: inline-flex; align-items: center; font-weight: 600; font-size: clamp(18px, 2vw, 24px); letter-spacing: -.02em; padding-right: 28px; white-space: nowrap; }
.marquee-track span::after { content: ""; width: 8px; height: 8px; margin-left: 28px; border-radius: 2px; background: var(--accent-ink); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* Заголовки разделов крупнее */
.sec-head h2, h2 { font-size: clamp(32px, 4.4vw, 58px); letter-spacing: -.045em; }

/* Витрина: демо на акцентной подложке, полоска времени у активной строки */
.showcase { margin-top: 0; border-top: 0; border-bottom: 0; grid-template-columns: minmax(0, 360px) 1fr; gap: 0; }
.sc-list { padding-top: 0; }
.sc-item { position: relative; }
.sc-bar { position: absolute; left: 0; right: 20px; bottom: -1px; height: 2px; background: var(--accent); transform: scaleX(0); transform-origin: 0 50%; }
.showcase.auto .sc-item[aria-selected="true"] .sc-bar { animation: sc-progress 5s linear forwards; }
.showcase.auto:hover .sc-bar, .showcase.off .sc-bar { animation-play-state: paused !important; }
@keyframes sc-progress { to { transform: scaleX(1); } }
.sc-item[aria-selected="true"] .sc-name { color: var(--text); }
.sc-view { padding: 24px; margin-left: 24px; border-radius: 14px; background: var(--accent); }
.sc-media { border: 0; box-shadow: 0 24px 60px -24px rgba(5, 32, 25, .7); }
.sc-media img, .sc-media iframe { transition: opacity .35s ease; }
.sc-cap span { color: rgba(5, 32, 25, .7); }
.sc-cap a { color: var(--accent-ink); font-weight: 500; }
.sc-cap a:hover { color: #000; }
@media (max-width: 960px) {
  .sc-view { margin-left: 0; padding: 14px; border-bottom: 0; margin-bottom: 8px; }
  .sc-bar { right: 0; }
}

/* Карточки: живее при наведении */
.pcard .pmedia { transition: border-color .2s ease, transform .3s var(--ease-out); }
@media (hover: hover) { .pcard:hover .pmedia { transform: translateY(-4px); border-color: var(--accent); } }
.pmedia img { transition: opacity .3s ease, transform .6s var(--ease-out); }
@media (hover: hover) { .pcard:hover .pmedia img { transform: scale(1.03); } }

/* «Как это работает»: крупные цифры */
.how .n { font-size: clamp(48px, 6vw, 80px); line-height: 1; letter-spacing: -.06em; margin-bottom: 28px; }

/* Набор: акцентный блок */
.bundle { background: var(--accent); border: 0; color: var(--accent-ink); }
.bundle .label { color: rgba(5, 32, 25, .6); }
.bundle > div > p { color: rgba(5, 32, 25, .78); }
.bundle-box { border-left-color: rgba(5, 32, 25, .18); }
.bundle-box .old { color: rgba(5, 32, 25, .6); }
.bundle-box ul { color: rgba(5, 32, 25, .85); }
.bundle-box li, .bundle-box li:last-child { border-color: rgba(5, 32, 25, .16); }
.bundle-box .btn--accent { background: var(--accent-ink); border-color: var(--accent-ink); color: #fff; }
.bundle-box .btn--accent:hover { background: #000; border-color: #000; }
.bundle-box .btn.in-cart { background: transparent; color: var(--accent-ink); border-color: rgba(5, 32, 25, .4); }
.bundle-strip img { border-color: rgba(5, 32, 25, .2); }
.bundle-strip { animation: none; }
.bundle-strip-track { display: flex; gap: 6px; width: max-content; animation: marquee 50s linear infinite; }

/* Каталог плотнее: 4 колонки на широком экране */
@media (min-width: 1240px) { #catalog-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 36px 20px; } }

/* Появление при прокрутке: заметнее, но быстро */
.reveal { transform: translateY(18px); transition: opacity .6s var(--ease-out), transform .6s var(--ease-out); }

@media (prefers-reduced-motion: reduce) {
  .split .w > span, .wall-tile { animation: none; transform: none; opacity: 1; }
  .marquee-track, .bundle-strip-track { animation: none; }
}

/* =====================================================================
   Шапка из «жидкого стекла» (js/glass.js). Плавающая панель: фон под ней
   размыт, а у края преломляется, по ободу идёт блик сверху-слева.
   ===================================================================== */
.header { position: sticky; top: 0; z-index: 40; padding-top: 12px; background: none; border: 0; -webkit-backdrop-filter: none; backdrop-filter: none; pointer-events: none; }
.header .wrap { display: block; height: auto; }
.header-bar, .nav[data-rim] { --glass-bg: rgb(30 31 33 / .58); }
.header-bar {
  position: relative; pointer-events: auto;
  display: flex; align-items: center; gap: 24px; height: 56px; padding: 0 8px 0 18px; border-radius: 18px;
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(16px) saturate(170%); backdrop-filter: blur(16px) saturate(170%);
  box-shadow: 0 12px 32px -14px rgba(0, 0, 0, .7), 0 0 0 .5px rgba(255, 255, 255, .1);
  transition: box-shadow .3s ease;
}
/* блик по ободу: тонкая рамка, светлее сверху-слева */
.header-bar::before, .nav[data-rim]::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; padding: 1px;
  background: linear-gradient(140deg, rgba(255, 255, 255, .34), rgba(255, 255, 255, .06) 28%, rgba(255, 255, 255, 0) 55%, rgba(255, 255, 255, .1) 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
}
/* мягкое внутреннее свечение верхней кромки */
.header-bar::after { content: ""; position: absolute; left: 14px; right: 14px; top: 0; height: 1px; border-radius: 1px; pointer-events: none; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .28), transparent); }
.header-bar.glass-refract { -webkit-backdrop-filter: var(--glass-filter); backdrop-filter: var(--glass-filter); --glass-bg: rgb(30 31 33 / .42); }
.header .nav a { border-radius: 10px; }
.header .nav a[aria-current="page"] { background: rgba(255, 255, 255, .08); }
.header .cart-btn, .header .burger { border-radius: 12px; }
.header .cart-btn:hover { background: rgba(255, 255, 255, .08); }
.toolbar { top: 80px; }
.prod aside { top: 96px; }

@media (min-width: 861px) {
  .nav[data-rim]::before { display: none; }
}
@media (max-width: 860px) {
  .header { padding-top: 8px; }
  .header-bar { gap: 8px; padding: 0 6px 0 14px; height: 52px; border-radius: 16px; }
  .header .nav {
    position: absolute; top: calc(100% + 8px); left: 0; right: 0; padding: 8px; border: 0; border-radius: 18px;
    background: var(--glass-bg); -webkit-backdrop-filter: blur(18px) saturate(170%); backdrop-filter: blur(18px) saturate(170%);
    box-shadow: 0 20px 50px -16px rgba(0, 0, 0, .8), 0 0 0 .5px rgba(255, 255, 255, .1);
    transform: translateY(-8px) scale(.97); transform-origin: top right;
  }
  .header .nav.glass-refract { -webkit-backdrop-filter: var(--glass-filter); backdrop-filter: var(--glass-filter); --glass-bg: rgb(22 23 25 / .84); }
  .header .nav { --glass-bg: rgb(22 23 25 / .9); }
  .header .nav.open { transform: none; }
  .header .nav a { padding: 12px 12px; border-bottom: 0; border-radius: 12px; }
  .toolbar { top: 0; }
}
@media (prefers-reduced-transparency: reduce) {
  .header-bar, .header .nav { background: #1e1f21 !important; -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
}

/* Меню внутри стеклянной панели: вложенное стекло в Chromium «не видит» фон,
   поэтому на телефоне меню — плотная тёмная панель с тем же бликом по ободу */
@media (max-width: 860px) {
  .header .nav, .header .nav.glass-refract { background: #161719 !important; -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
}
.toolbar { top: 76px; }
@media (max-width: 860px) { .toolbar { top: 0; } }

/* Переключатель валюты в шапке */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.cur-pick { position: relative; display: inline-flex; }
.cur-pick select {
  height: 36px; padding: 0 26px 0 10px; border: 0; border-radius: 12px; background: transparent; color: var(--text-2);
  font: 500 13px var(--mono); appearance: none; cursor: pointer; field-sizing: content; transition: color .15s ease, background-color .15s ease;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 13px) 16px, calc(100% - 9px) 16px; background-size: 4px 4px; background-repeat: no-repeat;
}
.cur-pick select:hover { color: var(--text); background-color: rgba(255, 255, 255, .08); }
.cur-pick option { background: #161719; color: var(--text); }
.cur-note { margin: 0; font-size: 13px; color: var(--text-3); }
.cur-note:empty { display: none; }
.modal .cur-note { margin: -8px 0 16px; }
@media (max-width: 400px) { .cur-pick select { padding: 0 20px 0 6px; font-size: 12px; } }

/* ---------- Аккаунт: вход, кабинет, админка ---------- */
.acc-btn { text-decoration: none; }
.acc-btn[hidden] { display: none; }
.acc-btn .acc-label { font-size: 14px; }
@media (max-width: 560px) { .acc-btn .acc-label { display: none; } }
.acc-box { max-width: 420px; margin: 0 auto; }
.acc-h { font-size: clamp(32px, 4.4vw, 48px); letter-spacing: -.03em; margin: 12px 0 6px; overflow-wrap: anywhere; }
.acc-tabs { margin: 18px 0 22px; }
.acc-form { display: grid; gap: 14px; }
.acc-small { font-size: 13px; }
.form-err { min-height: 1em; margin: 0; font-size: 14px; color: var(--danger); }
.form-err:empty { display: none; }
.tg-login { min-height: 40px; display: flex; justify-content: center; }
.or { display: flex; align-items: center; gap: 12px; margin: 18px 0; color: var(--text-3); font-size: 13px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.acc-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 28px; }
.acc-head > div:first-child { min-width: 0; }
.acc-actions { display: flex; gap: 8px; }
.acc-banner { padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-2); margin-bottom: 28px; font-size: 15px; }
.acc-banner.ok { border-color: rgba(61, 219, 179, .45); background: rgba(61, 219, 179, .07); }
.acc-sec { margin-top: 40px; }
.acc-sec h2 { font-size: 22px; letter-spacing: -.02em; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tag { font: 500 12px/1 var(--mono); padding: 5px 8px; border-radius: 99px; background: rgba(61, 219, 179, .12); color: var(--accent); }
.own-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.own { display: grid; grid-template-columns: 64px 1fr; grid-template-rows: auto auto; gap: 10px 12px; padding: 12px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-2); }
.own img { width: 64px; height: 48px; object-fit: cover; border-radius: var(--r-sm); background: var(--bg-3); }
.own-b { min-width: 0; display: flex; flex-direction: column; justify-content: center; }
.own-b b { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.own-b small { color: var(--text-3); font-size: 13px; }
.own .btn { grid-column: 1 / -1; }
.orders { display: grid; border-top: 1px solid var(--line); }
.order { display: grid; grid-template-columns: 110px 1fr 110px 120px 150px auto; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.order > * { min-width: 0; overflow-wrap: anywhere; }
.mono { font-family: var(--mono); font-size: 13px; }
.st { font-size: 13px; }
.st-paid { color: var(--accent); }
.st-pending { color: #f2c66d; }
.st-canceled { color: var(--text-3); }
.row-act { display: flex; gap: 6px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 8px; }
.stats > div { padding: 16px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-2); display: flex; flex-direction: column; gap: 4px; }
.stats b { font-size: 24px; letter-spacing: -.02em; }
.stats span { color: var(--text-3); font-size: 13px; }
@media (max-width: 760px) {
  .order { grid-template-columns: 1fr auto; }
  .order > :nth-child(2) { grid-column: 1 / -1; order: -1; }
  .stats { grid-template-columns: 1fr; }
}
.g-btn { gap: 10px; margin-bottom: 10px; }
[hidden] { display: none !important; }
.paybox { border: 1px solid rgba(61, 219, 179, .4); border-radius: var(--r); background: var(--bg-2); padding: 20px; margin-bottom: 28px; display: grid; gap: 18px; }
.paybox-head { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.paybox-head > div:first-child { min-width: 0; }
.paybox-items { margin: 8px 0 0; font-size: 15px; overflow-wrap: anywhere; }
.paybox-sum { text-align: right; display: flex; flex-direction: column; }
.paybox-sum b { font-size: 28px; letter-spacing: -.02em; }
.paybox-sum small { color: var(--text-3); font-size: 13px; }
.paybox-ways { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.payway { border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.payway h3 { font-size: 17px; }
.paydet { margin: 0; font: 500 15px/1.5 var(--mono); white-space: pre-wrap; overflow-wrap: anywhere; padding: 12px; border-radius: var(--r-sm); background: var(--bg-3); }
.payway-act { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.st-claimed { color: #f2c66d; }
