/* EB Result Checker — front end
   Built to read as the official Education Board page, but on a fluid grid so
   it survives a 360px phone. No web fonts, no images, no icon sets.
   Everything is scoped to .ebrc. */

.ebrc.ebrc {
	--ebrc-green: #046a0b;
	--ebrc-green-dark: #024a07;
	--ebrc-green-mid: #3b9e3f;
	--ebrc-green-lite: #8dc63f;
	--ebrc-green-soft: #7cc07f;
	--ebrc-red: #c1272d;
	--ebrc-ink: #1b1b1b;
	--ebrc-ink-2: #5b5b5b;
	--ebrc-line: #b9b9b9;
	--ebrc-line-soft: #dedede;
	--ebrc-field: #f0f0f0;
	--ebrc-shell: #efefef;
	--ebrc-paper: #ffffff;
	--ebrc-radius: 4px;
	--ebrc-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
	--ebrc-sans: Verdana, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
		"Noto Sans Bengali", "Hind Siliguri", Kalpurush, SolaimanLipi, Arial, sans-serif;

	box-sizing: border-box;
	max-width: 980px;
	margin: 1.75rem auto;
	padding: 10px;
	background: var(--ebrc-paper);
	border: 1px solid var(--ebrc-line-soft);
	border-radius: var(--ebrc-radius);
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.07);
	font-family: var(--ebrc-sans);
	font-size: 15px;
	line-height: 1.5;
	color: var(--ebrc-ink);
	-webkit-text-size-adjust: 100%;
}

.ebrc.ebrc *,
.ebrc.ebrc *::before,
.ebrc.ebrc *::after {
	box-sizing: inherit;
}

.ebrc.ebrc [hidden] {
	display: none !important;
}

/* Themes reach inside plugin output more often than you would hope. Kadence,
   for one, ships `.single-content p { margin-bottom }`, which outranked a plain
   `.ebrc-mast__name { margin: 0 }` and pushed the masthead apart. Every rule in
   this file is scoped `.ebrc.ebrc` for that reason; this block clears the
   inherited typography and spacing before the components build on top. */
.ebrc.ebrc p,
.ebrc.ebrc h2,
.ebrc.ebrc h3,
.ebrc.ebrc h4,
.ebrc.ebrc ul,
.ebrc.ebrc ol,
.ebrc.ebrc table,
.ebrc.ebrc figure {
	margin: 0;
	padding: 0;
	text-indent: 0;
}

.ebrc.ebrc p,
.ebrc.ebrc h2,
.ebrc.ebrc h3,
.ebrc.ebrc h4,
.ebrc.ebrc div,
.ebrc.ebrc span,
.ebrc.ebrc small,
.ebrc.ebrc strong,
.ebrc.ebrc b,
.ebrc.ebrc label,
.ebrc.ebrc th,
.ebrc.ebrc td,
.ebrc.ebrc button,
.ebrc.ebrc input,
.ebrc.ebrc select {
	font-family: var(--ebrc-sans);
	letter-spacing: normal;
	text-transform: none;
}

.ebrc.ebrc table,
.ebrc.ebrc th,
.ebrc.ebrc td {
	border: 0;
}

.ebrc.ebrc button {
	width: auto;
	text-shadow: none;
	box-shadow: none;
}

/* ------------------------------------------------------------------ */
/* Masthead                                                            */
/* ------------------------------------------------------------------ */

.ebrc.ebrc .ebrc-mast {
	display: grid;
	grid-template-columns: 215px 1fr;
	align-items: stretch;
}

.ebrc.ebrc .ebrc-mast__crest {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 12px;
	background: var(--ebrc-shell);
}

.ebrc.ebrc .ebrc-mast__crest img {
	display: block;
	width: auto;
	max-width: 100%;
	max-height: 96px;
	height: auto;
}

/* Stand-in until a crest image is set in the settings. */
.ebrc.ebrc .ebrc-crest-blank {
	display: grid;
	place-items: center;
	width: 96px;
	height: 96px;
	padding: 6px;
	border: 2px solid var(--ebrc-green);
	border-radius: 50%;
	font-family: var(--ebrc-mono);
	font-size: 10.5px;
	font-weight: 700;
	letter-spacing: 0.06em;
	color: var(--ebrc-green);
	text-align: center;
	line-height: 1.3;
}

.ebrc.ebrc .ebrc-mast__head {
	position: relative;
	overflow: hidden;
	background: var(--ebrc-green);
}

