/* ════════════════════════════════════════════════════════════════════
 * 오늘어디 (TodayWay) — landing v4
 * 컨셉: 한 장의 노트 위에서 펼쳐지는 하나의 여정.
 *   sticky stage 안에서 scroll 따라 씬이 fade·morph 로 이어짐.
 *   카드/박스 없음 — 모든 텍스트는 종이 위에 직접 놓임.
 * ════════════════════════════════════════════════════════════════════ */

:root {
  --paper: #f5edd6;
  --paper-deep: #ebe0bf;
  --paper-shadow: #d8caa4;
  --ink: #1f1a14;
  --ink-soft: #3a3023;
  --ink-mute: #6a5d44;
  --line: #c4b78c;

  --blue: #2563eb;
  --blue-deep: #1d4ed8;
  --blue-soft: #bfd0f5;
  --green: #5da566;
  --green-soft: #c0d8b7;
  --coral: #d8503f;
  --coral-soft: #f1b5ac;
  --amber: #d9a04a;
  --amber-soft: #ecd4a3;

  --hand: "Gaegu", "Gowun Dodum", "Pretendard Variable", sans-serif;
  --kr: "Gowun Dodum", "Pretendard Variable", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", monospace;
}

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

/* ═══════════════ Too-small viewport overlay ═══════════════
 * 1024×640 이하에서 사이트 전체 가리고 안내만 보여줌 */
.too-small {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background:
    radial-gradient(ellipse at 50% 30%, color-mix(in srgb, var(--blue) 18%, transparent), transparent 60%),
    var(--paper);
  background-image:
    radial-gradient(ellipse at 50% 30%, color-mix(in srgb, var(--blue) 18%, transparent), transparent 60%),
    url("landing/scene-1-calendar/notebook-paper.jpg");
  background-size: cover, 800px auto;
  background-repeat: no-repeat, repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 24px;
}
.too-small[hidden] { display: none; }
.too-small-inner {
  max-width: 360px;
  width: 100%;
  text-align: center;
  font-family: "Gaegu", "Gowun Dodum", sans-serif;
  color: var(--ink);
}
.too-small-logo {
  width: 180px;
  height: auto;
  margin: 0 auto 28px;
  display: block;
  filter: drop-shadow(0 6px 14px rgba(37, 99, 235, 0.18));
}
.too-small h2 {
  font-family: "Gaegu", sans-serif;
  font-weight: 700;
  font-size: 30px;
  line-height: 1.25;
  margin-bottom: 16px;
  color: var(--ink);
  word-break: keep-all;
}
.too-small p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink-soft);
  margin-bottom: 28px;
  word-break: keep-all;
}
.too-small p strong {
  font-weight: 700;
  color: var(--blue);
}
.too-small-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 22px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 999px;
  font-family: "Gaegu", sans-serif;
  font-weight: 700;
  font-size: 16px;
  text-decoration: none;
  transition: transform 0.2s, background 0.2s;
}
.too-small-cta:hover { transform: translateY(-2px); background: var(--blue); }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
body {
  font-family: var(--kr);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
  background-color: var(--paper);
  /* background-attachment: fixed 는 성능 킬러. 대신 fixed pseudo 레이어 사용 */
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-color: var(--paper);
  background-image: url("landing/scene-1-calendar/notebook-paper.jpg");
  background-size: 1400px auto;
  background-repeat: repeat;
  pointer-events: none;
  /* 종이 텍스처가 모든 화면에 깔리지만 스크롤 따라 리페인트 안 됨 */
}

a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
img, svg { display: block; max-width: 100%; }

.hand { font-family: var(--hand); }
.mono { font-family: var(--mono); font-feature-settings: "tnum" 1; }

/* 스크린리더용 — 시각적으로 안 보이지만 a11y 트리에 노출 */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Paper edge vignette — 종이 끄트머리 약간 어두운 느낌 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background:
    radial-gradient(ellipse at 50% 50%, transparent 55%, rgba(80, 60, 20, 0.10) 100%);
}

/* product frame 의 sub copy 만 가운데 정렬 (인라인 style 대체) */
.frame-sub-center { margin-left: auto; margin-right: auto; text-align: center; }

/* ═══════════════ Topbar ═══════════════ */
.topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  z-index: 100;
  transition: background 0.3s ease, backdrop-filter 0.3s, border-color 0.3s;
  border-bottom: 1px solid transparent;
}
.topbar.scrolled {
  background: color-mix(in srgb, var(--paper) 90%, transparent);
  backdrop-filter: blur(14px) saturate(1.3);
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  border-bottom-color: color-mix(in srgb, var(--line) 60%, transparent);
}
.topbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: auto;
}
.topbar-brand img {
  height: 30px;
  width: auto;
  display: block;
}
.topbar-nav {
  display: flex;
  gap: 28px;
  align-items: center;
}
.topbar-nav a {
  font-family: var(--hand);
  font-size: 18px;
  font-weight: 700;
  color: var(--ink-soft);
  letter-spacing: 0;
  position: relative;
  padding: 4px 0;
  transition: color 0.2s;
}
.topbar-nav a::after {
  content: "";
  position: absolute;
  left: 50%; right: 50%;
  bottom: -2px;
  height: 2px;
  background: var(--blue);
  transition: left 0.25s, right 0.25s;
}
.topbar-nav a:hover { color: var(--blue); }
.topbar-nav a:hover::after { left: 0; right: 0; }

