:root {
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-strong: #ffffff;
  --text: #171717;
  --muted: #737373;
  --muted-strong: #525252;
  --line: #d4d4d4;
  --line-soft: #e5e5e5;
  --primary: #fdcc49;
  --primary-hover: #fdc530;
  --primary-dark: #c48f02;
  --primary-soft: #fff7d6;
  --accent: #000000;
  --soft-bg: #f9fafb;
  --tag-bg: #f3f4f6;
  --shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
}

* {
  box-sizing: border-box;
}

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

a {
  color: inherit;
}

.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;
}

.board-topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px max(24px, calc((100vw - 1180px) / 2));
  background: var(--surface);
  border-bottom: 1px solid rgba(23, 23, 23, 0.15);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  text-decoration: none;
}

.brand::before {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: var(--primary);
  box-shadow: 0 0 0 2px #000000;
}

.board-topbar nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted);
  font-size: 14px;
}

.board-topbar nav a {
  text-decoration: none;
}

.board-topbar nav a:hover,
.quiet-link:hover,
.job-card:hover h3 {
  color: var(--text);
}

.board-main {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 34px 0 64px;
}

.board-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 24px;
  padding: 24px 0 20px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  max-width: 900px;
  margin: 0;
  font-size: 42px;
  line-height: 1.08;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: 0;
}

h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.25;
  letter-spacing: 0;
}

.board-subtitle {
  max-width: 720px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 17px;
}

.board-search {
  display: grid;
  grid-template-columns: minmax(170px, 1.15fr) minmax(170px, 1fr) minmax(130px, 0.6fr) minmax(160px, 0.75fr) auto auto;
  align-items: end;
  gap: 14px;
  margin: 16px 0 24px;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.board-search label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.board-search input[type="search"],
.board-search input[type="number"],
.board-search select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-strong);
  color: var(--text);
  font: inherit;
  font-size: 15px;
  padding: 9px 11px;
}

.radius-controls {
  display: grid;
  grid-template-columns: minmax(70px, 1fr) 64px;
  gap: 8px;
}

.board-search input:focus,
.board-search select:focus {
  outline: 3px solid var(--primary-soft);
  border-color: var(--primary);
}

.checkbox-line {
  min-height: 42px;
  display: flex !important;
  grid-template-columns: none !important;
  align-items: center;
  gap: 8px !important;
  padding: 9px 4px;
  color: var(--text) !important;
}

.checkbox-line input {
  width: 17px;
  height: 17px;
  accent-color: var(--primary);
}

.search-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 42px;
}

.search-note {
  margin: -10px 0 20px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.board-map-shell {
  margin: 0 0 24px;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.board-map-shell.is-collapsed .board-map-head {
  margin-bottom: 0;
}

.board-map-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 18px;
  margin-bottom: 14px;
}

.board-map-summary {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 650;
}

.board-map-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.board-map-actions button {
  cursor: pointer;
  font: inherit;
}

.board-map-actions button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.board-map-canvas {
  width: 100%;
  height: 420px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft-bg);
}

.board-map-status {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.board-map-marker {
  display: grid;
  place-items: center;
  background: transparent;
  border: 0;
}

.board-map-marker span {
  width: 22px;
  height: 22px;
  display: block;
  border: 2px solid #000000;
  border-radius: 999px;
  background: var(--primary);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.24);
}

.board-map-cluster {
  display: grid;
  place-items: center;
  border: 2px solid #000000;
  border-radius: 999px;
  background: var(--primary);
  color: #000000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.22);
  font-weight: 900;
}

.board-map-cluster span {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  border-radius: inherit;
}

.board-map-popup {
  display: grid;
  gap: 4px;
  min-width: 210px;
}

.board-map-popup a {
  color: #000000;
  text-decoration: none;
}

.board-map-popup a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.board-map-popup-company {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.board-map-popup-title {
  font-size: 15px;
  font-weight: 900;
  line-height: 1.25;
}

.board-map-popup-location,
.board-map-popup-meta {
  color: var(--muted-strong);
  font-size: 13px;
  font-weight: 650;
}

.button-primary,
.button-secondary {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 14px;
  border-radius: 6px;
  border: 1px solid transparent;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.button-primary {
  background: var(--primary);
  color: #000000;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}

.button-primary:hover {
  background: var(--primary-hover);
}

.button-secondary {
  background: var(--surface);
  border-color: var(--primary);
  color: #000000;
}

.button-secondary:hover {
  background: var(--primary-soft);
}

.quiet-link {
  color: var(--muted);
  font-weight: 750;
  text-decoration: none;
}

.board-results-shell,
.board-intro,
.search-page-links,
.message-panel,
.job-detail {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.board-results-shell {
  padding: 18px;
}

.board-results-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  padding: 4px 2px 16px;
}

.job-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  margin: 0 -8px;
  padding: 18px 8px;
  border-top: 1px solid var(--line);
  border-radius: 8px;
  color: inherit;
  cursor: pointer;
  transition: background-color 140ms ease, box-shadow 140ms ease;
}

.job-card-link {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 8px;
}

.job-card:hover,
.job-card:focus-within {
  background: var(--soft-bg);
}

.job-card:focus-within {
  outline: 3px solid var(--primary-soft);
  outline-offset: 2px;
}

.job-card-link:focus-visible {
  outline: none;
}

.job-card-main {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 14px;
  pointer-events: none;
}

.company-mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--primary);
  color: #000000;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.2);
  font-weight: 900;
  overflow: hidden;
  position: relative;
  z-index: 3;
  flex-shrink: 0;
  pointer-events: auto;
  text-decoration: none;
}

