<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
    xmlns:tools="http://schemas.android.com/tools"
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:id="@+id/userInfoLayout"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:orientation="vertical">

    <com.google.android.material.progressindicator.LinearProgressIndicator
        android:id="@+id/progressBar"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:indeterminate="true"
        android:visibility="gone"
        style="@style/Widget.Material3.LinearProgressIndicator"
        app:indicatorColor="?attr/progressIndicatorColor" />

    <androidx.core.widget.NestedScrollView
        android:orientation="vertical"
        android:background="?attr/primaryBackgroundColor"
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <LinearLayout
            android:padding="@dimen/dimen8dp"
            android:orientation="vertical"
            android:id="@+id/repoInfoLayout"
            android:layout_width="match_parent"
            android:layout_height="wrap_content">

            <com.google.android.material.card.MaterialCardView
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                style="?attr/materialCardViewFilledStyle"
                app:cardElevation="@dimen/dimen0dp">

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:foreground="?android:attr/selectableItemBackground"
                    android:background="?attr/materialCardBackgroundColor"
                    android:padding="@dimen/dimen24dp"
                    android:orientation="vertical">

                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="horizontal"
                        tools:ignore="UseCompoundDrawables">

                         <com.google.android.material.card.MaterialCardView
                             android:layout_width="@dimen/dimen80dp"
                             android:layout_height="@dimen/dimen80dp"
                             style="?attr/materialCardViewFilledStyle"
                             android:layout_marginBottom="@dimen/dimen8dp"
                             app:cardElevation="@dimen/dimen0dp"
                             app:cardCornerRadius="@dimen/dimen40dp">

                            <ImageView
                                android:id="@+id/userAvatar"
                                android:layout_width="match_parent"
                                android:layout_height="match_parent"
                                android:contentDescription="@string/generalImgContentText"
                                android:src="@mipmap/app_logo_round" />

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

                        <LinearLayout
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:paddingStart="@dimen/dimen24dp"
                            android:paddingEnd="@dimen/dimen10dp"
                            android:orientation="vertical">

                            <TextView
                                android:id="@+id/userFullName"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:textColor="?attr/primaryTextColor"
                                android:textIsSelectable="true"
                                android:textSize="@dimen/dimen18sp" />

                            <TextView
                                android:id="@+id/userLogin"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_marginBottom="@dimen/dimen10dp"
                                android:textColor="?attr/primaryTextColor"
                                android:textIsSelectable="true"
                                android:textSize="@dimen/dimen14sp" />

                        </LinearLayout>

                    </LinearLayout>

                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:layout_marginTop="@dimen/dimen20dp"
                        android:layout_marginBottom="@dimen/dimen0dp"
                        android:orientation="horizontal"
                        android:baselineAligned="false">

                        <LinearLayout
                            android:id="@+id/followers_section"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_weight="1"
                            android:gravity="center"
                            android:orientation="vertical">

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:textColor="?attr/primaryTextColor"
                                android:text="@string/profileTabFollowers"
                                android:textSize="@dimen/dimen14sp" />

                            <TextView
                                android:id="@+id/user_followers_count"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:textColor="?attr/primaryTextColor"
                                android:paddingTop="@dimen/dimen6dp"
                                android:textStyle="bold"
                                android:textSize="@dimen/dimen14sp" />

                        </LinearLayout>

                        <LinearLayout
                            android:id="@+id/following_section"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_weight="1"
                            android:gravity="center"
                            android:orientation="vertical">

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:textColor="?attr/primaryTextColor"
                                android:text="@string/profileTabFollowing"
                                android:textSize="@dimen/dimen14sp" />

                            <TextView
                                android:id="@+id/user_following_count"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:textColor="?attr/primaryTextColor"
                                android:paddingTop="@dimen/dimen6dp"
                                android:textStyle="bold"
                                android:textSize="@dimen/dimen14sp" />

                        </LinearLayout>

                        <LinearLayout
                            android:id="@+id/starred_repos_section"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_weight="1"
                            android:gravity="center"
                            android:orientation="vertical">

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:textColor="?attr/primaryTextColor"
                                android:text="@string/starredRepos"
                                android:textSize="@dimen/dimen14sp" />

                            <TextView
                                android:id="@+id/user_starred_repos_count"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:textColor="?attr/primaryTextColor"
                                android:paddingTop="@dimen/dimen6dp"
                                android:textStyle="bold"
                                android:textSize="@dimen/dimen14sp" />

                        </LinearLayout>

                    </LinearLayout>

                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:layout_marginTop="@dimen/dimen32dp"
                        android:orientation="horizontal">

                        <ImageView
                            android:layout_gravity="center"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:contentDescription="@string/generalImgContentText"
                            app:srcCompat="@drawable/ic_email" />

                        <LinearLayout
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:layout_marginStart="@dimen/dimen16dp"
                            android:gravity="center_vertical"
                            android:orientation="vertical">

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text="@string/userEmail"
                                android:textColor="?attr/primaryTextColor"
                                android:textSize="@dimen/dimen16sp" />

                            <TextView
                                android:id="@+id/userEmail"
                                android:layout_width="match_parent"
                                android:layout_height="wrap_content"
                                android:alpha="0.9"
                                android:textColor="?attr/primaryTextColor"
                                android:textSize="@dimen/dimen14sp" />
                        </LinearLayout>

                    </LinearLayout>

                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:layout_marginTop="@dimen/dimen32dp"
                        android:orientation="horizontal">

                            <ImageView
                                android:layout_gravity="center"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:contentDescription="@string/generalImgContentText"
                                app:srcCompat="@drawable/ic_language"/>

                            <LinearLayout
                                android:layout_width="match_parent"
                                android:layout_height="wrap_content"
                                android:layout_marginStart="@dimen/dimen16dp"
                                android:gravity="center_vertical"
                                android:orientation="vertical">

                                <TextView
                                    android:layout_width="wrap_content"
                                    android:layout_height="wrap_content"
                                    android:text="@string/settingsLanguageSelectorHeader"
                                    android:textColor="?attr/primaryTextColor"
                                    android:textSize="@dimen/dimen16sp" />

                                <TextView
                                    android:id="@+id/userLang"
                                    android:layout_width="match_parent"
                                    android:layout_height="wrap_content"
                                    android:alpha="0.9"
                                    android:textColor="?attr/primaryTextColor"
                                    android:textSize="@dimen/dimen14sp" />
                            </LinearLayout>

                        </LinearLayout>

                        <LinearLayout
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:layout_marginTop="@dimen/dimen32dp"
                            android:orientation="horizontal">

                            <ImageView
                                android:layout_gravity="center"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:contentDescription="@string/generalImgContentText"
                                app:srcCompat="@drawable/ic_calendar"/>

                            <LinearLayout
                                android:layout_width="match_parent"
                                android:layout_height="wrap_content"
                                android:layout_marginStart="@dimen/dimen16dp"
                                android:gravity="center_vertical"
                                android:orientation="vertical">

                                <TextView
                                    android:layout_width="wrap_content"
                                    android:layout_height="wrap_content"
                                    android:text="@string/joined"
                                    android:textColor="?attr/primaryTextColor"
                                    android:textSize="@dimen/dimen16sp" />

                                <TextView
                                    android:id="@+id/userJoinedOn"
                                    android:layout_width="match_parent"
                                    android:layout_height="wrap_content"
                                    android:alpha="0.9"
                                    android:textColor="?attr/primaryTextColor"
                                    android:textSize="@dimen/dimen14sp" />
                            </LinearLayout>

                        </LinearLayout>

                </LinearLayout>

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

            <com.google.android.material.card.MaterialCardView
                android:id="@+id/profile_repo_view"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                style="?attr/materialCardViewFilledStyle"
                app:cardElevation="@dimen/dimen0dp"
                android:layout_marginTop="@dimen/dimen8dp"
                android:visibility="gone">

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:foreground="?android:attr/selectableItemBackground"
                    android:background="?attr/materialCardBackgroundColor"
                    android:padding="@dimen/dimen24dp"
                    android:orientation="vertical">

                    <TextView
                        android:id="@+id/profile_repo_content"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:textIsSelectable="true"
                        android:textSize="@dimen/dimen16sp"
                        android:textColor="?attr/primaryTextColor" />

                    <androidx.recyclerview.widget.RecyclerView
                        android:id="@+id/profile_repo_content1"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:textIsSelectable="true"
                        android:textSize="@dimen/dimen16sp"
                        android:visibility="gone"
                        android:textColor="?attr/primaryTextColor" />

                </LinearLayout>

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

        </LinearLayout>

    </androidx.core.widget.NestedScrollView>

</LinearLayout>
