/**
 * PartX landing — corrections on top of the cloned theme stylesheet.
 * Loaded last so it wins without needing !important where avoidable.
 */

/* Lenis: the theme sets `scroll-behavior:smooth`, which fights the RAF loop. */
html.lenis,
html.lenis body {
  scroll-behavior: auto !important;
}

/* --- Header menu -------------------------------------------------------- */
/* The theme hid `.cm-menu` and built its mega-menu in JS at runtime, so on a
   static export the nav was invisible and the burger did nothing. This is a
   plain, working menu: inline on desktop, burger-driven panel on mobile.
   992px matches the theme's own `main-lg` breakpoint. */

/* Reset <button> UA defaults on the burger. `overflow: visible` matters:
   buttons clip by default, which cut the rotated bars of the close "X". */
.ca-hamburger {
  overflow: visible;
  padding: 0;
  border: 0;
  background: none;
  -webkit-appearance: none;
  appearance: none;
}

.ca-hamburger__line {
  display: block;
}

.cm-menu {
  margin: 0;
  padding: 0;
  list-style: none;
}

.cm-menu__ln--0 {
  text-decoration: none;
}

/* Theme's submenu indicator tick — none of our items have submenus, and it
   threw the items out of vertical alignment. */
.cm-menu__li--0:after {
  display: none;
}

@media (min-width: 992px) {
  .co-header__hamburger {
    display: none;
  }

  .co-header__logo {
    order: 1;
    margin: 0;
  }

  .co-header__nav {
    display: flex;
    order: 2;
    align-items: center;
    margin-left: auto;
  }

  .cm-menu {
    display: flex;
    align-items: center;
    gap: 0.5rem;
  }

  .cm-menu__li--0 {
    display: flex;
    align-items: center;
  }
}

@media (max-width: 991px) {
  /* Full-height panel under the fixed header. */
  .co-header__nav {
    position: fixed;
    z-index: 999;
    top: 3.875rem;
    right: 0;
    bottom: 0;
    left: 0;
    display: block;
    visibility: hidden;
    padding: 1.5rem;
    transition: transform 0.35s ease, opacity 0.25s ease, visibility 0.35s;
    transform: translateY(-0.75rem);
    opacity: 0;
    background-color: #fff;
  }

  .co-header__nav.is-open {
    visibility: visible;
    transform: none;
    opacity: 1;
  }

  .cm-menu {
    display: flex;
    flex-direction: column;
  }

  .cm-menu__li--0 {
    border-bottom: 1px solid #ebebeb;
  }

  .cm-menu__ln--0 {
    /* Comfortable tap target. */
    padding: 1.1rem 0;
    font-size: 1.15rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .co-header__nav {
    transition: none;
  }
}

/* --- Hero slider -------------------------------------------------------- */
/* Crossfade between slides (the theme only toggled display).
   Note: no `overflow:hidden` here — the slide CTA chips are positioned to
   straddle the bottom edge by design and would get clipped. */
.co-slide-1.is-enter,
.co-slide-1.is-exit {
  transition: opacity 0.9s ease;
}

.co-slide-1.is-enter {
  opacity: 1;
}

.co-slide-1.is-exit {
  opacity: 0;
}

/* Vertical progress bar sits above the darkening overlay. */
.co-hb-cover-1__progress-bar {
  transition: height 0.1s linear;
}

/* line-height:.8 on the title let descenders collide with the subtitle. */
.co-slide-1__subtitle {
  margin-top: 0.6rem;
}

/* --- "We optimize every aspect" band ------------------------------------ */
/* The theme painted a WebGL <canvas> backdrop here; without it the white
   type sat on a white page and the CTA buttons stayed at opacity:0. */
.co-fb-fx-1 {
  display: flex;
  align-items: center;
  background-color: #000;
  background-image: radial-gradient(
    circle at 70% 30%,
    rgba(218, 68, 44, 0.22),
    transparent 55%
  );
}

.co-fb-fx-1__text {
  width: 100%;
  max-width: 90rem;
  margin: 0 auto;
}

.co-fb-fx-1__nav {
  flex-flow: row wrap;
  gap: 0.5rem;
}

.co-fb-fx-1__nav .co-fb-fx-1__btn {
  margin-bottom: 0;
  opacity: 1;
}

/* --- Footer CTA --------------------------------------------------------- */
/* The theme sized this image via JS; unconstrained it rendered 1280x1280 and
   left a ~900px blank gap. */
.co-footer-cta {
  display: flex;
  align-items: center;
  flex-direction: column;
  padding: 5rem 1.5rem;
  text-align: center;
}

.co-footer-cta__btn {
  display: inline-flex;
  align-items: center;
  margin-top: 1.75rem;
  padding: 0.9rem 2rem;
  transition: background-color 0.3s, color 0.3s;
  color: #fff;
  background-color: #da442c;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
}

.co-footer-cta__btn:hover,
.co-footer-cta__btn:focus-visible {
  color: #fff;
  background-color: #b8351f;
}

/* The theme's arrow pseudo-element pointed at an asset that 404'd. */
.co-footer-cta__btn:after {
  width: 1.5rem;
  height: 1rem;
  margin-left: 1rem;
  background-size: contain;
}

/* --- Accessibility ------------------------------------------------------ */
a:focus-visible,
button:focus-visible {
  outline: 2px solid #da442c;
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .co-slide-1.is-enter,
  .co-slide-1.is-exit,
  .co-hb-cover-1__progress-bar {
    transition: none;
  }
}
