
Full HTML:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Profile Page</title>
<link rel="stylesheet" href="assets/css/style.css">
</head>
<body>
<!-- Profile Page -->
<div class="container">
<!-- Left Profile Card -->
<div class="left-profile-card">
<div class="user-profile">
<img src="profile-image.jpg" alt="User Profile" class="user-profile">
</div>
<h3>John Doe</h3>
<p>Software Engineer</p>
<div class="progress-bar" style="width: 70%;"></div>
<div class="personal-info">
<h3>Personal Information</h3>
<ul class="personal-list">
<li><i class="fas fa-envelope"></i> john@example.com</li>
<li><i class="fas fa-phone"></i> (123) 456-7890</li>
</ul>
</div>
<div class="skill">
<h3>Skills</h3>
<p>HTML, CSS, JavaScript, React, Node.js</p>
</div>
<div class="languages">
<h3>Languages</h3>
<p>English, Spanish</p>
</div>
</div>
<!-- Right Profile Card -->
<div class="right-profile-card">
<h3>Work Experience</h3>
<ul class="nav nav-pills">
<li class="nav-item"><a class="nav-link active" href="#">Overview</a></li>
<li class="nav-item"><a class="nav-link" href="#">Projects</a></li>
<li class="nav-item"><a class="nav-link" href="#">Skills</a></li>
</ul>
<div class="work-container">
<h4>Company Name</h4>
<p>Job Title - June 2018 - Present</p>
<p>Responsibilities and achievements go here.</p>
</div>
</div>
</div>
<!-- Timeline -->
<div class="timeline-centered">
<div class="timeline-entry left-aligned">
<div class="timeline-entry-inner">
<div class="timeline-time">
<span>2018</span>
<span>Joined ABC Corp</span>
</div>
<div class="timeline-icon bg-primary">
<i class="fas fa-briefcase"></i>
</div>
<div class="timeline-label">
<h2>ABC Corp</h2>
<p>Started as a Junior Developer.</p>
</div>
</div>
</div>
<div class="timeline-entry right-aligned">
<div class="timeline-entry-inner">
<div class="timeline-time">
<span>2020</span>
<span>Promoted to Senior Developer</span>
</div>
<div class="timeline-icon bg-success">
<i class="fas fa-briefcase"></i>
</div>
<div class="timeline-label">
<h2>ABC Corp</h2>
<p>Promoted to Senior Developer with increased responsibilities.</p>
</div>
</div>
</div>
</div>
</body>
</html>
Full CSS (style.css
):
body {
margin-top: 20px;
background: #DCDCDC;
font-family: Arial, sans-serif;
}
/* Profile Page styles */
.container {
display: flex;
justify-content: space-between;
padding: 20px;
}
.left-profile-card {
width: 45%;
}
.left-profile-card .user-profile {
width: 100px;
height: 100px;
border-radius: 50%;
margin: auto;
margin-bottom: 20px;
}
.left-profile-card h3 {
font-size: 18px;
margin-bottom: 0;
font-weight: 700;
}
.left-profile-card p {
margin-bottom: 5px;
}
.left-profile-card .progress-bar {
background-color: var(--main-color);
height: 10px;
border-radius: 5px;
margin-bottom: 20px;
}
.personal-info {
margin-bottom: 30px;
}
.personal-info .personal-list {
list-style-type: none;
margin: 0;
padding: 0;
}
.personal-list li {
margin-bottom: 5px;
}
.personal-info h3 {
margin-bottom: 10px;
}
.personal-info p {
margin-bottom: 5px;
font-size: 14px;
}
.personal-info i {
font-size: 15px;
color: var(--main-color);
margin-right: 15px;
width: 18px;
}
.skill {
margin-bottom: 30px;
}
.skill h3 {
margin-bottom: 15px;
}
.skill p {
margin-bottom: 5px;
}
.languages h3 {
margin-bottom: 15px;
}
.languages p {
margin-bottom: 5px;
}
/* Right Profile Card styles */
.right-profile-card {
width: 45%;
}
.right-profile-card .nav-pills .nav-link.active,
.right-profile-card .nav-pills .show > .nav-link {
color: #fff;
background-color: var(--main-color);
}
.right-profile-card .nav > li {
float: left;
margin-right: 10px;
}
.right-profile-card .nav-pills .nav-link {
border-radius: 26px;
}
.right-profile-card h3 {
font-size: 18px;
font-weight: 700;
margin-bottom: 15px;
}
.right-profile-card h4 {
font-size: 16px;
margin-bottom: 15px;
}
.right-profile-card .work-container {
border-bottom: 1px solid #eee;
margin-bottom: 20px;
padding: 10px;
}
/* Timeline styles */
.img-circle {
border-radius: 50%;
}
.timeline-centered {
position: relative;
margin-bottom: 30px;
}
.timeline-centered:before,
.timeline-centered:after {
content: " ";
display: table;
}
.timeline-centered:after {
clear: both;
}
.timeline-centered:before {
content: "";
position: absolute;
display: block;
width: 4px;
background: #f5f5f6;
top: 20px;
bottom: 20px;
margin-left: 30px;
}
.timeline-centered .timeline-entry {
position: relative;
margin-top: 5px;
margin-left: 30px;
margin-bottom: 10px;
clear: both;
}
.timeline-centered .timeline-entry.left-aligned {
float: left;
}
.timeline-centered .timeline-entry.left-aligned .timeline-entry-inner {
margin-left: 0;
margin-right: -18px;
}
.timeline-centered .timeline-entry.left-aligned .timeline-entry-inner .timeline-time {
left: auto;
right: -100px;
text-align: left;
}
.timeline-centered .timeline-entry.left-aligned .timeline-entry-inner .timeline-icon {
float: right;
}
.timeline-centered .timeline-entry.left-aligned .timeline-entry-inner .timeline-label {
margin-left: 0;
margin-right: 70px;
}
.timeline-centered .timeline-entry .timeline-entry-inner {
position: relative;
margin-left: -20px;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-time {
position: absolute;
left: -100px;
text-align: right;
padding: 10px;
box-sizing: border-box;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-time > span {
display: block;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-time > span:first-child {
font-size: 15px;
font-weight: bold;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-time > span:last-child {
font-size: 12px;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-icon {
background: #fff;
color: #737881;
display: block;
width: 40px;
height: 40px;
background-clip: padding-box;
border-radius: 20px;
text-align: center;
box-shadow: 0 0 0 5px #f5f5f6;
line-height: 40px;
font-size: 15px;
float: left;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-icon.bg-primary {
background-color: #303641;
color: #fff;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-icon.bg-success {
background-color: #00a651;
color: #fff;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-label {
position: relative;
background: #f5f5f6;
padding: 1em;
margin-left: 60px;
background-clip: padding-box;
border-radius: 3px;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-label:after {
content: "";
display: block;
position: absolute;
width: 0;
height: 0;
border-style: solid;
border-width: 9px 9px 9px 0;
border-color: transparent #f5f5f6 transparent transparent;
left: 0;
top: 10px;
margin-left: -9px;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-label h2,
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-label p {
color: #737881;
font-size: 12px;
margin: 0;
line-height: 1.428571429;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-label p + p {
margin-top: 15px;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-label h2 {
font-size: 16px;
margin-bottom: 10px;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-label h2 a {
color: #303641;
}
.timeline-centered .timeline-entry .timeline-entry-inner .timeline-label h2 span {
opacity: 0.6;
}
Explanation:
-
HTML Structure: The layout is split into a left profile card and a right profile card, and below that, there's a timeline of events like joining a company and promotions.
-
CSS: The CSS provides styles for the profile page with a focus on layout, profile information, and timeline entries. It uses flexbox for layout arrangement and custom colors for various sections like timelines and profile cards.