/* 창빙시 홈 v3.2.0(v3.1.0 + 자유 대화형·창작 예시·플레이 기록·판 기록·작화 보관함·제작 기록) — 상위 캐릭터챗 메인 실측(2026-10-31: 크랙·제타·Talkie·PolyBuzz, 팝업 닫고 끝까지 스크롤) 형식.
   크랙: 사이드바·종류 탭·검색·고정 장르 칩·배너 캐러셀(옆 슬라이드 보임)·주제별 카드 줄·숫자 랭킹·태그 모아보기·전체 그리드
   제타·Talkie·PolyBuzz: 어두운 테마·조회 수 배지·LIVE 영상 카드·하단 탭바·FAQ/푸터 */
/* 색 토큰은 홈 밖에 붙는 상세 시트·팝업·읽기 화면에도 필요합니다(v3.1.0에서는 #home에만 있어 상세 패널 배경이 비었습니다). */
#home, .f-sheet, .f-pop, .f-reader {
  --side-w: 232px;
  --f-bg: #0d0b13;
  --f-bg-2: #15121e;
  --f-bg-3: #1d1928;
  --f-line: rgba(255, 255, 255, 0.08);
  --f-text: #f4f1f8;
  --f-text-2: #b9b1c7;
  --f-text-3: #857d93;
  --f-live: #ff4d6a;
  --f-new: #4fd1a5;
}
#home {
  position: fixed; inset: 0; z-index: 4; overflow-y: auto; overflow-x: hidden; padding: 0;
  background: var(--f-bg); color: var(--f-text); scroll-behavior: smooth; overscroll-behavior: contain;
}
body:not(.is-home) #home { opacity: 0; transform: none; pointer-events: none; visibility: hidden; transition: opacity 0.3s var(--ease-out), visibility 0s 0.3s; }
body.is-home #stage, body.is-home .scrim { visibility: hidden; }
#home a { color: inherit; text-decoration: none; }
:where(#home, .f-sheet, .f-pop, .f-reader) button { border: 0; background: none; padding: 0; color: inherit; font: inherit; cursor: pointer; }
.f-main { min-height: 100%; padding-bottom: calc(var(--safe-b) + 84px); }

/* ── 로고 ─────────────────────────── */
.f-logo { font-family: var(--serif); font-size: 24px; font-weight: 700; letter-spacing: -0.01em; white-space: nowrap; }
.f-logo::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 3px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 12px var(--gold); vertical-align: 0.5em; }

