/* ==========================================================================
   Сквирел Дизайн — skvirel-design.ru
   ========================================================================== */

:root {
  --bg: #272727;
  --surface: #3c3c3c;
  --card: #47423b;
  --field: #1f1f1f;
  --accent: #c6ae8b;
  --accent-hover: #d4bf9f;
  --text: #f7f8fa;
  --muted: rgba(247, 248, 250, .7);
  --dim: #8a8a8a;
  --ink: #0f0f0f;
  --radius: 16px;
  --radius-lg: 20px;
  --font-head: "Golos Text", system-ui, sans-serif;
  --font-body: "Open Sans", system-ui, sans-serif;
  --container: 1120px;
  --gutter: 20px;
  --header-h: 132px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 300 16px/1.4 var(--font-body);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
h1, h2, h3, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
body.is-locked { overflow: hidden; }

.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.container--narrow { max-width: calc(860px + var(--gutter) * 2); }
.center { text-align: center; }

/* ----- buttons ----- */
.btn {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  min-height: 50px; padding: 14px 42px;
  background: var(--accent); color: var(--ink);
  border-radius: 40px;
  font: 600 14px/1.25 var(--font-head);
  text-align: center;
  transition: background-color .2s, transform .2s;
}
.btn:hover { background: var(--accent-hover); }
.btn:active { transform: scale(.98); }
.btn--sm { min-height: 44px; padding: 10px 24px; font-size: 13px; }
.btn--lg { min-height: 60px; padding: 18px 68px; font-size: 16px; box-shadow: 0 0 24px rgba(198, 174, 139, .35); }
.btn--wide { width: 100%; }
.btn b { font-weight: 600; font-size: 15px; }
.btn[disabled] { opacity: .6; pointer-events: none; }

/* ----- header ----- */
.header { position: absolute; z-index: 50; top: 0; left: 0; right: 0; }
.header__inner { display: flex; align-items: center; gap: 40px; height: var(--header-h); }
.header__logo img { width: 160px; height: auto; }
.header__nav { display: flex; gap: 60px; margin-left: 40px; font: 500 17px/1.2 var(--font-body); }
.header__nav a { transition: color .2s; }
.header__nav a:hover, .header__nav a.is-active { color: var(--accent); }
.header__phone { margin-left: auto; font: 400 17px/1.2 var(--font-body); white-space: nowrap; }
.header__phone--menu { display: none; }
.header__cta { flex-shrink: 0; }
.header__burger { display: none; width: 44px; height: 44px; position: relative; margin-left: auto; }
.header__burger span, .header__burger span::before, .header__burger span::after {
  position: absolute; left: 10px; width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .25s, top .25s;
}
.header__burger span { top: 21px; }
.header__burger span::before { content: ""; top: -7px; left: 0; }
.header__burger span::after { content: ""; top: 7px; left: 0; }
.header__burger[aria-expanded="true"] span { background: transparent; }
.header__burger[aria-expanded="true"] span::before { top: 0; transform: rotate(45deg); }
.header__burger[aria-expanded="true"] span::after { top: 0; transform: rotate(-45deg); }

/* ----- hero ----- */
.hero {
  position: relative; display: flex; align-items: center;
  min-height: 800px; padding: var(--header-h) 0 80px;
  background: #151411 var(--hero-bg) center / cover no-repeat;
  text-align: center;
}
.hero::before { content: ""; position: absolute; inset: 0; background: rgba(15, 14, 12, .7); }
.hero__inner { position: relative; display: flex; flex-direction: column; align-items: center; }
.hero__title { max-width: 1110px; font: 400 50px/1.2 var(--font-head); text-transform: uppercase; }
.hero__text { max-width: 620px; margin-top: 20px; color: var(--text); }
.hero .btn--lg { margin-top: 36px; }
.hero__features { display: grid; grid-template-columns: repeat(3, 250px); gap: 80px; margin-top: 130px; }
.hero--home .hero__features { margin-top: 130px; }
.hero__features li {
  display: flex; align-items: center; justify-content: center;
  min-height: 80px; padding: 12px 30px;
  background: rgba(198, 174, 139, .2); border-radius: 8px;
  color: var(--muted); font-size: 16px; line-height: 18px;
  backdrop-filter: blur(4px);
}
.hero__features a { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(247, 248, 250, .3); }
.hero__features a:hover { color: var(--text); }

/* ----- sections ----- */
.section { padding: 0 0 80px; }
.section--alt { background: var(--surface); padding-bottom: 60px; }
.section--first { padding-top: var(--header-h); }
.section-head { max-width: 920px; margin: 0 auto; padding: 80px 0 40px; text-align: center; }
.section-head__title { font: 400 36px/1.12 var(--font-head); text-transform: uppercase; }
.section-head__text { margin-top: 20px; color: var(--muted); }

/* ----- project cards ----- */
.cards { display: grid; gap: 20px; }
.cards--2 { grid-template-columns: repeat(2, 1fr); margin-bottom: 60px; }
.cards--3 { grid-template-columns: repeat(3, 1fr); gap: 20px 18px; }
.cards--2 + .cards--3 { margin-bottom: 20px; }
.card { display: flex; flex-direction: column; gap: 16px; }
.card__img { display: block; overflow: hidden; border-radius: var(--radius-lg); aspect-ratio: 1; }
.card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.card:hover .card__img img { transform: scale(1.04); }
.card__body { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.card__title { max-width: 330px; font-weight: 400; color: var(--text); }
.card__sub { display: block; color: var(--muted); font-weight: 300; }
.card__more { display: flex; align-items: center; gap: 14px; flex-shrink: 0; font-size: 13px; line-height: 18px; color: var(--accent); width: 160px; }
.card--sm .card__body { flex-direction: column; gap: 14px; }
.card--sm .card__title { max-width: 300px; }
.card__more svg { width: 26px; height: 26px; flex-shrink: 0; margin-left: auto; transition: transform .2s; }
.card--sm .card__more svg { margin-left: 0; }
.card:hover .card__more svg { transform: translateX(3px); }
.card--sm .card__more { width: auto; }

/* ----- 3D tour ----- */
.tour {
  width: calc(100% - var(--gutter) * 2); max-width: var(--container); height: 640px;
  margin: 0 auto 30px; background: #000; border-radius: var(--radius-lg); overflow: hidden;
} /* ширина как у сетки проектов, не на весь экран */
.tour--after-cards { margin-top: 80px; }
.tour iframe { display: block; width: 100%; height: 100%; border: 0; }

/* ----- compare (before / after gallery) ----- */
.compare-gallery { position: relative; max-width: var(--container); margin: 0 auto; } /* ширина по сетке сайта */
.compare-gallery__stage { position: relative; }
.compare { margin: 0; animation: fade .4s ease; }
.compare__frame {
  position: relative; overflow: hidden; border-radius: var(--radius-lg); aspect-ratio: 880 / 490;
  --pos: 50%; user-select: none; -webkit-user-select: none; touch-action: pan-y; cursor: ew-resize;
}
.compare__frame > img, .compare__before img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.compare__before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.compare__handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; margin-left: -1px; background: #fff; pointer-events: none; }
.compare__handle::after {
  content: ""; position: absolute; top: 50%; left: 50%; width: 72px; height: 72px; margin: -36px 0 0 -36px;
  border-radius: 50%; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='34' height='16' viewBox='0 0 34 16' fill='none' stroke='%23272727' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M8 2 2 8l6 6M26 2l6 6-6 6'/%3E%3C/svg%3E") center no-repeat;
  box-shadow: 0 2px 12px rgba(0, 0, 0, .25); transition: transform .2s;
}
.compare__frame:active .compare__handle::after { transform: scale(.92); }
.compare__range { position: absolute; left: 0; bottom: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.compare__range:focus-visible ~ .compare__handle::after { outline: 3px solid var(--accent); outline-offset: 3px; }
.compare__tag {
  position: absolute; bottom: 16px; padding: 6px 14px; border-radius: 20px; pointer-events: none;
  background: rgba(15, 14, 12, .62); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  font: 500 13px/1.2 var(--font-head); color: #fff; transition: opacity .2s;
}
.compare__tag--before { left: 16px; }
.compare__tag--after { right: 16px; }
.compare__frame.is-left .compare__tag--before, .compare__frame.is-right .compare__tag--after { opacity: 0; }
.compare-gallery__arrow {
  position: absolute; top: calc(50% - 72px); width: 48px; height: 48px; border-radius: 50%;
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='16' fill='none' stroke='%23f7f8fa' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 2l6 6-6 6'/%3E%3C/svg%3E") center no-repeat;
  transition: background-color .2s;
}
.compare-gallery__arrow { z-index: 3; background-color: rgba(39, 39, 39, .75); box-shadow: 0 2px 12px rgba(0, 0, 0, .3); }
.compare-gallery__arrow:hover { background-color: var(--card); }
.compare-gallery__arrow--prev { left: 20px; transform: scaleX(-1); }
.compare-gallery__arrow--next { right: 20px; }
.compare-gallery__thumbs { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.compare-gallery__thumb {
  display: grid; grid-template-columns: 1fr 1fr; gap: 2px; width: 120px; height: 68px; overflow: hidden;
  border-radius: 10px; background: #fff; opacity: .45; outline: 2px solid transparent; outline-offset: 3px;
  transition: opacity .2s, outline-color .2s;
}
.compare-gallery__thumb img { width: 100%; height: 100%; object-fit: cover; }
.compare-gallery__thumb:hover { opacity: .8; }
.compare-gallery__thumb[aria-current="true"] { opacity: 1; outline-color: var(--accent); }

/* ----- tabs ----- */
.tabs__list { display: flex; justify-content: center; flex-wrap: wrap; margin-bottom: 30px; }
.tabs__btn { position: relative; padding: 20px; font: 400 16px/1 var(--font-head); color: var(--muted); transition: color .2s; }
.tabs__btn::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--accent); transform: scaleX(0); transition: transform .25s; }
.tabs__btn:hover { color: var(--text); }
.tabs__btn[aria-selected="true"] { color: var(--text); }
.tabs__btn[aria-selected="true"]::after { transform: scaleX(1); }
.tabs__panel {
  display: grid; grid-template-columns: 460px 1fr; gap: 30px;
  min-height: 330px; padding: 40px 70px; border-radius: var(--radius-lg); background: var(--surface);
  animation: fade .3s ease;
}
.tabs__label { font: 400 20px/1.5 var(--font-head); text-transform: uppercase; color: rgba(247, 248, 250, .5); }
.tabs__title { margin-top: 10px; font: 400 30px/1.33 var(--font-head); text-transform: uppercase; }
.tabs__text { max-width: 430px; padding-top: 30px; font-size: 15px; line-height: 20px; color: rgba(247, 248, 250, .9); }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* ----- services (pricing accordion) ----- */
.services { display: flex; flex-direction: column; gap: 12px; }
.service { border-radius: var(--radius); background: var(--card); transition: background-color .2s; }
.service__head {
  display: grid; grid-template-columns: minmax(0, 1fr) auto auto 40px; align-items: center; gap: 32px;
  padding: 22px 26px 22px 32px; cursor: pointer;
}
.service__title { font: 400 20px/1.25 var(--font-head); text-transform: uppercase; }
.service__toggle { display: block; width: 100%; text-align: left; font: inherit; text-transform: inherit; }
.service__toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; border-radius: 4px; }
.service__price { white-space: nowrap; font: 400 16px/1 var(--font-head); color: var(--muted); }
.service__price span { font-size: 24px; color: var(--accent); }
.service__order { min-height: 44px; padding: 10px 30px; font-size: 14px; }
.service__chevron {
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(39, 39, 39, .55) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='8' fill='none' stroke='%23f7f8fa' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1l6 6 6-6'/%3E%3C/svg%3E") center no-repeat;
  transition: transform .3s;
}
.service.is-open .service__chevron { transform: rotate(180deg); }
@media (hover: hover) { .service__head:hover .service__title { color: var(--accent); } }
.service__body { display: grid; grid-template-rows: 0fr; visibility: hidden; transition: grid-template-rows .35s ease, visibility .35s; }
.service.is-open .service__body { grid-template-rows: 1fr; visibility: visible; }
.service__inner { overflow: hidden; min-height: 0; }
.service__text { max-width: 760px; padding: 4px 32px 0; font-size: 15px; line-height: 1.5; color: rgba(247, 248, 250, .85); }
.service__cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px; padding: 28px 32px 32px; }
.service__cap { margin-bottom: 14px; font: 500 15px/1.3 var(--font-head); color: var(--accent); text-transform: uppercase; letter-spacing: .02em; }
.service__list li { position: relative; padding-left: 20px; margin-bottom: 10px; font-size: 14px; line-height: 1.45; color: rgba(247, 248, 250, .85); }
.service__list li::before { content: ""; position: absolute; left: 0; top: 7px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.service__plan { counter-reset: n; columns: 2; column-gap: 24px; }
.service__plan li { counter-increment: n; break-inside: avoid; padding: 3px 0; font-size: 14px; line-height: 1.4; color: var(--muted); }
.service__plan li::before { content: counter(n) ". "; color: rgba(247, 248, 250, .45); }

/* ----- team ----- */
.team-panel { display: grid; grid-template-columns: 1fr 1fr; overflow: hidden; border-radius: var(--radius-lg); background: var(--surface); }
.team-panel__text { display: flex; flex-direction: column; justify-content: center; gap: 18px; padding: 60px 70px 60px 36px; font-size: 14px; line-height: 22px; color: rgba(247, 248, 250, .9); }
.team-panel__text .btn { margin-top: 12px; max-width: 430px; }
.team-panel__img { min-height: 520px; }
.team-panel__img img { width: 100%; height: 100%; object-fit: cover; object-position: center top; }
.team { display: flex; flex-wrap: wrap; justify-content: center; gap: 40px 18px; margin-top: 70px; }
.member { width: calc((100% - 18px * 4) / 5); } /* 5 в ряд на десктопе */
.member img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--radius); }
.member__name { margin-top: 26px; font-weight: 400; line-height: 20px; }
.member__role { margin-top: 4px; font-size: 13px; color: var(--dim); }

