:root {
    --bg: #0b0f1a;
    --bg-2: #0e1322;
    --surface: #141a2b;
    --surface-2: #1b2236;
    --border: #232b3f;
    --text: #eef1f7;
    --muted: #a3acc0;
    --accent: #6d5efc;
    --accent-2: #8b7bff;
    --rot: #e63946;
    --blau: #2563eb;
    --kampf: #1e7a44;
    --ok: #2a9d8f;
    --warn: #e9c46a;
    --err: #f43f5e;
    --radius: 16px;
    --radius-sm: 11px;
    --shadow: 0 10px 30px -14px rgba(0,0,0,.55);
    --sidebar-w: 264px;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

body {
    margin: 0;
    font-family: system-ui, "Segoe UI", Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
}

a { color: var(--accent-2); text-decoration: none; }
a:hover { text-decoration: underline; }

body.is-app { display: grid; grid-template-columns: var(--sidebar-w) 1fr; min-height: 100vh; }
.main-wrap { min-width: 0; display: flex; flex-direction: column; min-height: 100vh; }

.sidebar {
    background: var(--bg-2); border-right: 1px solid var(--border);
    display: flex; flex-direction: column; gap: 4px; padding: 16px 12px;
    position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.sidebar .brand { display: flex; align-items: center; gap: 10px; padding: 6px 8px 12px; font-weight: 700; font-size: 1.05rem; color: var(--text); }
.sidebar .brand:hover { text-decoration: none; }
.brand .mark {
    width: 30px; height: 30px; border-radius: 9px; flex: 0 0 auto; display: block;
}
.nav-group { font-size: .68rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); opacity: .75; padding: 14px 10px 4px; }

.nav-grp { margin-top: 6px; }
.nav-grp-head {
    display: flex; align-items: center; gap: 6px; width: 100%;
    background: none; border: 0; cursor: pointer; text-align: left;
    font-size: .68rem; font-weight: 600; text-transform: uppercase; letter-spacing: .12em;
    color: var(--muted); opacity: .8; padding: 10px 10px 4px; font-family: inherit;
}
.nav-grp-head:hover { color: var(--text); opacity: 1; }
.nav-chev { width: 13px; height: 13px; margin-left: auto; flex: 0 0 auto; transition: transform .18s ease; }
.nav-grp.closed .nav-chev { transform: rotate(-90deg); }
.nav-grp.closed .nav-grp-body { display: none; }
.nav-grp-badge { margin-left: 4px !important; }
.nav-grp:not(.closed) .nav-grp-badge { display: none; }
.nav-grp-body .nav-item { padding-left: 18px; }

@media (min-width: 1025px) {
    body.nav-slim { --sidebar-w: 64px; }
    body.nav-slim .sidebar .nav-lbl { display: none; }
    body.nav-slim .sidebar .nav-grp-head { display: none; }
    body.nav-slim .sidebar .nav-grp.closed .nav-grp-body { display: block; }
    body.nav-slim .sidebar .nav-item { justify-content: center; padding-left: 10px; }
    body.nav-slim .sidebar .nav-badge { position: absolute; transform: translate(10px, -8px); }
    body.nav-slim .sidebar .nav-item { position: relative; }
    body.nav-slim .side-cta { padding: 11px 8px; }
    body.nav-slim .sidebar .brand { justify-content: center; padding-left: 0; }
    body.nav-slim .nav-slim-toggle { justify-content: center; }
}
.nav-item {
    display: flex; align-items: center; gap: 11px; padding: 10px 12px;
    border-radius: var(--radius-sm); color: var(--muted); font-weight: 500; font-size: .92rem;
    min-height: 44px;
}
.nav-item:hover { background: var(--surface); color: var(--text); text-decoration: none; }
.nav-item.active { background: var(--surface-2); color: var(--text); box-shadow: inset 3px 0 0 var(--accent); }
.nav-ic { width: 22px; height: 22px; flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; }
.nav-emoji { font-size: 1.12rem; line-height: 1; }
.nav-item .nav-badge { margin-left: auto; background: var(--err); color: #fff; font-size: .7rem; font-weight: 700; padding: 1px 7px; border-radius: 8px; }
.nav-item.active .nav-badge { background: var(--err); }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 8px; padding-top: 14px; }
.side-cta {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; font-weight: 600;
    padding: 11px; border-radius: 12px;
}
.side-cta:hover { filter: brightness(1.08); text-decoration: none; }
.side-cta .nav-ic { width: 18px; height: 18px; }
.side-link { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: .82rem; padding: 6px 8px; }
.side-link:hover { color: var(--text); text-decoration: none; }
.side-link .nav-ic { width: 16px; height: 16px; }

.appbar {
    display: flex; align-items: center; gap: 14px; padding: 12px 22px;
    border-bottom: 1px solid var(--border); position: sticky; top: 0; background: var(--bg); z-index: 8;
}
.appbar .burger { display: none; background: none; border: 0; color: var(--text); cursor: pointer; padding: 6px; border-radius: 9px; }
.appbar .burger svg { width: 24px; height: 24px; }
.appbar .page-title { font-weight: 600; font-size: 1rem; }
.appbar .spacer { flex: 1; }
.appbar .readonly { background: rgba(233,196,106,.16); color: var(--warn); border: 1px solid var(--warn); padding: 4px 10px; border-radius: 9px; font-size: .78rem; }
.appbar .acct { display: flex; align-items: center; gap: 10px; color: var(--text); }
.appbar .acct:hover { text-decoration: none; }
.appbar .avatar { width: 38px; height: 38px; border-radius: 11px; flex: 0 0 auto; background: linear-gradient(135deg, var(--accent), var(--accent-2)); display: flex; align-items: center; justify-content: center; font-weight: 700; color: #fff; font-size: .82rem; }
.appbar .acct .nm { font-weight: 600; font-size: .85rem; line-height: 1.15; }
.appbar .acct .rl { color: var(--muted); font-size: .78rem; }
.icon-btn { width: 38px; height: 38px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); color: var(--text); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.icon-btn:hover { background: var(--surface-2); }
.icon-btn svg { width: 18px; height: 18px; }

.ctx-bar { display: inline-flex; align-items: center; gap: 8px; min-width: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 6px 11px; }
.ctx-bar .ctx-turnier { display: inline-flex; align-items: center; gap: 7px; min-width: 0; color: var(--text); font-size: .85rem; font-weight: 600; }
.ctx-bar .ctx-turnier:hover { color: var(--accent-2); text-decoration: none; }
.ctx-bar .nav-ic { width: 16px; height: 16px; flex: 0 0 auto; color: var(--accent-2); }
.ctx-bar .ctx-name { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ctx-bar .ctx-matte { color: var(--muted); font-weight: 500; white-space: nowrap; }
.ctx-bar .ctx-switch { font-size: .78rem; color: var(--muted); border-left: 1px solid var(--border); padding-left: 8px; white-space: nowrap; }
.ctx-bar .ctx-switch:hover { color: var(--accent-2); text-decoration: none; }
@media (max-width: 1100px) { .appbar .ctx-bar { display: none; } }

.appsearch { position: relative; flex: 1; max-width: 440px; display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 0 12px; }
.appsearch:focus-within { border-color: var(--accent); }
.appsearch .nav-ic { width: 18px; height: 18px; color: var(--muted); }
.appsearch input { width: 100%; border: 0; background: transparent; padding: 9px 0; color: var(--text); font: inherit; font-size: .9rem; }
.appsearch input:focus { outline: none; }

.search-suggest { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 60; max-height: 70vh; overflow-y: auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: 0 18px 40px -14px rgba(0,0,0,.65); padding: 4px; }
.search-suggest .ss-group { font-size: .7rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); padding: 8px 10px 4px; }
.search-suggest .ss-item { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 8px; color: var(--text); text-decoration: none; }
.search-suggest .ss-item:hover, .search-suggest .ss-item.active { background: color-mix(in srgb, var(--accent) 16%, transparent); }
.search-suggest .ss-ic { flex: 0 0 auto; width: 1.4rem; text-align: center; font-size: .95rem; }
.search-suggest .ss-txt { min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.search-suggest .ss-name { font-size: .9rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.search-suggest .ss-name mark { background: transparent; color: var(--accent-2); font-weight: 800; }
.search-suggest .ss-sub { font-size: .76rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.search-suggest .ss-empty { padding: 12px 12px; color: var(--muted); font-size: .85rem; }
.search-suggest .ss-all { display: block; width: 100%; text-align: left; margin-top: 4px; padding: 9px 10px; border: 0; border-top: 1px solid var(--border); border-radius: 0 0 8px 8px; background: transparent; color: var(--accent-2); font: inherit; font-size: .82rem; font-weight: 600; cursor: pointer; }
.search-suggest .ss-all:hover { background: color-mix(in srgb, var(--accent) 12%, transparent); }

.ladder-tabs { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.1rem; }

.kw-phasen { margin-bottom: 1.25rem; }
.kw-tabs { display: flex; align-items: center; gap: .2rem; border-bottom: 1px solid var(--border); margin-bottom: 1rem; }
.kw-tab { background: none; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px;
    padding: .55rem .9rem; font: inherit; font-size: .92rem; color: var(--muted); cursor: pointer; border-radius: 0; }
.kw-tab:hover { color: var(--text); }
.kw-tab.on { color: var(--text); border-bottom-color: var(--accent); }
.kw-tabs-hint { margin-left: auto; }
.kw-phasen:not(.js-an) .kw-tabs { display: none; }
@media (max-width: 640px) {
    .kw-tabs-hint { display: none; }
    .kw-tab { padding: .55rem .6rem; font-size: .88rem; }
}

.kw-panel.is-hidden { display: none; }
.kw-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: .9rem; }
.kw-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    padding: .85rem 1rem; box-shadow: var(--shadow); }
.kw-card.kw-primaer { border-color: var(--accent); }
.kw-titel { font-size: 1rem; font-weight: 600; margin-bottom: .15rem; }
.kw-sub { color: var(--muted); font-size: .8rem; margin-bottom: .55rem; }
.kw-links { display: flex; flex-wrap: wrap; gap: .15rem .7rem; font-size: .88rem; }
.kw-links a { line-height: 1.9; }
.kw-inline { margin-top: .5rem; }

.kw-status { margin-top: .55rem; padding-top: .5rem; border-top: 1px solid var(--border); font-size: .8rem; }
.kw-ok   { color: var(--ok); }
.kw-warn { color: var(--warn); }
.kw-info { color: var(--muted); }
.kw-aus  { color: var(--muted); font-style: italic; }

.kw-selten { margin-top: .9rem; background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: .6rem .9rem; }
.kw-selten > summary { cursor: pointer; color: var(--muted); font-size: .88rem; }
.kw-selten > summary:hover { color: var(--text); }
.kw-selten-body { padding-top: .7rem; }
.kw-selten-links { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
.kw-selten-block { margin-top: .9rem; padding-top: .8rem; border-top: 1px solid var(--border); }

.hp-bau { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1rem; }
.hp-bau-block { border: 1px solid var(--border); border-radius: var(--radius-sm);
    background: var(--surface-2); padding: .9rem 1rem 1rem; }
.hp-bau-kopf { display: flex; align-items: flex-start; gap: .6rem; margin-bottom: .7rem; }
.hp-nr { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 50%; background: var(--accent);
    color: #fff; font-size: .78rem; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.hp-bau-stand { margin: .65rem 0 0; padding-top: .5rem; border-top: 1px dashed var(--border);
    overflow-wrap: anywhere; }

.feat-group { margin: 0 0 .35rem; }
.feat-group-head { display: flex; align-items: center; gap: .55rem; width: 100%; padding: .55rem .4rem;
    background: none; border: 0; border-bottom: 1px solid var(--border); color: var(--text);
    font: inherit; text-align: left; cursor: pointer; border-radius: 8px 8px 0 0; }
.feat-group-head:hover { background: var(--surface-2); }
.feat-group-name { flex: 1; font-weight: 600; font-size: .95rem; }
.feat-chev { width: 16px; height: 16px; color: var(--muted); flex: 0 0 auto; transition: transform .16s ease; }
.feat-group.closed .feat-chev { transform: rotate(-90deg); }
.feat-group.closed .feat-body { display: none; }
.feat-group.is-hidden, .feat-item.is-hidden { display: none; }
.feat-body { padding: .25rem 0 .5rem; }
.feat-item { display: flex; align-items: flex-start; gap: .6rem; padding: .5rem .6rem .5rem 1.6rem; border-radius: 8px; }
.feat-item:hover { background: var(--surface-2); }
.feat-item input { width: auto; margin: .2rem 0 0; flex: 0 0 auto; }
.feat-item .switch { margin-top: .12rem; }
.feat-item.is-planned { opacity: .6; }
.feat-desc { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.feat-tools { display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; margin: .2rem 0 .9rem; }
.feat-search { flex: 1; min-width: 200px; }
.feat-search input { width: 100%; }
.feat-chips { display: flex; gap: .35rem; flex-wrap: wrap; }
.feat-chip { font: inherit; font-size: .82rem; padding: .28rem .7rem; border-radius: 999px;
    border: 1px solid var(--border); background: var(--surface); color: var(--muted); cursor: pointer; }
.feat-chip:hover { border-color: var(--accent-2); color: var(--text); }
.feat-chip.on { border-color: var(--accent); background: rgba(109,94,252,.16); color: var(--text); }

.feat-save { display: flex; align-items: center; gap: .6rem; margin-top: .8rem; }
.feat-save.is-sticky { position: sticky; bottom: 0; padding: .7rem .2rem .2rem;
    background: linear-gradient(to top, var(--surface) 72%, transparent); }
.feat-save.has-changes { border-top: 1px solid var(--accent); }
.feat-save-info { flex: 1; font-size: .85rem; color: var(--accent-2); }
.feat-text { display: flex; flex-direction: column; gap: .1rem; }
.feat-name { font-weight: 600; font-size: .92rem; display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; }

.searchbar { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 4px 4px 4px 14px; margin-bottom: 1.25rem; max-width: 640px; }
.searchbar .nav-ic { width: 20px; height: 20px; color: var(--muted); flex: 0 0 auto; }
.searchbar input { flex: 1; border: 0; background: transparent; padding: 8px 0; color: var(--text); font: inherit; }
.searchbar input:focus { outline: none; }

.ui-overlay { display: none; }

.topbar {
    display: flex; align-items: center; gap: 1.5rem;
    padding: 0 1.5rem; height: 58px;
    background: var(--bg-2); border-bottom: 1px solid var(--border);
    position: sticky; top: 0; z-index: 10;
}
.topbar .brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.1rem; color: var(--text); }
.brand:hover { text-decoration: none; }
.brand-mark { color: var(--accent); }
.mainnav { display: flex; gap: .25rem; flex: 1; }
.mainnav a { color: var(--muted); padding: .45rem .9rem; border-radius: var(--radius-sm); font-size: .95rem; }
.mainnav a:hover { background: var(--surface); color: var(--text); text-decoration: none; }
.mainnav a.active { background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; }

.pub-hero { text-align: center; padding: .4rem 0 1.1rem; }
.pub-hero h1 { margin-bottom: .15rem; }
.pub-hero p { margin: 0 0 .8rem; }
.pub-chips { display: flex; gap: .45rem; justify-content: center; flex-wrap: wrap; align-items: center; }
.pub-chip { padding: .32rem .95rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--muted); font: inherit; font-size: .84rem; cursor: pointer; }
.pub-chip:hover { color: var(--text); }
.pub-chip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.pub-chips input[type=search] { width: auto; min-width: 210px; padding: .35rem .8rem; border-radius: 999px; font-size: .84rem; }
.pub-sec { display: flex; align-items: center; gap: .7rem; margin: 1.3rem 0 .6rem; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.pub-sec-ln { flex: 1; height: 1px; background: var(--border); }
.pub-row { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: .85rem 1.05rem; margin-bottom: .6rem; box-shadow: var(--shadow); }
.pub-row.is-live { border-color: var(--rot); }
.pub-row.is-done { opacity: .88; }
.pub-row-main { display: flex; align-items: center; gap: .9rem; flex-wrap: wrap; }
.pub-logo { width: 40px; height: 40px; border-radius: 9px; object-fit: contain; background: var(--surface-2); flex: 0 0 auto; }
.pub-row-name { display: flex; align-items: center; gap: .55rem; flex-wrap: wrap; font-size: 1.02rem; }
.pub-row-name a { color: var(--text); }
.pub-row-meta { display: flex; gap: .9rem; flex-wrap: wrap; color: var(--muted); font-size: .82rem; margin-top: .15rem; align-items: center; }
.pub-row-meta .nav-ic { width: 14px; height: 14px; vertical-align: -2px; }
.pub-row-actions { display: flex; gap: .45rem; flex-wrap: wrap; margin-left: auto; }
.pub-cnt { background: var(--surface-2); border-radius: 8px; padding: .1rem .6rem; font-size: .74rem; color: var(--muted); white-space: nowrap; }
.pub-live-badge { display: inline-flex; align-items: center; gap: .35rem; background: rgba(230,57,70,.16); color: #ff8a94; border-radius: 999px; padding: .1rem .65rem; font-size: .74rem; font-weight: 600; }
.pub-live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--rot); animation: pubpulse 1.4s infinite; }
@keyframes pubpulse { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }
.pub-rank-row { display: flex; align-items: center; gap: .6rem; padding: .28rem 0; font-size: .92rem; }
.pub-rank { width: 22px; height: 22px; border-radius: 6px; background: var(--surface-2); display: inline-flex; align-items: center; justify-content: center; font-size: .72rem; color: var(--muted); flex: 0 0 auto; font-weight: 600; }
.pub-rank.r1 { background: rgba(233,196,106,.22); color: #f0d99a; }
.pub-rank.r2 { background: rgba(163,172,192,.2); color: #dbe2f0; }
.pub-rank.r3 { background: rgba(230,140,60,.18); color: #f0b287; }
@media (max-width: 640px) {
    .pub-row-actions { margin-left: 0; width: 100%; }
}

.pub-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.1rem; }
.pub-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.15rem 1.25rem; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: .75rem; }
.pub-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: .6rem; }
.pub-card-top h3 { margin: 0; font-size: 1.05rem; }
.pub-badges { display: flex; flex-direction: column; align-items: flex-end; gap: .35rem; flex: 0 0 auto; }
.badge-stack { display: flex; flex-wrap: wrap; gap: .35rem; }
.pub-meta { display: flex; flex-direction: column; gap: .35rem; color: var(--muted); font-size: .9rem; }
.pub-meta .em { margin-right: .4rem; display: inline-flex; vertical-align: -3px; }
.pub-meta .em .nav-ic { width: 16px; height: 16px; }
.pub-actions { display: flex; gap: .5rem; margin-top: auto; flex-wrap: wrap; }
.topbar-right { display: flex; align-items: center; gap: .75rem; }
.user { color: var(--muted); font-size: .85rem; }

.container { max-width: 1100px; margin: 0 auto; padding: 1.75rem 1.5rem 4rem; }
.container-narrow { max-width: 460px; }
.content { max-width: 1280px; width: 100%; margin: 0 auto; padding: 22px 24px 48px; }
.appfooter { text-align: center; color: var(--muted); font-size: .8rem; padding: 1.5rem; }

.fp-bar { display: flex; flex-direction: column; align-items: center; gap: .5rem; padding: 1.25rem 1.5rem 0; }
.fp-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .55rem; }
.fp-item { display: inline-flex; align-items: center; border-radius: 6px; padding: .3rem .5rem; opacity: .8; transition: opacity .15s ease; }
.fp-item:hover, .fp-item:focus-visible { opacity: 1; text-decoration: none; }
.fp-item img { display: block; height: 24px; width: auto; max-width: 120px; object-fit: contain; }
.fp-chip { background: #f4f5f8; }
@media (max-width: 560px) { .fp-item img { height: 20px; max-width: 96px; } }

h1 { font-size: 1.5rem; margin: 0 0 1rem; }
h2 { font-size: 1.15rem; margin: 1.5rem 0 .75rem; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.page-head h1 { margin: 0; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }

.card {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 1.25rem 1.4rem; margin-bottom: 1.25rem; box-shadow: var(--shadow);
}
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem 1.4rem; box-shadow: var(--shadow); }
.stat .num { font-size: 1.9rem; font-weight: 700; letter-spacing: .3px; }
.stat .lbl { color: var(--muted); font-size: .9rem; margin-top: 2px; }
.stat .sub { color: var(--muted); font-size: .78rem; margin-top: 6px; opacity: .85; }
.trend { display: inline-flex; align-items: center; gap: 5px; margin-top: 12px; font-size: .76rem; font-weight: 600; padding: 4px 9px; border-radius: 9px; background: rgba(52,211,153,.14); color: #34d399; }
.trend.down { background: rgba(244,63,94,.16); color: var(--err); }

.pills { display: inline-flex; gap: 6px; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 4px; }
.pills .pill { padding: 6px 12px; border-radius: 8px; font-size: .8rem; color: var(--muted); cursor: pointer; font-weight: 500; }
.pills .pill.active { background: var(--accent); color: #fff; }

.card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.card-head h2 { margin: 0; }
.card-head .pills { margin-left: auto; }
.dash-lower { display: grid; grid-template-columns: 1.6fr 1fr; gap: 1.25rem; }
.dash-lower .card { margin-bottom: 0; }

.chart { display: flex; align-items: flex-end; gap: 10px; height: 220px; padding-top: 10px; }
.chart .col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 8px; height: 100%; position: relative; }
.chart .stem { width: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; }
.chart .bar { width: 3px; min-height: 2px; background: linear-gradient(var(--accent), transparent); border-radius: 3px; }
.chart .dot { width: 11px; height: 11px; border-radius: 50%; background: var(--accent-2); margin-bottom: -6px; position: relative; z-index: 2; box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent), 0 0 16px 1px var(--accent); }
.chart .mo { font-size: .72rem; color: var(--muted); }
.chart .col.peak .dot { background: #fff; box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent) 35%, transparent), 0 0 22px 3px var(--accent); }
.chart .tip { position: absolute; top: -4px; left: 50%; transform: translate(-50%, -100%); background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 6px 10px; font-size: .72rem; white-space: nowrap; display: none; z-index: 3; box-shadow: var(--shadow); }
.chart .col:hover .tip { display: block; }
.chart .tip b { color: var(--text); } .chart .tip span { color: var(--muted); }

.rank { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--border); }
.rank:last-child { border-bottom: 0; }
.rank .nm { flex: 1; min-width: 0; }
.rank .nm .s { color: var(--muted); font-size: .78rem; }
.rank .num { font-weight: 700; font-variant-numeric: tabular-nums; }

.arts-picker { margin: .2rem 0 .6rem; }
.arts-picker > summary { display: inline-flex; align-items: center; gap: .4rem; list-style: none; cursor: pointer; width: auto; }
.arts-picker > summary::-webkit-details-marker { display: none; }
.arts-list { margin-top: .6rem; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: .4rem; }
.arts-list-grad { grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); }
.arts-item { display: flex; align-items: center; gap: .5rem; margin: 0; padding: .4rem .6rem; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.arts-item input[type=checkbox] { width: auto; flex: 0 0 auto; }
.arts-item.on { border-color: var(--accent); }
.arts-name { flex: 1; font-size: .9rem; }
.arts-grad { width: 120px !important; flex: 0 0 auto; padding: .3rem .5rem !important; }
.arts-grad:disabled { opacity: .45; }
select.arts-grad { width: 148px !important; }
.arts-grad-none { width: 148px; flex: 0 0 auto; text-align: right; font-size: .8rem; }
.arts-count { color: var(--muted); font-weight: 600; }
.arts-chips { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .2rem; }

.profile-photo { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; }
.pp-pic { flex: 0 0 auto; }
.pp-pic img, .pp-placeholder { width: 96px; height: 96px; border-radius: 16px; object-fit: cover; border: 1px solid var(--border); }
.pp-placeholder { display: flex; align-items: center; justify-content: center; font-size: 1.8rem; font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--accent), var(--accent-2)); }
.pp-side { flex: 1; min-width: 220px; }
.pp-form { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; margin: .4rem 0; }
.pp-form input[type=file] { width: auto; flex: 1; min-width: 180px; }
.pp-upload-btn { display: inline-flex; align-items: center; cursor: pointer; }
.pp-upload-btn .pp-file { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; clip: rect(0 0 0 0); }
.pp-form-confirm { flex-direction: column; align-items: flex-start; }
.pp-uploadrow { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.pp-consent { display: flex; gap: .5rem; align-items: flex-start; max-width: 540px; font-size: .85rem; cursor: pointer; line-height: 1.35; }
.pp-consent input[type=checkbox] { flex: 0 0 auto; margin-top: .15rem; width: auto; }
.pp-fname { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pp-note { margin: .1rem 0 .6rem; }
.pp-hint { margin: .1rem 0 0; }
.foto-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.foto-card { display: flex; flex-direction: column; gap: .75rem; }
.foto-card-pic { align-self: center; }
.foto-card-pic img { width: 180px; height: 180px; max-width: 100%; border-radius: 12px; object-fit: cover; border: 1px solid var(--border); background: var(--surface-2); }
.foto-card-body { display: flex; flex-direction: column; gap: .4rem; }
.foto-reject { margin-top: .1rem; }
.foto-reject > summary { display: inline-flex; list-style: none; }
.foto-reject > summary::-webkit-details-marker { display: none; }
.foto-reject-form { margin-top: .5rem; }
.foto-lock-btn { color: var(--muted); }
.foto-lock-row + .foto-lock-row { border-top: 1px solid var(--border); padding-top: .5rem; margin-top: .5rem; }
.progress { height: 6px; border-radius: 6px; background: var(--surface-2); overflow: hidden; margin-top: 6px; }
.progress > i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }

.news-overlay { position: fixed; inset: 0; background: rgba(5,8,15,.62); display: flex; align-items: center; justify-content: center; z-index: 100; padding: 1rem; }
.news-modal { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 30px 60px -20px rgba(0,0,0,.7); max-width: 520px; width: 100%; max-height: 85vh; overflow: auto; padding: 1.4rem 1.5rem; }
.news-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.news-kicker { display: inline-block; font-size: .7rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #fff; background: linear-gradient(135deg, var(--accent), var(--accent-2)); padding: 3px 10px; border-radius: 8px; margin-bottom: .55rem; }
.news-head h2 { margin: 0; font-size: 1.15rem; }
.news-x { background: none; border: 0; color: var(--muted); font-size: 1.05rem; cursor: pointer; padding: 4px 9px; border-radius: 8px; }
.news-x:hover { background: var(--surface-2); color: var(--text); }
.news-list { margin: .25rem 0 1.25rem; padding-left: 0; display: flex; flex-direction: column; gap: .5rem; }
.news-list li { line-height: 1.5; }

.patch-gruppe { margin: .9rem 0 .2rem; font-size: .78rem; font-weight: 700;
    letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.patch-gruppe:first-child { margin-top: .4rem; }
.patch-punkte { margin: 0; padding-left: 1.15rem; line-height: 1.55; }
.patch-punkte > li { margin-bottom: .3rem; }
.patch-unter { margin: .2rem 0 .45rem; padding-left: 1.05rem; list-style: circle; }
.patch-unter > li { color: var(--muted); font-size: .9rem; margin-bottom: .15rem; }
.news-actions { display: flex; justify-content: flex-end; gap: .6rem; flex-wrap: wrap; }

table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .65rem .8rem; border-bottom: 1px solid var(--border); vertical-align: top; }
th { color: var(--muted); font-weight: 600; font-size: .8rem; text-transform: uppercase; letter-spacing: .03em; }
tr:hover td { background: var(--surface-2); }
.table-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: auto; box-shadow: var(--shadow); }
.empty { padding: 2rem; text-align: center; color: var(--muted); }

.field { margin-bottom: 1rem; }
.field label { display: block; margin-bottom: .35rem; font-size: .9rem; color: var(--muted); }
input, select, textarea {
    width: 100%; padding: .6rem .75rem; background: var(--bg);
    border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text); font: inherit;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); border-color: transparent; }
