/* ============================================================
   Book product pages — sticky buy panel + tabbed content
   Used by book-textbook, book-bereavement, book-everything-guide,
   pocket-deck. 2026-10-12
   ============================================================ */

.bp-wrap { padding: 30px 0 46px; }
.bp-crumb { font-size: 0.88rem; margin: 0 0 16px; }
.bp-grid { display: grid; gap: 30px; align-items: start; }
@media (min-width: 900px) { .bp-grid { grid-template-columns: 1fr 360px; gap: 48px; } }

/* ---- Buy panel ---- */
.bp-buy { background: var(--cream); border: 1px solid rgba(27,42,71,.10); border-radius: 16px;
          padding: 22px; box-shadow: 5px 5px 0 rgba(228,69,135,.12); }
@media (min-width: 900px) { .bp-buy { position: sticky; top: 92px; } }
.bp-buy-cover { margin: 0 0 16px; }
.bp-buy-cover img { width: 100%; height: auto; display: block; border-radius: 8px; aspect-ratio: 2/3;
                    object-fit: cover; box-shadow: 0 10px 26px rgba(27,42,71,.22); }
.bp-opt { display: block; border: 2px solid rgba(27,42,71,.12); border-radius: 12px; padding: 13px 15px;
          margin-bottom: 10px; text-decoration: none; background: #fff;
          transition: border-color .15s, background .15s; }
