﻿/* ========== GLOBAL ========== */
body {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
}

#map {
    position: absolute;
    top: 60px;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 0;
}

/* Pin mode cursor */
#map.pin-mode {
    cursor: crosshair !important;
}

#map.pin-mode * {
    cursor: crosshair !important;
}

/* ========== NAVBAR ========== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: #2c3e50;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    gap: 20px;
}

.navbar-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.navbar-title {
    color: white;
    font-size: 22px;
    font-weight: 600;
    letter-spacing: 0.3px;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 10px;
    border-radius: 6px;
}

.navbar-title:hover {
    background: rgba(255,255,255,0.1);
}

.navbar-title:active {
    transform: translateY(0);
}

.navbar-title-icon {
    font-size: 24px;
    color: #3498db;
}

.mode-buttons {
    display: flex;
    gap: 8px;
}

/* Mode Toggle Buttons */
.mode-toggle-btn {
    background: rgba(255,255,255,0.1);
    border: 1.5px solid rgba(255,255,255,0.3);
    color: white;
    padding: 7px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
    white-space: nowrap;
}

.navbar-toggle:hover {
    background: rgba(255,255,255,0.15);
    border-color: #2980b9;
}

.mode-toggle-btn:hover {
    background: rgba(52, 152, 219, 0.15);
    border-color: #2980b9;
}

.mode-toggle-btn.active {
    background: #2980b9;
    color: white;
    border-color: #2980b9;
    font-weight: 600;
}

/* Search in Navbar */
.navbar-search {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 1;
    max-width: 500px;
    background: white;
    border-radius: 6px;
    padding: 4px 8px;
}
.navbar-search input[type="text"] {
    flex: 1;
    border: none;
    outline: none;
    padding: 6px 8px;
    font-size: 14px;
    background: transparent;
}

.navbar-icon-btn {
    background: transparent;
    border: none;
    font-size: 16px;
    cursor: pointer;
    padding: 6px 10px;
    border-radius: 4px;
    transition: background 0.2s;
    color: #666;
}

.navbar-icon-btn:hover {
    background: #e8e8e8;
    color: #333;
}

.navbar-icon-btn.active {
    background: #dc3545;
    color: white;
}

.navbar-icon-btn.hidden {
    display: none;
}

.navbar-buttons {
    display: flex;
    gap:8px;
}

.navbar-toggle {
    background: rgba(255,255,255,0.1);
    border: 1.5px solid rgba(255,255,255,0.3);
    color: white;
    padding: 7px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
    white-space: nowrap;
} 

.navbar-toggle:hover {
    background: rgba(52, 152, 219, 0.15);
    border-color: #3498db;
}

/* Suggestion List below Navbar */
.suggestion-container {
    position: fixed;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1999;
    max-width: 500px;
    width: 90%;
}

.suggestion-list {
    list-style: none;
    padding: 0;
    margin: 0;
    background: white;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    max-height: 300px;
    overflow-y: auto;
    display: none;
}

.suggestion-item {
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid #eee;
    font-size: 14px;
}

.suggestion-item:hover {
    background-color: #f0f0f0;
}

.suggestion-item:last-child {
    border-bottom: none;
}

/* Message Banner below Navbar */
.message-banner-navbar {
    position: fixed;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1999;
    padding: 10px 20px;
    border-radius: 6px;
    display: none;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    font-size: 14px;
}

.message-banner-navbar.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.message-banner-navbar.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message-banner-navbar.info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* ========== CONTROL PANEL (Location Search) ========== */
.control-panel {
    position: absolute;
    top: 80px;
    left: 30px;
    background: white;
    padding: 15x;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    z-index: 1000;
    min-width: 350px;
    transition: left 0.3s ease;
}

.control-panel.shifted {
    left: 470px;
}

.control-panel h3 {
    margin-top: 0;
    margin-bottom: 10px;
    color: #333;
    font-size: 16px;
}

.form-group {
    margin-bottom: 10px;
}

