/* phyllux.com -  dark romance literary shell
  Deep black, smoked glass, blood red, muted gold.
  Mobile first. prefers-reduced-motion respected. */

@import url("https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,500;0,600;0,700;1,500;1,600&family=Outfit:wght@300;400;500;600;700&display=swap");

:root {
  --bg: #07060a;
  --bg-elevated: #100e14;
  --bg-soft: #18151d;
  --fg: #f3ebe3;
  --muted: #a89a8c;
  --line: rgba(243, 235, 227, 0.1);
  --line-strong: rgba(243, 235, 227, 0.18);
  --accent: #b91c3c;
  --accent-hot: #e11d48;
  --accent-soft: rgba(185, 28, 60, 0.16);
  --gold: #c4a46a;
  --gold-soft: rgba(196, 164, 106, 0.14);
  --glass: rgba(16, 14, 20, 0.72);
  --glass-edge: rgba(243, 235, 227, 0.12);
  --max: 40rem;
  --wide: 68rem;
  --space: 1rem;
  --radius: 2px;
  --radius-lg: 4px;
  --touch: 44px;
  --font-display: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --font-body: "Outfit", system-ui, sans-serif;
  --header-h: 4rem;
  --shadow-glow: 0 0 60px rgba(185, 28, 60, 0.18);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@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;
  }

  .rain-canvas {
  display: none !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--fg);
  line-height: 1.7;
  font-size: 1.0625rem;
  font-weight: 400;
  overflow-x: clip;
  position: relative;
  min-height: 100dvh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
  radial-gradient(ellipse 90% 55% at 50% -10%, rgba(185, 28, 60, 0.22), transparent 55%),
  radial-gradient(ellipse 50% 40% at 100% 40%, rgba(196, 164, 106, 0.06), transparent 50%),
  radial-gradient(ellipse 40% 30% at 0% 80%, rgba(185, 28, 60, 0.08), transparent 45%);
}

.page-wrap {
  position: relative;
  z-index: 1;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.rain-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.35;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: #fff;
  padding: 0.75rem 1rem;
  z-index: 100;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--gold);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--fg);
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  line-height: 1.12;
  font-weight: 600;
  letter-spacing: 0.01em;
  margin: 0 0 0.75rem;
  color: var(--fg);
}

h1 {
  font-size: clamp(2.4rem, 8vw, 4.25rem);
  font-weight: 700;
}

h2 {
  font-size: clamp(1.75rem, 4.5vw, 2.6rem);
}

h3 {
  font-size: clamp(1.35rem, 3vw, 1.65rem);
}

p {
  margin: 0 0 1rem;
}

p:last-child {
  margin-bottom: 0;
}

.muted,
.hero-lede,
.section-lede,
.nm-hero-sub {
  color: var(--muted);
}

em {
  font-family: var(--font-display);
  font-style: italic;
}

/* -  - -  Header -  - -  */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(16px) saturate(1.2);
  background: rgba(7, 6, 10, 0.78);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top);
}

.site-header-inner {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0.85rem clamp(1rem, 3vw, 1.75rem);
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: var(--header-h);
}

.brand {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
  color: var(--fg);
  text-decoration: none;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.brand span {
  color: var(--gold);
}

.brand:hover {
  color: var(--fg);
}

.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-toggle,
.theme-toggle {
  min-height: var(--touch);
  min-width: var(--touch);
  padding: 0 0.85rem;
  border: 1px solid var(--line-strong);
  background: var(--bg-soft);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}

.theme-toggle {
  display: none; /* dark by default; keep API for site.js */
}

.site-nav {
  display: none;
}

.site-nav.is-open {
  display: block;
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--line);
  padding: 1rem clamp(1rem, 3vw, 1.75rem) 1.25rem;
  max-height: min(70vh, 28rem);
  overflow-y: auto;
}

