/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

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

:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --text-primary: #111827;
    --text-secondary: #374151;
    --text-tertiary: #6b7280;
    --bg-primary: #ffffff;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f3f4f6;
    --border-color: #e5e7eb;
    --accent-color: #f59e0b;
    --award-color: #dc2626;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: #ffffff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Container */
.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 24px;
}

/* Links */
a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s ease;
}

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

/* Typography */
h1, h2, h3 {
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-primary);
}

h1 {
    font-size: 2.25rem;
    margin-bottom: 0.75rem;
}

h2 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

h3 {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}

p {
    margin-bottom: 0.75rem;
    color: var(--text-secondary);
}

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

em {
    font-style: italic;
}

/* Hero Section */
.hero {
    margin-bottom: 40px;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 36px;
    align-items: start;
    background: transparent;
    padding: 0;
}

.hero-text .name {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bio {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.social-links a {
    font-size: 0.875rem;
    font-weight: 500;
    padding: 6px 14px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.social-links a:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    margin-top: 20px;
}

.hero-image img {
    width: 100%;
    height: auto;
    border-radius: 50%;
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s ease;
}

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

/* Updates Section */
.updates-section {
    margin-bottom: 40px;
    background: transparent;
    padding: 0;
}

.section-header {
    display: flex;
    align-items: baseline;
    margin-bottom: 16px;
    gap: 12px;
}

.section-header h2 {
    margin-bottom: 0;
}

#toggleLink {
    color: var(--primary-color);
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

#toggleLink:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

.updates-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.update-item {
    display: grid;
    grid-template-columns: 90px 1fr;
    gap: 16px;
    padding: 4px 10px;
    border-radius: 6px;
    transition: background-color 0.2s ease;
}

.update-item:hover {
    background: var(--bg-tertiary);
}

.update-item.hidden {
    display: none;
}

.update-date {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
    white-space: nowrap;
}

.update-content {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* Research Section */
.research-section {
    margin-bottom: 40px;
}

.research-section > h2 {
    margin-bottom: 12px;
}

.research-subtitle {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 24px;
}

.research-card {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 28px;
    background: var(--bg-primary);
    padding: 28px;
    border-radius: 12px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-md);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

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

.research-media {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.research-media img {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

.video-container {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 100%;
    overflow: hidden;
    border-radius: 10px;
}

.video-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 10px;
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.3);
    pointer-events: none;
    z-index: 1;
}

.video-container video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

.paper-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.paper-title a {
    color: var(--text-primary);
    transition: color 0.2s ease;
}

.paper-title a:hover {
    color: var(--primary-color);
}

.paper-authors {
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 6px;
    color: var(--text-secondary);
}

.paper-venue {
    font-size: 0.9rem;
    margin-bottom: 10px;
    color: var(--text-secondary);
}

.award {
    color: var(--award-color);
    font-weight: 600;
}

.paper-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.paper-links a {
    font-size: 0.85rem;
    font-weight: 500;
    padding: 5px 10px;
    background: var(--bg-tertiary);
    border-radius: 5px;
    transition: all 0.2s ease;
    position: relative;
    z-index: 10;
}

.paper-links a:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-1px);
}

.paper-links a.coming-soon {
    cursor: help;
}

.paper-links a.coming-soon::after {
    content: "Coming soon";
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    background: var(--text-primary);
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 100;
}

.paper-links a.coming-soon:hover::after {
    opacity: 1;
}

.research-card .paper-authors a {
    position: relative;
    z-index: 10;
}

.paper-description {
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-secondary);
    margin-bottom: 0;
}

/* Teaching Section */
.teaching-section {
    margin-bottom: 40px;
    background: transparent;
    padding: 0;
}

.teaching-section p {
    margin-bottom: 0;
}

/* Footer */
footer {
    text-align: center;
    padding: 32px 0;
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

footer p {
    color: var(--text-tertiary);
    margin-bottom: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 40px 20px;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 32px;
        padding: 32px 24px;
    }

    .hero-text .name {
        font-size: 2rem;
        text-align: center;
    }

    .bio {
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    .hero-image {
        order: -1;
    }

    .hero-image img {
        max-width: 200px;
    }

    .research-card {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 24px;
    }

    .research-media {
        order: -1;
    }

    .update-item {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .updates-section,
    .teaching-section {
        padding: 24px 20px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 32px 16px;
    }

    h1 {
        font-size: 1.75rem;
    }

    .hero-content {
        padding: 24px 20px;
    }

    .social-links {
        gap: 8px;
    }

    .social-links a {
        font-size: 0.85rem;
        padding: 6px 12px;
    }

    .paper-links {
        gap: 8px;
    }

    .paper-links a {
        font-size: 0.85rem;
        padding: 4px 10px;
    }
}

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

.update-item {
    animation: fadeIn 0.3s ease;
}
