/*
Theme Name: Hello elementor child
Template: hello-elementor
*/
html, body {
  min-height: 100vh;
}


button,
[type=submit],
[type=button] {
  display: inline-block;
  font-weight: 400;
  color: #EA9D82;
  text-align: center;
  white-space: nowrap;
  user-select: none;
  background-color: transparent;
  border: 1px solid #EA9D82;
  padding: 0.5rem 1rem;
  font-size: 1rem;
  transition: all 0.3s;
}
button:hover, button:focus,
[type=submit]:hover,
[type=submit]:focus,
[type=button]:hover,
[type=button]:focus {
  color: #ffffff;
  background-color: #EA9D82;
  text-decoration: none;
}
a {
  background-color: transparent;
  text-decoration: none;
  color: #EA9D82;
}
/* 🎨 Écran de chargement */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: black; /* Fond blanc */
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    font-size: 18px;
    font-weight: bold;
    color: white; /* Rouge Joylink */
    z-index: 9999;
}


#joylink-activation-page { 
  min-height: 100vh;
  min-height: calc(var(--vh, 1vh) * 100);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;

}


/* 🌀 Effet pulsatile du texte */
.loading-text, .loading-logo {
    animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
    0% { transform: scale(1); opacity: 0.8; }
    30% { transform: scale(1.2); opacity: 1; }
    60% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1); opacity: 0.8; }
}

/* 🖼️ Logo */
.loading-logo {
    width: 80px; /* Ajuste la taille selon ton logo */
    height: auto;
    margin-bottom: 15px;
}




.tp-mobile-menu .tp-mm-li i,
.tp-mm-c-wrapper i,
.tp-mm-et-wrapper .tp-mm-et-li i {
    color: #ffffff !important; /* Change la couleur des icônes en blanc */
}


/* Empêchez les débordements */
body, html {
    overflow-x: hidden;
}
@media (max-width: 768px) {
    .user-images-gallery {
        max-width: 100%; /* Permet au carousel de s'étendre sur toute la largeur */
    }

    .user-images-gallery .swiper-slide {
        width: 100%; /* Une seule image visible par slide sur mobile */
    }
}




.popup-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: rgba(0, 0, 0, 0.8);
  z-index: 99999;
  display: none; /* on garde le contrôle via JS */
  display: flex;
  align-items: center;
  justify-content: center;
}

.popup-content {
  background: white;
  padding: 20px;
  border-radius: 10px;
  width: 90%;
  max-width: 500px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  position: relative;
}



#canvasElement {
    cursor: pointer;
}


.no-media-message{
	text-align:center;
}



/* Ultimate Member - Style des boutons */
.um-button, 
.um-button:hover, 
.um-button:focus, 
.um-button:active {
    background-color: black !important; /* Remplacez #ff5722 par votre couleur */
    border-color: black !important;   /* Remplacez #ff5722 par votre couleur */
}

.um-button, 
.um-button:hover, 
.um-button:focus, 
.um-button:active {
    color: white !important; /* Remplacez #ffffff par votre couleur */
}

.um-button {
    border-radius: 5px !important; /* Ajustez selon vos préférences */
}
.um-account-meta{display:none !important;
}

/* Changer la couleur des liens (titres) dans le menu de profil */
body .um-account-nav a {
    color: #000000 !important; /* Change la couleur du texte en noir */
    text-decoration: none; /* Enlève le soulignement si présent */
}

/* Changer la couleur des icônes dans le menu de profil */
.um-account-nav i {
    color: #000000 !important; /* Change la couleur des icônes en noir */
}

/* Optionnel : Changer aussi les éléments <span> */
.um-account-nav span {
    color: #000000 !important; /* Change la couleur des spans en noir */
}

/* Optionnel : Ajuster l'apparence au survol */
.um-account-nav a:hover {
    color: #444444 !important; /* Couleur légèrement différente au survol */
}

.user-bijoux-list{
	font-size:14px;
}




/***********************************
 * MENU RADIAL - Début
 ***********************************/

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%; /* ✅ Barre pleine largeur */
  height: 70px;
  /*background: #fff;*/
  /*box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);*/
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0px 25px 0px;
  z-index: 999;
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
}

