/* LIZARD BOOKS LLC — concept "A bookshelf in the sun" */
:root {
  --c-parchment: #F6F0E4;
  --c-sand: #E9DEC8;
  --c-ink: #1D1A17;
  --c-green: #3E6B3F;
  --c-green-dark: #2E5230;
  --c-ochre: #C68B2C;
  --c-oxblood: #7B2D26;
  --c-muted: #544C43;
  --c-paper: #FFFCF6;
  --c-line: rgba(29, 26, 23, 0.14);
  --c-error: #9A2A1F;

  --f-display: "DM Serif Display", Georgia, "Times New Roman", serif;
  --f-body: "Karla", system-ui, -apple-system, "Segoe UI", sans-serif;

  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4.5rem;
  --s-9: 6.5rem;

  --r-sm: 4px;
  --r-md: 10px;
  --r-lg: 20px;
  --r-pill: 999px;

  --sh-soft: 0 12px 28px -18px rgba(29, 26, 23, 0.4);
  --sh-book: inset -6px 0 10px -6px rgba(0, 0, 0, 0.35), inset 4px 0 6px -4px rgba(255, 255, 255, 0.25);

  --wrap: 1180px;
  --gutter: 1rem;
  --header-h: 64px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--c-ink);
  background: var(--c-parchment);
  overflow-x: hidden;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--c-green-dark); text-underline-offset: 3px; }
a:hover { color: var(--c-oxblood); }
:focus-visible { outline: 3px solid var(--c-ochre); outline-offset: 3px; border-radius: var(--r-sm); }

h1, h2, h3 { font-family: var(--f-display); font-weight: 400; line-height: 1.08; margin: 0 0 var(--s-4); }
h1 { font-size: clamp(2.5rem, 9vw, 5rem); }
h2 { font-size: clamp(1.9rem, 5.5vw, 3rem); }
h3 { font-size: 1.45rem; }
p { margin: 0 0 var(--s-4); }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

.skip-link {
  position: absolute; left: var(--s-4); top: -100px; z-index: 100;
  background: var(--c-ink); color: var(--c-parchment);
  padding: var(--s-2) var(--s-4); border-radius: var(--r-sm);
}
.skip-link:focus { top: var(--s-4); color: var(--c-parchment); }

.kicker {
  font-family: var(--f-body);
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--c-oxblood);
  margin-bottom: var(--s-3);
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 var(--s-5);
  border-radius: var(--r-pill); border: 2px solid transparent;
  font-family: var(--f-body); font-weight: 700; font-size: 1rem;
  text-decoration: none; cursor: pointer;
  transition: transform 0.25s var(--ease);
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--c-green); color: #fff; }
.btn--primary:hover { background: var(--c-green-dark); color: #fff; }
.btn--ghost { border-color: var(--c-ink); color: var(--c-ink); }
.btn--ghost:hover { color: var(--c-ink); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(246, 240, 228, 0.95);
  border-bottom: 1px solid var(--c-line);
}
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--s-4); min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: var(--s-3); color: var(--c-ink); text-decoration: none; }
.brand__mark { width: 36px; height: 36px; flex-shrink: 0; }
.brand__name { font-family: var(--f-display); font-size: 1.3rem; line-height: 1; letter-spacing: 0.02em; }
.brand__name small { display: block; margin-top: 4px; font-family: var(--f-body); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.2em; color: var(--c-muted); }

.nav-toggle {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
  width: 46px; height: 46px; padding: 0 11px;
  border: 1px solid var(--c-line); border-radius: var(--r-md);
  background: var(--c-paper); cursor: pointer;
}
.nav-toggle span { display: block; height: 2px; width: 100%; background: var(--c-ink); border-radius: 2px; transition: transform 0.3s var(--ease), opacity 0.3s var(--ease); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.site-nav {
  position: fixed; inset: var(--header-h) 0 auto 0;
  background: var(--c-parchment);
  border-bottom: 1px solid var(--c-line);
  box-shadow: var(--sh-soft);
  padding: var(--s-4) var(--gutter) var(--s-6);
  opacity: 0; transform: translateY(-12px);
  visibility: hidden; pointer-events: none;
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
}
.site-nav.is-open { opacity: 1; transform: none; visibility: visible; pointer-events: auto; }
.site-nav ul { list-style: none; margin: 0; padding: 0; }
.site-nav a { display: block; padding: var(--s-3) 0; font-weight: 700; color: var(--c-ink); text-decoration: none; border-bottom: 1px solid var(--c-line); }
.site-nav a:hover { color: var(--c-oxblood); }
.site-nav .nav-cta { margin-top: var(--s-4); }
.site-nav .nav-cta a { border: 0; text-align: center; background: var(--c-ink); color: var(--c-parchment); border-radius: var(--r-pill); }

/* Hero */
.hero {
  position: relative;
  padding: var(--s-7) 0 var(--s-8);
  background:
    radial-gradient(90% 70% at 85% 10%, rgba(198, 139, 44, 0.22), transparent 60%),
    var(--c-parchment);
  overflow: hidden;
}
.hero__grid { display: grid; gap: var(--s-7); align-items: end; }
.hero h1 em { font-style: italic; color: var(--c-green); }
.hero__lead { font-size: 1.15rem; color: var(--c-muted); max-width: 34rem; }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--s-3); margin-top: var(--s-5); }

