/* Book layout – mobile first, two columns from 800px */
.bpb {
	--ink: #1f2a2e; --muted: #5b6b70; --teal: #0f4c4f; --accent: #e9a23b;
	--cream: #faf6ee; --line: #e6e1d6; --serif: Georgia, "Times New Roman", serif;
	color: var(--ink); font-size: 16px; line-height: 1.65;
}
.bpb h1, .bpb h2, .bpb h3 { font-family: var(--serif); font-weight: 400; color: var(--ink); line-height: 1.2; margin: 0 0 .5em; }
.bpb h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.bpb h3 { font-size: 1.1rem; font-weight: 700; font-family: inherit; }
.bpb p { margin: 0 0 1em; }
.bpb a { color: var(--teal); }

.bpb-wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.bpb-narrow { max-width: 760px; }
.bpb-section { padding-block: 48px; }
.bpb-alt { background: var(--cream); }
.bpb-grid { display: grid; gap: 16px; }

.bpb .bpb-kicker { font-size: .72rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--teal); margin-bottom: .6em; font-family: inherit; }
.bpb-meta, .bpb-crumbs { font-size: .82rem; color: var(--muted); }
.bpb-crumbs { margin-bottom: 20px; }
.bpb-strong { font-weight: 700; margin-top: 24px; }
.bpb-more { display: inline-block; margin-top: 12px; font-weight: 600; font-size: .9rem; }

