html {
    box-sizing: border-box;
}

*,
*::before,
*::after {
    box-sizing: inherit;
}
ul,
ol {
    margin: 0;
    padding-left: 0;
    list-style: none;
}

sup {
    line-height: 0;
}

.cf::before,
.cf::after {
    content: " ";
    display: table;
}

.cf::after {
    clear: both;
}
html {
    font-family: "Helvetica Neue", Arial, sans-serif;
    min-height: 100%;
}
body {
    min-height: 100%;
    margin: 0;
    background: url("images/clouds.png") repeat-x fixed,
        url("images/spring-flowers.png") repeat-x left bottom,
        #000 linear-gradient(to bottom, #1e5799 0%,#a2c4d8 22%,#87bbdb 57%,#87bbdb 85%,#157226 85%,#84c17f 100%) fixed;
}

.container {
    margin: 0 .625rem;
    overflow: hidden;
}

.wrapper {
    border: 2px solid white;
    border-radius: 10px;
    background: #EF8674;
    margin-top: 4.625em;
    margin-bottom: 10px;
}

header {
    display: flex;
    border-radius: 10px;
    border: 2px solid gray;
    margin: 20px;
    background: url("images/blue-flower.png")no-repeat top 0px right 0px / 200px 200px,
        url("images/sunny.webp") no-repeat center center / cover,
        #000 linear-gradient(to bottom, rgba(0, 159, 245, 1), rgba(0, 100, 225, 1));
    box-shadow: inset 0 4px 4px rgba(0, 0, 0, 0.8);
}

header h1 {
    line-height: 4;
    text-align: center;
    flex: 1 0 auto;
    margin: 0;
    color: #fff;
    font-family: "Myriad Pro Regular", sans-serif;
    font-weight: 200;
    letter-spacing: 4px;
    text-shadow: 0 -2px 2px rgba(0, 0, 0, 0.6);
    background: transparent linear-gradient(to bottom,
            hsla(197, 68%, 47%, 0.7) 1px,
            hsla(197, 68%, 47%, 0.7) 2px,
            hsla(197, 68%, 47%, 1.00));
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
}

header h1 sup {
    font-size: .6em;
}
.nav-main {
    position: relative;
}

.nav-main-menu-toggle {
    display: none;
}

.nav-main-menu-toggle-icon {
    position: fixed;
    z-index: 200;
    width: 64px;
    height: 64px;
    top: 0;
    left: 0;
    cursor: pointer;
}

.nav-main-menu-toggle-icon span {
    width: 100%;
    top: 50%;
    left: 10%;
    transform: translateY(-50%);
}

.nav-main-menu-toggle-icon span::before,
.nav-main-menu-toggle-icon span,
.nav-main-menu-toggle-icon span::after {
    background-color: #ffc840;
    height: 6px;
    position: absolute;
    content: '';
    transition: all 1s cubic-bezier(0.97, 0.1, 0.01, 0.96);
    border-radius: 3px;
}

.nav-main-menu-toggle-icon span::before {
    width: 100%;
    top: -10px;
}

.nav-main-menu-toggle-icon span::after {
    width: 100%;
    top: 10px;
}

.nav-main-menu-toggle:checked~.nav-main-menu-toggle-icon span {
    background-color: transparent;
}

.nav-main-menu-toggle:checked~.nav-main-menu-toggle-icon span::before,
.nav-main-menu-toggle:checked~.nav-main-menu-toggle-icon span::after {
    top: 0;
}

.nav-main-menu-toggle:checked~.nav-main-menu-toggle-icon span::before {
    transform: rotate(-135deg);
}

.nav-main-menu-toggle:checked~.nav-main-menu-toggle-icon span::after {
    transform: rotate(135deg);
}

.nav-main-menu {
    position: fixed;
    z-index: 50;
    top: 4em;
    left: 0;
    width: 0;
    height: calc(100vh - 3em);
    transition:
        width .5s .25s ease-in,
        box-shadow .25s ease-in;
    background-color: #ff6b51;
    box-shadow: none;
    overflow-y: auto;
}

.nav-main-menu-toggle:checked~.nav-main-menu {
    width: 60vw;
    box-shadow: 0 0 0 100vw hsl(211.07deg 53.33% 41.18% / 68%);
}

.nav-main-menu a {
    position: relative;
    display: block;
    font-size: 1.5em;
    line-height: 2;
    font-weight: 300;
    text-transform: uppercase; 
    color: hsl(0, 0%, 100%);
    text-decoration: none;
    text-indent: 1.25rem;
    margin: 4px 0;
    transition: all .25s ease-in;
}


.nav-main-menu a:hover {
    text-indent: 2.0rem;
}

