/* JAVIS Classic Founder-approved R2.1 premium account menu and logo animation. */
/* Scoped frontend-only overlays: no auth/J/provider backend changes. */
.authAccountMenu:not([hidden]){
 border:1px solid rgba(255,133,193,.26)!important;
 border-radius:22px!important;
 background:linear-gradient(145deg,rgba(29,16,28,.985),rgba(14,9,15,.985))!important;
 box-shadow:0 26px 70px rgba(0,0,0,.63),0 0 25px rgba(216,65,146,.13),inset 0 1px 0 rgba(255,192,229,.11)!important;
 animation:r21MenuOpen .18s cubic-bezier(.2,.72,.2,1) both;
 transform-origin:90% 0%;
}
@keyframes r21MenuOpen{from{opacity:.6;transform:translateY(-5px) scale(.986)}to{opacity:1;transform:translateY(0) scale(1)}}
.authMenuIdentity{padding-bottom:15px!important}
.authMenuIdentity .accountNameRow{align-items:center!important}
.accountNameRow .accountPlanTag{border-radius:999px!important;letter-spacing:.02em!important;box-shadow:0 1px 7px rgba(230,150,100,.11)}
.authMenuUsage{border-color:rgba(255,186,230,.13)!important;background:linear-gradient(115deg,rgba(255,100,161,.09),rgba(255,255,255,.025))!important;border-radius:14px!important;padding:13px 12px!important}
.authMenuUsage>b{font-size:19px!important}
.authMenuAvatar[role=button]{box-shadow:0 0 0 2px rgba(246,124,189,.21),0 0 14px rgba(255,104,183,.16)!important}
.authMenuAvatar[role=button] #authMenuAvatarFallback{display:block!important;width:100%;height:100%;line-height:0!important}
.authMenuAvatar[role=button] #authMenuAvatarFallback img{display:block;width:100%;height:100%;border-radius:50%;object-fit:cover}
.authMenuAvatar[role=button]::after{
 content:""!important;right:-4px!important;bottom:-4px!important;width:19px!important;height:19px!important;
 background-color:#dc428e!important;background-repeat:no-repeat!important;background-position:center!important;
 background-size:12px 12px!important;
 background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 7h4l2-3h4l2 3h4v13H4z'/%3E%3Ccircle cx='12' cy='13' r='3'/%3E%3C/svg%3E")!important;
 box-shadow:0 1px 8px rgba(194,42,117,.6);
}
.accountAvatarDialog[open]{
 border:1px solid rgba(255,100,177,.75)!important;
 border-radius:20px!important;
 background:linear-gradient(145deg,rgba(35,18,36,.98),rgba(17,10,20,.99))!important;
 box-shadow:0 22px 60px rgba(0,0,0,.68),0 0 0 1px rgba(255,181,223,.08),0 0 22px rgba(244,65,151,.21)!important;
 max-height:min(505px,calc(100dvh - 24px))!important;
}
.accountAvatarDialog .accountAvatarGrid{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:8px!important}
.accountAvatarChoice{
 width:100%;min-height:0!important;height:auto!important;aspect-ratio:1/1!important;
 padding:2px!important;border:1px solid rgba(255,173,218,.24)!important;
 border-radius:13px!important;overflow:hidden!important;
 background:#241327!important;display:block!important;position:relative!important;
 transition:transform .14s,border-color .14s,box-shadow .14s!important;
}
.accountAvatarChoice img{display:block;width:100%;height:100%;object-fit:cover;border-radius:10px;image-rendering:auto}
.accountAvatarChoice small{position:absolute;left:0;bottom:0;right:0;pointer-events:none;font-size:0!important;opacity:0}
.accountAvatarChoice:hover{transform:translateY(-2px) scale(1.025)!important;border-color:#ff87c6!important;box-shadow:0 5px 19px #0008,0 0 13px #ff6bb844!important}
.accountAvatarChoice[aria-pressed=true]{border-color:#ffc4df!important;box-shadow:inset 0 0 0 2px #ff8db5,0 0 16px #e949a877!important}
.accountAvatarHeader h3{font-size:16px!important;font-weight:700!important}
.accountAvatarNote{font-size:11px!important}
.accountAvatarGrid button:focus-visible{outline:2px solid #ffe1ef;outline-offset:2px}
.accountActionDecorated{display:flex!important;align-items:center!important;justify-content:flex-start!important;gap:13px!important;
 min-height:42px!important;padding:0 12px!important;transition:background .14s,color .14s}
.accountActionIcon{width:19px;height:19px;min-width:19px;flex:0 0 19px;stroke:#e6c9dd;stroke-width:1.8;fill:none;stroke-linecap:round;stroke-linejoin:round}
.authMenuAction.danger .accountActionIcon{stroke:#ef7ea9}
.authMenuAction.danger:hover .accountActionIcon{stroke:#ff9bbd}
.accountManageAction{color:#e8d7e3!important}
.javisAccountInfoPanel{padding:10px 12px 12px!important;margin:0 4px 7px;background:#241620;border:1px solid rgba(255,171,213,.14);border-radius:12px}
.javisAccountInfoPanel[hidden]{display:none!important}
.javisAccountInfoPanel>b{display:block;font-size:12px;margin-bottom:7px;color:#f4d5e7}
.javisAccountInfoPanel .accountDetailName{font-size:12px;color:#fff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.javisAccountInfoPanel .accountDetailEmail{font-size:11px;color:#ae8e9e;overflow-wrap:anywhere;margin-top:4px}
.javisAccountInfoPanel .accountDetailPlan{font-size:11px;color:#e8b3ce;margin:7px 0}
.accountDetailsAvatar{padding:7px 12px;border-radius:9px;background:#3e2132;color:#ffd9ed;border:1px solid #804263;font-size:11px;cursor:pointer}
@keyframes javisR21LogoBreath{
 0%,100%{filter:drop-shadow(0 0 0 rgba(244,78,161,0)) brightness(1)}
 50%{filter:drop-shadow(0 0 7px rgba(233,74,149,.27)) brightness(1.045)}
}
@keyframes javisR21LogoSheen{
 0%,10%{mask-position:145% 50%;-webkit-mask-position:145% 50%;opacity:0}
 14%{opacity:.5}
 28%{mask-position:-60% 50%;-webkit-mask-position:-60% 50%;opacity:0}
 100%{mask-position:-60% 50%;-webkit-mask-position:-60% 50%;opacity:0}
}
@media (min-width:761px){
 .topbar .brand img{animation:javisR21LogoBreath 5.8s ease-in-out infinite!important;transform:none!important;will-change:filter}
 .topbar .brand{overflow:visible!important;isolation:isolate}
 .topbar .brand::before{
  content:""!important;position:absolute;inset:0;z-index:2;pointer-events:none;
  background:url('/static/assets/JAVIS_CLASSIC_WAVEFORM_HORIZONTAL_V3.png?v=brand-v3-20261106') center/contain no-repeat!important;
  filter:brightness(1.7) saturate(.86) drop-shadow(0 0 6px rgba(252,178,223,.25))!important;
  mask-image:linear-gradient(112deg,transparent 0%,transparent 43%,#000 50%,transparent 57%,transparent 100%);
  -webkit-mask-image:linear-gradient(112deg,transparent 0%,transparent 43%,#000 50%,transparent 57%,transparent 100%);
  mask-size:290% 100%;-webkit-mask-size:290% 100%;mask-repeat:no-repeat;-webkit-mask-repeat:no-repeat;
  animation:javisR21LogoSheen 8s ease-in-out infinite!important;
 }
}
@media(max-width:520px){
 .authAccountMenu:not([hidden]){border-radius:16px!important;animation-duration:.12s}
 .accountAvatarDialog[open]{padding:12px!important}
 .accountAvatarGrid button{border-radius:11px!important}
 .accountNameRow .accountPlanTag{padding:2px 5px!important;font-size:8px!important}
}
@media(prefers-reduced-motion:reduce){
 .topbar .brand img,.topbar .brand::before,.authAccountMenu:not([hidden]){animation:none!important}
 .accountAvatarChoice,.accountActionDecorated{transition:none!important}
}

/* R2.1 one-management-action guarantee. Do not override the native [hidden] API. */
#authAccountMenu .accountManageAction[hidden],#authAccountMenu #authAdminConsole[hidden]{display:none!important}

/* R3: inset scrolling preserves the neon frame and keeps both controls visible. */
.accountAvatarDialog[open]{
 display:flex!important;flex-direction:column!important;gap:0!important;
 width:324px;max-height:min(438px,var(--avatar-viewport-height,calc(100dvh - 24px)))!important;
 padding:14px!important;overflow:hidden!important;overscroll-behavior:contain;
}
.accountAvatarHeader,.accountAvatarNote,.accountAvatarStatus{flex:0 0 auto}
.accountAvatarHeader{gap:10px}
.accountAvatarNote{margin:7px 0 10px!important;color:#cdb1c7!important}
.accountAvatarScroll{
 flex:1 1 auto;min-height:0;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;
 padding:5px 9px 7px 4px;margin:0 -1px 0 -4px;scrollbar-gutter:stable;
 scrollbar-width:thin;scrollbar-color:#d467a1 #321e32;border-radius:9px;
}
.accountAvatarScroll::-webkit-scrollbar{width:6px}
.accountAvatarScroll::-webkit-scrollbar-track{background:#321e32;border-radius:999px;margin-block:6px}
.accountAvatarScroll::-webkit-scrollbar-thumb{background:#d467a1;border:1px solid #321e32;border-radius:999px}
.accountAvatarScroll::-webkit-scrollbar-thumb:hover{background:#ef8bbc}
.accountAvatarScroll:focus-visible{outline:2px solid #f7a2ce;outline-offset:-2px}
.accountAvatarDialog .accountAvatarGrid{gap:8px!important}
.accountAvatarChoice{padding:3px!important;isolation:isolate}
.accountAvatarChoice .accountAvatarArt{
 display:block!important;width:100%;height:100%;aspect-ratio:1;overflow:hidden;
 border-radius:9px;background-repeat:no-repeat;background-size:400% 600%;
}
.authMenuAvatar[role=button] .accountAvatarArt{
 display:block;width:100%;height:100%;border-radius:50%;background-repeat:no-repeat;background-size:400% 600%;
}
.accountAvatarChoice[aria-pressed=true]::after{
 content:'✓';position:absolute;right:4px;bottom:4px;display:grid;place-items:center;
 width:17px;height:17px;border-radius:50%;background:#f5a3cd;color:#321326;
 font:700 12px/1 system-ui;border:1px solid #ffe3f2;box-shadow:0 1px 5px #0008;pointer-events:none;
}
.accountAvatarChoice:disabled{cursor:wait;opacity:.72}
.accountAvatarStatus{min-height:16px!important;line-height:1.4!important;margin:8px 0 0!important}
@media(max-width:520px){
 .accountAvatarDialog[open]{padding:12px!important}
}

/* Scale the shared logo wrapper so the V3 image and sheen stay aligned. */
.topbar .brand{transform-origin:center;transition:transform .3s cubic-bezier(.2,.65,.25,1)!important}
@media(hover:hover) and (pointer:fine){
 .topbar .brand:hover{transform:scale(1.04)!important}
}
@media(prefers-reduced-motion:reduce){
 .topbar .brand,.topbar .brand:hover{transform:none!important;transition:none!important}
 .accountAvatarChoice,.accountAvatarChoice:hover{transform:none!important;transition:none!important}
}
