/* Melhorias específicas para imagens dos produtos */

/* Forçar imagens maiores em todos os cards */
.produto-img-container {
    height: 220px !important;
    padding: 12px !important;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%) !important;
    border-bottom: 1px solid #e2e8f0;
}

.produto-img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    object-position: center !important;
    max-width: none !important;
    max-height: none !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
}

/* Efeito hover nas imagens */
.produto-card:hover .produto-img {
    transform: scale(1.05) !important;
    filter: brightness(1.1) !important;
}

/* Ajustar altura dos cards para acomodar imagens maiores */
.produto-card {
    min-height: 420px !important;
    max-height: 470px !important;
}

/* Responsividade para imagens */
@media (max-width: 1200px) {
    .produto-img-container {
        height: 200px !important;
    }
    
    .produto-card {
        min-height: 440px !important;
        max-height: 490px !important;
    }
}

@media (max-width: 900px) {
    .produto-img-container {
        height: 180px !important;
    }
    
    .produto-card {
        min-height: 420px !important;
        max-height: 470px !important;
    }
}

@media (max-width: 600px) {
    .produto-img-container {
        height: 200px !important;
        padding: 16px !important;
    }
    
    .produto-card {
        min-height: 400px !important;
        max-height: 450px !important;
    }
}

/* Placeholder para imagens que não carregam */
.produto-img[src=""], 
.produto-img:not([src]), 
.produto-img[src="#"] {
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-size: 2rem;
    font-weight: 300;
}

.produto-img[src=""]:before, 
.produto-img:not([src]):before, 
.produto-img[src="#"]:before {
    content: "📦";
    font-size: 3rem;
}

/* Melhorar qualidade das imagens */
.produto-img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: optimize-contrast;
    image-rendering: crisp-edges;
    -ms-interpolation-mode: bicubic;
}

/* Garantir que imagens SVG também fiquem grandes */
.produto-img[src$=".svg"] {
    width: 90% !important;
    height: 90% !important;
}

/* Efeito de loading para imagens */
.produto-img-container {
    position: relative;
}

.produto-img-container::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 3px solid #e2e8f0;
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    opacity: 0;
    pointer-events: none;
}

.produto-img[src=""]:not([alt]) + .produto-img-container::after,
.produto-img:not([src]) + .produto-img-container::after {
    opacity: 1;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Melhorar contraste das imagens */
.produto-card:hover .produto-img {
    filter: brightness(1.05) contrast(1.1) !important;
}

/* Garantir que o texto não sobreponha as imagens maiores */
.produto-info {
    padding: 14px 12px !important;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 200px;
}

/* Centralizar preço */
.produto-preco {
    text-align: center !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}