:root {
    --primary-color: #1a73e8;
    --secondary-color: #034f84;
    --accent-color: #92c7d3;
    --text-color: #333;
    --light-color: #f7f9fc;
    --dark-color: #2c3e50;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    color: var(--text-color);
    line-height: 1.6;
    background-color: #f8f9fa;
    overflow-x: hidden; /* Prevent horizontal scroll */
}

header {
    background: linear-gradient(135deg, rgba(26, 115, 232, 0.8), rgba(3, 79, 132, 0.9)), 
                url("images/photo1.jpeg") center/cover no-repeat fixed;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
    padding: 0 20px;
    position: relative;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 100"><path d="M0,0v46.29c47.79,22.2,103.59,32.17,158,28,70.36-5.37,136.33-33.31,206.8-37.5C438.64,32.43,512.34,53.67,583,72.05c69.27,18,138.3,24.88,209.4,13.08,36.15-6,69.85-17.84,104.45-29.34C989.49,25,1047.93,5.4,1100.92,13.91L1100,0Z" fill="%23ffffff" fill-opacity="0.1"/></svg>') bottom/cover no-repeat;
    animation: wave 3s ease-in-out infinite;
}

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

header h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
    animation: fadeInUp 1s ease-out;
    background: linear-gradient(45deg, #fff, #92c7d3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

header p {
    font-size: 1.5rem;
    max-width: 800px;
    margin-bottom: 30px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    text-decoration: none;
    background-color: var(--primary-color);
    color: white;
    border-radius: 5px;
    font-weight: bold;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

nav {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--secondary-color);
}

.logo span {
    color: var(--primary-color);
}

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

.nav-links li {
    margin-left: 30px;
}

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

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

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    transition: all 0.3s ease;
    background-color: var(--text-color);
}

section {
    padding: 80px 20px;
}

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

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 20px;
}

.section-title p {
    max-width: 700px;
    margin: 0 auto;
    color: #666;
}

.about-content {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 40px;
}

.about-img {
    flex: 1;
    min-width: 300px;
}

.about-img img {
    width: 80%;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.about-text {
    flex: 1;
    min-width: 300px;
}

.about-text h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--secondary-color);
}

section#projects {
    padding: 80px 20px;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.project-card:hover::before {
    transform: scaleX(1);
}

.project-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.project-img {
    position: relative;
    overflow: hidden;
}

.project-img::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(26, 115, 232, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:hover .project-img::after {
    opacity: 1;
}

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

.project-info {
    padding: 20px;
}

.section-title h2 {
    text-align: center;
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 20px;
}

.section-title p {
    max-width: 700px;
    margin: 0 auto;
    color: #666;
}

/* Popup styles */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 15px;  /* Add padding for mobile */
    overflow-y: auto;  /* Allow scrolling if needed */
}

.popup-overlay.active {
    display: flex; /* Show when active */
}

.popup-content {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    width: 100%;
    max-width: 800px;
    max-height: 90vh;  /* Limit height on all devices */
    position: relative;
    margin: auto;  /* Center horizontally */
    overflow-y: auto;  /* Allow scrolling inside popup */
}

.popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 30px;
    cursor: pointer;
    background: none;
    border: none;
    color: #333;
    z-index: 10;  /* Ensure it's always clickable */
}

.popup-title {
    font-size: 2rem;
    margin-bottom: 20px;
    padding-right: 40px;  /* Make room for close button */
}

.popup-img {
    width: 100%;
    margin-bottom: 20px;
    text-align: center;  /* Center the image */
}

.popup-img img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
    border-radius: 5px;
}

.popup-body {
    font-size: 1rem;
    color: #666;
    line-height: 1.6;
}

