/* Arena Breakout Orange Theme - Matching Main Page */
:root {
    --primary-color: #ff8c00;
    --secondary-color: #ff6b35;
    --accent-color: #ffb347;
    --bg-dark: #1a1a1a;
    --bg-darker: #0f0f0f;
    --bg-light: #2a2a2a;
    --bg-panel: #2d2d2d;
    --text-primary: #ffffff;
    --text-secondary: #e0e0e0;
    --text-muted: #9a9a9a;
    --text-accent: #ff8c00;
    --border-color: #4a4a4a;
    --border-accent: #ff8c00;
    --shadow-color: rgba(0, 0, 0, 0.6);
    --shadow-orange: 0 2px 8px rgba(255, 140, 0, 0.3);
    --gradient-primary: linear-gradient(135deg, #ff8c00 0%, #ff6b35 100%);
    --gradient-secondary: linear-gradient(135deg, #ff6b35 0%, #ff4500 100%);
    --gradient-dark: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    --gradient-accent: linear-gradient(135deg, #ffb347 0%, #ff8c00 100%);
}

/* Page Layout with Ad Spaces */
body {
    margin: 0;
    padding: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--bg-dark);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text-primary);
}

/* ===========================================
   NAVIGATION BAR STYLES
   =========================================== */

.map-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10000;
    background: var(--gradient-dark);
    border-bottom: 2px solid var(--border-accent);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-orange);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    max-width: 1400px;
    margin: 0 auto;
}

.nav-brand {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.brand-link {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 16px;
    transition: color 0.3s ease;
}

.brand-link:hover {
    color: var(--text-accent);
}

.brand-link i {
    font-size: 20px;
    color: var(--primary-color);
}

.nav-center {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 20px;
}

.current-page-info {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg-panel);
    padding: 4px 16px;
    border-radius: 20px;
    border: 1px solid var(--border-color);
}

.current-page-info i {
    color: var(--primary-color);
    font-size: 14px;
}

.page-indicator {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
}

.map-name-indicator {
    color: var(--text-accent);
    font-size: 14px;
    font-weight: 600;
    text-transform: capitalize;
}

/* Map Dropdown Styling */
.map-dropdown {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-primary);
    padding: 6px 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 140px;
}

.map-dropdown:hover,
.map-dropdown:focus {
    border-color: var(--border-accent);
    background: var(--bg-panel);
    outline: none;
}

.map-dropdown option {
    background: var(--bg-panel);
    color: var(--text-primary);
    padding: 8px 12px;
}

/* Difficulty Dropdown in Nav Actions */
.difficulty-dropdown.nav-dropdown {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-secondary);
    padding: 8px 12px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 100px;
}

.difficulty-dropdown.nav-dropdown:hover,
.difficulty-dropdown.nav-dropdown:focus {
    background: var(--bg-panel);
    border-color: var(--border-accent);
    color: var(--text-primary);
    outline: none;
}

.difficulty-dropdown.nav-dropdown option {
    background: var(--bg-panel);
    color: var(--text-primary);
    padding: 6px 12px;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nav-btn:hover {
    background: var(--bg-panel);
    border-color: var(--border-accent);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.nav-btn i {
    font-size: 14px;
}

/* Mobile Navigation Button (Hidden by default) */
.mobile-nav-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    background: var(--bg-panel);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    gap: 4px;
    padding: 8px;
}

.mobile-nav-btn:hover {
    background: var(--bg-light);
    border-color: var(--border-accent);
}

.hamburger-line {
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s ease;
    border-radius: 1px;
}

.mobile-nav-btn.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-nav-btn.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.mobile-nav-btn.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Mobile Navigation Overlay */
.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9997;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-nav-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* Responsive Navigation */
@media (max-width: 1024px) {
    .nav-container {
        padding: 10px 15px;
    }
    
    .nav-center {
        margin: 0 10px;
    }
    
    .current-page-info {
        padding: 6px 12px;
    }
    
    .page-indicator,
    .map-name-indicator {
        font-size: 12px;
    }
    
    /* Mobile navigation layout - difficulty on left, hamburger on right */
    .nav-actions {
        position: static;
        display: flex;
        align-items: center;
        gap: 8px;
        order: 3;
    }
    
    /* Show only difficulty dropdown and mobile button in navbar */
    .nav-actions .nav-btn:not(.sidebar-toggle-btn) {
        display: none !important;
    }
    
    .nav-actions .difficulty-dropdown {
        display: block !important;
        min-width: 80px !important;
        font-size: 12px !important;
        padding: 6px 8px !important;
        order: 1;
    }
    
    /* Show mobile navigation button */
    .mobile-nav-btn {
        display: flex;
        order: 2;
    }
    
    /* Hide sidebar toggle button for mobile and tablets */
    .sidebar-toggle-btn {
        display: none !important;
    }
    
    .brand-text {
        display: none;
    }
    
    /* COMPLETELY HIDE SIDEBAR FOR MOBILE AND TABLETS */
    .leaflet-sidebar,
    #sidebar,
    .sidebar-close-control,
    .sidebar-expand-btn,
    .mobile-sidebar-overlay {
        display: none !important;
    }
    
    /* Ensure map container takes full width */
    #map {
        width: 100vw !important;
        height: calc(100vh - 60px) !important;
        margin-left: 0 !important;
        position: relative !important;
    }
    
    /* Fix main content layout for full-width */
    #main-content {
        width: 100vw !important;
        margin-left: 0 !important;
        height: calc(100vh - 60px) !important;
        display: block !important;
    }
}

/* Mobile Navigation Panel (opened via hamburger) */
@media (max-width: 1024px) {
    .mobile-nav-panel {
        position: fixed;
        top: 60px;
        right: -100%;
        width: 280px;
        max-width: 90vw;
        height: auto;
        max-height: calc(100vh - 120px);
        background: var(--gradient-dark);
        border: 2px solid var(--border-accent);
        border-radius: 0 0 0 12px;
        padding: 20px;
        transition: right 0.3s ease;
        z-index: 500001;
        box-shadow: -4px 4px 20px rgba(0, 0, 0, 0.4);
        overflow-y: auto;
    }
    
    .mobile-nav-panel.active {
        right: 0;
    }
    
    .mobile-nav-panel .nav-btn {
        width: 100%;
        justify-content: flex-start;
        padding: 12px 16px;
        font-size: 16px;
        border-radius: 8px;
        margin-bottom: 12px;
    }
    
    .mobile-nav-panel .nav-btn span {
        display: inline;
    }
}

@media (max-width: 480px) {
    .current-page-info {
        flex-direction: column;
        gap: 4px;
        padding: 6px 10px;
    }
    
    /* Adjust mobile navigation for small screens */
    .nav-actions {
        gap: 6px !important;
    }
    
    .nav-actions .difficulty-dropdown {
        min-width: 70px !important;
        font-size: 11px !important;
        padding: 4px 6px !important;
    }
    
    .mobile-nav-btn {
        width: 36px !important;
        height: 36px !important;
    }
    
    .hamburger-line {
        width: 18px !important;
    }
    
    /* Ensure mobile nav panel fits small screens */
    .mobile-nav-panel {
        width: 260px !important;
        max-width: 85vw !important;
    }
    
    /* COMPLETELY HIDE SIDEBAR ON SMALL MOBILE */
    .leaflet-sidebar,
    #sidebar,
    .sidebar-close-control,
    .sidebar-expand-btn,
    .mobile-sidebar-overlay,
    .sidebar-toggle-btn {
        display: none !important;
    }
    
    /* Ensure full-width map on small mobile */
    #map {
        width: 100vw !important;
        height: calc(100vh - 60px) !important;
        margin-left: 0 !important;
    }
    
    #main-content {
        width: 100vw !important;
        margin-left: 0 !important;
        display: block !important;
    }
    
    /* Hide top ad on small mobile portraits too */
    .top-ad {
        display: none !important;
    }
}


