/* Home Featured Tours (v4): phones only. Two rows, opposite continuous marquees.
   Each track = 2 identical halves; CSS keyframes translate by exactly -50% of the
   track (= exactly one half), so the loop point can never drift or leave a blank.
   Top row glides right, bottom row glides left. Desktop/tablet untouched. */
@media (max-width: 767px) {
  html.hf .b44h-ft .b44h-ft-panels {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
  }
  html.hf .b44h-ft .b44h-ft-panels .b44h-ft-grid.hf-ft-m2 {
    display: flex !important;
    flex-direction: column !important;
    grid-auto-flow: unset !important;
    grid-template-columns: none !important;
    grid-template-rows: none !important;
    grid-auto-columns: unset !important;
    gap: 0.85rem !important;
    overflow: hidden !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0.2rem 0 0.9rem !important;
    scroll-snap-type: none !important;
  }
  html.hf .b44h-ft .b44h-ft-panels .hf-ft-row {
    display: block;
    overflow: hidden;
    width: 100%;
    max-width: 100%;
    touch-action: pan-y;
    -webkit-tap-highlight-color: transparent;
  }
  html.hf .b44h-ft .b44h-ft-panels .hf-ft-track {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: stretch;
    gap: 0;
    width: max-content;
    will-change: transform;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    transform: translate3d(0, 0, 0);
    -webkit-animation: hf-ft-left var(--hf-ft-dur, 60s) linear infinite;
    animation: hf-ft-left var(--hf-ft-dur, 60s) linear infinite;
  }
  html.hf .b44h-ft .b44h-ft-panels .hf-ft-row-top .hf-ft-track {
    -webkit-animation-name: hf-ft-right;
    animation-name: hf-ft-right;
  }
  html.hf .b44h-ft .b44h-ft-panels .hf-ft-track > a.b44h-tc {
    flex: 0 0 var(--hf-ft-card, calc(100vw - 4.5rem));
    width: var(--hf-ft-card, calc(100vw - 4.5rem)) !important;
    max-width: none !important;
    min-width: 0 !important;
    margin: 0 0.85rem 0 0 !important;
    scroll-snap-align: unset;
  }
  /* The page's scroll-reveal (.hf-rv, opacity 0 until ScrollTrigger fires once) only knows
     the cards that existed when it ran, so it never reveals the loop copies, and a card
     moved into a row can miss its trigger. Cards in the marquee must always be visible. */
  html.hf .b44h-ft .b44h-ft-panels .hf-ft-track > a.b44h-tc,
  html.hf .b44h-ft .b44h-ft-panels .hf-ft-track > a.b44h-tc.hf-rv {
    opacity: 1 !important;
    transform: none !important;
    visibility: visible !important;
  }
}

@-webkit-keyframes hf-ft-left {
  from { -webkit-transform: translate3d(0, 0, 0); transform: translate3d(0, 0, 0); }
  to { -webkit-transform: translate3d(-50%, 0, 0); transform: translate3d(-50%, 0, 0); }
}
@keyframes hf-ft-left {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-50%, 0, 0); }
}
@-webkit-keyframes hf-ft-right {
  from { -webkit-transform: translate3d(-50%, 0, 0); transform: translate3d(-50%, 0, 0); }
  to { -webkit-transform: translate3d(0, 0, 0); transform: translate3d(0, 0, 0); }
}
@keyframes hf-ft-right {
  from { transform: translate3d(-50%, 0, 0); }
  to { transform: translate3d(0, 0, 0); }
}

/* Reduced motion: two swipeable rows, no auto motion, no clones. */
@media (max-width: 767px) and (prefers-reduced-motion: reduce) {
  html.hf .b44h-ft .b44h-ft-panels .hf-ft-row {
    overflow-x: auto;
    touch-action: pan-x pan-y;
    -webkit-overflow-scrolling: touch;
  }
  html.hf .b44h-ft .b44h-ft-panels .hf-ft-track {
    -webkit-animation: none;
    animation: none;
    will-change: auto;
  }
}
