/* ==========================================================================
   Mobile Styles
   ========================================================================== */

/* Fonts
   ========================================================================== */
  @import url('https://fonts.googleapis.com/css2?family=Noto+Serif&family=Oswald&display=swap');

html, body { 
    font-family: "Noto Serif", sans-serif;
    font-weight: 300;
    font-size: 16px;
    color: #333;
}

h1, h2, h3, h4, h5, h6 {
    font-family: Oswald, sans‑serif;
    font-weight: bold;
    letter-spacing: 1px;
}

h1 {
    font-size: 1.5em;
}

h2 {
    font-size: 1.25em;   
}

/* Reset
   ========================================================================== */

* {
    margin: 0;
    padding: 0;
    border: none;
    box-sizing: border-box;
}

/* General Layout
   ========================================================================== */

html, body { 
    height: 100%;
}

section, footer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;    
}

section > div {
    width: 100%;
    text-align: center;
}

h1, h2, h3, h4, h5, h6, p {
    margin: 0 0 1em 0;
}

header, section, footer {
    width: 85%;
    margin: auto;
    padding: 0;
    display: flex;
    color: #333;
    width: 100%;
    padding: 1.5em;
}

header {
    flex-direction: row;
    padding: 0.5em 1.5em;
    justify-content: space-between;
    align-items: center;
    height: 82px;   
}

section { 
    flex-direction: column;
    justify-content: center;    
}

div[id^="parallax"] {
    display:none;
}

footer {
    flex-direction: row;
    flex-wrap: wrap;
}

hr {
    width: 100%;
    border: 1px solid lightgrey;
}

/* Buttons
   ========================================================================== */

.cta-btn {
    display:inline-block;
    border-radius: 50px;
    background-color: #1b5e20 ;
    color: #fff;
    padding: 10px 22px;
    margin: 1em 0;
    text-decoration: none;
}

a.cta-btn:hover {
    text-decoration: none;
    box-shadow: 0 12px 16px 0 rgba(0,0,0,0.24),0 17px 50px 0 rgba(0,0,0,0.19); /* Sourced from https://www.w3schools.com/css/tryit.asp?filename=trycss_buttons_shadow*/
}

.menu-items .cta-btn {
    margin-left: 1em;    
}

footer .cta-btn, nav .cta-btn {
    display:inline-block;
    border-radius: 50px;
    padding: 10px 22px;
    margin: 1em 0;
    text-decoration: none;
}

nav .cta-btn  {
    background-color: #0014B0;
    color: #fff;
}

footer .cta-btn {
    background-color: #fff;    
    color: #005c10;
    font-weight: bold;
}

nav a.cta-btn:hover {
    text-decoration: none;
    color: #fff;
    box-shadow: 0 6px 8px 0 rgba(0,0,0,0.24),0 8px 15px 0 rgba(0,0,0,0.19); /* Sourced from https://www.w3schools.com/css/tryit.asp?filename=trycss_buttons_shadow*/
}

footer a.cta-btn:hover {
    text-decoration: none;
    box-shadow: 0 12px 16px 0 rgba(255, 255, 255, 0.24),0 17px 50px 0 rgba(255, 255, 255, 0); /* Sourced from https://www.w3schools.com/css/tryit.asp?filename=trycss_buttons_shadow*/
} 

/* Navigation Menu - Adapted from https://codepen.io/alvarotrigo/pen/MWEJEWG 
   ========================================================================== */

nav {
    height: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: right;
    color: #333;
    height: auto;
    padding: 1em 0;
}

nav li {
    list-style-type: none;
}

nav li a {
    color: #333;
    text-decoration: none;
    font-weight: bold;
}

nav li a:hover {
    color: #333;
    text-decoration: underline;
}

