/**
 * Tour Itinerary Styles - Compact Spacing (30% reduction)
 * Theme: Teal/Cyan Premium
 * Version: 1.0.4
 */

/* ========================================
   ROOT VARIABLES
======================================== */
:root {
  --tour-primary-tsd419: #14b8a6;
  --tour-primary-dark-tsd419: #0d9488;
  --tour-primary-light-tsd419: #5eead4;
  --tour-secondary-tsd419: #06b6d4;
  --tour-accent-tsd419: #10b981;
  --tour-text-tsd419: #0f172a;
  --tour-text-light-tsd419: #64748b;
  --tour-bg-tsd419: #ffffff;
  --tour-bg-alt-tsd419: #f8fafc;
  --tour-border-tsd419: #e2e8f0;
  --tour-shadow-tsd419: 0 1px 3px rgba(0, 0, 0, 0.08);
  --tour-shadow-md-tsd419: 0 4px 6px rgba(0, 0, 0, 0.1);
  --tour-radius-tsd419: 12px;
}

/* ========================================
   MAIN WRAPPER - COMPACT SPACING
======================================== */
.tour-itinerary-wrapper-tsd419 {
  width: 100%;
  padding: 1.05rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--tour-text-tsd419);
  line-height: 1.6;
}

/* ========================================
   HEADER
======================================== */
.tour-header-tsd419 {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.05rem;
  padding-bottom: 0.7rem;
  border-bottom: 2px solid var(--tour-border-tsd419);
}

.tour-header-content-tsd419 {
  flex: 1;
}

.tour-main-title-tsd419 {
  margin: 0 0 0.35rem 0;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--tour-text-tsd419);
}

.tour-duration-tsd419 {
  margin: 0;
  font-size: 1rem;
  color: var(--tour-text-light-tsd419);
}

/* ========================================
   TIMELINE CONTAINER - COMPACT GAPS
======================================== */
.tour-timeline-tsd419 {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
  gap: 1.05rem;
}

/* ========================================
   DAY CARD - COMPACT
======================================== */
.tour-day-card-tsd419 {
  display: flex;
  gap: 0.7rem;
  position: relative;
  height: fit-content;
}

/* ========================================
   DAY BADGE
======================================== */
.tour-day-badge-tsd419 {
  flex-shrink: 0;
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, var(--tour-primary-tsd419) 0%, var(--tour-secondary-tsd419) 100%);
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(20, 184, 166, 0.35);
  position: relative;
  z-index: 2;
}

.day-label-tsd419 {
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.9;
}

.day-number-tsd419 {
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1;
}

/* ========================================
   DAY CONTENT - COMPACT PADDING
======================================== */
.tour-day-content-tsd419 {
  flex: 1;
  background: var(--tour-bg-tsd419);
  border: 1px solid var(--tour-border-tsd419);
  border-radius: var(--tour-radius-tsd419);
  padding: 1.05rem;
  box-shadow: var(--tour-shadow-tsd419);
  transition: box-shadow 0.3s ease;
}

.tour-day-content-tsd419:hover {
  box-shadow: var(--tour-shadow-md-tsd419);
}

.tour-day-title-tsd419 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.7rem 0;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--tour-text-tsd419);
}

.tour-day-title-tsd419 .fa-map-marker-alt {
  color: var(--tour-primary-tsd419);
  font-size: 1.1rem;
}

/* ========================================
   INLINE MEALS - HORIZONTAL LAYOUT
======================================== */
.tour-meals-inline-tsd419 {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.5rem 0.7rem;
  margin-bottom: 0.7rem;
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
  border-radius: 8px;
  border-left: 3px solid var(--tour-primary-tsd419);
}

.meals-icon-tsd419 {
  color: var(--tour-primary-tsd419);
  font-size: 1rem;
  flex-shrink: 0;
}

.meals-list-tsd419 {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  flex: 1;
}

.meal-item-tsd419 {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.6rem;
  background: var(--tour-bg-tsd419);
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--tour-text-tsd419);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  white-space: nowrap;
}

.meal-item-tsd419 i {
  color: var(--tour-secondary-tsd419);
  font-size: 0.95rem;
}

/* ========================================
   ACTIVITY TIMELINE - COMPACT
======================================== */
.tour-activities-tsd419 {
  margin-bottom: 0.7rem;
}

.activity-item-tsd419 {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
}

.activity-icon-tsd419 {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  background: linear-gradient(135deg, var(--tour-primary-light-tsd419) 0%, var(--tour-primary-tsd419) 100%);
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 1rem;
}

.activity-content-tsd419 {
  flex: 1;
  padding-top: 0.25rem;
}

