:root {
  --white: #ffffff;
  --blue-deep: #1e3a8a;
  --blue: #2563eb;
  --red: #dc2626;
  --black: #111827;
  --steel: #334155;
  --muted: #64748b;
  --line: #cbd5e1;
  --bg: #f4f7fb;
  --bg-accent: #dbeafe;
  --shadow: 0 20px 45px rgba(17, 24, 39, 0.12);
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --container: 1220px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  position: relative;
  color: var(--black);
  font-family: "Inter", "Open Sans", sans-serif;
  line-height: 1.55;
  background: transparent;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(180deg, rgba(8, 15, 31, 0.58), rgba(8, 15, 31, 0.66)),
    url("images/background.jpg") center center / cover no-repeat;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 20% -10%, rgba(37, 99, 235, 0.20), transparent 34%),
    radial-gradient(circle at 90% 0%, rgba(220, 38, 38, 0.14), transparent 38%);
  pointer-events: none;
}

body.lock-scroll {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  width: 100%;
  height: auto;
}

h1,
h2,
h3,
h4 {
  font-family: "Montserrat", "Playfair Display", serif;
  margin: 0 0 14px;
  line-height: 1.15;
  letter-spacing: 0.01em;
}

p {
  margin: 0 0 14px;
  color: var(--steel);
}

.container {
  width: min(var(--container), calc(100% - 34px));
  margin: 0 auto;
}

.section {
  padding: 74px 0;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 24px;
}

.section-head h2 {
  font-size: clamp(1.7rem, 3vw, 2.5rem);
}

.section-head p {
  max-width: 64ch;
}

/* Readable silver-white text on sections that sit directly over the photo background */
.container > .section-head h1,
.container > .section-head h2 {
  color: #eef2f7;
  text-shadow: 0 2px 12px rgba(2, 8, 23, 0.55);
}

.container > .section-head p {
  color: #dbe2ec;
  text-shadow: 0 1px 10px rgba(2, 8, 23, 0.5);
}

.container > .section-head .eyebrow {
  color: #d7e4fb;
  text-shadow: 0 1px 10px rgba(2, 8, 23, 0.45);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue-deep);
}

.eyebrow::before {
  content: "";
  width: 24px;
  height: 2px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--red), var(--blue));
}

.btn,
button {
  border: 0;
  font: inherit;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: 999px;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-deep), var(--blue));
  box-shadow: 0 10px 24px rgba(30, 58, 138, 0.25);
}

.btn-primary:hover {
  box-shadow: 0 14px 30px rgba(30, 58, 138, 0.32);
}

.btn-danger {
  color: var(--white);
  background: linear-gradient(135deg, #b91c1c, var(--red));
  box-shadow: 0 10px 24px rgba(185, 28, 28, 0.24);
}

.btn-ghost {
  color: var(--blue-deep);
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.18);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
}

.header-grid {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  min-height: 78px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: var(--white);
  font-weight: 800;
  background:
    linear-gradient(155deg, #1f2937 0%, #111827 44%, #2563eb 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-text strong {
  font-size: 1rem;
}

.brand-text span {
  font-size: 0.76rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(37, 99, 235, 0.11);
  color: var(--blue-deep);
  font-weight: 700;
}

.main-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}

.nav-link {
  padding: 9px 12px;
  border-radius: 999px;
  font-size: 0.93rem;
  font-weight: 600;
  color: #1f2937;
  border: 1px solid transparent;
}

.nav-link:hover {
  color: var(--blue-deep);
  background: rgba(37, 99, 235, 0.07);
}

.nav-link.active {
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-deep), var(--blue));
  box-shadow: 0 10px 20px rgba(30, 58, 138, 0.22);
}

.header-tools {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.site-search {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--white);
}

.site-search input {
  width: 190px;
  border: 0;
  outline: 0;
  padding: 8px 10px;
  background: transparent;
}

.site-search button {
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
  color: var(--white);
  background: linear-gradient(135deg, var(--red), #ef4444);
}

.cart-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(37, 99, 235, 0.2);
  color: var(--blue-deep);
  font-weight: 700;
  cursor: pointer;
  background: rgba(37, 99, 235, 0.08);
}

.cart-count {
  min-width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.76rem;
  color: var(--white);
  background: var(--red);
}

.hero {
  padding-top: 82px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 20px;
  align-items: stretch;
}

.hero-copy,
.hero-media,
.card,
.info-card,
.filter-panel,
.form-panel,
.calc-aside,
.article-card,
.legal-card {
  border-radius: var(--radius-lg);
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: var(--white);
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: clamp(24px, 4vw, 42px);
}

.hero-copy h1 {
  font-size: clamp(2rem, 4vw, 3.55rem);
  margin-bottom: 16px;
}

.hero-copy p {
  max-width: 60ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0 26px;
}

