:root {
  --canvas: #f4f7fb;
  --surface: #fff;
  --ink: #142033;
  --muted: #586579;
  --primary: #1c53d7;
  --primary-hover: #173fa5;
  --accent: #e9f0ff;
  --line: #dfe6f0;
  --radius: 20px;
  --font: Inter, 'Segoe UI', system-ui, sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font: 16px/1.55 var(--font);
}
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled, select:disabled { cursor: not-allowed; opacity: .55; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { line-height: 1.14; letter-spacing: -.042em; }
h2 { font-size: clamp(1.5rem, 2.8vw, 2.17rem); font-weight: 750; }
h3 { font-size: 1.05rem; font-weight: 750; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #83aeff; outline-offset: 3px; }
.shell { width: min(100% - 64px, 1220px); margin-inline: auto; }
.symbols { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon {
  width: 20px;
  height: 20px;
  flex: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  border-bottom: 1px solid var(--line);
  background: #fff;
}
.header-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  min-height: 73px;
}
.brand { display: inline-flex; align-items: center; gap: 11px; justify-self: start; white-space: nowrap; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 39px;
  height: 39px;
  flex: none;
  border-radius: 10px;
  background: #142338;
  color: white;
}
.brand-mark svg { width: 31px; height: 31px; }
.brand-name { font-size: 1.35rem; font-weight: 800; letter-spacing: -.055em; line-height: 1.08; }
.brand-name small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: 0;
}
.navigation { display: flex; align-items: center; gap: 37px; color: #43516a; font-size: .94rem; font-weight: 650; }
.navigation a { padding: 15px 2px; }
.navigation a:hover, .footer a:hover { color: var(--primary); }
.header-actions, .hero-actions { display: flex; align-items: center; gap: 10px; }
.header-actions { justify-content: flex-end; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 43px;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-size: .89rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  transition: background-color .18s, border-color .18s, color .18s;
}
.button .icon { width: 18px; height: 18px; }
.primary { border-color: var(--primary); background: var(--primary); color: #fff; }
.primary:hover { border-color: var(--primary-hover); background: var(--primary-hover); }
.ghost, .light { border-color: #d5dfeb; background: #fff; color: #21324b; }
.ghost:hover, .light:hover, .icon-button:hover { border-color: #a9bfed; background: #f0f5ff; color: var(--primary); }
.mobile-toggle { display: none; }

.hero {
  display: grid;
  grid-template-columns: .96fr 1.04fr;
  align-items: stretch;
  min-height: 410px;
  margin-top: 29px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 25px;
  background: #fff;
}
.hero-visual {
  grid-column: 2;
  grid-row: 1;
  background: #1c2a40 url('./repair-hero.webp') center 48% / cover no-repeat;
}
.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
  padding: clamp(28px, 4.1vw, 62px);
}
.hero h1 { font-size: clamp(2.4rem, 5vw, 4.35rem); font-weight: 800; line-height: 1.02; letter-spacing: -.069em; }
.hero h1 span { color: var(--primary); }
.hero-description { max-width: 405px; margin-top: 23px; color: var(--muted); font-size: 1.04rem; }
.hero-actions { flex-wrap: wrap; margin-top: 28px; }
.hero-actions .button { min-height: 47px; padding-inline: 16px; }

.surface { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.estimate { margin: 23px 0 0; padding: 23px 28px 25px; box-shadow: 0 12px 26px #1a3f7020; }
.estimate-title { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.estimate-title h2 { font-size: 1.32rem; }
.estimate-title p, .section-header p, .faq > div > p { margin-top: 5px; color: var(--muted); font-size: .94rem; }
.section-icon {
  display: grid;
  place-items: center;
  width: 43px;
  height: 43px;
  flex: none;
  border-radius: 11px;
  background: var(--accent);
  color: var(--primary);
}
.section-icon .icon { width: 22px; height: 22px; }
.quote-grid { display: grid; grid-template-columns: 1fr 1.15fr 1.1fr auto; align-items: end; gap: 14px; }
label { display: flex; flex-direction: column; gap: 7px; min-width: 0; color: #2b374c; font-size: .89rem; font-weight: 650; }
.select { position: relative; display: block; }
.select .icon {
  position: absolute;
  top: 50%;
  right: 12px;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
  color: #60728d;
  pointer-events: none;
}
input, select, textarea {
  width: 100%;
  min-width: 0;
  padding: 0 12px;
  border: 1px solid #d8e1ed;
  border-radius: 9px;
  background: #f7faff;
  color: var(--ink);
  font-size: .91rem;
  font-weight: 500;
}
input, select { height: 45px; }
select { appearance: none; padding-right: 35px; }
textarea { min-height: 66px; padding-block: 9px; resize: vertical; }
select:invalid, input::placeholder, textarea::placeholder { color: #68758a; opacity: 1; }
input:focus, select:focus, textarea:focus { outline: 2px solid #80a8fa; outline-offset: 1px; }
.quote-button { height: 45px; padding-inline: 20px; }
.quote-result {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 17px;
  margin-top: 18px;
  padding: 14px 16px;
  border: 1px solid #cbdbff;
  border-radius: 11px;
  background: #edf4ff;
}
.quote-result strong { display: block; color: var(--primary); font-size: 1.24rem; }
.quote-result p { margin-top: 4px; color: var(--muted); font-size: .88rem; }

.section { margin-top: 50px; }
.section-header { margin-bottom: 20px; }
.service-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.service-card {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 14px;
  row-gap: 4px;
  align-content: center;
  min-width: 0;
  min-height: 98px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  transition: background-color .18s, border-color .18s, box-shadow .18s;
}
.service-card:hover { border-color: #afc6f6; background: #fbfdff; box-shadow: 0 5px 16px #1c4f9612; }
.service-card .section-icon { grid-row: 1 / span 2; align-self: center; }
.service-card p, .process-grid p, .questions p { color: var(--muted); font-size: .93rem; line-height: 1.55; }
.service-card:nth-child(2) .section-icon { background: #e5f6ef; color: #176d51; }
.service-card:nth-child(3) .section-icon { background: #edf1fb; color: #445786; }
.service-card:nth-child(4) .section-icon { background: #e5f3fa; color: #1b657c; }

.process { padding: clamp(23px, 4vw, 43px); border-color: #14243d; background: #14243d; color: white; }
.process .section-header p, .process-grid p { color: #cad6e8; }
.process .section-header { margin-bottom: 25px; }
.process-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.process-grid article { min-width: 0; }
.process-grid article + article { padding-left: 20px; border-left: 1px solid #3c506b; }
.process-grid .section-icon { background: #234467; color: #b6d4ff; }
.process-grid h3 { margin: 11px 0 7px; }
.faq { display: grid; grid-template-columns: .85fr 1.4fr; gap: 36px; margin-bottom: 54px; }
.faq > div > p { margin-top: 8px; }
.questions { border-top: 1px solid var(--line); }
.questions details { border-bottom: 1px solid var(--line); }
summary { display: flex; justify-content: space-between; align-items: center; gap: 10px; min-height: 55px; font-size: .96rem; font-weight: 700; cursor: pointer; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary .icon { width: 17px; height: 17px; color: var(--primary); transition: transform .15s; }
details[open] summary .icon { transform: rotate(180deg); }
.questions p { margin: 0 20px 15px 0; }
.footer { border-top: 1px solid var(--line); background: #fff; }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 14px 24px; min-height: 85px; }
.footer-inner p, .footer-inner > a:last-child { color: var(--muted); font-size: .86rem; }

body:has(dialog[open]) { overflow: hidden; }
dialog {
  width: min(calc(100% - 26px), 510px);
  max-height: calc(100% - 26px);
  padding: 0;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 19px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 24px 95px #0c1a3655;
}
dialog::backdrop { background: #12203ba0; }
.dialog-head { display: flex; align-items: start; justify-content: space-between; gap: 10px; padding: 22px 22px 16px; border-bottom: 1px solid var(--line); }
.dialog-head h2 { font-size: 1.35rem; }
.dialog-head p { margin-top: 5px; color: var(--muted); font-size: .91rem; }
.icon-button { width: 38px; min-height: 38px; padding: 0; flex: none; border-color: #e0e9f5; background: #f4f7fc; color: #233956; }
.dialog-form { display: grid; gap: 12px; padding: 18px 22px 22px; }
.dialog-form .primary { justify-self: stretch; }
.field-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.optional { display: contents; color: var(--muted); font-size: .84rem; }
.dialog-result { padding: 0 22px 20px; }
.form-error { color: #a02943; font-size: .9rem; }
.receipt { padding: 13px 15px; border: 1px solid #d0dfff; border-radius: 12px; background: #eef4ff; }
.receipt .receipt-code { margin: 3px 0 6px; color: var(--primary); font-size: 1.23rem; font-weight: 800; letter-spacing: .062em; }
.receipt p { color: var(--muted); font-size: .91rem; overflow-wrap: anywhere; }
.receipt strong { display: block; margin-bottom: 5px; }
.receipt + .button { margin-top: 4px; }

@media (max-width: 1000px) {
  .shell { width: calc(100% - 42px); }
  .header-inner { gap: 17px; }
  .navigation { gap: 23px; }
  .hero { min-height: 360px; }
  .hero-copy { padding: 29px; }
  .hero h1 { font-size: clamp(2.35rem, 5.4vw, 3.8rem); }
  .estimate { padding-inline: 21px; }
}
@media (max-width: 760px) {
  .header-inner { position: relative; display: flex; min-height: 64px; gap: 8px; }
  .brand { margin-right: auto; }
  .brand-mark { width: 34px; height: 34px; }
  .brand-mark svg { width: 27px; height: 27px; }
  .brand-name { font-size: 1.18rem; }
  .brand-name small { font-size: .68rem; }
  .header-actions { gap: 6px; }
  .header-actions .button { min-height: 37px; padding-inline: 10px; font-size: .83rem; }
  .header-actions .icon { width: 15px; height: 15px; }
  .mobile-toggle { display: inline-flex; width: 38px; min-height: 37px; padding: 0; order: 3; }
  .navigation {
    display: none;
    position: absolute;
    z-index: 10;
    top: calc(100% + 5px);
    right: 0;
    min-width: 180px;
    padding: 6px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 12px 24px #172c5023;
  }
  .navigation.open { display: grid; gap: 0; }
  .navigation a { display: block; padding: 10px 12px; border-radius: 7px; }
  .navigation a:hover { background: #eef4ff; }
  .hero { grid-template-columns: 1fr 1fr; min-height: 328px; margin-top: 17px; border-radius: 17px; }
  .hero-copy { padding: 23px; }
  .hero h1 { font-size: clamp(2.04rem, 5vw, 3rem); }
  .hero-description { margin-top: 14px; font-size: .96rem; }
  .hero-actions { margin-top: 18px; }
  .hero-actions .button { min-height: 40px; padding-inline: 11px; }
  .estimate { margin-top: 16px; padding: 18px 17px; }
  .quote-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
  .section { margin-top: 37px; }
  .faq { grid-template-columns: 1fr; gap: 15px; margin-bottom: 39px; }
  .process-grid { gap: 17px; }
  .process-grid article + article { padding-left: 13px; }
}
@media (max-width: 520px) {
  .shell { width: calc(100% - 26px); }
  .header-inner { gap: 6px; }
  .header-actions .icon { display: none; }
  .header-actions .button { min-height: 35px; padding-inline: 8px; }
  .brand { gap: 7px; }
  .brand-name small { display: none; }
  .mobile-toggle { width: 33px; min-height: 35px; }
  .hero { grid-template-columns: 1fr; }
  .hero-visual { grid-column: 1; grid-row: 1; min-height: 183px; background-position: center 51%; }
  .hero-copy { grid-column: 1; grid-row: 2; padding: 21px 18px 23px; }
  .hero h1 { font-size: clamp(2.12rem, 10vw, 3.15rem); }
  .hero-description { margin-top: 12px; font-size: .91rem; }
  .hero-actions { gap: 8px; margin-top: 16px; }
  .hero-actions .button { min-height: 39px; padding-inline: 10px; font-size: .85rem; }
  .hero-actions .icon { width: 16px; height: 16px; }
  .estimate { padding: 15px 12px; }
  .estimate-title { margin-bottom: 14px; }
  .estimate-title p { font-size: .88rem; }
  .quote-grid { gap: 10px 8px; }
  .quote-grid .button { padding-inline: 8px; }
  .quote-result { align-items: start; flex-direction: column; }
  .service-grid { grid-template-columns: 1fr; gap: 9px; }
  .service-card { min-height: 80px; padding: 12px 13px; }
  .process-grid { grid-template-columns: 1fr; }
  .process-grid article + article { padding: 13px 0 0; border-top: 1px solid #3c506b; border-left: 0; }
  .footer-inner { padding-block: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

.catalog-status { margin-top: 13px; color: var(--muted); font-size: .92rem; }
