
/* ==========================
   NAVIGATION
   ========================== */
.nav-wrapper {
  background-color: rgba(0, 0, 50, 0.65); /* dark blue with transparency */
}


#about, #map-area {
    display: block !important;
    opacity: 1 !important;
    transform: none !important;
}

.map-instructions {
  text-align: center;
  font-size: 1.1rem;
  margin: 15px 0;
  color: white;
}

.map-instructions .camera-icon {
  font-size: 1.5rem;
  margin-right: 6px;
}

/* ==========================
   MAP BUTTONS & PHOTOS LEGEND
   ========================== */

/* Shared base styles */
.map-button, .photos-legend {
  background: rgba(255, 255, 255, 0.9);
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-size: 0.9rem;
  color: #333;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  border: none;
  display: inline-block;
  position: absolute;
  z-index: 1000;
  white-space: nowrap;
  transition: all 0.2s ease;
}

/* ==========================
   DESKTOP POSITION
   ========================== */
.map-button {
  top: 80px;        /* adjust according to your zoom controls */
  left: 10px;
}

.photos-legend {
  top: 130px;       /* map-button top + spacing */
  left: 10px;
}

/* ==========================
   TABLET POSITION (<=768px)
   ========================== */
/* MOBILE: stack map buttons at bottom */
@media (max-width: 768px) {
  #map-wrapper,
  #map {
    height: 50vh !important;  /* keep map smaller on mobile */
    max-height: 600px !important;
  }

  .map-button, .photos-legend {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    top: auto !important;           /* remove top position */
    font-size: 0.75rem !important;
    padding: 0.4rem 0.7rem !important;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3) !important;
    white-space: nowrap !important;
  }

  /* stack them from bottom up */
  .photos-legend {
    bottom: 10px !important;  /* bottom-most button */
  }

  .map-button {
    bottom: 50px !important;  /* above the photos-legend */
  }
}

/* ==========================
   MOBILE POSITION (<=480px)
   Stack buttons at bottom
   ========================== */
@media (max-width: 480px) {
  .map-button, .photos-legend {
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    padding: 0.35rem 0.5rem;
  }

  /* bottom stacking */
  .photos-legend {
    bottom: 10px;
    top: auto;
  }

  .map-button {
    bottom: 50px;
    top: auto;
  }
}

/* ==========================
   MAP WRAPPER & MAP
   ========================== */
#map-wrapper {
  position: relative;
  width: 90%;             /* desktop smaller than viewport */
  max-width: 1170px;
  height: 700px;          /* desktop height */
  margin: 0 auto;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(0,0,0,0.1);
  box-sizing: border-box;
}

#map {
  width: 100%;
  height: 100%;
  cursor: grab;
}

#map:active {
  cursor: grabbing;
}

/* Tooltip styles */
.leaflet-tooltip {
  font-size: 16px;
  font-weight: bold;
  color: #222;
  background: rgba(255,255,255,0.9);
  border: none;
  padding: 6px 10px;
  border-radius: 6px;
}

/* Hover on interactive map elements */
.leaflet-interactive:hover {
  stroke: #fff;
  stroke-width: 2;
  filter: drop-shadow(0 0 4px #00e1ff);
}

/* ==========================
   MAP BUTTONS & PHOTOS LEGEND
   ========================== */
.map-button, .photos-legend {
  background: rgba(255,255,255,0.9);
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-size: 0.9rem;
  color: #333;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  border: none;
  display: inline-block;
  position: absolute;
  z-index: 1000;
  white-space: nowrap;
  transition: all 0.2s ease;
}

/* Desktop positions */
.map-button {
  top: 80px;
  left: 20px;
}

.photos-legend {
  top: 140px;
  left: 20px;
}

/* ==========================
   RESPONSIVE ADJUSTMENTS
   ========================== */
@media (max-width: 991px) {
  #map-wrapper, #map {
    height: 50vh;
    max-height: 600px;
  }
}

@media (max-width: 768px) {
  /* Stack buttons above bottom, centered */
  .map-button, .photos-legend {
    left: 50%;
    transform: translateX(-50%);
    top: auto;
    font-size: 0.8rem;
    padding: 0.4rem 0.6rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  }

  .map-button {
    bottom: 60px;
  }

  .photos-legend {
    bottom: 10px;
  }
}

