
html {
    font-family: "Tahoma", sans-serif;
    font-size: 12pt;

    background: #ccc url("../images/background.gif");
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
}

#screen {
    position: relative;
    width: 640px;
    height: 480px;
    overflow: clip;
    
    user-select: none;
    
    margin: 8px auto auto;
    
    box-shadow: rgba(0, 0, 0, 0.6) 0px 0px 15px 10px;
}

#screen.fullscreen {
    margin: auto;
}

/* Cursor configurations (Assuming default) */
#screen.cursor-shown {
    cursor: url("../images/cursors/default.gif"), default;
}

#wallpaper_container {
    --wallpaper-colour: #4f8675;
    
    position: absolute;
    top: 0; left: 0;
    background: var(--wallpaper-colour, black);
    width: 100%;
    height: 100%;
    
    z-index: -1000000;
    
    pointer-events: none;
}

/* Wallpaper configurations */

/* Default */
#wallpaper_container img, #wallpaper_container.fill img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#wallpaper_container.solid-colour {
}

#wallpaper_container.solid-colour img {
    display: none;
}

/* End */

#window_root {
    position: relative;
    height: 100%;
    width: 100%;
}

.bluescreen {
    z-index: 2147483640;    /* 7 below the 32-bit integer limit */
    
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    
    padding: 12pt 32pt;
    
    display: block;
    
    background: rgba(59, 108, 92, 0.95);
    color: white;
}

.bluescreen h1 {
    font-size: 64pt;
    margin: 0 0 12pt;
}

.bluescreen .error-code {
    font-family: monospace;
}

/* Windows and taskbar */
.window {
    width: fit-content;
    height: fit-content;
    overflow: auto;
    
    position: absolute;
    
    outline: #eee 1pt solid;
}

.window .titlebar {
    display: flex;
    background: linear-gradient(to right, #467967, #77b19d);
    color: white;
    height: 18px;
    font-size: 8pt;
    line-height: 18px;
    padding: 0 2px;
    font-weight: bold;
}

.window .titlebar .title {
    flex: 1;
}

.window .titlebar .controls {
    display: flex;
    align-items: center;
}

.window .titlebar .controls button {
    all: unset;
    box-sizing: border-box;
    background: url("/assets/images/caption-buttons.png") 0 0;
    aspect-ratio: 1;
    width: 16px;
    height: 14px;
    position: relative;
    image-rendering: pixelated;
}
.window .titlebar .controls button::after {
    content: "";
    width: 16px;
    height: 14px;
    position: absolute;
    background-position: 32px 0;
    background-repeat: no-repeat;
    top: 0;
    left: 0;
}
.window .titlebar .controls button:active {
    background-position: -16px 0;
}
.window .titlebar .controls button:active::after {
    top: 1px;
    left: 1px;
}
.window .titlebar .controls button[aria-label=Close] {
    margin-left: 2px;
}
.window .titlebar .controls button[aria-label=Close]::after {
    background: url("/assets/images/caption-buttons.png");
    background-position: -32px 0px;
}
.window .titlebar .controls button[aria-label=Maximise]::after {
    background: url("/assets/images/caption-buttons.png");
    background-position: 0px 14px;
}
.window .titlebar .controls button[aria-label=Minimise]::after {
    background: url("/assets/images/caption-buttons.png");
    background-position: -16px 14px;
}
.window .titlebar .controls button[aria-label=Help]::after {
    background: url("/assets/images/caption-buttons.png");
    background-position: -32px 14px;
}

.window .window-content {
    background: white;
    color: black;
    resize: both;
    overflow: auto;
    display: flex;
    padding: 1px;
}

.window[data-resizable="no"] .window-content {
    resize: none;
}

.window.window-borderless {
    outline: unset;
    
}
.window.window-borderless .titlebar {
    display: none;
}

.taskbar {
    background: #ccc;
    border-top: 2px solid #dfdfdf;
    height: 28px;
    z-index: 1000000;
}

.taskbar .window-content {
    height: 100%;
    background: transparent;
}

.fix-to-bottom {
    position: absolute;
    bottom: 0;
}

.fill-width {
    width: 100%;
}