/**
 * Homepage-only: instant paint, no scroll-jank from dozens of WOW observers.
 */

body.pcs-home .wow {
  visibility: visible !important;
  opacity: 1 !important;
  animation: none !important;
  transform: none !important;
}

body.pcs-home .pace,
body.pcs-home .pace-progress {
  display: none !important;
}

/* Decorative sway on coverage card — static on home to save GPU */
body.pcs-home .sway__animation,
body.pcs-home .sway__animationX {
  animation: none !important;
}

/* Native Google reviews — compact reserve while loading */
body.pcs-home .pcs-svc-reviews-shell__embed-inner {
  min-height: 10rem;
}

body.pcs-home .pcs-google-reviews--loading {
  min-height: 10rem;
}

@media (prefers-reduced-motion: reduce) {
  body.pcs-home .banner-three__shape-left,
  body.pcs-home .banner-three__shape-right {
    transform: none !important;
  }
}

/* Hero decor can read as extra purple bars behind the fixed header */
body.pcs-home .banner-three__shape-left,
body.pcs-home .banner-three__shape-right {
  z-index: 0;
  pointer-events: none;
}

body.pcs-home .header-two-area {
  z-index: 1000;
}

/*
 * Home header — reference layout:
 * - Logo left, CTA+phone right, nav truly centered (1fr | auto | 1fr grid).
 * - Every block vertically centered in the bar.
 */
