/*
  Audience detail pages extend the Registered Evidence Grid. Each role begins
  with the same public filing record, then changes the question and next step.
*/

.page-role {
  --secondary-hero-art: url("/assets/filing-to-record-teal.png");
  --secondary-hero-position: 72% 50%;
  --secondary-hero-mobile-position: 64% 50%;
}

.page-role-recordkeepers {
  --secondary-hero-art: url("/assets/filing-lineage.webp");
}

.page-role-sponsors {
  --secondary-hero-art: url("/assets/filing-access-teal.png");
}

.role-hero {
  min-height: 760px;
  align-items: stretch;
}

.role-hero::before {
  background:
    linear-gradient(90deg, #05090b 0 36%, rgb(5 9 11 / .94) 49%, rgb(5 9 11 / .5) 75%, rgb(5 9 11 / .18) 100%),
    var(--secondary-hero-art) var(--secondary-hero-position) / cover no-repeat;
  opacity: 1;
}

.role-hero::after {
  top: auto;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgb(112 215 237 / .5) 18%, rgb(112 215 237 / .5) 82%, transparent);
  box-shadow: 0 -18px 50px rgb(50 181 216 / .1);
}

.role-hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(430px, .72fr);
  gap: clamp(54px, 8vw, 128px);
  align-items: end;
  padding-top: 150px;
  padding-bottom: 74px;
}

.role-hero-copy {
  max-width: 800px;
}

.role-hero .role-kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  align-items: center;
  margin: 0 0 24px;
  color: #70d7ed;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  line-height: 1.4;
  text-transform: uppercase;
}

.role-status {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  padding: 0 10px;
  border: 1px solid rgb(112 215 237 / .42);
  border-radius: 2px;
  background: rgb(112 215 237 / .08);
  color: #c7f3fb;
  letter-spacing: .08em;
}

.role-hero h1 {
  max-width: 12ch;
  color: #f4f6f2;
  font-size: clamp(54px, 6.2vw, 92px);
}

.role-hero h1 em {
  color: #9be9f7;
}

.role-hero .lede {
  max-width: 55ch;
  margin-top: 28px;
  color: #c4d0d2;
}

.role-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 34px;
}

.role-hero-actions .btn {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-inline: 22px;
}

.role-hero-actions .btn:not(.btn-ghost) {
  border-color: #116c88;
  background: #116c88;
  color: #fff;
}

.role-hero-actions .btn:not(.btn-ghost):hover {
  border-color: #0f6883;
  background: #0f6883;
}

.role-hero-actions .btn-ghost {
  border-color: rgb(244 246 242 / .36);
  color: #f4f6f2;
}

.role-hero-actions .btn-ghost:hover {
  border-color: #70d7ed;
  background: rgb(112 215 237 / .06);
  color: #fff;
}

.role-source-register {
  position: relative;
  margin: 0;
  border: 1px solid rgb(112 215 237 / .34);
  border-radius: 2px;
  background: rgb(5 14 17 / .9);
  color: #f4f6f2;
  box-shadow: 0 34px 72px -44px rgb(0 0 0 / .96);
}

.role-source-register::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 42%;
  height: 1px;
  background: #70d7ed;
  box-shadow: 0 0 22px rgb(112 215 237 / .72);
}

.role-source-register figcaption {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 20px;
  border-bottom: 1px solid rgb(244 246 242 / .16);
  color: #70d7ed;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .11em;
  line-height: 1.4;
  text-transform: uppercase;
}

.role-source-register figcaption span:last-child {
  color: rgb(244 246 242 / .5);
  text-align: right;
}

.role-source-row {
  display: grid;
  grid-template-columns: minmax(110px, .8fr) minmax(0, 1.25fr);
  gap: 22px;
  padding: 18px 20px;
  border-bottom: 1px solid rgb(244 246 242 / .12);
}

.role-source-row:last-child {
  border-bottom: 0;
}

.role-source-row span {
  color: rgb(244 246 242 / .5);
  font-size: 11px;
  line-height: 1.45;
}

.role-source-row strong {
  color: #f4f6f2;
  font-size: 13px;
  font-weight: 580;
  line-height: 1.45;
}

.role-source-register .source-note {
  margin: 0;
  padding: 14px 20px;
  border-top: 1px solid rgb(112 215 237 / .2);
  color: #9cb0b5;
  font-size: 10px;
  line-height: 1.55;
}

