@import url(style.css);

:root {
  --bg: #fff; /*var(--*/
  --text: #fff;
  --gray: #4d5974;
  --lightgray: #e5e5e5;
  --blue: #03b5d2;
}

p,
button {
  font-size: 24px;
  font-family: "narkiss-yair-variable", sans-serif;
  font-variation-settings: "MONO" 0, "wght" 400;
  color: #ffffff;
  line-height: normal;
}

h2 {
  font-size: 64px;
  font-family: "narkiss-yair-variable", sans-serif;
  font-variation-settings: "MONO" 0, "wght" 400;
  color: #ffffff;
}

.container {
  margin: auto;
  padding: 4rem;
  width: 50%;
}

.accordion {
  .accordion-item {
    border-bottom: 1px solid var(--lightgray);
    button[aria-expanded="true"] {
      border-bottom: 1px solid var(--blue);
    }
  }
  button {
    position: relative;
    display: block;
    text-align: left;
    width: 100%;
    padding: 16px 0;
    color: var(--text);
    border: none;
    background: none;
    outline: none;
    &:hover,
    &:focus {
      cursor: pointer;
      color: var(--blue);
      &::after {
        cursor: pointer;
        color: var(--blue);
        border: 1px solid var(--blue);
      }
    }

    .icon {
      display: inline-block;
      position: absolute;
      top: 18px;
      right: 0;
      width: 22px;
      height: 22px;
      border: 1px solid;
      border-radius: 22px;
      &::before {
        display: block;
        position: absolute;
        content: "";
        background: currentColor;
      }
      &::after {
        display: block;
        position: absolute;
        content: "";
        top: 5px;
        left: 9px;
        width: 2px;
        height: 10px;
        background: currentColor;
      }
    }
  }
  button[aria-expanded="true"] {
    color: var(--blue);
    .icon {
      &::after {
        width: 0;
      }
    }
    + .accordion-content {
      opacity: 1;
      max-height: 9em;
      transition: all 200ms linear;
      will-change: opacity, max-height;
    }
  }
  .accordion-content {
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: opacity 200ms linear, max-height 200ms linear;
    will-change: opacity, max-height;
  }
}

@media (min-width: 768px) and (max-width: 1200px) {
  h2 {
    font-size: 48px;
  }
  p,
  button {
    font-size: 22px;
  }
}

@media (max-width: 767px) {
  h2 {
    font-size: 32px;
  }
  p,
  button {
    font-size: 16px;
  }

  .container {
    margin: auto;
    padding: 2rem;
    width: 75%;
  }
}
