:root {
  --bg: #f4f0e8;
  --surface: #ffffff;
  --surface-strong: #fbf8f2;
  --ink: #17171a;
  --muted: #64666c;
  --line: #ddd5c7;
  --accent: #d81f26;
  --accent-dark: #a41219;
  --steel: #22313c;
  --sand: #efe6d9;
  --success: #1c7b4f;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(216, 31, 38, 0.08), transparent 26%),
    linear-gradient(180deg, #f7f4ed 0%, #f2ede4 100%);
  font-family: "Manrope", sans-serif;
  line-height: 1.45;
}

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

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

button,
input,
select {
  font: inherit;
}

.topline {
  display: flex;
  justify-content: center;
  gap: 28px;
  padding: 10px 18px;
  color: #fff;
  background: var(--steel);
  font-size: 13px;
  font-weight: 700;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 28px;
  padding: 18px clamp(18px, 4vw, 64px);
  background: rgba(247, 244, 237, 0.92);
  border-bottom: 1px solid rgba(23, 23, 26, 0.08);
  backdrop-filter: blur(14px);
}

.brand,
.header-actions,
.main-nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: 12px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), #ef4a3e);
  font-weight: 800;
}

.brand-copy {
  display: grid;
}

.brand-copy strong {
  font-size: 18px;
}

.brand-copy small {
  color: var(--muted);
  font-size: 12px;
}

.main-nav {
  justify-content: center;
  gap: clamp(16px, 3vw, 30px);
  font-size: 14px;
  font-weight: 700;
}

.main-nav a:hover,
.header-phone:hover {
  color: var(--accent);
}

.header-actions {
  gap: 14px;
}

.header-phone {
  font-weight: 800;
  white-space: nowrap;
}

.ghost-button,
.footer-button,
.back-link {
  padding: 0;
  border: 0;
  color: var(--accent);
  background: transparent;
  cursor: pointer;
  font-weight: 800;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 5px auto;
  background: var(--ink);
}

.hero,
.offer-section,
.value-section,
.cases-section,
.contacts-section {
  padding: clamp(34px, 6vw, 84px) clamp(18px, 5vw, 72px);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 420px);
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

.hero-copy {
  padding-top: 20px;
}

.eyebrow,
.card-eyebrow {
  margin: 0 0 14px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 860px;
  margin-bottom: 20px;
  font-size: clamp(38px, 5.7vw, 74px);
  line-height: 0.98;
  font-weight: 800;
}

h2 {
  margin-bottom: 16px;
  font-size: clamp(28px, 4vw, 52px);
  line-height: 1.02;
  font-weight: 800;
}

h3 {
  margin-bottom: 10px;
  font-size: 22px;
  line-height: 1.15;
}

.lead,
.card-copy,
.proof-strip p,
.offer-grid p,
.value-grid p,
.offer-form-card p {
  color: var(--muted);
}

.lead {
  max-width: 720px;
  margin-bottom: 28px;
  font-size: clamp(17px, 1.7vw, 21px);
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.hero-tags span {
  padding: 10px 14px;
  border: 1px solid rgba(23, 23, 26, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  font-size: 14px;
  font-weight: 700;
}

.hero-actions,
.contact-actions,
.footer-links,
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
  text-align: center;
  text-transform: uppercase;
}

.button-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), #ee4d42);
}

.button-primary:hover {
  background: linear-gradient(135deg, var(--accent-dark), #d6342c);
}

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

.button-dark {
  color: #fff;
  background: var(--ink);
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  max-width: 840px;
  margin: 36px 0 0;
}

.hero-metrics div {
  padding: 18px 20px;
  border: 1px solid rgba(23, 23, 26, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.7);
}

.hero-metrics dt {
  margin-bottom: 8px;
  font-size: 24px;
  font-weight: 800;
}

.hero-metrics dd {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.lead-card,
.proof-strip article,
.offer-grid article,
.offer-form-card,
.value-grid article,
.case-card,
.contacts-card,
.address-card,
.slidein,
.modal-panel {
  border: 1px solid rgba(23, 23, 26, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 16px 44px rgba(30, 30, 30, 0.08);
}

.lead-card {
  padding: 26px;
}

.lead-card h2 {
  font-size: clamp(28px, 3vw, 36px);
}

.lead-form,
.compact-form {
  display: grid;
  gap: 12px;
}

.form-step {
  display: none;
  gap: 12px;
}

.form-step.is-active {
  display: grid;
}

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

.segment-button {
  min-height: 52px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  font-weight: 700;
}

.segment-button.is-selected {
  color: #fff;
  border-color: var(--accent);
  background: var(--accent);
}

label span {
  display: block;
  margin: 0 0 8px 2px;
  font-size: 13px;
  font-weight: 700;
}

input,
select {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 16px;
  background: #fff;
}

input:focus,
select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(216, 31, 38, 0.12);
}

.form-note {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.proof-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  padding: 0 clamp(18px, 5vw, 72px);
}

.proof-strip article {
  padding: 24px;
}

.proof-strip strong {
  display: block;
  margin-bottom: 10px;
  font-size: 20px;
}

.section-head {
  display: grid;
  grid-template-columns: minmax(180px, 0.3fr) minmax(0, 0.7fr);
  gap: 28px;
  align-items: start;
  margin-bottom: 36px;
}

.offer-layout,
.offer-grid,
.value-grid {
  display: grid;
  gap: 14px;
}

.offer-layout {
  grid-template-columns: minmax(0, 1.5fr) minmax(320px, 0.82fr);
  align-items: stretch;
}

.offer-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: 1fr;
}

.value-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.offer-grid article,
.value-grid article {
  min-height: 205px;
  padding: 24px;
}

.offer-form-card {
  padding: 24px;
  height: 100%;
}

.offer-form-card h3 {
  font-size: 30px;
}

.value-grid span {
  display: block;
  margin-bottom: 26px;
  color: var(--accent);
  font-weight: 800;
}

.cases-section {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0));
}