/* Boutons latéraux (centrés sur les côtés) */
.nav-btn {
  background: none;
  border: none;
  font-size: 13px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: black;
  flex: 1; /* ✅ Équilibre l'espace */
}
/* Style des icônes pour Profil et Ma Page */
.nav-btn i {
  font-size: 16px;  /* ✅ Taille de l'icône */
  color: black;     /* ✅ Couleur noire unie */
transition: color 0.3s ease; /* Transition douce */
}
/* ✅ Changement de couleur quand actif ou survolé */
.nav-btn.active i,
.nav-btn:focus i,
.nav-btn:hover i {
  color: #6c63ff; /* Couleur violette pour l'état actif */
}

.nav-btn span {
  font-size: 12px;
  color: black;
}
/* Pour le texte aussi si nécessaire */
.nav-btn.active span,
.nav-btn:focus span,
.nav-btn:hover span {
  color: #6c63ff;
}

/* Bouton central */
.central-btn {
  width: 70px;
  height: 70px;
  background: black;
  border: none;
  border-radius: 50%;
  color: white;
  font-size: 32px;
  cursor: pointer;
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Position des boutons latéraux */
.left-btn {
  justify-content: center;
  align-items: center; /* Centré sur le côté gauche */
}

.right-btn {
  justify-content: center;
  align-items: center; /* Centré sur le côté droit */
}

/* Icônes noirs */
.nav-btn i, .radial-item i {
  color: black; /* ✅ Icônes unies noires */
  font-size: 24px;
}
✅ 
/* Effet clic (shrink) */
.central-btn:active {
  transform: translateX(-50%) scale(0.95);
}

/* Le "+" à l’intérieur du bouton */
.plus-icon {
  display: inline-block;
  transition: transform 0.3s ease;
}

/* Quand le bouton central a la classe .active => le plus tourne à 45° */
.central-btn.active .plus-icon {
  transform: rotate(45deg);
}




/* ✅ Active les interactions uniquement lorsque le menu est ouvert */
#radial-menu.active {
  pointer-events: none;  /* ❗ Important : pointer-events désactivé sur le conteneur */
  opacity: 1;
}

/* ✅ Affiche correctement les boutons lorsque le menu est actif */
#radial-menu.active .radial-item {
  pointer-events: auto;  /* Active les interactions sur les boutons */
  transform: scale(1);
  opacity: 1;
}




#radial-menu.active .radial-item {
  transform: scale(1);
  opacity: 1;
}

.radial-item,
#radial-menu {
  display: none !important;
  visibility: hidden !important;
}



/***********************************
 * MENU RADIAL - Fin
 ***********************************/


/* ============================
   JOYLINK MASONRY GRID
============================= */

.joylink-masonry-grid {
  display: block; /* important pour Masonry.js */
  margin: 0 auto;
  font-size: 0; /* évite les sauts de ligne fantômes */
  width: 100%;
}

.joylink-masonry-item {
  width: calc(50% - 8px);
  margin-bottom: 16px;
  box-sizing: border-box;
  display: inline-block;
  vertical-align: top;
  position: relative;
  border-radius: 16px; /* même arrondi que tes spectres audio */
    overflow: hidden; /* évite que les images/vidéos débordent du cadre */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15); /* même ombre que tes audios */
    background: #ffffff; /* (optionnel) couleur de fond neutre */
    transition: all 0.3s ease; /* transition douce au hover */
}

/* Cas où il n'y a qu'un seul média */
.joylink-masonry-grid.single-media {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start; /* ou center si tu veux verticalement aussi */
}



/* 🎯 Plusieurs médias ➔ 2 colonnes */
.joylink-masonry-grid.multi-media .joylink-masonry-item {
  width: calc(50% - 8px);
}

/* 🎯 Mobile : conserver 2 colonnes même sur petit écran */
@media (max-width: 768px) {
  .joylink-masonry-grid.multi-media .joylink-masonry-item {
    width: calc(50% - 8px);
  }
  .joylink-masonry-grid.single-media .joylink-masonry-item {
    width: 100%;
  }
}


