/*
 * Patient portal. Mobile-first, single column, calm and large.
 * Sizes in rem so the layout holds at 200% zoom. Targets are at least 44px (2.75rem).
 * One orange primary action per screen; status chips pair colour with icon and text.
 * The primary button uses --accent-2 so white text keeps AA contrast at body size.
 */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
}

body {
	margin: 0;
	background: var(--canvas);
	color: var(--text);
	font-family: var(--font-body);
	font-size: 1rem;
	line-height: 1.55;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}

[hidden] {
	display: none !important;
}

.sprite {
	position: absolute;
	width: 0;
	height: 0;
	overflow: hidden;
}

.icon {
	width: 1.25em;
	height: 1.25em;
	flex: none;
	vertical-align: -0.2em;
}

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.mono {
	white-space: nowrap;
	font-family: var(--font-mono);
	font-variant-numeric: tabular-nums;
	letter-spacing: 0;
}

a {
	color: var(--navy-3);
	text-underline-offset: 0.15em;
}

/* Phone numbers sit inside sentences; vertical padding gives them a 44px touch target without moving the text. */
a[href^="tel:"]:not(.btn) {
	display: inline-block;
	padding: 0.75rem 0;
	margin: -0.75rem 0;
}

:focus-visible {
	outline: 3px solid var(--focus);
	outline-offset: 2px;
	border-radius: 4px;
}

.skip {
	position: absolute;
	left: 0.75rem;
	top: -4rem;
	z-index: 10;
	background: var(--panel);
	color: var(--navy);
	padding: 0.75rem 1rem;
	border-radius: var(--r-sm);
	font-weight: 500;
}

.skip:focus {
	top: 0.75rem;
}

/* ---------- header ---------- */
.top {
	background: var(--navy);
	color: #fff;
}

.top-inner,
.tabs,
.foot-inner {
	max-width: 42rem;
	margin: 0 auto;
	padding: 0 1rem;
}

.top-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem 1rem;
	padding-top: 0.75rem;
	padding-bottom: 0.5rem;
}

.brand {
	color: #fff;
	text-decoration: none;
	display: flex;
	flex-direction: column;
	line-height: 1.25;
	min-height: 2.75rem;
	justify-content: center;
}

.brand-name {
	font-family: var(--font-display);
	font-weight: 500;
	font-size: 1.125rem;
}

.brand-sub {
	font-size: 0.9375rem;
	color: #c9d3e3;
}

.top-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem;
}

.lang {
	display: flex;
	border: 1px solid var(--navy-3);
	border-radius: var(--r-pill);
	overflow: hidden;
}

.lang a {
	color: #fff;
	text-decoration: none;
	min-width: 2.75rem;
	min-height: 2.75rem;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0 0.75rem;
	font-weight: 500;
	font-size: 0.9375rem;
}

.lang a[aria-current="true"] {
	background: #fff;
	color: var(--navy);
}

.top-btn {
	font: inherit;
	font-size: 0.9375rem;
	color: #fff;
	background: transparent;
	border: 1px solid var(--navy-3);
	border-radius: var(--r-pill);
	min-height: 2.75rem;
	padding: 0 0.875rem;
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	cursor: pointer;
}

.top-btn:hover {
	background: var(--navy-2);
}

/* Tabs wrap instead of scrolling sideways so every section stays visible on narrow screens and at 200% zoom. */
.tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 0 0.25rem;
}

.top :focus-visible {
	outline-color: #fff;
}

.tabs a {
	color: #dfe6f1;
	text-decoration: none;
	white-space: nowrap;
	min-height: 2.75rem;
	display: inline-flex;
	align-items: center;
	padding: 0 0.75rem;
	border-bottom: 3px solid transparent;
	font-size: 1rem;
}

.tabs a[aria-current="page"] {
	color: #fff;
	border-bottom-color: var(--accent);
	font-weight: 500;
}

/* ---------- page ---------- */
main {
	flex: 1;
	outline: none;
}

.page {
	max-width: 42rem;
	margin: 0 auto;
	padding: 1.25rem 1rem 3rem;
}

