/* KAIHOST Design v1.5.2 integration layer for APS.
   ─────────────────────────────────────────────────────────────
   v1.6 (디자인 통일): 콘텐츠 영역(구 .erp-content) 자체 디자인 블록과
   구 로그인(.auth-split) 스타일을 제거했다.
   · 콘텐츠 영역 규격  → assets/erp-unified.css + erp-unified-aps.css 가 담당
   · 로그인 페이지     → assets/auth-split.css (lg-* 시스템) 가 담당
   · 이 파일에는 "사이드바/탑바 셸" 관련 스타일만 남긴다 (수정 금지 영역). */
@import url("./app.css");

:root {
  --kh-content-gap: 20px;
  --kh-panel-radius: 12px;
  --kh-sidebar-collapsed: 76px;
}

/* Keep long navigation usable without showing a permanent inner scrollbar. */
.s-nav, .menu, .side-nav {
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.s-nav::-webkit-scrollbar,
.menu::-webkit-scrollbar,
.side-nav::-webkit-scrollbar {
  width: 0;
  height: 0;
}
.menu-group-h { appearance: none; font: inherit; }
.menu-sub { overflow: hidden; }
.menu-section-group { display: flex; flex-direction: column; }
.menu-section-toggle {
  width: 100%;
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 4px 0 2px;
  padding: 10px 10px 7px;
  border: 0;
  background: transparent;
  color: var(--sidebar-ink-dim);
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .06em;
  text-align: left;
  cursor: pointer;
}
.menu-section-toggle i { font-size: 12px; transition: transform .18s ease; }
.menu-section-group.collapsed .menu-section-toggle i { transform: rotate(-90deg); }
.menu-section-group.collapsed .menu-section-body { display: none; }
.menu-section-toggle:hover,
.menu-section-toggle:focus-visible { color: var(--sidebar-active-ink); }
.sidebar .sidebar-section-label,
.sidebar .menu-section-toggle,
.sidebar .menu-section,
.sidebar .s-section { font-size: 14px; }

.sidebar-mode-btn { display: inline-flex; }
.app-shell.sidebar-collapsed .sidebar { width: var(--kh-sidebar-collapsed); }
.app-shell.sidebar-collapsed .main { margin-left: var(--kh-sidebar-collapsed); }
.app-shell.sidebar-collapsed .s-head > div,
.app-shell.sidebar-collapsed .menu-item span,
.app-shell.sidebar-collapsed .menu-section,
.app-shell.sidebar-collapsed .s-foot { display: none; }
.app-shell.sidebar-collapsed .s-head,
.app-shell.sidebar-collapsed .menu-item { justify-content: center; }

body.sidebar-white .sidebar {
  background: #fff;
  color: #26384a;
  border-right: 1px solid #dce5ec;
}
body.sidebar-white .sidebar .menu-item,
body.sidebar-white .sidebar .menu-section,
body.sidebar-white .sidebar .s-foot { color: #53697c; }
body.sidebar-white .sidebar .menu-item.active,
body.sidebar-white .sidebar .menu-item:hover { background: #eaf5f7; color: #087f8c; }

.topbar-actions { flex-wrap: nowrap; }

/* 아이콘 칩 베이스(콘텐츠 톤 재정의는 erp-unified-aps.css §아이콘 참고) */
.ic-primary { background: var(--primary-soft); color: var(--primary); }
.ic-success { background: var(--success-soft); color: var(--success); }
.ic-warning { background: var(--warning-soft); color: var(--warning); }
.ic-danger { background: var(--danger-soft); color: var(--danger); }
.ic-violet { background: var(--violet-soft); color: var(--violet); }

/* 유틸리티 */
.wrap-anywhere { word-break: break-all; }
.cell-wrap { white-space: normal; }
.text-danger { color: var(--down, #d9433f); }
.flex-spacer { flex: 1; }
.inline-form { display: inline; }
.row-gap-sm { gap: 6px; }
.note-spaced { margin-top: 12px; }
.check-note { display: block; margin: 8px 0; }
.compact-list { margin: 0; padding-left: 18px; font-size: 13.5px; line-height: 1.9; }
.login-hint .btn { display: inline-block; margin-top: 10px; }

@media (max-width: 992px) {
  .sidebar-mode-btn { display: none; }
  .app-shell.sidebar-collapsed .main { margin-left: 0; }
}
