/* Import DM Sans font */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap');

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background-color: #ffffff;
    font-size: 16px;
    font-weight: 400;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background-color: #ffffff;
    border-bottom: 1px solid #e5e5e5;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a1a1a;
    text-decoration: none;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    margin: 0;
}

.nav-links a {
    color: #1a1a1a;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.nav-links a:hover {
    background-color: #f5f5f5;
    color: #000000;
}

/* Main content */
main {
    min-height: calc(100vh - 80px);
    padding: 2rem 0;
    background-color: #fafafa;
}

/* Welcome section */
#welcome-section {
    text-align: center;
    margin-bottom: 3rem;
    background-color: #ffffff;
    padding: 3rem 2rem;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

#welcome-section h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 1rem;
}

#welcome-section p {
    font-size: 1.125rem;
    color: #666666;
    margin-bottom: 2rem;
    font-weight: 400;
}

/* Forms */
.form-container {
    background-color: #ffffff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    max-width: 500px;
    margin: 2rem auto;
    border: 1px solid #e5e5e5;
}

.form-container h2 {
    text-align: center;
    margin-bottom: 1.5rem;
    color: #1a1a1a;
    font-size: 1.5rem;
    font-weight: 600;
}

.form-group {
    margin-bottom: 1.25rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #1a1a1a;
    font-size: 0.875rem;
}

input, select, textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 1rem;
    font-family: 'DM Sans', sans-serif;
    transition: border-color 0.2s ease;
    background-color: #ffffff;
    color: #1a1a1a;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

.btn {
    background-color: #1a1a1a;
    color: #ffffff;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    font-family: 'DM Sans', sans-serif;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn:hover {
    background-color: #000000;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn:active {
    transform: translateY(0);
}

.btn-secondary {
    background-color: #6b7280;
    color: #ffffff;
}

.btn-secondary:hover {
    background-color: #4b5563;
}

.btn-danger {
    background-color: #dc2626;
    color: #ffffff;
}

.btn-danger:hover {
    background-color: #b91c1c;
}

.btn-success {
    background-color: #059669;
    color: #ffffff;
}

.btn-success:hover {
    background-color: #047857;
}

.btn-warning {
    background-color: #d97706;
    color: #ffffff;
}

.btn-warning:hover {
    background-color: #b45309;
}

/* Cards */
.card {
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border: 1px solid #e5e5e5;
    transition: box-shadow 0.2s ease;
}

.card:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e5e5e5;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a1a;
}

.card-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-lost {
    background-color: #fee2e2;
    color: #991b1b;
}

.badge-found {
    background-color: #d1fae5;
    color: #065f46;
}

.badge-pending {
    background-color: #fef3c7;
    color: #92400e;
}

.badge-approved {
    background-color: #d1fae5;
    color: #065f46;
}

.badge-rejected {
    background-color: #fee2e2;
    color: #991b1b;
}

/* Grid */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

/* Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.stat-card {
    background-color: #ffffff;
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e5e5;
    transition: box-shadow 0.2s ease;
}

.stat-card:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: #6b7280;
    font-size: 0.875rem;
    font-weight: 500;
}

/* Tables */
.table-container {
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    margin: 2rem 0;
    border: 1px solid #e5e5e5;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #e5e5e5;
}

th {
    background-color: #f9fafb;
    font-weight: 600;
    color: #374151;
    font-size: 0.875rem;
}

tr:hover {
    background-color: #f9fafb;
}

/* Search and filters */
.search-container {
    background-color: #ffffff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
    border: 1px solid #e5e5e5;
}

.filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

/* Image preview */
.image-preview {
    max-width: 200px;
    max-height: 200px;
    border-radius: 4px;
    margin: 1rem 0;
    border: 1px solid #e5e5e5;
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: 4px;
    margin: 1rem 0;
    font-weight: 500;
}

