/* ==========================================================================
   Фотомагазин — яркая детская тема. Три палитры: sunny (по умолчанию),
   candy и night. Выбирается в админке, применяется через <html data-theme>.
   ========================================================================== */

:root,
[data-theme="sunny"] {
  --bg: #fff7e3;
  --bg-2: #ffefc4;
  --surface: #ffffff;
  --ink: #2b2a5c;
  --muted: #5f5c88;
  --line: rgba(43, 42, 92, .14);
  --accent: #ffc93c;
  --accent-ink: #2b2a5c;
  --pop: #ff6b5e;
  --pop-ink: #c7352a;
  --c1: #ffc93c;
  --c2: #4cc9f0;
  --c3: #3ddb9a;
  --c4: #9b7bff;
  --c5: #ff8dbb;
  --c6: #ff6b5e;
  --btn-shadow: rgba(43, 42, 92, .9);
  --soft-shadow: rgba(43, 42, 92, .16);
  --blob-a: #ffd84d;
  --blob-b: #ff9d8f;
  --blob-c: #7fdcff;
  color-scheme: light;
}
[data-theme="candy"] {
  --bg: #fff1f8;
  --bg-2: #ffdff0;
  --ink: #3b1f63;
  --muted: #6e5496;
  --line: rgba(59, 31, 99, .15);
  --accent: #ff86c2;
  --accent-ink: #3b1f63;
  --pop: #b24cf0;
  --pop-ink: #8a2fc4;
  --c1: #ffd84d;
  --c2: #5ad1f5;
  --c3: #4adea5;
  --c4: #a98bff;
  --c5: #ff86c2;
  --c6: #ff7a7a;
  --btn-shadow: rgba(59, 31, 99, .9);
  --soft-shadow: rgba(59, 31, 99, .16);
  --blob-a: #ffb0dc;
  --blob-b: #cfb4ff;
  --blob-c: #ffe58a;
}
[data-theme="night"] {
  --bg: #17143d;
  --bg-2: #201c55;
  --surface: #292570;
  --ink: #fff4e0;
  --muted: #bdb8ea;
  --line: rgba(255, 244, 224, .18);
  --accent: #ffc93c;
  --accent-ink: #1d1a45;
  --pop: #ff8e7f;
  --pop-ink: #ff9e90;
  --btn-shadow: rgba(0, 0, 0, .55);
  --soft-shadow: rgba(0, 0, 0, .35);
  --blob-a: #5b43d6;
  --blob-b: #d94a8c;
  --blob-c: #2a8fd8;
  color-scheme: dark;
}
:root {
  --on-color: #2b2a5c; /* текст на цветных карточках одинаков во всех темах */
  --radius: 22px;
  --gap: 18px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --sans: "Nunito", ui-rounded, "SF Pro Rounded", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; }
html.lb-open { overflow: hidden; }

body {
  margin: 0;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font: 500 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
main { flex: 1; }
[hidden] { display: none !important; }
a { color: inherit; }
img { display: block; max-width: 100%; }
h1, h2, h3 { font-weight: 900; letter-spacing: -.02em; line-height: 1.05; margin: 0; }

/* ---- Шапка и подвал ---------------------------------------------------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  padding: 12px clamp(18px, 4vw, 48px);
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 2px solid var(--line);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 900;
  font-size: 1.1rem;
  letter-spacing: -.01em;
  text-decoration: none;
}
.brand svg { width: 34px; height: 34px; flex: none; transition: transform .5s var(--ease); }
.brand:hover svg { transform: rotate(-12deg) scale(1.08); }

.foot {
  padding: 30px clamp(18px, 4vw, 48px);
  color: var(--muted);
  font-size: .9rem;
  font-weight: 600;
  text-align: center;
  border-top: 2px solid var(--line);
}

/* ---- Общие элементы ---------------------------------------------------- */
.eyebrow {
  margin: 0 0 12px;
  font-size: .8rem;
  font-weight: 900;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--pop-ink);
}
.lead {
  margin: 0;
  max-width: 56ch;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.7vw, 1.25rem);
  font-weight: 600;
}
.hl, mark.hl {
  color: inherit;
  background: linear-gradient(transparent 58%, var(--c1) 58% 94%, transparent 94%);
  border-radius: 6px;
  padding: 0 .12em;
  margin: 0 -.12em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
[data-theme="candy"] .hl { background-image: linear-gradient(transparent 58%, var(--c5) 58% 94%, transparent 94%); }
[data-theme="night"] .hl { background-image: linear-gradient(transparent 58%, rgba(255, 201, 60, .55) 58% 94%, transparent 94%); }

/* ---- Кнопки ------------------------------------------------------------ */
.buy {
  appearance: none;
  display: inline-block;
  padding: 8px 18px;
  border: 2px solid var(--btn-shadow);
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font: inherit;
  font-size: .9rem;
  font-weight: 900;
  line-height: 1.4;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 3px 0 var(--btn-shadow);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.buy:hover { transform: translateY(-2px); box-shadow: 0 5px 0 var(--btn-shadow); }
.buy:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--btn-shadow); }
.buy:focus-visible, .link-btn:focus-visible, .cart-link:focus-visible, .brand:focus-visible,
.card__btn:focus-visible { outline: 3px solid var(--c4); outline-offset: 3px; }
.buy--in { background: var(--surface); color: var(--ink); }
.buy--big { padding: 13px 30px; font-size: 1.05rem; }
.buy--lb { margin-left: 2px; }

.cart-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  padding: 7px 15px;
  border: 2px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-size: .92rem;
  font-weight: 800;
  text-decoration: none;
  transition: border-color .2s, transform .2s var(--ease);
}
.cart-link:hover { border-color: var(--ink); transform: translateY(-1px); }
.cart-link__count {
  min-width: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--pop);
  color: #fff;
  font-size: .78rem;
  line-height: 22px;
  text-align: center;
}

