/* Layout: configurator — drawing on the left, options in the middle, sticky price column on the right; stacks on phones.
   Dark-only design built around RAL 7016 anthracite. */
:root {
  --bg: #1b1e21;          /* deep anthracite ground */
  --surface: #25292d;     /* panels */
  --surface-2: #2e3337;   /* inputs, RAL 7016-ish */
  --line: #3b4146;
  --fg: #e8ebed;
  --muted: #9aa2a8;
  --accent: #6db33f;      /* NOVO green (з логотипу): вибір, фокус */
  --cta: #eef0f1;         /* white frame: primary action */
  --cta-fg: #1b1e21;
  --danger: #e08a7a;
  --font-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 10px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 15px/1.5 var(--font-body);
}
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
[hidden] { display: none !important; }

/* Top bar */
.topbar {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner, .wrap {
  max-width: 1320px; margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 12px; }
.brand { display: flex; align-items: center; }
.brand img { height: 40px; width: auto; display: block; }
.brand-mark { width: 22px; height: 22px; border: 3px solid var(--fg); border-radius: 3px; background:
  linear-gradient(var(--fg),var(--fg)) center/3px 100% no-repeat; }
.topbar-actions { display: flex; align-items: center; gap: 12px; }
.lang { display: flex; gap: 4px; }
.lang button { background: none; border: 1px solid var(--line); border-radius: 6px; padding: 4px 8px; cursor: pointer; font-size: 13px; color: var(--muted); }
.lang button[aria-pressed="true"] { color: var(--fg); border-color: var(--fg); }
.cart-btn {
  display: flex; align-items: center; gap: 8px; cursor: pointer;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px;
}
.cart-count { min-width: 22px; height: 22px; display: inline-grid; place-items: center; border-radius: 999px; background: var(--cta); color: var(--cta-fg); font-size: 12px; font-weight: 600; padding: 0 6px; }

/* Intro */
.wrap { padding-block: 28px 64px; }
.intro h1, .intro .calc-title { font: 700 clamp(28px, 4vw, 42px)/1.1 var(--font-display); margin: 0 0 8px; letter-spacing: -.01em; text-wrap: balance; }
.intro p { margin: 0; color: var(--muted); max-width: 60ch; }

/* Template picker */
.templates { display: flex; gap: 10px; margin: 24px 0; overflow-x: auto; padding-bottom: 4px; }
.tpl {
  flex: 0 0 auto; display: grid; justify-items: center; gap: 8px; width: 118px; padding: 14px 8px 10px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer;
  color: var(--muted); font-size: 13px; text-align: center; transition: border-color .15s, color .15s;
}
.tpl svg { width: 44px; height: 44px; }
.tpl:hover { color: var(--fg); }
.tpl[aria-pressed="true"] { border-color: var(--fg); color: var(--fg); background: var(--surface-2); }

/* Main layout */
.layout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) 300px; gap: 20px; align-items: start; }
.stage, .options, .price { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); min-width: 0; }
.stage { padding: 20px; }
.stage-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; }
.stage-head h2 { margin: 0; font: 600 20px/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .06em; }
.stage-hint { color: var(--muted); font-size: 13px; }
.drawing { margin-top: 16px; display: grid; place-items: center; min-height: 320px; }
.drawing svg { width: 100%; max-width: 100%; height: auto; max-height: 520px; }
.drawing .cell { cursor: pointer; }
.drawing .cell:hover .glass { filter: brightness(1.15); }
.dim { font-family: var(--font-body); font-weight: 500; font-variant-numeric: tabular-nums; }

