/* Typography ------------------------------------------------------------- */

h1,
h2,
h3,
p {
	margin-top: 0;
}

h1,
h2,
h3 {
	color: var(--am-navy-950);
	font-weight: 700;
	letter-spacing: -0.02em;
	line-height: var(--am-leading-tight);
}

h1 {
	font-size: var(--am-text-2xl);
	letter-spacing: -0.025em;
	line-height: 1.1;
	margin-bottom: var(--am-space-3);
}

h2 {
	font-size: var(--am-text-lg);
}

h3 {
	font-size: var(--am-text-md);
}

.am-eyebrow {
	color: var(--am-text-subtle);
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	margin-bottom: var(--am-space-2);
	text-transform: uppercase;
}

/* Page header / hero ------------------------------------------------------ */

.am-hero {
	align-items: end;
	display: flex;
	gap: var(--am-space-8);
	justify-content: space-between;
	margin: 0 auto var(--am-space-8);
	max-width: var(--am-content-max);
	position: relative;
}

.am-hero > div {
	max-width: 48rem;
}

.am-hero__summary,
.am-section__heading > p {
	color: var(--am-text-muted);
	margin-bottom: 0;
}

.am-page-heading {
	margin: 0 auto var(--am-space-6);
	max-width: var(--am-content-max);
	position: relative;
}

.am-page-heading h1 {
	margin-bottom: var(--am-space-2);
}

.am-page-heading > p:last-child {
	color: var(--am-text-muted);
	margin-bottom: 0;
}

/* Buttons ------------------------------------------------------------------ */

.am-button {
	align-items: center;
	border: 1px solid transparent;
	border-radius: var(--am-radius-control);
	cursor: pointer;
	display: inline-flex;
	font-weight: 600;
	gap: var(--am-space-2);
	justify-content: center;
	line-height: 1.2;
	min-height: 2.75rem;
	padding: var(--am-space-2) var(--am-space-5);
	text-decoration: none;
	transition:
		background-color var(--am-duration) var(--am-ease),
		border-color var(--am-duration) var(--am-ease),
		color var(--am-duration) var(--am-ease);
}

.am-button--primary {
	background: var(--am-action);
	color: var(--am-navy-950);
	font-size: 1.1875rem;
	font-weight: 700;
}

.am-button--primary:hover {
	background: var(--am-white);
	border-color: var(--am-action);
	color: var(--am-orange-text);
}

.am-button--primary.am-button--cart-current {
	background: var(--am-status-success-bg);
	border-color: #bfe3cd;
	color: var(--am-success);
}

.am-button--primary.am-button--cart-current:hover {
	background: var(--am-success);
	border-color: var(--am-success);
	color: var(--am-white);
}

.am-button--secondary {
	background: var(--am-white);
	border-color: var(--am-navy-900);
	color: var(--am-navy-900);
}

.am-button--secondary:hover {
	background: var(--am-surface-2);
	color: var(--am-navy-950);
}

.am-button--ghost {
	background: transparent;
	color: var(--am-navy-900);
}

.am-button--ghost:hover {
	background: var(--am-surface-2);
	color: var(--am-navy-950);
}

.am-button--danger {
	background: var(--am-danger);
	color: var(--am-white);
}

.am-button--danger:hover {
	background: var(--am-danger-hover);
	color: var(--am-white);
}

.am-button--pay {
	background: var(--am-status-success-bg);
	border-color: #bfe3cd;
	color: var(--am-success);
	font-weight: 700;
}

.am-button--pay:hover {
	background: var(--am-success);
	color: var(--am-white);
}

.am-button--attention {
	background: var(--am-orange-100);
	border-color: var(--am-status-warning-border);
	color: var(--am-orange-text);
	font-weight: 700;
}

.am-button--attention:hover {
	background: var(--am-brand);
	color: var(--am-white);
}

.am-button--view {
	background: var(--am-status-info-bg);
	border-color: #d3deea;
	color: var(--am-navy-900);
}

.am-button--view:hover {
	background: var(--am-navy-900);
	color: var(--am-white);
}

.am-button--track {
	background: var(--am-navy-950);
	border-color: var(--am-navy-950);
	color: var(--am-white);
}

.am-button--track:hover {
	background: var(--am-white);
	color: var(--am-navy-950);
}

