/* Fish a Human HQ - Meer-Design (dunkles Tiefblau, Tuerkis, Koralle, Gold), Handy zuerst, ab 1000 px Seitenleiste + 2 Spalten */
:root {
  --bg: #04121f;
  --bg2: #06192a;
  --card: #0a2236;
  --card2: #0f3049;
  --line: rgba(120, 205, 255, 0.10);
  --text: #eaf6ff;
  --muted: #86a8c0;
  --gold: #ffcc3d;
  --green: #3ee08f;
  --red: #ff5d6c;
  --cyan: #3cd2ff;
  --teal: #2ee6c8;
  --coral: #ff8a5c;
  --purple: #a77bff;
  --pink: #ff7ad9;
  --r: 18px;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body {
  font: 15px/1.38 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased; overscroll-behavior-y: none; font-variant-numeric: tabular-nums;
  background: radial-gradient(140% 70% at 50% -10%, #0b3a5c 0%, var(--bg) 55%) fixed, var(--bg);
}
.hidden { display: none !important; }
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; }
h1, h2, .stat-v, .hero-n, .top-name, .board-v, .tabs span, .pval, .isle-n, .fn-val, .verdict-n, .tabs-brand { font-family: "Fredoka", -apple-system, sans-serif; }
h2 { margin: 0; font-size: 17px; font-weight: 600; letter-spacing: 0.2px; }
.muted { color: var(--muted); }
.small { font-size: 12px; margin-top: 8px; }
.up { color: var(--green); }
.down { color: var(--red); }
.empty { padding: 22px 8px; text-align: center; color: var(--muted); }

/* aufsteigende Blasen im Hintergrund (sehr dezent) */
.sea { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.sea i { position: absolute; bottom: -40px; width: 10px; height: 10px; border-radius: 50%; border: 1px solid rgba(120, 220, 255, 0.18);
  background: radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.18), transparent 60%); animation: rise 22s linear infinite; }
