/* ===================================
   ENHANCED PAGES STYLING v2.0
   Police Dashboard Red Theme
   =================================== */

/* ===================================
   CONSISTENT PAGE DESIGN SYSTEM
   Matching index.html and dashboard.html
   =================================== */

/* ===================================
   PAGE HERO (for feature pages)
   =================================== */

.page-hero-modern {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    padding: 80px 20px 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-hero-modern.police-hero {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.page-hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.page-badge {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.page-title {
    font-size: 48px;
    font-weight: 700;
    color: white;
    margin: 0 0 15px 0;
    line-height: 1.2;
}

.page-subtitle {
    font-size: 20px;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    font-weight: 400;
}

/* ===================================
   POLICE DASHBOARD SPECIFIC
   =================================== */

/* ===================================
   POLICE DASHBOARD RED THEME
   =================================== */

/* Police Navigation */
.police-nav {
    border-bottom: 2px solid rgba(231, 76, 60, 0.2);
}

/* Police logo - no additional styling needed, using logo-police.svg */
.police-logo img {
    /* Keep the logo visible */
    filter: none !important;
    opacity: 1 !important;
}

.police-logo-text,
.police-nav .police-logo-text,
.police-logo .logo-text,
.police-nav .logo-text {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
    color: #e74c3c !important;
    font-weight: 700 !important;
}

.police-logout-btn {
    background: rgba(231, 76, 60, 0.1) !important;
    color: #e74c3c !important;
}

.police-logout-btn:hover {
    background: rgba(231, 76, 60, 0.2) !important;
}

.police-logout-btn svg {
    stroke: #e74c3c;
}

/* Police Badge */
.police-badge {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.4);
    color: #e74c3c;
}

.police-badge svg {
    stroke: #e74c3c;
}

/* Police Divider */
.police-divider-line {
    background: linear-gradient(90deg, transparent, rgba(231, 76, 60, 0.3), transparent);
}

.police-divider-icon {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.police-divider-icon svg {
    stroke: white;
}

/* Police hero gradient circles */
.police-hero .hero-circle-1 {
    background: radial-gradient(circle, rgba(231, 76, 60, 0.2) 0%, transparent 70%) !important;
    animation: float 8s ease-in-out infinite !important;
}

.police-hero .hero-circle-2 {
    background: radial-gradient(circle, rgba(192, 57, 43, 0.2) 0%, transparent 70%) !important;
    animation: float 10s ease-in-out infinite reverse !important;
}

/* Police gradient text for name */
.police-hero .gradient-text {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Police Feature Cards */
.police-feature-card {
    border: 2px solid rgba(231, 76, 60, 0.15);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.police-feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.03) 0%, rgba(192, 57, 43, 0.03) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.police-feature-card:hover {
    border-color: rgba(231, 76, 60, 0.5);
    box-shadow: 0 20px 60px rgba(231, 76, 60, 0.25);
    transform: translateY(-12px) scale(1.02);
}

.police-feature-card:hover::before {
    opacity: 1;
}

/* Police Feature Action Buttons */
.police-feature-action {
    color: #e74c3c;
    transition: all 0.3s ease;
}

.police-feature-action svg {
    stroke: #e74c3c;
    transition: transform 0.3s ease;
}

.police-feature-card:hover .police-feature-action {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.15) 0%, rgba(192, 57, 43, 0.15) 100%);
    padding: 10px 20px;
    border-radius: 10px;
    transform: translateX(5px);
}

.police-feature-card:hover .police-feature-action svg {
    transform: translateX(5px);
}

.police-quick-stats {
    max-width: 1400px;
    margin: -40px auto 40px;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    position: relative;
    z-index: 10;
}

.stat-card-police {
    background: white;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.3s ease;
    animation: fadeInUp 0.6s ease-out;
}

.stat-card-police:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
}

.stat-icon-police {
    width: 60px;
    height: 60px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-icon-police.red {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.1) 0%, rgba(231, 76, 60, 0.2) 100%);
}

.stat-icon-police.red svg {
    stroke: #e74c3c;
}