.topbar-gh {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 999px;
  font-family: var(--hand);
  font-size: 16px;
  font-weight: 700;
  transition: transform 0.2s, background 0.2s;
}
.topbar-gh:hover { transform: translateY(-1px); background: var(--blue); }

@media (max-width: 880px) {
  .topbar-nav { display: none; }
  .topbar { padding: 0 20px; }
}

/* ═══════════════ 좌측 rail — 출발/도착 + 캐릭터 ═══════════════ */
.rail {
  position: fixed;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 50;
  pointer-events: none;
}
.rail-label {
  font-family: var(--hand);
  font-size: 13px;
  color: var(--ink-mute);
  letter-spacing: 0.06em;
  margin: 4px 0;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  transform: rotate(180deg);
}
.rail-line {
  position: relative;
  width: 40px;
  height: 480px;
  max-height: 420px;
  min-height: 240px;
  margin: 6px 0;
  background: transparent;
  overflow: visible;
  /* 발자국이 스크롤 따라 위→아래로 차곡차곡 찍힘 */
  --p: 0%;
}
.rail-progress {
  position: absolute;
  top: 0;
  left: 50%;
  /* X 중앙 정렬 + Y 방향 뒤집기 (캐릭터는 아래로 걷는데 원본 이미지가 위로 향한 발자국이라) */
  transform: translateX(-50%) scaleY(-1);
  transform-origin: center center;
  width: 70px;
  height: 100%;
  background-image: url("landing/scene-3-route/footprints.png");
  background-repeat: repeat-y;
  background-size: 100% auto;
  background-position: top center;
  pointer-events: none;
  z-index: 1;
  clip-path: inset(calc(100% - var(--p, 0%)) 0 0 0);  /* scaleY -1 이라 inset 도 위아래 뒤집어서 */
}
.rail-char {
  position: absolute;
  left: 50%;
  top: 0;
  margin-top: -35px;
  margin-left: -23px;
  width: 46px;
  height: 70px;
  will-change: transform;
  z-index: 5;
}
.rail-char img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  filter: drop-shadow(0 3px 5px rgba(0,0,0,0.18));
}
.rail-char img.active { opacity: 1; }

/* 출발/도착 라벨 이미지 (rail 끝) */
.rail-end-img {
  width: 56px;
  height: auto;
  display: block;
  margin: 2px 0;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.12));
}
.rail-end-img.start { margin-bottom: 6px; }
.rail-end-img.end { margin-top: 6px; }

@media (max-width: 1100px) { .rail { display: none; } }

