/* tracks.html styles */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; background: #1a1a2e; color: #eee; overflow: hidden; }
#map { height: 100vh; width: 100vw; }
.leaflet-control-layers { background: rgba(26, 26, 46, 0.95) !important; color: #eee !important; border: 1px solid #444 !important; border-radius: 8px !important; }
.leaflet-control-layers label { color: #eee; font-size: 13px; padding: 2px 0; }
.leaflet-control-layers-base label { font-weight: 600; }
.leaflet-control-layers-overlays label { cursor: pointer; }
.leaflet-control-layers-overlays input { margin-right: 6px; }
.leaflet-control-layers-separator { border-top: 1px solid #444 !important; }
.leaflet-control-layers-list { padding: 8px 12px; }
.year-badge {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 2px;
    margin-right: 6px;
    vertical-align: middle;
}
.side-panel {
    position: absolute;
    top: 10px;
    left: 50px;
    z-index: 1000;
    background: rgba(26, 26, 46, 0.95);
    border: 1px solid #444;
    border-radius: 8px;
    padding: 12px 16px;
    max-width: 220px;
    max-height: calc(100vh - 20px);
    font-size: 13px;
    overflow-y: auto;
}
.side-panel h2 { font-size: 15px; margin-bottom: 8px; color: #fff; }
.side-panel .stat { display: flex; justify-content: space-between; margin: 4px 0; }
.side-panel .stat-value { color: #7ec8e3; font-weight: 600; }
.track-summary { margin-top: 10px; padding-top: 10px; border-top: 1px solid #444; }
.track-item {
    display: flex;
    align-items: center;
    margin: 3px 0;
    font-size: 12px;
    cursor: pointer;
    gap: 6px;
}
.track-item .year-badge { width: 10px; height: 10px; flex-shrink: 0; }
.track-item .year-label { flex: 1; }
.track-item .track-meta { color: #aaa; margin-left: auto; white-space: nowrap; }
.track-item input[type="checkbox"] {
    margin-right: 6px;
    accent-color: #7ec8e3;
    cursor: pointer;
    flex-shrink: 0;
}
.track-item.disabled { opacity: 0.35; }

/* Popup styles */
.leaflet-popup {
    z-index: 2000 !important;
}
.leaflet-popup-content-wrapper {
    background: #1a1a2e;
    color: #eee;
    border-radius: 8px;
    border: 1px solid #444;
}
.leaflet-popup-tip {
    background: rgba(26, 26, 46, 0.98);
    border: 1px solid #444;
}
.leaflet-popup-content {
    margin: 12px;
    font-size: 13px;
    line-height: 1.5;
}
.leaflet-popup-content h3 {
    font-size: 14px;
    margin-bottom: 6px;
    color: #7ec8e3;
}
.leaflet-popup-content .popup-date {
    font-size: 11px;
    color: #aaa;
    margin-bottom: 8px;
}
.leaflet-popup-content .popup-text {
    margin-bottom: 8px;
    max-height: 150px;
    overflow-y: auto;
}
.leaflet-popup-content .popup-images {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    margin-top: 8px;
}
.leaflet-popup-content .popup-images img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
    cursor: pointer;
}
.leaflet-popup-content a {
    color: #7ec8e3;
    text-decoration: none;
}
.leaflet-popup-content a:hover {
    text-decoration: underline;
}
.leaflet-container a.leaflet-popup-close-button {
    color: #aaa;
    font-size: 18px;
    padding: 4px 8px;
}

/* Post marker icons (CSP-safe: styled by class, color via data attribute + JS) */
.post-marker-inner {
    font-size: 16px;
    text-align: center;
    line-height: 22px;
    border: 2px solid currentColor;
    border-radius: 3px;
    background: rgba(255,255,255,0.9);
    width: 24px;
    height: 24px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

/* Popup year badge (CSP-safe) */
.popup-year-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 2px;
    margin-right: 4px;
}

/* Popup footer (CSP-safe) */
.popup-footer {
    margin-top: 8px;
    font-size: 11px;
}