.hero-stats {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.hero-stats li {
  padding: 12px;
  border-radius: 12px;
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.15);
}

.hero-stats strong {
  display: block;
  font-size: 1.1rem;
  color: var(--black);
}

.hero-media {
  position: relative;
  overflow: hidden;
  min-height: 360px;
  background: #0f172a;
}

.hero-media img {
  height: 100%;
  object-fit: cover;
}

.hero-badge {
  position: absolute;
  right: 16px;
  bottom: 16px;
  max-width: 260px;
  padding: 14px;
  border-radius: 14px;
  color: var(--white);
  background: rgba(17, 24, 39, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.slider-shell {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
}

.slider-btn {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  cursor: pointer;
  color: var(--blue-deep);
  background: var(--white);
  border: 1px solid rgba(37, 99, 235, 0.2);
}

.slider-track {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 8px;
}

.slider-track::-webkit-scrollbar {
  height: 8px;
}

.slider-track::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(30, 58, 138, 0.35);
}

.project-slide {
  flex: 0 0 min(360px, 82vw);
  scroll-snap-align: start;
}

.card {
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 40px rgba(17, 24, 39, 0.17);
}

.card-image {
  aspect-ratio: 16 / 10;
  background: #cbd5e1;
  position: relative;
  overflow: hidden;
}

.card-image img {
  height: 100%;
  object-fit: cover;
}

.card-body {
  padding: 16px;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: baseline;
  margin-bottom: 8px;
}

.price {
  font-weight: 700;
  color: var(--red);
}

.grid-3,
.grid-4,
.info-grid,
.blog-grid,
.product-grid,
.portfolio-grid,
.cert-grid,
.team-grid,
.guarantee-grid,
.review-grid {
  display: grid;
  gap: 16px;
}

.grid-3,
.blog-grid,
.review-grid,
.team-grid,
.guarantee-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid-4,
.info-grid,
.product-grid,
.portfolio-grid,
.cert-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.feature {
  padding: 18px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.78);
}

.feature h3 {
  font-size: 1.15rem;
}

.icon-mark {
  width: 34px;
  height: 34px;
  margin-bottom: 10px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: var(--white);
  font-weight: 700;
  background: linear-gradient(135deg, var(--blue), var(--blue-deep));
}

.steps {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
}

.steps li {
  display: grid;
  grid-template-columns: 42px 1fr;
  align-items: start;
  gap: 12px;
  padding: 14px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: var(--white);
}

.step-num {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: var(--white);
  font-weight: 700;
  background: linear-gradient(135deg, var(--red), #ef4444);
}

.form-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-grid .full {
  grid-column: 1 / -1;
}

.form-panel,
.filter-panel,
.calc-aside,
.info-card,
.article-card,
.legal-card {
  padding: 20px;
}

label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  color: var(--black);
}

input,
select,
textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: #f8fafc;
  font: inherit;
}

textarea {
  min-height: 110px;
  resize: vertical;
}

.chip-row,
.category-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip,
.category-chip {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(37, 99, 235, 0.25);
  color: var(--blue-deep);
  background: rgba(37, 99, 235, 0.06);
  cursor: pointer;
  font-weight: 600;
}

.chip.active,
.category-chip.active {
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-deep), var(--blue));
  box-shadow: 0 10px 20px rgba(30, 58, 138, 0.22);
}

.catalog-tools {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
}

.catalog-filters-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: end;
}

.price-range-block {
  display: grid;
  gap: 6px;
}

.price-range-block input {
  width: 100%;
}

.results-meta {
  margin: 10px 0;
  color: var(--muted);
}

.calc-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 18px;
}

.calc-price {
  margin: 0 0 10px;
  font-size: clamp(2rem, 3vw, 2.8rem);
  color: var(--red);
  font-weight: 800;
}

.checkbox-row {
  display: grid;
  gap: 8px;
}

.checkbox-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.checkbox-item input {
  width: auto;
}

.contacts-layout {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 18px;
}

.map-wrap {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.32);
  box-shadow: var(--shadow);
}

.map-wrap.route-enabled {
  position: relative;
  display: block;
  cursor: pointer;
}

.map-wrap.route-enabled iframe {
  pointer-events: none;
}

.map-route-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 4px;
  padding: 18px;
  color: var(--white);
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.72) 0%, rgba(15, 23, 42, 0.16) 48%, transparent 82%);
}

.map-route-overlay strong {
  font-size: 1.02rem;
}

.map-route-overlay span {
  font-size: 0.9rem;
  opacity: 0.92;
}

.map-wrap iframe {
  display: block;
  width: 100%;
  height: 380px;
  border: 0;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table td {
  padding: 8px 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.34);
}

.table td:first-child {
  color: var(--muted);
  width: 190px;
}

.article-card h2 {
  margin-bottom: 12px;
}

