/* ========================================================
   NOTION DESIGN SYSTEM - STYLE SHEET
   ======================================================== */

/* GLOBAL TOKENS */
:root {
    /* Fonts */
    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
    --font-mono: SFMono-Regular, Consolas, "Liberation Mono", Menlo, Courier, monospace;

    /* Notion Light Mode Colors */
    --bg-primary: #ffffff;
    --bg-sidebar: #fbfbfa;
    --border-color: rgba(55, 53, 47, 0.16);
    --border-strong: rgba(55, 53, 47, 0.28);
    --text-primary: #37352f;
    --text-secondary: #787774;
    --text-muted: #9b9a97;
    --hover-bg: rgba(55, 53, 47, 0.04);
    --active-bg: rgba(55, 53, 47, 0.08);
    --shadow-sm: 0 1px 2px rgba(15, 15, 15, 0.05);
    --shadow-md: 0 4px 12px rgba(15, 15, 15, 0.06), 0 2px 4px rgba(15, 15, 15, 0.04);
    --shadow-lg: 0 12px 24px rgba(15, 15, 15, 0.08), 0 4px 8px rgba(15, 15, 15, 0.05);
    
    /* Notion Brand Accent */
    --accent-blue: #0b6e9f;
    --accent-blue-bg: #d3e5ef;
    
    /* Cover Banner Gradient - Premium Light */
    --gradient-cover: #ffffff;
    --gradient-hero-text: linear-gradient(135deg, #1d4ed8, #2563eb, #3b82f6);

    /* Notion Tag Colors - Light Mode */
    --tag-red-bg: #ffe2dd; --tag-red-txt: #d4402a;
    --tag-orange-bg: #fadec9; --tag-orange-txt: #e87a32;
    --tag-yellow-bg: #fdecc8; --tag-yellow-txt: #dfab01;
    --tag-green-bg: #dbeddb; --tag-green-txt: #0f7b44;
    --tag-blue-bg: #d3e5ef; --tag-blue-txt: #0b6e9f;
    --tag-purple-bg: #e8deee; --tag-purple-txt: #9059b2;
    --tag-pink-bg: #f5e0e9; --tag-pink-txt: #d1578a;
    --tag-gray-bg: #e3e2e0; --tag-gray-txt: #5a5a57;

    /* Transitions */
    --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-spring: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.15);
}

/* DARK MODE OVERRIDES */
body.dark-mode {
    --bg-primary: #191919;
    --bg-sidebar: #202020;
    --border-color: rgba(255, 255, 255, 0.15);
    --border-strong: rgba(255, 255, 255, 0.26);
    --text-primary: #ebece6;
    --text-secondary: #9b9b9b;
    --text-muted: #606060;
    --hover-bg: rgba(255, 255, 255, 0.05);
    --active-bg: rgba(255, 255, 255, 0.09);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4), 0 2px 4px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 12px 24px rgba(0, 0, 0, 0.5), 0 4px 8px rgba(0, 0, 0, 0.4);

    --accent-blue: #539dfa;
    --accent-blue-bg: #0f3a52;

    --gradient-cover: #0f172a;
    --gradient-hero-text: linear-gradient(135deg, #60a5fa, #3b82f6, #06b6d4);

    /* Notion Tag Colors - Dark Mode */
    --tag-red-bg: #591b15; --tag-red-txt: #ff7360;
    --tag-orange-bg: #5c2b0b; --tag-orange-txt: #ffa870;
    --tag-yellow-bg: #573d08; --tag-yellow-txt: #ffeb85;
    --tag-green-bg: #1c3d24; --tag-green-txt: #6adc8f;
    --tag-blue-bg: #0f3a52; --tag-blue-txt: #75c9ff;
    --tag-purple-bg: #411751; --tag-purple-txt: #e2b3ff;
    --tag-pink-bg: #551733; --tag-pink-txt: #ff9ec6;
    --tag-gray-bg: #2c2c2c; --tag-gray-txt: #d3d3d3;
}

/* ========================================================
   BASE STYLES
   ======================================================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 60px;
    height: 100%;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    transition: background-color var(--transition-smooth), color var(--transition-smooth);
    height: 100%;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.3;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition-fast);
}

ul, ol {
    list-style: none;
}

button {
    font-family: inherit;
    border: none;
    background: none;
    cursor: pointer;
    color: inherit;
}

/* SCROLLBAR */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--border-strong);
}

/* ========================================================
   LAYOUT: SIDEBAR & MAIN CONTENT
   ======================================================== */
#app-container {
    display: flex;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    position: relative;
}

/* SIDEBAR */
#sidebar {
    width: 240px;
    background-color: var(--bg-sidebar);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    height: 100%;
    transition: transform var(--transition-smooth), margin-left var(--transition-smooth);
    z-index: 999;
}

#sidebar.collapsed {
    margin-left: -240px;
    transform: translateX(-240px);
}

/* Sidebar Toggle Buttons */
.sidebar-trigger {
    position: fixed;
    top: 14px;
    left: 14px;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    box-shadow: var(--shadow-sm);
    z-index: 1000;
    transition: all var(--transition-fast);
    opacity: 0;
    pointer-events: none;
}

.sidebar-trigger.visible {
    opacity: 1;
    pointer-events: auto;
}

