/* Site cart: floating cart button, add-to-cart bar on book pages, toast, and the "complete the series" section.
   Each book page sets --cl-accent (its action colour) on <main>; default ChocoLit ink. */
:root { --cl-ink: #2a1d2c; }
.cl-fab { position: fixed; right: 18px; bottom: calc(max(18px, env(safe-area-inset-bottom)) + 64px); z-index: 70; width: 58px; height: 58px; border-radius: 50%;
  background: #fff; color: var(--cl-ink); display: grid; place-items: center; text-decoration: none; box-shadow: 0 10px 26px -10px rgba(0,0,0,.45); border: 2px solid var(--cl-ink); }
.cl-fab[hidden] { display: none; }
.cl-fab svg { width: 26px; height: 26px; fill: currentColor; }
.cl-fab .n { position: absolute; top: -6px; right: -6px; min-width: 24px; height: 24px; padding: 0 6px; border-radius: 999px; background: #c2306f; color: #fff;
  font: 800 13px/24px 'Lexend', system-ui, sans-serif; text-align: center; }
.cl-fab .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
body.has-buybar .cl-fab { bottom: calc(max(18px, env(safe-area-inset-bottom)) + 84px); }
@media (max-width: 760px) { body.has-buybar .cl-fab { bottom: calc(max(18px, env(safe-area-inset-bottom)) + 140px); } }

.cl-buybar { position: fixed; left: 50%; translate: -50% 0; bottom: max(14px, env(safe-area-inset-bottom)); z-index: 65; width: min(620px, calc(100% - 24px));
  display: grid; grid-template-columns: 52px 1fr auto auto; gap: 12px; align-items: center; background: #fff; border-radius: 20px; padding: 9px 10px 9px 9px;
  box-shadow: 0 18px 40px -16px rgba(30,15,40,.45), 0 0 0 1px rgba(30,15,40,.06); font-family: 'Lexend', system-ui, sans-serif; color: var(--cl-ink);
  transition: transform .25s ease, opacity .25s ease; }
.cl-buybar[hidden] { display: grid; transform: translateY(140%); opacity: 0; pointer-events: none; }
.cl-buybar img { width: 52px; height: 52px; object-fit: contain; }
.cl-buybar .t { min-width: 0; } .cl-buybar strong { display: block; font-size: .98rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cl-buybar .t span { font-size: .82rem; color: #6b5a6e; }
.cl-buybar .amz { font-weight: 700; font-size: .9rem; color: var(--cl-ink); text-underline-offset: 3px; padding: 0 6px; }
.cl-buybar button { font: inherit; font-weight: 800; font-size: .98rem; border: 0; border-radius: 999px; padding: 12px 20px; min-height: 46px; cursor: pointer;
  background: var(--cl-accent, #2a1d2c); color: #fff; }
@media (max-width: 480px) { .cl-buybar { grid-template-columns: 44px 1fr auto; } .cl-buybar img { width: 44px; height: 44px; } .cl-buybar .amz { display: none; } }
@media (prefers-reduced-motion: reduce) { .cl-buybar { transition: none; } }

.cl-toast { position: fixed; right: 18px; top: 18px; z-index: 80; display: grid; grid-template-columns: 48px 1fr auto; gap: 12px; align-items: center; width: min(380px, calc(100% - 36px));
  background: #fff; color: var(--cl-ink); border-radius: 18px; padding: 10px 14px 10px 10px; box-shadow: 0 18px 40px -14px rgba(30,15,40,.45); font-family: 'Lexend', system-ui, sans-serif; }
.cl-toast[hidden] { display: none; }
.cl-toast img { width: 48px; height: 48px; object-fit: contain; }
.cl-toast strong { display: block; font-size: .95rem; } .cl-toast span { font-size: .82rem; color: #6b5a6e; }
.cl-toast a { font-weight: 800; color: var(--cl-ink); text-underline-offset: 3px; white-space: nowrap; }

/* Complete the series (book pages) */
.cl-series .cards { margin-top: clamp(26px, 4vw, 40px); display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 2.6vw, 28px); }
.cl-card { background: #fff; border-radius: 26px; padding: 18px 18px 22px; display: flex; flex-direction: column; box-shadow: 0 18px 36px -26px rgba(30,15,40,.5); }
.cl-card img { width: 78%; margin: 4px auto 10px; filter: drop-shadow(0 16px 18px rgba(30,15,40,.25)); }
.cl-card .k { font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #6b5a6e; }
.cl-card h3 { margin-top: 2px; font-family: 'Gochi Hand', cursive; font-weight: 400; font-size: 2rem; line-height: 1; }
.cl-card p { margin-top: 6px; color: #6b5a6e; font-size: .96rem; }
.cl-card .row { margin-top: auto; padding-top: 14px; display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; }
.cl-card button { font: inherit; font-weight: 800; border: 0; border-radius: 999px; padding: 11px 18px; min-height: 44px; cursor: pointer; background: var(--cl-accent, #2a1d2c); color: #fff; }
.cl-card .row a { font-weight: 700; color: inherit; text-underline-offset: 3px; }
.cl-card.best { border: 3px solid var(--cl-accent, #2a1d2c); }
.cl-card .tag { align-self: flex-start; background: var(--cl-accent, #2a1d2c); color: #fff; font-size: .78rem; font-weight: 800; border-radius: 999px; padding: 4px 12px; }
@media (max-width: 820px) { .cl-series .cards { grid-template-columns: 1fr; } }
