/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

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

/* Header */
.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 1.8rem;
    font-weight: 700;
    color: white;
    text-decoration: none;
}

.logo a:hover {
    color: #e8f4f8;
}

.nav {
    display: flex;
    gap: 2rem;
}

.nav a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.3s;
}

.nav a:hover {
    opacity: 0.8;
}

.admin-link {
    background: rgba(255,255,255,0.1);
    padding: 0.5rem 1rem;
    border-radius: 5px;
}

/* Main content */
.main {
    min-height: calc(100vh - 200px);
}

/* Hero section */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 4rem 0;
    text-align: center;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

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

/* Search and filters */
.search-filters {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    margin: -2rem auto 0;
    max-width: 800px;
    position: relative;
    z-index: 10;
}

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

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

.search-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid #e1e5e9;
    border-radius: 5px;
    font-size: 1rem;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
}

.search-btn {
    padding: 0.75rem 1.5rem;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s;
}

.search-btn:hover {
    background: #5a6fd8;
}

.filter-row {
    display: flex;
    gap: 1rem;
}

.filter-select {
    padding: 0.75rem;
    border: 2px solid #e1e5e9;
    border-radius: 5px;
    font-size: 1rem;
    background: white;
    flex: 1;
}

.filter-select:focus {
    outline: none;
    border-color: #667eea;
}

/* Job cards */
.jobs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.job-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.job-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

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

.job-header h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.job-header h3 a {
    color: #333;
    text-decoration: none;
}

.job-header h3 a:hover {
    color: #667eea;
}

.job-status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
}

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

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

.status-result-out {
    background: #d1ecf1;
    color: #0c5460;
}

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

.job-meta {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: #666;
}

.organization {
    font-weight: 500;
}

.category {
    font-style: italic;
}

.job-details p {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.job-details strong {
    color: #333;
}

.job-dates {
    display: flex;
    gap: 1rem;
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 1rem;
}

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

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.btn-primary {
    background: #667eea;
    color: white;
}

.btn-primary:hover {
    background: #5a6fd8;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-outline {
    background: transparent;
    color: #667eea;
    border: 2px solid #667eea;
}

.btn-outline:hover {
    background: #667eea;
    color: white;
}

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

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

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

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

/* Categories section */
.categories-section {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin: 2rem 0;
    text-align: center;
}

.categories-section h2 {
    margin-bottom: 1rem;
    color: #333;
}

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

.category-card {
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.category-card:hover {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
}

.category-card h4 {
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.category-card span {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin: 2rem 0;
}

.page-link {
    padding: 0.5rem 1rem;
    border: 2px solid #e1e5e9;
    background: white;
    color: #667eea;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s;
}

.page-link:hover,
.page-link.current {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* Footer */
.footer {
    background: #343a40;
    color: white;
    padding: 2rem 0;
    text-align: center;
    margin-top: 4rem;
}

.footer-content p {
    margin-bottom: 0.5rem;
    opacity: 0.8;
}

/* Job detail page */
.job-detail {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin: 2rem 0;
}

.job-title-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.job-title-section h1 {
    font-size: 2rem;
    color: #333;
    margin-bottom: 0;
}

.job-content {
    margin-top: 2rem;
}

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

.info-item {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.info-item h3 {
    color: #667eea;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.info-item p {
    color: #333;
    line-height: 1.5;
}

.job-description {
    margin: 2rem 0;
}

.job-description h3 {
    color: #333;
    margin-bottom: 1rem;
}

.description-content {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    line-height: 1.6;
}

.job-links {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
}

.job-navigation {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e1e5e9;
}

/* About page */
.about-page {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin: 2rem 0;
}

.about-header {
    text-align: center;
    margin-bottom: 2rem;
}

.about-header h1 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 1rem;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

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

.about-section h2 {
    color: #667eea;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.about-section ul {
    padding-left: 1.5rem;
}

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

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

.category-item {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
}

/* Contact page */
.contact-page {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin: 2rem 0;
}

.contact-header {
    text-align: center;
    margin-bottom: 2rem;
}

.contact-header h1 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 1rem;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-info h2 {
    color: #667eea;
    margin-bottom: 1rem;
}

.contact-details {
    margin-top: 2rem;
}

.contact-item {
    margin-bottom: 1.5rem;
}

.contact-item h4 {
    color: #333;
    margin-bottom: 0.5rem;
}

.contact-form-section {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 8px;
}

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

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

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e1e5e9;
    border-radius: 5px;
    font-size: 1rem;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: 5px;
    margin-bottom: 1rem;
}

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

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

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #666;
}

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

.no-jobs {
    text-align: center;
    padding: 3rem;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin: 2rem 0;
}

/* Error page */
.error-page {
    text-align: center;
    padding: 4rem 2rem;
}

.error-code {
    font-size: 8rem;
    color: #667eea;
    margin-bottom: 1rem;
    font-weight: 700;
}

.error-page h2 {
    font-size: 2rem;
    color: #333;
    margin-bottom: 1rem;
}

.error-actions {
    margin: 2rem 0;
}

.error-suggestions {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e1e5e9;
}

.error-suggestions ul {
    list-style: none;
    padding: 0;
}

.error-suggestions li {
    margin-bottom: 0.5rem;
}

.error-suggestions a {
    color: #667eea;
    text-decoration: none;
}

.error-suggestions a:hover {
    text-decoration: underline;
}

/* Responsive design */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .nav {
        gap: 1rem;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .search-input-group {
        flex-direction: column;
    }

    .filter-row {
        flex-direction: column;
    }

    .jobs-grid {
        grid-template-columns: 1fr;
    }

    .job-info-grid {
        grid-template-columns: 1fr;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .categories-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}
