/* ============================================================
   careers.css
   ============================================================ */

/* ===== CAREERS PAGE ===== */
.careers-page {
  background: var(--bg-page);
  padding: 180px 0 0;
}
.careers-page .container {
  max-width: 1180px;
}

/* Header / intro */
.careers-head {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 64px;
  align-items: start;
  margin-bottom: 96px;
  padding-bottom: 72px;
  border-bottom: 1px solid var(--border-mid);
}
.careers-meta .crumb {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--accent-rule);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.careers-meta .crumb::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--accent-rule);
}
.careers-meta .meta-stat {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.4px;
  color: var(--fg-muted);
  margin: 0;
  line-height: 18px;
}
.careers-meta .meta-stat span {
  display: block;
  color: var(--fg-secondary);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-size: 11px;
  margin-bottom: 4px;
}
.careers-head h1 {
  font-size: clamp(48px, 6vw, 88px);
  line-height: 0.96;
  letter-spacing: -0.03em;
  font-weight: 300;
  margin: 0 0 28px;
  color: var(--fg-primary);
}
.careers-head h1 .o {
  color: var(--accent);
  font-weight: 400;
}
.careers-head .lede {
  font-size: 21px;
  line-height: 32px;
  color: var(--fg-secondary);
  margin: 0;
  font-weight: 300;
  letter-spacing: -0.1px;
  max-width: 60ch;
}

/* Roles */
.careers-roles {
  padding-bottom: 120px;
}
.roles-section-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--accent-rule);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.roles-section-eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--accent-rule);
}
.roles-section-title {
  font-size: 38px;
  line-height: 1.15;
  letter-spacing: -1px;
  font-weight: 300;
  color: var(--fg-primary);
  margin: 0 0 64px;
  max-width: 22ch;
}
.roles-section-title .o {
  color: var(--accent);
  font-weight: 400;
}

.dept {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 64px;
  align-items: start;
  padding: 56px 0;
  border-top: 1px solid var(--border-subtle);
}
.dept:first-of-type {
  border-top: 1px solid var(--border-strong);
}
.dept-meta {
  position: sticky;
  top: 140px;
}
.dept-num {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.6px;
  color: var(--accent-rule);
  margin: 0 0 8px;
  text-transform: uppercase;
}
.dept-name {
  font-size: 24px;
  line-height: 30px;
  font-weight: 400;
  letter-spacing: -0.3px;
  color: var(--fg-primary);
  margin: 0 0 12px;
}
.dept-blurb {
  font-size: 14px;
  line-height: 22px;
  color: var(--fg-muted);
  margin: 0;
  font-weight: 300;
}
.role-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--border-mid);
}
.role-row {
  display: grid;
  grid-template-columns: 1fr auto auto auto;
  gap: 32px;
  align-items: center;
  padding: 22px 0;
  border-bottom: 1px solid var(--border-mid);
  transition: color 0.15s;
  cursor: pointer;
}
.role-row:hover .role-title {
  color: var(--accent);
}
.role-row:hover .role-arrow {
  color: var(--accent);
  transform: translateX(4px);
}
.role-title {
  font-size: 18px;
  font-weight: 400;
  color: var(--fg-primary);
  letter-spacing: -0.2px;
  line-height: 26px;
  transition: color 0.15s;
}
.role-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--fg-muted);
  white-space: nowrap;
}
.role-arrow {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-secondary);
  transition:
    color 0.15s,
    transform 0.15s;
}
.role-empty {
  padding: 20px 0;
  border-bottom: 1px solid var(--border-mid);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--fg-muted);
}

/* Apply form */
.careers-apply {
  background: var(--bg-section-alt);
  border-top: 1px solid var(--border-subtle);
  padding: 140px 0 160px;
}
.careers-apply .container {
  max-width: 1180px;
}
.apply-grid {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 64px;
  align-items: start;
}
.apply-meta .crumb {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--accent-rule);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.apply-meta .crumb::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--accent-rule);
}
.apply-meta h2 {
  font-size: 38px;
  line-height: 1.1;
  letter-spacing: -1px;
  font-weight: 300;
  color: var(--fg-primary);
  margin: 0 0 16px;
}
.apply-meta h2 .o {
  color: var(--accent);
  font-weight: 400;
}
.apply-meta p {
  font-size: 15px;
  line-height: 24px;
  color: var(--fg-secondary);
  margin: 0;
  font-weight: 300;
  max-width: 44ch;
}

.apply-form {
  background: var(--bg-page);
  border: 1px solid var(--border-subtle);
  padding: 48px;
  box-shadow: var(--shadow-card);
}

