/* 교재 · 전자책 스토어 (shop.html), 내 서재 (library.html) */
.shop{--sh-blue:#2563eb;max-width:1080px;margin:0 auto;padding:24px 16px 120px}
.shop-hero{padding:8px 0 18px}
.shop-kicker{font-size:12px;font-weight:800;letter-spacing:.1em;color:var(--sh-blue)}
.shop-hero h1{margin:6px 0 8px;font-size:clamp(26px,4vw,36px);letter-spacing:-.02em}
.shop-hero p{margin:0;color:var(--ac-muted,#6e6e73);line-height:1.6;max-width:640px}
.shop-hero a{color:var(--sh-blue)}
.shop-tabs{display:flex;gap:8px;flex-wrap:wrap;margin:8px 0 18px}
body .shop-tabs button{height:36px;padding:0 14px;border-radius:999px;border:1px solid var(--ac-line,#e5e5e7)!important;font:inherit;font-size:13.5px;font-weight:650;cursor:pointer}
body .shop-tabs button[aria-pressed=true]{background:var(--ac-text,#111)!important;color:var(--ac-bg,#fff)!important;border-color:var(--ac-text,#111)!important}
.shop-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:18px}
.shop-card{display:flex;flex-direction:column;border:1px solid var(--ac-line,#e5e5e7);border-radius:16px;overflow:hidden;background:var(--ac-surface,#fff)}
.shop-cover{aspect-ratio:3/4;background:#f1f3f7;display:flex;align-items:center;justify-content:center;overflow:hidden}
.shop-cover img{width:100%;height:100%;object-fit:cover}
.shop-cover-blank{flex-direction:column;gap:10px;padding:22px;text-align:center;background:linear-gradient(160deg,#0f2a5c,#2563eb);color:#fff}
.shop-cover-blank span{font-size:12px;font-weight:800;letter-spacing:.08em;opacity:.85}
.shop-cover-blank strong{font-size:20px;line-height:1.35;word-break:keep-all}
.shop-body{display:flex;flex-direction:column;gap:6px;padding:14px 14px 16px;flex:1}
.shop-tags{display:flex;gap:6px;flex-wrap:wrap}
.shop-chip{font-size:11.5px;font-weight:700;padding:2px 8px;border-radius:999px;background:color-mix(in srgb,var(--ac-text,#111) 7%,transparent);color:var(--ac-muted,#6e6e73)}
.shop-kind-ebook{background:color-mix(in srgb,#2563eb 12%,transparent);color:#2563eb}
.shop-body h3{margin:4px 0 0;font-size:16.5px;line-height:1.4;word-break:keep-all}
.shop-sub{margin:0;font-size:13px;color:var(--ac-muted,#6e6e73);line-height:1.5}
.shop-desc summary{cursor:pointer;font-size:12.5px;color:var(--ac-muted,#6e6e73)}
.shop-desc p{margin:6px 0 0;font-size:13px;line-height:1.6;white-space:pre-line}
.shop-price{display:flex;align-items:baseline;gap:6px;margin-top:auto;padding-top:6px}
.shop-price s{font-size:12.5px;color:var(--ac-muted,#6e6e73)}
.shop-price em{font-style:normal;font-size:13px;font-weight:800;color:#e0453a}
.shop-price strong{font-size:18px}
.shop-act{display:flex;align-items:center;gap:8px;flex-wrap:wrap;min-height:40px}
body .shop-add{width:100%;height:40px;border-radius:10px;font-weight:750}
.shop-added{font-size:13px;font-weight:700;color:#2563eb}
.shop-step{display:inline-flex;align-items:center;border:1px solid var(--ac-line,#e5e5e7);border-radius:10px;overflow:hidden}
body .shop-step button{width:34px;height:34px;border:0!important;font-size:18px;cursor:pointer}
.shop-step span{min-width:26px;text-align:center;font-weight:700}
body .shop-remove{margin-left:auto;height:34px;padding:0 10px;border-radius:9px;border:1px solid var(--ac-line,#e5e5e7)!important;font:inherit;font-size:12.5px;cursor:pointer}
.shop-soldout{font-size:13px;font-weight:700;color:var(--ac-muted,#6e6e73)}
a.shop-read{font-weight:750;color:#2563eb!important;text-decoration:none}
.shop-cart{position:sticky;bottom:0;margin-top:28px;padding:18px;border:1px solid var(--ac-line,#e5e5e7);border-radius:18px 18px 0 0;background:var(--ac-surface,#fff);box-shadow:0 -10px 30px rgba(0,0,0,.06);max-height:82vh;overflow:auto}
.shop-cart h2{margin:0 0 10px;font-size:18px}
.shop-lines{list-style:none;margin:0;padding:0}
.shop-lines li{display:flex;align-items:center;gap:10px;padding:8px 0;border-bottom:1px solid var(--ac-line,#e5e5e7);font-size:14px}
.shop-lines li span{flex:1;min-width:0}
body .shop-x{width:28px;height:28px;border-radius:50%;border:0!important;cursor:pointer;font-size:16px;line-height:1}
.shop-ship{margin:14px 0 0;padding:14px;border:1px solid var(--ac-line,#e5e5e7);border-radius:14px;display:grid;gap:10px}
.shop-ship legend{padding:0 6px;font-weight:750}
.shop-ship label{display:grid;gap:4px;font-size:12.5px;font-weight:650;color:var(--ac-muted,#6e6e73)}
.shop-ship input:not([type=checkbox]){height:42px;padding:0 12px;border:1px solid var(--ac-line,#e5e5e7);border-radius:10px;font:inherit;font-size:15px;background:var(--ac-bg,#fff);color:var(--ac-text,#111)}
.shop-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.shop-zip{grid-template-columns:1fr auto;align-items:end}
body .shop-zip button{height:42px;padding:0 14px;border-radius:10px;border:1px solid var(--ac-line,#e5e5e7)!important;font:inherit;font-weight:700;cursor:pointer}
label.shop-check{display:flex;align-items:center;gap:8px;font-weight:600}
.shop-totals{margin:14px 0 0;display:grid;gap:6px}
.shop-totals div{display:flex;justify-content:space-between;gap:12px;font-size:14px}
.shop-totals dt{color:var(--ac-muted,#6e6e73)}.shop-totals dd{margin:0;font-weight:650}
.shop-totals .shop-note{font-size:12.5px;color:#2563eb}.shop-totals .shop-note dt{color:inherit}
.shop-totals .shop-sum{padding-top:8px;border-top:1px solid var(--ac-line,#e5e5e7);font-size:16px}.shop-totals .shop-sum dd{font-weight:800}
body .shop-order{width:100%;height:52px;margin-top:12px;border-radius:12px;font-size:16px;font-weight:800}
.shop-order-status{margin:8px 0 0;font-size:13.5px;color:#c2352b}.shop-order-status:empty{display:none}
@media (max-width:560px){.shop-grid{grid-template-columns:1fr 1fr;gap:12px}.shop-body{padding:10px}.shop-body h3{font-size:14.5px}.shop-row{grid-template-columns:1fr}.shop-price strong{font-size:16px}}
/* 내 서재 */
.lib-tools{display:flex;align-items:center;flex-wrap:wrap;gap:12px;margin-bottom:16px}
body .lib-refresh{min-height:44px;padding:10px 16px;border:1px solid transparent;font:inherit;font-size:14px;font-weight:750;cursor:pointer}
.lib-refresh:disabled{opacity:.5;cursor:default}
.lib-tools a{color:#2563eb!important;font-weight:700}
.lib-section{margin:22px 0}
.lib-section h2{font-size:18px;margin:0 0 12px}
.lib-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:14px}
.lib-book{display:flex;flex-direction:column;gap:8px;min-width:0}
a.lib-book{text-decoration:none;color:inherit!important}
.lib-book.is-preparing small{color:var(--ac-muted,#6e6e73)!important}
.lib-book .shop-cover{border-radius:12px}
.lib-book strong{font-size:14.5px;line-height:1.4}
.lib-book small{color:#2563eb;font-weight:700}
.lib-ship{display:grid;gap:4px;padding:14px;border:1px solid var(--ac-line,#e5e5e7);border-radius:14px;margin-bottom:10px}
.lib-ship header{display:flex;justify-content:space-between;gap:10px;align-items:center}
.lib-state{font-size:12px;font-weight:800;padding:3px 9px;border-radius:999px;background:color-mix(in srgb,#2563eb 12%,transparent);color:#2563eb}
.lib-state[data-s=delivered]{background:color-mix(in srgb,#157a52 14%,transparent);color:#157a52}
.lib-state[data-s=canceled]{background:color-mix(in srgb,#c2352b 12%,transparent);color:#c2352b}
.lib-ship p{margin:0;font-size:13.5px;color:var(--ac-muted,#6e6e73)}
.lib-ship a{color:#2563eb!important;font-weight:700}
.lib-empty{color:var(--ac-muted,#6e6e73)}
/* 함께 보면 좋은 교재 (course page, cart) */
.sr-strip{margin:14px 0 0}
.sr-strip h3{margin:0 0 8px;font-size:14px}
.sr-list{display:grid;gap:8px}
a.sr-item{display:grid;grid-template-columns:44px 1fr auto;align-items:center;gap:10px;padding:8px 10px;border:1px solid var(--ac-line,#e5e5e7);border-radius:12px;text-decoration:none;color:inherit!important}
a.sr-item:hover{border-color:#2563eb}
.sr-thumb{width:44px;height:58px;border-radius:6px;overflow:hidden;background:linear-gradient(160deg,#0f2a5c,#2563eb);display:flex;align-items:center;justify-content:center;font-size:20px}
.sr-thumb img{width:100%;height:100%;object-fit:cover}
.sr-copy{display:grid;gap:1px;min-width:0}
.sr-copy small{font-size:11.5px;color:var(--ac-muted,#6e6e73)}
.sr-copy strong{font-size:13.5px;line-height:1.35;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sr-copy b{font-size:13px}
.sr-go{font-size:12.5px;font-weight:800;color:#2563eb}
a.sr-all{display:inline-block;margin-top:8px;font-size:13px;font-weight:700;color:#2563eb!important;text-decoration:none}
.sr-pick{display:flex;align-items:center;gap:12px;padding:12px 0;border-bottom:1px solid var(--ac-line,#394140)}
/* Site headers are flex rows elsewhere; the store hero is a plain block. */
header.shop-hero{display:block!important;border:0!important}
.shop-price{flex-wrap:wrap}.shop-price>*{white-space:nowrap}
@media (max-width:560px){.shop-row.shop-zip{grid-template-columns:1fr auto}}
.lib-ship>header{display:flex!important;padding:0!important;border:0!important;margin:0!important;background:none!important;position:static!important}
a.lib-book small{color:#2563eb!important}
