@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&display=swap");

:root {
    --dash-ink: #1c1033;
    --dash-muted: #6a5a8a;
    --dash-accent: #ffb703;
    --dash-surface: #ffffff;
    --dash-surface-alt: #f4f0ff;
    --dash-glow: rgba(108, 91, 231, 0.25);
}

.dash-shell {
    position: relative;
    padding: 8px 6px 24px;
    font-family: "Space Grotesk", "Segoe UI", sans-serif;
}

.dash-shell::before {
    content: "";
    position: absolute;
    inset: -20px -20px auto -20px;
    height: 220px;
    background: radial-gradient(1200px 240px at 20% -20%, rgba(108, 91, 231, 0.35), transparent 60%),
                radial-gradient(900px 220px at 80% -30%, rgba(255, 183, 3, 0.22), transparent 70%);
    z-index: 0;
    pointer-events: none;
}

.dash-hero {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    padding: 18px 20px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(244, 240, 255, 0.9));
    box-shadow: 0 18px 40px rgba(47, 13, 73, 0.12);
    backdrop-filter: blur(6px);
}

.dash-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--dash-muted);
    font-weight: 700;
}

.dash-title {
    font-size: 1.6rem;
    margin: 6px 0 4px;
    color: var(--dash-ink);
    font-weight: 700;
}

.dash-subtitle {
    color: var(--dash-muted);
    margin: 0;
    font-size: 0.95rem;
}

.dash-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.dash-pill {
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(108, 91, 231, 0.1);
    color: var(--dash-ink);
    font-weight: 600;
    border: 1px solid rgba(108, 91, 231, 0.25);
}

.dash-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

.stat-card {
    position: relative;
    background: var(--dash-surface);
    border-radius: 18px;
    padding: 18px 18px 16px;
    box-shadow: 0 14px 28px rgba(26, 12, 55, 0.1);
    border: 1px solid rgba(108, 91, 231, 0.12);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-card::after {
    content: "";
    position: absolute;
    inset: auto -40% -40% auto;
    width: 140px;
    height: 140px;
    background: radial-gradient(circle, rgba(108, 91, 231, 0.25), transparent 70%);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 38px rgba(26, 12, 55, 0.18);
}

.stat-card-rich {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.dash-card-top {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.stat-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    font-size: 1.1rem;
    box-shadow: 0 10px 18px var(--dash-glow);
}

.stat-label {
    margin-top: 12px;
    font-size: 0.9rem;
    color: var(--dash-muted);
}

.stat-value {
    margin-top: 4px;
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--dash-ink);
}

.dash-card-meta {
    position: relative;
    z-index: 1;
    margin-top: 6px;
    color: var(--dash-muted);
    font-size: 0.88rem;
    line-height: 1.45;
}

.dash-chip {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    white-space: nowrap;
    border: 1px solid transparent;
}

.dash-chip-success {
    background: rgba(35, 181, 116, 0.14);
    color: #12724a;
    border-color: rgba(35, 181, 116, 0.18);
}

.dash-chip-warning {
    background: rgba(255, 183, 3, 0.18);
    color: #9a5f00;
    border-color: rgba(255, 183, 3, 0.26);
}

.dash-chip-danger {
    background: rgba(239, 71, 111, 0.14);
    color: #b42347;
    border-color: rgba(239, 71, 111, 0.18);
}

.dash-chip-soft {
    background: rgba(108, 91, 231, 0.12);
    color: var(--dash-ink);
    border-color: rgba(108, 91, 231, 0.16);
}

.dash-section {
    margin-top: 18px;
}

.dash-panel {
    background: var(--dash-surface);
    border-radius: 18px;
    padding: 18px;
    box-shadow: 0 12px 26px rgba(26, 12, 55, 0.12);
    border: 1px solid rgba(108, 91, 231, 0.12);
}

.dash-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}

.dash-panel-title {
    font-weight: 700;
    color: var(--dash-ink);
    margin: 0;
}

