/* ═══ Glitter Books — A4 전자책 조판 시스템 (테마 변수 기반) ═══ */
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.min.css');
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;600;700;800&family=Noto+Serif+KR:wght@400;600;700;900&family=Noto+Sans+KR:wght@400;500;700&family=Gowun+Batang:wght@400;700&display=swap');
@import url('https://hangeul.pstatic.net/hangeul_static/css/maru-buri.css');
/* fonts-archive CDN — 사용될 때만 폰트 파일 다운로드됨 */
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/SUIT/SUIT.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/PyeongChangPeace/PyeongChangPeace.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/Aggro/Aggro.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/JejuDoldam/JejuDoldam.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/GangwonEduPower/GangwonEduPower.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/PartialSansKR/PartialSansKR.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/BookkMyungjo/BookkMyungjo.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/ChosunGu/ChosunGu.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/NanumSquareRound/NanumSquareRound.css');
@import url('https://cdn.jsdelivr.net/gh/fonts-archive/AritaDotum/AritaDotum.css');
/* 눈누 npm CDN */
@import url('https://cdn.jsdelivr.net/npm/@noonnu/vitro-core@0.1.0/index.css');
@import url('https://cdn.jsdelivr.net/npm/@noonnu/lee-seoyun@0.1.0/index.css');
/* 개별 @font-face */
@font-face { font-family:'OwnglyphPDH'; font-weight:400 700;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/2411-3@1.0/Ownglyph_ParkDaHyun.woff2') format('woff2'); font-display:swap; }
@font-face { font-family:'HiKR'; font-weight:400 800;
  src:url('https://cdn.jsdelivr.net/gh/Project-Noonnu/2607101609@hikr-extrabold/hikr-extrabold/HiKR-ExtraBold.woff2') format('woff2'); font-display:swap; }

/* 눈누 무료폰트 (사용할 때만 다운로드됨) */
@font-face { font-family:'GmarketSans'; font-weight:500;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/noonfonts_2001@1.1/GmarketSansMedium.woff') format('woff'); font-display:swap; }
@font-face { font-family:'GmarketSans'; font-weight:700;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/noonfonts_2001@1.1/GmarketSansBold.woff') format('woff'); font-display:swap; }
@font-face { font-family:'Paperlogy'; font-weight:400;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/2408-3@1.0/Paperlogy-4Regular.woff2') format('woff2'); font-display:swap; }
@font-face { font-family:'Paperlogy'; font-weight:800;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/2408-3@1.0/Paperlogy-8ExtraBold.woff2') format('woff2'); font-display:swap; }
@font-face { font-family:'SCoreDream'; font-weight:400;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/noonfonts_six@1.2/S-CoreDream-4Regular.woff') format('woff'); font-display:swap; }
@font-face { font-family:'SCoreDream'; font-weight:800;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/noonfonts_six@1.2/S-CoreDream-8Heavy.woff') format('woff'); font-display:swap; }
@font-face { font-family:'Cafe24Ssurround'; font-weight:400 900;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/noonfonts_2105_2@1.0/Cafe24Ssurround.woff') format('woff'); font-display:swap; }
@font-face { font-family:'KoPubDotum'; font-weight:400 700;
  src:url('https://cdn.jsdelivr.net/gh/projectnoonnu/noonfonts_two@1.0/KoPubDotumMedium.woff') format('woff'); font-display:swap; }

#book, #book * { margin:0; padding:0; box-sizing:border-box;
  -webkit-print-color-adjust:exact!important; print-color-adjust:exact!important; }
@page { size:A4; margin:0; }

/* 테마가 덮어쓰는 변수 기본값 (에디토리얼 — 화이트+카민 매거진) */
#book {
  --bg:#ffffff; --bg2:#f7f6f3; --bg3:#eceae5;
  --text:#1a1a1a; --muted:#484848; --muted2:#9b9b9b; --border:#e3e1db;
  --accent:#CF0A0A; --accent-dk:#8F0707; --accent-l:#FBEAEA; --accent-m:#DC5F00;
  --warn:#D97706; --warn-l:#FFFBEB; --warn-text:#78350F;
  --font-body:'Pretendard','Noto Sans KR',sans-serif;
  --font-disp:'Plus Jakarta Sans','Pretendard',sans-serif;
  --r:0px;
  --fs-body:12pt; --lh:1.9; --para-gap:10px; --blk-gap:12px;
  --pw:210mm; --ph:297mm;
  font-family:var(--font-body); color:var(--text);
  line-height:1.7; word-break:keep-all;
}

/* ── 페이지 ── */
#book .page { width:var(--pw); height:var(--ph); background:var(--bg);
  margin:8px auto; box-shadow:0 8px 40px rgba(0,0,0,.14);
  page-break-after:always; break-after:page; position:relative; overflow:hidden; }
#book .pf { position:absolute; bottom:12mm; left:0; right:0;
  display:flex; justify-content:space-between; padding:0 20mm;
  font-size:10px; color:var(--muted2); }
#book .pf .cr { position:absolute; left:0; right:0; text-align:center; font-size:8px; opacity:.55; }

/* ── 표지 ── */
#book .cover { height:var(--ph); background:var(--bg)!important;
  display:flex; flex-direction:column; position:relative; overflow:hidden; }
#book .cv-topbar { background:var(--accent); height:8px; flex-shrink:0; }
#book .cv-meta { display:flex; justify-content:space-between; align-items:center;
  padding:10px 20mm; border-bottom:1px solid var(--border); }
#book .cv-vol { font-family:var(--font-disp); font-size:10px; font-weight:800;
  letter-spacing:.18em; text-transform:uppercase; color:var(--accent); }
#book .cv-year { font-size:10px; font-weight:600; color:var(--muted); letter-spacing:.08em; }
#book .cv-hero { flex:1; display:flex; flex-direction:column; justify-content:center; padding:0 20mm; }
#book .cv-label { font-size:9.5px; font-weight:700; color:var(--muted);
  letter-spacing:.16em; text-transform:uppercase; margin-bottom:10mm; }
