/* Activity Map Styles */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* Reset and Base Styles */
.activity-map-container {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    display: flex;
    height: 100vh;
    background: #ffffff;
    overflow: hidden;
}

/* Activity List Panel */
.activity-list-panel {
    width: 33.333%;
    background: #ffffff;
    border-right: 1px solid #e5e7eb;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.activity-list-header {
    padding: 24px 20px 16px;
    border-bottom: 1px solid #e5e7eb;
    background: #ffffff;
}

.activity-list-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #1f2937;
    font-family: 'Inter', sans-serif;
}

.activity-list-content {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

.activity-list-items {
    padding: 0;
}

.activity-item {
    padding: 20px;
    border-bottom: 1px solid #e5e7eb;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #ffffff;
}

.activity-item:hover {
    background: #f9fafb;
}

.activity-item.selected {
    background: #f3f4f6;
    border-left: 4px solid #3b82f6;
}

.activity-category {
    font-size: 12px;
    font-weight: 600;
    color: #f97316;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    font-family: 'Inter', sans-serif;
}

.activity-title {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    line-height: 1.4;
    margin-bottom: 8px;
    font-family: 'Inter', sans-serif;
}

.activity-description {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
    margin-bottom: 12px;
    font-family: 'Inter', sans-serif;
}

.activity-location {
    display: flex;
    align-items: center;
    font-size: 14px;
    color: #374151;
    margin-bottom: 12px;
    font-family: 'Inter', sans-serif;
}

.location-icon {
    margin-right: 6px;
    font-size: 12px;
}

.activity-actions {
    margin-top: 12px;
}

.read-more-btn {
    background: #1e40af;
    color: #ffffff;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
}

.read-more-btn:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
}

.no-activities {
    padding: 40px 20px;
    text-align: center;
    color: #6b7280;
    font-size: 16px;
    font-family: 'Inter', sans-serif;
}

/* Map Panel */
.map-panel {
    flex: 1;
    position: relative;
    background: #f8fafc;
}

.map-canvas {
    width: 100%;
    height: 100%;
    position: relative;
}