.stat-icon-police.orange {
    background: linear-gradient(135deg, rgba(230, 126, 34, 0.1) 0%, rgba(230, 126, 34, 0.2) 100%);
}

.stat-icon-police.orange svg {
    stroke: #e67e22;
}

.stat-icon-police.green {
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.1) 0%, rgba(46, 204, 113, 0.2) 100%);
}

.stat-icon-police.green svg {
    stroke: #2ecc71;
}

.stat-icon-police.blue {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(52, 152, 219, 0.2) 100%);
}

.stat-icon-police.blue svg {
    stroke: #3498db;
}

.stat-info {
    flex: 1;
}

.stat-value {
    font-size: 36px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 14px;
    color: #7f8c8d;
    font-weight: 500;
}

/* ===================================
   NAVIGATION ENHANCEMENTS
   =================================== */

.nav-link-modern {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 10px;
    color: #2c3e50;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    background: rgba(52, 152, 219, 0.1);
}

.nav-link-modern:hover {
    background: rgba(52, 152, 219, 0.2);
    transform: translateY(-2px);
}

/* ===================================
   ALERTS CONTAINER & FILTERS
   =================================== */

.alerts-container,
.trends-container,
.safety-page-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px;
}

.incident-type-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 30px;
    background: white;
    border-radius: 15px;
    padding: 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.incident-tab {
    flex: 1;
    padding: 20px 25px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    color: #7f8c8d;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.incident-tab:hover {
    background: rgba(231, 76, 60, 0.05);
    color: #2c3e50;
}

.incident-tab.active {
    color: #e74c3c;
    border-bottom-color: #e74c3c;
    background: rgba(231, 76, 60, 0.08);
}

.alerts-filters {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    align-items: center;
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.cases-library-btn {
    padding: 12px 24px;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cases-library-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.3);
}

.filter-select {
    padding: 12px 18px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 500;
    color: #2c3e50;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 180px;
}

.filter-select:hover {
    border-color: #3498db;
}

.filter-select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 4px rgba(52, 152, 219, 0.1);
}

.alerts-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.no-alerts {
    text-align: center;
    padding: 80px 20px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.no-alerts h3 {
    color: #2c3e50;
    margin: 20px 0 10px;
    font-size: 24px;
}

.no-alerts p {
    color: #7f8c8d;
    font-size: 16px;
}

.notifications-banner {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 30px;
    color: white;
    box-shadow: 0 10px 40px rgba(52, 152, 219, 0.3);
    animation: fadeInDown 0.6s ease-out;
}

.notifications-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.notifications-header h3 {
    margin: 0;
    font-size: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.close-notifications-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 10px;
    padding: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-notifications-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.notifications-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* ===================================
   SAFETY PAGE COMPONENTS
   =================================== */

.current-location-alert {
    margin-bottom: 30px;
    padding: 20px 25px;
    border-radius: 15px;
    animation: fadeInDown 0.6s ease-out;
    display: flex;
    align-items: center;
    gap: 15px;
    font-weight: 600;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.safety-checker-card {
    background: white;
    border-radius: 20px;
    padding: 35px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
    animation: fadeInUp 0.6s ease-out;
}

.safety-checker-card h2 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 28px;
    display: flex;
    align-items: center;
}

.safety-checker-card > p {
    color: #7f8c8d;
    margin-bottom: 25px;
    font-size: 16px;
}

.safety-search-wrapper {
    position: relative;
    display: flex;
    gap: 10px;
    align-items: center;
}

.search-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #95a5a6;
    pointer-events: none;
    z-index: 1;
}

.safety-search-input,
.area-search-input,
.map-search-input {
    flex: 1;
    padding: 16px 16px 16px 50px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.safety-search-input:focus,
.area-search-input:focus,
.map-search-input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 4px rgba(52, 152, 219, 0.1);
}

.current-location-btn {
    padding: 16px;
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(41, 128, 185, 0.1) 100%);
    border: 2px solid #3498db;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.current-location-btn svg {
    stroke: #3498db;
    transition: all 0.3s ease;
}