/* Hero */
.bpb-hero { background: var(--cream); padding-block: 32px; }
.bpb-hero__grid { display: grid; gap: 32px; }
.bpb-title { font-size: clamp(2rem, 5vw, 2.9rem); }
.bpb-by { font-size: .9rem; }
.bpb-subtitle { font-weight: 700; font-size: 1.1rem; }
.bpb-formats { font-weight: 600; font-size: .9rem; margin-top: 12px; }
.bpb-hero__media { text-align: center; }
.bpb-cover { width: 100%; max-width: 380px; height: auto; box-shadow: 0 12px 30px rgba(0,0,0,.15); }
.bpb-audio { padding: 16px 0; margin: 12px auto 0; max-width: 380px; }
.bpb-play { position: relative; width: 100%; padding: 15px 18px; margin-bottom: 10px; border: 2px solid #f5c400; border-radius: 8px; background: #111; color: #fff; font-weight: 700; font-size: .85rem; letter-spacing: .04em; text-transform: uppercase; cursor: pointer; box-shadow: 0 0 8px rgba(245,196,0,.25), 0 0 18px rgba(245,196,0,.12); transition: transform .25s; animation: bpb-glow 2.2s ease-in-out infinite; }
.bpb-play::after { content: ""; position: absolute; inset: -6px; border-radius: 13px; border: 1px solid rgba(245,196,0,.5); pointer-events: none; animation: bpb-ring 2.2s ease-in-out infinite; }
.bpb-play:hover, .bpb-play.is-playing { animation: none; transform: translateY(-2px) scale(1.04); box-shadow: 0 0 15px rgba(245,196,0,.8), 0 0 35px rgba(245,196,0,.5), 0 0 60px rgba(245,196,0,.25); }
.bpb-play:active { transform: scale(.98); }
.bpb-play::before { content: "▶  "; }
.bpb-play.is-playing::before { content: "❚❚  "; }

/* Buttons */
.bpb-badge { position: relative; --x: 0; --y: -25; --r: 0; --speed: 2s; }
.bpb-badge span { display: flex; align-items: center; background: var(--badge-bg, var(--cream)); animation: bpb-float var(--speed) ease-in-out infinite; }
.bpb-badge picture { display: contents; }
.bpb-badge img { display: block; flex-shrink: 0; max-width: none; height: 50px; }
.bpb-badge__icon { width: 50px; mix-blend-mode: multiply; }
.bpb-badge__btn { box-sizing: border-box; width: 165px; padding: 7.5px 15px; background: #ff9e13; border-radius: 5px; }
.bpb-badge::before { content: ""; position: absolute; left: 0; bottom: 0; width: 200px; height: 4px; border-radius: 100%; background: #af9d9d; animation: bpb-shadow 2s ease-in-out infinite; }
.bpb-badge:hover { --speed: .1s; --x: 1; --y: -1; --r: -1; }

@keyframes bpb-float { 0%, 100% { transform: translate(calc(var(--x) * -1%), 0) rotate(calc(var(--r) * -1deg)); } 50% { transform: translate(calc(var(--x) * 1%), calc(var(--y) * 1%)) rotate(calc(var(--r) * 1deg)); } }
@keyframes bpb-shadow { 50% { opacity: .2; transform: scaleX(.25); } }
@keyframes bpb-glow { 50% { box-shadow: 0 0 18px rgba(245,196,0,.75), 0 0 40px rgba(245,196,0,.4), 0 0 65px rgba(245,196,0,.18); } }
@keyframes bpb-ring { 50% { transform: scale(1.035); opacity: .85; } }
@media (prefers-reduced-motion: reduce) { .bpb-badge span, .bpb-badge::before, .bpb-play, .bpb-play::after { animation: none; } }
.bpb-buy { display: flex; flex-wrap: wrap; gap: 12px 16px; margin-top: 24px; }
.bpb-btn { display: inline-block; padding: 10px 18px; border-radius: 6px; font-weight: 700; font-size: .9rem; text-decoration: none; border: 1px solid transparent; }
.bpb-btn:hover { filter: brightness(.95); }

/* Jump nav */
.bpb-jump { display: flex; gap: 20px; overflow-x: auto; padding-block: 16px; border-bottom: 1px solid var(--line); white-space: nowrap; font-size: .9rem; font-weight: 600; }
.bpb-jump a { text-decoration: none; }

/* Takeaways */
.bpb-box { border: 2px solid var(--accent); border-radius: 8px; padding: 24px; margin-top: 32px; }
.bpb-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px 32px; }
.bpb-checks li, .bpb-skill h3 { position: relative; padding-left: 26px; }
.bpb-checks li::before, .bpb-skill h3::before { content: "✓"; position: absolute; left: 0; color: var(--teal); font-weight: 700; }

/* Quote band */
.bpb-band { background: var(--teal); color: #fff; margin-top: 48px; }
.bpb-band__grid { display: grid; gap: 24px; }
.bpb-band h2, .bpb-band .bpb-kicker { color: #fff; }
.bpb-band blockquote, .bpb-band blockquote p { color: #fff; }
.bpb-band blockquote { margin: 0; border: 0; padding: 0; font-family: var(--serif); font-size: 1.45rem; font-style: normal; line-height: 1.4; }
.bpb-band cite { display: block; font-size: .8rem; font-style: normal; opacity: .75; margin-top: 12px; font-family: system-ui, sans-serif; }

/* Cards */
.bpb-card { --badge-bg: #fff; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 20px; margin: 0; }
.bpb-review blockquote { margin: 0 0 16px; padding: 0; border: 0; font-style: normal; color: var(--ink); font-family: var(--serif); font-size: 1.2rem; }
.bpb-review figcaption { font-size: .82rem; }
.bpb-review span { display: block; color: var(--muted); }
.bpb-skill p { font-size: .92rem; color: var(--muted); margin: 0; }
.bpb-prose h3 { margin-top: 1.6em; }

/* Author */
.bpb-author { display: flex; gap: 20px; align-items: flex-start; }
.bpb-avatar { flex: 0 0 64px; height: 64px; border-radius: 50%; background: var(--cream); border: 1px solid var(--line); display: grid; place-items: center; font-weight: 700; color: var(--teal); }

/* FAQs */
.bpb-faqs { display: grid; gap: 24px; }
.bpb-faqs details { border-bottom: 1px solid var(--line); padding: 14px 0; }
.bpb-faqs summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.bpb-faqs summary::-webkit-details-marker { display: none; }
.bpb-faqs summary::after { content: "+"; font-size: 1.3rem; line-height: 1; }
.bpb-faqs details[open] summary::after { content: "–"; }
.bpb-faqs details p { margin: 10px 0 0; color: var(--muted); }

/* Closing CTA + ebook */
.bpb-ebook { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding-block: 24px 40px; }
.bpb-ebook span { color: var(--muted); }
.bpb .bpb-ebook .bpb-btn { background: #fff; color: var(--teal); border-color: var(--teal); }
.bpb-more--tight { margin-top: 0; }
.bpb-cta { display: grid; gap: 16px; align-items: center; }

/* Series */
.bpb-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 12px; margin-bottom: 20px; }
.bpb-book { display: flex; gap: 16px; text-decoration: none; color: inherit; }
.bpb-book .bpb-kicker { margin-bottom: .3em; }
.bpb-book > img { width: 90px; aspect-ratio: 2 / 3; object-fit: cover; flex-shrink: 0; }
.bpb-book__intro { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; } .bpb-book p { font-size: .9rem; color: var(--muted); margin: 0; }

@media (min-width: 800px) {
	.bpb-hero { padding-block: 48px; }
	.bpb-hero__grid { grid-template-columns: 1.5fr 1fr; align-items: start; }
	.bpb-grid, .bpb-checks { grid-template-columns: 1fr 1fr; }
	.bpb-band__grid, .bpb-faqs { grid-template-columns: 1fr 1.5fr; }
	.bpb-band__grid { align-items: center; }
	.bpb-cta { grid-template-columns: 1.5fr 1fr; }
	.bpb-cta .bpb-buy { justify-content: flex-end; }
}

/* "Book style" page template (testimonials) – content comes from blocks with these classes */
.bpb-page > *, .bpb-page .wp-block-group { margin-block: 0; }
.bpb-page .wp-block-group__inner-container { display: contents; }
.bpb-page .bpb-hero__grid { align-items: center; }
.bpb-page .wp-block-image, .bpb-page .wp-block-embed { margin: 0; }
.bpb-media { display: grid; gap: 12px; justify-items: center; }
.bpb-stamp img { width: 200px; height: auto; }
.bpb-arrows { display: flex; justify-content: space-between; width: 100%; max-width: 420px; }
.bpb-arrows img { width: 56px; height: auto; mix-blend-mode: multiply; }
.bpb-arrows figure:last-child img { transform: scaleX(-1); }
.bpb-video { width: 100%; max-width: 300px; border-radius: 8px; overflow: hidden; box-shadow: 0 12px 30px rgba(0,0,0,.15); }
.bpb-author .wp-block-image img { width: 140px; height: 140px; object-fit: cover; border-radius: 50%; }
.bpb-author .bpb-checks { margin-block: 12px 16px; grid-template-columns: 1fr; }
.bpb-icons { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 16px; }
.bpb-author .bpb-icons img { width: 36px; height: 36px; object-fit: contain; border-radius: 0; }
@media (max-width: 599px) { .bpb-author { flex-direction: column; } }
.bpb-video .wp-block-embed__wrapper { position: relative; aspect-ratio: 9 / 16; } /* vertical video */
.bpb-video .wp-block-embed__wrapper::before { display: none; }
.bpb-video .wp-block-embed__wrapper > * { position: absolute; inset: 0; width: 100%; height: 100%; }
.bpb-book--feature { align-items: center; flex-wrap: wrap; }
.bpb-book--feature > :first-child { width: 140px; flex-shrink: 0; }
.bpb-book--feature > :first-child img { width: 100%; height: auto; }
.bpb-book--feature > div { flex: 1 1 260px; }
.bpb-book--feature h3 a { color: inherit; text-decoration: none; }

/* Shared refinements from the Resilient Children handoff (all book pages) */
.bpb [hidden] { display: none !important; }
.bpb [id] { scroll-margin-top: 24px; }
.bpb a:focus-visible, .bpb button:focus-visible, .bpb summary:focus-visible { outline: 3px solid #b27310; outline-offset: 4px; }
.bpb-jump { flex-wrap: wrap; white-space: normal; overflow: visible; gap: 4px 22px; }
.bpb-jump a { display: flex; align-items: center; min-height: 44px; }
.bpb-play { min-height: 48px; }
.bpb-video-mount iframe { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; margin-bottom: 10px; border-radius: 6px; }
.bpb-review-note { margin-top: 16px; }
.bpb-detail-stack { display: flex; flex-direction: column; }
.bpb-skill > .bpb-kicker { margin-bottom: .4em; }
@media (min-width: 800px) { .bpb-inside .bpb-skill:last-child:nth-child(odd) { grid-column: 1 / -1; } }
@media (max-width: 799px) {
	.bpb-inside { order: -1; }
	.bpb-hero__grid { display: flex; flex-direction: column; gap: 12px; }
	.bpb-hero-copy { display: contents; }
	.bpb-crumbs { order: 0; } .bpb-hero-copy > .bpb-kicker { order: 1; } .bpb-title { order: 2; } .bpb-by { order: 3; } .bpb-subtitle { order: 4; }
	.bpb-hero__media { order: 5; width: 100%; } .bpb-intro { order: 6; } .bpb-hero-copy > .bpb-buy { order: 7; } .bpb-formats { order: 8; } .bpb-hero-copy > .bpb-meta { order: 9; }
	.bpb-cover { max-width: 280px; }
	.bpb-section { padding-block: 36px; }
}

/* Book shelf ([bpb_shelf]) – centred series sections with a cover grid */
.bpb-shelf { text-align: center; }
.bpb-shelf + .bpb-shelf { border-top: 1px solid var(--line); }
.bpb .bpb-shelf h1, .bpb .bpb-shelf h2 { font-family: inherit; font-weight: 600; font-size: clamp(1.5rem, 3vw, 1.9rem); }
.bpb-shelf__sub { font-weight: 700; font-size: 1.05rem; }
.bpb-shelf__intro { max-width: 760px; margin-inline: auto; color: var(--muted); font-size: .92rem; }
.bpb-shelf__grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 32px 24px; margin-top: 32px; }
.bpb-shelf__book { flex: 0 1 calc(50% - 12px); color: var(--ink) !important; text-decoration: none; font-size: .85rem; line-height: 1.4; }
.bpb-shelf__book img { display: block; width: 100%; max-width: 200px; height: auto; margin: 0 auto 12px; box-shadow: 0 6px 16px rgba(0,0,0,.15); transition: transform .2s; }
.bpb-shelf__book:hover img { transform: translateY(-4px); }
.bpb-shelf__book span { display: block; max-width: 220px; margin-inline: auto; }
.bpb .bpb-shelf__more { margin: 48px 0 0; }
.bpb .bpb-shelf__more .bpb-btn { background: #f47b20; color: #fff; text-transform: uppercase; letter-spacing: .04em; font-size: .8rem; padding: 12px 28px; border-radius: 0; }
@media (min-width: 800px) { .bpb-shelf__book { flex-basis: calc(25% - 18px); } }
