/* Histerium landing — void + anomaly palette, less "epic template", more game. */

:root {
  --void: #0a0612;
  --ruin: #120a1c;
  --panel: #1a1028;
  --border: #2e2344;
  --amethyst: #b46bff;
  --crystal: #4cc3ff;
  --arc: #f2c14e;
  --siege: #ff5d5d;
  --text: #f0ebf7;
  --text-dim: #a89abf;
  --font: "Instrument Sans", system-ui, -apple-system, sans-serif;
  --font-pixel: "Silkscreen", ui-monospace, monospace;
  --radius: 8px;
  /* Content column + image splits; open up on large viewports */
  --max: clamp(40rem, 56vw, 52rem);
  --wide: clamp(60rem, 90vw, 88rem);
  --hero: clamp(34rem, 50vw, 46rem);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--void);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

:focus-visible {
  outline: 2px solid var(--arc);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--arc);
  color: #120826;
  padding: 0.5rem 1rem;
  z-index: 100;
  font-weight: 600;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* ================= hero ================= */

.hero {
  position: relative;
  min-height: min(92vh, 52rem);
  display: flex;
  flex-direction: column;
  align-items: center;       /* center column like the sections below */
  justify-content: flex-end;
  padding: clamp(2rem, 6vh, 4rem) 1.25rem clamp(3rem, 8vh, 5rem);
  background:
    url("img/hero-bg.jpg") center 40% / cover no-repeat,
    var(--void);
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    var(--void) 0%,
    rgba(10, 6, 18, 0.82) 38%,
    rgba(10, 6, 18, 0.45) 70%,
    rgba(10, 6, 18, 0.35) 100%
  );
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  /* min() so align-items:center can actually center the column */
  width: min(100%, var(--hero));
  margin-inline: auto;
  animation: rise 0.75s ease-out both;
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.5rem;
}

/* Transparent voxel wordmark — soft purple flair (lighter than footer) */
.wordmark {
  width: min(100%, 20rem);
  height: auto;
  opacity: 0.96;
  filter: drop-shadow(0 2px 14px rgba(160, 90, 255, 0.28));
}

@media (min-width: 700px) {
  .wordmark { width: min(100%, 24rem); }
}

.hook {
  font-size: clamp(1.65rem, 5.5vw, 2.45rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  text-wrap: balance;
  margin-bottom: 1rem;
}

.hook em {
  font-style: normal;
  color: var(--arc);
}

.pitch {
  color: var(--text-dim);
  font-size: 1.05rem;
  max-width: none;
  margin-bottom: 1.75rem;
  text-wrap: pretty;
}

/* ---- join panel ---- */

.join-panel {
  background: rgba(18, 10, 28, 0.88);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem 1.2rem;
  backdrop-filter: blur(10px);
}

.join-label {
  font-family: var(--font-pixel);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--crystal);
  margin-bottom: 0.65rem;
}

.address {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  font-family: var(--font-pixel);
  font-size: clamp(0.95rem, 3.5vw, 1.15rem);
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.85rem 1rem;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.address:hover,
.address:focus-visible {
  border-color: var(--arc);
  box-shadow: 0 0 0 1px rgba(242, 193, 78, 0.35);
}

.address-ip { letter-spacing: 0.04em; }

.copy-hint {
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
  flex-shrink: 0;
}

.address-inline {
  display: inline-flex;
  width: auto;
  font-size: 0.8rem;
  padding: 0.25rem 0.55rem;
  vertical-align: baseline;
  gap: 0.4rem;
}

.status {
  font-family: var(--font-pixel);
  font-size: 0.68rem;
  color: var(--text-dim);
  margin-top: 0.55rem;
}

.status::before { content: "●"; margin-right: 0.4rem; }
.status.online::before { color: #4ade80; }
.status.offline::before { color: var(--text-dim); }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.9rem;
}

/* ---- buttons ---- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 1.1rem;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
  border: 1px solid transparent;
  transition: filter 0.15s, border-color 0.15s, background 0.15s;
  cursor: pointer;
  color: inherit;
  background: none;
  font-family: inherit;
}

.btn:hover { filter: brightness(1.08); }

.btn-primary {
  background: linear-gradient(115deg, var(--amethyst), #7a3bc9);
  color: #120826;
}

.btn-ghost {
  border-color: var(--border);
  background: rgba(10, 6, 18, 0.4);
  color: var(--text);
}

.btn-ghost:hover { border-color: var(--amethyst); }

.btn-quiet {
  color: var(--text-dim);
  padding-left: 0.4rem;
  padding-right: 0.4rem;
}

.btn-quiet:hover { color: var(--text); filter: none; }

.btn-sm {
  padding: 0.45rem 0.85rem;
  font-size: 0.85rem;
}

/* ================= sections ================= */

.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(3rem, 8vw, 5rem) clamp(1.25rem, 3vw, 2rem) 0.5rem;
}

.eyebrow {
  font-family: var(--font-pixel);
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--crystal);
  margin-bottom: 0.55rem;
}

