/**
 * Hírlevél feliratkozás — oldal (/newsletter/) + site-wide modal.
 */

/* ——— Modal shell ——— */
.macske-nl-sub-overlay {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: none;
  background: rgba(0, 0, 0, 0.7);
  cursor: pointer;
}

.macske-nl-sub {
  position: fixed;
  z-index: 1101;
  display: none;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: calc(100% - 28px);
  max-width: 540px;
  max-height: calc(100vh - 28px);
  overflow-x: hidden;
  overflow-y: auto;
  padding: 28px 24px 22px;
  background-image: linear-gradient(45deg, #ceb189, #ebdac2e6);
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

.macske-nl-sub-overlay.is-open,
.macske-nl-sub.is-open {
  display: block;
}

body.macske-nl-sub-open {
  overflow: hidden;
}

.macske-nl-sub__close {
  position: absolute;
  top: 6px;
  right: 10px;
  z-index: 2;
  padding: 6px 10px;
  border: none;
  background: transparent;
  color: #a31b5a;
  font-size: 40px;
  font-weight: 400;
  line-height: 1;
  cursor: pointer;
}

.macske-nl-sub__close:hover,
.macske-nl-sub__close:focus {
  color: #7a1849;
  outline: none;
}

.macske-nl-sub__title {
  margin: 0 2.5rem 16px 0;
  font-size: 22px;
  line-height: 1.3;
  font-weight: 700;
  color: #3a3a3a;
  text-align: center;
  text-transform: uppercase;
}

.macske-nl-sub__body {
  margin: 0;
}

.macske-nl-sub__error {
  margin: 12px 0 0;
  color: #7a1849;
  font-size: 15px;
  line-height: 1.45;
}

.macske-nl-sub__ok {
  margin: 0;
  color: #3d5a3d;
  font-size: 16px;
  line-height: 1.45;
  text-align: center;
}

/* Modalon belül: ugyanaz a soft panel, mint a gate „Már feliratkoztam”. */
.macske-nl-sub .tnp.tnp-subscription {
  max-width: none;
  width: 100%;
  margin: 0 !important;
  padding: 18px 16px 14px;
  background: rgba(255, 255, 255, 0.45);
  border: 1px solid rgba(163, 27, 90, 0.12);
  border-radius: 10px;
  box-shadow: none;
  box-sizing: border-box;
}

/* ——— Form mezők: oldal + modal ——— */
body.newsletter .tnp-field,
.macske-nl-sub .tnp-field {
  margin: 0 0 16px;
  text-align: left;
}

body.newsletter .tnp-field label,
.macske-nl-sub .tnp-field label {
  display: block;
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 600;
  color: #3a3a3a;
}

body.newsletter .tnp-field input[type="text"],
body.newsletter .tnp-field input[type="email"],
body.newsletter .tnp-field select,
body.newsletter select.tnp-profile,
.macske-nl-sub .tnp-field input[type="text"],
.macske-nl-sub .tnp-field input[type="email"],
.macske-nl-sub .tnp-field select,
.macske-nl-sub select.tnp-profile {
  display: block;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin: 0;
  padding: 12px 14px;
  font-size: 16px;
  line-height: 1.4;
  color: #1a1a1a;
  background: #fff;
  border: 1px solid #cfc4cb;
  border-radius: 6px;
  text-align: left;
  justify-content: unset;
  appearance: auto;
}

body.newsletter .tnp-field input:focus,
body.newsletter .tnp-field select:focus,
.macske-nl-sub .tnp-field input:focus,
.macske-nl-sub .tnp-field select:focus {
  outline: 2px solid rgba(158, 32, 96, 0.3);
  outline-offset: 1px;
  border-color: #9e2060;
}

body.newsletter .tnp-privacy-field label,
.macske-nl-sub .tnp-privacy-field label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: 400;
  font-size: 14px;
  line-height: 1.5;
  color: #4a4a4a;
}

body.newsletter .tnp-privacy-field input[type="checkbox"],
.macske-nl-sub .tnp-privacy-field input[type="checkbox"] {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: #9e2060;
}

body.newsletter .tnp-privacy-field a,
.macske-nl-sub .tnp-privacy-field a {
  color: #9e2060;
  text-decoration: underline;
}

body.newsletter .tnp-field-button,
.macske-nl-sub .tnp-field-button {
  text-align: stretch !important;
  margin-bottom: 0;
}

body.newsletter .tnp-submit,
.macske-nl-sub .tnp-submit {
  display: block !important;
  width: 100% !important;
  margin: 4px 0 0 !important;
  padding: 14px 16px !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  border-radius: 8px !important;
  background: #9e2060 !important;
  border-color: #9e2060 !important;
  color: #fff !important;
  cursor: pointer;
}

body.newsletter .tnp-submit:hover,
body.newsletter .tnp-submit:focus,
.macske-nl-sub .tnp-submit:hover,
.macske-nl-sub .tnp-submit:focus {
  background: #7a1849 !important;
  border-color: #7a1849 !important;
}

/* ——— /newsletter/ oldal (fallback) ——— */
html:has(body.newsletter) {
  background-color: #a31b5a;
  min-height: 100%;
  height: 100%;
}

body.newsletter {
  max-width: none !important;
  width: auto !important;
  min-height: 100vh !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  background-color: #ebdac2 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  display: flex !important;
  flex-direction: column !important;
}

body.newsletter .page-container {
  background-color: #ebdac2;
  flex: 1 0 auto;
  width: 100%;
}

body.newsletter > footer {
  flex: 0 0 auto;
  width: 100%;
  margin-top: auto;
}

body.newsletter .main-article .news.article-layout {
  background: transparent;
  box-shadow: none;
  border-radius: 0;
  padding: 1.5rem 1rem 2.5rem;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

body.newsletter .article-layout__body {
  display: flex;
  justify-content: center;
}

body.newsletter .tnp.tnp-subscription {
  max-width: 520px;
  width: 100%;
  margin: 8px auto 0 !important;
  padding: 22px 20px 18px;
  background: rgba(255, 255, 255, 0.45);
  border: 1px solid rgba(163, 27, 90, 0.12);
  border-radius: 10px;
  box-shadow: none;
  box-sizing: border-box;
}

body.newsletter footer {
  background-color: #a31b5a;
}

body.newsletter footer .fdark {
  margin-bottom: 0;
  border-bottom: 0;
}

body.newsletter footer > .container-fluid {
  overflow: hidden;
  background-color: #a31b5a;
}

@media (min-width: 600px) {
  .macske-nl-sub {
    padding: 32px 28px 24px;
  }

  .macske-nl-sub__title {
    font-size: 24px;
  }

  body.newsletter .tnp.tnp-subscription {
    padding: 24px 24px 20px;
  }

  body.newsletter .main-article .news.article-layout {
    padding-top: 2rem;
    padding-bottom: 3rem;
    max-width: 560px;
  }
}
