@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');

html, body {
    height: 100%;
    margin: 0;
}

body {
    overflow: hidden; /* keep this */
    background: none !important; /* optional safety */
}
.page {
    min-height: 100vh;
    overflow-y: auto;
    background-attachment: fixed;
    background-size: cover;
}
.supplier-total-count {
    margin-left: auto;
    padding-right: 16px;
    color: rgba(255,255,255,0.65);
    font-size: 0.75rem;
    margin-right:50px;
}
.bg-analytics {
    background: radial-gradient(circle at 70% 20%, rgb(11, 47, 21, 0.18), transparent 40%), linear-gradient(135deg, #2b2d36 0%, #12141a 100%);
    rgba(0, 90, 90, 0.15)
}

.bg-tpms {
    background: radial-gradient(circle at 70% 20%, rgba(37, 99, 235, 0.12), transparent 40%), linear-gradient(135deg, #111827 0%, #020617 100%);
}

.bg-default {
    background: #12141a;
}

.main-header {
    background-color: transparent !important;
    transition: background-color 0.25s ease, box-shadow 0.25s ease;
}

.main-header-scrolled {
    background-color:rgba(39, 39, 47, 1) !important;
    backdrop-filter: blur(12px);
}

.full-screen-container::after {
    content: "";
    position: absolute;
    inset: 0;
    background: url('/images/noise.png');
    opacity: 0.03;
    pointer-events: none;
}

.partner-image {
    position: fixed; /* 🔥 THIS is the fix */

    bottom: 20px;
    right: 24px;
    width: 80px;
    height: auto;
    z-index: 1000; /* keep it above content */

    cursor: pointer;
}

.customer-root-card,
.product-card,
.value-chain-card,
.business-process-card,
.supplier-card {
    margin-bottom: 10px;
}

.child-processes,
.supplier-child-tree {
    margin-left: 28px;
    padding-left: 18px;
    border-left: 1px solid rgba(255,255,255,0.12);
}

.relationship-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 6px 0;
    opacity: .9;
}

.clickable-header {
    cursor: pointer;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.supplier-hierarchy-card {
    margin-bottom: 10px;
}

.supplier-child-tree {
    margin-left: 28px;
    padding-left: 18px;
    border-left: 1px solid rgba(255,255,255,0.12);
}

.supplier-relationship-line {
    position: relative;
    margin-top: 12px;
}

    .supplier-relationship-line::before {
        content: "";
        position: absolute;
        top: 28px;
        left: -18px;
        width: 18px;
        height: 1px;
        background: rgba(255,255,255,0.14);
    }

.relationship-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 4px 0 6px 0;
    opacity: 0.9;
}

.partner-tile {
    cursor: pointer;
    text-align: center;
    padding: 20px;
    transition: all .2s ease;
    color: var(--mud-palette-text-primary);
}

    .partner-tile:hover {
        transform: translateY(-4px);
    }

.settings-icon {
    filter: drop-shadow(0 0 8px rgba(255,255,255,.15));
}

.supplier-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}
.supplier-form {
    /*width: min(1200px, 100%);*/
    margin: 0 auto;
    background: transparent !important;
}

    .supplier-form .mud-expansion-panel {
        background: rgba(255,255,255,0.03);
        border: 1px solid rgba(255,255,255,0.06);
        border-radius: 14px;
        margin-bottom: 12px;
    }

    .supplier-form .mud-table {
        background: transparent;
    }

.import-preview-table {
    font-size: 0.78rem;
}

    .import-preview-table .mud-table-cell {
        padding: 4px 8px !important;
        vertical-align: middle;
    }

    .import-preview-table .mud-input {
        font-size: 0.75rem !important;
    }

    .import-preview-table .mud-input-control {
        margin-top: 0 !important;
        margin-bottom: 0 !important;
    }

    .import-preview-table .mud-input-slot {
        font-size: 0.75rem !important;
    }

    .import-preview-table .mud-select {
        font-size: 0.75rem !important;
    }

    .import-preview-table .mud-button-root {
        min-width: unset !important;
    }

    .import-preview-table .mud-icon-button {
        padding: 4px !important;
    }

    .import-preview-table .mud-table-row {
        height: 42px;
    }

.blurr-class {
    backdrop-filter: blur(10px);
}

.partner-icon {
    object-fit: contain;
    margin-bottom: 12px;
    opacity: 0.45;
    filter: grayscale(30%);
    cursor: pointer;
    transition: opacity 0.3s ease, transform 0.2s ease, filter 0.25s ease;
}

    /* hover = active */
    .partner-icon:hover {
        opacity: 1;
        transform: translateY(-6px) scale(1.05);
        filter: grayscale(0%) drop-shadow(0 0 10px rgb(213, 213, 209, 0.45));
    }



.settings-icon {
    object-fit: contain;
    margin-bottom: 12px;
    opacity: 1;
    filter: grayscale(30%);
    cursor: pointer;
    transition: opacity 0.3s ease, transform 0.2s ease, filter 0.25s ease;
}

    /* hover = active */
    .settings-icon:hover {
        opacity: 1;
        transform: translateY(-6px) scale(1.05);
        filter: grayscale(0%) drop-shadow(0 0 10px rgb(213, 213, 209, 0.45));
    }

.tprm-dock {
    position: fixed;
    left: 50%;
    bottom: 20px;
    transform: translateX(-50%);
    z-index: 1000;
    display: flex;
    align-items: end;
    gap: 18px;
    padding: 14px 24px;
    background: rgba(18, 20, 26, 0.10);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 28px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
    opacity: 0.22;
    transition: opacity 0.6s ease, background 0.6s ease, border 0.6s ease, box-shadow 0.6s ease;
}

    .tprm-dock:hover,
    .tprm-dock:focus-within,
    .tprm-dock.active {
        opacity: 0.75;
        background: rgba(18, 20, 26, 0.42);
        border: 1px solid rgba(255, 255, 255, 0.09);
        box-shadow: 0 14px 34px rgba(0, 0, 0, 0.32);
    }

    .tprm-dock:hover {
        opacity: 1;
        background: rgba(18, 20, 26, 0.72);
        border: 1px solid rgba(255, 255, 255, 0.12);
        box-shadow: 0 18px 45px rgba(0, 0, 0, 0.45);
    }

.tprm-dock-item {
    border: none;
    background: transparent;
    cursor: pointer;
    width: 46px;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.tprm-dock-icon {
    font-size: 24px;
    transition: color 0.2s ease;
}

.tprm-dock-img {
    width: 24px;
    height: 24px;
    transition: opacity 0.2s ease;
}

.tprm-dock:hover .tprm-dock-item img,
.tprm-dock:focus-within .tprm-dock-item img,
.tprm-dock.active .tprm-dock-item img {
    opacity: 1;
}

.tprm-dock-item:hover {
    transform: translateY(-8px);
}
    .tprm-dock-item:hover .tprm-dock-icon,
    .tprm-dock-item:hover .tprm-dock-img {
        color: #ffffff;
        opacity: 1;
    }

.tprm-dock-item:focus {
    outline: none;
}

.tprm-dock-item:focus-visible img {
    filter: drop-shadow(0 0 14px rgba(214, 31, 55, 0.65));
}

.tprm-dock-item span {
    font-size: 0.75rem;
    opacity: 0.85;
    white-space: nowrap;
}

.dashboard-kpi {
    height: 120px;
    padding: 20px;
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
}

    .dashboard-kpi.critical {
        background: linear-gradient(180deg,rgba(214,31,55,0.18) 0%, rgba(214,31,55,0.18) 100%, rgba(255,255,255,0.04) 100%);
    }

    .dashboard-kpi.warning {
        background: linear-gradient(180deg,rgba(255,170,0,0.16) 0%, rgba(255,170,0,0.16) 100%, rgba(255,255,255,0.04) 100%);
    }


.dashboard-kpi {
    position: relative; /* IMPORTANT */

    height: 120px;
    padding: 20px;
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border 0.2s ease;
}
/* hover */
    .dashboard-kpi.clickable:hover {
        cursor: pointer;
        transform: translateY(-6px) scale(1.02);
        background: rgba(255,255,255,0.06);
        border: 1px solid rgba(255,255,255,0.15);
        box-shadow: 0 14px 35px rgba(0,0,0,0.35);
    }



/* TABLE Values */
.mud-table-root{
    overflow:hidden!important;
}
.tprm-table {
    background: rgba(18, 20, 26, 0.75);
    border-radius: 18px;
    overflow: hidden;
}

.vertical-scroll-only .mud-table-container::-webkit-scrollbar {
    width: 10px;
}

.vertical-scroll-only .mud-table-container::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.03);
    border-radius: 10px;
}

.vertical-scroll-only .mud-table-container::-webkit-scrollbar-thumb {
    background: rgba(37,99,235,0.35);
    border-radius: 10px;
}

    .vertical-scroll-only .mud-table-container::-webkit-scrollbar-thumb:hover {
        background: rgba(96,165,250,0.5);
    }

