/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

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

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

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

.nav-logo a {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2563eb;
    text-decoration: none;
}

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

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

.nav-menu a:hover {
    color: #2563eb;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: #333;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 100px 20px 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.highlight {
    color: #fbbf24;
}

.hero-text h2 {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 1.5rem;
    opacity: 0.9;
}

.hero-text p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.8;
    line-height: 1.7;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.btn {
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: #fbbf24;
    color: #1f2937;
}

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

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background: white;
    color: #667eea;
}

.availability-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.availability-badge i {
    color: #22c55e;
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.hero-image {
    display: flex;
    justify-content: center;
}

.profile-img {
    width: 400px;
    height: 400px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    object-position: 30% 10%;
}

/* About Section */
.about {
    padding: 100px 20px;
    background: #f8fafc;
}

.about h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #1f2937;
}

.about-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    align-items: start;
}

.about-text p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: #4b5563;
    line-height: 1.8;
}

.skills h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #1f2937;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-tag {
    background: #2563eb;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Research Section */
.research {
    padding: 100px 20px;
    background: #f8fafc;
}

.research h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #1f2937;
}

.research-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.research-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e5e7eb;
    display: flex;
    flex-direction: column;
    height: 100%;
}

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

.research-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    width: fit-content;
}

.research-icon i {
    font-size: 3rem;
    color: #3b82f6;
}

.research-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: #1f2937;
    font-weight: 600;
    text-align: center;
}

.research-description {
    color: #6b7280;
    line-height: 1.7;
    margin-bottom: 1.5rem;
    text-align: left;
    font-size: 0.95rem;
}

.research-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #3b82f6;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-top: auto;
    font-size: 0.85rem;
}

.research-link:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.3);
}

.research-link i {
    transition: transform 0.3s ease;
}

.research-link:hover i {
    transform: translateX(3px);
}

.research-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background: #f1f5f9;
    color: #475569;
    padding: 0.25rem 0.75rem;
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid #e2e8f0;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Proj
ects Section */
.projects {
    padding: 100px 20px;
    background: #f8fafc;
}

.projects h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #1f2937;
}

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

.project-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.project-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(37, 99, 235, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:hover .project-overlay {
    opacity: 1;
}

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

.project-link {
    color: white;
    font-size: 1.5rem;
    padding: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transition: background 0.3s ease;
}

.project-link:hover {
    background: rgba(255, 255, 255, 0.3);
}

.project-content {
    padding: 1.5rem;
}

.project-content h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: #1f2937;
}

.project-content p {
    color: #4b5563;
    margin-bottom: 1rem;
    line-height: 1.6;
}

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

.tech-tag {
    background: #e5e7eb;
    color: #374151;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
}

/* Publications Section */
.publications {
    padding: 100px 20px;
    background: white;
}

.publications h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #1f2937;
}

.publications-list {
    max-width: 1000px;
    margin: 0 auto;
}

.publication-item {
    padding: 2rem 0;
    border-bottom: 1px solid #e5e7eb;
}

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

.publication-main {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
}

.publication-year {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2563eb;
    min-width: 60px;
    margin-right: 2rem;
    margin-top: 0.5rem;
}

.publication-content {
    flex: 1;
}

.publication-content h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: #1f2937;
    line-height: 1.4;
}

.publication-authors {
    color: #4b5563;
    margin-bottom: 0.25rem;
}

.publication-venue {
    color: #6b7280;
    margin-bottom: 1rem;
}

.publication-links {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: center;
}

.pub-link {
    color: #2563eb;
    text-decoration: none;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: color 0.3s ease;
}

.pub-link:hover {
    color: #1d4ed8;
}

.pub-link i {
    background: none !important;
    background-color: transparent !important;
    color: inherit;
}

.publication-graphic {
    flex-shrink: 0;
    width: 200px;
}

