/**
 * Busca Reglamentos front-end styles.
 *
 * Visual system mirrors https://www.ozzmx.com/isoptic-horizontal/
 * All component rules are scoped to .br-app so the WordPress theme keeps
 * control of the rest of the page.
 */

/* Hide the theme page title only on pages that render the shortcode. */
body.br-has-app .wp-block-post-title,
body.br-has-app .entry-title,
body.br-has-app .page-title,
body.br-has-app .post-title,
body.br-has-app .wp-block-query-title,
body.br-has-app .entry-header h1,
body:has(.br-app) .wp-block-post-title,
body:has(.br-app) .entry-title,
body:has(.br-app) .page-title,
body:has(.br-app) .post-title,
body:has(.br-app) .wp-block-query-title,
body:has(.br-app) .entry-header h1 {
	display: none !important;
}

.br-app {
	--br-gold: #b07c01;
	--br-gold-2: #eba501;
	--br-yellow: #ffd800;
	--br-ink: #010101;
	--br-accent: #de1414;
	--br-slate: #41474c;
	--br-muted: #6f8099;
	--br-bg: #f9fafb;
	--br-input-bg: #fafbfd;
	--br-line: rgba(206, 206, 206, 0.85);
	--br-line-soft: rgba(206, 206, 206, 0.45);
	--br-tab-head: #ccd8b8;
	--br-ok: #1d7a3e;
	--br-warn: #8a5a00;
	--br-danger: #a11717;

	--br-serif: "Lora", Georgia, "Times New Roman", serif;
	--br-sans: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	--br-mono: "DM Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

	--br-r: 3px;
	--br-shadow: 0 10px 30px -18px rgba(1, 1, 1, 0.35);

	box-sizing: border-box;
	max-width: 1180px;
	margin-inline: auto;
	font-family: var(--br-sans);
	font-size: 15px;
	line-height: 1.55;
	color: var(--br-ink);
	-webkit-text-size-adjust: 100%;
}

/*
 * Block themes constrain direct children of .is-layout-constrained to the
 * global content size (645px in Twenty Twenty-Five). That rule has the same
 * specificity as .br-app, so it wins on source order. Doubling the class keeps
 * the reference width without touching the theme's layout rules.
 */
.br-app.br-app {
	max-width: 1180px;
}

.br-app *,
.br-app *::before,
.br-app *::after {
	box-sizing: border-box;
}

.br-app h2,
.br-app h3,
.br-app h4 {
	font-family: var(--br-sans);
	color: var(--br-ink);
	line-height: 1.2;
	margin: 0 0 0.5rem;
}

.br-app p {
	margin: 0 0 0.75rem;
}

.br-app a {
	color: var(--br-gold);
}

/* ------------------------------------------------------------------ hero */

.br-hero {
	margin: 0 0 16px;
}

.br-hero__title {
	font-family: var(--br-serif);
	font-size: clamp(1.55rem, 3.2vw, 2rem);
	font-weight: 600;
	line-height: 1.15;
	letter-spacing: 0.01em;
	margin: 0 0 0.35rem;
}

.br-hero__subtitle {
	color: var(--br-muted);
	font-size: 0.9rem;
	max-width: 62ch;
	margin: 0;
}

/* ------------------------------------------------------------- disclaimer */

.br-disclaimer {
	background: #fffaf0;
	border: 1px solid #f0d9ae;
	border-left: 3px solid var(--br-gold-2);
	border-radius: var(--br-r);
	padding: 10px 14px;
	margin: 0 0 16px;
	color: #5a4300;
	font-size: 0.82rem;
	line-height: 1.5;
}

.br-disclaimer strong {
	display: block;
	color: #4a3000;
	margin-bottom: 2px;
}

.br-disclaimer p {
	margin: 0;
}

/* ------------------------------------------------------------------ form */

.br-form {
	background: #fff;
	border: 1px solid var(--br-line);
	border-radius: var(--br-r);
	box-shadow: var(--br-shadow);
	padding: 18px 20px 20px;
}

