/* Steez. Тёмная тема — винный потрёпанный фэшн-постер: затёртое фото на чёрном, тёплый белый текст, один винный акцент. Шрифты: Oswald, Onest, Marck Script (OFL). */
@font-face { font-family: "Oswald"; src: url("fonts/Oswald.woff2") format("woff2"); font-weight: 200 700; font-display: swap; }
@font-face { font-family: "Marck Script"; src: url("fonts/MarckScript-Regular.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Onest"; src: url("fonts/Onest.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

@property --accent { syntax: "<color>"; inherits: true; initial-value: #9a1f3a; }

:root {
  color-scheme: dark;
  --bg: #0d0a0b;
  --bg-2: rgb(20 14 17 / .78);   /* карточки полупрозрачные: фото проступает между ними */
  --ink: #f4eeea;
  --muted: #b9aeb0;          /* контраст ≥ 5 даже над самым светлым местом фото */
  --line: #43363b;
  --accent: #9a1f3a;         /* винный: белый на нём 8.0:1; всегда винный, цветотип его не меняет */
  --on-accent: #ffffff;
  --ct: #9a1f3a;             /* цвет цветотипа: только как информация, app.js (setCtColor) */
  --danger: #ff8a7a;
  --ink-2: #dcd3d3;          /* вторичный текст */
  --bg-3: #241a1e;           /* зазор между фото в look и cuts */
  --glass: rgb(14 10 12 / .94);
  --scrim: rgb(0 0 0 / .7);
  --edge: rgb(255 255 255 / .16);
  --strike: rgb(255 255 255 / .75);
  --accent-ink: #ec7690;      /* винный как цвет текста: на карточках #171114 около 7:1 */
  --tab-ic: #fff;            /* иконки белые */
  --gut: 16px;
  --tabbar: 60px;
  --r: 3px;
  --r-cut: 3px;                    /* острое: структура, архив, витрина */
  --r-leaf: 3px 18px;              /* лист/лекало: две острые вершины, две скруглённые */
  --r-fold: 3px 3px 40px 3px;      /* сгиб ткани: один мягкий угол */
  --hand: "Marck Script", "Segoe Script", cursive;
  --noise: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .9 -.28'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
  --hit: 48px;
  --head: "Oswald", "Arial Narrow", Impact, sans-serif;
  --text: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
  transition: --accent .8s var(--ease);
}


*, ::before, ::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { height: 100%; -webkit-tap-highlight-color: transparent; -webkit-text-size-adjust: 100%; overscroll-behavior: none; }
body {
  height: 100%; margin: 0; overflow: hidden;
  background: var(--bg); color: var(--ink);
  font: 16px/1.45 var(--text); -webkit-font-smoothing: antialiased;
}
/* Фон тёмной темы: фото закреплено псевдоэлементом (background-attachment: fixed на iOS не работает), поверх винное затемнение.
   Шрифтовой плакат: силуэт Нью-Йорка из вертикального слова STEEZ, Oswald + Bodoni Moda (вариант B, выбран Владом 25.10.2026).
   Генератор и прежний фон-фото — Проекты/steez-фон-варианты (make_typo.py B out.jpg). */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(120% 55% at 100% 0%, rgb(154 31 58 / .22), transparent 70%),
    linear-gradient(rgb(10 6 8 / .25), rgb(10 6 8 / .45)),
    url("bg.jpg") center top / cover no-repeat;
}
/* деталь: вертикальная подпись по левому краю */
body::after {
  content: "STEEZ"; position: fixed; left: 3px; top: 50%; z-index: 0; pointer-events: none;
  writing-mode: vertical-rl; transform: translateY(-50%) rotate(180deg);
  font: 500 9px/1 var(--head); letter-spacing: .32em; color: var(--muted); opacity: .55;
}
h1, h2, h3, p, dl, dd, ul, ol { margin: 0; padding: 0; }
ul, ol { list-style: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }

/* ---------- каркас ---------- */
.app {
  height: 100%; overflow-y: auto; overflow-x: hidden;
  padding: calc(20px + env(safe-area-inset-top)) calc(var(--gut) + env(safe-area-inset-right))
           calc(var(--tabbar) + 28px + env(safe-area-inset-bottom)) calc(var(--gut) + env(safe-area-inset-left));
}
.screen { display: none; max-width: 560px; margin: 0 auto; }
.screen.is-active { display: block; }
.screen--center { min-height: 70%; flex-direction: column; justify-content: center; }
.screen--center:not([hidden]) { display: flex; }
[data-step] > .step { display: none; }
[data-step="welcome"] > [data-when~="welcome"], [data-step="light"] > [data-when~="light"],
[data-step="consent"] > [data-when~="consent"], [data-step="pick"] > [data-when~="pick"],
[data-step="wait"] > [data-when~="wait"], [data-step="result"] > [data-when~="result"] { display: block; animation: rise .5s var(--ease) both; }
.step--center { text-align: center; padding-top: 12vh; }

/* ---------- типографика ---------- */
.kicker { font: 500 13px/1 var(--head); letter-spacing: .18em; text-transform: uppercase; color: var(--accent-ink); margin-bottom: 14px; }
/* восьмилучевая звезда: единственный знак, перед «Steez» на первом экране */
.step[data-when="welcome"] .kicker::before { content: ""; display: inline-block; width: 1.5em; height: 1.5em; margin: -.4em .6em -.4em 0; vertical-align: middle; background: var(--accent);
  clip-path: polygon(50.0% 0.0%, 54.6% 38.9%, 85.4% 14.6%, 61.1% 45.4%, 100.0% 50.0%, 61.1% 54.6%, 85.4% 85.4%, 54.6% 61.1%, 50.0% 100.0%, 45.4% 61.1%, 14.6% 85.4%, 38.9% 54.6%, 0.0% 50.0%, 38.9% 45.4%, 14.6% 14.6%, 45.4% 38.9%); }
.display { font: 700 clamp(32px, 10.4vw, 54px)/1 var(--head); letter-spacing: .01em; text-transform: uppercase; overflow-wrap: anywhere; margin-bottom: 18px; }
.title { font: 600 clamp(26px, 7.6vw, 34px)/1.1 var(--head); letter-spacing: .01em; text-transform: uppercase; overflow-wrap: anywhere; margin-bottom: 14px; }
.sub { font: 500 14px/1.2 var(--head); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 28px 0 12px; }
.lead { font-size: 17px; color: var(--ink-2); margin-bottom: 20px; }
.hint, .note { font-size: 14px; color: var(--muted); margin-top: 12px; }
.note { color: var(--ink); background: var(--bg-2); border: 1px solid var(--line); border-radius: 3px; padding: 12px 14px; margin: 0 0 14px; }
a { color: inherit; }

.facts { margin: 4px 0 24px; border-top: 1px solid var(--line); }
.facts li { display: flex; gap: 14px; align-items: baseline; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink-2); }
.facts b { font: 800 26px/1 var(--head); color: var(--accent-ink); min-width: 2.2ch; }
.rules { counter-reset: n; margin: 0 0 24px; }
.rules li { counter-increment: n; display: flex; gap: 14px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 17px; }
.rules:not(.rules--plain) li::before { content: counter(n); font: 800 20px/1.2 var(--head); color: var(--accent-ink); min-width: 1.2ch; }
.rules--plain li::before { content: ""; flex: none; width: 8px; height: 8px; margin-top: 9px; border-radius: 50%; background: var(--ct); }

/* подсказки к селфи: три рисунка про свет и рамка лица */
.tips { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 0 8px; }
.tip { margin: 0; padding: 8px 6px 10px; text-align: center; font-size: 13px; line-height: 1.25; color: var(--muted); background: var(--bg-2); border: 1px solid var(--line); border-radius: 3px; }
.tip--ok { color: var(--ink); border-color: var(--accent); }
.tip b { display: block; margin-bottom: 4px; font: 600 10px/1 var(--head); letter-spacing: .08em; text-transform: uppercase; }
.tip--ok b { color: var(--accent-ink); }
.tip svg, .frame { display: block; width: 100%; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.lamps { margin: 0 0 12px; }
.lamps li { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; line-height: 1.3; color: var(--muted); }
.lamps i { flex: none; width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); }
.lamps b { display: block; font-weight: 600; font-size: 15px; color: var(--ink); }
.lamps--ok i { border: 2px solid var(--accent); }
.lamps--ok b { color: var(--accent-ink); }
.tip svg { margin-bottom: 6px; }
.frame { max-width: 250px; margin: 0 auto 8px; color: var(--muted); }
.tip .a, .frame .a { stroke: var(--accent); }
.tip .lit { fill: var(--accent); fill-opacity: .22; }
.tip .dark { fill: var(--line); }
.frame .face { stroke: var(--ink); }

/* камера на шаге «селфи»: data-cam на #pick = off (выбор файла) | wait | on */
.cam { display: none; }
[data-cam="wait"] .cam, [data-cam="on"] .cam { display: block; }
[data-cam="wait"] .pick-file, [data-cam="on"] .pick-file { display: none; }
.cam__view { position: relative; aspect-ratio: 3 / 4; width: min(100%, 39vh); margin: 0 auto 10px; border-radius: var(--r); overflow: hidden; background: var(--bg-2); }
.cam__view video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.cam__view .frame { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; margin: 0; }
.cam__view .frame .a { stroke: var(--ink); stroke-opacity: .8; }
.cam__view.is-ok .frame .a { stroke: var(--accent); stroke-opacity: 1; }
.cam__hint { min-height: 2.9em; margin-bottom: 8px; text-align: center; font-size: 16px; font-weight: 600; }

/* ---------- кнопки ---------- */
.btn {
  text-transform: uppercase; letter-spacing: .06em;
  display: flex; align-items: center; justify-content: center; width: 100%; min-height: var(--hit);
  margin: 0 0 10px; padding: 12px 20px;
  font: 600 15px/1.2 var(--text); text-align: center; text-decoration: none; cursor: pointer;
  color: var(--ink); background: var(--bg-2); border: 1px solid var(--line); border-radius: 3px;
  transition: transform .15s var(--ease), opacity .15s;
}
.btn:active { transform: scale(.98); }
.btn--accent { background: var(--noise), var(--accent); background-blend-mode: soft-light, normal; color: var(--on-accent); border-color: rgb(255 255 255 / .14); box-shadow: inset 0 -2px 0 rgb(0 0 0 / .25); border-radius: 3px 16px; transition: transform .15s var(--ease), opacity .15s, border-radius .25s var(--ease); }
.btn--accent:active { border-radius: 16px 3px; }
.btn--ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn--danger { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 45%, transparent); background: transparent; margin-top: 28px; }
.btn.is-busy { opacity: .5; pointer-events: none; }
.btn:focus-visible, .tab:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- ожидание ---------- */
.scan { position: relative; aspect-ratio: 3 / 4; width: min(100%, 39vh); margin: 0 auto 24px; border-radius: var(--r); overflow: hidden; background: var(--bg-2); }
.scan img { display: block; width: 100%; height: 100%; object-fit: cover; }
.scan__line { position: absolute; inset: 0; pointer-events: none; will-change: transform, opacity;
  background: linear-gradient(to bottom, transparent calc(100% - 56px), color-mix(in srgb, var(--accent) 40%, transparent) calc(100% - 2px), var(--accent) calc(100% - 2px));
  animation: scan 2.2s ease-in-out infinite; }
#wait-text { min-height: 1.5em; }

/* ---------- раскрытие ---------- */
/* разбор признаков: нативный <details>, раскрытие без JS */
.insight { margin-top: 28px; }
.insight summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; padding: 8px 14px; cursor: pointer; list-style: none;
  font: 600 13px/1.2 var(--head); letter-spacing: .06em; text-transform: uppercase; background: var(--bg-2); border: 1px solid var(--line); border-radius: 3px; }
