/* tabs */

.TabsWrapper {
  display: flex;
  flex-grow: 1;
  flex-direction: column;
}

.TabsWrapper-header {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  flex-direction: row;
}

.TabsWrapper-header--withSeparator {
  border-bottom: var(--border);
}

.Tab {
  position: relative;
  display: flex;
  flex-direction: row;
  cursor: pointer;
  min-width: 40px;
  padding: 14px 20px 14px;
  margin-bottom: calc(-1 * var(--spacing-xs));
  text-align: center;
  margin-right: 20px;
}

.Tab:last-child {
  margin-right: 0;
}

.Tab::after {
  position: absolute;
  left: 0;
  bottom: 0;
  content: '';
  width: 100%;
  height: var(--spacing-s);
  background-color: transparent;
  border-top-left-radius: var(--spacing-xs);
  border-top-right-radius: var(--spacing-xs);
}

.Tab:hover::after {
  background-color: var(--inverse-lighter);
}

.Tab:active::after {
  background-color: var(--inverse-light);
}
.Tab--active .Text {
  color: var(--night);
  font-weight: 500;
  align-items: center;
  display: flex;
}
.Tab--active svg path {
  fill: black;
}
.Tab svg {
  margin-right: 8px;
}
.Tab--active::after {
  background-color: #5a05b8;
}
.Tab--active::before {
  border-color: #5a05b8 transparent transparent transparent;
  border-style: solid;
  border-width: 3px 3px 0px 3px;
  content: '';
  display: block;
  left: calc(55% - 10px);
  position: absolute;
  width: 0px;
  top: 48px;
  z-index: 10;
}
.Tab:focus {
  outline: none;
  border-radius: 4px;
  /* Using box shadow instead of border as border shifts the div down which cuts the Icon & Text of label. */
  box-shadow: var(--shadow-spread) var(--primary-shadow);
}

.Tab--active:hover .Tab-selected {
  color: var(--primary-dark);
}

.Tab-selected:hover::after {
  background-color: var(--primary-dark);
}

.Tab:active:focus {
  box-shadow: none;
}

.Tab--disabled {
  cursor: not-allowed;
}

.Tab--disabled:focus {
  box-shadow: none;
}

.Tab--disabled:hover::after {
  background-color: transparent;
}

.Tab-count {
  display: flex;
  margin-right: var(--spacing-l);
}

.Tab-count .Badge {
  margin-left: 0;
  margin-right: 0;
}

.Tab-icon {
  display: flex;
  min-width: inherit;
  justify-content: space-between;
}

.Tabs {
  display: flex;
  box-sizing: border-box;
  flex-direction: row;
}

.Tabs--withSeparator {
  border-bottom: var(--border);
}

.Tab-pills {
  cursor: pointer;
  margin-right: var(--spacing);
}

.Tab-pills--disabled {
  opacity: 60%;
  cursor: not-allowed;
}

.DismissibleTab-icon--right {
  padding: var(--spacing-s);
  margin-left: var(--spacing-s);
  outline: none;
  border-radius: 10px;
}

.DismissibleTab-icon--default:focus-visible {
  outline: var(--spacing-s) solid var(--secondary-shadow);
}

.DismissibleTab-icon--default:hover {
  background-color: var(--secondary);
}

.DismissibleTab-icon--default:active {
  background-color: var(--secondary-dark);
}

.DismissibleTab-icon--selected:focus-visible {
  outline: var(--spacing-s) solid var(--primary-shadow);
}

.DismissibleTab-icon--selected:hover {
  background-color: var(--primary-lighter);
}

.DismissibleTab-icon--selected:active {
  background-color: var(--primary-light);
}
.Tab .Pills {
  margin-left: 8px;
}
.Tab img {
  margin-right: 10px;
}
.Tab span {
  display: flex;
  align-items: center;
}

.tabwithsearch {
  display: flex;
  align-items: center;
  margin-bottom: 1.5rem;
  position: relative;
}
.tabsearchwrap {
  overflow: hidden;
  flex-grow: 1;
  display: flex;
  max-width: 100%;
}
.tabsearchwrap .inputsearch {
  margin-right: 20px;
}
.tabsearchwrapsection {
  display: flex;
  overflow-x: auto;
  scroll-behavior: smooth;
  width: 100%;
}
.tabwithsearchsection {
  overflow-x: auto;
  scroll-behavior: smooth;
  width: 100%;
  display: flex;
}

.tabwithsearchsection .DismissibleTab-icon--right {
  font-size: 16px !important;
}
.tabsearchwrap .arrowwrap {
  padding-top: 5px;
}
.inputsearch .Input--regular {
  height: var(--font-height-l);
}
.tabwithsearchsection .Tab {
  padding: 6px 20px 6px;
}
.tabwithsearchsection .Tab--active::before {
  top: 34px;
}

.tabwithsearchsection .TabsWrapper-content {
  width: 100%;
  position: absolute;
  left: 0;
  top: 100px;
}
.tabwithsearchsection {
  -ms-overflow-style: none; /* IE and Edge */
  scrollbar-width: none; /* Firefox */
}

.tabwithsearchsection .DismissibleTab-icon--default:hover {
  background-color: #fff;
}
.tabwithsearchsection .TabsWrapper-header {
  position: relative;
}
.tabwithsearch {
  position: relative;
}
.tabwithsearchsection .Tab:focus {
  border-radius: 0px;
}

.TabsWrapper-header--sticky {
  position: sticky;
  top: 0;
  z-index: 1; /* Ensure it stays on top of other content */
  background: white; /* To avoid transparency issue when scrolling */
}
