

:root {
    --primary-color: #2563eb;
    --bg-app: #020617;
    --text-main: #f8fafc;
    --sidebar-width: 320px;
    --sidebar-bg: rgba(15, 23, 42, 0.8);
    --sidebar-border: rgba(255, 255, 255, 0.1);
    --sidebar-text: #ffffff;
    --sidebar-text-dim: rgba(255, 255, 255, 0.6);
    --sidebar-hover: rgba(255, 255, 255, 0.05);
    --app-glow: rgba(37, 99, 235, 0.15);
    --marker-bg: #2563eb;
    --marker-dot: #ffffff;
    --header-bg: #ffffff;
}

.theme-light-cream {
    --primary-color: #facc15;
    --bg-app: #fdf8f4;
    --text-main: #1e293b;
    --sidebar-bg: #1e293b;
    --sidebar-border: #2d3748;
    --sidebar-text: #ffffff;
    --sidebar-text-dim: #cbd5e1;
    --sidebar-hover: #2d3748;
    --app-glow: rgba(250, 204, 21, 0.05);
    --marker-bg: #1e293b;
    --marker-dot: #facc15;
    --header-bg: #ffffff;
}

.theme-modern-white {
    --primary-color: #3b82f6;
    --bg-app: #ffffff;
    --text-main: #0f172a;
    --sidebar-bg: #ffffff;
    --sidebar-border: #e2e8f0;
    --sidebar-text: #0f172a;
    --sidebar-text-dim: #64748b;
    --sidebar-hover: #f1f5f9;
    --app-glow: rgba(59, 130, 246, 0.03);
    --marker-bg: #3b82f6;
    --marker-dot: #ffffff;
    --header-bg: #ffffff;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-app);
    color: var(--text-main);
}

/* Map page - fullscreen without scroll */
body.has-map {
    overflow: hidden;
    height: 100vh;
}

/* Content pages - normal scroll */
body.has-content {
    overflow-y: auto;
    min-height: 100vh;
    background-color: #ffffff;
    color: #1e293b;
}

/* Prevent tab navigation to hidden elements */
body.has-map * {
    -webkit-user-select: none;
    user-select: none;
}

body.has-map button,
body.has-map a,
body.has-map .point-item {
    -webkit-user-select: auto;
    user-select: auto;
}

/* Skip link for screen readers - WCAG 2.1 requirement */
.skip-link {
    position: absolute;
    top: -50px;
    left: 0;
    background: #000;
    color: #fff;
    padding: 12px 20px;
    text-decoration: none;
    z-index: 9999;
    font-weight: 600;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}

.skip-link:focus {
    top: 0;
    outline: 3px solid #facc15;
}

/* Custom scrollbar for sidebar */
#points-list::-webkit-scrollbar {
    width: 6px;
}

#points-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

#points-list::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 3px;
}

#points-list::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
    opacity: 0.8;
}

/* Header */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    z-index: 10000; /* Increased to stay above all map popups and modas */
    background: var(--header-bg);
    border-bottom: 3px solid var(--primary-color);
    padding: 0.75rem 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.header-container {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-center {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 2rem;
    flex: 1;
}

.header-right {
    display: flex;
    gap: 1rem;
    width: 30%;
    justify-content: flex-end;
}

.header-right a {
    color: #1e293b;
    font-size: 1.25rem;
    text-decoration: none;
    transition: color 0.2s;
    min-width: 44px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.header-right a:hover {
    color: var(--primary-color);
}

.site-logo {
    margin-bottom: 0;
}

.site-logo a {
    color: #1e293b;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.5rem;
    letter-spacing: -0.025em;
    padding: 0.5rem;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    gap: 2.5rem;
}

.main-navigation a {
    color: #1e293b;
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: all 0.2s;
    padding: 0.75rem 0.5rem;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}

.main-navigation a:hover {
    color: var(--primary-color);
}

/* Map App Container */
#map-app {
    width: 100vw;
    height: 100vh;
    position: relative;
    overflow: hidden;
    background-color: var(--bg-app);
    box-shadow: inset 0 0 150px var(--app-glow);
}

/* Viewport & Layers */
.map-viewport {
    width: 100%;
    height: 100%;
    cursor: grab;
    overflow: hidden;
    position: relative;
}

.map-viewport:active {
    cursor: grabbing;
}

#map-layers {
    position: absolute;
    top: 50%;
    left: 50%;
    transform-origin: center center;
    will-change: transform;
}