/* ── 사이드바(데스크톱) ───────────── */
.f-side { display: none; }
.f-side-nav a, .f-side-nav button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; border-radius: 10px; font-size: 15px; font-weight: 600; color: var(--f-text-2); text-align: left; }
.f-side-nav a:hover, .f-side-nav button:hover { background: var(--f-bg-3); color: var(--f-text); }
.f-side-nav .is-on { background: var(--f-bg-3); color: var(--f-text); }
.f-side-nav hr { border: 0; border-top: 1px solid var(--f-line); margin: 10px 4px; }
.f-side-nav .pill { margin-left: auto; font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 999px; background: var(--gold-soft); color: var(--gold); }
.f-login-card { margin-top: auto; padding: 16px; border-radius: 14px; background: var(--f-bg-2); border: 1px solid var(--f-line); }
.f-login-card p { margin: 0 0 12px; font-size: 13px; line-height: 1.5; color: var(--f-text-2); }
.f-login-card strong { display: block; color: var(--f-text); font-size: 14px; margin-bottom: 4px; }
.f-sso { display: flex; gap: 8px; justify-content: center; margin-bottom: 8px; }
.f-sso button { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 15px; }
.f-sso .kakao { background: #fee500; color: #191600; }
.f-sso .google { background: #fff; color: #3c4043; }
.f-sso .apple { background: #000; color: #fff; border: 1px solid var(--f-line); }
.f-login-card .more { display: block; width: 100%; font-size: 12px; color: var(--f-text-3); text-align: center; }

/* ── 상단 바 ─────────────────────── */
.f-top { position: sticky; top: 0; z-index: 6; display: flex; align-items: center; gap: 10px; height: calc(var(--safe-t) + 56px); padding: var(--safe-t) 16px 0; background: rgba(13, 11, 19, 0.92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.f-kind { display: none; }
.f-search { display: none; }
.f-logo-m { margin-right: auto; font-size: 22px; }
.f-icon { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; color: var(--f-text-2); }
.f-coin { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px 0 6px; border-radius: 999px; background: var(--f-bg-3); font-size: 13px; font-weight: 700; color: var(--f-text); }
.f-coin i { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: var(--gold); color: var(--gold-ink); font-style: normal; font-size: 11px; font-weight: 900; }
.f-make-btn { display: none; height: 32px; padding: 0 14px; border-radius: 999px; background: var(--f-bg-3) !important; color: var(--f-text); font-size: 13px; font-weight: 800; }
.f-login-btn { height: 32px; padding: 0 14px; border-radius: 999px; background: var(--gold) !important; color: var(--gold-ink); font-size: 13px; font-weight: 800; }

/* ── 장르 칩(고정) ───────────────── */
.f-chips { position: sticky; top: calc(var(--safe-t) + 56px); z-index: 5; display: flex; gap: 6px; padding: 6px 16px 10px; overflow-x: auto; scrollbar-width: none; background: rgba(13, 11, 19, 0.92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.f-chips::-webkit-scrollbar { display: none; }
.f-chip { flex: none; height: 32px; padding: 0 13px; border-radius: 999px; background: var(--f-bg-3) !important; color: var(--f-text-2); font-size: 13.5px; font-weight: 700; white-space: nowrap; }
.f-chip.is-on { background: var(--f-text) !important; color: #120f19; }

/* ── 배너 캐러셀 ─────────────────── */
.f-banner { position: relative; margin: 6px 0 8px; }
.f-banner-track { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 0 16px; }
.f-banner-track::-webkit-scrollbar { display: none; }
.f-slide { position: relative; flex: none; width: calc(100% - 32px); aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; scroll-snap-align: center; background: var(--f-bg-3); cursor: pointer; text-align: left; }
.f-slide img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.f-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(8, 6, 14, 0.92) 0%, rgba(8, 6, 14, 0.35) 45%, rgba(8, 6, 14, 0) 70%); }
.f-slide .txt { position: absolute; left: 18px; right: 18px; bottom: 16px; z-index: 1; }
.f-slide .kick { display: inline-block; font-size: 11.5px; font-weight: 800; padding: 3px 8px; border-radius: 6px; background: var(--gold); color: var(--gold-ink); margin-bottom: 8px; }
.f-slide .kick.live { background: var(--f-live); color: #fff; }
.f-slide .kick.event { background: #7c5cff; color: #fff; }
.f-slide h3 { margin: 0 0 4px; font-size: 21px; font-weight: 800; line-height: 1.25; text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5); }
.f-slide p { margin: 0; font-size: 13.5px; color: #e6e0ee; line-height: 1.45; }
.f-slide .period { display: block; margin-top: 6px; font-size: 12px; color: var(--f-text-2); }
.f-banner-count { position: absolute; right: 28px; top: 12px; z-index: 2; font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: rgba(0, 0, 0, 0.5); color: #fff; }
.f-arrow { display: none; }

/* ── 섹션 ───────────────────────── */
.f-sec { margin: 26px 0 0; }
.f-sec-h { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 0 16px; margin-bottom: 12px; }
.f-sec-h h2 { margin: 0; font-size: 18px; font-weight: 800; letter-spacing: -0.01em; }
.f-sec-h small { display: block; margin-top: 3px; font-size: 12.5px; font-weight: 500; color: var(--f-text-3); }
.f-sec-h .all { flex: none; font-size: 13px; color: var(--f-text-3); }
.f-row-wrap { position: relative; }
.f-row { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none; padding: 0 16px 4px; }
.f-row::-webkit-scrollbar { display: none; }
.f-row > * { scroll-snap-align: start; }

/* 세로 카드 */
.f-card { position: relative; flex: none; width: 31vw; max-width: 172px; text-align: left; cursor: pointer; }
.f-cover { position: relative; aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden; background: var(--f-bg-3); }
.f-cover img, .f-cover video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 18%; transition: transform 0.6s var(--ease-out); }
.f-card:hover .f-cover img { transform: scale(1.04); }
.f-badges { position: absolute; left: 6px; top: 6px; z-index: 1; display: flex; gap: 4px; flex-wrap: wrap; }
.f-badge { font-size: 10px; font-weight: 900; letter-spacing: 0.02em; padding: 2px 6px; border-radius: 5px; background: rgba(10, 8, 16, 0.72); color: #fff; }
.f-badge.orig { background: var(--gold); color: var(--gold-ink); }
.f-badge.new { background: var(--f-new); color: #04261a; }
.f-badge.live { background: var(--f-live); }
.f-badge.event { background: #7c5cff; }
.f-plays { position: absolute; left: 6px; bottom: 6px; z-index: 1; display: inline-flex; align-items: center; gap: 3px; font-size: 11px; font-weight: 700; padding: 2px 6px; border-radius: 5px; background: rgba(10, 8, 16, 0.6); }
.f-plays svg { width: 12px; height: 12px; stroke-width: 2.2; }
.f-card h3 { margin: 7px 0 2px; font-size: 13.5px; font-weight: 700; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.f-card .line { margin: 0 0 3px; font-size: 12px; color: var(--f-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-by { font-size: 11.5px; color: var(--f-text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-by b { font-weight: 600; color: var(--f-text-2); }
.f-by .off { display: inline-block; width: 13px; height: 13px; margin-left: 2px; border-radius: 50%; background: var(--gold); color: var(--gold-ink); font-size: 9px; font-weight: 900; line-height: 13px; text-align: center; vertical-align: -1px; }

/* 숫자 랭킹 카드 */
.f-rank .f-card { width: 36vw; max-width: 196px; }
.f-num { position: absolute; left: 8px; bottom: -6px; z-index: 1; font-size: 54px; font-weight: 900; font-style: italic; line-height: 1; color: #fff; -webkit-text-stroke: 1px rgba(0, 0, 0, 0.35); text-shadow: 0 4px 16px rgba(0, 0, 0, 0.6); }
.f-rank .f-plays { left: auto; right: 6px; }

/* 가로 카드(오직 창빙시에서만) */
.f-wide { position: relative; flex: none; width: 78vw; max-width: 340px; aspect-ratio: 16 / 10; border-radius: 14px; overflow: hidden; background: var(--f-bg-3); text-align: left; cursor: pointer; }
.f-wide img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; }
.f-wide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(8, 6, 14, 0.9), rgba(8, 6, 14, 0) 60%); }
.f-wide .txt { position: absolute; left: 14px; right: 74px; bottom: 12px; z-index: 1; }
.f-wide h3 { margin: 0 0 2px; font-size: 16px; font-weight: 800; }
.f-wide p { margin: 0; font-size: 12px; color: var(--f-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-wide .go { position: absolute; right: 12px; bottom: 12px; z-index: 1; padding: 6px 12px; border-radius: 8px; background: rgba(255, 255, 255, 0.92); color: #120f19; font-size: 12.5px; font-weight: 800; }

/* LIVE 카드(움직이는 캐릭터) */
.f-live { display: flex; gap: 12px; overflow-x: auto; scrollbar-width: none; padding: 0 16px 4px; scroll-snap-type: x mandatory; }
.f-live::-webkit-scrollbar { display: none; }
.f-live-card { position: relative; flex: none; width: 64vw; max-width: 300px; scroll-snap-align: start; border-radius: 16px; overflow: hidden; background: var(--f-bg-3); }
.f-live-card .f-cover { border-radius: 0; aspect-ratio: 3 / 4; }
.f-live-card .f-cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(8, 6, 14, 0.95) 0%, rgba(8, 6, 14, 0) 46%); }
.f-live-card .body { position: absolute; left: 14px; right: 14px; bottom: 14px; z-index: 2; }
.f-live-card h3 { margin: 0; font-size: 19px; font-weight: 800; }
.f-live-card p { margin: 3px 0 10px; font-size: 12.5px; line-height: 1.45; color: #ddd6e8; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.f-live-card .acts { display: flex; gap: 6px; }
.f-live-card .acts button { flex: 1; height: 36px; border-radius: 10px; font-size: 13.5px; font-weight: 800; }
.f-live-card .acts .chat { background: var(--gold) !important; color: var(--gold-ink); }
.f-live-card .acts .call { background: rgba(255, 255, 255, 0.14) !important; color: #fff; backdrop-filter: blur(8px); }
.f-live-dot { display: inline-flex; align-items: center; gap: 5px; }
.f-live-dot::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #fff; animation: f-blink 1.4s infinite; }
@keyframes f-blink { 50% { opacity: 0.25; } }

/* 창작자 */
.f-creator { flex: none; width: 92px; text-align: center; cursor: pointer; }
.f-creator .av { position: relative; width: 72px; height: 72px; margin: 0 auto 7px; border-radius: 50%; overflow: hidden; background: var(--f-bg-3); box-shadow: 0 0 0 2px var(--f-bg), 0 0 0 3.5px rgba(242, 184, 79, 0.55); }
.f-creator .av img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.f-creator b { display: block; font-size: 12.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-creator span { font-size: 11px; color: var(--f-text-3); }

/* 태그 모아보기 */
.f-tag { position: relative; flex: none; width: 40vw; max-width: 200px; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; background: var(--f-bg-3); cursor: pointer; }
.f-tag img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: saturate(0.9) brightness(0.62); }
.f-tag b { position: absolute; left: 12px; bottom: 10px; font-size: 16px; font-weight: 800; }

/* 이벤트 카드(공모전·혜택) */
.f-event { position: relative; flex: none; width: 82vw; max-width: 420px; border-radius: 16px; overflow: hidden; background: linear-gradient(135deg, #2a1f47, #171320); border: 1px solid var(--f-line); padding: 18px; text-align: left; cursor: pointer; }
.f-event img { position: absolute; right: -10px; top: 0; height: 100%; width: 46%; object-fit: cover; object-position: 50% 20%; -webkit-mask-image: linear-gradient(to left, #000 55%, transparent); mask-image: linear-gradient(to left, #000 55%, transparent); opacity: 0.85; }
.f-event .kick { position: relative; display: inline-block; font-size: 11px; font-weight: 800; padding: 3px 8px; border-radius: 6px; background: #7c5cff; color: #fff; }
.f-event h3 { position: relative; margin: 10px 0 6px; max-width: 62%; font-size: 17px; font-weight: 800; line-height: 1.3; }
.f-event p { position: relative; margin: 0; max-width: 60%; font-size: 12.5px; color: var(--f-text-2); line-height: 1.5; }
.f-event .when { position: relative; display: block; margin-top: 10px; font-size: 11.5px; color: var(--f-text-3); }

/* 전체 그리드 */
.f-grid-tools { display: flex; gap: 6px; padding: 0 16px; margin: -4px 0 12px; }
.f-grid-tools button { height: 30px; padding: 0 12px; border-radius: 8px; background: var(--f-bg-3) !important; color: var(--f-text-2); font-size: 12.5px; font-weight: 700; }
.f-grid-tools .is-on { color: var(--f-text); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.3); }
.f-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px 8px; padding: 0 16px; }
.f-grid .f-card { width: auto; max-width: none; }
.f-more { display: block; margin: 20px auto 0; height: 42px; padding: 0 28px; border-radius: 999px; background: var(--f-bg-3) !important; color: var(--f-text); font-size: 14px; font-weight: 700; }
.f-empty { padding: 30px 16px; color: var(--f-text-3); text-align: center; font-size: 14px; }

/* 푸터 */
.f-foot { margin: 48px 0 0; padding: 26px 16px 20px; border-top: 1px solid var(--f-line); color: var(--f-text-3); font-size: 12px; line-height: 1.7; }
.f-foot nav { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-bottom: 12px; }
.f-foot nav a { color: var(--f-text-2); font-weight: 600; }
.f-foot p { margin: 0 0 6px; }
.f-foot .demo { margin-top: 10px; padding: 10px 12px; border-radius: 10px; background: var(--f-bg-2); color: var(--f-text-2); }
.f-foot details { margin: 0 0 14px; }
.f-foot summary { cursor: pointer; color: var(--f-text-2); font-weight: 700; padding: 6px 0; }

/* 하단 탭(모바일) */
.f-tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 7; display: grid; grid-template-columns: repeat(5, 1fr); height: calc(var(--safe-b) + 60px); padding-bottom: var(--safe-b); background: rgba(13, 11, 19, 0.96); border-top: 1px solid var(--f-line); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
body:not(.is-home) .f-tabbar { display: none; }
.f-tabbar button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 10.5px; font-weight: 700; color: var(--f-text-3); }
.f-tabbar button.is-on { color: var(--f-text); }
.f-tabbar svg { width: 22px; height: 22px; }
.f-tabbar .make svg { width: 30px; height: 30px; padding: 5px; border-radius: 10px; background: var(--gold); color: var(--gold-ink); stroke-width: 2.4; }

/* ── 상세 시트 ───────────────────── */
.f-sheet, .f-pop { position: fixed; inset: 0; z-index: 30; display: flex; align-items: flex-end; justify-content: center; background: rgba(5, 4, 9, 0.62); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); animation: f-fade 0.2s var(--ease-out); }
.f-sheet[hidden], .f-pop[hidden] { display: none; }
@keyframes f-fade { from { opacity: 0; } }
@keyframes f-up { from { transform: translateY(28px); opacity: 0; } }
.f-panel { position: relative; width: 100%; max-height: 92dvh; overflow-y: auto; background: var(--f-bg-2); color: var(--f-text); border-radius: 20px 20px 0 0; padding: 0 0 calc(var(--safe-b) + 18px); animation: f-up 0.28s var(--ease-out); }
.f-close { position: absolute; right: 10px; top: 10px; z-index: 3; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: rgba(0, 0, 0, 0.45) !important; color: #fff; border: 0; }
.fd-hero { position: relative; height: 300px; overflow: hidden; }
.fd-hero img, .fd-hero video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.fd-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, var(--f-bg-2) 2%, rgba(21, 18, 30, 0) 60%); }
.fd-body { padding: 0 18px; margin-top: -40px; position: relative; z-index: 1; }
.fd-body h2 { margin: 6px 0 6px; font-size: 22px; font-weight: 800; line-height: 1.3; }
.fd-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 13px; color: var(--f-text-2); }
.fd-tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 12px 0 0; padding: 0; }
.fd-tags li { font-size: 12px; padding: 4px 9px; border-radius: 999px; background: var(--f-bg-3); color: var(--f-text-2); }
.fd-desc { margin: 14px 0 0; font-size: 14.5px; line-height: 1.7; color: var(--f-text); white-space: pre-line; }
.fd-open { margin: 16px 0 0; padding: 14px 16px; border-radius: 12px; background: var(--f-bg); border: 1px solid var(--f-line); font-family: var(--serif); font-size: 14.5px; line-height: 1.8; color: #e9e3f2; white-space: pre-line; }
.fd-open b { display: block; font-family: var(--font); font-size: 12px; color: var(--gold); margin-bottom: 6px; }
.fd-note { margin: 12px 0 0; font-size: 12px; color: var(--f-text-3); line-height: 1.6; }
.fd-cta { position: sticky; bottom: 0; display: flex; gap: 8px; padding: 14px 18px 0; margin-top: 16px; background: linear-gradient(to top, var(--f-bg-2) 70%, rgba(21, 18, 30, 0)); }
.fd-cta button { height: 48px; border-radius: 12px; font-size: 15px; font-weight: 800; border: 0; }
.fd-cta .main { flex: 1; background: var(--gold); color: var(--gold-ink); }
.fd-cta .sub { width: 48px; background: var(--f-bg-3); color: var(--f-text); display: grid; place-items: center; }

/* ── 팝업 ───────────────────────── */
.f-pop { align-items: center; padding: 20px; }
.f-pop.sheet { align-items: flex-end; padding: 0; }
.f-pop-box { position: relative; width: 100%; max-width: 380px; border-radius: 18px; overflow: hidden; background: var(--f-bg-2); animation: f-up 0.28s var(--ease-out); }
.f-pop.sheet .f-pop-box { max-width: 520px; border-radius: 20px 20px 0 0; padding-bottom: var(--safe-b); }
.f-pop-art { position: relative; aspect-ratio: 4 / 3; overflow: hidden; }
.f-pop-art img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 22%; display: block; }
.f-pop-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, var(--f-bg-2), rgba(21, 18, 30, 0) 55%); }
.f-pop-body { padding: 4px 20px 18px; }
.f-pop-body .kick { display: inline-block; font-size: 11px; font-weight: 800; padding: 3px 8px; border-radius: 6px; background: #7c5cff; color: #fff; }
.f-pop-body h2 { margin: 10px 0 6px; font-size: 20px; font-weight: 800; line-height: 1.35; }
.f-pop-body p { margin: 0 0 6px; font-size: 13.5px; line-height: 1.6; color: var(--f-text-2); }
.f-pop-body .fine { font-size: 11.5px; color: var(--f-text-3); }
.f-pop-cta { display: block; width: 100%; height: 46px; margin-top: 12px; border-radius: 12px; border: 0; background: var(--gold); color: var(--gold-ink); font-size: 15px; font-weight: 800; }
.f-pop-cta:disabled { opacity: 0.4; cursor: default; }
.f-pop-foot { display: flex; border-top: 1px solid var(--f-line); }
.f-pop-foot button { flex: 1; height: 46px; border: 0; background: none; color: var(--f-text-2); font-size: 13.5px; font-weight: 600; }
.f-pop-foot button + button { border-left: 1px solid var(--f-line); }
.f-pop-skip { position: absolute; right: 14px; top: 14px; height: 28px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--f-line); background: none; color: var(--f-text-2); font-size: 12px; font-weight: 700; }
.f-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 14px 0 4px; }
.f-pick button { position: relative; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; border: 0; padding: 0; background: var(--f-bg-3); }
.f-pick img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.f-pick span { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 6px 8px; background: linear-gradient(to top, rgba(8, 6, 14, 0.95), rgba(8, 6, 14, 0)); font-size: 13px; font-weight: 800; color: #fff; }
.f-pick button[aria-pressed="true"] { box-shadow: inset 0 0 0 3px var(--gold); }
.f-pick button[aria-pressed="true"]::after { content: "✓"; position: absolute; right: 6px; top: 6px; width: 22px; height: 22px; border-radius: 50%; background: var(--gold); color: var(--gold-ink); font-size: 13px; font-weight: 900; line-height: 22px; text-align: center; }
.f-notice { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.f-notice li { padding: 12px 14px; border-radius: 12px; background: var(--f-bg-3); font-size: 13px; line-height: 1.55; color: var(--f-text-2); }
.f-notice li b { display: block; color: var(--f-text); font-size: 13.5px; margin-bottom: 2px; }
.f-toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 10px; padding: 12px 14px; border-radius: 12px; background: var(--f-bg-3); font-size: 13px; color: var(--f-text-2); }

/* ── 데스크톱 ───────────────────── */
@media (min-width: 1024px) {
  .f-side { position: fixed; left: 0; top: 0; bottom: 0; z-index: 8; width: var(--side-w); display: flex; flex-direction: column; gap: 14px; padding: 20px 14px 18px; background: var(--f-bg); border-right: 1px solid var(--f-line); overflow-y: auto; }
  .f-side .f-logo { padding: 0 10px 8px; font-size: 26px; }
  .f-main { margin-left: var(--side-w); padding-bottom: 20px; }
  .f-top { height: 64px; padding: 0 28px; gap: 14px; }
  .f-logo-m, .f-search-m { display: none; }
  .f-make-btn { display: inline-block; }
  .f-kind { display: flex; gap: 2px; margin-right: 8px; }
  .f-kind-btn { height: 36px; padding: 0 14px; border-radius: 10px; font-size: 16px; font-weight: 800; color: var(--f-text-3); }
  .f-kind-btn.is-on { color: var(--f-text); }
  .f-search { display: flex; align-items: center; gap: 8px; flex: 1; max-width: 440px; height: 40px; margin-left: auto; padding: 0 14px; border-radius: 12px; background: var(--f-bg-3); color: var(--f-text-3); }
  .f-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; color: var(--f-text); font-size: 14px; }
  .f-search svg { width: 18px; height: 18px; }
  .f-chips { top: 64px; padding: 4px 28px 12px; }
  .f-banner-track { padding: 0 28px; gap: 14px; }
  .f-slide { width: min(860px, 64%); aspect-ratio: 21 / 9; border-radius: 18px; }
  .f-slide .txt { left: 32px; bottom: 28px; max-width: 60%; }
  .f-slide h3 { font-size: 28px; }
  .f-slide p { font-size: 15px; }
  .f-banner-count { right: auto; left: calc(28px + min(860px, 64%) - 74px); top: 16px; }
  .f-arrow { display: grid; place-items: center; position: absolute; top: 50%; z-index: 3; width: 40px; height: 40px; margin-top: -20px; border-radius: 50%; background: rgba(13, 11, 19, 0.82) !important; color: #fff; box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45); }
  .f-arrow.prev { left: 12px; }
  .f-arrow.next { right: 12px; }
  .f-arrow[disabled] { display: none; }
  .f-sec { margin-top: 34px; }
  .f-sec-h, .f-grid-tools { padding: 0 28px; }
  .f-row, .f-live { padding: 0 28px 4px; gap: 14px; }
  .f-card { width: 164px; }
  .f-rank .f-card { width: 196px; }
  .f-wide { width: 340px; }
  .f-live-card { width: 280px; }
  .f-tag { width: 200px; }
  .f-event { width: 440px; }
  .f-grid { grid-template-columns: repeat(auto-fill, minmax(156px, 1fr)); gap: 22px 14px; padding: 0 28px; }
  .f-foot { padding: 28px 28px 24px; }
  .f-tabbar { display: none; }
  .f-sheet { align-items: center; padding: 24px; }
  .f-panel { max-width: 760px; border-radius: 20px; display: grid; grid-template-columns: 300px 1fr; max-height: 86vh; padding: 0; }
  .fd-hero { height: auto; min-height: 100%; }
  .fd-hero::after { background: linear-gradient(to left, var(--f-bg-2) 0%, rgba(21, 18, 30, 0) 30%); }
  .fd-body { margin-top: 0; padding: 26px 26px 0; overflow-y: auto; }
  .fd-cta { padding: 14px 26px 22px; }
  .f-pop.sheet { align-items: center; padding: 20px; }
  .f-pop.sheet .f-pop-box { border-radius: 18px; }
}
@media (min-width: 1440px) { .f-card { width: 172px; } }
@media (max-width: 359px) { .f-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) {
  #home { scroll-behavior: auto; }
  .f-panel, .f-pop-box, .f-sheet, .f-pop { animation: none; }
  .f-live-dot::before { animation: none; }
  .f-card:hover .f-cover img { transform: none; }
}

/* ── 상세: 등장인물 ─────────────────── */
.fd-cast { display: flex; gap: 10px; overflow-x: auto; margin: 16px 0 0; scrollbar-width: none; }
.fd-person { flex: none; display: flex; gap: 10px; align-items: center; width: 240px; padding: 10px; border-radius: 12px; background: var(--f-bg); border: 1px solid var(--f-line); }
.fd-person img, .fd-person > span { flex: none; width: 52px; height: 52px; border-radius: 50%; object-fit: cover; object-position: 50% 20%; background: var(--f-bg-3); }
.fd-person b { display: block; font-size: 14px; }
.fd-person small { display: block; font-size: 12px; color: var(--f-text-3); line-height: 1.4; }
.fd-desc b { color: var(--gold); font-weight: 700; }

/* ── 첫 장면 읽기 ─────────────────── */
.f-reader { position: fixed; inset: 0; z-index: 40; overflow-y: auto; background: var(--f-bg, #0d0b13); color: var(--text); }
.f-reader[hidden] { display: none; }
.r-wrap { max-width: 720px; margin: 0 auto; padding-bottom: calc(var(--safe-b) + 28px); }
.r-top { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; gap: 8px; height: calc(var(--safe-t) + 56px); padding: var(--safe-t) 10px 0; background: rgba(13, 11, 19, 0.9); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.r-top .f-icon { border: 0; background: none; color: var(--text); }
.r-top b { display: block; font-size: 15px; }
.r-top small { font-size: 12px; color: #9b93a8; }
.r-art { margin: 0; aspect-ratio: 16 / 10; overflow: hidden; background: #15121e; }
.r-art img { width: 100%; height: 100%; object-fit: cover; display: block; }
.r-body { padding: 22px 20px 0; font-family: var(--serif); font-size: 17px; line-height: 1.9; }
.r-body h2 { margin: 0 0 14px; font-family: var(--font); font-size: 20px; font-weight: 800; }
.r-narr { margin: 0 0 12px; color: #ddd6e8; }
.r-line { margin: 0 0 12px; color: #fff; }
.r-line b { display: block; font-family: var(--font); font-size: 12.5px; color: var(--gold); }
.r-stats { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 16px 0 0; padding: 0; font-family: var(--font); }
.r-stats li { font-size: 12.5px; padding: 5px 10px; border-radius: 999px; background: #1d1928; color: #b9b1c7; }
.r-stats b { color: #fff; }
.r-choices { display: grid; gap: 8px; margin: 20px 0 0; font-family: var(--font); }
.r-choice { text-align: left; padding: 14px 16px; border-radius: 14px; border: 1px solid rgba(242, 184, 79, 0.35); background: rgba(242, 184, 79, 0.08); color: #fff; font-size: 15px; font-weight: 600; line-height: 1.45; }
.r-choice:hover:not(:disabled) { background: rgba(242, 184, 79, 0.16); }
.r-choice:disabled { opacity: 0.45; border-color: rgba(255, 255, 255, 0.12); background: none; cursor: default; }
.r-choice small { display: block; font-size: 12px; font-weight: 500; color: #9b93a8; }
.r-end { margin: 22px 0 0; padding: 18px; border-radius: 16px; background: linear-gradient(135deg, #2a1f47, #171320); font-family: var(--font); text-align: center; }
.r-end small { font-size: 12px; color: var(--gold); font-weight: 800; }
.r-end b { display: block; margin: 4px 0 6px; font-size: 20px; }
.r-end p { margin: 0 0 12px; font-size: 13.5px; color: #b9b1c7; }
.r-end-acts { display: flex; gap: 8px; justify-content: center; }
.r-end-acts button { height: 42px; padding: 0 16px; border-radius: 12px; border: 0; background: var(--gold); color: var(--gold-ink); font-weight: 800; font-size: 14px; }
.r-end-acts button + button { background: #1d1928; color: #fff; }
.r-notes { margin: 18px 0 0; font-family: var(--font); font-size: 13.5px; color: #b9b1c7; }
.r-notes summary { cursor: pointer; font-weight: 800; color: #fff; padding: 6px 0; }
.r-notes p { margin: 6px 0; line-height: 1.6; }
.r-notes b { display: block; color: #fff; }
.r-free { display: flex; gap: 8px; margin: 22px 0 0; font-family: var(--font); }
.r-free input { flex: 1; min-width: 0; height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, 0.1); background: #15121e; color: #9b93a8; font-size: 13px; }
.r-free button { height: 44px; padding: 0 14px; border-radius: 12px; border: 0; background: #1d1928; color: #fff; font-weight: 700; font-size: 13.5px; }

/* ── v3.2.0: 콘텐츠 라이브러리 반영 ─────────────────────────── */
.f-badge.free { background: #3b82f6; color: #fff; }
.f-badge.draft { background: #a78bfa; color: #1b1033; }
.f-badge.rec { background: rgba(10, 8, 16, 0.78); color: #e6e0ee; }
.f-badge.adult { background: #e11d48; color: #fff; }
.f-count { font-size: 0.78em; font-weight: 700; color: var(--f-text-3); }
/* 제목 표지: 그림이 없는 작품은 새 그림을 만들지 않고 글자로만 */
.f-typo { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; padding: 14px 12px; background: linear-gradient(160deg, #2a2140, #120f1b 70%); }
.f-typo[data-genre="modern"] { background: linear-gradient(160deg, #1f3247, #0f141c 70%); }
.f-typo[data-genre="mystery"] { background: linear-gradient(160deg, #3a2a1c, #15100b 70%); }
.f-typo[data-genre="romance"] { background: linear-gradient(160deg, #47202f, #160c11 70%); }
.f-typo small { font-size: 11px; font-weight: 700; color: var(--gold); letter-spacing: 0.04em; }
.f-typo b { font-family: var(--serif); font-size: 19px; line-height: 1.25; font-weight: 700; color: #fff; word-break: keep-all; }
.f-typo i { font-style: normal; font-size: 11px; color: var(--f-text-3); }
.f-typo.person { justify-content: center; align-items: center; text-align: center; gap: 8px; }
.f-typo.person b { width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; font-size: 26px; background: rgba(255, 255, 255, 0.08); }
.f-typo.person small { color: var(--f-text-2); font-weight: 500; letter-spacing: 0; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.f-turns { position: absolute; right: 6px; bottom: 6px; z-index: 1; font-size: 11px; font-weight: 800; padding: 2px 7px; border-radius: 6px; background: rgba(10, 8, 16, 0.78); color: #fff; }
.f-play-card .f-cover img { filter: saturate(0.85) brightness(0.8); }
.f-play-card.adult .f-cover img, .f-play-card.adult .f-typo { filter: blur(10px) brightness(0.5); }
/* 상세 탭 */
.fd-hero .f-typo b { font-size: 26px; }
.fd-cap { position: absolute; left: 12px; bottom: 10px; z-index: 2; font-size: 11px; color: var(--f-text-3); }
.fd-tabs { display: flex; gap: 2px; margin: 14px -4px 0; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--f-line); }
.fd-tabs::-webkit-scrollbar { display: none; }
.fd-tabs button { flex: none; height: 40px; padding: 0 10px; font-size: 14px; font-weight: 700; color: var(--f-text-3); border-bottom: 2px solid transparent !important; }
.fd-tabs button[aria-selected="true"] { color: var(--f-text); border-bottom-color: var(--gold) !important; }
.fd-pane { padding-top: 4px; }
.fd-pane[hidden] { display: none; }
.fd-h { margin: 20px 0 8px; font-size: 14px; font-weight: 800; }
.fd-stats { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 12px 0 0; padding: 0; }
.fd-stats li { font-size: 12.5px; padding: 4px 10px; border-radius: 999px; background: var(--f-bg-3); color: var(--f-text-2); }
.fd-stats b { color: var(--f-text); }
.fd-cast.rich { flex-direction: column; overflow: visible; }
.fd-person.rich { width: auto; align-items: flex-start; }
.fd-person p { margin: 6px 0 0; font-size: 12.5px; line-height: 1.55; color: var(--f-text-2); }
.fd-person .speech { color: var(--f-text-3); }
.fd-person .sample { padding: 8px 10px; border-radius: 10px; background: var(--f-bg-2); color: var(--f-text); font-family: var(--serif); }
.fd-person .sample em { display: block; font-style: normal; font-family: var(--font); font-size: 11.5px; color: var(--f-text-3); margin-bottom: 2px; }
.fd-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.fd-list li { padding: 12px 14px; border-radius: 12px; background: var(--f-bg); border: 1px solid var(--f-line); font-size: 13px; line-height: 1.6; color: var(--f-text-2); white-space: pre-line; }
.fd-list b { display: block; color: var(--f-text); font-size: 13.5px; margin-bottom: 2px; }
.fd-rel { display: grid; gap: 8px; }
.fd-rel button { display: flex; gap: 10px; align-items: center; padding: 8px; border-radius: 12px; background: var(--f-bg) !important; border: 1px solid var(--f-line) !important; text-align: left; color: var(--f-text); }
.fd-rel img { width: 44px; height: 58px; border-radius: 6px; object-fit: cover; }
.fd-rel b { display: block; font-size: 13.5px; }
.fd-rel small { font-size: 12px; color: var(--f-text-3); }
.fd-gal { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 10px; }
.fd-gal button { position: relative; aspect-ratio: 3 / 4; border-radius: 8px; overflow: hidden; background: var(--f-bg-3) !important; }
.fd-gal img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.fd-gal small { position: absolute; left: 4px; bottom: 4px; font-size: 10px; font-weight: 700; padding: 1px 5px; border-radius: 4px; background: rgba(10, 8, 16, 0.75); color: #e6e0ee; }
.fd-ver { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 8px; }
.fd-ver li { display: flex; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 12px; background: var(--f-bg); border: 1px solid var(--f-line); }
.fd-ver li > div { flex: 1; min-width: 0; }
.fd-ver b { display: block; font-size: 13.5px; }
.fd-ver small { font-size: 12px; color: var(--f-text-3); }
.fd-ver p { margin: 4px 0 0; font-size: 12.5px; color: var(--f-text-2); }
.fd-ver button, .fd-cta .wide { flex: none; height: 34px; padding: 0 12px; border-radius: 10px; background: var(--gold) !important; color: var(--gold-ink); font-size: 13px; font-weight: 800; }
.fd-cta .wide { width: auto; height: 48px; padding: 0 16px; background: var(--f-bg-3) !important; color: var(--f-text); }
.fd-plays { display: grid; gap: 8px; margin-top: 10px; }
.fd-plays button { text-align: left; padding: 12px 14px; border-radius: 12px; background: var(--f-bg) !important; border: 1px solid var(--f-line) !important; color: var(--f-text); }
.fd-plays b { font-size: 13.5px; }
.fd-plays span { float: right; font-size: 12px; color: var(--f-text-3); }
.fd-plays p { margin: 4px 0 0; font-size: 12.5px; line-height: 1.5; color: var(--f-text-2); }
/* 플레이 기록 보기 */
.p-note { margin: 0 0 14px; padding: 10px 12px; border-radius: 10px; background: #15121e; font-family: var(--font); font-size: 12.5px; line-height: 1.6; color: #9b93a8; }
.p-turn { margin: 22px 0 0; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, 0.07); }
.p-turn h3 { margin: 0 0 12px; font-family: var(--font); font-size: 14px; font-weight: 800; color: var(--gold); }
.p-turn h3 small { margin-left: 6px; font-weight: 600; color: #9b93a8; }
.p-info { margin: 12px 0; padding: 10px 12px; border-radius: 10px; background: #15121e; font-family: ui-monospace, Menlo, monospace; font-size: 12px; line-height: 1.6; color: #b9b1c7; white-space: pre-wrap; }
.p-user { margin: 0 0 12px; padding: 10px 12px; border-radius: 12px; background: rgba(242, 184, 79, 0.1); border: 1px solid rgba(242, 184, 79, 0.25); font-family: var(--font); font-size: 14.5px; line-height: 1.6; }
.p-user b { display: block; font-size: 12px; color: var(--gold); }
.p-choices { display: grid; gap: 6px; margin-top: 12px; font-family: var(--font); }
.p-choices small { font-size: 12px; color: #9b93a8; }
.p-choices span { padding: 10px 12px; border-radius: 12px; border: 1px dashed rgba(255, 255, 255, 0.14); font-size: 13.5px; line-height: 1.5; color: #ddd6e8; }
.p-answer { margin: 12px 0 0; padding: 12px 14px; border-radius: 12px; background: #15121e; }
.p-answer header { font-family: var(--font); margin-bottom: 8px; }
.p-answer header b { font-size: 13.5px; }
.p-answer header small { margin-left: 6px; font-size: 12px; color: #9b93a8; }
/* 팝업: 설정 예시·성인·그림 */
.f-pop-h { margin: 14px 0 6px; font-size: 14px; font-weight: 800; }
.f-presets { display: grid; gap: 6px; max-height: 210px; overflow-y: auto; }
.f-presets button { text-align: left; padding: 8px 10px; border-radius: 10px; background: var(--f-bg-3) !important; color: var(--f-text); }
.f-presets b { display: block; font-size: 13px; }
.f-presets small { font-size: 11.5px; color: var(--f-text-3); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-pop-body .kick.adult { background: #e11d48; }
.f-lightbox { max-width: 560px; }
.f-lightbox > img { display: block; width: 100%; max-height: 70dvh; object-fit: contain; background: #08060c; }
/* 제작 기록 */
.lab-stat { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; list-style: none; margin: 0; padding: 0 16px; }
.lab-stat li { padding: 14px; border-radius: 14px; background: var(--f-bg-2); border: 1px solid var(--f-line); }
.lab-stat b { display: block; font-size: 24px; font-weight: 900; }
.lab-stat span { font-size: 13px; font-weight: 700; }
.lab-stat small { display: block; margin-top: 2px; font-size: 11.5px; color: var(--f-text-3); }
.lab-tabs { position: sticky; top: calc(var(--safe-t) + 56px); z-index: 4; display: flex; gap: 6px; margin: 18px 0 0; padding: 8px 16px; overflow-x: auto; scrollbar-width: none; background: var(--f-bg); }
.lab-tabs::-webkit-scrollbar { display: none; }
.lab-tabs button { flex: none; height: 34px; padding: 0 14px; border-radius: 999px; background: var(--f-bg-3) !important; color: var(--f-text-2); font-size: 13.5px; font-weight: 700; }
.lab-tabs button[aria-selected="true"] { background: var(--f-text) !important; color: #120f19; }
.lab-pane { padding: 6px 16px 0; }
.lab-note { margin: 6px 0 12px; font-size: 13px; line-height: 1.6; color: var(--f-text-3); }
.lab-filter { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.lab-filter button { height: 30px; padding: 0 11px; border-radius: 999px; background: var(--f-bg-3) !important; color: var(--f-text-2); font-size: 12.5px; font-weight: 700; }
.lab-filter button[aria-pressed="true"] { box-shadow: inset 0 0 0 1px var(--gold); color: var(--f-text); }
.lab-filter span { color: var(--f-text-3); font-weight: 600; }
.lab-gal { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.lab-gal button { position: relative; aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: #1a1624 !important; }
.lab-gal img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; }
.lab-gal small { position: absolute; left: 4px; bottom: 4px; right: 4px; font-size: 10px; font-weight: 700; padding: 1px 5px; border-radius: 4px; background: rgba(10, 8, 16, 0.75); color: #e6e0ee; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: left; }
.lab-ver { margin: 0 0 8px; border-radius: 12px; background: var(--f-bg-2); border: 1px solid var(--f-line); }
.lab-ver summary { display: flex; align-items: center; gap: 10px; padding: 12px 14px; cursor: pointer; list-style: none; }
.lab-ver summary::-webkit-details-marker { display: none; }
.lab-ver summary b { flex: 1; font-size: 14px; }
.lab-ver summary span { font-size: 12.5px; color: var(--f-text-3); }
.lab-ver summary button { height: 28px; padding: 0 10px; border-radius: 8px; background: var(--f-bg-3) !important; color: var(--f-text); font-size: 12px; font-weight: 700; }
.lab-ver ol { margin: 0; padding: 0 14px 12px 34px; display: grid; gap: 8px; }
.lab-ver li { font-size: 13px; line-height: 1.55; color: var(--f-text-2); }
.lab-ver li b { color: var(--f-text); margin-right: 6px; }
.lab-ver li small { display: block; color: var(--f-text-3); font-size: 11.5px; word-break: break-all; }
.lab-ver li p { margin: 2px 0 0; color: var(--f-text-3); }
.lab-lines { list-style: none; margin: 0; padding: 0 14px 12px; display: grid; gap: 8px; }
.lab-lines li { font-family: var(--serif); font-size: 14px; line-height: 1.6; }
.lab-lines small { display: block; font-family: var(--font); font-size: 11px; font-weight: 700; color: var(--gold); }
.lab-lines em { display: block; font-style: normal; font-family: var(--font); font-size: 12px; color: var(--f-text-3); }
.lab-q { display: grid; gap: 10px; }
.lab-q article { padding: 14px; border-radius: 14px; background: var(--f-bg-2); border: 1px solid var(--f-line); }
.lab-q article.good { border-left: 3px solid var(--f-new); }
.lab-q article.bad { border-left: 3px solid #f43f5e; }
.lab-q header { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.lab-q header b { font-size: 14px; }
.lab-q .good header b { color: var(--f-new); }
.lab-q .bad header b { color: #fb7185; }
.lab-q header span { font-size: 12px; padding: 2px 8px; border-radius: 999px; background: var(--f-bg-3); color: var(--f-text-2); }
.lab-q header small { font-size: 11.5px; color: var(--f-text-3); }
.lab-q p { margin: 0 0 6px; font-size: 13.5px; line-height: 1.6; }
.lab-q .u { color: var(--gold); }
.lab-q .u::before { content: "플레이어 · "; font-size: 11.5px; color: var(--f-text-3); }
.lab-q .n { color: var(--f-text-2); }
.lab-q .now { font-weight: 600; }
.lab-q .n.now { color: var(--f-text); font-family: var(--serif); }
.lab-q .pin { font-size: 12.5px; color: var(--f-text-3); }
.lab-q footer { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.lab-q footer span { font-size: 11.5px; padding: 3px 8px; border-radius: 6px; background: var(--f-bg-3); }
.lab-q footer .x { color: #fb7185; }
.lab-q footer .o { color: var(--f-text-3); }
.lab-media { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.lab-media figure { margin: 0; padding: 10px; border-radius: 12px; background: var(--f-bg-2); border: 1px solid var(--f-line); }
.lab-media video { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 8px; background: #000; }
.lab-media audio { width: 100%; }
.lab-media figcaption b { display: block; margin-top: 6px; font-size: 13px; }
.lab-media figcaption small { font-size: 11px; color: var(--f-text-3); word-break: break-all; }
.lab-basis { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px; }
.lab-basis li { display: flex; justify-content: space-between; padding: 10px 12px; border-radius: 10px; background: var(--f-bg-2); font-size: 13px; color: var(--f-text-2); }
.lab-basis b { color: var(--f-text); }
.lab-h { margin: 22px 0 6px; font-size: 15px; font-weight: 800; }
@media (min-width: 1024px) {
  .lab-stat, .lab-pane { padding-left: 28px; padding-right: 28px; }
  .lab-tabs { top: 64px; padding: 8px 28px; }
  .lab-gal { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
  .fd-gal { grid-template-columns: repeat(4, 1fr); }
}

/* 읽기 화면(z 40) 위에서 연 로그인·성인 안내도 보이도록 팝업을 가장 위에 둡니다. */
.f-pop { z-index: 50; }
.fd-person > span { display: grid; place-items: center; font-size: 20px; font-weight: 800; color: var(--f-text-2); }
.fd-cap { top: 12px; bottom: auto; padding: 2px 8px; border-radius: 6px; background: rgba(10, 8, 16, 0.6); }
.f-pop-box { max-height: calc(100dvh - 40px); overflow-y: auto; }

/* v3.5.0 캐릭터 카드: 인기 캐릭터챗처럼 얼굴 위에 상황 제목, 아래에 이름·관계 한 줄·첫 대사·태그 */
.f-char { width: 42vw; max-width: 210px; }
.f-char .f-cover::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to top, rgba(8, 6, 14, 0.9) 0%, rgba(8, 6, 14, 0.3) 30%, rgba(8, 6, 14, 0) 46%); }
.f-char .f-ttl { position: absolute; left: 10px; right: 10px; bottom: 10px; z-index: 2; font-size: 17px; font-weight: 900; line-height: 1.22; letter-spacing: -0.02em; color: #fff; word-break: keep-all; text-shadow: 0 2px 10px rgba(0, 0, 0, 0.75), 0 0 2px rgba(0, 0, 0, 0.9); }
.f-char h3 small { margin-left: 3px; font-size: 11px; font-weight: 700; color: var(--gold); }
.f-char .hook { margin: 0 0 4px; font-size: 12px; line-height: 1.45; color: var(--f-text-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.f-char .quote { margin: 0 0 4px; font-size: 12px; color: #f1e4ff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-badge.char { background: #d9407a; }
.f-slide .kick.char { background: #d9407a; color: #fff; }
.fd-first { margin: 10px 0 6px; padding: 12px 14px; border-radius: 12px; background: var(--f-bg-3); font-size: 15px; line-height: 1.5; }
.fd-first b { display: block; margin-bottom: 4px; font-size: 12px; color: var(--gold); }
@media (min-width: 1024px) { .f-char { width: 208px; } .f-char .f-ttl { font-size: 19px; } }
