body {
    font-family: 'Segoe UI', Arial, sans-serif;
    text-align: center;
    margin: 0;
    background: radial-gradient(ellipse at 50% 0%, #1b5e20 0%, #0d2e0d 60%, #060f06 100%);
    min-height: 100vh;
}

/* ── Turn-Timer ──────────────────────────────────────────────────────────── */
#turnTimer {
    position: fixed;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 6px 18px;
    border-radius: 20px;
    font-size: 15px;
    font-weight: bold;
    z-index: 200;
    pointer-events: none;
}
#turnTimer.timer-ok      { background: rgba(76,175,80,0.85); color: #fff; }
#turnTimer.timer-warning { background: rgba(255,152,0,0.9);  color: #fff; }
#turnTimer.timer-urgent  { background: rgba(211,47,47,0.95); color: #fff; animation: timerPulse 0.5s infinite alternate; }
@keyframes timerPulse { from { opacity: 1; } to { opacity: 0.6; } }

/* ── Auth-Screen (Login / Register) ─────────────────────────────────────── */
#authScreen {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 300;
}

.auth-box {
    background: linear-gradient(160deg, rgba(15,35,15,0.97), rgba(5,18,5,0.98));
    border: 1px solid rgba(76,175,80,0.25);
    border-radius: 20px;
    padding: 40px 48px;
    min-width: 340px;
    box-shadow: 0 24px 64px rgba(0,0,0,0.65);
    color: white;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.auth-logo {
    font-size: 22px;
    font-weight: 700;
    color: #aed581;
    letter-spacing: 0.02em;
    margin-bottom: 4px;
}

.auth-tabs {
    display: flex;
    gap: 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(76,175,80,0.25);
}

.auth-tab {
    flex: 1;
    padding: 10px;
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.5);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.auth-tab.active {
    background: rgba(76,175,80,0.2);
    color: #aed581;
}

#loginForm, #registerForm {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.auth-box input {
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    color: white;
    padding: 11px 14px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.auth-box input:focus {
    border-color: rgba(76,175,80,0.6);
}

.auth-box input::placeholder { color: rgba(255,255,255,0.3); }

.auth-box button {
    background: linear-gradient(135deg, #388e3c, #2e7d32);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 4px;
    transition: opacity 0.2s;
}

.auth-box button:hover { opacity: 0.88; }

.auth-error {
    color: #ef9a9a;
    font-size: 13px;
    min-height: 18px;
    margin: 0;
}

/* ── Tisch-Vorraum ───────────────────────────────────────────────────────── */
#tableRoomScreen {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(160deg, rgba(15,35,15,0.97), rgba(5,18,5,0.98));
    border: 1px solid rgba(76,175,80,0.25);
    color: white;
    padding: 30px 40px;
    border-radius: 18px;
    z-index: 200;
    min-width: 320px;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6);
}

#tableRoomScreen h3 {
    margin-top: 0;
    font-size: 20px;
    color: #aed581;
}

#tableRoomScreen p {
    font-size: 14px;
    color: #ccc;
    margin: 10px 0;
}

.waiting-slots {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 16px 0;
}

.waiting-slot {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
}

.waiting-slot.filled {
    background: rgba(76,175,80,0.18);
    border: 1px solid rgba(76,175,80,0.35);
    color: #c8e6c9;
}

.waiting-slot.empty {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.3);
}

.waiting-status {
    font-size: 13px;
    color: #aed581;
    margin: 8px 0 14px;
}

#tableRoomReady {
    background: linear-gradient(135deg, #388e3c, #2e7d32);
    color: white;
    border: none;
    padding: 12px 36px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-bottom: 8px;
    transition: opacity 0.2s;
}

#tableRoomReady:hover { opacity: 0.85; }

.table-room-actions {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-top: 6px;
}

.waiting-limit-panel {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
    margin-top: 12px;
    font-size: 13px;
    color: #aed581;
}

.waiting-limit-panel input {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 6px;
    color: white;
    padding: 4px 8px;
    font-size: 13px;
}

/* ── Warteliste-Panel (linke Seite) ──────────────────────────────────────── */
.waiting-queue-panel {
    position: fixed;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: rgba(0,0,0,0.55);
    border: 1px solid rgba(76,175,80,0.2);
    border-radius: 12px;
    padding: 10px 12px;
    min-width: 120px;
    z-index: 10;
}

.wq-title {
    font-size: 11px;
    font-weight: 700;
    color: rgba(174,213,129,0.7);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 4px;
}

.wq-entry {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #e8f5e9;
}

.wq-pos {
    color: rgba(255,255,255,0.3);
    font-size: 11px;
    min-width: 14px;
}

.wq-icon { font-size: 14px; }
.wq-name { font-weight: 500; }

