<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

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

        <RelativeLayout
            android:id="@+id/fragment_tab_container"
            android:layout_width="match_parent"
            android:layout_height="@dimen/tab_layout_height"
            android:background="@color/ui_surface">

            <com.gh.gamecenter.common.view.TabIndicatorView
                android:id="@+id/fragment_tab_indicator"
                android:layout_width="match_parent"
                android:layout_height="@dimen/default_tab_indicator_height"
                android:layout_alignParentBottom="true" />

            <com.google.android.material.tabs.TabLayout
                android:id="@+id/fragment_tab_layout"
                android:layout_width="match_parent"
                android:layout_height="@dimen/tab_layout_height"
                app:tabIndicator="@null"
                app:tabTextAppearance="@style/TabLayoutTextAppearance" />

        </RelativeLayout>

        <View
            android:id="@+id/dividerLine"
            android:layout_width="match_parent"
            android:layout_height="0.5dp"
            android:background="@color/ui_divider"
            android:visibility="gone" />

        <com.lightgame.view.NoScrollableViewPager
            android:id="@+id/fragment_view_pager"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />

    </LinearLayout>

    <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true">

        <ImageView
            android:id="@+id/maskView"
            android:layout_width="match_parent"
            android:layout_height="32dp"
            android:scaleType="fitXY"
            android:src="@drawable/bg_banner_ad_mask"
            android:visibility="gone" />

        <FrameLayout
            android:id="@+id/adContainer"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_below="@id/maskView"
            android:background="@color/ui_surface" />

        <FrameLayout
            android:id="@+id/adGameItemContainer"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_below="@id/maskView"
            android:visibility="gone">

            <androidx.recyclerview.widget.RecyclerView
                android:id="@+id/adGameBannerRv"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:overScrollMode="never" />

            <ImageView
                android:id="@+id/closeAdIv"
                android:layout_width="16dp"
                android:layout_height="16dp"
                android:layout_gravity="top|end"
                android:layout_marginTop="8dp"
                android:layout_marginEnd="8dp"
                app:srcCompat="@drawable/icon_close" />

        </FrameLayout>

    </RelativeLayout>

</RelativeLayout>