/* ==========================================================================
   Shared header & footer styles for pages that do not load styles.css
   (the Zanzibar Activities section). Extracted from styles.css — keep in step.
   ========================================================================== */
/* Fallbacks; real values come from /css/theme.css */
:root { --transition: all .35s cubic-bezier(.4,0,.2,1); --white: #fff; --earth: #1A0E02; --gold: #C8872A; --gold-light: #E5A84A; --ivory: #F7F0E3; --cream: #EDE4CF; --text: #2B1A06; --font-body: 'Jost', system-ui, sans-serif; }
.util-bar, .navbar, .footer { font-family: var(--font-body); box-sizing: border-box; }
.util-bar *, .navbar *, .footer *, .util-bar *::before, .navbar *::before { box-sizing: border-box; }
.navbar ul, .footer ul { margin: 0; padding: 0; list-style: none; }
.navbar a, .footer a, .util-bar a { text-decoration: none; }
.navbar p, .footer p { margin: 0; }
.navbar img, .footer img { max-width: 100%; }
.util-bar .container, .navbar .container, .footer .container { max-width: 1260px; margin: 0 auto; padding: 0 24px; }
.footer p { color: inherit; line-height: 1.8; }
.footer-col .footer-title { font-family: var(--font-body); }
.whatsapp-btn { box-sizing: border-box; }
.scroll-top { border: 0; font-family: var(--font-body); }
/* ─── TOP BAR ─── */
.util-bar {
  background: var(--earth);
  padding: 8px 0;
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  color: rgba(247,240,227,0.72);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.util-bar .container { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.util-side { display: flex; align-items: center; gap: 20px; }
.util-item { display: flex; align-items: center; gap: 6px; font-size: .72rem; color: rgba(247,240,227,.75); }
.util-item a { color: rgba(247,240,227,.82); transition: color .2s; }
.util-item a:hover { color: var(--gold-light); }
.util-divider { width: 1px; height: 13px; background: rgba(255,255,255,.14); }
.util-wa {
  display: inline-flex; align-items: center; gap: 6px;
  background: #25D366; color: #fff !important;
  padding: 4px 12px; border-radius: 3px;
  font-size: .7rem; font-weight: 600; letter-spacing: .04em;
  text-decoration: none; transition: background .2s;
}
.util-wa:hover { background: #1aad54; }
.util-ta {
  display: inline-flex; align-items: center; gap: 5px;
  border: 1px solid rgba(255,255,255,.18); border-radius: 3px;
  padding: 3px 10px; font-size: .7rem;
  color: rgba(247,240,227,.88) !important; text-decoration: none; transition: border-color .2s;
}
.util-ta:hover { border-color: var(--gold); color: var(--gold-light) !important; }
/* Legacy compat */
.topbar { display: none; }

/* ═══ MAIN NAVIGATION (Altezza-inspired) ═══ */
.navbar {
  position: sticky;
  top: 0; z-index: 1000;
  background: #fff;
  border-bottom: 1px solid rgba(200,135,42,.1);
  transition: box-shadow .3s;
}
.navbar.scrolled { box-shadow: 0 2px 24px rgba(26,14,2,.1); }
.navbar > .container {
  display: flex; align-items: center;
  justify-content: space-between; height: 72px;
}
.nav-logo img { height: 52px; width: auto; }
.nav-menu { display: flex; align-items: center; gap: 0; list-style: none; }
.nav-item { position: static; }

.nav-link {
  display: flex; align-items: center; gap: 5px;
  padding: 0 15px; height: 72px; white-space: nowrap;
  font-size: .79rem; font-weight: 500; letter-spacing: .06em;
  color: var(--text); text-transform: uppercase;
  border-bottom: 3px solid transparent; margin-bottom: -3px;
  transition: color .2s, border-color .2s;
}
.nav-link:hover { color: var(--gold); border-bottom-color: var(--gold); }
.nav-link.active { color: var(--gold); border-bottom-color: var(--gold); }
.nav-caret {
  display: inline-block; width: 0; height: 0;
  border-left: 4px solid transparent; border-right: 4px solid transparent;
  border-top: 5px solid currentColor; margin-left: 1px;
  transition: transform .25s;
}
.nav-item:hover > .nav-link .nav-caret { transform: rotate(180deg); }
.nav-enquire-btn {
  display: inline-flex; align-items: center; margin-left: 10px;
  background: var(--gold); color: #fff !important;
  padding: 10px 22px; border-radius: 3px;
  font-size: .79rem; font-weight: 600; letter-spacing: .07em;
  text-transform: uppercase; text-decoration: none;
  transition: background .2s; white-space: nowrap;
  border-bottom: none !important;
}
.nav-enquire-btn:hover { background: var(--earth) !important; }

/* ── Simple dropdown (fallback for non-mega items) ── */
.nav-dropdown {
  position: absolute; top: 100%; left: 0;
  min-width: 220px; background: #fff;
  border-top: 3px solid var(--gold);
  box-shadow: 0 8px 32px rgba(26,14,2,.12);
  opacity: 0; pointer-events: none; transform: translateY(-6px);
  transition: opacity .22s, transform .22s; z-index: 997;
}
.nav-item:hover > .nav-dropdown { opacity: 1; pointer-events: auto; transform: translateY(0); }
.nav-dropdown a {
  display: block; padding: 11px 20px;
  font-size: .82rem; font-weight: 500; color: var(--text);
  border-bottom: 1px solid rgba(200,135,42,.08); transition: all .18s;
}
.nav-dropdown a:last-child { border-bottom: none; }
.nav-dropdown a:hover { color: var(--gold); background: var(--ivory); padding-left: 26px; }

/* ══ FULL-WIDTH MEGA PANEL (Altezza style) ══ */
.mega-panel {
  position: absolute;
  top: 100%; left: 0; right: 0; width: 100%;
  background: #fff;
  border-top: 3px solid var(--gold);
  box-shadow: 0 16px 52px rgba(26,14,2,.14);
  opacity: 0; pointer-events: none; transform: translateY(-6px);
  transition: opacity .25s, transform .25s; z-index: 997;
}
.nav-item:hover > .mega-panel { opacity: 1; pointer-events: auto; transform: translateY(0); }
.mega-panel-inner {
  max-width: 1260px; margin: 0 auto; padding: 0 24px;
  display: grid; align-items: start;
}
.mega-panel-inner.layout-tours {
  grid-template-columns: 1fr 1fr 180px 260px;
  gap: 0; padding-top: 32px; padding-bottom: 32px;
}
.mega-panel-inner.layout-destinations {
  grid-template-columns: 1fr 1fr 1fr 240px;
  gap: 0; padding-top: 32px; padding-bottom: 32px;
}
.mega-panel-inner.layout-resources {
  grid-template-columns: 1fr 1fr;
  gap: 0; padding-top: 28px; padding-bottom: 28px;
}

/* Mega column */
.mc {
  padding: 0 28px 0 0;
  border-right: 1px solid rgba(200,135,42,.1);
}
.mc + .mc { padding-left: 28px; }
.mc:last-child { border-right: none; }
.mc-title {
  font-size: .63rem; font-weight: 700; letter-spacing: .18em;
  text-transform: uppercase; color: var(--gold);
  margin-bottom: 14px; padding-bottom: 10px;
  border-bottom: 1px solid rgba(200,135,42,.15);
}
.mc-link {
  display: block; padding: 7px 0; text-decoration: none;
  border-bottom: 1px solid rgba(200,135,42,.06); transition: all .18s;
}
.mc-link:last-of-type { border-bottom: none; }
.mc-link-name {
  font-size: .84rem; font-weight: 500; color: var(--text);
  transition: all .18s; display: flex; align-items: center; gap: 0;
}
.mc-link-name::after { content: ''; transition: all .18s; }
.mc-link-desc { font-size: .73rem; color: #aaa; margin-top: 2px; line-height: 1.35; }
.mc-link:hover .mc-link-name { color: var(--gold); padding-left: 5px; }

/* Mega featured panel */
.mc-feat {
  padding-left: 28px; border-right: none !important;
  display: flex; flex-direction: column;
}
.mc-feat-img {
  width: 100%; height: 180px; object-fit: cover;
  border-radius: 8px; display: block; margin-bottom: 14px;
}
.mc-feat-eyebrow {
  font-size: .62rem; font-weight: 700; letter-spacing: .16em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 6px;
}
.mc-feat-title { font-size: .95rem; font-weight: 700; color: var(--earth); margin-bottom: 12px; line-height: 1.3; }
.mc-feat-cta {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--earth); color: #fff; padding: 9px 16px;
  border-radius: 3px; font-size: .76rem; font-weight: 600;
  letter-spacing: .05em; text-transform: uppercase;
  text-decoration: none; transition: background .2s; width: fit-content;
}
.mc-feat-cta:hover { background: var(--gold); }

/* Hamburger */
.hamburger {
  display: none; flex-direction: column; gap: 5px; padding: 6px; cursor: pointer;
}
.hamburger span {
  display: block; width: 24px; height: 2px;
  background: var(--earth); transition: var(--transition);
}


.footer { background: var(--earth); color: rgba(247,240,227,0.75); }
.footer-top {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.2fr;
  gap: 50px;
  padding: 70px 0 50px;
}
.footer-brand img { height: 50px; margin-bottom: 20px; filter: brightness(0) invert(1); }
.footer-brand p { font-size: 0.85rem; line-height: 1.8; max-width: 280px; }
.footer-social { display: flex; gap: 12px; margin-top: 24px; }
.footer-social a {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(247,240,227,0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(247,240,227,0.7);
  transition: var(--transition);
}
.footer-social a:hover { background: var(--gold); border-color: var(--gold); color: var(--white); }
.footer-col .footer-title { color: var(--ivory); font-size: 1rem; margin-bottom: 22px; font-family: var(--font-body); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.78rem; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul li a { font-size: 0.85rem; transition: var(--transition); color: inherit; text-decoration: none; }
.footer-col ul li a:hover { color: var(--gold-light); padding-left: 6px; }
.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 0.85rem;
}
.footer-contact-item span:first-child { font-size: 1rem; flex-shrink: 0; color: var(--gold); }
.footer-contact-item a { color: inherit; text-decoration: none; }
.footer-contact-item a:hover { color: var(--gold-light); }
.footer-bottom {
  border-top: 1px solid rgba(247,240,227,0.1);
  padding: 22px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
  flex-wrap: wrap;
  gap: 10px;
  text-align: center;
}
.footer-bottom a { color: var(--gold-light); }
.footer-bottom a:hover { text-decoration: underline; }

/* ─── WHATSAPP BUTTON ─── */
.whatsapp-btn {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 58px;
  height: 58px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 24px rgba(37,211,102,0.45);
  z-index: 999;
  transition: var(--transition);
  text-decoration: none;
}
.whatsapp-btn:hover { transform: scale(1.1); background: #20BD5B; }
.whatsapp-btn svg { width: 28px; height: 28px; fill: var(--white); }

/* ─── SCROLL TO TOP ─── */
.scroll-top {
  position: fixed;
  bottom: 98px;
  right: 28px;
  width: 44px;
  height: 44px;
  background: var(--earth);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 998;
  opacity: 0;
  pointer-events: none;
  transition: var(--transition);
  font-size: 1.1rem;
}
.scroll-top.visible { opacity: 1; pointer-events: auto; }
.scroll-top:hover { background: var(--gold); }


@media (max-width: 1024px) {
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 768px) {
    .nav-menu, .nav-enquire-btn { display: none; }
  .hamburger { display: flex; }
  .navbar { position: static; }
  .navbar { position: sticky !important; top: 0; }
  .nav-menu.mobile-open {
    display: flex; flex-direction: column;
    position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; padding: 8px 0 24px;
    box-shadow: 0 20px 50px rgba(26,14,2,.2);
    align-items: stretch; gap: 0;
    max-height: calc(100vh - 72px); overflow-y: auto; z-index: 999;
  }
  .nav-link { padding: 13px 22px; justify-content: space-between; border-bottom: 1px solid var(--cream); height: auto; border-top: none; margin: 0; }
  .mega-panel, .nav-dropdown { display: none; position: static; box-shadow: none; border-top: none; background: var(--ivory); opacity: 1; pointer-events: auto; transform: none; width: auto; }
  .nav-item.open > .mega-panel, .nav-item.open > .nav-dropdown { display: block; }
  .mc { border-right: none; padding: 12px 22px; }
  .mc + .mc { padding-left: 22px; border-top: 1px solid var(--cream); }
  .mc-feat { display: none; }
  .mega-panel-inner { grid-template-columns: 1fr !important; padding: 0 !important; }
  .footer-top { grid-template-columns: 1fr; gap: 0; padding: 44px 0 8px; }
  .footer-brand { padding-bottom: 30px; margin-bottom: 6px; border-bottom: 1px solid rgba(247,240,227,.14); }
  .footer-brand p { max-width: none; }
  .footer-col { border-bottom: 1px solid rgba(247,240,227,.14); }
  .footer-col .footer-title {
    margin: 0; padding: 18px 4px 18px 0;
    display: flex; align-items: center; justify-content: space-between;
    cursor: pointer;
  }
  .footer-col .footer-title::after {
    content: '+'; font-size: 1.1rem; font-weight: 400; color: var(--gold);
    margin-left: 12px; flex-shrink: 0;
  }
  .footer-col.open .footer-title::after { content: '\2212'; }
  .footer-col .footer-title ~ * { display: none; }
  .footer-col.open .footer-title ~ * { display: block; }
  .footer-col.open .footer-title { padding-bottom: 4px; }
  .footer-col.open ul,
  .footer-col.open .footer-contact-item:first-of-type { margin-top: 4px; }
  .footer-col ul { padding-bottom: 20px; }
  .footer-col > div:last-of-type { padding-bottom: 24px; }
  .footer-bottom { flex-direction: column; text-align: center; padding: 20px 0 90px; }
  .util-bar .container { flex-direction: column; text-align: center; gap: 8px; }
}

/* Tablet & phone: switch to the hamburger menu below 1024px so the menu never overflows */
@media (max-width: 1024px) {
  .nav-menu { display: none; }
  .hamburger { display: flex; }
  .navbar { position: sticky !important; top: 0; }
  .nav-menu.mobile-open {
    display: flex; flex-direction: column;
    position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; padding: 8px 0 24px;
    box-shadow: 0 20px 50px rgba(26,14,2,.2);
    align-items: stretch; gap: 0;
    max-height: calc(100vh - 72px); overflow-y: auto; z-index: 999;
  }
  .nav-link { padding: 13px 22px; justify-content: space-between; border-bottom: 1px solid var(--cream); height: auto; border-top: none; margin: 0; }
  .mega-panel, .nav-dropdown { display: none; position: static; box-shadow: none; border-top: none; background: var(--ivory); opacity: 1; pointer-events: auto; transform: none; width: auto; border-radius: 0; }
  .nav-item.open > .mega-panel, .nav-item.open > .nav-dropdown { display: block; }
  .mc { border-right: none; padding: 12px 22px; }
  .mc + .mc { padding-left: 22px; border-top: 1px solid var(--cream); }
  .mc-feat { display: none; }
  .mega-panel-inner { grid-template-columns: 1fr !important; padding: 0 !important; }
  .nav-menu.mobile-open .nav-cta { padding: 14px 22px 0; }
  .nav-menu.mobile-open .nav-enquire-btn { display: flex; justify-content: center; margin: 0; padding: 13px 20px; }
  .nav-item.has-mega.open > .nav-link .nav-caret { transform: rotate(180deg); }
  .nav-link::after { display: none; }
}
@media (min-width: 1025px) and (max-width: 1240px) {
  .nav-link { padding: 0 10px; font-size: .74rem; letter-spacing: .05em; }
  .nav-enquire-btn { padding: 10px 16px !important; }
}
.hamburger { border: 0; background: none; }