.current-location-btn:hover {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    border-color: #3498db;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.3);
}

.current-location-btn:hover svg {
    stroke: white;
}

/* Tooltip for current location button */
.current-location-btn::after {
    content: 'Use my location';
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    background: #2c3e50;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 10;
}

.current-location-btn:hover::after {
    opacity: 1;
}

.check-safety-btn,
.analyze-area-btn,
.map-search-btn {
    padding: 16px 32px;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.check-safety-btn:hover,
.analyze-area-btn:hover,
.map-search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.3);
}

.safety-result,
.risk-result {
    margin-top: 25px;
    padding: 25px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 15px;
    animation: fadeInUp 0.4s ease-out;
}

.quick-search-section {
    background: white;
    border-radius: 20px;
    padding: 35px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    animation: fadeInUp 0.6s ease-out 0.2s both;
}

.quick-search-section h3 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 24px;
}

.quick-search-section > p {
    color: #7f8c8d;
    margin-bottom: 25px;
}

.quick-search-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
}

.quick-search-btn {
    padding: 15px 20px;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    color: #2c3e50;
    cursor: pointer;
    transition: all 0.3s ease;
}

.quick-search-btn:hover {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    border-color: #3498db;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.2);
}

/* ===================================
   TRENDS PAGE COMPONENTS
   =================================== */

.risk-search-section,
.trends-section {
    background: white;
    border-radius: 20px;
    padding: 35px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
    animation: fadeInUp 0.6s ease-out;
}

.safety-tips-section {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.05) 0%, rgba(41, 128, 185, 0.05) 100%);
    border: 2px solid rgba(52, 152, 219, 0.2);
    border-radius: 20px;
    padding: 35px;
    box-shadow: 0 10px 40px rgba(52, 152, 219, 0.15);
    margin-bottom: 30px;
    animation: fadeInUp 0.6s ease-out;
}

.risk-search-section h2,
.trends-section h2 {
    color: #2c3e50;
    margin-bottom: 25px;
    font-size: 28px;
}

.safety-tips-section h2 {
    color: #3498db;
    margin-bottom: 25px;
    font-size: 28px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.safety-tips-section h2::before {
    content: '💡';
    font-size: 32px;
}

.search-wrapper {
    position: relative;
    display: flex;
    gap: 10px;
    align-items: center;
}

.risk-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e9ecef;
}

.risk-header h3 {
    font-size: 24px;
    color: #2c3e50;
    margin: 0;
}

.risk-badge {
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.risk-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.risk-stat {
    background: white;
    padding: 20px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    border: 2px solid #e9ecef;
    transition: all 0.3s ease;
}

.risk-stat:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    border-color: #3498db;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
}

.stat-icon svg {
    color: white;
}

.stat-content {
    flex: 1;
}

.stat-content .stat-label {
    font-size: 13px;
    color: #7f8c8d;
    margin-bottom: 5px;
}

.stat-content .stat-value {
    font-size: 24px;
    font-weight: 700;
    color: #2c3e50;
}

.crime-breakdown {
    background: white;
    padding: 25px;
    border-radius: 15px;
    border: 2px solid #e9ecef;
}

.crime-breakdown h4 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #2c3e50;
    font-size: 20px;
}

.crime-chart {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
    animation: fadeInUp 0.6s ease-out 0.2s both;
}

.stat-card {
    background: white;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.12);
}

