/* ============================================================
   Pépite Travel — V2 Spot Detail CSS
   Consistent with home-v2.css design language
   ============================================================ */

/* Override home-v2.css html overflow: hidden for scrollable spot pages */
html:has(body.v2-spot-body) { overflow: visible; overflow-y: auto; }

body.v2-spot-body {
  font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
  background: #f9f8f6;
  color: var(--v2-earth);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  overflow-y: auto;
  height: auto;
}

/* ── V2 Shell overrides for spot page ──────────────────── */
body.v2-spot-body .v2-shell {
  /* Use document scroll instead of fixed viewport on spot page */
  position: static;
  inset: auto;
  overflow: visible;
  display: block;
  flex-direction: column;
  padding-bottom: calc(var(--v2-bottomnav-h) + var(--v2-safe-bottom));
}

/* ── Top bar overrides for spot page ───────────────────── */
/* Top bar doesn't need to be transparent here — spot page has distinct content */
body.v2-spot-body .v2-topbar {
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* ── Spot content ──────────────────────────────────────── */
.v2-spot-content {
  min-height: 100vh;
}

/* ── Hero ───────────────────────────────────────────────── */
.v2-spot-hero {
  position: relative;
  height: 50vh;
  min-height: 300px;
  max-height: 480px;
  background-size: cover;
  background-position: center;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
}

/* WHY using ::before pseudo-element: CSS filter:blur on the hero itself would blur
   the overlay and text content too. Using a pseudo-element lets us blur only the image. */
.v2-spot-hero--blurred::before {
  content: '';
  position: absolute;
  inset: -10px; /* Extend beyond edges to prevent blur edge artifacts */
  background: inherit;
  background-size: cover;
  background-position: center;
  filter: blur(12px);
  -webkit-filter: blur(12px);
  z-index: 0;
}

.v2-spot-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,0.1) 0%,
    rgba(0,0,0,0.35) 40%,
    rgba(0,0,0,0.7) 100%
  );
  z-index: 1;
}

.v2-spot-hero-content {
  position: relative;
  z-index: 2;
  padding: 24px 20px 28px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.v2-spot-hero-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.v2-spot-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.v2-spot-badge--pepite { background: rgba(255,255,255,0.92); color: #BD6338; }
.v2-spot-badge--inco   { background: rgba(255,255,255,0.92); color: #3E5C76; }

.v2-spot-category {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  background: rgba(255,255,255,0.18);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 20px;
  font-size: 0.76rem;
  font-weight: 600;
  color: white;
  letter-spacing: 0.02em;
}

.v2-spot-name {
  font-size: clamp(1.5rem, 5vw, 2.2rem);
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.v2-spot-location {
  display: flex;
  align-items: center;
  gap: 4px;
  color: rgba(255,255,255,0.8);
  font-size: 0.88rem;
  font-weight: 500;
}

.v2-spot-tagline {
  color: rgba(255,255,255,0.85);
  font-size: 0.92rem;
  line-height: 1.5;
  margin-top: 4px;
}

/* ── Info strip ────────────────────────────────────────── */
.v2-spot-info-strip {
  display: flex;
  flex-direction: column;
  gap: 0;
  background: var(--v2-white);
  margin: 0;
  border-bottom: 1px solid var(--v2-border);
}

.v2-spot-info-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--v2-border);
  color: var(--v2-sage);
}
.v2-spot-info-item:last-child { border-bottom: none; }

.v2-spot-info-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(26,26,26,0.45);
  margin-bottom: 2px;
}

.v2-spot-info-value {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--v2-earth);
  line-height: 1.4;
}

/* ── Body sections ──────────────────────────────────────── */
.v2-spot-body {
  padding: 24px 20px;
}

.v2-spot-section {
  margin-bottom: 28px;
}

.v2-spot-section-label {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--v2-terracotta);
  margin-bottom: 6px;
}

.v2-spot-section-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--v2-earth);
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.v2-spot-section--highlight {
  background: var(--v2-white);
  border-radius: var(--v2-radius);
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.v2-spot-section-icon {
  font-size: 1.4rem;
  margin-bottom: 8px;
}

.v2-spot-prose {
  font-size: 0.95rem;
  line-height: 1.75;
  color: rgba(26,26,26,0.8);
}

.v2-spot-secret-code {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--v2-earth);
  color: var(--v2-terracotta);
  padding: 12px 16px;
  border-radius: var(--v2-radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 20px;
}
.v2-spot-secret-code-val {
  font-family: 'Courier New', monospace;
  font-size: 1.1rem;
  letter-spacing: 0.1em;
}

/* ── Photos carousel ──────────────────────────────────── */
.v2-spot-photos-wrap {
  padding: 20px;
  background: var(--v2-white);
  border-top: 1px solid var(--v2-border);
}

.v2-spot-photos-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.v2-spot-photos-header h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--v2-earth);
}
.v2-spot-photos-header span {
  font-size: 0.78rem;
  color: rgba(26,26,26,0.5);
  font-weight: 600;
}

