:root {
  --olive: #4a6741;
  --olive-dark: #3a5233;
  --olive-light: #e8efe6;
  --text: #1a1a1a;
  --text-muted: #666;
  --border: #ddd;
  --bg: #fafafa;
  --white: #fff;
  --red: #c0392b;
  --green: #27ae60;
  --radius: 6px;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

nav {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 0 1.5rem;
}
.nav-inner {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}
.logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--olive);
  text-decoration: none;
}
.nav-links { display: flex; align-items: center; gap: 1.25rem; }
.nav-links a { color: var(--text-muted); text-decoration: none; font-size: 0.9rem; }
.nav-links a:hover { color: var(--text); }

main {
  max-width: 900px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
  width: 100%;
  flex: 1;
}

footer {
  text-align: center;
  padding: 1.5rem;
  color: var(--text-muted);
  font-size: 0.8rem;
  border-top: 1px solid var(--border);
}

.auth-card {
  max-width: 420px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
}
.auth-card h1 {
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
}
.subtitle {
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
  margin-top: 1rem;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"] {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.9rem;
  outline: none;
}
input:focus { border-color: var(--olive); }
.hint {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.btn-primary {
  display: inline-block;
  background: var(--olive);
  color: var(--white);
  border: none;
  padding: 0.6rem 1.5rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  margin-top: 1.5rem;
}
.btn-primary:hover { background: var(--olive-dark); }
.btn-primary-sm {
  display: inline-block;
  background: var(--olive);
  color: var(--white);
  padding: 0.35rem 1rem;
  border-radius: var(--radius);
  font-size: 0.85rem;
  text-decoration: none;
}
.btn-link { color: var(--text-muted) !important; }
.switch {
  margin-top: 1.25rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}
.switch a { color: var(--olive); }

.alert {
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  margin-bottom: 1rem;
  font-size: 0.875rem;
}
.alert-error {
  background: #fdecea;
  color: var(--red);
  border: 1px solid #f5c6cb;
}

.onboard-card {
  background: var(--white);
  border: 2px solid var(--olive);
  border-radius: var(--radius);
  padding: 2rem;
  margin-bottom: 2rem;
  text-align: center;
}
.onboard-card h2 {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
  color: var(--olive-dark);
}
.onboard-card p { color: var(--text); font-size: 0.95rem; }

.dashboard .welcome { margin-bottom: 1.5rem; }
.dashboard .welcome h1 { font-size: 1.5rem; }
.dashboard .company { color: var(--text-muted); }

.cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}
@media (max-width: 600px) {
  .cards { grid-template-columns: 1fr; }
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.card h2 {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.balance {
  font-size: 2rem;
  font-weight: 700;
  color: var(--olive);
}
.balance.low { color: var(--red); }
.balance-warning {
  font-size: 0.8rem;
  color: var(--red);
  margin-top: 0.25rem;
}

.email-address {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--olive);
  font-family: monospace;
}

.section h2 {
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
}
.empty {
  color: var(--text-muted);
  font-style: italic;
}
.txn-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
.txn-table th {
  text-align: left;
  padding: 0.5rem 0.75rem;
  border-bottom: 2px solid var(--border);
  font-weight: 500;
  color: var(--text-muted);
}
.txn-table td {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid var(--border);
}
.txn-table .credit { color: var(--green); font-weight: 500; }
.txn-table .debit { color: var(--red); }

.amount-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-top: 1rem;
}
.amount-option {
  display: block;
  text-align: center;
  cursor: pointer;
}
.amount-option input { display: none; }
.amount-option span {
  display: block;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.15s;
}
.amount-option input:checked + span {
  border-color: var(--olive);
  background: var(--olive-light);
  color: var(--olive-dark);
}
.amount-option span:hover {
  border-color: var(--olive);
}
.custom-amount-row {
  margin-top: 1rem;
}
