/* ═══════════════════════════════════════════
   xavierscribe.com — Shared Stylesheet
   Xavier Scribe Publishing
   ═══════════════════════════════════════════ */

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

/* ── VARIABLES ── */
:root {
  /* Neutrals */
  --white: #ffffff;
  --off-white: #f9f9f7;
  --light-gray: #f2f2f0;
  --mid-gray: #e4e4e0;
  --border: #e8e8e4;

  /* Text */
  --text-dark: #1e1e1e;
  --text-mid: #555550;
  --text-muted: #9a9a94;

  /* Book Accents */
  --accent-rra: #4e7c5f;         /* REST · RULE · ABIDE — forest green */
  --accent-rra-light: #d4ead9;   /* RRA light tint */
  --accent-rm: #c47b2b;          /* RELEASE ME — warm amber */
  --accent-rm-light: #f5dfc0;    /* RM light tint */

  /* Warmth Palette */
  --linen: #f7f3ed;
  --linen-mid: #e8e0d4;
  --linen-deep: #d4c9b8;
  --stone-dark: #8a7a6a;
  --bark: #6b5a48;
}

/* ── BODY ── */
body {
  background: var(--white);
  color: var(--text-dark);
  font-family: 'Jost', sans-serif;
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
}

/* ══════════════════════════════════════
   NAVIGATION
══════════════════════════════════════ */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 4rem;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(8px);
}

.nav-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.nav-logo img { height: 44px; }
img.nav-logo-full { display: block; }
img.nav-logo-mark { display: none; }

.nav-links {
  display: flex;
  gap: 2.5rem;
  list-style: none;
  align-items: center;
}

.nav-links a {
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--text-mid);
  text-decoration: none;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--text-dark); }

.nav-cta {
  font-size: 12px;
  font-weight: 600;
  background: #2d4a2d;
  color: white;
  padding: 8px 20px;
  border-radius: 40px;
  transition: background 0.2s;
}

/* Higher specificity to override .nav-links a color rules */
.nav-links a.nav-cta,
.nav-links a.nav-cta:hover {
  color: white;
}

.nav-cta:hover { background: #4c5f3b; }

/* ══════════════════════════════════════
   HERO
══════════════════════════════════════ */
.hero {
  padding: 130px 4rem 80px;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 5rem;
  align-items: center;
  min-height: 100vh;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.1s forwards;
}

.hero-tag-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent-rra);
}

.hero-title {
  font-family: 'Lora', serif;
  font-size: clamp(2.8rem, 4.5vw, 5rem);
  font-weight: 600;
  line-height: 1.1;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.25s forwards;
}

.hero-title em {
  font-style: italic;
  font-weight: 400;
  color: var(--text-mid);
}

.hero-divider {
  width: 48px;
  height: 2px;
  background: var(--text-dark);
  margin: 1.75rem 0;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.4s forwards;
}

.hero-statement {
  font-family: 'Cardo', serif;
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  font-style: italic;
  color: var(--text-mid);
  line-height: 2;
  margin-bottom: 2.5rem;
  max-width: 520px;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.55s forwards;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.7s forwards;
}

.hero-right {
  opacity: 0;
  animation: fadeUp 0.9s ease 0.4s forwards;
}

/* ── COVER CARDS ── */
.covers-stack {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  align-items: end;
}

.cover-card {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
  position: relative;
}

.cover-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.15);
}

.cover-card:first-child { margin-bottom: 2rem; }
.cover-card img { width: 100%; display: block; }

.cover-pill {
  position: absolute;
  bottom: 12px; left: 12px;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 40px;
  backdrop-filter: blur(8px);
}

