body {
    background-color: #e0f7fa;
    color: #2c3e50;
    font-family: 'Raleway', sans-serif;
}

h1,
h5,
.card-title {
    font-family: 'Urbanist', sans-serif;
}

.navbar {
    background-color: rgba(176, 214, 255, 0.6);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 999;
}

.navbar-brand,
.nav-link {
    color: #3a2e2e !important;
    transition: color 0.3s;
}

.nav-link:hover {
    color: #f7f7f7 !important;
}

.btn-light {
    box-shadow: 0 0 8px rgba(0, 136, 255, 0.2);
    transition: all 0.3s ease;
  }
  
  .btn-light:hover {
    background-color: #b8e2ff!important;
    box-shadow: 0 0 12px rgba(0, 136, 255, 0.3);
  }

  #theme-toggle {
    color: #3a2e2e;
  }

/*@media (max-width: 576px) {
.modal-body {
    padding: 0 !important;
}
}*/

.osm-banner {
    max-width: 1920px;
    margin: 0 auto;
}

#darkModeToggle {
    background: none;
    border: none;
    font-size: 1.25rem;
    cursor: pointer;
  }

.featured-post {
    position: relative;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    margin-bottom: 0;
    /*margin-top: 30px;*/
    display: flex;
    align-items: center;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.8) !important;
    /*box-shadow: 0 10px 20px rgba(0, 0, 0, 0.8), inset 0 20px 30px rgba(0, 0, 0, 0.8);*/
    z-index: 2;
}

.newest-overlay {
    background: rgba(0, 0, 0, 0.5);
    width: 100%;
    height: 50%;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2rem;
    position: absolute;
    bottom: 0;
    left: 0;
}

.newest-overlay h1.days-count-featured {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 1.5rem;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.7);
}

@media (max-width: 768px) {
    .featured-post {
        min-height: 500px;
        flex-direction: column;
    }

    .newest-overlay {
        width: 100%;
        height: auto;
        padding: 1.5rem;
    }

    .newest-overlay h2 {
        font-size: 2rem;
    }

    .newest-overlay p {
        font-size: 1rem;
    }

    .featured-readmore {
        position: static;
        align-self: flex-start;
        margin-top: 1rem;
    }
}

@media (max-width: 992px) {
    .featured-post {
        min-height: 630px;
        flex-direction: column;
    }
}

.ribbon {
    position: absolute;
    top: 0;
    left: 0;
    background: #dc3545;
    /* Bootstrap danger red or change to match your palette */
    color: white;
    padding: 0.5rem 1rem;
    font-weight: bold;
    font-size: 0.9rem;
    z-index: 10;
    border-bottom-right-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.newest-overlay h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.newest-overlay p {
    font-size: 1.2rem;
}

.featured-readmore {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
}

.featured-tags {
    margin-top: auto;
    padding-top: 1rem;
}

.osm-banner #map {
  height: 300px !important;
  position: relative !important;
}

.offline {
    width: 100%;
    height: 300px;
    border: none;
    /*margin: 0;*/
    display: block;
    pointer-events: none;
    /*filter: grayscale(100%) contrast(1.2);*/
    opacity: 0.4;
}

.live {
    width: 100%;
    height: 300px;
    border: none;
    /*margin: 0;*/
    display: block;
    pointer-events: none;
    z-index: 1;
    position: relative;
}

.osm-banner {
    position: relative;
}

.map {
    z-index: 1;
}

.map-gradient-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30%;
    pointer-events: none;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0) 0%, #e0f7fa 100%);
    z-index: 1000; /* make sure it's above map tiles */
  }

.live-indicator {
    position: absolute;
    top: 20px;
    left: 20px;
    background: rgba(0, 0, 0, 0.6);
    padding: 5px 12px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    box-shadow: 0 0 10px rgba(0, 255, 0, 0.7);
    z-index: 15;
}

.live-indicator::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-right: 8px;
    background-color: limegreen;
    border-radius: 50%;
    box-shadow: 0 0 10px limegreen;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.4);
        opacity: 0.6;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.offline-indicator {
    position: absolute;
    top: 20px;
    left: 20px;
    background: rgba(0, 0, 0, 0.6);
    padding: 5px 12px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    box-shadow: 0 0 10px rgba(128, 128, 128, 0.7);
    z-index: 999;
}

.offline-indicator::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-right: 8px;
    background-color: grey;
    border-radius: 50%;
}

/*.content-section {
  padding: 0;
  }*/

.top-section {
    margin-top: -180px;
}

.card-img-top {
    width: 100%;
    /*height: 200px!important;*/
    aspect-ratio: 4/3;
    object-fit: cover;
    object-position: center;
}

