/* Estilos adicionales para la tienda */

/* ========== ESTILOS PARA CATEGORÍAS CON MEDIDAS ESPECÍFICAS ========== */
/* Contenedores de categorías más compactos manteniendo proporciones */
.block1.wrap-pic-w {
    width: 360px !important;
    height: 240px !important;
    margin: 0 auto 30px;
    overflow: hidden;
}

.block1.wrap-pic-w img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    display: block;
}

/* Ajustes responsive para categorías */
@media (max-width: 1200px) {
    .block1.wrap-pic-w {
        width: 320px !important;
        height: 213px !important;
    }
}

@media (max-width: 992px) {
    .block1.wrap-pic-w {
        width: 280px !important;
        height: 187px !important;
    }
}

@media (max-width: 768px) {
    .block1.wrap-pic-w {
        width: 250px !important;
        height: 167px !important;
    }
}

@media (max-width: 576px) {
    .block1.wrap-pic-w {
        width: 220px !important;
        height: 147px !important;
    }
}

/* ========== ESTILOS PARA CATEGORÍAS ========== */
/* Header de sección */
.section-header {
    position: relative;
}

.section-title {
    position: relative;
    display: inline-block;
    padding-bottom: 15px;
}

.section-divider {
    width: 80px;
    height: 3px;
    background: linear-gradient(45deg, #007bff, #0056b3);
    margin: 0 auto 20px;
    border-radius: 2px;
}

.section-subtitle {
    max-width: 600px;
    margin: 0 auto;
    font-size: 1.1rem;
    color: #666;
}

/* Contenedores tipo Kit */
.kit-container {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    text-align: left;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.kit-container:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-3px);
}

.kit-header {
    margin-bottom: 15px;
    flex-shrink: 0;
}

.kit-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    text-align: left;
}

.kit-description {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.4;
    margin: 0;
    text-align: left;
}

.kit-image {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 15px 0;
    min-height: 180px;
}

.kit-image img {
    max-width: 100%;
    max-height: 180px;
    object-fit: contain;
    border-radius: 8px;
}

.kit-footer {
    margin-top: auto;
    padding-top: 15px;
    flex-shrink: 0;
}

.kit-btn {
    display: inline-block;
    background: #007bff;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    text-align: center;
    width: 100%;
}

.kit-btn:hover {
    background: #0056b3;
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
}

/* Estilos eliminados - reemplazados por los contenedores Kit */

/* Responsive para contenedores Kit */
@media (max-width: 768px) {
    .kit-container {
        padding: 15px;
    }
    
    .kit-title {
        font-size: 1.2rem;
    }
    
    .kit-description {
        font-size: 0.85rem;
    }
    
    .kit-image {
        min-height: 150px;
    }
    
    .kit-image img {
        max-height: 150px;
    }
}

@media (max-width: 576px) {
    .kit-container {
        padding: 12px;
        margin-bottom: 20px;
    }
    
    .kit-title {
        font-size: 1.1rem;
    }
    
    .kit-image {
        min-height: 120px;
    }
    
    .kit-image img {
        max-height: 120px;
    }
    
    .kit-btn {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
}

/* ========== ANIMACIONES ========== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Efectos hover para los botones */
.btn-add-cart:hover {
    animation: pulse 0.5s ease-in-out;
}

/* Mejoras responsivas */
@media (max-width: 768px) {
    .hero-section {
        padding: 40px 0;
        text-align: center;
    }
    
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .sidebar-widget {
        margin-bottom: 20px;
    }
    
    .product-card {
        margin-bottom: 20px;
    }
    
    .product-count {
        padding: 10px 15px;
    }
    
    .product-count .row {
        text-align: center;
    }
    
    .product-count .col-md-6 {
        margin-bottom: 10px;
    }
}

@media (max-width: 576px) {
    .hero-section {
        padding: 30px 0;
    }
    
    .hero-section h1 {
        font-size: 1.5rem;
    }
    
    .product-image {
        height: 200px;
    }
    
    .product-info {
        padding: 15px;
    }
    
    .search-input {
        padding: 12px 40px 12px 15px;
    }
}

/* Mejoras en la accesibilidad */
.filter-link:focus,
.btn-add-cart:focus,
.search-btn:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

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

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #667eea;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
}

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

/* Mejoras en el contraste */
.product-category {
    background: rgba(103, 126, 234, 0.1);
    padding: 4px 8px;
    border-radius: 12px;
    display: inline-block;
}

/* Efectos de hover en las tarjetas */
.product-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-card:hover {
    transform: translateY(-8px) scale(1.02);
}

/* Indicadores de stock */
.stock-low {
    color: #e74c3c;
    font-weight: 600;
}

.stock-medium {
    color: #f39c12;
    font-weight: 600;
}

.stock-high {
    color: #27ae60;
    font-weight: 600;
}

/* Mejoras en los badges */
.product-badge {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Animación de entrada para los productos */
.product-item {
    animation: fadeInUp 0.6s ease-out;
}

.product-item:nth-child(1) { animation-delay: 0.1s; }
.product-item:nth-child(2) { animation-delay: 0.2s; }
.product-item:nth-child(3) { animation-delay: 0.3s; }
.product-item:nth-child(4) { animation-delay: 0.4s; }
.product-item:nth-child(5) { animation-delay: 0.5s; }
.product-item:nth-child(6) { animation-delay: 0.6s; }

/* Mejoras en los filtros */
.filter-link.active {
    color: #667eea;
    font-weight: 600;
    background: rgba(103, 126, 234, 0.1);
    padding: 8px 12px;
    border-radius: 8px;
    border: none;
}

/* Estilo para productos sin stock */
.out-of-stock {
    position: relative;
    opacity: 0.6;
}

.out-of-stock::before {
    content: 'Sin Stock';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 10px 20px;
    border-radius: 4px;
    font-weight: 600;
    z-index: 2;
}

/* Mejoras en la tipografía */
.product-title {
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Efectos en los iconos */
.product-actions i {
    transition: all 0.3s ease;
}

.product-actions i:hover {
    transform: scale(1.2);
    color: #667eea !important;
}