/* =========================================================================
   DIE RABEN ODINS — Design-System „Das Siegel"
   Farben, Typografie, Seitenrahmen (Header/Footer), Grundbausteine.

   Leitbild: eine gravierte Tafel bei Nacht. Tiefes Schwarz, Knochenweiß,
   ein einziges Messing-Gold — direkt aus dem Wappen. Kanten sind scharf,
   Linien haarfein, Runen sind das einzige Ornament. Keine Effekt-Stapel:
   was leuchtet, leuchtet mit Absicht.
   ========================================================================= */

:root {
  /* Grund & Flächen */
  --ground: #0a0a0c;
  --ground-2: #0d0d10;
  --surface: #121216;
  --surface-2: #17171c;
  --surface-3: #1e1e24;
  --wood: #2b2118;

  /* Linien — haarfein, wie in Stein geritzt */
  --line: #232329;
  --line-strong: #35353d;

  /* Schrift */
  --ink: #e8e3d5;
  --ink-muted: #a49f92;
  --ink-dim: #6f6e68;

  /* Der eine Akzent: Messing aus dem Wappen */
  --bronze: #9a7b40;
  --bronze-soft: #bb9a58;
  --gold: #c9a24f;
  --gold-bright: #e9d093;
  --gold-dim: #8a713a;

  /* Nebenfarben — nur für Status & vereinzelte Inhalte */
  --ember: #c06a32;
  --ember-hot: #e0995f;
  --blood: #8b3a34;
  --steel: #8a8f98;
  --frost: #7f97a8;
  --ice: #a9c2d2;

  /* Lichter — bewusst schwach */
  --glow-gold: rgb(201 162 79 / 18%);
  --glow-ember: rgb(192 106 50 / 16%);

  /* Messingverlauf — nur noch für große Zahlen, ruhig statt glänzend */
  --forge: linear-gradient(180deg, #e9d093 0%, #c9a24f 58%, #a8843f 100%);
  --forge-btn: linear-gradient(180deg, #d8b872, #c9a24f);
  --forge-hot: linear-gradient(180deg, #e9d093, #d8b872);

  /* Status */
  --ok: #6aa877;
  --warn: #cfa14a;
  --off: #6a6f78;

  /* Maße — Kanten scharf wie graviert */
  --shell: 1180px;
  --gutter: 28px;
  --radius: 0px;
  --radius-lg: 0px;

  /* Schriften */
  --font-display: 'Cinzel', 'Trajan Pro', Georgia, serif;
  --font-body: 'Public Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'SFMono-Regular', Consolas, monospace;
  --font-rune: 'Noto Sans Runic', 'Segoe UI Historic', 'Segoe UI Symbol', var(--font-display);

  /* Schatten — flach, nur Tiefe, kein Leuchten */
  --shadow-card: 0 18px 40px -32px rgb(0 0 0 / 85%);
  --shadow-raised: 0 30px 60px -36px rgb(0 0 0 / 92%);
  --shadow-glow: 0 0 40px -18px var(--glow-gold);
}

/* ---------------------------------------------------------------- Reset */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

#site-header,
#site-footer,
main { position: relative; z-index: 2; }

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

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: 0.015em;
  text-wrap: balance;
  margin: 0;
}

p { margin: 0; }

::selection { background: var(--gold); color: #0b0906; }

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

/* Skiplink für Tastatur & Screenreader */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  padding: 12px 20px;
  background: var(--gold);
  color: #10130f;
  font-weight: 700;
}
.skip-link:focus { left: 12px; top: 12px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Messing-Schrift — nur für große Display-Zahlen, nie für Fließtext. */
.forged {
  background: var(--forge);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* --------------------------------------------------------------- Layout */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section { padding: 112px 0; position: relative; }
.section--tight { padding: 72px 0; }

/* Abgesetzte Abschnitte: nur ein Hauch heller, von Haarlinien gefasst. */
.section--alt {
  background: var(--ground-2);
  border-block: 1px solid var(--line);
}

/* ---------------------------------------------------- Kapitel-Überschrift */

.section__head { max-width: 720px; margin-bottom: 56px; position: relative; }
.section__head--center { margin-inline: auto; text-align: center; }

/* Die Kapitelmarke: Runenkreuz, Wort, auslaufende Linie. */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 22px;
}
.eyebrow::before {
  content: '᛭';
  font-family: var(--font-rune);
  font-size: 0.85rem;
  letter-spacing: 0;
  color: var(--gold-dim);
}
.eyebrow::after {
  content: '';
  flex: 1;
  max-width: 120px;
  height: 1px;
  background: linear-gradient(90deg, var(--line-strong), transparent);
}
.section__head--center .eyebrow { justify-content: center; }
.section__head--center .eyebrow::after { display: none; }

/* Die Linie der Kapitelmarke ritzt sich ein, sobald der Abschnitt erscheint. */
.js .reveal .eyebrow::after {
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.25s;
}
.js .reveal.is-visible .eyebrow::after { transform: scaleX(1); }

.section__head h2 {
  font-size: clamp(1.9rem, 3.8vw, 2.8rem);
  color: var(--ink);
}
.section__head h2 em {
  font-style: normal;
  color: var(--gold);
}

.lede {
  margin-top: 18px;
  color: var(--ink-muted);
  font-size: 1.05rem;
  line-height: 1.75;
  max-width: 62ch;
}
.section__head--center .lede { margin-inline: auto; }

.grid { display: grid; gap: 22px; }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(276px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }

/* -------------------------------------------------------------- Buttons */

.btn {
  --btn-bg: transparent;
  --btn-border: var(--line-strong);
  --btn-ink: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 28px;
  border: 1px solid var(--btn-border);
  background: var(--btn-bg);
  color: var(--btn-ink);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}
.btn svg { width: 16px; height: 16px; flex: 0 0 auto; }

.btn--primary {
  --btn-bg: var(--gold);
  --btn-border: var(--gold);
  --btn-ink: #131007;
  font-weight: 600;
}
.btn--primary:hover {
  --btn-bg: var(--gold-bright);
  --btn-border: var(--gold-bright);
}

.btn--ghost {
  --btn-bg: transparent;
  --btn-border: color-mix(in srgb, var(--gold) 45%, transparent);
  --btn-ink: var(--ink);
}
.btn--ghost:hover {
  --btn-border: var(--gold);
  --btn-ink: var(--gold-bright);
}

.btn--quiet { --btn-border: var(--line); --btn-ink: var(--ink-muted); }
.btn--quiet:hover { --btn-border: var(--line-strong); --btn-ink: var(--ink); }

.btn--sm { padding: 11px 18px; font-size: 0.68rem; }
.btn--wide { width: 100%; }

.btn[aria-disabled='true'],
.btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------------------------------------------------------------- Cards */

.card {
  position: relative;
  padding: 30px 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  transition: border-color 0.25s ease, background 0.25s ease;
  overflow: hidden;
}

/* Eine einzige goldene Haarlinie am oberen Rand — erscheint beim Überfahren. */
.card::after {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, var(--gold), transparent 70%);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.card:hover {
  border-color: var(--line-strong);
  background: var(--surface-2);
}
.card:hover::after { opacity: 1; }

.card h3 {
  font-size: 1.16rem;
  margin-bottom: 10px;
}
.card p { color: var(--ink-muted); font-size: 0.94rem; }

.card__rune {
  font-family: var(--font-rune);
  font-size: 1.5rem;
  color: var(--gold);
  line-height: 1;
  margin-bottom: 16px;
}

.card__icon {
  width: 38px;
  height: 38px;
  margin-bottom: 18px;
  color: var(--gold);
}
.card__icon svg { width: 100%; height: 100%; }

.card--link:hover h3 { color: var(--gold-bright); }

/* Runen-Zierzeichen — eigene Schrift, damit sie auf jedem Gerät erscheinen. */
.card__rune,
.server-card__rune,
.rule-section__rune,
.guide-section__rune,
.usage-rune,
.rune-glyph { font-family: var(--font-rune); }

.tag {
  display: inline-block;
  padding: 4px 12px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink-muted);
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
}
.tag--gold {
  color: var(--gold);
  border-color: color-mix(in srgb, var(--gold) 40%, transparent);
}
.tag-row { display: flex; flex-wrap: wrap; gap: 8px; }

.note {
  position: relative;
  padding: 20px 24px;
  border: 1px solid var(--line);
  border-left: 2px solid var(--gold-dim);
  background: var(--surface);
  color: var(--ink-muted);
  font-size: 0.93rem;
}
.note strong { color: var(--ink); }

.todo-flag {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 8px;
  background: transparent;
  border: 1px solid color-mix(in srgb, var(--blood) 65%, transparent);
  color: #cf8a84;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  vertical-align: middle;
}

/* --------------------------------------------------------- Raben-Divider */

.raven-divider {
  display: flex;
  align-items: center;
  gap: 24px;
  margin: 0 auto;
  max-width: 460px;
  color: var(--gold-dim);
}
.raven-divider::before,
.raven-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line-strong));
}
.raven-divider::after { background: linear-gradient(270deg, transparent, var(--line-strong)); }
.raven-divider svg {
  width: 60px;
  height: 24px;
  opacity: 0.9;
}

