/* ============================================================================
   Email capture box (.capture-box)
   ----------------------------------------------------------------------------
   Used on pages that previously had no way to collect an address at all:
   book pages, the free tools, coaching pages and the paid Q-bank pages.

   Self-contained on purpose. The book pages and some resource pages declare
   their design tokens in an inline <style> block rather than loading
   article.css, so every custom property below carries a literal fallback and
   this file can be dropped onto any page in the site without assuming which
   stylesheet came before it.
   ========================================================================== */

.capture-box {
  background: var(--navy-900, #0B1F3A);
  color: var(--white, #FFFFFF);
  border-radius: var(--radius-lg, 20px);
  padding: 2rem clamp(1.4rem, 4vw, 2.4rem);
  margin: 2.6rem auto;
  max-width: 720px;
  font-family: var(--font-body, 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif);
}

/* A lighter variant for pages whose surrounding section is already dark. */
.capture-box.capture-box-light {
  background: var(--paper, #F7F9F7);
  color: var(--navy-900, #0B1F3A);
  border: 1px solid var(--line, rgba(11, 31, 58, 0.12));
}

.capture-box h2 {
  font-family: var(--font-display, 'Fraunces', Georgia, serif);
  font-size: 1.35rem;
  line-height: 1.25;
  margin: 0;
  color: var(--white, #FFFFFF);
}
.capture-box.capture-box-light h2 { color: var(--navy-900, #0B1F3A); }

.capture-box p {
  margin: 0.6rem 0 0;
  font-size: 1rem;
  line-height: 1.55;
  color: var(--navy-100, #E7ECF3);
}
.capture-box.capture-box-light p { color: var(--ink-muted, #5B697D); }

.capture-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.2rem;
}

.capture-form input[type="email"] {
  flex: 1 1 15rem;
  min-width: 0;                 /* lets the field shrink instead of overflowing */
  padding: 0.75rem 0.9rem;
  font-size: 1rem;
  font-family: inherit;
  color: var(--navy-900, #0B1F3A);
  background: var(--white, #FFFFFF);
  border: 1px solid var(--line, rgba(11, 31, 58, 0.12));
  border-radius: var(--radius-sm, 4px);
}
.capture-form input[type="email"]::placeholder { color: var(--ink-muted, #5B697D); }
.capture-form input[type="email"]:focus-visible {
  outline: 2px solid var(--gold-500, #C9A227);
  outline-offset: 1px;
}

.capture-form button {
  flex: 0 0 auto;
  padding: 0.75rem 1.3rem;
  font-size: 0.95rem;
  font-weight: 700;
  font-family: inherit;
  color: var(--navy-900, #0B1F3A);
  background: var(--gold-500, #C9A227);
  border: 0;
  border-radius: var(--radius-sm, 4px);
  cursor: pointer;
}
.capture-form button:hover { background: var(--gold-600, #B08D2B); }
.capture-form button:disabled { opacity: 0.75; cursor: default; }
.capture-form button:focus-visible {
  outline: 2px solid var(--white, #FFFFFF);
  outline-offset: 2px;
}

.capture-note {
  margin-top: 0.75rem;
  font-size: 0.8rem;
  color: var(--navy-100, #E7ECF3);
  opacity: 0.85;
}
.capture-box.capture-box-light .capture-note { color: var(--ink-muted, #5B697D); }

/* On a phone the button sits under the field rather than being squeezed to
   a couple of characters wide beside it. */
@media (max-width: 560px) {
  .capture-form button { flex: 1 1 100%; }
}