label {
    font-weight: bold;
    display: block;
    margin-bottom: 4px;
    color: #555;
    font-size: 13px;
}

/* Input Wrapper */
.input-wrapper {
    position: relative;
    width: 100%;
    display: flex;
    gap: 5px;
}

input[type="text"] {
    flex: 1;
    padding: 8px 30px 8px 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 13px;
}

.clear-button {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    font-size: 18px;
    padding: 0;
    width: 20px;
    height: 20px;
    line-height: 1;
    z-index: 10;
}

.clear-button:hover {
    color: #333;
    background: none;
}

.clear-button.hidden {
    display: none;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.btn-primary,
.btn-pin {
    padding: 8px 16px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 13px;
    font-weight: bold;
    transition: all 0.3s;
}

.btn-primary {
    flex: 1;
    background-color: #2980b9;
    color: white;
}

.btn-primary:hover {
    background-color: #0056b3;
}

.btn-pin {
    background-color: #6c757d;
    color: white;
    min-width: 120px;
}

.btn-pin:hover {
    background-color: #5a6268;
}

.btn-pin.active {
    background-color: #dc3545;
}

/* Message Banner */
.message-banner {
    margin-top: 10px;
    padding: 10px;
    border-radius: 5px;
    display: none;
}

.message-banner.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.message-banner.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message-banner.info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}


/* ========== OPTIONS SIDEBAR ========== */

.options-sidebar {
    position: fixed;
    top: 60px;
    right: -370px;
    width: 350px;
    height: calc(100% - 2*60px);
    background: white;
    box-shadow: -2px 0 10px rgba(0,0,0,0.3);
    z-index: 1500;
    padding: 15px;
    overflow-y: auto;
    transition: right 0.3s ease;
    padding-bottom: 80px;
}

.options-sidebar.active {
    right: 0;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
}

.sidebar-header h3 {
    margin: 0;
    color: #333;
    font-size: 18px;
}

.close-sidebar {
    background: #dc3545;
    border: none;
    font-size: 20px;
    color: white;
    cursor: pointer;
    padding: 4px 10px;
    border-radius: 4px;
    line-height: 1;
    transition: background 0.2s;
}

.close-sidebar:hover {
    background: #c82333;
}

/* Filter Sections */
.filter-section {
    margin-bottom: 12px;
}

.filter-section label {
    font-weight: bold;
    display: block;
    margin-bottom: 5px;
    color: #555;
    font-size: 15px;
}

/* Priority sections (Age Group & Metrics) */
.priority-section {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 5px;
    border-left: 3px solid #3498db;
    margin-bottom: 14px;
}

.priority-section label {
    color: #2c3e50;
    font-size: 15px;
    font-weight: 600;
}

.filter-section select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 13px;
}

/* Checkbox Group (Metrics) */
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    padding: 4px;
    border-radius: 4px;
    transition: background 0.2s;
}

.checkbox-item:hover {
    background: #f5f5f5;
}

.checkbox-item input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin-right: 8px;
    cursor: pointer;
}

.checkbox-item label {
    font-weight: normal !important;
    margin: 0 !important;
    cursor: pointer;
    flex: 1;
    font-size: 12px;
}

/* Category Checkboxes */
.collapsible-label {
    cursor: pointer;
    font-size: 13px;
    color: #666;
}

.collapse-icon {
    float: right;
    transition: transform 0.3s;
}

.category-checkboxes-scroll {
    max-height: 300px;
    overflow-y: auto;
    overflow-x: hidden;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 6px;
    background: #f9f9f9;
    margin-top: 5px;
}

.category-checkboxes {
    display: grid;
    grid-template-columns: 1fr;
    gap: 4px;
    max-height: 300px;
}

.category-checkbox-item {
    display: flex;
    align-items: center;
    padding: 5px 6px;
    border-radius: 4px;
    border: 1.5px solid #ddd;
    transition: all 0.2s;
    cursor: pointer;
}

