.cobalt- {
  &TabBar {
    position: relative;

    width: 100%;
    display: flex;
  }

  &TabBar__ScrollControl {
    flex: 0 0 theme("spacing.lg");
    display: flex;
  }

  &TabBar__ScrollButton {
    position: relative;

    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    width: 100%;

    border: 0;
    margin: 0;

    vertical-align: middle;
    text-decoration: none;

    background-color: transparent;
    cursor: pointer;
    outline: none;
    border-radius: 0;
    appearance: none;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
  }

  &TabScroller {
    flex: 1 1 auto;
    overflow-y: hidden;
  }

  &TabScroller--underlined:after {
    position: absolute;

    bottom: 0;

    width: 100%;
    height: 1px;

    background: theme("colors.outline");

    content: "";
  }

  &TabScroller__ScrollArea {
    position: relative;

    display: flex;
    overflow-x: scroll;
    overflow-y: hidden;
    height: 100%;
    flex: 1 0 auto;
    box-sizing: content-box;

    -webkit-overflow-scrolling: touch;

    &::-webkit-scrollbar {
      display: none;
    }
  }

  &TabScroller__ScrollArea--leftAlign {
    justify-content: flex-start;

    .cobalt-Tab {
      flex-grow: 0;
    }
  }

  &Tab {
    @apply c-text-section-heading c-bg-surfaceBright c-state-interactive c-transition-interactive;

    position: relative;
    z-index: theme("zIndex.above");

    display: flex;
    flex: 1 0 auto;
    justify-content: center;
    height: calc(17 * theme("spacing.2xs"));
    padding: 0 theme("spacing.md");

    box-sizing: border-box;
    border: 0;

    text-align: center;
    text-decoration: none;
    white-space: nowrap;
    font-size: 16px;
    line-height: 1;

    outline: none;
    cursor: pointer;

    appearance: none;

    &:after {
      position: absolute;
      bottom: 0;
      left: 0;
      right: 0;

      display: block;
      height: 3px;

      content: "";

      background: transparent;

      transform: scaleX(0);
      transition: transform ease-out 0.15s;
    }

    &:hover,
    &:focus {
      text-decoration: inherit;
    }

    &[aria-selected="true"] {
      @apply c-text-onSurface;

      &:after {
        @apply c-bg-primary;

        transform: scaleX(1);
      }
    }
  }

  &Tab--inCard {
    text-transform: none;

    &:after {
      display: none;
    }
  }

  &Tab__Content {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;
    height: inherit;
    pointer-events: none;
  }
}