.card {
    border: none;
    margin-bottom: 2rem;
    z-index: 2;
    overflow: hidden;
    position: relative;
    transition: transform 0.3s, box-shadow 0.3s;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.card img {
    transition: transform 0.4s ease;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card:hover img {
    transform: scale(1.1);
}

.post-img-overflow-hidden {
    overflow: hidden;
    position: relative;
    /*border-radius: 10px;*/
}

.card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    padding: 1rem;
    transition: background 0.3s;
}

.card:hover .card-overlay {
    background: rgba(0, 0, 0, 0.7);
}
.wrapper-days-date {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    z-index: 2;
}
.date-card {
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.7);
    color: white;
}
.days-count {
    margin-top: -0.2rem!important;
    font-size: 2rem;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.7);
    color: white;
}

.card-img-container {
    position: relative;
}

.badge {
    margin-right: 0.25rem;
    font-size: 0.7rem;
}

footer {
    background-color: #004c70;
    color: #ffffff;
    padding: 2rem 0;
}

footer a {
    color: #00d4ff;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

.peek-card-container {
    overflow: hidden;
    max-height: 100px;
    transition: max-height 0.5s ease;
    cursor: pointer;
}

.icon-weather img {
    max-width: 80px;
    height: auto;
}

.march-may-text {
    color:#222!important;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.7);
}

.august-october-text {
    color:#222!important;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.7);
}

.november-january-text {
    color: #c8e2e7!important;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.7);
}

.february-text {
    color: #c8e2e7!important;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.7);
}

.card-img-overlay {
    padding: 3rem;
}

.card-img-overlay img {
    max-width: 80px;
    height: auto;
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .card-img-overlay {
        padding: 2rem;
    }

    .card-img-overlay h4,
    .card-img-overlay h5 {
        font-size: 1.1rem;
    }

    .card-img-overlay .display-2 {
        font-size: 2rem;
    }

    .card-img-overlay p {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .card-img-overlay {
        padding: 1rem;
    }

    .card-img-overlay h4,
    .card-img-overlay h5 {
        font-size: 1rem;
    }

    .card-img-overlay .display-2 {
        font-size: 1.5rem;
    }

    .card-img-overlay p {
        font-size: 0.85rem;
    }
}

.february-text {
    color: white;
    text-shadow: 1px 1px 1px rgb(0, 0, 0);
}

@media (min-width: 992px) {

    .weather-card-lg h4,
    .weather-card-lg h5,
    .weather-card-lg p,
    .weather-card-lg .display-2 {
        font-size: 1rem;
    }

    .weather-card-lg .display-2 {
        font-size: 3.1rem;
    }
}

.sticky-sidebar {
    position: sticky;
    top: 1rem;
    height: fit-content;
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
    .sticky-sidebar {
        display: none;
    }
}

.video-card {
    overflow: hidden;
    max-height: 350px;
    transition: max-height 0.4s ease;
    cursor: pointer;
    position: relative;
}

.video-card.expanded {
    max-height: 2000px;
}

.video-container {
    display: flex;
    justify-content: center;
    align-items: center;
    background: black;
    position: relative;
    max-height: 350px;
    overflow: hidden;
}

.video-card.expanded .video-container {
    max-height: none;
    padding: 1rem 0;
}

.video-container video {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

.video-card.expanded video {
    object-fit: contain;
}

/* Overlay Play Button */
.play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    cursor: pointer;
    z-index: 10;
    transition: transform 0.2s ease, opacity 0.3s ease;
}

.play-icon {
    width: 80px;
    height: 80px;
    opacity: 0.95;
    transition: transform 0.2s ease, opacity 0.3s ease;
    filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.3));
}

.play-overlay:hover .play-icon {
    transform: scale(1.1);
    opacity: 1;
}

.video-card.expanded .play-overlay {
    display: none;
}

.snore-bubble {
    animation: snore-float 2s ease-in-out infinite;
    font-size: 1.5rem;
    transform: translateY(-30px);
}

@keyframes snore-float {
    0% {
        transform: translateY(-30px) scale(1);
        opacity: 0.8;
    }

    50% {
        transform: translateY(-40px) scale(1.1);
        opacity: 1;
    }

    100% {
        transform: translateY(-30px) scale(1);
        opacity: 0.8;
    }
}

.bear-icon .bear-wrapper .bear-rotatable {
    transition: transform 0.3s ease;
}

#bear-log {
    background-color: rgba(0, 0, 0, 0.7);
    color: #eee;
    pointer-events: none;
}

