/* =========================================================
   SIMFAR DASHBOARD V4
   CSS KHUSUS DASHBOARD
   Sinkron dengan index.php
   ========================================================= */


/* =========================================================
   1. DASHBOARD WRAPPER
   ========================================================= */

.simfar-dashboard-v2 {
    width: 100%;
    max-width: 1440px;

    margin: 0 auto;

    padding: 20px 26px 24px;

    box-sizing: border-box;
}


/* =========================================================
   2. PAGE HEADER
   ========================================================= */

.simfar-page-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    gap: 20px;

    margin-bottom: 14px;
}

.simfar-page-head > div {
    min-width: 0;
}

.simfar-breadcrumb {
    display: flex;
    align-items: center;

    gap: 6px;

    margin-bottom: 5px;

    color: #78909c;

    font-size: 10px;
}

.simfar-breadcrumb span {
    color: #82949b;
}

.simfar-breadcrumb svg {
    width: 12px;
    height: 12px;

    color: #a5b2b7;
}

.simfar-breadcrumb strong {
    color: #24434b;

    font-weight: 700;
}

.simfar-page-head h1 {
    margin: 0 0 3px;

    color: #17333c;

    font-size: 24px;
    font-weight: 800;

    line-height: 1.15;
}

.simfar-page-head p {
    margin: 0;

    color: #74888f;

    font-size: 11px;

    line-height: 1.45;
}


/* =========================================================
   3. PRIMARY BUTTON
   ========================================================= */

.simfar-primary-btn {
    flex-shrink: 0;

    height: 38px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 6px;

    padding: 0 16px;

    border: 0;
    border-radius: 8px;

    background: #0875d1;

    color: #ffffff;

    font-size: 11px;
    font-weight: 700;

    cursor: pointer;

    box-shadow: 0 3px 8px rgba(8, 117, 209, .15);

    transition:
        background .15s ease,
        transform .15s ease,
        box-shadow .15s ease;
}

.simfar-primary-btn:hover {
    background: #0669bc;

    transform: translateY(-1px);

    box-shadow: 0 5px 12px rgba(8, 117, 209, .20);
}

.simfar-primary-btn svg {
    width: 15px;
    height: 15px;
}


/* =========================================================
   4. KPI GRID
   ========================================================= */

.simfar-kpi-grid {
    display: grid;

    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    gap: 12px;

    margin-bottom: 12px;
}


/* =========================================================
   5. KPI CARD
   ========================================================= */

.simfar-kpi-card {
    min-width: 0;
    min-height: 82px;

    display: flex;
    align-items: center;

    gap: 11px;

    padding: 13px 14px;

    box-sizing: border-box;

    background: #ffffff;

    border: 1px solid #e3e9ec;

    border-radius: 10px;

    box-shadow:
        0 2px 6px rgba(20, 50, 60, .035);
}

.simfar-kpi-icon {
    width: 38px;
    height: 38px;

    min-width: 38px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;
}

.simfar-kpi-icon svg {
    width: 18px;
    height: 18px;
}


/* =========================================================
   KPI ICON COLORS
   ========================================================= */

.simfar-kpi-icon.blue {
    background: #edf5ff;
    color: #0875d1;
}

.simfar-kpi-icon.green {
    background: #eaf9f3;
    color: #00a878;
}

.simfar-kpi-icon.amber {
    background: #fff7e5;
    color: #f59e0b;
}

.simfar-kpi-icon.red {
    background: #fff0f1;
    color: #ef4444;
}


/* =========================================================
   6. KPI CONTENT
   ========================================================= */

.simfar-kpi-content {
    min-width: 0;

    display: flex;
    flex-direction: column;
}

.simfar-kpi-content > span {
    color: #71858d;

    font-size: 10px;

    line-height: 1.2;

    margin-bottom: 2px;
}

.simfar-kpi-content > strong {
    color: #162f39;

    font-size: 21px;
    font-weight: 800;

    line-height: 1.05;
}

.simfar-kpi-content small {
    display: flex;
    align-items: center;

    gap: 3px;

    margin-top: 3px;

    font-size: 8px;
    font-weight: 600;

    line-height: 1.2;
}

.simfar-kpi-content small svg {
    width: 10px;
    height: 10px;
}

.simfar-kpi-content small.positive {
    color: #00a878;
}

.simfar-kpi-content small.warning-text {
    color: #f59e0b;
}

.simfar-kpi-content small.danger-text {
    color: #ef4444;
}