.dash-panel-subtitle {
    margin: 4px 0 0;
    color: var(--dash-muted);
    font-size: 0.9rem;
}

.dash-branch {
    margin-bottom: 20px;
}

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

.dash-branch-header p {
    margin: 4px 0 0;
    color: var(--dash-muted);
    font-size: 0.92rem;
}

.dash-branch h5 {
    font-weight: 700;
    color: var(--dash-ink);
    margin: 0;
}

.dash-branch-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 14px;
}

.dash-scroll-area {
    position: relative;
    z-index: 1;
    margin-top: 14px;
    padding-right: 6px;
    max-height: 270px;
    overflow: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(108, 91, 231, 0.55) rgba(108, 91, 231, 0.08);
}

.dash-scroll-area-panel {
    max-height: 420px;
}

.dash-scroll-area::-webkit-scrollbar {
    width: 9px;
}

.dash-scroll-area::-webkit-scrollbar-track {
    background: rgba(108, 91, 231, 0.08);
    border-radius: 999px;
}

.dash-scroll-area::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(108, 91, 231, 0.75), rgba(255, 183, 3, 0.75));
    border-radius: 999px;
    border: 2px solid rgba(255, 255, 255, 0.65);
}

.dash-scroll-area::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(108, 91, 231, 0.95), rgba(255, 183, 3, 0.95));
}

.dash-mini-list {
    display: grid;
    gap: 10px;
}

.dash-mini-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    background: linear-gradient(135deg, rgba(244, 240, 255, 0.86), rgba(255, 255, 255, 0.95));
    border: 1px solid rgba(108, 91, 231, 0.1);
    border-radius: 14px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.dash-mini-main,
.dash-mini-side {
    display: grid;
    gap: 2px;
}

.dash-mini-main strong,
.dash-mini-side strong {
    color: var(--dash-ink);
    font-size: 0.95rem;
}

.dash-mini-main span,
.dash-mini-side span {
    color: var(--dash-muted);
    font-size: 0.82rem;
    line-height: 1.35;
}

.dash-mini-side {
    justify-items: end;
    text-align: right;
    flex-shrink: 0;
}

.dash-empty {
    padding: 18px 16px;
    border-radius: 14px;
    border: 1px dashed rgba(108, 91, 231, 0.24);
    background: rgba(244, 240, 255, 0.55);
    color: var(--dash-muted);
    text-align: center;
    font-size: 0.9rem;
}

.dash-status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    white-space: nowrap;
}

.status-success {
    background: rgba(35, 181, 116, 0.14);
    color: #12724a;
}

.status-warning {
    background: rgba(255, 183, 3, 0.18);
    color: #9a5f00;
}

.status-danger {
    background: rgba(239, 71, 111, 0.14);
    color: #b42347;
}

.dash-pill-soft {
    background: rgba(255, 255, 255, 0.78);
    border-color: rgba(108, 91, 231, 0.16);
}

.dash-list {
    display: grid;
    gap: 12px;
}

.dash-list-item {
    background: var(--dash-surface-alt);
    border-radius: 14px;
    padding: 14px 16px;
    border: 1px solid rgba(108, 91, 231, 0.12);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.dash-list-item h6 {
    margin: 0 0 6px;
    font-weight: 700;
    color: var(--dash-ink);
}

.dash-list-item p {
    margin: 0;
    color: var(--dash-muted);
    font-size: 0.9rem;
}

.dash-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(255, 183, 3, 0.18);
    color: #9a5f00;
    font-weight: 700;
    font-size: 0.75rem;
}

.dash-fade-in {
    animation: dashFadeUp 0.45s ease both;
}

@keyframes dashFadeUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .dash-hero {
        flex-direction: column;
        align-items: flex-start;
    }

    .dash-grid,
    .dash-branch-grid {
        grid-template-columns: 1fr;
    }

    .dash-branch-header,
    .dash-panel-header,
    .dash-card-top,
    .dash-mini-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .dash-mini-side {
        justify-items: start;
        text-align: left;
    }

    .dash-scroll-area {
        max-height: 240px;
    }
}