.insight summary::-webkit-details-marker { display: none; }
.insight summary::after { content: "+"; flex: none; font: 600 20px/1 var(--text); color: var(--accent-ink); }
.insight[open] summary::after { content: "\2212"; }
.insight summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.insight ul { display: grid; gap: 8px; margin-top: 8px; }
.insight li { background: var(--bg-2); border: 1px solid var(--line); border-radius: 3px; padding: 12px 14px; min-width: 0; overflow-wrap: anywhere; }
.insight li span { display: block; font-size: 12px; color: var(--muted); }
.insight li b { display: block; font-weight: 600; font-size: 16px; }
.insight li p { margin-top: 4px; font-size: 14px; color: var(--ink-2); }
.swatches { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.swatches li { aspect-ratio: 1; border-radius: 50%; background: var(--c); border: 1px solid var(--edge); }
.swatches--avoid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.swatches--avoid li { border-radius: 3px; aspect-ratio: 1.6; position: relative; }
.swatches--avoid li::after { content: ""; position: absolute; left: 14%; right: 14%; top: 50%; height: 2px; background: var(--strike); transform: rotate(-18deg); mix-blend-mode: difference; }
.why li { display: flex; justify-content: space-between; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); color: var(--muted); }
.why b { color: var(--ink); font-weight: 600; text-align: right; }
.actions { margin-top: 28px; }