.br-fieldset {
	border: 0;
	border-top: 1px solid var(--br-line-soft);
	margin: 0 0 16px;
	padding: 14px 0 0;
	min-width: 0;
}

.br-fieldset:first-of-type {
	border-top: 0;
	padding-top: 0;
}

.br-fieldset legend {
	display: block;
	font-family: var(--br-mono);
	font-size: 0.68rem;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--br-muted);
	padding: 0 0 10px;
}

.br-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 10px;
}

.br-field {
	min-width: 0;
	border: 1px solid var(--br-line);
	border-radius: var(--br-r);
	background: #fff;
	padding: 8px 10px 9px;
	transition: border-color 0.15s, box-shadow 0.15s;
}

.br-field:focus-within {
	border-color: var(--br-gold);
	box-shadow: 0 0 0 3px rgba(176, 124, 1, 0.12);
}

.br-field--full {
	grid-column: 1 / -1;
}

.br-field label {
	display: flex;
	align-items: baseline;
	gap: 6px;
	font-family: var(--br-sans);
	font-size: 0.74rem;
	font-weight: 500;
	color: #4a4a4a;
	margin-bottom: 5px;
	cursor: pointer;
}

.br-optional {
	font-weight: 400;
	color: var(--br-muted);
	font-size: 0.68rem;
	margin-left: 2px;
}

.br-app input[type="number"],
.br-app input[type="text"],
.br-app input[type="password"],
.br-app select,
.br-app textarea {
	width: 100%;
	max-width: 100%;
	border: 1px solid #d9d9d9;
	border-radius: 2px;
	background: var(--br-input-bg);
	color: var(--br-ink);
	font-family: var(--br-sans);
	font-size: 0.88rem;
	line-height: 1.35;
	padding: 6px 8px;
	transition: border-color 0.15s, box-shadow 0.15s;
}

.br-app input[type="number"] {
	font-family: var(--br-mono);
	font-size: 0.86rem;
	text-align: right;
}

.br-app textarea {
	resize: vertical;
	min-height: 5rem;
}

.br-app select {
	min-height: 2.15rem;
}

.br-app input:focus,
.br-app select:focus,
.br-app textarea:focus {
	outline: none;
	border-color: var(--br-gold);
	box-shadow: 0 0 0 2px rgba(176, 124, 1, 0.12);
}

.br-app .br-invalid {
	border-color: var(--br-danger) !important;
	box-shadow: 0 0 0 2px rgba(161, 23, 23, 0.12) !important;
}

.br-help {
	color: var(--br-muted);
	font-size: 0.7rem;
	margin: 4px 0 0;
	line-height: 1.4;
}

.br-preliminary {
	display: inline-block;
	margin: 6px 0 0;
	padding: 3px 8px;
	background: #fff8e1;
	border: 1px solid #f0d9ae;
	border-radius: 2px;
	color: #6d4700;
	font-family: var(--br-mono);
	font-size: 0.7rem;
	line-height: 1.4;
}

.br-assumption {
	margin: 10px 0 0;
	padding: 6px 0 6px 10px;
	border-left: 3px solid var(--br-gold-2);
	color: var(--br-muted);
	font-size: 0.72rem;
	line-height: 1.45;
}

.br-form__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 16px;
	padding-top: 14px;
	border-top: 1px solid var(--br-line-soft);
}

/* ---------------------------------------------------------------- buttons */

.br-btn {
	appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 7px;
	border: 1px solid transparent;
	border-radius: 0;
	background: var(--br-yellow);
	color: var(--br-ink);
	font-family: var(--br-sans);
	font-size: 0.82rem;
	font-weight: 500;
	line-height: 1.2;
	padding: 9px 22px;
	cursor: pointer;
	text-decoration: none;
	transition: transform 0.12s, background 0.15s, border-color 0.15s, color 0.15s;
}

.br-btn:hover {
	background: var(--br-gold-2);
	color: var(--br-ink);
}