/* Ad Spaces */
.ad-space {
    width: 100%;
    padding: 10px;
    text-align: center;
    border: 2px solid;
    background: var(--bg-panel);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    cursor: pointer;
    flex-shrink: 0; /* Prevent shrinking */
    max-height: 125px; /* Limit maximum height */
    min-height: 50px;  /* Ensure minimum height */
    overflow: hidden;  /* Hide content that exceeds max height */
    display: flex;
    justify-content: center;
    align-items: center;
}

.ad-space:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-orange);
}

/* Ensure AdSense containers respect the height limits */
.ad-space .adsbygoogle {
    max-height: 150px !important;
    overflow: hidden;
    width: 100%;
}

.top-ad {
    z-index: 10001;
    max-height: 125px; /* Specific limit for top ad */
    border-color: var(--secondary-color);
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.2), rgba(255, 107, 53, 0.1));
    margin-top: 65px; /* Account for fixed navbar */
}

.top-ad:hover {
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.3), rgba(255, 107, 53, 0.2));
    border-color: var(--accent-color);
}

.bottom-ad {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(255, 140, 0, 0.2), rgba(255, 140, 0, 0.1));
    margin-top: auto; /* Push to bottom of flex container */
    position: relative;
    z-index: 1000;
    flex-shrink: 0; /* Prevent shrinking */
    max-height: 150px; /* Specific limit for bottom ad */
}

.bottom-ad:hover {
    background: linear-gradient(135deg, rgba(255, 140, 0, 0.3), rgba(255, 140, 0, 0.2));
    border-color: var(--accent-color);
}

/* Remove above-map class as it's no longer needed */

.ad-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
}

.ad-content h3 {
    margin: 0 0 8px 0;
    color: var(--text-primary);
    font-size: 18px;
}

.top-ad .ad-content h3 {
    color: var(--secondary-color);
}

.bottom-ad .ad-content h3 {
    color: var(--primary-color);
}

.ad-content p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 14px;
}

/* Main Content Area */
#main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative;
    min-height: 0; /* Important for flex child */
    height: 100%;
    overflow: hidden; /* Prevent scrollbars in main content */
}

/* Map container */
#map {
    flex: 1;
    min-height: 0; /* Allow flexbox to shrink the map */
    width: 100%;
    background: var(--bg-dark);
    /* Ensure background color shows outside map bounds */
    background-color: var(--bg-dark) !important;
    overflow: hidden;
}

/* Leaflet map container background */
.leaflet-container {
    background: var(--secondary-color) !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 14px;
}

/* Leaflet tile layer background */
.leaflet-layer {
    background: var(--secondary-color);
}

/* Ensure map panes have colored background outside image bounds */
.leaflet-pane,
.leaflet-tile-pane,
.leaflet-overlay-pane {
    background: var(--secondary-color) !important;
}

/* Modern Vertical Sidebar Styles with Animations */

.leaflet-sidebar {
    top: 120px !important;
    margin-top: 25px;
    position: fixed;
    /* top: 60px;  */
    left: 0;
    width: 60px; /* Collapsed width for icons */
    height: calc(100vh - 220px); /* Account for navbar and bottom ad */
    background: var(--bg-panel);
    border-right: 2px solid var(--primary-color);
    box-shadow: var(--shadow-orange);
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(10px);
    border-radius: 0 12px 12px 0;
    overflow: hidden;
}

.leaflet-sidebar:hover {
    box-shadow: 0 4px 20px rgba(255, 140, 0, 0.4);
}

.leaflet-sidebar:not(.collapsed) {
    width: 450px;
    box-shadow: 0 4px 30px rgba(255, 140, 0, 0.3);
    z-index: 10;
}

.leaflet-sidebar.collapsed {
    width: 80px;
    z-index: 10;
}

/* Add animation class for smoother sidebar opening */
.sidebar-opening {
    animation: slideInFromLeft 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.sidebar-closing {
    animation: slideOutToLeft 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes slideInFromLeft {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

@keyframes slideOutToLeft {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-100%);
    }
}

/* Remove old sidebar expand button - using modern always-visible sidebar */

/* Modern Vertical Sidebar Tabs */
.leaflet-sidebar-tabs {
    background: transparent;
    border: none;
    padding: 20px 0;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    position: relative;
    z-index: 1001;
    width: 60px;
    border-bottom: 1px solid var(--border-color);
}

.leaflet-sidebar-tabs ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
     gap: 12px;
     width: 60%;
    align-items: center; 
}

.leaflet-sidebar-tabs li {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.leaflet-sidebar-tabs a {
    display: flex;
    width: 48px;
    height: 48px;
    background: var(--bg-darker);
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 14px;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.leaflet-sidebar-tabs a:hover {
    background: var(--bg-light);
    color: var(--primary-color);
    border-color: var(--primary-color);
    /* transform: scale(1.08); */
    box-shadow: var(--shadow-orange);
}

.leaflet-sidebar-tabs li.active a {
    background: var(--gradient-primary);
    color: var(--text-primary);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-orange);
    transform: scale(1.05);
}

/* Tooltip for collapsed sidebar */
.leaflet-sidebar-tabs a::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 55px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--bg-darker);
    color: var(--text-primary);
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    z-index: 10001;
    box-shadow: var(--shadow-orange);
}

.leaflet-sidebar.collapsed .leaflet-sidebar-tabs a:hover::after {
    opacity: 1;
    visibility: visible;
}

/* Modern Sidebar Content */
.leaflet-sidebar-content {
    flex: 1;
    overflow: hidden;
    position: absolute;
    left: 60px; /* Position content next to tabs */
    top: 0;
    width: 390px; /* Adjust width to account for tab space */
    height: 100%;
    background: var(--bg-panel);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) 0.1s;
    transform: translateX(-100%);
    border-left: 2px solid var(--primary-color);
    border-radius: 0 12px 12px 0;
    box-shadow: 2px 0 20px rgba(0, 0, 0, 0.3);
}

/* Independent Sidebar Close Control - Slides with Sidebar */
.sidebar-close-control {
    position: fixed;
    top: 50%;
    left: 60px; /* Start at sidebar collapsed width */
    transform: translateY(-50%);
    z-index: 1003;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: auto;
}

.sidebar-close-control.visible {
    opacity: 1;
    visibility: visible;
    left: 460px;
    bottom: -50px;
}

.sidebar-text{
    margin-right: 90px;
}

.sidebar-text2{
    margin-right: 150px;
}

.sidebar-text3{
    margin-right: 65px;
}

.sidebar-close-btn {
    width: 36px;
    height: 36px;
    background: var(--bg-panel) !important;
    border: 2px solid var(--primary-color) !important;
    border-radius: 6px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
    color: var(--primary-color) !important;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-orange) !important;
    backdrop-filter: blur(10px);
    text-decoration: none;
    line-height: 1;
}

.sidebar-close-btn:hover {
    background: rgba(255, 140, 0, 0.1) !important;
    color: var(--accent-color) !important;
    border-color: var(--accent-color) !important;
    transform: scale(1.05);
}

.leaflet-sidebar:not(.collapsed) .leaflet-sidebar-content {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateX(0) !important;
}

.leaflet-sidebar-pane {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-panel);
    color: var(--text-primary);
    display: none;
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
}

.leaflet-sidebar-pane.active {
    display: flex;
}

/* Custom scrollbar for sidebar content */
.leaflet-sidebar-pane::-webkit-scrollbar {
    width: 6px;
}

.leaflet-sidebar-pane::-webkit-scrollbar-track {
    background: var(--bg-darker);
    border-radius: 3px;
}

.leaflet-sidebar-pane::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 3px;
}

.leaflet-sidebar-pane::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}