.menu-button-container {
    display: flex;
    height: 30px;
    width: 30px;
    cursor: pointer;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* 
Fix mobile menu empty form label. Code adapated from 
https://stackoverflow.com/questions/71369244/empty-form-label-a-form-label-is-present-but-does-not-contain-any-content/71369523#71369523
by GrahamTheDev
*/

.visually-hidden {
    border: 0;
    padding: 0;
    margin: 0;
    position: absolute !important;
    height: 1px; 
    width: 1px;
    overflow: hidden;
    clip: rect(1px 1px 1px 1px); /* IE6, IE7 - a 0 height clip, off to the bottom right of the visible 1px box */
    clip: rect(1px, 1px, 1px, 1px); /*maybe deprecated but we need to support legacy browsers */
    clip-path: inset(50%); /*modern browsers, clip-path works inwards from each corner*/
    white-space: nowrap; /* added line to stop words getting smushed together (as they go onto seperate lines and some screen readers do not understand line feeds as a space */
}

#menu-toggle ~ .menu-items li {
    height: 0;
    margin: 0;
    padding: 0;
    border: 0;
    transition: height 400ms cubic-bezier(0.23, 1, 0.32, 1);
    width:0;
}

#menu-toggle:checked ~ .menu-items {
    position: absolute;
    top: 32px;
    left: 0;
    margin-top: 50px;
    width: 100%;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

#menu-toggle:checked ~ .menu-items li {
    height: 5em;
    align-items: center;
    padding: 0.5em;
    border: 1px solid lightgray;
    transition: height 400ms cubic-bezier(0.23, 1, 0.32, 1);
    width: 100%;
}

.menu-items > li {
    display: flex;
    justify-content: center;
    margin: 0;
    padding: 0.5em;
    width: 100%;
    color: #333;
    background-color: #fff;    
}

.menu-items > li:not(:last-child) {
    border-bottom: 1px solid lightgray;
}

#menu-toggle {
    display: none;
}

.menu-button,
.menu-button::before,
.menu-button::after {
display: block;
background-color: #333;
position: absolute;
height: 4px;
width: 30px;
transition: transform 400ms cubic-bezier(0.23, 1, 0.32, 1);
border-radius: 2px;
}

.menu-button::before {
content: '';
margin-top: -8px;
}

.menu-button::after {
content: '';
margin-top: 8px;
}

#menu-toggle:checked + .menu-button-container .menu-button::before {
margin-top: 0px;
transform: rotate(405deg);
}

#menu-toggle:checked + .menu-button-container .menu-button {
background: rgba(255, 255, 255, 0);
}

#menu-toggle:checked + .menu-button-container .menu-button::after {
margin-top: 0px;
transform: rotate(-405deg);
}

.menu-items > li {
    margin: 0 1rem;
    overflow: hidden;
}

/* Hero Section
   ========================================================================== */

#hero-text-container {
    width: 280px;
    padding-bottom: 1.5em;
}

/* Client Logos Section
   ========================================================================== */

#client-logos-inner {
    width: 280px;
}

#client-logos {
    display:flex;
    flex-direction: row;
    justify-content: space-around;
    flex-wrap: wrap;
    row-gap: 1.5em;
    column-gap: 0.75em;
}

/* Parallax Sections
   ========================================================================== */

#parallax1 {
    background: url('../images/nurture-growth.webp') no-repeat fixed top / cover;
    height: 40vh;
    padding: 0;
}

#parallax2 {
    background: url('../images/nurture-harvest.webp') no-repeat fixed top / cover;
    height: 40vh;
    padding: 0;   
}

/* Services Sections
   ========================================================================== */

#services {
    display:flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
}

.service-container {
    display:flex;
    flex-direction: column;
    justify-content: center;
    border-radius: 25px;
    padding: 2em;
    width: 280px;
    flex: 0 0 280px;
    align-items: center;
    border: 1px solid lightgray;
    align-self: stretch; /* Force service containers to maintain equal height*/
}

.service-container p {
    flex: 1 1 auto;
    text-align: center;
}

.service-container .cta-btn {
	margin: 5px 0 0 0;
}

/*
CSS gradient styles generated using https://cssgradient.io
*/

#service1 {
    background: rgb(255,255,255);
    background: linear-gradient(360deg, rgba(255,255,255,1) 92%, rgba(27, 94, 32, 1) 100%);
}

