/* С.Я. — компоненты. Значения цветов, шрифтов и размеров берутся только из tokens.css. */

/* ---------- Основа ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--stage-glow) no-repeat fixed, var(--bg);
  color: var(--text);
  font-family: var(--font-text);
  font-size: var(--fs-m);
  line-height: var(--lh-text);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p, ul, figure, blockquote { margin: 0; }
ul { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-hi); }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: -9999px; top: 8px; z-index: 100;
  padding: 10px 16px; border-radius: var(--r-pill);
  background: var(--accent-fill); color: var(--on-accent); font-weight: 700;
}
.skip:focus { left: 8px; }

.eyebrow {
  font-family: var(--font-label);
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  color: var(--accent);
}

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: var(--tap); padding: 0 var(--sp-5);
  border: 1.5px solid transparent; border-radius: var(--r-pill);
  font-family: var(--font-text); font-size: var(--fs-s); font-weight: 700; line-height: 1.15;
  text-align: center; text-decoration: none; cursor: pointer;
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast), transform var(--t-fast);
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn--gold {
  background: var(--accent-fill); color: var(--on-accent);
  box-shadow: 0 8px 22px -12px var(--accent-fill);
}
.btn--gold:hover { background: var(--accent-fill-hover); color: var(--on-accent); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--ghost[aria-pressed="true"] { border-color: var(--accent); color: var(--accent); background: var(--surface-2); }
.btn--s { min-height: var(--tap); padding: 0 var(--sp-4); font-size: var(--fs-xs); }

/* ---------- Шапка ---------- */
.top {
  position: sticky; top: 0; z-index: 30;
  height: var(--header-h);
  display: flex; align-items: center; gap: var(--sp-3);
  padding: 0 var(--sp-4);
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.logo { display: flex; align-items: baseline; gap: var(--sp-3); color: var(--accent); text-decoration: none; }
.logo b {
  font-family: var(--font-display); font-style: italic; font-weight: 800;
  font-size: 1.9rem; line-height: 1; letter-spacing: -.01em;
}
.logo span {
  display: none;
  font-family: var(--font-label); font-size: var(--fs-xs); letter-spacing: var(--track-label);
  text-transform: uppercase; color: var(--text-2);
}
.top__nav { margin-left: auto; display: flex; align-items: center; gap: var(--sp-1); }
.top__link {
  display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 var(--sp-3);
  border-radius: var(--r-pill); color: var(--text-2); font-size: var(--fs-s); text-decoration: none;
}
.top__link:hover { color: var(--text); }
/* «Как Софья Яковлевна / рекомендует» — двумя строками, пока шапка узкая; в одну — на широком экране (владелец 29.10) */
.top__link--how { flex-direction: column; align-items: flex-end; justify-content: center; line-height: 1.2; text-align: right; }
.top__link--how span { white-space: nowrap; }   /* ровно две строки, без третьей */
@media (max-width: 359px) { .top__link--how { padding: 0 var(--sp-1); font-size: var(--fs-xs); } }
@media (min-width: 1024px) { .top__link--how { flex-direction: row; align-items: center; gap: .3em; } }
.lamp {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-width: var(--tap); min-height: var(--tap); padding: 0 var(--sp-3);
  border: 1px solid var(--line); border-radius: var(--r-pill);
  background: transparent; color: var(--text); font-size: var(--fs-s); cursor: pointer;
}
.lamp:hover { border-color: var(--accent); }
.lamp svg { width: 18px; height: 18px; color: var(--accent); }
.lamp__label { display: none; }
@media (min-width: 720px) {
  .top { padding: 0 var(--sp-5); }
  .logo span, .lamp__label { display: inline; }
}

/* ---------- Зал: ложа (разговор) + сцена (подборка) ---------- */
.hall { display: grid; grid-template-columns: minmax(0, 1fr); }
.page-hall { padding-bottom: var(--ask-space, 96px); }
.loge { display: flex; flex-direction: column; gap: var(--sp-4); min-width: 0; padding: var(--sp-5) var(--sp-4); }
.log { display: flex; flex-direction: column; gap: var(--sp-5); }
.ask-wrap {
  position: fixed; z-index: 25; left: 0; right: 0; bottom: 0;
  padding: var(--sp-3) var(--sp-3) calc(var(--sp-3) + env(safe-area-inset-bottom));
  background: linear-gradient(to top, var(--bg) 70%, transparent);
}
@media (min-width: 1024px) {
  .hall { grid-template-columns: minmax(360px, 34%) minmax(0, 1fr); }
  .page-hall { padding-bottom: 0; }
  .loge {
    position: sticky; top: var(--header-h); align-self: start;
    height: calc(100dvh - var(--header-h));
    padding: var(--sp-6) var(--sp-5) var(--sp-5);
    border-right: 1px solid var(--line-soft);
  }
  .log { flex: 1; overflow-y: auto; padding-right: var(--sp-2); scrollbar-width: thin; }
  .ask-wrap { position: static; padding: 0; background: none; }
}

/* ---------- Сообщения ---------- */
.msg { display: grid; gap: var(--sp-2); max-width: 40rem; }
.log > .msg:not([hidden]) { animation: rise .5s var(--ease) both; }
/* Куда переходит фокус: не под липкой шапкой; рамка — только при работе с клавиатуры */
[data-focus-on] { scroll-margin-top: calc(var(--header-h) + var(--sp-4)); scroll-margin-bottom: 120px; }
[data-focus-on]:focus:not(:focus-visible) { outline: none; }
.msg--sya { grid-template-columns: 44px minmax(0, 1fr); column-gap: var(--sp-3); align-items: start; }
.msg--sya > .avatar { grid-row: 1 / span 2; }
.msg--sya > .msg__who, .msg--sya > .msg__body { grid-column: 2; }
.msg__body { display: grid; gap: var(--sp-3); }
.avatar {
  width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center;
  background: radial-gradient(circle at 32% 28%, var(--velvet-3), var(--velvet-2));
  border: 1.5px solid var(--fringe);
  color: var(--on-velvet);
  font-family: var(--font-display); font-style: italic; font-weight: 700; font-size: .92rem; letter-spacing: -.02em;
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--fringe) 14%, transparent);
}
.msg__who {
  font-family: var(--font-label); font-size: var(--fs-xs); letter-spacing: var(--track-label);
  text-transform: uppercase; color: var(--accent); line-height: 1.2; padding-top: 2px;
}
.msg__text { font-size: var(--fs-m); line-height: var(--lh-text); }
.msg__text--hero {
  font-family: var(--font-display); font-weight: 500; font-size: var(--fs-2xl); line-height: 1.08;
  letter-spacing: -.01em;
}
.msg__text--title { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-xl); line-height: 1.15; }
.msg__text--quiet { color: var(--text-2); font-size: var(--fs-s); }
body:not([data-state="first"]) .msg__text--hero { font-size: var(--fs-xl); }
body:not([data-state="first"]):not([data-state="onboarding"]) .msg__intro { display: none; }
.msg--user {
  align-self: flex-end; justify-self: end; max-width: 85%;
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--r-l) var(--r-l) var(--r-s) var(--r-l);
  background: var(--surface-2); border: 1px solid var(--line-soft);
}
.msg--status { padding-left: calc(44px + var(--sp-3)); }
.progress {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px;
  font-family: var(--font-label); font-size: var(--fs-s); letter-spacing: .06em; text-transform: uppercase;
  color: var(--text-2);
}
.progress b {
  font-family: var(--font-display); font-style: italic; font-weight: 700; letter-spacing: 0; text-transform: none;
  font-size: var(--fs-xl); color: var(--accent);
}
body[data-state="thinking"] .progress .step { animation: rise .5s var(--ease) both; }
body[data-state="thinking"] .progress .step:nth-child(2) { animation-delay: .5s; }
body[data-state="thinking"] .progress .step:nth-child(3) { animation-delay: 1.1s; }
body[data-state="thinking"] .progress .step:nth-child(4) { animation-delay: 1.4s; }
body[data-state="thinking"] .progress .step:nth-child(5) { animation-delay: 2s; }
body[data-state="thinking"] .progress .step:nth-child(6) { animation-delay: 2.3s; }

