/* espace design — главная и бриф. Токены те же, что у стенда (room/web3d). */
:root {
  color-scheme: light;
  --ink: #0a0a0a; --ink-2: #5f5d58; --sheet: #ffffff; --line: #e3dfd8; --bg: #f7f5f2; --chip: #efece7;
  --font: "Inter", -apple-system, "Segoe UI", system-ui, sans-serif;
  --gutter: 20px; --max: 1240px;
}
* { box-sizing: border-box; }
html { background: var(--bg); color: var(--ink); font-family: var(--font); -webkit-font-smoothing: antialiased; }
body { margin: 0; line-height: 1.45; }
a { color: inherit; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.bar { display: flex; align-items: center; gap: 28px; padding: 18px 0; }
.brand { font-weight: 700; font-size: 22px; letter-spacing: -0.02em; line-height: 1; text-decoration: none; }
.brand small { display: block; font-weight: 400; font-size: 11px; letter-spacing: 0.12em; margin-top: 3px; color: var(--ink-2); }
.nav { display: flex; gap: 22px; font-size: 14px; }
.nav a { text-decoration: none; }
.nav a:hover { text-decoration: underline; text-underline-offset: 3px; }
.spacer { flex: 1; }
.link { background: none; border: 0; padding: 0; font-size: 14px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.btn { display: inline-block; background: var(--ink); color: var(--bg); border: 0; border-radius: 2px; padding: 15px 26px; font-size: 15px; font-weight: 600; cursor: pointer; text-decoration: none; text-align: center; }
.btn:disabled { opacity: .5; cursor: default; }
.btn.ghost { background: none; color: var(--ink); border: 1px solid var(--ink); }
.muted { color: var(--ink-2); }
h1, h2, h3 { margin: 0; letter-spacing: -0.02em; line-height: 1.05; }
h1 { font-size: clamp(34px, 5vw, 56px); font-weight: 700; }
h2 { font-size: clamp(26px, 3.2vw, 36px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 700; line-height: 1.2; }
.lead { font-size: 18px; color: var(--ink-2); margin: 18px 0 0; max-width: 34ch; }
.price { font-size: 22px; font-weight: 700; margin: 28px 0 22px; }
.price small { font-weight: 400; font-size: 15px; color: var(--ink-2); }

/* главная */
.hero { display: grid; grid-template-columns: minmax(280px, 440px) 1fr; gap: 40px; align-items: center; padding: 20px 0 48px; }
.hero h1 { font-size: clamp(32px, 4.2vw, 48px); }
.live { position: relative; aspect-ratio: 4 / 3; background: #e9e6df; border-radius: 2px; overflow: hidden; }
.live iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; z-index: 2; }
.live .play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 3; }
.live.live-on .play { left: auto; top: auto; right: 16px; bottom: 14px; transform: none; padding: 10px 16px; font-size: 14px; }
/* живая сцена: один холст на всю страницу под содержимым, окна страницы прозрачные */
.live-canvas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
header, main, footer { position: relative; z-index: 1; }
[data-live] { position: relative; overflow: hidden; touch-action: pan-y; user-select: none; -webkit-user-select: none; cursor: grab; }
[data-live]:active { cursor: grabbing; }
[data-live] .poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .9s; z-index: 1; }
[data-live].live-on, .live-row .stage.live-on { background: transparent; }
[data-live].live-on .poster { opacity: 0; pointer-events: none; }
.live-ui { position: absolute; inset: 0; pointer-events: none; z-index: 2; }
.live-cap { position: absolute; left: 14px; bottom: 14px; max-width: 48ch; font-size: 13px; line-height: 1.35; color: var(--ink); background: rgba(255,255,255,.86); padding: 6px 10px; border-radius: 4px; }
.live-cap:empty { display: none; }
.live-sum { position: absolute; right: 14px; top: 14px; background: #fff; border: 1px solid var(--line); border-radius: 4px; padding: 6px 10px; font-weight: 700; font-size: 15px; min-width: 110px; }
.live-sum small { display: block; font-weight: 400; font-size: 11px; color: var(--ink-2); }
.live-tags { position: absolute; inset: 0; }
.live-tag { position: absolute; left: 0; top: 0; margin: -36px 0 0 -10px; background: #fff; border: 1px solid var(--line); border-radius: 4px; padding: 4px 8px; font-size: 12px; white-space: nowrap; opacity: 0; box-shadow: 0 2px 10px rgba(0,0,0,.08); }
.live-tag b { margin-left: 8px; }
.live-row { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding: 8px 0 56px; }
.live-row figure { margin: 0; }
.live-row .stage { aspect-ratio: 3 / 2; border-radius: 2px; background: #e9e6df; }
.live-row figcaption, .cap { font-size: 13px; margin-top: 8px; }
.split { position: absolute; top: 0; bottom: 0; left: 50%; width: 0; z-index: 2; }
.split i { position: absolute; top: 0; bottom: 0; left: -1px; width: 2px; background: #fff; box-shadow: 0 0 6px rgba(0,0,0,.35); }
.split i::after { content: ''; position: absolute; left: 50%; top: 50%; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.25); background-image: linear-gradient(90deg, transparent 8px, #0a0a0a 8px 10px, transparent 10px 24px, #0a0a0a 24px 26px, transparent 26px); }
.split span { position: absolute; top: 12px; font-size: 12px; background: rgba(255,255,255,.9); padding: 3px 8px; border-radius: 3px; white-space: nowrap; }
.split .l { right: 10px; }
.split .r { left: 10px; }
.no-live .split, .no-live .live-ui { display: none; }
.no-live [data-live="compare"] .poster.before { width: calc(50% - 5px); }
.no-live [data-live="compare"] .poster:not(.before) { left: calc(50% + 5px); width: calc(50% - 5px); }
section { padding: 56px 0; border-top: 1px solid var(--line); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; margin-top: 32px; }
.step b { display: block; font-size: 13px; letter-spacing: .08em; color: var(--ink-2); margin-bottom: 10px; }
.step p { margin: 8px 0 0; color: var(--ink-2); }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 32px; }
.card { text-decoration: none; }
.card img { aspect-ratio: 3 / 2; object-fit: cover; border-radius: 2px; }
.card h3 { margin-top: 12px; }
.card p { margin: 6px 0 0; color: var(--ink-2); font-size: 14px; }
footer { border-top: 1px solid var(--line); padding: 28px 0 40px; font-size: 13px; color: var(--ink-2); display: flex; flex-wrap: wrap; gap: 10px 26px; }
footer a { color: var(--ink-2); }

/* бриф */
.brief { display: grid; grid-template-columns: minmax(260px, 340px) 1fr; gap: 48px; padding: 24px 0 64px; align-items: start; }
.brief aside { position: sticky; top: 24px; }
.brief .lead { margin-top: 14px; }
.brief .actions { margin-top: 28px; display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.steps-nav { display: flex; gap: 18px; font-size: 13px; color: var(--ink-2); margin-bottom: 8px; flex-wrap: wrap; }
.steps-nav b { color: var(--ink); font-weight: 600; }
.panel[hidden] { display: none; }
.drop { border: 1.5px dashed var(--ink); border-radius: 2px; padding: 46px 20px; text-align: center; cursor: pointer; }
.drop.over { background: var(--chip); }
.drop .arrow { font-size: 28px; line-height: 1; }
.drop h3 { font-size: 24px; margin-top: 10px; }
.drop input { display: none; }
.files { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; margin-top: 22px; }
.file { font-size: 13px; }
.file .th { aspect-ratio: 4 / 3; background: var(--sheet); border: 1px solid var(--line); border-radius: 2px; display: grid; place-items: center; overflow: hidden; color: var(--ink-2); font-size: 12px; padding: 6px; text-align: center; }
.file .th img { width: 100%; height: 100%; object-fit: cover; }
.file .n { display: block; margin-top: 6px; font-weight: 600; }
.file .x { background: none; border: 0; padding: 0; font-size: 12px; color: var(--ink-2); text-decoration: underline; cursor: pointer; }
textarea, input[type=text], input[type=email], input[type=tel], input[type=url], input[type=number], select { width: 100%; border: 1px solid var(--line); background: var(--sheet); border-radius: 2px; padding: 12px 14px; font: inherit; font-size: 15px; color: var(--ink); }
textarea { min-height: 96px; resize: vertical; }
.row { display: grid; gap: 14px; margin-top: 22px; }
.row.two { grid-template-columns: 1fr 1fr; }
label.f { display: block; font-size: 13px; color: var(--ink-2); }
label.f > span { display: block; margin-bottom: 6px; }
.facts { border-top: 1px solid var(--line); }
.fact { display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--line); }
.fact small { display: block; color: var(--ink-2); font-size: 13px; margin-bottom: 4px; }
.fact b { font-size: 22px; letter-spacing: -0.01em; }
.fact .edit { display: none; margin-top: 8px; }
.fact.editing .edit { display: block; }
.fact.editing .val { display: none; }
.fact .ctl { display: flex; gap: 16px; font-size: 14px; }
.fact .ctl button { background: none; border: 0; padding: 0; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.fact .ctl button[aria-pressed="true"] { font-weight: 600; text-decoration: none; }
.tabs { display: flex; gap: 22px; font-size: 14px; margin-bottom: 20px; }
.tabs button { background: none; border: 0; padding: 4px 0; color: var(--ink-2); cursor: pointer; border-bottom: 2px solid transparent; }
.tabs button[aria-pressed="true"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--ink); }
.choices { display: grid; gap: 16px; }
.choice { display: block; position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice img { aspect-ratio: 16 / 7; object-fit: cover; border-radius: 2px; }
.choice .t { display: flex; justify-content: space-between; align-items: center; padding: 10px 0 12px; border-bottom: 1px solid var(--line); font-size: 18px; font-weight: 600; }
.choice .t::after { content: ""; width: 14px; height: 8px; border-left: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: rotate(-45deg) translateY(-3px); opacity: 0; }
.choice input:checked ~ .t::after { opacity: 1; }
.choice input:checked ~ .t { border-bottom-color: var(--ink); }
.choice input:focus-visible ~ .t { outline: 2px solid var(--ink); outline-offset: 4px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { cursor: pointer; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span { display: inline-block; padding: 10px 14px; border: 1px solid var(--line); border-radius: 2px; background: var(--sheet); font-size: 14px; }
.chip input:checked + span { border-color: var(--ink); background: var(--ink); color: var(--bg); }
.chip input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--ink-2); margin-top: 18px; }
.consent input { margin-top: 3px; }
.done { padding: 40px 0 80px; max-width: 560px; }
.done h1 { font-size: clamp(32px, 4.5vw, 48px); }
.done p { font-size: 17px; color: var(--ink-2); }
.done .num { font-size: 14px; color: var(--ink-2); margin-top: 22px; }
.err { color: #9c2f1f; font-size: 14px; margin-top: 12px; }
.err[hidden] { display: none; }
.list-links { display: grid; gap: 10px; margin-top: 12px; }
.list-links .l { display: flex; gap: 10px; align-items: center; font-size: 14px; }
.list-links .l a { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 860px) {
  .hero, .brief { grid-template-columns: 1fr; gap: 24px; }
  .brief aside { position: static; }
  .live-row, .steps, .cards { grid-template-columns: 1fr; }
  .live-row { gap: 28px; }
  .nav { display: none; }
  .row.two { grid-template-columns: 1fr; }
  .live-cap { font-size: 12px; max-width: 70%; }
  .live.live-on .play { padding: 8px 12px; font-size: 13px; }
  .live-tag { font-size: 11px; padding: 3px 6px; margin-top: -30px; }
  .live-sum { font-size: 13px; padding: 4px 8px; min-width: 0; }
  .live-sum small { font-size: 10px; }
}
