:root {
    --color-primary: #d97706;
    --color-primary-dark: #b45309;
    --color-secondary: #10b981;
    --color-background: #fafaf9;
    --color-surface: #ffffff;
    --color-border: #e7e5e4;
    --color-text: #292524;
    --color-text-light: #78716c;
    --color-danger: #ef4444;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.12);
}

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

body {
    font-family: 'Work Sans', sans-serif;
    background: linear-gradient(135deg, #fafaf9 0%, #f5f5f4 100%);
    color: var(--color-text);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header Styles */
.header {
    background: var(--color-surface);
    border-bottom: 3px solid var(--color-primary);
    padding: 2rem 0;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

.header-content h1 {
    font-family: 'Fraunces', serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 0.25rem;
    letter-spacing: -0.02em;
}

.subtitle {
    color: var(--color-text-light);
    font-size: 1rem;
    font-weight: 500;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    margin-top: 1.5rem;
    border-top: 1px solid var(--color-border);
    padding-top: 1rem;
}

.nav-link {
    color: var(--color-text-light);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: var(--color-primary);
    background: rgba(217, 119, 6, 0.1);
}

.nav-link.active {
    color: var(--color-primary);
    background: rgba(217, 119, 6, 0.15);
    font-weight: 600;
}

/* Main Content */
.main-content {
    padding: 2rem 0 4rem;
}

.form-section {
    background: var(--color-surface);
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: var(--shadow-md);
    max-width: 800px;
    margin: 0 auto;
}

.form-header {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid var(--color-border);
}

.form-header h2 {
    font-family: 'Fraunces', serif;
    font-size: 1.875rem;
    color: var(--color-text);
    margin-bottom: 0.5rem;
}

.form-header p {
    color: var(--color-text-light);
}

/* Form Styles */
.report-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--color-text);
    font-size: 0.938rem;
}

.help-text {
    font-size: 0.875rem;
    color: var(--color-text-light);
    margin-bottom: 0.75rem;
}

input[type="text"],
input[type="email"],
select,
textarea {
    padding: 0.75rem 1rem;
    border: 2px solid var(--color-border);
    border-radius: 8px;
    font-family: 'Work Sans', sans-serif;
    font-size: 1rem;
    transition: all 0.2s ease;
    background: var(--color-background);
}

input[type="text"]:focus,
input[type="email"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    background: var(--color-surface);
    box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.1);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

input[type="file"] {
    padding: 0.75rem;
    border: 2px dashed var(--color-border);
    border-radius: 8px;
    background: var(--color-background);
    cursor: pointer;
    transition: all 0.2s ease;
}

input[type="file"]:hover {
    border-color: var(--color-primary);
    background: rgba(217, 119, 6, 0.05);
}

.photo-preview {
    margin-top: 1rem;
    display: none;
}

.photo-preview.active {
    display: block;
}

.photo-preview img {
    max-width: 100%;
    max-height: 300px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

/* Map Styles */
.map-container {
    height: 400px;
    border: 2px solid var(--color-border);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.location-status {
    font-size: 0.875rem;
    color: var(--color-text-light);
    font-style: italic;
}

.location-status.active {
    color: var(--color-secondary);
    font-weight: 500;
}

/* Buttons */
.btn {
    padding: 0.875rem 2rem;
    border: none;
    border-radius: 8px;
    font-family: 'Work Sans', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background: var(--color-primary);
    color: white;
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--color-border);
    color: var(--color-text);
}

.btn-secondary:hover {
    background: #d6d3d1;
}

.btn-success {
    background: var(--color-secondary);
    color: white;
}

.btn-success:hover {
    background: #059669;
}

.btn-danger {
    background: var(--color-danger);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

/* Success Message */
.success-message {
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(16, 185, 129, 0.05) 100%);
    border-radius: 12px;
    border: 2px solid var(--color-secondary);
}

.success-message h3 {
    font-family: 'Fraunces', serif;
    color: var(--color-secondary);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.success-message p {
    color: var(--color-text-light);
    margin-bottom: 1.5rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

/* Issue Cards (for map and moderation views) */
.issues-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.issue-card {
    background: var(--color-surface);
    border: 2px solid var(--color-border);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.2s ease;
    position: relative;
}

.issue-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.issue-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

.issue-badge.pending {
    background: rgba(217, 119, 6, 0.15);
    color: var(--color-primary);
}

.issue-badge.active {
    background: rgba(16, 185, 129, 0.15);
    color: var(--color-secondary);
}

.issue-badge.archived {
    background: rgba(120, 113, 108, 0.15);
    color: var(--color-text-light);
}

.issue-card h3 {
    font-family: 'Fraunces', serif;
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--color-text);
}

.issue-category {
    font-size: 0.875rem;
    color: var(--color-text-light);
    text-transform: capitalize;
    margin-bottom: 0.75rem;
}

.issue-description {
    color: var(--color-text);
    margin-bottom: 1rem;
    line-height: 1.5;
}

.issue-meta {
    font-size: 0.813rem;
    color: var(--color-text-light);
    border-top: 1px solid var(--color-border);
    padding-top: 0.75rem;
    margin-top: 1rem;
}

.issue-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

.issue-actions .btn {
    flex: 1;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.issue-photo {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 1rem;
}

/* Map View Styles */
.map-view-container {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 1.5rem;
    margin-top: 2rem;
}

.map-main {
    height: 600px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.issues-sidebar {
    background: var(--color-surface);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    overflow-y: auto;
    max-height: 600px;
}

.sidebar-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--color-border);
}

.sidebar-header h2 {
    font-family: 'Fraunces', serif;
    font-size: 1.5rem;
    color: var(--color-text);
}

.filter-group {
    margin-bottom: 1.5rem;
}

.filter-group label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    display: block;
}

/* Login Form */
.login-container {
    max-width: 400px;
    margin: 4rem auto;
}

.login-form {
    background: var(--color-surface);
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: var(--shadow-md);
}

.login-form h2 {
    font-family: 'Fraunces', serif;
    text-align: center;
    margin-bottom: 2rem;
    color: var(--color-text);
}

.error-message {
    background: rgba(239, 68, 68, 0.1);
    border: 2px solid var(--color-danger);
    color: var(--color-danger);
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-content h1 {
        font-size: 2rem;
    }
    
    .form-section {
        padding: 1.5rem;
    }
    
    .map-view-container {
        grid-template-columns: 1fr;
    }
    
    .issues-sidebar {
        max-height: 400px;
    }
    
    .nav-links {
        flex-wrap: wrap;
        gap: 0.75rem;
    }
}

/* Leaflet Popup Customization */
.leaflet-popup-content-wrapper {
    border-radius: 8px;
    box-shadow: var(--shadow-md);
}

.leaflet-popup-content {
    margin: 1rem;
    font-family: 'Work Sans', sans-serif;
}

.popup-title {
    font-family: 'Fraunces', serif;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 0.5rem;
}

.popup-category {
    font-size: 0.875rem;
    color: var(--color-text-light);
    text-transform: capitalize;
}

.popup-photo {
    width: 100%;
    max-height: 150px;
    object-fit: cover;
    border-radius: 6px;
    margin: 0.75rem 0;
}
