/* Compact vertical rhythm requested for the Samara site. */

/* Shared headings. */
.section-header {
  margin-bottom: clamp(24px, 2.6vw, 38px);
}

.gallery-header,
.engineering-header {
  margin-bottom: clamp(24px, 2.5vw, 34px);
}

/* Home page: keep consecutive sections visually connected. */
.page-home #systems.systems {
  padding-bottom: 48px !important;
}

.page-home #profiles.profile-atelier {
  padding-bottom: 52px !important;
}

.page-home #quality.quality-showcase {
  padding: clamp(40px, 4vw, 56px) 0 !important;
}

.page-home #quality .quality-intro {
  margin-bottom: 28px;
}

.page-home #quality .quality-intro .section-title {
  font-size: clamp(34px, 3.2vw, 50px) !important;
}

.page-home #quality .why-it-matters {
  margin-top: clamp(34px, 3.4vw, 48px);
}

.page-home #atlas.atlas-laboratory {
  margin-bottom: 0 !important;
}

.page-home #engineering.engineering {
  margin-top: 0 !important;
  padding: clamp(42px, 4vw, 54px) 0 clamp(46px, 4.4vw, 60px) !important;
}

.page-home #engineering .engineering-header {
  margin-bottom: 28px !important;
}

.page-home #club.club {
  margin-top: 0 !important;
  padding: clamp(42px, 4vw, 54px) 0 clamp(46px, 4.4vw, 60px) !important;
}

.page-home #club .club-header {
  margin-bottom: 30px;
}

.page-home #club .rating-platforms {
  margin-bottom: 32px;
}

.page-home #club .reviews-grid {
  margin-bottom: 40px;
}

.page-home #dialog.dialog.dialog-v20 {
  margin-top: 0 !important;
  padding-top: 8px !important;
  padding-bottom: 16px !important;
}

/* New catalogue pages. */
.page-proflist .product-section,
.page-shtaketnik .product-section {
  padding-top: clamp(52px, 5vw, 68px);
  padding-bottom: clamp(52px, 5vw, 68px);
}

.page-proflist .product-heading,
.page-shtaketnik .product-heading {
  margin-bottom: 30px;
}

/* Coatings page. */
.palette-body .palette-section {
  padding-top: clamp(48px, 4.8vw, 64px);
  padding-bottom: clamp(48px, 4.8vw, 64px);
}

.palette-body .palette-heading {
  margin-bottom: 30px;
}

/* Portfolio and pages that retained 64–100 px empty bands. */
.pf-catalog {
  padding-bottom: 60px;
}

.construct-exploded,
.gallery-frames {
  padding-top: 48px;
  padding-bottom: 48px;
}

.page-zhalyuzi .jal-profiles,
.page-zhalyuzi .gallery-showcase,
.page-zhalyuzi #quality.quality-showcase,
.page-zhalyuzi .install-section {
  padding-top: 48px !important;
  padding-bottom: 48px !important;
}

.page-zhalyuzi .install-section {
  margin-bottom: 0 !important;
}

@media (max-width: 768px) {
  .page-home #systems.systems {
    padding-bottom: 40px !important;
  }

  .page-home #profiles.profile-atelier {
    padding-bottom: 44px !important;
  }

  .page-home #quality.quality-showcase {
    padding: 34px 0 !important;
  }

  .page-home #quality .quality-intro .section-title {
    font-size: clamp(30px, 8vw, 40px) !important;
  }

  .page-home #engineering.engineering,
  .page-home #club.club {
    padding-top: 36px !important;
    padding-bottom: 42px !important;
  }

  .page-home #dialog.dialog.dialog-v20 {
    padding-top: 20px !important;
    padding-bottom: 24px !important;
  }

  .page-proflist .product-section,
  .page-shtaketnik .product-section,
  .palette-body .palette-section {
    padding-top: 44px;
    padding-bottom: 44px;
  }

  .pf-catalog {
    padding-bottom: 52px;
  }

  .construct-exploded,
  .gallery-frames,
  .page-zhalyuzi .jal-profiles,
  .page-zhalyuzi .gallery-showcase,
  .page-zhalyuzi #quality.quality-showcase,
  .page-zhalyuzi .install-section {
    padding-top: 40px !important;
    padding-bottom: 40px !important;
  }
}

/* Final phone/tablet usability pass: controls remain reachable and readable. */
@media (max-width: 1100px) {
  .nav-links .dropdown-item,
  .nav-links .nav-cta {
    min-height: 44px !important;
  }

  .nav-links {
    padding-bottom: max(14px, env(safe-area-inset-bottom)) !important;
    scrollbar-gutter: stable;
  }
}

@media (max-width: 768px) {
  html {
    scroll-padding-top: 82px;
  }

  input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
  textarea,
  select,
  .strip-phone-input {
    font-size: 16px !important;
  }

  .strip-btn,
  .profile-action-btn,
  .palette-button,
  .lead-submit,
  .pf-btn,
  .product-button,
  .product-btn {
    min-height: 44px !important;
    touch-action: manipulation;
  }

  .profile-modal-container,
  .color-modal-container,
  .dialog-container,
  .pf-modal__dialog {
    width: min(calc(100% - 24px), 760px) !important;
    max-height: calc(100dvh - 24px) !important;
    margin: 12px auto !important;
    overflow-y: auto !important;
    overscroll-behavior: contain;
  }
}
