/* Daniel Sebastian Friedmann – Autorenseite
   Weiches, episches Design: Goldlicht, sanfte Verläufe, keine harten Kanten. */

@font-face {
  font-family: "Cinzel";
  src: url("../fonts/cinzel.woff2") format("woff2");
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("../fonts/cormorant.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("../fonts/cormorant-italic.woff2") format("woff2");
  font-weight: 300 700;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("../fonts/source-sans.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("../fonts/source-sans-italic.woff2") format("woff2");
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --bg: #08070c;
  --bg-soft: #100e16;
  --ink: #f3ead8;
  --ink-dim: #c9bba3;
  --muted: #9a8c76;
  --gold: #e0c48a;
  --gold-bright: #f6e2b3;
  --gold-deep: #a8844c;
  --glow: rgba(224, 196, 138, 0.28);
  --glow-soft: rgba(224, 196, 138, 0.12);
  --line: rgba(224, 196, 138, 0.22);
  --serif: "Cormorant Garamond", "Palatino Linotype", Palatino, "Times New Roman", serif;
  --display: "Cinzel", "Cormorant Garamond", serif;
  --sans: "Source Sans 3", "Segoe UI", Calibri, sans-serif;
  --radius: 1.6rem;
  --max: 1180px;
  --header-h: 4.6rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 1.125rem;
  line-height: 1.75;
  color: var(--ink);
  background:
    radial-gradient(1200px 700px at 50% -10%, rgba(168, 122, 50, 0.22), transparent 60%),
    radial-gradient(900px 600px at 100% 20%, rgba(70, 40, 80, 0.22), transparent 55%),
    radial-gradient(800px 500px at 0% 80%, rgba(80, 30, 20, 0.18), transparent 50%),
    var(--bg);
  background-attachment: fixed;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Soft cinematic grain, no hard edges */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 400;
  opacity: 0.18;
  background-image: url("../img/grain.png");
  background-size: 256px 256px;
  mix-blend-mode: overlay;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold); text-decoration: none; transition: color 0.4s ease, opacity 0.4s ease, text-shadow 0.4s ease; }
a:hover { color: var(--gold-bright); text-shadow: 0 0 18px var(--glow); }
a:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--gold); border-radius: 0.5rem; }

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.01em;
  color: var(--ink);
  margin: 0 0 0.7em;
}
h1 { font-size: clamp(2.4rem, 6vw, 4.6rem); font-weight: 400; }
h2 { font-size: clamp(2rem, 4vw, 3.1rem); font-weight: 400; }
h3 { font-size: clamp(1.4rem, 2.4vw, 1.85rem); }

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

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

.eyebrow {
  font-family: var(--display);
  font-size: 0.78rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.8rem;
}

.gold-rule {
  width: min(12rem, 50%);
  height: 1px;
  border: 0;
  margin: 1.4rem auto;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0.7;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: linear-gradient(180deg, rgba(8, 7, 12, 0.82), rgba(8, 7, 12, 0.42) 70%, transparent);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  transition: background 0.5s ease, box-shadow 0.5s ease;
}
.site-header.is-scrolled {
  background: rgba(8, 7, 12, 0.86);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.28);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: min(var(--max), calc(100% - 2rem));
}
.logo {
  font-family: var(--display);
  font-size: 0.92rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-bright);
  white-space: nowrap;
}
.logo span { opacity: 0.7; letter-spacing: 0.22em; font-size: 0.72em; display: block; font-family: var(--sans); font-weight: 300; }

.nav {
  display: flex;
  gap: 1.6rem;
  align-items: center;
}
.nav a {
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-dim);
  line-height: 1.5;
  padding: 0.35rem 0;
}
.nav a[aria-current="page"], .nav a:hover { color: var(--gold-bright); }

.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  color: var(--gold);
  width: 2.6rem;
  height: 2.6rem;
  cursor: pointer;
  border-radius: 999px;
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  display: block;
  width: 1.15rem;
  height: 1px;
  background: currentColor;
  position: relative;
  margin: 0 auto;
  box-shadow: 0 0 8px var(--glow);
}
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }

