.wc-linked-variants-container {
    display: flex;
	flex-direction: row;
	
    background: #efefef;
    overflow: hidden;
    padding: 8px;
    border-radius: 5px;
    flex-wrap: wrap;
    gap: 9px;
    transition: 1s max-height ease;
    pointer-events: visible;
	align-items: center;
}

.wc-linked-variant-item {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: calc(20% - 8px); /* A bit wider to accommodate text */
    max-height: 107px;
    border: 1px solid #d1b06b; /* Gold border based on the reference image */
    border-radius: 4px;
    overflow: hidden;
    text-decoration: none !important;
    transition: all 0.2s ease-in-out;
    box-sizing: border-box;
}

.wc-linked-variant-item:hover {
    border-color: #444; /* Darker border on hover to match the overlay */
}

.wc-linked-variant-item img {
    width: 100%;
    height: 100% !important;
    object-fit: cover;
    display: block;
    transition: opacity 0.3s ease;
}

/* Dark overlay on hover */
.wc-linked-variant-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgb(0 0 0 / 71%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
    padding: 6px;
    z-index: 2;
}

.wc-linked-variant-item:hover .wc-linked-variant-overlay {
    opacity: 1;
}

/* Text inside the overlay */
.wc-linked-variant-text {
    color: #ffffff !important;
    font-size: 11px;
    line-height: 1.2;
    text-align: center;
    font-weight: 700;
    font-family: inherit;
    word-break: break-word;
    margin: 0;
    padding: 0;
}

.wc-linked-variants-wrapper {
    margin-bottom: 25px;
}

.wc-linked-variants-container {
    margin-bottom: 10px; /* Reduced margin to bring toggle closer */
    margin-top: 20px;
}

.hidden-variant {
    display: none !important;
}

.wc-linked-variants-container.expanded .hidden-variant {
    display: flex !important;
}

.wc-linked-variants-toggle {
    text-align: center;
    font-size: 14px;
    color: #444;
    cursor: pointer;
    margin-top: 5px;
    font-weight: 500;
}

.wc-linked-variants-toggle:hover {
    text-decoration: underline;
}
