/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px; /* This accounts for the fixed navbar */
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f1f1f1;
}

/* Navbar Styles */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    background-color: #ffffff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #2d3436;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    text-decoration: none;
    color: #2d3436;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-links a:hover {
    color: #0984e3;
    font-size: 1.1rem;
    transform: translateY(-3px);
}

.hamburger {
    display: none;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.5rem;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 5px 0;
    transition: all 0.3s ease;
}

@media screen and (max-width: 768px) {
    .hamburger {
        display: block;
        z-index: 1001;
        position: absolute;
        right: 1rem;
        top: 1rem;
    }

    .nav-links {
        display: none;
        position: fixed;
        top: 0;
        right: -100%;
        height: auto;
        width: 250px;
        background-color: #ffffff;
        flex-direction: column;
        padding: 0;
        transition: right 0.3s ease;
        box-shadow: -2px 0 5px rgba(0,0,0,0.1);
        border-radius: 0 0 0 10px;
    }

    .nav-links::before {
        content: 'Menu';
        display: block;
        padding: 1.5rem;
        background: #0984e3;
        color: white;
        font-weight: bold;
        font-size: 1.2rem;
        text-align: center;
        border-bottom: 2px solid rgba(255,255,255,0.1);
    }

    .nav-links li {
        margin: 0;
        width: 100%;
        border-bottom: 1px solid #eee;
    }

    .nav-links li:last-child {
        border-bottom: none;
    }

    .nav-links a {
        display: block;
        padding: 1rem 2rem;
        font-size: 1.1rem;
        transition: all 0.3s ease;
    }

    .nav-links a:hover {
        background-color: #f8f9fa;
        padding-left: 2.5rem;
    }

    .nav-links.active {
        display: flex;
        right: 0;
    }

    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 6px);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -5px);
    }

    .navbar {
        padding: 1rem;
        flex-direction: row; /* Keep navbar in row format */
        justify-content: space-between;
        align-items: center;
    }

    .logo {
        margin-right: auto; /* Push logo to the left */
    }

    /* Remove the margin-top from nav-links in mobile view */
    .nav-links {
        margin-top: 0;
    }
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #74b9ff, #0984e3);
    color: white;
    padding: 2rem;
    text-align: center;
    padding-top: 80px;
    position: relative;
    overflow: hidden;
}

/* Add animated background effect */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, 
        rgba(255,255,255,0.1) 25%, 
        transparent 25%, 
        transparent 50%, 
        rgba(255,255,255,0.1) 50%, 
        rgba(255,255,255,0.1) 75%, 
        transparent 75%, 
        transparent);
    background-size: 100px 100px;
    animation: moveBackground 30s linear infinite;
    opacity: 0.1;
}

