/* Explore Jobs Page Specific Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background: #f8f9fa;
}

.explore-jobs-main {
    min-height: calc(100vh - 200px);
    padding: 3rem 1rem;
}

.explore-jobs-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* Page Header */
.page-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.page-header p {
    color: #666666;
    font-size: 1rem;
}

/* Filters Section */
.filters-section {
    background: #ffffff;
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.search-box {
    position: relative;
    margin-bottom: 1rem;
}

.search-box svg {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #999999;
    pointer-events: none;
}

.search-box input {
    width: 100%;
    padding: 0.9rem 1.2rem 0.9rem 3rem;
    border: 2px solid #e8e8e8;
    border-radius: 30px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #ffffff;
    color: #1a1a1a;
    font-family: inherit;
}

.search-box input:focus {
    outline: none;
    border-color: #2c384d;
    box-shadow: 0 0 0 3px rgba(44, 56, 77, 0.1);
}

.search-box input::placeholder {
    color: #999999;
}

.filter-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

/* Custom Select Dropdown (matching registration style) */
.custom-select {
    position: relative;
    width: 100%;
}

.select-trigger {
    width: 100%;
    padding: 0.9rem 1.2rem;
    border: 2px solid #e8e8e8;
    border-radius: 30px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background: #ffffff;
    color: #1a1a1a;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.select-trigger:hover {
    border-color: #2c384d;
}

.select-trigger.active {
    border-color: #2c384d;
    box-shadow: 0 0 0 3px rgba(44, 56, 77, 0.1);
}

.select-value {
    flex: 1;
    text-align: left;
    color: #1a1a1a;
}

.select-value.placeholder {
    color: #999999;
}

.select-arrow {
    width: 12px;
    height: 8px;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.select-trigger.active .select-arrow {
    transform: rotate(180deg);
}

.select-options {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    right: 0;
    background: #ffffff;
    border: 2px solid #e8e8e8;
    border-radius: 12px;
    list-style: none;
    padding: 0.5rem 0;
    margin: 0;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    max-height: 200px;
    overflow-y: auto;
    display: none;
}

.select-options.active {
    display: block;
}

.select-options li {
    padding: 0.75rem 1.2rem;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #1a1a1a;
    font-size: 0.95rem;
}

.select-options li:hover {
    background: #f8f9fa;
    color: #2c384d;
}

.select-options li.selected {
    background: #2c384d;
    color: #ffffff;
}

.select-options li.selected:hover {
    background: #1e2835;
}

/* Jobs Container */
.jobs-container {
    position: relative;
}

.loading-state,
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e8e8e8;
    border-top-color: #2c384d;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.spinner.small {
    width: 24px;
    height: 24px;
    border-width: 3px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.empty-state svg {
    color: #999999;
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.5rem;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: #666666;
}

/* Jobs List */
.jobs-list {
    display: grid;
    gap: 1.5rem;
}

.load-more-state {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 0;
    color: #4a5568;
    font-size: 0.95rem;
}

.job-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.job-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
    border-color: #2c384d;
}

.job-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    gap: 1rem;
}

.job-title-section {
    flex: 1;
}

.job-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.job-company {
    font-size: 1rem;
    color: #2c384d;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.job-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1rem;
}

.job-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #666666;
    font-size: 0.9rem;
}

.job-meta-item svg {
    width: 18px;
    height: 18px;
    color: #2c384d;
    flex-shrink: 0;
}

.job-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.job-badge {
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: capitalize;
}

.job-badge.type {
    background: #e8f0f8;
    color: #2c384d;
}

.job-badge.site {
    background: #f0f4f8;
    color: #2c5282;
}

