/* Academic Portfolio Theme - Light & Dark Mode */
:root {
    /* Light mode (default) */
    --primary: #0369A1;
    --primary-light: #0284C7;
    --secondary: #06B6D4;
    --accent: #F97316;
    
    /* Light mode backgrounds */
    --bg-light: #FFFFFF;
    --bg-secondary: #F9FAFB;
    --bg-tertiary: #F3F4F6;
    --bg-card: #FFFFFF;
    --bg-card-hover: #F9FAFB;
    
    /* Light mode text */
    --text-primary: #000000;
    --text-secondary: #4B5563;
    --text-tertiary: #6B7280;
    --text-muted: #9CA3AF;
    
    /* Borders */
    --border-light: #E5E7EB;
    --border-medium: #D1D5DB;
    
    --white: #FFFFFF;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
}

/* Dark mode */
:root.dark {
    /* Dark mode colors - lighter for better contrast */
    --primary: #0EA5E9;
    --primary-light: #38BDF8;
    --secondary: #60A5FA;
    --accent: #FBBF24;
    
    /* Dark mode backgrounds */
    --bg-light: #1F2937;
    --bg-secondary: #111827;
    --bg-tertiary: #0F172A;
    --bg-card: #1F2937;
    --bg-card-hover: #111827;
    
    /* Dark mode text */
    --text-primary: #FFFFFF;
    --text-secondary: #E5E7EB;
    --text-tertiary: #D1D5DB;
    --text-muted: #9CA3AF;
    
    /* Borders */
    --border-light: #374151;
    --border-medium: #4B5563;
    
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.5);
}

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

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

@keyframes glow {
    0%, 100% {
        box-shadow: var(--shadow-md);
    }
    50% {
        box-shadow: 0 8px 32px rgba(59, 130, 246, 0.2);
    }
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: var(--text-primary);
    background-color: var(--bg-light);
    line-height: 1.6;
    position: relative;
    overflow-x: hidden;
}

/* Navigation */
nav {
    background-color: var(--bg-light);
    border-bottom: 1px solid var(--border-light);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 0.8rem 0;
}

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

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.navbar-brand img {
    height: 45px;
    width: auto;
    transition: transform 0.3s ease, filter 0.3s ease;
    filter: invert(1) brightness(1.1);
}

.navbar-brand:hover img {
    transform: scale(1.05);
}

/* Dark mode logo - use original white */
:root.dark .navbar-brand img {
    filter: none;
}

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

.nav-menu a {
    color: var(--text-tertiary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    animation: slideInLeft 0.5s ease-out;
}

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

.nav-menu a.active {
    color: var(--primary);
}

.nav-menu a.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 1px;
}

/* Mobile menu toggle button */
.menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    gap: 0.4rem;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(10px, 10px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.nav-wrapper {
    display: flex;
    align-items: center;
    gap: 2rem;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }

    .navbar-container {
        padding: 1.5rem 2rem;
    }

    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background-color: var(--bg-light);
        gap: 0;
        list-style: none;
        padding: 1rem 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    .nav-menu.active {
        max-height: 400px;
    }

    .nav-menu li {
        padding: 0;
    }

    .nav-menu a {
        display: block;
        padding: 0.75rem 2rem;
        color: var(--text-tertiary);
        animation: none;
    }

    .nav-menu a:hover {
        background-color: var(--bg-secondary);
        color: var(--primary);
    }

    .nav-menu a.active {
        background-color: var(--bg-secondary);
        color: var(--primary);
    }

    .nav-menu a.active::after {
        display: none;
    }

    .nav-wrapper {
        gap: 0;
    }
}

/* Main Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Hero Section */
.hero {
    padding: 4rem 0;
    background: linear-gradient(135deg, var(--bg-light) 0%, var(--bg-secondary) 100%);
    border-bottom: 1px solid var(--border-light);
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 3rem;
    align-items: flex-start;
}

.hero-text h1 {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    letter-spacing: -0.8px;
    animation: slideInLeft 0.7s ease-out;
}