#book .cv-title { font-family:var(--font-disp); font-size:56px; font-weight:800;
  color:var(--text); line-height:1.08; letter-spacing:-0.03em; margin-bottom:7mm; }
#book .cv-title .hl { color:var(--accent); }
#book .cv-block { background:var(--accent); padding:7mm 20mm; flex-shrink:0; }
#book .cv-sub { font-size:12px; color:rgba(255,255,255,.88); line-height:1.9; max-width:400px; }
#book .cv-sub strong { color:#fff; }
#book .cv-bot { padding:8mm 20mm; border-top:1px solid var(--border);
  display:flex; justify-content:space-between; align-items:center; flex-shrink:0; }
#book .cv-tags { display:flex; flex-wrap:wrap; gap:5px; }
#book .ctag { background:var(--bg2); border:1px solid var(--border); border-radius:var(--r);
  font-size:9.5px; font-weight:600; color:var(--muted); padding:3px 9px; }
#book .cv-author { font-size:11px; color:var(--muted); font-weight:600; }

/* ── 목차 ── */
#book .toc-title { font-family:var(--font-disp); font-size:26px; font-weight:800;
  margin-bottom:6mm; letter-spacing:-0.02em; }
#book .toc-ch { display:flex; align-items:flex-end; justify-content:space-between; gap:10px;
  font-size:10px; font-weight:800; color:var(--accent);
  letter-spacing:.14em; text-transform:uppercase;
  padding:14px 0 7px; margin-top:6px; border-bottom:2px solid var(--accent); }
#book .toc-ch > span:first-child { min-width:0; overflow-wrap:anywhere; }
#book .toc-ch .toc-pg { margin-left:auto; }
#book .toc-title.toc-cont { font-size:21px; }
#book .toc-row { display:flex; align-items:center; padding:8px 0;
  border-bottom:1px solid var(--border); font-size:12.5px; }
#book .toc-n { color:var(--accent); font-weight:700; font-size:10.5px;
  margin-right:10px; flex-shrink:0; min-width:26px; font-family:var(--font-disp); }
#book .toc-name { color:var(--muted); }
#book .toc-dots { flex:1; border-bottom:1px dotted var(--border);
  margin:0 8px 5px; height:1px; align-self:flex-end; }
#book .toc-pg { color:var(--text); font-size:11px; font-weight:700; flex-shrink:0; font-family:var(--font-disp); }

/* ── 챕터 표제지 ── */
#book .ch-page { height:var(--ph); background:var(--bg)!important;
  display:flex; flex-direction:column; position:relative; overflow:hidden;
  border-top:8px solid var(--accent); }