/* =========================================================
   TPRM GLASS TABLE
   Fits:
   radial-gradient(circle at 70% 20%, rgba(37,99,235,0.12), transparent 40%),
   linear-gradient(135deg, #111827 0%, #020617 100%)
   ========================================================= */

.tprm-table {
    background: rgba(15, 23, 42, 0.42) !important;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.03);
}

    /* =========================================================
   TABLE HEADER
   ========================================================= */

    .tprm-table .mud-table-head {
        background: linear-gradient( 90deg, rgba(37,99,235,0.16) 0%, rgba(30,41,59,0.10) 100% );
    }

        .tprm-table .mud-table-head th {
            color: rgba(255,255,255,0.92);
            font-weight: 700;
            font-size: 0.92rem;
            letter-spacing: 0.02em;
            padding-top: 18px;
            padding-bottom: 18px;
            border-bottom: 1px solid rgba(255,255,255,0.06);
        }

    /* =========================================================
   SORT LABELS
   ========================================================= */

    .tprm-table .mud-table-sort-label {
        color: rgba(255,255,255,0.88);
    }

        .tprm-table .mud-table-sort-label:hover {
            color: #60A5FA;
        }

    /* =========================================================
   ROWS
   ========================================================= */

    .tprm-table .mud-table-body tr {
        background: transparent;
        transition: background 0.18s ease, transform 0.12s ease;
    }

        /* subtle stripe */

        .tprm-table .mud-table-body tr:nth-child(even) {
            background: rgba(255,255,255,0.018);
        }

        /* hover */

        .tprm-table .mud-table-body tr:hover {
            background: linear-gradient( 90deg, rgba(37,99,235,0.12), rgba(255,255,255,0.02) ) !important;
            transform: scale(1.001);
        }

    /* =========================================================
   CELLS
   ========================================================= */

    .tprm-table .mud-table-body td {
        color: rgba(255,255,255,0.88);
        border-bottom: 1px solid rgba(255,255,255,0.04);
        padding-top: 14px;
        padding-bottom: 14px;
    }

    /* =========================================================
   PAGINATION
   ========================================================= */

    .tprm-table .mud-table-pagination {
        background: rgba(255,255,255,0.02);
        border-top: 1px solid rgba(255,255,255,0.05);
        color: rgba(255,255,255,0.88);
    }

    /* =========================================================
   ICON BUTTONS
   ========================================================= */

    .tprm-table .mud-icon-button {
        color: rgba(255,255,255,0.75);
    }

        .tprm-table .mud-icon-button:hover {
            color: #60A5FA;
            background: rgba(37,99,235,0.12);
        }

    /* =========================================================
   EXPANDED DETAIL AREA
   ========================================================= */

    .tprm-table .supplier-detail {
        background: linear-gradient( 135deg, rgba(15,23,42,0.55), rgba(2,6,23,0.72) ) !important;
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border: 1px solid rgba(255,255,255,0.05);
        border-radius: 18px;
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
    }

    /* =========================================================
   CHIPS
   ========================================================= */

    .tprm-table .mud-chip {
        background: rgba(37,99,235,0.16);
        color: #BFDBFE;
        border: 1px solid rgba(96,165,250,0.15);
    }


@media print {

    html,
    body {
        width: 100%;
        height: 100%;
        overflow: hidden !important;
        background: white !important;
    }

        body * {
            visibility: hidden !important;
        }

    #sankey-print-area,
    #sankey-print-area * {
        visibility: visible !important;
    }

    #sankey-print-area {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        background: white !important;
        color: #111 !important;
        padding: 0;
        margin: 0;
        overflow: hidden !important;
    }

        #sankey-print-area canvas {
            max-width: 100% !important;
            max-height: 100% !important;
        }

    .sankey-print-header {
        display: block !important;
        padding: 12px 20px 0 20px;
    }

        .sankey-print-header h1 {
            font-size: 20px;
            margin: 0 0 4px 0;
            color: #111;
        }

        .sankey-print-header p {
            font-size: 11px;
            margin: 0 0 10px 0;
            color: #555;
        }

    .mud-button-root,
    .mud-input,
    .mud-select,
    .mud-toolbar,
    .mud-appbar,
    .mud-drawer,
    .mud-dialog {
        display: none !important;
    }

    @page {
        size: A3 landscape!important;
        margin: 8mm;
    }
}

@media screen {

    .sankey-print-header {
        display: none;
    }
}

.stat-card{
    background-color:transparent!important;
}


.map-container {
    position: relative;
}

.world-map {
    width: 100%;
    height: 550px;
}

.map-title {
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 6px;
    background: rgba(0,0,0,0.45);
    color: white;
    backdrop-filter: blur(8px);
}

.country-panel-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.15);
    z-index: 1200;
}

.country-panel {
    position: fixed;
    top: 90px;
    right: 24px;
    bottom: 24px;
    width: 460px;
    max-width: calc(100vw - 32px);
    z-index: 1300;
    padding: 18px;
    overflow-y: auto;
    border-radius: 14px;
    background: var(--ds-card-backgroud-30trans) !important;
    height: 850px;
}

.country-panel-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}

.supplier-row {
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: 8px;
    background: var(--ds-card-bg) !important;
}


.map-view-switch {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin-bottom: 18px;
    padding: 10px 14px;
    background: rgba(15, 23, 42, 0.48);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(96,165,250,0.18);
    border-radius: 999px;
    box-shadow: 0 12px 28px rgba(0,0,0,0.24);
}

.evidence-chip {
    background-color: var(--mud-palette-surface);
    color: var(--mud-palette-text-primary);
    border: 1px solid var(--mud-palette-lines-default);
}

.overdue-text {
    color: #EF4444;
    font-weight: 700;
}

.dependency-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    padding-bottom: 12px;
    backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.sankey-container {
    position: relative;
    z-index: 1;
    overflow: hidden;
}

/* =========================================================
   SEARCH BOX
   ========================================================= */
.tprm-search .mud-input-control {
    background: rgba(255,255,255,0.03);
    backdrop-filter: blur(12px);
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.05);
}

.tprm-search input {
    color: white !important;
}

.tprm-search .mud-input-adornment {
    color: rgba(255,255,255,0.65);
}
/*END*/
.tprm-dashboard-card {
    width: 100%;
    height: 100%;
    min-height: 330px;
    padding: 10px;
    background-color:transparent!important;
    overflow: hidden;
}


/*/   TPRM Chart Card  */
.tprm-chart-card {
    height: 100%;
    min-height: 330px;
    padding: 20px;
    background: rgba(15, 23, 42, 0.42) !important;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 22px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.03);
    overflow: hidden;
}

    .tprm-chart-card:hover {
        background: rgba(15, 23, 42, 0.55) !important;
        border-color: rgba(96,165,250,0.18);
    }

.chart-title {
    color: rgba(255,255,255,0.92);
    font-weight: 700;
    letter-spacing: 0.02em;
    margin-bottom: 12px;
}

.tprm-chart-card .mud-chart-legend {
    color: rgba(255,255,255,0.82);
}

.tprm-chart-card .mud-chart {
    color: rgba(255,255,255,0.88);
}

/* Pie slices */
.tprm-chart-card .mud-chart-serie {
    stroke: rgba(255,255,255,0.16) !important;
    stroke-width: 2.5px !important;
    filter: drop-shadow(0 3px 5px rgba(0,0,0,0.35)) drop-shadow(0 8px 14px rgba(0,0,0,0.18));
    paint-order: stroke fill;
    transition: filter 0.18s ease, transform 0.18s ease;
}

    /* fake bevel lighting */
    .tprm-chart-card .mud-chart-serie:hover {
        stroke: rgba(255,255,255,0.28) !important;
        filter: brightness(1.08) drop-shadow(0 6px 10px rgba(0,0,0,0.45)) drop-shadow(0 0 10px rgba(96,165,250,0.22));
        transform: translateY(-1px);
        transform: scale(1.050);
    }

/* Smooth edges */
.tprm-chart-card svg {
    overflow: visible;
}

/* Subtle center glow */
.tprm-chart-card .mud-chart-series {
    position: relative;
}

    .tprm-chart-card .mud-chart-series::after {
        content: "";
        position: absolute;
        inset: 28%;
        border-radius: 50%;
        background: radial-gradient( circle, rgba(255,255,255,0.08), transparent 70% );
        pointer-events: none;
    }
/*/  END   */
.chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
 /*   margin-bottom: 12px;*/
    margin-top:-15px;
}

.chart-header-icon {
    color: rgba(96,165,250,0.85);
}


/* RISK Matrix*/