.category-checkbox-item:hover {
    background: #f8f9fa;
    border-color: #3498db;
}

.category-checkbox-item input[type="checkbox"] {
    width: 14px;
    height: 14px;
    margin-right: 6px;
    cursor: pointer;
}

.category-color-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 6px;
    border: 1.5px solid white;
    box-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.category-label {
    flex: 1;
    font-weight: normal;
    margin: 0;
    cursor: pointer;
    font-size: 12px;
}

/* Select All Button */
.select-all-btn {
    width: 100%;
    padding: 6px;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    margin-bottom: 6px;
    margin-top: 6px;
}
.select-all-btn:hover {
    background: #5a6268;
}

/* Submit Section */
.submit-button {
    margin-top: 15px;
    padding: 10px;
    border-top: 1px solid #ddd;
    width: 100%;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.submit-button:hover {
    background-color: #2980b9;
}

.submit-button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

/* ========== INFO PANEL (Statistics) - LEFT SIDEBAR ========== */
.info-panel {
    position: fixed;
    top: 60px;
    left: -420px;  
    width: 390px;  
    height: calc(100% - 60px);
    background: white;
    box-shadow: 2px 0 10px rgba(0,0,0,0.3);
    z-index: 1500;
    padding: 18px;  
    padding-bottom: 80px; 
    overflow-y: auto;
    transition: left 0.3s ease;
    font-size: 13px;
}

.info-panel.active{
    left:0;
}

.panel-header h4 {
    margin: 0;
    color: #333;
    font-size: 20px;  /* MITTEL: zwischen 18px und 22px */
}

.legend-section h4,
.stats-section h4 {
    margin: 0 0 7px 0;
    font-size: 15px;  /* MITTEL: zwischen 13px und 16px */
    color: #333;
    font-weight: 600;
}

.legend-section{
    margin-bottom: 14px;
}

.stats-section {
    margin-bottom: 14px;
}
    
/* Time Legend */
.time-legend {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.time-legend-item {
    display: flex;
    align-items: center;
    font-size: 12px;  /* MITTEL */
    margin: 4px 0;
}

.time-legend-line {
    width: 30px;  /* MITTEL: zwischen 25px und 35px */
    height: 5px;  /* MITTEL: zwischen 4px und 6px */
    margin-right: 7px;
    border-radius: 2px;
}

/* Category Legend */
.category-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-bottom: 9px;
}

.category-legend-item {
    display: flex;
    align-items: center;
    font-size: 12px;  /* MITTEL */
    padding: 4px 7px;
    background: #f8f9fa;
    border-radius: 4px;
}

.category-legend-dot {
    width: 11px;  /* MITTEL: zwischen 10px und 12px */
    height: 11px;
    border-radius: 50%;
    margin-right: 6px;
    border: 1.5px solid white;
    box-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

/* Statistics */
.stat-item {
    display: flex;
    justify-content: space-between;
    margin: 7px 0;
    font-size: 13px;  /* MITTEL */
}

.stat-label {
    font-weight: 600;
    color: #555;
    font-size: 13px;  /* MITTEL */
}

.stat-value {
    color: #3498db;
    font-weight: 600;
    font-size: 13px;  /* MITTEL */
}

/* Metric Toggle Buttons */
.metric-toggle-buttons {
    display: flex;
    gap: 9px;
    margin: 14px 0;
    flex-wrap: wrap;
}

.metric-btn {
    flex: 1;
    min-width: 100px;  /* MITTEL: zwischen 90px und 110px */
    padding: 9px 11px;
    border: 1.5px solid #ddd;
    border-radius: 6px;
    background: white;
    cursor: pointer;
    font-size: 13px;  /* MITTEL */
    font-weight: 600;
    transition: all 0.2s;
    text-align: center;
}

.metric-btn .metric-value {
    display: block;
    font-size: 13px;  /* MITTEL: zwischen 14px und 16px */
    margin-top: 4px;
    color: #3498db;
}

.metric-btn.active .metric-value {
    font-size: 13px;
    color: #000000;
}

/* Category Stats */
.category-stats {
    margin-top: 9px;
    margin-bottom: 16px;
}

.category-stat {
    margin: 9px 0;
    padding: 9px;
    background: #f8f9fa;
    border-radius: 5px;
    border-left: 3px solid #3498db;
}

.category-stat-title {
    font-weight: 600;
    font-size: 13px;  /* MITTEL */
    margin-bottom: 7px;
    color: #333;
}

.category-stat-details {
    font-size: 12px;  /* MITTEL */
    color: #666;
    display: flex;
    gap: 13px;
    flex-wrap: wrap;
}

/* ========== POI MARKERS ========== */
.poi-icon {
    background: white;
    border: 2px solid #666;
    border-radius: 50%;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* WTW Slider */
input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    background: #ddd;
    border-radius: 3px;
    outline: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: #3498db;
    border-radius: 50%;
    cursor: pointer;
}

input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    background: #3498db;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* Minimize Button */
.minimize-btn {
    background: #6c757d;
    border: none;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    padding: 0;
}

.minimize-btn:hover {
    background: #5a6268;
}

/* Minimized state */
.control-panel.minimized {
    width: auto;
    min-width: 200px;
}

.control-panel.minimized #controlPanelContent {
    display: none;
}

/* Highlighted hexagon animation */
.highlighted-hexagon {
    animation: strongPulse 1s ease-in-out infinite;
    filter: drop-shadow(0 0 8px currentColor);
}

@keyframes strongPulse {
    0%, 100% {
        stroke-width: 6;
        stroke-opacity: 1;
        fill-opacity: 0.25;
    }
    50% {
        stroke-width: 10;
        stroke-opacity: 0.7;
        fill-opacity: 0.4;
    }
}

/* Collapsible Header */
.collapsible-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    padding: 8px 10px;
    background: #f8f9fa;
    border-radius: 5px;
    transition: background 0.2s;
}

