/* Зона барбекю – стили. Цвета: графит и сажа, жар, известковый раствор. */
:root {
  --soot: #1e2228;
  --soot-2: #282d35;
  --soot-3: #333a44;
  --sheet: #23272e;
  --ink: #1b1d21;
  --muted: #5b6068;
  --mortar: #ecebe8;
  --paper: #f8f7f5;
  --line: #d7d4cf;
  --ember: #e5823f;
  --ember-hi: #f09654;
  --ember-ink: #a3462a;
  --on-dark: #f2eee8;
  --on-dark-muted: #aaa49c;
  --focus: #ffb36b;
  --r-s: 4px;
  --r-m: 10px;
  --wrap: 1240px;
  --gut: clamp(16px, 4vw, 40px);
  --f-display: 'Dela Gothic One', 'Arial Black', system-ui, sans-serif;
  --f-text: 'Onest', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; }
body { margin: 0; font-family: var(--f-text); font-size: 17px; line-height: 1.55; color: var(--ink); background: var(--mortar); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ember-ink); text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--ember); color: #1b1d21; padding: 10px 16px; border-radius: var(--r-s); z-index: 50; font-weight: 600; }
.skip:focus { top: 12px; }

/* ---------- шапка ---------- */
.top { background: var(--soot); color: var(--on-dark); }
.top-row { display: flex; align-items: center; gap: 24px; min-height: 76px; padding-top: 10px; padding-bottom: 10px; }
.brand { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; margin-right: auto; }
.brand svg { width: 42px; height: 42px; flex: none; }
.brand-name { font-family: var(--f-display); font-size: 21px; line-height: 1; letter-spacing: 0.01em; }
.brand-sub { display: block; font-size: 13px; color: var(--on-dark-muted); margin-top: 5px; }
.nav { display: flex; gap: 22px; font-size: 15px; }
.nav a { color: var(--on-dark); text-decoration: none; opacity: 0.86; }
.nav a:hover { opacity: 1; text-decoration: underline; }
.phones { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; }
.phones a { color: var(--on-dark); text-decoration: none; font-weight: 600; font-size: 16px; white-space: nowrap; }
.phones a:hover { color: var(--ember-hi); }
.phones span { font-size: 12px; color: var(--on-dark-muted); }
@media (max-width: 1080px) { .nav { display: none; } }
@media (max-width: 640px) {
  .top-row { min-height: 64px; gap: 12px; }
  .brand svg { width: 34px; height: 34px; }
  .brand-name { font-size: 17px; }
  .brand-sub { font-size: 12px; }
  .phones a + a, .phones span { display: none; }
  .phones a { font-size: 15px; }
  .brand-sub { display: none; }
  .brand { gap: 10px; }
}

/* ---------- калькулятор (первый экран) ---------- */
.calc { background: var(--soot); color: var(--on-dark); padding: 28px 0 56px; }
.calc-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 40px; align-items: end; margin-bottom: 26px; }
.calc h1 { font-family: var(--f-display); font-weight: 400; font-size: clamp(30px, 4.3vw, 54px); line-height: 1.06; margin: 0; max-width: 15ch; letter-spacing: 0.005em; }
.calc-lead { color: var(--on-dark-muted); margin: 14px 0 0; max-width: 56ch; font-size: 17px; }
.calc-lead b { color: var(--on-dark); font-weight: 600; }
.tabs { display: inline-flex; background: var(--soot-2); border-radius: var(--r-m); padding: 4px; gap: 2px; flex-wrap: wrap; }
.tab { border: 0; background: none; color: var(--on-dark-muted); padding: 10px 16px; border-radius: 7px; cursor: pointer; font-weight: 600; font-size: 15px; }
.tab:hover { color: var(--on-dark); }
.tab[aria-selected="true"] { background: var(--on-dark); color: var(--ink); }
@media (max-width: 860px) { .calc-head { grid-template-columns: 1fr; } .tabs { width: 100%; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); } .tab { padding: 10px 6px; } }
@media (max-width: 560px) { .tabs { grid-template-columns: 1fr 1fr; } }

.calc-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(320px, 1fr); gap: 20px; align-items: start; }
@media (max-width: 960px) { .calc-grid { grid-template-columns: 1fr; } }

