/* Time Walk: desktop/tablet sticky booking bar (>= 768px). Built by tw-sticky-desktop.js. Tokens from tw-tokens.css.
   Phones use the mobile bar (.tw-sticky-cta, tw-site.css). z-index --z-sticky: under the header, menu and cookie banner.
   From 992px it is not shown on pages that have their own sticky booking/request card
   (group tour .tv-buy, private pages .tp-buy, IT/ES/FR .tl-buy): one booking action per view. */
.tw-sd {
  position: fixed;
  z-index: var(--z-sticky);
  left: var(--s-4);
  right: var(--s-4);
  bottom: var(--s-4);
  max-width: 960px;
  height: 64px;
  margin: 0 auto;
  box-sizing: border-box;
  padding: 0 10px 0 var(--s-5);
  display: flex;
  align-items: center;
  gap: var(--s-5);
  border-radius: var(--r-pill);
  background: rgba(16, 13, 10, .94);
  border: 1px solid var(--c-gold-line);
  box-shadow: var(--shadow-2);
  color: var(--c-text);
  font: 400 .875rem/1.3 var(--f-body);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px);
  transition: opacity var(--d-fast) ease-in, transform var(--d-fast) ease-in, visibility 0s linear var(--d-fast);
  pointer-events: none;
}
.tw-sd.is-in {
  opacity: 1;
  visibility: visible;
  transform: none;
  pointer-events: auto;
  transition: opacity var(--d-base) var(--ease-out), transform var(--d-base) var(--ease-out), visibility 0s;
}
.tw-sd-info { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.tw-sd-title {
  margin: 0;
  color: var(--c-text-strong);
  font: 600 1.1875rem/1.15 var(--f-display);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tw-sd-meta { display: flex; align-items: baseline; gap: var(--s-2); white-space: nowrap; overflow: hidden; color: var(--c-text-muted); font-size: var(--fs-caption); }
.tw-sd-x { display: inline-flex; align-items: baseline; gap: var(--s-2); }
.tw-sd-price { color: var(--c-text-strong); font-weight: 700; font-size: var(--fs-small); }
.tw-sd-meta s { color: var(--c-text-faint); }
.tw-sd-star { color: var(--c-gold); }
.tw-sd-dot { color: var(--c-text-faint); }
.tw-sd-vh {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.tw-sd-alt {
  flex: none;
  color: var(--c-text) !important;
  font-weight: 700;
  font-size: .875rem;
  text-decoration: underline;
  text-decoration-color: var(--c-gold-line);
  text-underline-offset: 4px;
  padding: 10px 4px;
  border-radius: 6px;
  white-space: nowrap;
  transition: color var(--d-fast) ease, text-decoration-color var(--d-fast) ease;
}
/* main button = the token primary: gradient with dark text (never white on orange) */
.tw-sd-btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  height: var(--h-btn-sm);
  padding: 0 var(--s-5);
  border-radius: var(--r-pill);
  background: var(--g-primary);
  color: var(--c-on-primary) !important;
  font: 700 var(--fs-small)/1 var(--f-body);
  letter-spacing: .01em;
  text-decoration: none !important;
  white-space: nowrap;
  box-shadow: var(--shadow-glow);
  transition: transform var(--d-fast) var(--ease-out), filter var(--d-fast) ease;
}
/* private pages: the main action is WhatsApp */
.tw-sd-btn[href*="wa.me"] { background: var(--c-wa); color: #fff !important; box-shadow: none; }
.tw-sd-btn:active { transform: scale(.97); }
@media (hover: hover) and (pointer: fine) {
  .tw-sd-btn:hover { filter: brightness(1.07); }
  .tw-sd-alt:hover { color: var(--c-text-strong) !important; text-decoration-color: var(--c-gold); }
}
.tw-sd a:focus-visible { outline: 2px solid var(--c-gold-bright); outline-offset: 3px; }

/* Tablet: tighter spacing so everything stays on one line at 768-991px */
@media (max-width: 991px) {
  .tw-sd { gap: 14px; padding-left: 20px; }
  .tw-sd-title { font-size: 1.0625rem; }
  .tw-sd-btn { padding: 0 18px; }
  .tw-sd-x { display: none; } /* private pages: extra note only where there is room */
}
/* Pages with their own sticky booking/request card: no bottom bar where that card is sticky */
@media (min-width: 992px) { body:has(.tv-buy, .tp-buy, .tl-buy) .tw-sd { display: none !important; } }

/* Phones use the mobile bar; never show this one. Not hidden for the cookie banner: the banner moves up above it (tw-consent.js). */
@media (max-width: 767px) { .tw-sd { display: none !important; } }

@media (prefers-reduced-motion: reduce) {
  .tw-sd, .tw-sd.is-in { transform: none; transition: opacity .12s linear, visibility 0s linear .12s; }
  .tw-sd.is-in { transition: opacity .12s linear, visibility 0s; }
  .tw-sd-btn { transition: none; }
  .tw-sd-btn:active { transform: none; }
}
/* accessibility audit S3 (2026-11-23, WCAG 2.4.11): a keyboard focus never ends up behind the bar */
html:has(.tw-sd.is-in) { scroll-padding-bottom: 104px; }
@media print { .tw-sd { display: none !important; } }