.leaflet-sidebar-pane h1,
.leaflet-sidebar-pane h2,
.leaflet-sidebar-pane h3,
.leaflet-sidebar-pane h4,
.leaflet-sidebar-pane h5,
.leaflet-sidebar-pane h6 {
    color: #00ff88;
}

/* Marker cluster styles */
.marker-cluster-small {
    background-color: rgba(0, 255, 136, 0.6);
}

.marker-cluster-small div {
    background-color: rgba(0, 255, 136, 0.8);
    color: #001428;
}

.marker-cluster-medium {
    background-color: rgba(0, 255, 136, 0.6);
}

.marker-cluster-medium div {
    background-color: rgba(0, 255, 136, 0.8);
    color: #001428;
}

.marker-cluster-large {
    background-color: rgba(0, 255, 136, 0.6);
}

.marker-cluster-large div {
    background-color: rgba(0, 255, 136, 0.8);
    color: #001428;
}

/* Popup styles */
.leaflet-popup-content-wrapper {
    background: var(--bg-panel);
    color: var(--text-primary);
    border: 1px solid var(--primary-color);
    border-radius: 8px;
    z-index: 5000 !important;
}

.leaflet-popup-content {
    color: var(--text-primary);
    margin: 15px;
}

.leaflet-popup-tip {
    background: var(--bg-panel);
    border: 1px solid var(--primary-color);
}

/* Ensure popup container has proper z-index */
.leaflet-popup {
    z-index: 5000 !important;
}

.leaflet-popup-pane {
    z-index: 5000 !important;
}

/* Marker Tooltip Styles */
.leaflet-tooltip {
    background: var(--bg-panel) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--primary-color) !important;
    border-radius: 6px !important;
    box-shadow: var(--shadow-orange) !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    padding: 6px 10px !important;
    white-space: nowrap !important;
    backdrop-filter: blur(10px) !important;
    z-index: 6000 !important;
}

.leaflet-tooltip::before {
    border-top-color: var(--primary-color) !important;
}

.marker-tooltip {
    background: var(--bg-panel) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--primary-color) !important;
    border-radius: 6px !important;
    box-shadow: var(--shadow-orange) !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif !important;
}

/* Sidebar list styles */
.collectibles_list {
    display: grid;
    grid-template-columns: repeat(2, auto);
    gap: 5px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.collectibles_list li {
    display: flex;
    align-items: center;
    padding: 5px;
    border: 1px solid rgba(255, 140, 0, 0.3);
    border-radius: 4px;
    background: rgba(255, 140, 0, 0.05);
}

.collectibles_list li:hover {
    background: rgba(255, 140, 0, 0.1);
    border-color: var(--primary-color);
}

.collectibles_list input[type="checkbox"] {
    margin-right: 8px;
    accent-color: var(--primary-color);
}

.collectibles_list label {
    color: var(--text-primary);
    cursor: pointer;
    flex-grow: 1;
}

.collectibles_list button {
    background: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    padding: 2px 6px;
    border-radius: 3px;
    cursor: pointer;
    margin-left: 5px;
    transition: all 0.3s ease;
}

.collectibles_list button:hover {
    background: rgba(255, 140, 0, 0.2);
}

/* Map marker ping animation */
.map-marker-ping {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: ping 2s infinite;
    z-index: -1;
}

@keyframes ping {
    0% {
        transform: translate(-50%, -50%) scale(0.5);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(2);
        opacity: 0;
    }
}

/* Sidebar image icons */
.sidebar-image {
    width: 24px;
    height: 24px;
    object-fit: contain;
    filter: brightness(0) saturate(100%) invert(59%) sepia(86%) saturate(2067%) hue-rotate(14deg) brightness(101%) contrast(101%);
}

/* Controls */
.leaflet-control-layers {
    display: none;
    background: var(--bg-panel);
    border: 1px solid var(--primary-color);
    border-radius: 8px;
    color: var(--text-primary);
}

.leaflet-control-layers-expanded {
    color: var(--text-primary);
}

.leaflet-control-layers label {
    color: var(--text-primary);
}

.leaflet-control-zoom {
    z-index: 1002 !important;
}

.leaflet-control-zoom a {
    background: var(--bg-panel) !important;
    border: 1px solid var(--primary-color) !important;
    color: var(--primary-color) !important;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-orange);
}

.leaflet-control-zoom a:hover {
    background: rgba(255, 140, 0, 0.1) !important;
    color: var(--accent-color) !important;
    border-color: var(--accent-color) !important;
    transform: scale(1.05);
}

/* Dynamic positioning based on sidebar state */
.leaflet-top.leaflet-left {
    top: 80px !important; /* Below navbar */
    left: 160px !important; /* Account for collapsed sidebar */
    z-index: 1002 !important;
    transition: left 0.3s ease;
}

/* When sidebar is expanded */
.leaflet-sidebar:not(.collapsed) ~ #map .leaflet-top.leaflet-left {
    left: 560px !important;
}

/* Ensure all Leaflet controls have proper z-index and are clickable */
.leaflet-control {
    z-index: 1002 !important;
    pointer-events: auto !important;
}

/* Make sure map controls container has proper positioning */
.leaflet-control-container {
    pointer-events: none;
}

.leaflet-control-container .leaflet-control {
    pointer-events: auto;
}

/* Map container */
#map {
    height: 100vh;
    width: 100%;
    background: #001428;
}

@media (max-width: 1000px) and (max-height: 600px) {
        .leaflet-top.leaflet-left {
        top: 180px !important; /* Below navbar */
        left: 0px !important; /* Account for collapsed sidebar */
    }
}

@media (max-width: 1000px) and (max-height: 350px) {
        .leaflet-top.leaflet-left {
        top: 130px !important; /* Below navbar */
        left: 0px !important; /* Account for collapsed sidebar */
    }
}


/* Mobile-First Responsive Design */
@media (max-width: 767px) {
    .leaflet-sidebar {
        width: 50px !important; /* Smaller on mobile */
        height: calc(100vh - 140px) !important; /* Account for navbar and bottom ad */
        border-radius: 0 8px 8px 0 !important;
    }
    
    .leaflet-sidebar:not(.collapsed) {
        width: 100vw !important;
        border-radius: 0 !important;
        box-shadow: 0 0 30px rgba(0, 0, 0, 0.5) !important;
    }
    
    /* Mobile close button positioning - slides with sidebar */
    .sidebar-close-control {
        left: 50px !important; /* Start at mobile sidebar collapsed width */
    }
    
    .sidebar-close-control.visible {
        left: calc(100vw - 46px) !important; /* Right edge of full-width mobile sidebar */
        top: 15px !important; /* Move to top area on mobile */
        transform: none !important;
    }
    
    .sidebar-close-btn {
        width: 32px !important;
        height: 32px !important;
        font-size: 16px !important;
        border-radius: 4px !important;
    }
    
    .leaflet-sidebar-tabs {
        padding: 12px 0 !important;
        gap: 8px !important;
    }
    
    .leaflet-sidebar-tabs li {
        width: 40px !important;
        height: 40px !important;
    }
    
    .leaflet-sidebar-tabs a {
        width: 40px !important;
        height: 40px !important;
        font-size: 16px !important;
        border-radius: 10px !important;
    }
    
    /* Mobile zoom controls positioning */
    .leaflet-top.leaflet-left {
        top: 100px !important; /* Below navbar */
        left: 0px !important; /* Account for collapsed sidebar */
    }
    
    .leaflet-sidebar:not(.collapsed) ~ #map .leaflet-top.leaflet-left {
        left: 10px !important;
        top: 70px !important;
    }
    
    /* Mobile floor and grid controls - above bottom ad */
    .floor-control-container:not(.leaflet-control) {
        bottom: 70px !important; /* Above bottom ad */
        right: 10px !important;
        scale: 0.85;
    }
    
    .grid-display-container:not(.leaflet-control) {
        top: 10px;
        right: 10px !important;
        scale: 0.85;
    }
    
    /* Mobile sidebar content */
    .leaflet-sidebar-header {
        padding: 16px 20px !important;
        font-size: 16px !important;
    }
    
    .leaflet-sidebar-pane > div {
        padding: 20px !important;
    }
    
    /* Tooltips disabled on mobile */
    .leaflet-sidebar-tabs a::after {
        display: none !important;
    }
    
    /* Mobile main content adjustment */
    #main-content {
        height: calc(100vh - 130px) !important; /* Account for mobile layout */
    }
}