/* ----- slider (reviews, gallery) ----- */
.slider { position: relative; touch-action: pan-y; }
.slider__viewport { overflow: hidden; touch-action: pan-y; }
.slider__track { display: flex; transition: transform .45s ease; }
.slider:not(.slider--gallery) { overflow: hidden; }
.slider__track > * { flex: 0 0 calc(100% / var(--per-view, 1)); min-width: 0; }
.slider__dots { display: flex; justify-content: center; gap: 8px; margin-top: 30px; }
.slider__dots button { width: 10px; height: 10px; border-radius: 50%; background: rgba(247, 248, 250, .5); transition: background-color .2s; }
.slider__dots button[aria-current="true"] { background: var(--accent); }
.slider__arrow {
  position: absolute; top: calc(50% - 30px); z-index: 2; width: 44px; height: 44px; border-radius: 50%;
  background: rgba(60, 60, 60, .9) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='16' fill='none' stroke='%23f7f8fa' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 2l6 6-6 6'/%3E%3C/svg%3E") center no-repeat;
  transition: background-color .2s;
}
.slider__arrow:hover { background-color: var(--card); }
.slider__arrow--prev { left: -22px; transform: scaleX(-1); }
.slider__arrow--next { right: -22px; }
.slider__arrow[disabled] { opacity: .35; cursor: default; }

