Spaces:
Sleeping
Sleeping
File size: 1,312 Bytes
a0a2714 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 |
body {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
background-color: #f0f0f0;
margin: 0;
font-family: Arial, sans-serif;
}
.calculator {
background-color: #fff;
padding: 20px;
border-radius: 8px;
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
max-width: 400px;
width: 100%;
}
.display {
background-color: #333;
color: #fff;
font-size: 2em;
text-align: right;
padding: 10px;
border-radius: 5px;
margin-bottom: 10px;
word-wrap: break-word;
}
.buttons {
display: grid;
grid-template-columns: repeat(4, 1fr);
gap: 10px;
}
.btn {
background-color: #f0f0f0;
border: none;
padding: 20px;
font-size: 1.5em;
border-radius: 5px;
cursor: pointer;
transition: background-color 0.3s ease;
}
.btn:active {
background-color: #ddd;
}
.operator {
background-color: #ff9500;
color: #fff;
}
.operator:active {
background-color: #cc7a00;
}
.equals {
grid-column: span 2;
background-color: #007aff;
color: #fff;
}
.equals:active {
background-color: #005bb5;
}
.zero {
grid-column: span 2;
}
@media (max-width: 400px) {
.btn {
padding: 15px;
font-size: 1.2em;
}
.display {
font-size: 1.5em;
}
}
|