/* Charles Spurgeon Books — storefront
   Cream / oxblood palette sampled from the book covers.
   EB Garamond for literary text; Source Sans 3 for UI. */

@font-face {
  font-family: "EB Garamond";
  src: url("../fonts/EBGaramond-Regular.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "EB Garamond";
  src: url("../fonts/EBGaramond-Medium.woff") format("woff");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "EB Garamond";
  src: url("../fonts/EBGaramond-SemiBold.woff") format("woff");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "EB Garamond";
  src: url("../fonts/EBGaramond-Bold.woff") format("woff");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "EB Garamond";
  src: url("../fonts/EBGaramond-Italic.woff") format("woff");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "EB Garamond";
  src: url("../fonts/EBGaramond-MediumItalic.woff") format("woff");
  font-weight: 500;
  font-style: italic;
  font-display: swap;
}

:root {
  --cream: #f6f0e4;
  --cream-deep: #ebe3d3;
  --paper: #fbf7ef;
  --ink: #2a1c1a;
  --ink-soft: #5c4a46;
  --oxblood: #4a1f22;
  --oxblood-hover: #63282c;
  --gold: #c9b27a;
  --gold-deep: #a8925a;
  --rule: #d8cdb8;
  --shadow: 0 10px 26px rgba(42, 28, 26, 0.16);
  --font-serif: "EB Garamond", "Palatino Linotype", Palatino, "Times New Roman", serif;
  --font-sans: "Source Sans 3", "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --wrap: 1120px;
  --gap: 1.5rem;
  --radius: 2px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-serif);
  font-size: 1.125rem;
  line-height: 1.65;
  font-weight: 400;
}

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--oxblood);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover { color: var(--oxblood-hover); }

:focus-visible {
  outline: 2px solid var(--oxblood);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--oxblood);
  color: var(--cream);
  padding: 0.5rem 0.9rem;
  z-index: 100;
}
.skip-link:focus { top: 0.75rem; }

.wrap {
  width: min(var(--wrap), calc(100% - 2.5rem));
  margin-inline: auto;
}

/* ---------- Header ---------- */
.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
  position: sticky;
  top: 0;
  z-index: 40;
}

.site-header .bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.25rem;
  padding-block: 0.6rem;
}

.logo {
  text-decoration: none;
  color: var(--oxblood);
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}
.logo:hover { color: var(--oxblood-hover); }
.logo-mark {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.logo-sub {
  font-size: 0.7rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-top: 0.15rem;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--oxblood);
  color: var(--oxblood);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.4rem 0.7rem;
  cursor: pointer;
}

.site-nav ul {
  display: flex;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-nav a {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink);
  font-weight: 500;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--oxblood);
}
.site-nav a[aria-current="page"] {
  box-shadow: inset 0 -2px 0 var(--gold);
  padding-bottom: 0.15rem;
}

.gold-rule {
  height: 0;
  border: 0;
  border-top: 1px solid var(--gold);
  border-bottom: 1px solid var(--gold);
  padding-top: 3px;
  margin: 0;
}

/* ---------- Hero ---------- */
.hero {
  text-align: center;
  padding: 3.75rem 0 3.25rem;
}
.kicker {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin: 0 0 1.25rem;
  font-weight: 600;
}
.hero h1 {
  font-weight: 500;
  font-size: clamp(2.15rem, 5.4vw, 3.7rem);
  line-height: 1.18;
  margin: 0 auto 1.25rem;
  color: var(--oxblood);
}
.ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  color: var(--gold);
  margin: 0 auto 1.5rem;
}
.ornament::before,
.ornament::after {
  content: "";
  width: 4.5rem;
  height: 1px;
  background: var(--gold);
}
.ornament span { font-size: 1.1rem; line-height: 1; }

.lede-follow { margin-top: -0.85rem; }
.lede {
  font-size: 1.2rem;
  line-height: 1.7;
  max-width: 36rem;
  margin: 0 auto 2rem;
  color: var(--ink);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  justify-content: center;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.75rem 1.15rem;
  border-radius: var(--radius);
  border: 1px solid var(--oxblood);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn-solid {
  background: var(--oxblood);
  color: var(--cream);
}
.btn-solid:hover {
  background: var(--oxblood-hover);
  color: var(--cream);
  border-color: var(--oxblood-hover);
}
.btn-ghost {
  background: transparent;
  color: var(--oxblood);
}
.btn-ghost:hover {
  background: var(--oxblood);
  color: var(--cream);
}
.btn[disabled],
.btn.is-disabled {
  opacity: 0.55;
  pointer-events: none;
}

/* ---------- Sections ---------- */
.section { padding: 2.75rem 0 3.5rem; }
.section-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  margin-bottom: 1.75rem;
}
.section-head h2 {
  font-size: clamp(1.8rem, 3vw, 2.35rem);
  font-weight: 500;
  margin: 0;
  color: var(--oxblood);
}
.section-head p {
  margin: 0;
  color: var(--ink-soft);
  max-width: 36rem;
}
.section-link {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
}