/* Images et vidéos */
.joylink-masonry-item img,
.joylink-masonry-item video {
  width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
  border-radius: 0;
}


/* Vidéos non prêtes (affiche fond noir) */
.joylink-masonry-item video:not([data-ready="true"]) {
  min-height: 200px;
  background-color: #000;
}
/* ✅ Ajustement propre pour vidéo unique */
.joylink-masonry-grid.single-media .joylink-masonry-item video {
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
  max-height: calc(100vh - 140px); /* évite chevauchement sans créer de vide */
  margin-bottom: 0; /* ❌ enlève l'espace trop grand */
  position: relative;
  z-index: 1;
}


/* Lien sur la vidéo (important pour la lightbox) */
.joylink-masonry-item a .joylink-video-link {
  display: block;
  width: 100%;
  height: 100%;
}


/* audio card */
.audio-card-premium {
  background: #111;
  border-radius: 20px;
  color: #fff;
  padding: 18px;
  text-align: center;
  min-height: 280px;
  max-height: 320px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  box-shadow: 0 8px 24px rgba(0,0,0,0.6);
  transition: transform 0.3s ease;
}

.audio-card-premium:hover {
  transform: translateY(-5px);
}

.audio-header {
  font-size: 13px;
  font-weight: bold;
  margin-bottom: 10px;
}

.waveform {
  width: 100%;
  height: 80px;
  margin: 15px 0;
}