#sitButton {
    padding: 10px 28px;
    font-size: 16px;
    background-color: rgba(100, 200, 100, 0.8);
    border: none;
    border-radius: 7px;
    cursor: pointer;
    margin-top: 8px;
}

#sitButton:hover:not(:disabled) {
    background-color: rgba(80, 180, 80, 0.95);
}

#sitButton:disabled {
    opacity: 0.6;
    cursor: default;
}

/* ── Lobby-Screen ────────────────────────────────────────────────────────── */
#lobbyScreen {
    position: fixed;
    inset: 0;
    display: flex;
    flex-direction: column;
    background: linear-gradient(160deg, #0f2010 0%, #07150a 100%);
    color: white;
    z-index: 200;
    overflow: hidden;
}

.lobby-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 28px;
    background: rgba(0, 0, 0, 0.45);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}

.lobby-brand {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: #c8e6c9;
}

.lobby-welcome {
    font-size: 14px;
    color: #a5d6a7;
}

.logout-btn {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.5);
    border-radius: 6px;
    padding: 5px 12px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}
.logout-btn:hover {
    border-color: rgba(255,255,255,0.4);
    color: rgba(255,255,255,0.8);
}

.lobby-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 16px 24px 0;
}

/* Category tabs */
.category-tabs {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 7px 18px;
    font-size: 13px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    color: #ccc;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}

.tab-btn:hover {
    background: rgba(255, 255, 255, 0.13);
    color: white;
}

.tab-btn.active {
    background: rgba(76, 175, 80, 0.35);
    border-color: #4caf50;
    color: #a5d6a7;
    font-weight: 600;
}

/* Table grid */
.table-grid {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-content: flex-start;
    padding-bottom: 10px;
}

.table-grid::-webkit-scrollbar {
    width: 5px;
}
.table-grid::-webkit-scrollbar-track { background: transparent; }
.table-grid::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 3px; }

/* Table cards */
.table-card {
    background: linear-gradient(145deg, rgba(255,255,255,0.07), rgba(255,255,255,0.03));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 16px 18px;
    width: 200px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: border-color 0.2s, transform 0.15s;
}

.table-card:hover {
    border-color: rgba(76, 175, 80, 0.5);
    transform: translateY(-2px);
}

.table-card-header {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.table-card-name {
    font-size: 14px;
    font-weight: 600;
    color: #e8f5e9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Category badges */
.cat-badge {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.4px;
    padding: 2px 8px;
    border-radius: 10px;
    text-transform: uppercase;
    align-self: flex-start;
}

.cat-FREIES_SPIEL  { background: rgba(100, 181, 246, 0.25); color: #90caf9; border: 1px solid rgba(100,181,246,0.3); }
.cat-QUALIFIKATION { background: rgba(255, 213, 79, 0.2);   color: #ffd54f; border: 1px solid rgba(255,213,79,0.3);  }
.cat-LIGA_2        { background: rgba(239, 154, 154, 0.2);  color: #ef9a9a; border: 1px solid rgba(239,154,154,0.3); }
.cat-LIGA_1        { background: rgba(206, 147, 216, 0.25); color: #ce93d8; border: 1px solid rgba(206,147,216,0.3); }

/* Player slots */
.player-slots {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.player-slot {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 6px;
}

.player-slot.filled {
    background: rgba(76, 175, 80, 0.15);
    color: #c8e6c9;
    border: 1px solid rgba(76, 175, 80, 0.25);
}

.player-slot.empty {
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.3);
    border: 1px dashed rgba(255, 255, 255, 0.12);
}

.slot-icon {
    font-size: 14px;
    line-height: 1;
}

/* Card footer */
.table-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 2px;
}

.table-status {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
}

.join-btn {
    padding: 5px 14px;
    font-size: 12px;
    background: rgba(76, 175, 80, 0.6);
    border: 1px solid rgba(76, 175, 80, 0.5);
    border-radius: 6px;
    color: white;
    cursor: pointer;
    transition: background 0.15s;
}

.join-btn:hover {
    background: rgba(76, 175, 80, 0.85);
}

.join-btn.waitlist {
    background: rgba(255, 167, 38, 0.35);
    border-color: rgba(255, 167, 38, 0.4);
    color: #ffcc80;
}

.join-btn.waitlist:hover {
    background: rgba(255, 167, 38, 0.55);
}

/* Create table bar */
.create-table-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 0 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    flex-shrink: 0;
    flex-wrap: wrap;
}

.create-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.45);
    white-space: nowrap;
}

#newTableName {
    padding: 7px 10px;
    font-size: 13px;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.08);
    color: white;
    flex: 1;
    min-width: 120px;
}

#newTableName::placeholder { color: rgba(255,255,255,0.3); }
#newTableName:focus { outline: none; border-color: rgba(76,175,80,0.5); }