/* =========================================================
   7. MIDDLE GRID
   ========================================================= */

.simfar-middle-grid {
    display: grid;

    grid-template-columns:
        minmax(0, 2.35fr)
        minmax(280px, .95fr);

    gap: 12px;

    margin-bottom: 12px;

    align-items: stretch;
}


/* =========================================================
   8. GENERIC PANEL
   ========================================================= */

.simfar-panel {
    min-width: 0;

    background: #ffffff;

    border: 1px solid #e2e8eb;

    border-radius: 10px;

    box-shadow:
        0 2px 6px rgba(20, 50, 60, .035);

    overflow: hidden;
}


/* =========================================================
   9. PANEL HEADER
   ========================================================= */

.simfar-panel-head {
    min-height: 50px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 12px;

    padding: 9px 14px;

    box-sizing: border-box;

    border-bottom: 1px solid #e8edef;
}

.simfar-panel-head > div {
    min-width: 0;
}

.simfar-panel-head h2 {
    margin: 0 0 2px;

    color: #17333c;

    font-size: 13px;
    font-weight: 800;

    line-height: 1.2;
}

.simfar-panel-head p {
    margin: 0;

    color: #84969d;

    font-size: 8px;

    line-height: 1.3;
}


/* =========================================================
   10. MORE BUTTON
   ========================================================= */

.simfar-more-btn {
    width: 28px;
    height: 28px;

    flex-shrink: 0;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    border: 0;
    border-radius: 6px;

    background: transparent;

    color: #73878e;

    cursor: pointer;
}

.simfar-more-btn:hover {
    background: #f3f7f8;
}

.simfar-more-btn svg {
    width: 16px;
    height: 16px;
}


/* =========================================================
   11. STOCK PANEL
   ========================================================= */

.simfar-stock-panel {
    min-height: 248px;

    display: flex;
    flex-direction: column;
}

.simfar-chart-area {
    flex: 1;

    min-height: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 12px 18px;

    box-sizing: border-box;
}


/* =========================================================
   12. CHART PLACEHOLDER
   ========================================================= */

.simfar-chart-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;
}

.simfar-chart-icon {
    width: 38px;
    height: 38px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 7px;

    background: #edf5ff;

    color: #0875d1;

    border-radius: 9px;
}

.simfar-chart-icon svg {
    width: 19px;
    height: 19px;
}

.simfar-chart-placeholder strong {
    display: block;

    margin-bottom: 3px;

    color: #203d46;

    font-size: 10px;
    font-weight: 700;
}

.simfar-chart-placeholder span {
    color: #899aa0;

    font-size: 8px;

    line-height: 1.4;
}


/* =========================================================
   13. QUICK PANEL
   ========================================================= */

.simfar-quick-panel {
    min-height: 248px;

    display: flex;
    flex-direction: column;
}

.simfar-quick-list {
    flex: 1;

    display: flex;
    flex-direction: column;

    padding: 0 13px;
}


/* =========================================================
   14. QUICK ITEM
   ========================================================= */

.simfar-quick-item {
    min-height: 49px;

    display: flex;
    align-items: center;

    gap: 9px;

    border-bottom: 1px solid #e8edef;

    color: #17333c;

    text-decoration: none;

    transition:
        background .15s ease;
}

.simfar-quick-item:last-child {
    border-bottom: 0;
}

.simfar-quick-item:hover {
    background: #fafcfc;

    text-decoration: none;
}


/* =========================================================
   15. QUICK ICON
   ========================================================= */

.simfar-quick-icon {
    width: 31px;
    height: 31px;

    min-width: 31px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 8px;
}

.simfar-quick-icon svg {
    width: 15px;
    height: 15px;
}

.simfar-quick-icon.blue {
    background: #edf5ff;
    color: #0875d1;
}

.simfar-quick-icon.green {
    background: #eaf9f3;
    color: #00a878;
}

.simfar-quick-icon.purple {
    background: #f2edff;
    color: #7c5ce5;
}

.simfar-quick-icon.amber {
    background: #fff7e5;
    color: #f59e0b;
}


/* =========================================================
   16. QUICK COPY
   ========================================================= */

.simfar-quick-copy {
    flex: 1;

    min-width: 0;

    display: flex;
    flex-direction: column;

    gap: 1px;
}

.simfar-quick-copy strong {
    color: #1a3540;

    font-size: 10px;
    font-weight: 700;

    line-height: 1.25;
}

