<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto"
    android:focusable="true"
    android:clickable="true"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginBottom="@dimen/row_spacing_mobile"
    android:foreground="?attr/selectableItemBackground"
    android:layout_marginEnd="@dimen/row_spacing_mobile">
    <androidx.cardview.widget.CardView
        android:id="@+id/poster_card"
        android:layout_width="@dimen/poster_width_mobile"
        android:layout_height="@dimen/poster_height_mobile"
        app:cardCornerRadius="@dimen/radius_poster_mobile"
        app:cardElevation="2dp">
        <FrameLayout
            android:layout_width="match_parent"
            android:layout_height="match_parent">
            <ImageView
                android:id="@+id/poster_image"
                android:background="@color/mobile_surface_variant"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:scaleType="centerCrop"
                android:contentDescription="@null"/>
            <com.facebook.shimmer.ShimmerFrameLayout
                android:id="@+id/shimmer_placeholder"
                android:visibility="gone"
                android:layout_width="match_parent"
                android:layout_height="match_parent">
                <View
                    android:background="@color/mobile_surface_variant"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"/>
            </com.facebook.shimmer.ShimmerFrameLayout>
            <LinearLayout
                android:gravity="center"
                android:layout_gravity="start|top"
                android:orientation="vertical"
                android:id="@+id/date_badge"
                android:background="@drawable/calendar_badge_bg"
                android:paddingTop="3dp"
                android:paddingBottom="3dp"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_margin="6dp"
                android:paddingHorizontal="6dp">
                <TextView
                    android:textSize="8sp"
                    android:textStyle="bold"
                    android:textColor="@android:color/white"
                    android:id="@+id/badge_day"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"/>
                <TextView
                    android:textSize="14sp"
                    android:textStyle="bold"
                    android:textColor="@android:color/white"
                    android:id="@+id/badge_date"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"/>
            </LinearLayout>
            <TextView
                android:textSize="10sp"
                android:textStyle="bold"
                android:textColor="@android:color/white"
                android:layout_gravity="end|bottom"
                android:id="@+id/show_count"
                android:background="@drawable/calendar_badge_bg"
                android:visibility="gone"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_margin="6dp"
                android:paddingHorizontal="5dp"
                android:paddingVertical="2dp"/>
            <TextView
                android:textSize="10sp"
                android:textColor="@android:color/white"
                android:ellipsize="end"
                android:layout_gravity="bottom"
                android:id="@+id/title_overlay"
                android:background="@drawable/poster_title_bg"
                android:visibility="gone"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:maxLines="2"
                android:paddingHorizontal="6dp"
                android:paddingVertical="4dp"/>
        </FrameLayout>
    </androidx.cardview.widget.CardView>
</FrameLayout>
