/* Page d'accueil — sections façon site WoW Forever */

header.top { position: fixed; left: 0; right: 0; }

/* ---------- En-tête illustré ---------- */

.masthead {
  position: relative; min-height: min(92vh, 860px); display: flex; align-items: center;
  padding: 120px 0 90px; overflow: hidden; background: #1d2f6b;
}
.masthead-art {
  position: absolute; inset: 0; background: #1d2f6b center left / cover no-repeat;
}
/* Dégradé vers le bleu de l'illustration pour que le texte reste lisible à droite */
.masthead::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(90deg, transparent 20%, rgba(22, 36, 92, .55) 50%, rgba(20, 32, 84, .85) 75%),
    linear-gradient(180deg, transparent 60%, rgba(10, 20, 50, .9) 100%);
}
.masthead::after { content: ""; position: absolute; inset: 0; z-index: 1; background: var(--grain); mix-blend-mode: overlay; opacity: .6; }
.masthead-inner {
  position: relative; z-index: 2; width: 100%;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  margin-left: auto; max-width: 640px; padding-right: 4vw;
}
.masthead .notice { margin-bottom: 22px; }
/* Grands écrans : aperçu de l'armurerie dans la partie bleue, collé au bord droit. La capture prend les
   teintes du bleu de l'illustration (mode "luminosity") et apparaît en fondu de gauche à droite, en
   diagonale. Taille : aussi grande que possible sans passer sous le texte. Image téléchargée seulement
   si la règle s'applique. */
