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

body {
    /* font-family: 'Arial', sans-serif; */
    font-family: 'Montserrat', sans-serif;
    color: #333;
    line-height: 1.6;
}

/* Header Section */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px 10%; /* Increased vertical padding and horizontal padding */
    flex-wrap: wrap;
}

.logo {
    font-size: 1.3rem;
    margin-right: 20px;
}

.logo img {
    width: 50px;
}

nav {
    display: flex;
    align-items: center;
}

nav a {
    text-decoration: none;
    color: #555;
    margin-left: 30px; /* Increased spacing between nav items */
}

nav a.download-cv-button {
    border: 2px solid #3f6ab0;
    padding: 5px 15px;
    border-radius: 25px;
    color: #3f6ab0;
    display: inline-block;
    text-decoration: none;
    font-size: 1rem;
    font-weight: bold;
    transition: background-color 0.3s ease, color 0.3s ease;
}

nav a.download-cv-button:hover {
    background-color: #3f6ab0;
    color: #fff;
}

/* Main Section */
.main {
    text-align: center;
    padding: 150px 20px;
}

h1 {
    font-size: 2.5rem;
    color: #333;
    font-weight: bold;
}

p {
    font-size: 1.2rem;
    color: #666;
}

.profile-pic {
    margin-top: 50px;
    width: 250px;
    border-radius: 50%;
}

.devices {
    margin-top: 60px;
    margin-bottom: -161px;
}

.devices img {
    width: 100%;
    max-width: 800px;
}

/* Introduction Section */
.about {
    background-color: #3f6ab0;
    color: white;
    padding-top: 100px;
    padding-bottom: 170px;
    position: relative;
    z-index: 1;
    text-align: center;
}

.about h2 {
    font-size: 2rem;
}

.about p {
    font-size: 1.1rem;
    color: #ffffff;
    margin-top: 20px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Cards Section */
.cards {
    display: flex;
    justify-content: center;
    padding: 50px 20px;
    max-width: 1350px;
    margin: -150px auto 0 auto;
    position: relative;
    z-index: 2;
}

.card {
    flex: 1;
    background: white;
    padding: 20px;
    border: 1px solid #bebebe;
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
    margin: 0;
    min-height: 450px;
}

/* Horizontal layout styling */
.card:first-child {
    border-radius: 20px 0 0 20px; /* Round the left side only */
}

.card:last-child {
    border-radius: 0 20px 20px 0; /* Round the right side only */
    margin-left: -1px
}

.card:not(:first-child):not(:last-child) {
    border-radius: 0; /* No border-radius for middle cards */
    margin-left: -1px; /* Increased overlap for horizontal layout */
}

@media (max-width: 1200px) {
    .cards {
        flex-direction: column;
        align-items: center;
    }

    .card {
        width: 100%;
        max-width: 400px;
        margin: -1px 0 0 0; /* Negative top margin to make cards touch */
        min-height: auto; /* Allow cards to expand based on content */
        box-sizing: border-box; /* Ensure padding is included in width calculation */
    }

    /* Vertical layout styling */
    .card:first-child {
        border-radius: 20px 20px 0 0; /* Round top corners for first card */
        margin-top: 0; /* No negative margin for first card */
    }

    .card:last-child {
        border-radius: 0 0 20px 20px; /* Round bottom corners for last card */
    }

    .card:not(:first-child):not(:last-child) {
        border-radius: 0; /* Keep middle card(s) without rounded corners */
        margin-left: 0; /* Reset margin for vertical layout */
    }
}

.icon img {
    width: 90px; /* Adjust the size as needed */
    height: auto; /* Maintain aspect ratio */
    display: inline-block;
    margin-bottom: 20px; /* Add space between the icon and the heading */
    margin-top: 30px;
    margin-bottom: 30px;
}

.card p {
    margin-top: 10px;
    margin-bottom: 20px;
}

.card > ul {
    list-style: none;
    text-align: center;
    padding: 0;
}

.card > ul > li {
    margin-bottom: 5px;
    font-size: 1.1rem;
    color: #555;
}

.card > ul > li > span {
    display: block;
    color: #3f6ab0;
    font-weight: bold;
    margin-bottom: 5px;
    margin-top: 20px;
}

/* Nested list for tools */
.second-list {
    list-style: disc;
    padding-left: 20px;
    text-align: left;
    margin-bottom: 40px;
}

.second-list li {
    margin-bottom: 5px;
    padding-left: 5px;
}

/* .second-list:has(li:nth-child(6)) {
    column-count: 2;
    column-gap: 20px;
    text-align: center;
}

.second-list:has(li:nth-child(6)) li {
    break-inside: avoid;
} */

/* Get in Touch Section */
.get-in-touch {
    text-align: center;
    padding: 100px 20px;
    background-color: #fff;
    color: #333;
}

.get-in-touch h2 {
    font-size: 2rem;
    color: #3f6ab0;
    margin-bottom: 10px;
}

.get-in-touch p {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 30px;
}

.get-in-touch .button {
    display: inline-block;
    padding: 10px 30px;
    border: 2px solid #3f6ab0;
    border-radius: 30px;
    color: #3f6ab0;
    text-decoration: none;
    font-size: 1rem;
    font-weight: bold;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.get-in-touch .button:hover {
    background-color: #3f6ab0;
    color: #fff;
}

/* Footer Section */
.footer {
    text-align: center;
    padding: 80px 20px;
    background-color: #3f6ab0;
    color: white;
}

.footer-logo img {
    width: 60px;
    margin-bottom: 20px;
}

.footer p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: rgba(255, 255, 255, 0.7);
}

.footer .social-icons {
    margin-bottom: 20px;
}

.footer .social-icons a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.5rem;
    margin: 0 10px;
    text-decoration: none;
}