.speech-bubble {
    position: absolute;
    top: -96px;
    left: 58%;
    transform: translateX(-50%);
    background: white;
    color: #333;
    padding: 8px;
    border-radius: 12px;
    /*font-size: 10px;*/
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.speech-bubble::after {
    content: "";
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 6px 6px 0 6px;
    border-style: solid;
    border-color: white transparent transparent transparent;
}

.poi-marker {
    text-align: center;
    width: 60px;
}

.poi-marker .poi-image {
    border: 2px solid #444;
    background: #fff;
    padding: 2px;
    border-radius: 4px;
    width: 50px;
    height: 50px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.poi-marker .poi-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 2px;
}

.poi-marker .poi-name {
    margin-top: 4px;
    font-size: 12px;
    color: #222;
    font-weight: 500;
    text-shadow: 1px 1px 1px #fff;
}

.poi-sign {
  background: rgba(0, 0, 0, 0.6); /* dark translucent */
  color: white;
  padding: 2px 4px;
  border-radius: 0px;
  font-size: 11px;
  white-space: nowrap;
  font-weight: 500;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  text-align: center;
}

.custom-poi-label {
  width: auto!important;
}

.glow-dot {
  /* initial glow */
  filter: drop-shadow(0 0 6px rgba(255, 0, 0, 0.7));
  /* pulsing animation */
  animation: pulse 1.5s ease-out infinite;
}

/* Pulse keyframes */
@keyframes pulse {
  0% {
    r: 6;                     /* starting radius */
    opacity: 1;               /* fully visible */
    filter: drop-shadow(0 0 6px rgba(255, 0, 0, 0.7));
  }
  70% {
    r: 20;                    /* expanded glow */
    opacity: 0,5;               /* fade out */
    filter: drop-shadow(0 0 20px rgba(255, 0, 0, 0.5));
  }
  100% {
    r: 6;                     /* back to original */
    opacity: 0,5;
    filter: drop-shadow(0 0 6px rgba(255, 0, 0, 0.7));
  }
}

.map-layout,
.map-layout html,
.map-layout body {
  height: 100dvh;
  height: 100svh;
  margin: 0;
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.map-layout main {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.map-site,
.map-content,
.map-wrapper-track {
  flex: 1 1 auto;
  display: flex;
  flex-direction: row;
  min-height: 0;
  overflow: hidden;
}

.map-site,
.map-content {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.map-content {
  height: 100dvh;
  height: 100svh;
}

.map-wrapper-track {
  flex: 1 1 auto;
  display: flex;
  position: relative;
  overflow: hidden;
  min-height: 0;
}

#map-track {
  flex: 1 1 auto;
  min-height: 0;
}

/*.map-controls-container {
  flex-shrink: 0;
  height: var(--controls-height, 47px);
  z-index: 999;
}*/

.map-controls-container {
  position: absolute;
  bottom: 0;
  left: 56px;
  right: 0;
  /*height: var(--controls-height, 47px);*/
  z-index: 998;
  transition: 0.1s ease;
  overflow: hidden;
}

.map-controls {
  height: 59px;
  background: rgba(176, 214, 255, 0.6);
  box-shadow: 1px -3px 12px rgba(0, 0, 0, 0.7);
}

.map-toggle-buttons {
  margin-left: auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: end;
}

.map-toggle-buttons .btn {
    width: 36px;
    height: 36px;
    padding: 0 0.5rem;
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.map-toggle-buttons button span {
    margin-left: 8px;
    opacity: 0;
    transition: opacity 0.2s ease;
    white-space: nowrap;
  }
#side-panel.expanded .map-toggle-buttons button span {
  opacity: 1;
}

.map-toggle-buttons .btn:focus:not(:focus-visible) {
  outline: none;
  box-shadow: none;
}
.characters-map {
    position: fixed;
    margin-left: var(--event-left-offset, 0);
    top: 62px;
    right: 1rem;
    display: flex;
    z-index: 767;
}

.img-char-user {
  transition: transform 0.2s ease, box-shadow 0.2s ease!important;
}

.img-char-user:hover {
  transform: scale(1.1)!important;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  z-index: 2;
}

.peeking-row {
  margin-bottom: -100px; /* Adjust to control overlap depth */
}

.card .img-char-user,
.card .img-char-anon,
.img-char-anon,
.img-char-user {
  width: 48px;
  height: 48px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.85);
  border-color: orange;
  border-width: 2px;
}

.card img.peeking-char-user-img,
.card img.img-char-user,
.card img.img-char-anon {
  transform: none;
  max-width: none;
  height: auto;
}

.img-char-anon {
  width: 48px;
  height: 48px;
  object-fit: cover;
  background-color: rgb(255, 255, 255);
}

.trip-card-fluid {
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease;
  color: white;
}

.trip-card {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
  transition: transform 0.3s ease;
  min-height: 260px;
  background-color: #111;
  color: white;
}

.trip-card:hover {
  transform: scale(1.01);
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.trip-bg {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.trip-bg video,
.trip-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.4);
}

.trip-overlay {
  position: relative;
  z-index: 3;
  padding: 1rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.character-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  padding-bottom: 1rem;
  pointer-events: none;
  gap: 1rem;
  flex-wrap: wrap;
  overflow: hidden;
  max-height: 100%;
}

.character-hero-overlay img {
  max-height: 220px;
  max-width: 25%;
  object-fit: contain;
  /*opacity: 0.2;
  filter: grayscale(100%);
  transition: opacity 0.3s ease;*/
}

.hero-count-1 img { max-width: 60%; }
.hero-count-2 img { max-width: 40%; }
.hero-count-3 img { max-width: 30%; }
.hero-count-4 img { max-width: 22%; }

.character-avatars {
  display: flex;
  gap: 0.5rem;
  align-items: flex-end;
  flex-wrap: wrap;
}

.character-hero img {
  object-fit: contain;
  transition: transform 0.2s;
}
.trip-card.no-guests .character-hero img {
  height: 120px;
}
.trip-card.with-guests .character-hero img {
  height: 90px;
}
.character-hero img:hover {
  transform: scale(1.05);
}
.character-guest {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 60px;
}
.character-guest img {
  height: 40px;
  width: 40px;
  border-radius: 50%;
  object-fit: cover;
  background-color: #f8f9fa; /* light gray circle */
  padding: 2px; /* optional border spacing */
}
.guest-name {
  font-size: 0.75rem;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.badge-track {
  font-size: 0.85rem;
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(3px);
  border-radius: 0.5rem;
  padding: 0.3rem 0.6rem;
}

.poi-list {
  justify-content: flex-start;
  flex-wrap: wrap;
}
.poi-list .badge {
  background-color: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  padding: 0.3rem 0.6rem;
  white-space: nowrap;
}

#event-card {
  position: fixed;
  bottom: 1rem;
  left: var(--event-left-offset, 0);
  right: 1rem;
  background: rgba(0, 0, 0, 0.85);
  color: white;
  padding: 1rem;
  border-radius: 0.5rem;
  z-index: 1000;
  max-width: 800px;
  width: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: left 0.3s ease;
}

#event-media img {
  max-height: 50vh;
  width: 100%;
  object-fit: cover;
  border-top-left-radius: 0.5rem;
  border-top-right-radius: 0.5rem;
}

#side-panel {
  position: fixed;
  top: var(--navbar-height, 56px);
  bottom: 0;
  left: 0;
  height: auto;
  max-height: 100%;
  width: 260px;
  max-width: 80%;
  background: rgba(176, 214, 255, 0.6);
  backdrop-filter: blur(6px);
  transition: transform 0.1s ease;
  z-index: 768;
  display: flex;
  flex-direction: column;
  padding: 1rem 0.5rem;
  transform: translateX(-204px);
}

