/* 손글씨: Gaegu (SIL OFL 1.1, public/fonts/OFL-Gaegu.txt). 한글 11,172자와 기본 문장부호만 담아 자체 호스팅한다. */
@font-face { font-family: 'DM Serif Display'; src: url(/fonts/dmserif-latin.woff2) format('woff2'); font-weight: 400; font-style: normal; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Gaegu'; src: url(/fonts/gaegu.woff2) format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
/* 어드벤트 캘린더
   방향: 손으로 만든 종이 선물. 판(그림)만 색을 갖고 나머지 화면은 조용하게.
   간격 4/8/12/16/20/24/32, 곡선 하나(--ease), 강조색 하나(--accent). */
:root {
  --foil: linear-gradient(165deg, #fff5cf 0%, #f0cd7a 30%, #c99536 55%, #f7e1a1 75%, #b8862c 100%);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .35 0 0 0 0 .28 0 0 0 0 .18 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E");
  --night: #0f1b1d;
  --ink: #1c1a17; --ink2: #5c554b; --ink3: #8a8378; --ink4: #b5ada1;
  --paper: #fbf8f2; --group: #fffdf9; --canvas: #f2efe9; --fill: #ebe5da; --hair: rgba(60, 50, 40, .13);
  --accent: #b23a2e; --accent-press: #9a3127;
  --cream: #f6efe0; --pine: #1d3b33;
  --w1: rgba(255,255,255,.92); --w2: rgba(255,255,255,.62); --w3: rgba(255,255,255,.4); --wfill: rgba(255,255,255,.08); --whair: rgba(255,255,255,.1);
  --ui: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Apple SD Gothic Neo', 'Pretendard', 'Noto Sans KR', system-ui, sans-serif;
  --letter: 'Gowun Batang', 'AppleMyungjo', serif;
  --num: 'DM Serif Display', Georgia, serif;
  --ease: cubic-bezier(.32, .72, 0, 1);
  --safe-t: env(safe-area-inset-top, 0px); --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  background: var(--night); color: var(--w1); font: 400 16px/1.45 var(--ui); letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; overflow-x: hidden;
  word-break: keep-all; overflow-wrap: break-word; -webkit-text-size-adjust: 100%;
}
body.light { background: var(--canvas); color: var(--ink); }
body.light #snow { display: none; }
button, input, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; -webkit-user-select: none; user-select: none; }
a { color: inherit; text-decoration: none; }
#snow { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 0; }
#app { position: relative; z-index: 1; }
#fx { position: fixed; inset: 0; pointer-events: none; z-index: 50; overflow: hidden; }

/* 누르면 살짝 들어가는 공통 반응 */
.press { transition: transform .18s var(--ease), opacity .18s var(--ease), background-color .18s var(--ease); }
.press:active { transform: scale(.97); opacity: .85; }

/* 위에서 내려오는 알림 */
#toast {
  position: fixed; left: 50%; top: calc(var(--safe-t) + 10px); transform: translate(-50%, calc(-100% - 20px));
  background: rgba(28, 28, 30, .88); -webkit-backdrop-filter: blur(20px) saturate(1.6); backdrop-filter: blur(20px) saturate(1.6);
  color: #fff; padding: 11px 18px; border-radius: 22px; font-size: 14px; font-weight: 500; line-height: 1.35;
  box-shadow: 0 10px 30px rgba(0,0,0,.25); pointer-events: none; z-index: 95; max-width: calc(100vw - 32px); text-align: center; text-wrap: balance;
  transition: transform .45s var(--ease);
}
#toast.on { transform: translate(-50%, 0); }

/* ---------- 보기 화면 ---------- */
.viewer { min-height: 100svh; display: flex; flex-direction: column; align-items: center; padding: calc(var(--safe-t) + 8px) 0 calc(var(--safe-b) + 24px); }
.v-top { width: 100%; max-width: 600px; display: flex; align-items: center; justify-content: space-between; padding: 0 16px; min-height: 40px; }
.v-to { font-size: 14px; color: var(--w2); }
.round { width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--wfill); color: var(--w2); display: grid; place-items: center; }
.round svg { width: 17px; height: 17px; }
.v-title { font-size: 26px; line-height: 1.2; font-weight: 650; letter-spacing: -0.025em; text-align: center; margin: 4px 24px 6px; text-wrap: balance; }
.v-status { font-size: 15px; color: var(--w2); text-align: center; min-height: 22px; font-variant-numeric: tabular-nums; }
.v-status b { color: var(--w1); font-weight: 600; }
.pv-pill { position: sticky; top: calc(var(--safe-t) + 8px); z-index: 5; display: flex; align-items: center; gap: 4px; padding: 4px; margin: 0 0 12px; border-radius: 20px; white-space: nowrap;
  background: rgba(36, 44, 46, .78); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); font-size: 13px; box-shadow: 0 6px 20px rgba(0,0,0,.25); }
