:root {
  color-scheme: light;
  --bg: #f6f7fb;
  --surface: #ffffff;
  --surface-strong: #101828;
  --text: #111827;
  --muted: #667085;
  --line: #d9dee8;
  --accent: #123c7c;
  --accent-strong: #09224a;
  --accent-soft: #e7eefb;
  --warn-bg: #fff7e6;
  --warn-text: #7a4a00;
  --error-bg: #fff0f0;
  --error-text: #8a1f1f;
  --shadow: 0 18px 50px rgba(16, 24, 40, 0.10);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

a {
  color: inherit;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -10rem;
  background: var(--surface);
  color: var(--text);
  padding: .75rem 1rem;
  border-radius: 999px;
  z-index: 50;
}

.skip-link:focus {
  top: 1rem;
}

.hero {
  background:
    radial-gradient(circle at top right, rgba(255,255,255,0.22), transparent 28rem),
    linear-gradient(135deg, #071b3d 0%, #123c7c 52%, #1b5fc1 100%);
  color: #fff;
  padding: clamp(2.5rem, 7vw, 6rem) 1rem;
}

.hero__inner,
.page,
.footer {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
}

.hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr);
  gap: 2rem;
  align-items: center;
}

.eyebrow {
  margin: 0 0 .85rem;
  color: rgba(255,255,255,.72);
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .78rem;
  font-weight: 700;
}

.hero h1 {
  margin: 0;
  font-size: clamp(2.3rem, 8vw, 5rem);
  line-height: .92;
  letter-spacing: -.06em;
}

.hero__copy > p:not(.eyebrow) {
  margin: 1.25rem 0 0;
  max-width: 62ch;
  color: rgba(255,255,255,.82);
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.6;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: .8rem;
  margin-top: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.9rem;
  border-radius: 999px;
  padding: 0 1.15rem;
  border: 1px solid rgba(255,255,255,.24);
  font-weight: 750;
  text-decoration: none;
  cursor: pointer;
  transition: transform .18s ease, opacity .18s ease, background .18s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:disabled {
  cursor: wait;
  opacity: .7;
  transform: none;
}

.btn--primary {
  background: #fff;
  color: var(--accent-strong);
}

.btn--ghost {
  background: rgba(255,255,255,.08);
  color: #fff;
}

.hero__panel {
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: var(--radius);
  padding: 1.2rem;
  box-shadow: 0 20px 80px rgba(0,0,0,.18);
  backdrop-filter: blur(18px);
}

.metric {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(255,255,255,.18);
}

.metric:first-child {
  padding-top: 0;
}

.metric__label,
.hero__hint {
  color: rgba(255,255,255,.72);
}

.metric strong {
  font-size: 2rem;
  letter-spacing: -.04em;
}

.hero__hint {
  margin: 1rem 0 0;
  font-size: .92rem;
  line-height: 1.45;
}

.page {
  padding: 2rem 0 3rem;
}

.controls {
  margin-top: -3.2rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px 180px;
  gap: .9rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
}

.field {
  display: grid;
  gap: .45rem;
}

.field label {
  color: var(--muted);
  font-weight: 720;
  font-size: .82rem;
}

.field input,
.field select {
  width: 100%;
  height: 2.9rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  color: var(--text);
  padding: 0 .85rem;
  font: inherit;
  outline: none;
}

.field input:focus,
.field select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(18, 60, 124, .12);
}

.notice {
  margin-top: 1rem;
  border-radius: 16px;
  padding: 1rem;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
}

.notice[data-type="warn"] {
  background: var(--warn-bg);
  color: var(--warn-text);
  border-color: rgba(122,74,0,.18);
}

.notice[data-type="error"] {
  background: var(--error-bg);
  color: var(--error-text);
  border-color: rgba(138,31,31,.18);
}

.result-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 1rem;
  margin: 2rem 0 1rem;
}

.result-head h2 {
  margin: 0;
  font-size: clamp(1.55rem, 3vw, 2.2rem);
  letter-spacing: -.04em;
}

.result-head p {
  margin: .35rem 0 0;
  color: var(--muted);
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 2.3rem;
  white-space: nowrap;
  border-radius: 999px;
  padding: 0 .8rem;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-weight: 800;
}

.jobs {
  display: grid;
  gap: 1rem;
}

.job-card,
.empty-state {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem;
  box-shadow: 0 8px 30px rgba(16, 24, 40, .05);
}

.job-card__top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
}

.job-card__agency {
  margin: 0 0 .35rem;
  color: var(--muted);
  font-size: .88rem;
  font-weight: 780;
}

.job-card h3 {
  margin: 0;
  font-size: clamp(1.08rem, 2vw, 1.35rem);
  letter-spacing: -.02em;
  line-height: 1.25;
}

.job-card h3 a {
  text-decoration: none;
}

.job-card h3 a:hover {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: .2em;
}

.job-card__city {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  border-radius: 999px;
  padding: 0 .7rem;
  background: var(--surface-strong);
  color: #fff;
  font-weight: 800;
  font-size: .85rem;
}

.job-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-top: .9rem;
}

.job-card__meta span {
  border: 1px solid var(--line);
  background: #fbfcff;
  color: #344054;
  border-radius: 999px;
  padding: .34rem .62rem;
  font-size: .84rem;
  font-weight: 680;
}

.job-card__summary {
  margin: 1rem 0 0;
  color: #344054;
  line-height: 1.55;
}

.job-card__footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.job-card__source {
  color: var(--muted);
  font-size: .86rem;
}

.job-card__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: .55rem;
}

.job-card__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.4rem;
  border-radius: 999px;
  padding: 0 .8rem;
  border: 1px solid var(--line);
  background: #fff;
  font-weight: 800;
  color: var(--accent);
  text-decoration: none;
}

.job-card__document-link {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.job-card__document-link[data-type="html"] {
  background: var(--accent-soft);
  border-color: rgba(18, 60, 124, .16);
  color: var(--accent-strong);
}

.job-card__link:hover {
  text-decoration: underline;
  text-underline-offset: .2em;
}

.empty-state {
  display: grid;
  gap: .35rem;
  color: var(--muted);
}

.empty-state strong {
  color: var(--text);
}

.footer {
  padding: 0 0 2rem;
  color: var(--muted);
  font-size: .9rem;
}

.is-loading .jobs {
  opacity: .62;
}

@media (max-width: 820px) {
  .hero__inner,
  .controls {
    grid-template-columns: 1fr;
  }

  .controls {
    margin-top: -2rem;
  }

  .result-head,
  .job-card__top,
  .job-card__footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .job-card__actions {
    justify-content: flex-start;
  }
}

.job-card--highlighted {
  position: relative;
  border-color: rgba(18, 60, 124, .28);
  background: linear-gradient(90deg, rgba(231, 238, 251, .42), #fff 18rem);
}

.job-card--highlighted::before {
  content: "";
  position: absolute;
  inset: 1rem auto 1rem 0;
  width: 4px;
  border-radius: 999px;
  background: var(--accent);
  opacity: .52;
}

.job-card__badge {
  display: inline-flex;
  align-items: center;
  min-height: 1.9rem;
  border-radius: 999px;
  padding: 0 .65rem;
  border: 1px solid rgba(18, 60, 124, .18);
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: .78rem;
  font-weight: 800;
  white-space: nowrap;
}

.job-card__badge[hidden] {
  display: none;
}

.job-card__footer > .job-card__source,
.job-card__footer > .job-card__badge {
  margin-right: .4rem;
}

@media (max-width: 820px) {
  .job-card__badge {
    white-space: normal;
  }
}