.case-cards {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 14px;
}

.case-card {
  overflow: hidden;
}

.case-card-large {
  grid-row: span 2;
}

.case-card img {
  width: 100%;
  height: 100%;
  min-height: 300px;
  object-fit: cover;
}

.case-card-large img {
  min-height: 614px;
}

.contacts-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.contacts-card,
.address-card {
  padding: 28px;
}

.contact-meta {
  display: grid;
  gap: 10px;
  margin-top: 22px;
  font-size: 22px;
  font-weight: 800;
}

.address-card ul {
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
}

.address-card li + li {
  margin-top: 10px;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 24px clamp(18px, 5vw, 72px) 96px;
  color: #d8d9dc;
  background: #14161b;
  font-size: 13px;
}

.footer-links {
  justify-content: flex-end;
}

.footer-links a,
.footer-button {
  color: #fff;
}

.floating-bar {
  position: fixed;
  right: 12px;
  bottom: 12px;
  left: 12px;
  z-index: 26;
  display: none;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(23, 23, 26, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.14);
}

.floating-bar a,
.floating-bar button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 0;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  font-weight: 800;
}

.floating-bar button {
  background: var(--accent);
  cursor: pointer;
}

.slidein {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 28;
  width: min(360px, calc(100vw - 36px));
  padding: 22px;
  padding-top: 28px;
  transform: translateY(140%);
  transition: transform 0.35s ease;
}

.slidein.is-visible {
  transform: translateY(0);
}

.slidein-close,
.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
}

.slidein-close::before,
.slidein-close::after,
.modal-close::before,
.modal-close::after {
  position: absolute;
  top: 18px;
  left: 11px;
  width: 14px;
  height: 2px;
  content: "";
  background: var(--ink);
}

.slidein-close::before,
.modal-close::before {
  transform: rotate(45deg);
}

.slidein-close::after,
.modal-close::after {
  transform: rotate(-45deg);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: none;
  place-items: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.56);
}

.modal.is-open {
  display: grid;
}

.modal-panel {
  position: relative;
  width: min(520px, 100%);
  padding: 28px;
  padding-right: 76px;
}

.success-state {
  color: var(--success);
}

.slidein h3,
.modal-panel h2 {
  padding-right: 44px;
}

.consent-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.consent-check input {
  width: 16px;
  min-width: 16px;
  height: 16px;
  min-height: 16px;
  margin: 2px 0 0;
  border-radius: 4px;
  padding: 0;
}

.consent-check span {
  display: inline;
  margin: 0;
  font-size: inherit;
  font-weight: 500;
}

.consent-check a {
  color: var(--ink);
  text-decoration: underline;
}

@media (max-width: 1100px) {
  .site-header {
    grid-template-columns: auto auto;
  }

  .menu-toggle {
    display: block;
    justify-self: end;
  }

  .main-nav,
  .header-actions {
    display: none;
  }

  .site-header.is-open .main-nav,
  .site-header.is-open .header-actions {
    display: flex;
    grid-column: 1 / -1;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .hero,
  .contacts-section,
  .case-cards,
  .offer-layout,
  .offer-grid,
  .value-grid,
  .proof-strip {
    grid-template-columns: 1fr;
  }

  .section-head {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .case-card-large {
    grid-row: auto;
  }

  .case-card-large img {
    min-height: 360px;
  }
}

@media (max-width: 720px) {
  .topline {
    display: none;
  }

  .hero-metrics {
    grid-template-columns: 1fr;
  }

  .segment-grid {
    grid-template-columns: 1fr 1fr;
  }

  .floating-bar {
    display: grid;
  }

  .slidein {
    right: 12px;
    bottom: 82px;
    left: 12px;
    width: auto;
  }

  .offer-grid {
    grid-template-columns: 1fr;
  }

  .site-footer {
    flex-direction: column;
    padding-bottom: 132px;
  }

  .contact-meta {
    font-size: 18px;
  }
}
