:root {
    --site-width: clamp(300px, 96vw, 1200px);
    --site-padding: calc(calc(100vw - var(--site-width))/2);
    --content-height: clamp(300px, calc(1200px - 55vw), 520px);

    --main-colour: #273C2C;
    --secondary-colour: #1b98a8;
    --third-colour: #3a3a3a;
    --minor-colour: rgb(255, 255, 255);
    
    --main-font: Roboto;
    --secondary-font: "Expletus Sans";
}
* {
    font-family: var(--main-font);
}
html {
    scrollbar-gutter: stable;
}
html, body {
    padding: 0;
    margin: 0;
}
#bg-video {
    z-index: -5;
    width: clamp(550px, 100%, 100%);
    height: 100vh;
    object-fit: cover;
    position: fixed;
    top: 0;

    box-sizing: border-box;
}
#video-overlay {
    z-index: -4;
    background-color: rgba(22, 22, 22, 0.3);
    width: 100vw;
    height: 100vh;
    top: 0;
    position: fixed;

}
#video-under {
    z-index: -20;
    background-color: black;
    width: 100vw;
    height: 100vh;
    top: 0;
    position: fixed;
}
main {
    margin-top: 25vh;
    width: 100%;
}
main > {
    width: var(--site-width);
    padding: 0 var(--site-padding);
}
#site-top {
    position: absolute;
    top: 0;
}

button {
        font-family: var(--main-font);
        font-size: clamp(1.2rem, calc(1.2rem + 0.5vw), 4.2rem);
        font-weight: 700;
        background-color: var(--secondary-colour);
        display: inline-flex;

        padding: 20px;
        border-radius: 4px;
        border: none;

        transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
    }
    .right-arrow {
        margin-left: 12px;
        width: 10px;
        height: 10px;
        border-bottom-right-radius: 3px;
        border-right: 5px solid var(--minor-colour);
        border-bottom: 5px solid var(--minor-colour);
        transform: rotate(45deg);

        display: inline-block;
        align-self: center;

        transition: transform 0.2s ease;
    }
    button:hover {
        background-color: #1aa7b9;
        transform: translate(4px, -4px) scale(102%, 102%);
        .right-arrow {
            transform: rotate(-45deg);
        }
    }

#landing-span {
    h1 {
        display: block;
        padding-top: 0;
        margin: 0;
        margin-left: clamp(15px, calc(calc(100vw - var(--site-width))/2), 500px);
        font-size: clamp(1.8rem, calc(1.8rem + 2vw), 5.6rem);
        color: var(--secondary-colour);
    }
    ul {
        list-style: none;
        padding-left: 0;
        margin-top: 0;
        margin-bottom: 20px;
        color: var(--secondary-colour);
        height: 1lh;
        overflow: hidden;
    }
    ul li {
        position: relative;
        transition: transform 0.5s ease;
        opacity: 0;
    }
    ul li.before {
        display: block;
        transform: translateY(-100%);
        opacity: 0;
    }
    ul li.selected {
        display: block;
        transform: translateY(0%);
        opacity: 1;
    }
    ul li.after {
        display: block;
        transform: translateY(100%);
        opacity: 1;
    }
    button {
        color: rgb(210,210,210);

        margin: 10px 0 10px calc(calc(100vw - var(--site-width))/2);
        margin-left: clamp(15px, calc(calc(100vw - var(--site-width))/2), 500px);
    }
    .right-arrow {
        border-color: rgb(210,210,210);
    }
    button:hover {
        color: var(--minor-colour);
        .right-arrow {
            border-color: var(--minor-colour);
        }
    }
    p {
        font-size: clamp(1.2rem, calc(1.2rem + 1vw), 1.8rem);
        font-weight: 300;
        text-indent: clamp(1.2rem, calc(1.2rem + 1vw), 1.8rem) each-line;
        color: var(--minor-colour);
        width: clamp(270px, 90vw, 1000px);

        padding-left: clamp(15px, calc(calc(100vw - var(--site-width))/2), 500px);
    }
}

