﻿.swal-product-wrapper {
    display: flex;
    flex-direction: column; /* 🔥 IMAGEN ARRIBA */
    gap: 15px;
    text-align: left;
}

/* IMAGEN GRANDE Y HORIZONTAL */
.swal-product-img img {
    width: 100%;
    max-height: 280px;
    object-fit: cover;
    border-radius: 10px;
}

/* INFO */
.swal-product-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 5px;
}

.swal-product-price {
    font-size: 20px;
    font-weight: bold;
    color: #dc0030;
    margin-bottom: 10px;
}

.swal-product-desc {
    font-size: 14px;
    color: #666;
    margin-bottom: 10px;
}

/* SWATCHES */
.swatch-group {
    display: flex;
    gap: 10px;
    margin-top: 5px;
}

.swatch-option {
    cursor: pointer;
    border-radius: 6px;
    transition: all .2s ease;
}

    .swatch-option.color {
        width: 28px;
        height: 28px;
    }

    .swatch-option.text {
        padding: 6px 12px;
        border: 1px solid #ccc;
        font-size: 13px;
    }

    .swatch-option.active {
        outline: 2px solid #dc0030;
    }


/* ===================== CONTENEDOR IMAGEN ===================== */
.img-container {
    width: 100%;
    max-height: 250px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    margin-bottom: 10px;
}

    .img-container img {
        width: auto;
        height: 100%;
        object-fit: contain;
        display: block;
    }


/* ===================== GRID ===================== */
.row {
    display: flex;
    flex-wrap: wrap;
}

    .row > .col-md-4 {
        display: flex;
        flex-direction: column;
    }


/* ===================== CAJA PRODUCTO ===================== */
.box {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px;
    margin-bottom: 30px;
    border: 1px solid #ddd;
    border-radius: 8px;
    min-height: 450px;
    height: 100%;
    overflow: hidden;
}

    .box img {
        max-width: 100%;
        height: auto;
        object-fit: contain;
        margin-bottom: 10px;
    }


/* ===================== TEXTO PRODUCTO ===================== */
.titulo-producto {
    font-size: 1.2rem;
    font-weight: bold;
    text-align: left;
    word-wrap: break-word;
    overflow-wrap: break-word;
    width: 100%;
    padding: 0 5px;
}

.box p {
    font-size: 0.95rem;
    line-height: 1.4;
    text-align: left;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: pre-wrap;
    width: 100%;
    padding: 0 5px;
}


/* ===================== PRECIOS ===================== */
.precios-container {
    display: flex;
    justify-content: flex-start;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.precio {
    display: inline-block;
    font-weight: bold;
}


/* ===================== BOTONES ===================== */
.btn-whatsapp {
    margin-top: auto;
    display: block;
    width: 100%;
    background-color: #25D366;
    color: #fff;
    padding: 8px 12px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
}

    .btn-whatsapp:hover {
        background-color: #1ebe57;
    }

.btnircategoria {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 15px;
    background-color: #007bff;
    color: #fff;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
}

    .btnircategoria:hover {
        background-color: #0056b3;
    }


/* ===================== RESPONSIVE ===================== */
@media (max-width: 768px) {
    .img-container {
        max-height: 200px;
    }
}


/* Contenedor de la imagen */
.img-container {
    width: 100%;
    /* Ajuste de altura para que todas las cajas tengan el mismo tamaño en desktop */
    max-height: 250px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    margin-bottom: 10px;
}

    /* Imagen dentro del contenedor */
    .img-container img {
        width: auto; /* Se ajusta automáticamente al contenedor */
        height: 100%; /* Ocupa toda la altura del contenedor */
        object-fit: contain; /* Mantiene proporción sin recortar */
        display: block;
    }

/* Caja de producto */
.box {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px;
    margin-bottom: 30px;
    border: 1px solid #ddd;
    border-radius: 8px;
    height: 100%; /* Permite que la caja se ajuste a la columna */
}

/* Responsivo en pantallas pequeñas */
@media (max-width: 768px) {
    .img-container {
        max-height: 200px;
    }
}

.row {
    display: flex;
    flex-wrap: wrap;
}

    .row > .col-md-4 {
        display: flex;
        flex-direction: column;
    }
/* Caja de producto */
.box {
    display: flex;
    flex-direction: column;
    align-items: center; /* imagen y botones centrados */
    padding: 15px;
    margin-bottom: 30px;
    border: 1px solid #ddd;
    border-radius: 8px;
    min-height: 450px;
    overflow: hidden;
}

    /* Imagen del producto */
    .box img {
        max-width: 100%;
        height: auto;
        object-fit: contain;
        margin-bottom: 10px;
    }


/* Título del producto */
.titulo-producto {
    font-size: 1.2rem;
    font-weight: bold;
    text-align: left; /* alineado a la izquierda */
    word-wrap: break-word;
    overflow-wrap: break-word;
    width: 100%;
    padding-left: 5px;
    padding-right: 5px;
}

/* Texto de descripción y datos */
.box p {
    font-size: 0.95rem;
    line-height: 1.4;
    text-align: left; /* alineado a la izquierda */
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: pre-wrap; /* respeta saltos de línea */
    width: 100%;
    padding-left: 5px;
    padding-right: 5px;
}

.precio span {
    font-weight: bold;
}

/* Botón de WhatsApp */
.btn-whatsapp {
    margin-top: auto;
    display: inline-block;
    background-color: #25D366;
    color: #fff;
    padding: 8px 12px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
}

    .btn-whatsapp:hover {
        background-color: #1ebe57;
    }

/* Botón ver todos los productos */
.btnircategoria {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 15px;
    background-color: #007bff;
    color: #fff;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
}

    .btnircategoria:hover {
        background-color: #0056b3;
    }

.precios-container {
    display: flex;
    justify-content: flex-start; /* alinear a la izquierda */
    gap: 10px; /* espacio entre precios */
    flex-wrap: wrap; /* si no caben, pasan a la siguiente línea */
    margin-top: 10px;
}

.precio {
    display: inline-block;
    font-weight: bold;
}

.btn-whatsapp {
    margin-top: 10px;
    display: block;
    text-align: center;
    width: 100%;
}
