/* 휴대폰 앱 화면. 대비: 글 #111 / 흰 바탕 18.9:1, 흰 글 / #0b57d0 6.4:1, #3c4043 / #f1f3f4 9.2:1 (WCAG 2.2 1.4.3 AA 4.5:1 넘음)
   터치: 모든 버튼 최소 48×48px (WCAG 2.2 2.5.8 최소 24px, 안드로이드·애플 권장 48dp/44pt) */
:root { --fs: 19px; --blue: #0b57d0; --ink: #111; --sub: #3c4043; --line: #c4c7c5; --bg2: #f1f3f4; --ok: #0d652d; }
html.big { --fs: 23px; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font: var(--fs)/1.5 system-ui, -apple-system, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif; color: var(--ink); background: #fff; display: flex; flex-direction: column; padding-bottom: env(safe-area-inset-bottom); }
button { font: inherit; min-height: 48px; min-width: 48px; border-radius: 14px; border: 1px solid var(--line); background: #fff; color: var(--ink); cursor: pointer; touch-action: manipulation; }
button:focus-visible, textarea:focus-visible { outline: 3px solid #e37400; outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.top { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px; border-bottom: 1px solid var(--line); }
.shop { font-weight: 700; font-size: 1.05em; }
.mode { font-size: .7em; font-weight: 600; margin-left: 8px; padding: 2px 8px; border-radius: 8px; background: #fef7e0; color: #5f3b00; }
.topbtns { display: flex; gap: 8px; }
.tbtn { padding: 0 12px; font-size: .85em; }
.tbtn[aria-pressed="true"] { background: var(--blue); color: #fff; border-color: var(--blue); }
.chat { flex: 1; overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 88%; padding: 10px 14px; border-radius: 18px; white-space: pre-wrap; word-break: keep-all; overflow-wrap: anywhere; }
.me { align-self: flex-end; background: var(--blue); color: #fff; border-bottom-right-radius: 6px; }
.ai { align-self: flex-start; background: var(--bg2); color: var(--ink); border-bottom-left-radius: 6px; }
.ai .rec1 { font-weight: 700; display: block; margin-bottom: 4px; }
.card { align-self: stretch; border: 2px solid var(--blue); border-radius: 18px; padding: 12px 14px; background: #fff; }
.card .what { font-weight: 700; margin: 0 0 4px; }
.card .why { color: var(--sub); margin: 0 0 10px; font-size: .9em; }
.card .row { display: flex; gap: 10px; justify-content: flex-end; }
.row { display: flex; gap: 10px; }
.primary { background: var(--blue); color: #fff; border-color: var(--blue); font-weight: 700; }
.ghost { background: #fff; }
.big { min-height: 56px; padding: 0 22px; flex: 1; }
.card .primary { flex: 1.4; }
.done { color: var(--ok); font-weight: 700; }
.thumbs { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.thumbs img { width: 96px; height: 96px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.quick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 8px 12px; border-top: 1px solid var(--line); }
.quick button { font-size: .85em; font-weight: 600; min-height: 52px; padding: 4px; background: var(--bg2); border-color: transparent; color: var(--ink); }
.bar { display: flex; align-items: flex-end; gap: 8px; padding: 8px 12px 6px; }
.bar textarea { flex: 1; font: inherit; font-size: .9em; min-height: 52px; max-height: 120px; padding: 12px; border-radius: 16px; border: 1px solid var(--line); resize: none; }
.round { border-radius: 50%; width: 52px; height: 52px; font-size: 1.2em; padding: 0; }
.send { background: var(--blue); color: #fff; border-color: var(--blue); }
.mic { width: 84px; height: 64px; border-radius: 20px; background: #c5221f; color: #fff; border: 0; font-size: .75em; font-weight: 700; line-height: 1.2; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.mic.on { background: #8c1411; transform: scale(1.06); }
.ver { text-align: center; font-size: 13px; color: var(--sub); padding: 0 0 6px; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; background: #fff; border-radius: 22px 22px 0 0; box-shadow: 0 -6px 24px rgba(0,0,0,.25); padding: 16px; display: flex; flex-direction: column; gap: 10px; z-index: 10; }
.sheet[hidden], .install[hidden], .driving[hidden], .rec[hidden] { display: none; }
.sheetbtn { text-align: left; padding: 0 18px; min-height: 60px; font-weight: 600; }
.hint { font-size: .8em; color: var(--sub); margin: 4px 0; word-break: break-all; }
.link { border: 0; background: none; color: var(--blue); text-decoration: underline; min-height: 48px; font-weight: 600; }
.hear-title { font-weight: 700; margin: 0; }
#heard { font: inherit; padding: 12px; border-radius: 14px; border: 2px solid var(--blue); }
.rec { position: fixed; left: 12px; right: 12px; bottom: 170px; background: #111; color: #fff; padding: 14px; border-radius: 16px; text-align: center; z-index: 11; }
.dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; background: #ff5f57; margin-right: 6px; }
.install { margin: 10px 12px 0; padding: 12px; border-radius: 16px; background: #e8f0fe; color: var(--ink); }
.install-title { font-weight: 700; margin: 0 0 8px; }
.install ol { margin: 8px 0; padding-left: 1.3em; }
.seg { display: flex; gap: 6px; }
.seg button { flex: 1; }
.seg button[aria-selected="true"] { background: var(--blue); color: #fff; border-color: var(--blue); }
.driving { position: fixed; inset: 0; background: #111; color: #fff; z-index: 20; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 24px; gap: 18px; }
.drive-big { font-size: 1.6em; font-weight: 800; margin: 0; }
.drive-small { margin: 0; color: #e8eaed; }
.driving .big { flex: 0; width: 100%; max-width: 320px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* 큰 글씨 모드: 줄바꿈 없이 한 손 배치 유지 */
.tbtn { white-space: nowrap; }
.shop { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 55vw; }
html.big .quick { grid-template-columns: repeat(2, 1fr); }
html.big .mic { width: 76px; }
html.big .round { width: 48px; height: 48px; }
.bar textarea { min-width: 0; }

