<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:background="@color/white_bg">

    <ScrollView
        android:layout_above="@id/set_pin"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:overScrollMode="never">

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

            <ImageView
                android:id="@+id/back_btn"
                android:layout_width="35sp"
                android:layout_height="35sp"
                android:layout_margin="15dp"
                android:contentDescription="@string/back_button"
                android:padding="5dp"
                android:paddingStart="-15dp"
                android:paddingEnd="0dp"
                android:src="@drawable/arrow_back" />

            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginHorizontal="15dp"
                android:layout_marginTop="20dp"
                android:layout_marginBottom="5dp"
                android:fontFamily="@font/nunito_medium"
                android:text="@string/create_a_pin"
                android:textSize="@dimen/_18ssp"
                android:textColor="@color/black" />

            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginHorizontal="15dp"
                android:layout_marginVertical="5dp"
                android:fontFamily="@font/nunito_regular"
                android:text="@string/create_a_pin_to_securely_store_your_personal_data"
                android:textSize="@dimen/_16ssp"
                android:textColor="@color/black" />

            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/set_4_digit_login_pin"
                android:layout_gravity="start"
                android:layout_marginTop="50dp"
                android:layout_marginHorizontal="15dp"
                android:fontFamily="@font/nunito_medium"
                android:textSize="@dimen/_16ssp"
                android:textColor="@color/black"
                />

            <com.google.android.material.textfield.TextInputLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginHorizontal="15dp"
                android:layout_marginVertical="15dp"

                app:hintEnabled="false"
                app:expandedHintEnabled="false"
                app:hintAnimationEnabled="false"

                android:background="@android:color/transparent"

                app:boxStrokeWidth="0dp"
                app:boxStrokeWidthFocused="0dp"
                app:passwordToggleDrawable="@drawable/password_toggle"
                app:passwordToggleEnabled="true"
                >

                <com.google.android.material.textfield.TextInputEditText
                    android:id="@+id/pin"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:background="@drawable/edit_text_bg_2"

                    android:hint="@string/set_4_digit_login_pin"
                    android:paddingVertical="15sp"
                    android:paddingHorizontal="10dp"
                    android:fontFamily="@font/nunito_regular"
                    android:textColor="@color/black"
                    android:textColorHint="#5B5B5B"

                    android:textAppearance="@style/TextAppearance.Material3.TitleMedium"

                    android:drawableStart="@drawable/ic_lock_outline"
                    android:drawablePadding="20dp"

                    android:autofillHints="password"
                    android:inputType="numberPassword"
                    android:maxLines="1"
                    android:maxLength="4"

                    android:nextFocusDown="@id/confirm_pin"
                    />

            </com.google.android.material.textfield.TextInputLayout>

            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="@string/confirm_pin"
                android:layout_gravity="start"
                android:layout_marginHorizontal="15dp"
                android:layout_marginTop="15dp"
                android:fontFamily="@font/nunito_medium"
                android:textSize="@dimen/_16ssp"
                android:textColor="@color/black"
                />

            <com.google.android.material.textfield.TextInputLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginHorizontal="15dp"
                android:layout_marginVertical="15dp"

                app:hintEnabled="false"
                app:expandedHintEnabled="false"
                app:hintAnimationEnabled="false"

                android:background="@android:color/transparent"

                app:boxStrokeWidth="0dp"
                app:boxStrokeWidthFocused="0dp"
                app:passwordToggleDrawable="@drawable/password_toggle"
                app:passwordToggleEnabled="true"
                >

                <com.google.android.material.textfield.TextInputEditText
                    android:id="@+id/confirm_pin"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:background="@drawable/edit_text_bg_2"

                    android:hint="@string/confirm_your_pin"
                    android:paddingVertical="15sp"
                    android:paddingHorizontal="10dp"
                    android:fontFamily="@font/nunito_regular"
                    android:textColor="@color/black"
                    android:textColorHint="#5B5B5B"

                    android:textAppearance="@style/TextAppearance.Material3.TitleMedium"

                    android:drawableStart="@drawable/ic_lock_outline"
                    android:drawablePadding="20dp"

                    android:autofillHints="password"
                    android:inputType="numberPassword"
                    android:maxLines="1"
                    android:maxLength="4"
                    />

            </com.google.android.material.textfield.TextInputLayout>

        </LinearLayout>

    </ScrollView>

    <com.google.android.material.button.MaterialButton
        android:id="@+id/set_pin"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginVertical="25dp"
        android:layout_marginHorizontal="15dp"
        android:backgroundTint="@color/color_primary"
        android:layout_marginTop="50dp"
        android:text="@string/set_pin"
        android:textColor="@color/white_bg"
        android:textAppearance="@style/TextAppearance.Material3.TitleMedium"
        android:textAllCaps="false"
        android:paddingVertical="15dp"
        app:cornerRadius="10dp"

        android:layout_alignParentBottom="true"

        />

</RelativeLayout>