/* Общие стили */
.frt-linked-wrapper {
    clear: both;
    width: 100%;
}

/* Grid Mode */
.frt-grid-mode {
    margin-top: 10px; 
    margin-bottom: 12px; 
    min-height: 24px;
}

/* Single Mode */
.frt-single-mode {
    margin-bottom: 20px;
}

.frt-attr-label-wrapper {
    margin-bottom: 15px;
}

.frt-label-title {
    font-weight: 800;
    text-transform: uppercase;
    font-size: 14px;
    color: #000;
}

/* Свотчи */
.frt-color-swatches {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.frt-swatch-circle {
    display: block;
    width: 24px; 
    height: 24px;
    border-radius: 50%;
    border: 1px solid rgba(0,0,0,0.1);
    cursor: pointer;
    transition: transform 0.2s ease;
    box-sizing: border-box;
    position: relative;
}

/* Размер в карточке */
.frt-single-mode .frt-swatch-circle {
    width: 28px;
    height: 28px;
}

.frt-swatch-circle:hover {
    transform: scale(1.15);
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}

.frt-swatch-circle.active {
    box-shadow: 0 0 0 2px #ffffff, 0 0 0 3px #000000;
    border-color: transparent;
    pointer-events: none;
}

/* --- СПИННЕР ЗАГРУЗКИ (НОВОЕ) --- */
.frt-swatch-circle.loading-active {
    pointer-events: none;
    opacity: 0.8;
}
.frt-swatch-circle.loading-active::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    border-radius: 50%;
    border: 2px solid transparent;
    border-top-color: #000; /* Цвет спиннера */
    animation: frt-spin 0.6s linear infinite;
}

@keyframes frt-spin {
    to { transform: rotate(360deg); }
}

/* Тултипы */
.frt-swatch-circle[title]:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 140%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #000;
    color: #fff;
    padding: 4px 6px;
    font-size: 10px;
    border-radius: 2px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    animation: frt-tooltip-fade 0.2s forwards;
    z-index: 100;
}

@keyframes frt-tooltip-fade {
    to { opacity: 1; }
}