:root {
    --border-radius: 10px;

    --font-family-title: 'Roboto', sans-serif;
    --font-family-main: 'Open Sans', sans-serif;
    --font-dark-no-adjust: black;

    --font-dark--light: var(--font-dark-no-adjust);
    --font-light--light: #f0f0f0;
    --bg-body--light: #ffffff;
    --bg-sub-1--light: #f2f2f2;
    --bg-sub-2--light: #e5e6e6;
    --bg-btn--light: #c8c8c8ff;

    --font-dark--dark: var(--font-light--dark);
    --font-light--dark: #bcbcbc;
    --bg-body--dark: #1d232a;
    --bg-sub-1--dark: #191e24;
    --bg-sub-2--dark: #15191e;
    --bg-btn--dark: #2a323c;


    color-scheme: light;
    --font-dark: var(--font-dark--light);
    --font-light: var(--font-light--light);
    --bg-body: var(--bg-body--light);
    --bg-sub-1: var(--bg-sub-1--light);
    --bg-sub-2: var(--bg-sub-2--light);
    --bg-ne: var(--bg-btn--light);
}

@media (prefers-color-scheme: dark) {
    :root {
        color-scheme: dark;
        --font-dark: var(--font-dark--dark);
        --font-light: var(--font-dark--dark);
        --bg-body: var(--bg-body--dark);
        --bg-sub-1: var(--bg-sub-1--dark);
        --bg-sub-2: var(--bg-sub-2--dark);
        --bg-ne: var(--bg-btn--dark);
    }
}

[data-theme=light]:root {
    color-scheme: light;
    --font-dark: var(--font-dark--light);
    --font-light: var(--font-light--light);
    --bg-body: var(--bg-body--light);
    --bg-sub-1: var(--bg-sub-1--light);
    --bg-sub-2: var(--bg-sub-2--light);
    --bg-ne: var(--bg-btn--light);
}

[data-theme=dark]:root {
    color-scheme: dark;
    --font-dark: var(--font-dark--dark);
    --font-light: var(--font-dark--dark);
    --bg-body: var(--bg-body--dark);
    --bg-sub-1: var(--bg-sub-1--dark);
    --bg-sub-2: var(--bg-sub-2--dark);
    --bg-ne: var(--bg-btn--dark);
}

main,
footer,
header,
input,
textarea,
select,
button,
label,
div,
strong {
    color: var(--font-dark);
    font-size: 1rem;
    font-family: var(--font-family-main);
}

h1,
h2,
h3 {
    font-family: var(--font-family-title);
    color: var(--font-dark);
    text-align: center;
}

h1 {
    font-size: 2em;
}

body {
    background-color: var(--bg-body);
    max-width: 1000px;
    margin: auto;
    padding: 1rem;
}

header {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

header h1 {
    margin-right: auto;
}

header nav {
    display: flex;
    gap: 10px;
}

header nav a:hover,
header nav button:hover {
    transition-duration: 400ms;
    background-color: black;
    color: var(--font-light);
    cursor: pointer;
}

form {
    display: flex;
    flex-direction: column;
}

table {
    width: 100%;
}

table thead {
    text-align: left;
}

textarea {
    resize: vertical;
}

input,
textarea,
select,
button,
.bnt,
.icon-bnt {
    padding: .4rem 1rem;
    border-radius: var(--border-radius);
    border-style: none;
    margin: .1rem;
    background-color: var(--bg-ne);
}

input {
    width: -webkit-fill-available;
}

button,
.bnt,
.icon-bnt {
    color: var(--font-dark);
    text-decoration: none;
    display: inline-block;
}

button:hover,
.bnt:hover,
.icon-bnt:hover {
    cursor: pointer;
    transition-duration: 400ms;
    background-color: black;
    color: var(--font-light);
}

.icon-bnt {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
}

header nav .icon-bnt {
    padding: .7rem 1.2rem;
    margin: 0;
}

footer {
    text-align: center;
    margin-top: 12rem;
    border-top: var(--bg-sub-2) solid .4rem;
    padding-top: 1rem;
}

footer a {
    color: #1d7dab;
    text-decoration: none;
}

.feather-icon {
    width: 24px;
    height: 24px;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    fill: none;
}

.widget-outer {
    border-radius: var(--border-radius);
    background-color: var(--bg-sub-1);
    padding: 10px;
    margin-bottom: 8px;
}

.widget-heading {
    text-align: center;
}

.panel {
    background-color: var(--bg-sub-1);
    padding: .5rem;
    margin-bottom: 1rem;
    border-radius: var(--border-radius);
}

.bnt-group {
    gap: .2rem;
    display: flex;
}

table td.bnt-group {
    justify-content: flex-end;
}

/* flash styles */
.flashes {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.flashes div {
    color: var(--font-light);
    border-radius: var(--border-radius);
    padding: 10px;
    margin-bottom: 5px;
}

.flashes div.ok {
    background-color: #217915;
}

.flashes div.error {
    background-color: #aa2020;
}

.flashes div span {
    margin-left: 15px;
    color: var(--font-light);
    font-weight: bold;
    float: right;
    font-size: 22px;
    line-height: 20px;
    cursor: pointer;
    transition: 0.3s;
}

.flashes div span:hover {
    color: black;
}

.img-branding {
    display: block;
    margin: auto;
    max-width: 200px;
    width: -webkit-fill-available;
}

.login {
    max-width: 500px;
    margin: auto;
}

.hidden {
    display: none;
}

.public-user-warning {
    text-align: center;
}

#theme-picker-selector {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: .3rem;
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    background-color: #00000091;
    backdrop-filter: blur(4px);
    width: 100%;
    height: 100%;
    border: none;
}

#theme-picker-selector button {
    padding: 1rem 2rem;
}

@media(max-width:640px) {

    #theme-picker-selector {
        flex-direction: column;
    }

    #theme-picker-selector button {
        min-width: 50%;
    }

    .hide-on-narrow {
        display: none;
    }
}

@media(max-width:500px) {

    header,
    header nav {
        flex-direction: column;
        width: 100%;
    }
}

@media(max-width:490px) {}