/* Mobile Portrait Orientation - Hide position panel and adjust top banner */
@media (max-width: 1024px) and (orientation: portrait) {
    /* COMPLETELY HIDE SIDEBAR ON MOBILE AND TABLETS */
    .leaflet-sidebar,
    #sidebar,
    .sidebar-close-control,
    .sidebar-expand-btn,
    .mobile-sidebar-overlay {
        display: none !important;
    }
    
    /* Hide sidebar toggle button in navigation */
    .sidebar-toggle-btn {
        display: none !important;
    }
    
    /* Hide position/coordinate displays in portrait */
    .grid-display-container:not(.leaflet-control),
    #current-position,
    .coordinate-display,
    .position-control {
        display: none !important;
    }
    
    /* HIDE TOP AD BANNER IN PORTRAIT MODE */
    .top-ad {
        display: none !important;
    }
    
    /* Adjust layout heights for full-width map without top ad */
    #map {
        width: 100vw !important;
        height: calc(100vh - 60px) !important; /* Only navbar height */
        margin-left: 0 !important;
        position: relative !important;
    }
    
    #main-content {
        width: 100vw !important;
        margin-left: 0 !important;
        height: calc(100vh - 60px) !important; /* Only navbar height */
        display: block !important;
    }
    
    /* Position mobile nav panel above any remaining ads */
    .nav-actions {
        z-index: 10001 !important; /* Above ad banners */
    }
}

/* Mobile Landscape Orientation - Hide bottom ad and position panel */
@media (max-width: 1024px) and (orientation: landscape), 
       (max-height: 600px) and (max-width: 1200px) {
    /* COMPLETELY HIDE SIDEBAR ON MOBILE AND TABLETS */
    .leaflet-sidebar,
    #sidebar,
    .sidebar-close-control,
    .sidebar-expand-btn,
    .mobile-sidebar-overlay {
        display: none !important;
    }
    
    /* Hide sidebar toggle button in navigation */
    .sidebar-toggle-btn {
        display: none !important;
    }
    
    /* Hide bottom ad panel in landscape */
    .bottom-ad {
        display: none !important;
    }
    
    /* Hide position/coordinate displays in landscape */
    .grid-display-container:not(.leaflet-control),
    #current-position,
    .coordinate-display,
    .position-control {
        display: none !important;
    }
    
    /* Adjust layout heights without bottom ad */
    #map {
        width: 100vw !important;
        height: calc(100vh - 60px) !important;
        margin-left: 0 !important;
        position: relative !important;
    }
    
    #main-content {
        width: 100vw !important;
        margin-left: 0 !important;
        height: calc(100vh - 60px) !important;
        display: block !important;
    }
    
    /* Adjust floor controls to bottom without ad spacing */
    .floor-control-container:not(.leaflet-control) {
        bottom: 10px !important;
        right: 10px !important;
    }
    
    /* Reduce top ad size in landscape for more map space */
    .top-ad {
        padding: 6px 0 !important;
    }
    
    .top-ad .ad-content h3 {
        font-size: 12px !important;
        margin-bottom: 2px !important;
    }
    
    .top-ad .ad-content p {
        font-size: 10px !important;
    }
}

/* Additional tablet-specific rules */
@media (min-width: 150px) and (max-width: 1024px) {
    /* COMPLETELY HIDE SIDEBAR ON TABLETS */
    .leaflet-sidebar,
    #sidebar,
    .sidebar-close-control,
    .sidebar-expand-btn,
    .mobile-sidebar-overlay {
        display: none !important;
    }
    
    /* Hide sidebar toggle button in navigation */
    .sidebar-toggle-btn {
        display: none !important;
    }
    
    /* Full-width layout for tablets */
    #map {
        width: 100vw !important;
        margin-left: 0 !important;
    }
    
    #main-content {
        width: 100vw !important;
        margin-left: 0 !important;
        display: block !important;
    }
}

/* Desktop layout - show sidebar and normal layout */
@media (min-width: 1025px) {
    /* Hide mobile navigation elements on desktop */
    .mobile-nav-btn,
    .mobile-nav-panel {
        display: none !important;
    }
    
    /* Show sidebar on desktop */
    .leaflet-sidebar,
    #sidebar,
    .sidebar-close-control,
    .sidebar-toggle-btn {
        display: block !important;
    }
    
    /* Normal desktop navigation layout */
    .nav-actions {
        position: static !important;
        flex-direction: row !important;
        width: auto !important;
        height: auto !important;
        background: transparent !important;
        border: none !important;
        border-radius: 0 !important;
        padding: 0 !important;
        gap: 8px !important;
        box-shadow: none !important;
        transition: none !important;
        order: initial !important;
    }
    
    .nav-actions .nav-btn {
        display: flex !important;
        width: auto !important;
        justify-content: center !important;
        padding: 8px 12px !important;
        font-size: 13px !important;
        border-radius: 6px !important;
        order: initial !important;
    }
    
    .nav-actions .difficulty-dropdown {
        display: block !important;
        width: auto !important;
        padding: 8px 12px !important;
        font-size: 13px !important;
        border-radius: 6px !important;
        order: initial !important;
    }
    
    .brand-text {
        display: inline !important;
    }
    
    /* Show top ad on desktop */
    .top-ad {
        display: block !important;
    }
}

@media (max-width: 480px) {
    .ad-content h3 {
        font-size: 14px;
    }
    
    .ad-content p {
        font-size: 11px;
    }
}

/* Custom marker icons */
.custom-div-icon {
    background: transparent;
    border: none;
    text-align: center;
}

/* Floor selector (if needed) */
.floor-selector {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 1000;
    background: rgba(0, 20, 40, 0.95);
    border: 1px solid #00ff88;
    border-radius: 8px;
    padding: 10px;
    color: #ffffff;
}

.floor-selector select {
    background: rgba(0, 20, 40, 0.95);
    border: 1px solid #00ff88;
    color: #ffffff;
    padding: 5px;
    border-radius: 4px;
}

.floor-selector select option {
    background: rgba(0, 20, 40, 0.95);
    color: #ffffff;
}

/* Enhanced UI Components */
.control-btn {
    background: rgba(255, 140, 0, 0.1);
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 4px;
    font-family: inherit;
}

.control-btn:hover {
    background: rgba(255, 140, 0, 0.2);
    transform: translateY(-1px);
    box-shadow: var(--shadow-orange);
}

.control-btn.primary {
    background: var(--gradient-primary);
    color: var(--text-primary);
}

.control-btn.primary:hover {
    background: var(--gradient-secondary);
}

.control-btn.danger {
    border-color: #ff4444;
    color: #ff4444;
    background: rgba(255, 68, 68, 0.1);
}

.control-btn.danger:hover {
    background: rgba(255, 68, 68, 0.2);
}

/* Form Styling */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    color: var(--primary-color);
    margin-bottom: 5px;
    font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    background: var(--bg-darker);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(255, 140, 0, 0.2);
}

.form-group textarea {
    resize: vertical;
    min-height: 60px;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

/* Filter Sections */
.filter-section {
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(255, 140, 0, 0.05);
    border: 1px solid rgba(255, 140, 0, 0.2);
    border-radius: 6px;
}

.filter-section h3 {
    color: var(--primary-color);
    margin: 0 0 10px 0;
    font-size: 16px;
}

.filter-controls {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    justify-content: center;
}

/* Coordinate Display */
.coordinate-display {
    background: rgba(255, 140, 0, 0.05);
    border: 1px solid rgba(255, 140, 0, 0.2);
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
}

.coord-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 10px;
}

