/* /assets/style.css - ReportLagos Complete Stylesheet */

/* === Root Variables (Theme Colors & Base Settings) === */
:root {
    --primary: #1976d2; 
    --accent: #16a34a;  
    --danger: #e3342f;  
    --warning: #ffc107; 
    --info: #17a2b8;    
    --light: #f8fafc;         
    --dark: #212529;          
    --text-main: #343a40;     
    --text-muted: #6c757d;    
    --text-light: #f8f9fa;    
    --border-color: #dee2e6;  
    --card-bg: #ffffff;
    --body-bg: #f4f6fb;       
    --sidebar-bg: #1a232b;    
    --sidebar-link: #bac8d3;  
    --sidebar-link-hover: #ffffff;
    --sidebar-link-active-bg: #233044; 
    --sidebar-link-active-border: var(--primary); 
    --font-primary: 'Inter', Arial, sans-serif;
    --base-font-size: 16px;
    --base-line-height: 1.6;
    --border-radius-sm: 4px;
    --border-radius-md: 6px;
    --border-radius-lg: 8px;
    --box-shadow-sm: 0 2px 5px rgba(0,0,0,0.08);
    --box-shadow-md: 0 4px 12px rgba(0,0,0,0.1);
}

/* === Global Reset & Base Styles === */
* { 
    box-sizing: border-box; 
    margin: 0;
    padding: 0;
}

html {
    font-size: var(--base-font-size);
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background-color: var(--body-bg);
    color: var(--text-main);
    line-height: var(--base-line-height);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    padding-top: 60px; /* Global padding for fixed header */
}

body.no-scroll { /* Added to prevent body scroll when off-canvas is open */
    overflow: hidden;
}

a { 
    color: var(--primary); 
    text-decoration: none; 
    transition: color 0.2s ease-in-out;
}
a:hover { 
    text-decoration: underline;
    color: #115293; 
}
a.active { 
    font-weight: 600;
}

h1, h2, h3, h4, h5, h6 { 
    margin-top: 0; 
    margin-bottom: 0.75em; 
    font-weight: 600;
    color: #333; 
    line-height: 1.3;
}
h1 { font-size: 2.2em; } 
h2 { font-size: 1.8em; } 
h3 { font-size: 1.4em; } 
h4 { font-size: 1.2em; }

p { margin-bottom: 1em; }

img, video {
    max-width: 100%;
    height: auto;
    display: block; 
}

/* === Layout & Container === */
.container {
    width: 100%;
    max-width: 1180px; 
    margin-left: auto;
    margin-right: auto;
    padding-left: 20px; 
    padding-right: 20px; 
}
body:not(.admin-layout) .container.main-content-public { 
    padding-top: 25px; 
    padding-bottom: 25px;
}


/* === Main Site Header (Public) === */
.site-header {
    background: var(--primary);
    color: var(--text-light);
    min-height: 60px;
    width: 100%;
    position: fixed; 
    top: 0; left: 0; right: 0;
    z-index: 1030; 
    box-shadow: var(--box-shadow-sm);
}

.header-container { 
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px; 
    position: relative; 
}

.logo-area {
    display: flex;
    align-items: center;
    z-index: 1042;
}
.site-logo-link { display: flex; align-items: center; text-decoration: none; color: var(--text-light); }
.site-logo-img { height: 38px; margin-right: 10px; }
.site-logo-icon-fallback, .site-logo-icon-default { font-size: 1.7em; margin-right: 10px; color: var(--text-light); }
.site-title-text { font-size: 1.4em; font-weight: 700; color: var(--text-light); }


/* --- PUBLIC NAVIGATION STYLES (DESKTOP FIRST, THEN MOBILE OVERRIDE FOR OFF-CANVAS) --- */

