@charset "UTF-8";

@font-face {
    font-family: CourierPrimeSans;
    src: url("fonts/Courier Prime Sans.ttf") format("truetype");
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: CourierPrimeSans;
    src: url("fonts/Courier Prime Sans Italic.ttf") format("truetype");
    font-weight: normal;
    font-style: italic;
}

@font-face {
    font-family: CourierPrimeSans;
    src: url("fonts/Courier Prime Sans Bold.ttf") format("truetype");
    font-weight: bold;
    font-style: normal;
}

@font-face {
    font-family: CourierPrimeSans;
    src: url("fonts/Courier Prime Sans Bold Italic.ttf") format("truetype");
    font-weight: bold;
    font-style: italic;
}

:root {
    --color: black;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    border: 0;
    outline: 0;
    font-size: 15px;
    line-height: 1.25em;
    font-family: CourierPrimeSans;
    box-sizing: border-box;
    color: black;
    font-weight: normal;
    user-select: none;
}

body {
    display: flex;
    position: fixed;
    width: 100%;
    height: 100%;
}

#interface {
    width: 24rem;
    background-color: rgb(240, 240, 240);
    flex-shrink: 0;
    border-right: 1px solid blue;
}

header, section {
    padding: 1.5rem;
    border-bottom: 1px solid blue;
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
    gap: 0.25rem;
}

section:last-of-type {
    border-bottom: 0;
}

section#process, section#save {
    flex-direction: row;
}

h1 {
    text-transform: uppercase;
}

section > button {
    flex: 1 1 0;
    text-transform: uppercase;
    display: block;
    background-color: rgba(0, 0, 0, 0.1);
    padding: 0.5rem;
    cursor: pointer;
    width: 100%;
    opacity: 1;
    border-radius: 4px;
    border: 1px solid blue;
    border-bottom: 3px double blue;
}

section > button:active {
    border-bottom-width: 1px;
    border-bottom-style: solid;
    margin-top: 2px;
}

section > button[disabled] {
    opacity: 0.35;
    pointer-events: none;
}

#input-image {
    width: 100%;
    aspect-ratio: 1;
    border: 1px solid blue;
    display: flex;
    justify-content: center;
    padding: 1.5rem;
}

#input-image img {
    max-width: 100%;
    object-fit: contain;
}

input[type="file"] {
    display: none;
}

label {
    position: relative;
    height: 1.5em;
    line-height: 1.5em;
    cursor: pointer;
    display: block;
}

label > input[type="number"] {
    float: right;
    width: calc(10ch + 1rem + 2px);
    margin-right: 0.75rem;
    padding: 0 0.5rem;
    text-align: right;
    height: 100%;
    border: 1px solid blue;
    appearance: textfield;
    background-color: transparent;
}

label > input[type=number]::-webkit-inner-spin-button, 
label > input[type=number]::-webkit-outer-spin-button { 
  appearance: none;
}

label > input[type="number"]::selection {
    background-color: dodgerblue;
    color: white;
}

label > button {
    position: absolute;
    height: calc(0.75rem + 0.5px);
    line-height: calc(0.75rem + 0.5px);
    width: calc(0.75rem + 1px);
    right: 0;
    cursor: pointer;
    background-color: transparent;
    box-sizing: border-box;
    color: blue;
}
    
label > button.up {
    border-top: 1px solid blue;
    border-right: 1px solid blue;
    border-bottom: 1px solid blue;
    top: 0;
}

label > button.down {
    border-right: 1px solid blue;
    border-bottom: 1px solid blue;
    bottom: 0;
}

label > input[type="checkbox"] {
    aspect-ratio: 1;
    height: calc(100% - 0.75rem);
    appearance: none;
    margin: 0.375rem 0.25rem;
    float: right;
    cursor: pointer;
    /* border-radius: 1rem; */
    outline: 1px solid blue;
    outline-offset: 0.25rem;
}

label > input[type="checkbox"]:checked {
    background-color: blue;
}

label > input[type="number"]:focus, button:focus {
    border-color: dodgerblue;
    background-color: rgba(0, 0, 0, 0.1);
}

label > input[type="checkbox"]:focus {
    outline-color: dodgerblue;
}

label > input[disabled],
label > button[disabled] {
    opacity: 0.35;
    pointer-events: none;
}

progress {
    width: 100%;
    height: 1.5rem;
    appearance: none;
    border: 1px solid blue;
    background-color: transparent;
}

progress::-webkit-progress-bar {
    background-color: transparent;
}

progress::-webkit-progress-value {
    background-color: blue;
}

progress::-moz-progress-bar {
    background-color: blue;
}

output {
    flex: 0 1 100%;
    font-size: 0.75rem;
    overflow-wrap: anywhere;
}

#preview {
    flex-basis: 100%;
    background-color: rgb(200, 200, 200);
    display: flex;
    align-items: center;
    justify-content: center;
}
