/* ═══════════════════════════════════════════════════════════
   RESET & BASE
═══════════════════════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* ── V2 Home palette ── */
  --bg:          #1A1030;
  --surface:     #22133C;
  --surface2:    #2C1A52;
  --purple:      #7C3AED;
  --pink:        #DB2777;
  --text:        #FFFFFF;
  --text2:       #B6A6D6;
  --nav-active:  #DB2777;
  --nav-muted:   #6B5D8B;

  /* ── Per-test theme (overridden by JS) ── */
  --primary:      #7C3AED;
  --accent:       #DB2777;
  --text-color:   #F0EBFF;
  --text-second:  rgba(240,235,255,0.68);
  --card-bg:      rgba(255,255,255,0.08);
  --card-border:  rgba(255,255,255,0.16);

  /* ── Tokens ── */
  --radius:    20px;
  --radius-sm: 12px;
  --ease:      0.22s cubic-bezier(0.4,0,0.2,1);
  --ease-pop:  0.38s cubic-bezier(0.34,1.56,0.64,1);
}

html {
  background: var(--bg);
  font-size: 16px;
  scroll-behavior: smooth;
}

html.reader-active {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  background: #000;
}

body {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  min-height: 100dvh; /* iOS Chrome 동적 뷰포트 적응 */
  -webkit-font-smoothing: antialiased;
}

body.theme-active {
  background: transparent;
  color: var(--text-color);
}

button { font-family: inherit; }

/* ═══════════════════════════════════════════════════════════
   FIXED LAYERS
═══════════════════════════════════════════════════════════ */

/* Subtle noise grain — adds texture on dark home */
.noise-layer {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0; /* iOS <14.5 longhand */
  pointer-events: none;
  z-index: 1;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 300px 300px;
}

/*
  Background layer: JS injects per-test theme gradient here.
  FUTURE: swap background-image to AI-generated image URL.
*/
.bg-image-layer {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0; /* inset: 0 — iOS <14.5 longhand */
  z-index: -1;
  pointer-events: none;
  background-size: cover;
  background-position: center center;
  overflow: hidden;
  transition: background 0.5s ease;
}

.bg-image-layer__pane {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 900ms ease;
  will-change: opacity;
}

.bg-image-layer__pane.is-visible {
  opacity: 1;
}

.reader-scene-backdrop,
.reader-scene-shade {
  pointer-events: none;
}

.reader-scene-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center center;
  opacity: 1;
  visibility: visible;
  transform: none;
  filter: none;
}

.reader-scene-shade {
  display: none;
}

/* 배경 이미지 위에 어두운 오버레이 — 텍스트 가독성 확보
   Problem 3: 야외 가시성 위해 0.62 → 0.40 로 완화 */
.bg-image-layer.has-bg-image::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0; /* iOS <14.5 호환 */
  background:
    linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0.46) 0%,
      rgba(0, 0, 0, 0.36) 38%,
      rgba(0, 0, 0, 0.72) 100%
    );
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════
   FULL-WIDTH PAGE HEADER
   화면 전체 폭으로 깔리는 헤더 — 컨테이너 밖에 렌더링됨
   탐색·카테고리 페이지: position:sticky (스크롤 고정)
   홈 페이지: 일반 흐름 (스크롤과 함께)
═══════════════════════════════════════════════════════════ */
.full-header {
  width: 100%;
  background: #0F0820;
  /* 탐색·카테고리: sticky로 오버라이드 */
  position: relative;
  z-index: 100;
}

.full-header--sticky {
  position: sticky;
  top: 0;
}

.full-header-inner {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 14px;
  gap: 12px;
  min-width: 0;
}

.full-header-actions,
.explore-bar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-shrink: 0;
  min-width: 0;
}

.lomm-account-slot {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.lomm-account-slot:empty {
  display: none;
}

.language-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.language-select__label {
  font-size: 12px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.54);
}

.language-select__control {
  max-width: 128px;
  min-height: 34px;
  padding: 0 30px 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  outline: none;
  cursor: pointer;
}

.language-select__control:focus {
  border-color: rgba(219, 39, 119, 0.75);
  box-shadow: 0 0 0 3px rgba(219, 39, 119, 0.18);
}

.language-select__control option {
  background: #18102C;
  color: #fff;
}

.loading-page {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 24px;
  color: var(--text);
}

.loading-page p {
  color: rgba(255, 255, 255, 0.68);
  font-size: 14px;
  font-weight: 650;
}

@media (min-width: 1024px) {
  .full-header-inner {
    max-width: 1280px;
    padding: 26px 48px 14px;
  }
  /* 홈 헤더 로고 크게 */
  .full-header-inner .v2-logo-icon { width: 38px; height: 38px; border-radius: 10px; }
  .full-header-inner .v2-logo-wordmark { width: 148px; }
  .full-header-inner .v2-logo-text { font-size: 22px; }
  /* 카테고리 헤더 뒤로가기: viewport 좌측 끝으로 (full-header가 position:relative, width:100%) */
  .full-header-inner .sub-back-btn {
    position: absolute;
    left: 24px;
    top: 50%;
    transform: translateY(-50%);
  }
}

@media (max-width: 520px) {
  .full-header-inner {
    gap: 8px;
  }

  .full-header-actions,
  .explore-bar-actions {
    gap: 6px;
  }

  .language-select__label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .language-select__control {
    max-width: 108px;
    min-height: 32px;
    padding-left: 10px;
    font-size: 12px;
  }

  .explore-bar-inner {
    gap: 8px;
    flex-wrap: wrap;
  }

  .explore-bar-inner .search-input-box {
    order: 3;
    flex-basis: 100%;
    min-width: 0;
  }

  .explore-bar-actions {
    margin-left: auto;
  }

  .language-select--explore .language-select__control {
    max-width: 96px;
  }

}

/* ═══════════════════════════════════════════════════════════
   V2 HOME — SHELL
═══════════════════════════════════════════════════════════ */
.v2-home {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  min-height: 100dvh;
  padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); /* clears fixed nav + iOS home indicator */
  max-width: 800px;
  margin: 0 auto;
}

/* ── Legacy header (홈 전체폭 헤더로 대체됨, 하위 호환용) ── */
.v2-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 10px;
}

.v2-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex-shrink: 1;
}

.v2-logo-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: contain;
}

.v2-logo-wordmark {
  display: block;
  width: 128px;
  height: auto;
  max-width: min(36vw, 156px);
  object-fit: contain;
}

.v2-logo-text {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.02em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ── TODAY'S PICK Hero ────────────────────────── */
.hero-section {
  padding: 2px 16px 20px;
}

.hero-card {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  min-height: 214px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: linear-gradient(150deg, var(--h-s, #3D2660) 0%, var(--h-e, #5B3D8B) 100%);
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 18px 48px rgba(0,0,0,0.36);
  cursor: pointer;
  transition: transform var(--ease), border-color var(--ease);
}

.hero-card:hover {
  transform: translateY(-1px);
  border-color: rgba(255,255,255,0.16);
}
.hero-card:active { transform: translateY(0); transition-duration: 0.1s; }

/* Decorative circle */
.hero-card::before {
  content: '';
  position: absolute;
  top: -64px; right: -64px;
  width: 260px; height: 260px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  pointer-events: none;
}

.hero-card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0; /* iOS <14.5 longhand */
  background: linear-gradient(to top, rgba(0,0,0,0.65) 0%, transparent 55%);
  pointer-events: none;
}

.hero-badge {
  position: absolute;
  top: 18px; left: 18px;
  z-index: 1;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  background: rgba(13, 7, 28, 0.62);
  border: 1px solid rgba(255,255,255,0.18);
  color: rgba(255,255,255,0.88);
  padding: 4px 10px;
  border-radius: 20px;
}

.hero-body {
  position: relative;
  z-index: 1;
  padding: 15px 18px 18px;
}

.hero-cat {
  font-size: 10px;
  font-weight: 700;
  color: var(--pink);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.hero-title {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 21px;
  font-weight: 700;
  color: white;
  line-height: 1.3;
  word-break: keep-all;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}

.hero-desc {
  font-size: 12px;
  color: rgba(255,255,255,0.75);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 14px;
  transition: -webkit-line-clamp 0.2s ease;
}

.hero-card.hero-expanded .hero-desc {
  -webkit-line-clamp: unset;
  overflow: visible;
}

.hero-btns {
  display: flex;
  gap: 10px;
  align-items: center;
}

.hero-btn-primary {
  background: linear-gradient(90deg, rgba(124,58,237,0.96) 0%, rgba(236,72,153,0.92) 100%);
  color: white;
  border: none;
  border-radius: 24px;
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: filter var(--ease), transform var(--ease);
  letter-spacing: 0.01em;
}

.hero-btn-primary:hover { filter: brightness(1.12); transform: translateY(-1px); }
.hero-btn-primary:active { transform: translateY(0); transition-duration: 0.1s; }

.hero-btn-info {
  background: transparent;
  color: rgba(255,255,255,0.82);
  border: 1.5px solid rgba(255,255,255,0.42);
  border-radius: 24px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color var(--ease), background var(--ease);
}

.hero-btn-info:hover {
  border-color: rgba(255,255,255,0.72);
  background: rgba(255,255,255,0.06);
}

/* 데스크탑 가로형 레이아웃용 우측 영역 — 모바일에서는 숨김 */
.hero-visual { display: none; }

/* ── WEEKLY PICK — 배경 이미지 통합 ──────────── */

/* 이미지가 카드 전체를 채움
   z-index 스태킹: img(1) → ::after scrim(2) → hero-badge/hero-body(이미 z-index:1이지만 위) */
.hero-bg-img {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0; /* 구형 iOS 호환 */
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  z-index: 1;
  display: block;
  pointer-events: none;
}

/* 데코 원 숨김 (이미지와 충돌) */
.hero-card--has-bg::before {
  display: none;
}

/* scrim이 이미지 위에 오도록 */
.hero-card--has-bg::after {
  z-index: 2;
}

/* 모바일: 위→아래 그라데이션
   상단은 이미지가 보이고, 하단(텍스트 영역)은 어두워짐 */
.hero-card--has-bg::after {
  background: linear-gradient(
    to top,
    rgba(10, 5, 25, 0.97) 0%,
    rgba(10, 5, 25, 0.75) 35%,
    rgba(10, 5, 25, 0.18) 62%,
    transparent 100%
  );
}

/* hero-badge, hero-body가 scrim 위에 오도록 */
.hero-card--has-bg .hero-badge,
.hero-card--has-bg .hero-body {
  z-index: 3;
}

/* ── Home Main ─────────────────────────────────── */
.home-main {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding-bottom: 8px;
}

/* ── Section Head ──────────────────────────────── */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0 16px;
  margin-bottom: 10px;
}

.section-title {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
}

.section-subtitle {
  margin: 4px 0 0;
  color: var(--text2);
  font-size: 12px;
  line-height: 1.35;
}

.section-more {
  font-size: 13px;
  color: var(--text2);
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
  transition: color var(--ease);
}
.section-more:hover { color: var(--text); }

/* ── Scroll Wrapper (arrow buttons sit outside the flow) ── */
.scroll-wrap {
  position: relative;
}

.scroll-arrow {
  display: none; /* visible only on desktop via media query */
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(15,8,32,0.88);
  border: 1px solid rgba(255,255,255,0.18);
  color: white;
  font-size: 18px;
  line-height: 1;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background var(--ease);
}
.scroll-arrow:hover { background: rgba(124,58,237,0.65); }
.scroll-arrow-left  { left:  4px; }
.scroll-arrow-right { right: 4px; }

@media (min-width: 600px) {
  .scroll-arrow { display: flex; }
}

/* ── Horizontal Scroll Row ─────────────────────── */
/* overflow-x: scroll → 카드 수와 무관하게 일관된 padding-left
   scroll-padding-left → scroll-snap이 padding 안쪽을 스냅 기준으로 삼도록 명시 */
.scroll-row {
  display: flex;
  justify-content: flex-start;
  gap: 12px;
  overflow-x: scroll;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  scroll-padding-left: 16px;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 6px 16px 10px;
}
.scroll-row::-webkit-scrollbar { display: none; }

/* ── V2 Cards — 130 × 175 ──────────────────────── */
.v2-card {
  position: relative;
  width: 130px;
  height: 175px;
  border-radius: 14px;
  overflow: hidden;
  flex-shrink: 0;
  cursor: pointer;
  scroll-snap-align: start;
  box-shadow: 0 4px 18px rgba(0,0,0,0.45);
  transition: transform var(--ease-pop), box-shadow var(--ease);
}

.v2-card:hover {
  transform: translateY(-5px) scale(1.03);
  box-shadow: 0 10px 32px rgba(0,0,0,0.55);
}
.v2-card:active { transform: translateY(-2px) scale(1.01); transition-duration: 0.1s; }

/* Gradient background layer */
.v2-card-bg {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0; /* inset: 0 — iOS <14.5 longhand */
  background: linear-gradient(160deg, var(--c-s, #3D2660) 0%, var(--c-e, #5B3D8B) 100%);
}

/* Decorative circle in top-right */
.v2-card-bg::before {
  content: '';
  position: absolute;
  top: -26px; right: -26px;
  width: 90px; height: 90px;
  border-radius: 50%;
  background: rgba(255,255,255,0.07);
}

/* Bottom scrim for text legibility */
.v2-card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0; /* iOS <14.5 longhand */
  background: linear-gradient(to top, rgba(0,0,0,0.76) 0%, transparent 56%);
  pointer-events: none;
}

/* 썸네일 이미지가 있는 카드:
   img(z-index:1) → ::after scrim(z-index:2) → v2-card-body(z-index:3) 순서 */
.v2-card--has-img .v2-card-img {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  z-index: 1;
  /* iOS 렌더링 버그 방지: GPU 합성 레이어 강제 */
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
  will-change: transform;
}

/* scrim이 이미지 위에 오도록 z-index 명시 */
.v2-card--has-img::after {
  z-index: 2;
}

/* 텍스트가 scrim 위에 오도록 */
.v2-card--has-img .v2-card-body {
  z-index: 3;
}

.v2-card-body {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 10px 10px 12px;
  z-index: 1;
}

.v2-card-cat {
  display: block;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--pink);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.v2-card-age-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 4px 7px;
  border-radius: 999px;
  background: rgba(18, 20, 28, .82);
  border: 1px solid rgba(255,255,255,.22);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 5px;
}

.v2-card-title {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: white;
  line-height: 1.45;
  word-break: keep-all;
  letter-spacing: -0.01em;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.service-footer--home {
  margin: 8px 16px 0;
  padding: 24px 0 20px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

/* ── Home curated carousels ───────────────────── */
.home-recent-slot:empty {
  display: none;
}

.home-carousel .scroll-row {
  overflow-x: auto;
  scroll-behavior: smooth;
  overscroll-behavior-inline: contain;
}

.story-carousel-row {
  align-items: stretch;
}

.story-carousel-item {
  position: relative;
  flex: 0 0 auto;
  scroll-snap-align: start;
}

.story-carousel-row .v2-card {
  width: 210px;
  height: 280px;
}

.recent-play-section .story-carousel-row .v2-card {
  width: 150px;
  height: 202px;
}

.recent-play-section .section-head,
.home-story-list-section .section-head {
  width: calc(100% - 32px);
  max-width: 1184px;
  margin: 0 auto 8px;
  padding: 0;
}

.recent-resume-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  width: calc(100% - 32px);
  max-width: 1184px;
  margin: 0 auto;
}

.recent-resume-item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 108px;
  padding: 10px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255,255,255,0.065), rgba(255,255,255,0.025));
  cursor: pointer;
  overflow: hidden;
  transition: background var(--ease), border-color var(--ease), transform var(--ease);
}