#book .ch-bg-n { position:absolute; right:-10mm; top:50%; transform:translateY(-52%);
  font-family:var(--font-disp); font-size:230px; font-weight:800;
  color:var(--accent-m); line-height:1; letter-spacing:-0.06em; opacity:.5; }
#book .ch-c { position:relative; z-index:2; display:flex; flex-direction:column;
  justify-content:center; flex:1; padding:0 20mm; }
#book .ch-tag { display:inline-block; background:var(--accent); color:#fff;
  font-size:12px; font-weight:700; padding:5px 14px; border-radius:var(--r);
  letter-spacing:.12em; text-transform:uppercase; margin-bottom:14px; align-self:flex-start; }
#book .ch-title { font-family:var(--font-disp); font-size:48px; font-weight:800;
  color:var(--text); line-height:1.08; letter-spacing:-0.03em; margin-bottom:11px; }
#book .ch-topics { display:flex; flex-direction:column; gap:0; margin-top:10px; max-width:420px; }
#book .ch-topic { display:flex; align-items:center; gap:8px; font-size:13.5px;
  color:var(--muted); font-weight:500; padding:8px 0; border-top:1px solid var(--border); }
/* 화살표도 글리프 대신 CSS 셰브론 (폰트 미지원 대비) */
#book .ch-topic::before { content:''; width:7px; height:7px; flex-shrink:0;
  border-top:1.5px solid var(--accent); border-right:1.5px solid var(--accent);
  transform:rotate(45deg); margin-right:2px; }

/* ── 본문 페이지 ── */
#book .pi { padding:16mm 20mm 22mm; height:var(--ph);
  display:block; overflow:hidden; } /* flex 금지 — 자식 float(이미지 텍스트 랩)이 무시됨 */
#book .ph { display:flex; justify-content:space-between; align-items:center;
  padding-bottom:10px; border-bottom:2px solid var(--text);
  margin-bottom:20px; flex-shrink:0; }
#book .ph-l { font-size:11px; font-weight:700; color:var(--text); letter-spacing:.06em; font-family:var(--font-disp); }
#book .ph-r { font-size:11px; font-weight:500; color:var(--muted); letter-spacing:.06em; }

#book h2.sh { font-size:16pt; font-weight:700; color:var(--text);
  margin:18px 0 10px; padding-left:12px; border-left:3px solid var(--accent); line-height:1.4; }
#book h3.sh3 { font-size:12.5pt; font-weight:700; color:var(--text); margin:14px 0 7px; }
#book .pi > h2.sh:first-of-type { margin-top:0; }
#book p { font-size:var(--fs-body); color:var(--muted);
  margin-bottom:var(--para-gap); line-height:var(--lh); }
#book p strong { color:var(--text); }
#book mark { color:inherit; padding:0 2px; border-radius:2px; }
#book mark.mk-y { background:#ffe95e; }
#book mark.mk-p { background:#ffd3e4; }
#book mark.mk-m { background:#c4f2de; }
#book .fig-cap:empty::before { content:'캡션 입력 (클릭)'; color:var(--muted2); opacity:.55; }
@media print { #book .fig-cap:empty { display:none; } }

/* ── 컴포넌트 ── */
#book .quote { border-left:3px solid var(--accent); padding:11px 15px;
  margin:var(--blk-gap) 0; background:var(--accent-l); border-radius:var(--r); }
#book .quote p { font-size:calc(var(--fs-body) + 1.5pt); font-weight:600;
  color:var(--text); margin:0; line-height:1.65; }

/* 풀쿼트 — 발췌 강조 (본문 1.65배, 액센트 바, 배경 없음) */
#book .pull { margin:calc(var(--blk-gap) + 12px) 0; }
#book .pull::before { content:''; display:block; width:26px; height:2.5px;
  background:var(--accent); margin-bottom:14px; }
#book .pull p { font-family:var(--font-disp); font-size:calc(var(--fs-body) * 1.65);
  line-height:1.55; font-weight:700; color:var(--text); letter-spacing:-0.01em;
  margin:0; max-width:92%; text-indent:0; }

/* 챕터 오프닝 페이지 — 에세이·실용서·워크북 모두 같은 상단 여백 */
#book .pi.ch-open { padding-top:32mm; }
#book .pi.ch-open .ph { visibility:hidden; }

