$sidebarWidth: 300px;
$sidebarWidthSmall: 44px;

html,
body {
    background: transparent;
}

#settings>.window-base {
    background: var(--page-background);
    background: none;
    color: var(--tray-text);
    font-family: 'Segoe UI', sans-serif;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding-top: 0px;
    box-sizing: border-box;
    border: 1px solid var(--window-border);
    user-select: none;
    overflow: hidden;
}

#page {
    overflow: auto;
    padding: 20px;
    box-sizing: border-box;
    height: 100%;
    background: var(--page-background);
    padding-top: 30px;
    flex: 1;
    max-height: 100vh;
    min-height: 100vh;
    border-top: 30px solid var(--page-background);
    position: relative;
    top: -30px;
}


::-webkit-scrollbar {
    width: 10px;
}

/* Track */
::-webkit-scrollbar-track {}

/* Handle */
::-webkit-scrollbar-thumb {
    background: rgba(122, 122, 122, 1);
}

::-webkit-scrollbar-thumb:window-inactive {
    background: rgba(122, 122, 122, 0.5);
}



// Titlebar
.window-titlebar {
    box-sizing: border-box;
    width: calc(100% - 2px);
    padding: 0 0px;
    overflow: visible;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    user-select: none;
    zoom: 1;
    line-height: 22px;
    height: 30px;
    display: flex;
    position: static;
    margin: 1px 0 0 1px;
    top: 1px;
    left: 1px;
    z-index: 100;

    @media (max-width: 700px) {
        background: var(--page-background);
    }

    .appIcon {
        width: 16px;
        height: 16px;
        background: url('../../src/assets/logo.png') center center no-repeat;
        background-size: contain;
        margin-right: 10px;
    }

    .titlebar-drag-region {
        top: 0;
        left: 0;
        display: block;
        position: absolute;
        width: 100%;
        height: 30px;
        z-index: -1;
        -webkit-app-region: drag
    }

    .window-title {
        font-size: 12px;
        padding: 0 10px;
        display: flex;
        align-items: center;
        z-index: 4;
        opacity: 1;
        transition: opacity 0.2s;
        @media (max-width: 880px) {
            opacity: 0;
        }
    }

    .window-controls-container {

        display: flex;
        flex-grow: 0;
        flex-shrink: 0;
        text-align: center;
        position: relative;
        z-index: 3000;
        -webkit-app-region: no-drag;
        height: 100%;
        width: 138px;
        margin-left: auto;


        .window-icon-bg {
            display: inline-block;
            -webkit-app-region: no-drag;
            height: 100%;
            width: 33.34%;

            &:hover .window-icon {
                background: var(--titlebar-icon-hover);
            }

            &:hover {
                background-color: rgba(122, 122, 122, .2)
            }
        }

        .window-icon {
            background: var(--titlebar-icon);
            height: 100%;
            width: 100%;
            -webkit-mask-size: 23.1%;
            -webkit-mask-size: 10px;
        }

        .window-close {
            -webkit-mask: url("data:image/svg+xml;charset=utf-8,%3Csvg width='11' height='11' viewBox='0 0 11 11' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6.279 5.5L11 10.221l-.779.779L5.5 6.279.779 11 0 10.221 4.721 5.5 0 .779.779 0 5.5 4.721 10.221 0 11 .779 6.279 5.5z' fill='%23000'/%3E%3C/svg%3E") no-repeat 50% 50%
        }

        .window-unmaximize {
            -webkit-mask: url("data:image/svg+xml;charset=utf-8,%3Csvg width='11' height='11' viewBox='0 0 11 11' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 8.798H8.798V11H0V2.202h2.202V0H11v8.798zm-3.298-5.5h-6.6v6.6h6.6v-6.6zM9.9 1.1H3.298v1.101h5.5v5.5h1.1v-6.6z' fill='%23000'/%3E%3C/svg%3E") no-repeat 50% 50%
        }

        .window-maximize {
            -webkit-mask: url("data:image/svg+xml;charset=utf-8,%3Csvg width='11' height='11' viewBox='0 0 11 11' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 0v11H0V0h11zM9.899 1.101H1.1V9.9h8.8V1.1z' fill='%23000'/%3E%3C/svg%3E") no-repeat 50% 50%
        }

        .window-minimize {
            -webkit-mask: url("data:image/svg+xml;charset=utf-8,%3Csvg width='11' height='11' viewBox='0 0 11 11' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 4.399V5.5H0V4.399h11z' fill='%23000'/%3E%3C/svg%3E") no-repeat 50% 50%
        }

        .window-icon-bg.window-close-bg:hover {
            background-color: rgba(232, 17, 35, .9)
        }

        .window-icon.window-close:hover {
            background-color: #fff !important;
        }



    }

}