/* ═══════════════ HERO ═══════════════ */
.hero {
  min-height: 820px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 90px 80px 40px;
  position: relative;
  z-index: 2;
}
.hero-inner {
  width: 100%;
  max-width: 1100px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
}
.hero-greeting {
  font-family: var(--hand);
  font-size: 28px;
  color: var(--ink-mute);
  margin-bottom: 20px;
  letter-spacing: 0.01em;
}
.hero-greeting .scribble {
  display: inline-block;
  position: relative;
  color: var(--blue);
}
.hero-greeting .scribble::after {
  content: "";
  position: absolute;
  left: -4px; right: -4px;
  bottom: 2px;
  height: 8px;
  background: var(--amber-soft);
  z-index: -1;
  border-radius: 4px;
  transform: rotate(-1deg);
}
.hero-brand {
  width: 640px;
  height: auto;
  margin-bottom: 32px;
  filter: drop-shadow(0 8px 20px rgba(37, 99, 235, 0.18));
  animation: heroBrandIn 1.2s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes heroBrandIn {
  0% { opacity: 0; transform: translateY(20px) scale(0.96); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
.hero-concept {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 10px;
  margin-bottom: 22px;
  font-family: var(--hand);
}
.hero-concept-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  font-size: 17px;
  font-weight: 700;
  color: var(--blue-deep);
  background: color-mix(in srgb, var(--blue) 14%, white);
  border-radius: 999px;
  border: 1.5px solid var(--blue);
  box-shadow: 2px 2px 0 var(--blue);
  letter-spacing: -0.01em;
}
.hero-concept-pill:nth-child(2) {
  background: color-mix(in srgb, var(--green) 14%, white);
  border-color: var(--green);
  box-shadow: 2px 2px 0 var(--green);
  color: var(--green);
}
.hero-concept-pill:nth-child(3) {
  background: color-mix(in srgb, var(--amber) 18%, white);
  border-color: var(--amber);
  box-shadow: 2px 2px 0 var(--amber);
  color: #8a6a1c;
}

.hero-tag {
  font-family: var(--hand);
  font-size: 24px;
  color: var(--ink-soft);
  line-height: 1.5;
  max-width: 540px;
  margin-bottom: 36px;
  word-break: keep-all;
}
.hero-tag em {
  font-style: normal;
  color: var(--blue);
  font-weight: 700;
  background: linear-gradient(transparent 65%, var(--amber-soft) 65%);
  padding: 0 4px;
}
.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  align-items: center;
  justify-content: center;
  font-family: var(--hand);
  font-size: 16px;
  color: var(--ink-mute);
}
.hero-meta-dot {
  display: inline-block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--ink-mute);
  opacity: 0.6;
}
.hero-cta-mouse {
  position: absolute;
  bottom: -20px;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 38px;
  border: 2px solid var(--ink-soft);
  border-radius: 16px;
  display: grid;
  place-items: start center;
  padding-top: 6px;
  opacity: 0.55;
}
.hero-cta-mouse::after {
  content: "";
  width: 3px;
  height: 8px;
  background: var(--ink-soft);
  border-radius: 2px;
  animation: mouseScroll 1.6s ease-in-out infinite;
}
@keyframes mouseScroll {
  0% { transform: translateY(0); opacity: 1; }
  60% { transform: translateY(10px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

/* hero 우측 살짝 위에 그림 — character 그림 */
.hero-char {
  position: absolute;
  right: -2%;
  bottom: 8%;
  width: 130px;
  height: auto;
  transform: rotate(-4deg);
  animation: heroCharBob 3.2s ease-in-out infinite;
  z-index: 3;
  pointer-events: none;
}
@keyframes heroCharBob {
  0%, 100% { transform: rotate(-4deg) translateY(0); }
  50% { transform: rotate(-2deg) translateY(-10px); }
}

/* hero 산재 doodle 들 */
.hero-doodle {
  position: absolute;
  z-index: 2;
  pointer-events: none;
  animation: heroDoodleBob 5s ease-in-out infinite;
}
@keyframes heroDoodleBob {
  0%, 100% { transform: translateY(0) rotate(var(--r, 0deg)); }
  50% { transform: translateY(-8px) rotate(calc(var(--r, 0deg) + 3deg)); }
}
.hero-doodle.hd-headline {
  top: 8%; left: 4%;
  width: 200px;
  --r: -8deg;
  opacity: 0.95;
}
.hero-doodle.hd-arrow {
  top: 18%; right: 16%;
  width: 90px;
  --r: 28deg;
  animation-duration: 4s;
  opacity: 0.85;
}
.hero-doodle.hd-star {
  top: 14%; right: 6%;
  width: 50px;
  --r: 12deg;
  animation-delay: 0.6s;
}
.hero-doodle.hd-heart {
  bottom: 22%; left: 10%;
  width: 38px;
  --r: -10deg;
  animation-delay: 1s;
}
.hero-doodle.hd-check {
  top: 50%; left: 6%;
  width: 46px;
  --r: -6deg;
  animation-delay: 0.4s;
}
.hero-doodle.hd-sparkle1 {
  top: 32%; right: 28%;
  width: 26px;
  animation: spark 1.6s ease-in-out infinite;
  animation-delay: 0s;
}
.hero-doodle.hd-sparkle2 {
  bottom: 38%; right: 8%;
  width: 22px;
  animation: spark 1.6s ease-in-out infinite;
  animation-delay: 0.8s;
}
.hero-doodle.hd-pin {
  bottom: 14%; left: 16%;
  width: 50px;
  --r: -8deg;
  animation-delay: 1.4s;
  opacity: 0.9;
}
.hero-doodle.hd-wave {
  bottom: 8%; left: 6%;
  width: 100px;
  --r: -6deg;
  animation-delay: 0.2s;
}

@media (max-width: 880px) {
  .hero { padding: 90px 24px 40px; }
  .hero-char,
  .hero-doodle.hd-arrow,
  .hero-doodle.hd-heart,
  .hero-doodle.hd-check,
  .hero-doodle.hd-pin,
  .hero-doodle.hd-wave { display: none; }
  .hero-doodle.hd-headline { top: 4%; width: 130px; }
}

/* ═══════════════ JOURNEY — 하나의 sticky stage 안에서 씬이 전환 ═══════════════ */
.journey {
  position: relative;
  width: 100%;
  /* 6 씬 × ~100vh + 여유 */
  /* 6 frame × ~1.4 viewport 씩 머묾 — 각 frame 1148px 스크롤 dwell */
  height: 8200px;
}
.stage-pin {
  position: sticky;
  top: 0;
  height: 820px;
  width: 100%;
  overflow: hidden;
}
.stage {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.frame {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.45s ease, visibility 0s linear 0.45s, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateY(40px);
  pointer-events: none;
  padding: 92px 64px 32px;
  overflow: hidden;
}
.frame.active {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.45s ease, visibility 0s, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateY(0);
  pointer-events: auto;
}

/* 각 씬 공통 좌측 라벨 */
.frame-num {
  position: absolute;
  top: 80px;
  left: 64px;
  font-family: var(--hand);
  font-size: 17px;
  font-weight: 700;
  color: var(--ink-mute);
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0.9;
  z-index: 5;
}
.frame-num strong {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 50%;
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
}
.frame-num em {
  font-style: normal;
  position: relative;
}
.frame-num em::before {
  content: "·";
  margin-right: 8px;
  color: var(--ink-mute);
}

@media (max-width: 880px) {
  .frame { padding: 70px 24px 40px; }
  .frame-num { top: 70px; left: 24px; font-size: 16px; }
}

/* ───── 공통 layout slots ───── */
.frame-title {
  font-family: var(--hand);
  font-weight: 700;
  font-size: 58px;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--ink);
  word-break: keep-all;
}
.frame-title .accent { color: var(--blue); }
.frame-title .underline {
  position: relative;
  display: inline-block;
}
.frame-title .underline::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 4px;
  height: 10px;
  background: var(--amber-soft);
  border-radius: 5px;
  z-index: -1;
  transform: rotate(-1deg);
}
.frame-sub {
  font-family: var(--hand);
  font-size: 21px;
  line-height: 1.6;
  color: var(--ink-soft);
  max-width: 38ch;
  margin-top: 16px;
}
.frame-sub strong {
  font-weight: 700;
  color: var(--blue);
  background: linear-gradient(transparent 62%, var(--amber-soft) 62%);
  padding: 0 2px;
}

/* ═══════════════ FRAME 0 — Calendar ═══════════════ */
.frame-calendar {
  display: grid;
  grid-template-columns: 0.9fr 1fr;
  gap: 60px;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}
.frame-calendar-text {
  display: flex;
  flex-direction: column;
}
.frame-calendar-list {
  font-family: var(--hand);
  font-size: 19px;
  line-height: 2;
  color: var(--ink-soft);
  margin-top: 24px;
}
.frame-calendar-list li {
  display: flex;
  align-items: baseline;
  gap: 12px;
}
.frame-calendar-list li::before {
  content: "✓";
  color: var(--green);
  font-weight: 700;
  font-size: 22px;
  line-height: 1;
}
.frame-calendar-list li b {
  color: var(--blue);
  font-weight: 700;
}
.frame-calendar-visual {
  position: relative;
  display: flex;
  justify-content: center;
}
.frame-calendar-visual img.calendar {
  width: 100%;
  max-width: 540px;
  height: auto;
  transform: rotate(2deg);
  filter: drop-shadow(0 18px 32px rgba(40, 30, 0, 0.15));
}
.frame-calendar-visual img.char {
  position: absolute;
  right: -8%;
  bottom: -10%;
  width: 36%;
  filter: drop-shadow(0 8px 14px rgba(0,0,0,0.15));
  z-index: 2;
}
.frame-calendar-visual .doodle-circle {
  position: absolute;
  top: 8%;
  right: 14%;
  width: 22%;
  transform: rotate(-12deg);
  z-index: 1;
}
.frame-calendar-visual .doodle-arrow {
  position: absolute;
  top: 22%;
  left: -6%;
  width: 16%;
  transform: rotate(-30deg);
  z-index: 1;
}

@media (max-width: 980px) {
  .frame-calendar { grid-template-columns: 1fr; gap: 30px; }
  .frame-calendar-visual { max-width: 380px; margin: 0 auto; }
}

/* ═══════════════ FRAME 1 — Map ═══════════════ */
.frame-map {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 0.85fr 1fr;
  gap: 60px;
  align-items: center;
}
.frame-map-text {
  text-align: left;
  max-width: 480px;
}
.frame-map-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  width: 100%;
  margin-left: auto;
  max-width: 760px;
}
.frame-map-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 1920 / 1080;
}
.map-extras {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  flex-wrap: wrap;
  width: 100%;
  padding: 0 12px;
}
.map-extra-coords {
  width: 300px;
  height: auto;
  transform: rotate(-2deg);
}
.map-extra-geo {
  width: 200px;
  height: auto;
  transform: rotate(3deg);
}
.frame-map-stage img.map {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 16px 32px rgba(40, 30, 0, 0.18));
}
.frame-map-stage .pin {
  position: absolute;
  width: 60px;
  transform: translate(-50%, -100%);
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.25));
  z-index: 3;
}
.frame-map-stage .pin.start { top: 22%; left: 16%; }
.frame-map-stage .pin.end { top: 78%; left: 80%; }
.frame-map-stage .pin-label {
  position: absolute;
  font-family: var(--hand);
  font-weight: 700;
  font-size: 17px;
  color: var(--ink);
  background: color-mix(in srgb, var(--paper) 75%, white);
  padding: 4px 12px;
  border-radius: 999px;
  border: 2px solid var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
  z-index: 4;
  white-space: nowrap;
  letter-spacing: -0.01em;
  transform: translate(-50%, 0);
}
/* 핀 머리 바로 위에 라벨이 붙도록 — pin top: X% 일 때 라벨 bottom 이 핀 머리에 닿게.
 * 핀 height ~60px, map height ~600px → 핀 머리는 pin top - 10% 정도.
 * 라벨 transform translate(-50%, -100%) → top 값이 바로 라벨 bottom edge 가 됨. */