.sidebar-trigger:hover {
    background: var(--hover-bg);
    color: var(--text-primary);
    transform: scale(1.05);
}

.sidebar-backdrop {
    display: none;
}

/* Sidebar Headers */
.sidebar-header {
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-family: var(--font-heading);
    font-size: 1.05rem;
    color: var(--text-primary);
}

.sidebar-brand-avatar {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    object-fit: cover;
}

.sidebar-close {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}

.sidebar-close:hover {
    background: var(--hover-bg);
    color: var(--text-primary);
}

/* Sidebar Menu Content */
.sidebar-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 16px 8px;
}

.sidebar-section-title {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    padding: 6px 12px;
    margin-top: 14px;
    margin-bottom: 4px;
}

.sidebar-section-title:first-child {
    margin-top: 0;
}

.sidebar-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 12px;
    border-radius: 6px;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 2px;
    transition: all var(--transition-fast);
}

.sidebar-item:hover {
    background-color: var(--hover-bg);
    color: var(--text-primary);
}

.sidebar-item.active {
    background-color: var(--active-bg);
    color: var(--text-primary);
    font-weight: 600;
}

.sidebar-item-icon {
    font-size: 0.95rem;
    width: 18px;
    display: flex;
    justify-content: center;
    flex-shrink: 0;
}

/* Sidebar Footers */
.sidebar-footer {
    padding: 12px;
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.theme-toggle-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}

.theme-toggle-btn:hover {
    background: var(--hover-bg);
    color: var(--text-primary);
}

/* MAIN CONTENT AREA */
#main-content {
    flex: 1;
    min-width: 0;
    height: 100%;
    overflow-y: auto;
    position: relative;
    background-color: var(--bg-primary);
    transition: background-color var(--transition-smooth);
}

/* ========================================================
   NOTION DESIGN COMPONENT STYLES
   ======================================================== */

/* RESEARCH RUNNER HERO */
.notion-cover {
    height: 180px;
    width: 100%;
    position: relative;
    overflow: hidden;
    background: var(--gradient-cover);
    border-bottom: 1px solid var(--border-color);
}

.research-runner-hero {
    height: clamp(350px, 51vw, 450px);
    min-height: 350px;
    width: 100%;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    background: #fff;
    border-bottom: 1px solid #171717;
}

.site-profile-header {
    width: min(100% - clamp(2.5rem, 8vw, 9rem), 1180px);
    margin: 0 auto;
    padding: clamp(32px, 5vw, 64px) 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 200px;
    align-items: stretch;
    gap: clamp(30px, 7vw, 96px);
    background: #fff;
}

.site-profile-copy {
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #171717;
}

.site-profile-kicker {
    margin: 0 0 15px;
    color: #555;
    font: 700 0.68rem/1 var(--font-mono);
    letter-spacing: .12em;
}

.site-profile-kicker::before {
    content: '';
    width: 7px;
    height: 7px;
    display: inline-block;
    margin-right: 9px;
    background: #171717;
}

.site-profile-copy h1 {
    margin: 0;
    color: #111;
    font-size: clamp(2.1rem, 4.1vw, 4rem);
    line-height: 1;
    letter-spacing: -.055em;
}

.site-profile-copy p:not(.site-profile-kicker) {
    max-width: 540px;
    margin: 14px 0 0;
    color: #4c4c4c;
    font-size: clamp(.9rem, 1.3vw, 1.05rem);
    line-height: 1.55;
}

.site-profile-copy .site-profile-role {
    margin-top: 15px;
    color: #171717;
    font: 600 clamp(.86rem, 1.25vw, 1rem)/1.4 var(--font-mono);
}

.site-profile-role b { color: #777; margin: 0 4px; }

.conference-updated {
    margin: 16px 0 0;
    color: #666;
    font: 600 .72rem/1.4 var(--font-mono);
    letter-spacing: .02em;
}

.conference-updated i { margin-right: 5px; }

.site-profile-photo {
    width: 100%;
    height: 100%;
    min-height: 200px;
    aspect-ratio: 1;
    object-fit: cover;
    border: 3px solid #fff;
    outline: 1px solid #171717;
    box-shadow: 7px 7px 0 #171717;
    transition: transform .2s ease, box-shadow .2s ease;
}

.site-profile-photo:hover {
    transform: translate(-2px, -2px);
    box-shadow: 10px 10px 0 #171717;
}

.conference-page .notion-page-header { display: none; }

.cover-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    z-index: 1;
    pointer-events: none;
}

.runner-hero-content {
    position: relative;
    z-index: 2;
    width: min(48%, 540px);
    min-width: 360px;
    height: 100%;
    padding: clamp(44px, 7vw, 82px) 0 40px clamp(32px, 6vw, 88px);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    color: #171717;
}

.runner-hero-content::before {
    display: none;
}

.runner-profile-panel {
    position: absolute;
    z-index: 3;
    right: clamp(28px, 6vw, 92px);
    top: 50%;
    width: clamp(200px, 29vw, 200px);
    height: clamp(200px, 29vw, 200px);
    transform: translateY(-50%);
    border: 3px solid #fff;
    outline: 1px solid #171717;
    box-shadow: 7px 7px 0 #171717;
    overflow: hidden;
    transition: transform .2s ease, box-shadow .2s ease;
}

