:root {
  --cream: #F3ECDD;
  --cream-2: #EDE6D6;
  --ink: #1A1612;
  --ink-soft: #3A332C;
  --gold: #B08A4A;
  --gold-bright: #C9A45C;
  --vine: #2F3A28;
  --cellar: #140E0A;
  --navy: #22344A;
  --opt-cream: #EDE6D6;
  --glass: rgba(243, 236, 221, 0.12);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --serif: "Fraunces", "Times New Roman", serif;
  --sans: "Source Sans 3", "Helvetica Neue", sans-serif;
  --archivo: "Archivo", "Helvetica Neue", sans-serif;
  --schibsted: "Schibsted Grotesk", "Helvetica Neue", sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { background: var(--ink); color: var(--cream); }
body {
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.45;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: -0.02em; line-height: 1.05; }

.preloader {
  position: fixed; inset: 0; z-index: 80;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 28px; background: #0E0C0A; transition: opacity 0.7s var(--ease), visibility 0.7s;
}
.preloader.is-done { opacity: 0; visibility: hidden; pointer-events: none; }
.preloader-mark {
  font-family: var(--serif); font-size: 28px; font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase;
}
.preloader-bar { width: 120px; height: 1px; background: rgba(243,236,221,0.18); }
.preloader-bar span { display: block; height: 100%; width: 0; background: var(--gold-bright); }

.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 40;
  display: flex; justify-content: space-between; align-items: center;
  padding: 22px 36px;
  pointer-events: none;
  transition: opacity 0.45s var(--ease), color 0.35s ease;
}
.nav a { pointer-events: auto; }
.nav-mark {
  font-family: var(--serif); font-size: 15px; font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase;
}
.nav-links { display: flex; gap: 28px; font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; font-weight: 500; }
.nav.is-ink { color: var(--ink); }
.nav.is-hidden { opacity: 0; pointer-events: none; }

.hero { height: 240vh; position: relative; }
.hero-sticky, .pour-sticky, .map-sticky, .wines-sticky, .end-sticky {
  position: sticky; top: 0; height: 100svh; width: 100%; overflow: hidden;
}
.hero-sticky canvas, .pour-sticky canvas {
  position: absolute; inset: 0; width: 100%; height: 100%; display: block;
}
.hero-veil {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(14,12,10,0.28) 0%, rgba(14,12,10,0.08) 36%, rgba(14,12,10,0.15) 70%, rgba(14,12,10,0.55) 100%);
  pointer-events: none;
}
.hero-copy {
  position: absolute; left: 36px; bottom: 14vh; max-width: 18em;
  transition: opacity 0.2s linear, transform 0.2s linear;
}
.eyebrow, .chapter-label {
  font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase;
  font-weight: 600; margin-bottom: 14px; color: var(--cream-2);
}
.chapter-label.ink { color: var(--ink-soft); }
.hero-copy h1 { font-size: clamp(56px, 8vw, 112px); font-optical-sizing: auto; }
.lede { margin-top: 14px; font-size: 18px; max-width: 22em; color: var(--cream-2); }
.chapter {
  position: absolute; left: 36px; bottom: 8vh;
  font-family: var(--serif); font-size: clamp(28px, 3.4vw, 44px);
  min-height: 1.2em; opacity: 0;
}
.progress {
  position: absolute; left: 36px; right: 36px; bottom: 28px; height: 1px;
  background: rgba(243,236,221,0.22);
}
.progress span { display: block; height: 100%; width: 0; background: var(--cream); transform-origin: 0 50%; }
.progress.light { background: rgba(243,236,221,0.14); }
.progress.ink { background: rgba(26,22,18,0.18); }
.progress.ink span { background: var(--ink); }

