/* Swamp Secrets — late-2000s conspiracy blog. Deliberately NOT the Marsh
   Chronicle's aesthetic (constellation rule: share tooling, never looks).
   v2 theme "Feu Follet": blue-black night water lit by the thing the site
   reports on — ghost-cyan glow, typed-report masthead (Special Elite,
   display only), warm accents reserved for warnings and the RSS badge.
   Still a 2009 custom WordPress theme at heart: gradients, rounded
   corners, inset glows, a sidebar full of widgets. */

/* Self-hosted (Apache 2.0, license alongside in /fonts/) — no external
   font CDN; the site stays self-contained like the rest of the lane. */
@font-face {
  font-family: 'Special Elite';
  src: url('../fonts/special-elite.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}

* { box-sizing: border-box; }

/* tiled grain, like every 2009 dark theme's noise.gif */
:root {
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.055'/%3E%3C/svg%3E");
}

body {
  margin: 0;
  background: #06090c;
  background-image:
    radial-gradient(ellipse 900px 340px at 50% -60px, rgba(127, 212, 193, 0.12), transparent),
    var(--grain),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.02) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(90deg, rgba(0,0,0,0.18) 0 2px, transparent 2px 5px);
  color: #b8c8cd;
  font: 13px/1.65 "Trebuchet MS", "Lucida Grande", Tahoma, sans-serif;
}

/* vignette over everything — the page is lit from its own middle */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 5;
  background: radial-gradient(ellipse 110% 85% at 50% 20%, rgba(0,0,0,0) 55%, rgba(0,0,0,0.38) 100%);
}