/* ==========================================================================
   Главная
   ========================================================================== */
.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  align-items: center;
  gap: clamp(20px, 4vw, 64px);
  width: min(1416px, 100%);
  margin-inline: auto;
  padding: clamp(36px, 7vw, 92px) clamp(18px, 4vw, 48px) clamp(56px, 8vw, 110px);
}
.hero__bg { position: absolute; inset: -40px -20vw; z-index: -1; pointer-events: none; overflow: hidden; }
.blob { position: absolute; border-radius: 50%; filter: blur(50px); opacity: .55; }
.blob--1 { width: 440px; height: 440px; left: 8%; top: -8%; background: var(--blob-a); animation: drift 16s ease-in-out infinite alternate; }
.blob--2 { width: 380px; height: 380px; right: 10%; top: 18%; background: var(--blob-b); animation: drift 19s ease-in-out infinite alternate-reverse; }
.blob--3 { width: 320px; height: 320px; left: 36%; bottom: -14%; background: var(--blob-c); animation: drift 22s ease-in-out infinite alternate; }

.deco { position: absolute; width: 48px; height: 48px; fill: currentColor; pointer-events: none; }
.deco--cloud1 { width: 120px; height: 68px; left: 6%; top: 16%; color: var(--surface); opacity: .9; animation: sway 9s ease-in-out infinite alternate; }
.deco--cloud2 { width: 90px; height: 52px; right: 14%; bottom: 20%; color: var(--surface); opacity: .8; animation: sway 12s ease-in-out infinite alternate-reverse; }

.hero__copy { position: relative; animation: rise .8s var(--ease) both; }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 20px;
  padding: 7px 16px 7px 12px;
  border: 2px solid var(--btn-shadow);
  border-radius: 999px;
  background: var(--c5);
  color: var(--on-color);
  font-size: .9rem;
  font-weight: 900;
  box-shadow: 0 3px 0 var(--btn-shadow);
  transform: rotate(-2deg);
}
.badge svg { width: 18px; height: 18px; fill: var(--on-color); }
.hero h1 { font-size: clamp(2.7rem, 7.4vw, 5.8rem); margin-bottom: 22px; text-wrap: balance; }
.perks { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin: 28px 0 0; padding: 0; }
.perks li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--surface);
  border: 2px solid var(--line);
  font-size: .88rem;
  font-weight: 800;
}
.perks svg { width: 16px; height: 16px; flex: none; }
.perks li:nth-child(1) svg { fill: var(--c6); }
.perks li:nth-child(2) svg { fill: var(--c1); stroke: var(--ink); stroke-width: 1; }
.perks li:nth-child(3) svg { fill: var(--c4); }

/* Стопка из трёх фото справа */
.stack { position: relative; width: 100%; aspect-ratio: 1 / 1.04; max-width: 620px; justify-self: center; }
.stack .stack__item { position: absolute; margin: 0; }
.stack__item--1 { left: 2%; top: 4%; width: 54%; z-index: 2; --tilt: -4deg; animation: float 7s ease-in-out infinite; }
.stack__item--2 { right: 0; top: 0; width: 41%; z-index: 3; --tilt: 6deg; animation: float 8s ease-in-out -2s infinite; }
.stack__item--3 { right: 6%; bottom: 2%; width: 40%; z-index: 4; --tilt: -3deg; animation: float 6.5s ease-in-out -4s infinite; }
.stack .deco--star1 { left: -2%; bottom: 14%; width: 54px; height: 54px; color: var(--c1); z-index: 5; animation: twinkle 3s ease-in-out infinite; }
.stack .deco--spark1 { right: 44%; top: -4%; width: 40px; height: 40px; color: var(--c4); z-index: 5; animation: twinkle 3.6s ease-in-out -1s infinite; }
.stack .deco--heart1 { left: 48%; bottom: 0; width: 44px; height: 44px; color: var(--c6); z-index: 5; animation: twinkle 4s ease-in-out -2s infinite; }
.sun { position: absolute; z-index: 0; right: 14%; top: 22%; width: 34%; aspect-ratio: 1; display: grid; place-items: center; }
.sun i {
  width: 70%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--c1);
  box-shadow: 0 0 0 14px color-mix(in srgb, var(--c1) 35%, transparent), 0 0 0 30px color-mix(in srgb, var(--c1) 18%, transparent);
}

/* Рамки для фото — «наклейки» разных форм */
.frame {
  --c: var(--c2);
  --tilt: 0deg;
  position: relative;
  margin: 0;
  overflow: visible;
  border: 6px solid #fff;
  background: #fff;
  box-shadow: 8px 8px 0 var(--c), 0 18px 30px -14px var(--soft-shadow);
  transform: rotate(var(--tilt));
  transition: transform .5s var(--ease), box-shadow .5s var(--ease);
}
.frame > img, .frame > svg:first-child {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}
.frame--arch { aspect-ratio: 4 / 5; border-radius: 999px 999px 26px 26px; }
.frame--circle { aspect-ratio: 1; border-radius: 50%; }
.frame--blob { aspect-ratio: 1; border-radius: 63% 37% 54% 46% / 55% 48% 52% 45%; }
.frame--round { aspect-ratio: 4 / 3; border-radius: 30px; }
.frame--polaroid { aspect-ratio: 1 / 1.16; border-radius: 10px; padding: 8px 8px 0; border-width: 0; }
.frame--polaroid > img, .frame--polaroid > svg:first-child { height: calc(100% - 38px); border-radius: 4px; }
.frame--art > svg { display: block; }
.frame--art.frame--arch > svg { border-radius: 999px 999px 20px 20px; }
.frame--art.frame--circle > svg { border-radius: 50%; }

.stack__item--1.frame { --c: var(--c2); }
.stack__item--2.frame { --c: var(--c5); }
.stack__item--3.frame { --c: var(--c3); }

