.mmg-price .mmg-price-slider[hidden],
.mmg-price .mmg-price-fields[hidden] {
    display: none;
}

.mmg-price fieldset {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.mmg-price .mmg-price-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 10px;
}

.mmg-price .mmg-price-fields input {
    box-sizing: border-box;
    width: 100%;
    padding-inline: 8px;
}

.mmg-price .mmg-price-track {
    --mmg-price-thumb: 36px;
    --mmg-price-rail-off: #dce7f1;
    --mmg-price-accent: #0068cd;
    position: relative;
    height: 44px;
    margin-block: 2px 0;
}

.mmg-price .mmg-price-rail {
    position: absolute;
    inset: 50% calc(var(--mmg-price-thumb) / 2) auto;
    height: 3px;
    transform: translateY(-50%);
    border-radius: 2px;
    background: linear-gradient(to right,
        var(--mmg-price-rail-off) 0% var(--mmg-price-start, 0%),
        var(--mmg-price-accent) var(--mmg-price-start, 0%) var(--mmg-price-end, 100%),
        var(--mmg-price-rail-off) var(--mmg-price-end, 100%) 100%);
}

.mmg-price .mmg-price-track input[type='range'] {
    appearance: none;
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    pointer-events: none;
    touch-action: pan-y;
}

.mmg-price .mmg-price-track input[type='range']::-webkit-slider-runnable-track {
    height: var(--mmg-price-thumb);
    background: transparent;
}

.mmg-price .mmg-price-track input[type='range']::-moz-range-track {
    height: var(--mmg-price-thumb);
    background: transparent;
}

.mmg-price .mmg-price-track input[type='range']::-webkit-slider-thumb {
    appearance: none;
    box-sizing: border-box;
    width: var(--mmg-price-thumb);
    height: var(--mmg-price-thumb);
    border: 0;
    border-radius: 50%;
    background: radial-gradient(circle, var(--mmg-price-accent) 7px, transparent 7.5px);
    cursor: ew-resize;
    pointer-events: auto;
}

.mmg-price .mmg-price-track input[type='range']::-moz-range-thumb {
    box-sizing: border-box;
    width: var(--mmg-price-thumb);
    height: var(--mmg-price-thumb);
    border: 0;
    border-radius: 50%;
    background: radial-gradient(circle, var(--mmg-price-accent) 7px, transparent 7.5px);
    cursor: ew-resize;
    pointer-events: auto;
}

.mmg-price .mmg-price-track input[type='range']:focus {
    z-index: 1;
}

.mmg-price .mmg-price-track input[type='range']:focus-visible {
    outline: 2px solid var(--mmg-price-accent);
    outline-offset: 2px;
}

.mmg-price .mmg-price-label {
    margin-block: 0 10px;
    color: #5d6470;
    font-size: 14px;
}

.mmg-price button.button {
    width: 100%;
}

.mmg-price-reset {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: var(--mmg-blue);
    text-decoration: underline;
}
