/* ===== Mi Catálogo - Estilos personalizados ===== */

/* Navbar púrpura (inspirada en Fiammé) */
.bg-purple {
    background: linear-gradient(135deg, #6a1b9a 0%, #8e24aa 100%) !important;
}

.text-purple {
    color: #7b1fa2 !important;
}

/* Tarjetas de estadísticas */
.card-stat {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card-stat:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1) !important;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

/* Acciones rápidas */
.quick-action {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.quick-action:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.12) !important;
}

/* Tablas */
.table th {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Cards */
.card {
    border-radius: 0.75rem !important;
}

.card-header {
    border-radius: 0.75rem 0.75rem 0 0 !important;
}

/* Botones */
.btn {
    border-radius: 0.5rem;
}

.btn-warning {
    background-color: #f9a825 !important;
    border-color: #f9a825 !important;
    color: #000 !important;
}
.btn-warning:hover {
    background-color: #f57f17 !important;
    border-color: #f57f17 !important;
}

/* Modal */
.modal-content {
    border-radius: 1rem;
    border: none;
}
.modal-header {
    border-radius: 1rem 1rem 0 0 !important;
}

/* Estado select en pedidos */
.estado-select {
    font-size: 0.85rem;
    border-radius: 0.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    .container-fluid {
        padding-left: 10px;
        padding-right: 10px;
    }
    
    h4 {
        font-size: 1.2rem;
    }
    
    .stat-icon {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .card-stat h3 {
        font-size: 1.1rem;
    }

    /* Productos - tarjetas móviles */
    .prod-card {
        border-radius: 0.75rem !important;
        transition: transform 0.15s ease;
        overflow: hidden;
    }
    .prod-card:active {
        transform: scale(0.98);
    }
    .prod-card .card-body {
        font-size: 0.85rem;
    }
    .prod-nombre {
        font-size: 0.88rem;
        line-height: 1.25;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
        word-break: break-word;
    }
    #vistaTarjetas {
        overflow-x: hidden;
    }

    /* Barra acción masiva sticky en móvil */
    #barraAccionMasiva {
        position: sticky;
        top: 56px;
        z-index: 100;
    }

    /* Modal fullscreen en móvil */
    .modal-dialog.modal-lg {
        margin: 0;
        max-width: 100%;
    }
    .modal-dialog.modal-lg .modal-content {
        border-radius: 0;
        min-height: 100vh;
    }
}

/* Productos vista tabla - estilos mejorados */
#tablaProductos {
    font-size: 0.88rem;
}
#tablaProductos thead th {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #6c757d;
    border-bottom: 2px solid #e9ecef;
    padding: 0.6rem 0.5rem;
    white-space: nowrap;
}
#tablaProductos tbody td {
    padding: 0.5rem;
    vertical-align: middle;
}
#tablaProductos tbody tr:hover {
    background-color: rgba(106, 27, 154, 0.04);
}

/* Producto tarjetas desktop */
.prod-card {
    border-radius: 0.75rem !important;
    transition: box-shadow 0.2s ease;
}
.prod-card:hover {
    box-shadow: 0 4px 15px rgba(0,0,0,0.08) !important;
}

/* Barra búsqueda con borde suave */
#buscarProducto:focus {
    box-shadow: none;
    border-color: #8e24aa;
}

/* Badge pill mejorado */
.badge.rounded-pill {
    font-weight: 500;
    letter-spacing: 0.2px;
}

/* Min-width helper */
.min-width-0 {
    min-width: 0;
}

/* Impresión */
@media print {
    .navbar, footer, .btn, .no-print {
        display: none !important;
    }
    .card {
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }
}

/* Animaciones suaves */
.fade-in {
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* DataTables ajustes */
.dataTables_wrapper .dataTables_filter input {
    border-radius: 0.5rem;
    border: 1px solid #dee2e6;
    padding: 0.375rem 0.75rem;
}

.dataTables_wrapper .dataTables_length select {
    border-radius: 0.5rem;
}
