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

body {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.calculator {
    display: grid;
    grid-template-columns: repeat(4, 80px);
    gap: 2px;
    background-color: #1a1a2e;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.display {
    grid-column: span 4;
    background-color: #16213e;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 15px;
    text-align: right;
    min-height: 90px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    word-wrap: break-word;
    word-break: break-all;
}

.previous-operand {
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.2rem;
    min-height: 24px;
}

.current-operand {
    color: white;
    font-size: 2.2rem;
    font-weight: 300;
}

button {
    height: 70px;
    border: none;
    border-radius: 10px;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    background-color: #0f3460;
    color: white;
}

button:hover {
    background-color: #1a4a7a;
    transform: translateY(-2px);
}

button:active {
    transform: translateY(0);
}

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

button[data-action="operator"] {
    background-color: #e94560;
}

button[data-action="operator"]:hover {
    background-color: #ff6b6b;
}

.equals {
    background-color: #4ecca3;
}

.equals:hover {
    background-color: #6ee7b7;
}

button[data-action="clear"],
button[data-action="delete"] {
    background-color: #533483;
}

button[data-action="clear"]:hover,
button[data-action="delete"]:hover {
    background-color: #7952a3;
}

/* Special animation for the result */
.hiring-message {
    animation: pulse 0.5s ease-in-out;
    color: #4ecca3 !important;
    font-weight: bold;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}
