/* ==========================================================================
   VOLLEYSCORE — Fiches match et compétition V3 (s'appuie sur profile3.css et les blocs .h3-*)
   ========================================================================== */

/* Bandeau du match : photo du club recevant, score au centre, sets en pastilles */
.m3-hero { padding: 0; }
.m3-hero .p3-bg { opacity: .26; object-position: center 40%; }
/* Voile symétrique : le score au centre reste lisible quelle que soit la photo */
.m3-hero::before { background: radial-gradient(60% 90% at 50% 55%, rgba(11, 14, 19, .82) 0%, rgba(11, 14, 19, .62) 100%),
  linear-gradient(90deg, color-mix(in srgb, var(--team, #C8102E) 22%, transparent) 0%, transparent 40%, transparent 60%, rgba(255, 255, 255, .03) 100%); }
.m3-hero .mx-top { border-bottom-color: rgba(255, 255, 255, .08); }
.m3-hero .mx-comp { flex-wrap: wrap; min-width: 0; text-align: left; }
.m3-hero .mx-main { padding: 26px 20px 18px; }
.m3-hero .mx-name { font-size: 26px; }
.m3-hero .mx-vs { color: #fff; }
.m3-hero .p3-credit { top: auto; bottom: 6px; left: auto; right: 12px; text-align: right; }
.m3-hero:has(.p3-credit) { padding-bottom: 18px; } /* bande réservée au crédit : il ne chevauche jamais l'enjeu */
.m3-sets { position: relative; z-index: 1; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; padding: 0 16px 18px; }
.m3-set { display: inline-flex; align-items: baseline; gap: 4px; padding: 4px 9px; border-radius: 4px; background: rgba(13, 16, 22, .82); border: 1px solid rgba(255, 255, 255, .12); font-family: 'JetBrains Mono', monospace; font-size: 13px; color: #A3ACBA; }
.m3-set em { font-style: normal; font-family: 'Barlow Condensed', sans-serif; font-weight: 800; font-size: 11px; letter-spacing: .06em; color: #8B95A6; margin-right: 2px; }
.m3-set b { font-weight: 700; }
.m3-set b.w { color: #fff; }
.m3-set i { font-style: normal; color: #5E6878; }
.m3-set.cur { border-color: var(--red); box-shadow: 0 0 0 1px var(--red) inset; }
.m3-set.tot { background: transparent; border-style: dashed; }
.m3-set sup { color: #9AA3B2; }
.m3-hero .mx-stake { padding-bottom: 20px; }

/* Lignes compactes et blocs latéraux */
.m3-line { grid-template-columns: 44px minmax(0, 1fr); }
.m3-line .h3-mt { flex-direction: column; align-items: flex-start; gap: 1px; }
.m3-line .h3-mt .mono { min-width: 0; }
.m3-line .m3-tm { color: var(--text-dim); font-size: 11px; }
.h3-t.me > span { color: var(--text-main); font-weight: 800; }
.h3-tr.m3-cut { box-shadow: inset 0 -2px 0 color-mix(in srgb, var(--green) 70%, transparent); }
.m3-form + .m3-form { border-top: 1px solid var(--border); }
.m3-form-h { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; align-items: center; gap: 7px; padding: 8px 12px 6px; background: var(--bg-subtle); border-bottom: 1px solid var(--border); font-size: 12.5px; }
.m3-form-h b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m3-form-h span { font-size: 11.5px; color: var(--text-dim); }
.m3-form-h img, .m3-form-h .team-logo { width: 18px; height: 18px; object-fit: contain; }
.m3-video { padding: 10px; }
.m3-video .vcard { width: 100%; }
.m3-lk { font-weight: 600; color: var(--red); text-align: left; }
.m3-lk:hover { text-decoration: underline; }
.p3-kv b a { color: var(--red); }
.m3-body { padding-bottom: 4px; }
.m3-body > .chip-row { padding: 10px 12px 0; }

/* Meilleures notes d'une compétition */
.m3-pl { width: 100%; display: grid; grid-template-columns: 16px 28px minmax(0, 1fr) 22px auto; align-items: center; gap: 8px; padding: 6px 12px; border-bottom: 1px solid var(--border); text-align: left; transition: background .12s ease; }
.m3-pl:hover { background: var(--bg-hover); }
.m3-pl .n { font-size: 12px; font-weight: 700; color: var(--text-dim); }
.m3-pl .mini { width: 28px; height: 28px; border-radius: 50%; overflow: hidden; background: var(--bg-subtle); display: inline-flex; align-items: center; justify-content: center; }
.m3-pl .mini img, .m3-pl .mini svg { width: 100%; height: 100%; object-fit: cover; }
.m3-pl .tx { display: flex; flex-direction: column; min-width: 0; }
.m3-pl .tx b { font-size: 13px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m3-pl .tx em { display: flex; align-items: center; gap: 5px; font-style: normal; font-size: 11px; color: var(--text-dim); min-width: 0; }
.m3-pl .tx em span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m3-pl .tx em img, .m3-pl .tx em .team-logo { width: 14px; height: 14px; object-fit: contain; flex: none; }
.m3-pl .ps { font-size: 11px; color: var(--text-dim); text-align: center; }

/* Navigation de journée */
.m3-nav { display: inline-flex; gap: 4px; }
.m3-nav button { width: 26px; height: 24px; border-radius: 4px; border: 1px solid var(--border); font-size: 16px; line-height: 1; color: var(--text-muted); transition: background .12s ease, color .12s ease; }
.m3-nav button:hover:not(:disabled) { background: var(--bg-hover); color: var(--red); }
.m3-nav button:disabled { opacity: .35; cursor: default; }

/* Bandeau de la compétition */
.m3-lg .p3-hero-left .crest-img, .m3-lg .p3-hero-left .league-badge { width: 112px; height: 112px; }
.m3-leader button { display: inline-flex; align-items: center; gap: 8px; margin: 2px 0 4px; color: #fff; }
.m3-leader button:hover b { color: var(--red); }
.m3-leader b { font-size: 26px !important; line-height: 1.05; }
.m3-leader img, .m3-leader .team-logo { width: 34px; height: 34px; object-fit: contain; }
.m3-trophy { height: 96px; filter: drop-shadow(0 6px 12px rgba(0, 0, 0, .5)); }

/* Mobile : une colonne ; vidéo et diffuseurs remontent juste sous le bandeau */
@media (max-width: 860px) {
  .m3-grid { display: flex; flex-direction: column; gap: 12px; }
  .m3-grid > .p3-main, .m3-grid > .p3-side { display: contents; }
  .m3-grid .m3-prio { order: -1; }
  /* Les blocs deviennent des éléments flex : sans min-width 0, un contenu large (sets, tableaux) déborderait */
  .m3-grid > .p3-main > *, .m3-grid > .p3-side > * { min-width: 0; max-width: 100%; }
}
@media (max-width: 640px) {
  .m3-hero .mx-main { padding: 18px 8px 12px; }
  .m3-hero .mx-name { font-size: 16px; }
  .m3-hero .mx-top { padding: 10px 12px; }
  .m3-set { padding: 3px 7px; font-size: 12px; }
  .m3-hero .p3-credit { max-width: calc(100% - 24px); }
  .m3-leader b { font-size: 20px !important; }
  .m3-lg .p3-hero-left .crest-img, .m3-lg .p3-hero-left .league-badge { width: 72px; height: 72px; }
}
@media (pointer: coarse) {
  .m3-nav button { width: 36px; height: 34px; }
}
@media (prefers-reduced-motion: reduce) { .m3-pl, .m3-nav button { transition: none; } }