.nav-main-menu a:hover::before {
    transform: translateX(25vw);

}

main {
    margin: 20px;
}

.cards {
    padding-left: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    border: 2px solid gray;
    border-radius: 10px;
    box-shadow: inset 0 4px 4px rgba(0, 0, 0, 0.8);
}

.cards .card {
    background: #2d9bc8;
    margin: 10px;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}
    
.cards .card figure {
    background: lightseagreen;
    margin: 0;
    line-height: 0;
}

.cards .card figure img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.cards .card section {
    background: #ffffff;
    padding: 10px;
    flex: 1 1 auto;
}

.cards .card a {
    text-decoration: none;
    border-radius: 6px;
    border: 2px solid white;
    color: white;
    box-shadow: inset 0px 3px 2px 0px #7986c2;
    font-weight: bold;
    text-shadow: 0px 1px 0px #647dbe;
    align-self: flex-end;
    background: #4b66af;
    margin: 10px;
    line-height: 3em;
    padding: 0 1em;
}
.cards .card a:hover {
    background:linear-gradient(to bottom, #7b92c9 5%,#647dbe 100%);
    background-color: #7b92c9;
}

.callout {
    border: 2px solid gray;
    border-radius: 10px;
    box-shadow: inset 0 4px 4px rgba(0, 0, 0, 0.8);
    font-family: sans-serif;
    background: #22b24c;
    padding: 12px;
    margin-top: 30px;
}

.callout-heading {
    color: white;
    font-size: 2.5em;
    font-weight: 200;
    text-transform: uppercase;
    margin: 0 0 32px;
    letter-spacing: -2px;
}

.callout-intro {
    color: white;
    font-size: 1.25em;
    margin: 0 0 16px;
}

.subscribe-newsletter {
    --color-white-20: hsla(0, 0%, 100%, 0.20);
    --color-white-40: hsla(0, 0%, 100%, 0.40);
    --color-white-60: hsla(0, 0%, 100%, 0.60);
    --color-white-80: hsla(0, 0%, 100%, 0.80);
    --color-black-20: hsla(0, 0%, 0%, 0.20);
    --color-black-40: hsla(0, 0%, 0%, 0.40);
    --color-black-60: hsla(0, 0%, 0%, 0.60);
    --color-black-80: hsla(0, 0%, 0%, 0.80);
    --color-button-dark: hsla(266, 47%, 30%, 1.00);
    --color-button-light: hsla(54, 86%, 58%, 1.00);
    --z-index: -1;
}

.subscribe-newsletter {
    transition: all 1s ease-in;
    background: transparent linear-gradient(to bottom,
            hsla(197, 68%, 47%, 0.7) 1px,
            hsla(197, 68%, 47%, 0.7) 2px,
            hsla(197, 68%, 47%, 1.00));
    border-radius: .5em;
}

.subscribe-newsletter {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: stretch;
    overflow: hidden;
}

.subscribe-newsletter fieldset {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0;
    margin: 0;
    border: none;
}

.subscribe-newsletter fieldset:first-child {
    flex: 1 1 auto;
}

.subscribe-newsletter fieldset:last-child::after {
    content: "";
    position: absolute;
    width: 100%;
    height: 100%;
    background: url("images/loader-circles-spin.svg") no-repeat center;
    z-index: var(--z-index, -1);
}

.subscribe-newsletter input:not([type="radio"]):not([type="checkbox"]) {
    -webkit-appearance: none;
    border: none;
    border-radius: 0;
}

.subscribe-newsletter input {
    position: relative;
    font-family: inherit;
    font-size: 1.2em;
    line-height: 2.4;
    letter-spacing: 0.05em;
    padding: 0 .5em;
    margin: 0;
    color: var(--color-button-dark);
}

.subscribe-newsletter input[type=email] {
    background: var(--color-white-60);
}

.subscribe-newsletter input[type=email]:focus {
    outline: none;
    box-shadow: inset 0 0 0 2px var(--color-button-dark);
}

.subscribe-newsletter input::placeholder {
    position: relative;
    color: var(--color-button-dark);
    opacity: .4
}

.subscribe-newsletter input::placeholder {
    transition: 2s cubic-bezier(1, 1.65, 0.35, 1.32), opacity .25s ease;
}

.subscribe-newsletter input:focus::placeholder {
    transform: translateX(100%);
    transition: transform 1s cubic-bezier(0.15, 0.69, 0.7, -0.42), opacity 2s ease;
    opacity: 0
}

.subscribe-newsletter input[type=submit],
.subscribe-newsletter input[type=submit]:invalid {
    background: hsl(1.23deg 80.22% 64.31%);
    color: white;
    font-weight: 400;
    text-transform: uppercase;
    padding: 0 1em;
    transition: all 1s .5s ease-in;
    transform-origin: right center;
    transform: scale(1);
    box-shadow: 0 0 0px 0px var(--color-black-60);
}

.subscribe-newsletter:valid input[type=submit] {
    color: hsl(1 90% 58% / 1);
    border-radius: 10px 0 0 10px;
    background: hsl(45.38deg 95.12% 67.84%);
    transform: scale(1);
    font-weight: bolder;
    box-shadow: -2px 2px 4px var(--color-black-60), -2px -2px 4px var(--color-black-60);
}

.subscribe-newsletter fieldset input[type=submit]:disabled {
    background: var(--color-white-80);
    color: black;
    transform: scale(1);
    box-shadow: 0 0 0px 0px var(--color-black-60);
    border-radius: 0px 0px 0px 0px;
}

.subscribe-newsletter label {
    color: var(--color-white-80);
    line-height: 1.625em;
    padding: 0 .5em;
}

.subscribe-newsletter.sending {
    background: var(--color-white-60);
}

.subscribe-newsletter.received {
    background: var(--color-white-20);
}

.subscribe-newsletter .subscribe-newsletter-message-error {
    background: var(--color-button-dark);
}

.subscribe-newsletter .subscribe-newsletter-message-success {
    background: var(--color-white-80);
    color: var(--color-button-dark);
    font-size: 1.6em;
    flex: 1;
    text-align: center;
}

img {
    width: 100%;
}

footer {
    clear: both;
    overflow: auto;
    margin: 0 20px;
    padding: 0 0 20px;
    color: #fff;
}

footer a[href^=javascript] {
    position: relative;
    color: #000;
    display: block;
    line-height: 2em;
    font-size: 0.625em;
    background-color: #fff;
    border-radius: 3px;
    margin: 0 0 0 10px;
    padding: 0 10px;
    float: right;
    text-decoration: none;
    box-shadow: 0 2px 2px #000;
}

footer a[href^=http]:active {
    top: 2px;
    box-shadow: none;
}

footer a {
    color: black;
}


@media (min-width: 768px){
    .container {
        width: 96%;
        max-width: 800px;
        margin: 20px auto;
    }

    header {
        height: 400px;
        background: url("images/final-project-sign.png") no-repeat 50px 10px / 300px 200px,
            url("images/blue-flower.png") no-repeat top 6px right 6px / 200px 180px,
            url("images/sunny.webp") no-repeat center center / cover,
            #000 linear-gradient(to bottom, rgba(0, 159, 245, 1), rgba(0, 100, 225, 1));
    }

    header h1 {
        line-height: 2;
        font-size: 2.75em;
        align-self: flex-end;
        border-top-left-radius: 0px;
        border-top-right-radius: 0px;
    }

    .nav-main-menu-toggle,
    .nav-main-menu-toggle-icon {
        display: none;
    }

    .nav-main-menu {
        display: flex;
        justify-content: space-between;
        position: relative;
        z-index: 0;
        top: auto;
        left: auto;
        width: auto;
        height: auto;
        transition: none;
        background-color: transparent;
        box-shadow: none;
        overflow: hidden;
        padding: 0 20px;
    }

    .nav-main-menu-toggle:checked~.nav-main-menu {
        width: auto;
        box-shadow: none;
    }

    .nav-main-menu a {
        position: static;
        display: block;
        text-indent: 0;
        padding: 0 1em;
        background-color: #1a7227;
        border: 2px solid hsl(0, 0%, 100%);
        border-radius: 10px;
        transition: all .25s linear;
        box-shadow: 0 0px 4px currentColor;
    }

    .nav-main-menu a::before {
        display: none;
    }

    .nav-main-menu a:hover {
        text-indent: 0;
        color: black;
        background-color: hsl(0, 0%, 100%);
        box-shadow: 0 0px 0px currentColor;
    }

    .nav-main-menu a:active {
        text-indent: 0;
        color: hsl(213, 100%, 44%);
        background-color: hsl(0, 0%, 100%);
        box-shadow: inset 0 0px 4px currentColor;
    }
    
     .cards .card {
        flex: 0 0 calc(50% - 20px);
    }
     .callout {
        padding: 80px;
    }
    .subscribe-newsletter {
        box-shadow: inset 0 4px 4px rgba(0, 0, 0, 0.8);
        flex-direction: row;
        height: 8em;
        align-items: center;
    }
    .subscribe-newsletter:valid input[type=submit] {
        transform: scale(1.2);
    }

    img {
        width: auto;
        float: right;
        margin: 0 0 2px 4px;
    }
}