.sticker {
  position: absolute;
  left: 50%;
  bottom: -14px;
  max-width: 92%;
  padding: 5px 14px;
  border: 2px solid var(--btn-shadow);
  border-radius: 999px;
  background: var(--c1);
  color: var(--on-color);
  font-size: .82rem;
  font-weight: 900;
  line-height: 1.3;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transform: translateX(-50%) rotate(-3deg);
  box-shadow: 0 3px 0 var(--btn-shadow);
}
.frame--polaroid .sticker {
  position: absolute;
  bottom: 6px;
  left: 8px;
  right: 8px;
  max-width: none;
  transform: none;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: #2b2a5c;
  font-size: .9rem;
}

/* Бегущая строка */
.ribbon {
  position: relative;
  z-index: 2;
  margin: -26px -2vw 0;
  padding: 14px 0;
  background: var(--ink);
  color: var(--bg);
  transform: rotate(-1.4deg);
  overflow: hidden;
  box-shadow: 0 10px 30px -14px var(--soft-shadow);
}
.ribbon__track { display: flex; width: max-content; animation: marquee 32s linear infinite; }
.ribbon__row { display: inline-flex; align-items: center; gap: 22px; padding-right: 22px; }
.ribbon b { font-size: 1.35rem; font-weight: 900; letter-spacing: .01em; white-space: nowrap; }
.ribbon svg { width: 22px; height: 22px; flex: none; fill: var(--c1); }
.ribbon__row svg:nth-of-type(3n+2) { fill: var(--c5); }
.ribbon__row svg:nth-of-type(3n) { fill: var(--c2); }

/* Подборка ярких моментов */
.moments { background: var(--bg-2); margin-top: -26px; padding: clamp(80px, 9vw, 120px) clamp(18px, 4vw, 48px) clamp(64px, 8vw, 110px); }
.section-head { width: min(1320px, 100%); margin: 0 auto clamp(30px, 5vw, 56px); }
.section-head h2 { font-size: clamp(2.2rem, 5.6vw, 4rem); margin-bottom: 14px; text-wrap: balance; }
.mosaic {
  --mpad: clamp(18px, 4vw, 48px);
  --mgap: clamp(16px, 2.4vw, 32px);
  --cols: 4;
  /* ширина столбца: клетки сетки получаются квадратными, поэтому круги и арки не растягиваются */
  --cell: calc((min(1320px, 100vw - 2 * var(--mpad)) - (var(--cols) - 1) * var(--mgap)) / var(--cols));
  width: min(1320px, 100%);
  margin-inline: auto;
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  grid-auto-rows: var(--cell);
  grid-auto-flow: dense;
  gap: var(--mgap);
  padding-bottom: 14px;
}
.mosaic .frame { aspect-ratio: auto; width: 100%; height: 100%; }
.tile.frame--circle, .tile.frame--blob { grid-column: span 2; grid-row: span 2; }
.mosaic .tile.frame--circle, .mosaic .tile.frame--blob { width: auto; height: 100%; aspect-ratio: 1; justify-self: center; }
.tile.frame--round { grid-column: span 2; }
.tile:nth-child(6n+1) { --c: var(--c2); --tilt: -1.6deg; }
.tile:nth-child(6n+2) { --c: var(--c5); --tilt: 1.4deg; }
.tile:nth-child(6n+3) { --c: var(--c3); --tilt: -1deg; }
.tile:nth-child(6n+4) { --c: var(--c1); --tilt: 1.8deg; }
.tile:nth-child(6n+5) { --c: var(--c4); --tilt: -1.8deg; }
.tile:nth-child(6n) { --c: var(--c6); --tilt: 1deg; }
.tile.frame--circle, .tile.frame--blob { --tilt: 0deg; }
.tile:hover { --tilt: 0deg; transform: scale(1.03); z-index: 3; box-shadow: 12px 12px 0 var(--c), 0 26px 40px -16px var(--soft-shadow); }
.tile .sticker { transition: transform .4s var(--ease); }
.tile:hover .sticker { transform: translateX(-50%) rotate(2deg) scale(1.06); }
.tile.frame--polaroid:hover .sticker { transform: none; }

/* Шаги */
.steps { padding: clamp(70px, 9vw, 120px) clamp(18px, 4vw, 48px) clamp(50px, 6vw, 80px); }
.steps__list {
  list-style: none;
  width: min(1320px, 100%);
  margin: 0 auto;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2.4vw, 30px);
}
.step {
  position: relative;
  padding: 30px 28px 32px;
  border: 3px solid var(--btn-shadow);
  border-radius: 28px;
  color: var(--on-color);
  box-shadow: 0 6px 0 var(--btn-shadow);
  transition: transform .35s var(--ease);
}
.step:hover { transform: translateY(-6px) rotate(-.6deg); }
.step--1 { background: var(--c1); }
.step--2 { background: var(--c2); }
.step--3 { background: var(--c5); }
.step__num {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  margin-bottom: 18px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid #2b2a5c;
  font-size: 1.6rem;
  font-weight: 900;
}
.step h3 { font-size: 1.55rem; margin-bottom: 10px; }
.step p { margin: 0; font-weight: 700; }

