/* Newsletter popup & vidéo merci — Créa Customa */

/* Curseur natif sur le popup (le site masque cursor: none avec le curseur custom) */
.nl-root,
.nl-root *,
.nl-video-modal,
.nl-video-modal * {
  cursor: auto;
}

.nl-root button,
.nl-root [role="button"],
.nl-root a,
.nl-video-modal button,
.nl-video-modal a {
  cursor: pointer;
}

.nl-root input[type="email"],
.nl-root input[type="text"],
.nl-root textarea {
  cursor: text;
}

.nl-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* —— Popup inscription —— */
.nl-root {
  position: relative;
  z-index: 1150;
}

.nl-popup {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 1150;
}

.nl-popup[hidden],
.nl-root[hidden] {
  display: none !important;
}

.nl-backdrop,
.nl-video-backdrop {
  position: absolute;
  inset: 0;
  border: none;
  background: rgba(0, 0, 0, .65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  cursor: pointer;
}

.nl-panel {
  position: relative;
  z-index: 1;
  width: min(96vw, 440px);
  background: var(--ig-surface, #fff);
  border: 1px solid var(--ig-border, #dbdbdb);
  border-radius: 16px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .04), 0 24px 48px rgba(0, 0, 0, .18);
  overflow: hidden;
}

.nl-panel-inner {
  padding: 1.25rem 1.5rem 1.5rem;
}

.nl-visual {
  line-height: 0;
  background: var(--ig-bg, #fafafa);
  border-bottom: 1px solid var(--ig-border, #dbdbdb);
}

.nl-visual img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  aspect-ratio: 2 / 1;
}

.nl-close,
.nl-video-close {
  position: absolute;
  top: .65rem;
  right: .65rem;
  z-index: 2;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--ig-text, #262626);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.nl-close {
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 1px 4px rgba(0, 0, 0, .12);
}

.nl-close:hover,
.nl-video-close:hover {
  background: var(--ig-bg, #fafafa);
}

.nl-label {
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--ig-blue, #0095f6);
  margin: 0 0 .35rem;
}

.nl-title {
  font-size: clamp(1.25rem, 4vw, 1.5rem);
  font-weight: 600;
  letter-spacing: -.02em;
  line-height: 1.25;
  margin: 0 0 .65rem;
  color: var(--ig-text, #262626);
  display: flex;
  align-items: center;
  gap: .5rem;
  padding-right: 1.75rem;
}

.nl-title::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ig-gradient, linear-gradient(45deg, #405de6, #833ab4, #e1306c, #fcaf45));
  flex-shrink: 0;
}

.nl-desc {
  font-size: .875rem;
  line-height: 1.55;
  color: var(--ig-muted, #8e8e8e);
  margin: 0 0 1.15rem;
}

.nl-form {
  display: flex;
  flex-direction: column;
  gap: .65rem;
}

.nl-field input {
  width: 100%;
  padding: .65rem .85rem;
  border: 1px solid var(--ig-border, #dbdbdb);
  border-radius: 8px;
  background: var(--ig-bg, #fafafa);
  font: inherit;
  font-size: .875rem;
  color: var(--ig-text, #262626);
  outline: none;
  transition: border-color .15s;
}

.nl-field input:focus {
  border-color: #a8a8a8;
}

.nl-honeypot {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

.nl-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: .65rem 1rem;
  border: none;
  border-radius: 999px;
  background: var(--ig-blue, #0095f6);
  color: #fff;
  font: inherit;
  font-size: .875rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform .2s ease, background .2s ease;
}

.nl-submit:hover {
  background: var(--ig-blue-hover, #1877f2);
  transform: translateY(-1px);
}

.nl-submit:disabled {
  opacity: .65;
  cursor: wait;
  transform: none;
}

.nl-note {
  margin: .85rem 0 0;
  font-size: .75rem;
  line-height: 1.45;
  color: var(--ig-muted, #8e8e8e);
  text-align: center;
}

.nl-note a {
  color: var(--ig-blue, #0095f6);
  text-decoration: none;
  font-weight: 500;
}

.nl-error {
  margin: .75rem 0 0;
  font-size: .8125rem;
  color: var(--ig-error, #ed4956);
  text-align: center;
}

/* —— Modale vidéo merci —— */
.nl-video-modal {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.nl-video-modal[hidden] {
  display: none !important;
}

.nl-video-panel {
  position: relative;
  z-index: 1;
  width: min(96vw, 720px);
  background: var(--ig-surface, #fff);
  border: 1px solid var(--ig-border, #dbdbdb);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .04), 0 24px 48px rgba(0, 0, 0, .18);
}

.nl-video-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .75rem 1rem;
  border-bottom: 1px solid var(--ig-border, #dbdbdb);
}

.nl-video-title {
  font-size: .9375rem;
  font-weight: 600;
  margin: 0;
  color: var(--ig-text, #262626);
}

.nl-video-body {
  position: relative;
  background: #000;
  line-height: 0;
}

.nl-video-unmute {
  position: absolute;
  left: 50%;
  bottom: 1rem;
  z-index: 2;
  transform: translateX(-50%);
  padding: .55rem 1.1rem;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, .94);
  color: var(--ig-text, #262626);
  font: inherit;
  font-size: .8125rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 0, 0, .35);
}

.nl-video-unmute:hover {
  background: #fff;
}

.nl-video-player {
  display: block;
  width: 100%;
  max-height: min(70vh, 480px);
  object-fit: contain;
  background: #000;
}

body.nl-popup-open,
body.nl-video-open {
  overflow: hidden;
}

@media (max-width: 768px) {
  .nl-panel,
  .nl-video-panel {
    border-radius: 12px;
  }

  .nl-panel-inner {
    padding: 1.35rem 1.15rem 1.15rem;
  }
}