.v2-spot-carousel {
  position: relative;
  border-radius: var(--v2-radius-sm);
  overflow: hidden;
  background: var(--v2-sand);
}

.v2-spot-slides {
  display: flex;
  transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.v2-spot-slide {
  flex-shrink: 0;
  width: 100%;
  height: 240px;
  background-size: cover;
  background-position: center;
}

.v2-spot-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  color: var(--v2-earth);
  transition: background 0.15s;
  z-index: 2;
}
.v2-spot-arrow:hover { background: var(--v2-white); }
.v2-spot-arrow--prev { left: 12px; }
.v2-spot-arrow--next { right: 12px; }

.v2-spot-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 2;
}
.v2-spot-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  border: none;
  cursor: pointer;
  transition: background 0.15s;
}
.v2-spot-dot.active { background: #fff; }

/* ── Map ───────────────────────────────────────────────── */
.v2-spot-map-wrap {
  padding: 20px;
  background: var(--v2-white);
  border-top: 1px solid var(--v2-border);
}

.v2-spot-map-header {
  margin-bottom: 12px;
}
.v2-spot-map-header h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--v2-earth);
  margin-bottom: 2px;
}
.v2-spot-map-header p {
  font-size: 0.82rem;
  color: rgba(26,26,26,0.55);
}

.v2-spot-map-container {
  height: 220px;
  border-radius: var(--v2-radius-sm);
  overflow: hidden;
  margin-bottom: 12px;
  z-index: 1;
}

.v2-spot-gmaps-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px;
  background: var(--v2-earth);
  color: #fff;
  border-radius: var(--v2-radius-sm);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  transition: background 0.15s;
}
.v2-spot-gmaps-btn:hover { background: #333; }

/* ── Locked state ──────────────────────────────────────── */
.v2-spot-locked {
  background: linear-gradient(135deg, var(--v2-earth) 0%, #2d3d2a 100%);
  color: #fff;
  padding: 40px 20px;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.v2-spot-locked-inner {
  max-width: 400px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.v2-spot-locked-icon {
  width: 80px; height: 80px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  display: flex; align-items: center; justify-content: center;
  color: var(--v2-terracotta);
  margin-bottom: 4px;
}

.v2-spot-locked h2 {
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
}

.v2-spot-locked-preview {
  color: rgba(255,255,255,0.7);
  font-size: 0.92rem;
  line-height: 1.5;
}

.v2-spot-unlock-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--v2-sage);
  color: #fff;
  text-decoration: none;
  padding: 14px 28px;
  border-radius: var(--v2-radius-sm);
  font-size: 0.95rem;
  font-weight: 700;
  transition: background 0.15s;
  width: 100%;
  justify-content: center;
}
.v2-spot-unlock-btn:hover { background: var(--v2-sage-light); }

.v2-spot-locked-preview-body {
  width: 100%;
  margin-top: 8px;
}

.v2-spot-locked-blur {
  background: rgba(255,255,255,0.06);
  border-radius: var(--v2-radius-sm);
  padding: 16px;
  margin-bottom: 16px;
}
.v2-spot-locked-blur strong {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.4);
  margin-bottom: 6px;
}
.v2-spot-locked-blur p {
  color: rgba(255,255,255,0.5);
  font-size: 0.88rem;
  line-height: 1.6;
  filter: blur(3px);
  user-select: none;
}

.v2-spot-locked-features {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
}
.v2-spot-locked-feature {
  display: flex;
  align-items: center;
  gap: 10px;
  color: rgba(255,255,255,0.6);
  font-size: 0.85rem;
  font-weight: 500;
}

/* ── Desktop: layout stays mobile (sidebar hidden for all widths) ── */
/* Sidebar is intentionally suppressed per owner request — mobile layout applies universally. */

/* ── Desktop sidebar nav (injected via JS) ── */
.v2-desktop-sidebar {
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 20px 16px;
  background: #f9f8f6;
  border-right: 1px solid var(--v2-border);
  width: 200px;
  flex-shrink: 0;
  overflow-y: auto;
}
.v2-sidebar-logo {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--v2-earth);
  text-decoration: none;
  margin-bottom: 16px;
  padding: 0 8px;
}
.v2-sidebar-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 500;
  color: rgba(26,26,26,0.7);
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
  width: 100%;
}
.v2-sidebar-link:hover { background: var(--v2-cream); color: var(--v2-earth); }
.v2-sidebar-link--active { background: var(--v2-cream); color: var(--v2-terracotta); font-weight: 700; }
.v2-sidebar-link--premium { color: var(--v2-terracotta); font-weight: 600; }