.review { padding: 30px 60px; }
.review blockquote { font-size: 14px; line-height: 22px; font-style: italic; color: var(--text); }
.review figcaption { display: flex; flex-direction: column; gap: 4px; margin-top: 20px; }
.review__name { font: 400 16px/20px var(--font-head); color: var(--muted); }
.review__city { font-size: 13px; color: var(--muted); }

/* ----- project gallery ----- */
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
.gallery__big { display: block; overflow: hidden; border-radius: var(--radius-lg); aspect-ratio: 1; }
.gallery__big img, .gallery__slide img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.gallery__big:hover img { transform: scale(1.04); }
.gallery__slide:hover img { opacity: .85; }
.slider--gallery .slider__track { margin: 0 -10px; }
.gallery__slide { display: block; padding: 0 10px; }
.gallery__slide img { aspect-ratio: 1; border-radius: var(--radius-lg); }
.gallery__slide { overflow: hidden; }

/* ----- FAQ ----- */
.faq { max-width: 750px; margin: 0 auto; }
.faq__item { border-bottom: 1px solid rgba(247, 248, 250, .08); }
.faq__item summary {
  position: relative; display: block; padding: 22px 60px 22px 0; cursor: pointer; list-style: none;
  font: 500 16px/1.3 var(--font-body); text-transform: uppercase;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: ""; position: absolute; right: 0; top: 50%; width: 40px; height: 40px; margin-top: -20px; border-radius: 50%;
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='8' fill='none' stroke='%23f7f8fa' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1l6 6 6-6'/%3E%3C/svg%3E") center no-repeat;
  transition: transform .25s;
}
.faq__item[open] summary::after { transform: rotate(180deg); }
.faq__item p { padding: 0 60px 22px 0; color: var(--muted); }

