/* Category Jobs Page Styles */

/* Container */
.container-inner {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Page Header */
.page-header {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
}

.page-header-content h1 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 15px;
}

.page-header-content p {
    font-size: 18px;
    opacity: 0.9;
    margin-bottom: 20px;
}

.breadcrumb {
    margin-top: 15px;
    font-size: 14px;
}

.breadcrumb a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: white;
}

.breadcrumb span {
    margin: 0 8px;
    color: rgba(255, 255, 255, 0.6);
}

/* Jobs Section */
.jobs-section {
    padding: 40px 0;
}

.search-filter-section {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 30px;
}

.search-bar {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.search-bar .search-input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.search-bar .search-input:focus {
    outline: none;
    border-color: #28a745;
}

.search-bar .search-btn {
    padding: 12px 20px;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.search-bar .search-btn:hover {
    background: #20c997;
}

.filter-options {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.filter-select {
    padding: 10px 12px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    background: white;
    font-size: 14px;
    min-width: 150px;
    color: #333;
    cursor: pointer;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* Default state - all options white */
.filter-select option {
    background: white !important;
    color: #333 !important;
}

/* Hover state - only the hovered option turns green */
.filter-select option:hover {
    background: #28a745 !important;
    color: white !important;
}

/* Selected state - only the selected option stays green */
.filter-select option:checked {
    background: #28a745 !important;
    color: white !important;
}

/* Override any blue highlighting */
.filter-select option::-moz-selection {
    background: #28a745 !important;
    color: white !important;
}

.filter-select option::selection {
    background: #28a745 !important;
    color: white !important;
}

.filter-select:active {
    border-color: #28a745;
    box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.2);
}

.filter-select:focus {
    outline: none;
    border-color: #28a745;
}

.filter-select:hover {
    border-color: #28a745;
}

/* Dropdown options styling */
.filter-select option {
    background: white !important;
    color: #333 !important;
    padding: 8px 12px;
}

.filter-select option:hover {
    background: #f8f9fa !important;
    color: #28a745 !important;
}

.filter-select option:checked {
    background: #28a745 !important;
    color: white !important;
}

/* Override browser default styles */
.filter-select option:focus {
    background: #28a745 !important;
    color: white !important;
}

.filter-select option:active {
    background: #28a745 !important;
    color: white !important;
}

.salary-filter-group {
    position: relative;
}

.filter-toggle-btn {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 500;
    color: #2c3e50;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 150px;
}

.filter-toggle-btn:hover {
    border-color: #28a745;
    color: #28a745;
}

.filter-toggle-btn.active {
    border-color: #28a745;
    background: #f8f9fa;
    color: #28a745;
}

.filter-toggle-btn i {
    font-size: 12px;
}

.salary-filter-panel {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #28a745;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    margin-top: 8px;
    min-width: 350px;
}

.salary-filter-panel::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid #28a745;
}

.salary-filter-header h4 {
    margin: 0 0 20px 0;
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
}

.salary-range-container {
    margin-bottom: 20px;
}

.salary-range-slider {
    margin-bottom: 20px;
}

.salary-track {
    position: relative;
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    margin: 20px 0;
    cursor: default;
}

.salary-progress {
    position: absolute;
    height: 100%;
    background: #28a745;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.salary-slider {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 20px;
    background: none;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    transform: translateY(-50%);
    cursor: pointer;
    z-index: 2;
}

.salary-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    background: #28a745;
    border-radius: 50%;
    cursor: pointer;
    border: 4px solid white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
    z-index: 10;
}

.salary-slider::-webkit-slider-thumb:hover {
    background: #20c997;
    transform: scale(1.15);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.salary-slider::-webkit-slider-thumb:active {
    transform: scale(1.2);
}

.salary-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    background: #28a745;
    border-radius: 50%;
    cursor: pointer;
    border: 4px solid white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
    z-index: 10;
}

.salary-slider::-moz-range-thumb:hover {
    background: #20c997;
    transform: scale(1.15);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.salary-slider::-moz-range-thumb:active {
    transform: scale(1.2);
}

.salary-inputs {
    display: flex;
    justify-content: center;
}

.salary-input-group {
    width: 200px;
}

.salary-input-group label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #7f8c8d;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.salary-input {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 14px;
    text-align: center;
    transition: border-color 0.3s ease;
}

.salary-input:focus {
    outline: none;
    border-color: #28a745;
}

.salary-unit {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 12px;
    color: #7f8c8d;
    pointer-events: none;
}

.salary-input-group {
    position: relative;
}

.salary-filter-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.apply-salary-btn {
    background: #28a745;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s ease;
}

.apply-salary-btn:hover {
    background: #20c997;
}

.clear-salary-btn {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.clear-salary-btn:hover {
    background: #c0392b;
}

.jobs-count {
    margin-bottom: 25px;
    font-size: 16px;
    color: #7f8c8d;
}

/* Jobs List Styles - Giống hệt trang chủ */
.jobs-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.job-item {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Top border like homepage cards */
.job-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border-radius: 12px 12px 0 0;
}

.job-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.job-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-color: #28a745;
}

.job-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 10px;
    position: relative;
    z-index: 2;
}

