
/*
 * EdwinOS unified stylesheet
 * ==========================================================================
 *
 * CASCADE CONTRACT
 * ----------------
 * This file is the single CSS entry point for the site. Its rule order is part
 * of the visual contract: later declarations intentionally resolve earlier
 * baseline declarations. Do not reorder sections merely to group selectors.
 *
 * ARCHITECTURE / CONTENTS
 * -----------------------
 * 1. Historical Material and site baseline (shared primitives and Overview)
 * 2. EdwinOS final component layer (site-hosted fonts, then component owners)
 *
 * Maintenance rule: extend the existing component section in the appropriate
 * cascade layer. Before removing or moving a rule, prove equivalent selector,
 * media context, specificity, importance, and source order.
 */

/* ==========================================================================
 * 1. Historical Material and site baseline
 * ========================================================================== */

/*
 * 选择器 [data-md-color-scheme="default"] 确保这些改动
 * 仅在用户选择“亮色”或系统默认为“亮色”时生效。
 * 当用户切换到暗色模式时，这些设置会被自动忽略，从而保护暗色体验。
 */
[data-md-color-scheme="default"] {

  /* ==============================================
     主色调配置 (Primary Colors) - 浙大蓝 #003F88
     ============================================== */
  /*
   * --md-primary-fg-color:
   * 控制页眉(Header)、侧边栏激活项、链接文字等核心元素的颜色。
   */
  --md-primary-fg-color:        #003F88;

  /*
   * --md-primary-fg-color--light:
   * 控制鼠标悬停(Hover)时的颜色，通常比主色稍亮。
   */
  --md-primary-fg-color--light: #0050AA;

  /*
   * --md-primary-fg-color--dark:
   * 控制被点击或激活状态的颜色，通常比主色稍暗。
   */
  --md-primary-fg-color--dark:  #002E66;

  /* ==============================================
     背景色配置 (Background Colors) - GitHub frame palette
     ============================================== */
  /*
   * --md-default-bg-color:
   * 控制页面主体的背景颜色。
   */
  --md-default-bg-color:        var(--github-frame-light-bg);

  /* ==============================================
     强调色配置 (Accent Colors)
     ============================================== */
  /*
   * --md-accent-fg-color:
   * 控制按钮、滑动条、高亮文本的颜色。建议与主色保持一致或互补。
   */
  --md-accent-fg-color:         #003F88;
}

/* --- 页脚定制开始 --- */

/* 强制页脚内部容器两端对齐 */
.md-footer-meta__inner {
    display: flex;
    justify-content: space-between!important; /* 覆盖默认样式 */
    align-items: center; /* 垂直居中 */
    flex-wrap: wrap; /* 移动端自动换行 */
}

/* 针对版权信息区域 */
.md-copyright {
    margin: 0!important;
    text-align: left;
}

/* 针对社交图标区域 */
.md-social {
    margin: 0!important;
    padding: 0;
    text-align: right;
}

/* 移动端适配：屏幕小于 40rem (约640px) 时，恢复堆叠布局，防止挤压 */
@media screen and (max-width: 40rem) {
   .md-footer-meta__inner {
        flex-direction: column-reverse; /* 图标在下，版权在上，或者反过来 */
        gap: 10px;
        justify-content: center!important;
    }
}
/* --- 页脚定制结束 --- */

/* ==============================================
   全局 UI 优化 - 科技感增强
   ============================================== */

/* 平滑滚动 */
html {
    scroll-behavior: smooth;
}

/* 标题排版增强 - 给标题更多个性 */
.md-typeset h1,
.md-typeset h2,
.md-typeset h3 {
    line-height: 1.3;
}

.md-typeset h1 {
    font-size: 2em;
    margin-bottom: 0.8em;
}

.md-typeset h2 {
    font-size: 1.5em;
    margin-top: 2em;
}

/* 优化链接过渡效果 */
a {
    transition: color 0.25s ease, opacity 0.25s ease, border-color 0.25s ease;
}

/* 内容卡片化效果 */
.md-content {
    padding-top: 1.5rem;
}

/* 表格美化 */
.md-typeset table:not([class]) {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}

.md-typeset table:not([class]) th {
    background: rgba(0, 63, 136, 0.08);
}

