/* ============================================================
   CRITICAL FIX: FORCE HIDE PRELOADER IMMEDIATELY
   Purpose: Override all preloader CSS to hide it permanently
   The preloader has z-index 1001 and covers the header (z-index 1000)
   This CSS forcefully hides it with !important
   ============================================================ */

#loader-wrapper,
.loaded #loader-wrapper,
body.loaded #loader-wrapper {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transform: none !important;
    transition: none !important;
    animation: none !important;
}

#loader-wrapper .loader-section,
#loader-wrapper .loader-section.section-left,
#loader-wrapper .loader-section.section-right,
.loaded #loader-wrapper .loader-section,
.loaded #loader-wrapper .loader-section.section-left,
.loaded #loader-wrapper .loader-section.section-right {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    transform: none !important;
    transition: none !important;
    animation: none !important;
}

/* Prevent animate/WOW flash before JS initializes */
.wow {
  visibility: hidden;
}

/* Closed mega panels must never flash open during navigation */
.mega-panel:not(.is-open) {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

#loader {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

/* Force show top header bar + main header immediately */
.header-section,
.header__top {
    visibility: visible !important;
    opacity: 1 !important;
}

/* Top header scrolls away naturally; sits just under sticky nav in stack */
section.header__top,
.header__top.topbar-v3 {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  position: relative !important;
  z-index: 11990 !important;
  width: 100% !important;
  background-color: #ffffff !important;
}

/* Smooth scroll: kill fixed parallax sitewide (major jank source) */
.emergency__section,
.background-cycle-section,
.breadcumd__banner,
.banner__section-override,
#main-banner {
  background-attachment: scroll !important;
}

/* No delayed transitions on headers during scroll (was 0.9s — caused glitch) */
.header-section,
.header-section .header-wrapper,
.header-section.header__one,
.header__top,
.header__top.topbar-v3,
.header__top .header__wrapper {
  transition: none !important;
}

/* Logo: only height may ease; position snaps instantly */
.header-section .straddle-logo {
  transition: height 0.2s ease-in-out !important;
}

.header-section.sticky-header .straddle-logo {
  transition: none !important;
}

/* Purple nav: normal flow; JS pins with .sticky-header once topbar scrolls away */
.header-section.header__one {
  position: relative !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  width: 100% !important;
  z-index: 12000 !important;
  transform: none !important;
  will-change: auto !important;
}

.header-section.sticky-header {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12) !important;
  transform: none !important;
}

.header-section.sticky-header.hide {
  transform: none !important;
}

/* ============================================================ */
/* Unified inner-page banner — aligned with Discount_Court      */
/* Documents_Rebrand .subpage-banner spec (cover + clamp height)  */
/* Reference: clamp(517.5px, 81vh, 922.5px) desktop             */
/* ============================================================ */
:root {
  --home-banner-height: clamp(517.5px, 81vh, 922.5px);
}

@media (max-width: 980px) {
  :root {
    --home-banner-height: clamp(450px, 78.75vh, 731.25px);
  }
}

@media (max-width: 400px) {
  :root {
    --home-banner-height: clamp(393.75px, 70.3125vh, 590.625px);
  }
}

/* Breadcrumb / inner-page banners — high specificity beats per-page overrides */
section.breadcumd__banner.overhid,
section.breadcumd__banner,
#main-banner.breadcumd__banner.overhid,
#main-banner.breadcumd__banner,
.breadcumd__banner.breadcumd__banner--detailed,
.breadcumd__banner {
  min-height: var(--home-banner-height) !important;
  height: var(--home-banner-height) !important;
  max-height: none !important;
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  background-attachment: scroll !important;
  overflow: hidden !important;
}

/* Contact video banner — same unified height, no aspect-ratio squeeze */
section.breadcumd__banner.contact-banner,
#main-banner.breadcumd__banner.contact-banner {
  min-height: var(--home-banner-height) !important;
  height: var(--home-banner-height) !important;
  max-height: none !important;
  aspect-ratio: auto !important;
}

.breadcumd__banner .breadcumd__wrapper,
.breadcumd__banner--detailed .breadcumd__wrapper {
  padding: 48px 0 !important;
  min-height: 100% !important;
  align-items: center !important;
}

/* Towing / service template banners */
section.banner__section-override,
#main-banner.banner__section-override {
  min-height: var(--home-banner-height) !important;
  height: var(--home-banner-height) !important;
  max-height: none !important;
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  background-attachment: scroll !important;
  overflow: hidden !important;
}

/* Dual-layer gradient + image backgrounds */
section.banner__section-override[style*="background"],
section.banner__section-override {
  background-size: cover, cover !important;
  background-position: center center, center center !important;
  background-repeat: no-repeat, no-repeat !important;
  background-attachment: scroll, scroll !important;
}

section.banner__section-override .banner__content-override {
  position: absolute !important;
}

/* Beat per-page mobile 60vh / 80vh overrides */
@media (max-width: 991px) {
  section.banner__section-override,
  #main-banner.banner__section-override,
  section.breadcumd__banner.overhid,
  #main-banner.breadcumd__banner.overhid,
  section.breadcumd__banner.contact-banner,
  #main-banner.breadcumd__banner.contact-banner {
    min-height: var(--home-banner-height) !important;
    height: var(--home-banner-height) !important;
    max-height: none !important;
  }
}

