@use 'pix-design-tokens/breakpoints';
@use 'pix-design-tokens/fonts';
@use 'pix-design-tokens/typography';

.rounded-panel {
  margin-bottom: 30px;
  background-color: var(--pix-neutral-0);
  border-radius: 10px;
  box-shadow: 0 2px 5px 0 rgb(0 0 0 / 5%);

  &--strong {
    padding-bottom: 30px;
    border-radius: 10px;
    box-shadow: 0 50px 54px -40px rgb(0 0 0 / 40%), 0 7px 14px 0 rgb(12 22 58 / 10%);
  }

  &--over-background-banner {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin-top: -205px;

    @include breakpoints.device-is('tablet') {
      max-width: 980px;
    }
  }

  &--no-margin-bottom {
    margin-bottom: 0;
  }

  &__row {
    padding: 16px;
    border-radius: 8px;
  }
}

.rounded-panel hr {
  margin-right: -20px;
  margin-left: -20px;
}

.rounded-panel-one-line-header {
  margin-bottom: 16px;
  text-align: center;

  @include breakpoints.device-is('tablet') {
    margin: 0 14px 30px;
    text-align: left;
  }
}

.rounded-panel-header-with-components {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  width: 100%;

  @include breakpoints.device-is('tablet') {
    flex-direction: row;
    height: 205px;
    border-bottom: 1px dashed var(--pix-neutral-100);
  }
}

.rounded-panel-header {
  &__left-wrapper {
    margin-left: 8px;
  }

  &__right-wrapper {
    display: flex;
    justify-content: center;
    margin: 10px 0;

    @include breakpoints.device-is('tablet') {
      margin: 0 30px 0 0;
    }
  }
}

.rounded-panel-body {
  display: flex;
  flex-direction: column;
  margin: 4px 0;

  &__areas {
    display: flex;
    flex-direction: column;
    align-items: center;

    @include breakpoints.device-is('tablet') {
      flex-direction: row;
      overflow: auto;
    }
  }

  &__competence-card {
    width: 100%;
    margin: 12px 10px;

    @include breakpoints.device-is('tablet') {
      width: auto;
      margin: 16px 10px;
    }

    &:first-child,
    &:nth-child(4) {
      margin: 16px 8px;
    }
  }

  @include breakpoints.device-is('tablet') {
    width: auto;
  }
}

.rounded-panel-header-text {
  &__content {
    margin: 10px 0;
  }

  &__content--first-title {
    @extend %pix-title-l;

    color: var(--pix-neutral-900);
    line-height: 2.75rem;
    letter-spacing: 0.009rem;

    @include breakpoints.device-is('tablet') {
      font-size: 2rem;
      line-height: 3.375rem;
    }
  }
}

// Text styles
.rounded-panel-title {
  text-align: center;

  @include breakpoints.device-is('tablet') {
    display: block;
    text-align: left;
  }

  &--all-small-caps {
    font-variant-caps: all-small-caps;
  }
}
