:root {
    --h-size: 30px;
    --p-size: 16px;
}


*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    font-family: var(--main-font);
    width: 100vw;
    -webkit-font-smoothing: antialiased;
}

.frc {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.rc {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    padding: 30px;
    align-items: center;
}

.rt {
    height: 100%;
    width: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: visible;
    box-sizing: border-box;
}



@media (max-width: 900px) {
    .rc {
        flex-direction: column;
        padding: 20px;
    }

    .rt {
        height: 50%;
        width: 100%;
    }

    .frc {
        padding: 25px;
    }

    :root {
        --h-size: 25px;
        --p-size: 17px;
    }

}

@media (max-width: 450px) {
    :root {
        --h-size: 20px;
        --p-size: 15px;
    }

    .rc {
        width: 100vw;
        padding: 5px;
    }

    .frc {
        padding: 20px;
    }
    
}

a:visited, a:active {
    color: inherit;
    text-decoration: none;
}

h1, h2, h3, h4, h5, h6 {
    font-size: var(--h-size);
}

p {
    font-size: var(--p-size);
}

/* #endregion */

/* #region Form Styling */

form {
    width: calc(100% - 50px);
    margin: 10px auto;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 25px;
    font-family: var(--main-font);
    font-size: 0.8rem;
}

/* Apply styles to all form elements */
form input, 
form textarea, 
form select, 
form button, 
form output {
    outline: none;
    background: transparent;
    color: var(--def-txt-clr);
    padding: 5px;
    border: none;
    border-bottom: 1px solid #434343;
    transition: all ease 500ms;
}

/* Placeholder styles */
form input::placeholder, 
form textarea::placeholder {
    font-family: var(--main-font);
    font-size: 0.9rem;
    opacity: 0.6;
}

form textarea {
    resize: vertical;
    overflow-y: visible;
}

/* When placeholder is shown */
form input:placeholder-shown, 
form textarea:placeholder-shown {
    opacity: 0.6;
}

/* When input has content */
form input:not(:placeholder-shown), 
form textarea:not(:placeholder-shown) {
    opacity: 1;
}

/* Focus & Active styles */
form input:focus, 
form textarea:focus, 
form select:focus, 
form button:focus, 
form input:active, 
form textarea:active, 
form select:active, 
form button:active {
    outline: none;
    background: transparent;
    color: var(--def-txt-clr);
    padding: 4px;
    border-bottom: 2px solid var(--def-main-clr);
    transition: all ease 500ms;
    opacity: 1;
}

/* Style checkboxes and radio buttons */
form input[type="checkbox"], 
form input[type="radio"] {
    width: 16px;
    height: 16px;
    margin-right: 5px;
    cursor: pointer;
}

/* Style file input */
form input[type="file"] {
    border: none;
    padding: 5px;
    cursor: pointer;
}

/* Style range slider */
form input[type="range"] {
    width: 100%;
    cursor: pointer;
}

/* Style buttons */
form button, 
form input[type="submit"], 
form input[type="reset"] {
    align-self: flex-end;
    padding: 8px 12px;
    margin-right: 20px;
    border: none;
    background: var(--def-main-clr);
    color: white;
    cursor: pointer;
    transition: background 0.3s ease;
}

form button:hover, 
form input[type="submit"]:hover, 
form input[type="reset"]:hover {
    background: darken(var(--def-main-clr), 10%);
}

/* #endregion */

/* #region Button states */

    button {
        position: relative;
        color: var(--def-txtinvert-clr);
        border: none;
        border-radius: 1rem;
        padding: 5px 10px;
        margin: 5px;
        cursor: pointer;
        background-color: var(--def-main-clr);
        box-shadow: -1px 3px 0px var(--def-clr-shadec), -1px 4px 0px var(--def-clr-shaded);
        transition: transform 0.2s ease, box-shadow 0.2s ease;
    }

    button:not(:disabled):hover {
        transform: translate(-1px, 2px);
        box-shadow: 0px 0px 0px var(--def-clr-shadec), 0px 1px 0px var(--def-clr-shaded);
    }

    button:focus {
        outline: none;
        transform: translateY(0px);
    }

    button:disabled {   
        filter: brightness(0.5) saturate(0.5);
        color: var(--def-clr-shaded);
        transform: translateY(1px);
        cursor: not-allowed;
        box-shadow: none;
    }

    button:active {
        outline: none;
        background-color: var(--def-clr-shadeb);
        scale: 0.995;
        transform-origin: bottom;
        box-shadow: inset 0px 0px 20px #000000c2;
    }

    

/* #endregion */