#service2 {
    margin: 20px 0;
    background: rgb(255,255,255);
    background: linear-gradient(360deg, rgba(255,255,255,1) 92%, rgba(255,193,7,1) 100%);
}

#service3 {
    background: rgb(255,255,255);
    background: linear-gradient(360deg, rgba(255,255,255,1) 92%, rgba(33,150,243,1) 100%);
}

/* Testimonials Section
   ========================================================================== */

.testimonials-container {
    width: 280px;
}

.testimonials-container blockquote {
    width: 100%;
    margin: 32px auto;
    padding: 0 1em;
}

#testimonial-name, #testimonial-company {
    display: block;
    font-weight: bold;
}

/* About Section
   ========================================================================== */

#about-container {
    width: 280px;
    padding: 0 1em;
}

/*
The styles used below to achieve a circular frame around the index page's
headshot image was adapted from the Code Institute's Love Running Project
https://github.com/Code-Institute-Org/love-running-2.0
*/

#about-image-container {
    background: url('../images/matthew-shepherd-140.webp') no-repeat center center;    
    width: 140px;
    height: 140px;
    border-style: solid;
    border-color: #ccc;
    border-width: 1px;
    border-radius: 50%;
    margin: 1.5em auto 0 auto;
}

#about-image-bg {
    height: 100%;
    border-radius: 50%;
    background-size: contain;
}

/* Contact Section
   ========================================================================== */

#connect-container {
    min-width: 280px;
    padding-bottom: 1.5em;
}

#connect-container iframe {
    width: 90%; /* Override width of Google map iframe and make responsive */
}

.social-link {
    display: inline-block;
    min-width: 250px;
    text-align: left;
    line-height: 48px;
}

.social-link a:link, .social-link a:visited, .social-link a:active {
    color: #333;
    text-decoration: none;
    margin-right: 1em;
    font-size: 0.9em;
}

.social-link img {
    position: relative;
    top: 12px;
    margin-right: 12px;
    filter: drop-shadow(5px 5px 5px #333);
}

.form-container {
    background-color: rgba(60, 60, 60, 0.2);
    display:flex;
    flex-direction: column;
    border-radius: 25px;
    padding: 2em 1.5em;
    margin-top: 1.5em;    
    min-width: 280px;
    flex: 1 1 440px;
    justify-content: space-between;
    align-items: center;    
}

.form-container form {
    text-align: left;
    width: 95%;
}

.form-center, .form-container label {
   display: block; 
}

.form-center {
    text-align: center;
}

.form-center .cta-btn {
    margin: 0;
}

.form-container .text-field {
    color: black;
    height: 25px;
    width: 100%;
    margin: 5px 0 20px 0;
    border: 1px solid #fafafa;
    border-radius: 15px; 
    padding: 0 0.5em;    
}

.form-container .textarea-field {
    color: black;
    height: 10em;
    width: 100%;
    margin: 5px 0 20px 0;
    border: 1px solid #fafafa;
    border-radius: 15px;
    padding: 0.5em 0.5em;
}

#form-message-values {
    margin-bottom: 20px;
}
#form-message-values p {
    font-weight: bold;
}

.connect-link {
    margin-top: 40px;
    text-decoration: underline;
}

.connect-link a:link, .connect-link a:visited, .connect-link a:hover, .connect-link a:active {
    color: #333;
    text-decoration: none;
}

/* Footer Section
   ========================================================================== */

footer {
    background: #005c10;
}

footer > div {
    text-align: center;
}

footer li {
    list-style-type: none;
    margin-bottom: 1.5em;    
}

footer li a {
    color: #fff;
    text-decoration: none;
}

footer li a:hover {
    color: #fff;
    text-decoration: underline;
}

#footer-top .cta-btn {
    margin-bottom: 1.5em;
}

#logo-tagline, #footer-bottom, #footer-connect {
    color: #fff;
}

#logo-tagline img {
    margin-bottom: 1.5em;
}

#footer-links, #footer-connect {
    border-top: 1px solid #fff;
}

