@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@700;900&family=Roboto:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@700;900&display=swap');

*{
    padding: 0%;
    margin: 0%;
    box-sizing: border-box;
    scroll-behavior: smooth;
}
body{
    background-image: radial-gradient(circle at 16% 83%, rgba(148, 148, 148,0.06) 0%, rgba(148, 148, 148,0.06) 50%,rgba(63, 63, 63,0.06) 50%, rgba(63, 63, 63,0.06) 100%),radial-gradient(circle at 68% 87%, rgba(66, 66, 66,0.06) 0%, rgba(66, 66, 66,0.06) 50%,rgba(105, 105, 105,0.06) 50%, rgba(105, 105, 105,0.06) 100%),radial-gradient(circle at 38% 50%, rgba(123, 123, 123,0.06) 0%, rgba(123, 123, 123,0.06) 50%,rgba(172, 172, 172,0.06) 50%, rgba(172, 172, 172,0.06) 100%),linear-gradient(90deg, hsl(18,0%,1%),hsl(18,0%,1%));
    background-repeat: no-repeat;
    background-size: cover;
    background-attachment: fixed;
    color: white;
    font-family: 'Arial', sans-serif;
}
html,body{
    max-width: 100%;
    max-height: 100%;
    overflow-x: hidden;
}
a{
    text-decoration: none;
    color: white;
    transition: color 0.3s ease;
}
a:hover {
    color: red;
}
span{
    color: red;
}
.nav{
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 1rem 2rem;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    box-shadow: 0 0 20px black,0 0 40px black ;
}

.nav h1 {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 0 10px rgba(255, 0, 60, 0.4);
    flex-shrink: 0;
}

@media (min-width: 769px) {
    .nav h1 {
        font-size: 1.8rem;  /* Decreased by 0.5 times from 2rem */
    }
}

.navbar {
    display: flex;
    align-items: center;
    gap: 2rem;
    position: static;
    left: auto;
    transform: none;
    margin: 0 auto;
    width: auto;
    height: auto;
    background: none;
    box-shadow: none;
    padding: 0;
    transition: none;
    flex-direction: row;
    flex-grow: 1;
    justify-content: center;
    list-style: none;
}

.navbar a {
    text-decoration: none;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.nav-link {
    position: relative;
    padding: 0.5rem 1rem;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: red;
    transition: width 0.3s ease;
}

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

.navbar .nav-link-right {
    display: none;
}

.nav-link-laptop-right {
    background: linear-gradient(90deg, #ff003c 0%, #ff4d4d 100%);
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    color: white;
    box-shadow: 0 4px 10px rgba(255, 0, 60, 0.4);
    transition: all 0.3s ease;
    position: static;
    right: auto;
    display: block;
    text-decoration: none;
    flex-shrink: 0;
    margin-left: auto;
}

.nav-link-laptop-right:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 0, 60, 0.6);
}

#bar {
    display: none;
}

.menu{
    position: fixed;
    top: 0;
    right: -100%;
    width: 250px;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    padding: 2rem;
    transition: right 0.3s ease;
    z-index: 1001;
}
.menu.active {
    right: 0;
}
#cross{
    position: absolute;
    top: 1rem;
    right: 1rem;
    color: red;
    cursor: pointer;
    font-size: 1.5rem;
}
li{
    list-style-type: none;
    margin-top: 10px;
    font-size: 17px;
}
.image{
    width: 400px;
    height: 400px;
    border: 4px solid red;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: red;
    position: relative;
    right: auto;
    top: auto;
    box-shadow: 0 0 30px red, 0 0 60px red;
    overflow: hidden;
}
img{
    width: 95%;
    height: 95%;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 0 20px black,0 0 40px black ;
    transition: transform 0.5s ease;
}
.image:hover img {
    transform: scale(1.05);
}
.siz{
    font-size: 25px;
}
.name{
    font-size: 30px;
    color: white;
}
.nam{
    margin-top: 7px;
}
.data{
    margin-top: 130px;
    margin-left: 5%;
}
.thank{
    font-size: 40px;
}
.thanks{
    text-align: center;
    width: 60%;
    margin-top: 70px;
}
.hero-title-typing {
    font-size: 1.6rem;
    color: #eee;
    margin-top: 1rem;
    min-height: 2rem;
    font-weight: 600;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    text-shadow: 0 0 10px rgba(0, 255, 231, 0.4);
}
.cursor {
    color: #00ffe7;
    font-weight: bold;
    animation: blink 1s infinite step-end;
}
@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}
.scroll-down {
    margin-top: 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #fff;
    font-size: 1rem;
    opacity: 0.7;
    gap: 0.5rem;
    animation: bounce 2s infinite;
}
.scroll-down i {
    color: red;
    font-size: 1.8rem;
}
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-15px); }
    60% { transform: translateY(-8px); }
}
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5%;
    margin-top: 4rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    left: -10%;
    top: -10%;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle at 60% 40%, rgba(255,0,0,0.08) 0%, transparent 70%);
    z-index: 0;
    pointer-events: none;
}

