/* Tour Page — Product Screenshot Gallery */

.tour-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

.tour-hero {
  text-align: center;
  padding: 3rem 0 2rem;
}

.tour-hero h1 {
  font-size: 2.5rem;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 0.75rem;
}

.tour-hero p {
  font-size: 1.125rem;
  color: #64748b;
  max-width: 600px;
  margin: 0 auto;
}

/* ── Filters ── */

.tour-filters {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  z-index: 50;
  padding: 1rem 0;
  border-bottom: 1px solid #e2e8f0;
  margin-bottom: 2rem;
}

.filter-bar {
  display: flex;
  gap: 1rem;
  align-items: end;
  flex-wrap: wrap;
}

.search-input {
  flex: 1;
  min-width: 200px;
  padding: 0.625rem 1rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 0.9375rem;
  outline: none;
  transition: border-color 0.2s;
}

.search-input:focus {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.filter-group label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.filter-group select {
  padding: 0.625rem 2rem 0.625rem 0.75rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 0.875rem;
  background: white;
  cursor: pointer;
  outline: none;
}

.filter-group select:focus {
  border-color: #6366f1;
}

/* ── Gallery Sections ── */

.tour-section {
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid #f1f5f9;
}

.tour-section:last-of-type {
  border-bottom: none;
}

.tour-section h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 0.5rem;
}

.section-desc {
  color: #64748b;
  font-size: 0.9375rem;
  margin-bottom: 1.5rem;
}

.tour-section[hidden] {
  display: none;
}

/* ── Screenshot Grid ── */

.screenshot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.screenshot-card {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  background: white;
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
}

.screenshot-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

.screenshot-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  object-position: top left;
  border-bottom: 1px solid #f1f5f9;
}

.screenshot-card h3 {
  font-size: 1rem;
  font-weight: 600;
  color: #1e293b;
  padding: 0.75rem 1rem 0.25rem;
  margin: 0;
}

.screenshot-card p {
  font-size: 0.8125rem;
  color: #64748b;
  padding: 0 1rem 1rem;
  margin: 0;
  line-height: 1.5;
}

.screenshot-card[hidden] {
  display: none;
}

/* ── Coming Soon ── */

.tour-coming-soon {
  background: #f8fafc;
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  border: 1px dashed #cbd5e1;
}

.tour-coming-soon h2 {
  color: #64748b;
}

/* ── CTA ── */

.tour-cta {
  text-align: center;
  padding: 3rem 0;
  margin-top: 2rem;
}

.tour-cta h2 {
  font-size: 1.75rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 0.5rem;
}

.tour-cta p {
  color: #64748b;
  margin-bottom: 1.5rem;
}

.btn-cta-large {
  display: inline-block;
  padding: 1rem 2.5rem;
  background: #6366f1;
  color: white;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1.0625rem;
  text-decoration: none;
  transition: background 0.2s;
}

.btn-cta-large:hover {
  background: #4f46e5;
}

/* ── Lightbox ── */

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.lightbox[hidden] {
  display: none;
}

.lightbox img {
  max-width: 90vw;
  max-height: 80vh;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
  user-select: none;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: white;
  font-size: 2.5rem;
  cursor: pointer;
  line-height: 1;
  padding: 0.5rem;
  z-index: 10;
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: white;
  font-size: 3rem;
  cursor: pointer;
  padding: 1rem 1.25rem;
  border-radius: 50%;
  line-height: 1;
  transition: background 0.2s;
  z-index: 10;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.3);
}

.lightbox-prev {
  left: 1.5rem;
}

.lightbox-next {
  right: 1.5rem;
}

.lightbox-caption {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 1rem;
  align-items: center;
  color: white;
  font-size: 0.9375rem;
  background: rgba(0, 0, 0, 0.6);
  padding: 0.625rem 1.25rem;
  border-radius: 8px;
}

#lightbox-title {
  font-weight: 600;
}

#lightbox-counter {
  opacity: 0.7;
  font-size: 0.8125rem;
}

/* ── Mobile ── */

@media (max-width: 768px) {
  .tour-hero h1 {
    font-size: 1.75rem;
  }

  .filter-bar {
    flex-direction: column;
    gap: 0.75rem;
  }

  .search-input {
    min-width: unset;
    width: 100%;
  }

  .filter-group {
    width: 100%;
  }

  .filter-group select {
    width: 100%;
  }

  .screenshot-grid {
    grid-template-columns: 1fr;
  }

  .screenshot-card img {
    height: 180px;
  }
}

@media (max-width: 480px) {
  .tour-page {
    padding: 1rem;
  }

  .tour-hero {
    padding: 2rem 0 1rem;
  }

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

  .tour-cta h2 {
    font-size: 1.375rem;
  }

  .btn-cta-large {
    padding: 0.875rem 2rem;
    font-size: 1rem;
    width: 100%;
    text-align: center;
  }
}
