/* Learning Space Information System - Main Stylesheet */

/* ===== CSS RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    margin-bottom: 0.5rem;
    font-weight: 600;
    line-height: 1.2;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p { margin-bottom: 1rem; }

a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #3498db;
}

/* ===== UTILITY CLASSES ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Skip to content styles removed - not needed for this simple navigation */

.screen-reader-only {
    position: absolute !important;
    height: 1px;
    width: 1px;
    overflow: hidden;
    clip: rect(1px, 1px, 1px, 1px);
    white-space: nowrap;
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

.hidden { display: none; }

/* ===== HEADER & NAVIGATION ===== */
.header {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.nav-brand h1 {
    margin: 0;
    font-size: 1.5rem;
    color: #2c3e50;
}

.nav-brand a {
    color: #2c3e50;
    font-weight: 700;
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-brand a:hover {
    color: #007bff;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 1rem;
    flex-wrap: wrap;
}

.nav-menu li {
    margin: 0;
}

.nav-menu a {
    color: #6c757d;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: block;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: #007bff;
    background-color: #f8f9fa;
    transform: translateY(-1px);
}

.nav-menu a.active {
    font-weight: 600;
    background-color: #e3f2fd;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    line-height: 1;
}

.btn-primary {
    background-color: #3498db;
    color: white;
}

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

.btn-secondary {
    background-color: #95a5a6;
    color: white;
}

.btn-secondary:hover {
    background-color: #7f8c8d;
    color: white;
}

.btn-success {
    background-color: #27ae60;
    color: white;
}

.btn-success:hover {
    background-color: #219a52;
    color: white;
}

.btn-danger {
    background-color: #e74c3c;
    color: white;
}

.btn-danger:hover {
    background-color: #c0392b;
    color: white;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

/* ===== HERO SECTION ===== */
.hero {
    position: relative;
    color: white;
    padding: 4rem 0;
    text-align: center;
    overflow: hidden;
    min-height: 400px;
}

/* Hero Carousel Backgrounds */
.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
    cursor: pointer;
    z-index: 0;
}

.hero-background.active {
    opacity: 1;
}

.hero-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.3) 0%, rgba(118, 75, 162, 0.3) 100%);
    z-index: 1;
}

