/* =====================================================================
   EASYKREST — NEWSLETTER SUBSCRIBE PROMPT
   newsletter.css
   ===================================================================== */

.nl-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(6, 8, 13, 0.55);
  backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 320ms ease, visibility 320ms ease;
}

.nl-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.nl-modal {
  position: relative;
  width: min(880px, 100%);
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  background: var(--color-white, #fff);
  border-radius: var(--radius-md, 20px);
  box-shadow: 0 30px 80px rgba(6, 8, 13, 0.35);
  display: grid;
  grid-template-columns: 0.85fr 1fr;
  transform: translateY(18px) scale(0.98);
  opacity: 0;
  transition: transform 320ms ease, opacity 320ms ease;
}

.nl-overlay.is-open .nl-modal {
  transform: translateY(0) scale(1);
  opacity: 1;
}

/* ── Left visual panel ────────────────────────────────────────────── */
.nl-modal__aside {
  background:
    linear-gradient(160deg, rgba(11, 37, 111, 0.92), rgba(21, 69, 216, 0.88)),
    url("assets/images/about-refinery.jpg") center / cover no-repeat;
  color: #fff;
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 14px;
  border-radius: var(--radius-md, 20px) 0 0 var(--radius-md, 20px);
}

.nl-modal__eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
  margin: 0;
}

.nl-modal__aside h3 {
  font-family: "Oswald", "Manrope", sans-serif;
  font-size: 1.6rem;
  line-height: 1.2;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.01em;
}

.nl-modal__aside p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
}

/* ── Right form panel ─────────────────────────────────────────────── */
.nl-modal__body {
  padding: 44px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.nl-modal__body h2 {
  font-family: "Oswald", "Manrope", sans-serif;
  font-size: 1.75rem;
  line-height: 1.15;
  margin: 0 0 10px;
  color: var(--color-text, #111);
  text-transform: uppercase;
}

.nl-modal__lead {
  margin: 0 0 24px;
  color: var(--color-muted, #576072);
  font-size: 0.95rem;
  line-height: 1.65;
}

.nl-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.nl-form input[type="text"],
.nl-form input[type="email"] {
  width: 100%;
  padding: 14px 18px;
  border: 1.5px solid var(--color-border, rgba(17, 17, 17, 0.12));
  border-radius: 100px;
  font-size: 0.95rem;
  color: var(--color-text, #111);
  background: #fff;
  transition: border-color 200ms ease, box-shadow 200ms ease;
}

.nl-form input:focus {
  outline: none;
  border-color: var(--color-blue, #1545d8);
  box-shadow: 0 0 0 4px rgba(21, 69, 216, 0.12);
}

.nl-form button {
  padding: 14px 26px;
  border: 0;
  border-radius: 100px;
  background: var(--color-blue, #1545d8);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: background 200ms ease, transform 200ms ease;
}

.nl-form button:hover:not(:disabled) {
  background: var(--color-blue-deep, #0b256f);
  transform: translateY(-1px);
}

.nl-form button:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.nl-form__note {
  margin: 6px 0 0;
  font-size: 0.78rem;
  color: var(--color-muted, #576072);
  line-height: 1.5;
}

.nl-msg {
  margin: 12px 0 0;
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.5;
  display: none;
}

.nl-msg.is-error {
  display: block;
  color: var(--color-red, #d61f38);
}

.nl-msg.is-success {
  display: block;
  color: #15803d;
}

/* ── Success state ────────────────────────────────────────────────── */
.nl-done {
  display: none;
  text-align: center;
}

.nl-modal.is-done .nl-form,
.nl-modal.is-done .nl-modal__lead,
.nl-modal.is-done .nl-modal__body > h2 {
  display: none;
}

.nl-modal.is-done .nl-done {
  display: block;
}

.nl-done__check {
  width: 62px;
  height: 62px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: rgba(22, 163, 74, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}

.nl-done__check svg {
  width: 30px;
  height: 30px;
  stroke: #16a34a;
  fill: none;
  stroke-width: 2.5;
}

.nl-done h2 {
  font-family: "Oswald", "Manrope", sans-serif;
  font-size: 1.5rem;
  margin: 0 0 10px;
  text-transform: uppercase;
}

.nl-done p {
  margin: 0;
  color: var(--color-muted, #576072);
  font-size: 0.92rem;
  line-height: 1.65;
}

/* ── Close button ─────────────────────────────────────────────────── */
.nl-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: rgba(17, 17, 17, 0.06);
  color: var(--color-text, #111);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 200ms ease;
  z-index: 2;
}

.nl-close:hover { background: rgba(17, 17, 17, 0.12); }
.nl-close svg   { width: 16px; height: 16px; stroke: currentColor; stroke-width: 2.5; fill: none; }

/* ── Inline footer signup (blog pages) ────────────────────────────── */
.nl-inline {
  background: var(--color-surface, #f5f8ff);
  border: 1px solid var(--color-border, rgba(17, 17, 17, 0.09));
  border-radius: var(--radius-md, 20px);
  padding: 32px;
  margin: 40px 0;
}

.nl-inline h3 {
  font-family: "Oswald", "Manrope", sans-serif;
  font-size: 1.25rem;
  margin: 0 0 8px;
  text-transform: uppercase;
}

.nl-inline p { margin: 0 0 18px; color: var(--color-muted, #576072); font-size: 0.92rem; }

.nl-inline .nl-form { flex-direction: row; flex-wrap: wrap; }
.nl-inline .nl-form input[type="email"] { flex: 1 1 240px; width: auto; }

/* ── Responsive ───────────────────────────────────────────────────── */
@media (max-width: 780px) {
  .nl-modal { grid-template-columns: 1fr; }

  .nl-modal__aside {
    border-radius: var(--radius-md, 20px) var(--radius-md, 20px) 0 0;
    padding: 30px 26px 24px;
    min-height: 150px;
  }

  .nl-modal__aside h3 { font-size: 1.3rem; }
  .nl-modal__aside p  { display: none; }
  .nl-modal__body     { padding: 30px 26px 34px; }
  .nl-modal__body h2  { font-size: 1.45rem; }
}

@media (prefers-reduced-motion: reduce) {
  .nl-overlay,
  .nl-modal { transition: none; }
}