.runner-profile-panel img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.runner-profile-panel:hover {
    transform: translate(-2px, calc(-50% - 2px));
    box-shadow: 10px 10px 0 #171717;
}

.runner-eyebrow, .runner-caption {
    font: 700 0.68rem/1 var(--font-mono);
    letter-spacing: 0.12em;
    color: #515151;
}

.runner-eyebrow { margin-bottom: 18px; }
.runner-eyebrow span, .runner-caption span {
    width: 7px;
    height: 7px;
    background: #171717;
    display: inline-block;
    margin-right: 8px;
    animation: runnerBlink 1.6s steps(1) infinite;
}

.runner-hero-content h1 {
    margin: 0;
    color: #101010;
    font-size: clamp(2.8rem, 5vw, 4.65rem);
    font-weight: 800;
    letter-spacing: -0.065em;
    line-height: 0.95;
}

.runner-role {
    margin: 16px 0 0;
    font: 600 clamp(0.86rem, 1.25vw, 1rem)/1.4 var(--font-mono);
    color: #171717;
}
.runner-role b { color: #777; margin: 0 4px; }
.runner-intro { max-width: 420px; margin: 17px 0 0; font-size: clamp(0.9rem, 1.35vw, 1.05rem); line-height: 1.55; color: #454545; }

.runner-hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 25px; }
.runner-action {
    border: 1px solid #171717;
    color: #171717;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 13px;
    font: 700 0.74rem/1 var(--font-mono);
    transition: background .2s ease, color .2s ease, transform .2s ease;
}
.runner-action:hover { background: #171717; color: #fff; transform: translateY(-2px); }
.runner-action-primary { 
    background: #171717; 
    color: #fff; 
    position: relative; 
    overflow: visible; 
}
.runner-action-primary:hover { background: #fff; color: #171717; }
.btn-panda-gif {
    position: absolute;
    top: -24px;
    left: 12px;
    height: 28px !important;
    max-height: 28px !important;
    width: 54px !important;
    max-width: 54px !important;
    object-fit: contain !important;
    display: block !important;
    pointer-events: none;
    z-index: 10;
    transition: transform .2s ease;
}
.runner-action:hover .btn-panda-gif {
    transform: translateY(-2px) scale(1.1);
}

.runner-socials { display: flex; gap: 9px; margin-top: 21px; }
.runner-socials a {
    width: 29px;
    height: 29px;
    border: 1px solid #171717;
    display: grid;
    place-items: center;
    font-size: 0.78rem;
    color: #171717;
    transition: all .2s ease;
}
.runner-socials a:hover { background: #171717; color: #fff; transform: rotate(-7deg); }
.runner-caption { position: absolute; z-index: 2; bottom: 17px; right: clamp(20px, 3vw, 46px); color: #555; }

@keyframes runnerBlink { 50% { opacity: .2; } }

/* BREADCRUMBS BAR (Floating top nav inside content) */
.notion-topbar {
    position: sticky;
    top: 0;
    width: 100%;
    height: 48px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    z-index: 100;
    display: flex;
    align-items: center;
    padding: 0 24px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    font-weight: 500;
}

body.dark-mode .notion-topbar {
    background: rgba(25, 25, 25, 0.85);
}

.notion-breadcrumbs {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 32px; /* Margin to clear the floating sidebar trigger button */
    transition: margin-left var(--transition-smooth);
}

.notion-breadcrumbs.wide {
    margin-left: 0;
}

.breadcrumb-separator {
    color: var(--text-muted);
    font-size: 0.75rem;
}

.breadcrumb-active {
    color: var(--text-primary);
    font-weight: 600;
}

/* PAGE HEADER AND TITLE */
.notion-page-header {
    padding-top: 2.25rem;
    position: relative;
    margin-bottom: 2rem;
}

/* PAGE ICON OVERLAP */
.notion-page-icon-wrapper {
    position: absolute;
    top: -85px;
    left: 2rem;
    z-index: 5;
}

.notion-page-icon {
    width: 140px;
    height: 140px;
    border-radius: 24px;
    border: 4px solid var(--bg-primary);
    background-color: var(--bg-primary);
    box-shadow: var(--shadow-md);
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.25, 1.25, 0.5, 1.25), border 0.3s ease, box-shadow 0.5s ease;
    transform-origin: center bottom;
}

.notion-page-icon:hover {
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.18);
    animation: hoverVibrate 0.45s ease-out forwards;
}

@keyframes hoverVibrate {
    0% {
        transform: scale(1) rotate(0deg);
    }
    15% {
        transform: scale(1.05) rotate(-6deg);
    }
    30% {
        transform: scale(1.05) rotate(5deg);
    }
    45% {
        transform: scale(1.05) rotate(-3.5deg);
    }
    60% {
        transform: scale(1.05) rotate(2.5deg);
    }
    75% {
        transform: scale(1.05) rotate(-1.5deg);
    }
    90% {
        transform: scale(1.05) rotate(1deg);
    }
    100% {
        transform: scale(1.05) rotate(1.5deg);
    }
}

/* TITLE GRID */
.notion-title-section {
    padding-top: 75px;
    margin-bottom: 1.5rem;
}

.notion-title {
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.notion-badge-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
}

.notion-badge {
    font-size: 0.78rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    background: var(--hover-bg);
    color: var(--text-secondary);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.notion-status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #22c55e;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
    display: inline-block;
}

/* PROPERTIES PANEL */
.notion-properties {
    display: grid;
    grid-template-columns: auto 1fr;
    row-gap: 8px;
    column-gap: 20px;
    padding: 12px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 2rem;
    font-size: 0.88rem;
}

.prop-name {
    color: var(--text-muted);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 140px;
}

.prop-value {
    color: var(--text-primary);
    font-weight: 600;
}

/* NOTION CALLOUT BOX */
.notion-callout {
    display: flex;
    gap: 12px;
    padding: 16px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-sidebar);
    margin: 1.5rem 0;
    font-size: 0.95rem;
    transition: border-color var(--transition-fast), transform var(--transition-fast);
}

.notion-callout:hover {
    border-color: var(--border-strong);
}

.notion-callout-icon {
    font-size: 1.3rem;
    line-height: 1.2;
    flex-shrink: 0;
}

.notion-callout-content {
    color: var(--text-primary);
}

.notion-callout-content a {
    color: var(--accent-blue);
    border-bottom: 1.5px solid rgba(11, 110, 159, 0.2);
    font-weight: 600;
}

.notion-callout-content a:hover {
    border-bottom-color: var(--accent-blue);
}

/* ABOUT BIOGRAPHY GRID & STACKED CARDS */
.about-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 1.25rem;
    align-items: start;
    margin: 1.5rem 0;
}

.about-text {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.about-text .notion-callout {
    margin: 0;
}

.about-cards {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.about-card {
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.1rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition-smooth), border var(--transition-smooth), box-shadow var(--transition-smooth);
}

.about-card:hover {
    transform: translateY(-2px);
    border-color: var(--accent-blue);
    box-shadow: var(--shadow-md);
}

.about-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: rgba(37, 99, 235, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-blue);
    font-size: 1.15rem;
    flex-shrink: 0;
}

body.dark-mode .about-card-icon {
    background-color: rgba(96, 165, 250, 0.15);
}

.about-card-info {
    display: flex;
    flex-direction: column;
}

.about-card-label {
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.about-card-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Responsive adjustment */
@media (max-width: 768px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
}


/* NOTION TOGGLES (details/summary) */
.notion-toggle {
    margin-bottom: 8px;
}

.notion-toggle summary {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 0.98rem;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 4px;
    user-select: none;
    list-style: none;
    transition: background-color var(--transition-fast);
}

.notion-toggle summary::-webkit-details-marker {
    display: none;
}

.notion-toggle summary:hover {
    background-color: var(--hover-bg);
}

.notion-toggle-arrow {
    display: inline-block;
    transition: transform var(--transition-fast) ease;
    font-size: 0.72rem;
    color: var(--text-secondary);
}

.notion-toggle[open] summary .notion-toggle-arrow {
    transform: rotate(90deg);
}

.notion-toggle-content {
    padding-left: 28px;
    padding-top: 6px;
    padding-bottom: 8px;
}

/* NOTION MULTI-SELECT TAGS */
.notion-tag {
    display: inline-flex;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 500;
    padding: 2px 8px;
    border-radius: 4px;
    white-space: nowrap;
    transition: opacity var(--transition-fast);
}

.notion-tag:hover {
    opacity: 0.85;
}

.tag-red { background-color: var(--tag-red-bg) !important; color: var(--tag-red-txt) !important; }
.tag-orange { background-color: var(--tag-orange-bg) !important; color: var(--tag-orange-txt) !important; }
.tag-yellow { background-color: var(--tag-yellow-bg) !important; color: var(--tag-yellow-txt) !important; }
.tag-green { background-color: var(--tag-green-bg) !important; color: var(--tag-green-txt) !important; }
.tag-blue { background-color: var(--tag-blue-bg) !important; color: var(--tag-blue-txt) !important; }
.tag-purple { background-color: var(--tag-purple-bg) !important; color: var(--tag-purple-txt) !important; }
.tag-pink { background-color: var(--tag-pink-bg) !important; color: var(--tag-pink-txt) !important; }
.tag-gray { background-color: var(--tag-gray-bg) !important; color: var(--tag-gray-txt) !important; }

/* NOTION DIVIDER */
.notion-divider {
    height: 1px;
    background-color: var(--border-color);
    border: none;
    margin: 1.8rem 0;
    width: 100%;
}

/* SECTION COMMONS */
.container {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

section {
    padding: 2.5rem 0;
}

.section-title {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.015em;
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ========================================================
   EDUCATION JOURNEY TIMELINE
   ======================================================== */
.journey-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.journey-item {
    display: flex;
    gap: 16px;
    position: relative;
}

.journey-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.journey-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--border-strong);
    border: 2px solid var(--bg-primary);
    z-index: 2;
    margin-top: 6px;
    transition: background-color var(--transition-fast);
}

.journey-dot.current {
    background-color: #22c55e !important;
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    animation: blink-green 2s infinite;
}

@keyframes blink-green {
    0% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    }
    70% {
        box-shadow: 0 0 0 8px rgba(34, 197, 94, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}


.journey-item:hover .journey-dot {
    background-color: var(--accent-blue);
}

.journey-line {
    width: 2px;
    flex-grow: 1;
    background-color: var(--border-color);
    margin-top: 4px;
}

.journey-item:last-child .journey-line {
    display: none;
}

.journey-content {
    padding-bottom: 8px;
    flex: 1;
}

.journey-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 4px;
}

.journey-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-primary);
}