.frame-map-stage .pin-label.start {
  top: 11%; left: 16%;
  transform: translate(-50%, -100%);
  border-color: var(--green);
  box-shadow: 2px 2px 0 var(--green);
  color: var(--green);
}
.frame-map-stage .pin-label.end {
  top: 66%; left: 80%;
  transform: translate(-50%, -100%);
  border-color: var(--coral);
  box-shadow: 2px 2px 0 var(--coral);
  color: var(--coral);
}
/* geo-bubble — 더 이상 사용 안 함 (지도에서 제거) */
.frame-map-stage img.char {
  position: absolute;
  top: 40%;
  left: 48%;
  width: 12%;
  transform: translate(-50%, -50%);
  z-index: 6;
  filter: drop-shadow(0 8px 12px rgba(0,0,0,0.2));
}

.frame-feature-list {
  margin-top: 24px;
  font-family: var(--hand);
  font-size: 18px;
  line-height: 1.6;
  color: var(--ink-soft);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.frame-feature-list li {
  position: relative;
  padding-left: 28px;
  word-break: keep-all;
}
.frame-feature-list li::before {
  content: "✦";
  position: absolute;
  left: 4px;
  top: 2px;
  color: var(--blue);
  font-size: 14px;
}
.frame-feature-list b {
  color: var(--blue);
  font-weight: 700;
}

@media (max-width: 980px) {
  .frame-map { grid-template-columns: 1fr; gap: 32px; }
  .frame-map-text { text-align: center; margin: 0 auto; }
  .frame-map-stage { margin: 0 auto; max-width: 560px; }
  .frame-feature-list { text-align: left; max-width: 360px; margin-left: auto; margin-right: auto; }
}
@media (max-width: 880px) {
  .frame-map-stage .geo-bubble { display: none; }
  .frame-map-stage .pin { width: 40px; }
}

/* ═══════════════ FRAME 2 — Route ═══════════════ */
.frame-route {
  display: grid;
  grid-template-columns: 0.9fr 1fr;
  gap: 60px;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}
.frame-route-visual {
  position: relative;
  order: 2;
  margin-top: 32px;
  height: 540px;
  max-height: 600px;
  display: flex;
  justify-content: center;
}
.frame-route-visual img.path {
  max-width: 100%;
  height: 100%;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 12px 24px rgba(40,30,0,0.15));
}
.frame-route-visual .runner {
  position: absolute;
  left: 50%;
  top: 0;
  width: 64px;
  height: 76px;
  transform: translate(-50%, -50%);
  z-index: 5;
  transition: top 0.15s linear;
}
.frame-route-visual .runner img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.25));
}
.frame-route-visual .runner img.active { opacity: 1; }