.risk-matrix {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.risk-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

    .risk-row.overall {
        margin-top: 4px;
    }

.risk-label {
    color: rgba(255,255,255,0.92);
    font-weight: 600;
}

.risk-description {
    color: rgba(255,255,255,0.55);
}

/*.risk-chip {
    min-width: 82px;
    justify-content: center;
    font-weight: 700;
}*/

.risk-chip {
    min-width: unset !important;
    height: 24px !important;
    padding-left: 8px !important;
    padding-right: 8px !important;
    font-size: 0.68rem !important;
    font-weight: 700;
    border-radius: 9px !important;
    backdrop-filter: blur(10px);
}

    .risk-chip.unknown {
        background: rgba(100,116,139,0.22) !important;
        color: #CBD5E1 !important;
    }

    .risk-chip.low {
        background: rgba(34,197,94,0.20) !important;
        color: #86EFAC !important;
    }

    .risk-chip.medium {
        background: rgba(234,179,8,0.22) !important;
        color: #FDE68A !important;
    }

    .risk-chip.high {
        background: rgba(249,115,22,0.22) !important;
        color: #FDBA74 !important;
    }

    .risk-chip.critical {
        background: rgba(239,68,68,0.24) !important;
        color: #FCA5A5 !important;
    }

    /* END */

    /* -------------------------- Dependency view ------------------------------*/

    /* -----------------------  Customer settings page -------------------------*/
.tprm-form-page {
    padding: 24px;
    background: transparent !important;
    color: white;
}

.page-title {
    color: rgba(255,255,255,0.95);
    font-weight: 700;
}

.page-subtitle {
    color: rgba(255,255,255,0.62);
    margin-bottom: 24px;
}

.glass-form-card {
    margin-bottom: 24px;
    padding: 24px;
    background: rgba(15, 23, 42, 0.42) !important;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 22px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.03);
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    color: rgba(255,255,255,0.94);
}

    .section-header .mud-icon-root {
        color: #60A5FA;
    }

.glass-form-card .mud-input,
.glass-form-card .mud-input-control,
.glass-form-card .mud-select {
    color: rgba(255,255,255,0.92);
}

.settings-panels .mud-expand-panel {
    margin-bottom: 16px;
    background: rgba(15, 23, 42, 0.42) !important;
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 18px !important;
    overflow: hidden;
}

.settings-panels .mud-expand-panel-header {
    color: rgba(255,255,255,0.94);
    font-weight: 700;
}

.settings-panels .mud-expand-panel-content {
    padding: 20px;
}

/*  ------------------------------ END -------------------------------------*/
.divider-space {
    margin-top: 50px !important;
    margin-bottom: 25px !important;
    /* ------------------------------------ TABLE SETTINGS ---------------------------------*/
    .tprm-table-small {
        font-size: 0.78rem;
    }

    .tiny-status-select .mud-select-input {
        font-size: 10px !important;
    }

    .tiny-status-select .mud-input-slot {
        font-size: 10px !important;
    }

    .tiny-status-select .mud-input-root {
        font-size: 10px !important;
    }

    .tiny-status-select-popover .mud-list-item {
        font-size: 10px !important;
        min-height: 26px;
    }


    .mud-popover .mud-list-item {
        font-size: 0.75rem;
        min-height: 28px;
    }

    tprm-table-small .mud-input-root {
        font-size: 10px;
    }

    .tprm-table-small .mud-table-cell {
        font-size: 0.78rem;
        padding-top: 4px;
        padding-bottom: 4px;
    }

    .tprm-table-small .mud-input {
        font-size: 0.78rem;
    }

    .tprm-table-small .mud-select {
        font-size: 0.78rem;
    }

    .tprm-table-small .mud-button-root {
        font-size: 0.72rem;
    }

    .tprm-table-small .mud-chip {
        font-size: 0.68rem;
        height: 20px;
    }

    .tprm-table-small .mud-input-slot {
        font-size: 0.78rem;
    }

    .tprm-table-small .mud-typography-body2 {
        font-size: 0.78rem;
    }

    .tprm-table-small .mud-typography-caption {
        font-size: 0.66rem;
    }
}
/* --------------------------PASSWORD SET ---------------------------*/
.set-password-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px;
    background: radial-gradient(circle at 70% 20%, rgba(37, 99, 235, 0.12), transparent 40%), linear-gradient(135deg, #111827 0%, #020617 100%);
    color: whitesmoke !important;
}