/* Контакты */
.cta {
  position: relative;
  overflow: hidden;
  width: min(1320px, calc(100% - 2 * clamp(18px, 4vw, 48px)));
  margin: clamp(20px, 4vw, 40px) auto clamp(60px, 8vw, 100px);
  padding: clamp(40px, 6vw, 76px) clamp(24px, 5vw, 70px);
  border: 3px solid var(--btn-shadow);
  border-radius: 36px;
  background: linear-gradient(120deg, var(--c4), var(--c5));
  color: var(--on-color);
  text-align: center;
  box-shadow: 0 8px 0 var(--btn-shadow);
}
.cta h2 { font-size: clamp(2rem, 5vw, 3.6rem); margin-bottom: 14px; }
.cta p { max-width: 52ch; margin: 0 auto; font-size: 1.15rem; font-weight: 800; }
.cta .deco--spark2 { left: 6%; top: 18%; width: 46px; height: 46px; color: #fff; animation: twinkle 3s ease-in-out infinite; }
.cta .deco--heart2 { right: 7%; bottom: 16%; width: 54px; height: 54px; color: #fff; animation: twinkle 4s ease-in-out -1s infinite; }

/* Появление при прокрутке (только если включён JS) */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: calc(min(var(--i, 0), 8) * 70ms); }
.js .reveal.is-in { opacity: 1; transform: none; }
.js .tile.reveal { transform: translateY(26px) rotate(var(--tilt)); }
.js .tile.reveal.is-in { transform: rotate(var(--tilt)); }
.js .tile.reveal.is-in:hover { transform: scale(1.03); }
.js .step.reveal.is-in:hover { transform: translateY(-6px) rotate(-.6deg); }

/* Страница 404 */
.lost { display: grid; justify-items: center; gap: 18px; padding: clamp(60px, 12vw, 140px) 20px; text-align: center; }
.lost h1 { font-size: clamp(2.2rem, 6vw, 4rem); }
.lost__code { margin: 0; font-size: clamp(5rem, 22vw, 11rem); font-weight: 900; line-height: .9; color: var(--c4); text-shadow: 6px 6px 0 var(--c1); }

/* ==========================================================================
   Страницы галереи, корзины и заказа
   ========================================================================== */
.page {
  width: min(1520px, 100%);
  margin-inline: auto;
  padding: clamp(32px, 6vw, 76px) clamp(16px, 4vw, 48px) 90px;
}
.page--narrow { width: min(820px, 100%); }
.page-head { max-width: 880px; margin-bottom: clamp(26px, 4vw, 52px); animation: rise .7s var(--ease) both; }
.page-head h1 { margin: 0 0 14px; font-size: clamp(2.4rem, 6vw, 4.4rem); text-wrap: balance; }
.meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: .98rem;
  font-weight: 700;
}
.meta strong { color: var(--ink); font-weight: 900; }
.meta .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--pop); }

.grid { list-style: none; margin: 0; padding: 0; column-width: 290px; column-gap: var(--gap); }
.card { position: relative; break-inside: avoid; margin: 0 0 var(--gap); animation: rise .7s var(--ease) both; animation-delay: calc(min(var(--i, 0), 14) * 45ms); }
.card__btn {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 5px solid #fff;
  border-radius: var(--radius);
  overflow: hidden;
  isolation: isolate;
  background: var(--surface);
  color: inherit;
  font: inherit;
  cursor: zoom-in;
  box-shadow: 0 0 0 2px var(--line), 0 14px 26px -14px var(--soft-shadow);
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.card__btn img { width: 100%; height: auto; background: var(--surface); transition: transform .8s var(--ease); }
.card__shade { position: absolute; inset: 0; background: linear-gradient(to top, rgba(20, 16, 60, .5), transparent 46%); opacity: .55; transition: opacity .4s; pointer-events: none; }
.card__price, .card__zoom {
  position: absolute;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, .92);
  color: #2b2a5c;
  border: 2px solid #2b2a5c;
}
.card__price { left: 10px; bottom: 10px; padding: 4px 12px; border-radius: 999px; font-size: .84rem; font-weight: 900; white-space: nowrap; }
.card__zoom { top: 10px; right: 10px; width: 38px; height: 38px; border-radius: 50%; opacity: 0; transform: scale(.85); transition: opacity .3s, transform .4s var(--ease); }
@media (hover: hover) {
  .card__btn:hover { transform: translateY(-5px) rotate(-.5deg); box-shadow: 0 0 0 2px var(--ink), 0 24px 36px -16px var(--soft-shadow); }
  .card__btn:hover img { transform: scale(1.05); }
  .card__btn:hover .card__shade { opacity: 1; }
}
.card__btn:hover .card__zoom, .card__btn:focus-visible .card__zoom { opacity: 1; transform: none; }
.card__buy { position: absolute; right: 10px; bottom: 10px; margin: 0; }
.card__buy.buy { padding: 5px 13px; font-size: .8rem; }

.empty { padding: 70px 20px; text-align: center; color: var(--muted); font-weight: 700; border: 3px dashed var(--line); border-radius: var(--radius); background: var(--surface); }

