*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: system-ui, -apple-system, sans-serif;
}

body {
    background: linear-gradient(to right, #00416A, #E4E5E6);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.calculator {
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    padding: 20px;
    width: 100%;
    max-width: 400px;
}

.display {
    background-color: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    text-align: right;
    min-height: 100px;
}

.previous-operand {
    color: #6c757d;
    font-size: 1.2rem;
    min-height: 24px;
}

.current-operand {
    color: #212529;
    font-size: 2.5rem;
    font-weight: 500;
    word-wrap: break-word;
    word-break: break-all;
}

.keypad {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

button {
    border: none;
    border-radius: 10px;
    padding: 20px;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.2s;
    background-color: #f8f9fa;
}

button:hover {
    background-color: #e9ecef;
}

button:active {
    transform: scale(0.95);
}

.span-2 {
    grid-column: span 2;
}

.operator {
    background-color: #e3f2fd;
    color: #1976d2;
}

.operator:hover {
    background-color: #bbdefb;
}

.equals {
    background-color: #1976d2;
    color: white;
}

.equals:hover {
    background-color: #1565c0;
}

.clear {
    background-color: #ffebee;
    color: #d32f2f;
}

.clear:hover {
    background-color: #ffcdd2;
}

.delete {
    background-color: #ffebee;
    color: #d32f2f;
}

.delete:hover {
    background-color: #ffcdd2;
}

.number 
{
    background-color: #f5f5f5;
    box-shadow: 3px 2px 2px #ddd;
}