{"id":231,"date":"2026-09-07T11:38:18","date_gmt":"2026-09-07T11:38:18","guid":{"rendered":"https:\/\/maroczain.com\/aviation.maroczain.com\/?page_id=231"},"modified":"2026-09-07T11:38:18","modified_gmt":"2026-09-07T11:38:18","slug":"academy-manager-pro-max","status":"publish","type":"page","link":"https:\/\/maroczain.com\/aviation.maroczain.com\/academy-manager-pro-max\/","title":{"rendered":"Academy Manager PRO MAX"},"content":{"rendered":"\n<div id=\"mzaAcademyProMax\" class=\"mza-academy\">\n\n  <header class=\"ma-header\">\n    <div>\n      <span class=\"ma-kicker\">MZA FOOTBALL MANAGEMENT 360\u00b0<\/span>\n      <h1>\ud83c\udf93 ACADEMY MANAGER PRO MAX<\/h1>\n      <p>U13 \u2022 U15 \u2022 U17 \u2022 U19 \u2022 R\u00e9serve \u2022 D\u00e9tection \u2022 Progression \u2022 Promotion<\/p>\n    <\/div>\n\n    <div class=\"ma-header-actions\">\n      <button data-action=\"sync\">\ud83d\udd04 Synchroniser Club<\/button>\n      <button data-action=\"save\">\ud83d\udcbe Sauvegarder<\/button>\n      <button data-action=\"simulate\">\u25b6 Simuler un mois<\/button>\n    <\/div>\n  <\/header>\n\n  <section class=\"ma-kpis\">\n    <div>\n      <span>Niveau Acad\u00e9mie<\/span>\n      <strong id=\"maAcademyLevel\">&#8212;<\/strong>\n    <\/div>\n\n    <div>\n      <span>Jeunes<\/span>\n      <strong id=\"maYouthCount\">&#8212;<\/strong>\n    <\/div>\n\n    <div>\n      <span>Potentiel moyen<\/span>\n      <strong id=\"maAvgPotential\">&#8212;<\/strong>\n    <\/div>\n\n    <div>\n      <span>Budget Acad\u00e9mie<\/span>\n      <strong id=\"maBudget\">&#8212;<\/strong>\n    <\/div>\n\n    <div>\n      <span>Promotions<\/span>\n      <strong id=\"maPromotions\">&#8212;<\/strong>\n    <\/div>\n\n    <div>\n      <span>Talents 85+<\/span>\n      <strong id=\"maElite\">&#8212;<\/strong>\n    <\/div>\n  <\/section>\n\n  <div class=\"ma-layout\">\n\n    <aside class=\"ma-menu\">\n      <button class=\"active\" data-tab=\"cockpit\">\ud83d\udcca Cockpit Acad\u00e9mie<\/button>\n      <button data-tab=\"teams\">\ud83d\udc65 \u00c9quipes jeunes<\/button>\n      <button data-tab=\"recruitment\">\ud83d\udd0e D\u00e9tection<\/button>\n      <button data-tab=\"development\">\ud83d\udcc8 D\u00e9veloppement<\/button>\n      <button data-tab=\"staff\">\ud83e\udde0 Staff<\/button>\n      <button data-tab=\"facilities\">\ud83c\udfdf Infrastructures<\/button>\n      <button data-tab=\"finance\">\ud83d\udcb0 Budget<\/button>\n      <button data-tab=\"pathway\">\ud83d\ude80 Passerelle Pro<\/button>\n      <button data-tab=\"journal\">\ud83d\udcf0 Journal<\/button>\n    <\/aside>\n\n    <main class=\"ma-main\">\n\n      <!-- COCKPIT -->\n      <section id=\"cockpit\" class=\"ma-tab active\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>YOUTH DEVELOPMENT CONTROL CENTER<\/span>\n            <h2>Cockpit Directeur d&#8217;Acad\u00e9mie<\/h2>\n          <\/div>\n\n          <button class=\"ma-primary\" data-action=\"simulate\">\n            \u25b6 Simuler un mois\n          <\/button>\n        <\/div>\n\n        <div class=\"ma-dashboard\">\n\n          <article class=\"ma-panel\">\n            <h3>\ud83c\udfaf Objectifs<\/h3>\n\n            <div class=\"ma-line\">\n              <span>Former 2 joueurs \u00e9quipe premi\u00e8re<\/span>\n              <strong id=\"maObjectivePromotions\">0 \/ 2<\/strong>\n            <\/div>\n\n            <div class=\"ma-line\">\n              <span>Potentiel moyen cible<\/span>\n              <strong>\u2265 78<\/strong>\n            <\/div>\n\n            <div class=\"ma-line\">\n              <span>Niveau Acad\u00e9mie cible<\/span>\n              <strong>\u2265 75%<\/strong>\n            <\/div>\n\n            <div class=\"ma-line\">\n              <span>R\u00e9ussite scolaire<\/span>\n              <strong id=\"maEducationKpi\">&#8212;<\/strong>\n            <\/div>\n          <\/article>\n\n          <article class=\"ma-panel\">\n            <h3>\u2b50 Top talents<\/h3>\n            <div id=\"maTopTalents\"><\/div>\n          <\/article>\n\n          <article class=\"ma-panel\">\n            <h3>\ud83d\udcc8 Performance Acad\u00e9mie<\/h3>\n\n            <div class=\"ma-progress-row\">\n              <span>Formation<\/span>\n              <div class=\"ma-progress\"><b id=\"maTrainingBar\"><\/b><\/div>\n              <strong id=\"maTrainingValue\">&#8212;<\/strong>\n            <\/div>\n\n            <div class=\"ma-progress-row\">\n              <span>Scouting<\/span>\n              <div class=\"ma-progress\"><b id=\"maScoutingBar\"><\/b><\/div>\n              <strong id=\"maScoutingValue\">&#8212;<\/strong>\n            <\/div>\n\n            <div class=\"ma-progress-row\">\n              <span>Installations<\/span>\n              <div class=\"ma-progress\"><b id=\"maFacilityBar\"><\/b><\/div>\n              <strong id=\"maFacilityValue\">&#8212;<\/strong>\n            <\/div>\n\n            <div class=\"ma-progress-row\">\n              <span>Staff<\/span>\n              <div class=\"ma-progress\"><b id=\"maStaffBar\"><\/b><\/div>\n              <strong id=\"maStaffValue\">&#8212;<\/strong>\n            <\/div>\n          <\/article>\n\n        <\/div>\n\n        <article class=\"ma-panel ma-next\">\n          <h3>D\u00e9cision recommand\u00e9e<\/h3>\n          <div id=\"maRecommendation\"><\/div>\n        <\/article>\n\n      <\/section>\n\n      <!-- TEAMS -->\n      <section id=\"teams\" class=\"ma-tab\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>ACADEMY SQUADS<\/span>\n            <h2>U13 \u2192 U15 \u2192 U17 \u2192 U19 \u2192 R\u00e9serve<\/h2>\n          <\/div>\n\n          <select id=\"maTeamFilter\">\n            <option value=\"ALL\">Toutes les cat\u00e9gories<\/option>\n            <option value=\"U13\">U13<\/option>\n            <option value=\"U15\">U15<\/option>\n            <option value=\"U17\">U17<\/option>\n            <option value=\"U19\">U19<\/option>\n            <option value=\"RESERVE\">R\u00e9serve<\/option>\n          <\/select>\n        <\/div>\n\n        <div class=\"ma-table-wrap\">\n          <table class=\"ma-table\">\n            <thead>\n              <tr>\n                <th>Joueur<\/th>\n                <th>Cat\u00e9gorie<\/th>\n                <th>\u00c2ge<\/th>\n                <th>Poste<\/th>\n                <th>Note<\/th>\n                <th>Potentiel<\/th>\n                <th>Forme<\/th>\n                <th>Moral<\/th>\n                <th>\u00c9ducation<\/th>\n                <th>Statut<\/th>\n                <th>Action<\/th>\n              <\/tr>\n            <\/thead>\n            <tbody id=\"maYouthTable\"><\/tbody>\n          <\/table>\n        <\/div>\n\n      <\/section>\n\n      <!-- RECRUITMENT -->\n      <section id=\"recruitment\" class=\"ma-tab\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>YOUTH SCOUTING<\/span>\n            <h2>D\u00e9tection nationale &#038; internationale<\/h2>\n          <\/div>\n        <\/div>\n\n        <div class=\"ma-card-grid\">\n\n          <article class=\"ma-card\">\n            <span class=\"ma-kicker-dark\">LOCAL SCOUTING<\/span>\n            <h3>D\u00e9tection r\u00e9gionale<\/h3>\n            <p>Tournois scolaires, clubs amateurs et acad\u00e9mies locales.<\/p>\n            <strong>Co\u00fbt : 0,20 M MAD<\/strong>\n            <button data-scout=\"local\">Lancer la d\u00e9tection<\/button>\n          <\/article>\n\n          <article class=\"ma-card\">\n            <span class=\"ma-kicker-dark\">NATIONAL SCOUTING<\/span>\n            <h3>D\u00e9tection nationale<\/h3>\n            <p>Couverture \u00e9largie du territoire avec plusieurs scouts.<\/p>\n            <strong>Co\u00fbt : 0,50 M MAD<\/strong>\n            <button data-scout=\"national\">Lancer la d\u00e9tection<\/button>\n          <\/article>\n\n          <article class=\"ma-card\">\n            <span class=\"ma-kicker-dark\">INTERNATIONAL SCOUTING<\/span>\n            <h3>D\u00e9tection internationale<\/h3>\n            <p>Recherche de jeunes talents \u00e0 potentiel sup\u00e9rieur.<\/p>\n            <strong>Co\u00fbt : 1,00 M MAD<\/strong>\n            <button data-scout=\"international\">Lancer la d\u00e9tection<\/button>\n          <\/article>\n\n        <\/div>\n\n        <div class=\"ma-panel ma-results\">\n          <h3>Derniers joueurs d\u00e9tect\u00e9s<\/h3>\n          <div id=\"maScoutingResults\"><\/div>\n        <\/div>\n\n      <\/section>\n\n      <!-- DEVELOPMENT -->\n      <section id=\"development\" class=\"ma-tab\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>PLAYER DEVELOPMENT<\/span>\n            <h2>Plans individuels de progression<\/h2>\n          <\/div>\n        <\/div>\n\n        <div id=\"maDevelopmentGrid\" class=\"ma-card-grid\"><\/div>\n\n      <\/section>\n\n      <!-- STAFF -->\n      <section id=\"staff\" class=\"ma-tab\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>ACADEMY STAFF<\/span>\n            <h2>Encadrement technique &#038; \u00e9ducatif<\/h2>\n          <\/div>\n        <\/div>\n\n        <div id=\"maStaffGrid\" class=\"ma-card-grid\"><\/div>\n\n      <\/section>\n\n      <!-- FACILITIES -->\n      <section id=\"facilities\" class=\"ma-tab\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>TRAINING FACILITIES<\/span>\n            <h2>Infrastructures de formation<\/h2>\n          <\/div>\n        <\/div>\n\n        <div id=\"maFacilitiesGrid\" class=\"ma-card-grid\"><\/div>\n\n      <\/section>\n\n      <!-- FINANCE -->\n      <section id=\"finance\" class=\"ma-tab\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>ACADEMY FINANCE<\/span>\n            <h2>Budget &#038; investissement formation<\/h2>\n          <\/div>\n        <\/div>\n\n        <div class=\"ma-dashboard\">\n\n          <article class=\"ma-panel\">\n            <h3>Budget<\/h3>\n            <div id=\"maFinanceSummary\"><\/div>\n          <\/article>\n\n          <article class=\"ma-panel\">\n            <h3>D\u00e9cisions<\/h3>\n\n            <button class=\"ma-wide-btn\" data-invest=\"training\">\n              \u26bd Programme technique intensif \u2014 0,50 M\n            <\/button>\n\n            <button class=\"ma-wide-btn\" data-invest=\"education\">\n              \ud83d\udcda Programme \u00e9ducatif \u2014 0,30 M\n            <\/button>\n\n            <button class=\"ma-wide-btn\" data-invest=\"medical\">\n              \ud83e\ude7a Pr\u00e9vention &#038; suivi m\u00e9dical \u2014 0,40 M\n            <\/button>\n\n            <button class=\"ma-wide-btn\" data-invest=\"analytics\">\n              \ud83d\udcca Data &#038; vid\u00e9o Acad\u00e9mie \u2014 0,60 M\n            <\/button>\n          <\/article>\n\n          <article class=\"ma-panel\">\n            <h3>Retour sur investissement<\/h3>\n            <div id=\"maROI\"><\/div>\n          <\/article>\n\n        <\/div>\n\n      <\/section>\n\n      <!-- PATHWAY -->\n      <section id=\"pathway\" class=\"ma-tab\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>FIRST TEAM PATHWAY<\/span>\n            <h2>Passerelle vers l&#8217;\u00e9quipe premi\u00e8re<\/h2>\n          <\/div>\n        <\/div>\n\n        <div id=\"maPathwayGrid\" class=\"ma-card-grid\"><\/div>\n\n      <\/section>\n\n      <!-- JOURNAL -->\n      <section id=\"journal\" class=\"ma-tab\">\n\n        <div class=\"ma-title\">\n          <div>\n            <span>ACADEMY NEWSROOM<\/span>\n            <h2>Journal de l&#8217;Acad\u00e9mie<\/h2>\n          <\/div>\n        <\/div>\n\n        <article class=\"ma-panel\">\n          <div id=\"maJournal\"><\/div>\n        <\/article>\n\n      <\/section>\n\n    <\/main>\n\n  <\/div>\n\n<\/div>\n\n<style>\n#mzaAcademyProMax,\n#mzaAcademyProMax *{\n  box-sizing:border-box;\n}\n\n#mzaAcademyProMax{\n  width:100%;\n  min-height:100vh;\n  background:#f1f5f3;\n  color:#132219;\n  font-family:Arial,Helvetica,sans-serif;\n}\n\n.ma-header{\n  display:flex;\n  justify-content:space-between;\n  align-items:center;\n  gap:24px;\n  padding:30px 3%;\n  color:#fff;\n  background:\n    radial-gradient(circle at 82% 20%,rgba(0,190,115,.25),transparent 28%),\n    linear-gradient(135deg,#03140c,#072d1b);\n}\n\n.ma-header h1{\n  font-size:clamp(30px,4vw,52px);\n  margin:7px 0;\n}\n\n.ma-header p{\n  margin:0;\n  opacity:.75;\n}\n\n.ma-kicker,\n.ma-kicker-dark{\n  display:block;\n  font-size:11px;\n  letter-spacing:2px;\n  font-weight:900;\n}\n\n.ma-kicker{opacity:.7;}\n.ma-kicker-dark{color:#607369;}\n\n.ma-header-actions{\n  display:flex;\n  gap:8px;\n  flex-wrap:wrap;\n}\n\n.ma-header-actions button{\n  padding:12px 15px;\n  border:1px solid rgba(255,255,255,.18);\n  border-radius:10px;\n  background:rgba(255,255,255,.08);\n  color:#fff;\n  font-weight:900;\n  cursor:pointer;\n}\n\n.ma-kpis{\n  display:grid;\n  grid-template-columns:repeat(6,minmax(0,1fr));\n  gap:1px;\n  background:#dbe3df;\n}\n\n.ma-kpis>div{\n  padding:18px;\n  background:#fff;\n}\n\n.ma-kpis span{\n  display:block;\n  font-size:11px;\n  color:#718078;\n  margin-bottom:6px;\n}\n\n.ma-kpis strong{\n  font-size:20px;\n}\n\n.ma-layout{\n  display:grid;\n  grid-template-columns:230px minmax(0,1fr);\n  min-height:800px;\n}\n\n.ma-menu{\n  background:#061b11;\n  padding:18px 12px;\n}\n\n.ma-menu button{\n  width:100%;\n  padding:14px;\n  margin-bottom:6px;\n  border:0;\n  border-radius:10px;\n  background:transparent;\n  color:rgba(255,255,255,.68);\n  text-align:left;\n  font-weight:800;\n  cursor:pointer;\n}\n\n.ma-menu button:hover,\n.ma-menu button.active{\n  background:rgba(255,255,255,.1);\n  color:#fff;\n}\n\n.ma-main{\n  min-width:0;\n  padding:28px;\n}\n\n.ma-tab{display:none;}\n.ma-tab.active{display:block;}\n\n.ma-title{\n  display:flex;\n  justify-content:space-between;\n  align-items:center;\n  gap:18px;\n  margin-bottom:22px;\n}\n\n.ma-title span{\n  font-size:11px;\n  letter-spacing:2px;\n  font-weight:900;\n  color:#597064;\n}\n\n.ma-title h2{\n  font-size:32px;\n  margin:6px 0 0;\n}\n\n.ma-title select{\n  min-width:210px;\n  height:46px;\n  padding:0 12px;\n  border:1px solid #d6dfda;\n  border-radius:10px;\n  background:#fff;\n}\n\n.ma-primary,\n.ma-wide-btn,\n.ma-card button{\n  border:0;\n  border-radius:10px;\n  cursor:pointer;\n  font-weight:900;\n}\n\n.ma-primary{\n  padding:12px 18px;\n  background:#0b6c3e;\n  color:#fff;\n}\n\n.ma-wide-btn{\n  display:block;\n  width:100%;\n  margin:8px 0;\n  padding:12px;\n  text-align:left;\n  background:#e7f0eb;\n  color:#103a24;\n}\n\n.ma-dashboard{\n  display:grid;\n  grid-template-columns:repeat(3,minmax(0,1fr));\n  gap:16px;\n}\n\n.ma-panel,\n.ma-card{\n  padding:20px;\n  border:1px solid #dce4df;\n  border-radius:17px;\n  background:#fff;\n  box-shadow:0 5px 18px rgba(0,0,0,.025);\n}\n\n.ma-panel h3,\n.ma-card h3{\n  margin-top:0;\n}\n\n.ma-line{\n  display:flex;\n  justify-content:space-between;\n  gap:15px;\n  padding:10px 0;\n  border-bottom:1px solid #edf1ef;\n}\n\n.ma-progress-row{\n  display:grid;\n  grid-template-columns:90px minmax(0,1fr) 40px;\n  gap:8px;\n  align-items:center;\n  margin:12px 0;\n  font-size:12px;\n}\n\n.ma-progress{\n  height:9px;\n  overflow:hidden;\n  border-radius:20px;\n  background:#e4ebe7;\n}\n\n.ma-progress b{\n  display:block;\n  height:100%;\n  background:#169154;\n}\n\n.ma-next{\n  margin-top:16px;\n}\n\n.ma-card-grid{\n  display:grid;\n  grid-template-columns:repeat(3,minmax(0,1fr));\n  gap:16px;\n}\n\n.ma-card p{\n  line-height:1.6;\n  color:#64746b;\n}\n\n.ma-card button{\n  width:100%;\n  padding:11px 13px;\n  margin-top:12px;\n  background:#e6efe9;\n  color:#103922;\n}\n\n.ma-table-wrap{\n  width:100%;\n  overflow:auto;\n  border-radius:16px;\n}\n\n.ma-table{\n  width:100%;\n  min-width:1050px;\n  border-collapse:collapse;\n  background:#fff;\n}\n\n.ma-table th{\n  padding:13px;\n  background:#061b11;\n  color:#fff;\n  text-align:left;\n}\n\n.ma-table td{\n  padding:12px 13px;\n  border-bottom:1px solid #e8edea;\n}\n\n.ma-table button{\n  padding:8px 11px;\n  border:0;\n  border-radius:8px;\n  background:#e5eee8;\n  font-weight:800;\n  cursor:pointer;\n}\n\n.ma-player-score{\n  display:inline-flex;\n  min-width:45px;\n  height:45px;\n  align-items:center;\n  justify-content:center;\n  border-radius:11px;\n  background:#071e13;\n  color:#fff;\n  font-weight:900;\n}\n\n.ma-status{\n  display:inline-block;\n  padding:5px 9px;\n  border-radius:20px;\n  background:#e9f1ed;\n  font-size:11px;\n  font-weight:900;\n}\n\n.ma-talent{\n  padding:10px 0;\n  border-bottom:1px solid #edf1ef;\n}\n\n.ma-talent strong{\n  display:block;\n  margin-bottom:4px;\n}\n\n.ma-results{\n  margin-top:18px;\n}\n\n.ma-result-grid{\n  display:grid;\n  grid-template-columns:repeat(3,minmax(0,1fr));\n  gap:12px;\n}\n\n.ma-result{\n  padding:15px;\n  border-radius:13px;\n  background:#f4f8f6;\n}\n\n.ma-dev-bar{\n  height:8px;\n  margin:7px 0 13px;\n  overflow:hidden;\n  border-radius:20px;\n  background:#e5ebe8;\n}\n\n.ma-dev-bar b{\n  display:block;\n  height:100%;\n  background:#168e52;\n}\n\n.ma-journal-entry{\n  padding:11px 0;\n  border-bottom:1px solid #edf1ef;\n  line-height:1.5;\n}\n\n.ma-positive{color:#087844;}\n.ma-warning{color:#a56700;}\n.ma-danger{color:#a52d2d;}\n\n@media(max-width:1100px){\n  .ma-kpis{\n    grid-template-columns:repeat(3,minmax(0,1fr));\n  }\n\n  .ma-dashboard,\n  .ma-card-grid{\n    grid-template-columns:1fr 1fr;\n  }\n}\n\n@media(max-width:800px){\n  .ma-header{\n    flex-direction:column;\n    align-items:flex-start;\n  }\n\n  .ma-layout{\n    grid-template-columns:1fr;\n  }\n\n  .ma-menu{\n    display:flex;\n    overflow:auto;\n    gap:6px;\n    position:sticky;\n    top:0;\n    z-index:50;\n  }\n\n  .ma-menu button{\n    min-width:160px;\n    margin:0;\n  }\n\n  .ma-main{\n    padding:18px;\n  }\n\n  .ma-title{\n    align-items:flex-start;\n    flex-direction:column;\n  }\n}\n\n@media(max-width:600px){\n  .ma-kpis{\n    grid-template-columns:1fr 1fr;\n  }\n\n  .ma-dashboard,\n  .ma-card-grid,\n  .ma-result-grid{\n    grid-template-columns:1fr;\n  }\n}\n<\/style>\n\n<script>\n(function(){\n\n\"use strict\";\n\nconst ROOT = document.getElementById(\"mzaAcademyProMax\");\nif(!ROOT) return;\n\nconst STORAGE_KEY = \"mzaClubManagerV2\";\n\nconst Academy = {\n\n  club:null,\n\n  data:null,\n\n  names:[\n    \"Adam\",\"Ayoub\",\"Anas\",\"Ilyas\",\"Hamza\",\"Yassine\",\n    \"Omar\",\"Mehdi\",\"Zakaria\",\"Amine\",\"Bilal\",\"Reda\",\n    \"Nassim\",\"Younes\",\"Rayan\",\"Soufiane\",\"Karim\",\"Nabil\"\n  ],\n\n  surnames:[\n    \"Bennani\",\"El Idrissi\",\"Naciri\",\"Amrani\",\"Bennis\",\n    \"Tazi\",\"Sabri\",\"Rahimi\",\"Alaoui\",\"Fathi\",\"Ghali\",\n    \"Saidi\",\"Mansouri\",\"El Khatib\",\"Rami\",\"Chraibi\"\n  ],\n\n  positions:[\n    \"GK\",\"DC\",\"DG\",\"DD\",\"MDC\",\"MC\",\"MOC\",\"AG\",\"AD\",\"BU\"\n  ],\n\n  init(){\n\n    this.setupTabs();\n    this.setupActions();\n    this.loadClub();\n    this.renderAll();\n\n  },\n\n  defaultClub(){\n\n    return {\n      state:{\n        club:\"MZA United\",\n        cash:32,\n        salary:14.8,\n        academy:55,\n        performance:74,\n        reputation:72,\n        board:76\n      },\n      players:[],\n      youth:[],\n      staff:[],\n      market:[],\n      sponsors:[],\n      table:[],\n      fixtures:[]\n    };\n\n  },\n\n  defaultAcademy(){\n\n    return {\n\n      month:1,\n\n      budget:4,\n\n      training:68,\n      scouting:64,\n      facilities:60,\n      education:78,\n      medical:65,\n      analytics:50,\n\n      promotions:0,\n\n      totalInvestment:0,\n\n      generatedValue:0,\n\n      staff:[\n        {\n          role:\"Directeur Acad\u00e9mie\",\n          name:\"Nabil El Mansouri\",\n          rating:82,\n          salary:.55\n        },\n        {\n          role:\"Coach U19\",\n          name:\"Adil Bennis\",\n          rating:79,\n          salary:.30\n        },\n        {\n          role:\"Coach U17\",\n          name:\"Samir Rahimi\",\n          rating:77,\n          salary:.25\n        },\n        {\n          role:\"Coach U15\",\n          name:\"Youssef Tazi\",\n          rating:75,\n          salary:.20\n        },\n        {\n          role:\"Pr\u00e9parateur physique\",\n          name:\"Karim Sabri\",\n          rating:80,\n          salary:.25\n        },\n        {\n          role:\"Responsable \u00e9ducatif\",\n          name:\"Mehdi Naciri\",\n          rating:84,\n          salary:.20\n        }\n      ],\n\n      facilities:[\n        {\n          id:\"pitches\",\n          name:\"Terrains d'entra\u00eenement\",\n          level:2,\n          max:5\n        },\n        {\n          id:\"gym\",\n          name:\"Centre de performance\",\n          level:2,\n          max:5\n        },\n        {\n          id:\"medical\",\n          name:\"P\u00f4le m\u00e9dical\",\n          level:1,\n          max:5\n        },\n        {\n          id:\"residence\",\n          name:\"R\u00e9sidence jeunes\",\n          level:2,\n          max:5\n        },\n        {\n          id:\"school\",\n          name:\"Centre \u00e9ducatif\",\n          level:2,\n          max:5\n        },\n        {\n          id:\"video\",\n          name:\"Data & vid\u00e9o\",\n          level:1,\n          max:5\n        }\n      ],\n\n      players:[\n        {\n          id:this.id(),\n          name:\"Ayoub El Khatib\",\n          category:\"U19\",\n          age:18,\n          pos:\"MC\",\n          rating:72,\n          potential:86,\n          form:78,\n          morale:82,\n          education:84,\n          status:\"Disponible\",\n          plan:\"Technique\"\n        },\n        {\n          id:this.id(),\n          name:\"Reda Naciri\",\n          category:\"U17\",\n          age:16,\n          pos:\"DC\",\n          rating:67,\n          potential:83,\n          form:75,\n          morale:79,\n          education:81,\n          status:\"Disponible\",\n          plan:\"Physique\"\n        },\n        {\n          id:this.id(),\n          name:\"Hamza Mouline\",\n          category:\"U19\",\n          age:17,\n          pos:\"AD\",\n          rating:70,\n          potential:88,\n          form:82,\n          morale:85,\n          education:76,\n          status:\"Disponible\",\n          plan:\"Technique\"\n        },\n        {\n          id:this.id(),\n          name:\"Adam Saidi\",\n          category:\"U15\",\n          age:14,\n          pos:\"MOC\",\n          rating:60,\n          potential:90,\n          form:77,\n          morale:80,\n          education:88,\n          status:\"Disponible\",\n          plan:\"Cr\u00e9ativit\u00e9\"\n        },\n        {\n          id:this.id(),\n          name:\"Yassine Rami\",\n          category:\"RESERVE\",\n          age:19,\n          pos:\"BU\",\n          rating:75,\n          potential:84,\n          form:81,\n          morale:77,\n          education:75,\n          status:\"Disponible\",\n          plan:\"Finition\"\n        },\n        {\n          id:this.id(),\n          name:\"Ilyas Chraibi\",\n          category:\"U13\",\n          age:12,\n          pos:\"DG\",\n          rating:50,\n          potential:87,\n          form:74,\n          morale:86,\n          education:91,\n          status:\"Disponible\",\n          plan:\"Fondamentaux\"\n        }\n      ],\n\n      scoutingResults:[],\n\n      journal:[\n        \"Academy Manager PRO MAX initialis\u00e9.\"\n      ]\n\n    };\n\n  },\n\n  id(){\n    return \"Y\"+Date.now().toString(36)+Math.random().toString(36).slice(2,8);\n  },\n\n  loadClub(){\n\n    const raw=localStorage.getItem(STORAGE_KEY);\n\n    if(raw){\n      try{\n        this.club=JSON.parse(raw);\n      }catch(e){\n        this.club=this.defaultClub();\n      }\n    }else{\n      this.club=this.defaultClub();\n    }\n\n    this.club.academyData =\n      this.club.academyData || this.defaultAcademy();\n\n    this.data=this.club.academyData;\n\n    if(!Array.isArray(this.data.players))\n      this.data.players=[];\n\n    if(!Array.isArray(this.data.journal))\n      this.data.journal=[];\n\n    this.syncLegacyYouth();\n\n  },\n\n  syncLegacyYouth(){\n\n    const legacy=this.club.youth || [];\n\n    legacy.forEach(y=>{\n\n      if(this.data.players.some(p=>p.name===y.name))\n        return;\n\n      this.data.players.push({\n        id:this.id(),\n        name:y.name,\n        category:this.categoryFromAge(y.age || 17),\n        age:y.age || 17,\n        pos:y.pos || \"MC\",\n        rating:Math.max(50,(y.potential || 78)-15),\n        potential:y.potential || 78,\n        form:75,\n        morale:78,\n        education:80,\n        status:\"Disponible\",\n        plan:\"\u00c9quilibr\u00e9\"\n      });\n\n    });\n\n  },\n\n  setupTabs(){\n\n    ROOT.querySelectorAll(\".ma-menu button\").forEach(btn=>{\n\n      btn.addEventListener(\"click\",()=>{\n\n        ROOT.querySelectorAll(\".ma-menu button\")\n          .forEach(b=>b.classList.remove(\"active\"));\n\n        ROOT.querySelectorAll(\".ma-tab\")\n          .forEach(tab=>tab.classList.remove(\"active\"));\n\n        btn.classList.add(\"active\");\n\n        const target=ROOT.querySelector(\"#\"+btn.dataset.tab);\n        if(target) target.classList.add(\"active\");\n\n      });\n\n    });\n\n  },\n\n  setupActions(){\n\n    ROOT.querySelectorAll('[data-action=\"sync\"]').forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.loadClub();\n        this.renderAll();\n        alert(\"Acad\u00e9mie synchronis\u00e9e avec Club Manager.\");\n      });\n    });\n\n    ROOT.querySelectorAll('[data-action=\"save\"]').forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.save();\n        alert(\"Acad\u00e9mie sauvegard\u00e9e.\");\n      });\n    });\n\n    ROOT.querySelectorAll('[data-action=\"simulate\"]').forEach(btn=>{\n      btn.addEventListener(\"click\",()=>this.simulateMonth());\n    });\n\n    ROOT.querySelectorAll(\"[data-scout]\").forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.scout(btn.dataset.scout);\n      });\n    });\n\n    ROOT.querySelectorAll(\"[data-invest]\").forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.specialInvestment(btn.dataset.invest);\n      });\n    });\n\n    ROOT.querySelector(\"#maTeamFilter\")\n      .addEventListener(\"change\",()=>this.renderYouthTable());\n\n  },\n\n  save(){\n\n    this.club.academyData=this.data;\n\n    this.club.state.academy=this.academyLevel();\n\n    this.club.youth=this.data.players\n      .filter(p=>p.category!==\"RESERVE\")\n      .map(p=>({\n        name:p.name,\n        age:p.age,\n        pos:p.pos,\n        potential:p.potential\n      }));\n\n    localStorage.setItem(\n      STORAGE_KEY,\n      JSON.stringify(this.club)\n    );\n\n  },\n\n  clamp(v,min=0,max=100){\n    return Math.max(min,Math.min(max,Math.round(v)));\n  },\n\n  money(v){\n    return Number(v || 0).toFixed(2)+\" M\";\n  },\n\n  academyLevel(){\n\n    const staff=this.staffScore();\n    const facilities=this.facilityScore();\n\n    return this.clamp(\n      this.data.training*.25+\n      this.data.scouting*.15+\n      facilities*.20+\n      staff*.15+\n      this.data.education*.10+\n      this.data.medical*.10+\n      this.data.analytics*.05\n    );\n\n  },\n\n  staffScore(){\n\n    if(!this.data.staff.length) return 0;\n\n    return Math.round(\n      this.data.staff.reduce((s,x)=>s+x.rating,0)\/\n      this.data.staff.length\n    );\n\n  },\n\n  facilityScore(){\n\n    if(!this.data.facilities.length) return 0;\n\n    return Math.round(\n      this.data.facilities.reduce(\n        (s,x)=>s+(x.level\/x.max)*100,0\n      )\/\n      this.data.facilities.length\n    );\n\n  },\n\n  avgPotential(){\n\n    if(!this.data.players.length) return 0;\n\n    return Math.round(\n      this.data.players.reduce((s,p)=>s+p.potential,0)\/\n      this.data.players.length\n    );\n\n  },\n\n  categoryFromAge(age){\n\n    if(age<=12) return \"U13\";\n    if(age<=14) return \"U15\";\n    if(age<=16) return \"U17\";\n    if(age<=18) return \"U19\";\n    return \"RESERVE\";\n\n  },\n\n  topTalents(){\n\n    return [...this.data.players]\n      .sort((a,b)=>\n        b.potential-a.potential ||\n        b.rating-a.rating\n      )\n      .slice(0,5);\n\n  },\n\n  log(text){\n\n    const prefix=\"M\"+this.data.month+\" \u2014 \";\n\n    this.data.journal.unshift(prefix+text);\n\n    if(this.data.journal.length>150)\n      this.data.journal.length=150;\n\n  },\n\n  simulateMonth(){\n\n    this.data.month++;\n\n    this.data.players.forEach(p=>{\n\n      if(p.status===\"Bless\u00e9\"){\n\n        if(Math.random()>.55){\n          p.status=\"Disponible\";\n          this.log(p.name+\" reprend l'entra\u00eenement.\");\n        }\n\n        return;\n      }\n\n      const trainingBoost=\n        (this.data.training\/100)*1.1;\n\n      const facilityBoost=\n        (this.facilityScore()\/100)*.7;\n\n      const staffBoost=\n        (this.staffScore()\/100)*.8;\n\n      const planBoost=\n        p.plan===\"\u00c9quilibr\u00e9\" ? .2 : .4;\n\n      const ageBoost=\n        p.age<=18 ? .7 : .35;\n\n      const potentialGap=\n        Math.max(0,p.potential-p.rating);\n\n      const growthChance=\n        (\n          trainingBoost+\n          facilityBoost+\n          staffBoost+\n          planBoost+\n          ageBoost\n        ) *\n        Math.min(1,potentialGap\/20);\n\n      if(Math.random()<Math.min(.95,growthChance\/3.2)){\n\n        const gain=Math.random()>.85 ? 2 : 1;\n\n        p.rating=Math.min(\n          p.potential,\n          p.rating+gain\n        );\n\n        this.log(\n          p.name+\" progresse \u00e0 \"+p.rating+\n          \" de note g\u00e9n\u00e9rale.\"\n        );\n\n      }\n\n      p.form=this.clamp(\n        p.form-2+Math.random()*6\n      );\n\n      p.morale=this.clamp(\n        p.morale-2+Math.random()*5\n      );\n\n      p.education=this.clamp(\n        p.education+\n        (this.data.education>=75 ? Math.random()*2 : -Math.random()*2)\n      );\n\n      const injuryChance=\n        Math.max(.01,.07-(this.data.medical\/2000));\n\n      if(Math.random()<injuryChance){\n\n        p.status=\"Bless\u00e9\";\n        p.form=this.clamp(p.form-8);\n\n        this.log(\n          \"Blessure d\u00e9tect\u00e9e chez \"+p.name+\".\"\n        );\n\n      }\n\n    });\n\n    if(this.data.month%3===0){\n\n      this.data.players.forEach(p=>{\n        if(Math.random()<.35 &#038;&#038; p.age<20){\n          p.age++;\n          this.updateCategory(p);\n        }\n      });\n\n    }\n\n    this.data.budget=Math.max(\n      0,\n      this.data.budget-.10\n    );\n\n    this.autoPromotionsBetweenTeams();\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  updateCategory(p){\n\n    const old=p.category;\n    const next=this.categoryFromAge(p.age);\n\n    if(next!==old){\n\n      p.category=next;\n\n      this.log(\n        p.name+\" passe de \"+old+\" \u00e0 \"+next+\".\"\n      );\n\n    }\n\n  },\n\n  autoPromotionsBetweenTeams(){\n\n    this.data.players.forEach(p=>{\n\n      if(\n        p.category===\"U17\" &&\n        p.rating>=70 &&\n        p.potential>=82\n      ){\n        p.category=\"U19\";\n        this.log(p.name+\" est promu en U19.\");\n      }\n\n      if(\n        p.category===\"U19\" &&\n        p.rating>=73 &&\n        p.age>=18\n      ){\n        p.category=\"RESERVE\";\n        this.log(p.name+\" rejoint l'\u00e9quipe r\u00e9serve.\");\n      }\n\n    });\n\n  },\n\n  scout(type){\n\n    const configs={\n      local:{\n        cost:.20,\n        count:3,\n        minPot:70,\n        maxPot:88\n      },\n      national:{\n        cost:.50,\n        count:5,\n        minPot:74,\n        maxPot:92\n      },\n      international:{\n        cost:1,\n        count:6,\n        minPot:76,\n        maxPot:95\n      }\n    };\n\n    const c=configs[type];\n\n    if(!c) return;\n\n    if(this.club.state.cash<c.cost){\n\n      alert(\"Tr\u00e9sorerie du club insuffisante.\");\n      return;\n\n    }\n\n    this.club.state.cash-=c.cost;\n    this.data.totalInvestment+=c.cost;\n\n    const results=[];\n\n    for(let i=0;i<c.count;i++){\n\n      const age=12+Math.floor(Math.random()*7);\n\n      const potential=\n        c.minPot+\n        Math.floor(\n          Math.random()*(c.maxPot-c.minPot+1)\n        );\n\n      const rating=\n        Math.max(\n          45,\n          potential-\n          (12+Math.floor(Math.random()*23))\n        );\n\n      const player={\n        id:this.id(),\n        name:\n          this.names[Math.floor(Math.random()*this.names.length)]\n          +\" \"+\n          this.surnames[Math.floor(Math.random()*this.surnames.length)],\n        category:this.categoryFromAge(age),\n        age:age,\n        pos:this.positions[Math.floor(Math.random()*this.positions.length)],\n        rating:rating,\n        potential:potential,\n        form:70+Math.floor(Math.random()*16),\n        morale:70+Math.floor(Math.random()*20),\n        education:70+Math.floor(Math.random()*22),\n        status:\"D\u00e9tect\u00e9\",\n        plan:\"\u00c9quilibr\u00e9\"\n      };\n\n      results.push(player);\n\n    }\n\n    this.data.scoutingResults=results;\n\n    this.data.scouting=this.clamp(\n      this.data.scouting+\n      (type===\"international\" ? 3 : 1)\n    );\n\n    this.log(\n      \"Campagne de d\u00e9tection \"+type+\n      \" termin\u00e9e : \"+results.length+\" profils.\"\n    );\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  recruitDetected(id){\n\n    const p=this.data.scoutingResults.find(x=>x.id===id);\n\n    if(!p) return;\n\n    const cost=.05;\n\n    if(this.data.budget<cost){\n\n      alert(\"Budget Acad\u00e9mie insuffisant.\");\n      return;\n\n    }\n\n    this.data.budget-=cost;\n\n    p.status=\"Disponible\";\n\n    this.data.players.push(p);\n\n    this.data.scoutingResults=\n      this.data.scoutingResults.filter(x=>x.id!==id);\n\n    this.log(\n      p.name+\n      \" rejoint l'Acad\u00e9mie. Potentiel \"+p.potential+\".\"\n    );\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  rejectDetected(id){\n\n    const p=this.data.scoutingResults.find(x=>x.id===id);\n\n    if(p)\n      this.log(\"Profil non retenu : \"+p.name+\".\");\n\n    this.data.scoutingResults=\n      this.data.scoutingResults.filter(x=>x.id!==id);\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  changePlan(id){\n\n    const p=this.data.players.find(x=>x.id===id);\n    if(!p) return;\n\n    const plans=[\n      \"\u00c9quilibr\u00e9\",\n      \"Technique\",\n      \"Physique\",\n      \"Finition\",\n      \"Cr\u00e9ativit\u00e9\",\n      \"Tactique\",\n      \"Fondamentaux\"\n    ];\n\n    const current=plans.indexOf(p.plan);\n\n    p.plan=plans[(current+1)%plans.length];\n\n    this.log(\n      \"Plan individuel de \"+p.name+\n      \" : \"+p.plan+\".\"\n    );\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  upgradeStaff(index){\n\n    const s=this.data.staff[index];\n    if(!s) return;\n\n    const cost=.35;\n\n    if(this.data.budget<cost){\n\n      alert(\"Budget Acad\u00e9mie insuffisant.\");\n      return;\n\n    }\n\n    if(s.rating>=95){\n\n      alert(\"Niveau maximal atteint.\");\n      return;\n\n    }\n\n    this.data.budget-=cost;\n    this.data.totalInvestment+=cost;\n\n    s.rating=this.clamp(s.rating+3,0,95);\n\n    this.log(\n      \"Formation staff : \"+s.name+\n      \" atteint \"+s.rating+\"\/100.\"\n    );\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  upgradeFacility(index){\n\n    const f=this.data.facilities[index];\n    if(!f) return;\n\n    if(f.level>=f.max){\n\n      alert(\"Infrastructure d\u00e9j\u00e0 au niveau maximal.\");\n      return;\n\n    }\n\n    const cost=Number((.45*f.level).toFixed(2));\n\n    if(this.club.state.cash<cost){\n\n      alert(\"Tr\u00e9sorerie insuffisante.\");\n      return;\n\n    }\n\n    this.club.state.cash-=cost;\n    this.data.totalInvestment+=cost;\n\n    f.level++;\n\n    this.log(\n      f.name+\n      \" passe au niveau \"+f.level+\".\"\n    );\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  specialInvestment(type){\n\n    const map={\n      training:{\n        cost:.5,\n        field:\"training\",\n        gain:5,\n        text:\"Programme technique intensif\"\n      },\n      education:{\n        cost:.3,\n        field:\"education\",\n        gain:5,\n        text:\"Programme \u00e9ducatif\"\n      },\n      medical:{\n        cost:.4,\n        field:\"medical\",\n        gain:6,\n        text:\"Programme m\u00e9dical\"\n      },\n      analytics:{\n        cost:.6,\n        field:\"analytics\",\n        gain:8,\n        text:\"Data &#038; vid\u00e9o Acad\u00e9mie\"\n      }\n    };\n\n    const x=map[type];\n    if(!x) return;\n\n    if(this.club.state.cash<x.cost){\n\n      alert(\"Tr\u00e9sorerie insuffisante.\");\n      return;\n\n    }\n\n    this.club.state.cash-=x.cost;\n    this.data.totalInvestment+=x.cost;\n\n    this.data[x.field]=this.clamp(\n      this.data[x.field]+x.gain\n    );\n\n    this.log(\n      x.text+\n      \" : investissement \"+this.money(x.cost)+\".\"\n    );\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  promoteToFirstTeam(id){\n\n    const p=this.data.players.find(x=>x.id===id);\n\n    if(!p) return;\n\n    if(p.rating<72){\n\n      alert(\n        \"Le joueur n'a pas encore le niveau minimum recommand\u00e9.\"\n      );\n      return;\n\n    }\n\n    const already=(this.club.players || [])\n      .some(x=>x.name===p.name);\n\n    if(already){\n\n      alert(\"Ce joueur est d\u00e9j\u00e0 dans l'\u00e9quipe premi\u00e8re.\");\n      return;\n\n    }\n\n    const salary=\n      Number(\n        Math.max(\n          .12,\n          (p.rating-60)*.025\n        ).toFixed(2)\n      );\n\n    const value=\n      Number(\n        Math.max(\n          .5,\n          (p.rating-60)*\n          (p.potential-p.rating+8)*\n          .04\n        ).toFixed(2)\n      );\n\n    this.club.players=this.club.players || [];\n\n    this.club.players.push({\n      name:p.name,\n      pos:p.pos,\n      age:p.age,\n      rating:p.rating,\n      form:p.form,\n      morale:p.morale,\n      value:value,\n      salary:salary,\n      contract:4,\n      status:\"Disponible\",\n      origin:\"Acad\u00e9mie MZA\"\n    });\n\n    this.club.state.salary=\n      Number(\n        (\n          (this.club.state.salary || 0)+salary\n        ).toFixed(2)\n      );\n\n    this.club.state.reputation=\n      this.clamp(\n        (this.club.state.reputation || 70)+2\n      );\n\n    this.data.promotions++;\n    this.data.generatedValue+=value;\n\n    this.data.players=\n      this.data.players.filter(x=>x.id!==id);\n\n    this.log(\n      p.name+\n      \" est promu en \u00e9quipe premi\u00e8re.\"\n    );\n\n    this.save();\n    this.renderAll();\n\n    alert(\n      p.name+\n      \" rejoint l'\u00e9quipe premi\u00e8re.\"\n    );\n\n  },\n\n  loanYouth(id){\n\n    const p=this.data.players.find(x=>x.id===id);\n\n    if(!p) return;\n\n    if(p.category!==\"RESERVE\"){\n\n      alert(\"Le pr\u00eat est r\u00e9serv\u00e9 ici aux joueurs de la r\u00e9serve.\");\n      return;\n\n    }\n\n    p.status=\"Pr\u00eat\u00e9\";\n\n    p.morale=this.clamp(p.morale+3);\n\n    this.log(\n      p.name+\n      \" est pr\u00eat\u00e9 pour obtenir du temps de jeu.\"\n    );\n\n    this.save();\n    this.renderAll();\n\n  },\n\n  renderAll(){\n\n    this.renderKPIs();\n    this.renderCockpit();\n    this.renderYouthTable();\n    this.renderScoutingResults();\n    this.renderDevelopment();\n    this.renderStaff();\n    this.renderFacilities();\n    this.renderFinance();\n    this.renderPathway();\n    this.renderJournal();\n\n  },\n\n  renderKPIs(){\n\n    ROOT.querySelector(\"#maAcademyLevel\")\n      .textContent=this.academyLevel()+\"%\";\n\n    ROOT.querySelector(\"#maYouthCount\")\n      .textContent=this.data.players.length;\n\n    ROOT.querySelector(\"#maAvgPotential\")\n      .textContent=this.avgPotential();\n\n    ROOT.querySelector(\"#maBudget\")\n      .textContent=this.money(this.data.budget);\n\n    ROOT.querySelector(\"#maPromotions\")\n      .textContent=this.data.promotions;\n\n    ROOT.querySelector(\"#maElite\")\n      .textContent=\n        this.data.players.filter(p=>p.potential>=85).length;\n\n  },\n\n  renderCockpit(){\n\n    ROOT.querySelector(\"#maObjectivePromotions\")\n      .textContent=this.data.promotions+\" \/ 2\";\n\n    const educationAvg=\n      this.data.players.length\n      ? Math.round(\n          this.data.players.reduce((s,p)=>s+p.education,0)\/\n          this.data.players.length\n        )\n      :0;\n\n    ROOT.querySelector(\"#maEducationKpi\")\n      .textContent=educationAvg+\"%\";\n\n    ROOT.querySelector(\"#maTrainingBar\")\n      .style.width=this.data.training+\"%\";\n\n    ROOT.querySelector(\"#maTrainingValue\")\n      .textContent=this.data.training+\"%\";\n\n    ROOT.querySelector(\"#maScoutingBar\")\n      .style.width=this.data.scouting+\"%\";\n\n    ROOT.querySelector(\"#maScoutingValue\")\n      .textContent=this.data.scouting+\"%\";\n\n    ROOT.querySelector(\"#maFacilityBar\")\n      .style.width=this.facilityScore()+\"%\";\n\n    ROOT.querySelector(\"#maFacilityValue\")\n      .textContent=this.facilityScore()+\"%\";\n\n    ROOT.querySelector(\"#maStaffBar\")\n      .style.width=this.staffScore()+\"%\";\n\n    ROOT.querySelector(\"#maStaffValue\")\n      .textContent=this.staffScore()+\"%\";\n\n    ROOT.querySelector(\"#maTopTalents\").innerHTML=\n      this.topTalents().map(p=>`\n        <div class=\"ma-talent\">\n          <strong>${p.name}<\/strong>\n          ${p.category} \u2022 ${p.pos}\n          \u2022 Note ${p.rating}\n          \u2022 Potentiel ${p.potential}\n        <\/div>\n      `).join(\"\");\n\n    let rec;\n\n    const candidates=this.data.players\n      .filter(p=>\n        p.rating>=72 &&\n        (p.category===\"U19\" || p.category===\"RESERVE\")\n      )\n      .sort((a,b)=>b.rating-a.rating);\n\n    if(candidates.length){\n\n      rec=`\n        <strong>${candidates[0].name}<\/strong>\n        est actuellement le candidat le plus proche de l'\u00e9quipe premi\u00e8re :\n        note ${candidates[0].rating}, potentiel ${candidates[0].potential}.\n      `;\n\n    }else if(this.facilityScore()<70){\n\n      rec=\"Priorit\u00e9 recommand\u00e9e : renforcer les infrastructures de formation.\";\n\n    }else if(this.staffScore()<80){\n\n      rec=\"Priorit\u00e9 recommand\u00e9e : d\u00e9velopper les comp\u00e9tences du staff.\";\n\n    }else{\n\n      rec=\"Priorit\u00e9 recommand\u00e9e : intensifier la d\u00e9tection de talents.\";\n\n    }\n\n    ROOT.querySelector(\"#maRecommendation\")\n      .innerHTML=rec;\n\n  },\n\n  renderYouthTable(){\n\n    const filter=ROOT.querySelector(\"#maTeamFilter\").value;\n\n    const list=this.data.players\n      .filter(p=>filter===\"ALL\" || p.category===filter)\n      .sort((a,b)=>{\n        const order={\n          U13:1,U15:2,U17:3,U19:4,RESERVE:5\n        };\n        return order[a.category]-order[b.category];\n      });\n\n    ROOT.querySelector(\"#maYouthTable\").innerHTML=\n      list.map(p=>`\n\n        <tr>\n          <td><strong>${p.name}<\/strong><\/td>\n          <td>${p.category}<\/td>\n          <td>${p.age}<\/td>\n          <td>${p.pos}<\/td>\n          <td><span class=\"ma-player-score\">${p.rating}<\/span><\/td>\n          <td><strong>${p.potential}<\/strong><\/td>\n          <td>${p.form}%<\/td>\n          <td>${p.morale}%<\/td>\n          <td>${p.education}%<\/td>\n          <td><span class=\"ma-status\">${p.status}<\/span><\/td>\n          <td>\n            <button data-plan-id=\"${p.id}\">\n              Plan : ${p.plan}\n            <\/button>\n          <\/td>\n        <\/tr>\n\n      `).join(\"\");\n\n    ROOT.querySelectorAll(\"[data-plan-id]\").forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.changePlan(btn.dataset.planId);\n      });\n    });\n\n  },\n\n  renderScoutingResults(){\n\n    const el=ROOT.querySelector(\"#maScoutingResults\");\n\n    if(!this.data.scoutingResults.length){\n\n      el.innerHTML=\"<p>Aucune campagne r\u00e9cente.<\/p>\";\n      return;\n\n    }\n\n    el.innerHTML=`\n      <div class=\"ma-result-grid\">\n        ${this.data.scoutingResults.map(p=>`\n          <div class=\"ma-result\">\n            <strong>${p.name}<\/strong>\n            <p>\n              ${p.age} ans \u2022 ${p.pos}<br>\n              Note ${p.rating} \u2022 Potentiel ${p.potential}\n            <\/p>\n\n            <button data-recruit-id=\"${p.id}\">\n              \u2705 Recruter\n            <\/button>\n\n            <button data-reject-id=\"${p.id}\">\n              \u2715 \u00c9carter\n            <\/button>\n          <\/div>\n        `).join(\"\")}\n      <\/div>\n    `;\n\n    ROOT.querySelectorAll(\"[data-recruit-id]\").forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.recruitDetected(btn.dataset.recruitId);\n      });\n    });\n\n    ROOT.querySelectorAll(\"[data-reject-id]\").forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.rejectDetected(btn.dataset.rejectId);\n      });\n    });\n\n  },\n\n  renderDevelopment(){\n\n    ROOT.querySelector(\"#maDevelopmentGrid\").innerHTML=\n      [...this.data.players]\n      .sort((a,b)=>b.potential-a.potential)\n      .map(p=>{\n\n        const progress=\n          p.potential\n          ? Math.round((p.rating\/p.potential)*100)\n          :0;\n\n        return `\n          <article class=\"ma-card\">\n            <span class=\"ma-kicker-dark\">${p.category} \u2022 ${p.pos}<\/span>\n            <h3>${p.name}<\/h3>\n\n            <div class=\"ma-line\">\n              <span>Note actuelle<\/span>\n              <strong>${p.rating}<\/strong>\n            <\/div>\n\n            <div class=\"ma-line\">\n              <span>Potentiel<\/span>\n              <strong>${p.potential}<\/strong>\n            <\/div>\n\n            <div class=\"ma-line\">\n              <span>Plan<\/span>\n              <strong>${p.plan}<\/strong>\n            <\/div>\n\n            <div class=\"ma-dev-bar\">\n              <b style=\"width:${progress}%\"><\/b>\n            <\/div>\n\n            <button data-plan-id=\"${p.id}\">\n              Changer le plan individuel\n            <\/button>\n          <\/article>\n        `;\n\n      }).join(\"\");\n\n    ROOT.querySelectorAll(\"#maDevelopmentGrid [data-plan-id]\")\n      .forEach(btn=>{\n        btn.addEventListener(\"click\",()=>{\n          this.changePlan(btn.dataset.planId);\n        });\n      });\n\n  },\n\n  renderStaff(){\n\n    ROOT.querySelector(\"#maStaffGrid\").innerHTML=\n      this.data.staff.map((s,i)=>`\n\n        <article class=\"ma-card\">\n          <span class=\"ma-kicker-dark\">${s.role}<\/span>\n          <h3>${s.name}<\/h3>\n\n          <div class=\"ma-line\">\n            <span>Comp\u00e9tence<\/span>\n            <strong>${s.rating}\/100<\/strong>\n          <\/div>\n\n          <div class=\"ma-line\">\n            <span>Salaire<\/span>\n            <strong>${this.money(s.salary)}<\/strong>\n          <\/div>\n\n          <button data-staff-upgrade=\"${i}\">\n            \ud83c\udf93 Former le collaborateur \u2014 0,35 M\n          <\/button>\n        <\/article>\n\n      `).join(\"\");\n\n    ROOT.querySelectorAll(\"[data-staff-upgrade]\")\n      .forEach(btn=>{\n        btn.addEventListener(\"click\",()=>{\n          this.upgradeStaff(\n            Number(btn.dataset.staffUpgrade)\n          );\n        });\n      });\n\n  },\n\n  renderFacilities(){\n\n    ROOT.querySelector(\"#maFacilitiesGrid\").innerHTML=\n      this.data.facilities.map((f,i)=>{\n\n        const pct=Math.round(\n          (f.level\/f.max)*100\n        );\n\n        return `\n          <article class=\"ma-card\">\n            <span class=\"ma-kicker-dark\">INFRASTRUCTURE<\/span>\n            <h3>${f.name}<\/h3>\n\n            <div class=\"ma-line\">\n              <span>Niveau<\/span>\n              <strong>${f.level} \/ ${f.max}<\/strong>\n            <\/div>\n\n            <div class=\"ma-dev-bar\">\n              <b style=\"width:${pct}%\"><\/b>\n            <\/div>\n\n            <button data-facility-upgrade=\"${i}\">\n              \u2b06 Am\u00e9liorer\n            <\/button>\n          <\/article>\n        `;\n\n      }).join(\"\");\n\n    ROOT.querySelectorAll(\"[data-facility-upgrade]\")\n      .forEach(btn=>{\n        btn.addEventListener(\"click\",()=>{\n          this.upgradeFacility(\n            Number(btn.dataset.facilityUpgrade)\n          );\n        });\n      });\n\n  },\n\n  renderFinance(){\n\n    ROOT.querySelector(\"#maFinanceSummary\").innerHTML=`\n\n      <div class=\"ma-line\">\n        <span>Budget Acad\u00e9mie<\/span>\n        <strong>${this.money(this.data.budget)}<\/strong>\n      <\/div>\n\n      <div class=\"ma-line\">\n        <span>Tr\u00e9sorerie Club<\/span>\n        <strong>${this.money(this.club.state.cash)}<\/strong>\n      <\/div>\n\n      <div class=\"ma-line\">\n        <span>Investissements cumul\u00e9s<\/span>\n        <strong>${this.money(this.data.totalInvestment)}<\/strong>\n      <\/div>\n\n      <div class=\"ma-line\">\n        <span>Valeur joueurs g\u00e9n\u00e9r\u00e9e<\/span>\n        <strong>${this.money(this.data.generatedValue)}<\/strong>\n      <\/div>\n\n    `;\n\n    const roi=\n      this.data.totalInvestment>0\n      ? (\n          this.data.generatedValue\/\n          this.data.totalInvestment\n        ).toFixed(2)\n      :\"0.00\";\n\n    ROOT.querySelector(\"#maROI\").innerHTML=`\n\n      <div style=\"font-size:44px;font-weight:900\">\n        ${roi}x\n      <\/div>\n\n      <p>\n        Valeur produite par l'Acad\u00e9mie pour chaque unit\u00e9 investie.\n      <\/p>\n\n      <div class=\"ma-line\">\n        <span>Promotions \u00e9quipe premi\u00e8re<\/span>\n        <strong>${this.data.promotions}<\/strong>\n      <\/div>\n\n      <div class=\"ma-line\">\n        <span>Niveau Acad\u00e9mie<\/span>\n        <strong>${this.academyLevel()}%<\/strong>\n      <\/div>\n\n    `;\n\n  },\n\n  renderPathway(){\n\n    const eligible=this.data.players\n      .filter(p=>\n        p.category===\"RESERVE\" ||\n        p.category===\"U19\"\n      )\n      .sort((a,b)=>\n        b.rating-a.rating ||\n        b.potential-a.potential\n      );\n\n    const el=ROOT.querySelector(\"#maPathwayGrid\");\n\n    if(!eligible.length){\n\n      el.innerHTML=`\n        <article class=\"ma-panel\">\n          Aucun joueur n'est encore proche de l'\u00e9quipe premi\u00e8re.\n        <\/article>\n      `;\n      return;\n\n    }\n\n    el.innerHTML=eligible.map(p=>{\n\n      const readiness=this.clamp(\n        p.rating*.65+\n        p.form*.15+\n        p.morale*.10+\n        (100-Math.max(0,p.potential-p.rating)*3)*.10\n      );\n\n      return `\n        <article class=\"ma-card\">\n\n          <span class=\"ma-kicker-dark\">\n            ${p.category} \u2022 ${p.pos}\n          <\/span>\n\n          <h3>${p.name}<\/h3>\n\n          <div class=\"ma-line\">\n            <span>Note<\/span>\n            <strong>${p.rating}<\/strong>\n          <\/div>\n\n          <div class=\"ma-line\">\n            <span>Potentiel<\/span>\n            <strong>${p.potential}<\/strong>\n          <\/div>\n\n          <div class=\"ma-line\">\n            <span>Pr\u00e9paration \u00e9quipe 1<\/span>\n            <strong>${readiness}%<\/strong>\n          <\/div>\n\n          <div class=\"ma-dev-bar\">\n            <b style=\"width:${readiness}%\"><\/b>\n          <\/div>\n\n          <button data-promote=\"${p.id}\">\n            \ud83d\ude80 Promouvoir \u00e9quipe premi\u00e8re\n          <\/button>\n\n          ${\n            p.category===\"RESERVE\"\n            ? `<button data-loan=\"${p.id}\">\ud83d\udd01 Envoyer en pr\u00eat<\/button>`\n            :\"\"\n          }\n\n        <\/article>\n      `;\n\n    }).join(\"\");\n\n    ROOT.querySelectorAll(\"[data-promote]\").forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.promoteToFirstTeam(btn.dataset.promote);\n      });\n    });\n\n    ROOT.querySelectorAll(\"[data-loan]\").forEach(btn=>{\n      btn.addEventListener(\"click\",()=>{\n        this.loanYouth(btn.dataset.loan);\n      });\n    });\n\n  },\n\n  renderJournal(){\n\n    ROOT.querySelector(\"#maJournal\").innerHTML=\n      this.data.journal.map(x=>`\n        <div class=\"ma-journal-entry\">\n          ${x}\n        <\/div>\n      `).join(\"\");\n\n  }\n\n};\n\nAcademy.init();\n\n})();\n<\/script>\n","protected":false},"excerpt":{"rendered":"<p>MZA FOOTBALL MANAGEMENT 360\u00b0 \ud83c\udf93 ACADEMY MANAGER PRO MAX U13 \u2022 U15 \u2022 U17 \u2022 U19 \u2022 R\u00e9serve \u2022 D\u00e9tection \u2022 Progression \u2022 Promotion \ud83d\udd04 Synchroniser Club \ud83d\udcbe Sauvegarder \u25b6 Simuler un mois Niveau Acad\u00e9mie &#8212; Jeunes &#8212; Potentiel moyen &#8212; Budget Acad\u00e9mie &#8212; Promotions &#8212; Talents 85+ &#8212; \ud83d\udcca Cockpit Acad\u00e9mie \ud83d\udc65 \u00c9quipes jeunes [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-231","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/maroczain.com\/aviation.maroczain.com\/wp-json\/wp\/v2\/pages\/231","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/maroczain.com\/aviation.maroczain.com\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/maroczain.com\/aviation.maroczain.com\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/maroczain.com\/aviation.maroczain.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/maroczain.com\/aviation.maroczain.com\/wp-json\/wp\/v2\/comments?post=231"}],"version-history":[{"count":1,"href":"https:\/\/maroczain.com\/aviation.maroczain.com\/wp-json\/wp\/v2\/pages\/231\/revisions"}],"predecessor-version":[{"id":233,"href":"https:\/\/maroczain.com\/aviation.maroczain.com\/wp-json\/wp\/v2\/pages\/231\/revisions\/233"}],"wp:attachment":[{"href":"https:\/\/maroczain.com\/aviation.maroczain.com\/wp-json\/wp\/v2\/media?parent=231"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}