/* 레이아웃: 폰 폭 한 열(최대 480px). 코스는 지하철 노선도처럼 세로 선 위의 정거장으로 보여준다(이 앱에서 하나뿐인 강한 요소).
   아래 고정: 다음 단계 버튼 + 탭 3개(코스 짜기 / 지난 데이트 / 유형 사전). 나머지는 조용하게. */
:root {
  --bg: #F1F3F6; --surface: #FFFFFF; --sunk: #E6E9EE; --rule: #D5DAE1;
  --ink: #181B22; --muted: #596170; --line: #0F7A4C; --line-soft: #DDF1E6; --on-line: #FFFFFF;
  --like: #C2365F; --like-soft: #F8E1E8;
  --ok: #17784A; --ok-soft: #DDF1E6; --est: #8F6205; --est-soft: #F8EDD3; --unk: #5F6675; --unk-soft: #E7EAEF;
  --warn: #B23B26; --warn-soft: #F9E2DC;
  --st-start: #6F63C8; --st-main: #0F7A4C; --st-rest: #2C8798; --st-meal: #C0691A; --st-end: #8A4E9D; --st-stay: #4A5568;
  --font: "Pretendard Sub", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", system-ui, sans-serif;
  /* 글자 크기 5단계·굵기 3단계(400 본문, 600 라벨·버튼, 700 제목). 이 밖의 값은 쓰지 않는다 */
  --fs-cap: 12px; --fs-sub: 14px; --fs-body: 16px; --fs-title: 19px; --fs-display: 24px;
  --rule-input: #858E9C;
  --r-lg: 18px; --r-md: 12px; --r-sm: 8px;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --bg: #111318; --surface: #1A1D24; --sunk: #242833; --rule: #313644;
  --ink: #E9ECF2; --muted: #9DA5B4; --line: #3CCB86; --line-soft: #173527; --on-line: #08130D;
  --like: #F07AA0; --like-soft: #3A1C27;
  --ok: #5CCB92; --ok-soft: #173226; --est: #E2B44E; --est-soft: #352A12; --unk: #A3A9B8; --unk-soft: #282C38;
  --warn: #F08A72; --warn-soft: #3A211B;
  --st-start: #A59AF0; --st-main: #3CCB86; --st-rest: #5CC0D0; --st-meal: #F0A35A; --st-end: #C79BE0; --st-stay: #A0AEC0;
  --rule-input: #6B7385;
  color-scheme: dark } }
:root[data-theme="dark"] {
  --bg: #111318; --surface: #1A1D24; --sunk: #242833; --rule: #313644;
  --ink: #E9ECF2; --muted: #9DA5B4; --line: #3CCB86; --line-soft: #173527; --on-line: #08130D;
  --like: #F07AA0; --like-soft: #3A1C27;
  --ok: #5CCB92; --ok-soft: #173226; --est: #E2B44E; --est-soft: #352A12; --unk: #A3A9B8; --unk-soft: #282C38;
  --warn: #F08A72; --warn-soft: #3A211B;
  --st-start: #A59AF0; --st-main: #3CCB86; --st-rest: #5CC0D0; --st-meal: #F0A35A; --st-end: #C79BE0; --st-stay: #A0AEC0;
  --rule-input: #6B7385;
  color-scheme: dark }
@font-face { font-family: "Pretendard Sub"; src: url("/static/fonts/pretendard-var-sub.woff") format("woff"); font-weight: 400 700; font-display: swap; }

* { box-sizing: border-box; }
body { background: var(--bg); color: var(--ink); font-family: var(--font); font-size: var(--fs-body); line-height: 1.5; word-break: keep-all; overflow-wrap: anywhere; -webkit-tap-highlight-color: transparent; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--line); outline-offset: 2px; }
.app { max-width: 480px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); padding-block: 8px 170px; }
.draft { font-size: var(--fs-cap); color: var(--muted); text-align: center; padding: 4px 0 8px; }

/* 머리: 제목 + 단계 */
.head { display: flex; flex-direction: column; gap: 10px; padding: 6px 0 18px; }
.head h1 { font-size: var(--fs-display); font-weight: 700; letter-spacing: -0.02em; margin: 0; line-height: 1.2; }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; list-style: none; margin: 0; padding: 0; }
.steps li { font-size: var(--fs-cap); color: var(--muted); display: flex; flex-direction: column; gap: 5px; }
.steps li::before { content: ""; height: 4px; border-radius: 2px; background: var(--rule); }
.steps li.done::before, .steps li.now::before { background: var(--line); }
.steps li.now { color: var(--ink); font-weight: 600; }
.back { align-self: flex-start; border: 0; background: none; color: var(--muted); font-size: var(--fs-sub); padding: 6px 0; cursor: pointer; min-height: 32px; }

