import type { NextConfig } from "next";

const nextConfig: NextConfig = {
  // cPanel deployment configuration
  // Note: Using standard build output (not standalone) for cPanel compatibility
  // If you need to disable image optimization, uncomment below:
  // images: {
  //   unoptimized: true,
  // },
  // Headers for better security and compatibility
  async headers() {
    return [
      {
        source: '/:path*',
        headers: [
          {
            key: 'Cross-Origin-Opener-Policy',
            value: 'same-origin-allow-popups', // Allows popups for Google Sign-In
          },
          {
            key: 'Cross-Origin-Embedder-Policy',
            value: 'unsafe-none', // Allows external resources
          },
        ],
      },
    ];
  },
};

export default nextConfig;