.site-nav a {
  display: flex;
  align-items: center;
  min-height: var(--touch);
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--line);
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--fg);
}

.site-nav a[aria-current="page"] {
  color: var(--gold);
}

.nav-group-label {
  display: block;
  margin: 1rem 0 0.35rem;
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-hot);
}

.nav-group-label:first-child {
  margin-top: 0;
}

@media (min-width: 960px) {
  .nav-toggle {
  display: none;
  }

  .site-nav,
  .site-nav.is-open {
  display: flex;
  position: static;
  background: transparent;
  border: 0;
  padding: 0;
  margin-left: auto;
  max-height: none;
  overflow: visible;
  align-items: center;
  gap: 0.15rem 1.1rem;
  }

  .site-nav-panel {
  display: flex;
  align-items: center;
  gap: 0.15rem 1.1rem;
  flex-wrap: wrap;
  justify-content: flex-end;
  }

  .nav-group-label {
  display: none;
  }

  .site-nav a {
  border: 0;
  min-height: auto;
  padding: 0.5rem 0;
  font-size: 0.78rem;
  }

  .header-actions {
  margin-left: 0.75rem;
  }
}

/* -  - -  Buttons -  - -  */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--touch);
  padding: 0.85rem 1.4rem;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.btn-primary,
.btn-primary.btn-on-dark {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn-primary:hover,
.btn-primary.btn-on-dark:hover {
  background: var(--accent-hot);
  border-color: var(--accent-hot);
  color: #fff;
}

.btn-secondary,
.btn-secondary.btn-on-dark {
  background: transparent;
  color: var(--fg);
  border-color: var(--line-strong);
}

.btn-secondary:hover,
.btn-secondary.btn-on-dark:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.btn-row-hero {
  margin-top: 1.75rem;
}

/* -  - -  Hero (full bleed) -  - -  */
.nm-hero {
  position: relative;
  min-height: min(92dvh, 52rem);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  isolation: isolate;
}

.nm-hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  z-index: 0;
  transform: scale(1.06);
  will-change: transform;
}

.nm-hero--parallax .nm-hero-img {
  transition: transform 0.1s linear;
}

.nm-hero-veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
  linear-gradient(180deg, rgba(7, 6, 10, 0.35) 0%, rgba(7, 6, 10, 0.55) 40%, rgba(7, 6, 10, 0.94) 100%),
  linear-gradient(90deg, rgba(7, 6, 10, 0.55) 0%, transparent 55%);
}

.nm-hero-copy {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--wide);
  margin: 0 auto;
  padding: clamp(5rem, 12vh, 7rem) clamp(1rem, 3vw, 1.75rem) clamp(2.5rem, 6vh, 4rem);
}

.nm-hero-brand,
.nm-eyebrow,
.hero-kicker,
.rank {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 1rem;
}

.nm-hero h1 {
  max-width: 14ch;
  margin-bottom: 1rem;
  text-shadow: 0 8px 40px rgba(0, 0, 0, 0.55);
}

.nm-hero-sub {
  max-width: 34rem;
  font-size: clamp(1.05rem, 2.4vw, 1.2rem);
  font-weight: 300;
  line-height: 1.65;
}

/* -  - -  Main sections -  - -  */
main {
  flex: 1;
  width: 100%;
}

.section,
.nm-gallery.section,
.nm-storyband,
.book-spotlight,
.featured-shelf,
.signup-band,
.honest-band {
  max-width: var(--wide);
  margin: 0 auto;
  padding: clamp(3rem, 8vw, 5.5rem) clamp(1rem, 3vw, 1.75rem);
}

.narrow,
main.narrow {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
  padding: clamp(2.5rem, 6vw, 4rem) clamp(1rem, 3vw, 1.75rem);
}

.page-hero-mini {
  margin-bottom: 2rem;
}

.tag {
  display: inline-block;
  padding: 0.28rem 0.65rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border: 1px solid var(--line-strong);
  margin: 0 0.35rem 0.35rem 0;
}

