MHKMarkedia is a global digital growth and marketing agency website engineered from scratch using Next.js 15 App Router, React Server Components (RSC), TypeScript, and Tailwind CSS. As the full-stack developer, I architected and developed the entire web application to deliver sub-second page transitions, 100/100 Core Web Vitals, automated CRM lead capture pipelines, and programmatic schema engineering to maximize client acquisition.
MHKMarkedia required a modern, ultra-fast agency web platform that conveyed high-ticket enterprise credibility while converting cold organic and paid traffic into booked strategy calls. As the sole full-stack developer on the project, I was responsible for the complete development lifecycle—from system architecture and responsive UI component development to backend API pipelines, performance profiling, and production deployment.
Traditional agency websites built on bloated WordPress themes or client-rendered single-page applications suffer from slow initial load times, brittle plugin ecosystems, and poor SEO indexation. I engineered a modern decoupled architecture using Next.js 15 App Router:
To allow the agency to scale its offerings effortlessly across industries (E-Commerce, Healthcare, Real Estate, Legal) and regional service hubs, I engineered a dynamic routing structure with type-safe metadata generation and automatic static route extraction:
// src/app/services/[slug]/page.tsx - Server Component with Static Params
import { notFound } from "next/navigation";
import type { Metadata } from "next";
import { getServiceBySlug, getAllServiceSlugs } from "@/lib/services";
export async function generateStaticParams() {
const slugs = await getAllServiceSlugs();
return slugs.map((slug) => ({ slug }));
}
export async function generateMetadata({
params
}: {
params: Promise<{ slug: string }>
}): Promise<Metadata> {
const { slug } = await params;
const service = await getServiceBySlug(slug);
if (!service) return { title: "Service Not Found" };
return {
title: `${service.title} | MHKMarkedia Digital Engineering`,
description: service.summary,
alternates: { canonical: `https://mhkmarkedia.com/services/${slug}` },
};
}
export default async function ServicePage({
params
}: {
params: Promise<{ slug: string }>
}) {
const { slug } = await params;
const service = await getServiceBySlug(slug);
if (!service) notFound();
return (
<article className="w-full max-w-6xl mx-auto px-4 py-20">
<header className="mb-12">
<span className="text-xs font-mono text-purple-400 uppercase tracking-widest">
{service.category}
</span>
<h1 className="text-4xl sm:text-6xl font-serif text-white mt-3">
{service.title}
</h1>
</header>
<ServiceDetailGrid deliverables={service.deliverables} content={service.body} />
</article>
);
}In the agency sector, a slow website directly undermines technical authority. Every millisecond of delay increases visitor bounce rates. I engineered the frontend to achieve a perfect 100/100 Google Lighthouse score on both mobile and desktop with zero Cumulative Layout Shift (CLS 0.000) and sub-400ms Largest Contentful Paint (LCP).
To eliminate rendering bottlenecks across international network connections, I applied rigorous frontend optimizations:
My production configuration in next.config.ts enforced modern image formats, long-term immutable caching headers, and bundle optimizations:
// next.config.ts - Production Asset Optimization & Compression
import type { NextConfig } from "next";
const nextConfig: NextConfig = {
images: {
formats: ["image/avif", "image/webp"],
minimumCacheTTL: 31536000,
deviceSizes: [640, 750, 828, 1080, 1200, 1920],
},
experimental: {
optimizeCss: true,
optimizePackageImports: ["lucide-react", "framer-motion"],
},
compiler: {
removeConsole: process.env.NODE_ENV === "production",
},
};
export default nextConfig;A world-class agency website must reliably convert traffic into sales pipeline value. I architected a robust, full-stack lead intake system that validates submissions server-side with Zod, blocks bot spam using Cloudflare Turnstile, and dispatches leads immediately into GoHighLevel CRM and team communication channels.
To ensure 100% lead delivery fidelity without relying on fragile third-party WordPress form plugins, I developed a custom Next.js Server Action with multi-destination dispatching:
| Layer | Technical Mechanism | Operational Benefit |
|---|---|---|
| Form Validation | React Hook Form + Server Zod Schema | Instant client feedback + zero unvalidated server execution |
| Bot Mitigation | Cloudflare Turnstile Server Verification | 100% spam elimination without CAPTCHA friction |
| CRM Automation | GoHighLevel HTTPS Webhook Dispatcher | Automated pipeline staging, SMS & email follow-up sequence |
| Sales Notification | Instant Slack/Telegram Webhook Alert | Team notified in real time for <90s lead response time |
The lead processing Server Action ensures airtight validation and resilient webhook delivery:
// src/app/actions/submitLead.ts - Secure Server Action
"use server";
import { z } from "zod";
const leadSchema = z.object({
fullName: z.string().min(2, "Name must be at least 2 characters").max(100),
email: z.string().email("Valid business email required"),
phone: z.string().min(8, "Valid phone number required"),
serviceInterest: z.string().min(1, "Please select a service"),
projectBudget: z.string().optional(),
message: z.string().max(1000).optional(),
turnstileToken: z.string().min(1, "Security verification failed"),
});
export async function submitLead(formData: FormData) {
const raw = Object.fromEntries(formData.entries());
const parsed = leadSchema.safeParse(raw);
if (!parsed.success) {
return { success: false, errors: parsed.error.flatten().fieldErrors };
}
// 1. Verify Cloudflare Turnstile Cryptographic Token
const turnstileSecret = process.env.TURNSTILE_SECRET_KEY!;
const verifyRes = await fetch("https://challenges.cloudflare.com/turnstile/v0/siteverify", {
method: "POST",
headers: { "Content-Type": "application/x-www-form-urlencoded" },
body: new URLSearchParams({
secret: turnstileSecret,
response: parsed.data.turnstileToken,
}),
});
const verifyData = await verifyRes.json();
if (!verifyData.success) {
return { success: false, message: "Security challenge failed. Please retry." };
}
// 2. Dispatch to GoHighLevel CRM Webhook with Attribution Tags
try {
await fetch(process.env.GHL_LEAD_WEBHOOK_URL!, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
...parsed.data,
source: "MHKMarkedia Web Platform",
tags: ["Inbound Lead", parsed.data.serviceInterest],
submittedAt: new Date().toISOString(),
}),
});
return { success: true };
} catch (err) {
console.error("CRM Webhook Error:", err);
return { success: false, message: "Server error. Please contact directly." };
}
}A successful agency platform must dominate organic search. I engineered a programmatic SEO infrastructure including semantic JSON-LD entity graphing, automated XML sitemap generation, and localized schema markup—securing #1 Google Map Pack rankings and top-tier visibility in generative AI search engines.
Rather than superficial meta tags, I built an interconnected schema graph that establishes verified business authority for search crawlers and LLM extraction engines:
// src/components/seo/JsonLdSchema.tsx - Comprehensive Structured Data
export default function JsonLdSchema() {
const schema = {
"@context": "https://schema.org",
"@graph": [
{
"@type": "ProfessionalService",
"@id": "https://mhkmarkedia.com/#organization",
name: "MHKMarkedia",
url: "https://mhkmarkedia.com",
logo: "https://mhkmarkedia.com/images/logo.png",
telephone: "+966500000000",
priceRange: "$$$$",
founder: {
"@type": "Person",
name: "M. Hafeez Khan",
jobTitle: "CEO & Lead Digital Architect",
},
areaServed: [
{ "@type": "Country", name: "Saudi Arabia" },
{ "@type": "Country", name: "United Arab Emirates" },
{ "@type": "Country", name: "United States" },
],
hasOfferCatalog: {
"@type": "OfferCatalog",
name: "Agency Services",
itemListElement: [
{ "@type": "Offer", name: "Custom Web Application Development" },
{ "@type": "Offer", name: "High-Speed Headless E-Commerce" },
{ "@type": "Offer", name: "Local SEO & Google Map Pack Dominance" },
],
},
},
],
};
return (
<script
type="application/ld+json"
dangerouslySetInnerHTML={{ __html: JSON.stringify(schema) }}
/>
);
}The user experience combines clean typography, dark-mode elegance, and high-performance interactive components designed to captivate high-ticket prospects without causing animation stutter or mobile battery drain.
Layered backdrop-blur surfaces with sub-pixel borders and radial lighting that accentuate content depth.
Smooth 60fps partner brand carousel utilizing CSS transform translation, completely bypassing main-thread layout thrashing.
Tailwind CSS dark/light theme switching with custom CSS variables that eliminates flashing of unstyled content upon load.
Spring-physics mobile drawer with touch swipe gestures, accessible focus management, and smooth scroll locking.
High-visibility agency websites face continuous automated brute-force attempts, scraper bots, and injection probes. I implemented comprehensive defense-in-depth across the DNS, edge middleware, and application runtime layers.
| Security Dimension | Threat Vector | Technical Mitigation |
|---|---|---|
| Bot & Scraper Defense | Automated scraper bots & contact form spam | Cloudflare Turnstile token validation + Edge rate limiting |
| XSS & Clickjacking | Cross-site scripting & iframe embedding | Strict Content Security Policy (CSP) + X-Frame-Options: DENY |
| Traffic Spikes & DDoS | Volumetric floods & viral visitor surges | Vercel multi-region serverless auto-scaling + Cloudflare edge CDN |
| Secrets Protection | API key and webhook endpoint leakage | Encrypted environment variables + strict server-only execution boundaries |
I'm available for full-time roles & freelance projects.
I thrive on crafting dynamic web applications and delivering seamless user experiences.