/* ── Map expand button ──────────────────────────── */
.v2-spot-map-expand-btn {
  position: absolute;
  bottom: 12px;
  right: 12px;
  z-index: 400;
  background: rgba(255,255,255,0.92);
  border: 1.5px solid rgba(0,0,0,0.12);
  border-radius: 8px;
  padding: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  color: #2a2420;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
  transition: box-shadow 0.15s;
}
.v2-spot-map-expand-btn:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.18);
}

/* ── Related spots ───────────────────────────────── */
.v2-spot-related {
  padding: 20px;
  background: var(--v2-white);
  border-top: 1px solid var(--v2-border);
}
.v2-spot-related-header {
  margin-bottom: 14px;
}
.v2-spot-related-header h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--v2-earth);
}
.v2-spot-related-scroll {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 8px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.v2-spot-related-scroll::-webkit-scrollbar { display: none; }

.v2-related-card {
  flex-shrink: 0;
  width: 160px;
  text-decoration: none;
  border-radius: var(--v2-radius-sm);
  overflow: hidden;
  background: var(--v2-cream);
  display: block;
}
.v2-related-card-img {
  position: relative;
  height: 100px;
  background-size: cover;
  background-position: center;
  background-color: var(--v2-sand);
}
.v2-related-card-img .v2-spot-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  font-size: 0.65rem;
  padding: 2px 8px;
}
.v2-related-lock-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.7);
  z-index: 2;
}

/* Blur the image behind the lock overlay for hidden gems in related spots */
.v2-related-card--locked .v2-related-card-img {
  overflow: hidden;
}
.v2-related-card--locked .v2-related-card-img::before {
  content: '';
  position: absolute;
  inset: -4px;
  background: inherit;
  background-size: cover;
  background-position: center;
  filter: blur(3px);
  -webkit-filter: blur(3px);
  z-index: 1;
}
.v2-related-card-body {
  padding: 10px;
}
.v2-related-card-body strong {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--v2-earth);
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.v2-related-card-body span {
  font-size: 0.72rem;
  color: rgba(26,26,26,0.5);
  font-weight: 500;
}

/* ── Map expand modal ─────────────────────────────── */
.v2-spot-modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 10000;
  background: rgba(0,0,0,0.5);
  border: none;
  cursor: pointer;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

/* ── Desktop sidebar active link ──────────────────── */
.v2-sidebar-link--active {
  background: var(--v2-cream);
  color: var(--v2-terracotta);
  font-weight: 700;
}

/* ── Topbar heart button (spot page) ──────────────── */
.v2-heart-btn--topbar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: transparent;
  cursor: pointer;
  color: rgba(26,26,26,0.5);
  transition: color 0.15s, background 0.15s;
  padding: 0;
}
.v2-heart-btn--topbar:hover { background: var(--v2-cream); color: var(--v2-terracotta); }
.v2-heart-btn--topbar.active { color: #e53e3e; }
.v2-heart-btn--topbar.active .v2-heart-icon { fill: #e53e3e; stroke: #e53e3e; }

/* Override spot-map-wrap to be just the Google Maps btn */
.v2-spot-map-wrap {
  padding: 16px 20px;
}

/* WHY removed: task requires ZERO floating — blur only for locked cards */

/* ── Spot page bottom nav — no underline on tabs ──────────── */
/* WHY: spot page uses <a> tags for bottom nav (not <button>),
   so we need to explicitly remove text-decoration and the ::before indicator */
body.v2-spot-body .v2-bottomnav .v2-tab {
  text-decoration: none;
}
body.v2-spot-body .v2-bottomnav .v2-tab::before {
  display: none;
}
body.v2-spot-body .v2-bottomnav .v2-tab .v2-tab-label {
  text-decoration: none;
}

/* ── Social sharing bar (hero top overlay) ────────────── */
.v2-share-bar {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 10px 16px;
  background: linear-gradient(to bottom, rgba(0,0,0,0.35) 0%, transparent 100%);
  pointer-events: none;
}
.v2-share-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255,255,255,0.8);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  pointer-events: none;
}
.v2-share-icons {
  display: flex;
  align-items: center;
  gap: 12px;
  pointer-events: auto;
}
.v2-share-btn {
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
  color: rgba(255,255,255,0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s, transform 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.v2-share-btn:hover, .v2-share-btn:active {
  color: #fff;
  transform: scale(1.15);
}
.v2-share-btn svg {
  width: 22px; height: 22px;
}
/* Copied feedback toast */
.v2-share-toast {
  position: fixed;
  bottom: 80px; left: 50%;
  transform: translateX(-50%);
  background: #2a2420;
  color: #fff;
  padding: 8px 18px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 600;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}
.v2-share-toast.visible { opacity: 1; }
@media (max-width: 600px) {
  .v2-share-btn svg { width: 20px; height: 20px; }
  .v2-share-icons { gap: 10px; }
  .v2-share-bar { padding: 8px 12px; }
}