:root {
  --bg: #F7F5F1;
  --surface: #FFFFFF;
  --sand: #EEE9E1;
  --taupe: #A09582;
  --taupe-ink: #7A6E5C;
  --ink: #211F1C;
  --ink-2: #4A453F;
  --muted: #7B746B;
  --line: #E3DCD1;
  --font-head: "Jost", system-ui, sans-serif;
  --font-accent: "Cormorant Garamond", Georgia, serif;
  --font-body: "Manrope", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.6 var(--font-body); -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
[hidden] { display: none !important; }
a { color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-family: var(--font-head); font-weight: 500; line-height: 1.12; letter-spacing: -.015em; }
h1 { font-size: clamp(38px, 5.4vw, 66px); }
h2 { font-size: clamp(30px, 3.6vw, 46px); }
h3 { font-size: 22px; line-height: 1.3; }
h1 em, h2 em {
  font-family: var(--font-accent); font-style: italic; font-weight: 500;
  font-size: 1.14em; line-height: 1; letter-spacing: 0; color: var(--taupe-ink);
}
section[id] { scroll-margin-top: 76px; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
@media (max-width: 600px) { .container { padding: 0 16px; } }

.eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .24em; text-transform: uppercase; color: var(--taupe-ink); }

/* Кнопки */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 52px; padding: 0 28px; border-radius: 999px;
  border: 1.5px solid var(--ink); background: transparent; color: var(--ink);
  font: 600 16px/1 var(--font-body); text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}
.btn:hover { background: var(--ink); color: var(--bg); }
.btn--primary { background: var(--ink); color: var(--bg); }
.btn--primary:hover { background: #3A3632; border-color: #3A3632; }
.btn--sm { height: 44px; padding: 0 22px; font-size: 15px; }
:focus-visible { outline: 3px solid var(--taupe); outline-offset: 3px; }

/* Шапка */
.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247, 245, 241, .9);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent; transition: border-color .2s;
}
.header.is-scrolled { border-bottom-color: var(--line); }
.header__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 76px; }
.logo img { width: auto; height: 40px; }
@media (max-width: 480px) { .logo img { height: 32px; } }

