:root {
  --ink: #111a17;
  --muted: #617069;
  --line: #d8ded8;
  --paper: #f4f1ea;
  --white: #fff;
  --accent: #1f7a55;
  --accent-dark: #14583d;
  --rust: #b86d3b;
  --gold: #e7b56a;
  --shadow: 0 22px 58px rgba(17, 26, 23, .14);
  --soft-shadow: 0 10px 28px rgba(17, 26, 23, .1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .42), rgba(255, 255, 255, 0) 420px),
    var(--paper);
  font: 16px/1.55 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

input,
textarea,
select,
button {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  min-height: 72px;
  padding: 14px clamp(20px, 5vw, 72px);
  background: rgba(246, 244, 239, .92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand,
.nav,
.hero__actions,
.hero-stats,
.card-row,
.admin-actions,
.form-actions,
.header-phone,
.header-contact {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: var(--white);
  background: var(--accent);
  border-radius: 8px;
  letter-spacing: 0;
}

.nav {
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px 22px;
  color: var(--muted);
}

.header-phone {
  min-height: 42px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, .72);
  color: var(--accent-dark);
  font-weight: 800;
  box-shadow: var(--soft-shadow);
  white-space: nowrap;
}

.header-contact {
  gap: 8px;
  justify-content: flex-end;
}

.messenger {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: var(--white);
  border-radius: 12px;
  box-shadow: 0 10px 22px rgba(17, 26, 23, .16), inset 0 1px 0 rgba(255, 255, 255, .28);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

.messenger svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.messenger:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(17, 26, 23, .2), inset 0 1px 0 rgba(255, 255, 255, .32);
  filter: saturate(1.05);
}

.messenger--wa {
  background: linear-gradient(145deg, #35d56f, #0fa958);
}

.messenger--tg {
  background: linear-gradient(145deg, #36b7f3, #168bd7);
}

.nav a:hover,
.text-link:hover {
  color: var(--accent);
}

.hero {
  min-height: calc(100vh - 72px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  align-items: end;
  gap: clamp(28px, 5vw, 70px);
  padding: clamp(64px, 10vw, 120px) clamp(20px, 5vw, 72px);
  color: var(--white);
  background:
    linear-gradient(90deg, rgba(12, 21, 17, .88), rgba(12, 21, 17, .52) 46%, rgba(12, 21, 17, .18)),
    url("https://images.unsplash.com/photo-1600607687920-4e2a09cf159d?auto=format&fit=crop&w=1800&q=80") center/cover;
}

.hero__content {
  max-width: 840px;
}

.hero h1,
.page-title h1,
.house-hero h1,
.admin-head h1 {
  margin: 0;
  line-height: 1.02;
  font-size: clamp(44px, 8vw, 92px);
  letter-spacing: 0;
}

.hero h1 {
  max-width: 920px;
  font-size: clamp(44px, 7vw, 88px);
}

.hero p {
  max-width: 640px;
  font-size: 20px;
}

.hero__actions,
.admin-actions,
.form-actions {
  gap: 12px;
  flex-wrap: wrap;
}

.button,
.danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 18px;
  border: 1px solid var(--accent);
  border-radius: 8px;
  color: var(--white);
  background: var(--accent);
  cursor: pointer;
  font-weight: 700;
}

.button:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

.button--ghost {
  color: var(--ink);
  background: transparent;
}

.hero .button--ghost {
  color: var(--white);
  border-color: rgba(255, 255, 255, .68);
}

.hero-stats {
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 34px;
}

.hero-stats div {
  min-width: 150px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: 8px;
  backdrop-filter: blur(12px);
}

.hero-stats strong,
.hero-stats span {
  display: block;
}

.hero-stats strong {
  font-size: 28px;
  line-height: 1;
}

.hero-stats span {
  margin-top: 6px;
  color: rgba(255, 255, 255, .78);
  font-size: 13px;
}

.hero-card {
  display: grid;
  gap: 16px;
  padding: 24px;
  color: var(--ink);
  background: rgba(255, 255, 255, .9);
  border: 1px solid rgba(255, 255, 255, .56);
  border-radius: 8px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.hero-card span {
  color: var(--rust);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.hero-card strong {
  font-size: 24px;
  line-height: 1.2;
}

.danger {
  border-color: #b23b3b;
  background: #b23b3b;
}

.section,
.page-title,
.admin-head,
.catalog-layout,
.house-hero {
  padding: clamp(44px, 7vw, 82px) clamp(20px, 5vw, 72px);
}

.section-head,
.admin-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
}

.admin-head--compact {
  padding-top: 12px;
  padding-bottom: 22px;
}

.admin-head h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.1;
}

.trust-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin: -34px clamp(20px, 5vw, 72px) 0;
  position: relative;
  z-index: 2;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.trust-strip div {
  display: grid;
  gap: 5px;
  min-height: 120px;
  padding: 24px;
  background: var(--white);
}

.trust-strip strong {
  font-size: 20px;
}

.trust-strip span {
  color: var(--muted);
}

.sales-section {
  padding-bottom: 18px;
}

.sales-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.sales-grid article {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 230px;
  padding: 24px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--soft-shadow);
}

.sales-grid article span {
  color: var(--rust);
  font-weight: 900;
}

.sales-grid h3 {
  margin: 0;
  font-size: 22px;
  line-height: 1.18;
}

.sales-grid p {
  margin: 0;
  color: var(--muted);
}

.section h2,
.message-box h1,
.admin-form h1 {
  margin: 0 0 14px;
  font-size: clamp(30px, 5vw, 52px);
  line-height: 1.08;
  letter-spacing: 0;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--rust);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.muted {
  color: var(--muted);
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.cards-grid--catalog {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.house-card {
  overflow: hidden;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  transition: transform .18s ease, box-shadow .18s ease;
}

.house-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 28px 70px rgba(17, 26, 23, .18);
}

.house-card__image {
  display: block;
  aspect-ratio: 4 / 3;
  background: #d5d9d1;
}

.house-card__image img,
.admin-item img,
.house-hero img,
.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.house-card__body {
  padding: 20px;
}

.house-card h3 {
  margin: 0 0 8px;
  font-size: 24px;
  line-height: 1.15;
}

.house-card p {
  min-height: 74px;
  color: var(--muted);
}

.specs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 18px 0;
}

.specs span {
  padding: 7px 10px;
  background: #edf0eb;
  border-radius: 8px;
  font-weight: 700;
}

.specs--large span {
  background: var(--white);
  border: 1px solid var(--line);
}

.card-row {
  justify-content: space-between;
  gap: 12px;
}

.text-link {
  color: var(--accent-dark);
  font-weight: 800;
}

.band {
  padding: clamp(54px, 8vw, 90px) clamp(20px, 5vw, 72px);
  color: var(--white);
  background:
    linear-gradient(135deg, rgba(31, 122, 85, .26), rgba(184, 109, 59, .12)),
    var(--ink);
}

.band-head {
  max-width: 760px;
  margin-bottom: 30px;
}

.band-head h2 {
  margin: 0;
  font-size: clamp(30px, 5vw, 54px);
  line-height: 1.08;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.steps div {
  min-height: 210px;
  padding: 24px;
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 8px;
}

.steps span {
  color: #f0b487;
  font-weight: 800;
}

.two-col,
.house-details,
.estimate-section {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(320px, 1.1fr);
  gap: clamp(28px, 5vw, 72px);
}

.estimate-section {
  align-items: center;
  background:
    linear-gradient(90deg, rgba(31, 122, 85, .08), rgba(231, 181, 106, .12));
}

.estimate-points {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 22px;
}

.estimate-points span {
  padding: 9px 12px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--accent-dark);
  font-weight: 800;
  box-shadow: var(--soft-shadow);
}

.callback-note {
  display: grid;
  gap: 4px;
  margin-top: 28px;
  padding: 18px;
  background: rgba(255, 255, 255, .72);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.callback-note p {
  margin: 0;
  color: var(--muted);
}

.reviews-section {
  background: var(--paper);
}

.review-feature {
  display: grid;
  grid-template-columns: minmax(280px, .86fr) minmax(0, 1.14fr);
  gap: clamp(24px, 5vw, 64px);
  align-items: stretch;
  padding: clamp(16px, 3vw, 24px);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.review-feature + .review-feature {
  margin-top: 18px;
}

.review-photo {
  min-height: 430px;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(31, 122, 85, .18), rgba(231, 181, 106, .18)),
    #e7e3d8;
  border-radius: 8px;
}

.review-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.review-copy {
  display: grid;
  align-content: center;
  gap: 24px;
  padding: clamp(16px, 3vw, 34px);
}

.review-quote {
  margin: 0;
  font-size: clamp(24px, 4vw, 42px);
  line-height: 1.13;
  font-weight: 800;
}

.review-author {
  display: grid;
  gap: 4px;
}

.review-author strong {
  font-size: 20px;
}

.review-author span {
  color: var(--muted);
}

.review-facts {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.review-facts span {
  padding: 9px 12px;
  color: var(--accent-dark);
  background: #edf3ef;
  border-radius: 8px;
  font-weight: 800;
}

.faq-section {
  background: #f8f7f2;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.faq-grid details {
  padding: 20px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--soft-shadow);
}

.faq-grid summary {
  cursor: pointer;
  font-size: 20px;
  font-weight: 900;
}

.faq-grid p {
  margin: 14px 0 0;
  color: var(--muted);
}

.lead-form,
.admin-form,
.filters,
.message-box {
  display: grid;
  gap: 16px;
  padding: 24px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.lead-form {
  padding: clamp(22px, 4vw, 34px);
}

.form-title {
  display: grid;
  gap: 5px;
  margin-bottom: 2px;
}

.form-title strong {
  font-size: 24px;
  line-height: 1.15;
}

.form-title span,
.lead-form small {
  color: var(--muted);
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 700;
}

input,
textarea,
select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  color: var(--ink);
  background: #fbfbf8;
  border: 1px solid var(--line);
  border-radius: 8px;
}

textarea {
  resize: vertical;
}

.page-title {
  padding-bottom: 20px;
}

.catalog-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 28px;
  padding-top: 0;
}

.filters {
  align-self: start;
  position: sticky;
  top: 92px;
}

.catalog-count {
  margin-bottom: 18px;
  color: var(--muted);
  font-weight: 800;
}

.house-hero {
  display: grid;
  grid-template-columns: minmax(0, .86fr) minmax(360px, 1.14fr);
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
}

.house-hero p {
  font-size: 18px;
  color: var(--muted);
}

.house-hero img {
  aspect-ratio: 16 / 11;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.feature-list {
  display: grid;
  gap: 10px;
  padding: 0;
  list-style: none;
}

.feature-list li {
  padding: 14px 16px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.price-box {
  display: grid;
  gap: 5px;
  margin-top: 22px;
  padding: 22px;
  color: var(--white);
  background: var(--accent-dark);
  border-radius: 8px;
}

.price-box strong {
  font-size: 30px;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.gallery img {
  aspect-ratio: 4 / 3;
  border-radius: 8px;
}

.center-page {
  min-height: 65vh;
  display: grid;
  place-items: center;
  padding: 40px 20px;
}

.message-box,
.login-form {
  width: min(100%, 520px);
}

.alert {
  padding: 12px 14px;
  color: #7a1919;
  background: #fae3e3;
  border-radius: 8px;
}

.admin-list {
  display: grid;
  gap: 14px;
  padding: 0 clamp(20px, 5vw, 72px) 72px;
}

.admin-item {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.admin-item img {
  aspect-ratio: 4 / 3;
  border-radius: 6px;
}

.admin-item h3,
.admin-item p {
  margin: 0;
}

.house-edit {
  margin: 0 clamp(20px, 5vw, 72px) 72px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.checkbox-row input {
  width: 18px;
  min-height: 18px;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 36px clamp(20px, 5vw, 72px);
  color: var(--white);
  background: var(--ink);
}

.footer div {
  display: grid;
  gap: 8px;
}

.footer p {
  margin: 0;
  color: rgba(255, 255, 255, .72);
}

@media (max-width: 980px) {
  .cards-grid,
  .cards-grid--catalog,
  .steps,
  .sales-grid,
  .two-col,
  .house-details,
  .estimate-section,
  .house-hero,
  .catalog-layout,
  .hero,
  .trust-strip,
  .review-feature,
  .faq-grid {
    grid-template-columns: 1fr;
  }

  .filters {
    position: static;
  }

  .house-card p {
    min-height: 0;
  }
}

@media (max-width: 700px) {
  .section-head,
  .admin-head,
  .footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-header {
    grid-template-columns: 1fr auto;
    gap: 12px;
  }

  .nav {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
    gap: 8px 16px;
    overflow-x: auto;
    width: 100%;
    padding-bottom: 2px;
    white-space: nowrap;
  }

  .header-phone {
    min-height: 38px;
    padding: 8px 10px;
    font-size: 14px;
  }

  .header-contact {
    grid-column: 1 / -1;
    grid-row: 3;
    justify-content: flex-start;
  }

  .messenger {
    width: 38px;
    height: 38px;
  }

  .hero {
    min-height: 620px;
    padding-top: 54px;
  }

  .hero-card {
    display: none;
  }

  .trust-strip {
    margin-top: 0;
    border-radius: 0;
  }

  .sales-grid article {
    min-height: 0;
  }

  .review-photo {
    min-height: 360px;
  }

  .admin-item,
  .form-grid,
  .gallery {
    grid-template-columns: 1fr;
  }

  .admin-item img {
    width: 100%;
  }
}
