/* ============================================================
   Attribute selectors — trigger rows + slide-in aside
   with full-width option rows (image thumbnail + label).
   ============================================================ */

/* Hide the native WC select; JS reads it but the user never sees it.
   Elementor renders without the standard attribute_select class, so we
   target the data attribute that is always present. */
.variations td.value select[data-attribute_name] {
    display: none !important;
}

/* ---- Attribute row trigger ---- */

.huus-attr-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 0;
    cursor: pointer;
    border-bottom: 1px solid #ebebeb;
    user-select: none;
}

.huus-attr-trigger:focus-visible {
    outline: 2px solid #8ca8bc;
    outline-offset: 2px;
}

.huus-attr-trigger__label {
    flex: 1;
    font-size: 0.9rem;
    color: #333;
    line-height: 1.4;
}

.huus-attr-trigger__selected {
    font-weight: 600;
    color: #111;
}

.huus-attr-trigger__chevron {
    flex-shrink: 0;
    font-size: 1.25rem;
    line-height: 1;
    color: #aaa;
}

/* ---- Inline image swatches (kleuren attribute, in the form) ---- */

.huus-swatch-label {
    font-size: 0.9rem;
    color: #333;
    padding: 10px 0 4px;
    line-height: 1.4;
}

.huus-img-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    padding: 4px 0 10px;
    border-bottom: 1px solid #ebebeb;
}

.huus-img-chip {
    width: 30px;
    height: 30px;
    border-radius: 0 !important;
    border: none;
    padding: 0 !important;
    background-position: top left;
    background-size: 3000%;
    background-repeat: no-repeat;
    background-color: #e8e8e8;
    cursor: pointer;
    overflow: hidden;
    outline: 1px solid transparent;
    outline-offset: 3px;
    transition: outline-color 0.12s ease;
}

.huus-img-chip:hover:not(.huus-img-chip--selected):not(.huus-img-chip--unavailable) {
    outline-color: #c0d0d8;
}

.huus-img-chip:focus-visible {
    outline: 2px solid #8ca8bc;
    outline-offset: 3px;
}

.huus-img-chip--selected {
    outline-color: #8ca8bc;
}

.huus-img-chip--unavailable {
    opacity: 0.35;
    cursor: not-allowed;
    pointer-events: none;
}

/* ---- Aside / drawer ---- */

.huus-aside {
    position: fixed;
    inset: 0;
    z-index: 99999;
    pointer-events: none;
}

.huus-aside__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.25);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.huus-aside--open {
    pointer-events: auto;
}

.huus-aside--open .huus-aside__backdrop {
    opacity: 1;
}

.huus-aside__panel {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(340px, 92vw);
    background: #fff;
    padding: 48px 24px 32px;
    box-shadow: -4px 0 32px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    gap: 20px;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.28s ease;
}

.huus-aside--open .huus-aside__panel {
    transform: translateX(0);
}

.huus-aside__close {
    position: absolute;
    top: 14px;
    right: 18px;
    background: none;
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    color: #888;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 3px;
    transition: color 0.15s;
}

.huus-aside__close:hover {
    color: #111;
}

.huus-aside__title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    color: #111;
    line-height: 1.3;
}

/* ---- Option list (full-width rows) ---- */

.huus-aside__options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.huus-aside__option {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: #f9f9f9;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
    font-size: 0.88rem;
    color: #333;
    transition: border-color 0.12s ease, background 0.12s ease;
}

.huus-aside__option:hover:not(.huus-aside__option--selected):not(.huus-aside__option--unavailable) {
    border-color: #aaa;
    background: #f2f2f2;
}

.huus-aside__option:focus-visible {
    outline: 2px solid #8ca8bc;
    outline-offset: 2px;
}

.huus-aside__option--selected {
    border-color: #8ca8bc;
    border-width: 2px;
    background: #fff;
    cursor: default;
}

.huus-aside__option--unavailable {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

/* Square image thumbnail inside each option row */
.huus-aside__option-img {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 3px;
    background-color: #e8e8e8;
    background-position: top left;
    background-size: 3000%;
    background-repeat: no-repeat;
}

.huus-aside__option-label {
    flex: 1;
    line-height: 1.3;
}