.footer .footer-text {
    font-size: 0.9rem;
    margin-bottom: 0px;
}

.footer .footer-made-with {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: -50px; /* Adjust margin */
}

/* Additional Styling */
.footer .social-icons a:hover {
    color: #ccccff;
}


.icon-tooltip {
    position: relative;
    display: inline-block;
}

.tooltip {
    visibility: hidden;
    background-color: #555;
    color: #fff;
    text-align: center;
    padding: 5px;
    border-radius: 5px;
    position: absolute;
    z-index: 1;
    bottom: 125%; /* Position the tooltip above the element */
    left: 50%;
    transform: translateX(-50%); /* Center the tooltip */
    width: 160px;
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 0.9rem;
}

.icon-tooltip:hover .tooltip, .footer-text:hover .tooltip {
    visibility: visible;
    opacity: 1;
}


.icon-tooltip, .footer-text {
    position: relative;
    display: inline-block;
}

.footer-text:hover .tooltip {
    visibility: visible;
    opacity: 1;
}

/* Research Section */
.about-research {
    background-color: #3f6ab0;
    color: white;
    padding: 70px 0; /* Keep vertical padding */
    width: 100%;
}

.about-research-container {
    padding-left: 10%;
    padding-right: 10%;
    max-width: none; /* Remove max-width to allow continuous growth */
    margin: 0 auto;
    text-align: justify;
}

.about-research h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    text-align: left;
}

.about-research p {
    font-size: 1.1rem;
    color: white;
    margin-top: 20px;
    text-align: justify;
}

.research-list {
    margin-top: 20px;
    font-size: 1.1rem;
    text-align: left;
    padding-left: 50px;
}

.research-list li {
    font-size: 1.1rem;
}

.research-section {
    padding: 60px 0;
    background-color: white;
    display: flex;
    flex-direction: column;
    align-items: center; /* Center the courses */
}

.research-section h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 50px;
    color: #3f6ab0;
}

