* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #3a86ff;
    --secondary-color: #8338ec;
    --text-color: #333;
    --background-color: #f8f9fa;
    --card-color: #fff;
    --border-color: #e9ecef;
    --timeline-blue: #3a86ff;
    --timeline-yellow: #ffbe0b;
    --timeline-green: #06d6a0;
    --timeline-red: #ef476f;
    --food-orange: #ff6b35;
    --food-green: #52b788;
    --food-red: #f72585;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    transition: all 0.3s ease;
}

body.dark-mode {
    --text-color: #e9ecef;
    --background-color: #121212;
    --card-color: #1e1e1e;
    --border-color: #333;
}

a {
    text-decoration: none;
    color: var(--primary-color);
}

h1, h2, h3, h4, h5, h6 {
    margin-bottom: 0.5rem;
    line-height: 1.2;
}

section {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* Navigation */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    background-color: var(--card-color);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo a {
    font-size: 1.5rem;
    font-weight: bold;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-links a {
    padding: 0.5rem;
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--primary-color);
}

/* Header */
header {
    padding: 6rem 2rem;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

header p {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 1rem;
}

/* Typing animation styles */
.typing-text, .typing-text-2 {
    position: relative;
}

.typing-text::after, .typing-text-2::after {
    content: '|';
    animation: blink 1s infinite;
    color: var(--primary-color);
}

.typing-complete::after {
    display: none;
}


@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.contact-info {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.contact-info a {
    color: var(--primary-color);
    text-decoration: none;
}

.separator {
    color: #666;
}

/* me Project */
.me-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

@media (min-width: 768px) {
    .me-container {
        grid-template-columns: 1fr 1fr;
    }
}

.me-image {
    perspective: 1000px;
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    height: auto;
}

.me-image img {
    width: 100%;
    height: auto;
    display: block;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.btn {
    padding: 0.75rem 1.5rem;
    background-color: var(--primary-color);
    color: white;
    border-radius: 4px;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: var(--secondary-color);
}

.featured-details h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.tech-stack span {
    padding: 0.25rem 0.75rem;
    background-color: var(--primary-color);
    color: white;
    border-radius: 20px;
    font-size: 0.875rem;
}

/* Add flip functionality to existing me-image */

.flip-image-inner {
    position: relative;
    width: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.me-image:hover .flip-image-inner {
    transform: rotateY(180deg);
}

.flip-image-front, .flip-image-back {
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 8px;
}

.flip-image-front {
    position: relative;
}

.flip-image-back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(132deg, var(--primary-color), var(--secondary-color));
    transform: rotateY(180deg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.flip-image-front img {
    width: 100%;
    height: auto;
    display: block;
}

.goals-overlay {
    text-align: center;
    color: white;
}

.goals-overlay h4 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.goals-overlay p {
    font-size: 1.1rem;
    line-height: 1.2;
}
/* About Section */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.photo {
    border-radius: 8px;
    overflow: hidden;
    height: 0;
    padding-bottom: 66.67%; /* 3:2 aspect ratio */
    position: relative;
}

.photo img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.photo:hover img {
    transform: scale(1.05);
}

/* Timeline */
.timeline {
    position: relative;
    margin: 3rem 0;
    padding-left: 2rem;
}

.timeline:before {
    content: '';
    position: absolute;
    left: 7px;
    top: 0;
    height: 100%;
    width: 2px;
    background-color: var(--border-color);
}

.timeline-item {
    margin-bottom: 2rem;
    position: relative;
}

.timeline-dot {
    position: absolute;
    left: -2rem;
    top: 0;
    width: 16px;
    height: 16px;
    border-radius: 50%;
}

.timeline-dot.blue { background-color: var(--timeline-blue); }
.timeline-dot.yellow { background-color: var(--timeline-yellow); }
.timeline-dot.green { background-color: var(--timeline-green); }
.timeline-dot.red { background-color: var(--timeline-red); }

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.timeline-date {
    color: #666;
    font-size: 0.875rem;
}

.timeline-position {
    font-style: italic;
    color: #666;
    margin-bottom: 0.5rem;
}

.timeline-content ul {
    padding-left: 1rem;
}

/* Skills Section */
.skills-section {
    margin: 3rem 0;
}

.skills-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 1rem;
}

@media (min-width: 768px) {
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

.skill-category h4 {
    margin-bottom: 0.75rem;
    color: var(--primary-color);
}

/* Projects Section */
.project-card {
    background-color: var(--card-color);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.tech-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: bold;
    color: white;
}

.badge.javascript { background-color: #f7df1e; color: #000; }
.badge.python { background-color: #3776ab; }
.badge.java { background-color: #ed8b00; }
.badge.lua { background-color: #000080; }
.badge.c { background-color: #00599c; }
.badge.html { background-color: #e34c26; }
.badge.css { background-color: #1572b6; }
.badge.assembly { background-color: #654ff0; }
.badge.git { background-color: #00a2ff; }
.badge.roblox { background-color: #00a2ff; }
.badge.vs { background-color: #007acc; }
.badge.office { background-color: #d83b01; }
.badge.discord { background-color: #5865f2; }
.badge.matplotlib { background-color: #11557c; }
.badge.game { background-color: #8b5cf6; }

/* Food Adventures Section */
.food-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.tab-btn {
    background: none;
    border: none;
    padding: 0.5rem 1rem;
    font-size: 1rem;
    cursor: pointer;
    opacity: 0.7;
    transition: all 0.3s ease;
    color: var(--text-color);
    border-radius: 20px;
    position: relative;
}

.tab-btn:hover {
    opacity: 1;
    background-color: var(--border-color);
}

.tab-btn.active {
    opacity: 1;
    background-color: var(--primary-color);
    color: white;
}

.food-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .food-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .food-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.food-card {
    background-color: var(--card-color);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    position: relative;
}

.food-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

/* Main featured card (First Watch) - keeps special layout */
.food-card.main-featured {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 0;
    max-height: 250px;
}

.food-image {
    position: relative;
    overflow: hidden;
}

.food-card.main-featured .food-image {
    height: 250px;
}

.food-card:not(.main-featured) .food-image {
    height: 200px;
}

.food-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.food-card:hover .food-image img {
    transform: scale(1.1);
}

.food-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, rgba(58,134,255,0.8), rgba(131,56,236,0.8));
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.food-card:hover .food-overlay {
    opacity: 1;
}

.view-recipe-btn {
    padding: 0.75rem 1.5rem;
    background-color: white;
    color: var(--primary-color);
    border-radius: 25px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid white;
}

.view-recipe-btn:hover {
    background-color: transparent;
    color: white;
}

.food-content {
    padding: 1.5rem;
}

.food-card.main-featured .food-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.food-title {
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.food-card.main-featured .food-title {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.food-description {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.food-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.food-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.food-tag {
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: bold;
    color: white;
}

.food-tag.homemade { background-color: var(--food-green); }
.food-tag.restaurant { background-color: var(--food-orange); }
.food-tag.dessert { background-color: #ff69b4; }
.food-tag.florida { background-color: #ff6b35; }
.food-tag.montreal { background-color: #8338ec; }
.food-tag.spicy { background-color: #ff4757; }
.food-tag.healthy { background-color: #2ed573; }
.food-tag.comfort { background-color: #ffa726; }

.food-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stars {
    display: flex;
    gap: 2px;
}

.star {
    color: #ffd700;
    font-size: 0.9rem;
}

.rating-text {
    font-size: 0.8rem;
    color: #666;
}

.cooking-stats {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    font-size: 0.8rem;
    color: #666;
}

.stat {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Footer */
footer {
    background-color: var(--card-color);
    padding: 2rem;
    text-align: center;
    margin-top: 3rem;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.social-links a {
    font-size: 1.5rem;
    color: var(--text-color);
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--primary-color);
}

footer p {
    opacity: 0.7;
    font-size: 0.875rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .contact-info {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .separator {
        display: none;
    }
    
    .food-card.main-featured {
        grid-template-columns: 1fr;
        max-height: none;
    }
    
    .food-card.main-featured .food-image {
        height: 200px;
    }
    
    .timeline-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 576px) {
    section {
        padding: 3rem 1rem;
    }
    
    .nav-links {
        gap: 1rem;
    }
    
    header {
        padding: 4rem 1rem;
    }
    
    header h1 {
        font-size: 2rem;
    }

    .food-grid {
        grid-template-columns: 1fr;
    }
}