@media (min-width: 992px) {
  body.pcs-home .header-two-area .header__container {
    max-width: min(1400px, calc(100% - 40px));
  }

  body.pcs-home .header-two-area .header__main {
    display: grid !important;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    justify-items: stretch;
    column-gap: clamp(16px, 2vw, 32px);
    min-height: clamp(100px, 8.5vw, 116px);
    position: relative;
  }

  body.pcs-home .header-two-area .header__main .logo {
    grid-column: 1;
    grid-row: 1;
    justify-self: start;
    align-self: center;
    display: flex;
    align-items: center;
    max-width: min(340px, 34vw);
    flex: none;
  }

  body.pcs-home .header-two-area .header__main .logo img {
    max-width: 100% !important;
    max-height: 96px;
    width: auto;
    height: auto;
    object-fit: contain;
    object-position: left center;
    vertical-align: middle;
  }

  /* Cancel viewport-absolute nav; center link row in the middle grid track */
  body.pcs-home .header-area.header-two-area .header__main .main-menu {
    grid-column: 2;
    grid-row: 1;
    position: static !important;
    left: auto !important;
    top: auto !important;
    transform: none !important;
    justify-self: center;
    align-self: center;
    display: flex;
    align-items: center;
    justify-content: center;
    width: auto;
    max-width: none;
    z-index: 2;
  }

  body.pcs-home .header-two-area .header__main .main-menu nav {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  body.pcs-home .header-two-area .header__main .main-menu ul,
  body.pcs-home .header-two-area .header__main .main-menu .pcs-main-nav__list {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 0;
    gap: clamp(10px, 1.35vw, 28px) !important;
  }

  body.pcs-home .header-two-area .header__main .main-menu ul li {
    display: flex;
    align-items: center;
    margin: 0;
  }

  body.pcs-home .header-two-area .header__main .main-menu ul li a:not(.search-trigger) {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 !important;
    line-height: 1.15;
    font-size: clamp(12px, 0.82vw, 16px) !important;
    font-weight: 700;
  }

  body.pcs-home .header-two-area .header__main .main-menu ul li a:not(.search-trigger)::after {
    bottom: -6px;
  }

  body.pcs-home .header-two-area .header__main > .d-none.d-xl-flex {
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
    align-self: center;
    display: flex !important;
    align-items: center;
    flex-wrap: nowrap;
    gap: clamp(12px, 1.2vw, 24px) !important;
  }

  body.pcs-home .header-two-area .header__main > .d-none.d-xl-flex .about-three__left-item {
    display: flex !important;
    align-items: center;
  }

  body.pcs-home .header-two-area .header__main > .d-none.d-xl-flex .btn-one {
    align-self: center;
    white-space: nowrap;
    padding-inline: clamp(16px, 1.3vw, 24px);
    font-size: clamp(13px, 0.85vw, 15px);
  }

  body.pcs-home .header-two-area .header__main .bars {
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
    align-self: center;
  }
}

@media (min-width: 992px) and (max-width: 1299.98px) {
  body.pcs-home .header-two-area .header__main .logo img {
    max-height: 84px;
  }

  body.pcs-home .header-two-area .header__main .main-menu ul li a:not(.search-trigger) {
    font-size: clamp(11.5px, 0.95vw, 14px) !important;
  }

  body.pcs-home .header-two-area .header__main .main-menu ul,
  body.pcs-home .header-two-area .header__main .main-menu .pcs-main-nav__list {
    gap: clamp(8px, 1vw, 16px) !important;
  }
}

@media (min-width: 1200px) and (max-width: 1450px) {
  body.pcs-home .header-two-area .header__main > .d-none.d-xl-flex .about-three__left-item {
    display: flex !important;
  }

  body.pcs-home .header-two-area .header__main > .d-none.d-xl-flex .about-three__left-item .info .sm-font {
    font-size: 12px;
  }

  body.pcs-home .header-two-area .header__main > .d-none.d-xl-flex .about-three__left-item .info h5 {
    font-size: 15px;
  }
}

/* Do not use contain on fixed header / hero — iOS Safari can pillarbox the whole page on scroll */

body.pcs-home .pcs-help-cta__canvas {
  display: none;
}

/*
 * Mobile hero: sit slider just below fixed header (global rules over-reserve ~86–118px).
 */
@media (max-width: 991.98px) {
  body.pcs-home main > .banner-three-area:first-child {
    padding-top: calc(
      env(safe-area-inset-top, 0px) + clamp(72px, 13vw, 96px) + 6px
    ) !important;
    padding-bottom: clamp(24px, 5.5vh, 44px) !important;
  }

  body.pcs-home .banner-three__container {
    padding: 8px clamp(12px, 4vw, 20px) 12px !important;
  }

  body.pcs-home .banner-three-area .row.align-items-center {
    --bs-gutter-y: 0.65rem;
  }

  body.pcs-home .banner-three-area .pcs-hero-slider {
    margin-top: 0 !important;
  }

  body.pcs-home .banner-three__content {
    margin-top: clamp(6px, 1.5vh, 14px) !important;
  }
}

@media (max-width: 767.98px) {
  body.pcs-home main > .banner-three-area:first-child {
    padding-top: calc(
      env(safe-area-inset-top, 0px) + clamp(68px, 12vw, 88px) + 4px
    ) !important;
    padding-bottom: clamp(20px, 5vh, 36px) !important;
  }

  body.pcs-home .banner-three__container {
    padding-top: 4px !important;
  }

  body.pcs-home .banner-three-area .pcs-hero-slider {
    margin-top: 0 !important;
  }
}

/* Short foldables / phones (Surface Duo, etc.) */
@media (max-width: 580px) and (max-height: 760px) and (max-aspect-ratio: 1 / 1) {
  body.pcs-home .banner-three-area {
    padding-top: calc(
      env(safe-area-inset-top, 0px) + clamp(64px, 11vw, 84px) + 4px
    ) !important;
    padding-bottom: clamp(16px, 4vh, 28px) !important;
  }

  body.pcs-home .pcs-hero-slider {
    margin-top: 0 !important;
  }
}

/* ---- Phones & tablets with hamburger (≤991px) — logo + menu vertically centered ---- */
@media (max-width: 991.98px) {
  body.pcs-home .header-two-area .header__container {
    display: flex;
    align-items: center;
  }

  body.pcs-home .header-two-area .header__main {
    display: flex !important;
    flex-direction: row;
    flex-wrap: nowrap !important;
    align-items: center !important;
    align-content: center;
    justify-content: space-between;
    width: 100%;
    min-height: clamp(68px, 12vw, 88px);
    padding-top: max(10px, env(safe-area-inset-top, 0px)) !important;
    padding-bottom: 10px !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    gap: 12px;
    box-sizing: border-box;
  }

  body.pcs-home .header-two-area .header__main .logo {
    display: flex;
    align-items: center;
    align-self: center;
    flex: 0 1 auto;
    margin: 0;
    padding: 0;
    min-width: 0;
  }

  body.pcs-home .header-two-area .header__main .logo img {
    display: block;
    margin: 0;
    max-width: clamp(150px, 46vw, 240px) !important;
    max-height: clamp(40px, 11vw, 56px);
    width: auto;
    height: auto;
    object-fit: contain;
    object-position: left center;
  }

  body.pcs-home .header-two-area .header__main .bars {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    align-self: center;
    flex: 0 0 auto;
    margin: 0 0 0 auto !important;
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    touch-action: manipulation;
  }

  body.pcs-home .header-two-area .header__main .bars .pcs-hamburger-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 8px;
  }

  body.pcs-home .banner-three__content h1 {
    font-size: clamp(1.45rem, 6.8vw, 2rem) !important;
  }

  body.pcs-home .pcs-hero-btn {
    min-width: 44px;
    min-height: 44px;
  }
}

