/* ── En-tête du mentorat ──────────────────────────────────────────────────
   Le mentor en grand, et le déclic montré sur une ligne de code d'apprenant.
   Couleurs du site : nuit #0a0a14, or #f59e0b, cyan #00d4ff, vert #10b981. */
.mh {
  --mh-or: #f59e0b; --mh-nuit: #0a0a14; --mh-texte: #e2e8f0;
  --mh-bord: max(48px, calc((100vw - 1200px) / 2 + 48px));
  position: relative; overflow: hidden; isolation: isolate;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); align-items: center;
  min-height: min(calc(100vh - 58px), 880px);
  padding: 0 0 0 var(--mh-bord);
  background: radial-gradient(900px 620px at 18% 30%, rgba(245,158,11,.10), transparent 65%), var(--mh-nuit);
}
.mh-texte { position: relative; z-index: 3; padding: 56px 72px 56px 0; max-width: 620px; }
.mh-sur { font-size: 15px; font-weight: 600; color: var(--mh-or); margin: 0 0 18px; letter-spacing: .2px; }
.mh .mh-titre {
  font-family: 'DM Serif Display', Georgia, serif; font-weight: 400; color: #fff;
  font-size: clamp(40px, 4.4vw, 70px); line-height: 1.04; letter-spacing: -.012em; margin: 0 0 24px;
}
.mh .mh-titre em { font-style: italic; color: var(--mh-or); }
.mh-sous { font-size: 18px; line-height: 1.65; color: rgba(226,232,240,.74); max-width: 33em; margin: 0 0 34px; }
.mh-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; margin-bottom: 44px; }
.mh .mh-cta {
  display: inline-flex; align-items: center; padding: 17px 30px; border-radius: 12px;
  background: linear-gradient(135deg, #f59e0b, #d97706); color: #fff; font-size: 16px; font-weight: 700;
  box-shadow: 0 14px 34px rgba(245,158,11,.28); transition: transform .2s, box-shadow .2s;
}
.mh .mh-cta:hover { transform: translateY(-2px); box-shadow: 0 18px 42px rgba(245,158,11,.38); }
.mh .mh-lien { color: #fff; font-size: 16px; font-weight: 600; padding: 6px 0;
  background: linear-gradient(var(--mh-or), var(--mh-or)) 0 100% / 100% 1px no-repeat; transition: color .2s; }
.mh .mh-lien:hover { color: var(--mh-or); }
.mh a:focus-visible { outline: 2px solid #00d4ff; outline-offset: 4px; border-radius: 6px; }
.mh-faits { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin: 0 0 30px; padding: 0; }
.mh-faits li { border-top: 1px solid rgba(245,158,11,.45); padding-top: 14px; }
.mh-faits b { display: block; color: #fff; font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.mh-faits li > span { display: block; color: rgba(226,232,240,.55); font-size: 13.5px; line-height: 1.5; }
.mh .mh-gratuit { color: #10b981; font-size: 14.5px; font-weight: 600; }
.mh .mh-gratuit:hover { text-decoration: underline; }

/* Étincelles dorées (canvas) : au-dessus de la photo, sous le texte et la revue de code */
.mh-etincelles { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 2; pointer-events: none; }

/* La scène : photo pleine hauteur qui touche le bord droit de l'écran */
.mh-scene { position: relative; align-self: stretch; padding: 22px 0; }
.mh-photo { position: relative; height: 100%; min-height: 560px; margin: 0; border-radius: 28px 0 0 28px; overflow: hidden;
  box-shadow: -30px 30px 80px rgba(0,0,0,.45); }
.mh-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 22% 0; transform-origin: 30% 0; }
.mh-photo::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(10,10,20,.55), transparent 28%), linear-gradient(0deg, rgba(10,10,20,.55), transparent 35%);
  box-shadow: inset 1px 0 0 rgba(245,158,11,.5); border-radius: inherit; }

/* La revue de code, posée à cheval entre le texte et la photo */
.mh-code {
  position: absolute; z-index: 4; left: -84px; bottom: 9%; width: min(470px, 84%);
  background: rgba(17,17,37,.94); border: 1px solid rgba(255,255,255,.09); border-radius: 16px;
  box-shadow: 0 30px 70px rgba(0,0,0,.55), 0 0 0 1px rgba(0,0,0,.4);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  font-size: 13px; color: var(--mh-texte); transform-style: preserve-3d;
}
.mh-code-tete { display: flex; align-items: center; gap: 6px; padding: 12px 16px; border-bottom: 1px solid rgba(255,255,255,.07); }
.mh-code-tete i { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,.16); }
.mh-code-tete span { margin-left: 10px; font-family: ui-monospace, 'Cascadia Code', Consolas, monospace; font-size: 12px; color: rgba(226,232,240,.7); }
.mh-code-tete em { margin-left: auto; font-style: normal; font-size: 11.5px; color: var(--mh-or); }
.mh-code-corps { margin: 0; padding: 14px 0 10px; font-family: ui-monospace, 'Cascadia Code', Consolas, monospace; font-size: 12.5px; line-height: 1.9;
  white-space: normal; overflow: hidden; }
