/* ========================================
   Tour Virtual 360° — Estilos propios
   (Complementa style.optimized.css de la shop)
   ======================================== */

/* --- Hero del Tour --- */
.tour-hero {
  position: relative;
  min-height: 55vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  background: linear-gradient(135deg, #060E1E 0%, #0f172a 50%, #1e293b 100%);
  overflow: hidden;
}

/* Video de fondo del hero */
.tour-hero-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0.45;
  filter: saturate(1.1);
}

/* Overlay gris delante del video para legibilidad */
.tour-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(to top, rgba(38,44,58,0.92) 0%, rgba(45,52,68,0.70) 50%, rgba(45,52,68,0.55) 100%),
    radial-gradient(ellipse at 50% 40%, rgba(120,130,150,0.12) 0%, transparent 60%);
  pointer-events: none;
}

.tour-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(99,102,241,0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 50%, rgba(139,92,246,0.10) 0%, transparent 50%);
  pointer-events: none;
}

.tour-hero-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
  padding: 2rem 1.5rem;
}

/* Marca arriba del título */
.tour-hero-brand {
  display: inline-block;
  font-family: 'Outfit', 'Inter', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #d4d4dc;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(90,96,110,0.25);
  padding: 0.5rem 1.4rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
  animation: tour-hero-fade-up 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: 0.15s;
}

.tour-hero-tag {
  display: inline-block;
  background: rgba(99,102,241,0.15);
  color: #818cf8;
  padding: 0.4rem 1rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1px;
  margin-bottom: 1rem;
  text-transform: uppercase;
}

.tour-hero h1,
.tour-hero-title {
  font-family: 'Outfit', 'Inter', sans-serif;
  font-size: clamp(2.6rem, 7vw, 4.5rem);
  font-weight: 800;
  line-height: 1.05;
  margin-bottom: 1rem;
  color: #ffffff;
  animation: tour-hero-fade-up 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: 0.3s;
  text-shadow: 0 4px 30px rgba(0,0,0,0.45);
}

/* El "360°" destacado en blanco con halo sutil (legible sobre gris) */
.tour-hero-title-360 {
  color: #ffffff;
  background: linear-gradient(90deg, rgba(120,130,150,0.35), rgba(160,170,190,0.35));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 40px rgba(255,255,255,0.25);
}

.tour-hero-subtitle {
  font-size: 1.15rem;
  opacity: 0.9;
  line-height: 1.6;
  margin-bottom: 2rem;
  color: #e4e4ea;
  animation: tour-hero-fade-up 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: 0.45s;
}

/* Botón principal (base — funciona en hero y en CTA final) */
.btn-start {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  border: none;
  padding: 0.9rem 2.2rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(99,102,241,0.35);
}

.btn-start:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 35px rgba(99,102,241,0.5);
}

/* En el hero: entrada cinemática al cargar */
.tour-hero .btn-start {
  animation: tour-hero-fade-up 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: 0.6s;
}

/* --- Sección del Tour Viewer --- */
.tour-viewer-section {
  padding: 2rem 1.5rem;
  background: var(--bg-dark, #060E1E);
  scroll-margin-top: 90px; /* deja espacio para el header fijo al hacer scroll (cambio de escena) */
}

.tour-viewer-wrap {
  max-width: 1400px;
  margin: 0 auto;
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.tour-viewer-wrap .panorama-viewer {
  width: 100%;
  height: 70vh;
  min-height: 450px;
  background: #000;
}

/* --- Controles del Tour --- */
.tour-controls {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 1rem;
  background: rgba(0, 0, 0, 0.75);
  padding: 0.7rem 1.5rem;
  border-radius: 50px;
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.08);
  z-index: 20;
}

.tour-controls .control-btn {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.15rem;
  cursor: pointer;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
}

.tour-controls .control-btn:hover {
  background: rgba(255,255,255,0.15);
}

.tour-controls .scene-indicator {
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  min-width: 50px;
  text-align: center;
}

/* --- Panel Info de Escena --- */
.tour-scene-info {
  position: absolute;
  top: 20px;
  left: 20px;
  background: rgba(0, 0, 0, 0.75);
  color: #fff;
  padding: 1rem 1.5rem;
  border-radius: 12px;
  max-width: 300px;
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.08);
}

.tour-scene-info h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.tour-scene-info p {
  font-size: 0.85rem;
  opacity: 0.85;
  line-height: 1.45;
  margin: 0;
}

