.product-color-picker {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 4px 0;
}

.product-color-picker__item {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 3px;
    cursor: pointer;
    border-radius: 50%;
    border: 2px solid transparent;
    background: transparent;
    transition: border-color 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

.product-color-picker__item:hover {
    transform: scale(1.08);
}

.product-color-picker__item.is-selected {
    border-color: #ee3b27;
    box-shadow: 0 0 0 2px rgba(238, 59, 39, 0.2);
}

.product-color-picker__item input[type="radio"] {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.product-color-picker__circle {
    display: block;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.12);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
    transition: box-shadow 0.2s ease;
}

.product-color-picker__item.is-selected .product-color-picker__circle {
    box-shadow: inset 0 0 0 2px #fff, 0 1px 4px rgba(0, 0, 0, 0.2);
}

.product-color-picker__item.is-selected::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: 0;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #ee3b27 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath fill='%23fff' d='M4.5 8.5L1.5 5.5l1-1 2 2 4.5-4.5 1 1z'/%3E%3C/svg%3E") center/10px no-repeat;
    border: 2px solid #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
}

.product-color-picker__tooltip {
    position: absolute;
    z-index: 20;
    left: 50%;
    bottom: calc(100% + 8px);
    transform: translateX(-50%) translateY(4px);
    padding: 4px 10px;
    font-size: 12px;
    line-height: 1.4;
    color: #fff;
    background: rgba(33, 37, 41, 0.92);
    border-radius: 4px;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s ease;
}

.product-color-picker__tooltip::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border: 5px solid transparent;
    border-top-color: rgba(33, 37, 41, 0.92);
}

.product-color-picker__item:hover .product-color-picker__tooltip,
.product-color-picker__item:focus-within .product-color-picker__tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.product-specification-selector .product-color-picker + select,
.product-specification-selector select.product-spec-value-input {
    max-width: 100%;
}
