/* ================================================================
   Post-Job Stepper — full viewport, never page-scrolls (desktop)
   ================================================================ */

/* Shell reset — zeros hero-band padding for post-job pages */
body.post-job-shell .hero-band {
  padding: 0;
  background: transparent;
  overflow: hidden;
}
body.post-job-shell .main-content { overflow: hidden; }
body.post-job-shell { overflow: hidden; }

/* ----------------------------------------------------------------
   Page wrapper
   ---------------------------------------------------------------- */
.post-job-page {
  display: flex;
  flex-direction: column;
  height: calc(100vh - var(--nav-height, 64px) - var(--footer-height, 44px));
  overflow: hidden;
  background: #f8f7f5;
  padding: 20px 20px 0;
  box-sizing: border-box;
}

/* ----------------------------------------------------------------
   Card wrapper — same box size for all 4 steps
   ---------------------------------------------------------------- */
.pj-card-wrap {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  max-width: 860px;
  width: 100%;
  margin: 0 auto;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 2px 16px rgba(0,0,0,0.07);
  border: 0.5px solid #e8e2d9;
}

/* ----------------------------------------------------------------
   Stepper bar
   ---------------------------------------------------------------- */
.stepper-bar {
  flex-shrink: 0;
  background: #ffffff;
  border-bottom: 0.5px solid #e8e2d9;
  padding: 14px 0 12px;
}

.stepper {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  max-width: 520px;
  margin: 0 auto;
  padding: 0 24px;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  flex: 1;
  position: relative;
}

