/* Redwake — coal / ember. Single file, no frameworks. */

*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --bg: #070505;
  --bg-raised: #100b0b;
  --bg-panel: #160e0e;
  --ink: #f2e8e6;
  --ink-muted: #b5a4a0;
  --ember: #c41e1e;
  --ember-hot: #ff5a3a;
  --ember-deep: #6e0c10;
  --steel: #8a9199;
  --line: #2a1518;
  --line-hot: #3a1518;
  --max: 68rem;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --display: Georgia, "Times New Roman", "Liberation Serif", serif;
  --section-pad: clamp(2.5rem, 6vw, 4rem);
}

html {
  color-scheme: dark;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--ember-hot);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: #ff8a6e;
}

a:focus-visible,
.btn-discord:focus-visible,
.header-cta:focus-visible {
  outline: 2px solid var(--ember-hot);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 100;
  padding: 0.5rem 0.85rem;
  background: var(--ember);
  color: #fff;
  font-weight: 600;
  border-radius: 2px;
  text-decoration: none;
}

.skip-link:focus {
  top: 0.75rem;
}

.wrap {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* ——— Header (sticky glass/coal — Toren L1) ——— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  width: 100%;
  margin: 0;
  padding: 0.85rem max(1rem, calc((100% - var(--max)) / 2 + 1rem));
  background: rgba(7, 5, 5, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(42, 21, 24, 0.65);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.brand-mark {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 4px;
  border: 1px solid var(--line);
}

.brand-name {
  font-family: var(--display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.header-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.45rem 0.95rem;
  border: 1px solid var(--ember-deep);
  background: transparent;
  color: var(--ink);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.header-cta:hover {
  background: var(--ember-deep);
  border-color: var(--ember);
  color: var(--ink);
}

/* ——— Hero ——— */
.hero {
  position: relative;
  isolation: isolate;
  min-height: min(100svh, 52rem);
  display: flex;
  align-items: flex-end;
}

.hero-media {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #050303;
  pointer-events: none;
}

.hero-media picture {
  display: block;
  width: 100%;
  height: 100%;
}

.hero-banner {
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
  object-position: center center;
}

/* Selene pass 2 — lighten center, soft side vignette */
.hero-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      180deg,
      rgba(7, 5, 5, 0.05) 0%,
      rgba(7, 5, 5, 0.28) 48%,
      rgba(7, 5, 5, 0.94) 100%
    ),
    linear-gradient(
      90deg,
      rgba(7, 5, 5, 0.55) 0%,
      transparent 28%,
      transparent 72%,
      rgba(7, 5, 5, 0.4) 100%
    );
  pointer-events: none;
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(100% - 2rem, var(--max));
  margin: 0 auto;
  padding-inline: 1rem;
  padding-top: clamp(6rem, 14vh, 9rem);
  padding-bottom: clamp(3rem, 10vh, 7rem);
  text-align: center;
}

.eyebrow {
  margin: 0 0 0.65rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

/* Selene pass 3 — title ember glow */
.hero-copy h1 {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(2.6rem, 8vw, 4.5rem);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  line-height: 1.05;
  text-shadow:
    0 0 28px rgba(196, 30, 30, 0.45),
    0 0 56px rgba(110, 12, 16, 0.35),
    0 2px 24px rgba(0, 0, 0, 0.85);
}

/* Selene — hero wordmark: first R + last e stronger */
.hero-copy h1 .hero-cap {
  font-size: 1.22em;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.04em;
  text-shadow:
    0 0 32px rgba(196, 30, 30, 0.55),
    0 0 64px rgba(110, 12, 16, 0.4),
    0 2px 28px rgba(0, 0, 0, 0.9);
}

.hero-copy h1 .hero-mid {
  font-size: 0.9em;
  font-weight: 600;
  color: rgba(242, 232, 230, 0.82);
  letter-spacing: 0.16em;
  text-shadow:
    0 0 20px rgba(196, 30, 30, 0.28),
    0 2px 18px rgba(0, 0, 0, 0.75);
}

.charter {
  margin: 0.85rem 0 0;
  font-family: var(--display);
  font-size: clamp(1.15rem, 2.8vw, 1.55rem);
  font-style: italic;
  letter-spacing: 0.08em;
  color: var(--ember-hot);
  text-shadow: 0 0 18px rgba(255, 90, 58, 0.35);
}

.charter::before,
.charter::after {
  content: "";
  display: inline-block;
  width: 1.5rem;
  height: 1px;
  margin: 0 0.65rem;
  vertical-align: middle;
  background: var(--ember-deep);
}

.hero-line {
  max-width: 36rem;
  margin: 1rem auto 1.5rem;
  font-size: clamp(1.05rem, 2.2vw, 1.125rem);
  line-height: 1.65;
  color: var(--ink-muted);
}

.hero-copy .btn-discord {
  margin-top: 0.25rem;
}

/* ——— Sections (Selene 4 / Toren L2) ——— */
.pitch,
.want,
.cta {
  position: relative;
  z-index: 1;
  padding-block: var(--section-pad);
  background: rgba(7, 5, 5, 0.9);
}

.pitch {
  border-bottom: 1px solid var(--line);
}

.pitch h2,
.want h2 {
  margin: 0 0 0.85rem;
  font-family: var(--display);
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  letter-spacing: 0.06em;
  color: var(--ember-hot);
  text-align: center;
}

.pitch h2::after,
.want h2::after {
  content: "";
  display: block;
  width: 2.5rem;
  height: 2px;
  margin: 0.55rem auto 0;
  background: var(--ember);
  box-shadow: 0 0 8px rgba(196, 30, 30, 0.4);
}

.lede {
  margin: 0 auto;
  max-width: 36rem;
  text-align: center;
  font-size: clamp(1.125rem, 2.4vw, 1.2rem);
  line-height: 1.65;
  color: var(--ink-muted);
}

.want .lede,
.pitch .lede {
  margin: 0 auto;
}

/* ——— CTA panel (Selene 8 / Toren L5) ——— */
.cta {
  padding-top: 0;
}

.cta-panel {
  max-width: 40rem;
  margin-inline: auto;
  padding: 2.25rem 1.5rem;
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(196, 30, 30, 0.22), transparent 55%),
    var(--bg-panel);
  border: 1px solid var(--line-hot);
  border-radius: 4px;
  box-shadow: inset 0 1px 0 rgba(255, 90, 58, 0.1);
}

.cta-panel h2,
.cta-panel .door-title {
  margin: 0 0 0.65rem;
  font-family: var(--display);
  font-size: clamp(1.85rem, 4.5vw, 2.65rem);
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  line-height: 1.15;
  color: #fff;
  text-shadow:
    0 0 28px rgba(196, 30, 30, 0.45),
    0 0 56px rgba(110, 12, 16, 0.35),
    0 2px 20px rgba(0, 0, 0, 0.85);
}

.cta-panel .door-title .door-lead {
  color: var(--ember-hot);
}

.cta-panel h2::after {
  content: "";
  display: block;
  width: 2.5rem;
  height: 2px;
  margin: 0.55rem auto 0;
  background: var(--ember);
  box-shadow: 0 0 8px rgba(196, 30, 30, 0.4);
}

.cta-panel p {
  margin: 0.85rem auto 1.5rem;
  max-width: 32rem;
  font-size: clamp(1.125rem, 2.4vw, 1.2rem);
  line-height: 1.65;
  color: var(--ink-muted);
}

/* Selene pass 6 — primary CTA */
.btn-discord {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 1rem 1.85rem;
  background: linear-gradient(180deg, #d62828 0%, #8f1014 100%);
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid #ff5a3a55;
  border-radius: 3px;
  box-shadow:
    0 8px 28px rgba(140, 16, 20, 0.45),
    inset 0 1px 0 rgba(255, 200, 180, 0.18);
  transition: transform 0.12s ease, filter 0.12s ease, box-shadow 0.12s ease;
}

.btn-discord:hover {
  color: #fff;
  filter: brightness(1.08);
  transform: translateY(-1px);
  box-shadow:
    0 10px 32px rgba(160, 20, 24, 0.55),
    inset 0 1px 0 rgba(255, 200, 180, 0.22);
}

.btn-discord:active {
  transform: translateY(1px);
  filter: brightness(0.96);
  box-shadow: 0 4px 16px rgba(140, 16, 20, 0.4);
}

/* Selene — Enter Discord button with locked mark */
.btn-discord--mark {
  gap: 0.65rem;
}

.btn-discord-mark {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  border-radius: 3px;
  border: 1px solid rgba(255, 90, 58, 0.35);
}

/* Selene — The Door / Open the Gates / Enter Discord label */
.cta-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  margin-top: 0.25rem;
}

.cta-dest {
  margin: 0.15rem 0 0;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: lowercase;
  color: var(--ink-muted);
  opacity: 0.85;
}

.cta-panel p {
  margin-bottom: 1.15rem;
}

/* ——— Footer (Selene 9) ——— */
.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--line);
  padding: 2.75rem 0 2.5rem;
  background: rgba(5, 3, 3, 0.92);
}

