/* map-style.css — Destination Experience: fullscreen cinematic showcase
   (replaces the former Three.js 3D map). Namespaced .dx-* throughout so it
   never collides with legacy .dest-* rules still sitting in style.css. */

.dx {
  --dx-header-h: 0px;
  position: relative;
  width: 100%;
  height: 90vh;
  min-height: 640px;
  overflow: hidden;
  background: #FCFBF8;
  isolation: isolate;
}

.dx-stage {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
}

/* ===================================================================
   LEFT — Destination navigation panel (glassmorphism, ~25%)
=================================================================== */
.dx-nav {
  position: relative;
  z-index: 5;
  flex: 0 0 clamp(280px, 25%, 380px);
  height: 100%;
  padding: 50px;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.88));
  backdrop-filter: var(--xp-blur, blur(20px)) saturate(1.4);
  -webkit-backdrop-filter: var(--xp-blur, blur(20px)) saturate(1.4);
  border-right: 1px solid rgba(22, 33, 43, 0.1);
  overflow-y: auto;
  scrollbar-width: none;
}

.dx-nav::-webkit-scrollbar {
  display: none;
}

.dx-nav__heading {
  position: relative;
  font-family: var(--xp-font-display, 'Fraunces', serif);
  font-weight: 400;
  font-size: clamp(1.5rem, 1.8vw, 1.95rem);
  letter-spacing: 0.02em;
  color: #16212B;
  margin: 0 0 2.1rem;
  padding-left: 0.9rem;
}

.dx-nav__heading::after {
  content: '';
  position: absolute;
  left: 0.9rem;
  bottom: -0.8rem;
  width: 30px;
  height: 2px;
  background: var(--xp-orange, #e67e22);
}

.dx-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.dx-nav__item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.85rem 0.9rem;
  border-radius: var(--xp-radius-md, 14px);
  cursor: pointer;
  color: rgba(22, 33, 43, 0.55);
  transition: background 0.5s var(--xp-ease, ease), color 0.5s var(--xp-ease, ease);
}

.dx-nav__item:hover {
  background: rgba(230, 126, 34, 0.08);
  color: rgba(22, 33, 43, 0.85);
}

.dx-nav__item:focus-visible {
  outline: 1px solid rgba(217, 108, 18, 0.5);
  outline-offset: 2px;
}

.dx-nav__item.is-active {
  background: linear-gradient(90deg, rgba(230, 126, 34, 0.2), rgba(230, 126, 34, 0.04));
  color: #D96C12;
  box-shadow: inset 0 0 0 1px rgba(230, 126, 34, 0.22);
}

.dx-nav__item.is-active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 14%;
  bottom: 14%;
  width: 3px;
  border-radius: 2px;
  background: var(--xp-orange, #e67e22);
  box-shadow: 0 0 14px rgba(230, 126, 34, 0.85);
}

.dx-nav__num {
  font-family: var(--xp-font-display, 'Fraunces', serif);
  font-size: 0.85rem;
  opacity: 0.55;
  min-width: 1.4rem;
  transition: opacity 0.4s var(--xp-ease, ease), color 0.4s var(--xp-ease, ease);
}

.dx-nav__item.is-active .dx-nav__num {
  opacity: 1;
  color: #D96C12;
}

.dx-nav__name {
  font-size: 0.96rem;
  font-weight: 500;
  letter-spacing: 0.01em;
}

/* ===================================================================
   RIGHT — Fullscreen cinematic showcase (~75%)
=================================================================== */
.dx-show {
  position: relative;
  flex: 1 1 auto;
  height: 100%;
  overflow: hidden;
  background: #FCFBF8;
}

.dx-show__images {
  position: absolute;
  inset: -3%;
  z-index: 0;
}

.dx-show__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  overflow: hidden;
}

.dx-show__slide.is-active {
  opacity: 1;
  z-index: 1;
}

.dx-show__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.02);
  transform-origin: 50% 50%;
  filter: brightness(1.04) saturate(1.06) contrast(1.02);
}

