.filter {
    position: relative;
    display: inline-block;
}

.filter[open] {
    position: absolute;
    background-color: white;
    box-shadow: 0 0 12px 6px rgba(0, 0, 0, 0.25);
    outline: 6px solid white;
    z-index: 10;
}

.filter-summary {
    list-style: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    z-index: 11;
}

.filter-summary::-webkit-details-marker {
    display: none;
}

.filter-chevron {
    width: 0.6rem;
    height: auto;
    display: inline-block;
    transition: transform 200ms ease;
    filter: invert(60%);
}

.filter[open] .filter-chevron {
    transform: rotate(180deg);
}

.filter-menu {
    top: 100%;
    left: -0.25rem;
    margin: 0.25rem 0 0;
    list-style: none;
    background: var(--color-background, #fff);
    min-width: 4rem;
    z-index: 10;
}

.filter-menu-item {
    list-style: none;
}

.filter-menu-link {
    display: block;
    padding: 0.15rem 0;
    text-decoration: none;
    color: inherit;
    white-space: nowrap;
    opacity: 0.5;
}

.filter-menu-link:hover,
.filter-menu-link.active {
    opacity: 1;
}

.filter-menu-sub {
    list-style: none;
    margin: 0;
    padding: 0;
}

.filter-menu-link-child {
    padding-left: 0.9rem;
}
