@import url('https://fonts.googleapis.com/css2?family=Pacifico&family=Inter:wght@400;500;600;700&display=swap');

:root{
  --black-true:#000; --black-900:#0B0B0C; --black-800:#101113;
  --outline:rgba(255,255,255,.06);
  --ink:#DCDCDC; --ink-dim:#A9A9A9; --ink-muted:#8A8A8A;
  --accent:#C5A572; --accent-2:#9B7F4E;
  --glass:rgba(16,17,19,.75);
  --shadow:0 10px 30px rgba(0,0,0,.45);
  --shadow-glow:0 0 40px rgba(197,165,114,.25);
  --radius:16px;
}

/* Floating Navigation Bar - Stays Fixed at Top When Scrolling */
.nav{
  position: fixed !important;
  top: 20px !important;
  left: 20px !important;
  right: 20px !important;
  z-index: 99999 !important;
  display: grid !important;
  grid-template-columns: 1fr auto 1fr !important;
  align-items: center !important;
  gap: 16px !important;
  padding: 14px 24px !important;
  border-radius: 24px !important;
  background: linear-gradient(135deg, rgba(16,17,19,.85), rgba(16,17,19,.75)) !important;
  backdrop-filter: blur(20px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
  border: 1px solid rgba(255,255,255,.08) !important;
  box-shadow: 
    0 10px 30px rgba(0,0,0,.45),
    0 0 40px rgba(197,165,114,.25),
    inset 0 1px 0 rgba(255,255,255,.05) !important;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
  max-width: 1400px !important;
  margin: 0 auto !important;
  width: calc(100% - 40px) !important;
  visibility: visible !important;
  opacity: 1 !important;
  transform: translateZ(0) !important; /* Force GPU acceleration for smooth scrolling */
}

/* Scrolled state - More compact and prominent */
.nav.scrolled {
  top: 12px !important;
  padding: 12px 20px !important;
  background: linear-gradient(135deg, rgba(16,17,19,.95), rgba(16,17,19,.88)) !important;
  backdrop-filter: blur(25px) saturate(200%) !important;
  -webkit-backdrop-filter: blur(25px) saturate(200%) !important;
  box-shadow: 
    0 8px 40px rgba(0,0,0,.7), 
    0 0 60px rgba(197,165,114,.35),
    inset 0 1px 0 rgba(255,255,255,.08) !important;
  border-color: rgba(197, 165, 114, .25) !important;
  border-width: 1.5px !important;
}

/* Glassy side panels */
.nav-glass{
  height: 44px !important;
  border-radius: 16px !important;
  background: linear-gradient(135deg, rgba(255,255,255,.08), rgba(255,255,255,.03)) !important;
  border: 1px solid rgba(255,255,255,.08) !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,.12),
    inset 0 -1px 0 rgba(0,0,0,.2) !important;
  display: block !important;
}

.nav-glass.left {
  width: 100%;
}

.nav-glass.right {
  width: 100% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  padding-right: 0 !important;
}

.nav.scrolled .nav-glass {
  height: 40px;
  background: linear-gradient(135deg, rgba(255,255,255,.08), rgba(255,255,255,.03));
}

/* Centered Logo */
.logo-link {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-decoration: none !important;
}

.logo {
  height: 52px !important;
  width: auto !important;
  justify-self: center !important;
  object-fit: cover !important;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
  filter: drop-shadow(0 4px 12px rgba(0,0,0,.5)) !important;
  display: block !important;
  visibility: visible !important;
}

.nav.scrolled .logo {
  height: 44px;
}

.logo.rounded {
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,.08);
}

.logo.glow {
  box-shadow: 
    0 0 0 3px rgba(255,255,255,.1),
    0 0 25px rgba(197,165,114,.4),
    0 0 50px rgba(197,165,114,.2) !important;
}

.logo:hover {
  transform: scale(1.1) rotate(3deg) !important;
  filter: drop-shadow(0 8px 24px rgba(197,165,114,.6)) !important;
  box-shadow: 
    0 0 0 3px rgba(197,165,114,.25),
    0 0 35px rgba(197,165,114,.6),
    0 0 70px rgba(197,165,114,.3) !important;
}

/* Profile/Login Button */
.btn-auth {
  justify-self: end !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 12px 20px !important;
  font-family: Inter, system-ui, sans-serif !important;
  color: #0f0f10 !important;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%) !important;
  border: none !important;
  border-radius: 14px !important;
  text-decoration: none !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  letter-spacing: 0.3px !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  box-shadow: 
    0 4px 18px rgba(197,165,114,.35),
    inset 0 1px 0 rgba(255,255,255,.25),
    inset 0 -1px 0 rgba(0,0,0,.1) !important;
  position: relative !important;
  overflow: hidden !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.btn-auth svg {
  transition: transform 0.3s;
}

.btn-auth::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.35), transparent);
  transition: left 0.5s;
}

.btn-auth:hover::before {
  left: 100%;
}

.btn-auth:hover {
  filter: brightness(1.15) !important;
  transform: translateY(-3px) !important;
  box-shadow: 
    0 8px 28px rgba(197,165,114,.5),
    inset 0 1px 0 rgba(255,255,255,.35),
    inset 0 -1px 0 rgba(0,0,0,.05) !important;
}

.btn-auth:hover svg {
  transform: scale(1.1);
}

.btn-auth:active {
  transform: translateY(0);
}

/* Accessibility focus */
:focus-visible {
  outline: 3px solid rgba(197,165,114,.3);
  outline-offset: 3px;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .nav {
    grid-template-columns: 80px 1fr 80px;
    gap: 12px;
    padding: 10px 14px;
    top: 12px;
    left: 12px;
    right: 12px;
  }

  .nav.scrolled {
    padding: 8px 12px;
    top: 8px;
  }

  .nav-glass {
    height: 40px;
  }

  .nav-glass.left,
  .nav-glass.right {
    width: 100%;
    min-width: 70px;
  }

  .logo {
    height: 42px;
  }

  .nav.scrolled .logo {
    height: 36px;
  }

  .btn-auth {
    padding: 9px 12px;
    font-size: 12px;
    gap: 6px;
  }

  .btn-auth svg {
    width: 14px;
    height: 14px;
  }
}

@media (max-width: 480px) {
  .nav {
    top: 8px;
    left: 8px;
    right: 8px;
    gap: 8px;
  }

  .nav.scrolled {
    top: 4px;
  }

  .btn-auth span {
    display: none;
  }

  .btn-auth {
    padding: 10px;
  }
}

/* Smooth entrance animation */
@keyframes navSlideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.nav {
  animation: navSlideDown 0.6s ease-out !important;
}

/* Ensure navbar is always visible */
nav.nav {
  display: grid !important;
  visibility: visible !important;
  opacity: 1 !important;
}