.stat-card-icon {
    width: 70px;
    height: 70px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-card-content {
    flex: 1;
}

.stat-card-label {
    font-size: 14px;
    color: #7f8c8d;
    margin-bottom: 8px;
    font-weight: 500;
}

.stat-card-value {
    font-size: 32px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
}

.stat-card-change {
    font-size: 13px;
    color: #95a5a6;
}

.chart-container {
    min-height: 300px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 12px;
}

.time-analysis {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.time-period {
    flex: 1;
    min-width: 150px;
    padding: 15px 20px;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    color: #7f8c8d;
}

.time-period:hover {
    border-color: #3498db;
    background: rgba(52, 152, 219, 0.05);
}

.time-period.active {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    border-color: #3498db;
    color: white;
}

.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

/* ===================================
   MAP PAGE COMPONENTS
   =================================== */

.map-search-container {
    position: absolute;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    width: 90%;
    max-width: 600px;
    animation: fadeInDown 0.6s ease-out;
}

.map-search-wrapper {
    position: relative;
    display: flex;
    gap: 10px;
    background: white;
    padding: 12px;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

.search-results {
    background: white;
    margin-top: 10px;
    border-radius: 15px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    max-height: 300px;
    overflow-y: auto;
}

.search-result-item {
    padding: 12px 15px;
    border-bottom: 1px solid #e9ecef;
    cursor: pointer;
    transition: all 0.2s ease;
}

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

.search-result-item:hover {
    background: rgba(52, 152, 219, 0.1);
}

/* Map height adjustment */
#map {
    width: 100%;
    height: 90vh;
    position: relative;
}

/* Leaflet legend mobile improvements */
.legend {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Leaflet popup mobile improvements */
.leaflet-popup-content-wrapper {
    border-radius: 12px;
}

.leaflet-popup-content {
    margin: 15px;
    font-size: 14px;
}

/* ===================================
   ANIMATIONS
   =================================== */

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

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===================================
   RESPONSIVE DESIGN
   =================================== */

@media (max-width: 768px) {
    .page-title {
        font-size: 36px;
    }
    
    .page-subtitle {
        font-size: 16px;
    }
    
    .police-quick-stats {
        grid-template-columns: 1fr;
        margin-top: -30px;
    }
    
    .stat-card-police {
        padding: 20px;
    }
    
    .stat-value {
        font-size: 28px;
    }
    
    .incident-type-tabs {
        flex-direction: column;
    }
    
    .incident-tab {
        border-bottom: 1px solid #e9ecef;
        border-left: 3px solid transparent;
        justify-content: flex-start;
    }
    
    .incident-tab.active {
        border-bottom-color: #e9ecef;
        border-left-color: #e74c3c;
    }
    
    .alerts-filters {
        flex-direction: column;
    }
    
    .cases-library-btn,
    .filter-select {
        width: 100%;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .risk-details {
        grid-template-columns: 1fr;
    }
    
    .time-analysis {
        flex-direction: column;
    }
    
    .time-period {
        min-width: 100%;
    }
    
    .safety-search-wrapper,
    .search-wrapper,
    .map-search-wrapper {
        flex-direction: column;
    }
    
    .current-location-btn,
    .check-safety-btn,
    .analyze-area-btn,
    .map-search-btn {
        width: 100%;
    }
    
    .quick-search-buttons {
        grid-template-columns: 1fr;
    }
    
    /* Map mobile improvements */
    .map-search-container {
        width: calc(100% - 20px);
        max-width: none;
        top: 70px;
        left: 10px;
        right: 10px;
        transform: none;
    }
    
    .map-search-wrapper {
        padding: 8px;
        gap: 8px;
    }
    
    .map-search-input {
        padding: 12px 12px 12px 40px;
        font-size: 14px;
    }
    
    .search-icon {
        left: 12px;
        width: 18px;
        height: 18px;
    }
    
    .map-search-btn {
        padding: 12px 20px;
        font-size: 14px;
    }
    
    .search-results {
        max-height: 150px;
        font-size: 13px;
    }
    
    .search-result-item {
        padding: 10px 12px;
    }
    
    /* Adjust map height on mobile */
    #map {
        height: calc(100vh - 60px);
    }
    
    /* Make legend more compact on mobile */
    .legend {
        font-size: 12px !important;
        padding: 10px !important;
        max-width: 200px;
    }
    
    .legend h4 {
        font-size: 14px !important;
        margin-bottom: 8px !important;
    }
    
    .legend > div {
        margin: 5px 0 !important;
        font-size: 11px !important;
    }
    
    .legend > div > div {
        font-size: 10px !important;
        margin-left: 20px !important;
    }
    
    /* Make popups more mobile-friendly */
    .leaflet-popup-content-wrapper {
        max-width: 250px;
    }
    
    .leaflet-popup-content {
        margin: 12px;
        font-size: 13px;
    }
    
    .leaflet-popup-content h3 {
        font-size: 16px !important;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .map-search-container {
        top: 65px;
        width: calc(100% - 16px);
        left: 8px;
        right: 8px;
    }
    
    .map-search-wrapper {
        padding: 6px;
        gap: 6px;
    }
    
    .map-search-input {
        padding: 10px 10px 10px 35px;
        font-size: 13px;
    }
    
    .map-search-btn {
        padding: 10px 16px;
        font-size: 13px;
    }
    
    .search-icon {
        left: 10px;
        width: 16px;
        height: 16px;
    }
    
    .search-results {
        max-height: 120px;
        font-size: 12px;
    }
    
    .search-result-item {
        padding: 8px 10px;
    }
    
    /* Even more compact legend */
    .legend {
        font-size: 11px !important;
        padding: 8px !important;
        max-width: 180px;
    }
    
    .legend h4 {
        font-size: 13px !important;
        margin-bottom: 6px !important;
    }
    
    .legend > div {
        margin: 4px 0 !important;
        font-size: 10px !important;
    }
    
    .legend > div > div {
        font-size: 9px !important;
        margin-left: 18px !important;
        line-height: 1.3;
    }
    
    .legend span {
        width: 10px !important;
        height: 10px !important;
        margin-right: 6px !important;
    }
    
    /* Smaller popups */
    .leaflet-popup-content-wrapper {
        max-width: 220px;
    }
    
    .leaflet-popup-content {
        margin: 10px;
        font-size: 12px;
    }
    
    .leaflet-popup-content h3 {
        font-size: 14px !important;
        margin-bottom: 8px !important;
    }
    
    .leaflet-popup-content p {
        margin: 4px 0 !important;
    }
    
    .leaflet-popup-content small {
        font-size: 11px !important;
    }
}


/* ===================================
   PAGE BADGE ICON IMPROVEMENTS
   =================================== */

/* Page hero icons - white outline, no background */
.page-badge .feature-icon-wrapper {
    background: transparent !important;
    border: 3px solid white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-badge .feature-icon-wrapper img,
.page-badge .feature-icon-wrapper svg {
    filter: brightness(0) invert(1);
}

.page-badge .feature-icon-wrapper.red,
.page-badge .feature-icon-wrapper.green,
.page-badge .feature-icon-wrapper.orange,
.page-badge .feature-icon-wrapper.blue,
.page-badge .feature-icon-wrapper.purple {
    background: transparent !important;
    border: 3px solid white;
}


/* ===================================
   LOCATION AUTOCOMPLETE
   =================================== */

.location-autocomplete-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #e9ecef;
    border-top: none;
    border-radius: 0 0 12px 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    margin-top: -2px;
}

.location-result-item {
    padding: 12px 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid #f0f0f0;
}

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

.location-result-item:hover {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(41, 128, 185, 0.1) 100%);
}

.location-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 4px;
    font-size: 15px;
}

.location-details {
    font-size: 13px;
    color: #7f8c8d;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.location-distance {
    font-size: 12px;
    color: #3498db;
    font-weight: 600;
    margin-left: 10px;
    white-space: nowrap;
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .location-autocomplete-results {
        max-height: 200px;
        font-size: 14px;
    }
    
    .location-result-item {
        padding: 10px 12px;
    }
    
    .location-name {
        font-size: 14px;
    }
    
    .location-details {
        font-size: 12px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .location-distance {
        margin-left: 0;
        margin-top: 4px;
    }
}


/* ===================================
   POLICE PAGE ELEMENTS
   =================================== */

/* Police Navigation Link */
.police-nav-link {
    background: rgba(231, 76, 60, 0.1) !important;
    color: #e74c3c !important;
}

.police-nav-link:hover {
    background: rgba(231, 76, 60, 0.2) !important;
}

.police-nav-link svg {
    stroke: #e74c3c;
}

/* Police Inputs */
.police-input:focus {
    border-color: #e74c3c !important;
    box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.1) !important;
}

/* Police Buttons */
.police-btn {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
}

.police-btn:hover {
    box-shadow: 0 8px 25px rgba(231, 76, 60, 0.3) !important;
}

/* Police Risk Stats */
.police-risk-stat:hover {
    border-color: #e74c3c !important;
}

.police-stat-icon {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
}

/* Police Time Periods */
.police-time-period:hover {
    border-color: #e74c3c !important;
    background: rgba(231, 76, 60, 0.05) !important;
}

.police-time-period.active {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
    border-color: #e74c3c !important;
}

/* Police Tips Section */
.police-tips-section {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.05) 0%, rgba(192, 57, 43, 0.05) 100%) !important;
    border: 2px solid rgba(231, 76, 60, 0.2) !important;
    box-shadow: 0 10px 40px rgba(231, 76, 60, 0.15) !important;
}