.am-button--reorder {
	background: var(--am-silver-100);
	border-color: var(--am-silver-300);
	color: var(--am-text-subtle);
}

.am-button--reorder:hover {
	background: var(--am-silver-300);
	color: var(--am-navy-950);
}

.am-button--small {
	font-size: var(--am-text-sm);
	min-height: 2.25rem;
	padding: var(--am-space-1) var(--am-space-3);
}

/* Bright brand orange always uses navy text at rest for AA text contrast. */
.am-button--primary.am-button--small {
	color: var(--am-navy-950);
	font-weight: 700;
}

.am-button--primary.am-button--small:hover {
	color: var(--am-orange-text);
}

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

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

.am-badge {
	align-items: center;
	background: var(--am-status-neutral-bg);
	border-radius: var(--am-radius-pill);
	color: var(--am-status-neutral-fg);
	display: inline-flex;
	font-size: var(--am-text-xs);
	font-weight: 600;
	gap: 0.4rem;
	line-height: 1.25;
	padding: 0.2rem 0.65rem;
	white-space: nowrap;
}

.am-badge::before {
	background: currentcolor;
	border-radius: 50%;
	content: "";
	flex: none;
	height: 0.4rem;
	width: 0.4rem;
}

.am-badge--neutral {
	background: var(--am-status-neutral-bg);
	color: var(--am-status-neutral-fg);
}

.am-badge--success {
	background: var(--am-status-success-bg);
	color: var(--am-status-success-fg);
}

.am-badge--attention,
.am-badge--warning {
	background: var(--am-status-warning-bg);
	color: var(--am-status-warning-fg);
}

.am-badge--danger {
	background: var(--am-status-danger-bg);
	color: var(--am-status-danger-fg);
}

.am-badge--info {
	background: var(--am-status-info-bg);
	color: var(--am-status-info-fg);
}

.am-badge--needs-partner {
	background: var(--am-status-warning-bg);
	color: var(--am-status-warning-fg);
}

.am-badge--with-amidose {
	background: var(--am-status-info-bg);
	color: var(--am-status-info-fg);
}

.am-badge--done {
	background: var(--am-status-success-bg);
	color: var(--am-status-success-fg);
}

.am-badge--closed {
	background: var(--am-status-neutral-bg);
	color: var(--am-status-neutral-fg);
}

.am-badge--overdue {
	background: var(--am-status-overdue-bg);
	color: var(--am-status-danger-fg);
}

/* Shared Phase 4 presentation contracts ----------------------------------- */

.am-page-title {
	background: var(--am-white);
	border-left: 0.25rem solid var(--am-navy-900);
	border-radius: 0 var(--am-radius-card) var(--am-radius-card) 0;
	box-shadow: var(--am-shadow-1);
	padding: var(--am-space-5) var(--am-space-6);
}

.am-page-title h1,
.am-page-title h2 {
	font-size: 1.5rem;
	line-height: 1.2;
	margin: 0;
}

.am-page-title__eyebrow {
	color: var(--am-navy-700);
	font-size: 0.6875rem;
	font-weight: 800;
	letter-spacing: 0.14em;
	margin: 0 0 var(--am-space-1);
	text-transform: uppercase;
}

.am-page-title__summary {
	color: var(--am-text-muted);
	margin: var(--am-space-2) 0 0;
}

.am-page-title--compact {
	box-shadow: none;
	padding-block: var(--am-space-4);
}

.am-address {
	display: grid;
	gap: 0.15rem;
	min-width: 0;
}

.am-address > span {
	overflow-wrap: anywhere;
}

.am-field-guidance {
	color: var(--am-text-muted);
	font-size: var(--am-text-sm);
	line-height: 1.45;
	margin: var(--am-space-2) 0 0;
}

.am-field-guidance--privacy {
	align-items: flex-start;
	display: flex;
	gap: var(--am-space-2);
}

.am-field-guidance--privacy::before {
	color: var(--am-orange-text);
	content: "i";
	font-weight: 800;
}

.am-filter__chips {
	display: flex;
	flex-wrap: wrap;
	gap: var(--am-space-2);
}

