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

body {
    font-family: 'Space Mono', monospace;
    background: #0a0a0a;
    color: #ffffff;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.calculator-container {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    max-width: 1200px;
    width: 100%;
}

.calculator {
    background: #1a1a1a;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    border: 1px solid #333;
    min-width: 400px;
}

.display {
    background: #000;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 25px;
    min-height: 120px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid #333;
}

.input-expression {
    font-size: 16px;
    color: #888;
    min-height: 20px;
    word-break: break-all;
    line-height: 1.4;
}

.result {
    font-size: 32px;
    font-weight: 700;
    color: #00ff88;
    text-align: right;
    word-break: break-all;
    line-height: 1.2;
    text-shadow: 0 0 10px rgba(0, 255, 136, 0.3);
}

.notation-toggles {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn.toggle {
    background: #2a2a2a;
    font-size: 14px;
    padding: 10px 15px;
    min-height: auto;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.arrow-controls {
    margin-top: 20px;
    display: flex;
    gap: 10px;
    align-items: center;
    justify-content: center;
    padding: 15px;
    background: #0a0a0a;
    border-radius: 10px;
    border: 1px solid #333;
}

.btn.small {
    font-size: 14px;
    padding: 8px 12px;
    min-height: auto;
}

#arrowCount {
    font-size: 14px;
    color: #00ff88;
    font-weight: 700;
    margin-left: 10px;
}

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

.btn {
    background: #2a2a2a;
    border: none;
    border-radius: 12px;
    padding: 20px;
    font-family: 'Space Mono', monospace;
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid #444;
    min-height: 60px;
}

.btn:hover {
    background: #3a3a3a;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.btn.number {
    background: #1a4a6b;
    border-color: #2a5a7b;
}

.btn.number:hover {
    background: #2a5a8b;
}

.btn.operator {
    background: #6b1a4a;
    border-color: #7b2a5a;
}

.btn.operator:hover {
    background: #8b2a6a;
}

.btn.equals {
    background: #00ff88;
    color: #000;
    grid-row: span 2;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.btn.equals:hover {
    background: #00dd77;
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.4);
}

.btn.clear {
    background: #ff4444;
    color: #fff;
}

.btn.clear:hover {
    background: #ff6666;
}

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

.info {
    background: #1a1a1a;
    border-radius: 20px;
    padding: 30px;
    border: 1px solid #333;
    max-width: 400px;
}

.info h3 {
    color: #00ff88;
    margin-bottom: 15px;
    font-size: 20px;
}

.info p {
    color: #ccc;
    margin-bottom: 20px;
    line-height: 1.5;
}

.info ul {
    list-style: none;
    color: #aaa;
}

.info li {
    margin-bottom: 10px;
    line-height: 1.4;
}

.info strong {
    color: #00ff88;
    background: #0a2a1a;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Space Mono', monospace;
}

/* Responsive design */
@media (max-width: 768px) {
    .calculator-container {
        flex-direction: column;
        gap: 20px;
    }
    
    .calculator {
        min-width: unset;
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .info {
        max-width: unset;
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .result {
        font-size: 24px;
    }
    
    .btn {
        padding: 15px;
        font-size: 16px;
        min-height: 50px;
    }
    
    .notation-toggles {
        flex-direction: column;
        gap: 8px;
    }
    
    .arrow-controls {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
}