/* ==========================================================================
   Carts HQ — Supplemental Styles
   Loaded after Tailwind. Handles motion/animation states that GSAP
   targets, plus components not easily expressed as pure utilities.
   ========================================================================== */

/* ---- Header scroll state ---- */
#site-header {
  background-color: transparent;
}

#site-header.is-scrolled {
  background-color: rgba(10, 10, 12, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* ---- Scroll-triggered fade/slide-up (GSAP toggles .is-visible) ---- */
.chq-anim-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.chq-anim-up.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .chq-anim-up {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ---- Vehicle reveal image effect (clip-path wipe on scroll) ---- */
.chq-reveal-img {
  clip-path: inset(0 0 0 0);
}

.chq-reveal-img.chq-reveal-pending {
  clip-path: inset(0 100% 0 0);
}

/* ---- Product card hover lift ---- */
.chq-cart-card {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.chq-cart-card:hover,
.chq-cart-card:focus-within {
  transform: translateY(-6px);
}

/* ---- Animated counters ---- */
.chq-counter-number {
  font-variant-numeric: tabular-nums;
}

/* ---- Parallax layer (for hero / section backgrounds) ---- */
.chq-parallax {
  will-change: transform;
}

/* ---- Mobile menu icon swap ---- */
.chq-menu-open #chq-icon-open {
  display: none;
}

.chq-menu-open #chq-icon-close {
  display: block;
}

/* ---- Form field error state ---- */
.chq-field-error {
  border-color: #f87171 !important;
}

/* ---- Star rating fill (used by chq_render_stars) ---- */
.chq-stars svg {
  display: inline-block;
}

/* ---- Lead form status messages ---- */
.chq-status-success {
  color: var(--chq-success);
}

.chq-status-error {
  color: #f87171;
}

/* ---- Prose adjustments for inner pages (sans-serif body per brand guidelines) ---- */
.prose-invert {
  --tw-prose-body: #d6d8db;
  --tw-prose-headings: #f5f6f7;
  --tw-prose-links: #2e6bff;
  --tw-prose-bold: #f5f6f7;
  --tw-prose-bullets: #2e6bff;
  font-family: var(--font-body);
}

.prose-invert h1,
.prose-invert h2,
.prose-invert h3,
.prose-invert h4 {
  font-family: var(--font-display);
}
