/* Shared auth-modal styles, extracted from the landing stylesheet so every page
   (landing loads styles.css, chat loads app.css) can render the auth modals. */

/* ── FAQ Section ─────────────────────────────────────────────── */
.ns-auth-modal[hidden] { display: none; }

.ns-auth-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 24px;
  opacity: 0;
  transition: opacity 0.22s ease;
}

.ns-auth-modal.is-open { opacity: 1; }

.ns-auth-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 9, 13, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.ns-auth-dialog {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(340px, 1fr);
  width: min(920px, 100%);
  min-height: 520px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  background: var(--bg-tooltip);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.32);
  transform: scale(0.96) translateY(10px);
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.ns-auth-modal.is-open .ns-auth-dialog { transform: none; }

.ns-auth-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.ns-auth-close:hover {
  background: rgba(255, 255, 255, 0.11);
  color: var(--text-primary);
}

.ns-auth-visual {
  position: relative;
  overflow: hidden;
}

.ns-auth-visual img {
  width: 100%;
  height: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center top;
  filter: saturate(0.9) brightness(0.78);
  display: block;
}

.ns-auth-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgba(14, 19, 25, 0.90), rgba(14, 19, 25, 0.16) 58%, rgba(14, 19, 25, 0.08)),
    linear-gradient(135deg, rgba(237, 55, 186, 0.24), transparent 54%);
}

.ns-auth-visual-copy {
  position: absolute;
  left: 32px;
  right: 32px;
  bottom: 32px;
  z-index: 1;
}

.ns-auth-kicker {
  color: var(--primary-color-hover);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.ns-auth-promise {
  max-width: 300px;
  color: var(--text-primary);
  font-size: 28px;
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: 0;
}

.ns-auth-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 56px 34px 40px;
  background:
    linear-gradient(135deg, rgba(20, 27, 33, 0.98), rgba(13, 18, 23, 0.98));
}

.ns-auth-title {
  color: var(--text-primary);
  font-size: clamp(28px, 4vw, 38px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  margin-bottom: 10px;
}

.ns-auth-subtitle {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.55;
  margin-bottom: 28px;
}

.ns-auth-form {
  display: grid;
  gap: 10px;
}

.ns-auth-label {
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.ns-auth-input {
  width: 100%;
  height: 48px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-button);
  background: rgba(255, 255, 255, 0.045);
  color: var(--text-primary);
  padding: 0 16px;
  font: 600 16px var(--font);
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.ns-auth-input::placeholder {
  color: var(--text-disabled);
  text-transform: uppercase;
}

.ns-auth-input:focus {
  border-color: var(--primary-border);
  box-shadow: 0 0 0 3px var(--primary-subtle);
}

.ns-auth-submit,
.ns-auth-google {
  height: 50px;
  border-radius: var(--radius-button);
  font: 800 16px var(--font);
  letter-spacing: 0.02em;
  cursor: pointer;
}

.ns-auth-submit {
  margin-top: 12px;
  border: 0;
  background: var(--grad-primary);
  color: var(--text-on-primary);
  transition: box-shadow var(--transition-normal);
}

.ns-auth-submit:hover {
  box-shadow: var(--shadow-pink);
}

.ns-auth-forgot {
  text-align: right;
  margin-top: -4px;
}

.ns-auth-forgot a {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.01em;
}

.ns-auth-forgot a:hover { color: var(--primary-color-hover); }

/* "Forgot password?" / "Create a free account" / "Sign in" are <button>s —
   without this they render with UA button chrome and read as broken chips. */
.ns-auth-linklike {
  appearance: none;
  border: none;
  padding: 0;
  background: transparent;
  font: inherit;
  font-weight: 700;
  color: var(--primary-color-hover);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.ns-auth-linklike:hover { color: var(--primary-color); }
.ns-auth-linklike:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
  border-radius: 4px;
}
.ns-auth-forgot .ns-auth-linklike {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
}
.ns-auth-forgot .ns-auth-linklike:hover { color: var(--primary-color-hover); }

.ns-auth-switch {
  margin: 22px 0 18px;
  text-align: center;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 700;
}

.ns-auth-switch a { color: var(--primary-color-hover); }

.ns-auth-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--text-disabled);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.ns-auth-divider::before,
.ns-auth-divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--border-subtle);
}

.ns-auth-google {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text-primary);
}

