/* Shared frontend dark mode. Quiz-specific styles belong in node-315.css. */

body.darktheme {
  background: #101010 !important;
  color: #f5f5f5;
}

body.darktheme #content,
body.darktheme #block-insights-theme-content,
body.darktheme .newsletter-section,
body.darktheme .author-page-profile,
body.darktheme .author-profile-container,
body.darktheme .author-profile-posts {
  background: #101010 !important;
  color: #f5f5f5;
}

body.darktheme .author-profile-header .auth-name,
body.darktheme .author-profile-header .auth-details,
body.darktheme .author-profile-header .auth-descr,
body.darktheme .author-profile-header .auth-descr p,
body.darktheme .author-profile-posts > h2,
body.darktheme .author-profile-no-posts,
body.darktheme .author-no-results,
body.darktheme .author-card .author-card-title {
  color: #f5f5f5 !important;
}

body.darktheme .author-card,
body.darktheme .author-profile-no-posts,
body.darktheme .author-no-results {
  background: #1b1b1b;
  border-color: #3d4655;
}

body.darktheme .author-card .author-card-cat,
body.darktheme .author-card .author-card-cat:hover,
body.darktheme .author-card .author-card-title:hover,
body.darktheme .author-profile-header .profile-link {
  color: #8db8ff !important;
}

/* Author page: filter tabs and See More button visibility in dark mode. */
body.darktheme .author-filter-tabs {
  border-bottom: 1px solid #3d4655;
}

body.darktheme .filter-tab {
  color: #c7cbd2 !important;
}

body.darktheme .filter-tab.active,
body.darktheme .filter-tab:hover {
  color: #fff !important;
}

body.darktheme .filter-tab.active::after,
body.darktheme .filter-tab:hover::after {
  background: #8db8ff !important;
}

body.darktheme .author-see-more-btn {
  background: #ffd639;
  color: #111;
}

/* Remove See More hover effect on mobile only, dark mode. */
@media only screen and (max-width: 650px) {
  body.darktheme .author-see-more-btn:hover,
  body.darktheme .author-see-more-btn:focus,
  body.darktheme .author-see-more-btn:active {
    background: #ffd639 !important;
    color: #111 !important;
    transform: none !important;
    box-shadow: none !important;
  }
}

/* Magazine subscribe popup and other shared subscription forms. */
body.darktheme #subscription-popup .popup-content {
  background: #171a21 !important;
  color: #f5f5f5 !important;
  border: 1px solid #3d4655;
}

body.darktheme #subscription-popup .popup-content h1,
body.darktheme #subscription-popup .popup-content h2,
body.darktheme #subscription-popup .popup-content p,
body.darktheme #subscription-popup .popup-content .label,
body.darktheme #subscription-popup .popup-content .dwn-priv-frm {
  color: #f5f5f5 !important;
}

body.darktheme #subscription-popup .form-control {
  background: #20242c !important;
}

/* Inputs/selects sit above the floating label (z-index 9 vs 8); keep them
   transparent so the "Email*" label stays visible. */
body.darktheme #subscription-popup .form-control input,
body.darktheme #subscription-popup .form-control select {
  background-color: transparent !important;
  border-color: #687385 !important;
  color: #fff !important;
}

body.darktheme #subscription-popup .form-control .label,
body.darktheme #subscription-popup .form-control.active-row .label {
  background: #20242c !important;
  color: #fff !important;
  opacity: 1 !important;
}

body.darktheme #subscription-popup .form-control input#emailNL,
body.darktheme #subscription-popup .form-control input#mag_emailNL,
body.darktheme #subscription-popup .form-control select#mag_zccountry {
  background-color: transparent !important;
  color: #fff !important;
  opacity: 1 !important;
}

body.darktheme #subscription-popup .form-control select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 2.75rem;
  background-image:
    linear-gradient(45deg, transparent 50%, #d7dbe2 50%),
    linear-gradient(135deg, #d7dbe2 50%, transparent 50%);
  background-position: calc(100% - 24px) 22px, calc(100% - 16px) 22px;
  background-size: 8px 8px, 8px 8px;
  background-repeat: no-repeat;
}

body.darktheme #subscription-popup .dwn-priv-frm a,
body.darktheme #subscription-popup .privacypolicy {
  color: #fff !important;
  text-decoration: underline;
}

body.darktheme #subscription-popup p.email-error {
  position: static;
  background: transparent !important;
  color: #ff6b6b !important;
  margin: 0 0 12px !important;
  min-height: 1.2em;
}

body.darktheme #subscription-popup .btn-submits button:hover,
body.darktheme #subscription-popup .btn-submits button:focus,
body.darktheme #subscription-popup .btn-submits button:active {
  background: #ffd639 !important;
  color: #111 !important;
}

/* Shared form controls used by gated/detail pages. */
body.darktheme .gated-in,
body.darktheme .gated-in input.txtfield,
body.darktheme .gated-in select.zccountry {
  background-color: #20242c;
  color: #fff;
  border-color: #687385;
}

body.darktheme .gated-in .dwn-priv,
body.darktheme .gated-in .dwn-priv a {
  color: #f5f5f5;
}
/* Country-based marketing consent (injected as #meGDPRMessage): Zoho's link. */
body.darktheme #meGDPRMessage label,
body.darktheme #meGDPRMessage label a {
  color: #fff !important;
}

body.darktheme #meGDPRMessage label a {
  text-decoration: underline;
}