/* Hero */
.hero {
  position: relative;
  min-height: 36rem;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 4rem 0 4.2rem;
  overflow: hidden;
}
@media (min-width: 800px) {
  .hero { min-height: 44rem; }
}
.hero::before {
  content: "";
  position: absolute;
  inset: -10% 0 0;
  background:
    radial-gradient(ellipse at 50% 30%, rgba(224, 196, 138, 0.16), transparent 55%),
    url("../img/hero-glow.webp") center 20% / cover no-repeat;
  pointer-events: none;
  animation: breathe 14s ease-in-out infinite alternate;
}
@keyframes breathe {
  from { transform: scale(1); opacity: 0.85; }
  to { transform: scale(1.06); opacity: 1; }
}
.hero-inner { position: relative; z-index: 1; }

.monogram {
  width: 8.2rem;
  height: 8.2rem;
  margin: 0 auto 2rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-size: 1.35rem;
  letter-spacing: 0.22em;
  color: var(--gold-bright);
  background:
    radial-gradient(circle at 50% 40%, rgba(246, 226, 179, 0.16), transparent 62%),
    radial-gradient(circle at 50% 50%, rgba(20, 16, 22, 0.2), rgba(8, 7, 12, 0.85));
  box-shadow:
    0 0 0 1px rgba(224, 196, 138, 0.28),
    0 0 40px rgba(224, 196, 138, 0.22),
    inset 0 0 30px rgba(224, 196, 138, 0.08);
  animation: pulse-glow 7s ease-in-out infinite;
}
@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 0 1px rgba(224, 196, 138, 0.24), 0 0 36px rgba(224, 196, 138, 0.18), inset 0 0 30px rgba(224, 196, 138, 0.06); }
  50% { box-shadow: 0 0 0 1px rgba(246, 226, 179, 0.4), 0 0 58px rgba(224, 196, 138, 0.32), inset 0 0 36px rgba(224, 196, 138, 0.12); }
}

