/* WP Job Postings - Frontend Styles */
@import url('https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700&family=DM+Sans:wght@300;400;500&display=swap');

.wjpb-careers-wrap {
    font-family: 'DM Sans', sans-serif;
    color: #0f172a;
    max-width: 860px;
    margin: 0 auto;
    padding: 0 16px;
}

.wjpb-page-message {
    border-radius: 12px;
    margin: 0 0 20px;
    padding: 14px 18px;
    font-size: 15px;
    line-height: 1.5;
    border: 1px solid transparent;
}
.wjpb-page-message.success {
    background: #ecfdf5;
    border-color: #86efac;
    color: #14532d;
}
.wjpb-page-message.warning {
    background: #fffbeb;
    border-color: #fcd34d;
    color: #78350f;
}
.wjpb-page-message.error {
    background: #fef2f2;
    border-color: #fca5a5;
    color: #7f1d1d;
}

/* Filter bar */
.wjpb-filters { margin-bottom: 32px; }
.wjpb-filter-form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px 18px;
}
.wjpb-search-box {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 8px 14px;
    flex: 1; min-width: 200px;
}
.wjpb-search-box svg { color: #94a3b8; flex-shrink: 0; }
.wjpb-search-box input {
    border: none; outline: none; background: transparent;
    font-size: 14px; width: 100%; font-family: inherit;
}
.wjpb-filter-form select {
    border: 1px solid #cbd5e1;
    border-radius: 8px; padding: 8px 12px;
    font-size: 14px; background: #fff;
    font-family: inherit; cursor: pointer; color: #374151;
}

/* Buttons */
.wjpb-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 9px 18px; border-radius: 8px; font-size: 14px; font-weight: 500;
    cursor: pointer; text-decoration: none; border: none; transition: all .2s; font-family: inherit;
}
.wjpb-btn-outline {
    background: #fff; border: 1.5px solid #1a1a2e; color: #1a1a2e;
}
.wjpb-btn-outline:hover { background: #1a1a2e; color: #fff; }
.wjpb-btn-ghost { background: transparent; color: #64748b; }
.wjpb-btn-ghost:hover { background: #f1f5f9; }
.wjpb-btn-apply {
    background: #1a1a2e; color: #fff; white-space: nowrap; flex-shrink: 0;
    font-family: 'Sora', sans-serif; letter-spacing: .02em;
}
.wjpb-btn-apply:hover { background: #2d2d4e; transform: translateY(-1px); box-shadow: 0 4px 14px rgba(26,26,46,.25); }
.wjpb-btn-primary {
    background: #1a1a2e; color: #fff; font-family: 'Sora', sans-serif;
    padding: 14px 32px; font-size: 15px; border-radius: 10px; width: 100%; justify-content: center;
    transition: all .2s;
}
.wjpb-btn-primary:hover { background: #2d2d4e; box-shadow: 0 6px 20px rgba(26,26,46,.3); }
.wjpb-btn-primary:disabled { opacity: .6; cursor: not-allowed; }

/* Results count */
.wjpb-results-count {
    font-size: 14px; color: #64748b; margin-bottom: 20px;
}

/* Job List */
.wjpb-job-list { display: flex; flex-direction: column; gap: 16px; }

.wjpb-job-card {
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    padding: 24px 28px;
    position: relative;
    transition: all .25s;
}
.wjpb-job-card:hover {
    border-color: #a5b4fc;
    box-shadow: 0 6px 30px rgba(99,102,241,.12);
    transform: translateY(-2px);
}
.wjpb-job-card.wjpb-featured {
    border-color: #fbbf24;
    background: linear-gradient(135deg, #fffbeb 0%, #fff 60%);
}
.wjpb-job-card.wjpb-expired { opacity: .65; }

.wjpb-badge-featured {
    position: absolute; top: -1px; right: 20px;
    background: #fbbf24; color: #78350f;
    font-size: 11px; font-weight: 700; padding: 4px 12px;
    border-radius: 0 0 8px 8px; text-transform: uppercase; letter-spacing: .06em;
}
.wjpb-badge-expired {
    position: absolute; top: 14px; right: 16px;
    background: #fee2e2; color: #991b1b;
    font-size: 11px; font-weight: 600; padding: 3px 10px; border-radius: 20px;
}

.wjpb-job-header {
    display: flex; align-items: flex-start; gap: 16px; justify-content: space-between;
}
.wjpb-job-title-wrap { flex: 1; }
.wjpb-job-title {
    font-family: 'Sora', sans-serif;
    font-size: 18px; font-weight: 600;
    margin: 0 0 10px; color: #0f172a;
    line-height: 1.3;
}
.wjpb-job-meta { display: flex; flex-wrap: wrap; gap: 7px; }

.wjpb-tag {
    display: inline-block;
    font-size: 12px; padding: 4px 10px; border-radius: 20px;
    font-weight: 500;
}
.wjpb-tag-dept   { background: #ede9fe; color: #5b21b6; }
.wjpb-tag-loc    { background: #e0f2fe; color: #075985; }
.wjpb-tag-type   { background: #dcfce7; color: #166534; }
.wjpb-tag-salary { background: #fff7ed; color: #9a3412; }

.wjpb-job-excerpt {
    margin-top: 14px;
    color: #475569; font-size: 14px; line-height: 1.65;
}
.wjpb-read-more {
    background: none; border: none; color: #6366f1;
    font-size: 13px; cursor: pointer; padding: 0; margin-left: 4px; font-family: inherit;
}
.wjpb-read-more:hover { text-decoration: underline; }

.wjpb-job-full {
    margin-top: 16px; padding-top: 16px;
    border-top: 1px solid #f1f5f9;
    color: #374151; font-size: 14px; line-height: 1.7;
}
.wjpb-deadline { color: #64748b; font-size: 13px; margin-top: 12px; }
.wjpb-deadline-expired { color: #ef4444; }

.wjpb-job-footer {
    margin-top: 12px;
    color: #94a3b8; font-size: 12px;
}

/* Empty state */
.wjpb-empty {
    text-align: center; padding: 60px 20px; color: #94a3b8;
}
.wjpb-empty svg { display: block; margin: 0 auto 16px; opacity: .4; }
.wjpb-empty h3 { color: #475569; font-size: 18px; margin: 0 0 8px; }

/* Modal Overlay */
.wjpb-modal-overlay {
    position: fixed; inset: 0; z-index: 100000;
    background: rgba(15,23,42,.65); backdrop-filter: blur(4px);
    display: flex; align-items: center; justify-content: center; padding: 20px;
}

.wjpb-modal-box {
    background: #fff; border-radius: 20px;
    width: 100%; max-width: 640px; max-height: 90vh;
    overflow-y: auto; position: relative;
    box-shadow: 0 25px 80px rgba(0,0,0,.3);
    animation: wjpb-modal-in .25s cubic-bezier(.34,1.56,.64,1);
}
@keyframes wjpb-modal-in {
    from { opacity: 0; transform: scale(.92) translateY(20px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}

.wjpb-modal-close {
    position: absolute; top: 18px; right: 20px; z-index: 2;
    background: #f1f5f9; border: none; width: 34px; height: 34px;
    border-radius: 50%; font-size: 16px; cursor: pointer; color: #64748b;
    display: flex; align-items: center; justify-content: center; transition: all .2s;
}
.wjpb-modal-close:hover { background: #e2e8f0; color: #0f172a; }

.wjpb-modal-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #2d2d5e 100%);
    color: #fff; padding: 36px 36px 28px; border-radius: 20px 20px 0 0;
}
.wjpb-modal-header h2 {
    font-family: 'Sora', sans-serif;
    margin: 0 0 6px; font-size: 22px; font-weight: 700;
}
.wjpb-modal-header p { margin: 0; opacity: .75; font-size: 14px; }

/* Form */
#wjpb-apply-form { padding: 28px 36px 36px; }

.wjpb-form-fields { display: flex; flex-direction: column; gap: 18px; }

.wjpb-form-group { display: flex; flex-direction: column; gap: 6px; }
.wjpb-form-group label {
    font-size: 13px; font-weight: 600; color: #374151;
    text-transform: uppercase; letter-spacing: .06em;
}
.wjpb-required { color: #ef4444; margin-left: 3px; }

.wjpb-form-group input:not([type=file]):not([type=checkbox]),
.wjpb-form-group textarea,
.wjpb-form-group select {
    border: 1.5px solid #e2e8f0;
    border-radius: 10px; padding: 12px 14px;
    font-size: 14px; font-family: inherit; color: #0f172a;
    background: #fafafa; transition: all .2s; width: 100%; box-sizing: border-box;
    outline: none;
}
.wjpb-form-group input:focus,
.wjpb-form-group textarea:focus {
    border-color: #6366f1; background: #fff; box-shadow: 0 0 0 3px rgba(99,102,241,.12);
}
.wjpb-form-group textarea { resize: vertical; min-height: 120px; }

/* Checkbox */
.wjpb-checkbox-label {
    display: flex; align-items: center; gap: 10px;
    cursor: pointer; font-size: 14px; font-weight: 400 !important;
    text-transform: none !important; letter-spacing: 0 !important;
}
.wjpb-checkbox-label input { width: auto; }

/* File drop */
.wjpb-resume-group { margin-top: 8px; }
.wjpb-file-drop {
    border: 2px dashed #cbd5e1; border-radius: 12px;
    position: relative; cursor: pointer; transition: all .2s;
    overflow: hidden;
}
.wjpb-file-drop:hover, .wjpb-file-drop.dragover { border-color: #6366f1; background: #f5f3ff; }
.wjpb-file-drop input[type=file] {
    position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%;
}
.wjpb-file-drop-ui {
    text-align: center; padding: 28px 20px; color: #64748b; pointer-events: none;
}
.wjpb-file-drop-ui svg { color: #94a3b8; margin-bottom: 10px; }
.wjpb-file-drop-ui p { margin: 0 0 4px; font-size: 14px; }
.wjpb-file-drop-ui strong { color: #6366f1; }
.wjpb-file-drop-ui small { font-size: 12px; color: #94a3b8; }

.wjpb-file-name {
    padding: 12px 16px; background: #f0fdf4;
    border-top: 1px solid #bbf7d0; color: #166534; font-size: 13px;
    display: flex; align-items: center; gap: 8px;
}

/* Messages */
.wjpb-form-messages {
    margin: 16px 0; padding: 14px 16px; border-radius: 10px; font-size: 14px;
}
.wjpb-form-messages.success { background: #f0fdf4; border: 1px solid #86efac; color: #166534; }
.wjpb-form-messages.error   { background: #fef2f2; border: 1px solid #fca5a5; color: #991b1b; }

.wjpb-form-actions { margin-top: 24px; }

@media (max-width: 640px) {
    .wjpb-job-header { flex-direction: column; }
    .wjpb-modal-header { padding: 28px 24px 22px; }
    #wjpb-apply-form { padding: 20px 24px 28px; }
    .wjpb-job-card { padding: 18px 20px; }
}
