.app-confirm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    z-index: 10100;
}

.app-confirm-overlay.show {
    opacity: 1;
    visibility: visible;
}

.app-confirm-modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 550px;
    max-width: 94vw;
    background: #ffffff;
    border-radius: 18px;
    border-top: 2px solid var(--verde-principal);
    box-shadow: 0 5px 24px rgba(0, 0, 0, 0.13);
    z-index: 10101;
    flex-direction: column;
    overflow: hidden;
}

.app-confirm-modal.open {
    display: flex;
    animation: app-confirm-in 0.22s ease;
}

.app-confirm-modal.closing {
    animation: app-confirm-out 0.18s ease forwards;
}

@keyframes app-confirm-in {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.97) translateY(-12px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1) translateY(0);
    }
}

@keyframes app-confirm-out {
    from {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1) translateY(0);
    }
    to {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.97) translateY(-12px);
    }
}

.app-confirm-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 20px 14px;
    background: #fff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.app-confirm-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

.app-confirm-headline {
    margin: 0;
    font-family: var(--fontfamilyroboto);
    font-size: 16px;
    font-weight: 700;
    color: var(--verde-principal);
    border-left: 3px solid var(--verde-principal);
    padding-left: 10px;
    line-height: 1.3;
}

.app-confirm-body {
    padding: 22px 20px 0px;
    background: #ffffff;
    font-family: var(--fontfamilyroboto);
    font-size: 14px;
    color: var(--font-color);
    line-height: 1.6;
}

.app-confirm-body .app-confirm-description {
    margin: 0 !important;
    padding: 0 !important;
}

.app-confirm-warning {
    display: block;
    margin-top: 10px;
    color: var(--verde-principal);
    font-weight: 600;
    font-size: 13px;
}

.app-confirm-danger .app-confirm-warning {
    color: #c62828;
}

.app-confirm-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 20px 20px 16px;
    background: #ffffff;
}

/* Modo danger: borde superior y titular en rojo */
.app-confirm-modal.app-confirm-danger {
    border-top-color: #c62828;
}

.app-confirm-modal.app-confirm-danger .app-confirm-headline {
    color: #c62828;
    border-left-color: #c62828;
}
