/* Custom Header Styles */
.navbar-brand {
    font-weight: bold;
  }
  .nav-link.active {
    font-weight: 600;
  }
  .realtor-badge {
    background-color: #28a745;
    color: white;
    font-size: 0.75em;
    padding: 2px 6px;
    border-radius: 3px;
  }
  .notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 0.7em;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .nav-item {
    position: relative;
  }
  /* Avatar image style */
  .avatar-image-small {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 8px; /* Spacing from text */
    border: 1px solid rgba(255, 255, 255, 0.3); /* Light border for dark navbar */
  }
  .navbar-dark .dropdown-toggle::after {
    color: rgba(255, 255, 255, 0.75); /* Dropdown arrow color */
  }
  .list-business-btn-header {
    background-color: #007bff; /* Bootstrap primary blue */
    color: white;
    border-radius: 0.25rem; /* Bootstrap default */
    padding: 0.375rem 0.75rem;
    text-decoration: none;
    font-weight: 400;
    transition: background-color 0.15s ease-in-out;
  }
  .list-business-btn-header:hover {
    background-color: #0056b3;
  }
  
  .list-business-button {
    display: inline-flex; /* Default to inline-flex for desktop */
    padding: 10px 20px;
    border-radius: 25px; /* More rounded, pill shape */
    background-color: #0c29ab; /* Black */
    color: #ffffff;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.2s ease;
    text-decoration: none; /* Ensure it's a link style */
    align-items: center;
    justify-content: center;
    font-size: 15px; /* Match nav links */
  }
  
  .list-business-button:hover {
    background-color: #001a66;
    color: #ffffff;
  }
  
  @media (max-width: 767px) {
    .list-business-button {
      display: none; /* Hide desktop list button on mobile */
    }
  }
  
  /* Refined Dropdown Menu Styles for Avatar Dropdown */
  .dropdown-menu {
    border-radius: 0.75rem; /* More rounded corners */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); /* Subtle shadow */
    padding: 0.5rem 0; /* Adjust overall padding */
    border: none; /* Remove default border */
    background-color: #fff; /* Ensure white background */
    overflow: hidden; /* To make sure border-radius applies to content */
  }
  
  .dropdown-item {
    padding: 0.75rem 1.25rem; /* More generous padding */
    font-size: 1rem; /* Standard font size */
    color: #333; /* Darker text color */
    font-weight: 400; /* Normal font weight */
    transition: background-color 0.15s ease-in-out, color 0.15s ease-in-out;
  }
  
  .dropdown-item:hover,
  .dropdown-item:focus {
    background-color: #f8f9fa; /* Light grey hover background */
    color: #333; /* Keep text color dark on hover */
  }
  
  .dropdown-divider {
    margin: 0.5rem 0; /* Adjust margin for divider */
    border-top: 1px solid #e9ecef; /* Light grey divider */
  }
  
  .dropdown-item-admin {
    background-color: #f0f2f5; /* Light grey background for Admin */
    color: #333; /* Dark text color */
    font-weight: 600; /* Bolder font weight */
    border-top: 1px solid #e9ecef; /* Top border for separation */
    padding-top: 0.75rem; /* Match other items' padding */
    padding-bottom: 0.75rem; /* Match other items' padding */
    display: flex; /* For icon alignment */
    align-items: center;
  }
  
  .dropdown-item-admin:hover,
  .dropdown-item-admin:focus {
    background-color: #e2e6ea; /* Slightly darker grey on hover */
    color: #333;
  }
  
  .dropdown-item-admin .fas.fa-star {
    color: #ffc107; /* Yellow star icon */
  }
  
  /* Profile Dropdown Styles */
.profile-dropdown-container {
    position: relative;
    display: inline-block;
}

.profile-trigger {
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.profile-trigger:hover {
    opacity: 0.8;
}

.profile-avatar-img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e5e5e7;
    transition: border-color 0.2s ease;
}

