/* ==========================================================================
   NsN — Tech news footer (light, black text — readable on white)
   ========================================================================== */

.nsn-site-footer {
  --nsn-ft-bg: #ffffff;
  --nsn-ft-bg2: #f8fafc;
  --nsn-ft-text: #0f172a;
  --nsn-ft-muted: #475569;
  --nsn-ft-accent: #0284c7;
  --nsn-ft-border: rgba(15, 23, 42, 0.1);
  --nsn-ft-max: 1200px;
  margin-top: 40px;
  background: var(--nsn-ft-bg);
  color: var(--nsn-ft-text);
  border-top: 1px solid var(--nsn-ft-border);
  font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
  box-shadow: 0 -8px 28px rgba(15, 23, 42, 0.04);
}

/* Override theme light footer wash-out */
body.nsn-light .nsn-site-footer,
body.nsn-light .site-footer.nsn-site-footer,
body .site-footer.nsn-site-footer {
  background: #ffffff !important;
  color: #0f172a !important;
}

.nsn-site-footer a {
  color: #0f172a;
  text-decoration: none;
  transition: color 0.15s ease;
}

.nsn-site-footer a:hover {
  color: var(--nsn-ft-accent);
}

.nsn-footer-inner {
  max-width: var(--nsn-ft-max);
  margin: 0 auto;
  padding: 0 20px;
}

.nsn-footer-top {
  padding: 40px 0 26px;
}

.nsn-footer-grid {
  display: grid;
  grid-template-columns: 1.35fr 0.9fr 1.15fr 0.95fr;
  gap: 28px 24px;
}

/* Brand */
.nsn-footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  color: #0f172a;
}

.nsn-footer-logo img {
  width: 44px;
  height: 44px;
  border-radius: 11px;
  object-fit: cover;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.08), 0 6px 16px rgba(15, 23, 42, 0.08);
}

.nsn-footer-brand-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.nsn-footer-brand-text .name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: #0f172a !important;
}

.nsn-footer-brand-text .tag {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0284c7 !important;
}

.nsn-footer-desc {
  margin: 0 0 8px;
  color: #0f172a !important;
  font-size: 0.9rem;
  font-weight: 650;
  line-height: 1.45;
}

.nsn-footer-mission {
  margin: 0 0 14px;
  color: #334155 !important;
  font-size: 0.86rem;
  line-height: 1.55;
  max-width: 36ch;
}

.nsn-footer-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.nsn-footer-badges span {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #0f172a !important;
  background: #f1f5f9;
  border: 1px solid rgba(15, 23, 42, 0.1);
}

/* Columns */
.nsn-footer-heading {
  margin: 0 0 12px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #0f172a !important;
  position: relative;
  padding-bottom: 8px;
}

.nsn-footer-heading::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, #0284c7, transparent);
}

.nsn-footer-heading.is-small {
  margin-top: 18px;
  margin-bottom: 6px;
  font-size: 0.72rem;
}

.nsn-footer-links,
.nsn-footer-posts {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nsn-footer-links li {
  margin: 0;
}

.nsn-footer-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 0;
  font-size: 0.9rem;
  font-weight: 650;
  color: #0f172a !important;
  border-bottom: 1px solid transparent;
}

.nsn-footer-links a:hover {
  color: #0284c7 !important;
}

.nsn-footer-links .count {
  font-size: 0.72rem;
  font-weight: 700;
  color: #64748b !important;
  background: #f1f5f9;
  padding: 1px 7px;
  border-radius: 999px;
}

.nsn-footer-col .menu-item {
  list-style: none;
}
.nsn-footer-col .menu-item a {
  display: block;
  padding: 6px 0;
  font-size: 0.9rem;
  font-weight: 650;
  color: #0f172a !important;
}
.nsn-footer-col .menu-item a:hover {
  color: #0284c7 !important;
}

.nsn-footer-posts li {
  margin: 0;
  border-bottom: 1px solid var(--nsn-ft-border);
}
.nsn-footer-posts li:last-child {
  border-bottom: 0;
}

.nsn-footer-posts a {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 0;
}

.nsn-footer-posts .t {
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.35;
  color: #0f172a !important;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.nsn-footer-posts a:hover .t {
  color: #0284c7 !important;
}

.nsn-footer-posts .d {
  font-size: 0.72rem;
  color: #64748b !important;
  font-weight: 500;
}

.nsn-footer-newsletter p {
  margin: 0 0 10px;
  font-size: 0.84rem;
  color: #334155 !important;
  line-height: 1.45;
}

.nsn-footer-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 700;
  color: #ffffff !important;
  background: linear-gradient(90deg, #0ea5e9, #0284c7);
  box-shadow: 0 6px 16px rgba(2, 132, 199, 0.22);
}

.nsn-footer-cta:hover {
  filter: brightness(1.05);
  color: #ffffff !important;
}

/* Bottom bar */
.nsn-footer-bottom {
  border-top: 1px solid var(--nsn-ft-border);
  background: #f8fafc !important;
  padding: 14px 0;
}

.nsn-footer-bottom-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
}

.nsn-footer-copy {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  font-size: 0.82rem;
  color: #0f172a !important;
}

.nsn-footer-copy strong {
  color: #0f172a !important;
  font-weight: 800;
}

.nsn-footer-copy .sep {
  opacity: 0.45;
  color: #64748b;
}

.nsn-footer-meta {
  font-size: 0.78rem;
  color: #475569 !important;
  font-weight: 600;
  letter-spacing: 0.02em;
}

body.nsn-custom-footer #newsmatic-scroll-to-top {
  background: #0284c7 !important;
  border-radius: 10px !important;
}

@media (max-width: 1024px) {
  .nsn-footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .nsn-footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .nsn-footer-top {
    padding: 28px 0 18px;
  }
  .nsn-footer-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }
  .nsn-footer-brand {
    grid-column: auto;
  }
  .nsn-footer-bottom-inner {
    flex-direction: column;
    align-items: flex-start;
  }
  .nsn-footer-mission {
    max-width: none;
  }
}