.recent-resume-item:hover {
  background: linear-gradient(135deg, rgba(255,255,255,0.09), rgba(255,255,255,0.035));
  border-color: rgba(255,255,255,0.16);
  transform: translateY(-1px);
}

.recent-resume-item:focus-visible {
  outline: 1px solid rgba(255,255,255,0.30);
  outline-offset: 2px;
}

.recent-resume-thumb {
  position: relative;
  flex: 0 0 58px;
  width: 58px;
  aspect-ratio: 130 / 175;
  border-radius: 8px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--c-s, #3D2660) 0%, var(--c-e, #5B3D8B) 100%);
}

.recent-resume-thumb::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.36), transparent 60%);
  pointer-events: none;
}

.recent-resume-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.recent-resume-copy {
  flex: 1 1 auto;
  min-width: 0;
}

.recent-resume-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px 7px;
  margin-bottom: 5px;
  color: rgba(255,255,255,0.48);
  font-size: 10px;
  font-weight: 650;
  line-height: 1.25;
}

.recent-resume-meta span:first-child {
  color: var(--pink);
}

.recent-resume-title {
  margin: 0 0 5px;
  color: #fff;
  font-size: 14px;
  font-weight: 740;
  line-height: 1.3;
  letter-spacing: 0;
  word-break: keep-all;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.recent-resume-note {
  margin: 0;
  color: var(--text2);
  font-size: 11px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.recent-resume-action {
  flex: 0 0 auto;
  align-self: center;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.86);
  padding: 7px 10px;
  font-size: 11px;
  font-weight: 720;
  white-space: nowrap;
}

.home-story-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  width: calc(100% - 32px);
  max-width: 1184px;
  margin: 0 auto;
  padding: 0;
}

.home-story-list-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 96px;
  padding: 9px;
  border: 1px solid rgba(255,255,255,0.075);
  border-radius: 12px;
  background: rgba(255,255,255,0.028);
  cursor: pointer;
  overflow: hidden;
  transition: background var(--ease), border-color var(--ease), transform var(--ease);
}

.home-story-list-item:hover {
  background: rgba(255,255,255,0.052);
  border-color: rgba(255,255,255,0.12);
  transform: translateY(-1px);
}

.home-story-list-item:focus-visible {
  outline: 1px solid rgba(255,255,255,0.24);
  outline-offset: 2px;
  background: rgba(255,255,255,0.052);
}

.home-story-list-thumb {
  position: relative;
  flex: 0 0 56px;
  width: 56px;
  aspect-ratio: 130 / 175;
  min-height: 75px;
  border-radius: 8px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--c-s, #3D2660) 0%, var(--c-e, #5B3D8B) 100%);
}

.home-story-list-thumb::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.34), transparent 62%);
  pointer-events: none;
}

.home-story-list-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.home-story-list-copy {
  flex: 1 1 auto;
  min-width: 0;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1px 0;
}

.home-story-list-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  margin-bottom: 4px;
  color: var(--pink);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0;
  text-transform: uppercase;
}

.home-story-list-age {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 5px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 999px;
  background: rgba(18,20,28,0.72);
  color: #fff;
  font-size: 9px;
  line-height: 1;
}

.home-story-list-title {
  margin: 0 0 4px;
  color: #fff;
  font-size: 13px;
  font-weight: 720;
  line-height: 1.35;
  letter-spacing: 0;
  word-break: keep-all;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.home-story-list-desc {
  margin: 0;
  color: var(--text2);
  font-size: 11px;
  line-height: 1.45;
  word-break: keep-all;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.home-story-list-chevron {
  flex: 0 0 auto;
  align-self: center;
  margin-left: auto;
  color: rgba(255,255,255,0.16);
  font-size: 15px;
  line-height: 1;
}

.home-mood-section .section-head {
  width: calc(100% - 32px);
  max-width: 1184px;
  margin: 0 auto 6px;
  padding: 0;
}

.home-mood-chip-row {
  display: flex;
  gap: 8px;
  width: calc(100% - 32px);
  max-width: 1184px;
  margin: 0 auto;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 0 0 6px;
  scroll-padding-left: 0;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.home-mood-chip-row::-webkit-scrollbar {
  display: none;
}

.home-mood-chip {
  flex: 0 0 auto;
  min-height: 44px;
  max-width: 150px;
  padding: 0 14px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 999px;
  background: rgba(255,255,255,0.035);
  color: rgba(255,255,255,0.72);
  font: inherit;
  font-size: 12px;
  font-weight: 720;
  letter-spacing: 0;
  white-space: nowrap;
  cursor: pointer;
  transition: background var(--ease), border-color var(--ease), color var(--ease);
}

.home-mood-chip.is-active {
  border-color: rgba(255,255,255,0.22);
  background: rgba(255,255,255,0.10);
  color: #fff;
}

.home-mood-chip:focus-visible {
  outline: 1px solid rgba(255,255,255,0.34);
  outline-offset: 2px;
}

.home-mood-panels {
  width: calc(100% - 32px);
  max-width: 1184px;
  margin: 4px auto 0;
}

.home-mood-panel {
  display: none;
  visibility: hidden;
  pointer-events: none;
}

.home-mood-panel.is-active {
  display: block;
  visibility: visible;
  pointer-events: auto;
  animation: homeMoodPanelIn 180ms ease-out both;
}

.home-mood-layout {
  display: grid;
  gap: 9px;
}

.home-mood-feature,
.home-mood-secondary {
  position: relative;
  border: 1px solid rgba(255,255,255,0.085);
  background: rgba(255,255,255,0.03);
  cursor: pointer;
  overflow: hidden;
  transition: background var(--ease), border-color var(--ease), transform var(--ease);
}

.home-mood-feature:hover,
.home-mood-secondary:hover {
  border-color: rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.055);
  transform: translateY(-1px);
}

.home-mood-feature:focus-visible,
.home-mood-secondary:focus-visible {
  outline: 1px solid rgba(255,255,255,0.26);
  outline-offset: 2px;
}

.home-mood-feature {
  min-height: clamp(236px, 58vw, 300px);
  border-radius: 14px;
  background: linear-gradient(155deg, var(--m-s, #141018) 0%, var(--m-e, #221827) 100%);
}

.home-mood-feature-media {
  position: absolute;
  inset: 0;
  background: linear-gradient(155deg, var(--m-s, #141018) 0%, var(--m-e, #221827) 100%);
  pointer-events: none;
  overflow: hidden;
}

.home-mood-feature--poster-fallback .home-mood-feature-media {
  display: flex;
  align-items: center;
  justify-content: center;
}

.home-mood-feature-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  pointer-events: none;
}

.home-mood-feature-backdrop,
.home-mood-feature-poster {
  pointer-events: none;
}

.home-mood-feature-backdrop {
  position: absolute;
  inset: -16px;
  width: calc(100% + 32px);
  height: calc(100% + 32px);
  display: block;
  object-fit: cover;
  object-position: center;
  filter: blur(22px) brightness(0.55);
  transform: scale(1.08);
}

.home-mood-feature-poster {
  position: relative;
  z-index: 1;
  display: block;
  width: auto;
  max-width: 42%;
  height: 88%;
  max-height: 88%;
  margin: auto;
  object-fit: contain;
  object-position: center;
}

.home-mood-feature-media::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgba(7,5,10,0.94) 0%, rgba(7,5,10,0.66) 36%, rgba(7,5,10,0.10) 72%, transparent 100%),
    linear-gradient(to right, rgba(7,5,10,0.28), transparent 54%);
  pointer-events: none;
}

.home-mood-feature-copy {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  z-index: 1;
  display: grid;
  gap: 5px;
}

.home-mood-feature-copy span,
.home-mood-secondary-copy span {
  color: var(--pink);
  font-size: 10px;
  font-weight: 760;
  line-height: 1.2;
  letter-spacing: 0;
}

.home-mood-feature-copy h3 {
  margin: 0;
  color: #fff;
  font-size: 19px;
  font-weight: 770;
  line-height: 1.25;
  letter-spacing: 0;
  word-break: keep-all;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.home-mood-feature-copy p {
  margin: 0;
  max-width: 46ch;
  color: rgba(255,255,255,0.76);
  font-size: 12px;
  line-height: 1.45;
  word-break: keep-all;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.home-mood-feature-copy small {
  width: fit-content;
  margin-top: 3px;
  color: rgba(255,255,255,0.72);
  font-size: 11px;
  font-weight: 730;
}

.home-mood-secondary-list {
  display: grid;
  gap: 8px;
}

.home-mood-secondary {
  display: flex;
  align-items: center;
  min-height: 92px;
  gap: 10px;
  padding: 9px;
  border-radius: 12px;
}

.home-mood-secondary-thumb {
  position: relative;
  flex: 0 0 56px;
  width: 56px;
  aspect-ratio: 130 / 175;
  min-height: 75px;
  border-radius: 8px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--c-s, #3D2660) 0%, var(--c-e, #5B3D8B) 100%);
  pointer-events: none;
}

.home-mood-secondary-thumb img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center top;
  pointer-events: none;
}

.home-mood-secondary-thumb::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.34), transparent 62%);
  pointer-events: none;
}

.home-mood-secondary-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.home-mood-secondary-copy strong {
  color: #fff;
  font-size: 13px;
  font-weight: 730;
  line-height: 1.35;
  letter-spacing: 0;
  word-break: keep-all;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.home-mood-secondary-copy p {
  margin: 0;
  color: var(--text2);
  font-size: 11px;
  line-height: 1.45;
  word-break: keep-all;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@keyframes homeMoodPanelIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── Popular Section — Netflix-style numbered ── */
.popular-row {
  display: flex;
  justify-content: flex-start;
  gap: 4px;
  overflow-x: scroll;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  scroll-padding-left: 16px;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 6px 16px 10px;
}

.popular-row::-webkit-scrollbar { display: none; }

.popular-item {
  display: flex;
  align-items: flex-end;
  flex-shrink: 0;
  scroll-snap-align: start;
}

/* Large hollow rank number behind card */
.rank-num {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-weight: 800;
  font-size: 88px;
  line-height: 0.85;
  color: transparent;
  -webkit-text-stroke: 2px rgba(255,255,255,0.20);
  width: 52px;
  text-align: right;
  flex-shrink: 0;
  z-index: 0;
  user-select: none;
  padding-bottom: 12px; /* aligns baseline with card bottom */
}

/* Card overlaps the number slightly */
.popular-item .v2-card {
  margin-left: -12px;
  z-index: 1;
  position: relative;
}

.minigame-section {
  padding-top: 0;
}

.minigame-section .section-head {
  margin-bottom: 6px;
}

.minigame-section .section-title {
  font-size: 15px;
  font-weight: 650;
  color: rgba(255,255,255,0.86);
}

.minigame-section .section-subtitle,
.minigame-section .section-more {
  font-size: 11px;
}

.minigame-row {
  gap: 10px;
  padding-top: 4px;
  padding-bottom: 8px;
}

.minigame-row .v2-card {
  width: 88px;
  height: 116px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.30);
}

.minigame-row .v2-card-body {
  padding: 8px;
}

.minigame-row .v2-card-title {
  font-size: 10px;
  line-height: 1.35;
  -webkit-line-clamp: 2;
}

.v2-card-status {
  display: block;
  width: fit-content;
  margin: 0 0 5px;
  padding: 4px 7px;
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 999px;
  background: rgba(8,3,18,0.76);
  color: rgba(255,255,255,0.92);
  font-size: 10px;
  font-weight: 750;
  line-height: 1;
}

.home-carousel .scroll-arrow {
  display: none;
}

.home-carousel .scroll-arrow:disabled {
  opacity: 0;
  pointer-events: none;
}

@media (min-width: 600px) {
  .home-carousel.is-scrollable .scroll-arrow {
    display: flex;
  }
}

@media (min-width: 768px) {
  .story-carousel-row .v2-card {
    width: 230px;
    height: 306px;
  }

  .recent-play-section .story-carousel-row .v2-card {
    width: 170px;
    height: 226px;
  }

  .recent-resume-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .recent-resume-item {
    min-height: 112px;
    padding: 11px;
  }

  .recent-resume-thumb {
    flex-basis: 62px;
    width: 62px;
  }

  .home-story-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }

  .home-story-list-item {
    min-height: 106px;
    padding: 10px;
  }

  .home-story-list-thumb {
    flex-basis: 60px;
    width: 60px;
    min-height: 81px;
  }

  .home-mood-chip-row {
    padding-bottom: 8px;
  }

  .home-mood-layout {
    grid-template-columns: minmax(0, 1.7fr) minmax(232px, 1fr);
    min-height: 350px;
    align-items: stretch;
  }

  .home-mood-feature {
    min-height: 100%;
  }

  .home-mood-feature-copy {
    left: 18px;
    right: 18px;
    bottom: 18px;
  }

  .home-mood-feature-copy h3 {
    font-size: 22px;
  }

  .home-mood-feature-copy p {
    font-size: 13px;
  }

  .home-mood-secondary-list {
    grid-template-rows: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .home-mood-secondary {
    min-height: 0;
    padding: 10px;
  }

  .home-mood-secondary-thumb {
    flex-basis: 62px;
    width: 62px;
    min-height: 84px;
  }

  .minigame-row {
    gap: 12px;
  }

  .minigame-row .v2-card {
    width: 96px;
    height: 126px;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .rank-num {
    width: 58px;
    font-size: 96px;
  }

  .popular-row {
    gap: 4px;
  }
}

@media (min-width: 1024px) {
  .story-carousel-row .v2-card {
    width: 260px;
    height: 346px;
  }

  .recent-play-section .story-carousel-row .v2-card {
    width: 190px;
    height: 253px;
  }

  .recent-resume-item {
    min-height: 118px;
    padding: 12px 14px;
    gap: 13px;
  }

  .recent-resume-thumb {
    flex-basis: 66px;
    width: 66px;
  }

  .recent-resume-title {
    font-size: 15px;
  }

  .recent-resume-note {
    font-size: 12px;
  }

  .recent-resume-action {
    padding: 8px 12px;
    font-size: 12px;
  }

  .home-story-list {
    gap: 12px;
  }

  .home-story-list-item {
    min-height: 112px;
    padding: 11px;
    gap: 11px;
  }

  .home-story-list-thumb {
    flex-basis: 64px;
    width: 64px;
    min-height: 86px;
  }

  .home-mood-layout {
    grid-template-columns: minmax(0, 1.85fr) minmax(280px, 1fr);
    min-height: 392px;
    gap: 12px;
  }

  .home-mood-feature-copy {
    left: 22px;
    right: 22px;
    bottom: 22px;
  }

  .home-mood-feature-copy h3 {
    font-size: 25px;
  }

  .home-mood-feature-copy p {
    max-width: 58ch;
    font-size: 14px;
    -webkit-line-clamp: 2;
  }

  .home-mood-secondary {
    gap: 12px;
    padding: 12px;
  }

  .home-mood-secondary-thumb {
    flex-basis: 74px;
    width: 74px;
    min-height: 100px;
  }

  .home-mood-secondary-copy strong {
    font-size: 15px;
  }

  .home-mood-secondary-copy p {
    font-size: 12px;
  }

  .home-story-list-copy {
    max-width: 100%;
  }

  .home-story-list-title {
    font-size: 14px;
  }

  .home-story-list-desc {
    font-size: 12px;
    line-height: 1.45;
  }

  .home-story-list-chevron {
    font-size: 16px;
  }

  .minigame-row .v2-card {
    width: 104px;
    height: 136px;
  }
}

@media (min-width: 1280px) {
  .story-carousel-row .v2-card {
    width: 280px;
    height: 373px;
  }

  .recent-play-section .story-carousel-row .v2-card {
    width: 190px;
    height: 253px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-mood-panel.is-active {
    animation: none;
  }

  .home-mood-chip,
  .home-mood-feature,
  .home-mood-secondary {
    transition: none;
  }
}

/* ── Bottom Nav Bar ────────────────────────────── */
.v2-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(8,3,18,0.96);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-top: 1px solid rgba(255,255,255,0.07);
  display: flex;
  justify-content: space-around;
  align-items: stretch;
  padding: 6px 0 env(safe-area-inset-bottom, 6px);
}

body.lomm-overlay-open .v2-nav {
  display: none;
}

/* On wide screens, keep nav within 800px */
@media (min-width: 800px) {
  .v2-nav {
    max-width: 800px;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    border-radius: 20px 20px 0 0;
  }
}

.v2-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  flex: 1;
  background: none;
  border: none;
  padding: 6px 12px;
  min-width: 64px;
  font-family: inherit;
  cursor: pointer;
  transition: opacity var(--ease);
}
.v2-nav-btn:active { opacity: 0.7; }

.nav-icon {
  width: 22px; height: 22px;
  fill: none;
  stroke: var(--nav-muted);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke var(--ease);
  display: block;
}

.v2-nav-btn.is-active .nav-icon { stroke: var(--nav-active); }

.nav-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--nav-muted);
  letter-spacing: 0.02em;
  transition: color var(--ease);
}
.v2-nav-btn.is-active .nav-label { color: var(--nav-active); }

