/* Company Job Manager - Frontend Styles */

/* Job Listings */
.cjm-job-listings {
    margin-bottom: 30px;
}

.cjm-search-filters {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.cjm-filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
}

.cjm-search-box {
    flex: 1;
    min-width: 200px;
    display: flex;
    gap: 10px;
}

.cjm-search-box input[type="search"] {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.cjm-filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.cjm-filters select,
.cjm-filters input[type="text"] {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    min-width: 150px;
}

.cjm-search-btn,
.cjm-filter-btn {
    padding: 10px 20px;
    background: #0073aa;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.cjm-search-btn:hover,
.cjm-filter-btn:hover {
    background: #005a87;
}

/* Job Items */
.cjm-jobs-container {
    display: grid;
    gap: 20px;
}

.cjm-job-item {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s, transform 0.3s;
}

.cjm-job-item:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.cjm-job-header {
    margin-bottom: 15px;
}

.cjm-job-title {
    font-size: 22px;
    font-weight: 600;
    margin: 0 0 10px 0;
    color: #333;
    line-height: 1.3;
}

.cjm-featured-badge {
    background: linear-gradient(45deg, #ff6b35, #ff8f5a);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: bold;
    margin-left: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cjm-job-meta {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: center;
    color: #666;
    font-size: 14px;
}

.cjm-job-type {
    background: #e8f4fd;
    color: #0073aa;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: 500;
    text-transform: capitalize;
}

.cjm-job-location {
    display: flex;
    align-items: center;
}

.cjm-job-location:before {
    content: "📍";
    margin-right: 5px;
}

.cjm-job-content {
    margin-bottom: 20px;
}

.cjm-job-excerpt {
    color: #555;
    line-height: 1.6;
    margin-bottom: 15px;
}

.cjm-job-salary,
.cjm-job-deadline {
    margin-bottom: 10px;
    font-size: 14px;
}

.cjm-job-salary strong,
.cjm-job-deadline strong {
    color: #333;
}

.cjm-job-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* Buttons */
.cjm-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: all 0.3s;
    display: inline-block;
    line-height: 1;
}

.cjm-btn-primary {
    background: #0073aa;
    color: white;
}

.cjm-btn-primary:hover {
    background: #005a87;
    color: white;
}

.cjm-btn-secondary {
    background: transparent;
    color: #0073aa;
    border: 1px solid #0073aa;
}

.cjm-btn-secondary:hover {
    background: #0073aa;
    color: white;
}

.cjm-btn-large {
    padding: 15px 30px;
    font-size: 16px;
}

/* No Jobs Message */
.cjm-no-jobs {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

/* Modal Styles */
.cjm-modal {
    display: none;
    position: fixed;
    z-index: 100000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    overflow-y: auto;
}

.cjm-modal-content {
    background-color: #fff;
    margin: 50px auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    position: relative;
}

.cjm-modal-large {
    max-width: 800px;
}

.cjm-modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e0e0e0;
    background: #f8f9fa;
    border-radius: 8px 8px 0 0;
}

.cjm-modal-header h3 {
    margin: 0;
    font-size: 20px;
    color: #333;
}

.cjm-modal-close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    color: #999;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.cjm-modal-close:hover {
    color: #333;
    background: #e0e0e0;
}

.cjm-modal-body {
    padding: 25px;
    max-height: 70vh;
    overflow-y: auto;
}

.cjm-modal-footer {
    padding: 20px 25px;
    border-top: 1px solid #e0e0e0;
    background: #f8f9fa;
    border-radius: 0 0 8px 8px;
    text-align: right;
}

/* Application Form */
.cjm-application-form {
    background: #f9f9f9;
    padding: 30px;
    border-radius: 8px;
    margin: 20px 0;
}

.cjm-application-form h3 {
    margin-top: 0;
    color: #333;
    font-size: 24px;
}

.cjm-job-summary {
    background: white;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 25px;
    border-left: 4px solid #0073aa;
}

.cjm-deadline-notice {
    margin-top: 10px;
    color: #d63638;
}

.cjm-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.cjm-form-group {
    margin-bottom: 20px;
}

.cjm-form-half {
    margin-bottom: 0;
}

.cjm-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.cjm-form-group input[type="text"],
.cjm-form-group input[type="email"],
.cjm-form-group input[type="tel"],
.cjm-form-group input[type="url"],
.cjm-form-group input[type="file"],
.cjm-form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.3s;
}

.cjm-form-group input[type="file"] {
    padding: 8px 12px;
    background: #f9f9f9;
    cursor: pointer;
}

.cjm-form-group input[type="file"]:hover {
    background: #f0f0f0;
}

.cjm-form-group input:focus,
.cjm-form-group textarea:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.1);
}

.cjm-field-description {
    display: block;
    color: #666;
    font-size: 12px;
    margin-top: 5px;
}

.cjm-form-actions {
    margin-top: 30px;
    text-align: center;
}

/* Messages */
.cjm-message {
    padding: 15px;
    border-radius: 4px;
    margin: 20px 0;
}

.cjm-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.cjm-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Job Details */
.cjm-job-details {
    line-height: 1.6;
}

.cjm-job-details h4 {
    color: #333;
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 18px;
}

.cjm-job-details ul,
.cjm-job-details ol {
    padding-left: 20px;
}

.cjm-job-details li {
    margin-bottom: 8px;
}

.cjm-job-detail-meta {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.cjm-job-detail-meta-item {
    display: flex;
    flex-direction: column;
}

.cjm-job-detail-meta-item strong {
    color: #333;
    margin-bottom: 5px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .cjm-filter-form {
        flex-direction: column;
        align-items: stretch;
    }
    
    .cjm-search-box,
    .cjm-filters {
        flex-direction: column;
    }
    
    .cjm-form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .cjm-job-actions {
        flex-direction: column;
    }
    
    .cjm-btn {
        width: 100%;
    }
    
    .cjm-modal-content {
        width: 95%;
        margin: 20px auto;
    }
    
    .cjm-modal-body {
        max-height: 60vh;
    }
    
    .cjm-job-detail-meta {
        grid-template-columns: 1fr;
    }
    
    .cjm-application-form {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .cjm-job-item {
        padding: 20px;
    }
    
    .cjm-job-title {
        font-size: 20px;
    }
    
    .cjm-application-form h3 {
        font-size: 20px;
    }
}