Implement games section with expandable cards
- Added responsive grid of game cards with dark-teal background - Each card has: rounded gray image placeholder, white title, gray description, orange year badge - Click to expand: shows full description + centered play button - Play button opens game in new window - Flat minimal design consistent with portfolio style - Created placeholder images for 6 games
This commit is contained in:
@@ -72,6 +72,17 @@ footer > div > p {
|
||||
.scroll_section {
|
||||
min-height: 100vh;
|
||||
scroll-snap-align: start;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.scroll_section > h1 {
|
||||
color: var(--white-clr);
|
||||
font-size: 48px;
|
||||
margin: 20px 0;
|
||||
text-align: center;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* ===== Navigationbar ===== */
|
||||
@@ -191,6 +202,574 @@ footer > div > p {
|
||||
float: left;
|
||||
}
|
||||
|
||||
/* New project card styling - rectangular with image on top */
|
||||
.project-card-new {
|
||||
background-color: var(--background-accent-clr);
|
||||
border-radius: var(--card-border-radius, 25px);
|
||||
overflow: hidden;
|
||||
margin: 10px;
|
||||
max-width: 400px;
|
||||
min-width: 300px;
|
||||
box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.project-card-new.expanded {
|
||||
z-index: 10;
|
||||
transform: scale(1.02);
|
||||
box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
||||
.project-card-new .toggle-icon {
|
||||
position: absolute;
|
||||
top: 10px;
|
||||
right: 10px;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
border-radius: 50%;
|
||||
background-color: var(--green-clr);
|
||||
color: var(--background-clr);
|
||||
font-size: 20px;
|
||||
font-weight: bold;
|
||||
z-index: 20;
|
||||
cursor: pointer;
|
||||
transition: transform 0.2s ease;
|
||||
}
|
||||
|
||||
.project-card-new .toggle-icon:hover {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
|
||||
.project-card-image-container {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 200px;
|
||||
overflow: hidden;
|
||||
transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
}
|
||||
|
||||
.project-card-new.expanded .project-card-image-container {
|
||||
height: 150px;
|
||||
}
|
||||
|
||||
.project-card-image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
background-color: #888; /* Plain grey as fallback */
|
||||
}
|
||||
|
||||
.project-card-title-container {
|
||||
position: relative;
|
||||
margin-top: -50px; /* Overlap with image */
|
||||
padding: 10px 20px;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.project-card-title-background {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
background-color: var(--background-accent-clr);
|
||||
border-radius: var(--card-border-radius, 25px);
|
||||
opacity: 0.95;
|
||||
}
|
||||
|
||||
.project-card-title {
|
||||
position: relative;
|
||||
font-weight: bold;
|
||||
font-size: 20px;
|
||||
color: var(--green-clr);
|
||||
margin: 0;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.project-card-content {
|
||||
padding: 0 20px;
|
||||
color: var(--text-color);
|
||||
max-height: 0;
|
||||
overflow: hidden;
|
||||
transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding-top 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding-bottom 0.4s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
}
|
||||
|
||||
.project-card-new.expanded .project-card-content {
|
||||
max-height: 1000px;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.project-card-short-desc {
|
||||
padding: 10px 20px 20px;
|
||||
color: var(--text-color);
|
||||
line-height: 1.6;
|
||||
transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
}
|
||||
|
||||
.project-card-new.expanded .project-card-short-desc {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.project-card-content p {
|
||||
margin: 0;
|
||||
line-height: 1.6;
|
||||
}
|
||||
|
||||
/* About Me grid layout */
|
||||
.about-me-projects-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
|
||||
gap: 20px;
|
||||
width: 100%;
|
||||
max-width: 1200px;
|
||||
margin: 20px auto;
|
||||
}
|
||||
|
||||
/* ===== Apps Section - Full Width Dashboard Carousel ===== */
|
||||
|
||||
.apps-container {
|
||||
width: 100%;
|
||||
max-width: 1600px;
|
||||
margin: 0 auto;
|
||||
padding: 20px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 30px;
|
||||
}
|
||||
|
||||
.carousel-container-full {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
padding: 40px 60px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.carousel-track-full {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
gap: 20px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.carousel-item-full {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
cursor: pointer;
|
||||
transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
z-index: 1;
|
||||
min-width: 120px;
|
||||
}
|
||||
|
||||
.carousel-item-full[data-selected="true"] {
|
||||
z-index: 5;
|
||||
}
|
||||
|
||||
.service-icon-large {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
border-radius: 50%;
|
||||
background-color: var(--icon-bg, #888);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: var(--white-clr);
|
||||
font-weight: bold;
|
||||
font-size: 40px;
|
||||
transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
.carousel-item-full[data-selected="true"] .service-icon-large {
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
font-size: 60px;
|
||||
box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
||||
.carousel-item-full:nth-child(1):not([data-selected="true"]) .service-icon-large,
|
||||
.carousel-item-full:nth-child(5):not([data-selected="true"]) .service-icon-large {
|
||||
width: 80px;
|
||||
height: 80px;
|
||||
font-size: 32px;
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
.carousel-item-full:nth-child(2):not([data-selected="true"]):not(:nth-child(4)) .service-icon-large,
|
||||
.carousel-item-full:nth-child(4):not([data-selected="true"]):not(:nth-child(2)) .service-icon-large {
|
||||
width: 90px;
|
||||
height: 90px;
|
||||
font-size: 36px;
|
||||
opacity: 0.85;
|
||||
}
|
||||
|
||||
.service-label-large {
|
||||
color: var(--white-clr);
|
||||
font-size: 22px;
|
||||
margin-top: 15px;
|
||||
opacity: 0.8;
|
||||
transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.carousel-item-full[data-selected="true"] .service-label-large {
|
||||
opacity: 1;
|
||||
font-size: 28px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.carousel-item-full:nth-child(1):not([data-selected="true"]) .service-label-large,
|
||||
.carousel-item-full:nth-child(5):not([data-selected="true"]) .service-label-large {
|
||||
opacity: 0.5;
|
||||
}
|
||||
|
||||
.carousel-nav-full {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
background: rgba(255, 255, 255, 0.15);
|
||||
border: none;
|
||||
color: var(--white-clr);
|
||||
font-size: 48px;
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
border-radius: 50%;
|
||||
cursor: pointer;
|
||||
transition: all 0.3s ease;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.carousel-nav-full:hover {
|
||||
background: rgba(255, 255, 255, 0.25);
|
||||
transform: translateY(-50%) scale(1.1);
|
||||
}
|
||||
|
||||
.carousel-nav-full.prev {
|
||||
left: 20px;
|
||||
}
|
||||
|
||||
.carousel-nav-full.next {
|
||||
right: 20px;
|
||||
}
|
||||
|
||||
/* Service detail area - full width */
|
||||
.service-detail-full {
|
||||
width: 100%;
|
||||
background-color: var(--dark-green, #1a3d2e);
|
||||
border-radius: var(--card-border-radius, 25px);
|
||||
padding: 40px;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 30px;
|
||||
}
|
||||
|
||||
.service-screenshot-full {
|
||||
width: 100%;
|
||||
height: 400px;
|
||||
border-radius: 15px;
|
||||
overflow: hidden;
|
||||
background-color: #2a2a2a;
|
||||
transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
}
|
||||
|
||||
.service-screenshot-full img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
opacity: 0;
|
||||
transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
}
|
||||
|
||||
.service-screenshot-full img.active {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.service-info-full {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
gap: 20px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.service-title {
|
||||
color: var(--green-clr);
|
||||
font-size: 42px;
|
||||
margin: 0;
|
||||
opacity: 0;
|
||||
transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.1s;
|
||||
}
|
||||
|
||||
.service-title.active {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.service-description-full {
|
||||
color: var(--white-clr);
|
||||
font-size: 24px;
|
||||
line-height: 1.6;
|
||||
max-width: 800px;
|
||||
opacity: 0;
|
||||
transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.2s;
|
||||
}
|
||||
|
||||
.service-description-full.active {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.service-description-full p {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
/* Go to App Button */
|
||||
.go-to-app-button {
|
||||
display: inline-block;
|
||||
background-color: var(--green-clr);
|
||||
color: var(--background-clr);
|
||||
padding: 18px 40px;
|
||||
font-size: 28px;
|
||||
font-weight: bold;
|
||||
text-decoration: none;
|
||||
border-radius: 15px;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
|
||||
margin-top: 20px;
|
||||
opacity: 0;
|
||||
transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.3s;
|
||||
}
|
||||
|
||||
.go-to-app-button:hover {
|
||||
transform: translateY(-2px);
|
||||
box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
.go-to-app-button.active {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
/* ===== Games Section ===== */
|
||||
|
||||
.games-container {
|
||||
width: 100%;
|
||||
max-width: 1600px;
|
||||
margin: 0 auto;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.games-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
|
||||
gap: 30px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.game-card {
|
||||
background-color: var(--dark-teal, #2c5f5f);
|
||||
border-radius: var(--card-border-radius, 25px);
|
||||
overflow: hidden;
|
||||
cursor: pointer;
|
||||
transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.game-card:hover {
|
||||
transform: translateY(-5px);
|
||||
box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
.game-card-image {
|
||||
width: 100%;
|
||||
height: 200px;
|
||||
overflow: hidden;
|
||||
background-color: #888;
|
||||
}
|
||||
|
||||
.game-card-image img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
background-color: #888;
|
||||
}
|
||||
|
||||
.game-card-content {
|
||||
padding: 20px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.game-card-title {
|
||||
color: var(--white-clr);
|
||||
font-size: 24px;
|
||||
font-weight: bold;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.game-card-description {
|
||||
color: var(--white-clr);
|
||||
font-size: 18px;
|
||||
opacity: 0.8;
|
||||
margin: 0;
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
.game-year-badge {
|
||||
display: inline-block;
|
||||
background-color: var(--orange-clr, #f39c12);
|
||||
color: var(--background-clr);
|
||||
padding: 5px 12px;
|
||||
border-radius: 20px;
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
align-self: flex-start;
|
||||
}
|
||||
|
||||
.game-card-expanded {
|
||||
display: none;
|
||||
padding: 20px;
|
||||
background-color: rgba(0, 0, 0, 0.2);
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.game-card.expanded .game-card-expanded {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.game-card.expanded .game-card-content {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.game-card.expanded .game-card-image {
|
||||
height: 250px;
|
||||
}
|
||||
|
||||
.game-card-full-description {
|
||||
color: var(--white-clr);
|
||||
font-size: 20px;
|
||||
line-height: 1.6;
|
||||
text-align: center;
|
||||
max-width: 80%;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.play-button {
|
||||
display: inline-block;
|
||||
background-color: var(--green-clr);
|
||||
color: var(--background-clr);
|
||||
padding: 15px 35px;
|
||||
font-size: 24px;
|
||||
font-weight: bold;
|
||||
text-decoration: none;
|
||||
border-radius: 15px;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
||||
box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
.play-button:hover {
|
||||
transform: scale(1.05);
|
||||
box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
/* Responsive design for carousel */
|
||||
@media (max-width: 1024px) {
|
||||
.apps-container {
|
||||
padding: 15px;
|
||||
}
|
||||
|
||||
.carousel-container-full {
|
||||
padding: 30px 40px;
|
||||
}
|
||||
|
||||
.carousel-track-full {
|
||||
gap: 15px;
|
||||
}
|
||||
|
||||
.service-icon-large {
|
||||
width: 80px;
|
||||
height: 80px;
|
||||
font-size: 32px;
|
||||
}
|
||||
|
||||
.carousel-item-full[data-selected="true"] .service-icon-large {
|
||||
width: 120px;
|
||||
height: 120px;
|
||||
font-size: 48px;
|
||||
}
|
||||
|
||||
.carousel-item-full:nth-child(1):not([data-selected="true"]) .service-icon-large,
|
||||
.carousel-item-full:nth-child(5):not([data-selected="true"]) .service-icon-large {
|
||||
width: 60px;
|
||||
height: 60px;
|
||||
font-size: 24px;
|
||||
}
|
||||
|
||||
.carousel-item-full:nth-child(2):not([data-selected="true"]):not(:nth-child(4)) .service-icon-large,
|
||||
.carousel-item-full:nth-child(4):not([data-selected="true"]):not(:nth-child(2)) .service-icon-large {
|
||||
width: 70px;
|
||||
height: 70px;
|
||||
font-size: 28px;
|
||||
}
|
||||
|
||||
.service-screenshot-full {
|
||||
height: 300px;
|
||||
}
|
||||
|
||||
.service-title {
|
||||
font-size: 36px;
|
||||
}
|
||||
|
||||
.service-description-full {
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
.service-label-large {
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.carousel-item-full[data-selected="true"] .service-label-large {
|
||||
font-size: 24px;
|
||||
}
|
||||
|
||||
.go-to-app-button {
|
||||
font-size: 24px;
|
||||
padding: 15px 35px;
|
||||
}
|
||||
}
|
||||
|
||||
/* Currently working on and However in the past sections */
|
||||
.about-me-section {
|
||||
width: 100%;
|
||||
margin-bottom: 40px;
|
||||
}
|
||||
|
||||
.about-me-section h2 {
|
||||
font-size: 28px;
|
||||
color: var(--white-clr);
|
||||
margin-bottom: 20px;
|
||||
border-bottom: 2px solid var(--green-clr);
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
|
||||
.about-me-section h2 .green-text {
|
||||
color: var(--green-clr);
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
/* ===== Images ===== */
|
||||
|
||||
.icon {
|
||||
|
||||
Reference in New Issue
Block a user