/* ============================================================
   Pa_Capona_Resume_Fin.css
   FEN_Pa_Capona_Resume_Fin
   ─────────────────────────────────────────────────────────
   Image de fond plein-écran : img/ResumeFinFond.jpg
   Zone de texte centrée (position:absolute) — fond #7F8CA0
   Barre bas absolue, transparente (photo visible en dessous)
   Navigation :
     IMG_Retour → Pa_Capona_27_Motus2.html
     IMG_Lien   → https://youtu.be/sFyTjOaa4CI (nouvel onglet)
============================================================ */

/* ============================================================
   RESET & BASE
============================================================ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  width: 100%;
  height: 100%;
  font-family: 'Helvetica Neue', Arial, sans-serif;
  background: #000;
}

/* ============================================================
   ECRAN PRINCIPAL — image de fond plein-écran
============================================================ */
.screen {
  width: 100%;
  height: 100dvh;
  position: relative;
  overflow: hidden;
  background: url('img/ResumeFinFond.jpg') center center / cover no-repeat;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  user-select: none;
  -webkit-user-select: none;
}

/* ============================================================
   ZONE TEXTE — centrée sur l'image, fond #7F8CA0
============================================================ */
.texte-zone {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 88%;
  max-width: 500px;
  max-height: 72dvh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  background: #7F8CA0;
  padding: 18px 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  cursor: auto;
}

.texte-zone::-webkit-scrollbar        { width: 3px; }
.texte-zone::-webkit-scrollbar-track  { background: transparent; }
.texte-zone::-webkit-scrollbar-thumb  { background: rgba(255,255,255,0.35); border-radius: 3px; }

.texte-principal {
  color: #ffffff;
  font-size: clamp(0.82rem, 3.3vw, 1.08rem);
  font-weight: 500;
  line-height: 1.55;
  text-align: left;
}

/* Lien YouTube */
.lien-yt {
  color: #a8d8f0;
  font-size: clamp(0.80rem, 3.1vw, 1.05rem);
  font-weight: 600;
  text-decoration: underline;
  word-break: break-all;
  cursor: pointer;
}
.lien-yt:active { opacity: 0.75; }

/* ============================================================
   BARRE BAS — absolue, transparente
   retour (gauche) | coffre+score (droite) — PAS de lézard
============================================================ */
.bas-zone {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding: 6px 12px 8px;
  background: transparent;
}

.retour-img {
  height: clamp(36px, 8vh, 64px);
  width: auto;
  display: block;
  cursor: pointer;
  -webkit-user-drag: none;
  transition: transform 0.12s ease;
}
.retour-img:active { transform: scale(0.90); }

.score-zone {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
}

.coffre-img {
  height: clamp(28px, 6vh, 48px);
  width: auto;
  display: block;
  -webkit-user-drag: none;
}

.points-box {
  background: #cc0000;
  color: #ffffff;
  font-weight: 700;
  font-size: clamp(0.80rem, 2.8vw, 1.1rem);
  min-width: clamp(32px, 9vw, 58px);
  padding: 3px 6px;
  border-radius: 5px;
  text-align: center;
  line-height: 1.2;
  border: 2px solid #cc0000;
}

/* ============================================================
   OVERLAY DE TRANSITION (fondu noir)
============================================================ */
.transition-overlay {
  position: fixed;
  inset: 0;
  background: #000000;
  z-index: 100;
  opacity: 1;
  pointer-events: all;
  transition: opacity 0.4s ease;
}

/* ============================================================
   RESPONSIVE — PORTRAIT ÉTROIT (≤ 360px)
============================================================ */
@media (max-width: 360px) {
  .texte-principal { font-size: 0.8rem; }
  .lien-yt         { font-size: 0.8rem; }
  .texte-zone      { padding: 12px 14px 10px; gap: 8px; max-height: 68dvh; }
  .coffre-img      { height: 22px; }
  .points-box      { font-size: 0.68rem; min-width: 26px; }
  .retour-img      { height: 28px; }
}

/* ============================================================
   RESPONSIVE — TABLETTE (>= 600px)
============================================================ */
@media (min-width: 600px) {
  .texte-zone      { width: 78%; max-width: 580px; padding: 24px 28px 20px; gap: 16px; }
  .texte-principal { font-size: clamp(1.00rem, 2.6vw, 1.45rem); }
  .lien-yt         { font-size: clamp(0.96rem, 2.5vw, 1.40rem); }
  .coffre-img      { height: clamp(34px, 6vh, 54px); }
  .retour-img      { height: clamp(44px, 8vh, 70px); }
}

/* ============================================================
   RESPONSIVE — iPad 6 (768-1023px, 900-1199px)
============================================================ */
@media (min-width: 768px) and (max-width: 1023px) and (min-height: 900px) and (max-height: 1199px) {
  .texte-principal { font-size: clamp(1.0rem, 2.4vw, 1.40rem); }
  .texte-zone      { max-height: 68dvh; }
}

/* ============================================================
   RESPONSIVE — Galaxy Tab A8 + iPad Pro (>= 768px, >= 1200px)
============================================================ */
@media (min-width: 768px) and (min-height: 1200px) {
  .texte-principal { font-size: clamp(1.05rem, 2.6vw, 1.65rem); }
  .texte-zone      { max-height: 65dvh; }
}

/* ============================================================
   RESPONSIVE — PAYSAGE MOBILE (hauteur ≤ 430px)
============================================================ */
@media (max-height: 430px) and (orientation: landscape) {
  .texte-zone      { max-height: 60dvh; padding: 8px 14px 6px; gap: 6px;
                     top: 46%; width: 70%; }
  .texte-principal { font-size: 0.55rem; line-height: 1.3; }
  .lien-yt         { font-size: 0.53rem; }
  .bas-zone        { padding: 2px 10px 3px; }
  .coffre-img      { height: 18px; }
  .points-box      { font-size: 0.58rem; min-width: 20px; padding: 1px 3px; }
  .retour-img      { height: 22px; }
}
