:root {
  --app-bg: #f6efe7;
  --app-brown: #6f4e37;
  --app-brown-dark: #4e3424;
  --app-accent: #c28b52;
  --app-card: #ffffff;
  --app-muted: #7b6f66;
}

body {
  background: linear-gradient(135deg, #f8f1e9 0%, #efe0d0 100%);
  min-height: 100vh;
  color: #2d2620;
}

.app-navbar {
  background: var(--app-brown);
  color: #fff;
  box-shadow: 0 8px 20px rgba(78, 52, 36, 0.18);
}

.app-navbar .navbar-brand {
  color: #fff;
}

.app-navbar .navbar-brand:hover {
  color: #fff3e3;
}

.btn-primary {
  --bs-btn-bg: var(--app-brown);
  --bs-btn-border-color: var(--app-brown);
  --bs-btn-hover-bg: var(--app-brown-dark);
  --bs-btn-hover-border-color: var(--app-brown-dark);
  --bs-btn-active-bg: var(--app-brown-dark);
  --bs-btn-active-border-color: var(--app-brown-dark);
}

.hero-card {
  background:
    radial-gradient(
      circle at top right,
      rgba(194, 139, 82, 0.25),
      transparent 35%
    ),
    #fff;
  border-radius: 28px;
  padding: 32px;
  box-shadow: 0 18px 45px rgba(78, 52, 36, 0.13);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.hero-card h1 {
  font-size: clamp(2rem, 4vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  margin-bottom: 0.25rem;
}

.hero-card p {
  color: var(--app-muted);
  font-size: 1.1rem;
  margin: 0;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.75rem;
  color: var(--app-accent);
  font-weight: 800;
  margin-bottom: 0.25rem;
}

.card {
  border: 0;
  border-radius: 20px;
  overflow: hidden;
}

.card-header {
  border-bottom: 1px solid rgba(111, 78, 55, 0.1);
  padding: 1rem 1.25rem;
}

.game-card {
  transition:
    transform 0.16s ease,
    box-shadow 0.16s ease;
}

.game-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 38px rgba(78, 52, 36, 0.14);
}

.meta {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  color: var(--app-muted);
  font-size: 0.95rem;
}

.empty-state {
  background: #fff;
  border-radius: 28px;
  padding: 48px 24px;
  text-align: center;
  box-shadow: 0 18px 45px rgba(78, 52, 36, 0.13);
}

.empty-state i {
  font-size: 4rem;
  color: var(--app-accent);
}

.rank-badge {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #f0dfcc;
  color: var(--app-brown-dark);
  font-weight: 800;
}

.table > :not(caption) > * > * {
  padding: 0.95rem 0.9rem;
}

.round-card {
  border: 2px solid rgba(111, 78, 55, 0.12);
}

.form-control:focus,
.form-check-input:focus {
  border-color: var(--app-accent);
  box-shadow: 0 0 0 0.25rem rgba(194, 139, 82, 0.22);
}

.form-check-input:checked {
  background-color: var(--app-brown);
  border-color: var(--app-brown);
}

.accordion-button:not(.collapsed) {
  background: #f4e7d9;
  color: var(--app-brown-dark);
}

.app-footer {
  color: var(--app-muted);
}

@media (max-width: 768px) {
  .hero-card {
    flex-direction: column;
    align-items: stretch;
    padding: 24px;
  }

  .hero-card .btn {
    width: 100%;
  }

  .table {
    font-size: 0.92rem;
  }
}

/* Karten-Engine */
.phase-player-card {
  border: 1px solid rgba(111, 78, 55, 0.16);
  border-radius: 18px;
  padding: 16px;
  background: #fffaf4;
}
.table-card {
  overflow: visible;
}
.pile-card {
  border: 1px dashed rgba(111, 78, 55, 0.25);
  border-radius: 18px;
  padding: 16px;
  background: #fffaf4;
  text-align: center;
}
.deck-visual {
  width: 86px;
  height: 122px;
  border-radius: 14px;
  margin: 8px auto;
  display: grid;
  place-items: center;
  background: repeating-linear-gradient(
    45deg,
    var(--app-brown),
    var(--app-brown) 8px,
    var(--app-brown-dark) 8px,
    var(--app-brown-dark) 16px
  );
  color: #fff;
  font-size: 34px;
  box-shadow: 0 10px 20px rgba(78, 52, 36, 0.18);
}
.hand-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(82px, 1fr));
  gap: 10px;
}
.selectable-card {
  cursor: pointer;
  margin: 0;
}
.selectable-card input {
  display: none;
}
.selectable-card input:checked + .game-card-face {
  transform: translateY(-8px);
  outline: 4px solid rgba(194, 139, 82, 0.45);
  box-shadow: 0 16px 26px rgba(78, 52, 36, 0.24);
}
.game-card-face {
  min-height: 122px;
  border-radius: 14px;
  padding: 12px 8px;
  background: #fff;
  border: 2px solid rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  box-shadow: 0 10px 18px rgba(78, 52, 36, 0.12);
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
  user-select: none;
}
.game-card-face strong {
  font-size: 34px;
  line-height: 1;
}
.game-card-face span {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.game-card-face.mini {
  min-height: 58px;
  width: 42px;
  padding: 6px 4px;
  border-radius: 9px;
  box-shadow: 0 4px 10px rgba(78, 52, 36, 0.12);
}
.game-card-face.mini strong {
  font-size: 18px;
}
.game-card-face.mini span {
  font-size: 7px;
}
.color-red {
  color: #b42318;
  border-color: rgba(180, 35, 24, 0.35);
}
.color-blue {
  color: #175cd3;
  border-color: rgba(23, 92, 211, 0.35);
}
.color-green {
  color: #027a48;
  border-color: rgba(2, 122, 72, 0.35);
}
.color-yellow {
  color: #ca8a04;
  border-color: rgba(250, 204, 21, 0.85);
  background: linear-gradient(135deg, #fffdf0, #fef3c7);
}
.type-wild {
  color: #6f2dbd;
  border-color: rgba(111, 45, 189, 0.35);
  background: linear-gradient(135deg, #fff, #f4ecff);
}
.type-skip {
  color: #344054;
  border-color: rgba(52, 64, 84, 0.35);
  background: linear-gradient(135deg, #fff, #eef2f6);
}
.action-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(111, 78, 55, 0.12);
}
.hit-group {
  max-width: 360px;
}
.player-turn-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(111, 78, 55, 0.1);
}
.player-turn-row.active {
  background: #fff3df;
}
.mini-card-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.played-area {
  border-bottom: 1px dashed rgba(111, 78, 55, 0.18);
  padding-bottom: 12px;
}
.played-area:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
@media (max-width: 768px) {
  .hand-grid {
    grid-template-columns: repeat(auto-fill, minmax(68px, 1fr));
  }
  .game-card-face {
    min-height: 104px;
  }
  .game-card-face strong {
    font-size: 28px;
  }
  .action-panel .btn,
  .hit-group {
    width: 100%;
    max-width: none;
  }
}

.activity-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.activity-item {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(111, 78, 55, 0.06);
  border: 1px solid rgba(111, 78, 55, 0.1);
}
.activity-item small {
  color: #6c757d;
}
.live-dot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: #087f5b;
}
.live-dot::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #12b886;
  box-shadow: 0 0 0 5px rgba(18, 184, 134, 0.12);
}
.phase10-refresh-notice {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 3000;
  padding: 14px 18px;
  border-radius: 16px;
  background: #7a4f35;
  color: #fff;
  text-align: center;
  max-width: min(92vw, 360px);
}

