/* ============================================================
   Poker — Texas Hold'em am Bananario-Tisch
   DOM + CSS, keine Grafikdateien: Holzrand, Lederpolster und Filz entstehen aus
   Verläufen, der Filz bekommt eine feine Rauschstruktur aus einem SVG-Filter.
   Alle Maße am Tisch hängen an CSS-Variablen, die poker.js aus der Bühnenbreite
   setzt (--pk-w, --pk-a Avatar, --pk-k Sitzkarte, --pk-ke eigene Karte,
   --pk-kb Board-Karte, --pk-c Chip, --pk-f Schrift). Animationen nur über
   CSS-Übergänge/-Keyframes und setTimeout (kein requestAnimationFrame).
   ============================================================ */

.pk-app { --pk-gold: #FFD93B; --pk-gold-tief: #C98A00; --pk-nacht: #0b1712; color: #EAF2EC; }
.pk-aus { text-align: center; padding: 2rem 1rem; color: var(--ink); }
/* Spielseite ohne ?saal=1: Weg in den Spielsaal und zur Bestenliste (2026-12-05) */
.pk-start { display: flex; flex-wrap: wrap; justify-content: center; gap: .7rem; margin: .4rem 0 1.2rem; }
.pk-sitzt-noch { max-width: 860px; margin: 0 auto 1rem; display: flex; flex-wrap: wrap; align-items: center;
	justify-content: space-between; gap: .6rem 1rem; border: 2px solid #FFD93B; }
.pk-sitzt-noch p { margin: 0; }
.pk-app [hidden] { display: none !important; }

/* ---------- Lobby ---------- */
.pk-lobby { color: var(--ink); }
.pk-lobby-kopf { display: flex; align-items: center; justify-content: space-between; gap: .8rem; flex-wrap: wrap; margin-bottom: .8rem; }
.pk-lobby-kopf h2 { margin: 0; }
.pk-konto { font-weight: 700; color: var(--jungle-dark); }
.pk-tischliste { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.pk-leer { grid-column: 1 / -1; text-align: center; color: var(--ink-soft); padding: 1.4rem .5rem; background: var(--sand); border-radius: var(--radius); margin: 0; }
.pk-kachel {
	position: relative; border-radius: 20px; padding: 14px 14px 12px; color: #EAF2EC; overflow: hidden;
	background: radial-gradient(120% 90% at 50% 0%, #23473a 0%, #12281f 60%, #0b1712 100%);
	box-shadow: 0 10px 26px rgba(12, 30, 20, .28), inset 0 1px 0 rgba(255, 255, 255, .06);
	display: flex; flex-direction: column; gap: 8px;
}
.pk-kachel h3 { margin: 0; font-family: var(--font-display); font-size: 1.25rem; color: var(--pk-gold); letter-spacing: .02em; }
.pk-kachel-zeile { display: flex; flex-wrap: wrap; gap: 6px; font-size: .86rem; }
.pk-pille { background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .1); border-radius: 999px; padding: .15em .65em; white-space: nowrap; }
.pk-pille.gold { background: rgba(255, 217, 59, .16); border-color: rgba(255, 217, 59, .35); color: #FFE88A; }
.pk-mini {
	position: relative; height: 86px; margin: 6px 22px 4px; border-radius: 999px;
	background: radial-gradient(ellipse at 50% 45%, #2f9a5c, #17643a 70%, #0f4a2a);
	box-shadow: 0 0 0 5px #3a2412, 0 0 0 7px #1a110a, 0 8px 16px rgba(0, 0, 0, .45);
}
.pk-mini-sitz {
	position: absolute; width: 30px; height: 30px; border-radius: 50%; transform: translate(-50%, -50%);
	background: rgba(0, 0, 0, .35) center/cover no-repeat; border: 2px dashed rgba(255, 255, 255, .28);
}
.pk-mini-sitz.besetzt { border: 2px solid var(--pk-gold); background-color: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .45); }
.pk-mini-sitz.aus { filter: grayscale(.9); opacity: .7; }
.pk-mini-info { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: .78rem; color: rgba(255, 255, 255, .78); font-weight: 600; text-shadow: 0 1px 2px rgba(0, 0, 0, .6); }
.pk-kachel-knoepfe { display: flex; gap: 8px; margin-top: 2px; }
.pk-kachel-knoepfe .btn { flex: 1; }
.pk-gast-hinweis { margin: .6rem 0 0; color: var(--ink-soft); font-size: .92rem; }

/* ---------- Raum (dunkle Spielhalle) ---------- */
.pk-raum {
	position: relative; border-radius: 26px; padding: 8px 8px 12px;
	background:
		radial-gradient(70% 55% at 50% 38%, rgba(255, 228, 150, .13), transparent 70%),
		radial-gradient(120% 90% at 50% 0%, #1d3a2d 0%, #0e2018 55%, #07110c 100%);
	box-shadow: 0 18px 40px rgba(8, 20, 14, .45), inset 0 1px 0 rgba(255, 255, 255, .05);
	overflow: hidden;
}
.pk-kopfleiste { display: flex; align-items: center; gap: 8px; padding: 2px 4px 6px; min-height: 36px; }
.pk-titel { flex: 1; min-width: 0; text-align: center; font-size: .9rem; color: rgba(234, 242, 236, .86); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pk-titel strong { color: var(--pk-gold); font-family: var(--font-display); font-size: 1.08rem; letter-spacing: .02em; font-weight: 400; }
.pk-kopf-rechts { display: flex; align-items: center; gap: 6px; }
.pk-zuschauer { font-size: .82rem; color: rgba(234, 242, 236, .7); white-space: nowrap; }
.pk-k-knopf {
	appearance: none; border: 1px solid rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .07); color: #EAF2EC;
	border-radius: 999px; padding: 6px 12px; font: inherit; font-size: .88rem; cursor: pointer; line-height: 1.1;
}
.pk-k-knopf:hover { background: rgba(255, 255, 255, .14); }
.pk-k-knopf:focus-visible, .pk-akt:focus-visible, .pk-vorab-knopf:focus-visible, .pk-preset:focus-visible { outline: 2px solid var(--pk-gold); outline-offset: 2px; }

/* ---------- Bühne und Tisch ---------- */
.pk-buehne {
	--pk-w: 900px; --pk-a: 66px; --pk-k: 42px; --pk-ke: 58px; --pk-kb: 60px; --pk-c: 19px; --pk-f: 13px;
	position: relative; width: 100%; margin: 0 auto; aspect-ratio: 16 / 9.4; font-size: var(--pk-f);
	user-select: none; -webkit-user-select: none;
}
.pk-hoch .pk-buehne { aspect-ratio: 100 / 128; }

.pk-tisch { position: absolute; inset: 11% 7.5% 13.5% 7.5%; border-radius: 9999px; }
.pk-hoch .pk-tisch { inset: 7% 9% 8.5% 9%; }
/* Holzrand: Mahagoni mit Maserung und Lichtkante */
.pk-tisch {
	background:
		radial-gradient(120% 70% at 50% -10%, rgba(255, 236, 200, .28), transparent 55%),
		repeating-linear-gradient(96deg, rgba(0, 0, 0, .10) 0 1px, transparent 1px 5px, rgba(255, 210, 160, .05) 5px 6px, transparent 6px 11px),
		linear-gradient(180deg, #8a5329 0%, #5f3517 45%, #3b200c 100%);
	box-shadow:
		0 34px 60px rgba(0, 0, 0, .6), 0 10px 20px rgba(0, 0, 0, .45),
		inset 0 2px 1px rgba(255, 222, 180, .45), inset 0 -4px 8px rgba(0, 0, 0, .55);
}
/* Lederpolster */
.pk-rand {
	position: absolute; inset: calc(var(--pk-w) * .011); border-radius: 9999px;
	background:
		radial-gradient(130% 80% at 50% 0%, rgba(255, 255, 255, .16), transparent 45%),
		linear-gradient(180deg, #2a1f19, #140e0b 60%, #0c0807);
	box-shadow: inset 0 2px 2px rgba(255, 255, 255, .12), inset 0 -3px 6px rgba(0, 0, 0, .8), 0 1px 0 rgba(255, 220, 170, .18);
}
.pk-rand::after { /* Ziernaht */
	content: ''; position: absolute; inset: calc(var(--pk-w) * .011); border-radius: 9999px;
	border: 1px dashed rgba(255, 217, 59, .28);
}
.pk-hoch .pk-rand { inset: calc(var(--pk-w) * .02); }
.pk-hoch .pk-rand::after { inset: calc(var(--pk-w) * .02); }
/* Filz */
.pk-filz {
	position: absolute; inset: calc(var(--pk-w) * .036); border-radius: 9999px; overflow: hidden;
	background:
		url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .5 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='.22'/%3E%3C/svg%3E"),
		radial-gradient(ellipse 68% 62% at 50% 44%, #39a866 0%, #238450 38%, #16653b 72%, #0d4527 100%);
	box-shadow:
		inset 0 0 0 1px rgba(0, 0, 0, .55), inset 0 calc(var(--pk-w) * .016) calc(var(--pk-w) * .035) rgba(0, 0, 0, .55),
		inset 0 calc(var(--pk-w) * -.008) calc(var(--pk-w) * .025) rgba(0, 0, 0, .3);
}
.pk-hoch .pk-filz { inset: calc(var(--pk-w) * .062); }
.pk-filz::before { /* Setzlinie */
	content: ''; position: absolute; inset: calc(var(--pk-w) * .055); border-radius: 9999px;
	border: 1.5px solid rgba(255, 217, 59, .2); box-shadow: 0 0 0 1px rgba(0, 0, 0, .12);
}
.pk-hoch .pk-filz::before { inset: calc(var(--pk-w) * .085); }
.pk-logo {
	position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); text-align: center; pointer-events: none;
	color: rgba(255, 255, 255, .075); text-shadow: 0 1px 0 rgba(0, 0, 0, .25), 0 -1px 0 rgba(255, 255, 255, .05);
	display: flex; flex-direction: column; align-items: center; line-height: 1;
}
.pk-logo-banane { font-size: calc(var(--pk-f) * 2.6); opacity: .18; filter: grayscale(.4); }
.pk-logo-text { font-family: var(--font-display); font-size: calc(var(--pk-f) * 3.1); letter-spacing: .04em; }
.pk-logo-unter { font-size: calc(var(--pk-f) * 1.05); letter-spacing: .5em; text-transform: uppercase; margin-top: .3em; padding-left: .5em; }
.pk-hoch .pk-logo { top: 72%; }
/* Während einer Hand liegen die Kartenplätze über dem Logo: dann blendet es aus */
.pk-logo { transition: opacity .5s ease; }
.pk-tisch.pk-mit-hand .pk-logo { opacity: 0; }
.pk-tisch:not(.pk-mit-hand) .pk-slot { opacity: 0; }
.pk-hoch .pk-logo-text { font-size: calc(var(--pk-f) * 2.2); }

/* Mitte: Pott, Board, Meldung */
.pk-mitte {
	position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
	display: flex; flex-direction: column; align-items: center; gap: calc(var(--pk-f) * .55); z-index: 2;
}
.pk-hoch .pk-mitte { top: 44%; }
.pk-board { display: flex; gap: calc(var(--pk-kb) * .08); }
.pk-slot {
	width: var(--pk-kb); height: calc(var(--pk-kb) * 1.404); border-radius: calc(var(--pk-kb) * .1);
	border: 1.5px dashed rgba(255, 255, 255, .13); background: rgba(0, 0, 0, .07);
}
.pk-pott {
	display: flex; align-items: center; gap: .45em; padding: .3em .9em .3em .5em; border-radius: 999px;
	background: rgba(0, 0, 0, .42); border: 1px solid rgba(255, 217, 59, .25);
	font-weight: 700; font-size: calc(var(--pk-f) * 1.05); color: #fff; white-space: nowrap;
	box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
}
.pk-pott small { font-weight: 500; color: rgba(255, 255, 255, .7); font-size: .82em; }
.pk-meldung {
	max-width: calc(var(--pk-w) * .5); text-align: center; padding: .4em 1em; border-radius: 999px;
	background: rgba(0, 0, 0, .5); color: #FFF5CC; font-size: calc(var(--pk-f) * .95); font-weight: 600;
	box-shadow: 0 2px 10px rgba(0, 0, 0, .35);
}
.pk-hoch .pk-meldung { max-width: calc(var(--pk-w) * .66); }
.pk-meldung.sieg { background: linear-gradient(180deg, rgba(255, 217, 59, .95), rgba(245, 183, 10, .95)); color: #2B2410; }

/* ---------- Karten ---------- */
.pk-karte {
	position: relative; display: block; width: var(--pk-k); height: calc(var(--pk-k) * 1.404);
	border-radius: calc(var(--pk-k) * .1); background: #fff center/100% 100% no-repeat;
	box-shadow: 0 2px 5px rgba(0, 0, 0, .45), 0 0 0 .5px rgba(0, 0, 0, .25);
}
.pk-karte.verdeckt {
	background:
		radial-gradient(circle at 50% 50%, rgba(255, 217, 59, .55) 0 9%, transparent 10%),
		radial-gradient(circle at 50% 50%, transparent 0 17%, rgba(255, 217, 59, .35) 18% 20%, transparent 21%),
		repeating-linear-gradient(45deg, rgba(255, 217, 59, .2) 0 1px, transparent 1px 5px),
		repeating-linear-gradient(-45deg, rgba(255, 217, 59, .2) 0 1px, transparent 1px 5px),
		linear-gradient(160deg, #1f6b40, #124a2b);
	box-shadow: 0 2px 5px rgba(0, 0, 0, .45), inset 0 0 0 calc(var(--pk-k) * .06) #F7F1DF, inset 0 0 0 calc(var(--pk-k) * .085) rgba(201, 138, 0, .8);
}
.pk-board .pk-karte { width: var(--pk-kb); height: calc(var(--pk-kb) * 1.404); border-radius: calc(var(--pk-kb) * .1); box-shadow: 0 4px 10px rgba(0, 0, 0, .45); transition: transform .35s ease, filter .35s ease, box-shadow .35s ease; }
.pk-karte.neu { animation: pk-aufdecken .5s cubic-bezier(.2, .7, .3, 1) both; }
@keyframes pk-aufdecken {
	0% { transform: translateY(-30%) rotateY(90deg) scale(.85); opacity: 0; }
	55% { opacity: 1; }
	100% { transform: none; opacity: 1; }
}
.pk-board.showdown .pk-karte:not(.best) { filter: brightness(.55) saturate(.6); }
.pk-board .pk-karte.best { transform: translateY(-10%); box-shadow: 0 0 0 2px var(--pk-gold), 0 6px 16px rgba(0, 0, 0, .5), 0 0 18px rgba(255, 217, 59, .45); }

/* ---------- Plätze ---------- */
.pk-plaetze { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.pk-platz {
	position: absolute; transform: translate(-50%, -50%); width: calc(var(--pk-a) * 1.95);
	display: flex; flex-direction: column; align-items: center; pointer-events: auto;
	transition: opacity .3s ease;
}
.pk-ava-rahmen {
	position: relative; width: var(--pk-a); height: var(--pk-a); border-radius: 50%; z-index: 2;
	background: radial-gradient(circle at 35% 30%, #fff, #e8e0c8); padding: 0;
	box-shadow: 0 0 0 3px #1a120c, 0 0 0 4px rgba(255, 217, 59, .45), 0 6px 14px rgba(0, 0, 0, .55);
	transition: box-shadow .3s ease, filter .3s ease;
}
.pk-ava { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
.pk-ring { position: absolute; inset: -9%; width: 118%; height: 118%; transform: rotate(-90deg); pointer-events: none; overflow: visible; }
.pk-ring circle { fill: none; stroke-width: 5.5; }
.pk-ring-spur { stroke: rgba(0, 0, 0, .45); opacity: 0; }
.pk-ring-uhr { stroke: #57E07F; stroke-dasharray: 100 100; stroke-dashoffset: 0; stroke-linecap: round; opacity: 0; }
.pk-dran .pk-ring-spur, .pk-dran .pk-ring-uhr { opacity: 1; }
.pk-dran .pk-ring-uhr { animation: pk-uhr var(--dauer, 20s) linear forwards; animation-delay: var(--verz, 0s); }
@keyframes pk-uhr {
	0% { stroke-dashoffset: 0; stroke: #57E07F; }
	55% { stroke: #FFD93B; }
	80% { stroke: #FF9A3B; }
	100% { stroke-dashoffset: -100; stroke: #FF4D4D; }
}
.pk-dran .pk-ava-rahmen { box-shadow: 0 0 0 3px #1a120c, 0 0 0 5px var(--pk-gold), 0 0 26px rgba(255, 217, 59, .65), 0 6px 14px rgba(0, 0, 0, .55); }
.pk-uhrzahl {
	position: absolute; right: -10%; top: -8%; min-width: 1.9em; height: 1.9em; padding: 0 .35em; border-radius: 999px;
	display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: calc(var(--pk-f) * .9);
	background: #FF4D4D; color: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .5); z-index: 3;
}
.pk-uhrzahl.bank { background: #3B8BFF; }

.pk-schild {
	position: relative; z-index: 3; margin-top: calc(var(--pk-a) * -.2); min-width: calc(var(--pk-a) * 1.55); max-width: 100%;
	padding: .28em .7em .32em; border-radius: calc(var(--pk-f) * .8); text-align: center; line-height: 1.15;
	background: linear-gradient(180deg, rgba(30, 36, 33, .96), rgba(12, 16, 14, .96));
	border: 1px solid rgba(255, 255, 255, .12); box-shadow: 0 4px 12px rgba(0, 0, 0, .5);
}
.pk-name { display: block; font-weight: 700; font-size: calc(var(--pk-f) * .92); color: #F2F5F3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pk-stapel { display: block; font-weight: 800; font-size: calc(var(--pk-f) * 1.02); color: var(--pk-gold); white-space: nowrap; font-variant-numeric: tabular-nums; }
.pk-ich .pk-schild { border-color: rgba(255, 217, 59, .55); }

.pk-tag {
	position: absolute; z-index: 5; right: -.7em; top: -1.05em;
	padding: .16em .62em; border-radius: 999px; font-size: calc(var(--pk-f) * .8); font-weight: 800; letter-spacing: .02em;
	white-space: nowrap; background: #3B4048; color: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .45);
	animation: pk-plopp .28s ease-out both; transform-origin: 80% 100%;
}
.pk-tag.fold { background: #5b5f66; color: #E3E5E8; }
.pk-tag.check { background: #2F7BD8; }
.pk-tag.call { background: #2E9C5A; }
.pk-tag.bet, .pk-tag.raise { background: linear-gradient(180deg, #FFD93B, #F5B70A); color: #2B2410; }
.pk-tag.allin { background: linear-gradient(180deg, #FF5A5A, #C92A2A); }
/* Zustände (setzt aus, offline …) unter dem Schild statt auf dem Avatar */
.pk-tag.status {
	top: auto; bottom: -1.25em; right: 50%; left: auto; translate: 50% 0; transform-origin: 50% 0;
	background: #2A302D; border: 1px solid rgba(255, 255, 255, .16); color: #D8DED9; font-weight: 600;
}
@keyframes pk-plopp { 0% { transform: scale(.6); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }

/* Sitzkarten: immer zur Tischmitte hin */
.pk-sk { position: absolute; z-index: 1; display: flex; pointer-events: none; }
.pk-sk .pk-karte + .pk-karte { margin-left: calc(var(--pk-k) * -.42); }
.pk-sk .pk-karte:first-child { transform: rotate(-7deg); }
.pk-sk .pk-karte:last-child { transform: rotate(7deg) translateY(4%); }
.pk-seite-unten .pk-sk { bottom: calc(100% - var(--pk-a) * .3); left: 50%; transform: translateX(-50%); }
.pk-seite-oben .pk-sk { top: calc(var(--pk-a) * .78); left: 50%; transform: translateX(-50%); }
.pk-seite-links .pk-sk { top: calc(var(--pk-a) * -.05); left: calc(50% + var(--pk-a) * .38); }
.pk-seite-rechts .pk-sk { top: calc(var(--pk-a) * -.05); right: calc(50% + var(--pk-a) * .38); }
.pk-hoch .pk-platz:not(.pk-ich) .pk-sk { top: calc(var(--pk-a) * -.28); bottom: auto; left: 50%; right: auto; transform: translateX(-50%); }
.pk-hoch .pk-platz:not(.pk-ich) .pk-sk.offen { --pk-k: calc(var(--pk-a) * .78); top: calc(var(--pk-a) * -.42); }
/* Eigene Karten groß NEBEN dem Avatar (rechts, der Dealer-Knopf kommt links daneben), sonst stoßen sie an den
   eigenen Einsatz. Hochkant lagen sie bis 2026-12-05 über dem Avatar und deckten den Einsatz zu. */
.pk-ich .pk-sk { --pk-k: var(--pk-ke); bottom: auto; top: calc(var(--pk-a) * -.34); left: calc(50% + var(--pk-a) * .42); right: auto; transform: none; }
.pk-hoch .pk-ich .pk-sk { top: calc(var(--pk-a) * -.56); left: calc(50% + var(--pk-a) * .45); }
.pk-ich .pk-sk .pk-karte + .pk-karte { margin-left: calc(var(--pk-k) * -.18); }
.pk-ich .pk-sk .pk-karte:first-child { transform: rotate(-5deg); }
.pk-ich .pk-sk .pk-karte:last-child { transform: rotate(5deg) translateY(3%); }
.pk-ich .pk-tag:not(.status) { right: auto; left: -.7em; transform-origin: 20% 100%; }
.pk-sk .pk-karte.best { box-shadow: 0 0 0 2px var(--pk-gold), 0 0 14px rgba(255, 217, 59, .6), 0 3px 8px rgba(0, 0, 0, .5); }
.pk-sk .pk-karte.geben { animation: pk-geben .45s cubic-bezier(.2, .7, .3, 1) both; }
@keyframes pk-geben {
	0% { translate: var(--gx, 0) var(--gy, 0); scale: .5; opacity: 0; }
	30% { opacity: 1; }
	100% { translate: 0 0; scale: 1; opacity: 1; }
}
.pk-sk.weg { animation: pk-wegwerfen .45s ease-in forwards; }
@keyframes pk-wegwerfen { to { translate: var(--gx, 0) var(--gy, 0); scale: .4; opacity: 0; } }

/* Zustände */
.pk-raus .pk-ava-rahmen { filter: grayscale(.85) brightness(.62); }
.pk-raus .pk-schild { opacity: .72; }
.pk-aussetzer .pk-ava-rahmen, .pk-weg .pk-ava-rahmen { filter: grayscale(.9) brightness(.55); }
.pk-sieger .pk-ava-rahmen { animation: pk-sieger 1.2s ease-in-out 3; box-shadow: 0 0 0 3px #1a120c, 0 0 0 5px var(--pk-gold), 0 0 34px rgba(255, 217, 59, .9); }
@keyframes pk-sieger { 50% { transform: scale(1.07); } }
.pk-plus {
	position: absolute; z-index: 6; left: 50%; top: 18%; transform: translateX(-50%);
	font-weight: 900; font-size: calc(var(--pk-f) * 1.25); color: var(--pk-gold); white-space: nowrap;
	text-shadow: 0 2px 4px rgba(0, 0, 0, .8), 0 0 12px rgba(255, 217, 59, .5);
	animation: pk-steigen 2.6s ease-out forwards;
}
@keyframes pk-steigen { 0% { transform: translate(-50%, 30%); opacity: 0; } 15% { opacity: 1; } 75% { opacity: 1; } 100% { transform: translate(-50%, -110%); opacity: 0; } }
.pk-handinfo {
	position: absolute; z-index: 6; top: calc(100% + 2px); left: 50%; transform: translateX(-50%);
	max-width: calc(var(--pk-a) * 2.6); padding: .2em .6em; border-radius: 8px; text-align: center; line-height: 1.15;
	font-size: calc(var(--pk-f) * .78); font-weight: 700; background: rgba(255, 217, 59, .94); color: #2B2410;
	box-shadow: 0 2px 8px rgba(0, 0, 0, .45);
}
.pk-seite-unten .pk-handinfo { top: auto; bottom: calc(100% + var(--pk-k) * 1.15); }
.pk-ich .pk-handinfo { display: none; }

/* Chat-Blase am Platz */
.pk-blase {
	position: absolute; z-index: 8; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%);
	max-width: calc(var(--pk-a) * 3); padding: .35em .7em; border-radius: 12px; background: #fff; color: #222;
	font-size: calc(var(--pk-f) * .88); font-weight: 600; line-height: 1.2; text-align: center; white-space: normal;
	box-shadow: 0 4px 14px rgba(0, 0, 0, .45); animation: pk-plopp-b .25s ease-out both;
}
.pk-blase::after { content: ''; position: absolute; left: 50%; top: 100%; transform: translateX(-50%); border: 6px solid transparent; border-top-color: #fff; }
.pk-blase.emoji { font-size: calc(var(--pk-f) * 2.1); padding: .1em .3em; background: transparent; box-shadow: none; }
.pk-blase.emoji::after { display: none; }
.pk-seite-oben .pk-blase { bottom: auto; top: calc(100% + 6px); }
.pk-seite-oben .pk-blase::after { top: auto; bottom: 100%; border-top-color: transparent; border-bottom-color: #fff; }
@keyframes pk-plopp-b { 0% { transform: translateX(-50%) scale(.6); opacity: 0; } 100% { transform: translateX(-50%) scale(1); opacity: 1; } }

/* Freier Platz */
.pk-frei-knopf {
	appearance: none; width: var(--pk-a); height: var(--pk-a); border-radius: 50%; cursor: default;
	border: 2px dashed rgba(255, 255, 255, .25); background: rgba(0, 0, 0, .28); color: rgba(255, 255, 255, .45);
	font: inherit; font-size: calc(var(--pk-f) * .82); font-weight: 600; line-height: 1.1; padding: 0;
	display: flex; align-items: center; justify-content: center; flex-direction: column;
}
.pk-frei-knopf.kann { cursor: pointer; border-color: rgba(255, 217, 59, .75); color: var(--pk-gold); background: rgba(255, 217, 59, .09); }
.pk-frei-knopf.kann:hover { background: rgba(255, 217, 59, .2); }
.pk-frei-knopf .plus { font-size: 1.6em; line-height: 1; }

/* ---------- Einsätze, Chips, Dealer-Button ---------- */
.pk-chips { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.pk-einsatz {
	position: absolute; transform: translate(-50%, -50%); display: flex; align-items: center; gap: .3em;
	transition: left .45s cubic-bezier(.3, .7, .3, 1), top .45s cubic-bezier(.3, .7, .3, 1), opacity .3s ease;
}
.pk-einsatz.flug { opacity: 1; }
.pk-einsatz.angekommen { opacity: 0; transition-delay: 0s, 0s, .05s; }
.pk-einsatz .pk-betrag {
	font-weight: 800; font-size: calc(var(--pk-f) * .9); color: #fff; padding: .08em .5em; border-radius: 999px;
	background: rgba(0, 0, 0, .5); white-space: nowrap; font-variant-numeric: tabular-nums;
}
.pk-einsatz.neu { animation: pk-setzen .38s cubic-bezier(.2, .7, .3, 1) both; }
@keyframes pk-setzen { 0% { translate: var(--vx, 0) var(--vy, 0); opacity: .2; } 100% { translate: 0 0; opacity: 1; } }
.pk-stapelchips { position: relative; width: var(--pk-c); height: calc(var(--pk-c) * 1.4); }
.pk-stapelchips + .pk-stapelchips { margin-left: calc(var(--pk-c) * -.25); }
.pk-chip {
	position: absolute; left: 0; width: var(--pk-c); height: var(--pk-c); border-radius: 50%;
	background: var(--cc); box-shadow: 0 1px 0 rgba(0, 0, 0, .65), 0 2px 3px rgba(0, 0, 0, .3);
}
.pk-chip::before { /* Randflecken */
	content: ''; position: absolute; inset: 0; border-radius: 50%;
	background: repeating-conic-gradient(from 8deg, transparent 0 30deg, var(--cs, rgba(255, 255, 255, .95)) 30deg 45deg);
	-webkit-mask: radial-gradient(circle, transparent 0 60%, #000 61%);
	mask: radial-gradient(circle, transparent 0 60%, #000 61%);
}
.pk-chip::after { /* Innenring */
	content: ''; position: absolute; inset: 23%; border-radius: 50%;
	border: 1px dashed var(--cs, rgba(255, 255, 255, .8)); box-shadow: inset 0 1px 1px rgba(255, 255, 255, .3);
}
.pk-chipgruppe { align-items: flex-end; }

.pk-dealer {
	position: absolute; z-index: 5; width: calc(var(--pk-c) * 1.35); height: calc(var(--pk-c) * 1.35); border-radius: 50%;
	transform: translate(-50%, -50%); display: flex; align-items: center; justify-content: center;
	background: radial-gradient(circle at 35% 30%, #fff, #e9e4d4 60%, #cfc7ad); color: #222; font-weight: 900;
	font-size: calc(var(--pk-c) * .68); box-shadow: 0 3px 6px rgba(0, 0, 0, .55), inset 0 0 0 2px rgba(0, 0, 0, .1);
	transition: left .6s cubic-bezier(.3, .7, .3, 1), top .6s cubic-bezier(.3, .7, .3, 1);
}

/* ---------- Steuerung unter dem Tisch ---------- */
.pk-steuer { position: relative; display: flex; flex-direction: column; gap: 8px; padding: 6px 4px 2px; min-height: 64px; }
.pk-meine { text-align: center; font-weight: 700; color: #FFE88A; font-size: .95rem; min-height: 1.3em; }
.pk-aktionen { display: flex; flex-direction: column; gap: 8px; }
.pk-knopfreihe { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
.pk-akt {
	appearance: none; border: 0; border-radius: 14px; padding: 12px 6px; min-height: 52px; cursor: pointer;
	font: inherit; font-weight: 800; font-size: 1.02rem; line-height: 1.1; color: #fff; letter-spacing: .01em;
	box-shadow: 0 4px 0 rgba(0, 0, 0, .35), 0 6px 14px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .25);
	transition: transform .08s ease, filter .15s ease, box-shadow .08s ease;
}
.pk-akt small { display: block; font-weight: 700; font-size: .8em; opacity: .9; margin-top: 2px; }
.pk-akt:active { transform: translateY(3px); box-shadow: 0 1px 0 rgba(0, 0, 0, .35), 0 3px 8px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .2); }
.pk-akt:hover { filter: brightness(1.08); }
.pk-akt:disabled { filter: grayscale(.7) brightness(.7); cursor: default; }
.pk-fold { background: linear-gradient(180deg, #E0565B, #A92E33); }
.pk-call { background: linear-gradient(180deg, #3FAE6A, #237A46); }
.pk-call.check { background: linear-gradient(180deg, #4A93E6, #2864B5); }
.pk-raise { background: linear-gradient(180deg, #FFE066, #F2B10A); color: #2B2410; }
.pk-raise.allin { background: linear-gradient(180deg, #FF7A3B, #D9480F); color: #fff; }
.pk-raise-zeile { display: flex; flex-direction: column; gap: 6px; padding: 8px; border-radius: 14px; background: rgba(0, 0, 0, .28); border: 1px solid rgba(255, 255, 255, .07); }
.pk-presets { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
.pk-preset {
	appearance: none; border: 1px solid rgba(255, 217, 59, .35); background: rgba(255, 217, 59, .1); color: #FFE88A;
	border-radius: 999px; padding: 5px 11px; font: inherit; font-size: .84rem; font-weight: 700; cursor: pointer;
}
.pk-preset:hover, .pk-preset.an { background: rgba(255, 217, 59, .28); }
.pk-schieber { display: flex; align-items: center; gap: 10px; }
.pk-schieber input[type=range] { flex: 1; min-width: 0; accent-color: var(--pk-gold); height: 28px; }
/* +1 BB neben dem Schieber (2026-12-05): einen Rasterpunkt weiter, gedrückt halten wiederholt */
.pk-bb-plus {
	appearance: none; flex: none; min-height: 38px; padding: 6px 12px; border-radius: 10px; cursor: pointer;
	border: 1px solid rgba(255, 217, 59, .55); background: rgba(255, 217, 59, .18); color: #FFE88A;
	font: inherit; font-size: .9rem; font-weight: 800; white-space: nowrap; touch-action: manipulation;
	user-select: none; -webkit-user-select: none;
}
.pk-bb-plus:hover { background: rgba(255, 217, 59, .3); }
.pk-bb-plus:active { transform: translateY(1px); }
.pk-bb-plus:disabled { opacity: .4; cursor: default; }
.pk-bb-plus:focus-visible { outline: 2px solid var(--pk-gold); outline-offset: 2px; }
.pk-schieber input[type=number] {
	width: 7.2em; padding: 7px 8px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .2);
	background: rgba(0, 0, 0, .35); color: #fff; font: inherit; font-weight: 700; text-align: right;
}
.pk-zeitbank {
	appearance: none; align-self: center; border: 1px solid rgba(59, 139, 255, .6); background: rgba(59, 139, 255, .18); color: #CFE2FF;
	border-radius: 999px; padding: 7px 16px; font: inherit; font-weight: 700; cursor: pointer;
}
.pk-zeitbank:hover { background: rgba(59, 139, 255, .32); }
.pk-vorab { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.pk-vorab-knopf {
	appearance: none; display: flex; align-items: center; gap: 7px; border: 1px solid rgba(255, 255, 255, .16);
	background: rgba(255, 255, 255, .06); color: #DDE6E0; border-radius: 12px; padding: 9px 12px; cursor: pointer;
	font: inherit; font-size: .92rem; font-weight: 600;
}
.pk-vorab-knopf::before {
	content: ''; width: 16px; height: 16px; border-radius: 5px; border: 2px solid rgba(255, 255, 255, .45); flex: none;
}
.pk-vorab-knopf.an { background: rgba(255, 217, 59, .16); border-color: rgba(255, 217, 59, .6); color: #FFE88A; }
.pk-vorab-knopf.an::before { background: var(--pk-gold) center/12px no-repeat; border-color: var(--pk-gold); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 6.5l2.5 2.5L10 3' fill='none' stroke='%232B2410' stroke-width='2'/%3E%3C/svg%3E"); }
.pk-hinweis {
	text-align: center; padding: 10px 12px; border-radius: 12px; background: rgba(255, 255, 255, .06); color: #DDE6E0;
	font-size: .93rem; line-height: 1.4;
}
.pk-hinweis .btn { margin: 6px 4px 0; }
.pk-anfrage {
	display: flex; align-items: center; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 6px;
	padding: 8px 10px; border-radius: 12px; background: rgba(255, 217, 59, .1); border: 1px solid rgba(255, 217, 59, .3);
}
.pk-anfrage img { width: 34px; height: 34px; border-radius: 50%; background: #fff; }

.pk-unterleiste { display: grid; grid-template-columns: 1fr; gap: 10px; padding: 8px 4px 0; }
.pk-eigene-knoepfe { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
.pk-eigene-knoepfe .pk-k-knopf { padding: 8px 13px; }
.pk-k-knopf.gold { border-color: rgba(255, 217, 59, .55); color: #FFE88A; background: rgba(255, 217, 59, .12); }
.pk-chat { border-radius: 14px; background: rgba(0, 0, 0, .25); border: 1px solid rgba(255, 255, 255, .07); padding: 8px; }
.pk-chat-log { max-height: 128px; overflow-y: auto; display: flex; flex-direction: column; gap: 3px; font-size: .86rem; padding-right: 2px; }
.pk-chat-log .z { line-height: 1.3; color: #DDE6E0; }
.pk-chat-log .z b { color: #FFE88A; font-weight: 700; }
.pk-chat-log .z.ich b { color: #8FE0AE; }
.pk-chat-log .z.sys { color: rgba(221, 230, 224, .6); font-style: italic; }
.pk-chat-log .z .emo { font-size: 1.35em; vertical-align: -.1em; }
.pk-chat-eingabe { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 7px; }
.pk-chat-eingabe button {
	appearance: none; border: 1px solid rgba(255, 255, 255, .12); background: rgba(255, 255, 255, .06); color: #E6EEE9;
	border-radius: 999px; padding: 4px 10px; font: inherit; font-size: .82rem; cursor: pointer;
}
.pk-chat-eingabe button.emo { font-size: 1.15rem; padding: 2px 7px; }
.pk-chat-eingabe button:hover { background: rgba(255, 255, 255, .14); }
.pk-karten-optionen { margin: 10px 4px 0; color: rgba(234, 242, 236, .8); font-size: .84rem; }
.pk-karten-optionen .karten-farbwahl { color: inherit; }

@media (min-width: 760px) {
	.pk-unterleiste { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); align-items: start; }
	.pk-eigene-knoepfe { justify-content: flex-start; }
	.pk-aktionen { max-width: 640px; margin: 0 auto; width: 100%; }
}

/* ---------- Fenster (Einkauf, Tisch eröffnen, Rückfrage) ---------- */
.pk-fenster {
	position: fixed; inset: 0; z-index: 10000; display: flex; align-items: center; justify-content: center; padding: 16px;
	background: rgba(6, 14, 10, .62); backdrop-filter: blur(2px);
}
.pk-blatt {
	width: min(440px, 100%); max-height: calc(100% - 8px); overflow-y: auto; border-radius: 22px; padding: 18px 18px 16px;
	background: linear-gradient(180deg, #FFFDF4, #FFF6DE); color: var(--ink); box-shadow: 0 24px 60px rgba(0, 0, 0, .5);
	animation: pk-blatt .22s ease-out both;
}
@keyframes pk-blatt { 0% { transform: translateY(14px) scale(.97); opacity: 0; } 100% { transform: none; opacity: 1; } }
.pk-blatt h3 { margin: 0 0 .6rem; font-family: var(--font-display); font-weight: 400; font-size: 1.45rem; color: var(--jungle-dark); }
.pk-blatt p { margin: .4rem 0; line-height: 1.45; }
.pk-fenster-knoepfe { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; margin-top: 14px; }
.pk-feld { margin: 10px 0; }
.pk-feld > label, .pk-feld > .titel { display: block; font-weight: 700; font-size: .92rem; margin-bottom: 5px; color: var(--ink); }
.pk-wahl { display: grid; gap: 6px; }
.pk-wahl.stufen { grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); }
.pk-wahl.reihe { grid-auto-flow: column; grid-auto-columns: 1fr; }
.pk-wahl label {
	position: relative; display: block; border: 2px solid #E8DDB8; background: #fff; border-radius: 12px; padding: 7px 9px;
	cursor: pointer; font-size: .86rem; line-height: 1.25; text-align: center;
}
.pk-wahl label strong { display: block; font-size: .95rem; color: var(--jungle-dark); }
.pk-wahl input { position: absolute; opacity: 0; pointer-events: none; }
.pk-wahl label:has(input:checked) { border-color: var(--banana-dark); background: #FFF3C2; box-shadow: 0 2px 8px rgba(245, 183, 10, .25); }
.pk-wahl label:has(input:focus-visible) { outline: 2px solid var(--jungle); outline-offset: 2px; }
.pk-betrag-zeile { display: flex; align-items: center; gap: 10px; }
.pk-betrag-zeile input[type=range] { flex: 1; accent-color: var(--banana-dark); }
.pk-betrag-zeile input[type=number] { width: 7.5em; padding: 7px 8px; border-radius: 10px; border: 2px solid #E8DDB8; font: inherit; font-weight: 700; text-align: right; }
.pk-klein { font-size: .85rem; color: var(--ink-soft); }
.pk-warnung { color: var(--danger); font-weight: 600; }
.pk-check { display: flex; align-items: center; gap: 8px; font-size: .92rem; cursor: pointer; }
.pk-check input { width: 18px; height: 18px; accent-color: var(--jungle); }

/* ---------- Kurze Meldung (Fehler, Hinweise) ---------- */
.pk-toast {
	position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 50; max-width: min(92%, 520px);
	padding: 10px 16px; border-radius: 14px; background: rgba(20, 26, 23, .95); color: #fff; font-weight: 600; font-size: .92rem;
	box-shadow: 0 8px 22px rgba(0, 0, 0, .45); text-align: center; animation: pk-blatt .2s ease-out both;
}
.pk-toast.fehler { background: rgba(170, 40, 45, .96); }

/* ---------- Vollbild ---------- */
.pk-raum:fullscreen, .pk-raum.pk-pseudo-fs { border-radius: 0; display: flex; flex-direction: column; padding: 6px 10px 8px; overflow-y: auto; }
.pk-raum.pk-pseudo-fs { position: fixed; inset: 0; z-index: 9999; }
.pk-raum:fullscreen::backdrop { background: #07110c; }
body.pk-noscroll { overflow: hidden; }
/* Nie stauchen: Reicht die Höhe nicht, scrollt der Raum. Sonst schob die Flex-Spalte Steuerung und
   Chat zusammen und ihr Inhalt lief übereinander (gesehen bei 771×718). */
.pk-raum.pk-fs-an > * { flex-shrink: 0; }
.pk-raum.pk-fs-an .pk-buehne { flex: none; }
.pk-raum.pk-fs-an .pk-unterleiste { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); }
.pk-raum.pk-fs-an .pk-karten-optionen { display: none; }

/* Querformat-Handy und breites Vollbild: Steuerung neben dem Tisch.
   Die Klasse setzt einpassen() genau in diesen Fällen, die Spaltenbreite kommt inline. */
.pk-raum.pk-quer-klein { display: grid; grid-template-columns: minmax(0, 1fr) 268px; grid-template-rows: auto auto minmax(0, 1fr); column-gap: 12px; align-content: start; }
.pk-raum.pk-quer-klein .pk-kopfleiste { grid-column: 1 / -1; }
.pk-raum.pk-quer-klein .pk-buehne { grid-column: 1; grid-row: 2 / 4; align-self: start; }
.pk-raum.pk-quer-klein .pk-steuer { grid-column: 2; grid-row: 2; padding-top: 0; }
.pk-raum.pk-quer-klein .pk-unterleiste { grid-column: 2; grid-row: 3; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
/* Die Spalte ist so hoch wie der Tisch (einpassen() setzt die Raumhöhe): der Chatverlauf nimmt den Rest */
.pk-raum.pk-quer-klein .pk-eigene-knoepfe { flex: none; }
.pk-raum.pk-quer-klein .pk-chat { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.pk-raum.pk-quer-klein .pk-chat-log { flex: 1 1 auto; min-height: 36px; max-height: none; }
.pk-raum.pk-quer-klein .pk-chat-eingabe { flex: none; }
.pk-raum.pk-quer-klein .pk-knopfreihe { grid-template-columns: 1fr 1fr 1fr; }
/* Schmale Spalte: Das Zahlenfeld steht als eigene Zeile über Schieber und +1 BB —
   in einer Reihe blieben dem Schieber nur rund 60 px. */
.pk-raum.pk-quer-klein .pk-schieber { gap: 6px; flex-wrap: wrap; }
.pk-raum.pk-quer-klein .pk-schieber input[type=range] { flex: 1 1 120px; }
.pk-raum.pk-quer-klein .pk-schieber input[type=number] { order: -1; flex: 1 1 100%; width: auto; padding: 6px 8px; text-align: center; }
.pk-raum.pk-quer-klein .pk-bb-plus { padding: 6px 9px; }
.pk-raum.pk-quer-klein .pk-presets { gap: 5px; }
.pk-raum.pk-quer-klein .pk-preset { padding: 5px 9px; }
.pk-raum.pk-quer-klein .pk-karten-optionen { display: none; }
.pk-raum.pk-quer-klein.pk-fs-an .pk-buehne { align-self: center; }
@media (max-height: 520px) {
	.pk-raum.pk-quer-klein .pk-akt { min-height: 44px; padding: 8px 4px; font-size: .9rem; }
	.pk-raum.pk-quer-klein .pk-chat-log { max-height: 70px; }
}

@media (prefers-reduced-motion: reduce) {
	.pk-karte.neu, .pk-sk .pk-karte.geben, .pk-einsatz.neu, .pk-tag, .pk-blase, .pk-sieger .pk-ava-rahmen, .pk-plus, .pk-blatt { animation-duration: .01s !important; }
	.pk-einsatz, .pk-dealer { transition-duration: .01s !important; }
}

.pk-rangfolge { margin: .3rem 0 0; padding-left: 1.4rem; line-height: 1.6; }