.section h2 {
  font-size: clamp(1.45rem, 4vw, 1.95rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 0.85rem;
  text-wrap: balance;
}

.section-lede {
  color: var(--text-dim);
  margin-bottom: 2.25rem;
  text-wrap: pretty;
}

.section p { text-wrap: pretty; }

.section strong { color: var(--text); font-weight: 600; }

/* ================= heat rail ================= */

.run {
  list-style: none;
  position: relative;
  padding-left: 2.5rem;
  display: grid;
  gap: 1.45rem;
  --heat-fill: 1;
}

.run::before {
  content: "";
  position: absolute;
  left: 0.5rem;
  top: 0.35rem;
  bottom: 0.35rem;
  width: 3px;
  background: var(--border);
  border-radius: 2px;
}

.run::after {
  content: "";
  position: absolute;
  left: 0.5rem;
  top: 0.35rem;
  bottom: 0.35rem;
  width: 3px;
  border-radius: 2px;
  background: linear-gradient(
    to bottom,
    var(--crystal),
    var(--amethyst) 42%,
    var(--arc) 78%,
    var(--siege)
  );
  transform-origin: top;
  transform: scaleY(var(--heat-fill));
  transition: transform 0.2s linear;
}

.moment { position: relative; }

.moment::before {
  content: "";
  position: absolute;
  left: -2.22rem;
  top: 0.4rem;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--void);
  border: 2px solid var(--text-dim);
  z-index: 1;
}

.moment h3 {
  font-size: 1.05rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.moment p {
  color: var(--text-dim);
  margin-top: 0.2rem;
  font-size: 0.98rem;
}

.moment em { color: var(--arc); font-style: italic; }

.threshold {
  position: relative;
  font-family: var(--font-pixel);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--arc);
  padding: 0.05rem 0;
}

.threshold::before {
  content: "";
  position: absolute;
  left: -2.18rem;
  top: 0.28rem;
  width: 9px;
  height: 9px;
  background: var(--arc);
  transform: rotate(45deg);
  box-shadow: 0 0 10px rgba(242, 193, 78, 0.55);
  z-index: 1;
}

/* ================= split + media ================= */

.split-section {
  max-width: var(--wide);
  display: grid;
  gap: 2rem;
  align-items: center;
  padding-top: clamp(3.5rem, 9vw, 5.5rem);
  padding-left: clamp(1.25rem, 3vw, 2rem);
  padding-right: clamp(1.25rem, 3vw, 2rem);
}

@media (min-width: 860px) {
  .split-section {
    grid-template-columns: 1fr 1.05fr;
    gap: clamp(2rem, 4vw, 3.5rem);
  }
  .split-reverse .split-copy { order: 2; }
  .split-reverse .split-media { order: 1; }
}

@media (min-width: 1200px) {
  .split-section {
    grid-template-columns: 1fr 1.15fr;
  }
}

.split-copy p {
  color: var(--text-dim);
  margin-bottom: 1.25rem;
}

.pillars {
  list-style: none;
  display: grid;
  gap: 0.85rem;
}

.pillars li {
  border-left: 2px solid var(--border);
  padding-left: 0.9rem;
}

.pillars strong {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 0.15rem;
  color: var(--text);
}

.pillars span {
  color: var(--text-dim);
  font-size: 0.92rem;
}

.split-media {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--ruin);
}

.split-media img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.split-media figcaption,
.media-band-copy {
  font-size: 0.88rem;
  color: var(--text-dim);
}

.split-media figcaption {
  padding: 0.65rem 0.9rem 0.85rem;
  border-top: 1px solid var(--border);
}

.media-band {
  max-width: var(--wide);
  padding-top: clamp(3.5rem, 9vw, 5.5rem);
  padding-left: clamp(1.25rem, 3vw, 2rem);
  padding-right: clamp(1.25rem, 3vw, 2rem);
}

.media-band-figure {
  margin: 0 0 1.25rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.media-band-figure img {
  width: 100%;
  max-height: 28rem;
  object-fit: cover;
  object-position: center 40%;
}

.media-band-copy {
  max-width: var(--max);
}

.media-band-copy h2 {
  color: var(--text);
  margin-bottom: 0.65rem;
}

.media-band-copy p {
  color: var(--text-dim);
  font-size: 1.02rem;
}

/* ================= join + footer ================= */

.join-section { padding-bottom: 2rem; }

.join-steps {
  display: grid;
  gap: 0.75rem;
  padding-left: 1.2rem;
  color: var(--text-dim);
}

.join-steps strong { color: var(--text); }
.join-steps a { color: var(--amethyst); }
.join-steps a:hover { color: var(--arc); }

footer {
  border-top: 1px solid var(--border);
  margin-top: 4rem;
  padding: 2.25rem 1.25rem 6rem; /* room for sticky bar */
}

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  text-align: center;
}

.footer-brand {
  display: flex;
  justify-content: center;
  margin-bottom: 0.65rem;
}

.wordmark-sm {
  width: min(9rem, 42vw);
  height: auto;
  opacity: 0.92;
  filter: drop-shadow(0 2px 12px rgba(140, 60, 255, 0.35));
}

footer a { color: var(--text-dim); }
footer a:hover { color: var(--arc); }

footer p { margin-top: 0.5rem; }

.fine-print {
  font-size: 0.78rem;
  color: var(--text-dim);
  opacity: 0.75;
}

/* ================= sticky join ================= */

.sticky-join {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.65rem 1rem calc(0.65rem + env(safe-area-inset-bottom));
  background: rgba(10, 6, 18, 0.92);
  border-top: 1px solid var(--border);
  backdrop-filter: blur(12px);
  transform: translateY(110%);
  transition: transform 0.25s ease;
}

.sticky-join.is-visible {
  transform: translateY(0);
}

.address-sticky {
  width: auto;
  min-width: min(100%, 18rem);
  padding: 0.55rem 0.85rem;
  font-size: 0.85rem;
}

/* ================= motion ================= */

@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-inner { animation: none; }
  .run::after { transition: none; }
  .sticky-join { transition: none; }
}

@media (max-width: 520px) {
  .sticky-join .btn { display: none; }
}