h1,
h2,
h3 {
	font-family: var(--font-display);
	color: var(--navy);
	line-height: 1.25;
	margin: 0 0 0.75rem;
}

h1 {
	font-size: 1.375rem;
	font-weight: 500;
}

h2 {
	font-size: 1.125rem;
	font-weight: 500;
}

h3 {
	font-size: 1.125rem;
	font-weight: 500;
}

h1:focus,
h2:focus {
	outline: none;
}

h1:focus-visible,
h2:focus-visible {
	outline: 3px solid var(--focus);
}

p {
	margin: 0 0 1rem;
}

.lead {
	color: var(--text-2);
}

.muted {
	color: var(--text-2);
}

.small {
	font-size: 1rem;
}

.loading {
	color: var(--text-2);
}

.loading::after {
	content: "";
	display: inline-block;
	width: 1em;
	height: 1em;
	margin-left: 0.5em;
	vertical-align: -0.15em;
	border: 2px solid var(--line-2);
	border-top-color: var(--navy-3);
	border-radius: 50%;
	animation: spin 900ms linear infinite;
}

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

@media (prefers-reduced-motion: reduce) {
	.loading::after {
		animation: none;
	}
}

/* ---------- surfaces ---------- */
.card {
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--r-md);
	padding: 1.125rem;
	margin: 0 0 1rem;
	box-shadow: var(--shadow-1);
}

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

.notice {
	display: flex;
	gap: 0.75rem;
	align-items: flex-start;
	border-radius: var(--r-md);
	padding: 1rem;
	margin: 0 0 1rem;
	border: 1px solid var(--line-2);
	background: var(--panel);
}

.notice > .icon {
	margin-top: 0.15rem;
}

.notice p {
	margin: 0 0 0.5rem;
}

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

.notice.urgent {
	background: var(--st-red-bg);
	border-color: #f0c2c4;
	color: var(--st-red-fg);
}

.notice.urgent strong {
	color: #7d1f1d;
}

.notice.urgent a {
	color: #7d1f1d;
	font-weight: 500;
}

.notice.info {
	background: var(--st-blue-bg);
	border-color: #c6ddf6;
	color: #174a78;
}

.notice.warn {
	background: var(--st-amber-bg);
	border-color: #eedba8;
	color: #6b4600;
}

.notice.ok {
	background: var(--st-green-bg);
	border-color: #bfe0c9;
	color: #1f5535;
}

.notice.error {
	background: var(--st-red-bg);
	border-color: #f0c2c4;
	color: #7d1f1d;
}

/* ---------- home ---------- */
.menu {
	list-style: none;
	margin: 0 0 1.25rem;
	padding: 0;
	display: grid;
	gap: 0.75rem;
}

.menu a {
	display: flex;
	align-items: center;
	gap: 0.875rem;
	min-height: 3.5rem;
	padding: 0.875rem 1rem;
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--r-md);
	color: var(--navy);
	font-weight: 500;
	text-decoration: none;
	box-shadow: var(--shadow-1);
}

.menu a:hover {
	border-color: var(--line-2);
	background: #fbfcfe;
}

.menu a .icon {
	color: var(--navy-3);
	width: 1.5rem;
	height: 1.5rem;
}

.menu a .go {
	margin-left: auto;
	color: var(--text-3);
}

/* ---------- buttons ---------- */
.btn {
	max-width: 100%;
	text-align: center;
	font: inherit;
	font-weight: 500;
	font-size: 1.0625rem;
	min-height: 3rem;
	padding: 0.625rem 1.25rem;
	border-radius: var(--r-md);
	border: 1px solid var(--line-2);
	background: var(--panel);
	color: var(--navy);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	cursor: pointer;
	text-decoration: none;
	transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}

.btn:hover {
	background: #f1f4f9;
}

.btn.primary {
	background: var(--accent-2);
	border-color: var(--accent-2);
	color: #fff;
}

.btn.primary:hover {
	background: #9a4708;
	border-color: #9a4708;
}