#side-panel.expanded {
  transform: translateX(0);
}

#side-panel.expanded .map-toggle-buttons button {
  width: 100% !important;
  justify-content: flex-start;
  padding-left: 0.75rem;
}

#panel-toggle {
  width: 100%;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 0.5rem;
  margin-bottom: 5px;
  cursor: pointer;
  z-index: 10;
}

#panel-toggle i {
  color: #fff;
  font-size: 1.25rem;
  transition: transform 0.2s ease;
}

.panel-content {
  display: flex;
  flex-direction: column;
  align-items: start;
  flex: 1 1 auto;
  min-height: 0;
}
.panel-extra-wrapper {
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1 1 auto;
  min-height: 0;
  max-height: 100%;
  padding-right: 4px; /* Prevent content clipping */
}
/* Hide scrollbar — WebKit (Chrome, Safari) */
.panel-extra-wrapper::-webkit-scrollbar {
  width: 0px;
  background: transparent;
}

/* Hide scrollbar — Firefox */
.panel-extra-wrapper {
  scrollbar-width: none;       /* Firefox */
  -ms-overflow-style: none;    /* IE/Edge */
}
.panel-extra {
  margin-top: 1rem;
  transition: opacity 0.2s ease;
}

#side-panel.collapsed .panel-extra {
    opacity: 0;
    pointer-events: none;
    max-height: 0;
    overflow: hidden;
    transition: opacity 0.2s ease, max-height 0.3s ease;
  }
  
#side-panel.expanded .panel-extra {
  opacity: 1;
  pointer-events: auto;
  /*max-height: 500px; */
}

/*.map-image-overlay {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 1000;
  display: flex;
  flex-direction: row-reverse;
  gap: 0.5rem;
  padding: 0.5rem;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 0.5rem;
  max-width: 90vw;
  overflow-x: auto;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
}

.map-image-overlay img {
  max-height: 200px;
  border-radius: 0.25rem;
  opacity: 0;
  transition: opacity 0.4s ease-in, transform 0.4s ease;
}

.map-image-overlay img.show {
  opacity: 1;
  transform: translateX(0);
}*/

.image-thumb-cluster {
  position: relative;
  display: inline-block;
}

.image-polaroid-wrapper {
  position: absolute;
  width: 36px;
  height: 36px;
  top: 0;
  left: 0;
}

.image-polaroid-wrapper:nth-child(1) {
  transform: rotate(-12deg);
  z-index: 1;
}
.image-polaroid-wrapper:nth-child(2) {
  transform: rotate(0deg);
  z-index: 2;
}
.image-polaroid-wrapper:nth-child(3) {
  transform: rotate(12deg);
  z-index: 3;
}

