/* NP Production popup (v181). Ported from the approved Sample 1 preview:
   vertical media left, ivory panel right, quiet luxury. Scoped under
   #npPopupRoot so none of this leaks into the rest of the site. */
#npPopupRoot {
  --np-ink: #17150f;
  --np-ink-soft: #4c463c;
  --np-gold: #b08d4f;
  --np-gold-deep: #97743a;
  --np-paper: #ffffff;
  --np-hairline: rgba(176, 141, 79, 0.45);
  --np-serif: "Cormorant Garamond", "Times New Roman", serif;
  --np-sans: "Jost", "Helvetica Neue", Arial, sans-serif;
}
body.no-scroll { overflow: hidden; }

#npPopupRoot .overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: center;
  justify-content: center;
  padding: clamp(12px, 3vw, 32px);
  background: rgba(8, 7, 6, 0.72);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}
#npPopupRoot .overlay.open { display: flex; }

@keyframes np-modal-rise {
  from { transform: translateY(14px); }
  to { transform: translateY(0); }
}

#npPopupRoot .modal {
  position: relative;
  width: 100%;
  max-width: 880px;
  height: min(540px, calc(100dvh - 24px));
  max-height: calc(100dvh - 24px);
  overflow-y: auto;
  background: var(--np-paper);
  color: var(--np-ink);
  display: grid;
  grid-template-columns: 1fr 1fr;
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.5);
  text-align: left;
}
#npPopupRoot .overlay.open .modal { animation: np-modal-rise 0.35s ease; }

#npPopupRoot .modal-photo {
  position: relative;
  overflow: hidden;
  background: #241f18;
  min-height: 0;
}
#npPopupRoot .modal-photo img,
#npPopupRoot .modal-photo video {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
#npPopupRoot .photo-footer {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  padding: clamp(44px, 7vw, 64px) clamp(22px, 3.5vw, 34px) clamp(18px, 2.5vw, 24px);
  background: linear-gradient(
    to top,
    rgba(10, 8, 5, 0.72) 0%,
    rgba(10, 8, 5, 0.45) 55%,
    rgba(10, 8, 5, 0) 100%
  );
}
#npPopupRoot .photo-referral {
  display: flex;
  align-items: center;
  gap: 12px;
}
#npPopupRoot .photo-referral p {
  margin: 0;
  flex: 1;
  font-size: 12.5px;
  font-weight: 300;
  line-height: 1.55;
  letter-spacing: 0.03em;
  color: rgba(255, 255, 255, 0.92);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.4);
}
#npPopupRoot .photo-fineprint {
  margin: 10px 0 0;
  font-size: 11px;
  font-weight: 300;
  line-height: 1.6;
  letter-spacing: 0.03em;
  color: rgba(255, 255, 255, 0.68);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.4);
}

#npPopupRoot .template-tag {
  align-self: flex-start;
  margin: 0 0 16px;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--np-gold-deep);
  border: 1px solid var(--np-hairline);
  padding: 6px 10px 5px;
}
#npPopupRoot .panel-eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: var(--np-gold-deep);
}
#npPopupRoot .panel-eyebrow::after {
  content: "";
  display: block;
  width: 40px;
  height: 1px;
  background: var(--np-gold);
  margin-top: 12px;
}
#npPopupRoot .panel-headline {
  margin: 14px 0 0;
  font-family: var(--np-serif);
  font-weight: 500;
  font-size: clamp(34px, 3.8vw, 44px);
  line-height: 1.12;
  color: var(--np-ink);
}
#npPopupRoot .panel-headline em {
  font-style: italic;
  color: var(--np-gold-deep);
}
#npPopupRoot .modal-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(26px, 3.5vw, 40px) clamp(26px, 4vw, 44px);
}
#npPopupRoot .copy {
  margin: 16px 0 0;
  font-weight: 300;
  font-size: 16px;
  line-height: 1.65;
  color: var(--np-ink-soft);
}
#npPopupRoot .partner { margin-top: 22px; }
#npPopupRoot .partner p {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--np-ink-soft);
}
#npPopupRoot .partner p a {
  color: var(--np-ink);
  text-decoration: none;
  border-bottom: 1px solid var(--np-hairline);
}
#npPopupRoot .partner p a:hover { border-bottom-color: var(--np-gold); }
#npPopupRoot .logo-slot {
  border: 1.5px dashed #c9bfa9;
  background: #faf8f3;
  padding: 13px 16px;
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #9a8f74;
}
#npPopupRoot .logo-slot.logo-img {
  border: 0;
  background: transparent;
  padding: 0;
}
#npPopupRoot .logo-slot.logo-img img {
  display: block;
  margin: 0 auto;
  height: 64px;
  width: auto;
  max-width: 100%;
}
#npPopupRoot .actions {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}
#npPopupRoot .cta {
  display: block;
  text-align: center;
  background: var(--np-gold);
  color: #ffffff;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  padding: 18px 24px 17px;
  transition: background 0.25s ease;
}
#npPopupRoot .cta:hover,
#npPopupRoot .cta:focus-visible { background: var(--np-gold-deep); outline: none; }
#npPopupRoot .dismiss {
  align-self: center;
  appearance: none;
  background: none;
  border: none;
  padding: 4px 8px;
  font-family: var(--np-sans);
  font-size: 13.5px;
  font-weight: 300;
  letter-spacing: 0.08em;
  color: var(--np-ink-soft);
  cursor: pointer;
  border-bottom: 1px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}
#npPopupRoot .dismiss:hover,
#npPopupRoot .dismiss:focus-visible {
  color: var(--np-ink);
  border-bottom-color: var(--np-gold);
  outline: none;
}
#npPopupRoot .copy-btn {
  appearance: none;
  flex-shrink: 0;
  background: rgba(10, 8, 5, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.55);
  color: #ffffff;
  font-family: var(--np-sans);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 8px 13px 7px;
  cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease, color 0.25s ease;
}
#npPopupRoot .copy-btn:hover,
#npPopupRoot .copy-btn:focus-visible {
  border-color: var(--np-gold);
  background: rgba(176, 141, 79, 0.3);
  outline: none;
}
#npPopupRoot .close-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(23, 21, 15, 0.14);
  background: rgba(255, 255, 255, 0.92);
  color: var(--np-ink);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}
#npPopupRoot .close-btn:hover,
#npPopupRoot .close-btn:focus-visible {
  background: #ffffff;
  transform: rotate(90deg);
  outline: none;
}
#npPopupRoot .close-btn svg { width: 15px; height: 15px; display: block; }

@media (max-width: 720px) {
  #npPopupRoot .modal { grid-template-columns: 1fr; height: auto; }
  #npPopupRoot .modal-photo { aspect-ratio: 4 / 5; }
  #npPopupRoot .modal-body { padding-top: 26px; justify-content: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  #npPopupRoot .overlay.open .modal { animation: none; }
  #npPopupRoot .close-btn,
  #npPopupRoot .cta,
  #npPopupRoot .dismiss,
  #npPopupRoot .copy-btn { transition: none; }
}
