

.calculator-grid {
    display: block;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}


.input-group {
    margin-bottom: 1.5rem;
}

.input-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #333;
    font-weight: 500;
}

.input-group input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.input-group input:focus {
    border-color: #4a90e2;
    outline: none;
}

.error-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: none;
}

.calculate-btn {
    background: #4a90e2;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
    margin-top: 1rem;
}

.calculate-btn:hover {
    background: #357abd;
}

.results-section {
    display: none;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
}

.results-section.visible {
    display: block;
    animation: fadeIn 0.5s ease-in;
}

.result-card {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.result-card h3 {
    margin: 0 0 0.5rem 0;
    color: #333;
    font-size: 1.1rem;
}

.result-card .value {
    font-size: 1.5rem;
    color: #4a90e2;
    font-weight: bold;
}

.chart-container {
    margin-top: 2rem;
    height: 300px;
}

.amortization-table {
    /* display: flex; */
    /* flex-wrap: wrap; */
    width: 100%;
    margin-top: 2rem;
    border-collapse: collapse;
}

.amortization-table th,
.amortization-table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.amortization-table th {
    background: #f8f9fa;
    font-weight: 500;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 768px) {
    .amortization-table{
        display: flex;
        overflow-x: scroll;
    }
    .calculator-container {
        /* padding: 1rem; */
        /* margin: 1rem; */
    }
    
    .calculator-grid {
        grid-template-columns: 1fr;
    }
}