/* --------------------------------------------------------------- Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: color-mix(in srgb, var(--ground) 92%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px var(--gutter);
  max-width: var(--shell);
  margin: 0 auto;
}

.brand { display: flex; align-items: center; gap: 14px; flex: 0 0 auto; }
.brand__seal {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  transition: transform 0.5s ease;
}
.brand:hover .brand__seal { transform: rotate(-5deg); }
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name {
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink);
  white-space: nowrap;
}
.brand__sub {
  font-family: var(--font-mono);
  font-size: 0.56rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--gold-dim);
  white-space: nowrap;
}

.nav__links { display: flex; align-items: center; gap: 4px; }
.nav__links a {
  padding: 10px 13px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-muted);
  transition: color 0.2s ease;
  white-space: nowrap;
  text-underline-offset: 9px;
  text-decoration-thickness: 1px;
}
.nav__links a:hover { color: var(--ink); }
.nav__links a[aria-current='page'] {
  color: var(--gold);
  text-decoration: underline;
  text-decoration-color: var(--gold);
}

.nav__actions { display: flex; align-items: center; gap: 10px; }

.nav__toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
}
.nav__toggle:hover { border-color: var(--gold); color: var(--gold); }
.nav__toggle span {
  position: relative;
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  transition: background 0.2s ease;
}
.nav__toggle span::before,
.nav__toggle span::after {
  content: '';
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: currentColor;
  transition: transform 0.24s ease, top 0.24s ease;
}
.nav__toggle span::before { top: -6px; }
.nav__toggle span::after { top: 6px; }
.nav__toggle[aria-expanded='true'] span { background: transparent; }
.nav__toggle[aria-expanded='true'] span::before { top: 0; transform: rotate(45deg); }
.nav__toggle[aria-expanded='true'] span::after { top: 0; transform: rotate(-45deg); }

/* Mobiles Menü */
.nav__panel {
  position: fixed;
  inset: 0;
  z-index: 95;
  display: none;
  flex-direction: column;
  padding: 100px 28px 36px;
  background: color-mix(in srgb, var(--ground) 97%, transparent);
  backdrop-filter: blur(10px);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.nav__panel.is-open { display: flex; }
.nav__panel a {
  padding: 17px 4px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink);
}
.nav__panel a[aria-current='page'] { color: var(--gold); }
.nav__panel .btn { margin-top: 28px; }
body.nav-open { overflow: hidden; }

