/* =============================================
   TOUR DETAIL PAGE — Peru Beyond Template (Luxury)
   ============================================= */

.tour-page { padding-bottom: 80px; }

.tour-hero-skeleton[hidden],
#tour-skeleton[hidden] {
  display: none !important;
}

.tour-hero__content {
  position: relative;
  z-index: 2;
}

.lux-header--solid {
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-gold);
  padding: 14px 0;
}
.lux-header--solid .lux-nav__link { color: var(--black); }
.lux-header--solid .lux-menu-btn span { background: var(--black); }
.lux-header--solid .theme-toggle-btn {
  border-color: var(--border-gold); color: var(--gold);
}
body.dark-mode .lux-header--solid {
  background: rgba(10,10,10,0.97);
}
body.dark-mode .lux-header--solid .lux-nav__link { color: var(--dark-text); }
body.dark-mode .lux-header--solid .lux-menu-btn span { background: var(--dark-text); }

/* Hero */
.tour-hero {
  position: relative; min-height: 70vh;
  display: flex; align-items: flex-end;
  padding: 140px 0 60px; margin-top: 0;
}
.tour-hero__bg {
  position: absolute; inset: 0;
  background-color: #0a1014;
  background-size: cover; background-position: center;
  overflow: hidden;
}
.tour-hero__media-loader {
  position: absolute;
  inset: 0;
  z-index: 2;
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease;
  background: linear-gradient(110deg, #0a1014 0%, #141c24 45%, #0a1014 90%);
  background-size: 220% 100%;
  animation: tourHeroLoaderShimmer 1.6s ease-in-out infinite;
}
.tour-hero__bg.is-loading .tour-hero__media-loader {
  opacity: 1;
}
.tour-hero__poster {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0;
  transition: opacity 280ms ease;
  will-change: opacity;
  background-size: cover;
  background-position: center;
}
.tour-hero__poster.is-visible {
  opacity: 1;
}
.tour-hero__video {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  display: block;
  z-index: 1;
  opacity: 0;
  visibility: hidden;
  transition: opacity 280ms ease;
  will-change: opacity;
}
.tour-hero__video.is-visible {
  opacity: 1;
  visibility: visible;
}
@keyframes tourHeroLoaderShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.media-slot.is-loaded img,
.media-fade-img.is-visible {
  opacity: 1;
}
.tour-hero__overlay {
  position: absolute; inset: 0;
  z-index: 1;
  background: linear-gradient(to top, rgba(10,10,10,0.95) 0%, rgba(10,10,10,0.4) 50%, rgba(10,10,10,0.6) 100%);
}

.breadcrumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  font-size: 12px; letter-spacing: 0.05em;
  color: rgba(255,255,255,0.55); margin-bottom: 20px;
}
.breadcrumb a:hover { color: var(--gold-pale); }

.tour-hero__title {
  font-family: var(--ff-display);
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 500; color: var(--white);
  line-height: 1.12; margin-bottom: 28px; max-width: 800px;
}

.tour-hero__meta {
  display: flex; flex-wrap: wrap; align-items: flex-end;
  gap: 24px 40px; margin-bottom: 32px;
}

.tour-hero__price-label {
  display: block; font-size: 11px; letter-spacing: 0.15em;
  text-transform: uppercase; color: rgba(255,255,255,0.6);
}
.tour-hero__price-value {
  font-family: var(--ff-display); font-size: 2.5rem;
  color: var(--gold-pale); font-weight: 600;
}
.tour-hero__price-unit { font-size: 14px; color: rgba(255,255,255,0.6); }

.tour-hero__badges { display: flex; flex-wrap: wrap; gap: 10px; }
.tour-badge {
  padding: 8px 16px; font-size: 11px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  border: 1px solid rgba(255,255,255,0.25); color: var(--white);
}

.tour-hero__cta { display: flex; flex-wrap: wrap; gap: 12px; }
.tour-hero__cta .btn-gold ion-icon { font-size: 20px; }

/* Tabs */
.tour-tabs {
  position: sticky; top: 72px; z-index: 50;
  background: var(--white);
  border-bottom: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 4px 20px rgba(0,0,0,0.04);
}
body.dark-mode .tour-tabs {
  background: var(--dark-surface); border-color: rgba(255,255,255,0.08);
}