@media (max-width: 480px) {
  .map-button, .photos-legend {
    font-size: 0.75rem;
    padding: 0.35rem 0.5rem;
  }

  .map-button {
    bottom: 55px;
  }

  .photos-legend {
    bottom: 10px;
  }
}

/* ==========================
   POI PANEL
   ========================== */
#poi-panel {
  width: 80%;
  max-width: 1000px;
  background: #f8f5ff;
  color: #1a1a1a;
  border-radius: 12px;
  margin: 20px auto;
  padding: 20px;
  display: none;
  opacity: 0;
  transition: all 0.4s ease;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

#poi-panel.open {
  display: block;
  opacity: 1;
}

#poi-panel .poi-header {
  margin-bottom: 15px;
  position: relative;
}

#poi-panel #close-panel {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 24px;
  background: none;
  border: none;
  cursor: pointer;
}

/* Gallery inside panel */
#poi-panel #poi-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 16px;
  margin-top: 20px;
  opacity: 0;
  transition: opacity 0.5s ease;
}

#poi-panel.open #poi-gallery {
  opacity: 1;
}

#poi-panel #poi-gallery img,
#poi-panel #poi-gallery video {
  width: 100%;
  height: 300px;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  transition: transform 0.3s ease;
}

#poi-panel #poi-gallery img:hover,
#poi-panel #poi-gallery video:hover {
  transform: scale(1.05);
}

/* Mobile / tablet POI adjustments */
@media (max-width: 991px) {
  #poi-panel {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    max-height: 90vh;
    border-radius: 12px 12px 0 0;
    display: flex;
    flex-direction: column;
    padding: 0;
    transform: translateY(100%);
    transition: transform 0.3s ease, opacity 0.3s ease;
    z-index: 2000;
    background: #fff;
    opacity: 0;
    overflow: visible;
  }

  #poi-panel.open {
    transform: translateY(0);
    opacity: 1;
  }

  #poi-panel .poi-header {
    flex-shrink: 0;
    margin-bottom: 0;
    padding: 15px;
  }

  #poi-panel #poi-gallery {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    max-height: calc(100vh - 80px);
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 15px;
  }

  #poi-panel #poi-gallery img,
  #poi-panel #poi-gallery video {
    width: 100%;
    height: auto;
    max-height: 250px;
  }
}

@media (max-width: 480px) {
  #poi-panel {
    padding: 10px;
  }

  #poi-panel #poi-gallery img,
  #poi-panel #poi-gallery video {
    max-height: 200px;
  }
}

/* ==========================
   HERO BUTTONS
   ========================== */
.intro-buttons a.btn-outline {
  display: inline-block !important;
  padding: 0.75rem 2rem !important;
  border: 2px solid #fff !important;
  background: transparent !important;
  color: #fff;
  font-size: 1.1rem;
  font-weight: 500;
  border-radius: 30px;
  text-transform: uppercase;
  transition: all 0.3s ease;
  cursor: pointer;
  text-align: center;
}

.intro-buttons a.btn-outline:hover {
  background: rgba(255, 255, 255, 0.15);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

.intro-buttons a.btn-outline:active {
  background: rgba(255, 255, 255, 0.25);
  box-shadow: inset 0 0 6px rgba(255, 255, 255, 0.9);
}

/* ==========================
   SERVICES & INDUSTRIES
   ========================== */
#services .service-items p,
#industries .industry-items p {
  font-size: 1.2rem;
  line-height: 1.6;
  margin: 0.5rem 0 1rem;
}

#services .row {
  margin-bottom: 1.2rem;
}

.industry-video {
  width: 100%;
  border-radius: 8px;
  cursor: pointer;
  margin-bottom: 8px;
}

/* ==========================
   MOBILE RESPONSIVE
   ========================== */