.page-hero-title {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.hero-text .title {
    font-size: 1.25rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    font-weight: 500;
    animation: slideInLeft 0.8s ease-out;
}

.hero-text p {
    color: var(--text-tertiary);
    line-height: 1.8;
    margin-bottom: 1.5rem;
    font-size: 1rem;
    animation: slideInLeft 0.9s ease-out;
}

.page-subtitle {
    font-size: 1.1rem;
    color: var(--primary);
}

.page-intro {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--text-tertiary);
}

.page-intro-strong {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-tertiary);
}

.page-lead {
    max-width: 900px;
    color: var(--text-tertiary);
}

.section-card-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

.section-card-title-alt {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.section-card-title-large {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.section-card-chip {
    font-size: 0.85rem;
}

.section-card-icon {
    font-size: 1.5rem;
}

.section-person-icon {
    font-size: 1.3rem;
}

.section-person-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
}

.section-person-meta {
    font-size: 0.95rem;
    color: var(--text-tertiary);
    margin: 0 0 0.5rem 0;
}

.centered-lead {
    text-align: center;
    color: var(--text-tertiary);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.news-article-kicker {
    color: var(--primary);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.hero-image {
    width: 280px;
    height: 280px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    border: 2px solid var(--border-medium);
    animation: slideInRight 0.8s ease-out;
}

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

.hero-image img:hover {
    transform: scale(1.02);
}

.cv-button {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white) !important;
    padding: 0.85rem 2rem;
    text-decoration: none !important;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-top: 1rem;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.cv-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4);
}

section:nth-of-type(even) .cv-button {
    background: linear-gradient(135deg, #2563EB 0%, #059669 100%);
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.4);
}

section:nth-of-type(even) .cv-button:hover {
    box-shadow: 0 8px 25px rgba(5, 150, 105, 0.5);
}

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

.social-links a {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--bg-secondary);
    border: 1.5px solid var(--border-light);
    border-radius: 50%;
    color: var(--primary);
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white);
    border-color: var(--primary);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

/* Section Styles */
section {
    padding: 4rem 0;
    border-bottom: 1px solid var(--border-light);
    background-color: var(--bg-light);
}

section:nth-of-type(odd) {
    background-color: var(--bg-light) !important;
}

section:nth-of-type(even) {
    background-color: var(--bg-secondary) !important;
}

.section-news {
    background-color: var(--bg-light) !important;
}

section:last-of-type {
    border-bottom: none;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2.5rem;
    color: var(--primary);
    padding-bottom: 1rem;
    border-bottom: 3px solid var(--primary);
    display: inline-block;
    animation: slideInLeft 0.7s ease-out;
}

/* Education Cards */
.education-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

:root.dark .section-publications {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05) 0%, rgba(6, 182, 212, 0.05) 100%);
}

.education-card {
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    padding: 2rem;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
    animation: fadeIn 0.6s ease-out;
}

.education-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
    border-color: var(--primary);
}

.education-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.education-card .institution {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.education-card .period {
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

/* Interests */
.interests-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.interest-tag {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white);
    padding: 1rem;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
    animation: fadeIn 0.6s ease-out;
    cursor: pointer;
}

.interest-tag:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

/* Experience Timeline */
.experience-timeline {
    border-left: 3px solid var(--primary);
    padding-left: 2rem;
    position: relative;
}

.experience-item {
    margin-bottom: 3rem;
    position: relative;
    padding-bottom: 2rem;
    animation: slideInLeft 0.6s ease-out;
}

.experience-item::before {
    content: '';
    position: absolute;
    left: -2.45rem;
    top: 0;
    width: 16px;
    height: 16px;
    background-color: var(--primary);
    border-radius: 50%;
    border: 3px solid var(--bg-light);
    box-shadow: 0 0 0 3px var(--primary);
}

:root.dark .experience-item::before {
    border-color: var(--bg-light);
}

.experience-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.experience-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
}

.experience-date {
    color: var(--text-tertiary);
    font-size: 0.95rem;
    font-weight: 500;
    white-space: nowrap;
}

.experience-org {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0.5rem 0;
}