.btn.link {
	background: transparent;
	border-color: transparent;
	color: var(--navy-3);
	text-decoration: underline;
	padding-left: 0.5rem;
	padding-right: 0.5rem;
}

.btn.danger {
	color: var(--st-red-fg);
	border-color: #e7b3b5;
}

.btn.danger:hover {
	background: var(--st-red-bg);
}

.btn[disabled],
.btn[aria-disabled="true"] {
	opacity: 0.55;
	cursor: not-allowed;
}

.btn.block {
	width: 100%;
}

.actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	align-items: center;
	margin-top: 1.25rem;
}

.actions.split {
	justify-content: space-between;
}

.actions .btn.primary {
	flex: 1 1 12rem;
}

/* ---------- steps ---------- */
.stepper {
	margin: 0 0 1rem;
}

.stepper p {
	margin: 0 0 0.375rem;
	font-size: 0.9375rem;
	color: var(--text-2);
}

.progress {
	height: 0.375rem;
	background: var(--line);
	border-radius: var(--r-pill);
	overflow: hidden;
}

.progress span {
	display: block;
	height: 100%;
	background: var(--navy-3);
	border-radius: var(--r-pill);
	transition: width var(--t-med) var(--ease);
}

/* ---------- choice cards (radio) ---------- */
.choices {
	border: 0;
	margin: 0;
	padding: 0;
	min-width: 0;
	display: grid;
	gap: 0.75rem;
}

.choices legend {
	padding: 0;
	margin-bottom: 0.75rem;
}

.choice {
	position: relative;
	display: block;
	background: var(--panel);
	border: 2px solid var(--line);
	border-radius: var(--r-md);
	padding: 0.875rem 1rem 0.875rem 3.25rem;
	cursor: pointer;
	min-height: 3.5rem;
}

.choice:hover {
	border-color: var(--line-2);
}

.choice input {
	position: absolute;
	left: 1rem;
	top: 1.05rem;
	width: 1.375rem;
	height: 1.375rem;
	margin: 0;
	accent-color: var(--navy);
}

.choice:has(input:checked) {
	border-color: var(--navy);
	background: #f7f9fd;
}

.choice:has(input:focus-visible) {
	outline: 3px solid var(--focus);
	outline-offset: 2px;
}

.choice-title {
	display: block;
	font-weight: 500;
	color: var(--navy);
}

.choice-text {
	display: block;
	color: var(--text-2);
	font-size: 1rem;
	margin-top: 0.25rem;
}

.choice-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 0.375rem 0.75rem;
	margin-top: 0.5rem;
	font-size: 0.9375rem;
	color: var(--text-2);
}

.choice details {
	margin-top: 0.5rem;
	font-size: 1rem;
}

.choice summary {
	cursor: pointer;
	color: var(--navy-3);
	min-height: 2.75rem;
	display: flex;
	align-items: center;
}

/* ---------- chips ---------- */
.chip {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	border-radius: var(--r-pill);
	padding: 0.2rem 0.7rem;
	font-size: 0.9375rem;
	font-weight: 500;
	line-height: 1.4;
	background: var(--st-grey-bg);
	color: var(--st-grey-fg);
	white-space: nowrap;
}

.chip .icon {
	width: 1rem;
	height: 1rem;
	vertical-align: 0;
}

.chip.blue {
	background: var(--st-blue-bg);
	color: var(--st-blue-fg);
}

.chip.green {
	background: var(--st-green-bg);
	color: var(--st-green-fg);
}

.chip.amber {
	background: var(--st-amber-bg);
	color: var(--st-amber-fg);
}

.chip.red {
	background: var(--st-red-bg);
	color: var(--st-red-fg);
}

.chip.violet {
	background: var(--st-violet-bg);
	color: var(--st-violet-fg);
}

/* ---------- form fields ---------- */
.field {
	margin: 0 0 1.125rem;
}

.field label,
.field .label {
	display: block;
	font-weight: 500;
	color: var(--navy);
	margin-bottom: 0.375rem;
}

.field .opt {
	font-weight: 400;
	color: var(--text-2);
}

