<?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/parent_layout"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="?android:attr/colorBackground">

    <com.google.android.material.appbar.AppBarLayout
        android:id="@+id/appbar"
        android:layout_width="match_parent"
        android:layout_height="wrap_content">

        <FrameLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content">

            <com.google.android.material.appbar.MaterialToolbar
                android:id="@+id/material_toolbar"
                style="@style/Threema.ToolbarStyle"
                android:layout_width="match_parent"
                android:layout_height="?attr/actionBarSize"
                app:title="@string/problemsolver_title"
                app:navigationIcon="?attr/homeAsUpIndicator" />

            <include layout="@layout/connection_indicator"/>

        </FrameLayout>

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

    <androidx.core.widget.NestedScrollView
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:padding="16dp"
        app:layout_behavior="@string/appbar_scrolling_view_behavior">

        <androidx.constraintlayout.widget.ConstraintLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content">

            <TextView
                android:id="@+id/intro_text"
                style="@style/Threema.TextAppearance.BodyLarge"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/problemsolver_intro"
                app:layout_constraintTop_toTopOf="parent"
                app:layout_constraintStart_toStartOf="parent"
                app:layout_constraintEnd_toEndOf="parent"
                />

            <LinearLayout
                android:id="@+id/problems_parent"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="vertical"
                app:layout_constraintTop_toBottomOf="@+id/intro_text"
                app:layout_constraintStart_toStartOf="parent"
                app:layout_constraintEnd_toEndOf="parent" />

            <ImageView
                android:id="@+id/info_icon"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginTop="16dp"
                app:srcCompat="@drawable/ic_info_outline"
                app:tint="?attr/colorOnBackground"
                app:layout_constraintTop_toBottomOf="@+id/problems_parent"
                app:layout_constraintStart_toStartOf="parent"
                />

            <TextView
                style="@style/Threema.TextAppearance.BodyMedium"
                android:id="@+id/info_text"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginTop="16dp"
                android:text="@string/problemsolver_info_text"
                app:layout_constraintTop_toBottomOf="@+id/info_icon"
                app:layout_constraintStart_toStartOf="parent"
                app:layout_constraintEnd_toEndOf="parent"
                app:layout_constraintBottom_toBottomOf="parent"/>

        </androidx.constraintlayout.widget.ConstraintLayout>

    </androidx.core.widget.NestedScrollView>

</androidx.coordinatorlayout.widget.CoordinatorLayout>