.sheet { background: var(--sheet); border-radius: var(--r-m); overflow: hidden; position: relative;
  background-image: linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 26px 15px, 52px 15px; }
.sheet-draw { padding: 18px 18px 6px; min-height: 280px; display: flex; align-items: flex-end; }
.sheet-draw svg { width: 100%; height: auto; max-height: 420px; display: block; font-family: var(--f-text); }
.sheet-caption { position: absolute; top: 14px; left: 18px; font-size: 13px; color: var(--on-dark-muted); }

.price { border-top: 1px solid var(--soot-3); padding: 20px 22px 22px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px 24px; align-items: end; }
.price-label { font-size: 14px; color: var(--on-dark-muted); }
.price-work { font-family: var(--f-display); font-size: clamp(32px, 4vw, 46px); line-height: 1.05; margin-top: 4px; letter-spacing: 0.01em; }
.price-range { font-size: 14px; color: var(--on-dark-muted); margin-top: 4px; }
.price-meta { display: grid; grid-template-columns: auto auto; gap: 4px 18px; font-size: 15px; margin-top: 16px; }
.price-meta dt { color: var(--on-dark-muted); }
.price-meta dd { margin: 0; font-weight: 600; }
.price-note { grid-column: 1 / -1; font-size: 13px; color: var(--on-dark-muted); margin: 0; max-width: 64ch; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; cursor: pointer; text-decoration: none; font-weight: 700; font-size: 16px; border-radius: var(--r-s); padding: 15px 22px; line-height: 1.2; }
.btn-fire { background: var(--ember); color: #1b1d21; }
.btn-fire:hover { background: var(--ember-hi); }
.btn-ghost { background: transparent; color: inherit; box-shadow: inset 0 0 0 1.5px currentColor; }
.how { grid-column: 1 / -1; font-size: 14px; }
.how summary { cursor: pointer; color: var(--on-dark); font-weight: 600; width: max-content; max-width: 100%; }
.how ul { list-style: none; margin: 10px 0 0; padding: 0; max-width: 560px; }
.how li { display: flex; justify-content: space-between; gap: 16px; padding: 6px 0; border-bottom: 1px dashed var(--soot-3); color: var(--on-dark-muted); }
.how li span:last-child { color: var(--on-dark); white-space: nowrap; font-variant-numeric: tabular-nums; }
.how p { color: var(--on-dark-muted); margin: 10px 0 0; max-width: 60ch; }
@media (max-width: 560px) { .price { grid-template-columns: 1fr; } .price .btn { width: 100%; } }

.panel { background: var(--paper); color: var(--ink); border-radius: var(--r-m); padding: 18px 20px 20px; }
.fld { border: 0; margin: 0; padding: 12px 0; border-bottom: 1px solid #e6e3de; min-width: 0; }
.fld:last-child { border-bottom: 0; }
.fld legend, .fld > label { font-weight: 600; font-size: 15px; padding: 0; margin-bottom: 8px; display: block; }
.fld-hint { font-size: 13px; color: var(--muted); margin: 8px 0 0; }
.fld-hint:empty { display: none; }
#len-note { color: var(--ember-ink); padding: 0 0 6px; margin: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.chip span { display: inline-block; padding: 7px 12px; border-radius: 999px; background: #fff; box-shadow: inset 0 0 0 1px var(--line); font-size: 14px; line-height: 1.3; transition: background .15s, box-shadow .15s; }
.chip:hover span { box-shadow: inset 0 0 0 1px #a9a39b; }
.chip input:checked + span { background: var(--soot); color: var(--on-dark); box-shadow: none; }
.chip input[type="checkbox"]:checked + span::before { content: ''; display: inline-block; width: 9px; height: 5px; border: 2px solid var(--ember-hi); border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -2px); margin-right: 7px; }
.chip input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.stepper-row { display: grid; grid-template-columns: 40px minmax(0, 1fr) 40px 64px; gap: 8px; align-items: center; }
.step { width: 40px; height: 40px; border-radius: 50%; border: 0; background: #fff; box-shadow: inset 0 0 0 1px var(--line); font-size: 20px; line-height: 1; cursor: pointer; }
.step:hover { box-shadow: inset 0 0 0 1px var(--soot); }
.stepper output { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
input[type="range"] { width: 100%; accent-color: var(--ember-ink); height: 28px; }
.link { border: 0; background: none; padding: 0; color: var(--ember-ink); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-size: inherit; }

/* укладка кирпича при добавлении модуля */
@keyframes lay { from { clip-path: inset(100% 0 0 0); } to { clip-path: inset(0 0 0 0); } }
.lay { animation: lay .6s cubic-bezier(.3,.7,.2,1) both; }
@media (prefers-reduced-motion: reduce) { .lay { animation: none; } }

/* ---------- секции ---------- */
.sec { padding: clamp(56px, 8vw, 96px) 0; }
.sec h2 { font-family: var(--f-display); font-weight: 400; font-size: clamp(26px, 3.2vw, 40px); line-height: 1.12; margin: 0 0 14px; max-width: 22ch; }
.sec-lead { color: var(--muted); max-width: 62ch; margin: 0 0 28px; }

/* работы */
.filters { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 28px; }
.filters button { border: 0; cursor: pointer; padding: 9px 16px; border-radius: 999px; background: #fff; box-shadow: inset 0 0 0 1px var(--line); font-weight: 600; font-size: 15px; }
.filters button[aria-pressed="true"] { background: var(--soot); color: var(--on-dark); box-shadow: none; }
.works { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 28px; }
@media (max-width: 980px) { .works { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .works { grid-template-columns: 1fr; gap: 36px; } }
.work { display: flex; flex-direction: column; }
.work-photo { position: relative; border: 0; padding: 0; background: #d9d6d0; cursor: zoom-in; border-radius: var(--r-s); overflow: hidden; aspect-ratio: 4 / 3; }
.work-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.work-photo:hover img { transform: scale(1.03); }
.work-count { position: absolute; right: 10px; bottom: 10px; background: rgba(20,22,26,.78); color: #fff; font-size: 13px; padding: 3px 9px; border-radius: 999px; }
.work h3 { font-size: 19px; line-height: 1.3; margin: 16px 0 6px; font-weight: 700; }
.work ul { list-style: none; padding: 0; margin: 0 0 12px; font-size: 15px; color: var(--muted); }
.work li + li { margin-top: 2px; }
.work-price { margin-top: auto; border-top: 1px solid var(--line); padding-top: 12px; display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; font-size: 15px; }
.work-price dt { color: var(--muted); }
.work-price dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.work-act { margin-top: 12px; }
.more { margin-top: 36px; }

/* как работаем */
.steps-grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 48px; align-items: start; }
@media (max-width: 900px) { .steps-grid { grid-template-columns: 1fr; gap: 28px; } }
.steps-photo { border-radius: var(--r-s); overflow: hidden; position: sticky; top: 24px; }
.steps-photo figcaption { font-size: 14px; color: var(--muted); padding-top: 10px; }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: st; }
.steps li { counter-increment: st; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 4px 16px; padding: 18px 0; border-top: 1px solid var(--line); }
.steps li::before { content: counter(st); grid-row: span 2; font-family: var(--f-display); font-size: 22px; color: var(--ember-ink); line-height: 1.2; }
.steps h3 { margin: 0; font-size: 18px; }
.steps p { margin: 0; color: var(--muted); font-size: 16px; }
.steps .t { color: var(--ink); font-weight: 600; white-space: nowrap; }

/* вопросы */
.faq { background: var(--paper); }
.faq-list { max-width: 860px; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 18px 40px 18px 0; font-weight: 600; font-size: 18px; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ''; position: absolute; right: 6px; top: 26px; width: 10px; height: 10px; border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: rotate(45deg); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(-135deg); top: 30px; }
.faq .a { padding: 0 0 20px; color: #3a3d42; max-width: 70ch; }
.faq .a p { margin: 0 0 10px; }
.faq .a ul { margin: 0 0 10px; padding-left: 20px; }

/* заявка */
.order { background: var(--soot); color: var(--on-dark); }
.order-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: start; }
@media (max-width: 900px) { .order-grid { grid-template-columns: 1fr; gap: 28px; } }
.order h2 { color: var(--on-dark); }
.order .sec-lead { color: var(--on-dark-muted); }
.order-photo { border-radius: var(--r-s); overflow: hidden; margin-top: 8px; }
.contacts { margin-top: 28px; display: grid; gap: 6px; font-size: 16px; }
.contacts a { color: var(--on-dark); font-weight: 600; text-decoration: none; }
.contacts a:hover { color: var(--ember-hi); }
.contacts span { color: var(--on-dark-muted); }
.form { background: var(--paper); color: var(--ink); border-radius: var(--r-m); padding: clamp(18px, 3vw, 30px); }
.mycalc { background: #fff; border-radius: var(--r-s); box-shadow: inset 0 0 0 1px var(--line); padding: 14px 16px; margin-bottom: 18px; font-size: 15px; }
.mycalc b { display: block; font-size: 14px; color: var(--muted); font-weight: 600; margin-bottom: 4px; }
.mycalc p { margin: 0 0 6px; }
.row { margin-bottom: 14px; }
.row label { display: block; font-weight: 600; font-size: 15px; margin-bottom: 6px; }
.row input[type="text"], .row input[type="tel"], .row select, .row textarea { width: 100%; padding: 13px 14px; border-radius: var(--r-s); border: 0; box-shadow: inset 0 0 0 1px var(--line); background: #fff; font-size: 17px; }
.row textarea { min-height: 92px; resize: vertical; }
.row input:focus, .row select:focus, .row textarea:focus { outline: none; box-shadow: inset 0 0 0 2px var(--soot); }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 520px) { .row-2 { grid-template-columns: 1fr; gap: 0; } }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--muted); margin: 6px 0 18px; }
.consent input { width: 20px; height: 20px; flex: none; margin: 1px 0 0; accent-color: var(--soot); }
.consent a { color: var(--ink); }
.err { color: #b3261e; font-size: 14px; margin: 6px 0 0; }
.hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }
.form .btn { width: 100%; }
.form-done { padding: 12px 0; }
.form-done h3 { font-family: var(--f-display); font-weight: 400; font-size: 26px; margin: 0 0 10px; }

/* подвал */
.foot { background: #16191e; color: var(--on-dark-muted); font-size: 14px; padding: 40px 0 96px; }
.foot-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px 40px; }
.foot a { color: var(--on-dark); }
.foot p { margin: 0 0 6px; }

/* липкая полоса цены на телефоне */
.sticky { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: rgba(30,34,40,.97); color: var(--on-dark); padding: 10px var(--gut) calc(10px + env(safe-area-inset-bottom)); display: none; align-items: center; gap: 12px; box-shadow: 0 -6px 20px rgba(0,0,0,.25); }
.sticky small { display: block; color: var(--on-dark-muted); font-size: 12px; }
.sticky strong { font-family: var(--f-display); font-weight: 400; font-size: 21px; }
.sticky .btn { margin-left: auto; padding: 12px 18px; }
@media (max-width: 960px) { .sticky.on { display: flex; } }

/* просмотр фото */
.lb { border: 0; padding: 0; background: transparent; max-width: min(1200px, 96vw); width: 100%; }
.lb::backdrop { background: rgba(12,13,15,.9); }
.lb figure { margin: 0; }
.lb img { max-height: 82vh; width: auto; max-width: 100%; margin: 0 auto; border-radius: var(--r-s); }
.lb figcaption { color: #e9e6e1; text-align: center; padding: 12px 8px 0; font-size: 15px; }
.lb-bar { display: flex; justify-content: center; gap: 10px; margin-top: 12px; }
.lb-bar button { border: 0; background: #2b3038; color: #fff; padding: 10px 16px; border-radius: var(--r-s); cursor: pointer; font-weight: 600; }

/* документы */
.doc { background: var(--paper); padding: 48px 0 80px; }
.doc .wrap { max-width: 860px; }
.doc h1 { font-family: var(--f-display); font-weight: 400; font-size: clamp(26px, 3.4vw, 38px); line-height: 1.15; margin: 0 0 24px; }
.doc h2 { font-size: 20px; margin: 30px 0 10px; }
.doc p, .doc li { color: #33363b; }