#newTableCategory {
    padding: 7px 10px;
    font-size: 13px;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.15);
    background: rgba(30,50,30,0.9);
    color: white;
    cursor: pointer;
}

.create-table-bar button {
    padding: 7px 16px;
    font-size: 13px;
    background: rgba(100, 160, 255, 0.5);
    border: 1px solid rgba(100, 160, 255, 0.4);
    border-radius: 6px;
    color: white;
    cursor: pointer;
    white-space: nowrap;
}

.create-table-bar button:hover {
    background: rgba(100, 160, 255, 0.7);
}

#joinScreen h2 {
    margin-top: 0;
    font-size: 26px;
    color: #c8e6c9;
    letter-spacing: 0.5px;
}

#playerNameInput {
    padding: 11px 14px;
    font-size: 16px;
    border-radius: 8px;
    border: 1px solid rgba(76, 175, 80, 0.4);
    background: rgba(255, 255, 255, 0.08);
    color: white;
    width: 210px;
}

#playerNameInput::placeholder { color: rgba(255,255,255,0.35); }
#playerNameInput:focus { outline: none; border-color: #4caf50; }

#joinScreen button {
    padding: 11px 32px;
    font-size: 16px;
    background: linear-gradient(135deg, #2e7d32, #388e3c);
    border: 1px solid rgba(76,175,80,0.5);
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: background 0.15s;
}

#joinScreen button:hover {
    background: linear-gradient(135deg, #388e3c, #43a047);
}

#waitingText {
    margin-top: 16px;
    font-size: 14px;
    color: #a5d6a7;
    min-height: 20px;
}

#hand {
    position: fixed;
    bottom: 80px;
    left: 10px;
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 8px;
    max-width: calc(100% - 220px);
}

#hand img {
    width: 6vw;
    height: 9vw;
    max-width: 85px;
    max-height: 128px;
    cursor: pointer;
    border: 2px solid #ccc;
    border-radius: 5px;
}

#hand img:hover {
    border-color: #007bff;
}

#trick {
    position: fixed;
    top: 50%;
    left: 45%;
    transform: translate(-50%, -50%);
    display: grid;
    grid-template-areas:
        ". top ."
        "left . right"
        ". bottom .";
    grid-template-columns: 120px 20px 120px;
    grid-template-rows: 185px 10px 185px;
    align-items: center;
    justify-items: center;
}

.trick-top    { grid-area: top; }
.trick-left   { grid-area: left; }
.trick-right  { grid-area: right; }
.trick-bottom { grid-area: bottom; }

.trick-slot {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 110px;
    height: 180px;
}

.trick-slot span {
    color: white;
    font-size: 10px;
    margin-top: 3px;
    text-shadow: 0 0 3px #000;
}

/* Re/Kontra-Badge unter dem Spieler-Icon */
.call-badge {
    display: none;
    font-size: 11px;
    font-weight: bold;
    color: #fff176;
    background: rgba(0, 0, 0, 0.55);
    border-radius: 4px;
    padding: 2px 7px;
    margin-top: 4px;
    white-space: nowrap;
}

#lastTrick {
    position: fixed;
    right: 20px;
    top: 20px;
    display: flex;
    flex-wrap: nowrap;
    gap: 5px;
}

#lastTrick div {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#trick img, .trick-slot img {
    width: 8vw;
    height: 12vw;
    max-width: 110px;
    max-height: 165px;
    border: 2px solid #ccc;
    border-radius: 5px;
}

#lastTrick img {
    width: 5vw;
    height: 7.5vw;
    max-width: 75px;
    max-height: 112px;
    border: 2px solid #ccc;
    border-radius: 5px;
}

#statusIndicator {
    position: fixed;
    top: 10px;
    left: 10px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #ccc;
    transition: background-color 0.3s;
}

#statusText {
    position: fixed;
    top: 10px;
    left: 30px;
    background: rgba(255, 255, 255, 0.7);
    padding: 5px;
    border-radius: 5px;
    font-size: 12px;
}

#buttons {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 150px;
}

button {
    padding: 10px 20px;
    font-size: 16px;
    background-color: rgba(255, 255, 255, 0.7);
    border: 1px solid #ccc;
    border-radius: 5px;
    cursor: pointer;
}

button:hover {
    background-color: rgba(200, 200, 200, 0.7);
}

#modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 999;
}

#modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(160deg, #0f2010 0%, #07150a 100%);
    border: 1px solid rgba(76, 175, 80, 0.25);
    border-radius: 16px;
    z-index: 1000;
    min-width: 340px;
    max-width: 460px;
    width: 92%;
    color: white;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.75);
    overflow: hidden;
    text-align: left;
}

