/* 0.4의 한지·먹·인주를 이어 쓰는, 손가락으로 읽는 짧은 놀이. */
html { background: #d2cfc4; }
body { display: block; height: auto; min-height: 100svh; overflow: auto; overscroll-behavior-y: none; user-select: auto; -webkit-user-select: auto; }
body.quick-mode #stage, body.quick-mode #word, body.quick-mode #live { display: none; }
body.legacy-mode { display: flex; height: 100svh; overflow: hidden; }
body.legacy-mode #quick-app { display: none; }
#quick-app { --paper: #e3e1d9; --ink: #161513; --quiet: #57534b; --red: #b62f1c; width: min(100%, 520px); min-height: 100svh; margin: 0 auto; padding: 23px 25px max(27px, env(safe-area-inset-bottom)); box-sizing: border-box; background: var(--paper); color: var(--ink); font-family: "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif; -webkit-tap-highlight-color: transparent; }
#quick-app *, #quick-app *::before, #quick-app *::after { box-sizing: border-box; }
#quick-app ::selection { background: #b62f1c; color: #fff9ed; }
#quick-app button, #quick-app input { font: inherit; }
#quick-app button { cursor: pointer; color: inherit; touch-action: manipulation; }
#quick-app button:focus-visible, #quick-app input:focus-visible, #quick-app a:focus-visible, #quick-return:focus-visible { outline: 2px solid var(--red, #b62f1c); outline-offset: 5px; }
#quick-app button:disabled { cursor: wait; opacity: .6; }
.q-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 38px; }
.q-wordmark { font-size: 15px; font-weight: 800; letter-spacing: -.025em; text-decoration: none; color: inherit; border: 0; background: none; padding: 8px 0; }
.q-top-actions { display: flex; gap: 15px; }
.q-text-button { border: 0; background: none; padding: 9px 0; font-size: 13px; color: var(--quiet) !important; text-decoration: underline; text-underline-offset: 4px; }
.q-intro { padding: 29px 0 0; }
.q-title { margin: 0; line-height: 1; }
.q-title canvas { display: block; width: 100%; max-width: 360px; height: auto; }
.q-lead { margin: 17px 0 0; color: var(--quiet); font-size: 15px; line-height: 1.65; word-break: keep-all; }
.q-prompt { margin: 28px 0 12px; font-size: 18px; font-weight: 750; letter-spacing: -.035em; }
.q-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.q-option { min-height: 47px; border: 1px solid #9d988b; border-radius: 4px 7px 3px 6px; background: transparent; font-size: 16px; font-weight: 650; }
.q-option[aria-pressed="true"] { background: var(--ink); color: #f7f3e9 !important; border-color: var(--ink); }
.q-custom { margin-top: 12px; display: flex; gap: 10px; align-items: center; }
.q-custom label { font-size: 13px; flex: 0 0 auto; color: var(--quiet); }
.q-custom input { width: 100%; min-width: 0; min-height: 43px; border: 0; border-bottom: 1px solid #9d988b; border-radius: 0; background: transparent; color: var(--ink); padding: 8px 1px; caret-color: var(--red); font-size: 16px; }
.q-custom input::placeholder { color: #706a5f; opacity: 1; }
.q-primary, .q-secondary { width: 100%; min-height: 52px; border-radius: 3px 9px 4px 7px; padding: 13px 15px; font-size: 16px; font-weight: 750; line-height: 1.5; }
.q-primary { border: 1px solid var(--ink); background: var(--ink); color: #faf7ee !important; }
.q-secondary { border: 1px solid #8c877a; background: transparent; }
.q-start { margin-top: 22px; }
.q-footnote { margin: 12px 0 0; color: var(--quiet); font-size: 12px; line-height: 1.65; word-break: keep-all; }
.q-end { margin: 24px 0 0; display: flex; align-items: center; justify-content: space-between; gap: 14px; border-top: 1px solid #b6b0a3; padding-top: 13px; }
.q-end span { color: var(--quiet); font-size: 12px; }
.q-stage-heading { margin: 30px 0 8px; font-size: 26px; line-height: 1.35; letter-spacing: -.04em; }
.q-stage-sub { margin: 0; color: var(--quiet); font-size: 14px; line-height: 1.7; }
.q-rock-button { display: block; position: relative; width: 100%; height: clamp(280px, 45svh, 380px); margin: 12px 0 0; padding: 0; border: 0; background: transparent; overflow: visible; touch-action: manipulation; -webkit-user-select: none; user-select: none; }
.q-rock-button canvas { width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.q-taps { display: flex; justify-content: center; gap: 11px; min-height: 16px; margin: 7px 0 14px; }
.q-tap { width: 8px; height: 8px; border: 1px solid #8c877a; border-radius: 50%; }
.q-tap.done { background: var(--ink); border-color: var(--ink); }
.q-count { text-align: center; margin: 0; min-height: 30px; font-size: 19px; font-weight: 700; font-variant-numeric: tabular-nums; }
.q-calm { margin: 12px 0 0; text-align: center; color: var(--quiet); font-size: 13px; }
.q-arrival { margin: 26px 0 0; padding-bottom: 20px; border-bottom: 1px solid #b6b0a3; }
.q-arrival h1 { font-size: 31px; line-height: 1.35; letter-spacing: -.04em; margin: 0 0 10px; }
.q-faces { display: grid; gap: 14px; align-items: end; margin: 16px 0 3px; }
.q-face { min-width: 0; text-align: center; margin: 0; }
.q-face canvas { display: block; width: 100%; max-height: 340px; object-fit: contain; margin: 0 auto; }
.q-arrival + .q-faces .q-face canvas { max-height: 210px; }
.q-face figcaption { margin-top: 5px; font-size: 13px; line-height: 1.7; color: var(--quiet); overflow-wrap: anywhere; }
.q-face strong { color: var(--ink); display: block; font-size: 16px; }
.q-result-face { margin: 5px auto 0; width: min(77%, 280px); }
.q-result-face canvas { display: block; width: 100%; height: auto; }
.q-result-context { text-align: center; font-size: 13px; color: var(--quiet); margin: 8px 0 0; }
.q-result-title { text-align: center; font-size: 30px; line-height: 1.3; letter-spacing: -.04em; margin: 24px 0 0; }
.q-result-quote { margin: 15px auto 0; max-width: 25ch; font-size: 20px; line-height: 1.55; text-align: center; font-weight: 650; word-break: keep-all; }
.q-stamp { margin: 16px auto 15px; width: fit-content; transform: rotate(-5deg); border: 2px solid var(--red); color: var(--red); padding: 5px 7px; font-weight: 800; font-size: 17px; letter-spacing: -.03em; }
.q-actions { display: grid; gap: 10px; margin-top: 21px; }
.q-privacy { display: flex; align-items: flex-start; gap: 9px; margin: 18px 0 0; font-size: 13px; color: var(--quiet); line-height: 1.7; }
.q-privacy input { flex: 0 0 auto; margin-top: 4px; width: 17px; height: 17px; accent-color: var(--red); }
.q-inline { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; margin-top: 12px; }
.q-separator { height: 1px; background: #b6b0a3; margin: 24px 0; }
.q-card-preview { width: min(100%, 250px); aspect-ratio: 9/16; display: block; margin: 18px auto; background: var(--paper); box-shadow: 0 8px 22px #3c322325; }
.q-message { padding: 12px 0; margin: 8px 0; color: var(--quiet); font-size: 13px; line-height: 1.8; white-space: pre-line; }
.q-error { color: #8e2010; }
.q-gift-options { display: flex; flex-wrap: wrap; gap: 8px; margin: 15px 0; }
.q-gift-options button { border: 1px solid #8c877a; background: transparent; padding: 10px 12px; border-radius: 4px; min-height: 44px; }
.q-gift-options button[aria-pressed="true"] { background: var(--ink); color: #faf7ee !important; }
.q-copy-area { width: 100%; min-height: 90px; border: 1px solid #8c877a; background: transparent; border-radius: 3px; padding: 10px; color: var(--ink); font: inherit; font-size: 13px; line-height: 1.7; }
.q-history { margin-top: 20px; padding: 0; list-style: none; }
.q-history button { display: flex; width: 100%; align-items: center; gap: 16px; border: 0; border-bottom: 1px solid #b6b0a3; background: transparent; padding: 12px 0; text-align: left; }
.q-history canvas { width: 48px; height: 64px; object-fit: contain; }
.q-history span { flex: 1; font-size: 14px; line-height: 1.7; }
.q-history small { display: block; color: var(--quiet); font-size: 12px; }
.q-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; clip: rect(0,0,0,0); overflow: hidden; white-space: nowrap; border: 0; }
#quick-return { position: fixed; left: 50%; bottom: 8px; transform: translateX(-50%); z-index: 5; border: 1px solid #161513; background: #e3e1d9; color: #161513; padding: 8px 15px; font: 13px "Apple SD Gothic Neo", sans-serif; border-radius: 3px; white-space: nowrap; }
@media (min-width: 700px) { #quick-app { min-height: calc(100svh - 40px); margin-top: 20px; margin-bottom: 20px; padding: 26px 36px 30px; } .q-intro { padding-top: 30px; } }
@media (max-width: 359px) { #quick-app { padding-left: 18px; padding-right: 18px; } .q-intro { padding-top: 22px; } .q-title canvas { width: 100%; } .q-prompt { margin-top: 23px; } .q-top-actions { gap: 12px; } .q-result-title { font-size: 26px; } .q-result-quote { font-size: 18px; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; } }

#quick-app .q-text-button, #quick-app .q-wordmark { min-height: 44px; }
