/* === FOUNDATION === */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  font-family: 'Cormorant Garamond', Georgia, serif;
  background: #FAF8F4;
  color: #231F20;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.sans { font-family: 'Inter', system-ui, -apple-system, sans-serif; }
a { color: inherit; }
section[id] { scroll-margin-top: 80px; }

/* === TYPOGRAPHY SCALE === */
h1 { font-size: clamp(2.4rem, 5vw, 4rem); font-weight: 300; letter-spacing: 0.06em; line-height: 1.1; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 400; letter-spacing: 0.08em; line-height: 1.3; }
h3 { font-size: 1.15rem; font-weight: 500; letter-spacing: 0.03em; line-height: 1.4; }
p { line-height: 1.75; }
.eyebrow {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem; font-weight: 500;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: #9A8A70;
}

/* === NAV === */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 1.2rem 2.5rem;
  display: flex; align-items: center; justify-content: space-between;
  background: rgba(250, 248, 244, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(35, 31, 32, 0.06);
  transition: all 0.3s;
}
nav.on-dark {
  background: rgba(35, 31, 32, 0.85);
  border-bottom-color: rgba(242, 237, 223, 0.08);
}
nav.on-dark .logo { color: #F2EDDF; }
nav.on-dark .nav-links a { color: #B0A898; }
nav.on-dark .nav-links a:hover { color: #F2EDDF; }
nav .logo {
  font-size: 0.8rem; font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: #231F20; text-decoration: none;
}
nav .nav-links { display: flex; gap: 2rem; }
nav .nav-links a {
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem; font-weight: 400;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: #6A5A48; text-decoration: none;
  transition: color 0.2s;
}
nav .nav-links a:hover { color: #231F20; }

/* === HERO === */
.hero {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  padding: 8rem 2.5rem 5rem;
  background: #231F20;
  color: #F2EDDF;
  position: relative;
  overflow: hidden;
}
.hero-inner {
  max-width: 1200px; width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}
.hero-text { max-width: 520px; }
.hero-text .eyebrow { color: #9A8A70; margin-bottom: 1.5rem; }
.hero-text h1 { color: #F2EDDF; margin-bottom: 1.5rem; }
.hero-text p {
  color: #B0A898; font-size: 1.1rem;
  max-width: 440px; margin-bottom: 2.5rem;
}
.hero-text .cta {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: #F2EDDF; text-decoration: none;
  border: 1px solid #6A5A48;
  padding: 0.8rem 2rem;
  transition: all 0.3s;
}
.hero-text .cta:hover { background: #F2EDDF; color: #231F20; }

/* Outline CTA on light backgrounds (e.g., "See all 143 planned editions") */
.see-all-row { text-align: center; margin-top: 3rem; }
.cta-outline {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: #6A5A48; text-decoration: none;
  border: 1px solid #C8A048;
  padding: 0.8rem 2rem;
  transition: all 0.3s;
}
.cta-outline:hover { background: #C8A048; color: #231F20; }
.hero-image {
  display: flex; justify-content: center;
  position: relative;
}
.hero-image img {
  max-height: 520px; width: auto;
  box-shadow: 8px 12px 40px rgba(0,0,0,0.5);
  border-radius: 2px;
}

/* === SECTION === */
.section { padding: clamp(4rem, 8vw, 7rem) 2.5rem; }
.section-inner { max-width: 1100px; margin: 0 auto; }
.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-header h2 { color: #231F20; text-transform: uppercase; margin-bottom: 0.8rem; }
.section-header p { color: #6A5A48; max-width: 580px; margin: 0 auto; font-size: 1.05rem; }
.divider { width: 40px; height: 1px; background: #C8A048; margin: 1.5rem auto; }

/* === BOOK GRID === */
.book-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 3rem 2rem;
}
.book-card { text-align: center; }
.book-card a { text-decoration: none; color: inherit; display: block; }
.book-card img {
  width: 100%; max-width: 220px;
  box-shadow: 4px 6px 24px rgba(35, 31, 32, 0.18);
  border-radius: 2px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.book-card a:hover img {
  transform: translateY(-6px);
  box-shadow: 6px 12px 36px rgba(35, 31, 32, 0.25);
}
.book-card h3 {
  margin-top: 1.2rem; font-size: 1rem;
  color: #231F20;
}
.book-card .author {
  font-style: italic; font-size: 0.92rem;
  color: #8A7A68; margin-top: 0.2rem;
}
.book-card .meta {
  font-family: 'Inter', sans-serif;
  font-size: 0.65rem; color: #A09080;
  letter-spacing: 0.05em; margin-top: 0.4rem;
}
.book-card .badge {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 0.58rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  padding: 0.2rem 0.6rem;
  margin-top: 0.5rem;
  border: 1px solid #C8A048;
  color: #8A6F2A;
}
.book-card .badge.forthcoming {
  border-color: #CBC4B4;
  color: #A09080;
}

/* === FEATURES === */
.features-bg { background: #231F20; color: #F2EDDF; }
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2.5rem;
}
.feature { padding: 2rem 1.5rem; border-left: 2px solid #3A3530; }
.feature h3 {
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: #C8A048; margin-bottom: 0.8rem;
}
.feature p { font-size: 0.95rem; color: #A09888; line-height: 1.7; }

/* === PROVENANCE === */
.provenance { background: #F2EDDF; }
.provenance-inner {
  max-width: 680px; margin: 0 auto;
  text-align: center;
}
.provenance-inner p {
  font-size: 1.05rem; color: #4A3A2E;
  margin: 0 auto 1.2rem; max-width: 620px;
}
.provenance-stat-row {
  display: flex; flex-wrap: wrap;
  justify-content: center; gap: 3rem;
  margin-top: 2.5rem;
}
.pstat { text-align: center; }
.pstat .num {
  display: block;
  font-size: 2.5rem; font-weight: 300;
  color: #231F20; line-height: 1.1;
}
.pstat .label {
  font-family: 'Inter', sans-serif;
  font-size: 0.62rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: #9A8A70;
}

/* === FOOTER === */
footer {
  background: #1A1816; color: #8A7A68;
  padding: 4rem 2.5rem 2rem;
}
.footer-inner {
  max-width: 1100px; margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
}
.footer-brand h3 {
  font-size: 1rem; font-weight: 400;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: #C8A048; margin-bottom: 0.8rem;
}
.footer-brand p { font-size: 0.88rem; line-height: 1.7; color: #6A5A48; max-width: 360px; }
.footer-col h4 {
  font-family: 'Inter', sans-serif;
  font-size: 0.65rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: #6A5A48; margin-bottom: 1rem;
}
.footer-col p, .footer-col a {
  font-size: 0.85rem; color: #8A7A68;
  text-decoration: none; display: block;
  margin-bottom: 0.4rem; transition: color 0.2s;
}
.footer-col a:hover { color: #F2EDDF; }
.footer-bottom {
  max-width: 1100px; margin: 2.5rem auto 0;
  padding-top: 1.5rem;
  border-top: 1px solid #2A2520;
  display: flex; justify-content: space-between;
  font-family: 'Inter', sans-serif;
  font-size: 0.62rem; color: #4A3A2E;
  letter-spacing: 0.05em;
}

/* === BOOK PAGE === */
.book-hero {
  padding: 8rem 2.5rem 4rem;
  background: #231F20;
  color: #F2EDDF;
}
.book-hero-inner {
  max-width: 1100px; margin: 0 auto;
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 4rem;
  align-items: start;
}
.book-hero-cover img {
  width: 100%; border-radius: 2px;
  box-shadow: 8px 12px 40px rgba(0,0,0,0.5);
}
.book-hero-text .eyebrow { color: #9A8A70; margin-bottom: 1rem; }
.book-hero-text h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  color: #F2EDDF; margin-bottom: 0.4rem;
}
.book-hero-text .byline {
  font-style: italic; font-size: 1.2rem;
  color: #C8A048; margin-bottom: 2rem;
}
.book-hero-text .meta-row {
  display: flex; flex-wrap: wrap;
  gap: 2rem; margin-bottom: 2rem;
  padding: 1.2rem 0;
  border-top: 1px solid #3A3530;
  border-bottom: 1px solid #3A3530;
}
.book-hero-text .meta-item {
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
}
.book-hero-text .meta-item .label {
  display: block;
  font-size: 0.6rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: #6A5A48; margin-bottom: 0.3rem;
}
.book-hero-text .meta-item .value {
  color: #F2EDDF;
}
.book-hero-text .cta-row {
  display: flex; flex-wrap: wrap; gap: 1rem;
  margin-top: 1.5rem;
}
.cta-primary, .cta-secondary {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  text-decoration: none;
  padding: 0.85rem 2rem;
  transition: all 0.3s;
}
.cta-primary {
  color: #231F20; background: #C8A048;
  border: 1px solid #C8A048;
}
.cta-primary:hover { background: #D8B058; border-color: #D8B058; }
.cta-secondary {
  color: #F2EDDF; background: transparent;
  border: 1px solid #6A5A48;
}
.cta-secondary:hover { background: #F2EDDF; color: #231F20; }

/* === BOOK DESCRIPTION === */
.book-body { padding: 4rem 2.5rem; }
.book-body-inner {
  max-width: 720px; margin: 0 auto;
  font-size: 1.1rem; line-height: 1.8;
  color: #2A2622;
}
.book-body-inner p { margin-bottom: 1.3rem; }
.book-body-inner b { color: #231F20; font-weight: 600; }
.book-body-inner ul {
  margin: 1.5rem 0 1.5rem 1.5rem;
}
.book-body-inner li {
  margin-bottom: 0.5rem; line-height: 1.7;
}
.book-body-inner br { display: none; }

/* === RELATED BOOKS === */
.related {
  background: #F2EDDF;
  padding: 4rem 2.5rem;
}
.related-inner {
  max-width: 1100px; margin: 0 auto;
}
.related h2 {
  text-align: center;
  text-transform: uppercase;
  margin-bottom: 2.5rem;
  color: #231F20;
}

/* === LIBRARY PAGE === */
.library-header {
  padding: 9rem 2.5rem 4rem;
  text-align: center;
  background: #F2EDDF;
}
.library-header h1 {
  color: #231F20;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.library-header p {
  max-width: 620px; margin: 0 auto;
  color: #4A3A2E; font-size: 1.1rem;
}
.library-filter {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 1rem; margin-top: 2rem;
}
.library-filter button {
  font-family: 'Inter', sans-serif;
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
  background: transparent; border: 1px solid #C8A048;
  color: #6A5A48;
  padding: 0.6rem 1.3rem;
  cursor: pointer;
  transition: all 0.2s;
}
.library-filter button.active,
.library-filter button:hover {
  background: #C8A048; color: #231F20;
}
.library-series {
  padding: 4rem 2.5rem;
}
.library-series-inner {
  max-width: 1100px; margin: 0 auto;
}
.series-block { margin-bottom: 4rem; }
.series-block h2 {
  color: #231F20;
  text-transform: uppercase;
  border-bottom: 1px solid #C8A048;
  padding-bottom: 0.8rem;
  margin-bottom: 2rem;
}
.series-block h2 .count {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem; font-weight: 500;
  letter-spacing: 0.15em;
  color: #8A7A68;
  margin-left: 1rem;
  letter-spacing: 0.1em;
}
.library-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(440px, 1fr));
  gap: 0.25rem 3rem;
}
.library-item {
  padding: 0.9rem 0;
  border-bottom: 1px dotted rgba(138, 122, 104, 0.3);
  display: grid;
  grid-template-columns: 3.5rem 1fr auto;
  align-items: baseline;
  column-gap: 1rem;
  text-decoration: none; color: inherit;
  transition: background 0.15s;
}
.library-item.available { color: #231F20; }
.library-item.forthcoming { color: #8A7A68; }
.library-item.available:hover {
  background: rgba(200, 160, 72, 0.06);
}
.library-item .volume-number {
  font-family: 'Inter', sans-serif;
  font-size: 0.62rem; font-weight: 500;
  letter-spacing: 0.1em;
  color: #A09080;
  text-transform: uppercase;
}
.library-item .title-author {
  display: flex; flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}
.library-item .title {
  font-size: 1rem; line-height: 1.35;
}
.library-item .author {
  font-style: italic;
  font-size: 0.82rem;
  color: #8A7A68;
  line-height: 1.3;
}
.library-item .author:empty { display: none; }
.library-item.available:hover .title {
  color: #8A6F2A;
}
.library-item .status-mark {
  font-family: 'Inter', sans-serif;
  font-size: 0.55rem; font-weight: 500;
  letter-spacing: 0.15em; text-transform: uppercase;
}
.library-item.available .status-mark { color: #C8A048; }
.library-item.forthcoming .status-mark { color: #A09080; }

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .book-hero-inner { grid-template-columns: 1fr; gap: 2.5rem; }
  .book-hero-cover { max-width: 280px; margin: 0 auto; }
}
@media (max-width: 768px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; }
  .hero-text { max-width: 100%; }
  .hero-text p { margin-left: auto; margin-right: auto; }
  .hero-image { margin-top: 2rem; }
  .hero-image img { max-height: 380px; }
  .book-grid { grid-template-columns: repeat(2, 1fr); gap: 2rem 1.5rem; }
  .footer-inner { grid-template-columns: 1fr; }
  nav { padding: 1rem 1.5rem; }
  nav .nav-links { gap: 1.2rem; }
  .library-list { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .book-grid { grid-template-columns: repeat(2, 1fr); gap: 1.5rem 1rem; }
  .feature-grid { grid-template-columns: 1fr; }
  .book-hero-text .cta-row { flex-direction: column; align-items: stretch; }
  .cta-primary, .cta-secondary { text-align: center; }
}
