.roles-section {
  padding-bottom: 85px;
}

.roles-section .projects-intro {
  margin-top: 46px;
  max-width: 570px;
}

.roles-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin-top: 36px;
}

.role-card {
  grid-column: span 2;
  min-height: 350px;
  padding: 20px;
}

.role-card:nth-last-child(2) {
  grid-column: 2 / span 2;
}

.role-card:last-child {
  grid-column: 4 / span 2;
}

.role-card h3 {
  font-size: clamp(30px, 3.35vw, 49px);
  line-height: .9;
}

.role-card .project-event {
  max-width: 250px;
  margin: 0 0 12px;
  font: 500 9px/1.45 var(--mono);
  letter-spacing: .05em;
  text-transform: uppercase;
}

.role-card__details {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
  padding-top: 10px;
  padding-right: 26px;
}

.role-card__details p {
  max-width: none;
  font-size: 8px;
  line-height: 1.45;
}

.role-card__examples {
  opacity: .72;
}

.role-card__details .project-arrow {
  position: absolute;
  right: 0;
  bottom: 0;
}

.role-card__explore {
  position: absolute;
  right: 0;
  bottom: 0;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: 500 8px/1.25 var(--mono);
  letter-spacing: .06em;
  text-transform: uppercase;
  cursor: pointer;
}

.role-card__details .role-card__explore .project-arrow {
  position: static;
  font-size: 22px;
}

.role-card .role-card__details {
  padding-right: 96px;
}

.role-card__explore:focus-visible,
.role-expansion button:focus-visible,
.role-expansion a:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
}

.role-card--coordination {
  background: var(--accent);
}

.role-card--coordination:after {
  content: "PLAN";
  position: absolute;
  right: -9px;
  top: 62px;
  z-index: -1;
  color: rgba(255,255,255,.36);
  font-size: clamp(82px, 9vw, 138px);
  font-weight: 700;
  letter-spacing: -.13em;
}

