/* 다울해운항공 정산·B/L 관리자 — daulair.com 브랜드 컬러 기반 */
:root {
  --navy: #0b1d3a;
  --navy-2: #122a52;
  --blue: #1e3a8a;
  --accent: #2563eb;
  --accent-soft: #dbeafe;
  --red: #dc2626;
  --green: #15803d;
  --amber: #b45309;
  --bg: #f4f7fc;
  --card: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(11, 29, 58, 0.06), 0 8px 24px rgba(11, 29, 58, 0.06);
  --sans: "Pretendard", "Malgun Gothic", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); }
[hidden] { display: none !important; }

.boot { padding: 40vh 0; text-align: center; color: var(--muted); }

/* ---------- 로그인 ---------- */
.login {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 24px;
  background: radial-gradient(1200px 600px at 50% -10%, #1e3a8a 0%, #0b1d3a 60%, #071227 100%);
}
.login__card {
  width: 100%;
  max-width: 380px;
  background: var(--card);
  border-radius: 20px;
  padding: 32px 26px 26px;
  box-shadow: 0 24px 60px rgba(4, 12, 28, 0.45);
}
.login__logo { display: block; width: 168px; height: auto; margin: 0 auto 14px; }
.login__card h1 { font-size: 19px; text-align: center; margin: 0 0 22px; color: var(--navy); }
.login label { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 12px; }
.login input {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfdff;
  font-size: 16px;
}
.login input:focus { outline: 2px solid var(--accent); border-color: var(--accent); background: #fff; }
.login input[name="code"] { text-align: center; letter-spacing: 8px; font-size: 24px; font-weight: 700; }
.login button {
  width: 100%;
  margin-top: 6px;
  padding: 13px;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}
.login button:hover { background: var(--blue); }
.login button.ghost { background: transparent; color: var(--muted); margin-top: 8px; }
.login__hint { font-size: 13px; color: var(--muted); text-align: center; margin: 0 0 10px; }
.login__msg { min-height: 20px; margin: 12px 0 0; color: var(--red); font-size: 13px; text-align: center; }
.login__foot { margin: 18px 0 0; padding-top: 14px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); text-align: center; }

/* ---------- 상단 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 10px 20px;
  background: var(--navy);
  color: #fff;
  box-shadow: 0 2px 12px rgba(6, 16, 36, 0.25);
}
.topbar__brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.topbar__brand img { height: 30px; width: auto; display: block; }
.topbar__title { font-size: 13px; color: #a8bccf; white-space: nowrap; }
.tabs { display: flex; gap: 4px; flex: 1; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button {
  border: 0;
  background: transparent;
  color: #c9d7e6;
  padding: 8px 14px;
  border-radius: 9px;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}
.tabs button:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.tabs button.is-active { background: #fff; color: var(--navy); }
.topbar__user { display: flex; align-items: center; gap: 10px; font-size: 13px; color: #c9d7e6; white-space: nowrap; }
.ghost { background: transparent; border: 1px solid rgba(255, 255, 255, 0.35); color: #fff; padding: 6px 10px; border-radius: 8px; cursor: pointer; }
.topbar__user .ghost:hover { background: rgba(255, 255, 255, 0.12); }

.banner {
  flex-wrap: wrap;
  background: #fff7ed;
  border-bottom: 1px solid #fed7aa;
  color: #9a3412;
  padding: 9px 20px;
  font-size: 13px;
  display: flex;
  gap: 8px;
  align-items: center;
}
.banner strong { font-weight: 700; white-space: nowrap; }
.banner span { flex: 1 1 260px; }

/* ---------- 공통 ---------- */
.view { max-width: 1220px; margin: 0 auto; padding: 20px 18px 80px; }
.section { margin-bottom: 22px; }
.section__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 10px; }
.section__head h2 { font-size: 17px; margin: 0; color: var(--navy); }
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.grid { display: grid; gap: 12px; }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.muted { color: var(--muted); font-size: 13px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; color: var(--muted); word-break: break-all; }
.field { display: flex; flex-direction: column; gap: 5px; font-size: 13px; color: var(--muted); font-weight: 600; }
.field input, .field select, .field textarea {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fbfdff;
  color: var(--ink);
  font-weight: 400;
  font-size: 15px;
  width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--accent); border-color: var(--accent); background: #fff; }