.row { display: flex; gap: 1rem; flex-wrap: wrap; }
.row .field { flex: 1; min-width: 120px; }
.form-actions { display: flex; gap: .75rem; margin-top: 1rem; align-items: center; flex-wrap: wrap; }

.btn {
    display: inline-flex; align-items: center; gap: .4rem;
    padding: .6rem 1.05rem; border: 1px solid transparent; border-radius: var(--radius-sm);
    background: var(--accent); color: #fff; font: inherit; cursor: pointer; text-decoration: none; white-space: nowrap;
    min-height: 44px;
}
.btn:hover { filter: brightness(1.1); text-decoration: none; }
.btn-primary { background: var(--accent); border-color: transparent; color: #fff; }
.btn-secondary { background: var(--surface-2); border-color: var(--border); color: var(--text); }
.btn-ghost { background: transparent; border-color: var(--border); color: var(--text); }
.btn-danger { background: var(--err); border-color: transparent; color: #fff; }
.btn-sm { padding: .38rem .7rem; font-size: .85rem; min-height: 34px; }
.inline { display: inline; }

:where(a, button, [role="button"], summary, [tabindex]):focus-visible {
    outline: 2px solid var(--accent-2); outline-offset: 2px;
}
@media (pointer: coarse) {
    .btn-sm { min-height: 44px; }
    .icon-btn { width: 44px; height: 44px; }
    .tabbar .tab, .pub-chip, .chip-btn, .filter-chip { min-height: 44px; }
    input:not([type=checkbox]):not([type=radio]):not([type=hidden]):not([type=range]),
    select, textarea { min-height: 44px; }
    .topbar .mainnav a, .pub-nav a { min-height: 44px; display: inline-flex; align-items: center; }
}

.empty .empty-title { display: block; color: var(--text); font-weight: 600; margin-bottom: .25rem; }
.empty .btn { margin-top: .9rem; }

.loading { display: inline-flex; align-items: center; gap: .5rem; color: var(--muted); }
.loading::before {
    content: ""; width: 1em; height: 1em; flex: 0 0 auto;
    border: 2px solid var(--border); border-top-color: var(--accent);
    border-radius: 50%; animation: map-spin .8s linear infinite;
}
@keyframes map-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .loading::before { animation-duration: 1.6s; } }

.idk-menu { position: relative; display: inline-block; }
.idk-menu > summary { list-style: none; cursor: pointer; }
.idk-menu > summary::-webkit-details-marker { display: none; }
.idk-menu > summary::marker { content: ""; }
.idk-menu .idk-menu-pop {
    position: absolute; z-index: 30; top: calc(100% + .35rem); left: 0;
    display: flex; flex-direction: column; gap: .35rem; min-width: 240px; padding: .45rem;
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
    box-shadow: 0 8px 24px rgba(0,0,0,.45);
}
.idk-menu .idk-menu-pop .btn { text-align: left; }

.cmd-head { align-items: flex-start; }
.cmd-title { display: flex; align-items: center; gap: .55rem; flex-wrap: wrap; margin-bottom: .25rem; }
.cmd-actions { display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; }
@media (max-width: 640px) {
    .page-head.cmd-head { flex-wrap: wrap; }
    .cmd-actions { flex: 1 1 100%; }
    .cmd-actions > .btn { flex: 1 1 100%; justify-content: center; }
}
.cmd-more > summary { min-width: 44px; justify-content: center; font-weight: 700; }
.cmd-more .idk-menu-pop { right: 0; left: auto; }

.ctx-row { display: flex; align-items: baseline; gap: 1.4rem; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: .7rem 1.1rem; margin-bottom: 1rem; }
.ctx-kpi { color: var(--muted); font-size: .88rem; display: inline-flex; gap: .45rem; align-items: baseline; white-space: nowrap; }
.ctx-kpi b { color: var(--text); font-size: 1.02rem; }
.ctx-kpi b.ok { color: var(--ok); }
.ctx-kpi-right { margin-left: auto; }

.cmd-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 1rem; align-items: start; }
@media (max-width: 1100px) { .cmd-grid { grid-template-columns: 1fr; } }
.cmd-main, .cmd-side { min-width: 0; }
.head-right { margin-left: auto; }

