/**
 * HPH Google Jobs – base styles
 * Simple, theme-independent layout. Override via theme hph-google-jobs.css if needed.
 */

/* ========== Job list (shortcode) ========== */
.hph_jobs_preview {
  max-width: 1200px;
  margin: 2rem auto 3rem;
  padding: 0 1rem;
}

.hph_jobs_preview #filter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
  align-items: center;
}

.hph_jobs_preview #filter-form select {
  padding: 0.5rem 1rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  min-width: 140px;
}

.hph_jobs_preview #filter-form #remove-all {
  background: none;
  border: none;
  padding: 0.5rem 0;
  cursor: pointer;
  color: #666;
  font-size: 0.875rem;
}

.hph_jobs_preview #filter-form #remove-all:hover {
  color: #333;
}

/* Job card in list */
.hph_jobs_preview .single_job {
  padding: 1.25rem 1.5rem;
  margin-bottom: 1rem;
  background: #f8f8f8;
  border-radius: 6px;
  border: 1px solid #eee;
}

.hph_jobs_preview .innersection {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.hph_jobs_preview .left_section {
  flex: 1;
  min-width: 200px;
}

.hph_jobs_preview .job_preview_title h6 {
  margin: 0 0 0.5rem;
  font-size: 1.125rem;
}

.hph_jobs_preview .job_preview_title h6 a {
  color: inherit;
  text-decoration: none;
}

.hph_jobs_preview .job_preview_title h6 a:hover {
  text-decoration: underline;
}

.hph_jobs_preview .job_preview_info {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin: 0;
  font-size: 0.875rem;
  color: #555;
}

.hph_jobs_preview .job_preview_info p {
  margin: 0;
}

.hph_jobs_preview .right_section {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.hph_jobs_preview .btn-primary,
.hph_jobs_preview .pdf_button {
  display: inline-block;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  text-decoration: none;
  border-radius: 4px;
  white-space: nowrap;
}

.hph_jobs_preview .btn-primary {
  border: 1px solid #333;
  color: #333;
  background: transparent;
}

.hph_jobs_preview .btn-primary.cta {
  background: #333;
  color: #fff;
  border-color: #333;
}

.hph_jobs_preview .btn-primary:hover,
.hph_jobs_preview .pdf_button:hover {
  opacity: 0.9;
}

.hph_jobs_preview .pdf_button {
  color: #555;
}

/* ========== Single job page ========== */
.single-job .entry-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Header image */
.single-job .job_banner {
  margin: 0 -1rem 1.5rem;
  overflow: hidden;
}

.single-job .job_banner img {
  width: 100%;
  height: auto;
  max-height: 280px;
  object-fit: cover;
  display: block;
  vertical-align: middle;
}

/* Main content area */
.single-job .single_job_wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-bottom: 2rem;
}

.single-job .single_job_content {
  flex: 1;
  min-width: 0;
}

.single-job .single_job_header h1 {
  margin: 0 0 1rem;
  font-size: 1.75rem;
}

.single-job .single_job_intro .job_info {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
  color: #555;
}

.single-job .single_job_intro .job_info p {
  margin: 0;
}

.single-job .single_job_body h2 {
  margin: 1.5rem 0 0.5rem;
  font-size: 1.25rem;
}

.single-job .single_job_body h2:first-child {
  margin-top: 0;
}

.single-job .single_job_body p,
.single-job .single_job_body ul {
  margin: 0 0 0.75rem;
}

/* Sidebar */
.single-job .single_job_sidebar {
  width: 100%;
  max-width: 320px;
}

.single-job .single_job_sidebar > div {
  margin-bottom: 1.5rem;
  padding: 1rem;
  background: #f8f8f8;
  border-radius: 6px;
  border: 1px solid #eee;
}

.single-job .single_job_sidebar h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

.single-job .single_job_sidebar p {
  margin: 0 0 0.25rem;
  font-size: 0.875rem;
}

.single-job .single_job_sidebar img {
  max-width: 100%;
  height: auto;
  margin-bottom: 0.5rem;
  display: block;
}

/* Buttons on single job */
.single-job .single_job_application .button,
.single-job .single_job_back_to_list .button {
  display: inline-block;
  padding: 0.6rem 1.25rem;
  margin-right: 0.75rem;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
  text-decoration: none;
  border-radius: 4px;
  border: 1px solid #333;
  color: #333;
  background: transparent;
}

.single-job .single_job_application .button:hover,
.single-job .single_job_back_to_list .button:hover {
  background: #333;
  color: #fff;
}

/* External apply iframe modal */
.hph-job-apply-modal-open {
  overflow: hidden;
}

.hph-job-apply-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.hph-job-apply-modal[hidden] {
  display: none !important;
}

.hph-job-apply-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.hph-job-apply-modal__dialog {
  position: relative;
  z-index: 1;
  width: min(960px, 100%);
  height: min(90vh, 900px);
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
}

.hph-job-apply-modal__close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 2;
  width: 2.5rem;
  height: 2.5rem;
  border: 0;
  border-radius: 4px;
  background: #fff;
  color: #1d2327;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

.hph-job-apply-modal__iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Responsive */
@media (max-width: 768px) {
  .single-job .job_banner img {
    max-height: 200px;
  }

  .single-job .single_job_sidebar {
    max-width: none;
  }

  .hph_jobs_preview .innersection {
    flex-direction: column;
    align-items: flex-start;
  }
}
