<?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"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@color/background"
    android:orientation="vertical">

    <!-- Header -->
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="@color/primary"
        android:gravity="center"
        android:orientation="vertical"
        android:padding="24dp">

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="Permissions Setup"
            android:textColor="@android:color/white"
            android:textSize="22sp"
            android:textStyle="bold" />

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_marginTop="4dp"
            android:text="Enable all required permissions"
            android:textColor="@android:color/white"
            android:textSize="14sp" />

        <!-- Progress -->
        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="16dp"
            android:gravity="center"
            android:orientation="vertical">

            <TextView
                android:id="@+id/tvProgress"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="0 / 10 Permissions Completed"
                android:textColor="@android:color/white"
                android:textSize="14sp"
                android:textStyle="bold" />

            <ProgressBar
                android:id="@+id/progressBar"
                style="?android:attr/progressBarStyleHorizontal"
                android:layout_width="match_parent"
                android:layout_height="12dp"
                android:layout_marginTop="8dp"
                android:max="10"
                android:progress="0"
                android:progressBackgroundTint="#80FFFFFF"
                android:progressTint="@color/success" />
        </LinearLayout>
    </LinearLayout>

    <!-- Permissions List -->
    <androidx.core.widget.NestedScrollView
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:layout_weight="1"
        android:padding="16dp">

        <LinearLayout
            android:id="@+id/permissionsContainer"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical" />
    </androidx.core.widget.NestedScrollView>

    <!-- Bottom Button -->
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="@android:color/white"
        android:elevation="8dp"
        android:padding="16dp">

        <com.google.android.material.button.MaterialButton
            android:id="@+id/btnComplete"
            style="@style/RoundedButton"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:enabled="false"
            android:text="Complete Setup" />
    </LinearLayout>

</LinearLayout>
