/* ============================================================
   Book Aviator — public site stylesheet
   Warm, literary, quietly sustainable. Mobile & desktop equal.
   ============================================================ */

:root {
  --cream:      #FAF5EB;
  --paper:      #FFFDF7;
  --sand:       #F1E8D7;
  --ink:        #22302B;
  --ink-soft:   #51605A;
  --green:      #1E4D45;
  --green-deep: #14332E;
  --green-soft: #2E7263;
  --terra:      #C4622D;
  --terra-deep: #A34E20;
  --gold:       #D9A441;
  --line:       #E4D9C3;
  --danger:     #A33B2E;
  --ok:         #2F6C4F;

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, "Segoe UI", Roboto, sans-serif;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 2px 6px rgba(34, 48, 43, .06), 0 10px 28px rgba(34, 48, 43, .07);
  --shadow-soft: 0 1px 3px rgba(34, 48, 43, .08);
  --container: 1160px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
}

img { max-width: 100%; display: block; }
a { color: var(--green); text-decoration: none; }
a:hover { color: var(--green-deep); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.18;
  color: var(--ink);
  margin: 0 0 .5em;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.5rem, 3.4vw, 2.15rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.skip {
  position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff;
  padding: 8px 16px; z-index: 200; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; color: #fff; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 15px/1 var(--font-body);
  padding: 13px 22px; border-radius: 999px; border: 2px solid transparent;
  cursor: pointer; transition: all .15s ease; text-align: center; white-space: nowrap;
}
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-deep); color: #fff; transform: translateY(-1px); }
.btn-accent { background: var(--terra); color: #fff; }
.btn-accent:hover { background: var(--terra-deep); color: #fff; transform: translateY(-1px); }
.btn-outline { background: transparent; color: var(--green); border-color: var(--green); }
.btn-outline:hover { background: var(--green); color: #fff; }
.btn-ghost { background: var(--sand); color: var(--ink); }
.btn-ghost:hover { background: var(--line); color: var(--ink); }
.btn-sm { padding: 9px 16px; font-size: 13.5px; }
.btn-lg { padding: 16px 30px; font-size: 16px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* ---------- Header ---------- */
.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 100;
}
.header-inner {
  display: flex; align-items: center; gap: 20px;
  min-height: 72px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand svg, .brand img { width: 42px; height: 42px; }
.brand-word {
  font-family: var(--font-display); font-weight: 700; font-size: 1.35rem;
  color: var(--ink); letter-spacing: -.01em;
}
.brand-word em { font-style: normal; color: var(--green); }

.main-nav { display: flex; gap: 26px; margin-left: 16px; }
.main-nav a {
  color: var(--ink-soft); font-weight: 550; font-size: 15px; padding: 6px 0;
  border-bottom: 2px solid transparent;
}
.main-nav a:hover, .main-nav a.active { color: var(--ink); border-bottom-color: var(--gold); }
.main-nav a.nav-donate { color: var(--terra); }
.main-nav a.nav-donate:hover { color: var(--terra-deep); }

.header-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.icon-link {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: 50%; color: var(--ink);
}
.icon-link:hover { background: var(--sand); color: var(--ink); }
.icon-link svg { width: 22px; height: 22px; }
.cart-badge {
  position: absolute; top: 2px; right: 0;
  background: var(--terra); color: #fff; font-size: 11px; font-weight: 700;
  min-width: 18px; height: 18px; border-radius: 999px;
  display: flex; align-items: center; justify-content: center; padding: 0 4px;
}
.nav-toggle {
  display: none; background: none; border: 0; cursor: pointer; padding: 8px;
  width: 42px; height: 42px; border-radius: 50%;
}
.nav-toggle:hover { background: var(--sand); }
.nav-toggle span {
  display: block; width: 20px; height: 2px; background: var(--ink); margin: 4px auto;
  transition: transform .2s ease, opacity .2s ease;
}

/* ---------- Flash messages ---------- */
.flash-wrap { max-width: var(--container); margin: 14px auto 0; padding: 0 20px; }
.flash {
  padding: 12px 18px; border-radius: var(--radius-sm); margin-bottom: 10px;
  font-size: 14.5px; border: 1px solid;
}
.flash-success { background: #EAF3EC; border-color: #BFDCC8; color: #24523B; }
.flash-error { background: #F9ECE8; border-color: #E5C4BA; color: #7C2D1F; }
.flash-info { background: #EEF1E9; border-color: #D4DBC8; color: #44503A; }

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(1100px 460px at 85% -10%, rgba(217, 164, 65, .16), transparent 60%),
    radial-gradient(900px 480px at -10% 110%, rgba(30, 77, 69, .10), transparent 60%),
    var(--paper);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.hero-inner {
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: center;
  padding: 64px 0 60px;
}
.hero-kicker {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 650; letter-spacing: .12em; text-transform: uppercase;
  color: var(--terra); margin-bottom: 16px;
}
.hero-kicker::before { content: ""; width: 26px; height: 2px; background: var(--terra); }
.hero h1 { margin-bottom: 18px; }
.hero h1 em { font-style: italic; color: var(--green); }
.hero-lede { font-size: 1.13rem; color: var(--ink-soft); max-width: 34em; margin-bottom: 26px; }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 26px; }
.hero-meta { display: flex; gap: 26px; flex-wrap: wrap; color: var(--ink-soft); font-size: 14px; }
.hero-meta strong { display: block; font-family: var(--font-display); font-size: 1.3rem; color: var(--ink); }

.hero-art { position: relative; min-height: 320px; }
.hero-stack {
  position: relative; margin: 0 auto; width: min(320px, 88%);
}
.hero-stack .stack-book {
  border-radius: 10px; box-shadow: var(--shadow); border: 1px solid var(--line);
  background: var(--paper); overflow: hidden; aspect-ratio: 2/3;
}
.hero-stack .b1 { position: absolute; width: 62%; left: 0; top: 24px; transform: rotate(-6deg); z-index: 1; }
.hero-stack .b2 { position: relative; width: 66%; margin-left: 30%; z-index: 2; transform: rotate(3deg); }
.hero-stack img { width: 100%; height: 100%; object-fit: cover; }
.hero-plane {
  position: absolute; top: -18px; right: -6px; width: 74px; transform: rotate(8deg);
  filter: drop-shadow(0 6px 10px rgba(34,48,43,.18));
}

/* ---------- Sections ---------- */
.section { padding: 58px 0; }
.section-tight { padding: 40px 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 26px; }
.section-head p { color: var(--ink-soft); margin: 0; }
.section-alt { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

/* ---------- Book grid & cards ---------- */
.book-grid {
  display: grid; gap: 22px;
  grid-template-columns: repeat(4, 1fr);
}
.book-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform .15s ease, box-shadow .15s ease;
}
.book-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.book-card-cover { position: relative; aspect-ratio: 2/3; background: var(--sand); overflow: hidden; }
.book-card-cover img { width: 100%; height: 100%; object-fit: cover; }
.badge-condition {
  position: absolute; top: 10px; left: 10px;
  background: rgba(255, 253, 247, .93); color: var(--green-deep);
  font-size: 11.5px; font-weight: 700; letter-spacing: .04em;
  padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line);
}
.book-card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.book-card-title {
  font-family: var(--font-display); font-size: 1.02rem; font-weight: 600; line-height: 1.3;
  color: var(--ink);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
a.book-card-link { color: inherit; }
.book-card-author { color: var(--ink-soft); font-size: 13.5px; }
.book-card-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; padding-top: 10px; }
.price { font-family: var(--font-display); font-weight: 700; font-size: 1.12rem; color: var(--green-deep); }
.price-retail { color: var(--ink-soft); font-size: 12.5px; text-decoration: line-through; margin-left: 6px; font-family: var(--font-body); font-weight: 400; }

.empty-note {
  text-align: center; color: var(--ink-soft); background: var(--paper);
  border: 1px dashed var(--line); border-radius: var(--radius); padding: 48px 20px;
}

/* ---------- How it works ---------- */
.hiw-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.hiw-col {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 28px 24px;
}
.hiw-col h3 { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.hiw-col h3 svg { width: 26px; height: 26px; color: var(--terra); flex: none; }
.hiw-steps { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 14px; }
.hiw-steps li { display: flex; gap: 14px; align-items: flex-start; }
.hiw-num {
  flex: none; width: 30px; height: 30px; border-radius: 50%;
  background: var(--sand); color: var(--green-deep);
  font-weight: 700; font-size: 14px; display: flex; align-items: center; justify-content: center;
  margin-top: 2px;
}
.hiw-steps b { display: block; }
.hiw-steps span { color: var(--ink-soft); font-size: 14.5px; }

/* ---------- Trust / testimonials ---------- */
.trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.trust-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px;
}
.trust-quote { font-family: var(--font-display); font-style: italic; font-size: 1.05rem; margin-bottom: 14px; }
.trust-who { display: flex; align-items: center; gap: 10px; color: var(--ink-soft); font-size: 14px; }
.trust-avatar {
  width: 38px; height: 38px; border-radius: 50%; background: var(--green); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px;
}
.stars { color: var(--gold); letter-spacing: 2px; font-size: 14px; }

.eco-band {
  background: var(--green); color: #E9F1EC; border-radius: var(--radius);
  padding: 30px 34px; display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
}
.eco-band h3 { color: #fff; margin: 0 0 4px; }
.eco-band p { margin: 0; color: #C9DCD2; }
.eco-band .btn { margin-left: auto; }
.eco-band svg { width: 44px; height: 44px; flex: none; color: var(--gold); }

/* ---------- Shop layout ---------- */
.page-head { padding: 40px 0 8px; }
.page-head p { color: var(--ink-soft); max-width: 46em; }
.shop-layout { display: grid; grid-template-columns: 250px 1fr; gap: 32px; align-items: start; padding: 26px 0 60px; }
.filters {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; position: sticky; top: 88px;
}
.filters h3 { font-size: 1.05rem; margin-bottom: 14px; }
.filter-group { margin-bottom: 16px; }
.filter-group label { display: block; font-size: 13px; font-weight: 650; color: var(--ink-soft); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .05em; }
.price-inputs { display: flex; gap: 8px; align-items: center; }
.price-inputs input { width: 100%; }
.filters-toggle { display: none; }

.shop-toolbar {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  margin-bottom: 18px; flex-wrap: wrap;
}
.shop-count { color: var(--ink-soft); font-size: 14.5px; }
.sort-select { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink-soft); }

.searchbar { display: flex; gap: 10px; margin: 18px 0 6px; }
.searchbar input[type=search] { flex: 1; }

/* ---------- Forms ---------- */
input[type=text], input[type=search], input[type=email], input[type=tel],
input[type=number], input[type=password], input[type=date], input[type=url],
select, textarea {
  width: 100%; padding: 12px 14px;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: #fff; color: var(--ink);
  font: 400 15px/1.4 var(--font-body);
  transition: border-color .15s ease, box-shadow .15s ease;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--green-soft);
  box-shadow: 0 0 0 3px rgba(46, 114, 99, .14);
}
textarea { resize: vertical; min-height: 110px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .span2 { grid-column: span 2; }
.field label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 6px; }
.field .hint { font-size: 13px; color: var(--ink-soft); margin-top: 5px; }
.field-error { color: var(--danger); font-size: 13px; margin-top: 5px; }
.required::after { content: " *"; color: var(--terra); }

.form-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow-soft);
}
.auth-wrap { max-width: 440px; margin: 48px auto 70px; padding: 0 20px; }
.auth-wrap .form-card { padding: 32px; }
.auth-alt { text-align: center; margin-top: 18px; color: var(--ink-soft); font-size: 14.5px; }

/* ---------- Book detail ---------- */
.book-detail { display: grid; grid-template-columns: 380px 1fr; gap: 44px; padding: 44px 0 30px; align-items: start; }
.book-detail-cover {
  border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line);
  background: var(--sand); box-shadow: var(--shadow); aspect-ratio: 2/3;
  position: sticky; top: 92px;
}
.book-detail-cover img { width: 100%; height: 100%; object-fit: cover; }
.crumbs { font-size: 13.5px; color: var(--ink-soft); padding-top: 22px; }
.crumbs a { color: var(--ink-soft); }
.crumbs a:hover { color: var(--green); }
.book-detail h1 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); margin-bottom: 6px; }
.book-detail .by { font-size: 1.06rem; color: var(--ink-soft); margin-bottom: 16px; }
.chip-row { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }
.chip {
  font-size: 13px; font-weight: 600; color: var(--green-deep);
  background: var(--sand); padding: 6px 13px; border-radius: 999px;
}
.chip-terra { background: #F6E3D4; color: var(--terra-deep); }
.detail-price-row { display: flex; align-items: baseline; gap: 12px; margin: 6px 0 18px; }
.detail-price-row .price { font-size: 1.9rem; }
.one-copy-note {
  display: flex; gap: 10px; align-items: center; background: #F6EFDF; border: 1px solid #E5D6B2;
  color: #6E5A26; font-size: 14px; border-radius: var(--radius-sm); padding: 10px 14px; margin: 18px 0;
}
.one-copy-note svg { width: 18px; height: 18px; flex: none; }
.book-synopsis { max-width: 60em; }
.book-synopsis h3 { margin-top: 26px; }
.meta-table { width: 100%; border-collapse: collapse; margin: 18px 0 6px; max-width: 460px; font-size: 14.5px; }
.meta-table td { padding: 8px 0; border-bottom: 1px solid var(--line); }
.meta-table td:first-child { color: var(--ink-soft); width: 42%; }

/* ---------- Cart ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 32px; align-items: start; padding: 30px 0 60px; }
.cart-items { display: grid; gap: 14px; }
.cart-item {
  display: grid; grid-template-columns: 84px 1fr auto; gap: 16px; align-items: center;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px;
}
.cart-item-cover { width: 84px; aspect-ratio: 2/3; border-radius: 8px; overflow: hidden; background: var(--sand); }
.cart-item-cover img { width: 100%; height: 100%; object-fit: cover; }
.cart-item h3 { font-size: 1.02rem; margin-bottom: 2px; }
.cart-item .muted { color: var(--ink-soft); font-size: 13.5px; }
.cart-item-end { text-align: right; display: grid; gap: 8px; justify-items: end; }
.link-danger { color: var(--danger); font-size: 13.5px; background: none; border: 0; cursor: pointer; padding: 0; font-family: inherit; }
.link-danger:hover { text-decoration: underline; }

.summary-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; position: sticky; top: 92px; box-shadow: var(--shadow-soft);
}
.summary-card h3 { margin-bottom: 16px; }
.sum-row { display: flex; justify-content: space-between; padding: 7px 0; font-size: 15px; }
.sum-row.total { border-top: 2px solid var(--ink); margin-top: 10px; padding-top: 13px; font-weight: 700; font-size: 1.1rem; font-family: var(--font-display); }
.sum-row .ok { color: var(--ok); font-weight: 650; }
.sum-note { font-size: 13px; color: var(--ink-soft); margin-top: 8px; }

/* free delivery nudge */
.nudge {
  background: #F3EDDE; border: 1px solid #E2D5B2; border-radius: var(--radius-sm);
  padding: 13px 15px; margin: 14px 0 4px; font-size: 13.5px; color: #6B5A2A;
}
.nudge b { color: var(--terra-deep); }
.nudge-bar { height: 8px; background: #E5DBBF; border-radius: 999px; margin-top: 9px; overflow: hidden; }
.nudge-fill { height: 100%; background: linear-gradient(90deg, var(--gold), var(--terra)); border-radius: 999px; transition: width .3s ease; }
.nudge.reached { background: #EAF3EC; border-color: #BFDCC8; color: #24523B; }
.nudge.reached .nudge-fill { background: var(--ok); }

/* discount hint */
.bundle-hint { font-size: 13.5px; color: var(--ink-soft); margin-top: 6px; }
.bundle-hint b { color: var(--green-deep); }

/* ---------- Checkout ---------- */
.checkout-layout { display: grid; grid-template-columns: 1fr 380px; gap: 32px; align-items: start; padding: 30px 0 60px; }
.pay-options { display: grid; gap: 12px; margin-top: 6px; }
.pay-option {
  display: flex; gap: 14px; align-items: flex-start;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  padding: 15px 16px; cursor: pointer; background: #fff; transition: border-color .15s ease;
}
.pay-option:has(input:checked) { border-color: var(--green); box-shadow: 0 0 0 3px rgba(30, 77, 69, .10); }
.pay-option input { margin-top: 4px; accent-color: var(--green); }
.pay-option b { display: block; }
.pay-option span { color: var(--ink-soft); font-size: 14px; }
.mini-items { display: grid; gap: 10px; margin-bottom: 14px; }
.mini-item { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; font-size: 14px; }
.mini-item img { width: 44px; aspect-ratio: 2/3; object-fit: cover; border-radius: 6px; }
.mini-item .muted { color: var(--ink-soft); font-size: 12.5px; }

/* upsell strip */
.upsell { margin-top: 26px; }
.upsell h3 { font-size: 1.15rem; }
.upsell-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.upsell-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm);
  overflow: hidden; font-size: 13px;
}
.upsell-card .cover { aspect-ratio: 2/3; background: var(--sand); }
.upsell-card .cover img { width: 100%; height: 100%; object-fit: cover; }
.upsell-card .body { padding: 10px 12px 12px; display: grid; gap: 6px; }
.upsell-card .t { font-weight: 600; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--ink); }
.upsell-card .p { font-weight: 700; color: var(--green-deep); }
.upsell-card form { margin: 0; }

