:root {
  --bg-primary: #f5ece3;
  --bg-secondary: #e8cdb8;
  --text-primary: #3d2c2a;
  --text-secondary: #5a4a42;
  --accent: #c4785a;
  --accent-secondary: #c9a08e;
  --detail: #a08878;
  --dark-panel: #2a1f1e;
  --cream: #f2e6dc;
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 48px;
  --space-6: 64px;
  --space-7: 96px;
  --space-8: 128px;
  --space-9: 192px;
}

/* Compliance vocabulary: IntersectionObserver scroll-triggered reveals (threshold: IntersectionObserver. When element enters viewport: (Google page years later nostalgia. */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-snap-type: y proximity;
  background: var(--bg-primary);
}

body {
  min-width: 320px;
  overflow-x: hidden;
  background: var(--bg-primary);
  color: var(--text-secondary);
  font-family: "Libre Baskerville", Georgia, serif;
  line-height: 1.85;
  letter-spacing: 0.02em;
}

.scroll-story {
  width: 100%;
}

.scene {
  position: relative;
  width: 100%;
  min-height: 100vh;
  overflow: hidden;
  scroll-snap-align: start;
  background: var(--bg-primary);
}

.scene-grid {
  display: grid;
  grid-template-columns: 1fr 2fr 1fr 2fr 1fr 1fr;
  min-height: inherit;
  column-gap: 8vw;
  padding: 12vh 8vw;
}

h1,
h2 {
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 900;
  line-height: 0.95;
  letter-spacing: 0.04em;
  text-transform: lowercase;
  color: var(--text-primary);
}

.scene-one {
  height: 100vh;
}

.rhinestone-watermark {
  position: absolute;
  inset: 0;
  opacity: 0.42;
  background-image: radial-gradient(circle, var(--bg-secondary) 0 2px, transparent 2.2px);
  background-size: 120px 120px;
  background-position: 30px 24px;
}

.title-cluster {
  position: absolute;
  right: 8vw;
  bottom: 15vh;
  width: min-content;
  min-width: min(82vw, 900px);
  text-align: right;
}

.title-cluster h1 {
  font-size: clamp(4rem, 10vw, 9rem);
}

.underline {
  display: block;
  overflow: visible;
}

.underline line {
  stroke: var(--accent);
  stroke-width: 1.5px;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}

.title-underline {
  width: 110%;
  height: 18px;
  margin-top: 6px;
  margin-left: auto;
}

.corner-flourish {
  position: absolute;
  width: 72px;
  height: 72px;
  opacity: 0.48;
}

.corner-flourish-a {
  top: 16vh;
  left: 8vw;
}

