:root {
  --bg: #ffffff;
  --bg-muted: #fafafa;
  --ink: #142018;
  --ink-soft: #3d4a40;
  --line: rgba(20, 32, 24, 0.08);
  --brand: #0f6b4c;
  --brand-deep: #0a4533;
  --accent: #d97706;
  --accent-2: #f59e0b;
  --surface: #ffffff;
  --shadow: 0 12px 40px rgba(0, 0, 0, 0.04);
  --radius: 18px;
  --font: "Manrope", sans-serif;
  --display: "Unbounded", sans-serif;
  --container: 1180px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: #ffffff;
  min-height: 100vh;
  line-height: 1.55;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand-deep); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--brand); }
button, input, textarea { font: inherit; }
.container { width: min(100% - 2rem, var(--container)); margin-inline: auto; }
.narrow { width: min(100%, 820px); }
.visually-hidden, .skip-link {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link:focus {
  position: fixed; top: 0.75rem; left: 0.75rem; z-index: 1000;
  width: auto; height: auto; clip: auto; margin: 0; padding: 0.75rem 1rem;
  background: #fff; color: var(--ink); border-radius: 999px;
}

.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--line);
}

.topbar {
  border-bottom: 1px solid var(--line);
  font-size: 0.875rem;
  color: var(--ink-soft);
}
.topbar__inner, .navbar__inner, .footer__bottom-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.topbar__inner { padding: 0.55rem 0; flex-wrap: wrap; }
.topbar__meta, .topbar__actions { display: flex; flex-wrap: wrap; gap: 0.85rem 1.1rem; align-items: center; }
.topbar__phone { color: var(--ink); font-weight: 700; text-decoration: none; }
.topbar__phone:hover { color: var(--brand); }
.linkish {
  border: 0; background: transparent; color: var(--brand-deep);
  cursor: pointer; padding: 0; text-decoration: underline; text-underline-offset: 0.18em;
}

.navbar__inner { padding: 0.85rem 0; gap: 1rem; }
.logo img { width: 170px; height: auto; }
.search {
  position: relative; flex: 1; max-width: 420px;
  display: flex; align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.15rem 0.25rem 0.15rem 1rem;
  box-shadow: 0 8px 24px rgba(20, 32, 24, 0.04);
}
.search input {
  flex: 1; border: 0; background: transparent; outline: none; padding: 0.55rem 0.4rem;
}
.search button {
  border: 0; width: 2.4rem; height: 2.4rem; border-radius: 999px;
  background: var(--brand); color: #fff; cursor: pointer;
  display: grid; place-items: center;
}
.search__drop {
  position: absolute; left: 0; right: 0; top: calc(100% + 0.4rem);
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow); overflow: hidden;
}
.search__drop a {
  display: block; padding: 0.75rem 1rem; color: var(--ink); text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.search__drop a:hover { background: rgba(15, 107, 76, 0.06); }

.nav {
  display: flex; flex-wrap: wrap; gap: 0.15rem 0.35rem; align-items: center;
}
.nav__item { position: relative; }
.nav__link {
  display: inline-flex; align-items: center; gap: 0.3rem;
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: 0.92rem;
  padding: 0.55rem 0.55rem; border-radius: 10px;
}
.nav__link:hover,
.nav__item:hover > .nav__link,
.nav__item.is-open > .nav__link { color: var(--brand); background: rgba(15, 107, 76, 0.06); }
.nav__caret {
  width: 0; height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  opacity: 0.55;
  margin-top: 2px;
}
.nav__drop {
  position: absolute; left: 0; top: calc(100% + 0.35rem);
  min-width: 280px; max-width: min(720px, 90vw);
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.08);
  padding: 0.85rem;
  opacity: 0; visibility: hidden; transform: translateY(6px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s;
  z-index: 60;
}
.nav__item:hover > .nav__drop,
.nav__item:focus-within > .nav__drop,
.nav__item.is-open > .nav__drop {
  opacity: 1; visibility: visible; transform: none;
}
.nav__drop-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.15rem 0.75rem;
  max-height: 320px;
  overflow: auto;
}
.nav__drop-grid a {
  display: block; padding: 0.45rem 0.35rem; border-radius: 8px;
  color: var(--ink); text-decoration: none; font-size: 0.9rem; font-weight: 500;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.nav__drop-grid a:hover { background: rgba(15, 107, 76, 0.07); color: var(--brand); }
.nav__drop-all {
  display: inline-flex; margin-top: 0.65rem; padding-top: 0.65rem;
  border-top: 1px solid var(--line); color: var(--brand-deep);
  font-weight: 700; font-size: 0.88rem; text-decoration: none;
}
.nav__drop-all:hover { color: var(--brand); }
.nav-toggle {
  display: none; width: 2.6rem; height: 2.6rem; border-radius: 12px;
  border: 1px solid var(--line); background: var(--surface); cursor: pointer;
  place-items: center; gap: 4px; padding: 0;
}
.nav-toggle span {
  display: block; width: 16px; height: 2px; background: var(--ink); border-radius: 2px;
}

.hero {
  position: relative; min-height: min(88vh, 760px);
  display: grid; align-items: end; overflow: hidden;
  color: #f8faf7;
}
.hero__media, .hero__overlay { position: absolute; inset: 0; }
.hero__media img {
  width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.04);
  animation: heroZoom 18s ease-in-out infinite alternate;
}
.hero__overlay {
  background:
    linear-gradient(90deg, rgba(8, 24, 18, 0.88) 0%, rgba(8, 24, 18, 0.55) 48%, rgba(8, 24, 18, 0.2) 100%),
    linear-gradient(180deg, rgba(8, 24, 18, 0.15), rgba(8, 24, 18, 0.72));
}
.hero__content {
  position: relative; z-index: 1; padding: 5.5rem 0 4rem;
  max-width: 760px; margin-left: max(1rem, calc((100% - var(--container)) / 2));
  animation: rise 0.9s ease both;
}
.brand-mark {
  font-family: var(--display);
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  margin: 0 0 0.55rem;
  letter-spacing: -0.04em;
  line-height: 1;
}
.hero h1 {
  font-family: var(--display);
  font-size: clamp(1.15rem, 2.2vw, 1.55rem);
  line-height: 1.35;
  font-weight: 500;
  margin: 0 0 1rem;
  max-width: 28ch;
  color: rgba(248, 250, 247, 0.92);
}
.hero__lead {
  margin: 0 0 1.6rem;
  max-width: 38ch;
  color: rgba(248, 250, 247, 0.88);
  font-size: 1.05rem;
}
.hero__cta, .page-hero__cta, .cta-band__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 0.4rem; border-radius: 999px; padding: 0.85rem 1.35rem;
  border: 1px solid transparent; font-weight: 700; cursor: pointer;
  text-decoration: none; transition: transform .2s ease, background .2s ease, color .2s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--accent); color: #1a1205; }
