/* The landing page of raidelver.com: gothic and dark, as the game. Self-hosted fonts (OFL),
   no trackers, no cookies. */

@font-face {
  font-family: 'Grenze Gotisch';
  src: url('/fonts/GrenzeGotisch-variable.woff2') format('woff2');
  font-weight: 400 900;
  font-display: swap;
}
@font-face {
  font-family: 'Cormorant Garamond';
  src: url('/fonts/CormorantGaramond-variable.woff2') format('woff2');
  font-weight: 300 700;
  font-display: swap;
}
@font-face {
  font-family: 'Cormorant Garamond';
  src: url('/fonts/CormorantGaramond-italic-variable.woff2') format('woff2');
  font-weight: 300 700;
  font-style: italic;
  font-display: swap;
}

/* The game has one dark look, and the page keeps it in all colour schemes. */
:root {
  --bg: #07060a;
  --bg-2: #0d0b11;
  --ink: #ddd5c4;
  --bone: #e6dfd0;
  --muted: #8f877a;
  --blood: #7d1414;
  --blood-bright: #b3261e;
  --silver: #b4b1aa;
  --line: rgba(221, 213, 196, 0.15);
  --line-strong: rgba(221, 213, 196, 0.3);
  --display: 'Grenze Gotisch', Georgia, serif;
  --text: 'Cormorant Garamond', Garamond, Georgia, serif;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--text);
  font-size: 20px;
  font-weight: 500;
  line-height: 1.5;
  overflow-x: hidden;
}

a {
  color: var(--silver);
}

.top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 0 max(16px, env(safe-area-inset-left));
  z-index: 3;
}

.mark {
  width: 34px;
  height: 34px;
  color: var(--bone);
}

.lang {
  font: inherit;
  font-size: 1rem;
  background: rgba(7, 6, 10, 0.6);
  border: 1px solid var(--line-strong);
  color: var(--ink);
  border-radius: 2px;
  padding: 0.15em 0.9em 0.25em;
  cursor: pointer;
}

.lang:hover {
  border-color: var(--bone);
}

/* The hero: a night sky, a cold moon, fog, and a gothic city. */

.hero {
  position: relative;
  min-height: min(92vh, 900px);
  display: grid;
  place-items: center;
  text-align: center;
  /* The text stays above the city. */
  padding: 104px 16px calc(clamp(150px, 22vw, 320px) + 24px);
  overflow: hidden;
  isolation: isolate;
}

.sky {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse at 50% 100%, rgba(125, 20, 20, 0.32), transparent 45%),
    linear-gradient(#08070c 0%, #0f0d16 55%, #1b1219 100%);
}