/* Company logo section - match homepage */
.job-logo-wrap {
    width: 88px;
    height: 88px;
    border-radius: 12px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border: 1px solid rgba(2, 6, 23, 0.04);
    overflow: hidden;
}

.job-logo-wrap img {
    width: 72px;
    height: 72px;
    object-fit: contain;
    display: block;
}

/* Job info section */
.job-info {
    flex: 1;
    min-width: 0;
}

.job-title {
    color: #0f172a;
    font-size: 14px;
    font-weight: 700;
    margin: 0 0 2px 0;
    line-height: 1.14;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.job-company {
    font-size: 13px;
    color: #6b7280;
    margin: 0;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.job-meta {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: flex-start;
    color: #6b7280;
    font-size: 13px;
}

.job-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.job-meta i {
    color: #10b981;
    font-size: 14px;
}

/* Job actions row with salary and save button */
.job-actions-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid #f8f9fa;
}

.job-salary {
    display: inline-block;
    color: white !important;
    font-weight: 700;
    font-size: 13px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
    padding: 6px 10px;
    border-radius: 14px;
    white-space: nowrap;
    position: relative;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.3);
    transition: all 0.3s ease;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.job-salary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.4);
}

/* Override home.css white color for job-salary */
.jobs-section .job-salary {
    color: white !important;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
}

/* Job details removed to match homepage - only shown in popup */

/* Job description removed to match homepage - only shown in popup */

/* Removed job-description styling to match homepage */

.job-requirements {
    margin-bottom: 10px;
    position: relative;
    z-index: 2;
    flex-grow: 1;
}

.job-requirements h5 {
    color: #333;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 600;
}

.requirements-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-height: 28px;
    align-items: flex-start;
}

.requirement-tag {
    background: #f8f9fa;
    color: #495057;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    border: 1px solid #e9ecef;
}

/* Save button styling like homepage */
.btn-save {
    background: white;
    border: 2px solid #e9ecef;
    color: #6c757d;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}

.btn-save:hover {
    background: #28a745;
    color: white;
    border-color: #28a745;
    transform: scale(1.1);
}

.btn-save.active {
    background: #28a745;
    color: #fff;
    border-color: #28a745;
}

.btn-save i {
    font-size: 14px;
    transition: all 0.3s ease;
}

.btn-save:hover i {
    transform: scale(1.1);
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 40px;
}

.page-btn {
    padding: 8px 12px;
    border: 2px solid #e9ecef;
    background: white;
    color: #7f8c8d;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.page-btn:hover {
    border-color: #28a745;
    color: #28a745;
}

.page-btn.active {
    background: #28a745;
    border-color: #28a745;
    color: white;
}

.page-ellipsis {
    padding: 8px 4px;
    color: #bdc3c7;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #7f8c8d;
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 20px;
    color: #bdc3c7;
}

.empty-state h3 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #2c3e50;
}

.empty-state p {
    font-size: 16px;
    margin-bottom: 25px;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: #28a745;
    color: white;
}

.btn-primary:hover {
    background: #20c997;
}

/* Responsive Design - Giống trang chủ */
@media (max-width: 768px) {
    .jobs-list {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .search-bar {
        flex-direction: column;
    }
    
    .filter-options {
        flex-direction: column;
    }
    
    .filter-select {
        min-width: auto;
    }
    
    .job-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .job-logo-wrap {
        width: 60px;
        height: 60px;
    }
    
    .job-logo-wrap img {
        width: 48px;
        height: 48px;
    }
    
    .job-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .job-meta span {
        white-space: normal;
    }
    
    .job-actions-row {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .salary-filter-panel {
        min-width: 280px;
    }
    
    .job-item {
        padding: 16px;
    }
    
    .job-title {
        font-size: 16px;
    }
    
    .btn-save {
        width: 40px;
        height: 40px;
        font-size: 14px;
    }
}