.window-base-inner {
    display: flex;
}


select,
input {
    -webkit-appearance: none;
    background: var(--page-background);
    color: var(--tray-text);
    border: 2px solid var(--input-border);
    outline: none;
    padding: 8px;
    line-height: 1.3;
    font-size: 14px;
    font-family: inherit;
    font-weight: 400;
    margin-top: 10px;
    margin-bottom: 15px;
    box-sizing: border-box;

    &:hover {
        border-color: var(--input-border-hover);
    }

    &:active {
        background: var(--input-active-background);
    }
}

input[type="text"] {
    min-width: 235px;
}

input[type="checkbox"] {
    width: 50px;
    padding: 3px;
    border-radius: 20px;

    &:before {
        content: '';
        display: block;
        width: 12px;
        height: 12px;
        border-radius: 10px;
        background: var(--input-border-hover);
        transform: translateX(0px);
        transition: transform 0.166s;
    }

    &[data-checked="true"] {
        background: var(--system-accent-color);
        border-color: var(--system-accent-color);

        &:before {
            background: white;
            transform: translateX(28px);
        }
    }
}

input[type="time"] {
    padding: 5px 5px 5px 10px;
    margin-right: 5px;
    line-height: 1;
    @media screen and (prefers-color-scheme: dark) {
        &::-webkit-calendar-picker-indicator {
            background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxNCIgaGVpZ2h0PSIxNCIgdmlld0JveD0iMCAwIDI0IDI0Ij48cGF0aCBmaWxsPSIjRkZGRkZGIiBkPSJNMTEuOTkgMkM2LjQ3IDIgMiA2LjQ4IDIgMTJzNC40NyAxMCA5Ljk5IDEwQzE3LjUyIDIyIDIyIDE3LjUyIDIyIDEyUzE3LjUyIDIgMTEuOTkgMnpNMTIgMjBjLTQuNDIgMC04LTMuNTgtOC04czMuNTgtOCA4LTggOCAzLjU4IDggOC0zLjU4IDgtOCA4eiIvPjxwYXRoIGQ9Ik0wIDBoMjR2MjRIMHoiIGZpbGw9Im5vbmUiLz48cGF0aCBmaWxsPSIjRkZGRkZGIiBkPSJNMTIuNSA3SDExdjZsNS4yNSAzLjE1Ljc1LTEuMjMtNC41LTIuNjd6Ii8+PC9zdmc+);
        }
    }
}


label {
    font-size: 14px;
    display: block;

    &+p {
        margin-top: 2px;
    }
}



.sectionTitle {
    font-size: 28px;
    font-weight: 400;
    margin-bottom: 20px;
    line-height: 1;
}

.sectionSubtitle {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
    line-height: 1;
    display: flex;

    .icon {
        font-size: 22px;
        font-weight: 400;
        margin-top: -1px;
    }

    div+div {
        margin-left: 10px;
    }
}

.pageSection {
    padding-bottom: 40px;
    max-width: 800px;

    &[data-active] {
        display: none;
    }

    &[data-active="true"] {
        display: block;
    }

    &.debug {
        user-select: text;
    }
}

.monitorItem {
    max-width: 320px;
    animation: sliderFadeIn 0.4s;

    @keyframes sliderFadeIn {
        0% {
            opacity: 0;
        }

        33% {
            opacity: 0;
        }

        100% {
            opacity: 1;
        }
    }
}

.monitorItem-list {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
}