a { color: #7fd4c1; }
a:hover { color: #d8fff2; }
/* F1: era-correct visited state, scoped to content links */
.post p a:visited, .widget .in a:visited, .stub-notice a:visited, .board-table a:visited { color: #6b9a93; }

.wrap { width: auto; max-width: 960px; margin: 0 auto; padding: 0 10px; }

/* ---- header (F2: banner-art band; placeholder until real art exists) ---- */
.site-head {
  position: relative;
  padding: 38px 0 20px 0;
  text-align: center;
  border-bottom: 1px solid #14212a;
  background:
    linear-gradient(rgba(6,9,12,0.25) 0%, rgba(6,9,12,0.55) 72%, #06090c 100%),
    var(--grain),
    url("../img/masthead.jpg") center / cover no-repeat,
    #070d12;
}
.site-title {
  font-family: "Special Elite", "Courier New", monospace;
  font-size: 54px;
  font-weight: normal;
  text-transform: uppercase;
  letter-spacing: 4px;
  margin: 0;
  color: #a8e6d8;
  text-shadow: 0 0 20px rgba(127, 212, 193, 0.55), 0 2px 0 #000;
}
.site-title a { color: inherit; text-decoration: none; }
.site-sub {
  font-family: "Courier New", monospace;
  font-weight: bold;
  font-size: 11px;
  color: #79a19d;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-shadow: 0 0 4px rgba(143, 240, 218, 0.45);
  margin: 6px 0 0 0;
}
.site-motto {
  font-family: Georgia, serif;
  font-style: italic;
  color: #46626b;
  font-size: 12px;
  margin: 8px 0 0 0;
}

/* ---- nav ---- */
.nav {
  display: flex;
  justify-content: center;
  gap: 2px;
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,0.02) 0 1px, transparent 1px 3px),
    linear-gradient(#12222a, #0a1218);
  border-top: 1px solid #24444d;
  border-bottom: 1px solid #000;
  box-shadow: 0 2px 6px rgba(0,0,0,0.6);
}
.nav a {
  color: #bfe3da;
  text-decoration: none;
  font-family: "Courier New", monospace;
  font-size: 13px;
  font-weight: normal;
  text-transform: uppercase;
  letter-spacing: 2px;
  padding: 9px 16px;
  border-right: 1px solid rgba(0,0,0,0.4);
  border-left: 1px solid rgba(255,255,255,0.05);
  text-shadow: 0 1px 0 #000;
  transition: text-shadow 0.25s, color 0.15s;
}
.nav a:hover {
  background: rgba(127, 212, 193, 0.10);
  color: #eafffa;
  text-shadow: 0 0 9px rgba(127, 212, 193, 0.65), 0 1px 0 #000;
}
.nav a.here { background: #06090c; color: #7fd4c1; box-shadow: inset 0 2px 6px rgba(0,0,0,0.8); }

/* ---- layout ---- */
.cols { display: flex; gap: 20px; padding: 20px 0 30px 0; align-items: flex-start; }
.main { flex: 1; min-width: 0; }
.side { width: 300px; flex-shrink: 0; display: flex; flex-direction: column; gap: 14px; }

/* ---- posts ---- */
.post {
  background: var(--grain), linear-gradient(#0d141a, #0a1014);
  border: 1px solid #1c2f38;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.55), inset 0 1px 0 rgba(255,255,255,0.04), inset 0 0 24px rgba(127,212,193,0.03);
  padding: 18px 22px;
  margin-bottom: 20px;
}
.post h2, .post h1 {
  font-family: Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 24px;
  line-height: 1.2;
  margin: 0 0 4px 0;
  color: #cdeae2;
  text-shadow: 0 1px 0 #000;
}
.post h1 { font-size: 28px; }
.post h2 a, .post h1 a { color: inherit; text-decoration: none; }
.post h2 a:hover { color: #eafffa; }
.postmeta {
  font-size: 11px;
  color: #5f7a80;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 1px dotted #1c2f38;
  padding-bottom: 8px;
  margin-bottom: 12px;
}
.postmeta .tag { color: #7fd4c1; }
.post p { margin: 0 0 12px 0; }
/* chapter-opening drop cap on story posts */
.post:has(.polaroid) > p:first-of-type::first-letter {
  float: left;
  font-family: Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif;
  font-size: 40px;
  line-height: 0.85;
  padding: 3px 8px 0 0;
  color: #9fd4c6;
  text-shadow: 0 0 10px rgba(127, 212, 193, 0.35), 0 1px 0 #000;
}
.post .reader-letter {
  border-left: 3px solid #2a4a44;
  background: rgba(127, 212, 193, 0.05);
  box-shadow: 0 0 14px rgba(127, 212, 193, 0.07);
  padding: 8px 14px;
  margin: 0 0 12px 0;
  font-style: italic;
  color: #b9cbc6;
}
.signoff {
  font-family: Georgia, serif;
  font-style: italic;
  color: #7fd4c1;
  margin-top: 14px;
}
.signoff.dim { color: #5f7a80; }
.signoff.dim .sig-motto { color: #79a19d; }
.editnote { font-size: 11px; color: #5f7a80; font-style: italic; }
.thread-close { margin-top: 18px; }
.more-link { text-align: center; color: #46626b; }
.readmore { font-size: 12px; }
.readmore a { text-decoration: none; }
.readmore a:hover { text-decoration: underline; }

/* ---- sidebar widgets ---- */
.widget {
  background: var(--grain), linear-gradient(#0e161c, #0a1014);
  border: 1px solid #1c2f38;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.5);
  overflow: hidden;
}
.widget h3 {
  margin: 0;
  font-family: "Courier New", monospace;
  font-weight: normal;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #d8f2ec;
  text-shadow: 0 1px 0 #000, 0 0 8px rgba(0, 0, 0, 0.85);
  padding: 8px 12px;
  background:
    linear-gradient(90deg, rgba(6,9,12,0.66) 0%, rgba(6,9,12,0.36) 55%, rgba(6,9,12,0.52) 100%),
    url("../img/widget-head.jpg") left center / cover no-repeat,
    linear-gradient(#173038, #0d1c21);
  border-bottom: 1px solid #000;
}
.widget .in { padding: 12px; }
.widget ul { margin: 0; padding: 0 0 0 18px; }
.widget li { margin-bottom: 6px; }
.sub-note { color: #5f7a80; }
.sub-note.sm { font-size: 11px; }
.counter-note { font-size: 10px; color: #46626b; text-align: center; margin-top: 4px; }

.tagcloud a { display: inline-block; margin: 0 6px 4px 0; }
.t1 { font-size: 11px; } .t2 { font-size: 13px; } .t3 { font-size: 16px; }
.t4 { font-size: 19px; } .t5 { font-size: 23px; }

/* period-true: the RSS badge stays orange — the one foreign color */
.rss-badge {
  display: inline-block;
  background: linear-gradient(#f79433, #d35d0b);
  color: #fff;
  font-weight: bold;
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 4px;
  border: 1px solid #8a3c05;
  text-decoration: none;
  text-shadow: 0 1px 1px rgba(0,0,0,0.4);
}

.counterbox {
  font-family: "Courier New", monospace;
  text-align: center;
  color: #8ff0da;
  background:
    repeating-linear-gradient(0deg, rgba(0,0,0,0.35) 0 1px, transparent 1px 3px),
    #04070a;
  border: 1px solid #12222a;
  border-radius: 4px;
  padding: 8px;
  text-shadow: 0 0 8px rgba(143, 240, 218, 0.75);
}

/* ---- believers: the lights themselves (js/beau.js builds this) ---- */
.wispfield {
  position: relative;
  height: 74px;
  background: radial-gradient(ellipse 120% 90% at 50% 130%, #0a141a, #04070a);
  border: 1px solid #12222a;
  border-radius: 4px;
  overflow: hidden;
}
/* the basin, drifting by — landmarks, not coordinates */
.wispfield::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../img/basin-map.png") repeat-x 0 0 / 274px 74px;
  opacity: 0.7;
  animation: basin-drift 45s linear infinite;
}
@keyframes basin-drift { to { background-position: -274px 0; } }
/* radar sweep — pings each light as it passes (delays set in js/beau.js) */
.wispfield::after {
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  width: 15%;
  left: -16%;
  background: linear-gradient(90deg,
    rgba(127,212,193,0) 0%,
    rgba(127,212,193,0.022) 60%,
    rgba(168,230,216,0.09) 97%,
    rgba(216,255,242,0.21) 100%);
  animation: wisp-sweep 16s linear infinite;
}
@keyframes wisp-sweep { from { left: -16%; } to { left: 114%; } }
.wispfield .dot {
  position: absolute;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: #d8fff2;
  --dotglow: 0 0 7px 2px rgba(127, 212, 193, 0.55);
  box-shadow: var(--dotglow);
  animation: wisp-flicker 4s ease-in-out infinite alternate;
}
.wispfield .dot.you { width: 5px; height: 5px; --dotglow: 0 0 9px 3px rgba(216, 255, 242, 0.75); }
@keyframes wisp-ping {
  0%   { box-shadow: 0 0 10px 4px rgba(216, 255, 242, 0.55); background: #eafffa; }
  8%   { box-shadow: var(--dotglow); background: #d8fff2; }
  100% { box-shadow: var(--dotglow); background: #d8fff2; }
}
@keyframes wisp-flicker {
  from { opacity: 0.25; transform: translateY(0); }
  to   { opacity: 1;    transform: translateY(-3px); }
}
.wisp-read {
  font: bold 11px "Courier New", monospace;
  color: #5f7a80;
  text-align: center;
  margin-top: 5px;
  letter-spacing: 0.5px;
  white-space: nowrap;
}
.wisp-read .wisp-n { color: #8ff0da; text-shadow: 0 0 6px rgba(143, 240, 218, 0.5); }
@media (prefers-reduced-motion: reduce) {
  .wispfield::before, .wispfield .dot { animation: none; }
  .wispfield::after { display: none; }
}

/* ---- forum ---- */
/* F3: warm second accent promoted — pinned amber / locked rust, on purpose */
.board-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.board-table th {
  text-align: left;
  background: linear-gradient(#173038, #0d1c21);
  color: #d8f2ec;
  padding: 7px 10px;
  border: 1px solid #000;
  font-family: "Courier New", monospace;
  font-weight: normal;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 11.5px;
}
.board-table td { padding: 8px 10px; border: 1px solid #14212a; background: #0c1218; vertical-align: top; }
.board-table tr:nth-child(odd) td { background: #0e161d; }
.thread-title { font-weight: bold; font-size: 13px; }
.thread-title a { text-decoration: none; }
.pinned { color: #d8b96a; }
.locked { color: #b0563f; }
.byline { color: #5f7a80; font-size: 11px; }
.thread-head { margin-top: 24px; }
/* thread pages */
.board-pages {
  font: 11px "Courier New", monospace;
  color: #5f7a80;
  letter-spacing: 1px;
  margin: 0 0 12px 0;
}
.attach-stub {
  font: 11px "Courier New", monospace;
  color: #5f7a80;
  border: 1px dashed #24444d;
  background: rgba(127, 212, 193, 0.03);
  padding: 6px 10px;
  margin: 8px 0 0 0;
}
.post > .attach-stub { margin: 4px 0 16px 0; }

.threadpost {
  border: 1px solid #1c2f38;
  border-radius: 6px;
  background: #0c1218;
  margin-bottom: 10px;
  display: flex;
}
.threadpost .who {
  width: 140px;
  flex-shrink: 0;
  padding: 10px;
  border-right: 1px solid #14212a;
  font-size: 11px;
  color: #7fd4c1;
  background: #0a1015;
  border-radius: 6px 0 0 6px;
}
.threadpost .who .avatar { font-size: 26px; }
.threadpost .who .avatar img {
  display: block;
  width: 56px;
  height: 56px;
  object-fit: cover;
  border: 1px solid #24444d;
  background: #04070a;
}
.threadpost .who .rank { color: #5f7a80; font-size: 10px; }
.threadpost .said { padding: 10px 14px; min-width: 0; }
.threadpost .when { color: #5f7a80; font-size: 10px; margin-bottom: 6px; }

details.thread { margin-bottom: 14px; }
details.thread summary {
  cursor: pointer;
  padding: 8px 12px;
  background: linear-gradient(#122028, #0c1218);
  border: 1px solid #1c2f38;
  border-radius: 6px;
  font-weight: bold;
  color: #cdeae2;
}
details.thread[open] summary { border-radius: 6px 6px 0 0; }
details.thread .body { border: 1px solid #1c2f38; border-top: 0; border-radius: 0 0 6px 6px; padding: 12px; background: #0a1014; }

/* ---- podcast ---- */
.episode {
  display: flex;
  gap: 14px;
  background: #0c1218;
  border: 1px solid #1c2f38;
  border-radius: 8px;
  padding: 14px;
  margin-bottom: 14px;
}
.episode .num {
  font-family: Palatino, "Palatino Linotype", Georgia, serif;
  font-size: 30px;
  color: #46626b;
  width: 58px;
  flex-shrink: 0;
  text-align: center;
}
.episode h3 { margin: 0 0 4px 0; color: #cdeae2; font-size: 16px; }
.episode p { margin: 6px 0 0 0; }
.episode .dur { color: #5f7a80; font-size: 11px; }
.ep-missing { color: #5f7a80; }
/* F8: streams are down in-fiction — the buttons should say so */
.listen {
  display: inline-block;
  margin-top: 6px;
  font-size: 11px;
  font-weight: bold;
  color: #5f7a80;
  background: none;
  border: 1px dashed #24444d;
  border-radius: 4px;
  padding: 3px 12px;
  text-decoration: none;
}
.listen::after { content: " \00b7 down since Jan"; font-weight: normal; letter-spacing: 0.5px; }
.listen:hover { color: #7fd4c1; border-color: #2a4a44; }

/* ---- tip line (F6: promoted from inline styles) ---- */
.tipline { margin-top: 16px; }
.tipline fieldset { border: 1px solid #1c2f38; border-radius: 6px; padding: 14px; opacity: 0.55; }
.tipline legend { padding: 0 8px; color: #5f7a80; }
.tipline input, .tipline textarea {
  width: 100%;
  padding: 6px;
  background: #06090c;
  border: 1px solid #1c2f38;
  color: #b8c8cd;
  border-radius: 4px;
  font: inherit;
}
.tipline button { padding: 5px 18px; border-radius: 4px; border: 1px solid #24444d; background: #0d1c21; color: #5f7a80; }

/* ---- footer ---- */
.site-foot {
  border-top: 1px solid #14212a;
  padding: 16px 0 30px 0;
  text-align: center;
  font-size: 11px;
  color: #46626b;
}
.site-foot a { color: #6b9a93; }

/* F5: 88x31 web buttons. Copy is DRAFT pending content sign-off. */
.badges { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.b88 {
  width: 88px;
  height: 31px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1.15;
  background: linear-gradient(#101c22, #0a1014);
  border: 1px solid #24444d;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06), 0 1px 2px #000;
  font-family: "Courier New", monospace;
  font-size: 10px;
  color: #7fd4c1;
  text-decoration: none;
}
.b88 b { font-size: 8px; font-weight: bold; letter-spacing: 1px; color: #5f7a80; }
.b88:hover { color: #d8fff2; border-color: #7fd4c1; }
.b88.amber { color: #e0a437; border-color: #4a3a1c; }
.b88.amber b { color: #8a7454; }
.b88.amber:hover { color: #f0c268; border-color: #e0a437; }
.b88.dead { opacity: 0.45; }
.foot-stamp {
  font-family: "Courier New", monospace;
  font-size: 11px;
  letter-spacing: 1px;
  color: #3f545c;
  margin: 10px 0 0 0;
}

.stub-notice {
  border: 1px dashed #2a4a44;
  background: rgba(127, 212, 193, 0.05);
  border-radius: 6px;
  padding: 14px 18px;
  color: #b9cbc6;
}

::selection { background: #1d4a42; color: #eafffa; }

/* ---- feature-image placeholders (exploration — pick a layout) ---- */
.post::after { content: ""; display: block; clear: both; }
.feat {
  background: repeating-linear-gradient(45deg, #0c141a 0 12px, #0a1015 12px 24px);
  border: 1px solid #1c2f38;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.feat .feat-what {
  font: 11px "Courier New", monospace;
  color: #46626b;
  letter-spacing: 1px;
  text-align: center;
  padding: 0 10px;
}
.feat .feat-dim {
  position: absolute;
  top: 4px; right: 6px;
  font: bold 9px "Courier New", monospace;
  color: #5f7a80;
  letter-spacing: 1px;
}
.feat-banner { width: 100%; height: 200px; margin: 0 0 14px 0; }
.feat-right { width: 220px; height: 160px; float: right; margin: 4px 0 10px 16px; }
.feat-left { width: 220px; height: 150px; float: left; margin: 4px 16px 10px 0; }
.feat-center { width: 420px; max-width: 100%; height: 200px; margin: 0 auto 6px auto; }
.feat-cap {
  font: italic 11px Georgia, serif;
  color: #5f7a80;
  margin: 0 0 12px 0;
  text-align: center;
}
/* recovered archive photographs */
.archive-photo {
  display: block;
  width: 100%;
  max-width: 560px;
  margin: 0 auto 6px auto;
  border: 1px solid #1c2f38;
  box-shadow: 0 3px 10px rgba(0,0,0,0.55);
}
.polaroid {
  float: none;
  width: auto;
  max-width: 100%;
  padding: 10px 10px 8px 10px;
  margin: 4px 0 16px 0;
  background: #c9d4ce;
  border: 1px solid #8fa39c;
  box-shadow: 0 4px 12px rgba(0,0,0,0.6);
  transform: rotate(1deg);
}
.polaroid .feat { width: 100%; height: 300px; }
.polaroid img {
  display: block;
  width: 100%;
  height: 300px;
  object-fit: cover;
  border: 1px solid #a4b5ae;
}
.polaroid .pol-cap {
  font: italic 12px Georgia, serif;
  color: #24332f;
  text-align: center;
  margin: 8px 0 0 0;
}
.polaroid::before {
  content: "";
  position: absolute;
  top: -8px; left: 50%;
  width: 64px; height: 16px;
  margin-left: -32px;
  background: rgba(127, 212, 193, 0.28);
  border: 1px solid rgba(31, 58, 52, 0.22);
  transform: rotate(-2deg);
}
.polaroid { position: relative; }

/* click-to-enlarge for recovered photographs (js/beau.js builds the overlay) */
.polaroid img, .archive-photo { cursor: zoom-in; }
.lightbox {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 50;
  background: rgba(3, 5, 7, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
  cursor: zoom-out;
}
.lightbox-frame {
  background: #c9d4ce;
  border: 1px solid #8fa39c;
  padding: 12px 12px 10px 12px;
  max-width: 940px;
  box-shadow: 0 14px 50px rgba(0,0,0,0.85), 0 0 40px rgba(127, 212, 193, 0.10);
}
.lightbox-frame img {
  display: block;
  max-width: 100%;
  max-height: 74vh;
  border: 1px solid #a4b5ae;
}
.lightbox-cap {
  font: italic 13px Georgia, serif;
  color: #24332f;
  text-align: center;
  padding: 9px 6px 0 6px;
}

/* sidebar mini polaroid (the host's "headshot") */
.polaroid.mini { margin: 2px auto 12px auto; padding: 8px 8px 6px 8px; }
.polaroid.mini img, .polaroid.mini .feat { height: 170px; }
.polaroid.mini .pol-cap { font-size: 11px; margin-top: 6px; }

/* the old masthead, kept for the record */
.relic {
  margin-top: 26px;
  border-top: 1px dotted #1c2f38;
  padding-top: 18px;
}
.relic img {
  display: block;
  width: 100%;
  border: 1px solid #1c2f38;
  box-shadow: 0 3px 10px rgba(0,0,0,0.55);
}
.relic .feat-cap { font-size: 12px; }

/* F7: quiet fallback below the fixed grid — nobody designed this, it just works */
@media (max-width: 979px) {
  .cols { flex-direction: column; }
  .side { width: 100%; }
  .nav { flex-wrap: wrap; }
  .site-title { font-size: 32px; letter-spacing: 3px; }
}