.graphical-abstract {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.graphical-abstract:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.graphical-abstract-video {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.graphical-abstract-video:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.abstract-toggle {
    background: #f3f4f6;
    border: 1px solid #d1d5db;
    color: #374151;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    transition: all 0.3s ease;
}

.abstract-toggle:hover {
    background: #e5e7eb;
    border-color: #9ca3af;
}

.abstract-toggle.active {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
}

.abstract-toggle.active i {
    transform: rotate(180deg);
}

.abstract-toggle i {
    transition: transform 0.3s ease;
}

.publication-abstract {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    background: #f8fafc;
    border-radius: 8px;
    margin-top: 1rem;
}

.publication-abstract.active {
    max-height: 300px;
    padding: 1.5rem;
    border: 1px solid #e5e7eb;
    overflow-y: auto;
    /* Force scroll bars to be visible on all browsers */
    scrollbar-width: thin;
    /* Firefox */
    scrollbar-color: #cbd5e1 #f1f5f9;
    /* Firefox */
}

.publication-abstract p {
    color: #4b5563;
    line-height: 1.7;
    margin: 0;
    text-align: justify;
    hyphens: auto;
}

/* Custom scrollbar for abstract */
.publication-abstract::-webkit-scrollbar {
    width: 8px;
    -webkit-appearance: none;
}

.publication-abstract::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.publication-abstract::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
}

.publication-abstract::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Safari-specific: Force scroll bars to always be visible */
.publication-abstract.active {
    -webkit-overflow-scrolling: touch;
}

/* Add scroll indicator for Safari users */
/* Add fade effect at bottom to indicate more content */
.publication-abstract.active::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 20px;
    background: linear-gradient(to bottom, transparent, rgba(248, 250, 252, 0.8));
    pointer-events: none;
    border-radius: 0 0 8px 8px;
}

/* Add scroll hint text for Safari users */
.publication-abstract.active[data-scrollable="true"]::after {
    content: '↕ Scroll to read more';
    position: absolute;
    bottom: 4px;
    right: 8px;
    font-size: 0.7rem;
    color: #6b7280;
    background: rgba(248, 250, 252, 0.9);
    padding: 2px 6px;
    border-radius: 4px;
    pointer-events: none;
}

.publication-abstract {
    position: relative;
}

/* Simple publication layout (without graphical abstract) - same as featured */
.publication-simple .publication-graphic {
    /* Hide the empty graphic space for simple publications */
    display: none;
}

.publication-simple .publication-content {
    /* When graphic is hidden, content takes full width */
    flex: 1;
    width: 100%;
}

/* Show More Publications Section */
.show-more-section {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid #e5e7eb;
}

.show-more-btn {
    display: block;
    width: 100%;
    padding: 1rem 2rem;
    background: #f8fafc;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    color: #4b5563;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 1rem;
}

.show-more-btn:hover {
    background: #e5e7eb;
    border-color: #d1d5db;
    color: #374151;
}

.show-more-btn.expanded {
    background: #dbeafe;
    border-color: #3b82f6;
    color: #1e40af;
}

.show-more-btn i {
    margin-right: 0.5rem;
}

.hidden-publications {
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Contact Section */
.contact {
    padding: 100px 20px;
    background: #1f2937;
    color: white;
}

.contact h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-info p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    line-height: 1.7;
}

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

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

.contact-method i {
    font-size: 1.2rem;
    color: #fbbf24;
    width: 20px;
}

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

.contact-method a:hover {
    color: #fbbf24;
}

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

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #374151;
    border-radius: 8px;
    background: #374151;
    color: white;
    font-family: inherit;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #9ca3af;
}

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