.article-card ul,
.article-card ol {
  margin: 0 0 14px;
  padding-left: 20px;
}

.article-card li {
  margin-bottom: 8px;
  color: var(--steel);
}

.anchor-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.anchor-nav a {
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--blue-deep);
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.2);
}

.site-footer {
  margin-top: 64px;
  border-top: 1px solid rgba(148, 163, 184, 0.3);
  background:
    linear-gradient(170deg, #0f172a 0%, #111827 55%, #1e3a8a 100%);
  color: rgba(255, 255, 255, 0.9);
}

.footer-grid {
  padding: 40px 0 20px;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 18px;
}

.footer-title {
  margin-bottom: 10px;
  color: var(--white);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.84);
}

.footer-links a:hover {
  color: var(--white);
}

.footer-bottom {
  padding: 16px 0 24px;
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
}

.search-modal,
.cart-drawer-overlay,
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
}

.search-modal[hidden],
.modal-overlay[hidden] {
  display: none;
}

.search-modal {
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, 0.56);
}

.search-modal-inner {
  width: min(760px, calc(100% - 24px));
  max-height: min(78vh, 760px);
  overflow: auto;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: var(--white);
  box-shadow: var(--shadow);
  padding: 18px;
}

.search-result-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}

.search-result-list li a {
  display: block;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #f8fafc;
}

.search-result-list small {
  color: var(--muted);
}

.cart-drawer-overlay {
  background: rgba(15, 23, 42, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.cart-drawer {
  position: fixed;
  z-index: 130;
  top: 0;
  right: 0;
  width: min(520px, 100%);
  height: 100dvh;
  padding: 18px;
  border-left: 1px solid rgba(148, 163, 184, 0.4);
  background: #f8fafc;
  box-shadow: -18px 0 32px rgba(15, 23, 42, 0.2);
  transform: translateX(104%);
  transition: transform 0.26s ease;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 12px;
}

.cart-drawer.open {
  transform: translateX(0);
}

.cart-drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.cart-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.cart-items {
  overflow: auto;
  display: grid;
  gap: 10px;
}

.cart-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.32);
  background: var(--white);
}

.cart-item h4 {
  margin: 0 0 6px;
  font-size: 1rem;
}

.cart-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.cart-actions button {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  color: var(--blue-deep);
  cursor: pointer;
  border: 1px solid rgba(37, 99, 235, 0.18);
  background: rgba(37, 99, 235, 0.08);
}

.cart-total {
  font-size: 1.05rem;
  font-weight: 700;
}

.modal-overlay {
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, 0.62);
}

.modal-content {
  width: min(820px, calc(100% - 24px));
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: var(--white);
  box-shadow: var(--shadow);
}

.modal-body {
  padding: 18px;
}

.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.35);
}

.modal-head button,
.close-btn {
  border-radius: 10px;
  padding: 8px 12px;
  cursor: pointer;
  color: var(--blue-deep);
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.18);
}

[data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

[data-reveal].visible {
  opacity: 1;
  transform: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.muted {
  color: var(--muted);
}

.mt-0 {
  margin-top: 0;
}

@media (max-width: 1170px) {
  .header-grid {
    grid-template-columns: auto auto 1fr;
    gap: 12px;
  }

  .menu-toggle {
    display: inline-grid;
    place-items: center;
  }

  .main-nav {
    position: absolute;
    top: 78px;
    left: 0;
    right: 0;
    display: none;
    padding: 12px;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid rgba(148, 163, 184, 0.28);
    justify-content: flex-start;
  }

  .site-header.nav-open .main-nav {
    display: flex;
  }

  .header-tools {
    justify-self: end;
  }

  .site-search input {
    width: 136px;
  }

  .hero-grid,
  .calc-layout,
  .contacts-layout {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-4,
  .info-grid,
  .product-grid,
  .portfolio-grid,
  .cert-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .section {
    padding: 62px 0;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-stats {
    grid-template-columns: 1fr;
  }

  .grid-3,
  .blog-grid,
  .review-grid,
  .team-grid,
  .guarantee-grid {
    grid-template-columns: 1fr;
  }

  .catalog-filters-row {
    grid-template-columns: 1fr;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(var(--container), calc(100% - 22px));
  }

  .header-grid {
    min-height: 70px;
  }

  .brand-text span {
    display: none;
  }

  .header-tools {
    gap: 6px;
  }

  .site-search {
    display: inline-flex;
  }

  .site-search input {
    width: 96px;
  }

  .cart-toggle {
    padding: 8px 11px;
  }

  .hero {
    padding-top: 66px;
  }

  .hero-badge {
    max-width: calc(100% - 24px);
  }

  .project-slide {
    flex: 0 0 88vw;
  }

  .grid-4,
  .info-grid,
  .product-grid,
  .portfolio-grid,
  .cert-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}