.btn--primary:hover { background: var(--accent-2); color: #1a1205; }
.btn--ghost {
  background: transparent; color: inherit; border-color: currentColor;
}
.btn--tiny {
  padding: 0.4rem 0.8rem; font-size: 0.82rem; background: rgba(15,107,76,.08); color: var(--brand-deep);
}

.section { padding: 4rem 0; }
.section--muted { background: var(--bg-muted); }

.reviews-section__head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem;
  max-width: none;
}
.reviews-section__all {
  color: var(--ink);
  border-color: var(--line);
  background: #fff;
  flex-shrink: 0;
}
.reviews-carousel {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.6rem;
  align-items: center;
}
.reviews-track-wrap {
  overflow: hidden;
  border-radius: 18px;
}
.reviews-track {
  display: flex;
  gap: 0.85rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 0.15rem 0.1rem 0.55rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.reviews-track::-webkit-scrollbar { display: none; }
.review-card {
  flex: 0 0 min(340px, 82vw);
  scroll-snap-align: start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.1rem 1.15rem;
  box-shadow: var(--shadow);
  min-height: 190px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.review-card__top {
  display: flex; justify-content: space-between; gap: 0.75rem; align-items: flex-start;
}
.review-card__top strong { display: block; }
.review-card__top time {
  display: block; margin-top: 0.15rem; color: var(--ink-soft); font-size: 0.85rem;
}
.review-card__stars {
  color: #d6d6d6; letter-spacing: 0.05em; white-space: nowrap; font-size: 0.95rem;
}
.review-card__stars .is-on { color: var(--accent); }
.review-card p {
  margin: 0; color: var(--ink-soft); line-height: 1.5; font-size: 0.95rem;
}
.reviews-nav {
  width: 2.5rem; height: 2.5rem; border-radius: 999px;
  border: 1px solid var(--line); background: #fff; color: var(--ink);
  cursor: pointer; font-size: 1.4rem; line-height: 1;
  box-shadow: var(--shadow);
}
.reviews-nav:hover { color: var(--brand); border-color: rgba(15,107,76,.35); }
.reviews-nav:disabled { opacity: 0.35; cursor: default; }

@media (max-width: 700px) {
  .reviews-section__head { flex-direction: column; align-items: flex-start; }
  .reviews-carousel { grid-template-columns: 1fr; }
  .reviews-nav { display: none; }
}

.section__head { margin-bottom: 1.6rem; max-width: 42rem; }
.section__head h2, .page-hero h1, .prices h2, .content-block h2 {
  font-family: var(--display);
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin: 0 0 0.55rem;
}
.section__head p { margin: 0; color: var(--ink-soft); }

.benefits { padding: 0; margin-top: -2rem; position: relative; z-index: 2; }
.benefits__grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.85rem;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1rem;
  box-shadow: var(--shadow);
}
.benefits__grid div {
  padding: 0.85rem 1rem; border-radius: 14px;
  background: #fafafa;
}
.benefits__grid strong { display: block; margin-bottom: 0.2rem; }
.benefits__grid span { color: var(--ink-soft); font-size: 0.92rem; }

.cat-grid, .model-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 0.85rem;
}
.cat-tile, .model-card {
  display: flex; flex-direction: column; gap: 0.7rem;
  text-decoration: none; color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1rem;
  min-height: 140px;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.cat-tile:hover, .model-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: rgba(15,107,76,0.28);
  color: var(--ink);
}
.cat-tile img, .model-card img {
  width: 72px; height: 72px; object-fit: contain; margin: 0 auto;
}
.cat-tile span, .model-card span {
  font-weight: 700; text-align: center; font-size: 0.92rem;
}

