/**
 * Job Search Module - Main Stylesheet
 * Bootstrap 5 Compatible
 */

/* ===========================
   General Styles
   =========================== */

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

.jobs-title {
    font-size: 2rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 0.5rem;
}

/* ===========================
   Job Cards
   =========================== */

.job-card {
    transition: all 0.3s ease;
    border: 1px solid #e0e0e0;
}

.job-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.job-featured {
    border-left: 4px solid #ffc107;
    background-color: #fffbf0;
}

.job-company-logo {
    max-width: 100px;
    max-height: 100px;
    object-fit: contain;
    border: 1px solid #e0e0e0;
    padding: 5px;
}

.job-title {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.job-title a {
    color: #333;
    text-decoration: none;
    transition: color 0.2s ease;
}

.job-title a:hover {
    color: #0d6efd;
}

.job-meta {
    font-size: 0.9rem;
}

.job-meta a {
    color: #6c757d;
    text-decoration: none;
}

.job-meta a:hover {
    color: #0d6efd;
    text-decoration: underline;
}

.job-description {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.6;
}

.job-tags .badge {
    font-size: 0.85rem;
    font-weight: normal;
    padding: 0.35em 0.65em;
}

.job-salary {
    font-size: 1.25rem;
    color: #28a745;
}

.job-stats {
    line-height: 1.8;
}

/* ===========================
   Filters
   =========================== */

.jobs-filters {
    background-color: #f8f9fa;
    border: 1px solid #e0e0e0;
}

.jobs-filters .form-label {
    font-weight: 600;
    font-size: 0.9rem;
    color: #495057;
}

.jobs-filters .form-select,
.jobs-filters .form-control {
    border-color: #ced4da;
}

.jobs-filters .form-select:focus,
.jobs-filters .form-control:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

/* ===========================
   Job Detail Page
   =========================== */

.job-detail-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px 30px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.job-detail-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.job-detail-meta {
    font-size: 1.1rem;
}

.job-detail-company-logo {
    max-width: 120px;
    max-height: 120px;
    background: white;
    padding: 10px;
    border-radius: 8px;
}

.job-detail-section {
    margin-bottom: 30px;
}

.job-detail-section h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #333;
    border-bottom: 2px solid #0d6efd;
    padding-bottom: 0.5rem;
}

.job-requirements ul,
.job-benefits ul {
    list-style-type: none;
    padding-left: 0;
}

.job-requirements ul li,
.job-benefits ul li {
    padding: 8px 0;
    padding-left: 25px;
    position: relative;
}

.job-requirements ul li:before {
    content: "\f00c";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    position: absolute;
    left: 0;
    color: #28a745;
}

.job-benefits ul li:before {
    content: "\f005";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    position: absolute;
    left: 0;
    color: #ffc107;
}

.job-apply-box {
    position: sticky;
    top: 20px;
    background: #f8f9fa;
    border: 2px solid #0d6efd;
    border-radius: 8px;
    padding: 25px;
}

.job-apply-box .btn-apply {
    font-size: 1.2rem;
    padding: 12px 30px;
    width: 100%;
}

.job-save-btn {
    width: 100%;
    margin-top: 10px;
}

/* ===========================
   Company Profile
   =========================== */