.reveal .r { opacity: 0; transform: translateY(14px); }
.reveal.is-on .r { animation: rise .6s var(--ease) both; animation-delay: calc(var(--i, 0) * 90ms); }
.reveal.is-on .swatches li { animation: pop .5s var(--ease) both; animation-delay: calc(var(--i, 0) * 60ms + 300ms); }

/* ---------- профиль, статистика ---------- */
.card { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-fold); padding: 18px; margin-bottom: 16px; border-left: 4px solid var(--ct); }
.card__name { font: 600 24px/1.15 var(--head); overflow-wrap: anywhere; }
.card__line { color: var(--muted); margin-top: 6px; }
.admin { margin-top: 24px; }
.stats > div { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; padding: 11px 0; border-bottom: 1px solid var(--line); }
.stats dt { color: var(--ink-2); font-size: 15px; }
.stats dd { text-align: right; font-weight: 700; flex: none; }
.stats small { display: block; font-weight: 400; color: var(--muted); font-size: 12px; }
.stats .ok { color: var(--accent-ink); }
.bars { margin-top: 12px; }
.bars li { display: flex; justify-content: space-between; padding: 6px 0; font-size: 14px; color: var(--muted); }

/* ---------- лента ---------- */
.posts { display: grid; gap: 28px; }
.post { border-radius: var(--r); overflow: hidden; }
.post__head { display: flex; align-items: center; gap: 8px; padding: 0 2px 8px; }
.post__ava { flex: none; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--on-accent); font: 700 12px var(--head); }
.post__author { font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.post__time { font-size: 12px; color: var(--muted); flex: none; }
.look { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px; background: var(--bg-3); }
.look img { width: 100%; aspect-ratio: 1; object-fit: contain; background: #ece9e2; padding: 8px; }
.post__foot { display: flex; gap: 8px; align-items: center; padding: 2px 0 0; }
.post__foot [data-action="like"] { font-size: 15px; padding-left: 0; }
.post__foot [data-action="like"] .ic { width: 26px; height: 26px; }
.post__foot [data-action="report"], .post__foot [data-action="unpublish"] { font-size: 12px; font-weight: 500; padding: 0; }
.post__foot .grow { flex: 1; }
.pbtn { min-width: var(--hit); min-height: var(--hit); display: inline-flex; align-items: center; gap: 8px; padding: 0 12px; background: none; border: 0; color: var(--muted); font: 600 14px var(--text); cursor: pointer; border-radius: 3px; }
.pbtn .ic { fill: none; }
.pbtn[aria-pressed="true"] { color: var(--accent-ink); }
.pbtn[aria-pressed="true"] .ic { fill: currentColor; }

/* ---------- подборка ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; margin: 0 calc(-1 * var(--gut)) 16px; padding: 0 var(--gut); scrollbar-width: none; }
.chip { flex: none; min-height: 40px; padding: 0 16px; border-radius: var(--r-cut); transition: border-radius .35s var(--ease); background: var(--bg-2); color: var(--muted); border: 1px solid var(--line); font: 600 14px var(--text); cursor: pointer; }
.chip[aria-pressed="true"] { border-radius: 3px 14px; background: var(--noise), var(--accent); background-blend-mode: soft-light, normal; color: var(--on-accent); border-color: transparent; }
.chips + .chips { margin-top: -6px; }
a.chip { display: inline-flex; align-items: center; text-decoration: none; }  /* ссылки-магазины: строчный <a> не держал высоту, рамка липла к тексту */
.chip:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.prods { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.prods > :not(.prod) { grid-column: 1 / -1; }  /* пустые состояния и блок магазинов — во всю ширину, не в одну колонку */
.prods > h3 { margin-bottom: 10px; }
.prods--row { display: flex; overflow-x: auto; gap: 12px; padding-bottom: 8px; }
.prods--row .prod { flex: none; width: 168px; }
.prod { display: flex; flex-direction: column; gap: 6px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: 8px; min-width: 0; }
/* фото магазинов 3:4 и 2:3 — рамка 3:4 и cover, у 2:3 срезается по ~5 % фона сверху и снизу */
.prod__img { position: relative; aspect-ratio: 3 / 4; background: #ece9e2; border-radius: 3px; overflow: hidden; }
.prod__img img { width: 100%; height: 100%; object-fit: cover; }
.prod > .prod__img:first-child { margin: -8px -8px 0; border-radius: 2px 2px 0 0; }
.prod__tag { position: absolute; left: 6px; top: 6px; padding: 4px 8px; border-radius: 2px; background: var(--noise), var(--accent); background-blend-mode: soft-light, normal; color: var(--on-accent); font: 700 11px var(--text); }
.prod__name { font: 600 14px/1.25 var(--text); overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.prod__why { font-size: 12px; line-height: 1.3; color: var(--muted); overflow-wrap: anywhere; }
.prod__price { font-weight: 700; }
.prod__price s { margin-left: 8px; font-weight: 400; font-size: 12px; color: var(--muted); }
.prod__mark { font-size: 11px; line-height: 1.3; color: var(--muted); overflow-wrap: anywhere; }
.prod__row { display: grid; gap: 4px; margin-top: auto; }
.panel { position: fixed; left: 0; right: 0; bottom: calc(var(--tabbar) + env(safe-area-inset-bottom)); z-index: 5; max-height: 70%; overflow-y: auto;
  padding: 12px var(--gut); background: var(--glass); border-top: 1px solid var(--line); border-radius: 3px; animation: rise .3s var(--ease) both; }
.panel__head { display: flex; align-items: center; justify-content: space-between; font: 700 16px var(--head); margin-bottom: 8px; }
.panel__head .btn { width: auto; }

/* ---------- шторка жалобы ---------- */
.sheet { width: min(100% - 24px, 520px); margin: auto auto calc(12px + env(safe-area-inset-bottom)); padding: 20px; background: var(--glass); color: var(--ink); border: 1px solid var(--line); border-radius: 3px 28px; }
.sheet::backdrop { background: var(--scrim); }
.opt { display: flex; align-items: center; gap: 12px; min-height: var(--hit); }
.opt input { accent-color: var(--accent); width: 20px; height: 20px; }
.sheet .btn { margin-top: 10px; }

/* ---------- вкладки, тост ---------- */
.tabs {
  position: fixed; inset: auto 0 0 0; display: flex; background: var(--glass); border-top: 1px solid var(--line);
  padding: 0 env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}
.tab { flex: 1; min-width: 0; min-height: var(--tabbar); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  font-size: 11px; font-weight: 600; text-decoration: none; color: var(--muted); }
.tab { position: relative; }
.tab .ic { color: var(--tab-ic); }
.tab[aria-current="page"] { color: var(--accent-ink); }
.tab[aria-current="page"] { color: var(--ink); }
.tab[aria-current="page"]::before { content: ""; position: absolute; top: 0; left: 28%; right: 28%; height: 3px; border-radius: 0; background: var(--accent); }
.ic { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.toast { position: fixed; left: 50%; bottom: calc(var(--tabbar) + 16px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  max-width: calc(100% - 32px); padding: 12px 18px; border-radius: 3px; background: var(--ink); color: var(--bg); font-weight: 600; font-size: 14px; animation: rise .3s var(--ease) both; }

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: none; } }
@keyframes scan { 0% { transform: translateY(-100%); opacity: 0; } 12%, 88% { opacity: 1; } 100% { transform: none; opacity: 0; } }

/* сохранённое, доска, образы из товаров, вырезы */
.prod__save { position: absolute; right: 2px; top: 2px; width: var(--hit); height: var(--hit); display: grid; place-items: center; border: 0; background: none; color: #1c1416; filter: drop-shadow(0 0 2px rgb(255 255 255 / .85)); cursor: pointer; }  /* без подложки: фото товаров светлые, тёмный контур + светлый ореол читаются на любом */
.prod__save .ic, .item__save .ic { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.prod__save[aria-pressed="true"], .item__save[aria-pressed="true"] { color: var(--accent-ink); }
.prod__save[aria-pressed="true"] .ic, .item__save[aria-pressed="true"] .ic { fill: currentColor; }
.prod__save[aria-pressed="true"] { color: #9a1f3a; }
.prod__row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.prod__row2 .btn { padding-inline: 2px; font-size: 14px; white-space: nowrap; }
.prod__row2 [aria-pressed="true"] { color: var(--accent-ink); }
.prod__flag { font: 700 12px var(--text); color: var(--muted); }
.prod__flag--down { color: var(--accent-ink); }
.prod--gone .prod__img { opacity: .55; }
.board { position: sticky; top: 0; z-index: 3; background: var(--glass); border: 1px solid var(--line); border-radius: var(--r); padding: 10px 12px; margin-bottom: 16px; }
.board__items { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
.board__it { flex: none; width: 44px; height: 44px; padding: 2px; border-radius: 3px; border: 1px solid var(--line); background: #ece9e2; cursor: pointer; }
.board__it img { width: 100%; height: 100%; object-fit: contain; }
.board__row { display: flex; gap: 8px; }
.board__row .btn { flex: 1; min-height: 40px; padding: 8px 12px; font-size: 14px; }
.board__sum { margin-left: auto; font-size: 14px; white-space: nowrap; }
.board__row .btn:disabled { opacity: .5; }
.cuts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px; background: var(--bg-3); border-radius: 3px; overflow: hidden; }
.cut { position: relative; padding: 6px; border: 0; background: #ece9e2; aspect-ratio: 1; cursor: pointer; }
.cut img { width: 100%; height: 100%; object-fit: contain; }
.cut__ad { position: absolute; left: 3px; bottom: 3px; padding: 1px 5px; border-radius: 3px; background: rgba(0,0,0,.7); color: #fff; font: 600 10px var(--text); }
.cuts--post { border-radius: 0; }
.cuts--one { grid-template-columns: 1fr; max-width: 120px; }
.cuts--alt { margin-bottom: 8px; }
.cut:focus-visible, .board__it:focus-visible, .prod__save:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.looklist { display: grid; gap: 14px; margin-bottom: 16px; }
.looklist > h3 { margin-top: 4px; }
.lookcard { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-leaf); padding: 10px; display: grid; gap: 8px; }
.lookcard__t { font: 600 18px var(--head); }
.lookcard__row { display: flex; gap: 8px; }
.lookcard__row .btn { width: auto; flex: 1; }
.item__img { max-width: 240px; margin: 0 auto 8px; }
.item__row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 8px 0 12px; }
.item__save { display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.prod__row2 .btn, .item__row .btn, .board__row .btn, .lookcard__row .btn { margin: 0; }
@media (prefers-reduced-motion: no-preference) { .board:not([hidden]) { animation: rise .25s var(--ease) both; } }

@media (prefers-reduced-motion: reduce) {
  *, ::before, ::after { animation: none !important; transition: none !important; }
  .reveal .r { opacity: 1; transform: none; }
}

/* ---------- лук-борд ---------- */
.lookboard__sheet { position: relative; display: grid; grid-template-columns: 57fr 39fr; justify-content: space-between; aspect-ratio: 5 / 7; padding: 4% 4% 7%; background: #fff; border-radius: 3px; isolation: isolate; }
.lookboard__sheet--solo { grid-template-columns: 62%; justify-content: center; }
.lookboard__col { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.lookboard__col--L { justify-content: center; }
.lookboard__col--R { justify-content: space-between; }
.lookboard__it { flex: var(--h) 1 0; max-height: calc(var(--h) * 1.8%); min-height: 0; display: flex; flex-direction: column; align-items: center; padding: 0; border: 0; background: none; cursor: pointer; }
.lookboard__it img { flex: 1; min-height: 0; width: 100%; object-fit: contain; mix-blend-mode: multiply; filter: brightness(1.08) contrast(1.12); } /* светлый фон кадра уходит в белый лист */
.lookboard__it:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.lookboard__price { flex: none; margin-top: 2px; color: #6b6466; font: 500 10px/1.2 var(--text); text-align: center; }
.lookboard__price s { margin-left: 4px; opacity: .6; }
.lookboard__ad { position: absolute; left: 4%; bottom: 2.2%; color: #8a8386; font: 500 10px/1 var(--text); }
.lookboard__pal { display: flex; height: 4px; margin-top: 4px; border-radius: 3px; overflow: hidden; }
.lookboard__pal i { flex: 1; }
.looksum { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 2px 0; }
.looksum p { margin: 0; }
.looksum__total { font: 600 26px var(--head); }
.looksum__n { font-size: 12px; color: var(--muted); }
.looksum__ct { display: inline-flex; align-items: center; gap: 7px; min-width: 0; padding: 6px 12px; border-radius: 3px; border: 1px solid var(--line); font: 600 13px var(--text); white-space: nowrap; }
.looksum__ct i { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--ct); }

/* ---------- дизайнерские детали ---------- */
/* 1. номера разделов */
.screen[data-screen="color"] .step[data-when="welcome"] .kicker::after { content: "  № 01"; color: var(--muted); }
.screen[data-screen="picks"] > .kicker::before { content: "№ 02 · "; }
.screen[data-screen="try"] > .kicker::before { content: "№ 03 · "; }
.screen[data-screen="feed"] > .kicker::before { content: "№ 04 · "; }
.screen[data-screen="profile"] > .kicker::before { content: "№ 05 · "; }
/* 2. линия под заголовком экрана */
.screen > .display { padding-bottom: 14px; border-bottom: 1px solid var(--line); }
/* 3. рукописный акцент, по одному на экран */
.step[data-when="welcome"] .display::after, #h-picks::after {
  display: block; margin-top: 6px; font: 400 30px/1.1 var(--hand); text-transform: none; letter-spacing: 0; color: var(--accent-ink); transform: rotate(-3deg); transform-origin: left; }
.step[data-when="welcome"] .display::after { content: "твой цвет"; }
#h-picks::after { content: "для тебя"; }
/* 4. метки обреза у карточек товара */
.prod { position: relative; }
.prod::before, .prod::after { content: ""; position: absolute; width: 9px; height: 9px; pointer-events: none; border: 0 solid var(--accent-ink); }
.prod::before { left: -4px; top: -4px; border-width: 1px 0 0 1px; }
.prod::after { right: -4px; bottom: -4px; border-width: 0 1px 1px 0; }
.prods--row .prod::before, .prods--row .prod::after { display: none; }

/* ---------- «Крой и рука»: острое = структура, текучее = человек и выбор (2–4 на экран) ---------- */
/* рукописные пометки: волнистая линия от руки под текстом, статично */
.step[data-when="welcome"] .display::after, #h-picks::after {
  width: fit-content; padding-bottom: 9px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'%3E%3Cpath d='M1 5 C9 1 15 1 22 4 S36 7 45 3 S60 1 68 4 S86 7 99 2' fill='none' stroke='%23ec7690' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") left bottom / 100% 7px no-repeat; }
/* единственный стежок: профиль, вместо прямой линейки под заголовком */
.screen[data-screen="profile"] > .display { border-bottom: 0; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 8' preserveAspectRatio='none'%3E%3Cpath d='M0 4 Q5 0 10 4 T20 4 T30 4 T40 4 T50 4 T60 4 T70 4 T80 4 T90 4 T100 4 T110 4 T120 4' fill='none' stroke='%2343363b' stroke-width='1.4'/%3E%3C/svg%3E") left bottom / 100% 8px no-repeat; }
/* капля туши: медленная, размытая, за текстом; только результат цветотипа и welcome */
.reveal, .step[data-when="welcome"] { position: relative; isolation: isolate; }
.reveal::before, .step[data-when="welcome"]::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none; width: 62%; aspect-ratio: 1; right: 2%; top: -6%;
  background: var(--ct); filter: blur(26px); opacity: .34; border-radius: 42% 58% 63% 37% / 41% 44% 56% 59%;
  animation: ink 22s ease-in-out infinite alternate; }
.step[data-when="welcome"]::before { background: var(--accent); width: 56%; right: 2%; top: 4%; opacity: .3; animation-duration: 19s; }
@keyframes ink {
  0% { border-radius: 42% 58% 63% 37% / 41% 44% 56% 59%; transform: translate(0, 0) rotate(0); }
  50% { border-radius: 58% 42% 38% 62% / 55% 36% 64% 45%; transform: translate(-6%, 8%) rotate(40deg); }
  100% { border-radius: 36% 64% 55% 45% / 62% 53% 47% 38%; transform: translate(3%, -4%) rotate(-25deg); } }
@media (prefers-reduced-motion: reduce) {
  .reveal::before, .step[data-when="welcome"]::before { animation: none !important; }
  .chip, .btn--accent { transition: none !important; }
}
.screen[data-screen="color"] { overflow-x: clip; }