.hero-content {
    max-width: 800px;
    position: relative;
    z-index: 1;
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 20px;
    backdrop-filter: blur(5px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.profile-img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid white;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    animation: fadeIn 1s ease, float 3s ease-in-out infinite;
    margin: 2rem auto;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    animation: fadeInDown 1s ease;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.tagline {
    font-size: 1.8rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    animation: fadeInUp 1s ease;
    font-weight: 300;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.typing {
    border-right: 3px solid;
    display: inline-block;
    white-space: nowrap;
    overflow: hidden;
    font-weight: 500;
    color: #ffffff;
    animation: typing 3.5s steps(40, end), blink .75s step-end infinite;
}

@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

@keyframes blink {
    from, to { border-color: transparent }
    50% { border-color: white }
}

/* CTA Button Enhancement */
.cta-button {
    display: inline-block;
    margin-top: 2rem;
    padding: 1rem 2.5rem;
    background: linear-gradient(45deg, #ffffff, #f8f9fa);
    color: #0984e3;
    text-decoration: none;
    border-radius: 30px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    position: relative;
    overflow: hidden;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    background: linear-gradient(45deg, #f8f9fa, #ffffff);
}

.cta-button:active {
    transform: translateY(-1px);
}

/* New Animations */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes moveBackground {
    0% { background-position: 0 0; }
    100% { background-position: 100px 100px; }
}

/* Section Styles */
section {
    padding: 5rem 2rem;
}

section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #2d3436;
}

/* About Section */
.about {
    background-color: white;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.2rem;
    font-family: 'Times New Roman', Times, serif;
}

/* Education Section */
.education-cards {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s ease;
    width: 300px;
}

.card:hover {
    transform: translateY(-10px);
}

.card i {
    font-size: 3rem;
    color: #0984e3;
    margin-bottom: 1rem;
}

.cgpa-display {
    margin-top: 1.5rem;
    padding: 1rem;
    background: linear-gradient(135deg, #0984e3, #74b9ff);
    border-radius: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 10px rgba(9, 132, 227, 0.3);
}

.cgpa-label {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.2rem;
    font-family: 'Times New Roman', Times, serif;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.cgpa-value {
    color: white;
    font-size: 2.5rem;
    font-weight: bold;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Skills Section */
.skills {
    background-color: white;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 1rem;
}

.skill-card {
    text-align: center;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 10px;
    transition: transform 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.skill-card:hover {
    transform: translateY(-5px);
}

.skill-card i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.skill-card h3 {
    font-size: 1.2rem;
    color: #2d3436;
}

/* Skill icon colors */
.skill-card .fa-html5 { color: #e34f26; }
.skill-card .fa-css3-alt { color: #264de4; }
.skill-card .fa-js { color: #f7df1e; }
.skill-card .fa-java { color: #007396; }
.skill-card .fa-python { color: #3776AB; }
.skill-card .fa-database { color: #336791; }

/* Make skills grid responsive */
@media (max-width: 768px) {
    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .skills-grid {
        grid-template-columns: 1fr;
    }
}

/* Contact Section */
.contact {
    background-color: #2d3436;
    color: white;
}

.contact-info {
    text-align: center;
}

.contact-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    text-decoration: none;
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
}

.social-icon {
    color: white;
    font-size: 1.5rem;
    transition: transform 0.3s ease;
}

.social-icon:hover {
    transform: translateY(-5px);
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    background-color: #2d3436;
    color: white;
}

/* Animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }

    .tagline {
        flex-direction: column;
        gap: 0.2rem;
    }

    .hero-content {
        padding: 1.5rem;
        margin: 1rem;
    }

    .profile-img {
        width: 150px;
        height: 150px;
    }

    .navbar {
        flex-direction: column;
        padding: 1rem;
    }

    .nav-links {
        margin-top: 1rem;
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }

    section {
        padding: 3rem 1rem;
    }

    section h2 {
        font-size: 2rem;
    }

    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .projects-grid {
        grid-template-columns: 1fr;
        padding: 0 1rem;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 2rem;
    }

    .tagline {
        font-size: 1.2rem;
    }

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

/* Projects Section */
.projects {
    background-color: #f8f9fa;
    padding: 5rem 2rem;
}

.project-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
}

.filter-btn {
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 30px;
    background: #e9ecef;
    color: #495057;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn.active {
    background: #0984e3;
    color: white;
    box-shadow: 0 4px 15px rgba(9, 132, 227, 0.3);
}

/* Web Development button special styling */
.filter-btn[data-filter="web"] {
    background: #e9ecef;
    color: #495057;
    padding: 0.8rem 2.5rem;
    font-size: 1.1rem;
}

/* Override for active state */
.filter-btn[data-filter="web"].active {
    background: #0984e3;
    color: white;
    box-shadow: 0 4px 15px rgba(9, 132, 227, 0.3);
}

.filter-btn:hover:not(.active) {
    background: #dee2e6;
    transform: translateY(-2px);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.project-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    display: none; /* Hidden by default */
}

.project-card.web {
    display: block; /* Show web projects by default */
}

.project-card:hover {
    transform: translateY(-5px);
}

.project-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.project-info {
    padding: 1.5rem;
}

.project-info h3 {
    margin-bottom: 0.5rem;
    color: #2d3436;
}

.project-info p {
    color: #636e72;
    margin-bottom: 1rem;
}

.project-links {
    display: flex;
    gap: 1rem;
}

.project-link {
    padding: 0.5rem 1rem;
    background: #0984e3;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.project-link:hover {
    background: #0873c4;
    transform: translateY(-2px);
}

/* Responsive Design */
@media (max-width: 768px) {
    .project-filters {
        flex-direction: column;
        align-items: center;
    }

    .filter-btn {
        width: 80%;
        max-width: 300px;
    }

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

.project-slider {
    position: relative;
    width: 100%;
    height: auto;
    overflow: hidden;
    border-radius: 8px;
    background: #f8f9fa;
    padding: 20px;
}

.slider-container {
    position: relative;
    width: 100%;
    height: auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.project-slider .project-img {
    position: absolute;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 500px;
    object-fit: contain;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    margin: 0 auto;
    display: block;
}

.project-slider .project-img.active {
    opacity: 1;
    position: relative;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    z-index: 10;
    transition: background-color 0.3s ease;
}

.slider-arrow:hover {
    background: rgba(0, 0, 0, 0.8);
}

.left-arrow {
    left: 10px;
}

.right-arrow {
    right: 10px;
}

/* Responsive adjustments for the slider */
@media (max-width: 768px) {
    .project-slider {
        padding: 10px;
    }
    
    .project-slider .project-img {
        max-height: 400px;
    }
    
    .slider-arrow {
        width: 35px;
        height: 35px;
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .project-slider .project-img {
        max-height: 300px;
    }
    
    .slider-arrow {
        width: 30px;
        height: 30px;
        font-size: 16px;
    }
}


