/* ========================================================================== */
/* ETHNOS R133 — profil : description affinée et éditeur latéral complet      */
/* Base : R132. Ce correctif ne touche ni la grille, ni Profil, ni Maps.       */
/* ========================================================================== */

/* La description accepte un texte long sans envahir visuellement le volet. */
html body .memberProfileDrawer > .memberDescription{
  font-size:clamp(13px,.82vw,16px) !important;
  line-height:1.48 !important;
  letter-spacing:.005em !important;
  white-space:pre-wrap !important;
  overflow-wrap:anywhere !important;
}

/* Bleu repris du fond du titre d'accueil « Bienvenue au cœur d'Ethnos ». */
html body .memberProfileDrawer .memberProfileBottomClose{
  border-color:#051b26 !important;
  background:#051b26 !important;
  color:#fffaf3 !important;
}
html body .memberProfileDrawer .memberProfileBottomClose:hover{
  background:#082634 !important;
}

/* -------------------------------------------------------------------------- */
/* Éditeur : calé dynamiquement sur le bord gauche du bloc d'accueil.          */
/* -------------------------------------------------------------------------- */
.memberProfileEditorDrawer[hidden]{display:none !important}
.memberProfileEditorDrawer{
  --profile-editor-left:clamp(225px,16vw,310px);
  position:fixed;
  inset:0;
  z-index:190;
  pointer-events:none;
}
.memberProfileEditorDrawer.isOpen{pointer-events:auto}
.memberProfileEditorBackdrop{
  position:absolute;
  inset:0;
  border:0;
  background:rgba(1,10,16,.38);
  opacity:0;
  transition:opacity .36s ease;
  backdrop-filter:blur(2px);
}
.memberProfileEditorDrawer.isOpen .memberProfileEditorBackdrop{opacity:1}
.memberProfileEditorPanel{
  position:absolute;
  top:var(--ethnos-card-height,132px);
  right:0;
  bottom:0;
  left:var(--profile-editor-left);
  min-width:0;
  display:grid;
  grid-template-rows:auto minmax(0,1fr);
  overflow:hidden;
  border-left:1px solid rgba(49,209,207,.35);
  background:#fff9f0;
  box-shadow:-24px 0 70px rgba(0,0,0,.34);
  transform:translate3d(100%,0,0);
  transition:transform .44s cubic-bezier(.22,.72,.18,1);
  will-change:transform;
}
.memberProfileEditorDrawer.isOpen .memberProfileEditorPanel{transform:translate3d(0,0,0)}

