:root {
  --bg: #0b1120;
  --bg-alt: #0f172a;
  --text: #e2e8f0;
  --muted: #94a3b8;
  --accent: #7dd3fc;
  --accent-2: #c084fc;
  --border: rgba(148, 163, 184, 0.18);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, Helvetica, Arial, sans-serif;
  overflow-x: hidden;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

a {
  color: inherit;
}

ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

button {
  font: inherit;
  color: inherit;
}

/* ---------- loading screen ---------- */
#loading-screen {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  background: var(--bg);
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

#loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-ring {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  animation: spin 0.9s linear infinite;
}

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

#loading-screen p {
  color: var(--muted);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
}

/* ---------- nav ---------- */
.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem clamp(1.25rem, 4vw, 3rem);
  background: transparent;
  transition: background 0.4s ease, border-color 0.4s ease;
  border-bottom: 1px solid transparent;
}

.site-nav.scrolled {
  background: rgba(11, 17, 32, 0.78);
  backdrop-filter: blur(10px);
  border-bottom-color: var(--border);
}

.site-nav .brand {
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  font-size: 1rem;
}

.site-nav .brand span {
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nav-links {
  display: flex;
  gap: clamp(1rem, 3vw, 2rem);
}

.nav-links a {
  text-decoration: none;
  font-size: 0.88rem;
  color: var(--muted);
  transition: color 0.25s ease;
}

.nav-links a:hover {
  color: var(--text);
}

/* ---------- pinned sections ---------- */
.pin-section {
  position: relative;
  height: 220vh;
}

.pin-stage {
  position: sticky;
  top: 0;
  height: 100vh;
  width: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.4s ease;
}

.pin-stage canvas {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  outline: none;
}

/* ---------- hero ---------- */
.hero-overlay {
  position: relative;
  z-index: 2;
  text-align: center;
  pointer-events: none;
  padding-top: 8vh;
}

.eyebrow {
  margin: 0 0 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.72rem;
  color: var(--muted);
}

.hero-overlay h1 {
  margin: 0;
  font-size: clamp(2.4rem, 7vw, 4.5rem);
  font-weight: 700;
  background: linear-gradient(120deg, #f8fafc, var(--accent) 60%, var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-overlay .tagline {
  margin: 0.75rem auto 0;
  max-width: 32rem;
  color: var(--muted);
  font-size: clamp(0.95rem, 2vw, 1.1rem);
}

.scroll-cue {
  position: absolute;
  bottom: 6vh;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  color: var(--muted);
  text-transform: uppercase;
}

.scroll-cue .dot-track {
  width: 1.5px;
  height: 34px;
  background: var(--border);
  position: relative;
  overflow: hidden;
}

.scroll-cue .dot-track::after {
  content: "";
  position: absolute;
  top: -40%;
  left: 0;
  width: 100%;
  height: 40%;
  background: linear-gradient(var(--accent), transparent);
  animation: scroll-cue-move 1.8s ease-in-out infinite;
}

@keyframes scroll-cue-move {
  0% {
    top: -40%;
  }
  100% {
    top: 100%;
  }
}

/* ---------- map section ---------- */
.map-wrap {
  position: absolute;
  inset: 0;
  transform-origin: center center;
  transition: transform 0.15s ease-out;
}

#ph-map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: var(--bg);
  cursor: grab;
}

#ph-map:active {
  cursor: grabbing;
}

.map-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 9vh 1.5rem 0;
  text-align: center;
}

.map-overlay h2 {
  margin: 0;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
}

.section-hint {
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.dest-list {
  position: absolute;
  bottom: 4.5vh;
  left: 0;
  right: 0;
  z-index: 3;
  display: flex;
  gap: 0.6rem;
  padding: 0 1.5rem 0.5rem;
  overflow-x: auto;
  pointer-events: auto;
  justify-content: flex-start;
  scrollbar-width: thin;
}

@media (min-width: 720px) {
  .dest-list {
    justify-content: center;
  }
}

.dest-list li {
  flex: 0 0 auto;
}

.dest-chip {
  display: block;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(15, 23, 42, 0.6);
  color: var(--muted);
  font-size: 0.78rem;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}

.dest-chip:hover,
.dest-chip.active {
  color: var(--text);
  border-color: var(--accent);
  background: rgba(125, 211, 252, 0.1);
}

/* Google Maps InfoWindow content (the wrapper markup we control) */
.gmap-popup strong {
  display: block;
  font-size: 0.95rem;
  color: var(--text);
}

.map-popup-region {
  display: block;
  color: var(--accent);
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  margin-top: 0.1rem;
}

.gmap-popup p {
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.4;
}

/* Google Maps InfoWindow chrome — these are Google's internal class names
   (not a documented public API), so this is a best-effort dark theme. */
.gm-style-iw-c {
  background: rgba(15, 23, 42, 0.97) !important;
  border-radius: 12px !important;
  padding: 0.9rem 1rem !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4) !important;
}

.gm-style-iw-d {
  overflow: auto !important;
}

.gm-style-iw-t::after {
  background: rgba(15, 23, 42, 0.97) !important;
}

.gm-ui-hover-effect {
  filter: invert(1);
}

/* ---------- reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- footer ---------- */
footer.site-footer {
  position: relative;
  z-index: 2;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 3.5rem 1.5rem 2.5rem;
  text-align: center;
}

.site-footer h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.4rem, 3.5vw, 2rem);
}

.site-footer p {
  margin: 0 auto 1.5rem;
  max-width: 28rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.footer-links a {
  text-decoration: none;
  font-size: 0.85rem;
  color: var(--muted);
  border: 1px solid var(--border);
  padding: 0.5rem 1rem;
  border-radius: 999px;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.footer-links a:hover {
  color: var(--text);
  border-color: var(--accent);
}

.site-footer .fine-print {
  color: #64748b;
  font-size: 0.75rem;
}

@media (max-width: 640px) {
  .pin-section {
    height: 240vh;
  }
}