.police-tips-section h2 {
    color: #e74c3c !important;
}

.police-tips-section h2::before {
    content: '🚨';
}

/* Police Map Search */
.police-map-search .map-search-btn {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
}

.police-map-search .map-search-btn:hover {
    box-shadow: 0 8px 25px rgba(231, 76, 60, 0.3) !important;
}

.police-map-search .map-search-input:focus {
    border-color: #e74c3c !important;
    box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.1) !important;
}


/* ===================================
   POLICE REPORT PAGE
   =================================== */

.police-background .bg-shape-1 {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.1) 0%, rgba(192, 57, 43, 0.1) 100%);
}

.police-background .bg-shape-2 {
    background: linear-gradient(135deg, rgba(192, 57, 43, 0.1) 0%, rgba(231, 76, 60, 0.1) 100%);
}

.police-background .bg-shape-3 {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.08) 0%, rgba(192, 57, 43, 0.08) 100%);
}


/* ===================================
   POLICE REPORT HERO
   =================================== */

.police-report-page .report-hero {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
}

.police-report-page .report-hero::before {
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
}

.police-report-page .hero-circle-1 {
    background: radial-gradient(circle, rgba(231, 76, 60, 0.15) 0%, transparent 70%);
}

.police-report-page .hero-circle-2 {
    background: radial-gradient(circle, rgba(192, 57, 43, 0.15) 0%, transparent 70%);
}


