/* operator profile (templates/core/operator_profile.html and its body partial _operator_profile_body.html, also
   included by the operator review page; shared, so it lives outside css/templates/): a resume page with a header card, a sticky section menu (a scrollable strip
   on phones) and the sections in one column; tokens only. */

.operator-profile {
  padding-block: var(--ds-space-48) var(--ds-space-120);
}

.operator-profile__body {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-24);
  min-width: 0;
}

.operator-profile__body .ds-card:hover {
  transform: none;
}

.operator-profile__notice {
  display: block;
}

/* Header */

.operator-profile__header {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--ds-space-16);
  padding: var(--ds-space-32) var(--ds-space-24);
}

.operator-profile__who {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--ds-space-16);
}

.operator-profile__identity {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--ds-space-8);
  min-width: 0;
}

.operator-profile__name {
  margin: 0;
  font-size: var(--ds-type-h3-size);
  line-height: var(--ds-type-h3-leading);
  font-weight: 600;
  letter-spacing: -0.4px;
  overflow-wrap: anywhere;
}

.operator-profile__summary {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-12);
  min-width: 0;
}

.operator-profile__headline {
  margin: 0;
  font-size: var(--ds-type-body-l-size);
  line-height: var(--ds-type-body-l-leading);
  overflow-wrap: anywhere;
}

.operator-profile__facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ds-space-4) var(--ds-space-16);
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--ds-text-muted);
  font-size: var(--ds-type-small-size);
  line-height: var(--ds-type-small-leading);
}

.operator-profile__cta {
  align-self: stretch;
}

.operator-profile__cta--end {
  margin-top: var(--ds-space-24);
}

@media (min-width: 900px) {
  .operator-profile__header {
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: var(--ds-space-32);
    padding: var(--ds-space-32);
  }

  .operator-profile__who {
    flex-wrap: nowrap;
    max-width: 320px;
  }

  .operator-profile__cta {
    align-self: auto;
  }

  .operator-profile__cta--end {
    align-self: flex-start;
  }
}

/* Section menu */

.operator-profile__menu {
  position: sticky;
  top: 0;
  z-index: var(--ds-z-sticky);
  margin-inline: calc(-1 * var(--ds-space-4));
  padding-inline: var(--ds-space-4);
  background: var(--ds-ground);
  border-bottom: 1px solid var(--ds-border-subtle);
}

.operator-profile__menu-list {
  display: flex;
  gap: var(--ds-space-4);
  margin: 0;
  padding: var(--ds-space-8) 0;
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.operator-profile__menu-list::-webkit-scrollbar {
  display: none;
}

.operator-profile__menu-list li {
  flex: none;
}

.operator-profile__menu-link {
  display: inline-block;
  padding: var(--ds-space-8) var(--ds-space-12);
  border-radius: var(--ds-radius-pill);
  color: var(--ds-text);
  font-size: var(--ds-type-small-size);
  line-height: var(--ds-type-small-leading);
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}

.operator-profile__menu-link:hover {
  background: var(--ds-surface);
}

.operator-profile__menu-link:focus-visible,
.operator-profile__link:focus-visible {
  outline: 2px solid var(--ds-focus-ring);
  outline-offset: 2px;
}

/* Sections */

.operator-profile__main {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-48);
  min-width: 0;
  padding-top: var(--ds-space-24);
}

.operator-profile__section {
  scroll-margin-top: var(--ds-space-64);
}

.operator-profile__item {
  scroll-margin-top: var(--ds-space-64);
}

html:has(.operator-profile) {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html:has(.operator-profile) {
    scroll-behavior: auto;
  }
}

.operator-profile__heading {
  margin: 0 0 var(--ds-space-16);
  font-size: var(--ds-type-h3-size);
  line-height: var(--ds-type-h3-leading);
  font-weight: 600;
  letter-spacing: -0.4px;
}

.operator-profile__eyebrow {
  margin: 0 0 var(--ds-space-12);
  color: var(--ds-text-muted);
  font-size: var(--ds-type-caption-size);
  line-height: var(--ds-type-caption-leading);
  font-weight: 600;
  letter-spacing: var(--ds-type-eyebrow-tracking);
  text-transform: uppercase;
}

.operator-profile__text {
  max-width: 72ch;
}

.operator-profile__text p {
  margin: 0 0 var(--ds-space-16);
  font-size: var(--ds-type-body-size);
  line-height: var(--ds-type-body-leading);
}

.operator-profile__text p:last-child {
  margin-bottom: 0;
}

.operator-profile__muted {
  margin: 0;
  color: var(--ds-text-muted);
  font-size: var(--ds-type-small-size);
  line-height: var(--ds-type-small-leading);
}

.operator-profile__link {
  color: var(--ds-text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.operator-profile__link:hover {
  text-decoration-thickness: 2px;
}

.operator-profile__chips,
.operator-profile__plain,
.operator-profile__list,
.operator-profile__rows,
.operator-profile__metrics,
.operator-profile__bullets,
.operator-profile__steps {
  margin: 0;
  padding: 0;
  list-style: none;
}

.operator-profile__chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ds-space-8);
}