.br-btn:active {
	transform: scale(0.985);
}

.br-btn:focus-visible {
	outline: 2px solid var(--br-ink);
	outline-offset: 2px;
}

.br-btn:disabled {
	opacity: 0.45;
	cursor: not-allowed;
	pointer-events: none;
}

.br-btn--primary {
	background: var(--br-yellow);
	color: var(--br-ink);
}

.br-btn--ghost {
	background: #fff;
	border-color: var(--br-line);
	color: #333;
}

.br-btn--ghost:hover {
	background: #f3f3f3;
	border-color: #b9b9b9;
	color: #333;
}

.br-form__status {
	margin: 10px 0 0;
	color: var(--br-gold);
	font-family: var(--br-mono);
	font-size: 0.72rem;
}

.br-form__error {
	margin: 10px 0 0;
	padding: 7px 10px;
	border-radius: var(--br-r);
	background: #fff5f5;
	border: 1px solid #f2c3c3;
	color: #8e1414;
	font-size: 0.8rem;
	line-height: 1.45;
}

.br-debug {
	display: block;
	margin-top: 4px;
	font-family: var(--br-mono);
	font-size: 0.66rem;
	font-weight: 400;
	color: var(--br-muted);
	letter-spacing: 0.01em;
	word-break: break-all;
}

/* ---------------------------------------------------------------- loading */

.br-loading {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-top: 14px;
	padding: 10px 14px;
	background: #fff;
	border: 1px solid var(--br-line);
	border-radius: var(--br-r);
	box-shadow: var(--br-shadow);
}

.br-loading[hidden] {
	display: none;
}

.br-loading p {
	margin: 0;
	color: var(--br-muted);
	font-size: 0.78rem;
}

.br-spinner {
	width: 26px;
	height: 26px;
	flex: 0 0 auto;
	border: 2px solid var(--br-line);
	border-top-color: var(--br-gold);
	border-radius: 50%;
	animation: br-spin 0.85s linear infinite;
}

@keyframes br-spin {
	to {
		transform: rotate(360deg);
	}
}

/* ---------------------------------------------------------------- results */

.br-results-slot:empty {
	display: none;
}

.br-results {
	padding-top: 14px;
}

.br-results:focus {
	outline: none;
}

.br-results__head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	justify-content: space-between;
	gap: 10px 24px;
	margin: 0 0 14px;
}

.br-results__title {
	font-family: var(--br-serif);
	font-size: clamp(1.35rem, 2.5vw, 1.75rem);
	font-weight: 600;
	margin: 0 0 0.2rem;
}

.br-results__for {
	margin: 0;
	font-weight: 500;
	color: var(--br-slate);
}

.br-results__meta {
	margin: 0.2rem 0 0;
	color: var(--br-muted);
	font-family: var(--br-mono);
	font-size: 0.68rem;
}

.br-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.br-actions .br-btn {
	padding: 7px 14px;
	font-size: 0.76rem;
}

/* ---------------------------------------------------------------- banners */

.br-banner {
	padding: 8px 12px;
	border-radius: var(--br-r);
	font-size: 0.78rem;
	line-height: 1.45;
	margin: 0 0 10px;
	border: 1px solid;
}

.br-banner--demo {
	background: #eef2ff;
	border-color: #c7d2fe;
	color: #3730a3;
}

.br-banner--warning {
	background: #fffaf0;
	border-color: #f0d9ae;
	color: #6d4700;
}

.br-banner--info {
	background: #f6f9fc;
	border-color: #d8e2ec;
	color: #3b556e;
}

/* ------------------------------------------------------------------ cards */

.br-card {
	background: #fff;
	border: 1px solid var(--br-line);
	border-radius: var(--br-r);
	box-shadow: var(--br-shadow);
	padding: 14px 18px;
	margin: 0 0 12px;
}

.br-card h3 {
	font-size: 1.02rem;
	font-weight: 600;
	margin: 0 0 10px;
	padding-bottom: 8px;
	border-bottom: 1px solid var(--br-line-soft);
}

