/* ============================================================
   navbar-v2.css — Navbar Baru Dream Tours and Travel
   Isolated: semua selector pakai prefix .nb2- atau #nb2-
   Tidak konflik dengan style.css yang sudah ada
   ============================================================ */

/* ── RESET SCOPE ─────────────────────────────────────────────
   Semua style di-scope ke .nb2 sehingga tidak bocor ke luar
   ─────────────────────────────────────────────────────────── */

/* ── CUSTOM PROPERTIES (scoped) ────────────────────────────── */
.nb2 {
  --nb2-navy: var(--navy);
  --nb2-navy-dark: var(--navy-dark);
  --nb2-text: var(--text);
  --nb2-muted: var(--muted);
  --nb2-border: rgba(255, 255, 255, .25);
  --nb2-bg: transparent;
  --nb2-bg-scrolled: rgba(255, 255, 255, .82);
  --nb2-pill-bg: rgba(255, 255, 255, .10);
  --nb2-pill-radius: 50px;
  --nb2-h: 68px;
  /* navbar height */
  --nb2-current-h: var(--nb2-h);
  --nb2-vv-top: 0px;
  --nb2-vv-left: 0px;
  --nb2-vv-width: 100vw;
  --nb2-ff: 'Plus Jakarta Sans', sans-serif;
  --nb2-fh: 'Playfair Display', Georgia, serif;
  --nb2-transition: all .3s cubic-bezier(.4, 0, .2, 1);
}

/* ── BASE NAVBAR ────────────────────────────────────────────── */
.nb2 {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1060;
  /* above everything */
  width: 100%;
  height: var(--nb2-current-h);
  display: flex;
  align-items: center;
  background: var(--nb2-bg);
  border-bottom: 1px solid transparent;
  transition: var(--nb2-transition);
  /* Glass blur — initial state */
  backdrop-filter: blur(0px) saturate(1);
  -webkit-backdrop-filter: blur(0px) saturate(1);
}

/* ── SCROLLED STATE ─────────────────────────────────────────── */
.nb2.nb2--scrolled {
  --nb2-current-h: 60px;
  background: var(--nb2-bg-scrolled);
  backdrop-filter: blur(18px) saturate(1.6);
  -webkit-backdrop-filter: blur(18px) saturate(1.6);
  border-bottom-color: rgba(29, 45, 74, .08);
  box-shadow:
    0 4px 6px -1px rgba(29, 45, 74, .06),
    0 10px 40px -8px rgba(29, 45, 74, .14);
  height: var(--nb2-current-h);
  /* slightly shorter when scrolled */
}

/* Halaman selain home tidak memiliki hero gelap di belakang navbar. */
.nb2.nb2--solid {
  background: var(--nb2-bg-scrolled);
  backdrop-filter: blur(18px) saturate(1.6);
  -webkit-backdrop-filter: blur(18px) saturate(1.6);
  border-bottom-color: rgba(29, 45, 74, .08);
  box-shadow:
    0 4px 6px -1px rgba(29, 45, 74, .06),
    0 10px 40px -8px rgba(29, 45, 74, .14);
}