.experience-desc {
    color: var(--text-tertiary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0.75rem 0 0 0;
}

/* Publication List */
.publication-list {
    max-width: 100%;
}

.publication-item {
    padding: 2.5rem 0;
    border-bottom: 1px solid var(--border-light);
    display: grid;
    grid-template-columns: 200px 1fr auto;
    gap: 2.5rem;
    align-items: flex-start;
}

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

.publication-featured-image {
    width: 200px;
    height: 140px;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

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

.publication-item:hover .publication-featured-image img {
    transform: scale(1.08);
}

.publication-featured-image.hidden {
    display: none;
}

.publication-item.no-image {
    grid-template-columns: 1fr auto;
}

.publication-content {
    display: flex;
    flex-direction: column;
}

.publication-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.publication-content h3 a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.publication-content h3 a:hover {
    color: var(--secondary);
}

.publication-authors {
    color: var(--text-tertiary);
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.publication-venue {
    color: var(--primary);
    font-weight: 500;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.publication-links {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-self: flex-start;
}

.pub-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-hover) 100%);
    color: var(--primary);
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 1px solid var(--border-light);
}

.pub-link:hover {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white);
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* News Grid (Featured on Home) */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.news-article-section {
    padding: 0 0 4rem;
}

.news-article-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
    gap: 2rem;
    align-items: start;
}

.news-article-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.news-article-image {
    display: block;
    width: 100%;
    height: auto;
}

.news-article-content {
    padding: 2rem;
}

.news-article-content p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.news-article-content h2 {
    margin: 1.75rem 0 0.75rem;
    font-size: 1.35rem;
    color: var(--text-primary);
}

.news-article-content ul {
    margin: 0 0 1.25rem 1.25rem;
    color: var(--text-secondary);
}

.news-article-content a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.news-article-content a:hover {
    text-decoration: underline;
}

.news-article-sidebar {
    display: grid;
    gap: 1.25rem;
}

.news-article-box {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.news-article-box h2 {
    font-size: 1.05rem;
    margin-bottom: 0.75rem;
}

.news-article-link-list {
    list-style: none;
    display: grid;
    gap: 0.65rem;
}

.news-article-link-list a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.news-article-link-list a:hover {
    text-decoration: underline;
}

@media (max-width: 960px) {
    .news-article-layout {
        grid-template-columns: 1fr;
    }
}

.news-card {
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    animation: fadeIn 0.6s ease-out;
    display: flex;
    flex-direction: column;
}

.news-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
    border-color: var(--primary);
}

.news-card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

.news-card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.news-card-date {
    color: var(--text-tertiary);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.news-meta {
    font-size: 0.85rem;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.news-card-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    line-height: 1.4;
    flex-grow: 1;
}

.news-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-weight: 600;
}

.news-card-excerpt {
    color: var(--text-tertiary);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.news-text {
    color: var(--text-tertiary);
    line-height: 1.6;
    flex-grow: 1;
    margin-bottom: 1rem;
}

.news-card-link {
    display: inline-block;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.news-card-link:hover {
    color: var(--secondary);
    transform: translateX(4px);
}

/* News Slider Section */
.news-section {
    padding: 3rem 0;
}

.news-slider-section {
    margin-top: 2rem;
}

.news-slider {
    position: relative;
    padding-bottom: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.news-card {
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    border: 1px solid var(--border-light);
}

.news-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.news-image-wrap {
    width: 100%;
    height: 300px;
    overflow: hidden;
    background: var(--bg-darker);
}

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

.news-card:hover .news-image {
    transform: scale(1.05);
}

.news-body {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.news-title {
    color: var(--primary);
    margin: 0 0 0.5rem 0;
    font-size: 1.3rem;
    line-height: 1.4;
    font-weight: 600;
}

.news-meta {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.news-text {
    color: var(--text-dark);
    line-height: 1.6;
    flex-grow: 1;
    font-size: 0.95rem;
}

.news-text p {
    margin-bottom: 1rem;
}

.news-text a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-text a:hover {
    color: var(--primary);
    text-decoration: underline;
}

.news-text strong {
    color: var(--primary);
    font-weight: 600;
}

.news-text em {
    font-style: italic;
}

/* Swiper Pagination */
.swiper-pagination {
    bottom: 0 !important;
}

.swiper-pagination-bullet {
    background: var(--primary) !important;
    opacity: 0.4;
    transition: all 0.3s ease !important;
}

.swiper-pagination-bullet:hover {
    opacity: 0.7 !important;
}

.swiper-pagination-bullet-active {
    opacity: 1 !important;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%) !important;
}

/* Swiper Navigation Buttons */
.swiper-button-next,
.swiper-button-prev {
    color: var(--primary) !important;
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-hover) 100%);
    border: 1px solid var(--border-light);
    border-radius: 50%;
    width: 44px !important;
    height: 44px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%) !important;
    color: white !important;
    border-color: var(--primary) !important;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.swiper-button-next::after,
.swiper-button-prev::after {
    font-size: 20px !important;
}

/* Testimonials */
.testimonial-item {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-hover) 100%);
    padding: 2rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    border-left: 4px solid var(--primary);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

.testimonial-item:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.testimonial-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.testimonial-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
    box-shadow: var(--shadow-sm);
}

