.dashboard-module .ddm-dash-kpi {
    order: -165;
    width: 100%;
    max-width: none;
    box-sizing: border-box;
    margin: 0 0 18px;
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
}

.ddm-dash-kpi-card {
    appearance: none;
    border: 0;
    margin: 0;
    width: 100%;
    min-height: 88px;
    padding: 14px 16px 12px;
    border-radius: 12px;
    color: #fff;
    text-align: left;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 8px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.12);
    transition: transform 0.12s ease, filter 0.12s ease, box-shadow 0.12s ease;
}

.ddm-dash-kpi-card:hover,
.ddm-dash-kpi-card:focus-visible {
    transform: translateY(-1px);
    filter: brightness(1.06);
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.16);
    outline: none;
}

.ddm-dash-kpi-label {
    font-size: 12px;
    font-weight: 700;
    line-height: 1.25;
    opacity: 0.95;
}

.ddm-dash-kpi-n {
    font-size: 28px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.03em;
}

.ddm-dash-kpi-card.tone-blue { background: #2563eb; }
.ddm-dash-kpi-card.tone-amber { background: #f59e0b; }
.ddm-dash-kpi-card.tone-cyan { background: #06b6d4; }
.ddm-dash-kpi-card.tone-indigo { background: #1d4ed8; }
.ddm-dash-kpi-card.tone-green { background: #059669; }
.ddm-dash-kpi-card.tone-slate { background: #64748b; }
.ddm-dash-kpi-card.tone-slate.has-alert { background: #dc2626; }

.dashboard-module:has([data-ddm-dash-kpi]) [data-ddm-compiti-dashboard] {
    display: none !important;
}

@media (max-width: 1100px) {
    .dashboard-module .ddm-dash-kpi {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .dashboard-module .ddm-dash-kpi {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .ddm-dash-kpi-card {
        min-height: 78px;
        padding: 12px;
        border-radius: 10px;
    }

    .ddm-dash-kpi-n {
        font-size: 24px;
    }
}