/* Police Report Page Buttons */
.police-report-page .tab-btn.active,
.police-report-page .tab-btn:hover {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
    border-color: #e74c3c !important;
}

.police-report-page .submit-btn,
.police-report-page .analyze-btn,
.police-report-page button[type="submit"],
.police-report-page button[type="button"]:not(.location-btn):not(#get-location-btn) {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
}

.police-report-page .submit-btn:hover,
.police-report-page .analyze-btn:hover,
.police-report-page button[type="submit"]:hover,
.police-report-page button[type="button"]:not(.location-btn):not(#get-location-btn):hover {
    box-shadow: 0 8px 25px rgba(231, 76, 60, 0.3) !important;
}

/* Keep location button green */
.police-report-page .location-btn,
.police-report-page #get-location-btn {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%) !important;
}

.police-report-page .location-btn:hover,
.police-report-page #get-location-btn:hover {
    box-shadow: 0 8px 25px rgba(46, 204, 113, 0.3) !important;
}

.police-report-page input:focus,
.police-report-page textarea:focus,
.police-report-page select:focus {
    border-color: #e74c3c !important;
    box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.1) !important;
}

.police-report-page .ai-input-section {
    border-left: 4px solid #e74c3c !important;
}


/* ===================================
   POLICE DASHBOARD BACKGROUND
   =================================== */

#police-dashboard {
    background-color: #fff9f9;
    min-height: 100vh;
}

/* Keep feature cards white for contrast */
#police-dashboard .feature-card-dashboard {
    background: white;
}

/* Keep section headers readable */
#police-dashboard .section-header-dashboard {
    background: transparent;
}
