class AppConstants {
  AppConstants._();

  static const String appName = 'EL3AB';
  static const String packageName = 'com.al-arcade.el3ab';

  // Supabase
  static const String supabaseUrl = 'https://safe-supabase-kong.caprover.al-arcade.com';
  static const String supabaseAnonKey =
      'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJyb2xlIjoiYW5vbiIsImlzcyI6InN1cGFiYXNlIiwiaWF0IjoxNzM1Njg5NjAwLCJleHAiOjE4OTM0NTYwMDB9.31PF6PvP-pSrvRuQwLFptQoejR0W1A7o53lZhEbnz84';

  // Web player URL
  static const String webPlayerUrl = 'https://el3ab-player.caprover.al-arcade.com/';
  static const String webPlayerHost = 'el3ab-player.caprover.al-arcade.com';

  // Allowed domains for WebView navigation
  static const List<String> allowedDomains = [
    // App & backend
    'el3ab-player.caprover.al-arcade.com',
    'al-arcade.com',
    'safe-supabase-kong.caprover.al-arcade.com',
    'stockfishapi.caprover.al-arcade.com',
    'swissapi.caprover.al-arcade.com',
    // Google OAuth
    'accounts.google.com',
    'google.com',
    'googleapis.com',
    'gstatic.com',
    'googleusercontent.com',
    // Apple Sign-In (future)
    'appleid.apple.com',
    'apple.com',
    // Facebook OAuth (future)
    'facebook.com',
    'fbcdn.net',
    // CDN & assets
    'cloudflare.com',
    'cdn.jsdelivr.net',
    'fonts.googleapis.com',
    'fonts.gstatic.com',
    // Payment providers (future)
    'stripe.com',
    'js.stripe.com',
  ];

  // Deep link schemes
  static const String deepLinkScheme = 'el3ab';
  static const String universalLinkHost = 'el3ab-player.caprover.al-arcade.com';

  // Storage keys
  static const String authTokenKey = 'auth_token';
  static const String refreshTokenKey = 'refresh_token';
  static const String userIdKey = 'user_id';
  static const String biometricEnabledKey = 'biometric_enabled';
  static const String onboardingCompleteKey = 'onboarding_complete';
  static const String pushTokenKey = 'push_token';

  // Timeouts
  static const Duration webViewTimeout = Duration(seconds: 30);
  static const Duration backgroundGracePeriod = Duration(minutes: 5);
}