.tour-tabs__inner {
  display: flex; gap: 0; overflow-x: auto;
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.tour-tabs__inner::-webkit-scrollbar { display: none; }

.tour-tabs__link {
  flex-shrink: 0; padding: 18px 20px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--text-muted);
  border-bottom: 2px solid transparent;
  transition: var(--transition); white-space: nowrap;
}
.tour-tabs__link:hover,
.tour-tabs__link.active {
  color: var(--gold); border-bottom-color: var(--gold);
}
.tour-tabs__link--gold { color: var(--gold); margin-left: auto; }

/* Layout */
.tour-layout {
  display: grid; gap: 48px;
  padding-block: 60px;
  align-items: start;
}

.tour-section { margin-bottom: 64px; scroll-margin-top: 140px; }
.tour-section__title {
  font-family: var(--ff-display); font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 24px; padding-bottom: 16px;
  border-bottom: 1px solid var(--border-gold);
}

.tour-lead {
  font-size: 1.125rem; line-height: 1.7;
  color: var(--black); margin-bottom: 16px; font-weight: 500;
}
body.dark-mode .tour-lead { color: var(--dark-text); }

.tour-info-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px; margin-top: 32px;
}
.tour-info-card {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 20px; background: var(--champagne);
  border: 1px solid var(--border-gold);
}
body.dark-mode .tour-info-card { background: var(--dark-surface-2); }
.tour-info-card__icon { font-size: 24px; line-height: 1; }
.tour-info-card strong {
  display: block; font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 4px;
}
.tour-info-card p { font-size: 14px; color: var(--text-muted); }
body.dark-mode .tour-info-card p { color: var(--dark-muted); }

/* Itinerary — Timeline premium (estilo Peru Beyond mejorado) */
.itinerary-intro {
  font-size: 15px; color: var(--text-muted); margin: -12px 0 40px;
  max-width: 560px; line-height: 1.7;
}
body.dark-mode .itinerary-intro { color: var(--dark-muted); }

.itinerary-timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.itinerary-step {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 0 28px;
  position: relative;
  padding-bottom: 48px;
}

.itinerary-step:last-child { padding-bottom: 0; }

.itinerary-step:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 43px;
  top: 72px;
  bottom: 0;
  width: 0;
  border-left: 2px dotted rgba(201, 162, 39, 0.45);
}

.itinerary-step__rail {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  align-self: start;
  padding-top: 4px;
}

.itinerary-step__badge {
  width: 72px;
  height: 72px;
  aspect-ratio: 1;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #E8B923 0%, #C9A227 55%, #A8841A 100%);
  border-radius: 10px;
  box-shadow: 0 6px 20px rgba(201, 162, 39, 0.4);
  position: relative;
  z-index: 1;
  transition: transform var(--transition), box-shadow var(--transition);
}

.itinerary-step:hover .itinerary-step__badge {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(201, 162, 39, 0.45);
}

.itinerary-step__label {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.92);
  line-height: 1;
  margin-bottom: 4px;
}

.itinerary-step__num {
  font-family: var(--ff-display);
  font-size: 1.65rem;
  font-weight: 700;
  color: #fff;
  line-height: 1;
}

.itinerary-step__panel {
  background: var(--white);
  border: 1px solid var(--border-gold);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: box-shadow var(--transition), border-color var(--transition);
}

body.dark-mode .itinerary-step__panel {
  background: var(--dark-surface-2);
  border-color: rgba(201, 162, 39, 0.2);
}

.itinerary-step:hover .itinerary-step__panel {
  box-shadow: 0 16px 48px rgba(201, 162, 39, 0.12);
  border-color: rgba(201, 162, 39, 0.4);
}

.itinerary-step__head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px;
  text-align: left;
  background: var(--champagne);
  border-bottom: 1px solid transparent;
  transition: background var(--transition), border-color var(--transition);
  cursor: pointer;
}

body.dark-mode .itinerary-step__head {
  background: rgba(201, 162, 39, 0.06);
}

.itinerary-step.is-open .itinerary-step__head {
  border-bottom-color: var(--border-gold);
}

