You are an expert full-stack developer. Your task is to build a comprehensive, multi-page web application MVP named 'Paw Finance' using Next.js 14+ App Router, TypeScript, Tailwind CSS, and Drizzle ORM with PostgreSQL. The application must feature full CRUD functionality for its core models, secure user authentication, and a clear, functional user interface. Project Setup: Initialize a Next.js 14+ project using `create-next-app` with TypeScript, Tailwind CSS, and App Router. Configure Drizzle ORM for PostgreSQL. Ensure proper setup for migrations and database connection. Database Schema (Drizzle ORM): Define the following tables with appropriate fields and relationships: 1. `users`: `id` (uuid, primary key, default generated), `email` (string, unique), `password_hash` (string), `created_at` (timestamp, default now), `updated_at` (timestamp, default now). 2. `pets`: `id` (uuid, primary key, default generated), `user_id` (uuid, foreign key to `users.id`), `name` (string), `type` (enum 'dog', 'cat', 'other'), `breed` (string, nullable), `age` (integer, nullable), `health_status` (string, e.g., 'healthy', 'chronic condition', nullable), `activity_level` (enum 'low', 'medium', 'high', nullable), `created_at` (timestamp, default now), `updated_at` (timestamp, default now). 3. `emergency_funds`: `id` (uuid, primary key, default generated), `user_id` (uuid, foreign key to `users.id`, unique - one fund per user), `target_amount` (numeric, default 0), `current_balance` (numeric, default 0), `created_at` (timestamp, default now), `updated_at` (timestamp, default now). 4. `fund_transactions`: `id` (uuid, primary key, default generated), `fund_id` (uuid, foreign key to `emergency_funds.id`), `type` (enum 'deposit', 'withdrawal'), `amount` (numeric), `description` (string, nullable), `transaction_date` (timestamp, default now), `created_at` (timestamp, default now). 5. `insurance_plans` (for mock data comparison): `id` (uuid, primary key, default generated), `provider_name` (string), `plan_name` (string), `monthly_premium` (numeric), `annual_deductible` (numeric), `reimbursement_rate` (numeric, e.g., 0.8 for 80%), `annual_limit` (numeric, nullable), `coverage_details` (text, nullable), `link` (string, nullable). 6. `vet_costs` (community-sourced cost estimates): `id` (uuid, primary key, default generated), `procedure_name` (string), `min_cost` (numeric, nullable), `max_cost` (numeric, nullable), `average_cost` (numeric, nullable), `description` (text, nullable), `submitted_by_user_id` (uuid, foreign key to `users.id`, nullable), `created_at` (timestamp, default now). Authentication: Implement simple email/password authentication (signup, login, logout). You can use a library like `next-auth` or implement a basic session-based approach with cookies. Store `password_hash` securely. Protect routes that require authentication (e.g., `/dashboard`, `/pets`, `/funds`). Core Features & Pages (App Router): 1. Home Page (`/`): Public landing page introducing the app. 2. Auth Pages (`/auth/login`, `/auth/signup`): Forms for user authentication. 3. Dashboard (`/dashboard`): Authenticated user's main hub. Display a summary of pets. Show current emergency fund balance and target. Quick links to other sections. 4. Pet Management (`/pets`): `app/pets/page.tsx`: List all authenticated user's pets. `app/pets/new/page.tsx`: Form to add a new pet. `app/pets/[id]/page.tsx`: View details of a specific pet. `app/pets/[id]/edit/page.tsx`: Form to edit an existing pet's details. API Routes (`/api/pets`): `GET /api/pets`: Get all pets for the authenticated user. `GET /api/pets/[id]`: Get a specific pet. `POST /api/pets`: Create a new pet. `PUT /api/pets/[id]`: Update an existing pet. `DELETE /api/pets/[id]`: Delete a pet. 5. Emergency Fund (`/funds`): `app/funds/page.tsx`: Display the user's emergency fund details, current balance, target, and a list of transactions. `app/funds/deposit/page.tsx`: Form to add a deposit to the fund. `app/funds/withdraw/page.tsx`: Form to record a withdrawal from the fund. API Routes (`/api/funds`): `GET /api/funds`: Get the authenticated user's fund. `POST /api/funds/target`: Update the fund's target amount. `POST /api/funds/transaction`: Record a deposit or withdrawal. 6. Insurance Comparison (`/insurance-compare`): `app/insurance-compare/page.tsx`: Display a list of `insurance_plans` from the database. Allow basic filtering (e.g., by premium range, deductible). Include a link for each plan to simulate external provider redirection. No API for this in MVP (data is static from DB). 7. Vet Cost Database (`/vet-costs`): `app/vet-costs/page.tsx`: List all `vet_costs` entries. `app/vet-costs/add/page.tsx`: Form for authenticated users to submit new `vet_costs` estimates. API Routes (`/api/vet-costs`): `GET /api/vet-costs`: Get all vet cost entries. `POST /api/vet-costs`: Add a new vet cost entry (user-submitted). Technical Requirements: Use Next.js Server Components for data fetching where appropriate (e.g., displaying pet lists, fund overview). Implement Next.js Server Actions or dedicated API routes for all mutations (creating, updating, deleting data). Ensure proper error handling and form validation (client-side and server-side). Apply Tailwind CSS for a clean and responsive UI. All code should be modular, maintainable, and adhere to best practices for Next.js development. Deliverables: A fully functional Next.js application with all specified pages, components, and API routes. Drizzle ORM schema definitions. Basic UI styling with Tailwind CSS. Clear instructions on how to set up the database and run the application.