@media (max-width: 1080px) {
  .nav__links { display: none; }
  .nav__toggle { display: inline-flex; }
  .nav__actions .btn--primary { display: none; }
  .brand__sub { display: none; }
}

/* --------------------------------------------------------------- Footer */

.site-footer {
  position: relative;
  padding: 44px 0 36px;
  background: var(--ground-2);
  border-top: 1px solid var(--line);
}

.footer__grid {
  display: grid;
  grid-template-columns: minmax(240px, 1.4fr) repeat(auto-fit, minmax(150px, 1fr));
  gap: 40px;
  padding: 28px 0 44px;
  border-bottom: 1px solid var(--line);
}
.footer__brand .brand { margin-bottom: 18px; }
.footer__brand p { color: var(--ink-muted); font-size: 0.9rem; max-width: 40ch; }

.footer__col h2 {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--gold-dim);
  margin-bottom: 18px;
}
.footer__col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer__col a { color: var(--ink-muted); font-size: 0.9rem; transition: color 0.2s ease; }
.footer__col a:hover { color: var(--gold); }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 28px;
  align-items: center;
  justify-content: space-between;
  padding-top: 26px;
  color: var(--ink-dim);
  font-size: 0.8rem;
}
.footer__disclaimer { max-width: 64ch; line-height: 1.6; }

/* ------------------------------------------------------- Scroll-Reveal */

/* Nur wenn JavaScript läuft, wird überhaupt etwas versteckt — sonst ist die
   Seite ohne JS trotzdem vollständig lesbar. */
.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ------------------------------------------------------------ Seitenkopf */

.page-head {
  position: relative;
  padding: 96px 0 64px;
  border-bottom: 1px solid var(--line);
  background: var(--ground);
  overflow: hidden;
}

/* Das Wappen wacht über jeder Unterseite — als kaum sichtbares Wasserzeichen. */
.page-head::before {
  content: '';
  position: absolute;
  right: -110px;
  top: 50%;
  transform: translateY(-50%);
  width: 460px;
  height: 460px;
  background: url('../../pic/seal-512.png') center / contain no-repeat;
  opacity: 0.05;
  filter: grayscale(35%);
  pointer-events: none;
}

.page-head .shell { position: relative; z-index: 1; }
.page-head h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  color: var(--ink);
}
.page-head h1::after {
  content: '';
  display: block;
  width: 64px;
  height: 1px;
  margin-top: 26px;
  background: var(--gold);
  transform-origin: left;
  animation: rule-draw 1s cubic-bezier(0.16, 1, 0.3, 1) 0.25s backwards;
}
@keyframes rule-draw { from { transform: scaleX(0); } }
.page-head .lede { font-size: 1.06rem; margin-top: 22px; }
.page-head .eyebrow { margin-bottom: 18px; }

/* Die alten Landschafts-Silhouetten der Seitenköpfe sind Geschichte. */
.page-head__ridge,
.page-head__embers { display: none; }

.breadcrumb {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 26px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.breadcrumb a:hover { color: var(--gold); }

/* ------------------------------------------------------- Reduced Motion */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .js .reveal { opacity: 1; transform: none; }
}

@media (max-width: 860px) {
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 720px) {
  :root { --gutter: 20px; }
  .section { padding: 76px 0; }
  .page-head { padding: 64px 0 48px; }
  .page-head::before { width: 300px; height: 300px; right: -90px; }
  .card { padding: 24px; }
  .footer__grid { grid-template-columns: 1fr; gap: 30px; }
  .footer__bottom { flex-direction: column; align-items: flex-start; }
}
