body {
    background-color: #f8f9fa;
    padding: 2rem 0;
}

.calculator-tool {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    padding: 2rem;
    margin-bottom: 2rem;
}

.calculator-tool h2 {
    margin-bottom: 0.5rem;
    color: #333;
}

.calculator-container {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
}

/* 计算器主体部分 */
.calculator-main {
    flex: 1;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.calculator-display {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.calculation-history {
    min-height: 60px;
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    font-family: monospace;
}

.current-calculation input {
    border: none;
    font-size: 1.5rem;
    font-weight: 500;
    width: 100%;
    text-align: right;
    font-family: monospace;
    padding: 0.5rem;
}

.current-calculation input:focus {
    outline: none;
    box-shadow: none;
}

/* 键盘部分 */
.calculator-keypad {
    display: grid;
    grid-template-rows: repeat(4, 1fr);
    gap: 0.75rem;
}

.keypad-row {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.75rem;
}

.keypad-btn {
    background: white;
    border: none;
    border-radius: 8px;
    padding: 1rem 0;
    font-size: 1.25rem;
    font-weight: 500;
    color: #333;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.keypad-btn:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.keypad-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.keypad-btn.operator {
    background: #e6f7ff;
    color: #0066cc;
}

.keypad-btn.function {
    background: #f0f0f0;
    color: #666;
}

.keypad-btn.equals {
    background: #0066cc;
    color: white;
}

/* 记录部分 */
.calculator-records {
    width: 300px;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.records-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.records-header h3 {
    font-size: 1.1rem;
    color: #333;
    margin: 0;
}

.records-actions {
    display: flex;
    gap: 0.5rem;
}

.records-list {
    max-height: 400px;
    overflow-y: auto;
}

.record-item {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
    position: relative;
}

.record-item:hover {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.record-expression {
    font-family: monospace;
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0.25rem;
}

.record-result {
    font-size: 1.1rem;
    font-weight: 500;
    color: #333;
    margin-bottom: 0.5rem;
}

.record-note {
    display: flex;
    gap: 0.5rem;
}

.record-note input {
    flex: 1;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    padding: 0.25rem 0.5rem;
    font-size: 0.9rem;
}

.record-note button {
    background: #0066cc;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 0.25rem 0.5rem;
    font-size: 0.9rem;
    cursor: pointer;
}

.record-note-text {
    font-size: 0.9rem;
    color: #666;
    font-style: italic;
    margin-top: 0.5rem;
}

.record-actions {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
}

.delete-record-btn {
    background: none;
    border: none;
    color: #dc3545;
    font-size: 0.85rem;
    padding: 0.25rem;
    cursor: pointer;
    opacity: 0.6;
    transition: all 0.2s ease;
}

.delete-record-btn:hover {
    opacity: 1;
    transform: scale(1.1);
}

.empty-records {
    text-align: center;
    padding: 2rem 0;
    color: #999;
}

.empty-records i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

/* 统计模态框 */
.stats-summary {
    display: flex;
    justify-content: space-between;
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    margin-top: 1rem;
}

.summary-item {
    text-align: center;
}

.summary-label {
    font-size: 0.9rem;
    color: #666;
    display: block;
    margin-bottom: 0.25rem;
}

.summary-value {
    font-size: 1.1rem;
    font-weight: 500;
    color: #333;
}

/* 响应式调整 */
@media (max-width: 992px) {
    .calculator-container {
        flex-direction: column;
    }
    
    .calculator-records {
        width: 100%;
    }
} 