#footer-top {
    display: flex;
    flex-direction: row;    
    padding: 0 0 1.5em 0;
    flex-wrap: wrap;
    column-gap: 3.5em;
}

#logo-tagline, #footer-nav {
    display: flex;
    flex-direction: column;
}

#logo-tagline {
    flex: 1 0 50%;
}

#footer-nav {
    flex: 1;
}

#footer-links, #footer-connect {
    display: flex;
    flex-direction: row;
    justify-content: center;
    flex-wrap: wrap;
}

#footer-links {
    text-align: right;
}

#footer-links, #connect-middle-block {
    padding-top: 1.5em;
}

#connect-left-block, #connect-right-block {
    flex: 1 1 33.33%;
}

#links-left-block {
    flex: 0;
}

#links-right-block {
    min-width: 280px;
    flex: 1 1 66.67%;
    text-align: center;    
}

#connect-middle-block, #connect-right-block {
    text-align: center;
}

#connect-left-block {
    flex: 0;
}

#connect-right-block {
    min-width: 320px;
}

#footer-connect h3 {
    font-weight: normal;
}

#footer-connect .social-link a:link, #footer-connect .social-link a:visited, #footer-connect .social-link a:active {
    color: #fff;
    text-decoration: none;
}

a[href^="mailto:"]:link, a[href^="mailto:"]:visited, a[href^="mailto:"]:active {
    color: #fff;
    text-decoration: none; 
}

#footer-bottom {
    min-width: 320px;
    width: 100%;
    padding: 1.5em 0 0 0;
    border-top: 1px solid #fff;
}

#footer-bottom .social-icon {
    margin-right: 1.5em;
}

#footer-bottom .social-icon img {
    filter: drop-shadow(5px 5px 5px #000);
}

/* ==========================================================================
   Tablet Portrait Styles
   ========================================================================== */

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

    /* Tablet - General Layout
    ========================================================================== */

    header, section:not([id*="parallax"]) {
        width: 85%;
        margin: auto;
        text-align: center;
    }

    div[id^="parallax"] {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;  
    }

    section {
        display: flex;
        flex-direction: row;
        justify-content: center; 
        column-gap: 3.5em;
    }

    #about {
        column-gap: 1.5em;
    }

    #services {
        column-gap: 2.5em;
        row-gap: 3.5em;
    }

    header {
        padding: 0;
    }

    section {
        padding: 3.5em 0;
    }

    #connect-container {
        padding-bottom: 3.5em;
    }

    #connect-container iframe {
        height: 550px;
    }

    footer {
        padding: 3.5em 0 1.5em 0;
    }

    #hero {
        border-bottom: none;
    }

    .mobile-divider {
        display: none;
    }

    /* Tablet - Hero, Testimonial, Contact, Footer Divs Multi Column Section Widths
    ========================================================================== */

    #hero-text-container, #hero > div, #about-container, #about-image-outer {
        flex: 1 0 40%;
        margin: auto;
    }

    #hero-image {
        text-align: center;
    }

    #hero-text-container, #hero-text-container, #about-container, #about-image-outer {
        text-align: left;
    }

    #contact {
        flex-direction: row-reverse;
        justify-content: center;
        align-items: flex-start;
        flex-wrap: wrap;
    }

    #connect-container, .form-container {
        text-align: left;
        margin: 0 auto;
        align-items: flex-start;
    }

    .form-container {
        flex: 0.75 0 280px;
        padding: 2em;
    }

    #connect-container {
        flex: 1 1 50%;
        text-align: center;
    }

    /* Tablet - Client Logos & Testimonial Single Column Section Widths
    ========================================================================== */

    #client-logos-inner, .testimonials-container {
        width: 100%;
    }

    /* Tablet - Service Section
    ========================================================================== */
    #service2 {
        margin: 0;
    }

    /* Tablet - About Section 
    ========================================================================== */
    #about-container, #about-image-outer {
        width: 40%;
    }

    #about-image-container {
        background: url('../images/matthew-shepherd.webp') no-repeat center center;    
        width: 280px;
        height: 280px;
    }

    #about-image-bg {
        background-size: auto;
    }

    /* Tablet - Footer Section 
    ========================================================================== */

    #footer-bottom, #footer-top {
        width: 85%;
    }

    #connect-right-block {
        padding-top: 1.5em;
    }

    #links-left-block {
        flex: 0;
    }

}

