/* Authenticated profile control in the home header. */
.home-header .btn-profile-header {
    display: grid !important;
    width: auto !important;
    max-width: min(70vw, 17rem) !important;
    min-height: 2.75rem;
    height: 2.75rem;
    padding: 0.3rem 0.75rem 0.3rem 0.3rem !important;
    grid-template-columns: auto minmax(0, auto) auto;
    align-items: center !important;
    gap: 0.55rem !important;
    overflow: hidden;
    color: #172033 !important;
    border: 1px solid #d6e2ef !important;
    border-radius: 999px !important;
    background: #fff !important;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06) !important;
    line-height: 1;
}

.home-header .btn-profile-header:hover {
    background: #f8fafc !important;
    border-color: #b7cce0 !important;
    transform: none !important;
    box-shadow: 0 6px 18px rgba(30, 64, 175, 0.1) !important;
}

.home-header .btn-profile-header > div {
    display: grid !important;
    flex: 0 0 2rem;
    width: 2rem !important;
    height: 2rem !important;
    min-width: 2rem;
    place-items: center;
    border-radius: 50%;
}

.home-header .btn-profile-header .user-avatar-small {
    width: 2rem !important;
    height: 2rem !important;
    border: 2px solid #38bdf8 !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    aspect-ratio: 1;
}

.home-header .btn-profile-header .user-name-display {
    min-width: 0;
    max-width: 9rem !important;
    margin: 0 !important;
    overflow: hidden;
    color: #172033 !important;
    font-size: 0.82rem !important;
    font-weight: 700 !important;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.home-header .btn-profile-header .profile-coin-balance {
    display: inline-flex;
    margin: 0 !important;
    align-items: center;
    gap: 0.3rem;
    color: #d97706 !important;
    font-size: 0.76rem !important;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.home-header .btn-profile-header:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.25);
    outline-offset: 2px;
}

@media (max-width: 35rem) {
    .home-header .btn-profile-header {
        max-width: 6.75rem !important;
        padding-right: 0.65rem !important;
        grid-template-columns: auto auto;
        gap: 0.45rem !important;
    }

    .home-header .btn-profile-header .user-name-display {
        display: none !important;
    }
}

@media (max-width: 22.5rem) {
    .home-header .btn-profile-header {
        width: 2.75rem !important;
        padding: 0.3rem !important;
        grid-template-columns: 1fr;
    }

    .home-header .btn-profile-header .profile-coin-balance {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .home-header .btn-profile-header {
        transition: none !important;
    }
}