.image-polaroid {
  width: 42px;
  height: 42px;
  object-fit: cover;
  border: 2px solid white;
  border-radius: 4px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.4);
  background: white;
}

.image-polaroid-overlay {
  position: absolute;
  top: 16px;
  left: 16px;
  width: 16px;
  height: 16px;
  background-color: rgba(0, 0, 0, 0.2);
  color: white;
  font-size: 16px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  pointer-events: none;
}

#imageClusterModal .swiper-slide {
  transform: none !important;
}

:root {
  --navbar-height: 56px;
  --controls-height: 59px;
}

@media (max-width: 576px) and (orientation: portrait) {
  :root {
    --navbar-height: 56px;
    --controls-height: 59px;
  }
}

/*.map-controls-container {
    position: relative;
    flex-shrink: 0;
    z-index: 1000
}

.map-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}*/


/*.map-wrapper-track {
    height: calc(60vh);
    position: relative;
    display: flex;
    flex-direction: column;
  }
  
  #map-track {
    flex-grow: 1;
    min-height: 0;
    height: 100%;
  }
  
  .map-controls-container {
    position: absolute;
    bottom: 0;
    width: 100%;
    z-index: 600;
  }*/

.poi-card-marker {
    text-align: center;
    display: inline-block;
    border-radius: 8px;
    background-color: rgba(116, 122, 116, 0.863);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    padding: 0;
    width: 110px;
    /*max-width: 100px;*/
    text-align: center;
    overflow: visible;
    position: relative;
}

.poi-card-marker img {
    width: 100% !important;
    height: 60px;
    display: block;
    object-fit: cover;
    border-radius: 0.35rem;
    margin-bottom: 0.25rem;
}

.poi-pointer {
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 10px solid rgb(116, 122, 116); /* same as background */
  filter: drop-shadow(0 -2px 2px rgba(0,0,0,0.1));
  z-index: 10;
}

.poi-check {
  position: absolute;
  top: 3px;
  right: 3px;
  background: white;
  color: #28a745;
  font-size: 1rem;
  border-radius: 50%;
  padding: 4px;
  box-shadow: 0 0 2px rgba(0, 0, 0, 0.2);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 15px;
  line-height: 1;
}

.poi-card-marker.been {
  border: 2px solid #28a745; /* Bootstrap green */
  box-shadow: 0 0 6px rgba(40, 167, 69, 0.4);
}

.poi-card-marker.not-been {
  border: 2px solid #888888; /* Bootstrap green */
  box-shadow: 0 0 6px rgba(40, 167, 69, 0.4);
  background-color: rgba(6, 6, 6, 0.6);
}

.poi-card-icon {
  display: inline-block;
  overflow: visible !important;  /* allow pointer to stick out */
  background: transparent;
}

.poi-card-marker .title {
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 0rem 0.2rem;
  color: #88ff6c;
}

.poi-card-marker.not-been .title {
    color: #c9d9c5;
}

.poi-card-marker .chevron-down {
  position: absolute;
  bottom: -28px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.5rem;
  color: rgba(116, 122, 116, 0.863);
  z-index: 10;
  pointer-events: none;
}

.poi-connector-line {
  stroke: white;
  stroke-opacity: 0.8;
  filter: drop-shadow(0 0 2px #fff);
}

#lightboxOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1056; /* above Bootstrap modal (1055) */
    display: flex;
    align-items: center;
    justify-content: center;
}

#lightboxOverlay.d-none {
    display: none;
}

#lightboxOverlay.fade-out {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1;
}

#lightboxImage {
    max-width: 90%;
    max-height: 90%;
    z-index: 2;
    border-radius: 8px;
    box-shadow: 0 0 12px rgba(0, 0, 0, 0.5);
    cursor: zoom-out;
}

.leaflet-marker-icon.fade {
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.media-thumb-img {
    height: 250px;
    width: 100%;
    object-fit: cover;
  }
  
  .gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
    color: white;
    z-index: 5;
    padding: 1rem;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
  }
  
  .media-thumbnail-wrapper {
    border-radius: 8px;
    overflow: hidden;
    position: relative;
  }

  .video-preview-wrapper {
    overflow: hidden;
    position: relative;
  }

  .video-preview {
    width: 100%;
    /* height: 200px !important; */
    aspect-ratio: 4 / 3;
    object-fit: cover;
    object-position: center;
  }
  .video-preview:hover {
    filter: brightness(1.05);
  }

  .youtube-post-detail {
    margin-top: -48px;
  }

  .blockquote {
    border-width: 0 0 0 10px;
    border-style: solid;
  }

  .blockquote p {
    margin-left: 10px;
  }

  .preview-item {
    margin-bottom: 1.5rem;
  }
  .preview-thumb {
    max-width: 200px;
    border: 1px solid #ccc;
    border-radius: 5px;
  }
  .dropzone {
    border: 2px dashed #ccc;
    padding: 2rem;
    text-align: center;
    border-radius: 5px;
    margin-bottom: 2rem;
    cursor: pointer;
  }
  .dropzone.dragover {
    background-color: #f0f8ff;
    border-color: #0d6efd;
  }

