/* Make space for the button */
#search-top-box {
right: 0.7rem;
}
#login-status span.printuser>a {
right: 1.4rem;
padding: 0;
width: 28px;
}
#login-status>a[href*='account/messages'] {
right: min(1.1rem, calc(var(--user-button-width) / 6) + 0.7rem);
}
/* Styling the button */
a#account-topbutton {
display: inline-block;
pointer-events: auto;
position: absolute;
top: 0;
right: 0;
height: calc(var(--base-header-height) * 0.25 + 1px);
padding: calc(var(--base-header-height) * 0.38) 0.4rem;
margin: 0;
border: none;
color: rgb(var(--basalt-overtone));
font-size: 0.6rem;
}
/* Hide the original avatar hover background */
#login-status::after {
display: none;
}
/* Hover background styling for the button */
a#account-topbutton::before,
a#account-topbutton::after {
display: block;
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
a#account-topbutton::before {
content: '';
z-index: -1;
background-color: rgb(var(--basalt-overtone));
height: 0;
transition: height var(--header-link-transition-1st);
}
a#account-topbutton::after {
content: '▼';
z-index: 2;
color: transparent;
background-color: rgb(254, 254, 254);
background-clip: text;
padding: calc(var(--base-header-height)* 0.38) 0.4rem;
mask-image: linear-gradient(to bottom, black, black);
mask-size: 100% 0;
transition: mask-size var(--header-link-transition-1st);
}
a#account-topbutton:is(:hover, :focus-within)::before,
a#account-topbutton:is(:hover, :focus-within)::after {
height: 100%;
mask-size: 100% 100%;
}