/* The diagonal weave and the red flash in the corner of the real page. */
.ebrc.ebrc .ebrc-mast__head::before {
	content: "";
	position: absolute;
	top: 0;
	right: 0;
	width: 46%;
	height: 100%;
	background: repeating-linear-gradient(
		115deg,
		rgba(255, 255, 255, 0.14) 0 9px,
		rgba(255, 255, 255, 0) 9px 22px
	);
	pointer-events: none;
}

.ebrc.ebrc .ebrc-mast__head::after {
	content: "";
	position: absolute;
	top: -26px;
	right: 26px;
	width: 34px;
	height: 78px;
	background: var(--ebrc-red);
	border-radius: 0 0 18px 18px;
	transform: rotate(24deg);
	box-shadow: -3px 3px 0 rgba(0, 0, 0, 0.12);
	pointer-events: none;
}

.ebrc.ebrc .ebrc-mast__ministry,
.ebrc.ebrc .ebrc-mast__name {
	position: relative;
	z-index: 1;
	padding: 0 20px;
	margin: 0;
}

.ebrc.ebrc .ebrc-mast__ministry {
	padding-top: 14px;
	font-size: clamp(17px, 3.4vw, 23px);
	font-weight: 700;
	line-height: 1.3;
	color: var(--ebrc-green-lite);
}

.ebrc.ebrc .ebrc-mast__name {
	padding-top: 8px;
	padding-bottom: 14px;
	font-size: clamp(16px, 3.2vw, 22px);
	font-weight: 700;
	line-height: 1.25;
	color: #fff;
}

.ebrc.ebrc .ebrc-mast__tag {
	position: relative;
	z-index: 1;
	margin: 0;
	padding: 4px 20px;
	background: var(--ebrc-green-mid);
	font-size: clamp(11px, 2.2vw, 13.5px);
	color: #eaf6ea;
	text-align: right;
}

@media (max-width: 620px) {
	.ebrc.ebrc .ebrc-mast {
		grid-template-columns: 1fr;
	}
	.ebrc.ebrc .ebrc-mast__crest {
		padding: 10px;
	}
	.ebrc.ebrc .ebrc-mast__crest img {
		max-height: 68px;
	}
	.ebrc.ebrc .ebrc-crest-blank {
		width: 68px;
		height: 68px;
		font-size: 9px;
	}
	.ebrc.ebrc .ebrc-mast__head::after {
		right: 12px;
		width: 26px;
		height: 62px;
	}
	.ebrc.ebrc .ebrc-mast__tag {
		text-align: center;
	}
}

/* ------------------------------------------------------------------ */
/* The bordered box                                                    */
/* ------------------------------------------------------------------ */

.ebrc.ebrc .ebrc-panel {
	max-width: 690px;
	margin: 26px auto;
	padding: clamp(18px, 4vw, 34px) clamp(14px, 4vw, 30px);
	background: var(--ebrc-paper);
	border: 1px solid var(--ebrc-line);
}

@media (max-width: 620px) {
	.ebrc.ebrc .ebrc-panel {
		margin: 16px 0;
	}
}

.ebrc.ebrc .ebrc-grid {
	display: grid;
	grid-template-columns: minmax(96px, 150px) 14px minmax(0, 1fr);
	align-items: center;
	gap: 12px 6px;
}

.ebrc.ebrc .ebrc-grid > label {
	font-size: clamp(13px, 2.8vw, 15px);
	font-weight: 700;
	line-height: 1.3;
}

.ebrc.ebrc .ebrc-colon {
	text-align: center;
	font-weight: 700;
	color: var(--ebrc-ink);
}

@media (max-width: 520px) {
	.ebrc.ebrc .ebrc-grid {
		grid-template-columns: 1fr;
		gap: 4px;
	}
	.ebrc.ebrc .ebrc-grid > label {
		margin-top: 10px;
	}
	.ebrc.ebrc .ebrc-colon {
		display: none;
	}
}

.ebrc.ebrc .ebrc-grid input,
.ebrc.ebrc .ebrc-grid select {
	width: 100%;
	max-width: 320px;
	min-height: 44px;
	padding: 8px 12px;
	font-family: var(--ebrc-sans);
	font-size: 16px; /* stops iOS zooming on focus */
	color: var(--ebrc-ink);
	background: var(--ebrc-field);
	border: 1px solid #c4c4c4;
	border-radius: 3px;
	appearance: none;
}

