<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Bank Account Bind</title>
  <style>
    :root {
      --bg:#0b0b0e;
      --card:#16161b;
      --soft:#1d1d24;
      --text:#e9e9ef;
      --muted:#a7a7b3;
      --gold:#d9b872;
      --gold-2:#f5d293;
      --radius:14px;
    }
    body {
      margin:0;
      font-family:"Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
      background:var(--bg);
      color:var(--text);
    }

    .page {
      max-width:480px;
      margin:0 auto;
      padding:20px;
    }

    /* Top Nav */
    .nav {
      display:flex;
      align-items:center;
      justify-content:space-between;
      margin-bottom:20px;
    }
    .nav i {
      cursor:pointer;
      font-size:20px;
      color:var(--gold);
    }
    .nav h1 {
      font-size:18px;
      font-weight:600;
      color:var(--gold-2);
      margin:0;
    }

    /* Form */
    form {
      background:var(--card);
      padding:20px;
      border-radius:var(--radius);
      box-shadow:0 6px 18px rgba(0,0,0,.3);
    }
    label {
      display:block;
      font-weight:600;
      margin-bottom:6px;
      color:var(--gold);
      font-size:14px;
    }
    input {
      width:100%;
      padding:12px;
      border-radius:8px;
      border:1px solid #333;
      background:var(--soft);
      color:var(--text);
      font-size:15px;
      margin-bottom:18px;
      transition:border .3s, box-shadow .3s;
    }
    input:focus {
      border-color:var(--gold);
      outline:none;
      box-shadow:0 0 0 2px rgba(217,184,114,.3);
    }

    /* Button */
    .btn {
      width:100%;
      padding:14px;
      border:none;
      border-radius:var(--radius);
      font-size:16px;
      font-weight:700;
      cursor:pointer;
      background:linear-gradient(90deg,var(--gold),var(--gold-2));
      color:#1c1c1c;
      transition:transform .2s;
    }
    .btn:hover {
      transform:translateY(-2px);
    }

    /* Timer */
    .timer {
      margin-top:16px;
      text-align:center;
      font-size:14px;
      color:var(--muted);
    }
  </style>
</head>
<body>
  <div class="page">
    <!-- Nav -->
    <div class="nav">
      <i onclick="window.history.back()">←</i>
      <h1>Bank Account Setting</h1>
      <div style="width:24px;"></div>
    </div>

    <!-- Form -->
    <form action="{{ route('setup.gateway.submit') }}" method="POST">
      @csrf
      <label for="name">Full Name</label>
      <input type="text" name="name" id="name" placeholder="Enter your full name" required>

      <label for="gateway_method">Bank Name</label>
      <input type="text" name="gateway_method" id="gateway_method" placeholder="Enter bank name" required>

      <label for="gateway_number">Account Number</label>
      <input type="text" name="gateway_number" id="gateway_number" placeholder="Enter account number" required>

      <button type="submit" class="btn">Confirm</button>
      <div class="timer" id="countdown">30:00 remaining</div>
    </form>
  </div>

  <!-- Countdown Script -->
  <script>
    let seconds = 30 * 60;
    const countdownEl = document.getElementById('countdown');

    function updateTimer() {
      const min = String(Math.floor(seconds / 60)).padStart(2, '0');
      const sec = String(seconds % 60).padStart(2, '0');
      countdownEl.textContent = `${min}:${sec} remaining`;
      if (seconds > 0) {
        seconds--;
        setTimeout(updateTimer, 1000);
      }
    }
    updateTimer();
  </script>

  @include('partials.notify')
</body>
</html>