.hero-content, .image {
    position: relative;
    z-index: 1;
}

.hero-content {
    flex: 1;
    max-width: 600px;
    margin-right: 3rem;
    text-align: left;
}

.data h5, .data .name h1, .hero-title-typing {
    text-align: left;
}

.data h5 span.siz {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ff4d4d;
    text-shadow: 0 0 8px rgba(255, 77, 77, 0.6);
}

.data .name h1.nam {
    font-size: 3.5rem;
    margin-top: 0.5rem;
    color: #fff;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.4);
    letter-spacing: 2px;
}

.hero-buttons {
    margin-top: 2.5rem;
    display: flex;
    gap: 1.5rem;
    justify-content: flex-start;
}

.cta-button, .secondary-button {
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: bold;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 1rem;
    letter-spacing: 0.5px;
}

.cta-button {
    background: linear-gradient(90deg, #ff003c 0%, #ff4d4d 100%);
    color: white;
    border: none;
    box-shadow: 0 5px 15px rgba(255, 0, 60, 0.4);
}

.secondary-button {
    background: transparent;
    border: 2px solid #ff003c;
    color: #ff003c;
    box-shadow: 0 5px 15px rgba(255, 0, 60, 0.2);
}

.cta-button:hover {
    background: linear-gradient(90deg, #ff4d4d 0%, #ff003c 100%);
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 8px 25px rgba(255, 0, 60, 0.6);
}

.secondary-button:hover {
    background: rgba(255, 0, 60, 0.1);
    border-color: #ff4d4d;
    color: #ff4d4d;
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 8px 25px rgba(255, 0, 60, 0.4);
}

/* About Section */
.about {
    padding: 5rem 5%;
}

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

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background: red;
}

.about-content {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
    align-items: center;
    justify-content: center;
}

.about-image {
    flex: 1;
    max-width: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 4px solid red;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 0 20px red, 0 0 40px red;
    background-color: rgba(255, 0, 0, 0.1);
}

.about-image img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
    transition: transform 0.5s ease;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

.about-image:hover img {
    transform: scale(1.05);
}

.about-text {
    flex: 2;
    min-width: 300px;
    max-width: 700px;
    line-height: 1.7;
}

.about-subheading {
    font-size: 1.8rem;
    color: #fff;
    margin-bottom: 1.5rem;
    text-shadow: 0 0 10px rgba(255, 0, 60, 0.5);
}

.about-text p {
    margin-bottom: 1rem;
    color: #ccc;
    font-size: 1.1rem;
}

.about-details {
    margin-top: 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.1rem;
    color: #fff;
}

.detail-item i {
    color: red;
    font-size: 1.6rem;
}

/* Skills Section */
.skills {
    padding: 5rem 5%;
    background: rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.skills-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    overflow: hidden;
    padding: 1.5rem 0;
}

.tech-stack-track {
    display: flex;
    width: max-content;
}

.tech-stack-track.track-2 {
}

.tech-stack-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    margin-right: 1.5rem;
    color: #ccc;
    font-size: 1rem;
    font-weight: 600;
    opacity: 1;
    transition: all 0.3s ease;
    min-width: 150px;
    max-width: 180px;

    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 0, 60, 0.3);
    border-radius: 8px;
    padding: 1.5rem 1rem;
    box-shadow: 0 2px 10px rgba(255, 0, 60, 0.1);
    text-align: center;
}

.tech-stack-item span {
    color: #ff003c;
    transition: color 0.3s ease;
}

.tech-stack-item:hover {
    opacity: 1;
    color: #fff;
    background: rgba(255, 0, 60, 0.15);
    border-color: #ff003c;
    box-shadow: 0 4px 15px rgba(255, 0, 60, 0.4);
    transform: translateY(-5px);
}

.tech-stack-item:hover span {
    color: #fff;
}