.coord-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg-darker);
    padding: 10px;
    border-radius: 4px;
    border: 1px solid rgba(255, 140, 0, 0.3);
}

.coord-item label {
    color: var(--primary-color);
    font-weight: bold;
    min-width: 20px;
}

.coord-item span {
    color: var(--text-primary);
    font-family: monospace;
    font-size: 16px;
}

.coordinate-tools {
    margin-bottom: 20px;
}

.goto-coords {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.goto-coords input {
    flex: 1;
}

/* Floor Selection */
.floors-container {
    padding: 10px;
}

.floor-info {
    background: rgba(255, 140, 0, 0.05);
    border: 1px solid rgba(255, 140, 0, 0.2);
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
}

.floor-selector-container {
    margin-bottom: 20px;
}

.floor-selector-container label {
    display: block;
    color: var(--primary-color);
    margin-bottom: 8px;
    font-weight: 500;
}

.floor-selector-container select {
    width: 100%;
    background: var(--bg-darker);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 10px;
    border-radius: 4px;
    font-size: 14px;
    font-family: inherit;
}

.floor-preview {
    background: var(--bg-darker);
    border: 1px solid rgba(255, 140, 0, 0.3);
    border-radius: 6px;
    padding: 15px;
}

#current-floor-info strong {
    color: var(--primary-color);
    display: block;
    margin-bottom: 8px;
}

/* Marker Controls */
.marker-controls {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    justify-content: center;
}

/* Create Instructions */
.create-instructions {
    background: rgba(255, 140, 0, 0.1);
    border: 1px solid var(--primary-color);
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
    text-align: center;
}

.create-instructions i {
    color: var(--primary-color);
    margin-right: 8px;
}

/* Custom Markers List */
#custom-markers-list {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 140, 0, 0.3);
}

#custom-markers-list h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.custom-marker-item {
    background: var(--bg-darker);
    border: 1px solid rgba(255, 140, 0, 0.3);
    border-radius: 4px;
    padding: 10px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.custom-marker-info {
    flex: 1;
}

.custom-marker-info strong {
    color: var(--primary-color);
    display: block;
}

.custom-marker-info small {
    color: var(--text-secondary);
}

.custom-marker-actions {
    display: flex;
    gap: 5px;
}

.custom-marker-actions button {
    padding: 4px 8px;
    font-size: 12px;
}

/* Modern Sidebar Header */
.leaflet-sidebar-header {
    background: linear-gradient(135deg, rgba(255, 140, 0, 0.15), rgba(255, 107, 53, 0.08));
    border-bottom: 2px solid var(--primary-color);
    color: var(--primary-color);
    padding: 24px 28px;
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
    backdrop-filter: blur(15px);
    box-shadow: 0 2px 10px rgba(255, 140, 0, 0.1);
    letter-spacing: 0.5px;
}

.leaflet-sidebar-header i {
    margin-right: 12px;
    font-size: 22px;
    filter: drop-shadow(0 2px 4px rgba(255, 140, 0, 0.3));
}

.leaflet-sidebar-header .leaflet-sidebar-close {
    display: none !important; /* Hide the close button completely */
}

.leaflet-sidebar-pane > div {
    padding: 28px;
    padding-bottom: 170px; /* Increased bottom padding to account for bottom ad banner */
    background: var(--bg-panel);
    color: var(--text-primary);
    flex: 1;
    overflow-y: auto;
    line-height: 1.6;
}

/* Enhanced Mobile Responsive */
@media (max-width: 768px) {
    /* Mobile adjustments for ads - smaller on mobile */
    .ad-space {
        max-height: 100px; /* Smaller on mobile */
        min-height: 50px;
        padding: 5px;
    }
    
    .top-ad, .bottom-ad {
        max-height: 125px;
    }
    
    .ad-space .adsbygoogle {
        max-height: 100px !important;
    }

    .coord-info {
        grid-template-columns: 1fr;
    }
    
    .goto-coords {
        flex-direction: column;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .marker-controls,
    .filter-controls {
        flex-direction: column;
    }
    
    .control-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Marker Popup Styling */
.marker-popup {
    color: var(--text-primary);
}

.marker-popup h3 {
    color: var(--primary-color);
    margin: 0 0 10px 0;
    font-size: 16px;
}

.marker-popup p {
    margin: 0 0 10px 0;
    line-height: 1.4;
    color: var(--text-secondary);
}

.marker-details {
    display: flex;
    gap: 10px;
    margin: 10px 0;
}

.marker-type {
    background: rgba(255, 140, 0, 0.2);
    color: var(--primary-color);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    text-transform: capitalize;
}

.marker-rarity {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    text-transform: capitalize;
    font-weight: bold;
}

.marker-rarity.common {
    background: rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
}

.marker-rarity.rare {
    background: rgba(0, 136, 255, 0.2);
    color: #0088ff;
}

.marker-rarity.epic {
    background: rgba(136, 0, 255, 0.2);
    color: #8800ff;
}

.marker-rarity.legendary {
    background: rgba(255, 140, 0, 0.3);
    color: var(--accent-color);
}

.marker-coords {
    margin: 10px 0;
    padding: 8px;
    background: var(--bg-darker);
    border-radius: 4px;
    border: 1px solid rgba(255, 140, 0, 0.3);
}

.marker-coords small {
    color: var(--text-muted);
    font-family: monospace;
}

.delete-marker-btn {
    background: rgba(255, 68, 68, 0.2);
    border: 1px solid #ff4444;
    color: #ff4444;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    margin-top: 10px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: all 0.3s ease;
}

.delete-marker-btn:hover {
    background: rgba(255, 68, 68, 0.3);
}

/* Checkbox styling in filters */
input[type="checkbox"] {
    accent-color: var(--primary-color);
}

/* Modern Layout with Bottom Ad Consideration */
#main-content {
    position: relative;
    height: calc(100vh - 120px); /* Account for navbar (60px) + bottom ad (60px) */
    display: flex;
}

#main-content #map {
    position: relative;
    z-index: 1;
    height: 100%;
    width: 100%;
    flex: 1;
}

/* Bottom ad positioning */
.bottom-ad {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 999 !important;
    margin-top: 0 !important;
}

/* Override sidebar-enhancements styles to fix display issues */
.leaflet-sidebar-tabs {
    background: var(--bg-darker) !important;
    border-bottom: 2px solid var(--primary-color) !important;
    padding: 10px !important;
    flex-shrink: 0 !important;
}

.leaflet-sidebar-content {
    flex: 1 !important;
    overflow: hidden !important;
    position: absolute !important;
    left: 60px !important;
    top: 0 !important;
    width: 390px !important;
    height: 100% !important;
    background: var(--bg-panel) !important;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease 0.1s;
    transform: translateX(-100%);
    border-left: 2px solid var(--primary-color);
    z-index: 1000;
}

.leaflet-sidebar-pane {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: var(--bg-panel) !important;
    color: var(--text-primary) !important;
    display: none !important;
    flex-direction: column !important;
}

.leaflet-sidebar-pane.active {
    display: flex !important;
}

/* Fix for sidebar header */
.leaflet-sidebar-header {
    background: rgba(255, 140, 0, 0.1) !important;
    border-bottom: 1px solid var(--primary-color) !important;
    color: var(--primary-color) !important;
    padding: 15px 20px !important;
    margin: 0 !important;
    font-size: 18px !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    flex-shrink: 0 !important;
}


.floor-control-container {
    z-index: 1001 !important;
}


