/* ============================================
   JUSTNEED COOKIE CONSENT BANNER
   GDPR-compliant, self-contained
   Shown once; preference stored in localStorage key: jn_cookie_consent
   Values: "all" | "necessary" | "custom"
   2026-10-11
   ============================================ */

.jn-cookie-banner {
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;
  max-width: 720px;
  margin: 0 auto;
  background: #FFFFFF;
  color: #1A1F2E;
  border: 1px solid #E8E0D0;
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(15, 19, 48, 0.18), 0 4px 12px rgba(15, 19, 48, 0.08);
  padding: 20px 22px;
  z-index: 999999;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  line-height: 1.55;
  animation: jnCookieSlide .35s cubic-bezier(.2, .9, .3, 1) both;
  display: none; /* toggled by JS */
}

.jn-cookie-banner.jn-visible { display: block; }

@keyframes jnCookieSlide {
  from { transform: translateY(28px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}

.jn-cookie-banner__title {
  font-weight: 800;
  font-size: 15px;
  letter-spacing: -0.01em;
  color: #1B1F3B;
  margin: 0 0 6px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.jn-cookie-banner__title::before {
  content: '🍪';
  font-size: 16px;
}

.jn-cookie-banner__body {
  color: #2A3148;
  margin: 0 0 14px;
}

.jn-cookie-banner__body a {
  color: #9D7340;
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 600;
}

.jn-cookie-banner__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.jn-cookie-btn {
  padding: 10px 18px;
  border-radius: 100px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all .18s ease;
  font-family: inherit;
}

.jn-cookie-btn--primary {
  background: #D4A574;
  color: #1B1F3B;
  border-color: #D4A574;
}
.jn-cookie-btn--primary:hover {
  background: #C29360;
  border-color: #C29360;
  transform: translateY(-1px);
}

.jn-cookie-btn--secondary {
  background: transparent;
  color: #1B1F3B;
  border-color: #E8E0D0;
}
.jn-cookie-btn--secondary:hover {
  background: #F8F4ED;
  border-color: #D4A574;
}

.jn-cookie-btn--ghost {
  background: transparent;
  color: #5A6376;
  border-color: transparent;
  text-decoration: underline;
  text-underline-offset: 3px;
  padding: 10px 8px;
}
.jn-cookie-btn--ghost:hover {
  color: #1B1F3B;
}

/* Expanded preferences panel */
.jn-cookie-prefs {
  display: none;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #F0E9DC;
}
.jn-cookie-prefs.jn-visible { display: block; }

.jn-cookie-category {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #F0E9DC;
}
.jn-cookie-category:last-child { border-bottom: 0; }

.jn-cookie-category__toggle {
  flex-shrink: 0;
  margin-top: 3px;
  width: 18px;
  height: 18px;
  accent-color: #D4A574;
  cursor: pointer;
}
.jn-cookie-category__toggle:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

.jn-cookie-category__text {
  flex: 1;
  font-size: 13px;
  color: #2A3148;
}
.jn-cookie-category__text strong {
  color: #1B1F3B;
  font-weight: 700;
  font-size: 13.5px;
  display: block;
  margin-bottom: 2px;
}

@media (max-width: 540px) {
  .jn-cookie-banner {
    bottom: 12px;
    left: 12px;
    right: 12px;
    padding: 16px 18px;
    font-size: 13.5px;
  }
  .jn-cookie-banner__actions { gap: 6px; }
  .jn-cookie-btn { padding: 9px 14px; font-size: 13px; flex: 1 1 auto; text-align: center; }
  .jn-cookie-btn--ghost { flex: 1 1 100%; }
}

/* ============================================
   SIGNUP CONSENT BLOCK (on /get-started)
   ============================================ */

.jn-consent-block {
  margin: 18px 0 8px;
  padding: 16px 18px;
  background: #F8F4ED;
  border: 1px solid #E8E0D0;
  border-radius: 12px;
}

.jn-consent-item {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 7px 0;
  font-size: 13px;
  line-height: 1.55;
  color: #2A3148;
}

.jn-consent-item input[type="checkbox"] {
  flex-shrink: 0;
  margin-top: 3px;
  width: 17px;
  height: 17px;
  accent-color: #D4A574;
  cursor: pointer;
}

.jn-consent-item label {
  flex: 1;
  cursor: pointer;
  margin: 0;
}

.jn-consent-item a {
  color: #9D7340;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.jn-consent-item a:hover {
  color: #C29360;
}

.jn-consent-required-marker {
  color: #B91C1C;
  font-weight: 700;
  margin-left: 2px;
}

.jn-consent-error {
  color: #B91C1C;
  font-size: 12.5px;
  font-weight: 600;
  margin: 8px 0 0;
  display: none;
}
.jn-consent-error.jn-visible { display: block; }
