/* ================================================================
   Job Board Pro — Stylesheet
   Compatible with Elementor. Uses CSS custom properties so
   clients can override via Elementor Global Colors.
================================================================ */

:root {
  --jbp-primary:      #2563eb;
  --jbp-primary-dark: #1d4ed8;
  --jbp-primary-light:#eff6ff;
  --jbp-accent:       #f59e0b;
  --jbp-text:         #111827;
  --jbp-text-muted:   #6b7280;
  --jbp-border:       #e5e7eb;
  --jbp-bg:           #f9fafb;
  --jbp-white:        #ffffff;
  --jbp-success:      #10b981;
  --jbp-error:        #ef4444;
  --jbp-radius:       10px;
  --jbp-radius-sm:    6px;
  --jbp-shadow:       0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.04);
  --jbp-shadow-md:    0 4px 12px rgba(0,0,0,.1);
  --jbp-font:         inherit;
}

/* ── Reset ── */
.jbp-board-wrap *,
.jbp-single-wrap *,
.jbp-submit-wrap *,
.jbp-apply-wrap *,
.jbp-search-standalone * {
  box-sizing: border-box;
}

/* ================================================================
   CONTROLS (search + filters)
================================================================ */
.jbp-controls {
  margin-bottom: 28px;
}
.jbp-filter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.jbp-search-wrap {
  position: relative;
  flex: 1 1 260px;
}
.jbp-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--jbp-text-muted);
  display: flex;
  pointer-events: none;
}
.jbp-search-input {
  width: 100%;
  padding: 11px 14px 11px 40px;
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius-sm);
  font-size: 15px;
  background: var(--jbp-white);
  color: var(--jbp-text);
  transition: border-color .2s, box-shadow .2s;
}
.jbp-search-input:focus {
  outline: none;
  border-color: var(--jbp-primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}
.jbp-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.jbp-select {
  padding: 10px 14px;
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius-sm);
  background: var(--jbp-white);
  font-size: 14px;
  color: var(--jbp-text);
  cursor: pointer;
  transition: border-color .2s;
}
.jbp-select:focus {
  outline: none;
  border-color: var(--jbp-primary);
}
.jbp-result-count {
  font-size: 14px;
  color: var(--jbp-text-muted);
  margin: 0 0 16px;
}

/* ================================================================
   LISTING GRID
================================================================ */
.jbp-listing {
  display: grid;
  gap: 16px;
}
.jbp-cols-2 { grid-template-columns: repeat(2, 1fr); }
.jbp-cols-3 { grid-template-columns: repeat(3, 1fr); }

/* ================================================================
   JOB CARD
================================================================ */
.jbp-job-card {
  background: var(--jbp-white);
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius);
  padding: 22px 24px;
  position: relative;
  transition: box-shadow .2s, transform .2s, border-color .2s;
}
.jbp-job-card:hover {
  box-shadow: var(--jbp-shadow-md);
  transform: translateY(-2px);
  border-color: #d1d5db;
}
.jbp-job-card.jbp-featured {
  border-color: var(--jbp-primary);
  background: linear-gradient(135deg, var(--jbp-primary-light) 0%, var(--jbp-white) 60%);
}

/* header row */
.jbp-card-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 12px;
}
.jbp-logo {
  width: 52px;
  height: 52px;
  object-fit: contain;
  border-radius: var(--jbp-radius-sm);
  border: 1px solid var(--jbp-border);
  flex-shrink: 0;
  background: var(--jbp-white);
  padding: 4px;
}
.jbp-logo-placeholder {
  width: 52px;
  height: 52px;
  border-radius: var(--jbp-radius-sm);
  background: var(--jbp-primary);
  color: var(--jbp-white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
  flex-shrink: 0;
}
.jbp-logo-lg { width: 72px; height: 72px; font-size: 30px; }

.jbp-card-title-wrap { flex: 1; min-width: 0; }
.jbp-job-title {
  font-size: 17px;
  font-weight: 700;
  margin: 0 0 4px;
  line-height: 1.3;
  color: var(--jbp-text);
}
.jbp-job-title a {
  color: inherit;
  text-decoration: none;
}
.jbp-job-title a:hover { color: var(--jbp-primary); }
.jbp-company-name {
  font-size: 14px;
  color: var(--jbp-text-muted);
  margin: 0;
}

/* meta row */
.jbp-card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.jbp-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: var(--jbp-text-muted);
}
.jbp-salary { color: var(--jbp-success); font-weight: 600; }

