/* ==========================================================
   ASIA JOB PLACEMENT - JOB LISTING PAGE STYLES (jobs.css)
   Pixel-perfect match to reference design with modern UX
   ========================================================== */

/* Page Background & Wrapper */
.jobs-page-body {
    background-color: #f4f7fb;
    min-height: 100vh;
}

.jobs-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 24px 20px 60px;
}

/* 2-Column Grid Layout */
.jobs-layout {
    display: grid;
    grid-template-columns: 290px 1fr;
    gap: 28px;
    align-items: start;
}

/* ==========================================================
   LEFT SIDEBAR - FILTERS
   ========================================================== */
.jobs-sidebar {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.04);
    padding: 24px;
    position: sticky;
    top: 80px;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

.jobs-sidebar::-webkit-scrollbar {
    width: 6px;
}
.jobs-sidebar::-webkit-scrollbar-thumb {
    background-color: #cbd5e1;
    border-radius: 10px;
}

/* Sidebar Header */
.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 16px;
    margin-bottom: 20px;
    border-bottom: 1px solid #f1f5f9;
}

.sidebar-title {
    font-size: 19px;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.clear-all-btn {
    background: none;
    border: none;
    color: var(--primary, #1a56db);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: var(--transition, all 0.2s ease);
}

.clear-all-btn:hover {
    background: rgba(26, 86, 219, 0.08);
}

.close-mobile-filter {
    display: none;
    background: #f1f5f9;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    font-size: 16px;
    color: #64748b;
    cursor: pointer;
}

/* Filter Sections */
.filter-section {
    margin-bottom: 22px;
    padding-bottom: 20px;
    border-bottom: 1px solid #f1f5f9;
}

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

.filter-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    cursor: pointer;
    user-select: none;
    margin-bottom: 14px;
}

.filter-header i {
    font-size: 12px;
    color: #64748b;
    transition: transform 0.25s ease;
}

.filter-section.collapsed .filter-header i {
    transform: rotate(-90deg);
}

.filter-section.collapsed .filter-body {
    display: none;
}

.filter-body {
    display: flex;
    flex-direction: column;
    gap: 11px;
}

/* Search inside filter (e.g. location) */
.filter-search-box {
    position: relative;
    margin-bottom: 6px;
}

.filter-search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 13px;
    color: #94a3b8;
}

.filter-search-input {
    width: 100%;
    height: 38px;
    padding: 0 12px 0 34px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 13px;
    color: #1e293b;
    outline: none;
    box-sizing: border-box;
    transition: all 0.2s ease;
}

.filter-search-input:focus {
    background: #ffffff;
    border-color: var(--primary, #1a56db);
    box-shadow: 0 0 0 3px rgba(26, 86, 219, 0.1);
}

/* Custom Checkbox */
.filter-checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13.5px;
    color: #334155;
    cursor: pointer;
    user-select: none;
    transition: color 0.15s ease;
}

