/* ==========================================================
   ALL MY BOOKS WIDGET — BASE STRUCTURAL STYLES
   Colors, gradients, typography and spacing are mostly driven
   by Elementor's Style tab controls (see
   widgets/class-all-books-widget.php). This file only holds
   structure, layout and responsive rules.
   ========================================================== */

.abk {
	overflow-x: clip;
}

.abk * {
	box-sizing: border-box;
}

.abk img {
	max-width: 100%;
	display: block;
}

/* ---------------- SECTION / HEADER ---------------- */

.abk-section {
	padding: 96px 24px;
}

.abk-header {
	max-width: 640px;
	margin: 0 auto;
	text-align: center;
}

.abk-header__eyebrow {
	font-size: 0.9rem;
	letter-spacing: 0.02em;
	margin: 0 0 10px;
}

.abk-header__title {
	font-size: clamp(2.2rem, 5vw, 3.4rem);
	line-height: 1.1;
	margin: 0 0 18px;
}

.abk-header__lede {
	font-size: 1.05rem;
	line-height: 1.75;
}

/* ---------------- LIST ---------------- */

.abk-list-wrap {
	width: 100%;
}

.abk-list {
	max-width: 1088px;
	margin: 0 auto;
	padding: 72px 24px 96px;
	display: flex;
	flex-direction: column;
	gap: 80px;
}

.abk-book {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 32px;
	padding-bottom: 80px;
	border-bottom: 1px solid rgba(34, 19, 41, 0.14);
}

.abk-list > .abk-book:last-child {
	border-bottom: none;
	padding-bottom: 0;
}

.abk-book__figure {
	flex: none;
	width: 100%;
	max-width: 400px;
	margin: 0 auto;
}

.abk-book__cover {
	width: 100%;
	aspect-ratio: 3 / 4.4;
	border: 1.5px dashed #4A3A52;
	border-radius: 6px;
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	padding: 16px;
	overflow: hidden;
}

.abk-book__cover img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.abk-book__cover-hint {
	font-size: 0.85rem;
	max-width: 9rem;
}

.abk-book__body {
	width: 100%;
	max-width: 640px;
	margin: 0 auto;
	min-width: 0;
}

.abk-book__title {
	font-size: 1.9rem;
	line-height: 1.2;
	margin: 0 0 16px;
}

.abk-book__blurb {
	font-size: 1rem;
	line-height: 1.75;
	max-width: 60ch;
	margin-bottom: 24px;
}

.abk-book__blurb p:first-child {
	margin-top: 0;
}

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

/* ---------------- ACTIONS / BUTTONS ---------------- */

.abk-book__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin-bottom: 32px;
}

.abk-btn {
	--abk-btn-start: #5A2A74;
	--abk-btn-end: #BC5130;

	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 0.95rem;
	text-decoration: none;
	padding: 12px 24px;
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.abk-btn--primary {
	background: linear-gradient(100deg, var(--abk-btn-start), var(--abk-btn-end));
}

.abk-btn--primary:hover,
.abk-btn--primary:focus-visible {
	transform: translateY(-1px);
	box-shadow: 0 12px 24px -10px rgba(90, 42, 116, 0.45);
}

.abk-btn--secondary {
	background: transparent;
	border: 1.5px solid currentColor;
}

.abk-btn--secondary:hover,
.abk-btn--secondary:focus-visible {
	background: rgba(90, 42, 116, 0.08);
}

/* ---------------- RATING BARS ---------------- */

.abk-book__bars {
	display: flex;
	flex-direction: column;
	gap: 18px;
	max-width: 24rem;
}

.abk-bar__label {
	display: flex;
	justify-content: space-between;
	font-size: 0.85rem;
	font-weight: bold;
	margin-bottom: 6px;
}

.abk-bar__track {
	width: 100%;
	height: 10px;
	border-radius: 999px;
	overflow: hidden;
}

.abk-bar__fill {
	height: 100%;
	border-radius: 999px;
}

/* ---------------- RESPONSIVE ---------------- */

@media (max-width: 780px) {
	.abk-section {
		padding: 72px 20px;
	}

	.abk-list {
		padding: 56px 20px 72px;
	}

	.abk-book {
		gap: 24px;
		padding-bottom: 56px;
	}

	.abk-book__figure {
		max-width: 260px !important;
	}
}

/* ---------------- ACCESSIBILITY ---------------- */

@media (prefers-reduced-motion: reduce) {
	.abk-btn {
		transition: none;
	}
}

.abk :focus-visible {
	outline: 2px solid #BC5130;
	outline-offset: 2px;
}