/* Переспрос кнопками */
.choices { display: grid; gap: var(--sp-3); }
@media (min-width: 520px) { .choices { grid-template-columns: 1fr 1fr; } }
.choices--three { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.choice {
  display: grid; gap: 2px; align-content: start;
  min-height: var(--tap); padding: var(--sp-4);
  border: 1.5px solid var(--line); border-radius: var(--r-m);
  background: var(--surface); color: var(--text);
  text-align: left; cursor: pointer;
  transition: border-color var(--t-fast), background var(--t-fast), transform var(--t-fast);
}
.choice:hover { border-color: var(--accent); background: var(--surface-2); transform: translateY(-1px); }
.choice[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.choice b { font-family: var(--font-display); font-size: var(--fs-l); font-weight: 700; line-height: 1.2; }
.choice span { font-size: var(--fs-s); color: var(--text-2); }

/* Плашка «Как это работает» */
.notice {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-2) var(--sp-3);
  padding: var(--sp-3) var(--sp-3) var(--sp-3) var(--sp-4);
  border: 1px solid var(--line-soft); border-radius: var(--r-m);
  background: var(--bg-2); color: var(--text-2); font-size: var(--fs-s);
}

/* Поле просьбы */
.ask {
  display: flex; align-items: flex-end; gap: var(--sp-2);
  padding: 6px 6px 6px var(--sp-2);
  border: 1.5px solid var(--line); border-radius: var(--r-l);
  background: var(--surface);
  box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .6);
}
.ask:focus-within { border-color: var(--accent); outline: 3px solid color-mix(in srgb, var(--focus) 55%, transparent); outline-offset: 1px; }
.ask textarea {
  flex: 1; min-height: var(--tap); max-height: 9rem; resize: none; field-sizing: content;
  padding: 10px var(--sp-2); border: 0; background: transparent; color: var(--text);
  font-family: var(--font-text); font-size: var(--fs-m); line-height: 1.4;
}
.ask textarea:focus { outline: none; }
.ask textarea::placeholder { color: var(--text-3); }
.ask textarea:disabled { cursor: not-allowed; }
.send {
  flex: none; width: var(--tap); height: var(--tap); border: 0; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--accent-fill); color: var(--on-accent); cursor: pointer;
}
.send:hover { background: var(--accent-fill-hover); }
.send:disabled { opacity: .45; cursor: not-allowed; }
.send svg { width: 20px; height: 20px; }