#book .chk { list-style:none; display:flex; flex-direction:column; gap:6px; margin:7px 0 var(--blk-gap); }
#book .chk li { display:flex; align-items:flex-start; gap:8px;
  font-size:var(--fs-body); color:var(--muted); line-height:1.65; }
/* 체크박스는 폰트 글리프 대신 CSS로 직접 그림 — 폰트에 □ 없을 때 검은 네모(tofu) 방지 */
#book .chk li::before { content:''; width:10px; height:10px; border:1.5px solid var(--muted2);
  border-radius:2px; flex-shrink:0; margin-top:4px; }

#book .steps { display:flex; flex-direction:column; margin:9px 0 var(--blk-gap); }
#book .step { display:flex; }
#book .sl { display:flex; flex-direction:column; align-items:flex-start; padding-right:14px; flex-shrink:0; }
#book .sn { width:auto; height:auto; background:none; color:var(--accent); border-radius:0;
  display:block; font-size:20px; font-weight:800; font-family:var(--font-disp); line-height:1;
  min-width:24px; text-align:left; }
#book .sline { display:none; }
#book .sr { padding:1px 0 14px; flex:1; }
#book .sr p { font-size:var(--fs-body); margin:0; line-height:1.75; }
#book .sr p strong { display:block; margin-bottom:2px; }

#book .tip, #book .warn { border-radius:0; padding:1px 0 1px 16px; margin:12px 0 var(--blk-gap);
  border-left:2px solid var(--accent); background:none; }
#book .tip-t, #book .warn-t { font-size:calc(var(--fs-body) - 1pt); font-weight:700;
  letter-spacing:.02em; margin-bottom:3px; }
#book .tip-t { color:var(--accent-dk); }
#book .tip p, #book .warn p { font-size:calc(var(--fs-body) - 0.5pt); color:var(--text); margin:0; line-height:1.7; }
#book .warn { border-left-color:var(--warn); }
#book .warn-t { color:var(--warn); }

#book .copy { background:var(--text); border-radius:var(--r);
  padding:18px 18px 16px; margin:calc(var(--blk-gap) + 3px) 0; position:relative; }
#book .copy::before { content:'복사해서 붙여넣기'; position:absolute; top:-9px; left:14px;
  background:var(--accent); color:#fff; font-size:10px; font-weight:700;
  padding:2px 9px; border-radius:2px; letter-spacing:.04em; }
#book .copy code { font-family:'IBM Plex Mono','SF Mono',monospace;
  font-size:calc(var(--fs-body) - 1pt); color:rgba(255,255,255,.9);
  line-height:1.85; white-space:pre-wrap; display:block; margin-top:4px; }

#book .divider { display:flex; align-items:center; gap:10px; margin:calc(var(--blk-gap) + 4px) 0; }
#book .divider::before, #book .divider::after { content:''; flex:1; height:1px; background:var(--border); }
#book .divider span { font-size:10px; color:var(--accent); }

#book .fig-wrap { margin:var(--blk-gap) 0; }
#book h2.sh, #book h3.sh3 { clear:both; } /* 플로트 이미지가 제목을 침범하지 않게 */
#book img.fig { display:block; margin:0 auto; max-width:100%;
  border:1px solid var(--border); border-radius:var(--r); }
#book .fig-cap { text-align:center; font-size:calc(var(--fs-body) - 2pt);
  color:var(--muted2); margin-top:6px; }
#book .fig-miss { border:1.5px dashed var(--border); border-radius:var(--r);
  padding:14px; margin:12px 0; text-align:center;
  font-size:calc(var(--fs-body) - 1pt); color:var(--muted2); }

/* ── 표 ── */
#book table.tbl { width:100%; border-collapse:collapse; margin:10px 0 var(--blk-gap);
  font-size:calc(var(--fs-body) - 0.5pt); }
#book .tbl th { padding:9px 12px; text-align:left; font-size:calc(var(--fs-body) - 1pt);
  font-weight:700; color:#fff; background:var(--accent-dk); letter-spacing:.04em; }
#book .tbl td { padding:8px 12px; border-bottom:1px solid var(--border); color:var(--muted); }
#book .tbl td strong { color:var(--text); }
#book .tbl tr:nth-child(even) td { background:var(--bg2); }

/* ── 기록 빈칸 (워크북) ── */
#book .wlines { margin:8px 0 var(--blk-gap); }
#book .wline { height:2.2em; border-bottom:1px dashed var(--muted2); }

