/* David Lingard — author site */
:root {
  --bg: #0e0c0b;
  --bg-2: #171412;
  --card: #1d1916;
  --line: #352c25;
  --text: #ece4d8;
  --muted: #b3a593;
  --gold: #e0a83a;
  --gold-2: #f3c96b;
  --crimson: #9e2a2b;
  --crimson-2: #c23b3c;
  --radius: 10px;
  --wrap: 1140px;
  --display: "Cinzel", "Trajan Pro", Georgia, serif;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.65;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold-2); text-underline-offset: 3px; }
a:hover { color: #fff; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.2; letter-spacing: .02em; margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.1rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); margin-inline: auto; }
.muted { color: var(--muted); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; z-index: 99; background: var(--gold); color: #000; padding: 8px 12px; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(14, 12, 11, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { font-family: var(--display); font-weight: 700; font-size: 1.35rem; letter-spacing: .12em; color: var(--text); text-decoration: none; text-transform: uppercase; }
.brand span { color: var(--gold); }
.nav { display: flex; gap: 4px; align-items: center; }
.nav a {
  font-family: var(--display); font-size: .82rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted); text-decoration: none; padding: 8px 10px; border-radius: 6px;
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--gold-2); }
.menu-btn { display: none; background: none; border: 1px solid var(--line); color: var(--text); border-radius: 6px; padding: 8px 12px; font: inherit; font-size: .9rem; }
@media (max-width: 860px) {
  .menu-btn { display: block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 68px; flex-direction: column; align-items: stretch; background: var(--bg-2); border-bottom: 1px solid var(--line); padding: 8px 16px 16px; }
  .nav.open { display: flex; }
  .nav a { padding: 12px 4px; border-bottom: 1px solid var(--line); }
}

/* ---------- buttons & chips ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--display); font-weight: 600; font-size: .9rem; letter-spacing: .08em; text-transform: uppercase;
  padding: 12px 20px; border-radius: 6px; text-decoration: none; border: 1px solid transparent; cursor: pointer;
}
.btn-gold { background: var(--gold); color: #1a1208; }
.btn-gold:hover { background: var(--gold-2); color: #000; }
.btn-ghost { border-color: var(--line); color: var(--text); background: transparent; }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-2); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0 0 12px; list-style: none; }
.chips li { font-size: .78rem; letter-spacing: .04em; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 2px 10px; }
.eyebrow { font-family: var(--display); font-size: .8rem; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); margin-bottom: .6em; display: block; }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(800px 420px at 70% 30%, rgba(80, 140, 200, .16), transparent 60%),
    radial-gradient(700px 500px at 10% 100%, rgba(158, 42, 43, .25), transparent 60%),
    var(--bg);
  border-bottom: 1px solid var(--line);
}
.hero .wrap { display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; padding: 64px 0 72px; }
.hero h1 { font-size: clamp(2.4rem, 6vw, 4rem); margin-bottom: .25em; }
.hero .tagline { font-family: var(--display); font-size: clamp(1.05rem, 2.2vw, 1.35rem); color: var(--gold-2); letter-spacing: .06em; margin-bottom: 1em; }
.hero .cover { justify-self: center; width: min(360px, 100%); transform: rotate(1.5deg); }
.hero .cover img { border-radius: 4px; box-shadow: 0 30px 60px rgba(0,0,0,.6), 0 0 0 1px rgba(255,255,255,.06); }
@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 32px; padding: 40px 0 48px; }
  .hero .cover { order: -1; width: min(260px, 70%); }
}

/* ---------- sections ---------- */
.section { padding: 72px 0; }
.section + .section { border-top: 1px solid var(--line); }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 28px; flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.page-head { padding: 56px 0 24px; }
.page-head p { color: var(--muted); max-width: 680px; }
@media (max-width: 600px) { .section { padding: 48px 0; } }

/* ---------- book shelf ---------- */
.shelf { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 28px 20px; }
.shelf a { text-decoration: none; color: var(--text); }
.shelf img { aspect-ratio: 2 / 3; object-fit: cover; width: 100%; border-radius: 4px; box-shadow: 0 10px 24px rgba(0,0,0,.5); transition: transform .2s ease; }
.shelf a:hover img { transform: translateY(-4px); }
.shelf .t { display: block; margin-top: 10px; font-size: .95rem; line-height: 1.3; }
.shelf .s { display: block; font-size: .8rem; color: var(--muted); }
@media (max-width: 480px) { .shelf { grid-template-columns: repeat(2, 1fr); gap: 20px 14px; } }

