/* ========================================
   Modals (from source.css)
   ======================================== */

.modal {
    z-index: 1055;
}

.modal-dialog {
    margin: 1.75rem auto;
    max-width: 500px;
}

.modal-dialog-centered {
    display: flex;
    align-items: center;
    min-height: calc(100% - 3.5rem);
}

.modal-content {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15), 0 4px 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.modal-header {
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-title {
    font-size: 18px;
    font-weight: 600;
    color: #111827;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;

    i {
        font-size: 18px;
        color: #2563eb;
    }
}

.modal-header .btn-close {
    opacity: 0.6;
}

.modal-header .btn-close:hover {
    opacity: 1;
}

.modal-body {
    padding: 24px;
    background: #ffffff;
}

.modal-footer {
    background: #f9fafb;
    border-top: 1px solid #e5e7eb;
    padding: 16px 20px;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.modal-footer .btn {
    min-width: 100px;
    height: 36px;
    padding: 0 16px;
    font-size: 13px;
    font-weight: 500;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background-color 0.15s ease, border-color 0.15s ease;
}

.modal-footer .btn-secondary {
    background: #ffffff;
    border: 1px solid #d1d5db;
    color: #374151;
}

.modal-footer .btn-secondary:hover {
    background: #f3f4f6;
    border-color: #9ca3af;
}

.modal-footer .btn-primary {
    background: #2563eb !important;
    border: 1px solid #2563eb !important;
    color: #ffffff !important;
}

.modal-footer .btn-primary:hover {
    background: #1d4ed8 !important;
    border-color: #1d4ed8 !important;
}

.modal-footer .btn-primary i,
.modal-footer .btn-primary .fa,
.modal-footer .btn-primary .fas {
    color: #ffffff !important;
}

.modal-body .form-control {
    height: 40px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 14px;
    padding: 0 12px;
}

.modal-body .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.modal-body .form-label {
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 8px;
}

.modal-body .form-label .text-danger {
    color: #dc2626;
}

.modal-body .form-text {
    font-size: 12px;
    color: #6b7280;
    margin-top: 8px;
}

.modal-body .progress {
    height: 4px;
    border-radius: 2px;
    background: #e5e7eb;
}

.modal-body .progress-bar {
    background: #2563eb;
    border-radius: 2px;
}

.modal-body .alert {
    font-size: 13px;
    padding: 12px 16px;
    border-radius: 6px;
    margin-top: 16px;
    margin-bottom: 0;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    border-left: 3px solid;

    i {
        font-size: 14px;
        margin-top: 2px;
        flex-shrink: 0;
    }

    code {
        background: rgba(0, 0, 0, 0.05);
        padding: 2px 6px;
        border-radius: 3px;
        font-size: 12px;
        font-family: var(--font-family-mono, monospace);
    }
}

.modal-body .alert-info {
    background: #eff6ff;
    border-color: #3b82f6;
    color: #1e40af;
    border-left-color: #3b82f6;

    i {
        color: #3b82f6;
    }
}

.modal-body .alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
}

.modal-body .alert-danger {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}
