:root {
    --color-primario: #8a2be2;
    --color-secundario: #ff6b6b;
    --tercer: #f35988;
    --font: #ffffff;
    --primary: #2c3e50;
    --primary-dark: #1a252f;
    --primary-light: #3d566e;
    --secondary: #f8f9fa;
    --gold: #d4af37;
    --platinum: #e5e4e2;
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
body { font-family: 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;}

.products-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.area-titulo {
    font-size: 2.5rem;
    font-weight: 300;
    margin: 3rem 0 1.5rem;
    text-align: center;
    color: var(--primary);
    position: relative;
    padding-bottom: 1rem;
}

.area-titulo::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: linear-gradient(90deg, var(--gold), var(--tercer));
}

.area-titulo strong {
    font-weight: 600;
    color: var(--color-primario);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    padding: 1rem 0;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    position: relative;
    border: 1px solid rgba(0,0,0,0.05);
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-color: rgba(0,0,0,0.1);
}

.product-image-container {
    width: 100%;
    height: 240px;
    overflow: hidden;
    background: var(--secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 1.5rem;
    transition: var(--transition);
}

.product-card:hover .product-image {
    transform: scale(1.03);
}

.product-content {
    padding: 1.5rem;
    border-top: 1px solid rgba(0,0,0,0.05);
}

.product-title {
    font-size: 1.1rem;
    font-weight: 500;
    margin-bottom: 0.75rem;
    color: #000000;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-price {
    font-weight: 700;
    color: #de4099;
    font-size: 1.3rem;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
}

.product-price::before {
    content: '$';
    font-size: 0.9em;
    margin-right: 2px;
    color: #de4099;
}

.recommended-actions {
    display: flex;
    gap: 0.8rem;
    justify-content: center;
    margin-top: 1.5rem;
    justify-content: flex-start; /* Alinea los botones a la izquierda */
    flex-wrap: wrap; /* Permite que los botones pasen a otra línea en móviles */
}
.recommended-actions .recommended-btn-primary {
    width: 100%;              /* O puedes usar un valor fijo como 100% del contenedor */
    text-align: center;
    justify-content: center;
}
.recommended-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 1.2rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    gap: 0.5rem;
}

.recommended-btn i {
    font-size: 0.9rem;
}
a {
   all: unset; /* Esto resetea todos los estilos por defecto */
   cursor: pointer; /* Vuelve a poner el cursor tipo enlace */
   color: inherit;  /* Hereda el color del padre */
   text-decoration: none; /* Quita el subrayado */
   }
.recommended-btn-primary {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 12px 24px; /* Mantengo tu padding original */
    background-color: transparent;
    color: var(--tercer);
    border: 2px solid var(--tercer);
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
    white-space: nowrap;
    width: auto; /* Asegura que el ancho se ajuste al contenido */
    min-width: min-content; /* Evita que el botón sea más estrecho que su contenido */
    box-sizing: border-box; /* Incluye padding y border en el ancho total */
}
.recommended-btn-primary:hover {
   background: linear-gradient(to right, var(--color-secundario) , var(--color-primario));
   color: #ffffff;
   }

.recommended-btn-secondary {
    background-color: white;
    color: var(--primary);
    border: 1px solid var(--primary);
    width: 42px;
    padding: 0.7rem;
}

.recommended-btn-secondary:hover {
    background-color: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Filtros y ordenación */
.filtros-container {
    max-width: 1400px;
    margin: 0 auto 2rem;
    padding: 0 2rem;
}

.filtro-orden {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-bottom: 1rem;
    gap: 1rem;
}

.filtro-orden label {
    font-size: 0.95rem;
    color: #555;
    font-weight: 500;
}

.custom-select-wrapper {
    position: relative;
    display: inline-block;
    min-width: 220px;
}

.custom-select-wrapper select {
    padding: 10px 40px 10px 15px;
    font-size: 0.95rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #fff;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    cursor: pointer;
    outline: none;
    width: 100%;
    color: #444;
    transition: var(--transition);
    box-shadow: 0 2px 5px rgba(0,0,0,0.03);
}

.custom-select-wrapper select:hover {
    border-color: #bbb;
}

.custom-select-wrapper select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(44, 62, 80, 0.1);
}

.custom-select-wrapper .flecha {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    font-size: 1rem;
    color: #777;
}

/* Paginación */
.pagination {
    display: flex;
    justify-content: center;
    margin: 3rem 0;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.page-link {
    padding: 0.7rem 1.2rem;
    border-radius: 8px;
    background: white;
    border: 1px solid #eee;
    font-weight: 500;
    color: #555;
    text-decoration: none;
    transition: var(--transition);
    box-shadow: 0 2px 5px rgba(0,0,0,0.03);
}

.page-link:hover {
    background: var(--primary-light);
    color: white;
    border-color: var(--primary-light);
}

.page-link.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    pointer-events: none;
}
.soldout-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: #c0392b;
    color: #fff;
    padding: 5px 8px;
    font-size: 0.75rem;
    border-radius: 8px;
    z-index: 2;
}
/* Mensaje cuando no hay productos */
.no-products {
    text-align: center;
    padding: 4rem 0;
    color: #777;
    font-size: 1.1rem;
}

/* Efecto hover más suave */
/* Badge para productos nuevos */
.new-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--tercer);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    z-index: 2;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Responsive */
@media (max-width: 1200px) {
    .products-grid {
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .area-titulo {
        font-size: 2rem;
        margin: 2rem 0 1rem;
    }

    .filtros-container {
        padding: 0 1rem;
    }

    .filtro-orden {
        justify-content: center;
    }

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 1.25rem;
    }
}

@media (max-width: 480px) {
    .area-titulo {
        font-size: 1.8rem;
    }

    .products-container {
        padding: 0 1rem;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr); /* Cambiado de auto-fill a 2 columnas fijas */
        gap: 1rem; /* Reducir el gap para aprovechar mejor el espacio */
    }

    .product-image-container {
        height: 180px; /* Altura ligeramente reducida */
    }

    .product-content {
        padding: 1rem; /* Padding reducido */
    }

    .product-title {
       font-size: 1.1rem;
       font-weight: 600;
       color:#000000;
       margin-bottom: 0.5rem;
       white-space: nowrap;
       overflow: hidden;
       text-overflow: ellipsis;
    }

    .product-price {
        font-size: 1.1rem; /* Tamaño de fuente reducido */
        margin-bottom: 1rem;
    }

    .recommended-actions {
        flex-direction: row; /* Mantener los botones en fila */
        gap: 0.5rem;
        margin-top: 1rem;
    }

    .recommended-btn {
        padding: 0.5rem; /* Padding reducido */
        font-size: 0.8rem;
    }

    .recommended-btn-secondary {
        width: auto; /* Ancho automático */
    }
}