:root {
  --ink: #284338;
  --muted: #6e8178;
  --green: #55c267;
  --green-dark: #267a45;
  --blue: #5ebde8;
  --blue-dark: #246e9f;
  --orange: #ffad43;
  --coral: #ff7b61;
  --purple: #a969df;
  --cream: #fffaf0;
  --paper: rgba(255, 255, 255, .94);
  --border: rgba(59, 99, 77, .14);
  --shadow: 0 18px 45px rgba(36, 92, 60, .16);
  --soft-shadow: 0 10px 24px rgba(35, 76, 54, .13);
  font-family: "Arial Rounded MT Bold", "Malgun Gothic", "Apple SD Gothic Neo", sans-serif;
  color: var(--ink);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 10% 3%, rgba(255,255,255,.95) 0 80px, transparent 81px),
    radial-gradient(circle at 85% 8%, rgba(255,255,255,.8) 0 105px, transparent 106px),
    linear-gradient(180deg, #c8f1ff 0, #eafbd9 32%, #fff8e9 100%);
  overflow-x: hidden;
}
button, audio { font: inherit; }
button { color: inherit; }
img { display: block; max-width: 100%; }
a { color: inherit; }

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 999;
  padding: 12px 18px;
  border-radius: 12px;
  background: #143d2a;
  color: white;
  text-decoration: none;
}
.skip-link:focus { top: 16px; }

.sky-decoration { position: fixed; inset: 0; pointer-events: none; z-index: -1; }
.sky-decoration i { position: absolute; color: rgba(255, 196, 45, .6); font-style: normal; animation: twinkle 2.7s ease-in-out infinite; }
.sky-decoration i:nth-child(1) { top: 13%; left: 4%; font-size: 28px; }
.sky-decoration i:nth-child(2) { top: 19%; right: 6%; font-size: 18px; animation-delay: .7s; }
.sky-decoration i:nth-child(3) { top: 63%; right: 3%; font-size: 34px; animation-delay: 1.2s; }
.sky-decoration i:nth-child(4) { top: 75%; left: 3%; font-size: 22px; animation-delay: 1.8s; }

.app-shell { width: min(1380px, calc(100% - 32px)); margin: 0 auto; }
.topbar {
  position: sticky;
  top: 12px;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 12px 0 20px;
  padding: 8px 14px 8px 16px;
  border: 2px solid rgba(255,255,255,.9);
  border-radius: 24px;
  background: rgba(255,255,255,.88);
  box-shadow: var(--soft-shadow);
  backdrop-filter: blur(14px);
  white-space: nowrap;
}
.brand {
  border: 0;
  background: transparent;
  display: flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
  text-align: left;
  flex-shrink: 0;
  white-space: nowrap;
  padding: 2px 4px;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: linear-gradient(145deg, #8be37e, #4db960);
  box-shadow: inset 0 2px 0 rgba(255,255,255,.7), 0 5px 10px rgba(51,139,71,.22);
  font-size: 22px;
  flex-shrink: 0;
}
.brand b { display: block; font-size: 19px; color: #23683b; white-space: nowrap; font-weight: 900; letter-spacing: -0.3px; line-height: 1.2; }
.brand small { display: block; margin-top: 1px; font-size: 11px; color: #728278; white-space: nowrap; }
.topbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  white-space: nowrap;
}
.desktop-nav {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: nowrap;
}
.desktop-nav button {
  border: 0;
  border-radius: 14px;
  padding: 8px 11px;
  background: transparent;
  font-weight: 800;
  font-size: 13.5px;
  cursor: pointer;
  transition: all .2s ease;
  white-space: nowrap !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  line-height: 1;
  flex-shrink: 0;
  color: #284338;
}
.desktop-nav button:hover, .desktop-nav button.is-active {
  background: #eff9ef;
  color: #1e7a3c;
  transform: translateY(-2px);
}
.desktop-nav span {
  font-size: 16px;
  line-height: 1;
  display: inline-block;
  margin-right: 2px;
}

.bgm-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 13px 6px 9px;
  border-radius: 999px;
  border: 2px solid rgba(85, 194, 103, 0.45);
  background: #f4fbf5;
  color: #284338;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 2px 8px rgba(38, 122, 69, 0.1);
  user-select: none;
  flex-shrink: 0;
}
.bgm-toggle-btn:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 6px 14px rgba(38, 122, 69, 0.2);
  border-color: #55c267;
}
.bgm-toggle-btn .bgm-icon {
  font-size: 15px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(85, 194, 103, 0.2);
  transition: transform 0.3s ease;
}
.bgm-toggle-btn.is-playing .bgm-icon {
  animation: bgmPulse 1.2s infinite alternate ease-in-out;
  background: #55c267;
  color: #fff;
}
.bgm-toggle-btn .bgm-text {
  display: flex;
  flex-direction: column;
  text-align: left;
  line-height: 1.1;
}
.bgm-toggle-btn .bgm-text small {
  font-size: 9.5px;
  color: #6e8178;
  font-weight: 800;
}
.bgm-toggle-btn .bgm-text b {
  font-size: 11.5px;
  color: #c94040;
}
.bgm-toggle-btn.is-playing {
  background: linear-gradient(135deg, #e8fbee 0%, #d4f7de 100%);
  border-color: #4db960;
  box-shadow: 0 4px 16px rgba(77, 185, 96, 0.35);
}
.bgm-toggle-btn.is-playing .bgm-text b {
  color: #1e873b;
}

@keyframes bgmPulse {
  0% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.18) rotate(-10deg); }
  100% { transform: scale(1) rotate(10deg); }
}