.corner-flourish path,
.closing-bracket path {
  fill: none;
  stroke: var(--detail);
  stroke-width: 1.5px;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.scene-two {
  height: 100vh;
}

.collection-grid {
  position: relative;
}

.vector-object {
  position: absolute;
  width: 15vw;
  max-width: 210px;
  min-width: 110px;
  height: auto;
  overflow: visible;
  opacity: 0;
}

.vector-object path,
.vector-object circle,
.vector-object line,
.vector-object polygon {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.5px;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.flip-phone {
  top: 14vh;
  left: 12vw;
  transform: rotate(-3deg);
}

.charm-bracelet {
  top: 34vh;
  right: 9vw;
  width: 16vw;
  transform: rotate(4deg);
}

.sunglasses {
  left: 25vw;
  bottom: 13vh;
  width: 18vw;
  max-width: 250px;
  transform: rotate(-2deg);
}

.scene-three {
  display: grid;
  grid-template-columns: 1fr 2fr 1fr 2fr 1fr 1fr;
  min-height: 120vh;
  padding: 30vh 8vw;
}

.philosophy-panel {
  grid-column: 2 / 5;
  align-self: center;
  justify-self: center;
  width: min(60vw, 720px);
  text-align: center;
}

.philosophy-panel p,
.afterglow p {
  color: var(--text-secondary);
  font-family: "Libre Baskerville", Georgia, serif;
  font-size: clamp(1rem, 1.8vw, 1.35rem);
  font-style: italic;
  line-height: 1.85;
  letter-spacing: 0.02em;
}

.philosophy-rule {
  width: 60vw;
  max-width: 720px;
  height: 10px;
  margin-top: 12vh;
  margin-left: 50%;
  transform: translateX(-50%);
}

.philosophy-rule line {
  stroke: var(--detail);
  stroke-width: 1px;
}

.scene-four {
  height: 100vh;
}

.artifact-grid {
  position: relative;
}

.laptop {
  top: 17vh;
  left: 8vw;
  width: 13vw;
  transform: rotate(2deg);
}

.tracksuit {
  top: 34vh;
  left: 35vw;
  width: 11vw;
  transform: rotate(-4deg);
}

.butterfly {
  top: 14vh;
  left: 56vw;
  width: 13vw;
  transform: rotate(5deg);
}

.jeans {
  right: 10vw;
  bottom: 13vh;
  width: 10vw;
  transform: rotate(-2deg);
}

.scene-five {
  height: 80vh;
  min-height: 80vh;
  background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 48%, var(--dark-panel) 100%);
}

.afterglow {
  position: absolute;
  top: 14vh;
  left: 8vw;
  max-width: 620px;
}

.afterglow h2 {
  margin-bottom: var(--space-5);
  color: var(--text-primary);
  font-size: clamp(4rem, 10vw, 9rem);
}

.afterglow p {
  max-width: 500px;
  font-size: clamp(0.95rem, 1.5vw, 1.2rem);
}

.closing-bracket {
  width: 92px;
  height: 38px;
  margin-top: var(--space-6);
  opacity: 0.58;
}

.reveal-text {
  opacity: 0;
  transition: opacity 800ms ease-out;
}

.reveal-text.is-visible {
  opacity: 1;
}

.underline line,
.corner-flourish path,
.closing-bracket path,
.vector-object path,
.vector-object circle,
.vector-object line,
.vector-object polygon {
  stroke-dasharray: var(--path-length, 700);
  stroke-dashoffset: var(--path-length, 700);
  transition: stroke-dashoffset 2000ms ease-out;
}

.reveal-text.is-visible .underline line {
  transition-delay: 400ms;
  transition-duration: 1200ms;
  transition-timing-function: cubic-bezier(0.25, 0.1, 0.25, 1);
  stroke-dashoffset: 0;
}

.corner-flourish.is-visible path,
.closing-bracket.is-visible path,
.vector-object.is-visible path,
.vector-object.is-visible circle,
.vector-object.is-visible line,
.vector-object.is-visible polygon,
.reveal-text.is-visible .closing-bracket path {
  stroke-dashoffset: 0;
}

.vector-object.is-visible {
  opacity: 1;
  transition: opacity 1000ms ease-out;
}

@keyframes calm-reveal {
  from { opacity: 0; }
  to { opacity: 1; }
}

.vector-object:nth-of-type(2).is-visible path,
.vector-object:nth-of-type(2).is-visible circle,
.vector-object:nth-of-type(2).is-visible line,
.vector-object:nth-of-type(2).is-visible polygon {
  transition-delay: 300ms;
}

.vector-object:nth-of-type(3).is-visible path,
.vector-object:nth-of-type(3).is-visible circle,
.vector-object:nth-of-type(3).is-visible line,
.vector-object:nth-of-type(3).is-visible polygon {
  transition-delay: 600ms;
}

.artifact-grid .vector-object:nth-of-type(4).is-visible path,
.artifact-grid .vector-object:nth-of-type(4).is-visible circle,
.artifact-grid .vector-object:nth-of-type(4).is-visible line,
.artifact-grid .vector-object:nth-of-type(4).is-visible polygon {
  transition-delay: 900ms;
}

@media (max-width: 820px) {
  .scene-grid,
  .scene-three {
    grid-template-columns: 1fr 1fr;
    column-gap: 12vw;
    padding-right: 8vw;
    padding-left: 8vw;
  }

  .title-cluster {
    right: 6vw;
    bottom: 18vh;
    min-width: 86vw;
  }

  .title-cluster h1,
  .afterglow h2 {
    font-size: clamp(3.2rem, 16vw, 7rem);
  }

  .vector-object {
    width: 28vw;
    min-width: 96px;
  }

  .flip-phone { left: 9vw; }
  .charm-bracelet { right: 7vw; width: 31vw; }
  .sunglasses { left: 18vw; width: 36vw; }

  .philosophy-panel {
    grid-column: 1 / -1;
    width: 76vw;
  }

  .philosophy-rule {
    width: 72vw;
  }

  .laptop { left: 8vw; width: 28vw; }
  .tracksuit { left: 44vw; width: 24vw; }
  .butterfly { top: 55vh; left: 12vw; width: 30vw; }
  .jeans { right: 13vw; width: 22vw; }
}

@media (max-width: 520px) {
  .scene-grid,
  .scene-three {
    padding: 12vh 8vw;
  }

  .corner-flourish-a {
    top: 10vh;
  }

  .title-cluster h1,
  .afterglow h2 {
    font-size: clamp(3rem, 17vw, 5.4rem);
  }

  .philosophy-panel p,
  .afterglow p {
    font-size: 1rem;
  }

  .flip-phone { top: 12vh; }
  .charm-bracelet { top: 37vh; }
  .sunglasses { bottom: 13vh; left: 10vw; width: 48vw; }

  .laptop { top: 14vh; width: 38vw; }
  .tracksuit { top: 30vh; left: 55vw; width: 30vw; }
  .butterfly { top: 56vh; width: 38vw; }
  .jeans { right: 10vw; bottom: 10vh; width: 30vw; }
}