.glass-form-card-password {
    width: 100%;
    max-width: 520px;
    padding: 36px;
    background: rgba(15, 23, 42, 0.42) !important;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 24px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.04);
}

    .glass-form-card-password .mud-input-control,
    .glass-form-card-password .mud-input,
    .glass-form-card-password .mud-select,
    .glass-form-card-password .mud-text-field {
        color: rgba(255,255,255,0.92);
    }

    .glass-form-card-password .mud-input-label {
        color: rgba(255,255,255,0.68);
    }

    .glass-form-card-password .mud-input-slot {
        background: rgba(255,255,255,0.03);
        border-radius: 14px;
        border: 1px solid rgba(255,255,255,0.06);
        transition: all 0.2s ease;
    }

        .glass-form-card-password .mud-input-slot:hover {
            border-color: rgba(96,165,250,0.35);
            background: rgba(255,255,255,0.05);
        }

    .glass-form-card-password .mud-input-focused .mud-input-slot {
        border-color: rgba(96,165,250,0.6);
        box-shadow: 0 0 0 3px rgba(59,130,246,0.15);
    }

    .glass-form-card-password .mud-button-root {
        border-radius: 14px;
    }

    .glass-form-card-password .mud-alert {
        border-radius: 14px;
    }
    .glass-form-card-password .mud-button-filled.mud-button-filled-primary {
        background: linear-gradient( 135deg, #2563EB 0%, #1D4ED8 100% ) !important;
        color: white !important;
        border: 1px solid rgba(255,255,255,0.08);
        box-shadow: 0 4px 18px rgba(37,99,235,0.35);
        transition: all 0.2s ease;
    }

        .glass-form-card-password .mud-button-filled.mud-button-filled-primary:hover {
            transform: translateY(-1px);
            box-shadow: 0 8px 24px rgba(37,99,235,0.45);
            background: linear-gradient( 135deg, #3B82F6 0%, #2563EB 100% ) !important;
        }

    /* ---------------------------------------------END ---------------------------------------------*/


.green-switch .mud-switch-base {
    color: #1e7a45 !important;
}

.green-switch .mud-switch-track {
    background-color: rgba(30,122,69,0.45) !important;
}

.green-switch .mud-switch-track {
    background: linear-gradient( 180deg, rgba(34,197,94,0.35), rgba(21,128,61,0.28) ) !important;
    border: 1px solid rgba(74,222,128,0.22);
    backdrop-filter: blur(10px);
    box-shadow: inset 0 0 8px rgba(255,255,255,0.08), 0 0 12px rgba(34,197,94,0.16);
}

.green-switch .mud-switch-button {
    color: #22c55e !important;
}

.map-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.glass-add-button {
    height: 46px;
    padding: 0 18px !important;
    color: white !important;
    background: linear-gradient( 135deg, rgba(59,130,246,0.28), rgba(37,99,235,0.18) ) !important;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(96,165,250,0.22);
    border-radius: 16px !important;
    box-shadow: 0 10px 28px rgba(0,0,0,0.24), inset 0 0 12px rgba(255,255,255,0.04);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

    .glass-add-button:hover {
        transform: translateY(-2px);
        border-color: rgba(147,197,253,0.42);
        box-shadow: 0 14px 36px rgba(0,0,0,0.34), 0 0 18px rgba(96,165,250,0.18);
    }
.dependency-map-page {
    background: transparent !important;
    color: white;
    padding: 24px;
}

.dependency-subtitle {
    color: rgba(255,255,255,0.62);
}

.dependency-map {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.value-chain-card {
    background: rgba(15, 23, 42, 0.48);
    backdrop-filter: blur(18px);
    border: 1px solid rgba(96,165,250,0.18);
    border-radius: 24px;
    padding: 22px;
    box-shadow: 0 18px 45px rgba(0,0,0,0.38);
    position: relative;
    z-index: 100;
    width:95%;
}

.node-header {
    display: flex;
    align-items: center;
    gap: 14px;
    justify-content: space-between;
}

    .node-header > div {
        flex: 1;
    }

    .node-header .mud-icon-root {
        color: #60A5FA;
    }

.process-tree {
    margin-top: 22px;
    padding-left: 26px;
    border-left: 2px solid rgba(96,165,250,0.22);
}

.process-node {
    position: relative;
    margin-bottom: 24px;
}

    .process-node::before {
        content: "";
        position: absolute;
        top: 26px;
        left: -26px;
        width: 24px;
        height: 2px;
        background: rgba(96,165,250,0.35);
    }

.process-card {
    background: rgba(255,255,255,0.035);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 18px;
    padding: 16px;
}

.supplier-row {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 14px;
    margin-left: 14px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.supplier-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.supplier-actions {
    display: flex;
    align-items: center;
    gap: 2px;
    flex-shrink: 0;
    margin-left: 25px;
}

.supplier-card {
    min-width: 270px;
    max-width: 300px;
    background: linear-gradient( 145deg, rgba(30,41,59,0.50), rgba(2,6,23,0.68) );
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 16px;
    padding: 12px 14px;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
    box-shadow: 0 8px 22px rgba(0,0,0,0.22);
    backdrop-filter: blur(12px);
}

    .supplier-card:hover {
        transform: translateY(-4px);
        border-color: rgba(96,165,250,0.34);
    }
    .supplier-card .mud-typography-body1 {
        font-size: 0.86rem;
        font-weight: 600;
    }

    .supplier-card .mud-typography-caption {
        font-size: 0.68rem;
        color: rgba(255,255,255,0.58);
    }
.supplier-main {
    display: flex;
    align-items: center;
    gap: 10px;
}

    .supplier-main .mud-icon-root {
        font-size: 1rem;
        color: #38BDF8;
    }

.supplier-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}
.supplier-card {
    cursor: grab;
}

    .supplier-card:active {
        cursor: grabbing;
    }

.clickable-header {
    cursor: pointer;
    user-select: none;
    transition: background 0.16s ease, transform 0.12s ease;
}

    .clickable-header:hover {
        background: rgba(255,255,255,0.03);
        border-radius: 12px;
    }

.header-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.drop-zone {
    transition: border-color 0.2s ease, background 0.2s ease;
}

    .drop-zone:hover {
        border-color: rgba(96,165,250,0.45) !important;
        background: rgba(37,99,235,0.08) !important;
    }
.backup-card {
    margin-top: 10px;
    padding: 8px 10px;
    border-radius: 12px;
    display: flex;
    gap: 8px;
    align-items: center;
    background: rgba(20,184,166,0.08);
    border: 1px solid rgba(45,212,191,0.14);
}

    .backup-card .mud-typography-body2 {
        font-size: 0.78rem;
    }

    .backup-card .mud-typography-caption {
        font-size: 0.66rem;
    }

    .backup-card .mud-icon-root {
        color: #2DD4BF;
    }

.child-processes {
    margin-top: 18px;
    margin-left: 32px;
    padding-left: 24px;
    border-left: 1px dashed rgba(255,255,255,0.14);
}

.default-node {
    border-style: dashed !important;
    border-color: rgba(148,163,184,0.28) !important;
    opacity: 0.92;
}


    /* ---------------------------------END -------------------------------------*/

.glass-paper {
    background: rgba(15, 23, 42, 0.58) !important;
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    border: 1px solid rgba(96, 165, 250, 0.18);
    border-radius: 28px !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255,255,255,0.04) inset;
    overflow: hidden;
    color: #e2e8f0;
}


    /* -------------------------- GLASS DIALOG ------------------------------*/
.glass-dialog {
    background: rgba(15, 23, 42, 0.58) !important;
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    border: 1px solid rgba(96, 165, 250, 0.18);
    border-radius: 28px !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255,255,255,0.04) inset;
    overflow: hidden;
    color: #e2e8f0;
}

    .glass-dialog .mud-dialog-title {
        padding: 22px 28px 12px 28px;
        background: linear-gradient( 90deg, rgba(96,165,250,0.08), rgba(214,31,55,0.08) );
        border-bottom: 1px solid rgba(255,255,255,0.06);
        font-weight: 600;
        font-size: 1.15rem;
        color: white;
    }

    .glass-dialog .mud-dialog-content {
        padding: 28px;
    }

    .glass-dialog .mud-dialog-actions {
        padding: 18px 28px 24px 28px;
        border-top: 1px solid rgba(255,255,255,0.05);
        background: rgba(255,255,255,0.015);
    }

.glass-dialog-overlay {
    backdrop-filter: blur(8px);
    background: rgba(2, 6, 23, 0.55);
}

.glass-dialog .mud-input-control {
    margin-bottom: 18px;
}

.glass-dialog .mud-input-slot {
    background: rgba(255,255,255,0.04) !important;
    border-radius: 14px;
}

.glass-dialog .mud-input-label {
    color: rgba(255,255,255,0.72) !important;
}

.glass-dialog .mud-input {
    color: white !important;
}

.glass-dialog .mud-select-input {
    color: white !important;
}

.glass-dialog .mud-button-filled-primary {
    background: linear-gradient( 135deg, #2563eb, #1d4ed8 );
}

.glass-dialog .mud-button-filled-error {
    background: linear-gradient( 135deg, #dc2626, #991b1b );
}
.glass-card{
    background-color:transparent!important;
}
/* -------------------------------- END -------------------------------------*/
.supplier-control-filterbar {
    position: sticky;
    top: 0;
    z-index: 50;
    padding: 16px;
    margin: -16px -16px 16px -16px;
    background: rgba(15, 23, 42, 0.78);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(96,165,250,0.18);
    box-shadow: 0 12px 30px rgba(0,0,0,0.28);
}

.control-treatment-panel {
    padding: 14px 18px 18px 52px;
    background: rgba(15, 23, 42, 0.38);
    border-bottom: 1px solid rgba(96,165,250,0.14);
}

.treatment-card {
    background: rgba(15, 23, 42, 0.52);
    border: 1px solid rgba(96,165,250,0.16);
    border-radius: 16px;
    padding: 14px 16px;
    margin-bottom: 10px;
    box-shadow: 0 10px 24px rgba(0,0,0,0.22);
}

.treatment-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.treatment-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}


.treatment-response-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255,255,255,0.035);
    border: 1px solid rgba(96,165,250,0.12);
    cursor: pointer;
    user-select: none;
}

.treatment-response-toggle-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.treatment-responses-panel {
    padding: 12px 0 0 0;
}

.treatment-response-card {
    background: rgba(2, 6, 23, 0.38);
    border: 1px solid rgba(96,165,250,0.14);
    border-radius: 14px;
    padding: 14px;
    margin-top: 10px;
}

.response-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.response-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.attachment-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.attachment-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.45);
    border: 1px solid rgba(255,255,255,0.06);
}

.attachment-left {
    display: flex;
    align-items: center;
    gap: 10px;
}


.dock-header {
    cursor: pointer;
    user-select: none;
    position: sticky;
    top: 0;
    z-index: 2;
    background: rgba(15, 23, 42, 0.82);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(96,165,250,0.14);
    padding-bottom: 12px;
}


/* -----------------------------------  Unmapped Hover in Operational Dependency Map ---------------------*/

.unmapped-suppliers-sidepanel {
    position: fixed;
    top: 90px;
    right: 18px;
    bottom: 18px;
    width: 380px;
    z-index: 3000;
    margin-top: 160px;
    transition: width 0.22s ease, transform 0.22s ease, z-index 0s;
}

    .unmapped-suppliers-sidepanel.expanded {
        z-index: 3000;
        transform: translateX(0);
    }

    .unmapped-suppliers-sidepanel.collapsed {
        width: 72px;
        z-index: 10;
        transform: translateX(46px);
    }
.unmapped-suppliers-sidepanel.collapsed {
    width: 72px;
    transform: none;
}

    .unmapped-suppliers-sidepanel.collapsed .supplier-row,
    .unmapped-suppliers-sidepanel.collapsed .supplier-meta,
    .unmapped-suppliers-sidepanel.collapsed .node-header .header-left div,
    .unmapped-suppliers-sidepanel.collapsed .risk-chip {
        display: none;
    }

    .unmapped-suppliers-sidepanel.collapsed .value-chain-card {
        padding: 14px 8px;
    }

    .unmapped-suppliers-sidepanel.collapsed .dock-header {
        padding: 8px 0;
        border-bottom: none;
    }

    .unmapped-suppliers-sidepanel.collapsed .header-left {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 10px;
    }

    .unmapped-suppliers-sidepanel.collapsed .node-header {
        justify-content: center;
    }

.unmapped-suppliers-sidepanel {
    position: fixed;
    top: 90px;
    right: 18px;
    bottom: 18px;
    width: 380px;
    z-index: 3000;
    max-height: calc(100vh - 108px);
}

    .unmapped-suppliers-sidepanel .value-chain-card {
        height: 100%;
        max-height: 100%;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }

    .unmapped-suppliers-sidepanel .mud-collapse-container {
        flex: 1;
        min-height: 0;
        overflow: hidden;
    }

    .unmapped-suppliers-sidepanel .mud-collapse-wrapper {
        height: 100%;
    }

    .unmapped-suppliers-sidepanel .mud-collapse-wrapper-inner {
        height: 100%;
/*        display: flex;
        flex-direction: column;
        justify-content: flex-start;*/
        align-items: stretch;
        min-height: 0;
    }
    .unmapped-suppliers-sidepanel .supplier-row {
        flex: 1;
        min-height: 0;
        overflow-y: auto;
        overflow-x: hidden;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        gap: 12px;
        padding-right: 6px;
    }
.unmapped-supplier-search {
    flex-shrink: 0;
    margin-bottom: 10px;
}


.unmapped-suppliers-sidepanel .supplier-card {
    flex-shrink: 0;
    width: 100%;
}


/* ---------------------------------  END ----------------------------------*/


.dock-header {
    cursor: pointer;
    user-select: none;
}

    /* Chart Summary*/
.chart-summary {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255,255,255,0.06);
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.chart-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.72);
}

    .chart-summary-row strong {
        color: rgba(255,255,255,0.95);
        font-weight: 700;
    }