/* ----- forms ----- */
.form { display: flex; flex-direction: column; gap: 14px; }
.field input, .field select {
  width: 100%; height: 58px; padding: 0 22px; border: 1px solid transparent; border-radius: 40px;
  background: var(--field); color: var(--text); font: 300 14px/1 var(--font-body); outline: none;
  transition: border-color .2s;
}
/* iOS увеличивает страницу при фокусе на поле со шрифтом меньше 16px */
@media (hover: none), (max-width: 767px) { .field input, .field select, .field textarea { font-size: 16px; } }
.field input::placeholder { color: rgba(247, 248, 250, .5); }
.field input:focus, .field select:focus { border-color: rgba(198, 174, 139, .6); }
.field.is-invalid input, .field.is-invalid select { border-color: #d0705f; }
.field--select select {
  -webkit-appearance: none; appearance: none; padding-right: 50px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='8' fill='none' stroke='%23f7f8fa' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 22px center;
}
.field--select select:invalid { color: rgba(247, 248, 250, .5); }
.field select option { color: var(--text); background: var(--field); }
.form .btn { margin-top: 14px; min-height: 58px; font-size: 16px; font-weight: 500; }
.form__note { font-size: 12px; text-align: center; color: rgba(247, 248, 250, .8); }
.form__note a { text-decoration: underline; text-underline-offset: 2px; }
.form__error { font-size: 13px; text-align: center; color: #e08b7b; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* ----- contacts ----- */
.contacts { padding-top: 80px; }
.contacts__grid { display: grid; grid-template-columns: 445px 1fr; gap: 125px; }
.contacts__title { font: 400 26px/1.1 var(--font-head); text-transform: uppercase; }
.contacts__lead { margin: 30px 0 26px; font-size: 16px; line-height: 1.3; color: var(--muted); }
.contacts__form .form__note { text-align: left; }
.contacts__info { display: flex; flex-direction: column; }
.contacts__cities { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; margin-top: 50px; }
.city__name { font: 400 18px/22px var(--font-head); }
.city__addr { margin-top: 8px; color: var(--muted); }
.city__phone { display: inline-block; margin-top: 18px; font: 400 22px/1.2 var(--font-head); transition: color .2s; }
.city__phone:hover { color: var(--accent); }
.contacts__social { display: flex; justify-content: flex-end; gap: 22px; margin-top: 60px; }
.contacts__social a { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 10px; background: var(--text); color: var(--bg); transition: background-color .2s; }
.contacts__social a:nth-child(2) { border-radius: 50%; }
.contacts__social a:hover { background: var(--accent); }
.contacts__social svg { width: 26px; height: 26px; }
.contacts__bottom { display: flex; justify-content: space-between; align-items: flex-start; gap: 30px; margin-top: 30px; }
.contacts__mail { font-size: 14px; color: var(--muted); }
.contacts__mail:hover { color: var(--text); }
.contacts__legal { font-size: 14px; line-height: 20px; color: #6e6e6e; text-align: right; }
.contacts__legal a:hover { color: var(--muted); }

/* ----- footer ----- */
.footer { padding: 40px 0 30px; }
.footer__inner { display: flex; justify-content: flex-end; }
.footer__dev { display: flex; align-items: center; gap: 12px; font-size: 14px; line-height: 18px; color: var(--muted); text-align: right; }
.footer__dev img { width: 32px; height: 32px; border-radius: 50%; }
.footer__dev:hover { color: var(--text); }

/* ----- privacy text ----- */
.prose { font-size: 15px; line-height: 1.6; color: rgba(247, 248, 250, .85); }
.prose h2 { margin: 36px 0 12px; font: 400 22px/1.3 var(--font-head); color: var(--text); }
.prose p + p { margin-top: 10px; }
.prose a { color: var(--accent); word-break: break-all; }

/* ----- modals ----- */
.modal { position: fixed; inset: 0; z-index: 100; display: flex; align-items: flex-start; justify-content: center; overflow-y: auto; padding: 40px 16px; }
.modal__overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, .75); animation: fade .25s; }
.modal__box {
  position: relative; width: 100%; max-width: 700px; margin: auto; padding: 80px 80px 70px;
  border-radius: 30px; background: var(--surface); text-align: center; animation: pop .3s ease;
}
.modal--small .modal__box { max-width: 560px; padding: 70px 60px 60px; }
.modal__close { position: absolute; top: 40px; right: 40px; width: 24px; height: 24px; }
.modal__close::before, .modal__close::after { content: ""; position: absolute; top: 11px; left: 3px; width: 18px; height: 2px; background: var(--text); border-radius: 2px; transform: rotate(45deg); }
.modal__close::after { transform: rotate(-45deg); }
.modal__title { font: 400 30px/1.2 var(--font-head); text-transform: uppercase; }
.modal__lead { margin: 18px auto 40px; max-width: 480px; font-weight: 400; color: rgba(247, 248, 250, .9); }
.modal--small .modal__lead { margin-bottom: 30px; }
.modal--text .modal__box { text-align: left; }
.modal--text .modal__title { padding-right: 30px; font-size: 26px; }
@keyframes pop { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }

/* ----- lightbox ----- */
.lightbox { position: fixed; inset: 0; z-index: 120; display: flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, .92); animation: fade .25s; }
.lightbox img { max-width: calc(100% - 140px); max-height: calc(100% - 80px); border-radius: 8px; }
.lightbox__close, .lightbox__prev, .lightbox__next { position: absolute; width: 50px; height: 50px; border-radius: 50%; background: rgba(60, 60, 60, .8) center no-repeat; }
.lightbox__close { top: 20px; right: 20px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' stroke='%23fff' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M2 2l12 12M14 2 2 14'/%3E%3C/svg%3E"); }
.lightbox__prev, .lightbox__next { top: calc(50% - 25px); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='16' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 2l6 6-6 6'/%3E%3C/svg%3E"); }
.lightbox__prev { left: 20px; transform: scaleX(-1); }
.lightbox__next { right: 20px; }

/* ----- to top ----- */
.to-top {
  position: fixed; right: 36px; bottom: 36px; z-index: 40; width: 48px; height: 48px; border-radius: 50%;
  background: rgba(39, 39, 39, .9) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='10' fill='none' stroke='%23f7f8fa' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 9l8-8 8 8'/%3E%3C/svg%3E") center no-repeat;
  box-shadow: 0 2px 12px rgba(0, 0, 0, .3);
  opacity: 0; visibility: hidden; transition: opacity .25s, visibility .25s;
}
.to-top.is-visible { opacity: 1; visibility: visible; }

/* ----- cookie notice ----- */
.cookie {
  position: fixed; left: 36px; bottom: 36px; z-index: 45; max-width: 440px;
  padding: 24px 28px 28px; background: var(--field); color: var(--text);
  border: 1px solid rgba(247, 248, 250, .08); border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(0, 0, 0, .45);
  opacity: 0; transform: translateY(16px); transition: opacity .3s, transform .3s;
}
.cookie.is-visible { opacity: 1; transform: none; }
.cookie__text { font-size: 15px; line-height: 1.5; }
.cookie__text a { text-decoration: underline; text-decoration-thickness: .5px; text-decoration-color: rgba(247, 248, 250, .6); text-underline-offset: 3px; }
.cookie__text a:hover { color: var(--accent); }
.cookie__btn { margin-top: 18px; padding-left: 36px; padding-right: 36px; }
@media (max-width: 767px) {
  .cookie { left: 12px; right: 12px; bottom: 12px; max-width: none; padding: 20px; border-radius: var(--radius); }
  .cookie__text { font-size: 14px; }
  .cookie__btn { width: 100%; margin-top: 16px; }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1199px) {
  .header__nav { gap: 32px; margin-left: 10px; }
  .header__inner { gap: 24px; }
  .hero__features { grid-template-columns: repeat(3, 230px); gap: 40px; }
  .tabs__panel { grid-template-columns: 1fr 1fr; padding: 40px; }
  .contacts__grid { grid-template-columns: 1fr 1fr; gap: 60px; }
  .team-panel__text { padding: 40px; }
}

@media (max-width: 1023px) {
  :root { --header-h: 90px; }
  .header { position: absolute; }
  .header__logo img { width: 120px; }
  .header__burger { display: block; margin-left: 0; }
  .header__phone { margin-left: auto; font-size: 15px; }
  .header__nav {
    position: fixed; inset: 0; z-index: -1; flex-direction: column; align-items: center; justify-content: center; gap: 28px;
    margin: 0; background: rgba(27, 26, 22, .98); font-size: 22px;
    opacity: 0; visibility: hidden; transition: opacity .25s, visibility .25s;
  }
  .header__nav.is-open { opacity: 1; visibility: visible; }
  .header__phone--menu { display: block; margin: 10px 0 0; }
  .hero { min-height: 700px; }
  .hero__title { font-size: 40px; }
  .hero__features { grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 80px; width: 100%; }
  .hero__features li { padding: 12px 16px; }
  .cards--3 { grid-template-columns: repeat(2, 1fr); }
  .card__body { flex-direction: column; gap: 12px; }
  .card__more { width: auto; }
  .card__more svg { margin-left: 0; }
  .service__head { gap: 20px; }
  .service__cols { grid-template-columns: 1fr; gap: 24px; }
  .tabs__panel { grid-template-columns: 1fr; gap: 10px; min-height: 0; }
  .tabs__text { padding-top: 10px; max-width: none; }
  .team-panel { grid-template-columns: 1fr; }
  .team-panel__img { min-height: 0; aspect-ratio: 4 / 3; order: -1; }
  .member { width: calc(33.333% - 12px); }
  .review { padding: 20px 30px; }
  .contacts__grid { grid-template-columns: 1fr; gap: 50px; }
  .contacts__social { justify-content: flex-start; margin-top: 40px; }
  .tour { height: 520px; }
  .compare-gallery__arrow { display: none; }
}

@media (max-width: 767px) {
  :root { --gutter: 16px; --header-h: 76px; }
  body { font-size: 15px; }
  .header__inner { gap: 12px; }
  .header__logo img { width: 104px; }
  .header__phone { display: none; }
  .header__cta { margin-left: auto; padding: 8px 16px; min-height: 38px; font-size: 12px; }
  .hero { min-height: 0; padding: calc(var(--header-h) + 60px) 0 50px; }
  .hero__title { font-size: 28px; }
  .hero__text { font-size: 15px; }
  .btn--lg { padding: 16px 40px; }
  .hero__features { grid-template-columns: 1fr; gap: 12px; margin-top: 50px; }
  .hero__features li { min-height: 60px; }
  .section { padding-bottom: 50px; }
  .section-head { padding: 50px 0 28px; }
  .section-head__title { font-size: 26px; }
  .cards--2, .cards--3 { grid-template-columns: 1fr; gap: 36px; }
  .cards--2 { margin-bottom: 36px; }
  .compare__frame { aspect-ratio: 4 / 3; }
  .compare__handle::after { width: 52px; height: 52px; margin: -26px 0 0 -26px; background-size: 26px; }
  .compare__tag { bottom: 10px; padding: 5px 10px; font-size: 12px; }
  .compare__tag--before { left: 10px; }
  .compare__tag--after { right: 10px; }
  .compare-gallery__thumb { width: 96px; height: 56px; }
  .tabs__list { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; scrollbar-width: none; margin: 0 calc(var(--gutter) * -1) 20px; padding: 0 var(--gutter); }
  .tabs__list::-webkit-scrollbar { display: none; }
  .tabs__btn { flex-shrink: 0; padding: 16px 14px; }
  .tabs__panel { padding: 28px 22px; }
  .tabs__label { font-size: 16px; }
  .tabs__title { font-size: 22px; }
  .service { position: relative; }
  .service__head { grid-template-columns: minmax(0, 1fr) auto 36px; grid-template-areas: "title title chevron" "price order order"; gap: 26px 12px; padding: 20px 16px 20px 20px; }
  .service__title { grid-area: title; align-self: center; font-size: 17px; }
  .service__chevron { grid-area: chevron; justify-self: end; align-self: start; width: 36px; height: 36px; }
  .service__price { grid-area: price; }
  .service__price span { font-size: 21px; }
  .service__order { grid-area: order; padding: 8px 22px; }
  .service__text { padding: 0 20px; font-size: 14px; }
  .service__cols { padding: 22px 20px 24px; }
  .service__plan { columns: 1; }
  .team-panel__text { padding: 28px 22px 32px; }
  .team { gap: 30px 16px; margin-top: 40px; }
  .member { width: calc(50% - 8px); }
  .member__name { margin-top: 14px; font-size: 15px; }
  .review { padding: 10px 4px; }
  .gallery { grid-template-columns: 1fr; gap: 16px; margin-bottom: 16px; }
  .slider__arrow { display: none; }
  .faq__item summary { padding-right: 56px; font-size: 14px; }
  .faq__item p { padding-right: 0; }
  .contacts { padding-top: 50px; }
  .contacts__title { font-size: 22px; }
  .contacts__cities { grid-template-columns: 1fr; gap: 26px; margin-top: 30px; }
  .city__phone { margin-top: 10px; }
  .contacts__bottom { flex-direction: column; gap: 16px; }
  .contacts__legal { text-align: left; }
  .footer__inner { justify-content: flex-start; }
  .footer__dev { text-align: left; }
  .tour { height: 420px; }
  .tour--after-cards { margin-top: 50px; }
  .modal { padding: 16px 12px; }
  .modal__box, .modal--small .modal__box { padding: 56px 20px 32px; border-radius: 20px; }
  .modal__close { top: 20px; right: 20px; }
  .modal__title { font-size: 22px; }
  .modal--text .modal__title { font-size: 20px; }
  .modal__lead { margin-bottom: 26px; }
  .lightbox img { max-width: 100%; max-height: calc(100% - 140px); border-radius: 0; }
  .lightbox { background: #0b0b0b; touch-action: pan-y; }
  .lightbox img { max-height: calc(100% - 160px); }
  .lightbox__close { top: 14px; right: 14px; width: 44px; height: 44px; }
  .lightbox__prev, .lightbox__next { top: calc(50% - 22px); width: 44px; height: 44px; background-color: rgba(30, 30, 30, .6); }
  .lightbox__prev { left: 8px; }
  .lightbox__next { right: 8px; }
  .to-top { right: 16px; bottom: 16px; width: 44px; height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* black & white team photos (as on the original site) */
.team-panel__img img, .member img { filter: grayscale(1); }

/* «Новый» label on project cards */
.card__img { position: relative; }
.card__badge {
  position: absolute; top: 16px; left: 16px; z-index: 1;
  padding: 7px 14px; border-radius: 20px; background: var(--accent); color: var(--ink);
  font: 600 12px/1 var(--font-head); letter-spacing: .06em; text-transform: uppercase;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .25);
}
.card--sm .card__badge { top: 12px; left: 12px; padding: 6px 12px; font-size: 11px; }

/* project page split by rooms */
.section--intro { padding-bottom: 0; }
.section--room { padding-bottom: 40px; }
.section--room .section-head { padding-top: 70px; padding-bottom: 30px; }
.section-head__text--slogan { margin-top: 12px; font: 400 18px/1.4 var(--font-head); color: var(--accent); }
.section--room .gallery:last-child { margin-bottom: 0; }
.section--floor { padding-bottom: 0; }
.section--floor + .section--room .section-head { padding-top: 50px; }
.section--floor .section-head { text-align: center; padding-bottom: 0; }
.section-floor__label { font: 500 14px/1 var(--font-head); letter-spacing: .2em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }
.floor-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 28px; padding-bottom: 36px; border-bottom: 1px solid rgba(255,255,255,.12); }
.floor-nav__link { padding: 9px 18px; border: 1px solid rgba(255,255,255,.25); border-radius: 40px; font-size: 15px; color: inherit; text-decoration: none; transition: border-color .2s, color .2s; }
.floor-nav__link:hover { border-color: var(--accent); color: var(--accent); }
@media (max-width: 767px) {
  .section--room { padding-bottom: 20px; }
  .section--room .section-head { padding-top: 44px; padding-bottom: 20px; }
  .section-head__text--slogan { font-size: 16px; }
}

/* gallery slider with fewer photos than slots: keep size, center */
.slider__track.is-short { justify-content: center; }
