:root {
  --bg: #121315;
  --ink: #e8e6e1;
  --warm: #d9b48f;
  --muted: rgba(232, 230, 225, 0.65);
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter Tight', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'IBM Plex Mono', Menlo, monospace;
  --gutter: clamp(24px, 4vw, 56px);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 100%; height: 100%; background: var(--bg); color: var(--ink); font-family: var(--sans); }
body { overflow-x: hidden; -webkit-font-smoothing: antialiased; }

#gl { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 1; pointer-events: none; }

#still {
  position: fixed; inset: 0; z-index: 2; pointer-events: none; opacity: 0;
  transition: opacity 0.5s ease-out; overflow: hidden;
}
#still.is-on { opacity: 0; display: none !important; }
#still img {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 100vw; height: 100vh; object-fit: cover;
}
#still::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 46%;
  background: linear-gradient(to top, rgba(14, 15, 18, 0.65), rgba(14, 15, 18, 0.15) 50%, transparent);
}

.brand {
  position: fixed; top: var(--gutter); left: var(--gutter); z-index: 10;
  pointer-events: none;
}
.brand__name {
  font-family: var(--serif); font-size: clamp(26px, 3.2vw, 42px);
  font-weight: 400; letter-spacing: 0.02em; line-height: 1.1;
}
.brand__sub {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--muted); margin-top: 6px;
}

.sheet {
  position: fixed; top: var(--gutter); right: var(--gutter); z-index: 10;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em;
  background: rgba(18, 19, 21, 0.65); backdrop-filter: blur(12px);
  padding: 16px 20px; border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 4px;
}
.sheet__rows div { display: flex; justify-content: space-between; gap: 24px; padding: 3px 0; }
.sheet__rows dt { color: var(--muted); text-transform: uppercase; font-size: 9.5px; }
.sheet__rows dd { color: var(--ink); font-weight: 500; }

.stops {
  position: fixed; right: var(--gutter); top: 50%; transform: translateY(-50%);
  z-index: 30; pointer-events: none;
}
.stops li {
  pointer-events: auto;
  cursor: pointer;
}
.stops ol { list-style: none; display: flex; flex-direction: column; gap: 14px; text-align: right; }
.stops li {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.16em;
  text-transform: uppercase; color: rgba(255, 255, 255, 0.35); transition: color 0.3s;
}
.stops li.is-active { color: var(--warm); font-weight: 500; }
.stops li.is-active::after { content: " —"; }

.caption {
  position: fixed; left: var(--gutter); bottom: var(--gutter); z-index: 10;
  max-width: min(540px, 86vw); pointer-events: none; opacity: 0;
  transform: translateY(14px); transition: opacity 0.4s ease, transform 0.4s ease;
}
body.is-caption-1 .caption--1,
body.is-caption-2 .caption--2,
body.is-caption-3 .caption--3,
body.is-caption-4 .caption--4,
body.is-caption-5 .caption--5,
body.is-caption-6 .caption--6 {
  opacity: 1; transform: translateY(0);
}
.caption__num {
  display: block; font-family: var(--mono); font-size: 11px;
  letter-spacing: 0.18em; color: var(--warm); margin-bottom: 6px;
}
.caption__title {
  font-family: var(--serif); font-size: clamp(32px, 4.2vw, 56px);
  font-weight: 400; line-height: 1.05; margin-bottom: 8px;
}
.caption__meta {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 12px;
}
.caption__desc {
  font-size: 14px; line-height: 1.55; color: rgba(232, 230, 225, 0.85);
  font-weight: 400;
}

#loader {
  position: fixed; inset: 0; z-index: 100; background: var(--bg);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s;
}
#loader.is-done { opacity: 0; visibility: hidden; pointer-events: none; }
.loader__line { width: 180px; height: 1.5px; background: rgba(255, 255, 255, 0.12); overflow: hidden; margin-bottom: 18px; }
.loader__line i { display: block; width: 0%; height: 100%; background: var(--warm); transition: width 0.2s; }
.loader__text { font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }

#scroll { height: 900vh; position: relative; z-index: 0; }


/* Lenis smooth scrolling rules */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }
.lenis.lenis-smooth iframe { pointer-events: none; }

.caption.is-active {
  opacity: 1;
  transform: translateY(0);
}
