/* ============================================================
   DEMIURGE — SHARED STYLES for content & legal pages
   Readability-first, consistent with the landing design system.
   ============================================================ */

.page-wrap { position: relative; z-index: 2; }

/* Generic content page shell */
.page-hero { padding: 132px 0 40px; }
.page-hero .lp-eyebrow { margin-bottom: 16px; }
.page-h1 {
  font-family: var(--font-display, 'Instrument Serif', Georgia, serif);
  font-style: italic; font-weight: 400;
  font-size: clamp(34px, 5.5vw, 60px); line-height: 1.02; letter-spacing: -0.03em;
  color: #f5f1e6; margin: 0 0 18px;
}
.page-lede { color: #8388a8; font-size: 17px; line-height: 1.6; max-width: 680px; }

.page-body { padding: 8px 0 96px; }
.prose { max-width: 760px; color: #b8bccf; font-size: 15.5px; line-height: 1.72; }
.prose h2 {
  font-family: var(--font-display, 'Instrument Serif', Georgia, serif);
  font-style: italic; font-weight: 400; font-size: 28px; color: #f5f1e6;
  margin: 44px 0 14px; letter-spacing: -0.01em; scroll-margin-top: 108px;
}
.prose h3 { font-size: 17px; color: #f5f1e6; margin: 28px 0 8px; font-weight: 600; scroll-margin-top: 108px; }
.prose p { margin: 0 0 16px; }
.prose ul, .prose ol { margin: 0 0 18px; padding-left: 22px; }
.prose li { margin: 0 0 8px; }
.prose a { color: #4be8ff; text-decoration: none; border-bottom: 1px solid rgba(75,232,255,0.25); }
.prose a:hover { border-bottom-color: #4be8ff; }
.prose strong { color: #f5f1e6; font-weight: 600; }
.prose code {
  font-family: var(--font-mono, 'Geist Mono', monospace); font-size: 13px;
  background: rgba(255,255,255,0.05); padding: 2px 6px; border-radius: 3px; color: #c8a8ff;
}
.prose hr { border: none; border-top: 1px solid rgba(255,255,255,0.08); margin: 40px 0; }

/* Callouts */
.note {
  border: 1px solid rgba(201,166,116,0.28); background: rgba(201,166,116,0.05);
  border-radius: 4px; padding: 16px 18px; margin: 22px 0; color: #c9a674; font-size: 14px; line-height: 1.6;
}
.note.info { border-color: rgba(75,232,255,0.28); background: rgba(75,232,255,0.05); color: #9fe6f2; }
.note.warn { border-color: rgba(232,201,138,0.3); background: rgba(232,201,138,0.06); color: #e8c98a; }

/* Legal document layout: sticky ToC + body */
.legal-grid { display: grid; grid-template-columns: 240px minmax(0,1fr); gap: 48px; align-items: start; }
.legal-toc { position: sticky; top: 104px; align-self: start; }
.legal-toc .toc-h {
  font-family: var(--font-mono,'Geist Mono',monospace); font-size: 10px; letter-spacing: 0.16em;
  text-transform: uppercase; color: #c9a674; margin-bottom: 12px;
}
.legal-toc a {
  display: block; color: #8388a8; text-decoration: none; font-size: 13px;
  padding: 5px 0; line-height: 1.4; border-left: 2px solid transparent; padding-left: 12px; transition: color .15s, border-color .15s;
}
.legal-toc a:hover, .legal-toc a.active { color: #f5f1e6; border-left-color: #8b6bff; }

.legal-meta {
  display: flex; flex-wrap: wrap; gap: 18px; margin: 18px 0 8px;
  font-family: var(--font-mono,'Geist Mono',monospace); font-size: 11px; letter-spacing: 0.06em; color: #8388a8;
}
.legal-meta b { color: #c9a674; font-weight: 500; }

/* Cards (research/press/operators) */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.card {
  border: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.02);
  border-radius: 6px; padding: 24px; display: flex; flex-direction: column; gap: 10px;
}
.card .k { font-family: var(--font-mono,'Geist Mono',monospace); font-size: 10.5px; letter-spacing: 0.18em; text-transform: uppercase; color: #c9a674; }
.card h3 { font-family: var(--font-display,'Instrument Serif',serif); font-style: italic; font-weight: 400; font-size: 22px; color: #f5f1e6; margin: 0; }
.card p { color: #8388a8; font-size: 14px; line-height: 1.55; margin: 0; }

.empty-state {
  border: 1px dashed rgba(255,255,255,0.14); border-radius: 8px; padding: 56px 32px; text-align: center;
  color: #8388a8; background: rgba(255,255,255,0.015);
}
.empty-state .es-icon {
  width: 52px; height: 52px; margin: 0 auto 18px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff, #c9a674 55%, #3d2e12 100%); opacity: 0.85;
}

/* Shared footer (multi-column) */
.site-foot { border-top: 1px solid rgba(255,255,255,0.06); padding: 64px 0 40px; margin-top: 40px; }
.site-foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 48px; }
.site-foot-brand { max-width: 320px; display: flex; flex-direction: column; gap: 14px; }
.site-foot-tag { color: #8388a8; font-size: 13.5px; line-height: 1.6; }
.site-foot-col { display: flex; flex-direction: column; gap: 10px; }
.site-foot-h { font-family: var(--font-mono,'Geist Mono',monospace); font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: #c9a674; margin-bottom: 4px; }
.site-foot-col a { color: #8388a8; text-decoration: none; font-size: 13.5px; transition: color .15s; }
.site-foot-col a:hover { color: #f5f1e6; }
.site-foot-base {
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
  padding-top: 24px; border-top: 1px solid rgba(255,255,255,0.08);
  font-family: var(--font-mono,'Geist Mono',monospace); font-size: 11px; letter-spacing: 0.04em; color: #8388a8;
}
.site-foot-base .sep { margin: 0 8px; opacity: 0.3; }
.site-foot-base a { color: inherit; text-decoration: none; }
.site-foot-base a:hover { color: #f5f1e6; }
.site-foot-base .r { display: flex; gap: 18px; }

/* Back link */
.page-back {
  display: inline-flex; align-items: center; gap: 8px; color: #8388a8; text-decoration: none;
  font-family: var(--font-mono,'Geist Mono',monospace); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  margin-bottom: 28px;
}
.page-back:hover { color: #f5f1e6; }

@media (max-width: 880px) {
  .legal-grid { grid-template-columns: 1fr; gap: 20px; }
  .legal-toc { position: static; top: auto; border: 1px solid rgba(255,255,255,0.08); border-radius: 6px; padding: 16px; margin-bottom: 8px; }
  .site-foot-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
}
@media (max-width: 640px) {
  .page-hero { padding: 104px 0 28px; }
  .site-foot-grid { grid-template-columns: 1fr; }
  .site-foot-base { flex-direction: column; align-items: flex-start; }
}

/* Print-friendly legal docs */
@media print {
  .lp-nav, .site-foot, .legal-toc, .page-back, .lp-starfield, .lp-vignette, .lp-scan { display: none !important; }
  body, body.landing { background: #fff !important; color: #111 !important; }
  .prose, .prose p, .prose li { color: #111 !important; }
  .prose h2, .prose h3, .page-h1 { color: #000 !important; }
  .legal-grid { grid-template-columns: 1fr !important; }
  a { color: #000 !important; text-decoration: underline; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