.journey-date {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.journey-institution {
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--accent-blue);
    margin-bottom: 6px;
}

.journey-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* ========================================================
   DATABASE VIEWS (Publications & Projects)
   ======================================================== */
.notion-db-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 8px;
}

.notion-db-tabs {
    display: flex;
    gap: 4px;
}

.notion-db-tab {
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all var(--transition-fast);
}

.notion-db-tab:hover {
    background-color: var(--hover-bg);
    color: var(--text-primary);
}

.notion-db-tab.active {
    background-color: var(--active-bg);
    color: var(--text-primary);
    font-weight: 600;
}

.notion-db-search {
    position: relative;
    max-width: 240px;
    width: 100%;
}

.notion-db-search input {
    width: 100%;
    padding: 6px 12px 6px 32px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-sidebar);
    color: var(--text-primary);
    font-size: 0.85rem;
    transition: all var(--transition-fast);
}

.notion-db-search input:focus {
    outline: none;
    border-color: var(--border-strong);
    background-color: var(--bg-primary);
}

.notion-db-search i {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.82rem;
}

/* DATABASE LIST (Publications Table Style) */
.notion-db-list {
    display: flex;
    flex-direction: column;
    gap: 1px;
    background-color: var(--border-color);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
}

.notion-db-item {
    display: flex;
    padding: 14px 16px;
    background-color: var(--bg-primary);
    gap: 16px;
    transition: background-color var(--transition-fast);
}