.operator-profile__chip-years {
  color: var(--ds-text-muted);
}

.operator-profile__chip-years::before {
  content: "\00b7";
  margin-inline: var(--ds-space-4);
}

/* Highlights */

.operator-profile__highlights {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--ds-space-16);
}

@media (min-width: 900px) {
  .operator-profile__highlights {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  }
}

.operator-profile__highlight {
  padding: var(--ds-space-24);
}

.operator-profile__plain {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-12);
  font-size: var(--ds-type-body-size);
  line-height: var(--ds-type-body-leading);
  overflow-wrap: anywhere;
}

.operator-profile__plain .operator-profile__muted {
  display: block;
}

/* Engagements and work history */

.operator-profile__list {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-16);
}

.operator-profile__item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--ds-space-12);
  padding: var(--ds-space-24);
}

.operator-profile__item > * {
  margin-block: 0;
}

.operator-profile__title {
  margin: 0;
  font-size: var(--ds-type-body-l-size);
  line-height: var(--ds-type-body-l-leading);
  font-weight: 600;
}

.operator-profile__metrics {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ds-space-16) var(--ds-space-32);
}

.operator-profile__metric {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-4);
  min-width: 0;
}

.operator-profile__figure {
  font-size: var(--ds-type-h2-size);
  line-height: var(--ds-type-h2-leading);
  font-weight: 600;
  letter-spacing: var(--ds-type-h2-tracking);
  color: var(--ds-text);
  overflow-wrap: anywhere;
}

.operator-profile__figure-label {
  color: var(--ds-text-muted);
  font-size: var(--ds-type-small-size);
  line-height: var(--ds-type-small-leading);
}

@media (max-width: 599px) {
  .operator-profile__figure {
    font-size: var(--ds-type-h3-size);
    line-height: var(--ds-type-h3-leading);
    letter-spacing: -0.4px;
  }
}

.operator-profile__story {
  display: grid;
  gap: var(--ds-space-4);
  margin: 0;
}

.operator-profile__story dt,
.operator-profile__terms dt {
  color: var(--ds-text-muted);
  font-size: var(--ds-type-caption-size);
  line-height: var(--ds-type-caption-leading);
  font-weight: 600;
  letter-spacing: var(--ds-type-eyebrow-tracking);
  text-transform: uppercase;
}

.operator-profile__story dd {
  margin: 0 0 var(--ds-space-8);
  font-size: var(--ds-type-body-size);
  line-height: var(--ds-type-body-leading);
}

.operator-profile__story dd:last-of-type {
  margin-bottom: 0;
}

.operator-profile__bullets {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-8);
  padding-left: var(--ds-space-16);
  list-style: disc;
  font-size: var(--ds-type-body-size);
  line-height: var(--ds-type-body-leading);
}

/* Education and certifications */

.operator-profile__rows {
  display: flex;
  flex-direction: column;
}

.operator-profile__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--ds-space-4) var(--ds-space-16);
  padding-block: var(--ds-space-16);
  border-bottom: 1px solid var(--ds-border-subtle);
}

.operator-profile__row:first-child {
  padding-top: 0;
}

.operator-profile__row .operator-profile__title {
  font-size: var(--ds-type-body-size);
  line-height: var(--ds-type-body-leading);
}

/* Skills */

.operator-profile__skill-groups {
  display: flex;
  flex-direction: column;
  gap: var(--ds-space-24);
}

.operator-profile__skill-group .operator-profile__eyebrow {
  margin-bottom: var(--ds-space-8);
}

/* Deal terms */

.operator-profile__terms {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--ds-space-16);
  margin: var(--ds-space-16) 0 0;
}

.operator-profile__terms dd {
  margin: var(--ds-space-4) 0 0;
  font-weight: 500;
}

/* How working together works */

.operator-profile__steps {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--ds-space-16);
  counter-reset: operator-step;
}

@media (min-width: 900px) {
  .operator-profile__steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.operator-profile__step {
  position: relative;
  padding: var(--ds-space-24) var(--ds-space-24) var(--ds-space-24) 72px;
  border: 1px solid var(--ds-border-subtle);
  border-radius: var(--ds-radius-24);
  background: var(--ds-surface);
  counter-increment: operator-step;
}

.operator-profile__step::before {
  content: counter(operator-step);
  position: absolute;
  top: var(--ds-space-24);
  left: var(--ds-space-24);
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--ds-space-32);
  height: var(--ds-space-32);
  border-radius: var(--ds-radius-pill);
  background: var(--ds-status-active-bg);
  color: var(--ds-status-active-text);
  font-size: var(--ds-type-small-size);
  font-weight: 600;
}

.operator-profile__step-text {
  margin: var(--ds-space-4) 0 0;
  color: var(--ds-text-muted);
  font-size: var(--ds-type-small-size);
  line-height: var(--ds-type-small-leading);
}