/* ---------- Сцена: ламбрекен, занавес ---------- */
.stage { position: relative; min-width: 0; padding: 0 var(--sp-4) var(--sp-7); container-type: inline-size; }
@media (min-width: 1024px) { .stage { padding: 0 var(--sp-6) var(--sp-8); } }
.valance {
  position: relative; z-index: 6;
  height: 46px; margin: 0 calc(var(--sp-4) * -1);
  background:
    radial-gradient(circle at 24px 0, var(--velvet-1) 0 22px, var(--fringe) 22.5px 25px, transparent 25.5px) 0 14px / 48px 32px repeat-x,
    repeating-linear-gradient(90deg, var(--velvet-2) 0, var(--velvet-1) 12px, var(--velvet-3) 20px, var(--velvet-1) 28px, var(--velvet-2) 48px) 0 0 / 100% 16px no-repeat;
  filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .35));
}
@media (min-width: 1024px) { .valance { margin: 0 calc(var(--sp-6) * -1); } }
.frame { position: relative; min-height: 440px; margin-top: -32px; padding-top: 32px; overflow: hidden; }
@media (min-width: 1024px) { .frame { min-height: calc(100dvh - var(--header-h) - 70px); } }
.curtain {
  position: absolute; inset: 0; z-index: 5;
  display: grid; place-items: center;
  padding: var(--sp-7) var(--sp-5);
  text-align: center; color: var(--on-velvet);
  background:
    radial-gradient(ellipse 60% 45% at 50% 40%, rgba(255, 190, 150, .16), transparent 70%),
    linear-gradient(to bottom, rgba(0, 0, 0, .3), transparent 22%, transparent 70%, rgba(0, 0, 0, .45)),
    repeating-linear-gradient(90deg, var(--velvet-2) 0, var(--velvet-1) 18px, var(--velvet-3) 31px, var(--velvet-1) 44px, var(--velvet-2) 64px);
  transition: transform var(--t-curtain) var(--ease), visibility 0s;
}
.curtain::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 18px;
  background:
    linear-gradient(var(--fringe), var(--fringe)) 0 0 / 100% 4px no-repeat,
    repeating-linear-gradient(90deg, var(--fringe) 0 2px, transparent 2px 6px) 0 4px / 100% 14px no-repeat;
}
.stage[data-curtain="open"] .curtain {
  transform: translateY(-103%); visibility: hidden;
  transition: transform var(--t-curtain) var(--ease), visibility 0s linear var(--t-curtain);
}
.stage[data-curtain="rising"] .curtain { transform: translateY(-60%); place-items: end center; padding-bottom: var(--sp-6); }
.curtain, .cta-band { --focus: var(--on-velvet); }
.curtain__inner { display: grid; justify-items: center; gap: var(--sp-4); max-width: 32rem; }
.curtain__inner > div { display: grid; justify-items: center; gap: var(--sp-4); }
.curtain__title { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-2xl); line-height: 1.05; }
.curtain__text { font-family: var(--font-display); font-style: italic; font-size: var(--fs-xl); line-height: 1.25; text-wrap: balance; }
.curtain__note { font-size: var(--fs-s); color: var(--on-velvet); }
.hints { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-2); }
.hint {
  display: inline-flex; align-items: center; text-decoration: none;
  min-height: var(--tap); padding: 0 var(--sp-4);
  border: 1px solid rgba(246, 215, 147, .55); border-radius: var(--r-pill);
  background: rgba(20, 4, 8, .4); color: var(--on-velvet);
  font-size: var(--fs-s); cursor: pointer;
}
.hint:hover { background: rgba(20, 4, 8, .65); border-color: var(--on-velvet); color: var(--on-velvet); }

