/* ============================================================
   Confirm Modal – Overlay-Bestätigungsdialog
   ============================================================ */

/* ── Backdrop ──────────────────────────────────────────────── */
#confirm-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 9000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(10, 20, 15, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.2s ease;
}

#confirm-modal-backdrop[hidden] {
    display: none;
}

#confirm-modal-backdrop.is-visible {
    opacity: 1;
}

/* ── Modal-Karte ───────────────────────────────────────────── */
.confirm-modal {
    width: min(440px, calc(100% - 2rem));
    padding: clamp(1.75rem, 5vw, 2.5rem);
    border: 1px solid var(--border, #dfe9e2);
    border-radius: 1.25rem;
    background: var(--surface, #ffffff);
    box-shadow:
        0 24px 60px rgba(10, 20, 15, 0.22),
        0 4px 16px rgba(10, 20, 15, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transform: translateY(10px) scale(0.98);
    transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
    opacity: 0;
}

#confirm-modal-backdrop.is-visible .confirm-modal {
    transform: translateY(0) scale(1);
    opacity: 1;
}

/* ── Icon ──────────────────────────────────────────────────── */
.confirm-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    margin-bottom: 1.1rem;
    border-radius: 0.85rem;
    background: rgba(169, 67, 60, 0.1);
    color: #a9433c;
    font-size: 1.3rem;
}

/* ── Titel ─────────────────────────────────────────────────── */
.confirm-modal-title {
    margin: 0 0 0.6rem;
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-heading, #20352d);
}

/* ── Nachrichtentext ───────────────────────────────────────── */
.confirm-modal-message {
    margin: 0 0 1.75rem;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-muted, #687571);
}

/* ── Aktionsbuttons ────────────────────────────────────────── */
.confirm-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.65rem;
}

.confirm-modal-cancel {
    color: var(--text-primary, #24312e);
    background: var(--surface-muted, #edf2ee);
    border: 1px solid var(--border, #dfe9e2);
}

.confirm-modal-cancel:hover {
    color: var(--text-heading, #20352d);
    background: #dde8e1;
    border-color: #ccdbd3;
    transform: none;
    box-shadow: none;
}

/* ── Dark-Mode ─────────────────────────────────────────────── */
:root[data-theme="dark"] #confirm-modal-backdrop {
    background: rgba(5, 10, 8, 0.7);
}

:root[data-theme="dark"] .confirm-modal {
    background: var(--surface, #1b2721);
    border-color: var(--border, #35453c);
    box-shadow:
        0 24px 60px rgba(0, 0, 0, 0.5),
        0 4px 16px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

:root[data-theme="dark"] .confirm-modal-icon {
    background: rgba(255, 110, 100, 0.12);
    color: #ff9d96;
}

:root[data-theme="dark"] .confirm-modal-cancel {
    color: var(--text-primary, #dbe5df);
    background: var(--surface-muted, #202f28);
    border-color: var(--border, #35453c);
}

:root[data-theme="dark"] .confirm-modal-cancel:hover {
    color: var(--text-heading, #eff5f1);
    background: #2a3b32;
    border-color: #50665a;
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 480px) {
    .confirm-modal-actions {
        flex-direction: column-reverse;
        gap: 0.5rem;
    }

    .confirm-modal-actions .btn {
        width: 100%;
        justify-content: center;
    }
}
