html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    width: 100%;
    font-family: Arial, sans-serif;
    background: white;
}

.layout-container {
    display: flex;
    height: 100vh;
    width: 100vw;
}

.sidebar {
    padding: 10px;
    background: #f0f0f0;
    overflow-y: auto;
    width: 300px;
    flex-shrink: 0;
}

/* Mobile layout - for actual mobile devices in portrait */
@media (orientation: portrait) and (max-width: 768px) {
    .layout-container {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        height: 33.33vh;
        max-height: none;
        box-sizing: border-box;
        overflow-y: auto;
    }
    
    #map-container {
        flex: 1;
        height: auto;
    }
    
    #data-list {
        height: auto;
        max-height: calc(33.33vh - 200px);
        overflow-y: auto;
    }
}

.sidebar h3 {
    font-size: 14px;
    margin: 10px 0 5px 0;
    color: #000;
}

#fetchData {
    background: #c0c0c0;
    border: 2px outset #c0c0c0;
    padding: 5px 10px;
    cursor: pointer;
    font-size: 12px;
}

#fetchData:active {
    border: 2px inset #c0c0c0;
}

#status {
    font-size: 11px;
    color: #666;
}

hr {
    margin: 15px 0;
    border: 0;
    border-top: 1px solid #999;
}

#map-container {
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

#world-map {
    width: 100%;
    height: 100%;
    display: block;
}

.country {
    fill: #e0e0e0;
    stroke: #ffffff;
    stroke-width: 0.5px;
}

.country:hover {
    fill: #d0d0d0;
}

.data-point {
    cursor: pointer;
    shape-rendering: crispEdges; /* Note: different from image-rendering: crisp-edges */
}
  /* Firefox-specific fixes */
@-moz-document url-prefix() {
    .data-point {
      image-rendering: -moz-crisp-edges;
      /* transform-style: preserve-3d; */
      image-rendering: optimizeQuality;
      will-change: transform;
    }

    .connection-line {
      image-rendering: -moz-crisp-edges;
      /* transform-style: preserve-3d; */
      image-rendering: optimizeQuality;
      will-change: transform;
    }

    .emoji-fallback {
      display: inline; /* Show HTML emoji instead */
    }

    .svg-emoji {
      display: none; /* Hide broken SVG emoji */
    }
}

.data-point.highlighted {
    filter: brightness(1.3) drop-shadow(0px 0px 5px rgba(255,68,68,1));
}

#data-list {
    height: calc(100vh - 150px);
    overflow-y: auto;
    font-size: 11px;
}

.data-item {
    padding: 5px;
    border: 1px solid #999;
    margin-bottom: 2px;
    background: #f9f9f9;
    cursor: pointer;
}

.data-item:hover {
    background: #f0f0f0;
}

.data-item strong {
    color: #000080;
}

.error {
    background: #ffcccc;
    color: #cc0000;
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #cc0000;
    font-size: 11px;
}