/* ── 마지막 안내 페이지 (도구 소개) ──
   내용을 세로 가운데로 모은다. 아래로 밀어두면 가운데가 텅 비어 보인다. */
#book .cta-page .pi { padding:26mm 24mm 22mm; display:flex; flex-direction:column;
  justify-content:center; }
#book .cta-head { position:absolute; top:26mm; left:24mm; right:24mm;
  font-size:9.5px; letter-spacing:.22em; text-transform:uppercase;
  color:var(--muted2); padding-bottom:7px; border-bottom:1px solid var(--border); }
#book .cta-t { font-family:var(--font-disp); font-size:30px; font-weight:800;
  line-height:1.35; color:var(--text); letter-spacing:-0.01em; }
#book .cta-t em { font-style:normal; color:var(--accent); }
#book .cta-lead { margin-top:7mm; font-size:11.5px; line-height:2; color:var(--muted);
  max-width:78%; text-indent:0; }
#book .cta-room { margin-top:14mm; border:1px solid var(--border); background:var(--bg2);
  border-radius:var(--r); padding:8mm 9mm; }
#book .cta-room .tag { display:inline-block; font-size:8.5px; font-weight:700; letter-spacing:.14em;
  color:var(--accent-dk); background:var(--accent-l); padding:3px 8px; border-radius:100px; }
#book .cta-room b { display:block; margin-top:6px; font-size:13.5px; color:var(--text); }
#book .cta-room .note { margin-top:5px; font-size:10.5px; line-height:1.8; color:var(--muted); text-indent:0; }
#book .cta-room a { display:inline-block; margin-top:6px; font-size:12px; font-weight:700;
  color:var(--accent-dk); word-break:break-all; text-decoration:underline; text-underline-offset:3px; }

/* ── 무료 모드 워터마크 ──
   편집 중 화면에서는 보이지 않는다 — 실제 PDF 저장(인쇄)에서만 나타난다.
   DOM 에는 항상 들어 있으므로 개발자도구로 지워도 인쇄 시점에 다시 만들어진다. */
#book .wmark { position:absolute!important; inset:-25%; z-index:9; pointer-events:none;
  display:none; flex-wrap:wrap; gap:70px 50px; align-items:center; justify-content:center;
  transform:rotate(-28deg); }
@media print { #book .wmark { display:flex!important; } }
#book .wmark i { font-style:normal; font-family:'Pretendard',sans-serif;
  font-size:24px; font-weight:800; letter-spacing:.18em; white-space:nowrap;
  color:rgba(0,0,0,.13); }
/* 페이지 중앙 큰 문구 — 타일과 별개로 1개만 */
#book .wmark .wm-center { position:absolute; left:50%; top:50%;
  transform:translate(-50%,-50%); font-family:'Pretendard',sans-serif;
  font-size:42px; font-weight:800; letter-spacing:.22em; white-space:nowrap;
  color:rgba(0,0,0,.18); }
/* 표지는 반복 워터마크 대신 한 번만 표시해 체크무늬처럼 보이지 않게 한다. */
#book .cover .wmark { inset:0; display:none; transform:none; }
@media print { #book .cover .wmark { display:block!important; } }
#book .cover .wmark i { display:none; }
#book .cover .wmark i:first-child { display:block; position:absolute; left:50%; top:52%;
  transform:translate(-50%,-50%) rotate(-28deg); font-size:28px; color:rgba(0,0,0,.13); }
#book .cover .wmark .wm-center { top:62%; font-size:34px; color:rgba(0,0,0,.16);
  transform:translate(-50%,-50%) rotate(-28deg); }

/* 어두운 배경 페이지 — 흰색 반투명으로 (밝은 표지·본문은 위 검정 스타일 그대로) */
#book .wmark.on-dark i { color:rgba(255,255,255,.16); }
#book .wmark.on-dark .wm-center { color:rgba(255,255,255,.22); }
#book .cover .wmark.on-dark i:first-child { color:rgba(255,255,255,.16); }
#book .cover .wmark.on-dark .wm-center { color:rgba(255,255,255,.20); }

