:root {
  /* compliance tokens: KR** interface labels Interprets Korean builds entire experience shore-to-shore */
  --deep-river-ink: #102A2C;
  --fog-paper: #EEF0E7;
  --reed-green: #65765A;
  --wet-wood-umber: #5A3F2D;
  --ticket-ochre: #D8B56D;
  --lantern-persimmon: #F26A3D;
  --rain-silver: #A8B7B1;
  --night-reflection-blue: #1B4251;
  --serif-kr: "Noto Serif KR", serif;
  --body-kr: "Gowun Batang", serif;
  --label-kr: "IBM Plex Sans KR", sans-serif;
  --hand-kr: "Nanum Pen Script", cursive;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--deep-river-ink);
}

body {
  margin: 0;
  color: var(--fog-paper);
  font-family: var(--body-kr);
  background:
    radial-gradient(circle at 20% 8%, rgba(238, 240, 231, 0.2), transparent 25rem),
    linear-gradient(180deg, #EEF0E7 0%, #A8B7B1 18%, #1B4251 54%, #102A2C 100%);
  overflow-x: hidden;
}

button { font: inherit; }

.crossing-shell {
  position: relative;
  min-height: 500vh;
  isolation: isolate;
}

.paper-grain {
  position: fixed;
  inset: 0;
  z-index: 12;
  pointer-events: none;
  opacity: 0.23;
  mix-blend-mode: multiply;
  background-image:
    repeating-radial-gradient(circle at 14% 19%, rgba(90, 63, 45, 0.16) 0 1px, transparent 1px 7px),
    repeating-linear-gradient(93deg, rgba(238, 240, 231, 0.08) 0 1px, transparent 1px 6px),
    linear-gradient(112deg, transparent, rgba(216, 181, 109, 0.07), transparent);
}

.river-band {
  position: fixed;
  left: -18vw;
  top: 39vh;
  width: 136vw;
  height: 30vh;
  z-index: 0;
  transform: rotate(-9deg) translate3d(0, 0, 0);
  border-top: 1px solid rgba(168, 183, 177, 0.28);
  border-bottom: 1px solid rgba(238, 240, 231, 0.14);
  background:
    linear-gradient(90deg, rgba(16, 42, 44, 0.92), rgba(27, 66, 81, 0.84), rgba(101, 118, 90, 0.38), rgba(16, 42, 44, 0.88)),
    radial-gradient(ellipse at 75% 50%, rgba(242, 106, 61, 0.08), transparent 22rem);
  box-shadow: 0 0 8rem rgba(16, 42, 44, 0.45);
  transition: transform 0.2s linear;
}

.river-current {
  position: absolute;
  left: 8%;
  right: 8%;
  height: 1px;
  border-radius: 50%;
  background: linear-gradient(90deg, transparent, rgba(238, 240, 231, 0.35), transparent 42%, rgba(168, 183, 177, 0.3), transparent);
  animation: currentDrift 13s linear infinite;
}

.current-one { top: 34%; }
.current-two { top: 62%; animation-duration: 17s; animation-delay: -5s; }

.tide-mark {
  position: absolute;
  width: 9rem;
  height: 2.6rem;
  border: 1px solid rgba(238, 240, 231, 0.25);
  border-left-color: transparent;
  border-right-color: transparent;
  border-radius: 50%;
  opacity: 0.7;
}

.tide-a { left: 18%; top: 18%; animation: ripple 8s ease-in-out infinite; }
.tide-b { left: 51%; top: 54%; animation: ripple 10s ease-in-out infinite -2s; }
.tide-c { right: 12%; top: 28%; animation: ripple 9s ease-in-out infinite -4s; }

.shore-markers {
  position: fixed;
  z-index: 20;
  right: 1.2rem;
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  gap: 0.55rem;
}

.marker {
  width: 6.9rem;
  padding: 0.42rem 0.55rem;
  border: 1px solid rgba(216, 181, 109, 0.28);
  border-radius: 999px;
  color: rgba(238, 240, 231, 0.72);
  background: rgba(16, 42, 44, 0.38);
  backdrop-filter: blur(7px);
  font-family: var(--label-kr);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 0.4s ease, color 0.4s ease, background 0.4s ease;
}

.marker span { color: var(--ticket-ochre); margin-right: 0.22rem; }
.marker.is-current { color: var(--fog-paper); border-color: var(--lantern-persimmon); background: rgba(27, 66, 81, 0.72); }

.shore-chapter {
  position: relative;
  min-height: 100vh;
  z-index: 1;
  overflow: hidden;
  padding: clamp(2rem, 5vw, 5rem);
}

.chapter-label {
  font-family: var(--label-kr);
  font-size: clamp(0.66rem, 1vw, 0.8rem);
  letter-spacing: 0.28em;
  color: var(--ticket-ochre);
  text-transform: uppercase;
}

h1, h2 {
  font-family: var(--serif-kr);
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.08;
  margin: 0;
}

h2 { font-size: clamp(2.25rem, 6.2vw, 7rem); }
p { font-size: clamp(1rem, 1.5vw, 1.35rem); line-height: 1.75; }

.fog-bank {
  display: grid;
  align-content: end;
  background:
    radial-gradient(circle at 15% 22%, rgba(238, 240, 231, 0.66), transparent 18rem),
    linear-gradient(180deg, rgba(238, 240, 231, 0.82), rgba(168, 183, 177, 0.4) 48%, rgba(16, 42, 44, 0.5));
  color: var(--deep-river-ink);
}

.fog-veil {
  position: absolute;
  inset: -10%;
  z-index: 2;
  background: linear-gradient(105deg, transparent 6%, rgba(238, 240, 231, 0.72) 28%, rgba(238, 240, 231, 0.18) 52%, transparent 78%);
  filter: blur(20px);
  animation: fogBreath 12s ease-in-out infinite;
}

.veil-far { animation-duration: 18s; animation-delay: -6s; transform: translateX(-16%); opacity: 0.7; }

.bell-pulse {
  position: absolute;
  left: 20vw;
  top: 38vh;
  width: 15rem;
  height: 15rem;
  transform: rotate(-9deg);
  z-index: 3;
}

.bell-pulse span {
  position: absolute;
  inset: 50%;
  border: 1px solid rgba(27, 66, 81, 0.42);
  border-radius: 50%;
  animation: bellRing 4.8s ease-out infinite;
}
.bell-pulse span:nth-child(2) { animation-delay: 1.2s; }
.bell-pulse span:nth-child(3) { animation-delay: 2.4s; }

.wordmark {
  position: relative;
  z-index: 4;
  margin: 0 0 6vh 9vw;
  font-size: clamp(4rem, 16vw, 15rem);
  color: rgba(16, 42, 44, 0.78);
  filter: blur(0.2px);
  opacity: 0;
  transform: translateY(1.4rem);
  animation: wordmarkArrive 2.8s ease 1.1s forwards;
}

.lantern-dot { color: var(--lantern-persimmon); text-shadow: 0 0 1.6rem rgba(242, 106, 61, 0.68); }
.poem-line { position: relative; z-index: 5; font-family: var(--body-kr); }
.opening-line { margin: 0 0 15vh 12vw; color: rgba(16, 42, 44, 0.72); }

.pier-post {
  position: absolute;
  width: 1.4rem;
  background: linear-gradient(90deg, #5A3F2D, #102A2C 55%, #5A3F2D);
  border-radius: 999px 999px 0 0;
  box-shadow: inset 0 0 1.4rem rgba(16, 42, 44, 0.45);
}
.post-left { left: 7vw; bottom: -4vh; height: 46vh; z-index: 3; opacity: 0.58; }

.rope-line {
  position: absolute;
  height: 2px;
  background: repeating-linear-gradient(90deg, rgba(90, 63, 45, 0.9) 0 8px, rgba(216, 181, 109, 0.7) 8px 13px);
  transform-origin: left center;
  box-shadow: 0 1px 0 rgba(238, 240, 231, 0.25);
}
.rope-opening { left: 5vw; bottom: 23vh; width: 38vw; transform: rotate(-8deg); z-index: 4; }
.rope-ticket { right: 4vw; top: 32vh; width: 46vw; transform: rotate(16deg) scaleX(0); animation: ropeDraw 3.8s ease-in-out infinite alternate; }

.ticket-shore {
  background: linear-gradient(180deg, rgba(168, 183, 177, 0.28), rgba(27, 66, 81, 0.65));
}

.shore-copy { position: relative; z-index: 5; max-width: 42rem; }
.bank-left { margin: 9vh 0 0 4vw; color: var(--fog-paper); }
.bank-right { margin-left: auto; margin-top: 20vh; max-width: 43rem; color: var(--fog-paper); }
.shore-copy p:not(.chapter-label) { color: rgba(238, 240, 231, 0.78); max-width: 31rem; }

.ticket-slip {
  position: absolute;
  right: 12vw;
  bottom: 13vh;
  z-index: 7;
  width: min(28rem, 78vw);
  min-height: 17rem;
  padding: 2rem 2.2rem;
  color: var(--deep-river-ink);
  background:
    linear-gradient(135deg, rgba(238, 240, 231, 0.32), transparent 50%),
    var(--ticket-ochre);
  clip-path: polygon(2% 4%, 97% 0, 100% 92%, 86% 96%, 74% 93%, 62% 100%, 48% 95%, 34% 98%, 18% 93%, 0 97%);
  box-shadow: 0 2rem 6rem rgba(16, 42, 44, 0.45);
  transform: rotate(-3deg);
  animation: ticketFloat 7s ease-in-out infinite;
}

.perforation {
  position: absolute;
  top: 0.6rem;
  bottom: 0.6rem;
  width: 0.5rem;
  background: radial-gradient(circle, rgba(16, 42, 44, 0.24) 0 2px, transparent 2.8px) 0 0 / 8px 13px;
}
.perforation-left { left: 0.6rem; }
.perforation-right { right: 0.6rem; }
.ticket-topline { font-family: var(--label-kr); font-size: 0.78rem; letter-spacing: 0.22em; }
.ticket-name { margin-top: 1.1rem; font-family: var(--serif-kr); font-size: clamp(2.6rem, 7vw, 5rem); letter-spacing: 0.1em; }
.stamp-grid { display: flex; flex-wrap: wrap; gap: 0.7rem; margin-top: 1rem; }
.route-stamp {
  border: 2px solid rgba(90, 63, 45, 0.6);
  padding: 0.28rem 0.55rem;
  border-radius: 0.35rem;
  font-family: var(--label-kr);
  color: rgba(90, 63, 45, 0.74);
  letter-spacing: 0.18em;
  opacity: 0;
  animation: stampAppear 6s ease-in-out infinite;
}
.route-stamp:nth-child(2) { animation-delay: 0.5s; }
.route-stamp:nth-child(3) { animation-delay: 1s; }
.hand-note { font-family: var(--hand-kr); font-size: 2rem; margin: 0.5rem 0 0; color: var(--wet-wood-umber); }
.ticket-seal { position: absolute; right: 2rem; bottom: 1.4rem; width: 2rem; height: 2rem; border-radius: 50%; background: var(--lantern-persimmon); }

.midstream-silence {
  min-height: 112vh;
  background: radial-gradient(ellipse at 52% 48%, rgba(238, 240, 231, 0.07), transparent 38rem), linear-gradient(180deg, rgba(27, 66, 81, 0.72), rgba(16, 42, 44, 0.92));
}
.midstream-notes { position: absolute; left: 9vw; top: 11vh; z-index: 4; color: rgba(238, 240, 231, 0.82); }
.midstream-notes h2 { font-size: clamp(2rem, 5vw, 5.2rem); }
.boat-line {
  position: absolute;
  z-index: 5;
  width: min(31rem, 58vw);
  left: 50%;
  top: 54%;
  transform: translate(-50%, -50%) rotate(-7deg);
  overflow: visible;
  animation: boatCross 14s ease-in-out infinite;
}
.boat-line path { fill: none; stroke: rgba(238, 240, 231, 0.82); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.boat-hull { fill: rgba(16, 42, 44, 0.72) !important; }
.midstream-tide { z-index: 4; border-color: rgba(168, 183, 177, 0.28); }
.midstream-tide.one { left: 17vw; bottom: 22vh; }
.midstream-tide.two { right: 18vw; top: 34vh; }
.midstream-line { position: absolute; right: 8vw; bottom: 12vh; color: rgba(238, 240, 231, 0.52); }

.reed-rain {
  background: linear-gradient(180deg, rgba(16, 42, 44, 0.92), rgba(101, 118, 90, 0.56) 45%, rgba(27, 66, 81, 0.82));
}
.reed-curtain {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}
.reed-curtain i {
  position: absolute;
  bottom: -8vh;
  width: 0.34rem;
  height: var(--reed-height, 76vh);
  left: var(--reed-left, 10%);
  border-radius: 50% 50% 0 0;
  background: linear-gradient(180deg, rgba(168, 183, 177, 0.22), #65765A 42%, #5A3F2D);
  transform-origin: bottom center;
  animation: reedSway 5.5s ease-in-out infinite;
}
.reed-curtain i:nth-child(1) { --reed-left: 4%; --reed-height: 84vh; animation-delay: -1s; }
.reed-curtain i:nth-child(2) { --reed-left: 9%; --reed-height: 62vh; }
.reed-curtain i:nth-child(3) { --reed-left: 15%; --reed-height: 91vh; animation-delay: -2s; }
.reed-curtain i:nth-child(4) { --reed-left: 25%; --reed-height: 67vh; }
.reed-curtain i:nth-child(5) { --reed-left: 32%; --reed-height: 78vh; animation-delay: -3s; }
.reed-curtain i:nth-child(6) { --reed-left: 41%; --reed-height: 58vh; }
.reed-curtain i:nth-child(7) { --reed-left: 55%; --reed-height: 86vh; animation-delay: -1.7s; }
.reed-curtain i:nth-child(8) { --reed-left: 64%; --reed-height: 72vh; }
.reed-curtain i:nth-child(9) { --reed-left: 72%; --reed-height: 93vh; animation-delay: -2.3s; }
.reed-curtain i:nth-child(10) { --reed-left: 81%; --reed-height: 68vh; }
.reed-curtain i:nth-child(11) { --reed-left: 89%; --reed-height: 82vh; animation-delay: -3.4s; }
.reed-curtain i:nth-child(12) { --reed-left: 96%; --reed-height: 74vh; }
.rain-window {
  position: absolute;
  left: 8vw;
  top: 18vh;
  z-index: 4;
  width: min(27rem, 62vw);
  height: 58vh;
  border: 1px solid rgba(168, 183, 177, 0.28);
  background: linear-gradient(90deg, rgba(238, 240, 231, 0.04), rgba(168, 183, 177, 0.14), rgba(238, 240, 231, 0.03));
  backdrop-filter: blur(3px);
}
.droplet { position: absolute; top: -2rem; width: 2px; height: 2.5rem; border-radius: 99px; background: linear-gradient(180deg, transparent, #A8B7B1); animation: dropletSlide 5s linear infinite; }
.d1 { left: 15%; animation-delay: -0.3s; }.d2 { left: 34%; animation-delay: -2.1s; }.d3 { left: 51%; animation-delay: -1.2s; }.d4 { left: 68%; animation-delay: -3.5s; }.d5 { left: 84%; animation-delay: -2.8s; }
.post-rain { bottom: -3vh; z-index: 4; opacity: 0.64; }
.post-rain.one { left: 48vw; height: 64vh; }.post-rain.two { left: 53vw; height: 78vh; width: 0.9rem; }

.lantern-arrival {
  min-height: 108vh;
  background: radial-gradient(circle at 72% 36%, rgba(242, 106, 61, 0.26), transparent 18rem), linear-gradient(180deg, #1B4251, #102A2C 72%);
}
.arrival-glow { position: absolute; right: 18vw; top: 24vh; width: 16rem; height: 16rem; border-radius: 50%; background: radial-gradient(circle, rgba(242, 106, 61, 0.42), rgba(242, 106, 61, 0.08) 42%, transparent 68%); animation: lanternGlow 4s ease-in-out infinite; }
.lantern-path { position: absolute; inset: 0; z-index: 5; }
.traveling-lantern { position: absolute; left: 30vw; top: 27vh; width: 1.4rem; height: 1.4rem; border-radius: 50%; background: var(--lantern-persimmon); box-shadow: 0 0 2rem var(--lantern-persimmon); animation: lanternTravel 9s ease-in-out infinite; }
.lantern-reflection { position: absolute; left: 30vw; top: 55vh; width: 1.2rem; height: 12rem; border-radius: 50%; background: linear-gradient(180deg, rgba(242, 106, 61, 0.55), transparent); filter: blur(4px); transform: scaleY(0.55); animation: reflectionTravel 9s ease-in-out infinite, reflectionShimmer 1.7s ease-in-out infinite; }
.final-sign { position: relative; z-index: 7; margin: 16vh 0 0 9vw; max-width: 50rem; }
.final-sign p:not(.chapter-label) { color: rgba(238, 240, 231, 0.76); max-width: 33rem; }
.final-wordmark { margin-top: 4vh; font-family: var(--serif-kr); font-size: clamp(3.2rem, 10vw, 9rem); letter-spacing: 0.12em; }
.plank-shadow { position: absolute; right: 5vw; bottom: 17vh; width: 44vw; height: 1.25rem; background: rgba(90, 63, 45, 0.45); transform: rotate(-9deg); border-radius: 99px; }
.p2 { bottom: 23vh; right: 0; opacity: 0.6; }.p3 { bottom: 29vh; right: 10vw; opacity: 0.35; }

@keyframes currentDrift { from { transform: translateX(-18%); } to { transform: translateX(18%); } }
@keyframes ripple { 0%,100% { transform: scale(0.8); opacity: 0.22; } 50% { transform: scale(1.45); opacity: 0.72; } }
@keyframes fogBreath { 0%,100% { opacity: 0.46; transform: translateX(-8%); } 50% { opacity: 0.86; transform: translateX(8%); } }
@keyframes bellRing { 0% { width: 0; height: 0; margin: 0; opacity: 0.85; } 100% { width: 15rem; height: 15rem; margin: -7.5rem; opacity: 0; } }
@keyframes wordmarkArrive { to { opacity: 1; transform: translateY(0); } }
@keyframes ropeDraw { to { transform: rotate(16deg) scaleX(1); } }
@keyframes ticketFloat { 0%,100% { transform: rotate(-3deg) translateY(0); } 50% { transform: rotate(-1.4deg) translateY(-0.8rem); } }
@keyframes stampAppear { 0%,18% { opacity: 0; transform: scale(1.18) rotate(-2deg); } 30%,80% { opacity: 0.82; transform: scale(1) rotate(-2deg); } 100% { opacity: 0; } }
@keyframes boatCross { 0%,100% { transform: translate(-58%, -50%) rotate(-7deg); } 50% { transform: translate(-42%, -54%) rotate(-6deg); } }
@keyframes reedSway { 0%,100% { transform: rotate(-2deg); } 50% { transform: rotate(3deg); } }
@keyframes dropletSlide { 0% { transform: translateY(-8vh); opacity: 0; } 15% { opacity: 0.9; } 100% { transform: translateY(67vh); opacity: 0; } }
@keyframes lanternGlow { 0%,100% { opacity: 0.62; transform: scale(0.92); } 50% { opacity: 1; transform: scale(1.1); } }
@keyframes lanternTravel { 0%,100% { transform: translate(0, 0); } 45% { transform: translate(25vw, 27vh); } 70% { transform: translate(36vw, 6vh); } }
@keyframes reflectionTravel { 0%,100% { transform: translate(0, 0) scaleY(0.5); } 45% { transform: translate(25vw, 8vh) scaleY(0.75); } 70% { transform: translate(36vw, -3vh) scaleY(0.32); } }
@keyframes reflectionShimmer { 0%,100% { opacity: 0.42; filter: blur(5px); } 50% { opacity: 0.78; filter: blur(2px); } }

@media (max-width: 760px) {
  .shore-markers { right: 0.5rem; gap: 0.35rem; }
  .marker { width: 2.4rem; overflow: hidden; white-space: nowrap; padding-inline: 0.55rem; }
  .wordmark { margin-left: 1vw; font-size: 19vw; }
  .ticket-slip { right: 5vw; bottom: 9vh; }
  .bank-left, .bank-right, .final-sign { margin-left: 0; margin-right: 3rem; }
  .rain-window { left: 3vw; width: 42vw; }
}