/* Research Items */
.research-item {
    display: flex;
    gap: 40px;
    margin-bottom: 50px;
    background-color: #fff;
    padding: 20px;
    border: 1px solid #bebebe;
    border-radius: 20px;
    width: 80%;
    max-width: none;
    align-items: flex-start;
}

.research-details {
    flex: 1; /* Allows the element to grow and fill available space */
    width: auto; /* Overrides any fixed width */
}

.image-container {
    flex: 0 0 300px; /* Fixed width to prevent resizing */
}

.image-container img.paper-img {
    width: 300px; /* Fixed width */
    height: auto; /* Maintain aspect ratio */
    border-radius: 10px;
    object-fit: cover;
}

.research-details h3 {
    font-size: 1.8rem;
    color: #3f6ab0;
    margin-bottom: 10px;
}

.research-details p {
    font-size: 1.1rem;
    margin-bottom: 20px;
    color: #666;
    text-align: justify;
}

.research-details p strong {
    font-weight: bold;
    color: #3f6ab0;
}

.research-details a.coauthor-hlink {
    color: #3f6ab0;
    text-decoration: none;
}

.research-details a.coauthor-hlink:hover {
    text-decoration: underline;
}

@media (max-width: 1200px) {
    .research-item {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .research-item img.paper-img {
        width: 100%;
        max-width: 300px; 
        margin-bottom: 20px;
    }

    .research-details {
        width: 100%;
    }

    .research-details-blog {
        width: 100%;
    }
}

/* Buttons */
.research-details .button {
    display: inline-block;
    padding: 10px 30px;
    border: 2px solid #3f6ab0;
    border-radius: 30px;
    color: #3f6ab0;
    text-decoration: none;
    font-size: 1rem;
    font-weight: bold;
    transition: background-color 0.3s ease, color 0.3s ease;
    margin-right: 10px; /* Add some space between buttons horizontally */
    margin-bottom: 5px; /* Add a small space below buttons for when they wrap */
}

.research-details .button:hover {
    background-color: #3f6ab0;
    color: #fff;
}


@media (max-width: 1200px) {
    .research-details .button {
        display: block;
        width: 200px; /* Or whatever width you prefer */
        margin: 0 auto 15px auto; /* Center the button and add more space below */
    }

    .research-details .button:last-child {
        margin-bottom: 0; /* Remove bottom margin from the last button */
    }
}

/* Course Section */
.course-section {
    padding: 60px 0;
    background-color: white;
    display: flex;
    flex-direction: column;
    align-items: center; /* Center the courses */
}

.course {
    background: white;
    padding: 20px;
    margin-bottom: 50px;
    border: 1px solid #bebebe;
    border-radius: 20px;
    width: 80%;
    max-width: none;
}

.course-content {
    flex: 1; 
    width: auto; 
}

.course h3 {
    max-width: 100%;
    font-size: 2rem;
    color: #3f6ab0;
    margin-bottom: 20px;
}

.course p {
    max-width: 100%;
    text-align: justify;
    font-size: 1.1rem;
    margin-bottom: 20px;
    color: #666;
}

.course .button {
    width: auto;
    display: inline-block;
}

.course p strong {
    font-weight: bold;
    color: #3f6ab0;
}

.course a.coauthor-hlink {
    color: #3f6ab0;
    text-decoration: none;
}

.course a.coauthor-hlink:hover {
    text-decoration: underline;
}

.course .button {
    display: inline-block;
    padding: 10px 30px;
    border: 2px solid #3f6ab0;
    border-radius: 30px;
    color: #3f6ab0;
    text-decoration: none;
    font-size: 1rem;
    font-weight: bold;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.course .button:hover {
    background-color: #285080;
    color: #fff;
}

.slides-gallery {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.slides-gallery a {
    display: block;
}

.slides-gallery img.slide-thumb {
    width: 100%;
    height: auto;
    border-radius: 5px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.slides-gallery img.slide-thumb:hover {
    transform: scale(1.05); /* Slight zoom effect */
}

@media (max-width: 768px) {
    .course {
        padding: 15px;
        text-align: center;
    }

    .course h3 {
        font-size: 1.8rem;
    }

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

    .slides-gallery {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }
}

/* Blog Post Styling */
.blog-section {
    padding: 60px 0;
    background-color: white;
    display: flex;
    flex-direction: column;
    align-items: center; /* Center the blog posts */
}

.blog-post {
    background-color: white;
    border: 1px solid #bebebe;
    border-radius: 20px;
    width: 80%;
    max-width: none;
    margin: 0 auto 50px auto;
    box-sizing: border-box;
}

/* Padding for different screen sizes */
@media (min-width: 1201px) {
    .blog-post {
        padding: 50px 80px; /* Increased padding for wider screens */
    }
}

@media (max-width: 1200px) and (min-width: 769px) {
    .blog-post {
        width: 90%;
        padding: 40px 60px; /* Slightly less padding for medium screens */
    }
}

@media (max-width: 768px) {
    .blog-post {
        width: 95%;
        padding: 30px 40px; /* Less padding for mobile screens */
    }
}

.blog-post h1 {
    font-size: 2.5rem;
    color: #3f6ab0;
    margin-bottom: 20px;
    text-align: left;
}

.blog-post p {
    font-size: 1.2rem;
    color: #666;
    line-height: 1.7;
    margin-bottom: 20px;
    text-align: left;
    text-align: justify;
}

.blog-post h2 {
    font-size: 1.8rem;
    color: #3f6ab0;
    margin-top: 30px;
    margin-bottom: 15px;
    text-align: left;
}

.blog-post h3 {
    font-size: 1.2rem;
    color: #3f6ab0;
    margin-top: 30px;
    margin-bottom: 15px;
    text-align: left;
}

.blog-post a {
    color: #3f6ab0;
    text-decoration: none;
}

.blog-post a:hover {
    text-decoration: underline;
}

.blog-post ul {
    padding: 0 40px 5px;
    font-size: 1.1rem;
    color: #666;
    text-align: left;
}

/* Research Blog */
.research-details-blog {
    flex-grow: 1;
    width: 100%;
}

.research-details-blog h3 {
    font-size: 1.8rem;
    color: #3f6ab0;
    margin-bottom: 10px;
}

.research-details-blog p {
    font-size: 1.1rem;
    margin-bottom: 20px;
    color: #666;
    text-align: justify;
}

.research-details-blog p strong {
    font-weight: bold;
    color: #3f6ab0;
}


@media (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 20px 5%; /* Slightly reduced padding for mobile */
    }

    .logo {
        margin-right: 0;
        margin-bottom: 15px;
    }

    nav {
        flex-direction: column;
        width: 100%;
    }

    nav a {
        margin: 10px 0;
        width: 100%;
        padding: 10px 0;
    }

    nav a.download-cv-button {
        width: auto; /* Override the full width for this button */
        margin: 10px auto; /* Center the button */
    }

    header, .about-research-container {
        padding-left: 5%;
        padding-right: 5%;
    }

    .blog-post {
        width: 95%; /* Almost full width on mobile */
        padding: 20px 30px;
    }

    .blog-post h1 {
        font-size: 2rem;
    }

    .blog-post p, .blog-post ul {
        font-size: 1.1rem;
    }
}

@media (max-width: 1200px) {
    .blog-post {
        width: 90%; /* Slightly wider on smaller screens */
        padding: 30px 50px;
    }
}

/* Responsive adjustments for both research-item and course */
@media (max-width: 1200px) {
    .research-item, .course {
        width: 90%; /* Slightly wider on smaller screens */
    }
}

@media (max-width: 768px) {
    .research-item, .course {
        width: 95%; /* Almost full width on mobile */
    }
}

/* Ensure consistent padding with header */
.research-item, .course {
    padding-left: 5%;
    padding-right: 5%;
}

@media (max-width: 768px) {
    header, .research-item, .course {
        padding-left: 5%;
        padding-right: 5%;
    }
}