/* ── 블록 선택 표시 ── */
#book [data-b0] { cursor:pointer; }
#book .b-sel { outline:2px solid var(--accent); outline-offset:5px; border-radius:2px; }
#book .t-sel { outline:2px solid var(--accent); outline-offset:5px; border-radius:2px; }
@media print { #book .b-sel, #book .t-sel { outline:none!important; } }

/* ── 미리보기 직접 수정 표시 ── */
#book [contenteditable]:hover { outline:1.5px dashed color-mix(in srgb, var(--accent) 55%, transparent); outline-offset:3px; cursor:text; }
#book [contenteditable]:focus { outline:2px solid var(--accent); outline-offset:3px; background:color-mix(in srgb, var(--accent) 6%, transparent); }
@media print { #book [contenteditable]:hover, #book [contenteditable]:focus { outline:none!important; background:none!important; } }

/* ── 뒤표지 ── */
#book .bc { height:var(--ph); background:var(--bg)!important;
  display:flex; flex-direction:column; position:relative; }
#book .bc-band { background:var(--accent); height:8px; flex-shrink:0; }
#book .bc-inner { flex:1; display:flex; flex-direction:column;
  justify-content:center; padding:0 25mm; gap:8mm; }
#book .bc-title { font-family:var(--font-disp); font-size:24px; font-weight:800; line-height:1.3; }
#book .bc-msg { font-size:13px; color:var(--muted); line-height:2; max-width:400px; }
#book .bc-author { font-size:12px; font-weight:700; color:var(--accent); }

/* ── 편집 가능 안내: 마우스를 올리면 점선 테두리로 표시 ── */
#book [data-b0]:hover:not(.b-sel) { outline:1.5px dashed #b6b6c0; outline-offset:5px; border-radius:2px; }

/* 장식 다이아몬드 — 폰트 글리프 대체 */
#book .orn-d { display:inline-block; width:7px; height:7px; background:var(--muted2);
  transform:rotate(45deg); }

/* ── 이미지 모서리 리사이즈 핸들 ── */
#book .fig-wrap { position:relative; }
#book .rz-h { position:absolute; width:13px; height:13px; background:#fff;
  border:2px solid #1d1d1f; border-radius:50%; z-index:5; touch-action:none;
  box-shadow:0 1px 4px rgba(0,0,0,.25); }
#book .rz-nw { left:-7px; top:-7px; cursor:nwse-resize; }
#book .rz-ne { right:-7px; top:-7px; cursor:nesw-resize; }
#book .rz-sw { left:-7px; bottom:-7px; cursor:nesw-resize; }
#book .rz-se { right:-7px; bottom:-7px; cursor:nwse-resize; }
#book .cv-sel { outline:2px solid #1d1d1f; outline-offset:4px; border-radius:2px; }
@media print { #book .rz-h, #book .cv-sel { outline:none!important; display:revert; }
  #book .rz-h { display:none!important; } }

/* ── 표지의 빈 항목: 화면에서만 연한 안내 문구 표시 (클릭해서 입력) ── */
#book .cover [data-edit]:empty::before, #book .cover [data-edit]:has(br:only-child)::before {
  content:attr(data-ph); opacity:.32; font-weight:400; }
#book .cover [data-edit]:empty { min-height:1em; min-width:40px; display:inline-block; }
#book .cover div[data-edit]:empty { display:block; }
@media print { #book .cover [data-edit]:empty::before,
  #book .cover [data-edit]:has(br:only-child)::before { content:none !important; } }
@media print { #book .cover [data-edit]:empty { display:none !important; } }

/* ── 이미지 좌우 드래그: 세로 스크롤은 유지, 가로 제스처만 잡음 + 고스트 드래그 방지 ── */
#book .fig-wrap, #book .cv-user-wrap { touch-action:pan-y; }
#book img { -webkit-user-drag:none; user-select:none; }

/* ── A5 판형 (148×210mm — 국내 전자책 단행본 표준) ── */
#book[data-size="a5"] { --pw:148mm; --ph:210mm; }
#book[data-size="a5"] .pi { padding:12mm 14mm 16mm; }

/* ── 드래그 이동 — 놓일 페이지 하이라이트 ── */
#book .page.drop-page { outline:3px solid color-mix(in srgb, var(--accent) 60%, transparent);
  outline-offset:-3px; }
@media print { #book .page.drop-page { outline:none!important; } }

/* ── 사진 이동 중 표시 (몸통을 세로로 끌 때) ── */
#book .fig-wrap.moving { opacity:.45; }