.dx-show__scrim {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.88) 0%, rgba(255, 255, 255, 0.64) 30%, rgba(255, 255, 255, 0.2) 56%, rgba(255, 255, 255, 0) 74%),
    linear-gradient(0deg, rgba(255, 255, 255, 0.76) 0%, rgba(255, 255, 255, 0) 26%);
}

/* ---- Content overlay ---- */
.dx-show__content {
  position: absolute;
  z-index: 3;
  left: clamp(2rem, 5vw, 4.5rem);
  right: clamp(2rem, 8vw, 8rem);
  top: 50%;
  transform: translateY(-50%);
  max-width: 560px;
  color: #16212B;
  font-family: var(--xp-font-body, 'Inter', sans-serif);
}

.dx-show__index {
  display: block;
  font-family: var(--xp-font-display, 'Fraunces', serif);
  font-size: 0.95rem;
  letter-spacing: 0.4em;
  color: #D96C12;
  opacity: 0.95;
  margin: 0 0 1.1rem;
}

.dx-show__name {
  font-family: var(--xp-font-display, 'Fraunces', serif);
  font-weight: 400;
  font-size: clamp(2.6rem, 4.6vw, 4.2rem);
  line-height: 1.06;
  margin: 0 0 1rem;
  color: #16212B;
}

.dx-show__tag {
  font-size: 0.76rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: #D96C12;
  margin: 0 0 1.5rem;
}

.dx-show__copy {
  font-size: 1.02rem;
  line-height: 1.72;
  color: rgba(22, 33, 43, 0.72);
  max-width: 460px;
  margin: 0 0 2.1rem;
}

.dx-show__stats {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(1.5rem, 3vw, 2.6rem);
  margin-bottom: 2.4rem;
}

.dx-show__stat b {
  display: block;
  font-family: var(--xp-font-display, 'Fraunces', serif);
  font-weight: 400;
  font-size: clamp(1.4rem, 2.2vw, 1.9rem);
  color: #16212B;
}

.dx-show__stat span {
  font-size: 0.64rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: rgba(217, 108, 18, 0.85);
}

.dx-show__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 1rem 1.9rem;
  background: var(--xp-orange, #e67e22);
  color: #fff;
  border-radius: var(--xp-radius-pill, 999px);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  box-shadow: 0 12px 30px rgba(230, 126, 34, 0.35);
  transition: background 0.35s var(--xp-ease, ease), transform 0.35s var(--xp-ease, ease), box-shadow 0.35s var(--xp-ease, ease);
}

.dx-show__cta:hover {
  background: var(--xp-orange-hover, #d96c12);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 16px 38px rgba(230, 126, 34, 0.45);
}

.dx-show__cta svg {
  width: 16px;
  height: 16px;
  transition: transform 0.35s var(--xp-ease, ease);
}

.dx-show__cta:hover svg {
  transform: translateX(4px);
}

/* ---- Bottom controls ---- */
.dx-controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.5rem clamp(1.5rem, 4vw, 3rem);
}

.dx-controls__progress {
  font-family: var(--xp-font-display, 'Fraunces', serif);
  font-size: 0.92rem;
  letter-spacing: 0.05em;
  color: rgba(22, 33, 43, 0.6);
  white-space: nowrap;
}

.dx-controls__progress b {
  color: #D96C12;
  font-weight: 400;
  font-size: 1.05rem;
}

.dx-controls__dots {
  display: flex;
  align-items: center;
  gap: 7px;
}

.dx-controls__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(22, 33, 43, 0.25);
  transition: background 0.35s var(--xp-ease, ease), width 0.35s var(--xp-ease, ease), border-radius 0.35s var(--xp-ease, ease);
}

.dx-controls__dot.is-active {
  background: #D96C12;
  width: 18px;
  border-radius: 3px;
}

