.ma-popup-root[hidden] {
  display: none;
}

.ma-popup-root {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 18px;
}

.ma-popup-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 12, 18, 0.62);
  backdrop-filter: blur(10px);
}

.ma-popup-dialog {
  position: relative;
  width: min(100%, 476px);
  max-height: min(92vh, 680px);
  overflow: auto;
  padding: 28px;
  border: 1px solid rgba(16, 33, 42, 0.1);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 26px 76px rgba(4, 12, 18, 0.28);
}

.ma-popup-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--muted);
  font: inherit;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}

.ma-popup-close:hover,
.ma-popup-close:focus-visible {
  color: var(--ink);
  outline: 2px solid rgba(17, 123, 118, 0.22);
  outline-offset: 2px;
}

.ma-popup-eyebrow {
  margin: 0 42px 10px 0;
  color: var(--brand);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ma-popup-title {
  margin: 0;
  max-width: 390px;
  font-size: clamp(1.8rem, 6vw, 2.55rem);
  line-height: 1.02;
  font-weight: 950;
}

.ma-popup-body {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 1rem;
  overflow-wrap: break-word;
}

.ma-popup-form {
  display: grid;
  gap: 13px;
  margin-top: 20px;
}

.ma-popup-field {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-weight: 850;
}

.ma-popup-input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-weight: 700;
}

.ma-popup-input:focus {
  border-color: var(--teal);
  outline: 3px solid rgba(17, 123, 118, 0.18);
}

.ma-popup-consent {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.36;
}

.ma-popup-consent input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--brand);
}

.ma-popup-consent a {
  color: var(--teal);
  font-weight: 900;
}

.ma-popup-submit,
.ma-popup-done {
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 8px;
  background: var(--brand);
  color: #ffffff;
  font: inherit;
  font-weight: 950;
  cursor: pointer;
  box-shadow: 0 14px 28px rgba(168, 50, 23, 0.22);
}

.ma-popup-submit:hover,
.ma-popup-done:hover {
  background: var(--brand-dark);
}

.ma-popup-submit:disabled {
  background: #c7cfcb;
  color: #69737a;
  cursor: wait;
  box-shadow: none;
}

.ma-popup-error {
  margin: 0;
  color: #a83217;
  font-size: 0.9rem;
  font-weight: 800;
}

.ma-popup-success {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}

.ma-popup-success h3 {
  margin: 0;
  font-size: 1.35rem;
  line-height: 1.12;
}

.ma-popup-success p {
  margin: 0;
  color: var(--muted);
}

body.ma-popup-open {
  overflow: hidden;
}

.ma-banner {
  width: 100%;
  padding: 48px 0 56px;
  background: linear-gradient(180deg, rgba(244, 247, 245, 0.92), var(--surface-soft));
}

.ma-banner-inner {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  gap: 34px;
  align-items: center;
  padding: 34px;
  border-radius: 8px;
  background: var(--navy);
  color: #fff;
  box-shadow: 0 22px 54px rgba(3, 18, 26, 0.18);
}

.ma-banner-eyebrow {
  margin: 0 0 10px;
  color: var(--brand-on-dark);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.ma-banner-title {
  margin: 0;
  font-size: clamp(1.75rem, 3.3vw, 2.8rem);
  line-height: 1.04;
  font-weight: 950;
}

.ma-banner-body {
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: 1rem;
}

.ma-banner-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: end;
}

.ma-banner-field {
  display: grid;
  gap: 7px;
  font-weight: 850;
}

.ma-banner-field-label {
  color: #fff;
}

.ma-banner-input {
  width: 100%;
  min-height: 50px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 700;
}

.ma-banner-input:focus {
  outline: 3px solid rgba(55, 210, 208, 0.34);
  outline-offset: 1px;
}

.ma-banner-submit {
  min-height: 50px;
  padding: 0 18px;
  border: 0;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font: inherit;
  font-weight: 950;
  cursor: pointer;
}

.ma-banner-submit:hover {
  background: var(--brand-dark);
}

.ma-banner-submit:disabled {
  background: #c7cfcb;
  color: #69737a;
  cursor: wait;
}

.ma-banner-consent {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 9px;
  align-items: start;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.86rem;
  line-height: 1.36;
}

.ma-banner-consent input {
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: var(--brand);
}

.ma-banner-consent a {
  color: var(--brand-on-dark);
  font-weight: 900;
}

.ma-banner-error {
  grid-column: 1 / -1;
  margin: 0;
  color: #ffb49d;
  font-size: 0.9rem;
  font-weight: 850;
}

.ma-banner-success {
  display: grid;
  gap: 8px;
}

.ma-banner-success h3,
.ma-banner-success p {
  margin: 0;
}

.ma-banner-success h3 {
  font-size: 1.45rem;
}

.ma-banner-success p {
  color: rgba(255, 255, 255, 0.76);
}

@media (max-width: 640px) {
  .ma-popup-root {
    align-items: end;
    padding: 10px;
  }

  .ma-popup-dialog {
    width: 100%;
    max-height: 86vh;
    padding: 24px 20px 20px;
  }

  .ma-banner {
    padding: 32px 0 44px;
  }

  .ma-banner-inner {
    width: min(100% - 24px, var(--max));
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 24px;
  }

  .ma-banner-form {
    grid-template-columns: 1fr;
  }

  .ma-banner-consent,
  .ma-banner-error {
    grid-column: 1;
  }
}

@media (min-width: 641px) and (max-width: 900px) {
  .ma-banner-inner {
    grid-template-columns: 1fr;
  }
}
