/* Sevendyne custom dialogs — replaces alert / confirm / prompt */
body.sv-dialog-open {
    overflow: hidden;
}

#sv-dialog-root {
    position: relative;
    z-index: 20000;
}

.sv-dialog-overlay {
    position: fixed;
    inset: 0;
    background: rgba(7, 24, 38, 0.62);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    animation: sv-dialog-fade 0.2s ease;
}

@keyframes sv-dialog-fade {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes sv-dialog-rise {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.sv-dialog {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 24px 64px rgba(7, 24, 38, 0.28);
    max-width: 28rem;
    width: 100%;
    padding: 1.75rem 1.75rem 1.5rem;
    animation: sv-dialog-rise 0.25s ease;
    text-align: center;
}

.sv-dialog--wide {
    max-width: 32rem;
    text-align: left;
}

.sv-dialog__icon {
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    font-weight: 700;
}

.sv-dialog__icon--info {
    background: rgba(21, 130, 189, 0.12);
    color: #0c5a8c;
}

.sv-dialog__icon--info::before { content: 'i'; }

.sv-dialog__icon--success {
    background: rgba(16, 185, 129, 0.12);
    color: #047857;
}

.sv-dialog__icon--success::before { content: '✓'; }

.sv-dialog__icon--error {
    background: rgba(239, 68, 68, 0.12);
    color: #b91c1c;
}

.sv-dialog__icon--error::before { content: '!'; }

.sv-dialog__icon--confirm {
    background: rgba(245, 158, 11, 0.14);
    color: #b45309;
}

.sv-dialog__icon--confirm::before { content: '?'; }

.sv-dialog__spinner {
    width: 2.75rem;
    height: 2.75rem;
    border: 3px solid #e2e8f0;
    border-top-color: #1582bd;
    border-radius: 50%;
    margin: 0 auto 1.25rem;
    animation: sv-dialog-spin 0.75s linear infinite;
}

@keyframes sv-dialog-spin {
    to { transform: rotate(360deg); }
}

.sv-dialog__title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 0.65rem;
    line-height: 1.3;
}

.sv-dialog__body {
    font-size: 0.95rem;
    color: #475569;
    line-height: 1.55;
    margin: 0 0 1.25rem;
}

.sv-dialog__body--center {
    text-align: center;
}

.sv-dialog__input {
    width: 100%;
    margin-bottom: 1.25rem;
    padding: 0.65rem 0.85rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
}

.sv-dialog__input:focus {
    outline: 2px solid rgba(21, 130, 189, 0.35);
    border-color: #1582bd;
}

.sv-dialog__input--area {
    min-height: 6rem;
    resize: vertical;
    line-height: 1.45;
}

.sv-dialog__actions {
    display: flex;
    gap: 0.65rem;
    justify-content: center;
    flex-wrap: wrap;
}

.sv-dialog--wide .sv-dialog__actions {
    justify-content: flex-end;
}

.sv-dialog__btn {
    border: none;
    border-radius: 8px;
    padding: 0.65rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s ease, transform 0.15s ease;
}

.sv-dialog__btn:active {
    transform: scale(0.98);
}

.sv-dialog__btn--primary {
    background: linear-gradient(135deg, #1582bd 0%, #0c5a8c 100%);
    color: #fff;
}

.sv-dialog__btn--primary:hover {
    filter: brightness(1.05);
}

.sv-dialog__btn--secondary {
    background: #f1f5f9;
    color: #334155;
}

.sv-dialog__btn--secondary:hover {
    background: #e2e8f0;
}

.sv-dialog__btn--danger {
    background: #dc2626;
    color: #fff;
}

.sv-dialog__btn--danger:hover {
    background: #b91c1c;
}