.tag-live {
  border-color: rgba(196, 164, 106, 0.45);
  color: var(--gold);
}

.tag-roadmap {
  border-color: rgba(185, 28, 60, 0.45);
  color: #fda4af;
}

/* Book spotlight */
.book-spotlight {
  display: grid;
  gap: 2rem;
  align-items: center;
}

.book-spotlight-cover {
  max-width: 18rem;
  margin: 0 auto;
  box-shadow: var(--shadow-glow), 0 24px 80px rgba(0, 0, 0, 0.55);
}

.book-spotlight-cover img {
  width: 100%;
  border: 1px solid var(--glass-edge);
}

.book-spotlight-body h2 a {
  color: inherit;
  text-decoration: none;
}

.book-spotlight-body h2 a:hover {
  color: var(--gold);
}

.book-spotlight-by {
  color: var(--muted);
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

@media (min-width: 800px) {
  .book-spotlight {
  grid-template-columns: minmax(14rem, 20rem) 1fr;
  gap: 3.5rem;
  }

  .book-spotlight-cover {
  margin: 0;
  max-width: none;
  }
}

/* Atmosphere gallery -  edge to edge images, not card UI */
.nm-gallery h2 {
  max-width: 18ch;
  margin-bottom: 1.5rem;
}

.nm-gallery-grid,
.velvet-scene-grid {
  display: grid;
  gap: 0.65rem;
  grid-template-columns: 1fr 1fr;
}

.nm-gallery-grid img,
.velvet-scene-grid img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  filter: saturate(0.85) contrast(1.05);
  border: 1px solid var(--line);
}

@media (min-width: 700px) {
  .nm-gallery-grid,
  .velvet-scene-grid {
  grid-template-columns: repeat(4, 1fr);
  }
}

/* Story band */
.nm-storyband {
  display: grid;
  gap: 2rem;
  align-items: center;
  background: linear-gradient(180deg, transparent, var(--bg-elevated), transparent);
}

.nm-storyband-media img {
  width: 100%;
  border: 1px solid var(--line);
}

@media (min-width: 800px) {
  .nm-storyband {
  grid-template-columns: 1.1fr 1fr;
  gap: 3rem;
  }
}

/* Featured shelf */
.featured-shelf h2 {
  margin-bottom: 0.5rem;
}

.shelf-grid {
  display: grid;
  gap: 1.25rem;
  margin-top: 2rem;
}

.shelf-item {
  border-top: 1px solid var(--line);
  padding-top: 1.25rem;
}

.shelf-item h3 {
  margin-bottom: 0.35rem;
}

.shelf-item p {
  color: var(--muted);
  font-size: 0.98rem;
}

@media (min-width: 700px) {
  .shelf-grid {
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  }
}

/* Signup */
.signup-band {
  border-block: 1px solid var(--line);
  background: linear-gradient(135deg, rgba(185, 28, 60, 0.12), transparent 55%);
}

.signup-form {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.5rem;
  max-width: 28rem;
}

.signup-form label {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.signup-form input[type="email"] {
  min-height: var(--touch);
  padding: 0.85rem 1rem;
  border: 1px solid var(--line-strong);
  background: rgba(0, 0, 0, 0.35);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 1rem;
}

.signup-form input[type="email"]:focus {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

.signup-note {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 0.75rem;
}

.signup-form[data-state="ok"] .signup-note {
  color: #86efac;
}

/* Tropes / warnings */
.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1.25rem 0;
  padding: 0;
  list-style: none;
}

.chip-list li {
  padding: 0.45rem 0.8rem;
  border: 1px solid var(--line-strong);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.excerpt-block {
  margin: 2rem 0;
  padding: 1.5rem 0 1.5rem 1.25rem;
  border-left: 2px solid var(--accent);
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 2.5vw, 1.4rem);
  font-style: italic;
  line-height: 1.55;
  color: #e8ddd2;
}

.warning-box {
  margin-top: 2rem;
  padding: 1.25rem 1.35rem;
  background: var(--accent-soft);
  border: 1px solid rgba(185, 28, 60, 0.35);
}

.warning-box h3 {
  font-size: 1rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-family: var(--font-body);
  font-weight: 600;
}

/* Novelmate proof strip */
.nm-proof-strip {
  display: grid;
  gap: 1.5rem;
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 clamp(1rem, 3vw, 1.75rem) clamp(3rem, 8vw, 5rem);
}

.nm-proof img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border: 1px solid var(--line);
  margin-bottom: 1rem;
}

