/**
 * newsletter-widget.css — standalone styles for the email-capture
 * block used across the landing site (factuur-tool, contract-tool,
 * /contracts/* spokes, homepage).
 *
 * Self-contained: doesn't depend on free-tool-modern.css (which is
 * scoped to .ft-body chrome). All selectors here are namespaced under
 * .mcd-newsletter-* so it can't leak into other landing components.
 *
 * The matching JS at /js/newsletter-capture.js binds to forms with
 * class .mcd-newsletter-form, posts to /api/public/newsletters/subscribe.
 */

.mcd-newsletter-section {
  padding: 3rem 0;
  background: #fafbfc;
  border-top: 1px solid #eef1f5;
  border-bottom: 1px solid #eef1f5;
}

.mcd-newsletter {
  background: #ffffff;
  border: 1px solid #e3e8ee;
  border-radius: 22px;
  padding: 1.75rem 1.5rem;
  max-width: 36rem;
  margin: 0 auto;
  text-align: center;
  box-shadow: 0 1px 2px rgba(8, 22, 40, 0.04), 0 1px 1px rgba(8, 22, 40, 0.03);
}

.mcd-newsletter h3 {
  font-size: 1.1875rem;
  margin: 0 0 0.5rem;
  letter-spacing: -0.01em;
  color: #0b1620;
}

.mcd-newsletter p.mcd-newsletter-lede {
  font-size: 0.9375rem;
  color: #5a6878;
  margin: 0 0 1.125rem;
  line-height: 1.55;
}

.mcd-newsletter form {
  display: flex;
  gap: 0.5rem;
  max-width: 26rem;
  margin: 0 auto;
  position: relative;
}

.mcd-newsletter input[type="email"] {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0.625rem 0.875rem;
  border: 1px solid #e3e8ee;
  border-radius: 10px;
  font-size: 0.9375rem;
  font-family: inherit;
  color: #0b1620;
  background: #ffffff;
}

.mcd-newsletter input[type="email"]:focus {
  outline: 2px solid #0da8ec;
  outline-offset: 1px;
  border-color: #0d7fc6;
}

/* Honeypot — visually hidden, only bots fill it. Named hp_field so
   password managers don't autofill it for real visitors. */
.mcd-newsletter input[name="hp_field"] {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.mcd-newsletter button {
  background: #015ea8;
  color: white;
  border: 0;
  padding: 0.625rem 1.125rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.9375rem;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.12s;
  font-family: inherit;
}
.mcd-newsletter button:hover:not([disabled]) {
  background: #0a488b;
}
.mcd-newsletter button[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
}

.mcd-newsletter [data-newsletter-msg] {
  margin: 0.875rem 0 0;
  font-size: 0.8125rem;
  min-height: 1.125rem;
}
.mcd-newsletter [data-newsletter-msg][data-state="ok"] {
  color: #2c6f22;
}
.mcd-newsletter [data-newsletter-msg][data-state="error"] {
  color: #d23a2a;
}
.mcd-newsletter [data-newsletter-msg][data-state="loading"] {
  color: #5a6878;
}

.mcd-newsletter-fineprint {
  margin: 0.875rem 0 0;
  font-size: 0.71875rem;
  color: #8a96a4;
  line-height: 1.5;
}
.mcd-newsletter-fineprint a {
  color: #5a6878;
  text-decoration: underline;
}

@media (max-width: 640px) {
  .mcd-newsletter form {
    flex-direction: column;
  }
  .mcd-newsletter button {
    width: 100%;
  }
}

/* Print — hide the capture (it's not relevant in a printed page) */
@media print {
  .mcd-newsletter-section {
    display: none !important;
  }
}