.field--wide { grid-column: span 2; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  border: 0;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}
.btn:hover { background: var(--blue); }
.btn--ghost { background: #eef3fb; color: var(--blue); }
.btn--ghost:hover { background: var(--accent-soft); }
.btn--danger { background: #fef2f2; color: var(--red); }
.btn--danger:hover { background: #fee2e2; }
.btn--sm { padding: 6px 10px; font-size: 13px; border-radius: 7px; }
.icon-btn { border: 0; background: transparent; font-size: 18px; cursor: pointer; color: var(--muted); padding: 4px 8px; border-radius: 8px; }
.icon-btn:hover { background: var(--accent-soft); }
textarea { resize: vertical; min-height: 64px; }

/* 계산 패널 */
.calc--full { width: 100%; margin-top: 14px; }
.form-actions { margin-top: 14px; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 500; color: var(--ink); font-size: 14px; padding: 9px 0; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }
.calc {
  background: linear-gradient(180deg, #f8fbff, #eef4ff);
  border: 1px solid #dbe7fb;
  border-radius: 12px;
  padding: 14px 16px;
}
.calc dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 18px; margin: 0; }
.calc div { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.calc dt { color: var(--muted); font-size: 13px; }
.calc dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.calc__total { grid-column: span 2; border-top: 1px dashed #c7d9f7; padding-top: 8px; }
.calc__total dd { color: var(--blue); font-size: 20px; }

/* 표 */
.table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid var(--line); background: var(--card); }
table.data { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 760px; }
table.data th, table.data td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
table.data th { background: #f7fafe; color: var(--muted); font-size: 12px; font-weight: 700; white-space: nowrap; }
table.data td.num, table.data th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.data tbody tr:hover { background: #f9fbff; }
table.data tbody tr:last-child td { border-bottom: 0; }
.empty { padding: 28px; text-align: center; color: var(--muted); font-size: 14px; }
.pill { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.pill--ready { background: #eef2ff; color: #3730a3; }
.pill--move { background: #e0f2fe; color: #0369a1; }
.pill--customs { background: #fef3c7; color: #92400e; }
.pill--done { background: #dcfce7; color: #166534; }
.pill--unpaid { background: #fee2e2; color: #b91c1c; }
.pill--paid { background: #e2e8f0; color: #334155; }
select.inline { padding: 6px 8px; border: 1px solid var(--line); border-radius: 7px; background: #fff; font-size: 13px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
.toolbar .field { min-width: 130px; }
.toolbar .field input, .toolbar .field select { padding: 8px 10px; font-size: 14px; }

/* KPI · 차트 */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.kpi { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.kpi__label { font-size: 12px; color: var(--muted); font-weight: 700; }
.kpi__value { font-size: 22px; font-weight: 800; margin-top: 6px; font-variant-numeric: tabular-nums; color: var(--navy); }
.kpi__sub { font-size: 12px; color: var(--muted); margin-top: 4px; }
.kpi--accent { background: linear-gradient(160deg, #1e3a8a, #0b1d3a); border-color: #122a52; }
.kpi--accent .kpi__label, .kpi--accent .kpi__sub { color: #b9cbe4; }
.kpi--accent .kpi__value { color: #fff; }
.chart-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.chart-card h3 { margin: 0 0 12px; font-size: 15px; color: var(--navy); }
.chart svg { display: block; width: 100%; height: auto; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--muted); margin-top: 8px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: middle; }
.bars { display: grid; gap: 9px; }
.bar { display: grid; grid-template-columns: 118px 1fr 92px; align-items: center; gap: 10px; font-size: 13px; }
.bar > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar__track { background: #eef3fb; border-radius: 6px; height: 10px; overflow: hidden; }
.bar__fill { background: var(--accent); height: 100%; border-radius: 6px; }
.bar__value { text-align: right; font-variant-numeric: tabular-nums; color: var(--navy); font-weight: 700; white-space: nowrap; }
.gauge { display: flex; align-items: center; gap: 18px; }
.gauge__value { font-size: 28px; font-weight: 800; color: var(--navy); }
.gauge__meta { font-size: 13px; color: var(--muted); }

/* 청구서 (화면) */
.invoice-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 26px 18px; margin-bottom: 18px; box-shadow: var(--shadow); }
.invoice-brand { text-align: center; }
.invoice-brand__logo { width: 132px; height: auto; }
.invoice-brand__tagline { margin: 2px 0 0; font-size: 10.5px; letter-spacing: 1.4px; color: var(--muted); }
.invoice-brand__title { margin: 10px 0 0; font-size: 28px; letter-spacing: 7px; font-weight: 800; color: var(--navy); border-bottom: 2px solid var(--navy); padding-bottom: 8px; }
.invoice-meta-grid { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin: 14px 0 10px; }
.invoice-meta-grid p { margin: 0 0 4px; font-size: 14px; }
.invoice-meta-grid .k { display: inline-block; width: 46px; font-weight: 800; letter-spacing: 0.5px; color: var(--navy); font-size: 12px; }
.invoice-meta-grid .v { color: var(--ink); }
.invoice-meta-grid .v.strong { font-weight: 700; }
.invoice-meta-grid__right { text-align: right; }
.invoice-table table.data { min-width: 720px; font-size: 13px; }
.invoice-table table.data th { font-size: 11px; letter-spacing: 0.4px; text-transform: uppercase; }
.invoice-table tfoot td { background: #f7fafe; border-top: 2px solid var(--navy); font-weight: 800; }
.invoice-total-label { text-align: center; letter-spacing: 2px; font-size: 12px; }
.invoice-total-sum { text-align: right; color: var(--blue); font-size: 15px; }
.invoice-notice { margin-top: 14px; border: 1px solid #c9d6e8; border-radius: 10px; background: #fbfcfe; padding: 12px 16px; }
.invoice-notice p { margin: 0 0 4px; font-size: 12px; color: #334155; line-height: 1.5; }
.invoice-notice__title { text-align: center; font-weight: 800; letter-spacing: 1px; color: var(--navy); margin-bottom: 6px !important; }
.invoice-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; margin-top: 14px; flex-wrap: wrap; }
.invoice-foot p { margin: 0 0 3px; font-size: 12px; color: #334155; }
.invoice-foot__bank strong { color: var(--navy); }
.invoice-foot__contact { text-align: right; }
.invoice-foot__contact img { width: 78px; height: auto; opacity: 0.9; margin-bottom: 3px; }
.invoice-printdate { margin: 14px 0 0; text-align: center; font-size: 11px; letter-spacing: 1px; color: var(--muted); }

/* 모달 */
.modal { border: 0; border-radius: 16px; padding: 0; width: min(560px, 94vw); box-shadow: 0 30px 80px rgba(8, 20, 44, 0.35); }
.modal--wide { width: min(860px, 96vw); }
.modal::backdrop { background: rgba(8, 17, 35, 0.55); }
.modal__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: #fff; z-index: 2; }
.modal__head h2 { font-size: 16px; margin: 0; color: var(--navy); }
#modal-body { padding: 18px; max-height: 78vh; overflow: auto; }

/* 스티커 */
.sticker-wrap { display: grid; grid-template-columns: 300px 1fr; gap: 18px; align-items: start; }
.sticker-preview { background: #eef2f8; border-radius: 10px; padding: 14px; }
.sticker {
  width: 100mm;
  height: 150mm;
  padding: 6mm;
  background: #fff;
  color: #000;
  display: flex;
  flex-direction: column;
  gap: 3mm;
  border: 1px solid #cbd5e1;
  box-sizing: border-box;
  font-family: var(--sans);
}
.sticker-preview .sticker { width: 260px; height: 390px; padding: 14px; gap: 8px; border-radius: 6px; transform-origin: top left; }
.sticker__top { display: flex; align-items: center; justify-content: space-between; }
.sticker__logo { width: 34mm; height: auto; }
.sticker-preview .sticker__logo { width: 96px; }
.sticker__badge { border: 1.2px solid #0b1d3a; border-radius: 999px; padding: 1mm 3mm; font-size: 3.4mm; font-weight: 800; }
.sticker__bl { border-top: 1.4px solid #000; border-bottom: 1.4px solid #000; padding: 2mm 0; }
.sticker__bl-label { display: block; font-size: 2.8mm; letter-spacing: 1px; }
.sticker__bl-no { display: block; font-size: 7.4mm; letter-spacing: 0.6px; font-weight: 800; }
.sticker__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.6mm 4mm; }
.sticker__grid span { display: block; font-size: 2.6mm; color: #444; }
.sticker__grid strong { font-size: 4mm; }
.sticker__item-label { font-size: 2.6mm; color: #444; }
.sticker__item p { margin: 0.6mm 0 0; font-size: 4mm; font-weight: 700; min-height: 8mm; }
.sticker__qr { display: flex; flex-direction: column; align-items: center; gap: 1mm; margin-top: auto; }
.sticker__qr-canvas { width: 34mm; height: 34mm; }
.sticker-preview .sticker__qr-canvas { width: 104px; height: 104px; }
.sticker__qr-hint { font-size: 2.6mm; margin: 0; color: #333; }
.sticker__foot { border-top: 1px dashed #999; padding-top: 1.6mm; font-size: 2.4mm; color: #222; }
.sticker__foot p { margin: 0; }
.sticker__foot-name { font-weight: 800; font-size: 3mm; }
.sticker-info { display: grid; gap: 10px; align-content: start; }

/* 첨부 */
.attach-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.attach { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: #f8fafc; position: relative; }
.attach img { display: block; width: 100%; height: 100px; object-fit: cover; }
.attach__doc { display: grid; place-items: center; height: 100px; font-size: 13px; color: var(--muted); }
.attach__meta { padding: 6px 8px; font-size: 11px; color: var(--muted); display: flex; justify-content: space-between; gap: 4px; align-items: center; }
.attach__del { border: 0; background: transparent; color: var(--red); cursor: pointer; font-size: 12px; }
.dropzone { border: 1.5px dashed #c7d7ee; border-radius: 10px; padding: 14px; text-align: center; color: var(--muted); font-size: 13px; background: #f9fbff; }
.dropzone input { display: none; }
.dropzone label { cursor: pointer; color: var(--accent); font-weight: 700; }

/* 알림 이력 */
.log-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.log-list li { display: grid; grid-template-columns: 92px 74px 1fr auto; gap: 8px; font-size: 12px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 8px; background: #fbfdff; align-items: center; }
.log-list--flex li { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.log-list--flex li .mono { flex: 1 1 120px; }
.tag { font-size: 11px; padding: 2px 7px; border-radius: 999px; background: #eef2ff; color: #3730a3; font-weight: 700; }
.tag--sent { background: #dcfce7; color: #166534; }
.tag--failed { background: #fee2e2; color: #b91c1c; }
.tag--simulated { background: #fef3c7; color: #92400e; }

/* 토스트 */
#toast-root { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); display: grid; gap: 8px; z-index: 60; width: min(520px, 92vw); }
.toast { background: #0b1d3a; color: #fff; padding: 12px 16px; border-radius: 10px; font-size: 14px; box-shadow: 0 10px 30px rgba(6, 16, 36, 0.3); transition: opacity 0.3s, transform 0.3s; }
.toast--error { background: #7f1d1d; }
.toast--ok { background: #14532d; }
.toast.is-out { opacity: 0; transform: translateY(6px); }

/* 인쇄 */
.print-root { display: none; }
body.printing #app, body.printing #login, body.printing .topbar, body.printing #toast-root,
body.printing #modal, body.printing #modal::backdrop { display: none !important; }
body.printing .print-root { display: block; }
body.printing { background: #fff; }

@media (max-width: 900px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sticker-wrap { grid-template-columns: 1fr; }
  .topbar { flex-wrap: wrap; gap: 8px; padding: 8px 12px; }
  .tabs { order: 3; flex-basis: 100%; }
  .topbar__title { display: none; }
  .view { padding: 14px 12px 70px; }
  .calc dl { grid-template-columns: 1fr; }
  .calc__total { grid-column: span 1; }
  .field--wide { grid-column: span 1; }
  .bar { grid-template-columns: 74px 1fr 74px; }
}
@media (max-width: 560px) {
  .banner { display: block; font-size: 12.5px; }
  .banner strong { display: block; margin-bottom: 3px; }
  .section__head { flex-direction: column; align-items: flex-start; gap: 4px; }
  .kpis { grid-template-columns: 1fr 1fr; }
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .invoice-head { flex-direction: column; }
  .invoice-meta { text-align: left; }
}

/* ---------- 2차: DAUL Desk 기능 ---------- */
.login__sub { display: block; font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: 0.4px; margin-top: 4px; }
.login__card--wide { max-width: 420px; }
.setup__qr { display: grid; place-items: center; margin: 4px 0 10px; }
.setup__qr canvas { width: 196px; height: 196px; border: 10px solid #fff; border-radius: 12px; box-shadow: 0 2px 10px rgba(11, 29, 58, 0.12); background: #fff; }
.setup__secret { margin: 0 0 14px; font-size: 12px; color: var(--muted); text-align: center; }
.setup__secret code { display: inline-block; margin-top: 4px; padding: 4px 8px; border-radius: 6px; background: #eef3fb; color: var(--navy); font-size: 12px; letter-spacing: 1px; word-break: break-all; }
.pwd-grid { display: grid; gap: 10px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 560px) { .pwd-grid { grid-template-columns: 1fr; } }
.stack { display: flex; flex-direction: column; gap: 3px; align-items: flex-start; }
.mt { margin-top: 16px; }
.unpaid-text { color: #b91c1c; font-size: 11.5px; font-weight: 700; }
.warn-text { color: #b45309; font-size: 12px; }
.ok-text { color: var(--green); font-size: 12px; }

/* 등급 배지 (내부 전용) */
.pill--grade-new { background: #eef2ff; color: #3730a3; }
.pill--grade-stable { background: #e0f2fe; color: #0369a1; }
.pill--grade-b { background: #f0fdf4; color: #15803d; }
.pill--grade-g { background: #fef9c3; color: #854d0e; }
.pill--grade-s { background: #0b1d3a; color: #fff; }

/* 청구서 ROUTE 배지 · DETAIL LIST */
.route-badge {
  display: inline-block;
  min-width: 30px;
  padding: 1px 7px;
  border: 1px solid var(--navy);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.4px;
  text-align: center;
  color: var(--navy);
  background: #fff;
}
.invoice-detail {
  margin-top: 12px;
  border: 1px dashed #b9c6d8;
  border-radius: 10px;
  padding: 10px 14px;
  background: #fbfcfe;
}
.invoice-detail__title { margin: 0 0 6px; font-size: 11px; letter-spacing: 1px; font-weight: 800; color: var(--navy); }
.invoice-detail ul { margin: 0; padding-left: 16px; font-size: 12px; color: #334155; }
.invoice-actions { margin: 0 0 8px; justify-content: flex-end; }

/* 매니페스트 업로드 · 미리보기 */
.dropzone--manifest { padding: 22px 16px; }
.dropzone--manifest.is-over { border-color: var(--accent); background: var(--accent-soft); }
.manifest-table { min-width: 980px; }
.manifest-table td { font-size: 13px; vertical-align: middle; }
.manifest-table select.inline { max-width: 170px; }

/* 메일 미리보기 */
.mail-preview {
  margin: 0;
  max-height: 260px;
  overflow: auto;
  background: #0b1d3a;
  color: #e6eefc;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 12px;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}

/* 분석 표 · KPI */
.kpis--profit { margin-top: 12px; }
.kpi--profit { background: linear-gradient(160deg, #ecfdf5, #ffffff); border-color: #bbf7d0; }
.kpi--profit .kpi__value { color: #14532d; }
.table-wrap--plain { border: 0; background: transparent; }
table.data--compact { min-width: 0; font-size: 13px; }
table.data--compact th, table.data--compact td { padding: 7px 9px; }
table.data tr.row--warn td { color: #b91c1c; }
.bar--trend { grid-template-columns: 58px 1fr 74px; }
.quick-range { margin-bottom: 10px; }
@media (max-width: 900px) {
  .quick-range .btn { flex: 1 1 auto; }
}

/* 2차: 청구 메일 미리보기 */
.attach-list { display: grid; gap: 2px; border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; background: #fbfdff; }
.attach-check { font-weight: 500; font-size: 13.5px; padding: 5px 0; }
.check--confirm { border-top: 1px dashed #c7d9f7; margin-top: 4px; padding-top: 10px; font-weight: 600; }

/* 3단계 권한 배지 */
.pill--role-superadmin { background: #0b1d3a; color: #fff; }
.pill--role-manager { background: #dbeafe; color: #1e3a8a; }
.pill--role-staff { background: #e2e8f0; color: #334155; }
.users-form { margin-top: 12px; }
.users-edit { margin-top: 10px; background: #f8fbff; }

/* 원장: 열이 많아 가로 스크롤을 허용하되 폭을 확보 */
table.data.ledger-table { min-width: 1180px; }
table.data.ledger-table td:nth-child(1) { white-space: nowrap; }
table.data.ledger-table td:nth-child(2) { white-space: nowrap; }