.map-controls {
    position: absolute;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.map-zoom-controls {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.map-zoom-controls button {
    display: block;
    width: 40px;
    height: 40px;
    border: none;
    background: #ffffff;
    color: #374151;
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
}

.map-zoom-controls button:hover {
    background: #f3f4f6;
    color: #1f2937;
}

.map-zoom-controls button:first-child {
    border-bottom: 1px solid #e5e7eb;
}

/* Category Filters */
.category-filters {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 8px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.category-button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 200px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.category-button:hover {
    background: #f9fafb;
    border-color: #d1d5db;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.category-button.active {
    background: #1e40af;
    border-color: #1e40af;
    color: #ffffff;
}

.category-button.active .category-text {
    color: #ffffff;
}

.category-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: 16px;
    background-repeat: no-repeat;
    background-position: center;
    flex-shrink: 0;
}

.sustainability-icon {
    background-color: #10b981;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M12 2L2 7l10 5 10-5-10-5zM2 17l10 5 10-5M2 12l10 5 10-5"/></svg>');
}

.promotion-icon {
    background-color: #6b7280;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M7 14l3-3 2 2 7-7-1.414-1.414L12 10.172 9 7.172 7.586 8.586z"/></svg>');
}

.disaster-icon {
    background-color: #f59e0b;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"/></svg>');
}

.network-icon {
    background-color: #ffffff;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%236b7280"><path d="M16 4c0-1.11.89-2 2-2s2 .89 2 2-.89 2-2 2-2-.89-2-2zm4 18v-6h2.5l-2.54-7.63A1.5 1.5 0 0 0 18.54 8H17c-.8 0-1.54.37-2.01 1l-3.7 4.99c-.56.75-.56 1.76 0 2.51l3.7 4.99c.47.63 1.21 1 2.01 1h1.54c.8 0 1.54-.37 2.01-1L22.5 22H20zM12.5 11.5c.83 0 1.5-.67 1.5-1.5s-.67-1.5-1.5-1.5S11 9.17 11 10s.67 1.5 1.5 1.5zM5.5 6c1.11 0 2-.89 2-2s-.89-2-2-2-2 .89-2 2 .89 2 2 2zm2 16v-6H9.9l1.49-4.5c.31-.95.39-1.99.25-3.01L9.9 6H6.5c-.8 0-1.54.37-2.01 1L.99 11.99c-.56.75-.56 1.76 0 2.51L4.49 18c.47.63 1.21 1 2.01 1H9.9l-1.49 4.5c-.31.95-.39 1.99-.25-3.01L9.9 22H7.5z"/></svg>');
    border: 2px solid #e5e7eb;
}

.category-text {
    font-size: 13px;
    color: #374151;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Activity Popup Styles */
.activity-popup-container {
    font-family: 'Inter', sans-serif;
}

.activity-popup {
    display: flex;
    max-width: 400px;
    background: #ffffff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.popup-image {
    width: 120px;
    height: 120px;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.popup-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.popup-content {
    flex: 1;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.popup-category {
    font-size: 12px;
    font-weight: 600;
    color: #f97316;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.popup-title {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    line-height: 1.4;
    margin-bottom: 8px;
}

.popup-location {
    display: flex;
    align-items: center;
    font-size: 14px;
    color: #374151;
    margin-bottom: 12px;
}

.popup-actions {
    margin-top: auto;
}

.popup-actions .read-more-btn {
    width: 100%;
    text-align: center;
}

/* Custom Map Markers */
.leaflet-marker-icon {
    transition: all 0.2s ease;
}

.leaflet-marker-icon.sustainability {
    background-color: #10b981;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.leaflet-marker-icon.promotion {
    background-color: #6b7280;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.leaflet-marker-icon.disaster {
    background-color: #f59e0b;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.leaflet-marker-icon.network {
    background-color: #ffffff;
    border: 2px solid #e5e7eb;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .activity-map-container {
        flex-direction: column;
        height: auto;
    }
    
    .activity-list-panel {
        width: 100%;
        height: 300px;
        border-right: none;
        border-bottom: 1px solid #e5e7eb;
    }
    
    .map-panel {
        height: 500px;
    }
    
    .category-filters {
        position: relative;
        bottom: auto;
        left: auto;
        margin: 20px;
        transform: none;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .category-button {
        min-width: 180px;
        flex: 1;
        max-width: 200px;
    }
}

@media (max-width: 768px) {
    .category-filters {
        margin: 16px;
        padding: 6px;
        gap: 8px;
    }
    
    .category-button {
        min-width: 150px;
        padding: 10px 12px;
    }
    
    .category-text {
        font-size: 12px;
    }
    
    .category-icon {
        width: 20px;
        height: 20px;
        background-size: 14px;
    }
}

@media (max-width: 480px) {
    .category-filters {
        flex-direction: column;
        gap: 6px;
    }
    
    .category-button {
        min-width: auto;
        max-width: none;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .activity-list-header {
        padding: 16px 16px 12px;
    }
    
    .activity-list-header h2 {
        font-size: 18px;
    }
    
    .activity-item {
        padding: 16px;
    }
    
    .activity-title {
        font-size: 15px;
    }
    
    .map-legend {
        margin: 16px;
        padding: 12px;
    }
    
    .legend-text {
        font-size: 13px;
    }
    
    .activity-popup {
        flex-direction: column;
        max-width: 300px;
    }
    
    .popup-image {
        width: 100%;
        height: 120px;
    }
}

/* Scrollbar Styling */
.activity-list-content::-webkit-scrollbar {
    width: 6px;
}

.activity-list-content::-webkit-scrollbar-track {
    background: #f1f5f9;
}

.activity-list-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

.activity-list-content::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Animation Classes */
.activity-item {
    animation: fadeInUp 0.3s ease-out;
}

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

/* Loading State */
.activity-map-container.loading {
    position: relative;
}

.activity-map-container.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 4px solid #e5e7eb;
    border-top: 4px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
} 