@import url('variables.css');

/* ==========================================================================
   Top Header Bar
   ========================================================================== */
.top-header-bar {
  width: 100%;
  background: #ffffff;
  border-bottom: none;
  padding: 8px 0;
  font-size: 0.78rem;
  font-weight: 500;
  color: #475569;
  position: relative;
  z-index: 100;
}

.top-promo-message {
  color: #475569;
}

.btn-download-now {
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  margin-left: 5px;
  transition: var(--transition-smooth);
}

.btn-download-now:hover {
  color: var(--secondary);
  text-decoration: underline;
}

.top-link {
  color: #475569;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition-smooth);
}

.top-link:hover {
  color: var(--primary);
}

.top-lang-select {
  border: none;
  background: transparent;
  font-size: 0.75rem;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  outline: none;
}

/* ==========================================================================
   Main Navigation Floating Capsule
   ========================================================================== */
.main-header-wrapper {
  position: sticky;
  top: 12px;
  z-index: 1000;
  margin: 12px auto 0 auto;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: #ffffff00;
  width: 100%;
}

.main-header {
  background: #265DF5;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(38, 93, 245, 0.2);
  padding: 14px 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  width: 100%;
}

/* Header scrolled / sticky compress state */
.main-header.scrolled {
  padding: 10px 0;
  box-shadow: 0 15px 35px rgba(38, 93, 245, 0.3);
  border-color: rgba(255, 255, 255, 0.2);
  background: #265DF5;
}

/* Logo */
.header-logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: var(--transition-smooth);
}

.header-logo-img {
  height: auto;
  max-height: 38px;
  max-width: 180px;
  object-fit: contain;
  filter: brightness(0) invert(1);
  transition: var(--transition-smooth);
}

.main-header.scrolled .header-logo-img {
  max-height: 36px;
}

/* Navbar Menu Link Items */
.navbar-custom {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-menu {
  display: flex;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 8px;
}

.nav-item {
  position: relative;
}

.nav-link-custom {
  font-size: var(--font-size-xs);
  font-weight: 600;
  color: #ffffff !important;
  padding: 6px 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  position: relative;
  text-decoration: none;
  border-radius: 20px;
  transition: var(--transition-smooth);
}

.nav-link-custom i {
  color: #ffffff !important;
}

.nav-link-custom:hover {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.15);
}

.nav-link-custom.active {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.25);
  font-weight: 700;
}

/* ==========================================================================
   Go Pro Glassy Premium Link
   ========================================================================== */
.nav-link-go-pro {
  position: relative;
  background: rgba(255, 255, 255, 0.16) !important;
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.35) !important;
  border-radius: 50px !important;
  padding: 6px 16px !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(255, 193, 7, 0.25), inset 0 1px 1px rgba(255, 255, 255, 0.6);
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nav-link-go-pro::before {
  content: '';
  position: absolute;
  top: 0;
  left: -150%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    115deg,
    transparent 20%,
    rgba(255, 255, 255, 0.65) 50%,
    transparent 80%
  );
  transform: skewX(-20deg);
  animation: glassShimmer 3.5s infinite ease-in-out;
}

.nav-link-go-pro:hover {
  background: rgba(255, 255, 255, 0.28) !important;
  border-color: rgba(255, 255, 255, 0.7) !important;
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 8px 25px rgba(255, 193, 7, 0.45), inset 0 1px 2px rgba(255, 255, 255, 0.9);
  color: #ffffff !important;
}

.nav-link-go-pro.active {
  background: linear-gradient(135deg, rgba(255, 193, 7, 0.3), rgba(255, 255, 255, 0.25)) !important;
  border-color: #ffc107 !important;
  box-shadow: 0 0 20px rgba(255, 193, 7, 0.5), inset 0 1px 2px rgba(255, 255, 255, 0.8);
}

.nav-link-go-pro .pro-badge-icon {
  color: #ffc107 !important;
  font-size: 1rem;
  filter: drop-shadow(0 0 4px rgba(255, 193, 7, 0.8));
  animation: proIconPulse 2s infinite ease-in-out;
}

@keyframes glassShimmer {
  0% {
    left: -150%;
  }
  30% {
    left: 150%;
  }
  100% {
    left: 150%;
  }
}

@keyframes proIconPulse {
  0%, 100% {
    transform: scale(1);
    filter: drop-shadow(0 0 4px rgba(255, 193, 7, 0.8));
  }
  50% {
    transform: scale(1.2) rotate(8deg);
    filter: drop-shadow(0 0 10px rgba(255, 193, 7, 1));
  }
}

/* Underline Hover Effect */
/* .nav-link-custom::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: var(--transition-smooth);
} */

.nav-link-custom:hover::after {
  width: 100%;
}

/* Single Column Loans Dropdown */
.nav-item-has-dropdown {
  position: relative;
}

.loans-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 300px;
  background-color: var(--white);
  box-shadow: var(--shadow-lg);
  border-top: 3px solid var(--primary);
  border-radius: 0 0 var(--radius-card) var(--radius-card);
  padding: 10px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(15px);
  transition: var(--transition-bounce);
  z-index: 999;
}

.nav-item-has-dropdown:hover .loans-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.loans-dropdown-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.loans-dropdown-links li {
  margin: 0;
}

.loans-dropdown-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 20px;
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--dark-color);
  transition: var(--transition-smooth);
  text-decoration: none;
}