.adjustmentTimes {
    padding-top: 5px;

    .item {
        padding-top: 20px;
        margin-top: 20px;
        border-top: 1px solid var(--page-text-mid);

        .monitor-item {
            max-width: 320px;
        }

        &+.item {}
    }

    select {
        margin-right: 4px;
    }
}

.hotkey-item {
    padding-top: 20px;
    margin-top: 20px;
    border-top: 1px solid var(--page-text-mid);
}

.detected-vcp-codes {

    .vcp-code {

        & + .vcp-code {
            margin-top: 10px;
        }
    }

    .supported-values {
        font-size: 16px;
        opacity: 0.7;
    }
}

p {
    font-size: 14px;
    color: var(--page-text-mid);

    b,
    strong {
        color: var(--page-text);
    }
}

a {
    text-decoration: underline;
    cursor: pointer;
    color: var(--page-text);

    &:hover {
        color: var(--page-text-mid);
    }
}

select {
    appearance: auto;
}

.icon {
    font-family: "Segoe MDL2 Assets";

    &.red {
        color: red;
    }

    &.green {
        color: green;
    }

    &.vfix {
        display: inline-block;
        position: relative;
        top: 2px;
    }
}


.button {
    background: var(--button-background);
    border: 2px solid var(--button-background);
    line-height: 0;
    padding: 15px 12px;
    //margin-top: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;

    .icon {
        margin-right: 8px;
    }

    &:hover {
        border-color: var(--input-border);
    }
}

.inputToggle-generic {
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;

    .text {
        font-size: 14px;
        line-height: 1;
        margin-top: -5px;
        margin-left: 8px;
    }

    &[data-textside="left"] {
        input {
            order: 2;
        }
        .text {
            margin-left: 0;
            margin-right: 8px;
        }
    }
}


.reorderList {
    max-width: 360px;
    width: 100%;
    border: 1px solid var(--window-border);

    .sectionSubtitle {
        padding: 15px;
        margin: 0;
    }

    .no-displays-message {
        margin: 10px 12px -10px 12px;
    }
}

.changelog {
    white-space: pre-wrap;
    padding: 10px 20px 20px;
    margin: 20px 0 5px;
    border-top: 1px solid var(--page-text-mid);
    border-bottom: 1px solid var(--page-text-mid);
    line-height: 0;

    p,
    h1,
    h2,
    h3,
    h4,
    h5,
    ul,
    ol {
        line-height: 1.4;
    }
}

.progress-bar {
    position: relative;
    width: 100%;
    height: 5px;
    max-width: 320px;
    background: var(--window-border);

    &>div {
        position: absolute;
        top: 0;
        left: 0;
        width: 0%;
        height: 100%;
        background: var(--system-accent-color);
    }
}


.icons-row {
    display: flex;
    margin: 3px -5px;
}

.icon-option {
    margin: 5px;
    cursor: pointer;
    user-select: none;

    img {
        width: 32px;
        padding: 10px;
        background: #333;
        background-color: var(--system-accent-dark2);
        border: 2px solid #333;
        border-color: var(--system-accent-dark1);
        filter: saturate(0);
    }

    &[data-active="true"] {
        img {
            background: var(--system-accent-medium);
            border-color: var(--system-accent-medium-dark);
            background-color: var(--system-accent-dark1);
            border-color: var(--system-accent-light2);
            filter: saturate(1);
        }
    }
}


.hotkey-monitors {

    .hotkey-item {
        margin-top: 30px;
    }

    .name {}

    .row {
        display: flex;
        //justify-content: end;
        align-items: center;
        line-height: 1;

        &>* {
            margin-right: 5px;
        }

    }

    .title {}

    input[type="text"] {
        padding: 6px;
        font-size: 14px;
        height: auto;
        box-sizing: border-box;
        line-height: 1;

        &:focus {
            border-color: var(--system-accent-color);
        }
    }

    input[type="button"] {
        @extend .button;
        padding: 8px;
        line-height: 1;
    }
}

