/* Ivoire Foot AI — identité orange, blanc, vert (drapeau ivoirien). */

:root {
  --orange: #F77F00;
  --orange-dark: #C96500;
  --orange-soft: #FFF1E2;
  --green: #009E60;
  --green-dark: #007A4A;
  --green-soft: #E3F6EE;
  --ink: #15181C;
  --ink-2: #3D444D;
  --muted: #6B737D;
  --line: #E4E7EB;
  --bg: #F6F7F9;
  --surface: #FFFFFF;
  --danger: #C62828;
  --danger-soft: #FDECEC;
  --info: #1E63B8;
  --info-soft: #E7F0FB;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .06), 0 4px 16px rgba(16, 24, 40, .06);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --display: "Arial Black", "Segoe UI Black", system-ui, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #F1F3F5;
    --ink-2: #C9CED4;
    --muted: #98A0AA;
    --line: #2A3038;
    --bg: #0E1114;
    --surface: #161A1F;
    --orange-soft: #33230F;
    --green-soft: #0F2A1F;
    --danger-soft: #3A1717;
    --info-soft: #14243A;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.5;
  color: var(--ink); background: var(--bg);
}
img { max-width: 100%; display: block; }
a { color: var(--green-dark); }
@media (prefers-color-scheme: dark) { a { color: #3DD598; } }
h1, h2, h3 { line-height: 1.2; margin: 0; }
code { font-size: .85em; background: var(--bg); padding: .1em .35em; border-radius: 4px; }

.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }
main:focus { outline: none; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.warn { color: var(--orange-dark); }

/* --- Bande tricolore et en-tête --- */
.flag-bar { display: flex; height: 5px; }
.flag-bar span { flex: 1; }
.flag-bar span:nth-child(1) { background: var(--orange); }
.flag-bar span:nth-child(2) { background: #fff; }
.flag-bar span:nth-child(3) { background: var(--green); }

.site-header { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); margin-right: auto; }
.brand-text { font-family: var(--display); font-size: 1.05rem; letter-spacing: .02em; }
.brand-text strong { color: var(--orange); }

.site-nav { display: flex; gap: 4px; flex-wrap: wrap; }
.site-nav a {
  text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: .92rem;
  padding: 8px 12px; border-radius: 999px;
}
.site-nav a:hover { background: var(--bg); }
.site-nav a.active { background: var(--orange); color: #fff; }

.menu-button { display: none; background: none; border: 1px solid var(--line); border-radius: 10px; width: 44px; height: 44px; cursor: pointer; }
.menu-icon, .menu-icon::before, .menu-icon::after {
  display: block; width: 20px; height: 2px; background: var(--ink); margin: 0 auto; position: relative; content: "";
}
.menu-icon::before { position: absolute; top: -6px; }
.menu-icon::after { position: absolute; top: 6px; }

@media (max-width: 900px) {
  .menu-button { display: block; }
  .site-nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column;
    background: var(--surface); border-bottom: 1px solid var(--line); padding: 8px 16px 16px; box-shadow: var(--shadow);
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 12px 14px; border-radius: 10px; font-size: 1rem; }
}

/* --- Hero --- */
.hero {
  margin: 24px 0; padding: 32px; border-radius: 20px; color: #fff;
  background: linear-gradient(120deg, var(--orange) 0%, #E8730A 38%, var(--green-dark) 100%);
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; align-items: center;
  box-shadow: var(--shadow); position: relative; overflow: hidden;
}
.hero::after {
  content: ""; position: absolute; right: -60px; top: -60px; width: 240px; height: 240px;
  border: 28px solid rgba(255, 255, 255, .12); border-radius: 50%;
}
.eyebrow { margin: 0 0 8px; font-weight: 700; opacity: .95; display: flex; align-items: center; gap: 8px; }
/* Drapeau dessiné en CSS : l'émoji 🇨🇮 s'affiche « CI » sous Windows. */
.mini-flag {
  display: inline-block; width: 24px; height: 16px; border-radius: 3px; flex-shrink: 0;
  background: linear-gradient(90deg, var(--orange) 0 33.3%, #fff 33.3% 66.6%, var(--green) 66.6%);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .15);
}
.hero h1 { font-family: var(--display); font-size: clamp(2rem, 6vw, 3.4rem); letter-spacing: .01em; }
.hero-sub { font-size: 1.08rem; max-width: 52ch; margin: 12px 0 0; opacity: .95; }
.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; position: relative; z-index: 1; }
.hero-stats .state { grid-column: 1 / -1; color: #fff; background: rgba(0, 0, 0, .15); border: 0; }
.hero-stats .state-text, .hero-stats .state-title { color: #fff; }
.stat { background: rgba(255, 255, 255, .16); border-radius: 12px; padding: 14px; text-align: center; backdrop-filter: blur(4px); }
.stat strong { display: block; font-family: var(--display); font-size: 1.8rem; }
.stat span { font-size: .85rem; }
.hero-update { grid-column: 1 / -1; margin: 0; font-size: .85rem; opacity: .9; text-align: right; }
@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; padding: 24px 18px; }
  .hero-update { text-align: left; }
}

/* --- Sections, grilles, cartes --- */
.section { margin: 28px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.section-head h2 { font-size: 1.3rem; padding-left: 12px; border-left: 5px solid var(--orange); }
.section-alerts .section-head h2 { border-left-color: var(--green); }
.section-link { font-weight: 600; font-size: .9rem; white-space: nowrap; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; }
.grid-2.tight { gap: 16px; }
@media (max-width: 860px) { .grid-2 { grid-template-columns: 1fr; } }

.page-head { margin: 28px 0 16px; }
.page-head h1 { font-family: var(--display); font-size: clamp(1.6rem, 4vw, 2.2rem); }
.page-head p { margin: 6px 0 0; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.card-title { font-size: 1rem; margin-bottom: 8px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.cards-players { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }

.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chip { display: inline-block; font-size: .75rem; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--bg); color: var(--ink-2); border: 1px solid var(--line); }
.chip-green { background: var(--green-soft); color: var(--green-dark); border-color: transparent; }
.chip-orange { background: var(--orange-soft); color: var(--orange-dark); border-color: transparent; }
@media (prefers-color-scheme: dark) {
  .chip-green { color: #3DD598; }
  .chip-orange { color: #FFB25C; }
}

/* --- États --- */
.state { border: 1px dashed var(--line); border-radius: var(--radius); padding: 20px; text-align: center; background: var(--surface); }
.state-title { font-weight: 700; margin: 0; }
.state-text { margin: 6px 0 0; color: var(--muted); font-size: .92rem; }
.state-error { border-style: solid; border-color: var(--danger); background: var(--danger-soft); }
.state-loading { display: flex; align-items: center; justify-content: center; gap: 10px; color: var(--muted); }
.spinner { width: 18px; height: 18px; border: 3px solid var(--line); border-top-color: var(--orange); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation: none; } }

.disclaimer { font-size: .8rem; color: var(--muted); margin: 10px 0 0; }

/* --- Buts --- */
.goal-card { border-top: 4px solid var(--orange); }
.goal-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.goal-minute { font-family: var(--display); color: var(--orange-dark); }
.goal-player { font-size: 1.1rem; }
.goal-match { margin: 4px 0 0; font-weight: 600; }
.goal-card p { margin: 2px 0; }

/* --- Classements --- */
.rank-list, .top-list, .alert-list, .news-list { list-style: none; margin: 0; padding: 0; }
.rank-row {
  display: grid; grid-template-columns: 32px 1fr auto; align-items: center; gap: 10px;
  padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 8px;
}
.rank { font-family: var(--display); color: var(--muted); text-align: center; }
.rank-main { display: flex; flex-direction: column; min-width: 0; }
.player-link { font-weight: 700; text-decoration: none; color: var(--ink); }
.player-link:hover { color: var(--orange-dark); text-decoration: underline; }

.top-list li { display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.top-list li:last-child { border-bottom: 0; }
.top-list strong { font-family: var(--display); color: var(--green-dark); }
@media (prefers-color-scheme: dark) { .top-list strong { color: #3DD598; } }

.form-badge { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; padding: 5px 10px; border-radius: 999px; white-space: nowrap; font-size: .9rem; }
.form-badge .stars { letter-spacing: 1px; }
.form-5 { background: var(--green); color: #fff; }
.form-4 { background: var(--green-soft); color: var(--green-dark); }
.form-3 { background: var(--orange-soft); color: var(--orange-dark); }
.form-low, .form-none { background: var(--bg); color: var(--muted); border: 1px solid var(--line); }
.trend-hausse { color: inherit; }
@media (max-width: 520px) {
  .rank-row { grid-template-columns: 26px 1fr; }
  .rank-row .form-badge { grid-column: 2; justify-self: start; }
}

/* --- Alertes --- */
.alert { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: start; padding: 12px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); border-left-width: 5px; margin-bottom: 8px; }
.alert p { margin: 0; }
.alert-level { font-size: .72rem; font-weight: 800; text-transform: uppercase; padding: 3px 8px; border-radius: 6px; }
.alert-forte { border-left-color: var(--danger); }
.alert-forte .alert-level { background: var(--danger-soft); color: var(--danger); }
.alert-attention { border-left-color: var(--orange); }
.alert-attention .alert-level { background: var(--orange-soft); color: var(--orange-dark); }
.alert-info { border-left-color: var(--info); }
.alert-info .alert-level { background: var(--info-soft); color: var(--info); }
.alert-message { font-weight: 600; }

/* --- Radar --- */
.radar-card { display: grid; grid-template-columns: 64px 1fr; gap: 14px; align-items: start; }
.radar-card h3 { font-size: 1.05rem; }
.radar-card p { margin: 2px 0; }
.radar-score {
  width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--orange) calc(var(--score) * 1%), var(--line) 0);
}
.radar-score span { width: 50px; height: 50px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font-family: var(--display); }

/* --- Actualités --- */
.news-list li { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
@media (max-width: 520px) { .news-list li { grid-template-columns: auto 1fr; } .news-list time { grid-column: 2; } }

/* --- Joueurs --- */
.player-card { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: center; text-decoration: none; color: var(--ink); transition: transform .15s, border-color .15s; }
.player-card:hover { transform: translateY(-2px); border-color: var(--orange); }
.player-card h3 { font-size: 1rem; }
.player-card p { margin: 2px 0; }
.avatar { border-radius: 50%; object-fit: cover; background: var(--bg); flex-shrink: 0; }
.avatar-md { width: 56px; height: 56px; }
.avatar-xl { width: 112px; height: 112px; border: 4px solid var(--surface); box-shadow: 0 0 0 3px var(--orange); }
.avatar-fallback { display: grid; place-items: center; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--orange), var(--green)); }
.avatar-xl.avatar-fallback { font-size: 2rem; }

.filters { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; margin-bottom: 16px; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.filters label { display: flex; flex-direction: column; gap: 4px; font-size: .85rem; font-weight: 600; flex: 1 1 160px; }
.filters input, .filters select { font: inherit; padding: 9px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--ink); min-height: 44px; }
.btn { font: inherit; font-weight: 700; padding: 10px 18px; min-height: 44px; border-radius: 10px; border: 0; background: var(--orange); color: #fff; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; }
.btn:hover { background: var(--orange-dark); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { background: var(--surface); }
.pager { display: flex; justify-content: space-between; align-items: center; margin: 18px 0; }

.tabs { display: flex; gap: 6px; overflow-x: auto; margin-bottom: 16px; padding-bottom: 4px; }
.tab { white-space: nowrap; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: .9rem; background: var(--surface); }
.tab.active { background: var(--green); color: #fff; border-color: var(--green); }

/* --- Fiche joueur --- */
.back { display: inline-block; margin: 20px 0 8px; font-weight: 600; text-decoration: none; }
.profile { display: grid; grid-template-columns: auto 1fr auto; gap: 20px; align-items: center; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); }
.profile h1 { font-family: var(--display); font-size: clamp(1.5rem, 4vw, 2.1rem); }
.profile p { margin: 4px 0; }
.profile-form { text-align: right; }
@media (max-width: 760px) {
  .profile { grid-template-columns: 1fr; text-align: center; justify-items: center; }
  .profile .chips { justify-content: center; }
  .profile-form { text-align: center; }
}
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px; text-align: center; }
.kpi strong { display: block; font-family: var(--display); font-size: 1.5rem; color: var(--orange-dark); }
@media (prefers-color-scheme: dark) { .kpi strong { color: #FFB25C; } }
.kpi span { font-size: .8rem; color: var(--muted); }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); background: var(--bg); }
tbody tr:last-child td { border-bottom: 0; }
.row-national td { background: var(--orange-soft); }

/* --- Pied de page --- */
.site-footer { margin-top: 48px; padding: 24px 0 32px; border-top: 4px solid var(--green); background: var(--surface); }
.site-footer p { margin: 4px 0; }

/* --- Menu « Plus » --- */
.nav-more { position: relative; }
.nav-more summary {
  list-style: none; cursor: pointer; font-weight: 600; font-size: .92rem; color: var(--ink-2);
  padding: 8px 12px; border-radius: 999px;
}
.nav-more summary::-webkit-details-marker { display: none; }
.nav-more summary::after { content: " ▾"; font-size: .8em; }
.nav-more summary:hover { background: var(--bg); }
.nav-more.active > summary { background: var(--orange); color: #fff; }
.nav-more-list {
  position: absolute; right: 0; top: calc(100% + 6px); min-width: 220px; display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 6px; box-shadow: var(--shadow); z-index: 60;
}
.nav-more-list a { border-radius: 8px; }
@media (max-width: 900px) {
  .nav-more summary { padding: 12px 14px; font-size: 1rem; border-radius: 10px; }
  .nav-more-list { position: static; box-shadow: none; border: 0; padding: 0 0 0 12px; min-width: 0; }
}
@media (max-width: 1100px) and (min-width: 901px) { .site-nav a, .nav-more summary { padding: 8px 9px; font-size: .86rem; } }

/* --- Onze probable : terrain --- */
.pitch {
  display: flex; flex-direction: column; gap: 18px; padding: 24px 12px; margin: 12px 0 16px; border-radius: 18px;
  background: repeating-linear-gradient(180deg, #0B8F55 0 48px, #0A8550 48px 96px);
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .55), var(--shadow); position: relative;
}
.pitch::before { content: ""; position: absolute; left: 12px; right: 12px; top: 50%; border-top: 2px solid rgba(255, 255, 255, .5); }
.pitch-line { display: flex; justify-content: space-evenly; gap: 8px; position: relative; z-index: 1; flex-wrap: wrap; }
.pitch-player { display: flex; flex-direction: column; align-items: center; gap: 4px; text-decoration: none; color: #fff; width: 96px; text-align: center; }
.pitch-score {
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; font-family: var(--display);
  background: var(--orange); border: 3px solid #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .3); color: #fff;
}
.pitch-name { font-weight: 700; font-size: .82rem; text-shadow: 0 1px 2px rgba(0, 0, 0, .6); line-height: 1.2; }
@media (max-width: 520px) { .pitch-player { width: 72px; } .pitch-score { width: 40px; height: 40px; } }

/* --- Divers pages --- */
.plain { list-style: none; padding: 0; margin: 0; }
.plain li { padding: 6px 0; border-bottom: 1px solid var(--line); }
.plain li:last-child { border-bottom: 0; }
.world { display: grid; gap: 10px; margin-top: 12px; }
.world-country summary { cursor: pointer; display: flex; gap: 8px; align-items: center; font-size: 1.05rem; }
.world-league h3 { font-size: .95rem; margin: 12px 0 4px; color: var(--green-dark); }
@media (prefers-color-scheme: dark) { .world-league h3 { color: #3DD598; } }
.world-league ul { margin: 0; padding-left: 18px; }
.world-league li { margin: 2px 0; }
.record h3 { font-size: 1rem; margin-top: 6px; }
.record .chip { margin: 0; }
.record-value { font-family: var(--display); font-size: 2rem; color: var(--orange-dark); margin: 6px 0; }
.record-value span { font-family: var(--font); font-size: .9rem; color: var(--muted); }
.record p { margin: 4px 0; }
.news-page li { align-items: start; }
.news-title { font-weight: 700; margin: 0; }
.news-page p { margin: 2px 0; }
.notice { text-align: left; margin-bottom: 16px; }
.cards-wide { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
@media (max-width: 520px) { .cards-wide { grid-template-columns: 1fr; } }
.draft-head { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.draft h3 { font-size: 1rem; }
.draft-body { white-space: pre-wrap; word-break: break-word; font-family: var(--font); font-size: .9rem; background: var(--bg); padding: 12px; border-radius: 10px; max-height: 320px; overflow: auto; }
.trophy-list li { display: flex; justify-content: space-between; gap: 8px; }

/* --- Vidéos à produire --- */
.video-card .clip { border-top: 1px solid var(--line); padding: 8px 0; }
.video-card .clip summary { cursor: pointer; font-weight: 700; }
.copy-block { margin: 8px 0; }
.copy-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 4px; }
.btn-small { min-height: 32px; padding: 4px 10px; font-size: .8rem; }
.montage { padding-left: 20px; margin: 4px 0 8px; }

/* --- Débat Ivoirien --- */
.debate-question { font-weight: 700; font-size: 1.05rem; margin: 6px 0 10px; }
.debate-side { border-radius: 12px; padding: 10px 12px; background: var(--bg); }
.debate-side ul { margin: 6px 0 0; padding-left: 18px; }
.debate-pro { border-left: 4px solid var(--green); }
.debate-con { border-left: 4px solid var(--orange); }
.poll { margin: 8px 0; padding-left: 22px; }
.poll li { margin: 6px 0; }

/* --- Football local (mobile d'abord) --- */
.note { margin: 0 0 14px; padding: 10px 12px; border-radius: 10px; background: var(--info-soft); font-size: .88rem; }
.note-warn { background: var(--orange-soft); }
.standings-wrap { margin-bottom: 14px; -webkit-overflow-scrolling: touch; }
.standings { font-size: .88rem; }
.standings th, .standings td { padding: 8px 8px; }
.standings td { font-variant-numeric: tabular-nums; }
.standings .col-rank { position: sticky; left: 0; z-index: 1; width: 2.6em; text-align: center; background: var(--surface); }
.standings .col-club { position: sticky; left: 2.6em; z-index: 1; min-width: 9.5em; max-width: 12em; background: var(--surface);
  white-space: normal; box-shadow: 1px 0 0 var(--line); }
.standings thead .col-rank, .standings thead .col-club { background: var(--bg); }
.standings .col-pts strong { font-size: 1rem; }
.standings tr.is-tie .col-rank { color: var(--orange-dark); font-weight: 700; }
.club-link { color: var(--ink); text-decoration: none; font-weight: 600; }
.club-link:hover, .club-link:focus-visible { text-decoration: underline; }
.group-title { margin: 18px 0 8px; font-size: 1.05rem; }
.section-title { margin: 14px 0 8px; font-size: 1.1rem; }

.form-pills { display: inline-flex; gap: 3px; }
.pill { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; font-size: .68rem;
  font-weight: 800; color: #fff; }
.pill-v { background: var(--green); }
.pill-n { background: #8A929C; }
.pill-d { background: var(--danger); }
.pill-x { background: var(--line); color: var(--ink); }

.badge { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; font-size: .68rem; font-weight: 700;
  vertical-align: middle; white-space: nowrap; border: 1px solid transparent; }
.badge-tie { background: var(--orange-soft); color: var(--orange-dark); }
.badge-verify { background: var(--danger-soft); color: var(--danger); border-color: var(--danger); }
.badge-rejected { background: var(--bg); color: var(--muted); border-color: var(--line); text-decoration: line-through; }
.badge-ok { background: var(--green-soft); color: var(--green-dark); }
.badge-adj { background: var(--info-soft); color: var(--info); }
.badge-next { background: var(--info-soft); color: var(--info); }
@media (prefers-color-scheme: dark) {
  .badge-tie { color: #FFB25C; }
  .badge-verify { color: #FF8A80; border-color: #FF8A80; }
  .badge-ok { color: #3DD598; }
  .badge-adj, .badge-next { color: #8AB4F8; }
  .standings tr.is-tie .col-rank { color: #FFB25C; }
}

.card-warn { border-color: var(--danger); margin: 14px 0; }
.round-pills { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 6px; }
.round-pill { position: relative; min-width: 44px; text-align: center; padding: 8px 10px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); text-decoration: none; font-weight: 700; }
.round-pill.active { background: var(--orange); border-color: var(--orange); color: #fff; }
.round-pill .dot { position: absolute; top: 4px; right: 4px; width: 7px; height: 7px; border-radius: 50%; background: var(--danger); }

.match-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.match-row { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.match-row.is-verify { border-color: var(--danger); }
.match-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: .78rem; color: var(--muted); align-items: center; }
.match-meta .badge { margin-left: 0; }
.match-line { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; margin: 6px 0; }
.team-home { text-align: right; }
.score { font-family: var(--display); font-size: 1.15rem; white-space: nowrap; }
.score-empty { color: var(--muted); font-family: var(--font); font-size: .9rem; }
.match-foot { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; font-size: .78rem; }
.match-foot .badge { margin-left: 0; }
.provenance { color: var(--muted); }
.club-form { margin: 10px 0 0; }
@media (max-width: 520px) {
  .standings { font-size: .84rem; }
  .standings .col-club { min-width: 8.5em; }
  .match-line { gap: 6px; font-size: .92rem; }
}

/* --- Centre Social (aperçus Facebook / Instagram) --- */
.social-group { margin: 0 0 28px; }
.social-group-title { font-size: 1.05rem; margin: 0 0 4px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.social-pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.social-post { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.social-visual { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  width: 100%; max-width: 320px; margin: 0 auto; aspect-ratio: 4 / 5; border: 2px dashed var(--line);
  border-radius: var(--radius); background: var(--bg); color: var(--muted); text-align: center; padding: 12px; }
.social-visual span { font-weight: 700; color: var(--ink-2); }
.social-text { width: 100%; box-sizing: border-box; font: inherit; font-size: .9rem; line-height: 1.45;
  padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink);
  resize: vertical; }
.social-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; }
.social-tags span { font-size: .8rem; color: var(--info); }
.social-actions { display: flex; flex-direction: column; gap: 8px; }
.social-op summary { cursor: pointer; font-weight: 600; font-size: .9rem; }
.social-op .draft-body { white-space: pre-wrap; word-break: break-all; font-size: .78rem; }

/* Fiche du but : section « Séquence du but » (vidéo réelle, lecteur YouTube intégré ou lien externe). */
.goal-page { display: grid; gap: 16px; margin-top: 12px; }
.goal-detail h1.goal-player { font-size: 1.4rem; }
.goal-video-title { font-size: 1.1rem; margin-bottom: 10px; padding-left: 12px; border-left: 5px solid var(--orange); }
.goal-video-player { position: relative; display: grid; place-items: center; aspect-ratio: 16 / 9; max-width: 720px;
  border-radius: var(--radius); overflow: hidden; background: var(--bg); border: 1px solid var(--line); }
.goal-video-thumb { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.goal-video-play { position: relative; }
.goal-video-iframe { width: 100%; height: 100%; border: 0; }
.goal-video-source { margin: 10px 0 0; }
.goal-video-others { margin-top: 8px; }
.goal-key code { overflow-wrap: anywhere; }
.player-goals .goal-key { margin: 0; }

/* Administration locale des vidéos des buts. */
.admin-form { display: grid; gap: 12px; max-width: 720px; }
.admin-field { display: grid; gap: 4px; font-weight: 600; }
.admin-field input, .admin-field select, .admin-status input, .admin-status select { font: inherit; font-weight: 400;
  padding: 9px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--ink); min-height: 44px; }
.admin-videos { list-style: none; padding: 0; display: grid; gap: 10px; max-width: 720px; }
.admin-video p { margin: 2px 0; overflow-wrap: anywhere; }
.admin-status { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }

/* Accueil : portrait décoratif d'un joueur de chaque côté de la page (grands écrans seulement).
   Purement décoratif (pseudo-éléments, aucun texte) ; fondu vers le contenu, qui reste au premier plan. */
@media (min-width: 1400px) {
  body.page-accueil::before, body.page-accueil::after {
    content: ""; position: fixed; top: 0; bottom: 0; z-index: 0; pointer-events: none;
    width: calc((100vw - 1180px) / 2 + 80px);
    background: var(--orange) url("../assets/photo-joueur.jpg") 45% 15% / cover no-repeat;
  }
  body.page-accueil::before {                       /* visage dans la partie nette, fondu vers le contenu */
    left: 0;
    -webkit-mask-image: linear-gradient(to right, #000 72%, transparent);
    mask-image: linear-gradient(to right, #000 72%, transparent);
  }
  body.page-accueil::after {
    right: 0;
    background-position: 30% 15%;
    -webkit-mask-image: linear-gradient(to left, #000 72%, transparent);
    mask-image: linear-gradient(to left, #000 72%, transparent);
  }
  body.page-accueil main, body.page-accueil .site-footer { position: relative; z-index: 1; }
}
@media print { body.page-accueil::before, body.page-accueil::after { display: none; } }