/* badges */
.jbp-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .01em;
}
.jbp-badge-featured { background: var(--jbp-accent); color: #fff; }
.jbp-badge-remote   { background: #d1fae5; color: #065f46; }
.jbp-badge-type     { background: var(--jbp-primary-light); color: var(--jbp-primary); }
.jbp-badge-cat      { background: #fef3c7; color: #92400e; }

/* excerpt */
.jbp-card-excerpt {
  font-size: 14px;
  color: var(--jbp-text-muted);
  line-height: 1.6;
  margin-bottom: 16px;
}

/* footer */
.jbp-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--jbp-border);
}
.jbp-posted-date { font-size: 12px; color: var(--jbp-text-muted); }

/* ================================================================
   BUTTONS
================================================================ */
.jbp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: var(--jbp-radius-sm);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, color .2s, box-shadow .2s, transform .1s;
  border: 2px solid transparent;
  text-decoration: none;
  line-height: 1;
}
.jbp-btn:active { transform: scale(.97); }
.jbp-btn-primary {
  background: var(--jbp-primary);
  color: var(--jbp-white);
  border-color: var(--jbp-primary);
}
.jbp-btn-primary:hover {
  background: var(--jbp-primary-dark);
  border-color: var(--jbp-primary-dark);
  color: #fff;
}
.jbp-btn-ghost {
  background: transparent;
  color: var(--jbp-text-muted);
  border-color: var(--jbp-border);
}
.jbp-btn-ghost:hover {
  background: var(--jbp-bg);
  color: var(--jbp-text);
}
.jbp-btn-sm  { padding: 7px 14px; font-size: 13px; }
.jbp-btn-lg  { padding: 14px 28px; font-size: 16px; }

/* ================================================================
   EMPTY STATE
================================================================ */
.jbp-no-jobs {
  text-align: center;
  padding: 60px 20px;
  color: var(--jbp-text-muted);
}
.jbp-no-jobs svg { display: block; margin: 0 auto 16px; opacity: .4; }
.jbp-no-jobs p   { font-size: 16px; }

/* ================================================================
   PAGINATION
================================================================ */
.page-numbers { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 24px 0 0; margin: 0; }
.page-numbers li { margin: 0; }
.page-numbers a,
.page-numbers span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 8px;
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius-sm);
  font-size: 14px;
  color: var(--jbp-text);
  text-decoration: none;
  transition: background .15s, color .15s;
}
.page-numbers .current,
.page-numbers a:hover {
  background: var(--jbp-primary);
  border-color: var(--jbp-primary);
  color: #fff;
}

/* ================================================================
   SINGLE JOB
================================================================ */
.jbp-single-wrap { max-width: 100%; }
.jbp-single-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 28px;
  background: var(--jbp-white);
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius);
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.jbp-single-title-block { flex: 1; min-width: 200px; }
.jbp-single-title {
  font-size: 26px;
  font-weight: 800;
  margin: 0 0 6px;
  color: var(--jbp-text);
}
.jbp-single-company { font-size: 16px; color: var(--jbp-text-muted); margin: 0 0 10px; }
.jbp-single-company a { color: var(--jbp-primary); text-decoration: none; }
.jbp-single-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.jbp-single-apply-btn-wrap { align-self: center; }

.jbp-single-body {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 24px;
  align-items: start;
}
.jbp-single-content {
  background: var(--jbp-white);
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius);
  padding: 28px;
}
.jbp-single-content h2 {
  font-size: 20px;
  font-weight: 700;
  margin-top: 0;
  color: var(--jbp-text);
}

/* sidebar */
.jbp-sidebar-card {
  background: var(--jbp-white);
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius);
  padding: 20px;
}
.jbp-sidebar-card h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--jbp-text);
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.jbp-overview-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.jbp-overview-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--jbp-border);
  font-size: 14px;
}
.jbp-overview-list li:last-child { border-bottom: none; }
.jbp-ov-label { color: var(--jbp-text-muted); }
.jbp-ov-value { font-weight: 600; color: var(--jbp-text); text-align: right; }

/* ================================================================
   FORMS (apply + submit)
================================================================ */
.jbp-apply-wrap,
.jbp-submit-wrap {
  background: var(--jbp-white);
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius);
  padding: 28px;
  margin-top: 28px;
}
.jbp-apply-title,
.jbp-submit-title {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 20px;
  color: var(--jbp-text);
}
.jbp-form-section {
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--jbp-border);
}
.jbp-form-section:last-of-type { border-bottom: none; }
.jbp-form-section h3 {
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--jbp-text-muted);
  margin: 0 0 16px;
}
.jbp-form-row { display: grid; gap: 16px; }
.jbp-form-row-2 { grid-template-columns: 1fr 1fr; }
.jbp-form-group { display: flex; flex-direction: column; gap: 6px; }
.jbp-form-group label {
  font-size: 14px;
  font-weight: 600;
  color: var(--jbp-text);
}
.jbp-form-group-checkbox {
  flex-direction: row;
  align-items: center;
  gap: 8px;
}
.jbp-form-group-checkbox label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 400;
  cursor: pointer;
}
.jbp-required { color: var(--jbp-error); }

