@media (max-width: 480px) {
    /* Global Adjustments */
    body {
        font-size: 14px;
        line-height: 1.4;
    }

    /* Header and Navigation */
    .nav-container {
        flex-direction: column;
        padding: 0.5rem;
    }

    nav ul {
        width: 100%;
        flex-direction: column;
        align-items: center;
    }

    .nav-link {
        padding: 10px;
        width: 100%;
        text-align: center;
    }

    /* Hero Section */
    .hero {
        padding: 1rem;
        text-align: center;
        font-size: 0.8rem;
    }

    .glitch {
        font-size: 2rem;
    }

    .typing {
        font-size: 0.65rem;
    }

    /* Sections */
    .section-content {
        padding: 0.5rem;
    }

    .section-title {
        font-size: 1.8rem;
        margin-bottom: 1rem;
    }

    /* Grids and Layouts */
    .about-grid,
    .experience-cards,
    .gallery-grid,
    .publications-grid {
        grid-template-columns: 1 fr;
        gap: 0.5rem;
        font-size: 0.5 rem;
        text-align: center;
    }

    /* Cards */
    .experience-card,
    .achievement-card,
    .publication-card {
        padding: 1rem;
    }

    /* Skills */
    .skills-sphere {
        height: 400px;
        width: 100%;
    }

    /* Contact and Social */
    .contact-info {
        flex-direction: column;
        align-items: center;
      
        
    }
    .about-text {
        font-size: 0.8rem;
        line-height: 1.8;
        align-items: center;
    
    }

    .social-links {
        flex-wrap: wrap;
        justify-content: center;
       
    }

    /* Prevent Horizontal Scroll */
    html, body {
        max-width: 100%;
        overflow-x: hidden;
        font-size: 0.5 rem;
    }

    /* Touch-Friendly Elements */
    .contact-item,
    .nav-link,
    .social-link {
        min-height: 44px;
        min-width: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Footer */
    footer {
        padding: 2rem 1rem;
    }

    .footer-quote {
        font-size: 1.2rem;
    }

    /* Scrollbar (optional) */
    ::-webkit-scrollbar {
        width: 6px;
    }

    /* WhatsApp Float Button */
    .whatsapp-float {
        width: 50px;
        height: 50px;
        right: 15px;
        bottom: 15px;
    }
}

/* Touch-friendly hover states */
@media (hover: hover) {
    .nav-link:hover::after,
    .contact-item:hover,
    .experience-card:hover {
        transition: all 0.3s ease;
    }
}



@media (max-width: 768px) {
    #carousel-gallery .container {
        width: 280px;
        margin: 30px auto;
    }
    #carousel-gallery .carousel__face {
        width: 250px;
        height: 150px;
    }
    #carousel-gallery span {
        font-size: 1.5rem;
    }
    #carousel-gallery {
        margin-bottom: 50px;
        padding-bottom: 30px;
    }
}

@media (max-width: 480px) {
    #carousel-gallery .container {
        width: 220px;
        margin: 20px auto;
    }
    #carousel-gallery .carousel__face {
        width: 200px;
        height: 120px;
    }
    #carousel-gallery span {
        font-size: 1.2rem;
    }
}
