/* ===== Thème global MAX JACK ===== */
:root {
  --mj-bg: #050506;
  --mj-panel: #111111;
  --mj-panel-2: #1a1a1a;
  --mj-gold: #d9a63a;
  --mj-gold-soft: #f0c86a;
  --mj-text: #f5f1e8;
  --mj-muted: #888888;
  --mj-border: #2a2a2a;
  --mj-success: #2e7d32;
  --mj-danger: #b71c1c;
  --mj-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  min-height: 100%;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(circle at top, #181818, var(--mj-bg));
  color: var(--mj-text);
  min-height: 100vh;
  line-height: 1.4;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
a,
input {
  font: inherit;
}

/* ===== Layout global ===== */

.mj-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  background: rgba(0, 0, 0, 0.85);
  border-bottom: 1px solid #222;
}

.mj-logo {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  color: var(--mj-gold);
  text-transform: uppercase;
}

.mj-logo span {
  margin-left: 0.2em;
}

.mj-nav a {
  margin-inline: 0.75rem;
  color: var(--mj-text);
  text-transform: uppercase;
  font-size: 0.9rem;
  position: relative;
}

.mj-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.2rem;
  width: 0;
  height: 2px;
  background: var(--mj-gold);
  transition: width 0.15s ease-out;
}

.mj-nav a:hover::after {
  width: 100%;
}

.mj-header-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.mj-username {
  font-size: 0.9rem;
  color: var(--mj-text);
}

.mj-main {
  padding: 2rem;
}

/* ===== Boutons génériques ===== */

.mj-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1.4rem;
  border-radius: 999px;
  border: 1px solid var(--mj-gold);
  background: var(--mj-gold);
  color: #000;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: transform 0.1s ease, box-shadow 0.1s ease, background 0.1s;
}

.mj-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

.mj-btn-outline {
  background: transparent;
  color: var(--mj-gold);
}

.mj-btn-outline:hover {
  background: rgba(217, 166, 58, 0.08);
}

/* ===== Base commune utilisée par le jeu ===== */

.game-container {
  width: min(1100px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 2rem 0 3rem;
}

.game-container h1 {
  text-align: center;
  color: var(--mj-gold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  font-size: clamp(2rem, 4vw, 3rem);
}

.score {
  color: var(--mj-text);
}

.cards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
}

/* boutons du nouveau game.php */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 170px;
  padding: 0.8rem 1.35rem;
  border-radius: 999px;
  font-weight: 700;
  transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.12s ease;
  box-shadow: var(--mj-shadow);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--mj-gold);
  color: #000;
}

.btn-secondary {
  background: transparent;
  color: var(--mj-gold);
  border: 1px solid var(--mj-gold);
}

.btn-secondary:hover {
  background: rgba(217, 166, 58, 0.08);
}

.btn-new-game {
  background: #ffffff;
  color: #111111;
}

/* ===== Footer ===== */

.mj-footer {
  padding: 1rem 2rem;
  border-top: 1px solid #222;
  font-size: 0.8rem;
  color: var(--mj-muted);
  text-align: center;
  margin-top: 2rem;
}