/* ── Shared styles across all DeepXplore pages ── */

/* Force scrollbar track to always occupy space so fixed header width is
   consistent across pages — prevents logo/button jump on navigation.
   overflow-x: hidden on body makes body the scroll container in some
   browsers, so scrollbar-gutter on html has no effect; overflow-y: scroll
   on html is the reliable cross-browser fix. */
html {
  overflow-y: scroll;
}

/* ── Header & Nav ─────────────────────────────── */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(8, 8, 8, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(212, 122, 13, 0.15);
  z-index: 1000;
  padding: 1rem 0;
  transition: all 0.3s ease;
}

.header.scrolled {
  background: rgba(8, 8, 8, 0.97);
  border-bottom: 1px solid rgba(212, 122, 13, 0.2);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.4);
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.8rem;
  font-weight: 700;
  background: linear-gradient(135deg, #D47A0D, #FF8C00);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
}

.nav-links a:hover { color: #FF8C00; }

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(135deg, #D47A0D, #FF8C00);
  transition: width 0.3s ease;
}

.nav-links a:hover::after { width: 100%; }

.nav-dropdown { position: relative; }
.nav-dropdown > a::after { display: none; }

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  padding-top: 10px;
  left: 50%;
  transform: translateX(-50%);
  background: #111;
  border-radius: 0.75rem;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5);
  min-width: 260px;
  padding: 0.5rem 0;
  z-index: 1001;
  border: 1px solid rgba(212, 122, 13, 0.2);
}

.nav-dropdown:hover .dropdown-menu { display: block; }

.dropdown-menu a {
  display: block;
  padding: 0.6rem 1.2rem;
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.dropdown-menu a:hover {
  color: #FF8C00;
  background: rgba(212, 122, 13, 0.08);
}

.nav-buttons {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.slack-button {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 0.5rem;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.slack-button:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.4);
}

.slack-icon { width: 16px; height: 16px; }

.cta-button {
  background: linear-gradient(135deg, #D47A0D, #FF8C00);
  color: white;
  padding: 0.6rem 1.4rem;
  border-radius: 0.5rem;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(212, 122, 13, 0.3);
}

/* ── Mobile nav strip — hidden on desktop ─────── */
.mobile-nav-strip { display: none; }

@media (max-width: 768px) {
  .nav-links,
  .slack-button { display: none; }

  /* Consistent container padding across all pages on mobile */
  .container { padding: 0 1rem; }

  /* Hero sections need extra top padding to clear the taller mobile header + strip */
  .page-hero,
  .article-hero { padding-top: 140px !important; }

  .mobile-nav-strip {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    padding: 0.75rem 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    flex-wrap: wrap;
    align-items: center;
    background: rgba(8, 8, 8, 0.97);
  }

  .mobile-nav-strip a {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.65);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
    white-space: nowrap;
  }

  .mobile-nav-strip a:hover,
  .mobile-nav-strip a.active { color: #FF8C00; }
}