/* Verbesserte Kartenoptik + gruppierte Auslagen */
.game-card-face {
  position: relative;
  overflow: hidden;
  border-width: 2px;
}
.game-card-face::before {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  pointer-events: none;
}
.game-card-face strong,
.game-card-face span {
  position: relative;
  z-index: 1;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.55);
}
.color-red {
  color: #b42318;
  border-color: #ef9a9a;
  background: linear-gradient(135deg, #fff7f7 0%, #ffe4e4 100%);
}
.color-blue {
  color: #175cd3;
  border-color: #93c5fd;
  background: linear-gradient(135deg, #f7fbff 0%, #dbeafe 100%);
}
.color-green {
  color: #027a48;
  border-color: #8fd0b7;
  background: linear-gradient(135deg, #f6fffb 0%, #d9f6ea 100%);
}
.color-yellow {
  color: #b77900;
  border-color: #facc15;
  background: linear-gradient(135deg, #fffde8 0%, #fff0a6 100%);
}
.type-wild {
  color: #6f2dbd;
  border-color: #c4a1ff;
  background: linear-gradient(135deg, #fffaff 0%, #efe2ff 100%);
}
.type-skip {
  color: #344054;
  border-color: #b8c0cc;
  background: linear-gradient(135deg, #ffffff 0%, #e8edf4 100%);
}
.game-card-face.mini {
  width: 58px;
  min-height: 78px;
}
.game-card-face.mini strong {
  font-size: 22px;
}
.game-card-face.mini span {
  font-size: 8px;
}
.played-group {
  padding: 8px 0 10px;
  border-top: 1px dashed rgba(111, 78, 55, 0.16);
}
.played-group:first-of-type {
  border-top: 0;
  padding-top: 0;
}
.played-group-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 800;
  color: var(--app-brown-dark);
  background: #f4e7d9;
  border: 1px solid rgba(111, 78, 55, 0.14);
  border-radius: 999px;
  padding: 4px 9px;
  margin-bottom: 7px;
}

/* Kompakter Live-Ticker statt großer Aktionsbox */
.activity-ticker {
  display: flex;
  align-items: stretch;
  gap: 0;
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(111, 78, 55, 0.12);
}
.activity-ticker-label {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #dff8ee;
  color: #087f5b;
  border-right: 1px solid rgba(111, 78, 55, 0.1);
}
.activity-ticker-track {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  overflow-x: auto;
  scrollbar-width: thin;
}
.activity-ticker-item {
  flex: 0 0 auto;
  max-width: min(520px, 72vw);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 7px 11px;
  border-radius: 999px;
  background: #fffaf4;
  border: 1px solid rgba(111, 78, 55, 0.12);
  color: #2d2620;
  font-size: 0.94rem;
}
.activity-ticker-item small {
  margin-left: 8px;
  color: #7b6f66;
}
.played-card-panel {
  position: sticky;
  top: 16px;
  z-index: 2;
}
.played-card-panel .card-body {
  overflow: visible;
}
@media (max-width: 1199px) {
  .played-card-panel {
    position: static;
  }
  .played-card-panel .card-body {
    overflow: visible;
  }
}
@media (max-width: 768px) {
  .activity-ticker {
    display: block;
  }
  .activity-ticker-label {
    border-right: 0;
    border-bottom: 1px solid rgba(111, 78, 55, 0.1);
  }
  .activity-ticker-track {
    padding: 8px;
  }
}

/* Kartenmodus: ruhigeres Nachladen und kompaktere Info-Leiste */
.phase10-restoring-scroll {
  opacity: 0;
}
.current-phase-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(111, 78, 55, 0.12);
  border-radius: 16px;
  padding: 12px 16px;
}
.current-phase-kicker {
  color: #6f4e37;
  font-weight: 800;
}
.current-phase-main {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 1.05rem;
}
.current-phase-main strong {
  font-size: 1.2rem;
  color: #2d2620;
}
.activity-ticker-track {
  overflow-x: hidden;
}
.activity-ticker-item {
  max-width: min(640px, 48vw);
}
.selectable-card.newly-drawn .game-card-face {
  box-shadow:
    0 0 0 4px rgba(255, 193, 7, 0.28),
    0 16px 34px rgba(255, 193, 7, 0.22);
  transform: translateY(-3px);
}
.selectable-card.newly-drawn::after {
  content: "neu";
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ffc107;
  color: #2d2620;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 800;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
}
@media (max-width: 768px) {
  .current-phase-strip {
    display: block;
  }
  .current-phase-main {
    margin-top: 4px;
  }
  .activity-ticker-item {
    max-width: 82vw;
  }
}

/* Spielerübersicht wieder im Hauptbereich neben Nachzieh- und Ablagestapel */
.inline-players-panel {
  border: 1px dashed rgba(111, 78, 55, 0.25);
  border-radius: 18px;
  padding: 12px;
  background: #fffaf4;
}
.inline-players-title {
  font-weight: 800;
  color: #2d2620;
  margin-bottom: 8px;
}
.player-turn-row.compact {
  padding: 10px 8px;
  border-radius: 12px;
  border-bottom: 1px solid rgba(111, 78, 55, 0.1);
}
.player-turn-row.compact:last-child {
  border-bottom: 0;
}
.player-turn-row.compact.active {
  background: #fff3df;
}
.player-turn-row.compact small {
  white-space: nowrap;
}
.selectable-card {
  position: relative;
}
@media (max-width: 768px) {
  .inline-players-panel {
    min-height: auto;
  }
}

/* Optimierung 2.3: Toasts, aktive Spieleranzeige und ruhiger Seitenwechsel */
.phase10-toast-container {
  z-index: 5000;
  width: min(92vw, 720px);
}
.phase10-toast {
  border-radius: 16px;
  box-shadow: 0 14px 34px rgba(45, 38, 32, 0.18);
  overflow: hidden;
}
.phase10-restoring-scroll {
  opacity: 0 !important;
}
.turn-banner {
  display: flex;
  align-items: center;
  gap: 14px;
  border-radius: 18px;
  padding: 14px 18px;
  border: 1px solid rgba(111, 78, 55, 0.12);
}
.turn-banner.my-turn {
  background: linear-gradient(135deg, #e7f8ef, #ffffff);
  border-color: rgba(25, 135, 84, 0.3);
}
.turn-banner.waiting-turn {
  background: linear-gradient(135deg, #fff7df, #ffffff);
  border-color: rgba(255, 193, 7, 0.38);
}
.turn-banner-icon {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  font-size: 1.25rem;
  color: #fff;
  background: #198754;
  box-shadow: 0 0 0 6px rgba(25, 135, 84, 0.12);
}
.turn-banner.waiting-turn .turn-banner-icon {
  background: #b77900;
  box-shadow: 0 0 0 6px rgba(255, 193, 7, 0.16);
}
.turn-banner-label {
  font-weight: 900;
  font-size: 1.05rem;
}
.player-turn-row.compact.active {
  position: relative;
  background: linear-gradient(135deg, #fff1ce, #fffaf4);
  border: 2px solid rgba(255, 193, 7, 0.75);
  box-shadow: 0 8px 18px rgba(255, 193, 7, 0.18);
  animation: phase10ActivePulse 1.4s ease-in-out infinite;
}
.active-turn-badge {
  color: #2d2620 !important;
  font-weight: 900;
  letter-spacing: 0.02em;
}
@keyframes phase10ActivePulse {
  0%,
  100% {
    box-shadow: 0 8px 18px rgba(255, 193, 7, 0.14);
  }
  50% {
    box-shadow: 0 8px 26px rgba(255, 193, 7, 0.34);
  }
}
@media (prefers-reduced-motion: reduce) {
  .player-turn-row.compact.active {
    animation: none;
  }
}
@media (max-width: 768px) {
  .turn-banner {
    align-items: flex-start;
    padding: 12px 14px;
  }
}

/* Optimierung 2.4: ruhigere Spielerbox */
.inline-players-panel {
  padding: 14px;
}
.inline-players-title {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
}
.player-turn-row.compact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  margin-bottom: 8px;
  border: 1px solid rgba(111, 78, 55, 0.1);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: none;
}
.player-turn-row.compact:last-child {
  margin-bottom: 0;
  border-bottom: 1px solid rgba(111, 78, 55, 0.1);
}
.player-turn-row.compact.active {
  background: linear-gradient(135deg, #fff8e4, #ffffff);
  border: 1px solid rgba(255, 193, 7, 0.6);
  border-left: 6px solid #ffc107;
  box-shadow: 0 8px 20px rgba(45, 38, 32, 0.08);
  animation: none;
}
.player-info-main {
  min-width: 0;
}
.player-name-line {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 1.02rem;
  line-height: 1.2;
  color: #111827;
}
.player-meta-line {
  margin-top: 4px;
  color: #6b5a4c;
  font-size: 0.9rem;
  white-space: nowrap;
}
.player-status-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
  flex: 0 0 auto;
}
.mini-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}
.badge-you {
  background: #0d6efd;
  color: #fff;
}
.badge-turn {
  background: #ffc107;
  color: #2d2620;
}
.badge-laid {
  background: #198754;
  color: #fff;
}
.badge-open {
  background: #6c757d;
  color: #fff;
}
@media (max-width: 768px) {
  .player-turn-row.compact {
    align-items: flex-start;
  }
  .player-status-stack {
    align-items: flex-end;
  }
}

/* Optimierung 2.5: Spielerbox ohne überlappende Badges */
.inline-players-panel {
  overflow: visible;
}
.player-turn-row.compact {
  display: block !important;
  padding: 14px 16px !important;
  margin-bottom: 12px !important;
  border-radius: 18px !important;
  min-width: 0;
}
.player-turn-row.compact.active {
  border-left: 6px solid #ffc107 !important;
  padding-left: 14px !important;
  background: linear-gradient(135deg, #fff6dc, #fffef9) !important;
  box-shadow: 0 10px 24px rgba(45, 38, 32, 0.08) !important;
  animation: none !important;
}
.player-card-top,
.player-card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}
.player-card-bottom {
  margin-top: 8px;
}
.player-name-line {
  min-width: 0;
  flex: 1 1 auto;
  flex-wrap: wrap;
}
.player-meta-line {
  min-width: 0;
  flex: 1 1 auto;
  white-space: normal !important;
  margin-top: 0 !important;
}
.player-status-stack {
  display: none !important;
}
.player-card-top .mini-badge,
.player-card-bottom .mini-badge {
  position: static !important;
  flex: 0 0 auto;
  transform: none !important;
  margin: 0 !important;
}
.badge-turn {
  background: #ffc107 !important;
  color: #2d2620 !important;
  font-size: 0.74rem !important;
  padding: 5px 10px !important;
}
.badge-open,
.badge-laid {
  font-size: 0.72rem !important;
  padding: 5px 10px !important;
}
@media (max-width: 520px) {
  .player-card-top,
  .player-card-bottom {
    align-items: flex-start;
    flex-direction: column;
    gap: 6px;
  }
}

/* Optimierung 2.6: Toast mittig, Sticky-Spielstatus unten */
.phase10-toast-container {
  width: min(94vw, 860px) !important;
  max-width: 860px !important;
}
.phase10-toast {
  width: 100%;
  min-height: 74px;
  display: flex;
  align-items: center;
  border-radius: 22px !important;
  font-size: 1.05rem;
}
.phase10-toast .toast-body {
  padding: 20px 22px;
}
.phase10-restoring-scroll {
  opacity: 1 !important;
}
body:has(.phase10-game-footer) {
  padding-bottom: 104px;
}
.phase10-game-footer {
  position: fixed;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  z-index: 2500;
  width: min(96vw, 1320px);
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(320px, 2fr) minmax(
      240px,
      1fr
    );
  gap: 10px;
  padding: 10px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(111, 78, 55, 0.16);
  backdrop-filter: blur(10px);
}
.phase10-game-footer-section {
  min-width: 0;
  border-radius: 16px;
  padding: 10px 13px;
  background: #fffaf4;
  border: 1px solid rgba(111, 78, 55, 0.1);
}
.phase10-game-footer .footer-label {
  font-size: 0.76rem;
  color: #7b6f66;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 3px;
}
.phase10-game-footer .footer-main {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.phase10-game-footer .footer-main strong {
  white-space: nowrap;
}
.phase10-game-footer .footer-main span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.phase10-game-footer .footer-player.is-me {
  background: linear-gradient(135deg, #e7f8ef, #fffaf4);
  border-color: rgba(25, 135, 84, 0.28);
}
.phase10-game-footer .footer-player.is-me .footer-main i,
.phase10-game-footer .footer-player.is-me .footer-main strong {
  color: #087f5b;
}
.footer-ticker-items {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  overflow: hidden;
}
.footer-ticker-items > span {
  min-width: 0;
  flex: 1 1 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 5px 9px;
  border-radius: 999px;
  background: #ffffff;
  border: 1px solid rgba(111, 78, 55, 0.1);
  font-size: 0.9rem;
}
.footer-ticker-items small {
  color: #7b6f66;
  margin-left: 6px;
}
.phase10-mobile-context {
  display: none;
}
@media (max-width: 992px) {
  body:has(.phase10-game-footer) {
    padding-bottom: 168px;
  }
  .phase10-game-footer {
    bottom: 8px;
    grid-template-columns: 1fr;
    gap: 7px;
    padding: 8px;
    border-radius: 18px;
  }
  .phase10-game-footer-section {
    padding: 8px 10px;
  }
  .footer-ticker-items {
    display: block;
  }
  .footer-ticker-items > span {
    display: block;
    margin-top: 5px;
  }
  .footer-ticker-items > span:nth-child(n + 2) {
    display: none;
  }
  .phase10-mobile-context {
    display: block;
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid rgba(111, 78, 55, 0.12);
    border-radius: 16px;
    padding: 10px 12px;
  }
}

/* Optimierung 2.7: moderner Kartenkopf und bessere Toast-Breite */
.game-mode-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  padding: 22px 24px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(111, 78, 55, 0.12);
  box-shadow: 0 10px 28px rgba(45, 38, 32, 0.07);
}
.game-mode-header-main {
  min-width: 0;
}
.back-mode-btn {
  border: 1px solid rgba(111, 78, 55, 0.14);
  border-radius: 999px;
  color: var(--app-brown-dark);
  font-weight: 800;
  margin-bottom: 12px;
  box-shadow: 0 4px 14px rgba(45, 38, 32, 0.05);
}
.back-mode-btn i {
  font-size: 1.1rem;
  vertical-align: -2px;
}
.game-title-kicker {
  color: #7b6f66;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  margin-bottom: 2px;
}
.game-mode-header h1 {
  font-size: clamp(2.1rem, 4vw, 3.4rem);
  line-height: 1;
}
.game-meta-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
.game-meta-pills span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border-radius: 999px;
  background: #fffaf4;
  border: 1px solid rgba(111, 78, 55, 0.12);
  color: #5f5147;
  font-weight: 800;
  font-size: 0.92rem;
}
.game-meta-pills span.is-active {
  background: #e7f8ef;
  border-color: rgba(25, 135, 84, 0.25);
  color: #087f5b;
}
.game-meta-pills .bi-circle-fill {
  font-size: 0.55rem;
}
.game-mode-header-actions {
  flex: 0 0 auto;
  padding-top: 6px;
}
.phase10-toast-container {
  width: min(94vw, 980px) !important;
  max-width: 980px !important;
}
.phase10-toast {
  min-height: 86px;
  font-size: 1.12rem;
  box-shadow: 0 22px 55px rgba(45, 38, 32, 0.28) !important;
}
.phase10-toast .toast-body {
  padding: 24px 28px !important;
}
@media (max-width: 768px) {
  .game-mode-header {
    display: block;
    padding: 18px;
    border-radius: 22px;
  }
  .game-mode-header-actions {
    padding-top: 14px;
  }
  .game-mode-header-actions .btn,
  .game-mode-header-actions form {
    width: 100%;
  }
  .game-meta-pills span {
    font-size: 0.86rem;
    padding: 6px 9px;
  }
  .phase10-toast {
    min-height: 74px;
    font-size: 1rem;
    border-radius: 18px !important;
  }
}

/* Phase 10 Bot / Solo-Modus */
.badge-bot {
  background: #eef4ff;
  color: #315c9b;
  border: 1px solid rgba(49, 92, 155, 0.18);
}
.phase10-solo-card {
  display: flex;
  gap: 1rem;
  padding: 1rem;
  border-radius: 18px;
  background:
    radial-gradient(
      circle at top right,
      rgba(13, 110, 253, 0.08),
      transparent 45%
    ),
    #fffaf4;
  border: 1px solid rgba(111, 78, 55, 0.14);
}
.phase10-solo-icon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  background: #eef4ff;
  color: #315c9b;
  border: 1px solid rgba(49, 92, 155, 0.18);
  font-size: 1.35rem;
}
.phase10-solo-content {
  min-width: 0;
  flex: 1;
}
.phase10-solo-title {
  font-weight: 900;
  font-size: 1.05rem;
  color: #2d2620;
}
.phase10-solo-text {
  color: #6b5a4c;
  line-height: 1.4;
  margin-top: 0.15rem;
}
.phase10-bot-add-btn {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(49, 92, 155, 0.28);
  color: #315c9b;
  border-radius: 12px;
  font-weight: 800;
  padding: 0.65rem 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}
.phase10-bot-add-btn:hover {
  background: #eef4ff;
  border-color: rgba(49, 92, 155, 0.5);
  color: #254878;
}
.phase10-solo-note {
  margin-top: 0.8rem;
  color: #087f5b;
  font-weight: 800;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.invite-code-big {
  font-size: 2.4rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  background: #fffaf4;
  border: 1px dashed rgba(111, 78, 55, 0.25);
  border-radius: 18px;
  text-align: center;
  padding: 0.8rem;
}