/* ============================================================ */
/* No shadow, opacity, or dark overlays on banner/content images */
/* ============================================================ */
.breadcumd__banner::before,
section.breadcumd__banner::before,
#main-banner.breadcumd__banner::before,
.breadcumd__banner.contact-banner::before,
.breadcumd__banner--detailed::before,
.banner__image::before,
.imagetwo::before,
.imagethree::before,
section.banner__section-override::before,
.banner__section::before,
.banner__two::before {
  display: none !important;
  content: none !important;
  opacity: 0 !important;
  background: none !important;
  box-shadow: none !important;
}

.banner__image,
.imagetwo,
.imagethree,
.breadcumd__banner,
section.breadcumd__banner,
section.banner__section-override,
.banner__section-override {
  filter: none !important;
  opacity: 1 !important;
  box-shadow: none !important;
}

.banner__section img,
.breadcumd__banner img,
section.banner__section-override img,
.details__thumb img,
.benefit__thumb img,
.thumb__custom img,
.service__helping .thumb img,
.shop__details .image img,
.img-frame img,
.gallery__item img,
.gallery-page img,
.about__thumb img,
.team__thumb img,
.discount__thumb img,
.service__thumb img,
.animation-scene img,
.animation-scene--video video {
  filter: none !important;
  opacity: 1 !important;
  box-shadow: none !important;
}

.discount__thumb::before,
.discount__thumb::after,
.service__thumb::before,
.details__thumb::before,
.benefit__thumb::before {
  display: none !important;
  content: none !important;
  background: none !important;
  opacity: 0 !important;
  box-shadow: none !important;
}

/* ============================================================ */
/* Allow text selection sitewide (for review / copy feedback)   */
/* ============================================================ */
html,
body,
body *:not(button):not(input):not(textarea):not(select):not(.nice-select):not(.mega-header):not(.mega-panel__close):not(.header-bar):not(.btn):not(.cmn--btn):not(.cmn--btn2):not(.arry__prev):not(.arry__next):not(.scroll-up):not(i):not([class*="fa-"]) {
  -webkit-user-select: text !important;
  user-select: text !important;
}

.banner__section .swiper-slide > .container:not(.banner__content-shell):not(.banner__content-shell--fixed) {
  position: relative !important;
  z-index: 2 !important;
  pointer-events: auto !important;
}

html[data-index-page] .banner__section .banner__content-shell--fixed,
html[data-page="gallery"] .banner__section .banner__content-shell--fixed {
  position: absolute !important;
  z-index: 10 !important;
  pointer-events: none !important;
}

.banner__section,
.banner__section .swiper,
.banner__section .swiper-slide,
.banner__section .swiper-slide > .container,
.banner__content,
.banner__content *,
.text-container,
.text-container *,
.about__content,
.about__content *,
.service__content,
.service__content *,
.product__content,
.product__content *,
.footer__widget,
.footer__widget * {
  -webkit-user-select: text !important;
  user-select: text !important;
  cursor: auto !important;
}

img,
picture,
figure {
  -webkit-user-drag: auto !important;
  pointer-events: auto !important;
}

#loader-wrapper,
#loader-wrapper * {
  pointer-events: none !important;
}

.nice-select,
.mega-header,
.mega-panel__close,
.header-bar,
button,
.btn,
.cmn--btn,
.cmn--btn2,
.arry__prev,
.arry__next {
  -webkit-user-select: none !important;
  user-select: none !important;
}

/* ============================================================ */
/* Straddle logo + hamburger on right (loads last sitewide)     */
/* ============================================================ */
/* Must beat mega-menu-discount-design.css and page-specific header overrides */
html body .header-section.header__one .straddle-logo,
.header-section.header__one .straddle-logo {
  top: 160% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) translateZ(0) !important;
}

/* Sticky: logo straddles purple nav bottom edge */
html body .header-section.sticky-header.header__one .straddle-logo,
.header-section.sticky-header.header__one .straddle-logo {
  top: 80% !important;
  transform: translate(-50%, -50%) translateZ(0) !important;
}

/* Align with 980px mobile menu — show straddle logo from 981px (Bootstrap lg is 992px) */
@media (min-width: 981px) {
  html body .header-section .straddle-logo.d-none.d-lg-block,
  .header-section .straddle-logo.d-none.d-lg-block {
    display: block !important;
  }
}

.header-section.sticky-header .straddle-logo img {
  height: 100px !important;
}

.header-section .header-wrapper {
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  justify-content: space-between !important;
  width: 100% !important;
}

.header-section .header-wrapper .logo__menuadjust {
  flex: 1 1 auto !important;
  min-width: 0 !important;
}

.header-section .header-wrapper .menu__components {
  flex: 0 0 auto !important;
  margin-left: auto !important;
  display: flex !important;
  align-items: center !important;
  gap: 20px !important;
  position: relative !important;
  z-index: 30 !important;
  visibility: visible !important;
}

.header-section .header-wrapper .menu__components .fa-bars,
.header-section .header-wrapper .menu__components #openButton {
  display: inline-block !important;
}

@media (max-width: 991px) {
  .header-section .header-wrapper .menu__components {
    display: flex !important;
    visibility: visible !important;
    margin-left: auto !important;
  }

  .header-section .header-wrapper .menu__components .fa-bars,
  .header-section .header-wrapper .menu__components #openButton {
    display: none !important;
  }

  .header-section .header-wrapper .header-bar,
  .header-section .header-wrapper #mobileHeaderHamburger {
    display: block !important;
    visibility: visible !important;
    margin-left: auto !important;
  }
}

@media (min-width: 992px) {
  .header-section .header-wrapper .header-bar,
  .header-section .header-wrapper #mobileHeaderHamburger {
    display: none !important;
  }
}