.nm-proof p {
  color: var(--muted);
}

@media (min-width: 800px) {
  .nm-proof-strip {
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
  }
}

.nm-gallery-grid--dense {
  grid-template-columns: 1fr 1fr;
}

@media (min-width: 800px) {
  .nm-gallery-grid--dense {
  grid-template-columns: repeat(3, 1fr);
  }
}

.split-feature {
  display: grid;
  gap: 1.75rem;
  margin: 2.5rem 0;
}

.split-feature img {
  border: 1px solid var(--line);
}

@media (min-width: 800px) {
  .split-feature {
  grid-template-columns: 1.2fr 1fr;
  align-items: center;
  gap: 2.5rem;
  }
}

.manifesto {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 2rem 0;
}

.manifesto blockquote {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-style: italic;
  line-height: 1.4;
  color: #e8ddd2;
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}

.stat-value {
  font-family: var(--font-display);
  font-size: 2.25rem;
  color: var(--gold);
  line-height: 1;
}

.stat-label {
  font-size: 0.78rem;
  color: var(--muted);
  letter-spacing: 0.04em;
  margin-top: 0.35rem;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding: 1.25rem 0 1.25rem 3rem;
  border-top: 1px solid var(--line);
}

.steps li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 1.35rem;
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--accent-hot);
}

/* Footer */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--line);
  background: #050408;
  padding: 2.5rem clamp(1rem, 3vw, 1.75rem) calc(2rem + env(safe-area-inset-bottom));
}

.site-footer-inner {
  max-width: var(--wide);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin-bottom: 0.35rem;
}

.site-footer span,
.site-footer a {
  color: var(--muted);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
}

.footer-links a {
  text-decoration: none;
  min-height: var(--touch);
  display: inline-flex;
  align-items: center;
}

.footer-links a:hover {
  color: var(--gold);
}

@media (min-width: 700px) {
  .site-footer-inner {
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-end;
  }
}

/* Reveal */
.reveal {
  opacity: 0;
  transform: translateY(1.25rem);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Legacy hero-band (secondary pages) */
.hero-band {
  position: relative;
  min-height: 42vw;
  max-height: 22rem;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}

.hero-band img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.45) saturate(0.8);
}

.hero-band-caption {
  position: relative;
  z-index: 1;
  padding: 2rem clamp(1rem, 3vw, 1.75rem);
  max-width: var(--wide);
  margin: 0 auto;
  width: 100%;
}

/* Light theme escape hatch (optional) */
[data-theme="light"] {
  --bg: #f7f3ec;
  --bg-elevated: #fffdf9;
  --bg-soft: #ebe4d8;
  --fg: #1c1916;
  --muted: #6b6358;
  --line: rgba(28, 25, 22, 0.1);
  --line-strong: rgba(28, 25, 22, 0.18);
  --accent: #9f1239;
  --glass: rgba(255, 253, 249, 0.85);
}

[data-theme="light"] body::before {
  background:
  radial-gradient(ellipse 80% 50% at 10% 0%, rgba(159, 18, 57, 0.08), transparent 55%),
  radial-gradient(ellipse 60% 40% at 90% 10%, rgba(196, 164, 106, 0.1), transparent 50%);
}

