/* Mobile account menu opened from the signed-in user's top-right avatar. */
.mobile-profile-menu{display:none}
@media(max-width:759px){
  body.fb-mobile-menu-open{overflow:hidden!important}
  .mobile-profile-menu{
    position:fixed;
    inset:var(--fb-mobile-header-h,102px) 0 0 0;
    z-index:900;
    display:flex;
    flex-direction:column;
    background:var(--fb-shell-bg,#f3f0e8);
    color:var(--fb-shell-text,#1f2a22);
    overflow:hidden;
    animation:fbMenuFade .16s ease-out both;
  }
  .mobile-profile-menu-head{
    flex:0 0 58px;
    min-height:58px;
    display:flex;
    align-items:center;
    gap:12px;
    padding:0 14px;
    border-bottom:1px solid var(--fb-shell-border,rgba(49,92,67,.16));
    background:color-mix(in srgb,var(--fb-shell-panel,#fffdf8) 97%,transparent);
  }
  .mobile-profile-menu-head h1{
    margin:0;
    font-size:1.55rem;
    line-height:1;
    font-weight:900;
  }
  .mobile-profile-menu-close{
    width:42px;
    height:42px;
    border:0;
    border-radius:50%;
    background:transparent;
    color:inherit;
    display:grid;
    place-items:center;
    padding:0;
  }
  .mobile-profile-menu-close:active{background:var(--fb-shell-panel-2,#f7f4ec);transform:scale(.95)}
  .mobile-profile-menu-close svg{width:27px;height:27px}

  .mobile-profile-menu-scroll{
    flex:1 1 auto;
    overflow:auto;
    overscroll-behavior:contain;
    padding:12px 14px calc(24px + env(safe-area-inset-bottom));
  }
  .mobile-profile-menu-profile{
    width:100%;
    margin-top:0;
    border:1px solid var(--fb-shell-border,rgba(49,92,67,.16));
    border-radius:17px;
    background:var(--fb-shell-panel,#fffdf8);
    color:inherit;
    display:grid;
    grid-template-columns:58px minmax(0,1fr) 38px;
    align-items:center;
    gap:12px;
    padding:14px;
    text-align:left;
    box-shadow:0 2px 10px rgba(0,0,0,.04);
    animation:fbMenuRise .22s ease-out both;
  }
  .mobile-profile-menu-profile:active{transform:scale(.985);background:var(--fb-shell-panel-2,#f7f4ec)}
  .mobile-profile-menu-avatar{
    width:58px;
    height:58px;
    border-radius:50%;
    overflow:hidden;
    display:grid;
    place-items:center;
    background:var(--fb-shell-accent-soft,#e7efe9);
    color:var(--fb-shell-accent,#315c43);
    font-weight:900;
    font-size:1rem;
    border:1px solid var(--fb-shell-border,rgba(49,92,67,.16));
  }
  .mobile-profile-menu-avatar img{width:100%;height:100%;object-fit:cover;object-position:center;display:block}
  .mobile-profile-menu-copy{min-width:0;display:grid;gap:3px}
  .mobile-profile-menu-copy strong{font-size:1rem;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .mobile-profile-menu-copy span{font-size:.78rem;color:var(--fb-shell-muted,#738076);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .mobile-profile-menu-copy small{font-size:.8rem;color:var(--fb-shell-accent,#315c43);font-weight:800}
  .mobile-profile-menu-chevron{
    width:36px;
    height:36px;
    border-radius:50%;
    display:grid;
    place-items:center;
    justify-self:end;
    background:var(--fb-shell-panel-2,#f7f4ec);
    color:var(--fb-shell-muted,#738076);
  }
  .mobile-profile-menu-chevron svg{width:20px;height:20px}

  .mobile-profile-menu-grid{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:10px;
    margin-top:12px;
  }
  .mobile-profile-menu-card{
    min-height:108px;
    border:1px solid var(--fb-shell-border,rgba(49,92,67,.16));
    border-radius:16px;
    background:var(--fb-shell-panel,#fffdf8);
    color:inherit;
    padding:15px 13px;
    display:flex;
    flex-direction:column;
    align-items:flex-start;
    justify-content:space-between;
    gap:10px;
    text-align:left;
    box-shadow:0 2px 8px rgba(0,0,0,.03);
    animation:fbMenuRise .25s ease-out both;
    min-width:0;
  }
  .mobile-profile-menu-card:nth-child(2){animation-delay:.02s}
  .mobile-profile-menu-card:nth-child(3){animation-delay:.04s}
  .mobile-profile-menu-card:nth-child(4){animation-delay:.06s}
  .mobile-profile-menu-card:nth-child(5){animation-delay:.08s}
  .mobile-profile-menu-card:nth-child(6){animation-delay:.10s}
  .mobile-profile-menu-card:active{transform:scale(.97);background:var(--fb-shell-panel-2,#f7f4ec)}
  .mobile-profile-menu-card-icon{
    width:40px;
    height:40px;
    border-radius:12px;
    display:grid;
    place-items:center;
    background:var(--fb-shell-accent-soft,#e7efe9);
    color:var(--fb-shell-accent,#315c43);
  }
  .mobile-profile-menu-card-icon svg{width:22px;height:22px}
  .mobile-profile-menu-card>span:last-child{
    width:100%;
    min-width:0;
    display:grid;
    gap:4px;
    align-content:start;
  }
  .mobile-profile-menu-card strong{
    display:block;
    width:100%;
    font-size:.96rem;
    line-height:1.15;
    white-space:normal;
  }
  .mobile-profile-menu-card small{
    display:block;
    width:100%;
    font-size:.72rem;
    color:var(--fb-shell-muted,#738076);
    line-height:1.3;
    white-space:normal;
  }

  .mobile-profile-menu-admin{
    width:100%;
    margin-top:10px;
    min-height:58px;
    border:1px solid var(--fb-shell-border,rgba(49,92,67,.16));
    border-radius:15px;
    background:var(--fb-shell-panel,#fffdf8);
    color:inherit;
    padding:11px 13px;
    display:flex;
    align-items:center;
    gap:11px;
    text-align:left;
    font-weight:800;
  }
  .mobile-profile-menu-admin span:first-child{width:38px;height:38px;border-radius:11px;background:var(--fb-shell-accent-soft,#e7efe9);color:var(--fb-shell-accent,#315c43);display:grid;place-items:center}
  .mobile-profile-menu-admin span:first-child svg{width:20px;height:20px}
  .mobile-profile-menu-admin>svg{margin-left:auto;width:20px;height:20px;color:var(--fb-shell-muted,#738076)}

  @keyframes fbMenuFade{from{opacity:0}to{opacity:1}}
  @keyframes fbMenuRise{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}
}
@media(prefers-reduced-motion:reduce){
  .mobile-profile-menu,.mobile-profile-menu-profile,.mobile-profile-menu-card{animation:none!important}
}