/* ---------- Сцена: подборка ---------- */
.scene { position: relative; z-index: 1; }
.scene__head { display: grid; gap: var(--sp-2); padding: var(--sp-5) 0 var(--sp-6); }
.scene__title { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-2xl); line-height: 1.04; letter-spacing: -.01em; text-wrap: balance; }
.conds { display: flex; flex-wrap: wrap; gap: 6px; margin-top: var(--sp-2); }
.conds li {
  padding: 4px 12px; border: 1px solid var(--line); border-radius: var(--r-pill);
  font-size: var(--fs-xs); color: var(--text-2);
}

.lineup { display: grid; gap: var(--sp-7) var(--sp-5); isolation: isolate; }
@container (min-width: 780px) { .lineup { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* Одна колонка на узкой сцене: афиша ниже, название крупнее */
@container (max-width: 519px) {
  .lineup .poster { aspect-ratio: 5 / 4; }
  .lineup .poster__title { font-size: clamp(1.9rem, 1rem + 5cqi, 2.6rem); }
}
@container (min-width: 640px) { .lineup--two { grid-template-columns: repeat(2, minmax(0, 360px)); justify-content: center; } }
.stage[data-curtain="open"] .lineup > * { animation: rise .8s var(--ease) both; }
.stage[data-curtain="open"] .lineup > :nth-child(1) { animation-delay: .35s; }
.stage[data-curtain="open"] .lineup > :nth-child(2) { animation-delay: .5s; }
.stage[data-curtain="open"] .lineup > :nth-child(3) { animation-delay: .65s; }

/* Карточка-афиша */
.playbill {
  position: relative; display: flex; flex-direction: column;
  border-radius: var(--r-l); background: var(--surface); box-shadow: var(--shadow-card);
}
.playbill::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  left: -22%; right: -22%; top: -90px; height: 70%;
  background: radial-gradient(ellipse 50% 50% at 50% 50%, var(--spot), transparent 70%);
}
.poster {
  position: relative; overflow: hidden; aspect-ratio: 3 / 4;
  border-radius: var(--r-l) var(--r-l) 0 0;
  background: var(--g1); color: var(--poster-ink);
}
.poster .art, .poster img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* Рисунок жанра красится переменными --g1…--g4 карточки; при свете в зале — приглушён */
[data-theme="light"] .art { filter: saturate(.7) brightness(1.04); opacity: .9; }
.art .c1 { fill: var(--g1); }
.art .c2 { fill: var(--g2); }
.art .c3 { fill: var(--g3); }
.art .c4 { fill: var(--g4); }
.art .s2, .art .s3, .art .s4 { fill: none; }
.art .s2 { stroke: var(--g2); }
.art .s3 { stroke: var(--g3); }
.art .s4 { stroke: var(--g4); }
.poster::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 70%;
  background: linear-gradient(to top, var(--scrim) 0%, var(--scrim) 35%, var(--scrim-mid) 70%, transparent);
}
.poster__cap { position: absolute; z-index: 2; left: 0; right: 0; bottom: 0; padding: var(--sp-4); }
.poster__kind {
  margin-bottom: 6px;
  font-family: var(--font-label); font-size: var(--fs-xs); letter-spacing: var(--track-label); text-transform: uppercase;
  color: var(--poster-ink); opacity: .88;
}
.poster__title {
  font-family: var(--font-display); font-weight: 800; line-height: 1.02; letter-spacing: -.012em;
  font-size: clamp(1.7rem, 1.1rem + 2.6cqi, 2.6rem);
  text-wrap: balance; color: var(--poster-ink);
  overflow-wrap: break-word; hyphens: auto;   /* настоящие названия длиннее демо: слово не вылезает за карточку */
}
/* Длинное название (больше 28 знаков) — кегль меньше */
.poster__title.poster__title--long, .lineup .poster__title.poster__title--long { font-size: clamp(1.35rem, .95rem + 2cqi, 1.9rem); }
.poster__num {
  position: absolute; z-index: 2; top: var(--sp-3); left: var(--sp-3);
  min-width: 38px; height: 38px; padding: 0 8px; border-radius: var(--r-pill);
  display: grid; place-items: center;
  background: rgba(12, 6, 8, .74); border: 1px solid rgba(251, 243, 230, .35);
  color: var(--poster-ink); font-family: var(--font-display); font-style: italic; font-weight: 700;
}
.badge {
  position: absolute; z-index: 2; top: var(--sp-3); right: var(--sp-3);
  padding: 7px 11px 6px; border-radius: var(--r-s);
  background: var(--badge); color: var(--on-badge);
  font-family: var(--font-label); font-size: var(--fs-xs); font-weight: 500; letter-spacing: .1em; text-transform: uppercase; line-height: 1;
  box-shadow: 0 6px 16px -6px rgba(0, 0, 0, .6);
}
.playbill__body { display: grid; gap: var(--sp-4); align-content: start; flex: 1; padding: var(--sp-4) var(--sp-4) var(--sp-5); }
.facts { font-size: var(--fs-s); color: var(--text-2); line-height: 1.45; }
.facts .when { color: var(--text); font-weight: 700; font-size: var(--fs-m); }
.age {
  display: inline-block; margin-left: 6px; padding: 0 6px;
  border: 1px solid var(--line); border-radius: 4px;
  font-size: var(--fs-xs); font-weight: 600; color: var(--text-2); vertical-align: 1px;
}
.why {
  display: grid; gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-3) var(--sp-3) var(--sp-4);
  margin: 0 calc(var(--sp-2) * -1) 0 0;
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--r-m) var(--r-m) 0;
  background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 13%, transparent), transparent 85%);
}
.why__label { font-family: var(--font-label); font-size: var(--fs-xs); font-weight: 500; letter-spacing: var(--track-label); text-transform: uppercase; color: var(--accent); }
.why__text { font-size: var(--fs-m); line-height: 1.5; }
.why__quote p { font-family: var(--font-display); font-style: italic; font-size: var(--fs-m); line-height: 1.4; color: var(--text-2); }
.why__quote footer { margin-top: 2px; font-size: var(--fs-xs); color: var(--text-3); }

