/* Alternative Vibration Network — section pages.
   Palette and type taken from the existing public/index.html so these pages do
   not look like a second site. */

:root {
  --ink: #f1f5f9;
  --muted: #94a3b8;
  --dim: #64748b;
  --bg: #080c14;
  --panel: #0d1420;
  --line: rgba(255, 255, 255, 0.08);
  --accent: #05c46b;
  --accent-dim: rgba(5, 196, 107, 0.14);
  --max: 46rem;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Outfit', system-ui, -apple-system, sans-serif;
  font-weight: 300;
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 1rem;
  top: 1rem;
  background: var(--accent);
  color: #04120a;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  z-index: 10;
}

/* ── header ─────────────────────────────────────────────────────────── */

.site-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding: 1.25rem clamp(1rem, 4vw, 2.5rem);
  border-bottom: 1px solid var(--line);
}

.brand {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  text-decoration: none;
}

.site-header nav {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 1.1rem;
  font-size: 0.92rem;
}

.site-header nav a {
  color: var(--muted);
  text-decoration: none;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
}

.site-header nav a:hover { color: var(--ink); }

.site-header nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--accent);
}

.site-header nav .join {
  color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 0.2rem 0.8rem;
}

/* ── body ───────────────────────────────────────────────────────────── */

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(2rem, 6vw, 4rem) clamp(1rem, 4vw, 1.5rem) 3rem;
}

h1, h2, h3, h4 {
  font-family: 'Orbitron', sans-serif;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.01em;
}

h1 {
  font-size: clamp(1.7rem, 4.6vw, 2.5rem);
  margin: 0 0 1.2rem;
}

h2 {
  font-size: clamp(1.15rem, 2.6vw, 1.4rem);
  margin: 3rem 0 0.8rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line);
}

h3 { font-size: 1.05rem; margin: 2.2rem 0 0.5rem; color: var(--ink); }

h4 {
  font-size: 1rem;
  margin: 2.4rem 0 0.4rem;
  color: var(--accent);
  letter-spacing: 0.02em;
}

p { margin: 0 0 1.1rem; }

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }

strong { font-weight: 600; color: #fff; }

em { font-style: italic; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.86em;
  background: rgba(255, 255, 255, 0.06);
  padding: 0.1em 0.35em;
  border-radius: 4px;
}

.math {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.88em;
  color: #cbd5e1;
}

blockquote {
  margin: 1.6rem 0;
  padding: 0.2rem 0 0.2rem 1.1rem;
  border-left: 2px solid var(--accent);
  color: #e2e8f0;
}

blockquote p:last-child { margin-bottom: 0; }

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 2.5rem 0;
}

ul, ol { margin: 0 0 1.2rem; padding-left: 1.3rem; }
li { margin-bottom: 0.45rem; }

.standfirst {
  font-size: 1.08em;
  color: #e2e8f0;
}

.note {
  font-size: 0.92rem;
  color: var(--muted);
}

/* ── tables ─────────────────────────────────────────────────────────── */

.table-wrap {
  overflow-x: auto;
  margin: 1.4rem 0 1.8rem;
  border: 1px solid var(--line);
  border-radius: 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

th, td {
  text-align: left;
  vertical-align: top;
  padding: 0.6rem 0.85rem;
  border-bottom: 1px solid var(--line);
}

th {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
  background: rgba(255, 255, 255, 0.02);
}

tbody tr:last-child td { border-bottom: 0; }

table.systems td.num {
  font-family: ui-monospace, monospace;
  color: var(--dim);
  white-space: nowrap;
  width: 3.2rem;
}

.badge {
  display: inline-block;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--accent);
  background: var(--accent-dim);
  border: 1px solid rgba(5, 196, 107, 0.35);
  border-radius: 999px;
  padding: 0.1rem 0.55rem;
  white-space: nowrap;
}

/* ── evidence ───────────────────────────────────────────────────────── */

.plots {
  display: grid;
  gap: 1.6rem;
  margin: 2rem 0;
}

.plot {
  margin: 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}

.plot img {
  display: block;
  width: 100%;
  height: auto;
  background: #fff;
}

.plot figcaption {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 0.9rem 1rem;
  font-size: 0.9rem;
}

.plot figcaption span { color: var(--muted); font-size: 0.85rem; }

/* ── footer ─────────────────────────────────────────────────────────── */

.stamp {
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  font-size: 0.82rem;
  color: var(--dim);
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem clamp(1rem, 4vw, 2.5rem) 3rem;
  font-size: 0.85rem;
  color: var(--muted);
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.1rem;
  margin-bottom: 1rem;
}