.notion-db-item:hover {
    background-color: var(--bg-sidebar);
}

.db-item-index {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.88rem;
    min-width: 24px;
    text-align: right;
    margin-top: 2px;
}

.db-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.db-item-title {
    font-size: 0.98rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
}

.db-item-title a:hover {
    color: var(--accent-blue);
    text-decoration: underline;
}

.db-item-authors {
    font-size: 0.88rem;
    color: var(--text-secondary);
}

.db-item-venue {
    font-size: 0.82rem;
    color: var(--text-muted);
    font-style: italic;
}

.db-item-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
}

.db-item-links {
    display: flex;
    gap: 12px;
    margin-top: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.db-item-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color var(--transition-fast);
}

.db-item-link-btn:hover {
    color: var(--text-primary);
}

/* BIBTEX COLLAPSED BOX */
.bibtex-box {
    display: none;
    width: 100%;
}
.bibtex-box.active {
    display: block;
}
.bibtex-card {
    background-color: var(--bg-sidebar);
    border: 1px dashed var(--border-color);
    border-radius: 6px;
    padding: 12px;
    font-family: var(--font-mono);
    font-size: 0.76rem;
    white-space: pre-wrap;
    overflow-x: auto;
    position: relative;
    margin-top: 8px;
}

.copy-bib-btn {
    position: absolute;
    right: 8px;
    top: 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    padding: 3px 8px;
    font-size: 0.72rem;
    font-family: var(--font-body);
    font-weight: 600;
    border-radius: 4px;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}

.copy-bib-btn:hover {
    background: var(--hover-bg);
    color: var(--text-primary);
}

/* ========================================================
   PROJECTS GALLERY VIEW
   ======================================================== */
.notion-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 1rem;
}

.notion-gallery-card {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--bg-primary);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.notion-gallery-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.card-cover {
    height: 120px;
    background: var(--gradient-cover);
    opacity: 0.85;
    transition: opacity var(--transition-fast);
}

.notion-gallery-card:hover .card-cover {
    opacity: 1;
}

.card-body {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.card-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-primary);
}

.card-title a:hover {
    color: var(--accent-blue);
}

.card-desc {
    font-size: 0.88rem;
    color: var(--text-secondary);
    flex: 1;
    line-height: 1.5;
}

.card-footer {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 4px;
    border-top: 1px solid var(--border-color);
    padding-top: 12px;
}

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

.card-links {
    display: flex;
    gap: 12px;
    font-size: 0.82rem;
    font-weight: 600;
}

.card-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--text-secondary);
    transition: color var(--transition-fast);
}

.card-link-btn:hover {
    color: var(--text-primary);
}

/* ========================================================
   SKILLS & ACHIEVEMENTS GRIDS
   ======================================================== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}

.skills-card {
    padding: 16px;
    background-color: var(--bg-sidebar);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.skills-card-title {
    font-size: 0.95rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.skills-tag-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

/* Achievements timeline list */
.award-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.award-item {
    display: flex;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-sidebar);
    border-radius: 8px;
    border: 1px solid var(--border-color);
    align-items: flex-start;
}

.award-item-icon {
    font-size: 1.15rem;
    color: var(--accent-blue);
    margin-top: 2px;
}

.award-item-content {
    flex: 1;
}

.award-item-title {
    font-size: 0.98rem;
    font-weight: 600;
}

.award-item-desc {
    font-size: 0.88rem;
    color: var(--text-secondary);
}

.award-item-date {
    font-size: 0.78rem;
    font-family: var(--font-mono);
    color: var(--text-muted);
    margin-top: 4px;
}

/* ========================================================
   TEACHING ASSISTANT LIST
   ======================================================== */
.teaching-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}

