/* =========================================================
   Le Repaire des Gardiens — feuille de style principale
   Conçue "mobile d'abord" : les règles de base visent le
   téléphone, les @media (min-width) élargissent pour l'ordi.
   ========================================================= */

/* ---------- 1. Couleurs et polices (charte graphique) ---------- */
:root {
  --anthracite: #1f1f24;   /* fond principal */
  --acier: #2e2b28;        /* cartes, blocs */
  --acier-bord: #3f3b36;   /* bordures des cartes */
  --or: #c8a53e;           /* accent principal */
  --or-pale: #e2c66a;      /* reflets, survols */
  --bronze: #8f7426;       /* ombres, gravures */
  --vert-mousse: #3b5532;  /* étiquettes, menus */
  --vert-profond: #20361c; /* grands aplats */
  --argent-clair: #d9d8d6; /* texte principal */
  --argent: #adaba9;       /* texte secondaire */
  --blanc-titre: #f0eee9;  /* titres */
  --nuit: #18181c;         /* en-tête, pied de page */

  --police-titre: 'Cinzel', Georgia, serif;
  --police-texte: 'Inter', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;

  --rayon: 10px;
  --largeur-max: 1180px;
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--anthracite);
  color: var(--argent-clair);
  font-family: var(--police-texte);
  font-size: 16px;
  line-height: 1.6;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--argent-clair); text-decoration: none; }