.br-card h4 {
	font-family: var(--br-mono);
	font-size: 0.7rem;
	font-weight: 500;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--br-gold);
	margin: 12px 0 6px;
}

.br-card--summary {
	border-left: 3px solid var(--br-gold);
}

.br-card--ada {
	border-left: 3px solid var(--br-gold-2);
}

.br-card--warnings {
	border-left: 3px solid var(--br-accent);
}

.br-note {
	color: var(--br-muted);
	font-size: 0.72rem;
	line-height: 1.5;
	margin: 0 0 8px;
}

.br-muted {
	color: var(--br-muted);
	font-style: italic;
}

.br-subgroup {
	margin-top: 2px;
}

/* ------------------------------------------------------------------ items */

.br-item {
	padding: 8px 0;
	border-bottom: 1px solid var(--br-line-soft);
}

.br-item:last-child {
	border-bottom: 0;
	padding-bottom: 2px;
}

.br-item__head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 4px 8px;
	margin-bottom: 2px;
}

.br-item__label {
	font-weight: 600;
	font-size: 0.84rem;
	color: var(--br-ink);
}

.br-item__value {
	font-family: var(--br-mono);
	font-size: 0.95rem;
	font-weight: 500;
	color: var(--br-ink);
	margin: 2px 0 3px;
}

.br-item__unit {
	font-family: var(--br-sans);
	font-size: 0.74rem;
	font-weight: 400;
	color: var(--br-muted);
	margin-left: 3px;
}

.br-item__row {
	font-size: 0.74rem;
	color: var(--br-slate);
}

.br-item__key {
	color: var(--br-muted);
	font-weight: 500;
}

.br-item__notes {
	font-size: 0.74rem;
	color: var(--br-slate);
	margin: 4px 0 0;
	line-height: 1.45;
}

.br-item__foot {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin-top: 4px;
}

/* Keep the status badge after the reference links, at the item's right edge. */
.br-item__foot > .br-citation-refs {
	margin-left: auto;
}

.br-item__foot > .br-badge {
	margin-left: auto;
}

.br-item__foot > .br-citation-refs + .br-badge {
	margin-left: 6px;
}

.br-confidence {
	color: var(--br-muted);
	font-family: var(--br-mono);
	font-size: 0.64rem;
}

.br-item--not_found .br-item__value {
	color: var(--br-muted);
	font-weight: 400;
	font-style: italic;
}

/* ------------------------------------------------ egress item grid */
/*
 * Mirrors the ADA calculator tiles: white cells separated by 1px hairlines,
 * gold labels. Columns follow the card width (1, 2, or 3 per row) instead of
 * the viewport, so the grid adapts inside narrow theme layouts too.
 */

.br-card--egress {
	container: br-egress / inline-size;
}

.br-egress-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 0;
	background: #fff;
	border-top: 1px solid var(--br-line);
	border-left: 1px solid var(--br-line);
	border-radius: var(--br-r);
	overflow: hidden;
	margin-top: 10px;
}