/* ==========================================================================
   Small Screens and Laptop Styles
   ========================================================================== */

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

    header {
        padding: 0;
    }

    section {
        padding: 3.5em 0;
    }

    #client-logos-container {
        padding-bottom: 3.5em;
    }

    #contact, #about {
        column-gap: 3.5em;
    }

    #connect-container {
        padding-bottom: 3.5em;
    }

    #links-right-block {
        min-width: 430px;
    }

    .social-link a:link, .social-link a:visited, .social-link a:active {
        font-size: 1em;
    }

    #client-logos-container, #footer-links, #footer-connect {
        border-top: none;
    }

    .testimonials-container blockquote {
        width: 75%;
    }

    #footer-links li {
        display: inline;
        margin-right: 20px;
    }

    #logo-tagline, #links-right-block {
        margin-bottom: 20px;
    }

    #links-right-block, #connect-right-block {
        text-align: right;
    }

    #footer-bottom {
        width: 100%;
    }    

    /* Small Screens and Laptop Styles - Fonts
    ========================================================================== */
    h1 {
        font-size: 1.75em;
    }

    h2 {
        font-size: 1.5em;   
    }
    
}

/* ==========================================================================
   Desktop and Landscape Tablet Styles
   ========================================================================== */

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

    /* Desktop and Landscape Tablet Styles - Navigation Menu
    ========================================================================== */

    header {
        padding: 3.5em 0;
    }

    .menu-items {
        display: flex;
        flex-direction: row;
        list-style-type: none;
        margin: 0;
        padding: 0;
        align-items: center;
    }

    .menu-button-container {
        display: none;
    }

    .menu-items > li:not(:last-child) {
        border-bottom: 1px solid #444;
    }
    .menu-items > li {
        margin: 0 1rem;
        overflow: hidden;
    }

    #menu-toggle ~ .menu-items li {
        display: list-item;
        height:auto;
        margin: 0;
        padding: 0.5em;
        width: auto;
        color: #fff;
        background-color: transparent;
    }

    /* Desktop and Landscape Tablet Styles - Section Styles
    ========================================================================== */

    #client-logos-container {
        padding: 0em 10em 3.5em 10em;
    }

    #services {
        padding: 3.5em 25em; /* Reduce available width to stop service containers growing too wide */
        flex-wrap: nowrap;    
    }

    .service-container {
        flex: 1 0 320px;
    }

    #footer-top {
        flex-wrap: nowrap;
        justify-content: space-between;    
    }

    #footer-nav {
        row-gap: 40%;
    }

    #footer-links, #footer-connect {
        flex-wrap: nowrap;
        padding-bottom: 1em;
    }

    #logo-tagline {
        flex: 0 1 30%;
    }

    #footer-nav {
        flex: 0 1 70%;    
    }

    #logo-tagline, #links-right-block {
        margin-bottom: 0px;
    }

    #links-left-block {
        flex: 1 1 33.33%;
    }

    #links-right-block {
        text-align: right;    
    }

    #footer-connect {
        justify-content: flex-end;
    }

    #connect-container {
        padding-bottom: 0em;
    }

    #connect-left-block, #connect-middle-block {
        flex: 1 1 40%;
    }

    #connect-middle-block {
        padding: 0.5em 1.5em 0 0;
    }

    #connect-right-block {
        min-width: 350px;
        padding: 0 0 0 1em;
    }

    #connect-middle-block, #connect-right-block {
        text-align: left;
    }

    /* Desktop and Landscape Tablet Styles - Fonts
    ========================================================================== */

    h1 {
        font-size: 3em;
    }

    h2 {
        font-size: 2em;   
    }
   
}