.pour { height: 200vh; position: relative; background: var(--cellar); }
.pour-bg {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(20,14,10,0.35), rgba(20,14,10,0.55)),
    url("../media/stills/cellar.webp") center/cover no-repeat;
  filter: blur(10px) saturate(0.9);
  transform: scale(1.08);
}
.pour-copy {
  position: absolute; left: 36px; top: 18vh; max-width: 16em; z-index: 2;
}
.pour-copy h2 { font-size: clamp(32px, 4vw, 56px); }
.specs { display: flex; gap: 18px; margin-top: 18px; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--cream-2); }
.specs span + span { border-left: 1px solid rgba(243,236,221,0.3); padding-left: 18px; }

.map { height: 200vh; position: relative; background: var(--cream); }
.map-photo, .map-wash, .map-svg {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
}
.map-wash {
  background: var(--cream);
  mix-blend-mode: normal;
  pointer-events: none;
}
.map-svg { z-index: 2; pointer-events: none; }
.map-stops { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.map-stop {
  position: absolute; transform: translate(-50%, -50%);
  display: flex; align-items: center; gap: 10px;
  opacity: 0;
}
.map-stop .dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--gold-bright);
  box-shadow: 0 0 0 5px rgba(201,164,92,0.28);
  flex: none;
}
.map-stop .meta { display: flex; flex-direction: column; gap: 2px; }
.map-stop .name { font-family: var(--serif); font-size: 18px; line-height: 1.1; }
.map-stop .walk { font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; }
.map-copy { position: absolute; left: 36px; top: 16vh; z-index: 4; max-width: 16em; }
.map-copy h2 { font-size: clamp(32px, 4vw, 56px); text-shadow: 0 2px 24px rgba(14,12,10,0.28); }
.map.is-light .map-copy, .map.is-light .map-stop { color: var(--ink); }
.map.is-dark .map-copy, .map.is-dark .map-stop { color: var(--cream); }

