.ebook-hero .story-hero-grid { align-items: start; }
.ebook-hero .story-hero-copy { align-self: center; }
.ebook-hero .ebook-subtitle { margin: 1.2rem 0 0; color: var(--story-green); font-family: 'Work Sans', sans-serif; font-size: clamp(1.15rem, 1.5vw, 1.5rem); font-weight: 600; line-height: 1.4; }
.ebook-intro p { margin: 0 0 .85rem; }
.ebook-intro p:last-child { margin-bottom: 0; }
.ebook-cover .story-hero-image { aspect-ratio: 1 / 1; padding: 1rem; background: #f7faf9; }
.ebook-cover .story-hero-image img { object-fit: contain; object-position: center; }
.ebook-detail-page .insight-related-image img { object-fit: contain; padding: .75rem; }
.ebook-detail-page .story-button { cursor: pointer; font-family: Poppins, sans-serif; }
.ebook-detail-page button.story-button { border-radius: 8px; background: #007b67; color: #fff; }
.ebook-detail-page button.story-button:hover { background: #006653; }
.ebook-detail-page :is(button, summary):focus-visible { outline: 3px solid #3bae91; outline-offset: 4px; }
.ebook-trust-inner { padding-block: 1.2rem; border-bottom: 1px solid var(--story-line); }
.ebook-trust-inner > .story-eyebrow { text-align: center; margin-bottom: 1.25rem; }
.ebook-trust-carousel { width: min(100%, 74rem); margin-inline: auto; }
.ebook-trust-carousel .trust-carousel-track { animation: ebook-trust-scroll 34s linear infinite; }
.ebook-trust-carousel .trust-logo { flex-basis: 12rem; }
.ebook-trust-carousel .trust-logo img { max-width: 9.7rem; max-height: 3.2rem; width: auto; height: auto; object-fit: contain; }
.ebook-trust-carousel .trust-logo-morrisons { padding: .18rem 1rem; }
.ebook-trust-carousel .trust-logo-morrisons img { max-width: 5.25rem; max-height: 5.25rem; transform: translateY(.22rem); }
.ebook-trust-motion { display: flex; align-items: center; justify-content: center; gap: .5rem; margin-top: .8rem; color: var(--story-green); font-size: .75rem; cursor: pointer; }
.ebook-trust-pause { width: 1rem; height: 1rem; accent-color: var(--story-green); }
.ebook-trust:has(.ebook-trust-pause:checked) .trust-carousel-track,
.ebook-trust-carousel:hover .trust-carousel-track { animation-play-state: paused; }
@keyframes ebook-trust-scroll { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
    .ebook-trust-carousel .trust-carousel-track { animation: none; width: 100%; }
    .ebook-trust-carousel .trust-carousel-set { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: .75rem; width: 100%; padding: 1rem; }
    .ebook-trust-carousel [aria-hidden="true"], .ebook-trust-motion,
    .ebook-trust-carousel::before, .ebook-trust-carousel::after { display: none; }
    .ebook-trust-carousel .trust-logo { min-width: 0; padding: .65rem; }
    .ebook-trust-carousel .trust-logo img { max-width: 100%; }
}
.ebook-trust-logos { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1.6rem 3rem; }
.ebook-trust-logos img { display: block; width: 7.5rem; height: 3rem; object-fit: contain; }
.ebook-sidebar .story-sidebar-inner { top: 7rem; }
.ebook-download-card > p:not(.story-eyebrow) { margin: 0 0 1.2rem; font-size: .82rem; line-height: 1.7; }
.ebook-download-card .story-button { width: 100%; }
.ebook-body .ebook-topic-list { gap: .65rem; }
.ebook-preview, .ebook-further, .ebook-faqs { margin-top: 2.5rem; }
.ebook-preview-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.ebook-preview-grid a { display: block; min-width: 0; overflow: hidden; border: 1px solid var(--story-line); border-radius: .75rem; background: #f6faf8; text-decoration: none !important; }
.ebook-preview-grid figure { margin: 0; }
.ebook-preview-grid img { width: 100%; height: auto; margin: 0; border-radius: 0; }
.ebook-preview-grid figcaption { display: flex; justify-content: space-between; padding: .6rem .75rem; font-size: .72rem; color: var(--story-green); }
.ebook-body .ebook-preview-note { font-size: .8rem; color: var(--story-muted); }
.ebook-video { overflow: hidden; border: 1px solid var(--story-line); border-radius: .8rem; background: #f5f9f8; }
.ebook-video iframe { display: block; width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; }
.ebook-reading-download { margin-top: 1.5rem; }
.ebook-faqs details { margin-bottom: .75rem; border: 1px solid var(--story-line); border-radius: .75rem; background: #f8fbfa; }
.ebook-faqs summary { padding: 1.1rem 1.25rem; cursor: pointer; color: var(--story-navy); font-family: 'Work Sans', sans-serif; font-size: 1.05rem; font-weight: 600; line-height: 1.4; }
.ebook-faqs summary::marker { color: var(--story-green); }
.ebook-faqs details > div { padding: 0 1.25rem 1.2rem; font-size: .9rem; line-height: 1.75; }
.ebook-faqs details > div > :last-child { margin-bottom: 0; }
.ebook-download-dialog { position: fixed; inset: 0; width: min(42rem, calc(100% - 2rem)); max-width: none; max-height: calc(100dvh - 2rem); margin: auto; padding: 2rem; overflow: auto; border: 1px solid var(--story-line); border-radius: 1rem; background: #fff; color: var(--story-text); box-shadow: 0 1.5rem 5rem #08234d30; }
.ebook-download-dialog::backdrop { background: #08234d88; backdrop-filter: blur(4px); }
html.ebook-dialog-open { overflow: hidden; }
.ebook-download-dialog h2 { margin: .5rem 2rem .75rem 0; font-size: 2rem; line-height: 1.15; letter-spacing: -.035em; }
.ebook-download-dialog .story-eyebrow { padding-right: 2rem; }
.ebook-dialog-intro { margin: 0 0 1.4rem; font-size: .9rem; line-height: 1.6; }
.ebook-dialog-close { position: absolute; top: .8rem; right: .8rem; width: 2.5rem; height: 2.5rem; display: grid; place-items: center; border: 1px solid var(--story-line); border-radius: 50%; background: #eef7f3; color: var(--story-green); font-size: 1.8rem; line-height: 1; cursor: pointer; }
/* Flatten only the legacy CF7 layout wrappers; field names and settings stay saved in WP. */
.ebook-download-form .wpcf7-form > div[style*="grid"] { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 1rem !important; }
.ebook-download-form .wpcf7-form > div[style*="grid"] > p { display: contents; }
.ebook-download-form .wpcf7-form > div[style*="grid"] br { display: none; }
.ebook-download-form label { display: block; margin: 0; color: var(--story-navy); font-size: .8rem; font-weight: 500; line-height: 1.5; }
.ebook-download-form .wpcf7-form-control-wrap { display: block; margin-top: .4rem; }
.ebook-download-form input:not([type="hidden"]):not([type="checkbox"]):not([type="submit"]) { display: block; width: 100%; min-width: 0; min-height: 2.8rem; padding: .65rem .8rem; border: 1px solid #becfc9; border-radius: .45rem; background: #fff; color: var(--story-navy); font-size: 1rem; }
.ebook-download-form input:focus-visible { outline: 2px solid var(--story-green); outline-offset: 2px; }
.ebook-download-form .policy-accept { margin: 1rem 0; }
.ebook-download-form .wpcf7-list-item { margin: 0; }
.ebook-download-form .wpcf7-list-item label { display: flex; gap: .6rem; align-items: center; }
.ebook-download-form input[type="checkbox"] { width: 1.1rem; height: 1.1rem; accent-color: var(--story-green); }
.ebook-download-form input[type="submit"] { width: 100%; min-height: 3rem; padding: .75rem 1rem; border: 1px solid var(--story-green); border-radius: 8px; background: #007b67; color: #fff; font-family: Poppins, sans-serif; font-size: .85rem; font-weight: 700; cursor: pointer; }
.ebook-download-form .wpcf7-response-output { margin: 1rem 0; font-size: .85rem; }
.ebook-download-form .wpcf7-not-valid-tip { font-size: .75rem; }
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
    .ebook-preview-grid a { transition: transform 180ms ease, box-shadow 180ms ease; }
    .ebook-preview-grid a:hover { transform: translateY(-3px); box-shadow: 0 .7rem 1.4rem #08234d12; }
}
@media (max-width: 960px) {
    .ebook-sidebar { order: 1; }
    .ebook-sidebar .story-sidebar-inner { position: static; grid-template-columns: 1fr 1fr; }
    .ebook-sidebar .story-company-card { grid-row: auto; }
}
@media (max-width: 640px) {
    .ebook-trust-logos { gap: 1rem 1.5rem; }
    .ebook-trust-logos img { width: 6rem; height: 2.5rem; }
    .ebook-sidebar .story-sidebar-inner { grid-template-columns: 1fr; }
    .ebook-preview-grid { grid-template-columns: 1fr; }
    .ebook-preview-grid img { max-height: 28rem; object-fit: contain; }
    .ebook-download-dialog { padding: 1.4rem; }
    .ebook-download-dialog h2 { font-size: 1.65rem; }
    .ebook-download-form .wpcf7-form > div[style*="grid"] { grid-template-columns: 1fr !important; }
}
