.app-dialog-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    z-index: 1060;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.app-dialog-backdrop.show {
    opacity: 1;
}

.app-dialog {
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
    max-width: 420px;
    width: 100%;
    overflow: hidden;
    transform: scale(0.95);
    transition: transform 0.2s ease;
}

.app-dialog-backdrop.show .app-dialog {
    transform: scale(1);
}

.app-dialog-header {
    padding: 1.25rem 1.25rem 0.5rem;
    text-align: center;
}

.app-dialog-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    margin-bottom: 0.75rem;
}

.app-dialog-icon.info { background: #dbeafe; color: #2563eb; }
.app-dialog-icon.success { background: #d1fae5; color: #059669; }
.app-dialog-icon.warning { background: #fef3c7; color: #d97706; }
.app-dialog-icon.error { background: #fee2e2; color: #dc2626; }
.app-dialog-icon.confirm { background: #ede9fe; color: #7c3aed; }

.app-dialog-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #111827;
    margin: 0 0 0.35rem;
}

.app-dialog-message {
    color: #4b5563;
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0;
    white-space: pre-line;
}

.app-dialog-body {
    padding: 0 1.25rem 1rem;
    text-align: center;
}

.app-dialog-footer {
    display: flex;
    gap: 0.65rem;
    padding: 0.75rem 1.25rem 1.25rem;
    justify-content: center;
}

.app-dialog-footer .app-dialog-btn {
    min-width: 110px;
    border: none;
    border-radius: 8px;
    padding: 0.55rem 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: filter 0.15s ease;
}

.app-dialog-footer .app-dialog-btn:hover {
    filter: brightness(0.95);
}

.app-dialog-btn-primary {
    background: #2563eb;
    color: #fff;
}

.app-dialog-btn-danger {
    background: #dc2626;
    color: #fff;
}

.app-dialog-btn-secondary {
    background: #e5e7eb;
    color: #374151;
}

.app-dialog-backdrop:not(.show){visibility:hidden;pointer-events:none;}
.app-dialog-backdrop.show{visibility:visible;pointer-events:auto;}
.app-dialog{max-height:calc(100dvh - 2rem);overflow-y:auto;}
.app-dialog-footer{flex-wrap:wrap;}