.secondary-body #main > section.role-thesis {
  background: #fcfdfc;
}

.role-thesis-grid {
  display: grid;
  grid-template-columns: minmax(260px, .72fr) minmax(0, 1.28fr);
  gap: clamp(48px, 8vw, 132px);
  align-items: start;
}

.role-thesis-head {
  position: sticky;
  top: 118px;
}

.role-thesis-head .label,
.role-workflow-head .label,
.role-record-head .label,
.role-boundary .label {
  margin-bottom: 18px;
}

.role-thesis-head h2,
.role-workflow-head h2,
.role-record-head h2 {
  max-width: 14ch;
}

.role-evidence-list {
  margin: 0;
  border-top: 1px solid var(--ink-1);
}

.role-evidence-list > div {
  display: grid;
  grid-template-columns: minmax(150px, .72fr) minmax(0, 1.28fr);
  gap: clamp(24px, 4vw, 58px);
  padding-block: 30px;
  border-bottom: 1px solid var(--line);
}

.role-evidence-list dt {
  color: var(--ink-1);
  font-size: 16px;
  font-weight: 650;
  line-height: 1.35;
}

.role-evidence-list dt span {
  display: block;
  margin-bottom: 8px;
  color: var(--accent-ink);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.role-evidence-list dd {
  margin: 0;
  color: var(--ink-3);
  font-size: 16px;
  line-height: 1.68;
}

.secondary-body #main > section.role-workflow {
  overflow: hidden;
  background: #080d0f;
  color: #f4f2ea;
}

.role-workflow-head {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(300px, .7fr);
  gap: clamp(40px, 8vw, 120px);
  align-items: end;
}

.secondary-body .role-workflow h2 {
  color: #f4f2ea;
}

.secondary-body .role-workflow h2 em,
.secondary-body .role-workflow .label {
  color: #70d7ed;
}

.role-workflow-head > p {
  max-width: 54ch;
  color: #b8c7c8;
  font-size: 17px;
  line-height: 1.65;
}

.role-sequence {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: clamp(54px, 7vw, 90px);
  border-top: 1px solid rgb(112 215 237 / .45);
  border-left: 1px solid rgb(244 246 242 / .15);
}

.role-sequence > div {
  min-height: 245px;
  display: flex;
  flex-direction: column;
  padding: 24px 22px;
  border-right: 1px solid rgb(244 246 242 / .15);
  border-bottom: 1px solid rgb(244 246 242 / .15);
}

.role-sequence span {
  color: #70d7ed;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.role-sequence h3 {
  margin-top: auto;
  color: #f4f2ea;
  font-size: 21px;
}

.role-sequence p {
  margin: 12px 0 0;
  color: #aebdc0;
  font-size: 13px;
  line-height: 1.58;
}

.secondary-body #main > section.role-record-section {
  background: #e5eae7;
}

.role-record-head {
  display: grid;
  grid-template-columns: minmax(0, .86fr) minmax(300px, .74fr);
  gap: clamp(40px, 8vw, 120px);
  align-items: end;
}

.role-record-head > p {
  max-width: 56ch;
  color: var(--ink-3);
  font-size: 17px;
  line-height: 1.65;
}

.role-record {
  margin-top: clamp(52px, 7vw, 86px);
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: #fcfdfc;
}

.role-record-top {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
  background: #111b1e;
  color: #f4f6f2;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .05em;
}

.role-record-top span:last-child {
  color: #70d7ed;
  text-align: right;
}

.role-record-row {
  display: grid;
  grid-template-columns: minmax(160px, .8fr) minmax(150px, .65fr) minmax(220px, 1.2fr);
  gap: 24px;
  padding: 20px 22px;
  border-bottom: 1px solid var(--line);
}

.role-record-row:last-child {
  border-bottom: 0;
}

.role-record-row strong {
  color: var(--ink-1);
  font-size: 14px;
}

.role-record-row span,
.role-record-row small {
  color: var(--ink-3);
  font-size: 12px;
  line-height: 1.5;
}

.secondary-body #main > section.role-boundary-section {
  background: #fcfdfc;
}

.role-boundary {
  display: grid;
  grid-template-columns: minmax(260px, .78fr) minmax(0, 1.22fr);
  gap: clamp(48px, 8vw, 130px);
  padding-top: 34px;
  border-top: 1px solid var(--ink-1);
}