.filter-checkbox-label:hover {
    color: var(--primary, #1a56db);
}

.filter-checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.custom-checkbox {
    width: 18px;
    height: 18px;
    background-color: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 5px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.filter-checkbox-label input[type="checkbox"]:checked ~ .custom-checkbox {
    background-color: var(--primary, #1a56db);
    border-color: var(--primary, #1a56db);
}

.filter-checkbox-label input[type="checkbox"]:checked ~ .custom-checkbox::after {
    content: "\f00c";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    color: #ffffff;
    font-size: 10px;
}

.filter-checkbox-label input[type="checkbox"]:focus ~ .custom-checkbox {
    box-shadow: 0 0 0 3px rgba(26, 86, 219, 0.2);
}

.filter-count {
    color: #64748b;
    font-size: 12.5px;
    margin-left: auto;
}

/* Show More Link */
.filter-show-more {
    background: none;
    border: none;
    color: var(--primary, #1a56db);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    padding: 4px 0 0;
    text-align: left;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.filter-show-more:hover {
    text-decoration: underline;
}

.filter-extra-items {
    display: none;
    flex-direction: column;
    gap: 11px;
}

.filter-extra-items.show {
    display: flex;
}

/* Salary Range Slider */
.salary-slider-container {
    padding: 8px 4px 4px;
}

.salary-slider-track {
    position: relative;
    width: 100%;
    height: 6px;
    background: #e2e8f0;
    border-radius: 4px;
    margin: 16px 0 10px;
}

.salary-slider-progress {
    position: absolute;
    height: 100%;
    background: #ff6b00;
    border-radius: 4px;
    left: 0%;
    right: 0%;
}

.salary-range-input {
    position: absolute;
    width: 100%;
    top: -6px;
    left: 0;
    height: 6px;
    background: none;
    pointer-events: none;
    -webkit-appearance: none;
    appearance: none;
}

.salary-range-input::-webkit-slider-thumb {
    height: 18px;
    width: 18px;
    border-radius: 50%;
    background: #ff6b00;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 6px rgba(255, 107, 0, 0.4);
    pointer-events: auto;
    -webkit-appearance: none;
    cursor: pointer;
}

.salary-labels {
    display: flex;
    justify-content: space-between;
    font-size: 12.5px;
    font-weight: 600;
    color: #475569;
    margin-top: 14px;
}

/* ==========================================================
   RIGHT MAIN CONTENT
   ========================================================== */
.jobs-main-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Top Search Bar (Matching Reference) */
.jobs-search-bar {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 8px 10px 8px 16px;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
    display: flex;
    align-items: center;
    gap: 12px;
}

.jobs-search-field {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.jobs-search-field i {
    font-size: 15px;
    color: #94a3b8;
    flex-shrink: 0;
}

.jobs-search-field input,
.jobs-search-field select {
    width: 100%;
    border: none;
    outline: none;
    background: transparent;
    font-size: 14px;
    color: #0f172a;
    font-family: inherit;
}

.jobs-search-field input::placeholder {
    color: #94a3b8;
}

.jobs-search-divider {
    width: 1px;
    height: 32px;
    background: #e2e8f0;
}

.btn-jobs-search {
    background: #ff6b00;
    color: #ffffff;
    border: none;
    border-radius: 10px;
    padding: 12px 32px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(255, 107, 0, 0.28);
}

.btn-jobs-search:hover {
    background: #e05e00;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(255, 107, 0, 0.38);
}

/* Results Header Bar */
.results-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 4px 2px;
}

.results-count {
    font-size: 17px;
    color: #475569;
}

.results-count strong {
    color: #0f172a;
    font-weight: 700;
}

.results-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sort-by-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #64748b;
}

.sort-select {
    border: 1px solid #e2e8f0;
    background: #ffffff;
    border-radius: 8px;
    padding: 7px 12px;
    font-size: 13.5px;
    color: #0f172a;
    font-weight: 600;
    cursor: pointer;
    outline: none;
}

.mobile-filter-trigger {
    display: none;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 13.5px;
    font-weight: 600;
    color: #0f172a;
    cursor: pointer;
}

.mobile-filter-trigger i {
    color: var(--primary, #1a56db);
}

/* Active Filter Chips */
.active-filters-bar {
    display: none;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.active-filters-bar.has-filters {
    display: flex;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #e0f2fe;
    color: #0369a1;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
}

.filter-chip i {
    cursor: pointer;
    font-size: 10px;
    padding: 2px;
}

.filter-chip i:hover {
    color: #0c4a6e;
}

/* ==========================================================
   JOB LISTING CARDS
   ========================================================== */
.jobs-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.job-card-item {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 22px 24px;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.03);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
}

.job-card-item:hover {
    border-color: #cbd5e1;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

/* Company Logo Box */
.job-company-logo {
    width: 60px;
    height: 60px;
    min-width: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    font-weight: 800;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.logo-google {
    background: #ffffff;
    border: 1px solid #e2e8f0;
}
.logo-apollo {
    background: #e0f2fe;
    color: #0284c7;
    border: 1px solid #bae6fd;
}
.logo-hdfc {
    background: #ffffff;
    border: 1px solid #e2e8f0;
}
.logo-zomato {
    background: #cb202d;
    color: #ffffff;
}
.logo-amazon {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    color: #000000;
}
.logo-byjus {
    background: #813588;
    color: #ffffff;
}
.logo-default {
    background: #f1f5f9;
    color: var(--primary, #1a56db);
}

/* Job Details (Center) */
.job-details-col {
    flex: 1;
    min-width: 0;
}

.job-role-title {
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 4px;
    line-height: 1.3;
}

.job-company-title {
    font-size: 14px;
    color: #64748b;
    font-weight: 500;
    margin: 0 0 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.job-tags-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.job-tag {
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.job-tag-type {
    background: #eff6ff;
    color: #1d4ed8;
}

.job-tag-exp {
    background: #f1f5f9;
    color: #475569;
}

.job-tag-loc {
    background: #f8fafc;
    color: #64748b;
    border: 1px solid #e2e8f0;
}

.job-salary-text {
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Actions Column (Right) */
.job-actions-col {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 14px;
}

.job-action-buttons-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-bookmark {
    background: none;
    border: none;
    font-size: 20px;
    color: #94a3b8;
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-bookmark:hover {
    color: #ff6b00;
    background: #fff7ed;
}

.btn-bookmark.bookmarked {
    color: #ff6b00;
}

.btn-apply-job {
    background: #1a56db;
    color: #ffffff;
    border: none;
    border-radius: 9px;
    padding: 10px 24px;
    font-size: 14.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(26, 86, 219, 0.2);
}

.btn-apply-job:hover {
    background: #1e429f;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26, 86, 219, 0.35);
}

.job-posted-time {
    font-size: 12.5px;
    color: #94a3b8;
}

/* Empty State */
.jobs-empty-state {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 60px 20px;
    text-align: center;
}

.empty-icon {
    font-size: 48px;
    color: #cbd5e1;
    margin-bottom: 16px;
}

.empty-title {
    font-size: 20px;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 8px;
}

.empty-desc {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 20px;
}

/* ==========================================================
   PAGINATION
   ========================================================== */
.jobs-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
    padding-top: 16px;
}

.page-btn {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    color: #334155;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.page-btn:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: var(--primary, #1a56db);
}

.page-btn.active {
    background: var(--primary, #1a56db);
    border-color: var(--primary, #1a56db);
    color: #ffffff;
}

.page-dots {
    color: #94a3b8;
    padding: 0 4px;
}

/* ==========================================================
   QUICK APPLY MODAL
   ========================================================== */
.quick-apply-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.quick-apply-modal.active {
    display: flex;
}

.quick-apply-card {
    background: #ffffff;
    border-radius: 18px;
    width: 100%;
    max-width: 520px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    animation: modalPop 0.25s ease-out forwards;
}

@keyframes modalPop {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.quick-apply-header {
    background: #f8fafc;
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.quick-apply-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
}

.quick-apply-header p {
    margin: 4px 0 0;
    font-size: 13px;
    color: #64748b;
}

.close-modal-btn {
    background: #e2e8f0;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    font-size: 18px;
    color: #64748b;
    cursor: pointer;
}

.quick-apply-body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.quick-apply-input-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.quick-apply-input-group label {
    font-size: 13px;
    font-weight: 600;
    color: #334155;
}

.quick-apply-input {
    width: 100%;
    height: 42px;
    padding: 0 14px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    color: #0f172a;
    box-sizing: border-box;
    outline: none;
}

.quick-apply-input:focus {
    background: #ffffff;
    border-color: #1a56db;
    box-shadow: 0 0 0 3px rgba(26, 86, 219, 0.1);
}

.quick-apply-footer {
    padding: 16px 24px 20px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-submit-quick-apply {
    width: 100%;
    padding: 13px;
    border-radius: 8px;
    background: #1a56db;
    color: #ffffff;
    border: none;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

.btn-submit-quick-apply:hover {
    background: #1e429f;
}

.full-form-link {
    text-align: center;
    font-size: 13px;
    color: #1a56db;
    text-decoration: none;
    font-weight: 500;
}

.full-form-link:hover {
    text-decoration: underline;
}

/* ==========================================================
   RESPONSIVE DESIGN (MOBILE & TABLET)
   ========================================================== */
@media (max-width: 1024px) {
    .jobs-layout {
        grid-template-columns: 260px 1fr;
        gap: 20px;
    }
}

@media (max-width: 860px) {
    .jobs-layout {
        grid-template-columns: 1fr;
    }

    /* Mobile Off-Canvas Drawer for Sidebar */
    .jobs-sidebar {
        position: fixed;
        top: 0;
        left: -100%;
        width: 85%;
        max-width: 340px;
        height: 100vh;
        max-height: 100vh;
        z-index: 1500;
        border-radius: 0 16px 16px 0;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
        transition: left 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    }

    .jobs-sidebar.active {
        left: 0;
    }

    .close-mobile-filter {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .sidebar-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(15, 23, 42, 0.5);
        backdrop-filter: blur(2px);
        z-index: 1400;
    }

    .sidebar-overlay.active {
        display: block;
    }

    .mobile-filter-trigger {
        display: flex;
    }

    .jobs-search-bar {
        flex-direction: column;
        padding: 12px;
        gap: 10px;
    }

    .jobs-search-divider {
        display: none;
    }

    .jobs-search-field {
        width: 100%;
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        border-radius: 8px;
        padding: 0 12px;
        height: 44px;
        box-sizing: border-box;
    }

    .btn-jobs-search {
        width: 100%;
        height: 46px;
    }

    .job-card-item {
        flex-direction: column;
        align-items: flex-start;
        padding: 18px;
    }

    .job-actions-col {
        width: 100%;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        margin-top: 10px;
        padding-top: 12px;
        border-top: 1px solid #f1f5f9;
    }

    .job-action-buttons-row {
        width: 100%;
        justify-content: space-between;
    }

    .btn-apply-job {
        flex: 1;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .jobs-container {
        padding: 16px 12px 40px;
    }

    .results-header-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .results-controls {
        width: 100%;
        justify-content: space-between;
    }

    .job-role-title {
        font-size: 16px;
    }

    .page-btn {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }
}
