/* Console v3 — shared classes of design/handoff/console-v3/artboards (ShopDash-A, ShopSales-A, ShopDB-A,
   ShopDBItem-A, EmpDash-A, EmpDB-B, EmpDaily-A, Settings-A). Every rule is scoped under .v3 so older
   screens keep their look; where an older global class has the same name (.kpi .tip .bar .mono
   .chart .inner, table cells) the properties it sets are reset here. The artboards' ".col" is ".vcol"
   here because v2.css styles every span inside a global .col (chart columns). */
#side nav .nav-label { margin: 16px 0 4px; }
.v3 { display: flex; flex-direction: column; gap: 20px; color: #182d32; font-size: 14px; line-height: 1.5; }
.v3 a { color: #12695c; }
.v3 a:hover { color: #0c4a41; }
.v3 h1 { margin: 0; font-size: 26px; line-height: 1.3; letter-spacing: 0; }
.v3 h2 { margin: 0; font-size: 17px; }
.v3 h3 { margin: 0; font-size: 15px; }
.v3 p { margin: 0; }
.v3 .mut { color: #586d70; }
.v3 .sm { font-size: 13px; }
.v3 .big { font-size: 24px; font-weight: 700; line-height: 1.3; }
.v3 .card { background: #fff; border: 1px solid #dce5e2; border-radius: 12px; padding: 18px 20px; min-width: 0; }
.v3 .row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.v3 .vcol { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.v3 .sp { margin-left: auto; }
.v3 .btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 18px; border-radius: 8px; border: 1px solid #b9cbc6; background: #fff; color: #12695c; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; white-space: nowrap; }
.v3 .btn.pri, .v3 .btn.pri:hover { background: #12695c; border-color: #12695c; color: #fff; }
.v3 .btn:disabled { opacity: 0.55; cursor: not-allowed; }
/* Touch targets of at least 44px (review r1 #12): text buttons and links in tables keep their line height in the
   layout (negative margin) while the clickable box is 44px tall. */
.v3 .link { display: inline-flex; align-items: center; background: none; border: 0; padding: 0 2px; margin: -10px 0; color: #12695c; font: inherit; font-weight: 700; text-align: left; cursor: pointer; min-height: 44px; min-width: 44px; }
.v3 td a:not(.btn), .v3 a.hit { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; margin: -10px 0; }
.v3 .link:hover { text-decoration: underline; }
.v3 .chip { display: inline-flex; align-items: center; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: #edf1ef; color: #465a5e; white-space: nowrap; line-height: 1.5; }
.v3 .chip.bad { background: #fde7e4; color: #8f1d17; }
.v3 .chip.wait { background: #fdf1d3; color: #6b4500; }
.v3 .chip.good { background: #e0f2ea; color: #0e5449; }
.v3 .chip.info { background: #e4eefb; color: #174c86; }
.v3 .chip.dark { background: #102f35; color: #fff; }
.v3 .chip.shp { background: #e9f3d9; color: #35520f; }
.v3 .chip.nc { background: #fff; color: #465a5e; box-shadow: inset 0 0 0 1px #9fb3ae; }
.v3 .chip.pend { background: #fff; color: #586d70; box-shadow: inset 0 0 0 1px #c7d3cf; font-weight: 600; }
/* "i" button: explanations live in the tooltip, not on the page. */
.v3 .tip { position: relative; display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 44px; height: 44px; margin: -12px -10px; padding: 0; border: 0; background: none; cursor: help; font: inherit; vertical-align: middle; color: inherit; }
.v3 .tip::before { content: "i"; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid #7b8f93; color: #465a5e; font-size: 12px; font-weight: 700; line-height: 16px; text-align: center; }
.v3 .tip > span { display: none; position: absolute; z-index: 9; top: 36px; left: 6px; width: 280px; padding: 10px 12px; border-radius: 8px; background: #102f35; color: #fff; font: 500 13px/1.5 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif; text-align: left; white-space: normal; box-shadow: 0 6px 18px rgba(16, 47, 53, 0.25); letter-spacing: 0; }
.v3 .tip.r > span { left: auto; right: 6px; }
.v3 .tip:hover > span, .v3 .tip:focus > span, .v3 .tip:focus-visible > span { display: block; }
/* Tables scroll inside their own area. */
.v3 .tw { overflow-x: auto; max-width: 100%; }
.v3 table { width: 100%; border-collapse: collapse; min-width: 640px; font-size: 14px; white-space: normal; }
.v3 th { text-align: left; font-size: 12px; color: #586d70; font-weight: 600; padding: 10px 12px; border-top: 0; border-bottom: 1px solid #dce5e2; white-space: nowrap; background: none; }
.v3 th small { display: block; font-weight: 500; color: #7b8f93; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px; }
.v3 td { padding: 10px 12px; border-top: 0; border-bottom: 1px solid #edf1ef; vertical-align: top; }
.v3 th:first-child, .v3 td:first-child { padding-left: 12px; }
.v3 td small { display: block; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px; color: #7b8f93; }
.v3 .num { text-align: right; font-variant-numeric: tabular-nums; }
.v3 tr.on td { background: #eef7e2; }
.v3 tr.diff td { background: #fdf1d3; }
.v3 tr.total td { font-weight: 700; background: #f4f7f4; }
.v3 td a { font-weight: 700; }
.v3 .mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; font-weight: inherit; line-height: inherit; color: inherit; }
.v3 .mono.mut { color: #586d70; }
.v3 .tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.v3 .tab { min-height: 44px; padding: 0 16px; border-radius: 8px; border: 1px solid #dce5e2; background: #fff; color: #33484c; font: inherit; font-weight: 600; cursor: pointer; }
.v3 .tab[aria-pressed="true"] { background: #102f35; border-color: #102f35; color: #fff; }
.v3 .tab small { font-size: 11px; font-weight: 700; color: #6b4500; margin-left: 2px; }
.v3 .tab[aria-pressed="true"] small { color: #fdf1d3; }
.v3 input[type="search"], .v3 input[type="text"], .v3 input[type="date"], .v3 input[type="number"], .v3 select { font: inherit; min-height: 44px; padding: 8px 12px; border: 1px solid #b9cbc6; border-radius: 8px; background: #fff; color: #182d32; min-width: 0; }
.v3 .kpi { flex: 1 1 170px; display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: 0; background: none; border: 0; border-radius: 0; }
.v3 .kpi:hover { border-color: transparent; }
.v3 .kpi b { font-size: 22px; line-height: 1.3; overflow-wrap: anywhere; }
.v3 .kv { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid #edf1ef; flex-wrap: wrap; }
.v3 .kvs { display: flex; flex-wrap: wrap; gap: 8px; }
.v3 .kvs > div { flex: 1 1 200px; background: #f4f7f4; border-radius: 8px; padding: 10px 12px; }
.v3 .kvs small { display: block; font-size: 12px; color: #586d70; font-weight: 600; }
.v3 .bar { height: 10px; border-radius: 5px; background: #edf1ef; overflow: hidden; max-width: none; width: auto; min-height: 0; }
.v3 .bar > i { display: block; height: 100%; background: #12695c; }
.v3 .dc { flex: 1 1 220px; display: flex; flex-direction: column; gap: 6px; }
.v3 .dc.warn { border: 2px solid #c98a00; }
/* 매출 — stacked day bars (pixel heights) and share bars. */
.v3 .chart { display: flex; align-items: flex-end; gap: 14px; padding: 8px 0 0; }
.v3 .chart > div { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 0; }
.v3 .chart.dense { gap: 3px; }
.v3 .chart.dense b { display: none; }
.v3 .chart.dense span { font-size: 10px; writing-mode: vertical-rl; }
.v3 .stk { width: 100%; max-width: 72px; display: flex; flex-direction: column; gap: 2px; border-radius: 6px 6px 0 0; overflow: hidden; }
.v3 .stk i { display: block; width: 100%; min-height: 0; }
.v3 .s1 { background: #102f35; }
.v3 .s2 { background: #2a9280; }
.v3 .s3 { background: #c2ed96; }
.v3 .s4 { background: #7aa6c2; }
.v3 .s5 { background: #c98a00; }
.v3 .s6 { background: #9aa9a9; }
.v3 .chart b { font-size: 13px; }
.v3 .chart span { font-size: 12px; color: #586d70; white-space: nowrap; }
.v3 .lg { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.v3 .lg i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; flex: none; }
.v3 .lg.miss { color: #586d70; }
.v3 .lg.miss i { background: #fff; box-shadow: inset 0 0 0 1.5px #9fb3ae; }
.v3 .bar.miss { background: repeating-linear-gradient(45deg, #edf1ef 0 6px, #fff 6px 12px); }
.v3 .ab { display: flex; align-items: center; gap: 10px; }
.v3 .ab > span { flex: 0 0 76px; font-weight: 700; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v3 .ab > .bar { flex: 1; }
.v3 .ab > b { flex: 0 0 auto; min-width: 120px; text-align: right; font-variant-numeric: tabular-nums; }
/* EMP 현황 — the flow strip (steps) is drawn differently from state values (chips). */
.v3 .inner { background: #eef7e2; box-shadow: inset 4px 0 0 #12695c; padding: 4px 16px 16px 48px; border-bottom: 1px solid #edf1ef; }
.v3 .inner > div { background: #fff; border: 1px solid #cfe5b0; border-radius: 10px; padding: 16px; display: flex; flex-direction: column; gap: 16px; }
.v3 .tl { display: flex; flex-wrap: wrap; row-gap: 18px; }
.v3 .ts { flex: 1 1 120px; padding: 14px 10px 0 0; border-top: 4px solid #12695c; position: relative; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.v3 .ts::before { content: ""; position: absolute; top: -10px; left: 0; width: 16px; height: 16px; border-radius: 50%; background: #12695c; border: 3px solid #fff; }
.v3 .ts.todo { border-top-color: #dce5e2; color: #586d70; }
.v3 .ts.todo::before { background: #b9cbc6; }
.v3 .ts.stop { border-top-color: #b3261e; color: #8f1d17; }
.v3 .ts.stop::before { background: #b3261e; }
/* EMP 데이터 조회 */
.v3 .pair { background: #f4f7f4; border-radius: 10px; padding: 12px 14px; }
/* 일자별 주문 상태 */
.v3 .day { flex: 1 1 96px; min-height: 72px; border-radius: 10px; border: 1px solid #dce5e2; background: #fff; font: inherit; color: #182d32; cursor: pointer; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 10px 12px; }
.v3 .day b { font-size: 20px; line-height: 1.2; }
.v3 .day[aria-pressed="true"] { background: #102f35; border-color: #102f35; color: #fff; }
.v3 .day em { font-style: normal; font-size: 12px; font-weight: 700; color: #8f1d17; }
.v3 .day[aria-pressed="true"] em { color: #ffb4ab; }
.v3 .day b.cut { font-size: 15px; }
/* 설정 · EMP API */
.v3 .sw { appearance: none; -webkit-appearance: none; flex: 0 0 46px; width: 46px; height: 26px; border-radius: 13px; background: #8d9c99; position: relative; cursor: pointer; margin: 0; }
.v3 .sw:checked { background: #12695c; }
.v3 .sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; }
.v3 .sw:checked::after { left: 23px; }
.v3 .sw:disabled { opacity: 0.5; cursor: not-allowed; }
.v3 .api { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; padding: 12px 0; border-top: 1px solid #edf1ef; }
/* The six states: each reads differently in words and look, never as "0건". */
.v3 .state { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 12px 14px; border-radius: 10px; background: #f4f7f4; border: 1px solid #dce5e2; min-width: 0; }
.v3 .state.error { background: #fff8f7; border-color: #f3c9c4; }
.v3 .state.disconnected { background: #fff; border: 1px dashed #9fb3ae; }
.v3 .state.noscope { background: #fffaf0; border-color: #f0dca8; }
.v3 .state.off { background: #eef1f0; border-color: #c7d3cf; }
.v3 .state.pending { background: #fff; border: 1px dotted #b9cbc6; }
.v3 .state.loading { background: #f6f9fd; border-color: #d3e1f2; }
.v3 .state.unknown { background: #fff; border: 2px dashed #9fb3ae; }
/* "확인된 n건 기준" under a partial sum. */
.v3 small.basis { display: block; font-size: 11px; font-weight: 600; color: #6b4500; font-family: inherit; }
.v3 .state .tip { margin: -12px -10px -12px -6px; }
/* EMP query: the server's fixed wording, its optional detail line in small type below. */
.v3 .state .emsg { flex-basis: 100%; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.v3 .state .emsg small { font-size: 12px; overflow-wrap: anywhere; }
/* Mirror screens (흐름 관제 · 원본 ↔ 재현 · EMP 예상 변경) — artboards FlowCity / FlowCityDash. */
.v3 .gl { flex: none; margin-right: 4px; vertical-align: -2px; }
.v3 .chip.plan { background: #ece7f6; color: #4b3a86; }
.v3 .chip.est { background: #f7f5fc; color: #4b3a86; box-shadow: none; border: 1.5px dashed #7056ae; padding: 2px 9px; }
.v3 .btn.est { border: 2px dashed #7056ae; color: #4b3a86; background: #f7f5fc; }
.v3 .seg2 { display: inline-flex; background: #e6ebe9; border-radius: 10px; padding: 4px; gap: 4px; }
.v3 .seg2 button, .v3 .seg2 a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border: 0; border-radius: 8px; font: inherit; font-weight: 700; cursor: pointer; background: transparent; color: #33484c; text-decoration: none; }
.v3 .seg2 button[aria-pressed="true"], .v3 .seg2 a[aria-current] { background: #102f35; color: #fff; }
.v3 .stg { flex: 1 1 190px; border-radius: 10px; padding: 10px 14px; background: #f4f7f4; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.v3 .stg small { font-size: 12px; font-weight: 700; color: #586d70; }
.v3 .stg b { font-size: 20px; line-height: 1.3; }
.v3 .stg.plan { background: #f7f5fc; }
.v3 .stg.plan small { color: #4b3a86; }
.v3 .stg.now { background: #fdf1d3; }
.v3 .stg.now small { color: #6b4500; }
.v3 .stg.now b { font-size: 15px; }
.v3 .cnts { display: flex; flex-wrap: wrap; gap: 8px; }
.v3 .cnt { flex: 1 1 110px; border-radius: 8px; background: #f4f7f4; padding: 8px 12px; display: flex; flex-direction: column; transition: background-color 0.6s, box-shadow 0.6s; }
.v3 .cnt b { font-size: 20px; line-height: 1.3; }
.v3 .evs { display: flex; flex-direction: column; gap: 6px; max-height: 560px; overflow-y: auto; padding: 2px; }
.v3 .ev { display: flex; flex: 0 0 auto; flex-wrap: wrap; gap: 10px; align-items: center; width: 100%; min-height: 56px; padding: 8px 12px; border-radius: 8px; border: 1px solid #dce5e2; background: #fff; font: inherit; color: inherit; text-align: left; cursor: pointer; transition: background-color 0.6s, box-shadow 0.6s; }
.v3 .ev[aria-pressed="true"] { border: 2px solid #12695c; background: #eef7e2; }
.v3 .ev time { flex: 0 0 82px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; }
.v3 .ev > div { flex: 1 1 160px; min-width: 0; }
.v3 .ev small { display: block; color: #586d70; font-size: 12.5px; overflow-wrap: anywhere; }
.v3 .fresh { background-color: #fdf1d3; box-shadow: 0 0 0 2px #c98a00; }
.v3 .tk { display: flex; flex-wrap: wrap; gap: 6px; }
.v3 .tk > div { flex: 1 1 130px; border-radius: 8px; padding: 8px 10px; border: 1.5px solid #dce5e2; display: flex; flex-direction: column; gap: 2px; font-size: 13px; min-width: 0; background: #f4f7f4; color: #586d70; }
.v3 .tk small { font-size: 12px; font-weight: 700; display: flex; align-items: center; }
.v3 .tk > .tk-done { border-color: #12695c; background: #e0f2ea; color: #0e5449; }
.v3 .tk > .tk-plan { border: 1.5px dashed #7056ae; background: #f7f5fc; color: #4b3a86; }
.v3 .tk > .tk-hold { border: 1.5px dashed #9b620d; background: #fdf1d3; color: #6b4500; }
.v3 .tk > .tk-fail { border-color: #b3261e; background: #fde7e4; color: #8f1d17; }
/* Expected EMP change: the purple dashed frame never used for real EMP values. */
.v3 .act { border: 2px dashed #7056ae; border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; background: #f7f5fc; }
.v3 .act.hold { border-color: #9b620d; background: #fffaf0; }
.v3 .act.fail { border-color: #b3261e; background: #fff8f7; }
.v3 .act.none { border-color: #8a9a9d; background: #f7f9f8; }
.v3 .actsum { font-size: 16px; }
.v3 .estimate { border: 2px dashed #7056ae; background: #fbfaff; }
.v3 .estimate td { background: transparent; }
.v3 .q { display: flex; flex-direction: column; gap: 10px; padding-top: 12px; border-top: 1px solid #edf1ef; }
.v3 .sel { border: 2px solid #12695c; }
.v3 .c3 .sel { padding: 12px; border-radius: 8px; }
.v3 .holdline { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 8px 0; border-top: 1px solid #edf1ef; }
.v3 .pay table, .v3 .q table { min-width: 0; }
.v3 .gid { overflow-wrap: anywhere; word-break: break-all; }
.v3 .rel { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 8px 0; border-top: 1px solid #edf1ef; }
/* 흐름 관제 ② : the event's own target and the current corrected order, drawn apart. */
.v3 .tgt { border: 1px solid #dce5e2; border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.v3 .tgt.cur { border: 2px solid #12695c; }
.v3 .state.nochange { background: #f3faf6; border: 1px solid #b8dcc9; border-left: 4px solid #12695c; }
.v3 .state.unchecked { background: #fff; border: 2px dashed #c98a00; }
.v3 .state.before { background: #fff; border: 1px dotted #9fb3ae; }
/* The scene: the artboard's SVG with overlay rings, segments and labels at its percentages. */
.v3 .scene { position: relative; width: 100%; aspect-ratio: 760 / 480; background: #eef3f1; border-radius: 12px; overflow: hidden; }
.v3 .scene svg { position: absolute; left: 0; top: 0; width: 100%; height: 100%; }
.v3 .sg { position: absolute; height: 0; transform-origin: 0 50%; border-top: 4px dashed #8a9a9d; pointer-events: none; color: #8a9a9d; }
.v3 .sg.k-done { border-top-style: solid; border-top-color: #12695c; color: #12695c; }
.v3 .sg.k-plan { border-top-color: #7056ae; color: #7056ae; }
.v3 .sg.k-hold { border-top-color: #9b620d; color: #9b620d; }
.v3 .sg.k-fail { border-top-color: #b3261e; color: #b3261e; }
.v3 .sl { position: absolute; transform: translate(-50%, -50%); display: inline-flex; align-items: center; font-size: 12px; font-weight: 700; color: #fff; padding: 2px 9px; border-radius: 999px; white-space: nowrap; pointer-events: none; background: #6b7b7e; }
.v3 .sl.k-done { background: #12695c; }
.v3 .sl.k-plan { background: #7056ae; }
.v3 .sl.k-hold { background: #9b620d; }
.v3 .sl.k-fail { background: #b3261e; }
.v3 .ring { position: absolute; width: 11%; aspect-ratio: 2 / 1; transform: translate(-50%, -50%); border-radius: 50%; border: 3px solid #12695c; pointer-events: none; }
.v3 .sg .dot { position: absolute; top: -9px; left: 0; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; background: #fff; border: 4px solid currentColor; opacity: 0; transition: left 0.7s linear, opacity 0.15s; }
.v3 .scene.go .sg .dot { left: 100%; opacity: 1; }
.v3 .replay { position: absolute; left: 12px; top: 12px; display: inline-flex; align-items: center; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: #102f35; color: #fff; }
.v3 .c3 { flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.v3 .sto { border-radius: 10px; padding: 12px 14px; border: 1px solid #dce5e2; background: #f4f7f4; display: flex; flex-direction: column; gap: 4px; }
.v3 .sto.observing, .v3 .sto.mirror_target { background: #fff; }
.v3 .sto.on { border: 2px solid #12695c; }
@media (prefers-reduced-motion: reduce) {
  .v3 .sg .dot { display: none; }
  .v3 .ev, .v3 .cnt { transition: none; }
}
@media (max-width: 720px) {
  .v3 { gap: 16px; }
  .v3 .ev time { flex-basis: 64px; }
  .v3 .sl { font-size: 10px; padding: 1px 6px; }
  .v3 h1 { font-size: 22px; }
  .v3 .card { padding: 14px; }
  .v3 .tip > span { width: min(280px, calc(100vw - 72px)); }
  .v3 .ab { flex-wrap: wrap; }
  .v3 .ab > span { flex-basis: 100% !important; }
  .v3 .ab > b { min-width: 0; }
  .v3 .chart { gap: 6px; }
  .v3 .chart b { font-size: 11px; }
  .v3 .inner { padding: 4px 8px 12px 16px; }
  .v3 input[type="search"] { flex-basis: 100% !important; }
}