/* Корешок билета: цена и покупка */
.stub {
  position: relative; display: grid; gap: var(--sp-3);
  padding: var(--sp-4);
  border-top: 2px dashed var(--line);
}
.stub::before, .stub::after {
  content: ""; position: absolute; top: -11px; width: 20px; height: 20px; border-radius: 50%; background: var(--bg);
}
.stub::before { left: -10px; }
.stub::after { right: -10px; }
.price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; }
.price b { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-xl); line-height: 1.1; font-variant-numeric: lining-nums; }
.price small { font-size: var(--fs-xs); color: var(--text-3); }
.price .price__other { flex-basis: 100%; }   /* дешевле на другом сеансе — своей строкой (F-185) */
.stub .btn { width: 100%; }

/* Карточка на средней ширине сцены — горизонтально */
@container (min-width: 520px) and (max-width: 779px) {
  .lineup:not(.lineup--two) .playbill { display: grid; grid-template-columns: 42% minmax(0, 1fr); grid-template-rows: 1fr auto; }
  .lineup:not(.lineup--two) .poster { grid-row: 1 / 3; aspect-ratio: auto; min-height: 100%; border-radius: var(--r-l) 0 0 var(--r-l); }
  .lineup:not(.lineup--two) .stub { grid-column: 2; }
  .lineup:not(.lineup--two) .stub::before { display: none; }
}

/* «Думает»: заготовки карточек */
.playbill--ghost { overflow: hidden; }
.playbill--ghost::before { display: none; }
.playbill--ghost .poster {
  background: linear-gradient(100deg, var(--surface-2) 30%, color-mix(in srgb, var(--surface-2) 80%, var(--text)) 50%, var(--surface-2) 70%) 0 0 / 250% 100%;
  animation: shimmer 1.6s linear infinite;
}
.playbill--ghost .poster::after { display: none; }
.ghost-line { height: 12px; margin: var(--sp-4) var(--sp-4) 0; border-radius: 6px; background: var(--surface-2); }
.ghost-line--short { width: 55%; margin-bottom: var(--sp-5); }

