/* Site de TCG Ranked : mêmes couleurs que l'app (gris sidéral et orange).
   Aucune police ni script externe : rien n'est chargé depuis un autre site.
   Police Poppins, la même que l'app (licence OFL, fonts/Poppins-OFL.txt). */
@font-face { font-family: "Poppins"; src: url("fonts/Poppins-Regular.ttf") format("truetype"); font-weight: 400 500; font-display: swap; }
@font-face { font-family: "Poppins"; src: url("fonts/Poppins-SemiBold.ttf") format("truetype"); font-weight: 600 800; font-display: swap; }
@font-face { font-family: "Poppins"; src: url("fonts/Poppins-Black.ttf") format("truetype"); font-weight: 900; font-display: swap; }

:root {
  --space: #0e0f11;
  --graphite: #16171a;
  --surface: #1e1f23;
  --steel: #3d3f46;
  --silver: #a6a8b0;
  --text: #ededef;
  --orange: #ff7a1a;
  --orange-light: #ffa455;
  --on-orange: #1a0c00;
}

* { box-sizing: border-box; }

html { color-scheme: dark; }

body {
  margin: 0;
  background: var(--graphite);
  color: var(--text);
  font-family: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
}

a { color: var(--orange-light); }
a:hover { color: var(--orange); }

.wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 16px;
}

header.site {
  background: var(--space);
  border-bottom: 1px solid var(--steel);
}

header.site .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 20px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.3px;
  text-decoration: none;
}

.brand img { width: 32px; height: 32px; border-radius: 8px; }
.brand span { color: var(--orange); margin-left: -4px; }
.brand:hover { color: var(--text); }

/* Barre du haut : l'essentiel seulement (Discord et langue) ; le reste est
   dans le pied de page. */
nav.site {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
}

.nav-discord {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 16px 0 12px;
  border-radius: 999px;
  background: #5865f2;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
}

.nav-discord svg { width: 20px; height: 20px; }
.nav-discord svg circle { fill: #5865f2; }
.nav-discord:hover { color: #fff; transform: translateY(-1px); box-shadow: 0 6px 20px rgba(88, 101, 242, 0.45); }

/* Sélecteur de langue, avec le drapeau de la langue affichée. */
.lang-menu { position: relative; }

.lang-menu summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid var(--steel);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary::after {
  content: "";
  width: 7px;
  height: 7px;
  margin: -3px 2px 0 2px;
  border-right: 2px solid var(--silver);
  border-bottom: 2px solid var(--silver);
  transform: rotate(45deg);
  transition: transform 0.2s;
}
.lang-menu[open] summary::after { transform: rotate(-135deg); margin-top: 3px; }
.lang-menu summary:hover { border-color: var(--orange-light); }

.lang-menu img, .footer-langs img {
  width: 22px;
  height: 15px;
  border-radius: 3px;
  object-fit: cover;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.15);
}

.lang-list {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 30;
  min-width: 170px;
  padding: 6px;
  border: 1px solid var(--steel);
  border-radius: 14px;
  background: #1b1c22;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
  animation: menu-in 0.18s ease-out;
}

.lang-list a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--text);
  text-decoration: none;
}

.lang-list a:hover { background: rgba(255, 255, 255, 0.07); color: var(--text); }
.lang-list a[aria-current] { color: var(--orange-light); font-weight: 700; }

@keyframes menu-in { from { opacity: 0; transform: translateY(-6px); } }

main { padding: 32px 0 48px; }

h1 {
  margin: 0 0 8px;
  font-size: 32px;
  line-height: 1.2;
  font-weight: 900;
}

h2 {
  margin: 32px 0 8px;
  font-size: 21px;
  font-weight: 800;
}

p, ul, ol { margin: 0 0 14px; }
li { margin-bottom: 6px; }

.lead { color: var(--silver); font-size: 19px; }
.updated { color: var(--silver); font-size: 15px; }

.hero {
  padding: 28px 0 8px;
  text-align: center;
}

.hero h1 { font-size: 40px; }
.hero h1 span { color: var(--orange); }

.button {
  display: inline-block;
  margin-top: 8px;
  padding: 13px 26px;
  border-radius: 14px;
  background: linear-gradient(var(--orange-light), var(--orange));
  color: var(--on-orange);
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 4px 0 #d9520a;
}

.button:hover { color: var(--on-orange); filter: brightness(1.05); }
.button.soon { background: var(--surface); color: var(--silver); box-shadow: none; border: 1px solid var(--steel); }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin: 28px 0;
}

.card {
  padding: 18px;
  border: 1px solid var(--steel);
  border-radius: 18px;
  background: var(--surface);
}

.card h2 { margin-top: 0; font-size: 18px; color: var(--orange-light); }
.card p { margin: 0; color: var(--silver); font-size: 16px; }

.note {
  padding: 14px 16px;
  border-left: 4px solid var(--orange);
  border-radius: 8px;
  background: var(--surface);
}

footer.site {
  border-top: 1px solid var(--steel);
  background: var(--space);
  color: var(--silver);
  font-size: 14px;
}

footer.site .wrap { max-width: 1160px; }

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 28px;
  padding-top: 40px;
  padding-bottom: 28px;
}

.footer-grid h2 {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}

.footer-grid nav, .footer-langs { display: flex; flex-direction: column; gap: 8px; }
.footer-grid nav a, .footer-langs a { color: var(--silver); text-decoration: none; }
.footer-grid nav a:hover, .footer-langs a:hover, .footer-grid a[aria-current] { color: var(--orange-light); }
.footer-langs a { display: inline-flex; align-items: center; gap: 10px; }
.footer-langs a[aria-current] { color: var(--text); font-weight: 700; }
.footer-brand p { margin: 10px 0 0; max-width: 260px; }

.footer-bottom {
  padding-top: 18px;
  padding-bottom: 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
}

footer.site .footer-bottom p { margin-bottom: 6px; }

@media (max-width: 480px) {
  header.site .wrap { flex-wrap: nowrap; }
  .nav-discord { padding: 0 10px; }
  .nav-discord span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
}

@media (max-width: 760px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 520px) {
  h1 { font-size: 27px; }
  .hero h1 { font-size: 32px; }
}

/* Un élément caché le reste, même s'il a une classe qui fixe son affichage. */
[hidden] { display: none !important; }
