// Copyright 2021 James Deery
// Released under the MIT licence, https://opensource.org/licenses/MIT

@use 'common' as *;

$menu-time: 80ms;

label, input, select, button {
    appearance: none;
    font-family: $m8-font;
    font-size: 14px;
    background-color: #000;
    color: #fff;

    &:hover {
        background-color: $m8;
        color: #000;
    }

    &:active {
        background-color: darken($m8, 10%);
        color: #fff;
    }

    &:focus, &:focus-within {
        outline: none;
        color: $m8;

        &:hover {
            color: #000;
        }

        &:active {
            color: #fff;
        }
    }
}

button {
    border: 3px solid #fff;
    padding: 20px;
}

input[type=checkbox] {
    font-family: $m8-font;

    &::after {
        content: 'OFF';
    }

    &:checked::after {
        content: 'ON';
    }
}

input[type=file] {
    border: 3px solid #fff;
    padding: 20px;
}

select {
    padding: 5px 32px 5px 5px;
    background-color: transparent;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23fff' stroke-width='3' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 16px;

    font-family: sans-serif;
    font-size: 12px;
}

progress {
    border: 3px solid #fff;
    height: 40px;
    width: 100%;

    &::-webkit-progress-bar {
        background-color: #000;
    }

    &::-webkit-progress-value {
        background-color: $m8;
    }
}