// DDC/CI Features 
.feature-row {
    display: flex;
    justify-content: flex-start;
    .monitor-item {
        flex: 1;
    }
}
.feature-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 28px;
    padding-right: 18px;
}
.feature-toggle-list {
    padding-top: 1px;
}
.feature-toggle-row {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 6px 0;
    input {
        margin: 0;
    }
}
.feature-toggle-set {
    margin: 0 0 0 -20px;
    padding: 0 20px;
    transition:  margin 0.3s, padding 0.3s, background 0.3s;
    background-color: rgba(0,0,0,0);
}
.feature-toggle-set[data-active="true"] {
    margin-bottom: 10px;
    margin-top: 10px;
    background: var(--page-section-bg);
    padding: 10px 20px;
    margin-left: -19px;
    width: calc(100% - 2px);
}
.feature-toggle-settings {
    padding: 0;
}
.feature-toggle-label {
    padding-left: 15px;
    flex: 1;
    .icon {
        margin-right: 8px
    }
}
.profile-monitors {
    margin: 13px 0;
    &:empty {
        margin: 0;
    }
}
.input-row {
    display: flex;
    justify-content: flex-start;
    align-items: stretch;
    gap: 10px;

    & > * {
        //flex: 1;
    }

    .field {
        select {
            width: 100%;
        }
    }

    input[type="text"], input[type="number"], input[type="button"], input[type="time"], select {
        margin: 0;
        width: auto;
        box-sizing: border-box;
        height: 40px;
    }

    input[type="button"] {
        width: auto;
    }

    label + input, label + select {
        margin-top: 8px !important;
    }

    .monitor-item {
        flex: 1;
        & + .monitor-item {
            margin-top: 0;
        }
    }

    & + .input-row  {
        margin-top: 15px;
    }
}


.add-feature-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: rgba(50, 50, 50, 0.95);

    display: none;

    &[data-show="true"] {
        animation: featureToggleSettingsIn 0.3s;
        display: flex;
    }

    .inner {
        background-color: var(--page-background);
        padding: 20px;
        border-radius: 3px;
        width: 100%;
        max-width: 500px;
    }

    .input-row {
        justify-content: flex-end;
    }

    input[type="text"] {
        width: 100%;
    }
    
    p {
        margin-top: 0;
    }
}

html body[data-is-win11="true"] {
    .add-feature-overlay {
        backdrop-filter: blur(5px);
    }
}

.hotkey-combo-input {
    margin: -10px 0 -12px;
}

.hotkey-values-list {
    
    label {
        margin-bottom: 8px;
    }
    
    input[type="button"] {
        margin-left: 8px;
    }
    .hotkey-value {
        margin-bottom: 8px;
    }
}

.hotkey-action-fields {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;

    .input-row {
        margin-top: 0 !important;
    }
}

.hotkey-action-type {

    select {
        width: 100%;
    }
}

.hotkey-action-code {
    input {
        min-width: 220px;
    }
}

.hotkey-action-value {
    input {
        min-width: 100px;
    }
}

.hotkey-action-values {
    width: 100%;
    padding-top: 10px;
    input {
        min-width: 100px;
    }
}

.hotkey-monitors-list {
    margin: -35px 0px auto 0px;
    width: 200px;
    background: rgba(122, 122, 122, .1);
    padding: 25px;
    order: 2;
    border-radius: 4px;
}


// Sidebar
#sidebar {
    position: relative;
    top: -30px;
    left: 0px;
    width: 300px;
    padding-top: 30px;
    height: calc(100vh - 2px - 30px);
    background: var(--tray-background-base);
    transition: width 0.2s;
    overflow: hidden;
    z-index: 3;
    display: flex;
    justify-content: flex-start;
    flex-direction: column;

    .item {
        width: 100%;
        display: flex;
        flex-direction: row;
        justify-items: end;
        align-items: center;
        padding: 13px;
        box-sizing: border-box;
        line-height: 1;

        &[data-type="debug"] {
            margin-top: auto;

            .icon {
                opacity: 0.1;
            }

            .label {
                opacity: 0;
            }

            &[data-active="true"] {

                .icon,
                .label {
                    opacity: 1;
                }
            }
        }

        .icon {
            padding-right: 13px;
            font-size: 18px;
            opacity: 1;
            transition: opacity 0.2s;
        }

        .label {
            margin-top: -2px;
            font-size: 14px;
            opacity: 1;
            transition: opacity 0.2s;
            white-space: pre;
        }

        &:hover {
            background: var(--sidebar-item-hover);
        }

        &:active {}

        &:before {
            content: ' ';
            width: 4px;
            min-width: 4px;
            height: 23px;
            display: block;
            position: relative;
            left: -13px;
            transform-origin: 0 50%;
            transform: scaleX(0);
            background: var(--system-accent-color);
            transition: transform 0.2s, opacity 0.2s;
            opacity: 0;
        }

        &[data-active='true'] {
            &:before {
                transform: scaleX(1);
                opacity: 1;
            }
        }
    }

    @media (max-width: 880px) {
        width: $sidebarWidthSmall;

        .item {
            &:before {
                margin-right: -4px;
            }

            .label {
                opacity: 0 !important;
            }
        }
    }
}