/* --- Botón Fullscreen --- */
.tour-fullscreen-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(0, 0, 0, 0.75);
  border: 1px solid rgba(255,255,255,0.1);
  color: #fff;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.25s ease;
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.tour-fullscreen-btn:hover {
  background: rgba(99,102,241,0.6);
  border-color: rgba(99,102,241,0.4);
  transform: scale(1.05);
}

/* --- Selector de Escenas (cards) --- */
.tour-scenes-section {
  padding: 4rem 1.5rem;
  background: var(--bg-dark, #060E1E);
}

.tour-scenes-section .section-title {
  text-align: center;
  margin-bottom: 2.5rem;
}

.tour-scenes-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
}

.tour-scene-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
}

.tour-scene-card:hover,
.tour-scene-card.active {
  transform: translateY(-5px);
  border-color: rgba(99,102,241,0.4);
  box-shadow: 0 12px 30px rgba(99,102,241,0.15);
}

.tour-scene-card.active {
  border-color: #6366f1;
  background: rgba(99,102,241,0.08);
}

.tour-scene-thumb {
  height: 140px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
}

.tour-scene-thumb::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(6,14,30,0.6) 0%, transparent 60%);
}

.tour-scene-label {
  padding: 0.85rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 500;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.85);
}

.tour-scene-label i {
  color: #818cf8;
  font-size: 1rem;
}

.tour-scene-card.active .tour-scene-label {
  color: #fff;
}

/* --- Sección Info (Ubicación, Horario, Contacto) --- */
.tour-info-section {
  padding: 4rem 1.5rem;
  background: #0a1628;
}

.tour-info-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

.tour-info-card {
  text-align: center;
  padding: 2rem 1.5rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 14px;
  transition: all 0.3s ease;
}

.tour-info-card:hover {
  transform: translateY(-5px);
  border-color: rgba(99,102,241,0.25);
  box-shadow: 0 12px 30px rgba(0,0,0,0.3);
}

.tour-info-icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, rgba(99,102,241,0.2), rgba(139,92,246,0.2));
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
}

.tour-info-icon i {
  font-size: 1.5rem;
  color: #818cf8;
}

.tour-info-card h3 {
  font-size: 1.05rem;
  color: #fff;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.tour-info-card p {
  color: rgba(255,255,255,0.6);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0;
}

/* --- WhatsApp Float (mismo estilo que shop) --- */
.tour-whatsapp-float {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 56px;
  height: 56px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.75rem;
  box-shadow: 0 6px 20px rgba(37,211,102,0.4);
  transition: all 0.3s ease;
  z-index: 9999;
  text-decoration: none;
}

.tour-whatsapp-float:hover {
  transform: scale(1.1);
  background: #128C7E;
  box-shadow: 0 8px 25px rgba(37,211,102,0.5);
}

/* --- Pannellum Overrides --- */
.tour-viewer-wrap .pnlm-container {
  background: #000;
  border-radius: 16px;
}

.tour-viewer-wrap .pnlm-render-container {
  cursor: grab;
  border-radius: 16px;
}

.tour-viewer-wrap .pnlm-render-container:active {
  cursor: grabbing;
}

.tour-viewer-wrap .pnlm-hotspot {
  cursor: pointer;
}

.tour-viewer-wrap .pnlm-hotspot:hover {
  filter: brightness(1.2);
}

/* --- Secciones de venta (dolor, stats, servicio, pasos, público, CTA) --- */
.tour-section-sub {
  text-align: center;
  color: rgba(255,255,255,0.75);
  font-size: 1.05rem;
  max-width: 680px;
  margin: -1.25rem auto 2.5rem;
  line-height: 1.6;
}

/* --- Dolor del cliente --- */
.tour-pain-section {
  padding: 4rem 1.5rem;
  background: #0a1628;
}

.tour-pain-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.tour-pain-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 14px;
  padding: 1.75rem 1.5rem;
  transition: all 0.3s ease;
}

.tour-pain-card:hover {
  transform: translateY(-5px);
  border-color: rgba(84,92,110,0.45);
  box-shadow: 0 12px 30px rgba(0,0,0,0.3);
}

