:root {
    --bg: #f4f7fb;
    --card: #ffffff;
    --text: #1e2a39;
    --muted: #6b7280;
    --line: #d9e0ea;
    --primary: #2b579a;
    --primary-soft: #e8eef8;
    --danger: #c0392b;
    --warning: #fff3cd;
    --success-bg: #ecfdf3;
    --success-text: #166534;
    --error-bg: #fef2f2;
    --error-text: #991b1b;
    --info-bg: #eff6ff;
    --info-text: #1d4ed8;
    --shadow: 0 8px 24px rgba(0,0,0,.06);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; font-family: "Malgun Gothic", "Segoe UI", sans-serif; background: var(--bg); color: var(--text); }
a { color: inherit; text-decoration: none; }

.shell { min-height: 100vh; display: grid; grid-template-columns: 240px 1fr; }
.sidebar { background: #1f2937; color: white; padding: 20px 16px; }
.brand { margin-bottom: 24px; padding-bottom: 16px; border-bottom: 1px solid rgba(255,255,255,.12); }
.brand-title { font-size: 1.35rem; font-weight: 700; }
.brand-subtitle { font-size: .9rem; opacity: .7; margin-top: 4px; }
.nav-menu { display: flex; flex-direction: column; gap: 8px; }
.nav-link { display: block; padding: 10px 12px; border-radius: 12px; color: rgba(255,255,255,.85); }
.nav-link.active, .nav-link:hover { background: rgba(255,255,255,.12); color: white; }
.content { padding: 24px; }

.page-grid { display: grid; gap: 16px; }
.page-card, .summary-card, .form-card { background: var(--card); border-radius: 18px; box-shadow: var(--shadow); padding: 18px; }
.mini-card { padding: 16px; }
.page-card h1, .page-card h3, .page-card h4 { margin-top: 0; }

.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 10px 0 16px; }
.toolbar-stack { gap: 8px; }
.toolbar-line { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.field-inline, .field-label { display: inline-flex; flex-direction: column; gap: 6px; font-weight: 600; }
.field-inline span { font-size: .95rem; }

.text-input, .text-area, select.text-input { width: 100%; padding: 9px 10px; border: 1px solid var(--line); border-radius: 10px; background: white; font: inherit; }
.text-input:focus, .text-area:focus { outline: 2px solid rgba(43, 87, 154, .2); border-color: var(--primary); }
.text-right { text-align: right; }

.btn { border: none; border-radius: 10px; padding: 10px 14px; font: inherit; font-weight: 600; cursor: pointer; }
.btn-primary { background: var(--primary); color: white; }
.btn-secondary { background: #eef2f7; color: #1f2937; }
.btn-light { background: #f7f9fc; color: #1f2937; border: 1px solid var(--line); }
.btn-danger { background: var(--danger); color: white; }
.btn:disabled { opacity: .55; cursor: not-allowed; }

.notice { padding: 12px 14px; border-radius: 12px; margin-bottom: 14px; font-weight: 600; }
.notice.success { background: var(--success-bg); color: var(--success-text); }
.notice.error { background: var(--error-bg); color: var(--error-text); }
.notice.info { background: var(--info-bg); color: var(--info-text); }
.notice.warning { background: var(--warning); color: #8a6d3b; }

.summary-grid, .form-grid, .preset-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); margin-bottom: 16px; }
.summary-label { font-size: .9rem; color: var(--muted); }
.summary-value { font-size: 1.2rem; font-weight: 700; margin-top: 8px; }

.table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 14px; }
.data-table { width: 100%; border-collapse: collapse; min-width: 980px; }
.data-table th, .data-table td { border-bottom: 1px solid var(--line); padding: 10px; vertical-align: top; }
.data-table th { position: sticky; top: 0; background: #f7f9fc; z-index: 1; text-align: left; }
.data-table tbody tr:hover { background: #fbfdff; }
.warning-cell { background: var(--warning); color: #8a6d3b; font-weight: 700; }
.row-selected { background: #eef6ff; }
.row-empty { opacity: .75; }

.tab-strip { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.tab-button { border: 1px solid var(--line); background: white; padding: 10px 14px; border-radius: 999px; cursor: pointer; font: inherit; font-weight: 600; }
.tab-button.active { background: var(--primary-soft); border-color: #b9cae7; color: var(--primary); }

.link-button { background: none; border: none; padding: 0; color: var(--primary); cursor: pointer; font: inherit; font-weight: 600; text-align: left; }
.row-action-group { display: flex; gap: 6px; }

.chip-list { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 999px; background: #f4f6f9; border: 1px solid var(--line); }
.chip-remove { border: none; background: transparent; color: #666; cursor: pointer; font-size: 1rem; }

.modal-backdrop { position: fixed; inset: 0; background: rgba(15, 23, 42, .4); z-index: 1000; }
.modal-panel { position: fixed; z-index: 1001; inset: 5% 10%; background: white; border-radius: 20px; box-shadow: var(--shadow); padding: 18px; overflow: auto; }
.modal-header { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; margin-bottom: 12px; }

.muted { color: var(--muted); }
.button-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0; }
.error-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; }

@media (max-width: 1100px) {
    .shell { grid-template-columns: 1fr; }
    .sidebar { position: sticky; top: 0; z-index: 5; }
    .content { padding: 14px; }
    .modal-panel { inset: 2%; }
}


.global-banner { margin-bottom: 1rem; }
.diagnostic-pre { white-space: pre-wrap; word-break: break-word; margin: 0; font-family: Consolas, monospace; }
.diagnostic-small { font-size: 0.95rem; line-height: 1.4; }
.notice.warning { background: #fff6db; color: #7a5a00; border: 1px solid #e8d38a; }
.notice.warning a { color: inherit; text-decoration: underline; }

.keyboard-ux-notice {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
    align-items: center;
}

.work-table [data-grid-cell] {
    transition: background-color .12s ease, box-shadow .12s ease;
}

.work-table .grid-editor,
.work-table .grid-lot-button {
    min-height: 40px;
}

.work-table .cell-active {
    background: #eef6ff;
    box-shadow: inset 0 0 0 2px rgba(43, 87, 154, .22);
}

.work-table tr.row-key-active {
    background: #f8fbff;
}

.work-table .grid-lot-button {
    display: inline-flex;
    width: 100%;
    min-width: 120px;
    align-items: center;
    justify-content: flex-start;
    padding: 9px 10px;
    border-radius: 10px;
}

/* Work grid column resize */
.work-table {
  table-layout: fixed;
}

.work-table th {
  position: relative;
  user-select: none;
}

.work-table th .col-resize-handle {
  position: absolute;
  top: 0;
  right: -4px;
  width: 8px;
  height: 100%;
  cursor: col-resize;
  z-index: 5;
}

.work-table th.resizing,
.work-table th.resizing .col-resize-handle {
  cursor: col-resize;
}

.work-table th[data-col-key],
.work-table td[data-col-key] {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* work grid column resize */
.work-table {
  table-layout: fixed;
}

.work-table th {
  position: relative;
  user-select: none;
}

.work-table th .col-resize-handle {
  position: absolute;
  top: 0;
  right: -4px;
  width: 8px;
  height: 100%;
  cursor: col-resize;
  z-index: 5;
}

.work-table th.resizing,
.work-table th.resizing .col-resize-handle {
  cursor: col-resize;
}

.work-table th,
.work-table td {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}


/* append to end of wwwroot/css/site.css */

.work-summary-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.section-tabs-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.section-tabs-scroll {
  display: inline-flex;
  gap: 8px;
  min-width: max-content;
}

.work-table-wrap {
  width: 100%;
  overflow-x: auto;
}

.mobile-only {
  display: none !important;
}

.desktop-only {
  display: block !important;
}

.work-mobile-list {
  display: none;
}

.work-mobile-card {
  border: 1px solid #dde5ee;
  border-radius: 14px;
  background: #fff;
  padding: 12px;
  display: grid;
  gap: 10px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.work-mobile-card.is-filled {
  border-color: #bfd4ff;
}

.work-card-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.work-card-row-top {
  align-items: end;
}

.work-card-col {
  flex: 1 1 0;
  min-width: 0;
}

.work-card-col.full {
  flex: 1 1 100%;
}

.work-card-col-small {
  max-width: 72px;
}

.work-card-label {
  font-size: 0.82rem;
  color: #6b7280;
  margin-bottom: 4px;
}

.work-card-value {
  font-size: 1rem;
  color: #111827;
  word-break: break-word;
}

.work-card-actions {
  display: flex;
  gap: 8px;
}

.work-card-actions .btn {
  flex: 1 1 0;
}

.mobile-lot-button {
  width: 100%;
  text-align: left;
  white-space: normal;
  line-height: 1.4;
}

.warning-text {
  color: #b91c1c;
  font-weight: 700;
}

.work-toolbar-stack .work-toolbar-primary,
.work-toolbar-stack .work-toolbar-secondary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

@media (min-width: 768px) and (max-width: 1199px) {
  .work-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .desktop-only {
    display: none !important;
  }

  .mobile-only {
    display: inline-flex !important;
  }

  .work-summary-grid {
    grid-template-columns: 1fr;
  }

  .work-mobile-list {
    display: grid;
    gap: 12px;
    margin-top: 12px;
  }

  .work-card-row {
    flex-direction: column;
  }

  .work-toolbar-stack .work-toolbar-primary,
  .work-toolbar-stack .work-toolbar-secondary {
    align-items: stretch;
  }

  .work-toolbar-stack .work-toolbar-primary > *,
  .work-toolbar-stack .work-toolbar-secondary > * {
    flex: 1 1 calc(50% - 8px);
  }

  .work-toolbar-stack .field-inline {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .work-toolbar-stack .work-toolbar-primary > *,
  .work-toolbar-stack .work-toolbar-secondary > * {
    flex: 1 1 100%;
  }
}



/* master lock */
.master-page-card {
    min-height: 420px;
}

.master-lock-panel {
    max-width: 640px;
    margin: 18px 0 22px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fbfdff;
    box-shadow: var(--shadow);
}

.master-lock-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.master-lock-desc {
    color: var(--muted);
    line-height: 1.5;
    margin-bottom: 14px;
}

.master-lock-form {
    display: flex;
    gap: 10px;
    align-items: center;
}

.master-lock-input {
    max-width: 240px;
    letter-spacing: 0.18em;
}

.master-lock-error {
    margin-top: 12px;
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .master-lock-form {
        flex-direction: column;
        align-items: stretch;
    }

    .master-lock-input {
        max-width: none;
    }
}


.work-table { border-collapse: separate; border-spacing: 0; min-width: 1180px; background: #fff; }
.work-table thead th { background: #eef3fb; border-right: 1px solid #c1cddd; border-bottom: 1px solid #9fb2c9; font-weight: 700; }
.work-table tbody td { border-right: 1px solid #d4deeb; border-bottom: 1px solid #d4deeb; background: #fff; }
.work-table thead th:first-child, .work-table tbody td:first-child { border-left: 1px solid #d4deeb; }
.work-table tbody tr:hover td { background: #f8fbff; }
.work-table .grid-static-cell { background: #f7f9fc; font-weight: 600; }
.work-table .cell-active { background: #cfe2ff !important; box-shadow: inset 0 0 0 2px #2563eb; }
.work-table .grid-range-selected { background: #dbeafe !important; box-shadow: inset 0 0 0 1px #3b82f6; }
.work-table tr.row-key-active td { background: #eef6ff; }
.work-table tr.row-key-active td.cell-active { background: #cfe2ff !important; }
.work-table .grid-editor, .work-table .grid-lot-button { border: 1px solid #b7c6d8; border-radius: 9px; background: #fff; }
.work-table .grid-editor:focus, .work-table .grid-lot-button:focus { outline: none; border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,.18); }
.work-table .row-action-group .btn { min-width: 58px; }
.table-wrap.work-table-wrap { border: 1px solid #b8c7da; border-radius: 14px; background: #fff; }
.keyboard-ux-notice { border: 1px solid #bfd4ff; }
body.grid-resizing { cursor: col-resize; user-select: none; }

/* 2026-04 UI polish: work table integer qty + resizable pane */
.work-table-wrap {
  width: 100%;
  overflow: auto;
  min-height: 340px;
  resize: vertical;
}

.work-table th,
.work-table td {
  vertical-align: middle;
}

.work-table td {
  min-height: 44px;
}

.work-table .grid-editor,
.work-table .grid-lot-button {
  min-height: 38px;
}

.work-table td:nth-child(8),
.work-table th:nth-child(8) {
  white-space: normal;
}

body.grid-resizing .work-table-wrap {
  resize: none;
}

/* === stage3 work toolbar trust patch === */
.page-card {
    border: 1px solid #d8e0ea;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}

.notice,
.grid-help {
    border-radius: 12px;
}

.work-main-actions,
.work-sub-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-top: 10px;
}

.work-main-actions {
    padding: 4px 0 2px 0;
}

.work-sub-actions {
    padding-top: 6px;
    border-top: 1px dashed #dbe3ee;
}

.work-main-actions .btn {
    min-height: 40px;
    font-weight: 700;
    border-radius: 10px;
}

.work-sub-actions .btn {
    min-height: 36px;
    font-weight: 600;
    border-radius: 10px;
    opacity: 0.96;
}

.work-sub-actions .btn.btn-light,
.work-sub-actions .btn.btn-secondary {
    background: #f5f7fb;
    border-color: #d7e0ec;
    color: #334155;
}

.work-sub-actions .btn:hover {
    opacity: 1;
}

.page-card h1 {
    letter-spacing: -0.02em;
    font-weight: 800;
    color: #0f172a;
}

.data-table thead th {
    background: #eef3f9;
    color: #1e293b;
    font-weight: 800;
    border-bottom: 1px solid #d6e0ec;
}

.data-table tbody td {
    border-bottom: 1px solid #e8eef6;
}

.nav-menu .nav-link {
    border-radius: 12px;
    font-weight: 700;
}

.brand-title {
    font-weight: 800;
    letter-spacing: -0.02em;
}

.summary-card,
.page-card .summary-card,
.status-card,
.dashboard-card {
    border: 1px solid #dde5ef;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.035);
}

/* === stage4 micro polish patch === */
.work-main-actions {
    row-gap: 10px;
    margin-top: 12px;
}

.work-sub-actions {
    row-gap: 10px;
    margin-top: 8px;
    padding-top: 10px;
}

.work-main-actions + .work-sub-actions {
    margin-bottom: 4px;
}

.work-main-actions .btn,
.work-sub-actions .btn {
    box-shadow: none;
}

.work-sub-actions .btn {
    background: #f7f9fc;
}

.page-card {
    border-radius: 16px;
}

.summary-card,
.status-card,
.dashboard-card {
    border-radius: 14px;
}

.data-table {
    border-radius: 12px;
    overflow: hidden;
}

.nav-menu {
    gap: 6px;
}

.nav-menu .nav-link {
    padding-top: 11px;
    padding-bottom: 11px;
}

.page-card h1 {
    margin-bottom: 14px;
}

@media (max-width: 1100px) {
    .work-main-actions,
    .work-sub-actions {
        gap: 7px;
        row-gap: 8px;
    }
}

/* === stage5 visible trust polish === */

/* 전체 톤을 조금 더 업무용/전산용으로 단단하게 */
body {
    background: #eef3f8;
}

/* 좌측 브랜드/메뉴 */
.brand-title {
    font-size: 2rem;
    font-weight: 900;
    letter-spacing: -0.03em;
    color: #ffffff;
    margin-bottom: 2px;
}

.nav-menu {
    gap: 8px;
    margin-top: 10px;
}

.nav-menu .nav-link {
    border-radius: 12px;
    padding: 12px 14px;
    font-weight: 700;
    border: 1px solid transparent;
    transition: all .15s ease;
}

.nav-menu .nav-link:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.10);
}

.nav-menu .nav-link.active,
.nav-menu .nav-link[aria-current="page"] {
    background: #26374b;
    border-color: #3a4d67;
    box-shadow: inset 3px 0 0 #8fb1de;
}

/* 메인 카드 */
.page-card {
    background: #ffffff;
    border: 1px solid #d9e4ef;
    border-radius: 18px;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.05);
}

.page-card h1 {
    font-size: 2rem;
    font-weight: 900;
    letter-spacing: -0.03em;
    color: #0f172a;
    margin-bottom: 16px;
}

/* 상단 버튼 영역을 시각적으로 더 또렷하게 */
.work-main-actions,
.work-sub-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    row-gap: 10px;
    align-items: center;
    border-radius: 14px;
    padding: 10px 12px;
}

.work-main-actions {
    background: #f7fbff;
    border: 1px solid #dbe7f3;
    margin-top: 12px;
}

.work-sub-actions {
    background: #fbfcfe;
    border: 1px dashed #d7e1ec;
    margin-top: 10px;
    padding-top: 11px;
    padding-bottom: 11px;
}

.work-main-actions .btn {
    min-height: 40px;
    border-radius: 11px;
    font-weight: 800;
}

.work-sub-actions .btn {
    min-height: 36px;
    border-radius: 10px;
    font-weight: 700;
    background: #f7f9fc;
    border-color: #d7e0ec;
    color: #334155;
}

/* 정보 카드 */
.summary-card,
.status-card,
.dashboard-card {
    border: 1px solid #dce6f0;
    border-radius: 16px;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.035);
}

/* 섹션 탭류: 가능한 셀렉터를 넓게 잡아 눈에 띄게 */
.section-tabs,
.section-tab-row,
.section-chip-row,
.work-section-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.section-tabs .btn,
.section-tab-row .btn,
.section-chip-row .btn,
.work-section-tabs .btn,
button.section-tab,
button.section-chip,
a.section-tab,
a.section-chip {
    border-radius: 999px;
    border: 1px solid #d6e1ee;
    background: #f8fbff;
    color: #243447;
    font-weight: 800;
    padding: 9px 16px;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.03);
}

.section-tabs .btn.active,
.section-tab-row .btn.active,
.section-chip-row .btn.active,
.work-section-tabs .btn.active,
button.section-tab.active,
button.section-chip.active,
a.section-tab.active,
a.section-chip.active,
.section-tabs .btn[aria-current="page"],
.section-tab-row .btn[aria-current="page"],
.section-chip-row .btn[aria-current="page"],
.work-section-tabs .btn[aria-current="page"] {
    background: #eaf3ff;
    border-color: #a9c1e2;
    color: #184a8b;
    box-shadow: inset 0 -2px 0 #7fa8dc;
}

/* 표/입력칸 */
.data-table {
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #d9e4ef;
}

.data-table thead th {
    background: linear-gradient(180deg, #eef4fa 0%, #e9f0f7 100%);
    color: #1e293b;
    font-weight: 800;
    border-bottom: 1px solid #d7e2ee;
}

.data-table tbody td {
    border-bottom: 1px solid #e7eef6;
}

.data-table tbody tr:hover td {
    background: #fbfdff;
}

.text-input,
.grid-editor,
input[type="text"],
input[type="number"],
input[type="date"],
select,
textarea {
    border-color: #c9d7e6;
    background: #ffffff;
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.03);
}

.text-input:focus,
.grid-editor:focus,
input[type="text"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
select:focus,
textarea:focus {
    border-color: #5b86c5;
    box-shadow: 0 0 0 3px rgba(91, 134, 197, 0.12);
}

/* LOT 버튼은 이 화면의 핵심이라 조금 더 또렷하게 */
[data-grid-button="lot"],
button[data-grid-button="lot"],
.lot-button,
.btn-lot {
    border-radius: 10px;
    border: 1px solid #c7d8ec;
    background: linear-gradient(180deg, #f8fbff 0%, #eef5ff 100%);
    color: #1d4ed8;
    font-weight: 900;
    letter-spacing: -0.01em;
}

[data-grid-button="lot"]:hover,
button[data-grid-button="lot"]:hover,
.lot-button:hover,
.btn-lot:hover {
    background: linear-gradient(180deg, #eef5ff 0%, #e2eeff 100%);
    border-color: #9db8db;
}

/* 선택/LOT 작은 작업 버튼도 조금 더 정돈 */
.row-action-group .btn,
td:last-child .btn {
    border-radius: 10px;
    font-weight: 700;
}

/* 화면이 넓을 때 상단 영역이 더 안정적으로 보이도록 */
@media (min-width: 1200px) {
    .page-card {
        padding-top: 18px;
    }
}

/* === stage7 high-visibility layout patch === */

/* 좌측 전체 폭과 브랜드 존재감 강화 */
.sidebar,
.layout-sidebar,
aside {
    min-width: 168px;
}

.brand-title {
    font-size: 2.15rem;
    font-weight: 900;
    letter-spacing: -0.035em;
    color: #ffffff;
    margin-bottom: 8px;
}

.brand-block,
.brand-area,
.sidebar-brand {
    padding-bottom: 10px;
    margin-bottom: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.10);
}

/* 좌측 메뉴 활성 상태를 더 확실하게 */
.nav-menu .nav-link {
    padding: 13px 16px;
    border-radius: 14px;
    font-weight: 800;
    font-size: 0.98rem;
    transition: all .16s ease;
}

.nav-menu .nav-link:hover {
    background: rgba(255,255,255,0.08);
    transform: translateX(1px);
}

.nav-menu .nav-link.active,
.nav-menu .nav-link[aria-current="page"] {
    background: linear-gradient(180deg, #29405a 0%, #24384f 100%);
    border: 1px solid #4f6a8a;
    box-shadow: inset 4px 0 0 #9cc0f2, 0 8px 18px rgba(0,0,0,0.12);
    color: #ffffff;
}

/* 상단 툴바를 박스 2개로 명확하게 분리 */
.work-toolbar-shell {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 14px;
    margin-bottom: 10px;
}

.work-primary-box,
.work-secondary-box {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    row-gap: 10px;
    align-items: center;
    border-radius: 16px;
    padding: 12px 14px;
}

.work-primary-box {
    background: linear-gradient(180deg, #f7fbff 0%, #eef5fd 100%);
    border: 1px solid #d6e4f3;
    box-shadow: 0 10px 20px rgba(30, 41, 59, 0.04);
}

.work-secondary-box {
    background: #fcfdff;
    border: 1px solid #dde6ef;
    box-shadow: 0 8px 16px rgba(30, 41, 59, 0.03);
}

.work-primary-box .btn {
    min-height: 42px;
    border-radius: 11px;
    font-weight: 800;
}

.work-secondary-box .btn {
    min-height: 37px;
    border-radius: 10px;
    font-weight: 700;
    background: #f6f8fb;
    border-color: #d4deea;
    color: #334155;
}

/* 섹션 탭을 더 또렷하게 */
button.section-tab,
button.section-chip,
a.section-tab,
a.section-chip,
.section-tabs .btn,
.section-tab-row .btn,
.work-section-tabs .btn {
    border-radius: 999px !important;
    padding: 10px 17px !important;
    font-weight: 800 !important;
    border: 1px solid #d7e2ee !important;
    background: #f8fbff !important;
    color: #243447 !important;
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.04);
}

button.section-tab.active,
button.section-chip.active,
a.section-tab.active,
a.section-chip.active,
.section-tabs .btn.active,
.section-tab-row .btn.active,
.work-section-tabs .btn.active,
button.section-tab[aria-current="page"],
button.section-chip[aria-current="page"],
.section-tabs .btn[aria-current="page"],
.section-tab-row .btn[aria-current="page"],
.work-section-tabs .btn[aria-current="page"] {
    background: linear-gradient(180deg, #e7f0ff 0%, #dce9ff 100%) !important;
    border-color: #93b3e0 !important;
    color: #15407b !important;
    box-shadow: inset 0 -3px 0 #6f98d1, 0 6px 14px rgba(59, 130, 246, 0.10);
}

/* LOT 버튼 존재감 강화 */
.lot-primary-button,
[data-grid-button="lot"],
button[data-grid-button="lot"] {
    border-radius: 11px !important;
    border: 1px solid #8fb2df !important;
    background: linear-gradient(180deg, #f2f7ff 0%, #e2eeff 100%) !important;
    color: #1d4ed8 !important;
    font-weight: 900 !important;
    box-shadow: 0 6px 14px rgba(37, 99, 235, 0.08);
}

.lot-primary-button:hover,
[data-grid-button="lot"]:hover,
button[data-grid-button="lot"]:hover {
    background: linear-gradient(180deg, #e7f0ff 0%, #d7e7ff 100%) !important;
    border-color: #6f98d1 !important;
    transform: translateY(-1px);
}

/* 작업 컬럼의 선택/LOT 버튼도 더 정돈 */
.row-action-group .btn,
td:last-child .btn {
    min-height: 34px;
    border-radius: 10px;
    font-weight: 700;
}

/* 표와 카드 톤을 조금 더 선명하게 */
.page-card {
    border-radius: 20px;
    border: 1px solid #d8e3ee;
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.05);
}

.summary-card,
.status-card,
.dashboard-card {
    border-radius: 16px;
    border: 1px solid #dbe5ef;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.035);
}

.data-table {
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #d9e4ef;
}

.data-table thead th {
    background: linear-gradient(180deg, #edf4fb 0%, #e6eef7 100%);
    color: #1e293b;
    font-weight: 800;
}

@media (max-width: 1100px) {
    .work-primary-box,
    .work-secondary-box {
        padding: 10px 11px;
        gap: 7px;
        row-gap: 8px;
    }

    .nav-menu .nav-link {
        padding: 11px 13px;
    }
}