body[data-transparent=true][data-acrylic=true] .window-base #sidebar {
    //--tray-background: var(--tray-background-blur) !important;
    background: none !important;
}



// Sun Valley tweaks
body[data-fluent-icons="true"] {
    .window-titlebar .window-controls-container {
        .window-close {
            -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http%3A//www.w3.org/2000/svg' width='11' height='11' viewBox='0 0 11 11'%3E%3Cpath d='M5.5,6.28.94,10.84A.53.53,0,0,1,.55,11a.51.51,0,0,1-.39-.16A.51.51,0,0,1,0,10.45a.53.53,0,0,1,.16-.39L4.72,5.5.16.94A.53.53,0,0,1,0,.55.54.54,0,0,1,0,.33.66.66,0,0,1,.16.16.57.57,0,0,1,.34,0,.52.52,0,0,1,.55,0,.53.53,0,0,1,.94.16L5.5,4.72,10.06.16A.53.53,0,0,1,10.45,0a.46.46,0,0,1,.21,0,.55.55,0,0,1,.3.3.46.46,0,0,1,0,.21.53.53,0,0,1-.16.39L6.28,5.5l4.56,4.56a.53.53,0,0,1,.16.39.52.52,0,0,1,0,.21.57.57,0,0,1-.12.18.52.52,0,0,1-.17.12.54.54,0,0,1-.22,0,.53.53,0,0,1-.39-.16Z'/%3E%3C/svg%3E") no-repeat 50% 50%
        }
        .window-unmaximize {
            -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http%3A//www.w3.org/2000/svg' width='11' height='11' viewBox='0 0 11 11'%3E%3Cpath d='M1.62,11A1.5,1.5,0,0,1,1,10.87a1.68,1.68,0,0,1-.51-.36A1.68,1.68,0,0,1,.13,10,1.5,1.5,0,0,1,0,9.38V3.82A1.5,1.5,0,0,1,.13,3.2a1.82,1.82,0,0,1,.36-.51A1.68,1.68,0,0,1,1,2.33a1.64,1.64,0,0,1,.62-.13H7.18a1.68,1.68,0,0,1,.62.13,1.57,1.57,0,0,1,.51.36,1.57,1.57,0,0,1,.36.51,1.68,1.68,0,0,1,.13.62V9.38a1.64,1.64,0,0,1-.13.62,1.68,1.68,0,0,1-.36.51,1.82,1.82,0,0,1-.51.36,1.5,1.5,0,0,1-.62.13ZM7.15,9.9a.78.78,0,0,0,.21,0,.55.55,0,0,0,.3-.3.46.46,0,0,0,0-.21V3.85a.49.49,0,0,0,0-.21.55.55,0,0,0-.3-.3.49.49,0,0,0-.21,0H1.65a.46.46,0,0,0-.21,0,.55.55,0,0,0-.3.3.78.78,0,0,0,0,.21v5.5a.65.65,0,0,0,0,.21.55.55,0,0,0,.3.3.65.65,0,0,0,.21,0ZM9.9,3.26a2,2,0,0,0-.18-.84A2.21,2.21,0,0,0,8.54,1.27,2.21,2.21,0,0,0,7.7,1.1H2.29A1.66,1.66,0,0,1,2.54.65,1.66,1.66,0,0,1,2.89.3,1.57,1.57,0,0,1,3.34.08,1.81,1.81,0,0,1,3.85,0H7.7A3.25,3.25,0,0,1,9,.26,3.3,3.3,0,0,1,10,1a3.15,3.15,0,0,1,.71,1A3.3,3.3,0,0,1,11,3.3V7.15a1.81,1.81,0,0,1-.08.51,1.57,1.57,0,0,1-.22.45,1.82,1.82,0,0,1-.8.6Z'/%3E%3C/svg%3E") no-repeat 50% 50%
        }
        .window-maximize {
            -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http%3A//www.w3.org/2000/svg' width='11' height='11' viewBox='0 0 11 11'%3E%3Cpath d='M1.62,11A1.5,1.5,0,0,1,1,10.87a1.68,1.68,0,0,1-.51-.36A1.68,1.68,0,0,1,.13,10,1.5,1.5,0,0,1,0,9.38V1.62A1.5,1.5,0,0,1,.13,1,1.68,1.68,0,0,1,.49.49,1.68,1.68,0,0,1,1,.13,1.5,1.5,0,0,1,1.62,0H9.38A1.5,1.5,0,0,1,10,.13a1.68,1.68,0,0,1,.51.36,1.68,1.68,0,0,1,.36.51,1.5,1.5,0,0,1,.13.62V9.38a1.5,1.5,0,0,1-.13.62,1.84,1.84,0,0,1-.87.87,1.5,1.5,0,0,1-.62.13ZM9.35,9.9a.65.65,0,0,0,.21,0,.55.55,0,0,0,.3-.3.65.65,0,0,0,0-.21V1.65a.65.65,0,0,0,0-.21.55.55,0,0,0-.3-.3.65.65,0,0,0-.21,0H1.65a.65.65,0,0,0-.21,0,.55.55,0,0,0-.3.3.65.65,0,0,0,0,.21v7.7a.65.65,0,0,0,0,.21.55.55,0,0,0,.3.3.65.65,0,0,0,.21,0Z'/%3E%3C/svg%3E") no-repeat 50% 50%
        }
        .window-minimize {
            -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http%3A//www.w3.org/2000/svg' width='11' height='11' viewBox='0 0 11 11'%3E%3Cpath d='M.55,5.5a.46.46,0,0,1-.21,0,.55.55,0,0,1-.3-.3A.46.46,0,0,1,0,5a.52.52,0,0,1,0-.21.71.71,0,0,1,.12-.18.57.57,0,0,1,.18-.12.46.46,0,0,1,.21,0h9.9a.46.46,0,0,1,.21,0,.57.57,0,0,1,.18.12.71.71,0,0,1,.12.18A.52.52,0,0,1,11,5a.46.46,0,0,1,0,.21.55.55,0,0,1-.3.3.46.46,0,0,1-.21,0Z'/%3E%3C/svg%3E") no-repeat 50% 50%
        }
    }
    .icon {
        font-family: "Segoe Fluent Icons", "Segoe MDL2 Assets";
    }
}