#map-image-wrapper {
    position: relative;
}

#map-image {
    display: block;
    user-select: none;
    pointer-events: none;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    background-color: #222;
    /* Fallback */
}

/* Markers */
.marker {
    position: absolute;
    width: 66px;
    height: 66px;
    background: var(--marker-bg);
    border: 4px solid white;
    border-radius: 50% 50% 50% 0;
    transform: translate(-50%, -100%) rotate(-45deg);
    cursor: pointer;
    transition: transform 0.2s, background-color 0.2s, box-shadow 0.2s;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.marker:hover {
    background-color: var(--primary-color);
    transform: translate(-50%, -100%) rotate(-45deg) scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.marker::after {
    content: '';
    position: absolute;
    width: 10px;
    height: 10px;
    background: var(--marker-dot);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Sidebar */
#sidebar-navigation {
    position: absolute;
    left: 20px;
    top: 148px;
    /* Adjusted for header height + margin */
    bottom: auto;
    max-height: calc(100vh - 168px);
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    border: 1px solid var(--sidebar-border);
    border-radius: 12px;
    z-index: 50;
    display: flex;
    flex-direction: column;
    padding: 0;
    transition: transform 0.3s ease, left 0.3s ease, right 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
}

/* Right-aligned sidebar */
#sidebar-navigation.sidebar-right {
    left: auto;
    right: 20px;
}

.sidebar-header {
    padding: 1.5rem;
    border-bottom: 3px solid var(--primary-color);
    position: relative;
    border-radius: 12px 12px 0 0;
}

.sidebar-header::after {
    display: none; /* Removed fixed icon */
}

.sidebar-header h2 {
    font-size: 0.875rem; /* Slightly smaller for mobile optimization */
    color: var(--sidebar-text);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
}

#points-list {
    list-style: none;
    overflow-y: auto;
    flex: 0 1 auto;
    max-height: 300px;
}

.point-item {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--sidebar-border);
    cursor: pointer;
    transition: all 0.2s;
    outline: none;
    min-height: 68px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.point-item:last-child {
    border-bottom: none;
}

.point-item:hover {
    background: var(--sidebar-hover);
    padding-left: 1.75rem;
}

.point-item:focus {
    background: var(--sidebar-hover);
    padding-left: 1.75rem;
    box-shadow: inset 3px 0 0 var(--primary-color);
}

/* WCAG 2.1 AA Focus Indicators */
button:focus,
a:focus,
.point-item:focus {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

/* High contrast focus for dark backgrounds */
body.has-map button:focus,
body.has-map a:focus {
    outline: 3px solid #facc15;
    outline-offset: 2px;
}

.point-item h4 {
    margin-bottom: 0.25rem;
    color: var(--sidebar-text);
    font-size: 1rem;
    font-weight: 500;
}

.point-item p {
    font-size: 0.9375rem;
    color: var(--sidebar-text-dim);
    line-height: 1.5;
}

/* Controls */
#map-controls {
    position: absolute;
    right: 20px;
    bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 50;
}

#map-controls button {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid var(--sidebar-border);
    background: var(--sidebar-bg);
    color: var(--sidebar-text);
    font-size: 1.25rem;
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

#map-controls button:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Popup */
#map-popup {
    position: absolute;
    width: 400px;
    max-width: 90vw;
    background: white;
    color: #1e293b;
    border-radius: 16px;
    overflow: hidden;
    z-index: 2500; /* Above sidebar (2000) but below header (10000) */
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s, transform 0.3s;
    pointer-events: auto;
}

