/* Orbis Da'at (NR1) — Globe & Map Styles */

/* CesiumJS overrides */
.cesium-viewer {
    position: absolute;
    inset: 0;
}

.cesium-viewer-bottom,
.cesium-viewer-toolbar,
.cesium-viewer-animationContainer,
.cesium-viewer-timelineContainer,
.cesium-viewer-fullscreenContainer {
    display: none !important;
}

.cesium-credit-logoContainer,
.cesium-credit-textContainer {
    opacity: 0.3 !important;
}

/* MapLibre GL overrides */
.maplibregl-map {
    position: absolute;
    inset: 0;
}

.maplibregl-ctrl-attrib {
    opacity: 0.3;
}

/* Custom marker styling */
.custom-marker {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.5);
    cursor: pointer;
    transition: transform 0.2s ease;
}

.custom-marker:hover {
    transform: scale(1.3);
}

.custom-marker.pulse {
    animation: markerPulse 2s ease-in-out infinite;
}

@keyframes markerPulse {
    0% { box-shadow: 0 0 0 0 currentColor; }
    50% { box-shadow: 0 0 0 10px transparent; }
    100% { box-shadow: 0 0 0 0 transparent; }
}

/* Cluster markers */
.cluster-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 700;
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    cursor: pointer;
}

.cluster-small { width: 32px; height: 32px; background: rgba(59, 130, 246, 0.8); }
.cluster-medium { width: 40px; height: 40px; background: rgba(245, 158, 11, 0.8); }
.cluster-large { width: 48px; height: 48px; background: rgba(239, 68, 68, 0.8); }

/* Map popup */
.map-popup {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px;
    max-width: 280px;
    color: var(--text-primary);
    font-size: 0.85rem;
}

.map-popup h4 {
    font-size: 0.9rem;
    margin-bottom: 6px;
    line-height: 1.3;
}

.map-popup .popup-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 6px;
}

.map-popup .popup-link {
    display: inline-block;
    margin-top: 8px;
    font-size: 0.8rem;
    color: var(--accent);
    font-weight: 500;
}

/* MapLibre popup override */
.maplibregl-popup-content {
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
    border-radius: 0 !important;
}

.maplibregl-popup-close-button {
    color: var(--text-secondary) !important;
    font-size: 1.2rem;
    right: 8px !important;
    top: 8px !important;
}

.maplibregl-popup-tip {
    border-top-color: var(--bg-card) !important;
}

/* Loading overlay */
.map-loading {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(10, 14, 26, 0.8);
    z-index: 100;
    transition: opacity 0.5s ease;
}

.map-loading.hidden { opacity: 0; pointer-events: none; }

.map-loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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