/* Clerq book store components. Layered on service-pages.css + visual-system.css. */

/* ---------- Shared store layout ---------- */
.pg{color:var(--green);border-color:rgba(45,212,160,.25);background:var(--green-bg)}
.pb{color:var(--blue);border-color:rgba(91,156,245,.25);background:rgba(91,156,245,.1)}
/* Hero tokens carried over verbatim from the original index.html hero */
.store-hero{padding:calc(var(--nav) + 72px) 0 72px}
.store-hero .hero-grid{display:grid;grid-template-columns:1fr 1.15fr;gap:48px;align-items:center}
.store-hero h1{font-family:var(--serif);font-size:clamp(2.8rem,6vw,4.8rem);font-weight:400;line-height:1.06;letter-spacing:-.02em;margin:20px 0 18px}
.store-hero h1 em{font-style:italic}
.store-hero .lead{font-size:clamp(1.15rem,1.6vw,1.45rem);font-family:var(--serif);font-weight:400;color:var(--text);line-height:1.35;letter-spacing:-.01em;max-width:560px;margin-bottom:20px}
.store-hero .sub{font-size:1.05rem;color:var(--text2);line-height:1.75;max-width:480px;margin-bottom:36px}
.store-hero .sub strong{color:var(--text);font-weight:600}
.hero-actions{display:flex;gap:12px;flex-wrap:wrap;align-items:center;margin-bottom:20px}
.hero-note{font-size:.78rem;color:var(--text3);margin-top:8px;line-height:1.5}
.format-line{display:flex;gap:8px;flex-wrap:wrap;margin-top:20px}
.format-line span{font-family:var(--mono);font-size:.62rem;color:var(--text3);text-transform:uppercase;letter-spacing:.06em;border:1px solid var(--border);border-radius:100px;padding:5px 12px}
@media(max-width:900px){.store-hero{padding-top:calc(var(--nav) + 44px);padding-bottom:48px}.store-hero .hero-grid{grid-template-columns:1fr;gap:40px}}

/* Section rhythm carried over verbatim from the original index.html */
.sec{padding:48px 0;border-top:1px solid var(--border)}
@media(max-width:768px){.sec{padding:32px 0}}
.sh{margin-bottom:14px}.sh-c{text-align:center}
.st{font-family:var(--serif);font-size:clamp(2.2rem,4.5vw,3.2rem);font-weight:400;line-height:1.1;letter-spacing:-.015em;margin-bottom:14px}
.ss{font-size:1rem;color:var(--text2);max-width:520px;line-height:1.7}
.sh-c .ss{margin:0 auto}

/* ---------- Typographic book covers (placeholder art, trivial to restyle) ---------- */
.cover{aspect-ratio:5/7.6;width:100%;max-width:340px;display:flex;flex-direction:column;border-radius:6px;overflow:hidden;box-shadow:0 32px 64px rgba(0,0,0,.5),0 2px 0 rgba(255,255,255,.05) inset;user-select:none}
/* Real cover artwork. The <img> carries width="640" height="1024" so the box is
   reserved before the file loads (no layout shift), but that height attribute is
   a presentational hint that wins unless CSS overrides it - without this rule
   every cover renders 1024px tall regardless of its width, stretching the art to
   roughly three times its true height. height:auto hands sizing back to the
   inline aspect-ratio, which is the artwork's real 1:1.6. The .cover ratio above
   (5/7.6) is for the retired CSS mock covers and must not apply to the images. */