/* ── Empty State ────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 80px 20px;
  color: var(--text2);
}
.empty-emoji { font-size: 56px; margin-bottom: 16px; }
.empty-state p { font-size: 15px; line-height: 1.8; }
.empty-hint { font-size: 13px; margin-top: 6px; font-style: italic; }

/* ═══════════════════════════════════════════════════════════
   검색창 (탐색 페이지)
═══════════════════════════════════════════════════════════ */
.search-wrap {
  padding: 10px 16px 4px;
  /* 탐색 페이지에서는 explore-bar가 대체 — 레거시 보존 */
}

.search-input-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 1.5px solid rgba(255, 255, 255, 0.10);
  border-radius: 14px;
  padding: 12px 16px;
  transition: border-color var(--ease);
}

.search-input-box:focus-within {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18);
}

.search-icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: var(--text2);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.search-input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 15px;
  color: var(--text);
  caret-color: var(--purple);
  min-width: 0;
}

.search-input::placeholder { color: var(--nav-muted); }

/* 브라우저 기본 clear 버튼 제거 (자체 UX 사용) */
.search-input::-webkit-search-cancel-button { display: none; }

/* ── 탐색 바 ("← 홈" + 검색창 한 줄) ──────────
   본문과 동일 배경 — 별도 헤더 구분 없이 자연스럽게 */
.explore-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  width: 100%;
  background: var(--bg);   /* 본문과 동일 배경색 */
}

.explore-bar-inner {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  padding: 10px 16px;
  gap: 10px;
  min-width: 0;
}

/* 검색창: 남은 공간 모두 채움 — 오른쪽 끝이 그리드 오른쪽과 일치 */
.explore-bar-inner .search-input-box {
  flex: 1;
  margin: 0;
  min-width: 120px;
}

@media (min-width: 1024px) {
  .explore-bar-inner {
    max-width: 1280px;
    padding: 12px 48px;
  }
  /* 데스크탑: 버튼을 viewport 좌측 끝으로 (explore-bar가 full-width sticky이므로 left=24px = 화면 좌측 24px) */
  .explore-bar-inner .sub-back-btn {
    position: absolute;
    left: 24px;
    top: 50%;
    transform: translateY(-50%);
    margin: 0;
  }
}

/* ── 검색 결과 영역 ──────────────────────────── */
.explore-results {
  padding: 8px 16px 12px;
}

.search-count {
  font-size: 12px;
  color: var(--text2);
  margin-bottom: 12px;
  padding: 0 2px;
}

/* 결과 그리드 — 카드 동일 디자인 유지 */
.search-result-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

/* 그리드 안 카드: 열 너비 채움 */
.search-result-grid .v2-card {
  width: 100%;
  height: 160px;
  flex-shrink: unset;
  scroll-snap-align: none;
}

/* 검색 결과 없음 */
.search-empty {
  padding: 48px 0 32px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.search-empty-msg {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.search-empty-hint {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.6;
}

.search-empty-browse {
  margin-top: 16px;
  background: rgba(124, 58, 237, 0.20);
  border: 1.5px solid rgba(124, 58, 237, 0.40);
  color: var(--text);
  border-radius: 24px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background var(--ease);
}
.search-empty-browse:hover { background: rgba(124, 58, 237, 0.32); }

/* 데스크탑 검색 */
@media (min-width: 768px) {
  .search-result-grid { grid-template-columns: repeat(3, 1fr); }
  .search-result-grid .v2-card { height: 180px; }
  .search-wrap      { padding: 14px 48px 4px; }
  .explore-results  { padding: 8px 48px 12px; }
}

@media (min-width: 1024px) {
  .search-result-grid { grid-template-columns: repeat(4, 1fr); }
  .search-result-grid .v2-card { height: 200px; }
}

/* ═══════════════════════════════════════════════════════════
   STORY PAGE — 인터랙티브 픽션 (타이프라이터 + 다음 버튼)
═══════════════════════════════════════════════════════════ */

/* 전체 화면 — 메인 배경 위에 어두운 오버레이로 영화 분위기 */
.story-page {
  --story-text: #F3F3F0;
  --story-muted: rgba(255,255,255,0.72);
  --story-accent: #C9C2B8;
  --story-danger: #8E5A5A;
  --story-button-bg: rgba(10,10,12,0.72);
  --story-button-bg-hover: rgba(33,33,35,0.82);
  --story-button-border: rgba(255,255,255,0.12);
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 2;
  background: rgba(0, 0, 0, 0.24);  /* 메인 배경보다 살짝 어둡게 */
}

/* 텍스트 영역 — 세로 가운데 정렬, 클릭으로 타이핑 스킵 */
.story-body {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 28px;
  cursor: pointer;   /* "클릭하면 건너뛰기" 신호 */
  width: 100%;
}

.story-page:focus,
.story-page:focus-visible,
.story-body:focus,
.story-body:focus-visible,
.story-text:focus,
.story-text:focus-visible {
  outline: none;
}

/* 스토리 텍스트 — 큰 글씨, 가운데 정렬, Pretendard 500 */
.story-text {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 20px;
  font-weight: 500;
  line-height: 1.85;
  color: var(--story-text);
  text-align: center;
  word-break: keep-all;
  overflow-wrap: normal;
  line-break: strict;
  text-wrap: pretty;
  letter-spacing: 0;
  max-width: 520px;
  width: 100%;
  /* 문제 3: 야외 가독성 */
  text-shadow: 0 2px 10px rgba(0,0,0,0.8);
}

/* 타이핑 중 커서 깜빡임 */
.story-text::after {
  content: '▋';
  font-size: 0.85em;
  color: var(--story-accent);
  animation: story-cursor 0.8s step-end infinite;
  display: inline;
  vertical-align: -0.05em;
  margin-left: 2px;
}

/* 타이핑 완료 → 커서 숨김 */
.story-text.typing-done::after {
  display: none;
}

@keyframes story-cursor {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* 하단 버튼 영역 */
.story-footer {
  padding: 20px 24px 52px;
  display: flex;
  justify-content: center;
}

.story-footer[hidden],
#if-choices[hidden] {
  display: none !important;
  height: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

.story-footer--continue {
  position: relative;
  z-index: 3;
}

.story-footer--choices {
  pointer-events: auto;
}

/* "다음 ▶" / "질문으로 ▶" 버튼 — 타이핑 끝나야 페이드인 */
.story-next-btn {
  background: var(--story-button-bg);
  color: var(--story-text);
  border: 1px solid var(--story-button-border);
  border-radius: 28px;
  padding: 14px 40px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  min-height: 44px;
  position: relative;
  z-index: 1;
  pointer-events: auto;
  touch-action: manipulation;
  font-family: inherit;
  letter-spacing: 0;
  box-shadow: 0 14px 36px rgba(0,0,0,0.28);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  /* opacity는 JS에서 제어 (0→1 페이드인) */
  transition: opacity 0.4s ease, background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.story-next-btn:hover  {
  background: var(--story-button-bg-hover);
  border-color: rgba(255,255,255,0.22);
  transform: translateY(-2px);
}
.story-next-btn:active { transform: translateY(0); transition-duration: 0.08s; }
.story-next-btn:focus:not(:focus-visible) { outline: none; }
.story-next-btn:focus-visible {
  outline: 2px solid var(--story-accent);
  outline-offset: 3px;
}

@media (min-width: 600px) {
  .story-text { font-size: 22px; }
  .story-next-btn { padding: 15px 52px; font-size: 17px; }
}

@media (max-width: 768px) {
  .bg-image-layer__pane {
    background-size: cover;
  }

  .bg-image-layer.has-bg-image::after {
    background:
      linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.58) 0%,
        rgba(0, 0, 0, 0.46) 34%,
        rgba(0, 0, 0, 0.84) 100%
      );
  }

  .story-page {
    min-height: 100dvh;
    background:
      linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.14) 0%,
        rgba(0, 0, 0, 0.22) 46%,
        rgba(0, 0, 0, 0.42) 100%
      );
  }

  .story-body {
    align-items: center;
    padding: 76px 20px 28px;
  }

  .story-text {
    max-width: 92vw;
    font-size: 18px;
    line-height: 1.78;
    text-shadow: 0 2px 14px rgba(0,0,0,0.92);
  }

  .story-footer {
    padding: 16px 18px 34px;
  }
}

/* 후속 스토리(response) — 선택 직후, 좌측에 미묘한 accent 라인으로 차별화 */
.story-page--response .story-text {
  border-left: 3px solid rgba(201,194,184,0.46);
  padding-left: 20px;
  text-align: left;
}

.story-page .back-btn {
  color: var(--story-text);
  background: rgba(10,10,12,0.54);
  border-color: rgba(255,255,255,0.12);
}

.story-page .back-btn:hover {
  background: rgba(32,32,34,0.68);
  opacity: 1;
}

.story-page .test-counter {
  color: var(--story-muted);
}

.story-page .progress-track {
  background: rgba(255,255,255,0.12);
}

.story-page .progress-fill {
  background: var(--story-accent);
  box-shadow: 0 0 8px rgba(201,194,184,0.35);
}

.story-page .option-btn {
  background: rgba(10,10,12,0.66);
  border-color: rgba(255,255,255,0.14);
  color: var(--story-text);
  letter-spacing: 0;
}

.story-page .option-btn:hover:not(:disabled) {
  background: rgba(33,33,35,0.78);
  border-color: rgba(201,194,184,0.46);
}

.story-page .option-btn.selected {
  background: rgba(142,90,90,0.42);
  border-color: rgba(201,194,184,0.28);
  color: var(--story-text);
}

/* Reader viewport: keep the interactive-fiction stage inside the visual viewport. */
body.reader-active {
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  overscroll-behavior: none;
  background: #000;
}

body.reader-active #app {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  min-width: 0;
  overflow: hidden;
  background: transparent;
}

body.reader-active #laxxm-support-widget {
  display: none !important;
}

body.reader-active .bg-image-layer {
  z-index: 0;
  height: 100vh;
  height: 100dvh;
}