.collapsible-header:hover {
    background: #e9ecef;
}

.collapse-icon {
    font-size: 12px;
    transition: transform 0.3s;
    color: #666;
}

.collapsible-header.active .collapse-icon {
    transform: rotate(-180deg);
}

.collapsible-content {
    padding-top: 10px;
}

/* District List */
.district-list {
    max-height: 350px;
    overflow-y: auto;
    background: #f8f9fa;
    border-radius: 5px;
    padding: 8px;
}

.district-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 10px;
    margin: 3px 0;
    background: white;
    border-radius: 4px;
    font-size: 13px;
    transition: background 0.2s;
}

.district-item:hover {
    background: #e8f4f8;
    cursor: pointer;
}

.district-rank {
    font-weight: bold;
    color: #666;
    min-width: 25px;
}

.district-name {
    flex: 1;
    margin-left: 8px;
    color: #333;
}

.district-value {
    font-weight: bold;
    color:#3498db;
    margin-right: 8px;
}

.district-bar {
    width: 60px;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.district-bar-fill {
    height: 100%;
    transition: width 0.3s;
}

/* View Toggle Buttons */
.view-toggle-btn {
    flex: 1;
    padding: 8px 12px;
    border: 2px solid #ddd;
    background: white;
    border-radius: 5px;
    cursor: pointer;
    font-size: 13px;
    font-weight: bold;
    transition: all 0.3s;
    color: #666;
}

.view-toggle-btn:hover {
    border-color: #3498db;
    color: #3498db;
}

.view-toggle-btn.active {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    animation: slideUp 0.3s;
}

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

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 2px solid #eee;
    background: #2c3e50;
    color: white;
    border-radius: 12px 12px 0 0;
}

.modal-header h3 {
    margin: 0;
    font-size: 22px;
}

