<?xml version="1.0" encoding="utf-8"?>

<RelativeLayout
    android:layout_height="match_parent"
     android:layout_width="match_parent"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools">

    <include
        android:id="@+id/cAppBar"
        layout="@layout/app_bar"/>

    <ImageView
        android:id="@+id/cartEmpty"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerInParent="true"
        android:src="@drawable/emptycart"/>

    <com.google.android.material.textview.MaterialTextView
        android:id="@+id/cartEmptyText"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_below="@id/cartEmpty"
        android:layout_centerInParent="true"
        android:textSize="30dp"
        android:text="No item in cart :("
        android:textColor="#61333333"
        />

    <androidx.recyclerview.widget.RecyclerView
        android:id="@+id/rvCart"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_above="@id/cardviews"
        android:layout_below="@id/cAppBar"
        android:overScrollMode="never"
        app:layoutManager="androidx.recyclerview.widget.GridLayoutManager"
        tools:listitem="@layout/item_cart" />

    <com.google.android.material.card.MaterialCardView
        android:id="@+id/cardviews"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:cardElevation="0dp"
        android:backgroundTint="#45EAEAEA"
        android:layout_alignParentBottom="true">

    <androidx.constraintlayout.widget.ConstraintLayout
        android:paddingTop="15dp"
        android:paddingBottom="10dp"
        android:paddingHorizontal="10dp"
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <com.google.android.material.button.MaterialButton
            android:id="@+id/btSave"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:backgroundTint="#fcbf1e"
            android:gravity="center"
            android:text="save"
            android:textAllCaps="true"
            android:layout_marginEnd="5dp"
            android:textColor="@android:color/white"
            android:textStyle="bold"
            android:paddingVertical="15dp"
            android:textSize="16sp"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintStart_toStartOf="parent"/>


        <com.google.android.material.button.MaterialButton
            android:id="@+id/btCheckout"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:backgroundTint="@color/colorPrimary"
            android:gravity="center"
            android:text="@string/title_checkout"
            android:textAllCaps="true"
            android:textColor="@android:color/white"
            android:layout_marginStart="5dp"
            android:textStyle="bold"
            android:paddingVertical="15dp"
            android:textSize="16sp"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toEndOf="@+id/btSave" />

    </androidx.constraintlayout.widget.ConstraintLayout>

    </com.google.android.material.card.MaterialCardView>

</RelativeLayout>