img.cover{height:auto;object-fit:contain;background:#f2ede4}
.cover-band-top,.cover-band-bottom{flex:0 0 21%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;padding:10px 18px;text-align:center}
.cover-mid{flex:1;background:#ece9e1;color:#15151e;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:18px 22px;gap:8px}
.cover-imprint{font-family:var(--mono);font-size:.55rem;letter-spacing:.14em;text-transform:uppercase}
.cover-series{font-family:var(--mono);font-size:.55rem;letter-spacing:.12em;text-transform:uppercase;color:#65625b}
.cover-title{font-family:var(--serif);font-size:clamp(1.5rem,2.4vw,2.1rem);line-height:1.08;letter-spacing:-.01em}
.cover-sub{font-size:.68rem;line-height:1.5;color:#514e48;max-width:24ch}
.cover-logo{font-weight:700;font-size:.85rem;letter-spacing:-.03em}
.cover-logo i{font-style:normal;opacity:.9}
.cover-flagship .cover-band-top,.cover-flagship .cover-band-bottom{background:var(--accent);color:#2b0f08}
.cover-e1 .cover-band-top,.cover-e1 .cover-band-bottom{background:var(--blue);color:#0a1a2e}
.cover-e2 .cover-band-top,.cover-e2 .cover-band-bottom{background:var(--green);color:#0c1f19}
.cover-e3 .cover-band-top,.cover-e3 .cover-band-bottom{background:#9b7df0;color:#1a0f33}
.cover-sm{max-width:200px;box-shadow:0 18px 36px rgba(0,0,0,.4)}
.cover-sm .cover-title{font-size:1.05rem}
.cover-sm .cover-sub{font-size:.56rem}
.cover-sm .cover-imprint,.cover-sm .cover-series{font-size:.46rem}
.cover-sm .cover-mid{padding:12px 14px;gap:5px}
.cover-sm .cover-band-top,.cover-sm .cover-band-bottom{padding:7px 12px}
.cover-sm .cover-logo{font-size:.68rem}
.hero-cover-wrap{display:grid;place-items:center;position:relative}
.hero-cover-wrap .cover{transform:rotate(2deg);transition:transform .5s var(--ease)}
.hero-cover-wrap .cover:hover{transform:rotate(0)}
@media(prefers-reduced-motion:reduce){.hero-cover-wrap .cover{transform:none}}

/* ---------- Edition picker ---------- */
.editions-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;margin-top:32px}
@media(max-width:1020px){.editions-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:560px){.editions-grid{grid-template-columns:1fr}}
.edition-card{display:flex;flex-direction:column;gap:14px;padding:28px 24px;background:var(--bg3);border:1px solid var(--border);border-radius:var(--r);transition:border-color .3s,transform .3s var(--ease)}
.edition-card:hover{border-color:var(--border2);transform:translateY(-3px)}
.edition-card.is-flagship{border-color:rgba(217,85,64,.4);background:linear-gradient(170deg,var(--bg3),rgba(217,85,64,.05))}
.edition-cover{display:grid;place-items:center;padding:6px 0 2px}
.edition-flag{font-family:var(--mono);font-size:.58rem;color:var(--accent);text-transform:uppercase;letter-spacing:.08em}
.edition-flag.muted{color:var(--text3)}
.edition-card h3{font-size:1.05rem;font-weight:700;letter-spacing:-.015em;line-height:1.25}
.edition-card .edition-d{font-size:.82rem;color:var(--text2);line-height:1.6;flex:1}
.edition-price{font-family:var(--serif);font-size:1.7rem;letter-spacing:-.02em}
.edition-price small{font-family:var(--sans);font-size:.7rem;color:var(--text3);display:block;margin-top:2px;font-weight:500}
.edition-actions{display:flex;flex-direction:column;gap:8px}
.edition-actions .text-link{font-size:.78rem;color:var(--text2);text-align:center}
.edition-actions .text-link:hover{color:var(--accent)}

/* ---------- What's inside ---------- */
.inside-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1px;background:var(--border);border:1px solid var(--border);border-radius:var(--r);overflow:hidden;margin-top:28px}
@media(max-width:860px){.inside-grid{grid-template-columns:1fr}}
.inside-cell{padding:32px 24px;background:var(--bg3);transition:background .3s}
.inside-cell:hover{background:var(--surface)}
.inside-n{font-family:var(--mono);font-size:.65rem;color:var(--accent);letter-spacing:.05em;margin-bottom:14px}
.inside-cell h3{font-size:1.25rem;font-weight:700;line-height:1.2;letter-spacing:-.015em;margin-bottom:10px}
.inside-cell p{font-size:.85rem;color:var(--text2);line-height:1.65}

/* ---------- Sample extract ---------- */
.extract-wrap{display:grid;grid-template-columns:.85fr 1.15fr;gap:48px;align-items:center}
@media(max-width:900px){.extract-wrap{grid-template-columns:1fr;gap:32px}}
.extract-page{background:#ece9e1;color:#211f1c;border-radius:6px;padding:40px 44px;box-shadow:0 28px 56px rgba(0,0,0,.45);position:relative}
@media(max-width:560px){.extract-page{padding:28px 24px}}
.extract-kicker{font-family:var(--mono);font-size:.58rem;letter-spacing:.12em;text-transform:uppercase;color:#67645d;margin-bottom:14px}
.extract-page h3{font-family:var(--serif);font-size:1.5rem;font-weight:400;line-height:1.15;letter-spacing:-.01em;margin-bottom:16px;color:#15151e}
.extract-page p{font-size:.88rem;line-height:1.75;color:#3c3934;margin-bottom:14px;max-width:58ch}
.extract-page p:last-of-type{margin-bottom:0}
.extract-foot{display:flex;justify-content:space-between;margin-top:24px;padding-top:14px;border-top:1px solid rgba(0,0,0,.12);font-family:var(--mono);font-size:.56rem;letter-spacing:.1em;text-transform:uppercase;color:#67645d}
/* Sample extract: the before/after pair from the book's meeting-notes
   walkthrough. Every colour below was contrast-checked against the composited
   panel background rather than eyeballed - lowest is 5.83:1. */
.extract-notes{font-family:var(--mono);font-size:.7rem;line-height:1.75;color:#4a4740;background:rgba(0,0,0,.045);border-left:2px solid rgba(0,0,0,.18);padding:12px 14px;margin:0 0 18px}
.extract-ba{display:grid;gap:12px}
/* Scoped to .extract-ba> so they outrank the shared rule below. The shorthand
   "border-left:2px solid" resets the colour to currentcolor, and at 0,1,1 it
   beats a bare .extract-bad at 0,1,0 - which silently painted both borders in
   the body text colour instead of red and green. */
.extract-ba>div{padding:12px 14px;border-left-width:2px;border-left-style:solid;border-radius:0 3px 3px 0}
.extract-ba>.extract-bad{border-left-color:#b3402c;background:rgba(179,64,44,.06)}
.extract-ba>.extract-good{border-left-color:#2f6f4f;background:rgba(47,111,79,.06)}
.extract-ba-l{display:block;font-family:var(--mono);font-size:.55rem;letter-spacing:.1em;text-transform:uppercase;margin-bottom:8px;font-weight:600}
.extract-bad .extract-ba-l{color:#8f3323}
.extract-good .extract-ba-l{color:#265c41}
.extract-ba p{font-size:.83rem;line-height:1.65;margin-bottom:8px;max-width:none}
.extract-ba-note{font-size:.75rem;color:#57534b;margin-bottom:0}
.extract-copy h2{font-family:var(--serif);font-size:clamp(1.8rem,3.4vw,2.6rem);font-weight:400;line-height:1.15;letter-spacing:-.015em;margin:12px 0 16px}
.extract-copy p{font-size:.95rem;color:var(--text2);line-height:1.75;margin-bottom:14px;max-width:52ch}

/* ---------- Trust / refund strip ---------- */
.trust-strip{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin-top:28px}
@media(max-width:860px){.trust-strip{grid-template-columns:1fr}}
.trust-cell{padding:24px 22px;background:var(--bg3);border:1px solid var(--border);border-radius:var(--r2)}
.trust-cell strong{display:block;font-size:.92rem;font-weight:700;margin-bottom:6px}
.trust-cell p{font-size:.82rem;color:var(--text2);line-height:1.6}

/* ---------- Email capture / launch fallback ---------- */
.capture{max-width:560px;margin:0 auto;text-align:center}
.capture.flash{animation:captureFlash 1.2s var(--ease)}
@keyframes captureFlash{0%{transform:scale(.985)}40%{transform:scale(1.01)}100%{transform:scale(1)}}
.capture-box{margin-top:26px;padding:28px 26px;background:var(--bg3);border:1px solid var(--border2);border-radius:var(--r);text-align:left}
/* Visible by default. This sentence is the only place the site discloses that
   checkout is not live, so it must not depend on JavaScript or on the visitor
   clicking a buy button first. The .on class is still added by two callers -
   public/store.js (buy-button fallback) and public/site.js (post-signup
   confirmation, which also rewrites the text) - and now emphasises the note
   rather than revealing it, so the two uses no longer conflict. */
.capture-note{display:block;margin:0 0 16px;padding:10px 14px;border:1px solid rgba(217,85,64,.35);background:var(--accent-bg);border-radius:var(--r2);font-size:.82rem;color:var(--text);line-height:1.55}
.capture-note.on{display:block;border-color:var(--accent)}
.capture-row{display:flex;gap:10px}
@media(max-width:560px){.capture-row{flex-direction:column}}
.capture-row input[type="email"]{flex:1}
.capture .ff{text-align:center;margin-top:12px;font-size:.68rem;color:var(--text3)}

/* ---------- FAQ ---------- */
.faq{max-width:680px;margin:48px auto 0}
.fqi{border-bottom:1px solid var(--border)}
.fqq{display:flex;justify-content:space-between;align-items:center;padding:18px 0;font-size:.95rem;font-weight:600;cursor:pointer;list-style:none;transition:color .2s}
.fqq::-webkit-details-marker{display:none}
.fqq::after{content:'+';font-size:1.2rem;color:var(--accent);flex-shrink:0;margin-left:14px;font-weight:400;transition:transform .3s var(--ease)}
details[open] .fqq::after{content:'\2212'}
.fqq:hover{color:var(--accent)}
.fqa{padding-bottom:18px}
.fqa p{font-size:.88rem;color:var(--text2);line-height:1.7;max-width:60ch}

/* ---------- Product detail (books page) ---------- */
.product{display:grid;grid-template-columns:.8fr 1.2fr;gap:56px;align-items:start}
@media(max-width:900px){.product{grid-template-columns:1fr;gap:32px}}
.product-cover-col{position:sticky;top:calc(var(--nav) + 32px);display:grid;place-items:center;gap:18px}
@media(max-width:900px){.product-cover-col{position:static}}
.product-buy{width:100%;max-width:340px;display:flex;flex-direction:column;gap:10px;text-align:center}
.product-buy .price{font-family:var(--serif);font-size:2.2rem;letter-spacing:-.02em}
.product-buy .price small{font-family:var(--sans);font-size:.72rem;color:var(--text3);display:block;margin-top:4px;font-weight:500}
.product h2{font-family:var(--serif);font-size:clamp(1.9rem,3.6vw,2.7rem);font-weight:400;line-height:1.12;letter-spacing:-.015em;margin:10px 0 14px}
.product .who{font-size:.98rem;color:var(--text2);line-height:1.75;max-width:56ch;margin-bottom:26px}
.product .who strong{color:var(--text);font-weight:600}
.contents-l{font-family:var(--mono);font-size:.62rem;color:var(--text3);text-transform:uppercase;letter-spacing:.08em;margin-bottom:10px}
.contents{margin-bottom:26px}
.contents li{display:flex;gap:14px;align-items:baseline;padding:10px 0;border-bottom:1px solid var(--border);font-size:.88rem;color:var(--text2);line-height:1.5}
.contents li:last-child{border:none}
.contents li b{font-family:var(--mono);font-size:.62rem;color:var(--accent);font-weight:500;flex-shrink:0;width:22px}
.contents li strong{color:var(--text);font-weight:600}
.spec-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
@media(max-width:560px){.spec-grid{grid-template-columns:1fr 1fr}}
.spec{padding:14px;background:var(--bg3);border:1px solid var(--border);border-radius:var(--r2)}
.spec span{display:block;font-family:var(--mono);font-size:.54rem;color:var(--text3);text-transform:uppercase;letter-spacing:.07em;margin-bottom:5px}
.spec strong{font-size:.8rem;font-weight:600;line-height:1.4}

/* ---------- Success / cancel ---------- */
.status-main{min-height:calc(100svh - var(--nav));display:flex;align-items:center;padding:calc(var(--nav) + 48px) 0 64px}
.status-card{max-width:620px;margin:0 auto;text-align:center}
.status-card .pill{margin-bottom:8px}
.status-card h1{font-family:var(--serif);font-size:clamp(2.2rem,5vw,3.4rem);font-weight:400;line-height:1.1;letter-spacing:-.02em;margin:14px 0 16px}
.status-card>p{font-size:1rem;color:var(--text2);line-height:1.75;max-width:48ch;margin:0 auto 18px}
.status-card h2{font-family:var(--serif);font-size:clamp(1.3rem,2.6vw,1.7rem);font-weight:400;line-height:1.25;letter-spacing:-.015em;margin:40px 0 0}
.status-steps{margin:30px auto;max-width:480px;text-align:left}
.status-steps li{display:flex;gap:14px;padding:14px 0;border-bottom:1px solid var(--border);font-size:.88rem;color:var(--text2);line-height:1.6}
.status-steps li:last-child{border:none}
.status-steps b{font-family:var(--mono);font-size:.65rem;color:var(--accent);font-weight:500;flex-shrink:0;padding-top:3px}
.status-steps strong{color:var(--text);font-weight:600}
.status-actions{display:flex;gap:12px;justify-content:center;flex-wrap:wrap;margin-top:28px}
.status-help{margin-top:26px;font-size:.78rem;color:var(--text3);line-height:1.7}
.status-help a{color:var(--accent)}
