/* GameGuides – Design. Die Akzentfarbe (--accent) kommt je Spiel aus der Datenbank. */
@property --ang { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@property --p { syntax: "<number>"; inherits: true; initial-value: 0; }
@view-transition { navigation: auto; }

:root {
  --accent: #d8a657;
  --bg: #0a090c;
  --bg-2: #121016;
  --panel: #17141c;
  --panel-2: #1e1a25;
  --line: rgb(255 255 255 / .08);
  --line-2: rgb(255 255 255 / .16);
  --text: #ece6dc;
  --muted: #a39b90;
  --good: #7fc97f;
  --bad: #e06c6c;
  --radius: 14px;
  --side-w: 316px;
  --top-h: 60px;
  --display: "Palatino Linotype", Palatino, "Book Antiqua", "URW Palladio L", Georgia, serif;
  --sans: system-ui, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
  --glow: color-mix(in oklab, var(--accent) 55%, transparent);
  --tint: color-mix(in oklab, var(--accent) 14%, transparent);
  interpolate-size: allow-keywords;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--top-h) + 16px); }
body {
  margin: 0;
  min-height: 100dvh;
  font: 16px/1.6 var(--sans);
  color: var(--text);
  background:
    radial-gradient(1100px 600px at 85% -10%, var(--tint), transparent 60%),
    radial-gradient(800px 500px at 0% 100%, color-mix(in oklab, var(--accent) 7%, transparent), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  overflow-x: hidden;
}
#embers { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 0; opacity: .7; }
a { color: color-mix(in oklab, var(--accent) 75%, white); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.15; text-wrap: balance; margin: 0 0 .5em; letter-spacing: .01em; }
h1 { font-size: clamp(1.9rem, 1.2rem + 2.4vw, 3rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; text-wrap: pretty; }
small, .hint { color: var(--muted); font-size: .82rem; }
kbd { font: 600 .7rem var(--mono); padding: 2px 6px; border: 1px solid var(--line-2); border-radius: 6px; color: var(--muted); white-space: nowrap; }
code { font-family: var(--mono); background: var(--panel-2); padding: 1px 6px; border-radius: 6px; font-size: .9em; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 100; background: var(--panel); padding: 8px 12px; }
[hidden] { display: none !important; }

/* ---------- Kopfzeile ---------- */
.top {
  position: sticky; top: 0; z-index: 40; height: var(--top-h);
  display: flex; align-items: center; gap: 14px; padding: 0 18px;
  background: color-mix(in oklab, var(--bg) 72%, transparent);
  backdrop-filter: blur(16px) saturate(1.4);
  border-bottom: 1px solid var(--line);
  view-transition-name: top;
}
.brand { font: 600 1.35rem var(--display); letter-spacing: .06em; color: var(--text); text-transform: uppercase; }
.brand b { color: var(--accent); text-shadow: 0 0 22px var(--glow); }
.brand:hover { text-decoration: none; }
.searchbtn {
  flex: 1; max-width: 460px; margin-inline: auto; display: flex; align-items: center; gap: 10px;
  height: 38px; padding: 0 12px; border-radius: 999px; cursor: pointer;
  background: var(--panel); border: 1px solid var(--line); color: var(--muted); font: inherit; font-size: .92rem;
  transition: border-color .2s, box-shadow .2s;
}
.searchbtn:hover { border-color: var(--line-2); box-shadow: 0 0 0 4px var(--tint); }
.searchbtn span { flex: 1; text-align: left; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.lang { display: flex; border: 1px solid var(--line); border-radius: 999px; padding: 2px; }
.lang a { padding: 3px 10px; border-radius: 999px; font: 700 .75rem var(--sans); color: var(--muted); }
.lang a[aria-current] { background: var(--accent); color: #14100a; }
.lang a:hover { text-decoration: none; color: var(--text); }
.lang a[aria-current]:hover { color: #14100a; }
.who { display: flex; align-items: center; gap: 10px; }
.who form { margin: 0; }
.avatar {
  display: inline-grid; place-items: center; width: 30px; height: 30px; flex: none; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), color-mix(in oklab, var(--accent) 40%, #201a2a));
  color: #14100a; font: 700 .85rem var(--sans);
}
.iconbtn { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: none; border: 1px solid transparent; color: var(--text); cursor: pointer; }
.iconbtn:hover { background: var(--panel); border-color: var(--line); }
.burger { display: none; }
.link { background: none; border: 0; padding: 0; color: var(--muted); font: inherit; font-size: .85rem; cursor: pointer; }
.link:hover { color: var(--text); text-decoration: underline; }

/* ---------- Knöpfe, Marken ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 18px;
  border-radius: 10px; border: 1px solid transparent; cursor: pointer; font: 600 .92rem var(--sans); color: #14100a;
  background: linear-gradient(180deg, color-mix(in oklab, var(--accent) 88%, white), var(--accent));
  box-shadow: 0 6px 22px -8px var(--glow), inset 0 1px 0 rgb(255 255 255 / .35);
  transition: transform .15s, box-shadow .2s, filter .2s;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); box-shadow: 0 10px 30px -8px var(--glow), inset 0 1px 0 rgb(255 255 255 / .35); filter: brightness(1.06); }
.btn:active { transform: translateY(0); }
.btn-sm { min-height: 32px; padding: 0 12px; font-size: .82rem; border-radius: 8px; }
.btn-lg { min-height: 48px; padding: 0 26px; font-size: 1rem; }
.btn-ghost { background: var(--panel); color: var(--text); border-color: var(--line-2); box-shadow: none; }
.btn-ghost:hover { box-shadow: none; border-color: var(--accent); }
.btn-danger { background: color-mix(in oklab, var(--bad) 22%, var(--panel)); color: #ffd9d9; border-color: color-mix(in oklab, var(--bad) 50%, transparent); box-shadow: none; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.tag, .chip {
  display: inline-flex; align-items: center; padding: 2px 10px; border-radius: 999px; font: 600 .72rem var(--sans);
  letter-spacing: .04em; text-transform: uppercase; color: var(--muted); background: rgb(255 255 255 / .05); border: 1px solid var(--line);
}
.tag-accent { color: color-mix(in oklab, var(--accent) 70%, white); background: var(--tint); border-color: color-mix(in oklab, var(--accent) 35%, transparent); }
.chip { padding: 5px 13px; text-transform: none; letter-spacing: 0; font-size: .85rem; transition: border-color .2s, color .2s; }
.chip:hover { text-decoration: none; color: var(--text); border-color: var(--line-2); }
.chip[aria-current] { color: #14100a; background: var(--accent); border-color: var(--accent); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.row form { display: contents; }

/* ---------- Gerüst ---------- */
.shell { position: relative; z-index: 1; display: flex; align-items: flex-start; }
main { flex: 1; min-width: 0; max-width: 1180px; margin-inline: auto; padding: 28px clamp(16px, 3vw, 40px) 0; view-transition-name: main; }
main > section { margin-bottom: 44px; }
.sec { display: flex; align-items: center; gap: 12px; font-size: 1.3rem; margin: 34px 0 16px; text-transform: uppercase; letter-spacing: .12em; color: color-mix(in oklab, var(--accent) 60%, white); }
.sec::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, color-mix(in oklab, var(--accent) 45%, transparent), transparent); }
.sec .count { font: 600 .8rem var(--sans); color: var(--muted); letter-spacing: 0; }
.foot { margin-top: 70px; padding: 22px 0 30px; border-top: 1px solid var(--line); color: var(--muted); font-size: .85rem; }
.foot p { margin: 0 0 4px; }

/* ---------- Seitenleiste ---------- */
.side {
  position: sticky; top: var(--top-h); flex: none; width: var(--side-w); height: calc(100dvh - var(--top-h));
  display: flex; border-right: 1px solid var(--line);
  background: linear-gradient(180deg, color-mix(in oklab, var(--bg-2) 80%, transparent), color-mix(in oklab, var(--bg) 80%, transparent));
  backdrop-filter: blur(10px);
  view-transition-name: side;
}
.rail { flex: none; width: 64px; padding: 14px 0; display: flex; flex-direction: column; align-items: center; gap: 10px; border-right: 1px solid var(--line); overflow-y: auto; scrollbar-width: none; }
.rail-btn {
  position: relative; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px;
  background: var(--panel); border: 1px solid var(--line); color: var(--muted);
  font: 700 .72rem var(--display); letter-spacing: .04em; transition: border-radius .25s, color .2s, background .25s, box-shadow .25s;
}
.rail-btn:hover { text-decoration: none; color: var(--text); border-radius: 50%; background: var(--tint); }
.rail-btn[aria-current] { color: #14100a; background: var(--accent); border-color: transparent; box-shadow: 0 0 26px -4px var(--glow); }
.rail-btn[aria-current]::before { content: ""; position: absolute; left: -11px; width: 4px; height: 22px; border-radius: 0 4px 4px 0; background: var(--accent); }
.tree { flex: 1; min-width: 0; padding: 14px 10px 30px; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.tree ul { list-style: none; margin: 0; padding: 0; }
.tree ul ul { margin-left: 13px; padding-left: 9px; border-left: 1px solid var(--line); }
.tree summary.tree-game { gap: 10px; padding: 8px 10px; margin-bottom: 2px; font: 600 1rem var(--display); letter-spacing: .07em; text-transform: uppercase; }
.tree summary.tree-game a { color: var(--accent); }
.game-icon { flex: none; width: 26px; height: 26px; border-radius: 50%; object-fit: cover; filter: drop-shadow(0 0 6px var(--glow)); }
.rail-btn:has(img.game-icon) { padding: 0; background: none; border-color: transparent; }
.rail-btn .game-icon { width: 42px; height: 42px; }
span.game-icon { width: auto; height: auto; filter: none; }
.tree a { color: var(--muted); }
.tree a:hover { text-decoration: none; color: var(--text); }
.tree summary, .tree .leaf {
  position: relative; display: flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 9px; font-size: .92rem;
  transition: background .18s, color .18s;
}
.tree summary { list-style: none; cursor: pointer; }
.tree summary::-webkit-details-marker { display: none; }
.tree summary a { flex: 1; min-width: 0; }
.tree summary:hover, .tree .leaf:hover { background: rgb(255 255 255 / .05); }
.tree > ul > li > details > ul > li > details > summary a { color: var(--text); font-weight: 600; }
.chev { width: 7px; height: 7px; flex: none; border: solid var(--muted); border-width: 0 1.5px 1.5px 0; transform: rotate(-45deg); transition: transform .25s; margin-right: 4px; }
details[open] > summary .chev { transform: rotate(45deg); }
.tree details::details-content { block-size: 0; overflow: clip; transition: block-size .28s ease, content-visibility .28s allow-discrete; }
.tree details[open]::details-content { block-size: auto; }
.tree [aria-current="page"] { color: var(--text); }
.tree .leaf[aria-current="page"], .tree summary:has(> [aria-current="page"]) {
  background: linear-gradient(90deg, var(--tint), transparent); color: var(--text);
}
.tree .leaf[aria-current="page"]::before, .tree summary:has(> [aria-current="page"])::before {
  content: ""; position: absolute; left: 0; top: 7px; bottom: 7px; width: 3px; border-radius: 3px; background: var(--accent); box-shadow: 0 0 12px var(--accent);
}
.scrim { position: fixed; inset: 0; z-index: 44; background: rgb(0 0 0 / .6); backdrop-filter: blur(2px); }

/* ---------- Karten ---------- */
.grid { display: grid; gap: 16px; }
.grid-games { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.grid-news { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.grid-builds { grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }
.grid-sections { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.card {
  position: relative; display: block; padding: 20px; border-radius: var(--radius); color: var(--text);
  background: linear-gradient(180deg, color-mix(in oklab, var(--panel-2) 88%, transparent), color-mix(in oklab, var(--panel) 88%, transparent));
  border: 1px solid var(--line); isolation: isolate; overflow: hidden;
  transition: transform .25s cubic-bezier(.2, .7, .2, 1), border-color .25s, box-shadow .25s;
}
.card p { color: var(--muted); font-size: .93rem; margin: 0; }
.card h3 { margin-bottom: .35em; }
a.card:hover { text-decoration: none; transform: translateY(-4px); border-color: transparent; box-shadow: 0 20px 44px -22px var(--glow); }
/* Lichtkegel, der dem Mauszeiger folgt */
.card::before {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity .3s;
  background: radial-gradient(340px circle at var(--mx, 50%) var(--my, 0%), color-mix(in oklab, var(--accent) 22%, transparent), transparent 65%);
}
.card:hover::before { opacity: 1; }
/* umlaufender Leuchtrand */
a.card::after {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; padding: 1px; opacity: 0; transition: opacity .3s;
  background: conic-gradient(from var(--ang), transparent 0 55%, var(--accent) 75%, color-mix(in oklab, var(--accent) 40%, white) 82%, transparent 92%);
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  animation: spin 3.2s linear infinite paused;
}
a.card:hover::after { opacity: 1; animation-play-state: running; }
@keyframes spin { to { --ang: 360deg; } }

.game-card { padding: 26px; min-height: 190px; }
.game-card .glyph {
  position: absolute; right: -8px; top: -22px; z-index: -1; font: 700 6.5rem/1 var(--display); letter-spacing: -.04em;
  color: transparent; -webkit-text-stroke: 1px color-mix(in oklab, var(--accent) 45%, transparent); opacity: .5; transition: transform .5s, opacity .3s;
}
.game-card:hover .glyph { transform: translate(-8px, 8px) scale(1.06); opacity: .9; }
.game-card h3 { font-size: 1.6rem; }
.go { display: inline-block; margin-top: 14px; font: 600 .85rem var(--sans); color: var(--accent); }
.news-card img { width: calc(100% + 40px); margin: -20px -20px 16px; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.news-card small { display: block; margin-top: 12px; }
.section-card h3 a { color: var(--text); }
.section-card ul { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 4px; }
.section-card li a { color: var(--muted); font-size: .93rem; }
.section-card li a::before { content: "› "; color: var(--accent); }
.section-card li a:hover { color: var(--text); }

.score { display: flex; align-items: center; gap: 10px; margin-top: 16px; font: 600 .8rem var(--mono); }
.score-up { color: var(--good); }
.score-down { color: var(--bad); }
.meter { flex: 1; height: 5px; border-radius: 5px; background: color-mix(in oklab, var(--bad) 45%, var(--panel)); overflow: hidden; }
.meter i { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg, color-mix(in oklab, var(--good) 70%, black), var(--good)); transition: width .5s cubic-bezier(.2, .7, .2, 1); }
.meter:has(i[style*="width: 0%"]) { background: var(--line); }

/* ---------- Aufhänger ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden; padding: clamp(34px, 6vw, 80px) clamp(22px, 5vw, 64px);
  border-radius: 24px; border: 1px solid var(--line);
  background: linear-gradient(135deg, color-mix(in oklab, var(--accent) 16%, var(--panel)), var(--bg-2) 60%);
}
.hero::after { /* feines Raster */
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .5;
  background: linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 100% 44px, linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 44px 100%;
  mask: radial-gradient(ellipse at 80% 0%, #000, transparent 70%);
}
.hero-glow {
  position: absolute; z-index: -1; right: -12%; top: -45%; width: 62%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle, var(--glow), transparent 62%); filter: blur(30px); animation: breathe 9s ease-in-out infinite;
}
@keyframes breathe { 50% { transform: translate(-6%, 8%) scale(1.15); opacity: .7; } }
.hero h1 {
  font-size: clamp(2.3rem, 1.2rem + 4.6vw, 4.6rem); max-width: 17ch; margin-bottom: .3em;
  background: linear-gradient(180deg, #fff 20%, color-mix(in oklab, var(--accent) 65%, white)); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.kicker { font: 700 .78rem var(--sans); letter-spacing: .28em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }
.lead { font-size: 1.13rem; color: color-mix(in oklab, var(--text) 82%, transparent); max-width: 62ch; }
.hero .lead { margin-bottom: 26px; }
.hero-game .lead { margin-bottom: 0; }

/* ---------- Text, Listen, Tabellen ---------- */
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; font-size: .85rem; color: var(--muted); }
.crumbs a { color: var(--muted); }
.crumbs [aria-current] { color: var(--text); }
.prose { max-width: 74ch; font-size: 1.04rem; }
.prose h2 { font-size: 1.45rem; margin-top: 1.6em; color: color-mix(in oklab, var(--accent) 55%, white); }
.prose h3 { margin-top: 1.4em; }
.prose ul { padding-left: 1.2em; margin: 0 0 1em; }
.prose li { margin-bottom: .35em; }
.prose li::marker { color: var(--accent); }
.empty, .note { color: var(--muted); }
.empty { padding: 28px; text-align: center; border: 1px dashed var(--line-2); border-radius: var(--radius); }
.note { font-size: .9rem; }
.flash { padding: 12px 16px; border-radius: 10px; border: 1px solid color-mix(in oklab, var(--good) 40%, transparent); background: color-mix(in oklab, var(--good) 12%, var(--panel)); animation: drop .4s ease; }
.flash-warn { border-color: color-mix(in oklab, var(--accent) 50%, transparent); background: color-mix(in oklab, var(--accent) 12%, var(--panel)); }
@keyframes drop { from { opacity: 0; transform: translateY(-8px); } }
.toolbar { display: flex; flex-wrap: wrap; gap: 12px 18px; align-items: center; margin: 6px 0 22px; }
.seg { display: inline-flex; flex-wrap: wrap; padding: 3px; border-radius: 11px; background: var(--panel); border: 1px solid var(--line); }
.seg a { padding: 6px 14px; border-radius: 8px; color: var(--muted); font: 600 .85rem var(--sans); }
.seg a:hover { text-decoration: none; color: var(--text); }
.seg a[aria-current] { background: var(--panel-2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2), 0 0 16px -6px var(--glow); }
.head-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.head-row h1 { margin: 0; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: color-mix(in oklab, var(--panel) 85%, transparent); margin-bottom: 20px; }
table.items { width: 100%; border-collapse: collapse; font-size: .93rem; }
.items th, .items td { padding: 10px 16px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.items thead th { font: 600 .72rem var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); background: rgb(255 255 255 / .03); white-space: nowrap; }
.items tbody tr:last-child > * { border-bottom: 0; }
.items tbody tr { transition: background .15s; }
.items tbody tr:hover { background: var(--tint); }
.items tbody th { font-weight: 600; color: color-mix(in oklab, var(--accent) 55%, white); }
.items tbody th small { display: block; font-weight: 400; }
.rune { display: inline-block; margin: 0 4px 4px 0; padding: 1px 8px; border-radius: 6px; font: 600 .8rem var(--mono); background: var(--panel-2); border: 1px solid var(--line-2); color: var(--text); }

/* ---------- Formulare ---------- */
label { display: grid; gap: 6px; font: 600 .85rem var(--sans); color: var(--muted); }
input:not([type="checkbox"], [type="color"]), textarea, select {
  width: 100%; padding: 10px 12px; border-radius: 10px; font: 400 1rem var(--sans); color: var(--text);
  background: var(--bg-2); border: 1px solid var(--line-2); transition: border-color .2s, box-shadow .2s;
}
textarea { resize: vertical; line-height: 1.5; }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--tint); }
.check { display: flex; align-items: center; gap: 10px; font-weight: 400; color: var(--text); }
.check input { width: 18px; height: 18px; accent-color: var(--accent); flex: none; }
.hp { position: absolute; left: -9999px; }
.filter { display: block; max-width: 420px; margin-bottom: 20px; }
.compose { display: grid; gap: 14px; max-width: 760px; margin-top: 22px; }
.compose .btn { justify-self: start; }
.auth { max-width: 440px; margin: 5vh auto 0; padding: 32px; }
.auth form { display: grid; gap: 16px; margin: 18px 0; }
.auth .note { margin: 0; }
.admin-tabs { margin-bottom: 8px; }
.admin-form { max-width: none; }
.admin-form .cols { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); align-items: start; }
.admin-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; padding: 14px 18px; }
.admin-row > div:first-child { flex: 1; min-width: 240px; }
.admin-row small { display: block; margin-top: 4px; overflow-wrap: anywhere; }

/* ---------- Build-Seite, Kommentare, Forum ---------- */
.build-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 20px; margin-bottom: 18px; }
.build-head h1 { margin-bottom: .2em; }
.meta { color: var(--muted); font-size: .9rem; margin: 0; }
.vote { display: grid; grid-template-columns: auto auto; gap: 10px; padding: 14px; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); }
.vote-info { grid-column: 1 / -1; display: grid; gap: 6px; }
.thumb {
  display: flex; align-items: center; gap: 8px; min-width: 92px; min-height: 46px; padding: 0 14px; border-radius: 11px; cursor: pointer;
  background: var(--bg-2); border: 1px solid var(--line-2); color: var(--muted); font: 700 1rem var(--mono); transition: all .2s;
}
.thumb:hover { color: var(--text); transform: translateY(-2px); }
.thumb-up:hover, .thumb-up[aria-pressed="true"] { color: var(--good); border-color: var(--good); box-shadow: 0 0 22px -8px var(--good); }
.thumb-down:hover, .thumb-down[aria-pressed="true"] { color: var(--bad); border-color: var(--bad); box-shadow: 0 0 22px -8px var(--bad); }
.thumb[aria-pressed="true"] svg { fill: currentColor; fill-opacity: .25; }
.thumb.pop svg { animation: pop .45s cubic-bezier(.3, 1.8, .5, 1); }
@keyframes pop { 40% { transform: scale(1.5) rotate(-12deg); } }
.source { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin: 26px 0; padding: 14px 18px; border-radius: var(--radius); border: 1px solid color-mix(in oklab, var(--accent) 30%, transparent); background: var(--tint); }
.comments { max-width: 800px; }
.post { padding: 16px 18px; margin-bottom: 10px; border-radius: var(--radius); background: color-mix(in oklab, var(--panel) 85%, transparent); border: 1px solid var(--line); }
.post:target { border-color: var(--accent); box-shadow: 0 0 0 4px var(--tint); }
.post header { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.post time { color: var(--muted); font-size: .82rem; }
.post .report { margin-left: auto; opacity: 0; transition: opacity .2s; }
.post:hover .report, .post .report:focus-visible { opacity: 1; }
.post .prose { font-size: 1rem; }
.post .prose > :last-child { margin-bottom: 0; }
.threads { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.threads a { display: flex; align-items: center; gap: 14px; padding: 14px 18px; border-radius: var(--radius); color: var(--text); background: color-mix(in oklab, var(--panel) 85%, transparent); border: 1px solid var(--line); transition: border-color .2s, transform .2s, background .2s; }
.threads a:hover { text-decoration: none; border-color: color-mix(in oklab, var(--accent) 50%, transparent); transform: translateX(4px); background: var(--panel-2); }
.th-main { flex: 1; min-width: 0; display: grid; }
.th-main b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.th-stat { display: grid; text-align: right; min-width: 74px; font-size: .9rem; }
.results { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; max-width: 760px; }
.results a { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-radius: 11px; color: var(--text); border: 1px solid var(--line); background: var(--panel); }
.results a:hover { text-decoration: none; border-color: var(--accent); }
.results small { margin-left: auto; }
.errpage { text-align: center; padding: 8vh 0; }
.errcode { font: 700 clamp(6rem, 22vw, 14rem)/1 var(--display); margin: 0; color: transparent; -webkit-text-stroke: 2px color-mix(in oklab, var(--accent) 60%, transparent); filter: drop-shadow(0 0 30px var(--glow)); }

/* ---------- Rechner ---------- */
.calc-bar { position: sticky; top: calc(var(--top-h) + 8px); z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 26px; padding: 12px 18px; margin-bottom: 18px; border-radius: var(--radius); background: color-mix(in oklab, var(--panel) 85%, transparent); backdrop-filter: blur(12px); border: 1px solid var(--line); }
.stat { display: grid; }
.stat b { font: 700 1.6rem/1.1 var(--mono); color: var(--accent); font-variant-numeric: tabular-nums; }
.spacer { flex: 1; }
.trees { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); }
.tree-tab { padding: 16px; border-radius: var(--radius); border: 1px solid var(--line); background: linear-gradient(180deg, color-mix(in oklab, var(--panel-2) 85%, transparent), color-mix(in oklab, var(--bg-2) 85%, transparent)); }
.tree-tab h3 { display: flex; justify-content: space-between; font-size: 1.05rem; letter-spacing: .1em; text-transform: uppercase; }
.tree-tab h3 span { font: 700 .9rem var(--mono); color: var(--accent); }
.tree-grid { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 78px; gap: 10px; }
.skill {
  position: relative; display: grid; place-items: center; align-content: center; gap: 2px; padding: 4px; border-radius: 12px; cursor: pointer; user-select: none;
  background: var(--bg-2); border: 1px solid var(--line-2); color: var(--muted); font: 600 .7rem/1.2 var(--sans); text-align: center; overflow-wrap: anywhere; hyphens: auto;
  transition: transform .15s, border-color .2s, box-shadow .2s, color .2s, opacity .2s;
}
.skill:hover { transform: scale(1.05); color: var(--text); z-index: 2; }
.skill b { font: 700 .95rem var(--mono); color: var(--text); }
.skill.on { color: var(--text); border-color: var(--accent); background: linear-gradient(180deg, var(--tint), var(--bg-2)); box-shadow: 0 0 20px -8px var(--accent), inset 0 0 14px -8px var(--accent); }
.skill.on b { color: var(--accent); }
.skill.max { box-shadow: 0 0 26px -6px var(--accent), inset 0 0 0 1px var(--accent); }
.skill.locked { opacity: .45; }
.skill.hl { border-color: color-mix(in oklab, var(--accent) 60%, white); border-style: dashed; opacity: 1; }
.skill.bump b { animation: pop .3s; }
.blockcalc { display: grid; gap: 26px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); max-width: 820px; margin-bottom: 14px; }
.calc-form { display: grid; gap: 14px; }
.calc-out { display: grid; justify-items: center; align-content: center; gap: 14px; text-align: center; }
.dial {
  --size: 190px; width: var(--size); aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; align-content: center;
  background: radial-gradient(closest-side, var(--panel) 80%, transparent 81%), conic-gradient(var(--accent) calc(var(--p) * 1%), var(--line) 0);
  box-shadow: 0 0 46px -16px var(--glow); transition: --p .6s cubic-bezier(.2, .7, .2, 1);
}
.dial b { font: 700 2.3rem var(--mono); }
.dial.full b { color: var(--good); }

/* ---------- Suche, Dialoge, Hinweise ---------- */
#palette { width: min(640px, calc(100vw - 24px)); margin: 12vh auto auto; padding: 0; border-radius: 18px; color: var(--text); background: color-mix(in oklab, var(--panel) 92%, transparent); backdrop-filter: blur(24px); border: 1px solid var(--line-2); box-shadow: 0 40px 100px -20px #000, 0 0 60px -30px var(--glow); }
#palette::backdrop, dialog::backdrop { background: rgb(0 0 0 / .6); backdrop-filter: blur(4px); }
#palette, dialog { opacity: 0; transform: translateY(-10px) scale(.98); transition: opacity .2s, transform .2s, overlay .2s allow-discrete, display .2s allow-discrete; }
#palette:popover-open, dialog[open] { opacity: 1; transform: none; }
@starting-style { #palette:popover-open, dialog[open] { opacity: 0; transform: translateY(-10px) scale(.98); } }
.palette-in { display: flex; grid-template-columns: none; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); color: var(--muted); }
.palette-in input { border: 0; background: none; padding: 0; font-size: 1.1rem; box-shadow: none !important; }
.palette-out { list-style: none; margin: 0; padding: 8px; max-height: 52vh; overflow-y: auto; }
.palette-out:empty { display: none; }
.palette-out a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; color: var(--text); }
.palette-out a:hover, .palette-out a.sel { background: var(--tint); text-decoration: none; }
.palette-out small { margin-left: auto; }
.palette-out .none { padding: 16px; text-align: center; color: var(--muted); }
dialog { width: min(480px, calc(100vw - 24px)); padding: 24px; border-radius: 18px; color: var(--text); background: var(--panel); border: 1px solid var(--line-2); }
dialog form { display: grid; gap: 14px; }
dialog h2 { margin: 0; font-size: 1.3rem; }
dialog .row { justify-content: flex-end; }
.consent { position: fixed; z-index: 60; left: 16px; right: 16px; bottom: 16px; max-width: 620px; margin-inline: auto; padding: 18px 20px; border-radius: 16px; background: color-mix(in oklab, var(--panel) 94%, transparent); backdrop-filter: blur(18px); border: 1px solid var(--line-2); box-shadow: 0 20px 60px -10px #000; animation: drop .5s ease .4s backwards; }
.consent p { font-size: .9rem; }
.consent .row { justify-content: flex-end; }

/* ---------- Werbeflächen ---------- */
.ad { position: relative; }
.ad > small { display: block; font-size: .65rem; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 6px; }
.ad-rail { position: sticky; top: calc(var(--top-h) + 20px); flex: none; width: 160px; margin: 28px 16px 0; display: none; }
.ad-inline { margin: 34px 0 0; padding: 14px; border: 1px dashed var(--line); border-radius: var(--radius); text-align: center; }
.ad-pop { inset: auto 20px 20px auto; margin: 0; max-width: min(360px, calc(100vw - 40px)); padding: 16px; border-radius: 16px; color: var(--text); background: var(--panel); border: 1px solid var(--line-2); box-shadow: 0 20px 60px -10px #000; }
.ad-pop .iconbtn { position: absolute; top: 6px; right: 6px; width: 30px; height: 30px; }
@media (min-width: 1500px) { .ad-right { display: block; } }
@media (min-width: 1760px) { .ad-left { display: block; } }

/* ---------- Bewegung beim Scrollen ---------- */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .reveal { animation: rise linear both; animation-timeline: view(); animation-range: entry 0% entry 55%; }
    @keyframes rise { from { opacity: 0; transform: translateY(26px) scale(.97); } }
  }
}
::view-transition-old(main) { animation: .18s ease both vt-out; }
::view-transition-new(main) { animation: .3s cubic-bezier(.2, .7, .2, 1) both vt-in; }
@keyframes vt-out { to { opacity: 0; transform: translateY(-8px); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(14px); } }

/* ---------- Kleine Bildschirme ---------- */
@media (max-width: 980px) {
  .burger { display: inline-grid; }
  .side { position: fixed; left: 0; top: 0; z-index: 45; height: 100dvh; width: min(var(--side-w), 88vw); transform: translateX(-102%); transition: transform .3s cubic-bezier(.2, .7, .2, 1); background: var(--bg-2); }
  .side.open { transform: none; box-shadow: 30px 0 80px #000; }
  .searchbtn kbd, .who-name { display: none; }
  main { padding-top: 20px; }
  .th-last { display: none; }
}
@media (max-width: 560px) {
  .top { gap: 8px; padding: 0 10px; }
  .brand { font-size: 1.05rem; }
  .searchbtn { flex: none; width: 38px; padding: 0; justify-content: center; margin-left: auto; }
  .searchbtn span { display: none; }
  .tree-grid { grid-auto-rows: 70px; gap: 7px; }
  .vote { width: 100%; grid-template-columns: 1fr 1fr; }
  .thumb { justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  #embers { display: none; }
  @view-transition { navigation: none; }
}

/* ---------- Item-Karten (Uniques usw.) ---------- */
.itemlist .toolbar { margin-bottom: 12px; }
.itemlist .toolbar input { flex: 1; min-width: 220px; max-width: 420px; }
.itemlist .chips { margin-bottom: 10px; }
.itemlist .count { color: var(--muted); font-size: .85rem; margin-left: auto; }
button.chip { cursor: pointer; font-family: var(--sans); }
.chip small { margin-left: 6px; opacity: .7; }
.chip[aria-pressed="true"] { color: #14100a; background: var(--accent); border-color: var(--accent); }
.grid-items { grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); align-items: start; margin-top: 18px; }
.item-card { padding: 16px 18px; content-visibility: auto; contain-intrinsic-size: auto 320px; }
.item-card:target { border-color: var(--accent); box-shadow: 0 0 0 4px var(--tint); }
.item-card header { display: flex; gap: 14px; margin-bottom: 10px; }
.item-card h3 { color: #c7b377; font-size: 1.15rem; margin-bottom: 2px; }
.item-img { flex: none; width: 60px; min-height: 84px; display: grid; place-items: center; border-radius: 10px; background: radial-gradient(circle at 50% 40%, var(--tint), transparent 70%), var(--bg-2); border: 1px solid var(--line); }
.item-img img { max-width: 56px; max-height: 84px; image-rendering: pixelated; }
.reqs { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; }
.reqs span { padding: 1px 8px; border-radius: 7px; font-size: .75rem; color: var(--muted); background: rgb(255 255 255 / .05); border: 1px solid var(--line); }
.reqs b { color: var(--text); font-family: var(--mono); }
.card .item-info { font-size: .85rem; margin: 0 0 3px; }
.was { opacity: .6; }
.itemlist.no-old .was, .itemlist.no-old .old { display: none; }
.mods { list-style: none; margin: 10px 0 0; padding: 0; font-size: .9rem; line-height: 1.5; }
.mods li { padding: 3px 0 3px 11px; border-left: 2px solid transparent; color: #8f9be8; }
.mods b { color: #fff; font-weight: 600; }
.mods .m-chg { border-left-color: var(--accent); }
.mods .m-new { border-left-color: var(--good); }
.mods .m-del { border-left-color: var(--bad); color: var(--muted); }
.mods em { font-style: normal; margin-left: 4px; padding: 0 7px; border-radius: 6px; font-size: .7rem; text-transform: uppercase; letter-spacing: .05em; }
.mods .m-new em { color: var(--good); background: color-mix(in oklab, var(--good) 15%, transparent); }
.mods .m-del em { color: var(--bad); background: color-mix(in oklab, var(--bad) 15%, transparent); }
.mods .old { display: block; font-size: .76rem; color: var(--muted); }
.item-base { margin-top: 10px; font-size: .85rem; }
.item-base summary { cursor: pointer; color: var(--muted); }
.item-base summary:hover { color: var(--text); }
.item-base p { margin-top: 4px; }
.group-select { max-width: 420px; margin-bottom: 10px; }
.item-card.is-bonus { border-style: dashed; border-color: color-mix(in oklab, var(--good) 45%, transparent); }
.item-card.is-bonus h3 { color: var(--good); }
.item-card .rune { margin: 0; }
.item-card h3 small { display: block; font: 400 .8rem var(--sans); color: var(--muted); letter-spacing: 0; margin-top: 2px; }

/* ---------- Guide-Texte: nummerierte Schritte, Hinweiskasten, Tabellen ---------- */
.prose ol { list-style: none; counter-reset: step; padding: 0; margin: 0 0 1.2em; display: grid; gap: 10px; }
.prose ol li { counter-increment: step; position: relative; margin: 0; padding: 12px 16px 12px 58px; border-radius: 12px; background: color-mix(in oklab, var(--panel) 85%, transparent); border: 1px solid var(--line); }
.prose ol li::before { content: counter(step); position: absolute; left: 14px; top: 11px; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; font: 700 .9rem var(--mono); color: #14100a; background: var(--accent); box-shadow: 0 0 18px -6px var(--accent); }
.prose ol li strong:first-child { color: var(--text); }
.prose strong { color: color-mix(in oklab, var(--accent) 35%, white); }
.callout { position: relative; margin: 1.4em 0; padding: 14px 18px 14px 20px; border-radius: 12px; border: 1px solid color-mix(in oklab, var(--accent) 40%, transparent); background: var(--tint); }
.callout::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 4px; border-radius: 4px; background: var(--accent); box-shadow: 0 0 12px var(--accent); }
.prose .table-wrap { margin: 1em 0 1.4em; }
.prose table.items td:first-child { font-weight: 600; color: color-mix(in oklab, var(--accent) 55%, white); white-space: nowrap; }
.prose code { overflow-wrap: anywhere; }
@media (max-width: 560px) { .prose table.items td:first-child { white-space: normal; } }

/* ---------- Build-Datenblatt ---------- */
.sheet { max-width: 860px; }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin-bottom: 1em; }
.fact { display: grid; gap: 2px; padding: 12px 14px; border-radius: 12px; background: color-mix(in oklab, var(--panel) 85%, transparent); border: 1px solid var(--line); }
.fact b { font: 700 1.25rem var(--mono); color: var(--accent); }
.proscons { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.prose .proscons ul { list-style: none; margin: 0; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line); background: color-mix(in oklab, var(--panel) 85%, transparent); }
.proscons li { position: relative; padding-left: 24px; }
.proscons li::before { position: absolute; left: 0; font-weight: 700; }
.proscons .pros { border-color: color-mix(in oklab, var(--good) 35%, transparent); }
.proscons .pros li::before { content: "+"; color: var(--good); }
.proscons .cons { border-color: color-mix(in oklab, var(--bad) 35%, transparent); }
.proscons .cons li::before { content: "−"; color: var(--bad); }
.gear { display: grid; grid-template-columns: minmax(110px, max-content) 1fr; gap: 0; margin: 0 0 1em; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.gear dt, .gear dd { margin: 0; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.gear dt { font: 600 .78rem var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: rgb(255 255 255 / .03); }
.gear dt:last-of-type, .gear dd:last-of-type { border-bottom: 0; }
.gear dd { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.gear dd span + span::before { content: "›"; margin-right: 16px; color: var(--muted); }
.item-ref { color: #c7b377; font-weight: 600; }
a.item-ref { text-decoration: underline dotted; text-underline-offset: 3px; }
a.item-ref:hover { color: #fff; }

/* ---------- Runen ---------- */
.runes { display: grid; grid-template-columns: repeat(auto-fill, minmax(116px, 1fr)); gap: 12px; margin-bottom: 20px; }
.rune-tile { position: relative; display: grid; justify-items: center; gap: 2px; padding: 14px 8px 12px; border-radius: var(--radius); cursor: help; text-align: center; background: linear-gradient(180deg, color-mix(in oklab, var(--panel-2) 88%, transparent), color-mix(in oklab, var(--panel) 88%, transparent)); border: 1px solid var(--line); transition: transform .2s, border-color .2s, box-shadow .2s; }
.rune-tile:hover, .rune-tile:focus-visible, .rune-tile:focus-within { z-index: 20; transform: translateY(-3px); border-color: #c98b3c; box-shadow: 0 14px 34px -18px #c98b3c; outline: none; }
.rune-tile:target { border-color: var(--accent); }
.rune-img { width: 56px; height: 56px; display: grid; place-items: center; }
.rune-img img { image-rendering: pixelated; filter: drop-shadow(0 0 8px rgb(201 139 60 / .55)); transition: transform .25s; }
.rune-tile:hover .rune-img img { transform: scale(1.15); }
.rune-tile > b { font: 600 1.05rem var(--display); color: #e0a34f; letter-spacing: .04em; }
.rune-tip { position: absolute; top: calc(100% + 8px); left: 0; z-index: 30; width: min(320px, calc(100vw - 32px)); padding: 14px 16px; text-align: left; cursor: auto; border-radius: 12px; background: color-mix(in oklab, var(--bg-2) 96%, transparent); backdrop-filter: blur(14px); border: 1px solid #c98b3c; box-shadow: 0 24px 60px -12px #000; opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .15s, transform .15s, visibility .15s; }
/* unsichtbare Brücke, damit das Popup beim Hineinfahren nicht zuklappt */
.rune-tip::before { content: ""; position: absolute; left: 0; right: 0; top: -10px; height: 10px; }
.rune-tile:hover .rune-tip, .rune-tile:focus .rune-tip, .rune-tile:focus-within .rune-tip { opacity: 1; visibility: visible; transform: none; }
.rune-tile.tip-right .rune-tip { left: auto; right: 0; }
.rune-tile.tip-up .rune-tip { top: auto; bottom: calc(100% + 8px); }
.rune-tile.tip-up .rune-tip::before { top: auto; bottom: -10px; }
.rune-tip h3 { color: #e0a34f; font-size: 1.2rem; margin-bottom: 8px; }
.rune-tip h3 small { font: 400 .8rem var(--sans); color: var(--muted); }
.rune-tip dl { margin: 0 0 10px; display: grid; gap: 8px; }
.rune-tip dt { font: 600 .7rem var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.rune-tip dd { margin: 2px 0 0; display: grid; gap: 1px; font-size: .92rem; color: #8f9be8; line-height: 1.45; }
.rune-tip p { margin: 0; padding-top: 8px; border-top: 1px solid var(--line); font-size: .82rem; color: var(--muted); }
.rune-tip p b { color: var(--text); }

/* ---------- Runen-Rechner ---------- */
.rune-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 8px; margin-bottom: 10px; }
.rune-btn { position: relative; display: grid; justify-items: center; gap: 2px; padding: 8px 4px 7px; border-radius: 12px; cursor: pointer; user-select: none; font: inherit; color: var(--muted); background: var(--bg-2); border: 1px solid var(--line-2); transition: transform .15s, border-color .2s, box-shadow .2s, color .2s, background .2s; }
.rune-btn .rune-img { width: 40px; height: 40px; }
.rune-btn .rune-img img { filter: grayscale(.85) brightness(.75); transition: filter .2s, transform .2s; }
.rune-btn b { font: 600 .82rem var(--display); letter-spacing: .04em; }
.rune-btn:hover { transform: translateY(-2px); color: var(--text); border-color: #c98b3c; }
.rune-btn:hover .rune-img img { filter: none; }
.rune-btn[aria-pressed="true"] { color: #e0a34f; border-color: #c98b3c; background: linear-gradient(180deg, rgb(201 139 60 / .2), var(--bg-2)); box-shadow: 0 0 20px -8px #c98b3c, inset 0 0 14px -8px #c98b3c; }
.rune-btn[aria-pressed="true"] .rune-img img { filter: drop-shadow(0 0 7px rgb(224 163 79 / .8)); transform: scale(1.08); }
.rune-btn i { position: absolute; top: 4px; right: 5px; font: 700 .72rem var(--mono); color: #14100a; background: #e0a34f; border-radius: 6px; padding: 0 5px; }
.rune-btn i:empty { display: none; }
.runecalc .chip { cursor: pointer; font-family: var(--sans); }
.word .rune.has { color: #14100a; background: #e0a34f; border-color: #e0a34f; }
.word .rune.lacks { color: var(--bad); border-color: color-mix(in oklab, var(--bad) 60%, transparent); border-style: dashed; }
.word.near { border-style: dashed; opacity: .82; }
.word.near:hover { opacity: 1; }
.card .missing { margin-top: 8px; font-size: .82rem; color: var(--bad); }
.word { content-visibility: visible; }

/* ---------- Runenwörter-Seite mit Runen-Rechner ---------- */
.rune-panel { margin-bottom: 22px; padding: 18px 20px; border-radius: var(--radius); border: 1px solid color-mix(in oklab, #c98b3c 40%, transparent); background: linear-gradient(180deg, rgb(201 139 60 / .08), transparent 70%), color-mix(in oklab, var(--panel) 85%, transparent); }
.rune-panel .head-row { margin-bottom: 4px; }
.rune-panel h2 { margin: 0; font-size: 1.3rem; color: #e0a34f; }
.rune-panel .hint { margin: 0; }
.seg button { padding: 6px 14px; border: 0; border-radius: 8px; background: none; cursor: pointer; color: var(--muted); font: 600 .85rem var(--sans); }
.seg button:hover { color: var(--text); }
.seg button[aria-pressed="true"] { background: var(--panel-2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2), 0 0 16px -6px var(--glow); }
.seg button small { margin-left: 4px; opacity: .75; font-family: var(--mono); }
.word.ready { border-color: color-mix(in oklab, #e0a34f 70%, transparent); box-shadow: 0 0 26px -14px #e0a34f; opacity: 1; }

/* ---------- Skill-Rechner im Stil der Skillbäume aus dem Spiel ---------- */
.skillcalc .trees { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); max-width: 980px; }
.skillcalc .tree-tab {
  padding: 12px 12px 16px; border-radius: 6px; border: 1px solid #5d5a55;
  background:
    radial-gradient(120% 80% at 30% 20%, rgb(255 255 255 / .07), transparent 60%),
    repeating-linear-gradient(115deg, rgb(255 255 255 / .025) 0 3px, transparent 3px 9px),
    linear-gradient(160deg, #4b4a48, #2f2e2d 55%, #3a3938);
  box-shadow: inset 0 0 0 3px #1b1a19, inset 0 0 0 4px #77726a, 0 16px 40px -20px #000;
}
.skillcalc .tree-tab h3 { display: flex; justify-content: space-between; align-items: baseline; margin: 2px 6px 10px; font-size: .95rem; letter-spacing: .1em; text-transform: uppercase; color: #d9d2c4; text-shadow: 0 1px 0 #000; }
.skillcalc .tree-tab h3 span { font: 700 .95rem var(--mono); color: var(--accent); }
.skillcalc .tree-grid { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(var(--rows, 6), 74px); grid-auto-rows: 74px; gap: 0; justify-items: center; align-items: center; }
.tree-lines { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.tree-lines line { stroke: #171615; stroke-width: 7; stroke-linecap: round; vector-effect: non-scaling-stroke; transition: stroke .25s; }
.tree-lines line.on { stroke: color-mix(in oklab, var(--accent) 80%, #3a1a0a); }
.skillcalc .skill {
  position: relative; z-index: 1; width: 56px; height: 56px; padding: 3px; display: grid; place-items: center; cursor: pointer; user-select: none;
  border-radius: 4px; border: 1px solid #0f0e0d; background: #141312; box-shadow: 0 2px 0 #000, inset 0 0 0 1px #6b665e; overflow: visible;
  font: inherit; color: var(--muted); transition: transform .12s, box-shadow .2s, filter .2s; opacity: 1;
}
.skillcalc.is-fixed .skill { cursor: help; }
.skillcalc .skill img { width: 48px; height: 48px; display: block; image-rendering: pixelated; filter: grayscale(1) brightness(.55); transition: filter .2s; }
.skillcalc .skill .skill-name { font: 600 .6rem/1.1 var(--sans); text-align: center; overflow-wrap: anywhere; }
.skillcalc .skill:hover, .skillcalc .skill:focus-visible { transform: scale(1.1); z-index: 3; box-shadow: 0 2px 0 #000, inset 0 0 0 1px #d8c9a8, 0 0 18px -4px #d8c9a8; outline: none; }
.skillcalc .skill:hover img { filter: grayscale(.2) brightness(.95); }
.skillcalc .skill.on { box-shadow: 0 2px 0 #000, inset 0 0 0 1px var(--accent), 0 0 20px -6px var(--accent); background: #141312; color: var(--text); }
.skillcalc .skill.on img { filter: none; }
.skillcalc .skill.max { box-shadow: 0 2px 0 #000, inset 0 0 0 2px #f1d27a, 0 0 22px -4px #f1d27a; }
.skillcalc .skill.locked { opacity: 1; }
.skillcalc .skill.locked img { filter: grayscale(1) brightness(.32); }
.skillcalc .skill b {
  position: absolute; right: -9px; bottom: -8px; min-width: 22px; height: 20px; padding: 0 4px; display: grid; place-items: center;
  font: 700 .8rem var(--mono); color: #fff; background: #1c1b1a; border: 1px solid #77726a; border-radius: 3px; box-shadow: 0 1px 0 #000;
}
.skillcalc .skill b:empty { display: none; }
.skillcalc .skill.max b { color: #f1d27a; border-color: #f1d27a; }
.skillcalc .skill.bump b { animation: pop .3s; }

.skill-tip {
  position: fixed; z-index: 80; width: min(330px, calc(100vw - 16px)); padding: 14px 16px; pointer-events: none;
  border-radius: 10px; border: 1px solid #77726a; background: rgb(14 13 12 / .96); box-shadow: 0 24px 60px -10px #000; font-size: .9rem; line-height: 1.45;
}
.skill-tip h4 { margin: 0 0 4px; font: 600 1.15rem var(--display); color: #7fd47f; }
.skill-tip p { margin: 0 0 8px; }
.skill-tip .tip-desc { color: var(--text); }
.skill-tip .tip-meta { color: var(--muted); font-size: .8rem; }
.skill-tip .tip-title { margin: 8px 0 3px; font: 600 .7rem var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.skill-tip dl { margin: 0 0 6px; padding: 8px 10px; border-radius: 8px; background: rgb(255 255 255 / .04); }
.skill-tip dl .tip-title { margin-top: 0; }
.skill-tip dl div { display: flex; justify-content: space-between; gap: 14px; }
.skill-tip dl span { color: var(--muted); }
.skill-tip dl b { font-family: var(--mono); color: #fff; }
.skill-tip .tip-now { border-left: 3px solid var(--accent); }
.skill-tip .tip-next { border-left: 3px solid #7fd47f; }
.skill-tip .tip-next b { color: #b9f0b9; }
.skill-tip .tip-facts { margin: 0 0 4px; padding-left: 16px; color: #8f9be8; font-size: .85rem; }
@media (max-width: 560px) { .skillcalc .tree-grid { grid-template-rows: repeat(var(--rows, 6), 66px); grid-auto-rows: 66px; } }

/* Skillverteilung und Schritte im Build-Datenblatt */
.sheet .skillcalc { margin-bottom: 1em; }
.sheet ol.steps li { padding-top: 14px; padding-bottom: 14px; }
.skill-list { margin: 0 0 1em; }
.skill-tip h4 small { display: block; font: 400 .75rem var(--sans); color: var(--muted); }
.skill-tip dl .tip-bonus { margin: 4px 0 0; font-size: .75rem; color: #e0a34f; }
.skill-tip .tip-facts b { color: #e0a34f; font-family: var(--mono); }
.run-status { margin: 12px 0; padding: 12px 16px; border-radius: 10px; border: 1px solid color-mix(in oklab, var(--accent) 45%, transparent); background: var(--tint); font-size: .92rem; }
button:disabled { opacity: .5; cursor: wait; }

/* ---------- Admin: Quellen je Spiel ---------- */
.source-group { margin-bottom: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: color-mix(in oklab, var(--panel) 60%, transparent); }
.source-group > summary { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 14px 18px; cursor: pointer; list-style: none; }
.source-group > summary::-webkit-details-marker { display: none; }
.source-group > summary b { font: 600 1.15rem var(--display); letter-spacing: .05em; color: var(--accent); }
.source-group > summary .btn { margin-left: auto; }
.source-group[open] > summary { border-bottom: 1px solid var(--line); }
.source-group > .admin-row { margin: 10px 12px; }
.source-group > .empty { margin: 12px; }
.run-status .run-line { display: block; margin-top: 4px; color: var(--muted); }

/* ---------- Hero-Banner eines Spiels (Bild mit überlagerten Klickflächen) ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.hero-banner { position: relative; margin-bottom: 44px; border-radius: 24px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 30px 80px -40px var(--glow); }
.hero-banner img { display: block; width: 100%; height: auto; }
.hero-banner a { position: absolute; border-radius: 10px; transition: box-shadow .2s, background .2s; }
.hero-banner a:hover, .hero-banner a:focus-visible { background: rgb(255 255 255 / .08); box-shadow: 0 0 0 2px rgb(255 255 255 / .5), 0 0 30px -4px var(--accent); }
.hero-fallback { display: none; }
.hero .hero-title { font: 600 clamp(2.3rem, 1.2rem + 4.6vw, 4.6rem)/1.15 var(--display); max-width: 17ch; margin: 0 0 .3em; background: linear-gradient(180deg, #fff 20%, color-mix(in oklab, var(--accent) 65%, white)); -webkit-background-clip: text; background-clip: text; color: transparent; }
/* Auf schmalen Bildschirmen wäre die Schrift im Bild unlesbar klein: dort der Text-Aufhänger */
@media (max-width: 760px) { .hero-banner { display: none; } .hero-fallback { display: block; } }

/* ---------- Gestalteter Banner: Text links, Emblem im Bannkreis rechts ---------- */
.hero-emblem {
  display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: center; gap: 24px;
  min-height: 330px; margin-bottom: 44px; padding: clamp(28px, 4vw, 56px) clamp(22px, 5vw, 64px);
  background:
    radial-gradient(60% 120% at 78% 50%, color-mix(in oklab, var(--accent) 26%, transparent), transparent 70%),
    linear-gradient(120deg, #151014, #0d0b0e 55%, #120d0b);
}
.hero-emblem::after { mask: radial-gradient(ellipse at 78% 50%, #000, transparent 65%); }
.hero-emblem .kicker { display: flex; align-items: center; gap: 14px; color: var(--muted); }
.hero-emblem .kicker span { color: var(--accent); }
.hero-emblem .kicker i { width: 46px; height: 1px; background: var(--accent); }
.hero-emblem h1 {
  font-size: clamp(2.4rem, 1.1rem + 4.4vw, 5rem); line-height: 1.02; max-width: none; margin-bottom: .35em;
  text-transform: uppercase; letter-spacing: .02em; font-variant-numeric: lining-nums;
  background: linear-gradient(180deg, #fff 10%, color-mix(in oklab, var(--accent) 80%, #fff) 95%); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-emblem .lead { margin-bottom: 26px; }
.hero-art { position: relative; justify-self: center; width: min(100%, 340px); aspect-ratio: 1; display: grid; place-items: center; color: color-mix(in oklab, var(--accent) 85%, #fff); }
.hero-art::before { content: ""; position: absolute; inset: 8%; border-radius: 50%; background: radial-gradient(circle, color-mix(in oklab, var(--accent) 70%, #ff5a1f) 0%, transparent 68%); filter: blur(26px); opacity: .75; animation: breathe 7s ease-in-out infinite; }
.hero-art .sigil { position: absolute; inset: 0; width: 100%; height: 100%; animation: sigil 90s linear infinite; }
.hero-art img { position: relative; width: 58%; height: auto; border-radius: 50%; box-shadow: 0 0 0 2px color-mix(in oklab, var(--accent) 60%, transparent), 0 0 60px -6px var(--accent); transition: transform .5s cubic-bezier(.2, .7, .2, 1); }
.hero-emblem:hover .hero-art img { transform: scale(1.05); }
@keyframes sigil { to { transform: rotate(360deg); } }
@media (max-width: 760px) {
  .hero-emblem { grid-template-columns: 1fr; min-height: 0; }
  .hero-art { order: -1; width: min(60%, 220px); }
}