/* «Ещё 10» и «поделиться» */
.after { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-3); margin-top: var(--sp-7); }
/* «Хочу / Не моё» на карточке подборки и ответы на «что по настроению?» */
.react { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.react__label { font-family: var(--font-label); font-size: var(--fs-xs); letter-spacing: .08em; text-transform: uppercase; color: var(--text-3); margin-right: 2px; }
.moods { display: flex; flex-wrap: wrap; gap: 6px; margin: var(--sp-2) 0; }
.more { display: grid; gap: var(--sp-3); margin-top: var(--sp-6); }
.more__title { font-family: var(--font-display); font-size: var(--fs-xl); font-weight: 700; margin-bottom: var(--sp-2); }
.row {
  display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: var(--sp-3) var(--sp-4); align-items: start;
  padding: var(--sp-3); border: 1px solid var(--line-soft); border-radius: var(--r-m); background: var(--surface);
}
.row__thumb { position: relative; width: 72px; aspect-ratio: 3 / 4; overflow: hidden; border-radius: var(--r-s); background: var(--g1); }
.row__thumb .art { position: absolute; inset: 0; width: 100%; height: 100%; }
.row__kind { font-family: var(--font-label); font-size: var(--fs-xs); letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.row__title { font-family: var(--font-display); font-size: var(--fs-l); font-weight: 700; line-height: 1.15; }
.row__meta { margin-top: 2px; font-size: var(--fs-s); color: var(--text-2); }
.row__why { margin-top: 6px; font-size: var(--fs-s); }
.row__buy { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-2) var(--sp-3); }
.row__buy .price b { font-size: var(--fs-l); }
@container (min-width: 700px) {
  .row { grid-template-columns: 72px minmax(0, 1fr) auto; align-items: center; }
  .row__buy { grid-column: auto; flex-direction: column; align-items: flex-end; }
}

/* «Ничего не подошло»: что сдвинули */
.shift {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: var(--sp-3);
  padding: 6px 12px; border: 1px dashed var(--accent); border-radius: var(--r-pill);
  font-family: var(--font-label); font-size: var(--fs-xs); letter-spacing: .1em; text-transform: uppercase; color: var(--accent);
}

/* «Зашло?»: билет с прошлого похода */
.visit { position: relative; max-width: 360px; margin: 0 auto; }
.stamp {
  position: absolute; z-index: 3; right: -10px; top: 44%;
  padding: 8px 14px; border: 3px double var(--accent); border-radius: var(--r-s);
  background: var(--surface); color: var(--accent);
  font-family: var(--font-label); font-size: var(--fs-l); font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  transform: rotate(-12deg);
}

/* ---------- Знакомство ---------- */
.seats-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-4); margin-top: var(--sp-2); }
.seats { display: flex; gap: 5px; }
.seat { width: 20px; height: 20px; color: var(--surface-2); transition: color .3s var(--ease), transform .3s var(--ease); }
.seat.is-on { color: var(--accent); transform: translateY(-2px); }
.count { font-size: var(--fs-s); color: var(--text-2); }
.count b { color: var(--text); }
.tiles { display: grid; gap: var(--sp-3); }
@container (min-width: 560px) { .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-4); } }
@container (min-width: 820px) { .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tile {
  min-width: 0; margin: 0; padding: 0; border: 0;
  display: grid; grid-template-columns: 96px minmax(0, 1fr);
  overflow: hidden; border-radius: var(--r-m); background: var(--surface); box-shadow: var(--shadow-card);
}
.tile .poster { aspect-ratio: auto; min-height: 128px; border-radius: 0; }
.tile .poster::after { height: 100%; }
.tile .poster__cap { padding: var(--sp-2); }
.tile .poster__kind { display: none; }
.tile .poster__title { font-size: 1rem; font-weight: 700; }
.tile__side { display: grid; align-content: space-between; gap: var(--sp-2); padding: var(--sp-3); }
.tile__kind { font-family: var(--font-label); font-size: var(--fs-xs); letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.marks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
.mark { position: relative; }
.mark input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.mark span {
  display: grid; place-items: center; min-height: var(--tap); padding: 4px;
  border: 1px solid var(--line); border-radius: var(--r-s);
  font-size: var(--fs-xs); font-weight: 700; line-height: 1.12; text-align: center; color: var(--text-2);
  cursor: pointer; transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast);
}
.mark span:hover { border-color: var(--accent); color: var(--text); }
.mark input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.mark--go input:checked + span { background: var(--accent-fill); border-color: transparent; color: var(--on-accent); }
.mark--no input:checked + span { background: var(--surface-2); border-color: var(--text-3); color: var(--text); }
.mark--idk input:checked + span { border-style: dashed; border-color: var(--text-2); color: var(--text); }
.tile:has(.mark--no input:checked) .poster { filter: grayscale(1) brightness(.6); }
.tile:has(.mark--go input:checked) { box-shadow: 0 0 0 2px var(--accent), var(--shadow-card); }
@container (min-width: 560px) {
  .tile { grid-template-columns: minmax(0, 1fr); }
  .tile .poster { aspect-ratio: 4 / 5; min-height: 0; }
  .tile .poster::after { height: 64%; }
  .tile .poster__cap { padding: var(--sp-3); }
  .tile .poster__kind { display: block; }
  .tile .poster__title { font-size: clamp(1.1rem, .8rem + 1.1cqi, 1.45rem); font-weight: 800; }
  .tile__kind { display: none; }
  .tile__side { padding: var(--sp-2); }
}
.intro__actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); margin-top: var(--sp-6); }
.seats-row .intro__actions { margin-top: 0; }