.floor-control-container:not(.leaflet-control) {
    position: absolute;
    bottom: 175px !important;
    right: 190px !important;
    z-index: 1000;
    pointer-events: auto;
    transition: right 0.3s ease;
}

/* Dynamic positioning based on floor count */
.floor-control-container:not(.leaflet-control).floors-7-12 {
    right: 145px!important; /* 190 - 28.24 = 161.76 */
}

.floor-control-container:not(.leaflet-control).floors-13-18 {
    right: 133.52px !important; /* 190 - (28.24 * 2) = 133.52 */
}

.floor-control-container:not(.leaflet-control).floors-19-24 {
    right: 105.28px !important; /* 190 - (28.24 * 3) = 105.28 */
}

.floor-control-container:not(.leaflet-control).floors-25-30 {
    right: 77.04px !important; /* 190 - (28.24 * 4) = 77.04 */
}

.floor-control-container:not(.leaflet-control).floors-31-36 {
    right: 48.8px !important; /* 190 - (28.24 * 5) = 48.8 */
}

.floor-control-container:not(.leaflet-control).floors-37-plus {
    right: 20.56px !important; /* 190 - (28.24 * 6) = 20.56 */
}

@media (max-width: 1000px) and (max-height: 600px), 
    (max-width: 1024px) and (orientation: landscape) {
    .floor-control-container:not(.leaflet-control) {
     right: 5px !important;
     bottom: 75px !important;
    }
    
    /* Override all floor count classes on mobile landscape */
    .floor-control-container:not(.leaflet-control).floors-7-12,
    .floor-control-container:not(.leaflet-control).floors-13-18,
    .floor-control-container:not(.leaflet-control).floors-19-24,
    .floor-control-container:not(.leaflet-control).floors-25-30,
    .floor-control-container:not(.leaflet-control).floors-31-36,
    .floor-control-container:not(.leaflet-control).floors-37-plus {
     right: 5px !important;
     bottom: 75px !important;
    }

    .floor-btn{
            padding: 2px 6px!important;
    }
}
/* Mobile responsive adjustments */
@media (max-width: 808px) {
    .floor-control-container:not(.leaflet-control) {
        right: 5px !important;
        bottom: 75px !important;
    }
    
    /* Override all floor count classes on mobile */
    .floor-control-container:not(.leaflet-control).floors-7-12,
    .floor-control-container:not(.leaflet-control).floors-13-18,
    .floor-control-container:not(.leaflet-control).floors-19-24,
    .floor-control-container:not(.leaflet-control).floors-25-30,
    .floor-control-container:not(.leaflet-control).floors-31-36,
    .floor-control-container:not(.leaflet-control).floors-37-plus {
        right: 5px !important;
        bottom: 75px !important;
    }
}


.floor-control {
    background: var(--bg-panel);
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    padding: 8px;
    box-shadow: var(--shadow-orange);
    backdrop-filter: blur(10px);
}

.floor-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 12px;
    font-size: 14px;
}

.floor-buttons {
    display: grid;
    grid-template-columns: 1fr;
    gap: 4px;
    max-height: 240px; /* Limit height for many floors */
}

/* Multi-column layout classes for JavaScript to apply */
.floor-buttons.multi-column-2 {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(6, auto);
    grid-auto-flow: column;
}

.floor-buttons.multi-column-3 {
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-rows: repeat(6, auto);
    grid-auto-flow: column;
}

.floor-btn {
    background: var(--bg-darker);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    font-family: inherit;
    font-weight: 600;
    min-width: 32px;
    text-align: center;
}

.floor-btn:hover {
    background: var(--bg-light);
    border-color: var(--primary-color);
    color: var(--text-primary);
}

.floor-btn.active {
    background: var(--gradient-primary);
    border-color: var(--primary-color);
    color: var(--text-primary);
    font-weight: 700;
}

.floor-btn.active i {
    color: var(--text-primary);
}

/* Grid Controls Styling */
.grid-controls {
    margin-top: 15px;
    border-top: 1px solid var(--border-color);
    padding-top: 15px;
}

.grid-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 12px;
    font-size: 14px;
}

.grid-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.grid-toggle-btn {
    background: var(--bg-darker);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-family: inherit;
}

.grid-toggle-btn:hover {
    background: var(--bg-light);
    border-color: var(--accent-color);
    color: var(--text-primary);
}

.grid-toggle-btn.active {
    background: var(--gradient-accent);
    border-color: var(--accent-color);
    color: var(--bg-dark);
    font-weight: 600;
}

.grid-size-select {
    background: var(--bg-darker);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease;
}

.grid-size-select:hover {
    border-color: var(--accent-color);
    color: var(--text-primary);
}

.grid-size-select:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px rgba(255, 179, 71, 0.2);
}

/* Grid Overlay Styles */
.grid-line {
    pointer-events: none;
}

.grid-label {
    background: rgba(255, 140, 0, 0.1) !important;
    border: 1px solid var(--primary-color) !important;
    border-radius: 4px !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3) !important;
}

.grid-text {
    color: var(--primary-color) !important;
    font-weight: bold !important;
    font-size: 11px !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8) !important;
    display: block !important;
    text-align: center !important;
    line-height: 20px !important;
}

/* Grid Display Styling */
.grid-display-container {
    z-index: 1001 !important;
}

/* Independent grid display positioning (outside Leaflet controls) */
.grid-display-container:not(.leaflet-control) {
    position: absolute !important;
    top: 10px;
    right: 20px !important;
    z-index: 1000 !important;
    pointer-events: auto !important;
}

.grid-display {
    background: var(--bg-panel);
    border: 2px solid var(--secondary-color);
    border-radius: 8px;
    padding: 15px;
    min-width: 200px;
    box-shadow: var(--shadow-orange);
    backdrop-filter: blur(10px);
}

.grid-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.grid-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 14px;
}

