<?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"
    xmlns:tools="http://schemas.android.com/tools"
    android:orientation="vertical"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context=".DetailActivity">
    <androidx.appcompat.widget.Toolbar
        android:id="@+id/toolbar"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_alignParentTop="true"
        android:background="@color/colorPrimary"
        android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar">
        <TextView
            android:id="@+id/telegram"
            android:layout_width="60dp"
            android:layout_height="25dp"
            android:background="@drawable/tele"
            android:layout_gravity="end"
            android:layout_marginEnd="20dp" />
    </androidx.appcompat.widget.Toolbar>
    <com.google.android.material.tabs.TabLayout
        android:id="@+id/tab"
        app:tabGravity="fill"
        app:tabMode="scrollable"
        app:tabIndicatorHeight="4dp"
        android:layout_below="@id/toolbar"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:tabBackground="@color/colorPrimary"
        android:background="@color/colorPrimary"
        app:tabIndicatorColor="@color/colorWhite"
        android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"/>
    <androidx.viewpager.widget.ViewPager
        android:id="@+id/viewpager"
        android:layout_below="@id/tab"
        android:layout_above="@id/adView"
        android:layout_width="match_parent"
        android:layout_height="match_parent"/>
    <com.google.android.gms.ads.AdView
        xmlns:ads="http://schemas.android.com/apk/res-auto"
        android:id="@+id/adView"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerHorizontal="true"
        android:layout_alignParentBottom="true"
        ads:adSize="SMART_BANNER"
        ads:adUnitId="@string/bannar_id">
    </com.google.android.gms.ads.AdView>
</RelativeLayout>