<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:id="@+id/bgLayout"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@color/material_grey100"
    android:orientation="vertical"
    android:paddingTop="@dimen/seekbarsize">

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="vertical">

        <com.google.android.material.appbar.AppBarLayout
            android:id="@+id/appBarLayout"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:background="@color/white">

            <LinearLayout
                android:id="@+id/layout1"
                android:layout_width="match_parent"
                android:layout_height="50dp"
                android:orientation="horizontal"
                android:paddingLeft="@dimen/seekbarsize_small"
                android:paddingRight="@dimen/seekbarsize_small">

                <ImageButton
                    android:id="@+id/previous"
                    android:layout_width="@dimen/buttonHeightNormal"
                    android:layout_height="@dimen/buttonHeightSmall"
                    android:layout_gravity="center_vertical"
                    android:background="@null"
                    android:contentDescription="@string/app_name"
                    android:padding="@dimen/seekbarsize_small"
                    android:scaleType="fitCenter"
                    android:src="@drawable/previous_tab" />

                <TextView
                    android:id="@+id/MonthText"
                    android:layout_width="0dip"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:gravity="center"
                    android:maxLines="1"
                    android:singleLine="true"
                    android:textColor="@color/btn_bg_color"
                    android:textSize="18dp" />

                <ImageButton
                    android:id="@+id/next"
                    android:layout_width="@dimen/buttonHeightNormal"
                    android:layout_height="@dimen/buttonHeightSmall"
                    android:layout_gravity="center"
                    android:background="@null"
                    android:contentDescription="@string/app_name"
                    android:padding="@dimen/seekbarsize_small"
                    android:scaleType="fitCenter"
                    android:src="@drawable/next_tab" />
            </LinearLayout>

        </com.google.android.material.appbar.AppBarLayout>

        <LinearLayout
            android:id="@+id/linear1"
            android:layout_width="match_parent"
            android:layout_height="24dp"
            android:orientation="horizontal"
            android:paddingLeft="@dimen/textSizeSmall"
            android:paddingRight="@dimen/textSizeSmall">

            <TextView
                android:id="@+id/pos_text"
                android:layout_width="0dip"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:gravity="center|left"
                android:maxLines="1"
                android:singleLine="true"
                android:text="Your Position"
                android:textColor="@color/material_black"
                android:textSize="@dimen/textSizeAverage"
                android:textStyle="bold" />

            <TextView
                android:id="@+id/positionOutof"
                android:layout_width="0dip"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:gravity="center|right"
                android:maxLines="1"
                android:singleLine="true"
                android:textColor="@color/material_black"
                android:textSize="@dimen/textSizeSmall" />
        </LinearLayout>


        <androidx.cardview.widget.CardView
            android:id="@+id/list_leaderbord"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginLeft="@dimen/seekbarsize_small"
            android:layout_marginRight="@dimen/seekbarsize_small"
            android:visibility="visible"
            app:cardBackgroundColor="#ffffff"
            app:cardElevation="0dp"
            app:cardMaxElevation="0dp"
            app:cardUseCompatPadding="true">

            <LinearLayout
                android:id="@+id/linear2"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:background="@drawable/border_grey"
                android:gravity="center"
                android:minHeight="120dp"
                android:orientation="horizontal">

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:baselineAligned="false"
                    android:orientation="horizontal">

                    <LinearLayout
                        android:layout_width="70dp"
                        android:layout_height="match_parent"
                        android:gravity="center"
                        android:orientation="vertical">

                        <FrameLayout
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content">

                            <ImageView
                                android:id="@+id/cup"
                                android:layout_width="@dimen/buttonHeight"
                                android:layout_height="@dimen/buttonHeight"
                                android:layout_gravity="center"
                                android:background="@android:color/transparent"
                                android:contentDescription="@string/app_name"
                                android:scaleType="fitCenter"
                                android:src="@mipmap/leader_icon" />

                            <TextView
                                android:id="@+id/position"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_gravity="center"
                                android:layout_marginBottom="@dimen/seekbarsize"
                                android:gravity="center"
                                android:maxLines="1"
                                android:singleLine="true"
                                android:text="10"
                                android:textColor="@color/material_black"
                                android:textSize="@dimen/textSizeToSmall"
                                android:textStyle="bold" />
                        </FrameLayout>

                        <TextView
                            android:id="@+id/score"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:gravity="center"
                            android:maxLines="1"
                            android:singleLine="true"
                            android:textColor="@color/material_black"
                            android:textSize="@dimen/textSizeAverage"
                            android:textStyle="bold" />
                    </LinearLayout>

                    <LinearLayout
                        android:layout_width="0dip"
                        android:layout_height="match_parent"
                        android:layout_weight="1"
                        android:gravity="center"
                        android:orientation="vertical">

                        <TextView
                            android:id="@+id/name"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:gravity="center|left"
                            android:maxLines="1"
                            android:textColor="@color/material_black"
                            android:textSize="@dimen/textSizeSmall"
                            android:textStyle="bold" />

                        <TextView
                            android:id="@+id/location"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:gravity="center|left"
                            android:maxLines="1"
                            android:singleLine="true"
                            android:textColor="@color/material_black"
                            android:textSize="@dimen/textSizeSmall" />

                        <TextView
                            android:id="@+id/dealer_name"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:gravity="center|left"
                            android:maxLines="1"
                            android:singleLine="true"
                            android:textColor="@color/material_black"
                            android:textSize="@dimen/textSizeSmall" />

                        <TextView
                            android:id="@+id/duration"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:gravity="center|left"
                            android:maxLines="1"
                            android:singleLine="true"
                            android:textColor="@color/material_black"
                            android:textSize="@dimen/textSizeSmall" />

                        <TextView
                            android:id="@+id/dateTime"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:gravity="center|left"
                            android:maxLines="1"
                            android:singleLine="true"
                            android:textColor="@color/material_black"
                            android:textSize="10dp" />

                    </LinearLayout>

                    <FrameLayout
                        android:layout_width="@dimen/buttonHeightLarge"
                        android:layout_height="@dimen/buttonHeightLarge"
                        android:layout_gravity="center"
                        android:layout_margin="@dimen/seekbarsize_small">

                        <ImageView
                            android:layout_width="match_parent"
                            android:layout_height="match_parent"
                            android:contentDescription="@string/app_name"
                            android:scaleType="fitCenter"
                            android:src="@drawable/ellipse" />

                        <com.github.siyamed.shapeimageview.CircularImageView
                            android:id="@+id/userImage"
                            android:layout_width="match_parent"
                            android:layout_height="match_parent"
                            android:layout_margin="2dp"
                            android:background="@drawable/custom_circle_blue"
                            app:siBorderColor="@android:color/white"
                            app:siBorderWidth="0dp" />
                    </FrameLayout>
                </LinearLayout>

            </LinearLayout>

        </androidx.cardview.widget.CardView>

        <LinearLayout
            android:id="@+id/linear3"
            android:layout_width="match_parent"
            android:layout_height="24dp"
            android:orientation="horizontal"
            android:paddingLeft="@dimen/textSizeSmall"
            android:paddingRight="@dimen/textSizeSmall">

            <TextView
                android:id="@+id/topcount"
                android:layout_width="0dip"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:gravity="center|left"
                android:maxLines="1"
                android:singleLine="true"
                android:textColor="@color/material_black"
                android:textSize="@dimen/textSizeAverage"
                android:textStyle="bold" />

            <TextView
                android:id="@+id/outofcount"
                android:layout_width="0dip"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:gravity="center|right"
                android:maxLines="1"
                android:singleLine="true"
                android:textColor="@color/material_black"
                android:textSize="@dimen/textSizeSmall" />
        </LinearLayout>

        <com.tylersuehr.esr.EmptyStateRecyclerView
            android:id="@+id/leaderList"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />
    </LinearLayout>

</FrameLayout>
