<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="vertical"
        android:background="@color/background_grey">

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="56dp"
            android:background="@color/primary_dark"
            android:gravity="center_vertical"
            android:paddingStart="16dp"
            android:paddingEnd="16dp"
            android:orientation="horizontal">

            <TextView
                android:id="@+id/tvMode"
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_weight="1"
                android:text="Add Service"
                android:textColor="@color/white"
                android:textSize="20sp"
                android:textStyle="bold" />

            <Button
                android:id="@+id/btnDeleteService"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginStart="8dp"
                android:backgroundTint="@color/accent_coral"
                android:text="Delete"
                android:textColor="@color/white" />

        </LinearLayout>

        <ScrollView
            android:layout_width="match_parent"
            android:layout_height="0dp"
            android:layout_weight="1">

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

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:orientation="vertical"
                    android:background="@drawable/rounded_card"
                    android:padding="16dp"
                    android:layout_marginBottom="16dp">

                    <TextView
                        android:id="@+id/tvServiceId"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="ID: #0"
                        android:textColor="@color/text_light"
                        android:textSize="11sp"
                        android:textStyle="italic"
                        android:layout_gravity="end"
                        android:layout_marginBottom="8dp"/>

                    <TextView
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="Service Name"
                        android:textColor="@color/text_dark"
                        android:textSize="12sp"
                        android:layout_marginBottom="4dp"/>

                    <EditText
                        android:id="@+id/etServiceName"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:hint="Enter service name"
                        android:inputType="text"
                        android:layout_marginBottom="16dp"
                        android:textColor="@color/text_dark"/>

                    <TextView
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="Description"
                        android:textColor="@color/text_dark"
                        android:textSize="12sp"
                        android:layout_marginBottom="4dp"/>

                    <EditText
                        android:id="@+id/etServiceDesc"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:layout_marginBottom="16dp"
                        android:hint="Enter description"
                        android:inputType="textMultiLine"
                        android:minLines="1"
                        android:textColor="@color/text_dark"/>

                    <TextView
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="Duration (minutes)"
                        android:textColor="@color/text_dark"
                        android:textSize="12sp"
                        android:layout_marginBottom="4dp"/>

                    <EditText
                        android:id="@+id/etServiceDuration"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:hint="Enter duration in minutes"
                        android:inputType="number"
                        android:layout_marginBottom="16dp"
                        android:textColor="@color/text_dark"/>

                    <TextView
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="Price"
                        android:textColor="@color/text_dark"
                        android:textSize="12sp"
                        android:layout_marginBottom="4dp"/>

                    <EditText
                        android:id="@+id/etServicePrice"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:hint="Enter price"
                        android:inputType="numberDecimal"
                        android:textColor="@color/text_dark"/>

                </LinearLayout>

            </LinearLayout>

        </ScrollView>

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="horizontal"
            android:background="@color/white"
            android:padding="16dp">

            <Button
                android:id="@+id/btnBack"
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_weight="1"
                android:layout_marginEnd="8dp"
                android:text="Back"
                android:backgroundTint="@color/primary_medium"
                android:textColor="@color/white"/>

            <Button
                android:id="@+id/btnSaveService"
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_weight="1"
                android:layout_marginStart="8dp"
                android:text="Save"
                android:backgroundTint="@color/accent_coral"
                android:textColor="@color/white"/>

        </LinearLayout>

    </LinearLayout>

    <ProgressBar
        android:id="@+id/progressBar"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="center"
        android:visibility="gone"
        android:indeterminateTint="@color/accent_coral"/>

</FrameLayout>