/* Donate page — mirrors jamesdann.ca/friends.html brand pattern. */

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

:root {
  --blue: #16478e;
  --yellow: #fdd106;
  --text: #1e1e1e;
  --white: #ffffff;
  --body-size: 18px;
}

body {
  font-family: "Hanken Grotesk", sans-serif;
  font-size: var(--body-size);
  color: var(--text);
  line-height: 1.6;
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 600px;
  margin: 0 auto;
  padding: 0 0 60px;
}

.header {
  background: var(--blue);
  padding: 28px 24px;
  text-align: center;
}
.header p {
  font-size: 0.8rem;
  color: #b8cef5;
  margin: 0;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}
.header h1 {
  font-family: "PT Sans Caption", sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--white);
  margin: 0;
}
.header h2 {
  font-family: "Hanken Grotesk", sans-serif;
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--white);
  margin: 8px 0 0;
  letter-spacing: 0.3px;
}

.body { padding: 28px 24px; }

.section-title {
  font-family: "Hanken Grotesk", sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--blue);
  margin: 0 0 12px;
}

.field-label {
  display: block;
  font-weight: 600;
  margin-bottom: 4px;
  font-size: 0.85rem;
  color: #333;
}
.field-label .hint { color: #999; font-weight: 400; }

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
select {
  display: block;
  width: 100%;
  padding: 10px 12px;
  font-family: "Hanken Grotesk", sans-serif;
  font-size: var(--body-size);
  font-weight: 300;
  border: 2px solid #d0d0d0;
  border-radius: 4px;
  background: var(--white);
  color: var(--text);
  outline: none;
  transition: border-color 150ms ease;
  margin-bottom: 12px;
}
input:focus, select:focus { border-color: var(--blue); }

.name-row { display: flex; gap: 12px; }
.name-row > div { flex: 1; min-width: 0; }

.divider {
  border: none;
  border-top: 1px solid #e5e5e5;
  margin: 24px 0;
}

/* Tax credit callout — copied verbatim from friends.html */
.tax-callout {
  font-size: 0.85rem;
  color: var(--blue);
  background: #eef3fb;
  padding: 10px 14px;
  border-radius: 4px;
  margin-bottom: 18px;
  line-height: 1.5;
}

/* Donation tiers */
.tier-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.tier {
  border: 2px solid #d0d0d0;
  border-radius: 6px;
  padding: 14px;
  text-align: center;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: border-color 150ms ease, background 150ms ease;
  user-select: none;
}
.tier:active { background: #f0f5ff; }
.tier.selected {
  border-color: var(--blue);
  background: #f0f5ff;
}
.tier .amount {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
}
.tier .credit {
  font-size: 0.7rem;
  color: var(--blue);
  font-weight: 600;
  margin-top: 2px;
}

.other-amount {
  display: none;
  margin-top: 10px;
}
.other-amount.visible { display: block; }

/* Attestation */
.attest-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  font-size: 0.9rem;
  line-height: 1.5;
}
.attest-check input[type="checkbox"] {
  width: 22px;
  height: 22px;
  accent-color: var(--blue);
  margin-top: 2px;
  flex-shrink: 0;
}

/* Payment */
.payment-note {
  font-size: 0.85rem;
  color: #666;
  margin-bottom: 14px;
}
.wallet-btn { margin-bottom: 10px; }
.wallet-btn:empty { display: none; }
#card-container {
  padding: 8px;
  min-height: 90px;
  border: 2px solid #d0d0d0;
  border-radius: 4px;
  background: var(--white);
}

/* Submit button */
.submit-btn {
  display: block;
  width: 100%;
  padding: 14px 16px;
  margin-top: 18px;
  background: var(--blue);
  color: var(--white);
  font-family: "Hanken Grotesk", sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background 150ms ease;
  -webkit-appearance: none;
}
.submit-btn:hover:not(:disabled) { background: #0f3470; }
.submit-btn:disabled { background: #999; cursor: not-allowed; }

.secure-line {
  font-size: 0.75rem;
  color: #888;
  text-align: center;
  margin-top: 10px;
  line-height: 1.5;
}

/* Error */
.form-error {
  display: none;
  background: #fde8e6;
  color: #c0392b;
  padding: 10px 14px;
  border-radius: 4px;
  margin-top: 14px;
  font-size: 0.9rem;
}
.form-error.visible { display: block; }

/* Success */
.success-card {
  background: #eef9ee;
  border: 2px solid #27ae60;
  border-radius: 6px;
  padding: 24px;
  text-align: center;
}
.success-card h2 { color: var(--blue); font-family: "PT Sans Caption", sans-serif; margin-bottom: 8px; }
.success-amount { font-size: 1.4rem; font-weight: 700; color: var(--text); margin: 8px 0 12px; }
.success-rebate { font-size: 0.85rem; color: #555; margin-top: 14px; }
.success-rebate a { color: var(--blue); }

/* Mobile */
@media (max-width: 480px) {
  .name-row { flex-direction: column; gap: 0; }
  .tier .amount { font-size: 1.2rem; }
  .header h1 { font-size: 1.5rem; }
  .header h2 { font-size: 1.1rem; }
}
