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

    <androidx.cardview.widget.CardView
        android:id="@+id/card_view"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_gravity="center"
        android:layout_margin="6dp"
        android:layout_marginStart="10dp"
        android:layout_marginEnd="10dp"
        card_view:cardCornerRadius="8dp">

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

            <androidx.constraintlayout.widget.ConstraintLayout
                android:id="@+id/header"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="horizontal"
                android:paddingStart="14dp"
                android:paddingTop="16dp"
                android:paddingBottom="16dp"
                android:paddingEnd="14dp">

                <ImageView
                    android:id="@+id/logoKompetisi"
                    android:layout_width="50dp"
                    android:layout_height="50dp"
                    card_view:layout_constraintTop_toTopOf="parent"
                    card_view:layout_constraintLeft_toLeftOf="parent"
                    card_view:layout_constraintBottom_toBottomOf="parent"
                    android:src="@drawable/icon_dashboard" />

                <LinearLayout
                    android:id="@+id/compInfo"
                    android:layout_width="wrap_content"
                    android:layout_height="match_parent"
                    card_view:layout_constraintTop_toTopOf="parent"
                    card_view:layout_constraintLeft_toRightOf="@id/logoKompetisi"
                    android:layout_marginStart="12dp"
                    android:orientation="vertical">

                    <TextView
                        android:id="@+id/namaKompetisi"
                        android:layout_width="190dp"
                        android:layout_height="wrap_content"
                        android:layout_marginBottom="10dp"
                        android:ellipsize="marquee"
                        android:marqueeRepeatLimit="marquee_forever"
                        android:scrollHorizontally="true"
                        android:singleLine="true"
                        android:text="Sample Nama Kompetisi"
                        android:textSize="15sp"
                        android:textStyle="bold" />

                    <TextView
                        android:id="@+id/dateEvent"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="1 Jan 2020 - 31 Dec 2020 (Sample)"
                        android:textSize="12sp" />

                </LinearLayout>

                <LinearLayout
                    android:id="@+id/poinPeriodLayout"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    card_view:layout_constraintTop_toTopOf="parent"
                    card_view:layout_constraintBottom_toBottomOf="parent"
                    card_view:layout_constraintRight_toRightOf="parent"
                    android:layout_gravity="center_vertical"
                    >

                    <ImageView
                        android:layout_width="15dp"
                        android:layout_height="15dp"
                        android:layout_gravity="center"
                        android:src="@drawable/coin_icon" />

                    <TextView
                        android:id="@+id/poinPeriod"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:layout_gravity="center"
                        android:text="273"
                        android:textAppearance="?attr/textAppearanceListItem"
                        android:textSize="15sp" />
                </LinearLayout>

            </androidx.constraintlayout.widget.ConstraintLayout>

            <View
                android:layout_width="match_parent"
                android:layout_height="1dp"
                android:layout_marginLeft="14dp"
                android:layout_marginRight="14dp"
                android:layout_marginBottom="15dp"
                android:background="@android:color/darker_gray" />

            <LinearLayout
                android:id="@+id/body"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginLeft="14dp"
                android:layout_marginRight="14dp"
                android:orientation="vertical">

                <TextView
                    android:id="@+id/labelRank"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_marginRight="8dp"
                    android:layout_marginBottom="10dp"
                    android:text="Rank (29 April 2020)"
                    android:textAppearance="?attr/textAppearanceListItem"
                    android:textSize="12sp" />

                <GridView
                    android:id="@+id/gridview"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_marginBottom="14dp"
                    android:columnWidth="80dp"
                    android:horizontalSpacing="10dp"
                    android:numColumns="auto_fit"
                    android:stretchMode="none"
                    android:verticalSpacing="20dp" />

            </LinearLayout>
        </LinearLayout>
    </androidx.cardview.widget.CardView>
</LinearLayout>