.prep-bar { height: 8px; border-radius: 999px; background: var(--surface-2); overflow: hidden; margin: .1rem 0 1rem; }
.prep-bar span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.prep-next { display: flex; gap: .95rem; align-items: center; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .95rem 1.05rem; flex-wrap: wrap; }
.prep-nr { width: 2.3rem; height: 2.3rem; flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; font-weight: 800; background: color-mix(in srgb, var(--accent) 22%, transparent); border: 1px solid var(--accent); color: var(--accent-2); }
.prep-next-txt { flex: 1 1 260px; min-width: 0; display: flex; flex-direction: column; gap: .12rem; }
.prep-kicker { font-size: .68rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--accent-2); }
.prep-done { margin-top: .8rem; }
.prep-done > summary { cursor: pointer; color: var(--muted); font-size: .85rem; }
.prep-chips { display: flex; gap: .45rem; flex-wrap: wrap; margin-top: .55rem; }
.prep-chip { display: inline-flex; align-items: center; gap: .3rem; padding: .28rem .65rem; border-radius: 999px; font-size: .8rem; background: rgba(42,157,143,.14); border: 1px solid var(--ok); color: #9fe6db; }
.prep-later { margin: .7rem 0 0; }

.ready-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.ready-list li { display: flex; align-items: center; justify-content: space-between; gap: .7rem; padding: .5rem 0; border-bottom: 1px solid var(--border); font-size: .9rem; }
.ready-list li:last-child { border-bottom: 0; }
.ready-hint { margin-top: .7rem; padding: .65rem .8rem; border-radius: var(--radius-sm); border: 1px solid var(--border); font-size: .84rem; color: var(--muted); }
.ready-hint a { display: block; margin-top: .25rem; }
.ready-hint-ok   { border-color: var(--ok); background: rgba(42,157,143,.1); }
.ready-hint-warn { border-color: var(--warn); background: rgba(233,196,106,.1); }
.ready-hint-err  { border-color: var(--err); background: rgba(244,63,94,.1); }

.set-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1rem; }
.set-card { display: flex; flex-direction: column; gap: .35rem; color: var(--text); }
.set-card:hover { text-decoration: none; border-color: var(--accent); }
.set-card-head { display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.set-card .set-arrow { color: var(--accent-2); font-weight: 700; }
.set-meta { display: flex; gap: .4rem; flex-wrap: wrap; margin-top: .55rem; }
.badge-neutral { background: var(--surface-2); }

.mp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: .9rem; align-items: start; }
.mp-col { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .7rem .8rem; display: flex; flex-direction: column; gap: .55rem; }
.mp-col-head { display: flex; align-items: baseline; justify-content: space-between; gap: .6rem; border-bottom: 1px solid var(--border); padding-bottom: .45rem; }
.mp-block { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: .5rem .65rem; display: flex; flex-direction: column; gap: .15rem; }
.mp-block[draggable="true"] { cursor: grab; }
.mp-col.mp-drop { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--bg)); }
.mp-block-head { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.mp-block-cats { font-size: .78rem; color: var(--muted); border-left: 2px solid var(--border); padding-left: .45rem; margin-top: .1rem; line-height: 1.35; }

.form-sect { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .65rem .8rem; margin: 0 0 1rem; background: var(--bg); }
.form-sect > summary { cursor: pointer; font-weight: 600; display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; min-height: 28px; }
.form-sect > summary .muted { font-weight: 400; }

@media (max-width: 640px) {
    .tbl-cards table, .tbl-cards tbody, .tbl-cards tr, .tbl-cards td { display: block; width: 100%; }
    .tbl-cards thead { display: none; }
    .tbl-cards tr { border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); padding: .5rem .7rem; margin-bottom: .55rem; }
    .tbl-cards td { border: 0; padding: .15rem 0; }
    .tbl-cards td[data-label]::before { content: attr(data-label) ": "; color: var(--muted); font-size: .78rem; }
    .tbl-cards td:empty { display: none; }
}