body.reader-active .bg-image-layer__pane[data-reader-scene-src] {
  background-image: none !important;
}

body.reader-active .story-page {
  width: 100%;
  max-width: none;
  height: 100vh;
  height: 100dvh;
  min-height: 0;
  overflow: hidden;
}

body.reader-active .story-page .test-header {
  flex: 0 0 auto;
  min-width: 0;
  padding-top: max(18px, env(safe-area-inset-top, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
  padding-left: max(20px, env(safe-area-inset-left, 0px));
}

body.reader-active .story-page .back-btn {
  flex: 0 0 auto;
  white-space: nowrap;
}

body.reader-active .story-page .test-counter {
  flex: 1 1 auto;
  min-width: 0;
  padding-left: 12px;
  overflow: hidden;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.reader-active .story-body {
  min-width: 0;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: max(20px, env(safe-area-inset-right, 0px));
  padding-left: max(20px, env(safe-area-inset-left, 0px));
}

body.reader-active .story-footer {
  flex: 0 0 auto;
  max-height: 48dvh;
  overflow-x: hidden;
  overflow-y: auto;
  padding-right: max(18px, env(safe-area-inset-right, 0px));
  padding-bottom: max(22px, calc(env(safe-area-inset-bottom, 0px) + 12px));
  padding-left: max(18px, env(safe-area-inset-left, 0px));
  overscroll-behavior: contain;
}

@media (orientation: landscape) and (max-height: 500px) {
  body.reader-active .story-page .test-header {
    padding-top: max(8px, env(safe-area-inset-top, 0px));
    padding-right: max(16px, env(safe-area-inset-right, 0px));
    padding-bottom: 6px;
    padding-left: max(16px, env(safe-area-inset-left, 0px));
  }

  body.reader-active .story-page .back-btn {
    padding: 6px 13px;
    font-size: 12px;
  }

  body.reader-active .story-page .test-counter {
    font-size: 12px;
  }

  body.reader-active .story-body {
    align-items: center;
    padding-top: 10px;
    padding-right: max(24px, env(safe-area-inset-right, 0px));
    padding-bottom: 8px;
    padding-left: max(24px, env(safe-area-inset-left, 0px));
  }

  body.reader-active .story-text {
    max-width: min(720px, 86vw);
    font-size: 16px;
    line-height: 1.55;
  }

  body.reader-active .story-footer {
    max-height: 44dvh;
    padding-top: 8px;
    padding-right: max(18px, env(safe-area-inset-right, 0px));
    padding-bottom: max(10px, calc(env(safe-area-inset-bottom, 0px) + 8px));
    padding-left: max(18px, env(safe-area-inset-left, 0px));
  }

  body.reader-active .story-next-btn {
    padding: 10px 28px;
    font-size: 14px;
  }
}

/*
  A visible choice list is a separate Reader layout state on short mobile
  landscape viewports. Use the visual viewport height so iOS browser chrome
  cannot push the final choice below the fold.
*/
html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible {
  height: var(--reader-visual-height, 100dvh);
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(42px, 1fr) auto;
  overflow: hidden;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .test-header {
  padding-top: max(6px, env(safe-area-inset-top, 0px));
  padding-right: max(14px, env(safe-area-inset-right, 0px));
  padding-bottom: 4px;
  padding-left: max(14px, env(safe-area-inset-left, 0px));
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .back-btn {
  min-height: 34px;
  padding: 5px 12px;
  font-size: 12px;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .test-counter {
  font-size: 12px;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .story-body {
  min-height: 42px;
  align-items: center;
  overflow: hidden;
  padding-top: 4px;
  padding-right: max(24px, env(safe-area-inset-right, 0px));
  padding-bottom: 4px;
  padding-left: max(24px, env(safe-area-inset-left, 0px));
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .story-text {
  max-width: min(720px, 88vw);
  max-height: 2.7em;
  display: -webkit-box;
  overflow: hidden;
  font-size: 15px;
  line-height: 1.35;
  text-overflow: ellipsis;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .story-footer {
  width: 100%;
  max-height: none;
  display: block;
  overflow: hidden;
  padding-top: 4px;
  padding-right: max(18px, env(safe-area-inset-right, 0px));
  padding-bottom: max(6px, env(safe-area-inset-bottom, 0px));
  padding-left: max(18px, env(safe-area-inset-left, 0px));
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .story-footer--continue {
  display: none !important;
  pointer-events: none !important;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible #story-next-btn {
  display: none !important;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .options-list {
  width: min(680px, 100%);
  margin: 0 auto;
  gap: 8px;
  overflow: hidden;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .option-btn {
  min-height: 52px;
  display: flex;
  align-items: center;
  padding: 9px 18px;
  font-size: 15px;
  line-height: 1.3;
  transform: none;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .option-btn__label {
  width: 100%;
  display: -webkit-box;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .option-btn:hover:not(:disabled),
html.reader-compact-choice-viewport body.reader-active .story-page--choices-visible .option-btn.selected {
  transform: none;
}

html.reader-ultra-compact-choice-viewport body.reader-active .story-page--choices-visible .story-body {
  min-height: 38px;
  padding-top: 2px;
  padding-bottom: 2px;
}

html.reader-ultra-compact-choice-viewport body.reader-active .story-page--choices-visible .option-btn {
  min-height: 48px;
  padding-top: 7px;
  padding-bottom: 7px;
}

html.reader-ultra-compact-choice-viewport body.reader-active .story-page--choices-visible[data-choice-count="4"] .options-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 8px;
}

@media (max-width: 767px) and (orientation: portrait) {
  body.reader-active .bg-image-layer.has-bg-image::after {
    display: none;
  }

  body.reader-active .reader-scene-backdrop {
    inset: -3px;
    width: calc(100% + 6px);
    height: calc(100% + 6px);
    object-fit: cover;
    filter: blur(1.5px) brightness(0.78) saturate(0.9);
    transform: scale(1.02);
    opacity: 1;
  }

  body.reader-active .reader-scene-shade {
    display: block;
    position: absolute;
    inset: 0;
    background:
      linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.12) 0%,
        rgba(0, 0, 0, 0.18) 38%,
        rgba(0, 0, 0, 0.55) 68%,
        rgba(0, 0, 0, 0.90) 88%,
        rgba(0, 0, 0, 0.97) 100%
      );
  }
}

.reader-orientation-prompt {
  position: fixed;
  inset: 0;
  z-index: 1900;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 18px;
  padding-bottom: max(18px, calc(env(safe-area-inset-bottom, 0px) + 14px));
  pointer-events: auto;
}

.reader-orientation-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.32);
}

.reader-orientation-sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 390px);
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(12, 12, 16, 0.88);
  color: #F3F3F0;
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.reader-orientation-sheet h2 {
  margin: 0 0 6px;
  font-size: 16px;
  line-height: 1.45;
  font-weight: 760;
  letter-spacing: 0;
}

.reader-orientation-sheet p {
  margin: 0 0 14px;
  color: rgba(243, 243, 240, 0.72);
  font-size: 13px;
  line-height: 1.5;
  letter-spacing: 0;
}

.reader-orientation-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
}

.reader-orientation-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #F3F3F0;
  font-size: 14px;
  font-weight: 760;
  cursor: pointer;
}

.reader-orientation-primary {
  background: linear-gradient(90deg, #7C3AED, #DB2777);
}

.reader-orientation-actions button:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.72);
  outline-offset: 3px;
}

/* 인터랙티브 픽션 장면 효과 — 짧은 컷인/맥박/점프스케어 */
.if-fx {
  position: fixed;
  inset: 0;
  z-index: 9200;
  pointer-events: none;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.72);
  opacity: 1;
  animation: if-fx-fade var(--if-fx-duration, 650ms) ease both;
}

.if-fx--out { opacity: 0; transition: opacity 120ms ease; }
.if-fx--hold {
  pointer-events: auto;
  animation: none;
}

.if-fx-preblack {
  position: fixed;
  inset: 0;
  z-index: 9199;
  pointer-events: none;
  background: #000;
  opacity: 1;
  transition: opacity 90ms ease;
}

.if-fx-preblack.is-out {
  opacity: 0;
}

.if-fx__image {
  position: absolute;
  inset: -6%;
  background-image: var(--if-fx-image, radial-gradient(circle at 52% 44%, rgba(80,0,0,.92) 0%, rgba(20,0,0,.78) 34%, rgba(0,0,0,.96) 72%));
  background-size: cover;
  background-position: center;
  transform: scale(1.04);
  filter: contrast(1.12) saturate(0.8) brightness(0.82);
  opacity: 0.92;
}

.if-fx__video {
  position: absolute;
  inset: -6%;
  width: 112%;
  height: 112%;
  object-fit: cover;
  object-position: center;
  filter: contrast(1.12) saturate(0.8) brightness(0.82);
  opacity: 0.94;
}

.if-fx__flash {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: rgba(255, 255, 255, 0.0);
}

.if-fx__grain {
  position: absolute;
  inset: 0;
  z-index: 3;
  opacity: 0.13;
  mix-blend-mode: screen;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='.55'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}

.if-fx__text {
  position: absolute;
  left: 50%;
  bottom: max(72px, calc(env(safe-area-inset-bottom) + 56px));
  z-index: 4;
  width: min(82vw, 520px);
  transform: translateX(-50%);
  margin: 0;
  color: rgba(240, 245, 252, 0.92);
  font-size: clamp(16px, 3.8vw, 22px);
  line-height: 1.55;
  font-weight: 650;
  text-align: center;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.9);
  opacity: 0;
  animation: if-fx-text-reveal var(--if-fx-duration, 900ms) ease both;
}

.if-fx--shadow_pass {
  background: rgba(0, 0, 0, 0.36);
}

.if-fx--shadow_pass .if-fx__image {
  inset: 0;
  background-image: var(--if-fx-image, linear-gradient(100deg, transparent 0%, rgba(0,0,0,.02) 35%, rgba(0,0,0,.88) 50%, rgba(0,0,0,.05) 65%, transparent 100%));
  background-size: 160% 100%;
  opacity: 0.72;
  animation: if-shadow-pass var(--if-fx-duration, 450ms) ease-in-out both;
}

.if-fx--pulse {
  background: rgba(5, 8, 12, 0.58);
}

.if-fx--pulse .if-fx__image {
  background-image: radial-gradient(circle at 50% 50%, transparent 0%, rgba(90,0,20,.24) 48%, rgba(0,0,0,.84) 100%);
  animation: if-pulse var(--if-fx-duration, 900ms) ease-in-out both;
}

.if-fx--jumpscare .if-fx__image,
.if-fx--jumpscare .if-fx__video,
.if-fx--threat_cut .if-fx__image,
.if-fx--threat_cut .if-fx__video {
  animation: if-threat-lunge var(--if-fx-duration, 650ms) cubic-bezier(.18,.95,.3,1) both;
}

.if-fx--strong.if-fx--jumpscare .if-fx__image,
.if-fx--strong.if-fx--jumpscare .if-fx__video {
  animation: if-strong-lunge var(--if-fx-duration, 1100ms) cubic-bezier(.16,.94,.26,1) both;
}

.if-fx--hold.if-fx--jumpscare .if-fx__image,
.if-fx--hold.if-fx--jumpscare .if-fx__video {
  animation: if-door-hold-in 360ms ease-out both;
}

.if-fx__next {
  position: absolute;
  left: 50%;
  bottom: max(32px, env(safe-area-inset-bottom));
  z-index: 4;
  transform: translateX(-50%);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 24px;
  background: rgba(0, 0, 0, 0.54);
  color: #fff;
  padding: 12px 28px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  opacity: 0;
  cursor: pointer;
  transition: opacity 180ms ease, background 180ms ease;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.if-fx__next.visible { opacity: 1; }
.if-fx__next:hover { background: rgba(0, 0, 0, 0.72); }

.if-fx--flash .if-fx__flash {
  animation: if-fx-flash var(--if-fx-duration, 650ms) ease-out both;
}

.if-fx--shake {
  animation: if-fx-fade var(--if-fx-duration, 650ms) ease both, if-fx-shake 90ms linear 2;
}

.if-fx--silence_drop {
  background: rgba(0, 0, 0, 0.78);
}

.if-fx--silence_drop .if-fx__image {
  opacity: 0.72;
  filter: grayscale(0.35) contrast(0.92) brightness(0.58) blur(0.4px);
  animation: if-silence-drop var(--if-fx-duration, 1200ms) ease-in-out both;
}

.if-fx--micro_zoom .if-fx__image,
.if-fx--radio_glitch .if-fx__image {
  animation: if-micro-zoom var(--if-fx-duration, 1400ms) ease-in-out both;
}

.if-fx--muffled_overlay {
  background: rgba(5, 7, 10, 0.82);
  backdrop-filter: blur(2px) saturate(0.65);
  -webkit-backdrop-filter: blur(2px) saturate(0.65);
}

.if-fx--muffled_overlay .if-fx__image {
  filter: blur(1.6px) contrast(0.9) saturate(0.55) brightness(0.62);
  animation: if-muffled-overlay var(--if-fx-duration, 1400ms) ease-in-out both;
}

.if-fx--direction_shift .if-fx__image {
  animation: if-direction-shift var(--if-fx-duration, 1150ms) cubic-bezier(.2,.9,.2,1) both;
}

.if-fx--radio_glitch .if-fx__image {
  background-image:
    repeating-linear-gradient(0deg, rgba(255,255,255,.10) 0 1px, transparent 1px 5px),
    radial-gradient(circle at 50% 45%, rgba(190,210,230,.16), rgba(0,0,0,.84) 62%);
  filter: contrast(1.1) saturate(0.4) brightness(0.66);
  opacity: 0.62;
}

.if-fx--ambient_overlay {
  background: rgba(2, 5, 8, 0.64);
  backdrop-filter: brightness(0.72) saturate(0.75);
  -webkit-backdrop-filter: brightness(0.72) saturate(0.75);
}

.if-fx--ambient_overlay .if-fx__image {
  background-image: radial-gradient(circle at 50% 50%, rgba(180, 205, 220, 0.08), rgba(0, 0, 0, 0.72) 68%);
  opacity: 0.52;
  animation: if-ambient-overlay var(--if-fx-duration, 1400ms) ease-in-out both;
}

@keyframes if-fx-fade {
  0% { opacity: 0; }
  12% { opacity: 1; }
  82% { opacity: 1; }
  100% { opacity: 0; }
}

@keyframes if-shadow-pass {
  0% { background-position: 120% 50%; opacity: 0; }
  22% { opacity: 0.8; }
  100% { background-position: -40% 50%; opacity: 0; }
}

@keyframes if-pulse {
  0%, 100% { transform: scale(1); opacity: 0.45; }
  35% { transform: scale(1.04); opacity: 0.92; }
  68% { transform: scale(1.01); opacity: 0.58; }
}

@keyframes if-threat-lunge {
  0% { transform: scale(1.28); opacity: 0; filter: blur(4px) contrast(1.2) brightness(0.55); }
  12% { opacity: 1; filter: blur(0) contrast(1.2) brightness(0.9); }
  55% { transform: scale(1.03); opacity: 1; }
  100% { transform: scale(1.1); opacity: 0; filter: blur(2px) contrast(1.08) brightness(0.55); }
}

@keyframes if-strong-lunge {
  0% { transform: scale(1.22); opacity: 0; filter: blur(3px) contrast(1.18) brightness(0.58); }
  10% { transform: scale(1.04); opacity: 1; filter: blur(0) contrast(1.12) brightness(0.88); }
  72% { transform: scale(1.02); opacity: 0.96; filter: blur(0) contrast(1.08) brightness(0.82); }
  100% { transform: scale(1.07); opacity: 0; filter: blur(2px) contrast(1.05) brightness(0.55); }
}

@keyframes if-door-hold-in {
  0% { transform: scale(1.08); opacity: 0; filter: blur(3px) contrast(1.12) brightness(0.6); }
  100% { transform: scale(1.02); opacity: 0.96; filter: blur(0) contrast(1.08) brightness(0.78); }
}

@keyframes if-fx-flash {
  0% { background: rgba(255,255,255,0); }
  8% { background: rgba(255,255,255,.72); }
  16% { background: rgba(80,0,0,.45); }
  100% { background: rgba(255,255,255,0); }
}

@keyframes if-fx-shake {
  0%, 100% { transform: translate3d(0,0,0); }
  25% { transform: translate3d(-10px, 4px, 0); }
  50% { transform: translate3d(8px, -5px, 0); }
  75% { transform: translate3d(-4px, -2px, 0); }
}

@keyframes if-silence-drop {
  0% { transform: scale(1.02); opacity: 0; filter: brightness(0.95) blur(0); }
  26% { opacity: 0.82; }
  100% { transform: scale(1.035); opacity: 0; filter: brightness(0.34) blur(1.8px); }
}

@keyframes if-micro-zoom {
  0% { transform: scale(1.01); opacity: 0; }
  15% { opacity: 0.94; }
  100% { transform: scale(1.075); opacity: 0; }
}

@keyframes if-muffled-overlay {
  0% { transform: scale(1.02); opacity: 0; }
  22% { opacity: 0.9; }
  100% { transform: scale(1.03); opacity: 0; }
}

@keyframes if-ambient-overlay {
  0% { transform: scale(1); opacity: 0; }
  24% { opacity: 0.58; }
  100% { transform: scale(1.01); opacity: 0; }
}

@keyframes if-fx-text-reveal {
  0% { opacity: 0; transform: translate(-50%, 8px); }
  22% { opacity: 1; transform: translate(-50%, 0); }
  82% { opacity: 1; transform: translate(-50%, 0); }
  100% { opacity: 0; transform: translate(-50%, -4px); }
}

@keyframes if-direction-shift {
  0% { transform: scale(1.02); opacity: 0; filter: brightness(0.45) blur(2px); }
  24% { opacity: 1; filter: brightness(0.72) blur(0); }
  52% { transform: scale(1.025) translateX(-4px); }
  100% { transform: scale(1.055) translateX(0); opacity: 0; filter: brightness(0.38) blur(1px); }
}

/* ═══════════════════════════════════════════════════════════
   TEST PAGE — LAYOUT
═══════════════════════════════════════════════════════════ */
.test-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding-bottom: 40px;
  position: relative;
  z-index: 2;
}

.test-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 10px;
}

.back-btn {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 20px;
  padding: 7px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-color);
  cursor: pointer;
  transition: background var(--ease);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.back-btn:hover { opacity: 0.8; }
.back-btn:disabled {
  opacity: 0.35;
  cursor: default;
}
.back-btn:disabled:hover { opacity: 0.35; }

.test-counter {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-second);
  letter-spacing: 0.04em;
}

/* Progress bar */
.progress-track {
  height: 3px;
  background: rgba(255,255,255,0.18);
  border-radius: 2px;
  overflow: hidden;
  margin: 0 20px 36px;
}
.progress-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 2px;
  transition: width 0.48s cubic-bezier(0.34,1.56,0.64,1);
  box-shadow: 0 0 8px var(--accent);
}

