/* Diaporama Apex Sport Performance. Même scène, typographie et commandes que les autres
   diaporamas TwinMe (deck.css, deck-mobile.css, twinme.css) ; seules les mises en page propres
   à Apex vivent ici : figure, schémas (saison, sept angles, rapports, équipe, cadre), pastilles. */
body.apex-presentation {
  --accent: #cdef9a;
  --aqua: #cdef9a;
  --apex-ink: #06141f;
  --apex-line: rgba(205, 239, 154, .42);
  --apex-card: rgba(12, 44, 43, .74);
  --apex-panel-bottom: 92px;
  --u: min(1vw, calc(100vh * 16 / 9 / 100));
  color-scheme: dark;
}
.apex-presentation .apex-eyebrow { margin: 0 0 calc(var(--u) * 1.1); color: var(--accent); font-size: clamp(11px, calc(var(--u) * .92), 15px); font-weight: 800; letter-spacing: .18em; text-transform: uppercase; }
.apex-presentation .apex-caption { max-width: 46ch; }
.apex-presentation .content.center .apex-caption { max-width: 50ch; }
.apex-presentation .apex-controls { opacity: .94; }
.apex-presentation .apex-controls button:disabled { opacity: .3; cursor: default; }
.apex-presentation .apex-controls .notes-button { width: 38px; padding: 0; font-size: 18px; }
.apex-presentation .speaker-note { display: none !important; }
.apex-presentation.apex-embedded .apex-return { display: none; }
.apex-presentation .apex-return { gap: 8px; }
.apex-presentation .act-nav button { min-height: 44px; padding: 8px 0; }
.apex-presentation .brand img { object-fit: contain; }
.apex-presentation .notes-panel { bottom: var(--apex-panel-bottom); max-height: min(65vh, calc(100dvh - var(--apex-panel-bottom) - 20px)); }
.apex-presentation .chapters-sheet { bottom: var(--apex-panel-bottom); max-height: min(74vh, calc(100dvh - var(--apex-panel-bottom) - 20px)); }
.apex-presentation .notes-panel h3,
.apex-presentation .help-panel h3 { padding-inline-end: 35px; line-height: 1.4; }
.apex-presentation .notes-panel p + p { margin-top: 14px; }
.apex-presentation .apex-source { border-top: 1px solid #496276; padding-top: 14px; }
.apex-presentation .apex-source > span { display: block; color: #abc5d7; font-size: 12px; }
.apex-presentation .apex-source a { display: inline-block; min-height: 44px; padding: 8px 0; color: #fff; text-underline-offset: 4px; }
.apex-presentation .apex-panel-close { position: absolute; inset-inline-end: 8px; top: 8px; width: 44px; height: 44px; border: 0; border-radius: 50%; background: transparent; color: #fff; font: inherit; font-size: 28px; cursor: pointer; }
.apex-presentation :is(a, button, [tabindex]):focus-visible { outline: 3px solid #f5d48a; outline-offset: 4px; }
.apex-presentation h1:focus, .apex-presentation h2:focus { outline: none; }
.apex-presentation .apex-skip { position: fixed; top: -100px; left: 12px; z-index: 120; padding: 12px 18px; background: #fff; color: #061a2c; }
.apex-presentation .apex-skip:focus { top: 12px; }
.apex-presentation .apex-noscript { padding: 24px; color: #061a2c; background: #fff; }

/* ---- Fonds des diapositives sans photo ---- */
.apex-presentation .apex-figure-slide,
.apex-presentation .apex-diagram-slide {
  background:
    radial-gradient(120% 90% at 78% 30%, rgba(205, 239, 154, .10), transparent 58%),
    radial-gradient(90% 80% at 10% 100%, rgba(128, 201, 244, .10), transparent 60%),
    linear-gradient(135deg, #0a2230, #03101d 78%);
}

/* ---- Figure : l'image carrée à côté du texte ---- */
.apex-presentation .apex-figure {
  position: absolute; z-index: 1; margin: 0;
  top: 50%; inset-inline-end: 6.5%; transform: translateY(-50%);
  width: min(40%, 64vh); aspect-ratio: 1;
  border-radius: calc(var(--u) * 1.6); overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .45), 0 0 0 1px rgba(205, 239, 154, .18);
}
.apex-presentation .apex-figure img { display: block; width: 100%; height: 100%; object-fit: cover; }
.apex-presentation .apex-figure-copy { width: 50%; }
.apex-presentation .apex-figure-copy h2 { max-width: 15ch; }

/* ---- Schémas : texte en haut, schéma dessous ---- */
.apex-presentation .apex-diagram-copy { width: 100%; justify-content: center; padding: 7.2% 7.5% 9.5%; gap: 0; }
.apex-presentation .apex-diagram-copy h2 { max-width: 26ch; font-size: clamp(28px, calc(var(--u) * 4), 64px); }
.apex-presentation .apex-diagram-copy .apex-caption { max-width: 70ch; margin-top: calc(var(--u) * 1.2); }
.apex-presentation .apex-diagram { margin-top: calc(var(--u) * 3.2); width: 100%; }

/* Saison : quatre phases et leurs prélèvements (exemple fictif) */
.apex-presentation .apex-season ol { display: grid; grid-template-columns: repeat(4, 1fr); gap: calc(var(--u) * 1.4); margin: 0; padding: 0; list-style: none; }
.apex-presentation .apex-season li { padding: calc(var(--u) * 2.1) calc(var(--u) * 2); border-radius: calc(var(--u) * 1.2); background: var(--apex-card); border: 1px solid var(--apex-line); }
.apex-presentation .apex-season b { display: block; margin-bottom: calc(var(--u) * 1.5); font-size: clamp(15px, calc(var(--u) * 1.7), 26px); }
.apex-presentation .apex-dots { display: grid; grid-template-columns: repeat(10, 1fr); gap: calc(var(--u) * .7); }
.apex-presentation .apex-dots i { display: block; aspect-ratio: 1; border-radius: 50%; border: 1px solid rgba(205, 239, 154, .45); }
.apex-presentation .apex-dots i.on { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 10px rgba(205, 239, 154, .35); }
.apex-presentation .apex-legend { margin: calc(var(--u) * 1.4) 0 0; color: #b9cdd8; font-size: clamp(12px, calc(var(--u) * 1.1), 17px); }

/* Sept angles */
.apex-presentation .apex-angles { display: grid; grid-template-columns: repeat(4, 1fr); gap: calc(var(--u) * 1.1); margin: calc(var(--u) * 4) 0 0; padding: 0; list-style: none; }
.apex-presentation .apex-angles li { display: flex; flex-direction: column; gap: calc(var(--u) * .6); padding: calc(var(--u) * 1.7); border-radius: calc(var(--u) * 1); background: var(--apex-card); border: 1px solid var(--apex-line); }
.apex-presentation .apex-angle-no { color: var(--accent); font-size: clamp(10px, calc(var(--u) * .85), 14px); font-weight: 800; letter-spacing: .12em; }
.apex-presentation .apex-angles b { font-size: clamp(14px, calc(var(--u) * 1.45), 23px); line-height: 1.25; }
.apex-presentation .apex-angles li > span:last-child { color: #c6d6df; font-size: clamp(12px, calc(var(--u) * 1.1), 18px); line-height: 1.4; }

/* Rapports : l'éventail des en-têtes fictifs */
.apex-presentation .apex-reports { position: relative; }
.apex-presentation .apex-reports ul { display: grid; grid-template-columns: 1fr 1fr; gap: calc(var(--u) * 2) calc(var(--u) * 3); max-width: 84%; margin: 0; padding: 0; list-style: none; }
.apex-presentation .apex-reports li { display: flex; flex-direction: column; gap: calc(var(--u) * .8); }
.apex-presentation .apex-reports li:nth-child(odd) img { transform: rotate(-1.6deg); }
.apex-presentation .apex-reports li:nth-child(even) img { transform: rotate(1.4deg) translateY(6px); }
.apex-presentation .apex-reports img { display: block; width: 100%; height: auto; border-radius: 6px; background: #fff; box-shadow: 0 18px 40px rgba(0, 0, 0, .45); }
.apex-presentation .apex-reports li span { font-size: clamp(13px, calc(var(--u) * 1.25), 20px); font-weight: 700; }
.apex-presentation .apex-badge { position: absolute; top: calc(var(--u) * -3.6); inset-inline-end: 16%; margin: 0; padding: 6px 12px; border-radius: 999px; background: var(--accent); color: var(--apex-ink); font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }

/* Équipe : l'athlète au centre */
.apex-presentation .apex-orbit { position: relative; height: min(52vh, calc(var(--u) * 29)); }
.apex-presentation .apex-orbit::before { content: ''; position: absolute; left: 50%; top: 50%; width: min(46vh, calc(var(--u) * 25)); aspect-ratio: 1; transform: translate(-50%, -50%); border: 1px dashed var(--apex-line); border-radius: 50%; }
.apex-presentation .apex-orbit-center { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: grid; place-items: center; width: calc(var(--u) * 10); aspect-ratio: 1; border-radius: 50%; background: var(--accent); color: var(--apex-ink); font-weight: 800; font-size: clamp(13px, calc(var(--u) * 1.25), 20px); text-align: center; box-shadow: 0 0 40px rgba(205, 239, 154, .35); }
.apex-presentation .apex-orbit-node { position: absolute; transform: translate(-50%, -50%); padding: calc(var(--u) * .8) calc(var(--u) * 1.4); border-radius: 999px; background: var(--apex-card); border: 1px solid var(--apex-line); font-weight: 700; font-size: clamp(12px, calc(var(--u) * 1.1), 18px); white-space: nowrap; }
.apex-presentation .apex-orbit-node.n1 { left: 30%; top: 10%; }
.apex-presentation .apex-orbit-node.n2 { left: 70%; top: 10%; }
.apex-presentation .apex-orbit-node.n3 { left: 80%; top: 62%; }
.apex-presentation .apex-orbit-node.n4 { left: 50%; top: 96%; }
.apex-presentation .apex-orbit-node.n5 { left: 20%; top: 62%; }

/* Ce qu'est TwinMe, et ce qu'il n'est pas */
.apex-presentation .apex-boundary { display: grid; grid-template-columns: 1fr 1fr; gap: calc(var(--u) * 1.6); }
.apex-presentation .apex-boundary > div { padding: calc(var(--u) * 2.6); border-radius: calc(var(--u) * 1.2); border: 1px solid var(--apex-line); background: var(--apex-card); }
.apex-presentation .apex-boundary .apex-isnot { border-color: rgba(128, 201, 244, .35); background: rgba(10, 34, 48, .8); }
.apex-presentation .apex-boundary h3 { margin: 0 0 calc(var(--u) * .8); color: var(--accent); font-size: clamp(15px, calc(var(--u) * 1.5), 24px); }
.apex-presentation .apex-boundary .apex-isnot h3 { color: #9fd3f4; }
.apex-presentation .apex-boundary p { margin: 0; font-size: clamp(14px, calc(var(--u) * 1.45), 23px); line-height: 1.5; }
.apex-presentation .apex-boundary .apex-apexline { grid-column: 1 / -1; padding-top: calc(var(--u) * .4); color: #d9e7ee; font-weight: 700; }
.apex-presentation .apex-est-nest-pas-slide .apex-diagram-copy h2 { max-width: 30ch; }

/* Pastilles des sources compatibles */
.apex-presentation .apex-chips-label { margin: calc(var(--u) * 1.8) 0 calc(var(--u) * .7); color: var(--accent); font-size: clamp(11px, calc(var(--u) * .92), 15px); font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.apex-presentation .apex-chips { display: flex; flex-wrap: wrap; gap: 8px; max-width: 56ch; margin: 0; padding: 0; list-style: none; }
.apex-presentation .apex-chips li { padding: 6px 12px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .28); background: rgba(3, 16, 29, .55); font-size: clamp(11px, calc(var(--u) * 1), 16px); font-weight: 600; }

/* Dernière diapositive : les deux gestes */
.apex-presentation .apex-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 22px; margin: calc(var(--u) * 2.2) 0 0; }
.apex-presentation .apex-cta-button { display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 12px 22px; border-radius: 999px; background: var(--accent); color: var(--apex-ink); font-weight: 800; text-decoration: none; }
.apex-presentation .apex-cta-link { color: #fff; font-weight: 700; text-underline-offset: 5px; }

/* ---- Arabe : la figure passe à gauche, le texte à droite ---- */
[dir="rtl"] .apex-presentation .apex-figure-copy { left: auto; right: 0; }
[dir="rtl"] .apex-presentation .apex-reports li:nth-child(odd) img { transform: rotate(1.6deg); }
[dir="rtl"] .apex-presentation .apex-reports li:nth-child(even) img { transform: rotate(-1.4deg) translateY(6px); }
[dir="rtl"] .apex-presentation .apex-eyebrow,
[dir="rtl"] .apex-presentation .apex-chips-label { letter-spacing: 0; }

/* Keep all slides readable if scripting is unavailable. */
html:has(body.apex-presentation:not(.apex-ready)) { height: auto; overflow: auto; }
.apex-presentation:not(.apex-ready) { height: auto; overflow: auto; }
.apex-presentation:not(.apex-ready) .deck-shell { position: static; display: block; }
.apex-presentation:not(.apex-ready) .stage { width: 100%; height: auto; overflow: visible; }
.apex-presentation:not(.apex-ready) .slide { position: relative; display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; animation: none; }
.apex-presentation:not(.apex-ready) :is(.controls, .act-nav, .progress) { display: none; }

@media (max-width: 760px), (orientation: portrait) {
  body.apex-presentation { --u: 1vw; }
  .apex-presentation .stage { width: 100vw; height: 100svh; }
  .apex-presentation .brand { top: 23px; right: 20px; width: 112px; }
  [dir="rtl"] .apex-presentation .brand { right: auto; left: 20px; }
  .apex-presentation .site-return { max-width: calc(100vw - 155px); font-size: 11px; padding-inline: 11px; }
  .apex-presentation .content,
  .apex-presentation .slide .content.bottom { width: 100%; padding: 100px 24px max(172px, var(--apex-copy-bottom, 172px)) !important; justify-content: flex-end; }
  .apex-presentation .slide .content h1,
  .apex-presentation .slide .content h2 { max-width: 18ch !important; font-size: clamp(30px, 8.2vw, 46px) !important; line-height: 1.07 !important; }
  .apex-presentation .slide .apex-caption { margin-top: 16px; font-size: 17px; line-height: 1.4; max-width: 36ch; }
  .apex-presentation .scrim.left { background: linear-gradient(0deg, #03101d 6%, rgba(3,16,29,.9) 38%, rgba(3,16,29,.45) 68%, rgba(3,16,29,.1)); }
  .apex-presentation .slide-no { right: 22px; bottom: 147px; font-size: 11px; }
  .apex-presentation .apex-controls { bottom: calc(64px + env(safe-area-inset-bottom, 0px)); gap: 4px; padding: 6px; }
  .apex-presentation .apex-controls button { width: 44px; height: 44px; }
  .apex-presentation .apex-controls .notes-button { width: 44px; }
  .apex-presentation .apex-controls .counter { min-width: 52px; }
  .apex-presentation #fullBtn { display: none; }
  .apex-presentation .notes-panel { left: 8px; right: 8px; width: auto; }
  .apex-presentation .help-panel { top: auto; bottom: var(--apex-panel-bottom); left: 8px; right: 8px; width: auto; max-height: calc(100dvh - var(--apex-panel-bottom) - 20px); transform: none; }

  /* Figure : l'image en haut, le texte en bas */
  .apex-presentation .apex-figure { top: 84px; inset-inline: 24px; transform: none; width: auto; max-height: 40svh; aspect-ratio: 1; margin-inline: auto; max-width: 40svh; }
  .apex-presentation .apex-figure-copy { width: 100%; }

  /* Schémas : le texte d'abord, le schéma ensuite, avec défilement si l'écran est court */
  .apex-presentation .apex-diagram-copy { justify-content: flex-start; padding: 86px 22px max(170px, var(--apex-copy-bottom, 170px)) !important; overflow-y: auto; }
  .apex-presentation .apex-diagram-copy h2 { font-size: clamp(26px, 7.4vw, 38px) !important; }
  .apex-presentation .apex-diagram-copy .apex-caption { font-size: 15px; }
  .apex-presentation .apex-diagram { margin-top: 18px; }
  .apex-presentation .apex-season ol { grid-template-columns: 1fr 1fr; gap: 10px; }
  .apex-presentation .apex-season li { padding: 12px; }
  .apex-presentation .apex-season b { font-size: 14px; margin-bottom: 8px; }
  .apex-presentation .apex-dots { gap: 4px; }
  .apex-presentation .apex-angles { grid-template-columns: 1fr 1fr; gap: 8px; }
  .apex-presentation .apex-angles li { padding: 9px 10px; gap: 2px; }
  .apex-presentation .apex-angles b { font-size: 12.5px; }
  .apex-presentation .apex-angles li > span:last-child { display: none; }
  .apex-presentation .apex-reports ul { grid-template-columns: 1fr 1fr; gap: 12px 10px; max-width: none; }
  .apex-presentation .apex-reports li span { font-size: 12px; }
  .apex-presentation .apex-badge { position: static; display: inline-block; margin-bottom: 10px; }
  .apex-presentation .apex-orbit { height: 300px; }
  .apex-presentation .apex-orbit::before { width: 250px; }
  .apex-presentation .apex-orbit-center { width: 96px; font-size: 13px; }
  .apex-presentation .apex-orbit-node { font-size: 12px; padding: 7px 10px; white-space: normal; max-width: 42vw; text-align: center; }
  .apex-presentation .apex-orbit-node.n1 { left: 26%; top: 8%; }
  .apex-presentation .apex-orbit-node.n2 { left: 74%; top: 8%; }
  .apex-presentation .apex-orbit-node.n3 { left: 78%; top: 66%; }
  .apex-presentation .apex-orbit-node.n5 { left: 22%; top: 66%; }
  .apex-presentation .apex-boundary { grid-template-columns: 1fr; gap: 10px; }
  .apex-presentation .apex-boundary > div { padding: 14px; }
  .apex-presentation .apex-boundary p { font-size: 14px; }
  .apex-presentation .apex-chips { gap: 6px; }
  .apex-presentation .apex-chips li { font-size: 12px; padding: 5px 10px; }
  .apex-presentation:not(.apex-ready) .slide { min-height: 740px; aspect-ratio: auto; }
}

@media (max-height: 620px) and (max-width: 760px) {
  .apex-presentation .brand { top: 16px; width: 92px; }
  .apex-presentation .slide .content h1,
  .apex-presentation .slide .content h2 { font-size: 28px !important; }
  .apex-presentation .slide .apex-caption { font-size: 15px; margin-top: 10px; }
  .apex-presentation .slide-no { display: none; }
}

@media print {
  .apex-presentation .stage { width: 16in; height: auto; }
  .apex-presentation .slide { width: 16in; height: 9in; }
  .apex-presentation .apex-skip { display: none; }
}
