/* ========================================================== */
/* == 🎨 ESTILOS EXCLUSIVOS PARA LA TARJETA DE PRODUCTO 🎨 == */
/* ========================================================== */

/* --- VARIABLES DE COLORES (Necesarias para la tarjeta) --- */
:root {
  /* TEMA CLARO (POR DEFECTO) */
  --color-texto: #212529;
  --color-texto-secundario: #6c757d;
  --color-tarjeta-fondo: #FFFFFF;
  --color-borde: #dee2e6;
  --color-borde-claro: #eee;
  --color-sutil: rgba(0, 0, 0, 0.04);
  --color-sombra: rgba(0,0,0,0.1);
}

[data-theme="dark"] {
  /* TEMA OSCURO */
  --color-texto: #E0E0E0;
  --color-texto-secundario: #adb5bd;
  --color-tarjeta-fondo: #1E1E1E;
  --color-borde: #444444;
  --color-sutil: rgba(255, 255, 255, 0.05);
}

/* --- TARJETAS DE PRODUCTO --- */
.producto-card { 
    background-color: var(--color-tarjeta-fondo);
    border: 1px solid var(--color-borde-claro); 
    transition: all 0.3s ease-in-out; 
    border-radius: 8px; 
    overflow: hidden; 
    cursor: pointer; 
    min-height: 370px; 
    display: flex; 
    flex-direction: column;
}
.producto-card:hover { 
    border-color: var(--color-borde); 
    box-shadow: 0 4px 12px var(--color-sombra); 
}
.producto-card .button-wrapper { cursor: default; }
.producto-card .image-container {
    height: 200px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    position: relative; 
    background-color: var(--color-sutil); 
}
.producto-card .image-container img { max-height: 100%; max-width: 100%; object-fit: contain; padding: 10px; }
.producto-card .btn-add-to-cart { border: 1px solid #E69A0E; color: #ba8a54; background-color: transparent; border-radius: 30px; font-size: 0.9rem; font-weight: 500; padding: 6px 15px; transition: all 0.2s ease-in-out; }
.producto-card .btn-add-to-cart:hover {
    background-color: #fff1e6;
}
.producto-card .button-wrapper { min-height: 50px; display: flex; align-items: center; justify-content: center; }
.producto-card .quantity-controls-wrapper { display: flex; flex-direction: column; align-items: flex-start; width: 100%; }
.producto-card .in-cart-text { font-size: 0.75rem; color: var(--color-texto-secundario); margin-bottom: 2px; }
.producto-card .controls-row { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.producto-card .button-group { display: flex; align-items: center; gap: 8px; }
.producto-card .btn-quantity { background-color: #F7C044; color: #725007; border-radius: 50%; width: 32px; height: 32px; border: none; font-size: 1.2rem; font-weight: bold; display: flex; align-items: center; justify-content: center; }
.producto-card .btn-quantity:disabled { background-color: #E0E0E0; color: #9E9E9E; cursor: not-allowed; }
.producto-card .quantity-display { font-weight: bold; font-size: 1.25rem; color: #B37B18; }

/* --- ICONO DE FAVORITO (OPCIONAL) --- */
.favorite-icon {
    font-size: 1.5rem;
    color: #ff4d6d;
    cursor: pointer;
    transition: transform 0.2s ease;
}
.favorite-icon:hover {
    transform: scale(1.2);
}

/* ========================================================== */
/* ✅ AJUSTES RESPONSIVE PARA LA TARJETA EN MÓVILES ✅ */
/* ========================================================== */
@media (max-width: 575.98px) {
    .producto-card {
        min-height: 260px;
    }
    .producto-card .image-container {
        height: 120px;
    }
    .producto-card .card-body {
        padding: 0.6rem;
    }
    .producto-card .card-title {
        font-size: 0.8rem;
        margin-bottom: 0.25rem !important;
        white-space: normal;
        text-overflow: initial;
        overflow: initial;
    }
    .producto-card .product-origin, .producto-card .card-text {
        font-size: 0.75rem;
        margin-bottom: 0.25rem !important;
    }
    .producto-card .price-container {
        margin-bottom: 0.5rem !important;
    }
    .producto-card .current-price {
        font-size: 1rem;
    }
    .producto-card .original-price {
        font-size: 0.8rem;
    }
    .producto-card .btn-add-to-cart {
        font-size: 0.75rem;
        padding: 4px 10px;
    }
}