.bp-opt:hover { border-color: var(--berry-accessible, #B82E66); background: rgba(243,181,207,.10); text-decoration: none; }
.bp-opt:focus-visible { outline: 3px solid var(--blush); outline-offset: 2px; }
.bp-opt-best { border-color: var(--berry-accessible, #B82E66); background: rgba(243,181,207,.14); }
.bp-opt-tag { display: inline-block; font-size: .68rem; letter-spacing: .09em; text-transform: uppercase;
              font-weight: 700; color: #fff; background: var(--berry-accessible, #B82E66);
              padding: 3px 9px; border-radius: 999px; margin-bottom: 7px; }
.bp-opt-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.bp-opt-name { font-family: var(--serif-heading); font-weight: 700; font-size: 1.02rem; color: var(--ink); line-height: 1.25; }
.bp-opt-price { font-weight: 700; font-size: 1.14rem; color: var(--deep-berry); white-space: nowrap; }
.bp-opt-note { font-size: .83rem; color: var(--muted); margin: 5px 0 0; line-height: 1.4; }
.bp-fine { font-size: .8rem; color: var(--muted); margin: 14px 0 0; line-height: 1.5; text-align: center; }

/* ---- Spec strip ---- */
.bp-specs { display: flex; flex-wrap: wrap; margin: 18px 0 20px;
            border: 1px solid rgba(27,42,71,.10); border-radius: 12px; overflow: hidden; background: var(--cream); }
.bp-spec { flex: 1 1 86px; padding: 12px 10px; text-align: center; border-right: 1px solid rgba(27,42,71,.08); }
.bp-spec:last-child { border-right: 0; }
.bp-spec b { display: block; font-family: var(--serif-heading); font-size: 1.22rem; color: var(--deep-berry); line-height: 1.1; }
.bp-spec span { display: block; font-size: .74rem; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }

/* ---- Callout ---- */
.bp-note { padding: 13px 17px; border-radius: 10px; font-size: .93rem; line-height: 1.55; margin: 0 0 20px; }
.bp-note-warn { background: var(--takeaway-bg, rgba(212,171,45,.12)); border-left: 4px solid var(--gold-deep, #B8912A); }

/* ---- Tabs ---- */
.bp-tabs { display: flex; gap: 4px; flex-wrap: wrap; border-bottom: 2px solid rgba(27,42,71,.10); margin-bottom: 20px; }
.bp-tab { appearance: none; border: 0; background: none; cursor: pointer; font: inherit;
          padding: 10px 16px; font-size: .95rem; font-weight: 600; color: var(--muted);
          border-bottom: 3px solid transparent; margin-bottom: -2px; border-radius: 6px 6px 0 0; }
.bp-tab:hover { color: var(--deep-berry); background: rgba(243,181,207,.12); }
.bp-tab[aria-selected="true"] { color: var(--deep-berry); border-bottom-color: var(--berry-accessible, #B82E66); }
.bp-tab:focus-visible { outline: 3px solid var(--blush); outline-offset: 2px; }
.bp-panel[hidden] { display: none; }
.bp-panel { animation: bpIn .22s ease; }
@keyframes bpIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }

/* ---- Content rows ---- */
.bp-units { display: grid; gap: 9px; }
.bp-unit { display: grid; grid-template-columns: 42px 1fr; gap: 14px; align-items: start;
           padding: 13px 15px; background: var(--cream); border-radius: 10px; border: 1px solid rgba(27,42,71,.07); }
.bp-unit-n { font-family: var(--serif-heading); font-weight: 700; font-size: 1.2rem; color: var(--berry-rose); }
.bp-unit h4 { margin: 0 0 3px; font-size: 1rem; color: var(--ink); }
.bp-unit p { margin: 0; font-size: .91rem; line-height: 1.5; color: var(--ink); }
.bp-quote { margin: 20px 0 0; padding: 16px 20px; border-left: 4px solid var(--blush);
            font-family: var(--serif-heading); font-style: italic; font-size: 1.06rem; line-height: 1.5; color: var(--ink); }
.bp-isbn { font-size: .8rem; color: var(--muted); margin-top: 16px; }
.bp-video { border-radius: 12px; overflow: hidden; aspect-ratio: 16/9; background: var(--navy); }
.bp-video iframe { width: 100%; height: 100%; border: 0; display: block; }

@media (prefers-reduced-motion: reduce) { .bp-panel { animation: none; } }

/* ============================================================
   Library grid — All Resources page. One card system.
   ============================================================ */
.lib { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.lib-card { display: flex; flex-direction: column; background: #fff;
  border: 1px solid rgba(27,42,71,.10); border-radius: 14px; overflow: hidden;
  box-shadow: 4px 4px 0 rgba(228,69,135,.10); transition: transform .15s ease, box-shadow .15s ease; }
.lib-card:hover { transform: translateY(-3px); box-shadow: 6px 8px 0 rgba(228,69,135,.16); }
.lib-cover { display: block; background: var(--cream); }
.lib-cover img { width: 100%; height: auto; display: block; aspect-ratio: 2/3; object-fit: cover; }
.lib-body { padding: 15px 16px 16px; display: flex; flex-direction: column; flex: 1; }
.lib-tag { font-size: .68rem; letter-spacing: .09em; text-transform: uppercase; font-weight: 700;
  color: var(--deep-berry); margin: 0 0 5px; }
.lib-title { font-family: var(--serif-heading); font-size: 1.08rem; line-height: 1.25; margin: 0 0 6px; }
.lib-title a { color: var(--ink); text-decoration: none; }
.lib-title a:hover { color: var(--deep-berry); }
.lib-desc { font-size: .88rem; line-height: 1.5; color: var(--muted); margin: 0 0 12px; }
.lib-foot { margin-top: auto; }
.lib-price { font-weight: 700; color: var(--deep-berry); font-size: 1.05rem; margin: 0 0 10px; }
.lib-price small { font-weight: 400; color: var(--muted); font-size: .8rem; }
.lib-btns { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.lib-buy { flex: 1 1 auto; text-align: center; background: var(--berry-accessible, #B82E66); color: #fff;
  border-radius: 999px; padding: 9px 14px; font-size: .88rem; font-weight: 600; text-decoration: none; white-space: nowrap; }
.lib-buy:hover { background: #9C2456; color: #fff; text-decoration: none; }
.lib-qv { appearance: none; border: 1px solid rgba(27,42,71,.18); background: #fff; cursor: pointer;
  border-radius: 999px; padding: 9px 13px; font: inherit; font-size: .84rem; color: var(--ink); white-space: nowrap; }
.lib-qv:hover { border-color: var(--berry-accessible, #B82E66); color: var(--deep-berry); }
.lib-qv:focus-visible, .lib-buy:focus-visible { outline: 3px solid var(--blush); outline-offset: 2px; }
.lib-free .lib-price { color: var(--sage, #4E7C68); }
.lib-free .lib-buy { background: var(--sage, #4E7C68); }
.lib-free .lib-buy:hover { background: #3C6151; }
