//
// Inputs
//

.input--range {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    position: relative;

    .progress {
        background: var(--system-accent-medium);
        height: 2px;
        width: 100%;
        position: absolute;
        top: 50%;
        left: 0px;
        margin-top: -1px;
        pointer-events: none;
    }

    .rangeGroup {
        flex: 2;
        position: relative;
    }

    .range {
        display: block;
        appearance: none;
        width: 100%;
        background: transparent;
        border: none;
        padding: 0;
        margin: 0 15px 0 0;
        -webkit-appearance: none;

        &:hover {
            &::-webkit-slider-thumb {
                background: var(--tray-text);
            }
        }

        &::-webkit-progress-value {
            background-color: var(--system-accent-light);
        }

        &:focus {
            outline: none;
        }

        &::-webkit-slider-thumb {
            -webkit-appearance: none;
            height: 24px;
            width: 8px;
            box-sizing: content-box;
            border-radius: 20px;
            background: var(--system-accent-color);
            margin-top: -12px;
            z-index: 3;
            position: relative;
        }

        &::-webkit-slider-runnable-track {
            width: 100%;
            height: 2px;
            background: var(--slider-track-color);
            border-radius: 0px;
            transition: background-color 0.1s;
            border-left: 0;
            border-right: 0;
            box-sizing: border-box;

        }

        &::-webkit-slider-container {
            padding: 7px 0;
        }

        &:focus::-webkit-slider-runnable-track {
            //background: var(--slider-track-color-focus);
        }
    }

    .val {
        width: 52px;
        box-sizing: border-box;
        -webkit-appearance: none;
        background: none;
        outline: none;
        border: none;
        font-size: 22px;
        text-align: center;
        color: var(--tray-text);
        font-family: 'Segoe UI Variable Text', 'Segoe UI';
        margin: 0;
        margin-right: -10px;
        margin-left: 5px;

        &::-webkit-inner-spin-button,
        &::-webkit-outer-spin-button {
            -webkit-appearance: none;
            margin: 0;
        }

    }

    &[data-height="short"] {
        padding-top: 4px;
        .val {
            text-align: left;
            padding: 0 0 0 4px;
            font-size: 16px;
            width: 32px;
            margin-left: 12px;
            line-height: 1;
            margin-bottom: -1px;
        }
    }
}


//
// Monitors
//

.no-displays-message {
    margin-top: 13px;
    margin-bottom: 13px;
}

.monitor-item {

    &+.monitor-item {
        margin-top: 20px;
    }

    .name-row {
        display: flex;
        justify-content: flex-start;
        align-items: center;
        width: 100%;

        .title {
            font-size: 16px;
            flex: 1;
        }

        .icon {
            font-family: "Segoe MDL2 Assets";
            font-size: 22px;
            margin-right: 10px;
            margin-bottom: -3px;
        }
    }

    .input--range {
        opacity: 1;
        transition: opacity 0.2s 0.05s;
    }
}

[data-refreshing="true"] .monitor-item .input--range {
    pointer-events: none;
    opacity: 0.35;
}

// Sun Valley tweaks
#root[data-fluent-icons="true"] {

    .monitor-item .name-row .icon {
        font-family: "Segoe Fluent Icons", "Segoe MDL2 Assets";
    }

}

// Windows 11 style
body[data-is-win11="true"]:not(.ignoreWin11) {

    .input--range {
    
        .progress {
            height: 4px;
            border-radius: 50px;
            margin-top: 0px;
            background-color: var(--system-accent-dark1);
            @media screen and (prefers-color-scheme: dark) {
                background-color: var(--system-accent-light2);
            }
        }
    
        .rangeGroup {
        }
    
        .range {
    
            &:hover {
                &::-webkit-slider-thumb {
                    
                }
            }
    
            &::-webkit-progress-value {
                
            }
    
            &:focus {
                
            }
    
            &::-webkit-slider-thumb {
                height: 10px;
                width: 10px;
                border-radius: 50px;
                background-color: var(--system-accent-dark1);
                margin-top: -3px;

                transform: scale(1);
                box-shadow: 0 0 0 4px var(--slider-thumb-border), 0 0.5px 3px 0 rgba(0, 0, 0, 0.603);

                height: 10px;
                width: 10px;

                transition: box-shadow 0.15s, transform 0.15s;
                will-change: box-shadow, transform;
                @media screen and (prefers-color-scheme: dark) {
                    background-color: var(--system-accent-light2);
                }
                &:hover {
                    box-shadow: 0 0 0 2px var(--slider-thumb-border), 0 0.5px 3px 0 rgba(0, 0, 0, 0.603);
                    transform: scale(1.3);
                }
            }
    
            &::-webkit-slider-runnable-track {
                height: 4px;
                border-radius: 8px;
                margin-top: 3px;
                margin-top: 4px;
            }
    
            &::-webkit-slider-container {
                
            }
    
            &:focus::-webkit-slider-runnable-track {
                
            }
        }
    
        .val {
    
            &::-webkit-inner-spin-button,
            &::-webkit-outer-spin-button {

            }
    
        }
    }

}