/* START MOSAIC AND MODAL */

.media-thumb {
  width: 100%;
  height: auto;
  object-fit: cover;
  aspect-ratio: 1 / 1;
  border-radius: 6px;
  display: block;
}

.media-wrapper {
  position: relative;
  overflow: hidden;
}

.media-wrapper.portrait .media-thumb {
  aspect-ratio: 3 / 4;
}
.media-wrapper.landscape .media-thumb {
  aspect-ratio: 4 / 3;
}

.media-tile {
  cursor: pointer;
}

.media-tile:hover .media-thumb {
  filter: brightness(0.95);
  box-shadow: 0 0 6px rgba(0, 0, 0, 0.2);
}

.overlay-count {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.6);
  color: white;
  font-size: 2rem;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
}

.modal-fullscreen .modal-body {
  overflow: hidden;
  /*touch-action: pan-x;*/
}

/* Hide nav buttons by default */

.swiper-button-next, .swiper-button-prev {
  opacity: 1;
  transition: 0.5s ease-in-out;
  pointer-events: none;
}
    
.swiper-button-disabled {
      visibility: hidden;
      opacity: 0;
      transition: 0.5s ease-in-out;
}

/* Show on hover */
#mediaSwiperModal:hover .swiper-button-next,
#mediaSwiperModal:hover .swiper-button-prev {
  opacity: 1;
  pointer-events: auto;
}

/*.modal-content {
  touch-action: pan-y;
}*/

.modal-fullscreen {
  overflow: hidden;
}

.modal-fullscreen .swiper-slide img {
  max-height: 100vh;
  max-width: 100vw;
  object-fit: contain;
}

.modal-fullscreen video {
  max-height: 100vh;
  max-width: 100vw;
  object-fit: contain;
}

.video-modal-wrapper img,
.video-modal-wrapper video {
  max-height: 100vh;
  max-width: 100vw;
  object-fit: contain;
}

.btn-close-light {
  position: absolute;
  width: 2rem;
  height: 2rem;
  padding: 0.5rem;
  top: 1rem;
  right: 1rem;
  z-index: 1056;
  filter: invert(1);
  opacity: 0.8;
}

.btn-close-light:hover {
  opacity: 1;
}

.private-badge {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  z-index: 5;
  font-size: 0.75rem;
  padding: 0.25em 0.5em;
  border-radius: 0.25rem;
  pointer-events: none;
}

.private-badge-right {
  position: absolute;
  top: 0.5rem;
  right: 1rem;
  z-index: 5;
  font-size: 0.75rem;
  padding: 0.25em 0.5em;
  border-radius: 0.25rem;
  pointer-events: none;
}

.tag-badges .badge{
  display:inline-block;
  font-size:.65rem;
  line-height:1;
  padding:.125rem .35rem!important;
}

.tag-badges{
  display:flex; gap:.25rem; margin-top:.35rem;
  overflow-x:auto; white-space:nowrap; scrollbar-width:none;
  mask-image: linear-gradient(to right, rgba(0,0,0,1) 80%, rgba(0,0,0,0));
}
.tag-badges::-webkit-scrollbar{ display:none; }

.modal-video-play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  cursor: pointer;
  display: none; /* Shown only when paused */
}

.video-modal-wrapper.paused .modal-video-play-button {
  display: block;
}

.video-modal-wrapper video {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.media-hover-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.6);
  color: white;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  opacity: 1;
  transition: opacity 0.2s ease-in-out;
  pointer-events: none;
}

.video-modal-wrapper.paused .media-hover-info {
  opacity: 1;
}


.modal-media-wrapper:hover .media-hover-info {
  opacity: 1;
  visibility: visible;
}

@media (hover: none) and (pointer: coarse) {
  .media-hover-info {
    opacity: 1 !important;
  }
}

/* END MOSAIC AND MODAL */

.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
    cursor: pointer;
}