.ab-filter { position: sticky; top: 0; z-index: 5; display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .5rem .7rem; margin: 0 0 1rem; }
.ab-filter input[type="search"] { flex: 1 1 200px; width: auto; }
.ab-filter select { width: auto; }
tr.ab-current { background: color-mix(in srgb, var(--accent) 14%, transparent); }
tr.ab-current td:first-child { position: relative; }
.ab-current-tag { display: inline-block; font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--accent-2); margin-right: .3rem; }

.msg-missing { margin: .4rem 0 0; padding-left: 1.1rem; font-size: .85rem; }
.msg-missing li { margin: .1rem 0; }

.tpl-workspace { display: grid; grid-template-columns: minmax(220px, 300px) minmax(0, 1fr); gap: 1rem; align-items: start; }
@media (max-width: 860px) { .tpl-workspace { grid-template-columns: 1fr; } }
.tpl-library { position: sticky; top: 1rem; max-height: calc(100vh - 2rem); overflow: auto; }
.tpl-lib-group { margin-bottom: .6rem; }
.tpl-lib-sport { font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: .5rem 0 .25rem; }
.tpl-lib-item { display: flex; justify-content: space-between; gap: .5rem; padding: .4rem .6rem; border-radius: var(--radius-sm); color: var(--text); text-decoration: none; border-left: 3px solid transparent; }
.tpl-lib-item:hover { background: var(--surface-2); text-decoration: none; }
.tpl-lib-item.on { background: color-mix(in srgb, var(--accent) 12%, transparent); border-left-color: var(--accent); font-weight: 600; }
.tpl-editor-col { min-width: 0; display: flex; flex-direction: column; gap: 1rem; }
.tpl-section .tpl-add { margin-top: .7rem; }

.club-workspace { display: grid; grid-template-columns: minmax(240px, 340px) minmax(0, 1fr); gap: 1rem; align-items: start; }
@media (max-width: 820px) { .club-workspace { grid-template-columns: 1fr; } }
.club-list-col { position: sticky; top: 1rem; }
.club-list { display: flex; flex-direction: column; max-height: 62vh; overflow: auto; margin: 0 -.35rem; }
.club-item { display: flex; flex-direction: column; gap: .1rem; padding: .5rem .6rem; border-radius: var(--radius-sm); color: var(--text); text-decoration: none; border-left: 3px solid transparent; }
.club-item:hover { background: var(--surface-2); text-decoration: none; }
.club-item.on { background: color-mix(in srgb, var(--accent) 12%, transparent); border-left-color: var(--accent); }
.club-item-name { font-weight: 600; }

.set-tab { cursor: pointer; text-align: left; font: inherit; }
.set-tab.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.set-card-title { display: inline-flex; align-items: center; gap: .45rem; font-weight: 600; }
.set-card-title svg { width: 18px; height: 18px; opacity: .8; }
.set-card-foot { margin-top: auto; padding-top: .5rem; }
.set-card-system { border-top: 3px solid var(--warn); }
.set-card-health { border-top: 3px solid var(--ok); }
.health-dot { display: inline-block; width: 11px; height: 11px; border-radius: 50%; box-shadow: 0 0 8px currentColor; }
.prot-table td { vertical-align: top; }
.prot-copy { background: none; border: 0; padding: 0; margin: 0; font: inherit; color: var(--text); text-align: left; cursor: copy; }
.prot-copy:hover { color: var(--accent-2); text-decoration: underline; }
.note-warn { border: 1px solid var(--warn); background: rgba(233,196,106,.1); border-radius: var(--radius-sm); padding: .7rem .9rem; margin: 0 0 1rem; font-size: .9rem; }

.wsp-switch { display: inline-flex; border: 1px solid var(--border); border-radius: 999px; overflow: hidden; margin-left: .6rem; flex: 0 0 auto; }
.wsp-btn { border: 0; background: none; color: var(--muted); font: inherit; font-size: .82rem; font-weight: 600; padding: .35rem .8rem; cursor: pointer; min-height: 0; }
.wsp-btn.on { background: color-mix(in srgb, var(--accent) 22%, transparent); color: var(--text); }
.wsp-btn:hover { color: var(--text); }
@media (max-width: 760px) { .wsp-switch { margin-left: .3rem; } .wsp-btn { padding: .3rem .55rem; } }