.itinerary-step__titles h3 {
  font-family: var(--ff-display);
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  font-weight: 600;
  color: var(--black);
  line-height: 1.25;
  margin-bottom: 6px;
}

body.dark-mode .itinerary-step__titles h3 { color: var(--dark-text); }

.itinerary-step__summary {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 640px;
}

body.dark-mode .itinerary-step__summary { color: var(--dark-muted); }

.itinerary-step__toggle {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border-gold);
  background: var(--white);
  position: relative;
  transition: transform var(--transition-smooth, 0.4s ease), background var(--transition);
}

body.dark-mode .itinerary-step__toggle { background: var(--dark-surface); }

.itinerary-step__toggle::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--gold);
  border-bottom: 2px solid var(--gold);
  transform: translate(-50%, -65%) rotate(45deg);
  transition: transform var(--transition-smooth, 0.4s ease);
}

.itinerary-step.is-open .itinerary-step__toggle::before {
  transform: translate(-50%, -35%) rotate(-135deg);
}

.itinerary-step__body {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.55s cubic-bezier(0.4, 0, 0.2, 1),
              opacity 0.4s ease,
              padding 0.4s ease;
  padding: 0 24px;
}

.itinerary-step.is-open .itinerary-step__body {
  max-height: 1200px;
  opacity: 1;
  padding: 24px;
}

.itinerary-step__list {
  margin-bottom: 24px;
}

.itinerary-step__list li {
  position: relative;
  padding-left: 22px;
  margin-bottom: 12px;
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.65;
}

body.dark-mode .itinerary-step__list li { color: var(--dark-muted); }

.itinerary-step__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-metallic);
  box-shadow: 0 0 0 3px rgba(201, 162, 39, 0.15);
}

.itinerary-step__photos {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.itinerary-step__photo {
  margin: 0;
  overflow: hidden;
  border-radius: 12px;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--border-gold);
  background: rgba(0, 0, 0, 0.06);
}

.itinerary-step__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 280ms ease, transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.itinerary-step__photo.is-loaded img {
  opacity: 1;
}

.itinerary-step__photo:hover img {
  transform: scale(1.06);
}

/* Todos abiertos por defecto en desktop */
@media (min-width: 769px) {
  .itinerary-step { grid-template-columns: 96px 1fr; }
  .itinerary-step:not(:last-child)::before { left: 47px; }
  .itinerary-step__badge { width: 80px; height: 80px; border-radius: 12px; }
  .itinerary-step__head { cursor: default; pointer-events: none; }
  .itinerary-step__toggle { display: none; }
  .itinerary-step__body {
    max-height: none;
    opacity: 1;
    padding: 24px;
    overflow: visible;
  }
  .itinerary-step__head { border-bottom-color: var(--border-gold); }
}

@media (max-width: 768px) {
  .itinerary-step {
    grid-template-columns: 64px 1fr;
    gap: 0 16px;
  }
  .itinerary-step:not(:last-child)::before { left: 31px; top: 64px; }
  .itinerary-step__badge {
    width: 56px;
    height: 56px;
    border-radius: 8px;
  }
  .itinerary-step__num { font-size: 1.25rem; }
  .itinerary-step__photos { grid-template-columns: 1fr; }
  .itinerary-step.is-open .itinerary-step__body { padding: 20px; }
}

/* Includes */
.includes-grid { display: grid; gap: 24px; }
.includes-box {
  padding: 28px; border: 1px solid var(--border-gold);
}
.includes-box--yes { background: rgba(201,162,39,0.06); }
.includes-box--no { background: var(--champagne); }
body.dark-mode .includes-box--no { background: var(--dark-surface-2); }

.includes-box h3 {
  font-family: var(--ff-display); font-size: 1.125rem;
  margin-bottom: 16px; color: var(--gold);
}
.includes-box li {
  position: relative; padding-left: 24px; margin-bottom: 10px;
  font-size: 14px; line-height: 1.6;
}
.includes-box--yes li::before {
  content: "✓"; position: absolute; left: 0; color: var(--gold); font-weight: 700;
}
.includes-box--no li::before {
  content: "×"; position: absolute; left: 0; color: var(--text-muted);
}

