Demo Projects
Three guided projects with complete, runnable code.
Personal Portfolio
Features:
- Hero section with name & title
- About me section
- Skills grid
- Projects showcase
- Contact form
- Responsive design
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Sarah's Portfolio</title>
<style>
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Segoe UI', sans-serif; color: #333; }
/* Hero Section */
.hero {
min-height: 100vh;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
color: white;
text-align: center;
padding: 2rem;
}
.hero h1 { font-size: 3rem; margin-bottom: 0.5rem; }
.hero p { font-size: 1.2rem; opacity: 0.9; }
/* Skills Grid */
.skills {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 1.5rem;
padding: 4rem 2rem;
max-width: 900px;
margin: 0 auto;
}
.skill-card {
background: white;
border: 1px solid #e0e0e0;
border-radius: 12px;
padding: 1.5rem;
text-align: center;
transition: transform 0.3s;
}
.skill-card:hover { transform: translateY(-5px); }
.skill-card h3 { margin-bottom: 0.5rem; }
.skill-bar {
height: 8px;
background: #e0e0e0;
border-radius: 4px;
overflow: hidden;
}
.skill-bar-fill {
height: 100%;
background: linear-gradient(to right, #667eea, #764ba2);
border-radius: 4px;
}
/* Projects Section */
.projects {
background: #f8f9fa;
padding: 4rem 2rem;
}
.projects h2 { text-align: center; margin-bottom: 2rem; }
.project-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
gap: 2rem;
max-width: 900px;
margin: 0 auto;
}
.project-card {
background: white;
border-radius: 12px;
overflow: hidden;
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
.project-card img { width: 100%; height: 200px; object-fit: cover; }
.project-card .info { padding: 1.5rem; }
/* Contact Form */
.contact {
max-width: 600px;
margin: 4rem auto;
padding: 0 2rem;
}
.contact input, .contact textarea {
width: 100%;
padding: 0.75rem;
margin-bottom: 1rem;
border: 1px solid #ddd;
border-radius: 8px;
font-size: 1rem;
}
.contact button {
background: #667eea;
color: white;
border: none;
padding: 0.75rem 2rem;
border-radius: 8px;
cursor: pointer;
font-size: 1rem;
}
</style>
</head>
<body>
<section class="hero">
<h1>Sarah Johnson</h1>
<p>Web Designer & Frontend Developer</p>
</section>
<section class="skills">
<div class="skill-card">
<h3>HTML5</h3>
<div class="skill-bar"><div class="skill-bar-fill" style="width: 95%"></div></div>
</div>
<div class="skill-card">
<h3>CSS3</h3>
<div class="skill-bar"><div class="skill-bar-fill" style="width: 90%"></div></div>
</div>
<div class="skill-card">
<h3>JavaScript</h3>
<div class="skill-bar"><div class="skill-bar-fill" style="width: 75%"></div></div>
</div>
<div class="skill-card">
<h3>Responsive Design</h3>
<div class="skill-bar"><div class="skill-bar-fill" style="width: 88%"></div></div>
</div>
</section>
<section class="projects">
<h2>My Projects</h2>
<div class="project-grid">
<div class="project-card">
<img src="https://picsum.photos/400/200?1" alt="Project 1">
<div class="info">
<h3>Restaurant Website</h3>
<p>A responsive restaurant site with menu and reservations.</p>
</div>
</div>
<div class="project-card">
<img src="https://picsum.photos/400/200?2" alt="Project 2">
<div class="info">
<h3>E-Commerce Store</h3>
<p>Product showcase with cart and checkout UI.</p>
</div>
</div>
</div>
</section>
<section class="contact">
<h2>Get In Touch</h2>
<form>
<input type="text" placeholder="Your Name" required>
<input type="email" placeholder="Your Email" required>
<textarea rows="5" placeholder="Your Message" required></textarea>
<button type="submit">Send Message</button>
</form>
</section>
</body>
</html>