.tour-pain-icon {
  width: 56px;
  height: 56px;
  background: rgba(140,84,92,0.15);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.tour-pain-icon i {
  font-size: 1.35rem;
  color: #e57373;
}

.tour-pain-card h3 {
  color: #fff;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.tour-pain-card p {
  color: rgba(255,255,255,0.65);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0;
}

/* --- Proof / stats --- */
.tour-stats-section {
  padding: 4rem 1.5rem;
  background: #060E1E;
}

.tour-stats-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  text-align: center;
}

.tour-stat {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 14px;
  padding: 2rem 1.25rem;
}

.tour-stat-number {
  display: block;
  font-family: 'Outfit', 'Inter', sans-serif;
  font-size: clamp(2.2rem, 5vw, 3rem);
  font-weight: 800;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.1;
  margin-bottom: 0.5rem;
}

.tour-stat-label {
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
  line-height: 1.5;
}

.tour-stats-note {
  text-align: center;
  color: rgba(255,255,255,0.35);
  font-size: 0.75rem;
  margin-top: 1.75rem;
}

/* --- Servicio --- */
.tour-service-section {
  padding: 4rem 1.5rem;
  background: #0a1628;
}

.tour-service-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.tour-service-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 14px;
  padding: 1.75rem 1.5rem;
  transition: all 0.3s ease;
}

.tour-service-card:hover {
  transform: translateY(-5px);
  border-color: rgba(99,102,241,0.35);
  box-shadow: 0 12px 30px rgba(99,102,241,0.12);
}

.tour-service-icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, rgba(99,102,241,0.2), rgba(139,92,246,0.2));
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.tour-service-icon i {
  font-size: 1.3rem;
  color: #818cf8;
}

.tour-service-card h3 {
  color: #fff;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.tour-service-card p {
  color: rgba(255,255,255,0.65);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0;
}

/* --- Pasos --- */
.tour-how-section {
  padding: 4rem 1.5rem;
  background: #060E1E;
}

.tour-steps-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  position: relative;
}

.tour-step {
  text-align: center;
  padding: 1.5rem 1.25rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 14px;
  position: relative;
}

.tour-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  font-family: 'Outfit', 'Inter', sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1rem;
  box-shadow: 0 8px 20px rgba(99,102,241,0.35);
}

.tour-step h3 {
  color: #fff;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.tour-step p {
  color: rgba(255,255,255,0.65);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0;
}

/* --- Para quién --- */
.tour-for-section {
  padding: 4rem 1.5rem;
  background: #0a1628;
}

.tour-for-grid {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.tour-for-card {
  text-align: center;
  padding: 2rem 1.5rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 14px;
  transition: all 0.3s ease;
}

.tour-for-card:hover {
  transform: translateY(-5px);
  border-color: rgba(99,102,241,0.35);
}

.tour-for-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, rgba(99,102,241,0.2), rgba(139,92,246,0.2));
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
}

.tour-for-icon i {
  font-size: 1.4rem;
  color: #818cf8;
}

.tour-for-card h3 {
  color: #fff;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.tour-for-card p {
  color: rgba(255,255,255,0.65);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0;
}

/* --- CTA final --- */
.tour-cta-section {
  padding: 4.5rem 1.5rem;
  background: linear-gradient(135deg, #060E1E 0%, #101c38 100%);
  text-align: center;
}

.tour-cta-section h2 {
  font-family: 'Outfit', 'Inter', sans-serif;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.75rem;
}

.tour-cta-section p {
  color: rgba(255,255,255,0.7);
  font-size: 1.05rem;
  margin-bottom: 2rem;
}

.tour-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.tour-cta-actions .btn-start {
  text-decoration: none;
  animation: none;
}

.tour-cta-actions .btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.25);
  padding: 0.9rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 50px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.tour-cta-actions .btn-outline:hover {
  border-color: #818cf8;
  color: #818cf8;
  transform: translateY(-2px);
}

/* --- Loading --- */
@keyframes tour-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* ========================================
   ANIMACIONES DEL TOUR (pone el sitio vivo)
   ======================================== */

/* Títulos de sección centrados y consistentes (la shop los deja a la izquierda) */
.tour-section .section-title,
.tour-pain-section .section-title,
.tour-stats-section .section-title,
.tour-service-section .section-title,
.tour-viewer-section .section-title,
.tour-scenes-section .section-title,
.tour-how-section .section-title,
.tour-for-section .section-title,
.tour-cta-section .section-title {
  text-align: center;
  font-weight: 800;
}