#map-popup.hidden {
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
}

.close-popup {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    color: white;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: background 0.2s;
}

.close-popup:hover {
    background: rgba(0, 0, 0, 0.9);
}

.close-popup:focus {
    outline: 3px solid #facc15;
    outline-offset: 2px;
}

.popup-image {
    width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
    background-color: #e2e8f0;
}

.popup-content {
    padding: 1.5rem;
}

.popup-title {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.popup-description {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #64748b;
    margin-bottom: 1.25rem;
    max-height: 150px;
    overflow-y: auto;
}

.btn-more {
    display: inline-block;
    padding: 12px 24px;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: background 0.2s;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.btn-more:hover {
    background: #1d4ed8;
}

/* Content Pages */
.content-page {
    padding-top: 120px;
    min-height: 100vh;
}

.content-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.content-container article {
    background: white;
    padding: 3rem;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.entry-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: #1e293b;
    line-height: 1.2;
}

.entry-content {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #475569;
}

.entry-content p {
    margin-bottom: 1.5rem;
}

.entry-content h2 {
    font-size: 2rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    color: #1e293b;
}

.entry-content h3 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: #334155;
}

.entry-content ul,
.entry-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.entry-content li {
    margin-bottom: 0.5rem;
}

.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 2rem 0;
}

.entry-content a {
    color: var(--primary-color);
    text-decoration: underline;
}

.entry-content a:hover {
    color: #1d4ed8;
}

.entry-thumbnail {
    margin-bottom: 2rem;
}

.entry-thumbnail img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.entry-meta {
    margin-bottom: 1.5rem;
}

.back-to-map {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--primary-color);
    color: white !important;
    text-decoration: none !important;
    border-radius: 8px;
    font-weight: 600;
    transition: background 0.2s;
}

.back-to-map:hover {
    background: #1d4ed8 !important;
    color: white !important;
}
/* Full Content Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10500; /* Above header (10000) and sidebar (2000) */
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.modal-overlay.hidden {
    opacity: 0;
    pointer-events: none;
    visibility: hidden; 
}

.modal-container {
    background: white;
    width: 90%;
    max-width: 900px; /* Reduced from 1200px for better UX on FullHD */
    height: 85vh;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: modalSlideUp 0.4s ease-out;
}

@media (min-width: 2400px) {
    .modal-container {
        max-width: 1200px; /* Larger max-width for 4K monitors */
    }
}

@keyframes modalSlideUp {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.modal-body {
    padding: 3rem;
    overflow-y: auto;
    overflow-x: hidden;
    color: #1e293b;
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    font-size: 2rem;
    color: #64748b;
    cursor: pointer;
    z-index: 10;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s, color 0.2s;
}

.close-modal:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.modal-title {
    margin-top: 0;
    margin-bottom: 2rem;
    font-size: 2.5rem;
    padding-right: 40px;
    color: #1e293b;
    line-height: 1.2;
}

.modal-content {
    font-size: 1.1rem;
    line-height: 1.8;
}

.modal-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5rem 0;
}

.modal-image {
    width: 100%;
    height: auto;
    max-height: 45vh; /* Increased from 30vh to allow more of the image to be shown */
    object-fit: contain; /* Changed from cover to prevent cropping */
    background: #f8fafc; /* Added light background for images that don't fill the width */
    border-radius: 8px;
    margin-bottom: 2rem;
}

/* Gallery Styles */
.point-gallery {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
}

.gallery-grid {
    display: grid;
    gap: 15px;
}

.gallery-grid-2 { grid-template-columns: repeat(2, 1fr); max-width: 600px; }
.gallery-grid-3 { grid-template-columns: repeat(3, 1fr); max-width: 800px; }
.gallery-grid-4 { grid-template-columns: repeat(4, 1fr); max-width: 1000px; }

@media (max-width: 640px) {
    .gallery-grid { grid-template-columns: repeat(2, 1fr) !important; max-width: 100% !important; }
}

.gallery-item {
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    background: #f1f5f9;
}

