html {
    box-sizing: border-box;
    font-size: 100%;
    font-family: Arial, Helvetica, sans-serif;
}

*,
*::after,
*::before {
    box-sizing: inherit;
}

body {
    text-align: center;
    margin: 0 auto;
}

div {
    margin: 0 auto;
    width: 100%;
}

button {
    font-size: 2.5rem;
    font-weight: bold;
    background: transparent;
    border: 1px solid lightgrey;
    transition: 50ms;
}

#calculator {
    min-height: 100vh;
    min-height: 100svh;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

#calc-display {
    min-height: 25vh;
    min-height: 25svh;
    font-size: 3rem;
    font-weight: bold;
    text-align: start;
    padding: 1rem;
    background-color: #efefef;
    word-wrap: break-word;
    overflow: auto;
}

#calc-body {
    flex-grow: 1;
    display: flex;
    justify-content: center;
    align-items: stretch;
    flex-wrap: wrap;
}

#calc-body>* {
    flex-basis: 25%;
}

#calc-body>#equal {
    flex-grow: 1;
}

@media (orientation: portrait) and (min-width: 480px) {

    #calculator {
        max-width: 1920px;
    }

}