* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: system-ui, sans-serif;
  min-height: 100vh;
  background: radial-gradient(circle at top, #111 0%, #050505 60%, #000 100%);
  color: #e5e5e5;
	overflow-x: hidden;
	overflow-y: auto;
}

.page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 40px;
}

.card {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 520px;
  padding: 40px;
  border-radius: 18px;
  background: rgba(15, 15, 15, 0.88);
  box-shadow: 0 30px 80px rgba(0,0,0,0.7);
  backdrop-filter: blur(6px);
  max-height: calc(100vh - 80px);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.card::-webkit-scrollbar { width: 10px; }
.card::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.10); border-radius: 999px; }
.card::-webkit-scrollbar-track { background: rgba(255,255,255,0.03); }


h1{
  margin-bottom: 12px;
  font-size: 2rem;
  text-align: center;
}

p  { line-height: 1.6; color: #cfcfcf; }

input, button {
  width: 100%;
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  border: none;
  background: #1c1c1c;
  color: #fff;
}

button {
  cursor: pointer;
  background: linear-gradient(135deg, #6b4cff, #8f7bff);
}

.link-accent { color: #8f7bff; text-decoration: none; }
.link-accent:hover { text-decoration: underline; }

.re-logo {
  display: block;
  width: min(420px, 100%);
  height: auto;
  margin: 0 auto 14px;
  filter: drop-shadow(0 14px 30px rgba(0,0,0,0.55));
}

.re-logo--small {
  width: min(320px, 100%);
  margin-bottom: 10px;
}


.re-list { margin-top: 14px; display: grid; gap: 10px; }

.re-char {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(28,28,28,0.9);
  border: 1px solid rgba(255,255,255,0.06);
  cursor: pointer;
}

.re-char:hover {
  border-color: rgba(143,123,255,0.45);
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}

.re-char .name { font-weight: 700; }
.re-char .meta { font-size: 0.9rem; color: #bdbdbd; margin-top: 4px; }
.re-pill {
  align-self: center;
  font-size: 0.85rem;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(143,123,255,0.15);
  border: 1px solid rgba(143,123,255,0.25);
  color: #e9e3ff;
}
.re-actions { margin-top: 14px; display: grid; gap: 10px; }
.re-mutedbtn { background: #1c1c1c; }

/* =========================
   Character Select UI
   ========================= */
.re-tabs {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin: 8px 0 14px;
}

.re-tab {
  flex: 1;
  max-width: 220px;
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(28,28,28,0.9);
  color: #eaeaea;
  cursor: pointer;
}

.re-tab.active {
  border-color: rgba(143,123,255,0.55);
  background: rgba(143,123,255,0.16);
}

.re-tab[disabled] {
  opacity: 0.35;
  cursor: not-allowed;
}

.re-card-wrap {
  display: grid;
  place-items: center;
  margin: 6px 0 10px;
}

.re-race-card {
  width: min(300px, 88%);
  height: auto;
  border-radius: 14px;
  box-shadow: 0 18px 55px rgba(0,0,0,0.6);
  user-select: none;
  -webkit-user-drag: none;
}


.re-arrows{
  display: grid;
  grid-template-columns: 1fr 1fr 1fr; /* echte 3 Zonen */
  align-items: center;
  margin: 10px 0 8px;
}

.re-arrow-btn{
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 6px;
  border-radius: 999px;
  width: auto;              /* wichtig: nicht 100% */
  justify-self: center;     /* Default */
}

.re-arrow-btn.left{ justify-self: start; }
.re-arrow-btn.right{ justify-self: end; }

.re-arrow-img{
  width: 78px;
  height: auto;
  display: block;
  filter: drop-shadow(0 12px 26px rgba(0,0,0,0.55));
}



.re-arrow-btn {
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 6px;
  border-radius: 999px;
}

.re-arrow-btn:hover {
  background: rgba(255,255,255,0.04);
}

.re-arrow-img {
  width: 78px;
  height: auto;
  display: block;
  filter: drop-shadow(0 12px 26px rgba(0,0,0,0.55));
}

.re-race-name {
  text-align: center;
  font-weight: 700;
  margin-top: 6px;
}

.re-note {
  text-align: center;
  font-size: 0.95rem;
  color: #cfcfcf;
  margin-top: 8px;
}

.re-note.warn {
  color: #ffd6a6;
}

.re-input {
  width: 100%;
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  border: none;
  background: #1c1c1c;
  color: #fff;
}
/* ===============================
   Reverse Empire – Loading Screen
   =============================== */

.re-loading {
  display: grid;
  place-items: center;
  gap: 18px;
  padding: 26px 16px 10px;
  text-align: center;
}

.re-loading-logo {
  width: 140px;
  height: 140px;
  object-fit: contain;
  filter: drop-shadow(0 10px 30px rgba(140, 90, 255, 0.28));
}

.re-loading-bar {
  width: min(420px, 92%);
  height: 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  overflow: hidden;
}

.re-loading-fill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg,
    rgba(120, 65, 255, 0.25),
    rgba(170, 110, 255, 0.95),
    rgba(120, 65, 255, 0.25)
  );
  box-shadow: 0 0 22px rgba(170, 110, 255, 0.55);
  transition: width 1.5s linear;
}

.re-loading-text {
  font-size: 0.95rem;
  opacity: 0.85;
}


/* ===============================
   Reverse Empire – Placeholder Game
   =============================== */

.re-game {
  display: grid;
  place-items: center;
  gap: 16px;
  padding: 22px 14px 16px;
  text-align: center;
}

.re-game-logo {
  width: 90px;
  height: 90px;
  object-fit: contain;
  opacity: 0.95;
  filter: drop-shadow(0 10px 30px rgba(140, 90, 255, 0.28));
}

.re-card-stage {
  width: min(820px, 96%);
  height: 220px;
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(0,0,0,0.18);
}

/* ===============================
   Game-Bereich – Kartenfenster
   =============================== */

.re-game .re-card-stage {
  width: min(1500px, 98%);
  height: 420px;
}



.re-card-group {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.re-float-pack {
  display: flex;
  gap: 16px;
  align-items: center;
  animation: re-drift 3.6s ease-in-out forwards;
  transform: translateX(-140%);
  opacity: 0;
}

.re-float-card {
  width: 150px;
  height: 200px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 18px 40px rgba(0,0,0,0.45);
}

/* Karten im Game größer */
.re-game .re-float-card {
  width: 260px;
  height: 360px;
}

.re-game .re-float-pack {
  gap: 28px;
}

/* Links rein -> kurz verweilen -> rechts raus */
@keyframes re-drift {
  0%   { transform: translateX(-140%); opacity: 0; }
  18%  { transform: translateX(-10%);  opacity: 1; }

  /* 👉 längeres Verweilen */
  40%  { transform: translateX(0%);    opacity: 1; }
  70%  { transform: translateX(0%);    opacity: 1; }

  88%  { transform: translateX(140%);  opacity: 1; }
  100% { transform: translateX(170%);  opacity: 0; }
}


.re-workhint {
  margin-top: 2px;
  font-size: 0.95rem;
  opacity: 0.80;
}

.re-card-empty {
  opacity: 0.75;
  font-size: 0.95rem;
  padding: 18px;
}
/* ===============================
   Game – Card Container breiter
   =============================== */

/* Nur wenn im Body die #game View aktiv ist */
body:has(#app .re-game) .card {
  max-width: 1400px;   /* Breite der großen Game-Card */
}
