* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: #d8d8d8;
    padding: 2rem;
}

.back-button {
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(to bottom, #f4f4f4, #dfdfdf);
    color: #333;
    border-radius: 5px;
    font-size: 1rem;
    margin-bottom: 2rem;
    border: 1px solid #999;
    box-shadow: 
        0 1px 2px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    text-shadow: 0 1px 0 white;
    transition: all 0.2s ease;
}

.back-button:hover {
    background: linear-gradient(to bottom, #fff, #e9e9e9);
}

.back-button:active {
    background: linear-gradient(to top, #f4f4f4, #dfdfdf);
    box-shadow: 
        inset 0 1px 2px rgba(0, 0, 0, 0.2),
        0 1px 0 rgba(255, 255, 255, 0.8);
}

.calculator {
    background: linear-gradient(45deg, #2c2c2c, #4a4a4a);
    padding: 1.5rem;
    border-radius: 15px;
    border: 2px solid #1a1a1a;
    box-shadow: 
        0 10px 20px rgba(0, 0, 0, 0.3),
        inset 0 2px 0 rgba(255, 255, 255, 0.1);
}

.display {
    background: #9ab089;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 5px;
    text-align: right;
    min-height: 100px;
    border: 3px solid #707c63;
    box-shadow: 
        inset 0 2px 5px rgba(0, 0, 0, 0.2),
        0 1px 0 rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.display::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.2), transparent);
}

.previous-operand {
    font-family: 'Digital-7', monospace;
    font-size: 1.1rem;
    color: #4a5240;
    min-height: 1.5rem;
    opacity: 0.8;
}

.current-operand {
    font-family: 'Digital-7', monospace;
    font-size: 2.2rem;
    color: #2a2f25;
    margin-top: 0.5rem;
}

.buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

button {
    font-size: 1.25rem;
    padding: 1rem;
    border: 1px solid #1a1a1a;
    background: linear-gradient(to bottom, #5a5a5a, #3a3a3a);
    color: #fff;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    text-shadow: 0 -1px 0 #000;
    transition: all 0.1s ease;
}

button:hover {
    background: linear-gradient(to bottom, #6a6a6a, #4a4a4a);
}

button:active {
    transform: translateY(1px);
    background: linear-gradient(to top, #5a5a5a, #3a3a3a);
    box-shadow: 
        inset 0 2px 4px rgba(0, 0, 0, 0.3),
        0 1px 0 rgba(255, 255, 255, 0.1);
}

.span-two {
    grid-column: span 2;
}

[data-action="="] {
    background: linear-gradient(to bottom, #ff9500, #ff7000);
    border-color: #cc6000;
}

[data-action="="]:hover {
    background: linear-gradient(to bottom, #ffaa00, #ff8000);
}

[data-action="="]:active {
    background: linear-gradient(to top, #ff9500, #ff7000);
}

@font-face {
    font-family: 'Digital-7';
    src: url('https://fonts.cdnfonts.com/css/digital-7-mono') format('woff2');
}