/* ═══════════════════════════════════════════════════════════
   QUESTION CARD (FROSTED GLASS)
═══════════════════════════════════════════════════════════ */
.question-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 0 16px;
  max-width: 520px;
  width: 100%;
  margin: 0 auto;
}

.question-card {
  background: var(--card-bg);
  backdrop-filter: blur(28px); /* 문제 3: blur 강화 → 배경과의 대비↑ */
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid var(--card-border);
  border-radius: 24px;
  padding: 28px 24px;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  /* 문제 3: 배경 이미지 위에서 최소 가독성 레이어 */
  box-shadow: inset 0 0 0 1000px rgba(10, 5, 25, 0.22);
}
.question-card.visible { opacity: 1; transform: translateY(0); }

.question-number {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.question-text {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.6;
  color: var(--text-color);
  /* 문제 3: 야외 가독성 — 텍스트 그림자 */
  text-shadow: 0 1px 6px rgba(0,0,0,0.7);
}

/* ═══════════════════════════════════════════════════════════
   OPTIONS
═══════════════════════════════════════════════════════════ */
.options-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.option-btn {
  width: 100%;
  background: var(--card-bg);
  backdrop-filter: blur(12px); /* 문제 3: blur 강화 → 배경 대비↑ */
  -webkit-backdrop-filter: blur(12px);
  border: 1.5px solid var(--card-border);
  border-radius: var(--radius-sm);
  padding: 15px 18px;
  text-align: left;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.55;
  color: var(--text-color);
  word-break: keep-all;
  overflow-wrap: normal;
  line-break: strict;
  text-wrap: pretty;
  /* 문제 3: 텍스트 그림자로 야외 가독성 */
  text-shadow: 0 1px 4px rgba(0,0,0,0.6);
  cursor: pointer;
  transition: border-color var(--ease), transform var(--ease), background var(--ease);
}
.option-btn:hover:not(:disabled) {
  border-color: var(--accent);
  transform: translateX(6px);
}
.option-btn:focus:not(:focus-visible) { outline: none; }
.option-btn:focus-visible {
  outline: 2px solid var(--focus-color, #8ab4ff);
  outline-offset: 3px;
}
.option-btn.selected {
  background: var(--accent);
  color: #fff;
  border-color: transparent;
  transform: translateX(6px);
}
.option-btn:disabled { cursor: default; }

/* ═══════════════════════════════════════════════════════════
   RESULT PAGE
═══════════════════════════════════════════════════════════ */
.result-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px 16px 64px;
  position: relative;
  z-index: 2;
  gap: 16px;
}

/* ── 결과 카드 (스크린샷 영역) ───────────────────
   headline + caption + 이모지가 한 화면에 들어가게 설계
*/
.result-card {
  background: var(--card-bg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--card-border);
  border-radius: 28px;
  padding: 30px 22px 22px;
  width: 100%;
  max-width: 380px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  opacity: 0;
  transform: translateY(28px) scale(0.97);
  transition: opacity 0.42s ease, transform 0.42s cubic-bezier(0.34,1.56,0.64,1);
}
.result-card.visible { opacity: 1; transform: none; }

/* Ambient glow */
.result-card-glow {
  position: absolute;
  top: -40%; left: -40%; right: -40%; bottom: -40%; /* iOS <14.5 longhand */
  background: radial-gradient(ellipse at 50% 20%, var(--accent) 0%, transparent 65%);
  opacity: 0.12;
  pointer-events: none;
}

.result-badge {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.result-emoji {
  font-size: 84px;
  line-height: 1;
  filter: drop-shadow(0 6px 16px rgba(0,0,0,0.18));
}

/* 임팩트 한 줄 헤드라인 */
.result-headline {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.25;
  color: var(--text-color);
  letter-spacing: -0.02em;
  word-break: keep-all;
}

/* 1~2문장 캐릭터 묘사 */
.result-caption {
  font-size: 13px;
  line-height: 1.65;
  color: var(--text-second);
  word-break: keep-all;
  margin-top: 2px;
}

.result-card--if {
  align-items: stretch;
  gap: 10px;
}

.result-card--if .result-headline,
.result-card--if .result-badge {
  text-align: center;
}

.result-ending-kicker {
  margin: -4px 0 2px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--text-second);
  text-align: center;
  word-break: keep-all;
  overflow-wrap: normal;
  line-break: strict;
  text-wrap: pretty;
}

.result-ending-summary {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 2px;
  color: var(--text-color);
  font-size: 13px;
  line-height: 1.65;
  word-break: keep-all;
  overflow-wrap: normal;
  line-break: strict;
  text-wrap: pretty;
}

.result-ending-summary p,
.result-ending-notes p {
  margin: 0;
}

.result-ending-notes {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
  padding: 12px 12px 0;
  border-top: 1px solid var(--card-border);
  color: var(--text-second);
  font-size: 12px;
  line-height: 1.55;
  text-align: left;
  word-break: keep-all;
  overflow-wrap: normal;
  line-break: strict;
  text-wrap: pretty;
}

.result-ending-notes span {
  display: inline-block;
  min-width: 34px;
  margin-right: 6px;
  color: var(--accent);
  font-weight: 700;
}

.result-watermark {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--card-border);
  width: 100%;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--text-second);
  opacity: 0.60;
}

/* ── 결과 페이지 — 캐릭터 이미지 독립 컨테이너 ──────────────── */
/* 카드 위쪽에 별도 영역으로 분리 — overflow 문제 원천 방지       */
.result-img-outer {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  width: 100%;
  flex-shrink: 0;
}

.result-char-img {
  display: block;
  /* 모바일: 뷰포트 80% 너비, 2:3 비율(1024×1536) */
  width: 80vw;
  max-width: 320px;
  aspect-ratio: 2 / 3;
  max-height: 62vh;       /* 작은 화면에서 과도한 높이 방지 */
  object-fit: contain;    /* 이미지 전체가 컨테이너 안에 */
  object-position: center center;
  border-radius: 20px;    /* 모서리 살짝 */
}

@media (min-width: 600px) {
  .result-char-img {
    max-width: 400px;
    max-height: 500px;
  }
}

/* ── 더 알아보기 버튼 ────────────────────────── */
.result-expand-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 20px;
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-second);
  cursor: pointer;
  transition: background var(--ease), color var(--ease);
  font-family: inherit;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.result-expand-btn:hover { background: rgba(255,255,255,0.14); color: var(--text-color); }

.expand-icon {
  display: inline-block;
  transition: transform 0.32s cubic-bezier(0.34,1.56,0.64,1);
  font-style: normal;
}

/* ── 상세 설명 패널 (max-height 애니메이션) ────── */
.result-details-panel {
  width: 100%;
  max-width: 380px;
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.44s ease, opacity 0.32s ease;
}
.result-details-panel.open {
  max-height: 600px;
  opacity: 1;
}

.result-details-text {
  font-size: 14px;
  line-height: 1.75;
  color: var(--text-second);
  word-break: keep-all;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 18px 20px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

/* ── 공유용 한 줄 (share_text) ───────────────── */
.result-share-quote {
  font-size: 13px;
  color: var(--text-second);
  text-align: center;
  line-height: 1.65;
  max-width: 340px;
  font-style: italic;
}

/* ═══════════════════════════════════════════════════════════
   RESULT — SHARE & NAV BUTTONS
═══════════════════════════════════════════════════════════ */
.result-actions {
  width: 100%;
  max-width: 380px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* 공통 share-btn */
.share-btn {
  width: 100%;
  border: none;
  border-radius: var(--radius-sm);
  padding: 14px 20px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  letter-spacing: 0.01em;
  transition: filter var(--ease), transform var(--ease), opacity var(--ease);
}

/* 이미지 카드 만들기 — 메인 (그라데이션) */
.share-btn--card {
  background: linear-gradient(90deg, var(--purple) 0%, var(--pink) 100%);
  color: #fff;
  border: none;
  font-size: 15px;
}
.share-btn--card:hover  { filter: brightness(1.12); transform: translateY(-1px); }
.share-btn--card:active { transform: translateY(0); transition-duration: 0.1s; }
.share-btn--card:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
  filter: none;
}

/* 링크 공유 — 보조 */
.share-btn--link {
  background: transparent;
  color: var(--text-second);
  border: 1.5px solid var(--card-border);
  font-size: 14px;
  font-weight: 600;
}
.share-btn--link:hover {
  background: var(--card-bg);
  color: var(--text-color);
  transform: translateY(-1px);
}
.share-btn--link:active { transform: translateY(0); transition-duration: 0.1s; }

.result-nav {
  display: flex;
  gap: 10px;
  width: 100%;
  max-width: 380px;
}

.nav-btn {
  flex: 1;
  border-radius: var(--radius-sm);
  padding: 13px 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--ease), color var(--ease), opacity var(--ease);
  border: 1.5px solid var(--card-border);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-family: inherit;
}
.btn-retry { background: var(--card-bg); color: var(--text-color); }
.btn-retry:hover { opacity: 0.85; }
.btn-home { background: transparent; color: var(--text-second); border-color: var(--card-border); }
.btn-home:hover { color: var(--text-color); opacity: 0.85; }

/* ═══════════════════════════════════════════════════════════
   TOAST
═══════════════════════════════════════════════════════════ */
.toast {
  position: fixed;
  bottom: 88px; /* above nav bar */
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  background: rgba(20,8,48,0.92);
  color: #fff;
  padding: 11px 22px;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 500;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.24s ease, transform 0.24s ease;
  z-index: 999;
  white-space: nowrap;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ═══════════════════════════════════════════════════════════
   정보 버튼 SVG 아이콘  (작업 3)
═══════════════════════════════════════════════════════════ */
.info-icon-svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
  display: block;
}