.job-description {
    color: #666666;
    line-height: 1.6;
    margin-top: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Allow HTML formatting to display properly */
.job-description p {
    margin: 0.5rem 0;
}

.job-description p:first-child {
    margin-top: 0;
}

.job-description p:last-child {
    margin-bottom: 0;
}

.job-description ul,
.job-description ol {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.job-description ul {
    list-style-type: disc;
}

.job-description ol {
    list-style-type: decimal;
}

.job-description li {
    margin: 0.25rem 0;
}

.job-description strong,
.job-description b {
    font-weight: 600;
    color: #1a1a1a;
}

.job-description em,
.job-description i {
    font-style: italic;
}

.job-description u {
    text-decoration: underline;
}

.job-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e8e8e8;
}

.job-posted {
    color: #999999;
    font-size: 0.85rem;
}

.btn-view-detail {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #2c384d;
    color: #ffffff;
    text-decoration: none;
    display: inline-block;
    text-transform: lowercase;
}

.btn-view-detail:hover {
    background: #1e2835;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(44, 56, 77, 0.3);
}

/* Job Detail Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 1rem;
}

.modal-content {
    background: #ffffff;
    border-radius: 16px;
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.modal-large {
    max-width: 1000px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid #e8e8e8;
    background: #ffffff;
    z-index: 10;
    flex-shrink: 0;
    position: relative;
}

.modal-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    color: #999999;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.modal-close:hover {
    color: #1a1a1a;
}

.modal-body {
    padding: 2rem;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    padding: 1.5rem 2rem;
    border-top: 1px solid #e8e8e8;
    position: sticky;
    bottom: 0;
    background: #ffffff;
    z-index: 10;
    flex-shrink: 0;
}

.btn-primary {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 30px;
    background: #2c384d;
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: lowercase;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary:hover {
    background: #1e2835;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(44, 56, 77, 0.3);
}

.btn-secondary {
    padding: 0.75rem 1.5rem;
    border: 2px solid #e8e8e8;
    border-radius: 30px;
    background: transparent;
    color: #666666;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: lowercase;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-secondary:hover {
    border-color: #2c384d;
    color: #2c384d;
}

/* Job Detail Content */
.job-detail-section {
    margin-bottom: 2rem;
}

.job-detail-section:last-child {
    margin-bottom: 0;
}

.job-detail-section h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 1rem;
}

.job-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    gap: 1rem;
}

.job-detail-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2c384d;
    margin: 0;
}

.job-detail-badges {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.job-detail-badge {
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    background: #e8f0f8;
    color: #2c384d;
}

.btn-view-profile {
    padding: 0.625rem 1.25rem;
    background: #ffffff;
    color: #2c384d;
    border: 2px solid #2c384d;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.btn-view-profile:hover {
    background: #2c384d;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(44, 56, 77, 0.25);
}

.btn-view-profile svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.job-detail-description {
    color: #666666;
    line-height: 1.8;
    font-size: 1rem;
}

.job-detail-description p {
    margin: 0.5rem 0;
}

.job-detail-description ul,
.job-detail-description ol {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.job-detail-description li {
    margin: 0.25rem 0;
}

.job-detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.job-detail-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.job-detail-item svg {
    width: 24px;
    height: 24px;
    color: #2c384d;
    flex-shrink: 0;
    margin-top: 0.25rem;
}

.job-detail-item strong {
    display: block;
    font-size: 0.9rem;
    color: #1a1a1a;
    margin-bottom: 0.25rem;
}

.job-detail-item p {
    margin: 0;
    color: #666666;
    font-size: 0.95rem;
}

.job-detail-skills {
    color: #666666;
    line-height: 1.6;
}

.job-detail-map a {
    color: #2c384d;
    text-decoration: none;
    word-break: break-all;
}

.job-detail-map a:hover {
    text-decoration: underline;
}

.job-detail-meta {
    padding-top: 1.5rem;
    border-top: 1px solid #e8e8e8;
    color: #999999;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .modal-content {
        max-height: 95vh;
    }

    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 1rem;
    }

    .job-detail-grid {
        grid-template-columns: 1fr;
    }

    .job-detail-header {
        flex-direction: column;
    }

    .btn-view-profile {
        width: 100%;
        justify-content: center;
        margin-top: 0.75rem;
    }

    .modal-footer {
        flex-direction: column;
    }

    .modal-footer .btn-primary,
    .modal-footer .btn-secondary {
        width: 100%;
        justify-content: center;
    }
    
    .btn-view-detail {
        width: 100%;
        text-align: center;
    }
}

/* Additional Responsive Styles */
@media (max-width: 768px) {
    .explore-jobs-main {
        padding: 2rem 1rem;
    }

    .page-header h1 {
        font-size: 2rem;
    }

    .filters-section {
        padding: 1rem;
    }

    .filter-group {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 0.5rem;
    }
    
    .filter-group .custom-select {
        flex: 1;
        min-width: 0;
    }
    
    .filter-group .select-trigger {
        padding: 0.75rem 0.9rem;
        font-size: 0.85rem;
    }
    
    .filter-group .select-value {
        font-size: 0.85rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .job-card {
        padding: 1.5rem;
    }

    .job-header {
        flex-direction: column;
    }

    .job-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
}