.pill-rra { background: rgba(214, 235, 218, 0.92); color: #2d5c3a; }
.pill-rm  { background: rgba(245, 223, 192, 0.92); color: #7a4a10; }

/* ══════════════════════════════════════
   BUTTONS
══════════════════════════════════════ */
.btn-dark {
  font-family: 'Jost', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: white;
  background: var(--text-dark);
  border: none;
  padding: 14px 32px;
  border-radius: 40px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s, transform 0.2s;
}

.btn-dark:hover { background: #333; transform: translateY(-1px); }

.btn-light {
  font-family: 'Jost', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dark);
  background: transparent;
  border: 1.5px solid var(--border);
  padding: 13px 32px;
  border-radius: 40px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: border-color 0.2s, background 0.2s;
}

.btn-light:hover { border-color: var(--text-dark); background: var(--off-white); }

.btn-amazon {
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: white;
  background: var(--accent-rra);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 40px;
  transition: background 0.2s, transform 0.2s;
}

.btn-amazon::after { content: "→"; }
.btn-amazon:hover { background: #3a6048; transform: translateY(-1px); }

.btn-preview-xs {
  font-family: 'Jost', sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--accent-rra);
  background: transparent;
  border: 1px solid var(--accent-rra-light);
  padding: 9px 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
  white-space: nowrap;
}

.btn-preview-xs:hover {
  background: var(--accent-rra-light);
  border-color: var(--accent-rra);
}

.btn-buy-direct {
  font-family: 'Jost', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: white;
  background: var(--bark);
  border: none;
  padding: 9px 16px;
  border-radius: 6px;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
  white-space: nowrap;
}

.btn-buy-direct:hover { background: #5a4a38; transform: translateY(-1px); }

/* ══════════════════════════════════════
   SCRIPTURE BAND
══════════════════════════════════════ */
.scripture-band {
  background: var(--off-white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 3rem 2rem;
  text-align: center;
}

.scripture-band p {
  font-family: 'Cardo', serif;
  font-style: italic;
  font-size: clamp(1rem, 1.8vw, 1.2rem);
  color: var(--text-mid);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.9;
}

.scripture-band cite {
  display: block;
  font-family: 'Jost', sans-serif;
  font-style: normal;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 1rem;
}

/* ══════════════════════════════════════
   CATALOG / BOOK CARDS
══════════════════════════════════════ */
.catalog-section {
  padding: 6rem 4rem;
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 3rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1.25rem;
}

.section-tag {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.section-title {
  font-family: 'Lora', serif;
  font-size: clamp(1.6rem, 2.5vw, 2.2rem);
  font-weight: 600;
  color: var(--text-dark);
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.book-card {
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  background: var(--white);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.book-card:hover {
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
  transform: translateY(-3px);
}

.book-card-available {
  border-color: rgba(78, 124, 95, 0.35);
  box-shadow: 0 0 0 1px rgba(78, 124, 95, 0.2);
}

.book-card-top {
  padding: 2rem 2rem 0;
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}

.book-thumb {
  width: 100px;
  flex-shrink: 0;
  border-radius: 6px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.book-meta { flex: 1; padding-top: 4px; }

.book-type-tag {
  display: inline-block;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 40px;
  margin-bottom: 0.6rem;
}

.tag-rra { background: var(--accent-rra-light); color: #2d5c3a; }
.tag-rm  { background: var(--accent-rm-light);  color: #7a4a10; }

.book-status {
  display: inline-block;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 40px;
  margin-left: 6px;
  background: var(--light-gray);
  color: var(--text-muted);
  border: 1px solid var(--mid-gray);
}

.book-status-available {
  display: inline-block;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 40px;
  margin-left: 6px;
  background: var(--accent-rra-light);
  color: #2d5c3a;
  border: 1px solid rgba(78, 124, 95, 0.35);
}

.book-title {
  font-family: 'Lora', serif;
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--text-dark);
  line-height: 1.25;
  margin-bottom: 0.3rem;
}

.book-tagline {
  font-size: 0.88rem;
  font-style: italic;
  color: var(--text-muted);
  line-height: 1.5;
  font-family: 'Cardo', serif;
}

.book-card-body { padding: 1.5rem 2rem 2rem; }

.book-desc {
  font-size: 0.9rem;
  color: var(--text-mid);
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

.book-price {
  font-family: 'Jost', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.book-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.book-accent-line {
  width: 32px; height: 3px;
  border-radius: 3px;
}

.line-rra { background: var(--accent-rra); }
.line-rm  { background: var(--accent-rm); }

.book-cta {
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dark);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.2s;
}

.book-cta:hover { gap: 10px; }
.book-cta::after { content: "→"; }

.rra-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
}

/* ══════════════════════════════════════
   NOTIFY SECTION
══════════════════════════════════════ */
.notify-section {
  background: var(--off-white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 6rem 4rem;
  text-align: center;
}

.notify-inner { max-width: 560px; margin: 0 auto; }

.notify-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.notify-title {
  font-family: 'Lora', serif;
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 1rem;
  line-height: 1.2;
}

.notify-desc {
  font-size: 1rem;
  color: var(--text-mid);
  line-height: 1.8;
  margin-bottom: 2rem;
}

.notify-form {
  display: flex;
  max-width: 460px;
  margin: 0 auto;
  border: 1.5px solid var(--mid-gray);
  border-radius: 40px;
  overflow: hidden;
  background: white;
  transition: border-color 0.2s;
}

.notify-form:focus-within { border-color: var(--text-dark); }

.notify-input {
  flex: 1;
  padding: 14px 22px;
  background: transparent;
  border: none;
  color: var(--text-dark);
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
  outline: none;
}

.notify-input::placeholder { color: var(--text-muted); }

.notify-btn {
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--text-dark);
  color: white;
  border: none;
  padding: 14px 26px;
  border-radius: 0 38px 38px 0;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s;
  margin: 3px;
}

.notify-btn:hover { background: #333; }

.notify-note { font-size: 0.78rem; color: var(--text-muted); margin-top: 1rem; }

.notify-success {
  display: none;
  color: var(--accent-rra);
  font-style: italic;
  margin-top: 1.5rem;
  font-family: 'Cardo', serif;
  font-size: 1.05rem;
}

.notify-error {
  color: var(--accent-rm);
  font-style: italic;
  margin-top: 1.5rem;
  font-family: 'Cardo', serif;
}

/* ══════════════════════════════════════
   ABOUT SECTION
══════════════════════════════════════ */
.about-section {
  padding: 6rem 4rem;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.about-text {
  font-family: 'Cardo', serif;
  font-size: 1.05rem;
  color: var(--text-mid);
  line-height: 1.9;
  margin-bottom: 2.5rem;
  font-style: italic;
}

/* ══════════════════════════════════════
   FOOTER
══════════════════════════════════════ */
footer {
  background: var(--text-dark);
  text-align: center;
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.footer-logo-mark {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}

.footer-logo-mark span {
  font-family: 'Lora', serif;
  font-size: 15px;
  font-weight: 600;
  color: white;
}

.footer-name {
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: white;
  letter-spacing: 0.06em;
}

.footer-text {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 0.05em;
}

.footer-link {
  font-family: 'Jost', sans-serif;
  font-size: 12px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  letter-spacing: 0.06em;
  transition: color 0.2s;
}

.footer-link:hover { color: rgba(255, 255, 255, 0.9); }

/* ══════════════════════════════════════
   ANIMATIONS
══════════════════════════════════════ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ══════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════ */
@media (max-width: 768px) {
  nav { padding: 1rem 1.5rem; }
  .nav-links { gap: 1rem; }
  .nav-links li:not(:last-child) { display: none; }
  img.nav-logo-full { display: none; }
  img.nav-logo-mark { display: block; }
  .hero {
    grid-template-columns: 1fr;
    gap: 3rem;
    padding: 110px 1.5rem 4rem;
    min-height: auto;
  }
  .covers-stack { max-width: 320px; margin: 0 auto; }
  .catalog-section { padding: 4rem 1.5rem; }
  .notify-section { padding: 4rem 1.5rem; }
  .about-section { padding: 4rem 1.5rem; }
  .notify-form { flex-direction: column; border-radius: 12px; }
  .notify-btn { border-radius: 0 0 10px 10px; margin: 0; padding: 14px; }
}

/* ══════════════════════════════════════
   RRA BOOK BUTTON (hero)
══════════════════════════════════════ */
.btn-rra {
  font-family: 'Jost', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: white;
  background: #2d4a2d;
  border: 1.5px solid #2d4a2d;
  padding: 13px 32px;
  border-radius: 40px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background 0.2s, transform 0.2s;
}

.btn-rra:hover { background: #4c5f3b; border-color: #4c5f3b; transform: translateY(-1px); }

/* ══════════════════════════════════════
   BOOK PREVIEW MODAL
══════════════════════════════════════ */
#xs-preview-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

#xs-preview-modal.open {
  opacity: 1;
  pointer-events: all;
}

.xs-overlay {
  position: absolute;
  inset: 0;
  background: rgba(20, 18, 15, 0.78);
  backdrop-filter: blur(3px);
}

.xs-preview-container {
  position: relative;
  z-index: 1;
  background: var(--white);
  width: min(660px, 95vw);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.35);
  transform: translateY(16px);
  transition: transform 0.3s ease;
  overflow: hidden;
}

#xs-preview-modal.open .xs-preview-container {
  transform: translateY(0);
}

.xs-preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--linen);
}

.xs-preview-eyebrow {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-rra);
  margin-bottom: 0.2rem;
}

.xs-preview-title {
  font-family: 'Lora', serif;
  font-size: 1rem;
  font-style: italic;
  color: var(--text-dark);
  font-weight: 400;
}

.xs-close-btn {
  background: none;
  border: none;
  font-size: 1rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  transition: color 0.2s, background 0.2s;
  line-height: 1;
}

.xs-close-btn:hover { color: var(--text-dark); background: var(--mid-gray); }

.xs-preview-body {
  flex: 1;
  overflow: hidden;
  background: var(--light-gray);
  position: relative;
}

.xs-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  height: 420px;
  color: var(--text-muted);
  font-family: 'Cardo', serif;
  font-style: italic;
  font-size: 1rem;
}

.xs-spinner {
  width: 28px;
  height: 28px;
  border: 2px solid var(--mid-gray);
  border-top-color: var(--accent-rra);
  border-radius: 50%;
  animation: xs-spin 0.9s linear infinite;
}

@keyframes xs-spin { to { transform: rotate(360deg); } }

.xs-reader {
  display: flex;
  align-items: center;
  height: 100%;
  min-height: 420px;
}

.xs-page-area {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: auto;
  padding: 1.5rem 0;
}

#xs-pdf-canvas {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 2px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}

.xs-nav-btn {
  background: none;
  border: none;
  font-size: 1.8rem;
  color: var(--stone-dark);
  cursor: pointer;
  padding: 1rem;
  transition: color 0.2s, background 0.2s;
  height: 100%;
  display: flex;
  align-items: center;
  border-radius: 0;
}

.xs-nav-btn:hover { color: var(--text-dark); background: rgba(0,0,0,0.04); }
.xs-nav-btn:disabled { opacity: 0.2; cursor: default; }
.xs-nav-btn:disabled:hover { background: none; }

.xs-preview-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem 1.5rem;
  border-top: 1px solid var(--border);
  background: var(--linen);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.xs-page-num {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.xs-footer-btns {
  display: flex;
  gap: 0.6rem;
  align-items: center;
}