.activity-label-tsd419 {
  display: block;
  font-weight: 600;
  color: var(--tour-text-tsd419);
  margin-bottom: 0.25rem;
  font-size: 0.95rem;
}

.activity-content-tsd419 p {
  margin: 0.25rem 0;
  color: var(--tour-text-light-tsd419);
  font-size: 0.95rem;
}

/* ========================================
   COLLAPSIBLE CONTENT
======================================== */
.activity-description-tsd419 {
  color: var(--tour-text-tsd419);
  font-size: 0.95rem;
}

.activity-text-content-tsd419 {
  transition: max-height 0.4s ease;
}

.activity-text-content-tsd419.is-collapsed-tsd419 {
  max-height: 250px;
  overflow: hidden;
  position: relative;
}

.activity-text-content-tsd419.is-collapsed-tsd419::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(to bottom, transparent, var(--tour-bg-tsd419));
  pointer-events: none;
}

.activity-description-tsd419 p {
  margin: 0 0 0.5rem 0;
}

.activity-description-tsd419 ul,
.activity-description-tsd419 ol {
  margin: 0.5rem 0;
  padding-left: 1.05rem;
}

.activity-description-tsd419 li {
  margin-bottom: 0.35rem;
}

/* Toggle Button */
.toggle-content-btn-tsd419 {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  width: 100%;
  margin-top: 0.7rem;
  padding: 0.5rem 0.7rem;
  background: var(--tour-bg-alt-tsd419);
  border: 1px solid var(--tour-border-tsd419);
  border-radius: 8px;
  color: var(--tour-primary-tsd419);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.toggle-content-btn-tsd419:hover {
  background: var(--tour-primary-tsd419);
  color: #ffffff;
  border-color: var(--tour-primary-tsd419);
}

.toggle-content-btn-tsd419:focus {
  outline: 2px solid var(--tour-primary-tsd419);
  outline-offset: 2px;
}

.toggle-content-btn-tsd419 i {
  transition: transform 0.3s ease;
}

/* ========================================
   ACCOMMODATION - COMPACT
======================================== */
.tour-accommodation-item-tsd419 {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  margin-top: 0.7rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--tour-border-tsd419);
}

.tour-accommodation-item-tsd419 .activity-icon-tsd419 {
  background: linear-gradient(135deg, #f59e0b 0%, #f97316 100%);
}

/* ========================================
   GALLERY SECTION - COMPACT
======================================== */
.tour-gallery-section-tsd419 {
  margin-top: 0.7rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--tour-border-tsd419);
}

.gallery-section-title-tsd419 {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0 0 0.7rem 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--tour-text-tsd419);
}

.gallery-section-title-tsd419 .fa-images {
  color: var(--tour-secondary-tsd419);
}

.gallery-count-tsd419 {
  margin-left: auto;
  font-size: 0.85rem;
  color: var(--tour-text-light-tsd419);
  font-weight: 400;
}

