.ww-education-layout {
  align-items: flex-start;
}

.ww-toc-column {
  width: 100%;
  min-width: 0;
}

.ww-education-toc {
  font-size: 0.875rem;
}

.ww-education-toc summary {
  font-size: 0.8rem;
  font-weight: 700;
  color: #405c65;
  text-transform: uppercase;
  letter-spacing: 0.035em;
  cursor: pointer;
}

.ww-education-toc-list {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
}

.ww-education-toc-list a {
  display: block;
  padding: 0.45rem 0.65rem;
  border-left: 3px solid transparent;
  border-radius: 0 4px 4px 0;
  color: #53656b;
  line-height: 1.4;
  text-decoration: none;
}

.ww-education-toc-list a:hover,
.ww-education-toc-list a:focus-visible {
  color: #0284c7;
  background: #f0f9ff;
}

.ww-education-toc-list a.is-active {
  color: #0284c7;
  background: #e0f2fe;
  border-left-color: #0284c7;
  font-weight: 600;
}

.ww-education-layout .field--name-body :is(h2, h3) {
  scroll-margin-top: 6rem;
}

@media (min-width: 1200px) {
  .ww-education-layout > .ww-toc-column {
    flex: 0 0 20%;
    width: 20%;
  }

  .ww-education-layout > .region-content {
    flex: 0 0 60%;
    width: 60%;
    min-width: 0;
  }

  .ww-education-layout > .region-sidebar-second {
    flex: 0 0 20%;
    width: 20%;
    min-width: 0;
  }

  .ww-education-layout > .ww-toc-column {
    position: sticky;
    top: 84px;
    align-self: flex-start;
    max-height: calc(100vh - 114px);
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .ww-education-toc summary {
    list-style: none;
    cursor: default;
  }

  .ww-education-toc summary::-webkit-details-marker {
    display: none;
  }
}

@media (max-width: 1199px) {
  .ww-education-layout > .ww-toc-column {
    order: -1;
  }

  .ww-education-toc {
    padding: 0.75rem;
    margin-bottom: 1.25rem;
    border: 1px solid #dce5e8;
    border-radius: 6px;
  }
}

/* Education TOC heading hierarchy */

.ww-education-toc-list .ww-toc-section > a {
  font-weight: 600;
}

.ww-education-toc-list .ww-toc-subsection > a {
  padding-left: 1.4rem;
  font-size: 0.825rem;
  font-weight: 400;
}

.ww-education-toc-list .ww-toc-subsection > a.is-active {
  font-weight: 600;
}


/* Refined Education TOC typography */
.ww-education-toc-list a,
.ww-education-toc-list .ww-toc-section > a,
.ww-education-toc-list .ww-toc-subsection > a,
.ww-education-toc-list a.is-active,
.ww-education-toc-list .ww-toc-subsection > a.is-active {
  font-weight: 400;
}

.ww-education-toc-list a:not(.is-active) {
  color: #68777d;
}


/* TOC finishing touches */

.ww-education-toc-list a {
  padding-top: 0.55rem;
  padding-bottom: 0.55rem;
}

.ww-toc-back-to-top {
  display: block;
  margin-top: 0.8rem;
  padding: 0.85rem 0.65rem 0.35rem;
  border-top: 1px solid #e1e7ea;
  color: #68777d;
  font-size: 0.825rem;
  font-weight: 400;
  text-decoration: none;
}

.ww-toc-back-to-top:hover,
.ww-toc-back-to-top:focus-visible {
  color: #0284c7;
  text-decoration: underline;
}