/* Shelf */
.shelf { position: relative; width: 100%; max-width: 480px; margin: 0 auto; padding-top: var(--s-6); }
.shelf__books { display: flex; align-items: flex-end; gap: 4px; height: 260px; padding: 0 var(--s-4); }
.book {
  position: relative;
  flex: 1 1 0;
  border-radius: 3px 3px 0 0;
  box-shadow: var(--sh-book);
  transition: transform 0.4s var(--ease);
}
.book::before, .book::after {
  content: ""; position: absolute; left: 18%; right: 18%; height: 2px;
  background: rgba(255, 255, 255, 0.45);
}
.book::before { top: 14%; }
.book::after { bottom: 14%; }
.book:nth-child(1) { height: 78%; background: var(--c-green); }
.book:nth-child(2) { height: 92%; background: var(--c-oxblood); flex-grow: 1.3; }
.book:nth-child(3) { height: 70%; background: var(--c-ochre); }
.book:nth-child(4) { height: 100%; background: var(--c-ink); flex-grow: 1.5; transform: translateY(-14px); }
.book:nth-child(5) { height: 84%; background: repeating-linear-gradient(0deg, #D8C9AA 0 6px, var(--c-sand) 6px 12px); }
.book:nth-child(6) { height: 74%; background: var(--c-green-dark); }
.book:nth-child(7) { height: 88%; background: var(--c-oxblood); transform: rotate(6deg); transform-origin: bottom left; margin-right: 9%; }
.book:nth-child(4)::before, .book:nth-child(4)::after { background: var(--c-ochre); }
.shelf:hover .book:nth-child(4) { transform: translateY(-26px); }
.shelf__board {
  position: relative; height: 18px;
  background: linear-gradient(180deg, #8A5E35, #6B4627);
  border-radius: 3px;
  box-shadow: 0 14px 22px -12px rgba(29, 26, 23, 0.55);
}
.lizard-run {
  position: absolute; left: 0; top: -30px;
  width: calc(100% - 92px); height: 34px;
  animation: crawl 22s linear infinite;
}
.lizard {
  width: 92px; height: 34px;
  animation: turn 22s steps(1, end) infinite;
}
.lizard svg { width: 100%; height: 100%; }
.shelf__caption { margin-top: var(--s-4); text-align: center; font-size: 0.9rem; color: var(--c-muted); font-style: italic; }

@keyframes crawl {
  0% { transform: translateX(0); }
  48% { transform: translateX(100%); }
  52% { transform: translateX(100%); }
  100% { transform: translateX(0); }
}
@keyframes turn {
  0% { transform: scaleX(1); }
  50% { transform: scaleX(-1); }
}

/* Sections */
.section { padding: var(--s-8) 0; }
.section--sand { background: var(--c-sand); }
.section--ink { background: var(--c-ink); color: var(--c-parchment); }
.section--ink h2, .section--ink h3 { color: var(--c-paper); }
.section--ink .kicker { color: var(--c-ochre); }
.section__head { max-width: 46rem; margin-bottom: var(--s-6); }
.section__head p { color: var(--c-muted); font-size: 1.1rem; }
.section--ink .section__head p { color: #D8D0C2; }

/* Imprints */
.imprints { display: grid; gap: var(--s-5); }
.imprint {
  position: relative;
  display: grid;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--c-paper);
  border: 1px solid var(--c-line);
  box-shadow: var(--sh-soft);
}
.imprint__cover { min-height: 180px; position: relative; }
.imprint__cover--fiction {
  background:
    radial-gradient(circle at 75% 35%, var(--c-ochre) 0 16%, transparent 17%),
    repeating-linear-gradient(125deg, rgba(255, 255, 255, 0.07) 0 2px, transparent 2px 12px),
    linear-gradient(160deg, var(--c-green), var(--c-green-dark));
}
.imprint__cover--faith {
  background:
    linear-gradient(90deg, transparent 47%, rgba(246, 240, 228, 0.85) 47% 53%, transparent 53%),
    linear-gradient(0deg, transparent 58%, rgba(246, 240, 228, 0.85) 58% 64%, transparent 64%),
    radial-gradient(circle at 50% 61%, rgba(198, 139, 44, 0.6), transparent 45%),
    linear-gradient(160deg, var(--c-oxblood), #5A1F1A);
}
.imprint__body { padding: var(--s-5); }
.imprint__body p { color: var(--c-muted); }
.tags { list-style: none; display: flex; flex-wrap: wrap; gap: var(--s-2); padding: 0; margin: var(--s-4) 0 0; }
.tags li { font-size: 0.85rem; font-weight: 700; padding: var(--s-1) var(--s-3); border-radius: var(--r-pill); background: var(--c-sand); color: var(--c-ink); }

/* Path (how a book travels) */
.path { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-5); counter-reset: p; }
.path li { position: relative; padding: var(--s-5); border: 1px solid rgba(246, 240, 228, 0.18); border-radius: var(--r-lg); counter-increment: p; }
.path li::before {
  content: counter(p, upper-roman);
  display: block;
  font-family: var(--f-display); font-size: 2.2rem; line-height: 1;
  color: var(--c-ochre); margin-bottom: var(--s-3);
}
.path p { color: #D8D0C2; margin: 0; }

/* Shop / events split */
.split { display: grid; gap: var(--s-6); align-items: center; }
.split__art {
  min-height: 280px; border-radius: var(--r-lg); position: relative; overflow: hidden;
  background:
    repeating-linear-gradient(90deg, transparent 0 22px, rgba(29, 26, 23, 0.06) 22px 24px),
    linear-gradient(180deg, var(--c-sand), #DCCDB0);
}
.split__art--events {
  background:
    radial-gradient(circle at 20% 30%, rgba(198, 139, 44, 0.45) 0 10%, transparent 11%),
    radial-gradient(circle at 70% 60%, rgba(62, 107, 63, 0.4) 0 14%, transparent 15%),
    radial-gradient(circle at 45% 85%, rgba(123, 45, 38, 0.35) 0 9%, transparent 10%),
    var(--c-parchment);
  border: 1px solid var(--c-line);
}
.split__stack {
  position: absolute; left: 50%; bottom: 0; transform: translateX(-50%);
  width: 60%; display: grid; gap: 4px;
}
.split__stack span { display: block; height: 26px; border-radius: 3px; box-shadow: var(--sh-book); }
.split__stack span:nth-child(1) { background: var(--c-oxblood); width: 82%; margin-left: 8%; }
.split__stack span:nth-child(2) { background: var(--c-green); width: 94%; }
.split__stack span:nth-child(3) { background: var(--c-ink); width: 88%; margin-left: 5%; }
.split__stack span:nth-child(4) { background: var(--c-ochre); width: 100%; }
.split__quote {
  position: absolute; inset: var(--s-5); margin: 0;
  display: grid; place-items: center; text-align: center;
  font-family: var(--f-display); font-size: clamp(1.5rem, 5vw, 2.2rem); line-height: 1.15; color: var(--c-ink);
}
.check-list { list-style: none; margin: var(--s-4) 0 0; padding: 0; display: grid; gap: var(--s-3); }
.check-list li { position: relative; padding-left: var(--s-6); }
.check-list li::before {
  content: ""; position: absolute; left: 0; top: 0.35em;
  width: 14px; height: 18px; background: var(--c-green);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 75%, 0 100%);
}

/* Audiences */
.audiences { display: grid; gap: var(--s-4); }
.audience { padding: var(--s-5); background: var(--c-paper); border-radius: var(--r-lg); border-top: 5px solid var(--c-green); box-shadow: var(--sh-soft); }
.audience:nth-child(2) { border-top-color: var(--c-ochre); }
.audience:nth-child(3) { border-top-color: var(--c-oxblood); }
.audience p { color: var(--c-muted); margin: 0; }

/* Contact */
.contact { display: grid; gap: var(--s-6); }
.contact__info dl { margin: 0; display: grid; gap: var(--s-4); }
.contact__info dt { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--c-muted); }
.contact__info dd { margin: 0; word-break: break-word; }

.form { background: var(--c-paper); border: 1px solid var(--c-line); border-radius: var(--r-lg); padding: var(--s-5); box-shadow: var(--sh-soft); }
.form__row { display: grid; gap: 0 var(--s-4); }
.field { display: grid; gap: var(--s-1); margin-bottom: var(--s-3); }
.field label { font-weight: 700; font-size: 0.95rem; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: var(--s-3) var(--s-4);
  font: inherit; color: var(--c-ink); background: var(--c-parchment);
  border: 1.5px solid rgba(29, 26, 23, 0.3); border-radius: var(--r-md);
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--c-green); box-shadow: 0 0 0 3px rgba(62, 107, 63, 0.25); }
.field.is-invalid input, .field.is-invalid select, .field.is-invalid textarea { border-color: var(--c-error); }
.field__error { min-height: 1.2em; font-size: 0.85rem; color: var(--c-error); }
.field--check { grid-template-columns: auto 1fr; align-items: start; gap: var(--s-3); }
.field--check input { width: 22px; height: 22px; min-height: 0; margin-top: 3px; accent-color: var(--c-green); }
.field--check label { font-weight: 400; font-size: 0.95rem; color: var(--c-muted); }
.field--check .field__error { grid-column: 1 / -1; }
.form__success { display: none; padding: var(--s-5); border-radius: var(--r-md); background: var(--c-paper); border-left: 4px solid var(--c-green); }
.form__success.is-visible { display: block; }

/* Legal & 404 */
.page-hero { padding: var(--s-7) 0 var(--s-5); background: var(--c-sand); }
.page-hero h1 { font-size: clamp(2.2rem, 7vw, 3.6rem); margin: 0; }
.legal { padding: var(--s-7) 0 var(--s-8); }
.legal__body { max-width: 46rem; }
.legal__body h2 { font-size: 1.6rem; margin-top: var(--s-6); }
.legal__body ul { padding-left: var(--s-5); }
.legal__updated { color: var(--c-muted); }
.notfound { padding: var(--s-8) 0 var(--s-9); text-align: center; }
.notfound .shelf { max-width: 320px; margin-bottom: var(--s-6); }
.notfound .shelf__books { height: 160px; }
.notfound p { color: var(--c-muted); }

/* Footer */
.site-footer { background: var(--c-ink); color: #E4DCCD; padding: var(--s-7) 0 var(--s-5); }
.site-footer a { color: var(--c-parchment); }
.site-footer a:hover { color: var(--c-ochre); }
.footer__grid { display: grid; gap: var(--s-6); }
.footer__brand .brand { color: var(--c-parchment); }
.footer__brand .brand__name small { color: #CFC6B6; }
.footer__brand p { color: #CFC6B6; max-width: 24rem; margin-top: var(--s-4); }
.footer__nav h2 { font-family: var(--f-body); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--c-ochre); margin-bottom: var(--s-3); }
.footer__nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-2); }
.footer__nav a { text-decoration: none; }
.footer__legal {
  margin-top: var(--s-6); padding-top: var(--s-5);
  border-top: 1px solid rgba(246, 240, 228, 0.18);
  font-size: 0.875rem; line-height: 1.7; color: #DAD2C4;
}
.footer__legal p { margin: 0 0 var(--s-2); }
.footer__legal-links { display: flex; flex-wrap: wrap; gap: var(--s-4); margin-top: var(--s-3); }

/* Reveal */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.is-in, .no-js .reveal { opacity: 1; transform: none; }

/* Breakpoints */
@media (min-width: 480px) {
  :root { --gutter: 1.5rem; }
  .form__row { grid-template-columns: 1fr 1fr; }
  .shelf__books { height: 300px; }
}
@media (min-width: 768px) {
  :root { --header-h: 76px; }
  .imprints { grid-template-columns: 1fr 1fr; }
  .path { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr 1fr; gap: var(--s-7); }
  .split--reverse .split__art { order: 2; }
  .split__art { min-height: 380px; }
  .audiences { grid-template-columns: repeat(3, 1fr); }
  .contact { grid-template-columns: 0.8fr 1.2fr; }
  .form { padding: var(--s-6); }
  .footer__grid { grid-template-columns: 1.4fr 1fr 1fr; }
}
@media (min-width: 1024px) {
  .nav-toggle { display: none; }
  .site-nav { position: static; opacity: 1; transform: none; visibility: visible; pointer-events: auto; background: transparent; border: 0; box-shadow: none; padding: 0; }
  .site-nav ul { display: flex; align-items: center; gap: var(--s-5); }
  .site-nav a { border: 0; padding: var(--s-2) 0; font-size: 0.98rem; }
  .site-nav .nav-cta { margin: 0; }
  .site-nav .nav-cta a { padding: var(--s-2) var(--s-5); }
  .site-nav .nav-cta a:hover { color: var(--c-parchment); background: var(--c-green-dark); }
  .hero { padding: var(--s-9) 0 var(--s-8); }
  .hero__grid { grid-template-columns: 1.1fr 0.9fr; }
  .shelf__books { height: 340px; }
  .path { grid-template-columns: repeat(4, 1fr); }
  .section { padding: var(--s-9) 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .lizard-run { animation: none; transform: translateX(60%); }
  .lizard { animation: none; }
  .reveal { opacity: 1; transform: none; }
}
