/* ============================================================
   MYTHÉO — Page « Ta progression »
   Reprend la charte du portail (arêtes franches, or, cartouches
   à coins). Réutilise .idx-wrap, .ring et .mc-bar déjà chargés.
   ============================================================ */

/* --- entête récapitulatif --- */
.pg-hero {
  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;
  background: var(--bg-raised);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--line));
  border-radius: var(--radius-md);
  padding: 20px;
  margin-bottom: 16px;
}
.pg-hero::before, .pg-hero::after {
  content: ""; position: absolute; width: 12px; height: 12px;
  border: 2px solid var(--accent); pointer-events: none;
}
.pg-hero::before { left: -1px; top: -1px; border-right: 0; border-bottom: 0; }
.pg-hero::after { right: -1px; bottom: -1px; border-left: 0; border-top: 0; }

.pg-ring-big { width: 88px; height: 88px; }
.pg-ring-big b { font-size: 21px; color: var(--accent-strong); }
.pg-hero .ring circle.val { stroke: var(--accent-strong); }

.pg-hero-txt { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pg-hero-txt strong {
  font-family: var(--font-display);
  font-size: 20px; font-weight: 700;
  text-wrap: balance;
}
.pg-hero-txt small { color: var(--text-dim); font-size: 14px; line-height: 1.45; }

/* --- bandeau de statistiques --- */
.pg-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 28px;
}
@media (min-width: 560px) {
  .pg-stats { grid-template-columns: repeat(4, 1fr); }
}
.pg-stat {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex; flex-direction: column; gap: 2px;
}
.pg-stat b {
  font-family: var(--font-display);
  font-size: 21px; color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.pg-stat span { font-size: 12.5px; color: var(--text-faint); }

/* --- liste des mondes --- */
.pg-h2 {
  font-family: var(--font-display);
  font-size: 20px; font-weight: 800;
  color: var(--accent-strong);
  margin: 0 0 12px;
}
.pg-worlds {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
@media (min-width: 620px) {
  .pg-worlds { grid-template-columns: 1fr 1fr; }
}

.pg-world {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg-raised);
  border: 1px solid color-mix(in srgb, var(--accent) 22%, var(--line));
  border-radius: var(--radius-md);
  padding: 14px 16px;
  text-decoration: none;
  color: var(--text);
  transition: border-color .15s ease, transform .1s ease, box-shadow .15s ease;
}
.pg-world:hover {
  border-color: var(--accent);
  box-shadow: 0 0 18px color-mix(in srgb, var(--accent) 20%, transparent);
  transform: translateY(-2px);
}
.pg-world:active { transform: scale(.99); }

.pg-ring-mini { width: 46px; height: 46px; flex: none; }
.pg-ring-mini b { font-size: 11px; }

.pg-world-body { display: flex; flex-direction: column; gap: 6px; min-width: 0; flex: 1; }
.pg-world-top { display: flex; align-items: baseline; gap: 8px; }
.pg-world-glyph {
  font-family: var(--font-display);
  color: var(--accent); font-size: 18px; line-height: 1;
}
.pg-world-name { font-family: var(--font-display); font-size: 16px; font-weight: 700; }
.pg-world-count { font-size: 12.5px; color: var(--text-faint); }

/* --- pastilles de badges --- */
.pg-badges { display: flex; gap: 5px; margin-top: 2px; }
.pg-badge {
  width: 22px; height: 22px;
  border-radius: var(--radius-circle);
  display: grid; place-items: center;
  font-size: 12px; line-height: 1;
  border: 1px solid var(--line);
  background: transparent;
  filter: grayscale(1);
  opacity: .38;
}
.pg-badge.on {
  border-color: color-mix(in srgb, var(--accent) 60%, transparent);
  background: color-mix(in srgb, var(--accent) 18%, transparent);
  filter: none;
  opacity: 1;
}

.pg-legend {
  color: var(--text-faint);
  font-size: 12.5px;
  line-height: 1.5;
  margin: 18px 0 0;
}

@media (prefers-reduced-motion: reduce) {
  .ring circle.val { transition: none; }
}
