:root {
    /* COLOR PALETTE */
    --light: #ffffff;
    --dark: #000000;
    --accent: #1600e0;
    --accent-soft: hsla(246, 100%, 44%, 0.1);
    --grey-light: #E5E5E5;
    --grey-medium: #8d8d8d;
    --red: #e00000;

    /* TYPOGRAPHY */
    --font-primary: "Sora", sans-serif;
    --font-secondary: "Source Code Pro", monospace;
    
    --fs-base: 1rem;       /* 16px */
    --fs-small: 0.625rem;  /* 10px - Footer */
    --fs-button: 1.25rem;  /* 20px - Buttons */
    --fs-sub: 2rem;        /* 32px - Sub Headings */
    --fs-heading: 2.5rem; /* 40px - Main Headings */
    
    --lh-base: 2;    
    --lh-tight: 1.2;

    --lsp: 1px;

    /* SPACING & SIZING */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 2rem;
    --space-lg: 4rem;

    /* UI ELEMENTS */
    --btn-radius: 15px;
    --radius: 30px;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    
    --transition: 0.2s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-primary);
}

header {
    padding: var(--space-lg);
    text-align: center;
}

section {
    padding-block: var(--space-lg);
    text-align: center;
    overflow: hidden;
}

h1, h2 {
    text-transform: capitalize;
    font-size: var(--fs-heading);
    font-weight: 600;
    line-height: var(--lh-tight);
}

p {
    line-height: var(--lh-base);
}

.flex-gap {
    display: flex;
    gap: var(--space-md);
}

.flex-center {
    display: flex;
    justify-content: center;
    align-items: center;
}

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

.absolute-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.button {
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--btn-radius);
    text-transform: uppercase;
    font-family: var(--font-secondary);
    color: var(--light);
    background-color: var(--dark);
    text-decoration: none;
    letter-spacing: var(--lsp);
    z-index: 10;
    transition: var(--transition);
    border: 2px solid var(--dark);
}

#menu-list.is-active {
    display: flex;
    z-index: 200;
}

header nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

header #logo {
    display: block;
    line-height: 0;
}

header #logo img {
    width: 50px;
    height: auto;
}

header #menu-toggle {
    background: transparent;
    border: none;
    cursor: pointer;
}

header #menu-list {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);

    text-align: center;
    list-style-type: none;

    border-radius: var(--radius);
    box-shadow: var(--shadow);

    background-color: var(--light);

    width: 80%;
    height: 70%;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: var(--space-lg);

    display: none;
}

header #menu-list li a {
    font-family: var(--font-secondary);
    text-transform: uppercase;
    text-decoration: none;
    color: var(--dark);
    padding: var(--space-md);
    letter-spacing: var(--lsp);
}

header #menu-list li a:hover {
    font-weight: 700;
}

header #success {
    position: fixed;
    top: -100px;
    opacity: 0;

    left: 50%;
    transform: translateX(-50%);

    transition: top 0.6s cubic-bezier(0.68, -0.55, 0.27, 1.55), opacity 0.4s ease;

    display: flex;
    align-items: center;
    flex-direction: row;
    gap: 2rem;

    background-color: hsl(110, 100%, 40%);
    border-radius: 50em;
    padding: 0.5rem 1rem;

    min-width: 372px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);;
}

header #success #tick {
    display: grid;
    place-items: center;
    background-color: hsl(110, 100%, 44%);
    width: 40px;
    height: 40px;
    border-radius: 50em;
    border: 3px solid hsla(110, 100%, 20%, 30%);
}

header #success strong {
    color: hsl(110, 100%, 20%);
}

header #success.visible {
    top: 5%;
    opacity: 1;
}

main {
    padding: var(--space-lg);
    text-align: center;
}

small {
    text-transform: uppercase;
    letter-spacing: .5px;
    color: var(--grey-medium);
    text-align: center;
    font-family: var(--font-secondary);
}

fieldset {
    display: none;
}

fieldset.active {
    display: flex;
    flex-direction: column;
}

main form section fieldset {
    border: none;
}

main form section fieldset label {
    font-size: var(--fs-heading);
    font-weight: 600;
    padding-block: var(--space-sm) var(--space-lg);
}

main form section fieldset input {
    font-size: var(--fs-base);
    padding: var(--space-sm);
    border: none;
    border-bottom: 1px solid var(--dark);
    outline-color: var(--accent);
}

main form section fieldset input:focus {
    border-color: var(--accent);
}

.buttons button {
    cursor: pointer;
}

.buttons {
    padding-block: var(--space-lg);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

fieldset:first-of-type .buttons {
    margin-left: auto;
}

.buttons .button:last-child:hover {
    background-color: var(--accent);
    border-color: var(--accent);
}

.buttons .button:first-child:not(:only-child):hover {
    background-color: var(--red);
    border-color: var(--red);
}

@media screen and (min-width: 700px) {

    .wrapper {
        display: flex;
        min-height: 100vh;
        width: 100%;
    }

    header {
        height: 100vh;
        width: 25%;
    }

    header nav {
        flex-direction: column;
        justify-content: center;
        height: 100%; 
        width: 100%;
        background: var(--light);
        border-radius: 0;
        box-shadow: none;
        gap: 5rem;
    }

    header #menu-toggle {
        display: none;
    }

    header #menu-list {
        padding-block: var(--space-lg);

        transform: none;
        width: 100%;
        box-shadow: var(--shadow);

        display: flex;
        position: static;
    }

    #menu-list li {
        width: 100%;
    }

    header #menu-list li a {
        display: block;
        padding: 0;
    }

    main {
        flex-grow: 1;
    }

    form {
        width: 100%;
    }

    form section small {
        text-align: left;
        display: block;
    }

    form section fieldset label {
        text-align: left;
    }

    main form section fieldset input {
        font-size: var(--fs-sub);
    }
}