/* Imports */

@import url('https://fonts.googleapis.com/css2?family=League+Spartan:wght@100..900&display=swap');

/* Variables */

:root {
    --dark-gray: hsl(0, 0%, 63%);
    --black: black;
    --white: white;
    --very-dark-gray: hsl(0, 0%, 27%);
}

/* Resets */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font: inherit;
    font-family: 'league spartan', arial;
    font-weight: 500;
}

h1,
h2 {
    color: var(--black);
}

a,
a:visited {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
    display: flex;
    gap: 30px;
    color: var(--white);
    font-weight: 500
}

.logo {
    margin-right: 20px;
}

/* Styles */

body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100dvh;
    width: 100%;
    background-color: #f0f0f0/*  */;
}

.container {
    max-width: 1440px;
    width: 100%;
    height: 100dvh;
    max-height: 800px;
    height: 100%;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    margin: 0 1rem;
}

main {
    display: grid;
    grid-template-columns: minmax(0, 420px) minmax(0, 420px) minmax(0, 160px) minmax(0, 440px);
    grid-template-rows: 66.75% 33.25%;
    height: 100%;
    position: relative;
}

header {
    padding: 60px;
    position: absolute;
    z-index: 99;
    text-transform: lowercase;
}

header .logo {
    margin-right: 45px;
}

header .hamburger-menu-btn {
    display: none;
}

header {
    display: flex;
    align-items: center;
}

header a {
    color: var(--white);
    border-bottom: 2px solid transparent;
}

header a:hover {
    border-bottom: 2px solid var(--white);
}

.col-span-2 {
    grid-column: span 2;
}

.content-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0 1rem;
}

.content-container .content>* {
    margin-bottom: 1rem;
}

.content-container .content>*:last-child {
    margin-bottom: 0;
}

.content-container.heading {
    grid-column: 3 / 5;
    grid-row: 1;
}

.content-container.heading .content {
    max-width: 400px;
}

.content-container.description {
    grid-column: span 2;
}

.content-container.description .content {
    max-width: 485px;
}

.content-container.heading .content h1 {
    font-size: 46px;
    font-weight: 700;
}

.content-container.heading .content a {
    display: flex;
    align-items: center;
    gap: 1rem;
    letter-spacing: 13px;
    text-transform: uppercase;
    stroke: var(--black);
    color: var(--black) !important;
    transition: color 0.3s, letter-spacing 0.2s;
    margin-top: 2rem;
}

.content-container.heading .content a:hover {
    color: var(--dark-gray) !important;
    stroke: var(--dark-gray);
    letter-spacing: 15px;
}

.content-container.description .content h2 {
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 8px;
}

.content-container .content p {
    line-height: 20px;
    font-size: 15px;
    color: var(--dark-gray);
}

.controls {
    position: absolute;
    grid-column: 3 / 3;
    grid-row: 1 / 1;
    width: 100%;
    display: flex;
    align-items: end;
    height: 100%;
    pointer-events: none;
}

.controls button {
    background-color: var(--black);
    border: 0;
    height: 80px;
    width: 100%;
    cursor: pointer;
    pointer-events: all;
}

.controls button:hover {
    background-color: var(--very-dark-gray);

}

button span, .logo span {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.img-container {
    height: 100%;
    width: 100%;
    overflow: hidden;
    background-color: var(--dark-gray);
}

.img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.img-container .mobile-img {
    display: none;
}

.mobile-controls {
    display: none;
}

@media (width < 1024px) {

    .mobile-controls {
        display: flex;
        position: absolute;
        z-index: 90;
        bottom: 0;
        right: 0;
        width: 160px;
    }

    .mobile-controls button img{
        height: unset;
        width: unset;
    }

    .img-container {
        position: relative;
    }

    .img-container .desktop-img {
        display: none;
    }

    .img-container .mobile-img {
        display: block;
    }

    .img-container img {
        object-position: left bottom;
    }

    header {
        width: 100%;
        justify-content: center;
    }

    header .logo {
        margin: 0;
    }

    header nav {
        position: fixed;
        z-index: 98;
        height: 100dvh;
        display: none;
        width: 100%;
        left: 0;
        top: 0;
        background-color: #00000058;
        padding: 0;
        flex-direction: column;
    }

    header ul {
        display: flex;
        background-color: white;
        width: 100%;
        color: black;
        padding: 0;
        padding-left: 80px;
        gap: 32px;
        height: 110px;
        align-items: center;
    }

    header .hamburger-menu-btn {
        display: block;
        position: absolute;
        z-index: 99;
        left: 28px;
        background-color: transparent;
        border: 0;
        cursor: pointer;
    }

    header .hamburger-menu-btn[aria-expanded="true"] ~ nav {
        display: flex;
    }

    header .hamburger-menu-btn[aria-expanded="true"] {
        transform: translateY(-15px);
        background-color: transparent;
    }

    body {
        justify-content: start;
        min-height: unset;
        height: fit-content;
        margin: 0;
    }

    main {
        display: flex;
        flex-direction: column;
        position: static;
    }

    .top-image img {
        max-height: 400px;
    }

    .content-container.heading .content h1 {
        font-size: 32px;
        font-weight: 700;
    }

    .content-container.description .content h2 {
        font-size: 14px;
        letter-spacing: 5px;
    }

    .content-container .content {
        padding: 63px 1.5rem;
    }

    .attribution {
        position: fixed !important;
    }

    .desktop-controls {
        display: none;
    }

}

/* Animations */

.animate-in {
    animation: appear-next 0.5s ease-out;
}

.animate-out {
    animation: appear-prev 0.5s ease-out;
}

@keyframes appear-next {
    0% {
        transform: translateX(-15px);
        opacity: 0;
    }

    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes appear-prev {
    0% {
        transform: translateX(15px);
        opacity: 0;
    }

    100% {
        transform: translateX(0);
        opacity: 1;
    }
}