/* =====================================================================
 * Furnace Repair Redmond Co — Right-to-Left Autoplay Motion System
 * GPU-composited seamless horizontal marquees + desktop hover pause
 * ===================================================================== */

.furnace-marquee-viewport {
  position: relative;
  width: 100%;
  overflow: hidden;
  touch-action: pan-y; /* Carousel handles horizontal loop; browser keeps smooth vertical page scroll */
  padding-top: 6px;
  padding-bottom: 10px;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000000 1.2%, #000000 98.8%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0%, #000000 1.2%, #000000 98.8%, transparent 100%);
}

.furnace-marquee-track {
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: stretch !important;
  width: max-content !important;
  gap: 20px !important;
  padding-right: 20px !important; /* Matches gap for pixel-exact -50% loop seam */
  will-change: transform;
  animation-name: furnaceMarqueeRtl !important;
  animation-duration: var(--marquee-duration, 20s) !important;
  animation-timing-function: linear !important;
  animation-iteration-count: infinite !important;
  animation-play-state: running !important;
}

/* Pause on desktop mouse hover only; never apply sticky :hover pauses on touch devices */
@media (hover: hover) and (pointer: fine) {
  .furnace-marquee-viewport:hover .furnace-marquee-track:not(.force-running) {
    animation-play-state: paused !important;
  }
}

.furnace-marquee-track.is-paused {
  animation-play-state: paused !important;
}

.furnace-marquee-card {
  flex: 0 0 auto !important;
  width: 300px !important;
  max-width: calc(100vw - 52px) !important;
}

@media (min-width: 640px) {
  .furnace-marquee-card {
    width: 376px !important;
  }
}

@keyframes furnaceMarqueeRtl {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-50%, 0, 0);
  }
}

/* Right-to-left slide entrance helper */
.furnace-slide-rtl {
  animation: furnaceSlideRtl 480ms cubic-bezier(0.55, 0, 0.35, 1) both;
}

@keyframes furnaceSlideRtl {
  0% {
    opacity: 0;
    transform: translate3d(38px, 0, 0);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

/* =====================================================================
 * Mobile-Native Platform Baseline (Safe Areas, Touch, Inputs, Sheets)
 * ===================================================================== */
html {
  -webkit-tap-highlight-color: transparent;
  -webkit-text-size-adjust: 100%;
}

@media (pointer: coarse) {
  input,
  textarea,
  select {
    font-size: 16px !important;
  }
}

button,
a,
[role="button"],
summary,
.sp-btn,
.sp-tab,
.sp-capsule-btn,
.sp-capsule-btn-light,
.sp-capsule-btn-dark {
  touch-action: manipulation;
}

button,
[role="button"],
summary,
.sp-btn,
.sp-tab,
.sp-capsule-btn,
.sp-capsule-btn-light,
.sp-capsule-btn-dark,
header a,
nav a,
a.touch-target {
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

button:active,
[role="button"]:active,
.sp-btn:active,
.sp-tab:active,
a.touch-target:active {
  transform: scale(0.97);
}

.sp-capsule-bar,
.sp-capsule-bar-light,
.sp-capsule-bar-dark {
  touch-action: pan-x;
  overscroll-behavior-x: contain;
}

.sp-drawer-panel,
#booking-drawer > div,
#review-modal > div {
  max-height: 90vh !important;
  max-height: 90dvh !important;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding-bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px)) !important;
}

header.sticky {
  padding-top: env(safe-area-inset-top, 0px);
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
}

footer {
  padding-bottom: calc(3rem + env(safe-area-inset-bottom, 0px)) !important;
}
