?
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>SIP Calculator</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
</head>
<body>
<div class="container">
<h1>SIP Calculator</h1>
<form method="POST" action="{{ route('sip.calculate') }}">
@csrf
<label for="lump_sum">Lump Sum Amount:</label>
<input type="text" name="lump_sum" required>
<label for="monthly_investment">Per Month Investment:</label>
<input type="text" name="monthly_investment" required>
<label for="duration">Duration (Years):</label>
<input type="range" name="duration" min="1" max="30" value="15" oninput="this.nextElementSibling.value = this.value">
<output>15</output>
<label for="rate_of_return">Rate of Return (%):</label>
<input type="range" name="rate_of_return" min="8" max="30" value="12" oninput="this.nextElementSibling.value = this.value">
<output>12</output>
<button type="submit">Calculate</button>
</form>
@if(isset($forecasted_amount))
<h2>Report</h2>
<table>
<thead>
<tr>
<th>Duration (Years)</th>
<th>SIP Amount</th>
<th>Forecasted Amount (Lakhs)</th>
</tr>
</thead>
<tbody>
<tr>
<td>{{ $duration }}</td>
<td>{{ $monthly_investment }}</td>
<td>{{ $forecasted_amount }}</td>
</tr>
</tbody>
</table>
@endif
</div>
</body>
</html>