<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
												 xmlns:app="http://schemas.android.com/apk/res-auto"
												 android:id="@+id/main_content"
												 android:layout_width="match_parent"
												 android:layout_height="match_parent"
												 android:fitsSystemWindows="true">

	<com.google.android.material.appbar.AppBarLayout
			android:id="@+id/appbar"
			android:layout_width="match_parent"
			android:layout_height="@dimen/contact_detail_avatar_height"
			android:theme="@style/ThemeOverlay.MaterialComponents.Dark.ActionBar"
			android:importantForAccessibility="no"
			android:fitsSystemWindows="true">

		<com.google.android.material.appbar.CollapsingToolbarLayout
				android:id="@+id/collapsing_toolbar"
				android:layout_width="match_parent"
				android:layout_height="match_parent"
				app:layout_scrollFlags="scroll|exitUntilCollapsed"
				android:fitsSystemWindows="true"
				android:importantForAccessibility="no"
				app:contentScrim="?android:windowBackground">

			<ch.threema.app.ui.AvatarEditView
				android:id="@+id/avatar_edit_view"
				android:layout_width="match_parent"
				android:layout_height="match_parent"
				android:fitsSystemWindows="true"
				android:importantForAccessibility="no"
				android:contentDescription="@string/profile_picture"
				app:layout_collapseMode="parallax"/>

			<LinearLayout
				android:layout_width="match_parent"
				android:layout_height="wrap_content"
				android:layout_marginLeft="16dp"
				android:layout_marginRight="16dp"
				android:layout_marginBottom="32dp"
				android:layout_gravity="bottom|left"
				android:gravity="bottom"
				android:importantForAccessibility="no"
				android:orientation="horizontal"
				>

			<ch.threema.app.ui.HintedImageView
				android:id="@+id/work_icon"
				android:layout_width="30dp"
				android:layout_height="30dp"
				android:layout_marginRight="6dp"
				android:layout_marginBottom="6dp"
				app:srcCompat="@drawable/ic_badge_work"
				android:foreground="@drawable/selector_avatar"
			    android:contentDescription="@string/threema_work_contact"
			    android:visibility="gone"
				/>

			<ch.threema.app.emojis.EmojiTextView
				android:id="@+id/contact_title"
				android:layout_width="match_parent"
				android:layout_height="wrap_content"
				android:textAppearance="@style/Threema.TextAppearance.DetailTitle"
				app:layout_anchor="@id/appbar"
				app:layout_anchorGravity="bottom|left"
				/>

			</LinearLayout>

			<View
				android:layout_width="match_parent"
				android:layout_height="16dp"
				android:layout_gravity="bottom"
				android:background="@drawable/shape_detail"/>

			<androidx.appcompat.widget.Toolbar
					android:id="@+id/toolbar"
					android:layout_width="match_parent"
					android:layout_height="?attr/actionBarSize"
					app:popupTheme="@style/Threema.PopupTheme.TransparentStatusbar"
					app:layout_collapseMode="pin" />

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

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

	<androidx.recyclerview.widget.RecyclerView
			android:id="@+id/contact_group_list"
			android:layout_width="match_parent"
			android:layout_height="match_parent"
			android:importantForAccessibility="no"
			app:layout_behavior="@string/appbar_scrolling_view_behavior">
	</androidx.recyclerview.widget.RecyclerView>

	<com.google.android.material.floatingactionbutton.FloatingActionButton
		android:id="@+id/floating"
		android:layout_height="wrap_content"
		android:layout_width="wrap_content"
		app:fabSize="normal"
		app:layout_anchor="@id/appbar"
		app:layout_anchorGravity="bottom|right|end"
		app:srcCompat="@drawable/ic_pencil_outline"
		android:contentDescription="@string/edit_name_only"
		android:layout_marginRight="@dimen/tablet_standard_padding_left_right"
		android:layout_marginBottom="-42dp"
		app:layout_insetEdge="bottom" />

</androidx.coordinatorlayout.widget.CoordinatorLayout>