.field .help {
	display: block;
	font-size: 1rem;
	color: var(--text-2);
	margin: -0.125rem 0 0.5rem;
}

.field input[type="text"],
.field input[type="tel"],
.field input[type="email"],
.field input[type="date"],
.field input[type="number"],
.field input:not([type]),
.field select,
.field textarea {
	font: inherit;
	width: 100%;
	min-height: 3rem;
	padding: 0.625rem 0.875rem;
	border: 1.5px solid #9aa8bd;
	border-radius: var(--r-sm);
	background: #fff;
	color: var(--text);
}

.field textarea {
	min-height: 6rem;
	resize: vertical;
}

.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
	outline: 3px solid var(--focus);
	outline-offset: 1px;
	border-color: var(--focus);
}

.field [aria-invalid="true"] {
	border-color: var(--st-red-fg);
	background: #fffafa;
}

.field .err {
	display: flex;
	gap: 0.375rem;
	align-items: flex-start;
	color: var(--st-red-fg);
	font-size: 1rem;
	font-weight: 500;
	margin: 0.375rem 0 0;
}

.field .err:empty {
	display: none;
}

.field.code input {
	font-family: var(--font-mono);
	font-size: 1.5rem;
	letter-spacing: 0.3em;
	max-width: 12rem;
}

.dob {
	display: flex;
	gap: 0.625rem;
	flex-wrap: wrap;
}

.dob .part {
	display: flex;
	flex-direction: column;
}

.dob .part span {
	font-size: 0.9375rem;
	color: var(--text-2);
	margin-bottom: 0.25rem;
}

.dob input {
	width: 4.5rem !important;
	font-family: var(--font-mono);
}

.dob .part.year input {
	width: 6rem !important;
}

.quick {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0 0 0.75rem;
}

.quick .btn {
	min-height: 2.75rem;
	font-size: 1rem;
	font-weight: 500;
	padding: 0.375rem 0.875rem;
}

.section {
	border-top: 1px solid var(--line);
	padding-top: 1rem;
	margin-top: 1.25rem;
}

.section-head {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	align-items: center;
	margin-bottom: 0.5rem;
}

.section-head h3 {
	margin: 0;
}

/* ---------- date strip and times ---------- */
.strip-wrap {
	margin: 0 0 1rem;
}

.strip {
	display: flex;
	gap: 0.5rem;
	overflow-x: auto;
	padding: 0.25rem 0.125rem 0.75rem;
	scroll-snap-type: x proximity;
	list-style: none;
	margin: 0;
}

.strip li {
	flex: none;
	scroll-snap-align: start;
}

.day {
	font: inherit;
	width: 5rem;
	min-height: 5.25rem;
	border: 2px solid var(--line);
	border-radius: var(--r-md);
	background: var(--panel);
	color: var(--navy);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 0.125rem;
	cursor: pointer;
	padding: 0.375rem 0.25rem;
}

.day .dw {
	font-size: 0.875rem;
	color: var(--text-2);
	text-transform: capitalize;
}

.day .dn {
	font-family: var(--font-mono);
	font-size: 1.125rem;
	font-weight: 500;
}

.day .dc {
	font-size: 0.8125rem;
	color: var(--text-2);
}

.day[aria-pressed="true"] {
	border-color: var(--navy);
	background: var(--navy);
	color: #fff;
}

.day[aria-pressed="true"] .dw,
.day[aria-pressed="true"] .dc {
	color: #dfe6f1;
}

.day[aria-disabled="true"] {
	background: #f3f5f9;
	color: var(--text-3);
	cursor: not-allowed;
}

.strip-nav {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 0.5rem;
}

.times-group {
	margin: 0 0 1rem;
}

.times-group h3 {
	font-size: 1rem;
	color: var(--text-2);
	font-weight: 500;
	margin-bottom: 0.5rem;
}

.times {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(6.5rem, 100%), 1fr));
	gap: 0.5rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.times.with-doc {
	grid-template-columns: repeat(auto-fill, minmax(min(11rem, 100%), 1fr));
}

