@use '@vizality' as vz;

.vz-settings-category {
  $base: &;
  margin-bottom: 16px;
  padding: 0;
  border-radius: 8px;
  flex-direction: column;
  overflow: hidden;
  /**
   * Targetting any elements after a category that aren't another category.
   */
  & + :not(.vz-settings-category) {
    margin-top: 20px;
  }
  &-meta {
    flex: 1;
    margin: 0;
  }
  &-icon-wrapper {
    @include vz.size(32px);
    margin-right: 16px;
    flex: 0 auto;
    padding: 4px;
  }
  &-icon {
    @include vz.size(100%);
  }
  &-title-wrapper {
    display: flex;
    flex: 1;
    align-items: center;
    width: 100%;
    padding: 16px 24px 16px 16px;
    box-sizing: border-box;
    border-radius: 8px;
    cursor: pointer;
    background-color: var(--background-secondary);
    transition: background .2s;
    &:hover {
      background-color: var(--background-secondary-alt);
    }
  }
  &-title-icon-wrapper {
    transition: transform 0.2s;
  }
  &[vz-expanded] {
    #{$base}-title-wrapper {
      background: var(--background-secondary-alt);
      color: var(--interactive-hover);
      border-radius: 8px 8px 0 0;
    }
    #{$base}-title-icon-wrapper {
      transform: rotate3d(0, 0, 1, 90deg);
    }
  }
  &-contents {
    padding: 20px;
  }
  &-inner {
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
    background: var(--background-secondary);
    > div:last-of-type {
      margin-bottom: 0;
      .divider-3573oO {
        display: none;
      }
    }
  }
}
