/* Poker House — estilos sencillos, sin framework. */
* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
  background: #1b1f24;
  color: #e8e8e8;
}

main { max-width: 860px; margin: 0 auto; padding: 1rem; }

header {
  background: #12151a;
  padding: 0.8rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

header h1 { margin: 0; font-size: 1.2rem; color: #d9b64a; }

h2 { font-size: 1rem; color: #aaa; margin: 1.2rem 0 0.5rem; }

section.panel {
  background: #242a31;
  border-radius: 10px;
  padding: 1rem;
  margin-bottom: 1rem;
}

button {
  background: #d9b64a;
  color: #1b1f24;
  border: none;
  border-radius: 6px;
  padding: 0.5em 1em;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}
button:hover { filter: brightness(1.1); }
button:disabled { opacity: 0.4; cursor: default; }
button.secondary { background: #3a4450; color: #e8e8e8; }
button.danger { background: #b0483f; color: #fff; }

input, select {
  background: #1b1f24;
  color: #e8e8e8;
  border: 1px solid #3a4450;
  border-radius: 6px;
  padding: 0.45em 0.6em;
  font-size: 0.95rem;
}
input[type='number'] { width: 7em; }

table.listing { width: 100%; border-collapse: collapse; }
table.listing th, table.listing td { text-align: left; padding: 0.45em 0.5em; }
table.listing tr { border-bottom: 1px solid #313943; }

.muted { color: #8a939e; font-size: 0.85rem; }

.avatar {
  width: 2.2em;
  height: 2.2em;
  border-radius: 50%;
  vertical-align: middle;
  margin-right: 0.4em;
  border: 2px solid #d9b64a;
}

#auth-logged { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; }

/* ── Cartas ── */
.card {
  display: inline-block;
  background: #fdfdf6;
  color: #16181c;
  border: 1px solid #b9b9ad;
  border-radius: 7px;
  padding: 0.3em 0.15em;
  margin: 0 0.12em;
  font-size: 1.5rem;
  font-weight: 700;
  min-width: 1.85em;
  text-align: center;
}
.card.red { color: #c0392b; }
.card.back {
  background: repeating-linear-gradient(45deg, #35507a, #35507a 4px, #2c4368 4px, #2c4368 8px);
  color: transparent;
  border-color: #26364f;
}

/* ── Mesa ── */
#table-area {
  background: radial-gradient(ellipse at center, #1e7a3c 0%, #14572a 100%);
  border: 6px solid #3d2b1f;
  border-radius: 18px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.seat {
  background: rgba(0, 0, 0, 0.35);
  border: 2px solid transparent;
  border-radius: 10px;
  padding: 0.6rem 0.8rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.seat.turn { border-color: #d9b64a; box-shadow: 0 0 12px rgba(217, 182, 74, 0.4); }
.seat.folded { opacity: 0.45; }
.seat .who { display: flex; align-items: center; gap: 0.5rem; }
.seat .name { font-weight: 700; }
.seat .stack { color: #ffd97a; }
.seat .bet { color: #9fd6ff; font-size: 0.9rem; }

.badge {
  background: #d9b64a;
  color: #1b1f24;
  font-size: 0.7rem;
  font-weight: 800;
  border-radius: 50%;
  width: 1.5em;
  height: 1.5em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.tag {
  font-size: 0.72rem;
  font-weight: 700;
  border-radius: 4px;
  padding: 0.1em 0.45em;
  background: #b0483f;
  color: #fff;
}

#board {
  text-align: center;
  padding: 0.4rem 0;
}
#board .pot { margin-top: 0.4rem; font-size: 1.05rem; color: #ffd97a; font-weight: 700; }

/* ── Acciones ── */
#actions { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; min-height: 3em; }
#actions .amount-group { display: flex; gap: 0.3rem; align-items: center; }

#banner {
  display: none;
  background: #2e4d2f;
  border: 1px solid #4f8a52;
  border-radius: 10px;
  padding: 0.8rem 1rem;
  margin-bottom: 0.8rem;
}
#banner.show { display: block; }

#log {
  font-size: 0.82rem;
  color: #8a939e;
  max-height: 9em;
  overflow-y: auto;
}
#log div { padding: 0.1em 0; border-bottom: 1px dotted #2e353d; }

@media (max-width: 600px) {
  .card { font-size: 1.15rem; }
  #actions button { flex: 1 1 auto; }
}