.footer-inner {
  text-align: center;
}

.footer-charter {
  margin: 0;
  font-family: var(--display);
  font-style: italic;
  letter-spacing: 0.1em;
  color: var(--ember-hot);
}

.footer-note {
  margin: 0.65rem 0 1.25rem;
  font-size: 0.88rem;
  color: var(--ink-muted);
}

.footer-note a {
  color: var(--ember-hot);
  text-decoration: none;
  border-bottom: 1px solid #b0101844;
  font-weight: 600;
}

.footer-note a:hover {
  border-bottom-color: #d62828;
  color: #ff8a6e;
}

.footer-mark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  color: #6a6260;
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0.72;
}

.footer-mark img {
  border-radius: 3px;
  opacity: 0.55;
}

/* ——— Desktop CTA padding (Toren L5) ——— */
@media (min-width: 720px) {
  .cta-panel {
    padding: 2.75rem 2.5rem;
  }
}

/* ——— Mobile (Selene 10 / Toren L3–L4) ——— */
@media (max-width: 480px) {
  .site-header {
    padding: 0.7rem 1rem;
  }

  .brand-name {
    letter-spacing: 0.08em;
    font-size: 1rem;
  }

  .hero {
    min-height: min(78svh, 42rem);
  }

  .hero-media {
    position: absolute;
    inset: 0;
  }

  .hero-banner {
    object-fit: contain;
    object-position: center 30%;
  }

  .hero-copy {
    margin: 0 auto;
    padding-top: 5rem;
    padding-bottom: 2.5rem;
    padding-inline: 1rem;
  }

  .hero-copy h1 {
    letter-spacing: 0.09em;
  }

  .charter::before,
  .charter::after {
    width: 0.85rem;
    margin: 0 0.4rem;
  }

  .cta-panel {
    padding: 1.75rem 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn-discord,
  .header-cta {
    transition: none;
  }

  .btn-discord:hover,
  .btn-discord:active {
    transform: none;
  }

  /* Reduced motion keeps the banner in its original document flow. */
  .hero {
    min-height: 0;
    display: block;
  }

  .hero-media {
    position: relative;
    inset: auto;
    width: 100%;
    height: auto;
    z-index: auto;
  }

  .hero-media picture {
    width: 100%;
    height: auto;
  }

  .hero-banner {
    width: 100%;
    height: auto;
    max-height: min(70vh, 560px);
    object-fit: contain;
    object-position: center center;
  }

  .hero-copy {
    margin: -5.5rem auto 0;
    padding-top: 0;
    padding-bottom: 2.5rem;
  }
}

@media (prefers-reduced-motion: reduce) and (max-width: 480px) {
  .hero-banner {
    max-height: min(42vh, 280px);
    object-position: center 30%;
  }

  .hero-copy {
    margin-top: -2.5rem;
    padding-top: 0;
  }
}


/* How to join list (Mara) */
.want ul {
  max-width: 36rem;
  margin: 1.25rem auto 0;
  padding: 0 0 0 1.25rem;
  color: var(--ink-muted);
  line-height: 1.7;
  text-align: left;
}
.want li {
  margin: 0.55rem 0;
}
.want li strong {
  color: var(--ink);
  font-weight: 600;
}
.footer-sep {
  opacity: 0.5;
}

/* Recruit pass — fit grid + numbered join path */
.fit-grid {
  display: grid;
  gap: 1.5rem 2rem;
  margin-top: 1.25rem;
}
@media (min-width: 720px) {
  .fit-grid { grid-template-columns: 1fr 1fr; }
}
.fit-label {
  margin: 0 0 0.5rem;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ember-hot, #ff5a3a);
  font-weight: 600;
}
.join-steps {
  margin: 1rem 0 0;
  padding-left: 1.25rem;
  max-width: 36rem;
  line-height: 1.7;
  color: var(--ink-muted, #b5a4a0);
}
.join-steps li { margin: 0.4rem 0; }
.join-steps strong { color: var(--ink, #f2e8e6); }