.dx-controls__buttons {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.dx-controls__btn {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid rgba(22, 33, 43, 0.18);
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #16212B;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.3s var(--xp-ease, ease), border-color 0.3s var(--xp-ease, ease), transform 0.3s var(--xp-ease, ease);
}

.dx-controls__btn:hover {
  background: rgba(230, 126, 34, 0.14);
  border-color: rgba(217, 108, 18, 0.45);
  color: #D96C12;
  transform: translateY(-2px);
}

.dx-controls__btn svg {
  width: 17px;
  height: 17px;
}

.dx-controls__play {
  width: auto;
  padding: 0 1.15rem;
  border-radius: 999px;
  gap: 0.5rem;
  font-size: 0.76rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

/* Show the pause icon while playing, the play icon once paused */
.dx-controls__play .dx-icon-play {
  display: none;
}

.dx-controls__play.is-paused .dx-icon-pause {
  display: none;
}

.dx-controls__play.is-paused .dx-icon-play {
  display: block;
  transform: translateX(1px);
}

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

/* Laptop */
@media (max-width: 1280px) {
  .dx-show__content {
    max-width: 500px;
  }
}

/* Tablet landscape */
@media (max-width: 1024px) {
  .dx-nav {
    flex-basis: 250px;
    padding: 1.8rem 1rem 1.5rem;
  }

  .dx-nav__heading {
    font-size: 1.4rem;
  }

  .dx-nav__name {
    font-size: 0.88rem;
  }

  .dx-show__content {
    max-width: 440px;
    left: 2.2rem;
  }

  .dx-show__name {
    font-size: clamp(2.2rem, 4.2vw, 3.1rem);
  }

  .dx-show__copy {
    font-size: 0.94rem;
  }
}

/* Mobile: nav collapses into a horizontal strip over the fullscreen image */
@media (max-width: 680px) {

  /* Legacy #destination-experience height rules from style.css are ID-scoped
     (higher specificity than .dx); restore full-height here so they can't
     shrink the fullscreen showcase on small screens. */
  #destination-experience {
    height: 100vh;
    min-height: 720px;
  }

  .dx {
    min-height: 720px;
  }

  .dx-stage {
    flex-direction: column;
  }

  .dx-nav {
    position: absolute;
    z-index: 6;
    top: var(--dx-header-h);
    left: 0;
    width: 100%;
    height: auto;
    flex: 0 0 auto;
    flex-direction: row;
    padding: 1rem 0.9rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0));
    border-right: none;
    border-bottom: none;
    overflow-x: auto;
    overflow-y: hidden;
  }

  .dx-nav__heading {
    display: none;
  }

  .dx-nav__list {
    flex-direction: row;
    gap: 0.35rem;
  }

  .dx-nav__item {
    flex-shrink: 0;
    padding: 0.55rem 0.9rem;
  }

  .dx-nav__item.is-active::before {
    left: 10%;
    right: 10%;
    top: auto;
    bottom: 0;
    width: auto;
    height: 2px;
  }

  .dx-show {
    width: 100%;
    height: 100%;
  }

  .dx-show__content {
    left: 1.3rem;
    right: 1.3rem;
    top: auto;
    bottom: 6.8rem;
    transform: none;
    max-width: none;
  }

  .dx-show__stats {
    gap: 1.1rem;
    margin-bottom: 1.7rem;
  }

  .dx-controls {
    padding: 1rem 1.1rem;
    gap: 0.8rem;
  }

  .dx-controls__progress {
    font-size: 0.8rem;
  }
}

/* Small mobile */
@media (max-width: 480px) {
  .dx-show__index {
    font-size: 0.75rem;
    margin-bottom: 0.7rem;
  }

  .dx-show__name {
    font-size: clamp(1.9rem, 8vw, 2.4rem);
  }

  .dx-show__tag {
    margin-bottom: 1rem;
  }

  .dx-show__copy {
    display: none;
  }

  .dx-show__stats {
    gap: 0.9rem;
    margin-bottom: 1.4rem;
  }

  .dx-show__cta {
    padding: 0.85rem 1.5rem;
    font-size: 0.82rem;
  }

  .dx-controls__play span {
    display: none;
  }

  .dx-controls__play {
    padding: 0;
    width: 44px;
  }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .dx-show__slide img {
    transform: none !important;
  }
}