<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@drawable/modal_bg"
    android:orientation="vertical">

    <View
        android:id="@+id/fakeStatusBar"
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:background="@color/silabs_redtheme_status_bar_color" />

    <View
        android:layout_width="match_parent"
        android:layout_height="@dimen/matter_1dp"
        android:background="@color/grey" />

    <com.google.android.material.appbar.MaterialToolbar
        android:id="@+id/toolbar"
        android:layout_width="match_parent"
        android:layout_height="?attr/actionBarSize"
        android:background="@color/silabs_redtheme_tool_bar_color"
        android:minHeight="?attr/actionBarSize"
        android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
        app:navigationIconTint="@color/silabs_white"
        app:titleCentered="true"
        app:titleTextAppearance="@style/TextAppearance.ToolbarTitle"
        app:titleTextColor="@color/silabs_white"
        tools:title="@string/title_Blinky" />

    <ScrollView
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:layout_weight="1"
        android:fillViewport="true"
        android:overScrollMode="never">

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:padding="@dimen/blinky_tb_content_padding">

            <com.google.android.material.card.MaterialCardView
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                app:cardBackgroundColor="@color/silabs_white"
                app:cardCornerRadius="@dimen/blinky_tb_card_corner_radius"
                app:cardElevation="@dimen/blinky_tb_card_elevation">

                <RelativeLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:paddingHorizontal="16dp"
                    android:paddingVertical="14dp">

                    <TextView
                        android:id="@+id/textview_menu_title3"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:layout_centerVertical="true"
                        android:layout_marginStart="4dp"
                        android:fontFamily="@font/stolzl_medium"
                        android:text="@string/blinky_tb_switch_status"
                        android:textColor="@color/silabs_redtheme_scanner_header_text_color"
                        android:textSize="@dimen/text_size_ML" />

                    <LinearLayout
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:layout_alignParentEnd="true"
                        android:layout_centerVertical="true"
                        android:orientation="horizontal">

                        <com.siliconlabs.bledemo.features.demo.thunderboard_demos.demos.blinky_thunderboard.control.SwitchControl
                            android:id="@+id/switch_0"
                            android:layout_width="@dimen/space_L"
                            android:layout_height="wrap_content"
                            android:layout_marginEnd="@dimen/space_XS" />

                        <com.siliconlabs.bledemo.features.demo.thunderboard_demos.demos.blinky_thunderboard.control.SwitchControl
                            android:id="@+id/switch_1"
                            android:layout_width="@dimen/space_L"
                            android:layout_height="wrap_content" />
                    </LinearLayout>
                </RelativeLayout>
            </com.google.android.material.card.MaterialCardView>

            <com.google.android.material.card.MaterialCardView
                android:id="@+id/leds_control"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginTop="@dimen/blinky_tb_card_spacing"
                app:cardBackgroundColor="@color/silabs_white"
                app:cardCornerRadius="@dimen/blinky_tb_card_corner_radius"
                app:cardElevation="@dimen/blinky_tb_card_elevation">

                <RelativeLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:paddingHorizontal="16dp"
                    android:paddingVertical="14dp">

                    <TextView
                        android:id="@+id/lightsTitle"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:layout_centerVertical="true"
                        android:layout_marginStart="4dp"
                        android:fontFamily="@font/stolzl_medium"
                        android:text="@string/blinky_tb_leds"
                        android:textColor="@color/silabs_redtheme_scanner_header_text_color"
                        android:textSize="@dimen/text_size_ML" />

                    <LinearLayout
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:layout_alignParentEnd="true"
                        android:layout_centerVertical="true"
                        android:orientation="horizontal">

                        <androidx.appcompat.widget.SwitchCompat
                            android:id="@+id/led_0"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_gravity="center"
                            android:minWidth="32dp"
                            android:padding="0dp"
                            android:layout_marginStart="@dimen/matter_5dp"
                            android:thumb="@drawable/sw_thumb"
                            app:splitTrack="false"
                            app:switchMinWidth="32dp"
                            app:track="@drawable/sw_track"  />

                        <androidx.appcompat.widget.SwitchCompat
                            android:id="@+id/led_1"
                            android:layout_marginStart="@dimen/matter_15dp"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_gravity="center"
                            android:minWidth="32dp"
                            android:padding="0dp"
                            android:thumb="@drawable/sw_thumb"
                            app:splitTrack="false"
                            app:switchMinWidth="32dp"
                            app:track="@drawable/sw_track"  />
                    </LinearLayout>
                </RelativeLayout>
            </com.google.android.material.card.MaterialCardView>

            <com.siliconlabs.bledemo.features.demo.thunderboard_demos.demos.blinky_thunderboard.control.ColorLEDControl
                android:id="@+id/color_led_control"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginTop="@dimen/blinky_tb_card_spacing" />
        </LinearLayout>
    </ScrollView>
</LinearLayout>
