/* ============================================================================
   NgModal — stili della modale riutilizzabile
   ========================================================================== */

.ng-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(2px);
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

.ng-modal {
    width: min(92vw, 480px);
    max-height: 85vh;
    overflow-y: auto;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 24px 60px -12px rgba(15, 23, 42, 0.35);
    padding: 1.5rem 1.6rem 1.4rem;
    animation: ngModalIn 0.18s ease;
}

@keyframes ngModalIn {
    from { opacity: 0; transform: translateY(14px) scale(0.98); }
    to   { opacity: 1; transform: none; }
}

.ng-modal-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 0.6rem;
    letter-spacing: -0.01em;
}

.ng-modal-body {
    font-size: 0.95rem;
    line-height: 1.55;
    color: #334155;
    white-space: pre-line;
}

.ng-modal-body.danger { color: #b91c1c; }

.ng-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.6rem;
    margin-top: 1.2rem;
    flex-wrap: wrap;
}

.ng-modal-btn {
    border: 1.5px solid transparent;
    border-radius: 10px;
    padding: 0.55rem 1.2rem;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    transition: all 0.15s ease;
    font-family: inherit;
}

.ng-modal-btn.primary   { background: #2563eb; color: #fff; }
.ng-modal-btn.primary:hover   { background: #1d4ed8; }

.ng-modal-btn.danger    { background: #dc2626; color: #fff; }
.ng-modal-btn.danger:hover    { background: #b91c1c; }

.ng-modal-btn.secondary { background: #fff; color: #334155; border-color: #cbd5e1; }
.ng-modal-btn.secondary:hover { background: #f1f5f9; }

@media (max-width: 480px) {
    .ng-modal-actions { justify-content: stretch; }
    .ng-modal-btn { flex: 1; }
}