/* Desktop Navigation (inline links shown by default) */
.desktop-navigation {
    display: flex; /* Visible on desktop by default */
    align-items: center;
    margin-left: auto; /* Pushes nav to the right of logo area */
}
.desktop-navigation a {
    color: var(--text-light);
    padding: 10px 12px;
    text-decoration: none;
    font-size: 0.95em;
    font-weight: 500;
    margin-left: 8px; 
    border-radius: var(--border-radius-sm);
    transition: background-color 0.2s ease, color 0.2s ease;
}
.desktop-navigation a:hover,
.desktop-navigation a.active {
    background-color: rgba(255,255,255,0.15);
    color: #fff;
}
.desktop-navigation a.nav-logout { color: #ffdddd; }
.desktop-navigation a.nav-logout:hover { color: #fff; background-color: var(--danger); }

/* Mobile Navigation Toggle Button (Hamburger) - Hidden on desktop */
.mobile-nav-toggle {
    display: none; /* Hidden on desktop, shown via media query */
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.8em; 
    cursor: pointer;
    padding: 8px 10px;
    align-items: center;
    z-index: 1051; /* Must be above off-canvas menu and overlay */
    margin-left: 15px; 
}
.mobile-nav-toggle .menu-text {
    font-size: 0.6em; 
    margin-left: 6px;
    font-weight: 500;
    line-height: 1;
}

/* Off-Canvas Menu Container (for Mobile) */
.off-canvas-menu {
    position: fixed;
    top: 0;
    left: -280px; /* Start off-screen */
    width: 280px; 
    height: 100%;
    background-color: var(--sidebar-bg); 
    color: var(--sidebar-link);
    box-shadow: 2px 0 10px rgba(0,0,0,0.2);
    z-index: 1050; 
    transition: left 0.3s ease-in-out;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    visibility: hidden; /* Initially hidden */
}
.off-canvas-menu.open {
    left: 0; /* Slide in */
    visibility: visible;
}

.off-canvas-header-mobile {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background-color: rgba(0,0,0,0.1); 
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.off-canvas-title-mobile {
    font-size: 1.1em;
    font-weight: 600;
    color: #fff;
}
.off-canvas-close {
    background: none;
    border: none;
    color: var(--sidebar-link-hover);
    font-size: 1.5em;
    cursor: pointer;
    padding: 5px;
}
.off-canvas-close:hover {
    color: var(--danger);
}

.mobile-navigation-links {
    flex-grow: 1; 
    padding-top: 10px;
}
.mobile-navigation-links a {
    display: block;
    padding: 14px 20px;
    color: var(--sidebar-link);
    text-decoration: none;
    font-size: 1em;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: background-color 0.2s ease, color 0.2s ease;
}
.mobile-navigation-links a:last-child {
    border-bottom: none;
}
.mobile-navigation-links a:hover,
.mobile-navigation-links a.active {
    background-color: var(--sidebar-link-active-bg);
    color: var(--sidebar-link-hover);
}
.mobile-navigation-links a.nav-logout { color: #ffcaca; }
.mobile-navigation-links a.nav-logout:hover { background-color: var(--danger); color: #fff; }


/* Site Overlay for Off-Canvas Menu */
.site-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1045; 
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease-in-out, visibility 0s linear 0.3s;
}
.site-overlay.open {
    opacity: 1;
    visibility: visible;
    transition-delay: 0s;
}


/* Media Query to switch from Desktop to Mobile Navigation */
@media (max-width: 991px) { /* Adjust this breakpoint as needed */
    .desktop-navigation {
        display: none; /* Hide desktop nav on mobile */
    }
    .mobile-nav-toggle {
        display: flex; /* Show hamburger toggle on mobile */
    }
}


/* === Footer === */
footer {
    background: var(--dark); color: #f0f0f0; text-align: center;
    padding: 25px 20px; font-size: 0.9em; margin-top: 40px;
    position: relative; border-top: 3px solid var(--primary);
}
footer .container {
    padding: 0; display: flex; justify-content: space-between;
    align-items: center; flex-wrap: wrap; gap: 10px;
}
footer .footer-copyright, footer .footer-nav { margin: 5px 10px; }
footer .footer-nav a { color: var(--sidebar-link); margin: 0 8px; text-decoration: none; }
footer .footer-nav a:hover { color: #fff; text-decoration: underline; }


/* === UI Components: Cards, Buttons, Tables, Forms etc. === */
.card {
    background: var(--card-bg); border-radius: var(--border-radius-lg);
    box-shadow: var(--box-shadow-md); padding: 25px; margin-bottom: 25px;
}
.card h1, .card h2, .card h3 { margin-bottom: 20px; }


/* --- DASHBOARD STATS CARD SECTION - UPDATED WITH FIX --- */
.stats-row {
    display: grid; /* Use grid for better alignment */
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); /* Responsive columns */
    gap: 20px; /* Space between cards */
    margin-bottom: 30px;
}
.stats-card {
    background: var(--card-bg);
    border-radius: var(--border-radius-md);
    box-shadow: var(--box-shadow-sm);
    padding: 20px 15px;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}
.stats-card:hover { transform: translateY(-3px); box-shadow: 0 5px 12px rgba(0,0,0,0.1); }
.stats-card i { font-size: 1.8em; margin-bottom: 15px; }
.stats-card h3 { 
    margin: 8px 0 0 0; 
    font-size: 1em; 
    font-weight: 500; 
    color: #444; 
    order: 2; /* Puts heading below the number */ 
}
.stats-card .stat { 
    font-size: 2em; 
    font-weight: 700; 
    color: var(--text-main); 
    line-height: 1; 
    order: 1; /* Puts number before the heading */
}


.table { width: 100%; border-collapse: collapse; margin-top: 20px; }
.table th, .table td {
    padding: 12px 15px; border-bottom: 1px solid var(--border-color);
    text-align: left; font-size: 0.95em; vertical-align: middle;
}
.table th { 
    background: #f9fafb; font-weight: 600; color: #333; 
    text-transform: uppercase; font-size: 0.85em; letter-spacing: 0.05em;
}
.table tr:hover td { background-color: #fdfdfe; }
.table td .button { padding: 5px 10px; font-size: 0.9em; margin-top: 0; margin-bottom: 0; }

.button, button[type="submit"] {
    display: inline-block; background: var(--primary); color: #fff !important;
    border-radius: var(--border-radius-md); border: none; padding: 10px 18px;
    font-weight: 500; font-size: 1em;
    transition: background-color .2s, box-shadow .2s; cursor: pointer;
    text-align: center; box-shadow: var(--box-shadow-sm);
}
.button:hover, button[type="submit"]:hover { 
    background: #115293; text-decoration: none; box-shadow: 0 4px 8px rgba(0,0,0,0.12);
}
.button i { margin-right: 6px; }

.form-group { margin-bottom: 20px; }
label { display: block; margin-bottom: 6px; font-weight: 500; color: #495057; font-size: 0.9em; }
input[type="text"], input[type="email"], input[type="password"], input[type="tel"],
input[type="url"], input[type="search"], input[type="color"], input[type="date"],
select, textarea {
    width: 100%; padding: 10px 12px; border: 1px solid var(--border-color);
    border-radius: var(--border-radius-md); margin-bottom: 5px; 
    font-size: 0.95em; background: #fff;
    transition: border-color .15s, box-shadow .15s; color: var(--text-main);
}
input[type="file"] { padding: 8px; margin-bottom: 5px; border: 1px solid var(--border-color); border-radius: var(--border-radius-md); display: block; background: #fff; }
input:focus, select:focus, textarea:focus {
    border-color: var(--primary); outline: none;
    box-shadow: 0 0 0 3px rgba(25, 118, 210, 0.15);
}
textarea { min-height: 100px; line-height: 1.5; }
.note { font-size: 0.85em; color: var(--text-muted); font-weight: normal; display: block; margin-top: 2px;}

.success, .error {
    border-radius: var(--border-radius-md); padding: 12px 18px; margin-bottom: 20px;
    font-weight: 500; font-size: 0.95em; display: flex; align-items: center;
}
.success { background: #d1e7dd; color: #0f5132; border-left: 5px solid var(--accent); }
.error { background: #f8d7da; color: #721c24; border-left: 5px solid var(--danger); }
.success i, .error i { margin-right: 10px; font-size: 1.2em; }

.form-field-error { border-color: var(--danger) !important; box-shadow: 0 0 0 3px rgba(227, 52, 47, 0.15) !important; }
.field-error-message { color: var(--danger); font-size: 0.85em; display: block; margin-top: 4px; margin-bottom: 10px; }


/* === Admin Layout Specifics === */
.admin-main {
    min-height: calc(100vh - 60px - 78px); 
    background: var(--body-bg);
    transition: margin-left .22s cubic-bezier(.4,0,.2,1);
}
.sidebar {
    position: fixed; top: 0; left: 0; bottom: 0; width: 250px;
    background: var(--sidebar-bg); color: var(--sidebar-link);
    display: flex; flex-direction: column; padding-top: 60px;
    z-index: 1020; box-shadow: 3px 0 10px rgba(0,0,0,0.05);
    transition: width .22s cubic-bezier(.4,0,.2,1), transform .22s cubic-bezier(.4,0,.2,1);
}
.sidebar a {
    color: var(--sidebar-link); text-decoration: none; display: flex; align-items: center;
    padding: 14px 20px; font-size: 1em; font-weight: 500;
    border-left: 4px solid transparent;
    transition: background .2s, border-color .2s, color .2s;
}
.sidebar a:hover { background: var(--sidebar-link-active-bg); color: var(--sidebar-link-hover); border-left-color: var(--sidebar-link-active-border); text-decoration: none; }
.sidebar a.active { background: var(--sidebar-link-active-bg); color: var(--sidebar-link-hover); font-weight: 600; border-left-color: var(--sidebar-link-active-border); }
.sidebar a i { margin-right: 12px; width: 20px; text-align: center; font-size: 1.1em; }
body.admin-layout.sidebar-collapsed .sidebar { width: 70px; }
body.admin-layout.sidebar-collapsed .sidebar a span { display: none; }
body.admin-layout.sidebar-collapsed .sidebar a { padding-left: 0; padding-right: 0; justify-content: center; }
body.admin-layout.sidebar-collapsed .sidebar:hover { width: 250px !important; }
body.admin-layout.sidebar-collapsed .sidebar:hover a span { display: inline-block !important; }
body.admin-layout.sidebar-collapsed .sidebar:hover a { justify-content: flex-start; padding-left:20px; padding-right:20px; }
body.admin-layout .site-header, 
body.admin-layout footer { margin-left: 250px; transition: margin-left .22s cubic-bezier(.4,0,.2,1); width: calc(100% - 250px); }
body.admin-layout.sidebar-collapsed .site-header,
body.admin-layout.sidebar-collapsed footer { margin-left: 70px; width: calc(100% - 70px); }
body.admin-layout .admin-main { margin-left: 250px; padding: 25px; transition: margin-left .22s cubic-bezier(.4,0,.2,1); }
body.admin-layout.sidebar-collapsed .admin-main { margin-left: 70px; }

@media (max-width: 900px) { /* Admin responsive for sidebar */
    body.admin-layout .sidebar,
    body.admin-layout.sidebar-collapsed .sidebar {
        transform: translateX(-260px); width: 250px !important; left: 0;
        z-index: 1040; box-shadow: 0 0 15px rgba(0,0,0,0.2);
        transition: transform .22s cubic-bezier(.4,0,.2,1);
    }
    body.admin-layout.sidebar-open .sidebar { transform: translateX(0); }
    body.admin-layout .site-header, body.admin-layout footer, body.admin-layout .admin-main {
        margin-left: 0 !important; width: 100% !important;
    }
    .sidebar-backdrop { display: none; position: fixed; left: 0; top: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.4); z-index: 1035; }
    body.admin-layout.sidebar-open .sidebar-backdrop { display: block; }
}


/* === Styles for Homepage Modernization & Other New Features === */
.form-section { border: 1px solid var(--border-color); padding: 20px; border-radius: var(--border-radius-lg); margin-bottom: 25px; }
.form-section legend { font-size: 1.2em; font-weight: 600; color: var(--primary); padding: 0 10px; margin-left: 10px; }
.hero-section {
    position: relative; color: #fff; padding: 80px 20px; text-align: center;
    background-image: url('https://images.unsplash.com/photo-1609142621760-3920373e33d4?q=80&w=1931&auto=format&fit=crop'); 
    background-size: cover; background-position: center center;
}
.hero-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 30, 80, 0.6); z-index: 1; }
.hero-content { position: relative; z-index: 2; }
.hero-section h1 { font-size: 2.8em; font-weight: 800; margin-bottom: 15px; color: #fff; text-shadow: 1px 1px 3px rgba(0,0,0,0.3); }
.hero-section .lead { font-size: 1.25em; color: rgba(255,255,255,0.9); max-width: 700px; margin: 0 auto 30px auto; }
.hero-section .button-cta { font-size: 1.2em; padding: 14px 35px; background-color: var(--accent); border: none; font-weight: bold; text-transform: uppercase; }
.hero-section .button-cta:hover { background-color: #117a37; transform: translateY(-2px); }
.hero-section .secondary-action-link { display: block; margin-top: 15px; color: rgba(255,255,255,0.8); text-decoration: underline; transition: color 0.2s; }
.hero-section .secondary-action-link:hover { color: #fff; }

.how-it-works-section { padding: 60px 0; background-color: var(--light); }
.section-title { text-align: center; font-size: 2.2em; font-weight: 700; margin-bottom: 40px; color: var(--text-main); }
.steps-container { display: flex; justify-content: space-around; align-items: flex-start; gap: 30px; text-align: center; flex-wrap: wrap; }
.step-box { flex: 1; min-width: 250px; padding: 20px; }
.step-box i { font-size: 3em; color: var(--primary); margin-bottom: 20px; }
.step-box h3 { font-size: 1.3em; margin-bottom: 10px; color: var(--text-main); }
.step-box p { font-size: 0.95em; color: var(--text-muted); }

.stats-banner-section {
    padding: 50px 0; background-color: var(--primary);
    background-image: linear-gradient(45deg, rgba(255,255,255,0.05) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.05) 75%, rgba(255,255,255,0.05)), linear-gradient(45deg, rgba(255,255,255,0.05) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.05) 75%, rgba(255,255,255,0.05));
    background-size: 60px 60px; color: #fff;
}
.stats-banner-section .section-title { color: #fff; text-shadow: 1px 1px 2px rgba(0,0,0,0.2); }
.stats-banner-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 30px; text-align: center; margin-top: 20px; }
.stats-banner-section .stat-item { padding: 15px; }
.stats-banner-section .stat-number { display: block; font-size: 3.5em; font-weight: 800; line-height: 1.1; }
.stats-banner-section .stat-label { font-size: 1.1em; font-weight: 400; opacity: 0.9; }

.live-feed-section { padding: 60px 0; background-color: var(--card-bg); }
.live-feed-section .section-title { margin-bottom: 30px; }
.live-feed-container { max-width: 700px; margin: 0 auto; background-color: #fff; padding: 20px 30px; border-radius: var(--border-radius-lg); box-shadow: var(--box-shadow-md); }
.feed-list { list-style: none; padding: 0; }
.feed-item { display: flex; align-items: center; padding: 15px 0; border-bottom: 1px solid var(--border-color); }
.feed-item:last-child { border-bottom: none; }
.feed-item .feed-icon-resolved, .feed-item .feed-icon-approved { font-size: 1.8em; margin-right: 20px; padding: 10px; border-radius: 50%; width: 50px; height: 50px; display: flex; align-items: center; justify-content: center; color: #fff; }
.feed-icon-resolved { background-color: var(--accent); }
.feed-icon-approved { background-color: var(--info); }
.feed-item-content { display: flex; flex-direction: column; }
.feed-item-content span { font-weight: 500; color: var(--text-main); }
.feed-item-content small { color: var(--text-muted); font-size: 0.85em; }

.final-cta-section { padding: 60px 20px; background-color: var(--dark); color: #fff; text-align: center; }
.final-cta-section h2 { color: #fff; font-size: 2em; }
.final-cta-section .button-cta { margin-top: 20px; background-color: var(--accent); }
.final-cta-section .button-cta:hover { background-color: #117a37; }


/* === General Responsive Adjustments === */
@media (max-width: 768px) { /* Tablet and smaller */
    h1 { font-size: 2em; } h2 { font-size: 1.6em; }
    .header-container { padding-left: 10px; padding-right: 10px; }
    .site-title-text { font-size: 1.2em; }
    .filters-container, .map-filters-container { flex-direction: column; align-items: stretch; }
    .filters-container .form-group, .filters-container button, .filters-container a.button,
    .map-filters-container .form-group, .map-filters-container button, .map-filters-container a.button {
        flex-basis: 100%; width: 100%; margin-bottom: 10px;
    }
     .filters-container a.button, .map-filters-container a.button { text-align: center; }

    .stats-banner-grid { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 20px; }
    .stats-banner-section .stat-number { font-size: 2.5em; }
}

@media (max-width: 600px) { /* Mobile phones */
    .container, .admin-main { padding-left: 15px; padding-right: 15px; }
    .stats-row { flex-direction: column; gap: 15px; }
    .card { padding: 20px; }
    
    /* Basic Responsive Table for Mobile */
    .table thead { display: none; } 
    .table tr { display: block; margin-bottom: 15px; border: 1px solid var(--border-color); border-radius: var(--border-radius-md); overflow: hidden; }
    .table td { display: block; text-align: right; padding-left: 50%; position: relative; border-bottom: 1px dotted #eee; }
    .table td:last-child { border-bottom: none; }
    .table td::before { 
        content: attr(data-label); 
        position: absolute; left: 10px; width: calc(50% - 20px); 
        padding-right: 10px; font-weight: bold; text-align: left; white-space: nowrap;
        font-size: 0.9em; color: var(--text-muted);
    }
    footer .container { flex-direction: column; } 
    footer .footer-nav a { margin: 5px; display: block; }
    .impact-grid { grid-template-columns: 1fr; gap: 40px; }
    .hero-section h1 { font-size: 1.8em; }
    .hero-section .lead { font-size: 1em; }
}


/* === Styles for Public Report Detail Page (view_public_report.php) === */
.report-header {
    text-align: center; padding: 20px; margin-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
}
.report-header h1 { font-size: 2.5em; margin-bottom: 5px; }
.report-header .report-subheader { font-size: 1.1em; color: var(--text-muted); margin-top: 0; }
.report-header .status-badge { margin-bottom: 15px; font-size: 1em; padding: 8px 15px; text-transform: uppercase; letter-spacing: 0.05em; }

.report-view-grid { display: grid; grid-template-columns: 1fr 350px; gap: 30px; }
.report-main-content .card { margin-bottom: 30px; }
.report-main-content h3 { font-size: 1.4em; margin-bottom: 15px; color: var(--primary); display: flex; align-items: center; }
.report-main-content h3 i { margin-right: 10px; }
.report-description { line-height: 1.8; }
.report-sidebar .card { position: sticky; top: 80px; }

.status-timeline { list-style: none; padding-left: 10px; border-left: 3px solid var(--border-color); }
.status-timeline li { position: relative; padding-left: 30px; margin-bottom: 20px; font-size: 0.95em; }
.status-timeline li:last-child { margin-bottom: 0; }
.status-timeline li i {
    position: absolute; left: -11px; top: 2px;
    font-size: 1.2em; color: #fff; background-color: var(--primary);
    border-radius: 50%; width: 22px; height: 22px;
    text-align: center; line-height: 22px;
}
.status-timeline li .fa-check-double { background-color: var(--accent); }

.social-share-buttons a {
    text-decoration: none; display: inline-flex; align-items: center; justify-content: center;
    padding: 8px 15px; margin-right: 10px; margin-bottom: 10px;
    border-radius: var(--border-radius-md); color: #fff !important;
    font-weight: 500; font-size: 0.9em; transition: opacity 0.2s;
}
.social-share-buttons a:hover { opacity: 0.85; text-decoration: none; }
.social-share-btn.facebook-share { background-color: #1877F2; }
.social-share-btn.twitter-share { background-color: #1DA1F2; }
.social-share-btn.whatsapp-share { background-color: #25D366; }

#reportDetailMap { height: 250px; width: 100%; border-radius: var(--border-radius-md); margin-bottom: 15px; }
.report-meta-box ul { list-style: none; padding: 0; }
.report-meta-box li { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #eee; font-size: 0.9em; }
.report-meta-box li:last-child { border-bottom: none; }
.report-meta-box strong { color: var(--text-muted); }
.report-meta-box span { text-align: right; font-weight: 500; }

.report-media-gallery h3, .report-media-gallery h4 { margin-top: 0; font-size: 1.3em; color: var(--primary); }
.photo-gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); gap: 10px; }
.photo-gallery-grid img { width: 100%; height: 80px; object-fit: cover; border-radius: var(--border-radius-md); border: 1px solid var(--border-color); cursor: pointer; transition: transform 0.2s, box-shadow 0.2s; }
.photo-gallery-grid img:hover { transform: scale(1.05); box-shadow: var(--box-shadow-md); }
.video-container video { width: 100%; border-radius: var(--border-radius-md); background-color: #000; }
.no-media-message { font-size: 0.95em; color: var(--text-muted); font-style: italic; }

.lightbox-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.85); z-index: 2000; 
    display: none; justify-content: center; align-items: center;
    padding: 20px; cursor: pointer;
}
.lightbox-content { max-width: 90%; max-height: 90%; object-fit: contain; cursor: default; }
.lightbox-close {
    position: absolute; top: 20px; right: 30px;
    color: #fff; font-size: 40px; font-weight: bold;
    cursor: pointer; transition: color 0.2s;
}
.lightbox-close:hover { color: #ccc; }

@media(max-width: 900px) {
    .report-view-grid { grid-template-columns: 1fr; }
    .report-sidebar .card { position: static; top: auto; }
}

/* Style for info boxes */
.info-box {
    border-radius: var(--border-radius-md);
    padding: 12px 18px;
    margin-bottom: 20px;
    font-size: 0.95em;
    display: flex;
    align-items: center;
    background: #e7f3fe; /* Light blue background */
    color: #0c5460; /* Darker blue text */
    border-left: 5px solid var(--info); 
}
.info-box i {
    margin-right: 15px;
    font-size: 1.5em;
}
.info-box a {
    font-weight: bold;
}

/* --- Modern Map View Styles --- */
#mapContainer {
    position: relative;
}
.map-loader {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.7);
    z-index: 1001; /* Above map tiles, below controls */
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 8px;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0s linear 0.2s, opacity 0.2s linear;
}
.map-loader.visible {
    visibility: visible;
    opacity: 1;
    transition-delay: 0s;
}
.map-loader .spinner {
    border: 5px solid #f3f3f3;
    border-top: 5px solid var(--primary);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.map-legend {
    padding: 6px 8px;
    background: white;
    background: rgba(255,255,255,0.8);
    box-shadow: 0 0 15px rgba(0,0,0,0.2);
    border-radius: 5px;
}
.map-legend h4 {
    margin: 0 0 5px;
    font-size: 1.1em;
}
.map-legend .legend-item {
    display: flex;
    align-items: center;
    margin-bottom: 3px;
}
.map-legend .legend-item i {
    width: 18px;
    height: 18px;
    margin-right: 5px;
    border-radius: 50%;
    border: 1px solid rgba(0,0,0,0.2);
}

/* --- Modern User Profile Page Styles --- */

.profile-page .profile-header {
    text-align: center;
    padding: 20px 0 30px 0;
}
.profile-page .profile-header h1 {
    font-size: 2.2em;
    font-weight: 800;
}
.profile-page .profile-header h1 .user-name {
    color: var(--primary);
}
.profile-page .profile-header p {
    font-size: 1.1em;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

.user-stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}
.user-stat-card {
    background-color: var(--card-bg);
    padding: 20px;
    text-align: center;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--box-shadow-sm);
}
.user-stat-card .stat-number {
    font-size: 2.5em;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
}
.user-stat-card .stat-label {
    font-size: 0.95em;
    color: var(--text-muted);
    margin-top: 5px;
}
.user-stat-card.action-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Tab Navigation */
.tabs-nav {
    display: flex;
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 20px;
}
.tab-link {
    padding: 10px 20px;
    cursor: pointer;
    background: none;
    border: none;
    font-size: 1.05em;
    font-weight: 500;
    color: var(--text-muted);
    border-bottom: 3px solid transparent;
    margin-bottom: -2px; /* Align with container border */
}
.tab-link:hover {
    color: var(--text-main);
}
.tab-link.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.tab-content {
    display: none; /* Hide all tab content by default */
}
.tab-content.active {
    display: block; /* Show only the active tab content */
}

/* User Report Card Styling */
.user-report-card {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    gap: 15px;
}
.user-report-card:last-child {
    border-bottom: none;
}
.user-report-card .report-card-status {
    flex-shrink: 0;
}
.user-report-card .report-card-details {
    flex-grow: 1;
}
.user-report-card .report-card-details h3 {
    margin: 0 0 3px 0;
    font-size: 1.1em;
}
.user-report-card .report-card-details p {
    margin: 0;
    font-size: 0.9em;
    color: var(--text-muted);
}
.user-report-card .report-card-action {
    flex-shrink: 0;
}
.no-reports-message {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}

/* --- Modern Resolved Issues Page Styles --- */
.resolved-page-header {
    text-align: center;
    padding: 20px 0 40px 0;
}
.resolved-page-header h1 {
    font-size: 2.5em;
    font-weight: 800;
    color: var(--primary);
}
.resolved-page-header p {
    font-size: 1.1em;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 30px auto;
}
.resolved-stat-box {
    background: var(--accent);
    color: #fff;
    padding: 20px;
    border-radius: var(--border-radius-lg);
    display: inline-block;
    min-width: 250px;
    box-shadow: 0 4px 15px rgba(22, 163, 74, 0.25);
}
.resolved-stat-number {
    font-size: 3em;
    font-weight: 800;
    line-height: 1;
}
.resolved-stat-label {
    font-size: 1em;
    font-weight: 500;
    opacity: 0.9;
}

.resolved-issues-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}
.report-card-resolved {
    background-color: var(--card-bg);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--box-shadow-sm);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}
.report-card-resolved:hover {
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-md);
}
.report-card-resolved .card-image-container {
    position: relative;
    width: 100%;
    height: 200px;
    background-color: #eee;
}
.report-card-resolved .card-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.report-card-resolved .status-badge {
    position: absolute;
    top: 10px;
    left: 10px;
}
.report-card-resolved .card-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.report-card-resolved .card-meta {
    font-size: 0.85em;
    color: var(--text-muted);
    margin-bottom: 8px;
    text-transform: uppercase;
}
.report-card-resolved .card-title {
    font-size: 1.2em;
    margin: 0 0 10px 0;
    flex-grow: 1; /* Pushes button to the bottom */
}
.report-card-resolved .card-description {
    font-size: 0.95em;
    margin-bottom: 15px;
    flex-grow: 1; /* Pushes button to the bottom */
}
.report-card-resolved .card-button {
    align-self: flex-start; /* Aligns button to the left */
    
/* --- Clickable Live Feed Item Styles --- */
a.feed-item-link {
    text-decoration: none;
    color: inherit; /* Inherit color from parent */
    display: block;
    transition: background-color 0.2s ease-in-out;
    border-bottom: 1px solid var(--border-color);
}
a.feed-item-link:first-child {
    border-top: 1px solid var(--border-color);
}
a.feed-item-link .feed-item {
    border-bottom: none; /* Remove border from li since link has it */
}
a.feed-item-link:hover {
    background-color: #f9f9f9;
    text-decoration: none;
}

.feed-item {
    display: flex;
    align-items: center;
    padding: 15px 10px; /* Adjust padding */
    width: 100%;
}
.feed-item-arrow {
    margin-left: auto;
    color: var(--text-muted);
    transition: color 0.2s ease-in-out;
}
a.feed-item-link:hover .feed-item-arrow {
    color: var(--primary);
}

/* --- Profile Page Report Card (Final Fix) --- */
.user-report-card {
    display: flex;
    align-items: center; /* Vertically align all items */
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    gap: 15px; /* Space between items */
}
.user-report-card:last-child {
    border-bottom: none;
}
.report-card-thumbnail {
    flex-shrink: 0; /* Prevents the image container from shrinking */
    width: 80px;
    height: 60px;
    border-radius: var(--border-radius-md);
    overflow: hidden;
    background-color: #eee;
}
.report-card-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures the image covers the area without distortion */
}
.report-card-status {
    flex-shrink: 0; /* This was missing before, now it's part of the main flex layout */
}
.report-card-details {
    flex-grow: 1; /* Allows this section to take up all available space */
    line-height: 1.4;
}
.report-card-details h3 {
    margin: 0 0 3px 0;
    font-size: 1.1em;
}
.report-card-details p {
    margin: 0;
    font-size: 0.9em;
    color: var(--text-muted);
}
.report-card-action {
    flex-shrink: 0;
    margin-left: auto; /* Pushes the "Track" button to the far right */
}
.no-reports-message {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}