#service-section {
    display: flex;
    z-index: 1;
    flex-direction: column;
    background-color: white;
    border-radius: 16px 16px 0 0;
    width: var(--site-width);
    padding: 50px var(--site-padding);
    margin-top: 15vh;

    a {
        color: inherit;
        text-decoration: none;
    }


    #service-heading {
        display: flex;
        justify-content: center;
        flex-direction: column;

        z-index: 0;
        padding-bottom: 50px;
    }
    @media only screen and (max-width: 800px) {
        #service-heading {
            width: 90%;
            margin: auto;
        }
    }
        h2 {
            font-family: var(--main-font);
            font-size: clamp(1.6rem, calc(1.0rem + 1vw), 2.6rem);
            font-weight: 700;
            text-align: center;
            justify-self: center;

            padding: 10px 20px;
            margin: 10px auto;

            background-color: white;
            color: var(--secondary-colour);
            position: relative;
            display: inline;
        }
        span {
            display: block;
            font-size: clamp(1.2rem, calc(0.8rem + 0.6vw), 1.8rem);
            font-weight: 400;
            color: rgb(31,31,31);
            text-align: center;

            border: 3px solid var(--secondary-colour);
            border-radius: 6px;

            padding: 50px 0 30px 0;
            width: 100%;
            margin: auto;
            z-index: -1;

            transform: translateY(-40px);
        }
        #service-heading {
            flex: 1;
        }
        #service-grid {
            flex: 1;
        }
    
        #service-grid {
            display: flex;
            flex-direction: row;
            column-gap: 35px;

            margin-top: 0;
            margin-bottom: 20px;
        }
        @media only screen and (max-width: 800px) {
            #service-grid {
                flex-direction: column;
                row-gap: 65px;
                width: 90%;
                margin: auto;
            }
        }
        @media only screen and (min-width: 801px) {
            #service-grid {
                transform: translateX(2%);
            }
        }
        .service-grid-unit {
            flex: 1;
            
            display: grid;
            grid-template-columns: 1fr;
            grid-auto-flow: row;

            margin-top: 20px;

            box-sizing: border-box;
        }
        .service-grid-unit {
            > img {
                width: 94%;
                height: auto;
                margin-left: 0;

                border-radius: 4px;
            }
            h3 {
                font-size: clamp(1.6rem, calc(1.6rem + 0.3vw), 2.9rem);
                color: var(--secondary-colour);
                margin: 0;
            }
            p {
                font-size: clamp(1.1rem, calc(1.1rem + 0.7vw), 1.4rem);
                align-self: center;
                justify-self: center;
            }
            button {
                justify-content: space-between;

                color: rgb(247,247,247);
                width: 97%;
                font-size: clamp(1.2rem, calc(1.2rem + 0.7vw), 1.6rem);
            }
            @media only screen and (max-width: 800px) {
                button {
                    width: 100%;
                }
                img {
                    margin: auto;
                }
            }
            .right-arrow {
                border-color: rgb(247,247,247);
            }
            button:hover {
                color: white;

                .right-arrow {
                border-color: white
                }
            }
            .header-wrapper {
                display: flex;
                justify-content: space-between;
                align-items: center;

                height: 100%;
                margin: 30px 0;
            }
            .service-icon-wrapper {
                display: inline-flex;
                align-items: center;
                justify-content: center;

                border-radius: 100%;
                background-color: var(--secondary-colour);
                height: 60px;
                width: 60px;
                
                transform: translateX(-10px);
            }
            @media only screen and (max-width: 800px) {
                .service-icon-wrapper {
                    transform: none;
                }
            }
            .service-icon {
                height: 60%;
                width: 60%;
            }
        }
}
#process-section {
    display: flex;
}
#process-span {
    z-index: 2;
    display: block;
    background-color: white;

    width: var(--site-width);
    padding: 50px var(--site-padding);

    overflow-x: hidden;
}
#process-span {
    #process-heading {
        display: flex;
        justify-content: center;
        flex-direction: column;

        text-align: center;
        margin-bottom: 40px;
    }
    @media only screen and (max-width: 450px) {
        #process-heading {
            margin-bottom: 0;
        }
        #process-titles {
            height: 250px;
            transform: translateX(25%);
        }
    }
    #process-heading {
        h2 {
        font-family: var(--main-font);
        font-size: clamp(1.6rem, calc(1.6rem + 1vw), 5.6rem);
        font-weight: 700;
        color: var(--secondary-colour);
        
        margin: 80px 0 10px 0;
        }
        span {
            font-size: clamp(1.1rem, calc(1.1rem + 0.7vw), 1.4rem);
            font-weight: 400;
            color: rgb(31,31,31);
        }
    }
    #process-titles {
        @media only screen and (max-width: 450px) {
            ul {
                flex-direction: column;
            }
            li {
                width: 150px;
                margin-top: 30px;
                text-align: center;
            }
            #titles-connector {
                border-right: 3px solid rgb(230,230,230);
                height: 150px;
                width: 0;

                position: relative;
                bottom: 170px;
                left: 90px;
            }
        }
        @media only screen and (min-width: 451px) {
            #titles-connector {
                border-bottom: 3px solid rgb(230,230,230);
                width: 100%;
                height: 0;
                transform: translateY(-35px);
            }
        }
        ul {
            list-style: none;
            display: flex;
            justify-content: space-between;

            padding: 0;
        }
        li {
            display: inline;
            position: relative;
            z-index: 1;
            padding: 5px 15px;

            font-size: 1.4rem;
            font-weight: 400;
            color: black;
            background-color: white;

            border-radius: 3px;
            border: 2px solid rgb(230,230,230);
        }
        li.selected {
            background-color: rgb(230,230,230);
        }
    }
    #process-content {
        display: flex;
        max-height: 400px;
        overflow: hidden;
    }
    
    #process-content {
        ul {
            display: block;
            list-style: none;
            width: 100%;
            height: 350px;

            padding-left: 0;
        }
        li {
            display: flex;
            width: clamp(200px, 90%, 100%);
            margin: auto;
            height: 350px;

        }
        .process-text {
            z-index: 0;

            display: flex;
            flex-direction: column;
            width: clamp(200px, 80%, 80%);
            margin: auto;

            border-radius: 10px;
            border: 2px solid rgb(230,230,230);
            padding: clamp(5px, 2vw, 20px);
            transition: transform 0.35s ease, opacity 0.25s ease;
        }

        #process-text-1 { --ty: 0% }
        #process-text-2 { --ty: -350px }
        #process-text-3 { --ty: -700px }
        .process-text.left { --tx: -60%; --op: 0;}
        .process-text.center { --tx: 0%; --op: 1;}
        .process-text.right { --tx: 60%; --op: 0;}
        .process-text {
            transform: translateX(var(--tx)) translateY(var(--ty));
            opacity: var(--op);
        }

        #left-process-arrow { 
            --rotDeg: 45deg; --offsetpx: 25px; 
            border-left: 3px solid rgb(31,31,31);
            border-bottom-left-radius: 6px;
        }
        #right-process-arrow { 
            --rotDeg: -45deg; --offsetpx: -25px; 
            border-right: 3px solid rgb(31,31,31);
            border-bottom-right-radius: 6px;
        }
        .process-arrow {
            z-index: 1;
            height: clamp(20px, 5vw, 40px);
            width: clamp(20px, 5vw, 40px);
            border-bottom: 3px solid rgb(31,31,31);

            transition: transform 0.1s ease;
            align-self: center;

            transform: rotate(var(--rotDeg)) translateX(var(--offsetpx)) scale(100%);
        }
        .process-arrow:hover {
            transform: rotate(var(--rotDeg)) translateX(var(--offsetpx)) scale(135%);
        }

        h3 {
            font-size: 1.8rem;
        }
        p {
            font-size: clamp(1.1rem, calc(1.1rem + 0.7vw), 1.4rem);
        }
        .header-divider {
            background-color: var(--secondary-colour);
            height: 4px;
            width: 25%;
            border-radius: 6px;
        }
    }
}
#about {
    background-color: white;
    margin: 0 auto;
    
    width: var(--site-width);
    padding: 100px var(--site-padding);
}
#about {
    #about-picture {
    float: left;
    width: clamp(300px, 45%, 600px);
    margin: 0 2vw 2vw 0;

    border-radius: 4px;
    }
    @media only screen and (max-width: 450px) {
        #about-picture {
            display: block;
            margin: auto;
            float: none;
        }
    }
    #header {
        h2 {
            font-family: var(--main-font);
            font-size: 2.2rem;
            font-weight: 700;
            color: var(--secondary-colour);
            text-align: center;
            margin-top: 0;
        }
        @media  only screen and (min-width: 451px) {
            h2 {
                transform: translateX(-1.5vw);
            }
        }
        p {
            font-size: 1.4rem;
            font-weight: 400;
            color: rgb(31,31,31);
            text-indent: 1.4rem;

            transform: translateX(20px);
            max-width: 90%;
        }
        #header-first-p {
            text-align: center;
        }
    }
}
#why-us {
    background-color: white;
    margin-top: 0;
    width: var(--site-width);
    padding: 100px var(--site-padding);
    z-index: 0;
}
#why-us {
    #why-us-span {
        border: 3px solid var(--secondary-colour);
        border-radius: 6px;
        padding: 15px;
        z-index: 1;
        display: flex;
        justify-content: space-between;
    }
    @media only screen and (max-width: 750px) {
        #why-us-span {
            flex-direction: column;
        }
    } 
    h2 {
        margin: 10px 0 0 2vw;
        padding: 0 10px;
        font-family: var(--main-font);
        font-size: 2.2rem;
        font-weight: 700;
        color: var(--secondary-colour);

        display: inline;

        position: relative;
        bottom: 35px;
        background-color: white;
        z-index: 1;
    }
    @media only screen and (max-width: 400px) {
        h2 {
            display: block;
            width: 245px;
            margin: 0 auto;
            padding: 0;
            text-align: center;
        }
    }
    ul {
        padding-bottom: 10px;
    }
    li {
        margin: 10px;
        font-family: var(--main-font);
        font-size: 1.4rem;
        font-weight: 400;
    }
    img {
        max-width: 100%;
        border-radius: 15px;
        margin: auto 0;
    }
    @media only screen and (max-width: 500px) {
        img {
            margin: auto;
        }
    }
}
#faq {
    background-color: white;
    width: var(--site-width);
    padding: 100px var(--site-padding);
}
#faq {
    h2 {
        margin-top: 0;
        padding-left: 30px;
        color: var(--secondary-colour);
        font-family: var(--main-font);
        font-size: 2.2rem;
        font-weight: 700;
    }
    > li {
        list-style: none;
        background-color: white;

        border-top: 2px solid rgb(200,200,200);
        padding: 35px;
    }
    > li:first-of-type {
        border-top: none;
    }
    > li {
        h3 {
            display: inline-flex;
            justify-content: space-between;
            gap: 10px;

            font-family: var(--main-font);
            font-size: 1.6rem;
            font-weight: 500;
            margin: 0;
            width: 100%;
        }
        .faq-arrow {
        margin-left: 20px;
        min-width: 10px;
        min-height: 10px;
        border-bottom-right-radius: 3px;
        border-right: 5px solid var(--secondary-colour);
        border-bottom: 5px solid var(--secondary-colour);
        transform: rotate(45deg);

        display: inline-block;
        align-self: center;

        transition: transform 0.2s ease;
        }
        .faq-arrow.up {
            transform: rotate(-135deg);
        }
    }
    span {
        font-family: var(--main-font);
        font-size: 1.4rem;
        font-weight: 400;

        p {
            margin: 30px 0 0 0;
            text-indent: 1.4rem each-line;
        }
    }
    span.hidden {
        display: none;
    }
    span.shown {
        display: block;
    }

    li.hidden {
        background-color: white;
    }
    li.shown {
        background-color: rgb(248,248,248);
    }
}