/* Gallery */
.tour-gallery {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px;
}
.tour-gallery img {
  width: 100%; aspect-ratio: 4/3; object-fit: cover;
  cursor: pointer; transition: var(--transition);
}
.tour-gallery img:first-child { grid-column: span 2; aspect-ratio: 21/9; }
.tour-gallery img:hover { opacity: 0.9; transform: scale(1.01); }

/* FAQ */
.faq-item { border-bottom: 1px solid var(--border-gold); }
.faq-item__q {
  width: 100%; display: flex; justify-content: space-between; align-items: center;
  gap: 16px; padding: 20px 0; text-align: left;
  font-family: var(--ff-display); font-size: 1.05rem; font-weight: 500;
  color: var(--black); transition: color var(--transition);
}
body.dark-mode .faq-item__q { color: var(--dark-text); }
.faq-item__q:hover { color: var(--gold); }
.faq-item__icon {
  flex-shrink: 0; width: 28px; height: 28px;
  display: grid; place-items: center;
  border: 1px solid var(--border-gold); color: var(--gold);
  font-size: 18px; transition: var(--transition);
}
.faq-item.open .faq-item__icon { transform: rotate(45deg); background: var(--gold); color: var(--black); }
.faq-item__a {
  display: none; padding-bottom: 20px;
  font-size: 15px; color: var(--text-muted); line-height: 1.7;
}
body.dark-mode .faq-item__a { color: var(--dark-muted); }
.faq-item.open .faq-item__a { display: block; }

/* Sidebar */
.tour-sidebar { position: relative; }
.tour-booking-card {
  position: sticky; top: 140px;
  padding: 32px; background: var(--white);
  border: 1px solid var(--border-gold);
  box-shadow: var(--shadow-soft);
}
body.dark-mode .tour-booking-card {
  background: var(--dark-surface); border-color: rgba(201,162,39,0.2);
}

.tour-booking-card__label {
  font-size: 11px; letter-spacing: 0.15em; text-transform: uppercase;
  color: var(--text-muted);
}
.tour-booking-card__price {
  font-family: var(--ff-display); font-size: 2.25rem;
  color: var(--gold); margin: 8px 0 4px;
}
.tour-booking-card__duration {
  font-size: 14px; color: var(--text-muted); margin-bottom: 24px;
}
.tour-booking-card__note {
  font-size: 12px; color: var(--text-muted); text-align: center;
  margin-top: 16px; line-height: 1.5;
}

.btn-block {
  width: 100%; margin-bottom: 10px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.btn-block ion-icon { font-size: 20px; }

/* Mobile bar */
.tour-mobile-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 90;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 12px 20px;
  background: var(--white); border-top: 1px solid var(--border-gold);
  box-shadow: 0 -4px 24px rgba(0,0,0,0.1);
}
body.dark-mode .tour-mobile-bar { background: var(--dark-surface); }

.tour-page .go-top { bottom: 92px; }
.tour-page .whatsapp-float { bottom: 80px; }
.tour-page .wsp-widget { bottom: 148px; }
.tour-page .toast-container { bottom: 80px; }

.tour-mobile-bar__price span {
  display: block; font-size: 10px; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--text-muted);
}
.tour-mobile-bar__price strong {
  font-family: var(--ff-display); font-size: 1.25rem; color: var(--gold);
}
.tour-mobile-bar .btn { padding: 12px 24px; flex-shrink: 0; }
.tour-mobile-bar .btn ion-icon { font-size: 18px; }

@media (min-width: 992px) {
  .tour-layout { grid-template-columns: 1fr 340px; }
  .includes-grid { grid-template-columns: 1fr 1fr; }
  .tour-mobile-bar { display: none; }
  .tour-page { padding-bottom: 0; }
}

@media (max-width: 991px) {
  .tour-sidebar { display: none; }
  .tour-tabs__link--gold { display: none; }
}

@media (max-width: 580px) {
  .itinerary-step__photos { grid-template-columns: 1fr; }
  .tour-gallery { grid-template-columns: 1fr; }
  .tour-gallery img:first-child { grid-column: span 1; aspect-ratio: 16/10; }
}
