/* ============================================================
   Premium Variation Thumbnails — clean, minimal, responsive
   ============================================================ */

/* Hide the theme's native colour selector row (the <select> stays
   in the DOM — WooCommerce needs it to find the variation). */
.pvt-native-hidden {
    display: none !important;
}

.pvt {
    margin: 20px 0 8px;
    font-family: inherit;
}

.pvt-label {
    font-size: 17px;
    line-height: 1.4;
    color: #111111;
    margin: 0 0 14px;
    font-weight: 400;
}

.pvt-label strong {
    font-weight: 700;
    color: #111111;
}

.pvt-thumbs {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    align-items: flex-start !important;
    justify-content: flex-start !important;
    gap: 14px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.pvt-thumb {
    appearance: none;
    -webkit-appearance: none;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    flex: 0 0 auto !important;
    width: 108px !important;
    max-width: 108px !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    background: #ffffff;
    border: 1px solid #e4e4e4;
    border-radius: 10px;
    padding: 8px 8px 10px;
    cursor: pointer;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
    text-align: center;
}

.pvt-thumb:hover {
    border-color: #9a9a9a;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.pvt-thumb:focus-visible {
    outline: 2px solid #111111;
    outline-offset: 2px;
}

.pvt-thumb.is-selected {
    border: 2px solid #111111;
    padding: 7px 7px 9px; /* compensate so size doesn't jump */
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.10);
}

.pvt-thumb-img {
    display: block;
    width: 100% !important;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 6px;
    background: #f6f6f6;
}

.pvt-thumb-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pvt-thumb-name {
    display: block;
    margin-top: 9px;
    font-size: 13.5px;
    line-height: 1.3;
    color: #111111;
    word-break: break-word;
}

/* ---------- Responsive ---------- */

@media (max-width: 768px) {
    .pvt-thumbs {
        gap: 10px;
    }
    .pvt-thumb {
        width: calc(33.333% - 7px) !important; /* 3 per row, touch-friendly */
        max-width: calc(33.333% - 7px) !important;
        min-width: 96px !important;
    }
}

@media (max-width: 420px) {
    .pvt-thumb {
        width: calc(50% - 5px) !important; /* 2 per row on very small screens */
        max-width: calc(50% - 5px) !important;
    }
}