.gallery-item:hover {
    transform: scale(1.03);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Lightbox Styles */
.lightbox-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    z-index: 11000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.3s;
}

.lightbox-modal.hidden {
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
}

.lightbox-container {
    position: relative;
    width: 90%;
    height: 90%;
    display: flex;
    flex-direction: column; /* Changed for caption */
    justify-content: center;
    align-items: center;
    gap: 15px;
}

.lightbox-image {
    max-width: 100%;
    max-height: calc(100% - 60px); /* Leave space for caption */
    object-fit: contain;
    box-shadow: 0 0 30px rgba(0,0,0,0.5);
    transition: opacity 0.2s ease;
}

/* Loading spinner while new image is being fetched */
.lightbox-container.lightbox-loading::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 48px;
    height: 48px;
    margin: -24px 0 0 -24px;
    border: 4px solid rgba(255, 255, 255, 0.2);
    border-top-color: white;
    border-radius: 50%;
    animation: lightbox-spin 0.8s linear infinite;
    z-index: 10;
}

@keyframes lightbox-spin {
    to { transform: rotate(360deg); }
}

.lightbox-caption {
    width: 100%;
    text-align: center;
    color: white;
    background: rgba(0, 0, 0, 0.6);
    padding: 10px 20px;
    border-radius: 8px;
    max-width: 800px;
}



.close-lightbox {
    position: absolute;
    top: -60px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 3rem;
    cursor: pointer;
    line-height: 1;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    width: calc(100% + 120px);
    left: -60px;
    display: flex;
    justify-content: space-between;
    transform: translateY(-50%);
    pointer-events: none;
}

