@import url('https://fonts.googleapis.com/css2?family=Fugaz+One&family=Nunito:ital,wght@0,200..1000;1,200..1000&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

input, button, textarea {
    font: inherit;
}

/* || VARIABLES */
:root {
    /* COLORS */
    --BGCOLOR: rgb(105,105,105);
    --BGCOLOR-FADE: rgb(255,250,250);
    --BGFADE: linear-gradient(to bottom, var(--BGCOLOR), var(--BGCOLOR-FADE), var(--BGCOLOR));
    --BGIMAGE: url('/www/img/bg2.webp');
    --BOX-BGCOLOR:rgba(255, 250, 250, 0.7);
    --HEADER-BGCOLOR:rgba(255, 250, 250, 0.9);
    --LK-COLOR: rgb(0, 0, 137);
    --LK-HOVER-COLOR: rgba(19, 19, 26, 0.6);
    --LK-ACTIVE-COLOR: rgb(70, 50, 50);
    --HC: #FFF;

    /* FONTS */
    --FF: "Nunito", sans-serif;
    --FF-HEADINGS: "Fugaz One", cursive;
    --FS: 1rem;

}

/* || UTILITY */
.offscreen {
    position: absolute;
    left: -10000px;
}

.nowrap {
    white-space: nowrap;
}

.center {
    text-align: center;
}

.highlight {
    background-color: var(--BOX-BGCOLOR);
}

.indent {
    text-indent: 2em;

}

/* || GENERAL STYLES */
html {
    scroll-behavior: smooth;
    font-size: var(--FS);
    font-family: var(--FF);
    background-color: var(--BGCOLOR-FADE);
    background: var(--BGIMAGE);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    background-color: rgba(255, 255, 255, 1);
    background-repeat: no-repeat;
    background-position: top;
    background-size: cover;
}

body {
    min-height: 100vh;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    padding-bottom: 50px;
}

a:any-link {
    color: var(--LK-COLOR);
    font-style: italic;
    text-decoration: underline;
}

a:hover, a:focus-visible {
    color: var(--LK-HOVER-COLOR)
}

a:active {
    color: var(--LK-ACTIVE-COLOR);
}

/* || HEADER */
.header {
    color: var(--HEADER-COLOR);
    position: sticky;
    top: 0;
    z-index: 1;
}

.header-title-line {
    background-color: var(--HEADER-BGCOLOR);
    padding: 0.25rem 0.5rem;
    display: flex;
    flex-flow: row nowrap;
    justify-content: right;
}

.menu-button {
    background-color: transparent;
    border: none;
    width: 48px;
    height: 48px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.close-menu-btn {
    display: none;
    background-color: transparent;
    outline: none;
    border: none;
    position: absolute;
    top: 0.25rem;
    right: 0.5rem;
    width: 48px;
    height: 48px;
}


.menu-icon,
.menu-icon::before,
.menu-icon::after {
    background-color: var(--BGCOLOR);
    width: 40px;
    height: 5px;
    border-radius: 5px;
    position: absolute;
    transition: all 0.5s;
}

.menu-icon::before,
.menu-icon::after {
    content: "";
}

.menu-icon::before {
    transform: translate(-20px, -12px);
}

.menu-icon::after {
    transform: translate(-20px, 12px);
}

.header-title-line:focus-within .menu-icon {
    background-color: transparent;
    transform: rotate(720deg)
}

.header-title-line:focus-within .menu-icon::before {
    transform: translateX(-20px) rotate(45deg);
}

.header-title-line:focus-within .menu-icon::after {
    transform: translateX(-20px) rotate(-45deg);
}

nav {
    display: none;
    position: relative;
}

header:focus-within nav {
    display: block;
    transform-origin: top center;
    animation: showMenu 0.5s ease-in-out forwards;
}

header:focus-within .close-menu-btn {
    display: block;
}

header:focus-within .close-menu-btn:focus {
    transform: translateX(-50px);
}

.close-menu-btn:focus+nav {
    transform-origin: top center;
    animation: hideMenu 0.5s ease forwards;
}

@keyframes showMenu {
    0% {
        transform: scaleY(0);
    }

    80% {
        transform: scaleY(1.2);
    }

    100% {
        transform: scaleY(1);
    }
}

@keyframes hideMenu {
    0% {
        transform: scaleY(1);
    }

    20% {
        transform: scaleY(1.2);
    }

    100% {
        transform: scaleY(0);
    }
}

nav ul {
    background-color: var(--HEADER-BGCOLOR);
    position: absolute;
    width: 100%;
    top: 0;
    z-index: 1;
    list-style-type: none;
    display: flex;
    flex-flow: column nowrap;
}

nav li {
    padding: 0.5rem;
    border-top: 1px solid black;
}

nav a {
    display: block;
    text-align: center;
    width: 80%;
    margin: auto;
}

nav a:any-link {
    color: black;
    font-weight: bold;
    text-decoration: none;
}

nav a:hover,
nav a:focus {
    transform: scale(1.2);
    transition: all 0.3s;
}

/* || HERO */

/* || FOOTER */
footer {
    background-color: var(--HEADER-BGCOLOR);
    position: absolute;
    display: flex;
    left: 0;
    bottom: 0;
    width: 100%;
    text-align: center;
    justify-content: space-evenly;
    padding: 10px;
    height: 55px;
}

.footer__image {
    height: clamp(25px, 32px, 45px);
    width: auto;
    overflow: hidden;
}

.footer__image:hover, .footer__image:focus-visible {
    transition: 1s;
    transform: scale(1.1);

}

/* || MAIN */
.main {
    align-items: center;
}

.main__article {
    gap: 0.1em;
    margin: 10px;
    padding: 10px;
    display: flex;
    flex-basis: 1 1 auto;
    flex-flow: column wrap;
    place-content: center;
}

.main__li {
    list-style: none;
    place-self: center;
}

.main__p {
    margin-bottom: 10px;
    line-height: 1.5rem;
    padding-block: 10px;
    text-align: center;
    flex-flow: row wrap;
}

.main:last-child {
    margin-bottom: 50px;
    border: 2px solid red;
}

.main__h1, .main__h2 {
    text-align: center;
}

.main__label, .main__input, .main__textarea {
    place-self: center;
    text-align: center;
}

.main__textarea {
    resize: vertical;
    width: 250px;
    max-height: 500px;
}

/* Tablets & larger phones*/
@media only screen and (min-width: 426px) {
.main {
    display: grid;
    grid-template-columns: repeat(3, 2fr, 1fr, 2fr);
    grid-auto-rows: minmax(100px, auto);
}

.main__article:first-child{
    grid-row: 1/3;
    grid-column: 1;
}

.main__article:last-child {
    grid-row: 2/4;
    grid-column: 3;
}
}

/* Laptops */
@media screen and (min-width: 768px) {
    .nav-button {
        display: none;
    }

    nav {
        display: none;
    }

    nav ul {
        flex-flow: row nowrap;
        justify-content: space-evenly;
        border-top: 1px solid black;
    }

    nav li {
        border-top: none;
    }

    header:focus-within nav {
        animation: none;
    }
}

/* Large Desktops */
@media only screen and (min-width: 1280px) {

}
