@import url('/css/base.css');

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
    line-height: 1.7;
    font-weight: 400;
    --primary: rgb(14, 82, 166);
    --primary-hover: rgb(23, 95, 184);
    --text-primary: rgb(241, 241, 241);
    --text-contrast: #242424;
    --background: rgb(18, 18, 18);
    --background-light: rgb(45, 45, 45);
    --background-contrast: rgb(255, 255, 255);
    --inputs: rgba(27, 27, 27, 1);
    --hero-image-position-y: 25%;

    --max-width: 1000px;
    --max-width-text: 720px;
    --border-radius: 8px;
    color-scheme: dark light;
    color: var(--text-primary);
}

ul,
li {
    list-style: none;
}

html,
body {
    max-width: 100vw;
    background: var(--background);
}

body {
    position: relative;
    margin: 0;
    min-height: 100vh;
    font-size: 16px;
}

body:has(dialog[open]) {
    overflow: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    line-height: 1.2;
    margin: 2rem 0 1.5rem 0;
}

p {
    margin: 2rem 0;
}

textarea {
    resize: none;
}


@media (prefers-color-scheme: light) {
    :root {
        font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
        line-height: 1.7;
        font-weight: 400;
        --primary: rgb(14, 82, 166);
        --primary-hover: rgb(23, 95, 184);
        --text-primary: rgb(18, 18, 18);
        --text-contrast: #ffffff;
        --background: rgb(241, 241, 241);
        --background-light: rgb(255, 255, 255);
        --background-contrast: rgb(18, 18, 18);
        --inputs: rgb(255, 255, 255);
    }
}

.scroll-lock {
    height: 100%;
    overflow: hidden;
    -webkit-overflow-scrolling: touch;
}

/* Header */

.header-container {
    position: sticky;
    top: 0;
    background-color: var(--background-light);
    z-index: 99;
    display: block;
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 1rem;
    justify-content: space-between;
    transition: transform 0.25s ease-in-out;
}

.header-container.vanish {
    transform: translateY(-100%);
}

@media only screen and (min-width: 900px) {
    .header-container.vanish {
        transform: none;
    }
}

.logo {
    background-color: var(--background-contrast);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 280px;
    height: 65px;
    color: var(--text-contrast);
    font-size: 1.2rem;
    font-weight: 900;
    letter-spacing: 0.3rem;
    text-transform: uppercase;
    user-select: none;
}

@media only screen and (min-width: 900px) {
    .header-container {
        display: flex;
        position: relative;
        background-color: initial;
    }

    .logo {
        font-size: 1.4rem;
        width: 340px;
        height: 70px;
    }
}

a {
    color: unset;
    text-decoration: inherit;
}

.nav {
    display: none;
    position: absolute;
    background-color: var(--background);
    inset: 0;
    transition: opacity 0.1s ease-in;
    min-height: 100vh;
    z-index: 99;
}

.nav[data-open="false"] {
    opacity: 0;
}

.nav[data-open="true"] {
    opacity: 1;
    display: block;
}

.nav-toggle {
    position: absolute;
    display: flex;
    justify-content: center;
    align-items: center;
    top: 2rem;
    right: 24px;
    border: none;
    background-color: transparent;
    height: 36px;
    width: 36px;
    padding: 0;
    margin: 0;
    z-index: 999;
}

.nav-toggle[aria-expanded="true"] :is(.top, .bottom) {
    y: 45;
}

.nav-toggle[aria-expanded="true"] .top {
    rotate: 45deg;
}

.nav-toggle[aria-expanded="true"] .bottom {
    rotate: -45deg;
}

.hamburger {
    fill: var(--text-primary);

    & .line {
        transition: 0.3s;
        transform-origin: center;
    }
}

.navitems {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: center;
    justify-content: center;
    padding-top: 4rem;
}

.navitem {
    display: flex;
    margin: 0;
    padding: 0;
}

.navlink {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    font-weight: 700;
    padding: 1rem;
    border: 2px solid transparent;
}

@media only screen and (min-width: 900px) {
    .nav {
        display: flex;
        position: relative;
        min-height: unset;
        transition: none;
        opacity: 1;
        background-color: transparent;
    }

    .nav[data-open="false"] {
        opacity: 1;
    }

    .nav[data-open="true"] {
        opacity: 1;
    }

    .navitems {
        display: flex;
        flex-direction: row;
        justify-content: center;
        align-items: center;
        padding: 0;
    }

    .navlink {
        border-bottom: 2px solid transparent;
    }

    .navlink:hover {
        border-bottom: 2px solid lavender;
    }

    .navlink.active {
        border-bottom: 2px solid lavender;
    }

    .nav-toggle {
        display: none;
    }
}

/* Main content */

.container {
    padding: 2rem 1rem;
    margin: 0 auto;
}

.main-content {
    padding: 2rem 1rem;
    margin: 0 auto;
    max-width: var(--max-width);
}

.text-wrapper {
    max-width: var(--max-width-text);
}

/* Footer */

.footer-container {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    gap: 1rem;
    font-size: 0.9rem;
    color: var(--text-primary);
}

.hero-image {
    border-radius: var(--border-radius);
    overflow: hidden;
    object-fit: cover;
    object-position: 0 var(--hero-image-position-y);
    width: 100%;
    height: 180px;
}

@media only screen and (min-width: 900px) {
    .hero-image {
        height: 320px;
    }
}

.images {
    border: 1px solid red;
}

@keyframes fade-in {
    to {
        scale: 1;
        opacity: 1;
    }
}

.img-fadein {
    scale: 0.95;
    opacity: 0;
    animation: fade-in 0.8s forwards;
    animation-iteration-count: 1;
}

@keyframes appear {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Experiments */

.hero {
    height: 100vh;
}

.scroll-animation-container {
    height: 300vh;
    outline: 3px solid cadetblue;
}

.scroll-animation-element {
    position: sticky;
    top: 2rem;
    outline: 5px solid aquamarine;
    height: calc(100vh - 2 * 2rem);
    padding: 2rem 0;
    overflow: hidden;
}

.scroll-animation-element-inner {
    position: absolute;
    height: 100%;
    width: 100%;
    object-fit: cover;
    outline: 5px solid blueviolet;
    transform-origin: top;
    overflow: hidden;
    transform: scale(1);
    transition: transform 0.2s ease-in-out;
}

.enter-image {
    object-fit: cover;
    object-position: center;
    min-height: 100%;
    min-width: 100%;
}

/* Cookie Banner */

.cookie-banner {
    background-color: rgba(0, 0, 0, 0.4);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    padding: 20px;
    position: fixed;
    bottom: 0;
    width: 100%;
    text-align: center;
    display: none;
}

.cookie-banner-description {
    margin: 1rem;
}

.cookies-button {
    width: 135px;
}