/* ---------- series groups (books page) ---------- */
.series { margin-bottom: 56px; }
.series > h2 { font-size: 1.5rem; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.book-row { display: grid; grid-template-columns: 180px 1fr; gap: 28px; padding: 24px 0; border-bottom: 1px dashed var(--line); }
.book-row:last-child { border-bottom: 0; }
.book-row img { border-radius: 4px; box-shadow: 0 10px 24px rgba(0,0,0,.5); }
.book-row h3 { font-size: 1.4rem; margin-bottom: .3em; }
.book-row h3 a { color: var(--text); text-decoration: none; }
.book-row h3 a:hover { color: var(--gold-2); }
.book-row .no { font-family: var(--display); font-size: .8rem; letter-spacing: .15em; color: var(--gold); text-transform: uppercase; }
@media (max-width: 600px) { .book-row { grid-template-columns: 110px 1fr; gap: 16px; } .book-row .blurb { display: none; } }

/* ---------- book detail ---------- */
.book-detail { display: grid; grid-template-columns: 340px 1fr; gap: 48px; padding: 56px 0; align-items: start; }
.book-detail .cover img { border-radius: 4px; box-shadow: 0 24px 50px rgba(0,0,0,.6); }
@media (max-width: 760px) { .book-detail { grid-template-columns: 1fr; gap: 28px; padding: 32px 0; } .book-detail .cover { width: min(260px, 70%); margin-inline: auto; } }

/* ---------- prose ---------- */
.prose p, .prose li { color: #e3dacd; }
.prose h2 { font-size: 1.5rem; margin-top: 1.6em; }
.prose h3 { margin-top: 1.4em; }
.prose blockquote { border-left: 3px solid var(--gold); margin: 1.5em 0; padding: .2em 0 .2em 1.2em; color: var(--muted); font-style: italic; }
.prose img { border-radius: 6px; margin: 1.5em auto; }
.prose .sep { text-align: center; color: var(--gold); letter-spacing: 1em; }
.story-body p { text-indent: 1.5em; margin: 0 0 .4em; }
.story-body p:first-child, .story-body h2 + p, .story-body h3 + p { text-indent: 0; }

/* ---------- cards (blog, stories) ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; text-decoration: none; color: var(--text); transition: border-color .2s; }
.card:hover { border-color: var(--gold); color: var(--text); }
.card .img { aspect-ratio: 16 / 9; background: var(--bg-2); overflow: hidden; }
.card .img img { width: 100%; height: 100%; object-fit: cover; }
.card .img.ph { display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, #2a201a, #120f0d); }
.card .img.ph img { width: auto; height: 80%; object-fit: contain; opacity: .55; }
.card .body { padding: 18px 20px 22px; }
.card h3 { font-size: 1.1rem; margin-bottom: .4em; }
.card p { font-size: .98rem; color: var(--muted); margin: 0; }
.card .date { font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); display: block; margin-bottom: 6px; }

/* ---------- reviews ---------- */
.review-tools { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 28px; }
.review-tools input, .review-tools select {
  background: var(--bg-2); color: var(--text); border: 1px solid var(--line); border-radius: 6px; padding: 10px 12px; font: inherit; font-size: 1rem;
}
.review-tools input { flex: 1 1 260px; }
.review-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.rv { display: grid; grid-template-columns: 72px 1fr; gap: 14px; align-items: center; padding: 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--text); }
.rv:hover { border-color: var(--gold); color: var(--text); }
.rv img { width: 72px; height: 72px; object-fit: cover; border-radius: 4px; }
.rv .t { display: block; font-size: 1rem; line-height: 1.25; }
.rv .a { display: block; font-size: .85rem; color: var(--muted); }
.score { display: inline-flex; align-items: baseline; gap: 2px; font-family: var(--display); font-weight: 700; color: var(--gold-2); }
.score small { font-size: .7em; color: var(--muted); font-weight: 400; }
.score-lg { font-size: 2.4rem; }
.meter { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; margin: 4px 0 0; width: 100%; max-width: 120px; }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--crimson-2), var(--gold)); }
.review-head { display: grid; grid-template-columns: 220px 1fr; gap: 36px; align-items: start; padding: 48px 0 8px; }
.review-head img { border-radius: 6px; box-shadow: 0 16px 40px rgba(0,0,0,.6); }
@media (max-width: 640px) { .review-head { grid-template-columns: 120px 1fr; gap: 18px; padding-top: 28px; } }
.pager { display: flex; justify-content: space-between; gap: 16px; padding: 32px 0 64px; border-top: 1px solid var(--line); margin-top: 32px; }
.pager a { text-decoration: none; max-width: 48%; }
.pager small { display: block; color: var(--muted); font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: 320px 1fr; gap: 48px; align-items: center; }
.about img { border-radius: var(--radius); aspect-ratio: 4 / 5; object-fit: cover; }
@media (max-width: 760px) { .about { grid-template-columns: 1fr; gap: 28px; } .about img { width: min(280px, 80%); margin-inline: auto; } }

/* ---------- feature strip ---------- */
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 760px) { .split { grid-template-columns: 1fr; } .panel { padding: 24px; } }
.rec { display: grid; grid-template-columns: 110px 1fr; gap: 20px; align-items: start; }
.rec img { border-radius: 4px; }

/* ---------- newsletter ---------- */
.newsletter { text-align: center; background: linear-gradient(180deg, rgba(158,42,43,.18), transparent), var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 48px 24px; }
.newsletter img { width: 64px; margin: 0 auto 16px; }
.newsletter form { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 20px; }
.newsletter input[type=email] { flex: 0 1 340px; min-width: 0; width: 100%; background: var(--bg); color: var(--text); border: 1px solid var(--line); border-radius: 6px; padding: 12px 14px; font: inherit; font-size: 1rem; }
.newsletter .ok { color: var(--gold-2); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--bg-2); padding: 48px 0 32px; margin-top: 0; font-size: .95rem; color: var(--muted); }
.site-footer .cols { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; }
.site-footer h3 { font-size: .85rem; letter-spacing: .15em; text-transform: uppercase; color: var(--text); }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 6px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--gold-2); }
.site-footer .legal { border-top: 1px solid var(--line); margin-top: 32px; padding-top: 20px; font-size: .82rem; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (max-width: 760px) { .site-footer .cols { grid-template-columns: 1fr 1fr; } .site-footer .cols > :first-child { grid-column: 1 / -1; } }
.socials { display: flex; gap: 10px; margin-top: 12px; }
.socials a { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 50%; color: var(--text); }
.socials a:hover { border-color: var(--gold); color: var(--gold-2); }
.socials svg { width: 18px; height: 18px; fill: currentColor; }

.empty { color: var(--muted); padding: 24px 0; }

[hidden] { display: none !important; }
