/**
 * TutorBridgePro unified page-width system.
 *
 * This file is intentionally loaded last. Page-specific styles may control
 * their internal reading measure, but the visible page boundary must remain
 * identical across public pages and authenticated workspaces.
 */

:root {
	--tbp-page-edge: 1rem;
	--tbp-page-frame: calc(100% - (var(--tbp-page-edge) * 2));
	--tbp-reading-measure: 48rem;
}

/* One shared outer boundary for headers, pages and footers. */
.tbp-container,
.site-header__inner,
.announcement-bar__inner,
.site-footer__inner,
.site-footer__main,
.site-footer__bottom {
	width: var(--tbp-page-frame) !important;
	max-width: none !important;
	margin-inline: auto !important;
}

/* Authenticated product areas use the same boundary as public pages. */
.tbp-container.tbp-workspace__shell,
.tbp-programme-shell,
.tbp-gpb-workspace,
.tbp-verification-page > .tbp-container,
.tbp-verification-page .tbp-verification-hero > .tbp-container {
	width: var(--tbp-page-frame) !important;
	max-width: none !important;
	margin-inline: auto !important;
}

/* Prevent full-width shells from producing accidental horizontal scrolling. */
.tbp-workspace,
.tbp-programme-centre,
.tbp-gpb-page,
.tbp-verification-page,
.site-main {
	min-width: 0;
	overflow-x: clip;
}

/* Preserve a comfortable line length inside wide legal/editorial pages. */
:where(
	.tbp-legal-copy,
	.tbp-legal-content,
	.tbp-policy-copy,
	.tbp-article-content,
	.tbp-reading-width
) {
	max-width: var(--tbp-reading-measure);
}

@media (max-width: 760px) {
	:root {
		--tbp-page-edge: .75rem;
	}
}

