/* topsis behält die warmen karten und bekommt ruhige blaue diagramme */
.topsis-explanation { --topsis-blue: #397e97; --topsis-green: #789163; --topsis-ink: #365c68; gap: 1.6rem; }
.topsis-explanation .topsis-detail-card { padding: clamp(1.2rem, 2.6vw, 2rem); border: 1px solid #d6d8c8; background: linear-gradient(140deg, #fffdf7, #f7f9f0); box-shadow: 0 4px 0 #e3e2d0; }
.topsis-explanation .topsis-detail-card h2 { margin: 0 0 .7rem; font-size: clamp(1.2rem, 2vw, 1.55rem); line-height: 1.3; }
.topsis-explanation .topsis-detail-card > .rec-detail-note { max-width: 90ch; font-size: .96rem; line-height: 1.7; }
.topsis-detail-kicker { color: #4e8290; font-size: .72rem; letter-spacing: .14em; font-weight: 750; margin: 0 0 .7rem; }
.topsis-explanation .topsis-hero-grid { display: grid; grid-template-columns: minmax(260px, .8fr) minmax(0, 1.65fr); gap: 1.4rem; }
.topsis-explanation .topsis-score-card { position: relative; overflow: hidden; background: radial-gradient(ellipse at top left, #eef6f3, transparent 60%), #fffcf4; border-top: 4px solid var(--topsis-blue); }
.topsis-explanation .topsis-score-ring { width: 224px; height: 224px; box-shadow: 0 0 0 9px #eff3e9, 0 12px 24px #486d7114; }
.topsis-explanation .topsis-score-ring > div { width: 174px; height: 174px; }
.topsis-explanation .topsis-score-ring strong { font-size: clamp(1.8rem, 3vw, 2.45rem); }
.topsis-explanation .topsis-distance-card { border-top: 4px solid #91a374; }
.topsis-explanation .topsis-distance-row { margin: 1.4rem 0; font-size: 1rem; gap: .65rem; }
.topsis-explanation .topsis-distance-row > strong { font-size: 1.05rem; font-weight: 750; white-space: nowrap; }
.topsis-explanation .topsis-distance-track { height: 15px; background: #e4e6d9; border-radius: 10px; }
.topsis-explanation .topsis-distance-track > span { background: linear-gradient(90deg, #9eae84, #728d5c); }
.topsis-explanation .topsis-distance-row[data-kind="worst"] .topsis-distance-track > span { background: linear-gradient(90deg, #80b5be, #397e97); }
.topsis-explanation .topsis-formula { background: #e8f0eb; color: #365c68; border: 1px solid #d3e3da; }
.topsis-explanation .topsis-formula-example { color: #53665f; font-size: 1rem; }
.topsis-coverage-chart { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 1.8rem; align-items: center; margin: 1.3rem 0; }
.topsis-coverage-ring { width: 150px; height: 150px; border-radius: 50%; background: conic-gradient(var(--topsis-blue) var(--topsis-known), #e2e2d5 0); display: grid; place-items: center; }
.topsis-coverage-ring > div { width: 116px; height: 116px; border-radius: 50%; background: #fcfcf4; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: .25rem; }
.topsis-coverage-ring strong { font-size: 1.6rem; color: var(--topsis-ink); }
.topsis-coverage-ring span { font-size: .7rem; }
.topsis-coverage-facts { display: grid; gap: .55rem; }
.topsis-coverage-facts > strong { font-size: 1.22rem; color: #477468; }
.topsis-coverage-facts > span { color: #756f5d; }
.topsis-explanation .topsis-detail-card meter { display: none; }
.topsis-share-charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem; margin-top: 1.8rem; }
.topsis-share-figure { margin: 0; display: flex; flex-direction: column; align-items: center; padding: 1rem; border: 1px solid #d9dfd2; border-radius: 18px; background: #f6f8ef; }
.topsis-share-figure figcaption { font-size: .92rem; font-weight: 650; color: #49666b; text-align: center; line-height: 1.5; }
.topsis-share-ring { width: 192px; height: 192px; max-width: 100%; border-radius: 50%; display: grid; place-items: center; margin: 1.2rem auto .5rem; box-shadow: 0 0 0 7px #e9eee4; }
.topsis-share-ring > div { width: 146px; height: 146px; max-width: 78%; max-height: 78%; border-radius: 50%; background: #fffdf6; display: flex; align-items: center; justify-content: center; flex-direction: column; padding: .7rem; box-sizing: border-box; text-align: center; }
.topsis-share-ring strong { color: #426b73; font-size: 1.65rem; white-space: nowrap; }
.topsis-share-ring span { font-size: .75rem; margin-top: .4rem; max-width: 105px; line-height: 1.3; overflow-wrap: anywhere; }
.topsis-distance-legend { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; margin-top: 1.4rem; }
.topsis-distance-legend-item { display: grid; gap: .65rem; min-width: 0; padding: .9rem 1rem; border: 1px solid #d5dccb; border-radius: 13px; background: #fdfbf2; color: #5b5a44; font: inherit; text-align: left; cursor: pointer; transition: transform .2s, border-color .2s, box-shadow .2s; }
.topsis-distance-legend-item:hover { transform: translateY(-2px); border-color: var(--topsis-part-color); }
.topsis-distance-legend-item[aria-pressed="true"] { border-color: var(--topsis-part-color); box-shadow: inset 4px 0 0 var(--topsis-part-color), 0 3px 0 #dbe5db; background: #f2f7ef; }
.topsis-distance-legend-item:focus-visible { outline: 3px solid #488997; outline-offset: 3px; }
.topsis-distance-legend-title { display: flex; align-items: center; gap: .65rem; }
.topsis-distance-legend-title i { width: 15px; height: 15px; flex: 0 0 auto; border-radius: 50%; background: var(--topsis-part-color); }
.topsis-distance-legend-title strong { font-size: .95rem; }
.topsis-share-line { display: grid; grid-template-columns: 1fr auto; gap: .35rem .6rem; font-size: .78rem; color: #78745f; }
.topsis-share-line > strong { color: #526c66; font-variant-numeric: tabular-nums; }
.topsis-share-line-track { grid-column: 1 / -1; height: 7px; border-radius: 4px; overflow: hidden; background: #e4e5d7; }
.topsis-share-line-track i { display: block; height: 100%; background: var(--topsis-part-color); border-radius: inherit; }
@media (max-width: 760px) {
    .topsis-explanation .topsis-hero-grid { grid-template-columns: 1fr; }
    .topsis-distance-legend { grid-template-columns: 1fr; }
    .topsis-share-ring { width: 160px; height: 160px; }
    .topsis-share-ring > div { width: 122px; height: 122px; }
    .topsis-share-ring strong { font-size: 1.35rem; }
    .topsis-share-figure { padding: .7rem; }
    .topsis-share-figure figcaption { font-size: .8rem; }
    .topsis-coverage-chart { grid-template-columns: 120px minmax(0, 1fr); gap: 1rem; }
    .topsis-coverage-ring { width: 120px; height: 120px; }
    .topsis-coverage-ring > div { width: 92px; height: 92px; }
    .topsis-coverage-ring strong { font-size: 1.35rem; }
    .topsis-coverage-facts > strong { font-size: 1rem; }
}
@media (max-width: 430px) {
    .topsis-share-charts { grid-template-columns: 1fr; }
    .topsis-explanation .topsis-distance-row { grid-template-columns: 1fr; }
    .topsis-explanation .topsis-distance-row > strong { justify-self: end; }
    .topsis-coverage-chart { grid-template-columns: 1fr; justify-items: center; text-align: center; }
}
@media (prefers-reduced-motion: reduce) { .topsis-distance-legend-item { transition: none; } }

.topsis-ring-meaning { font-size: .86rem; line-height: 1.6; color: #5c736a; margin: .7rem 0 0; text-align: center; max-width: 35ch; }
.topsis-explanation .topsis-distance-row > strong { max-width: 100%; white-space: normal; overflow-wrap: anywhere; text-align: right; }
.topsis-profile-chart { margin: 1.3rem 0 .5rem; padding: 1rem; background: #f7f9f1; border: 1px solid #d6e0d4; border-radius: 15px; }
.topsis-profile-chart figcaption { color: #426d75; font-size: 1.05rem; font-weight: 700; }
.topsis-profile-legend { display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; margin: 1rem 0; }
.topsis-profile-legend > span { display: inline-flex; gap: .5rem; align-items: center; color: #596e65; font-size: .8rem; }
.topsis-profile-legend > span::before { content: ""; width: 14px; height: 14px; background: #397e97; border-radius: 3px; }
.topsis-profile-legend > span[data-kind="best"]::before { background: #789163; }
.topsis-profile-legend > span[data-kind="worst"]::before { background: #a6a48f; }
.topsis-profile-canvas { position: relative; width: 100%; min-width: 0; margin: .8rem 0; }
.topsis-profile-canvas > svg { display: block; width: 100%; min-width: 0; max-width: 100%; height: auto; overflow: visible; }
.topsis-profile-grid { stroke: #dedfd1; stroke-width: 1; }
.topsis-profile-axis { fill: #757d68; font: 11px system-ui, sans-serif; }
.topsis-profile-pages { margin-top: 1rem; flex-wrap: wrap; }

/* drei echte balkenhöhen, ohne künstliche mindesthöhe */
.topsis-profile-bar--game { fill: #397e97; }
.topsis-profile-bar--best { fill: #789163; }
.topsis-profile-bar--worst { fill: #a6a48f; }
.topsis-profile-bar:hover { filter: brightness(.92); }
.topsis-profile-zero, .topsis-profile-missing { fill: #687968; font: 11px system-ui, sans-serif; }

/* eine gemeinsame spanne pro präferenz, mit echten spielen an den enden */
.topsis-area-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem; margin-top: 1.5rem; }
.topsis-area-card { min-width: 0; border: 1px solid #cbded1; border-radius: 16px; padding: clamp(1.1rem, 2vw, 1.5rem); background: linear-gradient(135deg, #f3f8ef, #faf9ed); }
.topsis-area-card > header { display: flex; flex-wrap: wrap; gap: .45rem 1rem; align-items: baseline; justify-content: space-between; }
.topsis-area-card h3 { margin: 0; font-size: 1.1rem; color: #3f6873; }
.topsis-area-card > header > span { font-size: .73rem; color: #7d816a; }
.topsis-area-current { display: grid; gap: .3rem; margin: 1.4rem auto 1.5rem; text-align: center; color: #48757e; }
.topsis-area-current > span { font-size: .9rem; overflow-wrap: anywhere; }
.topsis-area-current > strong { font-size: 1.3rem; line-height: 1.3; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.topsis-area-current > small { font-size: .73rem; color: #6f7a64; }
.topsis-area-track { position: relative; height: 15px; border-radius: 10px; margin: .8rem .7rem 1.25rem; background: linear-gradient(90deg, #d7d5c1, #b9cda8 48%, #74915d); }
.topsis-area-track::before, .topsis-area-track::after { content: ""; position: absolute; top: -3px; width: 2px; height: 21px; background: #829275; }
.topsis-area-track::before { left: 0; }
.topsis-area-track::after { right: 0; }
.topsis-area-marker { position: absolute; z-index: 1; width: 24px; height: 24px; top: 50%; transform: translate(-50%, -50%); border-radius: 50%; background: #397e97; border: 4px solid #fffdf6; box-sizing: border-box; box-shadow: 0 0 0 2px #397e97, 0 3px 7px #426d6e30; }
.topsis-area-ends { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
.topsis-area-ends > div { display: flex; flex-direction: column; gap: .35rem; min-width: 0; }
.topsis-area-ends > div:last-child { text-align: right; }
.topsis-area-ends span { font-size: .7rem; color: #7f816a; }
.topsis-area-ends strong { font-size: .95rem; line-height: 1.4; color: #556e55; overflow-wrap: anywhere; }
.topsis-area-ends small { font-size: .76rem; color: #7c826c; overflow-wrap: anywhere; }
.topsis-area-ends b { color: #4d7569; font-size: .85rem; overflow-wrap: anywhere; }
.topsis-area-reason { margin: 1.1rem 0 0; padding-top: .8rem; border-top: 1px dashed #d1dcca; font-size: .78rem; line-height: 1.6; color: #6f7865; }
.topsis-area-omitted { border-top: 1px solid #dde1d1; margin-top: 1.4rem; padding-top: 1rem; }
.topsis-area-omitted summary { cursor: pointer; color: #54766e; font-size: .9rem; line-height: 1.5; }
.topsis-area-notes { list-style: none; padding: 0; display: grid; gap: .8rem; }
.topsis-area-notes li { display: grid; gap: .3rem; font-size: .85rem; line-height: 1.6; }
.topsis-area-notes strong { color: #537466; }
.topsis-area-notes span { color: #767b67; }
@media (max-width: 820px) { .topsis-area-grid { grid-template-columns: 1fr; } }

/* hervorgehobene anteile bleiben genau so groß wie ihr echter wert */
.topsis-share-ring { position: relative; }
.topsis-share-ring > div { position: relative; z-index: 1; }
.topsis-share-ring > .topsis-share-selection { position: absolute; inset: -5px; margin: 0; max-width: none; max-height: none; border-radius: 50%; pointer-events: none; mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 0); -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 0); filter: drop-shadow(0 0 4px var(--topsis-selection-color)); }

/* die genaue zahl erscheint mit maus und tastatur im eigenen hinweis */
.topsis-profile-tooltip { position: absolute; z-index: 4; display: grid; gap: .35rem; width: 240px; max-width: calc(100% - 16px); padding: .8rem 1rem; box-sizing: border-box; border: 1px solid #b9cfc5; border-left: 4px solid #397e97; border-radius: 12px; background: #fffdf4; color: #496b67; box-shadow: 0 5px 18px #486d7130; pointer-events: none; }
.topsis-profile-tooltip[hidden] { display: none; }
.topsis-profile-tooltip[data-kind="best"] { border-left-color: #789163; }
.topsis-profile-tooltip[data-kind="worst"] { border-left-color: #a6a48f; }
.topsis-profile-tooltip span { font-size: .8rem; line-height: 1.4; overflow-wrap: anywhere; }
.topsis-profile-tooltip strong { color: #326a7c; font-size: 1.05rem; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.topsis-profile-tooltip small { font-size: .72rem; line-height: 1.4; color: #78806a; overflow-wrap: anywhere; }
.topsis-profile-tooltip .topsis-profile-tooltip-game { padding-top: .4rem; border-top: 1px solid #dfe6d6; font-size: .78rem; color: #496b67; }
.topsis-profile-tooltip .topsis-profile-tooltip-game[hidden] { display: none; }
.topsis-profile-bar, .topsis-profile-zero { cursor: help; }
.topsis-profile-bar:focus-visible { outline: none; stroke: #245365; stroke-width: 2; }
.topsis-profile-zero:focus-visible { outline: 2px solid #397e97; outline-offset: 2px; }
.topsis-profile-pages { display: flex; justify-content: center; align-items: center; gap: .7rem; padding: .8rem; border-radius: 12px; background: #eff3e7; }
.topsis-profile-pages > span { min-width: 6rem; text-align: center; color: #60715e; font-size: .85rem; }
.topsis-profile-pages button { min-height: 38px; padding: .5rem .9rem; }
@media (max-width: 480px) { .topsis-profile-pages { gap: .4rem; padding: .6rem; } .topsis-profile-pages button { padding: .45rem .65rem; } }

/* lesbare namen direkt unter der jeweiligen gruppe statt nummern */
.topsis-profile-condition-labels { display: grid; width: 100%; min-width: 0; box-sizing: border-box; }
.topsis-profile-condition-label { display: grid; align-content: start; gap: .3rem; min-width: 0; padding: 0 .45rem; text-align: center; overflow-wrap: anywhere; hyphens: auto; }
.topsis-profile-condition-label > span { color: #526e65; font-size: .82rem; font-weight: 650; line-height: 1.5; }
.topsis-profile-condition-label > small { color: #7b806b; font-size: .7rem; font-weight: 400; line-height: 1.45; }