footer {
    background-color: var(--secondary-colour);
    width: var(--site-width);
    padding: 10px var(--site-padding);
    padding-top: 50px;
}
footer {
    > span {
        display: flex;
        justify-content: space-between;
    }
    @media only screen and (max-width: 700px) {
        > span {
            flex-direction: column;
        }
    }
    div {
        display: flex;
        align-self: center;

        img {
            max-height: 120px;
        }
        ul {
            display: inline-flex;
            flex-direction: column;
            justify-content: space-around;
            list-style: none;

            margin: 0;
            padding-left: 20px;

            li {
                line-height: 60px;
                font-size: 2.1rem;
                font-weight: 700;
                font-family: var(--secondary-font);
                color: white;
            }
        }
    }
    p:first-of-type {
        margin-top: 20px;
        width: 100%;
        color: white;
        text-align: left;
        font-size: 1.7rem;
        font-weight: 600;
    }

    #link-list {
        display: flex;

        ul {
            list-style: none;
            color: rgb(220,220,220);
            font-size: 1.3rem;
            margin-left: 20px;
        }
        li {
            margin-top: 20px;
        }
        li:first-child {
            margin-top: 0;
            font-size: 1.5rem;
            color: white;
        }
        li:not(:first-child):hover {
            cursor: pointer;
        }
        a {
            font-weight: 400;
            text-align: left;
            text-decoration: none;
        }
    }
    @media only screen and (max-width: 750px) {
        #link-list {
            flex-direction: column;
            
            ul {
                margin-left: 0;
                padding-left: 10px;
            }
        }
    }

    #copyright {
        margin-top: 30px;
        width: 100%;
        color: rgb(230,230,230);
        text-align: center;
        font-size: 1.2rem;
    }
    a {
        display: block;
        text-align: center;
        width: 100%;
        color: rgb(230,230,230);
        font-size: 1.2rem;
        font-weight: 600;
    }
}