.memberProfileEditorHeader{
  position:relative;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:22px;
  align-items:start;
  padding:24px clamp(28px,3.2vw,62px) 22px;
  border-bottom:1px solid rgba(49,209,207,.23);
  background:linear-gradient(112deg,#041520,#082634);
  color:#fffaf3;
}
.memberProfileEditorHeader>div>span{
  display:block;
  margin-bottom:7px;
  color:#31d1cf;
  font-size:10px;
  font-weight:800;
  letter-spacing:.18em;
}
.memberProfileEditorHeader h2{
  margin:0;
  color:#fffaf3;
  font-family:var(--ethnos-official-title,var(--font-title,Georgia,serif));
  font-size:clamp(30px,2.35vw,46px);
  font-weight:400;
  line-height:1.02;
}
.memberProfileEditorHeader p{
  max-width:850px;
  margin:10px 0 0;
  color:#a9bdc3;
  font-size:clamp(12px,.78vw,15px);
  line-height:1.5;
}
.memberProfileEditorClose{
  width:44px;
  height:44px;
  display:grid;
  place-items:center;
  border:1px solid rgba(255,255,255,.2);
  border-radius:50%;
  background:rgba(255,255,255,.06);
  color:#fffaf3;
  font:400 29px/1 Arial,sans-serif;
}
.memberProfileEditorClose:hover{border-color:#f58a4b;background:rgba(245,138,75,.12)}

.memberProfileEditorForm{
  min-height:0;
  display:grid;
  grid-template-rows:minmax(0,1fr) auto;
}
.memberProfileEditorScroll{
  min-height:0;
  overflow-y:auto;
  padding:22px clamp(28px,3.2vw,62px) 30px;
  scrollbar-width:thin;
  scrollbar-color:rgba(5,27,38,.28) transparent;
}
.memberProfileEditCard{
  margin:0 0 14px;
  padding:20px;
  border:1px solid rgba(5,27,38,.11);
  border-radius:16px;
  background:rgba(255,255,255,.72);
  box-shadow:0 10px 26px rgba(5,27,38,.055);
}
.memberProfileEditCard:nth-child(2){background:#f5faf8}
.memberProfileEditCard:nth-child(3){background:#fff4e7}
.memberProfileEditCard:nth-child(4){background:#f3f7f9}
.memberProfileEditCard>header{
  display:grid;
  grid-template-columns:38px minmax(0,1fr);
  gap:12px;
  align-items:start;
  margin-bottom:17px;
}
.memberProfileEditCard>header>span{
  display:grid;
  place-items:center;
  width:34px;
  height:34px;
  border-radius:50%;
  background:#051b26;
  color:#31d1cf;
  font-size:10px;
  font-weight:800;
  letter-spacing:.05em;
}
.memberProfileEditCard h3{
  margin:0;
  color:#071a39;
  font-family:var(--ethnos-official-title,var(--font-title,Georgia,serif));
  font-size:clamp(20px,1.35vw,27px);
  font-weight:600;
}
.memberProfileEditCard header p{
  margin:4px 0 0;
  color:#6a7a88;
  font-size:12px;
  line-height:1.4;
}
.memberProfileEditGrid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:15px;
}
.memberProfileEditGridIdentity{grid-template-columns:minmax(170px,.32fr) minmax(0,1fr)}
.memberProfileIdentityFields{display:grid;gap:15px}
.memberProfileEditCard label{display:grid;gap:7px;min-width:0;color:#071a39}
.memberProfileEditCard label>span:first-child{
  color:#355367;
  font-size:10px;
  font-weight:800;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.memberProfileEditCard input:not([type="checkbox"]),
.memberProfileEditCard select,
.memberProfileEditCard textarea{
  width:100%;
  box-sizing:border-box;
  border:1px solid rgba(5,27,38,.18);
  border-radius:10px;
  background:#fffdf9;
  color:#071a39;
  font-family:var(--ethnos-official-title,Arial,sans-serif);
  font-size:14px;
  outline:none;
  transition:border-color .18s ease,box-shadow .18s ease,background .18s ease;
}
.memberProfileEditCard input:not([type="checkbox"]),
.memberProfileEditCard select{height:45px;padding:0 13px}
.memberProfileEditCard textarea{min-height:92px;padding:12px 13px;line-height:1.5;resize:vertical}
.memberProfileEditCard input:focus,
.memberProfileEditCard select:focus,
.memberProfileEditCard textarea:focus{
  border-color:#31d1cf;
  box-shadow:0 0 0 3px rgba(49,209,207,.13);
  background:#fff;
}
.memberProfileEditCard input:disabled{
  background:#edf1f2;
  color:#75848c;
  cursor:not-allowed;
}
.memberProfileEditCard small{
  color:#75838c;
  font-size:10px;
  line-height:1.35;
}
.memberProfileEditCard small b{color:#f26722}
.memberProfileEmailField{grid-column:1/-1}

.memberProfilePhotoField{align-content:start}
.memberProfilePhotoPreview{
  width:126px;
  aspect-ratio:1;
  display:grid;
  place-items:center;
  overflow:hidden;
  border:2px solid #f58a4b;
  border-radius:24px;
  background:#051b26;
  color:#fff;
  font-size:48px;
  box-shadow:0 10px 24px rgba(5,27,38,.14);
}
.memberProfilePhotoPreview img{width:100%;height:100%;object-fit:cover}
.memberProfilePhotoField input[type="file"]{
  height:auto !important;
  padding:9px !important;
  font-size:11px !important;
}

.memberProfileDangerZone{
  border-color:rgba(176,48,43,.25);
  background:#fff1ee !important;
}
.memberProfileDangerZone>header>span{background:#7d2421;color:#fff}
.memberProfileDangerZone h3{color:#7d2421}
.memberProfileDeleteOpen{
  min-height:44px;
  padding:0 18px;
  border:1px solid #a23a34;
  border-radius:10px;
  background:transparent;
  color:#8a2b27;
  font-weight:800;
}
.memberProfileDeleteOpen:hover{background:#8a2b27;color:#fff}
.memberProfileDeleteConfirm{
  margin-top:14px;
  padding:16px;
  border:1px solid rgba(138,43,39,.3);
  border-radius:12px;
  background:#fff;
}
.memberProfileDeleteConfirm[hidden]{display:none !important}
.memberProfileDeleteConfirm h4{margin:0;color:#7d2421;font-size:20px}
.memberProfileDeleteConfirm>p{margin:7px 0 13px;color:#6f5552;font-size:12px;line-height:1.45}
.memberProfileDeleteCheck{
  display:flex !important;
  grid-template-columns:none !important;
  flex-direction:row;
  align-items:flex-start;
  gap:9px !important;
  margin:0 0 14px;
}
.memberProfileDeleteCheck input{margin-top:2px}
.memberProfileDeleteCheck span{color:#573f3d !important;font-size:12px !important;font-weight:600 !important;letter-spacing:0 !important;text-transform:none !important}
.memberProfileDeleteConfirm>div{display:flex;gap:9px}
.memberProfileDeleteConfirm button{
  min-height:40px;
  padding:0 14px;
  border:1px solid rgba(5,27,38,.18);
  border-radius:9px;
  background:#fff;
  color:#071a39;
  font-weight:700;
}
.memberProfileDeleteConfirm [data-confirm-delete-account]{border-color:#8a2b27;background:#8a2b27;color:#fff}
.memberProfileDeleteConfirm [data-confirm-delete-account]:disabled{opacity:.4;cursor:not-allowed}

.memberProfileEditorFooter{
  display:grid;
  gap:8px;
  padding:14px clamp(28px,3.2vw,62px);
  border-top:1px solid rgba(5,27,38,.14);
  background:rgba(255,249,240,.97);
  box-shadow:0 -10px 30px rgba(5,27,38,.08);
}
.memberProfileEditorFooter>div{display:flex;justify-content:flex-end;gap:10px}
.memberProfileEditorFooter button{
  min-height:46px;
  padding:0 21px;
  border:1px solid rgba(5,27,38,.25);
  border-radius:10px;
  background:#fffdf9;
  color:#071a39;
  font-family:var(--ethnos-official-title,Arial,sans-serif);
  font-size:14px;
  font-weight:800;
}
.memberProfileEditorFooter [data-save-profile-editor]{
  border-color:#f26722;
  background:linear-gradient(180deg,#ff9854,#f27630);
  color:#071a39;
  box-shadow:0 8px 18px rgba(242,103,34,.18);
}
.memberProfileEditorFooter button:disabled{opacity:.55;cursor:wait}
.memberProfileFormError{margin:0;color:#a12e29;font-size:12px;font-weight:700}
.memberProfileFormError[hidden]{display:none !important}
body.hasProfileEditorOpen{overflow:hidden}

@media(max-width:1200px){
  .memberProfileEditorPanel{left:max(12px,var(--profile-editor-left))}
  .memberProfileEditGridIdentity{grid-template-columns:150px minmax(0,1fr)}
}
@media(max-width:900px){
  .memberProfileEditorPanel{top:0;left:0}
  .memberProfileEditorHeader{padding:18px 18px 16px}
  .memberProfileEditorScroll{padding:14px 14px 22px}
  .memberProfileEditorFooter{padding:12px 14px}
  .memberProfileEditGrid,
  .memberProfileEditGridIdentity{grid-template-columns:1fr}
  .memberProfilePhotoPreview{width:104px}
  .memberProfileEditorFooter>div{display:grid;grid-template-columns:1fr 1.35fr}
  .memberProfileEditorFooter button{padding:0 10px;font-size:12px}
}