.frame-route-text {
  order: 1;
  display: flex;
  flex-direction: column;
  margin-top: 32px;
}
.frame-route-text .frame-title { margin-bottom: 8px; }
.frame-route-segments {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 18px;
}
.seg {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--hand);
  font-size: 19px;
  color: var(--ink-soft);
  padding: 4px 0;
}
.seg-mode {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-family: var(--hand);
  font-size: 18px;
  font-weight: 700;
  flex-shrink: 0;
  color: white;
}
.seg.walk .seg-mode { background: var(--green); }
.seg.bus .seg-mode { background: var(--blue); }
.seg.subway .seg-mode { background: var(--coral); }
.seg.transfer .seg-mode { background: var(--amber); color: var(--ink); }
.seg-where {
  flex: 1;
  font-weight: 500;
}
.seg-where b { font-weight: 700; color: var(--ink); }
.seg-time {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 600;
  color: var(--ink-mute);
}
.seg-total {
  margin-top: 8px;
  padding-top: 14px;
  border-top: 2px dashed var(--line);
  display: flex;
  align-items: baseline;
  gap: 16px;
  font-family: var(--hand);
  font-size: 22px;
  color: var(--ink);
}
.seg-total-num {
  font-family: var(--hand);
  font-size: 56px;
  font-weight: 700;
  color: var(--blue);
  line-height: 1;
}
.seg-total small {
  font-size: 16px;
  font-weight: 500;
  color: var(--ink-mute);
}

@media (max-width: 980px) {
  .frame-route { grid-template-columns: 1fr; gap: 30px; padding-top: 0; }
  .frame-route-text,
  .frame-route-visual { order: initial; }
  .frame-route-visual { height: 320px; }
}