.role-card--operations {
  color: var(--paper);
  background: radial-gradient(circle at 72% 26%, rgba(233,173,150,.45), transparent 22%), linear-gradient(145deg,#191614,#080808 76%);
}

.role-card--crew {
  background: linear-gradient(120deg,rgba(243,239,235,.93),rgba(243,239,235,.38)),url("assets/blijdorp-crew-base.png") center/cover no-repeat;
}

.role-card--crew .project-orbit {
  width: 245px;
  height: 245px;
  top: 34px;
}

.role-card--entrance {
  color: var(--paper);
  background: linear-gradient(125deg,rgba(10,10,10,.8),rgba(10,10,10,.2)),url("assets/gob-entrance.jpg") center 46%/cover no-repeat;
}

.role-card--infrastructure {
  color: var(--paper);
  background: linear-gradient(125deg,rgba(10,10,10,.76),rgba(10,10,10,.16)),url("assets/experience-aoa-infra.png") center/cover no-repeat;
}

.role-card--infrastructure .project-lines {
  opacity: .35;
}

.role-expansion-layer {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 78px clamp(22px, 6.5vw, 105px) 32px;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity .42s ease, visibility 0s linear .42s;
}

.role-expansion-layer.is-open {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transition-delay: 0s;
}

.role-expansion__scrim {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: rgba(17,14,12,.38);
  backdrop-filter: blur(2px);
  cursor: pointer;
}

.role-expansion {
  --role-expansion-line: rgba(11,11,11,.52);
  --role-expansion-soft-line: rgba(11,11,11,.25);
  position: relative;
  z-index: 1;
  width: min(1060px, 100%);
  max-height: calc(100vh - 110px);
  overflow: auto;
  padding: clamp(28px, 4vw, 58px);
  background: var(--accent);
  color: var(--ink);
  box-shadow: 0 30px 75px rgba(20,15,12,.32);
  opacity: 0;
  transform: translateY(28px) scale(.9);
  transform-origin: 20% 45%;
  transition: transform .52s cubic-bezier(.2,.72,.2,1), opacity .34s ease;
}

[data-role-expansion="coordination"] .role-expansion {
  background: var(--accent);
}

[data-role-expansion="operations"] .role-expansion {
  --role-expansion-line: rgba(243,239,235,.58);
  --role-expansion-soft-line: rgba(243,239,235,.28);
  color: var(--paper);
  background: radial-gradient(circle at 72% 26%, rgba(233,173,150,.45), transparent 22%), linear-gradient(145deg,#191614,#080808 76%);
}

[data-role-expansion="crew"] .role-expansion {
  background: linear-gradient(120deg,rgba(243,239,235,.93),rgba(243,239,235,.38)),url("assets/blijdorp-crew-base.png") center/cover no-repeat;
}

[data-role-expansion="entrance"] .role-expansion {
  --role-expansion-line: rgba(243,239,235,.58);
  --role-expansion-soft-line: rgba(243,239,235,.28);
  color: var(--paper);
  background: linear-gradient(125deg,rgba(10,10,10,.84),rgba(10,10,10,.44)),url("assets/gob-entrance.jpg") center 46%/cover no-repeat;
}

[data-role-expansion="infrastructure"] .role-expansion {
  --role-expansion-line: rgba(243,239,235,.58);
  --role-expansion-soft-line: rgba(243,239,235,.28);
  color: var(--paper);
  background: linear-gradient(125deg,rgba(10,10,10,.82),rgba(10,10,10,.4)),url("assets/experience-aoa-infra.png") center/cover no-repeat;
}

.role-expansion-layer.is-open .role-expansion {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.role-expansion__close {
  position: absolute;
  top: 20px;
  right: 22px;
  padding: 0 0 3px;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: transparent;
  color: inherit;
  font: 500 9px/1.3 var(--mono);
  letter-spacing: .07em;
  text-transform: uppercase;
  cursor: pointer;
}

.role-expansion__layout {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, .92fr);
  gap: clamp(42px, 7vw, 95px);
}

.role-expansion__primary {
  display: flex;
  flex-direction: column;
  min-height: 530px;
}

.role-expansion__label,
.role-expansion__section h3 {
  margin: 0;
  font: 500 9px/1.35 var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.role-expansion__label {
  margin-bottom: 30px;
}

.role-expansion h2 {
  max-width: 590px;
  margin: 0;
  font-size: clamp(46px, 6.4vw, 88px);
  font-weight: 500;
  line-height: .88;
  letter-spacing: -.075em;
}

.role-expansion__intro {
  max-width: 500px;
  margin: 34px 0 0;
  font-size: 16px;
  line-height: 1.52;
}

.role-expansion__section {
  padding-top: 14px;
  border-top: 1px solid var(--role-expansion-line);
}

.role-expansion__section h3 {
  margin-bottom: 16px;
  opacity: .68;
}

.role-expansion__section p {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
}

.role-expansion__approach {
  margin-top: auto;
}

.role-expansion__secondary {
  display: flex;
  flex-direction: column;
  gap: 42px;
  padding-top: 50px;
}

.role-expansion ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.role-expansion li {
  position: relative;
  padding: 5px 0 5px 17px;
  border-bottom: 1px solid var(--role-expansion-soft-line);
  font: 500 10px/1.35 var(--mono);
}

.role-expansion li::before {
  content: "—";
  position: absolute;
  left: 0;
}

.role-expansion__experience-item {
  padding: 10px 0;
  border-bottom: 1px solid var(--role-expansion-soft-line);
}

.role-expansion__experience-link {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: start;
  width: 100%;
  padding: 0;
  color: inherit;
  text-decoration: none;
  transition: transform .28s ease;
}

.role-expansion__experience-link:hover {
  transform: translateX(7px);
}

.role-expansion__experience-link b {
  display: block;
  font-weight: 600;
  font-family: var(--sans);
  font-size: 12px;
}

.role-expansion__experience-link > span:last-child {
  font-size: 19px;
  transition: transform .28s ease;
}

.role-expansion__experience-link:hover > span:last-child {
  transform: translate(3px,-3px);
}

.role-expansion__experience-item > p {
  margin: 3px 0 0;
  font: 500 9px/1.45 var(--mono);
  opacity: .72;
}

body.role-expansion-open {
  overflow: hidden;
}

@media (max-width: 1050px) {
  .roles-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .role-card,
  .role-card:nth-last-child(2),
  .role-card:last-child {
    grid-column: auto;
  }

  .role-card:last-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .roles-section {
    padding-bottom: 65px;
  }

  .roles-section .projects-intro {
    margin-top: 36px;
  }

  .roles-grid {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 30px;
  }

  .role-card,
  .role-card:last-child {
    grid-column: auto;
    min-height: 385px;
    padding: 20px;
  }

  .role-card h3 {
    font-size: 42px;
  }

  .role-expansion-layer {
    place-items: start center;
    padding: 72px 12px 12px;
  }

  .role-expansion {
    max-height: calc(100vh - 84px);
    padding: 52px 22px 28px;
  }

  .role-expansion__layout {
    grid-template-columns: 1fr;
    gap: 38px;
  }

  .role-expansion__primary {
    min-height: 0;
  }

  .role-expansion h2 {
    font-size: clamp(45px, 14vw, 65px);
  }

  .role-expansion__intro {
    margin-top: 26px;
    font-size: 14px;
  }

  .role-expansion__approach {
    margin-top: 36px;
  }

  .role-expansion__secondary {
    gap: 36px;
    padding-top: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .role-expansion-layer,
  .role-expansion,
  .role-expansion__experience-link {
    transition: none;
  }
}