/* 页脚美化 */
.md-footer {
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

/* pymdownx.mark 将渲染为 <mark> 或 .pymdownx-mark, 统一样式 */
.md-typeset mark,
.md-typeset .pymdownx-mark {
    background-color: #fff59d; /* 柔和的荧光黄 */
    color: #000;
    padding: 0 0.18em;
    border-radius: 2px;
}

/* ==============================================
   暗色模式 - GitHub Dark
   以 GitHub 原生灰黑背景、边框和链接蓝覆盖 slate 模式。
   ============================================== */
[data-md-color-scheme="slate"] {
    --md-default-bg-color: var(--github-frame-dark-bg);
    --md-default-fg-color: #c9d1d9;
    --md-default-fg-color--light: #8b949e;
    --md-default-fg-color--lighter: #6e7681;
    --md-primary-fg-color: #58a6ff;
    --md-primary-fg-color--light: #79c0ff;
    --md-primary-bg-color: #161b22;
    --md-accent-fg-color: #58a6ff;
    --md-typeset-color: #c9d1d9;
    --md-typeset-a-color: #58a6ff;

    /* 代码相关颜色 */
    --md-code-hl-color: rgba(88, 166, 255, 0.14);

    /* 自定义扩展变量 */
}

/* 内容区域 */
[data-md-color-scheme="slate"] .md-content {
    background: #0d1117;
}

/* 表格美化 */
[data-md-color-scheme="slate"] .md-typeset table:not([class]) {
    background: #161b22;
    border: 1px solid #30363d;
}

[data-md-color-scheme="slate"] .md-typeset table:not([class]) th {
    background: rgba(88, 166, 255, 0.08);
    color: #c9d1d9;
    border-bottom: 1px solid #30363d;
}

[data-md-color-scheme="slate"] .md-typeset table:not([class]) td {
    border-color: #30363d;
}

[data-md-color-scheme="slate"] .md-typeset table:not([class]) tr:hover {
    background: rgba(88, 166, 255, 0.06);
}

/* 链接样式 - GitHub Blue */
[data-md-color-scheme="slate"] .md-typeset a {
    color: #58a6ff;
    text-decoration: none;
    transition: all 0.25s ease;
    border-bottom: 1px solid transparent;
}

[data-md-color-scheme="slate"] .md-typeset a:hover {
    color: #79c0ff;
    border-bottom-color: rgba(88, 166, 255, 0.45);
}

/* 页脚美化 */
[data-md-color-scheme="slate"] .md-footer {
    background: #0d1117;
    border-top: 1px solid #30363d;
}

[data-md-color-scheme="slate"] .md-footer-meta {
    background: transparent;
}

/* 选中文本颜色 */
[data-md-color-scheme="slate"] ::selection {
    background: rgba(88, 166, 255, 0.32);
    color: #fff;
}

/* 按钮美化 */
[data-md-color-scheme="slate"] .md-button {
    background: #161b22;
    border: 1px solid #30363d;
    color: #c9d1d9;
}

[data-md-color-scheme="slate"] .md-button:hover {
    background: rgba(88, 166, 255, 0.1);
    border-color: rgba(88, 166, 255, 0.45);
}

[data-md-color-scheme="slate"] .md-button--primary {
    background: #238636;
    border-color: transparent;
    color: #fff;
}

[data-md-color-scheme="slate"] .md-button--primary:hover {
    background: #2ea043;
    box-shadow: none;
}

/* 首页兜底：隐藏正文第一个 H1，避免即时导航时等待 JS 注入类名 */
body.is-homepage .md-content__inner > h1:first-of-type,
body:has(.academic-home-layout) .md-content__inner > h1:first-of-type {
    display: none !important;
}

/* ==============================================
   暗色模式标题可读性增强 - 梯度高亮
   ============================================== */
[data-md-color-scheme="slate"] .md-typeset h1 {
    color: #f8fafc !important;
    font-weight: 700;
    letter-spacing: -0.02em;
    text-shadow: 0 0 30px rgba(88, 166, 255, 0.12);
}

[data-md-color-scheme="slate"] .md-typeset h2 {
    color: #f1f5f9 !important;
    font-weight: 600;
    padding-bottom: 0.3em;
    border-bottom: 2px solid rgba(88, 166, 255, 0.16);
}

[data-md-color-scheme="slate"] .md-typeset h3 {
    color: #e2e8f0 !important;
    font-weight: 600;
}

[data-md-color-scheme="slate"] .md-typeset h4,
[data-md-color-scheme="slate"] .md-typeset h5,
[data-md-color-scheme="slate"] .md-typeset h6 {
    color: #cbd5e1 !important;
    font-weight: 600;
}

/* 暗色模式 strong/bold 高亮 - GitHub Yellow */

/* 暗色模式 blockquote 优化 */
[data-md-color-scheme="slate"] .md-typeset blockquote {
    border-left: 4px solid rgba(88, 166, 255, 0.42);
    background: rgba(88, 166, 255, 0.04);
    color: #8b949e;
}

/* 暗色模式分割线 */
[data-md-color-scheme="slate"] .md-typeset hr {
    border-color: rgba(88, 166, 255, 0.16);
}

/* ==============================================
   亮色模式标题装饰 - 浙大蓝增强
   ============================================== */
[data-md-color-scheme="default"] .md-typeset h1 {
    color: #003F88;
    font-weight: 700;
    letter-spacing: -0.02em;
}

[data-md-color-scheme="default"] .md-typeset h2 {
    color: #002E66;
    font-weight: 600;
    padding-bottom: 0.3em;
    border-bottom: 2px solid rgba(0, 63, 136, 0.12);
}

[data-md-color-scheme="default"] .md-typeset h3 {
    color: #003F88;
    font-weight: 600;
}

/* 亮色模式 blockquote 温暖化 */
[data-md-color-scheme="default"] .md-typeset blockquote {
    border-left: 4px solid rgba(0, 63, 136, 0.3);
    background: rgba(0, 63, 136, 0.03);
}

/* 亮色模式链接悬停下划线 */
[data-md-color-scheme="default"] .md-typeset a:hover {
    border-bottom: 1px solid rgba(0, 63, 136, 0.3);
}

/* ==============================================
   Obsidian 风格块引用链接样式
   ============================================== */
/* 块锚点标记 */
.block-anchor {
    position: relative;
}

.block-anchor::before {
    content: '';
    display: block;
    height: 0;
    margin-top: 0;
    visibility: hidden;
    pointer-events: none;
}

/* 块引用链接样式 */
a.block-link {
    color: var(--md-accent-fg-color, #003F88);
    text-decoration: none;
    background: rgba(0, 63, 136, 0.08);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.9em;
    transition: all 0.2s ease;
}

a.block-link:hover {
    background: rgba(0, 63, 136, 0.15);
    color: var(--md-primary-fg-color, #003F88);
}

/* URL fragment / Obsidian block target highlight */
.md-typeset .block-highlight {
    --fragment-highlight-bg-0: rgba(217, 119, 6, 0.2);
    --fragment-highlight-bg-1: rgba(245, 158, 11, 0.13);
    --fragment-highlight-bg-2: rgba(245, 158, 11, 0.055);
    --fragment-highlight-bg-3: rgba(245, 158, 11, 0);
    --fragment-highlight-ring-0: rgba(180, 83, 9, 0.26);
    --fragment-highlight-ring-1: rgba(180, 83, 9, 0.16);
    --fragment-highlight-ring-2: rgba(180, 83, 9, 0.06);
    --fragment-highlight-ring-3: rgba(180, 83, 9, 0);
    --fragment-highlight-shadow-0: rgba(120, 53, 15, 0.13);
    --fragment-highlight-shadow-1: rgba(120, 53, 15, 0.08);
    --fragment-highlight-shadow-2: rgba(120, 53, 15, 0.03);
    --fragment-highlight-shadow-3: rgba(120, 53, 15, 0);
    --fragment-highlight-bar: rgba(180, 83, 9, 0.82);
    position: relative;
    border-radius: 0.65rem;
    scroll-margin-top: 5.5rem;
}

.md-typeset .block-highlight--active:not(tr) {
    animation: fragment-target-fade 4.8s linear forwards;
}

.md-typeset .block-highlight--active:not(tr)::before {
    content: "";
    position: absolute;
    inset-block: 0.35rem;
    inset-inline-start: -0.62rem;
    width: 0.22rem;
    border-radius: 999px;
    background: var(--fragment-highlight-bar);
    box-shadow: 0 0 0.75rem rgba(180, 83, 9, 0.22);
    animation: fragment-target-bar-fade 4.8s linear forwards;
}

.md-typeset tr.block-highlight--active > th,
.md-typeset tr.block-highlight--active > td {
    animation: fragment-target-cell-fade 4.8s linear forwards;
}

@keyframes fragment-target-fade {
    0% {
        background-color: var(--fragment-highlight-bg-0);
        box-shadow:
            0 0 0 2px var(--fragment-highlight-ring-0),
            0 0.7rem 1.8rem var(--fragment-highlight-shadow-0);
    }
    28% {
        background-color: var(--fragment-highlight-bg-1);
        box-shadow:
            0 0 0 1.5px var(--fragment-highlight-ring-1),
            0 0.45rem 1.25rem var(--fragment-highlight-shadow-1);
    }
    70% {
        background-color: var(--fragment-highlight-bg-2);
        box-shadow:
            0 0 0 1px var(--fragment-highlight-ring-2),
            0 0.2rem 0.7rem var(--fragment-highlight-shadow-2);
    }
    100% {
        background-color: var(--fragment-highlight-bg-3);
        box-shadow:
            0 0 0 0 var(--fragment-highlight-ring-3),
            0 0 0 0 var(--fragment-highlight-shadow-3);
    }
}

@keyframes fragment-target-cell-fade {
    0% {
        background-color: var(--fragment-highlight-bg-0);
        box-shadow: inset 0 0 0 2px var(--fragment-highlight-ring-0);
    }
    28% {
        background-color: var(--fragment-highlight-bg-1);
        box-shadow: inset 0 0 0 1.5px var(--fragment-highlight-ring-1);
    }
    70% {
        background-color: var(--fragment-highlight-bg-2);
        box-shadow: inset 0 0 0 1px var(--fragment-highlight-ring-2);
    }
    100% {
        background-color: var(--fragment-highlight-bg-3);
        box-shadow: inset 0 0 0 0 var(--fragment-highlight-ring-3);
    }
}

@keyframes fragment-target-bar-fade {
    0% {
        opacity: 0.82;
        transform: scaleY(1);
    }
    28% {
        opacity: 0.58;
    }
    70% {
        opacity: 0.22;
    }
    100% {
        opacity: 0;
        transform: scaleY(0.92);
    }
}

/* 暗色模式适配 */
[data-md-color-scheme="slate"] a.block-link {
    background: rgba(88, 166, 255, 0.15);
    color: #58a6ff;
}

[data-md-color-scheme="slate"] a.block-link:hover {
    background: rgba(88, 166, 255, 0.24);
}

[data-md-color-scheme="slate"] .md-typeset .block-highlight {
    --fragment-highlight-bg-0: rgba(251, 191, 36, 0.17);
    --fragment-highlight-bg-1: rgba(88, 166, 255, 0.105);
    --fragment-highlight-bg-2: rgba(88, 166, 255, 0.045);
    --fragment-highlight-bg-3: rgba(88, 166, 255, 0);
    --fragment-highlight-ring-0: rgba(251, 191, 36, 0.28);
    --fragment-highlight-ring-1: rgba(251, 191, 36, 0.15);
    --fragment-highlight-ring-2: rgba(251, 191, 36, 0.06);
    --fragment-highlight-ring-3: rgba(251, 191, 36, 0);
    --fragment-highlight-shadow-0: rgba(0, 0, 0, 0.18);
    --fragment-highlight-shadow-1: rgba(0, 0, 0, 0.11);
    --fragment-highlight-shadow-2: rgba(0, 0, 0, 0.04);
    --fragment-highlight-shadow-3: rgba(0, 0, 0, 0);
    --fragment-highlight-bar: rgba(251, 191, 36, 0.82);
}

@media (prefers-reduced-motion: reduce) {
    .md-typeset .block-highlight--active,
    .md-typeset .block-highlight--active::before,
    .md-typeset tr.block-highlight--active > th,
    .md-typeset tr.block-highlight--active > td {
        animation: none;
    }

    .md-typeset .block-highlight--active:not(tr) {
        background-color: var(--fragment-highlight-bg-1);
        box-shadow: 0 0 0 1px var(--fragment-highlight-ring-1);
    }
}

/* =============================================================
   Focused UI Sync Layer (Light + Dark)
   Shared fallback fonts, page entrance, button hover and scrollbars.
   ============================================================= */

/* Fonts */
html {
    font-family: "Inter", "Noto Sans SC", "Segoe UI", sans-serif;
}

.md-typeset h1,
.md-typeset h2,
.md-typeset h3,
.md-typeset h4 {
    font-family: "Playfair Display", "Noto Serif SC", serif;
}

.md-button {
    font-family: "Inter", "Noto Sans SC", "Segoe UI", sans-serif;
}

.md-typeset code,
.md-typeset pre code,
.md-tabs__link,
.md-nav__link {
    font-family: "JetBrains Mono", "Fira Code", monospace;
}

/* Fade-in animation */
.md-content__inner {
    animation: pageFadeIn 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes pageFadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Hover lift behavior */
.md-button {
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.25s ease;
}

.md-button:hover {
    transform: translateY(-3px);
}

[data-md-color-scheme="default"] .md-button:hover {
    box-shadow: 0 12px 30px -10px rgba(15, 23, 42, 0.2);
}

[data-md-color-scheme="slate"] .md-button:hover {
    box-shadow: 0 14px 34px -12px rgba(1, 4, 9, 0.65);
}

/* Custom scrollbar */
[data-md-color-scheme="default"] ::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

[data-md-color-scheme="default"] ::-webkit-scrollbar-track {
    background: transparent;
}

[data-md-color-scheme="default"] ::-webkit-scrollbar-thumb {
    background: #a8a29e;
    border-radius: 3px;
}

[data-md-color-scheme="default"] ::-webkit-scrollbar-thumb:hover {
    background: #78716c;
}

[data-md-color-scheme="slate"] ::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

[data-md-color-scheme="slate"] ::-webkit-scrollbar-track {
    background: rgba(2, 6, 23, 0.7);
}

[data-md-color-scheme="slate"] ::-webkit-scrollbar-thumb {
    background: #334155;
    border-radius: 3px;
}

[data-md-color-scheme="slate"] ::-webkit-scrollbar-thumb:hover {
    background: #475569;
}

/* Desktop tabs + active state */


@media (prefers-reduced-motion: reduce) {
    .md-content__inner,
    .md-button,
    .admonition,
    .highlight,
    .md-typeset table:not([class]),
    .md-tabs__link,
    .md-tabs__link::after {
        animation: none !important;
        transition: none !important;
        transform: none !important;
    }
}

/* ==============================================
   斜体强调 (Italic Emphasis) - 浅绿色，与浙大蓝/琥珀金互补
   亮色: 沉稳的深松绿；暗色: 柔和的薄荷绿
   *text*       → em            → 浅绿斜体
   ***text***   → strong>em     → 粗+斜+绿色 + 半透明绿底色横条
   补丁：作为本地 patch 追加到上游样式之后，覆盖任何未定义的 em 样式
   ============================================== */
[data-md-color-scheme="default"] .md-typeset em {
    color: #15803d;
    font-style: italic;
    font-weight: 500;
}

[data-md-color-scheme="default"] .md-typeset strong em,
[data-md-color-scheme="default"] .md-typeset em strong {
    color: #14532d;
    font-style: italic;
    font-weight: 700;
    background: linear-gradient(180deg, transparent 65%, rgba(21, 128, 61, 0.15) 65%);
    padding: 0 0.1em;
    border-radius: 2px;
}

[data-md-color-scheme="slate"] .md-typeset em {
    color: #86efac;
    font-style: italic;
    font-weight: 500;
}

[data-md-color-scheme="slate"] .md-typeset strong em,
[data-md-color-scheme="slate"] .md-typeset em strong {
    color: #bbf7d0;
    font-style: italic;
    font-weight: 700;
    background: linear-gradient(180deg, transparent 65%, rgba(134, 239, 172, 0.18) 65%);
    padding: 0 0.1em;
    border-radius: 2px;
}

/* ==========================================================================
   Academic Homepage
   ========================================================================== */

body,
.academic-home-layout {
    --academic-card-bg: rgba(255, 255, 255, 0.82);
    --academic-card-border: rgba(15, 23, 42, 0.1);
    --academic-muted: #64748b;
    --academic-ink: #111827;
    --academic-accent: #2563eb;
    --academic-date: #14796d;
    --academic-rule: #b45f16;
    --academic-soft: rgba(0, 63, 136, 0.06);
}

body[data-md-color-scheme="slate"],
body[data-md-color-scheme="slate"] .academic-home-layout {
    --academic-card-bg: #0d1117;
    --academic-card-border: #30363d;
    --academic-muted: #8b949e;
    --academic-ink: #c9d1d9;
    --academic-accent: #58a6ff;
    --academic-date: #3fb950;
    --academic-rule: #30363d;
    --academic-soft: #161b22;
}


.academic-content {
    display: flex;
    flex-direction: column;
    gap: clamp(1.7rem, 3vw, 2.45rem);
    min-width: 0;
}

/* ==========================================================================
   正文排版系统精修 (Typography & Spacing Polish)
   ========================================================================== */

/* --- 标题装饰横线 --- */
.title-dash {
    display: inline-block;
    width: 2rem;
    height: 2px;
    background: var(--academic-rule);
    border-radius: 2px;
}

/* --- Section flow --- */
.academic-section {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 100%;
}


/* --- Academic links --- */
.academic-section p a {
    color: var(--academic-accent) !important;
    font-weight: 500;
    text-decoration: none !important;
    border-bottom: 0;
    padding-bottom: 0;
    transition: all 0.25s ease;
}

.academic-section p a:hover {
    color: #1d4ed8 !important;
    border-bottom: 0;
    text-decoration: underline !important;
    text-underline-offset: 3px;
    background: transparent;
}

/* --- Dark prose --- */
[data-md-color-scheme="slate"] .academic-section p {
    color: #cbd5e1;
}

[data-md-color-scheme="slate"] .academic-section p a {
    color: #58a6ff !important;
    border-bottom: 0;
}

[data-md-color-scheme="slate"] .academic-section p a:hover {
    color: #79c0ff !important;
    border-bottom: 0;
    text-decoration: underline !important;
    text-underline-offset: 3px;
    background: transparent;
}

.animate-slide-up {
    opacity: 1;
    transform: none;
}

.news-list,
.award-list {
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.news-list {
    border-top: 0;
}

.news-list li {
    display: grid !important;
    grid-template-columns: 5.2rem minmax(0, 1fr) !important;
    gap: 0.8rem;
    align-items: start;
    padding: 0.6rem 0 !important;
    margin: 0 !important;
    border-bottom: 1px solid var(--academic-card-border) !important;
}

.award-year,
.cv-time {
    color: var(--academic-date) !important;
    font-size: 0.76rem;
    font-weight: 700 !important;
    letter-spacing: 0.03em;
}

.news-date {
    color: var(--academic-date) !important;
    font-size: 0.76rem;
    font-weight: 700 !important;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.news-text {
    color: var(--md-default-fg-color);
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.45;
}




.md-typeset .cv-title {
    margin: 0 !important;
    color: var(--academic-ink) !important;
    font-family: "Inter", "Noto Sans SC", sans-serif !important;
    line-height: 1.36;
    letter-spacing: 0 !important;
}


.award-year {
    display: inline-flex;
    align-items: center;
    min-height: 1.35rem;
    padding: 0 0.42rem;
    background: var(--academic-soft);
    border-radius: 4px;
}


.cv-item {
    position: relative;
    padding-left: 1.25rem;
}


.md-typeset .cv-title {
    font-size: 0.98rem;
}

.cv-subtitle {
    margin: 0.2rem 0 0 !important;
    color: var(--md-default-fg-color);
    font-size: 0.9rem !important;
}

.cv-time {
    margin: 0.2rem 0 0.45rem !important;
}


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

.award-list li {
    display: grid !important;
    grid-template-columns: 6.8rem minmax(0, 1fr);
    gap: 0.9rem;
    align-items: baseline;
    padding: 0.64rem 0;
    border-bottom: 1px solid var(--academic-card-border);
    color: var(--md-default-fg-color);
    font-size: 0.9rem;
    line-height: 1.44;
}

.award-list .award-year {
    display: inline;
    min-height: 0;
    padding: 0;
    color: var(--academic-date) !important;
    background: transparent;
    border-radius: 0;
    white-space: nowrap;
    text-transform: uppercase;
}

.award-copy {
    min-width: 0;
    color: var(--md-default-fg-color);
}

.award-copy strong {
    color: var(--academic-accent) !important;
    background: transparent !important;
    padding: 0 !important;
    font-family: "Inter", "Noto Sans SC", sans-serif;
    font-weight: 750;
}

.award-separator {
    color: var(--academic-muted);
    padding: 0 0.28rem;
}

.visitor-container {
    position: relative;
    text-align: center;
}



@media screen and (max-width: 36rem) {


    .news-list li,
    .award-list li {
        grid-template-columns: 1fr;
        gap: 0.35rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .animate-slide-up {
        animation: none !important;
    }
}

/* ==========================================================================
   Overview emphasis
   ========================================================================== */


[data-md-color-scheme="default"] .md-typeset strong {
    color: #1f2328 !important;
    font-weight: 600;
}

[data-md-color-scheme="slate"] .md-typeset strong {
    color: #f0f6fc !important;
    font-weight: 600;
}

body.is-homepage .academic-section p strong,
body.is-homepage .news-text strong,
.academic-home-layout .academic-section p strong,
.academic-home-layout .news-text strong {
    color: var(--academic-ink) !important;
    background: rgba(175, 184, 193, 0.18) !important;
    border-radius: 4px;
    padding: 0.08em 0.28em;
    font-family: inherit;
    font-weight: 600;
}

body[data-md-color-scheme="slate"].is-homepage .academic-section p strong,
body[data-md-color-scheme="slate"].is-homepage .news-text strong,
body[data-md-color-scheme="slate"] .academic-home-layout .academic-section p strong,
body[data-md-color-scheme="slate"] .academic-home-layout .news-text strong {
    color: #f0f6fc !important;
    background: rgba(110, 118, 129, 0.3) !important;
}

/* ==========================================================================
   Awards names
   ========================================================================== */


.award-name {
    color: var(--academic-muted);
    font-weight: 400;
}

[data-md-color-scheme="slate"] .award-name {
    color: #8b949e;
}

/* ==========================================================================
   HOME subpage content
   ========================================================================== */


.academic-home-layout--subpage .academic-content {
    min-width: 0;
}


/* ==========================================================================
   Desktop frame hygiene
   ========================================================================== */


@media screen and (min-width: 76.25em) {
    :root {
        --compact-header-height: 3.5rem;
    }


    .md-sidebar,
    .md-sidebar--primary,
    .md-sidebar--secondary,
    .md-sidebar__inner,
    .md-sidebar__scrollwrap,
    .md-content,
    .md-content__inner,
    .md-main__inner {
        border-left: 0 !important;
        border-right: 0 !important;
        box-shadow: none !important;
    }

    .md-sidebar::before,
    .md-sidebar::after,
    .md-sidebar--primary::before,
    .md-sidebar--primary::after,
    .md-sidebar--secondary::before,
    .md-sidebar--secondary::after,
    .md-content::before,
    .md-content::after,
    .md-main__inner::before,
    .md-main__inner::after {
        display: none !important;
        content: none !important;
        border: 0 !important;
    }


}

/* ==========================================================================
   Final fixed GitHub frame and profile stability pass
   ========================================================================== */

:root {
    --github-frame-light-bg: #f6f8fa;
    --github-frame-light-border: #d0d7de;
    --github-frame-dark-bg: #0d1117;
    --github-frame-dark-border: #30363d;
}

body[data-md-color-scheme="default"],
body[data-md-color-scheme="default"] .md-container,
body[data-md-color-scheme="default"] .md-main,
body[data-md-color-scheme="default"] .md-content,
body[data-md-color-scheme="default"] .md-content__inner,
body[data-md-color-scheme="default"] .academic-home-layout {
    background: var(--github-frame-light-bg) !important;
}

body[data-md-color-scheme="slate"],
body[data-md-color-scheme="slate"] .md-container,
body[data-md-color-scheme="slate"] .md-main,
body[data-md-color-scheme="slate"] .md-content,
body[data-md-color-scheme="slate"] .md-content__inner,
body[data-md-color-scheme="slate"] .academic-home-layout {
    background: var(--github-frame-dark-bg) !important;
}


@media screen and (min-width: 76.25em) {
    .md-main {
        padding-top: 0 !important;
    }
}

/* ==========================================================================
   Narrow viewport guardrails
   ========================================================================== */

@media screen and (max-width: 58rem) {


    .academic-content {
        width: 100% !important;
        min-width: 0 !important;
    }


}

/* ==========================================================================
   Overview density and responsive flow
   ========================================================================== */


body:is(.is-homepage, .is-home-profile-page) .academic-content,
body:has(.academic-home-layout) .academic-content {
    gap: clamp(1.15rem, 2vw, 1.7rem) !important;
}

body:is(.is-homepage, .is-home-profile-page) .title-dash,
body:has(.academic-home-layout) .title-dash {
    width: 1.45rem !important;
}




body:is(.is-homepage, .is-home-profile-page) .news-text,
body:has(.academic-home-layout) .news-text,
body:is(.is-homepage, .is-home-profile-page) .cv-subtitle,
body:has(.academic-home-layout) .cv-subtitle,
body:is(.is-homepage, .is-home-profile-page) .cv-time,
body:has(.academic-home-layout) .cv-time,
body:is(.is-homepage, .is-home-profile-page) .award-copy,
body:has(.academic-home-layout) .award-copy {
    font-size: 0.76rem !important;
    line-height: 1.48 !important;
}

body:is(.is-homepage, .is-home-profile-page) .cv-title,
body:has(.academic-home-layout) .cv-title {
    font-size: 0.84rem !important;
    line-height: 1.35 !important;
}

body:is(.is-homepage, .is-home-profile-page) .news-date,
body:has(.academic-home-layout) .news-date,
body:is(.is-homepage, .is-home-profile-page) .award-year,
body:has(.academic-home-layout) .award-year {
    font-size: 0.64rem !important;
    line-height: 1.25 !important;
}

/* ==========================================================================
 * 2. EdwinOS final component layer
 * ==========================================================================
 * Component-specific final resolutions live below. This layer must remain
 * after the historical baseline unless a verified migration changes both.
 */

/* Site-hosted Latin subsets remove first-visit Google Fonts dependencies. The
   Chinese glyphs intentionally use the local overview subset and OS fallbacks. */
@font-face {
    font-family: "Source Serif 4";
    src: url("../assets/fonts/source-serif-4/source-serif-4-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 300 600;
    font-display: swap;
}

@font-face {
    font-family: "Source Serif 4";
    src: url("../assets/fonts/source-serif-4/source-serif-4-latin-italic.woff2") format("woff2");
    font-style: italic;
    font-weight: 300 600;
    font-display: swap;
}

@font-face {
    font-family: "JetBrains Mono";
    src: url("../assets/fonts/jetbrains-mono/jetbrains-mono-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 400 500;
    font-display: swap;
}

@font-face {
    font-family: "Inter";
    src: url("../assets/fonts/inter/inter-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 300 700;
    font-display: swap;
}

@font-face {
    font-family: "Playfair Display";
    src: url("../assets/fonts/playfair-display/playfair-display-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
}

@font-face {
    font-family: "Playfair Display";
    src: url("../assets/fonts/playfair-display/playfair-display-latin-italic.woff2") format("woff2");
    font-style: italic;
    font-weight: 400 700;
    font-display: swap;
}

@font-face {
    font-family: "Cinzel";
    src: url("../assets/fonts/cinzel/cinzel-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 500 600;
    font-display: swap;
}

@font-face {
    font-family: "Cormorant Garamond";
    src: url("../assets/fonts/cormorant-garamond/cormorant-garamond-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 500 600;
    font-display: swap;
}

@font-face {
    font-family: "Cormorant Garamond";
    src: url("../assets/fonts/cormorant-garamond/cormorant-garamond-latin-italic.woff2") format("woff2");
    font-style: italic;
    font-weight: 500 600;
    font-display: swap;
}

@font-face {
    font-family: "Caveat";
    src: url("../assets/fonts/caveat/caveat-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
}

@font-face {
    font-family: "Outfit EdwinOS";
    src: url("../assets/fonts/outfit/outfit-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 300 700;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC,
        U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F,
        U+20AC, U+2122, U+2191-2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: "Outfit EdwinOS";
    src: url("../assets/fonts/outfit/outfit-latin-ext.woff2") format("woff2");
    font-style: normal;
    font-weight: 300 700;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC,
        U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
        U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
        U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
    font-family: "Noto Sans SC EdwinOS";
    src: url("../assets/fonts/noto-sans-sc/noto-sans-sc-overview.woff2") format("woff2");
    font-style: normal;
    font-weight: 300 700;
    font-display: swap;
    unicode-range: U+00B7, U+2014, U+2192, U+4E0B, U+4E2D, U+4E8E,
        U+4EF6, U+5145, U+5173, U+5728, U+5BB8, U+5E74, U+5F00,
        U+603B, U+6253, U+63D2, U+65E0, U+6CD5, U+7684, U+7CFB,
        U+7EC8, U+7ECF, U+7ED3, U+7EDF, U+8865, U+95EE, U+9898,
        U+FF1A;
}

/* ==========================================================================
   Typography
   ========================================================================== */

:root {
    --edwinos-font-serif: "Source Serif 4", Georgia, "Noto Serif SC",
        "Microsoft YaHei", "PingFang SC", serif;
    --edwinos-font-hand: "Caveat", cursive;
    --edwinos-font-mono: "JetBrains Mono", "Noto Sans SC EdwinOS",
        "Microsoft YaHei", "PingFang SC", "Courier New", monospace;
    --edwinos-font-reading-sans: "Outfit EdwinOS", "Noto Sans SC EdwinOS",
        "PingFang SC", "Microsoft YaHei", sans-serif;
}

body,
.md-typeset,
.md-content,
.academic-content,
.archive-hero__lead,
.archive-note,
.friend-desc {
    font-family: var(--edwinos-font-serif) !important;
}

body.is-homepage .academic-home-layout .academic-content {
    font-family: var(--edwinos-font-reading-sans) !important;
    font-weight: 400;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

/* Overview section titles: base layout, final typeface, then route density. */
.academic-home-layout .academic-section > .section-title {
    -webkit-user-select: none;
    user-select: none;
}
.section-title {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin: 0 0 1.2rem 0 !important;
    color: var(--academic-ink) !important;
    border-bottom: 0 !important;
    font-size: 1.35rem !important;
    font-weight: 750 !important;
}

.md-typeset .section-title,
.section-title,
.md-typeset .archive-hero h1,
.archive-hero h1,
.md-typeset .archive-year__heading h2,
.archive-year__heading h2 {
    font-family: var(--edwinos-font-hand) !important;
    letter-spacing: 0 !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .cv-title,
body:has(.academic-home-layout) .md-typeset .cv-title,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .archive-card__title,
body:has(.academic-home-layout) .md-typeset .archive-card__title,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .friend-name,
body:has(.academic-home-layout) .md-typeset .friend-name {
    font-family: var(--edwinos-font-serif) !important;
    letter-spacing: 0 !important;
}

body.is-homepage .md-typeset .cv-title {
    font-family: var(--edwinos-font-reading-sans) !important;
    letter-spacing: -0.01em !important;
}

body:is(.is-homepage, .is-home-profile-page) .section-title,
body:has(.academic-home-layout) .section-title {
    gap: 0.55rem !important;
    margin-bottom: 10px !important;
    font-size: 1.48rem !important;
    font-weight: 700 !important;
    line-height: 1.08 !important;
}


body:is(.is-homepage, .is-home-profile-page) .md-typeset .cv-title,
body:has(.academic-home-layout) .md-typeset .cv-title {
    font-size: 1.04rem !important;
    font-weight: 600 !important;
    line-height: 1.28 !important;
}

body.is-homepage .md-typeset .cv-title {
    font-size: 17px !important;
    font-weight: 500 !important;
    line-height: 1.3 !important;
}

.md-header,
.md-tabs,
.md-nav,
.md-search,
.md-footer,
.news-date,
.award-year,
.cv-time,
.archive-hero__eyebrow,
.archive-hero__stats,
.archive-card__meta,
.archive-card__status,
.archive-card__category,
.md-typeset code,
.md-typeset pre code {
    font-family: var(--edwinos-font-mono) !important;
}


body.is-homepage .news-text,
body.is-homepage .cv-subtitle,
body.is-homepage .award-copy {
    font-family: var(--edwinos-font-reading-sans) !important;
    letter-spacing: 0 !important;
}

body.is-homepage .academic-home-layout :is(.news-date, .cv-time, .award-year, .visitor-meta-footer__signature, .visitor-badge-fallback) {
    font-family: var(--edwinos-font-reading-sans) !important;
}


body.is-homepage .academic-home-layout :is(.cv-time) {
    font-size: 12.5px !important;
    font-weight: 500 !important;
    letter-spacing: 0.04em !important;
    line-height: 1.4 !important;
}

body.is-homepage .academic-home-layout .cv-subtitle {
    font-size: 13.5px !important;
    font-weight: 400 !important;
    line-height: 1.5 !important;
}


body.is-homepage .academic-home-layout :is(.award-year) {
    font-size: 12px !important;
    font-weight: 500 !important;
    letter-spacing: 0.02em !important;
    line-height: 1.65 !important;
}


body.is-homepage .academic-home-layout .award-copy {
    font-size: 13px !important;
    font-weight: 400 !important;
    line-height: 1.45 !important;
}

body.is-homepage .academic-home-layout .award-copy strong {
    font-family: inherit !important;
    font-weight: 500 !important;
}

@media screen and (max-width: 42.5rem) {
    body.is-homepage .md-typeset .cv-title {
        font-size: 15.5px !important;
    }

    body.is-homepage .academic-home-layout .award-copy {
        font-size: 12.5px !important;
    }
}

/* Bold marked text needs a quiet surface in dark articles; the legacy yellow
   fill has insufficient contrast with the surrounding GitHub-dark palette. */
body[data-md-color-scheme="slate"]
.md-content__inner.md-typeset
:is(strong > mark, strong > .pymdownx-mark, mark:has(> strong), .pymdownx-mark:has(> strong)) {
    color: inherit;
    background-color: rgba(177, 186, 196, 0.16);
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
}

/* Search Keyword Marks: translucent orange covers each inline fragment.
   Animate its color, never the author's text opacity;
   authored mark fills and lower emphasis remain visible underneath. */
@property --edwinos-search-match-fill {
    syntax: "<color>";
    inherits: true;
    initial-value: transparent;
}

:root {
    --edwinos-search-match-tint: rgba(255, 128, 24, 0.26);
    --edwinos-search-match-glow: rgba(255, 143, 32, 0.3);
}

[data-md-color-scheme="slate"] {
    --edwinos-search-match-tint: rgba(255, 165, 66, 0.3);
    --edwinos-search-match-glow: rgba(255, 151, 40, 0.38);
}

.md-content__inner.md-typeset mark[data-md-highlight] {
    --edwinos-search-match-fill: var(--edwinos-search-match-tint);
    background: var(--edwinos-search-match-fill) !important;
    color: inherit !important;
    padding: 0 !important;
    border-radius: 0;
    font-style: inherit;
    font-weight: inherit;
    box-shadow: inset 0 2px 4px -2px var(--edwinos-search-match-glow);
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
    transition: --edwinos-search-match-fill 1500ms linear, box-shadow 1500ms linear;
}

.md-content__inner.md-typeset mark[data-md-highlight][data-edwinos-search-highlight="fading"],
.md-content__inner.md-typeset mark[data-md-highlight][data-edwinos-search-highlight="done"] {
    --edwinos-search-match-fill: transparent;
    box-shadow: inset 0 2px 4px -2px transparent;
}

@media (prefers-reduced-motion: reduce) {
    .md-content__inner.md-typeset mark[data-md-highlight] {
        transition: none;
    }
}

/* ==========================================================================
   Markdown Lists
   ========================================================================== */

/* Own only Markdown lists. Component lists carry classes and retain their
   component geometry instead of inheriting article indentation and markers. */
.md-typeset :where(ul:not([class]), ol:not([class]), ul.task-list) {
    margin-left: 1.5em !important;
    padding-left: 1em !important;
}

.md-typeset :where(ul:not([class]), ol:not([class]), ul.task-list) li {
    display: list-item !important;
}

.md-typeset :where(ul:not([class]), ul.task-list) {
    list-style-type: disc !important;
}

.md-typeset
:where(ul:not([class]), ul.task-list)
:where(ul:not([class]), ul.task-list) {
    list-style-type: circle !important;
}

.md-typeset
:where(ul:not([class]), ul.task-list)
:where(ul:not([class]), ul.task-list)
:where(ul:not([class]), ul.task-list) {
    list-style-type: square !important;
}

.md-typeset :where(ol:not([class])) {
    list-style-type: decimal !important;
}

.md-typeset :where(ol:not([class])) :where(ol:not([class])) {
    list-style-type: lower-alpha !important;
}

.md-typeset
:where(ol:not([class]))
:where(ol:not([class]))
:where(ol:not([class])) {
    list-style-type: lower-roman !important;
}

/* Root Markdown lists start at the article edge. Material's own direct-li
   margin supplies the marker gutter. Nested lists keep a compact, visible
   hierarchy without starving third- and fourth-level text of line width. */
.md-content__inner.md-typeset
> :is(ul:not([class]), ol:not([class])) {
    margin-inline-start: 0 !important;
    padding-inline-start: 0 !important;
    list-style-position: outside !important;
}

.md-content__inner.md-typeset
li > :is(ul:not([class]), ol:not([class])) {
    margin-inline-start: 0.2em !important;
    padding-inline-start: 1.35em !important;
    list-style-position: outside !important;
}

.md-content__inner.md-typeset
:is(ul:not([class]), ol:not([class])) > li {
    display: list-item !important;
}

@media screen and (max-width: 600px) {
    .md-typeset :where(ul:not([class]), ol:not([class]), ul.task-list) {
        margin-left: 1.2em !important;
    }
}

/* ==========================================================================
   Code Blocks
   ========================================================================== */

body[data-md-color-scheme="default"] {
    --md-code-bg-color: #f2f2f2;
    --md-code-fg-color: #2e3338;
    --edwinos-code-border: rgba(46, 51, 56, 0.12);
    --edwinos-code-title-bg: rgba(46, 51, 56, 0.045);
    --edwinos-inline-code-bg: rgba(46, 51, 56, 0.075);
    --edwinos-inline-code-fg: #9f1d35;
    --edwinos-code-label-fg: rgba(46, 51, 56, 0.52);
}

body[data-md-color-scheme="slate"] {
    --md-code-bg-color: #242424;
    --md-code-fg-color: #dcddde;
    --edwinos-code-border: rgba(255, 255, 255, 0.11);
    --edwinos-code-title-bg: rgba(255, 255, 255, 0.045);
    --edwinos-inline-code-bg: rgba(255, 255, 255, 0.085);
    --edwinos-inline-code-fg: #ff7b72;
    --edwinos-code-label-fg: rgba(220, 221, 222, 0.52);
}

/* The highlight wrapper is the only visual frame. Keeping pre/code frameless
   prevents the doubled top and bottom rules caused by the legacy cascade. */
.md-typeset .highlight {
    margin: 1.15em 0;
    overflow: hidden;
    background: var(--md-code-bg-color);
    border: 1px solid var(--edwinos-code-border);
    border-radius: 0.5rem;
    box-shadow: none;
}

.md-typeset .highlight > pre {
    margin: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.md-typeset .highlight > pre > code {
    display: block;
    margin: 0;
    padding: 0.82rem 1rem;
    overflow: auto;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

/* Pymdown title support. Untitled blocks have no internal divider. */
.md-typeset .highlight > .filename {
    display: block;
    margin: 0;
    padding: 0.48rem 1rem;
    color: var(--md-default-fg-color--light);
    background: var(--edwinos-code-title-bg);
    border: 0;
    border-bottom: 1px solid var(--edwinos-code-border);
    font-family: var(--edwinos-font-mono);
    font-size: 0.78rem;
    font-weight: 500;
    line-height: 1.45;
}

/* Standalone pre is uncommon with Pymdown, but receives the same single-frame
   treatment without matching pre elements that already live in .highlight. */
.md-typeset pre:not(.highlight > pre) {
    margin: 1.15em 0;
    padding: 0.82rem 1rem;
    overflow: auto;
    background: var(--md-code-bg-color);
    border: 1px solid var(--edwinos-code-border);
    border-radius: 0.5rem;
    box-shadow: none;
}

.md-typeset pre:not(.highlight > pre) > code {
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.md-typeset :not(pre) > code {
    padding: 0.1em 0.32em;
    color: var(--edwinos-inline-code-fg);
    background: var(--edwinos-inline-code-bg);
    border: 0;
    border-radius: 0.28rem;
    box-shadow: none;
    -webkit-box-decoration-break: clone;
    box-decoration-break: clone;
}

.md-typeset .md-code__button {
    border-radius: 0.32rem;
}

/* The copy utility is one small glass host; the native button and mask remain
   sharp above it. Blocks with additional tools keep Material's utility group. */
.md-typeset .md-code__nav:has(> .md-code__button[data-md-type="copy"]):not(:has(> .md-code__button:not([data-md-type="copy"]))) {
    --edwinos-copy-blur: 2.5px;
    padding: 0.2rem;
    border-radius: 7px;
    background: rgba(255, 255, 255, 0.13);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72),
                inset 0 -1px 0 rgba(52, 61, 73, 0.12),
                0 1px 4px rgba(28, 37, 49, 0.08);
    -webkit-backdrop-filter: blur(var(--edwinos-copy-blur)) saturate(1.12);
    backdrop-filter: blur(var(--edwinos-copy-blur)) saturate(1.12);
}

.md-typeset .md-code__nav.edwinos-copy-refraction:has(> .md-code__button[data-md-type="copy"]):not(:has(> .md-code__button:not([data-md-type="copy"]))) {
    -webkit-backdrop-filter: var(--edwinos-copy-filter) saturate(1.12);
    backdrop-filter: var(--edwinos-copy-filter) saturate(1.12);
}

.md-typeset .md-code__nav:has(> .md-code__button[data-md-type="copy"]):not(:has(> .md-code__button:not([data-md-type="copy"]))) > .md-code__button {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 1rem;
    height: 1rem;
    margin: 0;
    color: var(--md-default-fg-color--light);
}

.md-typeset .md-code__nav:has(> .md-code__button[data-md-type="copy"]):not(:has(> .md-code__button:not([data-md-type="copy"]))):is(:hover, :focus-within) {
    background: rgba(255, 255, 255, 0.25);
}

.md-typeset .md-code__nav:has(> .md-code__button[data-md-type="copy"]) > .md-code__button:focus-visible {
    outline: 2px solid var(--md-accent-fg-color);
    outline-offset: 3px;
}

.md-typeset .edwinos-copy-glass__highlight {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    box-shadow: inset 1px 0 rgba(255, 255, 255, 0.25),
                inset -1px 0 rgba(255, 255, 255, 0.15);
    pointer-events: none;
}

body[data-md-color-scheme="slate"] .md-typeset .md-code__nav:has(> .md-code__button[data-md-type="copy"]):not(:has(> .md-code__button:not([data-md-type="copy"]))) {
    background: rgba(34, 41, 52, 0.2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2),
                inset 0 -1px 0 rgba(0, 0, 0, 0.24),
                0 1px 4px rgba(0, 0, 0, 0.16);
}

body[data-md-color-scheme="slate"] .md-typeset .md-code__nav:has(> .md-code__button[data-md-type="copy"]):not(:has(> .md-code__button:not([data-md-type="copy"]))):is(:hover, :focus-within) {
    background: rgba(98, 112, 130, 0.2);
}

/* Language metadata reserves its own area left of copy in every state, so
   the label and control cannot overlap during their opacity crossfade. */
.md-typeset .highlight[data-code-language] {
    position: relative;
}

.md-typeset .highlight[data-code-language]::before {
    position: absolute;
    top: 0.25rem;
    inset-inline-end: 2.55rem;
    z-index: 1;
    height: 1.6rem;
    max-width: calc(100% - 5.25rem);
    overflow: hidden;
    color: var(--edwinos-code-label-fg);
    font-family: var(--edwinos-font-serif);
    font-size: 0.58rem;
    font-weight: 400;
    line-height: 1.6rem;
    text-overflow: ellipsis;
    white-space: nowrap;
    content: attr(data-code-language);
    pointer-events: none;
    user-select: none;
    transition: opacity 140ms ease;
}

.md-typeset .highlight[data-code-language]:not(:has(.md-code__nav))::before {
    inset-inline-end: 0.75rem;
}

.md-typeset .highlight[data-code-language] > pre > code {
    padding-top: 0.82rem;
}

.md-typeset .highlight[data-code-language]:has(> .filename) > .filename {
    padding-inline-end: 7rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.md-typeset .highlight[data-code-language]:has(> .filename) > pre > code {
    padding-top: 0.82rem;
}

/* Fine pointers can discover the copy control in its actual hit area: the
   language fades out and the button fades in without shifting any code. */
@media (hover: hover) and (pointer: fine) {
    .md-typeset
    .highlight[data-code-language]:not(:has(> .filename))::before {
        padding-inline: 0.28rem;
        border-radius: 0.28rem;
    }

    .md-typeset
    .highlight[data-code-language]:not(:has(> .filename))
    .md-code__nav {
        opacity: 0;
        transition: opacity 140ms ease, background-color 250ms;
    }

    .md-typeset
    .highlight[data-code-language]:not(:has(> .filename))
    .md-code__nav:is(:hover, :focus-within) {
        opacity: 1;
    }

    .md-typeset
    .highlight[data-code-language]:not(:has(> .filename)):has(.md-code__nav:hover)::before,
    .md-typeset
    .highlight[data-code-language]:not(:has(> .filename)):has(.md-code__nav:focus-within)::before {
        opacity: 0;
    }
}

@media screen and (max-width: 44.984375em) {
    .md-typeset .highlight[data-code-language]::before {
        font-size: 0.56rem;
    }

    .md-typeset .highlight[data-code-language] > pre > code {
        padding: 0.72rem 0.75rem;
    }

    .md-typeset .highlight[data-code-language]:has(> .filename) > pre > code {
        padding-top: 0.72rem;
    }
}

@media print {
    .md-typeset .highlight[data-code-language]::before {
        inset-inline-end: 0.75rem;
    }
}

/* ==========================================================================
   Callouts
   ========================================================================== */

.md-typeset :is(.admonition, details) {
    --edwinos-callout-rgb: 8, 109, 221;
    --edwinos-callout-alpha: 0.1;
    margin: 1.1em 0;
    padding: 0.58rem 0.72rem;
    overflow: visible;
    color: var(--md-default-fg-color);
    background: rgba(var(--edwinos-callout-rgb), var(--edwinos-callout-alpha));
    border: 0;
    border-radius: 0.48rem;
    box-shadow: none;
    font-size: 0.8rem;
    line-height: 1.55;
}

.md-typeset :is(.admonition, details):focus-within {
    box-shadow: none;
}

.md-typeset :is(.admonition, details) > :is(.admonition-title, summary) {
    position: relative;
    display: block;
    min-height: 1.25rem;
    margin: 0;
    padding: 0 0 0 1.55rem;
    color: rgb(var(--edwinos-callout-rgb));
    background: transparent;
    border: 0;
    border-radius: 0;
    font-size: 1em;
    font-weight: 600;
    line-height: 1.45;
}

.md-typeset details > summary {
    padding-right: 1.7rem;
    cursor: pointer;
}

/* Animated Obsidian-style callouts keep the card itself fill-only. The
   runtime temporarily clips the height while the body is revealed, so the
   card grows and the following content moves as one continuous motion. */
.md-typeset details[data-edwinos-callout] {
    border: 0 !important;
    border-color: transparent !important;
    outline: 0;
    box-shadow: none !important;
}

.md-typeset details[data-edwinos-callout][data-edwinos-callout-state]
> summary {
    -webkit-user-select: none;
    user-select: none;
}

.md-typeset details:not([open]) {
    padding-bottom: 0.58rem;
}

.md-typeset :is(.admonition, details) > :is(.admonition-title, summary)::before {
    position: absolute;
    top: 0.12em;
    left: 0;
    width: 1.08rem;
    height: 1.08rem;
    margin: 0;
    background-color: rgb(var(--edwinos-callout-rgb));
}

.md-typeset details > summary::after {
    top: 50%;
    right: 0;
    width: 1.08rem;
    height: 1.08rem;
    margin: 0;
    background-color: rgb(var(--edwinos-callout-rgb));
    transform: translateY(-50%);
    transform-origin: center;
    transition: transform 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

.md-typeset details[open] > summary::after,
.md-typeset details[data-edwinos-callout-state="opening"] > summary::after {
    transform: translateY(-50%) rotate(90deg);
}

.md-typeset details[data-edwinos-callout-state="closing"] > summary::after {
    transform: translateY(-50%);
}

.md-typeset details > summary:focus-visible {
    outline: 2px solid rgba(var(--edwinos-callout-rgb), 0.42);
    outline-offset: 0.22rem;
    border-radius: 0.2rem;
}

.md-typeset .admonition > :not(.admonition-title),
.md-typeset details[open] > :not(summary) {
    margin-top: 0.52rem;
    margin-bottom: 0;
}

.md-typeset :is(.admonition, details) > :is(ul, ol) {
    margin-left: 1.1em !important;
    padding-left: 0.9em !important;
}

/* Keep the PHIL 206 usage card's nested bullets compact and readable. */
.md-typeset #phil-206-notes + p + details.tip li > :is(ul, ol) {
    margin-inline-start: 0 !important;
    padding-inline-start: 1.5em !important;
}

.md-typeset :is(.admonition, details) > :is(.admonition-title, summary) code {
    padding: 0.06em 0.26em;
    color: inherit;
    background: rgba(var(--edwinos-callout-rgb), 0.1);
}

.md-typeset :is(.admonition, details) :is(.admonition, details) {
    --edwinos-callout-alpha: 0.13;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition, details) {
    --edwinos-callout-alpha: 0.12;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition, details) :is(.admonition, details) {
    --edwinos-callout-alpha: 0.15;
}

.md-typeset :is(.admonition.note, .admonition.info, .admonition.todo, details.note, details.info, details.todo) {
    --edwinos-callout-rgb: 8, 109, 221;
}

.md-typeset :is(.admonition.abstract, .admonition.summary, .admonition.tldr, .admonition.tip, .admonition.hint, .admonition.important, details.abstract, details.summary, details.tldr, details.tip, details.hint, details.important) {
    --edwinos-callout-rgb: 0, 191, 188;
}

.md-typeset :is(.admonition.success, .admonition.check, .admonition.done, details.success, details.check, details.done) {
    --edwinos-callout-rgb: 8, 185, 78;
}

.md-typeset :is(.admonition.question, .admonition.help, .admonition.faq, details.question, details.help, details.faq) {
    --edwinos-callout-rgb: 224, 172, 0;
}

.md-typeset :is(.admonition.warning, .admonition.caution, .admonition.attention, details.warning, details.caution, details.attention) {
    --edwinos-callout-rgb: 236, 117, 0;
}

.md-typeset :is(.admonition.failure, .admonition.fail, .admonition.missing, .admonition.danger, .admonition.error, .admonition.bug, details.failure, details.fail, details.missing, details.danger, details.error, details.bug) {
    --edwinos-callout-rgb: 233, 49, 71;
}

.md-typeset :is(.admonition.example, details.example) {
    --edwinos-callout-rgb: 120, 82, 238;
}

.md-typeset :is(.admonition.quote, .admonition.cite, details.quote, details.cite) {
    --edwinos-callout-rgb: 112, 118, 125;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition.note, .admonition.info, .admonition.todo, details.note, details.info, details.todo) {
    --edwinos-callout-rgb: 2, 122, 255;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition.abstract, .admonition.summary, .admonition.tldr, .admonition.tip, .admonition.hint, .admonition.important, details.abstract, details.summary, details.tldr, details.tip, details.hint, details.important) {
    --edwinos-callout-rgb: 83, 223, 221;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition.success, .admonition.check, .admonition.done, details.success, details.check, details.done) {
    --edwinos-callout-rgb: 68, 207, 110;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition.question, .admonition.help, .admonition.faq, details.question, details.help, details.faq) {
    --edwinos-callout-rgb: 224, 222, 113;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition.warning, .admonition.caution, .admonition.attention, details.warning, details.caution, details.attention) {
    --edwinos-callout-rgb: 233, 151, 63;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition.failure, .admonition.fail, .admonition.missing, .admonition.danger, .admonition.error, .admonition.bug, details.failure, details.fail, details.missing, details.danger, details.error, details.bug) {
    --edwinos-callout-rgb: 251, 70, 76;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition.example, details.example) {
    --edwinos-callout-rgb: 168, 130, 255;
}

body[data-md-color-scheme="slate"] .md-typeset :is(.admonition.quote, .admonition.cite, details.quote, details.cite) {
    --edwinos-callout-rgb: 166, 171, 178;
}

/* ==========================================================================
   Header, tabs, search, and source
   ========================================================================== */

/* Shared repository icons: both the header and Material drawer use these. */
:root {
    --edwinos-star-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194-3.047-2.97a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Z'/%3E%3C/svg%3E");
    --edwinos-fork-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M5 3.25a1.75 1.75 0 1 1-2.5 1.58v6.34a1.75 1.75 0 1 1-1.5 0V4.83A1.75 1.75 0 1 1 5 3.25Zm6.5-1.75a1.75 1.75 0 1 1-1.5 2.664V5a2.5 2.5 0 0 1-2.5 2.5h-1A1.5 1.5 0 0 0 5 9v2.17a1.75 1.75 0 1 1-1.5 0V9a3 3 0 0 1 3-3h1a1 1 0 0 0 1-1v-.836A1.75 1.75 0 0 1 11.5 1.5Z'/%3E%3C/svg%3E");
}

/* Retained palette, controls, tabs and search state primitives.
   Values below survive the historical cascade; geometry is owned by the
   responsive coordinate system that follows. The unscoped source primitives
   also serve Material's drawer repository, outside the header. */

.md-search__input {
    transition: all 0.3s ease;
}

.md-search__suggest {
    display: none !important;
}

[data-md-color-scheme="slate"] .md-header .md-header__title,
[data-md-color-scheme="slate"] .md-header .md-header__topic,
[data-md-color-scheme="slate"] .md-header .md-header__title .md-ellipsis,
[data-md-color-scheme="slate"] .md-header .md-header__topic .md-ellipsis,
[data-md-color-scheme="slate"] .md-header .md-logo,
[data-md-color-scheme="slate"] .md-header .md-header__button,
[data-md-color-scheme="slate"] .md-header .md-header__button .md-icon,
[data-md-color-scheme="slate"] .md-header .md-header__option .md-icon,
[data-md-color-scheme="slate"] .md-header [data-md-component="palette"] .md-icon,
[data-md-color-scheme="slate"] .md-header .md-source,
[data-md-color-scheme="slate"] .md-header .md-source__repository,
[data-md-color-scheme="slate"] .md-header .md-source .md-source__repository .md-ellipsis,
[data-md-color-scheme="slate"] .md-header .md-source__fact {
    color: #ffffff !important;
}

[data-md-color-scheme="slate"] .md-tabs__link {
    color: #8b949e !important;
    transition: all 0.3s ease;
}

[data-md-color-scheme="slate"] .md-tabs__link:hover,
[data-md-color-scheme="slate"] .md-tabs__link--active {
    color: #c9d1d9 !important;
    background: rgba(22, 27, 34, 0.92);
}

[data-md-color-scheme="default"] .md-header .md-header__title,
[data-md-color-scheme="default"] .md-header .md-header__topic,
[data-md-color-scheme="default"] .md-header .md-header__title .md-ellipsis,
[data-md-color-scheme="default"] .md-header .md-header__topic .md-ellipsis,
[data-md-color-scheme="default"] .md-header .md-logo,
[data-md-color-scheme="default"] .md-header .md-header__button,
[data-md-color-scheme="default"] .md-header .md-header__button .md-icon,
[data-md-color-scheme="default"] .md-header .md-header__option .md-icon,
[data-md-color-scheme="default"] .md-header [data-md-component="palette"] .md-icon,
[data-md-color-scheme="default"] .md-header .md-source,
[data-md-color-scheme="default"] .md-header .md-source__repository,
[data-md-color-scheme="default"] .md-header .md-source .md-source__repository .md-ellipsis,
[data-md-color-scheme="default"] .md-header .md-source__fact {
    color: #292524 !important;
}

[data-md-color-scheme="default"] .md-header .md-header__button:hover,
[data-md-color-scheme="default"] .md-header .md-header__button:hover .md-icon,
[data-md-color-scheme="default"] .md-header .md-header__option:hover .md-icon,
[data-md-color-scheme="default"] .md-header .md-logo:hover,
[data-md-color-scheme="default"] .md-header .md-source:hover,
[data-md-color-scheme="default"] .md-header .md-source:hover .md-source__repository,
[data-md-color-scheme="default"] .md-header .md-source:hover .md-source__fact {
    color: #1e3a8a !important;
}

[data-md-color-scheme="slate"] .md-header,
[data-md-color-scheme="slate"] .md-tabs {
    border-bottom-width: 1px;
    border-bottom-style: solid;
}

.md-tabs__list {
    gap: 0.2rem;
}

.md-tabs__link {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.2rem;
    padding: 0.35rem 0.7rem;
    border-radius: 8px;
}

.md-tabs__link::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -0.2rem;
    width: 0;
    height: 2px;
    transition: width 0.3s ease;
}

[data-md-color-scheme="default"] .md-tabs__link {
    color: #57534e;
}

[data-md-color-scheme="default"] .md-tabs__link:hover,
[data-md-color-scheme="default"] .md-tabs__link--active {
    background: rgba(255, 255, 255, 0.65);
    color: #0f172a;
}

[data-md-color-scheme="default"] .md-tabs__link::after {
    background: linear-gradient(90deg, #1e3a8a, #2563eb);
}

[data-md-color-scheme="slate"] .md-tabs__link::after {
    background: #58a6ff;
}

.md-tabs__link:hover::after,
.md-tabs__link--active::after {
    width: 100%;
}

@media screen and (max-width: 76.1875em) {
    .md-header__button[for="__drawer"] {
        border-radius: 8px;
        transition: background-color 0.2s ease;
    }

    [data-md-color-scheme="default"] .md-header__button[for="__drawer"]:hover {
        background: rgba(231, 229, 228, 0.8);
    }

    [data-md-color-scheme="slate"] .md-header__button[for="__drawer"]:hover {
        background: rgba(51, 65, 85, 0.5);
    }
}

body[data-md-color-scheme="slate"] .md-header {
    max-width: none;
    margin-top: 0;
}

body.is-homepage .md-header,
body.is-homepage .md-tabs,
body:has(.academic-home-layout) .md-header,
body:has(.academic-home-layout) .md-tabs {
    background: rgba(250, 247, 240, 0.76) !important;
    border-bottom: 1px solid rgba(15, 23, 42, 0.07) !important;
    box-shadow: none !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

body[data-md-color-scheme="slate"].is-homepage .md-header,
body[data-md-color-scheme="slate"].is-homepage .md-tabs,
body[data-md-color-scheme="slate"]:has(.academic-home-layout) .md-header,
body[data-md-color-scheme="slate"]:has(.academic-home-layout) .md-tabs {
    background: rgba(13, 17, 23, 0.9) !important;
    border-bottom-color: #30363d !important;
}

.md-header::before,
.md-header::after,
.md-header__inner::before,
.md-header__inner::after,
.md-header__source::before,
.md-header__source::after,
.md-header__option::before,
.md-header__option::after,
.md-search::before,
.md-search::after,
.md-tabs::before,
.md-tabs::after,
.md-tabs .md-grid::before,
.md-tabs .md-grid::after,
.md-tabs__list::before,
.md-tabs__list::after,
.md-header__title::before,
.md-header__title::after,
.md-source::before,
.md-source::after,
.md-source__repository::before,
.md-source__repository::after,
.md-source__facts::before,
.md-source__facts::after {
    display: none !important;
    content: none !important;
    border: 0 !important;
}

body[data-md-color-scheme="default"] .md-header,
body[data-md-color-scheme="default"] .md-tabs,
[data-md-color-scheme="default"] .md-header,
[data-md-color-scheme="default"] .md-tabs {
    border-bottom: 1px solid #d0d7de !important;
    box-shadow: none !important;
}

body[data-md-color-scheme="slate"] .md-header,
body[data-md-color-scheme="slate"] .md-tabs,
[data-md-color-scheme="slate"] .md-header,
[data-md-color-scheme="slate"] .md-tabs {
    border-bottom-color: #30363d !important;
    box-shadow: none !important;
}

@media screen and (min-width: 76.25em) {
    .md-header__button.md-logo,
    .md-header__title,
    .md-header__button[for="__drawer"],
    .md-header__button[for="__search"] {
        display: none !important;
    }

    .md-tabs .md-grid {
        overflow: visible !important;
    }

    .md-tabs__list {
        display: flex !important;
        height: auto !important;
        align-items: center !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .md-tabs__item {
        display: block !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .md-tabs__link {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
        border-radius: 999px !important;
        font-weight: 500 !important;
        line-height: 1 !important;
        white-space: nowrap;
    }

    .md-tabs__link::after {
        display: none !important;
    }

    .md-tabs__link:hover {
        transform: translateY(-1px);
    }

    [data-md-color-scheme="default"] .md-tabs__link {
        color: #57606a !important;
    }

    [data-md-color-scheme="default"] .md-tabs__link:hover {
        color: #1F2328 !important;
        background: rgba(31, 35, 40, 0.06) !important;
    }

    [data-md-color-scheme="default"] .md-tabs__link--active,
    [data-md-color-scheme="default"] .md-tabs__item--active .md-tabs__link {
        color: #1F2328 !important;
        background: transparent !important;
        font-weight: 600 !important;
    }

    [data-md-color-scheme="slate"] .md-tabs__link {
        color: #8b949e !important;
    }

    [data-md-color-scheme="slate"] .md-tabs__link:hover {
        color: #c9d1d9 !important;
        background: rgba(240, 246, 252, 0.08) !important;
    }

    [data-md-color-scheme="slate"] .md-tabs__link--active,
    [data-md-color-scheme="slate"] .md-tabs__item--active .md-tabs__link {
        color: #f0f6fc !important;
        background: transparent !important;
        font-weight: 600 !important;
    }

    .md-search {
        grid-column: 2;
        grid-row: 1;
        align-self: center !important;
        justify-self: stretch;
        border: 0 !important;
    }

    .md-header__source {
        grid-column: 3;
        grid-row: 1;
        align-self: center;
        justify-self: end;
        border: 0 !important;
    }

    .md-source {
        display: grid !important;
        width: 100% !important;
        min-width: 0;
        max-width: 100% !important;
        padding: 0 !important;
        border: 0 !important;
        background: transparent !important;
        line-height: 1.2;
        min-height: 2.28rem !important;
        height: 2.28rem !important;
        overflow: visible !important;
        grid-template-columns: 1.42rem minmax(0, 1fr) !important;
        column-gap: 0.34rem !important;
        align-items: center !important;
    }

    .md-source__icon {
        flex: 0 0 auto;
        color: currentColor !important;
        width: 1.42rem !important;
        height: 1.42rem !important;
        align-self: center !important;
        justify-self: center !important;
        transform: translateY(-0.34rem) !important;
    }

    .md-header__option {
        grid-column: 4;
        grid-row: 1;
        align-self: center;
        justify-self: end;
        overflow: visible;
    }

    .md-header__option .md-header__button {
        position: absolute !important;
        inset: 0 !important;
        border-radius: 50%;
        transition: background-color 0.25s ease, transform 0.25s ease, color 0.25s ease;
    }

    .md-header__option .md-header__button[hidden] {
        display: none !important;
    }

    body[data-md-color-scheme="default"] .md-header__option .md-option[data-md-color-scheme="default"] + .md-header__button[hidden],
    body[data-md-color-scheme="slate"] .md-header__option .md-option[data-md-color-scheme="slate"] + .md-header__button[hidden],
    .md-header__option .md-header__button:not([hidden]) {
        display: inline-flex !important;
    }

    .md-header__option .md-header__button:hover {
        transform: translateY(-1px);
    }

    .md-search__inner {
        z-index: 2;
    }

    .md-search__form .md-search__icon[for="__search"] {
        position: absolute !important;
        opacity: 1 !important;
        pointer-events: none;
    }

    .md-search__form .md-search__icon[for="__search"] svg {
        fill: currentColor !important;
    }

    .md-search__options {
        top: 50% !important;
        right: 0.32rem !important;
        height: 1.55rem !important;
        transform: translateY(-50%) !important;
    }

    .md-search__overlay {
        display: none;
    }

    [data-md-toggle="search"]:checked ~ .md-header .md-search,
    .md-header .md-search:focus-within {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
        will-change: auto !important;
        z-index: 20 !important;
    }

    [data-md-toggle="search"]:checked ~ .md-header .md-header__source,
    [data-md-toggle="search"]:checked ~ .md-header .md-header__option {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
        will-change: auto !important;
    }

    [data-md-toggle="search"]:checked ~ .md-header .md-header__option {
        width: 2.2rem !important;
        min-width: 2.2rem !important;
        max-width: 2.2rem !important;
        overflow: visible !important;
    }

    [data-md-toggle="search"]:checked ~ .md-header .md-search__overlay {
        z-index: 1 !important;
        display: block !important;
        cursor: default;
        background: transparent !important;
        opacity: 1 !important;
        pointer-events: auto !important;
    }

    [data-md-toggle="search"]:checked ~ .md-header .md-search__inner,
    .md-header .md-search:focus-within .md-search__inner {
        position: relative !important;
        z-index: 2 !important;
        width: 100% !important;
    }


}

@media (prefers-reduced-motion: reduce) {
    .md-header .md-header__source,
    .md-header .md-search,
    .md-header .md-header__option,
    .md-tabs__link,
    .md-header__option .md-header__button {
        animation: none !important;
        transition: none !important;
        transform: none !important;
    }
}

@media screen and (min-width: 76.25em) {
    body[data-md-color-scheme="slate"] .md-header,
    body[data-md-color-scheme="slate"] .md-tabs {
        border-bottom-color: var(--github-frame-dark-border) !important;
        box-shadow: none !important;
    }

    .md-header[data-md-state="shadow"],
    .md-tabs[data-md-state="hidden"],
    .md-tabs[data-md-state="lock"] {
        transform: none !important;
        box-shadow: none !important;
    }

    .md-source__icon svg {
        fill: currentColor !important;
        overflow: visible !important;
        width: 1.42rem !important;
        height: 1.42rem !important;
        transform: scale(1.08) !important;
        transform-origin: center center !important;
    }

    .md-source__repository {
        display: block !important;
        min-width: 0 !important;
        overflow: hidden !important;
        color: currentColor !important;
        font-size: 0.78rem !important;
        font-weight: 500 !important;
        line-height: 1.08 !important;
        white-space: nowrap !important;
        text-overflow: ellipsis !important;
        transform: none !important;
    }

    .md-source__repository--active {
        transform: none !important;
    }

    .md-source__facts {
        display: flex !important;
        min-height: 0.72rem !important;
        align-items: center !important;
        margin: 0.18rem 0 0 !important;
        padding: 0 !important;
        overflow: visible !important;
        color: inherit !important;
        font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace !important;
        line-height: 1 !important;
        list-style: none !important;
        gap: 0.56rem !important;
        font-size: 0.64rem !important;
        opacity: 0.8 !important;
    }

    .md-source__fact {
        display: inline-flex !important;
        align-items: center !important;
        margin: 0 !important;
        padding: 0 !important;
        color: inherit !important;
        line-height: 1 !important;
        gap: 0.22rem !important;
        font-weight: 500 !important;
    }

    .md-source__fact::before {
        display: inline-block !important;
        flex: 0 0 0.72rem !important;
        content: "" !important;
        background: currentColor !important;
        border: 0 !important;
        -webkit-mask: var(--edwinos-star-icon) center / contain no-repeat;
        mask: var(--edwinos-star-icon) center / contain no-repeat;
        opacity: 0.92;
        width: 0.72rem !important;
        height: 0.72rem !important;
    }

    .md-source__fact:nth-child(2)::before,
    .md-source__fact[data-source-fact="forks"]::before {
        -webkit-mask-image: var(--edwinos-fork-icon);
        mask-image: var(--edwinos-fork-icon);
    }
}

@media screen and (max-width: 88em) and (min-width: 76.25em) {
    .md-source__repository {
        font-size: 0.72rem !important;
    }

    .md-source {
        grid-template-columns: 1.34rem minmax(0, 1fr) !important;
        column-gap: 0.3rem !important;
    }

    .md-source__icon,
    .md-source__icon svg {
        width: 1.34rem !important;
        height: 1.34rem !important;
    }

    .md-source__icon svg {
        transform: scale(1.05) !important;
    }
}

/* Responsive coordinate system */

@media screen and (max-width: 76.1875em) {
    :root {
        --edwinos-mobile-header-height: 3.5rem;
        --edwinos-mobile-drawer-space: 0rem;
    }

    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"]),
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]) {
        --edwinos-mobile-drawer-space: 2.75rem;
    }


    .md-header__inner {
        z-index: 24 !important;
        pointer-events: none !important;
    }

    .md-header__button,
    .md-header__option,
    .md-header .md-search {
        pointer-events: auto !important;
    }

    .md-header__button.md-logo,
    .md-header__button[for="__drawer"],
    .md-header__source,
    .md-header__title,
    .md-header__topic {
        display: none !important;
    }

    .md-header__option {
        align-items: center !important;
        justify-content: center !important;
        order: 2;
    }

    .md-header__option,
    .md-header .md-search,
    .md-header__button[for="__search"] {
        border: 0 !important;
        box-shadow: none !important;
    }

    .md-header__option::before,
    .md-header__option::after,
    .md-header .md-search::before,
    .md-header .md-search::after,
    .md-header__button[for="__search"]::before,
    .md-header__button[for="__search"]::after {
        display: none !important;
        content: none !important;
    }

    .md-header__option .md-header__button,
    .md-header__button[for="__search"] {
        width: 2.2rem !important;
        height: 2.2rem !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
        padding: 0 !important;
        border-radius: 999px !important;
    }

    .md-header__option .md-option + .md-header__button,
    .md-header__option .md-header__button[hidden] {
        display: none !important;
    }

    .md-header__option .md-option + .md-header__button:not([hidden]),
    .md-header__option .md-option:checked + .md-header__button,
    .md-header__button[for="__search"] {
        display: inline-flex !important;
    }

    .md-header__button[for="__search"] {
        order: 1;
    }

    .md-tabs,
    .md-tabs[data-md-state="hidden"],
    .md-tabs[data-md-state="lock"] {
        border-bottom: 0 !important;
        box-shadow: none !important;
    }

    body[data-md-color-scheme] .md-tabs.md-tabs,
    body[data-md-color-scheme] .md-tabs.md-tabs[data-md-state="hidden"],
    body[data-md-color-scheme] .md-tabs.md-tabs[data-md-state="lock"] {
        background: transparent !important;
    }

    .md-tabs .md-grid {
        scrollbar-width: none;
    }

    .md-tabs .md-grid::-webkit-scrollbar {
        display: none;
    }

    .md-tabs__list {
        display: flex !important;
        width: max-content !important;
        height: auto !important;
        align-items: center !important;
        gap: 4px !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .md-tabs__item {
        display: block !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .md-tabs__link {
        display: inline-flex !important;
        height: 2.1rem !important;
        min-height: 2.1rem !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
        padding: 0 11px !important;
        border-radius: 999px !important;
        font-size: 17.2px !important;
        font-weight: 500 !important;
        letter-spacing: 0 !important;
        line-height: 1 !important;
        white-space: nowrap !important;
    }

    .md-tabs__link::after {
        display: none !important;
    }

    [data-md-color-scheme="default"] .md-header {
        border-bottom: 1px solid var(--github-frame-light-border, #d0d7de) !important;
    }

    [data-md-color-scheme="slate"] .md-header {
        border-bottom: 1px solid var(--github-frame-dark-border, #30363d) !important;
    }

    [data-md-toggle="search"]:checked ~ .md-header .md-search__overlay {
        opacity: 1 !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
    }


}

@media screen and (max-width: 35rem) {
    .md-header__option,
    .md-header__option .md-header__button,
    .md-header__button[for="__search"] {
        width: 2rem !important;
        height: 2rem !important;
    }


}

/* Material restores the fixed body's saved position when search unlocks.
   Keep that restoration immediate, including its unlock animation frame. */
html.edwinos-search-scroll-locked {
    scroll-behavior: auto;
}

/* Search: one glass shell grows from capsule to results window. */
.md-header .md-search {
    --edwinos-search-glass-blur: 6px;
    --edwinos-search-results-height: 0px;
    --edwinos-search-result-hover: rgba(60, 60, 67, 0.085);
    --edwinos-search-result-muted: #62646d;
    --edwinos-search-result-color: #25262b;
    --edwinos-search-scrollbar-thumb: rgba(96, 99, 108, 0.38);
    --edwinos-search-scrollbar-hover: rgba(96, 99, 108, 0.56);
}

[data-md-color-scheme="default"] .md-header .md-search {
    --edwinos-search-glass-tint: rgba(118, 118, 128, 0.085);
    --edwinos-search-glass-border: rgba(60, 60, 67, 0.22);
    --edwinos-search-glass-highlight: rgba(255, 255, 255, 0.4);
    --edwinos-search-glass-shadow: 0 2px 9px rgba(31, 35, 40, 0.09);
}

[data-md-color-scheme="slate"] .md-header .md-search {
    --edwinos-search-glass-tint: rgba(20, 25, 33, 0.19);
    --edwinos-search-glass-border: rgba(240, 246, 252, 0.19);
    --edwinos-search-glass-highlight: rgba(240, 246, 252, 0.16);
    --edwinos-search-glass-shadow: 0 2px 9px rgba(1, 4, 9, 0.24);
    --edwinos-search-result-hover: rgba(240, 246, 252, 0.095);
    --edwinos-search-result-muted: #b6bbc4;
    --edwinos-search-result-color: #f0f2f6;
    --edwinos-search-scrollbar-thumb: rgba(190, 195, 205, 0.38);
    --edwinos-search-scrollbar-hover: rgba(190, 195, 205, 0.56);
}

.md-header .md-search.edwinos-search-has-query {
    --edwinos-search-glass-blur: 22px;
}

[data-md-color-scheme="default"] .md-header .md-search.edwinos-search-has-query {
    --edwinos-search-glass-tint: rgba(246, 248, 250, 0.76);
    --edwinos-search-glass-border: rgba(60, 60, 67, 0.19);
    --edwinos-search-glass-shadow: 0 18px 44px rgba(31, 35, 40, 0.18);
}

[data-md-color-scheme="slate"] .md-header .md-search.edwinos-search-has-query {
    --edwinos-search-glass-tint: rgba(25, 29, 37, 0.76);
    --edwinos-search-glass-border: rgba(240, 246, 252, 0.2);
    --edwinos-search-glass-shadow: 0 18px 44px rgba(1, 4, 9, 0.38);
}

.md-header .edwinos-search-shell {
    position: absolute;
    top: 0;
    right: 1px;
    left: 1px;
    z-index: 0;
    box-sizing: border-box;
    height: var(--edwinos-search-shell-height, 100%);
    border-radius: min(24px, calc(var(--edwinos-search-input-height, 44px) / 2));
    box-shadow: var(--edwinos-search-glass-shadow);
    pointer-events: none;
    transition: box-shadow 220ms ease;
}

.md-header .md-search__form {
    z-index: 2;
    overflow: visible !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 999px !important;
    box-shadow: none !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
}

.md-header .md-search__input {
    position: relative !important;
    z-index: 2 !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: inherit !important;
    box-shadow: none !important;
}

.md-header .md-search__options {
    display: none !important;
}

[data-md-color-scheme="default"] .md-header .md-search__input {
    color: #1c1c1e !important;
}

[data-md-color-scheme="default"] .md-header .md-search__input::placeholder,
[data-md-color-scheme="default"] .md-header .md-search__form .md-search__icon {
    color: #51515a !important;
}

[data-md-color-scheme="slate"] .md-header .md-search__input {
    color: #f0f6fc !important;
}

[data-md-color-scheme="slate"] .md-header .md-search__input::placeholder,
[data-md-color-scheme="slate"] .md-header .md-search__form .md-search__icon {
    color: #aeb5c0 !important;
}

.md-header .edwinos-search-shell .edwinos-search-glass {
    position: absolute;
    inset: 0;
    display: block;
    box-sizing: border-box;
    border-radius: inherit;
    pointer-events: none;
}

.md-header .edwinos-search-shell .edwinos-search-glass--surface {
    z-index: 0;
    background: var(--edwinos-search-glass-tint);
    -webkit-backdrop-filter: blur(var(--edwinos-search-glass-blur)) saturate(1.16);
    backdrop-filter: blur(var(--edwinos-search-glass-blur)) saturate(1.16);
    transition: background-color 220ms ease;
}

/* Chromium samples outside the perimeter and clips one uninterrupted surface
   to the current shape. Other browsers retain the same continuous native blur. */
.md-header .edwinos-search-refraction .edwinos-search-glass--surface {
    inset: calc(-1 * var(--edwinos-search-sample-padding, 29px));
    border-radius: 0;
    clip-path: inset(
        var(--edwinos-search-sample-padding, 29px)
        round var(--edwinos-search-form-radius, 23px)
    );
    backdrop-filter: blur(var(--edwinos-search-glass-blur)) url(#edwinos-search-refraction) saturate(1.16);
}

.md-header .edwinos-search-shell .edwinos-search-glass--highlight {
    z-index: 1;
    border: 1px solid var(--edwinos-search-glass-border);
    box-shadow:
        inset 0 1px 0 var(--edwinos-search-glass-highlight),
        inset 0 -1px 0 rgba(31, 35, 40, 0.04);
}

[data-md-color-scheme="default"] .md-header .md-search__overlay {
    background: rgba(246, 248, 250, 0.08) !important;
}

[data-md-color-scheme="slate"] .md-header .md-search__overlay {
    background: rgba(1, 4, 9, 0.08) !important;
}

[data-md-toggle="search"]:checked ~ .md-header .md-search__overlay {
    position: fixed !important;
    inset: 0 !important;
    width: auto !important;
    height: auto !important;
}

/* Passive layout/font measurements must settle directly. Only an explicit
   search interaction animates the shared resting/expanded coordinates; the
   runtime keeps this state through the entire closing transition. */
.md-header .md-search {
    transition: none !important;
}

html.edwinos-search-transitioning .md-header .md-search {
    transition:
        left 420ms cubic-bezier(0.42, 0, 0.58, 1),
        right 420ms cubic-bezier(0.42, 0, 0.58, 1),
        top 420ms cubic-bezier(0.42, 0, 0.58, 1),
        height 420ms cubic-bezier(0.42, 0, 0.58, 1),
        opacity 180ms ease !important;
}

/* Keep covered controls beneath the glass until the capsule finishes closing. */
@media (prefers-reduced-motion: no-preference) {
    html.edwinos-search-transitioning .md-header .md-search {
        z-index: 30 !important;
    }
}

@media screen {
    [data-md-toggle="search"]:checked ~ .md-header .md-search {
        --edwinos-search-height: 48px;
        right: var(--edwinos-header-search-open-right, 2px) !important;
        left: var(--edwinos-header-edge) !important;
        z-index: 30 !important;
        display: block !important;
        width: auto !important;
        max-width: none !important;
        height: var(--edwinos-search-height) !important;
        margin: 0 !important;
        padding: 1px 0 !important;
        overflow: visible !important;
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
    }

    [data-md-toggle="search"]:checked ~ .md-header .md-search__inner {
        position: relative !important;
        inset: auto !important;
        width: 100% !important;
        height: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        opacity: 1 !important;
        transform: none !important;
    }

    [data-md-toggle="search"]:checked ~ .md-header .md-search__input {
        width: 100% !important;
        height: 100% !important;
        min-height: 0 !important;
        line-height: normal !important;
        transition:
            color 140ms ease,
            opacity 110ms ease !important;
    }

}

/* Results share the shell's material; content layers remain transparent. */
.md-header .md-search__output {
    position: absolute !important;
    top: var(--edwinos-search-input-height, 46px) !important;
    right: 1px !important;
    bottom: auto !important;
    left: 1px !important;
    z-index: 3 !important;
    box-sizing: border-box !important;
    width: auto !important;
    height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 0 var(--edwinos-search-form-radius, 23px) var(--edwinos-search-form-radius, 23px) !important;
    box-shadow: none !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    overflow: hidden !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: none !important;
    transition:
        height 420ms cubic-bezier(0.42, 0, 0.58, 1),
        opacity 160ms ease,
        visibility 0s linear 420ms !important;
}

.md-header .md-search__output[hidden] {
    display: none !important;
}

.md-header .md-search__scrollwrap {
    box-sizing: border-box !important;
    width: 100% !important;
    height: 100% !important;
    max-height: none !important;
    padding: 0 9px 12px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: var(--edwinos-search-scrollbar-thumb) transparent;
    background: transparent !important;
    background-image: none !important;
    box-shadow: none !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
}

.md-header .md-search__scrollwrap::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.md-header .md-search__scrollwrap::-webkit-scrollbar-track {
    background: transparent;
}

.md-header .md-search__scrollwrap::-webkit-scrollbar-thumb {
    background: var(--edwinos-search-scrollbar-thumb);
    border-radius: 999px;
}

.md-header .md-search__scrollwrap::-webkit-scrollbar-thumb:hover {
    background: var(--edwinos-search-scrollbar-hover);
}

[data-md-toggle="search"]:checked
~ .md-header
.md-search.edwinos-search-has-query
.md-search__output {
    height: var(--edwinos-search-results-height) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transition-delay: 0s !important;
}

[data-md-toggle="search"]:checked ~ .md-header .md-search__inner {
    overflow: visible !important;
}

/* A contracted input can exceed the capsule's padding box. Clip without a
   scroll container so focus cannot leave the resting icon shifted sideways. */
@media screen and (max-width: 59.984375em) {
    [data-md-toggle="search"]:not(:checked) ~ .md-header .md-search__inner {
        overflow: clip !important;
    }
}

.md-header .md-search-result {
    width: 100% !important;
    color: var(--edwinos-search-result-color);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif !important;
}

.md-header .md-search-result__meta {
    position: relative;
    padding: 13px 12px 7px !important;
    background: transparent !important;
    color: var(--edwinos-search-result-muted) !important;
    font-family: inherit !important;
    font-size: 12px !important;
    font-weight: 400;
    line-height: 1.5 !important;
}

.md-header .md-search-result__meta::before {
    position: absolute;
    top: 0;
    right: 12px;
    left: 12px;
    height: 1px;
    background: var(--edwinos-search-glass-border);
    content: "";
}

.md-header .md-search-result__list {
    margin: 0 !important;
    padding: 0 !important;
}

.md-header .md-search-result__item {
    margin: 0 0 5px !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

.md-header .md-search-result__link,
.md-header .md-search-result__more > summary {
    border-radius: 13px;
    background: transparent !important;
    transition: background-color 130ms ease !important;
}

.md-header .md-search-result__link:is(:hover, :focus),
.md-header .md-search-result__more > summary:is(:hover, :focus) {
    background: var(--edwinos-search-result-hover) !important;
}

.md-header .md-search-result__link:focus-visible,
.md-header .md-search-result__more > summary:focus-visible {
    outline: 1px solid var(--edwinos-search-glass-border);
    outline-offset: -1px;
}

.md-header .md-search-result__article {
    padding: 10px 12px !important;
}

.md-header .md-search-result__icon {
    display: none !important;
}

.md-header .md-search-result__article .md-tags {
    margin: 0 !important;
}

.md-header .md-search-result__article .md-tags:empty {
    display: none !important;
}

.md-header .md-search-result .md-typeset {
    font-family: inherit !important;
    font-size: 13.5px !important;
    font-weight: 400 !important;
    line-height: 20px !important;
    color: var(--edwinos-search-result-muted) !important;
}

.md-header .md-search-result .md-typeset :is(h1, h2, p) {
    font-family: inherit !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
    border: 0 !important;
    box-shadow: none !important;
}

.md-header .md-search-result .md-typeset h1 {
    margin: 1px 0 !important;
    padding: 0 !important;
    color: var(--edwinos-search-result-muted) !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    line-height: 1.4 !important;
}

.md-header .md-search-result .md-typeset h2 {
    margin: 0 0 5px !important;
    padding: 0 !important;
    color: var(--edwinos-search-result-color) !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    line-height: 1.4 !important;
}

.md-header .md-search-result .edwinos-search-provenance {
    color: var(--edwinos-search-result-muted) !important;
    font-family: inherit !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    line-height: 1.4 !important;
}

.md-header .md-search-result__link[hidden] {
    display: none !important;
}

.md-header .md-search-result .md-typeset p {
    margin: 0 !important;
    padding: 0 !important;
    color: var(--edwinos-search-result-muted) !important;
    font-size: 13.5px !important;
    font-weight: 400 !important;
    line-height: 20px !important;
    overflow-wrap: anywhere;
}

.md-header .md-search-result .md-typeset mark {
    --edwinos-search-match-fill: var(--edwinos-search-match-tint);
    padding: 0;
    border-radius: 0;
    background: var(--edwinos-search-match-fill) !important;
    color: inherit !important;
    font-style: inherit;
    font-weight: inherit;
    box-shadow: inset 0 2px 4px -2px var(--edwinos-search-match-glow);
    text-decoration: none !important;
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
}

.md-header .md-search-result .arithmatex {
    display: inline-block;
    max-width: 100%;
    vertical-align: middle;
    overflow-x: auto;
    overflow-y: hidden;
}

.md-header .md-search-result .md-typeset code {
    color: inherit;
    font-size: 0.92em;
    padding: 0 0.2em;
    border-radius: 4px;
    background: rgba(120, 128, 140, 0.12);
    white-space: normal;
    overflow-wrap: anywhere;
}

.md-header .md-search-result__more,
.md-header .md-search-result__more[open] > summary,
.md-header .md-search-result__more > summary > div {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}

.md-header .md-search-result__more > summary > div {
    padding: 8px 12px !important;
    color: var(--edwinos-search-result-muted) !important;
    font-family: inherit !important;
    font-size: 12px !important;
}

@media (prefers-reduced-motion: reduce) {
    .md-header .edwinos-search-shell,
    .md-header .edwinos-search-glass--surface,
    .md-header .md-search__output,
    .md-header .md-search-result__link,
    .md-header .md-search-result__more > summary {
        transition: none !important;
    }
}

/*
 * Header controls share one coordinate system and collapse in two ordered
 * stages. The search capsule contracts to a circle first, then the GitHub
 * icon wipes a stationary repository label as the remaining space contracts.
 */
:root {
    --edwinos-header-edge: clamp(8px, 2vw, 32px);
    --edwinos-header-right-edge: 12px;
    --edwinos-mobile-header-height: 3.5rem;
    --edwinos-header-height: var(
        --edwinos-mobile-header-height,
        var(--compact-header-height, 3.5rem)
    );
    --edwinos-header-control-size: 44px;
    --edwinos-header-control-gap: 4px;
    --edwinos-header-tabs-search-gap: clamp(
        2px,
        calc((100vw - 360px) / 20),
        4px
    );
    --edwinos-header-source-icon-size: 28px;
    --edwinos-header-source-icon-inset: calc(
        (
            var(--edwinos-header-control-size)
            - var(--edwinos-header-source-icon-size)
        )
        / 2
    );
    --edwinos-header-search-source-gap: clamp(
        10px,
        calc(3.75vw - 5.75px),
        16px
    );
    --edwinos-header-tabs-left: calc(
        var(--edwinos-header-edge)
        + var(--edwinos-mobile-drawer-space, 0px)
    );
    /* First-paint fallback for the current tabs; runtime uses their real width. */
    --edwinos-header-tabs-width: 254px;
    --edwinos-header-search-left: calc(
        var(--edwinos-header-tabs-left)
        + var(--edwinos-header-tabs-width)
        + var(--edwinos-header-tabs-search-gap)
    );
    --edwinos-header-source-max-width: 138.4px;
    --edwinos-header-source-right: calc(
        var(--edwinos-header-right-edge)
        + var(--edwinos-header-control-size)
        + var(--edwinos-header-control-gap)
    );
    --edwinos-header-compression-budget: calc(
        100%
        - var(--edwinos-header-search-left)
        - var(--edwinos-header-source-right)
        + var(--edwinos-header-source-icon-inset)
        - var(--edwinos-header-search-source-gap)
    );
    --edwinos-header-source-width: clamp(
        var(--edwinos-header-control-size),
        calc(
            var(--edwinos-header-compression-budget)
            - var(--edwinos-header-control-size)
        ),
        var(--edwinos-header-source-max-width)
    );
    --edwinos-header-search-width: max(
        var(--edwinos-header-control-size),
        calc(
            var(--edwinos-header-compression-budget)
            - var(--edwinos-header-source-width)
        )
    );
    --edwinos-header-search-right: calc(
        var(--edwinos-header-source-right)
        + var(--edwinos-header-source-width)
        - var(--edwinos-header-source-icon-inset)
        + var(--edwinos-header-search-source-gap)
    );
    --edwinos-header-search-rest-left: calc(
        100%
        - var(--edwinos-header-search-right)
        - var(--edwinos-header-search-width)
    );
}

/* Keep one header layout model across Material's 76.25em desktop breakpoint.
   The legacy layer switches fixed/grid to sticky/flex at that boundary, which
   forces a full header reflow while the browser window is being resized. */
.md-header {
    position: sticky !important;
    top: 0 !important;
    right: auto !important;
    left: auto !important;
    z-index: 20 !important;
    width: 100% !important;
    min-height: var(--edwinos-header-height) !important;
    height: var(--edwinos-header-height) !important;
    overflow: visible !important;
    transform: none !important;
    transition: none !important;
}

.md-header__inner {
    position: relative !important;
    display: flex !important;
    width: 100% !important;
    max-width: none !important;
    height: var(--edwinos-header-height) !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 0 !important;
    grid-template-columns: none !important;
    grid-template-rows: none !important;
    column-gap: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    transform: none !important;
    transition: none !important;
}

.md-header .md-tabs,
.md-header .md-tabs[data-md-state="hidden"],
.md-header .md-tabs[data-md-state="lock"] {
    position: absolute !important;
    top: 0 !important;
    right: calc(
        var(--edwinos-header-search-right)
        + var(--edwinos-header-control-size)
        + var(--edwinos-header-tabs-search-gap)
    ) !important;
    bottom: auto !important;
    left: var(--edwinos-header-tabs-left) !important;
    z-index: 21 !important;
    display: flex !important;
    width: auto !important;
    height: var(--edwinos-header-height) !important;
    min-height: var(--edwinos-header-height) !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    overflow: hidden !important;
    transform: none !important;
    transition: none !important;
    opacity: 1 !important;
    visibility: visible !important;
}

[data-md-color-scheme] .md-header .md-tabs,
[data-md-color-scheme] .md-header .md-tabs[data-md-state="hidden"],
[data-md-color-scheme] .md-header .md-tabs[data-md-state="lock"] {
    background: transparent !important;
}

.md-header .md-tabs .md-grid {
    display: flex !important;
    width: 100% !important;
    max-width: none !important;
    height: 100% !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    scrollbar-width: none;
}

.md-header .md-tabs .md-grid::-webkit-scrollbar {
    display: none;
}

.md-container {
    padding-top: 0 !important;
}

.md-header .md-search,
.md-header .md-header__source,
.md-header .md-header__option {
    animation: none !important;
    will-change: auto !important;
}

.md-header .md-search,
.md-header .md-search__inner,
.md-header .md-header__button[for="__search"] {
    background: transparent !important;
}

.md-tabs__list {
    flex: 0 0 max-content !important;
    min-width: max-content !important;
    justify-content: flex-start !important;
}

.md-tabs__link {
    font-family: "Inter", "Noto Sans SC", sans-serif !important;
    transition:
        color 160ms ease,
        background-color 160ms ease,
        transform 160ms ease !important;
}

.md-header .md-tabs__link--active,
.md-header .md-tabs__item--active .md-tabs__link {
    position: relative;
    z-index: 0;
}

/* Progressive fallback when scripting is unavailable. Once the template
   measures the persistent glass, links no longer paint a selected surface. */
body:not(.is-home-profile-page)[data-md-color-scheme="default"]
.md-header:not([data-edwinos-tab-glass-ready="1"]) .md-tabs__item--active .md-tabs__link {
    background: rgba(31, 35, 40, 0.1) !important;
}

body:not(.is-home-profile-page)[data-md-color-scheme="slate"]
.md-header:not([data-edwinos-tab-glass-ready="1"]) .md-tabs__item--active .md-tabs__link {
    background: rgba(240, 246, 252, 0.12) !important;
}

/* One persistent selected glass survives Material's tabs replacement. It
   samples the actual tab glyphs with a continuous UV lens field.
   The center has neither blur nor tint, keeping resting labels crisp. The
   later control rail shares z22 and therefore still paints above this track. */
.md-header .edwinos-tab-glass-track {
    position: absolute;
    z-index: 22;
    overflow: hidden;
    visibility: hidden;
    pointer-events: none;
}

.md-header[data-edwinos-tab-glass-ready="1"] .edwinos-tab-glass-track {
    visibility: visible;
}

.md-header .edwinos-tab-glass {
    position: absolute;
    display: block;
    box-sizing: border-box;
    border: 1px solid rgba(70, 76, 86, 0.14);
    border-radius: 999px;
    background: transparent;
    -webkit-backdrop-filter: blur(0px);
    backdrop-filter: blur(0px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5),
        inset 0 -1px 0 rgba(78, 85, 95, 0.09);
    pointer-events: none;
}

.md-header .edwinos-tab-glass[hidden] {
    display: none;
}

.md-header .edwinos-tab-refraction {
    -webkit-backdrop-filter: url(#edwinos-tab-refraction);
    backdrop-filter: url(#edwinos-tab-refraction);
}

[data-md-color-scheme="slate"] .md-header .edwinos-tab-glass {
    border-color: rgba(210, 220, 232, 0.16);
    background: transparent;
    box-shadow: inset 0 1px 0 rgba(235, 242, 255, 0.2),
        inset 0 -1px 0 rgba(0, 0, 0, 0.18);
}

.md-header .edwinos-tab-glass__highlight {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(125deg, rgba(255, 255, 255, 0.16), transparent 28%,
        transparent 70%, rgba(255, 255, 255, 0.1));
    pointer-events: none;
}

/* Safari uses one narrow SVG label source with disjoint optical clips. Keep
   the real links in layout/accessibility, and hide only their glyph paint once
   that source is ready; color remains readable by the source/palette owner. */
.md-header .edwinos-tab-label-optics {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.md-header[data-edwinos-tab-label-ready="1"] .md-tabs__link {
    -webkit-text-fill-color: transparent !important;
}

.md-header[data-edwinos-tab-glass-ready="1"] .md-tabs__link,
.md-header[data-edwinos-tab-glass-ready="1"] .md-tabs__link:hover {
    background: transparent !important;
    transform: none !important;
}

.md-header[data-edwinos-tab-glass-ready="1"] .md-tabs__link::after {
    display: none !important;
}

[data-md-color-scheme="default"] .md-header .md-tabs__link--active,
[data-md-color-scheme="default"]
.md-header
.md-tabs__item--active
.md-tabs__link {
    color: #1f2328 !important;
    background: transparent !important;
    font-weight: 600 !important;
}

[data-md-color-scheme="slate"] .md-header .md-tabs__link--active,
[data-md-color-scheme="slate"]
.md-header
.md-tabs__item--active
.md-tabs__link {
    color: #f0f6fc !important;
    background: transparent !important;
    font-weight: 600 !important;
}

.md-header .md-header__option {
    position: absolute !important;
    top: calc(
        (
            var(--edwinos-header-height)
            - var(--edwinos-header-control-size)
        )
        / 2
    ) !important;
    right: var(--edwinos-header-right-edge) !important;
    z-index: 28 !important;
    display: inline-flex !important;
    width: var(--edwinos-header-control-size) !important;
    min-width: var(--edwinos-header-control-size) !important;
    max-width: var(--edwinos-header-control-size) !important;
    height: var(--edwinos-header-control-size) !important;
    margin: 0 !important;
    padding: 0 !important;
    transform: none !important;
    opacity: 1 !important;
}

.md-header .md-header__option .md-header__button {
    width: var(--edwinos-header-control-size) !important;
    min-width: var(--edwinos-header-control-size) !important;
    max-width: var(--edwinos-header-control-size) !important;
    height: var(--edwinos-header-control-size) !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
}

.md-header .md-header__source {
    position: absolute !important;
    top: calc(
        (
            var(--edwinos-header-height)
            - var(--edwinos-header-control-size)
        )
        / 2
    ) !important;
    right: var(--edwinos-header-source-right) !important;
    z-index: 26 !important;
    display: block !important;
    width: var(--edwinos-header-source-width) !important;
    min-width: var(--edwinos-header-control-size) !important;
    max-width: var(--edwinos-header-source-width) !important;
    height: var(--edwinos-header-control-size) !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transition:
        background-color 160ms ease !important;
}

.md-header .md-source {
    position: relative !important;
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    min-height: var(--edwinos-header-control-size) !important;
    height: var(--edwinos-header-control-size) !important;
    margin: 0 !important;
    padding: 0 !important;
    align-items: normal !important;
    gap: 0 !important;
    grid-template-columns: none !important;
    overflow: hidden !important;
    border-radius: 999px !important;
    transform: none !important;
    pointer-events: auto !important;
    transition:
        background-color 160ms ease !important;
}

[data-md-color-scheme="default"] .md-header .md-source__icon {
    background: var(--github-frame-light-bg, #f6f8fa) !important;
}

[data-md-color-scheme="slate"] .md-header .md-source__icon {
    background: var(--github-frame-dark-bg, #0d1117) !important;
}

.md-header .md-source__icon {
    position: absolute !important;
    top: -1px !important;
    left: -1px !important;
    z-index: 3 !important;
    display: inline-flex !important;
    width: calc(var(--edwinos-header-control-size) + 2px) !important;
    min-width: calc(var(--edwinos-header-control-size) + 2px) !important;
    height: calc(var(--edwinos-header-control-size) + 2px) !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    overflow: visible !important;
    border-radius: 50% !important;
    transform: none !important;
    transition: none !important;
}

.md-header .md-source__icon svg {
    display: block !important;
    width: var(--edwinos-header-source-icon-size) !important;
    height: var(--edwinos-header-source-icon-size) !important;
    margin: 0 !important;
    overflow: visible !important;
    transform: none !important;
    transform-origin: center center !important;
}

.md-header .md-source__repository {
    position: absolute !important;
    top: 7px !important;
    right: 3px !important;
    left: auto !important;
    z-index: 1 !important;
    display: block !important;
    width: calc(
        var(--edwinos-header-source-max-width)
        - var(--edwinos-header-control-size)
        - 6px
    ) !important;
    min-width: 0 !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    color: currentColor !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    line-height: 1.08 !important;
    text-align: right !important;
    white-space: nowrap !important;
    text-overflow: clip !important;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transition: none !important;
}

.md-header .md-source__facts {
    display: flex !important;
    min-height: 14.4px !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 11.2px !important;
    margin-top: 2.4px !important;
    overflow: hidden !important;
    font-family:
        "JetBrains Mono",
        ui-monospace,
        SFMono-Regular,
        Menlo,
        monospace !important;
    font-size: 11px !important;
    line-height: 11px !important;
    opacity: 0.78 !important;
    animation: none !important;
    transition: none !important;
}

.md-header .md-source__fact {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4.4px !important;
    line-height: 11px !important;
    animation: none !important;
    transition: none !important;
}

.md-header .md-source__fact::before {
    display: inline-block !important;
    width: 14.4px !important;
    height: 14.4px !important;
    flex: 0 0 14.4px !important;
    content: "" !important;
    background-color: currentColor !important;
    border: 0 !important;
    -webkit-mask: var(--edwinos-star-icon) center / contain no-repeat !important;
    mask: var(--edwinos-star-icon) center / contain no-repeat !important;
    transform: translateY(-0.5px);
    transition: none !important;
}

.md-header .md-source__fact[data-source-fact="forks"]::before,
.md-header .md-source__fact--forks::before,
.md-header .md-source__fact:nth-child(2)::before {
    -webkit-mask-image: var(--edwinos-fork-icon) !important;
    mask-image: var(--edwinos-fork-icon) !important;
}

/* Covered header controls remain visually static behind the expanding search
   capsule. Disable interaction so clicks cannot pass through to navigation. */
[data-md-toggle="search"]:checked ~ .md-header .md-tabs,
[data-md-toggle="search"]:checked ~ .md-header .md-header__source,
[data-md-toggle="search"]:checked ~ .md-header .md-header__option {
    pointer-events: none !important;
}

@media screen and (min-width: 76.25em) {
    .md-tabs__list {
        gap: 4px !important;
    }

    .md-tabs__link {
        height: 42px !important;
        min-height: 42px !important;
        padding: 0 11px !important;
        font-size: 17.2px !important;
    }
}

@media screen {
    .md-header .md-search {
        --edwinos-search-height: var(--edwinos-header-control-size);
        position: absolute !important;
        top: calc(
            (
                var(--edwinos-header-height)
                - var(--edwinos-search-height)
            )
            / 2
        ) !important;
        right: var(--edwinos-header-search-right) !important;
        left: var(--edwinos-header-search-rest-left) !important;
        z-index: 27 !important;
        display: block !important;
        box-sizing: border-box !important;
        width: auto !important;
        min-width: var(--edwinos-header-control-size) !important;
        max-width: none !important;
        height: var(--edwinos-search-height) !important;
        margin: 0 !important;
        padding: 1px 0 !important;
        overflow: visible !important;
        container: edwinos-header-search / inline-size;
        transform: none !important;
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
    }

    .md-header .md-search__inner,
    .md-header .md-search__form {
        position: relative !important;
        inset: auto !important;
        box-sizing: border-box !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        height: 100% !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        transform: none !important;
        opacity: 1 !important;
    }

    .md-header .md-search__form {
        display: flex !important;
        width: calc(100% - 2px) !important;
        align-items: center !important;
        margin-inline: auto !important;
    }

    .md-header .md-search__input {
        box-sizing: border-box !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 1rem 0 46px !important;
        font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif !important;
        font-size: 16px !important;
        font-weight: 400 !important;
        letter-spacing: 0 !important;
        white-space: nowrap !important;
        text-overflow: clip !important;
        opacity: 1 !important;
        -webkit-appearance: none !important;
        appearance: none !important;
        transition: color 140ms ease, opacity 110ms ease !important;
    }

    .md-header .md-header__button[for="__search"] {
        display: none !important;
    }

    .md-header .md-search__form .md-search__icon[for="__search"] {
        top: 50% !important;
        left: min(14px, calc(50% - 9.5px)) !important;
        z-index: 3 !important;
        display: inline-flex !important;
        width: 19px !important;
        height: 19px !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
        padding: 0 !important;
        transform: translateY(-50%) !important;
        transform-origin: center center !important;
        transition: none !important;
    }

    .md-header .md-search__form .md-search__icon[for="__search"] svg {
        display: block !important;
        width: 100% !important;
        height: 100% !important;
    }

    .md-header .md-search__form .md-search__icon[for="__search"] svg:nth-of-type(2) {
        display: none !important;
    }
}

@media screen and (max-width: 76.1875em) {
    .md-tabs {
        right: calc(
            var(--edwinos-header-search-right)
            + var(--edwinos-header-control-size)
            + var(--edwinos-header-tabs-search-gap)
        ) !important;
    }
}

@container edwinos-header-search (max-width: 6.75rem) {
    .md-header .md-search__input {
        opacity: 0 !important;
        cursor: pointer !important;
    }

}

@media screen and (max-width: 34rem) {
    :root {
        --edwinos-header-edge: max(5px, 2vw);
        --edwinos-header-control-size: 44px;
        --edwinos-header-tabs-left: calc(
            max(7px, 2vw)
            + var(--edwinos-mobile-drawer-space)
        );
    }

    .md-header .md-header__source,
    .md-header .md-header__option,
    .md-header .md-header__button[for="__search"] {
        top: calc(
            (
                var(
                    --edwinos-mobile-header-height,
                    var(--compact-header-height, 3.5rem)
                )
                - var(--edwinos-header-control-size)
            )
            / 2
        ) !important;
    }

    .md-header .md-header__option .md-header__button,
    .md-header .md-header__button[for="__search"] {
        width: var(--edwinos-header-control-size) !important;
        min-width: var(--edwinos-header-control-size) !important;
        max-width: var(--edwinos-header-control-size) !important;
        height: var(--edwinos-header-control-size) !important;
    }

    .md-header .md-source {
        min-height: var(--edwinos-header-control-size) !important;
        height: var(--edwinos-header-control-size) !important;
    }

    .md-header .md-source__icon {
        width: calc(var(--edwinos-header-control-size) + 2px) !important;
        min-width: calc(var(--edwinos-header-control-size) + 2px) !important;
        height: calc(var(--edwinos-header-control-size) + 2px) !important;
    }

    .md-header .md-source__icon svg {
        width: var(--edwinos-header-source-icon-size) !important;
        min-width: var(--edwinos-header-source-icon-size) !important;
        height: var(--edwinos-header-source-icon-size) !important;
    }

    .md-tabs {
        left: calc(
            max(7px, 2vw)
            + var(--edwinos-mobile-drawer-space)
        ) !important;
        right: calc(
            var(--edwinos-header-search-right)
            + var(--edwinos-header-control-size)
            + var(--edwinos-header-tabs-search-gap)
        ) !important;
    }

    .md-tabs .md-tabs__list {
        gap: 4px !important;
    }

    .md-tabs .md-tabs__link {
        padding-inline: 11px !important;
        font-size: 17.2px !important;
    }

    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"]),
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]) {
        --edwinos-mobile-drawer-control-size: clamp(
            26px,
            calc(8.036vw + 0.286px),
            44px
        );
        --edwinos-mobile-drawer-space: calc(
            var(--edwinos-mobile-drawer-control-size)
            + 8px
        );
    }
}

/* Preserve the full navigation rhythm until the search has naturally reached
   its circular endpoint. Afterward, consume only surplus button spacing. */
@media screen and (max-width: 32.875rem) {
    :root {
        --edwinos-header-search-width: var(--edwinos-header-control-size);
    }

    [data-md-toggle="search"]:not(:checked)
    ~ .md-header
    .md-search__input {
        opacity: 0 !important;
        cursor: pointer !important;
    }

    .md-tabs .md-tabs__link {
        padding-inline: clamp(
            1.5px,
            calc((100vw - 460px) / 6),
            11px
        ) !important;
    }
}

@media screen and (min-width: 34.0625rem) and (max-width: 36rem) {
    :root {
        --edwinos-header-tabs-left: clamp(
            10.88px,
            calc(1.74vw + 1.5px),
            11.52px
        );
    }

    .md-tabs {
        left: clamp(
            10.88px,
            calc(1.74vw + 1.5px),
            11.52px
        ) !important;
    }

    .md-tabs .md-tabs__list {
        gap: 4px !important;
    }

    .md-tabs .md-tabs__link {
        padding-inline: 11px !important;
        font-size: 17.2px !important;
    }

    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
    .md-tabs,
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
    .md-tabs {
        left: calc(max(10px, 2vw) + 52px) !important;
    }

    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"]),
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]) {
        --edwinos-header-tabs-left: calc(max(10px, 2vw) + 52px);
    }
}

@media screen and (max-width: 40rem) {
    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
    .md-tabs .md-grid,
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
    .md-tabs .md-grid {
        overflow-x: auto !important;
        overflow-y: hidden !important;
        overscroll-behavior-inline: contain;
        -webkit-overflow-scrolling: touch;
    }

    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
    .md-tabs .md-tabs__list,
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
    .md-tabs .md-tabs__list {
        flex: 0 0 max-content !important;
        min-width: max-content !important;
    }
}

@media screen and (max-width: 22.5rem) {
    :root {
        --edwinos-header-control-size: clamp(
            34px,
            calc(25vw - 46px),
            44px
        );
        --edwinos-header-source-icon-size: clamp(
            24px,
            calc(10vw - 8px),
            28px
        );
    }
}

[data-md-toggle="search"]:checked
~ .md-header
.md-header__button[for="__search"] {
    transform: scale(0.88) !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transition: none !important;
}

.md-header .md-search__input {
    height: 100% !important;
    min-height: 0 !important;
    margin-block: 0 !important;
    padding-block: 0 !important;
    line-height: normal !important;
}

@media (prefers-reduced-motion: reduce) {
    .md-header .md-search,
    .md-header .md-search__input,
    [data-md-toggle="search"]:checked ~ .md-header .md-search__input,
    [data-md-toggle="search"]:checked
    ~ .md-header
    .md-search__form
    .md-search__icon[for="__search"] {
        transition: none !important;
    }
}

/* Navigation feedback: share the visible progress edge across all routes.
   Material keeps its real request lifecycle; this bar never supplies a fake
   completion percentage. Search keeps ownership of its expanded window. */
body .md-progress {
    top: calc(
        var(--edwinos-navigation-top, var(--edwinos-header-height, 3.5rem))
        - 0.15rem
    ) !important;
    z-index: 10005 !important;
    height: 0.15rem !important;
    background: #58a6ff !important;
    box-shadow: 0 0 0.45rem rgba(88, 166, 255, 0.72);
}

.page-navigation-feedback {
    position: fixed;
    top: calc(var(--edwinos-navigation-top, var(--edwinos-header-height, 3.5rem)) + 0.5rem);
    left: 50%;
    z-index: 21;
    width: max-content;
    max-width: min(90vw, 30rem);
    padding: 0.55rem 0.85rem;
    border: 0;
    border-radius: 1.5rem;
    font: 400 0.72rem/1.5 var(--edwinos-font-reading-sans);
    transform: translateX(-50%);
}

/* Header: independent academic name, chapter rail and compact glass panel. */
.edwinos-academic-header .edwinos-tab-glass-track { z-index: 23; }
.edwinos-academic-header .md-header__inner {
    /* Match the centered 80rem homepage shell on ultrawide viewports. */
    padding-inline: max(var(--edwinos-header-edge), calc((100% - 80rem) / 2)) max(12px, calc((100% - 80rem) / 2)) !important;
    gap: 20px !important;
    justify-content: space-between !important;
}
[data-md-color-scheme="default"] .edwinos-academic-header :is(.academic-header-name,.academic-header-github,.academic-header-menu) { color: #1f2328 !important; }
[data-md-color-scheme="slate"] .edwinos-academic-header :is(.academic-header-name,.academic-header-github,.academic-header-menu) { color: #f0f6fc !important; }
.edwinos-academic-header .academic-header-name {
    -webkit-user-select: none;
    user-select: none;
    cursor: default;
    position: relative; z-index: 24; flex: 0 0 auto;
    font-family: var(--edwinos-font-reading-sans); font-size: 14.5px;
    font-weight: 500; white-space: nowrap; color: inherit;
}
.edwinos-academic-header .academic-header-panel { flex: 1 1 auto; min-width: 0; height: 100%; position: relative; }
.edwinos-academic-header .academic-header-panel-surface { display: none; }
.edwinos-academic-header .academic-menu-selection-track { display: none; }
.edwinos-academic-header .md-tabs,
.edwinos-academic-header .md-tabs[data-md-state] {
    position: relative !important; inset: auto !important; width: 100% !important;
    height: 100% !important; min-height: 0 !important;
}
.edwinos-academic-header .md-tabs .md-grid { justify-content: flex-end !important; }
.edwinos-academic-header .md-tabs__list { gap: 2px !important; margin: 0 !important; padding: 0 !important; }
.edwinos-academic-header .md-tabs__item { height: auto !important; padding: 0 !important; }
.edwinos-academic-header .md-tabs__link {
    display: flex !important; align-items: center; height: 34px !important;
    margin: 0 !important; padding: 0 12px !important; opacity: 1 !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 13px !important; font-weight: 400 !important; line-height: 1 !important;
    white-space: nowrap;
}
.edwinos-academic-header .academic-header-controls { display: flex; align-items: center; gap: 4px; flex: 0 0 auto; position: relative; z-index: 28; }
.edwinos-academic-header .academic-header-github,
.edwinos-academic-header .academic-header-menu {
    width: var(--edwinos-header-control-size); height: var(--edwinos-header-control-size);
    display: inline-flex; align-items: center; justify-content: center;
    color: inherit; border-radius: 50%; cursor: pointer;
}
.edwinos-academic-header .academic-header-github svg { width: 25px; height: 25px; }
.edwinos-academic-header .academic-header-menu svg { width: 24px; height: 24px; }
.edwinos-academic-header .academic-header-menu { display: none; }
.edwinos-academic-header .academic-header-controls .md-header__option { position: relative !important; top: auto !important; right: auto !important; }
.edwinos-academic-header :is(.academic-header-name,.academic-header-menu,.academic-header-github,.md-tabs__link):focus-visible { outline: 2px solid var(--md-accent-fg-color); outline-offset: 3px; }
.edwinos-academic-header[data-compact="true"] .md-header__inner { gap: 6px !important; }
.edwinos-academic-header[data-compact="true"] .academic-header-menu { display: inline-flex; }
.edwinos-academic-header[data-compact="true"] .academic-header-panel {
    position: absolute; top: calc(100% - 4px); left: 8px; right: 8px;
    height: 58px; padding: 10px 8px; border-radius: 29px; z-index: 21;
    visibility: hidden; pointer-events: none;
    transform: translateY(var(--academic-menu-y, 0px));
}
.edwinos-academic-header[data-compact="true"] .edwinos-tab-glass-track {
    transform: translateY(var(--academic-menu-y, 0px));
}
.edwinos-academic-header[data-compact="true"] :is(.academic-header-panel-surface, .md-tabs) {
    opacity: var(--academic-menu-opacity, 1);
}
.edwinos-academic-header[data-compact="true"] .academic-menu-selection-track {
    display: block; position: absolute; inset: 10px 8px; z-index: 1;
    overflow: hidden; pointer-events: none; border-radius: 19px;
}
.edwinos-academic-header[data-compact="true"] .academic-menu-selection {
    display: block; position: absolute; border-radius: 999px;
    left: var(--academic-selection-x, 0px); top: var(--academic-selection-y, 0px);
    width: var(--academic-selection-width, 0px); height: var(--academic-selection-height, 36px);
    background: #e6e8eb;
    opacity: calc(var(--academic-menu-opacity, 1) * (1 - var(--academic-selection-glass, 0)));
}
[data-md-color-scheme="slate"] .edwinos-academic-header .academic-menu-selection { background: #30353c; }
.edwinos-academic-header[data-compact="true"] .md-tabs { z-index: 2; }
.edwinos-academic-header[data-compact="true"] .edwinos-tab-glass {
    opacity: calc(var(--academic-menu-opacity, 1) * var(--academic-selection-glass, 0));
}
.edwinos-academic-header[data-compact="true"] .md-tabs__link[aria-current="location"] { color: var(--md-default-fg-color) !important; }
.edwinos-academic-header[data-compact="true"]:not([data-menu-open="true"]) .academic-header-panel .md-tabs { visibility: hidden !important; pointer-events: none !important; }
.edwinos-academic-header[data-compact="true"][data-menu-open="true"] .academic-header-panel { visibility: visible; pointer-events: auto; }
.edwinos-academic-header[data-compact="true"] .academic-header-panel-surface {
    display: block; position: absolute; inset: 0; border-radius: inherit; z-index: 0;
    border: 1px solid rgba(100,110,125,.16); background: rgba(246,248,250,.5);
    box-shadow: 0 8px 24px rgba(31,35,40,.08), inset 0 1px 0 rgba(255,255,255,.45);
    -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
}
[data-md-color-scheme="slate"] .edwinos-academic-header .academic-header-panel-surface { background: rgba(22,27,34,.48); border-color: rgba(210,220,232,.16); }
.edwinos-academic-header .academic-header-panel-surface.edwinos-chapter-panel-refraction { backdrop-filter: url(#edwinos-chapter-panel-refraction); }
.edwinos-academic-header[data-compact="true"] .md-tabs .md-grid { justify-content: flex-start !important; overscroll-behavior-inline: contain; touch-action: pan-x; }
.edwinos-academic-header[data-compact="true"] .md-tabs__link { height: 36px !important; }
.edwinos-academic-header[data-compact="true"]:not([data-menu-open="true"]) .edwinos-tab-glass-track { visibility: hidden; }

/* The toast samples the page directly, with the lighter Back to Top tuning.
   Its filter and displacement geometry are independent of the other controls. */
.page-navigation-feedback.edwinos-navigation-glass {
    --edwinos-navigation-tint: rgba(246, 248, 250, 0.2);
    --edwinos-navigation-border: rgba(60, 60, 67, 0.2);
    --edwinos-navigation-highlight: rgba(255, 255, 255, 0.65);
    --edwinos-navigation-shadow: 0 3px 14px rgba(31, 35, 40, 0.13);
    overflow: visible;
    background: var(--edwinos-navigation-tint);
    -webkit-backdrop-filter: blur(4px) saturate(1.12);
    backdrop-filter: blur(4px) saturate(1.12);
    box-shadow: var(--edwinos-navigation-shadow);
    color: #303641;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.6);
}

[data-md-color-scheme="slate"] .page-navigation-feedback.edwinos-navigation-glass {
    --edwinos-navigation-tint: rgba(25, 29, 37, 0.26);
    --edwinos-navigation-border: rgba(240, 246, 252, 0.2);
    --edwinos-navigation-highlight: rgba(240, 246, 252, 0.24);
    --edwinos-navigation-shadow: 0 3px 14px rgba(1, 4, 9, 0.32);
    color: #dce2ea;
    text-shadow: 0 1px 2px rgba(1, 4, 9, 0.65);
}

.page-navigation-feedback.edwinos-navigation-refraction {
    backdrop-filter: url(#edwinos-navigation-refraction) saturate(1.12);
}

.page-navigation-feedback > .edwinos-navigation-glass__highlight {
    position: absolute;
    inset: 0;
    z-index: -1;
    display: block;
    box-sizing: border-box;
    border-radius: inherit;
    border: 1px solid var(--edwinos-navigation-border);
    box-shadow:
        inset 0 1px 0 var(--edwinos-navigation-highlight),
        inset 0 -1px 0 rgba(31, 35, 40, 0.07);
    pointer-events: none;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .page-navigation-feedback.edwinos-navigation-glass {
        --edwinos-navigation-tint: rgba(246, 248, 250, 0.94);
    }

    [data-md-color-scheme="slate"] .page-navigation-feedback.edwinos-navigation-glass {
        --edwinos-navigation-tint: rgba(25, 29, 37, 0.94);
    }
}

.page-navigation-feedback[hidden],
.page-navigation-feedback__recovery[hidden] {
    display: none;
}

.page-navigation-feedback__message {
    display: block;
    margin: 0;
    overflow-wrap: anywhere;
}

.page-navigation-feedback__recovery {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.55rem;
}

.page-navigation-feedback__recovery button {
    padding: 0.25rem 0.55rem;
    border: 1px solid var(--md-default-fg-color--lighter);
    border-radius: 0.35rem;
    color: var(--md-primary-fg-color);
    background: transparent;
    font: inherit;
    cursor: pointer;
}

.page-navigation-feedback__recovery button:focus-visible {
    outline: 2px solid var(--md-accent-fg-color);
    outline-offset: 3px;
}

body:has([data-md-toggle="search"]:checked) .md-progress,
body:has([data-md-toggle="search"]:checked) .page-navigation-feedback {
    visibility: hidden !important;
}

@media screen and (max-width: 44.984375em) {
    .page-navigation-feedback {
        max-width: calc(100vw - 1.5rem);
        font-size: 0.68rem;
    }
}

/*
 * Progressive Header Glass
 *
 * Seven independently masked backdrop filters dissolve scrolling content into
 * the translucent notch. Subpixel/low-radius bridge layers and eased mask
 * endpoints soften the lower edge without extending into the reading area.
 * The 52px extension is one continuous field, not a second attached panel.
 */
.md-header.md-header {
    isolation: isolate !important;
    border: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
}

/* The legacy homepage selectors include both body state and color-scheme
   classes, so repeat the transparent shell at matching specificity here. */
body[data-md-color-scheme] .md-header.md-header {
    border: 0 !important;
    background: transparent !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
}

/* Retire the former core/tail pseudo-elements from both EdwinOS and legacy. */
.md-header.md-header::before,
.md-header.md-header::after {
    display: none !important;
    content: none !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
}

.md-header > .edwinos-header-glass {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    left: 0 !important;
    z-index: 0 !important;
    display: block !important;
    width: auto !important;
    height: calc(100% + 52px) !important;
    overflow: hidden !important;
    pointer-events: none !important;
}

.edwinos-header-glass__layer,
.edwinos-header-glass__fade {
    position: absolute !important;
    inset: 0 !important;
    display: block !important;
    border: 0 !important;
    background: transparent;
    box-shadow: none !important;
    pointer-events: none !important;
}

.edwinos-header-glass__layer {
    -webkit-mask-repeat: no-repeat !important;
    mask-repeat: no-repeat !important;
    -webkit-mask-size: 100% 100% !important;
    mask-size: 100% 100% !important;
}

/* Preserve the reference-shaped five layers; two low-alpha fields soften detail. */
.edwinos-header-glass__layer--1 {
    -webkit-mask-image: linear-gradient(to bottom, transparent 0% 44%, rgb(0 0 0 / 15%) 52%, rgb(0 0 0 / 40%) 60%, rgb(0 0 0 / 55%) 64%, rgb(0 0 0 / 35%) 68%, rgb(0 0 0 / 10%) 72%, transparent 74% 100%);
    mask-image: linear-gradient(to bottom, transparent 0% 44%, rgb(0 0 0 / 15%) 52%, rgb(0 0 0 / 40%) 60%, rgb(0 0 0 / 55%) 64%, rgb(0 0 0 / 35%) 68%, rgb(0 0 0 / 10%) 72%, transparent 74% 100%);
    -webkit-backdrop-filter: blur(1px);
    backdrop-filter: blur(1px);
}

.edwinos-header-glass__layer--2 {
    -webkit-mask-image: linear-gradient(to bottom, transparent 0 24%, #000 44% 56%, transparent 74% 100%);
    mask-image: linear-gradient(to bottom, transparent 0 24%, #000 44% 56%, transparent 74% 100%);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
}

.edwinos-header-glass__layer--3 {
    -webkit-mask-image: linear-gradient(to bottom, transparent 0% 24%, rgb(0 0 0 / 15%) 30%, rgb(0 0 0 / 35%) 38%, rgb(0 0 0 / 50%) 44%, rgb(0 0 0 / 35%) 50%, rgb(0 0 0 / 15%) 58%, transparent 66% 100%);
    mask-image: linear-gradient(to bottom, transparent 0% 24%, rgb(0 0 0 / 15%) 30%, rgb(0 0 0 / 35%) 38%, rgb(0 0 0 / 50%) 44%, rgb(0 0 0 / 35%) 50%, rgb(0 0 0 / 15%) 58%, transparent 66% 100%);
    -webkit-backdrop-filter: blur(4.5px);
    backdrop-filter: blur(4.5px);
}

.edwinos-header-glass__layer--4 {
    -webkit-mask-image: linear-gradient(to bottom, transparent 0 18%, #000 36% 52%, transparent 74% 100%);
    mask-image: linear-gradient(to bottom, transparent 0 18%, #000 36% 52%, transparent 74% 100%);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

.edwinos-header-glass__layer--5 {
    -webkit-mask-image: linear-gradient(to bottom, #000 0 28%, transparent 58% 100%);
    mask-image: linear-gradient(to bottom, #000 0 28%, transparent 58% 100%);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.edwinos-header-glass__layer--6 {
    -webkit-mask-image: linear-gradient(to bottom, #000 0 16%, transparent 42% 100%);
    mask-image: linear-gradient(to bottom, #000 0 16%, transparent 42% 100%);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
}

.edwinos-header-glass__layer--7 {
    -webkit-mask-image: linear-gradient(to bottom, #000 0%, transparent 22% 100%);
    mask-image: linear-gradient(to bottom, #000 0%, transparent 22% 100%);
    -webkit-backdrop-filter: blur(22px);
    backdrop-filter: blur(22px);
}

[data-md-color-scheme="default"] .edwinos-header-glass__fade {
    background: linear-gradient(
        to bottom,
        rgba(246, 248, 250, 0.9) 0%,
        rgba(246, 248, 250, 0.55) 28%,
        rgba(246, 248, 250, 0.18) 52%,
        rgba(246, 248, 250, 0.08) 62%,
        rgba(246, 248, 250, 0.015) 70%,
        transparent 74% 100%
    ) !important;
}

[data-md-color-scheme="slate"] .edwinos-header-glass__fade {
    background: linear-gradient(
        to bottom,
        rgba(13, 17, 23, 0.9) 0%,
        rgba(13, 17, 23, 0.55) 28%,
        rgba(13, 17, 23, 0.18) 52%,
        rgba(13, 17, 23, 0.08) 62%,
        rgba(13, 17, 23, 0.015) 70%,
        transparent 74% 100%
    ) !important;
}

/* Material keeps tabs as a separate header child. Lift the control rail above
   the glass and tabs, but let pointer events pass through its empty areas so
   the tab links beneath remain interactive. */
.md-header > .md-header__inner {
    z-index: 22 !important;
    pointer-events: none !important;
}

.md-header > .md-header__inner > * {
    pointer-events: auto !important;
}

/* Legacy gives the direct-child tabs a solid dark/light rectangle. Keep only
   each individual tab pill opaque and leave the tab rail itself transparent. */
body[data-md-color-scheme] .md-header > .md-tabs.md-tabs,
[data-md-color-scheme] .md-header > .md-tabs.md-tabs,
body[data-md-color-scheme] .md-header .md-tabs.md-tabs,
[data-md-color-scheme] .md-header .md-tabs.md-tabs {
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
}

/* Safari keeps a tapped link in :hover after Material's instant navigation.
   On touch screens that stale hover must not compete with the new active tab. */
@media (hover: none), (pointer: coarse) {
    [data-md-color-scheme="default"] .md-tabs__link:hover {
        color: #57606a !important;
        background: transparent !important;
        font-weight: 500 !important;
        transform: none !important;
    }

    [data-md-color-scheme="slate"] .md-tabs__link:hover {
        color: #8b949e !important;
        background: transparent !important;
        font-weight: 500 !important;
        transform: none !important;
    }

    [data-md-color-scheme="default"]
    .md-tabs__item--active
    .md-tabs__link {
        color: #1f2328 !important;
        background: transparent !important;
        font-weight: 600 !important;
    }

    [data-md-color-scheme="slate"]
    .md-tabs__item--active
    .md-tabs__link {
        color: #f0f6fc !important;
        background: transparent !important;
        font-weight: 600 !important;
    }
}

/* Friends and Archive live under Overview in Material's navigation tree, but
   they are separate destinations in EdwinOS. Keep Overview available as the
   way home without presenting it as the current page. The active capsule is
   painted by the persistent header glass, separately from the link text. */
body.is-home-profile-page[data-md-color-scheme="default"]
.md-tabs__item--active
.md-tabs__link,
body.is-home-profile-page[data-md-color-scheme="default"]
.md-tabs__link--active {
    color: #57606a !important;
    background: transparent !important;
    box-shadow: none !important;
    font-weight: 500 !important;
    transform: none !important;
}

body.is-home-profile-page[data-md-color-scheme="slate"]
.md-tabs__item--active
.md-tabs__link,
body.is-home-profile-page[data-md-color-scheme="slate"]
.md-tabs__link--active {
    color: #8b949e !important;
    background: transparent !important;
    box-shadow: none !important;
    font-weight: 500 !important;
    transform: none !important;
}

body.is-home-profile-page
.md-tabs__item--active
.md-tabs__link::after,
body.is-home-profile-page
.md-tabs__link--active::after {
    width: 0 !important;
}

@media (hover: hover) and (pointer: fine) {
    body.is-home-profile-page[data-md-color-scheme="default"]
    .md-tabs__item--active
    .md-tabs__link:hover,
    body.is-home-profile-page[data-md-color-scheme="default"]
    .md-tabs__link--active:hover {
        color: #1f2328 !important;
        background: rgba(31, 35, 40, 0.06) !important;
        transform: translateY(-1px) !important;
    }

    body.is-home-profile-page[data-md-color-scheme="slate"]
    .md-tabs__item--active
    .md-tabs__link:hover,
    body.is-home-profile-page[data-md-color-scheme="slate"]
    .md-tabs__link--active:hover {
        color: #c9d1d9 !important;
        background: rgba(240, 246, 252, 0.08) !important;
        transform: translateY(-1px) !important;
    }
}

/* Keep the complete mobile notch, including expanded search, in the sticky
   header's coordinate system. iOS otherwise composites fixed controls and
   absolute tabs separately while recovering from elastic overscroll. */
@media screen and (max-width: 58em) {
    .md-header .md-search,
    .md-header .md-header__source,
    .md-header .md-header__option {
        position: absolute !important;
    }
}

/* ==========================================================================
   Drawer Navigation and Article TOC
   ========================================================================== */

/* Shared sidebar/navigation primitives. Typography remains separately owned. */
/* Both navigation sidebars share search's soft translucent gray scrollbar.
   Hover/focus remain gray rather than inheriting Material's blue accent. */
:is(.md-sidebar--primary, .md-sidebar--secondary) {
    --edwinos-nav-scrollbar-thumb: rgba(96, 99, 108, 0.38);
    --edwinos-nav-scrollbar-hover: rgba(96, 99, 108, 0.56);
}

[data-md-color-scheme="slate"] :is(.md-sidebar--primary, .md-sidebar--secondary) {
    --edwinos-nav-scrollbar-thumb: rgba(190, 195, 205, 0.38);
    --edwinos-nav-scrollbar-hover: rgba(190, 195, 205, 0.56);
}

:is(.md-sidebar--primary, .md-sidebar--secondary) .md-sidebar__scrollwrap {
    scrollbar-color: var(--edwinos-nav-scrollbar-thumb) transparent;
}

:is(.md-sidebar--primary, .md-sidebar--secondary) .md-sidebar__scrollwrap:is(:hover, :focus-within) {
    scrollbar-color: var(--edwinos-nav-scrollbar-hover) transparent;
}

:is(.md-sidebar--primary, .md-sidebar--secondary) .md-sidebar__scrollwrap::-webkit-scrollbar-track {
    background: transparent;
}

:is(.md-sidebar--primary, .md-sidebar--secondary) .md-sidebar__scrollwrap::-webkit-scrollbar-thumb,
:is(.md-sidebar--primary, .md-sidebar--secondary) .md-sidebar__scrollwrap:is(:hover, :focus-within)::-webkit-scrollbar-thumb {
    background-color: var(--edwinos-nav-scrollbar-thumb);
    border-radius: 999px;
}

:is(.md-sidebar--primary, .md-sidebar--secondary) .md-sidebar__scrollwrap::-webkit-scrollbar-thumb:hover,
:is(.md-sidebar--primary, .md-sidebar--secondary) .md-sidebar__scrollwrap:is(:hover, :focus-within)::-webkit-scrollbar-thumb:hover {
    background-color: var(--edwinos-nav-scrollbar-hover);
}

.md-nav__link {
    transition: all 0.2s ease;
}

.md-nav__item--active > .md-nav__link {
    font-weight: 600;
}

[data-md-color-scheme="slate"] .md-sidebar {
    background: #0d1117;
    border-right: 1px solid rgba(48, 54, 61, 0.72);
}

[data-md-color-scheme="slate"] .md-nav__link {
    color: #8b949e;
}

[data-md-color-scheme="slate"] .md-nav__link:hover {
    color: #c9d1d9;
}

[data-md-color-scheme="slate"] .md-nav__item--active > .md-nav__link {
    color: #58a6ff;
    font-weight: 600;
}

/* Material renders each TOC level alike by default. These retained primitives
   preserve the established hierarchy and remain before the final type scale. */
[data-md-component="toc"] > li > .md-nav__link {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--md-default-fg-color, #1c1917);
    letter-spacing: -0.005em;
    margin-top: 0.35rem;
}

[data-md-component="toc"] li li > .md-nav__link {
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--md-default-fg-color--light, #57534e);
    opacity: 0.95;
}

[data-md-component="toc"] li li li > .md-nav__link {
    font-size: 0.68rem;
    font-weight: 400;
    color: var(--md-default-fg-color--light, #57534e);
    opacity: 0.78;
}

[data-md-component="toc"] li li li li > .md-nav__link {
    font-size: 0.66rem;
    font-weight: 400;
    opacity: 0.65;
}

[data-md-component="toc"] li li li li li > .md-nav__link {
    font-size: 0.64rem;
    font-weight: 400;
    font-style: italic;
    opacity: 0.55;
}

[data-md-component="toc"] .md-nav__link--active,
[data-md-component="toc"] .md-nav__link--passed + nav .md-nav__link--active {
    color: var(--ej-brand, #1e3a8a) !important;
    font-weight: 600 !important;
    opacity: 1 !important;
}

[data-md-component="toc"] .md-nav__link:hover {
    color: var(--ej-brand-hover, #1d4ed8);
    opacity: 1;
}

[data-md-color-scheme="slate"] [data-md-component="toc"] > li > .md-nav__link {
    color: #e2e8f0;
}

[data-md-color-scheme="slate"] [data-md-component="toc"] li li > .md-nav__link {
    color: #cbd5e1;
}

[data-md-color-scheme="slate"] [data-md-component="toc"] li li li > .md-nav__link,
[data-md-color-scheme="slate"] [data-md-component="toc"] li li li li > .md-nav__link,
[data-md-color-scheme="slate"] [data-md-component="toc"] li li li li li > .md-nav__link {
    color: #94a3b8;
}

[data-md-color-scheme="slate"] [data-md-component="toc"] .md-nav__link--active {
    color: #93c5fd !important;
}

[data-md-color-scheme="slate"] [data-md-component="toc"] .md-nav__link:hover {
    color: #bfdbfe;
}

.md-sidebar--secondary .md-nav__title {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--ej-brand, #1e3a8a);
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(28, 25, 23, 0.08);
    margin-bottom: 0.5rem;
}

[data-md-color-scheme="slate"] .md-sidebar--secondary .md-nav__title {
    color: #93c5fd;
    border-bottom-color: rgba(148, 163, 184, 0.2);
}

@media screen and (max-width: 76.234375em) {
    [data-md-color-scheme="default"] .md-nav--primary {
        background: rgba(250, 250, 249, 0.96);
        border-right: 1px solid #e7e5e4;
        box-shadow: 0 16px 40px -18px rgba(0, 0, 0, 0.35);
    }

    [data-md-color-scheme="default"] .md-nav--primary .md-nav__title {
        background: #fafaf9;
        border-bottom: 1px solid #e7e5e4;
    }

    [data-md-color-scheme="slate"] .md-nav--primary {
        background: rgba(13, 17, 23, 0.96);
        border-right: 1px solid #30363d;
        box-shadow: 0 20px 45px -20px rgba(1, 4, 9, 0.72);
    }

    [data-md-color-scheme="slate"] .md-nav--primary .md-nav__title {
        background: #0d1117;
        border-bottom: 1px solid #30363d;
        color: #c9d1d9;
    }
}

.md-sidebar--primary .edwinos-profile-drawer-entry,
.md-sidebar--primary .md-nav--primary .md-nav__item:has(> .md-nav__link[href$="HOME/Archive/"]),
.md-sidebar--primary .md-nav--primary .md-nav__item:has(> .md-nav__link[href$="HOME/Archive/index.html"]),
.md-sidebar--primary .md-nav--primary .md-nav__item:has(> .md-nav__link[href$="HOME/friends/"]),
.md-sidebar--primary .md-nav--primary .md-nav__item:has(> .md-nav__link[href$="HOME/friends/index.html"]) {
    display: none !important;
}

@media screen and (max-width: 76.234375em) {
    html:not(:has(> head > link[rel="canonical"][href*="/OsdNotes/"])):not(:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]))
    [data-md-toggle="drawer"]:checked ~ .md-container .md-sidebar--primary,
    html:not(:has(> head > link[rel="canonical"][href*="/OsdNotes/"])):not(:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]))
    [data-md-toggle="drawer"]:checked ~ .md-overlay {
        display: none !important;
        opacity: 0 !important;
        pointer-events: none !important;
    }

    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
    body .md-header__button[for="__drawer"],
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
    body .md-header__button[for="__drawer"] {
        position: absolute !important;
        top: 50% !important;
        left: 0.6rem !important;
        z-index: 2 !important;
        display: inline-flex !important;
        width: 2.2rem !important;
        height: 2.2rem !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
        padding: 0 !important;
        transform: translateY(-50%) !important;
    }

    /* The runtime marks only the active ENotes/Experiences drawer branch. */
    .md-nav--primary[data-edwinos-drawer-section]
    .edwinos-drawer-section-nav
    > .edwinos-drawer-section-title {
        display: none !important;
    }

    /* The section title is intentionally hidden, so its list no longer inherits
       Material's native top bar. Place the first row's 0.6rem text inset just
       beyond the header glass's 74% fade boundary, and keep the viewport-height
       drawer border-box. */
    .md-nav--primary[data-edwinos-drawer-section]
    .edwinos-drawer-section-nav
    > .md-nav__list {
        --edwinos-drawer-glass-clearance: calc(
            var(--edwinos-mobile-header-height, 3.5rem)
            + 0.42rem
        );
        box-sizing: border-box !important;
        padding-top: var(--edwinos-drawer-glass-clearance) !important;
    }

    .md-nav--primary[data-edwinos-drawer-section]
    .edwinos-drawer-section-nav
    > .edwinos-drawer-section-title
    > .md-nav__icon {
        display: none !important;
    }

    .md-nav--primary[data-edwinos-drawer-section]
    .edwinos-drawer-section-nav
    > .edwinos-drawer-section-title::before,
    .md-nav--primary[data-edwinos-drawer-section]
    .edwinos-drawer-section-nav
    > .edwinos-drawer-section-title::after {
        display: none !important;
        content: none !important;
    }
}

@media screen and (min-width: 34.0625rem) and (max-width: 76.234375rem) {
    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"]),
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]) {
        --edwinos-mobile-drawer-space: calc(
            max(10px, 2vw)
            + 44px
            + 8px
            - 0.72rem
        );
    }
}

@media screen and (max-width: 34rem) {
    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
    body .md-header__button[for="__drawer"],
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
    body .md-header__button[for="__drawer"] {
        box-sizing: border-box !important;
        top: calc(
            (
                var(
                    --edwinos-mobile-header-height,
                    var(--compact-header-height, 3.5rem)
                )
                - var(--edwinos-mobile-drawer-control-size)
            )
            / 2
        ) !important;
        left: max(5px, 2vw) !important;
        width: var(--edwinos-mobile-drawer-control-size) !important;
        height: var(--edwinos-mobile-drawer-control-size) !important;
        padding: 0 !important;
        transform: none !important;
    }
}

@media screen and (min-width: 34.0625rem) and (max-width: 76.234375rem) {
    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
    body .md-header__button[for="__drawer"],
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
    body .md-header__button[for="__drawer"] {
        box-sizing: border-box !important;
        top: 13px !important;
        left: max(10px, 2vw) !important;
        width: 44px !important;
        height: 44px !important;
        padding: 0 !important;
        transform: none !important;
    }
}

/* Keep article navigation geometry stable across hover, focus, and active
   states. Preserve hierarchy through nested lists and communicate interaction
   with color alone, without shifting long titles onto another line. */
.md-sidebar--primary .md-nav__link {
    /* JetBrains covers Latin, while Windows' generic monospace CJK fallback
       otherwise switches to a visibly unrelated serif face. */
    font-family: var(--edwinos-font-mono) !important;
}

.md-sidebar--primary .md-nav__list
.md-nav__link:not(.md-nav__title):not(.edwinos-drawer-section-title),
.md-sidebar--secondary [data-md-component="toc"] .md-nav__link {
    box-sizing: border-box;
    transition-property: color, background-color, opacity !important;
}

.md-sidebar--primary .md-nav__list
.md-nav__link:not(.md-nav__title):not(.edwinos-drawer-section-title):is(:hover, :focus-visible, .md-nav__link--active),
.md-sidebar--secondary [data-md-component="toc"]
.md-nav__link:is(:hover, :focus-visible, .md-nav__link--active, .edwinos-toc-link--selected) {
    padding-left: 0 !important;
    transform: none !important;
}

/* Drawer: one optical canvas beneath clear, desktop-sized navigation text.
   Material keeps the outer drawer transform; children expand inline as a tree. */
@media screen and (max-width: 76.234375em) {
    .md-nav--primary[data-edwinos-drawer-section] {
        --edwinos-drawer-chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m9 5 7 7-7 7' fill='none' stroke='black' stroke-width='1.65' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    }

    .md-sidebar--primary.edwinos-drawer-glass {
        --edwinos-drawer-tint: linear-gradient(to left,
            rgba(246, 248, 250, 0.06) 0,
            rgba(246, 248, 250, 0.11175) 24px,
            rgba(246, 248, 250, 0.31) 48px,
            rgba(246, 248, 250, 0.50825) 72px,
            rgba(246, 248, 250, 0.56) 96px);
        background: var(--edwinos-drawer-tint) !important;
        border: 0 !important;
        border-right: 1px solid rgba(255, 255, 255, 0.48) !important;
        border-radius: 0 16px 16px 0;
        -webkit-backdrop-filter: blur(14px) saturate(1.08);
        backdrop-filter: blur(14px) saturate(1.08);
        transition: transform 320ms cubic-bezier(0.22, 0.68, 0, 1.01),
            box-shadow 320ms ease !important;
    }

    [data-md-color-scheme="slate"] .md-sidebar--primary.edwinos-drawer-glass {
        --edwinos-drawer-tint: linear-gradient(to left,
            rgba(13, 17, 23, 0.08) 0,
            rgba(13, 17, 23, 0.13175) 24px,
            rgba(13, 17, 23, 0.33) 48px,
            rgba(13, 17, 23, 0.52825) 72px,
            rgba(13, 17, 23, 0.58) 96px);
        border-right-color: rgba(203, 213, 225, 0.18) !important;
    }

    .md-sidebar--primary.edwinos-drawer-refraction {
        -webkit-backdrop-filter: var(--edwinos-drawer-filter) saturate(1.08);
        backdrop-filter: var(--edwinos-drawer-filter) saturate(1.08);
    }

    /* Safari keeps a clear sampling host. Complementary masks smoothly blend
       its frosted center into a lighter, more transparent outer edge. */
    .md-sidebar--primary.edwinos-drawer-glass[data-edwinos-drawer-mode="native-blur"] {
        background: transparent !important;
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
    }

    .md-sidebar--primary.edwinos-drawer-glass[data-edwinos-drawer-mode="native-blur"]::before,
    .md-sidebar--primary.edwinos-drawer-glass[data-edwinos-drawer-mode="native-blur"]::after {
        position: absolute;
        z-index: -1;
        inset: 0;
        border-radius: inherit;
        content: "";
        pointer-events: none;
    }

    .md-sidebar--primary.edwinos-drawer-glass[data-edwinos-drawer-mode="native-blur"]::before {
        -webkit-backdrop-filter: blur(14px) saturate(1.08);
        backdrop-filter: blur(14px) saturate(1.08);
        -webkit-mask-image: linear-gradient(to left,
            transparent 0, rgba(0, 0, 0, 0.1035) 24px,
            rgba(0, 0, 0, 0.5) 48px, rgba(0, 0, 0, 0.8965) 72px, #000 96px);
        mask-image: linear-gradient(to left,
            transparent 0, rgba(0, 0, 0, 0.1035) 24px,
            rgba(0, 0, 0, 0.5) 48px, rgba(0, 0, 0, 0.8965) 72px, #000 96px);
    }

    .md-sidebar--primary.edwinos-drawer-glass[data-edwinos-drawer-mode="native-blur"]::after {
        -webkit-backdrop-filter: blur(2px) saturate(1.08);
        backdrop-filter: blur(2px) saturate(1.08);
        -webkit-mask-image: linear-gradient(to left,
            #000 0, rgba(0, 0, 0, 0.8965) 24px,
            rgba(0, 0, 0, 0.5) 48px, rgba(0, 0, 0, 0.1035) 72px, transparent 96px);
        mask-image: linear-gradient(to left,
            #000 0, rgba(0, 0, 0, 0.8965) 24px,
            rgba(0, 0, 0, 0.5) 48px, rgba(0, 0, 0, 0.1035) 72px, transparent 96px);
    }

    .edwinos-drawer-glass[data-edwinos-drawer-mode="native-blur"]
    > .edwinos-drawer-glass__highlight {
        background: var(--edwinos-drawer-tint);
    }

    .edwinos-drawer-glass > .edwinos-drawer-glass__highlight {
        position: absolute;
        z-index: 0;
        inset: 0;
        border-radius: inherit;
        box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.36),
            inset -5px 0 10px -8px rgba(255, 255, 255, 0.7);
        pointer-events: none;
    }

    [data-md-color-scheme="slate"]
    .edwinos-drawer-glass > .edwinos-drawer-glass__highlight {
        box-shadow: inset -1px 0 0 rgba(226, 232, 240, 0.15),
            inset -5px 0 10px -8px rgba(226, 232, 240, 0.35);
    }

    .md-sidebar--primary.edwinos-drawer-glass
    :is(.md-nav, .md-nav__title, .md-nav__list, .md-nav__source),
    .md-sidebar--primary.edwinos-drawer-glass
    .md-nav--lifted > .md-nav__list > .md-nav__item--active > .md-nav__link {
        background: transparent !important;
        box-shadow: none !important;
        border-right: 0 !important;
    }

    .md-sidebar--primary.edwinos-drawer-glass
    .md-nav--primary :is(.md-nav__item, .md-nav__list) {
        border: 0 !important;
        box-shadow: none !important;
    }

    /* Only the active section's full-height root remains a native panel. Its
       ancestors have no visible controls; descendants keep their rows visible. */
    .md-sidebar--primary
    .md-nav--primary[data-edwinos-drawer-section]
    > :is(.md-nav__title, .md-nav__source),
    .md-sidebar--primary
    .md-nav--primary[data-edwinos-drawer-section]
    > .md-nav__list > .md-nav__item > .md-nav__link {
        display: none !important;
    }

    .md-sidebar--primary
    .md-nav--primary[data-edwinos-drawer-section] .md-nav__item {
        font-size: 0.7rem;
        line-height: 1.3;
    }

    /* Inline tree groups have a single grid child, so 0fr to 1fr follows
       actual content height without measuring or translating nested panels. */
    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-group {
        position: static !important;
        inset: auto !important;
        display: grid !important;
        grid-template-rows: 0fr;
        width: auto !important;
        height: auto !important;
        min-height: 0;
        margin: 0;
        padding: 0;
        opacity: 1 !important;
        transform: none !important;
        visibility: hidden;
        transition: grid-template-rows 220ms cubic-bezier(0.22, 0.68, 0, 1),
            visibility 0s 220ms !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-group[aria-expanded="true"] {
        grid-template-rows: 1fr;
        visibility: visible;
        transition: grid-template-rows 220ms cubic-bezier(0.22, 0.68, 0, 1),
            visibility 0s !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-group > .md-nav__title {
        display: none !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-group > .md-nav__list {
        min-height: 0;
        overflow: hidden !important;
        margin: 0 !important;
        padding: 0 0 0 12px !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav__list > .md-nav__item > .md-nav__link,
    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav__list > .md-nav__item
    > .md-nav__link:is(:hover, :focus-visible, .md-nav__link--active) {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 0.6rem 0.8rem !important;
        background: transparent !important;
        transform: none !important;
    }

    /* Keep the current article's outline accessible inside the same tree.
       Its duplicate native article anchor remains hidden on this route. */
    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav__link[for="__toc"] {
        display: flex !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav__link[for="__toc"] + a.md-nav__link {
        display: none !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav--secondary
    .md-nav:not(.edwinos-drawer-tree-group) {
        position: static !important;
        inset: auto !important;
        display: block !important;
        width: auto !important;
        height: auto !important;
        opacity: 1 !important;
        transform: none !important;
        visibility: inherit !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav--secondary
    .md-nav:not(.edwinos-drawer-tree-group) > .md-nav__list {
        margin: 0 !important;
        padding: 0 0 0 12px !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav__list
    > .md-nav__item > .md-nav__link[href] {
        padding-left: calc(0.8rem + 24px) !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav__container > .md-nav__link {
        align-items: center;
        padding: 0 !important;
        background: transparent !important;
        transform: none !important;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .md-nav__container > .edwinos-drawer-tree-toggle {
        order: -1;
        flex: 0 0 16px;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-toggle {
        cursor: pointer;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-toggle > .md-nav__icon {
        order: -1;
        flex: 0 0 16px;
        align-self: center;
        width: 16px;
        height: 16px;
        margin: 0;
        background: transparent;
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-toggle > .md-nav__icon::after {
        -webkit-mask-image: var(--edwinos-drawer-chevron);
        mask-image: var(--edwinos-drawer-chevron);
        transform: rotate(0deg);
        transition: transform 180ms cubic-bezier(0.22, 0.68, 0, 1);
    }

    .md-sidebar--primary
    .edwinos-drawer-section-nav
    .edwinos-drawer-tree-toggle[aria-expanded="true"] > .md-nav__icon::after {
        transform: rotate(90deg);
    }

    body[data-md-color-scheme="default"]
    .md-sidebar--primary
    .md-nav--primary[data-edwinos-drawer-section]
    .edwinos-drawer-section-nav
    .md-nav__link:is(:hover, :focus-visible) {
        color: #0969da !important;
        background: transparent !important;
        transform: none !important;
    }

    body[data-md-color-scheme="slate"]
    .md-sidebar--primary
    .md-nav--primary[data-edwinos-drawer-section]
    .edwinos-drawer-section-nav
    .md-nav__link:is(:hover, :focus-visible) {
        color: #58a6ff !important;
        background: transparent !important;
        transform: none !important;
    }
}

@media screen and (max-width: 76.234375em) and (prefers-reduced-motion: reduce) {
    .md-sidebar--primary.edwinos-drawer-glass,
    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-group,
    .md-sidebar--primary
    .edwinos-drawer-section-nav .edwinos-drawer-tree-toggle > .md-nav__icon::after {
        transition: none !important;
    }
}

body[data-md-color-scheme="default"]
.md-sidebar--primary .md-nav__link--active {
    color: #0969da !important;
}

body[data-md-color-scheme="slate"]
.md-sidebar--primary .md-nav__link--active {
    color: #58a6ff !important;
}

/* Article TOC: the title follows Overview's Caveat section headings. The
   masked layers retain their five-stage blur, while one theme-matched
   fade supplies the glass tint beneath the title divider. */
.md-sidebar--secondary .md-nav--secondary > .md-nav__title {
    position: sticky !important;
    z-index: 3 !important;
    overflow: visible !important;
    font-family: var(--edwinos-font-hand) !important;
    font-size: 1.3rem !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
    background: rgb(246, 248, 250) !important;
    border-bottom: 0 !important;
    box-shadow: none !important;
    -webkit-backdrop-filter: blur(18px) saturate(108%);
    backdrop-filter: blur(18px) saturate(108%);
}

/* Cover the small scrollwrap strip above the sticky title so TOC entries
   cannot peek through while Material keeps the sidebar vertically aligned. */
.md-sidebar--secondary .md-nav--secondary > .md-nav__title::before {
    position: absolute;
    right: 0;
    bottom: 100%;
    left: 0;
    height: 1rem;
    background: inherit;
    content: "";
    pointer-events: none;
}

[data-md-color-scheme="slate"]
.md-sidebar--secondary .md-nav--secondary > .md-nav__title {
    background: rgb(13, 17, 23) !important;
}

.md-sidebar--secondary .edwinos-toc-glass {
    position: absolute;
    top: calc(100% - 1px);
    right: 0;
    left: 0;
    z-index: 2;
    display: block;
    height: calc(var(--edwinos-toc-glass-depth, 0px) + 1px);
    overflow: hidden;
    pointer-events: none;
}

.md-sidebar--secondary :is(.edwinos-toc-glass__layer, .edwinos-toc-glass__fade) {
    position: absolute;
    inset: 0;
    display: block;
    border: 0;
    background: transparent;
    pointer-events: none;
}

.md-sidebar--secondary .edwinos-toc-glass__layer {
    background: transparent;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
}

.md-sidebar--secondary .edwinos-toc-glass__layer--1 {
    -webkit-mask-image: linear-gradient(to bottom, transparent 0 24%, #000 44% 56%, transparent 74% 100%);
    mask-image: linear-gradient(to bottom, transparent 0 24%, #000 44% 56%, transparent 74% 100%);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
}

.md-sidebar--secondary .edwinos-toc-glass__layer--2 {
    -webkit-mask-image: linear-gradient(to bottom, transparent 0 18%, #000 36% 52%, transparent 74% 100%);
    mask-image: linear-gradient(to bottom, transparent 0 18%, #000 36% 52%, transparent 74% 100%);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

.md-sidebar--secondary .edwinos-toc-glass__layer--3 {
    -webkit-mask-image: linear-gradient(to bottom, #000 0 28%, transparent 58% 100%);
    mask-image: linear-gradient(to bottom, #000 0 28%, transparent 58% 100%);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.md-sidebar--secondary .edwinos-toc-glass__layer--4 {
    -webkit-mask-image: linear-gradient(to bottom, #000 0 16%, transparent 42% 100%);
    mask-image: linear-gradient(to bottom, #000 0 16%, transparent 42% 100%);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
}

.md-sidebar--secondary .edwinos-toc-glass__layer--5 {
    -webkit-mask-image: linear-gradient(to bottom, #000 0%, transparent 22% 100%);
    mask-image: linear-gradient(to bottom, #000 0%, transparent 22% 100%);
    -webkit-backdrop-filter: blur(22px);
    backdrop-filter: blur(22px);
}

[data-md-color-scheme="default"]
.md-sidebar--secondary .edwinos-toc-glass__fade {
    background: linear-gradient(
        to bottom,
        rgba(246, 248, 250, 0.9) 0%,
        rgba(246, 248, 250, 0.55) 28%,
        rgba(246, 248, 250, 0.18) 52%,
        transparent 74%
    );
}

[data-md-color-scheme="slate"]
.md-sidebar--secondary .edwinos-toc-glass__fade {
    background: linear-gradient(
        to bottom,
        rgba(13, 17, 23, 0.9) 0%,
        rgba(13, 17, 23, 0.55) 28%,
        rgba(13, 17, 23, 0.18) 52%,
        transparent 74%
    );
}

.md-sidebar--secondary [data-md-component="toc"] .md-nav__link {
    font-family: var(--edwinos-font-serif) !important;
    line-height: 1.38 !important;
    transition: color 0.2s ease, padding 0.2s ease, opacity 0.2s ease;
}

.md-sidebar--secondary [data-md-component="toc"] > li > .md-nav__link {
    font-size: 0.69rem !important;
}

.md-sidebar--secondary [data-md-component="toc"] li li > .md-nav__link {
    font-size: 0.64rem !important;
}

.md-sidebar--secondary [data-md-component="toc"] li li li > .md-nav__link {
    font-size: 0.61rem !important;
}

.md-sidebar--secondary [data-md-component="toc"] li li li li > .md-nav__link {
    font-size: 0.59rem !important;
}

/* Deep TOC entries need a brighter active color than the inherited navy on
   both palettes, especially against EdwinOS's dark article background. */
body[data-md-color-scheme="default"]
.md-sidebar--secondary [data-md-component="toc"]
li li > .md-nav__link--active {
    color: #0550ae !important;
}

body[data-md-color-scheme="slate"]
.md-sidebar--secondary [data-md-component="toc"]
li li > .md-nav__link--active {
    color: #79c0ff !important;
}

/* A TOC click may intentionally place the heading below Material's scrollspy
   threshold to clear the translucent notch. Keep the clicked item visually
   selected while the page is stationary; normal scroll tracking resumes as
   soon as the reader scrolls again. */
body[data-md-color-scheme="default"]
.md-sidebar--secondary [data-md-component="toc"]
.edwinos-toc-link--selected {
    color: #0550ae !important;
    font-weight: 600 !important;
    opacity: 1 !important;
}

body[data-md-color-scheme="slate"]
.md-sidebar--secondary [data-md-component="toc"]
.edwinos-toc-link--selected {
    color: #79c0ff !important;
    font-weight: 600 !important;
    opacity: 1 !important;
}

body[data-md-color-scheme="default"]
.md-sidebar--secondary [data-md-component="toc"]:has(.edwinos-toc-link--selected)
.md-nav__link--active:not(.edwinos-toc-link--selected) {
    color: var(--md-default-fg-color--light) !important;
    font-weight: 400 !important;
}

body[data-md-color-scheme="slate"]
.md-sidebar--secondary [data-md-component="toc"]:has(.edwinos-toc-link--selected)
.md-nav__link--active:not(.edwinos-toc-link--selected) {
    color: #94a3b8 !important;
    font-weight: 400 !important;
}

/* ==========================================================================
   Profile Card and HOME shell
   ==========================================================================
   Single owner for profile layout, identity, actions, metadata and responsive
   details. Declarations below retain the currently winning cascade values.
   Desktop: 260px sidebar; tablet: 13rem avatar with a flex details column;
   phone: 5.4rem avatar, with metadata spanning both columns at <=26rem.
   Keep route selectors and breakpoint order intact when extending this owner.
   ========================================================================== */

body.is-homepage .md-main__inner,
body:has(.academic-home-layout) .md-main__inner {
    max-width: none;
    margin-top: 0;
}

body.is-homepage .md-content,
body:has(.academic-home-layout) .md-content {
    max-width: none;
    padding-top: 0 !important;
}

/* Refresh starts at the final profile/Overview geometry. Nested entrance
   transforms otherwise move both columns while scroll restoration settles. */
body:is(.is-homepage, .is-home-profile-page) .md-content__inner,
body:has(.academic-home-layout) .md-content__inner {
    animation: none;
}

body.is-homepage .md-content__inner::before,
body:has(.academic-home-layout) .md-content__inner::before {
    display: none;
}

.academic-home-layout {
    display: grid;
    margin: 0 auto;
}

.academic-home-layout .profile-card {
    display: flex;
    flex-direction: column;
    padding: 0;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0;
    box-shadow: none !important;
}

.profile-avatar {
    transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
    height: auto;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border: 1px solid var(--academic-card-border);
    border-radius: 50%;
    background: var(--academic-soft);
}

.profile-avatar img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.academic-home-layout .profile-card:hover .profile-avatar {
    transform: translateY(-2px);
}

.profile-role {
    letter-spacing: 0;
    margin-right: 0 !important;
    margin-bottom: 0 !important;
    margin-left: 0 !important;
    color: var(--academic-muted);
    font-weight: 500;
}

.social-icon {
    display: block;
    width: 1.05rem;
    height: 1.05rem;
    fill: currentColor;
}

@media (prefers-reduced-motion: reduce) {
    .profile-avatar {
        transition: none !important;
    }

}
.academic-sidebar {
    display: flex;
    flex-direction: column;
    row-gap: 0;
    column-gap: 0;
}

.md-typeset .profile-name {
    margin: 0 !important;
    color: var(--academic-ink) !important;
}

.profile-pronouns {
    margin: 0.08rem 0 0 !important;
    color: var(--academic-muted);
    font-weight: 300;
    display: block;
}

.profile-actions {
    width: 100%;
}

.md-typeset .btn-github-action,
.md-typeset .btn-github-action:hover,
.md-typeset .btn-github-action:focus {
    position: relative;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(31, 35, 40, 0.15) !important;
    border-radius: 8px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8),
                inset 0 -1px 0 rgba(67, 77, 91, 0.08),
                0 1px 4px rgba(27, 31, 36, 0.045);
    -webkit-backdrop-filter: blur(3.5px) saturate(1.12);
    backdrop-filter: blur(3.5px) saturate(1.12);
    text-decoration: none !important;
    white-space: nowrap;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
    color: #1F2328 !important;
    text-align: center !important;
    box-sizing: border-box !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.md-typeset .btn-github-action:hover,
.md-typeset .btn-github-action:focus {
    background-color: rgba(255, 255, 255, 0.28);
}

.md-typeset .btn-github-action.edwinos-profile-action-refraction {
    -webkit-backdrop-filter: var(--edwinos-profile-action-filter) saturate(1.12);
    backdrop-filter: var(--edwinos-profile-action-filter) saturate(1.12);
}

.md-typeset .btn-github-action:focus-visible {
    outline: 2px solid var(--md-accent-fg-color);
    outline-offset: 3px;
}

.md-typeset .edwinos-profile-action-glass__highlight {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    box-shadow: inset 1px 0 rgba(255, 255, 255, 0.32),
                inset -1px 0 rgba(255, 255, 255, 0.18);
    pointer-events: none;
}

body[data-md-color-scheme="slate"] .md-typeset .btn-github-action,
body[data-md-color-scheme="slate"] .md-typeset .btn-github-action:hover,
body[data-md-color-scheme="slate"] .md-typeset .btn-github-action:focus {
    background-color: rgba(40, 49, 61, 0.2);
    border-color: rgba(240, 246, 252, 0.1) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14),
                inset 0 -1px 0 rgba(0, 0, 0, 0.22),
                0 1px 4px rgba(0, 0, 0, 0.1);
    color: #f0f6fc !important;
}

body[data-md-color-scheme="slate"] .md-typeset .btn-github-action:hover,
body[data-md-color-scheme="slate"] .md-typeset .btn-github-action:focus {
    background-color: rgba(86, 101, 120, 0.22);
    border-color: rgba(240, 246, 252, 0.2) !important;
}

.profile-followers {
    width: 100%;
}

.md-typeset .follower-link,
.md-typeset .follower-link:hover,
.md-typeset .follower-link:focus {
    display: inline-flex;
    align-items: center;
    row-gap: 6px;
    column-gap: 6px;
    color: var(--academic-muted) !important;
    border-bottom: 0 !important;
    text-decoration: none !important;
    transition: color 0.2s ease;
}

.follower-link .meta-icon {
    fill: currentColor;
}

.follower-text {
    display: inline-flex;
    row-gap: 0.25rem;
    column-gap: 0.25rem;
    align-items: baseline;
}

.follower-text strong {
    color: var(--academic-ink) !important;
    background: transparent !important;
    padding: 0 !important;
    font-weight: 600;
}

.md-typeset .profile-meta li::before {
    display: none !important;
    content: none !important;
}

.meta-icon {
    flex-shrink: 0;
    fill: var(--academic-muted);
}

/* Align the envelope with the email glyphs rather than the font line box. */
.profile-meta .meta-icon--email {
    transform: translateY(0.08em);
}

.profile-meta .profile-email-digits {
    font-size: 0.92em;
}

.md-typeset .meta-link,
.md-typeset .meta-link:hover,
.md-typeset .meta-link:focus,
.md-typeset .meta-link:active {
    border-bottom: 0 !important;
    text-decoration: none !important;
    transition: color 0.2s ease;
}

.md-typeset .meta-link:hover,
.md-typeset .meta-link:focus,
.md-typeset .meta-link:active {
    color: var(--academic-accent) !important;
}

.profile-social-left {
    display: flex;
    width: 100%;
    align-items: center;
}

.md-typeset .profile-social-left a,
.md-typeset .profile-social-left a:hover,
.md-typeset .profile-social-left a:focus {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--academic-muted);
    background: transparent;
    border: 0 !important;
    border-radius: 0;
    text-decoration: none !important;
    transition: color 0.2s ease;
}

.md-typeset .profile-social-left a:hover,
.md-typeset .profile-social-left a:focus {
    color: var(--academic-ink);
}

.profile-social-left .social-icon {
    fill: currentColor;
}

.profile-social-left .social-icon--scholar {
    overflow: hidden;
    border-radius: 50%;
    background-color: currentColor;
}

.profile-social-left .social-icon--scholar::after {
    content: "";
    display: block;
    width: 100%;
    height: 100%;
    background: url("../assets/icons/google-scholar-glyph.png") center / contain no-repeat;
}

.academic-home-layout .profile-card .profile-name,
.academic-home-layout .profile-card .profile-pronouns,
.academic-home-layout .profile-card .profile-role {
    text-align: left;
}

.md-typeset .profile-meta {
    width: 100%;
    margin-top: 0 !important;
    margin-right: 0 !important;
    margin-left: 0 !important;
    padding: 0 !important;
    font-size: 14px;
    line-height: 1.5;
    list-style: none !important;
    list-style-type: none !important;
}

.md-typeset .profile-meta li {
    display: flex !important;
    width: 100%;
    justify-content: flex-start;
    margin: 0 !important;
    padding: 0 !important;
    color: var(--academic-ink);
    text-align: left;
    text-indent: 0 !important;
    list-style: none !important;
}

.md-typeset .profile-meta .meta-link,
.md-typeset .profile-meta .meta-text {
    font-size: inherit;
    line-height: inherit;
}

.profile-name-wrap {
    max-width: none;
}

.md-typeset .follower-link,
.md-typeset .follower-link:hover,
.md-typeset .follower-link:focus,
.follower-text {
    font-size: 14px;
    line-height: 1.5;
}

.md-typeset .follower-link:hover,
.md-typeset .follower-link:focus {
    color: var(--academic-muted) !important;
}

.md-typeset .follower-link:hover .meta-icon,
.md-typeset .follower-link:focus .meta-icon {
    fill: var(--academic-muted) !important;
}

.md-typeset .follower-link:hover .follower-text,
.md-typeset .follower-link:focus .follower-text,
.md-typeset .follower-link:hover .follower-count,
.md-typeset .follower-link:focus .follower-count,
.md-typeset .follower-link:hover .follower-separator,
.md-typeset .follower-link:focus .follower-separator {
    color: var(--academic-accent) !important;
}

.md-typeset .meta-link,
.meta-text,
.beijing-time-main,
.follower-count {
    color: #1F2328 !important;
}

.follower-text,
.follower-separator,
.beijing-time-zone {
    color: #656d76 !important;
}

[data-md-color-scheme="slate"] .md-typeset .meta-link,
[data-md-color-scheme="slate"] .meta-text,
[data-md-color-scheme="slate"] .beijing-time-main,
[data-md-color-scheme="slate"] .follower-count {
    color: #f0f6fc !important;
}

[data-md-color-scheme="slate"] .follower-text,
[data-md-color-scheme="slate"] .follower-separator,
[data-md-color-scheme="slate"] .beijing-time-zone {
    color: #8b949e !important;
}

[data-md-color-scheme="slate"] .meta-icon {
    fill: #8b949e !important;
}

[data-md-color-scheme="slate"] .md-typeset .meta-link:hover {
    color: #58a6ff !important;
}

body.is-home-profile-page .md-sidebar--primary {
    display: none !important;
}

body.is-home-profile-page .md-main__inner {
    max-width: none !important;
}

body.is-home-profile-page .md-content {
    max-width: none !important;
    padding-top: 0 !important;
}

.profile-cn-name {
    color: #656d76;
    font-size: 0.72em;
}

[data-md-color-scheme="slate"] .profile-cn-name {
    color: #8b949e;
}

body:is(.is-homepage, .is-home-profile-page) .md-content__inner,
body:has(.academic-home-layout) .md-content__inner {
    max-width: none !important;
    margin: 0 !important;
    padding: clamp(0.75rem, 1.55vw, 1.15rem) clamp(0.9rem, 3.4vw, 2rem) 4rem !important;
}

body:is(.is-homepage, .is-home-profile-page) .academic-home-layout,
body:has(.academic-home-layout) .academic-home-layout {
    align-items: start !important;
    grid-template-columns: 260px minmax(0, 1fr) !important;
    row-gap: clamp(1.75rem, 3.4vw, 2.5rem) !important;
    column-gap: clamp(1.75rem, 3.4vw, 2.5rem) !important;
    width: min(100%, 80rem) !important;
}

body:is(.is-homepage, .is-home-profile-page) .academic-sidebar,
body:has(.academic-home-layout) .academic-sidebar {
    position: sticky !important;
    align-self: flex-start !important;
    transform: none !important;
    top: calc(
        var(
            --edwinos-header-height,
            var(--compact-header-height, var(--md-header-height, 48px))
        )
        + clamp(0.75rem, 1.55vw, 1.15rem)
    ) !important;
}

@media screen and (max-width: 58rem) {
    .profile-name-wrap,
    .profile-followers,
    .profile-meta {
        width: 100% !important;
        text-align: center !important;
    }

}
body:is(.is-homepage, .is-home-profile-page) .academic-home-layout .profile-card,
body:has(.academic-home-layout) .academic-home-layout .profile-card {
    align-items: flex-start !important;
    text-align: left !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-avatar,
body:has(.academic-home-layout) .profile-avatar {
    width: 100% !important;
    max-width: 260px !important;
    margin: 0 0 0.8rem !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-name-wrap,
body:has(.academic-home-layout) .profile-name-wrap {
    width: 100% !important;
    margin: 0 0 0.75rem !important;
    text-align: left !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-pronouns,
body:has(.academic-home-layout) .profile-pronouns {
    transform: none !important;
    font-size: 0.92rem !important;
    line-height: 1.2 !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-role,
body:has(.academic-home-layout) .profile-role {
    margin-top: 0.12rem !important;
    font-size: 0.76rem !important;
    line-height: 1.25 !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-actions,
body:has(.academic-home-layout) .profile-actions,
body:is(.is-homepage, .is-home-profile-page) .profile-followers,
body:has(.academic-home-layout) .profile-followers {
    margin-bottom: 0.72rem !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .btn-github-action,
body:has(.academic-home-layout) .md-typeset .btn-github-action,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .btn-github-action:hover,
body:has(.academic-home-layout) .md-typeset .btn-github-action:hover,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .btn-github-action:focus,
body:has(.academic-home-layout) .md-typeset .btn-github-action:focus {
    min-height: 26px !important;
    height: 26px !important;
    padding: 0 12px !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 0.84rem !important;
    font-weight: 500 !important;
    letter-spacing: 0 !important;
    line-height: 1.2 !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .follower-link,
body:has(.academic-home-layout) .md-typeset .follower-link,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .follower-text,
body:has(.academic-home-layout) .md-typeset .follower-text,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta li,
body:has(.academic-home-layout) .md-typeset .profile-meta li {
    font-size: 0.84rem !important;
    line-height: 1.45 !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
body:has(.academic-home-layout) .md-typeset .profile-meta {
    margin-bottom: 0.65rem !important;
    display: flex !important;
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    align-items: flex-start !important;
    row-gap: 0.36rem !important;
    column-gap: 0.88rem !important;
    overflow: visible !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta .meta-icon,
body:has(.academic-home-layout) .md-typeset .profile-meta .meta-icon,
body:is(.is-homepage, .is-home-profile-page) .follower-link .meta-icon,
body:has(.academic-home-layout) .follower-link .meta-icon {
    width: 15px !important;
    height: 15px !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
body:has(.academic-home-layout) .profile-social-left {
    justify-content: flex-start !important;
    margin-top: 0.15rem !important;
    row-gap: 0.72rem !important;
    column-gap: 0.72rem !important;
    transform: translateX(-0.06rem);
}

@media screen and (max-width: 63.25em) {
    body:is(.is-homepage, .is-home-profile-page) .academic-home-layout,
    body:has(.academic-home-layout) .academic-home-layout {
        grid-template-columns: minmax(0, 1fr) !important;
        row-gap: 1.6rem !important;
        column-gap: 1.6rem !important;
        width: min(100%, 56rem) !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .academic-sidebar,
    body:has(.academic-home-layout) .academic-sidebar {
        position: static !important;
        width: 100% !important;
        min-width: 0 !important;
        padding-bottom: 1.2rem !important;
        margin-bottom: 0 !important;
        border-bottom: 1px solid var(--academic-card-border) !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .academic-home-layout .profile-card,
    body:has(.academic-home-layout) .academic-home-layout .profile-card {
        display: grid !important;
        row-gap: 0.45rem !important;
        align-items: start !important;
        width: 100% !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-avatar,
    body:has(.academic-home-layout) .profile-avatar {
        grid-column: 1 !important;
        margin: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-name-wrap,
    body:has(.academic-home-layout) .profile-name-wrap {
        grid-column: 2 !important;
        grid-row: 1 !important;
        margin-bottom: 0.25rem !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-actions,
    body:has(.academic-home-layout) .profile-actions {
        grid-column: 2 !important;
        grid-row: 2 !important;
        max-width: 16rem !important;
        margin-bottom: 0.25rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers {
        grid-column: 2 !important;
        grid-row: 3 !important;
        width: 100% !important;
        margin-bottom: 0 !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta {
        grid-row: 5 !important;
        margin: 0.65rem 0 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta li,
    body:has(.academic-home-layout) .md-typeset .profile-meta li {
        width: auto !important;
        justify-content: flex-start !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        grid-row: 6 !important;
        justify-content: flex-start !important;
        margin-top: 0.45rem !important;
    }

}
@media screen and (max-width: 48em) {
    body:is(.is-homepage, .is-home-profile-page) .md-content__inner,
    body:has(.academic-home-layout) .md-content__inner {
        padding: 0.8rem 0.85rem 3rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .academic-home-layout,
    body:has(.academic-home-layout) .academic-home-layout {
        row-gap: 1.2rem !important;
        column-gap: 1.2rem !important;
        width: 100% !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .academic-home-layout .profile-card,
    body:has(.academic-home-layout) .academic-home-layout .profile-card {
        grid-template-columns: 5.4rem minmax(0, 1fr) !important;
        column-gap: 0.85rem !important;
        row-gap: 0.35rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-avatar,
    body:has(.academic-home-layout) .profile-avatar {
        grid-row: 1 / span 3 !important;
        max-width: 5.4rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-actions,
    body:has(.academic-home-layout) .profile-actions,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers {
        grid-column: 2 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta,
    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        grid-column: 1 / -1 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-pronouns,
    body:has(.academic-home-layout) .profile-pronouns {
        font-size: 0.82rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-role,
    body:has(.academic-home-layout) .profile-role {
        font-size: 0.74rem !important;
    }

}
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-name,
body:has(.academic-home-layout) .md-typeset .profile-name,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-cn-name,
body:has(.academic-home-layout) .md-typeset .profile-cn-name {
    font-family: var(--edwinos-font-serif) !important;
    letter-spacing: 0 !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-name,
body:has(.academic-home-layout) .md-typeset .profile-name {
    font-size: 1.42rem !important;
    font-weight: 600 !important;
    line-height: 1.12 !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-cn-name,
body:has(.academic-home-layout) .md-typeset .profile-cn-name {
    font-weight: 400 !important;
}

.profile-pronouns,
.profile-role,
.profile-actions,
.profile-followers,
.profile-meta {
    font-family: var(--edwinos-font-reading-sans) !important;
}

.profile-social-left,
.beijing-time-main,
.beijing-time-zone {
    font-family: var(--edwinos-font-mono) !important;
}

.profile-meta,
.profile-meta a,
.profile-meta .meta-text {
    font-family: var(--edwinos-font-reading-sans) !important;
}

.profile-meta #beijing-time,
.profile-meta .beijing-time-main,
.profile-meta .beijing-time-zone {
    font-family: var(--edwinos-font-mono) !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-followers,
body:has(.academic-home-layout) .profile-followers,
body:is(.is-homepage, .is-home-profile-page) .profile-followers a,
body:has(.academic-home-layout) .profile-followers a,
body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-text,
body:has(.academic-home-layout) .profile-followers .follower-text,
body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-count,
body:has(.academic-home-layout) .profile-followers .follower-count,
body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-separator,
body:has(.academic-home-layout) .profile-followers .follower-separator {
    font-family: var(--edwinos-font-reading-sans) !important;
    font-weight: 500 !important;
    letter-spacing: 0 !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-count,
body:has(.academic-home-layout) .profile-followers .follower-count {
    font-family: var(--edwinos-font-mono) !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-text,
body:has(.academic-home-layout) .profile-followers .follower-text {
    row-gap: 0.16rem !important;
    column-gap: 0.16rem !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-followers,
body:has(.academic-home-layout) .profile-followers,
body:is(.is-homepage, .is-home-profile-page) .profile-followers a,
body:has(.academic-home-layout) .profile-followers a,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta li,
body:has(.academic-home-layout) .md-typeset .profile-meta li,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta a,
body:has(.academic-home-layout) .md-typeset .profile-meta a,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta .meta-text,
body:has(.academic-home-layout) .md-typeset .profile-meta .meta-text {
    font-size: 0.78rem !important;
    line-height: 1.38 !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-social-left a,
body:has(.academic-home-layout) .md-typeset .profile-social-left a,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-social-left a:hover,
body:has(.academic-home-layout) .md-typeset .profile-social-left a:hover,
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-social-left a:focus,
body:has(.academic-home-layout) .md-typeset .profile-social-left a:focus {
    width: 1.08rem !important;
    height: 1.08rem !important;
}

body:is(.is-homepage, .is-home-profile-page) .profile-social-left .social-icon,
body:has(.academic-home-layout) .profile-social-left .social-icon {
    width: 0.96rem !important;
    height: 0.96rem !important;
}

@media screen and (min-width: 46em) and (max-width: 63.25em) {
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta {
        grid-column: 2 !important;
        grid-row: 4 !important;
        justify-content: flex-start !important;
        justify-self: start !important;
        width: 100% !important;
        margin: 0.1rem 0 0 !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers a,
    body:has(.academic-home-layout) .profile-followers a,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-text,
    body:has(.academic-home-layout) .profile-followers .follower-text,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-count,
    body:has(.academic-home-layout) .profile-followers .follower-count,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-separator,
    body:has(.academic-home-layout) .profile-followers .follower-separator,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta li,
    body:has(.academic-home-layout) .md-typeset .profile-meta li,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta a,
    body:has(.academic-home-layout) .md-typeset .profile-meta a,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta .meta-text,
    body:has(.academic-home-layout) .md-typeset .profile-meta .meta-text {
        min-width: 0 !important;
        white-space: nowrap !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        grid-column: 2 !important;
        grid-row: 5 !important;
        justify-content: flex-start !important;
        justify-self: start !important;
        margin-top: 0.28rem !important;
    }

}
@media screen and (min-width: 43em) and (max-width: 45.9375em) {
    body:is(.is-homepage, .is-home-profile-page) .academic-home-layout .profile-card,
    body:has(.academic-home-layout) .academic-home-layout .profile-card {
        display: grid !important;
        row-gap: 0.32rem !important;
        width: 100% !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-name-wrap,
    body:has(.academic-home-layout) .profile-name-wrap,
    body:is(.is-homepage, .is-home-profile-page) .profile-actions,
    body:has(.academic-home-layout) .profile-actions,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta,
    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        grid-column: 2 !important;
        width: 100% !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-name-wrap,
    body:has(.academic-home-layout) .profile-name-wrap {
        grid-row: 1 !important;
        margin-bottom: 0.1rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-actions,
    body:has(.academic-home-layout) .profile-actions {
        grid-row: 2 !important;
        max-width: 15rem !important;
        margin-bottom: 0.12rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers {
        grid-row: 3 !important;
        margin-bottom: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta {
        justify-content: flex-start !important;
        margin-right: 0 !important;
        margin-bottom: 0 !important;
        margin-left: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers a,
    body:has(.academic-home-layout) .profile-followers a,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta li,
    body:has(.academic-home-layout) .md-typeset .profile-meta li,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta a,
    body:has(.academic-home-layout) .md-typeset .profile-meta a,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta .meta-text,
    body:has(.academic-home-layout) .md-typeset .profile-meta .meta-text {
        min-width: 0 !important;
        white-space: nowrap !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        justify-content: flex-start !important;
        margin-top: 0.18rem !important;
    }

}
@media screen and (min-width: 40em) and (max-width: 42.9375em) {
    body:is(.is-homepage, .is-home-profile-page) .academic-home-layout .profile-card,
    body:has(.academic-home-layout) .academic-home-layout .profile-card {
        display: grid !important;
        row-gap: 0.26rem !important;
        width: 100% !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-name-wrap,
    body:has(.academic-home-layout) .profile-name-wrap,
    body:is(.is-homepage, .is-home-profile-page) .profile-actions,
    body:has(.academic-home-layout) .profile-actions,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta,
    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        grid-column: 2 !important;
        width: 100% !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-name-wrap,
    body:has(.academic-home-layout) .profile-name-wrap {
        grid-row: 1 !important;
        margin-bottom: 0.08rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-actions,
    body:has(.academic-home-layout) .profile-actions {
        grid-row: 2 !important;
        max-width: 13.5rem !important;
        margin-bottom: 0.08rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers {
        grid-row: 3 !important;
        margin-bottom: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta {
        justify-content: flex-start !important;
        margin-right: 0 !important;
        margin-bottom: 0 !important;
        margin-left: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers a,
    body:has(.academic-home-layout) .profile-followers a,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-text,
    body:has(.academic-home-layout) .profile-followers .follower-text,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-count,
    body:has(.academic-home-layout) .profile-followers .follower-count,
    body:is(.is-homepage, .is-home-profile-page) .profile-followers .follower-separator,
    body:has(.academic-home-layout) .profile-followers .follower-separator,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta li,
    body:has(.academic-home-layout) .md-typeset .profile-meta li,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta a,
    body:has(.academic-home-layout) .md-typeset .profile-meta a,
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta .meta-text,
    body:has(.academic-home-layout) .md-typeset .profile-meta .meta-text {
        min-width: 0 !important;
        white-space: nowrap !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        justify-content: flex-start !important;
        margin-top: 0.12rem !important;
    }

}
@media screen and (max-width: 35.9375em) {
    body:is(.is-homepage, .is-home-profile-page) .academic-home-layout .profile-card,
    body:has(.academic-home-layout) .academic-home-layout .profile-card {
        grid-template-columns: 5.4rem minmax(0, 1fr) !important;
        column-gap: 0.85rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-avatar,
    body:has(.academic-home-layout) .profile-avatar {
        max-width: 5.4rem !important;
    }

}
body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-followers :is(.follower-link, .follower-text, .follower-count, .follower-separator),
body:has(.academic-home-layout) .md-typeset .profile-followers :is(.follower-link, .follower-text, .follower-count, .follower-separator) {
    font-family: var(--edwinos-font-reading-sans) !important;
    font-weight: 500 !important;
    letter-spacing: 0 !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-followers .follower-count,
body:has(.academic-home-layout) .md-typeset .profile-followers .follower-count {
    font-family: var(--edwinos-font-mono) !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta :is(li, a, .meta-text),
body:has(.academic-home-layout) .md-typeset .profile-meta :is(li, a, .meta-text) {
    font-size: 0.78rem !important;
    line-height: 1.38 !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta li,
body:has(.academic-home-layout) .md-typeset .profile-meta li {
    flex: 0 0 auto !important;
    min-width: max-content !important;
    max-width: 100% !important;
    align-items: center !important;
    row-gap: 0.42rem !important;
    column-gap: 0.42rem !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta .meta-icon,
body:has(.academic-home-layout) .md-typeset .profile-meta .meta-icon {
    flex: 0 0 auto !important;
}

body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta :is(a, .meta-text),
body:has(.academic-home-layout) .md-typeset .profile-meta :is(a, .meta-text) {
    min-width: max-content !important;
    white-space: nowrap !important;
    overflow: visible !important;
    text-overflow: clip !important;
}

@media screen and (min-width: 26.0625rem) and (max-width: 59.9375rem) {
    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta {
        grid-column: 2 !important;
        grid-row: 4 !important;
        justify-self: stretch !important;
        width: 100% !important;
        min-width: 0 !important;
        flex-direction: column !important;
        flex-wrap: nowrap !important;
        align-items: flex-start !important;
        row-gap: 0.32rem !important;
        column-gap: 0.32rem !important;
        margin-top: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        grid-column: 2 !important;
        grid-row: 5 !important;
        justify-self: start !important;
        width: 100% !important;
    }

}
@media screen and (min-width: 60rem) and (max-width: 63.25em) {
    body.is-homepage .md-typeset .profile-meta {
        flex-direction: column !important;
        flex-wrap: nowrap !important;
        align-items: flex-start !important;
        justify-content: flex-start !important;
        row-gap: 0.32rem !important;
        column-gap: 0.32rem !important;
    }

}
@media screen and (max-width: 26rem) {
    body:is(.is-homepage, .is-home-profile-page) .profile-followers,
    body:has(.academic-home-layout) .profile-followers {
        grid-column: 1 / -1 !important;
        grid-row: 3 !important;
        justify-self: stretch !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-meta {
        grid-column: 1 / -1 !important;
        grid-row: 4 !important;
        justify-self: stretch !important;
        width: 100% !important;
        min-width: 0 !important;
        flex-direction: column !important;
        flex-wrap: nowrap !important;
        align-items: flex-start !important;
        row-gap: 0.32rem !important;
        column-gap: 0.32rem !important;
        margin-top: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-social-left,
    body:has(.academic-home-layout) .profile-social-left {
        grid-column: 1 / -1 !important;
        grid-row: 5 !important;
        justify-self: start !important;
        width: 100% !important;
    }

}
.academic-home-layout .profile-details {
    display: contents;
}

@media screen and (min-width: 36rem) and (max-width: 63.25rem) {
    body:is(.is-homepage, .is-home-profile-page) .academic-home-layout .profile-card,
    body:has(.academic-home-layout) .academic-home-layout .profile-card {
        grid-template-columns: 13rem minmax(0, 1fr) !important;
        grid-template-rows: auto !important;
        column-gap: 1.15rem !important;
        align-items: start !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-avatar,
    body:has(.academic-home-layout) .profile-avatar {
        grid-column: 1 !important;
        grid-row: 1 !important;
        width: 13rem !important;
        max-width: 13rem !important;
        margin: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-details,
    body:has(.academic-home-layout) .profile-details {
        grid-column: 2 !important;
        grid-row: 1 !important;
        display: flex !important;
        min-width: 0 !important;
        width: 100% !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        row-gap: 0.46rem !important;
        column-gap: 0.46rem !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-details > *,
    body:has(.academic-home-layout) .profile-details > * {
        width: 100% !important;
        margin: 0 !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-details .profile-actions,
    body:has(.academic-home-layout) .profile-details .profile-actions {
        max-width: 14rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-details .profile-followers,
    body:has(.academic-home-layout) .profile-details .profile-followers,
    body:is(.is-homepage, .is-home-profile-page) .profile-details .profile-social-left,
    body:has(.academic-home-layout) .profile-details .profile-social-left {
        justify-self: auto !important;
        text-align: left !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .md-typeset .profile-details .profile-meta,
    body:has(.academic-home-layout) .md-typeset .profile-details .profile-meta {
        display: flex !important;
        min-width: 0 !important;
        width: 100% !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        row-gap: 0.32rem !important;
        column-gap: 0.32rem !important;
    }

    body:is(.is-homepage, .is-home-profile-page) .profile-details .profile-social-left,
    body:has(.academic-home-layout) .profile-details .profile-social-left {
        margin-top: 0.06rem !important;
    }

}
body:has(.friend-links)
.md-typeset
.profile-followers
:is(.follower-link, .follower-text, .follower-count, .follower-separator) {
    font-family: var(--edwinos-font-reading-sans) !important;
    font-weight: 500 !important;
    letter-spacing: 0 !important;
}

body:has(.friend-links)
.md-typeset
.profile-followers
.follower-count {
    font-family: var(--edwinos-font-mono) !important;
}


/* Overview scroll reveal: only unseen sections below the first viewport. */
body.is-homepage .academic-home-layout:not(.academic-home-layout--subpage)
> .academic-content > [data-overview-reveal].is-overview-reveal-pending {
    opacity: 0;
    transform: translateY(16px);
}

body.is-homepage .academic-home-layout:not(.academic-home-layout--subpage)
> .academic-content > [data-overview-reveal].is-overview-reveal-visible {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s cubic-bezier(.2, .7, .3, 1),
        transform 0.8s cubic-bezier(.2, .7, .3, 1);
}

@media (prefers-reduced-motion: reduce) {
    body.is-homepage .academic-home-layout:not(.academic-home-layout--subpage)
    > .academic-content > [data-overview-reveal] {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}

@media print {
    body.is-homepage .academic-content > [data-overview-reveal] {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}

/* ==========================================================================
   Overview Prose
   ========================================================================== */

body.is-homepage .academic-home-layout:not(.academic-home-layout--subpage) > .academic-content,
body:has(.academic-home-layout) .academic-home-layout:not(.academic-home-layout--subpage) > .academic-content {
    --overview-prose-size: 14px;
    --overview-prose-leading: 1.65;
    --overview-detail-leading: 1.7;
    --overview-paragraph-gap: 10px;
    --overview-caption-size: 12px;
    --overview-row-size: 0.76rem;
    font-size: var(--overview-prose-size);
    line-height: var(--overview-prose-leading);
}

/* Type inherits from the prose container; components own their own captions.
   Paragraph spacing only matches Material's ordinary paragraph specificity. */
.academic-home-layout :where(.academic-content > .academic-section) p {
    max-width: 100%;
    margin: 0 0 var(--overview-paragraph-gap, 10px);
    color: var(--md-default-fg-color);
    -webkit-font-smoothing: antialiased;
}

.academic-home-layout :where(.academic-content > .academic-section) p:where(:last-child) {
    margin-bottom: 0;
}

@media screen and (max-width: 48em) {
    body.is-homepage .academic-home-layout:not(.academic-home-layout--subpage) > .academic-content,
    body:has(.academic-home-layout) .academic-home-layout:not(.academic-home-layout--subpage) > .academic-content {
        --overview-row-size: 0.74rem;
    }
}

/* ==========================================================================
   About Me
   ========================================================================== */

/* Only the heading and short introduction size the background; details stay independent. */
.academic-home-layout .academic-content > .about-section {
    --about-surface: var(--github-frame-light-bg);
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: max-content max-content max-content;
    isolation: isolate;
    min-height: 0;
}

[data-md-color-scheme="slate"] .academic-home-layout .academic-content > .about-section {
    --about-surface: var(--github-frame-dark-bg);
}

.academic-home-layout .about-heading {
    grid-area: 1 / 1;
    position: relative;
    z-index: 1;
}

.academic-home-layout .about-section > p {
    grid-area: 2 / 1;
    position: relative;
    z-index: 1;
    width: 100%;
}

.academic-home-layout .about-section > .about-profile-details {
    grid-area: 3 / 1;
    position: relative;
    z-index: 1;
}

.academic-home-layout .about-background {
    grid-area: 1 / 1 / 3 / 2;
    position: relative;
    z-index: 0;
    align-self: stretch;
    justify-self: end;
    /* Align the photo with the right edge of the content sections. */
    right: 0;
    width: 100%;
    min-width: 0;
    min-height: 0;
    contain: size;
    overflow: hidden;
    pointer-events: none;
    /* Keep the fade attached to the visible field, not the cropped photo. */
    -webkit-mask-image: linear-gradient(to right, transparent 0% 8%, rgb(0 0 0 / 5%) 14%, rgb(0 0 0 / 22%) 22%, rgb(0 0 0 / 53%) 32%, rgb(0 0 0 / 80%) 44%, rgb(0 0 0 / 95%) 58%, rgb(0 0 0 / 99.5%) 74%, #000 88% 100%);
    mask-image: linear-gradient(to right, transparent 0% 8%, rgb(0 0 0 / 5%) 14%, rgb(0 0 0 / 22%) 22%, rgb(0 0 0 / 53%) 32%, rgb(0 0 0 / 80%) 44%, rgb(0 0 0 / 95%) 58%, rgb(0 0 0 / 99.5%) 74%, #000 88% 100%);
}

.academic-home-layout .about-background::after {
    content: "";
    position: absolute;
    z-index: 3;
    inset: 0;
    background: linear-gradient(to right, color-mix(in srgb, var(--about-surface) 65%, transparent), color-mix(in srgb, var(--about-surface) 45%, transparent) 30%, color-mix(in srgb, var(--about-surface) 22%, transparent) 65%, color-mix(in srgb, var(--about-surface) 8%, transparent));
    pointer-events: none;
}

/* Keep a broad landscape crop: growing prose reveals its vertical field. */
.academic-home-layout .about-photo {
    position: absolute;
    top: 0;
    right: 0;
    display: block;
    width: 900px;
    height: 100%;
    max-width: none;
    overflow: hidden;
    pointer-events: none;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, rgb(0 0 0 / 3%) 4%, rgb(0 0 0 / 12%) 10%, rgb(0 0 0 / 28%) 18%, rgb(0 0 0 / 50%) 27%, rgb(0 0 0 / 72%) 36%, rgb(0 0 0 / 90%) 47%, rgb(0 0 0 / 98%) 58%, #000 68%);
    mask-image: linear-gradient(to right, transparent 0%, rgb(0 0 0 / 3%) 4%, rgb(0 0 0 / 12%) 10%, rgb(0 0 0 / 28%) 18%, rgb(0 0 0 / 50%) 27%, rgb(0 0 0 / 72%) 36%, rgb(0 0 0 / 90%) 47%, rgb(0 0 0 / 98%) 58%, #000 68%);
}

.academic-home-layout .about-photo > img {
    position: relative;
    z-index: 0;
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: right 36%;
    border-radius: 0;
    filter: blur(1.25px) saturate(0.8) brightness(1.12);
    opacity: 0.54;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, rgb(0 0 0 / 4%) 2%, rgb(0 0 0 / 16%) 4%, rgb(0 0 0 / 50%) 7%, rgb(0 0 0 / 84%) 10%, rgb(0 0 0 / 96%) 12%, #000 14%);
    mask-image: linear-gradient(to bottom, transparent 0%, rgb(0 0 0 / 4%) 2%, rgb(0 0 0 / 16%) 4%, rgb(0 0 0 / 50%) 7%, rgb(0 0 0 / 84%) 10%, rgb(0 0 0 / 96%) 12%, #000 14%);
}

/* Static blur fields sample only this photo, below the crisp article copy.
   Each field eases to zero before the camera and face on the clear right side. */
.academic-home-layout .about-photo::before,
.academic-home-layout .about-photo::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.academic-home-layout .about-photo::before {
    z-index: 1;
    background: color-mix(in srgb, var(--about-surface) 8%, transparent);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    -webkit-mask-image: linear-gradient(to right, #000 0% 14%, rgb(0 0 0 / 85%) 24%, rgb(0 0 0 / 50%) 34%, rgb(0 0 0 / 15%) 46%, transparent 58% 100%);
    mask-image: linear-gradient(to right, #000 0% 14%, rgb(0 0 0 / 85%) 24%, rgb(0 0 0 / 50%) 34%, rgb(0 0 0 / 15%) 46%, transparent 58% 100%);
}

.academic-home-layout .about-photo::after {
    z-index: 2;
    background: color-mix(in srgb, var(--about-surface) 10%, transparent);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    -webkit-mask-image: linear-gradient(to right, #000 0% 5%, rgb(0 0 0 / 85%) 10%, rgb(0 0 0 / 50%) 17%, rgb(0 0 0 / 15%) 24%, transparent 32% 100%);
    mask-image: linear-gradient(to right, #000 0% 5%, rgb(0 0 0 / 85%) 10%, rgb(0 0 0 / 50%) 17%, rgb(0 0 0 / 15%) 24%, transparent 32% 100%);
}

@media (max-width: 680px) {
    .academic-home-layout .about-photo > img {
        opacity: 0.46;
    }

    [data-md-color-scheme="slate"] .academic-home-layout .about-photo > img {
        opacity: 0.42;
    }
}

.academic-home-layout .academic-content .about-profile-details {
    margin: 14px 0 0;
    padding: 0;
    color: var(--academic-ink);
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    font-family: var(--edwinos-font-reading-sans);
    font-size: var(--overview-prose-size);
    line-height: var(--overview-detail-leading);
}

.academic-home-layout .academic-content .about-profile-details > summary {
    position: static;
    display: list-item;
    min-height: 0;
    margin: 0;
    padding: 0;
    color: #7a7e87;
    background: transparent;
    border: 0;
    border-radius: 0;
    font-family: var(--edwinos-font-reading-sans);
    font-size: 11.5px;
    font-weight: 500;
    line-height: 1.65;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    list-style: none;
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
    transition: color 0.2s;
}

.academic-home-layout .academic-content .about-profile-details > summary::-webkit-details-marker {
    display: none;
}

.academic-home-layout .academic-content .about-profile-details > summary::marker {
    content: "";
}

.academic-home-layout .academic-content .about-profile-details > summary::before {
    content: "+ ";
    position: static;
    display: inline;
    width: auto;
    height: auto;
    margin: 0;
    color: #0b57d0;
    background: none;
    -webkit-mask: none;
    mask: none;
    transform: none;
}

.academic-home-layout .academic-content .about-profile-details[open] > summary::before {
    content: "– ";
}

.academic-home-layout .academic-content .about-profile-details > summary::after {
    content: none;
    display: none;
}

.academic-home-layout .academic-content .about-profile-details > summary:hover {
    color: #121317;
}

.academic-home-layout .academic-content .about-profile-details > summary:focus-visible {
    outline: 2px solid var(--academic-accent);
    outline-offset: 4px;
}

.academic-home-layout .academic-content .about-profile-details > .about-profile-body {
    margin: 12px 0 0;
}

/* Reveal the authored reading blocks in sequence whenever the profile opens. */
@media (prefers-reduced-motion: no-preference) {
    .academic-home-layout .about-profile-details[open] > .about-profile-body > :is(p, ul, hr),
    .academic-home-layout .about-profile-details[open] > .about-profile-body > [lang="zh-CN"] > :is(p, ul) {
        animation: edwinos-profile-paragraph-in 420ms cubic-bezier(0.22, 0.7, 0.3, 1) both;
        animation-delay: calc(var(--profile-reveal-order, 0) * 70ms);
    }

    @keyframes edwinos-profile-paragraph-in {
        from {
            opacity: 0;
            transform: translateY(12px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}

body[data-md-color-scheme="slate"] .academic-home-layout .academic-content .about-profile-details > summary {
    color: var(--academic-muted);
}

body[data-md-color-scheme="slate"] .academic-home-layout .academic-content .about-profile-details > summary::before {
    color: var(--academic-accent);
}

body[data-md-color-scheme="slate"] .academic-home-layout .academic-content .about-profile-details > summary:hover {
    color: var(--academic-ink);
}

@media (max-width: 680px) {
    .academic-home-layout .academic-content .about-profile-details > summary {
        text-align: center;
    }
}

body.is-homepage .academic-content > .academic-section:first-of-type p,
body.is-homepage .academic-content > .academic-section:first-of-type li,
body:has(.academic-home-layout) .academic-content > .academic-section:first-of-type p,
body:has(.academic-home-layout) .academic-content > .academic-section:first-of-type li {
    color: #1a1a1a !important;
    font-weight: 400 !important;
    letter-spacing: 0 !important;
}

body.is-homepage .academic-content > .academic-section:first-of-type .about-name-cn,
body:has(.academic-home-layout) .academic-content > .academic-section:first-of-type .about-name-cn {
    font-family: inherit !important;
}

body.is-homepage .academic-content > .academic-section:first-of-type > p,
body:has(.academic-home-layout) .academic-content > .academic-section:first-of-type > p {
    max-width: 76ch;
    font-size: 15px;
    line-height: 1.75;
    margin-bottom: 0 !important;
}

.academic-home-layout .academic-content .about-profile-body > :last-child,
.academic-home-layout .academic-content .about-profile-body > [lang="zh-CN"] > :last-child {
    margin-bottom: 0 !important;
}

.academic-home-layout .academic-content .about-profile-body ul {
    margin-block: 8px !important;
}

.academic-home-layout .academic-content .about-profile-body li {
    margin-block: 0 4px !important;
}

.academic-home-layout .academic-content .about-profile-body li:last-child {
    margin-bottom: 0 !important;
}

.academic-home-layout .academic-content .about-profile-body hr {
    height: 0;
    margin: 12px 0 !important;
    border: 0;
    border-top: 1px solid var(--md-default-fg-color--lightest);
}

body.is-homepage .academic-content > .academic-section:first-of-type strong,
body:has(.academic-home-layout) .academic-content > .academic-section:first-of-type strong {
    color: inherit !important;
    background: none !important;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    font-family: inherit !important;
    font-weight: 600 !important;
}

body.is-homepage .academic-content > .academic-section:first-of-type a,
body:has(.academic-home-layout) .academic-content > .academic-section:first-of-type a {
    color: #2563eb !important;
    text-decoration: none !important;
    border-bottom: 0 !important;
}

body.is-homepage .academic-content > .academic-section:first-of-type a:hover,
body:has(.academic-home-layout) .academic-content > .academic-section:first-of-type a:hover {
    color: #1d4ed8 !important;
    text-decoration: underline 1px !important;
    text-underline-offset: 3px;
    border-bottom: 0 !important;
}

body[data-md-color-scheme="slate"].is-homepage .academic-content > .academic-section:first-of-type p,
body[data-md-color-scheme="slate"].is-homepage .academic-content > .academic-section:first-of-type li,
body[data-md-color-scheme="slate"]:has(.academic-home-layout) .academic-content > .academic-section:first-of-type p,
body[data-md-color-scheme="slate"]:has(.academic-home-layout) .academic-content > .academic-section:first-of-type li {
    color: #e6edf3 !important;
}

body[data-md-color-scheme="slate"].is-homepage .academic-content > .academic-section:first-of-type a,
body[data-md-color-scheme="slate"]:has(.academic-home-layout) .academic-content > .academic-section:first-of-type a {
    color: #58a6ff !important;
}

body[data-md-color-scheme="slate"].is-homepage .academic-content > .academic-section:first-of-type a:hover,
body[data-md-color-scheme="slate"]:has(.academic-home-layout) .academic-content > .academic-section:first-of-type a:hover {
    color: #79c0ff !important;
}


/* ========================================================================
   Education rows (Tianxing Chen reference layout)
   ======================================================================== */
.academic-home-layout .overview-education-list {
    margin: 0 !important;
    padding: 0 !important;
    list-style: none;
}
.academic-home-layout .overview-education-list > .overview-education-item {
    margin-inline: 0 !important;
}
.academic-home-layout .overview-education-item {
    display: grid; grid-template-columns: 200px minmax(0, 1fr) max-content;
    gap: 16px 28px; align-items: center; padding: 16px 0;
    border-top: 1px solid var(--academic-card-border);
    font-size: var(--overview-row-size, 0.76rem);
    line-height: 1.48;
}
.academic-home-layout .overview-education-item:last-child {
    border-bottom: 1px solid var(--academic-card-border);
}
.academic-home-layout .overview-education-logo { width: 200px; }
.academic-home-layout .overview-education-logo img { display: block; width: 180px; max-width: 100%; height: auto; object-fit: contain; }
/* Preserve the university's blue artwork on a quiet light field at night.
   The painted surround does not change image dimensions or preload geometry. */
body[data-md-color-scheme="slate"] .academic-home-layout .overview-education-logo img {
    background: #edf2f7;
    border-radius: 4px;
    box-shadow: 0 0 0 7px #edf2f7;
}
.academic-home-layout .overview-education-content { display: grid; gap: 3px; min-width: 0; }
.academic-home-layout .overview-education-school { font-size: 17px; font-weight: 500; line-height: 1.65; }
.academic-home-layout .overview-education-school a,
.academic-home-layout .overview-education-dept a {
    color: var(--academic-accent) !important; text-decoration: none !important; border-bottom: 0 !important; transition: color .2s ease, text-decoration-color .2s ease;
}
.academic-home-layout .overview-education-school a:hover,
.academic-home-layout .overview-education-dept a:hover {
    color: #1d4ed8 !important; text-decoration: underline !important; text-underline-offset: 3px; border-bottom: 0 !important; background: transparent !important;
}
.academic-home-layout .overview-education-dept { color: var(--academic-ink); font-size: 13.5px; line-height: 1.5; }
.academic-home-layout .overview-education-degree { color: var(--academic-muted); font-size: 13px; line-height: 1.65; }
.academic-home-layout .overview-education-side { display: grid; align-self: center; gap: 4px; text-align: right; }
.academic-home-layout .overview-education-years,
.academic-home-layout .overview-education-place { color: var(--academic-muted); font-size: 12.5px; font-weight: 400; line-height: 1.55; white-space: nowrap; }
.academic-home-layout .overview-education-place { line-height: 1.4; }
@media screen and (max-width: 48em) {
    .academic-home-layout .overview-education-item { grid-template-columns: 5.4rem minmax(0, 1fr) max-content; gap: 12px 16px; }
    .academic-home-layout .overview-education-logo { width: 5.4rem; }
    .academic-home-layout .overview-education-logo img { width: 4.8rem; }
}
@media screen and (max-width: 680px) {
    .academic-home-layout .overview-education-item { grid-template-columns: minmax(0, 1fr) max-content; gap: 16px 1em; }
    .academic-home-layout .overview-education-side {
        grid-column: 2; grid-row: 1; justify-self: end; max-width: 100%;
        gap: 4px;
    }
    .academic-home-layout .overview-education-years { white-space: normal; }
    .academic-home-layout .overview-education-logo { display: block; grid-column: 1; grid-row: 1; width: 100%; }
    .academic-home-layout .overview-education-logo img {
        width: 80%; margin-left: 0;
        /* Align the visible seal: the source has 22px of left padding in 1458px. */
        transform: translateX(-1.509%);
    }
    .academic-home-layout .overview-education-content { grid-column: 1 / -1; grid-row: 2; }
}

/* Native images paint as soon as ready, including cache-restored documents.
   Preview underlays reserve geometry and retire after decoding; they never
   gate a loaded thumbnail behind runtime initialization or a fresh fade. */
.academic-home-layout [data-progressive-image] {
    position: relative;
}

.academic-home-layout [data-progressive-image]::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: var(--progressive-preview);
    background-position: center;
    background-size: contain;
    background-repeat: no-repeat;
    opacity: 0;
}

.academic-home-layout .overview-education-logo [data-progressive-full] {
    aspect-ratio: 720 / 263;
}

.academic-home-layout .overview-workshop__media [data-progressive-full] {
    aspect-ratio: 1550 / 1000;
}

.academic-home-layout .overview-education-logo[data-progressive-image]::before {
    width: 180px;
    max-width: 100%;
}

html.js .academic-home-layout [data-progressive-image]:not(.is-ready):not(.is-error)::before {
    opacity: 1;
}

html.js .academic-home-layout [data-progressive-image] [data-progressive-full] {
    position: relative;
    opacity: 1;
}

@media screen and (max-width: 48em) {
    .academic-home-layout .overview-education-logo[data-progressive-image]::before {
        width: 4.8rem;
    }
}

@media screen and (max-width: 680px) {
    .academic-home-layout .overview-education-logo[data-progressive-image]::before {
        width: 80%;
        transform: translateX(-1.509%);
    }
}

/* ==========================================================================
   Recent News first-line alignment
   ========================================================================== */

.academic-home-layout .news-list {
    margin-inline: 0 !important;
    padding-inline: 0 !important;
    list-style: none !important;
    border-top: 1px solid var(--academic-card-border);
}

body:is(.is-homepage, .is-home-profile-page) .news-list li,
body:has(.academic-home-layout) .news-list li {
    font-size: var(--overview-row-size, 0.76rem);
    line-height: 1.48;
    display: grid !important;
    grid-template-columns: 72px minmax(0, 1fr) !important;
    column-gap: 14px !important;
    row-gap: 0 !important;
    align-items: baseline !important;
    align-items: first baseline !important;
    padding: 7px 0 !important;
}

body:is(.is-homepage, .is-home-profile-page) .news-date,
body:has(.academic-home-layout) .news-date,
body:is(.is-homepage, .is-home-profile-page) .news-text,
body:has(.academic-home-layout) .news-text {
    display: block !important;
    margin-top: 0 !important;
}

body:is(.is-homepage, .is-home-profile-page) .news-date,
body:has(.academic-home-layout) .news-date {
    align-self: baseline !important;
    align-self: first baseline !important;
    color: var(--academic-date) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    letter-spacing: 0.02em !important;
    line-height: 1.65 !important;
    white-space: nowrap !important;
}

body:is(.is-homepage, .is-home-profile-page) .news-text,
body:has(.academic-home-layout) .news-text {
    align-self: baseline !important;
    align-self: first baseline !important;
    min-width: 0 !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 13.5px !important;
    font-weight: 400 !important;
    line-height: 1.5 !important;
}

.academic-home-layout .overview-news-inline-link {
    color: var(--academic-accent) !important;
    font: inherit;
    font-weight: 500;
    text-decoration: none !important;
    border-bottom: 0 !important;
}

.academic-home-layout .overview-news-inline-link:hover {
    color: var(--academic-accent) !important;
    text-decoration: underline 1px !important;
    text-underline-offset: 3px;
    background: transparent !important;
}

.academic-home-layout .overview-news-links {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    margin-left: 0.35rem;
}

.academic-home-layout .overview-news-links a {
    color: var(--academic-accent) !important;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.18em;
}

.academic-home-layout .overview-news-more {
    margin-top: 0.55rem;
}

.academic-home-layout .overview-news-more > summary {
    width: fit-content;
    margin-left: 6rem;
    color: var(--academic-muted);
    font-family: var(--edwinos-font-reading-sans);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    list-style: none;
}

.academic-home-layout .overview-news-more > summary::-webkit-details-marker {
    display: none;
}

.academic-home-layout .overview-news-more .when-open,
.academic-home-layout .overview-news-more[open] .when-closed {
    display: none;
}

.academic-home-layout .overview-news-more[open] .when-open {
    display: inline;
}

.academic-home-layout .overview-news-list--older {
    margin-top: 0.4rem !important;
}

@media screen and (max-width: 680px) {
    body.is-homepage .academic-home-layout .news-list li {
        grid-template-columns: 56px minmax(0, 1fr) !important;
        column-gap: 10px !important;
    }
}

/* ==========================================================================
   Overview Publications
   ========================================================================== */

.academic-home-layout .overview-publication-list {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.academic-home-layout .overview-publication {
    position: relative;
    display: grid !important;
    grid-template-columns: 9.5rem minmax(0, 1fr) !important;
    gap: 1rem !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 12px 10px !important;
    border-bottom: 1px solid var(--academic-card-border);
    background: transparent;
    list-style: none !important;
    font-size: var(--overview-row-size, 0.76rem);
    line-height: 1.48;
    transition: background-color 160ms ease;
}

.academic-home-layout .overview-publication:first-child {
    border-top: 1px solid var(--academic-card-border);
}

.academic-home-layout .overview-publication.is-lead {
    background: color-mix(in srgb, var(--academic-accent) 5%, transparent);
    box-shadow: inset 2px 0 color-mix(in srgb, var(--academic-accent) 44%, transparent);
}

@media (hover: hover) and (pointer: fine) {
    .academic-home-layout .overview-publication:hover {
        background: color-mix(in srgb, var(--academic-accent) 4%, transparent);
    }

    .academic-home-layout .overview-publication.is-lead:hover {
        background: color-mix(in srgb, var(--academic-accent) 8%, transparent);
    }
}

.academic-home-layout .overview-publication__media {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 1px solid var(--academic-card-border);
    border-radius: 0.55rem;
    background: var(--academic-soft);
}

.academic-home-layout .overview-publication__media img {
    display: block;
    width: 100%;
    height: auto;
    margin: 0 !important;
    object-fit: contain;
}

/* Optional motion stays above the existing native image, never in its place. */
.academic-home-layout .overview-publication__media--preview {
    position: relative;
    isolation: isolate;
}

.academic-home-layout .overview-publication__preview {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: var(--academic-soft);
    opacity: 0;
    pointer-events: none;
    transition: opacity 120ms ease;
}

.academic-home-layout .is-preview-playing > .overview-publication__preview {
    opacity: 1;
}

.academic-home-layout .overview-publication__preview-toggle {
    position: absolute;
    z-index: 1;
    right: 5px;
    bottom: 5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    min-height: 32px;
    padding: 4px 9px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 999px;
    background: rgba(20, 26, 34, 0.84);
    color: #fff;
    font: 500 11px/1.2 var(--edwinos-font-reading-sans);
    cursor: pointer;
}

.academic-home-layout .overview-publication__preview-toggle[hidden] {
    display: none;
}

.academic-home-layout .overview-publication__preview-toggle:focus-visible {
    outline: 2px solid var(--academic-accent);
    outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
    .academic-home-layout .overview-publication__preview {
        transition: none;
    }
}

.academic-home-layout .overview-publication__media--placeholder {
    aspect-ratio: 7 / 4;
    color: var(--academic-accent);
    background:
        linear-gradient(
            135deg,
            color-mix(in srgb, var(--academic-accent) 10%, transparent),
            color-mix(in srgb, var(--academic-accent) 3%, transparent)
        ),
        var(--academic-soft);
    font-family: var(--edwinos-font-reading-sans);
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.academic-home-layout .overview-publication__body {
    min-width: 0;
}

.academic-home-layout .md-typeset .overview-publication__title,
.academic-home-layout .overview-publication__title {
    margin: 0 !important;
    color: var(--academic-ink) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 16px !important;
    font-weight: 500 !important;
    line-height: 1.42 !important;
    letter-spacing: -0.015em !important;
}

body.is-homepage .academic-home-layout .overview-publication__authors,
body.is-homepage .academic-home-layout .overview-publication__authors-full {
    -webkit-user-select: none;
    user-select: none;
    margin: 3px 0 0 !important;
    color: var(--academic-muted) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 12.5px !important;
    font-weight: 400 !important;
    line-height: 1.45 !important;
}

.academic-home-layout .overview-publication__author {
    color: inherit !important;
    font-family: inherit !important;
    font-weight: 400 !important;
    text-decoration: none !important;
}

.academic-home-layout .overview-publication__author.is-self {
    color: var(--academic-ink) !important;
    padding: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    font-weight: 600 !important;
}

.academic-home-layout a.overview-publication__author:hover {
    color: var(--academic-accent) !important;
    text-decoration: underline !important;
    text-underline-offset: 0.17em;
}

.academic-home-layout .overview-publication__authors-toggle {
    appearance: none;
    display: inline;
    margin-left: 6px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--academic-ink);
    font-family: inherit;
    font-size: 12px;
    font-weight: 500;
    line-height: inherit;
    white-space: nowrap;
    text-decoration: none;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;
    cursor: pointer;
}

.academic-home-layout .overview-publication__authors-toggle:hover {
    color: var(--academic-ink);
    text-decoration: underline;
}

.academic-home-layout .overview-publication__authors .when-open,
.academic-home-layout .overview-publication__authors.is-expanded .when-closed {
    display: none;
}

.academic-home-layout .overview-publication__authors-full {
    display: none;
}

.academic-home-layout .overview-publication__authors.is-expanded .when-open,
.academic-home-layout .overview-publication__authors.is-expanded .overview-publication__authors-full {
    display: inline;
}

.academic-home-layout .overview-publication__authors.is-expanded .overview-publication__authors-short {
    display: none;
}

.academic-home-layout .overview-publication__venue {
    -webkit-user-select: none;
    user-select: none;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.28rem 0.5rem;
    margin-top: 4px;
    font-family: var(--edwinos-font-reading-sans);
    line-height: 1.35;
}

.academic-home-layout .overview-publication__venue-name {
    color: var(--academic-accent);
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.academic-home-layout .overview-publication__venue-meta {
    color: var(--academic-muted);
    font-size: 11.5px;
    font-weight: 400;
}

.academic-home-layout .overview-publication__award {
    margin: 4px 0 0 !important;
    color: #cf222e !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 11.5px !important;
    font-weight: 500 !important;
    line-height: 1.35 !important;
}

[data-md-color-scheme="slate"] .academic-home-layout .overview-publication__award {
    color: #ff7b72 !important;
}

.academic-home-layout .overview-publication__links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 2px 0;
    margin-top: 6px;
    font-family: var(--edwinos-font-reading-sans);
    font-size: 12.5px;
    font-weight: 500;
}

body.is-homepage .academic-home-layout .overview-publication__links a {
    position: relative;
    display: inline-block !important;
    border-bottom: 0 !important;
    color: var(--academic-ink) !important;
    line-height: 1.65 !important;
    text-decoration-line: underline !important;
    text-decoration-thickness: 1px !important;
    letter-spacing: 0.01em;
    text-decoration-color: color-mix(in srgb, var(--academic-ink) 22%, transparent) !important;
    text-underline-offset: 3px;
}

body.is-homepage .academic-home-layout .overview-publication__links a:hover {
    color: var(--academic-ink) !important;
    text-decoration-color: var(--academic-ink) !important;
}

.academic-home-layout .overview-publication__links a + a {
    margin-left: 0.62rem;
    padding-left: 0.62rem;
}

.academic-home-layout .overview-publication__links a + a::before {
    content: "";
    position: absolute;
    top: 0.12em;
    bottom: 0.12em;
    left: 0;
    width: 1px;
    background: var(--academic-card-border);
}

.academic-home-layout .overview-publication-notes {
    margin: 16px 0 0;
    color: var(--academic-muted) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: var(--overview-caption-size, 12px);
    font-weight: 400;
    line-height: 1.65;
}

.academic-home-layout .overview-section-empty {
    margin: 0.52rem 0 0 !important;
    color: var(--academic-muted) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 12px !important;
    line-height: 1.45 !important;
}

@media screen and (max-width: 42.5rem) {
    .academic-home-layout .overview-publication {
        grid-template-columns: 6.5rem minmax(0, 1fr) !important;
        gap: 12px !important;
        align-items: center !important;
        padding: 12px 8px !important;
    }

    .academic-home-layout .overview-publication__media {
        width: 100%;
    }

    .academic-home-layout .md-typeset .overview-publication__title,
    .academic-home-layout .overview-publication__title {
        font-size: 14.5px !important;
    }

    body.is-homepage .academic-home-layout .overview-publication__authors,
    body.is-homepage .academic-home-layout .overview-publication__authors-full {
        font-size: 12px !important;
    }

    .academic-home-layout .overview-news-more > summary {
        margin-left: 0;
    }
}

@media screen and (max-width: 26.25rem) {
    .academic-home-layout .overview-publication {
        grid-template-columns: 5.75rem minmax(0, 1fr) !important;
        gap: 10px !important;
        padding: 10px 0 !important;
    }

    .academic-home-layout .overview-publication__media {
        width: 100%;
    }

}

/* ==========================================================================
   Workshop Contributions & Presentations
   ========================================================================== */

.academic-home-layout .overview-workshop {
    display: grid;
    grid-template-columns: 8.75rem minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
    min-width: 0;
    padding: 12px 10px;
    border-top: 1px solid var(--academic-card-border);
}

.academic-home-layout .overview-workshop:last-child {
    border-bottom: 1px solid var(--academic-card-border);
}

.academic-home-layout .overview-workshop__body {
    min-width: 0;
}

body.is-homepage .academic-home-layout .overview-workshop__event {
    margin: 0 0 4px !important;
    color: var(--academic-accent) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 11.5px !important;
    font-weight: 600 !important;
    letter-spacing: 0.05em !important;
    line-height: 1.35 !important;
}

body.is-homepage .academic-home-layout .overview-workshop__event a {
    color: inherit !important;
    font: inherit;
    padding: 0 !important;
    text-decoration: none !important;
    border-bottom: 0 !important;
    background: transparent !important;
}

body.is-homepage .academic-home-layout .overview-workshop__event a:hover {
    color: inherit !important;
    text-decoration: underline 1px !important;
    text-underline-offset: 3px;
    border-bottom: 0 !important;
    background: transparent !important;
}

.academic-home-layout .md-typeset .overview-workshop__title,
.academic-home-layout .overview-workshop__title {
    margin: 0 !important;
    color: var(--academic-ink) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 16px !important;
    font-weight: 500 !important;
    line-height: 1.3 !important;
    letter-spacing: -0.015em !important;
}

.md-typeset .academic-home-layout .overview-workshop__authors {
    display: block;
    margin: 3px 0 0 !important;
    padding: 0;
    overflow: visible;
    color: var(--academic-muted) !important;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 12.5px !important;
    font-weight: 400 !important;
    line-height: 1.45 !important;
}

.academic-home-layout .overview-workshop__authors,
.academic-home-layout .overview-workshop__authors-full {
    margin: 3px 0 0 !important;
    color: var(--academic-muted) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 12.5px !important;
    font-weight: 400 !important;
    line-height: 1.45 !important;
}

.academic-home-layout .overview-workshop__authors strong {
    color: var(--academic-ink) !important;
    padding: 0.05em 0.3em;
    border-radius: 0.24rem;
    background: color-mix(in srgb, var(--academic-muted) 22%, transparent);
    font-family: inherit !important;
    font-weight: 600 !important;
    white-space: nowrap;
}

.academic-home-layout :is(.overview-publication__authors-ellipsis, .overview-workshop .authors-ellipsis) {
    color: var(--academic-muted);
    letter-spacing: 0.06em;
    user-select: none;
}

.academic-home-layout .overview-workshop__authors-toggle {
    display: inline;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    cursor: pointer;
    vertical-align: baseline;
    margin-left: 6px;
    color: var(--academic-ink);
    font-family: inherit;
    font-size: 12px;
    font-weight: 500;
    line-height: inherit;
    white-space: nowrap;
    text-decoration: none;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;
}

.academic-home-layout .overview-workshop__authors-toggle:hover {
    text-decoration: underline;
}

.academic-home-layout .overview-workshop__authors-full,
.academic-home-layout .overview-workshop__authors .when-open,
.academic-home-layout .overview-workshop__authors.is-expanded .when-closed,
.academic-home-layout .overview-workshop__authors.is-expanded .overview-workshop__authors-short {
    display: none;
}

.academic-home-layout .overview-workshop__authors.is-expanded .when-open,
.academic-home-layout .overview-workshop__authors.is-expanded .overview-workshop__authors-full {
    display: inline;
}

body.is-homepage .academic-home-layout .overview-workshop__status {
    -webkit-user-select: none;
    user-select: none;
    margin: 6px 0 0 !important;
    color: var(--academic-ink) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 13.5px !important;
    font-weight: 400 !important;
    line-height: 1.5 !important;
}

body.is-homepage .academic-home-layout .overview-workshop__meta {
    -webkit-user-select: none;
    user-select: none;
    margin: 4px 0 0 !important;
    color: var(--academic-muted) !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 12.5px !important;
    font-weight: 500 !important;
    letter-spacing: 0.04em !important;
    line-height: 1.4 !important;
}

@media screen and (max-width: 42.5rem) {
    .academic-home-layout .overview-workshop {
        grid-template-columns: 6rem minmax(0, 1fr);
        gap: 12px;
        padding: 12px 8px;
    }

    .academic-home-layout .md-typeset .overview-workshop__title,
    .academic-home-layout .overview-workshop__title {
        font-size: 14.5px !important;
    }

    body.is-homepage .academic-home-layout .overview-workshop__authors,
    body.is-homepage .academic-home-layout .overview-workshop__authors-full {
        font-size: 12px !important;
    }
}

@media screen and (max-width: 26.25rem) {
    .academic-home-layout .overview-workshop {
        grid-template-columns: 5rem minmax(0, 1fr);
        gap: 10px;
        padding: 10px 0;
    }
}

/* ==========================================================================
   Awards
   ========================================================================== */

.academic-home-layout .award-list {
    margin-inline: 0 !important;
    padding-inline: 0 !important;
    list-style: none !important;
    border-top: 1px solid var(--academic-card-border);
}

.academic-home-layout .award-list > li {
    font-size: var(--overview-row-size, 0.76rem);
    line-height: 1.48;
    grid-template-columns: 52px minmax(0, 1fr);
    column-gap: 12px;
    margin-block: 0;
    margin-inline: 0 !important;
    padding-block: 6px;
}

body.is-homepage .academic-home-layout .award-list .award-year,
body:has(.academic-home-layout) .academic-home-layout .award-list .award-year {
    line-height: 1.45 !important;
}

@media screen and (max-width: 680px) {
    .academic-home-layout .award-list > li {
        grid-template-columns: 44px minmax(0, 1fr);
        gap: 10px;
        padding-block: 9px;
    }
}

/* ==========================================================================
   Experiences Rows
   ========================================================================== */


.academic-home-layout .cv-lab-content {
    container: cv-lab / inline-size;
}

.academic-home-layout .cv-lab-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 3px 12px;
    padding: 14px 0;
}

.academic-home-layout .cv-lab-main {
    display: contents;
    min-width: 0;
}

.academic-home-layout .cv-lab-row :is(.cv-title, .cv-subtitle, .cv-time) {
    margin: 0 !important;
}

.academic-home-layout .cv-lab-row .cv-title {
    grid-column: 1;
    grid-row: 2;
    min-width: 0;
}

.academic-home-layout .cv-lab-row .cv-subtitle {
    grid-column: 1 / -1;
    grid-row: 3;
    min-width: 0;
}

body.is-homepage .academic-home-layout .cv-lab-row .cv-title a {
    color: var(--academic-accent) !important;
    font: inherit;
    padding: 0 !important;
    text-decoration: none !important;
    border-bottom: 0 !important;
    background: transparent !important;
}

body.is-homepage .academic-home-layout .cv-lab-row .cv-title a:hover {
    color: var(--academic-accent) !important;
    text-decoration: underline 1px !important;
    text-underline-offset: 3px;
    border-bottom: 0 !important;
    background: transparent !important;
}

.academic-home-layout .cv-lab-logo {
    grid-column: 1 / -1;
    grid-row: 1;
    display: grid;
    place-items: center;
    width: 190px;
    max-width: 100%;
    aspect-ratio: 461 / 70;
    margin-bottom: 9px;
}

.academic-home-layout .cv-lab-logo img {
    grid-area: 1 / 1;
    display: block;
    width: 100%;
    height: auto;
    margin: 0;
    object-fit: contain;
}

.academic-home-layout .cv-lab-logo .cv-lab-logo__dark {
    display: none;
}

body[data-md-color-scheme="slate"] .academic-home-layout .cv-lab-logo .cv-lab-logo__light {
    display: none;
}

body[data-md-color-scheme="slate"] .academic-home-layout .cv-lab-logo .cv-lab-logo__dark {
    display: block;
}

.academic-home-layout .cv-lab-row .cv-time {
    grid-column: 2;
    grid-row: 2;
    justify-self: end;
    text-align: right;
    white-space: nowrap;
}

@media screen and (min-width: 961px) {
    @container cv-lab (min-width: 760px) {
        .academic-home-layout .cv-lab-row {
            grid-template-columns: 240px minmax(0, 1fr) auto;
            gap: 28px;
            padding: 16px 0;
        }

        .academic-home-layout .cv-lab-logo {
            grid-column: 1;
            grid-row: 1;
            width: 240px;
            height: 80px;
            aspect-ratio: auto;
            margin-bottom: 0;
        }

        .academic-home-layout .cv-lab-main {
            display: flex;
            flex-direction: column;
            grid-column: 2;
            grid-row: 1;
            gap: 3px;
        }

        .academic-home-layout .cv-lab-logo img {
            width: 220px;
            max-width: 100%;
            max-height: 68px;
        }

        .academic-home-layout .cv-lab-row .cv-time {
            grid-column: 3;
            grid-row: 1;
            justify-self: end;
            text-align: right;
            white-space: nowrap;
        }
    }
}

body:is(.is-homepage, .is-home-profile-page) .cv-experience-list,
body:has(.academic-home-layout) .cv-experience-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 0.2rem;
    padding: 0;
}

body:is(.is-homepage, .is-home-profile-page) .cv-item,
body:has(.academic-home-layout) .cv-item {
    position: relative !important;
    padding-left: 0 !important;
}

.academic-home-layout .cv-experience-list > .cv-item > .cv-content {
    border-bottom: 1px solid var(--academic-card-border);
}

.academic-home-layout .cv-experience-list > .cv-item:first-child > .cv-content {
    border-top: 1px solid var(--academic-card-border);
}


/* ==========================================================================
   Article Headings
   ========================================================================== */

/* Publication context for individual ENotes and More articles.
   The build hook places this directly after the page title. */
.md-content__inner.md-typeset > h1:has(+ .article-meta) {
    margin-bottom: 0.42rem;
}

.md-content__inner.md-typeset > .article-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.18rem 0.42rem;
    margin: 0 0 1.35rem;
    color: var(--md-default-fg-color--light);
    font-family: var(--edwinos-font-serif);
    font-size: 0.64rem;
    font-weight: 400;
    line-height: 1.55;
    letter-spacing: 0.01em;
}

.md-content__inner.md-typeset > .article-meta time {
    color: var(--md-default-fg-color);
    font-variant-numeric: tabular-nums;
}

.md-content__inner.md-typeset > .article-meta .article-meta__author {
    color: var(--md-default-fg-color);
    font-weight: 600;
}

.md-content__inner.md-typeset > .article-meta .article-meta__inspiration {
    font-style: italic;
}

.md-content__inner.md-typeset > .article-meta .article-meta__separator {
    color: var(--md-default-fg-color--lighter);
    user-select: none;
}

@media screen and (max-width: 44.984375em) {
    .md-content__inner.md-typeset > .article-meta {
        gap: 0.12rem 0.32rem;
        margin-bottom: 1.15rem;
        font-size: 0.61rem;
    }
}

/*
 * Give both Introduction hubs and every child note the same compact opening
 * rhythm. Reset each contributing layout layer explicitly so the first H1 sits
 * about 0.625 of its 2.6rem line-height below the fixed header. Canonical URLs
 * are server-rendered, so there is no JavaScript-dependent first-paint jump.
 */
html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
body .md-main__inner,
html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-main__inner {
    margin-top: clamp(1.25rem, calc(1.05rem + 0.45vw), 1.5rem) !important;
}

html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
body .md-content,
html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-content {
    padding-top: 0 !important;
}

html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
body .md-content__inner,
html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-content__inner {
    padding-top: 0 !important;
    animation: none !important;
}

html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
body .md-content__inner::before,
html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-content__inner::before {
    display: none !important;
    content: none !important;
}

/*
 * Match the two Introduction hubs to the handwritten Overview section title
 * without changing article headings or navigation typography.
 */
:is(html:has(> head > link[rel="canonical"][href$="/OsdNotes/"]), html:has(> head > link[rel="canonical"][href$="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]))
body .md-content__inner.md-typeset {
    font-family: var(--edwinos-font-reading-sans) !important;
    letter-spacing: 0 !important;
}

html:has(> head > link[rel="canonical"][href$="/OsdNotes/"])
body .md-content__inner.md-typeset
:is(h1, h2, h3, h4, h5, h6, .intro-card-grid > ul > li > p:first-child strong, .admonition-title):where(:not(.landing-route > h3)),
html:has(> head > link[rel="canonical"][href$="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-content__inner.md-typeset
:is(h1, h2, h3, h4, h5, h6, .intro-card-grid > ul > li > p:first-child strong, .admonition-title):where(:not(.landing-route > h3)) {
    font-family: var(--edwinos-font-hand) !important;
    font-weight: 700 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

html:has(> head > link[rel="canonical"][href$="/OsdNotes/"])
body .md-content__inner.md-typeset h1,
html:has(> head > link[rel="canonical"][href$="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-content__inner.md-typeset h1 {
    line-height: 1.12 !important;
}

html:has(> head > link[rel="canonical"][href$="/OsdNotes/"])
body .md-content__inner.md-typeset h2,
html:has(> head > link[rel="canonical"][href$="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-content__inner.md-typeset h2 {
    line-height: 1.16 !important;
}

html:has(> head > link[rel="canonical"][href$="/OsdNotes/"])
body .md-content__inner.md-typeset :is(h3, h4, h5, h6),
html:has(> head > link[rel="canonical"][href$="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-content__inner.md-typeset :is(h3, h4, h5, h6) {
    line-height: 1.2 !important;
}

html:has(> head > link[rel="canonical"][href$="/OsdNotes/"])
body .md-content__inner.md-typeset
:is(.intro-card-grid > ul > li > p:first-child strong, .admonition-title),
html:has(> head > link[rel="canonical"][href$="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
body .md-content__inner.md-typeset
:is(.intro-card-grid > ul > li > p:first-child strong, .admonition-title) {
    font-size: 1.05rem !important;
    line-height: 1.15 !important;
}

/* Keep the MATLAB comparison heading stable before and after Material wraps
   its preceding table for horizontal scrolling. */
html:has(> head > link[rel="canonical"][href$="/OsdNotes/CS101/MATLAB/"])
body .md-content__inner > table:not([class]) + h2#matlab-python,
html:has(> head > link[rel="canonical"][href$="/OsdNotes/CS101/MATLAB/"])
body .md-content__inner > .md-typeset__scrollwrap + h2#matlab-python {
    margin-top: 2em !important;
    transition: none !important;
}

/* ==========================================================================
   Math
   ========================================================================== */

/* Math-bearing article tracks may shrink beside the desktop TOC. Each formula
   owns its overflow, so an oversized expression scrolls inside prose instead
   of widening the content track or painting across the right rail. */
.md-content:has(.md-content__inner.md-typeset .arithmatex),
.md-content__inner.md-typeset:has(.arithmatex) {
    min-width: 0;
}

.md-content__inner.md-typeset span.arithmatex:not(.arithmatex--display) {
    box-sizing: border-box;
    display: inline;
    max-width: none;
    overflow: visible;
}

.md-content__inner.md-typeset span.arithmatex.edwinos-math-overflow {
    display: inline-block;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-inline: contain;
    vertical-align: middle;
}

.md-content__inner.md-typeset span.arithmatex.arithmatex--display {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-inline: contain;
    text-align: center;
}

.md-content__inner.md-typeset div.arithmatex {
    box-sizing: border-box;
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
}

.md-content__inner.md-typeset :is(span.arithmatex, div.arithmatex) {
    scrollbar-width: thin;
    scrollbar-color: color-mix(in srgb, var(--md-default-fg-color) 35%, transparent)
        transparent;
}

.md-content__inner.md-typeset
:is(span.arithmatex, div.arithmatex)::-webkit-scrollbar {
    height: 0.35rem;
}

.md-content__inner.md-typeset
:is(span.arithmatex, div.arithmatex)::-webkit-scrollbar-thumb {
    background: color-mix(in srgb, var(--md-default-fg-color) 35%, transparent);
    border-radius: 999px;
}

/* Article-only math status never blocks prose or search-snippet rendering. */
.md-content__inner.md-typeset .edwinos-math-status {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.7rem;
    margin-block: 0.75rem;
    padding: 0.45rem 0.65rem;
    border: 1px solid var(--md-default-fg-color--lightest);
    border-radius: 0.45rem;
    color: var(--md-default-fg-color--light);
    background: color-mix(in srgb, var(--md-default-fg-color) 4%, var(--md-default-bg-color));
    font: 400 0.7rem/1.5 var(--edwinos-font-reading-sans);
}

.md-content__inner.md-typeset .edwinos-math-status[hidden],
.md-content__inner.md-typeset .edwinos-math-retry[hidden] {
    display: none;
}

.md-content__inner.md-typeset .edwinos-math-status[data-state="error"] {
    border-color: color-mix(in srgb, var(--md-accent-fg-color) 40%, transparent);
    color: var(--md-default-fg-color);
}

.md-content__inner.md-typeset .edwinos-math-retry {
    padding: 0.2rem 0.45rem;
    border: 1px solid var(--md-default-fg-color--lighter);
    border-radius: 0.3rem;
    color: var(--md-accent-fg-color);
    background: var(--md-default-bg-color);
    font: inherit;
    cursor: pointer;
}

.md-content__inner.md-typeset .edwinos-math-retry:focus-visible {
    outline: 2px solid var(--md-accent-fg-color);
    outline-offset: 3px;
}

.md-content__inner.md-typeset
:is(div.arithmatex, span.arithmatex--display)[data-edwinos-math-state="pending"] {
    position: relative;
    min-height: 2.6em;
    color: transparent;
    overflow: hidden;
}

.md-content__inner.md-typeset
:is(div.arithmatex, span.arithmatex--display)[data-edwinos-math-state="pending"]::after {
    content: "";
    position: absolute;
    inset: 0.7em max(1em, 15%);
    border-radius: 0.3rem;
    background: color-mix(in srgb, var(--md-default-fg-color) 7%, var(--md-default-bg-color));
    pointer-events: none;
}

/* ==========================================================================
   Tables
   ========================================================================== */

/* Keep the Bash syntax comparison readable instead of letting the longest
   command force the remaining columns into narrow slivers. */
.md-typeset .bash-option-table table {
    width: 100%;
    table-layout: fixed;
}

.md-typeset .bash-option-table :is(th, td):nth-child(1) {
    width: 24%;
}

.md-typeset .bash-option-table :is(th, td):nth-child(2) {
    width: 18%;
}

.md-typeset .bash-option-table :is(th, td):nth-child(3) {
    width: 20%;
}

.md-typeset .bash-option-table :is(th, td):nth-child(4) {
    width: 38%;
}

.md-typeset .bash-option-table :is(th, td, code) {
    overflow-wrap: anywhere;
    white-space: normal;
}

.md-typeset .bash-symbol-table table {
    width: 100%;
    table-layout: fixed;
}

.md-typeset .bash-symbol-table :is(th, td):nth-child(1) {
    width: 16%;
}

.md-typeset .bash-symbol-table :is(th, td):nth-child(2) {
    width: 46%;
}

.md-typeset .bash-symbol-table :is(th, td):nth-child(3) {
    width: 38%;
}

.md-typeset .bash-symbol-table :is(th, td, code) {
    overflow-wrap: anywhere;
    white-space: normal;
}

/* Keep the two script names intact in the Checkpoint guide's opening tool
   table. The table's existing Material scroll wrapper owns narrow-screen
   overflow; later tables and all other notes retain their normal wrapping. */
html:has(> head > link[rel="canonical"][href*="/Diffusion%20Policy%20checkpoint%20"])
body .md-content__inner.md-typeset
> h2[id="0"] + .highlight + table
:is(th, td):first-child code,
html:has(> head > link[rel="canonical"][href*="/Diffusion%20Policy%20checkpoint%20"])
body .md-content__inner.md-typeset
> h2[id="0"] + .highlight + .md-typeset__scrollwrap
table :is(th, td):first-child code {
    white-space: nowrap !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
    hyphens: none !important;
}

/* ==========================================================================
   PDF Viewer
   ========================================================================== */

.md-typeset .pdf-viewer-shell {
    width: 100%;
    margin-block: 1rem 0.75rem;
    overflow: hidden;
    border: 1px solid var(--md-default-fg-color--lightest);
    border-radius: 0.75rem;
    background: #e6e8eb;
    box-shadow: var(--md-shadow-z1);
}

[data-md-color-scheme="slate"] .md-typeset .pdf-viewer-shell {
    background: #161b22;
}

/* Two clear page images are useful before any native PDF reader is requested.
   Previews stay in normal flow after opening; load never hides them. */
.md-typeset .pdf-viewer-shell .pdf-viewer-previews {
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    font-size: inherit;
}

.md-typeset .pdf-viewer-shell .pdf-viewer-previews > summary {
    margin: 0;
    padding: 0.65rem 2rem 0.65rem 0.9rem;
    border: 0;
    color: var(--md-default-fg-color);
    background: transparent;
    font: 500 0.75rem/1.5 var(--edwinos-font-reading-sans);
    cursor: pointer;
}

.md-typeset .pdf-viewer-shell .pdf-viewer-previews > summary::before {
    display: none;
}

.md-typeset .pdf-viewer-shell .pdf-viewer-previews > summary::after {
    right: 0.8rem;
    width: 0.7rem;
    height: 0.7rem;
    background-color: var(--md-default-fg-color--light);
}

.md-typeset .pdf-viewer-shell .pdf-viewer-previews > summary:focus-visible {
    outline: 2px solid var(--md-accent-fg-color);
    outline-offset: -3px;
}

@media (prefers-reduced-motion: reduce) {
    .md-typeset .pdf-viewer-shell .pdf-viewer-previews > summary::after {
        transition: none;
    }
}

.md-typeset .pdf-viewer-preview-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
    padding: 0 0.85rem 0.85rem;
}

.md-typeset .pdf-viewer-preview-page {
    min-width: 0;
    margin: 0;
}

.md-typeset .pdf-viewer-preview-page > a {
    display: block;
    border: 0;
    text-decoration: none;
}

.md-typeset .pdf-viewer-preview {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    margin: 0;
    border: 1px solid rgb(13 17 23 / 12%);
    border-radius: 0.2rem;
    background: #fff;
    box-shadow: 0 0.15rem 0.45rem rgb(13 17 23 / 10%);
}

.md-typeset .pdf-viewer-preview-page figcaption {
    margin: 0.4rem 0 0;
    color: var(--md-default-fg-color--light);
    font: 400 0.65rem/1.5 var(--edwinos-font-reading-sans);
    text-align: center;
}

.md-typeset .pdf-viewer-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.55rem 0.8rem;
    padding: 0.65rem 0.85rem;
    border-top: 1px solid var(--md-default-fg-color--lightest);
}

.md-typeset .pdf-viewer-shell :is([data-pdf-open], [data-pdf-retry]) {
    padding: 0.45rem 0.75rem;
    border: 1px solid var(--md-accent-fg-color);
    border-radius: 0.4rem;
    color: var(--md-accent-fg-color);
    background: var(--md-default-bg-color);
    font: 500 0.75rem/1.4 var(--edwinos-font-reading-sans);
    cursor: pointer;
}

.md-typeset .pdf-viewer-shell :is([data-pdf-open], [data-pdf-retry]):focus-visible {
    outline: 2px solid var(--md-accent-fg-color);
    outline-offset: 3px;
}

.md-typeset .pdf-viewer-shell :is([data-pdf-open], [data-pdf-retry]):disabled {
    color: var(--md-default-fg-color--light);
    border-color: var(--md-default-fg-color--lighter);
    cursor: default;
}

/* The reader button shares Back to Top's lighter glass tuning. Its own
   backdrop keeps the label sharp; each visible viewer owns its optical map. */
.md-typeset .pdf-viewer-shell [data-pdf-open] {
    --edwinos-pdf-tint: rgba(246, 248, 250, 0.2);
    --edwinos-pdf-hover-tint: rgba(246, 248, 250, 0.28);
    --edwinos-pdf-border: rgba(60, 60, 67, 0.2);
    --edwinos-pdf-highlight: rgba(255, 255, 255, 0.65);
    --edwinos-pdf-shadow: 0 3px 14px rgba(31, 35, 40, 0.13);
    --edwinos-pdf-radius: 1.5rem;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    max-width: 100%;
    padding: 0.5rem 0.9rem;
    overflow: visible;
    border: 0;
    border-radius: var(--edwinos-pdf-radius);
    background: var(--edwinos-pdf-tint);
    -webkit-backdrop-filter: blur(4px) saturate(1.12);
    backdrop-filter: blur(4px) saturate(1.12);
    box-shadow: var(--edwinos-pdf-shadow);
    color: #303641;
    text-align: center;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.6);
}

[data-md-color-scheme="slate"] .md-typeset .pdf-viewer-shell [data-pdf-open] {
    --edwinos-pdf-tint: rgba(25, 29, 37, 0.26);
    --edwinos-pdf-hover-tint: rgba(25, 29, 37, 0.34);
    --edwinos-pdf-border: rgba(240, 246, 252, 0.2);
    --edwinos-pdf-highlight: rgba(240, 246, 252, 0.24);
    --edwinos-pdf-shadow: 0 3px 14px rgba(1, 4, 9, 0.32);
    color: #dce2ea;
    text-shadow: 0 1px 2px rgba(1, 4, 9, 0.65);
}

.md-typeset .pdf-viewer-shell [data-pdf-open].edwinos-pdf-refraction {
    backdrop-filter: var(--edwinos-pdf-filter) saturate(1.12);
}

.md-typeset .pdf-viewer-shell [data-pdf-open] > .edwinos-pdf-glass__highlight {
    position: absolute;
    inset: 0;
    z-index: -1;
    display: block;
    box-sizing: border-box;
    border: 1px solid var(--edwinos-pdf-border);
    border-radius: inherit;
    box-shadow:
        inset 0 1px 0 var(--edwinos-pdf-highlight),
        inset 0 -1px 0 rgba(31, 35, 40, 0.07);
    pointer-events: none;
}

.md-typeset .pdf-viewer-shell [data-pdf-open]:is(:hover, :focus):not(:disabled) {
    background: var(--edwinos-pdf-hover-tint);
}

.md-typeset .pdf-viewer-shell [data-pdf-open]:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .md-typeset .pdf-viewer-shell [data-pdf-open] {
        --edwinos-pdf-tint: rgba(246, 248, 250, 0.94);
        --edwinos-pdf-hover-tint: rgba(246, 248, 250, 0.98);
    }

    [data-md-color-scheme="slate"] .md-typeset .pdf-viewer-shell [data-pdf-open] {
        --edwinos-pdf-tint: rgba(25, 29, 37, 0.94);
        --edwinos-pdf-hover-tint: rgba(25, 29, 37, 0.98);
    }
}

.md-typeset .pdf-viewer-shell .pdf-viewer-status {
    flex: 1 1 12rem;
    margin: 0;
    color: var(--md-default-fg-color--light);
    font: 400 0.7rem/1.5 var(--edwinos-font-reading-sans);
}

/* A PDF reader is the page's primary content, so reclaim the desktop TOC
   column for both readable previews and the document canvas. */
html:has(body .pdf-viewer-shell) body .md-sidebar--secondary {
    display: none !important;
}

html:has(body .pdf-viewer-shell) body .md-content,
html:has(body .pdf-viewer-shell) body .md-content__inner {
    max-width: none !important;
}

.md-typeset .pdf-viewer-frame {
    display: block;
    width: 100%;
    height: 720px;
    border: 0;
    background: #fff;
}

.md-typeset .pdf-viewer-shell [hidden] {
    display: none !important;
}

.md-typeset .pdf-viewer-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 1rem;
    font-size: 0.8rem;
}

.md-typeset .pdf-viewer-shell noscript {
    display: block;
    padding: 0.65rem 0.85rem;
}

@media screen and (max-width: 44.984375em) {
    .md-typeset .pdf-viewer-preview-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.65rem;
        padding: 0 0.65rem 0.65rem;
    }

    .md-typeset .pdf-viewer-frame {
        height: 720px;
    }
}

/* Three anonymized editor screenshots include solid black padding in their
   raster files. Crop only their on-page presentation; other article images
   and the source Obsidian assets remain untouched. */
.md-typeset img.trim-black-padding,
.md-typeset img.trim-white-padding {
    display: block;
    object-fit: cover;
}

.md-typeset img.trim-black-padding--register {
    aspect-ratio: 2171 / 526;
    object-position: 50% 52.7%;
}

.md-typeset img.trim-black-padding--scene {
    aspect-ratio: 2117 / 390;
    object-position: 50% 47%;
}

.md-typeset img.trim-black-padding--asset {
    aspect-ratio: 2163 / 391;
    object-position: 50% 50%;
}

/* The anonymized transfer screenshot contains 107 px / 108 px of white
   canvas above and below the terminal capture. Crop only its presentation so
   the source asset remains byte-for-byte unchanged. */
.md-typeset img.trim-white-padding--npz-transfer {
    aspect-ratio: 2123 / 526;
    object-position: 50% 49.9%;
}

/* ==========================================================================
   Prose Links
   ========================================================================== */

/* Keep prose-link colors, hover highlights, and focus outlines without lines. */
.md-content__inner.md-typeset
:is(p, li, dd, blockquote):not(:where(.grid.cards *, [class*="card"], [class*="card"] *))
a:not(:where(.headerlink, .md-button, [role="button"], [class*="btn-"])) {
    text-decoration: none !important;
    border-bottom: 0 !important;
}

/* ==========================================================================
   Friends Page
   ========================================================================== */

body:has(.friend-links) .academic-content--subpage > h1 {
    margin: 0 0 0.35rem !important;
    color: #24292f !important;
    font-family: var(--edwinos-font-hand) !important;
    font-size: 32px !important;
    font-weight: 600 !important;
    letter-spacing: 0 !important;
    line-height: 1.2 !important;
}

body:has(.friend-links) .academic-content--subpage > p {
    margin: 0 0 0.8rem !important;
    color: #57606a !important;
    font-size: 16px !important;
    line-height: 1.45 !important;
}

body:has(.friend-links) .academic-content--subpage > h2 {
    margin: 1.15rem 0 0.42rem !important;
    color: #24292f !important;
    font-family: var(--edwinos-font-hand) !important;
    font-size: 24px !important;
    font-weight: 600 !important;
    letter-spacing: 0 !important;
}

body:has(.friend-links) .academic-content--subpage > ul,
body:has(.friend-links) .academic-content--subpage > ol {
    margin-top: 0.35rem !important;
    margin-bottom: 0.65rem !important;
}

body:has(.friend-links) .academic-content--subpage li {
    margin-bottom: 0.2rem !important;
    font-size: 16px !important;
    line-height: 1.45 !important;
}

body[data-md-color-scheme="slate"]:has(.friend-links)
.academic-content--subpage > :is(h1, h2) {
    color: #f0f6fc !important;
}

body[data-md-color-scheme="slate"]:has(.friend-links)
.academic-content--subpage > p {
    color: #8b949e !important;
}

/* The HOME subpage shell is a flex column with a generous global gap. Friends
   already defines its own heading, prose, list, and card spacing, so remove
   only the duplicated inter-element gap on this page. */
body:has(.friend-links) .academic-content--subpage {
    gap: 0 !important;
    font-family: var(--edwinos-font-reading-sans) !important;
}

.friend-links {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(16.5rem, 1fr)) !important;
    gap: 12px !important;
    padding: 4px 0 12px !important;
}

.friend-card {
    display: flex;
    box-sizing: border-box !important;
    min-height: 72px !important;
    align-items: center !important;
    padding: 10px 12px !important;
    border: 1px solid #d0d7de !important;
    border-radius: 6px !important;
    background: #ffffff !important;
    box-shadow: none !important;
    color: #24292f !important;
    text-decoration: none !important;
    transform: none !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.25s ease;
}

.friend-card:hover {
    border-color: #0969da !important;
    background: #f6f8fa !important;
}

.friend-avatar-stack,
.friend-avatar {
    display: block !important;
    width: 48px !important;
    height: 48px !important;
    flex: 0 0 48px !important;
    margin: 0 12px 0 0 !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    background-position: center !important;
    background-size: cover !important;
    background-repeat: no-repeat !important;
}

.friend-avatar-stack {
    position: relative !important;
    overflow: hidden !important;
    background: #f6f8fa !important;
}

.friend-avatar-stack .friend-avatar {
    position: absolute !important;
    inset: 0 !important;
    margin: 0 !important;
}

.friend-avatar--dark {
    display: none !important;
}

.friend-info {
    display: flex;
    min-width: 0 !important;
    flex-direction: column;
    gap: 0.16rem !important;
    overflow: hidden;
}

body:has(.friend-links) .academic-content--subpage .friend-name {
    margin: 0 !important;
    overflow: hidden;
    color: #0969da !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    line-height: 1.16 !important;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.friend-desc {
    display: -webkit-box;
    overflow: hidden;
    color: #57606a !important;
    font-family: var(--edwinos-font-reading-sans) !important;
    font-size: 14px !important;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-height: 1.28 !important;
}

body[data-md-color-scheme="slate"] .friend-card {
    border-color: #30363d !important;
    background: #161b22 !important;
    color: #f0f6fc !important;
}

body[data-md-color-scheme="slate"] .friend-card:hover {
    border-color: #58a6ff !important;
    background: #0d1117 !important;
}

body[data-md-color-scheme="slate"] .friend-avatar--light {
    display: none !important;
}

body[data-md-color-scheme="slate"] .friend-avatar--dark {
    display: block !important;
}

body[data-md-color-scheme="slate"] .friend-name {
    color: #58a6ff !important;
}

body[data-md-color-scheme="slate"] .friend-desc {
    color: #8b949e !important;
}

/* Keep the Friends profile statistic in the compact pre-handwriting face;
   page and section headings continue to inherit the Caveat heading rule. */


/* Keep the YAML example visually attached to its short "Link format:" label
   instead of inheriting the combined paragraph and code-block margins. */
body:has(.friend-links)
.academic-content--subpage
> p:has(> strong:only-child) {
    margin-bottom: 0 !important;
}

body:has(.friend-links)
.academic-content--subpage
> p:has(> strong:only-child)
+ .language-yaml.highlight {
    margin-top: 0.35rem !important;
}

@media screen and (max-width: 600px) {
    .friend-links {
        grid-template-columns: 1fr !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .friend-card {
        animation: none !important;
        transition: none !important;
        transform: none !important;
    }
}

/* ==========================================================================
   Archive
   ========================================================================== */

.archive-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    margin: 0 0 1.55rem;
    padding: 1.35rem clamp(1.4rem, 3.5vw, 2.5rem) 1.45rem;
    border: 1px solid rgba(30, 58, 138, 0.12);
    border-radius: 20px;
    background:
        radial-gradient(circle at 88% 12%, rgba(59, 130, 246, 0.17), transparent 34%),
        linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(239, 246, 255, 0.72));
    box-shadow: 0 14px 38px rgba(30, 58, 138, 0.075);
}

.archive-hero::after {
    content: "";
    position: absolute;
    z-index: -1;
    width: 7rem;
    height: 7rem;
    right: -2rem;
    bottom: -3.5rem;
    border: 1px solid rgba(30, 58, 138, 0.13);
    border-radius: 50%;
    box-shadow: 0 0 0 1.6rem rgba(59, 130, 246, 0.035),
                0 0 0 3.2rem rgba(59, 130, 246, 0.025);
}

.archive-hero__eyebrow {
    margin: 0 0 0.38rem !important;
    color: #1e3a8a;
    font: 600 0.58rem/1.2 "Cinzel", "Inter", sans-serif;
    letter-spacing: 0.2em;
}

.md-typeset .archive-hero h1 {
    margin: 0;
    color: #111827;
    font: 600 clamp(2rem, 5vw, 3.4rem)/0.92 "Cormorant Garamond", "Playfair Display", serif;
    letter-spacing: -0.035em;
}

.archive-hero__lead {
    max-width: 38rem;
    margin: 0.55rem 0 0 !important;
    color: #475569;
    font: 500 clamp(0.86rem, 1.4vw, 1rem)/1.45 "Cormorant Garamond", "Noto Serif SC", serif;
}

.archive-hero__stats {
    position: absolute;
    right: clamp(1.4rem, 3.5vw, 2.5rem);
    bottom: 1.35rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.archive-hero__stats > span {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
    padding: 0.34rem 0.62rem;
    color: #475569;
    font-size: 0.62rem;
    line-height: 1;
    border: 1px solid rgba(30, 58, 138, 0.11);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8),
                inset 0 -1px 0 rgba(44, 64, 91, 0.06),
                0 2px 7px rgba(30, 58, 138, 0.035);
    -webkit-backdrop-filter: blur(5px) saturate(1.12);
    backdrop-filter: blur(5px) saturate(1.12);
}

.archive-hero__stats > .edwinos-archive-stat-refraction {
    -webkit-backdrop-filter: var(--edwinos-archive-stat-filter) saturate(1.12);
    backdrop-filter: var(--edwinos-archive-stat-filter) saturate(1.12);
}

.archive-hero__stats .edwinos-archive-stat-glass__highlight {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    box-shadow: inset 1px 0 rgba(255, 255, 255, 0.28),
                inset -1px 0 rgba(255, 255, 255, 0.16);
    pointer-events: none;
}

.archive-hero__stats strong {
    color: #1e3a8a;
}

.archive-year {
    margin: 0 0 3.4rem;
}

.archive-year__heading {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin: 0 0 0.85rem;
    padding: 0 0 0.52rem;
    border-bottom: 1px solid rgba(30, 58, 138, 0.12);
}

.md-typeset .archive-year__heading h2 {
    margin: 0;
    padding: 0;
    color: #172554;
    font: 600 clamp(1.55rem, 3vw, 2rem)/1 "Cormorant Garamond", "Playfair Display", serif;
    border: 0;
}

.archive-year__heading > span {
    color: #64748b;
    font: 500 0.66rem/1 "JetBrains Mono", monospace;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.archive-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.9rem;
}

.archive-card {
    min-width: 0;
    overflow: hidden;
    border: 1px solid rgba(15, 23, 42, 0.09);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.72);
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.05);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.archive-card:hover {
    transform: translateY(-3px);
    border-color: rgba(30, 58, 138, 0.26);
    box-shadow: 0 13px 32px rgba(30, 58, 138, 0.11);
}

.md-typeset .archive-card__link,
.md-typeset .archive-card__link:hover {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(8rem, 1fr);
    height: 100%;
    min-height: 8.6rem;
    color: inherit;
    text-decoration: none;
    border: 0;
}

.archive-card__cover {
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 100%;
    min-height: 100%;
    background: #e2e8f0;
}

.archive-card__image {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0 !important;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.archive-card:hover .archive-card__image {
    transform: scale(1.035);
}

.archive-card__cover--emoji {
    display: grid;
    place-items: center;
    background:
        radial-gradient(circle at 68% 28%, rgba(255, 255, 255, 0.6), transparent 22%),
        linear-gradient(135deg, #dbeafe, #e0e7ff);
}

.archive-card--robotics .archive-card__cover--emoji {
    background: linear-gradient(135deg, #dbeafe, #c7d2fe);
}

.archive-card--science .archive-card__cover--emoji {
    background: linear-gradient(135deg, #d1fae5, #cffafe);
}

.archive-card--humanities .archive-card__cover--emoji {
    background: linear-gradient(135deg, #fef3c7, #fee2e2);
}

.archive-card--code .archive-card__cover--emoji {
    background: linear-gradient(135deg, #e0e7ff, #dbeafe);
}

.archive-card--writing .archive-card__cover--emoji {
    background: linear-gradient(135deg, #ffedd5, #fce7f3);
}

.archive-card--profile .archive-card__cover--emoji,
.archive-card--study .archive-card__cover--emoji {
    background: linear-gradient(135deg, #ede9fe, #e0f2fe);
}

.archive-card__emoji {
    font-size: clamp(2.7rem, 6vw, 4.2rem);
    filter: drop-shadow(0 10px 16px rgba(15, 23, 42, 0.13));
    transform: translateY(-0.06em);
}

.archive-card__status {
    flex: 0 0 auto;
    padding: 0.3rem 0.54rem;
    color: #1e3a8a;
    font: 650 0.52rem/1 "Inter", sans-serif;
    letter-spacing: 0.1em;
    border: 1px solid rgba(30, 58, 138, 0.13);
    border-radius: 999px;
    background: rgba(30, 58, 138, 0.07);
}

.archive-card__status--published {
    color: #166534;
    border-color: rgba(22, 101, 52, 0.14);
    background: rgba(22, 101, 52, 0.07);
}

.archive-card__body {
    display: flex;
    min-width: 0;
    padding: 1rem 1.2rem 0.95rem;
    flex-direction: column;
    justify-content: center;
}

.archive-card__meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.35rem;
    color: #64748b;
    font: 500 0.64rem/1.4 "JetBrains Mono", monospace;
}

.archive-card__title-row {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 0.58rem;
    margin: 0.6rem 0 0.8rem;
}

.md-typeset .archive-card__title {
    display: -webkit-box;
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
    margin: 0;
    color: #172033;
    font: 600 clamp(1.12rem, 2.3vw, 1.38rem)/1.3 "Playfair Display", "Noto Serif SC", serif;
    letter-spacing: -0.012em;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.archive-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: auto;
}

.archive-card__category {
    overflow: hidden;
    padding: 0.34rem 0.6rem;
    color: #1e3a8a;
    font: 600 0.6rem/1 "Inter", sans-serif;
    white-space: nowrap;
    text-overflow: ellipsis;
    border-radius: 999px;
    background: rgba(30, 58, 138, 0.075);
}

.archive-card__arrow {
    color: #1e3a8a;
    font-size: 1rem;
    transition: transform 0.25s ease;
}

.archive-card:hover .archive-card__arrow {
    transform: translate(2px, -2px);
}

.archive-note,
.archive-empty {
    margin-top: 2.6rem !important;
    padding-top: 1rem;
    color: #64748b;
    font-size: 0.68rem;
    text-align: center;
    border-top: 1px solid rgba(30, 58, 138, 0.1);
}

[data-md-color-scheme="slate"] .archive-hero {
    border-color: #30363d;
    background:
        radial-gradient(circle at 88% 12%, rgba(88, 166, 255, 0.12), transparent 34%),
        #161b22;
    box-shadow: none;
}

[data-md-color-scheme="slate"] .archive-hero__eyebrow,
[data-md-color-scheme="slate"] .archive-hero__stats strong,
[data-md-color-scheme="slate"] .archive-card__category,
[data-md-color-scheme="slate"] .archive-card__arrow {
    color: #58a6ff;
}

[data-md-color-scheme="slate"] .md-typeset .archive-hero h1,
[data-md-color-scheme="slate"] .md-typeset .archive-year__heading h2,
[data-md-color-scheme="slate"] .md-typeset .archive-card__title {
    color: #f8fafc !important;
}

[data-md-color-scheme="slate"] .archive-hero__lead,
[data-md-color-scheme="slate"] .archive-hero__stats > span,
[data-md-color-scheme="slate"] .archive-year__heading > span,
[data-md-color-scheme="slate"] .archive-card__meta,
[data-md-color-scheme="slate"] .archive-note {
    color: #8b949e;
}

[data-md-color-scheme="slate"] .archive-hero__stats > span {
    border-color: rgba(175, 195, 222, 0.15);
    background: rgba(20, 28, 40, 0.2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14),
                inset 0 -1px 0 rgba(0, 0, 0, 0.22),
                0 2px 7px rgba(0, 0, 0, 0.1);
}

[data-md-color-scheme="slate"] .archive-year__heading,
[data-md-color-scheme="slate"] .archive-note {
    border-color: #30363d;
}

[data-md-color-scheme="slate"] .archive-card {
    border-color: #30363d;
    background: #161b22;
    box-shadow: none;
}

[data-md-color-scheme="slate"] .archive-card:hover {
    border-color: rgba(88, 166, 255, 0.45);
    box-shadow: none;
}

[data-md-color-scheme="slate"] .archive-card__category {
    background: rgba(88, 166, 255, 0.1);
}

[data-md-color-scheme="slate"] .archive-card__status {
    color: #58a6ff;
    border-color: rgba(88, 166, 255, 0.24);
    background: rgba(88, 166, 255, 0.11);
}

[data-md-color-scheme="slate"] .archive-card__status--published {
    color: #86efac;
    border-color: rgba(134, 239, 172, 0.18);
    background: rgba(34, 197, 94, 0.1);
}

@media screen and (max-width: 48rem) {
    .archive-hero__stats {
        position: static;
        margin-top: 0.8rem;
    }

    .md-typeset .archive-card__link,
    .md-typeset .archive-card__link:hover {
        grid-template-columns: minmax(0, 3fr) minmax(7rem, 1fr);
        min-height: 7.8rem;
    }
}

@media screen and (max-width: 30rem) {
    .archive-hero {
        padding: 1rem 1.05rem 1.05rem;
        border-radius: 16px;
    }

    .archive-card {
        border-radius: 14px;
    }

    .archive-year__heading {
        align-items: center;
    }

    .md-typeset .archive-card__link,
    .md-typeset .archive-card__link:hover {
        grid-template-columns: minmax(0, 3fr) minmax(5.8rem, 1fr);
        min-height: 7.1rem;
    }

    .archive-card__body {
        padding: 0.78rem 0.85rem 0.75rem;
    }

    .archive-card__meta {
        font-size: 0.56rem;
    }

    .archive-card__title-row {
        gap: 0.42rem;
        margin: 0.42rem 0 0.58rem;
    }

    .md-typeset .archive-card__title {
        font-size: 0.96rem;
        line-height: 1.28;
    }

    .archive-card__category {
        max-width: 9rem;
        padding: 0.28rem 0.48rem;
        font-size: 0.54rem;
    }

    .archive-card__status {
        padding: 0.27rem 0.45rem;
        font-size: 0.52rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .archive-card,
    .archive-card__image,
    .archive-card__arrow {
        transition: none;
    }
}

/* Keep every entry on one stable grid rhythm. The cover is taken out of the
   intrinsic-size calculation so portrait and panoramic source images cannot
   stretch the card; object-fit then crops each source to the cover viewport. */
body.is-home-profile-page:has(.archive-grid) .archive-card {
    block-size: 10.75rem;
}

body.is-home-profile-page:has(.archive-grid) .archive-card__link,
body.is-home-profile-page:has(.archive-grid) .archive-card__link:hover {
    height: 100% !important;
    min-height: 0 !important;
}

body.is-home-profile-page:has(.archive-grid) .archive-card__cover {
    position: relative;
    height: 100%;
    min-height: 0;
}

body.is-home-profile-page:has(.archive-grid) .archive-card__image {
    position: absolute;
    inset: 0;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center;
}

/* Archive links can take a moment on a cold Pages cache. Give the click an
   immediate, unmistakable state while Material fetches the next document. */
body.is-archive-navigating {
    overflow: hidden;
}

body.is-archive-navigating::before,
body.is-archive-navigating::after {
    position: fixed;
    z-index: 10000;
    pointer-events: auto;
}

body.is-archive-navigating::before {
    content: "";
    inset: 0;
    background: rgba(5, 9, 14, 0.96);
}

body.is-archive-navigating::after {
    content: "Opening note\2026";
    top: 50%;
    left: 50%;
    padding-top: 2.4rem;
    color: #f0f6fc;
    font-family: var(--edwinos-font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    background:
        radial-gradient(circle, transparent 52%, #58a6ff 54% 64%, transparent 66%)
        top center / 1.6rem 1.6rem no-repeat;
    transform: translate(-50%, -50%);
    animation: edwinos-archive-loading 900ms linear infinite;
}

@keyframes edwinos-archive-loading {
    to {
        filter: hue-rotate(360deg);
    }
}

.archive-navigation-help {
    position: fixed;
    top: calc(50% + 4rem);
    left: 50%;
    z-index: 10001;
    width: min(90vw, 28rem);
    transform: translateX(-50%);
    color: #f0f6fc;
    text-align: center;
    font: 400 0.65rem/1.6 var(--edwinos-font-mono);
}

.archive-navigation-help p {
    margin: 0 0 0.8rem;
}

.archive-navigation-help button {
    margin: 0 0.3rem;
    padding: 0.45rem 0.65rem;
    border: 1px solid #58a6ff;
    border-radius: 0.35rem;
    background: #161b22;
    color: #f0f6fc;
    font: inherit;
    cursor: pointer;
}

.archive-navigation-help button:focus-visible {
    outline: 2px solid #f0f6fc;
    outline-offset: 3px;
}

@media screen and (max-width: 36rem) {
    body.is-home-profile-page:has(.archive-grid) .archive-card__title-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
        gap: 0.28rem;
        margin: 0 0 0.5rem;
    }

    body.is-home-profile-page:has(.archive-grid) .archive-card__status {
        justify-self: start;
        padding: 0.22rem 0.4rem;
        font-size: 0.46rem;
        letter-spacing: 0.07em;
    }

    body.is-home-profile-page:has(.archive-grid) .archive-card__title {
        width: 100%;
    }
}

@media screen and (max-width: 30rem) {
    body.is-home-profile-page:has(.archive-grid) .archive-card {
        block-size: 9.75rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    body.is-archive-navigating::after {
        animation: none;
    }
}

/* ==========================================================================
   Fragment Targets
   ========================================================================== */

/* Keep this shared heading state after Archive: equal-specificity heading
   resets must not override the selected target's spacing or border.
   A heading selected from the right-hand TOC remains identifiable through the
   scroll, then its yellow glass highlight fades without dimming the text. */
.md-typeset :is(h1, h2, h3, h4, h5, h6).block-highlight--pinned {
    box-sizing: border-box;
    width: calc(100% + 1.4rem);
    margin-inline: -0.7rem;
    padding: 0.42rem 0.7rem;
    border: 1px solid rgba(234, 179, 8, 0.26);
    border-radius: 1rem;
    background: rgba(255, 221, 36, 0.14);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.24),
        0 0.5rem 1.35rem rgba(234, 179, 8, 0.06);
    -webkit-backdrop-filter: blur(8px) saturate(115%);
    backdrop-filter: blur(8px) saturate(115%);
}

[data-md-color-scheme="slate"]
.md-typeset :is(h1, h2, h3, h4, h5, h6).block-highlight--pinned {
    border-color: rgba(255, 243, 138, 0.4);
    background: rgba(255, 232, 64, 0.2);
    box-shadow:
        inset 0 1px 0 rgba(255, 252, 214, 0.18),
        0 0 1.55rem rgba(255, 220, 24, 0.08),
        0 0.55rem 1.45rem rgba(0, 0, 0, 0.12);
}

.md-typeset :is(h1, h2, h3, h4, h5, h6).block-highlight--pinned.block-highlight--fading {
    border-color: transparent;
    background-color: transparent;
    box-shadow: none;
    -webkit-backdrop-filter: blur(0) saturate(100%);
    backdrop-filter: blur(0) saturate(100%);
    transition:
        border-color 1.15s ease,
        background-color 1.15s ease,
        box-shadow 1.15s ease,
        -webkit-backdrop-filter 1.15s ease,
        backdrop-filter 1.15s ease;
}

.md-typeset :is(h1, h2, h3, h4, h5, h6).block-highlight--pinned::before {
    content: none;
}

/* ==========================================================================
   Content Hubs
   ========================================================================== */

/* Match Overview's blank pending state. Seed it before the runtime arrives,
   then let independent headings/paragraphs/cards own their entrance. No
   opacity transition may reveal a waiting unit before its WAAPI effect. */
html.edwinos-hub-reveal-enabled .md-sidebar--primary .md-nav__list
.md-nav__link.is-hub-reveal-unit {
    /* The entrance owns opacity; native link hover still owns its colors. */
    transition-property: color, background-color !important;
}

@media screen and (prefers-reduced-motion: no-preference) {
    html.edwinos-hub-reveal-enabled
    .notes-landing:not([data-hub-reveal-ready]) [data-hub-reveal],
    html.edwinos-hub-reveal-enabled .is-hub-reveal-pending {
        opacity: 0;
        pointer-events: none;
        transition: none !important;
    }
}

@media screen and (min-width: 76.25em) {
    html:has(> head > link[rel="canonical"][href*="/OsdNotes/"])
    body .md-sidebar--primary
    .md-nav--primary > .md-nav__list
    > .md-nav__item--active.md-nav__item--section
    > .md-nav__container,
    html:has(> head > link[rel="canonical"][href*="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"])
    body .md-sidebar--primary
    .md-nav--primary > .md-nav__list
    > .md-nav__item--active.md-nav__item--section
    > .md-nav__container {
        display: none !important;
    }
}

.md-typeset .intro-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-block: 1rem 1.25rem;
}

.md-typeset .intro-card-grid > ul {
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.md-typeset .intro-card-grid > ul > li {
    display: block !important;
    min-width: 0;
    margin: 0 !important;
    list-style: none !important;
    overflow: hidden;
    border-radius: 1.25rem !important;
}

.md-typeset .intro-card-grid > ul > li::marker {
    content: "";
}

/* In dark mode, preserve the card boundary and replace Material's elevated
   drop shadow with a centered, low-intensity white edge glow. Light mode keeps
   the existing Material hover treatment. */
:is(html:has(> head > link[rel="canonical"][href$="/OsdNotes/"]), html:has(> head > link[rel="canonical"][href$="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]))
body[data-md-color-scheme="slate"]
.md-typeset .intro-card-grid > ul > li {
    border-color: rgba(240, 246, 252, 0.2) !important;
    box-shadow: none !important;
    transition: border-color 160ms ease, box-shadow 160ms ease !important;
}

:is(html:has(> head > link[rel="canonical"][href$="/OsdNotes/"]), html:has(> head > link[rel="canonical"][href$="/%E7%BB%8F%E9%AA%8C%E5%88%86%E4%BA%AB/"]))
body[data-md-color-scheme="slate"]
.md-typeset .intro-card-grid > ul > li:is(:hover, :focus-within) {
    border-color: rgba(240, 246, 252, 0.68) !important;
    box-shadow:
        0 0 0 1px rgba(240, 246, 252, 0.14),
        0 0 0.7rem rgba(240, 246, 252, 0.13) !important;
}

@media screen and (max-width: 59.984375em) {
    .md-typeset .intro-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .md-typeset .intro-card-grid > ul > li:last-child:nth-child(odd) {
        grid-column: 1 / -1;
    }
}

@media screen and (max-width: 44.984375em) {
    .md-typeset .intro-card-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .md-typeset .intro-card-grid > ul > li:last-child:nth-child(odd) {
        grid-column: auto;
    }
}

/* Landing pages offer reading routes without changing child article styles. */
.md-content__inner:has(> .notes-landing) {
    animation: none;
}

.md-typeset .notes-landing {
    max-width: 50rem;
    margin-inline: auto;
    color: var(--md-default-fg-color);
    font-size: 0.8rem;
    line-height: 1.7;
}

.md-typeset .notes-landing > h1 {
    margin-bottom: 0.55rem;
}

.md-typeset .landing-intro {
    max-width: 66ch;
    margin-bottom: 1rem;
    font-size: 0.84rem;
    line-height: 1.75;
}

.md-typeset .landing-intro p {
    margin: 0;
}

.md-typeset .landing-routes {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.8rem;
    margin-block: 0 1rem;
}

.md-typeset .landing-route {
    position: relative;
    min-width: 0;
    padding: 1rem;
    border: 1px solid rgba(60, 60, 67, 0.16);
    border-radius: 0.8rem;
    background: rgba(246, 248, 250, 0.2);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.75),
        inset 0 -1px 0 rgba(31, 35, 40, 0.06),
        0 3px 14px rgba(31, 35, 40, 0.055);
    -webkit-backdrop-filter: blur(4px) saturate(1.12);
    backdrop-filter: blur(4px) saturate(1.12);
}

/* Share Back to Top's rounded lens; filter the backdrop, leaving text sharp. */
.md-typeset .landing-route.edwinos-landing-route-refraction {
    -webkit-backdrop-filter: var(--edwinos-landing-route-filter) saturate(1.12);
    backdrop-filter: var(--edwinos-landing-route-filter) saturate(1.12);
}

.md-typeset .landing-route > .edwinos-landing-route-glass__highlight {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    box-shadow:
        inset 1px 0 rgba(255, 255, 255, 0.32),
        inset -1px 0 rgba(255, 255, 255, 0.18);
    pointer-events: none;
}

[data-md-color-scheme="slate"] .md-typeset .landing-route {
    border-color: rgba(240, 246, 252, 0.18);
    background: rgba(25, 29, 37, 0.26);
    box-shadow:
        inset 0 1px 0 rgba(240, 246, 252, 0.22),
        inset 0 -1px 0 rgba(1, 4, 9, 0.2),
        0 3px 14px rgba(1, 4, 9, 0.18);
}

[data-md-color-scheme="slate"] .md-typeset .landing-route > .edwinos-landing-route-glass__highlight {
    box-shadow:
        inset 1px 0 rgba(240, 246, 252, 0.12),
        inset -1px 0 rgba(240, 246, 252, 0.06);
}

.md-typeset .landing-route h3 {
    margin: 0 0 0.5rem;
    color: var(--md-typeset-a-color);
    font-family: var(--edwinos-font-reading-sans);
    font-size: 0.92rem;
    font-weight: 500;
    line-height: 1.5;
}

.md-typeset .landing-route p {
    margin: 0;
    font-size: 0.74rem;
    line-height: 1.7;
}

.md-typeset .notes-landing :is(.landing-route, .landing-reading-list) h3 a,
.md-typeset .notes-landing .landing-feature h2 a {
    font-family: var(--edwinos-font-reading-sans);
    font-weight: 500;
    line-height: 1.5;
    text-decoration: none;
    overflow-wrap: anywhere;
}

.md-typeset .notes-landing :is(h2, h3) a {
    border-bottom: 0;
}

.md-typeset .notes-landing :is(h2, h3) a:is(:hover, :focus-visible) {
    border-bottom: 0;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.18em;
}

.md-typeset .notes-landing .landing-title-translation {
    display: inline-block;
    max-width: calc(100% - 0.5em);
    margin-inline-start: 0.5em;
    color: var(--md-default-fg-color);
    font-family: var(--edwinos-font-reading-sans);
    font-size: 0.88em;
    font-style: normal;
    font-weight: 400;
    line-height: 1.5;
    cursor: default;
    -webkit-user-select: none;
    user-select: none;
}

.md-typeset .notes-landing a:focus-visible {
    outline: 2px solid var(--md-typeset-a-color);
    outline-offset: 4px;
    border-radius: 2px;
}

.md-typeset .notes-landing > h2,
.md-typeset .landing-selection > h2,
.md-typeset .landing-group > h2 {
    margin: 0 0 0.8rem;
}

.md-typeset .landing-reading-entry {
    display: flow-root;
    padding-top: 0.85rem;
    border-top: 1px solid var(--md-default-fg-color--lightest);
}

.md-typeset .landing-reading-entry:first-child {
    border-top: 0;
    padding-top: 0.25rem;
}

.md-typeset .landing-reading-entry > h3 {
    margin: 0;
    font-size: 0.84rem;
}

.md-typeset .landing-reading-entry > p {
    max-width: 72ch;
    margin: 0.32rem 0 1rem;
    font-size: 0.75rem;
    line-height: 1.7;
}

/* The next section/footer owns its gap; do not stack a trailing note margin. */
.md-typeset .landing-reading-entry:last-child > p:last-child {
    margin-bottom: 0;
}

.md-typeset .notes-landing .landing-language {
    display: inline-block;
    margin-left: 0.28rem;
    color: var(--md-default-fg-color--light);
    font-family: var(--edwinos-font-reading-sans);
    font-size: 0.62rem;
    font-weight: 400;
    white-space: nowrap;
    cursor: default;
    -webkit-user-select: none;
    user-select: none;
}

.md-typeset .landing-feature {
    margin-block: 0 1.8rem;
    padding: 1.1rem 1.25rem;
    border: 1px solid var(--md-default-fg-color--lightest);
    border-left: 3px solid var(--md-typeset-a-color);
    border-radius: 0 0.8rem 0.8rem 0;
    background: color-mix(in srgb, var(--md-typeset-a-color) 3%, transparent);
}

.md-typeset .landing-feature .landing-kicker {
    margin: 0 0 0.5rem;
    color: var(--md-default-fg-color--light);
    font-size: 0.66rem;
}

.md-typeset .landing-feature h2 {
    margin: 0 0 0.6rem;
    padding-bottom: 0;
    border-bottom: 0;
    font-size: 1.05rem;
}

.md-typeset .landing-feature > p:last-child {
    max-width: 72ch;
    margin: 0;
    font-size: 0.76rem;
    line-height: 1.75;
}

.md-typeset .landing-groups {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 1rem 2rem;
    align-items: start;
}

.md-typeset .landing-group {
    min-width: 0;
}

.md-typeset .landing-group:first-child {
    grid-column: 1 / -1;
}

.md-typeset .landing-footer {
    max-width: 76ch;
    margin-top: 1rem;
    padding-top: 0.9rem;
    border-top: 1px solid var(--md-default-fg-color--lightest);
    color: var(--md-default-fg-color--light);
    font-size: 0.7rem;
    line-height: 1.75;
}

.md-typeset .landing-footer p {
    margin: 0 0 0.4rem;
}

@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
    .md-typeset .landing-route {
        transition: transform 240ms cubic-bezier(.2, .7, .3, 1);
    }

    .md-typeset .landing-route:hover {
        transform: translateY(-3px);
    }
}

@media screen and (max-width: 59.984375em) {
    .md-typeset .landing-routes {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.65rem;
    }

    .md-typeset .landing-route {
        padding: 0.8rem 0.9rem;
    }
}

@media screen and (max-width: 34em) {
    .md-typeset .landing-groups {
        grid-template-columns: minmax(0, 1fr);
        gap: 1rem;
    }

    .md-typeset .landing-feature {
        padding: 0.85rem 0.9rem;
    }

    .md-typeset .notes-landing :is(h2, h3) > a:not(.headerlink) {
        display: inline-block;
        max-width: 100%;
    }

    .md-typeset .notes-landing .landing-title-translation {
        display: block;
        max-width: 100%;
        margin: 0.15em 0 0;
    }
}

/* ==========================================================================
   Back to Top
   ========================================================================== */

/* Sample the page on the control itself: Material's opacity transition would
   make a parent backdrop root and prevent a child surface seeing the page.
   Backdrop filtering leaves the label and arrow unfiltered. */
.md-top.edwinos-top-glass {
    --edwinos-top-tint: rgba(246, 248, 250, 0.2);
    --edwinos-top-hover-tint: rgba(246, 248, 250, 0.28);
    --edwinos-top-border: rgba(60, 60, 67, 0.2);
    --edwinos-top-highlight: rgba(255, 255, 255, 0.65);
    --edwinos-top-shadow: 0 3px 14px rgba(31, 35, 40, 0.13);
    font-family: "Inter", "Noto Sans SC", sans-serif;
    font-weight: 500;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    overflow: visible;
    background: var(--edwinos-top-tint);
    -webkit-backdrop-filter: blur(4px) saturate(1.12);
    backdrop-filter: blur(4px) saturate(1.12);
    box-shadow: var(--edwinos-top-shadow);
    color: #303641;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.6);
}

.md-top .edwinos-top__content {
    display: inline-flex;
    min-height: 1.2rem;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    vertical-align: middle;
}

.md-top .edwinos-top__content > svg {
    flex: none;
    width: 1rem;
    height: 1rem;
}

.md-top .edwinos-top__label {
    line-height: 1.2;
}

[data-md-color-scheme="slate"] .md-top.edwinos-top-glass {
    --edwinos-top-tint: rgba(25, 29, 37, 0.26);
    --edwinos-top-hover-tint: rgba(25, 29, 37, 0.34);
    --edwinos-top-border: rgba(240, 246, 252, 0.2);
    --edwinos-top-highlight: rgba(240, 246, 252, 0.24);
    --edwinos-top-shadow: 0 3px 14px rgba(1, 4, 9, 0.32);
    color: #dce2ea;
    text-shadow: 0 1px 2px rgba(1, 4, 9, 0.65);
}

.md-top.edwinos-top-glass > .edwinos-top-glass__highlight {
    position: absolute;
    inset: 0;
    z-index: -1;
    display: block;
    box-sizing: border-box;
    border-radius: inherit;
    pointer-events: none;
}

.md-top.edwinos-top-refraction {
    backdrop-filter: url(#edwinos-top-refraction) saturate(1.12);
}

.md-top.edwinos-top-glass > .edwinos-top-glass__highlight {
    border: 1px solid var(--edwinos-top-border);
    box-shadow:
        inset 0 1px 0 var(--edwinos-top-highlight),
        inset 0 -1px 0 rgba(31, 35, 40, 0.07);
}

.md-top.edwinos-top-glass:hover,
.md-top.edwinos-top-glass:focus {
    background: var(--edwinos-top-hover-tint);
    color: #303641;
}

[data-md-color-scheme="slate"] .md-top.edwinos-top-glass:hover,
[data-md-color-scheme="slate"] .md-top.edwinos-top-glass:focus {
    color: #dce2ea;
}

.md-top.edwinos-top-glass:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .md-top.edwinos-top-glass {
        --edwinos-top-tint: rgba(246, 248, 250, 0.94);
        --edwinos-top-hover-tint: rgba(246, 248, 250, 0.98);
    }

    [data-md-color-scheme="slate"] .md-top.edwinos-top-glass {
        --edwinos-top-tint: rgba(25, 29, 37, 0.94);
        --edwinos-top-hover-tint: rgba(25, 29, 37, 0.98);
    }
}

/* ==========================================================================
   Visitor Footer
   ========================================================================== */

.edwinos-notes-footer .edwinos-footer-metadata {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px 1rem;
    max-width: 100%;
    min-width: 0;
    padding: 0;
    text-align: center;
}

.academic-home-layout .academic-content .visitor-meta-footer,
.edwinos-notes-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    column-gap: 1rem;
    row-gap: 0.75rem;
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    margin: 1.65rem 0 0;
    padding-inline: 0;
    padding-top: 1.25rem;
    border-top: 1px solid var(--academic-card-border);
}

.academic-home-layout .academic-content .visitor-meta-footer__signature,
.edwinos-notes-footer .visitor-meta-footer__signature {
    display: flex;
    flex: 0 0 auto;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 0;
    color: var(--academic-muted);
    font-family: var(--edwinos-font-reading-sans);
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0;
    line-height: 1.45;
    text-align: center;
    white-space: nowrap;
}

.academic-home-layout .academic-content .visitor-meta-footer__metadata {
    display: flex;
    flex: 0 1 auto;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.75rem 1rem;
    max-width: 100%;
    min-width: 0;
}

.academic-home-layout .academic-content .visitor-meta-footer__license,
.edwinos-notes-footer .visitor-meta-footer__license {
    margin: 0;
    color: var(--academic-muted);
    font-family: var(--edwinos-font-reading-sans);
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0;
    line-height: 1.45;
}

.academic-home-layout .academic-content .visitor-meta-footer__separator,
.edwinos-notes-footer .visitor-meta-footer__separator {
    color: var(--academic-card-border);
}

.academic-home-layout .academic-content .visitor-container.visitor-badge-panel {
    display: flex !important;
    flex: 0 0 auto;
    align-items: center !important;
    justify-content: center !important;
    width: auto !important;
    max-width: none !important;
    min-width: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    transform: none !important;
    transition: none !important;
    white-space: nowrap !important;
}

.academic-home-layout .academic-content .visitor-badge-link {
    display: inline-flex !important;
    flex: 0 0 auto;
    align-items: center !important;
    justify-content: center !important;
    width: auto !important;
    max-width: none;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0;
    border: 0 !important;
    border-radius: 0.2rem;
    line-height: 0;
    text-decoration: none !important;
}

.academic-home-layout .academic-content .visitor-badge-link:focus-visible {
    outline: 2px solid var(--academic-accent);
    outline-offset: 3px;
    box-shadow: 0 0 0 1px var(--academic-card-bg);
}

.academic-home-layout .academic-content .visitor-badge-image {
    display: block !important;
    width: auto !important;
    max-width: none !important;
    height: auto !important;
    margin: 0 !important;
    object-fit: contain;
}

.academic-home-layout .academic-content .visitor-badge-image[hidden] {
    display: none !important;
}

.academic-home-layout .academic-content .visitor-badge-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 1.25rem;
    max-width: none;
    padding: 0;
    color: var(--academic-muted);
    font-family: var(--edwinos-font-reading-sans);
    font-size: 12px;
    font-weight: 400;
    line-height: 1.35;
    text-align: center;
    white-space: nowrap;
}

@media screen and (max-width: 36rem) {
    .academic-home-layout .academic-content .visitor-meta-footer,
    .edwinos-notes-footer {
        flex-direction: column;
        align-items: center;
        row-gap: 0.75rem;
        margin-top: 1.35rem;
        padding-inline: 0;
        padding-top: 1rem;
    }

    .academic-home-layout .academic-content .visitor-meta-footer__metadata {
        flex: 0 0 auto;
        flex-direction: row;
        width: 100%;
        text-align: center;
    }

    .academic-home-layout .academic-content .visitor-meta-footer__signature,
    .edwinos-notes-footer .visitor-meta-footer__signature {
        justify-content: center;
        gap: 0.32rem;
        font-size: 12px;
        text-align: center;
    }

    .academic-home-layout .academic-content .visitor-container.visitor-badge-panel {
        justify-content: center !important;
        width: auto !important;
    }
}
