<?xml version="1.0" encoding="utf-8"?>
<LinearLayout 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:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical">

    <com.google.android.material.appbar.MaterialToolbar
        android:id="@+id/anim_toolbar"
        android:layout_width="match_parent"
        android:layout_height="?attr/actionBarSize"
        android:background="?attr/colorSurface"
        app:layout_collapseMode="pin"
        app:navigationIcon="@drawable/ic_arrow_back" />

    <androidx.core.widget.NestedScrollView
        android:layout_width="match_parent"
        android:layout_height="match_parent">

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

        <com.google.android.material.appbar.AppBarLayout
            android:id="@+id/app_bar_layout"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_weight="1">


            <androidx.constraintlayout.widget.ConstraintLayout
                android:id="@+id/album_info_sector"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:background="?attr/colorSurface"
                android:paddingStart="20dp"
                app:layout_scrollFlags="exitUntilCollapsed">

                <ImageView
                    android:id="@+id/album_cover_image_view"
                    android:layout_width="0dp"
                    android:layout_height="0dp"
                    android:layout_marginLeft="64dp"
                    android:layout_marginTop="8dp"
                    android:layout_marginRight="64dp"
                    android:layout_marginBottom="8dp"
                    app:layout_constraintDimensionRatio="H,1:1"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toStartOf="parent"
                    app:layout_constraintTop_toTopOf="parent" />

                <TextView
                    android:id="@+id/album_name_label"
                    style="@style/LabelExtraLarge"
                    android:layout_width="0dp"
                    android:layout_height="wrap_content"
                    android:ellipsize="end"
                    android:maxLines="2"
                    android:paddingTop="8dp"
                    android:singleLine="false"
                    android:text="@string/label_placeholder"
                    android:textAlignment="center"
                    app:layout_constraintEnd_toEndOf="@+id/album_cover_image_view"
                    app:layout_constraintStart_toStartOf="@+id/album_cover_image_view"
                    app:layout_constraintTop_toBottomOf="@+id/album_cover_image_view" />

                <FrameLayout
                    android:id="@+id/album_other_info_button"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_marginTop="12dp"
                    android:foreground="?android:attr/selectableItemBackgroundBorderless"
                    app:layout_constraintBottom_toBottomOf="@+id/album_name_label"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toEndOf="@+id/album_name_label"
                    app:layout_constraintTop_toTopOf="@+id/album_name_label">

                    <ImageView
                        android:layout_width="24dp"
                        android:layout_height="24dp"
                        android:background="@drawable/ic_arrow_down" />
                </FrameLayout>

                <TextView
                    android:id="@+id/album_artist_label"
                    style="@style/LabelMedium"
                    android:layout_width="0dp"
                    android:layout_height="wrap_content"
                    android:layout_marginStart="18dp"
                    android:layout_marginEnd="18dp"
                    android:ellipsize="end"
                    android:maxLines="1"
                    android:text="@string/label_placeholder"
                    android:textAlignment="center"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toStartOf="parent"
                    app:layout_constraintTop_toBottomOf="@+id/album_name_label" />

                <TextView
                    android:id="@+id/album_release_year_label"
                    style="@style/LabelSmall"
                    android:layout_width="0dp"
                    android:layout_height="wrap_content"
                    android:layout_marginStart="18dp"
                    android:layout_marginEnd="18dp"
                    android:text="@string/label_placeholder"
                    android:textAlignment="center"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toStartOf="parent"
                    app:layout_constraintTop_toBottomOf="@+id/album_artist_label" />

                <androidx.constraintlayout.widget.ConstraintLayout
                    android:id="@+id/album_detail_view"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:animateLayoutChanges="true"
                    android:paddingTop="12dp"
                    android:paddingBottom="8dp"
                    android:visibility="gone"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toStartOf="parent"
                    app:layout_constraintTop_toBottomOf="@+id/album_release_year_label"
                    tools:visibility="visible">

                    <TextView
                        android:id="@+id/album_genres_textview"
                        style="@style/LabelSmall"
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
                        android:layout_marginStart="18dp"
                        android:layout_marginEnd="18dp"
                        android:text="@string/label_placeholder"
                        android:textAlignment="center"
                        android:visibility="gone"
                        app:layout_constraintEnd_toEndOf="parent"
                        app:layout_constraintStart_toStartOf="parent"
                        app:layout_constraintTop_toTopOf="parent"
                        tools:visibility="visible" />

                    <TextView
                        android:id="@+id/album_song_count_duration_textview"
                        style="@style/LabelSmall"
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
                        android:layout_marginStart="18dp"
                        android:layout_marginEnd="18dp"
                        android:paddingVertical="2dp"
                        android:text="@string/label_placeholder"
                        android:textAlignment="center"
                        app:layout_constraintEnd_toEndOf="parent"
                        app:layout_constraintStart_toStartOf="parent"
                        app:layout_constraintTop_toBottomOf="@+id/album_genres_textview" />

                    <TextView
                        android:id="@+id/album_notes_textview"
                        style="@style/LabelSmall"
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
                        android:layout_marginStart="18dp"
                        android:layout_marginEnd="18dp"
                        android:justificationMode="inter_word"
                        android:text="@string/label_placeholder"
                        android:textAlignment="center"
                        app:layout_constraintEnd_toEndOf="parent"
                        app:layout_constraintStart_toStartOf="parent"
                        app:layout_constraintTop_toBottomOf="@+id/album_song_count_duration_textview" />

                    <TextView
                        android:id="@+id/album_release_years_textview"
                        style="@style/LabelSmall"
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
                        android:layout_marginStart="18dp"
                        android:layout_marginEnd="18dp"
                        android:paddingVertical="4dp"
                        android:text="@string/label_placeholder"
                        android:textAlignment="center"
                        android:visibility="gone"
                        app:layout_constraintEnd_toEndOf="parent"
                        app:layout_constraintStart_toStartOf="parent"
                        app:layout_constraintTop_toBottomOf="@+id/album_notes_textview" />

                </androidx.constraintlayout.widget.ConstraintLayout>

                <View
                    android:id="@+id/upper_button_divider"
                    style="@style/Divider"
                    android:layout_marginStart="18dp"
                    android:layout_marginTop="4dp"
                    android:layout_marginEnd="18dp"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toStartOf="parent"
                    app:layout_constraintTop_toBottomOf="@+id/album_detail_view" />

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:gravity="center_vertical"
                    android:orientation="horizontal"
                    android:paddingStart="12dp"
                    android:paddingTop="4dp"
                    android:paddingEnd="12dp"
                    android:paddingBottom="4dp"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toStartOf="parent"
                    app:layout_constraintTop_toBottomOf="@+id/upper_button_divider">

                    <LinearLayout
                        android:id="@+id/album_page_button_layout"
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
                        android:layout_weight="1"
                        android:gravity="center_vertical"
                        android:orientation="horizontal">

                        <Button
                            android:id="@+id/album_page_play_button"
                            android:layout_width="0dp"
                            android:layout_height="wrap_content"
                            android:layout_marginStart="4dp"
                            android:layout_marginEnd="4dp"
                            android:layout_weight="1"
                            android:padding="10dp"
                            android:text="@string/album_page_play_button"
                            android:textAllCaps="false"
                            app:icon="@drawable/ic_play"
                            app:iconGravity="textStart"
                            app:iconPadding="18dp" />

                        <Button
                            android:id="@+id/album_page_shuffle_button"
                            android:layout_width="0dp"
                            android:layout_height="wrap_content"
                            android:layout_marginStart="4dp"
                            android:layout_marginEnd="4dp"
                            android:layout_weight="1"
                            android:padding="10dp"
                            android:text="@string/album_page_shuffle_button"
                            android:textAllCaps="false"
                            app:icon="@drawable/ic_shuffle"
                            app:iconGravity="textStart"
                            app:iconPadding="18dp" />
                    </LinearLayout>

                    <ToggleButton
                        android:id="@+id/button_favorite"
                        android:layout_width="34dp"
                        android:layout_height="34dp"
                        android:layout_marginStart="12dp"
                        android:layout_marginEnd="0dp"
                        android:background="@drawable/button_favorite_selector"
                        android:checked="false"
                        android:foreground="?android:attr/selectableItemBackgroundBorderless"
                        android:gravity="center"
                        android:text=""
                        android:textOff=""
                        android:textOn="" />

                </LinearLayout>

                <TextView
                    android:id="@+id/album_bio_label"
                    style="@style/LabelSmall"
                    android:layout_width="0dp"
                    android:layout_height="wrap_content"
                    android:layout_marginStart="18dp"
                    android:layout_marginEnd="18dp"
                    android:text="@string/label_placeholder"
                    android:textAlignment="center"
                    android:visibility="gone"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toStartOf="parent"
                    app:layout_constraintTop_toBottomOf="@id/album_page_button_layout"
                    tools:ignore="NotSibling" />

                <View
                    android:id="@+id/bottom_button_divider"
                    style="@style/Divider"
                    android:layout_marginStart="18dp"
                    android:layout_marginEnd="18dp"
                    android:layout_marginBottom="18dp"
                    app:layout_constraintEnd_toEndOf="parent"
                    app:layout_constraintStart_toStartOf="parent"
                    app:layout_constraintTop_toBottomOf="@+id/album_bio_label" />
            </androidx.constraintlayout.widget.ConstraintLayout>

        </com.google.android.material.appbar.AppBarLayout>


        <androidx.recyclerview.widget.RecyclerView
            android:id="@+id/song_recycler_view"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_weight="1"
            android:nestedScrollingEnabled="false"
            android:paddingTop="0dp"
            android:paddingBottom="75dp"
            android:clipToPadding="false"
            app:layout_behavior="@string/appbar_scrolling_view_behavior" />

    </LinearLayout>
    </androidx.core.widget.NestedScrollView>
</LinearLayout>