.am-filter-chip {
	align-items: center;
	background: var(--am-white);
	border: 1px solid var(--am-border);
	border-radius: var(--am-radius-pill);
	color: var(--am-text);
	display: inline-flex;
	font-size: var(--am-text-sm);
	font-weight: 700;
	gap: var(--am-space-1);
	min-height: 2.75rem;
	padding: 0 var(--am-space-4);
	text-decoration: none;
}

.am-filter-chip:hover,
.am-filter-chip:focus-visible,
.am-filter-chip.is-selected {
	background: var(--am-navy-900);
	border-color: var(--am-navy-900);
	color: var(--am-white);
}

.am-filter-chip span {
	font-variant-numeric: var(--am-tnum);
}

.am-filter-selector {
	align-items: center;
	background: var(--am-white);
	border: 1px solid var(--am-border-strong);
	border-radius: var(--am-radius-control);
	color: var(--am-text);
	display: none;
	font: inherit;
	justify-content: space-between;
	min-height: 3rem;
	padding: 0 var(--am-space-4);
	text-align: left;
	width: 100%;
}

.am-dialog {
	background: transparent;
	border: 0;
	color: var(--am-text);
	max-height: calc(100vh - 2rem);
	max-width: min(34rem, calc(100vw - 2rem));
	padding: 0;
	width: 100%;
}

.am-dialog::backdrop {
	background: rgb(7 26 53 / 0.52);
}

.am-dialog__surface {
	background: var(--am-white);
	border: 1px solid var(--am-border);
	border-radius: var(--am-radius-card);
	box-shadow: var(--am-shadow-drawer);
	display: grid;
	gap: var(--am-space-5);
	max-height: calc(100vh - 2rem);
	overflow: auto;
	padding: var(--am-space-6);
}

.am-dialog__header {
	align-items: flex-start;
	display: flex;
	gap: var(--am-space-4);
	justify-content: space-between;
}

.am-dialog__header h2,
.am-dialog__header p {
	margin: 0;
}

.am-dialog__header h2 {
	font-size: 1.25rem;
}

.am-dialog__header p {
	color: var(--am-text-muted);
	margin-top: var(--am-space-2);
}

.am-dialog__body {
	min-width: 0;
}

.am-dialog__actions {
	display: flex;
	gap: var(--am-space-3);
	justify-content: flex-end;
}

.am-dialog__handle {
	background: transparent;
	border: 0;
	cursor: grab;
	display: none;
	min-height: 2rem;
	padding: 0;
	place-items: center;
	width: 100%;
}

.am-dialog__handle span {
	background: var(--am-border-strong);
	border-radius: var(--am-radius-pill);
	display: block;
	height: 0.3rem;
	width: 2.75rem;
}

.am-filter-options {
	border: 0;
	display: grid;
	gap: var(--am-space-2);
	margin: 0;
	padding: 0;
}

.am-filter-option {
	align-items: center;
	background: var(--am-white);
	border: 1px solid var(--am-border);
	border-radius: var(--am-radius-control);
	cursor: pointer;
	display: grid;
	gap: var(--am-space-3);
	grid-template-columns: auto 1fr auto;
	min-height: 3rem;
	padding: var(--am-space-2) var(--am-space-3);
}

.am-filter-option:has(input:checked) {
	background: var(--am-brand-soft);
	border-color: var(--am-brand);
	box-shadow: inset 0.2rem 0 var(--am-brand);
}

.am-filter-option input {
	accent-color: var(--am-brand);
}

.am-filter-option small {
	color: var(--am-text-muted);
	font-variant-numeric: var(--am-tnum);
}

body.am-component-modal-open {
	overflow: hidden;
}

.am-toast-region {
	display: grid;
	gap: var(--am-space-2);
	inset: auto var(--am-space-5) var(--am-space-5) auto;
	max-width: min(26rem, calc(100vw - 2rem));
	pointer-events: none;
	position: fixed;
	z-index: 80;
}

.am-toast {
	align-items: center;
	background: var(--am-navy-900);
	border-radius: var(--am-radius-control);
	box-shadow: var(--am-shadow-drawer);
	color: var(--am-white);
	display: grid;
	gap: var(--am-space-3);
	grid-template-columns: auto 1fr auto;
	padding: var(--am-space-3) var(--am-space-4);
	pointer-events: auto;
}

