* {
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #000d46, #000000);
}

.calculator {
    width: 340px;
    padding: 20px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(16px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, .3);
}

.display input {
    width: 100%;
    height: 65px;
    border-radius: 12px;
    border: none;
    outline: none;
    padding: 15px;
    font-size: 1.8rem;
    text-align: right;
    background: rgba(255, 255, 255, .25);
    color: #fff;
}

.buttons {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

button {
    height: 55px;
    border: none;
    border-radius: 12px;
    font-size: 1.2rem;
    cursor: pointer;
    background: rgba(255, 255, 255, .25);
    color: #fff;
    transition: 0.2s;
}

button:hover {
    background: rgba(255, 255, 255, .4);
    transform: scale(1.05);
}

.operator {
    background: rgba(255, 255, 255, .4);
}

.equal {
    grid-column: span 2;
    background: #00e0ff;
    color: #000;
}

.clear {
    background: #ff4d4d;
}

.error {
    animation: shake 0.2s linear 2;
    background: rgba(255, 80, 80, 0.6) !important;
}

@keyframes shake {
    0% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px);
    }

    50% {
        transform: translateX(5px);
    }

    75% {
        transform: translateX(-5px);
    }

    100% {
        transform: translateX(0);
    }
}