<?xml version="1.0" encoding="utf-8"?>
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:id="@+id/list_refresh"
    android:background="@color/background"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <androidx.coordinatorlayout.widget.CoordinatorLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:fitsSystemWindows="true">

        <com.google.android.material.appbar.AppBarLayout
            android:id="@+id/appbar"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:background="@color/background_white"
            android:fitsSystemWindows="true"
            app:elevation="0dp"
            app:layout_behavior="com.gh.gamecenter.common.view.FixAppBarLayoutBehavior">

            <com.gh.gamecenter.common.view.ScrimAwareCollapsingToolbarLayout
                android:id="@+id/collapsingToolbar"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:fitsSystemWindows="true"
                app:contentScrim="@color/background_white"
                app:layout_scrollFlags="scroll|exitUntilCollapsed"
                app:scrimAnimationDuration="200">

                <RelativeLayout
                    android:layout_width="match_parent"
                    android:layout_height="match_parent">

                    <ImageView
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:adjustViewBounds="true"
                        android:src="@drawable/bg_amway_appbar" />

                    <View
                        android:id="@+id/nightMaskView"
                        android:layout_width="match_parent"
                        android:layout_height="match_parent"
                        android:background="@color/black_alpha_20"
                        android:visibility="gone" />

                    <androidx.constraintlayout.widget.ConstraintLayout
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:layout_alignParentBottom="true"
                        android:layout_centerHorizontal="true"
                        android:paddingBottom="33dp">

                        <ImageView
                            android:id="@+id/introIv"
                            android:layout_width="64dp"
                            android:layout_height="64dp"
                            android:src="@drawable/ic_amway_intro"
                            app:layout_constraintLeft_toLeftOf="parent"
                            app:layout_constraintTop_toTopOf="parent" />

                        <LinearLayout
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_marginLeft="12dp"
                            android:orientation="vertical"
                            app:layout_constraintBottom_toBottomOf="@id/introIv"
                            app:layout_constraintLeft_toRightOf="@id/introIv"
                            app:layout_constraintTop_toTopOf="@id/introIv">

                            <TextView
                                android:id="@+id/introTitleTv"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text="刷评论，写推荐"
                                android:textColor="@color/white"
                                android:textSize="18sp"
                                android:shadowColor="#80366a94"
                                android:shadowDx="0"
                                android:shadowDy="1.0"
                                android:shadowRadius="2.0"
                                android:textStyle="bold" />

                            <TextView
                                android:id="@+id/introContentTv"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_marginTop="2dp"
                                android:alpha="0.7"
                                android:text="一起发现更广阔的游戏世界"
                                android:textColor="@color/white"
                                android:textSize="12sp" />

                        </LinearLayout>

                    </androidx.constraintlayout.widget.ConstraintLayout>
                </RelativeLayout>

                <androidx.appcompat.widget.Toolbar
                    android:id="@+id/toolbar"
                    style="@style/Base_ToolbarStyle"
                    android:layout_width="match_parent"
                    android:layout_height="@dimen/appbar_height"
                    android:background="@android:color/transparent"
                    app:layout_collapseMode="pin"
                    app:navigationIcon="@drawable/ic_toolbar_back_white" />

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:orientation="vertical"
                    app:layout_collapseMode="pin">

                    <com.gh.gamecenter.common.view.StatusBarView
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content" />

                    <TextView
                        android:id="@+id/titleTv"
                        android:layout_width="match_parent"
                        android:layout_height="@dimen/appbar_height"
                        android:layout_marginLeft="50dp"
                        android:layout_marginRight="50dp"
                        android:gravity="center"
                        android:singleLine="true"
                        android:text="安利墙"
                        android:textColor="@color/white"
                        android:textSize="15sp"
                        android:textStyle="bold" />
                </LinearLayout>

            </com.gh.gamecenter.common.view.ScrimAwareCollapsingToolbarLayout>

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

        <RelativeLayout
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            app:behavior_overlapTop="17dp"
            app:layout_behavior="com.google.android.material.appbar.AppBarLayout$ScrollingViewBehavior">

            <androidx.recyclerview.widget.RecyclerView
                android:id="@+id/list_rv"
                android:layout_width="match_parent"
                android:layout_height="match_parent" />

            <FrameLayout
                android:id="@+id/skeletonPlaceholder"
                android:layout_width="match_parent"
                android:layout_height="match_parent" />

            <View
                android:id="@+id/reuse_ll_loading"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content" />

            <include layout="@layout/reuse_no_connection" />

            <include layout="@layout/reuse_none_data" />

            <include layout="@layout/reuse_data_exception" />

        </RelativeLayout>

        <ImageView
            android:id="@+id/fab"
            android:layout_width="60dp"
            android:layout_height="60dp"
            android:layout_gravity="end|bottom"
            android:layout_marginRight="14dp"
            android:layout_marginBottom="18dp"
            android:src="@drawable/ic_amway_fab" />

    </androidx.coordinatorlayout.widget.CoordinatorLayout>
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>