/* Mobile-specific fixes */
@media (max-width: 768px) {
    .popup-content {
        padding: 15px;
        margin: 10px;
        width: calc(100% - 20px);  /* Account for margins */
    }
    
    .popup-title {
        font-size: 1.5rem;
    }
    
    .popup-overlay {
        align-items: flex-start;  /* Align to top on mobile for better scrolling */
        padding: 10px;
    }
    
    /* Make sure the popup content doesn't exceed viewport */
    .popup-overlay.active {
        overflow-y: auto;
    }
}

/* Fix to ensure content doesn't overflow on very small screens */
@media (max-width: 480px) {
    .popup-content {
        margin: 5px;
        padding: 10px;
        width: calc(100% - 10px);
    }
}



/* Slider container styles */
.projects-slider-container {
    width: 100%;
    overflow: hidden;
    position: relative;
    padding: 20px 0;
}

/* Slider styles */
.projects-slider {
    display: flex;
    transition: transform 0.5s ease;
    animation: slideAnimation 30s linear infinite;
}

/* When hovering over the slider, pause the animation */
.projects-slider-container:hover .projects-slider {
    animation-play-state: paused;
}

/* Project card styles for slider */
.projects-slider .project-card {
    flex: 0 0 300px;
    margin-right: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Animation keyframes for continuous sliding */
@keyframes slideAnimation {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-330px * 3)); /* Adjust based on card width + margin */
    }
}

/* Slider navigation buttons */
.slider-nav {
    text-align: center;
    margin-top: 20px;
}

.slider-nav button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 15px;
    margin: 0 5px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.slider-nav button:hover {
    background-color: var(--secondary-color);
}

/* Research paper Project Slider Styles */

.research-papers-section {
    padding: 80px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

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

.research-heading {
    text-align: center;
    margin-bottom: 60px;
}

.research-heading h2 {
    font-size: 3rem;
    margin-bottom: 15px;
    color: #2c3e50;
    background: linear-gradient(45deg, #3498db, #2c3e50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.research-heading p {
    color: #7f8c8d;
    font-size: 1.2rem;
}

/* Research Papers Grid Layout */
.papers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.paper-card {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.paper-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #3498db, #2980b9);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.paper-card:hover::before {
    transform: scaleX(1);
}

.paper-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.12);
}

.paper-icon {
    text-align: center;
    margin-bottom: 20px;
}