@media (max-width: 640px) {
  .ns-container { padding-left: 16px; padding-right: 16px; }
  .ns-btn-signin {
    padding: 8px 16px;
    font-size: 13px;
  }
  .ns-hero { padding-top: 32px; padding-bottom: 0; }
  .ns-page-media {
    background-image: url(../img/background-mobile.jpg);
  }
  .ns-hero-carousel {
    height: 320px;
    margin-top: 30px;
  }
  .ns-hero-headline { font-size: 48px; }
  .ns-hero-sub { font-size: 15px; }
  .ns-hero-body { font-size: 14.5px; margin-bottom: 24px; }
  .ns-hero-body,
  .ns-create-body,
  .ns-proof-item p,
  .ns-auth-subtitle,
  .ns-live-intro-body,
  .ns-faq-subtitle,
  .ns-cta-body,
  .ns-footer-tagline,
  .ns-footer-note {
    line-height: 1.45;
  }
  .ns-hero-trust { display: none; }
  .ns-hcard { width: clamp(172px, 56vw, 215px); }
  .ns-design-flow { padding: 54px 0 34px; }
  .ns-design-panel {
    border-radius: var(--radius-xl);
  }
  .ns-create-card {
    min-height: 0;
    padding: 22px;
    width: 100%;
  }
  .ns-create-card::after {
    content: none;
  }
  .ns-hcard-views {
    padding: 4px 8px;
  }
  .ns-hcard-fav-btn {
    width: 32px; 
    height: 32px;
  }
  .ns-hcard-fav-btn svg {
    width: 16px;
    height: 16px;
  }
  .ns-hcard-bottom {
    gap: 4px 10px;
    padding: 16px;
  }
  .ns-create-copy {
    max-width: none;
  }
  .ns-create-headline {
    font-size: 30px;
  }
  .ns-create-body {
    max-width: none;
    margin-bottom: 16px;
  }
  .ns-create-step {
    grid-template-columns: 38px minmax(0, 1fr);
    padding: 12px;
  }
  .ns-create-preview {
    grid-template-columns: 1fr;
  }
  .ns-create-phone {
    min-height: 360px;
  }
  .ns-create-phone img {
    min-height: 360px;
  }
  .ns-create-controls {
    grid-template-columns: 1fr;
    padding-bottom: 0;
  }
  .ns-morph-glyphs {
    display: none;
  }
  .ns-create-morph {
    position: relative;
    right: auto;
    top: auto;
    bottom: auto;
    width: calc(100% + 44px);
    height: 220px;
    margin: 28px -22px -22px;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 18%);
    mask-image: linear-gradient(to bottom, transparent 0%, black 18%);
  }
  .ns-create-morph .ns-morph-img {
    object-position: center 15%;
  }
  .ns-proof-grid {
    grid-template-columns: 1fr;
    padding: 0 14px 14px;
  }
  .ns-proof-item {
    grid-template-columns: 42px minmax(0, 1fr);
    min-height: 120px;
    padding: 16px 14px;
    border-right: 0;
    border-top: 1px solid var(--border-subtle);
  }
  .ns-proof-item:first-child,
  .ns-proof-item:last-child {
    border-radius: 0;
  }
  .ns-proof-item:last-child {
    border-bottom-left-radius: var(--radius-lg);
    border-bottom-right-radius: var(--radius-lg);
  }
  .ns-proof-visual {
    height: 76px;
  }
  .ns-live {
    padding-bottom: 12px;
  }
  .ns-live::before {
    background-attachment: scroll;
    opacity: 0.44;
  }
  .ns-live::after {
    opacity: 0.34;
  }
  .ns-live-intro {
    padding: 32px 0 28px;
  }
  .ns-live-intro-heading,
  .ns-cta-heading {
    font-size: 34px;
  }
  .ns-live-preview {
    height: 390px;
  }
  .ns-chat-messages {
    min-height: 420px;
  }
  .ns-bubble {
    max-width: min(300px, calc(100vw - 72px));
  }
  .ns-bubble.ns-bubble--photo {
    max-width: 160px;
  }
  .ns-bubble--user {
    align-self: flex-start;
    margin-left: 32px;
  }
  .ns-auth-modal {
    padding: 14px;
  }
  .ns-auth-dialog {
    grid-template-columns: 1fr;
    width: min(420px, 100%);
    max-height: calc(100vh - 28px);
    overflow-y: auto;
  }
  .ns-auth-visual img {
    aspect-ratio: 6 / 2;
  }
  .ns-auth-visual-copy {
    display: none;
  }
  .ns-auth-panel {
    padding: 28px 22px 24px;
  }
  .ns-auth-title {
    font-size: 28px;
  }
  .ns-faq { padding: 0 0 58px; }
  .ns-faq-header {
    margin-bottom: 28px;
  }
  .ns-faq-layout {
    grid-template-columns: 1fr;
    gap: 54px;
  }
  .ns-faq-trigger {
    font-size: 15px;
    padding: 20px 0;
  }
  .ns-faq-card {
    position: relative;
    top: auto;
  }

  .ns-cta {
    padding: 66px 0;
  }
  .ns-cta-btn {
    width: 100%;
    justify-content: center;
    padding: 15px 24px;
  }
  .ns-footer-top,
  .ns-footer-cols {
    padding-left: 0;
    padding-right: 0;
  }
  .ns-nav-links { display: none !important; }
}
