:host {
  display: block;
  margin: 2rem auto 0.5rem auto;
  width: 100%;
  max-width: 70rem;
}

.myfairy-container {
  display: grid;
  max-width: 100%;
  grid-template-columns: 1fr 2fr;
  gap: 1rem;
}


.trait-selection {
  position: sticky;
  top: 1rem;
  align-self: start;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  align-items: flex-start;

  &--list {
    display: grid;
    gap: 0.5rem;
    grid-template-columns: 1fr 1fr;
  }
}

.plan-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 0;
  background-color: var(--background-color);
  border-radius: 0.5rem;
  margin-bottom: 1rem;

  span {
    font-weight: bold;
    color: var(--text-color);
  }
}

.plan-steps {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, 1fr);
}

.step {
  border: 1px solid var(--text-color);
  border-radius: 0.5rem;
  padding: 1rem;

  &--content {
    display: grid;
    grid-template-columns: 5fr 4fr;
    gap: 1rem;
  }

  &--traits {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;

    > * {
      text-wrap: nowrap;
    }
  }

  &--header {
    font-size: 1rem;
    font-weight: bold;
    margin: 0;
    margin-bottom: 1rem;
    display: flex;
    gap: 1rem;
    align-items: center;

    h3 {
      font-size: 1rem;
      margin: 0;
    }
  }

  &--skills {
    ul {
      list-style: none;
      padding: 0;
      padding-left: 1rem;
      margin: 0;
    }
  }

  &--change {
    margin: 0;
    border-left: 1px solid var(--text-color);
    padding-left: 1rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-around;

    .arrow {
      transform: rotate(90deg);
    }

    > div {
       text-wrap: nowrap
    }
  }
}

@media (max-width: 1350px) {
  .myfairy-container {
    grid-template-columns: 1fr;
  }

  .trait-selection {
    position: static;
    align-self: center;
  }

  .trait-selection--list {
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
  }

  .plan-steps {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 950px) {
  .trait-selection--list {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
  }
  .plan-steps {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 550px) {
  .step--content {
    grid-template-columns: 1fr;
  }

  .step--change {
    border: none;
    border-top: 1px solid var(--text-color);
    padding-top: 0.5rem;
    flex-direction: row;

    .arrow {
      transform: rotate(0deg);
    }
  }
}
