<?xml version="1.0" encoding="utf-8"?>
<com.google.android.material.card.MaterialCardView xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="124dp"
    android:layout_height="wrap_content"
    android:layout_marginEnd="14dp"
    android:clickable="true"
    android:focusable="true"
    android:foreground="?attr/selectableItemBackground"
    app:cardBackgroundColor="@android:color/transparent"
    app:cardCornerRadius="12dp"
    app:cardElevation="0dp"
    app:strokeWidth="0dp">

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

        <FrameLayout
            android:layout_width="match_parent"
            android:layout_height="176dp">

            <ImageView
                android:id="@+id/book_cover"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:background="@drawable/bg_cover_placeholder"
                android:importantForAccessibility="no"
                android:scaleType="centerCrop" />

            <ProgressBar
                android:id="@+id/book_progress_bar"
                style="?android:attr/progressBarStyleHorizontal"
                android:layout_width="match_parent"
                android:layout_height="4dp"
                android:layout_gravity="bottom"
                android:max="100"
                android:progressBackgroundTint="#402A1A0C"
                android:progressTint="@color/night_gold" />

            <TextView
                android:id="@+id/book_actions"
                android:layout_width="40dp"
                android:layout_height="40dp"
                android:layout_gravity="top|end"
                android:layout_marginTop="6dp"
                android:layout_marginEnd="6dp"
                android:background="@drawable/bg_circle_white"
                android:clickable="true"
                android:elevation="6dp"
                android:focusable="true"
                android:gravity="center"
                android:text="&#8942;"
                android:textColor="@color/ink_color"
                android:textSize="25sp"
                android:visibility="gone" />
        </FrameLayout>

        <TextView
            android:id="@+id/book_title"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="8dp"
            android:ellipsize="end"
            android:fontFamily="@font/open_sans_semibold"
            android:maxLines="2"
            android:textColor="@color/night_cream"
            android:textSize="12sp" />

        <TextView
            android:id="@+id/book_author"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="3dp"
            android:ellipsize="end"
            android:maxLines="1"
            android:textColor="@color/night_muted"
            android:textSize="10sp" />

        <TextView
            android:id="@+id/book_progress_text"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="4dp"
            android:ellipsize="end"
            android:maxLines="1"
            android:textColor="@color/night_gold_soft"
            android:textSize="10sp" />
    </LinearLayout>

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