/* Tabs in Classic Editor — base */
.a53mp-tabs {
	--a53mp-accent: #2271b1;
	--a53mp-border: #c3c4c7;
	--a53mp-bg: #fff;
	--a53mp-nav-bg: #f6f7f7;
	--a53mp-radius: 4px;
	margin: 1.5em 0;
	font-size: inherit;
	line-height: 1.6;
}

.a53mp-tabs__nav {
	display: flex;
	flex-wrap: wrap;
	gap: 0;
	margin: 0;
	padding: 0;
}

.a53mp-tabs__tab {
	appearance: none;
	background: transparent;
	border: none;
	cursor: pointer;
	font: inherit;
	font-weight: 600;
	line-height: 1.3;
	margin: 0;
	padding: 0.65em 1.1em;
	color: inherit;
	transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.a53mp-tabs__tab:focus {
	outline: 2px solid var(--a53mp-accent);
	outline-offset: 2px;
}

.a53mp-tabs__tab:focus:not(:focus-visible) {
	outline: none;
}

.a53mp-tabs__panels {
	background: var(--a53mp-bg);
}

.a53mp-tabs__panel {
	padding: 1.25em 1.35em;
}

.a53mp-tabs__panel[hidden] {
	display: none !important;
}

.a53mp-tabs__panel > :first-child {
	margin-top: 0;
}

.a53mp-tabs__panel > :last-child {
	margin-bottom: 0;
}

/* Classic — bordered tabs connected to panel */
.a53mp-tabs--classic {
	border: 1px solid var(--a53mp-border);
	border-radius: var(--a53mp-radius);
	overflow: hidden;
}

.a53mp-tabs--classic .a53mp-tabs__nav {
	background: var(--a53mp-nav-bg);
	border-bottom: 1px solid var(--a53mp-border);
}

.a53mp-tabs--classic .a53mp-tabs__tab {
	border-right: 1px solid var(--a53mp-border);
	border-bottom: 2px solid transparent;
	margin-bottom: -1px;
}

.a53mp-tabs--classic .a53mp-tabs__tab:last-child {
	border-right: none;
}

.a53mp-tabs--classic .a53mp-tabs__tab.is-active {
	background: var(--a53mp-bg);
	border-bottom-color: var(--a53mp-bg);
	color: var(--a53mp-accent);
}

.a53mp-tabs--classic .a53mp-tabs__tab:not(.is-active):hover {
	background: rgba(255, 255, 255, 0.6);
}

/* Pills — rounded toggles */
.a53mp-tabs--pills .a53mp-tabs__nav {
	gap: 0.35em;
	padding: 0.35em;
	background: var(--a53mp-nav-bg);
	border-radius: 999px;
	width: fit-content;
	max-width: 100%;
}

.a53mp-tabs--pills .a53mp-tabs__tab {
	border-radius: 999px;
	padding: 0.5em 1.15em;
}

.a53mp-tabs--pills .a53mp-tabs__tab.is-active {
	background: var(--a53mp-accent);
	color: #fff;
}

.a53mp-tabs--pills .a53mp-tabs__tab:not(.is-active):hover {
	background: rgba(0, 0, 0, 0.06);
}

.a53mp-tabs--pills .a53mp-tabs__panels {
	margin-top: 0.75em;
	border: 1px solid var(--a53mp-border);
	border-radius: var(--a53mp-radius);
}

/* Underline — minimal text tabs */
.a53mp-tabs--underline .a53mp-tabs__nav {
	border-bottom: 1px solid var(--a53mp-border);
	gap: 0.25em;
}

.a53mp-tabs--underline .a53mp-tabs__tab {
	padding: 0.55em 0.85em;
	font-weight: 500;
	color: #50575e;
	border-bottom: 2px solid transparent;
	margin-bottom: -1px;
	border-radius: 0;
}

.a53mp-tabs--underline .a53mp-tabs__tab.is-active {
	color: var(--a53mp-accent);
	border-bottom-color: var(--a53mp-accent);
}

.a53mp-tabs--underline .a53mp-tabs__tab:not(.is-active):hover {
	color: inherit;
}

.a53mp-tabs--underline .a53mp-tabs__panels {
	padding-top: 0.25em;
}
