/* ========================================
   Modal de Progreso del Proceso SRI
   ======================================== */

.sri-process-modal .swal2-popup {
    width: 600px;
    max-width: 90%;
}

.sri-process-steps {
    margin: 20px 0;
    padding: 0;
}

.sri-step {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    margin-bottom: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #dee2e6;
    transition: all 0.3s ease;
}

.sri-step.active {
    background: #fff3cd;
    border-left-color: #ffc107;
    box-shadow: 0 2px 8px rgba(255, 193, 7, 0.2);
}

.sri-step.completed {
    background: #d1e7dd;
    border-left-color: #198754;
}

.sri-step.error {
    background: #f8d7da;
    border-left-color: #dc3545;
}

.sri-step-icon {
    font-size: 24px;
    margin-right: 15px;
    min-width: 30px;
    text-align: center;
}

.sri-step-content {
    flex: 1;
}

.sri-step-title {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 2px;
    color: #333;
}

.sri-step-description {
    font-size: 12px;
    color: #6c757d;
    margin: 0;
}

.sri-step-status {
    font-size: 20px;
    min-width: 30px;
    text-align: center;
}

/* Animación de spinner */
.sri-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0,0,0,.1);
    border-radius: 50%;
    border-top-color: #ffc107;
    animation: sri-spin 1s ease-in-out infinite;
}

@keyframes sri-spin {
    to { transform: rotate(360deg); }
}

/* Estados de los pasos */
.sri-step.pending .sri-step-status {
    color: #6c757d;
}

.sri-step.active .sri-step-status {
    color: #ffc107;
}

.sri-step.completed .sri-step-status {
    color: #198754;
}

.sri-step.error .sri-step-status {
    color: #dc3545;
}

/* Progress bar general */
.sri-progress-container {
    margin: 20px 0;
    background: #e9ecef;
    border-radius: 10px;
    height: 8px;
    overflow: hidden;
}

.sri-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #198754 0%, #20c997 100%);
    border-radius: 10px;
    transition: width 0.5s ease;
}

/* Resultado final */
.sri-result-summary {
    margin-top: 20px;
    padding: 15px;
    border-radius: 8px;
    background: #f8f9fa;
}

.sri-result-summary.success {
    background: #d1e7dd;
    border: 1px solid #198754;
}

.sri-result-summary.error {
    background: #f8d7da;
    border: 1px solid #dc3545;
}

/* ========================================
   Bulk Processing Modal for Invoices
   ======================================== */

.bulk-process-modal-invoices .swal2-popup {
    border-radius: 12px;
}

.bulk-modal-html {
    overflow: visible !important;
}

/* Dark terminal scrollbar for invoices */
#bulk-invoice-status::-webkit-scrollbar {
    width: 8px;
}

#bulk-invoice-status::-webkit-scrollbar-track {
    background: #2d2d2d;
}

#bulk-invoice-status::-webkit-scrollbar-thumb {
    background: #4a4a4a;
    border-radius: 4px;
}

#bulk-invoice-status::-webkit-scrollbar-thumb:hover {
    background: #5a5a5a;
}

/* Terminal log entry animation */
.invoice-process-item-terminal {
    animation: slideInTerminal 0.3s ease-out;
}

@keyframes slideInTerminal {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
