/* =================================================================
   Shared styles: top-bar + nav + hamburger + footer
   Source of truth for the 4 landing pages (index / technology /
   compliance / demo). Don't inline duplicates of these rules in
   page-specific <style> blocks.

   Depends on CSS custom properties defined in each page:
     --bg-base --text-primary --text-secondary --text-muted
     --brand --brand-hover --border --success
     --max-width
   ================================================================= */

/* ---- TOP BAR (agilist.cn brand strip) ---- */
.top-bar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1001;
  background: #000; border-bottom: 1px solid var(--border);
  font-size: 12px; color: var(--text-muted);
}
.top-bar .nav-inner { height: 32px; justify-content: space-between; }
.top-back { color: var(--text-muted); text-decoration: none; transition: color 0.2s; }
.top-back:hover { color: var(--brand); }
.top-brand { color: var(--text-muted); letter-spacing: 0.02em; }
@media (max-width: 720px) { .top-brand { display: none; } }

/* ---- NAV ---- */
nav {
  position: fixed; top: 32px; left: 0; right: 0; z-index: 1000;
  background: rgba(8, 9, 10, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s;
}
nav.scrolled { box-shadow: 0 1px 24px rgba(0,0,0,0.4); }
.nav-inner {
  max-width: var(--max-width, 1200px); margin: 0 auto; padding: 0 24px;
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.nav-logo {
  font-weight: 700; font-size: 18px; color: var(--text-primary);
  text-decoration: none; letter-spacing: -0.02em;
}
.nav-links {
  display: flex; align-items: center; gap: 28px;
  list-style: none; margin: 0; padding: 0;
}
.nav-links a {
  color: var(--text-secondary); text-decoration: none;
  font-size: 14px; font-weight: 500; transition: color 0.2s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--text-primary); }
.nav-cta {
  background: var(--brand); color: #fff !important;
  padding: 8px 18px; border-radius: 6px; font-weight: 500;
  font-size: 14px !important;
  transition: background 0.2s, transform 0.2s;
}
.nav-cta:hover { background: var(--brand-hover, #2563eb); transform: translateY(-1px); }

/* ---- HAMBURGER (mobile toggle) ---- */
.hamburger {
  display: none; flex-direction: column; gap: 5px;
  cursor: pointer; background: none; border: none; padding: 4px;
}
.hamburger span {
  display: block; width: 22px; height: 2px;
  background: var(--text-primary); border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}
.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; flex-direction: column;
    position: absolute; top: 64px; left: 0; right: 0;
    background: rgba(8, 9, 10, 0.95);
    backdrop-filter: blur(20px);
    padding: 24px; gap: 20px;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
  }
  .hamburger { display: flex; }
}

/* ---- FOOTER ---- */
footer {
  border-top: 1px solid var(--border); padding: 48px 0 32px;
  color: var(--text-muted); font-size: 13px; background: #050607;
}
.footer-inner {
  max-width: var(--max-width, 1200px); margin: 0 auto; padding: 0 24px;
  display: flex; flex-wrap: wrap; justify-content: space-between;
  align-items: flex-start; gap: 32px;
}
.footer-brand { display: flex; flex-direction: column; gap: 8px; }
.footer-brand-name {
  font-size: 16px; font-weight: 700; color: var(--text-primary);
  letter-spacing: -0.02em;
}
.footer-brand-tagline { color: var(--text-muted); font-size: 13px; }
.footer-links { display: flex; gap: 40px; }
.footer-col { display: flex; flex-direction: column; gap: 8px; }
.footer-col-title {
  font-size: 13px; font-weight: 600; color: var(--text-secondary);
  margin-bottom: 4px;
}
.footer-col a {
  color: var(--text-muted); text-decoration: none;
  font-size: 13px; transition: color 0.2s;
}
.footer-col a:hover { color: var(--brand); }
.footer-bottom {
  width: 100%; display: flex; justify-content: space-between;
  align-items: center; padding-top: 24px;
  border-top: 1px solid var(--border); margin-top: 8px;
}
.footer-status {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--success);
}
.footer-status-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--success); display: inline-block;
  animation: sharedStatusPulse 2s ease-in-out infinite;
}
@keyframes sharedStatusPulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 4px rgba(16,185,129,0.4); }
  50%      { opacity: 0.6; box-shadow: 0 0 8px rgba(16,185,129,0.6); }
}
@media (max-width: 720px) {
  .footer-inner { flex-direction: column; align-items: center; text-align: center; }
  .footer-links { flex-direction: column; gap: 24px; align-items: center; }
  .footer-bottom { flex-direction: column; gap: 8px; align-items: center; }
}