/* Fallback gradient when no images available */
.hero.no-images {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Ensure hero content stays above backgrounds */
.hero .container {
    position: relative;
    z-index: 2;
}

.hero-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* ===== SEARCH FORM ===== */
.search-form {
    max-width: 600px;
    margin: 0 auto;
}

.search-input-group {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.search-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
}

.search-select {
    padding: 0.75rem 1rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    background-color: white;
    min-width: 150px;
}

.search-btn {
    padding: 0.75rem 1.5rem;
    background-color: #2c3e50;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.search-btn:hover {
    background-color: #34495e;
}

/* ===== STATISTICS SECTION ===== */
.stats-section {
    padding: 3rem 0;
    background-color: white;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.stat-card {
    text-align: center;
    padding: 2rem 1rem;
    background-color: #f8f9fa;
    border-radius: 8px;
    border: 2px solid #e9ecef;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
    border-color: #3498db;
}

.stat-card h3 {
    font-size: 2.5rem;
    color: #3498db;
    margin-bottom: 0.5rem;
}

.stat-card p {
    color: #666;
    font-weight: 500;
    margin: 0;
}

.stat-card.highlight {
    background-color: #fff3cd;
    border-color: #ffeaa7;
}

.stat-card.highlight h3 {
    color: #e17055;
}

/* ===== SECTIONS ===== */
.featured-section,
.districts-section,
.cta-section,
.admin-section {
    padding: 3rem 0;
}

.featured-section {
    background-color: white;
}

.districts-section {
    background-color: #f8f9fa;
}

.cta-section {
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    color: white;
    text-align: center;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

/* ===== GRIDS ===== */
.spaces-grid,
.districts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.districts-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* ===== SPACE CARDS ===== */
.space-card,
.district-card {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.space-card {
    padding: 0;
    position: relative;
    overflow: hidden;
}

.space-card::before {
    content: "coffee";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-45deg);
    font-size: 5.5rem;
    font-weight: bold;
    color: #f0f0f0;
    opacity: 0.15;
    z-index: 1;
    pointer-events: none;
    user-select: none;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    white-space: nowrap;
}

.space-card .space-card-header,
.space-card .space-card-body,
.space-card .space-card-footer {
    position: relative;
    z-index: 2;
    padding: 0 1.5rem;
}

.space-card .space-card-header {
    padding-top: 1.5rem;
}

.space-card .space-card-footer {
    padding-bottom: 1.5rem;
}

/* ===== SPACES LISTING IMAGES ===== */
.space-item {
    position: relative;
}

.grid-view .space-item {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.grid-view .space-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

/* Background logo design with coffee watermark */
.space-item {
    position: relative;
    overflow: hidden;
}

.space-item::before {
    content: "coffee";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-45deg);
    font-size: 5.5rem;
    font-weight: bold;
    color: #f0f0f0;
    opacity: 0.15;
    z-index: 1;
    pointer-events: none;
    user-select: none;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    white-space: nowrap;
}

.space-item .space-content,
.space-item .space-actions {
    position: relative;
    z-index: 2;
}

.list-view .space-content {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.space-card:hover,
.district-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.space-card-header {
    margin-bottom: 1rem;
}

.space-card-header h3 {
    margin-bottom: 0.5rem;
}

.space-card-header a {
    color: #2c3e50;
    font-weight: 600;
}

.space-card-header a:hover {
    color: #3498db;
}

.rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.stars {
    color: #f39c12;
    font-size: 1rem;
    line-height: 1;
}

.stars.large {
    font-size: 1.5rem;
}

.star {
    display: inline-block;
    font-size: inherit;
    line-height: 1;
}

.star.filled {
    color: #f39c12;
}

.star.half {
    color: #f39c12;
    opacity: 0.7;
}

.star.empty {
    color: #ddd;
}

.rating-text {
    font-size: 0.875rem;
    color: #666;
    font-weight: 500;
}

.location {
    color: #666;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.description {
    color: #555;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.amenities {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.amenity {
    background-color: #e8f4f8;
    color: #2c3e50;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

.space-card-footer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

/* ===== FORMS ===== */
.form-container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.form-section {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #e9ecef;
}

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

.form-section h2 {
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.form-description {
    color: #666;
    margin-bottom: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #2c3e50;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

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

.form-help {
    display: block;
    margin-top: 0.25rem;
    color: #666;
    font-size: 0.875rem;
}

.form-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.form-disclaimer {
    margin-top: 1rem;
    color: #666;
    font-size: 0.875rem;
}

/* ===== CHECKBOXES ===== */
.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
    padding: 0.5rem 0;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    background-color: white;
    border: 2px solid #ddd;
    border-radius: 4px;
    position: relative;
    flex-shrink: 0;
    margin-top: 0.125rem;
    transition: all 0.3s ease;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background-color: #3498db;
    border-color: #3498db;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark:after {
    content: "✓";
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.amenities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1rem;
}

.amenity-info {
    display: flex;
    flex-direction: column;
}

.amenity-name {
    font-weight: 500;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

/* ===== SPACE DETAIL PAGE ===== */
.breadcrumb {
    margin: 1rem 0;
    font-size: 0.875rem;
    color: #666;
}

.breadcrumb a {
    color: #3498db;
}

.space-detail {
    background: white;
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.space-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e9ecef;
}

.space-title h1 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

.space-info-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.info-section {
    margin-bottom: 2rem;
}

.info-section h2,
.info-section h3 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

.info-card {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.info-card h3 {
    color: #2c3e50;
    margin-bottom: 1rem;
    font-size: 1.125rem;
}

.amenities-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.amenity-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.5rem 0;
}

.amenity-icon {
    font-size: 1.25rem;
    width: 2rem;
    text-align: center;
}

.amenity-label {
    flex: 1;
    font-weight: 500;
}

.amenity-status {
    font-weight: bold;
    font-size: 1.125rem;
}

.amenity-status.available {
    color: #27ae60;
}

.amenity-status.not-available {
    color: #e74c3c;
}

.social-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.social-link {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    text-align: center;
    transition: all 0.3s ease;
}

.social-link.facebook {
    background-color: #3b5998;
    color: white;
}

.social-link.instagram {
    background: linear-gradient(45deg, #f09433 0%,#e6683c 25%,#dc2743 50%,#cc2366 75%,#bc1888 100%);
    color: white;
}

/* ===== REVIEWS SECTION ===== */
.reviews-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e9ecef;
}

.reviews-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.review-form {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.rating-input {
    display: flex;
    flex-direction: row-reverse;
    gap: 0.25rem;
}

.rating-input input[type="radio"] {
    display: none;
}

.rating-input label {
    font-size: 2rem;
    color: #ddd;
    cursor: pointer;
    transition: color 0.3s ease;
}

.rating-input input[type="radio"]:checked ~ label,
.rating-input label:hover,
.rating-input label:hover ~ label {
    color: #f39c12;
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.review-item {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid #3498db;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.reviewer-name {
    color: #2c3e50;
    font-weight: 600;
}

.review-date {
    color: #666;
    font-size: 0.875rem;
}

.review-text p {
    color: #555;
    line-height: 1.6;
    margin: 0;
}

/* ===== LISTING PAGE ===== */
.page-header {
    text-align: center;
    margin: 2rem 0;
}

.page-header h1 {
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.search-filter-section {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: relative;
}


.filter-loading .spinner {
    width: 30px;
    height: 30px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 8px;
}

.filter-loading {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    z-index: 1000;
    font-size: 14px;
    color: #666;
}

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

.filter-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
}

.filter-group {
    flex: 1;
    min-width: 200px;
}

.amenity-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.filter-actions {
    display: flex;
    gap: 0.5rem;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    background: white;
    padding: 1rem 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.filter-indicator {
    color: #3498db;
    font-weight: 500;
    background: #e8f4f8;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    margin-left: 0.5rem;
}

.view-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.view-toggle {
    display: flex;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.view-btn {
    padding: 0.5rem 1rem;
    background: white;
    color: #666;
    text-decoration: none;
    border-right: 1px solid #ddd;
    transition: all 0.3s ease;
}

.view-btn:last-child {
    border-right: none;
}

.view-btn:hover,
.view-btn.active {
    background: #3498db;
    color: white;
}

/* ===== SPACE LISTING VIEWS ===== */
.spaces-container.grid-view {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.spaces-container.list-view {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.list-view .space-item {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.grid-view .space-item {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.grid-view .space-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.space-content {
    flex: 1;
}

.space-header h3 {
    margin-bottom: 0.5rem;
}

.space-header a {
    color: #2c3e50;
    font-weight: 600;
}

.space-location {
    color: #666;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.separator {
    color: #ccc;
}

.space-amenities {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.space-hours {
    color: #666;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.space-actions {
    margin-top: 1rem;
}

.list-view .space-actions {
    margin-top: 0;
}

/* ===== PAGINATION ===== */
.pagination-section {
    margin: 3rem 0;
    text-align: center;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 0.25rem;
    margin-bottom: 1rem;
}

.page-btn {
    padding: 0.75rem 1rem;
    background: white;
    color: #666;
    text-decoration: none;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.page-btn:hover {
    background: #f8f9fa;
    color: #2c3e50;
}

.page-btn.current {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

.page-ellipsis {
    padding: 0.75rem 1rem;
    color: #666;
}

.pagination-info {
    color: #666;
    font-size: 0.875rem;
}

/* ===== ALERTS ===== */
.alert {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
}

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

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

.alert h3 {
    margin-bottom: 0.5rem;
    color: inherit;
}

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

.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    background: white;
    border-radius: 8px;
    color: #666;
}

.empty-state h3 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

/* ===== ADMIN PANEL ===== */
.admin-stats {
    margin-bottom: 3rem;
}

.district-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.district-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: white;
    padding: 1rem;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.district-name {
    font-weight: 500;
    color: #2c3e50;
}

.district-count {
    font-weight: 600;
    color: #3498db;
}

.contributions-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contribution-item {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.contribution-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.contribution-meta {
    color: #666;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.contribution-actions {
    display: flex;
    gap: 0.5rem;
}

.contribution-details {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

.contributor-contact {
    background: #f8f9fa;
    padding: 0.75rem 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.data-section h4 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

.data-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.data-item {
    background: #f8f9fa;
    padding: 0.75rem;
    border-radius: 4px;
    font-size: 0.875rem;
}

.data-item.full-width {
    grid-column: 1 / -1;
}

.amenities-preview {
    margin-top: 1rem;
    font-size: 0.875rem;
}

.changes-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.change-item {
    background: #fff3cd;
    padding: 0.75rem;
    border-radius: 4px;
    border-left: 4px solid #ffc107;
    font-size: 0.875rem;
}

.quick-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ===== ADVANCED MODERATION ===== */
.status-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid #e9ecef;
}

.tab {
    padding: 1rem 1.5rem;
    color: #666;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
}

.tab:hover,
.tab.active {
    color: #3498db;
    border-bottom-color: #3498db;
}

.moderation-filters {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.bulk-actions {
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.bulk-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.contributions-table {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.table-responsive {
    overflow-x: auto;
}

.contributions-table table {
    width: 100%;
    border-collapse: collapse;
}

.contributions-table th,
.contributions-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
}

.contributions-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #2c3e50;
}

.contribution-type {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

.contribution-type.new_space {
    background: #d1ecf1;
    color: #0c5460;
}

.contribution-type.update_info {
    background: #fff3cd;
    color: #856404;
}

.contributor-info strong {
    color: #2c3e50;
}

.contribution-details {
    max-width: 300px;
}

.status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

.status-pending {
    background: #fff3cd;
    color: #856404;
}

.status-approved {
    background: #d4edda;
    color: #155724;
}

.status-rejected {
    background: #f8d7da;
    color: #721c24;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* ===== MODAL ===== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: 8px;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    margin: 1rem;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.modal-close {
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    line-height: 1;
}

.modal-body {
    padding: 1.5rem;
}

/* ===== FOOTER ===== */
.footer {
    background-color: #2c3e50;
    color: white;
    padding: 3rem 0 1rem;
    margin-top: auto;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
    color: white;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: #bdc3c7;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #34495e;
    color: #bdc3c7;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .container {
        padding: 0 0.75rem;
    }
    
    .hero-content h2 {
        font-size: 2rem;
    }
    
    .hero-content p {
        font-size: 1.125rem;
    }
    
    .search-input-group {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 1rem;
    }
    
    .spaces-grid,
    .districts-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .space-info-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .space-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .reviews-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .filter-row {
        flex-direction: column;
    }
    
    .results-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .view-controls {
        width: 100%;
        justify-content: space-between;
    }
    
    .spaces-container.grid-view {
        grid-template-columns: 1fr;
    }
    
    .list-view .space-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .amenities-grid {
        grid-template-columns: 1fr;
    }
    
    .navbar .container {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .nav-menu {
        width: 100%;
        justify-content: center;
        gap: 0.5rem;
    }

    .nav-menu a {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
    }

    .nav-brand h1 {
        font-size: 1.25rem;
    }
    
    .contribution-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .data-grid {
        grid-template-columns: 1fr;
    }
    
    .status-tabs {
        flex-wrap: wrap;
    }
    
    .bulk-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }
    
    .action-buttons {
        justify-content: flex-start;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 2rem 0;
    }
    
    .hero-content h2 {
        font-size: 1.75rem;
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    .form-container {
        padding: 1rem;
    }
    
    .space-detail {
        padding: 1rem;
    }
    
    .stat-card {
        padding: 1rem;
    }
    
    .stat-card h3 {
        font-size: 2rem;
    }

    .nav-menu {
        flex-direction: column;
        width: 100%;
        gap: 0.25rem;
    }

    .nav-menu a {
        text-align: center;
        padding: 0.75rem;
    }
}

/* ===== PRINT STYLES ===== */
@media print {
    .header,
    .footer,
    .search-filter-section,
    .cta-section,
    .form-actions,
    .contribution-actions,
    .action-buttons {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
    
    .space-detail,
    .form-container,
    .contribution-item {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}