:root {
  --bg: #f2f7f1;
  --surface: #ffffff;
  --text: #182516;
  --muted: #50634d;
  --primary: #3f9f18;
  --primary-dark: #1f7312;
  --border: #d2e6cc;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; color-scheme: light; }
body {
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

.container { width: min(1120px, 92%); margin: 0 auto; }
.header { position: sticky; top: 0; background: rgba(242, 247, 241, 0.95); border-bottom: 1px solid var(--border); backdrop-filter: blur(8px); z-index: 20; }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 92px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; font-size: 22px; }
.brand img {
  width: 80px;
  height: 75px;
  object-fit: contain;
  object-position: center center;
  border-radius: 14px;
  border: 2px solid var(--border);
  background: #fff;
  box-shadow: 0 8px 24px rgba(41, 128, 29, 0.12);
}
.brand-only { gap: 0; }
.brand-footer img {
  width: 80px;
  height: 75px;
}
.menu {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--border);
}
.menu a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  padding: 8px 14px;
  border-radius: 999px;
  transition: color .2s ease, background-color .2s ease, box-shadow .2s ease;
}
.menu a:hover {
  color: var(--primary-dark);
  background: #ffffff;
  box-shadow: 0 3px 10px rgba(31, 115, 18, 0.12);
}
.phone {
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: .01em;
  white-space: nowrap;
  padding: 10px 16px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 8px 18px rgba(31, 115, 18, 0.24);
  transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}
