@font-face {
    font-family: 'Comrade Bold';
    src: url('fonts/Comrade-Bold-Regular.ttf') format('truetype');
}

@font-face {
    font-family: 'Gemunu Libre';
    src: url('fonts/GemunuLibre-SemiBold.ttf') format('truetype');
}

:root {
    --pink: #E8308A;
    --yellow: #F6CA21;
    --blue: #2049BF;
    --black: #1D1D1B;
    --gray: #E9E8E8;
    --padding: 24px;
}

html {
    scroll-behavior: smooth;
    line-height: 1.6em;
}

body {
    font-family: 'Gemunu Libre', sans-serif;
    text-rendering: optimizeLegibility;
    image-rendering: optimizeQuality;
    background: var(--black);
    color: var(--gray);
    margin: 0;
}

p {
    font-size: 20px;
}

a {
    color: var(--gray);
}

h3 {
    margin-bottom: 0;
}

h3 + :not(em) {
    margin-bottom: 1em;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Comrade Bold', sans-serif;
    line-height: 1.2em;
}

h1 {
    font-size: 48px;
}

h2 {
    font-size: 36px;
}

h3 {
    font-size: 32px;
}

nav {
    padding: var(--padding);
    padding-top: 12px;
    padding-bottom: 12px;
    position: sticky;
    top: 0;
    left: 0;
    z-index: 1000;
    background: rgba(29, 29, 27, 0.7);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    box-shadow: 0 0 8px var(--black);
}

nav .centered {
    display: flex;
    justify-content: space-between;
    align-items: center;
    align-items: center;
    gap: var(--padding);
}

nav .nav-links {
    display: flex;
    gap: var(--padding);
}

nav .nav-links a {
    font-size: 24px;
    text-decoration: none;
    transition-duration: 200ms;
}

nav .nav-links a:hover,
nav .nav-links a:focus {
    transform: scale(1.1);
}

nav img {
    height: 48px;
}

section {
    padding: var(--padding);
    padding-top: calc(2vw + var(--padding));
    padding-bottom: calc(2vw + var(--padding));
    margin-top: calc(10vw + 48px);
    margin-bottom: calc(10vw + 48px);
    position: relative;
}

section.overview {
    padding-top: calc(var(--padding) + 64px);
    padding-bottom: var(--padding);
    margin-top: 64px;
    margin-bottom: -64px;
}

section.blue {
    background: var(--blue);
}

section.blue::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--blue);
    transform-origin: 0 0;
    transform: skew(0, -1deg);
    z-index: -1;
}

section.blue::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--blue);
    transform-origin: 0 0;
    transform: skew(0, 2deg);
    z-index: -1;
}

section.pink {
    background: var(--pink);
    color: var(--black);
}

section.pink::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--pink);
    transform-origin: 0 0;
    transform: skew(0, 2deg);
    z-index: -1;
}

section.pink::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--pink);
    transform-origin: 0 0;
    transform: skew(0, -2deg);
    z-index: -1;
}

section.yellow {
    background: var(--yellow);
    color: var(--black);
}

section.yellow::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--yellow);
    transform-origin: 0 0;
    transform: skew(0, 2deg);
    z-index: -1;
}

section.yellow::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--yellow);
    transform-origin: 0 0;
    transform: skew(0, -1deg);
    z-index: -1;
}

.portrait {
    padding-left: 0;
    padding-right: 0;
}

.portrait figure {
    margin: 0;
    display: flex;
    flex-direction: row;
    align-items: center;
}

.portrait figcaption {
    padding: var(--padding);
}

.portrait img {
    display: block;
    width: 50vw;
    flex-shrink: 0;
    max-width: 368px;
    max-height: 368px;
}

footer {
    padding: var(--padding);
}

@media screen and (max-width: 512px) {
    .portrait img {
        width: 100%;
        max-height: none;
        height: auto;
        max-width: none;
    }

    .portrait figure {
        flex-direction: column;
    }
}

header {
    display: flex;
    flex-wrap: nowrap;
    height: 100vh;
}

