/**
 * Auth Group Layout
 *
 * Layout for authenticated screens with header navigation.
 */

import { Stack } from 'expo-router';
import { useSafeAreaInsets } from 'react-native-safe-area-context';

export default function AuthLayout() {
  const insets = useSafeAreaInsets();

  return (
    <Stack
      screenOptions={{
        headerStyle: {
          backgroundColor: '#2563eb',
        },
        headerTintColor: '#fff',
        headerTitleStyle: {
          fontWeight: 'bold',
        },
        // Ensure header accounts for status bar on Android
        headerStatusBarHeight: insets.top,
      }}
    >
      <Stack.Screen
        name="jobs"
        options={{
          headerShown: false,
        }}
      />
      <Stack.Screen
        name="job/[id]"
        options={{
          title: 'Job Details',
        }}
      />
    </Stack>
  );
}