.hover-shadow {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hover-shadow:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.map-event-thumb{
  float: left !important;
  width: 140px !important;              /* small screens */
  aspect-ratio: 1 / 1;
  object-fit: cover !important;
  margin: 0 .5rem .3rem 0;  /* space to the right and bottom */
  border-radius: .5rem;      /* optional: soften corners */
  transform: none !important;
}

/* Clear the float so the parent wraps around the image+text */
.map-event-embed::after{
  content: "";
  display: table;
  clear: both;
}

/* Slightly larger thumb on wider screens */
@media (min-width: 768px){
  .map-event-thumb{ width: 140px; }
}

/* If screens get very narrow, shrink the thumb a bit more */
@media (max-width: 360px){
  .map-event-thumb{ width: 100px; }
}

/* Base */
.fb-comment { display:flex; gap:.75rem; color:var(--fb-text); }
.fb-avatar { width:40px; height:40px; flex:0 0 40px; border-radius:50%; overflow:hidden;
  background:var(--fb-avatar-bg); display:flex; align-items:center; justify-content:center; }
.fb-avatar img { width:100%; height:100%; object-fit:cover; }
.fb-avatar .bi { font-size:1.8rem; color:var(--fb-muted); }
.fb-main { flex:1 1 auto; min-width:0; }

/* Bubbles */
.fb-bubble { position:relative; background:var(--fb-top-bg); border-radius:16px; padding:.5rem .75rem; color:var(--fb-text); }
.is-reply .fb-bubble { background:var(--fb-reply-bg); }

/* Reply notch */
.is-reply .fb-bubble::before {
  content:""; position:absolute; left:-6px; top:14px; width:10px; height:10px;
  background:var(--fb-reply-bg); transform:rotate(45deg); border-radius:2px;
}

/* Reply branch + tighter layout */
.fb-replies { margin-left:2.25rem; padding-left:.75rem; border-left:2px solid var(--fb-reply-line); }
.fb-replies .fb-more { margin: .25rem 0; }
.is-reply .fb-avatar { width:32px; height:32px; flex-basis:32px; }
.is-reply.fb-comment { gap:.5rem; }

/* Text + actions */
.fb-text { word-wrap:break-word; color:var(--fb-text); }
.fb-actions a { text-decoration:none; color:var(--fb-link); }
.fb-actions a:hover { text-decoration:underline; }

/* Optional "Author" badge */
.badge-author {
  background:transparent; border:1px solid var(--fb-border);
  color:var(--fb-muted); font-size:.7rem; padding:.1rem .35rem; border-radius:999px;
  vertical-align:middle;
}

/* Long-comment clamp */
.fb-text[data-truncate="true"] {
  display:-webkit-box; -webkit-line-clamp:8; -webkit-box-orient:vertical; overflow:hidden;
}
.fb-text[data-truncate="true"].expanded {
  -webkit-line-clamp: unset;
  display: block;
}

.fb-highlight .fb-bubble {
  outline: 2px solid var(--fb-link);
  transition: outline-color .8s ease;
}

.fb-see-more { display:none; cursor:pointer; user-select:none; color:var(--fb-muted); }
.fb-text.truncated + .fb-see-more { display:inline-block; margin-top:.25rem; }

/* Composer — textarea INSIDE the bubble */
.fb-comments .fb-bubble { padding:0; } /* bubble frames the input neatly */
.fb-textarea,
#comment-form textarea { /* fallback if you don't use widget_tweaks */
  width:100%;
  display:block;
  border:0 !important;
  background:var(--fb-input-bg) !important;
  color:var(--fb-text) !important;
  border-radius:16px !important;
  padding:.65rem .75rem !important;
  min-height:44px;
  box-shadow:none !important;
  resize:vertical;
}
#comment-form textarea::placeholder { color:var(--fb-muted); }
#comment-form textarea:focus { background:var(--fb-input-bg-focus) !important; outline:none; box-shadow:none !important; }

.form-control.fb-input {
  background-color: var(--fb-input-bg);
  color: var(--fb-text);
  border-color: var(--fb-border);
  border-radius: 12px;
}
.form-control.fb-input::placeholder { color: var(--fb-muted); }
.form-control.fb-input:focus {
  background-color: var(--fb-input-bg-focus);
  color: var(--fb-text);
  border-color: var(--fb-border);
  box-shadow: none;
}


/* Replying pill */
#replying-pill {
  background:var(--fb-pill-bg);
  color:var(--fb-pill-text);
  border-radius:999px;
  padding:.125rem .5rem;
  display:inline-flex; align-items:center;
}
#replying-pill button { color:inherit; }

:root {
  --fb-bg: #f0f2f5;          /* bubble + input bg */
  --fb-elev: #ffffff;        /* not used yet, for cards */
  --fb-top-bg: #f0f2f5;     /* top-level bubble */
  --fb-reply-bg: #e8eaed;   /* reply bubble */
  --fb-border: #e9ecef;
  --fb-text: #212529;
  --fb-muted: #6c757d;
  --fb-link: #0d6efd;
  --fb-accent: #0b5ed7;
  --fb-avatar-bg: #e9ecef;
  --fb-reply-line: #e3e6ea;
  --fb-input-bg: var(--fb-bg);
  --fb-input-bg-focus: #e8eaed;
  --fb-pill-bg: #e7f1ff;
  --fb-pill-text: var(--fb-accent);
}

#comments, .fb-comment[id] { scroll-margin-top: 80px; }

/* Make the article container the positioning context for the overlay */
.article-container, .post, .enriched-body-wrapper { position: relative; }

/* Base */
.like-widget {
  --like-icon: 42px;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  cursor: pointer;
  user-select: none;
  z-index:9;
}