.ebrc.ebrc .ebrc-grid input {
	font-family: var(--ebrc-mono);
	font-variant-numeric: tabular-nums;
	letter-spacing: 0.02em;
}

.ebrc.ebrc .ebrc-grid input::placeholder {
	color: #9a9a9a;
	letter-spacing: 0;
}

.ebrc.ebrc .ebrc-grid input:focus,
.ebrc.ebrc .ebrc-grid select:focus {
	outline: none;
	border-color: var(--ebrc-green);
	box-shadow: 0 0 0 2px rgba(4, 106, 11, 0.18);
	background: #fff;
}

.ebrc.ebrc .ebrc-grid input:focus-visible,
.ebrc.ebrc .ebrc-grid select:focus-visible,
.ebrc.ebrc button:focus-visible {
	outline: 2px solid var(--ebrc-green);
	outline-offset: 2px;
}

.ebrc.ebrc .ebrc-grid select[disabled],
.ebrc.ebrc .ebrc-grid input[disabled] {
	color: var(--ebrc-ink);
	opacity: 1;
	background: #e7e7e7;
	cursor: default;
}

.ebrc.ebrc .ebrc-sel {
	position: relative;
	max-width: 320px;
}

.ebrc.ebrc .ebrc-sel::after {
	content: "";
	position: absolute;
	right: 13px;
	top: 50%;
	width: 7px;
	height: 7px;
	border-right: 2px solid #6a6a6a;
	border-bottom: 2px solid #6a6a6a;
	transform: translateY(-70%) rotate(45deg);
	pointer-events: none;
}

.ebrc.ebrc .ebrc-sel select {
	padding-right: 32px;
}

/* Fixed exam / year, set as plain text the way a printed form would show it. */
.ebrc.ebrc .ebrc-fixed {
	font-family: var(--ebrc-mono);
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.01em;
}

.ebrc.ebrc .ebrc-buttons {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 10px;
	margin-top: 22px;
}

@media (max-width: 520px) {
	.ebrc.ebrc .ebrc-buttons {
		justify-content: stretch;
	}
	.ebrc.ebrc .ebrc-buttons button {
		flex: 1 1 0;
	}
}