// Windows 11 style
body[data-is-win11="true"] {
    background-color: var(--page-background);
    width: 100vw;
    height: 100vh;
    margin: 0;

    #settings > .window-base {
        background-color: var(--page-background);
        background: none;
        font-family: 'Segoe UI Variable Text', 'Segoe UI';
    }

    &[data-segoe-u-i-variable="true"] {
        .window-titlebar .window-title {
            font-family: "Segoe UI Variable", "Segoe UI";
            font-weight: 400;
            font-size: 12px;
        }
        #sidebar .item .label {
            font-family: "Segoe UI Variable", "Segoe UI";
            font-size: 13px;
            font-weight: 400;
        }
        .sectionTitle {
            font-weight: 500;
            font-family: "Segoe UI Variable Display", "Segoe UI";
            font-size: 28px;
        }
    }


    #sidebar, #page {
        background: none !important;
    }
    #sidebar {
        padding: 45px 0 15px 15px;
        padding-top: 45px;
        height: calc(100vh - 2px - 60px);
        .item {
            border-radius: 6px;
            padding: 8px 10px;
            margin: 4px 0;
            line-height: 1;

            &:before {
                background-color: var(--system-accent-dark2);
                border-radius: 10px;
                left: -10px;
                @media screen and (prefers-color-scheme: dark) {
                    background-color: var(--system-accent-light2);
                }
            }

            &[data-active='true'] {
                background: var(--sidebar-item-hover);
            }

            &[data-type="debug"] {
                margin-top: auto;
            }
        }
    }
    #page {
        padding-top: 19px;
        border-top-color: transparent;
    }
    .button {
        background: var(--button-background);
        color: var(--page-text);
        border-radius: 6px;
        border: 0;
        box-shadow: inset 0 0.25px 0 0.5px var(--button-border), 0 0.5px 1px 0 rgba(0, 0, 0, 0.203);
        font-weight: 400;
        box-sizing: border-box;
        &:hover {
            background: var(--button-highlight);
        }
        &.button-primary {
            background-color: var(--button-primary-background);
            color: var(--page-background);
            &:hover {
                background-color: var(--button-primary-background-hover);
            }
        }
        &.full-width {
            width: 100%;
        }
    }
    .window-titlebar .window-title {
        position: relative;
        top: 8px;
        left: 10px;
        opacity: 1 !important;
    }
    input, select {
        border-radius: 5px;
        border-width: 1.5px;
        background-color: var(--page-section-bg);
        border-color: var(--button-border);
        transition: background 0.1s;

        &[type="text"] {
            border-bottom: 1px solid var(--page-text-mid);
        }

        &[type="range"] {
            background-color: transparent !important;
        }

        &:hover {
            background-color: var(--button-highlight);
        }
    }
    option {
        background: white;
        color: black;
    }
    input[type="checkbox"] {
        width: 44px;
        border-width: 1.5px;
        border-radius: 50px;
        border-color: var(--input-border);

        &::before {
            background-color: var(--input-border);
            transform-origin: center;
            transform: translateY(-0.2px);
        }

        &:hover {
            &:before {
                transform: translateY(-0.2px) scale(1.2);
            }
        }

        &[data-checked="true"] {  
            background-color: var(--system-accent-dark2);
            border-color: var(--system-accent-dark2);
            @media screen and (prefers-color-scheme: dark) {
                background-color: var(--system-accent-light2);
                border-color: var(--system-accent-light2);
            }
            &:before {
                transform: translateX(24px) translateY(-0.2px);
                background-color: var(--page-background);  
            }
            &:hover {
                &:before {
                    transform: translateX(22px) translateY(-0.2px) scale(1.2);
                }
            }
        }
    }
    .icon-option img {
        border-radius: 4px;
        background-color: #81818145;
        border-color: var(--button-border);
    }
    .icon-option[data-active=true] img {
        background: var(--system-accent-medium);
        border-color: var(--system-accent-medium-dark);
        background-color: var(--system-accent-dark1);
        border-color: var(--system-accent-light2);
    }
    .reorderList {
        border-color: var(--button-border);
        border-width: 1.5px;
        border-width: 0;
        border-radius: 5px;
        max-width: none;
    }
    .pageSection {
        padding-bottom: 40px;
        max-width: 1000px;
        width: 100%;

        &.is-panel {
            background: var(--page-section-bg);
            border-radius: 4px;
            padding: 20px;
            margin-bottom: 20px;
            box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
        }
    }
    .settings-page {
        display: flex;
        flex-direction: column;
        align-items: center;
        animation: pageSectionIn 0.6s cubic-bezier(0.075, 0.82, 0.165, 1);
        @keyframes pageSectionIn {
            0% { opacity: 0; transform: translateY(90px); }
            80% { opacity: 1; }
            100% { transform: translateY(0px); }
        }
    }
    ::-webkit-scrollbar-thumb {
        border-radius: 20px;
    }

    &[data-focused="false"] {
        #mica img {
            opacity: 0;
        }
    }
    .changelog {
        border-color: #8181818c;
    }
}

#mica {
    background: none !important;
    img {
        transition: opacity 0.5s;
        opacity: 1;
    }
}

body[data-is-win11="false"] {
    .win11only {
        display: none;
    }
}

body[data-is-win11="true"] {
    .win10only {
        display: none;
    }
}

.try-catch-failure {
    user-select: auto;
}