.custom-play-btn {
    background: transparent;
    border: 2px solid white;
    border-radius: 50%; /* ➔ rend le bouton rond */
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.custom-play-btn i {
    font-size: 24px;
    color: white;
    transition: color 0.3s ease;
}

/* Lorsqu'on survole */
.custom-play-btn:hover {
    background: white;
}

.custom-play-btn:hover i {
    color: black;
}

/* Lorsqu'on clique sur Play ➔ changement manuel (ajout d'une classe "playing") */
.custom-play-btn.playing {
    background: white;
}

.custom-play-btn.playing i {
    color: black;
}

.audio-times {
    margin: 5px 0;
    font-size: 14px;
    color: white;
    display: flex;
    justify-content: center;
    gap: 5px;
    font-family: 'Poppins', sans-serif;
}



/* Placeholder pour chargement */
.joylink-masonry-item.placeholder {
  height: 180px;
  background: linear-gradient(100deg, #eee 30%, #ddd 50%, #eee 70%);
  background-size: 400% 100%;
  animation: loadingShimmer 1.2s infinite;
  border-radius: 10px;
  margin-bottom: 16px;
}

@keyframes loadingShimmer {
  0% { background-position: -400px 0; }
  100% { background-position: 400px 0; }
}

/* Bouton supprimer */
.delete-media-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(255, 0, 0, 0.8);
  color: white;
  border: none;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
  display: none;
  z-index: 10;
}

.joylink-masonry-item:hover .delete-media-btn {
  display: inline-block;
}




/* JOYLINK STORAGE */

.joylink-storage-wrapper {
  margin: 20px 0;
  width: 100%;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.joylink-storage-bar {
  height: 16px;
  background: #e0e0e0;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}

.joylink-storage-bar .fill {
  height: 100%;
  width: 0%;
  background-color: #4caf50;
  transition: width 200ms ease, background-color 200ms ease;
}

.joylink-storage-bar .fill.is-green  { background:#2ecc71; } /* vert  */
.joylink-storage-bar .fill.is-orange { background:#f39c12; } /* orange */
.joylink-storage-bar .fill.is-red    { background:#e74c3c; } /* rouge */
.joylink-storage-bar .fill.is-error  { background:#bdc3c7; } /* gris si erreur */

.joylink-storage-info {
  text-align: center;
  margin-top: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #333;
}



#video-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
}

#video-modal-content {
    position: relative;
    text-align: center;
}

#video-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    font-size: 30px;
    color: white;
    cursor: pointer;
}


.firstname {
	Font-size:15px;
}



.joylink-button {
  background-color: black;
  color: white;
  font-size: 16px;
  font-weight: bold;
  padding: 14px 30px;
  border: none;
  border-radius: 40px;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.2);
  transition: all 0.2s ease;
  cursor: pointer;
  width: 80%;
  max-width: 250px;
}

.joylink-button:hover {
  box-shadow: 0 0 18px rgba(255, 255, 255, 0.3);
  transform: scale(1.03);
}

/* ALERTE M4A */

.jl-audio-notice{
  display:flex; gap:.5rem; align-items:center;
  margin:.5rem 0 0; padding:.6rem .8rem;
  background:#fff6f1; border:1px solid #ffd6c8; border-radius:8px;
  font-size:.92rem; color:#5b341f;
}
.jl-audio-notice .jl-i{
  width:1.1rem; height:1.1rem; line-height:1.1rem;
  display:inline-block; text-align:center; border-radius:50%;
  border:1px solid currentColor; font-weight:700; font-size:.85rem;
}


/* Icône crayon */
.rename-bijou-icon {
    border: none;
    background: transparent;
    padding: 4px;
    margin-left: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.rename-bijou-svg {
    width: 18px;
    height: 18px;
    fill: #222; /* tu peux adapter à ta charte */
}

.rename-bijou-icon:hover {
    background: rgba(0,0,0,0.04);
    transform: translateY(-1px);
}

/* Modal overlay */
.jl-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* Carte centrale */
.jl-modal {
    background: #fff;
    border-radius: 20px;
    padding: 24px 22px 20px;
    max-width: 420px;
    width: 90%;
    box-shadow: 0 18px 45px rgba(0,0,0,0.18);
    position: relative;
    font-family: inherit;
}

.jl-modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    border: none;
    background: transparent;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.jl-modal-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 6px;
}

.jl-modal-subtitle {
    font-size: 14px;
    color: #666;
    margin: 0 0 16px;
}

.jl-modal-input {
    width: 100%;
    border-radius: 999px;
    border: 1px solid #ddd;
    padding: 10px 14px;
    font-size: 14px;
    outline: none;
}

.jl-modal-input:focus {
    border-color: #ea9d82; /* couleur Joylink */
    box-shadow: 0 0 0 2px rgba(234,157,130,0.2);
}

.jl-modal-helper {
    font-size: 12px;
    color: #999;
    margin-top: 6px;
}

.jl-modal-error {
    margin-top: 10px;
    font-size: 13px;
    color: #c0392b;
}

/* Boutons */
.jl-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.jl-btn {
    border-radius: 999px;
    padding: 8px 18px;
    font-size: 14px;
    cursor: pointer;
    border: none;
    transition: background 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease;
}

.jl-btn-primary {
    background: #ea9d82;
    color: #fff;
    box-shadow: 0 8px 18px rgba(234,157,130,0.4);
}

.jl-btn-primary:hover {
    background: #e28765;
}

.jl-btn-ghost {
    background: #f5f5f5;
    color: #333;
}

.jl-btn-ghost:hover {
    background: #ebebeb;
}



.user-bijou-item.is-current-bijou .bijou-main-line {
    background: #fff7f3;
    border-radius: 999px;
    background-color: #fff6f1;
     padding-inline: 8px;
}

/* == Joylink – Liste des bijoux / boutons actions == */
.user-bijou-item .bijou-main-line {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.user-bijou-item .delete-bijou {
    border: none;
    background: none;
    padding: 0;
    margin-left: 6px;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.user-bijou-item .delete-bijou-svg {
    width: 16px;
    height: 16px;
    display: inline-block;
    fill: #444;          /* couleur par défaut */
    vertical-align: middle;
}

.user-bijou-item .delete-bijou:hover .delete-bijou-svg {
    fill: #c0392b;       /* rouge au survol */
}
.user-bijoux-list {
  list-style: disc;
  padding-left: 1.5rem;
}

.user-bijou-item {
  margin: 0.2rem 0;
}

.user-bijou-item.is-current-bijou .bijou-main-line {
  font-weight: 600;
}

.user-bijou-item.is-current-bijou .bijou-label {
  text-decoration: underline;
}

.joylink-media-filters {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.joylink-filter-btn {
    border: 1px solid #ddd;
    border-radius: 999px;
    padding: 6px 14px;
    background: #fff;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.joylink-filter-btn:hover {
    border-color: #ea9d82;
    color: #ea9d82;
}



.joylink-filter-btn.is-active {
    background: #000;
    color: #fff;
    border-color: #000;
    box-shadow: 0 4px 10px rgba(0,0,0,0.18);
    font-weight: 600;
}

.joylink-media-filters {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.joylink-filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    border: 1px solid #e2e2e2;
    padding: 6px 14px;
    background: #fff;
    font-size: 13px;
    line-height: 1;
    cursor: pointer;
    transition: all 0.18s ease-out;
    box-shadow: 0 0 0 transparent;
    color: #111;
}

.joylink-filter-icon {
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.joylink-filter-btn:hover:not(.is-active) {
    border-color: #111;
}



.joylink-filter-btn.is-active .joylink-filter-icon {
    color: #fff;
}


.joylink-media-modal.is-open {
  display: flex;
}



.joylink-media-modal-dialog {
  position: relative;
  background: #fff;
  border-radius: 18px;
  max-width: 960px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 2;
}



.joylink-media-modal-media img,
.joylink-media-modal-media video {
  max-width: 100%;
  max-height: 60vh;
  border-radius: 14px;
}





.joylink-modal-audio p {
  margin: 0 0 10px;
  font-size: 0.95rem;
}

.joylink-modal-audio-player {
  width: 100%;
}





/* ======================
   JOYLINK MEDIA MODAL
====================== */

.jlm-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 999999;
  display: none;
  justify-content: center;
  align-items: center;
}

.jlm-modal.is-open {
  display: flex;
}

.jlm-overlay {
  position: absolute;
  inset: 0;
}

.jlm-dialog {
  position: relative;
  width: 100%;
  height: 100%;
  max-width: 480px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}

/* HEADER */
.jlm-header {
  display: flex;
  justify-content: space-between;
  padding: 18px;
  z-index: 10;
}

.jlm-back-btn,
.jlm-options-btn {
  background: rgba(255,255,255,0.15);
  border: none;
  padding: 10px 12px;
  border-radius: 12px;
  color: white;
  font-size: 20px;
}

.jlm-media-wrapper {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 10px;
}

#jlm-media img,
#jlm-media video {
  max-width: 100%;
  max-height: 70vh;
  border-radius: 12px;
}

/* CAPTION */

.jlm-caption {
  flex: 1;
  margin: 0;
  font-size: 16px;
  color: #222;
  line-height: 1.4;
}

.jlm-caption-edit-btn {
  border: none;
  background: transparent;
  font-size: 18px;
  color: #555;
}

/* ======================
   BOTTOM SHEET
====================== */

.jlm-sheet {
  position: absolute;
  bottom: -300px;
  left: 0; right: 0;
  background: #fff;
  padding: 20px;
  border-radius: 18px 18px 0 0;
  box-shadow: 0 -6px 20px rgba(0,0,0,0.25);
  transition: bottom 0.25s ease;
}

.jlm-sheet.open {
  bottom: 0;
}

.jlm-sheet-handle {
  width: 50px;
  height: 6px;
  background: #ccc;
  border-radius: 99px;
  margin: 0 auto 15px;
}

.jlm-sheet-delete {
  width: 100%;
  text-align: left;
  border: none;
  background: transparent;
  color: #b81414;
  font-size: 16px;
  padding: 12px;
}

.jlm-sheet-info {
  padding: 12px;
  font-size: 15px;
}

.jlm-sheet-close {
  margin-top: 15px;
  width: 100%;
  padding: 12px;
  border: none;
  background: #000;
  color: #fff;
  border-radius: 12px;
  font-size: 16px;
}


/* Joylink – on cache le bouton de suppression sur les cartes de la grille */
.joylink-masonry-grid .delete-media-btn {
  display: none !important;
  pointer-events: none !important;
}
/* Toute la carte média est cliquable, logique sur mobile */
.joylink-masonry-item {
  cursor: pointer;
}

/* ─────────────────────────────────────
   Joylink – Ajustements modale média
   ───────────────────────────────────── */

/* La modale occupe tout l'écran, mais on aligne le contenu en haut */
.jlm-modal {
  display: none; /* gardé, mais surchargé par le JS en display:flex */
  align-items: flex-start;
  justify-content: center;
  padding: 16px 12px;
  box-sizing: border-box;
}

/* Le "cadre" blanc principal */
.jlm-dialog {
  max-width: 420px;
  width: 100%;
  background: #000; /* ou la couleur que tu utilises déjà */
  border-radius: 18px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 32px);
}

/* Le bloc média prend la place principale */
.jlm-media-wrapper {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Légende immédiatement sous le média, toujours visible */

/* Texte de légende */
.jlm-caption {
  font-size: 0.95rem;
  line-height: 1.4;
}

/* Bouton ✎ bien visible à côté/à droite */
.jlm-caption-edit-btn {
  margin-left: 8px;
}

/* ─────────────────────────────────────
   Joylink – Ajustements modale média v2
   (à coller tout en bas du CSS enfant)
   ───────────────────────────────────── */

/* La modale reste sur overlay noir, mais contenu aligné en haut */
.jlm-modal.is-open {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 16px 12px;
  box-sizing: border-box;
}

/* Le "cadre" de la modale */
.jlm-dialog {
  max-width: 420px;
  width: 100%;
  background: #000;
  border-radius: 18px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 32px);
}

/* Zone média : centrée, sans chevauchement */
.jlm-media-wrapper {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 10px 6px;
  overflow: hidden;
}

/* Hauteur max vidéo/image réduite pour laisser place à la légende + commandes */
#jlm-media img,
#jlm-media video {
  max-width: 100%;
  max-height: 60vh;
  border-radius: 12px;
}

/* Écrans bas (iPhone petit / barre Safari visible) → un peu moins haut */
@media (max-height: 700px) {
  #jlm-media img,
  #jlm-media video {
    max-height: 55vh;
  }
}

/* Légende : carte blanche séparée, toujours visible, safe-area friendly */
.jlm-caption-block {
  background: #ffffff;
  color: #222;
  border-radius: 18px 18px 0 0;
  border-top: 1px solid rgba(0,0,0,0.04);
  box-shadow: 0 -6px 20px rgba(0,0,0,0.35);
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  cursor: pointer;
  padding: 8px 8px;
}

.jlm-caption {
  flex: 1;
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.4;
}

.jlm-caption-edit-btn {
  margin-left: 8px;
  border: none;
  background: transparent;
  font-size: 18px;
  color: #555;
}

/* Placeholder visuel quand il n'y a pas encore de légende */
.jlm-caption-empty {
  opacity: 0.65;
  font-style: italic;
}

/* Bloc d'édition de légende */
.jlm-caption-editor {
  margin-top: 10px;
  width: 100%;
}

#jlm-caption-input {
  width: 100%;
  min-height: 70px;
  max-height: 120px;
  resize: vertical;
  border-radius: 12px;
  border: 1px solid #ddd;
  padding: 8px 10px;
  font-size: 0.9rem;
  box-sizing: border-box;
}

.jlm-caption-editor-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 8px;
}

.jlm-caption-editor-actions .jlm-caption-cancel,
.jlm-caption-editor-actions .jlm-caption-save {
  border-radius: 999px;
  border: none;
  padding: 6px 14px;
  font-size: 0.85rem;
  cursor: pointer;
}

.jlm-caption-editor-actions .jlm-caption-cancel {
  background: #f1f1f1;
  color: #333;
}

.jlm-caption-editor-actions .jlm-caption-save {
  background: #ea9d82;
  color: #fff;
  box-shadow: 0 4px 10px rgba(234,157,130,0.45);
}

.jlm-caption-help {
  margin: 6px 0 0;
  font-size: 0.75rem;
  color: #777;
}

.jlm-caption-error {
  margin-top: 6px;
  font-size: 0.8rem;
  color: #d32f2f;
}



.jlm-caption-empty {
  color: #bbb;
  font-style: italic;
}


