@import url('https://fonts.googleapis.com/css?family=Inter:700|Inter:400');
@import "../common.css";

* {
    box-sizing: border-box;
    font-family: 'Inter', sans-serif; font-weight: 400; color: var(--text);
}

body{
    font-family: 'Inter', sans-serif;
    width: 100vw;
    height: 100dvh;
    margin: 0;
    background-color: var(--background);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.calculator{
    @media (min-width: 1000px) {width: 19%; max-height: 50%;}
    @media (max-width: 1000px) {width: 90%; max-height: 70%;}
    padding: 10px;
    background-color: var(--secondary);
    border: solid var(--accent) 3px;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    flex: 1;
}
.display {
    font-size: 16px;
    direction: rtl;
    text-align: right;
    padding-right: 7px;
    border: solid var(--accent) 2px;
    background-color: var(--foreground);
    width: 0;
    min-width: calc(100%);
    margin-bottom: 10px;
    border-radius: 7px;
    height: 15%;
}
.keypad{
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    grid-template-rows: repeat(5, 1fr);
    flex: 1;
    gap: 4px;
}
.keypad button{
    font-size: 20px;
    border: solid black 2px;
    background-color: var(--foreground);
    @media (min-width: 1000px) {transition: filter 0.2s;}
    @media (max-width: 1000px) {transition: filter 0.5s;}
    border-radius: 7px;
    height: 100%;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}
/* Only applies on devices that support true hover (mouse/trackpad) */
@media (hover: hover) {
    button:hover{
        filter: brightness(96%)
    }
}

button:active{
    filter: brightness(85%);
    @media (max-width: 1000px) {transition-duration: 0s;}
}