.hero-btn-info {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ═══════════════════════════════════════════════════════════
   정보 모달  (작업 3)
═══════════════════════════════════════════════════════════ */
.info-modal-backdrop {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0; /* iOS <14.5 longhand */
  z-index: 200;
  background: rgba(0, 0, 0, 0.60);
  display: flex;
  align-items: flex-end;     /* 모바일: 아래서 올라오는 시트 */
  justify-content: center;
  opacity: 0;
  transition: opacity 0.22s ease;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.info-modal-backdrop.open { opacity: 1; }

.info-modal {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-width: 600px;
  padding: 28px 24px 40px;
  position: relative;
  max-height: calc(100vh - 24px);
  overflow-y: auto;
  transform: translateY(48px);
  transition: transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.info-modal-backdrop.open .info-modal { transform: translateY(0); }

/* 데스크탑 — 중앙 팝업 */
@media (min-width: 600px) {
  .info-modal-backdrop { align-items: center; padding: 20px; }
  .info-modal {
    border-radius: 24px;
    max-width: 480px;
  }
}

.info-modal-close {
  position: absolute;
  top: 16px; right: 16px;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.10);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background var(--ease);
}
.info-modal-close:hover { background: rgba(255, 255, 255, 0.18); }
.info-modal-close svg {
  width: 15px; height: 15px;
}

.info-modal-cat {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pink);
  margin-bottom: 8px;
}

.info-modal-title {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  word-break: keep-all;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
  padding-right: 36px; /* X 버튼 겹침 방지 */
}

.info-modal-desc {
  font-size: 14px;
  color: var(--text2);
  line-height: 1.65;
  margin-bottom: 22px;
}

.info-modal-start {
  width: 100%;
  background: linear-gradient(90deg, var(--purple) 0%, var(--pink) 100%);
  color: white;
  border: none;
  border-radius: 24px;
  padding: 14px 20px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  letter-spacing: 0.01em;
  transition: filter var(--ease), transform var(--ease);
}
.info-modal-start:hover  { filter: brightness(1.12); transform: translateY(-1px); }
.info-modal-start:active { transform: translateY(0); transition-duration: 0.1s; }

/* ── 인포 모달 — 버튼 그룹 ─────── */
.info-modal-actions {
  display: flex;
  margin-top: 4px;
}
.info-modal-actions .info-modal-start {
  width: 100%;
  margin-top: 0;
}

/* ── 인포 모달 — 썸네일 히어로 ──────────────── */
.info-modal--has-img {
  padding-top: 0;
}

.info-modal-hero {
  width: calc(100% + 48px);
  margin-left: -24px;
  margin-top: 0;
  margin-bottom: 20px;
  border-radius: 24px 24px 0 0;
  overflow: hidden;
  max-height: 220px;
}

.info-modal-hero img {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: cover;
  object-position: center center;
}

.info-modal--has-img .info-modal-cat {
  margin-top: 4px;
}

/* ═══════════════════════════════════════════════════════════
   서브 페이지 공통 (탐색·카테고리)
═══════════════════════════════════════════════════════════ */
.sub-page {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  min-height: 100dvh;
  padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); /* clears nav + iOS home indicator */
  max-width: 800px;
  margin: 0 auto;
}

/* 고정 서브 헤더 (레거시 — full-header로 대체됨) */
.sub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 14px;
  position: sticky;
  top: 0;
  z-index: 10;
  background: #0F0820;
  border-bottom: none;
  gap: 12px;
}

/* 탐색·카테고리 뒤로가기 버튼 — 테스트 페이지 back-btn과 동일한 frosted-glass 스타일 */
.sub-back-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: background var(--ease);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  white-space: nowrap;
  flex-shrink: 0;
  font-family: inherit;
}
.sub-back-btn:hover { background: rgba(255, 255, 255, 0.14); }

.sub-title {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  text-align: center;
  flex: 1;
  letter-spacing: -0.02em;
}

.sub-header-spacer { min-width: 60px; }

/* ═══════════════════════════════════════════════════════════
   탐색 페이지 그리드  (작업 4)
   모바일 1열 → 태블릿 2열 → 데스크탑 3열
═══════════════════════════════════════════════════════════ */
.explore-main { padding-top: 4px; }

.explore-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  padding: 16px;
}

@media (min-width: 540px) {
  .explore-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .explore-grid {
    grid-template-columns: repeat(3, 1fr);
    max-width: 1280px;
    margin: 0 auto;
    padding: 24px 48px;
    gap: 20px;
  }
}

/* 카테고리 카드 (탐색 페이지) */
.cat-card {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  min-height: 148px;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45);
  transition: transform var(--ease-pop), box-shadow var(--ease);
}
.cat-card:hover  { transform: translateY(-4px) scale(1.02); box-shadow: 0 10px 32px rgba(0,0,0,0.55); }
.cat-card:active { transform: scale(0.99); transition-duration: 0.1s; }

.adult-entry-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  padding: 0 16px;
}

@media (min-width: 768px) {
  .adult-entry-row {
    grid-template-columns: minmax(240px, 360px);
  }
}

.cat-card--adult .cat-card-bg {
  background:
    linear-gradient(160deg, var(--c-s, #38111F) 0%, var(--c-e, #8F1D3F) 100%);
}

.cat-card--adult .cat-card-emoji {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(18, 20, 28, .72);
  border: 1px solid rgba(255,255,255,.22);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.cat-card-bg {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0; /* iOS <14.5 longhand */
  background: linear-gradient(160deg, var(--c-s, #3D2660) 0%, var(--c-e, #5B3D8B) 100%);
}

/* Decorative circle */
.cat-card-bg::before {
  content: '';
  position: absolute;
  top: -30px; right: -30px;
  width: 120px; height: 120px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.07);
  pointer-events: none;
}

/* Scrim */
.cat-card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0; /* iOS <14.5 longhand */
  background: linear-gradient(to top, rgba(0,0,0,0.50) 0%, transparent 60%);
  pointer-events: none;
}

.cat-card-body {
  position: relative;
  z-index: 1;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  height: 100%;
}

.cat-card-emoji {
  font-size: 30px;
  line-height: 1;
  margin-bottom: 4px;
}

.cat-card-title {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: white;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.cat-card-desc {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.55;
}

.cat-card-count {
  display: block;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.50);
  margin-top: 6px;
}

/* ═══════════════════════════════════════════════════════════
   카테고리 전체 페이지  (작업 5 + 6)
   모바일 2열 → 태블릿 3열 → 데스크탑 4열
   .cat-grid .v2-card { width: 100% } → 그리드 열 자동 채움
═══════════════════════════════════════════════════════════ */
.cat-main { padding-top: 4px; }

.cat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  padding: 16px;
}

@media (min-width: 768px) {
  .cat-grid { grid-template-columns: repeat(3, 1fr); gap: 14px; }
}

@media (min-width: 1024px) {
  .cat-grid {
    grid-template-columns: repeat(4, 1fr);
    max-width: 1280px;
    margin: 0 auto;
    padding: 24px 48px;
    gap: 16px;
  }
}

/* 작업 6 — 그리드 안 카드는 열 너비를 채우도록 */
.cat-grid .v2-card {
  width: 100%;
  height: 160px;
  flex-shrink: unset;
  scroll-snap-align: none;
}

@media (min-width: 768px) {
  .cat-grid .v2-card { height: 180px; }
}

@media (min-width: 1024px) {
  .cat-grid .v2-card { height: 200px; }
}

.empty-cat {
  grid-column: 1 / -1;
  padding: 48px 0;
  text-align: center;
  color: var(--text2);
  font-size: 15px;
}

.adult-category-main {
  min-height: calc(100vh - 140px);
}

.adult-category-notice,
.adult-category-info,
.adult-category-loading {
  width: min(100% - 32px, 560px);
  margin: 28px auto;
  padding: 24px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(12, 14, 22, .74);
  color: var(--text);
  box-shadow: 0 12px 34px rgba(0,0,0,.26);
}

.adult-category-notice h2 {
  margin: 10px 0 8px;
  font-size: 20px;
  line-height: 1.35;
  letter-spacing: 0;
}

.adult-category-notice p,
.adult-category-info p,
.adult-category-loading p {
  margin: 0;
  color: var(--text2);
  line-height: 1.6;
}

.adult-category-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(143, 29, 63, .32);
  border: 1px solid rgba(244, 200, 180, .28);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.adult-category-cta {
  margin-top: 18px;
  min-height: 42px;
  padding: 10px 16px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #8F1D3F, #5B2344);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.adult-category-cta:disabled {
  cursor: not-allowed;
  opacity: .62;
}

.adult-category-dev-note {
  margin-top: 12px !important;
  font-size: 12px;
}

.adult-direct-gate {
  gap: 10px;
  text-align: center;
}

.adult-direct-gate h2,
.adult-direct-gate p {
  margin: 0;
}

.adult-direct-gate-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
  width: min(280px, 100%);
}

/* ═══════════════════════════════════════════════════════════
   계정 페이지
═══════════════════════════════════════════════════════════ */
.account-page {
  padding-bottom: calc(84px + env(safe-area-inset-bottom, 0px));
}

.account-page--onboarding {
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.account-main {
  max-width: 720px;
  margin: 0 auto;
  padding: 24px 16px 32px;
}

.account-panel {
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.055);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.20);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 20px;
}

.account-panel-head {
  margin-bottom: 16px;
}

.account-kicker {
  margin: 0 0 6px;
  color: rgba(255, 255, 255, 0.48);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.12em;
}

.account-panel h2 {
  margin: 0;
  color: var(--text);
  font-size: 24px;
  letter-spacing: -0.02em;
}

.account-muted {
  margin: 0;
  color: var(--text2);
  font-size: 14px;
  line-height: 1.6;
}

/* ═══════════════════════════════════════════════════════════
   회원가입 전용 페이지
═══════════════════════════════════════════════════════════ */
.signup-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(circle at 18% 16%, rgba(124, 58, 237, 0.22), transparent 34%),
    linear-gradient(135deg, #07070b 0%, #10111b 54%, #07070b 100%);
}

.signup-header {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(18px, 4vw, 48px);
}

.signup-brand {
  display: inline-flex;
  align-items: center;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
}

.signup-main {
  flex: 1;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  padding: 24px 16px 42px;
}

.signup-panel {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 22px;
  background: rgba(14, 16, 24, 0.92);
  box-shadow: 0 22px 64px rgba(0, 0, 0, 0.28);
  padding: 28px;
}

.account-action-row {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.account-action-row .lomm-btn {
  min-height: 42px;
}

.service-footer {
  margin-top: 18px;
  padding: 18px 4px 0;
  color: rgba(255, 255, 255, 0.48);
  font-size: 12px;
  line-height: 1.6;
}

.service-footer--landing {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  margin: 0;
  padding: 0 clamp(18px, 5vw, 64px) 24px;
  color: rgba(255, 255, 255, 0.50);
}

.service-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 8px;
}

.service-footer a {
  color: rgba(255, 255, 255, 0.68);
  text-decoration: none;
}

.service-footer a:hover {
  color: #fff;
}

.service-footer p {
  margin: 0;
}

.info-page {
  padding-bottom: 42px;
}

.info-main {
  max-width: 820px;
  margin: 0 auto;
  padding: 24px 16px 40px;
}

.info-panel {
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.055);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.20);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 22px;
}

.info-kicker {
  margin: 0 0 8px;
  color: rgba(255, 255, 255, 0.48);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.info-panel h1 {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.info-lead {
  margin: 0 0 18px;
  color: var(--text2);
  font-size: 15.5px;
  line-height: 1.85;
  word-break: keep-all;
}

.policy-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin: 0 0 16px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.policy-meta div {
  display: grid;
  gap: 3px;
}

.policy-meta dt {
  color: rgba(255, 255, 255, 0.50);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.policy-meta dd {
  margin: 0;
  color: var(--text);
  font-size: 13px;
  line-height: 1.4;
}

.policy-toc,
.policy-related {
  margin: 18px 0;
  padding: 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.policy-toc h2,
.policy-related h2 {
  margin: 0 0 10px;
  color: var(--text);
  font-size: 15px;
  line-height: 1.35;
}

.policy-toc-list {
  display: grid;
  gap: 6px 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--text2);
  font-size: 13px;
  line-height: 1.55;
}

.policy-toc a,
.policy-related a {
  color: #d7ccff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.policy-toc a:hover,
.policy-related a:hover {
  color: #fff;
}

.policy-related {
  margin-bottom: 0;
}

.policy-related div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
}

.policy-related a[aria-current="page"] {
  color: var(--text);
  text-decoration: none;
}

.support-contact {
  display: grid;
  gap: 5px;
  margin: 0 0 18px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.09);
}

.support-contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0 0 18px;
}

.support-contact-grid .support-contact {
  margin: 0;
}

.support-contact span {
  color: rgba(255, 255, 255, 0.52);
  font-size: 12px;
  font-weight: 750;
}

.support-contact a,
.support-contact strong {
  color: #fff;
  font-size: 14px;
  font-weight: 750;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.support-message-panel {
  margin: 0 0 18px;
  padding: 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.support-message-panel h2 {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 17px;
  line-height: 1.4;
}

.support-message-panel--chat {
  padding: 14px;
}

.message-section-head,
.message-page-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 14px;
}

.message-section-head h2 {
  margin-bottom: 4px;
}

.message-section-head p,
.support-refresh-status {
  margin: 0;
  color: rgba(255, 255, 255, 0.56);
  font-size: 13px;
  line-height: 1.5;
}

.message-page-toolbar {
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
}

.support-thread-form {
  display: grid;
  gap: 12px;
}

.support-form-field {
  display: grid;
  gap: 7px;
}

.support-form-field label,
.support-consent {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.45;
}

.support-form-field input,
.support-form-field select,
.support-form-field textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.22);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  line-height: 1.55;
  padding: 12px 13px;
  outline: none;
}

.support-form-field textarea {
  resize: vertical;
  min-height: 132px;
}

.support-form-field input:focus,
.support-form-field select:focus,
.support-form-field textarea:focus {
  border-color: rgba(215, 204, 255, 0.52);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18);
}

.support-form-field input::placeholder,
.support-form-field textarea::placeholder {
  color: rgba(255, 255, 255, 0.34);
}