.close-modal {
    background: rgba(255,255,255,0.2);
    border: 2px solid white;
    color: white;
    font-size: 24px;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.close-modal:hover {
    background: white;
    color: #2c3e50;
    transform: rotate(90deg);
}

.modal-body {
    padding: 25px;
}

/* Chart Type Toggle */
.chart-type-btn {
    padding: 8px 20px;
    margin: 0 5px;
    border: 2px solid #ddd;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.3s;
    color: #666;
}

.chart-type-btn:hover {
    border-color: #3498db;
    color: #3498db;
}

.chart-type-btn.active {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

/* Floating Compare Button */
.floating-compare-btn {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    padding: 12px 25px;
    background: #2c3e50;
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(44, 62, 80, 0.3);
    transition: all 0.3s;
    z-index: 1500;
}

.floating-compare-btn:hover {
    transform: translateX(-50%) translateY(-2px);
    box-shadow: 0 6px 20px rgba(44, 62, 80, 0.4);
    background: #34495e;
}

/* Help Icon Buttons */
.help-icon-btn {
    background: rgba(255,255,255,0.1);
    border: 1.5px solid rgba(255,255,255,0.3);
    color: #3498db;
    padding: 7px 10px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.help-icon-btn:hover {
    background: rgba(52, 152, 219, 0.2);
    border-color: #3498db;
    color: #3498db;
}

.help-icon-btn-small {
    background: transparent;
    border: none;
    color: #3498db;
    cursor: pointer;
    font-size: 18px;
    padding: 4px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.help-icon-btn-small:hover {
    color: #2980b9;
    transform: scale(1.1);
}

/* Help Modal Specific Styles */
.help-modal {
    max-width: 700px;
}

.help-modal .modal-body {
    max-height: 70vh;
    overflow-y: auto;
}

.help-section {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.help-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.help-section h4 {
    color: #2c3e50;
    margin-top: 0;
    margin-bottom: 12px;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.help-section p {
    color: #555;
    line-height: 1.6;
    margin: 8px 0;
}

.help-section ul {
    margin: 10px 0;
    padding-left: 25px;
}

.help-section li {
    color: #666;
    line-height: 1.7;
    margin: 6px 0;
}

.help-section strong {
    color: #2c3e50;
}

/* Age Group Buttons - Single Column like Metrics */
.age-group-buttons {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 8px;
}

.age-group-btn {
    padding: 8px 12px;
    border: 2px solid #ddd;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
    font-weight: 500;
    text-align: left;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.age-group-btn:hover {
    background: #f8f9fa;
    border-color: #2980b9;
    transform: translateY(-1px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}

.age-group-btn.active {
    background: linear-gradient(135deg, #3498db 0%, #3498db 100%);
    color: white;
    border-color: #3498db;
    font-weight: 600;
    box-shadow: 0 3px 8px rgba(0, 123, 255, 0.4);
}

/* Metric Buttons - Compact with units */
.metric-buttons {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 8px;
}

.metric-btn {
    padding: 8px 12px;
    border: 2px solid #ddd;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
    font-weight: 500;
    text-align: left;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.metric-btn:hover {
    background: #f8f9fa;
    border-color:#3498db;
    transform: translateY(-1px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}

.metric-btn.active {
    background: linear-gradient(135deg, #3498db 0%,  #3498db 100%);
    color: white;
    border-color:  #3498db;
    font-weight: 600;
}

.metric-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.metric-btn-unit {
    font-size: 11px;
    opacity: 0.8;
    font-weight: normal;
}

/* Comparison Modal Metric Buttons - Horizontal */
.comparison-metric-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 10px;
}

.comparison-metric-btn {
    padding: 10px 12px;
    border: 2px solid #ddd;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
    font-weight: 500;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.comparison-metric-btn:hover {
    background: #f8f9fa;
    border-color:  #3498db;
    transform: translateY(-1px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.12);
}

.comparison-metric-btn.active {
    background: linear-gradient(135deg,  #3498db 0%,  #3498db 100%);
    color: white;
    border-color:  #3498db;
    font-weight: 600;
    box-shadow: 0 3px 8px rgba(108, 99, 255, 0.4);
}