/* ============================================
   MAILING LIST — /mailing-list signup page
   Scoped to body.mailing-list-page and body.path-mailing-list
   (Drupal adds path-mailing-list even if preprocess misses).
   ============================================ */

body.mailing-list-page .content-wrapper.mailing-list-page__layout,
body.path-mailing-list .content-wrapper.mailing-list-page__layout {
  max-width: min(32rem, var(--site-content-width));
  margin: 0 auto;
  padding-top: 0.25rem;
}

/* No duplicate CTA when you're already on the signup page */
body.mailing-list-page .mailing-list-banner,
body.path-mailing-list .mailing-list-banner {
  display: none;
}

/* Drop the empty basic page shell — form lives in a Webform block */
body.mailing-list-page article.node--type-page,
body.path-mailing-list article.node--type-page {
  display: none !important;
}

/* Hide duplicate titles from blocks */
body.mailing-list-page .block-page-title-block,
body.path-mailing-list .block-page-title-block,
body.mailing-list-page .block-webform .block__title,
body.path-mailing-list .block-webform .block__title,
body.mailing-list-page .block-webform h2,
body.path-mailing-list .block-webform h2 {
  display: none !important;
}

/* Admin tabs add noise on a one-field form — toolbar still has Edit */
body.mailing-list-page .block-local-tasks-block,
body.path-mailing-list .block-local-tasks-block,
body.mailing-list-page ul.tabs,
body.path-mailing-list ul.tabs {
  display: none !important;
}

.mailing-list-page__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 1.85rem);
  font-weight: 600;
  color: var(--white);
  letter-spacing: -0.3px;
  margin: 0 0 0.75rem;
  text-align: center;
}

.mailing-list-page__intro {
  text-align: center;
  margin-bottom: 2rem;
}

.mailing-list-page__eyebrow {
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--green-light);
  margin: 0 0 0.75rem;
}

.mailing-list-page__lede {
  font-family: var(--font-display);
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--muted-light);
  margin: 0;
}

/* Webform — block embed or inside page body */
body.mailing-list-page .mailing-list-page__form .webform-submission-form,
body.path-mailing-list .mailing-list-page__form .webform-submission-form,
body.mailing-list-page .mailing-list-page__form .mailing-list-form,
body.path-mailing-list .mailing-list-page__form .mailing-list-form,
body.mailing-list-page .mailing-list-page__form form,
body.path-mailing-list .mailing-list-page__form form,
body.mailing-list-page .block-webform .webform-submission-form,
body.path-mailing-list .block-webform .webform-submission-form,
body.mailing-list-page .block-webform .mailing-list-form,
body.path-mailing-list .block-webform .mailing-list-form,
body.mailing-list-page .block-webform form,
body.path-mailing-list .block-webform form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

body.mailing-list-page .block-webform,
body.path-mailing-list .block-webform {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: clamp(1.25rem, 3vw, 1.75rem);
}

body.mailing-list-page .mailing-list-page__form .form-item,
body.path-mailing-list .mailing-list-page__form .form-item,
body.mailing-list-page .mailing-list-page__form .webform-flexbox,
body.path-mailing-list .mailing-list-page__form .webform-flexbox,
body.mailing-list-page .block-webform .form-item,
body.path-mailing-list .block-webform .form-item,
body.mailing-list-page .block-webform .webform-flexbox,
body.path-mailing-list .block-webform .webform-flexbox {
  margin: 0;
}

body.mailing-list-page .mailing-list-page__form label,
body.path-mailing-list .mailing-list-page__form label,
body.mailing-list-page .mailing-list-page__form .form-item label,
body.path-mailing-list .mailing-list-page__form .form-item label,
body.mailing-list-page .mailing-list-page__form .webform-element-label,
body.path-mailing-list .mailing-list-page__form .webform-element-label,
body.mailing-list-page .block-webform label,
body.path-mailing-list .block-webform label,
body.mailing-list-page .block-webform .form-item label,
body.path-mailing-list .block-webform .form-item label,
body.mailing-list-page .block-webform .webform-element-label,
body.path-mailing-list .block-webform .webform-element-label {
  display: block;
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted-light);
  margin-bottom: 0.4rem;
  font-weight: 400;
}