/* ── INNER CONTAINER ────────────────────────────────────────── */
.nb2__inner {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

/* ── BRAND / LOGO ───────────────────────────────────────────── */
.nb2__brand {
  display: flex;
  align-items: center;
  gap: 0;
  text-decoration: none;
  flex-shrink: 0;
}

.nb2__brand-logo {
  display: block;
  width: auto;
  height: 42px;
  max-width: 154px;
  object-fit: contain;
}

/* Logo putih hanya dipakai saat navbar berada di atas hero home. */
.nb2__brand-logo--white {
  display: none;
}
.nb2.nb2--overlay:not(.nb2--scrolled) .nb2__brand-logo {
  display: none;
}
.nb2.nb2--overlay:not(.nb2--scrolled) .nb2__brand-logo--white {
  display: block;
}

.nb2__brand-name {
  font-family: var(--nb2-fh);
  font-size: 19px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -.3px;
  line-height: 1;
  transition: color .2s;
}

.nb2__brand-name:hover {
  color: var(--gold-light);
}

/* Optional dot accent after brand name */
.nb2__brand-dot {
  width: 6px;
  height: 6px;
  background: #c8952a;
  /* gold */
  border-radius: 50%;
  margin-left: 3px;
  margin-bottom: 12px;
  /* superscript position */
  flex-shrink: 0;
}

/* ── NAV PILL CONTAINER ─────────────────────────────────────── */
.nb2__pill {
  display: flex;
  align-items: center;
  background: var(--nb2-pill-bg);
  border-radius: var(--nb2-pill-radius);
  padding: 5px;
  gap: 2px;
  transition: var(--nb2-transition);
}

.nb2--scrolled .nb2__pill,
.nb2--solid .nb2__pill {
  background: #f0f2f7;
}

/* Scrolled/solid: restore original white theme */
.nb2.nb2--scrolled .nb2__link,
.nb2.nb2--solid .nb2__link {
  color: var(--nb2-muted);
}
.nb2.nb2--scrolled .nb2__link:hover,
.nb2.nb2--solid .nb2__link:hover {
  color: var(--nb2-navy);
  background: rgba(29, 45, 74, .06);
}
.nb2.nb2--scrolled .nb2__link.nb2--active,
.nb2.nb2--solid .nb2__link.nb2--active {
  background: var(--nb2-navy);
  color: #ffffff;
}
.nb2.nb2--scrolled .nb2__link.nb2--active:hover,
.nb2.nb2--solid .nb2__link.nb2--active:hover {
  background: var(--nb2-navy-dark);
  color: #ffffff;
}
.nb2.nb2--scrolled .nb2__drop-arrow,
.nb2.nb2--solid .nb2__drop-arrow {
  color: var(--nb2-muted);
}
.nb2.nb2--scrolled .nb2__brand-name,
.nb2.nb2--solid .nb2__brand-name {
  color: var(--nb2-navy);
}
.nb2.nb2--scrolled .nb2__brand-name:hover,
.nb2.nb2--solid .nb2__brand-name:hover {
  color: var(--nb2-navy-dark);
}
.nb2.nb2--scrolled .nb2__toggle,
.nb2.nb2--solid .nb2__toggle {
  background: #ffffff;
  border-color: rgba(29, 45, 74, .2);
}
.nb2.nb2--scrolled .nb2__toggle:hover,
.nb2.nb2--solid .nb2__toggle:hover {
  background: #f0f2f7;
  border-color: rgba(29, 45, 74, .2);
}
.nb2.nb2--scrolled .nb2__bar,
.nb2.nb2--solid .nb2__bar {
  background: var(--nb2-navy);
}

/* ── NAV ITEMS ──────────────────────────────────────────────── */
.nb2__link {
  font-family: var(--nb2-ff);
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, .82);
  text-decoration: none;
  padding: 8px 18px;
  border-radius: var(--nb2-pill-radius);
  white-space: nowrap;
  transition: var(--nb2-transition);
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  border: none;
  background: none;
  line-height: 1;
}

.nb2__link:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, .10);
}

/* Active/current page */
.nb2__link.nb2--active {
  background: var(--nb2-navy);
  color: #ffffff;
  font-weight: 600;
}

.nb2__link.nb2--active:hover {
  background: var(--nb2-navy-dark);
  color: #ffffff;
}

/* ── DROPDOWN TRIGGER ───────────────────────────────────────── */
.nb2__link--drop {
  padding-right: 14px;
}

.nb2__drop-arrow {
  font-size: 10px;
  color: rgba(255, 255, 255, .65);
  transition: transform .25s ease;
  margin-left: 2px;
  flex-shrink: 0;
}

.nb2__item--dd:hover .nb2__drop-arrow,
.nb2__item--dd.nb2--open .nb2__drop-arrow {
  transform: rotate(180deg);
}

/* ── DROPDOWN MENU ──────────────────────────────────────────── */
.nb2__item--dd {
  position: relative;
}

/* Hover bridge: keeps dropdown open while cursor moves from pill to menu */
.nb2__item--dd::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 14px;
  display: block;
}

.nb2__dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(-6px);
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid rgba(29, 45, 74, .08);
  box-shadow:
    0 4px 6px -1px rgba(29, 45, 74, .06),
    0 20px 48px -8px rgba(29, 45, 74, .18);
  padding: 8px;
  min-width: 200px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s ease, transform .22s ease;
  z-index: 10;
}

/* border-top accent */
.nb2__dropdown::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 16px;
  right: 16px;
  height: 2px;
  background: linear-gradient(90deg, var(--nb2-navy), var(--gold));
  border-radius: 0 0 2px 2px;
}

/* open state */
.nb2__item--dd:hover .nb2__dropdown,
.nb2__item--dd.nb2--open .nb2__dropdown {
  opacity: 1;
  pointer-events: all;
  transform: translateX(-50%) translateY(0);
}

.nb2__dd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  border-radius: 10px;
  font-family: var(--nb2-ff);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--nb2-text);
  text-decoration: none;
  transition: all .18s;
  cursor: pointer;
}

.nb2__dd-item:hover {
  background: #f0f2f7;
  color: var(--nb2-navy);
}

.nb2__dd-item i {
  width: 28px;
  height: 28px;
  background: rgba(29, 45, 74, .07);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--nb2-navy);
  flex-shrink: 0;
  transition: background .18s;
}

.nb2__dd-item:hover i {
  background: rgba(29, 45, 74, .14);
}

/* Dropdown divider */
.nb2__dd-divider {
  height: 1px;
  background: rgba(29, 45, 74, .07);
  margin: 6px 8px;
}

/* Dropdown group label */
.nb2__dd-label {
  font-family: var(--nb2-ff);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--nb2-muted);
  padding: 8px 14px 4px;
}

