/* Reading pages: Intentions, Divine Office, Today's Prayers */
.reading-column {
	max-width: 800px;
	margin-left: auto;
	margin-right: auto;
}

.reading p,
.reading li,
.reading td,
.reading blockquote,
.reading .card-body,
.reading .list-group-item {
	font-size: 1.125rem;
	line-height: 1.65;
}

/* Scraped office text and rich-text prayers carry their own inline styles. */
.reading .office-text *,
.reading .list-group-item * {
	color: inherit !important;
	background-color: transparent !important;
}
.reading img,
.reading table,
.reading iframe {
	max-width: 100%;
	height: auto;
}
/* Rich-text paragraphs shouldn't leave a gap at the end of a row or card. */
.reading .list-group-item p:last-child {
	margin-bottom: 0;
}
.reading .office-text {
	overflow-wrap: break-word;
}

/* Touch-sized controls */
.tap-target {
	min-width: 44px;
	min-height: 44px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

/* Bottom navigation bar (narrow screens only; hidden at lg+ by d-lg-none) */
.bottom-nav {
	z-index: 1030; /* Bootstrap's fixed layer; below dropdowns (1000 within nav), modals (1055) and popovers (1070) */
	padding-bottom: env(safe-area-inset-bottom);
	background-color: var(--bs-body-bg);
	border-top: 1px solid var(--bs-border-color);
}
.bottom-nav .nav-item {
	flex: 1 1 0;
}
.bottom-nav .bottom-nav-link {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 56px;
	min-width: 44px;
	padding: .25rem;
	font-size: .75rem;
	color: var(--bs-secondary-color);
	background: none;
	border: 0;
	text-decoration: none;
}
.bottom-nav .bottom-nav-link .bi {
	font-size: 1.35rem;
	line-height: 1;
}
.bottom-nav .bottom-nav-link.active,
.bottom-nav .bottom-nav-link[aria-expanded="true"] {
	color: var(--bs-primary);
}
.bottom-nav .dropdown-menu {
	min-width: 12rem;
}
.bottom-nav .dropdown-item {
	min-height: 44px;
	display: flex;
	align-items: center;
}

@media (max-width: 991.98px) {
	/* Leave room so the end of every page scrolls clear of the bottom bar. */
	body.has-bottom-nav {
		padding-bottom: calc(56px + 1rem + env(safe-area-inset-bottom));
	}

	/* Give text the full width on phones. */
	.content-card {
		border: 0;
		background-color: transparent;
	}
	#content.container-lg {
		padding-left: .5rem;
		padding-right: .5rem;
	}
}

/* Long dropdown menus (prayer favorites, groups) scroll instead of running off-screen. */
.bottom-nav .dropdown-menu,
.navbar .prayers-menu {
	max-height: calc(100vh - 8rem);
	overflow-y: auto;
}

/* In list rows with buttons (group and prayer lists), let a long title wrap
   instead of pushing the buttons off a phone screen. */
.list-group-item > a.flex-grow-1 {
	min-width: 0;
	overflow-wrap: break-word;
	hyphens: auto;
}
@media (max-width: 575.98px) {
	/* Phone: make room so single long words (e.g. "Miscellaneous") fit beside four buttons. */
	.list-group-item > a.flex-grow-1 {
		font-size: 1rem !important;
	}
	.list-group-item.gap-2 {
		gap: .25rem !important;
	}
}

/* Today (home) page */
.today-heading {
	font-size: .75rem;
	font-weight: 600;
	letter-spacing: .05em;
	text-transform: uppercase;
	color: var(--bs-secondary-color);
	margin-bottom: .35rem;
}
.today-now {
	display: flex;
	align-items: baseline;
	gap: .75rem;
	padding-top: .9rem;
	padding-bottom: .9rem;
}
.today-now > span:first-child {
	font-size: 1.5rem;
	font-weight: 500;
	color: var(--bs-primary);
}
.today-hours {
	display: flex;
	flex-wrap: wrap;
	gap: .5rem;
}
.today-hour {
	display: inline-flex;
	align-items: baseline;
	gap: .35rem;
	min-height: 44px;
	padding: .5rem .75rem;
	border: 1px solid var(--bs-border-color);
	border-radius: var(--bs-border-radius);
	text-decoration: none;
}