.moon {
  position: absolute;
  top: 12%;
  right: 14%;
  width: clamp(70px, 11vw, 132px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 38% 36%, #f1eee6, #c9c4b8 58%, #a8a297 100%);
  box-shadow: 0 0 40px 10px rgba(220, 222, 235, 0.16), 0 0 140px 60px rgba(160, 170, 200, 0.08);
  opacity: 0.92;
}

.fog {
  position: absolute;
  left: -20%;
  right: -20%;
  pointer-events: none;
}

.fog-1 {
  bottom: 18%;
  height: 32%;
  background: radial-gradient(ellipse at 30% 60%, rgba(180, 186, 205, 0.1), transparent 60%),
    radial-gradient(ellipse at 75% 50%, rgba(180, 186, 205, 0.08), transparent 55%);
  animation: drift 38s ease-in-out infinite alternate;
}

.fog-2 {
  bottom: -8%;
  height: 22%;
  background: radial-gradient(ellipse at 55% 40%, rgba(170, 176, 196, 0.08), transparent 62%),
    radial-gradient(ellipse at 15% 70%, rgba(170, 176, 196, 0.06), transparent 55%);
  animation: drift 46s ease-in-out infinite alternate-reverse;
}

@keyframes drift {
  from {
    transform: translateX(-4%);
  }
  to {
    transform: translateX(4%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .fog {
    animation: none;
  }
}

.city {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: clamp(150px, 22vw, 320px);
}

.silhouette {
  fill: #040306;
}

@media (max-width: 600px) {
  .moon {
    top: 7%;
    right: 8%;
    width: 58px;
  }
}

.windows {
  fill: #b5462a;
  opacity: 0.55;
  filter: drop-shadow(0 0 4px rgba(200, 80, 40, 0.8));
}

.hero-text {
  position: relative;
  max-width: 760px;
}

.kicker {
  margin: 0 0 6px;
  color: var(--muted);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  font-size: 0.85rem;
  font-weight: 600;
}

h1 {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(4rem, 17vw, 9rem);
  line-height: 0.95;
  letter-spacing: 0.01em;
  color: var(--bone);
  text-shadow: 0 0 2px rgba(0, 0, 0, 0.9), 0 4px 0 #2a0606, 0 0 50px rgba(179, 38, 30, 0.35);
}

.tagline {
  margin: 18px auto 32px;
  max-width: 36ch;
  font-size: clamp(1.25rem, 3.8vw, 1.6rem);
  font-style: italic;
  color: var(--ink);
}

.cta {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.button {
  display: inline-block;
  text-decoration: none;
  border-radius: 2px;
  padding: 0.62em 1.8em 0.72em;
  font-family: var(--text);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.primary {
  background: linear-gradient(#8a1717, #560c0c);
  color: var(--bone);
  border: 1px solid #b4473f;
  box-shadow: inset 0 1px 0 rgba(255, 200, 190, 0.18), 0 10px 30px rgba(0, 0, 0, 0.65);
}

.primary:hover,
.primary:focus-visible {
  background: linear-gradient(#a01d1d, #650e0e);
  outline: none;
}

.small {
  margin: 22px auto 0;
  max-width: 48ch;
  color: var(--muted);
  font-size: 0.95rem;
  font-style: italic;
}

.rule {
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: 520px;
  margin: 8px auto 0;
  padding: 0 16px;
  color: var(--blood-bright);
  font-size: 0.8rem;
}

.rule::before,
.rule::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line-strong), transparent);
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: 18px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 16px 72px;
}

.features article {
  background: linear-gradient(var(--bg-2), var(--bg));
  border: 1px solid var(--line);
  border-top-color: var(--line-strong);
  border-radius: 2px;
  padding: 22px 22px 24px;
}

.features h2 {
  margin: 0 0 8px;
  font-family: var(--text);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--bone);
}

.features p {
  margin: 0;
  color: var(--muted);
}

footer {
  border-top: 1px solid var(--line);
  padding: 20px 16px max(20px, env(safe-area-inset-bottom));
  text-align: center;
  color: var(--muted);
  font-size: 0.95rem;
}

.ghost {
  color: var(--bone);
  border: 1px solid var(--line-strong);
  background: rgba(7, 6, 10, 0.55);
}

.ghost:hover,
.ghost:focus-visible {
  border-color: #b4473f;
  outline: none;
}

/* The choice of the build (docs/code/builds.md) */

.builds {
  max-width: 1100px;
  margin: 0 auto;
  padding: 36px 16px 28px;
  text-align: center;
  scroll-margin-top: 12px;
}

.builds h2 {
  margin: 0 0 8px;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.2rem, 7vw, 3.2rem);
  line-height: 1;
  color: var(--bone);
}

.builds-intro {
  margin: 0 auto 24px;
  max-width: 52ch;
  color: var(--muted);
  font-style: italic;
  font-size: 1.1rem;
}

.build-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr));
  gap: 18px;
  text-align: left;
}

.build {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px 22px 18px;
  text-decoration: none;
  color: var(--ink);
  background: linear-gradient(var(--bg-2), var(--bg));
  border: 1px solid var(--line);
  border-top-color: var(--line-strong);
  border-radius: 2px;
  transition: border-color 0.2s, transform 0.2s;
}

.build:hover,
.build:focus-visible {
  border-color: #b4473f;
  outline: none;
  transform: translateY(-2px);
}

.build.main {
  border-color: rgba(180, 71, 63, 0.65);
  box-shadow: inset 0 0 48px rgba(125, 20, 20, 0.2);
}

.build-kind {
  color: var(--blood-bright);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.build-name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 2rem;
  line-height: 1.05;
  color: var(--bone);
  overflow-wrap: anywhere;
}

.build-text {
  color: var(--muted);
}

.build-release {
  margin-top: auto;
  padding-top: 8px;
  min-height: 1.6em;
  color: var(--silver);
  font-size: 0.9rem;
  font-style: italic;
}

.build.offline {
  opacity: 0.5;
  cursor: default;
}

.build.offline:hover {
  border-color: var(--line);
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .build,
  .build:hover,
  .build:focus-visible {
    transition: none;
    transform: none;
  }
}