.paper-icon i {
    font-size: 3.5rem;
    color: #3498db;
    background: linear-gradient(45deg, #3498db, #2980b9);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.paper-info h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: #2c3e50;
    font-weight: 600;
    text-align: center;
}

.paper-info p {
    color: #7f8c8d;
    line-height: 1.6;
    margin-bottom: 20px;
    text-align: center;
    font-size: 0.95rem;
}

.paper-meta {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.paper-type, .paper-pages, .paper-year {
    background: #f8f9fa;
    color: #495057;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid #e9ecef;
}

.paper-type {
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: white;
    border: none;
}

.paper-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.view-btn, .download-btn {
    padding: 10px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    border: none;
    cursor: pointer;
}

.view-btn {
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: white;
}

.view-btn:hover {
    background: linear-gradient(45deg, #2980b9, #1f5f8b);
    transform: translateY(-2px);
}

.download-btn {
    background: #f8f9fa;
    color: #495057;
    border: 1px solid #e9ecef;
}

.download-btn:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .papers-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .paper-card {
        padding: 25px 20px;
    }
    
    .paper-actions {
        flex-direction: column;
    }
    
    .view-btn, .download-btn {
        justify-content: center;
    }
}

/* PDF Viewer Modal - Improved */
.pdf-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.pdf-modal-content {
    background: white;
    width: 95%;
    max-width: 1200px;
    height: 90%;
    border-radius: 15px;
    position: relative;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

.pdf-modal-header {
    padding: 20px 25px;
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.pdf-modal-title {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 600;
}

.pdf-modal-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.pdf-modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.pdf-modal-body {
    flex: 1;
    position: relative;
    background: #f8f9fa;
}

.pdf-display-area {
    width: 100%;
    height: 100%;
    position: relative;
}

.pdf-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #7f8c8d;
}

.pdf-loading i {
    font-size: 3rem;
    margin-bottom: 15px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.pdf-display-area iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Mobile responsiveness for PDF modal */
@media (max-width: 768px) {
    .pdf-modal-content {
        width: 98%;
        height: 95%;
    }
    
    .pdf-modal-title {
        font-size: 1.2rem;
        padding: 15px;
    }
}



.gallery {
    background-color: white;
}

.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.gallery-item {
    position: relative;
    height: 250px;
    overflow: hidden;
    border-radius: 10px;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    max-width: 100%;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-item .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .overlay {
    opacity: 1;
}

.stats {
    background-color: var(--secondary-color);
    color: white;
    text-align: center;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}

.stat-item {
    padding: 20px;
}

.stat-number {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 10px;
    color: var(--accent-color);
}

.slider-dots {
    display: flex;
    justify-content: center;
    margin-top: 30px;
}

.dot {
    width: 12px;
    height: 12px;
    background-color: #ccc;
    border-radius: 50%;
    margin: 0 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.dot.active {
    background-color: var(--primary-color);
}

/* Download Button Styling */
.download-resume {
    margin-top: 25px;
}


.download-btn {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: #ffffff;
    padding: 12px 25px;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

/* .download-btn:before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(to left, #3494e6, #ec6ead);
    opacity: 0;
    z-index: -1;
    transition: opacity 0.5s ease;
} */

.download-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.download-btn:hover:before {
    opacity: 1;
}

.download-btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.download-btn i {
    margin-right: 8px;
}

/* Media Query for Mobile Responsiveness */
@media (max-width: 768px) {
    .download-btn {
        padding: 10px 20px;
        font-size: 14px;
    }
    
    .download-resume {
        margin-top: 20px;
        text-align: center;
    }
}


/* Main container styling */
.contact {
    position: relative;
    padding: 80px 0;
    background: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.9)), 
                url('images/water-bg.jpg') center/cover no-repeat fixed;
    overflow: hidden;
}

/* Section title consistent with your theme */
.contact .section-title h2 {
    color: var(--secondary-color);
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

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

/* Contact card styles */
.contact-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    margin: 40px auto;
    max-width: 1200px;
    position: relative;
    z-index: 5;
}

.contact-content {
    display: flex;
    flex-wrap: wrap;
}

/* Contact info side */
.contact-info {
    flex: 1;
    min-width: 300px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 40px;
    position: relative;
}

.info-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.profile-badge {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin: 0 auto 15px;
    overflow: hidden;
    border: 3px solid white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.profile-badge img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.info-header h3 {
    font-size: 1.6rem;
    margin-bottom: 5px;
}

.subtitle {
    opacity: 0.8;
    font-size: 0.95rem;
}

.info-details {
    margin-top: 20px;
}

.contact-detail {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
}

.contact-icon {
    flex: 0 0 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.contact-detail:hover .contact-icon {
    transform: scale(1.1);
    background: white;
    color: var(--primary-color);
}

.contact-detail h4 {
    font-size: 1rem;
    margin-bottom: 5px;
}

.contact-detail p {
    font-size: 0.95rem;
    opacity: 0.9;
}

.contact-detail a {
    color: white;
    text-decoration: none;
    transition: opacity 0.3s;
}

.contact-detail a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

/* Social links */
.social-links {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    gap: 15px;
}

.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.8rem;
}

.social-icon:hover {
    background: white;
    color: var(--primary-color);
    transform: translateY(-3px);
}

/* Form container */
.contact-form-container {
    flex: 1.2;
    min-width: 300px;
    padding: 40px;
    background: white;
}

.form-header {
    margin-bottom: 30px;
    text-align: center;
}

.form-header h3 {
    font-size: 1.6rem;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.form-header p {
    color: #666;
    font-size: 0.95rem;
}

/* Animated form */
.animated-form .form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 0;
}

.form-row .form-group {
    flex: 1;
}

.animated-form input,
.animated-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: none;
    border-bottom: 2px solid #ddd;
    background: #f9f9f9;
    border-radius: 5px 5px 0 0;
    font-size: 1rem;
    transition: all 0.3s;
    color: #333;
}

.animated-form textarea {
    min-height: 120px;
    resize: vertical;
}

.animated-form input:focus,
.animated-form textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.animated-form .focus-border {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.4s;
}

.animated-form input:focus ~ .focus-border,
.animated-form textarea:focus ~ .focus-border {
    width: 100%;
}

/* Submit button */
.btn-submit {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 50px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 5px 15px rgba(var(--primary-color-rgb), 0.3);
    width: auto;
    margin: 0 auto;
}

.btn-submit:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(var(--primary-color-rgb), 0.4);
}

.btn-submit .btn-icon {
    transition: transform 0.3s ease;
}

.btn-submit:hover .btn-icon {
    transform: translateX(5px);
}

/* Optional background elements */
.contact-backdrop {
    position: absolute;
    bottom: -50px;
    right: -50px;
    width: 300px;
    height: 300px;
    background: url('images/water-drop.png') no-repeat center/contain;
    opacity: 0.1;
    z-index: 1;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .contact-content {
        flex-direction: column;
    }
    
    .contact-info, 
    .contact-form-container {
        width: 100%;
    }
    
    .form-row {
        flex-direction: column;
        gap: 0;
    }
}

@media (max-width: 768px) {
    .contact {
        padding: 60px 20px;
    }
    
    .contact-card {
        margin: 30px 10px;
    }
    
    .contact-info,
    .contact-form-container {
        padding: 30px 20px;
    }
}

footer {
    background-color: var(--dark-color);
    color: white;
    padding: 40px 20px;
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.footer-column {
    flex: 1;
    min-width: 250px;
    margin-bottom: 30px;
}

.footer-column h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--accent-color);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    text-decoration: none;
    color: #ddd;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--accent-color);
}

.social-links {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.social-links a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    margin: 0 10px;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background-color: var(--accent-color);
    transform: translateY(-5px);
}

.copyright {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

    header p {
        font-size: 1.2rem;
        padding: 0 15px;
    }

    /* Navigation */
    .nav-links {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 20px 0;
        z-index: 999;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links li {
        margin: 15px 0;
    }

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

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    /* Container padding */
    .container {
        padding: 0 15px;
    }

    /* Section titles */
    .section-title h2 {
        font-size: 2rem;
    }

    .section-title p {
        font-size: 1rem;
    }

    /* Projects/Articles slider */
    .projects-slider-container {
        padding: 10px 0;
    }

    .projects-slider .project-card {
        flex: 0 0 280px;
        margin-right: 15px;
    }

    .project-card {
        margin-bottom: 20px;
    }

    .project-img img {
        height: 180px;
    }

    .project-info {
        padding: 15px;
    }

    .project-info h3 {
        font-size: 1.2rem;
    }

    .project-info p {
        font-size: 0.9rem;
    }

    /* Gallery grid */
    .gallery-container {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 15px;
    }

    .gallery-item {
        height: 180px;
    }

    .gallery-item .overlay h3 {
        font-size: 1rem;
    }

    .gallery-item .overlay p {
        font-size: 0.85rem;
    }

    /* About section */
    .about-content {
        flex-direction: column;
        text-align: center;
    }

    .about-img {
        margin-bottom: 30px;
    }

    .about-img img {
        max-width: 250px;
    }

    .about-text {
        padding: 0;
    }

    .about-text h2 {
        font-size: 1.8rem;
    }

    .about-text p {
        font-size: 0.95rem;
    }

    /* Stats section */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .stat-item h3 {
        font-size: 2rem;
    }

    /* Buttons */
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* Smaller mobile devices (phones in portrait) */
@media (max-width: 480px) {
    /* Header */
    header h1 {
        font-size: 2rem;
    }

    header p {
        font-size: 1rem;
        padding: 0 10px;
    }

    /* Section titles */
    .section-title h2 {
        font-size: 1.6rem;
    }

    .section-title p {
        font-size: 0.9rem;
    }

    /* Projects slider */
    .projects-slider .project-card {
        flex: 0 0 250px;
        margin-right: 10px;
    }

    .project-img img {
        height: 150px;
    }

    .project-info {
        padding: 12px;
    }

    .project-info h3 {
        font-size: 1.1rem;
    }

    .project-info p {
        font-size: 0.85rem;
    }

    /* Gallery */
    .gallery-container {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 10px;
    }

    .gallery-item {
        height: 150px;
    }

    .gallery-item .overlay h3 {
        font-size: 0.9rem;
    }

    .gallery-item .overlay p {
        font-size: 0.75rem;
    }

    /* About section */
    .about-img img {
        max-width: 200px;
    }

    .about-text h2 {
        font-size: 1.5rem;
    }

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

    /* Research papers */
    .paper-card {
        padding: 15px;
    }

    .paper-info h3 {
        font-size: 1.1rem;
    }

    .paper-meta {
        flex-direction: column;
        gap: 5px;
    }

    .paper-meta span {
        font-size: 0.75rem;
    }

    /* Contact section */
    .contact-detail {
        padding: 15px;
    }

    .contact-detail h3 {
        font-size: 1.1rem;
    }

    .contact-detail p {
        font-size: 0.85rem;
    }

    /* Forms */
    input, textarea {
        font-size: 14px;
        padding: 10px;
    }

    /* Buttons */
    .btn {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
}

/* Very small screens (320px) */
@media (max-width: 360px) {
    header h1 {
        font-size: 1.8rem;
    }

    header p {
        font-size: 0.9rem;
    }

    .section-title h2 {
        font-size: 1.4rem;
    }

    .projects-slider .project-card {
        flex: 0 0 220px;
    }

    .gallery-container {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .gallery-item {
        height: 120px;
    }
}

/* Landscape orientation on mobile */
@media (max-height: 500px) and (orientation: landscape) {
    header {
        height: auto;
        min-height: 100vh;
        padding: 80px 20px 40px;
    }

    header h1 {
        font-size: 2rem;
    }

    header p {
        font-size: 1rem;
    }

    .nav-links {
        top: 60px;
    }
}

/* Touch-friendly improvements for mobile devices */
@media (hover: none) and (pointer: coarse) {
    /* Larger touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
        padding: 12px 24px;
    }

    .nav-links a {
        min-height: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 12px 20px;
    }

    /* Disable hover effects on touch devices */
    .project-card:hover {
        transform: none;
    }

    .gallery-item:hover img {
        transform: none;
    }

    /* Make cards tappable with visual feedback */
    .project-card:active {
        transform: scale(0.98);
        opacity: 0.9;
    }

    .gallery-item:active {
        opacity: 0.9;
    }

    /* Larger close buttons */
    .popup-close,
    .pdf-modal-close {
        min-height: 44px;
        min-width: 44px;
        font-size: 1.5rem;
    }

    /* Better form inputs */
    input, textarea, select {
        min-height: 44px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

/* Prevent text selection on interactive elements */
.btn, .project-card, .gallery-item, .nav-links a {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    -webkit-touch-callout: none;
    user-select: none;
}

/* Smooth scrolling for all devices */
html {
    scroll-behavior: smooth;
}

/* Fix for iOS Safari bottom bar */
@supports (-webkit-touch-callout: none) {
    header {
        min-height: -webkit-fill-available;
    }
}

/* Animation classes */
.animate-in {
    animation: slideInUp 0.6s ease-out forwards;
}

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

/* Stagger animation delays */
.project-card:nth-child(1) { animation-delay: 0.1s; }
.project-card:nth-child(2) { animation-delay: 0.2s; }
.project-card:nth-child(3) { animation-delay: 0.3s; }

/* Loading skeleton */
.loading-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}