/* The icon container MUST have size */
.like-widget .icon-bear-heart.media-bear {
  position: relative;
  width: var(--like-icon);
  height: var(--like-icon);
  flex: 0 0 var(--like-icon);
}

/* Swap images */
.like-widget .icon-bear-heart.media-bear img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: contain;
  transition: opacity .18s ease-in-out;
  pointer-events: none;
}

.icon-bear-heart { position: relative; display:inline-block; }
.icon-bear-heart img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: contain;
  transition: opacity 180ms ease-in-out, transform 180ms ease-out;
  pointer-events: none;
}

/* Swap bear images */
.icon-bear-heart .state-loved { opacity: 0; }
.like-widget.liked .icon-bear-heart .state-idle  { opacity: 0; }
.like-widget.liked .icon-bear-heart .state-loved { opacity: 1; }

/* Pop animation */
@keyframes hugPop { 0%{transform:scale(.9) rotate(-2deg)} 60%{transform:scale(1.08) rotate(1deg)} 100%{transform:scale(1)} }
.like-widget.hugging .icon-bear-heart { animation: hugPop 320ms ease-out; }

/* Liked state styling */
.like-widget.liked .speech-bubble { border-color:#fecaca; }
.like-widget.liked .speech-bubble::after { border-right-color:#fecaca; }
.like-widget.liked .like-number { color:#e03131; font-weight:700; }

/* === Inline mode (snug next to icon) === */
.like-inline { gap: .5rem; }

/* === Overlay mode (floating over content) === */
.like-overlay {
  position: absolute;             /* pin inside the article container */
  top: .75rem;
  right: .75rem;
  z-index: 20;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
}

/* Compact bubble for overlay */
.like-overlay .speech-bubble {
  box-shadow: 0 6px 16px rgba(0,0,0,.08);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .icon-bear-heart img { transition: none; }
  .like-widget.hugging .icon-bear-heart { animation: none; }
}

/* Inline layout */
.like-inline {
  --like-icon: 72px; /* override inline for small version */
  display: inline-flex;
  align-items: flex-start;  /* top-align bubble with bear */
  gap: .5rem;
  cursor: pointer;
  max-width: 100%;
}

/* Polar bear icon */
.like-inline .icon-bear-heart {
  position: relative;
  width: var(--like-icon);
  height: var(--like-icon);
  flex: 0 0 var(--like-icon);
}
.like-inline .icon-bear-heart img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: contain;
  transition: opacity .18s ease-in-out;
}
.like-inline .state-loved { opacity: 0; }
.like-inline.liked .state-idle { opacity: 0; }
.like-inline.liked .state-loved { opacity: 1; }

/* Bubble styling */
.like-bubble {
  position: relative;
  flex: 1 1 auto;
  max-width: 28ch;            /* narrower width */
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: .6rem .8rem;
  line-height: 1.25;
  font-size: 0.75rem;
  color: #111827;
  word-wrap: break-word;      /* allow wrapping */
  white-space: normal;        /* multi-line text */
}

/* Tail now outside bubble */
.like-bubble::before,
.like-bubble::after {
  content: "";
  position: absolute;
  top: 1.1rem;                /* aligns with first line roughly */
  left: -8px;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
}
.like-bubble::before {
  border-right: 7px solid #e5e7eb; /* border edge */
}
.like-bubble::after {
  left: -6px;
  border-right: 6px solid #fff;    /* fill color */
}

/* When liked */
.like-inline.liked .like-bubble { border-color: #fecaca; }
.like-inline.liked .like-bubble::before { border-right-color: #fecaca; }
.like-inline.liked .like-number { color: #dacece; font-weight: 700; }

.like-widget.like-compact {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2px;
  line-height: 1;
  font-size: .72rem;
  cursor: pointer;
  background: rgba(0, 0, 0, 0.432);
  border-radius: 0.25rem;
}

/* fixed-size icon for this variant */
.like-widget.like-compact .icon-bear-heart {
  --icon: 52px;                 /* default; can override via inline style */
  position: relative;
  width: var(--icon);
  height: var(--icon);
  flex: 0 0 auto;
}

.like-widget.like-compact .icon-bear-heart img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: contain;
  transition: opacity .18s ease;
  pointer-events: none;
}
.like-widget.like-compact .state-loved { opacity: 0; }
.like-widget.like-compact.liked .state-idle  { opacity: 0; }
.like-widget.like-compact.liked .state-loved { opacity: 1; }
.like-widget.like-compact .like-label,
.like-widget.like-compact .like-count {
  color: #6c757d;
}
.like-widget.like-compact.liked .like-label,
.like-widget.like-compact.liked .like-count {
  color: #fcf5f5;
}
.like-widget.like-compact .like-label {
  color: #f8f8f8;
}
.btn-tiny {
  padding: 0.2rem 0.4rem;
  font-size: 0.6rem;
  border-radius: 0.2rem;
}