.alert-success {
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.alert-error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

.alert-warning {
    background-color: #fef3c7;
    color: #92400e;
    border: 1px solid #fcd34d;
}

/* Toggle forms */
.form-toggle {
    text-align: center;
    margin-bottom: 2rem;
    background-color: #f9fafb;
    padding: 1rem;
    border-radius: 4px;
    border: 1px solid #e5e5e5;
}

.toggle-btn {
    background: none;
    border: none;
    color: #1a1a1a;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    font-family: 'DM Sans', sans-serif;
}

.toggle-btn:hover {
    background-color: #e5e7eb;
}

/* Contact info */
.contact-info {
    background-color: #f9fafb;
    padding: 1rem;
    border-radius: 4px;
    margin-top: 1rem;
    border-left: 4px solid #1a1a1a;
}

.contact-info p {
    margin: 0.25rem 0;
    font-size: 0.875rem;
    color: #374151;
}

/* Admin specific styles */
.admin-header {
    background-color: #1a1a1a;
    color: #ffffff;
}

.admin-header .logo {
    color: #ffffff;
}

.admin-header .nav-links a {
    color: #ffffff;
}

.admin-header .nav-links a:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.admin-sidebar {
    background-color: #111827;
    color: #ffffff;
    padding: 1rem;
    min-height: calc(100vh - 80px);
    width: 250px;
}

.admin-sidebar h3 {
    margin-bottom: 1rem;
    font-size: 1.125rem;
    font-weight: 600;
}

.admin-sidebar a {
    color: #d1d5db;
    text-decoration: none;
    display: block;
    padding: 0.75rem 1rem;
    border-radius: 4px;
    margin-bottom: 0.5rem;
    transition: all 0.2s ease;
    font-weight: 400;
}

.admin-sidebar a:hover {
    background-color: #374151;
    color: #ffffff;
}

.admin-sidebar a.active {
    background-color: #1a1a1a;
    color: #ffffff;
    font-weight: 500;
}

/* Responsive design */
@media (max-width: 768px) {
    .nav-links {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .filters {
        grid-template-columns: 1fr;
    }
    
    .table-container {
        overflow-x: auto;
    }
    
    .card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .admin-sidebar {
        width: 100%;
        min-height: auto;
    }
    
    main {
        padding: 1rem 0;
    }
    
    .form-container {
        margin: 1rem auto;
        padding: 1.5rem;
    }
    
    #welcome-section {
        padding: 2rem 1rem;
    }
    
    #welcome-section h1 {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .card {
        padding: 1rem;
    }
    
    .btn {
        padding: 0.625rem 1.25rem;
        font-size: 0.875rem;
    }
}

/* Loading spinner */
.spinner {
    border: 4px solid #e5e5e5;
    border-top: 4px solid #1a1a1a;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Hidden elements */
.hidden {
    display: none;
}

/* Text utilities */
.text-center {
    text-align: center;
}

/* Focus styles for accessibility */
button:focus, input:focus, select:focus, textarea:focus, .btn:focus {
    outline: 2px solid #1a1a1a;
    outline-offset: 2px;
}

/* Selection styling */
::selection {
    background-color: #1a1a1a;
    color: #ffffff;
}

/* Search and filters */
.search-container {
    background: #ffffff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
    border: 1px solid #e5e5e5;
}

.filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

/* Image preview */
.image-preview {
    max-width: 200px;
    max-height: 200px;
    border-radius: 8px;
    margin: 1rem 0;
    border: 1px solid #e5e5e5;
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    font-weight: 500;
}

.alert-success {
    background: #f8f9fa;
    color: #1a1a1a;
    border: 1px solid #1a1a1a;
}

.alert-error {
    background: #fff5f5;
    color: #dc2626;
    border: 1px solid #dc2626;
}

.alert-warning {
    background: #fffbeb;
    color: #d97706;
    border: 1px solid #d97706;
}

/* Toggle forms */
.form-toggle {
    text-align: center;
    margin-bottom: 2rem;
    background: #ffffff;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #e5e5e5;
}

.toggle-btn {
    background: none;
    border: none;
    color: #1a1a1a;
    cursor: pointer;
    font-size: 1.1rem;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.toggle-btn:hover {
    color: #ffffff;
    background: #1a1a1a;
}

/* Loading animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card, .form-container, .search-container {
    animation: fadeInUp 0.4s ease-out;
}

/* Enhanced image preview */
.image-preview {
    max-width: 200px;
    max-height: 200px;
    border-radius: 8px;
    margin: 1rem 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    border: 1px solid #e5e5e5;
}

.image-preview:hover {
    transform: scale(1.02);
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        flex-direction: column;
        gap: 1rem;
    }
    
    .grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .filters {
        grid-template-columns: 1fr;
    }
    
    .table-container {
        overflow-x: auto;
    }
    
    .card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}

/* Loading spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Hidden elements */
.hidden {
    display: none;
}

/* Contact info */
.contact-info {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin-top: 1rem;
    border-left: 4px solid #1a1a1a;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.contact-info p {
    margin: 0.5rem 0;
    font-size: 0.95rem;
    font-weight: 500;
}

/* Admin specific styles */
.admin-header {
    background: #1a1a1a;
    color: #ffffff;
}

.admin-sidebar {
    background: #2d3748;
    color: white;
    padding: 1rem;
    min-height: 100vh;
}

.admin-sidebar a {
    color: white;
    text-decoration: none;
    display: block;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    margin-bottom: 0.5rem;
    transition: background-color 0.3s;
    font-weight: 500;
}

.admin-sidebar a:hover {
    background-color: rgba(255,255,255,0.1);
}

.admin-sidebar a.active {
    background: #1a1a1a;
    color: #ffffff;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #1a1a1a;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #333333;
}

/* Text selection */
::selection {
    background: #1a1a1a;
    color: #ffffff;
}

/* Focus outline for accessibility */
button:focus, input:focus, select:focus, textarea:focus {
    outline: 2px solid #1a1a1a;
    outline-offset: 2px;
}

/* Enhanced spinner */
.spinner {
    border: 4px solid #e5e5e5;
    border-top: 4px solid #1a1a1a;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
} 