/* =============================================
   BRANCH'S — NEWSLETTER POPUP CSS
   Styled to match the Branch's website aesthetic
   ============================================= */

/* ---- OVERLAY ---- */
.nl-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44, 26, 0, 0.72);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}
.nl-overlay.nl-visible {
  opacity: 1;
  pointer-events: all;
}

/* ---- MODAL ---- */
.nl-modal {
  position: relative;
  width: 100%;
  max-width: 480px;
  background: #FFF8EE;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(44, 26, 0, 0.45);
  transform: translateY(24px) scale(0.97);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.nl-overlay.nl-visible .nl-modal {
  transform: translateY(0) scale(1);
}

/* ---- CLOSE BUTTON ---- */
.nl-close {
  position: absolute;
  top: 12px;
  right: 14px;
  background: none;
  border: none;
  font-size: 22px;
  line-height: 1;
  color: rgba(255, 255, 255, 0.75);
  cursor: pointer;
  z-index: 10;
  padding: 4px 6px;
  transition: color 0.2s ease;
}
.nl-close:hover {
  color: #ffffff;
}

/* ---- IMAGE BAND ---- */
.nl-image-band {
  width: 100%;
  height: 160px;
  object-fit: cover;
  object-position: center 40%;
  display: block;
}

/* ---- HEADER BAND (dark brown like the nav) ---- */
.nl-header-band {
  background: #2C1A00;
  padding: 20px 32px 18px;
  text-align: center;
}
.nl-logo-text {
  font-family: 'Dancing Script', cursive;
  font-size: 2.2rem;
  color: #C8860A;
  line-height: 1;
  margin: 0 0 4px;
  display: block;
}
.nl-tagline-small {
  font-family: 'Oswald', sans-serif;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  margin: 0;
}

/* ---- BODY ---- */
.nl-body {
  padding: 26px 30px 30px;
  background: #FFF8EE;
}

/* ---- EYEBROW ---- */
.nl-eyebrow {
  font-family: 'Oswald', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #C8860A;
  margin: 0 0 6px;
}

/* ---- HEADLINE ---- */
.nl-headline {
  font-family: 'Dancing Script', cursive;
  font-size: 1.9rem;
  font-weight: 700;
  color: #2C1A00;
  margin: 0 0 10px;
  line-height: 1.2;
}

/* ---- SUBTEXT ---- */
.nl-subtext {
  font-family: 'Open Sans', sans-serif;
  font-size: 0.88rem;
  color: #5C3A10;
  margin: 0 0 20px;
  line-height: 1.65;
}

/* ---- DIVIDER ---- */
.nl-divider {
  width: 44px;
  height: 2px;
  background: #C8860A;
  margin: 0 0 20px;
  border: none;
}

/* ---- FORM ---- */
.nl-form {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}
.nl-input-wrap {
  flex: 1;
  position: relative;
}
.nl-input {
  width: 100%;
  padding: 12px 14px;
  font-family: 'Open Sans', sans-serif;
  font-size: 0.88rem;
  color: #2C1A00;
  background: #ffffff;
  border: 1.5px solid #D4A85A;
  border-radius: 4px;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.nl-input::placeholder {
  color: #A08050;
}
.nl-input:focus {
  border-color: #C8860A;
  box-shadow: 0 0 0 3px rgba(200, 134, 10, 0.15);
}
.nl-input.nl-input-error {
  border-color: #c0392b;
}
.nl-error-msg {
  display: none;
  font-family: 'Open Sans', sans-serif;
  font-size: 11px;
  color: #c0392b;
  margin-top: 4px;
}
.nl-error-msg.nl-show {
  display: block;
}

/* ---- SUBMIT BUTTON ---- */
.nl-submit {
  padding: 12px 18px;
  background: #C8860A;
  color: #ffffff;
  font-family: 'Oswald', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s ease, transform 0.1s ease;
  flex-shrink: 0;
}
.nl-submit:hover {
  background: #A06A08;
}
.nl-submit:active {
  transform: scale(0.97);
}
.nl-submit:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* ---- PRIVACY NOTE ---- */
.nl-privacy {
  font-family: 'Open Sans', sans-serif;
  font-size: 11px;
  color: #8A6A40;
  margin: 12px 0 0;
  text-align: center;
}

/* ---- DISMISS LINK ---- */
.nl-dismiss {
  display: block;
  text-align: center;
  margin-top: 12px;
  font-family: 'Open Sans', sans-serif;
  font-size: 12px;
  color: #A08050;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s ease;
  background: none;
  border: none;
  padding: 0;
  width: 100%;
}
.nl-dismiss:hover {
  color: #5C3A10;
}

/* ---- SUCCESS STATE ---- */
.nl-success {
  display: none;
  text-align: center;
  padding: 16px 0 8px;
}
.nl-success-icon {
  font-size: 52px;
  margin-bottom: 12px;
  display: block;
}
.nl-success-title {
  font-family: 'Dancing Script', cursive;
  font-size: 2rem;
  color: #2C1A00;
  margin: 0 0 10px;
}
.nl-success-msg {
  font-family: 'Open Sans', sans-serif;
  font-size: 0.88rem;
  color: #5C3A10;
  margin: 0 0 22px;
  line-height: 1.6;
}
.nl-success-close {
  display: inline-block;
  padding: 11px 30px;
  background: #C8860A;
  border: none;
  color: #ffffff;
  font-family: 'Oswald', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: 4px;
  transition: background 0.2s ease;
}
.nl-success-close:hover {
  background: #A06A08;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 520px) {
  .nl-body {
    padding: 22px 20px 26px;
  }
  .nl-form {
    flex-direction: column;
  }
  .nl-submit {
    width: 100%;
    text-align: center;
  }
  .nl-image-band {
    height: 120px;
  }
  .nl-headline {
    font-size: 1.65rem;
  }
}