.time {
	font: inherit;
	width: 100%;
	min-height: 3rem;
	border: 1.5px solid var(--line-2);
	border-radius: var(--r-md);
	background: var(--panel);
	color: var(--navy);
	cursor: pointer;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 0.375rem 0.5rem;
}

.time .tt {
	font-family: var(--font-mono);
	font-weight: 500;
	font-size: 1.125rem;
}

.time .td {
	font-size: 0.875rem;
	color: var(--text-2);
}

.time:hover {
	border-color: var(--navy-3);
	background: #f7f9fd;
}

.time[aria-busy="true"] {
	opacity: 0.6;
}

/* ---------- summary / result ---------- */
.summary {
	display: grid;
	gap: 0.625rem;
	margin: 0;
}

.summary div {
	display: grid;
	gap: 0.125rem;
}

.summary dt {
	font-size: 0.9375rem;
	color: var(--text-2);
}

.summary dd {
	margin: 0;
	font-weight: 500;
	color: var(--navy);
}

.hold {
	display: flex;
	align-items: center;
	gap: 0.625rem;
	flex-wrap: wrap;
	font-size: 1rem;
	padding: 0.75rem 1rem;
	border-radius: var(--r-md);
	background: var(--st-blue-bg);
	color: #174a78;
	margin: 0 0 1rem;
}

.hold .mono {
	font-size: 1.125rem;
	font-weight: 500;
}

.hold.low {
	background: var(--st-amber-bg);
	color: #6b4600;
}

.result-head {
	display: flex;
	gap: 0.75rem;
	align-items: flex-start;
	margin-bottom: 1rem;
}

.result-head .icon {
	width: 2.25rem;
	height: 2.25rem;
	flex: none;
}

.result-head.ok .icon {
	color: var(--success);
}

.result-head.pending .icon {
	color: var(--st-amber-fg);
}

.result-head h2 {
	margin: 0.25rem 0 0.25rem;
}

.ref {
	font-family: var(--font-mono);
	font-size: 1.25rem;
	letter-spacing: 0.08em;
}

.prep {
	background: #f7f9fd;
	border-left: 4px solid var(--navy-3);
	padding: 0.75rem 1rem;
	border-radius: 0 var(--r-sm) var(--r-sm) 0;
	margin: 0.75rem 0 0;
	white-space: pre-line;
}

/* ---------- appointment cards ---------- */
.list {
	list-style: none;
	margin: 0 0 1.5rem;
	padding: 0;
}

.appt-head {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 0.5rem;
	align-items: flex-start;
	margin-bottom: 0.5rem;
}

.appt-when {
	font-weight: 500;
	color: var(--navy);
}

.appt-when .mono {
	font-size: 1.1875rem;
}

.appt-meta {
	margin: 0 0 0.25rem;
	color: var(--text-2);
	font-size: 1rem;
}

.appt-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-top: 0.875rem;
}

.appt-actions .btn {
	flex: 1 1 10rem;
}

.inline-panel {
	margin-top: 0.875rem;
	padding-top: 0.875rem;
	border-top: 1px dashed var(--line-2);
}

.past li {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 0.25rem 0.75rem;
	padding: 0.75rem 0;
	border-bottom: 1px solid var(--line);
}

.past .when {
	font-family: var(--font-mono);
	color: var(--text-2);
}

.doc-row {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	align-items: center;
	justify-content: space-between;
}

.doc-row .doc-title {
	font-weight: 500;
	color: var(--navy);
	margin: 0;
}

.doc-row .doc-meta {
	margin: 0;
	font-size: 1rem;
	color: var(--text-2);
}

/* ---------- footer ---------- */
.foot {
	background: var(--panel);
	border-top: 1px solid var(--line);
	font-size: 1rem;
}

.foot-inner {
	padding-top: 1rem;
	padding-bottom: 1rem;
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 0.25rem 1rem;
}

.foot p {
	margin: 0;
}

.foot a {
	font-weight: 500;
}

@media (min-width: 40rem) {
	h1 {
		font-size: 1.5rem;
	}

	.page {
		padding-top: 2rem;
	}

	.card {
		padding: 1.5rem;
	}
}

