<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout 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"
    xmlns:tools="http://schemas.android.com/tools">

    <androidx.constraintlayout.widget.ConstraintLayout
        android:id="@+id/clRule"
        app:layout_constraintTop_toTopOf="@+id/clRedEnvelope"
        android:background="@drawable/shape_161722_top_20"
        app:layout_constraintBottom_toBottomOf="@+id/clRedEnvelope"
        android:visibility="invisible"
        android:layout_width="match_parent"
        android:layout_height="0dp">

        <com.swago.baseswago.cusview.MediumTextView
            android:id="@+id/tvRuleTitle"
            android:textSize="16dp"
            android:textColor="#fff"
            android:text="@string/red_envelope_rule"
            android:layout_marginTop="9dp"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintTop_toTopOf="parent"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"/>

        <ImageView
            android:id="@+id/ivBack"
            android:layout_marginStart="16dp"
            android:layout_marginTop="10dp"
            android:src="@mipmap/back_white"
            app:layout_constraintTop_toTopOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            android:layout_width="20dp"
            android:layout_height="20dp"/>


        <androidx.core.widget.NestedScrollView
            android:layout_marginTop="16dp"
            app:layout_constraintTop_toBottomOf="@+id/ivBack"
            app:layout_constraintBottom_toBottomOf="parent"
            android:layout_width="match_parent"
            android:layout_height="0dp">

            <TextView
                android:id="@+id/tvRule"
                android:textSize="12dp"
                android:textColor="#D4FFFFFF"
                android:layout_marginStart="16dp"
                android:layout_marginEnd="16dp"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"/>

        </androidx.core.widget.NestedScrollView>


    </androidx.constraintlayout.widget.ConstraintLayout>


    <androidx.constraintlayout.widget.ConstraintLayout
        android:id="@+id/clRedEnvelope"
        android:visibility="visible"
        android:background="@drawable/shape_161722_top_20"
        app:layout_constraintBottom_toBottomOf="parent"
        android:layout_width="match_parent"
        android:layout_height="wrap_content">


        <com.swago.baseswago.cusview.MediumTextView
            android:id="@+id/tvTitle"
            android:textSize="16dp"
            android:textColor="#fff"
            android:text="@string/red_envelope"
            android:layout_marginTop="9dp"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintTop_toTopOf="parent"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"/>

        <ImageView
            android:id="@+id/ivHelp"
            android:layout_marginEnd="16dp"
            android:layout_marginTop="10dp"
            android:src="@mipmap/icon_help"
            app:layout_constraintTop_toTopOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            android:layout_width="20dp"
            android:layout_height="20dp"/>

        <TextView
            android:id="@+id/tvSum"
            android:text="@string/coin_sum"
            android:textColor="#99FFFFFF"
            android:layout_marginStart="16dp"
            android:layout_marginTop="64dp"
            app:layout_constraintTop_toTopOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"/>

        <androidx.appcompat.widget.AppCompatEditText
            android:id="@+id/etInputCoin"
            app:layout_constraintTop_toBottomOf="@+id/tvSum"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            android:layout_marginTop="7dp"
            android:layout_marginStart="16dp"
            android:layout_marginEnd="16dp"
            android:paddingStart="12dp"
            android:textSize="14dp"
            android:textColor="#fff"
            android:inputType="number"
            android:textColorHint="#99FFFFFF"
            android:hint="@string/not_less_coin"
            android:gravity="center_vertical"
            android:drawablePadding="8dp"
            android:drawableStart="@mipmap/icon_envelope_num"
            android:background="@drawable/shape_1affffff_all_12"
            android:layout_width="0dp"
            android:layout_height="48dp"/>

        <TextView
            android:id="@+id/tvEnvelope"
            android:text="@string/red_envelope_num"
            android:textColor="#99FFFFFF"
            android:layout_marginStart="16dp"
            android:layout_marginTop="16dp"
            app:layout_constraintTop_toBottomOf="@+id/etInputCoin"
            app:layout_constraintStart_toStartOf="parent"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"/>

        <androidx.appcompat.widget.AppCompatEditText
            android:id="@+id/etInputCount"
            app:layout_constraintTop_toBottomOf="@+id/tvEnvelope"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            android:layout_marginTop="7dp"
            android:layout_marginStart="16dp"
            android:layout_marginEnd="16dp"
            android:paddingStart="12dp"
            android:textSize="14dp"
            android:textColor="#fff"
            android:inputType="number"
            android:textColorHint="#99FFFFFF"
            android:hint="@string/at_last_red_num"
            android:gravity="center_vertical"
            android:drawablePadding="8dp"
            android:drawableStart="@mipmap/icon_person_num"
            android:background="@drawable/shape_1affffff_all_12"
            android:layout_width="0dp"
            android:layout_height="48dp"/>


        <TextView
            android:id="@+id/tvDescribe"
            android:text="@string/broadcast_red_envelope"
            android:textColor="#99FFFFFF"
            android:layout_marginStart="16dp"
            android:layout_marginEnd="16dp"
            android:layout_marginTop="16dp"
            app:layout_constraintTop_toBottomOf="@+id/etInputCount"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            android:layout_width="0dp"
            android:layout_height="wrap_content"/>

        <TextView
            android:id="@+id/tvNotEnough"
            app:layout_constraintTop_toBottomOf="@+id/tvDescribe"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            android:layout_marginTop="20dp"
            android:textSize="12dp"
            android:textColor="#FFD917"
            android:text="@string/not_enough_coin"
            android:visibility="gone"
            tools:visibility="visible"
            android:drawableStart="@mipmap/icon_red_envelope_not_enough_coin"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"/>


        <com.swago.baseswago.cusview.BoldTextView
            android:id="@+id/tvSendRedEnvelope"
            android:text="@string/send_red_envelope"
            android:textColor="#fff"
            android:textSize="16dp"
            android:gravity="center"
            android:layout_marginBottom="25dp"
            android:background="@drawable/shape_80ff56b7_all_38"
            android:layout_marginStart="15dp"
            android:layout_marginEnd="15dp"
            app:layout_constraintTop_toBottomOf="@+id/tvNotEnough"
            android:layout_marginTop="15dp"
            app:layout_constraintBottom_toBottomOf="parent"
            android:layout_width="match_parent"
            android:layout_height="44dp"/>

    </androidx.constraintlayout.widget.ConstraintLayout>


</androidx.constraintlayout.widget.ConstraintLayout>