.lightbox-nav button {
    pointer-events: auto;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    font-size: 2rem;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-nav button:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* Hide toggle/hamburger and mobile-only elements on desktop */
.mobile-menu-toggle, .sidebar-toggle, .mobile-social-row {
    display: none;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .lightbox-nav {
        width: 100%;
        left: 0;
        padding: 0 10px;
    }

    .lightbox-nav button {
        width: 44px;
        height: 44px;
        font-size: 1.5rem;
    }

    .close-lightbox {
        top: -50px;
        right: 10px;
    }

    /* Map items safety margin from bottom sidebar */
    #map-controls {
        bottom: 80px;
    }

    /* --- Header / Hamburger Menu --- */
    .header-container {
        flex-wrap: wrap;
    }

    .header-center {
        flex: 1;
        min-width: 0;
    }

    .header-right {
        width: auto;
        order: 0;
    }

    /* Hide social links in top row, show them in nav dropdown */
    .header-right a:not([aria-label="Menu"]) {
        display: none;
    }

    /* Social links row inside mobile nav */
    .mobile-social-row {
        display: flex;
        justify-content: center;
        gap: 1.5rem;
        padding: 1rem 2rem;
        border-top: 1px solid #e2e8f0;
        width: 100%;
    }

    .mobile-social-row a {
        color: #1e293b;
        font-size: 1.25rem;
        text-decoration: none;
        min-width: 44px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 64px;
        height: 32px;
        background: #f1f5f9;
        border: none;
        border-radius: 8px;
        cursor: pointer;
        padding: 0;
        z-index: 101;
    }

    .hamburger-icon, .hamburger-icon::before, .hamburger-icon::after {
        content: '';
        display: block;
        width: 26px;
        height: 2px;
        background: #0f172a;
        position: relative;
        transition: all 0.2s;
    }

    .hamburger-icon::before { top: -7px; }
    .hamburger-icon::after { top: 5px; }

    .mobile-menu-toggle[aria-expanded="true"] .hamburger-icon { background: transparent; }
    .mobile-menu-toggle[aria-expanded="true"] .hamburger-icon::before { transform: rotate(45deg); top: 0; }
    .mobile-menu-toggle[aria-expanded="true"] .hamburger-icon::after { transform: rotate(-45deg); top: -2px; }

    .main-navigation {
        position: fixed;
        top: 64px;
        left: 0;
        width: 100%;
        background: white;
        height: 0;
        overflow: hidden;
        transition: height 0.3s ease;
        box-shadow: 0 10px 20px rgba(0,0,0,0.1);
        z-index: 9999;
    }

    .main-navigation.active {
        height: auto;
        padding-bottom: 0;
    }

    .main-navigation ul {
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
    }

    .main-navigation a {
        padding: 1rem 2rem;
        width: 100%;
        border-bottom: 1px solid #f1f5f9;
    }

    /* --- Sidebar / Bottom Panel Mobile --- */
    #sidebar-navigation,
    #sidebar-navigation.sidebar-left,
    #sidebar-navigation.sidebar-right {
        position: fixed !important;
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        max-width: none !important;
        max-height: 50vh !important;
        margin: 0 !important;
        border-radius: 20px 20px 0 0 !important;
        transform: translateY(0);
        transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
        z-index: 2000 !important;
        box-shadow: 0 -5px 25px rgba(0,0,0,0.3) !important;
        display: flex !important;
        flex-direction: column !important;
        background: white !important;
    }

    #sidebar-navigation.mobile-collapsed {
        transform: translateY(calc(100% - 60px));
    }

    /* Hide the separate toggle button - use header drag instead */
    .sidebar-toggle {
        display: none !important;
    }

    /* Drag handle on sidebar header */
    .sidebar-header {
        cursor: grab;
        position: relative;
        padding: 1.25rem 1.5rem;
        -webkit-user-select: none;
        user-select: none;
    }

    .sidebar-header::before {
        content: '';
        display: block;
        width: 40px;
        height: 4px;
        background: #cbd5e1;
        border-radius: 2px;
        margin: 0 auto 0.75rem;
    }

    .sidebar-header:active {
        cursor: grabbing;
    }

    /* --- Popup mobile: smaller paddings & close button --- */
    #map-popup {
        width: 260px;
        max-width: 85vw;
    }

    .popup-content {
        padding: 0.75rem;
    }

    .popup-image {
        height: 120px;
    }

    .popup-title {
        font-size: 1rem;
        margin-bottom: 0.4rem;
    }

    .popup-description {
        font-size: 0.85rem;
        margin-bottom: 0.75rem;
        max-height: 80px;
    }

    .close-popup {
        width: 28px;
        height: 28px;
        font-size: 1rem;
        top: 4px;
        right: 4px;
    }

    .btn-more {
        padding: 0.4rem 0.75rem;
        font-size: 0.85rem;
        min-height: 36px;
    }

    /* --- Modal mobile: fullscreen, always on top --- */
    .modal-overlay {
        z-index: 10500; /* Above header and sidebar */
    }

    .modal-container {
        width: 100%;
        height: 100%;
        max-width: 100%;
        border-radius: 0;
    }

    .modal-body {
        padding: 1.5rem;
    }

    .modal-title {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .close-modal {
        width: 48px;
        height: 48px;
        font-size: 2rem;
        top: 12px;
        right: 12px;
    }

    /* Content pages - reduce margins/padding on mobile */
    .content-page {
        padding-top: 80px;
    }

    .content-container {
        padding: 0.75rem;
    }

    .content-container article {
        padding: 1.25rem;
        border-radius: 8px;
    }

    .entry-title {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .entry-content {
        font-size: 1rem;
    }

    .entry-content h2 {
        font-size: 1.4rem;
        margin-top: 1.5rem;
    }

    .entry-content h3 {
        font-size: 1.15rem;
        margin-top: 1.25rem;
    }
}

/* Custom Marker Overrides */
.marker.has-custom-icon {
    border-radius: 0;
    box-shadow: none;
    background-color: transparent;
    transform: translate(-50%, -100%) rotate(0deg);
}

.marker.has-custom-icon:hover {
    background-color: transparent;
    transform: translate(-50%, -100%) scale(1.1);
    box-shadow: none;
}

.marker.has-custom-icon::after {
    display: none;
}