.dob-set {
	border: 0;
	padding: 0;
	margin: 0 0 1.125rem;
	min-width: 0;
}

.choice-wrap details {
	padding: 0 1rem 0 3.25rem;
	font-size: 1rem;
}

.choice-wrap summary {
	cursor: pointer;
	color: var(--navy-3);
	min-height: 2.75rem;
	display: flex;
	align-items: center;
	text-decoration: underline;
}

details > summary.btn {
	display: inline-flex;
	list-style: none;
}

.choice-meta .chip,
.section-head .chip {
	white-space: normal;
}

/* ================= round 2 ================= */

.field input[type="time"],
.field input[type="file"] {
	font: inherit;
	width: 100%;
	min-height: 3rem;
	padding: 0.625rem 0.875rem;
	border: 1.5px solid #9aa8bd;
	border-radius: var(--r-sm);
	background: #fff;
	color: var(--text);
}

.field input[type="time"] {
	max-width: 10rem;
	font-family: var(--font-mono);
}

.field input[type="file"]:focus-visible,
.field input[type="time"]:focus-visible {
	outline: 3px solid var(--focus);
	outline-offset: 1px;
	border-color: var(--focus);
}

.field.short input {
	max-width: 8rem;
	font-family: var(--font-mono);
	text-transform: uppercase;
}

a.top-btn {
	text-decoration: none;
}

.btn.big {
	min-height: 4rem;
	font-size: 1.0625rem;
}

details.card > summary {
	cursor: pointer;
	padding: 0.5rem 0;
	color: var(--navy);
}

details.card[open] > summary {
	margin-bottom: 0.75rem;
}

/* ---------- cost explainer, test prep ---------- */
.costs .summary div {
	grid-template-columns: 1fr auto;
	column-gap: 1rem;
	align-items: baseline;
	border-top: 1px solid var(--line);
	padding-top: 0.625rem;
}

.costs .summary div:first-child {
	border-top: 0;
	padding-top: 0;
}

.costs .summary dt {
	color: var(--text);
	font-size: 1rem;
}

.cost-amount {
	text-align: right;
}

.cost-note {
	grid-column: 1 / -1;
	font-size: 0.9375rem;
	color: var(--text-2);
	font-weight: 400;
}

/* ---------- pre-visit pack ---------- */
.pv-files li {
	align-items: center;
}

.pv-files .btn {
	margin-left: auto;
}

.pv-questions {
	margin: 0;
	padding-left: 1.5rem;
}

.pv-questions li {
	margin-bottom: 0.5rem;
}

/* ---------- home BP diary ---------- */
.how ol {
	margin: 0;
	padding-left: 1.5rem;
}

.how li {
	margin-bottom: 0.5rem;
}

.bp-count {
	font-weight: 500;
	color: var(--navy);
	margin-bottom: 0.5rem;
}

.bp-progress .progress {
	height: 0.75rem;
	margin-bottom: 0.75rem;
}

.bp-day.done {
	border-color: #bfe0c9;
}

.bp-day h3 {
	margin: 0;
}

.bp-session {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.25rem 1rem;
	padding: 0.625rem 0;
	border-top: 1px solid var(--line);
}

.bp-session p {
	margin: 0;
}

.bp-session .bp-label {
	min-width: 6rem;
}

.bp-session .bp-values {
	flex: 1 1 12rem;
	display: flex;
	flex-direction: column;
}

.bp-session .btn {
	margin-left: auto;
}

.bp-reading {
	border: 1px solid var(--line);
	border-radius: var(--r-md);
	padding: 0.75rem 1rem 0;
	margin: 0 0 1rem;
	min-width: 0;
}

.bp-reading legend {
	font-weight: 500;
	color: var(--navy);
	padding: 0 0.25rem;
}

.bp-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(9rem, 100%), 1fr));
	gap: 0 1rem;
	align-items: start;
}

/* Two-line label box so the three inputs line up whatever the label length. */
.bp-grid .field label {
	min-height: 3.2em;
	display: flex;
	align-items: flex-end;
}