.step::before {
  content: '';
  position: absolute;
  top: 14px;
  left: 50%;
  right: -50%;
  height: 1.5px;
  background: #e8e2d9;
  z-index: 0;
}
.step:last-child::before { display: none; }
.step.done::before,
.step.active::before { background: #5DCAA5; }

.step-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 500;
  z-index: 1;
  position: relative;
}
.step.todo   .step-circle { background: #f5f0e8; border: 1.5px solid #e8e2d9; color: #b4b2a9; }
.step.active .step-circle { background: #2d4a3e; border: 1.5px solid #2d4a3e; color: #ffffff; }
.step.done   .step-circle { background: #5DCAA5; border: 1.5px solid #5DCAA5; color: #ffffff; }

.step-label { font-size: 10px; color: #b4b2a9; white-space: nowrap; }
.step.active .step-label { color: #2d4a3e; font-weight: 500; }
.step.done   .step-label { color: #5DCAA5; }

/* ----------------------------------------------------------------
   Two-column layout
   ---------------------------------------------------------------- */
.form-layout {
  flex: 1;
  min-height: 0;
  display: flex;
  overflow: hidden;
  border: none;
  background: transparent;
}

.form-left {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: #ffffff;
}

.form-right {
  width: 280px;
  flex-shrink: 0;
  background: #fdfcfa;
  border-left: 0.5px solid #e8e2d9;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

/* ----------------------------------------------------------------
   Form sections
   ---------------------------------------------------------------- */
.form-header {
  flex-shrink: 0;
  padding: 18px 28px 14px;
  border-bottom: 0.5px solid #e8e2d9;
}
.form-step-title { font-size: 16px; font-weight: 500; color: #2c2c2a; margin: 0; }
.form-step-sub   { font-size: 11px; color: #b4b2a9; margin-top: 2px; }

.form-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 20px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-footer {
  flex-shrink: 0;
  padding: 14px 28px;
  border-top: 0.5px solid #e8e2d9;
  background: #ffffff;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ----------------------------------------------------------------
   Field components
   ---------------------------------------------------------------- */
.pj-field-group {
  display: flex;
  flex-direction: column;
}

.pj-label {
  font-size: 11px;
  font-weight: 500;
  color: #5F5E5A;
  margin-bottom: 5px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.pj-req { color: #E24B4A; font-size: 11px; }
.pj-opt { font-size: 10px; color: #b4b2a9; font-weight: 400; }
.pj-hint { font-size: 10px; color: #b4b2a9; margin-top: 4px; }
.pj-field-error { font-size: 11px; color: #E24B4A; margin-top: 4px; }

.pj-input {
  width: 100%;
  padding: 9px 11px;
  border: 0.5px solid #e8e2d9;
  border-radius: 8px;
  font-size: 13px;
  color: #2c2c2a;
  background: #ffffff;
  outline: none;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
  box-sizing: border-box;
}
.pj-input:focus {
  border-color: #2d4a3e;
  box-shadow: 0 0 0 3px rgba(45,74,62,0.08);
}
.pj-field-group.has-error .pj-input { border-color: #E24B4A; }

.pj-textarea {
  resize: vertical;
  line-height: 1.6;
  min-height: 80px;
  max-height: 140px;
}

.pj-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* ----------------------------------------------------------------
   Error banner
   ---------------------------------------------------------------- */
.pj-errors {
  background: #fff0f0;
  border: 0.5px solid #fca5a5;
  border-radius: 8px;
  padding: 10px 12px;
}
.pj-errors p {
  font-size: 12px;
  color: #E24B4A;
  margin: 0 0 3px;
}
.pj-errors p:last-child { margin: 0; }

/* ----------------------------------------------------------------
   Work type chips
   ---------------------------------------------------------------- */
.type-chips { display: flex; gap: 7px; flex-wrap: wrap; }

.pj-chip {
  padding: 7px 14px;
  border-radius: 20px;
  border: 0.5px solid #e8e2d9;
  background: #ffffff;
  font-size: 12px;
  color: #5F5E5A;
  cursor: pointer;
  white-space: nowrap;
  user-select: none;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.pj-chip:hover { border-color: #2d4a3e; color: #2d4a3e; }
.pj-chip.chip-active { background: #2d4a3e; color: #ffffff; border-color: #2d4a3e; }

/* ----------------------------------------------------------------
   Apply method cards
   ---------------------------------------------------------------- */
.apply-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.apply-opt {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 12px;
  border: 0.5px solid #e8e2d9;
  border-radius: 10px;
  cursor: pointer;
  background: #ffffff;
  transition: border-color 0.15s, background 0.15s;
  user-select: none;
}
.apply-opt:hover { border-color: #2d4a3e; }
.apply-opt.apply-opt-active { border-color: #2d4a3e; background: #f5faf7; }

.apply-opt-icon {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 14px;
  color: #ffffff;
}
.apply-opt-label { font-size: 12px; color: #2c2c2a; flex: 1; }
.apply-opt-check {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  border: 1.5px solid #e8e2d9;
  flex-shrink: 0;
  transition: background 0.15s, border-color 0.15s;
}
.apply-opt.apply-opt-active .apply-opt-check {
  background: #2d4a3e;
  border-color: #2d4a3e;
}

/* ----------------------------------------------------------------
   Add-on rows
   ---------------------------------------------------------------- */
.addon-list {
  border: 0.5px solid #e8e2d9;
  border-radius: 10px;
  overflow: hidden;
}
.addon-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 0.5px solid #f5f0e8;
  cursor: pointer;
  background: #ffffff;
  transition: background 0.15s;
  user-select: none;
}
.addon-row:last-child { border-bottom: none; }
.addon-row:hover { background: #fdfcfa; }
.addon-row.addon-active { background: #f5faf7; }

.addon-check-box {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  border: 1.5px solid #e8e2d9;
  flex-shrink: 0;
  transition: background 0.15s, border-color 0.15s;
}
.addon-row.addon-active .addon-check-box {
  background: #2d4a3e;
  border-color: #2d4a3e;
}
.addon-info { flex: 1; }
.addon-name { font-size: 12px; font-weight: 500; color: #2c2c2a; }
.addon-desc { font-size: 10px; color: #888780; margin-top: 2px; }
.addon-price-tag { font-size: 12px; font-weight: 500; color: #2d4a3e; white-space: nowrap; }

/* ----------------------------------------------------------------
   Price summary (right panel)
   ---------------------------------------------------------------- */
.price-summary-card {
  margin: 16px;
  background: #eaf3de;
  border-radius: 12px;
  padding: 14px;
}
.price-summary-head {
  font-size: 10px;
  color: #3B6D11;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}
.ps-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #2c2c2a;
  padding: 3px 0;
}
.ps-total {
  display: flex;
  justify-content: space-between;
  font-size: 15px;
  font-weight: 500;
  color: #27500A;
  padding-top: 10px;
  margin-top: 6px;
  border-top: 0.5px solid #c0dd97;
}

/* ----------------------------------------------------------------
   Step 3 preview card
   ---------------------------------------------------------------- */
.pj-preview {
  border: 0.5px solid #e8e2d9;
  border-radius: 10px;
  overflow: hidden;
  background: #ffffff;
}
.pj-preview__head {
  padding: 12px 14px 10px;
  border-bottom: 0.5px solid #f5f0e8;
}
.pj-preview__title {
  font-size: 14px;
  font-weight: 600;
  color: #2c2c2a;
  margin-bottom: 4px;
}
.pj-preview__meta {
  font-size: 11px;
  color: #888780;
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  align-items: center;
}
.pj-preview__salary {
  display: inline-block;
  margin-top: 6px;
  font-size: 11px;
  font-weight: 500;
  color: #2d4a3e;
  background: #eaf3de;
  padding: 2px 8px;
  border-radius: 20px;
}
.pj-preview__body {
  padding: 10px 14px;
  font-size: 12px;
  color: #5F5E5A;
  line-height: 1.6;
}

/* ----------------------------------------------------------------
   Step 4 recap card
   ---------------------------------------------------------------- */
.recap-card {
  background: #f5f0e8;
  border-radius: 10px;
  padding: 12px 14px;
}
.recap-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 5px 0;
  border-bottom: 0.5px solid #e8e2d9;
  gap: 8px;
}
.recap-row:last-child { border-bottom: none; }
.recap-label { font-size: 11px; color: #888780; white-space: nowrap; }
.recap-val {
  font-size: 11px;
  font-weight: 500;
  color: #2c2c2a;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 180px;
}

/* ----------------------------------------------------------------
   Step 4 payment — centered single column within the shared card
   ---------------------------------------------------------------- */
.form-layout--pay {
  justify-content: center;
  align-items: flex-start;
  overflow-y: auto;
  padding: 28px 20px 32px;
  background: #f8f7f5;
}
.form-layout--pay .form-left {
  flex: none;
  width: 100%;
  max-width: 520px;
  border-radius: 12px;
  border: 0.5px solid #e8e2d9;
  background: #ffffff;
  box-shadow: none;
}
.form-layout--pay .form-right { display: none; }
.form-layout--pay .price-summary-card { margin: 0; }

/* ----------------------------------------------------------------
   Payment processing overlay
   ---------------------------------------------------------------- */
.pj-processing-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.88);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}
.pj-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #e8e2d9;
  border-top-color: #2d4a3e;
  border-radius: 50%;
  animation: pj-spin 0.8s linear infinite;
  margin-bottom: 14px;
}
@keyframes pj-spin { to { transform: rotate(360deg); } }
.pj-processing-text {
  font-size: 14px;
  color: #2d4a3e;
  font-weight: 500;
}

/* ----------------------------------------------------------------
   Navigation buttons
   ---------------------------------------------------------------- */
.btn-pj-next {
  margin-left: auto;
  padding: 10px 24px;
  background: #2d4a3e;
  color: #ffffff;
  border: none;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.btn-pj-next:hover { background: #3d6b57; color: #ffffff; text-decoration: none; }

.btn-pj-back {
  padding: 10px 18px;
  background: transparent;
  color: #888780;
  border: 0.5px solid #e8e2d9;
  border-radius: 9px;
  font-size: 13px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: border-color 0.15s, color 0.15s;
  white-space: nowrap;
}
.btn-pj-back:hover { border-color: #888780; color: #5F5E5A; text-decoration: none; }

.btn-pj-pay {
  margin-left: auto;
  padding: 10px 24px;
  background: #2d4a3e;
  color: #ffffff;
  border: none;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
}
.btn-pj-pay:hover { background: #3d6b57; }

/* ----------------------------------------------------------------
   Right panel tip card
   ---------------------------------------------------------------- */
.tip-card {
  margin: 16px;
  background: #2d4a3e;
  border-radius: 12px;
  padding: 14px;
}
.tip-head {
  font-size: 10px;
  font-weight: 500;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 8px;
}
.tip-body {
  font-size: 12px;
  color: rgba(255,255,255,0.8);
  line-height: 1.6;
  margin: 0;
}
.tip-bullets {
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
}
.tip-bullets li {
  font-size: 11px;
  color: rgba(255,255,255,0.65);
  padding: 3px 0 3px 13px;
  position: relative;
  line-height: 1.5;
  margin: 0;
}
.tip-bullets li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 9px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #5DCAA5;
}

/* ----------------------------------------------------------------
   Mobile: allow page scroll, hide right panel
   ---------------------------------------------------------------- */
@media (max-width: 767px) {
  .form-right { display: none; }

  .post-job-page {
    height: auto;
    overflow: visible;
    padding: 0;
  }
  .pj-card-wrap {
    border-radius: 0;
    box-shadow: none;
    border-left: none;
    border-right: none;
  }
  body.post-job-shell,
  body.post-job-shell .hero-band,
  body.post-job-shell .main-content {
    overflow: visible;
  }
  .form-layout { overflow: visible; height: auto; }
  .form-left   { height: auto; }
  .form-body   { overflow: visible; max-height: none; height: auto; }
  .form-footer {
    position: sticky;
    bottom: 0;
    z-index: 10;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.06);
  }
  .pj-row-2 { grid-template-columns: 1fr; }
  .form-header { padding: 14px 18px 12px; }
  .form-body   { padding: 16px 18px; }
  .form-footer { padding: 12px 18px; }
}
