* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #dddddd;
    font-size: 16px;
    font-family: 'Open Sans', sans-serif;
}

header {
    height: auto;
}

main {
    height: auto;
    padding: 10px;
}

footer {
    height: auto;
    display: flex;
    justify-content: space-around;
}

img {
    height: 30px;
    /* margin: 0 auto;
    display: block; */
}

.main-container {
    display: grid;
    grid-template-rows: auto auto;
    grid-row-gap: 20px;
}

.section {
    display: grid;
    grid-template-rows: auto auto;
    border-radius: 10px;
    box-shadow: 0px 2px 10px 0px rgba(0, 0, 0, 0.1);
}

.section-header {
    padding: 10px;
    background: rgb(29, 108, 182);
    border-top-right-radius: 10px;
    border-top-left-radius: 10px;
    display: grid;
    grid-template-rows: auto auto;
    grid-template-columns: 1fr 1fr;
}

.section-header h3 {
    color: white;
    text-align: center;
    grid-column: 1/3;
    font-family: 'Open Sans', sans-serif;
    font-size: 1.3rem;
    font-weight: 500;
}

.section-body {
    padding: 20px;
    background: #ffffff;
    border-bottom-right-radius: 10px;
    border-bottom-left-radius: 10px;
}

.section-body-dati {
    display: grid;
    grid-template-rows: auto auto auto auto auto;
    grid-template-columns: 8fr 0.5fr 0.5fr 0.5fr;
    grid-row-gap: 10px;
}

.section-body-risultati {
    display: grid;
    grid-template-rows: auto auto auto auto auto;
    grid-template-columns: 8fr 0.5fr 0.5fr 0.5fr;
    grid-row-gap: 10px;
    padding-bottom: 25px;
    border-radius: 10px;
}

.span-parameter {
    padding: 5px 10px 0 0;
    text-align: left;
    border-bottom: 1px solid #e2e2e2;
}

.no-underline {
    border-bottom: none;
}

.span-full-width {
    grid-column: 1/5;
}

.span-symbol {
    padding: 5px 10px 0 0;
    text-align: right;
}

.span-unit {
    padding: 5px 0 0 10px;
    text-align: left;
}

.input-value,
.output-value {
    margin: 0;
    width: 100px;
    text-align: center;
    background: none;
    border: none;
    outline: none;
    border-bottom: 2px solid rgb(29, 108, 182);
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
    font-weight: 400;
}

.select-wrapper {
    grid-column: 1/5;
    /* padding-top: 5px; */
}

select {
    width: 100%;
    padding: 5px;
    border: none;
    border-bottom: 2px solid rgb(29, 108, 182);
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
    font-weight: 400;
    cursor: pointer;
}

select:focus {
    outline: 2px solid rgb(29, 108, 182);
    -moz-outline-radius: 3px;
}

select::selection {
    background: black;
    color: white;
}

.radio-wrapper {
    grid-column: 1/5;
}

input[type="radio"] {
    cursor: pointer;
}

label[for="radio-darcy"],
label[for="radio-orsi"],
label[for="radio-hazen-williams"],
label[for="radio-contessini"],
label[for="radio-bazin"],
label[for="radio-kutter"],
label[for="radio-gaukler-strickler"] {
    padding-left: 5px;
    cursor: pointer;
}

.button-wrapper {
    grid-column: 1/5;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    grid-column-gap: 10px;
}

button {
    padding: 10px;
    background: rgb(29, 108, 182);
    border: none;
    border-radius: 5px;
    outline: none;
    color: white;
    font-family: 'Open Sans', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
}

button:hover {
    background: rgb(36, 140, 236);
}

/* MEDIA QUERIES */
@media screen and (min-width: 320px) {
    main {
        padding: 10px;
    }

    footer {
        padding-bottom: 10px;
    }

    .section-body {
        padding: 10px;
        font-size: 0.8rem;
    }

    .section-body-risultati {
        padding-bottom: 15px;
    }

    .section-body input {
        font-size: 0.8rem;
    }

    .section-body select {
        font-size: 0.8rem;
    }

    .section-body button {
        font-size: 0.9rem;
    }

    .section-header h3 {
        font-size: 1.1rem;
    }

    .input-value,
    .output-value {
        width: 60px;
    }
}

@media screen and (min-width: 768px) {
    main {
        padding: 20px;
    }

    footer {
        padding-bottom: 20px;
    }

    .section-body {
        padding: 20px;
        font-size: 1rem;
    }

    .section-body-risultati {
        padding-bottom: 25px;
    }

    .section-body input {
        font-size: 1rem;
    }

    .section-body select {
        font-size: 1rem;
    }

    .section-body button {
        font-size: 1.1rem;
    }

    .section-header h3 {
        font-size: 1.3rem;
    }

    .input-value,
    .output-value {
        width: 100px;
    }
}

@media screen and (min-width: 960px) {
    .section {
        width: 960px;
        justify-self: center;
    }
}