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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.8;
    color: #1a1a1a;
    background: #f5f1ed;
    min-height: 100vh;
}

.navbar {
    background: #f5f1ed;
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid #e0dad5;
}

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

.logo {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-link {
    color: #1a1a1a;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #ff7b5f;
    border-bottom: 2px solid #ff7b5f;
    padding-bottom: 2px;
}

.linkedin-icon {
    color: #1a1a1a;
    transition: color 0.3s ease;
}

.linkedin-icon:hover {
    color: #0077b5;
}

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

.hero {
    margin-bottom: 100px;
    display: flex;
    gap: 60px;
    align-items: flex-start;
    justify-content: space-between;
}

.hero-left {
    flex: 1;
    max-width: 700px;
}

.hero-right {
    flex-shrink: 0;
}

.profile-image {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.hero-title {
    font-size: 64px;
    font-weight: 700;
    color: #ff7b5f;
    margin-bottom: 40px;
    line-height: 1.2;
}

.wave {
    display: inline-block;
    animation: wave 2s infinite;
}

@keyframes wave {
    0%, 100% { transform: rotate(0deg); }
    10%, 30% { transform: rotate(14deg); }
    20% { transform: rotate(-8deg); }
    40% { transform: rotate(0deg); }
}

.hero-content {
    max-width: 900px;
}

.hero-content p {
    font-size: 18px;
    line-height: 1.8;
    color: #4a4a4a;
    margin-bottom: 20px;
}

.cta-button {
    display: inline-block;
    margin-top: 20px;
    padding: 15px 40px;
    background: #0077b5;
    color: white;
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.cta-button:hover {
    background: #005582;
}

.section-title {
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 2px;
    color: #ff7b5f;
    margin-bottom: 40px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 16px;
}

.section-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e0dad5;
}

.work-experience,
.education,
.projects {
    margin-bottom: 80px;
}

.experience-item,
.education-item {
    margin-bottom: 50px;
}

.experience-item h3,
.education-item h3 {
    font-size: 32px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
}

.role {
    margin-bottom: 20px;
    padding-left: 16px;
    border-left: 2px solid #e0dad5;
}

.role:last-child {
    margin-bottom: 0;
}

.role-header {
    display: flex;
    align-items: baseline;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}

.role-title {
    font-size: 16px;
    font-weight: 600;
    font-style: italic;
    color: #ff7b5f;
}

.role-date {
    font-size: 14px;
    color: #7a7a7a;
    font-variant-numeric: tabular-nums;
}

.description {
    font-size: 16px;
    line-height: 1.8;
    color: #4a4a4a;
    max-width: 900px;
}

.edu-highlight {
    font-weight: 600;
    color: #ff7b5f;
}

.projects-page-title {
    font-size: 48px;
    font-weight: 700;
    color: #ff7b5f;
    margin-bottom: 16px;
    line-height: 1.2;
}

.projects-page-subtitle {
    font-size: 18px;
    color: #4a4a4a;
    margin-bottom: 50px;
    max-width: 700px;
    line-height: 1.6;
}

.project-category {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 12px;
    margin-top: 40px;
}

.project-category:first-of-type {
    margin-top: 0;
}

.project-list {
    max-width: 900px;
    margin-bottom: 10px;
}

.project-item {
    padding: 16px 0;
    border-bottom: 1px solid #e0dad5;
    display: flex;
    align-items: baseline;
    gap: 12px;
    flex-wrap: wrap;
}

.project-item:first-child {
    border-top: 1px solid #e0dad5;
}

.project-name {
    font-size: 18px;
    font-weight: 600;
    color: #ff7b5f;
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.3s ease;
}

.project-name:hover {
    color: #e0634a;
}

.project-desc {
    font-size: 15px;
    color: #4a4a4a;
    flex: 1;
    min-width: 200px;
}

.project-tag {
    font-size: 12px;
    font-weight: 600;
    color: #7a7a7a;
    background: #e8e3de;
    padding: 2px 10px;
    border-radius: 3px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.footer {
    margin-top: 100px;
    padding-top: 40px;
    border-top: 1px solid #e0dad5;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    max-width: 900px;
}

.footer-section h4 {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    color: #1a1a1a;
    margin-bottom: 15px;
    text-transform: uppercase;
}

.footer-section p {
    font-size: 16px;
    color: #4a4a4a;
    line-height: 1.8;
}

.footer-section a {
    color: #4a4a4a;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #ff7b5f;
}

.footer-linkedin {
    color: #1a1a1a;
    transition: color 0.3s ease;
}

.footer-linkedin:hover {
    color: #0077b5;
}

/* Blog Listing Page */
.blog-page-title {
    font-size: 48px;
    font-weight: 700;
    color: #ff7b5f;
    margin-bottom: 16px;
    line-height: 1.2;
}

.blog-page-subtitle {
    font-size: 18px;
    color: #4a4a4a;
    margin-bottom: 50px;
    max-width: 700px;
    line-height: 1.6;
}

.blog-list {
    max-width: 900px;
}

.blog-item {
    padding: 16px 0;
    border-bottom: 1px solid #e0dad5;
    display: flex;
    align-items: baseline;
    gap: 16px;
    flex-wrap: wrap;
}

.blog-item:first-child {
    border-top: 1px solid #e0dad5;
}

.blog-date {
    font-size: 14px;
    color: #7a7a7a;
    white-space: nowrap;
    min-width: 100px;
    font-variant-numeric: tabular-nums;
}

.blog-title {
    font-size: 18px;
    font-weight: 600;
    color: #ff7b5f;
    text-decoration: none;
    flex: 1;
    min-width: 200px;
    transition: color 0.3s ease;
}

.blog-title:hover {
    color: #e0634a;
}

.blog-external-icon {
    font-size: 14px;
    margin-left: 4px;
    opacity: 0.6;
}

.blog-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.blog-tag {
    font-size: 12px;
    font-weight: 600;
    color: #7a7a7a;
    background: #e8e3de;
    padding: 2px 10px;
    border-radius: 3px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.blog-source {
    font-size: 12px;
    font-weight: 600;
    color: #ff7b5f;
    background: rgba(255, 123, 95, 0.1);
    padding: 2px 10px;
    border-radius: 3px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

/* Blog Post Page */
.blog-back-link {
    display: inline-block;
    font-size: 14px;
    color: #ff7b5f;
    text-decoration: none;
    margin-bottom: 40px;
    transition: color 0.3s ease;
}

.blog-back-link:hover {
    color: #e0634a;
}

.blog-post-title {
    font-size: 40px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
    line-height: 1.3;
}

.blog-post-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 48px;
    flex-wrap: wrap;
}

.blog-post-date {
    font-size: 15px;
    color: #7a7a7a;
}

.blog-post-tags {
    display: flex;
    gap: 6px;
}

.blog-post-content {
    max-width: 720px;
    font-size: 17px;
    line-height: 1.9;
    color: #2a2a2a;
}

.blog-post-content h2 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-top: 48px;
    margin-bottom: 16px;
}

.blog-post-content h3 {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a1a;
    margin-top: 36px;
    margin-bottom: 12px;
}

.blog-post-content p {
    margin-bottom: 20px;
}

.blog-post-content a {
    color: #ff7b5f;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.blog-post-content a:hover {
    color: #e0634a;
}

.blog-post-content code {
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.9em;
    background: #e8e3de;
    padding: 2px 6px;
    border-radius: 3px;
}

.blog-post-content pre {
    background: #2a2a2a;
    color: #e8e3de;
    padding: 20px 24px;
    border-radius: 6px;
    overflow-x: auto;
    margin: 24px 0;
    line-height: 1.5;
}

.blog-post-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.blog-post-content blockquote {
    border-left: 3px solid #ff7b5f;
    margin: 24px 0;
    padding: 4px 20px;
    color: #4a4a4a;
    font-style: italic;
}

.blog-post-content img {
    max-width: 100%;
    border-radius: 6px;
    margin: 24px 0;
}

.blog-post-content ul,
.blog-post-content ol {
    margin-bottom: 20px;
    padding-left: 24px;
}

.blog-post-content li {
    margin-bottom: 8px;
}

.blog-post-content .mermaid {
    margin: 32px 0;
    text-align: center;
    background: #ffffff !important;
    border: 1px solid #e0dad5 !important;
    border-radius: 8px;
    padding: 32px 24px;
    overflow-x: auto;
    max-width: none;
    width: calc(100vw - 120px);
    max-width: 960px;
}

.blog-post-content .mermaid svg {
    width: 100% !important;
    height: auto !important;
    min-height: 120px;
}

.blog-post-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 15px;
}

.blog-post-content th {
    background: #e8e3de;
    font-weight: 700;
    text-align: left;
    padding: 10px 14px;
    border: 1px solid #d4cec9;
}

.blog-post-content td {
    padding: 10px 14px;
    border: 1px solid #e0dad5;
}

.blog-post-content tr:nth-child(even) {
    background: rgba(232, 227, 222, 0.3);
}

.blog-post-content hr {
    border: none;
    border-top: 1px solid #e0dad5;
    margin: 48px 0;
}

/* PDF Viewer */
.pdf-viewer {
    margin: 0;
    max-width: none;
    width: calc(100vw - 120px);
    max-width: 960px;
}

.pdf-viewer embed {
    border: 1px solid #e0dad5;
    border-radius: 6px;
}

.pdf-fallback {
    margin-top: 12px;
    font-size: 14px;
    color: #7a7a7a;
}

.pdf-fallback a {
    color: #ff7b5f;
}

/* Publications Listing Page */
.pub-page-title {
    font-size: 48px;
    font-weight: 700;
    color: #ff7b5f;
    margin-bottom: 16px;
    line-height: 1.2;
}

.pub-page-subtitle {
    font-size: 18px;
    color: #4a4a4a;
    margin-bottom: 50px;
    max-width: 700px;
    line-height: 1.6;
}

.pub-list {
    max-width: 900px;
}

.pub-item {
    padding: 28px 0;
    border-bottom: 1px solid #e0dad5;
}

.pub-item:first-child {
    border-top: 1px solid #e0dad5;
}

.pub-title-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.pub-title {
    font-size: 20px;
    font-weight: 700;
    color: #ff7b5f;
    text-decoration: none;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.pub-title:hover {
    color: #e0634a;
}

.pub-authors {
    font-size: 15px;
    color: #4a4a4a;
    margin-top: 6px;
    line-height: 1.6;
}

.pub-venue {
    font-size: 14px;
    color: #7a7a7a;
    font-style: italic;
    margin-top: 4px;
}

.pub-links {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
    align-items: center;
}

.pub-link-btn {
    font-size: 13px;
    font-weight: 600;
    color: #ff7b5f;
    background: rgba(255, 123, 95, 0.1);
    padding: 4px 14px;
    border-radius: 4px;
    text-decoration: none;
    transition: background 0.3s ease;
}

.pub-link-btn:hover {
    background: rgba(255, 123, 95, 0.2);
}

.pub-toggle {
    font-size: 13px;
    font-weight: 600;
    color: #7a7a7a;
    background: #e8e3de;
    padding: 4px 14px;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    transition: background 0.3s ease;
}

.pub-toggle:hover {
    background: #d4cec9;
}

.pub-hidden {
    display: none;
}

.pub-abstract {
    margin-top: 16px;
    padding: 16px 20px;
    background: #faf8f6;
    border-left: 3px solid #ff7b5f;
    border-radius: 0 6px 6px 0;
}

.pub-abstract p {
    font-size: 15px;
    color: #4a4a4a;
    line-height: 1.8;
    margin: 0;
}

.pub-bibtex {
    margin-top: 16px;
}

.pub-bibtex pre {
    background: #2a2a2a;
    color: #e8e3de;
    padding: 16px 20px;
    border-radius: 6px;
    overflow-x: auto;
    font-size: 13px;
    line-height: 1.5;
    margin: 0;
}

.pub-bibtex pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.pub-tags {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
    flex-wrap: nowrap;
}

.pub-tag {
    font-size: 12px;
    font-weight: 600;
    color: #7a7a7a;
    background: #e8e3de;
    padding: 2px 10px;
    border-radius: 3px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

/* Publication Detail Page */
.pub-back-link {
    display: inline-block;
    font-size: 14px;
    color: #ff7b5f;
    text-decoration: none;
    margin-bottom: 40px;
    transition: color 0.3s ease;
}

.pub-back-link:hover {
    color: #e0634a;
}

.pub-detail-title {
    font-size: 36px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
    line-height: 1.3;
    max-width: 800px;
}

.pub-detail-authors {
    font-size: 16px;
    color: #4a4a4a;
    line-height: 1.6;
    margin-bottom: 4px;
}

.pub-detail-venue {
    font-size: 15px;
    color: #7a7a7a;
    font-style: italic;
    margin-bottom: 24px;
}

.pub-detail-buttons {
    display: flex;
    gap: 10px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.pub-btn {
    display: inline-block;
    font-size: 14px;
    font-weight: 600;
    color: white;
    background: #ff7b5f;
    padding: 8px 20px;
    border-radius: 4px;
    text-decoration: none;
    transition: background 0.3s ease;
}

.pub-btn:hover {
    background: #e0634a;
}

.pub-detail-section {
    margin-bottom: 36px;
    max-width: 800px;
}

.pub-detail-section-title {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 12px;
}

.pub-detail-abstract {
    font-size: 16px;
    color: #4a4a4a;
    line-height: 1.8;
}

.pub-detail-image {
    max-width: 100%;
    border-radius: 6px;
    border: 1px solid #e0dad5;
    margin: 12px 0;
}

/* Publication Detail Content (markdown rendered) */
.pub-detail-content {
    max-width: 800px;
    margin-bottom: 36px;
}

.pub-detail-content h2 {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    margin-top: 40px;
    margin-bottom: 16px;
}

.pub-detail-content h3 {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin-top: 28px;
    margin-bottom: 12px;
}

.pub-detail-content p {
    font-size: 16px;
    color: #4a4a4a;
    line-height: 1.8;
    margin-bottom: 16px;
}

.pub-detail-content img {
    max-width: 100%;
    border-radius: 6px;
    border: 1px solid #e0dad5;
    margin: 20px 0;
}

.pub-detail-content ul {
    margin-bottom: 16px;
    padding-left: 24px;
}

.pub-detail-content li {
    font-size: 16px;
    color: #4a4a4a;
    line-height: 1.8;
    margin-bottom: 8px;
}

.pub-detail-content strong {
    color: #1a1a1a;
}

.pub-detail-bibtex {
    background: #2a2a2a;
    color: #e8e3de;
    padding: 20px 24px;
    border-radius: 6px;
    overflow-x: auto;
    font-size: 14px;
    line-height: 1.5;
}

.pub-detail-bibtex code {
    background: none;
    padding: 0;
    color: inherit;
}

@media (max-width: 768px) {
    .nav-container {
        padding: 0 20px;
    }

    .container {
        padding: 40px 20px;
    }

    .hero {
        flex-direction: column-reverse;
        align-items: center;
        gap: 40px;
    }

    .hero-left {
        max-width: 100%;
    }

    .profile-image {
        width: 200px;
        height: 200px;
    }

    .hero-title {
        font-size: 42px;
    }

    .hero-content p {
        font-size: 16px;
    }

    .experience-item h3,
    .education-item h3 {
        font-size: 24px;
    }

    .footer-content {
        flex-direction: column;
        gap: 30px;
    }

    .project-item {
        flex-direction: column;
        gap: 6px;
    }

    .project-desc {
        min-width: 0;
    }

    .blog-page-title {
        font-size: 36px;
    }

    .blog-item {
        flex-direction: column;
        gap: 4px;
    }

    .blog-date {
        min-width: auto;
    }

    .blog-post-title {
        font-size: 28px;
    }

    .blog-post-content {
        font-size: 16px;
    }

    .pub-page-title {
        font-size: 36px;
    }

    .pub-detail-title {
        font-size: 28px;
    }

    .pub-links {
        gap: 6px;
    }
}