/* Головний екран */
.hero { padding: 48px 0 96px; }
.hero__grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 64px; align-items: center; }
.hero__text { display: grid; gap: 26px; justify-items: start; }
.hero__lead { max-width: 540px; font-size: 18px; color: var(--ink-2); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero__photo { position: relative; margin: 0; overflow: hidden; border-radius: 28px; background: #EFEFEF; }
.hero__photo img { width: 100%; height: auto; aspect-ratio: 1122 / 1402; object-fit: cover; }
.hero__photo figcaption {
  position: absolute; left: 20px; bottom: 20px; padding: 10px 16px; border-radius: 999px;
  background: rgba(247, 245, 241, .92); font-size: 14px; font-weight: 600;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
@media (max-width: 960px) {
  .hero { padding-top: 32px; }
  .hero__grid { grid-template-columns: 1fr; gap: 40px; }
}
@media (max-width: 560px) {
  .hero { padding-bottom: 64px; }
  .hero__photo { border-radius: 22px; }
  .hero__photo figcaption { left: 12px; bottom: 12px; font-size: 13px; }
  .hero__actions { width: 100%; }
  .hero__actions .btn { flex: 1 1 100%; }
}

/* Секції */
.section { padding: 96px 0; }
.section--line { border-top: 1px solid var(--line); }
.section--alt { background: var(--sand); }
.section-head { display: grid; gap: 16px; justify-items: start; max-width: 720px; margin-bottom: 44px; }
.section-head p { font-size: 18px; color: var(--ink-2); }
@media (max-width: 760px) {
  .section { padding: 64px 0; }
  .section-head { margin-bottom: 32px; }
}

/* Про нас + ескіз */
.about { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.about__text { display: grid; gap: 18px; justify-items: start; }
.about__text p { font-size: 18px; color: var(--ink-2); }
@media (max-width: 960px) { .about { grid-template-columns: 1fr; gap: 40px; } }

.techcard {
  position: relative; margin: 0; padding: 22px 24px 24px; overflow: hidden;
  border-radius: 28px; background-color: var(--sand);
  background-image:
    linear-gradient(rgba(33, 31, 28, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(33, 31, 28, .045) 1px, transparent 1px);
  background-size: 24px 24px;
}
.techcard__top {
  display: flex; justify-content: space-between; gap: 12px;
  font-size: 11px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--muted);
}
.techcard__art { width: 100%; max-width: 440px; margin: 12px auto 4px; }
.techcard__legend {
  list-style: none; margin: 8px 0 0; padding: 18px 0 0;
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px 20px; border-top: 1px dashed #CFC5B5;
}
.techcard__legend li { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; line-height: 1.3; }
.num {
  flex: none; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%;
  background: var(--ink); color: var(--bg); font-size: 12px; font-weight: 700;
}
@media (max-width: 560px) {
  .techcard { padding: 18px 16px 20px; border-radius: 22px; }
  .techcard__legend { grid-template-columns: 1fr; }
}

.flat .f { fill: var(--g); stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; }
.flat .dk { fill: var(--g2); stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; }
.flat .l { fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; }
.flat .rib { fill: none; stroke: var(--ink); stroke-opacity: .35; stroke-width: 1.2; stroke-linecap: round; }
.flat .st { fill: none; stroke: rgba(255, 255, 255, .45); stroke-width: 1.2; stroke-dasharray: 3 3; }
.flat .zip { fill: none; stroke: #171513; stroke-width: 4.5; stroke-dasharray: 1.6 2.2; }
.flat .pull { fill: #2B2826; stroke: #0F0E0D; stroke-width: 1.2; }
.flat .emb { fill: none; stroke: #E9E4D6; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.flat .slit { fill: none; stroke: #1A1A17; stroke-width: 2.2; stroke-linecap: round; }
.flat .tab rect { fill: #151513; }
.flat .mk circle { fill: var(--ink); stroke: #fff; stroke-width: 2; }
.flat .mk text { fill: #fff; font: 700 12px var(--font-body); text-anchor: middle; }
.flat .lead { fill: none; stroke: var(--ink); stroke-width: 1.4; }

/* Моделі */
.products { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card { display: flex; flex-direction: column; overflow: hidden; background: var(--surface); border-radius: 24px; }
.card__media { aspect-ratio: 1 / 1; overflow: hidden; background: #EFEFEF; }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card__media img { transform: scale(1.03); }
.card__body { display: flex; flex: 1; flex-direction: column; gap: 14px; padding: 26px 26px 28px; }
.card__desc { color: var(--ink-2); }
.list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.list li { position: relative; padding-left: 22px; }
.list li::before {
  content: ""; position: absolute; left: 0; top: .5em;
  width: 9px; height: 9px; border-radius: 50%; border: 2px solid var(--taupe);
}
.card__spec { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); font-size: 14px; line-height: 1.5; color: var(--muted); }
.card__spec span { display: block; margin-bottom: 2px; font-size: 11px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--taupe-ink); }
.colors { display: flex; flex-wrap: wrap; gap: 8px; }
.color {
  display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px 0 8px;
  border: 1.5px solid var(--line); border-radius: 999px; background: var(--surface);
  font: 600 14px/1 var(--font-body); color: var(--ink-2); cursor: pointer;
}
.color::before { content: ""; width: 20px; height: 20px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12); }
.color.is-active { border-color: var(--ink); color: var(--ink); }
@media (max-width: 900px) {
  .products { grid-template-columns: 1fr; gap: 18px; max-width: 560px; }
  .card__body { padding: 22px 20px 24px; }
}

/* Контакти */
.contact { text-align: center; }
.contact__inner { display: grid; gap: 16px; justify-items: center; }
.contact__inner p { max-width: 520px; font-size: 18px; color: var(--ink-2); }
.contact__phone {
  margin-top: 12px; padding-bottom: 4px; border-bottom: 2px solid var(--taupe);
  font: 500 clamp(36px, 6vw, 64px)/1.1 var(--font-head); letter-spacing: -.01em; text-decoration: none;
}
.contact__phone:hover { color: var(--taupe-ink); }
.contact__reveal { margin-top: 12px; }

/* Футер */
.footer { padding: 28px 0; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.footer__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; }
.footer__logo { width: auto; height: 30px; }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--ink); }
.footer__links { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.footer__note { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 13px; }

/* Юридичні сторінки */
.legal { max-width: 760px; padding-top: 48px; padding-bottom: 80px; }
.legal h1 { font-size: clamp(32px, 4vw, 44px); }
.legal__date { margin: 12px 0 36px; font-size: 14px; color: var(--muted); }
.legal h2 { margin: 32px 0 10px; font-size: 20px; line-height: 1.3; }
.legal p { color: var(--ink-2); }
.legal a { color: var(--ink); text-underline-offset: 3px; }

/* Поява при прокрутці */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}
