.newsletter-section {
  background: #f4f8fc;
  border-bottom: 1px solid #dce5ee;
}

.newsletter-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.newsletter-layout h2 {
  margin: 0 0 10px;
  color: #18211d;
  font-size: 28px;
  line-height: 1.4;
}

.newsletter-layout > div > p {
  max-width: 900px;
  margin: 0;
  color: #526059;
  line-height: 1.75;
}

.newsletter-form,
.newsletter-token-card {
  min-width: 0;
  padding: 22px;
  border: 1px solid #cfdce7;
  border-radius: 8px;
  background: #ffffff;
}

.newsletter-form label,
.newsletter-token-card label {
  display: grid;
  gap: 7px;
  color: #344254;
  font-size: 13px;
  font-weight: 600;
}

.newsletter-form input[type="email"],
.newsletter-token-card input[type="email"] {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid #bfcbd7;
  border-radius: 6px;
  background: #ffffff;
  color: #18211d;
  font: inherit;
  font-size: 16px;
}

.newsletter-form input:focus-visible,
.newsletter-token-card input:focus-visible,
.newsletter-form button:focus-visible,
.newsletter-token-card button:focus-visible {
  outline: 2px solid #0067ce;
  outline-offset: 3px;
}

.newsletter-topics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
  margin: 0 0 20px;
  padding: 0;
  border: 0;
}

.newsletter-topics legend {
  margin-bottom: 8px;
  color: #263248;
  font-size: 14px;
  font-weight: 650;
}

.newsletter-check {
  display: grid !important;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 9px;
  align-items: start;
  font-weight: 400 !important;
}

.newsletter-check input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: #0067ce;
}

.newsletter-check strong,
.newsletter-check small {
  display: block;
}

.newsletter-check strong {
  color: #18211d;
  font-size: 14px;
}

.newsletter-check small,
.newsletter-note,
.newsletter-message,
.newsletter-status,
.newsletter-token-meta {
  color: #657281;
  font-size: 12px;
  line-height: 1.65;
}

.newsletter-check small {
  margin-top: 2px;
}

.newsletter-consent {
  margin: 14px 0 18px;
}

.newsletter-form > label[for="newsletterEmail"] {
  max-width: 560px;
}

.newsletter-topics .newsletter-topic-option {
  padding: 16px 0;
  align-items: start;
  border-bottom: 1px solid #dce5ee;
}

.newsletter-topics .newsletter-topic-option input {
  width: 22px;
  height: 22px;
  margin-top: 4px;
}

.newsletter-topic-option strong {
  font-size: 20px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.newsletter-topic-option small {
  margin-top: 10px;
  color: #4f5c6a;
  font-size: 15px;
  line-height: 1.75;
}

.newsletter-topic-frequency {
  display: block;
  margin-top: 12px;
  color: #0055ac;
  font-size: 13px;
  line-height: 1.7;
  font-weight: 600;
}

@media (max-width: 760px) {
  .newsletter-topics {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }
  .newsletter-topic-option strong { font-size: 18px; }
}

.newsletter-submit,
.newsletter-token-card button {
  min-height: 46px;
  padding: 10px 18px;
  border: 1px solid #0067ce;
  border-radius: 6px;
  background: #0067ce;
  color: #ffffff;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

.newsletter-submit:hover,
.newsletter-token-card button:hover {
  border-color: #0055ac;
  background: #0055ac;
}

.newsletter-submit:disabled,
.newsletter-token-card button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.newsletter-note,
.newsletter-message,
.newsletter-status {
  margin: 12px 0 0;
}

.newsletter-status.is-development {
  color: #8a5a1f;
}

.newsletter-status.is-disabled,
.newsletter-message.is-error {
  color: #a33d45;
}

.newsletter-message.is-pending {
  color: #526059;
}

.newsletter-message.is-success {
  color: #176b54;
}

.newsletter-token-page {
  box-sizing: border-box;
  margin: 0;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 24px;
  background: #f4f8fc;
  color: #18211d;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

.newsletter-token-page * { box-sizing: border-box; }

.newsletter-token-card {
  width: min(560px, 100%);
}

.newsletter-token-brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #18211d;
  text-decoration: none;
  font-weight: 700;
}

.newsletter-token-brand img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.newsletter-token-card h1 {
  margin: 26px 0 10px;
  font-size: 26px;
  line-height: 1.3;
}

.newsletter-token-card > p {
  color: #526059;
  line-height: 1.75;
}

.newsletter-token-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.newsletter-token-actions .newsletter-button-quiet {
  border-color: #cbd6cf;
  background: #ffffff;
  color: #18211d;
}

@media (max-width: 760px) {
  .newsletter-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .newsletter-layout h2 {
    font-size: 22px;
  }

  .newsletter-form,
  .newsletter-token-card {
    padding: 18px;
  }

  .newsletter-submit,
  .newsletter-token-card button {
    width: 100%;
  }

  .newsletter-check {
    min-height: 44px;
    align-items: center;
  }

  .newsletter-check input {
    margin-top: 0;
  }

  .newsletter-token-actions {
    display: grid;
  }
}

@media (max-width: 700px) {
  body:has(#newsletterForm:focus-within) .xiaoyang-launcher,
  body:has(#newsletterForm:focus-within) .xiaoyang-reopen,
  body:has(#newsletterForm:focus-within) .mobile-contact-bar {
    display: none;
  }
}