/* ========================================
   GALLERY GRID - 100x100px WITH COMPACT GAP
======================================== */
.tour-gallery-grid-tsd419 {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.gallery-thumb-tsd419 {
  position: relative;
  width: 100px;
  height: 100px;
  overflow: hidden;
  border-radius: 8px;
  border: 2px solid var(--tour-border-tsd419);
  padding: 0;
  background: var(--tour-bg-alt-tsd419);
  cursor: pointer;
  transition: all 0.3s ease;
}

.gallery-thumb-tsd419:hover {
  transform: scale(1.08);
  border-color: var(--tour-primary-tsd419);
  box-shadow: 0 4px 12px rgba(20, 184, 166, 0.3);
}

.gallery-thumb-tsd419:focus {
  outline: 2px solid var(--tour-primary-tsd419);
  outline-offset: 2px;
}

.gallery-thumb-tsd419 img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-thumb-overlay-tsd419 {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(20, 184, 166, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-thumb-tsd419:hover .gallery-thumb-overlay-tsd419 {
  opacity: 1;
}

.gallery-thumb-overlay-tsd419 .fa-search-plus {
  font-size: 1.5rem;
  color: #ffffff;
}

/* ========================================
   LIGHTBOX MODAL
======================================== */
.tour-lightbox-tsd419 {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.95);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.lightbox-content-tsd419 {
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.lightbox-image-tsd419 {
  max-width: 100%;
  max-height: calc(90vh - 6rem);
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.lightbox-caption-tsd419 {
  padding: 0.75rem 1.5rem;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 6px;
  color: var(--tour-text-tsd419);
  font-size: 0.95rem;
  max-width: 600px;
  text-align: center;
}

.lightbox-counter-tsd419 {
  padding: 0.5rem 1rem;
  background: rgba(20, 184, 166, 0.9);
  border-radius: 20px;
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 600;
}

/* Lightbox Controls */
.lightbox-close-tsd419,
.lightbox-prev-tsd419,
.lightbox-next-tsd419 {
  position: absolute;
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: #ffffff;
  font-size: 1.5rem;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 50%;
  transition: background 0.3s ease;
  backdrop-filter: blur(10px);
}

.lightbox-close-tsd419:hover,
.lightbox-prev-tsd419:hover,
.lightbox-next-tsd419:hover {
  background: rgba(20, 184, 166, 0.8);
}

.lightbox-close-tsd419:focus,
.lightbox-prev-tsd419:focus,
.lightbox-next-tsd419:focus {
  outline: 2px solid #ffffff;
  outline-offset: 2px;
}

.lightbox-close-tsd419 {
  top: 1rem;
  right: 1rem;
}

.lightbox-prev-tsd419 {
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-next-tsd419 {
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

/* ========================================
   NO DATA MESSAGE
======================================== */
.tour-no-data-tsd419 {
  padding: 2rem;
  text-align: center;
  color: var(--tour-text-light-tsd419);
  background: var(--tour-bg-alt-tsd419);
  border-radius: var(--tour-radius-tsd419);
}

/* ========================================
   RESPONSIVE DESIGN
======================================== */
@media (max-width: 1200px) {
  .tour-timeline-tsd419 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .tour-itinerary-wrapper-tsd419 {
    padding: 0.7rem;
  }

  .tour-header-tsd419 {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 0.7rem;
    padding-bottom: 0.5rem;
  }

  .tour-main-title-tsd419 {
    font-size: 1.5rem;
  }

  .tour-timeline-tsd419 {
    gap: 0.7rem;
  }

  .tour-day-card-tsd419 {
    gap: 0.5rem;
  }

  .tour-day-badge-tsd419 {
    width: 60px;
    height: 60px;
  }

  .day-number-tsd419 {
    font-size: 1.5rem;
  }

  .tour-day-content-tsd419 {
    padding: 0.7rem;
  }

  .tour-day-title-tsd419 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
  }

  .tour-meals-inline-tsd419 {
    padding: 0.4rem 0.5rem;
    margin-bottom: 0.5rem;
  }

  .meals-list-tsd419 {
    gap: 0.35rem;
  }

  .meal-item-tsd419 {
    font-size: 0.8rem;
    padding: 0.2rem 0.5rem;
  }

  .activity-icon-tsd419 {
    width: 34px;
    height: 34px;
    font-size: 0.9rem;
  }

  .tour-gallery-grid-tsd419 {
    gap: 0.35rem;
  }

  .gallery-thumb-tsd419 {
    width: 80px;
    height: 80px;
  }
}

@media (max-width: 480px) {
  .tour-day-card-tsd419 {
    flex-direction: column;
  }

  .tour-day-badge-tsd419 {
    align-self: flex-start;
    width: 55px;
    height: 55px;
  }

  .day-number-tsd419 {
    font-size: 1.35rem;
  }

  .gallery-thumb-tsd419 {
    width: 70px;
    height: 70px;
  }

  .lightbox-close-tsd419,
  .lightbox-prev-tsd419,
  .lightbox-next-tsd419 {
    width: 40px;
    height: 40px;
    font-size: 1.25rem;
  }
}

/* ========================================
   PRINT STYLES
======================================== */
@media print {

  .tour-gallery-section-tsd419,
  .tour-lightbox-tsd419,
  .toggle-content-btn-tsd419 {
    display: none !important;
  }

  .activity-text-content-tsd419.is-collapsed-tsd419 {
    max-height: none !important;
    overflow: visible !important;
  }

  .activity-text-content-tsd419.is-collapsed-tsd419::after {
    display: none !important;
  }

  .tour-day-card-tsd419 {
    page-break-inside: avoid;
  }
}

/* ========================================
   ACCESSIBILITY
======================================== */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
  :root {
    --tour-text-tsd419: #f1f5f9;
    --tour-text-light-tsd419: #94a3b8;
    --tour-bg-tsd419: #1e293b;
    --tour-bg-alt-tsd419: #0f172a;
    --tour-border-tsd419: #334155;
  }

  .tour-meals-inline-tsd419 {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
  }

  .meal-item-tsd419 {
    background: var(--tour-bg-alt-tsd419);
  }

  .activity-text-content-tsd419.is-collapsed-tsd419::after {
    background: linear-gradient(to bottom, transparent, #1e293b);
  }

  .lightbox-caption-tsd419 {
    background: rgba(30, 41, 59, 0.95);
    color: #f1f5f9;
  }
}
