/**
 * Estilos para Pills de Variaciones de WooCommerce
 * Sistema de botones visuales para reemplazar selects de variaciones
 * 
 * @package DG_Regalos_Productos
 * @version 1.0.0
 */

/* ===========================
   OCULTAR SELECT ORIGINAL
   =========================== */
select.dg-select--hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    border: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* ===========================
   CONTENEDOR DE PILLS
   =========================== */
.dg-variation-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

/* ===========================
   PILL BASE
   =========================== */
.dg-pill {
    border: 1px solid #3b3b3b;
    background: #0c0c0c;
    color: #eaeaea;
    padding: 0.55rem 0.8rem;
    border-radius: 0.6rem;
    font-size: 0.95rem;
    min-height: 46px;
    min-width: 46px;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.08s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    font-family: Oswald, Arial, sans-serif;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.dg-pill:hover:not(.is-disabled) {
    border-color: #ffffff;
    background-color: #ffffff;
    color: #000000;
    transform: translateY(-2px);
}

.dg-pill:focus {
    outline: 2px solid #02be95;
    outline-offset: 2px;
}

/* ===========================
   ESTADO: SELECCIONADO
   =========================== */
.dg-pill.is-selected {
    border-color: #02be95;
    background-color: #02be95 !important;
    color: #ffffff;
}

.dg-pill.is-selected:hover {
    background-color: #029f7d !important;
}

/* ===========================
   ESTADO: DESHABILITADO
   =========================== */
.dg-pill.is-disabled {
    cursor: not-allowed;
    position: relative;
    color: #979797;
    border-color: #545454;
    background-color: #2F2F2F;
    opacity: 0.6;
}

.dg-pill.is-disabled::before,
.dg-pill.is-disabled::after {
    content: "";
    position: absolute;
    top: 48%;
    left: -5px;
    width: 124%;
    height: 2px;
    background: #545454;
    opacity: 0.4;
}

.dg-pill.is-disabled::before {
    transform: rotate(45deg);
}

.dg-pill.is-disabled::after {
    transform: rotate(-45deg);
}

/* ===========================
   VARIANTES ESPECÍFICAS
   =========================== */

/* Pills de color - puede mostrar color real si quieres */
.dg-variation-pills--color .dg-pill {
    min-width: 50px;
    padding: 0.6rem 1rem;
}

/* Pills de talla - más compactas */
.dg-variation-pills--talla .dg-pill {
    min-width: 46px;
    font-weight: 600;
}

/* Pills de tamaño */
.dg-variation-pills--tamano .dg-pill {
    min-width: 60px;
}

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 768px) {
    .dg-variation-pills {
        gap: 0.4rem;
    }

    .dg-pill {
        font-size: 0.9rem;
        padding: 0.5rem 0.7rem;
        min-height: 42px;
        min-width: 42px;
    }
}