/* CLEARSHIELD PRO 보증서·재고 — 관리자 화면
   매장 PC, 밝은 사무실 조명에서 표와 입력칸을 오래 보는 화면 → 밝은 작업면 + 짙은 남색 메뉴.
   오렌지는 주요 버튼과 현재 위치에만. 파랑은 링크·초점·선택. */

:root {
  /* SolarLuxe IR: 로고 먹색 + 흰 작업면 + 연보라 기 도는 회색 + 페리윙클 강조. 무지갯빛은 면 단위로만 */
  --navy: #17151b;          /* 사이드바·어두운 버튼 (로고 먹색) */
  --navy-2: #201e26;
  --navy-line: #2f2c37;
  --navy-ink: #d9d6e3;
  --navy-mute: #938ea3;

  --bg: #f4f4f8;
  --surface: #ffffff;
  --surface-2: #f8f8fb;
  --line: #e4e3ec;
  --line-strong: #cfcdda;
  --ink: #18161c;
  --ink-2: #34313d;
  --mute: #625e6e;
  --mute-2: #8e8a99;

  --blue: #4c5bd4;          /* 페리윙클: 링크·초점·선택 */
  --blue-ink: #3a47b8;
  --blue-soft: #eef0fd;
  --orange: #18161c;        /* 주요 버튼 = 먹색 (옛 오렌지 자리) */
  --orange-press: #000000;
  --orange-soft: #efeef4;
  --iris: linear-gradient(118deg, #a6dcf6 0%, #aebaf7 42%, #cbbdf3 72%, #e9d6f5 100%);
  --iris-line: linear-gradient(90deg, #8fd0f2, #9aa6f5 45%, #c4aef0);

  --ok: #157a4a;   --ok-soft: #e6f5ec;
  --warn: #9a5200; --warn-soft: #fff3e0;
  --bad: #c5282f;  --bad-soft: #fdecec;

  --r-sm: 6px; --r: 8px; --r-lg: 12px;
  --shadow-1: 0 1px 2px rgb(0 0 0 / .06), 0 1px 1px rgb(0 0 0 / .04);
  --shadow-pop: 0 14px 34px -10px rgb(0 0 0 / .28), 0 2px 6px rgb(0 0 0 / .08);
  --side-w: 232px;
  --font: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 14.5px/1.55 var(--font); letter-spacing: -0.005em;
  word-break: keep-all; overflow-wrap: anywhere;
  -webkit-font-smoothing: antialiased;
}
::selection { background: rgb(76 91 212 / .18); color: inherit; }
a { color: var(--blue-ink); text-underline-offset: 3px; }
h1, h2, h3 { margin: 0; letter-spacing: -0.02em; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--mute); }
.num, .tbl td.a-num { font-variant-numeric: tabular-nums; }
.icon { flex: none; }
* { scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }

/* ---- 첫 화면 ---- */
/* 앱 시작 화면(manifest background_color)과 같은 남색에서 로그인 화면으로 이어짐 */
.boot-loading { min-height: 100vh; min-height: 100dvh; display: grid; place-content: center; justify-items: center; gap: 18px; color: #c9d2e4;
  background: radial-gradient(110% 70% at 50% 45%, #12306e 0%, #0a1428 48%, #000 100%); }
.boot-loading .wordmark { width: min(300px, 64vw); height: auto; color: #fff; animation: boot-in .6s ease-out both; }
.boot-line { width: 64px; height: 3px; background: var(--orange); transform-origin: left center; animation: boot-line 1.2s cubic-bezier(.45, 0, .25, 1) .2s infinite alternate both; }
@keyframes boot-in { from { opacity: 0; transform: translateY(6px); } }
@keyframes boot-line { from { transform: scaleX(.15); opacity: .5; } to { transform: scaleX(1); opacity: 1; } }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--blue); animation: spin .8s linear infinite; }
.boot-loading .spinner { border-color: rgb(255 255 255 / .16); border-top-color: #fff; }
@media (prefers-reduced-motion: reduce) { .boot-loading .wordmark, .boot-line { animation: none; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- 로그인 ---- */
.login { min-height: 100vh; display: grid; grid-template-columns: minmax(380px, 520px) 1fr; }
.login-panel { background: var(--surface); padding: clamp(32px, 6vh, 72px) clamp(28px, 4vw, 64px); display: flex; flex-direction: column; justify-content: center; gap: 36px; }
.login-brand .wordmark { width: 260px; height: auto; color: var(--navy); display: block; }
.login-product { margin-top: 12px; color: var(--mute); font-size: 15px; }
.login-form { display: grid; gap: 16px; max-width: 360px; }
.login-error { color: var(--bad); background: var(--bad-soft); padding: 10px 12px; border-radius: var(--r); font-size: 13.5px; }
.login-help { color: var(--mute); font-size: 13px; }
.btn-block { width: 100%; justify-content: center; height: 46px; font-size: 15px; }
.login-aside { background: #03060d; color: #f5f5f7; display: flex; flex-direction: column; justify-content: flex-end; gap: 22px; padding: clamp(40px, 9vh, 96px) clamp(32px, 5vw, 72px) clamp(28px, 5vh, 48px); position: relative; overflow: hidden; isolation: isolate; }
/* Higgsfield로 만든 어두운 차량 사진을 패널 전체 배경으로 (위쪽 어두운 공간에 문구) */
.login-car { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; object-fit: cover; object-position: 50% 74%; }
/* 사진 위 검정 30% 막 + 위아래 그늘: 은은한 배경 */
.login-aside::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(rgb(0 0 0 / .3), rgb(0 0 0 / .3)), linear-gradient(180deg, rgb(3 6 13 / .35) 0%, rgb(3 6 13 / 0) 30%, rgb(3 6 13 / 0) 85%, rgb(3 6 13 / .45) 100%); }
/* 사진 정중앙 로고 하나 */
.login-aside-mark { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; pointer-events: none; }
.login-aside-mark::after { content: ""; width: 88px; height: 4px; margin-top: 26px; background: var(--orange); }
.login-aside-mark .wordmark { width: min(74%, 540px); height: auto; color: #fff; filter: drop-shadow(0 2px 18px rgb(0 0 0 / .55)); }
/* 등장: 로고가 왼쪽부터 드러나고(그림자까지 보이게 위아래·좌우 여유), 이어 오렌지 선이 왼쪽부터 그어짐 */
@media (prefers-reduced-motion: no-preference) {
  .login-aside-mark .wordmark { clip-path: inset(-40% 110% -40% -10%); animation: login-mark-in 1.2s cubic-bezier(.55, .1, .3, 1) .3s forwards; }
  .login-aside-mark::after { transform: scaleX(0); transform-origin: left center; animation: login-mark-line .7s cubic-bezier(.4, 0, .2, 1) 1.35s forwards; }
}
@keyframes login-mark-in { to { clip-path: inset(-40% -10% -40% -10%); } }
@keyframes login-mark-line { to { transform: scaleX(1); } }
/* 로그인 사진: 아래 고객 조회, 오른쪽 위 앱 설치 */
.login-links { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.login-install { position: absolute; top: clamp(16px, 3vh, 28px); right: clamp(16px, 3vw, 32px); z-index: 1; display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid rgb(255 255 255 / .4);
  background: rgb(255 255 255 / .1); color: #fff; font: 600 14px/1 var(--font); cursor: pointer; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transition: background .15s, border-color .15s; }
.login-install:hover { background: rgb(255 255 255 / .18); border-color: rgb(255 255 255 / .7); }
.login-install:focus-visible { outline-color: #8fb0ff; }
.login-remember { display: flex; align-items: center; justify-content: space-between; gap: 8px 14px; flex-wrap: wrap; }
.login-remember .check { font-size: 14px; }
.login-remember .check input { width: 18px; height: 18px; accent-color: var(--blue); }
.login-remember span { color: var(--mute); font-size: 12.5px; }
.install-steps { margin: 0; padding-left: 22px; display: grid; gap: 12px; }
.install-steps li { padding-left: 4px; }
.install-steps b { display: block; color: var(--ink); }
.install-steps span { color: var(--mute); font-size: 13.5px; }
.install-ico { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 6px; background: var(--blue-soft); color: var(--blue-ink); vertical-align: -6px; margin: 0 2px; }
.login-check { position: relative; color: var(--navy-ink); display: inline-flex; gap: 8px; align-items: center; text-decoration: none; font-size: 14px; align-self: flex-start; }
.login-check:hover { color: #fff; }
.demo-login { border-top: 1px solid var(--line); padding-top: 24px; max-width: 420px; }
.demo-login-title { font-weight: 650; }
.demo-login-text { color: var(--mute); font-size: 13px; margin: 4px 0 14px; }
.demo-accounts { display: grid; gap: 6px; }
.demo-acc { display: flex; align-items: center; gap: 10px; text-align: left; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r); padding: 9px 12px; cursor: pointer; transition: border-color .15s, background .15s; }
.demo-acc:hover { border-color: var(--blue); background: var(--blue-soft); }
.demo-acc-name { font-weight: 600; }
.demo-acc-sub { color: var(--mute); font-size: 12.5px; margin-left: auto; }
@media (max-width: 860px) {
  .login { grid-template-columns: 1fr; }
  .login-aside { order: -1; min-height: 340px; gap: 14px; padding: 30px 20px 18px; }
  .login-car { object-position: 50% 82%; }
  .login-aside-mark .wordmark { width: 76%; }
  .login-aside-mark::after { width: 60px; height: 3px; margin-top: 16px; }
}

/* ---- 틀 ---- */
.has-shell .app { display: grid; grid-template-columns: var(--side-w) 1fr; min-height: 100vh; }
.skip { position: absolute; left: 12px; top: -48px; z-index: 50; background: var(--surface); padding: 8px 12px; border-radius: var(--r); }
.skip:focus { top: 12px; }
.side { position: sticky; top: 0; height: 100vh; background: var(--navy); color: var(--navy-ink); display: flex; flex-direction: column; padding: 20px 12px 14px; overflow-y: auto; }
.side-brand { display: grid; gap: 6px; padding: 4px 10px 22px; color: #f5f5f7; text-decoration: none; }
.side-brand .wordmark { width: 168px; height: auto; color: #f5f5f7; }
.side-brand-sub { color: var(--navy-mute); font-size: 12.5px; }
.nav { display: grid; gap: 18px; }
.nav-group { display: grid; gap: 2px; }
.nav-group-label { color: var(--navy-mute); font-size: 12px; font-weight: 600; padding: 0 10px 4px; }
.nav-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--r); color: var(--navy-ink); text-decoration: none; font-weight: 500; transition: background .15s, color .15s; }
.nav-item:hover { background: rgb(255 255 255 / .06); color: #fff; }
.nav-item.is-on { background: rgb(255 255 255 / .08); color: #fff; }
.nav-item.is-on .icon { color: var(--orange); }
.nav-item:focus-visible { outline-color: #8fb0ff; }
.side-foot { margin-top: auto; padding-top: 16px; border-top: 1px solid var(--navy-line); display: grid; gap: 4px; }
.side-me { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: var(--r); color: #fff; text-decoration: none; }
.side-me:hover { background: rgb(255 255 255 / .06); }
.side-me-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-logout { display: flex; align-items: center; gap: 8px; background: none; border: 0; color: var(--navy-mute); padding: 8px 10px; border-radius: var(--r); cursor: pointer; text-align: left; }
.side-logout:hover { color: #fff; background: rgb(255 255 255 / .06); }
.guide-text { width: 100%; min-height: 300px; font: 13.5px/1.6 var(--font); padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface-2); color: var(--ink); resize: vertical; }
.role-dot { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 11.5px; font-weight: 650; flex: none; }
.role-master { background: var(--orange-soft); color: #a3400a; }
.role-distributor { background: var(--blue-soft); color: var(--blue-ink); }
.role-dealer { background: var(--veu-soft); color: #0a6b6b; }
.side .role-master { background: rgb(255 106 19 / .16); color: #ffb58a; }
.side .role-distributor { background: rgb(76 91 212 / .18); color: #a9c1ff; }
.side .role-dealer { background: rgb(13 138 138 / .22); color: #8fe0de; }

.content { min-width: 0; display: flex; flex-direction: column; }
.main { padding: 28px clamp(20px, 3vw, 40px) 64px; max-width: 1480px; width: 100%; outline: none; }
.mobile-top { display: none; }
.scrim { display: none; }
.demo-bar { display: flex; align-items: center; gap: 16px; justify-content: space-between; background: #fff7ef; border-bottom: 1px solid #f6d9c2; color: #6b3610; font-size: 13px; padding: 8px clamp(20px, 3vw, 40px); }
.demo-bar-reset { background: none; border: 1px solid #ecc4a5; border-radius: var(--r-sm); padding: 4px 10px; color: inherit; cursor: pointer; white-space: nowrap; }
.demo-bar-reset:hover { background: #fff; }

@media (max-width: 1024px) {
  .has-shell .app { grid-template-columns: 1fr; }
  .side { position: fixed; inset: 0 auto 0 0; width: var(--side-w); z-index: 40; transform: translateX(-100%); transition: transform .22s var(--ease); }
  .nav-open .side { transform: none; }
  .nav-open .scrim { display: block; position: fixed; inset: 0; background: rgb(20 16 32 / .4); z-index: 30; }
  .mobile-top { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: var(--surface); border-bottom: 1px solid var(--line); font-weight: 650; position: sticky; top: 0; z-index: 20; }
  .main { padding: 20px 16px 56px; }
}

/* ---- 페이지 머리 ---- */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.page-title { display: flex; align-items: center; gap: 10px; min-width: 0; }
.page-title h1 { font-size: 24px; font-weight: 700; line-height: 1.25; }
.page-sub { color: var(--mute); margin-top: 4px; font-size: 14px; }
.back { display: grid; place-items: center; width: 34px; height: 34px; border-radius: var(--r); color: var(--ink-2); border: 1px solid var(--line); background: var(--surface); flex: none; }
.back:hover { border-color: var(--line-strong); }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.section-title { font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.section-title .count { color: var(--mute); font-weight: 500; font-size: 14px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.section-head a { font-size: 13.5px; text-decoration: none; }

/* ---- 버튼 ---- */
.btn { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px; border-radius: var(--r); border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); font-weight: 600; font-size: 14px; cursor: pointer; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, box-shadow .15s, transform .08s; }
.btn:hover { background: var(--surface-2); border-color: #bdbaca; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--orange); border-color: var(--orange); color: var(--navy); }
.btn-primary:hover { background: var(--orange-press); border-color: var(--orange-press); }
.btn-dark { background: var(--navy); border-color: var(--navy); color: #fff; }
.btn-dark:hover { background: #000; border-color: #000; }
.btn-danger { background: var(--surface); border-color: #efb8bb; color: var(--bad); }
.btn-danger:hover { background: var(--bad-soft); border-color: var(--bad); }
.btn-ghost { border-color: transparent; background: transparent; }
.btn-ghost:hover { background: rgb(24 22 28 / .05); border-color: transparent; }
.btn-sm { height: 30px; padding: 0 10px; font-size: 13px; }
.btn.is-busy { position: relative; color: transparent !important; }
.btn.is-busy::after { content: ""; position: absolute; inset: 0; margin: auto; width: 16px; height: 16px; border-radius: 50%; border: 2px solid rgb(24 22 28 / .25); border-top-color: var(--navy); animation: spin .7s linear infinite; }
.btn.is-busy .icon { opacity: 0; }
.icon-btn { display: grid; place-items: center; width: 34px; height: 34px; border-radius: var(--r); border: 0; background: transparent; color: var(--ink-2); cursor: pointer; }
.icon-btn:hover { background: rgb(24 22 28 / .06); }

/* ---- 입력칸 ---- */
.field { display: grid; gap: 6px; align-content: start; min-width: 0; }
.field-label { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.req { color: var(--orange-press); }
.field-hint { font-size: 12.5px; color: var(--mute); }
.field-error { font-size: 12.5px; color: var(--bad); }
:where(input:not([type=checkbox]):not([type=radio]):not([type=file]), select, textarea) {
  width: 100%; height: 40px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: var(--r); background: var(--surface);
  transition: border-color .15s, box-shadow .15s; caret-color: var(--blue);
}
textarea { height: auto; padding: 10px 12px; resize: vertical; line-height: 1.55; }
select { appearance: none; padding-right: 34px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%235d6a84' stroke-width='2' stroke-linecap='round' viewBox='0 0 24 24'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 10px center; }
input::placeholder, textarea::placeholder { color: var(--mute-2); }
input:hover, select:hover, textarea:hover { border-color: #bdbaca; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgb(76 91 212 / .16); }
input[aria-invalid], select[aria-invalid], textarea[aria-invalid] { border-color: var(--bad); box-shadow: 0 0 0 3px rgb(197 40 47 / .12); }
input:disabled, select:disabled, textarea:disabled { background: var(--surface-2); color: var(--mute); }
input[type=checkbox], input[type=radio] { accent-color: var(--blue); width: 16px; height: 16px; margin: 0; }
input[type=number] { font-variant-numeric: tabular-nums; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 18px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px 18px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px 18px; }
.field-wide { grid-column: 1 / -1; }
.consent { display: grid; gap: 6px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface-2); }
.consent-check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; font-size: 14px; line-height: 1.45; }
.consent-check input { width: 18px; height: 18px; margin-top: 1px; flex: none; accent-color: var(--blue); }
.consent .field-hint { padding-left: 28px; }
.consent .field-hint a { color: var(--blue-ink); }
.consent .field-error { padding-left: 28px; }
@media (max-width: 860px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 500; }
.input-unit { position: relative; }
.input-unit input { padding-right: 34px; }
.input-unit span { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--mute); font-size: 13px; pointer-events: none; }

/* ---- 면 ---- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
.panel-body { padding: 20px 22px; }
.panel + .panel { margin-top: 16px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 22px; border-bottom: 1px solid var(--line); }
.panel-head h2 { font-size: 16px; font-weight: 700; }
.stack { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.stack > *, .panel { min-width: 0; }
.cols { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 20px; align-items: start; }
@media (max-width: 1180px) { .cols { grid-template-columns: 1fr; } }

/* ---- 도구 줄 (검색·필터) ---- */
.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.toolbar .search { position: relative; flex: 1 1 280px; max-width: 420px; }
.toolbar .search .icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--mute); }
.toolbar .search input { padding-left: 38px; }
.toolbar select, .toolbar input[type=date] { width: auto; min-width: 128px; }
.toolbar .spacer { flex: 1; }
.seg { display: inline-flex; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r); padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; height: 30px; padding: 0 12px; border-radius: var(--r-sm); cursor: pointer; color: var(--mute); font-weight: 600; font-size: 13.5px; }
.seg button:hover { color: var(--ink); }
.seg button.is-on { background: var(--navy); color: #fff; }

/* ---- 표 ---- */
.tbl-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 12.5px; font-weight: 600; color: var(--mute); padding: 10px 14px; background: var(--surface-2); border-bottom: 1px solid var(--line); white-space: nowrap; position: sticky; top: 0; }
.tbl td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tr.is-link { cursor: pointer; }
.tbl tr.is-link:hover td { background: #f5f5fb; }
.tbl tr.is-link:focus-visible { outline-offset: -2px; }
.tbl tr.is-dim td { color: var(--mute-2); }
.tbl .a-num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl .a-center { text-align: center; }
.tbl .strong { font-weight: 650; }
.tbl .mono, .mono { font-variant-numeric: tabular-nums; letter-spacing: .01em; }
.tbl .sub { font-weight: 400; display: block; color: var(--mute); font-size: 12.5px; margin-top: 1px; }
.tbl .nowrap { white-space: nowrap; }
.tbl-compact td { padding: 8px 12px; }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; color: var(--mute); font-size: 13px; }
.pager-btns { display: flex; gap: 4px; }
.pg { min-width: 32px; height: 32px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--surface); cursor: pointer; display: grid; place-items: center; font-variant-numeric: tabular-nums; }
.pg:hover:not(:disabled) { border-color: var(--line-strong); }
.pg.is-on { background: var(--navy); border-color: var(--navy); color: #fff; }
.pg:disabled { opacity: .4; cursor: default; }

/* ---- 휴대폰: 표는 가로로 밀어 보기, 보증서 목록은 카드 ---- */
@media (max-width: 860px) {
  .tbl { min-width: 760px; }
  .tbl.tbl-certs { min-width: 0; }
  .tbl-certs thead { display: none; }
  .tbl-certs, .tbl-certs tbody { display: block; }
  .tbl-certs tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
  .tbl-certs tbody tr:last-child { border-bottom: 0; }
  .tbl-certs td { display: block; padding: 0; border: 0; text-align: left; min-width: 0; }
  .tbl-certs tr.is-link:hover td { background: transparent; }
  .tbl-certs .c-serial { grid-column: 1; grid-row: 1; align-self: center; font-size: 15px; }
  .tbl-certs .c-state { grid-column: 2; grid-row: 1; justify-self: end; align-self: center; }
  .tbl-certs .c-shop { grid-column: 1 / -1; }
  .tbl-certs .c-car, .tbl-certs .c-cust { grid-column: 1 / -1; font-weight: 600; }
  .tbl-certs .c-car .sub, .tbl-certs .c-cust .sub { display: inline; margin-left: 8px; font-weight: 400; }
  .tbl-certs .c-parts { grid-column: 1 / -1; color: var(--mute); font-size: 13px; }
  .tbl-certs .c-parts > span { max-width: none !important; }
  .tbl-certs td.c-price { grid-column: 1; font-weight: 700; text-align: left; }
  .tbl-certs .c-date { grid-column: 2; justify-self: end; color: var(--mute); font-size: 13px; align-self: center; }
}

/* ---- 휴대폰: 목록 표는 카드 (첫 열 = 제목, 나머지 = 항목 이름 | 값) ---- */
@media (max-width: 860px) {
  .tbl.tbl-cards { min-width: 0; }
  .tbl-cards thead { display: none; }
  .tbl-cards, .tbl-cards tbody { display: block; }
  .tbl-cards tr { display: grid; gap: 7px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
  .tbl-cards tbody tr:last-child { border-bottom: 0; }
  .tbl-cards tr.is-link:hover td { background: transparent; }
  .tbl-cards td { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 10px; align-items: baseline; padding: 0; border: 0; text-align: left; min-width: 0; white-space: normal; }
  .tbl-cards td.a-num, .tbl-cards td.a-center { text-align: left; }
  .tbl-cards td::before { content: attr(data-label); color: var(--mute); font-size: 12.5px; font-weight: 500; }
  .tbl-cards td:first-child { display: block; font-size: 15px; padding-bottom: 2px; }
  .tbl-cards td:first-child::before, .tbl-cards td.td-actions::before { content: none; }
  .tbl-cards td.td-actions { display: flex; justify-content: flex-end; padding-top: 4px; }
  .tbl-cards td.is-blank { display: none; }
  .tbl-cards td > * { justify-self: start; }
  .tbl-cards td > .meter { justify-self: stretch; }
  .tbl-cards .meter { min-width: 0; max-width: 260px; }
  .tbl-cards .meter-val { text-align: left; }
  .tbl-cards td > span > .sub { display: inline; margin-left: 6px; }
  .tbl-cards .holder .sub, .tbl-cards .prod .prod-brand { display: block; margin-left: 0; }
  .tbl-cards td:first-child .holder, .tbl-cards td:first-child .prod { grid-auto-flow: column; justify-content: start; align-items: center; gap: 8px; }
}

.m-only { display: none; }
@media (max-width: 860px) {
  .m-only { display: inline; color: var(--mute); font-weight: 400; }
  .tbl.tbl-stock { min-width: 0; }
  .tbl-stock thead { display: none; }
  .tbl-stock, .tbl-stock tbody { display: block; }
  .tbl-stock tr { display: grid; grid-auto-flow: dense; grid-template-columns: auto minmax(0, 1fr) auto; gap: 8px 10px; align-items: center; padding: 13px 16px; border-bottom: 1px solid var(--line); }
  .tbl-stock tbody tr:last-child { border-bottom: 0; }
  .tbl-stock tr.is-link:hover td { background: transparent; }
  .tbl-stock td { display: block; padding: 0; border: 0; min-width: 0; text-align: left; }
  .tbl-stock .c-holder { grid-column: 1 / -1; }
  .tbl-stock .c-holder .holder { grid-auto-flow: column; justify-content: start; align-items: center; gap: 8px; }
  .tbl-stock .c-prod { grid-column: 1; }
  .tbl-stock .c-prod .prod { grid-auto-flow: column; align-items: center; gap: 6px; }
  .tbl-stock .c-prod .prod-brand { display: none; }
  .tbl-stock .c-box { grid-column: 2; }
  .tbl-stock .c-box .sub { display: inline; margin-left: 6px; }
  .tbl-stock .c-lot { grid-column: 3; font-size: 12.5px; text-align: right; }
  .tbl-stock .c-meter { grid-column: 1 / 3; }
  .tbl-stock .c-meter .meter { min-width: 0; }
  .tbl-stock td.c-date { grid-column: 3; text-align: right; font-size: 12.5px; color: var(--ink-2); }
  .tbl-stock .c-state { grid-column: 1 / -1; }
  .tbl-stock .c-act { grid-column: 1 / -1; display: flex; justify-content: flex-end; }
  .tbl-stock .c-act:empty, .tbl-stock .c-act > span:empty { display: none; }
  /* 고르기 체크: 카드 맨 아래 줄 왼쪽, 보내기·폐기 버튼과 같은 줄 */
  .tbl-stock tr td.c-pick { grid-column: 1; grid-row: 3; width: auto; padding: 0; }
  .tbl-stock tr:has(td.c-pick) .c-act { grid-column: 2 / -1; grid-row: 3; }
  .tbl-stock td.c-pick:empty { display: none; }
  /* 고른 롤 막대: 휴대폰은 화면 아래 탭 바로 위에 떠 있게 */
  /* (아래쪽 PC 규칙보다 앞에 있어 선택자를 한 단계 높임) */
  .bulk-bar.bulk-bar { position: fixed; top: auto; left: 12px; right: 12px; bottom: calc(58px + 10px + env(safe-area-inset-bottom)); z-index: 24; margin: 0; padding: 10px 10px 10px 14px; }
  .bulk-bar.bulk-bar .bulk-count { flex-basis: 100%; }
  .bulk-bar.bulk-bar .btn { flex: 1 1 0; justify-content: center; }
  .has-shell .main:has(.bulk-bar:not([hidden])) { padding-bottom: calc(58px + 28px + 96px + env(safe-area-inset-bottom)); }
}

/* ---- 배지 ---- */
.shop-chip { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 6px; background: var(--blue-soft); color: var(--blue-ink); border: 1px solid #cfdcff; font-size: 13px; font-weight: 650; white-space: nowrap; }
.shop-chip.is-dist { background: #eef1f5; color: var(--ink-2); border-color: #d6dce6; }
.holder { display: grid; justify-items: start; gap: 4px; }
.holder .sub { margin-top: 0; }
.prod { display: grid; justify-items: start; gap: 3px; }
.prod-name { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 6px; border: 1px solid; font-size: 13px; font-weight: 650; white-space: nowrap; }
.prod-clear { background: var(--blue-soft); color: var(--blue-ink); border-color: #cfdcff; }
.prod-matte { background: #eef1f5; color: #262d3a; border-color: #cbd3df; }
.prod-veu { background: var(--veu-soft); color: #0a6b6b; border-color: #b9e2df; }
.prod-brand { font-size: 10.5px; font-weight: 650; letter-spacing: .08em; color: var(--mute); }
button.shop-chip { cursor: pointer; font-family: inherit; transition: background .15s, border-color .15s; }
button.shop-chip:hover { background: #dce7ff; border-color: var(--blue); }
button.shop-chip.is-dist:hover { background: #e3e7ee; border-color: var(--mute-2); }
.owner-sum { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); margin-bottom: 12px; overflow: hidden; }
.owner-sum-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--surface-2); font-size: 13.5px; }
.owner-sum-head .shop-chip { height: 30px; font-size: 14.5px; }
.owner-sum-close { margin-left: auto; }
/* 대리점 하나 고르면 나오는 제품별 요약 표 (2026-11-25: 큰 숫자 칸 → 작은 표) */
.owner-sum-scroll { overflow-x: auto; }
.owner-sum-tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; font-variant-numeric: tabular-nums; }
.owner-sum-tbl th, .owner-sum-tbl td { padding: 9px 14px; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--line); }
.owner-sum-tbl tbody tr:last-child > * { border-bottom: 0; }
.owner-sum-tbl thead th { font-weight: 600; }
.owner-sum-tbl th[scope=row] { text-align: left; font-weight: 600; color: var(--mute); font-size: 12.5px; width: 1%; }
.owner-sum-tbl td { color: var(--ink); font-weight: 600; }
.owner-sum-tbl td.is-zero { color: var(--mute-2); font-weight: 400; }
.owner-sum-tbl .is-total { background: #eef2f8; font-weight: 700; color: var(--ink); }
.owner-sum-tbl .prod-name { height: 24px; padding: 0 8px; font-size: 12px; font-weight: 600; white-space: pre; }
.owner-sum-tbl .osum-sub { display: block; font-size: 11.5px; font-weight: 500; color: var(--mute); margin-top: 1px; }
.owner-sum-tbl tr.osum-rec > * { border-top: 1px dashed var(--line); }
@media (max-width: 860px) {
  .owner-sum-tbl .osum-brand { display: none; }   /* 휴대폰: 모델명만(S, S PLUS …)으로 한 화면에 */
  .owner-sum-tbl th, .owner-sum-tbl td { padding: 8px 4px; font-size: 12px; }
  .owner-sum-tbl th[scope=row] { padding-left: 10px; white-space: normal; min-width: 44px; }
  .owner-sum-tbl td:last-child, .owner-sum-tbl th:last-child { padding-right: 10px; }
  .owner-sum-tbl .prod-name { padding: 0 5px; font-size: 11.5px; height: 22px; }
}
.owner-sum-body { display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); }
.owner-sum-item { display: grid; justify-items: start; gap: 4px; padding: 14px 16px; }
.owner-sum-item + .owner-sum-item { border-left: 1px solid var(--line); }
.owner-sum-item b { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.owner-sum-item .muted { font-size: 12.5px; font-variant-numeric: tabular-nums; }
.owner-sum-total { background: #eef2f8; }
.owner-sum-total > span:first-child { font-size: 13px; font-weight: 650; color: var(--ink-2); height: 26px; display: inline-flex; align-items: center; }
@media (max-width: 860px) {
  .owner-sum-body { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .owner-sum-item:nth-child(3) { border-left: 0; }
  .owner-sum-item:nth-child(n+3) { border-top: 1px solid var(--line); }
  .owner-sum-close { margin-left: 0; }
}
/* ---- 통합 재고표 (본사): 엑셀처럼 칸이 많은 표. 첫 열 고정, 가로로 밀어 봄 ---- */
.lg-wrap { overflow-x: auto; }
.ledger { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 14px; font-variant-numeric: tabular-nums; }
.ledger th, .ledger td { padding: 9px 12px; border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); text-align: right; white-space: nowrap; height: 44px; }
.ledger tr > :last-child { border-right: 0; }
.ledger thead th { font-size: 12.5px; font-weight: 600; color: var(--mute); background: var(--surface-2); text-align: center; height: auto; padding: 8px 10px; }
.ledger thead th small { display: block; font-size: 11px; font-weight: 500; color: var(--mute-2); }
.ledger thead .lg-g { color: var(--ink-2); font-weight: 700; }
.ledger .lg-prod { position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: left; min-width: 150px; box-shadow: 1px 0 0 var(--line); }
.ledger thead .lg-prod { background: var(--surface-2); z-index: 2; }
.ledger tbody .lg-prod small { display: block; font-size: 11.5px; color: var(--mute-2); font-weight: 500; margin-top: 2px; }
.ledger td.lg-open { color: var(--mute); }
.ledger .lg-in { background: #fbfcfe; }
.ledger thead .lg-in { background: #eef2f8; }
.ledger .lg-hq { background: var(--blue-soft); color: var(--blue-ink); font-weight: 750; }
.ledger thead .lg-hq { background: #dce7ff; color: var(--blue-ink); }
.ledger thead .lg-now.lg-g { background: #e3ebff; color: var(--blue-ink); }
.ledger td.lg-now:not(.lg-hq) { color: var(--ink-2); }
.ledger .lg-alt { background: #f9fafc; }
.ledger thead .lg-out { background: #f3f5f9; }
.ledger thead .lg-out.lg-alt { background: #eceff5; }
.ledger thead .lg-cur { box-shadow: inset 0 -2px 0 var(--blue); }
.ledger thead .lg-cur { color: var(--ink); }
.ledger .lg-sum { font-weight: 750; background: #f3f5f9; }
.ledger .lg-gone { color: var(--mute); }
.ledger .lg-neg { color: var(--bad); }
.ledger .lg-q { display: inline-flex; flex-direction: column; align-items: flex-end; line-height: 1.15; }
.ledger .lg-part { font-size: 11.5px; font-weight: 600; color: var(--mute); }
.ledger tbody tr:hover > * { background-image: linear-gradient(rgb(76 91 212 / .04), rgb(76 91 212 / .04)); }
.ledger tfoot th, .ledger tfoot td { border-bottom: 0; border-top: 2px solid var(--line-strong); font-weight: 750; background: var(--surface-2); }
.ledger tfoot .lg-prod { background: var(--surface-2); }
.ledger tfoot .lg-hq { background: #dce7ff; }
.lg-note { margin: 10px 2px 0; font-size: 12.5px; color: var(--mute); line-height: 1.6; max-width: 980px; }
/* 출고 현황 */
.lg-ship td { text-align: right; }
.lg-ship .lg-date { position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: left; box-shadow: 1px 0 0 var(--line); }
.lg-ship thead .lg-date { background: var(--surface-2); z-index: 2; }
.lg-ship tfoot .lg-date { background: var(--surface-2); }
.lg-ship .lg-to, .lg-ship .lg-memo { text-align: left; }
.lg-ship .lg-memo { white-space: normal; min-width: 140px; }
.lg-ship tbody tr { cursor: pointer; }
.lg-ship tbody tr:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }
.lg-ship .lg-badge { margin-left: 6px; }
.lg-ship tr.lg-ret td { background: #fffaf3; }
@media (max-width: 860px) {
  .ledger th, .ledger td { padding: 8px 10px; font-size: 13.5px; }
  .ledger .lg-prod { min-width: 112px; }
  .page-ledger .toolbar .spacer { display: none; }
}

/* 제품 풀네임: CLEARSHIELD PRO는 옅고 작게, 모델명(S · S PLUS · M)은 굵게 (2026-11-23) */
.pl { white-space: nowrap; }
.pl-brand { font-size: .84em; font-weight: 600; letter-spacing: .02em; opacity: .62; }
.pl-model { font-weight: 800; letter-spacing: -0.01em; }
.film-maker { font-size: 11.5px; font-weight: 650; letter-spacing: .04em; color: var(--fc); opacity: .65; line-height: 1.1; }
.film-card.is-on .film-maker { color: #fff; opacity: .72; }
.ledger .lg-prod { min-width: 210px; }
.serial-cell { letter-spacing: .06em; }
.badge { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 12px; font-weight: 650; white-space: nowrap; background: var(--surface-2); color: var(--mute); }
.badge-ok { background: var(--ok-soft); color: var(--ok); }
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.badge-bad { background: var(--bad-soft); color: var(--bad); }
.badge-void { background: #eef1f5; color: var(--mute); }
.badge-info { background: var(--blue-soft); color: var(--blue-ink); }
.fam { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; white-space: nowrap; }
.fam::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: currentColor; }
.fam-clear { color: var(--clear); }
.fam-matte { color: var(--matte); }
.fam-veu { color: var(--veu); }

/* ---- 남은 길이 막대 ---- */
.meter { display: flex; align-items: center; gap: 10px; min-width: 150px; }
.meter-bar { flex: 1; height: 6px; background: #e8e7f0; border-radius: 999px; overflow: hidden; }
.meter-bar i { display: block; height: 100%; background: var(--blue); border-radius: inherit; }
.meter.is-low .meter-bar i { background: var(--orange); }
.meter-val { font-variant-numeric: tabular-nums; font-weight: 650; min-width: 52px; text-align: right; }

/* ---- 비어 있음 · 불러오는 중 ---- */
.empty { display: grid; justify-items: center; gap: 6px; text-align: center; padding: 44px 20px; color: var(--mute); background: var(--surface); border: 1px dashed var(--line-strong); border-radius: var(--r-lg); }
.empty .icon { color: var(--mute-2); margin-bottom: 4px; }
.empty-title { color: var(--ink-2); font-weight: 650; }
.empty-text { font-size: 13.5px; max-width: 46ch; }
.empty .btn { margin-top: 10px; }
.empty-page { margin-top: 10vh; border: 0; background: transparent; }
.skeleton { display: grid; gap: 10px; }
.sk-row, .sk-title { height: 40px; border-radius: var(--r); background: linear-gradient(90deg, #ececf2 0%, #f6f6f9 50%, #ececf2 100%); background-size: 200% 100%; animation: sk 1.2s ease-in-out infinite; }
.sk-title { height: 30px; width: 240px; margin-bottom: 22px; }
@keyframes sk { from { background-position: 100% 0; } to { background-position: -100% 0; } }

/* ---- 알림 ---- */
.toasts { position: fixed; right: 20px; bottom: 20px; z-index: 100; display: grid; gap: 8px; }
.toast { display: flex; align-items: center; gap: 10px; background: var(--navy); color: #fff; padding: 12px 16px; border-radius: var(--r); box-shadow: var(--shadow-pop); max-width: 420px; animation: toast-in .2s var(--ease); font-size: 14px; }
.toast-ok .icon { color: #7fe0a8; }
.toast-error { background: #4a0f13; }
.toast-error .icon { color: #ff9ca1; }
.toast.out { opacity: 0; transform: translateY(6px); transition: .2s; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

/* ---- 대화상자 ---- */
.dlg { border: 0; padding: 0; border-radius: var(--r-lg); width: min(480px, calc(100vw - 32px)); box-shadow: var(--shadow-pop); color: var(--ink); }
.dlg-wide { width: min(720px, calc(100vw - 32px)); }
.dlg::backdrop { background: rgb(20 16 32 / .45); }
.dlg[open] { animation: dlg-in .18s var(--ease); }
@keyframes dlg-in { from { opacity: 0; transform: translateY(8px) scale(.99); } }
.dlg-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 6px; }
.dlg-head h2 { font-size: 18px; font-weight: 700; }
.dlg-body { padding: 10px 20px 20px; display: grid; gap: 16px; }
.dlg-msg { color: var(--ink-2); }
.dlg-foot { display: flex; justify-content: flex-end; gap: 8px; padding-top: 4px; }
.dlg-note { background: var(--surface-2); border-radius: var(--r); padding: 12px 14px; font-size: 13.5px; color: var(--ink-2); }

.pick-list { display: grid; gap: 2px; max-height: 232px; overflow-y: auto; border: 1px solid var(--line-strong); border-radius: var(--r); padding: 4px; background: var(--surface); }
.pick-item { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; text-align: left; border: 0; background: transparent; padding: 8px 10px; border-radius: var(--r-sm); cursor: pointer; font: inherit; color: var(--ink); }
.pick-item:hover { background: var(--surface-2); }
.pick-item:focus-visible { outline-offset: -2px; }
.pick-item.is-on { background: var(--blue-soft); box-shadow: inset 0 0 0 1.5px var(--blue); }
.pick-name { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pick-sub { font-size: 12.5px; color: var(--mute); white-space: nowrap; }
.pick-chosen { font-size: 13px; font-weight: 650; color: var(--blue-ink); min-height: 1em; }
.pick-chosen:empty { display: none; }

/* ---- 정보 목록 (상세 화면) ---- */
.dl { margin: 0; display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 10px 16px; font-size: 14px; }
.dl dt { color: var(--mute); }
.dl dd { margin: 0; font-weight: 500; }
.dl-2 { grid-template-columns: 110px minmax(0, 1fr) 110px minmax(0, 1fr); }
@media (max-width: 860px) { .dl-2 { grid-template-columns: 110px minmax(0, 1fr); } }

.callout { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--r); font-size: 13.5px; background: var(--blue-soft); color: #1d3f9a; }
.callout .icon { margin-top: 1px; }
.callout-warn { background: var(--warn-soft); color: #7a4200; }
.callout-bad { background: var(--bad-soft); color: #8f1d22; }

/* ---- 홈 ---- */
.home-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 1180px) { .home-grid { grid-template-columns: 1fr; } }
.home-grid-master { grid-template-columns: minmax(0, 1fr) 340px; }
@media (max-width: 1024px) { .home-grid-master { grid-template-columns: 1fr; } }
.mini-stock { width: 100%; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
.mini-stock th, .mini-stock td { padding: 10px 18px; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
.mini-stock th:first-child { text-align: left; }
.mini-stock thead th { font-size: 12.5px; font-weight: 600; color: var(--mute); background: var(--surface-2); padding-top: 8px; padding-bottom: 8px; }
.mini-stock tbody td { font-weight: 650; }
.mini-stock tfoot th, .mini-stock tfoot td { border-bottom: 0; font-weight: 700; }
.mini-stock tfoot th { color: var(--ink-2); }
.mini-note { padding: 10px 22px 14px; border-top: 1px solid var(--line); color: var(--mute); font-size: 12.5px; }
.home-hello { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.home-hello h1 { font-size: 24px; font-weight: 700; }
.home-hello p { color: var(--mute); margin-top: 4px; }
.stock-line { display: grid; grid-template-columns: 215px minmax(60px, 1fr) 90px 80px; align-items: center; gap: 14px; padding: 14px 22px; border-bottom: 1px solid var(--line); }
.stock-line:last-child { border-bottom: 0; }
.stock-line .big { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; text-align: right; }
.stock-line .sub { color: var(--mute); font-size: 13px; text-align: right; font-variant-numeric: tabular-nums; }
.stat-row { margin: 0; display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--line); }
.stat-row > div { padding: 14px 22px; }
.stat-row > div + div { border-left: 1px solid var(--line); }
.stat-row dt { color: var(--mute); font-size: 13px; }
.stat-row dd { margin: 2px 0 0; font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }
.list a { display: flex; align-items: center; gap: 12px; padding: 12px 22px; color: inherit; text-decoration: none; }
.list a:hover { background: #f5f5fb; }
.list .grow { flex: 1; min-width: 0; }
.list .grow > .title, .list .grow > .meta { display: block; }
.list .grow > .title.mono + .meta, .list .grow > .title.mono { display: inline; }
.list .title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list .meta { color: var(--mute); font-size: 12.5px; }
.list .side-val { color: var(--mute); font-size: 13px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pin { color: var(--orange-press); font-weight: 700; font-size: 12px; }

/* ---- 보증서 발급 ---- */
.issue { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: start; }
@media (max-width: 1180px) { .issue { grid-template-columns: 1fr; } }
.issue-summary { position: sticky; top: 20px; }
.parts-pick { display: grid; gap: 18px; }
.parts-group-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.parts-group-head h3 { font-size: 14px; font-weight: 700; color: var(--ink-2); }
.parts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 8px; }
.part-toggle { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 10px 12px; border-radius: var(--r); border: 1px solid var(--line-strong); background: var(--surface); cursor: pointer; text-align: left; transition: border-color .15s, background .15s, box-shadow .15s; }
.part-toggle:hover { border-color: #9fb3d8; }
.part-toggle .pn { font-weight: 650; }
.part-toggle .pu { color: var(--mute); font-size: 12px; font-variant-numeric: tabular-nums; }
.part-toggle[aria-pressed="true"] { border-color: var(--blue); background: var(--blue-soft); box-shadow: inset 0 0 0 1px var(--blue); }
.part-toggle[aria-pressed="true"]::after { content: ""; position: absolute; right: 10px; top: 10px; width: 16px; height: 16px; border-radius: 50%; background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 10px no-repeat; }
.film-pick { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px 18px; } /* 차체 제품 줄, 그 아래 유리 줄 */
@media (max-width: 860px) { .film-pick { grid-template-columns: 1fr; } }
.panel-film { background: #eef2f8; border-color: #d6deeb; }
.panel-film .panel-head { border-bottom-color: #d6deeb; }
.film-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.film-card { --fc: var(--ink); display: flex; align-items: center; justify-content: space-between; gap: 14px; text-align: left; min-height: 84px; padding: 14px 18px; border-radius: 10px;
  border: 1.5px solid var(--line-strong); background: var(--surface); font: inherit; color: var(--ink); }
button.film-card { cursor: pointer; transition: background .15s, border-color .15s, box-shadow .15s, color .15s; }
.film-text { display: grid; gap: 3px; min-width: 0; }
.film-name { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; color: var(--fc); line-height: 1.2; white-space: nowrap; }
.film-brand { font-size: 12px; font-weight: 600; letter-spacing: 0; color: var(--mute); white-space: nowrap; }
.film-left { display: grid; justify-items: end; gap: 0; text-align: right; flex: none; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.film-left b { font-size: 20px; font-weight: 750; letter-spacing: -0.01em; color: var(--ink); line-height: 1.2; }
.film-left span { font-size: 12.5px; }
.film-clear { --fc: #1f4fd6; --fill: #1f4fd6; }
.film-matte { --fc: #262d3a; --fill: #262d3a; }
/* 윈드쉴드: 고르기 전엔 차체 카드처럼 흰 바탕, 고르면 진한 청록으로 채움(흰 글자 대비 5:1 이상) */
.film-veu { --fc: #0a6b6b; --fill: #0b7a76; }
button.film-card:hover:not(:disabled):not(.is-on) { border-color: var(--fill); box-shadow: 0 2px 8px -4px rgb(0 0 0 / .25); }
.film-card.is-on { background: var(--fill); border-color: var(--fill); box-shadow: 0 6px 16px -8px rgb(0 0 0 / .45); }
.film-card.is-on .film-name, .film-card.is-on .film-left b, .film-card.is-on .film-left span { color: #fff; }
.film-card.is-on .film-brand { color: rgb(255 255 255 / .72); }
.film-card.is-empty { background: var(--surface-2); border-style: dashed; cursor: not-allowed; }
.film-card.is-empty .film-name { color: var(--mute); }
.sum-group { margin-top: 14px; padding: 12px 14px; border-radius: var(--r); border: 1px solid var(--line); display: grid; gap: 8px; }
.sum-clear { background: #f2f6ff; border-color: #d9e4ff; }
.sum-matte { background: #f4f5f8; }
.sum-veu { background: #eff9f8; border-color: #d3eeec; }
.sum-group-title { font-weight: 750; font-size: 15px; }
.sum-clear .sum-group-title { color: #1a46c4; }
.sum-veu .sum-group-title { color: #0a6b6b; }
.sum-left { display: flex; justify-content: flex-end; align-items: baseline; gap: 4px; padding-top: 8px; border-top: 1px solid rgb(24 22 28 / .08); font-size: 13px; color: var(--mute); }
.sum-left b { color: var(--ink); font-variant-numeric: tabular-nums; }
.sum-left.is-short b { color: var(--bad); }
.sum-warn { font-size: 12.5px; color: var(--bad); }
.items-tbl input { height: 34px; }
.items-tbl select { height: 34px; min-width: 200px; }
.items-tbl td:first-child { white-space: nowrap; min-width: 96px; }
.items-tbl td:first-child .sub { font-weight: 400; }
.items-tbl .len { width: 100%; text-align: right; }
.items-tbl .input-unit { width: 120px; }
.items-tbl .pname { min-width: 180px; }
.sum-total { display: flex; justify-content: space-between; align-items: baseline; padding-top: 12px; border-top: 1px solid var(--line); }
.sum-total b { font-size: 22px; font-variant-numeric: tabular-nums; }
.sum-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 13.5px; }
.sum-list li { display: flex; justify-content: space-between; gap: 8px; }
.sum-list li span:last-child { color: var(--mute); font-variant-numeric: tabular-nums; }
.issue-actions { display: grid; gap: 8px; margin-top: 16px; }
.issue-actions .btn { justify-content: center; height: 46px; font-size: 15px; }

/* ---- 보증서 상세 ---- */
.serial { font-size: 15px; font-weight: 700; letter-spacing: .04em; font-variant-numeric: tabular-nums; }
.cert-hero { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; flex-wrap: wrap; }
.cert-hero .until { text-align: right; }
.cert-hero .until b { display: block; font-size: 22px; font-variant-numeric: tabular-nums; }
.cert-hero .until span { color: var(--mute); font-size: 13px; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 132px 1fr auto; gap: 12px; padding: 11px 22px; border-bottom: 1px solid var(--line); align-items: center; font-size: 14px; }
.timeline li:last-child { border-bottom: 0; }
.timeline time { color: var(--mute); font-size: 13px; font-variant-numeric: tabular-nums; }
.delta { font-variant-numeric: tabular-nums; font-weight: 650; white-space: nowrap; }
.delta.minus { color: var(--bad); }
.delta.plus { color: var(--ok); }

.cert-top { overflow: hidden; }
.cert-top-band { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; padding: 16px 22px; background: var(--navy); color: #fff; }
.ct-item { display: grid; gap: 1px; }
.ct-item span { font-size: 12px; color: var(--navy-mute); }
.ct-item b { font-size: 20px; font-weight: 750; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.ct-item b.serial { letter-spacing: .06em; }
.ct-state { margin-left: auto; display: flex; gap: 6px; }
.cert-top-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.ct-block { padding: 18px 22px; display: grid; gap: 3px; align-content: start; font-size: 14px; }
.ct-block + .ct-block { border-left: 1px solid var(--line); }
.ct-label { font-size: 12.5px; font-weight: 600; color: var(--mute); margin-bottom: 4px; }
.ct-dl { margin: 0; display: grid; }
.ct-dl > div { display: grid; grid-template-columns: 60px minmax(0, 1fr); gap: 10px; align-items: baseline; padding: 8px 0; border-bottom: 1px solid var(--line); }
.ct-dl > div:first-child { padding-top: 2px; }
.ct-dl > div:last-child { border-bottom: 0; padding-bottom: 0; }
.ct-dl dt { font-size: 13px; color: var(--mute); }
.ct-dl dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.ct-dl dd.is-vin { font-size: 13px; letter-spacing: 0; }
.ct-dl dd.is-main { font-size: 17px; font-weight: 750; letter-spacing: -0.01em; }
.ct-price { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 22px; background: #eef2f8; border-top: 1px solid var(--line); }
.ct-price-label { font-size: 14px; font-weight: 650; color: var(--ink-2); }
.ct-price-val { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; color: var(--ink); }
.ct-memo { padding: 12px 22px; border-top: 1px solid var(--line); white-space: pre-wrap; font-size: 14px; }
@media (max-width: 860px) { .cert-top-body { grid-template-columns: 1fr; } .ct-block + .ct-block { border-left: 0; border-top: 1px solid var(--line); } .ct-state { margin-left: 0; } }

/* ---- 공지 ---- */
.notice-body { white-space: pre-wrap; line-height: 1.75; font-size: 15px; max-width: 75ch; }

/* ---- 업로드 ---- */
.drop { display: grid; justify-items: center; gap: 8px; text-align: center; padding: 28px 20px; border: 1.5px dashed var(--line-strong); border-radius: var(--r-lg); background: var(--surface-2); color: var(--mute); cursor: pointer; transition: border-color .15s, background .15s; }
.drop:hover, .drop.is-over { border-color: var(--blue); background: var(--blue-soft); color: var(--blue-ink); }
.drop b { color: var(--ink); }

/* ---- 휴대폰: 화면별 다듬기 ---- */
@media (max-width: 860px) {
  .page-head { margin-bottom: 16px; align-items: flex-start; }
  .page-title h1 { font-size: 21px; }
  .page-actions { width: 100%; }
  .page-actions .btn { flex: 1 1 auto; justify-content: center; }
  .home-hello h1 { font-size: 21px; }
  .home-hello .page-actions .btn { flex: 1 1 0; }
  /* 검색·필터 줄: 검색은 한 줄 전체, 나머지는 반씩 */
  .toolbar { gap: 8px; }
  .toolbar .seg { flex: 1 1 100%; display: flex; }
  .toolbar .seg button { flex: 1; }
  .toolbar .search { flex: 1 1 100%; max-width: none; }
  .toolbar select { flex: 1 1 calc(50% - 4px); min-width: 0; }
  .toolbar input[type=date] { flex: 1 1 130px; min-width: 130px; }
  .toolbar > .muted { flex: none; }
  .panel-head { padding: 14px 16px; flex-wrap: wrap; }
  .panel-body { padding: 16px; }
  .list a { padding: 12px 16px; }
  .stock-line { grid-template-columns: minmax(0, 1fr) auto; gap: 6px 10px; padding: 12px 16px; }
  .stock-line > .fam { grid-column: 1 / -1; } /* 제품 풀네임은 윗줄, 아래에 막대·길이 */
  .stock-line .sub { grid-column: 1 / -1; text-align: right; margin-top: -6px; }
  .stock-line .big { font-size: 18px; }
  .stat-row > div { padding: 12px 16px; }
  /* 보증서 발급 */
  .parts-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .film-card { min-height: 72px; padding: 12px 14px; }
  .film-name { font-size: 18px; }
  .issue-summary { position: static; }
  .tbl.items-tbl { min-width: 0; }
  .items-tbl thead { display: none; }
  .items-tbl, .items-tbl tbody { display: block; }
  .items-tbl tr { display: grid; grid-template-columns: minmax(0, 1fr) 120px 34px; gap: 8px; align-items: center; padding: 10px 12px; border-bottom: 1px solid var(--line); }
  .items-tbl td { display: block; padding: 0; border: 0; }
  .items-tbl td:first-child { grid-column: 1 / -1; }
  .items-tbl .pname { min-width: 0; }
  /* 보증서 상세 */
  .cert-top-band { gap: 14px 22px; padding: 14px 16px; }
  .ct-item b { font-size: 17px; }
  .ct-block { padding: 14px 16px; }
  .ct-price { padding: 12px 16px; }
  .ct-price-val { font-size: 21px; }
  /* 롤 이력 */
  .timeline li { grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 11px 16px; }
  .timeline time { grid-column: 1 / -1; }
  /* 대화상자 */
  .dlg { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); overflow-y: auto; }
  .dlg-foot .btn { flex: 1; justify-content: center; }
  .pick-item { grid-template-columns: auto minmax(0, 1fr); }
  .pick-sub { grid-column: 2; white-space: normal; }
  .dl { grid-template-columns: 92px minmax(0, 1fr); }
  .toasts { left: 12px; right: 12px; bottom: 12px; }
  .toast { max-width: none; }
}

/* ---- 로그인 들어갈 때 ---- */
.enter { position: fixed; inset: 0; z-index: 300; display: grid; place-content: center; justify-items: center; gap: 18px;
  background: radial-gradient(110% 70% at 50% 45%, #12306e 0%, #0a1428 48%, #000 100%); animation: enter-in .25s ease-out both; }
.enter.out { animation: enter-out .5s cubic-bezier(.4, 0, .2, 1) forwards; }
.enter-mark { position: relative; width: min(440px, 76vw); animation: mark-in .75s cubic-bezier(.2, .8, .2, 1) .08s both; }
.enter-mark .wordmark { display: block; width: 100%; height: auto; color: #66789c; }
.enter-clear { position: absolute; inset: 0; clip-path: inset(0 100% 0 0); animation: wipe .9s cubic-bezier(.45, 0, .25, 1) .4s forwards; }
.enter-clear .wordmark { color: #fff; }
/* 필름 가장자리: 얇은 빛 띠가 로고 위를 지나가며 흐린 로고를 맑게 바꿈 */
.enter-edge { position: absolute; top: -18%; bottom: -18%; left: 0; width: 34px; margin-left: -17px; opacity: 0; pointer-events: none;
  background: linear-gradient(90deg, rgb(127 176 255 / 0), rgb(127 176 255 / .5) 42%, #fff 50%, rgb(127 176 255 / .5) 58%, rgb(127 176 255 / 0));
  animation: edge .9s cubic-bezier(.45, 0, .25, 1) .4s forwards; }
@keyframes wipe { to { clip-path: inset(0 0 0 0); } }
@keyframes edge { 0% { left: 0; opacity: 0; } 12% { opacity: 1; } 88% { opacity: 1; } 100% { left: 100%; opacity: 0; } }
.enter-line { width: 0; height: 3px; background: var(--orange); animation: line-grow .55s cubic-bezier(.2, .8, .2, 1) .65s forwards; }
.enter-sub { color: #c9d2e4; font-size: 14px; letter-spacing: .02em; animation: sub-in .5s ease-out .8s both; }
@keyframes enter-in { from { opacity: 0; } }
@keyframes enter-out { to { opacity: 0; transform: scale(1.03); visibility: hidden; } }
@keyframes mark-in { from { opacity: 0; transform: translateY(12px) scale(.97); filter: blur(8px); } }
@keyframes line-grow { to { width: 72px; } }
@keyframes sub-in { from { opacity: 0; transform: translateY(6px); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* 인쇄용 요소는 화면에서 숨김 */
#print-root { display: none; }

/* ---- 휴대폰 · 터치 (2026-11-20 모바일 점검) ---- */
.tabbar, .issue-bar { display: none; }
@media (max-width: 860px) {
  /* 아이폰은 16px보다 작은 입력칸을 누르면 화면을 확대함 */
  input:not([type=checkbox]):not([type=radio]):not([type=file]), select, textarea { font-size: 16px; }

  /* 아래 탭: 홈 · 발급 · 보증서 · 재고 · 메뉴 */
  .tabbar { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 25;
    background: rgb(255 255 255 / .96); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom);
    -webkit-backdrop-filter: saturate(160%) blur(12px); backdrop-filter: saturate(160%) blur(12px); }
  .tab-item { display: grid; justify-items: center; align-content: center; gap: 3px; height: 58px; padding: 0; border: 0; background: none;
    color: var(--mute); font: 600 11.5px/1 var(--font); text-decoration: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
  .tab-item.is-on { color: var(--ink); }
  .tab-item.is-on .icon { color: var(--orange); }
  .tab-item:active { background: var(--surface-2); }
  .has-shell .main { padding-bottom: calc(58px + 28px + env(safe-area-inset-bottom)); }

  /* 보증서 발급 화면: 아래 탭 대신 발급 줄 */
  body[data-route="/certs/new"] .tabbar { display: none; }
  .issue-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 25;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: rgb(255 255 255 / .97); border-top: 1px solid var(--line);
    box-shadow: 0 -6px 18px rgb(0 0 0 / .06); }
  .issue-bar-info { color: var(--ink-2); font-size: 14px; min-width: 0; }
  .issue-bar-info b { color: var(--ink); }
  .issue-bar .btn { height: 46px; padding: 0 22px; font-size: 15px; flex: none; }
  .nav-open .tabbar, .nav-open .issue-bar { visibility: hidden; }
}
@media print { .tabbar, .issue-bar { display: none !important; } }

/* 재고 현황: 여러 롤 한꺼번에 보내기 (2026-11-25) */
.tbl-stock th:first-child:has(input[type=checkbox]), .tbl-stock td.c-pick { width: 44px; padding-right: 0; }
.tbl-stock input[type=checkbox], .pick-chk input { width: 18px; height: 18px; accent-color: var(--ink); cursor: pointer; vertical-align: middle; }
.pick-chk { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; padding: 4px 2px; white-space: nowrap; }
.bulk-bar { position: sticky; top: 8px; z-index: 5; display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  margin: 0 0 12px; padding: 10px 12px 10px 16px; background: var(--ink); color: #fff; border-radius: 12px; box-shadow: 0 6px 20px rgba(0, 0, 0, .18); }
.bulk-bar[hidden] { display: none; }
.bulk-bar .bulk-count { flex: 1 1 auto; font-size: 14px; }
.bulk-bar .bulk-count b { font-size: 15.5px; }
.bulk-bar .btn-ghost { color: #fff; border-color: rgba(255, 255, 255, .35); background: transparent; }
.bulk-sum { margin: 6px 0 0; padding-left: 18px; font-size: 13.5px; }
.bulk-boxes { margin: 6px 0 0; font-size: 12.5px; color: var(--mute); max-height: 72px; overflow: auto; word-break: break-all; }

/* 입고 등록: 제품명이 앞에 다 보이게 넓게 (2026-11-25. 제품별 색은 정신없다는 의견으로 같은 날 뺌) */
.rcv-row .prod-sel { min-width: 336px; font-size: 14.5px; font-weight: 650; }
.rcv-row.is-none .prod-sel { color: var(--bad); border-color: var(--bad); border-style: dashed; }

/* 직접 고치는 표(입고 등록·설정): 휴대폰에서는 줄마다 카드로 (옆으로 밀지 않게) */
@media (max-width: 860px) {
  .edit-tbl, .edit-tbl tbody { display: block; width: 100%; min-width: 0; }
  .edit-tbl thead { display: none; }
  .edit-tbl tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; padding: 16px; border-bottom: 1px solid var(--line); }
  .edit-tbl tr:last-child { border-bottom: 0; }
  .edit-tbl td { display: grid; gap: 6px; align-content: start; padding: 0; border: 0; min-width: 0; text-align: left; }
  .edit-tbl td[data-label]::before { content: attr(data-label); font-size: 12.5px; font-weight: 600; color: var(--mute); }
  .edit-tbl td.et-wide { grid-column: 1 / -1; }
  .edit-tbl td.et-num { grid-column: 1; grid-row: 1; align-self: center; font-weight: 700; color: var(--ink); }
  .edit-tbl td.et-num::after { content: '번째 롤'; font-weight: 600; }
  .edit-tbl td.et-num { display: block; }
  .edit-tbl td.et-del { grid-column: 2; grid-row: 1; justify-self: end; }
  .edit-tbl td :is(input, select, textarea), .edit-tbl td .input-unit { width: 100% !important; min-width: 0 !important; }
  .edit-tbl td.muted { color: var(--ink-2); }
  .edit-tbl td.et-num { text-align: left; }
  /* 부위 표: 카드 두 줄 (이름 · 사용 / 단위 · 길이 · 대형) */
  .parts-tbl tr { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, .7fr); gap: 10px; padding: 14px 16px; }
  .parts-tbl td.et-wide { grid-column: 1 / 3; }
  .parts-tbl td.et-use { grid-column: 3; justify-items: end; }
  .parts-tbl td.et-hide { display: none; }
}

/* 손가락으로 누르는 기기: 누르는 칸 44px 안팎 */
@media (pointer: coarse) {
  .btn { height: 44px; }
  .btn-sm { height: 40px; padding: 0 14px; }
  .icon-btn, .back { width: 44px; height: 44px; }
  .seg button { height: 40px; }
  .nav-item, .side-me, .side-logout { padding-block: 12px; }
  .consent-check input, .login-remember .check input { width: 22px; height: 22px; }
  .pg { min-width: 40px; height: 40px; }
}

/* =====================================================================
   SolarLuxe IR (teyler) — clearshield-warranty 화면 위에 얹은 브랜드·새 화면 규칙
   ===================================================================== */
/* 첫 화면·로그인 들어갈 때: 먹색 + 흰 로고 + 무지갯빛 선 */
.boot-loading, .enter { background: radial-gradient(120% 80% at 50% 40%, #2a2640 0%, #17151b 55%, #0c0b0f 100%); }
.boot-logo { width: min(200px, 48vw); height: auto; animation: boot-in .6s ease-out both; }
.boot-line, .enter-line { background: var(--iris-line); }
.enter-logo { width: min(240px, 52vw); height: auto; animation: mark-in .75s cubic-bezier(.2, .8, .2, 1) .08s both; }
.enter-sub { color: #c9c4d8; }

/* 로그인: 왼쪽 흰 패널(검정 로고) + 오른쪽 어두운 차량 사진(SolarFX 홈페이지 SolarLuxe IR 슬라이드와 같은 사진) 정중앙에 흰 로고 */
.login-logo { width: 236px; height: auto; display: block; }
.login-product { margin-top: 14px; }
.login-aside { background: #050507; }
.login-car { object-position: 72% 55%; filter: brightness(.62) saturate(.9); }
.login-aside::after { background: linear-gradient(rgb(0 0 0 / .38), rgb(0 0 0 / .38)), linear-gradient(180deg, rgb(5 5 7 / .55) 0%, rgb(5 5 7 / 0) 32%, rgb(5 5 7 / 0) 70%, rgb(5 5 7 / .7) 100%); }
.login-aside-mark::after { background: var(--iris-line); }
.login-mark { width: min(40%, 300px); height: auto; display: block; filter: drop-shadow(0 2px 18px rgb(0 0 0 / .6)); }
@media (prefers-reduced-motion: no-preference) {
  .login-aside-mark .login-mark { clip-path: inset(-40% 110% -40% -10%); animation: login-mark-in 1.2s cubic-bezier(.55, .1, .3, 1) .3s forwards; }
}
.login-check { color: #e1ddec; }
@media (max-width: 860px) {
  .login-aside { min-height: 300px; }
  .login-car { object-position: 78% 60%; }
  .login-mark { width: 46%; }
  .login-logo { width: 200px; }
}

/* 사이드바 */
.side-logo { width: 156px; height: auto; display: block; }
.side-brand { padding-bottom: 20px; margin-bottom: 4px; background: var(--iris-line) left bottom / 40px 2px no-repeat; }
.nav-item.is-on { background: rgb(255 255 255 / .09); }
.nav-item.is-on .icon { color: #b9c1ff; }
.mobile-logo { width: 116px; height: auto; display: block; }
@media (max-width: 860px) { .tab-item.is-on .icon { color: var(--blue); } }

/* 권한 표시 */
.role-Admin { background: #ecebf3; color: #2c2938; }
.role-Vendor { background: var(--blue-soft); color: var(--blue-ink); }
.role-User { background: #f1eafc; color: #5b3d99; }
.side .role-Admin { background: rgb(255 255 255 / .12); color: #f1eff6; }
.side .role-Vendor { background: rgb(146 158 255 / .2); color: #c3caff; }
.side .role-User { background: rgb(196 170 240 / .2); color: #dccbff; }

/* 버튼: 주요 = 먹색 */
.btn-primary { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-primary:hover { background: #000; border-color: #000; }
.btn.is-busy.btn-primary::after, .btn.is-busy.btn-dark::after { border-color: rgb(255 255 255 / .3); border-top-color: #fff; }
.req { color: var(--blue); }
.meter.is-low .meter-bar i { background: #c97a12; }
.meter-bar i { background: var(--blue); }
.callout-ok { background: var(--ok-soft); color: #0f5c37; }
.form-foot { display: flex; align-items: center; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.form-foot .field-error { margin-right: auto; }
.list-static { display: flex; align-items: center; gap: 12px; padding: 12px 22px; }
.list li.is-dim .title { color: var(--mute-2); }

/* 홈 */
.home-stats { margin-bottom: 20px; }
.home-stats .stat-row { border-top: 0; }
.stat-row-4 { grid-template-columns: repeat(4, 1fr); }
.stat-row dd { font-size: 22px; letter-spacing: -0.02em; }
.stat-sub { color: var(--mute); font-size: 12.5px; margin-top: 2px; }
.stat-row > .is-warn dd { color: #9a5200; }
@media (max-width: 860px) {
  .stat-row-4 { grid-template-columns: repeat(2, 1fr); }
  .stat-row-4 > div:nth-child(3) { border-left: 0; }
  .stat-row-4 > div:nth-child(n+3) { border-top: 1px solid var(--line); }
}
.mini-stock tbody th { font-weight: 600; text-align: left; }

/* 공지 */
.notice-article { max-width: 820px; }
.notice-body { font-size: 15px; line-height: 1.75; max-width: 68ch; }
.notice-body > * + * { margin-top: .8em; }
.notice-body ul, .notice-body ol { padding-left: 1.4em; }
.notice-body img { max-width: 100%; height: auto; border-radius: var(--r); }
.notice-body table { border-collapse: collapse; }
.notice-body td, .notice-body th { border: 1px solid var(--line); padding: 6px 10px; }
.rte { border: 1px solid var(--line-strong); border-radius: var(--r); background: var(--surface); overflow: hidden; }
.rte:focus-within { border-color: var(--blue); box-shadow: 0 0 0 3px rgb(76 91 212 / .16); }
.rte-tools { display: flex; align-items: center; gap: 2px; padding: 6px; border-bottom: 1px solid var(--line); background: var(--surface-2); flex-wrap: wrap; }
.rte-btn { height: 30px; min-width: 32px; padding: 0 8px; border: 0; border-radius: var(--r-sm); background: transparent; color: var(--ink-2); cursor: pointer; font-size: 13.5px; display: inline-grid; place-items: center; }
.rte-btn:hover { background: rgb(24 22 28 / .07); }
.rte-sep { width: 1px; height: 18px; background: var(--line-strong); margin: 0 4px; }
.rte-area { min-height: 260px; padding: 12px 14px; outline: none; line-height: 1.7; }
.rte-area ul, .rte-area ol { padding-left: 1.4em; }

/* 시공확인서 등록: 부위 6칸 */
.owner-fixed { font-size: 15px; }
.parts { display: grid; }
.part-row { display: grid; grid-template-columns: 150px minmax(0, 1fr) 120px 76px; gap: 12px; align-items: center; padding: 12px 22px; border-bottom: 1px solid var(--line); transition: background .15s; }
.part-row:last-child { border-bottom: 0; }
.part-row-head { padding-top: 9px; padding-bottom: 9px; background: var(--surface-2); font-size: 12.5px; font-weight: 600; color: var(--mute); }
.part-row.is-on { background: #f7f7fd; }
.part-row.is-over { background: var(--bad-soft); }
.part-name { display: grid; gap: 6px; justify-items: start; }
.part-name b { font-size: 14.5px; }
.part-roll { display: grid; gap: 4px; min-width: 0; }
.part-left { font-size: 12.5px; color: var(--mute); min-height: 1em; }
.part-row.is-over .part-left { color: var(--bad); font-weight: 600; }
.part-due-wrap { display: grid; text-align: right; }
.part-due-label { display: none; }
.part-due { font-weight: 650; font-variant-numeric: tabular-nums; }
.seg-sm button { height: 26px; padding: 0 9px; font-size: 12.5px; }
.issue-summary .dl { grid-template-columns: 80px minmax(0, 1fr); }
.form-error { background: var(--bad-soft); padding: 10px 12px; border-radius: var(--r); }
@media (max-width: 860px) {
  .part-row { grid-template-columns: minmax(0, 1fr) 110px; padding: 14px 16px; }
  .part-row-head { display: none; }
  .part-name { grid-column: 1 / -1; grid-template-columns: auto auto; align-items: center; justify-content: space-between; width: 100%; }
  .part-roll { grid-column: 1 / -1; }
  .part-due-wrap { text-align: left; }
  .part-due-label { display: inline; font-size: 12px; color: var(--mute); }
}

/* 시공확인서 목록·상세 */
.parts-mini { display: flex; flex-wrap: wrap; gap: 4px; }
.part-tag { display: inline-flex; align-items: center; height: 22px; padding: 0 7px; border-radius: 5px; background: #efeef5; color: var(--ink-2); font-size: 12px; font-weight: 600; }
.cert-band { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 16px; border-radius: var(--r-lg); overflow: hidden; background: var(--iris); color: #1d1a2b; }
.cert-band > div { padding: 14px 20px; display: grid; gap: 2px; }
.cert-band > div + div { border-left: 1px solid rgb(35 32 74 / .12); }
.cert-band span { font-size: 12px; color: #4a4663; }
.cert-band b { font-size: 16px; font-weight: 750; font-variant-numeric: tabular-nums; }
.cert-band .mono { letter-spacing: .06em; font-size: 18px; }
@media (max-width: 860px) {
  .cert-band { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cert-band > div:nth-child(3) { border-left: 0; }
  .cert-band > div:nth-child(n+3) { border-top: 1px solid rgb(35 32 74 / .12); }
}
.tbl-plain { overflow-x: auto; }
.tbl-plain .tbl tbody th { text-align: left; font-weight: 600; font-size: 14px; color: var(--ink-2); padding: 11px 14px; border-bottom: 1px solid var(--line); }
.tbl-plain .tbl tbody tr:last-child th { border-bottom: 0; }
.callout { margin-bottom: 12px; }

/* 재고 */
.select-bar { position: sticky; top: 8px; z-index: 5; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 8px 10px 8px 16px; margin-bottom: 12px;
  background: var(--ink); color: #fff; border-radius: var(--r-lg); box-shadow: var(--shadow-pop); }
.select-bar .spacer { flex: 1; }
.select-bar .btn { border-color: rgb(255 255 255 / .25); background: rgb(255 255 255 / .08); color: #fff; }
.select-bar .btn:hover { background: rgb(255 255 255 / .16); }
.select-bar .btn-primary { background: #fff; border-color: #fff; color: var(--ink); }
.select-bar .btn-primary:hover { background: #ecebf6; }
.holder-chip { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 6px; font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.holder-Admin { background: #ecebf3; color: #2c2938; }
.holder-Vendor { background: var(--blue-soft); color: var(--blue-ink); }
.holder-User { background: #f1eafc; color: #5b3d99; }
.who { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.timeline { list-style: none; margin: 0; padding: 8px 22px 14px; display: grid; }
.timeline li { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.timeline li:last-child { border-bottom: 0; }
.tl-date { color: var(--mute); font-size: 13px; font-variant-numeric: tabular-nums; }
.ledger td .lg-m { display: block; color: var(--mute); font-size: 12px; font-weight: 500; }
.ledger td b { font-weight: 700; }
.ledger td.is-zero { color: var(--mute-2); }
.ledger tbody th, .ledger tfoot th { text-align: left; font-weight: 650; padding: 11px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.ledger tfoot th, .ledger tfoot td { background: #f1f0f7; border-bottom: 0; }
.ledger .lg-names { color: var(--mute); font-size: 13px; }
.tbl tr.is-warn td { background: #fffaf2; }

/* 제품명 · 농도 (2026-11-26) */
.prod-pick { grid-column: span 2; }
.prod-pick-row { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 8px; }
@media (max-width: 860px) { .prod-pick { grid-column: auto; } }
.prod-card.is-off { opacity: .7; }
.prod-card .panel-head { flex-wrap: wrap; }
.shade-list { display: flex; flex-wrap: wrap; gap: 8px; }
.shade-chip { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 6px 0 12px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--surface); }
.shade-chip b { font-size: 15px; font-variant-numeric: tabular-nums; }
.shade-chip .shade-name { color: var(--mute); font-size: 12.5px; }
.shade-chip.is-off { background: var(--surface-2); border-style: dashed; }
.shade-chip.is-off b, .shade-chip.is-off .shade-name { color: var(--mute-2); text-decoration: line-through; }
.shade-x { display: grid; place-items: center; width: 26px; height: 26px; border: 0; border-radius: 50%; background: transparent; color: var(--mute); cursor: pointer; }
.shade-x:hover { background: #ecebf3; color: var(--ink); }
.shade-add { display: flex; gap: 8px; align-items: center; }
.shade-add .input-unit { width: 110px; }
.shade-add input { height: 34px; }

/* =====================================================================
   필름 색 (2026-11-26): 제품 줄마다 한 색. l0 LUXE IR · l1 CORE · l2 EVO · l3·l4 추가 제품 · lx 목록에 없는 이름
   --fc 진한 색(글자·채움), --fs 옅은 바탕, --fb 테두리
   ===================================================================== */
.film-l0 { --fc: #3f4cc4; --fs: #eef0fd; --fb: #cdd3fa; }
.film-l1 { --fc: #0b6e6d; --fs: #e3f4f3; --fb: #b6e0dd; }
.film-l2 { --fc: #9a4f00; --fs: #fdf1e2; --fb: #f2d3a8; }
.film-l3 { --fc: #9b2f73; --fs: #fbeaf4; --fb: #efc4dd; }
.film-l4 { --fc: #2c6e37; --fs: #e8f5ea; --fb: #c0e2c6; }
.film-lx { --fc: #3e3b48; --fs: #efeef4; --fb: #d8d6e2; }
.film-chip { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 6px; border: 1px solid var(--fb); background: var(--fs); color: var(--fc); font-size: 13px; font-weight: 650; white-space: nowrap; }
.part-tag[class*="film-l"] { background: var(--fs); color: var(--fc); }
.holder-chip { border: 1px solid transparent; }
.holder-User { border-color: #e2d4f8; }
.holder-Vendor { border-color: #d7dcfb; }
.holder-Admin { border-color: #dddbe8; }
.flow { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.flow .icon { color: var(--mute-2); }
.sub.bad { color: var(--bad); font-weight: 600; }

/* 재고 목록 위 제품별 요약 */
.film-sum { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.film-sum-item { display: inline-flex; align-items: center; gap: 10px; height: 38px; padding: 0 14px; border-radius: var(--r); border: 1px solid var(--fb); background: var(--fs); color: var(--fc);
  font: inherit; font-size: 13.5px; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.film-sum-item .fs-name { font-weight: 700; }
.film-sum-item .fs-val { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.film-sum-item .fs-val b { color: var(--fc); }
.film-sum-item:hover { border-color: var(--fc); }
.film-sum-item.is-on { background: var(--fc); border-color: var(--fc); color: #fff; }
.film-sum-item.is-on .fs-val, .film-sum-item.is-on .fs-val b { color: rgb(255 255 255 / .9); }

/* ---- 시공확인서 등록: ① 필름 카드 ② 부위 버튼 (clearshield 발급 화면 문법) ---- */
.panel-film { background: #f3f3f9; border-color: #e1e0ec; }
.panel-film .panel-head { border-bottom-color: #e1e0ec; }
.film-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(196px, 1fr)); gap: 10px; }
.film-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; text-align: left; min-height: 78px; padding: 12px 16px; border-radius: 10px;
  border: 1.5px solid var(--fb); background: var(--surface); font: inherit; color: var(--ink); cursor: pointer; transition: background .15s, border-color .15s, box-shadow .15s; }
.film-card:hover:not(.is-on) { border-color: var(--fc); box-shadow: 0 2px 8px -4px rgb(0 0 0 / .22); }
.film-text { display: grid; gap: 2px; min-width: 0; }
.film-name { font-size: 18px; font-weight: 800; letter-spacing: -0.02em; color: var(--fc); line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.film-brand { font-size: 12px; font-weight: 600; color: var(--mute); white-space: nowrap; }
.film-left { display: grid; justify-items: end; text-align: right; flex: none; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.film-left b { font-size: 18px; font-weight: 750; color: var(--ink); line-height: 1.2; }
.film-left span { font-size: 12px; }
.film-card.is-on { background: var(--fc); border-color: var(--fc); box-shadow: 0 6px 16px -8px rgb(0 0 0 / .45); }
.film-card.is-on .film-name, .film-card.is-on .film-left b, .film-card.is-on .film-left span { color: #fff; }
.film-card.is-on .film-brand { color: rgb(255 255 255 / .75); }
.part-toggles { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; }
.part-toggle { position: relative; display: grid; justify-items: start; gap: 2px; padding: 10px 12px; min-height: 58px; border-radius: var(--r); border: 1px solid var(--line-strong);
  background: var(--surface); font: inherit; color: var(--ink); cursor: pointer; text-align: left; transition: background .15s, border-color .15s; }
.part-toggle:hover:not(:disabled) { border-color: #a9a6bb; }
.part-toggle:disabled { opacity: .5; cursor: not-allowed; }
.part-toggle .pn { font-weight: 700; font-size: 14.5px; }
.part-toggle .pu { color: var(--mute); font-size: 12px; font-variant-numeric: tabular-nums; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.part-toggle.is-on { background: var(--fs); border-color: var(--fc); box-shadow: inset 0 0 0 1px var(--fc); }
.part-toggle.is-on .pn, .part-toggle.is-on .pu { color: var(--fc); }
.part-toggle.is-on::after { content: ""; position: absolute; right: 9px; top: 9px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--fc) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' viewBox='0 0 24 24'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 10px no-repeat; }
.items-tbl select { height: 34px; min-width: 210px; }
.items-tbl .len { width: 100%; text-align: right; height: 34px; }
.items-tbl .input-unit { width: 110px; margin-left: auto; }
.items-tbl tr.is-over td { background: var(--bad-soft); }
.items-empty { padding: 4px 2px; font-size: 13.5px; }
.sum-dl { grid-template-columns: 64px minmax(0, 1fr); }
.sum-group { padding: 12px 14px; border-radius: var(--r); border: 1px solid var(--fb); background: var(--fs); display: grid; gap: 8px; }
.sum-group-title { font-weight: 750; font-size: 15px; color: var(--fc); }
.sum-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 13.5px; }
.sum-list li { display: flex; justify-content: space-between; gap: 8px; }
.sum-list li span:last-child { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.sum-left { display: flex; justify-content: flex-end; align-items: baseline; gap: 4px; padding-top: 8px; border-top: 1px solid rgb(0 0 0 / .08); font-size: 13px; color: var(--mute); }
.sum-left b { color: var(--ink); font-variant-numeric: tabular-nums; }
@media (max-width: 860px) {
  .film-cards { grid-template-columns: 1fr 1fr; }
  .film-card { min-height: 70px; padding: 10px 12px; flex-direction: column; align-items: flex-start; gap: 4px; }
  .film-left { justify-items: start; text-align: left; }
  .part-toggles { grid-template-columns: repeat(3, 1fr); }
  .items-tbl select { min-width: 0; width: 100%; }
}

/* 제품·농도 관리: 기본 길이 */
.len-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px 16px; }
.len-item { display: grid; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.len-item input { text-align: right; }
.len-roll { border-left: 1px solid var(--line); padding-left: 16px; }
@media (max-width: 860px) { .len-roll { border-left: 0; padding-left: 0; } }

/* 재고 현황 보유처 탭 (2026-11-26) */
.hold-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line-strong); margin-bottom: 16px; overflow-x: auto; }
.hold-tab { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 16px; border: 0; border-bottom: 2.5px solid transparent; margin-bottom: -1px; background: none; font: inherit; font-size: 15px; font-weight: 600; color: var(--mute); cursor: pointer; white-space: nowrap; transition: color .15s, border-color .15s; }
.hold-tab:hover { color: var(--ink); }
.hold-tab.is-on { color: var(--ink); border-bottom-color: var(--ink); }
.hold-tab .tab-n { min-width: 26px; height: 22px; padding: 0 7px; border-radius: 999px; background: #ecebf3; color: var(--ink-2); font-size: 12.5px; font-weight: 700; display: inline-grid; place-items: center; font-variant-numeric: tabular-nums; }
.hold-tab.is-on .tab-n { background: var(--ink); color: #fff; }
@media (max-width: 860px) { .hold-tab { padding: 0 12px; font-size: 14px; } }

/* 제품 등록 표 (2026-11-26, clearshield 입고 등록처럼) */
.rcv-head-side { display: inline-flex; align-items: center; gap: 14px; font-size: 13.5px; }
.rcv-common { display: grid; grid-template-columns: 220px 180px minmax(0, 1fr); gap: 8px 16px; align-items: end; border-bottom: 1px solid var(--line); }
.rcv-common .field-hint { align-self: center; }
.rcv-tbl td { vertical-align: middle; }
.rcv-tbl input, .rcv-tbl select { height: 36px; }
.rcv-prod { display: flex; align-items: center; gap: 6px; }
.film-sel { width: 128px; font-weight: 700; color: var(--fc); background-color: var(--fs); border-color: var(--fb); }
.film-sel:hover { border-color: var(--fc); }
.shade-sel { width: 86px; font-weight: 650; }
.rcv-row.is-none .shade-sel { border-color: var(--bad); border-style: dashed; color: var(--bad); }
.rcv-name { margin-left: 4px; }
.rcv-due { font-weight: 650; font-variant-numeric: tabular-nums; }
.rcv-add { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; border-top: 1px solid var(--line); }
.rcv-save { display: flex; justify-content: flex-end; }
.btn-lg { height: 46px; padding: 0 22px; font-size: 15px; }
@media (max-width: 860px) {
  .rcv-common { grid-template-columns: 1fr 1fr; }
  .rcv-common .field-hint { grid-column: 1 / -1; }
  .rcv-prod { flex-wrap: wrap; }
  .film-sel { flex: 1; width: auto; }
  .rcv-tbl input { width: 100% !important; }
  .rcv-save .btn { width: 100%; justify-content: center; }
}
.prod-warranty { font-size: 13px; font-weight: 600; color: var(--ink-2); background: #ecebf3; border-radius: 999px; padding: 3px 10px; margin-left: 8px; vertical-align: 2px; }

/* 제품명·농도 칩 고르기 (2026-11-26: 제품명마다 자기 배경색) */
.fp { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.fp-prod, .fp-shade { display: flex; flex-wrap: wrap; gap: 4px; }
.fp-chip { height: 32px; padding: 0 12px; border-radius: 7px; border: 1px solid var(--fb); background: var(--fs); color: var(--fc); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; white-space: nowrap; transition: background .12s, color .12s, box-shadow .12s; }
.fp-chip:hover { border-color: var(--fc); }
.fp-chip.is-on { background: var(--fc); border-color: var(--fc); color: #fff; box-shadow: 0 3px 8px -4px rgb(0 0 0 / .4); }
.fp-shade { padding-left: 10px; border-left: 1px solid var(--line-strong); }
.fp-sh { height: 32px; min-width: 46px; padding: 0 9px; border-radius: 7px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink-2); font: inherit; font-size: 13px; font-weight: 650; cursor: pointer; font-variant-numeric: tabular-nums; }
.fp-sh:hover { border-color: var(--fc); color: var(--fc); }
.fp-sh.is-on { background: var(--fc); border-color: var(--fc); color: #fff; }
.rcv-row.is-none .fp-shade { border-left-color: var(--bad); }
.rcv-row.is-none .fp-sh:not(.is-on) { border-style: dashed; border-color: #e6a7aa; }
.film-sum-label { display: inline-grid; align-content: center; margin-right: 4px; font-size: 13px; font-weight: 700; color: var(--ink-2); line-height: 1.25; }
.film-sum-label small { font-size: 11.5px; font-weight: 500; color: var(--mute); }
.rcv-tbl .fp { flex-wrap: nowrap; }
.rcv-tbl .rcv-prod { min-width: 360px; }
.rcv-tbl .fp-sh { min-width: 40px; padding: 0 7px; }
@media (max-width: 860px) { .rcv-tbl .fp { flex-wrap: wrap; } .rcv-tbl .rcv-prod { min-width: 0; } }
.rcv-tbl .fp-chip { padding: 0 9px; }
.rcv-tbl td { padding-left: 8px; padding-right: 8px; }

/* 재고 목록 위 제품별 남은 재고 표 */
.sum-panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); overflow-x: auto; margin-bottom: 14px; }
.sum-tbl { border-collapse: collapse; font-size: 13.5px; font-variant-numeric: tabular-nums; min-width: 100%; }
.sum-tbl th, .sum-tbl td { padding: 8px 14px; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--line); }
.sum-tbl tbody tr:last-child > * { border-bottom: 0; }
.sum-tbl thead th { background: var(--surface-2); padding-top: 9px; padding-bottom: 9px; }
.sum-tbl th[scope=row], .sum-tbl .sum-corner { text-align: left; font-size: 12.5px; font-weight: 600; color: var(--mute); width: 1%; }
.sum-tbl td { font-weight: 650; color: var(--ink); }
.sum-tbl .sum-total { background: #f1f0f7; font-weight: 750; color: var(--ink); }
.sum-tbl thead .sum-total { font-size: 12.5px; }
.sum-tbl .fp-chip { height: 28px; }

/* 출고 현황 */
.hist-date { display: inline-flex; align-items: baseline; gap: 8px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.hist-date span { color: var(--mute); font-size: 12.5px; }
.tbl td.hist-arrow { padding-left: 0; padding-right: 0; color: var(--mute-2); text-align: center; }
@media (max-width: 860px) { .tbl td.hist-arrow { display: none; } }
.hist-tbl th, .hist-tbl td { padding-left: 22px; padding-right: 22px; }
.hist-tbl td { padding-top: 13px; padding-bottom: 13px; }
.hist-tbl th:first-child, .hist-tbl td:first-child { padding-left: 24px; }
.hist-tbl td.hist-arrow { padding-left: 4px; padding-right: 4px; }
.hist-date { gap: 10px; }

/* 시공확인서 발급: 남은 재고 표 · 부위 버튼(켜고 끄기만) · 줄마다 필름 드롭다운 — 2026-11-26 사용자 */
.cf-stock td, .cf-stock th { font-variant-numeric: tabular-nums; }
.cf-stock td b.bad { color: var(--bad); }
.items-tbl select.film-sel { min-width: 150px; width: 150px; }
.items-tbl tr.is-nofilm td { background: var(--surface-2); }
@media (max-width: 860px) {
  .items-tbl select.film-sel { width: 100%; }
  .tbl.cf-stock { min-width: 0; }
  .cf-stock th, .cf-stock td, .tbl-plain .cf-stock tbody th { padding: 10px 10px; font-size: 13.5px; }
  .cf-stock th:first-child, .tbl-plain .cf-stock tbody th { padding-left: 16px; }
}

.sum-name { border: 0; background: none; padding: 2px 0; font: inherit; font-size: 13px; font-weight: 700; color: var(--ink); cursor: pointer; white-space: nowrap; border-bottom: 1.5px solid transparent; }
.sum-name:hover { border-bottom-color: var(--ink-2); }
.sum-name.is-on { border-bottom-color: var(--ink); }
.sum-tbl td.is-zero { color: var(--mute-2); font-weight: 500; }

/* 2026-11-26 사용자: 제품명 칸은 평소엔 색 테두리만, 누르면(고른 제품) 그 색으로 채움 */
.fp-chip { background: var(--surface); color: var(--ink); border: 1.5px solid var(--fc); }
.fp-chip:hover { background: var(--fs); box-shadow: inset 0 0 0 1px var(--fc); }
.fp-chip.is-on, .fp-chip.is-on:hover { background: var(--fc); color: #fff; border-color: var(--fc); box-shadow: 0 3px 8px -4px rgb(0 0 0 / .4); font-weight: 800; }
.fp-sh.is-on { background: var(--ink); border-color: var(--ink); color: #fff; }
.fp-sh:hover { color: var(--ink); border-color: var(--ink-2); }
/* 고른 제품명·농도를 옆에 한 번 더 (예: CORE 15%) */
.rcv-pick { display: inline-flex; align-items: center; height: 32px; padding: 0 12px; border-radius: 7px; font-size: 13.5px; font-weight: 800; white-space: nowrap;
  background: var(--fs); color: var(--fc); border: 1.5px solid var(--fc); font-variant-numeric: tabular-nums; }
.rcv-tbl .rcv-prod { min-width: 330px; }
.rcv-tbl td, .rcv-tbl th { padding-left: 5px; padding-right: 5px; }
.rcv-pick.is-none { background: none; color: var(--bad); border: 1.5px dashed #e6a7aa; font-weight: 600; }
.film-sel { background-color: var(--surface); color: var(--ink); border: 1.5px solid var(--fc); font-weight: 700; }
.film-sel.is-empty { border: 1.5px dashed var(--ink-2); color: var(--mute); font-weight: 600; }
.edit-window { margin: -10px 0 14px; font-size: 13px; color: var(--mute); }

/* ---- 통계 (2026-11-27) : 한 차트에 한 값, 한 색(파랑). 값 글자는 먹색 ---- */
.page-stats .home-stats { margin-bottom: 16px; }
.st-dates { display: inline-flex; align-items: center; gap: 6px; color: var(--mute); }
.st-dates[hidden] { display: none; }
.st-loc { display: inline-flex; align-items: center; height: 38px; padding: 0 12px; border-radius: var(--r); background: var(--blue-soft); color: var(--blue-ink); font-weight: 650; font-size: 14px; }
.st-head-note { font-size: 12.5px; }
.st-chart { position: relative; display: grid; grid-template-columns: 52px 1fr; padding: 22px 22px 12px 12px; --h: 220px; }
.st-grid { display: flex; flex-direction: column; justify-content: space-between; height: var(--h); padding-right: 10px; text-align: right; font-size: 11.5px; color: var(--mute-2); font-variant-numeric: tabular-nums; }
.st-grid span { line-height: 0; }
.st-bars { display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); gap: 2px; min-width: 0;
  background-image: linear-gradient(var(--line), var(--line)), linear-gradient(var(--line), var(--line)), linear-gradient(var(--line-strong), var(--line-strong));
  background-size: 100% 1px; background-repeat: no-repeat; background-position: 0 0, 0 calc(var(--h) / 2), 0 calc(var(--h) - 1px); }
.st-col { display: flex; flex-direction: column; align-items: center; border-radius: 6px; outline: none; min-width: 0; }
.st-col:hover, .st-col:focus-visible { background: rgb(76 91 212 / .06); }
.st-col:focus-visible { box-shadow: 0 0 0 2px var(--blue); }
.st-bar-area { height: var(--h); width: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; }
.st-bar { display: block; width: min(30px, 62%); background: var(--blue); border-radius: 4px 4px 0 0; }
.st-col:hover .st-bar, .st-col:focus-visible .st-bar { background: var(--blue-ink); }
.st-col.is-now .st-bar { background: repeating-linear-gradient(135deg, var(--blue) 0 5px, #8792e3 5px 8px); }
.st-val { font-size: 11.5px; font-weight: 650; color: var(--ink-2); margin-bottom: 4px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.st-chart.is-dense .st-val { display: none; }
.st-x { padding-top: 7px; font-size: 12px; color: var(--mute); white-space: nowrap; }
.st-chart.is-dense .st-x { font-size: 10.5px; }
.st-tip { position: absolute; top: 6px; transform: translateX(-50%); z-index: 3; display: flex; flex-direction: column; gap: 2px; padding: 9px 12px; border-radius: var(--r); background: var(--navy); color: #f2f1f6; font-size: 12.5px; white-space: nowrap; pointer-events: none; box-shadow: var(--shadow-pop); }
.st-tip[hidden] { display: none; }
.st-tip strong { font-weight: 700; color: #fff; margin-bottom: 2px; }
.st-flat { border: 0; border-radius: 0 0 var(--r-lg) var(--r-lg); }
.st-flat .tbl th[scope=row] { font-weight: 600; color: var(--ink); background: none; font-size: 14px; padding: 11px 14px; border-bottom: 1px solid var(--line); position: static; }
.st-flat .tbl tbody tr:last-child th { border-bottom: 0; }
.st-barcol { width: 36%; min-width: 240px; }
.st-hbar { display: flex; align-items: center; gap: 10px; }
.st-hbar-track { flex: 1; height: 10px; overflow: hidden; }
.st-hbar-fill { display: block; height: 100%; background: var(--blue); border-radius: 0 4px 4px 0; }
.st-hbar-val { min-width: 72px; text-align: right; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.st-rank { width: 44px; color: var(--mute-2); }
.st-sort { all: unset; cursor: pointer; font: inherit; color: inherit; white-space: nowrap; }
.st-sort:hover, .st-sort.is-on { color: var(--ink); }
.st-sort:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 3px; }
.st-note { margin: 0; padding: 12px 22px 16px; border-top: 1px solid var(--line); }
@media (max-width: 860px) {
  .st-chart { grid-template-columns: 40px 1fr; padding: 18px 12px 10px 4px; --h: 180px; }
  .st-chart .st-val { display: none; }
  .st-barcol { min-width: 180px; }
  .st-dates { flex: 1 1 100%; }
}
.st-stores td, .st-stores th { white-space: nowrap; }
.st-stores .st-barcol { width: 30%; min-width: 200px; }
.st-sort-sel { display: none; }
/* 휴대폰: 필름별·대리점별 표를 줄마다 카드로 (가로로 밀지 않고 한눈에) */
@media (max-width: 600px) {
  .st-head-note { display: none; }
  .st-sort-sel { display: block; width: auto; height: 34px; font-size: 13.5px; }
  .st-flat { overflow: visible; }
  .st-flat thead { display: none; }
  .st-flat table, .st-flat tbody { display: block; min-width: 0 !important; width: 100%; }
  .st-flat tbody tr { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
  .st-flat tbody tr:last-child { border-bottom: 0; }
  .st-flat tbody tr > * { display: block; padding: 0 !important; border: 0 !important; text-align: left; width: auto; min-width: 0; }
  .st-flat tbody th[scope=row] { order: 1; flex: 1 1 auto; }
  .st-flat .st-rank { order: 0; width: auto; }
  .st-flat .st-locc { order: 2; color: var(--mute); font-size: 13px; }
  .st-flat .st-barcol { order: 3; flex: 1 1 100%; margin: 4px 0 2px; }
  .st-flat td[data-l] { order: 4; font-size: 12.5px; color: var(--ink-2); }
  .st-flat td[data-l]::before { content: attr(data-l) ' '; color: var(--mute); }
  .st-flat .st-topc .film-chip { font-size: 11.5px; }
  .st-stores td, .st-stores th { white-space: normal; }
}
@media (max-width: 600px) {
  .ledger .lg-prod { min-width: 112px; }
  .ledger th, .ledger td { padding: 8px 10px; }
}
/* 본사 재고 수정 (2026-11-27) */
.ledger .lg-adj { color: var(--ink); font-variant-numeric: tabular-nums; }
.toolbar .grow { flex: 1 1 auto; }
.adj-list { display: grid; gap: 6px; max-height: min(52vh, 460px); overflow-y: auto; margin: 4px 0 14px; padding-right: 2px; }
.adj-row { display: grid; grid-template-columns: minmax(0, 1fr) auto 96px 44px; align-items: center; gap: 10px; }
.adj-now { font-size: 13px; font-variant-numeric: tabular-nums; }
.adj-in { width: 96px; text-align: right; font-variant-numeric: tabular-nums; }
.adj-diff { font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--blue); }
@media (max-width: 600px) {
  .adj-row { grid-template-columns: minmax(0, 1fr) 84px 40px; }
  .adj-now { display: none; }
  .adj-in { width: 84px; }
}
/* 계정 접속 안내 (2026-11-27) */
.pw-row { display: flex; gap: 8px; }
.pw-row input { flex: 1 1 auto; min-width: 0; }
.pw-row .btn { flex: none; }
