/* ESTILOS ADICIONALES PARA MÓDULO DE REPORTES DINÁMICOS */

/* Alertas personalizadas */
.alert-pink {
    color: #8e44ad;
    background-color: #f4ecf7;
    border-color: #d7bde2;
}

.alert-tips {
    color: #2c3e50;
    background-color: #e8f4f8;
    border-color: #aed6f1;
}

/* Contenedor de gráficos */
.chart-container {
    position: relative;
    margin: 20px 0;
    padding: 15px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 1px 1px rgba(0,0,0,0.05);
}

/* Tabla de reportes */
#tablaReportes {
    font-size: 14px;
    margin-bottom: 0;
}

#tablaReportes thead th {
    background-color: #f8f9fa;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #dee2e6;
    padding: 12px 8px;
    vertical-align: middle;
    white-space: nowrap;
    text-align: center;
}

#tablaReportes tbody td {
    padding: 10px 8px;
    vertical-align: middle;
    border-bottom: 1px solid #f1f1f1;
    text-align: center;
}

#tablaReportes tbody tr:hover {
    background-color: #f8f9fa;
    transition: background-color 0.2s ease;
}

#tablaReportes tbody tr:nth-child(even) {
    background-color: #fafafa;
}

#tablaReportes tbody tr:nth-child(even):hover {
    background-color: #f0f0f0;
}

/* Badges personalizados */
.badge {
    font-size: 11px;
    padding: 4px 8px;
    border-radius: 3px;
    font-weight: 500;
}

/* Estrellas de calificación */
.fa-star, .fa-star-o {
    font-size: 14px;
    margin-right: 2px;
}

.fa-star.text-warning {
    color: #f39c12 !important;
}

.fa-star-o.text-muted {
    color: #bdc3c7 !important;
}

/* Botones de acción */
.btn-lg {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 500;
    margin: 0 5px;
}

/* Panel de filtros */
.box.box-primary .box-header {
    background-color: #3c8dbc;
    color: #fff;
}

.box.box-info .box-header {
    background-color: #00c0ef;
    color: #fff;
}

.box.box-warning .box-header {
    background-color: #f39c12;
    color: #fff;
}

/* Formularios */
.form-group label {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 5px;
}

.form-control:focus {
    border-color: #3c8dbc;
    box-shadow: 0 0 0 0.2rem rgba(60, 141, 188, 0.25);
}

/* Checkbox personalizado */
.checkbox input[type="checkbox"] {
    margin-right: 8px;
}

.checkbox label {
    cursor: pointer;
    font-weight: 400;
    margin-bottom: 0;
}

/* Modal de carga */
.modal-body {
    padding: 30px;
}

.modal-body h4 {
    margin-top: 20px;
    margin-bottom: 10px;
    color: #3c8dbc;
}

.modal-body p {
    color: #666;
    margin-bottom: 20px;
}

.progress {
    height: 8px;
    margin-bottom: 0;
}

.progress-bar {
    background-color: #3c8dbc;
}

/* Animaciones */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#panelResultados {
    animation: fadeInUp 0.5s ease;
}

/* Responsive */
@media (max-width: 768px) {
    .btn-lg {
        padding: 10px 16px;
        font-size: 14px;
        margin: 2px;
    }
    
    .form-group {
        margin-bottom: 15px;
    }
    
    #tablaReportes {
        font-size: 12px;
    }
    
    #tablaReportes thead th,
    #tablaReportes tbody td {
        padding: 8px 4px;
    }
    
    .chart-container {
        height: 300px !important;
    }
}

@media (max-width: 480px) {
    .btn-lg {
        display: block;
        width: 100%;
        margin: 5px 0;
    }
    
    .box-tools {
        display: none;
    }
    
    #tablaReportes {
        font-size: 11px;
    }
}

/* Tooltip personalizado */
.tooltip-inner {
    background-color: #2c3e50;
    color: #fff;
    border-radius: 4px;
    padding: 8px 12px;
    font-size: 12px;
}

.tooltip-arrow {
    border-top-color: #2c3e50;
}