a:hover, a:focus-visible { color: var(--or-pale); }
:focus-visible { outline: 2px solid var(--or-pale); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--police-titre); font-weight: 500; color: var(--blanc-titre); line-height: 1.2; margin: 0; }
h1 { font-size: 1.9rem; }
h2 { font-size: 1.45rem; }
h3 { font-size: 1.15rem; }
p { margin: 0; }
.conteneur { width: 100%; max-width: var(--largeur-max); margin: 0 auto; padding: 0 18px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.surtitre { font-size: .78rem; letter-spacing: .3em; text-transform: uppercase; color: var(--or-pale); }
.texte-secondaire { color: var(--argent); }

/* ---------- 3. En-tête et menu ---------- */
.entete { position: sticky; top: 0; z-index: 20; background: var(--nuit); border-bottom: 1px solid #34343a; }
.entete .conteneur { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; }
.marque { display: flex; align-items: center; gap: 10px; }
.marque img { width: 40px; height: 40px; }
.marque span { font-family: var(--police-titre); font-size: .95rem; letter-spacing: .12em; color: var(--argent-clair); }

.bouton-menu {
  display: inline-flex; align-items: center; justify-content: center;
  width: 46px; height: 46px; border-radius: 8px;
  background: transparent; border: 1px solid #45454c; color: var(--argent-clair); cursor: pointer;
}
.bouton-menu svg { width: 24px; height: 24px; }

.menu { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--nuit); border-bottom: 1px solid #34343a; }
.menu.ouvert { display: block; }
.menu ul { list-style: none; margin: 0; padding: 8px 18px 16px; }
.menu a { display: block; padding: 14px 4px; font-size: 1.05rem; border-bottom: 1px solid #2a2a30; }
.menu a[aria-current="page"] { color: var(--or-pale); }
.menu .lien-builds { color: var(--or); }

/* Bandeau « en cours de construction » (à retirer quand le site sera complet) */
.chantier { background: var(--vert-profond); border-bottom: 1px solid var(--bronze); font-size: .88rem; color: var(--argent-clair); }
.chantier .conteneur { display: flex; align-items: center; gap: 12px; padding-top: 10px; padding-bottom: 10px; }
.chantier > .conteneur > svg { flex: none; width: 22px; height: 22px; color: var(--or-pale); }
.chantier p { flex: 1; }
.chantier strong { color: var(--or-pale); font-weight: 600; }
.chantier-fermer { flex: none; width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; background: transparent; border: none; color: var(--argent); cursor: pointer; border-radius: 6px; }
.chantier-fermer:hover { color: var(--argent-clair); }
.chantier-fermer svg { width: 18px; height: 18px; }
.chantier.masque { display: none; }

/* ---------- 4. Boutons, étiquettes, cartes ---------- */
.bouton {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 22px; border-radius: 8px; border: none;
  background: var(--or); color: var(--anthracite); font: 600 1rem var(--police-texte); cursor: pointer;
}
.bouton:hover, .bouton:focus-visible { background: var(--or-pale); color: var(--anthracite); }
.bouton-contour { background: transparent; color: var(--argent-clair); border: 1px solid #55555c; }
.bouton-contour:hover { background: transparent; color: var(--or-pale); border-color: var(--or); }

.etiquette { display: inline-block; font-size: .75rem; padding: 3px 10px; border-radius: 4px; background: var(--vert-mousse); color: #e4ecdf; }
.carte > .etiquette { align-self: flex-start; }
.etiquette-attente { background: #4a4535; color: #f0e3b8; }
.etiquette-recoupe { background: #3d4a3a; color: #e4ecdf; }
.choix { height: 50px; padding: 0 12px; border-radius: 8px; background: var(--anthracite); color: var(--argent-clair); border: 1px solid #55555c; font: 1rem var(--police-texte); }
.etiquette-contour { background: transparent; border: 1px solid #5a564f; color: #c9c7c3; }

.carte { display: flex; flex-direction: column; gap: 10px; padding: 20px; background: var(--acier); border: 1px solid var(--acier-bord); border-radius: var(--rayon); }
a.carte:hover { border-color: var(--or); color: var(--argent-clair); }
.carte h3 { font-size: 1.1rem; }
.carte .icone { width: 28px; height: 28px; color: var(--or); }
.carte-mise-en-avant { border-color: var(--or); }

.grille { display: grid; gap: 14px; grid-template-columns: 1fr; }

.emplacement-image {
  aspect-ratio: 16 / 9; border-radius: 6px; border: 1px dashed #5a564f; background: #26241f;
  display: flex; align-items: center; justify-content: center; font-size: .8rem; color: #9e9b96; text-align: center; padding: 8px;
}

/* ---------- 5. Bandeau d'accueil ---------- */
.bandeau {
  background: var(--anthracite) url('../img/fond-banniere-mobile.jpg') center / cover no-repeat;
  border-bottom: 2px solid var(--or);
}
.bandeau .conteneur { padding-top: 28px; padding-bottom: 32px; display: flex; flex-direction: column; gap: 14px; }
.bandeau .logo { width: 180px; }
.bandeau p { max-width: 520px; }
.voile { background: linear-gradient(90deg, rgba(20,20,24,.92) 0%, rgba(20,20,24,.75) 55%, rgba(20,20,24,.25) 100%); }

.recherche { display: flex; gap: 8px; width: 100%; max-width: 600px; }
.recherche input {
  flex: 1; min-width: 0; height: 50px; padding: 0 16px; border-radius: 8px;
  background: var(--anthracite); color: var(--argent-clair); border: 1px solid var(--or);
  font: 1rem var(--police-texte);
}
.recherche input::placeholder { color: #8d8b88; }

/* ---------- 6. Sections ---------- */
.section { padding-top: 36px; padding-bottom: 8px; }
.section-entete { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 18px; }
.section-entete a { color: var(--or-pale); font-size: .95rem; }

.semaine .carte { gap: 6px; }
.semaine .quoi { font-size: .78rem; letter-spacing: .15em; text-transform: uppercase; color: var(--or-pale); }

.encart { display: flex; flex-direction: column; gap: 16px; padding: 24px; background: var(--vert-profond); border: 1px solid var(--or); border-radius: 12px; }

.reseaux { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- 7. Pages intérieures ---------- */
.titre-page { padding-top: 28px; padding-bottom: 8px; display: flex; flex-direction: column; gap: 10px; }
.fil { font-size: .85rem; color: var(--argent); display: flex; flex-wrap: wrap; gap: 6px; }
.fil a { color: var(--argent); }
.liste-sous-pages { display: grid; gap: 12px; }
.prose { max-width: 720px; display: flex; flex-direction: column; gap: 14px; }
.prose h2 { margin-top: 12px; }

/* Fiches de sets */
.filtres { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.filtres label { font-size: .85rem; color: var(--argent); }
.bonus { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; background: #26241f; border-radius: 6px; font-size: .92rem; }
.bonus-icone { flex: none; width: 40px; height: 40px; border-radius: 6px; background: #1a1a1e; border: 1px solid var(--bronze); }
.bonus-icone-vide { display: inline-flex; align-items: center; justify-content: center; font-family: var(--police-titre); color: var(--or); font-size: 1.1rem; }
.bonus strong { color: var(--or-pale); font-weight: 600; }
.vide { padding: 24px; text-align: center; color: var(--argent); border: 1px dashed #4a4a50; border-radius: var(--rayon); }

/* ---------- 8. Pied de page ---------- */
.pied { margin-top: 56px; background: var(--nuit); border-top: 1px solid #34343a; font-size: .88rem; color: #a9a7a4; }
.pied .conteneur { padding-top: 26px; padding-bottom: 26px; display: flex; flex-direction: column; gap: 10px; }
.pied .nom { font-family: var(--police-titre); letter-spacing: .15em; color: var(--or); }
.pied nav { display: flex; flex-wrap: wrap; gap: 14px; }
.pied a { color: #c9c7c3; }

/* ---------- 9. Tablette (≥ 640 px) ---------- */
@media (min-width: 640px) {
  h1 { font-size: 2.4rem; }
  .grille-2, .grille-3, .grille-4 { grid-template-columns: repeat(2, 1fr); }
  .liste-sous-pages { grid-template-columns: repeat(2, 1fr); }
  .encart { flex-direction: row; align-items: center; justify-content: space-between; }
  .filtres { flex-direction: row; align-items: end; }
}

/* ---------- 10. Ordinateur (≥ 960 px) ---------- */
@media (min-width: 960px) {
  h1 { font-size: 2.9rem; }
  .bouton-menu { display: none; }
  .menu { display: block; position: static; border: none; background: none; }
  .menu ul { display: flex; gap: 4px; padding: 0; }
  .menu a { padding: 10px 14px; border: none; font-size: .95rem; }
  .menu a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--or); }
  .menu .lien-builds { background: var(--or); color: var(--anthracite); border-radius: 6px; font-weight: 600; }
  .menu .lien-builds:hover { background: var(--or-pale); color: var(--anthracite); }
  .marque span { font-size: 1.15rem; }
  .bandeau { background-image: url('../img/fond-banniere.jpg'); background-position: 70% center; }
  .bandeau .conteneur { padding-top: 48px; padding-bottom: 56px; gap: 18px; }
  .bandeau .logo { width: 260px; }
  .grille-3 { grid-template-columns: repeat(3, 1fr); }
  .grille-4 { grid-template-columns: repeat(4, 1fr); }
  .section { padding-top: 56px; }
  .pied .conteneur { flex-direction: row; justify-content: space-between; align-items: center; }
}

/* ---------- Bannière d'une page de raid / donjon ---------- */
.raid-banniere { position: relative; margin-top: 16px; border-radius: 10px; overflow: hidden; min-height: 220px; display: flex; align-items: flex-end;
  background: #1a1a1e center / cover no-repeat; border: 1px solid #3a3530; }
.raid-banniere::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20,20,24,.15) 0%, rgba(20,20,24,.55) 55%, rgba(20,20,24,.95) 100%); }
.raid-banniere-contenu { position: relative; padding: 20px; display: flex; flex-direction: column; gap: 10px; width: 100%; }
.raid-banniere h1 { text-shadow: 0 2px 12px rgba(0,0,0,.7); }
@media (min-width: 768px) { .raid-banniere { min-height: 340px; } .raid-banniere-contenu { padding: 32px; } }
.etapes-rencontre { margin: 10px 0 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.liste-raids { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 768px) { .liste-raids { grid-template-columns: repeat(2, 1fr); } }
.carte-raid { margin-top: 0; min-height: 200px; color: inherit; text-decoration: none; transition: border-color .2s, transform .2s; }
.carte-raid:hover { border-color: var(--or); transform: translateY(-2px); }
@media (min-width: 768px) { .carte-raid { min-height: 240px; } }
.perk { display: inline-flex; align-items: center; gap: 6px; }
.perk img { width: 22px; height: 22px; border-radius: 50%; background: #1a1a1e; flex: none; }
/* Sous-menus d'archétypes (page Armes) */
.archetype { border: 1px solid #3a3530; border-radius: 10px; background: #26241f; margin-bottom: 12px; }
.archetype > summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 12px; padding: 16px 20px; }
.archetype > summary::-webkit-details-marker { display: none; }
.archetype > summary::before { content: '›'; color: var(--or); font-size: 1.4rem; line-height: 1; transition: transform .2s; }
.archetype[open] > summary::before { transform: rotate(90deg); }
.archetype > summary:hover .archetype-nom { color: var(--or-pale); }
.archetype-nom { font-family: var(--police-titre); font-size: 1.25rem; color: var(--blanc-titre); flex: 1; }
.archetype-nombre { font-size: .9rem; }
.archetype-contenu { padding: 0 20px 20px; }