.kpi-icon {
    position: absolute;
    top: 12px;
    right: 12px;
    opacity: 0.85;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

/* nice hover effect */
.dashboard-kpi:hover .kpi-icon {
    transform: scale(1.8);
    opacity: 1;
}


.dashboard-card {
    padding: 16px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    overflow: hidden;
    background-color: transparent !important;
}


.scroll-page {
    position: fixed;
    top: 60px; /* header height */
    left: 0;
    right: 0;
    bottom: 0;
    overflow-y: auto;
    overflow-x: hidden;
    background: transparent !important;
    padding: 24px;
    box-sizing: border-box;
}
.scroll-content {
    width: 100%;
    margin: 0 auto;
    background: transparent !important;
    padding-bottom: 100px;
    box-sizing: border-box;
}

.scroll-content-70 {
    width: 70%;
    margin: 0 auto;
    background: transparent !important;
    padding-bottom: 100px;
    box-sizing: border-box;
}
.scroll-content-80 {
    width: 80%;
    margin: 0 auto;
    background: transparent !important;
    padding-bottom: 100px;
    box-sizing: border-box;
}
.scroll-content-90 {
    width: 90%;
    margin: 0 auto;
    background: transparent !important;
    padding-bottom: 100px;
    box-sizing: border-box;
}
.customer-content {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.customer-actions {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 10px;
}

.customer-tile {
    background-color:transparent!important;
    position: relative;
    height: 140px;
    padding: 16px;
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    /* GLASS BASE */
    background: linear-gradient( 135deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02) );
    border: 1px solid rgba(255,255,255,0.08);
    /* subtle glow */
    box-shadow: 0 8px 25px rgba(0,0,0,0.25), inset 0 1px 0 rgba(255,255,255,0.05);
    backdrop-filter: blur(10px);
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border 0.25s ease;
}

    .customer-tile:hover {
        transform: translateY(-6px) scale(1.02);
        background: linear-gradient( 135deg, rgba(255,255,255,0.10), rgba(255,255,255,0.04) );
        border: 1px solid rgba(255,255,255,0.15);
        box-shadow: 0 14px 35px rgba(0,0,0,0.35), 0 0 20px rgba(214,31,55,0.15);
    }
.app-logo {
    position: absolute;
    top: 20px;
    left: 24px;
    height: 40px; /* adjust */
    width: auto;
    z-index: 10; /* stays above everything */
}
.form-scroll-page {
    position: fixed;
    top: 320px; /* header height */
    left: 0;
    right: 0;
    bottom: 0;
    overflow-y: auto;
    overflow-x: hidden;
    background: transparent !important;
    padding: 24px;
    box-sizing: border-box;
}

.form-content {
    width: min(900px, 100%);
    margin: 0 auto;
    background: transparent !important;
    padding-bottom: 140px;
    box-sizing: border-box;
}

.image-button {
    padding: 0!important;
    border-radius: 16p!important;
    overflow: hidden!important;
    transition: transform 0.2s ease, box-shadow 0.2s ease!important;
    border-radius: 30px !important;
    background: transparen!important;
}

    .image-button:hover {
        transform: scale(1.01);
        box-shadow: 0 8px 24px rgba(0,0,0,0.3);
    }

.btn-img {
    width: 300px; /* adjust */
    height: auto;
    display: block;
}

.image-tile {
    cursor: pointer;
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.25s ease;
    background-color: #111;
    display: flex; /* 🔥 important */
    justify-content: center; /* horizontal */
    align-items: center; /* vertical */

    height: 300px; /* define height or it won’t center vertically */
}

    .image-tile img {
        max-width: 90%;
        max-height: 90%;
        object-fit: contain;
    }

    .image-tile.watchtower {
        background: radial-gradient(circle at center, rgba(0,150,255,0.15), #111);
    }

    .image-tile.tprm {
        background: radial-gradient(circle at center, rgba(0,255,180,0.15), #111);
    }




.worldmap-host svg {
    display: block;
    width: 100%;
    height: 100%;
}

.worldmap-host .countries path {
    fill: #eaeaea !important;
    stroke: #111 !important;
    stroke-width: 0.6px !important;
    vector-effect: non-scaling-stroke;
}
.worldmap-host {
    height: 353px;
    width: 100%;
}

#map, .leaflet-container {
    background: transparent !important;
}

/*#map, .leaflet-control-attribution {
    display: none !important;
}*/

@media print {
    .cover, cover * {
        page-break-after: always;
    }
    .no-print, .no-print * {
        display: none !important;
    }
}
@media print {
    .no-break-inside {
        break-inside: avoid;
        page-break-inside: avoid;
    }
}

@page {
    size: A4;
}

.mud-table-cell {
    cursor: pointer;
}


.reportcover {
    background-image: url("../assets/images/report/cover.jpg");
    background-position: center;
    background-size: cover;
}

html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}
.no-borders > td, .no-borders > tr > th {
    border: none;
}
h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}


.panel{
    background-color:transparent!important;
    padding: 5px;
}

.content {
    padding-top: 1.1rem;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }


/* =========================================================
   Theme layer appended by ChatGPT. You may alternatively use tprm-theme.css after site.css.
   ========================================================= */

/* =========================================================
   Darkscope / 360TPRM Theme Layer
   Load this file AFTER site.css.
   Supported theme hooks:
      <body data-theme="dark">  or  <body class="theme-dark">
      <body data-theme="light"> or  <body class="theme-light">
   ========================================================= */

/* ---------- Base variables ---------- */
:root,
body[data-theme="dark"],
body.theme-dark {
    --ds-bg-0: #020617;
    --ds-bg-1: #071126;
    --ds-bg-2: #0f172a;
    --ds-bg-3: #111827;

    --ds-surface-0: rgba(15, 23, 42, 0.42);
    --ds-surface-1: rgba(15, 23, 42, 0.58);
    --ds-surface-2: rgba(30, 41, 59, 0.50);
    --ds-surface-3: rgba(2, 6, 23, 0.68);

    --ds-card-backgroud-30trans: rgba(15, 23, 42, 0.85);
    --ds-card-bg: rgba(15, 23, 42, 0.48);
    --ds-card-bg-hover: rgba(15, 23, 42, 0.62);
    --ds-panel-bg: rgba(15, 23, 42, 0.78);
    --ds-dialog-bg: rgba(15, 23, 42, 0.72);
    --ds-table-bg: rgba(15, 23, 42, 0.42);
    --ds-table-header-bg: linear-gradient(90deg, rgba(37,99,235,0.16) 0%, rgba(30,41,59,0.10) 100%);
    --ds-row-alt-bg: rgba(255,255,255,0.018);
    --ds-row-hover-bg: linear-gradient(90deg, rgba(37,99,235,0.12), rgba(255,255,255,0.02));

    --ds-text: rgba(255,255,255,0.94);
    --ds-text-strong: #ffffff;
    --ds-text-muted: rgba(255,255,255,0.64);
    --ds-text-soft: rgba(255,255,255,0.50);
    --ds-text-inverse: #0f172a;

    --ds-border: rgba(255,255,255,0.07);
    --ds-border-strong: rgba(96,165,250,0.18);
    --ds-border-hover: rgba(96,165,250,0.34);

    --ds-primary: #60a5fa;
    --ds-primary-strong: #2563eb;
    --ds-primary-soft: rgba(37,99,235,0.16);
    --ds-danger: #ef4444;
    --ds-warning: #f59e0b;
    --ds-success: #22c55e;

    --ds-shadow: 0 18px 45px rgba(0,0,0,0.38);
    --ds-shadow-soft: 0 8px 32px rgba(0,0,0,0.35);
    --ds-glass-blur: blur(18px);

    color-scheme: dark;
}

body[data-theme="light"],
body.theme-light {
    --ds-bg-0: #f8fafc;
    --ds-bg-1: #f1f5f9;
    --ds-bg-2: #e2e8f0;
    --ds-bg-3: #cbd5e1;

    --ds-surface-0: rgba(255, 255, 255, 0.76);
    --ds-surface-1: rgba(255, 255, 255, 0.88);
    --ds-surface-2: rgba(248, 250, 252, 0.88);
    --ds-surface-3: rgba(241, 245, 249, 0.92);


    --ds-card-backgroud-30trans: rgba(255, 255, 255, 0.85);
    --ds-card-bg: rgba(255, 255, 255, 0.82);
    --ds-card-bg-hover: rgba(255, 255, 255, 0.94);
    --ds-panel-bg: rgba(248, 250, 252, 0.92);
    --ds-dialog-bg: rgba(255, 255, 255, 0.92);
    --ds-table-bg: rgba(255, 255, 255, 0.84);
    --ds-table-header-bg: linear-gradient(90deg, rgba(37,99,235,0.14) 0%, rgba(226,232,240,0.82) 100%);
    --ds-row-alt-bg: rgba(15,23,42,0.025);
    --ds-row-hover-bg: linear-gradient(90deg, rgba(37,99,235,0.10), rgba(255,255,255,0.60));

    --ds-text: rgba(15,23,42,0.92);
    --ds-text-strong: #020617;
    --ds-text-muted: rgba(51,65,85,0.76);
    --ds-text-soft: rgba(71,85,105,0.62);
    --ds-text-inverse: #ffffff;

    --ds-border: rgba(15,23,42,0.10);
    --ds-border-strong: rgba(37,99,235,0.22);
    --ds-border-hover: rgba(37,99,235,0.38);

    --ds-primary: #2563eb;
    --ds-primary-strong: #1d4ed8;
    --ds-primary-soft: rgba(37,99,235,0.12);
    --ds-danger: #dc2626;
    --ds-warning: #d97706;
    --ds-success: #15803d;

    --ds-shadow: 0 18px 45px rgba(15,23,42,0.14);
    --ds-shadow-soft: 0 8px 32px rgba(15,23,42,0.10);
    --ds-glass-blur: blur(14px);

    color-scheme: light;
}