.hero h1 {
  font-family: var(--display);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: none;
  margin-bottom: 0.4rem;
  background: linear-gradient(180deg, #fff6e0 0%, var(--gold) 55%, var(--gold-deep) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: none;
  filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.35));
}
.hero h1 .last { display: block; }
.tagline {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.2rem, 2.4vw, 1.7rem);
  color: var(--ink-dim);
  max-width: 38rem;
  margin: 1rem auto 2rem;
  line-height: 1.5;
}
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* Buttons – soft pills, no sharp corners */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.7rem;
  border-radius: 999px;
  font-family: var(--sans);
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 0;
  cursor: pointer;
  transition: transform 0.45s ease, box-shadow 0.45s ease, background 0.45s ease, color 0.45s ease;
}
.btn-gold {
  color: #1a140c;
  background: linear-gradient(180deg, #f6e2b3, #d4b06a 60%, #b88942);
  box-shadow: 0 8px 28px rgba(184, 137, 66, 0.35), 0 0 0 1px rgba(255, 240, 200, 0.2) inset;
}
.btn-gold:hover {
  color: #1a140c;
  text-shadow: none;
  transform: translateY(-2px);
  box-shadow: 0 14px 36px rgba(184, 137, 66, 0.48), 0 0 24px var(--glow);
}
.btn-ghost {
  color: var(--gold);
  background: rgba(224, 196, 138, 0.06);
  box-shadow: inset 0 0 0 1px rgba(224, 196, 138, 0.35);
}
.btn-ghost:hover {
  background: rgba(224, 196, 138, 0.14);
  transform: translateY(-2px);
}

/* Sections */
.section { padding: 5.5rem 0; position: relative; }
.section-head { text-align: center; max-width: 40rem; margin: 0 auto 3.2rem; }
.section-head p { color: var(--ink-dim); }

.lead { font-size: 1.2rem; color: var(--ink-dim); }

/* Author */
.author-grid {
  display: grid;
  grid-template-columns: 16.5rem 1fr;
  gap: 3.2rem;
  align-items: center;
}
.portrait {
  position: relative;
  width: 16.5rem;
  height: 16.5rem;
  margin: 0 auto;
}
.portrait-frame {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 50% 40%, rgba(246, 226, 179, 0.14), transparent 60%),
    radial-gradient(circle at 50% 80%, #161018, #0a090e);
  box-shadow:
    0 0 0 1px rgba(224, 196, 138, 0.3),
    0 0 60px rgba(224, 196, 138, 0.16),
    0 20px 50px rgba(0, 0, 0, 0.4);
  overflow: hidden;
}
.portrait-frame .letters {
  font-family: var(--display);
  font-size: 2.2rem;
  letter-spacing: 0.18em;
  color: var(--gold-bright);
}
.portrait-caption {
  text-align: center;
  margin-top: 0.9rem;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.bio p { color: var(--ink-dim); }
.bio p:first-of-type { color: var(--ink); font-size: 1.2rem; font-family: var(--serif); font-style: italic; line-height: 1.6; }

/* Book grid */
.book-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.2rem 1.6rem;
}
.book-card {
  display: flex;
  flex-direction: column;
  color: inherit;
  border-radius: 1.2rem;
  padding: 0.4rem;
  transition: transform 0.55s ease;
}
.book-card:hover { transform: translateY(-8px); color: inherit; text-shadow: none; }
.cover-wrap {
  position: relative;
  border-radius: 0.7rem;
  overflow: hidden;
  background: #0b0a10;
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.45),
    0 0 40px rgba(224, 196, 138, 0.08);
  transition: box-shadow 0.55s ease;
  aspect-ratio: 2 / 2.85;
}
.book-card:hover .cover-wrap {
  box-shadow:
    0 28px 50px rgba(0, 0, 0, 0.5),
    0 0 50px rgba(224, 196, 138, 0.22);
}
.cover-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
}
.book-card:hover .cover-wrap img { transform: scale(1.03); }
.cover-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(8, 7, 12, 0.35));
  pointer-events: none;
}
.badge {
  position: absolute;
  top: 0.8rem;
  left: 0.8rem;
  z-index: 2;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: rgba(8, 7, 12, 0.72);
  color: var(--gold-bright);
  backdrop-filter: blur(8px);
  box-shadow: 0 0 20px rgba(224, 196, 138, 0.2);
}
.book-card h3 {
  font-size: 1.28rem;
  margin: 1rem 0 0.25rem;
  color: var(--ink);
}
.book-card .sub {
  font-size: 0.92rem;
  color: var(--muted);
  font-style: italic;
  font-family: var(--serif);
  margin-bottom: 0.5rem;
  line-height: 1.4;
}
.book-card .excerpt {
  font-size: 0.95rem;
  color: var(--ink-dim);
  flex-grow: 1;
}
.more {
  margin-top: 0.7rem;
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}

/* Donate line */
.donate {
  margin-top: 3.2rem;
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--gold);
  max-width: 40rem;
  margin-inline: auto;
  padding: 1.4rem 1.6rem;
  background: radial-gradient(ellipse at center, rgba(224, 196, 138, 0.08), transparent 70%);
}

/* Workshops teaser / page */
.workshop-panel {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3rem;
  align-items: center;
  padding: 2.4rem;
  border-radius: 2rem;
  background:
    radial-gradient(600px 300px at 10% 0%, rgba(224, 196, 138, 0.12), transparent 55%),
    linear-gradient(180deg, rgba(20, 16, 24, 0.7), rgba(10, 8, 14, 0.5));
  box-shadow: 0 0 0 1px rgba(224, 196, 138, 0.12), 0 30px 80px rgba(0, 0, 0, 0.25);
}
.workshop-panel h2 { text-align: left; }
.soft-list { list-style: none; padding: 0; margin: 1.2rem 0 0; }
.soft-list li {
  position: relative;
  padding: 0.45rem 0 0.45rem 1.4rem;
  color: var(--ink-dim);
}
.soft-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1rem;
  width: 0.55rem;
  height: 1px;
  background: var(--gold);
  box-shadow: 0 0 8px var(--glow);
}

/* Contact */
.contact-box { text-align: center; }
.contact-box a.mail {
  display: inline-block;
  font-family: var(--serif);
  font-size: 1.5rem;
  margin-top: 0.4rem;
}

