/* mer-gate.css — Email gate modal + permalink UI */

/* Welcome banner (shown once after account activation) */
.mer-welcome-banner {
  background: #d1e7dd;
  color: #0a3622;
  font-size: 0.875rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid #a3cfbb;
}

.mer-welcome-banner .container {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.mer-welcome-banner__link {
  color: #0a3622;
  font-weight: 600;
  text-decoration: underline;
}

.mer-welcome-banner__link:hover {
  color: #051b11;
}

.mer-welcome-banner__close {
  margin-left: auto;
  background: none;
  border: none;
  padding: 0 0.25rem;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  color: #0a3622;
  opacity: 0.6;
}

.mer-welcome-banner__close:hover {
  opacity: 1;
}

/* Permalink notice bar */
.mer-permalink-notice {
  background: #1a5276;
  color: #fff;
  font-size: 0.85rem;
  padding: 0.5rem 0;
  text-align: center;
}

.mer-permalink-notice__link {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: underline;
}

.mer-permalink-notice__link:hover {
  color: #fff;
}

.mer-permalink-notice__btn {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font: inherit;
  font-size: inherit;
  color: rgba(255, 255, 255, 0.8);
  text-decoration: underline;
}

.mer-permalink-notice__btn:hover {
  color: #fff;
}

.mer-permalink-notice__btn:disabled {
  opacity: 0.6;
  cursor: default;
}

/* Wizard fully hidden in permalink mode */
.mer-wizard--hidden {
  display: none !important;
}

.mer-gate-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mer-gate-overlay[hidden] {
  display: none !important;
}

.mer-gate-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.mer-gate-dialog {
  position: relative;
  z-index: 1;
  background: #fff;
  border-radius: 0.75rem;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
  padding: 2rem;
  width: min(480px, calc(100vw - 2rem));
  max-height: 90dvh;
  overflow-y: auto;
}

.mer-gate-dialog__title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.75rem;
}

.mer-gate-dialog__lead {
  font-size: 0.9rem;
  color: #555;
  margin: 0 0 1.25rem;
}

.mer-gate-dialog__field {
  margin-bottom: 0.75rem;
}

.mer-gate-dialog__input {
  width: 100%;
  padding: 0.55rem 0.85rem;
  font-size: 1rem;
  border: 1px solid #ced4da;
  border-radius: 0.375rem;
  box-sizing: border-box;
}

.mer-gate-dialog__input:focus {
  outline: none;
  border-color: #0d6efd;
  box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.15);
}

.mer-gate-dialog__error {
  font-size: 0.85rem;
  color: #dc3545;
  margin-top: 0.35rem;
}

.mer-gate-dialog__error[hidden] {
  display: none;
}

.mer-gate-dialog__cancel {
  display: block;
  margin: 0.85rem auto 0;
  background: none;
  border: none;
  padding: 0;
  color: #888;
  font-size: 0.85rem;
  cursor: pointer;
  text-decoration: underline;
}

.mer-gate-dialog__cancel:hover {
  color: #444;
}

@media (prefers-color-scheme: dark) {
  .mer-gate-dialog {
    background: #1e1e2e;
    color: #eee;
  }

  .mer-gate-dialog__lead {
    color: #aaa;
  }

  .mer-gate-dialog__input {
    background: #2a2a3e;
    border-color: #444;
    color: #eee;
  }

  .mer-gate-dialog__input:focus {
    border-color: #4a8fd4;
    box-shadow: 0 0 0 3px rgba(74, 143, 212, 0.2);
  }

  .mer-gate-dialog__cancel:hover {
    color: #ccc;
  }
}