/* ── MOBILE TOGGLE ──────────────────────────────────────────── */
.nb2__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1.5px solid var(--nb2-border);
  background: rgba(255, 255, 255, .06);
  cursor: pointer;
  flex-shrink: 0;
  transition: var(--nb2-transition);
}

.nb2__toggle:hover {
  background: rgba(255, 255, 255, .14);
  border-color: rgba(255, 255, 255, .4);
}

.nb2__bar {
  display: block;
  width: 18px;
  height: 2px;
  background: #ffffff;
  border-radius: 2px;
  transition: var(--nb2-transition);
}

/* Hamburger → X animation */
.nb2__toggle.nb2--open .nb2__bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nb2__toggle.nb2--open .nb2__bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.nb2__toggle.nb2--open .nb2__bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ── MOBILE NAV DRAWER ──────────────────────────────────────── */
.nb2__drawer {
  display: none;
  /* block only on mobile via media query */
  position: fixed;
  top: var(--nb2-current-h);
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(20px) saturate(1.6);
  -webkit-backdrop-filter: blur(20px) saturate(1.6);
  border-bottom: 1px solid rgba(29, 45, 74, .1);
  box-shadow: 0 16px 40px rgba(29, 45, 74, .12);
  z-index: 1059;
  padding: 12px 20px 20px;
  max-height: calc(100vh - var(--nb2-current-h));
  max-height: calc(100dvh - var(--nb2-current-h));
  overflow-y: auto;
  overscroll-behavior: contain;
  transform: translateY(-8px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}

.nb2__drawer.nb2--open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.nb2__drawer-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: 10px;
  font-family: var(--nb2-ff);
  font-size: 15px;
  font-weight: 500;
  color: var(--nb2-text);
  text-decoration: none;
  border: none;
  background: none;
  width: 100%;
  cursor: pointer;
  transition: background .18s;
}

.nb2__drawer-link:hover,
.nb2__drawer-link.nb2--active {
  background: #f0f2f7;
  color: var(--nb2-navy);
  font-weight: 600;
}

.nb2__drawer-link.nb2--active {
  background: rgba(29, 45, 74, .08);
}

.nb2__drawer-divider {
  height: 1px;
  background: rgba(29, 45, 74, .07);
  margin: 8px 0;
}

/* Sub-links (second level in drawer) */
.nb2__drawer-sub {
  padding-left: 16px;
  display: none;
}

.nb2__drawer-sub.nb2--open {
  display: block;
}

.nb2__drawer-sub-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border-radius: 8px;
  font-family: var(--nb2-ff);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--nb2-muted);
  text-decoration: none;
  transition: all .18s;
}

.nb2__drawer-sub-link:hover {
  background: #f0f2f7;
  color: var(--nb2-navy);
}


/* ── BODY OFFSET ─────────────────────────────────────────────── 
   Tambahkan class .nb2-offset ke <body> atau wrapper utama
   agar konten tidak tertutup navbar fixed
   ─────────────────────────────────────────────────────────── */
.nb2-offset {
  padding-top: 68px;
}

/* ── RESPONSIVE ─────────────────────────────────────────────── */
@media (max-width: 900px) {
  .nb2 {
    --nb2-h: 64px;
    --nb2-current-h: var(--nb2-h);
    position: fixed !important;
    top: 0 !important;
    left: var(--nb2-vv-left);
    right: auto;
    bottom: auto;
    width: var(--nb2-vv-width);
    max-width: var(--nb2-vv-width);
    height: var(--nb2-current-h) !important;
    min-height: var(--nb2-current-h);
    max-height: var(--nb2-current-h);
    overflow: visible;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    transform: translate3d(0, var(--nb2-vv-top), 0);
    -webkit-transform: translate3d(0, var(--nb2-vv-top), 0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    will-change: transform;
    transition: background-color .2s ease, border-color .2s ease, box-shadow .2s ease;
  }

  .nb2.nb2--scrolled {
    --nb2-current-h: var(--nb2-h);
    height: var(--nb2-current-h) !important;
    background: var(--nb2-bg-scrolled);
    backdrop-filter: blur(18px) saturate(1.6);
    -webkit-backdrop-filter: blur(18px) saturate(1.6);
  }

  .nb2-offset {
    padding-top: 64px;
  }

  .nb2__inner {
    height: var(--nb2-current-h);
    min-height: var(--nb2-current-h);
  }

  .nb2__pill {
    display: none !important;
  }

  .nb2__toggle {
    display: flex !important;
    visibility: visible;
    opacity: 1;
    flex: 0 0 40px;
    position: relative;
    z-index: 1;
  }

  .nb2__drawer {
    display: block;
    position: absolute;
    top: 100%;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    max-height: calc(100vh - var(--nb2-current-h) - var(--nb2-vv-top));
    max-height: calc(100dvh - var(--nb2-current-h) - var(--nb2-vv-top));
    /* show drawer slot (visibility via opacity) */
  }
}

@media (max-width: 480px) {
  .nb2__inner {
    padding: 0 16px;
  }

  .nb2__brand-name {
    font-size: 17px;
  }
}