.bp-grid input {
	font-family: var(--font-mono);
	font-size: 1.25rem;
}

.bp-avg {
	font-size: 1.75rem;
	font-weight: 500;
	color: var(--navy);
	margin-bottom: 0.25rem;
}

/* ---------- wait page ---------- */
.wait-box {
	background: var(--panel);
	border: 2px solid var(--navy);
	border-radius: var(--r-md);
	padding: 1.5rem 1rem;
	margin: 0 0 1rem;
	text-align: center;
}

.wait-box p {
	margin: 0 0 0.5rem;
}

.wait-label {
	font-weight: 500;
	color: var(--text-2);
}

.wait-time {
	font-size: 3.5rem;
	line-height: 1.1;
	font-weight: 500;
	color: var(--navy);
}

.wait-sub {
	font-size: 1.25rem;
}

.wait-box .wait-note {
	margin-top: 1rem;
	color: var(--text-2);
}

.wait-called {
	font-size: 1.375rem;
	font-weight: 500;
}

/* ---------- visit summary (large print friendly) ---------- */
.summary-doc {
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--r-md);
	padding: 1.25rem;
	margin: 0 0 1rem;
	font-size: 1.25rem;
	line-height: 1.7;
}

.summary-doc section + section {
	border-top: 1px solid var(--line);
	padding-top: 1rem;
}

.summary-doc p {
	white-space: pre-line;
}

@media print {
	.top,
	.foot,
	.skip,
	.no-print,
	#live {
		display: none !important;
	}

	body {
		background: #fff;
	}

	.page {
		max-width: none;
		padding: 0;
	}

	.summary-doc {
		border: 0;
		padding: 0;
		font-size: 14pt;
	}
}

/* ================= senior mode (html.senior) =================
 * Base type 20px, darker secondary text and borders, targets at least 56px (3.5rem), one question per screen.
 */
html.senior body {
	font-size: 1.25rem;
	line-height: 1.6;
	--text-2: #2b3a52;
	--text-3: #3d4b61;
	--line: #c3cddd;
	--line-2: #8f9db3;
}

html.senior h1 {
	font-size: 2rem;
}

html.senior h2 {
	font-size: 1.5rem;
}

html.senior h3 {
	font-size: 1.3125rem;
}

html.senior .btn,
html.senior .top-btn,
html.senior .lang a,
html.senior .tabs a,
html.senior .menu a,
html.senior .time,
html.senior .choice,
html.senior .field input,
html.senior .field select,
html.senior .field textarea,
html.senior details > summary,
html.senior .choice-wrap summary {
	min-height: 3.5rem;
}

html.senior .btn {
	font-size: 1.25rem;
	padding: 0.75rem 1.5rem;
}

html.senior .field input,
html.senior .field select,
html.senior .field textarea {
	font-size: 1.25rem;
	border-width: 2px;
	border-color: #5d6b82;
}

html.senior .field .help,
html.senior .small,
html.senior .choice-text,
html.senior .choice-meta,
html.senior .chip,
html.senior .stepper p {
	font-size: 1.0625rem;
}

html.senior .choice {
	padding: 1rem 1rem 1rem 3.75rem;
	border-width: 3px;
}

html.senior .choice input {
	width: 1.75rem;
	height: 1.75rem;
	top: 1.1rem;
}

html.senior .choice-title {
	font-size: 1.3125rem;
}

html.senior .strip {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(9rem, 100%), 1fr));
	overflow: visible;
}

html.senior .day {
	width: 100%;
	min-height: 4.5rem;
	flex-direction: row;
	gap: 0.5rem;
}

html.senior .day .dw,
html.senior .day .dc {
	font-size: 1.0625rem;
}

html.senior .times {
	grid-template-columns: repeat(auto-fill, minmax(min(8.5rem, 100%), 1fr));
}

html.senior .time .tt {
	font-size: 1.5rem;
}

html.senior :focus-visible {
	outline-width: 4px;
}

/* Headings keep a clear but restrained weight; body emphasis uses 500. */
h1,
h2 {
	font-weight: 600;
}