.support-consent {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-weight: 650;
}

.support-consent input {
  flex: 0 0 auto;
  margin-top: 3px;
  accent-color: #8B5CF6;
}

.support-form-status {
  min-height: 20px;
  margin: 0;
  color: rgba(255, 255, 255, 0.58);
  font-size: 13px;
  line-height: 1.55;
}

.support-form-status--success {
  display: grid;
  gap: 6px;
  color: #C7F9CC;
}

.support-form-status--error {
  color: #FFB4B4;
}

.support-form-status button,
.support-submit,
.support-secondary-btn {
  justify-self: start;
  min-height: 42px;
  border-radius: 12px;
  font-weight: 850;
  font-size: 14px;
  padding: 0 18px;
  cursor: pointer;
  transition: filter var(--ease), opacity var(--ease), transform var(--ease);
}

.support-form-status button,
.support-submit {
  border: 0;
  background: linear-gradient(135deg, #7C3AED 0%, #DB2777 100%);
  color: #fff;
}

.support-secondary-btn {
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.055);
  color: var(--text);
}

.support-form-status button:hover,
.support-submit:hover,
.support-secondary-btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.support-submit:disabled,
.support-secondary-btn:disabled {
  cursor: wait;
  opacity: 0.68;
  transform: none;
}

.support-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 10px 0 18px;
}

.support-login-gate {
  display: grid;
  gap: 10px;
}

.support-login-gate p,
.support-muted {
  margin: 0;
  color: var(--text2);
  font-size: 14px;
  line-height: 1.7;
}

.message-inbox {
  display: grid;
  grid-template-columns: minmax(220px, 0.82fr) minmax(0, 1.55fr);
  gap: 14px;
  margin-top: 16px;
  align-items: stretch;
}

.message-inbox--chat,
.message-inbox--support-compose,
.admin-message-inbox {
  min-height: min(66vh, 680px);
}

.message-thread-list,
.message-thread-detail {
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  padding: 12px;
}

.message-thread-list {
  display: grid;
  align-content: start;
  gap: 8px;
  max-height: min(66vh, 680px);
  overflow: auto;
}

.message-thread-item {
  width: 100%;
  min-width: 0;
  display: grid;
  gap: 4px;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.16);
  color: var(--text);
  padding: 11px 12px;
  cursor: pointer;
}

.message-thread-item.active {
  border-color: rgba(215, 204, 255, 0.48);
  background: rgba(124, 58, 237, 0.18);
}

.message-thread-item span,
.message-thread-item small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.message-thread-item span {
  font-weight: 850;
  font-size: 14px;
}

.message-thread-item small {
  color: rgba(255, 255, 255, 0.58);
  font-size: 12px;
  line-height: 1.4;
}

.message-thread-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.message-thread-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.message-thread-head p,
.message-thread-head span {
  margin: 0;
  color: rgba(255, 255, 255, 0.58);
  font-size: 12px;
  line-height: 1.5;
}

.message-thread-head h2 {
  margin: 3px 0 0;
  color: var(--text);
  font-size: 18px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.support-secondary-btn--small {
  min-height: 32px;
  border-radius: 10px;
  font-size: 12px;
  padding: 0 12px;
}

.message-thread-detail {
  display: flex;
  flex-direction: column;
  min-height: min(66vh, 680px);
  overflow: hidden;
}

.message-thread-detail--compose {
  overflow: visible;
}

.message-bubble-list {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 180px;
  margin: 0 -4px 14px;
  padding: 4px 4px 12px;
  overflow: auto;
}

.message-bubble {
  display: grid;
  gap: 5px;
  max-width: min(78%, 560px);
  padding: 12px 13px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.message-bubble--user {
  align-self: flex-end;
  border-bottom-right-radius: 5px;
  background: rgba(124, 58, 237, 0.20);
}

.message-bubble--admin {
  align-self: flex-start;
  border-bottom-left-radius: 5px;
  background: rgba(255, 255, 255, 0.07);
}

.message-bubble p {
  margin: 0;
  color: var(--text2);
  font-size: 14px;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.message-bubble .message-sender {
  color: rgba(255, 255, 255, 0.58);
  font-size: 12px;
  line-height: 1.4;
}

.support-thread-form--reply {
  position: sticky;
  bottom: 0;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(17, 13, 31, 0), rgba(17, 13, 31, 0.98) 22%),
    rgba(17, 13, 31, 0.94);
}

.message-composer .support-form-field {
  gap: 6px;
}

.message-composer textarea {
  min-height: 64px;
  max-height: 150px;
}

.support-thread-form--compose {
  margin-top: auto;
}

.message-room-empty {
  margin: 0 0 14px;
  padding: 14px;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
}

.message-room-empty p {
  margin: 0;
  color: var(--text2);
  font-size: 14px;
  line-height: 1.7;
}

.support-widget {
  position: fixed;
  z-index: 1700;
  pointer-events: none;
  --support-widget-panel-right: 24px;
  --support-widget-panel-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  --support-widget-panel-pad: 12px;
  --support-widget-action-right: calc(var(--support-widget-panel-right) + var(--support-widget-panel-pad));
  --support-widget-action-bottom: calc(var(--support-widget-panel-bottom) + var(--support-widget-panel-pad));
  --support-widget-action-bg: linear-gradient(135deg, #7C3AED 0%, #DB2777 100%);
  --support-widget-action-shadow: 0 18px 46px rgba(0, 0, 0, 0.38), 0 0 0 1px rgba(255, 255, 255, 0.13) inset;
}

.support-widget-button {
  position: fixed;
  right: var(--support-widget-action-right);
  bottom: var(--support-widget-action-bottom);
  z-index: 1701;
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 82px;
  min-height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: var(--support-widget-action-bg);
  color: #fff;
  box-shadow: var(--support-widget-action-shadow);
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  transform-origin: calc(100% - 30px) 50%;
  transition:
    transform 180ms cubic-bezier(0.34, 1.56, 0.64, 1),
    filter var(--ease),
    opacity 150ms ease;
}

.support-widget-button:hover {
  filter: brightness(1.08);
  transform: translateY(-2px);
}

.support-widget.is-open .support-widget-button {
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px) scale(0.86);
}

.support-widget-button-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  font-size: 14px;
  line-height: 1;
}

.support-widget-scrim {
  position: fixed;
  inset: 0;
  z-index: 1698;
  pointer-events: auto;
  background: transparent;
}

.support-widget-panel {
  position: fixed;
  right: var(--support-widget-panel-right);
  bottom: var(--support-widget-panel-bottom);
  z-index: 1702;
  pointer-events: auto;
  width: min(408px, calc(100vw - 32px));
  height: min(82vh, 720px);
  min-height: 560px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(31, 18, 57, 0.98), rgba(13, 10, 24, 0.98)),
    #120B24;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.48);
  transform-origin: calc(100% - 42px) calc(100% - 30px);
  animation: support-widget-panel-in 190ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.support-widget.is-closing .support-widget-panel {
  pointer-events: none;
  animation: support-widget-panel-out 170ms cubic-bezier(0.4, 0, 1, 1) both;
}

@keyframes support-widget-panel-in {
  from {
    opacity: 0;
    transform: translate(10px, 10px) scale(0.88);
    filter: blur(2px);
  }
  to {
    opacity: 1;
    transform: translate(0, 0) scale(1);
    filter: blur(0);
  }
}

@keyframes support-widget-panel-out {
  from {
    opacity: 1;
    transform: translate(0, 0) scale(1);
    filter: blur(0);
  }
  to {
    opacity: 0;
    transform: translate(10px, 10px) scale(0.88);
    filter: blur(2px);
  }
}

.support-widget-header {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 16px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  background:
    radial-gradient(circle at 18% 20%, rgba(219, 39, 119, 0.18), transparent 38%),
    rgba(255, 255, 255, 0.035);
}

.support-widget-header p,
.support-widget-thread-head p {
  margin: 0;
  color: rgba(255, 255, 255, 0.58);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.4;
}

.support-widget-header h2,
.support-widget-thread-head h3 {
  margin: 2px 0 0;
  color: #fff;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.support-widget-header h2 {
  font-size: 18px;
}

.support-widget-close {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.support-widget-body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 12px;
  overflow: hidden;
}

.support-widget-login {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
}

.support-widget-operator-bubble {
  display: grid;
  gap: 7px;
  max-width: 92%;
  padding: 14px;
  border-radius: 18px 18px 18px 6px;
  background: rgba(255, 255, 255, 0.075);
  border: 1px solid rgba(255, 255, 255, 0.10);
}

.support-widget-operator-bubble strong,
.support-widget-operator-bubble p {
  margin: 0;
}

.support-widget-operator-bubble strong {
  color: #fff;
  font-size: 13px;
}

.support-widget-operator-bubble p {
  color: var(--text2);
  font-size: 14px;
  line-height: 1.65;
}

.support-widget-login-actions {
  display: flex;
  gap: 8px;
}

.support-widget-login-actions .support-submit,
.support-widget-login-actions .support-secondary-btn {
  flex: 1;
  justify-content: center;
}

.support-widget-fallback {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.support-widget-fallback div {
  display: grid;
  gap: 4px;
  padding: 11px 12px;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.support-widget-fallback span {
  color: rgba(255, 255, 255, 0.50);
  font-size: 11px;
  font-weight: 850;
}

.support-widget-fallback a,
.support-widget-fallback strong {
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.support-widget-thread-list {
  flex: 0 0 auto;
  display: flex;
  gap: 8px;
  min-width: 0;
  overflow-x: auto;
  padding: 0 0 2px;
  scrollbar-width: thin;
}

.support-widget-thread {
  flex: 0 0 min(188px, 72vw);
  display: grid;
  gap: 4px;
  min-width: 0;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
  padding: 10px 11px;
  cursor: pointer;
}

.support-widget-thread.active {
  border-color: rgba(215, 204, 255, 0.50);
  background: rgba(124, 58, 237, 0.20);
}

.support-widget-thread span,
.support-widget-thread small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-widget-thread span {
  font-size: 13px;
  font-weight: 900;
}

.support-widget-thread small {
  color: rgba(255, 255, 255, 0.56);
  font-size: 11px;
}

.support-widget-room {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
}

.support-widget-thread-head {
  flex: 0 0 auto;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 2px 2px 0;
}

.support-widget-thread-head h3 {
  font-size: 15px;
}

.support-widget-bubbles,
.support-widget-bubble-list {
  flex: 1 1 auto;
  min-height: 0;
  margin: 0;
  padding: 4px 2px 10px;
  overflow: auto;
}

.support-widget-bubbles {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
}

.support-widget-bubble-list {
  min-height: 160px;
}

.support-widget-compose {
  flex: 0 0 auto;
  display: grid;
  gap: 9px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(18, 11, 36, 0), rgba(18, 11, 36, 0.98) 20%),
    rgba(18, 11, 36, 0.96);
}

.support-widget-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.support-widget-chip {
  min-height: 30px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.055);
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  font-weight: 850;
  padding: 0 10px;
  cursor: pointer;
}

.support-widget-chip.active {
  border-color: rgba(215, 204, 255, 0.54);
  background: rgba(124, 58, 237, 0.24);
  color: #fff;
}

.support-widget-privacy-note {
  margin: -1px 0 0;
  color: rgba(255, 255, 255, 0.50);
  font-size: 11px;
  font-weight: 650;
  line-height: 1.5;
  word-break: keep-all;
}

.support-widget-privacy-note button {
  border: 0;
  background: transparent;
  color: #d7ccff;
  font: inherit;
  font-weight: 850;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

.support-widget-status {
  min-height: 17px;
  color: rgba(255, 255, 255, 0.56);
  font-size: 12px;
  line-height: 1.4;
}

.support-widget-status--success {
  color: #C7F9CC;
}

.support-widget-status--error {
  color: #FFB4B4;
}

.support-widget-input-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.support-widget-input-row textarea {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  min-height: 44px;
  max-height: 112px;
  resize: vertical;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.24);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  line-height: 1.5;
  padding: 11px 12px;
  outline: none;
}

.support-widget-input-row textarea:focus {
  border-color: rgba(215, 204, 255, 0.52);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.16);
}

.support-widget-input-row textarea::placeholder {
  color: rgba(255, 255, 255, 0.36);
}

.support-widget-send {
  flex: 0 0 auto;
  min-width: 72px;
  min-height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: var(--support-widget-action-bg);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  padding: 0 14px;
  cursor: pointer;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.24);
  transition: transform var(--ease), filter var(--ease), opacity var(--ease);
}

.support-widget-send:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.support-widget-send:disabled {
  cursor: wait;
  opacity: 0.68;
}

.support-widget-muted {
  margin: 0;
  color: var(--text2);
  font-size: 13px;
  line-height: 1.7;
}

.support-widget-launch-panel p {
  margin: 0 0 12px;
  color: var(--text2);
  font-size: 14px;
  line-height: 1.7;
}

.info-grid,
.info-list {
  display: grid;
  gap: 14px;
}