/* ---------- Подвал ---------- */
.foot {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-5);
  padding: var(--sp-6) var(--sp-5);
  border-top: 1px solid var(--line-soft);
  font-size: var(--fs-s); color: var(--text-2);
}
.foot a { color: var(--text-2); }
.foot a:hover { color: var(--accent); }
.foot__demo { flex-basis: 100%; font-size: var(--fs-xs); color: var(--text-3); }
.ph { color: var(--text-3); }

/* ---------- Сообщение «скопировано» ---------- */
.toast:empty { opacity: 0; pointer-events: none; }
.toast {
  position: fixed; z-index: 50; left: 50%; bottom: 104px; transform: translateX(-50%);
  max-width: calc(100vw - 32px); padding: 12px 18px; border-radius: var(--r-pill);
  background: var(--text); color: var(--bg); font-size: var(--fs-s); font-weight: 600;
  box-shadow: 0 12px 30px -12px rgba(0, 0, 0, .6);
}
@media (min-width: 1024px) { .toast { bottom: 32px; } }

/* ---------- Демо-панель (не часть продукта) ---------- */
.demo { position: fixed; z-index: 40; right: 8px; bottom: 84px; font-family: var(--font-text); font-size: 13px; }
@media (min-width: 1024px) { .demo { right: 12px; bottom: 16px; } }
.demo details {
  max-width: 240px; border: 1px dashed #e2b05a; border-radius: 12px;
  background: #0b0708; color: #f5ebdb; box-shadow: 0 12px 30px -10px rgba(0, 0, 0, .7);
}
.demo summary {
  display: flex; align-items: center; min-height: var(--tap); padding: 0 14px; cursor: pointer; list-style: none;
  font-family: var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: #e2b05a;
}
.demo summary::-webkit-details-marker { display: none; }
.demo summary::after { content: "▴"; margin-left: 8px; }
.demo details[open] summary::after { content: "▾"; }
.demo__body { display: grid; gap: 6px; max-height: 70vh; overflow-y: auto; padding: 0 10px 10px; }
.demo__hint { margin-top: 6px; color: #a8927e; font-size: 12px; }
.demo__list { display: grid; gap: 4px; }
.demo__list--row { grid-template-columns: 1fr 1fr; }
.demo button, .demo a {
  display: flex; align-items: center; min-height: 36px; padding: 0 10px;
  border: 1px solid rgba(245, 235, 219, .16); border-radius: 8px;
  background: transparent; color: #f5ebdb; text-align: left; text-decoration: none; cursor: pointer; font-size: 13px;
}
.demo button:hover, .demo a:hover { border-color: #e2b05a; }
.demo [aria-current="true"], .demo [aria-pressed="true"] { background: #e2b05a; border-color: #e2b05a; color: #1d1307; }

/* ---------- Отдельные страницы ---------- */
/* overflow-x: clip — свечение карточек (.playbill::before) выходит за край; clip не создаёт прокрутку и не мешает sticky */
.page { max-width: 1240px; margin: 0 auto; padding: 0 var(--sp-4) var(--sp-8); overflow-x: clip; }
@media (min-width: 1024px) { .page { padding: 0 var(--sp-6) var(--sp-8); } }
.sit-hero { max-width: 56rem; padding: var(--sp-7) 0 var(--sp-5); }
.sit-hero h1 {
  margin: var(--sp-3) 0 var(--sp-4);
  font-family: var(--font-display); font-weight: 800; font-size: var(--fs-hero); line-height: 1.02; letter-spacing: -.015em;
  text-wrap: balance;
}
.sit-who { max-width: 44rem; display: grid; gap: var(--sp-2); padding-bottom: var(--sp-7); }
.sit-who p { font-size: var(--fs-l); line-height: 1.5; color: var(--text-2); }
.stage--static { padding: 0 0 var(--sp-6); }
.stage--static .valance { margin: 0 0 var(--sp-3); border-radius: var(--r-s) var(--r-s) 0 0; }
.cta-band {
  display: grid; gap: var(--sp-4); justify-items: start;
  margin-top: var(--sp-6); padding: var(--sp-6);
  border-radius: var(--r-l); color: var(--on-velvet);
  background:
    radial-gradient(ellipse 60% 80% at 15% 0%, rgba(255, 190, 150, .18), transparent 70%),
    repeating-linear-gradient(90deg, var(--velvet-2) 0, var(--velvet-1) 18px, var(--velvet-3) 31px, var(--velvet-1) 44px, var(--velvet-2) 64px);
}
.cta-band__text { max-width: 36rem; font-family: var(--font-display); font-style: italic; font-size: var(--fs-xl); line-height: 1.25; }
.others { display: grid; gap: var(--sp-3); margin-top: var(--sp-7); }
.others ul { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.others a {
  display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 var(--sp-4);
  border: 1px solid var(--line); border-radius: var(--r-pill); color: var(--text); text-decoration: none; font-size: var(--fs-s);
}
.others a:hover { border-color: var(--accent); color: var(--accent); }

.prose { max-width: 46rem; margin: 0 auto; padding: var(--sp-7) 0 0; display: grid; gap: var(--sp-4); }
.prose h1 { font-family: var(--font-display); font-weight: 800; font-size: var(--fs-hero); line-height: 1.02; letter-spacing: -.015em; }
.prose h2 { margin-top: var(--sp-5); font-family: var(--font-display); font-weight: 700; font-size: var(--fs-xl); line-height: 1.2; }
.prose .lead { font-size: var(--fs-l); color: var(--text-2); }
.placeholder {
  padding: var(--sp-4); border: 1px dashed var(--line); border-radius: var(--r-m);
  background: repeating-linear-gradient(135deg, transparent 0 10px, color-mix(in srgb, var(--text) 3%, transparent) 10px 20px);
  color: var(--text-3); font-style: italic;
}

/* ---------- Движение ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes shimmer { to { background-position: -150% 0; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* ---------- Страница «Стиль» ---------- */
.sg-lead { max-width: 46rem; font-size: var(--fs-l); line-height: 1.5; color: var(--text-2); }
.sg-sec { display: grid; gap: var(--sp-4); padding: var(--sp-7) 0; border-top: 1px solid var(--line-soft); }
.sg-h { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-2xl); line-height: 1.05; }
.sg-note { max-width: 46rem; font-size: var(--fs-s); color: var(--text-2); }
.sg code, .sg-val { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .8125rem; }
.sg-sub { margin-top: var(--sp-3); }
.sg-themes { display: grid; gap: var(--sp-4); }
@media (min-width: 760px) { .sg-themes { grid-template-columns: 1fr 1fr; } }
.sg-theme { display: grid; gap: var(--sp-3); padding: var(--sp-5); border-radius: var(--r-l); background: var(--bg); color: var(--text); border: 1px solid var(--line-soft); }
.sg-swatches { display: grid; gap: 6px; }
.sg-swatches li { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: var(--sp-3); font-size: var(--fs-s); }
.sg-swatches--row { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.sg-sw { width: 36px; height: 36px; border-radius: var(--r-s); border: 1px solid var(--line-soft); }
.sg-val { color: var(--text-3); }
.sg-genres { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: var(--sp-4); }
.sg-genres li { display: grid; gap: 6px; font-size: var(--fs-s); }
.sg-genre { position: relative; aspect-ratio: 3 / 4; overflow: hidden; border-radius: var(--r-m); background: var(--g1); }
.sg-genre .art { position: absolute; inset: 0; width: 100%; height: 100%; }
.sg-chips { display: flex; gap: 4px; }
.sg-chips i { width: 22px; height: 12px; border-radius: 3px; border: 1px solid var(--line-soft); }
.sg-type { display: grid; gap: var(--sp-5); }
.sg-display { font-family: var(--font-display); font-weight: 800; font-size: var(--fs-hero); line-height: 1; letter-spacing: -.015em; }
.sg-display--i { font-style: italic; font-weight: 500; font-size: var(--fs-2xl); color: var(--accent); }
.sg-label { font-family: var(--font-label); font-size: var(--fs-l); letter-spacing: var(--track-label); text-transform: uppercase; }
.sg-scale { display: grid; gap: var(--sp-2); }
.sg-scale li { display: grid; grid-template-columns: 90px minmax(0, 1fr); align-items: baseline; gap: var(--sp-4); line-height: 1.15; }
.sg-scale code { color: var(--text-3); }
.sg-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-3); }
.sg-narrow { max-width: 34rem; }
.sg-static { position: static; }
.sg-cards { padding-top: var(--sp-7); }
.sg-stack { display: grid; gap: var(--sp-3); align-content: start; }
.sg-one { grid-template-columns: minmax(0, 260px) !important; }
.sg-mini .frame { min-height: 280px !important; }
.sg-space { display: flex; flex-wrap: wrap; align-items: flex-end; gap: var(--sp-5); font-size: var(--fs-s); }
.sg-space li { display: grid; gap: 6px; justify-items: start; }
.sg-space li > span { display: block; background: var(--accent-fill); }
.sg-radius { width: 64px !important; height: 44px !important; background: var(--surface-2) !important; border: 1.5px solid var(--accent); }

/* DES-012, 10: «Не то?» со словами */
.note { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.note__input { flex: 1 1 220px; min-width: 0; padding: 6px 10px; border-radius: 8px; border: 1px solid currentColor; background: transparent; color: inherit; font: inherit; }
.note__done { font-size: 0.9em; opacity: 0.8; }
