/* ===== NAVBAR COMPONENT ===== */
bf-navbar {
  display: block;
  width: 100%;
}

.nav-bar {
  width: 100%;
  min-height: 56px;
  background: var(--nav, #f6f0ee);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 18px;
  gap: 14px;
}

/* ===== LEFT SIDE ===== */
.nav-left {
  display: flex;
  align-items: center;
  gap: 22px;
  min-width: 420px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.nav-logo {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  color: var(--red, #F05454);
  font-weight: 900;
}

.nav-brand-text {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: .2px;
  color: #111;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
}

.nav-link {
  text-decoration: none;
  color: #111;
  font-size: 14px;
  font-weight: 500;
  opacity: .85;
  transition: all .15s ease;
}

.nav-link:hover {
  opacity: 1;
}

.nav-link.active {
  color: var(--red, #F05454);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 6px;
}

/* ===== SEARCH BAR ===== */
.nav-center {
  flex: 1;
  display: flex;
  justify-content: center;
}

.nav-search {
  width: min(520px, 55vw);
  height: 34px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border, rgba(0,0,0,.08));
  display: flex;
  align-items: center;
  padding: 0 10px;
  gap: 8px;
  box-shadow: 0 6px 18px rgba(0,0,0,.04);
}

.nav-search-ic {
  color: #7d7d7d;
  display: flex;
}

.nav-search-input {
  border: none;
  outline: none;
  width: 100%;
  font-size: 13px;
  font-family: "Poppins", sans-serif;
}

.nav-filter {
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  color: #666;
  padding: 4px 6px;
  border-radius: 8px;
}

.nav-filter:hover {
  background: rgba(0,0,0,.05);
}

/* ===== RIGHT SIDE ===== */
.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 240px;
  justify-content: flex-end;
}

.nav-right.is-loading {
  visibility: hidden;
}

.nav-guest[hidden],
.nav-auth[hidden] {
  display: none !important;
}

/* ===== WRITE MENU ===== */
.nav-write-wrapper {
  position: relative;
}

.nav-write-btn {
  background: var(--red, #F05454);
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  padding: 8px 18px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  opacity: 1;
}

.nav-write-btn:hover {
  opacity: 0.95;
}

.nav-write-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 180px;
  background: #fff;
  border: 1px solid var(--border, rgba(0,0,0,.08));
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,.10);
  padding: 6px 0;
  z-index: 999;
}

.nav-write-dropdown a {
  display: block;
  width: 100%;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  color: #333;
  text-decoration: none;
}

.nav-write-dropdown a:hover {
  background: #f5f5f5;
}

/* ===== ICON BUTTON ===== */
.nav-icon-btn {
  width: 34px;
  height: 34px;
  border: none;
  background: transparent;
  border-radius: 10px;
  cursor: pointer;
  color: #333;
  display: grid;
  place-items: center;
  transition: background .15s ease;
}

.nav-icon-btn:hover {
  background: rgba(0,0,0,.06);
}

/* ===== AVATAR ===== */
.nav-avatar-wrapper {
  position: relative;
}

.nav-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  overflow: hidden;

  display: flex;
  align-items: center;
  justify-content: center;

  border: 1px solid rgba(0,0,0,.08);
  cursor: pointer;

  transition: opacity .15s ease;
}

.nav-avatar:hover {
  opacity: .85;
}

.nav-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ===== PROFILE DROPDOWN ===== */
.nav-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 190px;
  background: #fff;
  border: 1px solid var(--border, rgba(0,0,0,.08));
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,.10);
  padding: 6px 0;
  z-index: 999;
}

.nav-dropdown[hidden] {
  display: none;
}

.nav-dropdown-name {
  padding: 10px 16px 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text, #222);
}

.nav-dropdown-divider {
  height: 1px;
  background: var(--border, rgba(0,0,0,.08));
  margin: 4px 0;
}

.nav-dropdown-item {
  display: block;
  width: 100%;
  padding: 9px 16px;
  font-size: 13px;
  font-family: "Poppins", sans-serif;
  font-weight: 500;
  color: #333;
  text-decoration: none;
  background: transparent;
  border: none;
  text-align: left;
  cursor: pointer;
  transition: background .12s;
}

.nav-dropdown-item:hover {
  background: #f7f7f7;
}

.nav-signout {
  color: var(--red, #F05454);
}

/* ===== GUEST / AUTH ===== */
.nav-guest {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-auth {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-btn {
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  color: #111;
  padding: 6px 10px;
  display: inline-flex;
  align-items: center;
}

.nav-btn-solid {
  background: var(--red, #F05454);
  color: #fff !important;
  border-radius: 4px;
  padding: 8px 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nav-btn-solid:hover {
  opacity: 0.9;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 980px) {
  .nav-center {
    display: none;
  }

  .nav-left {
    min-width: auto;
  }
}