.ebrc.ebrc .ebrc-btn {
	min-height: 44px;
	padding: 10px 24px;
	font-family: inherit;
	font-size: 15px;
	font-weight: 700;
	color: var(--ebrc-ink);
	background: linear-gradient(#fbfbfb, #e9e9e9);
	border: 1px solid #adadad;
	border-radius: 3px;
	cursor: pointer;
}

.ebrc.ebrc .ebrc-btn:hover {
	background: linear-gradient(#fff, #e2e2e2);
}

.ebrc.ebrc .ebrc-btn:active {
	transform: translateY(1px);
}

.ebrc.ebrc .ebrc-btn--go {
	color: #fff;
	background: var(--ebrc-green);
	border-color: var(--ebrc-green-dark);
}

.ebrc.ebrc .ebrc-btn--go:hover {
	background: #05800d;
}

.ebrc.ebrc .ebrc-btn[disabled] {
	cursor: progress;
	opacity: 0.75;
}

.ebrc.ebrc .ebrc-btn--go .ebrc-inner {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
}

.ebrc.ebrc .ebrc-spinner {
	display: none;
	width: 14px;
	height: 14px;
	border: 2px solid rgba(255, 255, 255, 0.4);
	border-top-color: #fff;
	border-radius: 50%;
	animation: ebrc-spin 0.7s linear infinite;
}

.ebrc.ebrc.is-loading .ebrc-spinner {
	display: block;
}

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

.ebrc.ebrc .ebrc-hint {
	grid-column: 1 / -1;
	margin: 6px 0 0;
	padding: 9px 12px;
	font-size: 13.5px;
	color: #8c1a1f;
	background: #fdeced;
	border: 1px solid #f2c4c6;
	border-radius: 3px;
}

/* ------------------------------------------------------------------ */
/* Before publication                                                  */
/* ------------------------------------------------------------------ */

.ebrc.ebrc .ebrc-pending {
	max-width: 690px;
	margin: 26px auto;
	padding: clamp(18px, 4vw, 28px);
	background: #fbfdf9;
	border: 1px solid var(--ebrc-line);
	border-top: 4px solid var(--ebrc-green);
}

.ebrc.ebrc .ebrc-pending__title {
	margin: 0 0 10px;
	font-size: clamp(16px, 3.6vw, 19px);
	font-weight: 700;
	line-height: 1.35;
	color: var(--ebrc-green-dark);
}

.ebrc.ebrc .ebrc-pending__body p {
	margin: 0 0 10px;
	font-size: 14.5px;
	color: #3d3d3d;
}

.ebrc.ebrc .ebrc-pending__body p:last-child {
	margin-bottom: 0;
}

.ebrc.ebrc .ebrc-pending__when {
	margin: 16px 0 0;
	font-size: 13px;
	color: var(--ebrc-ink-2);
}

.ebrc.ebrc .ebrc-countdown {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 8px;
	margin-top: 18px;
}

.ebrc.ebrc .ebrc-tile {
	padding: 10px 4px;
	text-align: center;
	background: #fff;
	border: 1px solid var(--ebrc-line-soft);
	border-radius: 3px;
}

.ebrc.ebrc .ebrc-tile span {
	display: block;
	font-family: var(--ebrc-mono);
	font-size: clamp(19px, 5.5vw, 26px);
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	line-height: 1.1;
	color: var(--ebrc-green-dark);
}

.ebrc.ebrc .ebrc-tile small {
	display: block;
	margin-top: 3px;
	font-size: 10px;
	letter-spacing: 0.09em;
	text-transform: uppercase;
	color: var(--ebrc-ink-2);
}

/* ------------------------------------------------------------------ */
/* Result sheet                                                        */
/* ------------------------------------------------------------------ */

.ebrc.ebrc .ebrc-out:empty {
	display: none;
}

.ebrc.ebrc .ebrc-sheet {
	max-width: 830px;
	margin: 26px auto;
	border: 1px solid var(--ebrc-line-soft);
	background: #fff;
}

@media (max-width: 620px) {
	.ebrc.ebrc .ebrc-sheet,
	.ebrc.ebrc .ebrc-pending {
		margin: 16px 0;
	}
}

.ebrc.ebrc .ebrc-sheet__title {
	padding: 12px 16px;
	background: var(--ebrc-green-soft);
	color: #fff;
	font-size: clamp(15px, 3.4vw, 20px);
	font-weight: 700;
	line-height: 1.3;
	text-align: center;
}

.ebrc.ebrc .ebrc-sheet--fail .ebrc-sheet__title {
	background: var(--ebrc-red);
}

.ebrc.ebrc .ebrc-sheet__body {
	padding: 12px;
}

/* Field grid — same cells, same blanks, as the board's own sheet. */
.ebrc.ebrc .ebrc-facts {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 2px;
}

.ebrc.ebrc .ebrc-fact {
	display: grid;
	grid-template-columns: minmax(84px, 34%) minmax(0, 1fr);
	gap: 2px;
	min-width: 0;
}

.ebrc.ebrc .ebrc-fact.is-wide {
	grid-column: 1 / -1;
	grid-template-columns: minmax(84px, 17%) minmax(0, 1fr);
}

@media (max-width: 620px) {
	.ebrc.ebrc .ebrc-facts {
		grid-template-columns: 1fr;
	}
	.ebrc.ebrc .ebrc-fact.is-wide {
		grid-template-columns: minmax(84px, 34%) minmax(0, 1fr);
	}
}

.ebrc.ebrc .ebrc-fact__k,
.ebrc.ebrc .ebrc-fact__v {
	display: flex;
	align-items: center;
	min-height: 38px;
	padding: 7px 11px;
	font-size: clamp(13px, 2.7vw, 14.5px);
	line-height: 1.4;
	word-break: break-word;
	background: #ececec;
}

.ebrc.ebrc .ebrc-fact__v {
	background: #f5f5f5;
}

.ebrc.ebrc .ebrc-fact[data-k="result"] .ebrc-fact__v,
.ebrc.ebrc .ebrc-fact[data-k="gpa"] .ebrc-fact__v {
	font-weight: 700;
}

.ebrc.ebrc .ebrc-fact[data-k="gpa"] .ebrc-fact__v,
.ebrc.ebrc .ebrc-fact[data-k="roll"] .ebrc-fact__v {
	font-family: var(--ebrc-mono);
	font-variant-numeric: tabular-nums;
}

.ebrc.ebrc .ebrc-gradehead {
	margin: 20px 0 10px;
	font-size: clamp(16px, 3.6vw, 20px);
	font-weight: 700;
	text-align: center;
	color: var(--ebrc-ink);
}

.ebrc.ebrc .ebrc-grades {
	width: 100%;
	border-collapse: separate;
	border-spacing: 2px;
	font-size: clamp(12.5px, 2.7vw, 14px);
}

.ebrc.ebrc .ebrc-grades th {
	padding: 8px 11px;
	background: #b3b8bd;
	color: #16191c;
	font-weight: 700;
	text-align: left;
}

.ebrc.ebrc .ebrc-grades td {
	padding: 8px 11px;
	background: #eeeeee;
	text-align: left;
	vertical-align: middle;
	word-break: break-word;
}

.ebrc.ebrc .ebrc-grades tbody tr:nth-child(even) td {
	background: #dee1e4;
}

.ebrc.ebrc .ebrc-grades th:first-child,
.ebrc.ebrc .ebrc-grades__code {
	width: 16%;
	font-family: var(--ebrc-mono);
	font-variant-numeric: tabular-nums;
}

.ebrc.ebrc .ebrc-grades th:last-child,
.ebrc.ebrc .ebrc-grades__g {
	width: 14%;
	font-family: var(--ebrc-mono);
	font-weight: 700;
}

@media (max-width: 480px) {
	.ebrc.ebrc .ebrc-grades th,
	.ebrc.ebrc .ebrc-grades td {
		padding: 7px 8px;
	}
	.ebrc.ebrc .ebrc-grades th:first-child,
	.ebrc.ebrc .ebrc-grades__code {
		width: 15%;
		font-size: 11.5px;
	}
}

/* Upcoming exam, answered inside the result area. */
.ebrc.ebrc .ebrc-sheet--notice .ebrc-sheet__title {
	background: var(--ebrc-green-mid);
}

.ebrc.ebrc .ebrc-notice__lead {
	margin: 2px 0 0;
	font-size: clamp(15px, 3.4vw, 18px);
	font-weight: 700;
	text-align: center;
	color: var(--ebrc-green-dark);
}

.ebrc.ebrc .ebrc-sheet--notice .ebrc-countdown {
	margin: 16px 0 4px;
}

.ebrc.ebrc .ebrc-notice__text {
	margin-top: 16px;
	padding-top: 14px;
	border-top: 1px solid var(--ebrc-line-soft);
}

.ebrc.ebrc .ebrc-notice__text p {
	margin: 0 0 10px;
	font-size: clamp(13.5px, 2.9vw, 15px);
	line-height: 1.65;
	color: #3d3d3d;
}

.ebrc.ebrc .ebrc-notice__text p:last-child {
	margin-bottom: 0;
}

.ebrc.ebrc .ebrc-sheet__foot {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	padding: 4px 12px 14px;
}

.ebrc.ebrc .ebrc-sheet__foot .ebrc-btn {
	flex: 1 1 auto;
	padding: 11px 18px;
	font-size: 14px;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.ebrc.ebrc .ebrc-stamp {
	margin: 0;
	padding: 0 12px 14px;
	font-family: var(--ebrc-mono);
	font-size: 11px;
	color: #8a8a8a;
}

/* Messages */

.ebrc.ebrc .ebrc-msg {
	max-width: 690px;
	margin: 26px auto;
	padding: clamp(16px, 4vw, 22px);
	background: #fff;
	border: 1px solid var(--ebrc-line);
	border-left: 4px solid var(--ebrc-green-mid);
}

.ebrc.ebrc .ebrc-msg--error {
	border-left-color: var(--ebrc-red);
}

.ebrc.ebrc .ebrc-msg__title {
	margin: 0 0 8px;
	font-size: clamp(15px, 3.4vw, 17px);
	font-weight: 700;
	letter-spacing: 0.03em;
	color: var(--ebrc-red);
}

.ebrc.ebrc .ebrc-gradetag {
	margin-left: 10px;
	padding: 2px 8px;
	background: var(--ebrc-green);
	border-radius: 3px;
	color: #fff;
	font-family: var(--ebrc-sans);
	font-size: 11.5px;
	font-style: normal;
	font-weight: 700;
	letter-spacing: 0.03em;
	white-space: nowrap;
}

.ebrc.ebrc .ebrc-msg__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 16px;
}

.ebrc.ebrc .ebrc-msg__actions .ebrc-btn {
	flex: 1 1 auto;
	margin-top: 0;
}

.ebrc.ebrc .ebrc-msg__stamp {
	margin: 12px 0 0;
	font-size: 12.5px;
	color: #8a8a8a;
}

.ebrc.ebrc .ebrc-checklist {
	margin: 12px 0 0;
	padding: 0 0 0 20px;
	list-style: disc;
}

.ebrc.ebrc .ebrc-checklist li {
	margin: 0 0 8px;
	padding-left: 2px;
	font-size: clamp(13.5px, 2.9vw, 14.5px);
	line-height: 1.6;
	color: #3d3d3d;
}

.ebrc.ebrc .ebrc-checklist li:last-child {
	margin-bottom: 0;
}

.ebrc.ebrc .ebrc-msg p {
	margin: 0;
	font-size: 14.5px;
	color: #3d3d3d;
}

.ebrc.ebrc .ebrc-msg .ebrc-btn {
	margin-top: 14px;
}

@media (max-width: 620px) {
	.ebrc.ebrc .ebrc-msg {
		margin: 16px 0;
	}
}

.ebrc.ebrc .ebrc-raw {
	padding: 4px 16px 14px;
	overflow-x: auto;
}

.ebrc.ebrc .ebrc-raw table {
	width: 100%;
	border-collapse: collapse;
	font-size: 13.5px;
}

.ebrc.ebrc .ebrc-raw td,
.ebrc.ebrc .ebrc-raw th {
	padding: 6px 8px;
	border-bottom: 1px solid #ececec;
	text-align: left;
}

/* Footer rule, echoing the strip at the bottom of the official page. */
.ebrc.ebrc .ebrc-rule {
	height: 5px;
	margin-top: 18px;
	background: var(--ebrc-green-mid);
}

@media (prefers-reduced-motion: reduce) {
	.ebrc.ebrc .ebrc-spinner {
		animation-duration: 2s;
	}
}

/* Off-screen holder for the print copy. */
.ebrc.ebrc.ebrc-printroot {
	display: none;
}

@media print {
	html.ebrc-printing,
	html.ebrc-printing body {
		margin: 0 !important;
		padding: 0 !important;
		background: #fff !important;
	}

	/* Whatever the theme wraps the page in, it is a child of body. */
	html.ebrc-printing body > *:not(.ebrc-printroot) {
		display: none !important;
	}

	html.ebrc-printing .ebrc.ebrc.ebrc-printroot {
		display: block !important;
		max-width: none;
		margin: 0;
		padding: 0;
		border: 0;
		box-shadow: none;
	}

	.ebrc.ebrc .ebrc-panel,
	.ebrc.ebrc .ebrc-pending,
	.ebrc.ebrc .ebrc-sheet__foot,
	.ebrc.ebrc .ebrc-rule {
		display: none !important;
	}

	.ebrc.ebrc .ebrc-sheet {
		max-width: none;
		margin: 0;
		border: 1px solid #999;
		break-inside: auto;
	}

	.ebrc.ebrc .ebrc-grades tr,
	.ebrc.ebrc .ebrc-fact {
		break-inside: avoid;
	}

	/* Keep the fills — an all-white printout of a grey table is unreadable. */
	.ebrc.ebrc .ebrc-sheet__title,
	.ebrc.ebrc .ebrc-fact__k,
	.ebrc.ebrc .ebrc-fact__v,
	.ebrc.ebrc .ebrc-grades th,
	.ebrc.ebrc .ebrc-grades td,
	.ebrc.ebrc .ebrc-mast__head,
	.ebrc.ebrc .ebrc-mast__tag,
	.ebrc.ebrc .ebrc-mast__crest {
		-webkit-print-color-adjust: exact;
		print-color-adjust: exact;
	}

	/* Tighten up so a full grade sheet lands on one sheet of A4. */
	.ebrc.ebrc .ebrc-mast__ministry {
		padding-top: 8px;
		font-size: 14pt;
	}

	.ebrc.ebrc .ebrc-mast__name {
		padding-bottom: 8px;
		font-size: 12.5pt;
	}

	.ebrc.ebrc .ebrc-sheet__title {
		padding: 8px 12px;
		font-size: 13.5pt;
	}

	.ebrc.ebrc .ebrc-sheet__body {
		padding: 8px;
	}

	.ebrc.ebrc .ebrc-fact__k,
	.ebrc.ebrc .ebrc-fact__v {
		min-height: 0;
		padding: 5px 8px;
		font-size: 10.5pt;
	}

	.ebrc.ebrc .ebrc-gradehead {
		margin: 12px 0 6px;
		font-size: 12.5pt;
	}

	.ebrc.ebrc .ebrc-grades th,
	.ebrc.ebrc .ebrc-grades td {
		padding: 4px 8px;
		font-size: 10pt;
	}

	@page {
		margin: 12mm;
	}
}
