/* BrilliantMinds PDF Embed - viewer styles */
.bmpdf-wrap { max-width: 100%; box-sizing: border-box; margin-top: 1.5em; margin-bottom: 1.5em; }
.bmpdf-align-left { margin-right: auto; margin-left: 0; }
.bmpdf-align-center { margin-right: auto; margin-left: auto; }
.bmpdf-align-right { margin-right: 0; margin-left: auto; }

.bmpdf-notice { padding: 12px 16px; border-left: 4px solid #d63638; background: #fcf0f1; color: #1d2327; }

.bmpdf-viewer {
	--bmpdf-desk: #e6e8ec;
	--bmpdf-bar: #ffffff;
	--bmpdf-fg: #1b1f27;
	--bmpdf-muted: #667085;
	--bmpdf-line: #d9dce3;
	--bmpdf-hover: rgba(27, 31, 39, 0.07);
	--bmpdf-shadow: 0 10px 30px -12px rgba(16, 24, 40, 0.35);
	position: relative;
	display: flex;
	flex-direction: column;
	box-sizing: border-box;
	width: 100%;
	height: min(var(--bmpdf-height, 720px), 90vh);
	overflow: hidden;
	border: 1px solid var(--bmpdf-line);
	border-radius: var(--bmpdf-radius, 14px);
	background: var(--bmpdf-desk);
	color: var(--bmpdf-fg);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	font-size: 14px;
	line-height: 1.4;
	text-align: left;
}
.bmpdf-viewer *, .bmpdf-viewer *::before, .bmpdf-viewer *::after { box-sizing: border-box; }
.bmpdf-viewer.bmpdf-has-shadow { box-shadow: var(--bmpdf-shadow); }

.bmpdf-viewer.bmpdf-theme-dark {
	--bmpdf-desk: #111318;
	--bmpdf-bar: #1b1e26;
	--bmpdf-fg: #e8eaf0;
	--bmpdf-muted: #9aa1b2;
	--bmpdf-line: #2b2f3a;
	--bmpdf-hover: rgba(255, 255, 255, 0.09);
	--bmpdf-shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.8);
}
@media (prefers-color-scheme: dark) {
	.bmpdf-viewer.bmpdf-theme-auto {
		--bmpdf-desk: #111318;
		--bmpdf-bar: #1b1e26;
		--bmpdf-fg: #e8eaf0;
		--bmpdf-muted: #9aa1b2;
		--bmpdf-line: #2b2f3a;
		--bmpdf-hover: rgba(255, 255, 255, 0.09);
		--bmpdf-shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.8);
	}
}

