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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
    overflow-x: hidden; /* ✅ Prevent horizontal scroll */
    background: linear-gradient(-45deg, #667eea, #764ba2, #f093fb, #f5576c);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    transition: all 0.3s ease;
}

nav.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #667eea;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

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

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

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background: #667eea;
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.hero-content {
    z-index: 2;
    animation: fadeInUp 1s ease-out;
    color: #141e30;
    
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.tech-stack {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    color: #764ba2;
}

.tech-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    animation: float 3s ease-in-out infinite;
}

.tech-badge:nth-child(2) { animation-delay: 0.5s; }
.tech-badge:nth-child(3) { animation-delay: 1s; }
.tech-badge:nth-child(4) { animation-delay: 1.5s; }

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* Sections */
section {
    padding: 5rem 0;
    background: white;
    margin: 2rem 0;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #333;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 4px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

/* SOCIAL LINKS  */
.social-links a {
    margin: 0 10px;
    font-size: 2.25rem;
    color: #764ba2;
    text-decoration: none;
    transition: color 0.3s, transform 0.3s;
}

.social-links a:hover i {
    color: #764ba2;
    transform: scale(1.2);
}

/* About Section */
.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.about-text {
    font-size: 1.1rem;
    line-height: 1.8;
}

.about-image {
    text-align: center;
}

.profile-img {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    border: 5px solid #667eea;
    animation: pulse 2s infinite;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.skill-card {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    transition: transform 0.3s ease;
    cursor: pointer;
}

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

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

/* Projects Section */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

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

/* .project-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
} */

.project-image {
    width: 100%;
    height: 410px;
    overflow: hidden;
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
}

.project-image img {
    width: 100%;
    /* height: 100%; */
    object-fit: cover;
    display: block;
}


.project-info {
    padding: 1.5rem;
}

.project-title {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.project-desc {
    color: #666;
    margin-bottom: 1rem;
}

.project-tech {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tech-tag {
    background: #f0f0f0;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    color: #667eea;
}

/* Media query for screens smaller than 600px */
@media (max-width: 600px) {
    .projects-grid {
    grid-template-columns: 1fr; /* Stack project cards vertically */
    gap: 1rem;
}

    .project-card {
    border-radius: 10px;
}

    .project-image {
    height: 250px; /* Adjust height for smaller screens */
}

    .project-info {
    padding: 1rem;
}

    .project-title {
    font-size: 1.1rem;
}

    .project-desc {
    font-size: 0.9rem;
}

    .tech-tag {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
}
}

/* Contact Section */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 0.5rem;
    font-weight: bold;
    color: #333;
}

.form-group input,
.form-group textarea {
    padding: 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

/* Footer */
footer {
    background: white;
    color: black;
    text-align: center;
    padding: 2rem 0;
    margin-top: 2rem;
}

.f-info-links a {
    text-decoration: none;
    color: #764ba2;
}

.f-info-links a:hover {
    text-decoration: underline;
    color: #764ba2;
}

.f-info-links, .f-info-socials, .f-info-brand  {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: larger;
    color: #764ba2;
}

.f-info-socials i {
    font-size: 4rem;
    margin-right: 3.5rem;
}

.f-info {
    text-align: center;
    height: auto;
    padding: 1rem;
    color: #764ba2;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    font-size: large;
    gap: 1rem;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .about-content,
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .tech-stack {
        flex-wrap: wrap;
    }
}

/* Scroll animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 500px) {
    section {
    padding: 2rem 1rem;  /* Reduce top/bottom & side padding */
    margin: 1rem 0.5rem; /* Reduce margin for smaller screens */
    border-radius: 10px;
}

.container {
    padding: 0 10px; /* Reduce side padding */
}

body {
    overflow-x: hidden; /* Prevent any horizontal scrolling */
}

.hero-content {
    padding: 0 1rem;
}

.project-image {
    height: auto; /* Allow image height to adjust naturally */
}
}

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

.hero p {
    font-size: 1rem;
}

.btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
}

.tech-stack {
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tech-badge {
    font-size: 0.75rem;
    padding: 0.4rem 0.8rem;
}
}
