/*General styles*/

body {
    font-size: 16px;
}

::selection {
    background: orange;
    color: white;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/*Title*/

.title {
    font-family: monospace;
    font-style: italic;
    color: gray;
}

/*Wrapper*/

.content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100vh;
    padding: 10px;
}

/*Main styles*/

.calculator {
    max-width: 300px;
    width: 100%;
    padding: 20px;
    border-radius: 20px;
    background-color: black;
    box-shadow: 5px 5px 10px gray;
}

/*Panels*/

.output,
.input {
    padding: 10px;
    border: 1px solid gray;
    border-radius: 20px;
    color: white;
}

.output {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 260px;
    height: 75px;
    padding: 10px;
    overflow: hidden;
}

.input {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    justify-items: center;
    row-gap: 10px;
    margin-top: 20px;
    font-size: 20px;
    font-weight: bold;
}

#expression,
#result {
    display: block;
    text-align: right;
}

#result {
    font-size: 24px;
}

/*Buttons*/

.number-btn,
.action-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    transition: 0.1s all linear;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

.number-btn:hover,
.action-btn:hover {
    opacity: 0.9;
}

.number-btn {
    background-color: gray;
}

.number-btn:nth-child(15) {
    grid-column: 1/3;
    width: 100%;
    border-radius: 20px;
}

.number-btn:active {
    background-color: #666564;
}

.action-btn {
    background-color: orange;
}

.action-btn:first-child {
    width: 100%;
    grid-column: 1/4;
    border-radius: 20px;
    background-color: lightgray;
    color: black;
}

.action-btn:first-child:active {
    background-color: #666564;
}

.action-btn:active {
    background-color: #cf6a06;
}
