.@{tab-prefix-cls} {
	&-card&-left,
	&-card&-right {
		.@{tab-prefix-cls}-tab {
			border-color: transparent;

			.@{tab-prefix-cls}-tab-btn {
				&::before {
					top: 0;
					bottom: 0;
					width: 2px;
					height: initial;
				}

				// Separator gutter
				&::after {
					top: initial;
					left: 0;
					right: 0;
					bottom: 0;
					width: initial;
					height: 1px;
				}
			}
		}

		.@{tab-prefix-cls}-tab-active {
			border-color: @primary-color;
		}
	}

	&-card&-left {
		.@{tab-prefix-cls}-tab {
			border-right-color: @primary-color;

			&::before,
			&::after {
				left: initial;
				right: -1px;
			}

			&::before {
				--circle-pos: top left;
				top: calc(var(--border-radius) * -1);
			}

			&::after {
				--circle-pos: bottom left;
				bottom: calc(var(--border-radius) * -1);
			}

			.@{tab-prefix-cls}-tab-btn {
				&::before {
					left: 0;
					border-top-left-radius: @tab-border-radius;
					border-bottom-left-radius: @tab-border-radius;
				}

				&::after {
					border-bottom-left-radius: @tab-border-radius;
				}
			}
		}

		.@{tab-prefix-cls}-tab-active {
			border-right-color: @component-background;
		}
	}

	&-card&-right {
		.@{tab-prefix-cls}-tab {
			border-left-color: @primary-color;

			&::before,
			&::after {
				right: initial;
				left: -1px;
			}

			&::before {
				--circle-pos: top right;
				top: calc(var(--border-radius) * -1);
			}

			&::after {
				--circle-pos: bottom right;
				bottom: calc(var(--border-radius) * -1);
			}

			.@{tab-prefix-cls}-tab-btn {
				&::before {
					right: 0;
					border-top-right-radius: @tab-border-radius;
					border-bottom-right-radius: @tab-border-radius;
				}

				&::after {
					border-bottom-right-radius: @tab-border-radius;
				}
			}
		}

		.@{tab-prefix-cls}-tab-active {
			// border-color: @primary-color @primary-color @primary-color @component-background;
			border-left-color: @component-background;
		}
	}
}