/* ===== ROLE NOT FOUND ===== */
.role-not-found {
  padding: 80px 0 120px;
  max-width: 480px;
}
.role-not-found h1 {
  font-size: clamp(36px, 5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  font-weight: 300;
  margin: 0 0 20px;
  color: var(--fg-primary);
}
.role-not-found p {
  font-size: 17px;
  line-height: 28px;
  color: var(--fg-secondary);
  font-weight: 300;
  margin: 0 0 32px;
}

/* Closed / no-roles state */
.apply-closed {
  text-align: center;
  max-width: 44ch;
  margin: 0 auto;
}
.apply-closed::before {
  content: "";
  display: block;
  width: 40px;
  height: 2px;
  background: var(--accent);
  margin: 0 auto 32px;
}
/* With no roles open, the message is its own centred block between the intro and the teams */
.careers-closed {
  margin: 0 auto 96px;
  padding: 64px 32px;
  background: var(--bg-section-alt);
  border: 1px solid var(--border-subtle);
  max-width: none;
}
.careers-closed .apply-closed-msg {
  max-width: 44ch;
  margin: 0 auto;
}
.apply-closed-msg {
  font-size: 19px;
  line-height: 30px;
  color: var(--fg-secondary);
  font-weight: 300;
  margin: 0;
  letter-spacing: -0.1px;
}
.apply-closed-msg a {
  color: var(--fg-primary);
  border-bottom: 1px solid var(--border-strong);
  padding-bottom: 1px;
  transition:
    color 0.15s,
    border-color 0.15s;
}
.apply-closed-msg a:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* ===== ROLE DETAIL PAGE ===== */
.role-page {
  background: var(--bg-page);
  padding: 180px 0 0;
}
.role-page .container {
  max-width: 1180px;
}

.role-crumbs {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin: 0 0 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.role-crumbs a {
  color: var(--fg-secondary);
  transition: color 0.15s;
}
.role-crumbs a:hover {
  color: var(--accent);
}
.role-crumbs .sep {
  color: var(--border-strong);
}
.role-crumbs .here {
  color: var(--accent-rule);
}

.role-hero {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 64px;
  align-items: start;
  padding-bottom: 72px;
  margin-bottom: 80px;
  border-bottom: 1px solid var(--border-mid);
}
.role-hero h1 {
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.02em;
  font-weight: 300;
  margin: 0 0 28px;
  color: var(--fg-primary);
  max-width: 18ch;
}
.role-hero h1 .o {
  color: var(--accent);
  font-weight: 400;
}
.role-hero .lede {
  font-size: 19px;
  line-height: 30px;
  color: var(--fg-secondary);
  margin: 0;
  font-weight: 300;
  max-width: 56ch;
}

.role-facts {
  border: 1px solid var(--border-subtle);
  background: var(--bg-section-alt);
  padding: 28px;
  position: sticky;
  top: 140px;
}
.role-facts .fact {
  padding: 12px 0;
  border-bottom: 1px solid var(--border-subtle);
}
.role-facts .fact:last-of-type {
  border-bottom: 0;
}
.role-facts .fact-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin: 0 0 4px;
}
.role-facts .fact-value {
  font-size: 14px;
  line-height: 22px;
  color: var(--fg-primary);
  margin: 0;
}
.role-facts .apply-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 18px;
  margin-top: 20px;
  background: var(--accent);
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  border: 0;
  cursor: pointer;
  transition: background 0.15s;
  text-decoration: none;
}
.role-facts .apply-cta:hover {
  background: var(--accent-hover);
}

.role-body {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 64px;
  align-items: start;
  padding-bottom: 120px;
}
.role-body-meta {
  position: sticky;
  top: 140px;
}
.role-body-meta .num {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.6px;
  color: var(--accent-rule);
  margin: 0 0 8px;
  text-transform: uppercase;
}
.role-body-meta .label {
  font-size: 18px;
  line-height: 26px;
  font-weight: 400;
  letter-spacing: -0.2px;
  color: var(--fg-primary);
  margin: 0;
}
.role-body-content {
  max-width: 68ch;
}
.role-body-content h2 {
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.5px;
  font-weight: 300;
  color: var(--fg-primary);
  margin: 56px 0 18px;
}
.role-body-content h2:first-of-type {
  margin-top: 0;
}
.role-body-content p {
  font-size: 16px;
  line-height: 28px;
  color: var(--fg-secondary);
  margin: 0 0 16px;
  font-weight: 300;
}
.role-body-content ul {
  list-style: none;
  margin: 8px 0 16px;
  padding: 0;
}
.role-body-content ul li {
  position: relative;
  padding: 6px 0 6px 22px;
  font-size: 16px;
  line-height: 26px;
  color: var(--fg-secondary);
  font-weight: 300;
}
.role-body-content ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 17px;
  width: 10px;
  height: 1px;
  background: var(--accent);
}

/* Apply summary on role page */
.apply-for {
  background: var(--bg-page);
  border: 1px solid var(--border-subtle);
  padding: 18px 20px;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.apply-for-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin: 0 0 4px;
}
.apply-for-value {
  font-size: 16px;
  line-height: 22px;
  color: var(--fg-primary);
  margin: 0;
  font-weight: 400;
}
.apply-for a {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--fg-secondary);
  border-bottom: 1px solid var(--border-strong);
  padding-bottom: 1px;
  transition:
    color 0.15s,
    border-color 0.15s;
}
.apply-for a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.salary-note {
  margin-top: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.4px;
  color: var(--fg-secondary);
}

@media (max-width: 900px) {
  .careers-page {
    padding: 140px 0 0;
  }
  .careers-head,
  .dept,
  .apply-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .dept-meta {
    position: static;
  }
  .careers-apply {
    padding: 100px 0 120px;
  }
  .apply-form {
    padding: 32px 24px;
  }
  .field-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .role-row {
    grid-template-columns: 1fr auto;
    gap: 8px 18px;
  }
  .role-row .role-tag.location {
    grid-column: 1 / 2;
  }
  .role-row .role-arrow {
    grid-row: 1 / 3;
    grid-column: 2;
    align-self: center;
  }

  .role-page {
    padding: 140px 0 0;
  }
  .role-hero,
  .role-body {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .role-facts {
    position: static;
  }
  .role-body-meta {
    position: static;
  }
  .role-body-content h2 {
    margin-top: 40px;
  }
}

/* ---- 768px — careers pages ---- */
@media (max-width: 768px) {
  .careers-page {
    padding: 100px 0 0;
  }
  .careers-apply {
    padding: 72px 0 80px;
  }
  .careers-head {
    padding-bottom: 48px;
    margin-bottom: 64px;
  }
}