.teaching-card {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    background-color: var(--bg-primary);
    transition: all var(--transition-fast);
}

.teaching-card:hover {
    border-color: var(--border-strong);
    background-color: var(--bg-sidebar);
}

.teaching-code {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--accent-blue);
    background-color: var(--accent-blue-bg);
    padding: 2px 6px;
    border-radius: 4px;
    width: fit-content;
    margin-bottom: 8px;
}

.teaching-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 6px;
}

.teaching-desc {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.45;
}

/* ========================================================
   RICIAN SIMULATOR DASHBOARD Redesign
   ======================================================== */
.sim-dashboard {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background-color: var(--bg-sidebar);
    padding: 24px;
    margin-top: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.sim-top-row {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

/* Controls block styling */
.sim-controls {
    flex: 1 1 280px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.sim-control-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sim-control-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.88rem;
    font-weight: 600;
}

.sim-value-display {
    font-family: var(--font-mono);
    color: var(--accent-blue);
}

.sim-slider {
    -webkit-appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: var(--border-color);
    outline: none;
    transition: background 0.2s;
}

.sim-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent-blue);
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition-fast);
}

.sim-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

/* Derived panel box */
.sim-derived-panel {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sim-derived-panel h4 {
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 4px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 6px;
}

.sim-derived-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.sim-derived-row strong {
    font-family: var(--font-mono);
    color: var(--text-primary);
}

/* Graphs grid layout */
.sim-plots {
    flex: 2 1 450px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.sim-plot-card {
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    transition: border-color var(--transition-fast);
}

.sim-plot-card:hover {
    border-color: var(--border-strong);
}

.sim-plot-card canvas {
    width: 100% !important;
    height: 100% !important;
}

/* Math block */
.sim-math-panel {
    margin-top: 24px;
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
}

.sim-math-panel h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.sim-math-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.sim-math-block {
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    overflow-x: auto;
}

.sim-math-block h5 {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

/* BUTTONS & CONTROLS */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.88rem;
    font-weight: 600;
    transition: all var(--transition-fast);
    text-decoration: none;
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--accent-blue);
    color: #ffffff !important;
}

.btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.btn-outline {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    border-color: var(--border-color);
}

.btn-outline:hover {
    background-color: var(--hover-bg);
    border-color: var(--border-strong);
}

/* ========================================================
   CONTACT FORM & CHANNELS
   ======================================================== */
.contact-grid {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.contact-channels {
    flex: 1 1 280px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.contact-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    background-color: var(--bg-sidebar);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    transition: all var(--transition-fast);
}

.contact-card:hover {
    border-color: var(--border-strong);
    background-color: var(--bg-primary);
    transform: translateX(3px);
}

.contact-card-icon {
    font-size: 1.25rem;
    color: var(--accent-blue);
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-color);
}

.contact-card-info h4 {
    font-size: 0.78rem;
    text-transform: uppercase;
    color: var(--text-muted);
}

.contact-card-info p {
    font-size: 0.9rem;
    font-weight: 600;
}

/* Contact Form */
.contact-form-wrapper {
    flex: 1.2 1 340px;
    background-color: var(--bg-sidebar);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
}

.contact-form-wrapper h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.form-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.form-group {
    flex: 1 1 150px;
    display: flex;
    flex-direction: column;
}

.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.88rem;
    transition: border-color var(--transition-fast);
}

.contact-form input:focus, .contact-form textarea:focus {
    outline: none;
    border-color: var(--border-strong);
}

.contact-form textarea {
    height: 100px;
    resize: vertical;
}

.submit-btn {
    background-color: var(--accent-blue);
    color: #ffffff;
    padding: 10px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: opacity var(--transition-fast);
}

.submit-btn:hover {
    opacity: 0.9;
}

/* ========================================================
   FOOTER SECTION
   ======================================================== */
footer {
    border-top: 1px solid var(--border-color);
    padding: 2.5rem 0;
    margin-top: 4rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    background-color: var(--bg-sidebar);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 24px;
    margin-bottom: 1.8rem;
}