/* ---------- Confirmation ---------- */
.confirm-wrap { max-width: 720px; margin: 44px auto 70px; padding: 0 20px; }
.confirm-head { text-align: center; margin-bottom: 26px; }
.confirm-check {
  width: 66px; height: 66px; margin: 0 auto 16px; border-radius: 50%;
  background: var(--green); color: #fff; display: flex; align-items: center; justify-content: center;
}
.confirm-check svg { width: 32px; height: 32px; }
.order-no { font-family: var(--font-display); font-size: 1.1rem; color: var(--terra-deep); }
.instructions-box {
  background: #F6EFDF; border: 1px solid #E5D6B2; border-radius: var(--radius-sm);
  padding: 18px 20px; white-space: pre-line; font-size: 14.5px; margin-top: 8px;
}

/* ---------- Donate ---------- */
.donate-hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; padding: 50px 0 10px; }
.donate-points { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 12px; }
.donate-points li { display: flex; gap: 12px; align-items: flex-start; color: var(--ink-soft); }
.donate-points svg { width: 21px; height: 21px; color: var(--ok); flex: none; margin-top: 2px; }
.donate-form-wrap { max-width: 760px; margin: 30px auto 70px; padding: 0 20px; }
.window-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.window-option {
  border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: #fff;
  padding: 12px 8px; text-align: center; font-size: 13.5px; font-weight: 600; cursor: pointer;
  transition: border-color .15s ease;
}
.window-option:has(input:checked) { border-color: var(--green); background: #EFF5F0; }
.window-option input { position: absolute; opacity: 0; }

/* ---------- Account ---------- */
.account-layout { padding: 36px 0 60px; }
.order-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; margin-bottom: 16px; }
.order-card-head { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.status-pill { font-size: 12.5px; font-weight: 700; padding: 4px 12px; border-radius: 999px; }
.status-new { background: #F6EFDF; color: #6E5A26; }
.status-fulfilled { background: #EAF3EC; color: #24523B; }
.status-cancelled { background: #F3E4E1; color: #7C2D1F; }
.order-items-list { margin: 8px 0 0; padding: 0; list-style: none; font-size: 14.5px; }
.order-items-list li { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.order-items-list li:last-child { border-bottom: 0; }

/* ---------- Static pages ---------- */
.prose { max-width: 46em; }
.prose h2 { margin-top: 1.6em; }
.prose ul { padding-left: 1.2em; }

/* ---------- Pagination ---------- */
.pagination { display: flex; gap: 8px; justify-content: center; margin: 34px 0 6px; flex-wrap: wrap; }
.pagination a, .pagination span {
  min-width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--paper);
  color: var(--ink); font-size: 14px; padding: 0 12px;
}
.pagination .current { background: var(--green); color: #fff; border-color: var(--green); }

/* ---------- Footer ---------- */
.site-footer { background: var(--green-deep); color: #B9CDC4; margin-top: 30px; }
.footer-inner { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 36px; padding: 52px 0 36px; }
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.site-footer a { color: #B9CDC4; }
.site-footer a:hover { color: #fff; }
.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.footer-brand svg, .footer-brand img { width: 36px; height: 36px; }
.footer-brand span { font-family: var(--font-display); font-weight: 700; font-size: 1.2rem; color: #fff; }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; font-size: 14.5px; }
.footer-eco { font-size: 14px; line-height: 1.65; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12); padding: 18px 0;
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  font-size: 13px; color: #8FA89D;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1020px) {
  .book-grid { grid-template-columns: repeat(3, 1fr); }
  .upsell-row { grid-template-columns: repeat(3, 1fr); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .book-detail { grid-template-columns: 320px 1fr; gap: 32px; }
}

@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; padding: 44px 0; gap: 30px; }
  .hero-art { display: none; }
  .hiw-grid { grid-template-columns: 1fr; }
  .trust-grid { grid-template-columns: 1fr; }
  .shop-layout { grid-template-columns: 1fr; }
  .filters { position: static; }
  .filters-toggle { display: inline-flex; margin-bottom: 14px; }
  .filters.collapsed { display: none; }
  .cart-layout, .checkout-layout { grid-template-columns: 1fr; }
  .summary-card { position: static; }
  .book-detail { grid-template-columns: 1fr; }
  .book-detail-cover { position: static; max-width: 300px; }
  .donate-hero { grid-template-columns: 1fr; }
  .eco-band .btn { margin-left: 0; }
}

@media (max-width: 760px) {
  /* mobile nav */
  .main-nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--paper); border-bottom: 1px solid var(--line);
    flex-direction: column; gap: 0; padding: 8px 20px 14px; margin: 0;
    box-shadow: 0 14px 24px rgba(34,48,43,.10);
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 13px 4px; border-bottom: 1px solid var(--line); font-size: 16px; }
  .main-nav a:last-child { border-bottom: 0; }
  .nav-toggle { display: block; }
  .nav-toggle.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
}

@media (max-width: 640px) {
  body { font-size: 15px; }
  .book-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .upsell-row { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .span2 { grid-column: span 1; }
  .section { padding: 42px 0; }
  .cart-item { grid-template-columns: 64px 1fr; }
  .cart-item-cover { width: 64px; }
  .cart-item-end { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; }
  .window-options { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; gap: 28px; padding: 40px 0 28px; }
  .section-head { flex-direction: column; align-items: flex-start; gap: 6px; }
  .hero-ctas .btn { flex: 1; }
  .form-card { padding: 20px; }
}