@media (max-width: 991px) {
  /* Map scales */
  #map-wrapper,
  #map {
    height: 50vh;
    max-height: 600px;
  }

  #poi-panel {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: auto !important;       /* auto height based on content */
    max-height: 90vh !important;
    border-radius: 12px 12px 0 0 !important;
    display: flex !important;
    flex-direction: column !important;
    padding: 0 !important;
    transform: translateY(100%) !important;
    transition: transform 0.3s ease, opacity 0.3s ease !important;
    z-index: 2000 !important;
    background: #fff !important;
    opacity: 0 !important;
    overflow: visible !important; /* allow inner scroll */
  }

   #poi-panel.open {
     transform: translateY(0) !important;
     opacity: 1 !important;
   }

/* Header stays visible */
  #poi-panel .poi-header {
    flex-shrink: 0 !important;
    margin-bottom: 0px !important;
    padding: 15px !important;
  }


/* Scrollable gallery */
  #poi-panel #poi-gallery {
    flex: 1 !important;
    min-height: 0 !important; /* ⚠️ essential for flex scroll */
    overflow-y: auto !important;
    max-height: calc(100vh - 80px) !important; /* subtract header height */
    -webkit-overflow-scrolling: touch !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    padding: 15px !important;
  }


  /* Panel title & narrative adjustments */
  #poi-panel .poi-header h2 {
    font-size: 1.8rem !important;  /* smaller title */
    margin-bottom: 6px !important;
  }

  #poi-panel .poi-header p {
    font-size: .9rem !important;  /* smaller narrative */
    margin-bottom: 6px !important;  /* reduce white space */
  }

  /* Reduce padding between header and gallery */
  #poi-panel #poi-gallery {
    padding-top: 4px !important;    /* less white space */
    gap: 8px !important;            /* less space between images */
  }

/* Center single image vertically in the panel */
    #poi-panel.single-media #poi-gallery {
      justify-content: center !important;
      align-items: center !important;
    }

  /* Images & videos on mobile */
  #poi-panel #poi-gallery img,
  #poi-panel #poi-gallery video {
    width: 100% !important;
    height: auto !important;
    max-height: 250px !important;
    object-fit: cover !important;
    border-radius: 8px !important;
  }
}

/* Extra small screens (<480px) */
@media (max-width: 480px) {
  #poi-panel {
    padding: 10px;
  }

  #poi-panel #poi-gallery img,
  #poi-panel #poi-gallery video {
    max-height: 200px;
  }
}

#about, #map-area, #contact {
  caret-color: transparent;   /* hides blinking cursor */
  user-select: none;          /* prevents accidental text selection */
}

#about {
  caret-color: transparent; /* hides the blinking text cursor */
  user-select: none;        /* prevents accidental text selection */
}

/* Mobile sidenav and overlay fix for z-index conflicts */
.sidenav {
  position: fixed !important; /* ensure it's not affected by parent positioning */
  z-index: 5000 !important;   /* high enough to be above canvas, map, or panels */
  background-color: #453c3c !important;
  
}

.sidenav li a {
  color: #ffffff !important;
}
  
.sidenav-overlay {
  z-index: 4999 !important;   /* sits just below the menu */
 
}

canvas#spiral-buffer-kingdom {
  pointer-events: none; /* allows clicks to pass through */
}


/* ==========================
   NAVIGATION
   ========================== */
.nav-wrapper {
  background-color: rgba(0, 0, 50, 0.65); /* dark blue with transparency */
}


#about, #map-area {
    display: block !important;
    opacity: 1 !important;
    transform: none !important;
}

.map-instructions {
  text-align: center;
  font-size: 1.1rem;
  margin: 15px 0;
  color: white;
}

.map-instructions .camera-icon {
  font-size: 1.5rem;
  margin-right: 6px;
}

/* Shared button/legend styles */
.map-button, .photos-legend {
  background: rgba(255,255,255,0.9);
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 0.9rem;
  color: #333;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  border: none;
  display: inline-block;
  position: absolute;
  left: 10px;
  z-index: 1000;
  white-space: nowrap;
}

/* Shared button/legend styles */
.map-button, .photos-legend {
  background: rgba(255,255,255,0.9);
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-size: 0.9rem;
  color: #333;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  border: none;
  display: inline-block;
  position: absolute;
  left: 10px;
  z-index: 1000;
  white-space: nowrap;
}

/* Desktop offsets (zoom controls ~50px) */
.map-button {
  top: 80px; /* zoom control height + 10px margin */
}