.company-mark-large {
  width: 74px;
  height: 74px;
  border-radius: 8px;
  font-size: 22px;
}

.company-initials {
  display: grid;
  width: 100%;
  height: 100%;
  grid-area: 1 / 1;
  place-items: center;
}

.company-logo {
  display: block;
  width: 100%;
  height: 100%;
  grid-area: 1 / 1;
  object-fit: cover;
  padding: 0;
  background: #ffffff;
}

.company-mark-large .company-logo {
  padding: 0;
}

.company-mark.logo-loaded .company-logo {
  display: block;
}

.company-mark.logo-loaded .company-initials {
  display: none;
}

.company-mark.logo-failed .company-initials {
  display: grid;
}

.company-link {
  position: relative;
  z-index: 3;
  pointer-events: auto;
  text-decoration: none;
}

.company-link:hover {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.job-card:hover h3 {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.job-location,
.detail-location {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 650;
}

.job-preview {
  margin: 12px 0 0;
  color: var(--muted);
}

.job-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.job-tags span {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  padding: 4px 9px;
  border-radius: 6px;
  background: var(--tag-bg);
  color: var(--muted-strong);
  font-size: 13px;
  font-weight: 750;
}

.job-card-actions {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  pointer-events: none;
}

.pagination {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.pagination > :last-child {
  justify-self: end;
}

.pagination [aria-busy="true"] {
  opacity: 0.72;
  pointer-events: none;
}

.pagination-end {
  color: var(--muted);
  font-weight: 750;
  justify-self: end;
}

.board-intro,
.search-page-links,
.message-panel {
  margin: 0 0 24px;
  padding: 20px;
}

.board-intro p,
.message-panel p {
  max-width: 820px;
  margin: 0;
  color: var(--muted);
}

.intro-actions,
.detail-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
}

.search-page-links {
  margin-top: 24px;
}

.search-page-links div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.search-page-links a {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 6px 10px;
  border-radius: 6px;
  background: var(--tag-bg);
  color: var(--text);
  font-size: 14px;
  font-weight: 750;
  text-decoration: none;
}

.search-page-links a:hover {
  background: var(--primary-soft);
}

.empty-state {
  padding: 28px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

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

.job-detail {
  padding: 24px;
}

.company-hero {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  margin: 0 0 24px;
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.company-meta {
  margin-top: 14px;
}

.detail-kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
  color: var(--muted);
  font-weight: 750;
}

.detail-kicker a {
  color: var(--text);
  text-decoration: none;
}

.detail-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: start;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.detail-identity {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 18px;
}

.detail-facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 20px 0;
}

.detail-facts div {
  min-height: 78px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft-bg);
}

.detail-facts dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.detail-facts dd {
  margin: 6px 0 0;
  font-weight: 800;
}

.detail-description {
  max-width: 820px;
  color: #262626;
}

.detail-description p,
.detail-description ul,
.detail-description ol {
  margin: 0 0 16px;
}

.detail-description li {
  margin-bottom: 8px;
}

.message-panel {
  max-width: 720px;
  margin: 40px auto;
}

@media (max-width: 900px) {
  .board-topbar,
  .board-heading,
  .company-hero,
  .detail-header {
    grid-template-columns: 1fr;
  }

  .board-topbar {
    position: static;
    align-items: start;
    flex-direction: column;
  }

  .board-topbar nav {
    flex-wrap: wrap;
  }

  .board-search {
    grid-template-columns: 1fr;
  }

  .board-map-head {
    grid-template-columns: 1fr;
  }

  .board-map-actions {
    justify-content: flex-start;
  }

  .search-actions {
    justify-content: space-between;
  }

  .detail-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .board-main {
    width: min(100% - 20px, 1180px);
    padding-top: 18px;
  }

  h1 {
    font-size: 32px;
  }

  .board-heading,
  .job-card,
  .job-card-main,
  .board-results-head,
  .detail-identity,
  .detail-facts {
    grid-template-columns: 1fr;
  }

  .board-results-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .board-map-shell {
    padding: 12px;
  }

  .board-map-canvas {
    height: 340px;
  }

  .board-map-actions,
  .board-map-actions .button-secondary {
    width: 100%;
  }

  .job-card .company-mark {
    display: none;
  }

  .job-card-actions,
  .pagination > :last-child,
  .pagination-end {
    justify-self: stretch;
  }

  .button-primary,
  .button-secondary,
  .job-card-actions .button-secondary {
    width: 100%;
  }

  .pagination {
    grid-template-columns: 1fr;
    text-align: center;
  }
}
