/* -------------------------------------------------------------
   ADAPTIVE NAVBAR STYLING
------------------------------------------------------------- */
.navbar {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 80px;
  z-index: 1000;
  display: flex;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background-color: transparent;
  
  /* Smooth transition for capsule morphing */
  transition: 
    top 0.5s cubic-bezier(0.25, 1, 0.5, 1),
    width 0.5s cubic-bezier(0.25, 1, 0.5, 1),
    height 0.5s cubic-bezier(0.25, 1, 0.5, 1),
    background-color 0.5s cubic-bezier(0.25, 1, 0.5, 1),
    border-radius 0.5s cubic-bezier(0.25, 1, 0.5, 1),
    border-color 0.5s cubic-bezier(0.25, 1, 0.5, 1),
    box-shadow 0.5s cubic-bezier(0.25, 1, 0.5, 1);
}

.nav-container {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 48px;
  transition: padding 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* Scrolled State: Morph into Floating Capsule */
.navbar.scrolled {
  top: 20px;
  width: 90%;
  max-width: 850px;
  left: 50%;
  transform: translateX(-50%);
  height: 64px;
  background-color: rgba(255, 251, 242, 0.65); /* More transparent cream canvas */
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid rgba(26, 26, 26, 0.12);
  border-radius: 14px;
  box-shadow: 
    0 10px 30px rgba(0, 0, 0, 0.12),
    inset 0 1px 1px rgba(255, 255, 255, 0.8);
}

.navbar.scrolled .nav-container {
  padding: 0 24px;
}

/* Logo and Symbol */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: #1a1a1a; /* Dark charcoal color matches branding logo text */
  transition: color 0.5s;
}

.navbar.scrolled .nav-logo {
  color: #1a1a1a; /* Dark charcoal on scrolled cream */
}

.logo-compass {
  width: 28px;
  height: 28px;
  object-fit: contain;
  display: block;
}

.logo-text {
  font-family: 'Outfit', sans-serif;
  font-weight: 700; /* Outfit 700 (Bold) */
  font-size: 1.4rem;
  line-height: 1;
  letter-spacing: -0.02em;
  opacity: 1;
  max-width: 150px;
  overflow: hidden;
  transition: opacity 0.4s cubic-bezier(0.25, 1, 0.5, 1), max-width 0.4s cubic-bezier(0.25, 1, 0.5, 1), color 0.4s ease;
}

.navbar.scrolled .logo-text {
  opacity: 0;
  max-width: 0;
}

/* Menu Links */
.nav-menu {
  display: flex;
  align-items: center;
  gap: 20px;
  list-style: none;
}

.nav-link {
  text-decoration: none;
  font-family: 'Inter', sans-serif; /* Inter for navigation */
  font-size: 0.95rem; /* ~15px */
  font-weight: 500; /* Inter 500 (Medium) */
  color: #1a1a1a; /* Black menu links when transparent */
  padding: 8px 16px;
  border-radius: 20px;
  transition: all 0.3s ease;
}

.navbar.scrolled .nav-link {
  color: #1a1a1a; /* Full opacity dark charcoal */
}

.nav-link:hover {
  color: #1a1a1a;
  background-color: rgba(26, 26, 26, 0.06);
}

.navbar.scrolled .nav-link:hover {
  color: #1a1a1a;
  background-color: rgba(26, 26, 26, 0.06);
}

.nav-link.active {
  color: #1a1a1a;
}

.navbar.scrolled .nav-link.active {
  color: #1a1a1a;
}

/* Action Buttons */
.nav-buttons {
  display: flex;
  gap: 12px;
  align-items: center;
}

.btn-signin {
  text-decoration: none;
  font-family: 'Inter', sans-serif; /* Inter for buttons */
  font-size: 0.9rem; /* ~15px */
  font-weight: 600; /* Inter 600 (SemiBold) */
  color: #1a1a1a;
  padding: 10px 20px;
  border-radius: 30px;
  background-color: #e9b7aa; /* Soft warm orange/terracotta */
  border: 1px solid rgba(26, 26, 26, 0.08);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.btn-signin:hover {
  background-color: #f0c5bb;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.12);
}

.btn-demo {
  text-decoration: none;
  font-family: 'Inter', sans-serif; /* Inter for buttons */
  font-size: 0.9rem; /* ~15px */
  font-weight: 600; /* Inter 600 (SemiBold) */
  color: #1a1a1a;
  padding: 10px 20px;
  border-radius: 30px;
  background-color: #fffbf2; /* Warm Cream */
  border: 1px solid rgba(26, 26, 26, 0.12);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.btn-demo:hover {
  background-color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.12);
}

/* -------------------------------------------------------------
   RESPONSIVE NAVBAR & GLOBAL OVERRIDES
------------------------------------------------------------- */
@media (max-width: 768px) {
  .nav-container {
    padding: 0 16px;
  }
  .nav-menu {
    display: none; /* Hide middle links on mobile for capsule cleanliness */
  }
  .navbar {
    height: 64px;
  }
  .navbar.scrolled {
    width: 95%;
    height: 56px;
    top: 12px;
    border-radius: 12px;
  }
  .navbar.scrolled .nav-container {
    padding: 0 16px;
  }
  .btn-signin,
  .btn-demo {
    padding: 8px 14px;
    font-size: 0.8rem;
  }
  .logo-text {
    font-size: 1.2rem;
  }
}

@media (max-width: 480px) {
  .nav-container {
    padding: 0 12px;
  }
  .btn-signin,
  .btn-demo {
    padding: 7px 12px;
    font-size: 0.75rem;
  }
  .nav-buttons {
    gap: 8px;
  }
  .logo-compass {
    width: 24px;
    height: 24px;
  }
  .logo-text {
    font-size: 1.1rem;
  }
}