.footer-brand-title {
    font-weight: 700;
    font-size: 1.05rem;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.footer-col h4 {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

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

.footer-social-row {
    display: flex;
    gap: 12px;
}

.footer-social-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    transition: all var(--transition-fast);
}

.footer-social-btn:hover {
    border-color: var(--border-strong);
    color: var(--text-primary);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    border-top: 1px solid var(--border-color);
    padding-top: 1.5rem;
}

.footer-time {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
}

.pulse-dot {
    width: 6px;
    height: 6px;
    background-color: #22c55e;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 5px rgba(34, 197, 94, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

/* BACK TO TOP BUTTON */
.back-to-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
    transition: all var(--transition-fast);
    z-index: 1000;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.back-to-top:hover {
    background-color: var(--hover-bg);
    color: var(--text-primary);
}

/* SCROLL REVEAL CLASS */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ========================================================
   CV SPECIFIC STYLES
   ======================================================== */
.cv-toolbar {
    position: sticky;
    top: 0;
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    z-index: 100;
    padding: 10px 0;
}

.cv-toolbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cv-toolbar-left a {
    font-size: 0.88rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.cv-toolbar-right {
    display: flex;
    gap: 8px;
}

.cv-page {
    background-color: var(--bg-primary);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 3rem 2rem;
    margin-top: 1.5rem;
    margin-bottom: 3rem;
}

.cv-section-title {
    border-bottom: 1.5px solid var(--border-color);
    padding-bottom: 4px;
    margin-bottom: 1rem;
    font-size: 1.25rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.cv-header-grid {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 16px;
}

.cv-personal-info h1 {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 4px;
}

.cv-personal-info h2 {
    font-size: 1.1rem;
    color: var(--accent-blue);
    font-weight: 600;
    margin-bottom: 12px;
}

.cv-personal-info p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.cv-contact-info {
    text-align: right;
    font-size: 0.88rem;
}

@media (max-width: 768px) {
    .cv-contact-info {
        text-align: left;
    }
}

.cv-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
}

.cv-table td {
    padding: 8px 12px 8px 0;
    vertical-align: top;
    font-size: 0.9rem;
}

.cv-table tr:hover td {
    background-color: var(--hover-bg);
}

.cv-table-date {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-secondary);
    width: 140px;
}

/* ========================================================
   MEDIA QUERIES (Responsive Layout)
   ======================================================== */
@media (max-width: 900px) {
    #sidebar {
        position: fixed;
        inset: 0 auto 0 0;
        height: 100dvh;
        margin-left: 0 !important;
        transform: translateX(-100%);
        box-shadow: 12px 0 30px rgba(0, 0, 0, 0.16);
        z-index: 1200;
    }

    #sidebar:not(.collapsed) {
        transform: translateX(0);
    }

    .sidebar-trigger {
        z-index: 1210;
        opacity: 0;
        pointer-events: none;
    }

    .sidebar-trigger.visible {
        opacity: 1;
        pointer-events: auto;
    }

    .sidebar-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 1190;
        border: 0;
        background: rgba(0, 0, 0, 0.3);
        opacity: 0;
        pointer-events: none;
        transition: opacity var(--transition-smooth);
    }

    .sidebar-backdrop.visible {
        opacity: 1;
        pointer-events: auto;
    }

    .notion-breadcrumbs {
        margin-left: 24px;
    }
}

@media (max-width: 600px) {
    .site-profile-header {
        width: calc(100% - 2.5rem);
        grid-template-columns: minmax(0, 1fr) 128px;
        gap: 20px;
        padding: 30px 0;
    }
    .site-profile-copy, .site-profile-photo { min-height: 128px; }
    .site-profile-copy h1 { font-size: clamp(1.85rem, 9vw, 2.5rem); }
    .site-profile-kicker { font-size: .57rem; letter-spacing: .08em; }
    .site-profile-copy p:not(.site-profile-kicker) { margin-top: 10px; font-size: .78rem; }
    .site-profile-photo { border-width: 2px; box-shadow: 4px 4px 0 #171717; }
    .research-runner-hero { height: 600px; min-height: 600px; }
    .runner-hero-content {
        width: 100%;
        min-width: 0;
        justify-content: flex-start;
        padding: 47px 28px 0;
    }
    .runner-hero-content h1 { font-size: clamp(3rem, 15vw, 4.3rem); }
    .runner-intro { max-width: 310px; }
    .runner-profile-panel { top: auto; right: 20px; bottom: 54px; width: 180px; height: 180px; transform: none; box-shadow: 4px 4px 0 #171717; }
    .runner-profile-panel:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 #171717; }
    .runner-caption { right: 20px; bottom: 16px; font-size: 0.58rem; }
    .container {
        padding: 0 1.25rem;
    }
}

@media (max-width: 600px) {
    .runner-hero-content {
        width: 58% !important;
        padding-left: 20px !important;
        padding-right: 0 !important;
    }
    .runner-hero-actions {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .runner-action {
        width: 100% !important;
        max-width: 170px !important;
        justify-content: center;
        box-sizing: border-box;
        font-size: clamp(0.55rem, 3vw, 0.72rem) !important;
        padding: 6px 8px !important;
        white-space: normal !important;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .runner-profile-panel {
        width: 135px !important;
        height: 135px !important;
        right: 15px !important;
    }
    .runner-caption {
        right: 15px !important;
        font-size: 0.52rem !important;
    }
}

@media (max-width: 360px) {
    .runner-profile-panel {
        width: 110px !important;
        height: 110px !important;
        right: 10px !important;
    }
    .runner-caption {
        right: 10px !important;
        font-size: 0.48rem !important;
    }
}

@media (min-width: 601px) and (max-width: 900px) {
    .runner-hero-content { width: 57%; min-width: 390px; padding-left: 48px; }
}

@media (prefers-reduced-motion: reduce) {
    .runner-eyebrow span, .runner-caption span { animation: none; }
}

/* ========================================================
   PRINT SPECIFIC SYSTEM
   ======================================================== */
@media print {
    #sidebar, .sidebar-trigger, .notion-topbar, .cv-toolbar, .back-to-top, footer, .bibtex-card, .copy-bib-btn, .notion-cover, .site-profile-header, .runner-profile-panel, .research-runner-hero {
        display: none !important;
    }

    #app-container, #main-content {
        display: block !important;
        height: auto !important;
        overflow: visible !important;
    }

    .container {
        max-width: 100% !important;
        padding: 0 !important;
    }

    .cv-page {
        border: none !important;
        box-shadow: none !important;
        padding: 0 !important;
        margin: 0 !important;
        background: transparent !important;
        color: #000 !important;
    }
    
    body {
        background: #fff !important;
        color: #000 !important;
        font-size: 11pt !important;
    }
    
    .cv-section-title {
        border-bottom-color: #000 !important;
        color: #000 !important;
    }

    a {
        color: #000 !important;
        text-decoration: underline !important;
    }
}

/* Floating Paper Plane Styling */
.hero-plane-gif {
    height: 110px;
    width: auto;
    vertical-align: middle;
    margin-left: 12px;
    display: inline-block;
    animation: floatPlane 3s ease-in-out infinite;
    filter: drop-shadow(0 2px 4px rgba(11, 110, 159, 0.15));
}

@media (max-width: 768px) {
    .hero-plane-gif {
        height: 75px;
    }
}
@media (max-width: 480px) {
    .hero-plane-gif {
        height: 55px;
        margin-left: 8px;
    }
}

@keyframes floatPlane {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-6px) rotate(-3deg);
    }
}