/* ---- Просмотр фото (lightbox) — всегда тёмный ------------------------- */
.lb {
  --ink: #fff4e0;
  --muted: #cfcaf5;
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  color: var(--ink);
  background: rgba(20, 16, 56, .92);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  overflow: hidden;
}
.lb[open] { display: grid; place-items: center; animation: fade .25s ease both; }
.lb::backdrop { background: rgba(0, 0, 0, .5); }
.lb__bar { position: absolute; inset: 0 0 auto 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; pointer-events: none; }
.lb__bar > * { pointer-events: auto; }
.lb__count { font-size: .92rem; font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; }
.lb__btn, .lb__nav {
  display: grid;
  place-items: center;
  border: 2px solid rgba(255, 255, 255, .28);
  border-radius: 50%;
  background: rgba(255, 255, 255, .12);
  color: #fff4e0;
  cursor: pointer;
  transition: background .25s, transform .25s var(--ease);
}
.lb__btn { width: 44px; height: 44px; }
.lb__nav { position: absolute; top: 50%; z-index: 2; width: 54px; height: 54px; margin-top: -27px; }
.lb__nav--prev { left: 18px; }
.lb__nav--next { right: 18px; }
.lb__btn:hover, .lb__nav:hover { background: rgba(255, 255, 255, .26); }
.lb__nav:active, .lb__btn:active { transform: scale(.94); }
.lb__btn:focus-visible, .lb__nav:focus-visible { outline: 3px solid var(--c1); outline-offset: 2px; }
.lb__stage { margin: 0; width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 68px 92px 28px; }
.lb__img {
  max-width: 100%;
  max-height: calc(100dvh - 68px - 28px - 64px);
  width: auto;
  height: auto;
  object-fit: contain;
  border: 5px solid #fff;
  border-radius: 20px;
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .9);
  transition: opacity .25s ease, transform .35s var(--ease);
}
.lb__img.is-loading { opacity: 0; transform: scale(.985); }
.lb__caption { display: flex; align-items: center; gap: 12px; padding: 8px 8px 8px 18px; border: 2px solid rgba(255, 255, 255, .22); border-radius: 999px; background: rgba(255, 255, 255, .1); font-size: .92rem; color: var(--muted); }
.lb__price { padding: 5px 14px; border-radius: 999px; background: #fff; color: #2b2a5c; font-weight: 900; white-space: nowrap; }
.lb__caption > span:only-child { margin-left: -10px; }
.lb .buy { --btn-shadow: rgba(0, 0, 0, .5); --accent: #ffc93c; --accent-ink: #2b2a5c; }
.lb .buy--in { background: #fff; color: #2b2a5c; }

/* ---- Корзина и заказ --------------------------------------------------- */
.cart-list { list-style: none; margin: 0 0 32px; padding: 0; display: grid; gap: 14px; }
.cart-row {
  display: grid;
  grid-template-columns: 90px 1fr auto auto;
  align-items: center;
  gap: 16px;
  padding: 12px;
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.cart-row img { width: 90px; height: 68px; object-fit: cover; border-radius: 14px; }
.cart-row__info { display: grid; min-width: 0; }
.cart-row__info strong { font-weight: 900; }
.cart-row__info span { color: var(--muted); font-size: .9rem; font-weight: 600; }
.cart-row__price { font-weight: 900; white-space: nowrap; }
.link-btn { appearance: none; border: 0; background: none; color: var(--muted); font: inherit; font-size: .9rem; font-weight: 700; text-decoration: underline; cursor: pointer; }
.link-btn:hover { color: var(--pop-ink); }

.checkout { display: grid; gap: 8px; max-width: 480px; padding: 26px; border: 3px solid var(--btn-shadow); border-radius: 28px; background: var(--surface); box-shadow: 0 6px 0 var(--btn-shadow); }
.checkout label { font-weight: 900; }
.checkout input[type=email],
.checkout input[type=text] { width: 100%; padding: 13px 16px; border: 2px solid var(--line); border-radius: 14px; background: var(--bg); color: var(--ink); font: inherit; font-weight: 600; }
.checkout input[type=email]:focus-visible,
.checkout input[type=text]:focus-visible { outline: 3px solid var(--c4); outline-offset: 2px; border-color: var(--ink); }
.checkout__total { display: flex; justify-content: space-between; align-items: baseline; margin: 0 0 8px; font-size: 1.1rem; font-weight: 700; color: var(--muted); }
.checkout__total strong { color: var(--ink); font-size: 1.7rem; font-weight: 900; }
.checkout__help { margin: 0; color: var(--muted); font-size: .86rem; font-weight: 600; }
.checkout .buy--big { margin-top: 10px; }

.notes { list-style: none; margin: 0 0 20px; padding: 0; }
.note { margin: 0 0 10px; padding: 11px 16px; border-radius: 14px; border: 2px solid var(--line); background: var(--surface); font-weight: 700; }
.note--error { border-color: var(--pop); color: var(--pop-ink); }

/* ---- Анимации ---------------------------------------------------------- */
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes drift { from { transform: translate3d(-5%, -4%, 0) scale(1); } to { transform: translate3d(6%, 5%, 0) scale(1.12); } }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(var(--tilt)); } 50% { transform: translateY(-12px) rotate(calc(var(--tilt) * -.5)); } }
@keyframes twinkle { 0%, 100% { transform: scale(1) rotate(0); opacity: 1; } 50% { transform: scale(.7) rotate(25deg); opacity: .7; } }
@keyframes sway { from { transform: translateX(-16px); } to { transform: translateX(16px); } }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---- Планшеты и телефоны ---------------------------------------------- */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding-bottom: 80px; }
  .stack { max-width: 460px; margin-top: 10px; }
  .steps__list { grid-template-columns: 1fr; }
  .mosaic { --cols: 2; }
}
@media (max-width: 640px) {
  :root { --gap: 12px; --radius: 16px; }
  .grid { column-count: 2; column-width: auto; }
  .cart-link span:not(.cart-link__count) { display: none; }
  .card__price { left: 7px; bottom: 7px; padding: 3px 9px; font-size: .72rem; }
  .card__zoom { display: none; }
  .card__buy { right: 7px; bottom: 7px; }
  .card__buy.buy { padding: 4px 10px; font-size: .72rem; }
  .ribbon b { font-size: 1.1rem; }
  .frame { border-width: 5px; box-shadow: 6px 6px 0 var(--c), 0 14px 24px -12px var(--soft-shadow); }
  .lb__stage { padding: 62px 12px 20px; }
  .lb__img { max-height: calc(100dvh - 62px - 20px - 64px); border-radius: 12px; }
  .lb__nav { width: 42px; height: 42px; margin-top: -21px; }
  .lb__nav--prev { left: 8px; }
  .lb__nav--next { right: 8px; }
  .cart-row { grid-template-columns: 64px 1fr; }
  .cart-row img { width: 64px; height: 52px; }
  .cart-row__price { grid-column: 2; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---- Защита витрины ----------------------------------------------------- */
/* Прозрачный слой поверх снимка: мешает выделению и перетаскиванию, но не
   перехватывает клики — карточка и светбокс остаются рабочими. */
.card__shield,
.lb__shield { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.card__shield { border-radius: inherit; }
.lb__hint { margin: 0; padding: 8px 16px; border-radius: 999px; background: rgba(186, 33, 33, .9); color: #fff; font-size: .9rem; }
.lb__stage { position: relative; }

.grid img,
.lb__img,
.cart-row img {
  -webkit-user-drag: none;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

canvas.lb__img { display: block; }

/* ---- Вход в галерею по ФИО ---------------------------------------------- */
.gate { display: grid; gap: 10px; max-width: 480px; margin: 0 auto; padding: 26px; border: 3px solid var(--btn-shadow); border-radius: 28px; background: var(--surface); box-shadow: 0 6px 0 var(--btn-shadow); }
.gate label { font-weight: 900; }
.gate input[type=text] { width: 100%; padding: 13px 16px; border: 2px solid var(--line); border-radius: 14px; background: var(--bg); color: var(--ink); font: inherit; font-weight: 600; }
.gate input[type=text]:focus-visible { outline: 3px solid var(--c4); outline-offset: 2px; border-color: var(--ink); }
.gate .buy--big { margin-top: 10px; }
.gate-user { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.gate-user form { margin: 0; }

/* ---- Набор фотографий ---------------------------------------------------- */
.note--discount { border-color: var(--c4); }
.note--ok { border-color: var(--c2); }
.set-note a { font-weight: 800; }

.set-prompt { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; background: rgba(12, 10, 30, .55); }
.set-prompt__card { max-width: 460px; padding: 26px; border-radius: 24px; background: var(--surface); box-shadow: 0 24px 60px -20px rgba(0, 0, 0, .6); }
.set-prompt__card h2 { margin-top: 0; }
.set-prompt__actions { display: flex; align-items: center; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.set-prompt__actions form { margin: 0; }

.cart-row__price s { opacity: .5; margin-right: 6px; }
.cart-row__price small { color: var(--pop); font-weight: 900; }




/* ---- Пометка для сотрудника, сообщения, дополнительные товары ---------- */
.note--staff { border-color: var(--c4); background: var(--surface); }
.note--info { border-color: var(--c4); }
.note--success { border-color: var(--c2); }
.set-who { margin: 0 0 14px; font-weight: 700; color: var(--muted); }
.set-actions__hint { color: var(--muted); font-weight: 800; font-size: .9rem; }
.set-actions button[disabled] { opacity: .5; cursor: not-allowed; box-shadow: none; transform: none; }

/* ---- «Выбрать»: три кружка при наведении (фото · магнит · календарь) ----- */
.pick { position: absolute; right: 10px; bottom: 10px; z-index: 4; display: flex; flex-direction: column; align-items: flex-end; margin: 0; }
.pick__main { position: relative; }
.pick.is-picked .pick__main:not(.buy--in)::after {
  content: "✓"; position: absolute; top: -8px; right: -8px; display: grid; place-items: center;
  width: 20px; height: 20px; border-radius: 50%; background: var(--c2, #3ec6a8); color: #fff; font-size: .72rem; font-weight: 900; line-height: 1;
  box-shadow: 0 0 0 2px #fff;
}
.pick__menu {
  position: absolute; right: 0; bottom: 100%; z-index: 5;
  display: flex; flex-direction: column; align-items: flex-end; gap: 10px;
  padding: 0 0 12px; /* «мостик» к кнопке, чтобы меню не гасло по дороге */
  pointer-events: none; opacity: 0; transform: translateY(8px) scale(.9); transform-origin: bottom right;
  transition: opacity .2s var(--ease), transform .3s var(--ease);
}
.pick:hover .pick__menu, .pick:focus-within .pick__menu, .pick.is-open .pick__menu { pointer-events: auto; opacity: 1; transform: none; }
.pick__form { margin: 0; }
.pick__opt {
  appearance: none; position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 0;
  width: 46px; height: 46px; padding: 0; border: 3px solid #fff; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink); font: inherit; text-decoration: none; cursor: pointer;
  box-shadow: 0 0 0 2px var(--btn-shadow), 0 8px 16px -6px rgba(0, 0, 0, .55);
  transition: transform .25s var(--ease), width .25s var(--ease), box-shadow .25s var(--ease);
}
.pick__opt[data-kind="magnet"] { background: var(--c2, #3ec6a8); }
.pick__opt[data-kind="calendar"] { background: var(--c4, #ffc93c); color: #2b2a5c; }
.pick__opt .kind-icon { flex: 0 0 auto; width: 22px; height: 22px; }
.pick__label { display: none; flex-direction: column; align-items: flex-start; margin-left: 8px; font-size: .78rem; font-weight: 900; line-height: 1.15; white-space: nowrap; text-align: left; }
.pick__label small { font-size: .68rem; font-weight: 800; opacity: .85; }
.pick__opt:hover, .pick__opt:focus-visible { width: auto; min-width: 62px; padding: 0 14px 0 12px; transform: scale(1.14); box-shadow: 0 0 0 2px var(--ink), 0 12px 22px -8px rgba(0, 0, 0, .6); outline: none; }
.pick__opt:hover .pick__label, .pick__opt:focus-visible .pick__label { display: flex; }
.pick__opt.is-on::after {
  content: "✓"; position: absolute; top: -7px; right: -7px; display: grid; place-items: center; width: 19px; height: 19px;
  border-radius: 50%; background: var(--ink); color: var(--bg); font-size: .68rem; font-weight: 900; line-height: 1; box-shadow: 0 0 0 2px #fff;
}
.pick__opt.is-disabled { background: var(--surface); color: var(--muted); border-color: var(--line); cursor: not-allowed; box-shadow: none; }
.pick__opt.is-busy { opacity: .6; pointer-events: none; }
@media (hover: none) {
  /* На телефоне наведения нет: меню открывает первое нажатие на «Выбрать».
     Кружки идут рядом, без подписей — иначе они не помещаются в узкую карточку. */
  .pick:hover .pick__menu { pointer-events: none; opacity: 0; transform: translateY(8px) scale(.9); }
  .pick.is-open .pick__menu { pointer-events: auto; opacity: 1; transform: none; flex-direction: row-reverse; gap: 8px; }
  .pick__opt, .pick__opt:hover, .pick__opt:focus-visible { width: 44px; height: 44px; min-width: 0; padding: 0; transform: none; }
  .pick__label { display: none !important; }
}
@media (max-width: 640px) {
  .pick { right: 7px; bottom: 7px; }
}

/* ---- Заявка: переключатель «фото / магнит / календарь» ------------------ */
.cart-row { grid-template-columns: 90px 1fr auto auto; grid-template-areas: "img info price rm" "img kinds kinds kinds"; row-gap: 10px; }
.cart-row > img { grid-area: img; align-self: start; }
.cart-row__info { grid-area: info; }
.cart-row__price { grid-area: price; text-align: right; }
.cart-row > form:last-child { grid-area: rm; }
.cart-row__kinds { grid-area: kinds; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.kind-switch { display: inline-flex; gap: 4px; padding: 4px; border: 2px solid var(--line); border-radius: 999px; background: var(--bg); }
.kind-switch form { margin: 0; }
.kind-switch__btn {
  appearance: none; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px 6px 9px; border: 0; border-radius: 999px;
  background: transparent; color: var(--muted); font: inherit; font-size: .84rem; font-weight: 800; cursor: pointer;
  transition: background .2s, color .2s, transform .2s var(--ease);
}
.kind-switch__btn .kind-icon { width: 18px; height: 18px; }
.kind-switch__btn:hover { color: var(--ink); transform: translateY(-1px); }
.kind-switch__btn:focus-visible { outline: 3px solid var(--c4); outline-offset: 2px; }
.kind-switch__btn.is-on { background: var(--ink); color: var(--bg); cursor: default; transform: none; }
.qty { display: inline-flex; align-items: center; gap: 2px; }
.qty form { margin: 0; }
.qty button { appearance: none; width: 30px; height: 30px; border: 2px solid var(--line); border-radius: 50%; background: var(--bg); color: var(--ink); font: inherit; font-weight: 900; cursor: pointer; }
.qty button:hover:not(:disabled) { border-color: var(--ink); }
.qty button:disabled { opacity: .35; cursor: not-allowed; }
.qty output { min-width: 40px; text-align: center; font-weight: 900; }
@media (max-width: 640px) {
  .cart-row { grid-template-columns: 64px 1fr; grid-template-areas: "img info" "img price" "kinds kinds" "rm rm"; }
}

/* ---- Выбор набора -------------------------------------------------------- */
.set-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.set-step { display: flex; align-items: center; gap: 10px; margin: 26px 0 12px; font-size: 1.15rem; font-weight: 900; }
.set-step span { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: var(--bg); font-size: .85rem; }

/* Три варианта — три крупные карточки с листом внутри */
.set-layouts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.set-layout {
  position: relative; display: grid; justify-items: center; align-content: start; gap: 8px; padding: 16px 12px 14px;
  border: 3px solid var(--line); border-radius: 20px; background: var(--surface); cursor: pointer; text-align: center;
  transition: transform .25s var(--ease), border-color .2s, box-shadow .25s var(--ease);
}
.set-layout:hover { transform: translateY(-3px); border-color: var(--ink); }
.set-layout input { position: absolute; opacity: 0; pointer-events: none; }
.set-layout:has(input:focus-visible) { outline: 3px solid var(--c4); outline-offset: 3px; }
.set-layout:has(input:checked) { border-color: var(--ink); box-shadow: 0 6px 0 var(--btn-shadow); background: var(--bg); }
.set-layout strong { font-weight: 900; font-size: 1rem; line-height: 1.2; }
.set-layout small { color: var(--muted); font-weight: 800; font-size: .8rem; }
.set-layout__tick { position: absolute; top: 10px; right: 10px; display: none; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--ink); color: var(--bg); font-weight: 900; line-height: 1; }
.set-layout:has(input:checked) .set-layout__tick { display: grid; }

/* Лист А4 с местами под фото: общий вид для карточек вариантов и для «Выбрано» */
.set-sheet { display: grid; gap: 6px; padding: 8px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.set-sheet > i { display: block; border: 2px dashed #b9b3d6; border-radius: 5px; background: #f3f1fb; }
.set-sheet--4s { grid-template-columns: 1fr 1fr; }
.set-sheet--2s1l { grid-template-columns: 1fr 1fr; }
.set-sheet--2l { grid-template-columns: 1fr; }
.set-layout .set-sheet { width: min(100%, 150px); aspect-ratio: 210 / 297; align-content: center; }
.set-layout .set-sheet > i { aspect-ratio: 2 / 3; }
.set-layout .set-sheet > i.is-large { grid-column: 1 / -1; aspect-ratio: 3 / 2; }

/* Кадры: плитки с отметкой «выбрано» */
.set-work { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.set-help { margin: 0 0 14px; }
.set-photos { list-style: none; margin: 0 0 24px; padding: 0; column-width: 190px; column-gap: 14px; }
.set-photo {
  position: relative; display: block; margin: 0 0 14px; break-inside: avoid; padding: 0;
  border: 5px solid #fff; border-radius: var(--radius); background: var(--surface); overflow: hidden; cursor: pointer;
  box-shadow: 0 0 0 2px var(--line), 0 14px 26px -14px var(--soft-shadow);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), opacity .25s, filter .25s;
}
.set-photo img { width: 100%; height: auto; display: block; }
.set-photo:hover { transform: translateY(-3px); box-shadow: 0 0 0 2px var(--ink), 0 18px 30px -16px var(--soft-shadow); }
.set-photo:focus-visible { outline: 3px solid var(--c4); outline-offset: 3px; }
.set-photo.is-used { box-shadow: 0 0 0 3px var(--c2, #3ec6a8), 0 14px 26px -14px var(--soft-shadow); }
.set-photo.is-used img { opacity: .82; }
.set-photo.is-locked { filter: grayscale(1); opacity: .35; pointer-events: none; }
.set-photo__tick { position: absolute; top: 8px; right: 8px; display: none; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--c2, #3ec6a8); color: #fff; font-weight: 900; box-shadow: 0 2px 8px rgba(0,0,0,.35); }
.set-photo.is-used .set-photo__tick { display: grid; }
.set-photo__size { position: absolute; left: 8px; bottom: 8px; padding: 4px 10px; border-radius: 999px; background: #fff; color: #2b2a5c; font-size: .72rem; font-weight: 900; box-shadow: 0 2px 8px rgba(0,0,0,.2); }
.set-photo__size:empty { display: none; }
.set-photo__check, .set-photo__slot { display: flex; align-items: center; gap: 8px; padding: 8px 10px; margin: 0; font-weight: 800; font-size: .9rem; }
.set-photo select { flex: 1; padding: 8px 10px; border: 2px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--ink); font: inherit; }
.set-js .set-photo__check, .set-js .set-photo__slot { display: none; }

/* Панель «Выбрано»: липкая, места в виде листа */
.set-tray { position: sticky; top: 16px; display: grid; gap: 10px; padding: 16px; border: 3px solid var(--btn-shadow); border-radius: 24px; background: var(--surface); box-shadow: 0 6px 0 var(--btn-shadow); }
.set-tray__head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.set-tray__head h3 { margin: 0; font-size: 1.1rem; font-weight: 900; }
.set-tray__count { font-size: 1.3rem; font-weight: 900; }
.set-tray__bar { height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; }
.set-tray__bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--c2, #3ec6a8); transition: width .35s var(--ease); }
.set-tray__slots.set-sheet { width: min(100%, 230px); justify-self: center; padding: 10px; gap: 8px; }
.set-slot {
  appearance: none; position: relative; display: grid; place-items: center; align-content: center; gap: 2px; width: 100%; padding: 0; overflow: hidden;
  aspect-ratio: 2 / 3; border: 2px dashed #b9b3d6; border-radius: 8px; background: #f3f1fb; color: #5b5890; font: inherit; font-weight: 800; cursor: pointer;
  transition: transform .2s var(--ease), border-color .2s, background .2s;
}
.set-slot.is-large { grid-column: 1 / -1; aspect-ratio: 3 / 2; }
.set-slot b { font-size: 1.6rem; line-height: 1; }
.set-slot span { font-size: .78rem; }
.set-slot.is-empty:hover { border-color: var(--ink); transform: scale(1.02); }
.set-slot.is-next { border: 3px solid var(--ink); background: #fff8dc; color: #2b2a5c; animation: slot-pulse 1.4s ease-in-out infinite; }
.set-slot:focus-visible { outline: 3px solid var(--c4); outline-offset: 2px; }
.set-slot.is-filled { border: 2px solid var(--c2, #3ec6a8); background: #fff; }
.set-slot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.set-slot__size { position: absolute; left: 6px; bottom: 6px; padding: 2px 8px; white-space: nowrap; border-radius: 99px; background: #fff; color: #2b2a5c; font-size: .68rem; font-weight: 900; box-shadow: 0 1px 6px rgba(0,0,0,.3); }
.set-slot__remove { position: absolute; top: 6px; right: 6px; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--pop); color: #fff; font-size: 1rem; font-weight: 900; line-height: 1; box-shadow: 0 2px 8px rgba(0,0,0,.35); }
.set-slot.is-filled:hover .set-slot__remove { transform: scale(1.15); }
@keyframes slot-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(255, 201, 60, .7); } 50% { box-shadow: 0 0 0 7px rgba(255, 201, 60, 0); } }
.set-tray__hint { margin: 0; color: var(--muted); font-size: .88rem; font-weight: 800; }
.set-tray__hint.is-done { color: var(--ink); }
.set-tray__hint.is-warn { color: var(--pop-ink); }
.set-tray__actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.set-tray__actions .buy { flex: 1; text-align: center; }
.set-tray__actions .buy[disabled] { opacity: .45; cursor: not-allowed; box-shadow: none; transform: none; }
.set-tray__cancel { justify-self: start; }

@media (max-width: 899px) {
  .set-work { display: block; }
  /* На телефоне панель — липкая полоса снизу: места в один ряд */
  .set-tray { position: sticky; bottom: 10px; top: auto; z-index: 20; padding: 12px; border-radius: 20px; gap: 8px; }
  .set-tray__slots.set-sheet { display: flex; width: 100%; gap: 8px; padding: 8px; overflow-x: auto; }
  .set-tray__bar { display: none; }
  .set-slot { flex: 0 0 auto; width: 54px; }
  .set-slot.is-large { width: 81px; aspect-ratio: 3 / 2; }
  .set-slot b { font-size: 1.1rem; }
  .set-slot span { font-size: .66rem; }
  .set-slot__size { left: 3px; bottom: 3px; padding: 1px 5px; font-size: .58rem; }
  .set-slot__remove { top: 3px; right: 3px; width: 20px; height: 20px; font-size: .85rem; }
  .set-tray__actions .buy { padding: 9px 16px; font-size: .95rem; }
  .set-tray__head h3 { font-size: 1rem; }
  .set-tray__count { font-size: 1.1rem; }
  .set-tray__cancel { display: none; }
}
@media (max-width: 640px) {
  .set-layouts { grid-template-columns: 1fr; }
  .set-layout { grid-template-columns: 84px 1fr; justify-items: start; text-align: left; align-items: center; column-gap: 14px; }
  .set-layout .set-sheet { grid-row: 1 / span 2; width: 84px; }
  .set-photos { column-width: auto; column-count: 2; }
}
.cart-list.is-busy { opacity: .6; pointer-events: none; transition: opacity .15s; }