#header-nav {
    position: absolute;
    width: 100vw;
    margin-top: 70vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
}

#header-nav a {
    color: var(--yellow);
    font-size: 4vh;
    font-family: "Comrade Bold";
    line-height: 6vh;
    display: inline-block;
    text-shadow: 4px 4px 0 var(--black),
    0 0 8px var(--black);
    text-decoration: 0;
    position: relative;
    transition-duration: 200ms;
}

#header-nav a:hover,
#header-nav a:focus {
   transform: scale(1.1);
}

#header-background {
    width: 100%;
    background: var(--black);
    background-image: url("media/Titelbild_Landing_Page_Zwaegbier.jpg");
    background-size: cover;
    background-position: center;
}

#header-logo {
    position: absolute;
    width: 30vh;
    margin-left: calc(50vw - 15vh);
    margin-top: 5vh;
    display: block;
    filter: drop-shadow(0 0 8px var(--black));
}

.centered {
    margin: auto;
    max-width: 768px;
    width: 100%;
}

/* SPARKLING ANIMATION */

.wrapper {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

.bubble {
    position: absolute;
    top: 53%;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.small {
    width: 10px;
    height: 10px;
    left: 50%;
    animation: flow-s 2s linear infinite;
}

.small-l {
    width: 10px;
    height: 10px;
    left: 43%;
    animation: flow-s-l 0.9s linear infinite;
}

.s-medium {
    width: 20px;
    height: 20px;
    left: 43%;
    animation: flow-s 1.3s linear infinite;
}

.medium {
    width: 25px;
    height: 25px;
    left: 45%;
    animation: flow-m 0.8s linear infinite;
}

.large {
    width: 5px;
    height: 5px;
    left: 57%;
    animation: flow-l 0.7s linear infinite;
}

@keyframes flow-l {
    0% {
        top: 53%;
        left: 57%;
        opacity: 0;
    }

    25% {
        top: 49%;
        left: 57.5%;
        opacity: 1;
    }

    50% {
        left: 58%;
        opacity: 1;
    }

    75% {
        left: 57.5%;
        opacity: 1;
    }

    100% {
        top: 32%;
        left: 57%;
        opacity: 0;
    }
}

@keyframes flow-s {
    0% {
        top: 53%;
        left: 50%;
        opacity: 0;
    }

    25% {
        top: 49%;
        left: 51%;
        opacity: 1;
    }

    50% {
        top: 45%;
        left: 52%;
        opacity: 1;
    }

    75% {
        top: 41%;
        left: 51%;
        opacity: 1;
    }

    100% {
        top: 37%;
        left: 50%;
        opacity: 0;
    }
}

@keyframes flow-s-m {
    0% {
        top: 53%;
        left: 43%;
        ;
        opacity: 0;
    }

    25% {
        top: 49%;
        left: 42.5%;
        opacity: 1;
    }

    50% {
        top: 45%;
        left: 42%;
        opacity: 1;
    }

    75% {
        top: 41%;
        left: 42.5%;
        opacity: 1;
    }

    100% {
        top: 37%;
        left: 43%;
        opacity: 0;
    }
}

@keyframes flow-m {
    0% {
        top: 53%;
        left: 45%;
        ;
        opacity: 0;
    }

    25% {
        top: 48%;
        left: 44.5%;
        opacity: 1;
    }

    50% {
        top: 43%;
        left: 44%;
        opacity: 1;
    }

    75% {
        top: 38%;
        left: 44.5%;
        opacity: 1;
    }

    100% {
        top: 33%;
        left: 45%;
        opacity: 0;
    }
}

@keyframes flow-s-l {
    0% {
        top: 53%;
        left: 43%;
        ;
        opacity: 0;
    }

    25% {
        top: 48%;
        left: 43.5%;
        opacity: 1;
    }

    50% {
        top: 43%;
        left: 44%;
        opacity: 1;
    }

    75% {
        top: 38%;
        left: 43.5%;
        opacity: 1;
    }

    100% {
        top: 33%;
        left: 43%;
        opacity: 0;
    }
}