.ab-bar { margin-top: -.2rem; }
.ab-bar .tab { text-decoration: none; }
.ab-bar-right { margin-left: auto; display: inline-flex; align-items: center; gap: .4rem; padding: .35rem 0; }

.kc-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(200px, 1fr) minmax(200px, 1fr); gap: 1rem; align-items: start; margin-bottom: 1rem; }
@media (max-width: 1000px) { .kc-grid { grid-template-columns: 1fr; } }
.kc-current { border-left: 3px solid var(--accent); display: flex; flex-direction: column; gap: .55rem; }
.kc-zone { display: flex; flex-direction: column; gap: .3rem; }

.tag-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.tag-card { display: flex; flex-direction: column; gap: .55rem; border-top: 3px solid var(--border); }
.tag-card-start  { border-top-color: var(--ok); }
.tag-card-waage  { border-top-color: var(--warn); }
.tag-card-matten { border-top-color: var(--accent); }
.tag-card-foot { margin-top: auto; padding-top: .35rem; }
.tag-mats { display: flex; flex-direction: column; gap: .3rem; }
.tag-mat { display: flex; align-items: center; gap: .5rem; padding: .3rem 0; border-bottom: 1px solid var(--border); font-size: .9rem; }
.tag-mat:last-child { border-bottom: 0; }
.tag-mat-nr { font-weight: 600; min-width: 4.6rem; }
.tag-mat-next { margin-left: auto; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 12rem; }
.prep-chip-off { background: var(--surface-2); border-color: var(--border); color: var(--muted); }
.txt-ok { color: var(--ok); }
.txt-warn { color: var(--warn); }

.status-page { max-width: 460px; margin: 10vh auto 2rem; text-align: center; padding: 0 1rem; }
.status-page .status-code { font-size: 3rem; font-weight: 800; color: var(--accent-2); line-height: 1; }
.status-page h1 { font-size: 1.3rem; margin: .7rem 0 .4rem; }
.status-page .status-actions { display: flex; gap: .75rem; justify-content: center; margin-top: 1.2rem; flex-wrap: wrap; }

.flash { padding: .75rem 1rem; border-radius: var(--radius-sm); margin-bottom: 1rem; border: 1px solid; }
.flash-success { background: rgba(42,157,143,.15); border-color: var(--ok); }
.flash-error   { background: rgba(244,63,94,.15); border-color: var(--err); }
.flash-info    { background: rgba(233,196,106,.12); border-color: var(--warn); }