.sea i:nth-child(1) { left: 8%; animation-delay: -3s; }
.sea i:nth-child(2) { left: 24%; width: 6px; height: 6px; animation-duration: 28s; animation-delay: -12s; }
.sea i:nth-child(3) { left: 47%; width: 14px; height: 14px; animation-duration: 34s; animation-delay: -20s; }
.sea i:nth-child(4) { left: 66%; width: 7px; height: 7px; animation-delay: -8s; }
.sea i:nth-child(5) { left: 81%; width: 12px; height: 12px; animation-duration: 30s; animation-delay: -16s; }
.sea i:nth-child(6) { left: 93%; width: 5px; height: 5px; animation-duration: 26s; animation-delay: -1s; }
@keyframes rise { from { transform: translate(0, 0); opacity: 0; } 10% { opacity: 1; } 50% { transform: translate(14px, -55vh); }
  to { transform: translate(-6px, -110vh); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .sea { display: none; } * { animation: none !important; } }

/* Login */
.login { position: fixed; inset: 0; z-index: 5; display: grid; place-items: center; padding: 24px; }
.login-card { width: 100%; max-width: 340px; text-align: center; }
.login-icon { width: 104px; height: 104px; border-radius: 26px; box-shadow: 0 14px 44px rgba(60, 210, 255, 0.35); }
.login h1 { margin: 18px 0 4px; font-size: 30px; font-weight: 700; }
.login h1 span, .top-name span, .tabs-brand b { color: var(--gold); }
.login p { margin: 0 0 22px; color: var(--muted); }
.login input { width: 100%; padding: 15px 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); color: var(--text); font-size: 17px; outline: none; }
.login input:focus { border-color: var(--cyan); }
.login button { width: 100%; margin-top: 12px; padding: 15px; border-radius: 14px; font-weight: 700; font-size: 17px;
  background: linear-gradient(180deg, #ffe066, #ffbf1f); color: #2a1c00; }
.login-err { color: var(--red); min-height: 20px; margin-top: 10px; font-size: 14px; }

/* Rahmen */
.app { position: relative; z-index: 1; min-height: 100vh; padding: calc(var(--safe-t) + 64px) 14px calc(var(--safe-b) + 86px); }
.top { position: fixed; top: 0; left: 0; right: 0; z-index: 20; display: flex; align-items: center; gap: 10px;
  padding: calc(var(--safe-t) + 8px) 14px 10px; background: rgba(4, 18, 31, 0.8);
  backdrop-filter: saturate(160%) blur(18px); -webkit-backdrop-filter: saturate(160%) blur(18px); border-bottom: 1px solid var(--line); }
.top-icon { width: 36px; height: 36px; border-radius: 10px; }
.top-title { flex: 1; min-width: 0; }
.top-name { font-size: 18px; font-weight: 700; line-height: 1.1; }
.top-sub { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.live-pill { display: flex; align-items: center; gap: 7px; padding: 6px 12px; border-radius: 99px; background: rgba(62, 224, 143, 0.12);
  color: var(--green); font-weight: 700; font-family: "Fredoka", sans-serif; font-size: 16px; }
.live-pill i { width: 8px; height: 8px; border-radius: 50%; background: var(--green); animation: ping 1.8s infinite; }
.live-pill.off { background: rgba(134, 168, 192, 0.12); color: var(--muted); }
.live-pill.off i { background: var(--muted); animation: none; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(62, 224, 143, 0.55); } 80%, 100% { box-shadow: 0 0 0 9px rgba(62, 224, 143, 0); } }
.refresh { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; color: var(--muted); flex: none; }
.refresh svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.refresh.busy { color: var(--gold); }
.refresh.busy svg { animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.ptr { position: fixed; top: calc(var(--safe-t) + 66px); left: calc(50% - 18px); z-index: 19; width: 36px; height: 36px; border-radius: 50%;
  background: var(--card2); border: 1px solid var(--line); display: grid; place-items: center; color: var(--muted); transform: translateY(-70px); }
.ptr svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform .15s; }
.ptr.ready { color: var(--gold); border-color: var(--gold); }
.ptr.ready svg { transform: rotate(180deg); }

.view { display: none; animation: fade .25s ease; }
.view.active { display: block; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.card { background: linear-gradient(180deg, rgba(15, 48, 73, 0.55), rgba(10, 34, 54, 0.92)); border: 1px solid var(--line); border-radius: var(--r);
  padding: 16px; margin-bottom: 14px; break-inside: avoid; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.link { color: var(--cyan); font-size: 13px; font-weight: 600; }

/* Held */
.hero { padding: 18px 16px; background: radial-gradient(120% 140% at 0% 0%, rgba(60, 210, 255, 0.22), transparent 55%),
  radial-gradient(90% 120% at 100% 100%, rgba(46, 230, 200, 0.12), transparent 60%), var(--card); }
.hero-main { display: flex; align-items: center; gap: 18px; }
.hero-ring { width: 128px; height: 128px; flex: none; border-radius: 50%; display: grid; place-items: center; position: relative;
  background: conic-gradient(from 200deg, var(--cyan), var(--teal), var(--green), var(--gold), var(--coral), var(--cyan)); padding: 5px; }
.hero-ring::before { content: ""; position: absolute; inset: 5px; border-radius: 50%; background: radial-gradient(circle at 50% 35%, #0f3352, #071a2b); }
.hero-ring::after { content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 2px solid rgba(60, 210, 255, 0.4); animation: halo 2.6s infinite; }
@keyframes halo { 0% { transform: scale(0.94); opacity: 0.9; } 100% { transform: scale(1.13); opacity: 0; } }
.hero-n { position: relative; font-size: 54px; font-weight: 700; line-height: 1; }
.hero-n.bump { animation: bump .5s ease; }
@keyframes bump { 40% { transform: scale(1.18); color: var(--gold); } }
.hero-txt { flex: 1; min-width: 0; }
.hero-label { font-weight: 700; font-size: 17px; }
.hero-meta { margin-top: 4px; font-size: 13px; color: var(--muted); }
.acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.acts:empty { display: none; }
.act { display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 99px; background: rgba(255, 255, 255, 0.06); font-size: 12px; font-weight: 600; }
.act b { font-family: "Fredoka", sans-serif; font-size: 14px; }
.link-warn { margin-top: 12px; padding: 10px 12px; border-radius: 12px; background: rgba(255, 93, 108, 0.14); color: #ffb9c0; font-size: 13px; }

.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.grid.tight { margin-bottom: 0; }
.stat { background: linear-gradient(180deg, rgba(15, 48, 73, 0.6), rgba(10, 34, 54, 0.95)); border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; min-width: 0; }
.stat-k { font-size: 11.5px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.6px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat-v { font-size: 25px; font-weight: 700; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat-s { font-size: 12px; color: var(--muted); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat.gold .stat-v { color: var(--gold); }
.stat.green .stat-v { color: var(--green); }
.stat.cyan .stat-v { color: var(--cyan); }
.stat.coral .stat-v { color: var(--coral); }

.seg { display: inline-flex; background: var(--bg2); border-radius: 11px; padding: 3px; gap: 2px; }
.seg button { padding: 6px 11px; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.seg button.on { background: var(--card2); color: var(--text); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3); }
.seg button b { font-family: "Fredoka", sans-serif; margin-left: 3px; color: var(--green); }
.seg.wide { display: flex; width: 100%; margin-bottom: 12px; overflow-x: auto; scrollbar-width: none; }
.seg.wide::-webkit-scrollbar, .chips::-webkit-scrollbar { display: none; }
.seg.wide button { flex: 1; }

/* Inselkarte: 8 Inseln + Zuhause, Farbe der Insel aus dem Spiel */
.isles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.isle { position: relative; border-radius: 14px; padding: 10px 11px; min-height: 74px; overflow: hidden; border: 1px solid var(--line);
  background: linear-gradient(135deg, color-mix(in srgb, var(--c) 30%, transparent), rgba(10, 34, 54, 0.6) 70%); }
.isle.empty-isle { opacity: .55; }
.isle-top { display: flex; align-items: baseline; gap: 6px; }
.isle-i { font-size: 10px; font-weight: 800; color: var(--c); letter-spacing: .5px; }
.isle-name { font-size: 13px; font-weight: 650; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.isle-n { font-size: 22px; font-weight: 700; line-height: 1; }
.isle-people { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.isle-p { position: relative; width: 26px; height: 26px; border-radius: 50%; background: var(--card2); border: 2px solid var(--c); overflow: visible; cursor: pointer; }
.isle-p img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
.isle-p em { position: absolute; right: -5px; bottom: -4px; font-style: normal; font-size: 11px; line-height: 1; }
.isle-p.fight { animation: wob .9s ease-in-out infinite; }
@keyframes wob { 50% { transform: rotate(-8deg) scale(1.06); } }
.isle.home { grid-column: 1 / -1; min-height: 0; }

/* Verlauf */
.chart { height: 200px; position: relative; }
.chart svg { width: 100%; height: 100%; display: block; overflow: visible; }
.chart .tip, .vb-tip { position: absolute; top: 0; pointer-events: none; background: var(--card2); border: 1px solid var(--line); border-radius: 10px;
  padding: 5px 9px; font-size: 12px; white-space: nowrap; transform: translateX(-50%); z-index: 2; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35); }
.legend { display: flex; gap: 14px; margin-top: 8px; font-size: 11px; color: var(--muted); flex-wrap: wrap; }
.legend i { display: inline-block; width: 14px; height: 3px; border-radius: 2px; vertical-align: middle; margin-right: 5px; }
.lg-line { background: var(--cyan); }
.lg-ver { background: repeating-linear-gradient(90deg, var(--gold) 0 3px, transparent 3px 5px); }
.lg-ad { background: rgba(255, 138, 92, 0.6); height: 8px !important; }

/* Gesundheit */
.hl { display: grid; gap: 8px; }
.srv { display: grid; grid-template-columns: auto 1fr auto; gap: 4px 10px; align-items: center; padding: 10px 12px; background: var(--bg2); border-radius: 12px; font-size: 13px; }
.srv-n { font-family: "Fredoka", sans-serif; font-size: 18px; }
.srv-m { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srv-kpis { grid-column: 1 / -1; display: flex; gap: 6px; flex-wrap: wrap; }
.k { padding: 2px 8px; border-radius: 8px; font-size: 12px; font-weight: 650; background: rgba(255, 255, 255, 0.06); }
.k.good { color: var(--green); } .k.ok { color: var(--gold); } .k.bad { color: var(--red); background: rgba(255, 93, 108, 0.14); }

/* Spieler */
.plist { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; }
.prow { display: flex; align-items: center; gap: 11px; padding: 9px 4px; border-bottom: 1px solid var(--line); }
.prow:last-child { border-bottom: 0; }
.ava { width: 44px; height: 44px; border-radius: 50%; background: var(--card2); flex: none; object-fit: cover; }
.pinfo { flex: 1; min-width: 0; }
.pname { font-weight: 650; display: flex; align-items: baseline; gap: 5px; white-space: nowrap; min-width: 0; }
.pname .pn { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.pname small { flex: 0 1000 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; color: var(--muted); font-weight: 400; }
.pmeta { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.pval { flex: none; white-space: nowrap; text-align: right; font-weight: 600; font-size: 16px; color: var(--gold); }
.pval small { display: block; font-family: -apple-system, sans-serif; font-weight: 400; font-size: 11px; color: var(--muted); }
.tag { flex: none; display: inline-block; padding: 1px 7px; border-radius: 6px; font-size: 10px; font-weight: 800; letter-spacing: 0.5px; vertical-align: 2px; }
.tag.new { background: var(--gold); color: #2a1c00; }
.tag.fight { background: var(--red); color: #fff; animation: blink 1s infinite; }
.tag.auto { background: var(--teal); color: #032a24; }
.tag.studio { background: var(--purple); color: #fff; }
.tag.dev { background: var(--cyan); color: #032333; }
.tag.grp { background: rgba(255, 204, 61, 0.2); color: var(--gold); }
@keyframes blink { 50% { opacity: 0.55; } }
.pg .card { padding: 8px 12px; }
.prow[data-uid], .brow[data-uid] { cursor: pointer; }

.board { display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.brow { display: flex; align-items: center; gap: 12px; padding: 9px 4px; border-bottom: 1px solid var(--line); }
.brow:last-child { border-bottom: 0; }
.rank { width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; font-family: "Fredoka", sans-serif; font-weight: 700; background: var(--card2); flex: none; }
.brow:nth-child(1) .rank { background: linear-gradient(180deg, #ffe680, #ffb81f); color: #3a2800; }
.brow:nth-child(2) .rank { background: linear-gradient(180deg, #eef2ff, #aab3cf); color: #222a40; }
.brow:nth-child(3) .rank { background: linear-gradient(180deg, #ffc08a, #c97a3a); color: #3a1c00; }
.board-n { flex: 1; min-width: 0; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.board-v { font-weight: 600; font-size: 17px; color: var(--gold); white-space: nowrap; }

/* Feed */
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 10px; scrollbar-width: none; }
.chips button, .chips span { padding: 8px 14px; border-radius: 99px; background: var(--card); border: 1px solid var(--line); white-space: nowrap; font-size: 14px; font-weight: 600; color: var(--muted); }
.chips button.on { background: var(--text); color: var(--bg); }
.chips.static { flex-wrap: wrap; overflow: visible; }
.chips.static span { padding: 5px 11px; font-size: 13px; }
.chips.static span small { color: var(--muted); font-weight: 400; margin-left: 4px; }
.feed { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.ev { display: flex; gap: 12px; padding: 12px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; }
.feed.compact { gap: 0; }
.feed.compact .ev { background: none; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; padding: 9px 2px; }
.feed.compact .ev:last-child { border-bottom: 0; }
.ev-ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; font-size: 19px; flex: none; background: var(--card2); }
.ev-ic.purchase { background: rgba(62, 224, 143, 0.15); }
.ev-ic.rare { background: rgba(255, 204, 61, 0.16); }
.ev-ic.error { background: rgba(255, 93, 108, 0.2); }
.ev-ic.join { background: rgba(60, 210, 255, 0.14); }
.ev-ic.area, .ev-ic.rebirth { background: rgba(46, 230, 200, 0.14); }
.ev-b { flex: 1; min-width: 0; }
.ev-t { font-weight: 600; }
.ev-s { font-size: 13px; color: var(--muted); margin-top: 1px; word-break: break-word; }
.ev-time { font-size: 12px; color: var(--muted); white-space: nowrap; text-align: right; }
.err { padding: 12px; background: var(--card); border: 1px solid rgba(255, 93, 108, 0.25); border-radius: 16px; }
.err-top { display: flex; gap: 10px; align-items: baseline; }
.err-n { font-family: "Fredoka", sans-serif; font-size: 20px; color: var(--red); flex: none; }
.err-m { flex: 1; min-width: 0; font: 12px/1.4 ui-monospace, Menlo, monospace; word-break: break-word; }
.err-s { font-size: 12px; color: var(--muted); margin-top: 6px; }
.err pre { margin: 6px 0 0; white-space: pre-wrap; font: 11px/1.4 ui-monospace, Menlo, monospace; color: var(--muted); }

/* Diagramme */
.vb { position: relative; margin-top: 4px; }
.vb.short .vb-plot { height: 84px; }
.vb-plot { display: flex; align-items: flex-end; gap: 3px; height: 130px; padding-top: 18px; }
.vb-col { flex: 1; height: 100%; display: flex; align-items: flex-end; position: relative; cursor: pointer; }
.vb-bar { width: 100%; border-radius: 4px 4px 2px 2px; background: linear-gradient(180deg, var(--cyan), rgba(60, 210, 255, 0.35)); transition: filter .12s; }
.vb-bar.green { background: linear-gradient(180deg, var(--green), rgba(62, 224, 143, 0.35)); }
.vb-bar.gold { background: linear-gradient(180deg, var(--gold), rgba(255, 204, 61, 0.35)); }
.vb-bar.coral { background: linear-gradient(180deg, var(--coral), rgba(255, 138, 92, 0.35)); }
.vb-bar.teal { background: linear-gradient(180deg, var(--teal), rgba(46, 230, 200, 0.35)); }
.vb-bar.red { background: linear-gradient(180deg, var(--red), rgba(255, 93, 108, 0.35)); }
.vb-col.hot .vb-bar { filter: brightness(1.35); }
.vb-max { position: absolute; top: -16px; left: 50%; transform: translateX(-50%); font-size: 10px; color: var(--text); white-space: nowrap; pointer-events: none; }
.vb-x { display: flex; gap: 3px; margin-top: 4px; }
.vb-x span { flex: 1; text-align: center; font-size: 10px; color: var(--muted); white-space: nowrap; overflow: hidden; }
.vb-tip { top: -10px; transform: translate(-50%, -100%); }
.fn { display: grid; gap: 2px; }
.fn-row { display: grid; grid-template-columns: 1fr auto; gap: 5px 10px; padding: 7px 0; align-items: baseline; }
.fn-label { font-size: 14px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fn-val { font-weight: 600; font-size: 15px; white-space: nowrap; }
.fn-val .muted { font-weight: 500; font-size: 13px; }
.fn-val small { margin-left: 6px; color: var(--red); font-size: 12px; font-weight: 500; }
.fn-track { grid-column: 1 / -1; height: 9px; background: rgba(255, 255, 255, 0.06); border-radius: 99px; overflow: hidden; }
.fn-track i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, rgba(60, 210, 255, 0.5), var(--cyan)); }
.fn.gold .fn-track i { background: linear-gradient(90deg, rgba(255, 204, 61, 0.5), var(--gold)); }
.fn.green .fn-track i { background: linear-gradient(90deg, rgba(62, 224, 143, 0.5), var(--green)); }
.fn.coral .fn-track i { background: linear-gradient(90deg, rgba(255, 138, 92, 0.5), var(--coral)); }

/* Seltenheiten: Ist-Balken + Strich fuer die Grundchance */
.rar { display: grid; gap: 10px; }
.rar-row { display: grid; grid-template-columns: 92px 1fr auto; gap: 10px; align-items: center; font-size: 13px; }
.rar-name { font-weight: 700; color: var(--c); }
.rar-track { position: relative; height: 12px; background: rgba(255, 255, 255, 0.06); border-radius: 99px; }
.rar-track i { display: block; height: 100%; border-radius: 99px; background: var(--c); opacity: .85; }
.rar-track b { position: absolute; top: -3px; bottom: -3px; width: 2px; background: var(--text); border-radius: 2px; opacity: .8; }
.rar-v { font-family: "Fredoka", sans-serif; font-weight: 600; white-space: nowrap; }
.rar-v small { color: var(--muted); font-family: -apple-system, sans-serif; font-weight: 400; margin-left: 4px; }

/* Fortschritt Soll/Ist: Band = Soll A bis B, Kasten = mittlere Haelfte der Spieler, Strich = Median */
.ip { display: grid; gap: 12px; }
.ip-row { display: grid; grid-template-columns: 112px 1fr; gap: 10px; align-items: center; }
.ip-name { font-size: 13px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ip-name small { display: block; color: var(--muted); font-weight: 400; font-size: 11px; }
.ip-track { position: relative; height: 26px; background: rgba(255, 255, 255, 0.04); border-radius: 8px; }
.ip-soll { position: absolute; top: 3px; bottom: 3px; border-radius: 6px; background: repeating-linear-gradient(135deg, rgba(255, 204, 61, 0.28) 0 5px, rgba(255, 204, 61, 0.12) 5px 10px); border: 1px solid rgba(255, 204, 61, 0.55); }
.ip-box { position: absolute; top: 7px; bottom: 7px; border-radius: 5px; background: color-mix(in srgb, var(--c) 55%, transparent); }
.ip-med { position: absolute; top: 2px; bottom: 2px; width: 3px; border-radius: 2px; background: var(--text); box-shadow: 0 0 0 2px rgba(4, 18, 31, .7); }
.ip-lab { position: absolute; top: 50%; transform: translateY(-50%); font-size: 11px; white-space: nowrap; color: var(--text); font-weight: 650; text-shadow: 0 1px 2px #000; }
.ip-axis { display: grid; grid-template-columns: 112px 1fr; gap: 10px; }
.ip-axis div { position: relative; height: 14px; font-size: 10px; color: var(--muted); }
.ip-axis > div span { position: absolute; white-space: nowrap; }

/* Tabellen */
.tbl-wrap { overflow-x: auto; margin: 0 -4px; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
.tbl th { color: var(--muted); font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: .4px; text-align: right; padding: 4px 4px 8px; white-space: nowrap; }
.tbl th:first-child, .tbl td.day { text-align: left; }
.tbl td { text-align: right; padding: 5px 4px; border-top: 1px solid var(--line); white-space: nowrap; }
.tbl td.na { color: var(--muted); }
.tbl.dense { font-size: 12px; }
.tbl.dense td, .tbl.dense th { padding: 4px 3px; }
.tbl tr.weak td { color: var(--muted); }
.tbl .ch { display: inline-block; min-width: 40px; padding: 2px 6px; border-radius: 6px; text-align: center; background: rgba(60, 210, 255, 0.2); }
.tbl .ch.bad { background: rgba(255, 93, 108, 0.22); }
.tbl .ch.good { background: rgba(62, 224, 143, 0.22); }
.tbl .ch.ok { background: rgba(255, 204, 61, 0.22); }
.bad-t { color: var(--red); font-weight: 700; }
.good-t { color: var(--green); font-weight: 700; }

.hm { display: grid; gap: 2px; margin-top: 4px; }
.hm-row { display: grid; grid-template-columns: 24px repeat(24, 1fr); gap: 2px; align-items: center; }
.hm-row > span { font-size: 10px; color: var(--muted); text-align: center; }
.hm-row > span:first-child { text-align: left; }
.hm-row i { display: block; aspect-ratio: 1; border-radius: 3px; background: rgba(255, 255, 255, 0.04); cursor: pointer; }
.hm-row i.na { background: repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.05) 0 2px, transparent 2px 4px); }

.gs-kv { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 2px 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.gs-kv:last-child { border-bottom: 0; }
.gs-kv b { font-family: "Fredoka", sans-serif; font-size: 20px; }
.gs-kv small { grid-column: 2; text-align: right; color: var(--muted); font-size: 12px; }
.gs-kv .when { font-family: inherit; font-size: 11px; font-weight: 400; color: var(--muted); white-space: nowrap; }
.gs-kv .sub { display: block; font-size: 12px; color: var(--muted); }
.gs-block { margin-top: 12px; }
.gs-block h3 { margin: 0 0 4px; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; font-weight: 600; }

.verdict { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: 14px; background: var(--bg2); margin-bottom: 6px; }
.verdict-n { font-size: 34px; font-weight: 700; flex: none; }
.verdict small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.verdict.good .verdict-n, .verdict.good b { color: var(--green); }
.verdict.ok .verdict-n, .verdict.ok b { color: var(--gold); }
.verdict.bad .verdict-n, .verdict.bad b { color: var(--red); }
.sig { padding: 9px 0; border-bottom: 1px solid var(--line); }
.sig:last-child { border-bottom: 0; }
.sig-top { display: flex; align-items: center; gap: 8px; }
.sig-l { flex: 1; min-width: 0; font-size: 14px; }
.sig-v { font-family: "Fredoka", sans-serif; font-size: 16px; white-space: nowrap; }
.sig-n { font-size: 12px; color: var(--muted); margin-top: 3px; }
.pill { flex: none; padding: 2px 8px; border-radius: 99px; font-size: 11px; font-weight: 700; white-space: nowrap; }
.pill.good { background: rgba(62, 224, 143, 0.18); color: var(--green); }
.pill.ok { background: rgba(255, 204, 61, 0.18); color: var(--gold); }
.pill.bad { background: rgba(255, 93, 108, 0.18); color: var(--red); }
.pill.na { background: var(--card2); color: var(--muted); }

/* Werbung */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form label { display: grid; gap: 4px; font-size: 12px; color: var(--muted); font-weight: 600; }
.form label:first-child { grid-column: 1 / -1; }
.form input, .form select { width: 100%; padding: 11px 12px; border-radius: 11px; border: 1px solid var(--line); background: var(--bg2); color: var(--text); font: inherit; color-scheme: dark; }
.form .btn { grid-column: 1 / -1; margin-top: 2px; }
.camp-days { display: flex; align-items: flex-end; gap: 3px; height: 60px; margin: 8px 0 4px; }
.camp-days i { flex: 1; background: linear-gradient(180deg, var(--coral), rgba(255, 138, 92, 0.35)); border-radius: 3px 3px 1px 1px; min-height: 2px; }

/* Knoepfe, Einstellungen */
.btn { display: block; width: 100%; text-align: center; padding: 13px; border-radius: 13px; font-weight: 700; margin-top: 8px;
  background: linear-gradient(180deg, #5fe0ff, #1fa8e0); color: #022235; text-decoration: none; }
.btn.ghost { background: var(--card2); color: var(--text); }
.btn.danger { background: rgba(255, 93, 108, 0.14); color: var(--red); }
.btn.small { display: inline-block; width: auto; padding: 6px 12px; font-size: 12px; margin: 0; }
.hint { padding: 12px; border-radius: 12px; background: rgba(255, 204, 61, 0.1); color: #ffe6a0; font-size: 14px; margin-bottom: 6px; }
.prefs { margin-top: 10px; display: grid; }
.pref { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 2px; border-bottom: 1px solid var(--line); }
.pref:last-child { border-bottom: 0; }
.pref small { display: block; color: var(--muted); font-size: 12px; }
.switch { position: relative; width: 51px; height: 31px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span { position: absolute; inset: 0; background: #2b4157; border-radius: 99px; transition: .2s; }
.switch span::before { content: ""; position: absolute; width: 27px; height: 27px; left: 2px; top: 2px; background: #fff; border-radius: 50%; transition: .2s; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }
.switch input:checked + span { background: var(--green); }
.switch input:checked + span::before { transform: translateX(20px); }
.badge { padding: 3px 9px; border-radius: 99px; font-size: 12px; font-weight: 700; background: var(--card2); white-space: nowrap; }
.badge.live { background: rgba(62, 224, 143, 0.14); color: var(--green); }
.steps { margin: 0 0 10px; padding-left: 20px; font-size: 14px; display: grid; gap: 6px; }
.steps a { color: var(--cyan); }
.scriptbox { width: 100%; height: 130px; margin-top: 8px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg2); color: var(--text);
  font: 11px/1.4 ui-monospace, Menlo, monospace; padding: 8px; resize: none; }

/* Spieler-Detail */
.sheet { position: fixed; inset: 0; z-index: 30; }
.sheet-bg { position: absolute; inset: 0; background: rgba(0, 8, 16, 0.6); }
.sheet-card { position: absolute; left: 0; right: 0; bottom: 0; max-height: 88vh; overflow-y: auto; background: var(--card); border-radius: 22px 22px 0 0;
  padding: 10px 16px calc(var(--safe-b) + 20px); border-top: 1px solid var(--line); animation: sheetin .25s ease; }
@keyframes sheetin { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.sheet-grip { width: 40px; height: 5px; border-radius: 3px; background: var(--muted); opacity: .5; margin: 0 auto 10px; }
.sheet-card > div > .prow:first-child { padding-right: 40px; }
.sheet-x { position: absolute; top: 10px; right: 12px; width: 32px; height: 32px; border-radius: 50%; background: var(--card2); color: var(--muted); font-size: 14px; }
.sheet-card .grid { margin: 10px 0 0; grid-template-columns: repeat(3, 1fr); }
.sheet-card .stat-v { font-size: 18px; }
.sheet-card .pval { text-decoration: none; font-size: 14px; color: var(--cyan); }
.sheet-card .pname { white-space: normal; }
.path { display: flex; gap: 6px; flex-wrap: wrap; }
.path span { padding: 4px 9px; border-radius: 99px; background: rgba(46, 230, 200, 0.12); color: var(--teal); font-size: 12px; font-weight: 650; }
.path span small { color: var(--muted); font-weight: 400; margin-left: 4px; }
body.noscroll { overflow: hidden; }

/* Tab-Leiste (Handy unten) */
.tabs { position: fixed; bottom: 0; left: 0; right: 0; z-index: 20; display: flex; padding: 6px 6px calc(var(--safe-b) + 6px);
  background: rgba(4, 18, 31, 0.86); backdrop-filter: saturate(160%) blur(18px); -webkit-backdrop-filter: saturate(160%) blur(18px); border-top: 1px solid var(--line); }
.tabs-brand { display: none; }
.tabs button { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 0; color: var(--muted); position: relative; }
.tabs svg { width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.tabs span { font-size: 11px; font-weight: 600; }
.tabs button.on { color: var(--gold); }
.tabs .dot { position: absolute; top: 4px; right: calc(50% - 16px); width: 9px; height: 9px; border-radius: 50%; background: var(--red); border: 2px solid var(--bg); }

@media (max-width: 420px) { .hero-ring { width: 108px; height: 108px; } .hero-n { font-size: 46px; } .hero-main { gap: 14px; } }
@media (min-width: 560px) {
  .grid { grid-template-columns: repeat(4, 1fr); }
  .isles { grid-template-columns: repeat(4, 1fr); }
  .vb-plot { height: 160px; }
}
@media (min-width: 720px) and (max-width: 999px) {
  .app { max-width: 780px; margin: 0 auto; }
}
/* PC: Seitenleiste links, Inhalt in zwei Spalten (Karten mit .span ueber beide) */
@media (min-width: 1000px) {
  .app { padding: 24px 28px 40px 264px; max-width: 1640px; }
  .top { left: 236px; padding: 12px 28px; }
  .top-icon, .top-name { display: none; }
  .top-sub { font-size: 13px; }
  .app { padding-top: 76px; }
  .tabs { top: 0; bottom: 0; right: auto; width: 236px; flex-direction: column; justify-content: flex-start; gap: 4px; padding: 18px 14px;
    border-top: 0; border-right: 1px solid var(--line); }
  .tabs-brand { display: flex; align-items: center; gap: 10px; padding: 0 6px 18px; font-size: 18px; font-weight: 700; }
  .tabs-brand img { width: 40px; height: 40px; border-radius: 11px; }
  .tabs button { flex: none; flex-direction: row; gap: 12px; padding: 11px 12px; border-radius: 12px; }
  .tabs button.on { background: rgba(60, 210, 255, 0.1); }
  .tabs span { font-size: 15px; }
  .tabs .dot { top: 14px; right: 14px; }
  .view.active, .sg:not(.hidden), .pg:not(.hidden) { column-count: 2; column-gap: 16px; }
  .view.active > .sg, .view.active > .pg { column-span: all; }
  .view.active:has(> .sg), .view.active:has(> .pg) { column-count: 1; }
  .span { column-span: all; }
  .grid { grid-template-columns: repeat(4, 1fr); }
  .isles { grid-template-columns: repeat(3, 1fr); }
  .hero-ring { width: 150px; height: 150px; }
  .hero-n { font-size: 64px; }
  .sheet-card { max-width: 720px; left: 50%; right: auto; transform: translateX(-50%); bottom: 4vh; border-radius: 22px; max-height: 90vh; animation: none; }
  .sheet-grip { display: none; }
  .ptr { display: none; }
}
@media (min-width: 1500px) { .grid { grid-template-columns: repeat(8, 1fr); } }