.jbp-apply-form input[type="text"],
.jbp-apply-form input[type="email"],
.jbp-apply-form textarea,
.jbp-submit-form input[type="text"],
.jbp-submit-form input[type="url"],
.jbp-submit-form input[type="number"],
.jbp-submit-form input[type="email"],
.jbp-submit-form input[type="date"],
.jbp-submit-form textarea,
.jbp-submit-form select {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--jbp-border);
  border-radius: var(--jbp-radius-sm);
  font-size: 15px;
  color: var(--jbp-text);
  background: var(--jbp-white);
  transition: border-color .2s, box-shadow .2s;
  font-family: var(--jbp-font);
}
.jbp-apply-form input:focus,
.jbp-apply-form textarea:focus,
.jbp-submit-form input:focus,
.jbp-submit-form textarea:focus,
.jbp-submit-form select:focus {
  outline: none;
  border-color: var(--jbp-primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}
.jbp-apply-form textarea,
.jbp-submit-form textarea { resize: vertical; }

/* file upload */
.jbp-file-upload { position: relative; }
.jbp-file-upload input[type="file"] {
  position: absolute;
  width: 1px; height: 1px;
  opacity: 0; overflow: hidden;
}
.jbp-file-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border: 2px dashed var(--jbp-border);
  border-radius: var(--jbp-radius-sm);
  cursor: pointer;
  font-size: 14px;
  color: var(--jbp-text-muted);
  transition: border-color .2s, color .2s;
  width: 100%;
}
.jbp-file-label:hover {
  border-color: var(--jbp-primary);
  color: var(--jbp-primary);
}
.jbp-file-name { font-size: 13px; color: var(--jbp-text-muted); margin-top: 4px; display: block; }

.jbp-form-footer { padding-top: 8px; }

/* alerts */
.jbp-alert {
  padding: 14px 18px;
  border-radius: var(--jbp-radius-sm);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 20px;
}
.jbp-alert-success { background: #d1fae5; color: #065f46; border: 1px solid #a7f3d0; }
.jbp-alert-error   { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.jbp-alert-info    { background: var(--jbp-primary-light); color: var(--jbp-primary-dark); border: 1px solid #bfdbfe; }

/* apply message */
.jbp-apply-message { margin-bottom: 20px; }

/* ================================================================
   STANDALONE SEARCH HERO
================================================================ */
.jbp-search-standalone { width: 100%; }
.jbp-search-hero-form { width: 100%; }
.jbp-search-hero-inner {
  display: flex;
  align-items: center;
  background: var(--jbp-white);
  border: 2px solid var(--jbp-border);
  border-radius: 50px;
  padding: 6px 6px 6px 20px;
  gap: 10px;
  box-shadow: var(--jbp-shadow-md);
  transition: border-color .2s, box-shadow .2s;
}
.jbp-search-hero-inner:focus-within {
  border-color: var(--jbp-primary);
  box-shadow: 0 4px 20px rgba(37,99,235,.15);
}
.jbp-search-hero-icon { color: var(--jbp-text-muted); display: flex; flex-shrink: 0; }
.jbp-search-hero-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 16px;
  color: var(--jbp-text);
  background: transparent;
}
.jbp-search-hero-input::placeholder { color: #9ca3af; }
.jbp-search-standalone .jbp-btn { border-radius: 50px; }

/* ================================================================
   ADMIN — status badges
================================================================ */
.jbp-status-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 600;
}
.jbp-status-pending    { background: #fef3c7; color: #92400e; }
.jbp-status-reviewing  { background: #dbeafe; color: #1e40af; }
.jbp-status-shortlisted{ background: #ede9fe; color: #5b21b6; }
.jbp-status-rejected   { background: #fee2e2; color: #991b1b; }
.jbp-status-hired      { background: #d1fae5; color: #065f46; }

/* ================================================================
   RESPONSIVE
================================================================ */
@media ( max-width: 900px ) {
  .jbp-single-body { grid-template-columns: 1fr; }
  .jbp-cols-3      { grid-template-columns: repeat(2, 1fr); }
}
@media ( max-width: 640px ) {
  .jbp-cols-2,
  .jbp-cols-3     { grid-template-columns: 1fr; }
  .jbp-form-row-2 { grid-template-columns: 1fr; }
  .jbp-single-header { flex-direction: column; }
  .jbp-filter-form { flex-direction: column; align-items: stretch; }
  .jbp-search-wrap { flex: unset; width: 100%; }
  .jbp-search-hero-inner { flex-wrap: wrap; border-radius: var(--jbp-radius); padding: 12px 16px; gap: 8px; }
  .jbp-search-hero-input { width: 100%; }
  .jbp-search-standalone .jbp-btn { width: 100%; border-radius: var(--jbp-radius-sm); }
}