.pv-pill span { padding: 0 8px 0 10px; color: var(--w2); }
.demo-pill { min-height: 40px; padding: 4px 4px 4px 14px; font-size: 13px; }
.demo-pill span { flex: 1; padding: 0; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.demo-pill button, .demo-pill a { padding: 6px 11px; font-size: 13px; }
.demo-pill .cta-pill { background: rgba(255,255,255,.9); color: #1b2426; }
.pv-pill button, .pv-pill a { white-space: nowrap; flex: none; border: 0; border-radius: 16px; padding: 7px 12px; background: rgba(255,255,255,.12); color: var(--w1); font-weight: 500; }

.board-wrap { width: 100%; display: flex; justify-content: center; padding: 0 3vw; margin-top: 18px; }
.board {
  --w: min(94vw, 560px, calc((100svh - 190px) / 1.5));
  position: relative; width: max(300px, var(--w)); aspect-ratio: 2 / 3;
  background: #20343a var(--cover, url(/img/cover.jpg)) center / 100% 100% no-repeat;
  border-radius: 6px; padding: 3.4%;
  box-shadow: inset 0 0 0 .5px rgba(255,255,255,.25), 0 50px 80px -30px rgba(0,0,0,.8), 0 18px 30px -12px rgba(0,0,0,.5), 0 2px 4px rgba(0,0,0,.3);
  display: grid; grid-template-columns: repeat(5, 1fr); grid-template-rows: repeat(6, 1fr); gap: 2.4%;
  user-select: none; -webkit-user-select: none; -webkit-touch-callout: none;
}
.board::after { content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: linear-gradient(165deg, rgba(255,255,255,.06), transparent 35%, rgba(0,0,0,.14)); }

.door { --c: clamp(9px, 19cqmin, 16px); position: relative; container-type: size; border: 0; padding: 0; margin: 0; background: none; outline: none; touch-action: pan-y; -webkit-user-select: none; }
.door.ready { touch-action: none; }
.door:focus-visible { outline: 2px solid #fff; outline-offset: 2px; border-radius: 4px; }

/* 문 안쪽 */
.hole { position: absolute; inset: 0; border-radius: 2px; overflow: hidden; opacity: 0;
  background: radial-gradient(100% 90% at 50% 30%, #4a301d 0%, #2a1a10 60%, #170e08 100%); }
.hole::after { content: ''; position: absolute; inset: 0; box-shadow: inset 0 4px 10px rgba(0,0,0,.7), inset 0 0 0 1px rgba(0,0,0,.35); pointer-events: none; z-index: 3; }
.door.ready .hole, .door.lifting .hole, .door.torn .hole { opacity: 1; }
.thumb { position: absolute; inset: 0; opacity: 0; transition: opacity .5s var(--ease) .1s; }
.door.torn .thumb { opacity: 1; }
.thumb img, .thumb video { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.thumb .play { position: absolute; left: 6%; bottom: 6%; width: clamp(14px, 22cqmin, 24px); height: clamp(14px, 22cqmin, 24px); border-radius: 50%; background: rgba(0,0,0,.45); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); display: grid; place-items: center; z-index: 2; }
.thumb .play svg { width: 55%; height: 55%; fill: #fff; margin-left: 8%; }
.thumb .orn { position: absolute; inset: 14%; background: center / contain no-repeat; filter: drop-shadow(0 4px 6px rgba(0,0,0,.5)); }
.thumb::after { content: ''; position: absolute; inset: 0; background: radial-gradient(120% 120% at 50% 40%, transparent 55%, rgba(20,10,0,.45)); pointer-events: none; }
.hole-num { position: absolute; z-index: 4; right: 5%; bottom: 4%; font: 400 clamp(10px, 20cqmin, 22px)/1 var(--num); color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.8); opacity: 0; transition: opacity .3s .3s; }
.door.torn .hole-num { opacity: .95; }
.glow { position: absolute; inset: 0; z-index: 5; background: radial-gradient(60% 50% at 50% 50%, rgba(255,214,140,.85), rgba(255,180,90,.2) 55%, transparent 75%); opacity: var(--glow, 0); mix-blend-mode: screen; pointer-events: none; }

/* 뜯긴 가장자리 */
.rim { position: absolute; inset: -1px; pointer-events: none; display: none; z-index: 6; }
.door.torn .rim { display: block; }
.rim .fiber { position: absolute; inset: 0; background: #f4ecdb; }
.rim .print { position: absolute; inset: 0; background-image: var(--cover, url(/img/cover.jpg)); background-repeat: no-repeat; background-size: var(--bw) var(--bh); background-position: var(--bx) var(--by); filter: drop-shadow(0 1px 1px rgba(0,0,0,.45)); }

/* 문 */
.flap { position: absolute; inset: 0; z-index: 7; border-radius: 2px; will-change: transform;
  background-image: var(--cover, url(/img/cover.jpg)); background-repeat: no-repeat; background-size: var(--bw) var(--bh); background-position: var(--bx) var(--by);
  transform-origin: var(--ox, 50%) var(--oy, 50%); transition: transform .5s var(--ease); }
.door.dragging .flap { transition: none; }
.door.torn .flap { display: none; }
.flap::before { content: ''; position: absolute; inset: 0; border-radius: 2px;
  box-shadow: 0 0 0 .75px rgba(20,10,0,.55), inset 1px 1px 0 rgba(255,255,255,.28), inset -1px -1px 0 rgba(0,0,0,.25), 0 1px 0 .75px rgba(255,255,255,.12); }
.flap::after { content: ''; position: absolute; inset: 0; background: linear-gradient(var(--shade-dir, 180deg), rgba(0,0,0,0), rgba(0,0,0,.5)); opacity: var(--shade, 0); pointer-events: none; }
.door.lifting .flap { filter: drop-shadow(0 10px 12px rgba(0,0,0,.45)); }
/* 뜯을 수 있는 문: 귀퉁이가 접혀 안쪽이 살짝 보인다 */
.door.ready:not(.lifting) .flap { clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, 0 100%); }
.curl { position: absolute; right: 0; bottom: 0; width: var(--c); height: var(--c); z-index: 8; display: none; pointer-events: none;
  background: linear-gradient(to bottom right, #fbf4e4 0%, #f1e4c8 30%, #d8c29b 47%, transparent 50%);
  filter: drop-shadow(-1.5px -1.5px 2px rgba(40,20,0,.35)); }
.door.ready .hole { background: radial-gradient(70% 70% at 100% 100%, #f2b766 0%, #a8662c 35%, #3a2414 75%); }
.door.ready.lifting .hole { background: radial-gradient(100% 90% at 50% 30%, #4a301d 0%, #2a1a10 60%, #170e08 100%); }
.door.ready:not(.lifting) .curl { display: block; }
.door.ready.hinting .curl { animation: curl 1.1s var(--ease); transform-origin: 100% 100%; }
@keyframes curl { 35% { transform: scale(1.7); } }
.num { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -52%); font: 400 clamp(17px, 46cqmin, 64px)/1 var(--num); letter-spacing: -0.02em;
  background: var(--foil); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 1px 0 rgba(0,0,0,.55)) drop-shadow(0 0 6px rgba(0,0,0,.45)); pointer-events: none; }
.door[data-day="24"] .num, .door[data-day="25"] .num { font-size: clamp(22px, 52cqmin, 120px); }
.countdown { position: absolute; left: 50%; bottom: 6%; transform: translateX(-50%); font-size: clamp(9px, 14cqmin, 12px); font-weight: 600; background: rgba(15,27,29,.78);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); color: #fff; padding: 2px 7px; border-radius: 10px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.door.shake .flap { animation: shake .4s var(--ease); }
@keyframes shake { 20% { transform: translateX(-3px); } 45% { transform: translateX(3px); } 70% { transform: translateX(-2px); } }
.board.thump { animation: thump .3s var(--ease); }
@keyframes thump { 35% { transform: translateY(1.5px); } }

.v-foot { margin-top: 20px; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 0 24px; text-align: center; }
.v-hint { font-size: 14px; color: var(--w2); }
.v-from { font: 400 16px/1.5 var(--letter); color: var(--w2); }
.v-make { margin-top: 14px; font-size: 13px; color: var(--w3); padding: 8px; }

.flying { position: fixed; border-radius: 2px; background-repeat: no-repeat; will-change: transform, opacity; }
.flying::before { content: ''; position: absolute; inset: 0; box-shadow: inset 1px 1px 0 rgba(255,255,255,.28), inset -1px -1px 0 rgba(0,0,0,.25); }
.flying .back { position: absolute; inset: 0; background: #d9c29a var(--grain); backface-visibility: hidden; transform: rotateY(180deg); }
.bit { position: fixed; width: 5px; height: 4px; background: #f3ead6; border-radius: 1px; will-change: transform, opacity; }

/* ---------- 열린 칸 (시트) ---------- */
.sheet-back { position: fixed; inset: 0; background: rgba(0,0,0,.42); z-index: 60; opacity: 0; transition: opacity .35s var(--ease); }
.sheet-back.on { opacity: 1; }
.sheet { position: fixed; inset: 0; z-index: 61; display: flex; justify-content: center; align-items: flex-end; pointer-events: none; }
.card { pointer-events: auto; width: min(100%, 600px); max-height: calc(100svh - var(--safe-t) - 12px); display: flex; flex-direction: column;
  background: var(--paper) var(--grain); color: var(--ink); border-radius: 22px 22px 0 0;
  box-shadow: 0 -8px 40px rgba(0,0,0,.35); will-change: transform; touch-action: pan-y; }
.grab { width: 36px; height: 5px; border-radius: 3px; background: rgba(60,50,40,.22); margin: 8px auto 0; flex: none; }
.card-head { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; padding: 12px 16px 14px 20px; flex: none; cursor: grab; }
.card-day { font: 400 46px/.9 var(--num); color: var(--accent); min-width: 1.1em; }
.card-date b { display: block; font-size: 17px; font-weight: 600; letter-spacing: -0.02em; }
.card-date span { font-size: 14px; color: var(--ink3); }
.x { width: 30px; height: 30px; border-radius: 50%; border: 0; background: rgba(60,50,40,.1); color: var(--ink2); display: grid; place-items: center; }
.x svg { width: 13px; height: 13px; stroke-width: 2.6; }
.card-body { overflow-y: auto; padding: 2px 20px 8px; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; flex: 1; }
.card-nav { display: flex; justify-content: space-between; align-items: center; padding: 6px 8px calc(6px + var(--safe-b)); border-top: .5px solid var(--hair); flex: none; }
.navbtn { border: 0; background: none; color: var(--accent); font-size: 16px; font-weight: 500; padding: 10px 12px; display: inline-flex; align-items: center; gap: 2px; border-radius: 10px; }
.navbtn svg { width: 18px; height: 18px; stroke-width: 2.2; }
.navbtn[hidden] { display: inline-flex; visibility: hidden; }
.blk { margin: 0 0 20px; }
.blk-img img, .blk-video video { display: block; width: 100%; height: auto; border-radius: 14px; background: var(--fill); }
.blk-video video { max-height: 72svh; background: #000; }
.blk-img img { cursor: zoom-in; }
.cap { font-size: 13px; color: var(--ink3); margin-top: 8px; }
.cap a { color: var(--accent); }
.yt { position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: #000; }
.yt img { width: 100%; height: 100%; object-fit: cover; display: block; }
.yt button { position: absolute; inset: 0; border: 0; background: rgba(0,0,0,.12); display: grid; place-items: center; }
.yt button span { width: 56px; height: 56px; border-radius: 50%; background: rgba(255,255,255,.9); display: grid; place-items: center; box-shadow: 0 6px 20px rgba(0,0,0,.3); }
.yt button svg { width: 22px; height: 22px; fill: var(--ink); margin-left: 3px; }
.yt iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.blk-link a { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 14px; background: rgba(255,255,255,.75); border: .5px solid var(--hair); }
.blk-link .lt { width: 36px; height: 36px; border-radius: 10px; background: var(--fill); display: grid; place-items: center; color: var(--accent); flex: none; }
.blk-link .lt svg { width: 18px; height: 18px; }
.blk-link a span { flex: 1; min-width: 0; }
.blk-link a b { display: block; font-weight: 600; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.blk-link a small { color: var(--ink3); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.blk-link a > svg { width: 16px; height: 16px; color: var(--ink4); flex: none; }
.sign { font: 400 16px/1.5 var(--letter); color: var(--ink2); text-align: right; margin: -4px 0 16px; }
.empty-note { text-align: center; color: var(--ink3); padding: 8px 0 28px; font-size: 15px; }
.empty-note img { width: 96px; height: 96px; object-fit: contain; display: block; margin: 0 auto 8px; }
.zoom { position: fixed; inset: 0; z-index: 90; background: #000; display: grid; place-items: center; animation: fade .25s var(--ease); }
.zoom img { max-width: 100vw; max-height: 100svh; object-fit: contain; }
@keyframes fade { from { opacity: 0; } }

/* ---------- 묶음 목록 (편집·첫 화면 공통) ---------- */
.page { max-width: 640px; margin: 0 auto; padding: 0 0 calc(var(--safe-b) + 40px); }
.nav { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: calc(var(--safe-t) + 6px) 8px 6px;
  background: rgba(242,239,233,.82); -webkit-backdrop-filter: blur(20px) saturate(1.8); backdrop-filter: blur(20px) saturate(1.8); }
.nav a, .nav .navtxt { display: inline-flex; align-items: center; gap: 2px; color: var(--accent); font-size: 17px; padding: 8px; }
.nav a svg { width: 22px; height: 22px; stroke-width: 2.2; }
.save-state { font-size: 13px; color: var(--ink3); padding: 8px 10px; white-space: nowrap; }
.save-state.err { color: var(--accent); font-weight: 600; }
.large { font-size: 32px; line-height: 1.15; font-weight: 700; letter-spacing: -0.03em; margin: 4px 20px 22px; text-wrap: balance; }
.gh { font-size: 13px; color: var(--ink3); margin: 0 32px 7px; }
.gh.split { display: flex; justify-content: space-between; }
.group { background: var(--group); border-radius: 14px; margin: 0 16px 8px; overflow: hidden; }
.gf { font-size: 13px; color: var(--ink3); margin: 0 32px 30px; line-height: 1.45; }
.row { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 0 16px; position: relative; }
.row + .row::before { content: ''; position: absolute; top: 0; left: 16px; right: 0; border-top: .5px solid var(--hair); }
.row > label, .row > .lbl { font-size: 17px; width: 88px; flex: none; }
.row input { flex: 1; min-width: 0; border: 0; background: transparent; font-size: 17px; outline: none; padding: 12px 0; color: var(--ink); }
.row input::placeholder { color: var(--ink4); }
.row .chev { width: 16px; height: 16px; color: var(--ink4); stroke-width: 2.4; }
.row.link { justify-content: space-between; font-size: 17px; }
.row.link small { color: var(--ink3); font-size: 15px; }
.btn { display: flex; align-items: center; justify-content: center; gap: 8px; height: 50px; padding: 0 20px; border: 0; border-radius: 14px; font-size: 17px; font-weight: 600; background: var(--accent); color: #fff; width: 100%; }
.btn:active { background: var(--accent-press); }
.btn svg { width: 19px; height: 19px; stroke-width: 2.1; }
.btn.tint { background: rgba(118,104,84,.1); color: var(--ink); font-weight: 500; height: 44px; font-size: 16px; }
.btn:disabled { opacity: .45; }
.share { padding: 16px; display: grid; gap: 10px; }
.share .url { font-size: 15px; color: var(--ink3); text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 2px 8px 4px; }
.share .two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }


/* 하루 편집 시트 */
.de-back { position: fixed; inset: 0; background: rgba(0,0,0,.32); z-index: 60; animation: fade .3s var(--ease); }
.de { position: fixed; z-index: 61; left: 0; right: 0; bottom: 0; top: calc(var(--safe-t) + 10px); max-width: 640px; margin: 0 auto; display: flex; flex-direction: column;
  background: var(--canvas); color: var(--ink); border-radius: 14px 14px 0 0; box-shadow: 0 -6px 30px rgba(0,0,0,.2); will-change: transform; }
.de.enter { animation: up .45s var(--ease); }
@keyframes up { from { transform: translateY(100%); } }
.de-head { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 4px 8px 8px; flex: none; touch-action: none; }
.de-head .grab { grid-column: 1 / -1; margin: 4px auto 6px; }
.de-title { display: flex; align-items: center; gap: 2px; }
.de-title div { text-align: center; min-width: 120px; }
.de-title b { display: block; font-size: 17px; font-weight: 600; }
.de-title small { font-size: 12px; color: var(--ink3); }
.chevbtn { width: 36px; height: 36px; border: 0; background: none; color: var(--accent); display: grid; place-items: center; border-radius: 50%; }
.chevbtn svg { width: 20px; height: 20px; stroke-width: 2.3; }
.chevbtn:disabled { color: var(--ink4); }
.done { justify-self: end; border: 0; background: none; color: var(--accent); font-size: 17px; font-weight: 600; padding: 8px 10px; }
.de-body { overflow-y: auto; padding: 4px 16px 24px; flex: 1; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
@keyframes pop { from { opacity: 0; transform: translateY(8px); } }
.upl { padding: 22px 16px 18px; }
.upl .bar { height: 4px; border-radius: 2px; background: var(--fill); overflow: hidden; }
.upl .bar i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .25s var(--ease); }
.upl .t { font-size: 13px; color: var(--ink3); text-align: center; margin-top: 10px; font-variant-numeric: tabular-nums; }
.tools { display: grid; grid-template-columns: repeat(5, 1fr); padding: 6px 6px calc(var(--safe-b) + 6px); flex: none;
  background: rgba(255,253,249,.9); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); border-top: .5px solid var(--hair); }
.tools button { border: 0; background: none; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 0; font-size: 11px; color: var(--ink2); border-radius: 10px; }
.tools button svg { width: 24px; height: 24px; color: var(--accent); stroke-width: 1.7; }

/* ---------- 첫 화면 ---------- */
.home { padding-bottom: calc(var(--safe-b) + 40px); max-width: 520px; margin: 0 auto; }
.stage { padding: calc(var(--safe-t) + 40px) 0 8px; display: flex; justify-content: center; perspective: 900px; }
.cal { width: 168px; aspect-ratio: 2 / 3; border-radius: 6px; position: relative; z-index: 1; background: center / cover;
  box-shadow: 0 0 0 1px rgba(0,0,0,.5), 0 40px 60px -24px rgba(0,0,0,.9), 0 16px 24px -10px rgba(0,0,0,.6);
  transform: rotateX(var(--rx, 8deg)) rotateY(var(--ry, -10deg)); transition: transform .9s var(--ease); transform-style: preserve-3d; }
.cal::after { content: ''; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(calc(120deg + var(--ry, -10deg) * 3), rgba(255,255,255,.18), transparent 45%, rgba(0,0,0,.2)); }
.cal .d { position: absolute; left: 39%; top: 37%; width: 22%; height: 15%; border-radius: 1px; background: radial-gradient(#5a3a22, #1f140b); box-shadow: inset 0 2px 5px rgba(0,0,0,.7); }
.cal .d::before { content: ''; position: absolute; inset: 10% 12%; background: url(/img/assets/orn-bauble.png) center / contain no-repeat; }
.cal .d::after { content: ''; position: absolute; inset: -2px; border: 1px dashed rgba(255,250,238,.7); clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); }
.home h1 { font-size: 30px; line-height: 1.22; font-weight: 700; letter-spacing: -0.03em; text-align: center; margin: 28px 24px 10px; text-wrap: balance; }
.home .lede { font-size: 16px; line-height: 1.55; color: var(--w2); text-align: center; margin: 0 32px 32px; text-wrap: balance; }
.dark .group { background: #1d2a2c; }
.dark .row + .row::before { border-color: var(--whair); }
.dark .row input { color: var(--w1); }
.dark .row input::placeholder { color: var(--w3); }
.dark .gh, .dark .gf { color: var(--w3); }
.dark .row.link small, .dark .row .chev { color: var(--w3); }
.cta { margin: 16px 16px 12px; width: calc(100% - 32px); }
.demo-link { display: flex; align-items: center; justify-content: center; gap: 4px; width: fit-content; min-height: 44px; margin: 0 auto 28px; padding: 0 16px; color: rgba(255,255,255,.62); font-size: 15px; font-weight: 500; }
.demo-link::after { content: '›'; font-size: 20px; line-height: 1; margin-top: -2px; }
.demo-link:active { color: rgba(255,255,255,.9); }

@media (prefers-reduced-motion: reduce) {
  .cal { transition: none; }
  .door.ready.hinting .curl { animation: none; }
}


.card-head, .grab { touch-action: none; }

/* 배경 고르기 */
.themes { display: flex; gap: 12px; overflow-x: auto; padding: 16px; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.themes::-webkit-scrollbar { display: none; }
.th { flex: none; width: 88px; border: 0; background: none; padding: 0; text-align: center; scroll-snap-align: start; scroll-margin-left: 16px; color: var(--ink2); font-size: 13px; }
.th i { display: block; position: relative; aspect-ratio: 2 / 3; border-radius: 8px; background: var(--fill) center / cover; margin-bottom: 8px;
  box-shadow: 0 0 0 .5px rgba(0,0,0,.12), 0 4px 10px -2px rgba(0,0,0,.18); transition: box-shadow .25s var(--ease); }
.th.on { color: var(--ink); font-weight: 600; }
.th.on i { box-shadow: 0 0 0 2.5px var(--group), 0 0 0 4.5px var(--accent), 0 6px 14px -2px rgba(0,0,0,.25); }
.th.on i::after { content: ''; position: absolute; right: 6px; bottom: 6px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 12px no-repeat; box-shadow: 0 0 0 2px #fff; }
/* 첫 화면 부채꼴 */
.stage { position: relative; }
.cal.side { position: absolute; top: calc(var(--safe-t) + 58px); left: 50%; width: 136px; margin-left: -68px; opacity: .9; transition: none; }
.cal.side.l { transform: translateX(-92px) rotate(-11deg); }
.cal.side.r { transform: translateX(92px) rotate(11deg); }
.cal.side::after { background: rgba(0,0,0,.18); }

/* 숫자가 어느 그림 위에서도 읽히도록 */
.plate { position: absolute; left: 50%; top: 50%; width: 78cqmin; height: 64cqmin; transform: translate(-50%, -50%); border-radius: 50%;
  background: radial-gradient(closest-side, rgba(12,8,4,.55), rgba(12,8,4,.28) 55%, transparent); pointer-events: none; }
.door[data-day="25"] .plate, .door[data-day="24"] .plate { width: 70cqmin; height: 56cqmin; }
.theme-midnight .plate { background: radial-gradient(closest-side, rgba(8,14,40,.6), transparent); }

/* v4: 손가락 홈과 깨끗한 칼선 */
.curl, .rim { display: none !important; }
.door { --n: clamp(5px, 11cqmin, 10px); }
.door.ready:not(.lifting) .flap { clip-path: none;
  -webkit-mask: radial-gradient(circle at 100% 50%, transparent var(--n), #000 calc(var(--n) + .6px));
  mask: radial-gradient(circle at 100% 50%, transparent var(--n), #000 calc(var(--n) + .6px)); }
.door.ready .hole { background: radial-gradient(calc(var(--n) * 3) calc(var(--n) * 3) at 100% 50%, #ffd48a 0%, #c9803a 40%, #3a2414 100%); }
.door.ready.lifting .hole, .door.torn .hole { background: radial-gradient(100% 90% at 50% 30%, #4a301d 0%, #2a1a10 60%, #170e08 100%); }
.hole::after { box-shadow: inset 0 0 0 1.25px rgba(236,224,200,.9), inset 2px 3px 0 1.25px rgba(0,0,0,.35), inset 0 6px 12px rgba(0,0,0,.6); border-radius: 2px; }
.door.ready .hole::after { box-shadow: none; }
.door.ready.hinting .flap { animation: nudge .9s var(--ease); transform-origin: 0 50%; }
@keyframes nudge { 40% { transform: perspective(500px) rotateY(-16deg); } }
.flying::before { box-shadow: inset 0 0 0 .75px rgba(20,10,0,.5), inset 1px 1px 0 rgba(255,255,255,.28); }
.hole::after { box-shadow: inset 0 0 0 1px rgba(236,224,200,.45), inset 0 5px 9px rgba(0,0,0,.65), inset 0 -1px 0 rgba(255,255,255,.08); }
.door.torn { filter: drop-shadow(0 -1px 0 rgba(0,0,0,.25)); }

/* v5: 가운데에 뜨는 카드 */
.viewer { transition: transform .5s var(--ease), filter .5s var(--ease); }
.viewer.behind { transform: scale(.94); filter: brightness(.7) saturate(.9); }
.sheet-back { background: rgba(5,8,10,.45); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.sheet { align-items: center; padding: calc(var(--safe-t) + 16px) 18px calc(var(--safe-b) + 16px); }
.card { position: relative; width: min(100%, 440px); max-height: min(82svh, 760px); border-radius: 22px; overflow: hidden;
  box-shadow: 0 0 0 .5px rgba(0,0,0,.2), 0 30px 80px -10px rgba(0,0,0,.6), 0 10px 24px -6px rgba(0,0,0,.4); transform-origin: 50% 50%; }
.grab { display: none; }
.lid { position: relative; flex: none; height: 132px; display: flex; align-items: flex-end; gap: 14px; padding: 16px 18px; background-color: #2a1a10; color: #fff; touch-action: none; cursor: grab; }
.lid::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.05) 20%, rgba(0,0,0,.62)); }
.lid > * { position: relative; }
.lid-num { flex: none; text-align: center; font: 400 58px/.8 var(--num); background: var(--foil); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 2px 2px rgba(0,0,0,.6)); padding-top: 6px; }
.lid-date { flex: 1; min-width: 0; margin-left: 4px; padding-bottom: 2px; }
.lid-date b { display: block; font-size: 17px; font-weight: 600; letter-spacing: -0.02em; text-shadow: 0 1px 3px rgba(0,0,0,.5); }
.lid-date span { font-size: 13px; color: rgba(255,255,255,.75); }
.lid .x { position: absolute; top: 12px; right: 12px; background: rgba(0,0,0,.35); color: #fff; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.card-body { padding: 20px 20px 6px; }
.card-nav { padding: 4px 6px calc(4px); }
.dots { overflow: hidden; flex: none; }
.dots-track { display: flex; transition: transform .28s var(--ease, ease); }
.dots i { flex: none; width: 11px; height: 8px; position: relative; }
.dots i::before { content: ''; position: absolute; left: 50%; top: 50%; width: 5px; height: 5px; margin: -2.5px 0 0 -2.5px; border-radius: 50%; background: rgba(60,50,40,.22); transition: all .2s; }
.dots i.md::before { width: 4px; height: 4px; margin: -2px 0 0 -2px; }
.dots i.sm::before { width: 3px; height: 3px; margin: -1.5px 0 0 -1.5px; }
.dots i.on::before { background: var(--accent); width: 5px; height: 5px; margin: -2.5px 0 0 -2.5px; }
@media (prefers-reduced-motion: reduce) { .viewer.behind { transform: none; } }

/* v6: 문 모양 */
.door[data-shape="arch"] { --rad: 50% 50% 3px 3px / 32% 32% 3px 3px; }
.door[data-shape="round"] { --rad: 50%; }
.door .flap, .door .hole, .door .hole::after, .door .flap::before, .door .flap::after { border-radius: var(--rad, 2px); }
.door[data-shape="round"] .plate { width: 70cqmin; height: 60cqmin; }
.board { transition: transform .6s var(--ease); transform-style: preserve-3d; }

/* 금박 위로 빛이 지나간다 */
.num { display: block; }
.num::after { content: attr(data-n); position: absolute; inset: 0; padding-top: inherit;
  background: linear-gradient(105deg, transparent 38%, rgba(255,255,255,.95) 50%, transparent 62%) 160% 0 / 260% 100% no-repeat;
  -webkit-background-clip: text; background-clip: text; color: transparent; pointer-events: none; }
.board.shine-in .num::after { animation: foil 1.1s var(--ease) both; animation-delay: calc(var(--i) * 90ms + 300ms); }
.door.today .num::after, .door.unlocking .num::after { animation: foil 1.2s var(--ease) both; }
.door.today.ready .num::after { animation: foil 1.4s var(--ease) 2s infinite; animation-duration: 1.4s; }
@keyframes foil { from { background-position: 160% 0; } to { background-position: -60% 0; } }

/* 오늘 문: 홈 사이로 불빛이 숨 쉬듯 */
.door.today.ready .hole { animation: ember 2.8s ease-in-out infinite; }
@keyframes ember { 50% { filter: brightness(1.45) saturate(1.2); } }
.door.today.ready .flap { filter: drop-shadow(0 0 6px rgba(255,200,110,.55)); }

/* 기다리는 문이 살짝 들썩 */
.door.ready.hinting .flap { animation: nudge 1s var(--ease); transform-origin: 0 50%; }
@keyframes nudge { 35% { transform: perspective(500px) rotateY(-14deg); } 60% { transform: perspective(500px) rotateY(-4deg); } }

/* 잠긴 문 누름 */
.door.locked:active .flap { transform: scale(.96); transition-duration: .12s; }

/* 0시에 풀리는 순간 */
.door.unlocking .flap { animation: unlock 1s cubic-bezier(.2,1.6,.4,1); }
@keyframes unlock { 0% { transform: scale(1); } 30% { transform: scale(1.12) rotate(-2deg); } 55% { transform: scale(.98) rotate(1deg); } 100% { transform: none; } }
.spark { position: fixed; width: 4px; height: 4px; border-radius: 50%; background: #fff6d8; box-shadow: 0 0 8px 2px rgba(255,210,120,.9); pointer-events: none; z-index: 55; }

/* 카드가 구멍으로 돌아왔을 때 */
.door.settle .thumb { animation: settle .5s var(--ease); }
@keyframes settle { 0% { transform: scale(1.12); filter: brightness(1.5); } 100% { transform: none; } }

@media (prefers-reduced-motion: reduce) { .door.today.ready .hole, .door.today.ready .num::after { animation: none; } }

/* 편집: 문 배치 미리보기 */
/* v7: 영상·사진을 원래 비율대로, 좌우 검은 띠 없이 */
.blk-video, .blk-img { display: flex; flex-direction: column; align-items: center; }
.blk-video video, .blk-img img { width: auto; height: auto; max-width: 100%; max-height: 64svh; background: transparent; border-radius: 14px; }
.blk-video video:not([data-ready]) { width: 100%; aspect-ratio: 9 / 16; max-height: 64svh; background: var(--fill); }
/* 세로 영상이 카드 높이를 넘지 않게: 카드 최대 높이에서 머리·넘기기 줄·여백을 뺀 만큼까지, 비율은 그대로 */
.blk-video video { max-height: min(64svh, calc(82svh - 300px)); touch-action: pan-y; }
.blk-video video:not([data-ready]) { max-height: min(64svh, calc(82svh - 300px)); }
.yt-note:empty { display: none; }



/* ---------- 속지(편지지): 받는 화면과 편집 화면이 같은 규칙을 쓴다 ---------- */
:root { --hand: 'Gaegu', 'Gowun Batang', 'AppleMyungjo', serif; }
.paper { --pb: #f8ebd4; --pk: #493426; --pt: 12; --pi: none; --pis: none;
  position: relative; container-type: inline-size; color: var(--pk); border-radius: 3px; background: var(--pb);
  box-shadow: 0 0 0 .5px rgba(0,0,0,.14), 0 1px 3px rgba(60,40,20,.14); }
/* 종이 그림은 ::before에 깐다 (cqw가 이 종이의 너비를 따르도록). 그림 아래 끝은 base 색으로 이어 붙인다 */
.paper::before { content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(transparent, var(--pb)) 0 124cqw / 100% 16cqw no-repeat, var(--pi) center top / 100% auto no-repeat; }
.paper.sm::before { background: var(--pis) center top / 100% auto no-repeat; }
/* 줄노트: 글줄이 괘선 위에 앉도록 줄 간격을 괘선 두 칸에 맞추고, 그림이 끝난 뒤에도 괘선을 이어 그린다 */
.paper[data-paper="lined"]:not(.sm)::before { background-image: var(--pi), linear-gradient(rgba(146,149,180,.8) 0 max(1px, .22cqw), transparent 0), linear-gradient(90deg, transparent 4.55cqw, rgba(221,153,140,.9) 4.55cqw 4.85cqw, transparent 4.85cqw);
  background-size: 100% auto, 100% 4.397cqw, 100% 100%; background-position: center top, 0 12.8cqw, 0 0; background-repeat: no-repeat, repeat-y, no-repeat; }
.paper[data-paper="lined"] .paper-in { padding-top: 20.1cqw; }
.paper[data-paper="lined"] .letter, .paper[data-paper="lined"] textarea { font-size: clamp(18px, 6.8cqw, 27px); line-height: 8.794cqw; }
.paper[data-paper="lined"] .sign { margin-top: 8.794cqw; font-size: clamp(18px, 6.8cqw, 27px); line-height: 8.794cqw; }
.paper-in { position: relative; padding: calc(var(--pt) * 1.4cqw) 9cqw 10cqw; }
.letter, .paper textarea { font: 400 clamp(21px, 7.4cqw, 29px)/1.62 var(--hand); letter-spacing: -0.012em; overflow-wrap: break-word; word-break: keep-all; }
.letter { white-space: pre-wrap; }
.letter.short, .paper textarea.short { font-size: clamp(25px, 8.8cqw, 35px); line-height: 1.5; }
.paper .sign { margin: 1.1em 0 0; font: 400 clamp(21px, 7.4cqw, 29px)/1.4 var(--hand); letter-spacing: -0.012em; color: var(--pk); opacity: .85; text-align: right; }
/* 높이는 내용에 맞춘다. 짧은 쪽지도 엽서만큼(220px)은 되어 장식이 잘리지 않고, 긴 편지는 길어진다 */
.blk-text.paper, .eb-paper { max-width: 400px; margin-left: auto; margin-right: auto; }
.blk-text .paper-in, .eb-paper .paper-in { min-height: max(220px, 62cqw); }
.blk-text.paper { margin-bottom: 20px; }
.paper textarea { display: block; width: 100%; min-height: 1.7em; margin: 0; padding: 0; border: 0; border-radius: 0; resize: none; overflow: hidden; outline: none; background: transparent; color: var(--pk); caret-color: var(--pk); }
.paper textarea::placeholder { color: var(--pk); opacity: .38; }

/* 판 위 쪽지 */
.thumb .note, .ed-door .note { position: absolute; inset: 9% 8% 12% 9%; transform: rotate(-2.5deg); overflow: hidden; border-radius: 2px; text-align: left; box-shadow: 0 2px 6px rgba(0,0,0,.45); }
.note .note-in { position: relative; z-index: 1; padding: calc(var(--pt) * 1.4cqw) 10cqw 0; font: 400 max(7px, 15cqw)/1.45 var(--hand); }
.note.paper::after { content: ''; z-index: 2; position: absolute; left: 0; right: 0; bottom: 0; height: 40%; background: linear-gradient(transparent, var(--pb)); }
.thumb .note.link, .ed-door .note.link { display: grid; place-items: center; background: #fbf7ee; color: var(--ink2); }
.thumb .note.link svg, .ed-door .note.link svg { width: 38%; height: auto; color: var(--accent); }
.thumb .note.link { font-family: var(--ui); font-weight: 600; text-align: center; }
.thumb .note.link svg { display: block; margin: 0 auto 6%; }

/* ---------- 편집: 위쪽과 판 ---------- */
.nav-r { display: flex; align-items: center; gap: 2px; }
.nav .nav-pv { font-size: 17px; font-weight: 500; }
.nav .nav-pv svg { width: 21px; height: 21px; stroke-width: 1.9; margin-right: 3px; }
.page.ed { padding-bottom: calc(var(--safe-b) + 112px); }
.title-input { display: block; width: calc(100% - 40px); margin: 6px 20px 14px; padding: 4px 0; border: 0; border-radius: 0; background: transparent; outline: none; color: var(--ink); text-overflow: ellipsis;
  font: 700 30px/1.15 var(--ui); letter-spacing: -0.03em; }
.title-input::placeholder { color: var(--ink4); }
.ed .group { margin-bottom: 16px; }
.ed .group > .row { min-height: 46px; }
.prog { margin: 4px 20px 14px; }
.prog-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 8px; font-size: 15px; color: var(--ink2); font-variant-numeric: tabular-nums; }
.prog-num b { color: var(--ink); font-weight: 650; }
.prog-hint { border: 0; background: none; padding: 4px 0; color: var(--accent); font-size: 14px; font-weight: 500; }
.prog-hint.plain { color: var(--ink3); font-weight: 400; }
.prog .bar { height: 4px; border-radius: 2px; background: rgba(60,50,40,.12); overflow: hidden; }
.prog .bar i { display: block; height: 100%; width: 0; border-radius: 2px; background: var(--accent); transition: width .6s var(--ease); }
.board-wrap { display: flex; justify-content: center; padding: 0 16px; margin: 0 0 28px; }
.ed-board { position: relative; width: min(100%, 430px); aspect-ratio: 2 / 3; padding: 3.4%; border-radius: 6px; display: grid; grid-template-columns: repeat(5, 1fr); grid-template-rows: repeat(6, 1fr); gap: 2.4%;
  background: #20343a var(--cover, url(/img/cover.jpg)) center / 100% 100% no-repeat; box-shadow: 0 0 0 .5px rgba(0,0,0,.3), 0 16px 30px -18px rgba(30,20,10,.6); user-select: none; -webkit-user-select: none; }
.ed-door { --rad: 2px; position: relative; container-type: size; display: block; border: 0; padding: 0; margin: 0; border-radius: var(--rad); background: none; outline: none; touch-action: manipulation; }
.ed-door[data-shape="arch"] { --rad: 50% 50% 3px 3px / 32% 32% 3px 3px; }
.ed-door[data-shape="round"] { --rad: 50%; }
.ed-door:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.ed-door.empty { background: var(--cover) no-repeat; background-size: var(--bw) var(--bh); background-position: var(--bx) var(--by); }
.ed-door.empty::before { content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  box-shadow: 0 0 0 .75px rgba(20,10,0,.55), inset 1px 1px 0 rgba(255,255,255,.28), inset -1px -1px 0 rgba(0,0,0,.25); }
.ed-door.full { overflow: hidden; background: radial-gradient(100% 90% at 50% 30%, #4a301d 0%, #2a1a10 60%, #170e08 100%); }
.ed-door.full::after { content: ''; position: absolute; inset: 0; z-index: 3; border-radius: inherit; pointer-events: none; box-shadow: inset 0 3px 8px rgba(0,0,0,.6), inset 0 0 0 1px rgba(0,0,0,.35); }
.ed-door img, .ed-door video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.ed-door .num { pointer-events: none; }
.ed-door[data-day="25"] .num { font-size: clamp(22px, 52cqmin, 120px); }
.ed-door .dn { position: absolute; z-index: 4; right: 6%; bottom: 4%; font: 400 clamp(10px, 20cqmin, 18px)/1 var(--num); color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.85); }
.ed-door .badge { position: absolute; left: 6%; bottom: 6%; z-index: 4; width: clamp(14px, 24cqmin, 22px); height: clamp(14px, 24cqmin, 22px); border-radius: 50%; background: rgba(0,0,0,.45); display: grid; place-items: center; }
.ed-door .badge svg { width: 55%; height: 55%; fill: #fff; margin-left: 8%; }
.ed-door .count { position: absolute; right: 6%; top: 5%; z-index: 4; font-size: 10px; font-weight: 600; color: #fff; background: rgba(0,0,0,.45); border-radius: 8px; padding: 1px 5px; }
.ed-board.deal .ed-door { animation: deal .45s cubic-bezier(.2,1.4,.4,1) both; animation-delay: calc(var(--i) * 12ms); }
@keyframes deal { from { transform: scale(.5); opacity: 0; } }

/* 꾸미기·설정 */
.row.link { width: 100%; border: 0; background: none; text-align: left; justify-content: space-between; }
.row.link span { min-width: 0; }
.row.link:active { background: rgba(118,104,84,.08); }
.theme-wrap + .row.link::before, .theme-acts .row.link::before, .row.pw-edit::before { content: ''; position: absolute; top: 0; left: 16px; right: 0; border-top: .5px solid var(--hair); }
.row.url span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pw-head { justify-content: space-between; }
.pw-head .lbl { width: auto; flex: 1; }
.pw-stat { font-size: 15px; color: var(--ink3); }
.pw-stat.on { color: var(--ink2); }
.pw-val { font-size: 17px; color: var(--ink2); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pw-act { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; padding: 6px 16px 16px; }
.sw { position: relative; flex: none; width: 51px; height: 31px; padding: 0; border: 0; border-radius: 16px; background: rgba(120,120,128,.26); transition: background .25s var(--ease); }
.sw i { position: absolute; left: 2px; top: 2px; width: 27px; height: 27px; border-radius: 50%; background: #fff; box-shadow: 0 2px 4px rgba(0,0,0,.2); transition: transform .25s var(--ease); }
.sw.on { background: #34c759; }
.sw.on i { transform: translateX(20px); }

/* 아래 고정 보내기 줄 */
.sendbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 10px 16px calc(var(--safe-b) + 10px); background: rgba(242,239,233,.94); border-top: .5px solid var(--hair);
  -webkit-backdrop-filter: blur(20px) saturate(1.8); backdrop-filter: blur(20px) saturate(1.8); }
.sendbar > * { max-width: 608px; margin-left: auto; margin-right: auto; }
.send-hint { font-size: 12px; color: var(--ink3); text-align: center; margin-bottom: 6px; }
.send-hint[hidden] { display: none; }
.btn.send.weak { background: #e3ddd1; color: var(--ink); }
.btn.send.weak:active { background: #d9d2c4; }

/* ---------- 하루 편집 ---------- */
.de-head .grab { display: block; width: 36px; height: 5px; border-radius: 3px; background: rgba(60,50,40,.22); margin: 4px auto 6px; }
.de-head .save-state { justify-self: start; padding: 8px; font-size: 13px; }
.de-body { padding-top: 6px; }
.de-empty { padding: 26px 8px 18px; }
.de-empty h2 { margin: 0 0 6px; font-size: 24px; line-height: 1.2; font-weight: 700; letter-spacing: -0.03em; text-wrap: balance; }
.de-empty p { margin: 0; font-size: 15px; color: var(--ink3); }
.choices { margin: 0 0 8px; }
.choice { width: 100%; min-height: 64px; padding: 10px 16px; gap: 14px; border: 0; background: none; text-align: left; }
.choice > svg:first-child { width: 27px; height: 27px; flex: none; color: var(--accent); stroke-width: 1.6; }
.choice .ct { flex: 1; min-width: 0; }
.choice .ct b { display: block; font-size: 17px; font-weight: 600; }
.choice .ct small { display: block; margin-top: 1px; font-size: 13px; color: var(--ink3); }
.eb { margin-bottom: 22px; animation: pop .35s var(--ease); }
.eb-head { display: flex; align-items: center; justify-content: space-between; padding: 0 2px 6px 6px; }
.eb-head .kind { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 500; color: var(--ink3); }
.eb-head .kind svg { width: 16px; height: 16px; }
.eb-head .acts { display: flex; }
.eb-head .acts button { width: 36px; height: 30px; border: 0; border-radius: 8px; background: none; color: var(--ink3); display: grid; place-items: center; }
.eb-head .acts svg { width: 18px; height: 18px; }
.eb-head .acts button:disabled { opacity: .3; }
.eb-head .acts button.del { color: var(--accent); }
.eb-card { background: var(--group); border-radius: 14px; overflow: hidden; }
.eb-card .field { display: block; width: 100%; padding: 13px 16px; border: 0; border-top: .5px solid var(--hair); border-radius: 0; background: transparent; outline: none; color: var(--ink); font-size: 16px; }
.eb-card .field:first-child { border-top: 0; }
.eb-card .field::placeholder { color: var(--ink4); }
.eb-card .media { background: var(--fill); display: flex; justify-content: center; }
.eb-card .media img, .eb-card .media video { display: block; width: auto; max-width: 100%; max-height: 320px; object-fit: contain; }
.eb-card .ytprev { aspect-ratio: 16 / 9; background: #000 center / cover; }
.yt-note { padding: 0 16px 11px; font-size: 12px; color: var(--ink3); }
.yt-note.ok { color: #2f7d4f; }
.yt-note.bad { color: var(--accent); }
.upl { padding: 22px 16px 18px; }
.papers { position: relative; display: flex; gap: 12px; overflow-x: auto; margin: 0 -16px; padding: 4px 16px 14px; scroll-snap-type: x proximity; scroll-padding-left: 16px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.papers::-webkit-scrollbar { display: none; }
.pp { position: relative; flex: none; width: 58px; padding: 0; border: 0; background: none; display: grid; justify-items: center; gap: 8px; font-size: 11px; color: var(--ink3); scroll-snap-align: start; }
.pp i { display: block; width: 100%; aspect-ratio: 5 / 7; border-radius: 6px; background: var(--pb) var(--pis) center top / 100% auto no-repeat; box-shadow: 0 0 0 .5px rgba(0,0,0,.2); transition: box-shadow .2s var(--ease); }
.pp.on i { box-shadow: 0 0 0 2px var(--canvas), 0 0 0 4px var(--accent); }
.pp.on { color: var(--ink); font-weight: 600; }
.pp .tick { position: absolute; right: -4px; top: 66px; width: 20px; height: 20px; padding: 4px; border-radius: 50%; background: var(--accent); color: #fff; stroke-width: 3; box-shadow: 0 0 0 2px var(--canvas); }
.undo { position: absolute; left: 16px; right: 16px; bottom: calc(var(--safe-b) + 78px); z-index: 3; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 8px 8px 16px; border-radius: 14px;
  background: rgba(28,28,30,.92); color: #fff; font-size: 14px; animation: pop .3s var(--ease); }
.undo[hidden], .tools[hidden] { display: none; }
.undo button { border: 0; background: none; color: #ffb4a8; font-size: 14px; font-weight: 600; padding: 6px 10px; }

/* ---------- 비밀번호 잠금 화면 ---------- */
.lock { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; padding: calc(var(--safe-t) + 24px) 24px calc(var(--safe-b) + 24px); background: var(--night); color: var(--w1); overflow: hidden;
  transition: opacity .7s var(--ease), transform .7s var(--ease), filter .7s var(--ease); }
.lk-bg { position: absolute; inset: -30px; background: center / cover no-repeat; filter: blur(26px) brightness(.45) saturate(1.1); transform: scale(1.05); }
.lk-box { position: relative; width: min(100%, 340px); display: flex; flex-direction: column; align-items: center; text-align: center; }
.lk-seal { width: 76px; height: 76px; margin-bottom: 20px; border-radius: 22px; display: grid; place-items: center; color: var(--w1); background: rgba(255,255,255,.1); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.28);
  -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); transition: transform .5s var(--ease); }
.lk-seal svg { width: 36px; height: 36px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
.lk-seal .shackle { transform-origin: 16px 10.5px; transition: transform .5s var(--ease); }
.lk-seal.open { transform: scale(1.06); }
.lk-seal.open .shackle { transform: translateY(-1px) rotate(28deg); }
.lk-cal { max-width: 100%; margin-bottom: 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; color: var(--w3); }
.lk-h { margin: 0 0 8px; font-size: 26px; line-height: 1.2; font-weight: 700; letter-spacing: -0.03em; }
.lk-sub { margin: 0 0 26px; font-size: 15px; line-height: 1.5; color: var(--w2); text-wrap: balance; }
.lk-sub b { color: var(--w1); font-weight: 600; }
.lk-form { width: 100%; display: grid; gap: 10px; }
.lk-field { position: relative; }
.lk-input { display: block; width: 100%; height: 60px; padding: 0 52px; border: 0; border-radius: 16px; outline: none; text-align: center; font-size: 22px; font-weight: 500; letter-spacing: .02em; color: var(--w1);
  background: rgba(255,255,255,.12); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.22); -webkit-text-security: disc; transition: background .2s var(--ease), box-shadow .2s var(--ease); }
.lk-input.show { -webkit-text-security: none; }
.lk-input::placeholder { color: var(--w3); font-weight: 400; }
.lk-input:focus { background: rgba(255,255,255,.16); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.55); }
.lk-eye { position: absolute; right: 8px; top: 8px; width: 44px; height: 44px; border: 0; border-radius: 50%; background: none; color: var(--w3); display: grid; place-items: center; }
.lk-eye[aria-pressed="true"] { color: var(--w1); }
.lk-eye svg { width: 20px; height: 20px; }
.lk-msg { min-height: 20px; font-size: 14px; color: #ffb4a8; }
.lk-go { height: 52px; border: 0; border-radius: 14px; background: rgba(255,255,255,.92); color: #1b2426; font-size: 17px; font-weight: 600; }
.lk-go:disabled { opacity: .35; }
.lock.leave { opacity: 0; transform: scale(1.04); filter: blur(8px); pointer-events: none; }
.viewer.arrive { animation: arrive .9s var(--ease) both; }
@keyframes arrive { from { opacity: 0; transform: scale(.96) translateY(10px); } }
@media (prefers-reduced-motion: reduce) { .viewer.arrive, .ed-board.deal .ed-door { animation: none; } .lock { transition: none; } }














/* 내 사진 배경 */
.th.mine i { display: grid; place-items: center; color: var(--ink2); background-color: var(--fill); background-size: cover; background-repeat: no-repeat; background-position: center; }
.th.mine i svg { width: 26px; height: 26px; }
.th.mine:disabled { opacity: .65; }
.ed-board.adjusting { touch-action: none; }
.adj { position: absolute; inset: 0; z-index: 20; border-radius: inherit; cursor: grab; touch-action: none; box-shadow: inset 0 0 0 2px rgba(255,255,255,.92); }
.adj.grab { cursor: grabbing; }
.adj-bar { position: absolute; left: 10px; right: 10px; bottom: 10px; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 7px 7px 14px; border-radius: 14px; background: rgba(28,28,30,.74); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); color: #fff; font-size: 14px; }
.adj-done { border: 0; background: #fff; color: #1c1c1e; font: 600 14px/1 var(--sans, inherit); padding: 8px 14px; border-radius: 10px; }

/* 만드는 사람 돕기: 아이디어, 문장 시작, 추천 영상 */
.idea-link { display: inline-flex; align-items: center; gap: 2px; margin: 10px 0 0; padding: 4px 0; border: 0; background: none; color: var(--accent); font-size: 14px; font-weight: 500; }
.idea-link svg { width: 14px; height: 14px; stroke-width: 2.4; }
.de-idea { margin: 10px 0 8px !important; font-size: 15px !important; line-height: 1.5; color: var(--ink2) !important; }
.de-idea b { font-weight: 600; color: var(--ink); }
.choice .sug { margin-left: 8px; padding: 1px 7px; border-radius: 9px; background: rgba(184,52,42,.1); color: var(--accent); font-size: 11px; font-style: normal; font-weight: 600; vertical-align: 2px; }
.starters, .recs { margin-top: 14px; }
.st-title { padding: 0 4px 8px; font-size: 13px; font-weight: 500; color: var(--ink3); }
.st-tabs { display: flex; gap: 8px; overflow-x: auto; padding: 0 2px 10px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.st-tabs::-webkit-scrollbar { display: none; }
.st-tabs button { flex: none; border: 0; border-radius: 15px; padding: 6px 13px; background: rgba(60,50,40,.08); color: var(--ink2); font-size: 14px; }
.st-tabs button.on { background: var(--ink); color: #fff; font-weight: 600; }
.st-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { max-width: 100%; border: .5px solid var(--hair); border-radius: 14px; padding: 9px 13px; background: var(--group); color: var(--ink); font-size: 15px; line-height: 1.4; text-align: left; }
.st-toggle { border: 0; background: none; padding: 6px 4px; color: var(--accent); font-size: 14px; font-weight: 500; }
.rec-list { background: var(--group); border-radius: 12px; overflow: hidden; }
.rec { position: relative; display: flex; align-items: center; gap: 12px; width: 100%; border: 0; background: none; padding: 9px 14px 9px 10px; text-align: left; color: var(--ink); }
.rec + .rec::before { content: ''; position: absolute; top: 0; left: 118px; right: 0; border-top: .5px solid var(--hair); }
.rec i { flex: none; width: 96px; aspect-ratio: 16 / 9; border-radius: 6px; background: var(--fill) center / cover; }
.rec .rt { flex: 1; min-width: 0; }
.rec .rt b { display: block; font-size: 15px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rec .rt small { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 2px; font-size: 13px; line-height: 1.35; color: var(--ink3); }
.rec .tick, .idea .tick { flex: none; width: 20px; height: 20px; color: var(--accent); stroke-width: 2.4; }
.idea-list { margin-bottom: 20px; }
.row.idea { position: relative; align-items: flex-start; gap: 14px; width: 100%; border: 0; background: none; padding: 12px 16px; text-align: left; color: var(--ink); }
.row.idea + .row.idea::before { content: ''; position: absolute; top: 0; left: 62px; right: 0; border-top: .5px solid var(--hair); }
.idea .id { flex: none; width: 34px; padding-top: 2px; font-size: 14px; font-weight: 600; color: var(--ink3); font-variant-numeric: tabular-nums; }
.idea .it { flex: 1; min-width: 0; }
.idea .it b { display: block; font-size: 16px; font-weight: 600; }
.idea .it b em { margin-left: 8px; font-size: 12px; font-style: normal; font-weight: 500; color: var(--ink3); }
.idea .it small { display: block; margin-top: 2px; font-size: 13px; line-height: 1.4; color: var(--ink3); }
.idea.done .it b { color: var(--ink3); }
.idea > svg:last-child { margin-top: 4px; }

/* 자동 시연 (?tour=1): 첫 화면 휴대폰 틀 안에서 돌아간다 */
html.tour, html.tour body { overflow: hidden; }
.tour * { pointer-events: none !important; }
.tour .pv-pill, .tour .demo-pill, .tour .round, .tour .v-make, .tour .v-hint { display: none !important; }
.tour .board-wrap:not(.tour-in) { opacity: 0; }
.tour .board-wrap.tour-in { animation: tourIn 1.2s cubic-bezier(.2,.8,.2,1) both; }
@keyframes tourIn { from { opacity: 0; transform: translateY(22px) scale(.96); } }
.tour-finger { position: fixed; left: 0; top: 0; z-index: 200; width: 46px; height: 46px; border-radius: 50%; pointer-events: none; opacity: 0; scale: 1.35; will-change: transform;
  background: rgba(255,255,255,.3); border: 1.5px solid rgba(255,255,255,.7); transition: opacity .22s ease, scale .18s ease, background .18s ease; }
.tour-finger.on { opacity: 1; scale: 1; }
.tour-finger.press { scale: .82; background: rgba(255,255,255,.5); }

/* ---------- v7: 문 경계와 숫자가 어떤 배경에서도 읽히게 ---------- */
/* 칼선: 바깥은 어두운 1px, 안쪽은 밝은 1px. 칼집 낸 종이처럼 보인다. 윗변·왼변은 살짝 밝고 아랫변·오른변은 살짝 어둡다. */
.flap::before, .ed-door.empty::before {
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.5), inset 0 0 0 2px rgba(255,255,255,.34), inset 0 0 6px 1px rgba(0,0,0,.2);
  background: linear-gradient(135deg, rgba(255,255,255,.15), rgba(255,255,255,0) 32%, rgba(0,0,0,0) 62%, rgba(0,0,0,.17)); }
.door:not(.torn), .ed-door { filter: drop-shadow(0 1px 1.2px rgba(0,0,0,.4)); }
.door.torn { filter: drop-shadow(0 -1px 0 rgba(0,0,0,.25)); }
.door.today.ready { filter: drop-shadow(0 1px 1.2px rgba(0,0,0,.4)); }
.ed-door.full::after { box-shadow: inset 0 0 0 1px rgba(0,0,0,.5), inset 0 3px 8px rgba(0,0,0,.55); }
/* 밝은 배경(테마 tone:light, 밝은 내 사진)은 문마다 옅은 덮개를 깔아 무늬 대비를 낮춘다 */
.tone-light .flap::before, .tone-light .ed-door.empty::before {
  background: linear-gradient(135deg, rgba(255,255,255,.12), rgba(255,255,255,0) 32%, rgba(0,0,0,0) 62%, rgba(0,0,0,.17)), linear-gradient(rgba(20,12,6,var(--veil, .1)), rgba(20,12,6,var(--veil, .1))); }
.plate { background: radial-gradient(closest-side, rgba(12,8,4,.6), rgba(12,8,4,.32) 58%, transparent); }
.theme-midnight .plate { background: radial-gradient(closest-side, rgba(8,14,40,.65), rgba(8,14,40,.3) 58%, transparent); }
.ed-door .plate { position: absolute; left: 50%; top: 50%; width: 78cqmin; height: 64cqmin; transform: translate(-50%, -50%); border-radius: 50%; pointer-events: none; }
.ed-door[data-day="25"] .plate, .ed-door[data-day="24"] .plate { width: 70cqmin; height: 56cqmin; }
.ed-door[data-shape="round"] .plate { width: 70cqmin; height: 60cqmin; }
/* 금박 숫자: 얇은 어두운 외곽 */
.num { filter: var(--numfx, drop-shadow(1px 0 0 rgba(30,14,0,.78)) drop-shadow(-1px 0 0 rgba(30,14,0,.78)) drop-shadow(0 1px 0 rgba(30,14,0,.78)) drop-shadow(0 -1px 0 rgba(30,14,0,.78)) drop-shadow(0 0 5px rgba(0,0,0,.5))); }

/* 숫자 스타일: 배경에 맞춰 고른다 (판에 numeral-gold / ivory / ink / red 클래스) */
.numeral-ivory { --foil: linear-gradient(170deg, #fffefa 0%, #f8eed8 50%, #e6d7b6 100%); }
.numeral-ink { --foil: linear-gradient(170deg, #55362a 0%, #2b1912 55%, #1b0f0b 100%);
  --numfx: drop-shadow(1px 0 0 rgba(255,247,232,.9)) drop-shadow(-1px 0 0 rgba(255,247,232,.9)) drop-shadow(0 1px 0 rgba(255,247,232,.9)) drop-shadow(0 -1px 0 rgba(255,247,232,.9)) drop-shadow(0 1px 3px rgba(255,255,255,.55)); }
.numeral-red { --foil: linear-gradient(170deg, #c13a30 0%, #8e1a1d 55%, #6d0f16 100%);
  --numfx: drop-shadow(1px 0 0 rgba(255,247,232,.92)) drop-shadow(-1px 0 0 rgba(255,247,232,.92)) drop-shadow(0 1px 0 rgba(255,247,232,.92)) drop-shadow(0 -1px 0 rgba(255,247,232,.92)) drop-shadow(0 1px 3px rgba(255,255,255,.5)); }
.numeral-ink .plate, .numeral-red .plate { background: radial-gradient(closest-side, rgba(255,246,228,.78), rgba(255,246,228,.4) 58%, transparent); }
.numeral-ink .num::after, .numeral-red .num::after { display: none; }
/* 내 사진: 사진이 선명하게 보이도록 문 덮개를 깔지 않는다. 대비는 칼선과 숫자 그림자가 맡는다 */
.theme-custom .flap::before, .theme-custom .ed-door.empty::before { background: linear-gradient(135deg, rgba(255,255,255,.1), rgba(255,255,255,0) 30%, rgba(0,0,0,0) 65%, rgba(0,0,0,.1)); }

/* 숫자 스타일 고르기 */
.ns-wrap { padding: 4px 16px 16px; border-top: .5px solid var(--hair); }
.ns-title { padding: 12px 0 10px; font-size: 13px; color: var(--ink3); }
.numerals { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.ns { border: 0; background: none; padding: 0; text-align: center; color: var(--ink2); font-size: 12px; }
.ns i { position: relative; display: block; container-type: size; aspect-ratio: 5 / 4; border-radius: 8px; overflow: hidden; background: var(--fill) center / cover; margin-bottom: 6px; box-shadow: inset 0 0 0 .5px rgba(0,0,0,.25); }
.ns .plate { width: 90cqw; height: 70cqh; }
.ns .num { font-size: 52cqh; }
.ns.on { color: var(--ink); font-weight: 600; }
.ns.on i { box-shadow: 0 0 0 2px var(--group), 0 0 0 4px var(--accent); }
/* 1일부터 채우기, 목록으로 보기 */
.fill-btn { display: flex; align-items: center; justify-content: space-between; width: calc(100% - 32px); margin: 4px 16px 12px; padding: 15px 18px; border: 0; border-radius: 14px; background: var(--accent); color: #fff; font-size: 17px; font-weight: 600; text-align: left; }
.fill-btn[hidden] { display: none; }
.fill-btn svg { width: 18px; height: 18px; stroke-width: 2.4; }
.seg { display: flex; margin: 0 16px 12px; padding: 2px; border-radius: 9px; background: rgba(60,50,40,.1); }
.seg button { flex: 1; border: 0; border-radius: 7px; padding: 6px 0; background: none; color: var(--ink2); font-size: 13px; font-weight: 500; }
.seg button.on { background: var(--group); color: var(--ink); font-weight: 600; box-shadow: 0 1px 3px rgba(0,0,0,.14); }
.board-wrap[hidden], .ed-list[hidden] { display: none; }
.ed-list { margin: 0 16px 28px; }
.ed-li { position: relative; display: flex; align-items: center; gap: 14px; width: 100%; min-height: 50px; padding: 10px 16px; border: 0; background: none; text-align: left; color: var(--ink); }
.ed-li + .ed-li::before { content: ''; position: absolute; top: 0; left: 62px; right: 0; border-top: .5px solid var(--hair); }
.ed-li .ld { flex: none; width: 34px; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
.ed-li .ls { flex: 1; min-width: 0; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ed-li.empty .ls { color: var(--ink4); }
.ed-li.empty .ld { color: var(--ink3); }
.ed-li.next .ld, .ed-li.next .ls { color: var(--accent); }
/* 다음에 채울 칸을 은은하게 */
.ed-door.next::after { content: ''; position: absolute; inset: -3px; z-index: 5; border-radius: inherit; pointer-events: none; box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--accent), 0 3px 14px 2px rgba(0,0,0,.28); animation: nextGlow 2.6s ease-in-out infinite; }
@keyframes nextGlow { 50% { opacity: .55; } }
@media (prefers-reduced-motion: reduce) { .ed-door.next::after { animation: none; } }
/* 하루 시트: 다음 빈 칸으로 */
.next-bar { display: flex; align-items: center; justify-content: space-between; flex: none; margin: 0 16px 8px; padding: 12px 16px; border: 0; border-radius: 12px; background: var(--accent); color: #fff; font-size: 16px; font-weight: 600; }
.next-bar[hidden] { display: none; }
.next-bar svg { width: 18px; height: 18px; stroke-width: 2.4; }

/* QA: 태블릿처럼 넓은 화면에서도 글 종이는 받는 화면 카드와 같은 폭(세로 속지 비율)으로 */
.eb-paper { max-width: 420px; margin-left: auto; margin-right: auto; }
