@import url('https://fonts.googleapis.com/css2?family=Comfortaa:wght@300..700&family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap');

:root {
    --black: #2B4150;
    --red: #EF3054;
    --blue: #008FF5;
    --gray: #9FB1BC;
    --light-gray: #F3F5F7;
    --beige: #E8DBC5;
    --light-beige: #FFF4E9;

    font-size: 20px;
    line-height: 1.5;

    font-family: "Open Sans", sans-serif;;
    color: var(--black);
}

body {
    margin: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

header {
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
    margin: 0;
}

h1 {
    font-family: "Comfortaa", sans-serif;
    font-weight: 900;
    margin: 0.5rem 0;
    letter-spacing: -5%;
    color: var(--black);
}

a:has(h1):hover {
    text-decoration: none;
}

header nav {
    border: 0;
}

nav ul, footer ul {
    border: 0;
    display: flex;
}

nav li, footer li {
    display: flex;
    align-items: center;
    margin: 0 0.5rem;
}

nav a {
    color: var(--black);
}

nav li:not(:last-child), footer li:not(:last-child) {
    border: 0;
}

footer {
    background-color: var(--black);
    color: white;
    font-weight: 200;
    font-size: 18px;
    padding: 0.5rem 0;
}

footer a {
    color: white;
}

.container, .content {
    max-width: 960px;
    margin: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.content {
    flex-direction: column;
    flex: 1;
    justify-content: start;
}

.highlight {
    color: var(--red);
}

ul {
    padding: 0;
}

li {
    list-style: none;
}

li:not(:last-child) {
    border-bottom: 1px dotted var(--black);
}

li > a {
    padding: 0;
    display: block;
}

img {
    max-width: 100%;
}

.row {
    display: flex;
    justify-content: space-between;
    width: 100%;
    align-items: center;
}

.title {
    margin-top: 3rem;
    margin-bottom: 0.5rem;
    border-bottom: 1px solid var(--black);
}

.breadcrumbs{
    margin-top: 1.5rem;
    line-height: 0.5rem;
    margin-bottom: -2rem;

    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;

    width: 100%;
}

.button, button {
    margin-right: 0 !important;
    color: white !important;
    text-decoration: none !important;
    transition-duration: 0.25s !important;
}

a {
    text-decoration: none;
    color: var(--blue);
    transition-duration: 0.25s;
}

a:hover {
    color: var(--blue);
    text-decoration: underline;
}

a.selected {
    font-weight: 700;
    text-decoration: underline;
}

h2 {
    flex: 1;
    margin: 0.5rem 0;
    font-weight: 200;
    font-size: 32px;
}

nav {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    border-bottom: 1px solid var(--black);
}

nav > * {
    align-self: flex-start;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    column-gap: 1rem;
    row-gap: 1rem;
}

.gallery li {
    border-bottom: 0;
}

.button, button {
    display: block;
    border: 2px solid var(--blue);
    padding: 0.4rem 1rem;
    border-radius: 0.25rem;

    background-color: var(--blue);
    color: white;
    font-size: 20px;
    font-weight: 200;

    margin: auto;

    transition-duration: 0.25s;
    line-height: 1.25rem;
}

.button:hover, button:hover {
    transform: scale(1.05);
}

.button:hover, button:hover {
    background-color: var(--blue);
    border-color: var(--blue);
}

.button input {
    display: none;
}

form {
    display: flex;
    column-gap: 0.5rem;
    flex-wrap: wrap;
    max-width: 600px;
    margin: 1rem auto;
    border: 1px solid var(--blue);
    padding: 1rem;
}

input {
    border: 1px solid var(--gray);
    border-radius: 0.25rem;
    flex: 1;
}

label {
    flex-basis: 100%;
}

.narrow {
    max-width: 600px;
    margin: auto;
}

p {
    text-align: center;
}

table {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
    font-weight: 200;
    line-height: 50px;
    border-radius: 0.5rem;
    overflow: hidden;
}

table tr:first-child {
    background-color: var(--black);
    border: 0 !important;
    color: white;
}

table tr:not(:last-child) {
    border-bottom: 1px solid var(--gray);
}

table th {
    font-weight: 200;
}

table td, table th {
    text-align: left;
    padding: 0 0.5rem;
}

table th:not(:last-child) {
    border-right: 1px dashed white;
}

table td:not(:last-child) {
    border-right: 1px dashed var(--gray);
}

/*
table td:last-child, table th:last-child {
    text-align: right;
}
*/

tr:nth-child(2n) {
    background-color: var(--light-gray);
}

table tr {
    transition: background-color 0.25s;
}

table tr:not(:first-child):hover {
    background-color: var(--light-beige);
}

.solo {
    margin-top: 3rem;
}

.login {
    width: max-content;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border: 1px solid var(--gray);
    padding: 1rem;
    width: calc(50% - 5rem);
    text-align: center;

    a {
        margin: auto !important;
    }
}

.login-wrapper {
    display: flex;
    gap: 2rem;
    margin: auto;
    flex-wrap: wrap;
    justify-content: center;

    p {
        width: 100%;
    }
}

.add-event {
    form {
        display: none;
        flex-direction: column;
        gap: 0.5rem;

        div {
            display: flex;
            justify-content: space-between;
            gap: 2rem;
        }
    }
}

#event-type:has(option[value="meal"]:checked) ~ #meal,
#event-type:has(option[value="vomit"]:checked) ~ #vomit {
    display: flex;
}