.phone:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
  box-shadow: 0 10px 22px rgba(31, 115, 18, 0.28);
}
.nav-phones {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: nowrap;
  justify-content: flex-end;
}
.viber-icon {
  width: 18px;
  height: 18px;
  display: inline-block;
  vertical-align: middle;
  margin-left: 4px;
}
.phone--viber {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.hero { position: relative; min-height: 72vh; display: flex; align-items: center; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(to right, rgba(8, 42, 14, 0.78), rgba(8, 42, 14, 0.35)); }
.hero-content { position: relative; color: #fff; max-width: 720px; padding: 72px 0; }
.hero h1 { font-size: clamp(34px, 6vw, 62px); line-height: 1.05; margin: 10px 0 18px; }
.hero .tag { margin: 0 0 20px; }
.hero-lead { margin: 0 0 12px; max-width: 640px; line-height: 1.55; }
.hero-lead strong { color: #d4f5c0; font-weight: 700; }
.hero-lead-guarantee { margin-bottom: 20px; opacity: 0.95; }
.tag { letter-spacing: .18em; text-transform: uppercase; font-size: 12px; color: #b5f58f; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.btn { display: inline-block; padding: 12px 20px; border-radius: 10px; text-decoration: none; border: 1px solid transparent; cursor: pointer; font-weight: 600; white-space: nowrap; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { border-color: rgba(255, 255, 255, 0.6); color: #fff; }
.btn-outline:hover { background: rgba(255, 255, 255, 0.1); }

.stats { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: rgba(255,255,255,.7); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stats-grid div { padding: 18px; border-right: 1px solid var(--border); display: grid; gap: 3px; }
.stats-grid div:last-child { border-right: none; }
.stats strong { font-size: 24px; }
.stats span { color: var(--muted); font-size: 14px; }

.section { padding: 72px 0; }
.section-alt { background: #eaf3e6; }
.section h2 { font-size: clamp(28px, 4.2vw, 46px); margin: 0 0 26px; }
.price-block { margin-top: 40px; }
.price-block:first-of-type { margin-top: 0; }
.price-block-title {
  font-size: clamp(20px, 2.8vw, 28px);
  font-weight: 700;
  margin: 0 0 16px;
  color: var(--text);
}
.price-block-note {
  margin: -6px 0 16px;
  max-width: 720px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px;
  transition: transform .28s ease, box-shadow .28s ease, border-color .28s ease;
}
.card h3 { margin: 0 0 10px; }
.card p { margin: 0; color: var(--primary-dark); font-weight: 600; }

.card--with-icon {
  position: relative;
  overflow: hidden;
}
.card-row {
  display: flex;
  flex-direction: row-reverse;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.card-text { min-width: 0; flex: 1; }
.card--with-icon:hover {
  transform: translateY(-4px);
  box-shadow:
    0 16px 36px rgba(22, 63, 18, 0.1),
    0 4px 12px rgba(31, 115, 18, 0.06);
  border-color: rgba(63, 159, 24, 0.38);
}
.card-icon {
  flex-shrink: 0;
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  color: var(--primary-dark);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.07);
  transition:
    transform .4s cubic-bezier(.34, 1.45, .64, 1),
    box-shadow .35s ease,
    border-color .25s ease;
}
.card-icon .card-picto {
  width: 68px;
  height: 68px;
  max-width: 100%;
  display: block;
}
.card--with-icon:hover .card-icon {
  transform: scale(1.03);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.1);
  border-color: #c5d6c2;
}

@keyframes card-appear {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@media (prefers-reduced-motion: no-preference) {
  .cards .card--with-icon {
    animation: card-appear .5s ease backwards;
  }
  .cards .card--with-icon:nth-child(1) { animation-delay: 0.03s; }
  .cards .card--with-icon:nth-child(2) { animation-delay: 0.06s; }
  .cards .card--with-icon:nth-child(3) { animation-delay: 0.09s; }
  .cards .card--with-icon:nth-child(4) { animation-delay: 0.12s; }
  .cards .card--with-icon:nth-child(5) { animation-delay: 0.15s; }
  .cards .card--with-icon:nth-child(6) { animation-delay: 0.18s; }
  .cards .card--with-icon:nth-child(7) { animation-delay: 0.21s; }
  .cards .card--with-icon:nth-child(8) { animation-delay: 0.24s; }
  .cards .card--with-icon:nth-child(9) { animation-delay: 0.27s; }
  .cards .card--with-icon:nth-child(10) { animation-delay: 0.3s; }
  .cards .card--with-icon:nth-child(11) { animation-delay: 0.33s; }
  .cards .card--with-icon:nth-child(12) { animation-delay: 0.36s; }
}
@media (prefers-reduced-motion: reduce) {
  .cards .card--with-icon {
    animation: none;
  }
  .card--with-icon:hover {
    transform: none;
    box-shadow: none;
  }
  .card--with-icon:hover .card-icon {
    transform: none;
  }
}

#works .container > h2 {
  margin-bottom: 20px;
}
.works-block + .works-block {
  margin-top: 48px;
}
.works-subtitle {
  font-size: clamp(20px, 2.8vw, 28px);
  font-weight: 700;
  margin: 0 0 16px;
  color: var(--text);
}

.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; border: 1px solid var(--border); }

.contact { display: block; }
.contact-cta {
  background:
    radial-gradient(1200px 240px at 50% -60%, rgba(63, 159, 24, 0.14), transparent 70%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 34px 28px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow:
    0 8px 20px rgba(22, 63, 18, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.65);
}
.contact-cta h2 {
  margin: 0 0 14px;
}
.contact-cta p {
  margin: 0;
}
.phones-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin: 16px 0 12px;
}
.phone-big {
  display: block;
  width: max-content;
  margin: 0 auto;
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 800;
  letter-spacing: .02em;
  color: #ffffff;
  text-decoration: none;
  padding: 10px 26px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: 0 12px 22px rgba(31, 115, 18, 0.26);
  transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}
.phone-big:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
  box-shadow: 0 14px 24px rgba(31, 115, 18, 0.3);
}
.phone-big.phone--disabled:hover {
  transform: none;
  filter: none;
  box-shadow: 0 12px 22px rgba(31, 115, 18, 0.26);
}
.phone-big--viber {
  display: flex;
  align-items: center;
  gap: 8px;
}
.viber-icon-big {
  width: 20px;
  height: 20px;
  display: inline-block;
  vertical-align: middle;
}
.work-time {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
  width: fit-content;
  margin: 0;
  padding: 8px 14px;
  border-radius: 999px;
  background: #f7fbf5;
  border: 1px solid var(--border);
}
.work-time strong {
  color: var(--text);
}

.footer { padding: 28px 0 36px; border-top: 1px solid var(--border); background: #edf6ea; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; color: var(--muted); font-size: 14px; }
.footer-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; text-align: right; }
.footer-tagline { margin: 0; max-width: 420px; line-height: 1.45; }
.footer-credit { margin: 0; font-size: 13px; color: var(--muted); }
.footer-credit a { color: var(--text); text-decoration: underline; text-underline-offset: 2px; }
.footer-credit a:hover { color: var(--primary-dark); }

@media (max-width: 900px) {
  .menu, .nav-phones { display: none; }
  .stats-grid, .cards, .gallery { grid-template-columns: 1fr 1fr; }
  .nav { min-height: 92px; }
  .brand img { width: 80px; height: 75px; }
  .brand-footer img { width: 80px; height: 75px; }
}
@media (max-width: 640px) {
  .stats-grid, .cards, .gallery, .footer-inner { grid-template-columns: 1fr; display: grid; }
  .footer-meta { align-items: center; text-align: center; }
  .footer-tagline { max-width: none; }
  .hero { min-height: 64vh; }
  .nav { min-height: 92px; }
  .brand img { width: 80px; height: 75px; }
  .brand-footer img { width: 80px; height: 75px; }
  .card-icon {
    width: 80px;
    height: 80px;
  }
  .card-icon .card-picto {
    width: 58px;
    height: 58px;
  }
}