.am-toast::before {
	color: var(--am-status-success-fg-on-dark, #8ee0b4);
	content: "✓";
	font-weight: 900;
}

.am-toast button {
	background: transparent;
	border: 0;
	color: inherit;
	font: inherit;
	min-height: 2.75rem;
	min-width: 2.75rem;
}

@media (max-width: 50rem) {
	.am-page-title {
		background: transparent;
		border: 0;
		border-radius: 0;
		box-shadow: none;
		padding: 0;
	}

	.am-page-title__eyebrow {
		align-items: center;
		display: flex;
		gap: var(--am-space-2);
	}

	.am-page-title__eyebrow::before {
		background: var(--am-brand);
		content: "";
		height: 0.1875rem;
		width: 1.375rem;
	}

	.am-filter__chips {
		display: none;
	}

	.am-filter-selector {
		display: flex;
	}

	.am-dialog {
		inset: auto 0 0;
		margin: auto auto 0;
		max-height: 92vh;
		max-width: 24.375rem;
		width: 100%;
	}

	.am-dialog__surface {
		border-width: 1px 0 0;
		border-radius: var(--am-radius-lg) var(--am-radius-lg) 0 0;
		max-height: 92vh;
		padding: 0 var(--am-space-4) calc(var(--am-space-5) + env(safe-area-inset-bottom));
	}

	.am-dialog__handle {
		display: grid;
	}

	.am-dialog__actions {
		grid-template-columns: 1fr 1fr;
	}

	.am-dialog__actions .am-button {
		width: 100%;
	}

	.am-toast-region {
		inset: auto var(--am-space-4) calc(5rem + env(safe-area-inset-bottom));
		max-width: none;
	}
}

@media (prefers-reduced-motion: no-preference) {
	.am-dialog[open] .am-dialog__surface {
		animation: am-component-dialog-in 240ms var(--am-ease);
	}
}

@keyframes am-component-dialog-in {
	from {
		transform: translateY(1rem);
	}

	to {
		transform: translateY(0);
	}
}

/* Notices and callouts ------------------------------------------------------- */

.am-notice {
	background: var(--am-status-info-bg);
	border-left: 3px solid var(--am-navy-700);
	border-radius: var(--am-radius-control);
	color: var(--am-text);
	font-size: var(--am-text-sm);
	margin: 0 auto var(--am-space-5);
	max-width: var(--am-content-max);
	padding: var(--am-space-3) var(--am-space-4);
}

.am-notice p {
	margin: 0;
}

.am-notice p + p {
	margin-top: var(--am-space-1);
}

.am-notice--neutral {
	background: var(--am-status-info-bg);
	border-left-color: var(--am-navy-700);
}

.am-notice--warning {
	background: var(--am-status-warning-bg);
	border-left-color: var(--am-warning);
}

.am-notice--error {
	background: var(--am-status-danger-bg);
	border-left-color: var(--am-danger);
}

.am-notice--success {
	background: var(--am-status-success-bg);
	border-left-color: var(--am-success);
}

.am-demo-status {
	background: var(--am-status-info-bg);
	border-left: 3px solid var(--am-navy-700);
	border-radius: var(--am-radius-control);
	color: var(--am-text);
	margin: var(--am-space-5) 0 0;
	padding: var(--am-space-3) var(--am-space-4);
}

/* Empty and state blocks ---------------------------------------------------- */

.am-empty-state {
	background: var(--am-surface);
	border: 1px dashed var(--am-border-strong);
	border-radius: var(--am-radius-card);
	padding: var(--am-space-8) var(--am-space-6);
	text-align: center;
}

.am-empty-state h2,
.am-empty-state h3 {
	margin-bottom: var(--am-space-2);
}

.am-empty-state p {
	color: var(--am-text-muted);
	margin: 0 auto var(--am-space-4);
	max-width: 38rem;
}

.am-empty-state p:last-child {
	margin-bottom: 0;
}

/* Metric strip -------------------------------------------------------------- */

.am-metrics {
	background: var(--am-white);
	border: 1px solid var(--am-border-strong);
	border-radius: var(--am-radius-card);
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	margin: 0 auto var(--am-space-10);
	max-width: var(--am-content-max);
}

.am-metric-card {
	align-items: center;
	display: flex;
	gap: var(--am-space-4);
	min-height: 7rem;
	padding: var(--am-space-5);
}

.am-metric-card + .am-metric-card {
	border-left: 1px solid var(--am-border);
}

.am-metric-card__icon {
	background: var(--am-surface);
	border: 1px solid var(--am-border);
	border-radius: 50%;
	color: var(--am-text-subtle);
	display: grid;
	font-size: var(--am-text-xs);
	font-variant-numeric: tabular-nums;
	height: 2.75rem;
	place-items: center;
	width: 2.75rem;
}

.am-metric-card div {
	display: grid;
}

.am-metric-card div span {
	color: var(--am-text-subtle);
	font-size: var(--am-text-sm);
}

.am-metric-card strong {
	font-size: var(--am-text-md);
}

/* Sections and cards ------------------------------------------------------- */

.am-section {
	background: var(--am-white);
	border: 1px solid var(--am-border-strong);
	border-radius: var(--am-radius-card);
	margin: 0 auto var(--am-space-8);
	max-width: var(--am-content-max);
	padding: var(--am-space-6);
	position: relative;
	scroll-margin-top: calc(var(--am-topbar-height) + var(--am-space-4));
}

.am-section__heading {
	align-items: start;
	display: grid;
	gap: var(--am-space-8);
	grid-template-columns: minmax(0, 1fr) minmax(18rem, 0.8fr);
	margin-bottom: var(--am-space-6);
}

.am-section__heading h2 {
	margin-bottom: 0;
}

.am-destination-grid,
.am-state-grid {
	display: grid;
	gap: var(--am-space-4);
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.am-destination-card,
.am-state-card {
	background: var(--am-surface);
	border: 1px solid var(--am-border);
	border-radius: var(--am-radius-card);
	min-width: 0;
	padding: var(--am-space-5);
	scroll-margin-top: calc(var(--am-topbar-height) + var(--am-space-4));
}

.am-destination-card {
	display: flex;
	flex-direction: column;
}

.am-destination-card__index {
	align-items: center;
	background: var(--am-white);
	border: 1px solid var(--am-border-strong);
	border-radius: 50%;
	color: var(--am-text-subtle);
	display: inline-flex;
	font-size: var(--am-text-xs);
	font-weight: 700;
	height: 2.75rem;
	justify-content: center;
	width: 2.75rem;
}

.am-destination-card__link {
	color: var(--am-link);
	font-size: var(--am-text-sm);
	font-weight: 700;
	margin-top: auto;
	padding-top: var(--am-space-5);
}

.am-destination-card h3 {
	margin: var(--am-space-4) 0 var(--am-space-2);
}

.am-destination-card p,
.am-state-card p {
	color: var(--am-text-muted);
	font-size: var(--am-text-sm);
	margin-bottom: 0;
}

.am-state-grid {
	grid-template-columns: repeat(4, minmax(0, 1fr));
}

.am-state-card {
	display: flex;
	flex-direction: column;
}

.am-state-card__symbol {
	align-items: center;
	background: var(--am-white);
	border: 1px solid var(--am-border-strong);
	border-radius: 50%;
	display: inline-flex;
	font-weight: 700;
	height: 2.75rem;
	justify-content: center;
	margin-bottom: var(--am-space-4);
	width: 2.75rem;
}

.am-state-card--error {
	border-color: var(--am-status-danger-border);
}

.am-state-card--denied {
	border-color: var(--am-status-warning-border);
}

.am-state-card .am-button {
	align-self: flex-start;
	margin-top: auto;
	padding-inline: var(--am-space-4);
}

.am-skeleton {
	background: linear-gradient(90deg, var(--am-silver-100) 25%, var(--am-white) 50%, var(--am-silver-100) 75%);
	background-size: 200% 100%;
	border-radius: var(--am-radius-control);
	height: 1rem;
	width: 4.5rem;
}

/* Data table -------------------------------------------------------------- */

/* Wide tables scroll inside their own region so the page never scrolls sideways. */
.am-table-scroll {
	max-width: 100%;
	overflow-x: auto;
}

.am-table-scroll:focus-visible {
	outline: 3px solid var(--am-focus);
	outline-offset: 2px;
}

.am-table {
	border-collapse: collapse;
	font-size: var(--am-text-sm);
	width: 100%;
}

.am-table caption {
	caption-side: top;
	color: var(--am-text-subtle);
	font-size: var(--am-text-xs);
	padding-bottom: var(--am-space-2);
	text-align: left;
}

.am-table th,
.am-table td {
	padding: var(--am-space-3) var(--am-space-3);
	text-align: left;
	vertical-align: top;
}

.am-table thead th {
	border-bottom: 1px solid var(--am-border-strong);
	color: var(--am-text-subtle);
	font-size: var(--am-text-xs);
	font-weight: 600;
	letter-spacing: 0.02em;
	white-space: nowrap;
}

.am-table tbody tr + tr th,
.am-table tbody tr + tr td {
	border-top: 1px solid var(--am-border);
}

.am-table tbody th {
	color: var(--am-navy-950);
	font-weight: 700;
	overflow-wrap: anywhere;
}

.am-table td {
	color: var(--am-text);
	overflow-wrap: anywhere;
}

.am-table .is-numeric {
	font-variant-numeric: var(--am-tnum);
	text-align: right;
	white-space: nowrap;
}

.am-table .is-muted {
	color: var(--am-text-subtle);
}

.am-table .is-action {
	text-align: right;
	white-space: nowrap;
}

/* Stacked rows below the breakpoint; each cell keeps its header via data-label. */
@media (max-width: 50rem) {
	.am-table--stacked thead {
		clip: rect(1px, 1px, 1px, 1px);
		clip-path: inset(50%);
		height: 1px;
		overflow: hidden;
		position: absolute;
		white-space: nowrap;
		width: 1px;
	}

	.am-table--stacked tbody tr {
		border: 1px solid var(--am-border);
		border-radius: var(--am-radius-control);
		display: grid;
		margin-bottom: var(--am-space-3);
		padding: var(--am-space-3);
	}

	.am-table--stacked tbody tr + tr th,
	.am-table--stacked tbody tr + tr td {
		border-top: 0;
	}

	.am-table--stacked tbody th,
	.am-table--stacked tbody td {
		display: flex;
		gap: var(--am-space-4);
		justify-content: space-between;
		padding: var(--am-space-1) 0;
	}

	.am-table--stacked tbody td[data-label]::before {
		color: var(--am-text-subtle);
		content: attr(data-label);
		flex: 0 0 auto;
		font-size: var(--am-text-xs);
	}

	.am-table--stacked .is-numeric,
	.am-table--stacked .is-action {
		text-align: left;
	}

	/*
	 * The row header is the card title. When it carries an identity block
	 * (product name plus strength and SKU) the parts stack and read as one
	 * group; laid out in a row they became three narrow columns that broke
	 * mid-word at 320px.
	 */
	.am-table--stacked tbody th {
		align-items: flex-start;
		flex-direction: column;
		font-size: var(--am-text-base);
		gap: var(--am-space-1);
		padding-bottom: var(--am-space-2);
	}

	.am-table--stacked tbody th span {
		color: var(--am-text-subtle);
		display: block;
		font-size: var(--am-text-xs);
		font-weight: 400;
	}
}

/* Stat tiles --------------------------------------------------------------- */

/*
 * Explicit breakpoints rather than auto-fit: the summary reads as one balanced
 * row of four on desktop, a 2x2 block on tablets, and a single column on
 * phones, instead of leaving a lone tile stranded on its own row.
 */
.am-stats {
	display: grid;
	gap: var(--am-space-4);
	grid-template-columns: repeat(4, minmax(0, 1fr));
	margin: 0 auto var(--am-space-6);
	max-width: var(--am-content-max);
}

@media (max-width: 64rem) {
	.am-stats {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 34rem) {
	.am-stats {
		grid-template-columns: minmax(0, 1fr);
	}
}

.am-stat {
	/* Top-aligned so labels line up across tiles even when a value wraps. */
	align-items: flex-start;
	background: var(--am-white);
	border: 1px solid var(--am-border-strong);
	border-radius: var(--am-radius-card);
	display: flex;
	gap: var(--am-space-3);
	min-width: 0;
	padding: var(--am-space-4);
}

.am-stat__icon {
	align-items: center;
	background: var(--am-surface-2);
	border-radius: var(--am-radius-control);
	color: var(--am-navy-900);
	display: flex;
	flex: none;
	height: 2.5rem;
	justify-content: center;
	width: 2.5rem;
}

.am-stat > div {
	display: grid;
	min-width: 0;
}

.am-stat span {
	color: var(--am-text-subtle);
	font-size: var(--am-text-xs);
}

.am-stat strong {
	font-size: var(--am-text-md);
	overflow-wrap: anywhere;
}

.am-stat strong.is-numeric {
	font-variant-numeric: var(--am-tnum);
}

/* Timeline ----------------------------------------------------------------- */

.am-timeline {
	display: grid;
	gap: 0;
	list-style: none;
	margin: 0;
	padding: 0;
}

.am-timeline > li {
	display: grid;
	gap: var(--am-space-4);
	grid-template-columns: 2rem minmax(0, 1fr);
	padding-bottom: var(--am-space-5);
	position: relative;
}

.am-timeline > li:last-child {
	padding-bottom: 0;
}

/* Connector line between markers. */
.am-timeline > li:not(:last-child)::before {
	background: var(--am-border-strong);
	content: "";
	inset: 2.25rem auto 0 0.9375rem;
	position: absolute;
	width: 1px;
}

/* Clinic overview ---------------------------------------------------------- */

/* Block flow, not grid: a centred grid item with auto inline margins is sized
from its max-content, so the auto-fit stat grid would resolve four tracks and
overflow the clipped canvas at narrow widths. */
.am-overview {
	display: block;
}

.am-overview__header {
	align-items: flex-end;
	display: flex;
	gap: var(--am-space-6);
	justify-content: space-between;
	margin-bottom: var(--am-space-5);
}

.am-overview__header > div {
	max-width: 46rem;
	min-width: 0;
}

.am-overview__header p {
	color: var(--am-text-muted);
	margin-bottom: 0;
}

.am-overview__orders .am-section__heading {
	align-items: center;
	border-bottom: 1px solid var(--am-border);
	gap: var(--am-space-4);
	grid-template-columns: minmax(0, 1fr) auto;
	margin-bottom: var(--am-space-4);
	padding-bottom: var(--am-space-3);
}

.am-overview__orders .am-section__heading h2 {
	font-size: var(--am-text-md);
}

.am-overview__orders .am-section__heading p {
	color: var(--am-text-subtle);
	font-size: var(--am-text-sm);
	font-variant-numeric: var(--am-tnum);
	margin: var(--am-space-1) 0 0;
}

.am-overview__orders .am-empty-state .am-icon {
	color: var(--am-text-subtle);
	margin: 0 auto var(--am-space-3);
}

@media (max-width: 50rem) {
	.am-overview__header {
		align-items: stretch;
		flex-direction: column;
		gap: var(--am-space-4);
	}

	.am-overview__orders .am-section__heading {
		grid-template-columns: 1fr;
	}

	.am-overview__orders .am-section__heading .am-button {
		justify-self: start;
	}
}

/* Pagination --------------------------------------------------------------- */

.am-pagination {
	align-items: center;
	border-top: 1px solid var(--am-border);
	display: grid;
	gap: var(--am-space-4);
	grid-template-columns: 1fr auto 1fr;
	margin-top: var(--am-space-5);
	padding-top: var(--am-space-5);
}

.am-pagination > :last-child {
	justify-self: end;
}

.am-pagination [aria-current="page"] {
	color: var(--am-text-subtle);
	font-size: var(--am-text-sm);
	font-variant-numeric: var(--am-tnum);
}

/* Responsive components ------------------------------------------------------ */

@media (max-width: 70rem) {
	.am-destination-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

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

@media (max-width: 50rem) {
	.am-hero {
		align-items: start;
		flex-direction: column;
		gap: var(--am-space-5);
	}

	.am-metrics {
		grid-template-columns: 1fr;
	}

	.am-metric-card {
		min-height: auto;
	}

	.am-metric-card + .am-metric-card {
		border-left: 0;
		border-top: 1px solid var(--am-border);
	}

	.am-section__heading {
		gap: var(--am-space-3);
		grid-template-columns: 1fr;
	}
}

@media (max-width: 34rem) {
	.am-destination-grid,
	.am-state-grid {
		grid-template-columns: 1fr;
	}

	.am-section {
		padding: var(--am-space-5);
	}

	.am-hero .am-button {
		width: 100%;
	}
}