@container br-egress (min-width: 600px) {
	.br-egress-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@container br-egress (min-width: 880px) {
	.br-egress-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@supports not (container-type: inline-size) {
	@media (min-width: 720px) {
		.br-egress-grid {
			grid-template-columns: repeat(2, minmax(0, 1fr));
		}
	}

	@media (min-width: 1020px) {
		.br-egress-grid {
			grid-template-columns: repeat(3, minmax(0, 1fr));
		}
	}
}

.br-egress-grid > .br-item {
	display: flex;
	flex-direction: column;
	background: #fff;
	padding: 10px 12px 9px;
	border-right: 1px solid var(--br-line);
	border-bottom: 1px solid var(--br-line);
}

.br-egress-grid > .br-item:last-child {
	padding-bottom: 9px;
}

.br-egress-grid > .br-item .br-item__label {
	color: var(--br-gold);
}

.br-egress-grid > .br-item .br-item__foot {
	margin-top: auto;
	padding-top: 8px;
}

.br-egress-grid .br-egress-grid__title {
	grid-column: 1 / -1;
	margin: 0;
	padding: 8px 12px 6px;
	background: var(--br-bg);
	border-right: 1px solid var(--br-line);
	border-bottom: 1px solid var(--br-line);
}

/* ----------------------------------------------------------------- badges */

.br-badge {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 999px;
	font-family: var(--br-sans);
	font-size: 0.62rem;
	font-weight: 600;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	white-space: nowrap;
	border: 1px solid transparent;
}

.br-badge--required {
	background: #fdeaea;
	color: var(--br-danger);
	border-color: #f2c3c3;
}

.br-badge--recommended,
.br-badge--verified {
	background: #e7f6ec;
	color: var(--br-ok);
	border-color: #bfe5cb;
}

.br-badge--reference,
.br-badge--deterministic {
	background: #eef2ff;
	color: #3730a3;
	border-color: #c7d2fe;
}

.br-badge--not_found {
	background: #f1f4f6;
	color: var(--br-muted);
	border-color: var(--br-line);
}

.br-badge--varies,
.br-badge--unverified {
	background: #fdf3e2;
	color: var(--br-warn);
	border-color: #f0d9ae;
}

.br-badge--registry {
	background: rgba(176, 124, 1, 0.1);
	color: var(--br-gold);
	border-color: rgba(176, 124, 1, 0.28);
}

/* --------------------------------------------------------- citation refs */

.br-citation-refs {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 4px;
}

.br-ref {
	display: inline-block;
	font-family: var(--br-mono);
	font-size: 0.66rem;
	font-weight: 500;
	color: var(--br-gold);
	text-decoration: none;
	padding: 1px 4px;
	border-radius: 2px;
	background: rgba(176, 124, 1, 0.1);
}

.br-ref:hover {
	background: rgba(176, 124, 1, 0.18);
	color: var(--br-gold);
}

.br-citation.is-flash {
	animation: br-citation-flash 1.7s ease-out;
}

@keyframes br-citation-flash {
	0% {
		background: rgba(255, 216, 0, 0);
		box-shadow: 0 0 0 0 rgba(176, 124, 1, 0);
	}
	18% {
		background: rgba(255, 216, 0, 0.32);
		box-shadow: 0 0 0 5px rgba(176, 124, 1, 0.18);
	}
	100% {
		background: rgba(255, 216, 0, 0);
		box-shadow: 0 0 0 0 rgba(176, 124, 1, 0);
	}
}

/* ------------------------------------------------------------- ADA card */

.br-ada-details {
	border: 0;
}

.br-ada-details__summary {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 6px 10px;
	cursor: pointer;
	list-style: none;
	padding: 0;
}

.br-ada-details__summary::-webkit-details-marker {
	display: none;
}

.br-ada-details__summary::marker {
	content: "";
}

.br-ada-details__summary:focus-visible {
	outline: 2px solid var(--br-gold);
	outline-offset: 2px;
}

.br-ada-details__title {
	flex: 1 1 auto;
	font-family: var(--br-sans);
	font-size: 1.02rem;
	font-weight: 600;
	color: var(--br-ink);
}

.br-ada-details__meta {
	font-family: var(--br-mono);
	font-size: 0.68rem;
	color: var(--br-muted);
	white-space: nowrap;
}

.br-ada-details__chev {
	width: 8px;
	height: 8px;
	flex: 0 0 auto;
	margin-left: 2px;
	border-right: 1.5px solid var(--br-gold);
	border-bottom: 1.5px solid var(--br-gold);
	transform: rotate(45deg);
	transition: transform 0.15s;
}

.br-ada-details[open] .br-ada-details__chev {
	transform: rotate(225deg);
}

.br-ada-details__body {
	padding-top: 10px;
}

.br-ada-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	gap: 1px;
	background: var(--br-line);
	border: 1px solid var(--br-line);
	border-radius: var(--br-r);
	overflow: hidden;
	margin: 8px 0 10px;
}

.br-ada-tile {
	display: flex;
	flex-direction: column;
	gap: 2px;
	background: #fff;
	padding: 8px 11px 7px;
}

.br-ada-tile__label {
	font-family: var(--br-mono);
	font-size: 0.64rem;
	font-weight: 500;
	color: var(--br-gold);
	letter-spacing: 0.02em;
}

.br-ada-tile__value {
	font-family: var(--br-mono);
	font-size: 0.9rem;
	color: var(--br-ink);
	line-height: 1.3;
}

.br-ada-tile__unit {
	font-size: 0.66rem;
	color: var(--br-muted);
}

.br-ada-tile__note {
	font-size: 0.62rem;
	color: var(--br-muted);
	line-height: 1.35;
}

.br-ada-notes {
	margin: 6px 0 8px;
	padding-left: 1.1rem;
	color: var(--br-slate);
	font-size: 0.74rem;
	line-height: 1.45;
}

.br-ada-notes li {
	margin-bottom: 3px;
}

.br-ada-outside-note {
	margin: 10px 0 0;
	padding: 7px 10px;
	border-left: 3px solid var(--br-gold-2);
	border-radius: 2px;
	background: #fffaf0;
	color: #6d4700;
	font-size: 0.74rem;
	line-height: 1.45;
}

/* --------------------------------------------------------------- warnings */

.br-warning-list {
	margin: 0;
	padding-left: 1.1rem;
	color: var(--br-slate);
	font-size: 0.78rem;
	line-height: 1.45;
}

.br-warning-list li {
	margin-bottom: 4px;
}

/* -------------------------------------------------------------- citations */

.br-citation-list {
	margin: 0;
	padding-left: 1.3rem;
}

.br-citation {
	margin-bottom: 12px;
	padding-left: 2px;
}

.br-citation:last-child {
	margin-bottom: 0;
}

.br-citation__head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	margin-bottom: 2px;
}