/* ═══════════════ FRAME 3 — Alert ═══════════════ */
.frame-alert {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}
.frame-alert-text {
  display: flex;
  flex-direction: column;
}
.frame-alert-points {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-family: var(--hand);
  font-size: 19px;
  color: var(--ink-soft);
  line-height: 1.6;
}
.frame-alert-points li {
  position: relative;
  padding-left: 22px;
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink-soft);
}
.frame-alert-points li::before {
  content: "✦";
  position: absolute;
  left: 0;
  top: 1px;
  color: var(--coral);
  font-size: 15px;
  line-height: 1;
}
.frame-alert-points b {
  display: inline;
  color: var(--ink);
  font-weight: 700;
  margin-right: 6px;
  letter-spacing: -0.01em;
}
.frame-alert-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 480px;
}
.frame-alert-notif {
  width: 86%;
  max-width: 480px;
  transform: rotate(-4deg);
  filter: drop-shadow(0 16px 30px rgba(40,30,0,0.25));
  animation: alertNotifIn 2.4s ease-in-out infinite alternate;
  z-index: 2;
}
@keyframes alertNotifIn {
  0% { transform: rotate(-4deg) translateY(0); }
  100% { transform: rotate(-2deg) translateY(-6px); }
}
.frame-alert-char {
  position: absolute;
  right: -6%;
  bottom: 4%;
  width: 36%;
  z-index: 3;
  filter: drop-shadow(0 10px 14px rgba(0,0,0,0.18));
}
.frame-alert-spark {
  position: absolute;
  width: 28px;
  height: 28px;
  z-index: 1;
  animation: spark 1.6s ease-in-out infinite;
}
.frame-alert-spark.s1 { top: 8%; left: 16%; animation-delay: 0s; }
.frame-alert-spark.s2 { top: 22%; right: 8%; animation-delay: 0.4s; }
.frame-alert-spark.s3 { bottom: 20%; left: 8%; animation-delay: 0.8s; }
.frame-alert-spark.s4 { top: 60%; right: 22%; animation-delay: 1.2s; width: 22px; height: 22px; }
.frame-alert-spark.s5 { top: 14%; left: 56%; animation-delay: 0.6s; width: 18px; height: 18px; }
@keyframes spark {
  0%, 100% { opacity: 0; transform: scale(0.5) rotate(0); }
  50% { opacity: 1; transform: scale(1) rotate(20deg); }
}

/* 알림 주변 손그림 doodle 들 */
.frame-alert-doodle {
  position: absolute;
  pointer-events: none;
  z-index: 1;
  animation: doodleFloat 4.5s ease-in-out infinite;
}
@keyframes doodleFloat {
  0%, 100% { transform: translateY(0) rotate(var(--r, 0deg)); }
  50% { transform: translateY(-6px) rotate(calc(var(--r, 0deg) + 3deg)); }
}
.frame-alert-doodle.d-bell {
  top: 18%; left: 22%;
  width: 54px;
  --r: -14deg;
  animation-duration: 5s;
}
.frame-alert-doodle.d-excl {
  top: 8%; right: 26%;
  width: 22px;
  --r: 8deg;
  animation-delay: 0.4s;
}
.frame-alert-doodle.d-shock {
  bottom: 4%; right: 6%;
  width: 90px;
  opacity: 0.55;
  --r: 12deg;
  animation-delay: 0.8s;
}
.frame-alert-doodle.d-star {
  top: 48%; left: 4%;
  width: 36px;
  --r: -10deg;
  animation-delay: 1.4s;
  animation-duration: 4s;
}
.frame-alert-doodle.d-heart {
  bottom: 10%; right: 28%;
  width: 32px;
  --r: 6deg;
  animation-delay: 0.6s;
}
.frame-alert-doodle.d-check {
  top: 70%; left: 14%;
  width: 44px;
  --r: -8deg;
  animation-delay: 1.0s;
}
.frame-alert-doodle.d-clock {
  top: 16%; left: 52%;
  width: 56px;
  opacity: 0.9;
  --r: 10deg;
  animation-delay: 0.2s;
  animation-duration: 6s;
}

@media (max-width: 980px) {
  .frame-alert { grid-template-columns: 1fr; gap: 40px; }
  .frame-alert-visual { min-height: 380px; }
}

/* ═══════════════ FRAME 4 — Product (실제 화면) ═══════════════ */
.frame-product {
  max-width: 1300px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}
.frame-product .frame-title {
  font-size: 46px;
  text-align: center;
}
.frame-product-text {
  text-align: center;
  max-width: 720px;
}
.frame-product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
  width: 100%;
  max-width: 1200px;
}
.product-shot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.product-shot img {
  width: 100%;
  height: auto;
  display: block;
  transform: rotate(var(--rot, -2deg));
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  filter: drop-shadow(0 18px 26px rgba(40,30,0,0.18));
}
.product-shot:nth-child(1) { --rot: -3deg; }
.product-shot:nth-child(2) { --rot: 2deg; }
.product-shot:nth-child(3) { --rot: -1deg; }
.product-shot:nth-child(4) { --rot: 3deg; }
.product-shot:hover img {
  transform: rotate(0deg) translateY(-6px) scale(1.03);
}
.product-shot-caption {
  font-family: var(--hand);
  font-size: 17px;
  color: var(--ink-soft);
  text-align: center;
  line-height: 1.4;
}
.product-shot-caption b { color: var(--blue); font-weight: 700; }

@media (max-width: 1100px) {
  .frame-product-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
}
@media (max-width: 600px) {
  .frame-product-grid { grid-template-columns: 1fr; max-width: 280px; }
}