/* Footer */
.site-footer {
  padding: 3.2rem 0 2.2rem;
  color: var(--muted);
  font-size: 0.92rem;
  text-align: center;
}
.site-footer nav { display: flex; gap: 1.4rem; justify-content: center; flex-wrap: wrap; margin-bottom: 1rem; }
.site-footer p { max-width: 38rem; margin: 0.6rem auto; }

/* Book detail */
.book-hero {
  display: grid;
  grid-template-columns: minmax(16rem, 22rem) 1fr;
  gap: 3.2rem;
  align-items: start;
  padding: 3rem 0 2rem;
}
.book-cover-lg {
  border-radius: 0.9rem;
  overflow: hidden;
  box-shadow:
    0 30px 70px rgba(0, 0, 0, 0.5),
    0 0 60px rgba(224, 196, 138, 0.14);
}
.meta { color: var(--ink-dim); font-size: 1rem; }
.meta dt {
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 1rem;
  font-weight: 500;
  font-family: var(--sans);
}
.meta dd { margin: 0.15rem 0 0; }
.blurb {
  font-size: 1.14rem;
  color: var(--ink-dim);
  max-width: 42rem;
}
.blurb p:first-child {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.4rem;
  color: var(--ink);
  line-height: 1.45;
}
.shops { margin-top: 1.6rem; display: flex; flex-wrap: wrap; gap: 0.8rem; align-items: center; }
.shop-note { color: var(--muted); font-size: 0.95rem; width: 100%; }

/* Legal */
.legal { max-width: 42rem; margin: 0 auto; padding: 4rem 0 5rem; }
.legal h1 { font-size: 2.6rem; }
.legal h2 { font-size: 1.5rem; margin-top: 2rem; }
.legal p, .legal li { color: var(--ink-dim); }
.address { font-style: normal; color: var(--ink); line-height: 1.7; }

/* Reveal: visible by default (no-JS, print, slow net). Hidden only when JS is ready. */
.reveal { opacity: 1; transform: none; }
.js .reveal {
  opacity: 0;
  transform: translateY(22px);
  animation: none;
}
.js .reveal.is-in {
  animation: fade-up 1s ease forwards;
}
@keyframes fade-up {
  to { opacity: 1; transform: none; }
}
.delay-1 { animation-delay: 0.12s; }
.delay-2 { animation-delay: 0.24s; }
.delay-3 { animation-delay: 0.36s; }
.delay-4 { animation-delay: 0.48s; }

/* Skip link */
.skip {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--gold);
  color: #1a140c;
  padding: 0.5rem 1rem;
  z-index: 100;
  border-radius: 0 0 0.6rem 0;
}
.skip:focus { left: 0; }

/* Responsive */
@media (max-width: 1024px) {
  .book-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 860px) {
  .author-grid, .book-hero, .workshop-panel { grid-template-columns: 1fr; }
  .book-hero .book-cover-lg { max-width: 22rem; margin-inline: auto; }
  .workshop-panel { padding: 1.6rem; }
  .book-grid { grid-template-columns: repeat(2, 1fr); gap: 1.6rem 1rem; }
  .nav-toggle { display: grid; place-items: center; }
  .nav {
    position: absolute;
    top: var(--header-h);
    left: 1rem; right: 1rem;
    display: none;
    flex-direction: column;
    gap: 0;
    padding: 1rem 1.2rem 1.2rem;
    border-radius: 1.2rem;
    background: rgba(12, 10, 16, 0.94);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(224, 196, 138, 0.15);
    backdrop-filter: blur(18px);
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 0.7rem 0.2rem; }
}
@media (max-width: 520px) {
  body { font-size: 1.05rem; }
  .book-grid { grid-template-columns: 1fr 1fr; }
  .logo { letter-spacing: 0.08em; font-size: 0.8rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
  .reveal { opacity: 1; transform: none; }
}

@media print {
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .js .reveal { opacity: 1 !important; transform: none !important; animation: none !important; }
  .hero { min-height: auto; }
  .site-header { position: static; }
  body::before { display: none; }
}
