    :root {
        --navy: #1f3864;
        --navy-dark: #16294a;
        --row-alt: #eaf2fb;
        --border: #cdd9e6;
        --text: #1a1a1a;
        --muted: #5a6b7d;
        --accent: #1a4f8a;
        --danger: #c0392b;
    }
    * { box-sizing: border-box; }
    body {
       font-family: 'DM Sans', sans-serif;
        margin: 0;
        background: #F5F4F0;
        color: var(--text);
        font-size: 14px;
    }
    header.topbar {
        background: var(--navy);
        color: #fff;
        padding: 5px 24px;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    header.topbar h1 { font-size: 18px; margin: 0; font-weight: 600; }
    nav.tabs {
        display: flex;
        gap: 4px;
        padding: 0 24px;
        background: var(--navy-dark);
    }
    nav.tabs a {
        color: #cfe0f5;
        text-decoration: none;
        padding: 10px 16px;
        font-size: 13px;
        border-bottom: 3px solid transparent;
    }
    nav.tabs a.active {
        color: #fff;
        border-bottom-color: var(--accent);
        font-weight: 600;
    }
    .card {
        background: #fff;
        border: 1px solid var(--border);
        border-radius: 6px;
        padding: 18px;
        margin-bottom: 18px;
    }
    .filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; }
    .filters .field { display: flex; flex-direction: column; gap: 4px; }
    .filters label { font-size: 12px; color: var(--muted); }
    input, select {
        padding: 6px 8px;
        border: 1px solid var(--border);
        border-radius: 4px;
        font-size: 13px;
        min-width: 160px;
    }
    button, .btn {
        background: var(--accent);
        color: #fff;
        border: none;
        padding: 7px 14px;
        border-radius: 4px;
        font-size: 13px;
        cursor: pointer;
        text-decoration: none;
        display: inline-block;
    }
    button.secondary, .btn.secondary { background: #6b7d92; }
    button.danger, .btn.danger { background: var(--danger); }
    table { width: 100%; border-collapse: collapse; background: #fff; }
    thead th {
        background: var(--navy);
        color: #fff;
        text-align: left;
        padding: 9px 10px;
        font-size: 12.5px;
        position: sticky;
        top: 0;
    }
    tbody td { padding: 8px 10px; border-bottom: 1px solid var(--border); }
    tbody tr:nth-child(even) { background: var(--row-alt); }
    tbody tr:hover { background: #d9e8fb; }
    .table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 6px; }
    .pagination { display: flex; align-items: center; gap: 10px; margin-top: 14px; font-size: 13px; color: var(--muted); }
    .pagination a { color: var(--accent); text-decoration: none; }
    .pagination a.disabled { color: #b7c2cf; pointer-events: none; }
    .badge { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 11.5px; background: #e3ecf7; color: var(--navy); }
    .badge.warn { background: #fdecea; color: var(--danger); }
    .badge.ok { background: #e6f4ea; color: #1e7e34; }
    .flash { padding: 10px 14px; border-radius: 5px; margin-bottom: 14px; font-size: 13px; }
    .flash.success { background: #e6f4ea; color: #1e7e34; border: 1px solid #b7dfc3; }
    .flash.error { background: #fdecea; color: var(--danger); border: 1px solid #f3c1bb; }
    .muted { color: var(--muted); }
    form.stacked { display: flex; flex-direction: column; gap: 12px; max-width: 640px; }
    form.stacked .field { display: flex; flex-direction: column; gap: 4px; }
    form.stacked label { font-size: 13px; font-weight: 600; }
    .grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
    .category-fields { display: none; }
    .category-fields.active { display: block; }
    tr.detail-row td { background: #f4f7fb; padding: 10px 14px; }
    .subtable-wrap { color: var(--muted); font-size: 12.5px; }
    table.subtable { width: 100%; border-collapse: collapse; background: #fff; }
    table.subtable thead th {
        background: #dbe6f4; color: var(--navy); position: static;
        font-size: 11.5px; padding: 6px 10px;
    }
    table.subtable tbody td { padding: 5px 10px; border-bottom: 1px solid var(--border); font-size: 12.5px; }
.page-content{
    display: flex;
    min-height: calc(100vh - 72px);
    background: #f5f4f0;
}
.page-sidebar {
    width: 200px;
    min-width: 200px;
    border-right: 1px solid rgba(0, 0, 0, 0.09);
    background: #111827;
    padding: 16px 12px;
}
main {
    flex: 1;
    min-width: 0;
    padding:20px;
}
.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.nav-menu a {
    display: block;
    padding: 8px 10px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    color: #fff;
    text-decoration: none;
    white-space: nowrap;
}
.nav-menu a.active {
background: #263247;
    color: #fff;
}
.logo {
    width: 50px;
    margin-right: 10px;
}
.login-card {
    background: #FFFFFF;
    border-radius: 12px;
    border: 1px solid #00000017;
    box-shadow:0 1px 3px rgba(0, 0, 0, 0.07), 0 4px 14px rgba(0, 0, 0, 0.05);
    padding: 30px 40px;
    text-align: center;
    max-width: 420px;
    margin: 50px auto;
}
.login-card h2 {
    font-size: 21px;
    font-weight: 700;
    margin-bottom: 8px;
    margin-top:0px;
}
.login-card p {
    color: #5a5955;
    font-size: 14px;
    margin-bottom: 15px;
}
.btn-primary {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
    padding: 10px 22px;
    border-radius: 7px;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background 0.12s;
}
.login-divider{
margin:20px 0;display:flex;align-items:center;gap:10px
}
.login-form label{
        font-size: 12px;
    font-weight: 600;
    color: #5A5955;
    display: block;
    margin-bottom: 4px;
    text-align: left;
}
.login-form input{
        width: 100%;
    padding: 9px 11px;
    border: 1px solid #D1D5DB;
    border-radius: 7px;
    font-size: 14px;
    font-family: inherit;
    outline: none;
    margin-bottom: 12px;
}
.login-note{
        font-size: 12px !important;
    color: #9A9892 !important;
    margin-top: 6px;
    text-align: center;
    margin-bottom: 0 !important;
}
.ms-logo {
    display: inline-flex;
    gap: 2px;
    flex-wrap: wrap;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}
.ms-logo span {
    width: 9px;
    height: 9px;
    border-radius: 1px;
}
.login-btn{
        width: 100%;
    justify-content: center;
}
#loginSection{
        display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh;
}
/* ---- Price Matrix Lookup ---- */
.pml-columns {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}
.pml-columns > .card {
    border-radius: 10px;
    padding: 22px 24px;
    margin-bottom: 0;
    border-color: #e5e7eb;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}
.pml-card-title {
    font-size: 17px;
    font-weight: 700;
    margin: 0 0 18px;
    color: #111827;
}
.pml-tiles {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}
.pml-tile {
    display: flex;
    flex-direction: column;
    gap: 5px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 11px 13px;
    min-width: 0;
}
.pml-tile-label {
    font-size: 10.5px;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #6b7280;
}
.pml-tile-value {
    font-size: 15px;
    font-weight: 700;
    color: #111827;
    overflow-wrap: anywhere;
}
.pml-note {
    background: #f1f7e8;
    border-left: 4px solid #7cb342;
    border-radius: 4px;
    padding: 12px 14px;
    margin-top: 16px;
    font-size: 13.5px;
    line-height: 1.5;
    color: #33401f;
}
.pml-empty { margin: 0; font-size: 13.5px; }
.pml-pipeline {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}
.pml-step {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 12px 11px;
    min-width: 0;
}
.pml-step-title {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 8px;
}
.pml-step p {
    margin: 0;
    font-size: 12.5px;
    line-height: 1.45;
    color: #374151;
}
@media (max-width: 1200px) {
    .pml-columns { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
    .pml-tiles { grid-template-columns: minmax(0, 1fr); }
    .pml-pipeline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}