.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--accent); }
.colophon { margin: 0; color: var(--dim); }

@media (min-width: 720px) {
  .plots { grid-template-columns: 1fr 1fr; }
}

/* ── news ───────────────────────────────────────────────────────────── */

.posts { margin: 2rem 0; }

.post {
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--line);
}

.post:last-child { border-bottom: 0; }

.post-meta {
  margin: 0 0 0.4rem;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dim);
}

.post h2 {
  border-top: 0;
  padding-top: 0;
  margin: 0 0 0.6rem;
}

.post .standfirst { margin-bottom: 1rem; }

/* ── forum ──────────────────────────────────────────────────────────── */

.count {
  font-family: 'Outfit', sans-serif;
  font-size: 0.75rem;
  color: var(--dim);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.05rem 0.5rem;
  vertical-align: middle;
}

.thread {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 1.1rem 1.2rem;
  margin-bottom: 1rem;
}

.thread h3 { margin: 0 0 0.3rem; color: var(--ink); }

.thread-meta {
  margin: 0 0 0.8rem;
  font-size: 0.8rem;
  color: var(--dim);
}

.thread p:last-child { margin-bottom: 0; }

/* ── home page ──────────────────────────────────────────────────────── */

/* The ERP container is authored in content/home.html and only needs room
   under the shared header; everything else about it is its own inline CSS. */
body > main.erp-container { margin: 2rem auto; }

/* ── posts: official and member ──────────────────────────────────────── */

.post-badge {
  display: inline-block;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 999px;
  padding: 0.1rem 0.5rem;
  vertical-align: middle;
}

/* Official: filled. A member post can never look like this — the database
   refuses to write kind='official' from a browser (docs/POSTING.md). */
.post-badge.official {
  background: var(--accent);
  color: #04120a;
  font-weight: 600;
}

.post-badge.member {
  color: var(--muted);
  border: 1px solid var(--line);
  background: transparent;
}

.member-posts {
  margin-top: 1.2rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--line);
}

.member-posts h4 {
  margin: 0 0 0.6rem;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
}

.post-item {
  padding: 0.7rem 0 0.8rem;
  border-bottom: 1px solid var(--line);
}

.post-item:last-child { border-bottom: 0; }

.post-item .post-meta {
  margin: 0 0 0.35rem;
  font-size: 0.78rem;
  letter-spacing: 0;
  text-transform: none;
  color: var(--muted);
}

.post-item .post-body { margin: 0; }

.post-delete {
  margin-top: 0.5rem;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--dim);
  border-radius: 6px;
  font-size: 0.72rem;
  padding: 0.15rem 0.5rem;
  cursor: pointer;
}

.composer { margin-top: 0.9rem; }
.composer label { display: block; font-size: 0.85rem; color: var(--muted); margin-bottom: 0.35rem; }

.composer textarea,
.composer input {
  width: 100%;
  background: #0d1527;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font-family: inherit;
  font-size: 0.95rem;
  padding: 0.6rem 0.7rem;
  margin-bottom: 0.6rem;
  resize: vertical;
}

.composer button {
  background: var(--accent);
  color: #04120a;
  border: 0;
  border-radius: 6px;
  font-family: 'Orbitron', sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.5rem 0.9rem;
  cursor: pointer;
}

.composer [data-status] { font-size: 0.8rem; color: var(--muted); margin-left: 0.5rem; }
.post-error { color: #f87171; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 1.2rem 1.3rem; }

/* ── thread replies ──────────────────────────────────────────────────── */

.replies {
  margin: 0 0 1.2rem;
  padding: 0.4rem 0 0 1rem;
  border-left: 2px solid var(--line);
}

.replies h4 {
  margin: 0.4rem 0 0.6rem;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
}

.reply { padding: 0.5rem 0; }
.reply + .reply { border-top: 1px solid var(--line); }

.reply .reply-meta {
  margin: 0 0 0.3rem;
  font-size: 0.78rem;
  color: var(--muted);
}

.reply .reply-body { margin: 0; }
.reply .reply-body p { margin: 0 0 0.5rem; }
.reply .reply-body p:last-child { margin-bottom: 0; }

.thread-more {
  display: inline-block;
  margin: -0.4rem 0 1.2rem;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 999px;
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  padding: 0.3rem 0.8rem;
  cursor: pointer;
}

.thread-more:hover { color: var(--accent); border-color: rgba(5, 196, 107, 0.4); }
.thread-more:disabled { cursor: default; color: var(--dim); }
