/* --- SCSS Variables --- */
/* These are the default WordPress Breakpoints */
/* Custom Breakpoints */
.wp-block-details {
  font-family: var(--wp--preset--font-family--avantgarde);
  font-size: var(--wp--preset--font-size--caption-large);
  border-top: solid 1px var(--wp--preset--color--contrast);
  margin: 0 !important;
}
.wp-block-details:first-of-type {
  margin-top: 1.25rem !important;
}
.wp-block-details:last-of-type {
  border-bottom: solid 1px var(--wp--preset--color--contrast);
}
.wp-block-details[open] {
  animation: open_details 0.5s ease-in-out;
  overflow: hidden;
}
.wp-block-details summary {
  font-size: var(--wp--preset--font-size--caption-xlarge);
  display: flex;
  padding: 1.25rem 2rem 1.25rem 0;
  position: relative;
  font-weight: 700;
}
.wp-block-details summary::-webkit-details-marker {
  display: none;
}
.wp-block-details summary::after {
  content: url('data:image/svg+xml,<svg width="8" height="14" viewBox="0 0 8 14" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M1.42188 12.625L6.57812 7L1.42188 1.375" stroke="black" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>');
  position: absolute;
  right: 10px;
  transform: rotate(90deg);
  transition: transform 0.125s ease-out;
}
.wp-block-details summary:hover::before {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  left: 0;
  background: url(../../images/HTGF-Mastergradient.webp) no-repeat;
  background-size: 100% 100%;
  mix-blend-mode: lighten;
  z-index: 1;
  pointer-events: none;
}
.wp-block-details[open] summary::after {
  transform: rotate(-90deg) translate(4px, 4px);
}
.wp-block-details p,
.wp-block-details ul,
.wp-block-details ol {
  font-size: var(--htgf--preset--font-size--caption-large);
  text-align: left;
  color: var(--wp--preset--color--contrast--opacity--60);
  margin-top: 0;
}
.wp-block-details p:last-child,
.wp-block-details ul:last-child,
.wp-block-details ol:last-child {
  margin-bottom: 2.5rem;
}
.wp-block-details ul,
.wp-block-details ol {
  list-style-type: none;
  padding-left: 0;
}
.wp-block-details ul:not(:first-child),
.wp-block-details ol:not(:first-child) {
  margin-top: 2.5rem;
}
.wp-block-details ul li,
.wp-block-details ol li {
  position: relative;
  padding-left: 0.625rem;
  margin-bottom: 0.5rem;
}
.wp-block-details ul li::before,
.wp-block-details ol li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.05rem;
  height: 1rem;
  width: 3px;
  background: var(--htgf--preset--color--grey);
}

@keyframes open_details {
  from {
    max-height: 3rem;
  }
  to {
    max-height: 100rem;
  }
}
/* ---
   Special cases
*/
.wp-block-details.is-style-timeline {
  --story-left-padding: 2rem;
  --story-right-padding: 5rem;
  border: none;
  padding-left: var(--story-left-padding);
  padding-right: var(--story-right-padding);
  position: relative;
}
.wp-block-details.is-style-timeline::after {
  content: "";
  position: absolute;
  right: 1.35rem;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--wp--preset--color--contrast);
  z-index: 1;
}
.wp-block-details.is-style-timeline:first-of-type::after {
  background: linear-gradient(180deg, transparent 2rem, var(--wp--preset--color--contrast) 2rem);
}
.wp-block-details.is-style-timeline:last-of-type::after {
  background: linear-gradient(0deg, transparent 2rem, var(--wp--preset--color--contrast) 2rem);
}
.wp-block-details.is-style-timeline summary::after {
  right: auto;
  left: calc((var(--story-left-padding) - 0.4rem) * -1);
}
.wp-block-details.is-style-timeline .mark--year {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--htgf--preset--font-size--caption-small);
  line-height: 1;
  padding: 0.4rem 0.5rem 0.2rem;
  border: solid 1px var(--wp--preset--color--contrast);
  background-color: var(--wp--preset--color--base);
  border-radius: 99999px;
  position: absolute;
  right: calc(var(--story-right-padding) * -1);
  z-index: 2;
  font-weight: 500;
}
.wp-block-details.is-style-timeline summary:hover .mark--year {
  font-weight: 500;
  background-image: url(../../images/HTGF-Mastergradient-40.webp);
  background-size: cover;
}
.wp-block-details.is-style-timeline[open] summary {
  font-weight: 400;
}
.wp-block-details.is-style-timeline[open] summary .mark--year, .wp-block-details.is-style-timeline[open] summary:hover .mark--year {
  font-weight: 500;
  background-image: none;
  color: var(--wp--preset--color--base);
  background-color: var(--wp--preset--color--contrast);
}

/* ---
   Changes for the WP admin area.
*/
.wp-admin .wp-block-details summary:hover::before {
  content: none;
}