/* 입력 묶음: 상자 없이 제목 + 내용. 중요한 것만 면으로 */
.q { display: flex; flex-direction: column; gap: 10px; padding: 18px 0; border-top: 1px solid var(--rule); }
.q:first-of-type { border-top: 0; padding-top: 4px; }
.q > h2 { font-size: var(--fs-title); font-weight: 700; margin: 0; letter-spacing: -0.01em; }
.q .help { font-size: var(--fs-sub); color: var(--muted); margin: -4px 0 0; }
.err-line { margin: 0; font-size: var(--fs-sub); font-weight: 600; color: var(--warn); }
.linkish { border: 0; background: none; padding: 0; color: var(--line); font-weight: 600; text-decoration: underline; cursor: pointer; }
.asking > .q, .asking > details { opacity: .35; pointer-events: none; }
.scroller { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.scroller::-webkit-scrollbar { display: none; }
/* 날짜 달력(폰·PC 같은 모양) */
.cal { background: var(--surface); border-radius: var(--r-md); padding: 12px 8px 8px; }
.cal .mon { margin: 0 8px 8px; font-size: var(--fs-sub); font-weight: 600; }
.cal .wk { display: grid; grid-template-columns: repeat(7, 1fr); }
.cal .wk.head span { text-align: center; font-size: var(--fs-cap); color: var(--muted); padding-bottom: 4px; }
.cal .wk.head .we { color: var(--ink); font-weight: 600; }
.cal .day { border: 0; background: none; padding: 2px 0; cursor: pointer; display: flex; justify-content: center; position: relative; min-height: 52px; }
.cal .day i { font-style: normal; width: 44px; height: 48px; border-radius: var(--r-md); display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.15; position: relative; z-index: 1; }
.cal .day b { font-size: var(--fs-body); font-weight: 600; font-variant-numeric: tabular-nums; }
.cal .day small { font-size: var(--fs-cap); color: var(--muted); }
.cal .day.today i { box-shadow: inset 0 0 0 1.5px var(--ink); }
.cal .day:disabled { cursor: default; }
.cal .day:disabled b { color: var(--muted); opacity: .5; font-weight: 400; }
.cal .day[aria-pressed=true] i { background: var(--line); box-shadow: none; }
.cal .day[aria-pressed=true] b, .cal .day[aria-pressed=true] small { color: var(--on-line); }
.cal .day.m1::after { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 1px; background: var(--rule-input); }
.cal .day.jl::before, .cal .day.jr::before { content: ""; position: absolute; top: 2px; height: 48px; background: var(--line); }
.cal .day.jl::before { left: 0; right: 50%; }
.cal .day.jr::before { left: 50%; right: 0; }
.cal .day.jl.jr::before { left: 0; right: 0; }
.cal .day.jl i { border-top-left-radius: 0; border-bottom-left-radius: 0; }
.cal .day.jr i { border-top-right-radius: 0; border-bottom-right-radius: 0; }
.cal .day.jl.m1::after { display: none; }
@media (hover: hover) and (pointer: fine) { .cal .day:hover:not(:disabled):not([aria-pressed=true]) i { background: var(--sunk); } }
.picked { margin: 0; font-size: var(--fs-sub); color: var(--muted); }
.picked b { color: var(--ink); font-weight: 600; }
.picked.err { color: var(--warn); font-weight: 600; }
/* 오늘 취향: 끌려요 / 별로예요 묶음 */
.taste { display: flex; flex-direction: column; gap: 8px; }
.taste + .taste { border-top: 1px dashed var(--rule); padding-top: 14px; margin-top: 4px; }
.taste > .th { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; margin: 0; }
.taste > .th b { font-size: var(--fs-body); font-weight: 600; }
.taste > .th span { font-size: var(--fs-sub); color: var(--muted); }
.taste .who > span { font-weight: 400; color: var(--muted); }
/* 마우스로 쓰는 화면(PC): 가로 줄(날짜 탭·분류 줄)은 얇은 스크롤바를 보인다 */
@media (hover: hover) and (pointer: fine) {
  .daytabs button:hover, .l1s button:hover { border-color: var(--line); }
  .daytabs, .l1s { scrollbar-width: thin; padding-bottom: 4px; }
}
.seg2 { display: inline-grid; grid-template-columns: 1fr 1fr; background: var(--sunk); border-radius: 999px; padding: 3px; align-self: flex-start; }
.seg2 button { border: 0; background: none; border-radius: 999px; padding: 7px 16px; font-size: var(--fs-sub); color: var(--muted); cursor: pointer; min-height: 36px; }
.seg2 button[aria-pressed=true] { background: var(--ink); color: var(--surface); font-weight: 600; }
.seg2 button[aria-pressed=true]::before { content: "✓ "; }
.timebar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; background: var(--surface); border-radius: var(--r-md); padding: 8px; }
.timebar input[type=time] { border: 1px solid var(--rule-input); background: var(--surface); border-radius: var(--r-sm); padding: 10px 6px; font-size: var(--fs-body); font-weight: 600; font-variant-numeric: tabular-nums; min-width: 0; width: 100%; }
.timebar .day { display: none; }
.timebar .to { color: var(--muted); }
.timebar .day { font-size: var(--fs-sub); font-weight: 600; white-space: nowrap; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.pill { border: 1px solid var(--rule); background: var(--surface); border-radius: 999px; padding: 6px 12px; font-size: var(--fs-sub); cursor: pointer; min-height: 36px; }
.pill:hover { border-color: var(--line); }
input.field, select.field, textarea.field { background: var(--surface); border: 1px solid var(--rule-input); border-radius: var(--r-md); padding: 11px 12px; width: 100%; min-width: 0; font-size: var(--fs-body); }
label.lab { display: flex; flex-direction: column; gap: 5px; font-size: var(--fs-sub); color: var(--muted); min-width: 0; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* 얼마나: 노선 미리보기가 있는 선택지 */
.levels { display: flex; flex-direction: column; gap: 8px; }
.level { display: grid; grid-template-columns: 1fr; gap: 6px; text-align: left; border: 1.5px solid var(--rule); background: var(--surface); border-radius: var(--r-md); padding: 12px 14px; cursor: pointer; }
.level[aria-checked=true] { border-color: var(--line); box-shadow: inset 0 0 0 1px var(--line); }
.level .t { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.level .t b { font-size: var(--fs-body); font-weight: 700; }
.level .t span { font-size: var(--fs-sub); color: var(--muted); }
.level p { margin: 0; font-size: var(--fs-sub); color: var(--muted); }
.mini { display: flex; align-items: center; gap: 0; flex-wrap: wrap; row-gap: 6px; }
.mini .s { display: flex; align-items: center; font-size: var(--fs-cap); color: var(--ink); white-space: nowrap; }
.mini .s i { width: 9px; height: 9px; border-radius: 50%; border: 2px solid var(--line); background: var(--surface); margin-right: 4px; flex: none; }
.mini .s.meal i { border-radius: 2px; border-color: var(--st-meal); }
.mini .s + .s::before { content: ""; width: 14px; height: 2px; background: var(--rule); margin: 0 6px; }
.level[aria-checked=true] .mini .s + .s::before { background: var(--line); }
.mini .s.far::before { width: 26px !important; background: repeating-linear-gradient(90deg, var(--muted) 0 4px, transparent 4px 7px) !important; }

/* 끌리는 것 */
.who { display: grid; grid-template-columns: 76px 1fr; gap: 8px; align-items: start; }
.who > span { font-size: var(--fs-sub); font-weight: 600; padding-top: 8px; }
.tag { display: inline-flex; align-items: center; gap: 4px; border-radius: 999px; padding: 4px 4px 4px 12px; font-size: var(--fs-sub); background: var(--like-soft); color: var(--like); min-height: 36px; }
.tag.meh { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--rule-input); }
.tag.exc { background: var(--unk-soft); color: var(--unk); }
.tag.inc { background: var(--line-soft); color: var(--line); }
.tag button { border: 0; background: none; color: inherit; width: 28px; height: 28px; border-radius: 50%; cursor: pointer; font-size: var(--fs-body); line-height: 1; }
.add { border: 1.5px dashed var(--rule); background: none; color: var(--muted); border-radius: 999px; padding: 6px 12px; font-size: var(--fs-sub); cursor: pointer; min-height: 36px; }
.add:hover { color: var(--line); border-color: var(--line); }
.rate-note { font-size: var(--fs-sub); color: var(--muted); margin: 2px 0 0; }

details.more { border-top: 1px solid var(--rule); padding: 14px 0 4px; }
details.more > summary { cursor: pointer; font-size: var(--fs-body); font-weight: 700; list-style: none; display: flex; justify-content: space-between; align-items: center; min-height: 40px; }
details.more > summary::-webkit-details-marker { display: none; }
details.more > summary::after { content: "+"; font-size: 22px; font-weight: 400; color: var(--muted); }
details.more[open] > summary::after { content: "−"; }
details.more > summary small { font-size: var(--fs-sub); font-weight: 400; color: var(--muted); margin-left: 6px; }
.more-body { display: flex; flex-direction: column; gap: 14px; padding: 8px 0 6px; }
.switches { display: flex; flex-direction: column; gap: 2px; background: var(--surface); border-radius: var(--r-md); padding: 4px 12px; }
.switch { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--rule); font-size: var(--fs-body); cursor: pointer; }
.switch:first-child { border-top: 0; }
.switch.repeat { background: var(--surface); border-radius: var(--r-md); border-top: 0; padding: 10px 12px; margin-top: 10px; }
.switch small { display: block; font-size: var(--fs-cap); color: var(--muted); }
.switch input { appearance: none; width: 46px; height: 28px; border-radius: 999px; background: var(--rule); position: relative; flex: none; cursor: pointer; transition: background .2s; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--surface); transition: left .2s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.switch input:checked { background: var(--line); }
.switch input:checked::after { left: 21px; }
.days { display: flex; flex-direction: column; gap: 8px; }
.dayline { background: var(--surface); border-radius: var(--r-md); padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
.dayline .top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.dayline .top b { font-size: var(--fs-body); }
.dayline .row3 { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.dayline input, .dayline select { background: var(--sunk); border: 0; border-radius: var(--r-sm); padding: 8px; font-size: var(--fs-body); min-width: 0; width: 100%; }

/* 아래 고정 */
.dock { position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; background: var(--surface); border-top: 1px solid var(--rule);
  padding-bottom: env(safe-area-inset-bottom, 0px); padding-left: env(safe-area-inset-left, 0px); padding-right: env(safe-area-inset-right, 0px); }
.dock .cta { max-width: 480px; margin: 0 auto; padding: 10px 16px 6px; display: flex; gap: 8px; }
.btn { flex: 1; border: 0; border-radius: var(--r-md); padding: 14px 16px; font-size: var(--fs-body); font-weight: 700; background: var(--line); color: var(--on-line); cursor: pointer; min-height: 50px; }
.btn.quiet { flex: none; background: var(--sunk); color: var(--ink); font-weight: 600; }
.btn:disabled { opacity: .45; cursor: default; }
.tabs { max-width: 480px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); }
.tabs button { border: 0; background: none; padding: 8px 0 10px; font-size: var(--fs-cap); color: var(--muted); cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 3px; min-height: 48px; }
.tabs svg { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.tabs button[aria-current=page] { color: var(--line); font-weight: 600; }

/* 코스: 노선도 */
.planpick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-bottom: 14px; }
.planpick button { min-width: 0; border: 1.5px solid var(--rule); background: var(--surface); border-radius: var(--r-md); padding: 8px 6px; cursor: pointer; text-align: left; min-height: 56px; display: flex; flex-direction: column; gap: 2px; }
.planpick button b { font-size: var(--fs-body); font-weight: 700; }
.planpick button span { font-size: var(--fs-cap); color: var(--muted); line-height: 1.3; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.planpick button[aria-pressed=true] { border-color: var(--line); background: var(--line-soft); }
.course { background: var(--surface); border-radius: var(--r-lg); padding: 18px 16px 10px; }
.course .sum { font-size: var(--fs-body); margin: 0 0 4px; }
.course .sum b { font-weight: 700; }
.course .facts2 { font-size: var(--fs-sub); color: var(--muted); margin: 0 0 12px; }
.daytabs { display: flex; gap: 6px; overflow-x: auto; margin: 0 0 12px; scrollbar-width: none; }
.daytabs button { border: 1px solid var(--rule); background: none; border-radius: 999px; padding: 6px 12px; font-size: var(--fs-sub); cursor: pointer; white-space: nowrap; min-height: 34px; }
.daytabs button[aria-pressed=true] { background: var(--ink); color: var(--bg); border-color: var(--ink); font-weight: 600; }
.stops { list-style: none; margin: 0; padding: 0; position: relative; }
.stop { display: grid; grid-template-columns: 50px 22px 1fr 44px; gap: 0 8px; align-items: start; position: relative; padding: 4px 0 16px; }
.stop .tm { font-size: var(--fs-sub); font-weight: 600; font-variant-numeric: tabular-nums; padding-top: 1px; text-align: right; }
.stop .rail { position: relative; align-self: stretch; display: flex; justify-content: center; }
.stop .rail::before { content: ""; position: absolute; top: 0; bottom: -4px; width: 4px; background: var(--line); border-radius: 2px; }
.stop:first-child .rail::before { top: 10px; }
.stop:last-child .rail::before { bottom: auto; height: 10px; }
.stop:only-child .rail::before { display: none; }
.stop .dot { position: relative; z-index: 1; width: 18px; height: 18px; border-radius: 50%; background: var(--surface); border: 4px solid var(--c, var(--line)); margin-top: 2px; }
.stop[data-r=식사] .dot { border-radius: 5px; }
.stop[data-r=숙소] .dot { border-radius: 3px; background: var(--c); }
.stop .bd { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.stop .nm { font-size: var(--fs-body); font-weight: 600; line-height: 1.35; }
.stop .rl { font-size: var(--fs-cap); font-weight: 600; color: var(--c); }
.stop .pl { font-size: var(--fs-sub); color: var(--muted); }
.stop .pl.known { color: var(--ok); font-weight: 600; }
.stop .badges { display: flex; flex-wrap: wrap; gap: 4px; }
.badge { font-size: var(--fs-cap); border-radius: 6px; padding: 1px 7px; }
.badge.like { background: var(--like-soft); color: var(--like); font-weight: 600; }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.redo { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--rule); background: var(--surface); color: var(--muted); cursor: pointer; display: grid; place-items: center; }
.redo svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 2; }
.redo:hover { color: var(--line); border-color: var(--line); }
.stop.flash .nm { animation: flash .6s; }
@keyframes flash { from { color: var(--line); } }
.legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: var(--fs-cap); color: var(--muted); margin: 8px 0 0; padding-top: 10px; border-top: 1px solid var(--rule); }
.legend span { display: inline-flex; align-items: center; gap: 5px; }
.legend i { width: 10px; height: 10px; border-radius: 50%; border: 3px solid var(--c); }
.legend i.sq { border-radius: 3px; }
.textlink { border: 0; background: none; color: var(--line); font-weight: 600; font-size: var(--fs-body); padding: 12px 0; cursor: pointer; }
.side { font-size: var(--fs-sub); color: var(--muted); margin: 14px 0 0; }
.side summary { cursor: pointer; color: var(--ink); font-weight: 600; min-height: 36px; display: flex; align-items: center; }

/* 장소 */
.slotcard { background: var(--surface); border-radius: var(--r-lg); padding: 14px; display: flex; flex-direction: column; gap: 10px; margin-bottom: 10px; }
.slotcard .h { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.slotcard .h b { font-size: var(--fs-body); }
.slotcard .h span { font-size: var(--fs-sub); color: var(--muted); font-variant-numeric: tabular-nums; }
.status { font-size: var(--fs-sub); color: var(--muted); display: flex; align-items: center; gap: 7px; }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--unk); flex: none; }
.pulse.run { background: var(--est); animation: pulse 1s infinite; } .pulse.done { background: var(--ok); }
@keyframes pulse { 50% { opacity: .3; } }
.cands { display: flex; flex-direction: column; gap: 8px; }
.cand { border: 1.5px solid var(--rule); border-radius: var(--r-md); padding: 10px 12px; background: var(--surface); text-align: left; cursor: pointer; display: flex; flex-direction: column; gap: 6px; }
.cand[aria-pressed=true] { border-color: var(--line); background: var(--line-soft); }
.cand b { font-size: var(--fs-body); }
.kv { display: grid; grid-template-columns: auto 1fr auto; gap: 4px 10px; font-size: var(--fs-sub); align-items: center; }
.kv .k { color: var(--muted); }
.lv { font-size: var(--fs-cap); font-weight: 600; padding: 1px 6px; border-radius: 6px; white-space: nowrap; }
.lv.확인 { background: var(--ok-soft); color: var(--ok); } .lv.추정 { background: var(--est-soft); color: var(--est); } .lv.미확인 { background: var(--unk-soft); color: var(--unk); }
.daylabel { font-size: var(--fs-sub); font-weight: 700; margin: 16px 0 8px; }