.tech-stack-item i {
    font-size: 3rem;
    color: #fff;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.6);
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.tech-stack-item:hover i {
    color: #ff003c;
    text-shadow: 0 0 15px rgba(255, 0, 60, 0.8);
}

/* Projects Section */
.projects {
    padding: 5rem 5%;
    overflow: hidden !important;
    position: relative;
    z-index: 0;
}

.projects-carousel {
    position: relative;
    overflow: hidden !important;
    padding-top: 2.5rem;
    padding-bottom: 2.5rem;
    margin-bottom: 2rem;
    min-height: 450px;
    height: auto;
    z-index: 1;
}
.carousel-track {
    display: flex;
    gap: 1.5rem;
    width: max-content;
    animation: marquee-projects 40s linear infinite;
    will-change: transform;
}

@keyframes marquee-projects {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.project-card {
    min-width: 300px;
    width: 320px;
    background: #1c1c1c;
    border-radius: 12px;
    box-shadow: 0 8px 16px rgba(255,0,60,0.3), 0 0 12px rgba(255,0,60,0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 0, 60, 0.2);
    z-index: 1;
    display: flex;
    flex-direction: column;
    height: auto;
}
.project-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 24px rgba(255,0,60,0.5), 0 0 20px rgba(255,0,60,0.8);
    border-color: #ff003c;
    z-index: 10;
}
.project-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 12px 12px 0 0;
    box-shadow: 0 8px 16px rgba(255,0,60,0.3);
}
.project-content-area {
    padding: 1rem 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    flex-grow: 1;
}
.project-title {
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 0.3rem;
    text-shadow: none;
    font-weight: 700;
    display: flex;
    align-items: center;
}
.project-title i {
    font-size: 0.9rem;
    margin-left: 8px;
    color: #00ffe7;
    transition: transform 0.3s ease;
}
.project-card:hover .project-title i {
    transform: translateX(4px);
}
.project-description {
    font-size: 0.9rem;
    color: #ccc;
    line-height: 1.4;
    margin-bottom: 0.8rem;
    flex-grow: 1;
}
.project-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.8rem;
}
.skill-tag {
    background: rgba(255, 0, 60, 0.1);
    color: #ff003c;
    border: 1px solid rgba(255, 0, 60, 0.4);
    border-radius: 4px;
    padding: 0.2rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}
.skill-tag i {
    font-size: 1.1em;
    color: #fff;
}

