:root {
    --ui-color-1: rgb(32, 35, 38);
    --ui-color-2: rgb(53, 53, 53);
    --ui-color-3: rgb(46, 46, 46);
    --ui-color-4: rgb(32, 35, 38);

    --ui-color-close-x: rgb(132, 94, 94);

    --fg-color: white;
    --terminal-color: lightgreen;

    --bg-color: #282828;
}

@media (prefers-color-scheme: light) {
    :root {
        --ui-color-1: rgb(255, 254, 245);
        --ui-color-2: rgb(255, 253, 235);
        --ui-color-3: rgb(255, 253, 240);
        --ui-color-4: rgb(61, 61, 58);
        --ui-color-close-x: rgb(210, 114, 114);
        --fg-color: black;

        --terminal-color: green;
        --bg-color: #282828;
    }
}


html,
body {
    margin: 0;
    height: 100%;
    width: 100%;
    background-color: var(--bg-color);
    background-image: url('../images/gruvbox_grid.png');

    background-repeat: repeat-y;
    background-attachment: fixed;
    overflow: hidden;
}

@media (prefers-color-scheme: light) {

    html,
    body {
        background-image: url('../images/swapped.png');
    }
}



html * {
    overscroll-behavior: none;
    user-select: none;
}

.use-filter .glass {
    filter: url(#liquidGlass);
}



.glass {
    backdrop-filter: blur(var(--glass-opacity, 8px));
    -webkit-backdrop-filter: blur(var(--glass-opacity, 8px));
    /* filter: url(#liquidGlass); */
    background-color: color-mix(in srgb, var(--glass-color, var(--ui-color-2)) 50%, transparent);
    /* background-color: transparent; */
    /* opacity: 90%; */
}

.glass::after {
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.25),
        inset 1px 0 0 rgba(255, 255, 255, 0.1),
        inset -1px 0 0 rgba(255, 255, 255, 0.05),
        inset 0 -1px 0 rgba(255, 255, 255, 0.05),
        0 0 0 1px rgba(0, 0, 0, 0.4),
        inset -2px -2px 6px rgba(0, 0, 0, 0.5)
}

.window-wrapper {
    overflow: hidden;
    border-radius: 15px;
    position: fixed;
    cursor: grab;
    user-select: none;
    z-index: 2;
    top: 25px;
    left: 100px;
    transition: scale 400ms ease-in-out, outline-color 100ms ease-out;
    

    /* transition: left 0.5s cubic-bezier(0.34, 1.56, 0.64, 1),
                top 0.5s cubic-bezier(0.34, 1.56, 0.64, 1); */

    /*  top 10ms ease-out, left 10ms ease-out */
}

.window-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 15px;
    pointer-events: none;
    z-index: 999;
}

.window-wrapper:active {
    cursor: grabbing;
}

.window-wrapper:hover {
    scale: 1.01;
}

.window-close-bar {
    background-color: var(--ui-color-1);
    border-bottom: none;
}

.window-close-bar button {
    border-radius: 15px;
    margin: 5px;
    margin-left: 10px;
    color: var(--fg-color);
    background-color: var(--ui-color-close-x);
    border: none;
    cursor: pointer;
    transition: text-shadow 400ms;
}

.window-close-bar :hover {
    text-shadow: 2px 2px 4px var(--bg-color);
    /* text-size-adjust: 120%; */
}

.window-resize {
    position: absolute;
    right: 4px;
    bottom: 4px;
    width: 16px;
    height: 16px;
    cursor: se-resize;
    font-size: 18px;
    line-height: 16px;
    color: black;
    opacity: 0;
    transition: opacity 0.2s;
    user-select: none;
}

.window-resize::after {
    content: '⌟';
}

.window-wrapper:hover .window-resize {
    opacity: 1;
}

.window-content {
    border-top: none;
    overflow: scroll;
    box-sizing: border-box;
    isolation: isolate;
    cursor: auto;

}

.window-content * {
    width: 100%;
    height: 100%;
    border-radius: inherit;
    color: var(--fg-color);
    background: none;
    outline: none;
}

.window-content pre {
    margin-left: 10px;
    user-select: text;
}