.simfar-quick-copy small {
    color: #82959c;

    font-size: 8px;

    line-height: 1.25;
}

.simfar-quick-item > svg {
    width: 14px;
    height: 14px;

    flex-shrink: 0;

    color: #9aabb0;
}


/* =========================================================
   17. BOTTOM GRID
   ========================================================= */

.simfar-bottom-grid {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 12px;
}


/* =========================================================
   18. BOTTOM PANEL
   ========================================================= */

.simfar-bottom-panel {
    min-height: 126px;

    display: flex;
    flex-direction: column;
}


/* =========================================================
   19. COMPACT PANEL HEADER
   ========================================================= */

.simfar-panel-head.compact {
    min-height: 48px;

    padding-top: 8px;
    padding-bottom: 8px;
}

.simfar-panel-head.compact a {
    flex-shrink: 0;

    color: #0875d1;

    font-size: 8px;
    font-weight: 700;

    text-decoration: none;
}

.simfar-panel-head.compact a:hover {
    text-decoration: underline;
}


/* =========================================================
   20. BOTTOM CONTENT
   ========================================================= */

.simfar-bottom-content {
    flex: 1;

    min-height: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 12px;

    box-sizing: border-box;
}


/* =========================================================
   21. EMPTY STATE
   ========================================================= */

.simfar-empty {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 7px;

    text-align: center;

    color: #8c9da3;
}

.simfar-empty svg {
    width: 17px;
    height: 17px;

    flex-shrink: 0;

    color: #a6b5ba;
}

.simfar-empty span {
    font-size: 8px;

    line-height: 1.4;
}


/* =========================================================
   22. DESKTOP OPTIMIZATION
   ========================================================= */

@media (min-width: 1200px) {

    .simfar-dashboard-v2 {
        padding-top: 18px;
        padding-bottom: 20px;
    }

    .simfar-page-head {
        margin-bottom: 12px;
    }

    .simfar-kpi-grid {
        gap: 11px;
        margin-bottom: 11px;
    }

    .simfar-middle-grid {
        gap: 11px;
        margin-bottom: 11px;
    }

    .simfar-bottom-grid {
        gap: 11px;
    }

    .simfar-stock-panel,
    .simfar-quick-panel {
        min-height: 238px;
    }

    .simfar-bottom-panel {
        min-height: 118px;
    }
}


/* =========================================================
   23. TABLET
   ========================================================= */

@media (max-width: 1100px) {

    .simfar-dashboard-v2 {
        padding-left: 18px;
        padding-right: 18px;
    }

    .simfar-kpi-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .simfar-middle-grid {
        grid-template-columns:
            minmax(0, 1.8fr)
            minmax(250px, 1fr);
    }
}


/* =========================================================
   24. MOBILE / SMALL TABLET
   ========================================================= */

@media (max-width: 800px) {

    .simfar-dashboard-v2 {
        padding: 16px 14px 22px;
    }

    .simfar-page-head {
        align-items: flex-start;

        flex-direction: column;

        gap: 12px;
    }

    .simfar-primary-btn {
        align-self: flex-start;
    }

    .simfar-middle-grid {
        grid-template-columns: 1fr;
    }

    .simfar-stock-panel,
    .simfar-quick-panel {
        min-height: 230px;
    }

    .simfar-bottom-grid {
        grid-template-columns: 1fr;
    }
}


/* =========================================================
   25. PHONE
   ========================================================= */

@media (max-width: 600px) {

    .simfar-dashboard-v2 {
        padding: 14px 12px 20px;
    }

    .simfar-kpi-grid {
        grid-template-columns: 1fr;
    }

    .simfar-page-head h1 {
        font-size: 21px;
    }

    .simfar-page-head p {
        font-size: 10px;
    }

    .simfar-primary-btn {
        width: 100%;

        align-self: stretch;
    }

    .simfar-stock-panel,
    .simfar-quick-panel {
        min-height: 220px;
    }

    .simfar-bottom-panel {
        min-height: 115px;
    }
}


/* =========================================================
   26. VERY SMALL PHONE
   ========================================================= */

@media (max-width: 400px) {

    .simfar-dashboard-v2 {
        padding-left: 10px;
        padding-right: 10px;
    }

    .simfar-kpi-card {
        padding: 12px;
    }

    .simfar-panel-head {
        padding-left: 12px;
        padding-right: 12px;
    }

    .simfar-quick-list {
        padding-left: 11px;
        padding-right: 11px;
    }
}