* {
    font-family: 'Open Sans', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    --light-color: #FF8F00;
    --light-red: #B5153B;
    --navbar-size: 60px;

    --maestro-background: #37474F;

    --samwise-background: #1f1b17;
    --samwise-primary: #c49a6c;
    --samwise-secondary: #c0cc9a;

    margin: 0;
}

p {
    margin: 0px;
}

pre {
    overflow-x: auto;
    white-space: pre-wrap;
    white-space: -moz-pre-wrap;
    white-space: -pre-wrap;
    white-space: -o-pre-wrap;
    word-wrap: break-word;
}

a {
    color: white;
}

/* NavBar */
#nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;

    height: var(--navbar-size);

    display: grid;
    grid-template-columns: auto auto auto auto auto;
    align-items: center;
    justify-items: center;

    background-color: white;

    transition: box-shadow .5s;
}

#nav>button {
    height: 100%;
    width: 100%;

    background-color: transparent;
    border: none;
    color: var(--light-color);
    font-size: 1.6em;
    text-align: center;
    text-decoration: none;
}

#nav>button:hover {
    cursor: pointer;
}

.nav-space {
    width: 64px;
}

.nav-shadow {
    box-shadow: 0 0 10px rgba(0, 0, 0, .2);
}

/* Main */
#main {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    height: calc(100vh - var(--navbar-size));
}

#stripe {
    position: absolute;
    top: -27vw;
    left: -27vw;

    width: 54vw;
    height: 54vw;

    background-color: var(--light-color);
    transform: rotate(45deg);
}

#stripe-red {
    position: fixed;
    top: -12vw;
    right: -12vw;

    width: 24vw;
    height: 24vw;

    background-color: var(--light-red);
    transform: rotate(45deg);
}

#logo-layout {
    max-width: 90vw;
    max-height: 70vh;
}

#logo {
    height: auto;
    max-height: 100%;
    max-width: 100%;

    display: block;
    margin: auto auto;
}

#logo-layout>h2 {
    margin: 0px 16px 16px 16px;

    color: #0005;
    font-weight: 500;
    font-size: 1.5em;
    text-align: center;
}

/* About */
#about {
    display: grid;
    padding: 64px;

    background-color: var(--light-color);
    color: white;
}

#about-right-arrow {
    grid-area: icon;

    width: 200px;
}

#about-down-arrow {
    grid-area: icon;
    justify-self: center;

    width: 180px;
}

#about-text-gap {
    height: 32px;
}

#about-text {
    grid-area: text;
}

#about-text>h2 {
    font-size: 2.4em;
    text-align: center;
}

#about-text>pre {
    text-align: justify;
    font-size: 1.38em;
}

/********** App Pages **********/

.app-container {
    display: grid;
    grid-template-areas:
        'logo'
        'button';
    grid-template-rows: 1fr auto;
    grid-template-columns: auto;

    height: calc(100vh - var(--navbar-size));
}

.app-content {
    display: flex;
    flex-direction: column;

    grid-area: logo;

    align-items: center;
    align-self: center;
    justify-self: center;
}

.app-logo {
    width: 50vh;
    max-width: 95%;
    height: auto;

    display: block;
    margin: auto auto;
}

.app-title {
    margin-top: 64px;

    color: white;
    font-size: 2em;
    font-weight: 500;
    text-align: center;
}

.app-subtitle {
    margin-top: 16px;

    color: white;
    font-size: 1.5em;
    text-align: center;
}

.app-button {
    grid-area: button;
    justify-self: center;
    margin-bottom: 64px;

    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 54px;
    padding: 0 32px;

    background-color: transparent;
    border: solid white 1px;
    border-radius: 27px;
    color: white;
    font-size: 1.1em;
    text-decoration: none;

    transition: background-color .5s, color .5s;
}

.app-button:focus {
    outline-color: white;
}

@media only screen and (max-width: 600px) {
    .app-title {
        font-size: 1.6em;
    }

    .app-subtitle {
        font-size: 1.2em;
    }
}

/********** Samwise **********/

#samwise {
    background-color: var(--samwise-background);
}

#samwise-title {
    color: var(--samwise-secondary);
}