/* Loading spinner */
.fa-spinner.fa-spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Estados de carga */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Table responsive mejorado */
.table-responsive {
    border-radius: 4px;
    overflow: hidden;
}

/* Scroll personalizado */
.table-responsive::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.table-responsive::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.table-responsive::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.table-responsive::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Mejoras visuales para badges en tabla */
#tablaReportes .badge {
    display: inline-block;
    min-width: 60px;
    text-align: center;
}

/* Colores personalizados para diferentes tipos de datos */
.text-currency {
    color: #27ae60;
    font-weight: 600;
}

.text-date {
    color: #8e44ad;
    font-family: 'Courier New', monospace;
}

.text-status-active {
    color: #27ae60;
}

.text-status-pending {
    color: #f39c12;
}

.text-status-inactive {
    color: #e74c3c;
}

/* Efectos hover para botones */
.btn:hover {
    transform: translateY(-1px);
    transition: all 0.2s ease;
}

.btn:active {
    transform: translateY(0);
}

/* Mejoras para el panel de ayuda */
.alert ul {
    margin-bottom: 0;
}

.alert ul li {
    margin-bottom: 8px;
    line-height: 1.5;
}

.alert h4 {
    margin-bottom: 15px;
    border-bottom: 1px solid rgba(0,0,0,0.1);
    padding-bottom: 10px;
}

/* Contador de registros */
.badge.bg-blue {
    background-color: #3c8dbc !important;
    font-size: 12px;
    padding: 6px 10px;
}

/* Mejoras para las pestañas */
.nav-tabs > li > a {
    border-radius: 4px 4px 0 0;
    border: 1px solid transparent;
    color: #666;
    font-weight: 500;
}

.nav-tabs > li.active > a,
.nav-tabs > li.active > a:hover,
.nav-tabs > li.active > a:focus {
    background-color: #fff;
    border-color: #ddd #ddd transparent;
    color: #3c8dbc;
    font-weight: 600;
}

.nav-tabs > li > a:hover {
    background-color: #f8f9fa;
    border-color: #eee #eee transparent;
}

/* Estados de validación */
.has-error .form-control {
    border-color: #e74c3c;
    box-shadow: inset 0 1px 1px rgba(0,0,0,.075);
}

.has-success .form-control {
    border-color: #27ae60;
    box-shadow: inset 0 1px 1px rgba(0,0,0,.075);
}

/* Mejoras para el modal */
.modal-content {
    border-radius: 6px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.modal-header {
    border-bottom: 1px solid #eee;
}

.modal-footer {
    border-top: 1px solid #eee;
}

/* Animación de entrada para notificaciones */
.alert {
    animation: slideInRight 0.3s ease;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Estilos para datos vacíos */
.text-muted {
    color: #999;
    font-style: italic;
}

/* Mejoras para el responsive de gráficos */
@media (max-width: 992px) {
    .chart-container {
        height: 350px !important;
    }
}

@media (max-width: 768px) {
    .chart-container {
        height: 300px !important;
    }
}

/* Filtros dinámicos */
#filtrosAdicionales {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 4px;
    margin-top: 15px;
    border: 1px solid #e9ecef;
}

/* Estados de carga para selectores */
select:disabled {
    background-color: #f8f9fa;
    cursor: not-allowed;
}

/* Mejoras para el box principal */
.box {
    border-radius: 4px;
    box-shadow: 0 1px 1px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.box-header {
    border-radius: 4px 4px 0 0;
}

.box-body {
    padding: 20px;
}

/* Estilos para exportación */
.export-icon {
    margin-right: 5px;
}

/* Mejoras para el footer de la tabla */
.table tfoot th {
    background-color: #f8f9fa;
    font-weight: 600;
    border-top: 2px solid #dee2e6;
}

/* Colores temáticos para diferentes tipos de reportes */
.reporte-ventas { color: #3c8dbc; }
.reporte-clientes { color: #00a65a; }
.reporte-productos { color: #f39c12; }
.reporte-visitas { color: #605ca8; }
.reporte-inventario { color: #dd4b39; }
.reporte-comentarios { color: #00c0ef; }
.reporte-deseos { color: #d81b60; }