<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout 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="wrap_content"
    android:padding="16dp">

    <!-- Back Button -->
    <ImageButton
        android:id="@+id/backButton"
        android:layout_width="24dp"
        android:layout_height="24dp"
        android:layout_marginEnd="20dp"
        android:background="?android:attr/selectableItemBackground"
        android:src="@drawable/ic_arrow_back"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        android:contentDescription="Back" />

    <!-- Chat Avatar -->
    <ImageView
        android:id="@+id/chatAvatarImageView"
        android:layout_width="32dp"
        android:layout_height="32dp"
        android:layout_marginStart="8dp"
        android:layout_marginEnd="20dp"
        android:background="@drawable/circle_background"
        android:scaleType="centerCrop"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintStart_toEndOf="@id/backButton"
        app:layout_constraintTop_toTopOf="parent"
        tools:srcCompat="@tools:sample/avatars" />

    <!-- Chat Name -->
    <TextView
        android:id="@+id/chatNameTextView"
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_marginStart="8dp"
        android:ellipsize="end"
        android:maxLines="1"
        android:textColor="@color/white"
        android:textSize="18sp"
        android:textStyle="bold"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toEndOf="@id/chatAvatarImageView"
        app:layout_constraintTop_toTopOf="parent"
        tools:text="John Doe" />

</androidx.constraintlayout.widget.ConstraintLayout>