[data-theme="dark"] .tprm-dock-icon {
    color: rgba(255,255,255,0.78);
}

[data-theme="dark"] .tprm-dock-item:hover .tprm-dock-icon {
    color: rgba(255,255,255,1);
}

[data-theme="light"] .tprm-dock-icon {
    color: rgba(0,0,0,0.70);
}

[data-theme="light"] .tprm-dock-item:hover .tprm-dock-icon {
    color: rgba(0,0,0,1);
}

/* ---------- Page backgrounds ---------- */
body[data-theme="dark"] .bg-tpms,
body.theme-dark .bg-tpms {
    background:
        radial-gradient(circle at 70% 20%, rgba(37,99,235,0.12), transparent 40%),
        linear-gradient(135deg, #111827 0%, #020617 100%) !important;
}

body[data-theme="light"] .bg-tpms,
body.theme-light .bg-tpms,
body[data-theme="light"] .bg-default,
body.theme-light .bg-default,
body[data-theme="light"] .bg-analytics,
body.theme-light .bg-analytics {
    background:
        radial-gradient(circle at 70% 20%, rgba(37,99,235,0.10), transparent 42%),
        linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%) !important;
}

body[data-theme="dark"] .page,
body.theme-dark .page,
body[data-theme="dark"] .scroll-page,
body.theme-dark .scroll-page {
    color: var(--ds-text);
}

body[data-theme="light"] .page,
body.theme-light .page,
body[data-theme="light"] .scroll-page,
body.theme-light .scroll-page {
    color: var(--ds-text);
}

/* ---------- General typography ---------- */
body[data-theme] .mud-typography,
body.theme-dark .mud-typography,
body.theme-light .mud-typography,
body[data-theme] .page-title,
body.theme-dark .page-title,
body.theme-light .page-title,
body[data-theme] .chart-title,
body.theme-dark .chart-title,
body.theme-light .chart-title,
body[data-theme] .risk-label,
body.theme-dark .risk-label,
body.theme-light .risk-label {
    color: var(--ds-text) !important;
}

body[data-theme] .page-subtitle,
body.theme-dark .page-subtitle,
body.theme-light .page-subtitle,
body[data-theme] .dependency-subtitle,
body.theme-dark .dependency-subtitle,
body.theme-light .dependency-subtitle,
body[data-theme] .risk-description,
body.theme-dark .risk-description,
body.theme-light .risk-description,
body[data-theme] .chart-summary-row,
body.theme-dark .chart-summary-row,
body.theme-light .chart-summary-row,
body[data-theme] .supplier-card .mud-typography-caption,
body.theme-dark .supplier-card .mud-typography-caption,
body.theme-light .supplier-card .mud-typography-caption {
    color: var(--ds-text-muted) !important;
}

/* ---------- Core cards / glass surfaces ---------- */
body[data-theme] .dashboard-kpi,
body[data-theme] .tprm-table,
body[data-theme] .tprm-chart-card,
body[data-theme] .glass-form-card,
body[data-theme] .glass-paper,
body[data-theme] .value-chain-card,
body[data-theme] .customer-tile,
body[data-theme] .dashboard-card,
body[data-theme] .process-card,
body[data-theme] .treatment-card,
body[data-theme] .treatment-response-card,
body[data-theme] .attachment-row,
body.theme-dark .dashboard-kpi,
body.theme-dark .tprm-table,
body.theme-dark .tprm-chart-card,
body.theme-dark .glass-form-card,
body.theme-dark .glass-paper,
body.theme-dark .value-chain-card,
body.theme-dark .customer-tile,
body.theme-dark .dashboard-card,
body.theme-dark .process-card,
body.theme-dark .treatment-card,
body.theme-dark .treatment-response-card,
body.theme-dark .attachment-row,
body.theme-light .dashboard-kpi,
body.theme-light .tprm-table,
body.theme-light .tprm-chart-card,
body.theme-light .glass-form-card,
body.theme-light .glass-paper,
body.theme-light .value-chain-card,
body.theme-light .customer-tile,
body.theme-light .dashboard-card,
body.theme-light .process-card,
body.theme-light .treatment-card,
body.theme-light .treatment-response-card,
body.theme-light .attachment-row {
    background: var(--ds-card-bg) !important;
    color: var(--ds-text) !important;
    border-color: var(--ds-border) !important;
    box-shadow: var(--ds-shadow-soft);
    backdrop-filter: var(--ds-glass-blur);
    -webkit-backdrop-filter: var(--ds-glass-blur);
}

body[data-theme] .tprm-chart-card:hover,
body.theme-dark .tprm-chart-card:hover,
body.theme-light .tprm-chart-card:hover,
body[data-theme] .supplier-card:hover,
body.theme-dark .supplier-card:hover,
body.theme-light .supplier-card:hover {
    background: var(--ds-card-bg-hover) !important;
    border-color: var(--ds-border-hover) !important;
}

body[data-theme] .supplier-card,
body.theme-dark .supplier-card,
body.theme-light .supplier-card {
    background: linear-gradient(145deg, var(--ds-surface-2), var(--ds-surface-3)) !important;
    color: var(--ds-text) !important;
    border-color: var(--ds-border) !important;
    box-shadow: var(--ds-shadow-soft);
}

/* ---------- Tables ---------- */
body[data-theme] .tprm-table .mud-table-head,
body.theme-dark .tprm-table .mud-table-head,
body.theme-light .tprm-table .mud-table-head {
    background: var(--ds-table-header-bg) !important;
}

body[data-theme] .tprm-table .mud-table-head th,
body[data-theme] .tprm-table .mud-table-sort-label,
body.theme-dark .tprm-table .mud-table-head th,
body.theme-dark .tprm-table .mud-table-sort-label,
body.theme-light .tprm-table .mud-table-head th,
body.theme-light .tprm-table .mud-table-sort-label {
    color: var(--ds-text-strong) !important;
}

body[data-theme] .tprm-table .mud-table-body tr:nth-child(even),
body.theme-dark .tprm-table .mud-table-body tr:nth-child(even),
body.theme-light .tprm-table .mud-table-body tr:nth-child(even) {
    background: var(--ds-row-alt-bg) !important;
}

body[data-theme] .tprm-table .mud-table-body tr:hover,
body.theme-dark .tprm-table .mud-table-body tr:hover,
body.theme-light .tprm-table .mud-table-body tr:hover {
    background: var(--ds-row-hover-bg) !important;
}

body[data-theme] .tprm-table .mud-table-body td,
body.theme-dark .tprm-table .mud-table-body td,
body.theme-light .tprm-table .mud-table-body td {
    color: var(--ds-text) !important;
    border-bottom-color: var(--ds-border) !important;
}

body[data-theme] .tprm-table .mud-table-pagination,
body.theme-dark .tprm-table .mud-table-pagination,
body.theme-light .tprm-table .mud-table-pagination {
    background: var(--ds-surface-0) !important;
    color: var(--ds-text) !important;
    border-top-color: var(--ds-border) !important;
}

body[data-theme] .mud-table-cell,
body.theme-dark .mud-table-cell,
body.theme-light .mud-table-cell {
    color: var(--ds-text) !important;
}

/* ---------- Forms, inputs, selects ---------- */
body[data-theme] .mud-input,
body[data-theme] .mud-input-control,
body[data-theme] .mud-select,
body[data-theme] .mud-select-input,
body[data-theme] input,
body[data-theme] textarea,
body.theme-dark .mud-input,
body.theme-dark .mud-input-control,
body.theme-dark .mud-select,
body.theme-dark .mud-select-input,
body.theme-dark input,
body.theme-dark textarea,
body.theme-light .mud-input,
body.theme-light .mud-input-control,
body.theme-light .mud-select,
body.theme-light .mud-select-input,
body.theme-light input,
body.theme-light textarea {
    color: var(--ds-text) !important;
}

body[data-theme] .mud-input-label,
body.theme-dark .mud-input-label,
body.theme-light .mud-input-label {
    color: var(--ds-text-muted) !important;
}

body[data-theme] .mud-input-slot,
body.theme-dark .mud-input-slot,
body.theme-light .mud-input-slot,
body[data-theme] .tprm-search .mud-input-control,
body.theme-dark .tprm-search .mud-input-control,
body.theme-light .tprm-search .mud-input-control {
    background: var(--ds-surface-0) !important;
    border-color: var(--ds-border) !important;
    color: var(--ds-text) !important;
}

