/* Shared header / nav chrome — Candor marketing site */
:root {
  --primary-blue: #2563eb;
  --dark-blue: #1d4ed8;
}

header.header {
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 12px 0;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

header.header .container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.nav-brand-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  line-height: 0;
}

/* Official lockup: globe + Candor + “Vibe Coding for Data Platform” */
.nav-brand img.candor-brand-lockup,
.nav-brand .candor-brand-lockup,
header.header img.candor-brand-lockup,
img.candor-brand-lockup {
  height: 52px;
  max-height: 52px;
  width: auto;
  max-width: min(300px, 70vw);
  object-fit: contain;
  object-position: left center;
}

.nav-brand img:not(.candor-brand-lockup),
.nav-brand .logo:not(.candor-brand-lockup),
header.header .logo:not(.candor-brand-lockup),
img.candor-logo:not(.candor-brand-lockup) {
  height: 45px;
  width: auto;
  object-fit: contain;
}

.navbar-subheading {
  display: none !important;
}

.nav {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: nowrap;
}

.nav-link {
  color: #111827;
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem;
  border-radius: 10px;
  font-size: 15px;
  white-space: nowrap;
}

.nav-link:hover {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.1), rgba(37, 99, 235, 0.05));
  color: var(--primary-blue);
}

.nav-link.signup-btn-style {
  background: rgba(16, 185, 129, 0.1);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.2);
  font-weight: 600;
}

.nav-link.signup-btn-style:hover {
  background: #10b981;
  color: white;
  border-color: #10b981;
}

.drawer-links a.signup-btn-style,
.drawer-links .signup-btn-style {
  display: block;
  text-align: center;
  padding: 0.8rem 1rem;
  border-radius: 10px;
  margin: 0.25rem 0;
}

.nav-dashboard-btn,
a.nav-dashboard-btn {
  background: rgba(37, 99, 235, 0.08) !important;
  color: #2563eb !important;
  border: 1px solid rgba(37, 99, 235, 0.2) !important;
  padding: 0.5rem 1rem !important;
  border-radius: 10px !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  white-space: nowrap !important;
}

.nav-logout-btn,
a.nav-logout-btn {
  color: #64748b !important;
  font-weight: 500 !important;
  padding: 0.5rem 0.75rem !important;
  text-decoration: none !important;
}

.nav-logout-btn:hover,
a.nav-logout-btn:hover {
  color: #0f172a !important;
  background: rgba(15, 23, 42, 0.05) !important;
}

.nav-download-btn,
a.nav-download-btn,
.drawer-download-btn,
.drawer-links a.nav-download-btn,
.drawer-links a[onclick*="openDownloadModal"],
.nav a[onclick*="openDownloadModal"].nav-download-btn {
  background: linear-gradient(135deg, #10b981, #059669) !important;
  color: white !important;
  padding: 0.5rem 1.2rem !important;
  border-radius: 10px !important;
  font-weight: 600 !important;
  border: none !important;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.2) !important;
  text-decoration: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  position: relative !important;
  overflow: hidden !important;
  isolation: isolate !important;
}

/* Shining sweep across Download buttons */
.nav-download-btn::before,
a.nav-download-btn::before,
.drawer-download-btn::before,
.drawer-links a.nav-download-btn::before,
.drawer-links a[onclick*="openDownloadModal"]::before,
.nav a[onclick*="openDownloadModal"].nav-download-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -120%;
  width: 55%;
  height: 100%;
  background: linear-gradient(
    105deg,
    transparent 0%,
    rgba(255, 255, 255, 0.08) 35%,
    rgba(255, 255, 255, 0.45) 50%,
    rgba(255, 255, 255, 0.08) 65%,
    transparent 100%
  );
  transform: skewX(-18deg);
  animation: candor-download-shine 2.8s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}

.nav-download-btn::after,
a.nav-download-btn::after,
.drawer-download-btn::after,
.drawer-links a.nav-download-btn::after,
.drawer-links a[onclick*="openDownloadModal"]::after,
.nav a[onclick*="openDownloadModal"].nav-download-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
  pointer-events: none;
  z-index: 0;
}

@keyframes candor-download-shine {
  0%,
  72%,
  100% {
    left: -120%;
  }
  38% {
    left: 130%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nav-download-btn::before,
  a.nav-download-btn::before,
  .drawer-download-btn::before,
  .drawer-links a.nav-download-btn::before,
  .drawer-links a[onclick*="openDownloadModal"]::before,
  .nav a[onclick*="openDownloadModal"].nav-download-btn::before {
    animation: none;
  }
}

.dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  min-width: 180px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  z-index: 1001;
  border: 1px solid rgba(0, 0, 0, 0.05);
  padding: 8px;
  margin-top: 10px;
}

.dropdown:hover .dropdown-content,
.dropdown.open .dropdown-content {
  display: block;
}

.dropdown-content a {
  color: #111827;
  padding: 10px 16px;
  text-decoration: none;
  display: block;
  border-radius: 8px;
  font-weight: 500;
  font-size: 14px;
}

.dropdown-content a:hover {
  background: rgba(37, 99, 235, 0.08);
  color: var(--primary-blue);
}

.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 2rem;
  color: var(--primary-blue);
  cursor: pointer;
}

.mobile-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
  z-index: 1199;
}

.mobile-drawer-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.mobile-drawer {
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: 75vw;
  max-width: 320px;
  background: #f7f8fa;
  box-shadow: 2px 0 24px rgba(0, 0, 0, 0.18);
  transform: translateX(-100%);
  transition: transform 0.22s ease;
  z-index: 1200;
  display: flex;
  flex-direction: column;
  padding-top: 2rem;
}

.mobile-drawer.open {
  transform: translateX(0);
}

.drawer-links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.5rem;
}

.drawer-links a {
  padding: 0.8rem 1rem;
  text-decoration: none;
  color: #111827;
  border-radius: 12px;
  font-weight: 500;
}

.drawer-download-btn {
  margin-top: 10px;
  text-align: center;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 1250px) {
  .nav {
    display: none;
  }

  .mobile-nav-toggle {
    display: block;
  }

  .navbar-subheading {
    display: none;
  }
}

/* Smooth in-page scroll (site-navigation.js) */
html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