.br-citation__title {
	font-weight: 600;
	font-size: 0.84rem;
	color: var(--br-ink);
}

.br-citation__meta {
	font-size: 0.72rem;
	color: var(--br-muted);
}

.br-citation__quote {
	margin: 5px 0;
	padding: 6px 10px;
	border-left: 3px solid var(--br-gold-2);
	background: var(--br-bg);
	color: var(--br-slate);
	font-size: 0.74rem;
	font-style: italic;
	line-height: 1.45;
}

.br-citation__foot {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: center;
	font-size: 0.7rem;
}

.br-citation__lang {
	color: var(--br-muted);
}

.br-citation__link {
	font-weight: 500;
	color: var(--br-gold);
}

/* ----------------------------------------------------------------- footer */

.br-results__footer {
	margin-top: 14px;
}

.br-disclaimer--footer {
	margin-top: 14px;
}

.br-generated {
	margin-top: 8px;
	color: var(--br-muted);
	font-family: var(--br-mono);
	font-size: 0.66rem;
}

.br-form__footer {
	margin-top: 18px;
	text-align: center;
	color: var(--br-muted);
	font-size: 0.72rem;
}

.br-form__footer p {
	margin: 2px 0;
}

/* ------------------------------------------------- floating egress button */

.br-back-egress {
	position: fixed;
	right: 22px;
	bottom: 22px;
	z-index: 9999;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 10px 16px;
	border: 1px solid var(--br-ink);
	border-radius: 999px;
	background: var(--br-yellow);
	color: var(--br-ink);
	font-family: var(--br-sans);
	font-size: 0.78rem;
	font-weight: 600;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 10px 30px -12px rgba(1, 1, 1, 0.55);
	opacity: 0;
	transform: translateY(10px);
	transition: opacity 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

.br-back-egress[hidden] {
	display: none;
}

.br-back-egress.is-on {
	opacity: 1;
	transform: translateY(0);
}

.br-back-egress:hover {
	background: var(--br-gold-2);
}

.br-back-egress:focus-visible {
	outline: 2px solid var(--br-ink);
	outline-offset: 3px;
}

.br-back-egress__arrow {
	font-size: 1rem;
	line-height: 1;
}

/* --------------------------------------------------------------- tooltips */

.br-app [data-tip] {
	cursor: help;
}

[data-tip]:focus-visible {
	outline: none;
}

.br-tip {
	/* The tip lives on <body>, outside .br-app, so it carries its own tokens. */
	--br-tip-bg: #1e1e1e;
	--br-tip-border: #333;
	--br-tip-text: #f0f0f0;
	--br-mono: "DM Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

	position: fixed;
	z-index: 99998;
	top: 0;
	left: 0;
	max-width: min(260px, calc(100vw - 16px));
	padding: 6px 11px;
	border-radius: 12px;
	background: var(--br-tip-bg);
	color: var(--br-tip-text);
	border: 1px solid var(--br-tip-border);
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
	font-family: var(--br-mono);
	font-size: 0.7rem;
	font-weight: 400;
	line-height: 1.45;
	text-align: left;
	pointer-events: none;
	opacity: 0;
	transform: translateY(3px);
	transition: opacity 0.14s ease, transform 0.14s ease;
}

.br-tip.is-on {
	opacity: 1;
	transform: translateY(0);
}

.br-tip::after {
	content: "";
	position: absolute;
	left: var(--br-tip-arrow, 50%);
	bottom: -6px;
	margin-left: -6px;
	border-left: 6px solid transparent;
	border-right: 6px solid transparent;
	border-top: 6px solid var(--br-tip-border);
}

.br-tip.is-below::after {
	bottom: auto;
	top: -6px;
	border-top: 0;
	border-bottom: 6px solid var(--br-tip-border);
}

/* ------------------------------------------------------------- responsive */

@media (max-width: 900px) {
	.br-grid {
		grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
	}
}

@media (max-width: 720px) {
	.br-app {
		font-size: 14px;
	}

	.br-form {
		padding: 14px;
	}

	.br-grid {
		grid-template-columns: 1fr;
	}

	.br-results__head {
		flex-direction: column;
	}

	.br-actions {
		width: 100%;
	}

	.br-actions .br-btn {
		flex: 1 1 calc(50% - 4px);
	}

	.br-ada-grid {
		grid-template-columns: 1fr 1fr;
	}
}

@media (max-width: 460px) {
	.br-ada-grid {
		grid-template-columns: 1fr;
	}

	.br-actions .br-btn {
		flex-basis: 100%;
	}

	.br-back-egress {
		right: 12px;
		bottom: 12px;
		padding: 9px 13px;
		font-size: 0.72rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	.br-app *,
	.br-app *::before,
	.br-app *::after {
		transition-duration: 0.01ms !important;
		animation-duration: 0.01ms !important;
	}

	.br-spinner {
		animation-duration: 2.4s !important;
	}
}

/* ------------------------------------------------------------------ print */

@media print {
	.br-app.br-app {
		max-width: none;
	}

	.br-app {
		padding: 0;
		color: #000;
	}

	.br-form,
	.br-loading,
	.br-actions,
	.br-back-egress,
	.br-form__footer,
	.br-preliminary,
	.br-assumption,
	.br-tip {
		display: none !important;
	}

	.br-ada-details:not([open]) > .br-ada-details__body {
		display: block !important;
	}

	.br-ada-details__chev {
		display: none;
	}

	.br-card,
	.br-disclaimer {
		box-shadow: none;
		break-inside: avoid;
		page-break-inside: avoid;
	}

	.br-card {
		border: 1px solid #999;
	}

	.br-item__value {
		color: #000;
	}

	.br-egress-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.br-egress-grid > .br-item {
		border: 1px solid #ddd;
	}

	.br-ref {
		background: none;
		color: #000;
	}
}
