/****** LIGHT MODE ******/
html {
    font-size: 62.5%;    /* Sets 1 rem to 10px */
    box-sizing: border-box;
    overflow-x: hidden;
}

@media screen and (max-width: 860px) {
    html {
        font-size: 55%;
    }
}

@media screen and (max-width: 760px) {
    html {
        font-size: 50%;
    }
}

@media screen and (max-width: 670px) {
    html {
        font-size: 62.5%;
    }
}

*,
*::before,
*::after {
    padding: 0;
    margin: 0;
    box-sizing: inherit;
}

body {
    font-family: 'Inter', sans-serif;
    font-size: 1.4rem;
    background-color: hsl(0, 0%, 100%);
}

.container-outer {
    height: 100vh;
    width: 100vw;

    display: flex;
    flex-direction: column;
    align-items: center;

    background: linear-gradient(
        to bottom,
        hsl(225, 100%, 98%),
        hsl(225, 100%, 98%) 25rem,
        hsl(0, 0%, 100%) 25rem,
        hsl(0, 0%, 100%) 100%
    );
}

.container-inner {
    width: 80%;
    margin-top: 4rem;
}

@media screen and (max-width: 980px) {
    .container-inner {
        width: 90%;
    }
}


/*** HEADING ***/
.top__heading {
    display: flex;
    width: 100%;
    justify-content: space-between;
    align-items: center;
}

.top__heading__title h1 {
    font-size: 3rem;
    margin-bottom: .5rem;
    color: hsl(230, 17%, 14%);
}

.top__heading__title h3 {
    color: hsl(228, 12%, 44%);
    margin-bottom: 4rem;
}

@media screen and (max-width: 580px) {
    .top__heading__title h1 {
        font-size: 2.5rem;
    }

    .top__heading__title h3 {
        font-size: 1.4rem;
    }
}

@media screen and (max-width: 470px) {
    .top__heading {
        flex-direction: column;
        justify-content: stretch;
    }

    .top__heading__title {
        width: 100%;
        border-bottom: 1px solid darkslategrey;
    }

    .top__heading__title h3 {
        margin-bottom: 2rem;
    }
}


/*** SWITCH ***/
.top__heading__switch {
    display: flex;
    align-items: center;
    color: hsl(228, 12%, 44%);
}

button {
    height: 2.5rem;
    width: 5rem;
    margin-left: 1.5rem;
    border: none;
    border-radius: 2rem;
    background: hsl(230, 22%, 74%);
    position: relative;
}

.switch {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translate(-15%, -50%);

    display: inline-block;
    content: "";
    height: 2rem;
    width: 2rem;
    border-radius: 50%;
    background: hsl(225, 100%, 98%);
}

@media screen and (max-width: 580px) {
    #button-text {
        font-size: 1.4rem;
    }

    button {
        height: 2rem;
        width: 4rem;
        margin-left: 1rem;
    }

    .switch {
        height: 1.6rem;
        width: 1.6rem;
    }
}

@media screen and (max-width: 470px) {
    .top__heading__switch {
        width: 100%;
        justify-content: space-between;
        
        margin-top: 2rem;
        margin-bottom: 3rem;
    }
}




/****** DARK MODE ******/
.body--dark {
    background-color: hsl(230, 17%, 14%);
    transition: background-color .5s;
}

.container-outer--dark {
    background: linear-gradient(
        to bottom,
        hsl(232, 19%, 15%),
        hsl(232, 19%, 15%) 25rem,
        hsl(230, 17%, 14%) 25rem,
        hsl(230, 17%, 14%) 100%);
}


/*** SWITCH ***/
.clicked {
    background: linear-gradient(90deg, hsl(210, 78%, 56%), hsl(146, 68%, 55%));
}

.switch--clicked {
    left: 0;
    transform: translate(15%, -50%);
    background: hsl(232, 19%, 15%);
}

/*** UTILITY CLASSES ***/
.white-text {
    color: hsl(0, 0%, 100%) !important;
    transition: color .5s;
}

.blue-text {
    color: hsl(228, 34%, 66%) !important;
    transition: color .5s;
}




/****** INCLUDED STYLES ******/
.attribution { font-size: 11px; text-align: center;}
.attribution a { color: hsl(228, 45%, 44%); }

.attribution {
    background-color: hsl(0, 0%, 100%);
    transition: background-color .5s;
}


/* Dark */
.attribution--dark {
    background-color: hsl(230, 17%, 14%);
    transition: background-color .5s;
    color: white;
}