/* 확정 */
.checks { background: var(--surface); border-radius: var(--r-lg); padding: 6px 14px; margin-top: 12px; }
.checks div { display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 10px 0; border-top: 1px solid var(--rule); font-size: var(--fs-sub); align-items: center; }
.checks div:first-child { border-top: 0; }
.checks small { display: block; color: var(--muted); font-size: var(--fs-cap); }
.consent { margin-top: 12px; border: 1.5px solid var(--warn); background: var(--warn-soft); border-radius: var(--r-md); padding: 14px; display: flex; flex-direction: column; gap: 12px; font-size: var(--fs-sub); }
.consent .row { display: flex; gap: 8px; }
.outs { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.out { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: var(--surface); border-radius: var(--r-md); padding: 12px 14px; border: 0; cursor: pointer; text-align: left; min-height: 56px; }
.out b { font-size: var(--fs-body); } .out small { display: block; color: var(--muted); font-size: var(--fs-cap); }

/* 지난 데이트 */
.past { background: var(--surface); border-radius: var(--r-lg); padding: 14px; display: flex; flex-direction: column; gap: 12px; margin-bottom: 10px; }
.past .h { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.pending { font-size: var(--fs-cap); font-weight: 600; color: var(--like); background: var(--like-soft); border-radius: 999px; padding: 3px 9px; }
.ratebox { display: flex; flex-direction: column; gap: 12px; }
.rate { display: grid; grid-template-columns: 72px 1fr; align-items: center; gap: 8px; font-size: var(--fs-sub); font-weight: 600; }
.stars { display: flex; gap: 2px; }
.stars button { width: 44px; height: 44px; border: 0; background: none; cursor: pointer; font-size: var(--fs-display); line-height: 1; color: var(--rule); padding: 0; }
.stars button.on { color: var(--like); }
.again { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.again button { border: 1.5px solid var(--rule); background: var(--surface); border-radius: var(--r-md); padding: 10px; cursor: pointer; font-size: var(--fs-sub); min-height: 44px; }
.again button[aria-pressed=true] { border-color: var(--line); background: var(--line-soft); font-weight: 600; }

/* 아래에서 올라오는 판 */
.scrim { position: fixed; inset: 0; background: rgba(10,14,20,.35); z-index: 8; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: 9; background: var(--bg); border-radius: 20px 20px 0 0; box-shadow: 0 -10px 40px rgba(0,0,0,.2);
  padding-bottom: env(safe-area-inset-bottom, 0px); padding-left: env(safe-area-inset-left, 0px); padding-right: env(safe-area-inset-right, 0px); }
.sheet .in { max-width: 480px; margin: 0 auto; padding: 8px 16px 12px; display: flex; flex-direction: column; gap: 10px; height: min(84vh, 680px); }
/* 나갈 때 묻는 창: 다른 판보다 위에, 높이는 내용만큼 */
.scrim.ask { z-index: 11; }
.sheet.ask { z-index: 12; }
.sheet.ask .in { height: auto; padding: 8px 16px 16px; gap: 8px; }
.sheet.ask h2 { font-size: var(--fs-title); font-weight: 700; margin: 4px 0 0; }
.sheet.ask p { margin: 0; font-size: var(--fs-body); color: var(--muted); line-height: 1.5; }
.sheet.ask .rb { display: flex; gap: 8px; margin-top: 8px; }
.grab { width: 40px; height: 4px; border-radius: 2px; background: var(--rule); align-self: center; }
.sheet .hd { display: flex; justify-content: space-between; align-items: center; }
.sheet .hd h2 { font-size: var(--fs-title); font-weight: 700; margin: 0; }
.sheet .done { border: 0; background: var(--line); color: var(--on-line); border-radius: 999px; padding: 8px 16px; font-weight: 700; cursor: pointer; min-height: 40px; }
.target { display: grid; grid-template-columns: repeat(5, 1fr); background: var(--sunk); border-radius: var(--r-md); padding: 3px; gap: 2px; flex: none; }
.target button { border: 0; background: none; border-radius: 9px; padding: 8px 0; font-size: var(--fs-sub); color: var(--muted); cursor: pointer; min-height: 38px; }
.target button[aria-pressed=true] { background: var(--surface); color: var(--ink); font-weight: 700; }
.search { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r-md); padding: 10px 12px; width: 100%; font-size: var(--fs-body); flex: none; }
.l1s { display: flex; gap: 6px; overflow-x: auto; flex: none; scrollbar-width: none; }
.l1s button { flex: none; border: 1px solid var(--rule); background: var(--surface); border-radius: 999px; padding: 7px 12px; font-size: var(--fs-sub); cursor: pointer; white-space: nowrap; min-height: 38px; }
.l1s button small { color: var(--muted); margin-left: 4px; }
.l1s button[aria-pressed=true] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.l1s button[aria-pressed=true] small { color: var(--bg); opacity: .7; }
.browse { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 16px; min-height: 0; }
.grp { display: flex; flex-direction: column; gap: 2px; }
.grp .gh { display: flex; justify-content: space-between; align-items: center; gap: 8px; position: sticky; top: 0; background: var(--bg); padding: 6px 0; z-index: 1; }
.grp .gh b { font-size: var(--fs-body); } .grp .gh small { color: var(--muted); font-weight: 400; margin-left: 4px; }
.grp .gh button { border: 1px solid var(--rule); background: var(--surface); border-radius: 999px; padding: 5px 11px; font-size: var(--fs-sub); cursor: pointer; min-height: 34px; white-space: nowrap; }
.grp .gh button[aria-pressed=true] { border-color: var(--line); color: var(--line); font-weight: 600; }
.ty { display: grid; grid-template-columns: 1fr 28px; gap: 10px; align-items: center; text-align: left; border: 0; background: var(--surface); border-radius: var(--r-md); padding: 10px 12px; cursor: pointer; min-height: 52px; }
.ty + .ty { margin-top: 2px; }
.ty .nm { font-size: var(--fs-body); display: block; }
.ty .mt { font-size: var(--fs-cap); color: var(--muted); display: flex; flex-wrap: wrap; gap: 3px 8px; margin-top: 2px; }
.ty .ck { width: 26px; height: 26px; border-radius: 50%; border: 1.5px solid var(--rule); display: grid; place-items: center; color: transparent; font-size: var(--fs-sub); }
.ty[aria-pressed=true] { box-shadow: inset 0 0 0 1.5px var(--line); }
.ty[aria-pressed=true] .ck { background: var(--line); border-color: var(--line); color: var(--on-line); }
.ty.off .nm { color: var(--muted); }
.flag { font-size: var(--fs-cap); border-radius: 5px; padding: 0 5px; background: var(--unk-soft); color: var(--unk); }
.flag.c { background: var(--est-soft); color: var(--est); }

.chat { position: fixed; right: calc(16px + env(safe-area-inset-right, 0px)); bottom: calc(138px + env(safe-area-inset-bottom, 0px)); z-index: 6; border: 0; border-radius: 999px; padding: 10px 14px; background: var(--ink); color: var(--bg); font-size: var(--fs-sub); font-weight: 600; cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,.2); min-height: 44px; }
.log { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; font-size: var(--fs-body); }
.msg { max-width: 86%; padding: 9px 12px; border-radius: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.msg.me { align-self: flex-end; background: var(--line); color: var(--on-line); }
.msg.cl { align-self: flex-start; background: var(--surface); }
.sheet form { display: flex; gap: 8px; }
.sheet form input { flex: 1; min-width: 0; }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(150px + env(safe-area-inset-bottom, 0px)); background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 12px; font-size: var(--fs-sub); z-index: 10; max-width: calc(100% - 32px); }
@media (prefers-reduced-motion: reduce) { .pulse.run, .stop.flash .nm { animation: none; } .switch input, .switch input::after { transition: none; } }

/* 정해진 일정 */
.fx { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; align-items: flex-start; }
.fxrow { align-self: stretch; background: var(--surface); border-radius: var(--r-md); padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; border-left: 4px solid var(--st-stay); }
.fxtop { display: flex; gap: 6px; }
.fxtop .fx-name { flex: 1; min-width: 0; }
.fx-del { border: 0; background: var(--sunk); border-radius: var(--r-sm); width: 44px; font-size: 20px; color: var(--muted); cursor: pointer; }
.fxline { display: grid; grid-template-columns: 1fr 1fr auto; gap: 6px; align-items: center; }
.fxline input[type=time], .fxline select { background: var(--sunk); border: 0; border-radius: var(--r-sm); padding: 8px; font-size: var(--fs-body); min-width: 0; width: 100%; }
.fx-meal { display: flex; align-items: center; gap: 6px; font-size: var(--fs-sub); font-weight: 600; white-space: nowrap; padding: 0 4px; min-height: 44px; }
.fx-meal input { width: 18px; height: 18px; }
.fx .fx-help { margin: 0; }
.dayline .fx { margin-top: 0; }

/* 장소 찾기 */
.slotcard .rs { margin-top: 10px; }
.slotcard .rs:disabled { opacity: .55; }
.rs-st { font-size: var(--fs-sub); color: var(--muted); margin: 6px 0 0; }
.rs-st:empty { display: none; }

/* 그날 확인 */
.lv.gap { background: var(--warn-soft); color: var(--warn); }
.vhead { font-size: var(--fs-body); font-weight: 600; margin: 20px 0 4px; }
.vhelp { font-size: var(--fs-sub); color: var(--muted); margin: 0 0 10px; }
.vcard .vf { align-self: flex-start; }
.vcard .vf:disabled { opacity: .55; }
.warnline { margin: 12px 0 0; padding: 10px 12px; border-radius: var(--r-md); background: var(--warn-soft); color: var(--warn); font-size: var(--fs-sub); }
.warnline:empty { display: none; }
.calrows { display: flex; flex-direction: column; gap: 6px; }
.calrow { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; background: var(--surface); border-radius: var(--r-md); padding: 10px 14px; min-height: 48px; color: inherit; text-decoration: none; }
.calrow .tm { font-size: var(--fs-sub); color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.calrow .nm { font-size: var(--fs-body); min-width: 0; overflow-wrap: anywhere; }
.calrow .go { font-size: var(--fs-sub); font-weight: 600; white-space: nowrap; }
.calrow.opened .go { color: var(--muted); font-weight: 400; }
.calrow:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

/* 이어서 하기 안내 */
.resume { background: var(--line-soft); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px; margin: 12px 0 4px; display: flex; flex-direction: column; gap: 10px; }
.resume .rh { margin: 0; display: flex; flex-direction: column; gap: 2px; }
.resume .rh b { font-size: var(--fs-body); }
.resume .rh span { font-size: var(--fs-sub); color: var(--muted); }
.resume .rb { display: flex; gap: 8px; }
.resume .rn { margin: 0; font-size: var(--fs-cap); color: var(--muted); }
.btn.ghost { background: var(--surface); color: var(--ink); border: 1px solid var(--rule); font-weight: 600; }

/* 코스가 모자랄 때 이유와 바꿀 것 */
.why { background: var(--surface); border-radius: var(--r-lg); padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.why.soft { margin-top: 12px; background: var(--sunk); }
.why .wh { margin: 0; font-size: var(--fs-body); }
.why ul { margin: 0; padding-left: 18px; font-size: var(--fs-sub); color: var(--ink); display: flex; flex-direction: column; gap: 4px; }
.why .wt { margin: 4px 0 0; font-size: var(--fs-sub); color: var(--muted); }
.why .tips { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.why .tip { text-align: left; min-height: 44px; border-color: var(--line); color: var(--line); font-weight: 600; border-radius: var(--r-md); }

/* 이미 정한 일정: 종류 → 이름 → 시간. 아래 하루 띠에 빈 시간을 보여 준다 */
.fxkind { display: flex; gap: 6px; flex-wrap: wrap; }
.fxkind button { border: 1px solid var(--rule-input); background: var(--surface); border-radius: 999px; padding: 6px 12px; font-size: var(--fs-sub); min-height: 36px; cursor: pointer; }
.fxkind button[aria-pressed=true] { background: var(--ink); border-color: var(--ink); color: var(--surface); font-weight: 600; }
.fxrow.bad { border-left-color: var(--warn); }
.addfx { align-self: stretch; border: 1.5px dashed var(--rule-input); background: none; border-radius: var(--r-md); padding: 12px; font-size: var(--fs-body); font-weight: 600; color: var(--ink); min-height: 48px; cursor: pointer; }
.strip { align-self: stretch; display: flex; gap: 2px; height: 14px; margin-top: 6px; }
.strip .sg { border-radius: 4px; min-width: 2px; }
.strip .sg.free { background: var(--line-soft); border: 1px dashed var(--line); }
.strip .sg.tight { background: var(--sunk); }
.strip .sg.fix { background: var(--st-stay); }
.strip-t { align-self: stretch; display: flex; justify-content: space-between; font-size: var(--fs-cap); color: var(--muted); font-variant-numeric: tabular-nums; margin-top: -4px; }
.strip-w { margin: 0; font-size: var(--fs-sub); }
select.bad { outline: 2px solid var(--warn); }
#food-where { display: flex; flex-direction: column; gap: 8px; }
#food-where .help { margin: 0; }
#food-season { display: flex; flex-direction: column; gap: 8px; }
#food-season:empty { display: none; }
#food-season .help { margin: 0; }
.help.warn { color: var(--warn); }
.help b { color: var(--ink); font-weight: 600; }
.help.warn b { color: inherit; }

/* 장소 카드: 날짜·추정은 카드에 한 줄, 시간 안 맞으면 경고 */
.slotcard.fixedcard { background: var(--sunk); padding-block: 10px; }
.slotcard.fixedcard .h b { font-weight: 600; }
.cand .src { display: block; font-size: var(--fs-cap); color: var(--muted); margin-top: 6px; }
.cand .cwarn { display: block; font-size: var(--fs-sub); font-weight: 600; color: var(--warn); margin-top: 6px; }
.cand .cwarn.soft { font-weight: 400; color: var(--muted); }
.side.tight { margin: 6px 0 0; }
.vall { align-self: flex-start; margin: 4px 0 8px; border-color: var(--line); color: var(--line); font-weight: 600; }

/* 강도: 그날 시간에 안 맞는 건 흐리게(이유는 설명 줄에) — 2026-11-20 */
.level.off { opacity: .55; border-style: dashed; }
.level .fit { color: var(--ink); }
.level.off .fit { color: var(--muted); }
.d-lab { margin: 0 0 4px; font-size: var(--fs-sub); color: var(--muted); }
.d-lv { display: flex; flex-wrap: wrap; gap: 6px; }
.d-lv button { border: 1px solid var(--rule-input); background: var(--surface); border-radius: 999px; padding: 6px 12px; font-size: var(--fs-sub); min-height: 36px; cursor: pointer; color: var(--ink); }
.d-lv button[aria-checked=true] { background: var(--ink); border-color: var(--ink); color: var(--surface); font-weight: 600; }
.d-lv button[aria-checked=true]::before { content: "✓ "; }
.d-lv button.off { opacity: .5; border-style: dashed; }
.d-lvdesc { margin: 6px 0 0; }
.dayline .d-region { background: var(--sunk); }

/* 어디서·얼마나를 따로 고르기(시안 docs/gui/mockup_where_level.html) — 2026-11-23 */
.seg3 { display: grid; grid-template-columns: repeat(3, 1fr); background: var(--sunk); border-radius: 999px; padding: 3px; }
.seg3 button { border: 0; background: none; border-radius: 999px; padding: 8px 6px; font-size: var(--fs-sub); color: var(--muted); cursor: pointer; min-height: 44px; }
.seg3 button[aria-pressed=true] { background: var(--ink); color: var(--surface); font-weight: 600; }
.seg3 button[aria-pressed=true]::before { content: "✓ "; }
.wsub { display: flex; flex-direction: column; gap: 10px; }
#one-time { display: flex; flex-direction: column; gap: 10px; }
.cal .mon small { font-weight: 400; color: var(--muted); margin-left: 8px; font-size: var(--fs-sub); }
.level { gap: 4px; }
.level b { font-size: var(--fs-body); font-weight: 700; }
.level .ord { color: var(--ink); }
.level.off { opacity: 1; border-style: dashed; cursor: default; }
.level.off b, .level.off .desc { opacity: .55; }
.level.off .nofit { color: var(--ink); }
.level .ord span { white-space: nowrap; }
/* 여러 날: 한 줄 요약, 누른 날만 펼침 */
.dayline { padding: 0; gap: 0; }
.dayline.open { box-shadow: inset 0 0 0 1.5px var(--rule-input); }
.dayrow { display: flex; justify-content: space-between; align-items: center; gap: 10px; width: 100%; text-align: left; background: none; border: 0; border-radius: var(--r-md); padding: 12px; min-height: 48px; cursor: pointer; font-size: var(--fs-sub); }
.dayrow b { font-size: var(--fs-body); font-weight: 600; margin-right: 6px; }
.dayrow .sum { color: var(--muted); }
.dayrow .chev { color: var(--muted); flex: none; }
.d-body { display: flex; flex-direction: column; gap: 10px; padding: 0 12px 12px; }
.dayline .seg3 { background: var(--bg); }
.dayline .d-lab { margin: 0 0 -4px; }
.dayline input.field { background: var(--surface); border: 1px solid var(--rule-input); border-radius: var(--r-md); padding: 11px 12px; }
.dayline .help { font-size: var(--fs-sub); color: var(--muted); margin: 0; }
.d-lv button { min-height: 44px; padding: 6px 14px; }
.d-lvdesc { margin: 8px 0 0; }
/* 코스 칸의 '확인 필요': 누르면 무엇을 확인할지 한 줄 */
.badge.note { background: var(--unk-soft); color: var(--unk); }
.badge.ask { border: 0; font-family: inherit; cursor: pointer; padding: 5px 8px; text-decoration: underline dotted; text-underline-offset: 3px; position: relative; }
.badge.ask::after { content: ""; position: absolute; inset: -9px -4px; }  /* 누르는 자리만 넓힌다 */
.bwhy { display: block; font-size: var(--fs-sub); color: var(--muted); }
.maplink { align-self: flex-start; margin: -4px 0 0; padding: 12px 2px; min-height: 44px; font-size: var(--fs-sub); color: var(--line); font-weight: 600; text-underline-offset: 3px; }
.dayline .d-lvoff { margin: 4px 0 0; }

/* 지역 고르기(시안 docs/gui/mockup_region_picker.html) — 2026-11-23 */
.pickbtn { display: flex; justify-content: space-between; align-items: center; gap: 10px; width: 100%; text-align: left; background: var(--surface);
  border: 1px solid var(--rule-input); border-radius: var(--r-md); padding: 11px 12px; min-height: 48px; cursor: pointer; font-size: var(--fs-body); color: var(--ink); }
.pickbtn .v { min-width: 0; overflow-wrap: anywhere; }
.pickbtn .v.empty { color: var(--muted); }
.pickbtn .go { flex: none; font-size: var(--fs-sub); font-weight: 600; color: var(--line); }
.dayline .pickbtn { background: var(--bg); }
.rp-body { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 10px; }
.rp-two { flex: 1; min-height: 0; display: grid; grid-template-columns: 100px 1fr; gap: 8px; }
.rp-rail, .rp-list { overflow-y: auto; display: flex; flex-direction: column; min-height: 0; }
.rp-rail { gap: 2px; }
.rp-list { gap: 6px; }
.rp-list.full { flex: 1; }
.rp-rail > *, .rp-list > * { flex: none; }
.rp-rail button { border: 0; background: none; text-align: left; padding: 9px 8px; border-radius: var(--r-md); font-size: var(--fs-sub); color: var(--muted); min-height: 44px; cursor: pointer; }
.rp-rail button small { display: block; font-size: var(--fs-cap); }
.rp-rail button[aria-pressed=true] { background: var(--surface); color: var(--ink); font-weight: 600; }
.rrow { display: flex; flex-direction: column; gap: 2px; text-align: left; border: 1px solid transparent; background: var(--surface); border-radius: var(--r-md); padding: 10px 12px; min-height: 52px; cursor: pointer; color: var(--ink); }
.rrow[aria-pressed=true] { border-color: var(--line); background: var(--line-soft); }
.rrow .nm { font-size: var(--fs-body); font-weight: 600; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.rrow .sub { font-size: var(--fs-sub); color: var(--muted); }
.rrow .tm { font-size: var(--fs-sub); font-variant-numeric: tabular-nums; }
.rrow .badge { font-weight: 400; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.rgh { margin: 8px 2px 0; font-size: var(--fs-sub); color: var(--muted); }
.rp-quick { display: flex; flex-direction: column; gap: 6px; flex: none; }
.rp-quick p, .rp-base { margin: 0; font-size: var(--fs-sub); color: var(--muted); }
.rp-chips { display: flex; flex-wrap: wrap; gap: 6px; flex: none; }
.rp-chips .pill { min-height: 40px; }
.rp-chips .pill[aria-pressed=true] { background: var(--ink); border-color: var(--ink); color: var(--bg); font-weight: 600; }
.seg2.wide { display: grid; align-self: stretch; flex: none; }
.seg2.wide button { min-height: 44px; }
.rnone { background: var(--surface); border-radius: var(--r-md); padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; font-size: var(--fs-sub); }
.rnone p { margin: 0; }
.rnone .pill { align-self: flex-start; border-color: var(--line); color: var(--line); font-weight: 600; min-height: 44px; }
#rp-title:focus { outline: none; }
.rrow.dim { opacity: .6; }