.company-header {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.company-logo-large {
    max-width: 150px;
    max-height: 150px;
    object-fit: contain;
}

.company-info {
    margin-top: 20px;
}

.company-info-item {
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
}

.company-info-item:last-child {
    border-bottom: none;
}

.company-info-label {
    font-weight: 600;
    color: #495057;
    min-width: 120px;
    display: inline-block;
}

/* ===========================
   Application Form
   =========================== */

.application-form {
    max-width: 800px;
    margin: 0 auto;
}

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

.application-form .form-label {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.application-form .required:after {
    content: " *";
    color: #dc3545;
}

.application-form textarea {
    min-height: 150px;
}

.application-form .file-upload {
    border: 2px dashed #ced4da;
    border-radius: 4px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.application-form .file-upload:hover {
    border-color: #0d6efd;
    background-color: #f8f9fa;
}

.application-form .file-info {
    margin-top: 10px;
    font-size: 0.9rem;
    color: #6c757d;
}

/* ===========================
   Dashboard
   =========================== */

.dashboard-nav {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 30px;
}

.dashboard-nav .nav-link {
    color: #495057;
    font-weight: 500;
    padding: 10px 20px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.dashboard-nav .nav-link:hover {
    background-color: #e9ecef;
    color: #0d6efd;
}

.dashboard-nav .nav-link.active {
    background-color: #0d6efd;
    color: white;
}

.application-status {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
}

.status-pending {
    background-color: #ffc107;
    color: #000;
}

.status-reviewed {
    background-color: #0dcaf0;
    color: #000;
}

.status-shortlisted {
    background-color: #198754;
    color: #fff;
}

.status-rejected {
    background-color: #dc3545;
    color: #fff;
}

.status-accepted {
    background-color: #28a745;
    color: #fff;
}

/* ===========================
   Search Page
   =========================== */

.search-form {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 50px 30px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.search-form h1 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    text-align: center;
}

.search-form .form-control,
.search-form .form-select {
    height: 50px;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.search-form .btn-search {
    height: 50px;
    font-size: 1.1rem;
    font-weight: 600;
}

/* ===========================
   Blocks
   =========================== */

.jobs-block {
    padding: 15px;
}

.jobs-block .job-item {
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
}

.jobs-block .job-item:last-child {
    border-bottom: none;
}

.jobs-block .job-item-title {
    font-weight: 600;
    margin-bottom: 5px;
}

.jobs-block .job-item-title a {
    color: #333;
    text-decoration: none;
}

.jobs-block .job-item-title a:hover {
    color: #0d6efd;
}

.jobs-block .job-item-meta {
    font-size: 0.85rem;
    color: #6c757d;
}

/* ===========================
   Admin Panel
   =========================== */

.admin-statistics {
    margin-bottom: 30px;
}

.admin-stat-card {
    text-align: center;
    padding: 25px;
    border-radius: 8px;
    color: white;
    transition: transform 0.2s ease;
}

.admin-stat-card:hover {
    transform: translateY(-5px);
}

.admin-stat-card h3 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.admin-stat-card p {
    font-size: 1rem;
    margin: 0;
    opacity: 0.9;
}

.stat-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.stat-success {
    background: linear-gradient(135deg, #56ab2f 0%, #a8e063 100%);
}

.stat-warning {
    background: linear-gradient(135deg, #f2994a 0%, #f2c94c 100%);
}

.stat-danger {
    background: linear-gradient(135deg, #eb3349 0%, #f45c43 100%);
}

.stat-info {
    background: linear-gradient(135deg, #2193b0 0%, #6dd5ed 100%);
}

.admin-table {
    background: white;
    border-radius: 8px;
    overflow: hidden;
}

.admin-table table {
    margin-bottom: 0;
}

.admin-table .table-actions a {
    margin-right: 5px;
}

/* ===========================
   Responsive Design
   =========================== */

@media (max-width: 768px) {
    .jobs-title {
        font-size: 1.5rem;
    }

    .job-card .row > div {
        text-align: center !important;
    }

    .job-card .col-md-2,
    .job-card .col-md-3 {
        margin-bottom: 15px;
    }

    .job-company-logo {
        margin: 0 auto;
    }

    .job-detail-title {
        font-size: 1.75rem;
    }

    .search-form h1 {
        font-size: 1.75rem;
    }

    .admin-stat-card {
        margin-bottom: 15px;
    }
}

@media (max-width: 576px) {
    .jobs-container {
        padding: 10px;
    }

    .jobs-filters .col-md-2,
    .jobs-filters .col-md-3,
    .jobs-filters .col-md-4 {
        margin-bottom: 10px;
    }

    .job-title {
        font-size: 1.25rem;
    }

    .job-meta {
        font-size: 0.85rem;
    }

    .job-meta span {
        display: block;
        margin-bottom: 5px;
    }
}

/* ===========================
   Utilities
   =========================== */

.text-truncate-2 {
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.text-truncate-3 {
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.badge-featured {
    background-color: #ffc107;
    color: #000;
}

.loading-spinner {
    text-align: center;
    padding: 40px;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
}

.empty-state i {
    font-size: 4rem;
    color: #6c757d;
    margin-bottom: 20px;
}

.empty-state h3 {
    color: #495057;
    margin-bottom: 10px;
}

.empty-state p {
    color: #6c757d;
}