/* Footer */
.footer {
    background: #111827;
    color: white;
    text-align: center;
    padding: 2rem 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 2rem 0;
    }

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

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-text h1 {
        font-size: 2.5rem;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .research-grid {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .publication-item {
        padding: 1.5rem 0;
    }

    .publication-main {
        flex-direction: column;
        gap: 1rem;
    }

    .publication-year {
        margin-right: 0;
        margin-bottom: 1rem;
    }

    .publication-graphic {
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }

    .publication-links {
        justify-content: flex-start;
    }

    .publication-simple {
        flex-direction: column;
        gap: 1rem;
    }

    .publication-abstract.active {
        max-height: 250px;
        padding: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 200px;
        justify-content: center;
    }
}

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

    .profile-img {
        width: 250px;
        height: 250px;
        object-position: 40% 80%;
    }

    .research-grid {
        grid-template-columns: 1fr;
    }

    .research-card {
        min-width: auto;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .project-card {
        min-width: auto;
    }
}

:root {
    --nav-h: 72px;
}

/* adjust if your navbar is taller/shorter */

/* Any section with an id (your anchors) will stop *below* the navbar */
section[id] {
    scroll-margin-top: calc(var(--nav-h) + 12px);
}

/* Navbar should always be above content */
.navbar {
    position: fixed;
    z-index: 1000;
}

/* Give anchors breathing room under the fixed navbar */
:root {
    --nav-h: 72px;
}

/* adjust if your nav is taller/shorter */
section[id] {
    scroll-margin-top: calc(var(--nav-h) + 12px);
}

/* Ensure the hero (home) never overlays later sections */
.hero {
    position: relative;
    z-index: 0;
    /* put the hero behind */
    overflow: hidden;
    /* just in case of parallax spillover */
}

/* If you use a hero overlay ::before, keep it behind the text */
.hero::before {
    z-index: 0;
}

.hero>* {
    position: relative;
    z-index: 1;
}

/* All other sections should render above the hero */
/*section:not(.hero) {
  position: relative;
  z-index: 1;
  background: #fff;                         /* ensures the next section “covers” the hero */
/* } */
/* instead of: section:not(.hero) { ... } */
.about,
.research,
.projects,
.publications {
    position: relative;
    z-index: 1;
    background: #fff;
}

/* S
oftware Page Styles */
.software-hero {
    padding: 120px 20px 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
}

.software-hero-content h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.software-hero-content p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.software-list {
    padding: 80px 20px;
    background: #f8fafc;
}

.software-grid {
    display: flex;
    flex-direction: column;
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.software-item {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.software-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.software-item:nth-child(even) {
    grid-template-columns: 400px 1fr;
}

.software-item:nth-child(even) .software-content {
    order: 2;
}

.software-item:nth-child(even) .software-video {
    order: 1;
}

.software-content {
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.software-header {
    margin-bottom: 1.5rem;
}

.software-header h2 {
    font-size: 2rem;
    color: #1f2937;
    margin-bottom: 1rem;
}

.software-badges {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.badge-primary {
    background: #2563eb;
    color: white;
}

.badge-secondary {
    background: #6b7280;
    color: white;
}

.badge-success {
    background: #10b981;
    color: white;
}

.software-description {
    font-size: 1.1rem;
    color: #4b5563;
    line-height: 1.7;
    margin-bottom: 2rem;
}

.software-features {
    margin-bottom: 2rem;
}

.software-features h3 {
    font-size: 1.2rem;
    color: #1f2937;
    margin-bottom: 1rem;
}

.software-features ul {
    list-style: none;
    padding: 0;
}

.software-features li {
    color: #4b5563;
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

.software-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #10b981;
    font-weight: bold;
}

.software-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
}

.download-btn {
    background: #2563eb;
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

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

.download-btn.secondary {
    background: #6b7280;
}

.download-btn.secondary:hover {
    background: #4b5563;
}

.software-link {
    color: #2563eb;
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.3s ease;
}

.software-link:hover {
    color: #1d4ed8;
}

.software-video {
    background: #1f2937;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.demo-video {
    width: 100%;
    max-width: 100%;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.video-caption {
    color: #9ca3af;
    font-size: 0.9rem;
    margin-top: 1rem;
    text-align: center;
    font-style: italic;
}

/* Responsive Design for Software Page */
@media (max-width: 1024px) {
    .software-item {
        grid-template-columns: 1fr;
    }

    .software-item:nth-child(even) {
        grid-template-columns: 1fr;
    }

    .software-item:nth-child(even) .software-content {
        order: 1;
    }

    .software-item:nth-child(even) .software-video {
        order: 2;
    }

    .software-content {
        padding: 2rem;
    }
}

@media (max-width: 768px) {
    .software-hero-content h1 {
        font-size: 2.5rem;
    }

    .software-hero-content p {
        font-size: 1.1rem;
    }

    .software-header h2 {
        font-size: 1.5rem;
    }

    .software-description {
        font-size: 1rem;
    }

    .software-links {
        flex-direction: column;
        align-items: stretch;
    }

    .download-btn {
        justify-content: center;
    }

    .software-video {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .software-hero {
        padding: 100px 20px 40px;
    }

    .software-hero-content h1 {
        font-size: 2rem;
    }

    .software-content {
        padding: 1.5rem;
    }

    .software-badges {
        justify-content: center;
    }
}

/* Cita
tion Button Styles */
.cite-btn {
    background: #f3f4f6;
    border: 1px solid #d1d5db;
    color: #374151;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: all 0.3s ease;
    text-decoration: none;
}

.cite-btn:hover {
    background: #e5e7eb;
    border-color: #9ca3af;
    color: #1f2937;
}

/* Citation Modal Styles */
.citation-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.citation-modal-content {
    background-color: white;
    margin: 5% auto;
    border-radius: 12px;
    width: 90%;
    max-width: 700px;
    max-height: 80vh;
    overflow: hidden;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.citation-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid #e5e7eb;
    background: #f8fafc;
}

.citation-modal-header h3 {
    margin: 0;
    color: #1f2937;
    font-size: 1.5rem;
}

.citation-close {
    color: #6b7280;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
    line-height: 1;
}

.citation-close:hover {
    color: #374151;
}

.citation-modal-body {
    padding: 2rem;
}

.citation-format-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.citation-tab {
    background: none;
    border: none;
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    font-size: 1rem;
    color: #6b7280;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.citation-tab:hover {
    color: #374151;
}

.citation-tab.active {
    color: #2563eb;
    border-bottom-color: #2563eb;
}

.citation-content {
    margin-bottom: 1.5rem;
}

#citation-text {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 1.5rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #374151;
    white-space: pre-wrap;
    word-wrap: break-word;
    max-height: 300px;
    overflow-y: auto;
    margin: 0;
}

.copy-btn {
    background: #2563eb;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
}

.copy-btn.copied {
    background: #10b981;
}

.copy-btn.copied::after {
    content: ' Copied!';
}

/* Responsive Citation Modal */
@media (max-width: 768px) {
    .citation-modal-content {
        margin: 10% auto;
        width: 95%;
        max-height: 85vh;
    }

    .citation-modal-header {
        padding: 1rem 1.5rem;
    }

    .citation-modal-body {
        padding: 1.5rem;
    }

    .citation-format-tabs {
        flex-direction: column;
        gap: 0;
    }

    .citation-tab {
        padding: 0.5rem 1rem;
        text-align: left;
        border-bottom: 1px solid #e5e7eb;
        border-radius: 0;
    }

    .citation-tab.active {
        background: #f3f4f6;
        border-bottom-color: #e5e7eb;
    }

    #citation-text {
        font-size: 0.8rem;
        padding: 1rem;
    }
}

/*
 Research Detail Pages */
.research-detail {
    padding: 0 20px 60px;
    background: #f8fafc;
    min-height: 100vh;
    position: relative;
}

.navbar-spacer {
    height: 100px;
    width: 100%;
}
}

.research-header {
    text-align: center;
    margin-bottom: 4rem;
    margin-top: 2rem;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, #f8fafc 0%, #e5e7eb 100%);
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 2rem;
    padding: 0.5rem 1rem;
    background: white;
    border-radius: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.back-link:hover {
    color: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.research-icon-large {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.25);
}

.research-icon-large i {
    font-size: 2rem;
    color: white;
}

.research-detail h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1rem;
    line-height: 1.2;
    text-align: center;
}

.research-subtitle {
    font-size: 1.1rem;
    color: #6b7280;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.5;
    text-align: center;
}

.research-content-detail {
    max-width: 1000px;
    margin: 0 auto;
    background: white;
    border-radius: 16px;
    padding: 3rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.content-section {
    margin-bottom: 3rem;
}

.content-section:last-child {
    margin-bottom: 0;
}

.content-section h2 {
    font-size: 1.8rem;
    color: #1f2937;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 0.5rem;
}

.content-section p {
    color: #4b5563;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    text-align: justify;
}

.research-highlights {
    display: grid;
    gap: 1.5rem;
    margin: 2rem 0;
}

.highlight-item {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: 12px;
    border-left: 4px solid #3b82f6;
}

.highlight-item h3 {
    color: #1f2937;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.highlight-item h3 i {
    color: #3b82f6;
}

.highlight-item p {
    color: #6b7280;
    margin: 0;
    line-height: 1.6;
}

.contribution-list {
    list-style: none;
    padding: 0;
}

.contribution-list li {
    background: #f8fafc;
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    border-radius: 8px;
    border-left: 3px solid #3b82f6;
    color: #4b5563;
    line-height: 1.6;
}

.contribution-list li strong {
    color: #1f2937;
}

.related-publications {
    background: #f0f9ff;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
}

.related-publications h2 {
    border: none;
    margin-bottom: 1.5rem;
}

.pub-links {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.related-publications .pub-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #3b82f6;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.related-publications .pub-link:hover {
    background: #1d4ed8;
}

/* Responsive Design for Research Detail Pages */
@media (max-width: 768px) {
    .research-detail h1 {
        font-size: 2rem;
    }

    .research-subtitle {
        font-size: 1rem;
    }

    .research-header {
        padding: 2rem 1.5rem;
        margin-bottom: 3rem;
    }

    .research-icon-large {
        width: 70px;
        height: 70px;
        margin-bottom: 1.5rem;
    }

    .research-icon-large i {
        font-size: 1.5rem;
    }

    .research-content-detail {
        padding: 2rem 1.5rem;
    }

    .pub-links {
        flex-direction: column;
        align-items: center;
    }

    .pub-link {
        width: 100%;
        max-width: 250px;
        justify-content: center;
    }
}