.sash-editor { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 16px; display: grid; gap: 12px; }
.sash-editor h4 { margin: 0; font: 600 14px var(--font-display); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg button {
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 8px; padding: 7px 12px; cursor: pointer; font-size: 13px;
}
.seg button[aria-pressed="true"] { border-color: var(--accent); color: var(--accent); }
.warn { color: var(--danger); font-size: 13px; margin: 0; }

/* Options column */
.options { padding: 20px; display: grid; gap: 22px; }
.opt-group { display: grid; gap: 12px; }
.opt-group h3, .field > span, .carousel h3 {
  margin: 0; font: 600 13px var(--font-display); text-transform: uppercase; letter-spacing: .09em; color: var(--muted);
}
.opt-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 14px; }
.field { display: grid; gap: 6px; }
.field small { color: var(--muted); font-size: 12px; min-height: 1em; }
select, .num input, .order-form input, .order-form textarea {
  width: 100%; background: var(--surface-2); border: 1px solid var(--line); border-radius: 8px; padding: 9px 12px;
}
select { appearance: none; padding-right: 34px; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 55%, calc(100% - 13px) 55%; background-size: 5px 5px; background-repeat: no-repeat; }
.sizes { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.num { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.num input { color: var(--fg); font-variant-numeric: tabular-nums; font-size: 16px; }
.num input[aria-invalid="true"] { border-color: var(--danger); }
.num .err { color: var(--danger); font-size: 12px; }
.hint { margin: 0; color: var(--muted); font-size: 12px; }

.carousel { display: grid; gap: 8px; }
.carousel-row { display: grid; grid-template-columns: 36px 1fr 36px; align-items: center; gap: 8px; }
.carousel-row button.arrow {
  height: 36px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface-2); cursor: pointer; font-size: 18px; line-height: 1;
}
.carousel-val { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 36px; text-align: center; font-size: 14px;
  border-bottom: 1px solid var(--line); padding-bottom: 6px; }
.swatch { width: 18px; height: 18px; border-radius: 4px; border: 1px solid rgba(255,255,255,.25); flex: 0 0 auto; }
.carousel-dots { display: flex; justify-content: center; gap: 5px; }
.carousel-dots span { width: 5px; height: 5px; border-radius: 50%; background: var(--line); }
.carousel-dots span.on { background: var(--fg); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line); background: transparent; border-radius: 8px; padding: 8px 14px; cursor: pointer; font-size: 14px;
  display: inline-flex; align-items: center; gap: 8px;
}
.chip::before { content: ""; width: 14px; height: 14px; border-radius: 4px; border: 1.5px solid var(--muted); }
.chip[aria-pressed="true"] { border-color: var(--fg); background: var(--surface-2); }
.chip[aria-pressed="true"]::before { background: var(--fg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M3 7.5l2.5 2.5L11 4.5' fill='none' stroke='%231b1e21' stroke-width='2'/%3E%3C/svg%3E") center/12px no-repeat; border-color: var(--fg); }

.install { border-top: 1px solid var(--line); padding-top: 18px; }
.radios { display: grid; gap: 8px; }
.radio, .check { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: 14px; }
.radio input, .check input { accent-color: var(--accent); width: 16px; height: 16px; margin: 3px 0 0; flex: 0 0 auto; }

/* Price column */
.price { padding: 20px; position: sticky; top: calc(env(safe-area-inset-top, 0px) + 76px); display: grid; gap: 16px; }
.price-top { display: grid; gap: 2px; }
.price-label { font: 600 13px var(--font-display); text-transform: uppercase; letter-spacing: .09em; color: var(--muted); }
.price-value { font: 700 40px/1.1 var(--font-display); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.price-vat { color: var(--muted); font-size: 13px; }
.price-details summary { cursor: pointer; color: var(--accent); font-size: 14px; }
.price-details ul { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; font-size: 13px; }
.price-details li { display: flex; justify-content: space-between; gap: 12px; color: var(--muted); }
.price-details li b { color: var(--fg); font-weight: 500; font-variant-numeric: tabular-nums; white-space: nowrap; }
.price-actions { display: grid; grid-template-columns: auto 1fr; gap: 10px; }
.qty { display: grid; grid-template-columns: 34px 44px 34px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.qty button { background: var(--surface-2); border: 0; cursor: pointer; font-size: 18px; }
.qty input { width: 100%; text-align: center; background: transparent; border: 0; font-variant-numeric: tabular-nums; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.btn-primary {
  background: var(--cta); color: var(--cta-fg); border: 0; border-radius: 8px; padding: 12px 16px; cursor: pointer;
  font: 600 15px var(--font-display); letter-spacing: .02em;
}
.btn-primary:hover { background: #fff; }
.btn-secondary { background: transparent; color: var(--fg); border: 1px solid var(--line); border-radius: 8px; padding: 11px 16px; cursor: pointer; font-weight: 500; }
.disclaimer { margin: 0; color: var(--muted); font-size: 12px; }

/* Drawer (cart + order form) */
.drawer-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.55); z-index: 40; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 50; width: min(440px, 100%);
  background: var(--surface); border-left: 1px solid var(--line); display: flex; flex-direction: column;
  padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px); padding-right: env(safe-area-inset-right, 0px);
}
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { margin: 0; font: 600 20px var(--font-display); }
.icon-btn { background: none; border: 0; font-size: 28px; line-height: 1; cursor: pointer; color: var(--muted); }
.drawer-body { padding: 20px; overflow-y: auto; display: grid; gap: 16px; align-content: start; flex: 1; }
.cart-item { display: grid; grid-template-columns: 64px 1fr auto; gap: 12px; align-items: start; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.cart-item svg { width: 64px; height: 64px; }
.cart-item h4 { margin: 0 0 2px; font: 600 14px var(--font-display); }
.cart-item p { margin: 0; font-size: 12px; color: var(--muted); }
.cart-item .ci-price { text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; }
.link-btn { background: none; border: 0; padding: 0; color: var(--danger); font-size: 12px; cursor: pointer; margin-top: 4px; }
.totals { display: grid; gap: 6px; font-size: 14px; }
.totals div { display: flex; justify-content: space-between; color: var(--muted); }
.totals div b { color: var(--fg); font-weight: 500; font-variant-numeric: tabular-nums; }
.totals .grand { color: var(--fg); font: 700 22px var(--font-display); border-top: 1px solid var(--line); padding-top: 10px; margin-top: 4px; }
.totals .grand b { font-weight: 700; }
.empty { color: var(--muted); margin: 0; }
.drawer-actions { display: grid; gap: 10px; }

.order-form p.lead { margin: 0; color: var(--muted); font-size: 14px; }
.order-form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.order-form label.f { display: grid; gap: 5px; font-size: 13px; color: var(--muted); }
.order-form .err { color: var(--danger); font-size: 12px; }
.order-form [aria-invalid="true"] { border-color: var(--danger); }
.success { border: 1px solid var(--accent); border-radius: var(--radius); padding: 16px; }
.success p { margin: 0 0 6px; }
.success small { color: var(--muted); }

.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 60;
  background: var(--cta); color: var(--cta-fg); padding: 10px 18px; border-radius: 999px; font-weight: 500; font-size: 14px;
}

/* Responsive */
@media (max-width: 1100px) {
  .layout { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .price { grid-column: 1 / -1; position: static; grid-template-columns: 1fr auto; align-items: center; }
  .price-details, .disclaimer { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
  .price {
    position: sticky; bottom: 0; top: auto; z-index: 15; grid-template-columns: 1fr; gap: 10px;
    border-radius: var(--radius) var(--radius) 0 0;
    padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -10px 30px rgba(0,0,0,.35);
  }
  .price-value { font-size: 28px; }
  .price-label { display: none; }
  .price-details summary { font-size: 13px; }
  .disclaimer { display: none; }
  .drawing { min-height: 240px; }
  .stage, .options { padding: 16px; }
  .order-form .row { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---------- Профілі та склопакети (верх сторінки): стрічка карток ---------- */
#calc { scroll-margin-top: 64px; }
.showcase { border-bottom: 1px solid var(--line); }
.sc-inner { max-width: 1320px; margin: 0 auto; padding-block: 24px 28px; display: grid; gap: 16px; }
.sc-head {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.sc-title { margin: 0; font: 600 15px var(--font-display); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); }
.sc-tabs { display: inline-flex; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 999px; }
.sc-tab { background: none; border: 0; border-radius: 999px; padding: 5px 14px; cursor: pointer; color: var(--muted); font-size: 13px; font-weight: 500; }
.sc-tab[aria-selected="true"] { background: var(--surface-2); color: var(--fg); }

.sc-strip {
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 40px, #000 calc(100% - 40px), transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 40px, #000 calc(100% - 40px), transparent 100%);
}
.sc-strip::-webkit-scrollbar { display: none; }
.sc-strip:focus-visible { outline-offset: -2px; }
.sc-row { display: flex; gap: 16px; width: max-content; padding: 2px 16px; }
.sc-card {
  width: 272px; flex: 0 0 auto; display: grid; grid-template-rows: auto 1fr;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden;
}
.sc-card-img { height: 180px; display: grid; place-items: center; padding: 8px; background: var(--surface-2); }
.sc-card-img svg { width: 100%; height: 100%; }
.sc-card-img .sc-photo { width: 100%; height: 100%; object-fit: contain; }
.sheet-visual .sc-photo { width: 100%; height: auto; max-height: 380px; object-fit: contain; display: block; border-radius: 10px; }
.sc-source { color: var(--muted); font-size: 12px; }
.sc-source:hover { color: var(--fg); }
.sc-card-body { padding: 14px 16px 16px; display: grid; gap: 8px; align-content: start; }
.sc-card-name { margin: 0; font: 600 17px/1.25 var(--font-display); }
.sc-card-desc { margin: 0; color: var(--muted); font-size: 13px; min-height: 2.6em; }
.sc-card-specs { margin: 0; display: grid; gap: 4px; font-size: 13px; }
.sc-card-specs div { display: flex; align-items: baseline; gap: 6px; }
.sc-card-specs dt { color: var(--muted); white-space: nowrap; }
.sc-card-specs div::after { content: none; }
.sc-card-specs dd { margin: 0 0 0 auto; font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.sc-card-specs dt::after { content: ""; display: inline-block; }
.sc-card-specs div > dt { flex: 0 0 auto; }
.sc-card-specs div { background: radial-gradient(circle, var(--line) 1px, transparent 1.2px) 0 calc(100% - 4px) / 6px 6px repeat-x; }
.sc-card-specs dt, .sc-card-specs dd { background: var(--surface); }
.sc-card-specs dt { padding-right: 6px; } .sc-card-specs dd { padding-left: 6px; }
.sc-more {
  justify-self: start; margin-top: 4px; background: transparent; color: var(--fg); border: 1px solid var(--line);
  border-radius: 8px; padding: 7px 14px; cursor: pointer; font-size: 13px; font-weight: 500;
}
.sc-more:hover { border-color: var(--fg); }

/* Вікно «Деталі» */
html.sheet-lock { overflow: hidden; }
.sheet-backdrop { position: fixed; inset: 0; z-index: 70; background: rgba(0, 0, 0, .55); opacity: 0; transition: opacity .3s; }
.sheet-backdrop.open { opacity: 1; }
.sheet {
  position: fixed; left: 50%; bottom: 0; z-index: 80; width: min(760px, 100%); max-height: 90vh; max-height: 90dvh;
  translate: -50% 0; transform: translateY(100%); transition: transform .32s cubic-bezier(.2, .8, .2, 1);
  display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-bottom: 0;
  border-radius: 18px 18px 0 0; box-shadow: 0 -20px 60px rgba(0, 0, 0, .5);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.sheet.open { transform: translateY(0); }
.sheet.dragging { transition: none; }
.sheet-grip { display: grid; place-items: center; padding: 10px 0 2px; cursor: grab; touch-action: none; }
.sheet-grip span { width: 42px; height: 5px; border-radius: 3px; background: var(--line); }
.sheet-top { display: flex; align-items: center; justify-content: space-between; padding: 4px 16px 4px 20px; touch-action: none; }
.sheet-close { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface-2); cursor: pointer; font-size: 22px; line-height: 1; color: var(--fg); }
.sheet-body { overflow-y: auto; overscroll-behavior: contain; padding: 8px 20px 24px; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 20px; align-items: center; }
.sheet-visual { touch-action: none; min-width: 0; }
.sheet-visual svg { width: 100%; height: auto; max-height: 380px; display: block; }
.sheet-info { display: grid; gap: 12px; min-width: 0; }
.sc-class { justify-self: start; font: 600 11px var(--font-display); text-transform: uppercase; letter-spacing: .12em; color: var(--muted);
  border: 1px solid var(--line); border-radius: 999px; padding: 4px 10px; }
.sc-name { margin: 0; font: 700 24px/1.15 var(--font-display); }
.sc-desc { margin: 0; color: var(--muted); font-size: 14px; }
.sc-specs { margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px 16px; }
.sc-specs div { display: grid; gap: 2px; border-top: 1px solid var(--line); padding-top: 6px; }
.sc-specs dt { font-size: 12px; color: var(--muted); }
.sc-specs dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.sc-rate { display: grid; grid-template-columns: 110px 1fr; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); }
.sc-rate-bar { display: flex; gap: 4px; }
.sc-rate-bar i { width: 13px; height: 13px; border: 1.5px solid var(--muted); border-radius: 2px; }
.sc-rate-bar i.on { background: var(--fg); border-color: var(--fg); }
.sc-pick { justify-self: start; margin-top: 4px; background: var(--cta); color: var(--cta-fg); border: 0; border-radius: 8px; padding: 11px 18px; cursor: pointer; font-weight: 600; }
.sc-pick[aria-pressed="true"] { background: transparent; color: var(--accent); border: 1px solid var(--accent); }

/* «Збирання» креслення у вікні «Деталі» */
.sc-svg .pa { transform-box: view-box; }
.sheet.open .pa-frame { animation: sc-in-up .8s .1s cubic-bezier(.2, .7, .2, 1) both; }
.sheet.open .pa-sash  { animation: sc-in-down .8s .2s cubic-bezier(.2, .7, .2, 1) both; }
.sheet.open .pa-glass { animation: sc-in-glass .9s .32s cubic-bezier(.2, .7, .2, 1) both; }
.sheet.open .pa-lbl   { animation: sc-fade .5s .8s ease both; }
@keyframes sc-in-up    { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes sc-in-down  { from { transform: translateY(-40px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes sc-in-glass { from { transform: translateY(-80px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes sc-fade     { from { opacity: 0; } to { opacity: 1; } }

@media (max-width: 680px) {
  .sc-card { width: 240px; }
  .sc-card-img { height: 150px; }
  .sheet-body { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .sheet-visual svg { max-height: 280px; }
  .sc-name { font-size: 21px; }
}
@media (prefers-reduced-motion: reduce) {
  .sheet, .sheet-backdrop { transition: none; }
  .sheet .pa { animation: none !important; }
}

/* ---------- 3D-вступ (intro.js) ---------- */
.intro3d { position: relative; height: 250vh; background: #2a2e32; --copy: 0; --room: 0; --room-b: 24px; --logo: 0; --logo-s: .92; --logo-b: 10px; --title: 0; }
.intro3d.is-static { height: 100vh; }
.intro3d.is-sharp .intro3d-canvas { filter: none; }
.cut.is-sharp .cut-profile { filter: none; }
.intro3d { --out: 0; }
.intro3d-stage {
  position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden;
  transform: scale(calc(1 - .08 * var(--out))); border-radius: calc(28px * var(--out)); transform-origin: 50% 40%;
}
.intro3d-canvas {
  position: absolute; inset: 0; width: 100%; height: 100%; display: block;
  opacity: var(--room); filter: blur(var(--room-b)) brightness(calc(.35 + .65 * var(--room)));
}
/* лого на антрацитовому екрані під час відкриття */
.intro3d-logo {
  position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none;
  opacity: var(--logo); transform: scale(var(--logo-s)); filter: blur(var(--logo-b));
}
.intro3d-logo img { width: min(46vw, 340px); height: auto; }
/* заголовок поверх кімнати, зникає з першим скролом */
.intro3d-open {
  position: absolute; left: 0; right: 0; bottom: clamp(88px, 14vh, 140px);
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  display: grid; justify-items: center; gap: 10px; text-align: center;
  opacity: var(--title); transform: translateY(calc((1 - var(--title)) * 20px));
  pointer-events: none; text-shadow: 0 2px 24px rgba(0,0,0,.55);
}
.intro3d-open > * { margin: 0; }
.intro3d-open-title { font: 700 clamp(34px, 5vw, 68px)/1 var(--font-display); letter-spacing: -.03em; text-wrap: balance; max-width: 20ch; }
.intro3d-open-sub { color: #d5dadd; max-width: 44ch; font-size: clamp(15px, 1.3vw, 18px); }
.intro3d-shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(15,17,19,calc(.6 * var(--copy))) 0%, transparent 30%),
    linear-gradient(to top, rgba(15,17,19,calc(.55 * var(--copy))) 0%, transparent 30%),
    linear-gradient(to top, rgba(15,17,19,calc(.65 * var(--title))) 0%, transparent 50%),
    linear-gradient(to top, var(--bg) 0%, rgba(27,30,33,0) 22%);
}
.intro3d-copy {
  position: absolute; inset: clamp(76px, 11vh, 110px) 0 clamp(64px, 9vh, 96px);
  padding-inline: max(16px, env(safe-area-inset-left, 0px));
  text-align: center; display: flex; flex-direction: column; justify-content: space-between; align-items: center;
  opacity: var(--copy); pointer-events: none;
}
.intro3d-top, .intro3d-bottom { display: grid; justify-items: center; gap: 10px; }
.intro3d-top { transform: translateY(calc((1 - var(--copy)) * -24px)); }
.intro3d-bottom { transform: translateY(calc((1 - var(--copy)) * 28px)); }
.intro3d-copy * { margin: 0; }
.intro3d-copy > * { margin: 0; }
.intro3d-kicker { font: 600 13px var(--font-display); letter-spacing: .18em; text-transform: uppercase; color: var(--accent); }
.intro3d-title { font: 700 clamp(30px, 4.4vw, 60px)/1.05 var(--font-display); letter-spacing: -.02em; text-wrap: balance; max-width: 24ch; text-shadow: 0 2px 24px rgba(0,0,0,.45); }
.intro3d-sub { color: #d5dadd; max-width: 46ch; font-size: clamp(15px, 1.4vw, 18px); text-shadow: 0 1px 12px rgba(0,0,0,.5); }
.intro3d-cta { margin-top: 6px; border-radius: 999px; padding: 12px 22px; text-decoration: none; }
.intro3d-cta { pointer-events: auto; }
.intro3d:not(.copy-on):not(.is-static) .intro3d-cta { visibility: hidden; }
.intro3d-hint {
  position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%);
  display: grid; justify-items: center; gap: 8px; color: #e8ebed; font-size: 13px; letter-spacing: .06em;
  opacity: var(--title); text-shadow: 0 1px 8px rgba(0,0,0,.6);
}
.intro3d-hint i { width: 1px; height: 34px; background: linear-gradient(#fff, transparent); animation: hintDrop 1.8s ease-in-out infinite; transform-origin: top; }
@keyframes hintDrop { 0% { transform: scaleY(0); opacity: 1; } 70% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }
.intro3d.is-static .intro3d-copy { opacity: 1; transform: none; pointer-events: auto; }
.intro3d.is-static .intro3d-hint, .intro3d.is-static .intro3d-open, .intro3d.is-static .intro3d-logo { display: none; }
.intro3d.is-static { --room: 1; --room-b: 0px; }

/* Поява блоків при скролі, прив'язана до прокрутки (intro.js ставить --p від 0 до 1) */
.scrub { --p: 1; }
.scrub-up { opacity: var(--p); transform: translateY(calc((1 - var(--p)) * 70px)); will-change: transform, opacity; }
.scrub-zoom { opacity: calc(.2 + .8 * var(--p)); transform: translateY(calc((1 - var(--p)) * 90px)) scale(calc(.92 + .08 * var(--p))); transform-origin: 50% 0; will-change: transform; }
.scrub-fan .sc-card {
  transform: translateX(calc((1 - var(--p)) * var(--fx, 0px))) rotate(calc((1 - var(--p)) * var(--fr, 0deg))) scale(calc(.9 + .1 * var(--p)));
  opacity: calc(.15 + .85 * var(--p));
}
@media (prefers-reduced-motion: reduce) { .scrub, .scrub .sc-card { transform: none !important; opacity: 1 !important; } }

/* ---------- Перехід "вікно → розріз профілю" (story.js) ---------- */
.cut { position: relative; height: 220vh; --spin: 0; --txt: 0; }
.cut.is-static { height: auto; --spin: 1; --txt: 1; }
.cut-stage {
  position: sticky; top: 0; min-height: 100vh; min-height: 100svh; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); align-items: center; gap: clamp(16px, 4vw, 64px);
  max-width: 1320px; margin: 0 auto; padding-block: 88px 40px;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.cut.is-static .cut-stage { position: static; }
.cut-copy { display: grid; gap: 14px; align-content: center; min-width: 0;
  opacity: var(--txt); transform: translateY(calc((1 - var(--txt)) * 40px)); }
.cut-copy > * { margin: 0; }
.cut-kicker { font: 600 13px var(--font-display); letter-spacing: .18em; text-transform: uppercase; color: var(--accent); }
.cut-title { font: 700 clamp(28px, 3.6vw, 52px)/1.05 var(--font-display); letter-spacing: -.02em; text-wrap: balance; }
.cut-lead { color: var(--muted); max-width: 44ch; }
.cut-points { list-style: none; padding: 0; display: grid; gap: 4px; margin-top: 8px !important; }
.cut-points li {
  --pi: 0; display: grid; gap: 2px; padding: 12px 0 12px 18px; border-left: 2px solid var(--line); position: relative;
  opacity: calc(.15 + .85 * var(--pi)); transform: translateX(calc((1 - var(--pi)) * 24px));
}
.cut-points li::before { content: ""; position: absolute; left: -2px; top: 0; bottom: 0; width: 2px; background: var(--accent); transform: scaleY(var(--pi)); transform-origin: top; }
.cut-points b { font: 600 17px var(--font-display); }
.cut-points span { color: var(--muted); font-size: 14px; }
.cut.is-static .cut-points li { --pi: 1; }

.cut-visual { position: relative; height: min(72vh, 640px); perspective: 1400px; min-width: 0; }
.cut-3d { position: absolute; inset: 0; transform-style: preserve-3d; }
.cut-profile {
  position: absolute; left: 50%; top: 50%; max-width: none; height: min(100%, 640px); width: auto; aspect-ratio: 1;
  will-change: transform, opacity, filter;
  /* кадри відео обертання (story.js); краї кадрів уже розчинені у колір фону */
  transform: translate(-50%, -50%) scale(calc(.86 + .14 * var(--spin)));
  opacity: clamp(0, calc((var(--spin) - .06) * 3.2), 1);
  filter: blur(calc(max(0, 1 - var(--spin) * 2.6) * 10px));
}
/* м'яке світло за профілем, коли він зупиняється */
.cut-3d::before {
  content: ""; position: absolute; left: 50%; top: 50%; width: 70%; aspect-ratio: 1; translate: -50% -50%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(109,179,63,.16), transparent 70%);
  opacity: var(--spin); pointer-events: none;
}
@media (max-width: 820px) {
  .cut { height: 240vh; }
  .cut-stage { grid-template-columns: minmax(0, 1fr); align-content: start; gap: 8px; padding-block: 76px 24px; }
  .cut-visual { order: -1; height: 42vh; }
  .cut-profile { height: 100%; }
  .cut-title { font-size: 26px; }
  .cut-lead { display: none; }
  .cut-points { grid-template-columns: 1fr 1fr; gap: 6px 12px; }
  .cut-points li { padding: 8px 0 8px 12px; }
  .cut-points b { font-size: 15px; }
  .cut-points span { font-size: 12.5px; }
}

/* ---------- Переваги ---------- */
.perks { border-block: 1px solid var(--line); background: #1f2326; }
.perks-inner {
  max-width: 1320px; margin: 0 auto; padding-block: 36px;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px;
}
.perk { display: grid; gap: 6px; align-content: start; }
.perk svg { width: 30px; height: 30px; fill: none; stroke: var(--accent); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 6px; }
.perk h3 { margin: 0; font: 600 17px var(--font-display); }
.perk p { margin: 0; color: var(--muted); font-size: 14px; }
@media (max-width: 900px) { .perks-inner { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 460px) { .perks-inner { grid-template-columns: minmax(0, 1fr); gap: 20px; } }

/* ---------- Як ми працюємо ---------- */
.steps-inner {
  max-width: 1320px; margin: 0 auto; padding-block: 72px;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  display: grid; gap: 32px;
}
.steps-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 16px; }
.steps-head h2 { margin: 0; font: 700 clamp(28px, 3.4vw, 44px)/1.05 var(--font-display); letter-spacing: -.02em; }
.steps-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; counter-reset: s; }
.steps-list li { display: grid; gap: 8px; align-content: start; padding: 20px 24px 0 0; border-top: 1px solid var(--line); position: relative; }
.steps-list li::before { content: ""; position: absolute; top: -1px; left: 0; width: 40px; height: 2px; background: var(--accent); }
.steps-n { font: 600 13px var(--font-display); color: var(--muted); font-variant-numeric: tabular-nums; }
.steps-list h3 { margin: 0; font: 600 20px var(--font-display); }
.steps-list p { margin: 0; color: var(--muted); font-size: 14px; max-width: 30ch; }
@media (max-width: 900px) { .steps-list { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 28px; } }
@media (max-width: 460px) { .steps-list { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Футер ---------- */
.foot { border-top: 1px solid var(--line); background: #16191b; }
.foot-inner {
  max-width: 1320px; margin: 0 auto; padding-block: 40px calc(40px + env(safe-area-inset-bottom, 0px));
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 40px; align-items: start;
}
.foot-brand { display: grid; gap: 10px; }
.foot-brand img { height: 44px; width: auto; }
.foot-brand p, .foot-copy { margin: 0; color: var(--muted); font-size: 14px; }
.foot-nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.foot-nav a, .linkish { color: var(--fg); text-decoration: none; font-size: 14px; }
.foot-nav a:hover, .linkish:hover { color: var(--accent); }
.foot-copy { grid-column: 1 / -1; font-size: 13px; }
@media (max-width: 700px) { .foot-inner { grid-template-columns: minmax(0, 1fr); } }
.linkish { background: none; border: 0; padding: 0; cursor: pointer; font: inherit; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line); }
.hint .linkish { color: var(--accent); font-size: 12px; text-decoration-color: currentColor; }
.foot-nav .linkish { text-decoration: none; }

/* ---------- Вікно "Як заміряти вікно" ---------- */
.measure {
  width: min(760px, calc(100% - 24px)); max-height: min(88vh, 900px); padding: 0; border: 1px solid var(--line); border-radius: 18px;
  background: var(--surface); color: var(--fg); box-shadow: 0 40px 120px rgba(0,0,0,.6);
}
.measure[open] { display: flex; flex-direction: column; animation: mIn .35s cubic-bezier(.2,.8,.2,1); }
.measure::backdrop { background: rgba(0,0,0,.6); backdrop-filter: blur(4px); }
@keyframes mIn { from { opacity: 0; transform: translateY(24px) scale(.98); } }
.measure-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 20px 10px; }
.measure-head h2 { margin: 0; font: 700 24px var(--font-display); }
.measure-body { overflow-y: auto; padding: 0 20px 22px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
.measure-lead, .measure-note, .measure-body > .btn-primary { grid-column: 1 / -1; margin: 0; }
.measure-lead { color: var(--muted); }
.measure-note { color: var(--muted); font-size: 13px; border-left: 2px solid var(--accent); padding-left: 12px; }
.measure-body > .btn-primary { justify-self: start; border-radius: 999px; padding: 11px 22px; }
.measure-step { margin: 0; display: grid; gap: 10px; background: var(--surface-2); border-radius: 12px; padding: 14px; }
.measure-step svg { width: 100%; height: auto; display: block; }
.measure-step figcaption { display: grid; gap: 3px; font-size: 13.5px; }
.measure-step figcaption b { font: 600 15px var(--font-display); }
.measure-step figcaption span { color: var(--muted); }
.m-wall { fill: #4a4f53; }
.m-hole { fill: #1b1e21; stroke: #6b7277; stroke-width: 1.5; }
.m-win { fill: none; stroke: #9aa2a8; stroke-width: 3; }
.m-arrow path { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.m-t { fill: var(--fg); font: 600 12px var(--font-body); text-anchor: middle; }
.m-s { fill: var(--muted); font: 500 10px var(--font-body); text-anchor: middle; }
@media (max-width: 560px) { .measure-body { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Шапка: кнопка розрахунку, кошик, бургер ---------- */
.topbar-actions { gap: 10px; }
.lang button { min-height: 32px; min-width: 36px; transition: color .15s, border-color .15s; }
.lang button:hover { color: var(--fg); }
.cart-btn { min-height: 40px; transition: border-color .15s; }
.cart-btn:hover { border-color: var(--muted); }
.top-cta { border-radius: 999px; padding: 10px 18px; text-decoration: none; font-size: 14px; white-space: nowrap; transition: background .15s; }
.burger {
  width: 44px; height: 44px; display: grid; place-content: center; gap: 5px; flex: 0 0 auto;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px; cursor: pointer; transition: border-color .15s;
}
.burger:hover { border-color: var(--muted); }
.burger span { display: block; width: 18px; height: 2px; border-radius: 2px; background: var(--fg); }
.burger span:nth-child(2) { width: 12px; justify-self: end; }
.visually-hidden, .cart-btn .vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 980px) { .top-cta { display: none; } }
/* Вузький екран: мови переїжджають у бургер-меню, кошик лише іконкою з лічильником */
@media (max-width: 600px) {
  .lang-top { display: none; }
  .cart-btn [data-i18n="nav.cart"] { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .cart-btn { min-height: 44px; padding: 7px 12px; }
}

/* ---------- Бургер-меню (бокова панель) ---------- */
.menu {
  margin: 0 0 0 auto; height: 100%; max-height: none; max-width: 100%; width: min(420px, 100%); padding: 0; border: 0; border-left: 1px solid var(--line);
  background: var(--surface); color: var(--fg); box-shadow: -30px 0 80px rgba(0,0,0,.5);
  padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px);
}
.menu[open] { display: flex; flex-direction: column; animation: menuIn .32s cubic-bezier(.2,.8,.2,1); }
.menu::backdrop { background: rgba(0,0,0,.55); backdrop-filter: blur(4px); }
@keyframes menuIn { from { transform: translateX(40px); opacity: 0; } }
.menu-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 8px 24px; }
.menu-title { margin: 0; font: 600 13px var(--font-display); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.menu .sheet-close { width: 44px; height: 44px; }
.menu-nav { display: grid; padding: 4px 12px; overflow-y: auto; flex: 1; align-content: start; }
.menu-nav a, .menu-nav button {
  display: grid; gap: 2px; text-align: left; padding: 14px 12px; border-radius: 12px; text-decoration: none; color: var(--fg);
  background: none; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; cursor: pointer; font: inherit; transition: background .15s;
}
.menu-nav a:hover, .menu-nav button:hover { background: var(--surface-2); }
.menu-nav span { font: 600 20px/1.2 var(--font-display); letter-spacing: -.01em; }
.menu-nav small { color: var(--muted); font-size: 13.5px; }
.menu-foot { display: grid; gap: 14px; padding: 16px 24px 24px; border-top: 1px solid var(--line); }
.menu-foot .lang button { min-height: 44px; min-width: 52px; font-size: 14px; }
.menu-foot .btn-primary { text-align: center; text-decoration: none; border-radius: 999px; padding: 14px 18px; }
@media (prefers-reduced-motion: reduce) { .menu[open] { animation: none; } }

/* ---------- Про нас ---------- */
.about { border-top: 1px solid var(--line); background: linear-gradient(#1f2326, var(--bg) 60%); scroll-margin-top: 64px; }
.about-inner {
  max-width: 1320px; margin: 0 auto; padding-block: 80px;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  display: grid; gap: 40px;
}
.about-head { display: grid; gap: 12px; max-width: 760px; }
.about-head > * { margin: 0; }
.about-kicker { font: 600 13px var(--font-display); letter-spacing: .18em; text-transform: uppercase; color: var(--accent); }
.about-head h2 { font: 700 clamp(28px, 3.6vw, 48px)/1.06 var(--font-display); letter-spacing: -.02em; text-wrap: balance; }
.about-lead { color: var(--muted); font-size: 16.5px; max-width: 62ch; }
.about-stats { margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-block: 1px solid var(--line); }
.about-stats div { display: grid; gap: 4px; padding: 22px 20px 22px 0; }
.about-stats div + div { border-left: 1px solid var(--line); padding-left: 20px; }
.about-stats dt { font: 700 clamp(28px, 3vw, 40px)/1 var(--font-display); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.about-stats dd { margin: 0; color: var(--muted); font-size: 14px; }
.about-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.about-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px; display: grid; gap: 8px; align-content: start; }
.about-card h3 { margin: 0; font: 600 18px var(--font-display); }
.about-card p { margin: 0; color: var(--muted); font-size: 14.5px; }
.about-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.about-cta .btn-primary { border-radius: 999px; padding: 13px 22px; text-decoration: none; }
.about-cta .btn-secondary { border-radius: 999px; padding: 12px 22px; }
.about-source { margin: -16px 0 0; color: var(--muted); font-size: 12.5px; }
@media (max-width: 900px) {
  .about-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about-stats div:nth-child(3) { border-left: 0; padding-left: 0; }
  .about-stats div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .about-cols { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 460px) { .about-inner { padding-block: 56px; gap: 28px; } .about-stats div { padding: 16px 12px 16px 0; } .about-stats div + div { padding-left: 12px; } }

/* ---------- Дрібні покращення з огляду ---------- */
.foot-nav a, .foot-nav .linkish { display: inline-flex; align-items: center; min-height: 40px; }
.hint .linkish { padding-block: 4px; }
.sc-tab { min-height: 36px; }
.m-s { font-size: 11px; }
#showcase, #steps, #cut { scroll-margin-top: 64px; }
a, button, summary, select, label.check, label.radio { -webkit-tap-highlight-color: transparent; }
.btn-primary { transition: background .15s, transform .15s; }
.btn-primary:active, .btn-secondary:active, .burger:active, .cart-btn:active { transform: scale(.97); }

/* ---------- Форма заявки: надсилання ---------- */
.order-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-error { margin: 0; color: var(--danger); font-size: 14px; border-left: 2px solid var(--danger); padding-left: 10px; }
.order-form button[disabled] { opacity: .6; cursor: progress; }

/* ---------- Форма заявки: зручний час, фото; кнопка WhatsApp ---------- */
.order-form .photos { display: grid; gap: 8px; }
.photos-hint { color: var(--muted); font-size: 12px; margin-top: -4px; }
.photo-list { display: flex; flex-wrap: wrap; gap: 8px; }
.photo-thumb { position: relative; width: 76px; height: 76px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-thumb button { position: absolute; top: 3px; right: 3px; width: 26px; height: 26px; border-radius: 50%; border: 0; background: rgba(0,0,0,.7); color: #fff; cursor: pointer; font-size: 17px; line-height: 1; }
.photo-add { width: 76px; height: 76px; border: 1px dashed var(--muted); border-radius: 8px; background: var(--surface-2); color: var(--fg); cursor: pointer; display: grid; place-content: center; gap: 2px; text-align: center; font-size: 11px; padding: 4px; }
.photo-add:hover { border-color: var(--fg); }
.photo-add span { font-size: 22px; line-height: 1; }
.photo-add b { font-weight: 500; }
.photo-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.wa-link { display: inline-flex; align-items: center; gap: 8px; justify-self: start; min-height: 40px; color: var(--fg); font-size: 14px; text-decoration: none; }
.wa-link svg { color: #25d366; }
.wa-link:hover span { text-decoration: underline; text-underline-offset: 3px; }
.wa-fab {
  position: fixed; z-index: 30; right: max(16px, env(safe-area-inset-right, 0px)); bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px 12px 14px; border-radius: 999px;
  background: #25d366; color: #0b1f12; font: 600 14px var(--font-display); text-decoration: none;
  box-shadow: 0 10px 30px rgba(0,0,0,.4); transition: transform .15s, box-shadow .15s;
}
.wa-fab:hover { transform: translateY(-2px); box-shadow: 0 14px 34px rgba(0,0,0,.45); }
.wa-fab svg { width: 24px; height: 24px; flex: 0 0 auto; }
@media (max-width: 760px) {
  .wa-fab { padding: 0; width: 52px; height: 52px; justify-content: center; bottom: calc(176px + env(safe-area-inset-bottom, 0px)); }
  .wa-fab span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .wa-fab svg { width: 28px; height: 28px; }
}
@media (prefers-reduced-motion: reduce) { .wa-fab { transition: none; } }

/* ---------- Форма заявки: зручний час (галочка + варіанти) ---------- */
.calltime { margin: 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-2); display: grid; gap: 10px; }
.calltime legend { padding: 0 6px; margin-left: -6px; font-size: 13px; color: var(--fg); font-weight: 600; }
.calltime-any { font-size: 14px; }
.calltime-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.calltime-opt { position: relative; cursor: pointer; }
.calltime-opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.calltime-opt span { display: inline-flex; align-items: center; min-height: 38px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; font-size: 13.5px; background: var(--surface); }
.calltime-opt input:checked + span { border-color: var(--accent); color: var(--accent); }
.calltime-opt input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Коротка заявка: необовʼязкове за кнопками «+ …» ---------- */
.opt-secs { display: grid; gap: 16px; }
.opt-secs:empty { display: none; }
.opt-sec { display: grid; gap: 12px; animation: undoIn .25s ease; }
.form-more { margin: 4px 0 -6px; color: var(--muted); font-size: 13px; }
.add-row { display: flex; flex-wrap: wrap; gap: 8px; }
.add-chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 8px 14px; cursor: pointer;
  background: transparent; color: var(--fg); border: 1px dashed var(--muted); border-radius: 999px; font-size: 14px;
  transition: border-color .15s, background .15s;
}
.add-chip:hover { border-color: var(--fg); background: var(--surface-2); }
.add-chip span { color: var(--accent); font-size: 18px; line-height: 1; font-weight: 600; }
.add-chip b { font-weight: 500; }
@keyframes undoIn { from { opacity: 0; transform: translateY(-6px); } }
@media (prefers-reduced-motion: reduce) { .opt-sec { animation: none; } }

/* ---------- Вступ без скролу: камера відʼїжджає сама, секція займає один екран ---------- */
.intro3d { height: 100vh; height: 100svh; }
.intro3d-stage { position: relative; transform: none; border-radius: 0; }
.intro3d-logo, .intro3d-open { display: none; }

/* ---------- Заявка без розрахунку (над калькулятором) ---------- */
.quick-lead {
  margin-top: 14px; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 10px 18px; cursor: pointer;
  background: transparent; color: var(--fg); border: 1px solid var(--accent); border-radius: 999px; font: 600 14.5px var(--font-display);
  transition: background .15s;
}
.quick-lead svg { color: var(--accent); }
.quick-lead:hover { background: rgba(109,179,63,.12); }

/* ---------- Розріз профілю: коротший скрол, пункти зʼявляються разом ---------- */
.cut { height: 170vh; }
@media (max-width: 820px) { .cut { height: 180vh; } }
.cut-points li { opacity: 0; transform: translateX(24px); transition: opacity .5s ease, transform .5s ease; }
.cut-points li::before { transform: scaleY(0); transition: transform .5s ease; }
.cut.pts-in .cut-points li, .cut.is-static .cut-points li { opacity: 1; transform: none; }
.cut.pts-in .cut-points li::before, .cut.is-static .cut-points li::before { transform: scaleY(1); }
.cut-points li:nth-child(2), .cut-points li:nth-child(2)::before { transition-delay: .08s; }
.cut-points li:nth-child(3), .cut-points li:nth-child(3)::before { transition-delay: .16s; }
.cut-points li:nth-child(4), .cut-points li:nth-child(4)::before { transition-delay: .24s; }
@media (prefers-reduced-motion: reduce) { .cut-points li, .cut-points li::before { transition: none; } }

/* Телефон: поля вводу 16px, інакше iPhone сам збільшує сторінку при натисканні на поле. */
@media (max-width: 760px) {
  select, .num input, .qty input, .order-form input, .order-form textarea { font-size: 16px; }
}
/* Кнопки, які легко натиснути пальцем (мінімум ~40px). */
@media (pointer: coarse) {
  .lang button { min-height: 36px; min-width: 40px; }
  .sc-tab { min-height: 36px; }
}
