:root {
    --header: #6D2323;
    --background: #A31D1D;
    --device: #931F1F;
    --buttons: #E5D0AC;
    --buttons-hover: #F7EDD1;
    --buttons-active: #FEF9E1;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Roboto, sans-seif
}

/* Header */

.header {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 5vh;
    background-color: var(--header);
    color: white;
    border-bottom: 0.5vh solid var(--buttons);
    text-shadow: 0 0 5px black;
}

/* MAIN */

.main {
    background-color: var(--background);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20vh 5vw;
    gap: 3vw;
    flex-wrap: wrap;
}

.control-text,
h5 {
    color: white;
    text-shadow: 0 0 5px black;
}

.controls {
    background-color: var(--device);
    padding: 5vh 5vw;
    border-radius: 15px;
    border: 0.5vh solid var(--buttons);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 80vh;
}

.tool-container,
.main-colour-container,
.slider-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

.colour-container {
    display: flex;
    flex: 1;
    gap: 10px;
}

.colour-box {
    border-radius: 3px;
    width: 40px;
    height: 40px;
    border: 3px solid var(--buttons);
}

#rainbow-box {
    background-color: darkgray;
    display: flex;
    justify-content: center;
    align-items: center;
}

#black-box {
    background-color: black;
}

.shade-box-behind {
    border-radius: 3px;
    width: 40px;
    height: 40px;
    background-color: white;
    z-index: 0;
    position: relative;
    overflow: hidden;
}

#shading-box {
    background-color: #E6E6E6;
    z-index: 1;
    position: absolute;
} 

button {
    padding: 10px 20px;
    width: 80px;
    height: 40px;
    background-color: var(--buttons);
    color: white;
    text-shadow: 0 0 5px black;
    border-radius: 10px;
    border: var(--header);
    display: flex;
    justify-content: center;
    align-items: center;
}

button:hover {
    background-color: var(--buttons-hover);
    width: 85px;
    height: 42.5px;
}

button:active {
    background-color: var(--buttons-active);
    width: 90px;
    height: 45px;
}

.tool-container button,
#clear-grid {
    width: 135px;
}

#slider::-webkit-slider-runnable-track  {
    -webkit-appearance: none;
    appearance: none;
    background-color: #E5D0AC;
    height: 8px;
    border-radius: 5px;
}

#slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    background-color: white;
    height: 20px;
    width: 20px;
    margin-top: -5px;
    border-radius: 50%;
    cursor: pointer;
}

#slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    background: transparent;
}

.slider-fill {
    width: 0px;
    height: 8px;
    background-color: white;
    border-radius: 5px;
    position: absolute;
    z-index: 0;
    left: 0;
}

.slider-container {
    position: relative; 
}

.sketch-container {
    min-width: 60vw;
    min-height: 60vw;
    background-color: var(--device);
    flex-shrink: 0;
    border-radius: 50px;
    border: 0.5vh solid var(--buttons);
    display: flex;
    justify-content: center;
    align-items: center;
}

#grid {
    min-width: 50vw;
    min-height: 50vw;
    width: 50vw;
    height: 50vw;
    border: 0.5vh solid var(--buttons);
    display: flex;
    flex-wrap: wrap;
    background-color: white;
}

.grid-item {
    box-sizing: border-box;
    background-color: white;
    border: 0.01px solid lightgray;
}

/* FOOTER */

.footer {
    position: fixed;
    bottom: 0px;
    height: 7vh;
    width: 100vw;
    padding: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: var(--header);
    color: white;
    border-top: 0.5vh solid var(--buttons);
    text-shadow: 0 0 5px black;
}

.github {
    height: 3.5vh;
    width: auto;
    margin-left: 10px;
}

.github:hover {
    height: 3.7vh;
}

.github:active {
    height: 3.8vh;
}