#modal-header {
    padding: 14px 22px;
    background: rgba(0, 0, 0, 0.35);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #a5d6a7;
}

#modal-content {
    padding: 20px 22px;
    max-height: 65vh;
    overflow-y: auto;
}

#modal-content::-webkit-scrollbar { width: 4px; }
#modal-content::-webkit-scrollbar-track { background: transparent; }
#modal-content::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 2px; }

#modal-footer {
    padding: 14px 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* ── Auswertungs-Inhalt ──────────────────────────────────────────────────── */
.eval-winner {
    font-size: 26px;
    font-weight: 800;
    text-align: center;
    padding: 10px 0 18px;
    letter-spacing: 0.5px;
}
.eval-winner.re     { color: #81c784; }
.eval-winner.kontra { color: #ff8a65; }
.eval-winner.none   { color: #90a4ae; }

.eval-parties {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 13px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.party-tag {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    padding: 1px 8px;
    border-radius: 10px;
    margin-right: 6px;
    text-transform: uppercase;
}
.party-tag.re { background: rgba(76, 175, 80, 0.3); color: #a5d6a7; }
.party-tag.ko { background: rgba(255, 138, 101, 0.3); color: #ffccbc; }

.eval-augen {
    display: flex;
    justify-content: space-around;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 16px;
    text-align: center;
}
.eval-augen-col span { display: block; font-size: 11px; color: rgba(255,255,255,0.45); margin-bottom: 4px; }
.eval-augen-col strong { font-size: 26px; font-weight: 700; }

.eval-section-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: rgba(255, 255, 255, 0.35);
    margin-bottom: 6px;
}

.eval-bonus-list {
    margin-bottom: 14px;
}
.eval-bonus-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 2px;
    font-size: 13px;
    color: #ddd;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.eval-bonus-line:last-child { border-bottom: none; }
.eval-bonus-pts { font-weight: 600; white-space: nowrap; margin-left: 12px; }
.eval-bonus-pts.pos { color: #81c784; }
.eval-bonus-pts.neg { color: #e57373; }

.eval-scores {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    overflow: hidden;
}
.eval-score-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 9px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 14px;
}
.eval-score-row:last-child { border-bottom: none; }
.eval-score-pts {
    font-size: 18px;
    font-weight: 700;
}
.eval-score-pts.pos { color: #81c784; }
.eval-score-pts.neg { color: #e57373; }

.modal-btn-ready {
    padding: 9px 22px;
    font-size: 14px;
    background: linear-gradient(135deg, #2e7d32, #388e3c);
    border: 1px solid rgba(76,175,80,0.5);
    border-radius: 8px;
    color: white;
    cursor: pointer;
}
.modal-btn-ready:hover { background: linear-gradient(135deg, #388e3c, #43a047); }

.modal-btn-leave {
    padding: 9px 22px;
    font-size: 14px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    color: #ccc;
    cursor: pointer;
}
.modal-btn-leave:hover { background: rgba(255, 255, 255, 0.12); color: white; }

#declarationButtons {
    position: fixed;
    bottom: 80px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 150px;
}

#soloChoicePanel {
    position: fixed;
    bottom: 80px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 150px;
}

/* Spieler-Positionen */
.player-position {
    position: fixed;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: rgba(0, 0, 0, 0.35);
    border-radius: 10px;
    padding: 8px 14px;
    color: white;
    pointer-events: none;
    z-index: 10;
    overflow: visible;
}

.player-info {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.player-icon {
    font-size: 28px;
}

.player-name {
    font-size: 12px;
    margin-top: 4px;
    font-weight: bold;
    white-space: nowrap;
}

#player-top {
    top: 22%;
    left: 45%;
    transform: translateX(-50%);
}

#player-left {
    left: 18%;
    top: 50%;
    transform: translateY(-50%);
}

#player-right {
    left: 68%;
    top: 50%;
    transform: translateY(-50%);
}

#player-bottom {
    bottom: 260px;
    left: 45%;
    transform: translateX(-50%);
    flex-direction: row;
    align-items: flex-start;
    gap: 10px;
}

/* Stich-Stapel unter/neben den Icons */
.trick-stack {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 8px;
    pointer-events: none;
}

#stack-bottom {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 0;
    max-width: 220px;
    align-self: center;
}

/* Gruppe von 4 Karten pro gewonnenem Stich */
.trick-group {
    position: relative;
    width: 95px;
    height: 38px; /* ~30% der Kartenhöhe sichtbar */
    flex-shrink: 0;
}

/* Einzelne gestapelte Karte */
.stacked-card {
    position: absolute;
    top: 0;
    width: 58px;
    height: 38px;
    overflow: hidden;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
}

.stacked-card img {
    width: 58px;
    height: auto;
    display: block;
}