.mh-code-corps code { font: inherit; }
.mh-l { display: block; white-space: pre; padding: 0 16px 0 12px; border-left: 2px solid transparent; position: relative; }
.mh-l b { display: inline-block; width: 26px; color: rgba(226,232,240,.3); font-weight: 400; }
.mh-l s { text-decoration: none; color: #00d4ff; }
.mh-cible { background: linear-gradient(90deg, rgba(245,158,11,.14), rgba(245,158,11,.03)) 0 0 / var(--mh-surligne, 100%) 100% no-repeat;
  border-left-color: var(--mh-or); }
.mh-apres { color: #10b981; }
.mh-note { display: flex; gap: 12px; margin: 4px 16px 0; padding: 12px 14px; border-radius: 12px;
  background: rgba(245,158,11,.08); border: 1px solid rgba(245,158,11,.28); transform-origin: 20px 0; }
.mh-avatar { flex: none; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
  background: var(--mh-or); color: var(--mh-nuit); font-weight: 700; font-size: 13px; }
.mh-note p { margin: 0; font-size: 13px; line-height: 1.55; color: rgba(226,232,240,.85); }
.mh-note p b { display: block; color: #fff; font-size: 12.5px; margin-bottom: 2px; }
.mh-note code { font-family: ui-monospace, Consolas, monospace; color: #fff; font-size: 12px; }
.mh-ok { display: flex; align-items: center; gap: 8px; padding: 12px 16px 14px; font-size: 12.5px; font-weight: 600; color: #10b981; }
.mh-ok i { width: 16px; height: 16px; border-radius: 50%; background: #10b981; position: relative; flex: none; }
.mh-ok i::after { content: ""; position: absolute; left: 5px; top: 3px; width: 4px; height: 7px; border: solid var(--mh-nuit); border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* Ordinateurs moyens */
@media (max-width: 1180px) {
  .mh-texte { padding-right: 48px; }
  .mh-code { left: -48px; width: min(420px, 88%); }
  .mh-faits { grid-template-columns: 1fr 1fr; }
}

/* Tablettes et téléphones : le texte d'abord, puis la scène */
@media (max-width: 900px) {
  .mh { grid-template-columns: 1fr; padding: 0; min-height: 0; }
  .mh-texte { padding: 36px 20px 8px; max-width: none; }
  .mh .mh-titre { font-size: clamp(36px, 9.5vw, 48px); }
  .mh-sous { font-size: 17px; margin-bottom: 26px; }
  .mh-actions { margin-bottom: 32px; }
  .mh .mh-cta { width: 100%; justify-content: center; }
  .mh-faits { grid-template-columns: 1fr; gap: 14px; margin-bottom: 22px; }
  .mh-scene { padding: 28px 16px 40px; }
  .mh-photo { min-height: 0; height: auto; aspect-ratio: 4 / 3; border-radius: 20px; box-shadow: 0 24px 60px rgba(0,0,0,.45); }
  .mh-photo img { object-position: 28% 0; }
  .mh-code { position: relative; left: auto; bottom: auto; width: auto; margin: -64px 0 0 18px; }
  .mh-code-corps { font-size: 11.5px; }
  .mh-l { white-space: pre-wrap; }
}