.badge { display: inline-block; padding: .15rem .55rem; border-radius: 999px; font-size: .78rem; border: 1px solid var(--border); }
.badge-rot { background: rgba(230,57,70,.18); border-color: var(--rot); color: #ffb3ba; }
.badge-blau { background: rgba(37,99,235,.18); border-color: var(--blau); color: #b3c7ff; }
.badge-ok { background: rgba(42,157,143,.18); border-color: var(--ok); }
.badge-warn { background: rgba(233,196,106,.18); border-color: var(--warn); }
.badge-kampf { background: rgba(30,122,68,.22); border-color: var(--kampf); color: #86efac; }
.badge-neu { background: rgba(37,99,235,.15); border-color: var(--blau); }
.badge-beta { display: inline-block; margin-left: 6px; padding: .05rem .4rem; border-radius: 999px; font-size: .62rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; vertical-align: middle; background: rgba(124,92,255,.18); border: 1px solid var(--accent); color: var(--accent); }
.status-geplant { color: var(--warn); }
.status-laufend { color: var(--accent-2); }
.status-abgeschlossen { color: var(--muted); }

.auth-card { margin-top: 8vh; }
.auth-card h1 { text-align: center; }
.auth-logo { display: block; margin: 0 auto .6rem; max-width: 300px; width: 100%; height: auto; }
.logo-mark-big { display: block; margin: 0 auto .6rem; border-radius: .9rem; }

.hilfe-kachel { display: block; color: inherit; text-decoration: none; transition: border-color .12s ease; }
.hilfe-kachel:hover, .hilfe-kachel:focus-visible { border-color: var(--accent); }
.hilfe-seite h2 { font-size: 1.1rem; margin: 1.1rem 0 .4rem; }
.hilfe-seite h3, .hilfe-seite h4 { font-size: 1rem; margin: .9rem 0 .3rem; }
.hilfe-seite > :first-child { margin-top: 0; }
.hilfe-seite p, .hilfe-seite li { line-height: 1.6; }
.hilfe-seite ul { padding-left: 1.2rem; margin: .35rem 0 .7rem; }
.hilfe-seite code { background: rgba(127, 127, 127, .18); border-radius: 4px; padding: .05rem .3rem; }

.toolbar { display: flex; gap: .75rem; margin-bottom: 1rem; align-items: center; flex-wrap: wrap; }
.toolbar .grow { flex: 1; }
.history-win { color: var(--ok); font-weight: 600; }
.history-loss { color: var(--err); }
code { background: var(--surface-2); padding: .1rem .35rem; border-radius: 4px; }

.pcols { display: flex; gap: 2.5rem; align-items: stretch; min-width: max-content; padding: .25rem 0; }
.pcol { display: flex; flex-direction: column; justify-content: space-around; gap: 1rem; min-width: 220px; }
.pcol h3 { text-align: center; color: var(--muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; margin: 0 0 .4rem; }
.pmatch {
    position: relative;
    background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,.2);
}
.pslot { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .5rem .7rem; }
.pslot + .pslot { border-top: 1px solid var(--border); }
.pslot .dot { width: .5rem; height: .5rem; border-radius: 50%; flex: 0 0 auto; }
.pslot.rot .dot { background: var(--rot); }
.pslot.blau .dot { background: var(--blau); }
.pslot span.nm { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pslot b { font-variant-numeric: tabular-nums; font-weight: 800; min-width: 1.4rem; text-align: center; }
.pslot.win { background: rgba(42,157,143,.16); }
.pslot.win span.nm { color: #bdf0e6; font-weight: 700; }
.pslot.tbd span.nm { color: var(--muted); font-style: italic; }

.pcol + .pcol .pmatch::before {
    content: ""; position: absolute; left: -1.3rem; top: 50%;
    width: 1.3rem; height: 2px; background: var(--border);
}
.pcol:not(:last-child) .pmatch::after {
    content: ""; position: absolute; right: -1.3rem; top: 50%;
    width: 1.3rem; height: 2px; background: var(--border);
}

.breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; font-size: .85rem; color: var(--muted); margin-bottom: .5rem; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--text); text-decoration: none; }
.breadcrumb .sep { color: var(--border); }
.breadcrumb .current { color: var(--text); font-weight: 600; }

.tag { display: inline-block; font-size: .72rem; font-weight: 600; line-height: 1.55; padding: 3px 10px; border-radius: 8px; white-space: nowrap; }
.tag-open, .tag-live { background: rgba(52,157,143,.18); color: #5fe3d0; }
.tag-soon { background: rgba(99,102,241,.20); color: #a9b2fb; }
.tag-paused { background: rgba(233,196,106,.16); color: #f0d99a; }
.tag-full { background: rgba(244,63,94,.18); color: #fb7185; }
.tag-done { background: var(--surface-2); color: var(--muted); }

.mmr-chip { display: inline-block; font-size: .68rem; font-weight: 700; line-height: 1.4; padding: 1px 7px; border-radius: 7px; vertical-align: middle; background: var(--surface-2); color: var(--muted); letter-spacing: .02em; }
.mmr-chip.mmr-high { background: rgba(52,157,143,.18); color: #5fe3d0; }
.mmr-chip.mmr-top { background: color-mix(in srgb, var(--accent) 22%, transparent); color: var(--accent-2); }

.badge-status { text-transform: capitalize; font-weight: 600; }
.badge-status-geplant { background: rgba(233,196,106,.18); border-color: var(--warn); color: #f0d99a; }
.badge-status-laufend { background: rgba(42,157,143,.20); border-color: var(--ok); color: #9fe6db; }
.badge-status-abgeschlossen { background: var(--surface-2); border-color: var(--border); color: var(--muted); }

.action-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1rem; margin-bottom: 1.25rem; }
.action-group { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem; box-shadow: var(--shadow); }
.action-group h3 { margin: 0 0 .1rem; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.action-group .grp-hint { margin: 0 0 .7rem; }
.action-group .toolbar { margin: 0; }
.action-group .idk-release { display: flex; align-items: center; flex-wrap: wrap; gap: .25rem .7rem; margin: .7rem 0 0; padding: .55rem .7rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; }
.action-group .idk-release .muted { flex-basis: 100%; margin: 0; }

.checklist { list-style: none; margin: .25rem 0 0; padding: 0; display: flex; flex-direction: column; gap: .5rem; }
.checklist li { display: flex; align-items: center; gap: .7rem; }
.checklist .mark { width: 1.5rem; height: 1.5rem; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: 700; flex: 0 0 auto; border: 1px solid var(--border); background: var(--bg); color: var(--muted); }
.checklist .done .mark { background: rgba(42,157,143,.2); border-color: var(--ok); color: #9fe6db; }
.checklist .step-label { color: var(--text); }
.checklist .done .step-label { color: var(--muted); }
.checklist .step-meta { color: var(--muted); font-size: .85rem; margin-left: auto; }
.checklist a.step-label:hover { text-decoration: underline; }

.badge-empty { background: rgba(244,63,94,.18); border-color: var(--err); color: #f3b5a3; }

.m0 { margin: 0 !important; }
.checkbox-inline { display: flex; align-items: center; gap: .5rem; margin: 0; }
.checkbox-inline input { width: auto; }

.switch { display: inline-flex; align-items: center; gap: .5rem; cursor: pointer; font-size: .88rem; color: var(--text); user-select: none; line-height: 1.2; }
.switch > input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; }
.switch .switch-track {
    position: relative; flex: 0 0 auto; width: 38px; height: 22px;
    background: var(--surface-2); border: 1px solid var(--border);
    border-radius: 999px; transition: background .16s ease, border-color .16s ease;
}
.switch .switch-thumb {
    position: absolute; top: 2px; left: 2px; width: 16px; height: 16px;
    background: var(--muted); border-radius: 50%;
    transition: transform .16s ease, background .16s ease;
}
.switch > input:checked + .switch-track { background: linear-gradient(135deg, var(--accent), var(--accent-2)); border-color: var(--accent); }
.switch > input:checked + .switch-track .switch-thumb { transform: translateX(16px); background: #fff; }
.switch > input:focus-visible + .switch-track { outline: 2px solid var(--accent-2); outline-offset: 2px; }
.switch:hover .switch-track { border-color: var(--accent-2); }
.switch.switch-sm .switch-track { width: 32px; height: 18px; }
.switch.switch-sm .switch-thumb { width: 13px; height: 13px; }
.switch.switch-sm > input:checked + .switch-track .switch-thumb { transform: translateX(14px); }

label.toggle { display: inline-flex; align-items: center; gap: .5rem; margin: 0; cursor: pointer; font-size: .88rem; line-height: 1.25; color: var(--text); }
label.toggle > input[type="checkbox"] {
    appearance: none; -webkit-appearance: none;
    flex: 0 0 auto; position: relative; width: 38px; height: 22px; margin: 0; padding: 0;
    background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px;
    cursor: pointer; transition: background .16s ease, border-color .16s ease; vertical-align: middle;
}
label.toggle > input[type="checkbox"]::before {
    content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px;
    border-radius: 50%; background: var(--muted); transition: transform .16s ease, background .16s ease;
}
label.toggle > input[type="checkbox"]:checked { background: linear-gradient(135deg, var(--accent), var(--accent-2)); border-color: var(--accent); }
label.toggle > input[type="checkbox"]:checked::before { transform: translateX(16px); background: #fff; }
label.toggle > input[type="checkbox"]:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; }
label.toggle:hover > input[type="checkbox"] { border-color: var(--accent-2); }
label.toggle.toggle-sm > input[type="checkbox"] { width: 32px; height: 18px; }
label.toggle.toggle-sm > input[type="checkbox"]::before { width: 13px; height: 13px; }
label.toggle.toggle-sm > input[type="checkbox"]:checked::before { transform: translateX(14px); }

.kchooser-bar { display: flex; align-items: stretch; gap: 10px; margin-bottom: .9rem; }
.kchooser-arrow { flex: 0 0 auto; width: 42px; border: 1px solid var(--border); background: var(--surface); color: var(--accent-2); border-radius: var(--radius-sm); font-size: 1.3rem; line-height: 1; cursor: pointer; }
.kchooser-arrow:hover:not(:disabled) { background: var(--surface-2); border-color: var(--accent-2); }
.kchooser-arrow:disabled { opacity: .3; cursor: default; }
.kchooser-tiles { flex: 1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.kchooser-tile { min-width: 0; text-align: left; cursor: pointer; color: var(--text); font: inherit; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 12px 13px; transition: border-color .15s, background .15s; }
.kchooser-tile:hover { border-color: var(--accent-2); }
.kchooser-tile.on { border: 2px solid var(--accent); background: var(--surface-2); padding: 11px 12px; }
.kchooser-thead { display: flex; justify-content: space-between; gap: 6px; }
.kchooser-tmain { min-width: 0; }
.kchooser-tname { font-weight: 500; font-size: .95rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kchooser-tmeta { color: var(--muted); font-size: .72rem; margin: .15rem 0 .55rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kchooser-tcount { display: inline-block; background: rgba(109, 94, 252, .18); color: var(--accent-2); font-size: .72rem; padding: .15rem .55rem; border-radius: 999px; }
.kchooser-chev { color: var(--accent); font-size: 1rem; line-height: 1; }
.kchooser-info { text-align: center; color: var(--muted); font-size: .75rem; margin-top: -.4rem; margin-bottom: .2rem; }
.kchooser-hint { background: var(--surface); border: 1px dashed var(--border); border-radius: 12px; padding: 1.1rem; text-align: center; color: var(--muted); font-size: .9rem; }
@media (max-width: 640px) { .kchooser-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.auth-card .sub { text-align: center; color: var(--muted); margin: -.4rem 0 1.2rem; }
.auth-card .below { text-align: center; margin-top: 1.1rem; font-size: .9rem; }

.suggest { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); padding: 1rem 1.1rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.suggest h3 { margin: 0 0 .35rem; font-size: 1rem; }
.suggest .members { display: flex; flex-wrap: wrap; gap: .4rem; margin: .5rem 0 .8rem; }
.suggest .chip { display: inline-flex; align-items: center; gap: .35rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: .25rem .7rem; font-size: .9rem; }
.suggest .chip .badge-empty { font-size: .7rem; }

.empty-cta { padding: 2rem 1rem; text-align: center; color: var(--muted); }
.empty-cta p { margin: 0 0 .9rem; }

@media (max-width: 1024px) {
    body.is-app { grid-template-columns: 1fr; }
    .sidebar {
        position: fixed; left: 0; top: 0; width: var(--sidebar-w); z-index: 60;
        transform: translateX(-100%); transition: transform .25s ease; box-shadow: var(--shadow);
    }
    body.drawer-open .sidebar { transform: none; }
    body.drawer-open .ui-overlay { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.55); z-index: 50; }
    .appbar .burger { display: inline-flex; }
}

@media (max-width: 900px) {
    .dash-lower { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
    .topbar { height: auto; flex-wrap: wrap; padding: .6rem 1rem; gap: .6rem 1rem; }
    .mainnav { flex-wrap: wrap; flex-basis: 100%; order: 3; }
    .action-groups { grid-template-columns: 1fr; }
    .appbar .acct .nm, .appbar .acct .rl { display: none; }
    .chart { gap: 5px; height: 190px; }
    .chart .mo { font-size: .62rem; }
}

@media (max-width: 680px) {
    .container { padding: 1.25rem 1rem 4rem; }
    .content { padding: 16px 14px 40px; }
    th, td { padding: .5rem .55rem; }
    .table-wrap table th:first-child,
    .table-wrap table td:first-child {
        position: sticky; left: 0; z-index: 1; background: var(--surface);
    }
    .table-wrap table thead th:first-child { z-index: 2; }
    .table-wrap table tr:hover td:first-child { background: var(--surface-2); }
}

@media (max-width: 720px) {
    .pcols { flex-direction: column; gap: 1rem; min-width: 0; }
    .pcol { min-width: 0; }
    .pcol h3 { text-align: left; }
    .pcol + .pcol .pmatch::before,
    .pcol:not(:last-child) .pmatch::after { display: none; }
}

#map-toasts { position: fixed; right: 16px; bottom: 16px; z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: flex-end; pointer-events: none; }
.map-toast { background: var(--surface-2); border: 1px solid var(--ok); color: var(--text); font-size: .85rem; padding: 9px 14px; border-radius: 10px; max-width: 340px; opacity: 0; transform: translateY(6px); transition: all .25s ease; box-shadow: var(--shadow); }
.map-toast.is-error { border-color: var(--err); }
.map-toast.show { opacity: 1; transform: none; }
.map-toast.has-action { pointer-events: auto; display: flex; align-items: center; gap: .8rem; }
.map-toast-act { background: none; border: 0; color: var(--accent-2); font: inherit; font-weight: 700; cursor: pointer; padding: .2rem .1rem; min-height: 0; }
.map-toast-act:hover { text-decoration: underline; }

.map-modal-ov { position: fixed; inset: 0; background: rgba(5,8,15,.62); z-index: 150; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.map-modal { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 30px 60px -20px rgba(0,0,0,.7); max-width: 420px; width: 100%; padding: 1.2rem 1.35rem; }
.map-modal-title { font-weight: 600; font-size: 1.02rem; margin-bottom: .5rem; }
.map-modal-text { color: var(--muted); font-size: .9rem; margin-bottom: 1rem; display: flex; flex-direction: column; gap: .15rem; }
.map-modal-actions { display: flex; justify-content: flex-end; gap: .6rem; }

.stack-0 { margin: 0 !important; }
.stack-1 { margin-bottom: .5rem; }
.stack-2 { margin-bottom: 1rem; }
.stack-3 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: .5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 1.5rem; }
.flex { display: flex; gap: .6rem; align-items: center; }
.flex-wrap { flex-wrap: wrap; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.flex-end { display: flex; justify-content: flex-end; gap: .6rem; }
.grow { flex: 1; min-width: 0; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
@media (max-width: 760px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }
.w-90 { max-width: 90px; } .w-120 { max-width: 120px; } .w-160 { max-width: 160px; } .w-240 { max-width: 240px; }
.ta-r { text-align: right; } .ta-c { text-align: center; }
.text-ok { color: var(--ok); } .text-err { color: var(--err); } .text-warn { color: var(--warn); }
.nowrap { white-space: nowrap; }
.field-inline { flex: 0 0 auto; }
.hr-t { border-top: 1px solid var(--border); padding-top: 1rem; margin-top: 1rem; }

.tabbar { display: flex; gap: 2px; border-bottom: 1px solid var(--border); margin: 0 0 1.1rem; flex-wrap: wrap; }
.tabbar .tab { padding: .55rem 1rem; border: 0; background: none; color: var(--muted); font: inherit; font-size: .92rem; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; display: inline-flex; align-items: center; gap: .45rem; }
.tabbar .tab:hover { color: var(--text); }
.tabbar .tab.on { color: var(--text); border-bottom-color: var(--accent); font-weight: 600; }
.tabbar .tab .tcount { background: var(--surface-2); border-radius: 999px; padding: 0 .5rem; font-size: .72rem; color: var(--muted); line-height: 1.6; }
.tabbar a.tab:hover { text-decoration: none; }

.kbadge { display: inline-flex; align-items: center; gap: .35rem; border-radius: 999px;
          padding: .18rem .7rem; font-size: .8rem; font-weight: 700; border: 1px solid; }
.kbadge-bund { background: rgba(231,180,22,.14); color: #e7b416; border-color: #e7b416; }
.kbadge-land { background: rgba(154,167,179,.14); color: #c3ccd6; border-color: #9aa7b3; }
.kb-ebene { display: inline-block; border-radius: 999px; padding: .1rem .55rem; font-size: .72rem; font-weight: 700; }
.kb-bund { background: rgba(231,180,22,.16); color: #e7b416; }
.kb-land { background: rgba(154,167,179,.16); color: #c3ccd6; }
.kb-sparte { display: inline-block; border-radius: 6px; padding: .06rem .45rem; font-size: .72rem; background: var(--surface-2); color: var(--muted); }
.kb-beendet { opacity: .62; }

.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: .8rem; margin-bottom: 1.1rem; }
.stat-mini { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: .75rem 1rem; }
.stat-mini b { display: block; font-size: 1.35rem; font-weight: 700; }
.stat-mini span { color: var(--muted); font-size: .8rem; }

.mvbtn { width: 24px; height: 24px; border-radius: 7px; border: 1px solid var(--border); background: var(--surface-2); color: var(--muted); cursor: pointer; font-size: .68rem; line-height: 1; padding: 0; }
.mvbtn:hover { color: var(--text); border-color: var(--accent); }

.form-sticky { position: sticky; bottom: 0; z-index: 20; display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: .7rem 1rem; margin-top: 1rem; box-shadow: 0 -8px 24px -12px rgba(0,0,0,.6); }

.picker { position: relative; }
.picker-list { position: absolute; top: calc(100% + 4px); left: 0; right: 0; z-index: 30; max-height: 300px; overflow-y: auto; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow); }
.picker-list:empty { display: none; }
.picker-item { display: flex; flex-direction: column; gap: .1rem; width: 100%; text-align: left; padding: .55rem .8rem; background: none; border: 0; border-bottom: 1px solid var(--border); color: var(--text); font: inherit; cursor: pointer; }
.picker-item:last-child { border-bottom: 0; }
.picker-item:hover, .picker-item:focus { background: var(--surface); outline: none; }
.picker-empty { padding: .55rem .8rem; }

.hidden { display: none !important; }
.quick-card { max-width: 760px; margin: 0 auto; }
.quick-meta { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin-bottom: 1rem; }
.quick-vs { display: grid; grid-template-columns: 1fr auto 1fr; gap: 1rem; align-items: center; margin: 1.2rem 0 1.4rem; }
.quick-side { min-width: 0; text-align: center; padding: .9rem .6rem; border-radius: var(--radius-sm); background: var(--surface-2); border-top: 3px solid transparent; }
.quick-side.rot  { border-top-color: var(--rot); }
.quick-side.blau { border-top-color: var(--blau); }
.quick-label { font-size: .72rem; letter-spacing: .14em; color: var(--muted); }
.quick-name { font-size: 1.35rem; font-weight: 700; overflow-wrap: anywhere; }
.quick-mid { color: var(--muted); font-weight: 700; }
.quick-actions { display: grid; grid-template-columns: 1fr auto 1fr; gap: 1rem; align-items: center; }
.quick-win { padding: 1rem .6rem; font-size: 1.05rem; font-weight: 700; }
.quick-win.rot  { background: var(--rot); }
.quick-win.blau { background: var(--blau); }
.quick-score { display: flex; align-items: center; gap: .45rem; justify-content: center; }
.quick-score input { width: 74px; text-align: center; font-size: 1.15rem; }
@media (max-width: 640px) {
    .quick-vs, .quick-actions { grid-template-columns: 1fr; }
    .quick-mid { display: none; }
}

.undo-bar { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.undo-bar form { margin: 0; }

details.tpl-section { padding: 0; }
.tpl-sec-head { display: flex; align-items: center; gap: .6rem; padding: .9rem 1.25rem; cursor: pointer; list-style: none; }
.tpl-sec-head::-webkit-details-marker { display: none; }
.tpl-sec-title { font-size: 16px; font-weight: 600; }
.tpl-sec-count { margin-left: auto; }
.tpl-sec-chev { width: 18px; height: 18px; color: var(--muted); transition: transform .15s; flex-shrink: 0; }
details.tpl-section[open] .tpl-sec-chev { transform: rotate(180deg); }
.tpl-sec-body { padding: 0 1.25rem 1.1rem; }

.rule-tabs { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 1rem; }
.rule-pill { padding: .4rem .8rem; font-size: .85rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-2); color: var(--muted); cursor: pointer; }
.rule-pill.on { background: var(--surface-2); color: var(--text); border-color: var(--accent); }

.tpl-levels { display: flex; flex-wrap: wrap; gap: .4rem; }
.tpl-chosen { margin-top: .4rem; display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; }
.stdgrp > summary { display: inline-block; }
.stdgrp-form { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .8rem 1rem; background: var(--surface-2); }
.checkbox-inline { display: inline-flex; align-items: center; gap: .3rem; font-size: .88rem; }

.merge-heads { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.merge-src { padding: .7rem 1rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface-2); min-width: 200px; }
.merge-src.keep { border-left: 3px solid var(--ok); }
.merge-src.dup  { border-left: 3px solid var(--err); }
.merge-arrow { font-size: 1.4rem; color: var(--muted); }
td.merge-win { color: var(--text); font-weight: 600; }

.stat-bar { height: 12px; border-radius: 999px; background: var(--surface-2); overflow: hidden; border: 1px solid var(--border); }
.stat-bar.sm { height: 8px; max-width: 220px; }
.stat-bar > span { display: block; height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent-2)); border-radius: 999px; transition: width .3s; }

.recent-chip { display: inline-flex; flex-direction: column; gap: .2rem; padding: .5rem .8rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface-2); text-decoration: none; color: var(--text); max-width: 260px; }
.recent-chip:hover { border-color: var(--accent); }
.recent-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recent-meta { font-size: .78rem; color: var(--muted); }

.w-check { width: 34px; text-align: center; }
.w-check input[type=checkbox] { width: 16px; height: 16px; accent-color: var(--accent); }
.bulk-bar { align-items: center; opacity: .65; transition: opacity .15s; }
.bulk-bar.has-selection { opacity: 1; }

.field-err { display: block; margin-top: .25rem; font-size: .8rem; color: var(--err); }
.field:has(.field-err) input, .field:has(.field-err) select, .field:has(.field-err) textarea { border-color: var(--err); }

.tick-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: .8rem; }
.tick-mat { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .8rem .9rem; }
.tick-head { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: .55rem; }
.tick-vs { display: grid; grid-template-columns: 1fr auto 1fr; gap: .6rem; align-items: center; }
.tick-vs:has(.solo) { grid-template-columns: 1fr; }
.tick-side { min-width: 0; display: flex; flex-direction: column; font-weight: 600; overflow-wrap: anywhere; }
.tick-side small { color: var(--muted); font-weight: 400; }
.tick-side.rot  { border-left: 3px solid var(--rot);  padding-left: .5rem; }
.tick-side.blau { border-right: 3px solid var(--blau); padding-right: .5rem; text-align: right; align-items: flex-end; }
.tick-score { font-weight: 800; font-variant-numeric: tabular-nums; color: var(--muted); }
.tick-next { margin-top: .5rem; border-top: 1px solid var(--border); padding-top: .4rem; }

.err-page { max-width: 460px; margin: 12vh auto 0; text-align: center; }
.err-page .code { font-size: 3.2rem; font-weight: 800; color: var(--accent-2); line-height: 1; }
.err-page h1 { margin: .6rem 0 .4rem; }
.err-page p { color: var(--muted); }

@media print {
    body, body.is-app { background: #fff !important; color: #111 !important; display: block; }
    .sidebar, .appbar, .ui-overlay, .toolbar, .form-actions, .btn, #map-toasts, .appfooter { display: none !important; }
    .card, .table-wrap, .stat, .action-group { background: #fff !important; border-color: #bbb !important; box-shadow: none !important; color: #111 !important; }
    th, td { color: #111 !important; border-color: #ccc !important; }
    a { color: #111 !important; text-decoration: none !important; }
    .muted, .small { color: #555 !important; }
}

.ktree-title { color: var(--muted, #8b98a5); font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; margin: 1rem 0 .5rem; }
.ktree-cols { display: flex; gap: 2rem; align-items: stretch; overflow-x: auto; padding-bottom: .5rem; }
.ktree-col { display: flex; flex-direction: column; justify-content: space-around; gap: .8rem; min-width: 220px; }
.ktree-col h4 { text-align: center; color: var(--muted, #8b98a5); font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; margin: 0 0 .2rem; }
.ktree-form { text-align: center; color: var(--accent, #6ea8fe); font-size: .82rem; font-weight: 600; margin: -.1rem 0 .5rem; }
.ktree-match { background: var(--surface, #161d26); border: 1px solid var(--border, #2a3744); border-radius: 10px; overflow: hidden; }
.ktree-match.live { border-color: #e9c46a; box-shadow: 0 0 0 2px rgba(233,196,106,.35); }
.ktree-slot { display: flex; align-items: center; gap: .5rem; padding: .5rem .7rem; }
.ktree-slot + .ktree-slot { border-top: 1px solid var(--border, #2a3744); }
.ktree-slot .nm { flex: 1; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ktree-slot .club { color: var(--muted, #8b98a5); font-weight: 400; font-size: .8rem; }
.ktree-slot .pts { font-variant-numeric: tabular-nums; font-weight: 800; min-width: 2.4rem; text-align: right; }
.ktree-slot .dot { width: .55rem; height: .55rem; border-radius: 50%; flex: 0 0 auto; }
.ktree-slot.rot .dot { background: #e63946; }
.ktree-slot.blau .dot { background: #2563eb; }
.ktree-slot.win { background: rgba(42,157,143,.16); }
.ktree-slot.win .nm { color: #bdf0e6; }
.ktree-slot.lose { opacity: .55; }
.ktree-slot.tbd .nm { color: var(--muted, #8b98a5); font-weight: 400; font-style: italic; }
@media (max-width: 720px) {
    .ktree-cols { flex-direction: column; gap: 1.1rem; }
    .ktree-col { min-width: 0; }
    .ktree-slot .nm { white-space: normal; }
}

.lang-switch { display: inline-flex; align-items: center; gap: .28rem; font-size: .8rem; font-weight: 600; letter-spacing: .02em; white-space: nowrap; }
.lang-switch a { color: var(--muted); padding: .12rem .3rem; border-radius: 7px; line-height: 1; }
.lang-switch a:hover { color: var(--text); background: var(--surface); text-decoration: none; }
.lang-switch .lang-cur { color: var(--accent-2); padding: .12rem .3rem; }
.lang-switch .lang-sep { color: var(--muted); opacity: .45; }
.lang-switch-bare { position: fixed; top: 1rem; right: 1.25rem; z-index: 20; }

.tabbar .step-no { display:inline-flex; align-items:center; justify-content:center; width:1.5em; height:1.5em; border-radius:50%; background:var(--surface); font-size:.78em; font-weight:700; margin-right:.2rem; vertical-align:middle; }
.tabbar .tab.on .step-no { background:var(--accent); color:#fff; }
.tabbar .tab.step-done .step-no { background:var(--ok); color:#fff; }
.tabbar .tab.step-locked { opacity:.45; cursor:not-allowed; }
[data-stepper-bar] [data-step-info] { margin-left:auto; }

.sym-feld { width: 5.5rem; font-size: 1.5rem; text-align: center; line-height: 1.2; }
.sym-palette { margin-top: .6rem; display: flex; flex-direction: column; gap: .5rem; }
.sym-gruppe { display: flex; flex-direction: column; gap: .25rem; }
.sym-titel { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.sym-reihe { display: flex; flex-wrap: wrap; gap: .3rem; }
.sym-knopf {
    width: 44px; height: 44px;
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
    color: var(--text); font-size: 1.25rem; line-height: 1; cursor: pointer; padding: 0;
}
.sym-knopf:hover { background: var(--surface-2); }
.sym-knopf.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }

.brechbar { overflow-wrap: anywhere; word-break: break-word; }

@media (max-width: 700px) {
    .table-wrap table td, .table-wrap table th { overflow-wrap: anywhere; }
}


.mz-zustand { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.mz-zk { background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--muted);
         border-radius: var(--radius); padding: .8rem .9rem; }
.mz-zk.an   { border-left-color: var(--ok, #2f9e5f); }
.mz-zk.warn { border-left-color: var(--warn, #e7b416); }
.mz-zk .kopf { display: flex; justify-content: space-between; align-items: center; gap: .5rem; }
.mz-zk h3 { margin: 0; font-size: .95rem; }
.mz-zk .wert { font-size: 1.25rem; font-weight: 700; margin: .3rem 0 .15rem; }
.mz-zk.an .wert   { color: var(--ok, #2f9e5f); }
.mz-zk.warn .wert { color: var(--warn, #e7b416); }
.mz-zk p { margin: 0; color: var(--muted); font-size: .78rem; line-height: 1.45; }
.mz-sw { border: none; background: var(--surface-3, #2a2f3d); width: 40px; height: 22px; border-radius: 11px;
         position: relative; cursor: pointer; padding: 0; flex: none; }
.mz-sw.on { background: var(--ok, #2f9e5f); }
.mz-sw::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px;
                border-radius: 50%; background: #fff; transition: left .12s; }
.mz-sw.on::after { left: 21px; }

.mz-pakete { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .7rem; }
.mz-pk { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm);
         padding: .75rem; position: relative; display: flex; flex-direction: column; }
.mz-pk.top { border-color: var(--accent); }
.mz-pk .kl { color: var(--muted); font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; }
.mz-pk .preis { font-size: 1.6rem; font-weight: 700; margin: .15rem 0 .05rem; line-height: 1.1; }
.mz-pk .je { color: var(--muted); font-size: .72rem; }
.mz-pk .gr { margin-top: .5rem; font-size: .82rem; }
.mz-pk .zusatz { margin-top: .3rem; font-size: .74rem; color: var(--warn, #e7b416); line-height: 1.4; }
.mz-pk .fuss { display: flex; justify-content: space-between; align-items: center; gap: .4rem;
               margin-top: auto; padding-top: .55rem; border-top: 1px solid var(--border); }
.mz-pk .abz { position: absolute; top: -.55rem; left: .7rem; background: var(--accent); color: #fff;
              font-size: .62rem; font-weight: 700; padding: .1rem .5rem; border-radius: .5rem;
              text-transform: uppercase; letter-spacing: .04em; }

.mz-schritte { list-style: none; padding: 0; margin: 0; }
.mz-schritte li { display: flex; gap: .55rem; align-items: flex-start; padding: .45rem 0;
                  border-bottom: 1px solid var(--border); font-size: .84rem; }
.mz-schritte li:last-child { border-bottom: none; }
.mz-schritte .z { font-weight: 700; flex: none; width: 1rem; text-align: center; }
.mz-schritte .z-ok   { color: var(--ok, #2f9e5f); }
.mz-schritte .z-warn { color: var(--warn, #e7b416); }
.mz-schritte .z-todo { color: var(--muted); }
.mz-schritte .t { display: block; color: var(--muted); font-size: .76rem; margin-top: .1rem; }

.mz-fortschritt { display: flex; align-items: center; margin-bottom: 1rem; flex-wrap: wrap; gap: .3rem 0; }
.mz-fortschritt .st { display: flex; align-items: center; gap: .45rem; }
.mz-fortschritt .kugel { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center;
                         justify-content: center; font-size: .78rem; font-weight: 700;
                         background: var(--surface-2); color: var(--muted); border: 1px solid var(--border); }
.mz-fortschritt .st.fertig .kugel { background: rgba(47,158,95,.18); color: var(--ok, #2f9e5f); border-color: var(--ok, #2f9e5f); }
.mz-fortschritt .st.jetzt  .kugel { background: var(--accent); color: #fff; border-color: var(--accent); }
.mz-fortschritt .txt { font-size: .8rem; color: var(--muted); }
.mz-fortschritt .st.jetzt .txt { color: var(--text); font-weight: 600; }
.mz-fortschritt .linie { flex: 1; min-width: 1rem; height: 2px; background: var(--border); margin: 0 .6rem; }
.mz-fortschritt .linie.fertig { background: var(--ok, #2f9e5f); }
.mz-schritt { border-top: 1px solid var(--border); padding-top: .8rem; margin-top: .8rem; }
.mz-schritt:first-of-type { border-top: none; padding-top: 0; margin-top: 0; }
.js-an .mz-schritt { display: none; }
.js-an .mz-schritt.on { display: block; }
.mz-wahl { display: grid; gap: .55rem; }
.mz-opt { display: flex; gap: .6rem; align-items: flex-start; background: var(--surface-2);
          border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .65rem .75rem; cursor: pointer; }
.mz-opt:has(input:checked) { border-color: var(--accent); background: var(--surface-3, var(--surface)); }
.mz-opt input[type="radio"] { margin-top: .2rem; flex: none; width: 1rem; height: 1rem; }
.mz-opt b { display: block; font-size: .88rem; }
.mz-opt p { margin: .15rem 0 0; color: var(--muted); font-size: .78rem; line-height: 1.5; }

.preis-zusatz {
    margin: .45rem 0 .15rem;
    background: rgba(231, 180, 22, .12);
    border: 1px solid rgba(231, 180, 22, .55);
    border-radius: var(--radius-sm);
    padding: .5rem .6rem;
    line-height: 1.45;
}
.preis-zusatz strong { display: block; font-size: .84rem; color: var(--warn, #b8860b); }
.preis-zusatz span   { display: block; font-size: .74rem; color: var(--muted); margin-top: .15rem; }


.pz-kuenste { display: grid; gap: .5rem; margin-top: .6rem; }
.pz-kunst { display: flex; gap: .6rem; align-items: flex-start; background: var(--surface-2);
            border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .6rem .75rem; cursor: pointer; }
.pz-kunst.pz-aus { opacity: .55; cursor: default; }
.pz-kunst input[type="checkbox"] { margin-top: .2rem; flex: none; width: 1rem; height: 1rem; }
.pz-kunst span { display: block; }
.pz-kunst .muted { display: block; }

.pz-block { background: var(--surface-2); border: 1px solid var(--border);
            border-radius: var(--radius-sm); padding: .75rem .85rem; margin-bottom: .7rem; }
.pz-kopf { display: flex; justify-content: space-between; align-items: center; gap: .6rem; margin-bottom: .5rem; }
.pz-zeile { display: flex; gap: .5rem; align-items: center; margin-bottom: .4rem; flex-wrap: wrap; }
.pz-zeile select { flex: 1 1 14rem; min-width: 12rem; }
.pz-zeile input { flex: 0 0 11rem; }
.pz-haken { display: flex; gap: .6rem; align-items: flex-start; margin: .3rem 0 .6rem; }
.pz-haken input[type="checkbox"] { margin-top: .2rem; flex: none; width: 1rem; height: 1rem; }

.pf-klapp { background: var(--surface-2); border: 1px solid var(--border);
            border-radius: var(--radius-sm); padding: .6rem .7rem; margin-top: .35rem;
            display: grid; gap: .3rem; min-width: 15rem; }
.pf-haken { display: flex; gap: .5rem; align-items: center; margin: .2rem 0; }
.pf-haken input[type="checkbox"] { flex: none; width: 1rem; height: 1rem; }
.pf-warnung { border-color: var(--warn); background: rgba(233, 196, 106, .10); }

.pe-zeile { border: 1px solid var(--border); border-radius: var(--radius-sm);
            padding: .75rem .85rem; margin-bottom: .7rem; background: var(--surface-2); }
.pe-kopf { display: flex; justify-content: space-between; align-items: flex-start; gap: .6rem; margin-bottom: .5rem; }
.pe-form { display: grid; gap: .4rem; }

.check { display: flex; align-items: center; gap: .55rem; margin: .35rem 0;
         font-size: .92rem; color: var(--text); cursor: pointer; line-height: 1.45; }
.check input[type="checkbox"], .check input[type="radio"] {
    flex: 0 0 auto; width: 1rem; height: 1rem; margin: 0; padding: 0;
}
.check.check-oben { align-items: flex-start; }
.check.check-oben input { margin-top: .18rem; }

.pf-antrag { border: 1px solid var(--border); border-radius: var(--radius-sm);
             padding: .75rem .85rem; margin-bottom: .8rem; background: var(--surface-2); }
.pf-kopf { display: flex; justify-content: space-between; align-items: flex-start;
           gap: .8rem; flex-wrap: wrap; margin-bottom: .6rem; }
.pf-kopf strong { margin-right: .5rem; }