.band {
  background: var(--paper);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

/* ---------- Book grid ---------- */
.book-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2.25rem 1.6rem;
}
.book-card {
  flex: 1 1 280px;
  max-width: 340px;
  width: 100%;
}
@media (max-width: 639px) {
  .book-card { max-width: 26rem; }
}

.book-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.cover {
  background: var(--oxblood);
  aspect-ratio: 2 / 3;
  box-shadow: var(--shadow);
  margin-bottom: 1rem;
  overflow: hidden;
}
.cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.book-card h3 {
  font-size: 1.35rem;
  font-weight: 500;
  margin: 0 0 0.4rem;
  line-height: 1.25;
  color: var(--ink);
}
.book-card .blurb {
  font-size: 1.02rem;
  color: var(--ink-soft);
  margin: 0 0 1rem;
  flex: 1;
}
.buy-label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0 0 0.45rem;
  font-weight: 600;
}
.book-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.book-actions .btn { padding: 0.6rem 0.85rem; }

.badge {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: var(--oxblood);
  color: var(--cream);
  padding: 0.3rem 0.55rem;
  margin-bottom: 0.65rem;
}

/* ---------- Signup / Kit placeholder ---------- */
.signup {
  padding: 3.25rem 0;
  text-align: center;
}
.signup h2 {
  font-size: clamp(1.8rem, 3vw, 2.35rem);
  font-weight: 500;
  color: var(--oxblood);
  margin: 0 0 0.75rem;
}
.signup > .wrap > .offer {
  max-width: 36rem;
  margin: 0 auto 1.5rem;
}

.kit-placeholder {
  max-width: 32rem;
  margin: 0 auto;
  border: 1px dashed var(--gold-deep);
  background: var(--paper);
  padding: 1.25rem 1.25rem 1.4rem;
  text-align: left;
  position: relative;
}
.kit-placeholder__label {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--oxblood);
  background: #f3e3b8;
  border: 1px solid var(--gold);
  padding: 0.35rem 0.55rem;
  margin: 0 0 1rem;
}
.kit-placeholder form {
  display: grid;
  gap: 0.55rem;
}
.kit-placeholder label {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
}
.kit-placeholder input[type="email"] {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--rule);
  background: #fff;
  color: var(--ink);
  width: 100%;
}
.kit-placeholder .btn { width: 100%; }
.fineprint {
  font-size: 0.95rem;
  color: var(--ink-soft);
  max-width: 32rem;
  margin: 1rem auto 0;
}

/* ---------- About ---------- */
.about-prose {
  max-width: 38rem;
  margin: 0 auto;
  padding: 3rem 0 4rem;
}
.about-prose h1 {
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 500;
  color: var(--oxblood);
  margin: 0 0 0.5rem;
  text-align: center;
}
.about-prose .kicker { text-align: center; }
.about-prose p {
  font-size: 1.2rem;
  margin: 0 0 1.15rem;
}

.page-intro {
  padding: 2.75rem 0 0.5rem;
  text-align: center;
}
.page-intro h1 {
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 500;
  color: var(--oxblood);
  margin: 0 0 0.6rem;
}
.page-intro p {
  max-width: 36rem;
  margin: 0 auto 0.5rem;
  color: var(--ink-soft);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--oxblood);
  color: var(--cream);
  padding: 2.5rem 0 2rem;
  margin-top: 0;
}
.site-footer a { color: var(--gold); }
.site-footer a:hover { color: var(--cream); }
.footer-brand {
  font-size: 1.35rem;
  font-weight: 500;
  margin: 0 0 0.25rem;
}
.footer-tag {
  font-style: italic;
  margin: 0 0 1.25rem;
  color: var(--cream);
  opacity: 0.9;
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  margin: 0 0 1.5rem;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
}
.footer-nav a { text-decoration: none; }
.footer-legal {
  border-top: 1px solid rgba(201, 178, 122, 0.35);
  padding-top: 1.15rem;
  font-size: 0.95rem;
  color: var(--cream);
  opacity: 0.88;
}
.footer-legal p { margin: 0 0 0.55rem; }

/* ---------- Mobile nav ---------- */
@media (max-width: 719px) {
  .nav-toggle { display: inline-flex; }
  .site-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--paper);
    border-bottom: 1px solid var(--rule);
    padding: 0.5rem 1.25rem 1rem;
  }
  .site-nav.is-open { display: block; }
  .site-nav ul {
    flex-direction: column;
    gap: 0.85rem;
  }
  .hero { padding: 2.5rem 0 2.25rem; }
}

@media (min-width: 720px) {
  .site-nav { display: block !important; }
}