/* ========================================================
   ABSTRACT ACCORDION BOX
   ======================================================== */
.abstract-box {
    display: none;
    width: 100%;
}
.abstract-box.active {
    display: block;
}
.abstract-card {
    background-color: var(--bg-sidebar);
    border-left: 3px solid var(--accent-blue);
    border-radius: 4px;
    padding: 12px 16px;
    font-size: 0.82rem;
    line-height: 1.45rem;
    margin-top: 8px;
    text-align: justify;
    color: var(--text-secondary);
}

/* ========================================================
   NOTION CHANGELOG TIMELINE
   ======================================================== */
.changelog-list {
    list-style: none;
    padding: 0;
    margin: 8px 0 0 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.changelog-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 0.85rem;
    line-height: 1.4rem;
}

@media (max-width: 600px) {
    .changelog-item {
        flex-direction: column;
        gap: 4px;
    }
}

.changelog-tag {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    flex-shrink: 0;
    margin-top: 2px;
}

.changelog-text {
    color: var(--text-secondary);
}

/* Cover Plane GIF floating inside poster banner */
.cover-plane-gif {
    position: absolute;
    right: 12%;
    top: 95px; /* Brought lower down */
    height: 55px;
    width: auto;
    z-index: 2;
    pointer-events: none;
    animation: floatCoverPlane 4s ease-in-out infinite;
    mix-blend-mode: multiply;
}

body.dark-mode .cover-plane-gif {
    filter: invert(1) hue-rotate(180deg);
    mix-blend-mode: screen;
}

@keyframes floatCoverPlane {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-8px) rotate(4deg);
    }
}

/* Companion Paper Plane Sticker */
.cover-spark-plane {
    position: absolute;
    left: 45%;
    top: 15px;
    width: 80px; /* Sized to 80px */
    height: auto;
    z-index: 2;
    pointer-events: none;
    mix-blend-mode: multiply;
    animation: floatSparkPlane 5.5s ease-in-out infinite;
}

body.dark-mode .cover-spark-plane {
    filter: invert(1) hue-rotate(180deg);
    mix-blend-mode: screen;
}

@keyframes floatSparkPlane {
    0%, 100% {
        transform: translateY(-90%) rotate(0deg);
    }
    50% {
        transform: translateY(-98%) rotate(3deg);
    }
}

/* Dark Mode Hero Header Overrides */
body.dark-mode .runner-eyebrow,
body.dark-mode .runner-caption {
    color: #94a3b8;
}
body.dark-mode .runner-eyebrow span,
body.dark-mode .runner-caption span {
    background: #cbd5e1;
}
body.dark-mode .runner-hero-content h1 {
    color: #f8fafc;
}
body.dark-mode .runner-role {
    color: #cbd5e1;
}
body.dark-mode .runner-role b {
    color: #475569;
}
body.dark-mode .runner-intro {
    color: #94a3b8;
}
body.dark-mode .runner-action {
    border-color: #cbd5e1;
    color: #cbd5e1;
}
body.dark-mode .runner-action:hover {
    background: #cbd5e1;
    color: #0f172a;
}
body.dark-mode .runner-action-primary {
    background: #cbd5e1;
    color: #0f172a;
}
body.dark-mode .runner-action-primary:hover {
    background: transparent;
    color: #cbd5e1;
}
body.dark-mode .runner-socials a {
    border-color: #cbd5e1;
    color: #cbd5e1;
}
body.dark-mode .runner-socials a:hover {
    background: #cbd5e1;
    color: #0f172a;
}

/* MODERN & USER-FRIENDLY INTERACTION REFINEMENTS */
.skills-card, .award-item, .about-card, .education-card, .ta-card, .sim-plot-card, .notion-callout, .notion-gallery-card {
    transition: transform var(--transition-fast), box-shadow var(--transition-fast), border-color var(--transition-fast);
}

.skills-card:hover, .award-item:hover, .about-card:hover, .education-card:hover, .ta-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-strong);
}

/* Tactile button active click feedback */
.btn:active, 
.runner-action:active, 
.sidebar-item:active, 
.copy-bib-btn:active, 
.runner-socials a:active,
.theme-toggle-btn:active {
    transform: scale(0.96) !important;
}

/* Scrollbar tracks modernization */
::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 10px;
}
