/* ===== Fonty Books: block styles ===== */

.fb-placeholder {
	padding: 0.75rem 1rem;
	border: 1px dashed currentColor;
	font-size: 0.85rem;
	opacity: 0.6;
}

/* ----- Single book layout (template classes) ----- */
.fb-single__top {
	gap: 3rem;
	align-items: flex-start !important;
}
.fb-single__cover {
	flex: 0 0 34%;
	margin: 0;
}
.fb-single__cover img {
	box-shadow: 0 6px 20px rgb(0 0 0 / 0.18);
}
.fb-single__info {
	flex: 1 1 auto;
	min-width: 0;
}
.fb-single__info .wp-block-post-title {
	margin-bottom: 0;
}
@media (max-width: 700px) {
	.fb-single__top {
		flex-wrap: wrap !important;
		gap: 1.5rem;
	}
	.fb-single__cover {
		flex-basis: 100%;
		max-width: 18rem;
		margin-inline: auto;
	}
}

/* ----- Book Details ----- */
.fb-details > * {
	margin-block: 0 0.35rem;
}
.fb-details__subtitle {
	font-size: 1.3em;
	font-style: italic;
	line-height: 1.3;
}
.fb-details__byline {
	font-weight: 600;
}
.fb-details__meta {
	margin: 1rem 0 0;
	font-size: 0.9rem;
}
.fb-details__meta div {
	display: flex;
	gap: 0.5rem;
}
.fb-details__meta dt {
	font-weight: 600;
}
.fb-details__meta dt::after {
	content: ":";
}
.fb-details__meta dd {
	margin: 0;
}

/* ----- Buy buttons ----- */
.fb-buy {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
}
/* Fixed size so site-wide and theme button styles can't change these.
   Selectors are .fb-buy + the theme's own outline selector so they always win. */
.fb-buy .wp-block-button .wp-block-button__link,
.fb-buy .wp-block-button.is-style-outline .wp-block-button__link {
	font-size: 1rem;
	line-height: 1.3;
	padding: 0.75em 1.4em;
	border: 2px solid transparent; /* same box size for filled and outline */
}
/* "Read free": a real outline so it reads as the secondary action */
.fb-buy .wp-block-button.is-style-outline .wp-block-button__link {
	background: transparent;
	border-color: currentColor;
	color: #32373c;
}
/* Hover/focus: Care Think pink with white text (theme default hover is pale pink on off-white, unreadable) */
.fb-buy .wp-block-button .wp-block-button__link:hover,
.fb-buy .wp-block-button .wp-block-button__link:focus-visible,
.fb-buy .wp-block-button.is-style-outline .wp-block-button__link:hover,
.fb-buy .wp-block-button.is-style-outline .wp-block-button__link:focus-visible {
	background: var(--wp--preset--color--custom-care-think-pink, #c2349a);
	border-color: var(--wp--preset--color--custom-care-think-pink, #c2349a);
	color: #fff;
}

/* ----- Reviews ----- */
.fb-reviews__item {
	margin-block: 1.5rem;
}
.fb-reviews__item cite {
	display: block;
	margin-top: 0.5rem;
	font-size: 0.9rem;
	font-style: normal;
}
.fb-reviews__item cite::before {
	content: "— ";
}

/* ----- Related articles (on a book) ----- */
.fb-related__list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
	gap: 1.5rem;
	margin: 0;
	padding: 0;
	list-style: none;
}
.fb-related__thumb img {
	display: block;
	width: 100%;
	aspect-ratio: 16 / 9;
	object-fit: cover;
}
.fb-related__title {
	margin: 0.6rem 0 0.2rem;
	font-size: 1.1rem;
	line-height: 1.3;
}
.fb-related__date {
	font-size: 0.85rem;
	opacity: 0.8;
}

/* ----- Related books (on an article) ----- */
.fb-books__heading {
	font-size: 1.1rem;
}
.fb-books__list {
	display: flex;
	flex-wrap: wrap;
	gap: 1.25rem;
	margin: 0;
	padding: 0;
	list-style: none;
}
.fb-books__item a {
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
	width: 8rem;
	text-decoration: none;
}
.fb-books__cover {
	width: 100%;
	height: auto;
	aspect-ratio: 2 / 3;
	object-fit: cover;
	box-shadow: 0 3px 10px rgb(0 0 0 / 0.15);
}
.fb-books__title {
	font-weight: 600;
	line-height: 1.25;
}
.fb-books__year {
	font-size: 0.85rem;
	opacity: 0.8;
}