#samwise-subtitle {
    max-width: 750px;
    color: var(--samwise-primary);
}

/********** m.a.estro **********/

#maestro {
    background-color: var(--maestro-background);
}

#maestro-logo {
    max-width: 82%;
}

#maestro-lang-warning {
    font-size: .75em;
    opacity: .7;
}

/******************** Footer ********************/
#footer {
    display: grid;

    row-gap: 16px;

    background-color: white;
    color: rgba(0, 0, 0, .84);
    padding: 32px 16px 32px 16px;
}

#footer * {
    font-size: .875em;
}

footer p {
    font-weight: 300;
}

footer>a {
    margin: auto 24px auto 0;
}

#studio-logo {
    grid-area: logo;

    height: 120px;
    shape-rendering: auto;
}

.studio-slogan {
    font-size: 1.125em !important;
    font-weight: 500;
}

#copyright {
    grid-area: company-info;

    align-content: flex-start;
    align-self: center;
    text-align: end;
}

#copyright a {
    color: rgba(0, 0, 0, .84);
    font-size: 1.12em;
    margin: 0;
}

#language-selector {
    grid-area: lang;

    background-color: transparent;
    border-radius: 8px;
    color: rgba(0, 0, 0, .84);
    font-weight: 300;
    padding: 8px 16px;
    text-align: center;

    -webkit-appearance: none;
    appearance: none;
}

#small-screen-info {
    display: none;
}

#large-screen-info {
    display: none;
}

#rights {
    grid-area: rights;

    align-content: flex-end;
    align-self: center;
}

#legal-links {
    grid-area: legal-links;

    display: flex;
    justify-self: center;
}

#legal-links a {
    color: rgba(0, 0, 0, .84);
    margin: 0 32px;
    text-align: center;
}

@media(max-width: 840px) {
    #footer {
        grid-template-areas:
            'logo'
            'copyright'
            'rights'
            'company-info'
            'lang';

        grid-template-columns: auto;
        grid-template-rows: auto auto auto auto auto;
    }

    #studio-logo {
        height: auto;
        width: 100%;
        margin: 0 0 16px 0;
    }

    #logo-layout>h2 {
        margin-top: 16px;
        font-size: 1.125em;
    }

    #copyright {
        text-align: center;
        margin: 0;
    }

    #copyright a {
        font-size: 4.5vw;
        word-wrap: break-word;
    }

    #small-screen-info {
        display: inline;
    }

    #rights {
        text-align: center;
        margin: 0;
    }
}

@media(min-width: 841px) {
    #footer {
        grid-template-areas:
            'logo rights free-space company-info'
            'lang lang lang lang';

        grid-template-columns: auto auto 1fr auto;
        grid-template-rows: auto auto;
    }

    #large-screen-info {
        display: inline;
    }
}

/******************** General queries ********************/

/* Mobile query */
@media only screen and (max-width: 600px) {
    #nav>button {
        font-size: 1em;
    }

    #stripe {
        top: -20vmax;
        left: -20vmax;

        width: 40vmax;
        height: 40vmax;
    }

    #about {
        grid-template-areas:
            'icon'
            'text';
        grid-template-rows: auto auto;
        grid-template-columns: auto;
        padding: 16px;

        background-color: var(--light-color);
        color: white;
    }

    #about-right-arrow {
        visibility: hidden;
    }

    #about-down-arrow {
        visibility: visible;
    }

    #about-text>h2 {
        font-size: 1.75em;
        text-align: center;
    }

    #about-text>pre {
        font-size: 1.12em;
        text-align: left;
    }

    .app-button {
        height: 48px;

        border-radius: 60px;
        font-size: 1.12em;
        padding: 0 48px;
    }
}

/* Desktop query */
@media only screen and (min-width: 601px) {
    .app-button:hover {
        background-color: white;
        color: rgba(0, 0, 0, .84);
        cursor: pointer;
    }

    #about {
        grid-template-areas: 'left-margin icon separator text right-margin';
        grid-template-rows: auto;
        grid-template-columns: 1fr auto 64px minmax(0px, 800px) 1fr;
    }

    #about-right-arrow {
        visibility: visible;
    }

    #about-down-arrow {
        visibility: hidden;
    }
}
