A modern, responsive website for Hanzo AI built with React, TypeScript, and Tailwind CSS.
The project follows a component-based architecture with the following structure:
src/
├── components/ # React components
│ ├── ui/ # UI components (buttons, cards, etc.)
│ ├── platform/ # Platform-specific components
│ ├── cloud/ # Cloud-specific components
│ └── index3/ # Homepage components
├── constants/ # Constants and configuration
├── hooks/ # React hooks
├── lib/ # Utility functions
└── pages/ # Page components
- We use a consistent typographic scale across all pages
- Main headings:
text-5xl md:text-6xl lg:text-7xl
withfont-bold tracking-tight
- Secondary headings:
text-3xl md:text-5xl
withfont-bold
- Body text:
text-lg
for normal text,text-xl
for emphasized text - Every page should have a pre-heading with the format:
<span className="inline-block px-4 py-1 rounded-full bg-purple-900/30 border border-purple-500/30 text-purple-300 text-sm font-medium"> AI Engineering Platform </span>
- Every section should have consistent vertical padding:
py-32
- Use a max-width container for content:
max-w-7xl mx-auto
- Maintain consistent horizontal padding with:
px-4 sm:px-6 lg:px-8
- Use the grid system with responsive breakpoints:
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
- Always include sufficient whitespace between sections (min 8rem)
All hero sections should follow this structure:
- Include the "AI Engineering Platform" pre-heading with purple background
- Use ChromeText for the main heading
- Include a concise subheading that explains the value proposition
- Add call-to-action buttons with gradient backgrounds
- Consider adding subtle animations with Framer Motion
- Ensure proper spacing (py-32) and responsive behavior
The ChromeText
component is used for headings with a metallic gradient effect:
<ChromeText
as="h2"
className="text-3xl md:text-5xl font-bold mb-4"
preHeading="Optional Pre-Heading"
preHeadingClassName="optional-additional-classes"
style={{
backgroundPosition: `${mouseX}% ${mouseY}%`,
}}
>
Your Heading Text
</ChromeText>
Props:
as
: HTML element to render (h1, h2, etc.)className
: Additional classes for the headingpreHeading
: Optional text to show above the headingpreHeadingClassName
: Additional classes for the pre-headingstyle
: Additional styles including backgroundPosition for the reflection effect
When adding UI mockups:
- Create self-contained components for mockups
- Use responsive design patterns
- Add subtle animations to enhance visual appeal
- Include realistic-looking data and UI elements
For cloud console mockups, follow the style in AIPlatformSection.tsx
.
For platform mockups, follow the style in DXPlatform.tsx
.
When making updates to the website:
- Keep styling consistent across all pages
- Maintain proper spacing between elements
- Ensure all components are responsive
- Keep large components refactored into smaller, focused pieces
- Follow the established UI patterns and color schemes
- Use the Chrome Text component for main headings
- Add appropriate pre-headings to each major section
When adding new pages:
- Create a new page component in the
src/pages
directory - Include the proper pre-heading and ChromeText heading
- Add the page to the appropriate routes in
App.tsx
- Follow the established layout patterns:
- Pre-heading (AI Engineering Platform)
- ChromeText main heading
- Concise description
- Clear call-to-action buttons
- Consistent spacing (py-32)
- Ensure the page is fully responsive
The website uses Framer Motion for animations. When adding new animations:
- Use consistent animation patterns:
<motion.div initial={{ opacity: 0, y: 20 }} animate={{ opacity: 1, y: 0 }} transition={{ duration: 0.5 }} >
- Stagger animations for related elements
- Use viewport animations for scrolling sections:
<motion.div initial={{ opacity: 0, y: 20 }} whileInView={{ opacity: 1, y: 0 }} viewport={{ once: true }} transition={{ duration: 0.5 }} >
When adding or modifying feature sections:
- Use a consistent grid layout (1, 2, or 3 columns depending on content)
- Use icons from lucide-react library with matching colors
- Keep descriptions concise and focused on benefits
- Use ChromeText for section headings
- Add subtle hover effects to interactive elements
- Include proper spacing between items
All components must be fully responsive:
- Use flexible layouts with grid and flex
- Use responsive text sizes (text-base md:text-lg lg:text-xl)
- Stack elements vertically on mobile, horizontally on desktop
- Ensure sufficient spacing on all device sizes
- Test all changes across multiple viewport sizes
- Use Tailwind's responsive prefixes consistently (sm, md, lg, xl)
Most UI components use the shadcn/ui library found in src/components/ui/
. When creating new UI elements:
- Check if a shadcn component already exists for your need
- Follow the established patterns and styling
- Extend existing components rather than creating new ones
- Maintain accessibility across all interactive elements
Follow this typography scale consistently:
- Headings:
- h1:
text-5xl md:text-6xl lg:text-7xl font-bold tracking-tight
- h2:
text-3xl md:text-5xl font-bold
- h3:
text-2xl font-bold
- h4:
text-xl font-semibold
- h1:
- Body:
- Large:
text-xl text-gray-300
- Default:
text-lg text-gray-400
- Small:
text-base text-gray-500
- Caption:
text-sm text-gray-500
- Large:
Use these color classes consistently:
- Primary text:
text-white
(headings and important text) - Secondary text:
text-gray-300
(body text) - Muted text:
text-gray-400
ortext-gray-500
(less important text) - Primary accent:
text-purple-400
or backgroundbg-purple-600
- Secondary accent:
text-blue-400
or backgroundbg-blue-600
- Backgrounds:
bg-black
,bg-gray-900/50
, orbg-gray-900/20
- Borders:
border-gray-800
orborder-purple-500/30
for accents