/* ═══════════════ FRAME 5 — Team ═══════════════ */
.frame-team {
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
}
.frame-team-banner {
  width: 100%;
  max-width: 380px;
  height: auto;
}
.frame-team-sub {
  font-family: var(--hand);
  font-size: 20px;
  color: var(--ink-soft);
  text-align: center;
  margin-bottom: 12px;
}
.frame-team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
  width: 100%;
  max-width: 1100px;
}
.team-card {
  position: relative;
  transform: rotate(var(--rot, 0deg));
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.team-card:nth-child(1) { --rot: -2.5deg; }
.team-card:nth-child(2) { --rot: 1.8deg; }
.team-card:nth-child(3) { --rot: -1.2deg; }
.team-card:nth-child(4) { --rot: 2.4deg; }
.team-card:hover { transform: rotate(0deg) translateY(-6px); }

.team-polaroid {
  position: relative;
  aspect-ratio: 600 / 720;
  filter: drop-shadow(0 14px 22px rgba(40,30,0,0.18));
}
.team-polaroid > img.poly-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}
.team-polaroid-photo {
  position: absolute;
  top: 6%;
  left: 7%;
  right: 7%;
  bottom: 30%;
  background: color-mix(in srgb, var(--paper) 60%, white);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  overflow: hidden;
  padding-top: 6%;
}
.team-polaroid-photo img {
  max-width: 70%;
  max-height: 96%;
  height: 96%;
  width: auto;
  object-fit: contain;
  object-position: bottom center;
}
.team-polaroid-tape {
  position: absolute;
  width: 90px;
  height: auto;
  z-index: 3;
  top: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(-50%) rotate(-4deg);
  opacity: 0.95;
}
.team-card:nth-child(2) .team-polaroid-tape { transform: translateX(-50%) translateY(-50%) rotate(7deg); left: 58%; }
.team-card:nth-child(3) .team-polaroid-tape { transform: translateX(-50%) translateY(-50%) rotate(-9deg); left: 42%; }
.team-card:nth-child(4) .team-polaroid-tape { transform: translateX(-50%) translateY(-50%) rotate(3deg); }

/* 폴라로이드 아래에 카드 안 일반 블록으로 — z-index/positioning 충돌 없음 */
.team-name {
  margin-top: 14px;
  text-align: center;
  font-family: var(--hand);
  font-weight: 700;
  font-size: 26px;
  color: var(--ink);
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.team-role {
  margin-top: 6px;
  text-align: center;
  font-family: var(--hand);
  font-weight: 700;
  font-size: 17px;
  color: var(--blue);
  letter-spacing: 0;
  word-break: keep-all;
}

@media (max-width: 1000px) {
  .frame-team-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
}
@media (max-width: 560px) {
  .frame-team-grid { grid-template-columns: 1fr; max-width: 280px; }
}

/* ═══════════════ FOOTER ═══════════════ */
.foot {
  background: var(--ink);
  color: var(--paper);
  padding: 80px 60px 40px;
  position: relative;
  z-index: 3;
}
.foot-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
  padding-bottom: 36px;
  border-bottom: 1px solid color-mix(in srgb, var(--paper) 14%, transparent);
}
.foot-brand img {
  width: 200px;
  height: auto;
  filter: brightness(0) invert(1) sepia(0.06);
}
.foot-brand p {
  margin-top: 14px;
  font-family: var(--hand);
  font-size: 16px;
  color: color-mix(in srgb, var(--paper) 70%, transparent);
  line-height: 1.55;
}
.foot-col h6 {
  font-family: var(--hand);
  font-size: 14px;
  font-weight: 700;
  color: color-mix(in srgb, var(--paper) 55%, transparent);
  margin-bottom: 12px;
  letter-spacing: 0.06em;
}
.foot-col a, .foot-col span {
  display: block;
  font-family: var(--hand);
  font-size: 16px;
  color: color-mix(in srgb, var(--paper) 90%, transparent);
  line-height: 1.7;
}
.foot-col a:hover { color: var(--amber); }
.foot-bottom {
  max-width: 1200px;
  margin: 28px auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--hand);
  font-size: 14px;
  color: color-mix(in srgb, var(--paper) 55%, transparent);
}

@media (max-width: 900px) {
  .foot { padding: 60px 24px 30px; }
  .foot-inner { grid-template-columns: 1fr 1fr; gap: 28px; }
  .foot-brand { grid-column: 1 / -1; }
  .foot-bottom { flex-direction: column; gap: 6px; }
}