.loans-dropdown-link i {
  color: var(--primary);
  font-size: 1.1rem;
  transition: var(--transition-smooth);
  width: 20px;
  text-align: center;
}

.loans-dropdown-link img {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.loans-dropdown-link:hover {
  background-color: rgba(20, 123, 255, 0.06);
  color: var(--primary);
  padding-left: 24px;
}

.loans-dropdown-link:hover i {
  transform: scale(1.15);
}

/* Header Action Buttons */
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.call-btn {
  background: none;
  border: none;
  color: var(--primary);
  font-size: 1.15rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: rgba(20, 123, 255, 0.06);
  text-decoration: none;
}

.call-btn:hover {
  background-color: var(--primary) !important;
  color: var(--white) !important;
  transform: translateY(-2px);
}

/* Navigation Buttons */
.btn-login {
  padding: 8px 24px;
  font-size: var(--font-size-sm);
  font-weight: 700;
  color: #265DF5 !important;
  background: #ffffff !important;
  border: none !important;
  border-radius: var(--radius-button);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: var(--transition-smooth);
  text-decoration: none !important;
}

.btn-login:hover {
  background: #F1F5F9 !important;
  color: #1D4ED8 !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

/* Mobile Toggle Hamburger */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.6rem;
  color: #ffffff !important;
  cursor: pointer;
}

/* ==========================================================================
   User Profile Frame & Header Chip
   ========================================================================== */
.header-user-profile {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.profile-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 5px 16px 5px 6px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50px;
  text-decoration: none !important;
  color: #ffffff !important;
  font-weight: 600;
  font-size: 0.88rem;
  transition: all 0.25s ease;
  cursor: pointer;
}

.profile-chip.dropdown-toggle::after {
  display: none !important;
}

.profile-chip:hover,
.profile-chip:focus {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
  color: #ffffff !important;
}

.profile-name {
  color: #ffffff !important;
  font-weight: 600;
}

/* ==========================================================================
   Pro Premium User Profile Chip (Gold Shine Animation)
   ========================================================================== */
.profile-chip.pro-profile-chip {
  position: relative;
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.32) 0%, rgba(255, 140, 0, 0.25) 100%) !important;
  border: 1px solid rgba(255, 215, 0, 0.8) !important;
  box-shadow: 0 4px 18px rgba(255, 193, 7, 0.38), inset 0 1px 2px rgba(255, 255, 255, 0.8) !important;
  overflow: hidden;
  color: #ffffff !important;
  font-weight: 700 !important;
  padding-right: 12px !important;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.profile-chip.pro-profile-chip::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -150%;
  width: 100%;
  height: 200%;
  background: linear-gradient(
    115deg,
    transparent 20%,
    rgba(255, 245, 180, 0.85) 45%,
    rgba(255, 255, 255, 0.95) 50%,
    rgba(255, 245, 180, 0.85) 55%,
    transparent 80%
  );
  transform: rotate(25deg);
  animation: goldShineSweep 3.2s infinite ease-in-out;
  pointer-events: none;
}

.profile-chip.pro-profile-chip:hover {
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.5) 0%, rgba(255, 140, 0, 0.4) 100%) !important;
  border-color: #ffe066 !important;
  box-shadow: 0 8px 25px rgba(255, 193, 7, 0.6), inset 0 1px 3px rgba(255, 255, 255, 1) !important;
  transform: translateY(-2px) scale(1.03);
}

.profile-chip.pro-profile-chip .pro-crown-icon {
  color: #ffc107 !important;
  font-size: 1.1rem;
  filter: drop-shadow(0 0 6px rgba(255, 193, 7, 0.9));
  animation: goldCrownPulse 2.2s infinite ease-in-out;
}

.profile-chip.pro-profile-chip .pro-gold-badge {
  background: linear-gradient(135deg, #ffe066 0%, #ffab00 100%);
  color: #3d2400;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 20px;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
}

@keyframes goldShineSweep {
  0% {
    left: -150%;
  }
  35% {
    left: 150%;
  }
  100% {
    left: 150%;
  }
}

@keyframes goldCrownPulse {
  0%, 100% {
    transform: scale(1);
    filter: drop-shadow(0 0 4px rgba(255, 193, 7, 0.8));
  }
  50% {
    transform: scale(1.2) rotate(10deg);
    filter: drop-shadow(0 0 12px rgba(255, 215, 0, 1));
  }
}

.profile-avatar-frame {
  position: relative;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  padding: 2px;
  background: linear-gradient(135deg, #265DF5 0%, #00d2ff 100%);
  box-shadow: 0 2px 8px rgba(20, 123, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

.profile-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background-color: #ffffff;
}

.profile-name {
  max-width: 130px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.profile-dropdown-menu {
  min-width: 220px;
  border-radius: 16px !important;
  padding: 8px 0;
  margin-top: 10px !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1) !important;
  border: 1px solid rgba(20, 123, 255, 0.1) !important;
}

.dropdown-header-box {
  padding: 10px 16px;
}

.user-display-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: #0f172a;
}

.user-display-email {
  font-size: 0.78rem;
  color: #64748b;
  overflow: hidden;
  text-overflow: ellipsis;
}

.profile-dropdown-menu .dropdown-item {
  padding: 8px 16px;
  font-size: 0.85rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.profile-dropdown-menu .dropdown-item:hover {
  background-color: rgba(20, 123, 255, 0.06);
}