/* Subrayado animado bajo los títulos de sección */
.tour-section .section-title,
.tour-pain-section .section-title,
.tour-stats-section .section-title,
.tour-service-section .section-title,
.tour-viewer-section .section-title,
.tour-scenes-section .section-title,
.tour-how-section .section-title,
.tour-for-section .section-title,
.tour-cta-section .section-title {
  position: relative;
  padding-bottom: 0.65rem;
}

.tour-section .section-title::after,
.tour-pain-section .section-title::after,
.tour-stats-section .section-title::after,
.tour-service-section .section-title::after,
.tour-viewer-section .section-title::after,
.tour-scenes-section .section-title::after,
.tour-how-section .section-title::after,
.tour-for-section .section-title::after,
.tour-cta-section .section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 3px;
  border-radius: 3px;
  background: linear-gradient(90deg, #6366f1, #8b5cf6, #6366f1);
  background-size: 200% 100%;
  animation: tour-underline-grow 1s cubic-bezier(0.22, 1, 0.36, 1) 0.2s forwards;
}

@keyframes tour-underline-grow {
  0% { width: 0; }
  100% { width: 120px; }
}

/* Reveal on scroll: las cards aparecen con fade-up escalonado */
.reveal {
  opacity: 0;
  transform: translateY(36px) scale(0.97);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: var(--reveal-delay, 0s);
  will-change: opacity, transform;
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Hover: levantar cards + icono cobra vida */
.tour-pain-card, .tour-stat, .tour-service-card, .tour-step,
.tour-for-card, .tour-scene-card, .tour-info-card {
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
              box-shadow 0.35s ease, border-color 0.35s ease;
}

.tour-pain-card:hover, .tour-stat:hover, .tour-service-card:hover,
.tour-step:hover, .tour-for-card:hover, .tour-info-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 22px 45px rgba(0,0,0,0.35);
}

.tour-pain-icon, .tour-service-icon, .tour-for-icon, .tour-info-icon {
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tour-pain-card:hover .tour-pain-icon,
.tour-service-card:hover .tour-service-icon,
.tour-for-card:hover .tour-for-icon,
.tour-info-card:hover .tour-info-icon {
  transform: scale(1.12) rotate(-6deg);
}

/* Botón principal: brillo que cruza (shine sweep) */
.btn-start {
  position: relative;
  overflow: hidden;
}

.btn-start::after {
  content: '';
  position: absolute;
  top: 0;
  left: -80%;
  width: 50%;
  height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,0.35), transparent);
  transform: skewX(-20deg);
  animation: tour-shine 3s ease-in-out infinite;
}

@keyframes tour-shine {
  0% { left: -80%; }
  55%, 100% { left: 130%; }
}