.photos-legend {
  top: calc(85px + 1.5em + 20px); /* map-button top + button height + spacing */
}

/* Tablet adjustments */
@media (max-width: 768px) {
  .map-button, .photos-legend {
    font-size: 0.8rem;
    padding: 0.4rem 0.6rem;
    left: 8px;
  }

  .map-button {
    top: 55px; /* zoom control smaller on tablet if needed */
  }

  .photos-legend {
    top: calc(55px + 1.4em + 8px);
  }
}

/* Mobile adjustments */
@media (max-width: 480px) {
  .map-button, .photos-legend {
    font-size: 0.75rem;
    padding: 0.35rem 0.5rem;
    left: 5px;
  }

  .map-button {
    top: 75px; /* adjust for mobile zoom control */
  }

  .photos-legend {
    top: calc(75px + 1.6em + 10px); /* more spacing */
  }
}
/* ==========================
   MAP WRAPPER & MAP
   ========================== */
#map-wrapper {
  position: relative;
  width: 100%;
  max-width: 1170px;
  height: 800px;          /* desktop height */
  margin: 0 auto;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(0,0,0,0.1);
}

#map {
  width: 100%;
  height: 800px;          /* desktop height */
  cursor: grab;
}

#map:active {
  cursor: grabbing;
}

/* Tooltip styles */
.leaflet-tooltip {
  font-size: 16px;
  font-weight: bold;
  color: #222;
  background: rgba(255,255,255,0.9);
  border: none;
  padding: 6px 10px;
  border-radius: 6px;
}

/* Hover on interactive map elements */
.leaflet-interactive:hover {
  stroke: #fff;
  stroke-width: 2;
  filter: drop-shadow(0 0 4px #00e1ff);
}


/* ==========================
   POI PANEL
   ========================== */
#poi-panel {
  width: 80%;
  max-width: 1000px;
  background: #f8f5ff;
  color: #1a1a1a;
  border-radius: 12px;
  margin: 20px auto;
  padding: 20px;
  display: none;
  transition: all 0.4s ease;
  opacity: 0;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

#poi-panel.open {
  display: block;
  opacity: 1;
}

/* Header and close button */
#poi-panel .poi-header {
  margin-bottom: 15px;
  position: relative;
}

#poi-panel #close-panel {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 24px;
  background: none;
  border: none;
  cursor: pointer;
}

/* ==========================
   GALLERY
   ========================== */
#poi-panel #poi-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 16px;
  margin-top: 20px;
  opacity: 0;
  transition: opacity 0.5s ease;
}

#poi-panel.open #poi-gallery {
  opacity: 1;
}

/* Images & videos */
#poi-panel #poi-gallery img,
#poi-panel #poi-gallery video {
  width: 100%;
  height: 300px;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  transition: transform 0.3s ease;
}

#poi-panel #poi-gallery img:hover,
#poi-panel #poi-gallery video:hover {
  transform: scale(1.05);
}

/* Bottom panel overrides */
#poi-bottom-panel #poi-content #poi-gallery img,
#poi-bottom-panel #poi-content #poi-gallery video {
  width: 100% !important;
  max-height: 400px !important;
  object-fit: cover !important;
  border-radius: 6px !important;
}

/* ==========================
   HERO BUTTONS
   ========================== */
.intro-buttons a.btn-outline {
  display: inline-block !important;
  padding: 0.75rem 2rem !important;
  border: 2px solid #fff !important;
  background: transparent !important;
  color: #fff;
  font-size: 1.1rem;
  font-weight: 500;
  border-radius: 30px;
  text-transform: uppercase;
  transition: all 0.3s ease;
  cursor: pointer;
  text-align: center;
}

.intro-buttons a.btn-outline:hover {
  background: rgba(255, 255, 255, 0.15);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

.intro-buttons a.btn-outline:active {
  background: rgba(255, 255, 255, 0.25);
  box-shadow: inset 0 0 6px rgba(255, 255, 255, 0.9);
}

/* ==========================
   SERVICES & INDUSTRIES
   ========================== */
#services .service-items p,
#industries .industry-items p {
  font-size: 1.2rem;
  line-height: 1.6;
  margin: 0.5rem 0 1rem;
}