/* Fallback shown before JavaScript runs (or when it is disabled) */
.bmpdf-fallback { margin: auto; padding: 24px; text-align: center; }
.bmpdf-fallback a { color: var(--bmpdf-accent, #2563eb); font-weight: 600; }
.bmpdf-ready > .bmpdf-fallback { display: none; }

/* Toolbar */
.bmpdf-toolbar {
	display: flex;
	flex: none;
	align-items: center;
	gap: 4px;
	min-height: 52px;
	padding: 8px 10px;
	background: var(--bmpdf-bar);
	border-bottom: 1px solid var(--bmpdf-line);
	z-index: 5;
}
.bmpdf-bottom-bar { flex-direction: column-reverse; }
.bmpdf-bottom-bar .bmpdf-toolbar { border-top: 1px solid var(--bmpdf-line); border-bottom: 0; }

.bmpdf-title {
	flex: 1 1 auto;
	min-width: 0;
	margin: 0 8px 0 4px;
	overflow: hidden;
	font-weight: 600;
	text-overflow: ellipsis;
	white-space: nowrap;
}
.bmpdf-spacer { flex: 1 1 auto; }
.bmpdf-group { display: flex; align-items: center; gap: 2px; }
.bmpdf-sep { width: 1px; height: 22px; margin: 0 6px; background: var(--bmpdf-line); }

.bmpdf-btn {
	display: inline-flex;
	flex: none;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 10px;
	background: transparent;
	color: var(--bmpdf-fg);
	box-shadow: none;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.12s ease;
}
.bmpdf-btn:hover { background: var(--bmpdf-hover); color: var(--bmpdf-fg); }
.bmpdf-btn:active { background: var(--bmpdf-hover); }
.bmpdf-btn[disabled] { opacity: 0.35; cursor: default; background: transparent; }
.bmpdf-btn:focus-visible, .bmpdf-page-input:focus-visible, .bmpdf-viewer:focus-visible {
	outline: 2px solid var(--bmpdf-accent, #2563eb);
	outline-offset: 1px;
}
.bmpdf-btn svg { display: block; width: 20px; height: 20px; }

.bmpdf-pager { display: flex; align-items: center; gap: 6px; padding: 0 4px; color: var(--bmpdf-muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.bmpdf-page-input {
	width: 52px;
	height: 34px;
	margin: 0;
	padding: 0 4px;
	border: 1px solid var(--bmpdf-line);
	border-radius: 9px;
	background: var(--bmpdf-desk);
	color: var(--bmpdf-fg);
	font: inherit;
	font-weight: 600;
	text-align: center;
	box-shadow: none;
	-moz-appearance: textfield;
	appearance: textfield;
}
.bmpdf-page-input::-webkit-outer-spin-button, .bmpdf-page-input::-webkit-inner-spin-button { margin: 0; -webkit-appearance: none; }
.bmpdf-zoom-label { min-width: 46px; color: var(--bmpdf-muted); font-variant-numeric: tabular-nums; text-align: center; }

/* Floating toolbar */
.bmpdf-floating .bmpdf-toolbar {
	position: absolute;
	top: 12px;
	left: 50%;
	max-width: calc(100% - 24px);
	min-height: 0;
	padding: 5px 8px;
	border: 1px solid var(--bmpdf-line);
	border-radius: 999px;
	box-shadow: var(--bmpdf-shadow);
	transform: translateX(-50%);
}
.bmpdf-floating.bmpdf-bottom-bar .bmpdf-toolbar { top: auto; bottom: 12px; border-top: 1px solid var(--bmpdf-line); }
.bmpdf-floating .bmpdf-scroll { padding-top: 76px; }
.bmpdf-floating.bmpdf-bottom-bar .bmpdf-scroll { padding-top: 20px; padding-bottom: 76px; }
.bmpdf-floating .bmpdf-title { max-width: 220px; flex: 0 1 auto; }

/* Document area */
.bmpdf-body { position: relative; flex: 1 1 auto; min-height: 0; }
.bmpdf-scroll { position: absolute; inset: 0; padding: 20px 16px; overflow-x: auto; overflow-y: scroll; -webkit-overflow-scrolling: touch; outline: 0; }
.bmpdf-pages { display: block; }
.bmpdf-page {
	position: relative;
	margin: 0 auto 16px;
	overflow: hidden;
	border-radius: 3px;
	background: #fff;
	box-shadow: 0 1px 2px rgba(16, 24, 40, 0.18), 0 8px 24px -10px rgba(16, 24, 40, 0.35);
}
.bmpdf-page canvas { display: block; width: 100%; height: 100%; }
.bmpdf-single .bmpdf-page { display: none; margin-bottom: 0; }
.bmpdf-single .bmpdf-page.bmpdf-current { display: block; }

.bmpdf-progress { position: absolute; top: 0; left: 0; z-index: 4; width: 0; height: 3px; background: var(--bmpdf-accent, #2563eb); transition: width 0.2s ease; }
.bmpdf-progress.bmpdf-done { opacity: 0; transition: opacity 0.4s ease 0.2s; }

.bmpdf-status { position: absolute; inset: 0; z-index: 3; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 24px; text-align: center; background: var(--bmpdf-desk); }
.bmpdf-status[hidden] { display: none; }
.bmpdf-spinner { width: 30px; height: 30px; border: 3px solid var(--bmpdf-line); border-top-color: var(--bmpdf-accent, #2563eb); border-radius: 50%; animation: bmpdf-spin 0.8s linear infinite; }
@keyframes bmpdf-spin { to { transform: rotate(360deg); } }
.bmpdf-status-title { max-width: 32em; margin: 0; font-size: 16px; font-weight: 600; }
.bmpdf-status-text { margin: 0; color: var(--bmpdf-muted); }
.bmpdf-cta {
	display: inline-flex; align-items: center; gap: 8px;
	margin: 0; padding: 11px 20px;
	border: 0; border-radius: 999px;
	background: var(--bmpdf-accent, #2563eb); color: #fff;
	font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
	box-shadow: none;
}
.bmpdf-cta:hover, .bmpdf-cta:focus { color: #fff; filter: brightness(1.08); }
.bmpdf-cta:focus-visible { outline: 2px solid var(--bmpdf-fg); outline-offset: 2px; }
.bmpdf-poster-badge { padding: 3px 10px; border: 1px solid var(--bmpdf-line); border-radius: 6px; color: var(--bmpdf-muted); font-size: 12px; font-weight: 700; letter-spacing: 0.04em; }

/* Text layer (selectable text) */
.bmpdf-text {
	--total-scale-factor: calc(var(--scale-factor) * var(--user-unit, 1));
	position: absolute; inset: 0; z-index: 1;
	overflow: clip; opacity: 1; line-height: 1;
	text-align: initial; text-size-adjust: none; forced-color-adjust: none;
	transform-origin: 0 0; caret-color: CanvasText;
}
.bmpdf-text :is(span, br) { position: absolute; color: transparent; white-space: pre; cursor: text; transform-origin: 0 0; }
.bmpdf-text ::selection { background: rgba(37, 99, 235, 0.3); }
.bmpdf-text br::selection { background: transparent; }
.bmpdf-text .endOfContent { position: absolute; inset: 100% 0 0; z-index: 0; display: block; cursor: default; user-select: none; }
.bmpdf-no-select .bmpdf-text { display: none; }

/* Fullscreen */
.bmpdf-viewer:fullscreen { width: 100%; height: 100%; max-height: none; border: 0; border-radius: 0; }
.bmpdf-viewer:-webkit-full-screen { width: 100%; height: 100%; max-height: none; border: 0; border-radius: 0; }
.bmpdf-fake-fs { position: fixed !important; inset: 0; z-index: 999999; width: 100% !important; height: 100% !important; max-height: none !important; border: 0; border-radius: 0 !important; }

/* Small containers */
.bmpdf-compact .bmpdf-title, .bmpdf-compact .bmpdf-hide-compact { display: none; }
.bmpdf-compact .bmpdf-toolbar { justify-content: center; flex-wrap: wrap; }
.bmpdf-compact .bmpdf-scroll { padding-right: 8px; padding-left: 8px; }

@media (prefers-reduced-motion: reduce) {
	.bmpdf-btn, .bmpdf-progress { transition: none; }
	.bmpdf-spinner { animation-duration: 2.4s; }
}
@media print {
	.bmpdf-viewer { display: none; }
}