.page-hero {
  padding: 2.2rem 0 0.5rem;
  background: #fff;
}
.page-hero__inner {
  display: grid; grid-template-columns: 1.4fr 0.8fr; gap: 1.5rem; align-items: center;
}
.page-hero__lead { color: var(--ink-soft); max-width: 48ch; }
.page-hero__img {
  justify-self: end; width: min(100%, 280px);
  filter: drop-shadow(0 8px 28px rgba(0, 0, 0, 0.08));
  animation: floaty 5s ease-in-out infinite;
}

.breadcrumbs { width: min(100% - 2rem, var(--container)); margin: 1.2rem auto 0; }
.breadcrumbs ol {
  list-style: none; display: flex; flex-wrap: wrap; gap: 0.35rem 0.55rem;
  padding: 0; margin: 0; color: var(--ink-soft); font-size: 0.9rem;
}
.breadcrumbs li:not(:last-child)::after {
  content: "→"; margin-left: 0.55rem; opacity: 0.55;
}
.breadcrumbs a { color: inherit; text-decoration: none; }
.breadcrumbs a:hover { color: var(--brand); }

.prices { margin: 2rem 0; }
.prices__table-wrap {
  overflow: auto; border: 1px solid var(--line); border-radius: 16px;
  background: #fff;
}
.prices__table { width: 100%; border-collapse: collapse; min-width: 560px; }
.prices__table th, .prices__table td {
  padding: 0.9rem 1rem; text-align: left; border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
.prices__table th {
  font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-soft);
  background: #fafafa;
}
.prices__table tr:last-child td { border-bottom: 0; }
.prices__table tr:hover td { background: rgba(15,107,76,0.03); }

.prose { color: var(--ink-soft); }
.prose h2, .prose h3 { color: var(--ink); margin-top: 1.8rem; }
.prose p { margin: 0 0 1rem; }
.prose ul { padding-left: 1.2rem; }
.content-block {
  margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--line);
}

.contacts-page h1 {
  font-family: var(--display);
  letter-spacing: -0.03em;
  margin: 0 0 1.5rem;
}
.contacts-layout {
  display: grid;
  grid-template-columns: minmax(260px, 360px) 1fr;
  gap: 1.25rem;
  align-items: stretch;
}
.contacts-info__name {
  margin: 0 0 1rem;
  font-weight: 700;
  color: var(--ink);
}
.contacts-card {
  padding: 0.95rem 1rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  margin-bottom: 0.75rem;
}
.contacts-card h2 {
  margin: 0 0 0.4rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  font-family: var(--font);
  font-weight: 700;
}
.contacts-card p { margin: 0; }
.contacts-card a {
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}
.contacts-card a:hover { color: var(--brand); }
.contacts-muted { color: var(--ink-soft); font-size: 0.92rem; }
.contacts-actions {
  display: flex; flex-wrap: wrap; gap: 0.65rem; margin-top: 1rem;
}
.contacts-actions__ghost {
  color: var(--ink);
  border-color: var(--line);
  background: #fff;
}
.contacts-map-wrap { min-width: 0; }
.contacts-map {
  height: min(560px, 70vh);
  min-height: 360px;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  background: #f3f5f4;
}
.contacts-map iframe {
  display: block; width: 100%; height: 100%; border: 0;
}
.contacts-map-note {
  margin: 0.65rem 0 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
}
.reviews-list {
  display: grid;
  gap: 0.85rem;
  margin-top: 1.5rem;
}
.review-card--list {
  flex: none;
  width: 100%;
  min-height: 0;
}
.blog-list {
  display: grid;
  gap: 0.65rem;
  margin-top: 1.5rem;
}
.blog-item {
  display: grid;
  gap: 0.35rem;
  padding: 0.95rem 1rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  text-decoration: none;
  color: var(--ink);
  background: #fff;
}
.blog-item:hover { border-color: rgba(15,107,76,.35); color: var(--ink); }
.blog-item .badge { width: fit-content; }


