:root {
    font-family: "Open sans";
    font-size: calc(.8rem + .4vw);

    /* Variables */
    --primary-color: #6eba01;
    --secondary-color: #222;

    --content-width: 65ch;
    --paragraph-gap: .4rem;
    --page-line-height: 1.4em;
    --section-padding: 4rem 2vw;
    --scroll-wheel-size: 2rem;
    --mobile-main-height: 80vw;
    --side-bar-size: .8rem;
}

::selection {
    background-color: var(--primary-color);
    color: #F8F3F3;
}

body {
    background: #222;
    margin: 0;
    position: relative;
}

* {
    box-sizing: border-box;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: "Montserrat";
    font-weight: 600;
}

h1,
h2,
h3,
h4,
h5,
h6,
p {
    margin: 0;
    line-height: var(--page-line-height);
}

a {
    text-decoration: none;
}

/* Start area */
main {
    min-height: 75vh;
    background-image: url('content/images/milk-carton-table.webp');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center center;
    position: relative;
}

.title-area {
    font-size: calc(1rem + .5vw);
    color: white;
    text-align: center;
}

.title-area h1 {
    font-size: 2em;
    font-weight: bold;
    line-height: 1em;
    margin: 1em auto 0;
    color: black;
    background: white;
    max-width: max-content;
    padding: .4em .8em;
    border-radius: 10em;
    box-shadow: 0px 5px 20px -10px rgba(0, 0, 0, 0.75);
}

.title-area a {
    font-size: 1em;
    line-height: 1em;
    color: white;
    transition: .25s;
}

.title-area a:hover {
    opacity: .5;
}

.title-area .upa-banner {
    background: var(--primary-color);
    padding: .4em;
}

h1 span {
    font-size: .5rem;
}

.section-with-sidebar {
    z-index: 50;
}

.sidebar-container {
    max-width: var(--content-width);
    width: 100%
}

.sidebar {
    font-size: var(--side-bar-size);
    position: fixed;
    left: -.15rem;
    top: 50%;
    transform: translateY(-50%);
    padding: .5rem;
    border: .15em solid black;
    display: flex;
    flex-direction: column;
    gap: .4rem;
    background: white;
    box-shadow: 0px 0px 15px -5px rgba(0, 0, 0, 0.75);
    border-radius: 0rem 1rem 1rem 0rem;
    max-width: max-content;
}

.sidebar img {
    height: auto;
    max-height: 8rem;
    object-fit: contain;
}

.sidebar div {
    display: flex;
    flex-direction: column;
}

.sidebar h3 {
    margin-top: .5em;
}

.services {
    background-image: url('content/images/milk-carton-with-glass.webp');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
}

.services .content {
    background: white;
    padding: 2rem;
    box-sizing: content-box;
}

section {
    background: white;
    padding: var(--section-padding);
    display: grid;
    place-items: center;
    position: relative;
}

.content {
    max-width: var(--content-width);
    display: flex;
    flex-direction: column;
    gap: var(--paragraph-gap);
    border-radius: .5rem;
}

.content h2 {
    font-weight: 600;
    font-size: 1.2rem;
}

.button {
    max-width: max-content;
    background: var(--primary-color);
    color: white;
    font-weight: bold;
    padding: .5em 1em;
    margin-top: .5em;
    align-self: flex-end;
    display: block;
    border-radius: 100rem;
}

footer {
    display: flex;
    gap: 1rem;
    justify-content: center;
    padding: 1rem;
    background: var(--primary-color);
}

footer a,
footer p {
    color: white;
    transition: .25s;
    line-height: 1.5em;
}

footer a:hover {
    opacity: 0.5;
}

/* Scroll wheel animation */
.mouse {
    font-size: var(--scroll-wheel-size);
    width: .6em;
    height: 1em;
    border: .075em solid currentcolor;
    border-radius: 20em;
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    color: white;
}

.mouse::before {
    content: '';
    width: .2em;
    height: .2em;
    position: absolute;
    top: .1em;
    left: 50%;
    transform: translateX(-50%);
    background-color: currentcolor;
    border-radius: 50%;
    opacity: 1;
    animation: wheel 2s infinite;
}

@keyframes wheel {
    to {
        opacity: 0;
        top: .62em;
    }
}

/* Dropcap */
.dropcap {
    font-size: 3em;
    font-weight: bold;
    float: left;
    margin-right: 0.2em;
    line-height: 0.8em;
}

/* Responsive */
@media screen and (max-width: 1500px),
(orientation: portrait) {
    .sidebar {
        position: relative;
        left: 0;
        top: 0;
        transform: none;
        display: flex;
        flex-direction: row;
        gap: 1em;
        background: white;
        box-shadow: none;
        border-radius: 0;
        justify-self: flex-start;
        margin-bottom: .5em;
        border: .2em solid black;
    }

    .sidebar img {
        max-height: calc(3 * var(--page-line-height));
        object-position: left;
    }
}

@media all and (max-width: 980px) {
    main {
        min-height: var(--mobile-main-height);
    }

    footer {
        flex-direction: column;
    }

    .mouse {
        display: none;
    }
}