.minimize-btn {
    align-self: flex-start;
    background: transparent;
    border: 1px solid var(--secondary-color);
    color: var(--secondary-color);
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

.minimize-btn:hover {
    background: var(--secondary-color);
    color: var(--bg-panel);
    transform: scale(1.05);
}

.grid-content {
    transition: all 0.3s ease;
}

.grid-coordinates {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 10px;
}

.grid-coordinates .coord-display:nth-child(3) {
    grid-column: 1 / -1;
}

.coord-display {
    background: var(--bg-darker);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.coord-label {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 12px;
}

.coord-value {
    color: var(--text-primary);
    font-family: monospace;
    font-size: 14px;
    font-weight: bold;
}

.grid-info {
    text-align: center;
    margin-top: 8px;
}

.grid-info small {
    color: var(--text-muted);
    font-size: 10px;
}

/* Ensure Leaflet controls are properly positioned */
.leaflet-bottom.leaflet-left {
    bottom: 10px !important;
    left: 10px !important;
}

.leaflet-control {
    margin: 5px !important;
}



/* Responsive adjustments for floor controls */
@media (max-width: 768px) {
    /* Mobile positioning for independent floor control */
    .floor-control-container:not(.leaflet-control) {
        bottom: 30px !important;
        right: 10px !important;
    }
    
    /* Mobile positioning for independent grid display */
    .grid-display-container:not(.leaflet-control) {
        top: 10px;
        right: 10px !important;
        min-width: 150px;
    }
    
    /* Ensure zoom controls are visible on mobile */
    .leaflet-sidebar:not(.collapsed) ~ #map .leaflet-top.leaflet-left {
        left: 10px !important;
        top: 10px !important;
    }
    
    /* Mobile sidebar expand button positioning */
    .sidebar-expand-btn {
        left: 15px !important;
        padding: 10px 6px !important;
        font-size: 16px !important;
    }
    
    /* Make sidebar full width on mobile */
    .leaflet-sidebar {
        width: 100vw !important;
        max-width: 100% !important;
    }
    
    .floor-control,
    .grid-display {
        padding: 8px;
    }
    
    .grid-display-container:not(.leaflet-control) .grid-display {
        padding: 8px;
        min-width: 150px;
    }
    
    .floor-title,
    .grid-title {
        font-size: 13px;
    }
    
    .floor-btn {
        padding: 6px 8px;
        font-size: 12px;
        min-width: 28px;
    }
    
    .grid-coordinates {
        gap: 8px;
    }
    
    .coord-display {
        padding: 6px;
    }
}

@media (max-width: 755px) {
    /* Mobile positioning for independent floor control */
    .floor-control-container:not(.leaflet-control) {
        bottom: 80px !important;
        right: 10px !important;
    }
}

@media (max-width: 705px) {
    /* Mobile positioning for independent floor control */
    .floor-control-container:not(.leaflet-control) {
        bottom: 80px !important;
        right: 10px !important;
    }
}
/* ===========================================
   ENHANCED CUSTOM MARKERS SYSTEM
   =========================================== */

/* Custom Markers Panel Styling */
.marker-creation-section {
    margin-bottom: 30px;
    padding: 20px;
    background: var(--bg-darker);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.create-instructions {
    background: rgba(255, 140, 0, 0.1);
    border: 1px solid var(--primary-color);
    border-radius: 6px;
    padding: 12px;
    margin-bottom: 20px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 13px;
}

.create-instructions i {
    color: var(--primary-color);
    margin-right: 8px;
}

.marker-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-row {
    display: flex;
    gap: 12px;
    width: 100%;
}

.form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.form-group.half-width {
    flex: 0.5;
}

.form-group label {
    color: var(--primary-color);
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea,
.form-group select {
    background: var(--bg-light);
    border: 2px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-primary);
    padding: 10px 12px;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(255, 140, 0, 0.2);
    background: var(--bg-panel);
}

.form-group textarea {
    resize: vertical;
    min-height: 50px;
    max-height: 100px;
}

.form-group input[type="color"] {
    width: 60px;
    height: 40px;
    padding: 2px;
    border-radius: 6px;
    cursor: pointer;
}

.marker-actions {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.marker-actions .control-btn {
    flex: 1;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 600;
}

/* Custom Markers List */
.custom-markers-list {
    background: var(--bg-darker);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: var(--bg-light);
    border-bottom: 1px solid var(--border-color);
}

.list-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 600;
}

.list-header span {
    color: var(--primary-color);
    font-weight: 700;
}

.list-actions .control-btn.small {
    padding: 6px 12px;
    font-size: 12px;
}

.markers-list {
    max-height: 300px;
    overflow-y: auto;
}

.no-markers {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}

.no-markers i {
    font-size: 32px;
    color: var(--border-color);
    margin-bottom: 12px;
    display: block;
}

.no-markers p {
    margin: 8px 0 4px 0;
    font-size: 16px;
    color: var(--text-secondary);
}

.no-markers small {
    font-size: 12px;
    color: var(--text-muted);
}

/* Individual Marker Items */
.marker-item {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    border-bottom: 1px solid var(--border-color);
    transition: background-color 0.2s ease;
}

.marker-item:hover {
    background: var(--bg-light);
}

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

.marker-icon-preview {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 3px solid;
    margin-right: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    color: white;
    font-weight: bold;
    flex-shrink: 0;
}

.marker-info {
    flex: 1;
    min-width: 0;
}

.marker-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 14px;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.marker-details {
    font-size: 11px;
    color: var(--text-muted);
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.marker-type-badge {
    background: rgba(255, 140, 0, 0.2);
    color: var(--primary-color);
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
}

.marker-actions-buttons {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

.marker-action-btn {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    width: 28px;
    height: 28px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 12px;
}

.marker-action-btn:hover {
    background: var(--bg-panel);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.marker-action-btn.delete:hover {
    background: rgba(255, 68, 68, 0.2);
    border-color: #ff4444;
    color: #ff4444;
}

/* Mobile responsive for custom markers */
@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
        gap: 12px;
    }
    
    .form-group.half-width {
        flex: 1;
    }
    
    .marker-actions {
        flex-direction: column;
    }
    
    .list-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .marker-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 16px 20px;
    }
    
    .marker-icon-preview {
        margin-right: 0;
    }
    
    .marker-actions-buttons {
        align-self: flex-end;
    }
}

/* Filter Section Styles */
.filters-section {
    margin-bottom: 20px;
    padding: 15px;
    background: var(--bg-panel);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.filters-section h3 {
    margin: 0 0 12px 0;
    color: var(--text-accent);
    font-size: 14px;
    font-weight: 600;
}

.filter-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    font-size: 13px;
}

.filter-checkbox:hover {
    background: var(--bg-light);
}

.filter-checkbox input[type="checkbox"] {
    margin-right: 8px;
    width: 16px;
    height: 16px;
    accent-color: var(--primary-color);
}

/* Difficulty Section Styles */
.difficulty-section {
    margin-bottom: 20px;
    padding: 15px;
    background: var(--bg-panel);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.difficulty-section h3 {
    margin: 0 0 12px 0;
    color: var(--text-accent);
    font-size: 14px;
    font-weight: 600;
}

.difficulty-buttons {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.difficulty-btn {
    padding: 8px 12px;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 12px;
    font-weight: 500;
}

.difficulty-btn:hover {
    background: var(--bg-darker);
    border-color: var(--border-accent);
}

.difficulty-btn.active {
    background: var(--gradient-primary);
    border-color: var(--primary-color);
    color: var(--bg-dark);
    font-weight: 600;
}

/* User Markers Section Styles */
.user-markers-section {
    margin-bottom: 20px;
    padding: 15px;
    background: var(--bg-panel);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.user-markers-section h3 {
    margin: 0 0 12px 0;
    color: var(--text-accent);
    font-size: 14px;
    font-weight: 600;
}

.action-btn {
    width: 100%;
    padding: 10px 15px;
    background: var(--gradient-primary);
    border: none;
    border-radius: 6px;
    color: var(--bg-dark);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.action-btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-orange);
}

.marker-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 10px;
}

.marker-form input,
.marker-form textarea {
    padding: 8px 10px;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-primary);
    font-size: 12px;
    font-family: inherit;
}

.marker-form input:focus,
.marker-form textarea:focus {
    outline: none;
    border-color: var(--border-accent);
    box-shadow: 0 0 0 2px rgba(255, 140, 0, 0.2);
}

.marker-form textarea {
    min-height: 60px;
    resize: vertical;
}

.form-actions {
    display: flex;
    gap: 8px;
}

.confirm-btn,
.cancel-btn {
    flex: 1;
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.confirm-btn {
    background: #28a745;
    color: white;
}

.confirm-btn:hover {
    background: #218838;
}

.cancel-btn {
    background: #dc3545;
    color: white;
}

.cancel-btn:hover {
    background: #c82333;
}

/* Marker Styles */
.custom-marker {
    background: transparent !important;
    border: none !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

.marker-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(0, 0, 0, 0.3);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.marker-icon img {
    width: 16px;
    height: 16px;
    object-fit: contain;
}

.marker-circle {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 3px solid;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
    position: relative;
    opacity: 0.9;
}

.marker-inner {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(0, 0, 0, 0.2);
}

.temp-marker {
    font-size: 24px;
    animation: pulse 1s infinite;
}

.temp-marker-icon {
    background: transparent !important;
    border: none !important;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}

/* Marker Popup Styles */
.marker-popup {
    min-width: 200px;
    max-width: 300px;
}

.marker-popup h4 {
    margin: 0 0 8px 0;
    color: var(--text-accent);
    font-size: 14px;
    font-weight: 600;
}

.marker-popup p {
    margin: 4px 0;
    font-size: 12px;
    color: var(--text-secondary);
}

.marker-type {
    font-weight: 500;
    color: var(--text-primary) !important;
}

.marker-coords {
    font-family: 'Courier New', monospace;
    color: var(--text-muted) !important;
}

.marker-description {
    font-style: italic;
    color: var(--text-secondary) !important;
    border-top: 1px solid var(--border-color);
    padding-top: 6px;
    margin-top: 6px;
}

.delete-marker-btn {
    background: #dc3545;
    color: white;
    border: none;
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 11px;
    cursor: pointer;
    margin-top: 8px;
    transition: background-color 0.2s ease;
}

.delete-marker-btn:hover {
    background: #c82333;
}

/* Type-specific marker styles */
.marker-type-spawn .marker-circle { border-color: #00ff00; }
.marker-type-loot .marker-circle { border-color: #ffff00; }
.marker-type-weapons .marker-circle { border-color: #ff8800; }
.marker-type-medical .marker-circle { border-color: #ff4444; }
.marker-type-extraction .marker-circle { border-color: #00ffff; }
.marker-type-entrance .marker-circle { border-color: #00ff00; }
.marker-type-objective .marker-circle { border-color: #ff0000; }
.marker-type-vehicle .marker-circle { border-color: #0000ff; }
.marker-type-danger .marker-circle { border-color: #aa0000; }
.marker-type-rare-loot .marker-circle { border-color: #ffd700; }
.marker-type-obstacle .marker-circle { border-color: #888888; }
.marker-type-user-marker .marker-circle { 
    border-color: var(--primary-color);
    border-width: 3px;
}
.leaflet-control-attribution{
    display: none;
}
.notification {
            position: fixed;
            top: 20px;
            right: 20px;
            z-index: 10000;
            background: var(--bg-panel);
            border: 2px solid;
            border-radius: 8px;
            padding: 12px 16px;
            transform: translateX(400px);
            transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
            box-shadow: var(--shadow-orange);
            max-width: 300px;
        }

        .notification.show {
            transform: translateX(0);
        }

        .notification-success {
            border-color: #28a745;
            background: linear-gradient(135deg, rgba(40, 167, 69, 0.1), rgba(40, 167, 69, 0.05));
        }

        .notification-error {
            border-color: #dc3545;
            background: linear-gradient(135deg, rgba(220, 53, 69, 0.1), rgba(220, 53, 69, 0.05));
        }

        .notification-info {
            border-color: var(--primary-color);
            background: linear-gradient(135deg, rgba(255, 140, 0, 0.1), rgba(255, 140, 0, 0.05));
        }

        .notification-content {
            display: flex;
            align-items: center;
            gap: 10px;
            color: var(--text-primary);
            font-size: 14px;
            font-weight: 500;
        }

        .notification-success .notification-content i {
            color: #28a745;
        }

        .notification-error .notification-content i {
            color: #dc3545;
        }

        .notification-info .notification-content i {
            color: var(--primary-color);
        }

        /* Custom marker badges */
        .marker-type-badge {
            background: var(--gradient-primary);
            color: var(--text-primary);
            padding: 2px 8px;
            border-radius: 12px;
            font-size: 11px;
            font-weight: 600;
            text-transform: capitalize;
        }

        .marker-floor-badge {
            background: linear-gradient(135deg, #17a2b8, #138496);
            color: white;
            padding: 2px 8px;
            border-radius: 12px;
            font-size: 11px;
            font-weight: 600;
            text-transform: capitalize;
        }

        .current-floor-indicator {
            margin-top: 8px;
            padding: 8px 12px;
            background: linear-gradient(135deg, rgba(23, 162, 184, 0.1), rgba(19, 132, 150, 0.05));
            border: 1px solid rgba(23, 162, 184, 0.3);
            border-radius: 6px;
            color: var(--text-primary);
            font-size: 13px;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .current-floor-indicator i {
            color: #17a2b8;
        }

        .current-floor-indicator strong {
            color: #17a2b8;
            font-weight: 700;
        }

        /* Settings tab styles */
        .data-info {
            background: var(--bg-light);
            border: 1px solid var(--border-color);
            border-radius: 6px;
            padding: 12px;
            margin-bottom: 16px;
            color: var(--text-secondary);
            font-size: 13px;
            line-height: 1.4;
        }

        .data-stats {
            background: var(--bg-darker);
            border: 1px solid var(--border-color);
            border-radius: 6px;
            padding: 12px;
            margin-top: 16px;
        }

        .stat-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 4px 0;
        }

        .stat-row:not(:last-child) {
            border-bottom: 1px solid var(--border-color);
            margin-bottom: 8px;
            padding-bottom: 8px;
        }

        .stat-label {
            color: var(--text-secondary);
            font-size: 13px;
        }

        .stat-value {
            color: var(--primary-color);
            font-weight: 600;
            font-size: 13px;
        }

        /* Floor selector styles */
        .floor-info-header {
            margin-bottom: 16px;
            text-align: center;
        }

        .floor-info-header h4 {
            margin: 0 0 8px 0;
            color: var(--primary-color);
            font-size: 16px;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
        }

        .floor-info-header .floor-description {
            margin: 0;
            color: #888888;
            font-size: 13px;
            line-height: 1.4;
        }

        .floor-selector-grid {
              scrollbar-color: #ffffff #555555;
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
            gap: 12px;
            margin-bottom: 20px;
            max-height: 400px;
            overflow-y: auto;
            padding: 4px;
        }

        .floor-select-btn {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 8px;
            padding: 16px 12px;
            background: #262626;
            border: 2px solid #555555;
            border-radius: 12px;
            color: #cccccc;
            cursor: pointer;
            transition: all 0.3s ease;
            font-size: 12px;
            font-weight: 600;
            position: relative;
            overflow: hidden;
            min-height: 80px;
        }

        .floor-select-btn:hover {
            background: #404040;
            border-color: #ff8c00;
            color: #ffffff;
            transform: translateY(-2px);
            box-shadow: 0 6px 16px rgba(255, 139, 71, 0.25);
        }

        .floor-select-btn.active {
            background: linear-gradient(135deg, #ff8c00, #ff6b35);
            border-color: #ff8c00;
            color: white;
            box-shadow: 0 6px 20px rgba(255, 139, 71, 0.4);
            transform: translateY(-1px);
        }

        .floor-btn-icon {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 6px;
        }

        .floor-btn-icon i {
            font-size: 20px;
        }

        .floor-label {
            font-size: 16px;
            font-weight: bold;
            background: rgba(255, 255, 255, 0.2);
            padding: 4px 10px;
            border-radius: 14px;
            min-width: 32px;
            text-align: center;
            line-height: 1;
        }

        .floor-select-btn.active .floor-label {
            background: rgba(255, 255, 255, 0.35);
            font-weight: 800;
        }

        .floor-btn-text {
            text-align: center;
            max-width: 100%;
            margin-top: 2px;
        }

        .floor-name {
            font-size: 10px;
            line-height: 1.2;
            opacity: 0.85;
            font-weight: 500;
        }

        .floor-select-btn.active .floor-name {
            opacity: 1;
            font-weight: 600;
        }

        .floor-info-display {
            background: #404040;
            border: 1px solid #555555;
            border-radius: 10px;
            padding: 18px;
            margin-top: 10px;
        }

        .current-floor-info h4 {
            margin: 0 0 12px 0;
            color: #ff8c00;
            font-size: 15px;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .current-floor-info h4 span {
            color: #ffffff;
            font-weight: 700;
        }

        .floor-stats {
            display: flex;
            align-items: center;
            gap: 8px;
            color: #888888;
            font-size: 13px;
            margin-top: 8px;
            padding-top: 8px;
            border-top: 1px solid #555555;
        }

        .floor-stats i {
            color: #ff8c00;
        }

        .floor-count {
            display: flex;
            align-items: center;
            gap: 6px;
        }

        .no-floors {
            text-align: center;
            color: #888888;
            font-style: italic;
            padding: 20px;
        }