/* Crime Research Interactive Website Styles */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Styles */
.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.header h1 {
    color: #2c3e50;
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.header p {
    color: #7f8c8d;
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto;
}

/* Navigation */
.nav-tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50px;
    padding: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.nav-tab {
    background: transparent;
    border: none;
    padding: 15px 30px;
    margin: 0 5px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    color: #666;
}

.nav-tab.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.nav-tab:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

/* Content Sections */
.content-section {
    display: none;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.content-section.active {
    display: block;
    animation: fadeIn 0.5s ease-in;
}

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

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-card {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 15px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.dashboard-card:hover {
    transform: translateY(-5px);
}

.dashboard-card h3 {
    color: #2c3e50;
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.dashboard-card .metric {
    font-size: 2.5rem;
    font-weight: 700;
    color: #e74c3c;
    margin-bottom: 10px;
}

.dashboard-card .change {
    font-size: 1rem;
    font-weight: 600;
}

.change.positive { color: #e74c3c; }
.change.negative { color: #27ae60; }

/* Chart Containers */
.chart-container {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.chart-container h3 {
    color: #2c3e50;
    font-size: 1.5rem;
    margin-bottom: 20px;
    text-align: center;
}

/* Controls */
.controls {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 25px;
    justify-content: center;
}

.control-group {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.control-group label {
    font-weight: 600;
    margin-bottom: 5px;
    color: #2c3e50;
}

.control-group select,
.control-group input {
    padding: 10px 15px;
    border: 2px solid #ddd;
    border-radius: 25px;
    font-size: 1rem;
    background: white;
    transition: border-color 0.3s ease;
}

.control-group select:focus,
.control-group input:focus {
    outline: none;
    border-color: #667eea;
}

/* Map Container */
.map-container {
    height: 500px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

/* Analysis Section */
.analysis-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 25px;
}

.analysis-card {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.analysis-card h4 {
    color: #2c3e50;
    font-size: 1.3rem;
    margin-bottom: 15px;
}

.analysis-card p {
    color: #555;
    line-height: 1.6;
}

/* Key Findings */
.key-findings {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
}

.key-findings h3 {
    color: #2c3e50;
    font-size: 1.8rem;
    margin-bottom: 20px;
    text-align: center;
}

.findings-list {
    list-style: none;
    counter-reset: finding-counter;
}

.findings-list li {
    counter-increment: finding-counter;
    margin-bottom: 15px;
    padding-left: 40px;
    position: relative;
    color: #2c3e50;
    font-weight: 500;
}

.findings-list li::before {
    content: counter(finding-counter);
    position: absolute;
    left: 0;
    top: 0;
    background: #667eea;
    color: white;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
}

/* Download Section */
.download-section {
    text-align: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px;
    padding: 30px;
    margin-top: 30px;
}

.download-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid white;
    color: white;
    padding: 15px 30px;
    border-radius: 25px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    margin: 10px;
}

.download-btn:hover {
    background: white;
    color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .header h1 {
        font-size: 2rem;
    }
    
    .nav-tabs {
        flex-direction: column;
        align-items: center;
    }
    
    .nav-tab {
        margin: 5px 0;
        width: 200px;
    }
    
    .controls {
        flex-direction: column;
        align-items: center;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .analysis-grid {
        grid-template-columns: 1fr;
    }
}

/* Loading Animation */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Tooltip Styles */
.tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 10px;
    border-radius: 5px;
    font-size: 0.9rem;
    pointer-events: none;
    z-index: 1000;
}