.info-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.info-grid article,
.info-list article {
  scroll-margin-top: 92px;
  padding: 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.info-grid h2,
.info-list h2 {
  margin: 0 0 10px;
  color: var(--text);
  font-size: 17px;
  line-height: 1.4;
}

.info-grid p,
.info-list p {
  margin: 0;
  color: var(--text2);
  font-size: 14.5px;
  line-height: 1.85;
  word-break: keep-all;
}

.info-list p + p {
  margin-top: 10px;
}

.info-list ul {
  margin: 10px 0 0;
  padding-left: 20px;
  color: var(--text2);
  font-size: 14.5px;
  line-height: 1.85;
  word-break: keep-all;
}

.info-list li + li {
  margin-top: 7px;
}

.info-list a,
.policy-contact a {
  color: #d7ccff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.info-list a:hover,
.policy-contact a:hover {
  color: #fff;
}

@media (max-width: 520px) {
  .account-main {
    padding: 18px 14px 28px;
  }

  .account-panel {
    border-radius: 16px;
    padding: 18px;
  }

  .account-panel h2 {
    font-size: 22px;
  }

  .signup-header {
    min-height: 64px;
    padding: 14px 16px;
  }

  .signup-main {
    align-items: flex-start;
    padding: 18px 14px 34px;
  }

  .signup-panel {
    border-radius: 18px;
    padding: 20px;
  }

  .account-action-row {
    flex-direction: column;
  }

  .service-footer {
    font-size: 11px;
  }

  .service-footer-links {
    gap: 7px 11px;
  }

  .info-main {
    padding: 18px 14px 34px;
  }

  .info-panel {
    border-radius: 16px;
    padding: 18px;
  }

  .info-panel h1 {
    font-size: 24px;
  }

  .policy-meta {
    gap: 8px 12px;
    padding: 12px;
  }

  .policy-toc,
  .policy-related {
    padding: 14px;
  }

  .policy-toc-list {
    grid-template-columns: 1fr;
    font-size: 13px;
  }

  .info-list article {
    padding: 14px;
  }

  .info-list p,
  .info-list ul {
    font-size: 14px;
    line-height: 1.8;
  }

  .info-grid {
    grid-template-columns: 1fr;
  }

  .support-contact-grid {
    grid-template-columns: 1fr;
  }

  .support-message-panel,
  .message-thread-list,
  .message-thread-detail {
    padding: 14px;
  }

  .message-section-head,
  .message-page-toolbar {
    display: grid;
    gap: 10px;
  }

  .support-submit,
  .support-secondary-btn {
    width: 100%;
  }

  .message-inbox {
    grid-template-columns: 1fr;
  }

  .message-inbox--chat,
  .message-inbox--support-compose,
  .admin-message-inbox,
  .message-thread-list,
  .message-thread-detail {
    min-height: 0;
    max-height: none;
  }

  .message-thread-head {
    display: grid;
  }

  .message-thread-actions {
    justify-content: flex-start;
  }

  .message-bubble {
    max-width: 94%;
  }

  .message-bubble-list {
    min-height: 220px;
    max-height: none;
  }

  .support-widget {
    --support-widget-panel-right: 0px;
    --support-widget-panel-bottom: 0px;
    --support-widget-panel-pad: 11px;
    --support-widget-action-right: 16px;
    --support-widget-action-bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  }

  .support-widget.has-bottom-nav {
    --support-widget-action-bottom: calc(78px + env(safe-area-inset-bottom, 0px));
  }

  .support-widget-button {
    min-width: 76px;
    min-height: 46px;
  }

  .support-widget-scrim {
    background: rgba(0, 0, 0, 0.42);
  }

  .support-widget-panel {
    left: 0;
    right: var(--support-widget-panel-right);
    bottom: var(--support-widget-panel-bottom);
    width: 100%;
    max-width: none;
    height: 86vh;
    min-height: 0;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 24px 24px 0 0;
  }

  .support-widget-header {
    padding: 15px 16px 13px;
  }

  .support-widget-body {
    padding: 11px;
  }

  .support-widget-login-actions,
  .support-widget-input-row {
    display: flex;
  }

  .support-widget-login-actions .support-submit,
  .support-widget-login-actions .support-secondary-btn {
    width: auto;
  }

  .support-widget-fallback {
    grid-template-columns: 1fr;
  }

  .support-widget-thread {
    flex-basis: min(182px, 76vw);
  }

  .support-widget-chip-row {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .support-widget-chip {
    flex: 0 0 auto;
  }

  .support-widget-bubble-list {
    min-height: 0;
  }

  .support-widget-send {
    min-width: 58px;
    padding: 0 12px;
  }
}

/* ═══════════════════════════════════════════════════════════
   공개 랜딩
═══════════════════════════════════════════════════════════ */
.landing-page {
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  overflow-y: auto;
  color: #F7F4FF;
  background:
    radial-gradient(circle at 18% 12%, rgba(124, 58, 237, 0.22), transparent 34%),
    radial-gradient(circle at 88% 18%, rgba(219, 39, 119, 0.15), transparent 32%),
    linear-gradient(155deg, #0A0812 0%, #141020 48%, #08070D 100%);
}

.landing-orbit {
  position: fixed;
  width: 520px;
  height: 520px;
  right: -180px;
  top: 120px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  box-shadow:
    inset 0 0 80px rgba(124, 58, 237, 0.08),
    0 0 90px rgba(124, 58, 237, 0.10);
  opacity: 0.82;
}

.landing-card-grid {
  position: fixed;
  right: clamp(18px, 7vw, 96px);
  bottom: clamp(38px, 11vh, 126px);
  width: min(34vw, 360px);
  min-width: 240px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  opacity: 0.92;
  pointer-events: none;
  transform: rotate(-4deg);
  filter: saturate(1.02) contrast(1.10) brightness(1.16);
}

.landing-card-grid span {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.20);
  background: rgba(11, 12, 20, 0.92);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.20),
    inset 0 0 34px rgba(124, 58, 237, 0.16),
    inset 0 -48px 68px rgba(0, 0, 0, 0.30),
    0 24px 58px rgba(0, 0, 0, 0.38),
    0 0 54px rgba(88, 70, 180, 0.16);
  backdrop-filter: blur(10px);
  transform: translateZ(0);
}

.landing-card-grid img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0.90;
  filter: brightness(0.78) saturate(0.90) contrast(1.06);
  transform: scale(1.05);
}

.landing-card-grid span:nth-child(1) img {
  object-position: 50% 48%;
  filter: brightness(0.74) saturate(0.86) contrast(1.08);
}

.landing-card-grid span:nth-child(2) img {
  object-position: 52% 45%;
  filter: brightness(0.78) saturate(0.92) contrast(1.08);
}

.landing-card-grid span:nth-child(3) img {
  object-position: 52% 50%;
  filter: brightness(0.82) saturate(0.94) contrast(1.04);
}

.landing-card-grid span:nth-child(4) img {
  object-position: 50% 50%;
  filter: brightness(0.78) saturate(0.90) contrast(1.06);
}

.landing-card-grid span:nth-child(5) img,
.landing-card-grid span:nth-child(6) img {
  object-position: center;
  filter: brightness(0.72) saturate(0.86) contrast(1.10);
  transform: scale(1.10);
}

.landing-card-grid span:nth-child(2n) {
  transform: translateY(20px);
}

.landing-card-grid span:nth-child(3n) {
  opacity: 0.88;
}

.landing-card-grid span::before,
.landing-card-grid span::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.landing-card-grid span::before {
  background:
    radial-gradient(circle at 42% 22%, rgba(255, 255, 255, 0.12), transparent 26%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent 36%);
  mix-blend-mode: screen;
  opacity: 0.72;
}

.landing-card-grid span::after {
  background:
    linear-gradient(180deg, rgba(4, 5, 9, 0.02), rgba(4, 5, 9, 0.24) 68%, rgba(4, 5, 9, 0.58)),
    radial-gradient(circle at 50% 30%, transparent 0 42%, rgba(0, 0, 0, 0.14) 78%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.20), transparent 19%, transparent 81%, rgba(0, 0, 0, 0.20));
}

.landing-page::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(7, 7, 11, 0.82) 0%, rgba(7, 7, 11, 0.66) 54%, rgba(7, 7, 11, 0.28) 100%),
    linear-gradient(0deg, rgba(7, 7, 11, 0.78) 0%, rgba(7, 7, 11, 0.05) 58%, rgba(7, 7, 11, 0.48) 100%);
}

.landing-header,
.landing-main {
  position: relative;
  z-index: 1;
}

.landing-header {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(18px, 4vw, 48px);
}

.landing-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.landing-account-btn {
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(12, 14, 22, 0.66);
  color: #F2F0FF;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.landing-main {
  min-height: calc(100vh - 144px);
  display: flex;
  align-items: end;
  padding: clamp(30px, 7vh, 78px) clamp(18px, 5vw, 64px) clamp(42px, 8vh, 86px);
}

.landing-hero {
  max-width: 700px;
}

.landing-kicker {
  margin: 0 0 14px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.landing-hero h1 {
  margin: 0;
  max-width: min(100%, 1120px);
  color: #FFFFFF;
  font-size: clamp(40px, 5.4vw, 68px);
  line-height: 1.04;
  letter-spacing: 0;
  word-break: keep-all;
  overflow-wrap: normal;
  line-break: strict;
  text-wrap: balance;
}

.landing-copy {
  max-width: 600px;
  margin: 20px 0 0;
  color: rgba(247, 244, 255, 0.78);
  font-size: clamp(17px, 2.2vw, 22px);
  line-height: 1.62;
}

.landing-status {
  max-width: 580px;
  margin: 18px 0 0;
  color: rgba(234, 229, 255, 0.72);
  font-size: 15px;
  line-height: 1.65;
}

.landing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.landing-btn {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: #FFFFFF;
  font: inherit;
  font-size: 15px;
  font-weight: 750;
  cursor: pointer;
}

.landing-btn--primary {
  border-color: transparent;
  background: #FFFFFF;
  color: #111118;
}

.landing-note {
  max-width: 560px;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.52);
  font-size: 12px;
  line-height: 1.6;
}

@media (max-width: 760px) {
  .landing-header {
    align-items: flex-start;
    padding: 14px 16px;
  }

  .landing-header-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .landing-main {
    min-height: calc(100vh - 68px);
    align-items: end;
    padding: 28px 16px 38px;
  }

  .landing-card-grid {
    right: -32px;
    bottom: 132px;
    min-width: 190px;
    width: 220px;
    gap: 8px;
    opacity: 0.62;
  }

  .landing-orbit {
    width: 330px;
    height: 330px;
    right: -180px;
    top: 96px;
  }

  .landing-hero h1 {
    font-size: clamp(36px, 9.6vw, 46px);
  }

  .landing-actions,
  .landing-actions .landing-btn {
    width: 100%;
  }
}

/* ═══════════════════════════════════════════════════════════
   서브 페이지 데스크탑 max-width 확장
═══════════════════════════════════════════════════════════ */
@media (min-width: 1024px) {
  .sub-page  { max-width: 1280px; }
  .sub-title { font-size: 22px; }
}

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE — TABLET  768px – 1023px
   모바일 디자인 유지하되 카드 조금 크게, 폰트 살짝 키움
═══════════════════════════════════════════════════════════ */
@media (min-width: 768px) and (max-width: 1023px) {
  .v2-home    { max-width: 720px; }

  /* 카드 */
  .v2-card         { width: 150px; height: 200px; border-radius: 16px; }
  .v2-card-title   { font-size: 13px; }

  /* 히어로 */
  .hero-card  { min-height: 248px; }
  .hero-title { font-size: 25px; }

  /* 섹션 제목 */
  .section-title { font-size: 19px; }

  /* 스크롤 간격 */
  .scroll-row  { gap: 14px; }
}

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE — DESKTOP  1024px+
   진짜 데스크탑다운 넓은 레이아웃
═══════════════════════════════════════════════════════════ */
@media (min-width: 1024px) {

  /* ── 전체 컨테이너 ── */
  .v2-home { max-width: 1280px; }

  /* nav도 동일 너비로 */
  .v2-nav {
    max-width: 1280px;
    /* 800px 브레이크포인트에서 설정한 left/transform 유지, width만 확장 */
  }

  /* ── 헤더: full-header-inner 에서 처리 ── */

  /* ── TODAY'S PICK — 가로형 레이아웃 ── */
  .hero-section { padding: 8px 48px 34px; }

  .hero-card {
    flex-direction: row;        /* 세로→가로 전환 */
    justify-content: flex-start;
    align-items: stretch;
    min-height: 292px;
  }

  /* 스크림: 세로(아래→위) → 가로(왼쪽→오른쪽) */
  .hero-card::after {
    background: linear-gradient(
      to right,
      rgba(0,0,0,0.82) 0%,
      rgba(0,0,0,0.40) 50%,
      transparent 80%
    );
  }

  /* 배경 이미지 있을 때: 좌→우 페이드 (좌측 완전 불투명, 우측 투명) */
  /* z-index: 2 는 모바일 규칙에서 이미 설정됨 */
  .hero-card--has-bg::after {
    background: linear-gradient(
      to right,
      rgba(10, 5, 25, 0.97) 0%,
      rgba(10, 5, 25, 0.80) 30%,
      rgba(10, 5, 25, 0.35) 58%,
      transparent 100%
    );
  }

  /* 텍스트 영역: 좌측 55% */
  .hero-body {
    flex: 0 0 55%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 44px 56px;
  }

  .hero-title { font-size: 32px; }
  .hero-desc  { font-size: 14px; -webkit-line-clamp: 3; }
  .hero-btns  { gap: 14px; margin-top: 4px; }
  .hero-btn-primary { padding: 11px 26px; font-size: 14px; }
  .hero-btn-info    { padding: 10px 22px; font-size: 14px; }

  /* 시각 영역: 우측 나머지 (장식용 원) */
  .hero-visual {
    display: block;
    flex: 1;
    position: relative;
    overflow: hidden;
    pointer-events: none;
  }
  .hero-vis-1 {
    position: absolute;
    width: 280px; height: 280px;
    top: -60px; right: -60px;
    border-radius: 50%;
    background: rgba(255,255,255,0.07);
  }
  .hero-vis-2 {
    position: absolute;
    width: 140px; height: 140px;
    bottom: 36px; right: 90px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
  }

  /* ── 홈 메인 ── */
  .home-main     { gap: 42px; }
  .section-head  { padding: 0 48px; }
  .section-title { font-size: 22px; }

  /* ── 스크롤 행 ── */
  .scroll-row  { gap: 16px; padding: 8px 48px 14px; scroll-padding-left: 48px; }
  .popular-row { gap: 4px; padding: 8px 48px 14px; scroll-padding-left: 48px; }
  .service-footer--home { margin: 4px 48px 0; }

  /* ── 카드 180 × 240 ── */
  .v2-card       { width: 180px; height: 240px; border-radius: 18px; }
  .v2-card-title { font-size: 14px; line-height: 1.4; }
  .v2-card-cat   { font-size: 10px; }

  /* ── 인기 순위 번호 ── */
  .rank-num { width: 76px; padding-bottom: 16px; font-size: 120px; }
  .popular-item .v2-card { margin-left: -18px; }

  /* ── 스크롤 화살표 — 카드 영역 좌우 끝에 오버레이 ── */
  .scroll-arrow        { width: 44px; height: 44px; font-size: 20px; }
  .scroll-arrow-left   { left:  48px; }   /* scroll-row padding과 동일 */
  .scroll-arrow-right  { right: 48px; }
}
