/* Account controls live inside Mon espace; the application frame stays fixed. */
#overliveAccountPanel {
  flex: 0 0 auto;
  min-width: 0;
  margin: 0 0 18px;
  padding: clamp(16px, 3vw, 24px);
  border: 1px solid #ff8a3655;
  border-radius: 22px;
  background: radial-gradient(ellipse at top right, #a23b1626, transparent 70%), linear-gradient(140deg, #351b10f5, #20110df5);
  box-shadow: inset 0 1px #ffbe8520;
  color: #ffdbbd;
}
#overliveAccountPanel *, #overliveAccountPanel *::before, #overliveAccountPanel *::after { box-sizing: border-box; }
#overliveAccountPanel [hidden] { display: none !important; }
.account-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.account-heading .eyebrow { color: #f39751; }
.account-heading h2 { margin: 6px 0 0; font-size: clamp(21px, 3.5vw, 27px); letter-spacing: -.7px; color: #ffdfc1; }
.account-avatar { flex: 0 0 auto; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 17px; border: 1px solid #ffab5e66; background: linear-gradient(145deg, #ff9c2f, #e95824); color: #44200d; font-size: 18px; font-weight: 800; }
.account-avatar { overflow: hidden; }
.account-avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
#overliveAccountPanel .account-fallback-rose { object-fit: contain; padding: 9px; }
.account-description { margin: 13px 0; max-width: 600px; color: #dfa57b; font-size: 12px; line-height: 1.7; }
.account-status { min-height: 37px; margin: 0 0 16px; padding: 10px 12px; border-radius: 11px; border: 1px solid #e4873e2e; background: #4c281850; color: #efb384; font-size: 12px; line-height: 1.55; overflow-wrap: anywhere; }
.account-status[data-kind='error'] { color: #ffc0a7; border-color: #e9764d66; background: #5c241e70; }
.account-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; max-width: 570px; margin-bottom: 17px; padding: 5px; border: 1px solid #d57b3833; border-radius: 14px; background: #1b100b99; }
.account-tabs button { min-width: 0; min-height: 44px; padding: 9px; border: 1px solid transparent; border-radius: 10px; background: transparent; color: #df9c6d; font: inherit; font-size: 12px; font-weight: 700; }
.account-tabs button[aria-selected='true'] { color: #4c240e; background: #fff0df; border-color: #ffce9c; }
.account-form { display: grid; gap: 12px; width: 100%; max-width: 570px; margin: 0; }
#overliveAccountPanel .field { display: flex; flex-direction: column; gap: 7px; margin: 0; min-width: 0; color: #efb48b; font-size: 12px; }
#overliveAccountPanel input { display: block; min-width: 0; width: 100%; min-height: 46px; margin: 0; padding: 11px 12px; border: 1px solid #e4823d66; border-radius: 11px; background: #25140e; color: #ffdfc2; font: 16px/1.4 system-ui, sans-serif; }
#overliveAccountPanel input:autofill { box-shadow: 0 0 0 1000px #3c2114 inset; -webkit-text-fill-color: #ffdfc2; caret-color: #ffdfc2; }
.account-field-hint { margin: -6px 0 1px; color: #c58b63; font-size: 10px; line-height: 1.6; }
.account-remember-options { min-width: 0; margin: -3px 0 0; padding: 0; border: 0; }
.account-remember-options legend { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.account-remember-options label { display: flex; align-items: center; gap: 10px; min-height: 44px; color: #f4bc91; font-size: 12px; line-height: 1.5; cursor: pointer; }
#overliveAccountPanel .account-remember-options input[type='checkbox'] { display: block; flex: 0 0 19px; width: 19px; height: 19px; min-height: 19px; padding: 0; border-radius: 5px; accent-color: #ff8a32; }
.account-remember-options p { margin: 5px 0 0; color: #cb9169; font-size: 10px; line-height: 1.65; }
.account-connection-options summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; padding: 5px 0; color: #d79c72; font-size: 11px; cursor: pointer; list-style: none; }
.account-connection-options summary::-webkit-details-marker { display: none; }
.account-connection-options summary span { font-size: 17px; transition: transform .18s ease; }
.account-connection-options[open] summary span { transform: rotate(180deg); }
.account-connection-options summary:focus-visible { outline: 2px solid #ffb267; outline-offset: 3px; border-radius: 6px; }
.account-connection-options > div { padding: 0 10px 11px; border-left: 1px solid #e4823d44; }
#overliveAccountPanel .account-submit, #overliveAccountPanel #accountLogout { min-height: 46px; border: 1px solid #ffd1a5; border-radius: 12px; background: #fff0df; color: #4c240e; font: inherit; font-size: 13px; font-weight: 700; }
#overliveAccountPanel .account-submit { width: 100%; margin-top: 3px; }
#overliveAccountPanel #accountLogout { padding: 10px 18px; }
.account-identity { display: flex; flex-direction: column; gap: 5px; margin: 0 0 17px; overflow-wrap: anywhere; }
.account-identity strong { color: #ffbf83; font-size: 20px; }
.account-identity span { color: #c18a63; font-size: 12px; }
.account-profile-editor { width: 100%; max-width: 570px; margin-bottom: 12px; border: 1px solid #e4823d44; border-radius: 14px; background: #1c100c55; }
.account-profile-editor summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 46px; padding: 12px 14px; color: #ffd2a8; font-size: 12px; font-weight: 700; cursor: pointer; list-style: none; }
.account-profile-editor summary::-webkit-details-marker { display: none; }
.account-profile-editor summary span { font-size: 18px; transition: transform .18s ease; }
.account-profile-editor[open] summary span { transform: rotate(180deg); }
.account-profile-editor summary:focus-visible { outline: 2px solid #ffb267; outline-offset: 3px; border-radius: 12px; }
.account-profile-form { padding: 0 14px 14px; }
.account-password-row { position: relative; display: flex; align-items: stretch; min-width: 0; }
#overliveAccountPanel .account-password-row input { padding-right: 91px; }
#overliveAccountPanel .account-password-toggle { position: absolute; top: 1px; right: 1px; bottom: 1px; min-width: 80px; min-height: 44px; padding: 6px 9px; border: 0; border-radius: 9px; background: #603118; color: #ffd0a5; font-size: 11px; font-weight: 600; }
#overliveAccountPanel .account-password-toggle[aria-pressed='true'] { background: #8c441e; color: #ffe0be; }
.account-confirm-error { margin: -5px 0 0; color: #ffc0a7; font-size: 11px; line-height: 1.5; }
.account-security { margin: 0 14px 14px; padding-top: 14px; border-top: 1px solid #e4823d33; }
.account-security h3, .account-reset-panel h3, .account-recovery-code h3 { margin: 0 0 9px; color: #ffd3a9; font-size: 16px; }
.account-security p, .account-reset-panel > p, .account-recovery-code p { margin: 0 0 12px; color: #d59a73; font-size: 11px; line-height: 1.6; }
#overliveAccountPanel .account-text-button { display: inline-flex; align-items: center; min-height: 44px; margin: 4px 0 0; padding: 9px 2px; border: 0; border-radius: 8px; color: #ffc18d; background: transparent; font-size: 12px; text-decoration: underline; text-underline-offset: 3px; }
.account-reset-panel { max-width: 570px; }
.account-reset-panel .account-recovery-help { margin-top: 7px; color: #b8805c; font-size: 10px; }
.account-recovery-code { max-width: 570px; margin: 0 0 18px; padding: 15px; border: 1px solid #ffad5a99; border-radius: 15px; background: #65321588; }
.account-recovery-code code { display: block; padding: 12px; border: 1px dashed #efad69aa; border-radius: 10px; color: #fff0df; background: #27150d; font: 700 16px/1.7 ui-monospace, monospace; letter-spacing: 1px; overflow-wrap: anywhere; user-select: all; }
.account-recovery-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin-top: 11px; }
#overliveAccountPanel .account-recovery-actions button { min-width: 0; min-height: 44px; padding: 9px; border: 1px solid #ffc28b66; border-radius: 9px; background: #ffe9d2; color: #562713; font-size: 11px; font-weight: 700; }
#overliveAccountPanel #accountRecoveryDismiss { grid-column: 1 / -1; background: transparent; color: #ffd1a7; }
#overliveAccountPanel .account-visitor { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; max-width: 570px; min-height: 46px; margin-top: 15px; padding: 10px 14px; border: 1px solid #d0783c55; border-radius: 12px; background: #3b2013; color: #ffc18d; font-size: 12px; font-weight: 600; }
#overliveAccountPanel #accountLogout { min-height: 44px; padding: 9px 0; border-color: transparent; border-radius: 8px; background: transparent; color: #d99a73; font-size: 12px; }
.account-photo-editor { display: flex; align-items: center; gap: 13px; min-width: 0; }
.account-photo-editor .field { flex: 1 1 auto; }
.account-photo-preview { flex: 0 0 auto; display: grid; place-items: center; width: 76px; height: 76px; border: 1px solid #f5a06166; border-radius: 19px; overflow: hidden; background: #6f341a; color: #ffbc7c; font-size: 25px; font-weight: 700; }
.account-photo-preview img { display: block; width: 100%; height: 100%; object-fit: cover; }
#overliveAccountPanel input[type='file'] { padding: 7px; font-size: 11px; }
#overliveAccountPanel input[type='file']::file-selector-button { min-height: 30px; margin: 0 8px 0 0; padding: 5px 8px; border: 0; border-radius: 6px; background: #ffd7ac; color: #4c240e; font: inherit; font-weight: 700; }
.account-photo-remove { justify-self: start; min-height: 44px; border: 1px solid #c7713944; border-radius: 10px; padding: 8px 12px; background: #4b2617; color: #eeb083; font: inherit; font-size: 11px; }
#overliveAccountPanel :is(input, button):focus-visible { outline: 2px solid #ffb267; outline-offset: 3px; }
#overliveAccountPanel :is(input, button):disabled { cursor: wait; opacity: .65; }
@media (max-width: 500px) {
  #overliveAccountPanel { padding: 16px 14px; margin-bottom: 14px; border-radius: 19px; }
  .account-description, .account-status { font-size: 11px; }
  .account-avatar { width: 42px; height: 42px; border-radius: 14px; font-size: 16px; }
  .account-tabs button { font-size: 11px; }
}

.account-identity .account-app-role{display:inline-flex;align-self:flex-start;padding:5px 10px;border:1px solid #ffd29966;border-radius:18px;background:#56371966;color:#ffdfa9;font:600 11px/1.4 system-ui}.account-identity .account-app-role[hidden]{display:none!important}

/* Explicit account sign-out action. */
#overliveAccountPanel #accountLogout { background:#d71920!important; color:#fff!important; border:1px solid #ff5964!important; border-radius:12px; padding:12px 18px; font-weight:750; }
#overliveAccountPanel #accountLogout:hover { background:#f0252f!important; color:#fff!important; }

/* The native chooser stays connected; the custom button is the sole visible file control. */
#overliveAccountPanel #accountPhotoFile,#overliveAccountPanel #accountPhotoRemove{display:none!important;}
.account-photo-controls{display:grid;gap:7px;min-width:0;flex:1;}
#overliveAccountPanel #accountPhotoChoose{justify-self:start;min-height:44px;max-width:100%;padding:9px 14px;border:1px solid #ffc39b70;border-radius:11px;background:#543026;color:#fff1e4;font:600 13px/1.35 system-ui;}
#accountPhotoCount{font:600 12px/1.4 system-ui;color:inherit;}
.account-photo-gallery{display:grid;grid-template-columns:repeat(auto-fit,minmax(96px,1fr));gap:10px;min-width:0;max-width:540px;}
.account-gallery-photo{display:grid;grid-template-columns:minmax(0,1fr) 44px;gap:4px;min-width:0;padding:5px;border:1px solid #ffffff25;border-radius:14px;}
.account-gallery-photo[data-main='true']{border-color:#e9b789;}
#overliveAccountPanel .account-gallery-action{min-width:0;min-height:44px;padding:5px;border:1px solid #ffffff25;border-radius:9px;background:#ffffff0c;color:inherit;font:600 11px/1.3 system-ui;}
#overliveAccountPanel .account-gallery-main{grid-column:1/-1;display:grid;place-items:center;position:relative;padding:0;overflow:hidden;aspect-ratio:1;}
.account-gallery-main img{display:block;width:100%;height:100%;object-fit:cover;}
.account-gallery-main[aria-pressed='true']::after{content:'Principale';position:absolute;inset:auto 0 0;background:#100a10d9;color:#fff;font:600 10px/1.4 system-ui;padding:4px;}
#accountPhotoHint[data-kind='error']{color:#ffb8ad;}
.profile-public-photos{display:grid;grid-template-columns:repeat(auto-fit,minmax(100px,1fr));gap:8px;margin:12px 0;min-width:0;}
.profile-public-photos img{display:block;width:100%;max-height:260px;aspect-ratio:1;object-fit:contain;border-radius:14px;background:#08090d;}
.profile-public-photos[hidden]{display:none!important;}
.social-avatar-wrap{position:relative;display:inline-grid;flex:0 0 auto;vertical-align:middle;line-height:0;}

#overliveAccountPanel #accountPhotoCount{position:absolute;width:1px;height:1px;min-height:0;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0;}
