@font-face { font-family: "Pretendard"; src: url("fonts/PretendardVariable-subset.woff2") format("woff2"); font-weight: 45 920; font-style: normal; font-display: swap; }
/* 사진쏙 v1.8 — 다크(기본)·일반 두 가지 화면. 색은 모두 아래 토큰으로만 정한다. */
:root {
  color-scheme: light;
  --bg: #f3f4f2;
  --panel: #ffffff;
  --surface: #f7f8f6;
  --subtle: #eef0ec;
  --line: #dfe3de;
  --field: #ffffff;
  --text: #101213;
  --muted: #6b7378;
  --accent: #101213;
  --accent-strong: #2b3033;
  --accent-soft: #f1f8dc;
  --on-accent: #ffffff;
  --lime: #c8f04a;
  --on-lime: #101213;
  --clay: #ff8a5c;
  --danger: #d0392b;
  --warn-bg: #fff4e6;
  --warn-line: #f0d2b0;
  --warn-text: #8a4b1f;
  --backdrop: rgba(16,18,19,.55);
  --overlay: rgba(16,18,19,.78);
  --bar-bg: rgba(255,255,255,.94);
  --yellow: var(--accent);
  --green: var(--accent);
  --shadow: 0 10px 30px rgba(16,18,19,.06);
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #101213;
  --panel: #1b1e20;
  --surface: #202427;
  --subtle: #24282b;
  --line: #2f3438;
  --field: #15181a;
  --text: #f4f6f5;
  --muted: #8a9399;
  --accent: #c8f04a;
  --accent-strong: #b5dc3a;
  --accent-soft: #252c15;
  --on-accent: #101213;
  --lime: #c8f04a;
  --on-lime: #101213;
  --clay: #ff9466;
  --danger: #ff7a66;
  --warn-bg: #2a2116;
  --warn-line: #4a3a22;
  --warn-text: #f0b46a;
  --backdrop: rgba(0,0,0,.72);
  --overlay: rgba(0,0,0,.72);
  --bar-bg: rgba(16,18,19,.94);
  --shadow: none;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: "Pretendard", Pretendard, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans KR", sans-serif; letter-spacing: -.025em; }
button, input, select { font: inherit; }
button, a, input, select, summary { -webkit-tap-highlight-color: transparent; }
button { border: 0; cursor: pointer; }
button:disabled { cursor: default; opacity: .48; }
button, a, input, select, summary { touch-action: manipulation; }
:where(button,a,input,select,summary):focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
a { color: inherit; text-decoration: none; }
svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.svg-defs { display: none; }
.topbar { max-width: 1160px; min-height: 92px; margin: auto; padding: 0 28px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 25px; font-weight: 800; letter-spacing: -.065em; }
.brand-mark { width: 39px; height: 43px; display: grid; place-items: center; }
.brand-mark img { width: 100%; height: 100%; display: block; }
.brand-dot { color: var(--clay); }
.private-tag { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12px; }
.private-tag svg { width: 15px; height: 15px; }
main { max-width: 1104px; margin: auto; padding: 48px 0 0; }
.intro { display: grid; grid-template-columns: 1fr 290px; align-items: center; gap: 36px; margin-bottom: 40px; }
.intro-copy { min-width: 0; }
.eyebrow { display: flex; align-items: center; gap: 8px; color: var(--accent); font-size: 12px; font-weight: 700; letter-spacing: .04em; margin: 0 0 14px; }
.eyebrow > span { width: 6px; height: 6px; background: var(--clay); border-radius: 50%; }
h1 { margin: 0 0 17px; font-size: clamp(34px, 4vw, 48px); line-height: 1.23; letter-spacing: -.065em; font-weight: 800; }
.mobile-break { display: none; }
.intro p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.8; }
.intro-art { width: 100%; display: flex; justify-content: center; }
.intro-art img { display: block; width: 100%; max-height: 220px; object-fit: contain; }
.workspace-heading { display: flex; align-items: center; gap: 14px; margin: 0 0 13px; }
.workspace-heading .eyebrow { margin: 0; }
.workspace-heading > span { color: var(--muted); font-size: 12px; }
.workflow-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 18px; }
.workflow-switch > button { display: flex; align-items: center; text-align: left; gap: 14px; min-height: 92px; padding: 18px 22px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); color: var(--text); }
.workflow-switch > button.selected { border: 2px solid var(--accent); padding: 17px 21px; background: var(--accent-soft); }
.workflow-switch svg { width: 29px; height: 29px; color: var(--accent); }
.workflow-switch strong { display: block; font-size: 16px; margin-bottom: 6px; }
.workflow-switch small { display: block; color: var(--muted); font-size: 12px; line-height: 1.55; }
.new-badge { display: none; }
.flow-hint { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; color: var(--muted); font-size: 12px; line-height: 1.7; margin: 18px 2px 21px; }
.flow-hint span { color: var(--muted); }
.modes { display: flex; gap: 5px; padding: 5px; width: max-content; max-width: 100%; background: var(--subtle); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 22px; }
.mode { min-height: 44px; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 0 22px; color: var(--muted); background: transparent; border-radius: 8px; font-size: 14px; font-weight: 600; }
.mode.active { color: var(--accent); background: var(--panel); box-shadow: 0 2px 5px #18353f0b; }
.mode svg { width: 19px; height: 19px; }
.workspace { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(330px, 1fr); align-items: start; gap: 24px; }
.photos-panel, .settings-panel { min-width: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); }
.photos-panel { min-height: 455px; padding: 20px; }
.settings-panel { padding: 25px; }
.dropzone { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 414px; padding: 28px 18px; border: 1px dashed var(--line); border-radius: 13px; background: var(--surface); text-align: center; transition: background .15s, border-color .15s; }
.dropzone.dragover { background: var(--accent-soft); border-color: var(--accent); }
.drop-art { width: 120px; height: 90px; margin: 0 0 18px; }
.drop-art img { width: 100%; height: 100%; display: block; object-fit: contain; }
.dropzone h2 { font-size: 20px; font-weight: 750; line-height: 1.45; letter-spacing: -.04em; margin: 0 0 10px; }
.dropzone .desktop-copy { font-size: 13px; line-height: 1.7; color: var(--muted); margin: 0 0 22px; }
.primary { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 20px; background: var(--accent); color: var(--on-accent); border-radius: 10px; font-size: 14px; font-weight: 700; transition: background .15s, transform .15s; }
.primary:not(:disabled):hover { background: var(--accent-strong); }
.primary:not(:disabled):active { transform: translateY(1px); }
.primary:disabled { background: var(--line); color: var(--muted); opacity: 1; }
.choose { padding: 12px 28px; min-height: 48px; font-size: 15px; }
.camera-button { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 9px; min-height: 44px; padding: 9px 22px; border: 1px solid var(--line); border-radius: 9px; background: transparent; color: var(--text); font-size: 13px; }
.camera-button svg { width: 18px; height: 18px; }
.file-hint { font-size: 12px; color: var(--muted); line-height: 1.6; margin: 16px 0 5px; }
.text-button { min-height: 44px; background: none; color: var(--muted); font-size: 12px; padding: 9px 5px; }
.text-button span { color: var(--accent); }
.text-button:hover { color: var(--accent); }
.settings-heading { display: flex; align-items: center; gap: 9px; margin-bottom: 20px; }
.step-number { background: var(--warn-bg); color: var(--warn-text); border-radius: 5px; padding: 5px 7px; font-size: 12px; font-weight: 750; }
.settings-heading h2 { margin: 0; font-size: 17px; font-weight: 750; letter-spacing: -.04em; }
.preset-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.preset-grid > button { position: relative; min-height: 86px; text-align: left; padding: 13px 11px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); }
.preset-grid > button.selected { border: 2px solid var(--accent); padding: 12px 10px; color: var(--accent); background: var(--accent-soft); }
.preset-grid strong { display: block; font-size: 26px; letter-spacing: -.06em; }
.preset-grid strong span { font-size: 12px; font-weight: 500; letter-spacing: 0; }
.preset-grid small { display: block; margin-top: 7px; font-size: 12px; line-height: 1.4; color: var(--muted); }
.preset-check { position: absolute; top: 5px; right: 7px; font-size: 12px; }
.preset-grid button:not(.selected) .preset-check { display: none; }
.custom-toggle { display: flex; justify-content: space-between; align-items: center; width: 100%; min-height: 44px; padding: 12px 0 4px; background: none; color: var(--muted); font-size: 13px; }
.custom-toggle span { font-size: 18px; }
.custom-input { margin-top: 12px; }
.custom-input label, .field-label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.custom-input > div { position: relative; }
.custom-input input, .size-inputs input, .pdf-filename input { width: 100%; min-height: 46px; background: var(--field); border: 1px solid var(--line); border-radius: 8px; color: var(--text); padding: 11px 13px; }
.custom-input > div input { padding-right: 90px; }
.custom-input > div > span { position: absolute; right: 12px; top: 14px; color: var(--muted); font-size: 12px; }
.custom-input small { display: block; color: var(--muted); margin-top: 6px; font-size: 12px; line-height: 1.6; }
.note { display: flex; gap: 8px; padding: 13px; margin-top: 18px; border-radius: 9px; background: var(--subtle); color: var(--muted); }
.note-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--clay); flex-shrink: 0; margin-top: 8px; }
.note p { font-size: 12px; line-height: 1.75; margin: 0; }
.note b { color: var(--text); font-weight: 650; }
.setting-divider { height: 1px; background: var(--line); margin: 23px 0 17px; }
.output-info { display: flex; justify-content: space-between; gap: 12px; color: var(--muted); font-size: 12px; }
.output-info strong { color: var(--text); text-align: right; font-weight: 600; }
.output-note { color: var(--muted); font-size: 12px; line-height: 1.75; margin: 10px 0 20px; }
.process { width: 100%; min-height: 51px; padding: 12px 15px; }
.process > span { flex: 1; }
.process > svg { width: 19px; height: 19px; }
.process .button-arrow { margin-left: auto; }
.safe-caption { display: flex; justify-content: center; align-items: center; gap: 5px; margin: 13px 0 0; font-size: 12px; color: var(--muted); }
.safe-caption svg { width: 13px; height: 13px; }
select { width: 100%; min-height: 48px; background: var(--field); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; color: var(--text); font-size: 14px; }
.trust-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; padding: 30px 6px; margin-top: 8px; }
.trust-row > div { display: flex; gap: 12px; align-items: center; }
.trust-icon { display: grid; place-items: center; width: 36px; height: 36px; flex-shrink: 0; color: var(--accent); border-radius: 50%; background: var(--accent-soft); }
.trust-icon svg { width: 18px; height: 18px; }
.trust-row p { margin: 0; }
.trust-row strong { display: block; margin-bottom: 5px; font-size: 13px; font-weight: 650; }
.trust-row p > span { font-size: 12px; color: var(--muted); line-height: 1.6; }
.faq { border-top: 1px solid var(--line); margin-top: 3px; color: var(--muted); font-size: 13px; line-height: 1.9; }
.faq summary { display: flex; justify-content: space-between; min-height: 56px; align-items: center; list-style: none; cursor: pointer; color: var(--text); }
.faq summary::-webkit-details-marker { display: none; }
.faq p { margin: 0 0 17px; }
.faq a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
footer { max-width: 1104px; margin: 24px auto 0; padding: 25px 0 32px; display: flex; gap: 17px; align-items: center; border-top: 1px solid var(--line); color: var(--muted); }
footer > span:first-child { color: var(--text); font-size: 18px; font-weight: 800; }
footer p { font-size: 12px; margin: 0; }
footer .version { margin-left: auto; font-size: 12px; }
.queue-header { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 0 0 15px; }
.queue-header h2 { margin: 0; font-size: 16px; }
.queue-header h2 span { padding-left: 5px; color: var(--accent); }
.queue-header > div { display: flex; align-items: center; gap: 5px; }
.small-button { display: flex; align-items: center; justify-content: center; gap: 4px; min-height: 44px; border: 1px solid var(--line); border-radius: 8px; padding: 9px 11px; background: var(--accent-soft); color: var(--accent); font-size: 12px; font-weight: 600; }
.small-button svg { width: 16px; height: 16px; }
.summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; border: 1px solid var(--line); background: var(--accent-soft); border-radius: 11px; padding: 16px; margin-bottom: 14px; }
.summary div > span { font-size: 12px; color: var(--muted); }
.summary p { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 16px; margin: 6px 0 0; }
.summary p > span { font-size: 13px; color: var(--muted); }
.summary svg { width: 16px; height: 16px; color: var(--muted); }
.summary strong, .summary > b { color: var(--accent); }
.summary > b { font-size: 19px; white-space: nowrap; }
.photo-list { display: flex; flex-direction: column; gap: 11px; }
.photo-card { display: grid; grid-template-columns: 64px minmax(0, 1fr) 44px; gap: 12px; padding: 13px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); }
.photo-thumb { display: block; width: 64px; height: 78px; object-fit: cover; border: 1px solid var(--line); background: var(--subtle); border-radius: 5px; }
.photo-detail { min-width: 0; }
.filename { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; line-height: 1.6; margin: 2px 0 5px; }
.photo-status { color: var(--muted); font-size: 12px; line-height: 1.7; margin: 0; overflow-wrap: anywhere; }
.photo-status.error { color: var(--danger); }
.photo-status.done { color: var(--accent); }
.photo-status.stale { color: var(--warn-text); }
.card-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin-top: 7px; }
.card-actions button { min-width: 44px; min-height: 44px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); color: var(--accent); font-size: 12px; }
.card-meta { color: var(--muted); font-size: 12px; line-height: 1.6; margin: 5px 0 0; }
.remove { width: 44px; min-height: 44px; display: grid; place-items: center; padding: 4px; background: none; color: var(--muted); }
.remove svg { width: 18px; height: 18px; }
.save-all, .share-all { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 48px; padding: 12px; border-radius: 9px; font-size: 14px; font-weight: 700; margin-top: 15px; }
.save-all { background: var(--accent); color: var(--on-accent); }
.save-all svg { width: 18px; height: 18px; }
.share-all { background: var(--accent-soft); border: 1px solid var(--line); color: var(--accent); margin-top: 9px; }
.helper { color: var(--muted); font-size: 12px; line-height: 1.75; text-align: center; margin: 11px 0 0; }
.align-left { text-align: left; }
.cancel { display: block; margin: 6px auto 0; color: var(--warn-text); }
progress { appearance: none; width: 100%; height: 6px; margin-top: 15px; border: 0; border-radius: 5px; overflow: hidden; background: var(--line); accent-color: var(--accent); }
progress::-webkit-progress-bar { background: var(--line); }
progress::-webkit-progress-value { background: var(--accent); }
.toast { position: fixed; z-index: 10; bottom: 24px; left: 50%; transform: translateX(-50%); max-width: calc(100vw - 32px); width: max-content; padding: 14px 20px; background: var(--text); color: var(--on-accent); border-radius: 12px; box-shadow: 0 8px 30px #18353f28; font-size: 13px; line-height: 1.7; }
.toast.error { background: var(--danger); }
dialog { width: calc(100% - 24px); max-width: 680px; max-height: 92dvh; padding: 22px; overflow: auto; background: var(--panel); color: var(--text); border: 1px solid var(--line); border-radius: 18px; }
dialog::backdrop { background: var(--backdrop); backdrop-filter: blur(4px); }
.dialog-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.dialog-head h2 { font-size: 20px; margin: 0; }
.icon-button { display: grid; place-items: center; flex-shrink: 0; width: 44px; height: 44px; border-radius: 50%; color: var(--accent); background: var(--accent-soft); }
.icon-button svg { width: 20px; height: 20px; }
.compare-name { font-size: 13px; color: var(--muted); overflow-wrap: anywhere; }
.compare-stage { height: min(50vh, 420px); position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: var(--subtle); }
.compare-stage > img, .compare-stage > div > img { width: 100%; height: 100%; object-fit: contain; display: block; }
.compare-stage > #beforeLayer { position: absolute; inset: 0; clip-path: inset(0 50% 0 0); background: var(--subtle); }
.before-badge, .after-badge { position: absolute; top: 12px; padding: 6px 9px; border-radius: 5px; font-size: 12px; color: var(--on-accent); background: var(--overlay); }
.before-badge { left: 12px; }
.after-badge { right: 12px; }
#splitLine { position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; background: var(--clay); pointer-events: none; }
#compareRange { width: 100%; height: 36px; margin: 4px 0; accent-color: var(--accent); }
.slider-label { display: block; text-align: center; margin-top: 14px; font-size: 12px; color: var(--muted); }
.compare-meta { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 8px; margin: 10px 0 20px; font-size: 12px; }
.compare-meta svg { width: 16px; height: 16px; }
.compare-meta strong { color: var(--accent); }
#dialogSave { width: 100%; }
.advanced { border-top: 1px solid var(--line); margin-top: 18px; font-size: 13px; color: var(--text); }
.advanced summary { display: flex; justify-content: space-between; align-items: center; min-height: 48px; padding: 13px 0 8px; cursor: pointer; list-style: none; }
.advanced summary::-webkit-details-marker { display: none; }
.check-row { display: flex; align-items: flex-start; gap: 9px; min-height: 44px; font-size: 13px; line-height: 1.65; color: var(--text); cursor: pointer; margin: 14px 0; }
.check-row input { accent-color: var(--accent); width: 18px; height: 18px; flex-shrink: 0; margin: 2px 0 0; }
.check-row small { display: block; color: var(--muted); font-size: 12px; }
.privacy-option { margin: 21px 0 -7px; }
.size-inputs { display: flex; align-items: center; gap: 8px; margin: 12px 0; }
.size-inputs label { flex: 1; min-width: 0; font-size: 12px; color: var(--muted); }
.size-inputs input { display: block; margin-top: 6px; }
.size-inputs > span { padding-top: 20px; color: var(--muted); }
.size-presets { display: flex; flex-wrap: wrap; gap: 8px; }
.size-presets button { min-height: 44px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 7px; background: var(--accent-soft); color: var(--accent); font-size: 12px; }
.stale-note { padding: 12px 14px; background: var(--warn-bg); color: var(--warn-text); border: 1px solid var(--warn-line); border-radius: 8px; margin: 0 0 12px; font-size: 12px; line-height: 1.75; }
.whole-file-label { font-size: 13px; color: var(--muted); margin: -3px 0 15px; line-height: 1.75; }
.whole-file-label b { color: var(--accent); }
.pdf-name-label { margin-top: 21px; }
.pdf-filename { position: relative; }
.pdf-filename input { padding-right: 45px; font-size: 14px; }
.pdf-filename > span { position: absolute; right: 12px; top: 14px; color: var(--muted); font-size: 12px; }
.pdf-result { border: 1px solid var(--line); border-radius: 12px; padding: 19px; background: var(--subtle); margin: 0 0 17px; }
.pdf-result.old-result { background: var(--warn-bg); border-color: var(--warn-line); }
.pdf-result-top { display: flex; align-items: center; gap: 11px; }
.result-icon { display: grid; place-items: center; flex-shrink: 0; width: 35px; height: 35px; background: var(--accent); color: var(--on-accent); border-radius: 50%; }
.pdf-result-top strong { font-size: 16px; color: var(--text); }
.pdf-result-top p { margin: 7px 0 0; font-size: 12px; line-height: 1.7; color: var(--muted); }
.pdf-checks { list-style: none; padding: 0; margin: 17px 0; }
.pdf-checks li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 12px; line-height: 1.6; }
.pdf-checks li strong { text-align: right; color: var(--text); font-weight: 650; }
.pdf-result-actions { display: flex; gap: 10px; margin-top: 15px; }
.pdf-result-actions .primary { flex: 1; }
.pdf-result-actions .small-button { padding: 10px; }
.pdf-error { margin: 0 0 14px; padding: 15px; border: 1px solid var(--warn-line); border-radius: 9px; background: var(--warn-bg); color: var(--danger); font-size: 13px; line-height: 1.8; }
.page-label { display: inline-block; padding: 3px 7px; margin-bottom: 5px; border-radius: 5px; background: var(--subtle); color: var(--accent); font-size: 12px; }
.page-controls { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.page-controls button { min-width: 44px; min-height: 44px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--field); color: var(--accent); font-size: 12px; }
.page-controls button:disabled { opacity: .35; }
.pdf-preview-controls { display: flex; justify-content: space-between; align-items: center; margin: 16px 0; }
.pdf-preview-controls strong { color: var(--muted); font-size: 14px; }
.pdf-preview-scroll { max-height: 64vh; overflow: auto; background: var(--subtle); padding: 16px; }
.pdf-page-canvas { position: relative; width: 100%; margin: auto; background: var(--field); }
.pdf-page-canvas img { position: absolute; object-fit: fill; }
#pdfPreviewSave { width: 100%; margin-top: 16px; }
.pdf-mode-choice { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pdf-mode-choice button { min-height: 48px; padding: 11px 8px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: var(--muted); font-size: 13px; line-height: 1.5; }
.pdf-mode-choice button.selected { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.mode-note { margin: 12px 0 18px; padding: 12px; border-left: 3px solid var(--line); background: var(--subtle); color: var(--muted); font-size: 12px; line-height: 1.75; }
.mobile-bar { display: none; }
@media (max-width: 1160px) {
  main, footer { margin-left: 28px; margin-right: 28px; }
}
@media (max-width: 760px) {
  .topbar { min-height: 75px; padding: 0 20px; }
  .brand { font-size: 23px; gap: 8px; }
  .brand-mark { width: 33px; height: 37px; }
  .private-tag { font-size: 12px; gap: 4px; }
  .private-tag svg { width: 14px; height: 14px; }
  main { margin: 0; padding: 31px 18px 0; }
  .intro { grid-template-columns: minmax(0, 1fr) 100px; gap: 9px; margin-bottom: 29px; }
  h1 { font-size: 33px; margin-bottom: 12px; line-height: 1.3; }
  .mobile-break { display: block; }
  .intro p { font-size: 13px; line-height: 1.75; }
  .intro-art img { max-height: 130px; }
  .eyebrow { font-size: 12px; margin-bottom: 11px; letter-spacing: .01em; }
  .workspace-heading { gap: 10px; margin-bottom: 11px; }
  .workspace-heading > span { font-size: 12px; }
  .workflow-switch { gap: 9px; margin-bottom: 16px; }
  .workflow-switch > button, .workflow-switch > button.selected { display: block; padding: 13px 12px; min-height: 115px; border-width: 1px; }
  .workflow-switch > button.selected { box-shadow: inset 0 0 0 1px var(--accent); }
  .workflow-switch svg { width: 22px; height: 22px; margin-bottom: 7px; }
  .workflow-switch strong { font-size: 14px; margin-bottom: 4px; }
  .workflow-switch small { font-size: 12px; line-height: 1.5; }
  .flow-hint { font-size: 12px; gap: 7px; margin: 15px 0 18px; }
  .modes { width: 100%; padding: 4px; gap: 3px; margin-bottom: 17px; }
  .mode { flex: 1; min-width: 0; padding: 8px 2px; gap: 4px; font-size: 12px; }
  .mode svg { width: 16px; height: 16px; }
  .workspace { grid-template-columns: minmax(0, 1fr); gap: 17px; }
  .photos-panel { min-height: 0; padding: 12px; border-radius: 16px; }
  .dropzone { min-height: 335px; padding: 22px 10px 15px; }
  .drop-art { width: 100px; height: 75px; margin-bottom: 13px; }
  .dropzone h2 { font-size: 17px; margin-bottom: 12px; }
  .desktop-copy { display: none; }
  .choose { min-width: 195px; min-height: 46px; font-size: 14px; }
  .file-hint { font-size: 12px; margin: 13px 0 3px; }
  .camera-button { font-size: 12px; margin-top: 8px; }
  .settings-panel { padding: 21px 18px; border-radius: 16px; }
  .settings-heading { margin-bottom: 18px; }
  .settings-heading h2 { font-size: 16px; }
  .preset-grid > button { padding: 13px 9px; }
  .preset-grid > button.selected { padding: 12px 8px; }
  .preset-grid strong { font-size: 25px; }
  .preset-grid small { font-size: 12px; }
  .trust-row { grid-template-columns: 1fr; gap: 16px; padding: 25px 3px; margin: 0; }
  .trust-row > div { gap: 11px; }
  .trust-row p { display: flex; align-items: center; flex-wrap: wrap; gap: 3px 11px; }
  .trust-row strong { margin: 0; min-width: 110px; font-size: 12px; }
  .trust-row p > span { font-size: 12px; }
  .trust-icon { width: 31px; height: 31px; }
  .faq { font-size: 12px; }
  footer { margin: 16px 18px 0; padding: 20px 0 27px; gap: 11px; flex-wrap: wrap; }
  footer > span:first-child { font-size: 16px; }
  footer p { font-size: 12px; }
  .queue-header h2 { font-size: 14px; }
  .photo-card { grid-template-columns: 48px minmax(0,1fr) 44px; gap: 8px; padding: 10px; }
  .photo-thumb { width: 48px; height: 66px; }
  .filename { font-size: 12px; }
  .remove { width: 44px; }
  .page-controls, .card-actions { margin-left: -56px; margin-top: 10px; gap: 6px; }
  .page-controls button, .card-actions button { min-height: 44px; padding: 8px 10px; }
  .card-actions + .card-actions { margin-top: 6px; }
  .summary { padding: 13px; }
  .summary > b { font-size: 17px; }
  .pdf-result { padding: 14px; }
  .pdf-result-top strong { font-size: 15px; }
  .pdf-result-actions { gap: 8px; }
  .pdf-result-actions .small-button, .pdf-result-actions .primary { font-size: 12px; padding: 9px; }
  .pdf-preview-scroll { padding: 8px; }
  dialog { padding: 17px; }
  .dialog-head h2 { font-size: 18px; }
  .toast { font-size: 12px; padding: 12px 16px; bottom: 18px; }
  body.has-mobile-bar { padding-bottom: 94px; }
  .mobile-bar { display: flex; position: fixed; z-index: 5; left: 0; bottom: 0; width: 100%; align-items: center; gap: 9px; background: var(--bar-bg); border-top: 1px solid var(--line); box-shadow: 0 -5px 25px #18353f0a; backdrop-filter: blur(12px); padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); }
  .mobile-bar > div { flex: 1; min-width: 0; }
  .mobile-bar strong { display: block; font-size: 13px; }
  .mobile-bar span { display: block; margin-top: 5px; color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .mobile-bar .primary { min-height: 46px; font-size: 13px; padding: 10px 16px; min-width: 105px; }
  .mobile-bar .small-button { min-height: 44px; padding: 8px 10px; }
  .has-mobile-bar .toast { bottom: 105px; }
}
@media (max-width: 365px) {
  .intro { grid-template-columns: minmax(0,1fr); }
  .intro-art { display: none; }
  .workspace-heading > span { font-size: 12px; }
  .private-tag { font-size: 12px; }
  .workflow-switch small { font-size: 12px; }
  .pdf-mode-choice button { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
.app-update{position:fixed;left:50%;bottom:calc(16px + env(safe-area-inset-bottom));transform:translateX(-50%);z-index:60;display:flex;align-items:center;gap:12px;max-width:calc(100% - 32px);padding:10px 10px 10px 16px;border-radius:14px;background:var(--text);color:var(--bg);font-size:14px;box-shadow:0 8px 24px rgba(24,53,63,.25)}
.app-update button{border:0;border-radius:10px;padding:8px 12px;background:var(--bg);color:var(--text);font:inherit;font-weight:700;cursor:pointer}

/* ---- v1.8 첫 화면: 큰 숫자 결과 + 4칸 기능 ---- */
.intro, .workspace-heading, .workflow-switch, .flow-hint, .modes, .trust-row { display: none !important; }
body { background: var(--bg); }
.topbar { border-bottom: 0; min-height: 68px; }
.brand { font-size: 22px; }
.brand-mark { width: 32px; height: 32px; }
.brand-mark img { border-radius: 9px; }
.brand-dot { font-style: normal; color: var(--lime); }
:root:not([data-theme="dark"]) .brand-dot { color: var(--clay); }
.top-actions { display: flex; align-items: center; gap: 10px; }
.theme-toggle { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: var(--panel); color: var(--text); border: 1px solid var(--line); }
.theme-toggle svg { width: 20px; height: 20px; }
:root[data-theme="dark"] .theme-toggle .icon-moon, :root:not([data-theme="dark"]) .theme-toggle .icon-sun { display: none; }
main { padding-top: 8px; }
.home-hero { background: var(--panel); border-radius: 26px; padding: 22px 22px 20px; margin-bottom: 12px; }
.hero-label { font-size: 14px; color: var(--muted); }
.hero-value { margin: 8px 0 0; font-size: 34px; font-weight: 800; line-height: 1.15; letter-spacing: -.04em; overflow-wrap: anywhere; }
.hero-value b { color: var(--accent); }
:root:not([data-theme="dark"]) .hero-value b { color: #5f7a00; }
.hero-bar { height: 10px; border-radius: 5px; background: var(--subtle); margin-top: 16px; overflow: hidden; }
.hero-bar > div { height: 100%; width: 0; background: var(--lime); border-radius: 5px; transition: width .4s ease; }
.hero-caption { margin: 12px 0 0; font-size: 13px; color: var(--muted); line-height: 1.6; }
.tool-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 18px; }
.tool { display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; gap: 18px; min-height: 124px; padding: 16px; text-align: left; border-radius: 22px; background: var(--panel); color: var(--text); border: 1px solid transparent; }
.tool-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--subtle); }
.tool-icon svg { width: 21px; height: 21px; }
.tool strong { display: block; font-size: 16px; font-weight: 700; }
.tool small { display: block; margin-top: 3px; font-size: 12px; color: var(--muted); }
.tool.active { background: var(--lime); color: var(--on-lime); }
.tool.active .tool-icon { background: rgba(0,0,0,.1); }
.tool.active small { color: #3d4a12; }
.tool:disabled { opacity: .45; }
.photos-panel, .settings-panel { border: 0; border-radius: 24px; box-shadow: var(--shadow); }
.dropzone { border: 1.5px dashed var(--line); background: var(--surface); border-radius: 18px; }
.primary { border-radius: 14px; }
.process, .save-all { min-height: 54px; font-size: 15px; }
.preset-grid > button, .pdf-mode-choice button, .card-actions button, .page-controls button, .small-button, .size-presets button, .camera-button { border-radius: 12px; }
.photo-card { border: 0; background: var(--surface); border-radius: 16px; }
.summary, .pdf-result { border: 0; border-radius: 18px; }
select, .custom-input input, .size-inputs input, .pdf-filename input { border-color: var(--line); border-radius: 12px; }
.step-number { background: var(--subtle); color: var(--muted); }
footer { border-top: 0; }
@media (min-width: 761px) {
  .home-hero { padding: 30px; }
  .hero-value { font-size: 44px; }
  .tool-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 760px) {
  .topbar { min-height: 64px; padding: 0 16px; }
  main { padding: 6px 14px 0; }
  .private-tag span { display: none; }
  .mobile-bar { border-top: 1px solid var(--line); box-shadow: none; }
  .mobile-bar .primary { border-radius: 14px; }
}
.drop-art { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.drop-art svg { width: 30px; height: 30px; stroke-width: 2.2; }
@media (max-width: 760px) { .drop-art { width: 56px; height: 56px; } .dropzone { min-height: 280px; } }

/* ---- 공유받기 빠른 줄이기 ---- */
.quick-sheet { width: 100%; max-width: 520px; margin: auto auto 0; padding: 12px 20px calc(20px + env(safe-area-inset-bottom)); border: 0; border-radius: 26px 26px 0 0; background: var(--panel); color: var(--text); }
.quick-sheet::backdrop { background: var(--backdrop); }
.quick-grab { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 14px; }
.quick-label { margin: 0; font-size: 13px; color: var(--muted); }
.quick-sheet h2 { margin: 6px 0 16px; font-size: 22px; font-weight: 800; }
.quick-chips { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.quick-chip { min-height: 56px; border-radius: 16px; background: var(--subtle); color: var(--text); font-size: 18px; font-weight: 700; }
.quick-chip.on { background: var(--lime); color: var(--on-lime); }
.quick-result { margin-top: 16px; padding: 16px; border-radius: 18px; background: var(--surface); }
.quick-big { margin: 0; font-size: 28px; font-weight: 800; letter-spacing: -.04em; }
.quick-big b { color: var(--accent); }
:root:not([data-theme="dark"]) .quick-big b { color: #5f7a00; }
.quick-sub { margin: 6px 0 0; font-size: 13px; color: var(--muted); }
.quick-error { margin: 14px 0 0; color: var(--danger); font-size: 13px; line-height: 1.6; }
.quick-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 18px; }
.quick-actions .primary { width: 100%; min-height: 56px; font-size: 16px; }
.quick-after { display: flex; gap: 8px; }
.quick-after .primary { flex: 1; }
.quick-after .small-button { min-width: 96px; min-height: 56px; font-size: 15px; }
.quick-actions .text-button { align-self: center; }

/* v1.10 · 100KB 칩, 화질 선택, 제출 규격 프리셋 */
.preset-grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.preset-grid.four > button { min-height: 78px; padding: 11px 8px; }
.preset-grid.four > button.selected { padding: 10px 7px; }
.preset-grid.four strong { font-size: 21px; }
.preset-grid.four small { font-size: 11px; margin-top: 5px; }
.quality-row { display: flex; align-items: center; gap: 6px; margin-top: 10px; flex-wrap: wrap; }
.quality-row > span { font-size: 12px; color: var(--muted); margin-right: auto; }
.quality-row button { min-height: 40px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--text); font-size: 13px; }
.quality-row button.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 700; }
.spec-presets { display: grid; gap: 8px; margin: 4px 0 6px; }
.spec-presets button { display: flex; justify-content: space-between; align-items: center; gap: 10px; min-height: 52px; padding: 10px 14px; text-align: left; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--text); }
.spec-presets button strong { font-size: 14px; }
.spec-presets button small { font-size: 12px; color: var(--muted); text-align: right; }
.spec-presets button.on { border: 2px solid var(--accent); padding: 9px 13px; background: var(--accent-soft); color: var(--accent); }
.spec-presets button.on small { color: var(--accent); }
.spec-source { margin: 6px 0 4px; padding: 10px 12px; border-radius: 10px; background: var(--subtle); color: var(--muted); font-size: 12px; line-height: 1.6; }
.fit-choice { display: grid; gap: 4px; margin: 12px 0 0; }
.fit-choice label { display: flex; align-items: center; gap: 9px; min-height: 40px; font-size: 13px; color: var(--text); cursor: pointer; }
.fit-choice input { accent-color: var(--accent); width: 18px; height: 18px; margin: 0; }
@media (max-width: 360px) { .preset-grid.four strong { font-size: 18px; } }
.spec-tile { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 12px; margin: -8px 0 18px; padding: 14px 16px; text-align: left; border-radius: 18px; border: 1px solid var(--line); background: var(--panel); color: var(--text); }
.spec-tile strong { display: block; font-size: 15px; }
.spec-tile small { display: block; margin-top: 3px; font-size: 12px; color: var(--muted); }
.spec-tile b { font-size: 22px; color: var(--accent); font-weight: 500; }

/* v1.11 · 자르기 조절 */
#cropDialog { max-width: 460px; }
.crop-hint { margin: 8px 0 12px; font-size: 13px; color: var(--muted); line-height: 1.6; }
.crop-stage { display: flex; justify-content: center; padding: 14px; border-radius: 14px; background: var(--subtle); }
#cropCanvas { display: block; max-width: 100%; max-height: 52dvh; width: auto; height: auto; border-radius: 4px; touch-action: none; cursor: grab; box-shadow: 0 0 0 1px var(--line); }
#cropCanvas:active { cursor: grabbing; }
.crop-size { margin: 10px 0 0; text-align: center; font-size: 12px; color: var(--muted); }
.crop-zoom { display: flex; align-items: center; gap: 12px; margin: 14px 0 4px; font-size: 13px; }
.crop-zoom input { flex: 1; accent-color: var(--accent); }
.crop-actions { display: grid; grid-template-columns: auto 1fr; gap: 10px; margin-top: 14px; }
.crop-actions .small-button { min-height: 50px; padding: 0 16px; border: 1px solid var(--line); background: var(--surface); color: var(--text); }
.card-actions .crop-button { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

/* v1.12 · 글씨 넣기 */
#textDialog { max-width: 480px; }
.text-stage { display: flex; justify-content: center; margin-top: 12px; padding: 12px; border-radius: 14px; background: var(--subtle); }
#textCanvas { display: block; max-width: 100%; max-height: 42dvh; width: auto; height: auto; border-radius: 4px; touch-action: none; cursor: move; }
.text-hint { margin: 8px 0 10px; text-align: center; font-size: 12px; color: var(--muted); }
#textInput { width: 100%; box-sizing: border-box; min-height: 64px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--text); font: inherit; font-size: 16px; resize: vertical; }
#textInput:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.text-row { display: flex; gap: 8px; margin-top: 10px; }
.text-row button { flex: 1; min-height: 42px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--text); font-size: 13px; }
.text-row button.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 700; }
.text-row.colors button { flex: 0 0 42px; height: 42px; padding: 0; background: var(--sw); border: 2px solid var(--line); }
.text-row.colors button.on { border: 3px solid var(--accent); box-shadow: 0 0 0 2px var(--panel) inset; }

/* v1.13 · 인스타 꾸미기 */
#decoDialog { max-width: 520px; }
#decoCanvas { display: block; max-width: 100%; max-height: 40dvh; width: auto; height: auto; border-radius: 4px; touch-action: none; cursor: grab; }
.deco-label { margin: 14px 0 6px; font-size: 13px; font-weight: 700; color: var(--text); }
.deco-filters { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 8px; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; }
.deco-filters button { flex: 0 0 76px; display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 4px; border: 2px solid transparent; border-radius: 12px; background: none; color: var(--muted); font-size: 11px; scroll-snap-align: start; }
.deco-filters img { width: 64px; height: 64px; object-fit: cover; border-radius: 9px; background: var(--subtle); }
.deco-filters button.on { border-color: var(--accent); color: var(--accent); font-weight: 700; }
.text-row.wrap { flex-wrap: wrap; }
.text-row.wrap button { flex: 1 1 auto; padding: 0 12px; }
.crop-zoom b { min-width: 42px; text-align: right; font-size: 12px; color: var(--muted); font-weight: 600; }
.tool.wide { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: flex-start; min-height: 0; gap: 14px; }

/* v1.14 · 얼굴 맞춤 · 배경 흰색 */
.spec-face { margin: 6px 0; padding: 10px 12px; border-radius: 10px; background: var(--accent-soft); color: var(--accent); font-size: 12px; line-height: 1.6; }
.whiten-all { width: 100%; margin: 4px 0 8px; }
.face-note.ok { color: var(--accent); }
.face-note.warn { color: #f0a04a; }
.crop-face { margin: 10px 0 0; padding: 9px 12px; border-radius: 10px; background: var(--accent-soft); color: var(--accent); font-size: 12px; line-height: 1.6; text-align: center; }
.crop-face.warn { background: rgba(240,160,74,.14); color: #f0a04a; }
.crop-actions.three { grid-template-columns: auto auto 1fr; }
.deco-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin: 14px 0 8px; padding: 4px; border-radius: 12px; background: var(--subtle); }
.deco-tabs button { min-height: 38px; border: 0; border-radius: 9px; background: none; color: var(--muted); font-size: 13px; font-weight: 600; }
.deco-tabs button.on { background: var(--panel); color: var(--text); box-shadow: 0 1px 2px rgba(0,0,0,.15); }
.crop-zoom.adj { margin: 6px 0; }
.crop-zoom.adj span { min-width: 46px; font-size: 12px; color: var(--muted); }
.deco-adj-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.deco-adj-actions .small-button { flex: 1 1 auto; }
.lang-toggle { font-size: 13px; font-weight: 800; letter-spacing: 0; }
.lang-menu { position: fixed; z-index: 1000; min-width: 180px; max-height: min(70vh, 440px); overflow: auto; padding: 6px; border-radius: 16px; background: var(--panel); color: var(--text); border: 1px solid var(--line); box-shadow: 0 12px 32px rgba(0,0,0,.18); display: grid; gap: 2px; }
.lang-menu button { text-align: left; padding: 11px 14px; border-radius: 10px; font-size: 15px; font-weight: 600; background: none; color: inherit; border: 0; }
.lang-menu button[aria-checked="true"] { background: var(--soft, rgba(127,127,127,.12)); font-weight: 800; }
.lang-menu button[aria-checked="true"]::after { content: " ✓"; }
.top-actions { gap: 8px; }
.apply-all { width: 100%; margin-top: 12px; }
/* v1.17 글씨 강화 */
.text-row[hidden] { display: none; }
.text-row.colors { flex-wrap: wrap; }
.text-row.colors { gap: 6px; }
.text-row.colors button { flex: 0 0 34px; height: 34px; }
.wm-ideas button { min-height: 36px; font-size: 12px; }
#textOpacityValue { min-width: 42px; text-align: right; font-size: 13px; color: var(--muted); }
.mask-note { margin: 8px 2px 0; font-size: 12px; color: var(--muted); line-height: 1.5; }
#maskCanvas { display: block; max-width: 100%; max-height: 46dvh; width: auto; height: auto; border-radius: 4px; touch-action: none; cursor: crosshair; }
@media (min-width: 761px) { .tool-grid { grid-template-columns: repeat(4, 1fr); } }
#printPreview { display: block; max-width: 100%; max-height: 46dvh; border-radius: 4px; box-shadow: 0 2px 10px rgba(0,0,0,.25); }
.print-summary { margin: 10px 2px 0; font-size: 15px; font-weight: 700; text-align: center; }

/* v1.18 앱 화면: 처음 화면(목록) ↔ 작업 화면 */
body[data-screen="home"] .work-bar,
body[data-screen="home"] .workspace-heading,
body[data-screen="home"] .workflow-switch,
body[data-screen="home"] .modes,
body[data-screen="home"] #pdfFlowHint,
body[data-screen="home"] .workspace { display: none !important; }
body[data-screen="work"] .home-hero,
body[data-screen="work"] .list-label,
body[data-screen="work"] .tool-list,
body[data-screen="work"] .trust-row,
body[data-screen="work"] .faq,
body[data-screen="work"] .workspace-heading,
body[data-screen="work"] .workflow-switch,
body[data-screen="work"] .modes { display: none !important; }
.list-label { margin: 22px 4px 10px; font-size: 13px; font-weight: 700; color: var(--muted); letter-spacing: -.01em; }
.tool-list { display: flex; flex-direction: column; gap: 8px; }
.tool-list .tool { flex-direction: row; align-items: center; justify-content: flex-start; gap: 14px; min-height: 72px; padding: 13px 14px 13px 14px; border-radius: 18px; background: var(--panel); color: var(--text); width: 100%; }
.tool-list .tool > span:not(.tool-icon) { flex: 1; min-width: 0; }
.tool-list .tool-icon { flex: 0 0 46px; width: 46px; height: 46px; border-radius: 14px; background: var(--lime); color: var(--on-lime); }
.tool-list .tool-icon svg { width: 23px; height: 23px; }
.tool-list .tool strong { font-size: 16.5px; letter-spacing: -.02em; }
.tool-list .tool small { font-size: 13px; margin-top: 4px; }
.tool-chev { flex: 0 0 20px; width: 20px; height: 20px; color: var(--muted); }
.tool-list .tool.active, .tool-list .tool.active small { background: var(--panel); color: var(--text); }
.tool-list .tool.active small { color: var(--muted); }
.tool-list .tool.active .tool-icon { background: var(--lime); }
.tool-list .tool:active { transform: scale(.985); background: var(--subtle); }
.home-hero { padding: 20px 20px 18px; }
.hero-value { font-size: 30px; }
.work-bar { display: flex; align-items: center; gap: 6px; margin: 2px 0 14px -6px; }
.work-bar h1 { margin: 0; font-size: 22px; font-weight: 800; letter-spacing: -.03em; }
.work-bar .icon-button { width: 44px; height: 44px; background: transparent; border: 0; }
.work-bar .icon-button svg { width: 26px; height: 26px; }
@media (min-width: 761px) {
  .tool-list { display: grid; grid-template-columns: 1fr 1fr; }
  .hero-value { font-size: 40px; }
}
/* 편집 바텀 시트 */
.card-actions .edit-button { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--subtle); color: var(--text); font-weight: 700; font-size: 13px; }
.card-actions .edit-button svg { width: 16px; height: 16px; color: var(--accent); }
.card-actions .crop-button { border-radius: 999px; padding: 8px 14px; font-weight: 700; }
dialog.sheet { position: fixed; inset: auto 0 0 0; margin: 0 auto; width: 100%; max-width: 560px; max-height: 80dvh; padding: 8px 16px calc(16px + env(safe-area-inset-bottom)); border: 0; border-radius: 24px 24px 0 0; background: var(--panel); color: var(--text); overflow: auto; }
dialog.sheet[open] { animation: sheet-up .22s ease-out; }
dialog.sheet::backdrop { background: rgba(0,0,0,.55); }
@keyframes sheet-up { from { transform: translateY(40%); opacity: .4; } to { transform: none; opacity: 1; } }
.sheet-grip { width: 40px; height: 4px; border-radius: 4px; background: var(--line); margin: 4px auto 12px; }
.sheet-title { margin: 0 4px 10px; font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sheet-list { display: flex; flex-direction: column; gap: 6px; }
.sheet-row { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 58px; padding: 8px 12px; border: 0; border-radius: 16px; background: var(--subtle); color: var(--text); font-size: 16px; font-weight: 700; text-align: left; }
.sheet-row:disabled { opacity: .4; }
.sheet-icon { flex: 0 0 40px; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--lime); color: var(--on-lime); }
.sheet-icon svg { width: 21px; height: 21px; }
.sheet-undo .sheet-icon { background: var(--line); color: var(--text); }
.sheet-cancel { width: 100%; min-height: 52px; margin-top: 10px; border: 0; border-radius: 16px; background: transparent; color: var(--muted); font-size: 15px; font-weight: 700; }
body[data-screen] .step-number { display: none; }
@media (max-width: 760px) { .photo-detail .card-actions { margin-left: 0; } }
.photo-card { align-items: center; }
/* 첫 실행 소개 */
dialog.onboard { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0 0 calc(20px + env(safe-area-inset-bottom)); border: 0; background: var(--bg); color: var(--text); overflow: hidden; display: none; flex-direction: column; }
dialog.onboard[open] { display: flex; }
dialog.onboard::backdrop { background: var(--bg); }
.ob-track { flex: 1; display: flex; transition: transform .3s ease; }
.ob-slide { flex: 0 0 100%; display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 24px 28px; text-align: center; }
.ob-art { height: 210px; display: grid; place-items: center; margin-bottom: 28px; }
.ob-slide h2 { margin: 0 0 12px; font-size: 26px; font-weight: 800; letter-spacing: -.03em; }
.ob-slide p { margin: 0; max-width: 320px; font-size: 15.5px; line-height: 1.6; color: var(--muted); }
.ob-big { display: flex; flex-direction: column; align-items: center; gap: 6px; font-weight: 800; letter-spacing: -.04em; }
.ob-big s { font-size: 26px; color: var(--muted); text-decoration-thickness: 3px; }
.ob-big b { font-size: 64px; color: var(--accent); }
.ob-icon { width: 130px; height: 130px; border-radius: 36px; background: var(--lime); color: var(--on-lime); display: grid; place-items: center; }
.ob-icon svg { width: 64px; height: 64px; }
.ob-chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; max-width: 300px; }
.ob-chips span { padding: 12px 16px; border-radius: 999px; background: var(--panel); font-weight: 700; font-size: 15px; }
.ob-chips span:nth-child(odd) { background: var(--lime); color: var(--on-lime); }
.ob-dots { display: flex; justify-content: center; gap: 8px; margin: 8px 0 18px; }
.ob-dots i { width: 7px; height: 7px; border-radius: 7px; background: var(--line); transition: width .2s; }
.ob-dots i.on { width: 22px; background: var(--accent); }
.ob-actions { display: flex; align-items: center; gap: 10px; padding: 0 20px; }
.ob-skip { flex: 0 0 auto; min-height: 54px; padding: 0 18px; border: 0; background: transparent; color: var(--muted); font-size: 15px; font-weight: 700; }
.ob-next { flex: 1; min-height: 56px; border-radius: 16px; font-size: 16.5px; }
/* 광고 자리: 나중에 아래 배너 광고를 붙일 때 --ad-h 만 바꾸면 하단 바·알림이 그 위로 올라간다. (지금은 0) */
:root { --ad-h: 0px; }
@media (max-width: 760px) { .mobile-bar { bottom: var(--ad-h); } body { padding-bottom: var(--ad-h); } }
.toast { bottom: calc(24px + var(--ad-h)); }
#adSlot { position: fixed; left: 0; right: 0; bottom: 0; height: var(--ad-h); z-index: 6; }
#adSlot:empty { display: none; }
body[data-screen="home"] .mobile-bar { display: none; }
/* v1.19 시안: 맨 위 큰 카드 + 기능별 색 */
.hero-targets { display: flex; gap: 8px; margin-top: 16px; }
.hero-targets button { flex: 1; min-height: 44px; border-radius: 12px; border: 1px solid var(--line); background: var(--subtle); color: var(--text); font-weight: 800; font-size: 15px; letter-spacing: -.02em; }
.hero-targets button.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.hero-go { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 56px; margin-top: 12px; border-radius: 16px; font-size: 16.5px; font-weight: 800; }
.hero-go svg { width: 22px; height: 22px; }
.tool-list .tool[data-color] .tool-icon { background: var(--ic); color: #111; }
.tool[data-color="lime"] { --ic: #c8f04a; }
.tool[data-color="clay"] { --ic: #e0906a; }
.tool[data-color="sky"] { --ic: #7cc8ff; }
.tool[data-color="coral"] { --ic: #ff8a7a; }
.tool[data-color="pink"] { --ic: #ff9cc6; }
.tool[data-color="yellow"] { --ic: #ffd84d; }
.tool[data-color="violet"] { --ic: #b9a2ff; }
.tool[data-color="mint"] { --ic: #6fe3c8; }
.tool[data-color="blue"] { --ic: #7fb2ff; }
body[data-screen="work"] .home-hero { display: none !important; }
/* 공간 확보 (전체 화면 창) */
.tool[data-color="orange"] { --ic: #ffb15c; }
dialog.fullsheet { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: var(--bg); color: var(--text); display: none; flex-direction: column; }
dialog.fullsheet[open] { display: flex; }
dialog.fullsheet::backdrop { background: var(--bg); }
.fs-head { display: flex; align-items: center; gap: 4px; padding: 10px 10px 4px; }
.fs-head h2 { margin: 0; font-size: 21px; font-weight: 800; letter-spacing: -.03em; }
.fs-head .icon-button { width: 44px; height: 44px; background: transparent; border: 0; }
.fs-head .icon-button svg { width: 26px; height: 26px; }
.fs-tabs { display: flex; gap: 6px; margin: 6px 16px 4px; padding: 4px; border-radius: 14px; background: var(--panel); }
.fs-tabs button { flex: 1; min-height: 42px; border: 0; border-radius: 11px; background: transparent; color: var(--muted); font-weight: 700; font-size: 14.5px; }
.fs-tabs button.on { background: var(--subtle); color: var(--text); }
.fs-tabs button { padding: 4px 2px; line-height: 1.2; }
.fs-tabs:has(> :nth-child(4)) button { font-size: 13.5px; }
/* 큰 동영상 목록 */
.fs-vlist { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.fs-vrow { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 14px; background: var(--panel); border: 2px solid transparent; }
.fs-vrow.on { border-color: #ff6b5e; }
.fs-vpick { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; padding: 0; border: 0; background: transparent; color: inherit; text-align: start; }
.fs-vthumb { position: relative; flex: none; width: 96px; height: 72px; border-radius: 10px; overflow: hidden; background: var(--subtle); }
.fs-vthumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fs-vdur { position: absolute; right: 4px; bottom: 4px; padding: 1px 5px; border-radius: 5px; background: rgba(0,0,0,.65); color: #fff; font-size: 11px; font-weight: 700; }
.fs-vthumb .fs-check { left: 5px; top: 5px; right: auto; }
.fs-vrow.on .fs-check { background: #ff6b5e; border-color: #ff6b5e; }
.fs-vrow.on .fs-check::after { content: "✕"; display: grid; place-items: center; height: 100%; color: #fff; font-size: 13px; font-weight: 900; }
.fs-vinfo { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.fs-vinfo strong { font-size: 18px; font-weight: 800; letter-spacing: -.02em; }
.fs-vinfo span { font-size: 12.5px; color: var(--muted); }
.fs-vshrink { flex: none; min-width: 64px; font-size: 13px; }
.fs-body { flex: 1; overflow-y: auto; padding: 10px 16px 24px; }
.fs-bar { padding: 10px 16px calc(12px + env(safe-area-inset-bottom) + var(--ad-h)); border-top: 1px solid var(--line); background: var(--bg); }
.fs-main { width: 100%; min-height: 54px; border-radius: 16px; font-size: 16px; font-weight: 800; }
#cleanDialog .fs-main.danger { background: #ff6b5e; color: #fff; }
.fs-empty { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 36px 8px 8px; }
.fs-empty h3 { margin: 18px 0 8px; font-size: 20px; font-weight: 800; letter-spacing: -.02em; }
.fs-empty p { margin: 0; color: var(--muted); line-height: 1.6; font-size: 14.5px; max-width: 340px; }
.fs-empty .fs-main { margin-top: 22px; }
.fs-badge { width: 84px; height: 84px; border-radius: 24px; display: grid; place-items: center; background: var(--ic, #ffb15c); color: #111; }
.fs-badge.ok { background: var(--lime); }
.fs-badge svg { width: 40px; height: 40px; }
.fs-points { margin: 16px 0 0; padding: 0; list-style: none; text-align: left; font-size: 13.5px; color: var(--muted); line-height: 1.7; }
.fs-points li::before { content: "✓ "; color: var(--accent); font-weight: 800; }
.fs-row { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.chip { min-height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); color: var(--text); font-size: 13.5px; font-weight: 600; }
.chip.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 800; }
.fs-summary { display: flex; flex-direction: column; gap: 3px; margin: 14px 2px 6px; }
.fs-summary strong { font-size: 26px; font-weight: 800; letter-spacing: -.03em; }
.fs-summary span, .fs-note, .fs-loading { font-size: 13px; color: var(--muted); line-height: 1.55; }
.fs-note { margin: 6px 2px 10px; }
.fs-loading { text-align: center; padding: 40px 0; }
.link-button { border: 0; background: none; padding: 0; color: var(--accent); font: inherit; font-weight: 700; text-decoration: underline; }
.fs-selrow { display: flex; justify-content: space-between; align-items: center; margin: 4px 2px 8px; font-size: 13.5px; font-weight: 700; }
.fs-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.fs-cell { position: relative; aspect-ratio: 1; padding: 0; border: 0; border-radius: 8px; overflow: hidden; background: var(--panel); }
.fs-cell img { width: 100%; height: 100%; object-fit: cover; display: block; transition: opacity .15s; }
.fs-cell:not(.on) img { opacity: .45; }
.fs-size { position: absolute; left: 5px; bottom: 5px; padding: 2px 6px; border-radius: 6px; background: rgba(0,0,0,.6); color: #fff; font-size: 11px; font-weight: 700; }
.fs-check { position: absolute; right: 6px; top: 6px; width: 22px; height: 22px; border-radius: 50%; border: 2px solid #fff; background: rgba(0,0,0,.25); }
.fs-cell.on .fs-check { background: var(--lime); border-color: var(--lime); }
.fs-cell.on .fs-check::after { content: "✓"; display: grid; place-items: center; height: 100%; color: #111; font-size: 13px; font-weight: 900; }
.fs-cell.del.on .fs-check { background: #ff6b5e; border-color: #ff6b5e; }
.fs-cell.del.on .fs-check::after { content: "✕"; color: #fff; }
.fs-cell.del.on img { opacity: .55; }
.fs-cell.del:not(.on) img { opacity: 1; }
.fs-star { position: absolute; left: 5px; bottom: 5px; padding: 2px 7px; border-radius: 6px; background: var(--lime); color: #111; font-size: 11px; font-weight: 800; }
.fs-group { margin-bottom: 16px; }
.fs-gtitle { margin: 0 2px 6px; font-size: 13px; font-weight: 700; color: var(--muted); }
.fs-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.fs-progress { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.fs-progress progress { flex: 1 1 100%; width: 100%; height: 8px; }
.fs-progress p { flex: 1; margin: 0; font-size: 13.5px; }
.ad-privacy { margin-left: auto; font-size: 12px; }
/* 광고 없이 쓰기 (보상형) */
.ad-free { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 64px; margin-top: 18px; padding: 12px 14px; border: 1px dashed var(--line); border-radius: 18px; background: transparent; color: var(--text); text-align: left; }
.ad-free > span:not(.ad-free-icon) { flex: 1; }
.ad-free strong { display: block; font-size: 15px; font-weight: 700; }
.ad-free small { display: block; margin-top: 3px; font-size: 12.5px; color: var(--muted); }
.ad-free-icon { flex: 0 0 40px; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--subtle); color: var(--accent); }
.ad-free-icon svg { width: 20px; height: 20px; }
.ad-free.on { border-style: solid; border-color: var(--accent); }
.ad-free.on .tool-chev { visibility: hidden; }
body[data-screen="work"] .ad-free { display: none; }

/* v1.23 증명사진 강화: 얼굴 맞춰 찍기, 배경색, 인화 용지·간격, 자르기 치수 */
.spec-camera { display: flex; align-items: center; gap: 12px; width: 100%; margin: 10px 0 4px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--subtle); color: var(--text); text-align: left; cursor: pointer; }
.spec-camera svg { width: 34px; height: 34px; padding: 7px; border-radius: 10px; background: #c8f04a; color: #111; fill: none; stroke: currentColor; stroke-width: 2; flex: none; }
.spec-camera span { display: flex; flex-direction: column; gap: 2px; }
.spec-camera strong { font-size: 15px; }
.spec-camera small { font-size: 12px; color: var(--muted); }
.cam-dialog { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; padding: 0 16px calc(16px + env(safe-area-inset-bottom)); border: 0; background: #0b0c0d; color: #f2f3f1; display: none; flex-direction: column; gap: 12px; }
.cam-dialog[open] { display: flex; }
.cam-head { display: flex; align-items: center; justify-content: space-between; padding-top: calc(10px + env(safe-area-inset-top)); }
.cam-head h2 { margin: 0; font-size: 18px; }
.cam-head .icon-button { color: #f2f3f1; }
.cam-stage { position: relative; width: min(100%, calc((100dvh - 250px) * .75)); margin: 0 auto; border-radius: 16px; overflow: hidden; background: #000; }
.cam-stage video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cam-stage video.mirror { transform: scaleX(-1); }
.cam-stage svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.cam-stage #camOval, .cam-stage #camShoulder { stroke: rgba(255,255,255,.9); transition: stroke .2s; }
.cam-stage.ok #camOval, .cam-stage.ok #camShoulder { stroke: #c8f04a; stroke-dasharray: none; }
.cam-status { position: absolute; left: 50%; bottom: 12px; transform: translateX(-50%); margin: 0; padding: 7px 14px; border-radius: 999px; background: rgba(0,0,0,.65); font-size: 14px; font-weight: 600; white-space: nowrap; max-width: 92%; overflow: hidden; text-overflow: ellipsis; }
.cam-stage.ok .cam-status { background: #c8f04a; color: #111; }
.cam-tip { margin: 0; text-align: center; font-size: 13px; color: #9aa0a6; line-height: 1.5; }
.cam-bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; margin-top: auto; }
.cam-flip { justify-self: start; width: 48px; height: 48px; color: #f2f3f1; }
.cam-shutter { width: 72px; height: 72px; border-radius: 50%; border: 5px solid #f2f3f1; background: #f2f3f1; box-shadow: inset 0 0 0 4px #0b0c0d; cursor: pointer; }
.cam-shutter:active { transform: scale(.94); }
.bg-swatches { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 6px 0 12px; }
.bg-swatches button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px; border: 1px solid var(--line); border-radius: 12px; background: var(--subtle); color: var(--text); font-size: 12px; cursor: pointer; }
.bg-swatches i { width: 40px; height: 52px; border-radius: 6px; box-shadow: 0 0 0 1px rgba(0,0,0,.15); }
.print-opts { display: flex; align-items: center; gap: 10px; margin: 8px 0; }
.print-opts > span { flex: none; width: 34px; font-size: 13px; color: var(--muted); }
.chip-row { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-row button { padding: 7px 11px; border: 1px solid var(--line); border-radius: 999px; background: var(--subtle); color: var(--text); font-size: 13px; cursor: pointer; }
.chip-row button[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); font-weight: 700; }
.crop-frame { display: grid; grid-template-columns: auto auto; grid-template-rows: auto auto; gap: 6px; align-items: center; justify-items: center; }
.crop-frame .cr-w { grid-column: 1; grid-row: 1; font-size: 11px; color: var(--muted); border-bottom: 1px solid var(--muted); width: 100%; text-align: center; padding-bottom: 2px; }
.crop-frame canvas { grid-column: 1; grid-row: 2; }
.crop-frame .cr-h { grid-column: 2; grid-row: 2; writing-mode: vertical-rl; font-size: 11px; color: var(--muted); border-left: 1px solid var(--muted); height: 100%; text-align: center; padding-left: 2px; }
.crop-frame .cr-w[hidden], .crop-frame .cr-h[hidden] { display: none; }

/* v1.23 선명하게 */
.sharp-stage { position: relative; width: 100%; max-height: 52dvh; margin: 0 auto; border-radius: 12px; overflow: hidden; background: var(--subtle); touch-action: none; cursor: ew-resize; }
.sharp-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.sharp-split { position: absolute; top: 0; bottom: 0; width: 0; border-left: 2px solid #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.25); pointer-events: none; }
.sharp-split i { position: absolute; top: 50%; left: -15px; width: 28px; height: 28px; margin-top: -14px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(0,0,0,.35); }
.sharp-tag { position: absolute; top: 8px; padding: 2px 8px; border-radius: 999px; background: rgba(0,0,0,.55); color: #fff; font-size: 12px; font-weight: 700; pointer-events: none; }
.sharp-tag.l { left: 8px; } .sharp-tag.r { right: 8px; }

/* v1.25 꾸미기 스티커 */
.deco-emojis { display: grid; grid-template-columns: repeat(auto-fill, minmax(44px, 1fr)); gap: 4px; max-height: 150px; overflow-y: auto; padding: 2px; }
.deco-emojis button { height: 44px; border: 0; border-radius: 10px; background: var(--subtle); font-size: 26px; line-height: 1; font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif; }
.deco-emojis button:active { transform: scale(.92); }
.deco-text-add { display: flex; gap: 8px; margin-bottom: 8px; }
.deco-text-add input { flex: 1; min-width: 0; height: 42px; padding: 0 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--text); font: inherit; font-size: 16px; }
#decoStickerPane .deco-label:first-child { margin-top: 4px; }
/* 스티커를 고르는 동안에도 미리보기가 보이게 위에 붙여 둔다 */
#decoDialog .text-stage { position: sticky; top: -1px; z-index: 3; box-shadow: 0 6px 12px -8px rgba(0,0,0,.35); }
#decoDialog .text-stage canvas { max-height: 38vh; width: auto; max-width: 100%; touch-action: none; }
/* v1.26 꾸미기 효과·커브 */
.deco-tabs { grid-template-columns: repeat(4, 1fr); }
.deco-curve { display: block; width: 100%; height: auto; aspect-ratio: 520 / 300; border-radius: 12px; background: var(--subtle); touch-action: none; cursor: ns-resize; }
.deco-label small { margin-left: 6px; font-weight: 500; font-size: 11px; color: var(--muted); }
.deco-note { margin: 4px 0 0; font-size: 12px; color: var(--muted); line-height: 1.5; }
/* v1.27 스티커 모음·스티커 만들기 */
.deco-packs { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 8px; -webkit-overflow-scrolling: touch; }
.deco-packs button { flex: 0 0 auto; min-height: 34px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; background: none; color: var(--muted); font: inherit; font-size: 13px; font-weight: 600; }
.deco-packs button.on { border-color: var(--lime); color: var(--text); background: color-mix(in srgb, var(--lime) 16%, transparent); }
.deco-emojis.labels { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
.deco-emojis .label-chip { font-family: inherit; font-size: 13px; font-weight: 800; color: var(--text); }
.deco-emojis .label-chip.fx-tape { background: repeating-linear-gradient(90deg, #ff9cc6aa 0 10px, #ffb8d6aa 10px 14px); color: #222; }
.deco-emojis .label-chip.fx-tag { background: #ffd84d; color: #111; }
.deco-emojis .label-chip.fx-badge { border: 2px solid #ff4d4f; color: #ff4d4f; background: none; }
.deco-emojis .label-chip.fx-neon { color: #fff; text-shadow: 0 0 6px #ff8fb8, 0 0 12px #ff8fb8; }
.deco-emojis .label-chip.fx-glow { color: #fff7c2; text-shadow: 0 0 10px #ffd43b; }
.deco-emojis .label-chip.fx-marker { background: linear-gradient(transparent 45%, #ffd43b99 45%); }
.deco-emojis.mine { grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); }
.deco-emojis.mine button { height: 64px; background: repeating-conic-gradient(#0000 0 25%, #8882 0 50%) 0 0 / 12px 12px; }
.deco-emojis.mine img { max-width: 56px; max-height: 56px; object-fit: contain; }
.deco-emojis.mine .make { font-family: inherit; font-size: 13px; font-weight: 700; color: var(--text); background: var(--subtle); }
#stickerDialog { max-width: 560px; }
.sm-stage { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: center; margin-top: 12px; padding: 12px; border-radius: 14px; background: var(--subtle); }
.sm-stage canvas { display: block; width: 100%; height: auto; max-height: 40dvh; object-fit: contain; border-radius: 6px; touch-action: none; }
#smOut { background: repeating-conic-gradient(#0000 0 25%, #8883 0 50%) 0 0 / 16px 16px; border-radius: 10px; }
.sm-busy { position: absolute; inset: 0; display: grid; place-items: center; margin: 0; border-radius: 14px; background: rgba(0,0,0,.45); color: #fff; font-weight: 700; }
.sm-busy[hidden] { display: none; }
.sm-tones { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 8px; }
.sm-tones button { flex: 0 0 72px; display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 4px; border: 2px solid transparent; border-radius: 12px; background: none; color: var(--muted); font-size: 11px; }
.sm-tones button.on { border-color: var(--lime); color: var(--text); }
.sm-tones img { width: 60px; height: 60px; object-fit: cover; border-radius: 9px; }
/* v1.28 잡티·부분 보정 */
#retouchDialog { max-width: 560px; }
#retouchDialog .rt-tools { grid-template-columns: 1fr 1fr; }
#rtCanvas { display: block; max-width: 100%; max-height: 46dvh; width: auto; height: auto; border-radius: 4px; touch-action: none; cursor: crosshair; }
#retouchDialog .rt-stage { position: sticky; top: -1px; z-index: 3; }

/* v1.29: 앱 안 사진 찍기 */
.cam-opts { display: grid; gap: 8px; }
.cam-chips { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.cam-chips button { min-height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid rgba(255,255,255,.22); background: rgba(255,255,255,.06); color: #f2f3f1; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.cam-chips button.on { background: #c8f04a; border-color: #c8f04a; color: #111; }
.cam-count { position: absolute; inset: 0; margin: 0; display: grid; place-items: center; font-size: 96px; font-weight: 800; color: #fff; text-shadow: 0 4px 24px rgba(0,0,0,.6); pointer-events: none; }
.cam-count[hidden] { display: none; }
.cam-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.cam-flash.go { animation: camFlash .35s ease-out; }
@keyframes camFlash { from { opacity: .85; } to { opacity: 0; } }
.cam-done { justify-self: end; display: flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; border-radius: 14px; border: 0; background: rgba(255,255,255,.1); color: #f2f3f1; font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; grid-column: 3; grid-row: 1; }
.cam-done img { width: 44px; height: 44px; object-fit: cover; border-radius: 10px; }
.cam-done[hidden] { display: none; }
.cam-bar .cam-spacer { grid-column: 3; grid-row: 1; }

/* v1.30: 꾸미기 화면을 사진 중심으로 (큰 사진 + 아래 아이콘 줄) */
#decoDialog { --text: #f2f3f1; --muted: #9aa0a6; --line: #2c3033; --subtle: #1d2022; --surface: #16191a; --panel: #0e1011; --accent: #c8f04a;
  width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; padding: 0; border: 0; border-radius: 0; background: #0b0c0d; color: var(--text); overflow: hidden; }
#decoDialog[open] { display: flex; flex-direction: column; }
#decoDialog .deco-top { flex: 0 0 auto; display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: 8px; padding: calc(8px + env(safe-area-inset-top)) 12px 6px; }
#decoDialog .deco-top h2 { margin: 0; text-align: center; font-size: 16px; font-weight: 700; }
#decoDialog .deco-x { width: 44px; height: 44px; border: 0; border-radius: 50%; background: none; color: var(--text); display: grid; place-items: center; cursor: pointer; }
#decoDialog .deco-x svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
#decoDialog .deco-done { min-height: 38px; padding: 0 16px; border: 0; border-radius: 999px; background: none; color: var(--accent); font: inherit; font-size: 16px; font-weight: 800; cursor: pointer; }
#decoDialog .text-stage { position: relative; flex: 1 1 auto; min-height: 120px; overflow: hidden; display: block; padding: 0; margin: 0; background: none; border: 0; box-shadow: none; border-radius: 0; }
#decoDialog .text-stage canvas, #decoCanvas { position: absolute; inset: 0; margin: auto; max-width: calc(100% - 24px); max-height: 100%; width: auto; height: auto; border-radius: 2px; }
#decoDialog .text-hint { flex: 0 0 auto; margin: 6px 16px 0; min-height: 0; text-align: center; font-size: 12px; color: var(--muted); }
#decoDialog .text-hint:empty { display: none; }
#decoDialog .deco-panel { flex: 0 1 auto; max-height: 38dvh; overflow-y: auto; padding: 8px 16px 4px; overscroll-behavior: contain; }
#decoDialog .deco-panel > div > .deco-label:first-child { margin-top: 2px; }
#decoDialog .deco-tools { flex: 0 0 auto; display: grid; grid-template-columns: repeat(8, minmax(44px, 1fr)); padding: 6px 2px; border-top: 1px solid var(--line); background: #0b0c0d; overflow-x: auto; scrollbar-width: none; }
#decoDialog .deco-tools button { display: flex; flex-direction: column; align-items: center; gap: 3px; min-height: 52px; padding: 0 1px; border: 0; background: none; color: var(--muted); font: inherit; font-size: 10.5px; font-weight: 600; letter-spacing: -.02em; white-space: nowrap; cursor: pointer; }
#decoDialog .deco-tools svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
#decoDialog .deco-tools button.on { color: var(--text); }
#decoDialog .deco-tools button.on svg { stroke: var(--accent); }
#decoDialog .deco-save-row { flex: 0 0 auto; display: flex; gap: 8px; padding: 4px 16px calc(10px + env(safe-area-inset-bottom)); }
#decoDialog .deco-save-row .primary { flex: 1; min-height: 46px; }
#decoDialog .deco-save-row .small-button[hidden] { display: none; }
/* 필터: 내 사진 미리보기 카드 */
#decoDialog .deco-filters button { flex: 0 0 72px; gap: 6px; padding: 0; border: 0; background: none; color: var(--muted); font-size: 11px; }
#decoDialog .deco-filters span { order: -1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 72px; }
#decoDialog .deco-filters img { width: 72px; height: 92px; border-radius: 6px; border: 2px solid transparent; }
#decoDialog .deco-filters button.on { color: var(--text); }
#decoDialog .deco-filters button.on img { border-color: var(--accent); }
/* 조절: 동그란 아이콘 + 막대 하나 */
.deco-dials { display: flex; gap: 14px; overflow-x: auto; padding: 4px 2px 6px; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; }
.deco-dials button { flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; gap: 6px; border: 0; background: none; color: var(--muted); font: inherit; font-size: 11px; font-weight: 600; cursor: pointer; scroll-snap-align: center; }
.deco-dials i { position: relative; width: 52px; height: 52px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center; color: var(--text); }
.deco-dials svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.deco-dials button.on { color: var(--text); }
.deco-dials button.on i { border-color: var(--accent); border-width: 2px; }
.deco-dials button.set i::after { content: ""; position: absolute; top: 2px; right: 2px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
#decoAdjustPane .crop-zoom.adj { margin: 10px 0 4px; }
/* 글씨: 모양 카드, 색 동그라미, 색조·채도·밝기 */
.deco-fonts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 6px 0 10px; }
.deco-fonts button { --c: #ff8fb8; display: flex; flex-direction: column; align-items: center; gap: 2px; min-height: 64px; padding: 6px 4px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--subtle); color: var(--muted); font: inherit; font-size: 11px; cursor: pointer; }
.deco-fonts button b { font-size: 20px; font-weight: 800; color: var(--c); line-height: 1.3; padding: 0 6px; border-radius: 6px; }
.deco-fonts button.on { border-color: var(--accent); color: var(--text); }
.deco-fonts .fx-neon b { color: #fff; text-shadow: 0 0 4px var(--c), 0 0 10px var(--c); }
.deco-fonts .fx-glow b { color: #fff; text-shadow: 0 0 10px var(--c), 0 0 18px var(--c); }
.deco-fonts .fx-marker b { color: #fff; background: linear-gradient(transparent 50%, color-mix(in srgb, var(--c) 70%, transparent) 50%); }
.deco-fonts .fx-outline b { color: var(--c); -webkit-text-stroke: 1.5px #111; paint-order: stroke fill; text-shadow: 0 0 0 #fff; }
.deco-fonts .fx-bubble b { color: #111; background: var(--c); border: 1.5px solid #111; border-radius: 10px; }
.deco-fonts .fx-tape b { color: #111; background: repeating-linear-gradient(90deg, color-mix(in srgb, var(--c) 80%, transparent) 0 8px, color-mix(in srgb, var(--c) 55%, transparent) 8px 11px); border-radius: 2px; }
.deco-fonts .fx-tag b { color: #111; background: var(--c); }
.deco-fonts .fx-badge b { color: var(--c); border: 2px solid var(--c); border-radius: 999px; font-size: 15px; }
.deco-swatches { display: flex; gap: 10px; overflow-x: auto; padding: 4px 2px; }
.deco-swatches button { flex: 0 0 30px; height: 30px; padding: 0; border-radius: 50%; background: var(--sw); border: 2px solid #fff; cursor: pointer; }
.deco-swatches button.on { box-shadow: 0 0 0 3px var(--accent); }
#decoTextPane .crop-zoom { margin: 10px 0 2px; }
#decoTextPane .crop-zoom span { min-width: 36px; font-size: 12px; color: var(--muted); }
#decoTextPane .crop-zoom input { -webkit-appearance: none; appearance: none; height: 6px; border-radius: 999px; }
#decoTextPane .crop-zoom.hue input { background: linear-gradient(90deg, #f00, #ff0, #0f0, #0ff, #00f, #f0f, #f00); }
#decoTextPane .crop-zoom.satr input { background: linear-gradient(90deg, hsl(var(--hue, 0) 0% 60%), hsl(var(--hue, 0) 100% 55%)); }
#decoTextPane .crop-zoom.lumr input { background: linear-gradient(90deg, #111, hsl(var(--hue, 0) 90% 55%), #fff); }
#decoTextPane .crop-zoom input::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%; background: #fff; border: 2px solid #111; box-shadow: 0 1px 4px rgba(0,0,0,.4); }
#decoTextPane .crop-zoom input::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 2px solid #111; }
#decoDialog .deco-packs button.on { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, transparent); }
#decoDialog .deco-emojis { max-height: 170px; }
#decoDialog .deco-curve { background: var(--subtle); }
#decoDialog .deco-fonts { display: flex; overflow-x: auto; gap: 8px; padding-bottom: 4px; }
#decoDialog .deco-fonts button { flex: 0 0 74px; min-height: 58px; }
#decoDialog .small-button { background: var(--subtle); color: var(--text); border: 1px solid var(--line); }
#decoDialog .deco-curve { max-height: 150px; width: auto; max-width: 100%; margin: 0 auto; }

/* 담은 사진: 사진을 누르면 편집 화면이 열린다 */
.photo-thumb-edit { cursor: pointer; transition: transform .12s ease, opacity .12s ease; -webkit-tap-highlight-color: transparent; }
.photo-thumb-edit:active { transform: scale(.94); opacity: .85; }
.photo-thumb-edit:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
/* v1.31: 레이아웃(여러 장 한 장에), 사진 겹치기, 배경색 */
.deco-layouts { display: flex; gap: 10px; overflow-x: auto; padding: 4px 2px 8px; -webkit-overflow-scrolling: touch; }
.deco-layouts button { flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; gap: 5px; width: 58px; padding: 0; border: 0; background: none; color: var(--muted); font: inherit; font-size: 10.5px; font-weight: 600; cursor: pointer; }
.deco-layouts span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 58px; }
.deco-layouts svg { width: 42px; height: 56px; padding: 3px; border: 2px solid transparent; border-radius: 9px; }
.deco-layouts .lt-bg { fill: var(--subtle); }
.deco-layouts .lt-c { fill: #5b6166; }
.deco-layouts .lt-1 { fill: #7c8388; }
.deco-layouts .lt-2 { fill: #474c50; }
.deco-layouts button.on { color: var(--text); }
.deco-layouts button.on svg { border-color: var(--accent); }
.deco-layouts button.on .lt-c { fill: color-mix(in srgb, var(--accent) 70%, #333); }
.deco-layouts button.on .lt-1 { fill: color-mix(in srgb, var(--accent) 45%, #333); }
.deco-layouts button.on .lt-2 { fill: color-mix(in srgb, var(--accent) 30%, #333); }
.deco-photo-pick { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 6px; -webkit-overflow-scrolling: touch; }
.deco-photo-pick button { flex: 0 0 64px; height: 64px; padding: 0; border: 1.5px solid var(--line); border-radius: 12px; background: var(--subtle); overflow: hidden; cursor: pointer; }
.deco-photo-pick button:active { transform: scale(.94); }
.deco-photo-pick img { width: 100%; height: 100%; object-fit: cover; display: block; }
.deco-photo-pick .pick-album { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--text); font: inherit; font-size: 10.5px; font-weight: 600; border-style: dashed; }
.deco-photo-pick .pick-album svg { width: 22px; height: 22px; fill: none; stroke: var(--accent); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.deco-bgs button { border-color: rgba(255,255,255,.55); }
.deco-bgs .bg-auto { background: conic-gradient(from 0deg, #ffb3c1, #ffe08a, #b9f0c9, #a9d4ff, #d3b8ff, #ffb3c1); }
.deco-bgs .bg-auto.on { background: var(--sw); }
#decoLayoutPane .crop-zoom, #decoSelRow .crop-zoom { margin: 8px 0 2px; }
#decoShapeRow .text-row { margin-top: 8px; }

/* 결과 카드가 길어져도 사진은 왼쪽 위(파일 이름 옆)에 둔다 */
.photo-card > .photo-thumb { align-self: start; }
:root[dir="rtl"] .brand { direction: ltr; }

/* ---- 동영상 용량 줄이기 ---- */
.vid-badge { --ic: #7fb2ff; }
.vid-src { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 16px; background: var(--panel); margin-bottom: 16px; }
.vid-src img, .vid-thumb-empty { width: 64px; height: 64px; border-radius: 12px; object-fit: cover; background: var(--subtle); flex: none; display: grid; place-items: center; }
.vid-thumb-empty svg { width: 28px; height: 28px; }
.vid-src > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.vid-src strong { font-size: 15px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vid-src span { font-size: 13px; color: var(--muted); }
.vid-q { margin: 4px 2px 10px; font-size: 17px; font-weight: 800; letter-spacing: -.02em; }
.vid-presets { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.vid-preset { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; min-height: 72px; padding: 12px 14px; border-radius: 16px; border: 1.5px solid transparent; background: var(--panel); color: var(--text); text-align: left; }
.vid-preset strong { font-size: 22px; font-weight: 800; letter-spacing: -.03em; }
.vid-preset small { font-size: 12.5px; color: var(--muted); }
.vid-preset.on { border-color: var(--lime); background: var(--subtle); }
.vid-preset.on strong { color: var(--lime); }
:root[data-theme="light"] .vid-preset.on strong { color: var(--text); }
.vid-custom { margin: 10px 0 4px; }
.vid-audio { margin: 8px 0 4px; }
.vid-est { display: flex; flex-direction: column; gap: 4px; margin: 12px 0 6px; padding: 14px 16px; border-radius: 16px; background: var(--subtle); }
.vid-est strong { font-size: 16px; font-weight: 800; }
.vid-est span { font-size: 13.5px; color: var(--muted); line-height: 1.5; }
.vid-est.warn { background: rgba(255, 107, 94, .14); }
.vid-est.warn strong { color: #ff6b5e; }
.vid-est.ok strong { color: var(--accent); }
.vid-done { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 18px 8px 6px; }
.vid-done-badge { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; background: var(--lime); color: #111; }
.vid-done-badge.warn { background: #ffb15c; }
.vid-done-badge svg { width: 32px; height: 32px; }
.vid-done-size { margin: 16px 0 10px; font-size: 22px; font-weight: 700; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.vid-done-size b { font-size: 34px; font-weight: 800; color: var(--text); letter-spacing: -.03em; }
.vid-done-size svg { width: 20px; height: 20px; }
.vid-done .hero-bar { width: 100%; max-width: 320px; }
.vid-done-cap { margin: 12px 0 4px; font-size: 15px; font-weight: 700; }
.vid-done-meta { margin: 0; font-size: 13px; color: var(--muted); }
.vid-again { display: block; margin: 18px auto 0; }
.vid-actions { display: grid; grid-template-columns: 1fr 1.6fr; gap: 8px; }
.vid-actions button { min-height: 54px; border-radius: 16px; font-size: 16px; font-weight: 800; }

/* v1.34 공간 확보 탭이 6개라 옆으로 밀어 보는 줄로 */
.fs-tabs:has(> :nth-child(5)) { overflow-x: auto; scrollbar-width: none; scroll-snap-type: x proximity; }
.fs-tabs:has(> :nth-child(5))::-webkit-scrollbar { display: none; }
.fs-tabs:has(> :nth-child(5)) button { flex: 0 0 auto; padding: 4px 13px; font-size: 14px; white-space: nowrap; scroll-snap-align: center; }
.fs-total { margin-top: 10px !important; font-weight: 800; color: var(--accent) !important; }
#cleanDialog .fs-empty .text-button { margin-top: 14px; }
/* v1.34 정리 기록 */
.hist-link { display: inline-flex; flex-direction: row-reverse; align-items: center; gap: 2px; margin: 2px 0 10px; padding: 0; font-size: 13.5px; font-weight: 700; color: var(--accent); }
.hist-link svg { width: 16px; height: 16px; }
[dir="rtl"] .hist-link svg { transform: scaleX(-1); }
.hist-hero { padding: 20px 18px; border-radius: 22px; background: var(--panel); margin-bottom: 12px; }
.hist-value { margin: 6px 0 4px; font-size: 46px; font-weight: 900; letter-spacing: -.04em; color: var(--accent); line-height: 1.05; }
.hist-sub { margin: 0; font-size: 14px; color: var(--muted); font-weight: 600; }
.hist-card { padding: 16px 16px 8px; border-radius: 20px; background: var(--panel); margin-bottom: 12px; }
.hist-h { margin: 0 0 12px; font-size: 15px; font-weight: 800; }
.hist-kind { margin-bottom: 12px; }
.hist-kind-top { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; margin-bottom: 6px; }
.hist-kind-top strong { font-weight: 800; }
.hist-bar { height: 8px; border-radius: 4px; background: var(--subtle); overflow: hidden; }
.hist-bar i { display: block; height: 100%; border-radius: 4px; }
.hist-list { list-style: none; margin: 0; padding: 0; }
.hist-list li { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); }
.hist-list li:first-child { border-top: 0; }
.hist-dot { flex: none; width: 10px; height: 10px; border-radius: 50%; }
.hist-what { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.hist-what strong { font-size: 14.5px; font-weight: 700; }
.hist-what small { font-size: 12.5px; color: var(--muted); }
.hist-list b { font-size: 15px; font-weight: 800; }
.hist-foot { text-align: center; }
.hist-go { margin-top: 8px; }
.hist-link[hidden] { display: none; }
#cleanDialog .fs-empty .text-button { color: var(--accent); font-size: 14px; font-weight: 700; }

/* ---- 1.35 오늘의 정리 5분 · 연속 기록 · N년 전 오늘 ---- */
.daily-card { display: flex; align-items: center; gap: 14px; width: 100%; margin: 12px 0 0; padding: 14px; border: 0; border-radius: 20px; background: var(--panel); color: var(--text); text-align: start; }
.daily-card[hidden] { display: none; }
.daily-card:active { transform: scale(.985); background: var(--subtle); }
body[data-screen="work"] .daily-card { display: none !important; }
.daily-flame { position: relative; flex: 0 0 46px; width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: var(--subtle); color: var(--muted); }
.daily-flame svg { width: 24px; height: 24px; }
.daily-card.lit .daily-flame { background: #ff9d4d; color: #2a1200; }
.daily-card.lit .daily-flame svg { fill: #ffd27a; }
.daily-flame b { position: absolute; right: -6px; bottom: -6px; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 11px; background: var(--accent); color: var(--bg); font-size: 12px; font-weight: 900; line-height: 22px; text-align: center; }
.daily-flame b:empty { display: none; }
.daily-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.daily-text strong { font-size: 16.5px; font-weight: 800; letter-spacing: -.02em; }
.daily-text small { font-size: 13px; color: var(--muted); }
.daily-card.done .daily-text strong { color: var(--accent); }

.dl-hero { padding: 18px; border-radius: 22px; background: var(--panel); margin-bottom: 12px; display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; align-items: center; }
.dl-flame { width: 58px; height: 58px; border-radius: 18px; display: grid; place-items: center; background: var(--subtle); color: var(--muted); }
.dl-flame svg { width: 32px; height: 32px; }
.dl-flame.lit { background: #ff9d4d; color: #2a1200; }
.dl-flame.lit svg { fill: #ffd27a; }
.dl-hero-text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.dl-hero-text strong { font-size: 28px; font-weight: 900; letter-spacing: -.04em; line-height: 1.1; }
.dl-hero-text span { font-size: 13.5px; color: var(--muted); font-weight: 600; }
.dl-hero.pop .dl-flame { animation: dl-pop .8s ease; }
@keyframes dl-pop { 0% { transform: scale(1); } 35% { transform: scale(1.25) rotate(-8deg); } 70% { transform: scale(.95); } 100% { transform: scale(1); } }
.dl-week { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin-top: 10px; }
.dl-day { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.dl-day i { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--subtle); }
.dl-day i svg { width: 16px; height: 16px; stroke-width: 2.6; }
.dl-day.on i { background: #ff9d4d; color: #2a1200; }
.dl-day.today i { box-shadow: 0 0 0 2px var(--accent); }
.dl-day.later i { opacity: .45; }
.dl-day small { font-size: 11.5px; color: var(--muted); font-weight: 700; }
.dl-today .hist-h { margin-bottom: 10px; }
.dl-result { margin: 0 0 10px; font-size: 22px; font-weight: 800; color: var(--accent); letter-spacing: -.02em; }
.dl-peek { display: flex; padding: 4px 0 6px; }
.dl-peek-item { width: 64px; height: 64px; border-radius: 14px; overflow: hidden; border: 3px solid var(--panel); margin-inline-start: -14px; transform: rotate(calc((var(--i) - 2) * 4deg)); background: var(--subtle); box-shadow: 0 2px 8px rgba(0,0,0,.18); }
.dl-peek-item:first-child { margin-inline-start: 0; }
.dl-peek-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.dl-mem { padding-bottom: 6px; }
.dl-memrow { display: block; width: 100%; padding: 0 0 12px; margin: 0 0 12px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: inherit; text-align: start; }
.dl-memrow:last-of-type { border-bottom: 0; margin-bottom: 0; }
.dl-memhead { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.dl-memhead strong { font-size: 15px; font-weight: 800; }
.dl-memhead small { font-size: 12.5px; color: var(--muted); }
.dl-strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; }
.dl-strip img, .dl-more { width: 100%; aspect-ratio: 1; border-radius: 10px; object-fit: cover; display: block; background: var(--subtle); }
.dl-more { display: grid; place-items: center; font-size: 14px; font-weight: 800; color: var(--muted); }
.dl-weekly { padding-bottom: 14px; }
.dl-wk-top { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 12px; }
.dl-bell { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--subtle); }
.dl-bell.on { background: var(--lime); color: #111; }
.dl-wk-text { display: flex; flex-direction: column; gap: 3px; }
.dl-wk-text strong { font-size: 15px; font-weight: 800; }
.dl-wk-text small { font-size: 13px; color: var(--muted); line-height: 1.5; }
.dl-wk-btn { width: 100%; min-height: 44px; border-radius: 14px; font-weight: 800; }
.dl-histlink { display: block; margin: 6px auto 0; color: var(--accent); font-weight: 700; }
.dl-badge { background: #ff9d4d; }
#dailyDialog .fs-main.danger { background: #ff6b5e; color: #fff; }

/* 넘겨 보기 */
.dl-stage { display: flex; flex-direction: column; height: 100%; min-height: 420px; }
.dl-progress { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 800; margin-bottom: 12px; }
.dl-pbar { flex: 1; height: 6px; border-radius: 3px; background: var(--subtle); overflow: hidden; }
.dl-pbar i { display: block; height: 100%; background: #ff9d4d; border-radius: 3px; transition: width .2s; }
.dl-deck { position: relative; flex: 1; min-height: 340px; }
.dl-card { position: absolute; inset: 0; border-radius: 24px; overflow: hidden; background: var(--panel); box-shadow: 0 10px 30px rgba(0,0,0,.25); touch-action: none; user-select: none; -webkit-user-select: none; }
.dl-card img { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.dl-card.under { transform: scale(.94) translateY(12px); opacity: .7; }
.dl-card.fly { transition: transform .22s ease-out; }
.dl-stamp { position: absolute; top: 22px; padding: 6px 14px; border: 3px solid currentColor; border-radius: 12px; font-size: 24px; font-weight: 900; letter-spacing: .02em; background: rgba(0,0,0,.35); opacity: 0; transition: opacity .1s; }
.dl-stamp.drop { right: 18px; color: #ff6b5e; transform: rotate(10deg); }
.dl-stamp.keep { left: 18px; color: #c8f04a; transform: rotate(-10deg); }
.dl-card.show-drop .dl-stamp.drop, .dl-card.show-keep .dl-stamp.keep { opacity: 1; }
.dl-meta { margin: 12px 0 2px; text-align: center; font-size: 14px; font-weight: 700; }
.dl-hint { margin: 0; text-align: center; font-size: 12.5px; color: var(--muted); }
.dl-actions { display: grid; grid-template-columns: 1fr auto 1fr; gap: 10px; }
.dl-btn { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 56px; border-radius: 18px; border: 0; font-size: 16px; font-weight: 800; }
.dl-btn svg { width: 22px; height: 22px; stroke-width: 2.4; }
.dl-btn.drop { background: #ff6b5e; color: #fff; }
.dl-btn.keep { background: var(--lime); color: #111; }
.dl-btn.undo { width: 56px; background: var(--panel); color: var(--text); }
.dl-btn.undo:disabled { opacity: .35; }
.hist-streak { display: flex; align-items: center; gap: 6px; margin: 10px 0 0; font-size: 14px; font-weight: 800; color: #ff9d4d; }
.hist-streak svg { width: 18px; height: 18px; fill: #ffd27a; }
.hist-streak small { margin-inline-start: auto; color: var(--muted); font-weight: 700; font-size: 12.5px; }
#dailyDialog .fs-body { overflow-x: hidden; }

/* 업데이트 소식(whatsnew.js): 업데이트 뒤 처음 열 때 한 번 */
dialog.whatsnew { padding-left: 20px; padding-right: 20px; }
.wn-kicker { margin: 4px 0 2px; font-size: 13px; font-weight: 800; color: var(--accent); }
dialog.whatsnew h2 { margin: 0 0 14px; font-size: 23px; font-weight: 800; letter-spacing: -.03em; }
.wn-list { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 8px; }
.wn-item { display: flex; align-items: center; gap: 14px; width: 100%; padding: 12px; border: 0; border-radius: 16px; background: var(--bg); color: var(--text); text-align: start; font: inherit; }
button.wn-item:active { transform: scale(.985); }
.wn-icon { flex: 0 0 46px; width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; color: #111; }
.wn-icon svg { width: 24px; height: 24px; }
.wn-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.wn-text strong { font-size: 16px; font-weight: 800; letter-spacing: -.02em; }
.wn-text small { font-size: 13.5px; line-height: 1.45; color: var(--muted); }
.wn-chev { flex: 0 0 18px; width: 18px; height: 18px; color: var(--muted); }
.wn-ok { width: 100%; min-height: 54px; border-radius: 16px; font-size: 16px; font-weight: 800; }
[dir="rtl"] .wn-chev { transform: scaleX(-1); }
dialog.whatsnew .wn-ok:focus { outline: none; }