.masthead-showcase { display: none; }
@media (min-width: 1480px) {
  .masthead { isolation: isolate; }
  .masthead-showcase {
    display: block; position: absolute; z-index: 1; right: -3vw; top: 50%; transform: translateY(-46%);
    height: min(94%, calc((53vw - 290px) * .97)); aspect-ratio: 1300 / 1052;
    background: url("showcase.webp") center / 100% 100% no-repeat;
    mix-blend-mode: luminosity; opacity: .78;
    /* fondu en diagonale depuis la gauche + halo autour du personnage : rien ne s'arrête net */
    -webkit-mask-image: linear-gradient(105deg, transparent 26%, #000 68%),
                        radial-gradient(ellipse 48% 58% at 50% 46%, #000 22%, transparent 100%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(105deg, transparent 26%, #000 68%),
                radial-gradient(ellipse 48% 58% at 50% 46%, #000 22%, transparent 100%);
    mask-composite: intersect;
  }
}
.masthead-emblem { width: 132px; margin-bottom: 14px; filter: drop-shadow(0 8px 18px rgba(0,0,0,.55)); animation: float 7s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-6px) rotate(2deg); } }
.masthead .title { font-size: clamp(36px, 5.2vw, 62px); margin-bottom: 14px; }
.masthead .lead { margin: 0 auto 26px; text-shadow: 0 1px 3px rgba(0,0,0,.6); }
.masthead form.search {
  justify-content: center; padding: 14px; width: 100%;
  background: rgba(8, 16, 44, .55); border: 1px solid rgba(198, 175, 141, .35); border-radius: 4px;
  box-shadow: 0 16px 40px rgba(0,0,0,.35); backdrop-filter: blur(4px);
}
/* Largeur réservée avant que le script remplisse les listes (sinon le bouton change de ligne : CLS) */
.masthead form.search select[name="region"] { min-width: 76px; }
.masthead form.search select[name="server"] { min-width: 180px; }
/* Perso ou guilde : petit sélecteur au-dessus des champs, même style que Personnage / Talents */
.search-kind { flex-basis: 100%; display: flex; justify-content: center; margin-bottom: 2px; }
.search-kind .kinds {
  display: flex; gap: 4px; padding: 4px; border-radius: 999px;
  background: rgba(3, 16, 26, .55); border: 1px solid rgba(239, 227, 200, .16); box-shadow: inset 0 1px 3px rgba(0,0,0,.35);
}
.search-kind label { cursor: pointer; }
.search-kind input { position: absolute; opacity: 0; pointer-events: none; }
.search-kind label span {
  display: block; padding: 8px 18px; border-radius: 999px; font: 600 13.5px/1 var(--modern); color: #b7c6d1;
  transition: background .15s ease, color .15s ease;
}
.search-kind label:hover span { color: #fff; }
.search-kind input:checked + span {
  color: #fff; background: linear-gradient(180deg, #3a9888, var(--jade) 55%, var(--jade-2));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.22), 0 2px 8px rgba(0,0,0,.3);
}
.search-kind input:focus-visible + span { outline: 2px solid var(--glow); outline-offset: 2px; }
.masthead-note { margin: 14px 0 0; font: 500 13px/1 var(--modern); letter-spacing: .06em; color: #c3cde8; }

/* ---------- Compte à rebours ---------- */

.countdown-inner { display: flex; align-items: center; justify-content: space-around; gap: 30px; flex-wrap: wrap; }
.countdown-label { display: flex; align-items: center; gap: 16px; }
.countdown-label img { width: 70px; filter: drop-shadow(0 4px 8px rgba(0,0,0,.4)); }
.countdown-label p { margin: 0; font: 700 24px/1.25 var(--modern); color: var(--ivory); text-shadow: 0 2px 4px rgba(0,0,0,.4); }
.countdown-timer { display: flex; align-items: flex-start; gap: 14px; }
.countdown-timer div { text-align: center; min-width: 74px; }
.countdown-timer b { display: block; font: 700 52px/1 var(--modern); color: var(--ivory); letter-spacing: -.03em; text-shadow: 0 2px 6px rgba(0,0,0,.4); font-variant-numeric: tabular-nums; }
.countdown-timer span { font: 600 13px/1 var(--modern); letter-spacing: .08em; text-transform: uppercase; color: #dfeef1; }
.countdown-timer i { font: 700 30px/1.3 var(--modern); color: var(--sand); font-style: normal; }

/* ---------- Présentation ---------- */

.overview-inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 56px; align-items: center; }
.overview p { color: #f1e7d1; font-size: 16px; }
.overview b { color: #fff4dc; }
.features { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; }
.features li { position: relative; padding-left: 28px; color: #eadcbf; }
.features li::before {
  content: ""; position: absolute; left: 0; top: 6px; width: 14px; height: 14px;
  background: url("svg/emblem.svg") center / contain no-repeat;
}

.video-frame { aspect-ratio: 16 / 9; background: #000; overflow: hidden; }
.video-frame iframe, .video-facade { position: absolute; inset: 8px; width: calc(100% - 16px); height: calc(100% - 16px); border: 0; }
.video-facade { padding: 0; cursor: pointer; background: #000; }
.video-facade img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease, filter .3s ease; }
.video-facade:hover img { transform: scale(1.03); filter: brightness(1.08); }
.video-facade .play {
  position: absolute; left: 50%; top: 50%; width: 84px; height: 84px; transform: translate(-50%, -50%);
  border-radius: 50%; background: rgba(4, 18, 28, .45); box-shadow: 0 0 0 2px rgba(239,227,200,.85), 0 8px 20px rgba(0,0,0,.4);
}
.video-facade .play::after {
  content: ""; position: absolute; left: 34px; top: 26px;
  border-left: 26px solid var(--ivory); border-top: 16px solid transparent; border-bottom: 16px solid transparent;
}

/* ---------- Zones en vidéo ---------- */

.zones { position: relative; min-height: 560px; display: flex; align-items: flex-end; overflow: hidden; background: #0b2433; }
.zones-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.zones-shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(4,18,28,.55) 0%, transparent 30%, transparent 55%, rgba(4,18,28,.9) 100%),
    radial-gradient(ellipse 80% 60% at 50% 100%, rgba(4,18,28,.5), transparent 70%);
}
/* Ornements aux 4 coins, comme le cadre officiel : chacun est retourné vers son angle */
.zones > .corner {
  position: absolute; width: 46px; height: 46px; z-index: 2; pointer-events: none;
  background: url("svg/corner.svg") center / contain no-repeat;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.6));
}
.zones > .corner.tl { top: 24px; left: 18px; }
.zones > .corner.tr { top: 24px; right: 18px; transform: scaleX(-1); }
.zones > .corner.bl { bottom: 24px; left: 18px; transform: scaleY(-1); }
.zones > .corner.br { bottom: 24px; right: 18px; transform: scale(-1, -1); }
.zones-inner { position: relative; z-index: 2; text-align: center; padding-bottom: 64px; }
.zone-tabs { display: flex; justify-content: center; gap: 8px 30px; flex-wrap: wrap; margin: 22px 0 14px; }
.zone-tabs button {
  font: 700 21px/1.3 var(--modern); color: #cfdde4; background: none; border: 0; cursor: pointer;
  padding: 6px 4px 10px; border-bottom: 3px solid transparent; text-shadow: 0 2px 4px rgba(0,0,0,.6);
}
.zone-tabs button:hover { color: #fff; }
.zone-tabs button[aria-selected="true"] { color: #fff; border-bottom-color: var(--glow); }
.zone-text { margin: 0 auto; max-width: 60ch; color: #e5edf0; text-shadow: 0 1px 3px rgba(0,0,0,.8); min-height: 3em; }
.zone-pause {
  position: absolute; left: 76px; bottom: 30px; z-index: 3; width: 38px; height: 38px;
  font-size: 13px; color: #fff; background: var(--royal); border: 0; border-radius: 2px; cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,.4);
}

/* ---------- Registre des héros ---------- */

.section-head { margin-bottom: 36px; }
.section-head.center { text-align: center; }
.home-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; align-items: start; }

.card { border-radius: 4px; padding: 22px 22px 14px; box-shadow: 0 14px 36px rgba(0,0,0,.35); }
.card.dark { background: rgba(4, 18, 28, .72); border: 1px solid rgba(198,175,141,.28); }
.card.parchment {
  color: var(--ink-text);
  background: var(--grain), linear-gradient(180deg, var(--parch-1), var(--parch-2));
  border: 1px solid #b89c78; box-shadow: inset 0 0 0 4px rgba(255,255,255,.35), inset 0 0 0 5px rgba(120,90,50,.35), 0 14px 36px rgba(0,0,0,.35);
}
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.card-title { margin: 0 0 10px; font: 700 24px/1.2 var(--modern); color: var(--ivory); }
.card.parchment .card-title { color: #3b2b17; margin: 0; }
.card.parchment .filters { display: flex; gap: 6px; }
.card.parchment .filters select {
  background: rgba(255,255,255,.55); color: var(--ink-text); border-color: #b89c78; box-shadow: none; padding: 8px 10px; font-size: 13px;
}

.list { list-style: none; margin: 0; padding: 0; }
.list .row { display: flex; align-items: center; gap: 12px; padding: 10px 6px; border-bottom: 1px solid rgba(198,175,141,.14); transition: background .15s ease; }
.list li:last-child .row { border-bottom: 0; }
.list .row:hover { background: rgba(95, 208, 224, .07); }
.list .avatar {
  width: 42px; height: 42px; flex: none; border-radius: 50%; overflow: hidden; background: #0a2a3d;
  box-shadow: 0 0 0 2px var(--sand), 0 0 0 3px rgba(0,0,0,.5);
}
.list .avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.list .who { flex: 1; min-width: 0; line-height: 1.3; }
.list .who b { display: block; font: 600 15px/1.3 var(--modern); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list .who small { color: var(--muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.list .where { font: 600 12px/1 var(--modern); color: var(--muted); white-space: nowrap; }
.list .where .tag { text-transform: none; letter-spacing: 0; font-size: 12px; } /* nom du royaume : casse du jeu, compact */
.list .score { font: 800 20px/1 var(--modern); letter-spacing: -.03em; font-variant-numeric: tabular-nums; color: var(--ivory); text-align: right; min-width: 56px; }
.list .score small { display: block; font: 600 10px/1.5 var(--modern); letter-spacing: .1em; color: var(--muted); }
.list .rank { min-width: 26px; text-align: center; font: 700 16px/1 var(--modern); font-variant-numeric: tabular-nums; color: var(--sand-2); }

/* Classement sur parchemin : encre sombre */
.card.parchment .row { border-bottom-color: rgba(90, 64, 32, .18); }
.card.parchment .row:hover { background: rgba(255,255,255,.35); }
.card.parchment .who b { text-shadow: 0 0 1px rgba(0,0,0,.6), 0 1px 0 rgba(0,0,0,.25); filter: brightness(.72) saturate(1.3); }
.card.parchment .who small, .card.parchment .where, .card.parchment .score small { color: #6d5638; }
.card.parchment .score { color: #3b2b17; }
.card.parchment .rank { color: #9a7a4c; }
/* podium : seulement sur la première page */
.card.parchment .list:not(.paged) li:nth-child(-n+3) .rank { color: #fff; background: linear-gradient(180deg, #d8b774, #9c7535); border-radius: 50%; height: 26px; line-height: 27px; font-size: 15px; box-shadow: 0 2px 4px rgba(0,0,0,.25); }
.card.parchment .tag { background: rgba(255,255,255,.4); }
.card.parchment .tag.normal { color: #1d6d5e; border-color: #1d6d5e77; }
.card.parchment .tag.pvp { color: #8a5a00; border-color: #8a5a0077; }
.card.parchment .tag.rp, .card.parchment .tag.pvp_rp { color: #6a3d9a; border-color: #6a3d9a77; }
.card.parchment .tag.hardcore { color: #a2352a; border-color: #a2352a77; }
.card.parchment .empty { color: #6d5638; }

/* Pages du classement */
.pager { display: flex; justify-content: center; align-items: center; gap: 6px; margin-top: 16px; flex-wrap: wrap; }
.pager:empty { display: none; }
.pager button {
  min-width: 36px; height: 36px; padding: 0 10px; cursor: pointer; font: 600 14px/1 var(--modern);
  font-variant-numeric: tabular-nums; color: #4a3920; background: rgba(255,255,255,.35);
  border: 1px solid rgba(90, 64, 32, .3); border-radius: 6px; transition: background .15s ease;
}
.pager button:hover:not(:disabled) { background: rgba(255,255,255,.6); }
.pager button[aria-current="page"] { color: #fff; background: linear-gradient(180deg, #d8b774, #9c7535); border-color: transparent; cursor: default; }
.pager button:disabled { opacity: .35; cursor: default; }
.pager span { color: #6d5638; padding: 0 2px; }

@media (max-width: 900px) {
  .masthead-inner { margin: 0 auto; padding: 0; }
  .masthead::before { background: linear-gradient(180deg, rgba(20,32,84,.35) 0%, rgba(20,32,84,.8) 60%, rgba(10,20,50,.95) 100%); }
  .overview-inner, .home-cols { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .zone-pause { left: auto; right: 72px; bottom: auto; top: 28px; }
  .countdown-timer b { font-size: 38px; }
  .countdown-timer div { min-width: 56px; }
}
@media (max-width: 420px) {
  .list .where { display: none; }
}

/* ---------- Encart du calculateur de talents ---------- */

.tc-promo { padding: 48px 0 40px; }
.promo-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.promo-text { margin: 8px 0 0; color: #d9e2e8; }
.promo-classes { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.promo-classes a {
  display: flex; align-items: center; gap: 8px; padding: 6px 14px 6px 6px; border-radius: 999px;
  background: rgba(3, 20, 32, .5); border: 1px solid rgba(239, 227, 200, .16);
  font: 600 14px/1 var(--modern); color: #e3eef0; transition: border-color .15s ease, transform .15s ease;
}
.promo-classes a:hover { border-color: var(--sand); transform: translateY(-1px); }
.promo-classes img { width: 30px; height: 30px; border-radius: 50%; box-shadow: 0 0 0 1px rgba(0,0,0,.6); }