/* Specific colors for skill icons (examples) */
.skill-tag .fab.fa-html5 { color: #E44F26; }
.skill-tag .fab.fa-css3-alt { color: #1572B6; }
.skill-tag .fab.fa-js { color: #F7DF1E; }
.skill-tag .fab.fa-python { color: #3776AB; }
.skill-tag .fab.fa-github { color: #181717; }
/* Add more specific icon colors here as needed */

.project-actions {
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    padding: 0.8rem 1.2rem;
    background: rgba(0,0,0,0.7);
    border-radius: 0 0 12px 12px;
    gap: 0.6rem;
}
.project-btn {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.8rem;
    border-radius: 5px;
    font-weight: 600;
    font-size: 0.85rem;
    background: #181818;
    color: #fff;
    border: 1.5px solid #ff003c;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
    box-shadow: 0 0 6px 1px #ff003c33;
}
.project-btn.github {
    background: #181818;
    color: #fff;
}
.project-btn.demo {
    background: #ff003c;
    color: #fff;
    border: 1.5px solid #ff003c;
}
.project-btn:hover {
    background: #fff;
    color: #ff003c;
    box-shadow: 0 0 12px 2px #ff003c99;
}
.project-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0; top: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.7);
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s;
}
.project-modal.active {
    display: flex;
}
.modal-content {
    background: #181818;
    color: #fff;
    border-radius: 14px;
    padding: 2.5rem 2rem 2rem 2rem;
    min-width: 320px;
    max-width: 90vw;
    box-shadow: 0 0 32px 4px #ff003c99;
    position: relative;
    text-align: center;
}
.close-modal {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 2rem;
    color: #ff003c;
    cursor: pointer;
    font-weight: bold;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Contact Section */
.contact {
    padding: 5rem 5%;
    background: linear-gradient(120deg, #181818 60%, #fff1 100%);
    border-radius: 24px;
    margin: 3rem 0;
    position: relative;
    overflow: visible;
    box-shadow: none !important;
}

.contact-container {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
    align-items: flex-start;
    justify-content: center;
    background: rgba(255,255,255,0.01);
    border-radius: 18px;
    box-shadow: 0 0 24px 0 #ff003c22;
    padding: 2.5rem;
    position: relative;
    z-index: 1;
}

.contact-left,
.contact-right {
    flex: 1;
    min-width: 300px;
}

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

.contact-subheading {
    font-size: 2rem;
    color: #fff;
    margin-bottom: 1rem;
    text-shadow: 0 0 10px rgba(255, 0, 60, 0.5);
}

.contact-description {
    font-size: 1.1rem;
    color: #ccc;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.contact-info,
.follow-me {
    background: rgba(255,255,255,0.04);
    border-radius: 14px;
    padding: 1.8rem;
    box-shadow: 0 0 18px 0 #ff003c22;
    margin-bottom: 2rem;
}

.info-heading {
    font-size: 1.3rem;
    color: #ff003c;
    margin-bottom: 1.2rem;
    border-bottom: 2px solid rgba(255, 0, 60, 0.3);
    padding-bottom: 0.5rem;
    text-shadow: 0 0 8px rgba(255, 0, 60, 0.6);
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1.1rem;
    color: #fff;
    font-size: 1.1rem;
    font-family: 'Segoe UI', Arial, sans-serif;
    padding: 0.8rem 0;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
}

.info-item:last-child {
    border-bottom: none;
}

.info-item i {
    color: #ff003c;
    font-size: 1.5rem;
}

.contact-social-links {
    display: flex;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.contact-social-links a {
    color: #fff;
    font-size: 1.8rem;
    transition: color 0.3s ease, transform 0.3s ease;
    text-shadow: 0 0 10px rgba(255, 0, 60, 0.4);
}

.contact-social-links a:hover {
    color: #ff4d4d;
    transform: scale(1.2);
    text-shadow: 0 0 15px rgba(255, 77, 77, 0.8);
}

.contact-form {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    background: rgba(255,255,255,0.04);
    border-radius: 14px;
    padding: 2rem;
    box-shadow: 0 0 18px 0 #ff003c22;
    position: relative;
    z-index: 1;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1.2rem;
    background: rgba(255,255,255,0.09);
    border: 1.5px solid #ff003c44;
    border-radius: 7px;
    color: #fff;
    font-size: 1.1rem;
    font-family: 'Segoe UI', Arial, sans-serif;
    transition: border 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 12px 0 #ff003c22;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #aaa;
    opacity: 0.8;
}

.form-group input:focus,
.form-group textarea:focus {
    border: 1.5px solid #ff003c;
    outline: none;
    box-shadow: 0 0 16px 2px #ff003c55;
    background: rgba(255,255,255,0.15);
}

.form-group textarea {
    min-height: 160px;
    resize: vertical;
}

.submit-button {
    background: linear-gradient(90deg, #ff003c 0%, #ff4d4d 100%);
    color: #fff;
    padding: 1rem 2rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 1.2px;
    box-shadow: 0 6px 20px 0 rgba(255, 0, 60, 0.4);
    transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    text-transform: uppercase;
}

.submit-button:hover {
    background: linear-gradient(90deg, #ff4d4d 0%, #ff003c 100%);
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 8px 25px 0 rgba(255, 0, 60, 0.7);
}

.submit-button:disabled,
.submit-button.loading {
    background: #333;
    cursor: not-allowed;
    opacity: 0.7;
    transform: none;
    box-shadow: none;
}

.submit-button.loading i {
    margin-right: 8px;
}

@media (max-width: 900px) {
    .contact-container {
        flex-direction: column;
        gap: 3rem;
        padding: 2rem 5%;
    }
    .contact-left,
    .contact-right {
        min-width: 100%;
    }
    .contact-info,
    .follow-me,
    .contact-form {
        padding: 1.5rem;
    }
    .contact-subheading {
        font-size: 1.8rem;
        text-align: center;
    }
    .contact-description {
        text-align: center;
    }
    .info-heading {
        text-align: center;
    }
    .contact-social-links {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .nav {
        padding: 1rem;
    }

    .nav h1 {
        text-align: center;
        width: 100%;
        margin: 0 auto;
        display: block;
    }

    .hero {
        padding: 3rem 1rem 1.5rem; /* Adjusted padding for smaller screens */
        gap: 1rem; /* Adjusted gap */
    }

    .image {
        width: 200px; /* Further reduced image size */
        height: 200px; /* Further reduced image size */
    }

    .data {
        margin-top: 1.5rem;
        margin-left: 0;
        text-align: center;
    }

    .data h5 {
        text-align: left;
    }

    .data .name h1 {
        text-align: center; /* Ensure center alignment for smaller mobiles */
    }

    .data h5 span.siz {
        font-size: 1.2rem;
    }

    .data .name h1.nam {
        font-size: 1.8rem; /* Further decreased font size for smaller mobiles */
    }

    .hero-title-typing {
        font-size: 1rem; /* Further reduced font size */
    }

    .hero-buttons {
        margin-top: 1rem; /* Adjusted margin top */
        gap: 0.8rem; /* Adjusted gap */
    }

    .cta-button, .secondary-button {
        padding: 0.6rem 1.2rem; /* Further reduced button padding */
        font-size: 0.8rem; /* Further reduced font size */
    }

    .scroll-down {
        margin-top: 1.5rem; /* Adjusted margin top */
    }

    .section-title {
         font-size: 2rem; /* Reduced section title size */
         margin-bottom: 4.5rem; /* Further increased gap below section titles for smaller mobiles */
    }

    .about-text p {
        font-size: 0.9rem; /* Adjusted font size */
    }

    .tech-stack-track {
        gap: 0.4rem; /* Adjusted gap between tech stack items */
    }

    .tech-stack-item {
        width: 70px; /* Further reduced width */
        height: 70px; /* Further reduced height */
        padding: 0.3rem; /* Further reduced padding */
        gap: 0.1rem; /* Further reduced internal gap */
    }

    .tech-stack-item i {
        font-size: 1.4rem; /* Further reduced icon size */
    }

    .tech-stack-item span {
        font-size: 0.6rem; /* Further reduced text size */
    }

    .projects-carousel {
        min-height: 300px;
        padding: 0.0rem 0;
        margin-bottom: 0.0rem; /* Further decreased margin bottom for smaller mobiles */
    }

    .carousel-track {
        gap: 0.8rem; /* Adjusted gap between project cards */
    }

    .project-card {
        width: 200px; /* Adjusted width for smaller screens */
        height: 280px; /* Adjusted height */
    }

     .project-img {
        height: 100px; /* Adjusted image height */
    }

    .project-content-area {
        padding: 0.4rem 0.6rem;
        gap: 0.6rem; /* Adjusted gap for smaller screens */
    }

    .project-title {
        font-size: 0.85rem;
        margin-bottom: 0.3rem;
    }

    .project-description {
        font-size: 0.7rem;
        line-height: 1.2;
        margin-bottom: 0.3rem;
    }

    .project-skills {
        margin-top: 0.3rem;
        gap: 0.25rem;
    }

    .skill-tag {
        font-size: 0.7rem; /* Increased from 0.55rem */
        padding: 0.1rem 0.3rem; /* Increased padding */
    }

     .project-actions {
        padding: 0.3rem 0.6rem; /* Adjusted padding */
        gap: 0.2rem; /* Adjusted gap */
    }

    .project-btn {
        font-size: 0.6rem; /* Adjusted font size */
        padding: 0.2rem 0.3rem; /* Adjusted padding */
    }

    .contact {
        padding: 3rem;
        margin-top: 1rem;
    }

    .contact-subheading {
        font-size: 1.3rem;
    }
    .contact-description {
        font-size: 0.85rem;
    }
    .info-heading {
        font-size: 1.2rem;
    }
    .info-item {
        font-size: 0.85rem;
    }
    .contact-social-links a {
        font-size: 1.5rem;
    }
    .form-group input,
    .form-group textarea {
        padding: 0.8rem;
        font-size: 0.9rem;
    }
    .submit-button {
        padding: 0.8rem;
        font-size: 0.9rem;
    }
}

/* Footer */
.footer {
    background: rgba(0, 0, 0, 0.8);
    padding: 2rem 5%;
    text-align: center;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

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

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

.social-links a:hover {
    color: red;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav {
        padding: 2.5rem 1rem 2rem;
        justify-content: space-between;
        align-items: center;
        flex-wrap: wrap;
    }

    .nav h1 {
        font-size: 1.4rem;
        flex-shrink: 0;
        margin-right: 0;
    }

    .navbar {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: rgba(0, 0, 0, 0.98);
        backdrop-filter: blur(10px);
        display: flex;
        flex-direction: column;
        padding: 6rem 2rem;
        transition: right 0.3s ease;
        z-index: 1000;
        box-shadow: -5px 0 15px rgba(255, 0, 60, 0.2);
        border-radius: 0;
        margin-top: 0;
        justify-content: flex-start;
        align-items: center;
        left: auto;
        transform: none;
        gap: 0.5rem;
        flex-grow: 0;
        margin: 0;
        list-style: none;
    }

    .navbar.active {
        right: 0;
    }

    .navbar li {
        margin: 0.5rem 0;
        width: 100%;
        text-align: center;
    }

    .navbar a {
        font-size: 1rem;
        text-align: center;
        padding: 0.6rem 1rem;
        border-radius: 6px;
        transition: all 0.3s ease;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 0, 60, 0.1);
        display: block;
        width: 100%;
    }

    .navbar a:hover {
        background: rgba(255, 0, 60, 0.15);
        transform: none;
        border-color: rgba(255, 0, 60, 0.3);
    }

    .navbar .nav-link-right {
        display: block;
        width: auto;
        margin: 1rem auto 0;
        text-align: center;
        padding: 0.6rem 1.5rem;
        border-radius: 8px;
        font-size: 1.1rem;
        background: linear-gradient(90deg, #ff003c 0%, #ff4d4d 100%);
        color: white;
        box-shadow: 0 4px 10px rgba(255, 0, 60, 0.4);
        transition: all 0.3s ease;
        position: static;
        right: auto;
    }

    .nav-link-laptop-right {
        display: none;
    }

    #bar {
        display: block;
        z-index: 1001;
        font-size: 0.9rem;
        cursor: pointer;
        transition: transform 0.3s ease;
        position: static;
        top: auto;
        right: auto;
        margin-left: auto;
        flex-shrink: 0;
    }

    #bar:hover {
        transform: scale(1.1);
        color: #ff4d4d;
    }

    .hero {
        flex-direction: column;
        text-align: center;
        padding: 2.5rem 1rem 2rem;
        gap: 1.5rem;
        min-height: 100vh;
    }

    .hero-content {
        order: 2;
        margin-right: 0;
        max-width: 100%;
    }

    .image {
        order: 1;
        width: 240px;
        height: 240px;
        margin: 0 auto;
        box-shadow: 0 0 20px red, 0 0 40px red;
    }

    .image img {
        width: 95%;
        height: 95%;
        object-fit: cover;
    }

    .data {
        margin-top: 1.5rem;
        margin-left: 0;
        text-align: center;
    }

    .data h5, .data .name h1 {
        text-align: left;
    }

    .data h5 span.siz {
        font-size: 1.5rem;
    }

    .data .name h1.nam {
        font-size: 2.2rem; /* Further decreased font size for mobile */
    }

    .hero-title-typing {
        font-size: 1.3rem;
    }

    .hero-buttons {
        justify-content: center;
        margin-top: 1.5rem;
        gap: 1rem;
    }

    .cta-button, .secondary-button {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }

    .scroll-down {
        margin-top: 2rem;
        align-items: center;
    }

    .about-image {
        display: none;
    }

    .about-text {
        text-align: left;
        padding: 0 1rem;
    }

    .about-subheading {
        text-align: left;
        font-size: 1.5rem;
        margin-bottom: 1.2rem;
    }

    .about-text p {
        font-size: 0.95rem;
        line-height: 1.6;
        text-align: left;
        margin-bottom: 1rem;
    }

    .projects {
        padding: 3rem 0;
        overflow: hidden;
    }

    .projects-carousel {
        padding: 2rem 0;
        margin-bottom: 1rem; /* Decreased margin bottom */
        width: 100%;
        overflow: hidden;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .carousel-track {
        gap: 1rem;
    }

    .project-card {
        min-width: 220px;
        max-width: 250px;
        margin: 0;
        height: 300px;
        display: flex;
        flex-direction: column;
        box-sizing: border-box;
    }

    .project-img {
        height: 120px;
        object-fit: cover;
        border-radius: 12px 12px 0 0;
        box-shadow: 0 8px 16px rgba(255,0,60,0.3);
    }

    .project-content-area {
        padding: 0.5rem 0.8rem;
        gap: 0.8rem; /* Increased gap between elements */
        flex-grow: 1;
        overflow: hidden;
    }

    .project-title {
        font-size: 0.9rem;
        margin-bottom: 0.4rem; /* Added margin bottom for spacing */
        text-shadow: none;
        font-weight: 700;
        display: flex;
        align-items: center;
    }

    .project-description {
        font-size: 0.75rem;
        line-height: 1.3;
        margin-bottom: 0.4rem;
        flex-grow: 1;
        display: -webkit-box;
        -webkit-line-clamp: 4;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .project-skills {
        margin-top: 0.4rem;
        gap: 0.3rem; /* Increased gap between skill tags */
    }

    .skill-tag {
        font-size: 0.75rem; /* Increased font size */
        padding: 0.15rem 0.4rem; /* Increased padding */
    }

    .project-actions {
        padding: 0.4rem 0.8rem;
        gap: 0.3rem;
    }

    .project-btn {
        font-size: 0.7rem;
        padding: 0.3rem 0.4rem;
    }

    .contact-container {
        padding: 1.5rem 1rem;
    }

    .contact-left,
    .contact-right {
        padding: 0;
    }

    .contact-subheading {
        font-size: 1.5rem;
        text-align: left;
    }

    .contact-description {
        font-size: 0.9rem;
        text-align: left;
        line-height: 1.5;
    }

    .info-item {
        font-size: 0.9rem;
        padding: 0.6rem 0;
    }

    .info-item i {
        font-size: 1.2rem;
    }

    .contact-form {
        padding: 1.2rem;
    }

    .form-group input,
    .form-group textarea {
        padding: 0.8rem;
        font-size: 0.9rem;
    }

    .submit-button {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }

    .nav-link-right {
        margin-left: 0;
        margin-top: 1.5rem;
    }

    /* Mobile specific styles for Tech Stack */
    .skills-container {
        padding: 1rem 0;
    }

    .tech-stack-track {
        gap: 0.5rem;
    }

    .tech-stack-item {
        width: 80px;
        height: 80px;
        padding: 0.4rem;
        gap: 0.2rem;
        justify-content: center;
    }

    .tech-stack-item i {
        font-size: 1.6rem;
    }

    .tech-stack-item span {
        font-size: 0.65rem;
    }

    .section-title {
        margin-bottom: 5rem; /* Increased gap below section titles to 5rem */
    }

    .projects {
        padding: 3rem 0;
        overflow: hidden;
    }

    .projects-carousel {
        padding: 2rem 0;
        margin-bottom: 1rem; /* Space before next section */
        width: 100%;
        overflow: hidden;
        display: flex;
        justify-content: center;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .nav {
        padding: 1rem;
    }

    .image {
        width: 240px;
        height: 240px;
    }

    .image img {
        width: 95%;
        height: 95%;
    }

    .projects {
        margin-top: 1rem 0;
        overflow: hidden;
    }

    .projects-carousel {
        padding: 1rem 0; /* Restored padding */
        margin-bottom: 1rem; /* Restored margin bottom */
    }

    .carousel-track {
        gap: 0.4rem;
    }

    .project-card {
        min-width: 200px;
        max-width: 220px;
        max-height: 260px;
        margin: 0;
        box-sizing: border-box;
    }

    .project-img {
        height: 80px;
    }

    .project-content-area {
        padding: 0.4rem 0.6rem;
        gap: 0.6rem; /* Adjusted gap for smaller screens */
    }

    .project-title {
        font-size: 0.85rem;
        margin-bottom: 0.3rem;
    }

    .project-description {
        font-size: 0.7rem;
        line-height: 1.2;
        margin-bottom: 0.3rem;
    }

    .project-skills {
        margin-top: 0.3rem;
        gap: 0.25rem;
    }

    .skill-tag {
        font-size: 0.7rem; /* Increased from 0.55rem */
        padding: 0.1rem 0.3rem; /* Increased padding */
    }

    .project-actions {
        padding: 0.1rem 0.6rem;
        gap: 0.15rem;
    }

    .project-btn {
        font-size: 0.55rem;
        padding: 0.15rem 0.25rem;
    }

    .contact-subheading {
        font-size: 1.3rem;
    }

    .contact-description {
        font-size: 0.85rem;
    }

    .info-item {
        font-size: 0.85rem;
    }

    .section-title {
         font-size: 2rem;
         margin-bottom: 4.5rem; /* Increased gap below section titles to 4.5rem for smaller mobiles */
    }

    .projects-carousel {
        padding: 1rem 0; /* Restored padding */
        margin-bottom: 1rem; /* Restored margin bottom */
    }
}

@media (max-width: 768px) {
    .navbar.active::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }
}

.contact-success-msg,
.contact-error-msg {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    opacity: 0;
    transition: all 0.4s ease-in-out;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.contact-success-msg {
    background: rgba(40, 167, 69, 0.95);
    color: #fff;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.4);
}

.contact-error-msg {
    background: rgba(220, 53, 69, 0.95);
    color: #fff;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.4);
}

.contact-success-msg i,
.contact-error-msg i {
    font-size: 1.3rem;
}

.contact-success-msg.show,
.contact-error-msg.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 600px) {
    .contact-success-msg,
    .contact-error-msg {
        bottom: -60px;
        padding: 10px 15px;
        font-size: 0.9rem;
    }
     .contact-success-msg i,
    .contact-error-msg i {
        font-size: 1.1rem;
    }
}

.image img.tilt {
    transition: transform 0.1s linear;
}

.hero-image-container {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    transition: transform 0.5s ease;
}

.hero-image-container:hover {
    transform: perspective(1000px) rotateY(5deg);
}

.hero .data {
    flex-basis: 100%;
    text-align: center;
    padding: 0 20px;
}

/* Resume Dropdown Styles */
.resume-dropdown {
    position: relative;
    display: inline-block;
}

.resume-button.cta-button {
    display: flex;
    align-items: center;
    gap: 8px;
}

.resume-button i {
    transition: transform 0.3s ease;
}

.resume-dropdown.active .resume-button i {
    transform: rotate(180deg);
}

.resume-dropdown-content {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    background-color: #1a1a1a;
    min-width: 200px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border-radius: 5px;
    z-index: 1000;
    border: 1px solid rgba(255, 0, 0, 0.1);
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.3s ease-out, transform 0.3s ease-out;
}

.resume-dropdown.active .resume-dropdown-content {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.resume-dropdown-content a {
    color: white;
    padding: 12px 16px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.resume-dropdown-content a:hover {
    background-color: rgba(255, 0, 0, 0.1);
    color: #ff3333;
}

.resume-dropdown-content a i {
    width: 20px;
    text-align: center;
}

/* Mobile Responsiveness */
@media screen and (max-width: 768px) {
    .resume-dropdown-content {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(0, 0, 0, 0.95);
        backdrop-filter: blur(10px);
        border-radius: 8px;
        padding: 1rem;
        display: none;
        z-index: 1000;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    }

    .resume-dropdown.active .resume-dropdown-content {
        display: block;
    }

    .resume-dropdown-content a {
        display: block;
        padding: 0.6rem 0.8rem; /* Reduced padding */
        color: white;
        text-decoration: none;
        transition: all 0.3s ease;
        border-radius: 4px;
        margin: 0.3rem 0;
        font-size: 0.9rem; /* Reduced font size */
    }

    .resume-dropdown-content a:hover {
        background: rgba(255, 0, 60, 0.1);
        color: #ff003c;
    }

    .resume-dropdown-content a i {
        margin-right: 0.5rem;
        color: #ff003c;
    }
}

/* Hide mobile-only elements on desktop/laptop */
.mobile-only { display: none !important; }

@media (max-width: 480px) {
  .mobile-only { display: flex !important; }
  .bottom-nav {
    position: fixed;
    left: 0;
    bottom: 0;
    width: 100vw;
    height: 56px;
    background: #181515;
    display: flex;
    align-items: center;
    justify-content: space-around;
    z-index: 1001;
    border-top-left-radius: 18px;
    border-top-right-radius: 18px;
    box-shadow: 0 -2px 12px rgba(0,0,0,0.12);
    padding: 0;
  }
  .bottom-nav a {
    flex: 1;
    text-align: center;
    color: #fff;
    text-decoration: none;
    font-size: 0.85rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    font-weight: 500;
    transition: color 0.2s;
    padding: 0;
    height: 100%;
  }
  .bottom-nav a:active {
    color: #f7bfc9;
  }
  .bottom-nav i {
    font-size: 1.3rem;
    margin-bottom: 2px;
    display: block;
  }
  .bottom-nav span {
    font-size: 0.78rem;
    margin: 0;
    display: block;
  }
}

@media (max-width: 480px) {
  .mobile-hide { display: none !important; }
}

/* Hide mobile-only-about on desktop/laptop */
.mobile-only-about { display: none; }

@media (max-width: 480px) {
  .mobile-only-about {
    display: block;
    text-align: center;
    font-size: 1.05rem;
    color: #fff;
    margin: 0.5rem 0 1.2rem 0;
    font-weight: 500;
    background: #2d2829;
    border-radius: 14px;
    padding: 0.7rem 1rem;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  }
  .about-text > p:not(.mobile-only-about) {
    display: none !important;
  }
}

@media (max-width: 480px) {
  .navbar { display: none !important; }
  #bar { display: none !important; }
}

/* Hide mobile-message-form on desktop/laptop */
.mobile-message-form { display: none; }

@media (max-width: 480px) {
  .mobile-message-form {
    display: block;
    margin: 1.2rem 0 0 0;
    padding: 1.2rem 0.5rem 0.5rem 0.5rem;
    background: #231f20;
    border-radius: 18px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.10);
  }
  .mobile-message-form .contact-subheading {
    text-align: center;
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.7rem;
  }
  .mobile-message-form .contact-form {
    background: #2d2829;
    border-radius: 18px;
    padding: 1rem 0.8rem 0.7rem 0.8rem;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  }
  .mobile-message-form .form-group {
    margin-bottom: 0.7rem;
  }
  .mobile-message-form input,
  .mobile-message-form textarea {
    width: 100%;
    padding: 0.7rem 1rem;
    border-radius: 12px;
    border: none;
    background: #181515;
    color: #fff;
    font-size: 0.98rem;
    font-family: inherit;
    margin-bottom: 0.2rem;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  }
  .mobile-message-form textarea {
    min-height: 80px;
    resize: vertical;
  }
  .mobile-message-form .submit-button {
    width: 100%;
    background: #f7bfc9;
    color: #181515;
    border-radius: 12px;
    padding: 0.8rem 0;
    font-size: 1.1rem;
    font-weight: 700;
    border: none;
    margin-top: 0.2rem;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    transition: background 0.2s;
  }
  .mobile-message-form .submit-button:active {
    background: #f7a6b6;
  }
  /* Hide desktop form on mobile */
  .contact-right { display: none !important; }
}