
/* Container details block */
details {
  margin-bottom: 1rem;
  position:relative;
}

/* Header style when the accordion is closed/default */
details summary {
  display: flex;
  align-items: center;
  background-color: transparent;
  color: var(--theme--text-color); /* Default text color */
  padding: 1rem;
  font-weight: bold;
  cursor: pointer;
  list-style: none; /* Removes default arrow in modern browsers */
  transition: all 0.3s ease;
  border-radius: var(--theme--border-radius);
}

/* Removes default arrow in Safari */
details summary::-webkit-details-marker {
  display: none;
}

/* Pseudo-element for the "+" icon when closed */
details summary::before {
  content: "\f078";
  font-family: "Font Awesome 5 Pro";
  right: 0;
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  margin-right: 15px;
  font-size: 15px;
  font-weight: normal;
  color:#fff;
  background-color: var(--theme--primary-color);
  flex-shrink: 0;
  transition: all 0.3s ease;
}
details summary::after {
     content: "";
     position: absolute;
     bottom: 2px;
     width: 100%;
     height: 2px;
     left: 0;
     background-color: #eaeaea;
}

/* Header style changes dynamically when the accordion is OPEN */
details[open] summary {
  background-color: var(--theme--primary-color);
  color: #ffffff; 
  border-bottom: none;
  transition: all 0.5s ease;
}

/* Pseudo-element changes to a "-" icon when OPEN */
details[open] summary::before {

  transform:rotateX(180deg);
  border: none;
  transition: all 0.3s ease;
}

/* Content area styling when open */
details > div,
details > p,
details > ul{
  line-height: 1.6;
  margin: 0 2rem;

}

details > :not(summary):first-of-type {
  padding-top: 2rem;
}

details > :last-child {
  padding-bottom: 2rem;
}

details > ul li {
  margin-bottom: 8px;
}