[data-theme="light"] .site-header {
  background: rgba(247, 243, 236, 0.85);
}

[data-theme="light"] .theme-toggle {
  display: inline-flex;
}

/* Workshop shelf + book cards */
.workshop-band {
  max-width: var(--wide);
  margin: 0 auto;
  padding: clamp(2.5rem, 6vw, 4rem) clamp(1rem, 3vw, 1.75rem);
}

.workshop-intro {
  max-width: 42rem;
  margin-bottom: 2rem;
}

.workshop-grid {
  display: grid;
  gap: 2rem;
  margin-top: 2rem;
}

@media (min-width: 640px) {
  .workshop-grid {
  grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .workshop-grid {
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  }
}

.workshop-card {
  border-top: 1px solid var(--line);
  padding-top: 1.5rem;
}

.workshop-card-link {
  display: grid;
  gap: 1rem;
  color: inherit;
  text-decoration: none;
}

.workshop-card-link:hover h3 {
  color: var(--gold);
}

.workshop-cover {
  position: relative;
  aspect-ratio: 5 / 8;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-soft);
}

.workshop-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cover-spec-label {
  position: absolute;
  left: 0.5rem;
  bottom: 0.5rem;
  padding: 0.25rem 0.5rem;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: rgba(7, 6, 10, 0.82);
  border: 1px solid var(--line-strong);
  color: var(--muted);
}

.workshop-meta h3 {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
  margin: 0 0 0.35rem;
}

.workshop-by {
  color: var(--gold);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0 0 0.35rem;
}

.workshop-genre {
  color: var(--muted);
  font-size: 0.88rem;
  margin: 0 0 0.75rem;
}

.workshop-blurb {
  font-size: 0.95rem;
  line-height: 1.55;
  margin: 0 0 0.75rem;
}

.workshop-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0;
}

.tag-muted {
  border-color: var(--line);
  color: var(--muted);
  background: transparent;
}

.collab-grid {
  display: grid;
  gap: 1.25rem;
  margin-top: 2rem;
}

@media (min-width: 700px) {
  .collab-grid {
  grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .collab-grid {
  grid-template-columns: repeat(4, 1fr);
  }
}

.collab-card {
  border: 1px solid var(--line);
  padding: 1.25rem;
  background: rgba(0, 0, 0, 0.2);
}

.collab-card h3 {
  font-size: 1.05rem;
  margin: 0 0 0.35rem;
}

.collab-role {
  color: var(--gold);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 0 0 0.65rem;
}

.collab-card p:last-child {
  color: var(--muted);
  font-size: 0.92rem;
  margin: 0;
  line-height: 1.5;
}

.book-cover-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  text-align: center;
  background: linear-gradient(145deg, var(--g1), var(--g2));
}

.book-cover-fallback span {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: rgba(255, 252, 247, 0.92);
}

.curation-steps {
  display: grid;
  gap: 1.25rem;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.curation-steps li {
  border-left: 2px solid var(--accent);
  padding: 0 0 0 1rem;
}

.curation-steps h3 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
}

.curation-steps p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.55;
}

/* Ecosystem strip.
   The markup on research.html had no styles at all, so the sibling sites
   rendered as bare stacked links. */
.ecosystem-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  gap: 0.75rem;
  margin: 2rem 0;
}
.eco-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--bg-elevated);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.eco-tile:hover,
.eco-tile:focus-visible {
  border-color: var(--gold);
  background: var(--bg-soft);
}
.eco-tile strong {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--fg);
}
.eco-tile span {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.4;
}
/* Corner chip so a tile with a mark keeps its title aligned with the
   sibling tiles that have none. */
.eco-mark {
  position: absolute;
  top: 0.9rem;
  right: 1rem;
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
}
.eco-tile:has(.eco-mark) strong,
.eco-tile:has(.eco-mark) span {
  padding-right: 2.6rem;
}
