/* ============================================================
   Custom Handles — Inline Color Panel
   ============================================================ */

/* Inline color panel (rendered below the "Colours" button) */
.ch-color-inline {
    margin-top: 8px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 6px;
    color: var(--menu_text_color);
}

/* Color pair block */
.ch-color-pair {
    margin-bottom: 12px;
}

.ch-color-pair:last-child {
    margin-bottom: 0;
}

/* Category names row */
.ch-pair-names {
    display: flex;
    gap: 14px;
    margin-bottom: 4px;
}

.ch-pair-name {
    flex: 1;
    min-width: 0;
    font-size: 13px;
    opacity: 0.8;
    color: var(--menu_text_color);
}

.ch-pair-name-primary {
    padding-right: 14px;
    border-right: 1px solid var(--buttons_background_color);
}

/* Price row */
.ch-pair-price {
    text-align: center;
    margin-bottom: 6px;
}

/* Swatches row */
.ch-pair-swatches {
    display: flex;
    gap: 14px;
    align-items: stretch;
}

.ch-swatch-column {
    flex: 1;
    min-width: 0;
}

.ch-swatch-column-primary {
    padding-right: 14px;
    border-right: 1px solid var(--buttons_background_color);
}

.ch-swatch-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 6px;
    row-gap: 3px;
}

/* "Colours" toggle button */
.ch-color-popup-btn {
    font-size: 13px;
    padding: 6px 16px;
    cursor: pointer;
    border: 1px solid var(--buttons_background_color);
    background: var(--buttons_background_color);
    color: var(--buttons_text_color);
    border-radius: 4px;
    width: 100%;
}

.ch-color-popup-btn:hover {
    background: var(--active_buttons_background_color);
    color: var(--active_buttons_text_color);
}

.ch-color-popup-btn.ch-color-btn-open {
    background: var(--active_buttons_background_color);
    color: var(--active_buttons_text_color);
}

/* ============================================================
   Mobile responsive
   ============================================================ */
@media (max-width: 600px) {
    .ch-pair-names {
        flex-direction: column;
        gap: 4px;
    }

    .ch-pair-name-primary {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid var(--buttons_background_color);
        padding-bottom: 4px;
    }

    .ch-pair-swatches {
        flex-direction: column;
        gap: 10px;
    }

    .ch-swatch-column-primary {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid var(--buttons_background_color);
        padding-bottom: 10px;
    }

    .ch-swatch-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 380px) {
    .ch-swatch-grid {
        grid-template-columns: 1fr;
    }
}