/* Número de paso: pop al hover */
.tour-step-num {
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tour-step:hover .tour-step-num {
  transform: scale(1.18) rotate(6deg);
}

/* WhatsApp float: pulso permanente */
.tour-whatsapp-float {
  animation: tour-whatsapp-pulse 2.4s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.tour-whatsapp-float:hover {
  animation-play-state: paused;
}

@keyframes tour-whatsapp-pulse {
  0%, 100% { box-shadow: 0 6px 20px rgba(37,211,102,0.4), 0 0 0 0 rgba(37,211,102,0.55); }
  50% { box-shadow: 0 6px 20px rgba(37,211,102,0.4), 0 0 0 16px rgba(37,211,102,0); }
}

/* Stats: número con escala al entrar (mantiene block: número arriba, texto debajo) */
.tour-stat-number {
  display: block;
  transform: scale(0.8);
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tour-stat.revealed .tour-stat-number {
  transform: scale(1);
}

/* Hero: video se acerca sutilmente (slow zoom) */
.tour-hero-video {
  animation: tour-hero-slowzoom 22s ease-in-out infinite alternate;
}

@keyframes tour-hero-slowzoom {
  0% { transform: scale(1); }
  100% { transform: scale(1.08); }
}

/* Controles del viewer: entrada suave */
.tour-controls, .tour-scene-info, .tour-fullscreen-btn {
  animation: tour-controls-in 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.4s both;
}

@keyframes tour-controls-in {
  0% { opacity: 0; transform: translateY(14px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* Arrow indices del hero: sutil movimiento */
.tour-hero-content .fa-play {
  display: inline-block;
  animation: tour-play-bounce 1.8s ease-in-out infinite;
}

@keyframes tour-play-bounce {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(4px); }
}

/* ========================================
   RESPONSIVE MEJORADO
   ======================================== */

/* PC grande: compactar nav antes de que desborde */
@media (max-width: 1200px) {
  .tour-pain-grid, .tour-for-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .tour-service-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Tablet: header hamburguesa ya aparece (shop a 992px), grids compactan */
@media (max-width: 992px) {
  .tour-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .tour-steps-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }

  .tour-viewer-wrap .panorama-viewer {
    height: 55vh;
  }
}

/* --- Entrada cinemática del hero --- */
@keyframes tour-hero-fade-up {
  0% {
    opacity: 0;
    transform: translateY(28px) scale(0.98);
    filter: blur(6px);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

.tour-loading {
  animation: tour-pulse 2s infinite;
}

/* --- Aviso de carga del visor 360° (móvil con datos lentos) --- */
.tour-viewer-loading {
  position: absolute;
  inset: 0;
  z-index: 25;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  text-align: center;
  padding: 1.5rem;
  background: linear-gradient(135deg, #0b1424 0%, #101c33 100%);
  border-radius: 14px;
  pointer-events: none;
}

.tour-viewer-loading.is-hidden {
  display: none;
}

.tour-viewer-loading.is-error {
  pointer-events: auto;
}

.tour-viewer-loading-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 3px solid rgba(129, 140, 248, 0.25);
  border-top-color: #818cf8;
  animation: tour-loading-spin 1s linear infinite;
}

.tour-viewer-loading.is-error .tour-viewer-loading-icon {
  animation: none;
  border: 3px solid rgba(248, 113, 113, 0.6);
}

.tour-viewer-loading-text {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.9rem;
  max-width: 30ch;
}

@keyframes tour-loading-spin {
  to { transform: rotate(360deg); }
}

/* --- Planes / inversión (valores por confirmar) --- */
.tour-plans-section {
  padding: 4rem 1.5rem;
  background: #060E1E;
}

.tour-plans-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  align-items: stretch;
}

.tour-plan-card {
  display: flex;
  flex-direction: column;
  padding: 2rem 1.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  transition: all 0.3s ease;
}

.tour-plan-card:hover {
  transform: translateY(-5px);
  border-color: rgba(99, 102, 241, 0.35);
}

.tour-plan-card.is-featured {
  border-color: rgba(99, 102, 241, 0.45);
  background: rgba(99, 102, 241, 0.07);
  box-shadow: 0 14px 34px rgba(99, 102, 241, 0.14);
}

.tour-plan-name {
  color: #fff;
  font-family: 'Outfit', 'Inter', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.tour-plan-for {
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.8rem;
  margin-bottom: 1.1rem;
}

.tour-plan-price {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: 0.4rem;
  padding: 0.5rem 0.9rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px dashed rgba(255, 255, 255, 0.28);
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.tour-plan-card.is-featured .tour-plan-price {
  background: rgba(99, 102, 241, 0.16);
  border-color: rgba(129, 140, 248, 0.5);
  color: #c7d2fe;
}

.tour-plan-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
  display: grid;
  gap: 0.6rem;
  flex: 1;
}

.tour-plan-list li {
  position: relative;
  padding-left: 1.6rem;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.88rem;
  line-height: 1.5;
}

.tour-plan-list li::before {
  content: '\f00c';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  left: 0;
  top: 0;
  color: #818cf8;
  font-size: 0.78rem;
}

.tour-plan-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.85rem 1rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.25s ease;
}

.tour-plan-card.is-featured .tour-plan-cta {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(99, 102, 241, 0.3);
}

.tour-plan-cta:hover {
  filter: brightness(1.12);
}

.tour-plans-note {
  max-width: 720px;
  margin: 1.75rem auto 0;
  text-align: center;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.8rem;
  line-height: 1.6;
}

/* --- Zona de servicio --- */
.tour-zone-section {
  padding: 4rem 1.5rem;
  background: #0a1628;
}

.tour-zone-grid {
  max-width: 1000px;
  margin: 0 auto 1.75rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

.tour-zone-item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.6rem 1.1rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.09);
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.88rem;
}

.tour-zone-item i {
  color: #818cf8;
  font-size: 0.8rem;
}

.tour-zone-item.is-base {
  background: rgba(99, 102, 241, 0.14);
  border-color: rgba(129, 140, 248, 0.45);
  color: #fff;
}

.tour-zone-note {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
  line-height: 1.7;
}

/* --- Preguntas frecuentes --- */
.tour-faq-section {
  padding: 4rem 1.5rem;
  background: #060E1E;
}

.tour-faq-list {
  max-width: 860px;
  margin: 0 auto;
  display: grid;
  gap: 0.85rem;
}

.tour-faq-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  overflow: hidden;
}

.tour-faq-item > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 1.25rem;
  color: #fff;
  font-size: 0.98rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.tour-faq-item > summary::-webkit-details-marker {
  display: none;
}

.tour-faq-item > summary::after {
  content: '\f078';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  color: #818cf8;
  font-size: 0.8rem;
  transition: transform 0.25s ease;
  flex-shrink: 0;
}

.tour-faq-item[open] > summary::after {
  transform: rotate(180deg);
}

.tour-faq-body {
  padding: 0 1.25rem 1.2rem;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.9rem;
  line-height: 1.7;
}

.tour-faq-body p {
  margin: 0;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .tour-hero {
    min-height: 45vh;
  }

  .tour-hero-title {
    font-size: 2rem;
  }

  .tour-hero-brand {
    font-size: 0.8rem;
    letter-spacing: 3px;
  }

  /* Grids de venta: 2 columnas en tablet */
  .tour-pain-grid,
  .tour-service-grid,
  .tour-for-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .tour-stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .tour-steps-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .tour-pain-section,
  .tour-stats-section,
  .tour-service-section,
  .tour-viewer-section,
  .tour-scenes-section,
  .tour-how-section,
  .tour-for-section,
  .tour-plans-section,
  .tour-zone-section,
  .tour-faq-section,
  .tour-cta-section {
    padding: 3rem 1rem;
  }

  .tour-section-sub {
    font-size: 0.95rem;
    margin-bottom: 1.75rem;
  }

  .tour-hero h1 {
    font-size: 1.8rem;
  }

  .tour-hero .hero-subtitle {
    font-size: 1rem;
  }

  .tour-viewer-wrap .panorama-viewer {
    height: 50vh;
    min-height: 300px;
  }

  .tour-controls {
    /* En móvil: barra debajo del viewer (flujo normal, siempre visible) */
    position: relative;
    bottom: auto;
    left: auto;
    transform: none;
    margin: 0.75rem auto 0;
    width: max-content;
    padding: 0.5rem 1rem;
    gap: 0.75rem;
    z-index: 30;
  }

  .tour-viewer-wrap {
    padding-bottom: 0.25rem;
  }

  .tour-scene-info {
    position: relative;
    top: auto;
    left: auto;
    max-width: 100%;
    margin: 0 0 0.75rem;
    border-radius: 10px;
  }

  .tour-fullscreen-btn {
    top: 12px;
    right: 12px;
    width: 38px;
    height: 38px;
  }

  .tour-scenes-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }

  .tour-scene-thumb {
    height: 100px;
  }

  .tour-info-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .tour-whatsapp-float {
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
  }
}

@media (max-width: 480px) {
  .tour-scenes-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
  }

  .tour-info-grid {
    grid-template-columns: 1fr;
  }

  /* Secciones de venta: 1 columna en móvil */
  .tour-pain-grid,
  .tour-service-grid,
  .tour-for-grid,
  .tour-stats-grid,
  .tour-plans-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .tour-plan-card {
    padding: 1.5rem 1.15rem;
  }

  .tour-zone-grid {
    gap: 0.5rem;
  }

  .tour-zone-item {
    padding: 0.5rem 0.85rem;
    font-size: 0.82rem;
  }

  .tour-faq-item > summary {
    padding: 0.95rem 1rem;
    font-size: 0.92rem;
  }

  .tour-faq-body {
    padding: 0 1rem 1rem;
  }

  .tour-viewer-loading {
    font-size: 0.85rem;
  }

  .tour-pain-card,
  .tour-service-card,
  .tour-for-card,
  .tour-stat {
    padding: 1.25rem 1rem;
  }

  .tour-cta-actions {
    flex-direction: column;
    align-items: center;
  }

  .tour-cta-actions .btn-start,
  .tour-cta-actions .btn-outline {
    width: 100%;
    max-width: 320px;
    justify-content: center;
  }

  .tour-hero .btn-start {
    padding: 0.8rem 1.8rem;
    font-size: 0.9rem;
  }
}