.wines { height: 180vh; position: relative; background: var(--cream); color: var(--ink); }
.wines-sticky { display: flex; flex-direction: column; justify-content: flex-end; padding: 0 36px 64px; background: var(--cream); }
.wines-copy { position: absolute; top: 14vh; left: 36px; max-width: 20em; }
.wines-copy h2 { font-size: clamp(32px, 4vw, 56px); }
.lede-ink { margin-top: 12px; font-size: 17px; color: var(--ink-soft); }
.wines-stage {
  display: flex; align-items: flex-end; justify-content: center;
  gap: 8px; height: 62vh; touch-action: pan-y;
  cursor: grab;
}
.wines-stage.is-dragging { cursor: grabbing; }
.bottle {
  flex: none; width: 240px; text-align: center;
  transform: translateX(var(--spread, 0px)) translateY(var(--lift, 0px));
  user-select: none;
}
.bottle h3 { font-size: 22px; margin-top: 26px; }
.bottle p { font-size: 14px; color: var(--ink-soft); margin-top: 6px; max-width: 16em; margin-left: auto; margin-right: auto; opacity: 0; min-height: 2.6em; }
.bottle.is-on p { opacity: 1; }
.bottle-3d {
  width: 96px; margin: 0 auto; position: relative;
  transform: rotate(var(--tilt, 0deg));
  transform-origin: 50% 100%;
  filter: drop-shadow(0 22px 20px rgba(26,22,18,0.2));
}
.foil { height: 26px; border-radius: 7px 7px 2px 2px; margin: 0 auto; width: 26px; position: relative; z-index: 2; }
.foil-gold { background: linear-gradient(180deg, #F0E0A8, #B08A3A 70%, #8A6420); }
.foil-rose { background: linear-gradient(180deg, #F0D0CC, #B87872); }
.foil-dark { background: linear-gradient(180deg, #4A3428, #1A100C 70%, #C9A45C); }
.neck { width: 24px; height: 58px; margin: -1px auto 0; position: relative; z-index: 1; }
.shoulder { width: 78px; height: 36px; margin: -6px auto 0; border-radius: 28px 28px 8px 8px; }
.body { width: 86px; min-height: 200px; margin: -8px auto 0; border-radius: 10px 10px 12px 12px / 6px 6px 18px 18px; position: relative; display: flex; align-items: center; justify-content: center; }
.punt { width: 76px; height: 12px; margin: -2px auto 0; border-radius: 0 0 40px 40px; background: rgba(0,0,0,0.16); }
.glass-chenin {
  background: linear-gradient(90deg, rgba(210,230,180,0.35), rgba(230,245,200,0.8) 40%, rgba(160,190,120,0.55) 70%, rgba(90,120,60,0.35));
  box-shadow: inset 8px 0 16px rgba(255,255,255,0.35), inset -10px 0 18px rgba(30,50,10,0.2);
}
.glass-rose {
  background: linear-gradient(90deg, rgba(230,180,180,0.35), rgba(255,220,220,0.75) 40%, rgba(200,120,130,0.5) 70%, rgba(120,50,60,0.3));
  box-shadow: inset 8px 0 16px rgba(255,255,255,0.35), inset -10px 0 18px rgba(80,20,30,0.18);
}
.glass-pinotage {
  background: linear-gradient(90deg, #2A1218, #5A1E28 36%, #1A0A0C 60%, #3A1016);
  box-shadow: inset 8px 0 14px rgba(255,255,255,0.12), inset -10px 0 16px rgba(0,0,0,0.45);
}
.neck.glass-chenin, .neck.glass-rose, .neck.glass-pinotage { border-radius: 3px; }
.label {
  width: 62px; background: #EFE6D2; color: var(--ink);
  padding: 10px 6px 8px; text-align: center;
  box-shadow: 0 1px 2px rgba(0,0,0,0.12);
}
.label-dark { background: #1A1612; color: var(--cream-2); }
.label-mark { display: block; font-family: var(--serif); font-size: 8px; letter-spacing: 0.14em; text-transform: uppercase; }
.label-wine { display: block; font-family: var(--serif); font-size: 10px; margin-top: 6px; }
.label-year { display: block; font-size: 8px; letter-spacing: 0.16em; margin-top: 6px; opacity: 0.7; }

.end { height: 160vh; position: relative; background: var(--navy); color: var(--opt-cream); }
.end-sticky {
  background: var(--navy);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.end-inner {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 0 36px;
  will-change: transform, opacity;
}
.end-lockup { width: min(420px, 56vw); height: auto; }
.end-rule {
  width: 48px; height: 1px; background: var(--gold-bright);
  margin: 36px 0 32px; transform-origin: 50% 50%;
}
.end-tag {
  font-family: var(--archivo);
  font-weight: 600;
  font-size: clamp(28px, 3.2vw, 42px);
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--opt-cream);
}
.end-line {
  font-family: var(--schibsted);
  font-weight: 400;
  font-size: clamp(15px, 1.3vw, 18px);
  margin-top: 18px;
  color: rgba(237,230,214,0.82);
  max-width: 22em;
}
.end-foot {
  position: absolute; bottom: 36px; left: 0; right: 0; text-align: center;
  font-family: var(--schibsted);
  font-size: 13px;
  letter-spacing: 0.08em;
  color: rgba(237,230,214,0.7);
}

@media (max-width: 700px) {
  .nav { padding: 16px 20px; }
  .nav-links { display: none; }
  .hero-copy, .chapter, .pour-copy, .map-copy, .wines-copy { left: 20px; right: 20px; }
  .hero { height: 200vh; }
  .pour, .map { height: 180vh; }
  .wines-stage { height: 58vh; }
  .bottle { width: 140px; }
  .end-lockup { width: min(280px, 78vw); }
}
@media (prefers-reduced-motion: reduce) {
  .hero, .pour, .map, .wines, .end { height: auto; }
  .hero-sticky, .pour-sticky, .map-sticky, .wines-sticky, .end-sticky { position: relative; height: auto; min-height: 100svh; }
}