.page { display: none; animation: pageIn .38s ease both; }
.page.is-active { display: block; }
.home-page {
  overflow: hidden;
  min-height: 720px;
  border-radius: 42px;
  border: 4px solid rgba(255,255,255,.92);
  background:
    linear-gradient(90deg, rgba(250,255,246,.98) 0 42%, rgba(247,255,244,.25) 72%),
    url("assets/jeongseon-world.png") center/cover;
  box-shadow: var(--shadow);
}
.home-hero { display: grid; grid-template-columns: 1.04fr .96fr; min-height: 480px; padding: 68px 64px 22px; }
.hero-copy { align-self: center; z-index: 2; }
.eyebrow {
  display: inline-block;
  margin-bottom: 13px;
  padding: 8px 13px;
  border-radius: 999px;
  background: #e6f7dc;
  color: #2b8144;
  font-weight: 900;
  font-size: 13px;
  letter-spacing: -.02em;
}
.eyebrow.coral { color: #b34d37; background: #fff0e8; }
.eyebrow.blue-text { color: #246e9f; background: #e7f6ff; }
.hero-copy h1 { margin: 0; font-size: clamp(48px, 6.2vw, 78px); line-height: 1.04; letter-spacing: -.07em; color: #275c3d; }
.hero-copy h1 em { color: #ff8a39; font-style: normal; text-shadow: 0 4px 0 white; }
.hero-copy p { max-width: 570px; margin: 22px 0 26px; font-size: 18px; font-weight: 700; line-height: 1.75; color: #587267; word-break: keep-all; }
.primary-button {
  border: 0;
  border-radius: 18px;
  padding: 15px 20px;
  background: linear-gradient(180deg, #ffcf51, #ffa937);
  color: #6a4514;
  box-shadow: inset 0 3px 0 rgba(255,255,255,.7), 0 8px 0 #d98025, 0 13px 24px rgba(177,101,30,.2);
  font-weight: 1000;
  cursor: pointer;
  transition: .18s ease;
}
.primary-button:hover { transform: translateY(-3px); }
.primary-button:active { transform: translateY(4px); box-shadow: inset 0 2px 0 rgba(255,255,255,.6), 0 3px 0 #d98025; }
.primary-button span { margin-left: 10px; }

.mascot-stage { position: relative; display: grid; place-items: end center; min-height: 410px; }
.mascot-button { position: relative; z-index: 2; width: min(390px, 90%); border: 0; background: transparent; cursor: pointer; filter: drop-shadow(0 18px 20px rgba(30,74,44,.23)); animation: mascotFloat 3s ease-in-out infinite; }
.mascot-button img { width: 100%; max-height: 410px; object-fit: contain; filter: drop-shadow(0 15px 24px rgba(30,70,45,.24)); }
.mascot-button:active { transform: scale(.96); }
.mascot-speech {
  position: absolute;
  z-index: 4;
  top: 0;
  right: 0;
  width: 245px;
  padding: 16px 18px;
  border: 4px solid #83ca6a;
  border-radius: 24px 24px 24px 7px;
  background: white;
  box-shadow: var(--soft-shadow);
  font-size: 14px;
  font-weight: 900;
  line-height: 1.5;
  word-break: keep-all;
}
.spark { position: absolute; color: #ffcf31; font-size: 28px; animation: twinkle 1.8s ease-in-out infinite; }
.spark-one { top: 25%; left: 4%; }.spark-two { top: 17%; right: 2%; animation-delay: .6s; }.spark-three { bottom: 18%; right: 4%; animation-delay: 1.1s; }

.door-section { position: relative; z-index: 5; margin: 0 30px 30px; padding: 28px; border-radius: 32px; background: rgba(255,255,255,.92); box-shadow: var(--soft-shadow); }
.section-heading { text-align: center; margin: 0 auto 24px; }
.section-heading.compact { display: flex; align-items: end; justify-content: space-between; text-align: left; gap: 16px; }
.section-heading span { display: block; margin-bottom: 5px; color: #6a8a78; font-size: 13px; font-weight: 900; }
.section-heading h2 { margin: 0; font-size: clamp(27px, 4vw, 39px); letter-spacing: -.05em; }
.door-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.door-card {
  min-height: 182px;
  border: 0;
  border-radius: 26px;
  padding: 22px 16px 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: white;
  text-align: center;
  cursor: pointer;
  box-shadow: inset 0 4px 0 rgba(255,255,255,.35), 0 8px 0 rgba(44,84,55,.19), 0 14px 22px rgba(50,83,61,.13);
  transition: .2s ease;
}
.door-card:hover { transform: translateY(-6px) rotate(-1deg); }
.door-card:active { transform: translateY(3px); box-shadow: inset 0 3px 0 rgba(255,255,255,.3), 0 3px 0 rgba(44,84,55,.19); }
.door-card.green { background: linear-gradient(145deg, #67d16d, #2cae61); }
.door-card.blue { background: linear-gradient(145deg, #70d3f0, #3a9ed8); }
.door-card.orange { background: linear-gradient(145deg, #ffc456, #ff9239); }
.door-card.purple { background: linear-gradient(145deg, #c27ae8, #8c54d1); }
.door-icon { display: grid; place-items: center; width: 58px; height: 58px; border-radius: 20px; background: rgba(255,255,255,.93); font-size: 31px; box-shadow: 0 8px 16px rgba(44,61,50,.15); }
.door-card b { display: block; font-size: 18px; text-shadow: 0 2px 0 rgba(39,69,49,.18); }
.door-card small { display: block; margin-top: 5px; font-size: 11px; opacity: .94; }
.door-card i { padding: 7px 12px; border-radius: 999px; background: rgba(255,255,255,.21); font-size: 11px; font-style: normal; font-weight: 900; }

.themed-page { overflow: hidden; border: 4px solid rgba(255,255,255,.95); border-radius: 40px; background: var(--paper); box-shadow: var(--shadow); }
.page-hero { position: relative; min-height: 335px; padding: 64px 64px 46px; overflow: hidden; isolation: isolate; }
.page-hero::after { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(90deg, rgba(255,255,255,.96), rgba(255,255,255,.55) 58%, rgba(255,255,255,.1)); }
.page-hero::before { content: ""; position: absolute; inset: 0; z-index: -3; background: url("assets/jeongseon-world.png") center/cover; }
.back-button { border: 0; padding: 9px 13px; border-radius: 999px; background: rgba(255,255,255,.78); box-shadow: 0 5px 14px rgba(54,86,67,.12); font-size: 12px; font-weight: 900; cursor: pointer; }
.page-hero-copy { margin-top: 28px; max-width: 690px; }
.page-kicker { display: inline-block; margin-bottom: 8px; font-size: 13px; font-weight: 900; color: #47725b; }
.page-hero h1 { margin: 0; font-size: clamp(44px, 6vw, 68px); line-height: 1.05; letter-spacing: -.07em; }
.page-hero h1 em { color: var(--green-dark); font-style: normal; }
.page-hero p { max-width: 650px; margin: 17px 0 0; font-size: 17px; line-height: 1.65; font-weight: 800; color: #587065; word-break: keep-all; }
.content-wrap { padding: 42px 44px 55px; }

.arirang-hero { background: linear-gradient(135deg, rgba(255,240,212,.75), rgba(255,255,255,.25)); }
.arirang-hero h1 em { color: #e96a4b; }
.hero-sticker { position: absolute; right: 8%; top: 88px; width: 200px; height: 200px; display: grid; place-items: center; border: 8px solid white; border-radius: 50%; background: linear-gradient(145deg, #ffcc5a, #ff7d5f); box-shadow: var(--shadow); color: white; font-size: 25px; font-weight: 1000; transform: rotate(7deg); }
.hero-sticker span { display: block; position: absolute; bottom: 36px; right: 31px; font-size: 35px; }
.fact-bubbles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; margin-bottom: 36px; }
.fact-bubbles article { display: flex; gap: 13px; padding: 22px; border: 2px solid #f1e1ca; border-radius: 24px; background: #fffaf2; }
.fact-bubbles article > span { display: grid; place-items: center; flex: 0 0 48px; height: 48px; border-radius: 16px; background: white; font-size: 27px; box-shadow: 0 5px 14px rgba(111,80,45,.11); }
.fact-bubbles b { display: block; margin: 2px 0 8px; font-size: 17px; }
.fact-bubbles p { margin: 0; color: #65746c; line-height: 1.55; font-size: 13px; font-weight: 700; word-break: keep-all; }
/* ==========================================================
   ARIRANG MUSIC PLAYER STATION (정선아리랑 뮤직 스테이션)
   ========================================================== */
.arirang-station-wrapper {
  margin: 35px 0 25px;
  padding: 36px 36px 42px;
  border-radius: 36px;
  background: linear-gradient(145deg, #1b2720 0%, #121c17 100%);
  border: 2px solid rgba(138, 201, 158, 0.22);
  box-shadow: 0 24px 60px rgba(12, 28, 18, 0.45);
  color: #f1f8f3;
}

.station-top-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  flex-wrap: wrap;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  margin-bottom: 30px;
}
.station-official-badge {
  display: inline-block;
  padding: 6px 13px;
  border-radius: 999px;
  background: rgba(85, 194, 103, 0.18);
  border: 1px solid rgba(85, 194, 103, 0.35);
  color: #7ce890;
  font-size: 11px;
  font-weight: 900;
  margin-bottom: 8px;
}
.station-header-text h2 {
  margin: 0 0 6px;
  font-size: clamp(26px, 3.4vw, 36px);
  letter-spacing: -.04em;
  color: #ffffff;
}
.station-header-text p {
  margin: 0;
  font-size: 14px;
  color: #b5cdc0;
  font-weight: 700;
  line-height: 1.5;
}
.station-header-stats {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.stat-pill {
  padding: 6px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 11px;
  font-weight: 800;
  color: #e2f0e7;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* 스테이션 2컬럼 레이아웃 */
.station-main-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  margin-bottom: 35px;
}

/* 좌측 턴테이블 카드 */
.station-turntable-card {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  padding: 24px;
  backdrop-filter: blur(10px);
}
.turntable-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 250px;
  padding: 20px 0 15px;
}
.vinyl-record-wrap {
  position: relative;
  width: 200px;
  height: 200px;
  display: grid;
  place-items: center;
}
.vinyl-disc {
  width: 190px;
  height: 190px;
  border-radius: 50%;
  background: radial-gradient(circle, #1a1a1a 0%, #0d0d0d 65%, #050505 100%);
  border: 4px solid #333;
  box-shadow: 0 12px 30px rgba(0,0,0,0.7), inset 0 0 12px rgba(255,255,255,0.15);
  display: grid;
  place-items: center;
  position: relative;
  transition: transform 0.4s ease;
}
.vinyl-groove-rings {
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 0 0 8px rgba(0,0,0,0.3), inset 0 0 0 16px rgba(255,255,255,0.04), inset 0 0 0 24px rgba(0,0,0,0.4), inset 0 0 0 32px rgba(255,255,255,0.03);
}
.vinyl-center-label {
  position: relative;
  z-index: 2;
  width: 78px;
  height: 78px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff8c42, #ff5757);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  text-align: center;
  padding: 4px;
  box-shadow: inset 0 2px 4px rgba(255,255,255,0.5), 0 3px 8px rgba(0,0,0,0.4);
}
.vinyl-label-icon { font-size: 16px; line-height: 1; }
.vinyl-center-label b { font-size: 10px; line-height: 1.1; margin-top: 2px; }
.vinyl-center-label small { font-size: 8px; opacity: 0.9; }

/* 턴테이블 톤암 */
.turntable-tonearm {
  position: absolute;
  top: 5px;
  right: -5px;
  width: 50px;
  height: 120px;
  pointer-events: none;
  transform-origin: 35px 15px;
  transform: rotate(-10deg);
  transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 5;
}
.tonearm-base {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(145deg, #bbb, #666);
  box-shadow: 0 4px 8px rgba(0,0,0,0.4);
}
.tonearm-rod {
  position: absolute;
  top: 15px;
  right: 14px;
  width: 4px;
  height: 95px;
  background: linear-gradient(to bottom, #ddd, #888);
  border-radius: 2px;
  transform: rotate(8deg);
}
.tonearm-head {
  position: absolute;
  bottom: 5px;
  right: 2px;
  width: 14px;
  height: 20px;
  background: #ff5757;
  border-radius: 3px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.5);
}

.vinyl-disc.is-spinning {
  animation: spinRecord 5s linear infinite;
}
.turntable-tonearm.is-playing {
  transform: rotate(24deg);
}

@keyframes spinRecord {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* 실시간 EQ 비주얼라이저 */
.eq-visualizer-bar {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 32px;
  margin-top: 16px;
}
.eq-col {
  display: block;
  width: 5px;
  height: 4px;
  border-radius: 3px;
  background: linear-gradient(to top, #41b860, #88ea9e);
  transition: height 0.2s ease;
}
.eq-visualizer-bar.is-active .eq-1 { animation: eqBounce 0.5s ease-in-out infinite 0.1s; }
.eq-visualizer-bar.is-active .eq-2 { animation: eqBounce 0.7s ease-in-out infinite 0.25s; }
.eq-visualizer-bar.is-active .eq-3 { animation: eqBounce 0.4s ease-in-out infinite 0.05s; }
.eq-visualizer-bar.is-active .eq-4 { animation: eqBounce 0.8s ease-in-out infinite 0.35s; }
.eq-visualizer-bar.is-active .eq-5 { animation: eqBounce 0.6s ease-in-out infinite 0.15s; }
.eq-visualizer-bar.is-active .eq-6 { animation: eqBounce 0.75s ease-in-out infinite 0.4s; }
.eq-visualizer-bar.is-active .eq-7 { animation: eqBounce 0.55s ease-in-out infinite 0.2s; }
.eq-visualizer-bar.is-active .eq-8 { animation: eqBounce 0.65s ease-in-out infinite 0.3s; }

@keyframes eqBounce {
  0%, 100% { height: 4px; opacity: 0.5; }
  50% { height: 28px; opacity: 1; }
}

/* 현재 재생 트랙 정보 & 컨트롤러 */
.now-playing-panel {
  margin-top: 10px;
}
.now-track-meta {
  text-align: center;
  margin-bottom: 16px;
}
.now-track-genre {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 140, 66, 0.2);
  border: 1px solid rgba(255, 140, 66, 0.4);
  color: #ffaa6b;
  font-size: 10px;
  font-weight: 900;
  margin-bottom: 6px;
}
.now-track-title {
  margin: 0 0 4px;
  font-size: 20px;
  color: #ffffff;
  letter-spacing: -.03em;
}
.now-track-artist {
  margin: 0;
  font-size: 12px;
  color: #a4c4b2;
  font-weight: 750;
}

/* 오디오 타임라인 프로그레스바 */
.audio-timeline-wrap {
  margin-bottom: 18px;
}
.time-display {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #92b0a0;
  font-weight: 800;
  font-family: monospace;
  margin-bottom: 6px;
}
.timeline-bar-bg {
  position: relative;
  width: 100%;
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  cursor: pointer;
}
.timeline-bar-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #50c46b, #84fab0);
  pointer-events: none;
}
.timeline-bar-handle {
  position: absolute;
  top: 50%;
  left: 0%;
  transform: translate(-50%, -50%);
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 2px 6px rgba(0,0,0,0.4);
  pointer-events: none;
}

/* 컨트롤러 버튼군 */
.station-controls-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.control-main-btn, .control-sub-btn, .control-play-btn {
  border: 0;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: transform 0.15s ease, background 0.2s ease;
}
.control-main-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: white;
  font-size: 16px;
}
.control-main-btn:hover {
  background: rgba(255, 255, 255, 0.24);
  transform: scale(1.08);
}
.control-sub-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: transparent;
  color: #9ab4a5;
  font-size: 15px;
}
.control-sub-btn:hover {
  color: white;
  transform: scale(1.1);
}
.control-sub-btn.is-active {
  color: #ffcf43;
  background: rgba(255, 207, 67, 0.15);
}
.control-play-btn {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4ade80, #22c55e);
  color: #0b3819;
  font-size: 22px;
  font-weight: 1000;
  box-shadow: 0 8px 24px rgba(34, 197, 94, 0.4);
}
.control-play-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 10px 28px rgba(34, 197, 94, 0.55);
}
.control-play-btn.is-playing {
  background: linear-gradient(135deg, #ffb03a, #f97316);
  color: #431a00;
  box-shadow: 0 8px 24px rgba(249, 115, 22, 0.4);
}
.station-volume-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: 6px;
}
#arirangVolumeRange {
  width: 65px;
  accent-color: #4ade80;
  cursor: pointer;
}

/* 우측 탭 상세 카드 (가사/해설/교재) */
.station-detail-card {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  padding: 24px;
  backdrop-filter: blur(10px);
  min-height: 480px;
}
.station-tabs-nav {
  display: flex;
  gap: 8px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 18px;
  overflow-x: auto;
}
.station-tab-btn {
  border: 0;
  padding: 10px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.07);
  color: #a4c2b2;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
  transition: .18s ease;
  white-space: nowrap;
}
.station-tab-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  color: white;
}
.station-tab-btn.is-active {
  background: #3e9955;
  color: white;
  box-shadow: 0 4px 14px rgba(62, 153, 85, 0.35);
}

.station-tab-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* 가사 탭 */
.lyrics-header, .story-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}
.lyrics-title, .story-title {
  font-size: 14px;
  font-weight: 900;
  color: #7de894;
}
.copy-lyrics-btn {
  border: 0;
  padding: 6px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  color: #d1e8dc;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  transition: .18s ease;
}
.copy-lyrics-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: white;
}
.lyrics-scroll-box {
  flex: 1;
  max-height: 380px;
  overflow-y: auto;
  padding: 16px 20px;
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.lyrics-text {
  font-size: 14px;
  line-height: 1.85;
  color: #e5f3ec;
  font-weight: 700;
  white-space: pre-line;
}

/* 곡 해설 탭 */
.story-scroll-box {
  flex: 1;
  max-height: 380px;
  overflow-y: auto;
  padding: 18px 20px;
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.story-meta-box {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.story-badge {
  padding: 4px 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 11px;
  font-weight: 800;
  color: #ffcb77;
}
.story-desc {
  font-size: 13.5px;
  line-height: 1.8;
  color: #d9ebe1;
  font-weight: 700;
}
.story-desc b { color: #88ea9e; }
.story-desc i { color: #fce79a; font-style: normal; }

/* 교재 탭 */
.guidebook-card {
  padding: 20px;
  border-radius: 20px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.guidebook-badge-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.guidebook-official-tag {
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(94, 219, 138, 0.2);
  color: #7de894;
  font-size: 10.5px;
  font-weight: 900;
}
.guidebook-size-tag {
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #cbdad1;
  font-size: 10.5px;
  font-weight: 800;
}
.guidebook-card h3 {
  margin: 0 0 8px;
  font-size: 18px;
  color: #ffffff;
}
.guidebook-card p {
  margin: 0 0 16px;
  font-size: 12.5px;
  line-height: 1.6;
  color: #b8d2c4;
}
.guidebook-highlights {
  display: grid;
  gap: 8px;
  margin-bottom: 20px;
}
.highlight-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
}
.highlight-item span { font-size: 20px; }
.highlight-item b { font-size: 12px; color: #ffdf79; display: block; }
.highlight-item small { font-size: 11px; color: #a4c4b2; font-weight: 700; }
.guidebook-actions {
  display: flex;
  gap: 10px;
}
.guidebook-btn {
  padding: 10px 16px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: .18s ease;
}
.guidebook-btn.primary {
  background: #3e9955;
  color: white;
}
.guidebook-btn.primary:hover { background: #35874a; transform: translateY(-2px); }
.guidebook-btn.secondary {
  background: rgba(255, 255, 255, 0.12);
  color: #e5f3ec;
}
.guidebook-btn.secondary:hover { background: rgba(255, 255, 255, 0.22); transform: translateY(-2px); }

/* 하단 12곡 플레이리스트 쥬크박스 */
.station-playlist-container {
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.playlist-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.playlist-heading h3 {
  margin: 0 0 4px;
  font-size: 18px;
  color: #ffffff;
}
.playlist-heading small {
  font-size: 12px;
  color: #92b0a0;
  font-weight: 700;
}
.playlist-filter-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.p-filter-pill {
  border: 0;
  padding: 7px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #b0c9bb;
  font-size: 11px;
  font-weight: 850;
  cursor: pointer;
  transition: .18s ease;
}
.p-filter-pill:hover { background: rgba(255, 255, 255, 0.16); color: white; }
.p-filter-pill.is-active {
  background: #ff8c42;
  color: white;
  box-shadow: 0 4px 12px rgba(255, 140, 66, 0.35);
}

.playlist-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.playlist-track-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 13px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: .18s ease;
}
.playlist-track-card:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(94, 219, 138, 0.35);
  transform: translateY(-2px);
}
.playlist-track-card.is-active {
  background: linear-gradient(90deg, rgba(62, 153, 85, 0.35), rgba(41, 105, 58, 0.25));
  border-color: #55c267;
  box-shadow: 0 6px 18px rgba(46, 133, 68, 0.25);
}
.p-card-left {
  display: flex;
  align-items: center;
  gap: 12px;
}
.track-num-circle {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  font-size: 11px;
  font-weight: 1000;
  color: #88ea9e;
}
.playlist-track-card.is-active .track-num-circle {
  background: #55c267;
  color: #0d3618;
}
.track-meta { display: flex; flex-direction: column; gap: 2px; }
.track-name { font-size: 13px; color: #ffffff; }
.track-sub { font-size: 10.5px; color: #9bb7a8; font-weight: 700; }
.p-card-right {
  display: flex;
  align-items: center;
  gap: 10px;
}
.track-tag-pill {
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 9.5px;
  font-weight: 800;
  color: #ffd079;
}
.track-duration {
  font-size: 11px;
  color: #83a492;
  font-family: monospace;
}
.track-play-status-btn {
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
}
.track-play-status {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  font-size: 10px;
  font-weight: 900;
  color: #b5d8c5;
}
.playlist-track-card.is-active .track-play-status {
  background: #55c267;
  color: #0b3819;
}

.say-along { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 26px; padding: 21px; border-radius: 24px; background: linear-gradient(90deg, #fff0c8, #fff8e7); border: 3px dashed #ffc45e; text-align: center; }
.say-along > span { font-size: 38px; }.say-along small, .say-along b { display: block; }.say-along small { color: #9c7631; font-size: 11px; }.say-along b { margin-top: 4px; font-size: 24px; color: #674314; }

.library-hero { background: linear-gradient(135deg, rgba(218,246,255,.75), rgba(255,255,255,.2)); }
.library-hero h1 em { color: var(--blue-dark); }
.library-building { position: absolute; right: 8%; bottom: 32px; width: 235px; height: 205px; display: flex; flex-direction: column; align-items: center; justify-content: center; border: 9px solid white; border-radius: 38px 38px 22px 22px; background: linear-gradient(180deg, #79d9f3 0 37%, #fff6d6 38%); box-shadow: var(--shadow); transform: rotate(2deg); }
.library-building::before { content: ""; position: absolute; left: -15px; right: -15px; top: 62px; height: 25px; border-radius: 9px; background: #ff9146; box-shadow: inset 0 5px 0 #ffc170; }
.library-building span { position: relative; z-index: 2; font-size: 52px; }.library-building b { position: relative; z-index: 2; margin-top: 12px; font-size: 16px; }.library-building i { position: absolute; top: 12px; right: 14px; padding: 6px 9px; border-radius: 999px; background: #fff9d5; color: #d57835; font-size: 10px; font-style: normal; font-weight: 900; }
.service-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.service-grid article { min-height: 195px; padding: 26px 20px; border-radius: 25px; background: white; border: 2px solid #dcecf3; box-shadow: 0 10px 20px rgba(50,104,132,.08); text-align: center; }
.service-grid article:nth-child(2n) { transform: translateY(10px); }
.service-grid span { display: grid; place-items: center; width: 63px; height: 63px; margin: 0 auto 15px; border-radius: 21px; background: #e5f7ff; font-size: 32px; }
.service-grid b { display: block; font-size: 18px; }.service-grid p { margin: 9px 0 0; color: #6b7b73; line-height: 1.55; font-size: 13px; font-weight: 700; }
.library-tour { display: grid; grid-template-columns: .78fr 1.22fr; gap: 35px; align-items: center; margin: 54px 0 32px; padding: 30px; border-radius: 32px; background: #edf9ff; border: 2px solid #d6edf7; }
.shelf-illustration { position: relative; height: 290px; border-radius: 25px; background: linear-gradient(180deg, #c8edfa 0 58%, #8bd49d 59%); overflow: hidden; }
.shelf-illustration::before, .shelf-illustration::after { content: ""; position: absolute; left: 32px; right: 32px; height: 15px; border-radius: 8px; background: #b6713c; box-shadow: 0 8px 0 rgba(94,53,22,.12); }
.shelf-illustration::before { top: 115px; }.shelf-illustration::after { top: 220px; }
.book { position: absolute; bottom: 175px; width: 35px; border-radius: 7px 7px 2px 2px; box-shadow: inset -5px 0 rgba(0,0,0,.08); }
.b1 { left: 50px; height: 75px; background: #ff7f66; }.b2 { left: 89px; height: 92px; background: #ffca4b; }.b3 { left: 128px; height: 66px; background: #66c77a; }.b4 { left: 168px; height: 86px; background: #6ebbe7; }.b5 { left: 208px; height: 58px; background: #b96eda; }
.shelf-illustration i { position: absolute; z-index: 2; right: 26px; bottom: 30px; font-style: normal; font-size: 72px; transform: rotate(-7deg); }
.library-tour h2 { margin: 2px 0 20px; font-size: 32px; letter-spacing: -.05em; }
.library-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.library-steps li { display: flex; gap: 12px; align-items: center; padding: 12px; border-radius: 17px; background: white; }
.library-steps li > span { display: grid; place-items: center; flex: 0 0 38px; height: 38px; border-radius: 14px; background: #5ebde8; color: white; font-weight: 1000; }
.library-steps b, .library-steps small { display: block; }.library-steps b { font-size: 14px; }.library-steps small { margin-top: 3px; color: #71827a; font-size: 11px; font-weight: 700; }
.library-info { display: grid; grid-template-columns: 1.3fr .8fr auto; gap: 12px; align-items: center; padding: 19px; border-radius: 23px; background: #316e91; color: white; }
.library-info > div { display: flex; gap: 10px; align-items: center; }.library-info > div > span { font-size: 25px; }.library-info small, .library-info b { display: block; }.library-info small { color: #c8e8f6; font-size: 10px; }.library-info b { margin-top: 2px; font-size: 12px; }
.library-info a { padding: 11px 14px; border-radius: 14px; background: white; color: #276586; text-decoration: none; font-size: 12px; font-weight: 1000; }

.places-hero { background: linear-gradient(135deg, rgba(255,240,206,.7), rgba(255,255,255,.15)); }
.places-hero h1 em { color: #e6782f; }
.places-hero-character {
  position: absolute;
  right: 6%;
  bottom: 25px;
  width: 210px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  filter: drop-shadow(0 14px 28px rgba(30, 74, 44, 0.18));
  animation: floatSubtle 3.5s ease-in-out infinite;
}
.places-character-img {
  width: 100%;
  border-radius: 24px;
  border: 4px solid #ffffff;
  object-fit: cover;
  box-shadow: 0 8px 20px rgba(0,0,0,.1);
}
.places-char-badge {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  background: #ffaa38;
  color: #4f2900;
  font-size: 11px;
  font-weight: 1000;
  box-shadow: 0 4px 10px rgba(0,0,0,.15);
}

.place-filter { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.place-filter button { border: 2px solid #e2e8e3; border-radius: 999px; padding: 11px 17px; background: white; font-size: 12px; font-weight: 1000; cursor: pointer; transition: .18s ease; }
.place-filter button:hover, .place-filter button.is-active { border-color: #ffad43; background: #fff2d9; color: #a75f18; transform: translateY(-2px); }
.place-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.place-card { overflow: hidden; border: 2px solid #e7e8df; border-radius: 25px; background: white; box-shadow: 0 10px 24px rgba(57,79,59,.09); transition: .2s ease; }
.place-card:hover { transform: translateY(-5px); box-shadow: 0 17px 32px rgba(57,79,59,.16); }
.place-card img { width: 100%; height: 190px; object-fit: cover; }
.place-card-body { position: relative; padding: 20px; }
.place-card-tag { display: inline-block; margin-bottom: 8px; padding: 6px 9px; border-radius: 999px; font-size: 10px; font-weight: 1000; }
.place-card[data-kind="nature"] .place-card-tag { color: #217243; background: #e4f7e9; }
.place-card[data-kind="tradition"] .place-card-tag { color: #a25524; background: #fff0df; }
.place-card[data-kind="sight"] .place-card-tag { color: #405aba; background: #e9edff; }
.place-card h2 { margin: 0 0 8px; font-size: 20px; letter-spacing: -.04em; }.place-card p { margin: 0; color: #69776f; font-size: 13px; line-height: 1.6; font-weight: 700; word-break: keep-all; }

.story-hero { background: linear-gradient(135deg, rgba(244,228,255,.72), rgba(255,255,255,.14)); }
.story-hero h1 em { color: #8e52c8; }
.open-book { position: absolute; right: 8%; bottom: 47px; width: 260px; height: 190px; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,.72); box-shadow: var(--shadow); font-size: 92px; transform: rotate(2deg); }
.open-book span { position: absolute; bottom: 18px; padding: 8px 13px; border-radius: 999px; background: #8e52c8; color: white; font-size: 11px; font-weight: 900; }
.storybook { display: grid; grid-template-columns: .9fr 1.1fr; min-height: 500px; overflow: hidden; border: 3px solid #ecdffc; border-radius: 34px; background: #fffdfc; box-shadow: var(--soft-shadow); }
.storybook-visual { min-height: 500px; background-position: center; background-size: cover; transition: .25s ease; }
.storybook-copy { display: flex; flex-direction: column; padding: 48px 45px 35px; }
.chapter-label { align-self: flex-start; padding: 8px 12px; border-radius: 999px; background: #f1e3ff; color: #7c45b4; font-size: 12px; font-weight: 1000; }
.storybook-copy h2 { margin: 18px 0 16px; font-size: clamp(31px, 4.5vw, 45px); line-height: 1.15; letter-spacing: -.06em; }
.storybook-copy > p { margin: 0; min-height: 165px; color: #5d6e65; font-size: 17px; line-height: 1.85; font-weight: 700; word-break: keep-all; }
.story-question { margin-top: 18px; padding: 15px 17px; border-radius: 17px; background: #fff4ce; color: #7b5e20; font-size: 13px; font-weight: 900; line-height: 1.5; }
.story-controls { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; margin-top: auto; padding-top: 22px; }
.story-controls > button { border: 0; border-radius: 15px; padding: 11px 14px; background: #8f5cc2; color: white; font-size: 12px; font-weight: 1000; cursor: pointer; }
.story-controls > button:disabled { opacity: .35; cursor: default; }
.story-dots { display: flex; justify-content: center; gap: 8px; }
.story-dot { width: 13px; height: 13px; border: 0; border-radius: 50%; background: #d8c9e7; cursor: pointer; padding: 0; }
.story-dot.is-active { width: 31px; border-radius: 999px; background: #9a62cf; }
.adventure-book { margin-top: 34px; padding: 34px; border: 3px solid #dfe9d4; border-radius: 34px; background: linear-gradient(145deg, #fffef8, #f5fbef); box-shadow: var(--soft-shadow); }
.adventure-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 20px; }
.book-kicker { display: inline-block; margin-bottom: 8px; padding: 7px 11px; border-radius: 999px; background: #e5f5d9; color: #3f7d39; font-size: 11px; font-weight: 1000; }
.adventure-heading h2 { margin: 0 0 8px; color: #3c513d; font-size: clamp(31px, 4vw, 43px); letter-spacing: -.06em; }
.adventure-heading p { margin: 0; color: #68786c; font-size: 14px; line-height: 1.7; font-weight: 800; word-break: keep-all; }
.book-badge { flex: 0 0 auto; padding: 14px 18px; border: 2px solid #fff; border-radius: 20px; background: #8d62bc; color: #efe5fa; box-shadow: 0 8px 20px rgba(88,57,122,.18); text-align: center; font-size: 10px; line-height: 1.45; font-weight: 800; transform: rotate(2deg); }
.book-badge b { display: block; color: white; font-size: 14px; }

/* PDF 원본 그림책 배너 및 뷰어 */
.pdf-book-banner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 20px;
  align-items: center;
  margin-bottom: 22px;
  padding: 20px 24px;
  border-radius: 24px;
  background: linear-gradient(135deg, #ffffff 0%, #f4fbf5 100%);
  border: 2.5px solid #c0e6ce;
  box-shadow: 0 10px 28px rgba(35, 100, 60, 0.09);
}
.pdf-book-icon-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.pdf-book-icon {
  font-size: 38px;
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 18px;
  background: #e7f8ed;
  box-shadow: 0 4px 12px rgba(45, 120, 70, 0.12);
}
.pdf-format-pill {
  font-size: 9.5px;
  font-weight: 1000;
  padding: 2px 8px;
  border-radius: 999px;
  background: #ff5479;
  color: white;
  letter-spacing: -0.02em;
}
.pdf-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 5px;
}
.pdf-official-tag {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  background: #def4e4;
  color: #1a7437;
  font-size: 10.5px;
  font-weight: 900;
}
.pdf-book-info h3 {
  margin: 0;
  font-size: 19px;
  letter-spacing: -.03em;
  color: #204632;
}
.pdf-book-info p {
  margin: 0;
  font-size: 13px;
  color: #556c60;
  font-weight: 750;
  line-height: 1.55;
}
.pdf-book-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.pdf-action-btn {
  border: 0;
  padding: 11px 16px;
  border-radius: 14px;
  font-size: 12.5px;
  font-weight: 900;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s ease;
  white-space: nowrap;
}
.pdf-action-btn.primary {
  background: linear-gradient(135deg, #2ea44f, #238636);
  color: white;
  box-shadow: 0 4px 12px rgba(35, 134, 54, 0.3);
}
.pdf-action-btn.primary:hover {
  transform: translateY(-2px);
  background: #279444;
  box-shadow: 0 6px 16px rgba(35, 134, 54, 0.4);
}
.pdf-action-btn.secondary {
  background: #f0f7f2;
  color: #245838;
  border: 1.5px solid #c2decc;
}
.pdf-action-btn.secondary:hover {
  background: #e1efe5;
  transform: translateY(-2px);
}
.pdf-action-btn.outline {
  background: white;
  color: #6c3db5;
  border: 1.5px solid #d5c2f0;
}
.pdf-action-btn.outline:hover, .pdf-action-btn.outline.is-active {
  background: #f6f0ff;
  border-color: #9258cf;
  transform: translateY(-2px);
}

.inline-pdf-viewer {
  margin-bottom: 24px;
  border-radius: 26px;
  overflow: hidden;
  border: 3.5px solid #7c4dc5;
  background: #1e1e24;
  box-shadow: 0 16px 40px rgba(40, 20, 70, 0.25);
  animation: pageIn 0.3s ease both;
}
.pdf-viewer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 13px 22px;
  background: linear-gradient(90deg, #32254d, #251b3b);
  color: white;
  font-size: 13.5px;
  font-weight: 900;
}
.pdf-close-btn {
  border: 0;
  padding: 6px 14px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.16);
  color: white;
  font-size: 11.5px;
  font-weight: 900;
  cursor: pointer;
  transition: 0.15s ease;
}
.pdf-close-btn:hover {
  background: rgba(255, 255, 255, 0.3);
}
.pdf-viewer-frame-wrap {
  position: relative;
  width: 100%;
  height: 680px;
  background: #525659;
}
.pdf-iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.adventure-art-banner {
  margin: 0 0 24px;
  border-radius: 26px;
  overflow: hidden;
  border: 3px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 12px 30px rgba(50, 75, 55, 0.12);
  background: #ffffff;
}
.adventure-art-img {
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  display: block;
}
.adventure-art-caption {
  display: block;
  padding: 11px 20px;
  background: #f7faf5;
  color: #43634e;
  font-size: 12.5px;
  font-weight: 800;
  text-align: center;
  border-top: 1px solid #e7ede2;
}
.adventure-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.adventure-card { position: relative; min-height: 245px; overflow: hidden; padding: 25px 20px 20px; border: 2px solid rgba(255,255,255,.92); border-radius: 25px; box-shadow: 0 10px 24px rgba(65,78,57,.1); }
.adventure-card::after { content: ''; position: absolute; right: -24px; bottom: -24px; width: 90px; height: 90px; border-radius: 50%; background: rgba(255,255,255,.38); }
.adventure-card.green { background: #e5f7df; }.adventure-card.blue { background: #e2f3ff; }.adventure-card.yellow { background: #fff4c9; }
.adventure-card.orange { background: #ffe8d2; }.adventure-card.purple { background: #eee4ff; }.adventure-card.pink { background: #ffe4ea; }
.adventure-number { position: absolute; top: 13px; right: 15px; width: 29px; height: 29px; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,.9); color: #665577; font-size: 12px; font-weight: 1000; }
.adventure-icon { display: grid; place-items: center; width: 61px; height: 61px; margin-bottom: 15px; border-radius: 19px; background: rgba(255,255,255,.76); font-size: 31px; transform: rotate(-3deg); }
.adventure-card:nth-child(even) .adventure-icon { transform: rotate(3deg); }
.adventure-card h3 { position: relative; z-index: 1; margin: 0 0 9px; color: #3e4e43; font-size: 20px; letter-spacing: -.04em; }
.adventure-card p { position: relative; z-index: 1; margin: 0; color: #5c6c62; font-size: 12px; line-height: 1.7; font-weight: 750; word-break: keep-all; }
.adventure-finish { display: flex; align-items: center; gap: 16px; margin-top: 18px; padding: 18px 21px; border-radius: 22px; background: #415e48; color: white; }
.adventure-finish > span { flex: 0 0 auto; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 17px; background: rgba(255,255,255,.13); font-size: 28px; }
.adventure-finish b { display: block; margin-bottom: 4px; color: #d8f5ca; font-size: 13px; }
.adventure-finish p { margin: 0; font-size: 12px; line-height: 1.55; font-weight: 750; word-break: keep-all; }
.book-source-note { margin: 14px 4px 0; color: #758278; font-size: 10px; line-height: 1.55; font-weight: 700; word-break: keep-all; }
.closing-card { display: flex; align-items: center; gap: 22px; margin-top: 28px; padding: 23px 28px; border-radius: 28px; background: linear-gradient(135deg, #e9f8df, #fff3c9); border: 3px dashed #9bd279; }
.closing-card img { width: 130px; height: 130px; object-fit: cover; border-radius: 22px; border: 3.5px solid #ffffff; box-shadow: 0 8px 20px rgba(45,90,55,.18); }
.closing-card small, .closing-card b { display: block; }.closing-card small { color: #5e8d49; font-size: 11px; font-weight: 900; }.closing-card b { margin: 5px 0 13px; font-size: 18px; line-height: 1.45; }.closing-card button { border: 0; border-radius: 14px; padding: 10px 13px; background: #65bd62; color: white; font-size: 11px; font-weight: 1000; cursor: pointer; }

.home-hero-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.game-shortcut-btn {
  border: 0;
  border-radius: 18px;
  padding: 15px 22px;
  background: linear-gradient(180deg, #ff6b8b, #e03b62);
  color: white;
  box-shadow: inset 0 3px 0 rgba(255,255,255,.6), 0 8px 0 #b32143, 0 13px 24px rgba(224,59,98,.28);
  font-weight: 1000;
  cursor: pointer;
  transition: .18s ease;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.game-shortcut-btn:hover { transform: translateY(-3px); }
.game-shortcut-btn:active { transform: translateY(4px); box-shadow: inset 0 2px 0 rgba(255,255,255,.5), 0 3px 0 #b32143; }

.view-all-games-tag {
  border: 0;
  background: #fff0f3;
  color: #d82b56;
  border: 1.5px solid #ffccd7;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  transition: .18s ease;
}
.view-all-games-tag:hover { background: #ffe1e8; transform: translateY(-2px); }

.door-grid.five-doors { grid-template-columns: repeat(5, 1fr); }
.door-card.red-game {
  background: linear-gradient(145deg, #ff6b8b, #e93d65);
  box-shadow: inset 0 4px 0 rgba(255,255,255,.38), 0 8px 0 rgba(160,25,55,.28), 0 14px 22px rgba(233,61,101,.22);
}
.door-card.highlight-door { position: relative; }
.door-card.highlight-door::before {
  content: "HOT";
  position: absolute;
  top: 10px;
  right: 10px;
  background: #ffe600;
  color: #b02100;
  font-size: 9px;
  font-weight: 1000;
  padding: 3px 7px;
  border-radius: 999px;
  box-shadow: 0 3px 6px rgba(0,0,0,.15);
}

.nav-games-btn { color: #d82b56 !important; background: #fff1f4 !important; }
.nav-games-btn:hover, .nav-games-btn.is-active { background: #ffe0e7 !important; transform: translateY(-2px); }

/* ==========================================================
   MAIN PAGE IN-GAME SECTION (정선이의 별빛 보물대작전)
   ========================================================== */
.home-game-section {
  position: relative;
  z-index: 5;
  margin: 10px 30px 35px;
}
.main-game-wrapper {
  background: #111a24;
  border: 3.5px solid rgba(255, 255, 255, .95);
  border-radius: 32px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(18, 48, 34, .18), 0 0 0 1px rgba(0,0,0,.08);
}
.main-game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 24px;
  background: linear-gradient(90deg, #192736, #131e2b);
  border-bottom: 2px solid rgba(255, 255, 255, .1);
  color: white;
}
.main-game-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.main-game-badge {
  padding: 5px 12px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ffb800, #ff8c00);
  color: #3b2200;
  font-size: 11px;
  font-weight: 1000;
  box-shadow: 0 3px 10px rgba(255,184,0,.3);
}
.main-game-title-group h2 {
  margin: 0;
  font-size: 20px;
  letter-spacing: -.04em;
  color: #ffffff;
}
.main-game-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}
.game-tool-btn {
  border: 0;
  padding: 9px 15px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  background: rgba(255, 255, 255, .12);
  color: #e2f0f8;
  text-decoration: none;
  transition: .18s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.game-tool-btn:hover {
  background: rgba(255, 255, 255, .22);
  transform: translateY(-2px);
}
.game-tool-btn.primary {
  background: #2ea44f;
  color: white;
  box-shadow: 0 4px 12px rgba(46,164,79,.35);
}
.game-tool-btn.primary:hover {
  background: #2c974b;
}

.main-game-frame {
  position: relative;
  width: 100%;
  height: 640px;
  background: #090d12;
}
.main-game-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.main-game-footer {
  padding: 12px 24px;
  background: #141f2c;
  border-top: 1px solid rgba(255, 255, 255, .08);
  color: #a4c2d6;
  font-size: 12px;
  font-weight: 750;
  text-align: center;
}
.main-game-footer b { color: #ffd644; }

.home-door-section {
  margin-top: 25px;
  margin-bottom: 40px;
}

/* ==========================================================
   GAME GALLERY PAGE STYLES
   ========================================================== */
.games-hero { background: linear-gradient(135deg, rgba(255,233,240,.82), rgba(237,243,255,.65)); }
.games-hero h1 em { color: #d82b56; }

.arcade-badge {
  position: absolute;
  right: 7%;
  top: 55px;
  width: 220px;
  height: 195px;
  background: #252b42;
  border: 7px solid #455073;
  border-radius: 28px 28px 18px 18px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 16px 14px 14px;
  transform: rotate(3deg);
}
.arcade-screen {
  width: 100%;
  height: 100px;
  border-radius: 16px;
  background: #0f1423;
  border: 3px solid #1cbb7a;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #5efc82;
  text-shadow: 0 0 10px rgba(94,252,130,.7);
}
.pixel-star { font-size: 20px; animation: twinkle 1s infinite alternate; }
.arcade-screen b { font-size: 16px; letter-spacing: .08em; font-family: monospace; }
.arcade-screen small { font-size: 9px; color: #a4e9bd; margin-top: 3px; font-weight: 800; }
.arcade-buttons { display: flex; gap: 14px; margin-top: 6px; }
.arcade-buttons i { display: block; width: 22px; height: 22px; border-radius: 50%; box-shadow: 0 4px 0 rgba(0,0,0,.4); }
.arcade-buttons i:nth-child(1) { background: #ff4757; }
.arcade-buttons i:nth-child(2) { background: #ffa502; }
.arcade-buttons i:nth-child(3) { background: #2ed573; }

/* 갤러리 상단 환영 배너 */
.gallery-welcome-banner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 22px 26px;
  border-radius: 26px;
  background: linear-gradient(135deg, #fff7ea 0%, #fff0f5 100%);
  border: 2px solid #ffdfdf;
  box-shadow: 0 8px 24px rgba(220,90,120,.09);
  margin-bottom: 30px;
}
.banner-icon-group {
  display: flex;
  align-items: center;
}
.gallery-lead-icon {
  font-size: 32px;
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  border-radius: 20px;
  background: white;
  box-shadow: 0 8px 18px rgba(220,120,140,.16);
}
.banner-text b { display: block; font-size: 18px; color: #2b3933; margin-bottom: 5px; }
.banner-text p { margin: 0; font-size: 13px; color: #6d7d74; font-weight: 750; line-height: 1.55; }
.banner-links { display: flex; flex-wrap: wrap; gap: 8px; }
.padlet-btn, .workshop-btn {
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  transition: .18s ease;
  white-space: nowrap;
}
.padlet-btn { background: #ff4b72; color: white; box-shadow: 0 4px 12px rgba(255,75,114,.3); }
.padlet-btn:hover { transform: translateY(-2px); background: #eb3860; }
.workshop-btn { background: white; color: #32644e; border: 1.5px solid #d4e5dc; }
.workshop-btn:hover { background: #f2f9f5; transform: translateY(-2px); }

/* 검색 및 필터 바 */
.game-controls-bar {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 32px;
}
.game-search-box {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}
.search-icon { position: absolute; left: 18px; font-size: 18px; color: #8ea096; pointer-events: none; }
.game-search-box input {
  width: 100%;
  height: 52px;
  padding: 0 46px 0 50px;
  border-radius: 20px;
  border: 2.5px solid #e1ebdf;
  background: white;
  font-size: 14px;
  font-weight: 800;
  color: var(--ink);
  transition: .2s ease;
  box-shadow: 0 6px 18px rgba(45,85,60,.06);
}
.game-search-box input:focus {
  border-color: #ff6b8b;
  box-shadow: 0 0 0 5px rgba(255,107,139,.15);
}
.clear-search-btn {
  position: absolute;
  right: 14px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 0;
  background: #e2e8e3;
  color: #5d6e64;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  display: grid;
  place-items: center;
}
.clear-search-btn:hover { background: #cfd8d1; }

.game-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  justify-content: center;
}
.game-filter button {
  border: 2px solid #e1e7e2;
  border-radius: 999px;
  padding: 11px 18px;
  background: white;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  transition: .18s ease;
  color: #4f6358;
}
.game-filter button:hover {
  border-color: #ff8fa5;
  background: #fff4f6;
  color: #cf2d53;
  transform: translateY(-2px);
}
.game-filter button.is-active {
  border-color: #ff4772;
  background: linear-gradient(135deg, #ff577e, #e8325e);
  color: white;
  box-shadow: 0 6px 16px rgba(232,50,94,.28);
  transform: translateY(-2px);
}

/* 게임 카드 그리드 */
.game-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.game-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 28px;
  background: white;
  border: 2.5px solid #edf1ee;
  box-shadow: 0 12px 30px rgba(35,68,50,.08);
  padding: 24px;
  transition: all .25s cubic-bezier(.25,.8,.25,1);
  overflow: hidden;
}
.game-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 8px;
}
.game-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 42px rgba(35,68,50,.16);
  border-color: rgba(255,107,139,.4);
}

.game-card-top {
  display: flex;
  gap: 15px;
  align-items: flex-start;
  margin-bottom: 14px;
}
.game-card-avatar {
  flex: 0 0 60px;
  height: 60px;
  border-radius: 20px;
  display: grid;
  place-items: center;
  font-size: 32px;
  box-shadow: 0 8px 18px rgba(0,0,0,.08);
  transition: .2s ease;
}
.game-card:hover .game-card-avatar { transform: scale(1.08) rotate(-4deg); }

.game-card-meta {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.game-badge {
  align-self: flex-start;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 1000;
}
.game-creator { margin-top: 2px; }
.creator-name { font-size: 14px; color: #20362b; }
.creator-role { display: block; font-size: 10px; color: #7f9187; font-weight: 700; }

.game-card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}
.game-title {
  margin: 0 0 10px;
  font-size: 21px;
  letter-spacing: -.04em;
  color: #1e3328;
}
.game-tags-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 12px;
}
.game-tag-pill {
  padding: 4px 8px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 850;
  background: #f1f6f3;
  color: #4b6658;
}
.game-desc {
  margin: 0 0 18px;
  font-size: 13px;
  line-height: 1.6;
  color: #5c7065;
  font-weight: 700;
  word-break: keep-all;
}

.game-card-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  padding-top: 14px;
  border-top: 1.5px dashed #eaefe9;
}
.game-play-btn {
  border: 0;
  border-radius: 14px;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 1000;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: .18s ease;
  color: white;
  box-shadow: 0 5px 14px rgba(0,0,0,.12);
}
.game-play-btn:hover { transform: translateY(-2px); }
.game-play-btn:active { transform: translateY(2px); }

.game-ext-btn {
  padding: 11px 14px;
  border-radius: 14px;
  background: #f1f5f2;
  color: #3b5447;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  border: 1px solid #dce4de;
  transition: .18s ease;
  white-space: nowrap;
}
.game-ext-btn:hover { background: #e3ede6; transform: translateY(-2px); }

/* 테마별 색상 스타일 */
.theme-pink::before { background: linear-gradient(90deg, #ff758c, #ff7eb3); }
.theme-pink .game-card-avatar { background: #ffe6eb; }
.theme-pink .game-badge { background: #ffe1e8; color: #d82b56; }
.theme-pink .game-play-btn { background: linear-gradient(135deg, #ff5e83, #e82c57); box-shadow: 0 6px 16px rgba(232,44,87,.3); }

.theme-cyan::before { background: linear-gradient(90deg, #00d2ff, #3a7bd5); }
.theme-cyan .game-card-avatar { background: #e0f7fc; }
.theme-cyan .game-badge { background: #d7f4fa; color: #02829d; }
.theme-cyan .game-play-btn { background: linear-gradient(135deg, #02b6db, #0881bf); box-shadow: 0 6px 16px rgba(2,182,219,.3); }

.theme-green::before { background: linear-gradient(90deg, #43e97b, #38f9d7); }
.theme-green .game-card-avatar { background: #e2f9ec; }
.theme-green .game-badge { background: #daf5e4; color: #1e7d44; }
.theme-green .game-play-btn { background: linear-gradient(135deg, #2ebf68, #189e4e); box-shadow: 0 6px 16px rgba(46,191,104,.3); }

.theme-yellow::before { background: linear-gradient(90deg, #f6d365, #fda085); }
.theme-yellow .game-card-avatar { background: #fff4d8; }
.theme-yellow .game-badge { background: #ffeed0; color: #a46104; }
.theme-yellow .game-play-btn { background: linear-gradient(135deg, #f59e0b, #d97706); box-shadow: 0 6px 16px rgba(245,158,11,.3); }

.theme-orange::before { background: linear-gradient(90deg, #ff9966, #ff5e62); }
.theme-orange .game-card-avatar { background: #ffe9df; }
.theme-orange .game-badge { background: #ffe4d7; color: #c94314; }
.theme-orange .game-play-btn { background: linear-gradient(135deg, #f97316, #ea580c); box-shadow: 0 6px 16px rgba(249,115,22,.3); }

.theme-mint::before { background: linear-gradient(90deg, #84fab0, #8fd3f4); }
.theme-mint .game-card-avatar { background: #e6faf2; }
.theme-mint .game-badge { background: #dcf6eb; color: #158359; }
.theme-mint .game-play-btn { background: linear-gradient(135deg, #10b981, #059669); box-shadow: 0 6px 16px rgba(16,185,129,.3); }

.theme-blue::before { background: linear-gradient(90deg, #667eea, #764ba2); }
.theme-blue .game-card-avatar { background: #edf1fe; }
.theme-blue .game-badge { background: #e5eafc; color: #4057c2; }
.theme-blue .game-play-btn { background: linear-gradient(135deg, #4f46e5, #4338ca); box-shadow: 0 6px 16px rgba(79,70,229,.3); }

.theme-purple::before { background: linear-gradient(90deg, #c471ed, #f64f59); }
.theme-purple .game-card-avatar { background: #f6ebfd; }
.theme-purple .game-badge { background: #f0e0fb; color: #8332b7; }
.theme-purple .game-play-btn { background: linear-gradient(135deg, #9333ea, #7e22ce); box-shadow: 0 6px 16px rgba(147,51,234,.3); }

.theme-red::before { background: linear-gradient(90deg, #f857a6, #ff5858); }
.theme-red .game-card-avatar { background: #ffe7eb; }
.theme-red .game-badge { background: #fedade; color: #c71b38; }
.theme-red .game-play-btn { background: linear-gradient(135deg, #ef4444, #dc2626); box-shadow: 0 6px 16px rgba(239,68,68,.3); }

.theme-gold::before { background: linear-gradient(90deg, #fbc2eb, #a6c1ee); }
.theme-gold .game-card-avatar { background: #fff8dc; }
.theme-gold .game-badge { background: #fef0c7; color: #97600b; }
.theme-gold .game-play-btn { background: linear-gradient(135deg, #d97706, #b45309); box-shadow: 0 6px 16px rgba(217,119,6,.3); }

.theme-indigo::before { background: linear-gradient(90deg, #30cfd0, #330867); }
.theme-indigo .game-card-avatar { background: #e8ecf8; }
.theme-indigo .game-badge { background: #dfe5f7; color: #2d45a3; }
.theme-indigo .game-play-btn { background: linear-gradient(135deg, #3b82f6, #2563eb); box-shadow: 0 6px 16px rgba(59,130,246,.3); }

.theme-teal::before { background: linear-gradient(90deg, #0ba360, #3cba92); }
.theme-teal .game-card-avatar { background: #e6f7f5; }
.theme-teal .game-badge { background: #d7f3ee; color: #0d796e; }
.theme-teal .game-play-btn { background: linear-gradient(135deg, #0d9488, #0f766e); box-shadow: 0 6px 16px rgba(13,148,136,.3); }

.theme-night::before { background: linear-gradient(90deg, #141e30, #243b55); }
.theme-night { background: linear-gradient(145deg, #ffffff, #f0f4fc); }
.theme-night .game-card-avatar { background: #1c263a; color: #ffd700; }
.theme-night .game-badge { background: #1e293b; color: #f8fafc; }
.theme-night .game-play-btn { background: linear-gradient(135deg, #1e293b, #0f172a); box-shadow: 0 6px 16px rgba(30,41,59,.3); }

.theme-coral::before { background: linear-gradient(90deg, #ff758c, #ff7eb3); }
.theme-coral .game-card-avatar { background: #fff0f3; }
.theme-coral .game-badge { background: #ffe4eb; color: #cf2d5b; }
.theme-coral .game-play-btn { background: linear-gradient(135deg, #f43f5e, #e11d48); box-shadow: 0 6px 16px rgba(244,63,94,.3); }

.theme-sunset::before { background: linear-gradient(90deg, #fa709a, #fee140); }
.theme-sunset .game-card-avatar { background: #fff1e8; }
.theme-sunset .game-badge { background: #ffe8db; color: #bc420f; }
.theme-sunset .game-play-btn { background: linear-gradient(135deg, #ea580c, #c2410c); box-shadow: 0 6px 16px rgba(234,88,12,.3); }

/* 검색 결과 없을 때 */
.no-game-result {
  text-align: center;
  padding: 60px 20px;
  background: white;
  border-radius: 28px;
  border: 2px dashed #dbe5de;
}
.empty-icon { font-size: 50px; display: block; margin-bottom: 12px; }
.no-game-result h3 { margin: 0 0 8px; font-size: 22px; color: #284338; }
.no-game-result p { margin: 0 0 20px; color: #6a7d72; font-size: 14px; font-weight: 700; }
.no-game-result button {
  border: 0;
  border-radius: 14px;
  padding: 12px 20px;
  background: #ff577e;
  color: white;
  font-weight: 900;
  font-size: 13px;
  cursor: pointer;
}

/* 하단 패들렛 소통 및 응원 배너 */
.padlet-invite-banner {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 30px;
  align-items: center;
  margin-top: 55px;
  padding: 38px 44px;
  border-radius: 34px;
  background: linear-gradient(135deg, #1f4233 0%, #153226 100%);
  color: white;
  box-shadow: 0 20px 48px rgba(18,48,34,.28);
}
.padlet-tag {
  display: inline-block;
  margin-bottom: 10px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.18);
  color: #ffdf79;
  font-size: 12px;
  font-weight: 1000;
}
.padlet-banner-copy h2 { margin: 0 0 12px; font-size: clamp(26px, 3.5vw, 36px); letter-spacing: -.05em; color: #fff; }
.padlet-banner-copy p { margin: 0 0 24px; color: #d2e4db; font-size: 14px; line-height: 1.7; font-weight: 700; }
.padlet-banner-btn {
  display: inline-block;
  padding: 14px 22px;
  border-radius: 16px;
  font-size: 14px;
  font-weight: 1000;
  text-decoration: none;
  background: #ff577e;
  color: white;
  box-shadow: 0 6px 18px rgba(255,87,126,.38);
  transition: .18s ease;
}
.padlet-banner-btn:hover { transform: translateY(-2px); background: #eb3e66; box-shadow: 0 10px 24px rgba(255,87,126,.5); }
.padlet-banner-art { display: grid; place-items: center; }
.padlet-banner-art img, .padlet-ballerina-art {
  width: min(220px, 90%);
  max-height: 220px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 20px;
  border: 3px solid rgba(255, 255, 255, 0.28);
  box-shadow: 0 12px 28px rgba(0,0,0,.45), 0 0 0 1px rgba(255, 182, 193, 0.3);
  animation: mascotFloat 3.2s ease-in-out infinite;
  transition: transform .25s ease, box-shadow .25s ease;
}
.padlet-ballerina-art:hover {
  transform: scale(1.03) translateY(-4px);
  box-shadow: 0 16px 36px rgba(0,0,0,.55), 0 0 16px rgba(255, 182, 193, 0.4);
}

/* ==========================================================
   IN-APP GAME MODAL STYLES
   ========================================================== */
.game-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all .25s ease;
}
.game-modal.is-open {
  opacity: 1;
  visibility: visible;
}
.game-modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 18, 14, .75);
  backdrop-filter: blur(8px);
}
.game-modal-window {
  position: relative;
  z-index: 2;
  width: min(960px, 100%);
  height: min(720px, 90vh);
  background: #141d24;
  border-radius: 28px;
  border: 3px solid rgba(255, 255, 255, .15);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .6);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: pageIn .3s ease;
}
.game-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 22px;
  background: #1a252f;
  border-bottom: 2px solid rgba(255, 255, 255, .08);
}
.modal-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}
.modal-creator-badge {
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .12);
  color: #ffb800;
  font-size: 11px;
  font-weight: 900;
}
.game-modal-header h2 {
  margin: 0;
  font-size: 19px;
  color: white;
  letter-spacing: -.03em;
}
.modal-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.modal-ext-btn {
  padding: 8px 14px;
  border-radius: 12px;
  background: #ff577e;
  color: white;
  text-decoration: none;
  font-size: 12px;
  font-weight: 900;
  box-shadow: 0 4px 12px rgba(255, 87, 126, .35);
  transition: .18s ease;
}
.modal-ext-btn:hover { background: #e83a63; transform: translateY(-2px); }
.modal-close-btn {
  border: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .12);
  color: white;
  font-size: 16px;
  font-weight: 900;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: .18s ease;
}
.modal-close-btn:hover { background: rgba(255, 255, 255, .25); transform: rotate(90deg); }
.game-modal-body {
  position: relative;
  flex: 1;
  background: #080c10;
}
.game-modal-body iframe {
  width: 100%;
  height: 100%;
  border: 0;
}
.modal-loading-spinner {
  position: absolute;
  inset: 0;
  background: #141d24;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: #c9d8e2;
  font-size: 14px;
  font-weight: 800;
  z-index: 1;
}
.spinner-circle {
  width: 44px;
  height: 44px;
  border: 4px solid rgba(255,255,255,.15);
  border-top-color: #ff577e;
  border-radius: 50%;
  animation: spin 1s infinite linear;
}
@keyframes spin { to { transform: rotate(360deg); } }

footer { display: flex; justify-content: space-between; gap: 20px; padding: 24px 10px 95px; color: #61746a; font-size: 11px; font-weight: 700; }
footer p { margin: 0; }
.mobile-nav { display: none; }

button:focus-visible, a:focus-visible { outline: 4px solid #ffcf43; outline-offset: 3px; }

@keyframes pageIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes mascotFloat { 0%,100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-11px) rotate(1deg); } }
@keyframes twinkle { 0%,100% { transform: scale(.75) rotate(-8deg); opacity: .35; } 50% { transform: scale(1.2) rotate(8deg); opacity: 1; } }

@media (max-width: 980px) {
  .home-hero { grid-template-columns: 1fr .75fr; padding: 60px 38px 18px; }
  .mascot-speech { width: 205px; right: -10px; }
  .door-grid.five-doors { grid-template-columns: repeat(3, 1fr); }
  .door-grid { grid-template-columns: repeat(2, 1fr); }
  .fact-bubbles { grid-template-columns: 1fr; }
  .arirang-station-wrapper { padding: 26px 20px 32px; }
  .station-main-grid { grid-template-columns: 1fr; }
  .music-room { grid-template-columns: .8fr 1.2fr; }
  .service-grid { grid-template-columns: repeat(2, 1fr); }
  .place-grid { grid-template-columns: repeat(2, 1fr); }
  .game-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-welcome-banner { grid-template-columns: 1fr; text-align: center; }
  .banner-icon { margin: 0 auto; }
  .banner-icon-group { justify-content: center; }
  .banner-links { justify-content: center; }
  .padlet-invite-banner { grid-template-columns: 1fr; text-align: center; }
  .promo-actions { justify-content: center; }
  .hero-sticker, .library-building, .postcard-stack, .open-book, .arcade-badge { right: 3%; transform: scale(.8); transform-origin: right center; }
}

@media (max-width: 720px) {
  body { padding-bottom: 78px; }
  .app-shell { width: min(100% - 16px, 680px); }
  .topbar { position: relative; top: 0; margin: 8px 0 12px; padding: 8px 12px; border-radius: 19px; }
  .desktop-nav { display: none; }
  .brand-mark { width: 39px; height: 39px; border-radius: 13px; }
  .brand b { font-size: 18px; }.brand small { font-size: 9px; }
  .home-page, .themed-page { border-width: 3px; border-radius: 27px; }
  .home-page { background: linear-gradient(180deg, rgba(250,255,246,.96) 0 54%, rgba(247,255,244,.28) 78%), url("assets/jeongseon-world.png") center/cover; }
  .home-hero { display: flex; flex-direction: column; min-height: 0; padding: 38px 22px 5px; }
  .hero-copy { text-align: center; }
  .hero-copy h1 { font-size: 45px; }
  .hero-copy p { margin: 16px auto 22px; font-size: 14px; line-height: 1.65; }
  .home-hero-actions { justify-content: center; }
  .mascot-stage { min-height: 300px; margin-top: 15px; }
  .mascot-button { width: 265px; }
  .mascot-button img { max-height: 290px; }
  .mascot-speech { top: 10px; right: 2%; width: 170px; padding: 12px; border-width: 3px; border-radius: 18px 18px 18px 6px; font-size: 10px; }
  .home-game-section { margin: 12px 8px 26px; }
  .main-game-wrapper { border-radius: 24px; border-width: 2.5px; }
  .main-game-header { flex-direction: column; align-items: flex-start; gap: 10px; padding: 12px 15px; }
  .main-game-title-group h2 { font-size: 17px; }
  .main-game-controls { width: 100%; justify-content: flex-end; }
  .main-game-frame { height: 460px; }
  .door-section { margin: 0 10px 12px; padding: 18px 13px; border-radius: 23px; }
  .home-door-section { margin-top: 15px; }
  .section-heading.compact { display: block; text-align: center; }.section-heading h2 { font-size: 27px; }
  .view-all-games-tag { display: inline-block; margin-top: 8px; }
  .door-grid.five-doors { grid-template-columns: repeat(2, 1fr); }
  .door-grid { gap: 9px; }
  .door-card { min-height: 155px; border-radius: 20px; padding: 15px 8px; }
  .door-icon { width: 48px; height: 48px; border-radius: 16px; font-size: 25px; }
  .door-card b { font-size: 14px; }.door-card small { font-size: 9px; }
  .page-hero { min-height: 305px; padding: 28px 23px 35px; }
  .page-hero::after { background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(255,255,255,.79) 75%, rgba(255,255,255,.45)); }
  .page-hero-copy { margin-top: 35px; text-align: center; }
  .page-hero h1 { font-size: 42px; }
  .page-hero p { font-size: 14px; }
  .page-kicker { font-size: 11px; }
  .hero-sticker, .library-building, .postcard-stack, .places-hero-character, .open-book, .arcade-badge { display: none; }
  .content-wrap { padding: 25px 16px 36px; }
  .fact-bubbles article { padding: 17px; }
  
  .arirang-station-wrapper { padding: 20px 14px 28px; border-radius: 26px; }
  .station-top-header { flex-direction: column; align-items: flex-start; gap: 12px; }
  .station-header-text h2 { font-size: 24px; }
  .station-turntable-card, .station-detail-card { padding: 16px 14px; border-radius: 22px; }
  .turntable-stage { min-height: 190px; }
  .vinyl-record-wrap { width: 155px; height: 155px; }
  .vinyl-disc { width: 150px; height: 150px; }
  .vinyl-center-label { width: 62px; height: 62px; }
  .turntable-tonearm { height: 95px; right: -10px; }
  .station-controls-row { flex-wrap: wrap; gap: 8px; }
  .station-volume-wrap { width: 100%; justify-content: center; margin-top: 6px; }
  #arirangVolumeRange { width: 100px; }
  .playlist-header-row { flex-direction: column; align-items: flex-start; gap: 10px; }
  .playlist-grid { grid-template-columns: 1fr; }
  .playlist-track-card { padding: 10px 12px; }
  .lyrics-scroll-box, .story-scroll-box { max-height: 300px; }

  .music-room { grid-template-columns: 1fr; padding: 14px; }
  .music-photo { min-height: 270px; }
  .music-console { padding: 10px 3px; }
  .music-console h2 { font-size: 28px; }
  .track-list { grid-template-columns: 1fr; }
  .say-along b { font-size: 18px; }
  .service-grid { gap: 9px; }
  .service-grid article { min-height: 180px; padding: 20px 12px; }
  .service-grid article:nth-child(2n) { transform: none; }
  .service-grid span { width: 52px; height: 52px; font-size: 27px; }
  .service-grid b { font-size: 15px; }.service-grid p { font-size: 11px; }
  .library-tour { grid-template-columns: 1fr; margin: 35px 0 22px; padding: 16px; }
  .shelf-illustration { height: 235px; }
  .library-tour h2 { font-size: 27px; }
  .library-info { grid-template-columns: 1fr; }
  .library-info a { text-align: center; }
  .place-filter { position: sticky; top: 8px; z-index: 5; padding: 7px; border-radius: 17px; background: rgba(255,255,255,.9); box-shadow: var(--soft-shadow); }
  .place-filter button { padding: 9px 11px; font-size: 10px; }
  .place-grid { grid-template-columns: 1fr; gap: 13px; }
  .place-card { display: grid; grid-template-columns: 42% 58%; min-height: 155px; }
  .place-card img { height: 100%; min-height: 155px; }
  .place-card-body { padding: 15px; }
  .place-card h2 { font-size: 17px; }.place-card p { font-size: 11px; }
  .game-grid { grid-template-columns: 1fr; gap: 16px; }
  .game-filter { overflow-x: auto; flex-wrap: nowrap; justify-content: flex-start; padding-bottom: 6px; width: 100%; }
  .game-filter button { flex: 0 0 auto; padding: 9px 14px; font-size: 11px; }
  .storybook { grid-template-columns: 1fr; }
  .storybook-visual { min-height: 285px; }
  .storybook-copy { padding: 26px 22px 24px; }
  .storybook-copy h2 { font-size: 31px; }
  .storybook-copy > p { min-height: 0; font-size: 14px; }
  .story-controls { grid-template-columns: auto 1fr auto; }
  .story-controls > button { padding: 10px; font-size: 10px; }
  .adventure-book { margin-top: 22px; padding: 21px 15px; border-radius: 26px; }
  .pdf-book-banner {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 16px 14px;
    gap: 12px;
  }
  .pdf-book-icon-wrap { margin: 0 auto; }
  .pdf-title-row { justify-content: center; }
  .pdf-book-actions { justify-content: center; }
  .pdf-viewer-frame-wrap { height: 460px; }
  .adventure-heading { align-items: flex-start; gap: 12px; }
  .adventure-heading h2 { font-size: 28px; }
  .adventure-heading p { font-size: 12px; }
  .book-badge { padding: 10px 11px; border-radius: 16px; font-size: 8px; }
  .book-badge b { font-size: 11px; }
  .adventure-grid { grid-template-columns: 1fr; gap: 10px; }
  .adventure-card { min-height: 0; padding: 18px 18px 18px 88px; }
  .adventure-icon { position: absolute; top: 19px; left: 16px; width: 56px; height: 56px; margin: 0; }
  .adventure-card h3 { font-size: 17px; }
  .adventure-card p { font-size: 11px; }
  .adventure-finish { padding: 15px; }
  .closing-card { padding: 16px; gap: 12px; }
  .closing-card img { width: 85px; height: 85px; }.closing-card b { font-size: 14px; }
  footer { display: block; text-align: center; padding-bottom: 15px; line-height: 1.6; }
  
  .mobile-nav {
    position: fixed;
    z-index: 90;
    left: 9px;
    right: 9px;
    bottom: 8px;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    padding: 7px 4px;
    border: 2px solid rgba(255,255,255,.95);
    border-radius: 22px;
    background: rgba(255,255,255,.92);
    box-shadow: 0 12px 32px rgba(29,62,42,.25);
    backdrop-filter: blur(13px);
  }
  .mobile-nav button { border: 0; border-radius: 15px; padding: 7px 1px 5px; background: transparent; color: #65766d; font-size: 8.5px; font-weight: 900; cursor: pointer; }
  .mobile-nav button span { display: block; margin-bottom: 2px; font-size: 18px; }
  .mobile-nav button.is-active { background: #eaf8e6; color: #277043; }
  .mobile-nav .mobile-games-btn { color: #d82b56; }
  .mobile-nav .mobile-games-btn.is-active { background: #ffe6ec; color: #d82b56; }
}

@media (max-width: 430px) {
  .hero-copy h1 { font-size: 38px; }
  .door-card { min-height: 145px; }
  .page-hero h1 { font-size: 35px; }
  .content-wrap { padding-left: 12px; padding-right: 12px; }
  .place-card { grid-template-columns: 40% 60%; }
  .place-card-body { padding: 12px; }
  .game-card { padding: 18px 15px; }
  .game-card-top { gap: 10px; }
  .game-card-avatar { flex: 0 0 48px; height: 48px; font-size: 26px; border-radius: 16px; }
  .game-title { font-size: 18px; }
  .game-card-actions { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}


/* ==========================================================
   신규 추가: 바이브코딩 & 학생작품 갤러리 & 별빛 보물대작전 스타일
   ========================================================== */

/* 상단바 & 모바일 학생작품 갤러리 강조 */
.nav-games-btn.highlight-nav-btn {
  background: linear-gradient(135deg, #fff0f5, #ffe4ec) !important;
  border: 1.5px solid rgba(255, 71, 114, 0.4) !important;
  color: #d82b56 !important;
  box-shadow: 0 4px 12px rgba(216, 43, 86, 0.15) !important;
  font-weight: 1000 !important;
  position: relative;
}
.nav-games-btn.highlight-nav-btn:hover,
.nav-games-btn.highlight-nav-btn.is-active {
  background: linear-gradient(135deg, #ff4772, #e82654) !important;
  color: white !important;
  box-shadow: 0 6px 18px rgba(232, 38, 84, 0.35) !important;
  transform: translateY(-2px);
}
.nav-badge-pill {
  display: inline-block;
  font-size: 10px;
  font-weight: 900;
  padding: 2px 7px;
  border-radius: 999px;
  background: #ff3366;
  color: white;
  margin-left: 4px;
  letter-spacing: -0.2px;
  animation: badge-pulse-glow 2s infinite ease-in-out;
}
.nav-games-btn.highlight-nav-btn.is-active .nav-badge-pill {
  background: #fff;
  color: #e82654;
}
.highlight-mobile-btn {
  color: #d82b56 !important;
  font-weight: 900;
}
.highlight-mobile-btn.is-active {
  background: #ffe6ee !important;
  color: #c91844 !important;
}

@keyframes badge-pulse-glow {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.08); opacity: 0.88; }
}

/* 홈 히어로 액션 버튼들 */
.hero-cta-highlight {
  background: linear-gradient(180deg, #ff577e, #e82a57) !important;
  box-shadow: inset 0 3px 0 rgba(255,255,255,.6), 0 8px 0 #b8193f, 0 13px 24px rgba(232,42,87,.32) !important;
}
.quest-shortcut-btn {
  border: 0;
  border-radius: 18px;
  padding: 15px 22px;
  background: linear-gradient(180deg, #fbb034, #f59e0b);
  color: white;
  box-shadow: inset 0 3px 0 rgba(255,255,255,.6), 0 8px 0 #b45309, 0 13px 24px rgba(245,158,11,.28);
  font-weight: 1000;
  cursor: pointer;
  transition: .18s ease;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.quest-shortcut-btn:hover { transform: translateY(-3px); }
.quest-shortcut-btn:active { transform: translateY(4px); box-shadow: inset 0 2px 0 rgba(255,255,255,.5), 0 3px 0 #b45309; }

.sub-link-btn {
  border: 2px solid rgba(85, 194, 103, 0.4);
  border-radius: 18px;
  padding: 14px 20px;
  background: rgba(255, 255, 255, 0.9);
  color: #246e3e;
  font-weight: 900;
  cursor: pointer;
  transition: .18s ease;
}
.sub-link-btn:hover { background: #ebfaee; transform: translateY(-2px); }

/* 홈 하이라이트 쇼케이스 */
.home-highlight-showcase {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin: 6px 0 28px;
}
.highlight-banner-card {
  position: relative;
  border-radius: 28px;
  padding: 24px 26px;
  background: white;
  border: 2.5px solid transparent;
  box-shadow: 0 12px 32px rgba(32, 60, 45, 0.09);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: .22s cubic-bezier(.25, .8, .25, 1);
  overflow: hidden;
}
.highlight-banner-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 18px 40px rgba(32, 60, 45, 0.15);
}
.gallery-banner-card {
  background: linear-gradient(145deg, #ffffff 0%, #fff4f7 100%);
  border-color: #ffccd8;
}
.gallery-banner-card:hover {
  border-color: #ff85a1;
}
.quest-banner-card {
  background: linear-gradient(145deg, #ffffff 0%, #fffbf0 100%);
  border-color: #ffe8a3;
}
.quest-banner-card:hover {
  border-color: #f59e0b;
}
.highlight-badge-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
.h-badge {
  font-size: 11px;
  font-weight: 900;
  padding: 4px 10px;
  border-radius: 999px;
}
.h-badge.pink {
  background: #ffe4ec;
  color: #d82b56;
}
.h-badge.gold {
  background: #fef3c7;
  color: #b45309;
}
.h-count {
  font-size: 11px;
  font-weight: 800;
  color: #728278;
}
.highlight-banner-card h3 {
  font-size: 21px;
  margin: 0 0 8px;
  color: var(--ink);
}
.highlight-banner-card p {
  font-size: 13px;
  line-height: 1.55;
  color: #556b60;
  margin: 0 0 16px;
  flex-grow: 1;
}
.h-card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.h-card-btn {
  border: 0;
  border-radius: 14px;
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  transition: .18s ease;
  display: inline-flex;
  align-items: center;
}
.h-card-btn.pink {
  background: linear-gradient(135deg, #ff577e, #e8325e);
  color: white;
  box-shadow: 0 4px 12px rgba(232, 50, 94, 0.28);
}
.h-card-btn.pink:hover {
  background: linear-gradient(135deg, #ff3d6a, #cf204c);
  transform: translateY(-2px);
}
.h-card-btn.gold {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  box-shadow: 0 4px 12px rgba(217, 119, 6, 0.28);
}
.h-card-btn.gold:hover {
  background: linear-gradient(135deg, #d97706, #b45309);
  transform: translateY(-2px);
}
.h-direct-link-tag {
  font-size: 11px;
  font-family: Consolas, monospace;
  color: #8c9e94;
  background: rgba(0,0,0,0.04);
  padding: 3px 8px;
  border-radius: 6px;
}

/* 6개 도어 그리드 */
.door-grid.six-doors {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 11px;
}
.door-card.gold-quest {
  background: linear-gradient(145deg, #ffd056, #f59e0b);
  box-shadow: inset 0 4px 0 rgba(255,255,255,.38), 0 8px 0 rgba(180,83,9,.28), 0 14px 22px rgba(245,158,11,.22);
}

/* 별빛 보물대작전 전용 페이지 (Quest Page) */
.quest-hero-badge {
  position: absolute;
  right: 54px;
  bottom: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 16px 22px;
  border-radius: 24px;
  background: linear-gradient(145deg, #192736, #0f1822);
  border: 2px solid rgba(255, 215, 0, 0.5);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.22);
  color: white;
  text-align: center;
}
.quest-star-glow {
  font-size: 30px;
  color: #ffd700;
  animation: twinkle 2s infinite ease-in-out;
}
.quest-hero-badge b { font-size: 15px; color: #ffd700; letter-spacing: 0.5px; }
.quest-hero-badge small { font-size: 11px; color: #a4b6c9; }

.quest-game-section {
  margin: 10px 0 35px;
}
.quest-extras-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 15px;
  margin-bottom: 20px;
}
.quest-extra-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 20px;
  border-radius: 22px;
  background: white;
  border: 2px solid #e7ece8;
  box-shadow: 0 8px 20px rgba(35, 68, 50, 0.06);
  transition: .2s ease;
}
.quest-extra-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 26px rgba(35, 68, 50, 0.12);
  border-color: #bcdbc6;
}
.quest-extra-card.highlight {
  background: linear-gradient(135deg, #fff7fa, #ffeaf1);
  border-color: #ffccd8;
}
.extra-icon {
  font-size: 28px;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  background: #f3f6f4;
  border-radius: 16px;
}
.quest-extra-card.highlight .extra-icon {
  background: #ffe1eb;
}
.extra-info {
  flex-grow: 1;
}
.extra-info b {
  display: block;
  font-size: 14px;
  color: var(--ink);
  margin-bottom: 3px;
}
.extra-info p {
  font-size: 11px;
  color: #6e8178;
  margin: 0;
  line-height: 1.4;
}
.extra-btn {
  border: 0;
  border-radius: 12px;
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  background: #eef4f0;
  color: #246e3e;
  text-decoration: none;
  white-space: nowrap;
  transition: .18s ease;
}
.extra-btn:hover {
  background: #e0eee4;
}
.extra-btn.primary {
  background: linear-gradient(135deg, #ff577e, #e8325e);
  color: white;
  box-shadow: 0 4px 10px rgba(232, 50, 94, 0.28);
}
.extra-btn.primary:hover {
  background: linear-gradient(135deg, #ff3d6a, #cf204c);
}

/* 갤러리 직접 링크 바 & 복사 버튼 */
.gallery-share-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 20px;
  background: #ffffff;
  border: 2px dashed #ffb3c6;
  border-radius: 18px;
  margin-bottom: 25px;
  box-shadow: 0 4px 14px rgba(255, 71, 114, 0.08);
}
.share-bar-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.share-label-tag {
  font-size: 12px;
  font-weight: 900;
  color: #d82b56;
}
.share-bar-left code {
  font-family: Consolas, "Courier New", monospace;
  font-size: 13px;
  font-weight: 700;
  color: #2c4436;
  background: #fff0f5;
  padding: 4px 10px;
  border-radius: 8px;
  border: 1px solid #ffd6e0;
}
.share-bar-copy-btn, .copy-gallery-url-btn {
  border: 0;
  border-radius: 12px;
  padding: 9px 16px;
  background: linear-gradient(135deg, #ff577e, #e8325e);
  color: white;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(232, 50, 94, 0.25);
  transition: .18s ease;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.share-bar-copy-btn:hover, .copy-gallery-url-btn:hover {
  background: linear-gradient(135deg, #ff3d6a, #cf204c);
  transform: translateY(-2px);
}

/* 토스트 알림창 */
.toast-notification {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: rgba(20, 45, 30, 0.95);
  color: white;
  padding: 12px 24px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 800;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  z-index: 1000;
  pointer-events: none;
  opacity: 0;
  transition: transform .3s cubic-bezier(0.18, 0.89, 0.32, 1.28), opacity .3s ease;
}
.toast-notification.is-visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

@media (max-width: 1080px) {
  .door-grid.six-doors { grid-template-columns: repeat(3, 1fr); }
  .quest-extras-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .door-grid.six-doors { grid-template-columns: repeat(2, 1fr); }
  .home-highlight-showcase { grid-template-columns: 1fr; }
  .gallery-share-bar { flex-direction: column; align-items: stretch; text-align: center; }
  .share-bar-left { justify-content: center; }
  .quest-hero-badge { position: static; margin-top: 15px; }
}


/* ==========================================================
   실시간 응원 댓글 시스템 스타일 (Comments Section)
   ========================================================== */
.scroll-comment-btn {
  border: 0;
  border-radius: 12px;
  padding: 9px 16px;
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
  transition: .18s ease;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.scroll-comment-btn:hover {
  background: linear-gradient(135deg, #059669, #047857);
  transform: translateY(-2px);
}

.comments-section {
  margin: 35px 0 20px;
  padding: 36px 32px;
  border-radius: 36px;
  background: linear-gradient(160deg, #ffffff 0%, #fffbf8 60%, #fff4f7 100%);
  border: 3px solid #ffdde5;
  box-shadow: 0 16px 45px rgba(220, 80, 110, 0.08);
}

.comments-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 28px;
}
.comments-header-copy {
  max-width: 680px;
}
.comments-tag {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  background: #ffe4ec;
  color: #d82b56;
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 8px;
}
.comments-header-copy h2 {
  font-size: 26px;
  margin: 0 0 8px;
  color: #20352b;
}
.comments-header-copy p {
  font-size: 14px;
  color: #5d6e64;
  margin: 0;
  line-height: 1.55;
}
.comments-header-badge {
  flex-shrink: 0;
}
.comments-ballerina-art {
  max-height: 110px;
  filter: drop-shadow(0 8px 16px rgba(216, 43, 86, 0.18));
  animation: float-ballerina 3.5s ease-in-out infinite;
}
@keyframes float-ballerina {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-8px) rotate(2deg); }
}

/* 댓글 작성 카드 */
.comment-write-card {
  background: white;
  border: 2px solid #ffccd8;
  border-radius: 26px;
  padding: 24px 26px;
  box-shadow: 0 10px 30px rgba(216, 43, 86, 0.06);
  margin-bottom: 35px;
}
.comment-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.form-meta-row {
  display: grid;
  grid-template-columns: 1fr 1.3fr auto;
  gap: 16px;
  align-items: end;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-group label {
  font-size: 12px;
  color: #4a5c52;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.char-counter {
  font-size: 11px;
  font-family: Consolas, monospace;
  color: #8c9e94;
}

.name-group input,
.target-group select {
  height: 44px;
  border: 2px solid #e5ece7;
  border-radius: 14px;
  padding: 0 14px;
  font-size: 13px;
  font-weight: 700;
  color: #284338;
  background: #fafcfa;
  transition: .18s ease;
  outline: none;
}
.name-group input:focus,
.target-group select:focus,
.text-group textarea:focus {
  border-color: #ff4772;
  background: white;
  box-shadow: 0 0 0 3px rgba(255, 71, 114, 0.15);
}

.emoji-picker-row {
  display: flex;
  gap: 5px;
  background: #f7faf8;
  padding: 4px;
  border-radius: 14px;
  border: 1.5px solid #e3eae5;
}
.emoji-choice-btn {
  border: 0;
  background: transparent;
  font-size: 18px;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: .15s ease;
}
.emoji-choice-btn:hover {
  background: rgba(255, 71, 114, 0.12);
  transform: scale(1.15);
}
.emoji-choice-btn.is-selected {
  background: white;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
  transform: scale(1.15);
  border: 1.5px solid #ff4772;
}

.text-group textarea {
  border: 2px solid #e5ece7;
  border-radius: 16px;
  padding: 12px 16px;
  font-size: 14px;
  font-family: inherit;
  line-height: 1.5;
  color: #284338;
  background: #fafcfa;
  resize: vertical;
  min-height: 75px;
  transition: .18s ease;
  outline: none;
}

.form-actions-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  flex-wrap: wrap;
}
.form-tip {
  font-size: 12px;
  color: #728278;
}
.comment-submit-btn {
  border: 0;
  border-radius: 16px;
  padding: 13px 26px;
  background: linear-gradient(135deg, #ff4772, #e82654);
  color: white;
  font-size: 14px;
  font-weight: 1000;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(232, 38, 84, 0.32);
  transition: .18s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.comment-submit-btn:hover {
  background: linear-gradient(135deg, #ff2d5d, #cf1642);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(232, 38, 84, 0.4);
}
.comment-submit-btn:active {
  transform: translateY(2px);
}

/* 댓글 목록 영역 */
.comments-list-wrapper {
  margin-top: 20px;
}
.comments-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  border-bottom: 2px dashed #ffe0e7;
  padding-bottom: 12px;
}
.comments-list-header h3 {
  font-size: 18px;
  margin: 0;
  color: #284338;
}
.comments-filter-hint {
  font-size: 12px;
  color: #8c9e94;
  font-weight: 700;
}

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

.comment-card {
  background: white;
  border: 2px solid #edf2ee;
  border-radius: 22px;
  padding: 18px 20px;
  box-shadow: 0 6px 20px rgba(35, 68, 50, 0.05);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all .25s ease;
  position: relative;
}
.comment-card:hover {
  border-color: #ffccd8;
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(216, 43, 86, 0.1);
}
.comment-card.newly-added {
  border-color: #ff4772;
  background: linear-gradient(145deg, #ffffff, #fff5f8);
  animation: highlight-pulse 2.5s ease-out;
}
@keyframes highlight-pulse {
  0% { transform: scale(1.02); box-shadow: 0 0 0 4px rgba(255, 71, 114, 0.3); }
  100% { transform: scale(1); box-shadow: 0 6px 20px rgba(35, 68, 50, 0.05); }
}

.comment-card-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 10px;
}
.comment-avatar {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #fdf2f5;
  display: grid;
  place-items: center;
  font-size: 22px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.04);
}
.comment-user-info {
  flex-grow: 1;
  min-width: 0;
}
.comment-user-name-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 3px;
}
.comment-author {
  font-size: 14px;
  color: #284338;
}
.comment-date {
  font-size: 11px;
  color: #9aa8a0;
}
.comment-target-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 6px;
  background: #eef7f2;
  color: #257a4a;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.comment-target-badge.special {
  background: #ffe8ee;
  color: #d82b56;
}

.comment-card-body {
  margin: 6px 0 12px;
  flex-grow: 1;
}
.comment-text {
  font-size: 13.5px;
  line-height: 1.55;
  color: #384f44;
  margin: 0;
  word-break: break-word;
}

.comment-card-footer {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  border-top: 1px solid #f2f6f3;
  padding-top: 8px;
}
.comment-like-btn {
  border: 1.5px solid #f0d5dd;
  background: #fff8fa;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 800;
  color: #cf2d53;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: .15s ease;
}
.comment-like-btn:hover {
  background: #ffe4eb;
  border-color: #ff85a1;
  transform: scale(1.05);
}
.comment-like-btn.liked .like-heart {
  animation: heart-pop .5s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}
@keyframes heart-pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.5); }
  100% { transform: scale(1); }
}

.empty-comments-box {
  grid-column: 1 / -1;
  text-align: center;
  padding: 40px 20px;
  background: white;
  border-radius: 20px;
  border: 2px dashed #e5ece7;
}
.empty-emoji {
  font-size: 36px;
  display: block;
  margin-bottom: 8px;
}
.empty-comments-box p {
  font-size: 14px;
  color: #728278;
  margin: 0;
}

@media (max-width: 900px) {
  .form-meta-row { grid-template-columns: 1fr 1fr; }
  .emoji-group { grid-column: 1 / -1; }
  .comments-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .comments-section { padding: 24px 18px; border-radius: 26px; }
  .comments-header { flex-direction: column; align-items: flex-start; text-align: left; }
  .comments-header-badge { display: none; }
  .form-meta-row { grid-template-columns: 1fr; }
  .emoji-picker-row { flex-wrap: wrap; }
}


/* 상단바 반응형 최적화 */
@media (max-width: 1260px) {
  .brand small { display: none; }
  .desktop-nav { gap: 3px; }
  .desktop-nav button { padding: 8px 8px; font-size: 12.5px; }
  .desktop-nav span { font-size: 14px; margin-right: 1px; }
}

@media (max-width: 1060px) {
  .topbar { padding: 6px 10px; gap: 6px; }
  .brand b { font-size: 16.5px; }
  .brand-mark { width: 36px; height: 36px; font-size: 18px; }
  .desktop-nav button { padding: 6px 6px; font-size: 11.5px; }
  .desktop-nav span { font-size: 13px; margin-right: 1px; }
  .bgm-toggle-btn { padding: 5px 8px 5px 6px; }
  .bgm-toggle-btn .bgm-text small { display: none; }
}

@media (max-width: 860px) {
  body { padding-bottom: 78px; }
  .topbar { position: relative; top: 0; margin: 8px 0 12px; padding: 8px 12px; border-radius: 19px; }
  .desktop-nav { display: none !important; }
  .mobile-nav { display: grid !important; }
  .brand-mark { width: 38px; height: 38px; font-size: 19px; }
  .brand b { font-size: 18px; }
  .brand small { display: block; font-size: 9.5px; }
}