@media (max-width: 390px) {
  body.pcs-home .header-two-area .header__container {
    padding-inline: max(8px, env(safe-area-inset-left, 0px))
      max(8px, env(safe-area-inset-right, 0px));
  }

  body.pcs-home .header-two-area .header__main {
    min-height: clamp(64px, 14vw, 76px);
  }

  body.pcs-home .header-two-area .header__main .logo img {
    max-width: clamp(140px, 52vw, 200px) !important;
    max-height: clamp(36px, 10vw, 48px);
  }
}

/* ---- Tablets (iPad Mini / Air / Pro, Surface) — still hamburger bar ---- */
@media (min-width: 768px) and (max-width: 991.98px) {
  body.pcs-home .header-two-area .header__main {
    min-height: clamp(72px, 10vw, 92px);
  }

  body.pcs-home .header-two-area .header__main .logo img {
    max-width: clamp(200px, 28vw, 280px) !important;
    max-height: clamp(44px, 8vw, 60px);
  }

  body.pcs-home .banner-three__container {
    padding-inline: clamp(16px, 3vw, 28px);
  }
}

/* ---- Short landscape (Nest Hub, Nest Hub Max, foldables) ---- */
@media (max-height: 600px) and (min-width: 900px) {
  body.pcs-home .header-two-area .header__main {
    min-height: 72px;
    grid-template-columns: 1fr auto 1fr;
  }

  body.pcs-home .header-two-area .header__main .logo img {
    max-height: 58px;
  }

  body.pcs-home .header-two-area .header__main .main-menu ul li a:not(.search-trigger) {
    font-size: 12px !important;
  }

  body.pcs-home .banner-three-area {
    padding-top: clamp(78px, 12vh, 110px) !important;
    padding-bottom: clamp(32px, 6vh, 56px) !important;
  }
}

@media (max-height: 800px) and (min-width: 1024px) and (max-width: 1400px) {
  body.pcs-home .header-two-area .header__main {
    min-height: 84px;
  }

  body.pcs-home .header-two-area .header__main .logo img {
    max-height: 76px;
  }
}

/* ---- Laptop / 27″ (~1920px) ---- */
@media (min-width: 1920px) {
  body.pcs-home .header-two-area .header__container {
    max-width: min(1440px, calc(100% - 56px));
  }

  body.pcs-home main .container {
    max-width: min(1320px, 86vw);
  }
}

/* ---- 32″ / QHD (~2560px) ---- */
@media (min-width: 2560px) {
  body.pcs-home .header-two-area .header__container {
    max-width: min(1520px, 78vw);
  }

  body.pcs-home main .container {
    max-width: min(1400px, 72vw);
  }

  body.pcs-home .header-two-area .header__main .main-menu ul li a:not(.search-trigger) {
    font-size: 15px !important;
  }
}

/* ---- 4K TV (~3840px) ---- */
@media (min-width: 3840px) {
  body.pcs-home .header-two-area .header__container {
    max-width: min(1680px, 70vw);
  }

  body.pcs-home main .container {
    max-width: min(1520px, 64vw);
  }

  body.pcs-home .banner-three__content h1 {
    font-size: clamp(2.5rem, 2vw + 1rem, 3.25rem) !important;
  }
}

/* ---- Ultra-wide fold (Surface Duo, Zenbook Fold) ---- */
@media (max-width: 720px) and (min-width: 520px) and (max-height: 760px) {
  body.pcs-home .header-two-area .header__main .logo img {
    max-width: min(200px, 36vw) !important;
  }
}