#services .row {
  margin-bottom: 1.2rem;
}

.industry-video {
  width: 100%;
  border-radius: 8px;
  cursor: pointer;
  margin-bottom: 8px;
}

/* ==========================
   MOBILE RESPONSIVE
   ========================== */

@media (max-width: 991px) {
  /* Map scales */
  #map-wrapper,
  #map {
    height: 50vh;
    max-height: 600px;
  }

  #poi-panel {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: auto !important;       /* auto height based on content */
    max-height: 90vh !important;
    border-radius: 12px 12px 0 0 !important;
    display: flex !important;
    flex-direction: column !important;
    padding: 0 !important;
    transform: translateY(100%) !important;
    transition: transform 0.3s ease, opacity 0.3s ease !important;
    z-index: 2000 !important;
    background: #fff !important;
    opacity: 0 !important;
    overflow: visible !important; /* allow inner scroll */
  }

   #poi-panel.open {
     transform: translateY(0) !important;
     opacity: 1 !important;
   }

/* Header stays visible */
  #poi-panel .poi-header {
    flex-shrink: 0 !important;
    margin-bottom: 0px !important;
    padding: 15px !important;
  }


/* Scrollable gallery */
  #poi-panel #poi-gallery {
    flex: 1 !important;
    min-height: 0 !important; /* ⚠️ essential for flex scroll */
    overflow-y: auto !important;
    max-height: calc(100vh - 80px) !important; /* subtract header height */
    -webkit-overflow-scrolling: touch !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    padding: 15px !important;
  }


  /* Panel title & narrative adjustments */
  #poi-panel .poi-header h2 {
    font-size: 1.8rem !important;  /* smaller title */
    margin-bottom: 6px !important;
  }

  #poi-panel .poi-header p {
    font-size: .9rem !important;  /* smaller narrative */
    margin-bottom: 6px !important;  /* reduce white space */
  }

  /* Reduce padding between header and gallery */
  #poi-panel #poi-gallery {
    padding-top: 4px !important;    /* less white space */
    gap: 8px !important;            /* less space between images */
  }

/* Center single image vertically in the panel */
    #poi-panel.single-media #poi-gallery {
      justify-content: center !important;
      align-items: center !important;
    }

  /* Images & videos on mobile */
  #poi-panel #poi-gallery img,
  #poi-panel #poi-gallery video {
    width: 100% !important;
    height: auto !important;
    max-height: 250px !important;
    object-fit: cover !important;
    border-radius: 8px !important;
  }
}

/* Extra small screens (<480px) */
@media (max-width: 480px) {
  #poi-panel {
    padding: 10px;
  }

  #poi-panel #poi-gallery img,
  #poi-panel #poi-gallery video {
    max-height: 200px;
  }
}

#about, #map-area, #contact {
  caret-color: transparent;   /* hides blinking cursor */
  user-select: none;          /* prevents accidental text selection */
}

#about {
  caret-color: transparent; /* hides the blinking text cursor */
  user-select: none;        /* prevents accidental text selection */
}

/* Mobile sidenav and overlay fix for z-index conflicts */
.sidenav {
  position: fixed !important; /* ensure it's not affected by parent positioning */
  z-index: 5000 !important;   /* high enough to be above canvas, map, or panels */
  background-color: #453c3c !important;
  
}

.sidenav li a {
  color: #ffffff !important;
}
  
.sidenav-overlay {
  z-index: 4999 !important;   /* sits just below the menu */
 
}

canvas#spiral-buffer-kingdom {
  pointer-events: none; /* allows clicks to pass through */
}

/* Force full viewport width and prevent horizontal scroll */
html, body {
  max-width: 100%;
  overflow-x: hidden !important;
  padding: 0;
  margin: 0;
}

/* Ensure map wrapper and map don’t overflow */
#map-wrapper, #map {
  width: 100% !important;
  box-sizing: border-box !important;
}

/* Canvas full width fix */
canvas#spiral-buffer-kingdom {
  width: 100% !important;
  max-width: 100% !important;
  display: block;
}

/* Optional: POI bottom panel fix */
#poi-bottom-panel, #poi-panel {
  width: 100% !important;
  box-sizing: border-box !important;
}