.profile-trigger:hover .profile-avatar-img {
    border-color: #d1d1d6;
}

.profile-dropdown-menu {
    position: absolute;
    top: calc(100% - 10px);
    right: 0;
    width: 160px;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-top: none;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-5px);
    transition: all 0.2s ease;
    z-index: 1000;
    overflow: hidden;
}

.profile-dropdown-menu.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Dropdown Header */
.dropdown-header {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    background: #ffffff;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dropdown-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #e0e0e0;
}

.user-name {
    font-size: 14px;
    font-weight: 500;
    color: #333333;
}

/* Menu Items */
.dropdown-items {
    padding: 4px 0;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    color: #333333;
    text-decoration: none;
    font-size: 13px;
    font-weight: 400;
    transition: background-color 0.15s ease;
    border: none;
    width: 100%;
}

.dropdown-item:hover {
    background-color: #fff;
    color: #000;
    text-decoration: underline;
}

.item-icon {
    width: 14px;
    color: #666666;
    font-size: 12px;
    text-align: center;
}

.dropdown-item span {
    flex: 1;
}

/* 빈 상단 메뉴 항목 스타일 */
.empty-top-item {
    height: 20px !important;
    padding: 0 !important;
    background: transparent !important;
    cursor: default !important;
    pointer-events: none !important;
}

.empty-top-item:hover {
    background: transparent !important;
}

/* Separator */
.dropdown-separator {
    height: 1px;
    background-color: #e8e8e8;
    margin: 4px 0;
    border: none;
}

/* Admin Item Special Styling */
.admin-item {
    background: #f8f9ff;
    color: #333333 !important;
    margin: 0;
    border-radius: 0;
}

.admin-item:hover {
    background: #f0f2ff;
    color: #333333 !important;
}

.admin-item .item-icon {
    color: #ffc107 !important;
    font-size: 13px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .profile-dropdown-menu {
        width: 150px;
        right: -5px;
    }
    
    .dropdown-header {
        padding: 10px 12px;
    }
    
    .dropdown-item {
        padding: 6px 12px;
        font-size: 12px;
    }
    
    .user-name {
        font-size: 13px;
    }
    
    .dropdown-user-avatar {
        width: 28px;
        height: 28px;
    }
}

/* Click outside to close dropdown */
.dropdown-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 999;
    background: transparent;
    display: none;
}

.dropdown-backdrop.active {
    display: block;
}

/* Bootstrap dropdown override */
.dropdown-menu.show {
    position: absolute !important;
    top: calc(100% - 1px) !important;
    right: 0 !important;
    left: auto !important;
    width: 160px !important;
    background: #ffffff !important;
    border-top: 0px solid #e0e0e0 !important;    
    border-left: 1px solid #e0e0e0 !important;
    border-right: 1px solid #e0e0e0 !important;
    border-bottom: 1px solid #e0e0e0 !important;
    border-radius: 0 0 8px 8px !important;
    box-shadow: 0 13px 12px 0px rgba(0, 0, 0, 0.15) !important;
    transform: translateY(0) !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
}

.dropdown-menu.show::before {
    display: none !important;
}

.dropdown-menu.show::after {
    display: none !important;
}


.main-nav {
  display: flex; /* Default to flex for desktop */
  align-items: center;
  gap: 24px;
  font-size: 15px; /* Slightly larger */
  font-weight: 500; /* Semi-bold for menu links */
  margin-left: 30px; /* Space between logo and nav */
}

.nav-link {
  text-decoration: none;
  color: #000; /* Black color */
  transition: color 0.2s ease, text-decoration 0.2s ease; /* Add text-decoration to transition */
  font-weight: 600; /* Bolder for main nav links */
}

.nav-link:hover {
  color: #000; /* Darker grey on hover */
  text-decoration: underline; /* Underline on hover */
  text-underline-offset: 4px; /* Offset underline */
}


@media (max-width: 767px) {
  .main-nav {
    display: none; /* Hide desktop nav on mobile */
  }