/* Remote job search. Builds on ../styles.css (tokens, topbar, buttons, footer). */

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.muted { color: var(--muted); font-size: .95rem; }

/* ------------------------------------------------------------------ hero */
.jobs-hero { background: var(--navy); color: rgba(255,255,255,.85); padding: clamp(2rem, 5vw, 3.2rem) 0 clamp(1.6rem, 4vw, 2.4rem); }
.jobs-hero h1 { color: var(--white); font-size: clamp(2rem, 5vw, 3rem); margin-bottom: .35em; }
.jobs-hero__lede { max-width: 62ch; margin: 0; font-size: 1.05rem; }
.presets { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 1.2rem; }
.presets__label { font-size: .88rem; color: rgba(255,255,255,.7); margin-right: .2rem; }
.presets a {
  color: var(--white); text-decoration: none; font-size: .88rem; font-weight: 500;
  border: 1px solid rgba(246,197,68,.6); border-radius: 999px; padding: .38rem .85rem;
  transition: background .15s ease, color .15s ease;
}
.presets a:hover, .presets a[aria-current="true"] { background: var(--gold); color: var(--navy); border-color: var(--gold); }
.presets a:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* ---------------------------------------------------------------- layout */
.jobs { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 2rem; padding: 2rem 0 3.5rem; align-items: start; }
.filters-toggle { display: none; }

.filters {
  position: sticky; top: 82px; max-height: calc(100vh - 100px); overflow-y: auto;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.1rem 1.1rem .4rem; font-size: .94rem;
  scrollbar-width: thin;
}
.field { border: 0; margin: 0 0 1.25rem; padding: 0; min-width: 0; }
.field legend, .field > label:first-child {
  display: block; font-family: var(--font-head); font-weight: 700; color: var(--navy);
  font-size: .95rem; margin-bottom: .45rem; padding: 0;
}
.sub-label { display: block; font-size: .88rem; font-weight: 600; color: var(--ink); margin: .8rem 0 .3rem; }
.field input[type="search"], .field input[type="number"], .field select, .results select {
  width: 100%; font: inherit; padding: .6rem .75rem; border: 1px solid var(--line); border-radius: 10px;
  background: var(--white); color: var(--ink);
}
.field input:focus-visible, .field select:focus-visible, .results select:focus-visible, .check input:focus-visible + span,
.btn:focus-visible, .job__title a:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.field label[for="pay"] { font-weight: 500; color: var(--ink); font-family: var(--font-body); font-size: .9rem; margin-bottom: .3rem; display: block; }
.hint { color: var(--muted); font-size: .82rem; line-height: 1.45; margin: .4rem 0 0; }

.checks, .radios { display: flex; flex-direction: column; gap: .15rem; }
.check, .radio { display: flex; align-items: center; gap: .5rem; cursor: pointer; padding: .18rem 0; line-height: 1.3; }
.check input, .radio input { width: 1.05rem; height: 1.05rem; accent-color: var(--indigo); flex: none; margin: 0; }
.check .n { margin-left: auto; color: var(--muted); font-size: .8rem; font-variant-numeric: tabular-nums; }
.check--sub { margin-top: .35rem; font-size: .88rem; }
.field--actions { margin-bottom: 1rem; }

.jobs .btn--ghost { color: var(--navy); border-color: var(--line); background: var(--white); }
.jobs .btn--ghost:hover { border-color: var(--navy); }

/* --------------------------------------------------------------- results */
.results__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1rem; margin-bottom: 1rem; }
.results__count { margin: 0; font-weight: 600; color: var(--navy); font-size: 1.05rem; }
.results__tools { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.results__tools select { width: auto; padding: .45rem .6rem; }

.saved { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 1rem; }
.saved__item { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); overflow: hidden; }
.saved__item a { padding: .3rem .4rem .3rem .8rem; text-decoration: none; font-size: .88rem; font-weight: 600; }
.saved__item button { border: 0; background: none; padding: .3rem .7rem .3rem .3rem; cursor: pointer; color: var(--muted); font-size: 1rem; line-height: 1; }
.saved__item button:hover { color: var(--navy); }

.loading { color: var(--muted); margin: 0 0 1rem; }
.joblist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .7rem; }

.job {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .4rem 1.2rem;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: .95rem 1.1rem;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.job:hover { border-color: var(--lake); box-shadow: var(--shadow); }
.job__title { font-size: 1.06rem; margin: 0 0 .15rem; line-height: 1.3; }
.job__title a { color: var(--navy); text-decoration: none; }
.job__title a:hover { text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 3px; }
.job__meta { margin: 0 0 .45rem; color: var(--ink); font-size: .93rem; overflow-wrap: anywhere; }
.job__company { font-weight: 600; }
.job__loc { color: var(--muted); }
.job__loc:not(:empty)::before { content: " · "; }
.job__side { text-align: right; font-size: .86rem; color: var(--muted); white-space: nowrap; }
.job__side p { margin: 0 0 .15rem; }
.job__pay { color: var(--navy); font-weight: 600; }
.job__posted.is-new { color: #1C7C4A; font-weight: 600; }
.job__via a { color: var(--muted); }

.job__why { margin: .45rem 0 0; font-size: .8rem; color: var(--muted); font-style: italic; overflow-wrap: anywhere; }
.chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .35rem; }
.chip { font-size: .76rem; line-height: 1; padding: .32rem .55rem; border-radius: 999px; background: var(--lake-2); color: var(--navy); white-space: nowrap; }
.chip--warn { background: #FFF1CC; color: #6B4E00; }
.chip--region { background: var(--paper); border: 1px solid var(--line); color: var(--muted); }

.more { margin: 1.4rem auto 0; display: flex; }
.empty { background: var(--paper); border: 1px dashed var(--line); border-radius: var(--radius); padding: 1.5rem; color: var(--muted); }

/* ----------------------------------------------------------------- about */
.jobs-about { background: var(--paper); border-top: 1px solid var(--line); padding: clamp(2.2rem, 5vw, 3.2rem) 0; }
.jobs-about__inner { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2.5rem; }
.jobs-about h2 { font-size: 1.35rem; }

/* ---------------------------------------------------------------- mobile */
@media (max-width: 900px) {
  .jobs { grid-template-columns: 1fr; gap: 1rem; padding-top: 1.2rem; }
  .filters-toggle { display: inline-flex; justify-self: start; }
  .filters { display: none; position: static; max-height: none; }
  .filters.is-open { display: block; }
  .jobs-about__inner { grid-template-columns: 1fr; gap: 1rem; }
}
@media (max-width: 560px) {
  .job { grid-template-columns: 1fr; }
  .job__side { text-align: left; white-space: normal; display: flex; flex-wrap: wrap; gap: .2rem .9rem; }
  .results__tools { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .job { transition: none; } }