.testimonial-author h4 {
    margin: 0;
    font-size: 1rem;
    color: var(--primary);
}

.testimonial-author p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.stars {
    color: var(--warning, #ffc107);
    margin-left: auto;
}

.testimonial-text {
    color: var(--text-dark);
    line-height: 1.8;
    font-style: italic;
}

/* Footer */
footer {
    background-color: var(--bg-secondary);
    border-top: 2px solid var(--primary);
    padding: 4rem 0 2rem;
    margin-top: 6rem;
}

.footer-logo-section {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-light);
}

.footer-logo {
    height: 60px;
    width: auto;
    flex-shrink: 0;
    filter: invert(1) brightness(1.1);
    transition: transform 0.3s ease, filter 0.3s ease;
}

.footer-logo:hover {
    transform: scale(1.05);
}

:root.dark .footer-logo {
    filter: none;
}

.footer-logo-text h3 {
    color: var(--text-primary);
    font-weight: 700;
    margin: 0;
    font-size: 1.3rem;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-logo-text p {
    color: var(--text-tertiary);
    margin: 0.5rem 0 0 0;
    font-size: 0.9rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    margin-bottom: 3rem;
}

@media (max-width: 1200px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
    }

    .footer-logo-section {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
}

.footer-section {
    padding: 0;
}

.footer-section h4 {
    color: var(--text-primary);
    font-weight: 700;
    margin-bottom: 1.2rem;
    font-size: 1.15rem;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

.footer-section p, .footer-section a {
    color: var(--text-tertiary);
    text-decoration: none;
    font-size: 0.95rem;
    line-height: 2;
    transition: color 0.3s ease, transform 0.3s ease;
}

.footer-section a:hover {
    color: var(--primary);
    transform: translateX(2px);
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid var(--border-light);
    padding-top: 2.5rem;
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

/* Consulting Page Styles */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.service-card {
    padding: 2rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    transition: all 0.3s ease;
    text-align: center;
}

.service-card:hover {
    border-color: var(--primary);
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.15);
    transform: translateY(-4px);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.service-card h3 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.service-card p {
    color: var(--text-tertiary);
    line-height: 1.6;
}

.expertise-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.expertise-item {
    padding: 2rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.expertise-item h4 {
    color: var(--primary);
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.expertise-item ul {
    list-style: none;
    padding: 0;
}

.expertise-item li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.expertise-item li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--secondary);
    font-weight: bold;
}

/* Testimonials Slider */
.testimonials-slider {
    padding-bottom: 2rem;
}

.testimonials-slider .swiper-slide {
    height: auto;
    padding: 1rem;
}

.testimonial-card {
    padding: 2rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-left: 4px solid var(--primary);
    border-radius: 8px;
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.testimonial-card:hover {
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.15);
    transform: translateY(-4px);
}

.testimonial-header {
    margin-bottom: 1rem;
}

.stars {
    color: var(--secondary);
    font-size: 1.1rem;
    letter-spacing: 2px;
}

.testimonial-text {
    color: var(--text-tertiary);
    line-height: 1.8;
    margin-bottom: 1rem;
    font-style: italic;
    flex-grow: 1;
}

.testimonial-author {
    color: var(--text-primary);
    font-weight: 600;
    margin: 0;
}

/* Swiper pagination */
.testimonials-slider .swiper-pagination {
    position: relative;
    margin-top: 1rem;
    bottom: auto;
}

.testimonials-slider .swiper-pagination-bullet {
    background-color: var(--primary);
    opacity: 0.5;
}

.testimonials-slider .swiper-pagination-bullet-active {
    background-color: var(--primary);
    opacity: 1;
}

.cta-section {
    background: var(--card-bg);
    border: 2px solid var(--primary);
    border-radius: 12px;
    padding: 3rem 2rem;
    text-align: center;
}

.cv-button {
    display: inline-block;
    padding: 0.75rem 2rem;
    background-color: var(--primary);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
    font-weight: 600;
}

.cv-button:hover {
    background-color: var(--primary);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.4);
    transform: translateY(-2px);
}

/* Responsive for consulting page */
@media (max-width: 768px) {
    .services-grid,
    .expertise-grid {
        grid-template-columns: 1fr;
    }
    
    .cta-section {
        padding: 2rem 1.5rem;
    }

    .testimonials-slider .swiper-slide {
        padding: 0.5rem;
    }

    .testimonial-card {
        padding: 1.5rem;
    }
}

/* Theme Toggle */
.theme-toggle {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 8px;
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border-light);
}

.theme-toggle:hover {
    background-color: var(--bg-tertiary);
    transform: scale(1.05);
}

.theme-icon {
    display: inline-flex;
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    font-size: 1.3rem;
}

.theme-toggle:active .theme-icon {
    transform: rotate(180deg);
}

/* Accent color styles for links and CTAs */
a {
    transition: color 0.3s ease;
}

.pub-link, 
a[href^="mailto"], 
.contact-link {
    color: var(--primary);
    font-weight: 500;
}

.pub-link:hover, 
a[href^="mailto"]:hover, 
.contact-link:hover {
    color: var(--secondary);
    text-decoration: underline;
}

/* Accent highlights */
.highlight {
    color: var(--accent);
    font-weight: 600;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-content {
        grid-template-columns: 1fr;
        grid-auto-flow: dense;
    }

    .hero-image {
        order: -1;
        width: 100%;
        max-width: 280px;
        margin: 0 auto 2rem;
    }

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

    .publication-item {
        grid-template-columns: 1fr;
    }

    .nav-menu {
        gap: 1rem;
        font-size: 0.9rem;
    }

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

    .interests-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.cookie-settings-link {
    background: none;
    border: none;
    color: var(--primary);
    font-size: inherit;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
}

.cookie-settings-link:hover {
    color: var(--secondary);
}

.cookie-consent-banner {
    position: fixed;
    bottom: 1.25rem;
    left: 1.25rem;
    right: 1.25rem;
    z-index: 1000;
    display: flex;
    justify-content: center;
}

.cookie-consent-banner.hidden {
    display: none;
}

.cookie-consent-content {
    width: 100%;
    max-width: 760px;
    background: var(--bg-card);
    border: 1px solid var(--border-medium);
    border-radius: 10px;
    box-shadow: var(--shadow-lg);
    padding: 1rem 1.1rem;
}

.cookie-consent-title {
    font-size: 1rem;
    color: var(--text-primary);
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.cookie-consent-text {
    color: var(--text-tertiary);
    font-size: 0.92rem;
    margin-bottom: 0.4rem;
}

.cookie-consent-links a {
    color: var(--primary);
    text-decoration: underline;
}

.cookie-consent-actions {
    display: flex;
    gap: 0.7rem;
    justify-content: flex-end;
    margin-top: 0.85rem;
}

.cookie-btn {
    border-radius: 6px;
    border: 1px solid var(--border-medium);
    padding: 0.5rem 0.8rem;
    font-size: 0.9rem;
    cursor: pointer;
}

.cookie-btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.cookie-btn-primary {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

@media (max-width: 768px) {
    .cookie-consent-banner {
        bottom: 0.8rem;
        left: 0.8rem;
        right: 0.8rem;
    }

    .cookie-consent-actions {
        flex-direction: column;
    }

    .cookie-btn {
        width: 100%;
    }
}