/* ═══════════════ 부스 퀴즈 CTA ═══════════════ */
.quiz-cta {
  position: relative;
  padding: 110px 60px 20px;
  display: flex;
  justify-content: center;
  z-index: 2;
}
.quiz-cta-inner {
  position: relative;
  z-index: 1;
  max-width: 700px;
  width: 100%;
  text-align: center;
  background: #fffdf4;
  border: 2.5px solid var(--ink);
  border-radius: 28px;
  padding: 50px 46px 56px;
  box-shadow: 9px 11px 0 var(--paper-shadow);
}
.quiz-cta-badge {
  display: inline-block;
  font-family: var(--hand);
  font-weight: 700;
  font-size: 16px;
  color: var(--paper);
  background: var(--coral);
  padding: 5px 18px;
  border-radius: 999px;
  margin-bottom: 18px;
  transform: rotate(-2.5deg);
}
.quiz-cta-title {
  font-family: var(--hand);
  font-size: clamp(27px, 3.7vw, 42px);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.36;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
}
.quiz-cta-title .accent { color: var(--blue); }
.quiz-cta-sub {
  font-family: var(--hand);
  font-size: 19px;
  color: var(--ink-soft);
  margin-bottom: 32px;
}
.quiz-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 38px;
  background: var(--blue);
  color: #fff;
  border-radius: 999px;
  font-family: var(--hand);
  font-size: 22px;
  font-weight: 700;
  box-shadow: 4px 5px 0 var(--blue-deep);
  transition: transform 0.18s, box-shadow 0.18s, background 0.18s;
}
.quiz-cta-btn span { display: inline-block; transition: transform 0.18s; }
.quiz-cta-btn:hover {
  transform: translateY(-2px);
  background: var(--blue-deep);
  box-shadow: 6px 8px 0 var(--ink);
}
.quiz-cta-btn:hover span { transform: translateX(5px); }
.quiz-cta-doodle {
  position: absolute;
  pointer-events: none;
  user-select: none;
}
.quiz-cta-doodle.qd-star { width: 48px; top: 74px; left: calc(50% - 372px); transform: rotate(-14deg); }
.quiz-cta-doodle.qd-q { width: 62px; bottom: 24px; right: calc(50% - 392px); transform: rotate(11deg); }
.quiz-cta-char {
  position: absolute;
  width: 96px;
  bottom: -6px;
  left: calc(50% - 410px);
  transform: rotate(-5deg);
  pointer-events: none;
  user-select: none;
}
@media (max-width: 860px) {
  .quiz-cta-doodle, .quiz-cta-char { display: none; }
}
@media (max-width: 720px) {
  .quiz-cta { padding: 76px 22px 8px; }
  .quiz-cta-inner { padding: 40px 26px 44px; box-shadow: 6px 7px 0 var(--paper-shadow); }
  .quiz-cta-btn { font-size: 20px; padding: 15px 32px; }
}

/* ═══════════════ 페이지 종료 후 — closing ═══════════════ */
.closing {
  position: relative;
  padding: 120px 60px;
  text-align: center;
  z-index: 2;
}
.closing-title {
  font-family: var(--hand);
  font-size: 58px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
  margin-bottom: 16px;
}
.closing-title .accent { color: var(--blue); }
.closing-sub {
  font-family: var(--hand);
  font-size: 20px;
  color: var(--ink-soft);
  max-width: 520px;
  margin: 0 auto 32px;
}
.closing-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 999px;
  font-family: var(--hand);
  font-size: 20px;
  font-weight: 700;
  transition: transform 0.2s, background 0.2s;
}
.closing-cta:hover {
  transform: translateY(-2px);
  background: var(--blue);
}

/* ═══════════════ 단어 단위 reveal (GSAP 가 제어) ═══════════════ */
.frame-title .w, .frame-sub .w {
  display: inline-block;
  will-change: transform, opacity;
}

/* ═══════════════ 성능 최적화 ═══════════════ */
/* sticky stage 가 paint 영역을 가둠 */
.journey { contain: layout paint; }
.frame { contain: layout paint style; }
/* visibility: hidden 으로 inactive frame 의 paint 비용 차단 */

/* 큰 이미지에서 drop-shadow filter 제거 */
.frame-calendar-visual img.calendar,
.frame-map-stage img.map,
.frame-route-visual img.path,
.frame-product .product-shot img,
.team-polaroid {
  filter: none;
}
.frame-calendar-visual { filter: drop-shadow(0 14px 22px rgba(40,30,0,0.12)); }
.frame-map-stage { filter: drop-shadow(0 14px 22px rgba(40,30,0,0.12)); }

/* phone SVG 들은 매우 무거움 — GPU layer 로 격리 + content-visibility */
.product-shot { contain: layout paint; }

/* ═══════════════ 스크롤 progress 표시 (상단 가는 줄) ═══════════════ */
.scroll-progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), var(--coral));
  z-index: 200;
  pointer-events: none;
  transform-origin: left center;
  transform: scaleX(0);
  will-change: transform;
}

/* ═══════════════ frame 전환을 좀 더 부드럽게 ═══════════════
 * blur filter 는 성능 비싸서 제거. opacity + translateY 만으로 부드럽게. */
.frame {
  transition:
    opacity 0.55s cubic-bezier(0.4, 0, 0.2, 1),
    visibility 0s linear 0.55s,
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateY(28px) scale(0.985);
}
.frame.active {
  transition:
    opacity 0.55s cubic-bezier(0.4, 0, 0.2, 1),
    visibility 0s,
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateY(0) scale(1);
}

/* ═══════════════ 인터랙티브 hover lift ═══════════════ */
.seg {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), padding-left 0.3s ease;
  cursor: default;
}
.seg:hover {
  transform: translateX(4px);
  padding-left: 6px;
}
.frame-alert-points li {
  transition: transform 0.25s ease;
}
.frame-alert-points li:hover {
  transform: translateX(4px);
}

/* ═══════════════ Reduced motion ═══════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}