@media (max-width: 900px) {
  .contacts-layout { grid-template-columns: 1fr; }
  .contacts-map { min-height: 300px; height: 420px; }
}
.cta-band__inner {
  display: flex; justify-content: space-between; gap: 1.5rem; align-items: center;
  padding: 1.6rem 1.6rem;
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(15,107,76,0.95), rgba(10,69,51,0.92)),
    url("/images/zamena-korpusa-telephona.jpg") center/cover;
  color: #f7faf8;
  box-shadow: var(--shadow);
}
.cta-band h2 { margin: 0 0 0.4rem; font-family: var(--display); }
.cta-band p { margin: 0; color: rgba(247,250,248,0.86); max-width: 42ch; }

.site-footer {
  background: #102018; color: rgba(243,239,231,0.82); padding-top: 3rem;
}
.footer__grid {
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.1fr; gap: 1.5rem;
  padding-bottom: 2rem;
}
.footer__title {
  font-family: var(--display); font-size: 1rem; color: #fff; margin: 0 0 0.9rem;
}
.footer__list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.45rem; }
.footer__list a { color: inherit; text-decoration: none; }
.footer__list a:hover { color: #fff; }
.footer__brand p { max-width: 34ch; }
.footer__bottom {
  border-top: 1px solid rgba(255,255,255,0.08); padding: 1rem 0;
  font-size: 0.88rem;
}

.modal[hidden] { display: none; }
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 1rem; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(10, 20, 16, 0.55); }
.modal__dialog {
  position: relative; width: min(100%, 420px);
  background: #fff; border-radius: 18px; padding: 1.4rem;
  box-shadow: var(--shadow); animation: rise .35s ease both;
}
.modal__close {
  position: absolute; top: 0.6rem; right: 0.7rem; border: 0; background: transparent;
  font-size: 1.5rem; cursor: pointer; color: var(--ink-soft);
}
.modal__lead { color: var(--ink-soft); margin-top: 0; }
.lead-form { display: grid; gap: 0.75rem; }
.lead-form label { display: grid; gap: 0.35rem; font-weight: 600; font-size: 0.92rem; }
.lead-form input, .lead-form textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 12px;
  padding: 0.75rem 0.85rem; background: #fff;
}
.form-note, .form-status { font-size: 0.82rem; color: var(--ink-soft); margin: 0; }
.form-status.is-ok { color: var(--brand); }
.form-status.is-err { color: #b42318; }

@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}
@keyframes heroZoom {
  from { transform: scale(1.02); }
  to { transform: scale(1.08); }
}
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@media (max-width: 980px) {
  .benefits__grid { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .page-hero__inner { grid-template-columns: 1fr; }
  .page-hero__img { justify-self: start; }
  .nav-toggle { display: grid; }
  .nav {
    display: none; position: absolute; left: 1rem; right: 1rem; top: calc(100% + 0.4rem);
    background: #fff; border: 1px solid var(--line); border-radius: 16px;
    padding: 0.55rem; flex-direction: column; box-shadow: var(--shadow);
    align-items: stretch; max-height: min(70vh, 560px); overflow: auto;
  }
  .nav.is-open { display: flex; }
  .nav__item { width: 100%; }
  .nav__link { width: 100%; justify-content: space-between; }
  .nav__drop {
    position: static; opacity: 1; visibility: visible; transform: none;
    display: none; box-shadow: none; border: 0; padding: 0.25rem 0.35rem 0.75rem 0.85rem;
    max-width: none; min-width: 0;
  }
  .nav__item.is-open > .nav__drop { display: block; }
  .nav__drop-grid { grid-template-columns: 1fr 1fr; max-height: none; }
  .navbar { position: relative; }
  .search { max-width: none; order: 3; flex-basis: 100%; }
}

@media (max-width: 640px) {
  .topbar__addr, .topbar__hours { display: none; }
  .benefits__grid, .footer__grid { grid-template-columns: 1fr; }
  .hero { min-height: 78vh; }
  .hero__content { padding: 4.5rem 0 3rem; }
  .cta-band__inner { flex-direction: column; align-items: flex-start; }
  .brand-mark { font-size: 2rem; }
}