body[data-theme] .tprm-search input,
body.theme-dark .tprm-search input,
body.theme-light .tprm-search input {
    color: var(--ds-text) !important;
}

body[data-theme] .tprm-search .mud-input-adornment,
body.theme-dark .tprm-search .mud-input-adornment,
body.theme-light .tprm-search .mud-input-adornment {
    color: var(--ds-text-muted) !important;
}

/* ---------- Dialogs ---------- */
body[data-theme] .glass-dialog,
body.theme-dark .glass-dialog,
body.theme-light .glass-dialog {
    background: var(--ds-dialog-bg) !important;
    color: var(--ds-text) !important;
    border-color: var(--ds-border-strong) !important;
}

body[data-theme] .glass-dialog .mud-dialog-title,
body.theme-dark .glass-dialog .mud-dialog-title,
body.theme-light .glass-dialog .mud-dialog-title {
    color: var(--ds-text-strong) !important;
    background: linear-gradient(90deg, rgba(96,165,250,0.10), rgba(214,31,55,0.08)) !important;
    border-bottom-color: var(--ds-border) !important;
}

body[data-theme] .glass-dialog .mud-dialog-actions,
body.theme-dark .glass-dialog .mud-dialog-actions,
body.theme-light .glass-dialog .mud-dialog-actions {
    background: var(--ds-surface-0) !important;
    border-top-color: var(--ds-border) !important;
}

body[data-theme="light"] .glass-dialog-overlay,
body.theme-light .glass-dialog-overlay {
    background: rgba(15, 23, 42, 0.30) !important;
}

/* ---------- Navigation dock ---------- */
body[data-theme] .tprm-dock,
body.theme-dark .tprm-dock,
body.theme-light .tprm-dock {
    background: var(--ds-surface-0) !important;
    border-color: var(--ds-border) !important;
    box-shadow: var(--ds-shadow-soft);
}

body[data-theme] .tprm-dock-item,
body.theme-dark .tprm-dock-item,
body.theme-light .tprm-dock-item,
body[data-theme] .tprm-dock-item span,
body.theme-dark .tprm-dock-item span,
body.theme-light .tprm-dock-item span {
    color: var(--ds-text) !important;
}

/* ---------- Map / dependency UI ---------- */
body[data-theme] .dependency-map-page,
body.theme-dark .dependency-map-page,
body.theme-light .dependency-map-page,
body[data-theme] .map-view-switch,
body.theme-dark .map-view-switch,
body.theme-light .map-view-switch,
body[data-theme] .supplier-control-filterbar,
body.theme-dark .supplier-control-filterbar,
body.theme-light .supplier-control-filterbar,
body[data-theme] .dock-header,
body.theme-dark .dock-header,
body.theme-light .dock-header {
    background: var(--ds-panel-bg) !important;
    color: var(--ds-text) !important;
    border-color: var(--ds-border-strong) !important;
}

body[data-theme] .process-tree,
body.theme-dark .process-tree,
body.theme-light .process-tree {
    border-left-color: var(--ds-border-strong) !important;
}

body[data-theme] .process-node::before,
body.theme-dark .process-node::before,
body.theme-light .process-node::before {
    background: var(--ds-border-hover) !important;
}

body[data-theme] .control-treatment-panel,
body.theme-dark .control-treatment-panel,
body.theme-light .control-treatment-panel,
body[data-theme] .treatment-response-toggle,
body.theme-dark .treatment-response-toggle,
body.theme-light .treatment-response-toggle {
    background: var(--ds-surface-0) !important;
    color: var(--ds-text) !important;
    border-color: var(--ds-border) !important;
}

/* ---------- Buttons ---------- */
body[data-theme] .glass-add-button,
body.theme-dark .glass-add-button,
body.theme-light .glass-add-button {
    color: #ffffff !important;
    background: linear-gradient(135deg, rgba(37,99,235,0.90), rgba(29,78,216,0.82)) !important;
    border-color: var(--ds-border-strong) !important;
}

body[data-theme="light"] .mud-button-text,
body.theme-light .mud-button-text {
    color: var(--ds-primary) !important;
}

/* ---------- Icons ---------- */
body[data-theme] .node-header .mud-icon-root,
body[data-theme] .section-header .mud-icon-root,
body[data-theme] .chart-header-icon,
body.theme-dark .node-header .mud-icon-root,
body.theme-dark .section-header .mud-icon-root,
body.theme-dark .chart-header-icon,
body.theme-light .node-header .mud-icon-root,
body.theme-light .section-header .mud-icon-root,
body.theme-light .chart-header-icon {
    color: var(--ds-primary) !important;
}

body[data-theme] .mud-icon-button,
body.theme-dark .mud-icon-button,
body.theme-light .mud-icon-button {
    color: var(--ds-primary) !important;
}

/* ---------- Charts / summaries ---------- */
body[data-theme] .chart-summary,
body.theme-dark .chart-summary,
body.theme-light .chart-summary {
    border-top-color: var(--ds-border) !important;
}

body[data-theme] .chart-summary-row strong,
body.theme-dark .chart-summary-row strong,
body.theme-light .chart-summary-row strong {
    color: var(--ds-text-strong) !important;
}

body[data-theme] .tprm-chart-card .mud-chart-legend,
body[data-theme] .tprm-chart-card .mud-chart,
body.theme-dark .tprm-chart-card .mud-chart-legend,
body.theme-dark .tprm-chart-card .mud-chart,
body.theme-light .tprm-chart-card .mud-chart-legend,
body.theme-light .tprm-chart-card .mud-chart {
    color: var(--ds-text) !important;
}

/* ---------- Scrollbars ---------- */
body[data-theme] .vertical-scroll-only .mud-table-container,
body[data-theme] .unmapped-suppliers-sidepanel .supplier-row,
body.theme-dark .vertical-scroll-only .mud-table-container,
body.theme-dark .unmapped-suppliers-sidepanel .supplier-row,
body.theme-light .vertical-scroll-only .mud-table-container,
body.theme-light .unmapped-suppliers-sidepanel .supplier-row {
    scrollbar-width: thin;
    scrollbar-color: var(--ds-border-hover) transparent;
}

body[data-theme] .vertical-scroll-only .mud-table-container::-webkit-scrollbar,
body[data-theme] .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar,
body.theme-dark .vertical-scroll-only .mud-table-container::-webkit-scrollbar,
body.theme-dark .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar,
body.theme-light .vertical-scroll-only .mud-table-container::-webkit-scrollbar,
body.theme-light .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar {
    width: 8px;
}

body[data-theme] .vertical-scroll-only .mud-table-container::-webkit-scrollbar-track,
body[data-theme] .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar-track,
body.theme-dark .vertical-scroll-only .mud-table-container::-webkit-scrollbar-track,
body.theme-dark .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar-track,
body.theme-light .vertical-scroll-only .mud-table-container::-webkit-scrollbar-track,
body.theme-light .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar-track {
    background: transparent;
}

body[data-theme] .vertical-scroll-only .mud-table-container::-webkit-scrollbar-thumb,
body[data-theme] .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar-thumb,
body.theme-dark .vertical-scroll-only .mud-table-container::-webkit-scrollbar-thumb,
body.theme-dark .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar-thumb,
body.theme-light .vertical-scroll-only .mud-table-container::-webkit-scrollbar-thumb,
body.theme-light .unmapped-suppliers-sidepanel .supplier-row::-webkit-scrollbar-thumb {
    background: var(--ds-border-hover);
    border-radius: 20px;
}

/* ---------- Risk chips: light mode needs stronger contrast ---------- */
body[data-theme="light"] .risk-chip.unknown,
body.theme-light .risk-chip.unknown {
    background: rgba(100,116,139,0.15) !important;
    color: #334155 !important;
}

body[data-theme="light"] .risk-chip.low,
body.theme-light .risk-chip.low {
    background: rgba(34,197,94,0.16) !important;
    color: #166534 !important;
}

body[data-theme="light"] .risk-chip.medium,
body.theme-light .risk-chip.medium {
    background: rgba(234,179,8,0.18) !important;
    color: #854d0e !important;
}

body[data-theme="light"] .risk-chip.high,
body.theme-light .risk-chip.high {
    background: rgba(249,115,22,0.18) !important;
    color: #9a3412 !important;
}

body[data-theme="light"] .risk-chip.critical,
body.theme-light .risk-chip.critical {
    background: rgba(239,68,68,0.18) !important;
    color: #991b1b !important;
}

/* ---------- MudBlazor paper/popover defaults ---------- */
body[data-theme] .mud-paper,
body.theme-dark .mud-paper,
body.theme-light .mud-paper {
    color: var(--ds-text);
}

body[data-theme="light"] .mud-popover,
body.theme-light .mud-popover {
    background: rgba(255,255,255,0.96) !important;
    color: var(--ds-text) !important;
    border: 1px solid var(--ds-border) !important;
    overflow: hidden;
}

