@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@100..900&family=Overpass:ital,wght@0,100..900;1,100..900&family=Space+Mono:ital,wght@0,400;0,700;1,400;1,700&display=swap');

:root{
    --background-color: hsl(185, 41%, 84%);
    --Green-400: hsl(172, 67%, 45%);
    --Green-900: hsl(183, 100%, 15%);
    --Grey-500: hsl(186, 14%, 43%);
    --Grey-400: hsl(184, 14%, 56%);
    --Grey-200: hsl(185, 41%, 84%);
    --Grey-50: hsl(189, 47%, 97%);
}

body{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: var(--background-color);
    margin: 0;
}

input{
    box-sizing: border-box;
    background-color: var(--Grey-200);
    font-size: 24px;
    border: none;
    border-radius: 5px;
    height: 50px;
    padding: 10px;
}

input:focus{
    border: solid 2px var(--Green-400);
    outline: none;
}

.container{
    font-family: 'Space Mono';
    color: var(--Grey-500);
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    background-color: white;
    width: 50vw;
    min-height: 400px;
    padding: 20px;
    border-radius: 20px;
    gap: 15px;
}

.settings-container{
    font-weight: 700;
}

.bill-container input{
    width: 100%;
    background: url(images/icon-dollar.svg) no-repeat 10px var(--Grey-200);
    text-align: right;
    font-family: 'Space Mono';
    font-weight: 700;
    color: var(--Green-900);
}

.number-people-container input{
    width: 100%;
    background: url(images/icon-person.svg) no-repeat 10px var(--Grey-200);
    text-align: right;
    font-family: 'Space Mono';
    font-weight: 700;
    color: var(--Green-900);
}

.buttons-container{
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    justify-content: space-between;
    gap: 10px;
}

.buttons-container button{
    background-color: var(--Green-900);
    width: 100%;
    height: 50px;
    border: none;
    color: white;
    border-radius: 5px;
    font-family: 'Space Mono';
    font-weight: 700;
    font-size: 24px;
    cursor: pointer;
}

.buttons-container button:hover{
    background-color: var(--Green-400);
    color: var(--Green-900);
    transition-duration: 0.3s;
}

.buttons-container button:focus{
    background-color: var(--Green-400);
    color: var(--Green-900);
}

.buttons-container input{
    width: 100%;
    color: var(--Green-900);
    font-family: 'Space Mono';
    font-weight: 700;
    text-align: center;
}

.custom-tip-container{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.result-container{
    background-color: var(--Green-900);
    min-width: 50%;
    color: white;
    border-radius: 20px;
    padding: 50px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 10px;
}

.tip-amount-container, .total-container{
    display: flex;
    justify-content: space-between;
}

.text-container h3, .text-container p{
    margin: 0;
}

.text-container p{
    opacity: 50%;
}

#tip-amount p, #total p{
    font-size: 40px;
    color: var(--Green-400);
    font-weight: bold;
    margin: 0;
}

.result-button{
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.reset-button{
    width: 100%;
}

.reset-button button{
    width: 100%;
    height: 50px;
    cursor: pointer;
    background-color: var(--Green-400);
    color: var(--Green-900);
    text-transform: uppercase;
    font-family: 'Space Mono';
    font-weight: 700;
    border: none;
    border-radius: 5px;
}

.attribution{
    font-size: 11px; 
    text-align: center;
}

.attribution a{
    color: hsl(228, 45%, 44%); 
}

@media screen and (max-width: 375px) {
    .container{
        width: 80vw;
        flex-direction: column;
    }

    .buttons-container{
        grid-template-columns: 1fr 1fr;
    }

    .result-container{
        padding: 30px;
    }
}