.role-boundary h2 {
  max-width: 15ch;
}

.role-boundary-copy {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 clamp(28px, 5vw, 72px);
}

.role-boundary-copy p {
  margin: 0;
  color: var(--ink-3);
  font-size: 15px;
  line-height: 1.7;
}

.role-boundary-copy strong {
  color: var(--ink-1);
}

.secondary-body #main > section.role-close {
  background: #0d181b;
  color: #f4f6f2;
}

.role-close .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 48px;
  align-items: end;
}

.secondary-body .role-close h2 {
  max-width: 16ch;
  color: #f4f6f2;
}

.secondary-body .role-close h2 em {
  color: #70d7ed;
}

.role-close p {
  max-width: 62ch;
  margin-top: 22px;
  color: #b8c7c8;
  font-size: 16px;
  line-height: 1.65;
}

.role-close .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.role-close .btn {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.role-close .btn:not(.btn-ghost) {
  border-color: #116c88;
  background: #116c88;
  color: #fff;
}

.role-close .btn-ghost {
  border-color: rgb(244 246 242 / .32);
  color: #f4f6f2;
}

.role-close .btn-ghost:hover {
  border-color: #70d7ed;
  background: rgb(112 215 237 / .06);
  color: #fff;
}

.role-close-note {
  grid-column: 1 / -1;
  margin: -20px 0 0;
  color: #8fa2a6;
  font-size: 11px;
}

.secondary-body.page-role-sponsors #main > section.role-thesis {
  background: #eff7fa;
}

.page-role-sponsors .role-status-panel {
  margin-top: 34px;
  padding: 18px 20px;
  border: 1px solid rgb(112 215 237 / .3);
  background: rgb(112 215 237 / .06);
  color: #c5d7da;
  font-size: 13px;
  line-height: 1.6;
}

.page-role-sponsors .role-status-panel strong {
  color: #fff;
}

@media (max-width: 1080px) {
  .role-hero .wrap {
    grid-template-columns: 1fr;
    gap: 52px;
    align-items: start;
  }

  .role-source-register {
    max-width: 720px;
  }

  .role-sequence {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 860px) {
  .role-hero {
    min-height: auto;
  }

  .role-hero::before {
    background:
      linear-gradient(180deg, rgb(5 9 11 / .97) 0%, rgb(5 9 11 / .84) 58%, rgb(5 9 11 / .64) 100%),
      var(--secondary-hero-art) var(--secondary-hero-mobile-position) / cover no-repeat;
  }

  .role-hero .wrap {
    padding-top: 122px;
  }

  .role-thesis-grid,
  .role-workflow-head,
  .role-record-head,
  .role-boundary,
  .role-close .wrap {
    grid-template-columns: 1fr;
  }

  .role-thesis-head {
    position: static;
  }

  .role-close .actions {
    justify-content: flex-start;
  }

  .role-close-note {
    margin-top: -12px;
  }
}

@media (max-width: 640px) {
  .role-hero .wrap {
    padding-top: 108px;
    padding-bottom: 56px;
  }

  .role-hero h1 {
    max-width: 11ch;
    font-size: clamp(44px, 13vw, 62px);
  }

  .role-hero-actions,
  .role-hero-actions .btn,
  .role-close .actions,
  .role-close .btn {
    width: 100%;
  }

  .role-source-register figcaption,
  .role-source-row,
  .role-evidence-list > div,
  .role-record-row {
    grid-template-columns: 1fr;
  }

  .role-source-register figcaption {
    display: grid;
    gap: 5px;
  }

  .role-source-register figcaption span:last-child {
    text-align: left;
  }

  .role-source-row,
  .role-evidence-list > div,
  .role-record-row {
    gap: 8px;
  }

  .role-sequence,
  .role-boundary-copy {
    grid-template-columns: 1fr;
  }

  .role-sequence > div {
    min-height: 190px;
  }

  .role-record-top {
    display: grid;
    gap: 6px;
  }

  .role-record-top span:last-child {
    text-align: left;
  }

  .role-close-note {
    margin-top: 0;
  }
}

@media (max-width: 380px) {
  .secondary-body .role-hero h1 {
    max-width: none;
    font-size: 38px;
    line-height: .96;
  }
}

@media (prefers-reduced-motion: reduce) {
  .role-source-register::before {
    box-shadow: none;
  }
}