body[data-theme="dark"] .mud-popover,
body.theme-dark .mud-popover {
    background: rgba(15,23,42,0.96) !important;
    color: var(--ds-text) !important;
    border: 1px solid var(--ds-border) !important;
    overflow: hidden;
}

/* ---------- Utility helpers ---------- */
.theme-surface {
    background: var(--ds-card-bg) !important;
    color: var(--ds-text) !important;
    border: 1px solid var(--ds-border) !important;
}

.theme-text {
    color: var(--ds-text) !important;
}

.theme-muted {
    color: var(--ds-text-muted) !important;
}

/* =========================================================
   Partner Admin Workspace
   Neutral portal-wide styling for AP and TPRM administration.
   ========================================================= */

.admin-layout,
.admin-shell {
    height: 100vh;
    min-height: 0;
    overflow: hidden;
    color: var(--ds-text);
}

.admin-scroll {
    height: calc(100vh - 64px);
    height: calc(100dvh - 64px);
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 72px 18px 42px;
    scrollbar-gutter: stable;
}

.admin-hero,
.admin-panel,
.admin-empty,
.admin-dialog {
    background: var(--ds-card-bg) !important;
    color: var(--ds-text) !important;
    border: 1px solid var(--ds-border) !important;
    border-radius: 8px;
    box-shadow: var(--ds-shadow-soft);
    backdrop-filter: var(--ds-glass-blur);
    -webkit-backdrop-filter: var(--ds-glass-blur);
}

.admin-hero {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 18px;
    margin: 0 auto 14px;
    max-width: 1480px;
}

.admin-hero div:first-child,
.admin-panel-header div,
.admin-empty div {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.admin-hero span,
.admin-panel-header span,
.admin-empty span,
.admin-hero small,
.admin-panel-header small {
    color: var(--ds-text-muted);
    font-size: 0.72rem;
    line-height: 1.2;
}

.admin-hero strong,
.admin-panel-header strong,
.admin-empty strong {
    color: var(--ds-text-strong);
    font-size: 1.12rem;
    line-height: 1.18;
    font-weight: 800;
}

.admin-hero-state {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 11px;
    border-radius: 999px;
    color: var(--ds-primary);
    background: var(--ds-primary-soft);
    border: 1px solid var(--ds-border-strong);
    font-size: 0.7rem;
    font-weight: 800;
}

.admin-nav-container {
    max-width: 1480px;
    padding: 0 !important;
    margin-bottom: 14px;
}

.admin-nav-grid {
    align-items: stretch;
}

.admin-nav-card {
    height: 100%;
    min-height: 112px;
    display: grid;
    grid-template-rows: 1fr auto;
    place-items: center;
    gap: 8px;
    padding: 14px 10px;
    cursor: pointer;
    color: var(--ds-text) !important;
    background: var(--ds-surface-0) !important;
    border: 1px solid var(--ds-border) !important;
    border-radius: 8px;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.admin-nav-card:hover,
.admin-nav-card.is-active {
    transform: translateY(-2px);
    background: var(--ds-card-bg-hover) !important;
    border-color: var(--ds-border-hover) !important;
}

.admin-nav-card.is-active {
    box-shadow: inset 0 0 0 1px var(--ds-border-strong);
}

.admin-nav-icon {
    font-size: 42px !important;
    color: var(--ds-primary) !important;
}

.admin-nav-title {
    color: var(--ds-text) !important;
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1.15;
}

.admin-workspace {
    max-width: 1480px;
    min-height: 360px;
    margin: 0 auto;
}

.admin-section-title {
    margin: 0 0 10px !important;
    color: var(--ds-text-strong) !important;
    font-size: 0.82rem !important;
    font-weight: 800 !important;
    text-transform: uppercase;
}

.admin-page {
    width: 100%;
    min-height: 0;
    background: transparent !important;
    color: var(--ds-text) !important;
    overflow: visible;
}

.admin-panel {
    width: 100%;
    min-width: 0;
    padding: 14px;
    overflow: hidden;
}

.admin-panel-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.admin-panel-header .mud-icon-root,
.admin-dialog-title .mud-icon-root,
.admin-customer-icon {
    color: var(--ds-primary) !important;
}

.admin-toolbar,
.admin-action-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 14px;
}

.admin-search {
    flex: 1 1 280px;
    min-width: 220px;
}

.admin-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(260px, 1fr));
    gap: 12px 16px;
}

.admin-form-grid .mud-input-control,
.admin-dialog-form .mud-input-control,
.admin-scan-form .mud-input-control {
    margin-top: 0;
}

.admin-form-grid .mud-checkbox,
.admin-form-actions {
    grid-column: 1 / -1;
}

.admin-form-actions {
    display: flex;
    justify-content: flex-end;
}

.admin-customer-grid {
    margin-top: 0 !important;
}

.admin-customer-card {
    height: 100%;
    min-height: 150px;
    padding: 14px;
    cursor: pointer;
    color: var(--ds-text) !important;
    background: var(--ds-surface-0) !important;
    border: 1px solid var(--ds-border) !important;
    border-radius: 8px;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.admin-customer-card:hover {
    transform: translateY(-2px);
    background: var(--ds-card-bg-hover) !important;
    border-color: var(--ds-border-hover) !important;
}

.admin-customer-content {
    height: 100%;
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 10px;
}

.admin-customer-name {
    color: var(--ds-text-strong) !important;
    font-weight: 800 !important;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.admin-customer-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.admin-table,
.admin-page .mud-data-grid,
.admin-page .mud-table {
    width: 100%;
    background: transparent !important;
    color: var(--ds-text) !important;
    border: 1px solid var(--ds-border) !important;
    border-radius: 8px;
    overflow: hidden;
}

.admin-table .mud-table-head,
.admin-page .mud-data-grid .mud-table-head,
.admin-page .mud-table .mud-table-head {
    background: var(--ds-table-header-bg) !important;
}

.admin-table .mud-table-cell,
.admin-page .mud-data-grid .mud-table-cell,
.admin-page .mud-table .mud-table-cell {
    color: var(--ds-text) !important;
    border-bottom-color: var(--ds-border) !important;
}

.admin-table .mud-table-row:hover,
.admin-page .mud-data-grid .mud-table-row:hover,
.admin-page .mud-table .mud-table-row:hover {
    background: var(--ds-row-hover-bg) !important;
}

.admin-table .mud-table-pagination,
.admin-page .mud-data-grid .mud-table-pagination,
.admin-page .mud-table .mud-table-pagination {
    width: 100%;
    justify-content: flex-end;
    background: var(--ds-surface-0) !important;
    color: var(--ds-text) !important;
    border-top: 1px solid var(--ds-border) !important;
}

.admin-empty {
    min-height: 280px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 12px;
    text-align: center;
    padding: 34px;
}

.admin-empty-icon {
    font-size: 56px !important;
    color: var(--ds-primary) !important;
}

.admin-selftest-panel {
    max-width: 780px;
}

.admin-test-status {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px;
    background: var(--ds-surface-0);
    border: 1px solid var(--ds-border);
    border-radius: 8px;
}

.admin-test-status span {
    color: var(--ds-text-muted);
    font-size: 0.75rem;
}

.admin-test-status strong {
    color: var(--ds-text-strong);
    font-size: 0.9rem;
}

.admin-scan-panel {
    min-height: 550px;
}

.admin-scan-form {
    width: min(980px, 100%);
    display: grid;
    gap: 12px;
}

.admin-radio-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.admin-error-line {
    margin-bottom: 12px;
    padding: 10px 12px;
    text-align: center;
    color: var(--ds-danger);
    background: rgba(239,68,68,0.10);
    border: 1px solid rgba(239,68,68,0.24);
    border-radius: 8px;
    font-size: 0.78rem;
}

.admin-divider {
    margin: 12px 0 14px !important;
    border-color: var(--ds-border) !important;
}

.admin-dialog {
    color: var(--ds-text) !important;
}

.admin-dialog-wide {
    width: min(900px, calc(100vw - 32px)) !important;
}

.admin-dialog-md {
    width: min(680px, calc(100vw - 32px)) !important;
}

.admin-dialog-title {
    display: flex;
    align-items: center;
    gap: 9px;
}

.admin-dialog-form,
.admin-dialog-stack {
    display: grid;
    gap: 12px;
}

.admin-dialog-overlay {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    background: rgba(2, 6, 23, 0.42) !important;
}

body[data-theme="light"] .admin-dialog-overlay,
body.theme-light .admin-dialog-overlay {
    background: rgba(15, 23, 42, 0.22) !important;
}

.admin-success-text {
    color: var(--ds-success);
    font-weight: 800;
}

.admin-spacer {
    height: 2px;
}

@media (max-width: 900px) {
    .admin-scroll {
        padding: 72px 10px 32px;
    }

    .admin-hero,
    .admin-panel-header {
        flex-direction: column;
        align-items: stretch;
    }

    .admin-form-grid {
        grid-template-columns: 1fr;
    }
}
