/* READY BOX 배송 기사 앱 (모바일 웹). 갤럭시·아이폰 어느 폭에서나 꽉 차게, 마우스 쓰는 데스크톱에서만 휴대폰 틀 안에 보여 줌 */
:root {
  --navy: #0e1440; --navy-2: #1b2363; --indigo: #2b37a0; --blue: #3b4fd8; --lilac: #a9b4f2; --sky: #eef0fd;
  --ink: #0b1020; --text: #2a3142; --muted: #6b7386; --line: #e8eaf0; --bg: #f3f4f8;
  --teal: #0e9384; --teal-50: #e3f6f3; --amber: #b25f00; --amber-50: #fff3e0; --red: #d92d3a; --red-50: #fdecee;
  --z1: #3b4fd8; --z2: #0e9384; --z3: #e38a12; --z4: #c0399b; --z5: #5b6478;
  --font: -apple-system, BlinkMacSystemFont, "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --safe-t: env(safe-area-inset-top, 0px); --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { font-family: var(--font); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; overscroll-behavior: none; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }

/* 휴대폰: 화면 전체 */
.phone { position: fixed; inset: 0; overflow: hidden; background: var(--bg); }
.intro { display: none; }

/* 데스크톱(마우스): 왼쪽 설명 + 가운데 휴대폰 틀. 가로로 돌린 휴대폰·태블릿은 틀 없이 화면 전체 */
@media (min-width: 760px) and (hover: hover) and (pointer: fine) {
  body { display: flex; align-items: center; justify-content: center; gap: 64px; min-height: 100vh; background: radial-gradient(900px 600px at 70% 20%, #26318a 0%, transparent 60%), var(--navy); padding: 24px; }
  .phone { position: relative; inset: auto; width: 390px; height: min(844px, calc(100vh - 48px)); border-radius: 48px; box-shadow: 0 0 0 11px #05081c, 0 0 0 13px #2a3270, 0 40px 90px rgba(0, 0, 0, .5); flex: none; }
  .intro { display: block; color: #fff; max-width: 360px; }
  .intro h1 { font-size: 40px; line-height: 1.15; margin: 18px 0 14px; letter-spacing: -0.03em; }
  .intro p { color: #c8cee8; font-size: 15px; line-height: 1.7; margin: 0 0 18px; }
  .intro ul { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 8px; color: #c8cee8; font-size: 14.5px; }
  .intro li b { color: #fff; margin-right: 8px; }
  .intro .small { font-size: 13px; color: #8f98c8; }
  .intro .back { display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 20px 0 16px; border-radius: 999px; color: #c8cee8; background: rgba(255, 255, 255, .08); text-decoration: none; font-weight: 700; font-size: 17px; transition: background .2s, color .2s; }
  .intro .intro-logo { display: block; height: 54px; width: auto; margin: 26px 0 0 -4px; }
  .intro .back:hover { background: rgba(255, 255, 255, .16); color: #fff; }
  :root { --safe-t: 14px; --safe-b: 10px; }
}
@media (min-width: 760px) and (max-width: 1000px) and (hover: hover) and (pointer: fine) { .intro { display: none; } }

.screen { position: absolute; inset: 0; display: flex; flex-direction: column; }
.logo { width: 54px; height: 54px; border-radius: 16px; background: var(--navy) url("../brand/mark-white.png") center / 74% no-repeat; }
.login-logo { height: 52px; width: auto; display: block; margin-left: -4px; }
.boot { align-items: center; justify-content: center; gap: 10px; background: var(--navy); color: #fff; }
.boot b { font-size: 20px; letter-spacing: .02em; }
.boot span { color: #aab2d6; font-size: 13px; }

/* 시작 */
.login { padding: calc(var(--safe-t) + 70px) 26px calc(var(--safe-b) + 30px); background: #fff; }
.login-top { margin-bottom: 40px; }
.login h1 { margin: 18px 0 4px; font-size: 28px; letter-spacing: -0.02em; color: var(--ink); }
.login-top p { margin: 0; color: var(--muted); }
.login label { font-size: 13px; font-weight: 700; color: var(--muted); }
.dno { display: flex; align-items: center; gap: 10px; margin-top: 8px; border-bottom: 2px solid var(--blue); padding: 6px 0; }
.dno span { font-size: 26px; font-weight: 800; color: var(--muted); }
.dno input { flex: 1; border: 0; outline: 0; font-size: 34px; font-weight: 900; color: var(--ink); background: none; width: 100%; }
.login .hint { font-size: 12.5px; color: var(--muted); margin: 10px 0 auto; }
.primary { height: 56px; border: 0; border-radius: 16px; background: var(--blue); color: #fff; font-size: 17px; font-weight: 800; width: 100%; }
.primary:active { background: var(--indigo); }

/* 본 화면 */
.app { position: absolute; inset: 0; display: flex; flex-direction: column; }
.bar { display: flex; align-items: center; justify-content: space-between; padding: calc(var(--safe-t) + 10px) 18px 10px; background: var(--navy); color: #fff; }
.who b { display: block; font-size: 17px; }
.who span { font-size: 12px; color: #aab2d6; }
.clock { display: flex; align-items: center; gap: 7px; height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .18); background: rgba(255, 255, 255, .08); color: #fff; }
.clock b { font-size: 16px; font-variant-numeric: tabular-nums; }
.clock .dot { width: 7px; height: 7px; border-radius: 50%; background: #3fd6c4; box-shadow: 0 0 0 3px rgba(63, 214, 196, .25); }
.clock .dot.off { background: #8f98c8; box-shadow: none; }
.views { position: relative; flex: 1; min-height: 0; }
.view { position: absolute; inset: 0; overflow-y: auto; padding: 16px 16px calc(var(--safe-b) + 90px); display: none; -webkit-overflow-scrolling: touch; }
.view.on { display: block; }
.sec { font-size: 15px; margin: 22px 4px 10px; color: var(--ink); }
.date { font-size: 13px; color: var(--muted); margin: 0 4px 10px; }

/* 지금 할 일 */
.now-card { border-radius: 22px; padding: 18px; background: var(--navy); color: #fff; box-shadow: 0 10px 26px rgba(14, 20, 64, .2); }
.now-card .k { font-size: 12.5px; color: var(--lilac); font-weight: 800; letter-spacing: .02em; }
.now-card h3 { margin: 6px 0 6px; font-size: 22px; line-height: 1.3; letter-spacing: -0.02em; }
.now-card p { margin: 0; color: #cfd4ec; font-size: 14px; line-height: 1.55; }
.now-card .big { font-size: 40px; font-weight: 900; letter-spacing: -0.03em; margin: 8px 0 2px; font-variant-numeric: tabular-nums; }
.now-card .big small { font-size: 16px; color: var(--lilac); margin-left: 6px; }
.prog { height: 8px; border-radius: 4px; background: rgba(255, 255, 255, .14); overflow: hidden; margin: 14px 0 4px; }
.prog i { display: block; height: 100%; background: linear-gradient(90deg, #7d8cf0, #3fd6c4); border-radius: 4px; transition: width .4s; }
.now-card .row { display: flex; gap: 8px; margin-top: 14px; }
.now-card .row button, .now-card .row a { flex: 1; height: 44px; border-radius: 13px; border: 0; background: #fff; color: var(--navy); font-weight: 800; font-size: 14.5px; display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.now-card .row .sub { background: rgba(255, 255, 255, .12); color: #fff; }
.now-card.ready { background: linear-gradient(135deg, #0e9384, #0b6f64); }
.now-card.ready .k { color: #c6f3ec; }
.dock { display: inline-flex; align-items: baseline; gap: 6px; margin-top: 10px; padding: 8px 14px; border-radius: 12px; background: rgba(255, 255, 255, .14); font-weight: 900; font-size: 26px; }
.dock small { font-size: 13px; font-weight: 700; color: #e6fbf7; }

.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.tile { background: #fff; border-radius: 18px; padding: 14px 15px; }
.tile span { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.tile b { display: block; font-size: 24px; color: var(--ink); margin-top: 4px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.tile b small { font-size: 13px; color: var(--muted); margin-left: 3px; font-weight: 600; }
.tile em { display: block; font-style: normal; font-size: 12px; color: var(--muted); margin-top: 2px; }

.timeline { list-style: none; margin: 0; padding: 4px 16px; background: #fff; border-radius: 18px; }
.timeline li { position: relative; display: grid; grid-template-columns: 52px 1fr; gap: 10px; padding: 12px 0 12px 18px; border-top: 1px solid #f1f2f6; font-size: 14.5px; }
.timeline li:first-child { border-top: 0; }
.timeline li::before { content: ""; position: absolute; left: 0; top: 18px; width: 9px; height: 9px; border-radius: 50%; background: #d4d8e2; }
.timeline li.done { color: var(--muted); }
.timeline li.done::before { background: var(--lilac); }
.timeline li.now { font-weight: 800; color: var(--ink); }
.timeline li.now::before { background: var(--blue); box-shadow: 0 0 0 4px var(--sky); }
.timeline time { font-variant-numeric: tabular-nums; color: var(--muted); font-weight: 600; }
.timeline li.now time { color: var(--blue); }
.timeline small { display: block; font-size: 12px; color: var(--muted); font-weight: 500; margin-top: 2px; }

.notes { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.notes li { background: #fff; border-radius: 16px; padding: 13px 14px 13px 44px; position: relative; font-size: 13.5px; line-height: 1.5; }
.notes li::before { content: attr(data-i); position: absolute; left: 13px; top: 12px; width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; font-size: 12px; font-weight: 900; color: #fff; background: var(--blue); }
.notes li.warn::before { background: var(--amber); }
.notes li.ok::before { background: var(--teal); }
.notes b { color: var(--ink); }

/* 경로 */
#v-route { padding: 0; overflow: hidden; display: none; flex-direction: column; }
#v-route.on { display: flex; }
.map-wrap { position: relative; height: var(--map-h, clamp(210px, 46%, 520px)); flex: none; background: #e7eaf1; transition: height .25s ease; }
#v-route.dragging .map-wrap { transition: none; }
#map, #smap { position: absolute; inset: 0; width: 100%; height: 100%; }
.map-top { position: absolute; left: 12px; right: 12px; top: 12px; display: flex; justify-content: space-between; z-index: 5; pointer-events: none; }
.map-top > * { pointer-events: auto; }
.seg { display: inline-flex; padding: 3px; border-radius: 12px; background: rgba(255, 255, 255, .94); box-shadow: 0 2px 10px rgba(14, 20, 64, .12); }
.seg button { border: 0; background: none; padding: 7px 14px; border-radius: 9px; font-size: 13.5px; font-weight: 700; color: var(--muted); }
.seg button.on { background: var(--navy); color: #fff; }
.seg.wide { display: flex; width: 100%; box-shadow: none; background: var(--bg); }
.seg.wide button { flex: 1; }
.round { width: 40px; height: 40px; border-radius: 50%; border: 0; background: #fff; box-shadow: 0 2px 10px rgba(14, 20, 64, .15); font-size: 18px; color: var(--blue); }
.map-leg { position: absolute; left: 12px; bottom: 26px; display: flex; gap: 6px; z-index: 5; flex-wrap: wrap; }
.map-leg span { font-size: 11px; font-weight: 800; color: #fff; background: var(--c); padding: 3px 8px; border-radius: 8px; box-shadow: 0 1px 4px rgba(0, 0, 0, .15); }
.sheet { flex: 1; min-height: 0; overflow-y: auto; background: #fff; border-radius: 22px 22px 0 0; margin-top: -16px; position: relative; z-index: 6; padding: 8px 16px calc(var(--safe-b) + 90px); box-shadow: 0 -6px 20px rgba(14, 20, 64, .08); }
.grab { width: 38px; height: 5px; border-radius: 3px; background: #d4d8e2; margin: 2px auto 12px; }
/* 목록 판 손잡이: 보이는 막대는 작아도 누르는 칸은 판 폭 전체 · 높이 30px */
.sheet-grab { width: auto; height: 30px; margin: -8px -16px 2px; background: none; position: relative; cursor: grab; touch-action: none; outline: none; }
.sheet-grab::before { content: ""; position: absolute; left: 50%; top: 11px; width: 40px; height: 5px; margin-left: -20px; border-radius: 3px; background: #c9ced8; }
.sheet-grab:focus-visible::before, #v-route.dragging .sheet-grab::before { background: var(--blue); }
#v-route.dragging .sheet-grab { cursor: grabbing; }
.next { border-radius: 18px; background: var(--sky); padding: 14px; }
.next .k { font-size: 12px; font-weight: 800; color: var(--blue); }
.next h3 { margin: 4px 0 2px; font-size: 18px; color: var(--ink); }
.next p { margin: 0; font-size: 13px; color: var(--muted); }
.next .row { display: flex; gap: 8px; margin-top: 12px; }
.next .row a, .next .row button { flex: 1; height: 42px; border-radius: 12px; border: 0; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; text-decoration: none; }
.btn-kakao { background: #fee500; color: #191919; }
.btn-blue { background: var(--blue); color: #fff; }
.btn-line { background: #fff; color: var(--navy); border: 1.5px solid var(--line) !important; }
.list-h { display: flex; justify-content: space-between; align-items: baseline; margin: 18px 2px 6px; }
.list-h b { font-size: 15px; color: var(--ink); }
.list-h span { font-size: 12.5px; color: var(--muted); }
.stops { list-style: none; margin: 0; padding: 0; }
.map-src { margin: 14px 0 4px; font-size: 11px; color: var(--muted); text-align: center; }
.map-src a { color: inherit; }
.stops li { display: grid; grid-template-columns: 34px 1fr auto; gap: 12px; align-items: center; padding: 11px 2px; border-top: 1px solid #f1f2f6; cursor: pointer; }
.stops li:first-child { border-top: 0; }
.stops .no { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 13px; color: #fff; background: var(--c); }
.stops li.done .no { background: #c9ced8; }
.stops li.done { color: var(--muted); }
.stops li.now { background: var(--sky); border-radius: 12px; padding-left: 6px; padding-right: 6px; }
.stops .t b { display: block; font-size: 14.5px; color: var(--ink); }
.stops li.done .t b { color: var(--muted); font-weight: 600; }
.stops .t span { font-size: 12px; color: var(--muted); }
.stops .r { text-align: right; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.stops .r b { display: block; color: var(--ink); font-size: 14px; }
.tag { display: inline-block; font-size: 11px; font-weight: 800; padding: 2px 7px; border-radius: 6px; color: #fff; background: var(--c); }
.chip { display: inline-block; font-size: 11.5px; font-weight: 800; padding: 2px 8px; border-radius: 6px; background: var(--teal-50); color: var(--teal); }
.chip.away { background: var(--amber-50); color: var(--amber); }

/* 카카오맵 위 표시 */
.pin { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font: 900 12px var(--font); color: #fff; border: 2px solid #fff; box-shadow: 0 1px 5px rgba(0, 0, 0, .3); }
.pin.done { background: #b3b8c3 !important; }
.pin.now { transform: scale(1.25); box-shadow: 0 0 0 5px rgba(59, 79, 216, .25), 0 1px 5px rgba(0, 0, 0, .3); }
.van { width: 34px; height: 34px; border-radius: 50%; background: var(--red); border: 3px solid #fff; box-shadow: 0 0 0 6px rgba(217, 45, 58, .2), 0 2px 6px rgba(0, 0, 0, .3); display: grid; place-items: center; color: #fff; font-size: 15px; }
.term { padding: 4px 9px; border-radius: 9px; background: var(--navy); color: #fff; font: 800 11.5px var(--font); white-space: nowrap; }

/* 카세트 */
.cas-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.cas-head .seg { box-shadow: none; background: #fff; }
.cas-head p { margin: 0; font-size: 12.5px; color: var(--muted); text-align: right; }
.light { border-radius: 18px; padding: 14px 16px; background: var(--navy); color: #fff; margin-bottom: 12px; }
.light .k { font-size: 12px; color: var(--lilac); font-weight: 800; }
.light h3 { margin: 4px 0 0; font-size: 18px; }
.light p { margin: 4px 0 0; font-size: 13px; color: #cfd4ec; }
.truck { background: #fff; border-radius: 22px; padding: 12px; }
.truck-door { text-align: center; font-size: 11.5px; font-weight: 800; color: var(--muted); padding: 4px; border: 1.5px dashed #c9ced8; border-radius: 10px; }
.truck-door.in { border-style: solid; background: #f6f7fa; }
.cassettes { display: grid; gap: 8px; margin: 8px 0; }
.cas { border-radius: 14px; padding: 10px; background: #f6f7fa; border-left: 5px solid var(--c); }
.cas-h { display: flex; justify-content: space-between; align-items: baseline; font-size: 13px; margin-bottom: 8px; }
.cas-h b { color: var(--ink); }
.cas-h span { color: var(--muted); font-size: 12px; }
.slots { display: grid; grid-template-columns: repeat(6, 1fr); gap: 5px; }
.slot { aspect-ratio: 1.2; border-radius: 8px; background: #fff; border: 1.5px solid #e1e4ea; display: grid; place-items: center; font-size: 11.5px; font-weight: 800; color: var(--text); position: relative; padding: 0; }
.slot small { display: block; font-size: 9.5px; font-weight: 600; color: var(--muted); }
.slot.done { background: #eceef2; color: #a3a9b6; border-color: #eceef2; }
.slot.lit { background: #fff7c2; border-color: #f0c400; box-shadow: 0 0 0 3px rgba(240, 196, 0, .35), 0 0 16px rgba(240, 196, 0, .55); animation: glow 1.2s ease-in-out infinite alternate; }
@keyframes glow { from { box-shadow: 0 0 0 2px rgba(240, 196, 0, .3), 0 0 8px rgba(240, 196, 0, .4); } to { box-shadow: 0 0 0 4px rgba(240, 196, 0, .45), 0 0 18px rgba(240, 196, 0, .7); } }
.cas-help { font-size: 12.5px; color: var(--muted); line-height: 1.6; margin: 12px 4px 0; }

/* 내 정보 */
.me-top { display: flex; align-items: center; gap: 14px; background: #fff; border-radius: 20px; padding: 16px; }
.avatar { width: 54px; height: 54px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font-weight: 900; font-size: 19px; }
.me-top b { display: block; font-size: 18px; color: var(--ink); }
.me-top span { font-size: 13px; color: var(--muted); }
.kv { display: grid; grid-template-columns: 1fr auto; gap: 0; margin: 0; background: #fff; border-radius: 18px; padding: 4px 16px; }
.kv dt, .kv dd { padding: 12px 0; border-top: 1px solid #f1f2f6; font-size: 14px; }
.kv dt:first-of-type, .kv dd:first-of-type { border-top: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 800; color: var(--ink); text-align: right; font-variant-numeric: tabular-nums; }
.kv dd small { display: block; font-size: 11.5px; color: var(--teal); font-weight: 700; }
.log { list-style: none; margin: 0; padding: 4px 16px; background: #fff; border-radius: 18px; font-size: 13.5px; }
.log li { padding: 11px 0; border-top: 1px solid #f1f2f6; display: flex; justify-content: space-between; gap: 10px; }
.log li:first-child { border-top: 0; }
.log li span { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.log .empty { color: var(--muted); justify-content: center; }
.demo { background: #fff; border-radius: 18px; padding: 14px 16px; display: grid; gap: 12px; }
.demo label { display: flex; justify-content: space-between; font-size: 14px; color: var(--muted); }
.demo label b { color: var(--ink); font-variant-numeric: tabular-nums; }
.demo input[type=range] { width: 100%; accent-color: var(--blue); }
.jumps { display: flex; flex-wrap: wrap; gap: 6px; }
.jumps button { border: 1.5px solid var(--line); background: #fff; border-radius: 10px; padding: 7px 10px; font-size: 12.5px; font-weight: 700; color: var(--text); }
.ghost { width: 100%; height: 50px; margin-top: 12px; border: 0; border-radius: 15px; background: #fff; font-weight: 800; color: var(--navy); }
.ghost.danger { color: var(--red); }

/* 아래 탭 */
.tabs { position: absolute; left: 0; right: 0; bottom: 0; display: flex; padding: 6px 6px calc(var(--safe-b) + 6px); background: rgba(255, 255, 255, .92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid rgba(14, 20, 64, .08); z-index: 20; }
.tabs button { flex: 1; border: 0; background: none; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 0; font-size: 11px; font-weight: 700; color: #9aa1b2; }
.tabs svg { width: 25px; height: 25px; fill: currentColor; }
.tabs button.on { color: var(--blue); }

/* 정류장 자세히 */
.dim { position: absolute; inset: 0; background: rgba(5, 8, 28, .35); z-index: 30; }
.detail { position: absolute; left: 0; right: 0; bottom: 0; max-height: 86%; overflow-y: auto; background: #fff; border-radius: 24px 24px 0 0; padding: 10px 18px calc(var(--safe-b) + 18px); z-index: 31; animation: up .22s ease-out; }
@keyframes up { from { transform: translateY(40px); opacity: .4; } to { transform: none; opacity: 1; } }
.detail .grab { cursor: pointer; padding: 6px 0; margin: -6px auto 6px; background-clip: content-box; height: 17px; }
.x { position: absolute; top: 12px; right: 14px; width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--bg); color: var(--muted); font-size: 14px; font-weight: 800; }
.d-top { padding-right: 36px; display: flex; gap: 12px; align-items: center; margin-top: 6px; }
.d-top .no { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; font-weight: 900; color: #fff; background: var(--c); font-size: 18px; flex: none; }
.d-top h3 { margin: 0; font-size: 19px; color: var(--ink); line-height: 1.3; }
.d-top p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.d-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0; }
.d-grid div { background: var(--bg); border-radius: 14px; padding: 10px 12px; }
.d-grid span { font-size: 11.5px; color: var(--muted); font-weight: 600; }
.d-grid b { display: block; font-size: 17px; color: var(--ink); margin-top: 2px; }
.d-act { display: grid; gap: 8px; }
.d-act a, .d-act button { height: 50px; border-radius: 15px; border: 0; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 15px; text-decoration: none; }
.d-two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.d-sub { font-size: 12.5px; color: var(--muted); margin: 14px 2px 8px; font-weight: 700; }
.reasons { display: flex; flex-wrap: wrap; gap: 6px; }
.reasons button { border: 1.5px solid var(--line); background: #fff; border-radius: 10px; padding: 8px 12px; font-size: 13px; font-weight: 700; }
.reasons button.on { border-color: var(--blue); background: var(--sky); color: var(--blue); }
.d-photo { margin-top: 10px; border-radius: 14px; width: 100%; max-height: 180px; object-fit: cover; }
.d-done { margin-top: 10px; padding: 10px 12px; border-radius: 12px; background: var(--teal-50); color: var(--teal); font-weight: 800; font-size: 13.5px; }

.toast { position: absolute; left: 50%; bottom: calc(var(--safe-b) + 84px); transform: translateX(-50%); background: rgba(14, 20, 64, .94); color: #fff; padding: 11px 16px; border-radius: 14px; font-size: 13.5px; font-weight: 600; opacity: 0; transition: opacity .25s; pointer-events: none; z-index: 40; width: max-content; max-width: 88%; text-align: center; }
.toast.show { opacity: 1; }

/* 실시간 도로 상황 */
.mt-r { display: flex; gap: 8px; align-items: center; }
.pill { height: 40px; padding: 0 14px; border-radius: 20px; border: 0; background: #fff; color: var(--muted); font-weight: 800; font-size: 13px; box-shadow: 0 2px 10px rgba(14, 20, 64, .15); }
.pill.on { background: #16a34a; color: #fff; }
.livebox { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 10px; padding: 12px 14px; border-radius: 16px; border: 1.5px solid var(--line); }
.livebox b { display: block; font-size: 15px; color: var(--ink); }
.livebox span { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.livebox .lb { display: flex; gap: 6px; flex: none; }
.livebox button { height: 38px; padding: 0 12px; border-radius: 11px; border: 1.5px solid var(--line); background: #fff; font-weight: 800; font-size: 13px; color: var(--navy); }
.livebox button.pri { background: var(--navy); border-color: var(--navy); color: #fff; }
em.late, b.late, .late { font-style: normal; color: var(--red); font-weight: 800; }
em.ontime, b.ontime { font-style: normal; color: var(--teal); font-weight: 800; }
.stops .r em { display: block; font-size: 12px; }
.now-card .live { margin-top: 10px; font-size: 13px; color: #cfd4ec; }
.now-card .live b { color: #fff; }
.now-card .row button[data-reorder] { background: rgba(255, 255, 255, .16); color: #fff; }
.demo .note { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.5; }
.ghost.slim { height: 42px; margin: 0; background: var(--bg); font-size: 13.5px; }
/* 순서 다시 짜기 판 */
.re-wait { margin: 18px 2px; font-size: 14px; color: var(--muted); }
.re-cmp { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; margin: 16px 0 8px; }
.re-cmp > div:not(.arr) { background: var(--bg); border-radius: 14px; padding: 12px; text-align: center; }
.re-cmp .best { background: var(--sky); }
.re-cmp span { display: block; font-size: 12px; color: var(--muted); font-weight: 700; }
.re-cmp b { font-size: 24px; color: var(--ink); }
.re-cmp .best b { color: var(--blue); }
.re-cmp .arr { color: var(--muted); font-weight: 900; }
.re-sum { font-size: 13.5px; color: var(--text); line-height: 1.55; margin: 8px 2px 10px; }
.re-list { list-style: none; margin: 0 0 14px; padding: 0; max-height: 34vh; overflow: auto; }
.re-list li { display: grid; grid-template-columns: 30px 1fr; column-gap: 10px; align-items: center; padding: 8px 4px; border-top: 1px solid #f1f2f6; font-size: 14px; }
.re-list li:first-child { border-top: 0; }
.re-list li.mv { background: var(--sky); border-radius: 10px; }
.re-list .no { grid-row: span 2; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 900; font-size: 12.5px; background: var(--c); }
.re-list b { color: var(--ink); font-size: 14px; }
.re-list em { font-style: normal; font-size: 12px; color: var(--muted); }
.re-note { font-size: 11.5px; color: var(--muted); margin: 12px 2px 0; line-height: 1.5; }
.re-chk { margin: 0 0 12px; padding: 12px 14px; border-radius: 14px; background: var(--teal-50); }
.re-chk.bad { background: var(--amber-50); }
.re-chk span { display: block; font-size: 12px; color: var(--muted); font-weight: 700; }
.re-chk b { display: block; font-size: 18px; color: var(--ink); margin: 2px 0; font-variant-numeric: tabular-nums; }
.re-chk em { font-style: normal; font-size: 13px; font-weight: 700; color: var(--teal); }
.re-chk.bad em { color: var(--amber); }

/* 넓은 화면(접는 폰 펼침·태블릿): 내용은 가운데 600px 안에 모아 버튼이 너무 길어지지 않게 */
.view, .sheet { padding-left: max(16px, calc(50% - 300px)); padding-right: max(16px, calc(50% - 300px)); }
.login { padding-left: max(26px, calc(50% - 260px)); padding-right: max(26px, calc(50% - 260px)); }
.detail { left: max(0px, calc(50% - 320px)); right: max(0px, calc(50% - 320px)); }
.tabs { padding-left: max(6px, calc(50% - 300px)); padding-right: max(6px, calc(50% - 300px)); }

/* 가로로 돌린 휴대폰(차량 거치대): 경로는 지도 왼쪽 · 목록 오른쪽, 노치 쪽 안전 영역 비움 */
@media (orientation: landscape) and (max-height: 520px) {
  .app { left: env(safe-area-inset-left, 0px); right: env(safe-area-inset-right, 0px); }
  .bar { padding-top: calc(var(--safe-t) + 6px); padding-bottom: 6px; }
  #v-route.on { flex-direction: row; }
  .map-wrap { height: auto; flex: 1 1 auto; }
  .map-leg { bottom: 10px; }
  .sheet { flex: 0 0 min(420px, 48%); margin-top: 0; border-radius: 0; box-shadow: -6px 0 20px rgba(14, 20, 64, .08); padding-left: 14px; padding-right: 14px; }
  .sheet .grab { display: none; }
  .detail { max-height: 92%; }
  /* 낮은 화면: 아래 탭을 한 줄(아이콘 옆 글자)로 줄여 내용 칸을 넓힘 */
  .tabs { padding-top: 2px; padding-bottom: calc(var(--safe-b) + 2px); }
  .tabs button { flex-direction: row; justify-content: center; gap: 6px; padding: 8px 0; font-size: 12.5px; }
  .tabs svg { width: 20px; height: 20px; }
  .view { padding-bottom: calc(var(--safe-b) + 60px); }
  .sheet { padding-bottom: calc(var(--safe-b) + 60px); }
  .map-wrap { margin-bottom: calc(var(--safe-b) + 44px); }
  .toast { bottom: calc(var(--safe-b) + 56px); }
  /* 시작 화면: 왼쪽 이름 · 오른쪽 입력 */
  .login { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; align-content: center; padding-top: calc(var(--safe-t) + 16px); padding-bottom: calc(var(--safe-b) + 16px); overflow-y: auto; }
  .login > * { grid-column: 2; }
  .login-top { grid-column: 1; grid-row: 1 / span 4; align-self: center; margin: 0; }
  .login .hint { margin: 10px 0 16px; }
}

/* 머리줄 오른쪽: 음성 안내 · 시각 */
.bar-r { display: flex; align-items: center; gap: 8px; }
.voice { width: 34px; height: 34px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .18); background: rgba(255, 255, 255, .08); color: #8f98c8; display: grid; place-items: center; padding: 0; }
.voice svg { width: 19px; height: 19px; fill: currentColor; }
.voice .w { display: none; }
.voice.on { color: #fff; background: var(--blue); border-color: var(--blue); }
.voice.on .w { display: inline; }

/* 정류장 자세히: 고객 요청 · 미배송 */
.d-memo { margin: 0 0 12px; padding: 11px 13px; border-radius: 14px; background: var(--amber-50); color: #7a4300; font-size: 14.5px; font-weight: 700; line-height: 1.45; }
.d-memo span { display: block; font-size: 11.5px; font-weight: 800; color: var(--amber); margin-bottom: 2px; }
.chip.bad { background: var(--red-50); color: var(--red); }
.d-done { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.d-done.bad { background: var(--red-50); color: var(--red); }
.d-done button { height: 32px !important; padding: 0 12px; border-radius: 9px !important; background: #fff; color: var(--navy); font-size: 12.5px !important; font-weight: 800; border: 0; flex: none; }
.d-fail { background: var(--bg); border-radius: 16px; padding: 14px; display: grid; gap: 12px; }
.d-fail h4 { margin: 0; font-size: 14.5px; color: var(--ink); }
.stepper { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 14px; font-weight: 700; }
.stepper div { display: flex; align-items: center; gap: 10px; }
.stepper button { width: 40px !important; height: 40px !important; border-radius: 12px !important; background: #fff; border: 1.5px solid var(--line) !important; font-size: 20px !important; font-weight: 800; }
.stepper b { min-width: 52px; text-align: center; font-size: 17px; color: var(--ink); font-variant-numeric: tabular-nums; }
.btn-red { background: var(--red); color: #fff; }

/* 센터에 알리기 */
.rp-text { width: 100%; min-height: 76px; border: 1.5px solid var(--line); border-radius: 14px; padding: 11px 13px; font: inherit; font-size: 15px; resize: none; margin: 12px 0; }
.rp-text:focus { outline: none; border-color: var(--blue); }
.reasons.big button { padding: 11px 14px; font-size: 14px; }
.notes li.sent::before { background: var(--navy); }

/* 하루 요약 */
.sum { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 14px 0 4px; }
.sum div { background: rgba(255, 255, 255, .1); border-radius: 14px; padding: 10px 8px; text-align: center; }
.sum b { display: block; font-size: 20px; color: #fff; font-variant-numeric: tabular-nums; }
.sum span { font-size: 11.5px; color: #c8cee8; }
.now-card .cmp { margin-top: 10px; font-size: 13px; color: #c8cee8; line-height: 1.55; }
.now-card .cmp b { color: #7fe3d6; }

.tile em i.bad { font-style: normal; color: var(--red); font-weight: 800; }

/* 시연 시각으로 보는 중이면 시계를 주황으로 */
.clock.sim { border-color: rgba(233, 177, 90, .7); }
.clock.sim .dot { background: #e9b15a; box-shadow: 0 0 0 3px rgba(233, 177, 90, .25); }