body.mailing-list-page .mailing-list-page__form input[type="email"],
body.path-mailing-list .mailing-list-page__form input[type="email"],
body.mailing-list-page .mailing-list-page__form input[type="text"],
body.path-mailing-list .mailing-list-page__form input[type="text"],
body.mailing-list-page .mailing-list-page__form input[type="tel"],
body.path-mailing-list .mailing-list-page__form input[type="tel"],
body.mailing-list-page .mailing-list-page__form textarea,
body.path-mailing-list .mailing-list-page__form textarea,
body.mailing-list-page .mailing-list-page__form select,
body.path-mailing-list .mailing-list-page__form select,
body.mailing-list-page .block-webform input[type="email"],
body.path-mailing-list .block-webform input[type="email"],
body.mailing-list-page .block-webform input[type="text"],
body.path-mailing-list .block-webform input[type="text"],
body.mailing-list-page .block-webform input[type="tel"],
body.path-mailing-list .block-webform input[type="tel"],
body.mailing-list-page .block-webform textarea,
body.path-mailing-list .block-webform textarea,
body.mailing-list-page .block-webform select,
body.path-mailing-list .block-webform select {
  width: 100%;
  box-sizing: border-box;
  padding: 0.75rem 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--white);
  background: var(--deep);
  border: 1px solid var(--border);
  border-radius: 4px;
  transition: border-color var(--transition);
}

body.mailing-list-page .mailing-list-page__form input:focus,
body.path-mailing-list .mailing-list-page__form input:focus,
body.mailing-list-page .mailing-list-page__form textarea:focus,
body.path-mailing-list .mailing-list-page__form textarea:focus,
body.mailing-list-page .mailing-list-page__form select:focus,
body.path-mailing-list .mailing-list-page__form select:focus,
body.mailing-list-page .block-webform input:focus,
body.path-mailing-list .block-webform input:focus,
body.mailing-list-page .block-webform textarea:focus,
body.path-mailing-list .block-webform textarea:focus,
body.mailing-list-page .block-webform select:focus,
body.path-mailing-list .block-webform select:focus {
  outline: none;
  border-color: var(--green);
}

body.mailing-list-page .mailing-list-page__form .form-actions,
body.path-mailing-list .mailing-list-page__form .form-actions,
body.mailing-list-page .mailing-list-page__form .webform-actions,
body.path-mailing-list .mailing-list-page__form .webform-actions,
body.mailing-list-page .block-webform .form-actions,
body.path-mailing-list .block-webform .form-actions,
body.mailing-list-page .block-webform .webform-actions,
body.path-mailing-list .block-webform .webform-actions {
  margin: 0.5rem 0 0;
}

body.mailing-list-page .mailing-list-page__form .button,
body.path-mailing-list .mailing-list-page__form .button,
body.mailing-list-page .mailing-list-page__form input[type="submit"],
body.path-mailing-list .mailing-list-page__form input[type="submit"],
body.mailing-list-page .mailing-list-page__form button[type="submit"],
body.path-mailing-list .mailing-list-page__form button[type="submit"],
body.mailing-list-page .block-webform .button,
body.path-mailing-list .block-webform .button,
body.mailing-list-page .block-webform input[type="submit"],
body.path-mailing-list .block-webform input[type="submit"],
body.mailing-list-page .block-webform button[type="submit"],
body.path-mailing-list .block-webform button[type="submit"] {
  width: 100%;
  padding: 0.85rem 1.5rem;
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 400;
  color: var(--white);
  background: var(--green);
  border: 1px solid var(--green);
  border-radius: 4px;
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition);
}

body.mailing-list-page .mailing-list-page__form .button:hover,
body.path-mailing-list .mailing-list-page__form .button:hover,
body.mailing-list-page .mailing-list-page__form input[type="submit"]:hover,
body.path-mailing-list .mailing-list-page__form input[type="submit"]:hover,
body.mailing-list-page .mailing-list-page__form button[type="submit"]:hover,
body.path-mailing-list .mailing-list-page__form button[type="submit"]:hover,
body.mailing-list-page .block-webform .button:hover,
body.path-mailing-list .block-webform .button:hover,
body.mailing-list-page .block-webform input[type="submit"]:hover,
body.path-mailing-list .block-webform input[type="submit"]:hover,
body.mailing-list-page .block-webform button[type="submit"]:hover,
body.path-mailing-list .block-webform button[type="submit"]:hover {
  background: var(--green-light);
  border-color: var(--green-light);
}

body.mailing-list-page .webform-confirmation,
body.path-mailing-list .webform-confirmation {
  font-family: var(--font-display);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--green-pale);
  text-align: center;
  padding: 1.5rem 0;
}

body.mailing-list-page .messages,
body.path-mailing-list .messages {
  margin-bottom: 1rem;
}

@media (max-width: 600px) {
  body.mailing-list-page .block-webform,
  body.path-mailing-list .block-webform {
    padding: 1rem;
  }
}

/* Fallback layout when intro lives in page template */
body.path-mailing-list .content-wrapper:not(.mailing-list-page__layout) {
  max-width: 32rem;
  margin: 0 auto;
}
