/* ============================================================
   字体（@import 必须位于文件最顶部）
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Roboto+Slab:wght@400;500;700&family=Noto+Sans+SC:wght@400;500;700&display=swap');

/* ============================================================
   RoboSense 品牌主题层（对齐 robosense_manual_site 视觉风格）
   速腾红 #e21d23 · Roboto Slab 标题 · 蓝色正文链接
   ============================================================ */

/* ============================================================
   首页产品卡片（.rs-home / .rs-psec / .rs-card）
   ============================================================ */
:root {
  --rs-card-bg:   #17191d;
  --rs-card-bg2:  #1f2228;
  --rs-card-bd:   #23262c;
  --rs-card-bd-h: #33373f;
}

/* 首页容器：清掉 Material 给 typeset 子元素的默认 margin，避免大段空白 */
.rs-home { padding: 0 0 28px; }
.md-typeset .rs-home > *,
.md-typeset .rs-home section,
.md-typeset .rs-home .rs-hero { margin-top: 0; }

/* Hero */
.rs-hero { padding: 4px 0 8px; }
.rs-hero__eyebrow {
  font-family: var(--rs-disp);
  color: var(--rs-red);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.md-typeset .rs-hero__title {
  font-family: var(--rs-disp);
  font-weight: 700;
  font-size: 30px;
  color: var(--rs-ink);
  margin: 0;
}
/* 首页大标题不要正文那条红色短横线 */
.md-typeset .rs-hero__title::after { content: none; }

/* Platform sections */
.rs-psec { padding: 18px 0 6px; }
.rs-psec__head {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.rs-psec__badge {
  font-family: var(--rs-disp);
  font-weight: 700;
  font-size: 13px;
  padding: 5px 13px;
  border-radius: 8px;
  color: #fff;
  white-space: nowrap;
}
.rs-psec--em .rs-psec__badge { background: #cf9319; }
.rs-psec--e  .rs-psec__badge { background: #9b4d97; }
.rs-psec--r  .rs-psec__badge { background: #0f9d8f; }
.rs-psec--m  .rs-psec__badge { background: #3a6fc4; }
.md-typeset .rs-psec__title {
  font-family: var(--rs-disp);
  font-weight: 700;
  font-size: 21px;
  color: var(--rs-ink);
  margin: 0;
  border-left: 0;
  padding-left: 0;
}
.md-typeset .rs-psec__title::after { content: none; }
.rs-psec__cnt { font-size: 13px; color: #9aa0a8; }
.rs-psec__ln { flex: 1; height: 1px; background: #e7e9ec; min-width: 20px; }

/* Card grid */
.rs-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
@media (max-width: 1200px) { .rs-cards { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 860px)  { .rs-cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 540px)  { .rs-cards { grid-template-columns: 1fr; } }

/* Individual card */
.rs-card {
  display: flex;
  flex-direction: column;
  background: var(--rs-card-bg);
  border: 1px solid var(--rs-card-bd);
  border-radius: 14px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform .2s, border-color .2s, box-shadow .2s;
}
.rs-card:hover {
  transform: translateY(-5px);
  border-color: var(--rs-card-bd-h);
  box-shadow: 0 20px 40px -24px rgba(0,0,0,.55);
}

/* Card image area */
.rs-card__img {
  height: 148px;
  background: radial-gradient(ellipse 70% 60% at 50% 38%, #2a2e35, #0c0d10);
  display: grid;
  place-items: center;
  position: relative;
}
.rs-card__glyph { font-size: 44px; color: #41464f; transition: color .2s; }
.rs-card:hover .rs-card__glyph { color: #565c66; }
.rs-card__wm {
  position: absolute;
  right: 13px; bottom: 10px;
  font-family: var(--rs-disp);
  font-size: 11px;
  color: #3c4148;
  letter-spacing: .05em;
}
.rs-card__pill {
  position: absolute;
  left: 13px; top: 13px;
  font-size: 10.5px;
  color: #cfd3da;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.14);
  padding: 3px 9px;
  border-radius: 20px;
}

/* Card meta */
.rs-card__meta {
  padding: 14px 16px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.rs-card__name {
  font-family: var(--rs-disp);
  font-weight: 700;
  font-size: 18px;
  color: #fff;
  margin: 0;
}
.rs-card__view {
  font-size: 13px;
  color: #fff;
  border: 1px solid rgba(255,255,255,.28);
  padding: 6px 13px;
  border-radius: 9px;
  white-space: nowrap;
  transition: background .15s, border-color .15s;
}
.rs-card:hover .rs-card__view {
  background: var(--rs-red);
  border-color: var(--rs-red);
}

/* ============================================================
   侧栏头部红色 Logo 区（补强）
   ============================================================ */

:root {
  /* 用精确品牌色覆盖 Material 的 red 预设 */
  --md-primary-fg-color:            #e21d23;
  --md-primary-fg-color--light:     #e8484d;
  --md-primary-fg-color--dark:      #c5161b;
  --md-accent-fg-color:             #e21d23;
  --md-accent-fg-color--transparent: rgba(226, 29, 35, 0.10);
}

/* Material 用属性选择器定义调色板，优先级高于 :root —— 必须用同等选择器覆盖，
   否则顶栏会保留 Material 默认浅红，与侧栏品牌红产生色差 */
[data-md-color-primary="red"] {
  --md-primary-fg-color:        #e21d23;
  --md-primary-fg-color--light: #e21d23;
  --md-primary-fg-color--dark:  #c5161b;

  /* 参考站配套色 */
  --rs-red:    #e21d23;
  --rs-red-d:  #c5161b;
  --rs-blue:   #2980b9;
  --rs-ink:    #2b2b2b;
  --rs-disp:   'Roboto Slab', 'Noto Sans SC', serif;

  /* 正文链接改为参考站的蓝色 */
  --md-typeset-a-color: #2980b9;
}

/* 顶栏文字/图标在红底上保持白色（Material 已处理，这里固化对比度） */
.md-header,
.md-tabs {
  color: #ffffff;
}

/* 标题统一使用展示字体 Roboto Slab，呼应参考站 */
.md-typeset h1,
.md-typeset h2,
.md-typeset h3,
.md-typeset h4,
.md-typeset h5,
.md-header__title,
.md-nav__title {
  font-family: var(--rs-disp);
}

.md-typeset h1 {
  color: var(--rs-ink);
  font-weight: 700;
}

/* 左侧导航：当前条目用红色左边框 + 红字，复刻参考站 active 样式 */
.md-nav__link--active,
.md-nav__item .md-nav__link--active {
  color: var(--rs-red);
  font-weight: 700;
}

.md-nav__list .md-nav__item > .md-nav__link--active {
  border-left: 3px solid var(--rs-red);
  padding-left: calc(0.6rem - 3px);
}

/* 右侧目录（TOC）当前章节高亮为品牌红 */
.md-nav--secondary .md-nav__link--active {
  color: var(--rs-red);
}

/* 正文链接 hover 加深 */
.md-typeset a:hover {
  color: var(--rs-red-d);
}

/* 搜索框聚焦、各类强调元素跟随品牌红（accent 已覆盖，此处补强） */
.md-search__input:focus,
.md-search__input:hover {
  background-color: rgba(255, 255, 255, 0.4);
}

/* 行内代码与提示块强调色对齐红系，避免残留靛蓝 */
.md-typeset .md-button--primary {
  background-color: var(--rs-red);
  border-color: var(--rs-red);
  color: #ffffff;
}
.md-typeset .md-button--primary:hover {
  background-color: var(--rs-red-d);
  border-color: var(--rs-red-d);
}

/* 暗色模式下保持品牌红主色 */
[data-md-color-scheme="slate"] {
  --md-primary-fg-color:        #e21d23;
  --md-primary-fg-color--light: #e8484d;
  --md-primary-fg-color--dark:  #c5161b;
  --md-accent-fg-color:         #e8484d;
  --md-typeset-a-color:         #5aa9dc;
}

/* ============================================================
   深色左侧栏（复刻 robosense_manual_site 侧栏）
   仅作用于主侧栏；右侧 TOC「目录」保持浅色
   ============================================================ */
:root {
  --rs-side:     #2d2b2a;  /* 侧栏底色 */
  --rs-side-2:   #262423;  /* hover 底色 */
  --rs-side-hi:  #3a3836;  /* active 底色 */
  --rs-side-txt: #d6d2cf;  /* 一级文字 */
  --rs-side-dim: #9a938e;  /* 二级文字 */
}

/* 侧栏整体深色 */
.md-sidebar--primary {
  background-color: var(--rs-side);
}
.md-sidebar--primary .md-sidebar__scrollwrap {
  background-color: var(--rs-side);
}
.md-sidebar--primary .md-sidebar__scrollwrap::-webkit-scrollbar {
  width: 7px;
}
.md-sidebar--primary .md-sidebar__scrollwrap::-webkit-scrollbar-thumb {
  background: #555049;
  border-radius: 4px;
}

/* 顶部「RoboSense wiki」红块：仅作用于主侧栏最外层标题 */
.md-sidebar--primary > .md-sidebar__scrollwrap > .md-nav--primary > .md-nav__title {
  color: #ffffff;
  background-color: var(--md-primary-fg-color);
}

/* 隐藏嵌套分组内的标题副本（移动端抽屉才用，桌面会造成多余缩进/重复） */
.md-sidebar--primary .md-nav .md-nav__title {
  display: none;
}

/* 清零 Material 嵌套 nav/list/item 自带的左右边距与内边距，统一由 link 控制缩进 */
.md-sidebar--primary .md-nav,
.md-sidebar--primary .md-nav__list,
.md-sidebar--primary .md-nav__item {
  margin: 0;
  padding: 0;
}

/* 所有条目基础样式：红条用内阴影实现（不挤压文字） */
.md-sidebar--primary .md-nav__link {
  color: var(--rs-side-dim);
  margin: 0;
  padding-top: .42rem;
  padding-bottom: .42rem;
  padding-right: .8rem;
  box-shadow: inset 3px 0 0 transparent;
  transition: background-color .12s, color .12s, box-shadow .12s;
}
.md-sidebar--primary .md-nav__link:hover {
  color: #ffffff;
  background-color: var(--rs-side-2);
}

/* —— 第一层：首页 + 平台分组标题，统一左基线 1rem —— */
.md-sidebar--primary .md-nav--primary > .md-nav__list > .md-nav__item > .md-nav__link {
  padding-left: 1rem;
}

/* 平台分组标题白色加粗（与首页同一基线，仅字色/字重不同） */
.md-sidebar--primary .md-nav--primary > .md-nav__list > .md-nav__item--section > .md-nav__link {
  color: #ffffff;
  font-family: var(--rs-disp);
  font-weight: 500;
}

/* —— 第二层：产品条目，缩进 1.9rem —— */
.md-sidebar--primary .md-nav--primary .md-nav .md-nav__list > .md-nav__item > .md-nav__link {
  padding-left: 1.9rem;
}

/* 当前条目：红色左条（内阴影）+ 白字 + 深色高亮底，文字不偏移 */
.md-sidebar--primary .md-nav__link--active {
  color: #ffffff;
  box-shadow: inset 3px 0 0 var(--rs-red);
  background-color: var(--rs-side-hi);
  font-weight: 700;
}

/* 展开/折叠箭头图标变浅，深底上可见 */
.md-sidebar--primary .md-nav__icon,
.md-sidebar--primary .md-nav__button {
  color: var(--rs-side-dim);
}

/* 暗色模式下侧栏维持同一深色，不被 slate 主题覆盖 */
[data-md-color-scheme="slate"] .md-sidebar--primary,
[data-md-color-scheme="slate"] .md-sidebar--primary .md-sidebar__scrollwrap {
  background-color: var(--rs-side);
}

/* ============================================================
   手机版导航抽屉适配（窗口/预览宽度 < 1220px 时）
   抽屉是白底，但侧栏文字是为「桌面深色侧栏」设的白色 → 白底白字看不见；
   且 Material 手机版默认逐层下钻，进到某产品后只剩该平台、回不到首页。
   这里在手机版断点里：① 文字改深色/红色；② 嵌套导航平铺展开。
   只在 <1220px 生效，不影响桌面深色侧栏。
   ============================================================ */
@media screen and (max-width: 76.1875em) {
  /* 一级链接（如「首页」）与产品条目：深色 */
  .md-sidebar--primary .md-nav__link {
    color: var(--rs-ink);
  }
  /* 平台分组标题（EM平台/E平台/R平台）：深色加粗 */
  .md-sidebar--primary .md-nav--primary > .md-nav__list > .md-nav__item--section > .md-nav__link {
    color: var(--rs-ink);
    font-weight: 600;
  }
  /* 展开/折叠箭头：深色 */
  .md-sidebar--primary .md-nav__icon,
  .md-sidebar--primary .md-nav__button {
    color: var(--rs-ink);
  }
  /* 当前页：白底上用红字 + 红色左条 */
  .md-sidebar--primary .md-nav__link--active {
    color: var(--rs-red);
    background-color: transparent;
    box-shadow: inset 3px 0 0 var(--rs-red);
  }
  /* 悬停：浅灰底 + 红字 */
  .md-sidebar--primary .md-nav__link:hover {
    color: var(--rs-red);
    background-color: rgba(0, 0, 0, .04);
  }

  /* ---- 让嵌套导航「平铺展开」，而不是逐层下钻 ----
     这样不论在哪个产品页，侧栏都同时列出全部平台 + 全部产品，
     并且左上角 logo / 首页 入口始终在最上方，随时能回首页。 */
  .md-sidebar--primary .md-nav--primary .md-nav {
    position: static !important;
    transform: none !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    display: block !important;
  }
  /* 平铺后下钻面板自带的返回头多余，隐藏 */
  .md-sidebar--primary .md-nav--primary .md-nav > .md-nav__title {
    display: none !important;
  }
  /* 分组标题旁的展开箭头在平铺模式下没意义，隐藏 */
  .md-sidebar--primary .md-nav--primary > .md-nav__list > .md-nav__item--section > .md-nav__link > .md-nav__icon {
    display: none;
  }
}

/* ============================================================
   正文内容细节优化
   ============================================================ */

/* 正文背景微暖灰，区别于纯白 */
.md-content { background: #f6f7f9; }
.md-content__inner { background: #fff; border-radius: 12px; padding: 1.2rem 2.4rem 1.6rem; margin: .6rem 0; box-shadow: 0 1px 4px rgba(0,0,0,.06); }
/* 首页内容区取消多余顶/底留白，更紧凑 */
.md-content__inner:has(.rs-home) { padding-top: .6rem; }
.md-typeset .rs-home { margin: 0; }

/* h1 下方红色分割线 */
.md-typeset h1::after {
  content: '';
  display: block;
  margin-top: 10px;
  height: 3px;
  width: 48px;
  background: var(--rs-red);
  border-radius: 2px;
}

/* h2 左侧红色边框 */
.md-typeset h2 {
  border-left: 4px solid var(--rs-red);
  padding-left: .65rem;
  margin-left: -4px;
}

/* 正文表格样式对齐参考站 */
.md-typeset table:not([class]) {
  border-collapse: collapse;
  width: 100%;
}
.md-typeset table:not([class]) th {
  background: #eeeeee;
  font-weight: 700;
  text-align: center;
}
.md-typeset table:not([class]) th,
.md-typeset table:not([class]) td {
  border: 1px solid #9e9e9e;
  padding: .5rem .75rem;
  vertical-align: middle;
}
[data-md-color-scheme="slate"] .md-typeset table:not([class]) th {
  background: #424242;
}
[data-md-color-scheme="slate"] .md-content { background: #1a1c20; }
[data-md-color-scheme="slate"] .md-content__inner { background: #22252b; }

/* ============================================================
   侧栏顶部 site title 红底白字强化
   ============================================================ */
.md-header__button.md-logo img,
.md-header__button.md-logo svg { filter: brightness(0) invert(1); }

/* 顶部 tab 栏字重 */
.md-tabs__link { font-family: var(--rs-disp); font-weight: 500; }
.md-tabs__link--active,
.md-tabs__link:hover { opacity: 1; }

/* ============================================================
   以下为本项目原有的手册正文表格/图片样式（保持不变）
   ============================================================ */
/* 独立成段的 Markdown 图片居中（如 1.5 节安全标识图） */
.md-typeset p:has(> img:only-child) {
  text-align: center;
  margin: 0.75em auto 1em;
}

.md-typeset p:has(> img:only-child) img {
  display: inline-block;
  margin: 0 auto;
  max-width: min(100%, 360px);
  height: auto;
}

/* 插图缩放（单独一行图片加 class，需 mkdocs.yml 中 attr_list） */
.md-typeset img.manual-img--sm,
.md-typeset p:has(> img:only-child) img.manual-img--sm {
  max-width: min(100%, 200px);
}

.md-typeset img.manual-img--md,
.md-typeset p:has(> img:only-child) img.manual-img--md {
  max-width: min(100%, 360px);
}

.md-typeset img.manual-img--lg,
.md-typeset p:has(> img:only-child) img.manual-img--lg {
  max-width: min(100%, 560px);
}

.md-typeset img.manual-img--xl,
.md-typeset p:has(> img:only-child) img.manual-img--xl {
  max-width: min(100%, 720px);
}

.md-typeset img.manual-img--full,
.md-typeset p:has(> img:only-child) img.manual-img--full {
  max-width: 100%;
}

/* 3.1 线束说明表格（HTML rowspan） */
.md-typeset table.wire-harness-table {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
  table-layout: fixed;
  border-collapse: collapse;
}

.md-typeset table.wire-harness-table th,
.md-typeset table.wire-harness-table td {
  vertical-align: middle;
  text-align: center;
  border: 1px solid #9e9e9e;
  padding: 0.45rem 0.35rem;
}

.md-typeset table.wire-harness-table thead th {
  background-color: #eeeeee;
  font-weight: 700;
}

.md-typeset table.wire-harness-table col.wh-col-a {
  width: 9.5rem;
}

.md-typeset table.wire-harness-table col.wh-col-b {
  width: 10.75rem;
}

.md-typeset table.wire-harness-table col.wh-col-pin {
  width: 2.75rem;
}

.md-typeset table.wire-harness-table col.wh-col-def {
  width: 11.5rem;
}

.md-typeset table.wire-harness-table col.wh-col-desc {
  width: 13.5rem;
}

.md-typeset table.wire-harness-table td.wh-connector {
  font-size: 0.92em;
  line-height: 1.4;
  padding-left: 0.3rem;
  padding-right: 0.3rem;
}

.md-typeset table.wire-harness-table tbody td:nth-child(3) {
  white-space: nowrap;
}

[data-md-color-scheme="slate"] .md-typeset table.wire-harness-table thead th {
  background-color: #424242;
}

/* DIFOP 等协议包定义表（rowspan / colspan） */
.md-typeset table.packet-def-table {
  width: 100%;
  border-collapse: collapse;
}

.md-typeset table.packet-def-table th,
.md-typeset table.packet-def-table td {
  vertical-align: middle;
  text-align: center;
  border: 1px solid #9e9e9e;
  padding: 0.4rem 0.5rem;
}

.md-typeset table.packet-def-table thead th {
  background-color: #f0f0f0;
  font-weight: 600;
}

[data-md-color-scheme="slate"] .md-typeset table.packet-def-table thead th {
  background-color: #3a3a3a;
}

/* 产品协议一览表（MSOP 固定/压缩模式分行，见 EM4 表7） */
.md-typeset table.product-protocol-table {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
  table-layout: fixed;
}

.md-typeset table.product-protocol-table col.pp-col-name {
  width: 14rem;
}

.md-typeset table.product-protocol-table col.pp-col-abbr {
  width: 4.75rem;
}

.md-typeset table.product-protocol-table col.pp-col-func {
  width: 7rem;
}

.md-typeset table.product-protocol-table col.pp-col-type {
  width: 3.25rem;
}

.md-typeset table.product-protocol-table col.pp-col-size {
  width: 15rem;
}

.md-typeset table.product-protocol-table col.pp-col-rate {
  width: 13rem;
}

.md-typeset table.product-protocol-table th:nth-child(2),
.md-typeset table.product-protocol-table th:nth-child(3),
.md-typeset table.product-protocol-table th:nth-child(4),
.md-typeset table.product-protocol-table td:nth-child(2),
.md-typeset table.product-protocol-table td:nth-child(3),
.md-typeset table.product-protocol-table td:nth-child(4) {
  white-space: nowrap;
}

.md-typeset table.product-protocol-table td.protocol-size-compressed {
  line-height: 1.45;
  font-size: 0.92em;
  white-space: normal;
}

.md-typeset table.product-protocol-table td:first-child {
  white-space: normal;
}

/* MSOP 字段定义表（变量/偏置/长度居中，内容左对齐，见 EM4 表8） */
.md-typeset table.msop-data-table {
  width: 100%;
  table-layout: fixed;
}

.md-typeset table.msop-data-table col.msop-col-var {
  width: 11rem;
}

.md-typeset table.msop-data-table col.msop-col-offset,
.md-typeset table.msop-data-table col.msop-col-len {
  width: 5.5rem;
}

.md-typeset table.msop-data-table td.msop-content {
  text-align: left;
  vertical-align: middle;
  line-height: 1.5;
}

.md-typeset table.msop-data-table .msop-subline {
  display: block;
  padding-left: 1.25em;
  margin-top: 0.2em;
}

.md-typeset table.msop-data-table .msop-note {
  display: block;
  padding-left: 1.25em;
  margin-top: 0.2em;
}

/* MSOP 字段表：前三列按内容自适应（见 EMX 表6） */
.md-typeset table.msop-data-table.msop-data-table--auto-label-cols {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
  table-layout: auto;
}

.md-typeset table.msop-data-table.msop-data-table--auto-label-cols col.msop-col-var,
.md-typeset table.msop-data-table.msop-data-table--auto-label-cols col.msop-col-offset,
.md-typeset table.msop-data-table.msop-data-table--auto-label-cols col.msop-col-len {
  width: auto;
}

.md-typeset table.msop-data-table.msop-data-table--auto-label-cols th:nth-child(1),
.md-typeset table.msop-data-table.msop-data-table--auto-label-cols th:nth-child(2),
.md-typeset table.msop-data-table.msop-data-table--auto-label-cols th:nth-child(3),
.md-typeset table.msop-data-table.msop-data-table--auto-label-cols td:nth-child(1),
.md-typeset table.msop-data-table.msop-data-table--auto-label-cols td:nth-child(2),
.md-typeset table.msop-data-table.msop-data-table--auto-label-cols td:nth-child(3) {
  width: 1%;
  white-space: nowrap;
}

.md-typeset table.msop-data-table.msop-data-table--auto-label-cols td.msop-content {
  white-space: normal;
  min-width: 14rem;
}

/* MSOP Header 字段表（信息列浅底，见 Airy 表9） */
.md-typeset table.msop-header-table {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
  table-layout: auto;
}

.md-typeset table.msop-header-table th:nth-child(1),
.md-typeset table.msop-header-table td:nth-child(1) {
  white-space: nowrap;
}

.md-typeset table.msop-header-table col.msop-col-offset,
.md-typeset table.msop-header-table col.msop-col-len {
  width: auto;
}

.md-typeset table.msop-header-table col.msop-col-total {
  width: 1%;
}

.md-typeset table.msop-header-table td:first-child {
  background-color: #fffde7;
}

[data-md-color-scheme="slate"] .md-typeset table.msop-header-table td:first-child {
  background-color: #3d3822;
}

.md-typeset table.msop-header-table td:nth-child(4) {
  text-align: left;
}

.md-typeset table.msop-header-table th:nth-child(5),
.md-typeset table.msop-header-table td[rowspan] {
  width: 1%;
  white-space: nowrap;
  padding-left: 0.35rem;
  padding-right: 0.35rem;
}

/* Data Block 单包字段表（见 Fairy 表11）；信息列用 class 标记，避免 rowspan 时 td:first-child 错位着色 */
.md-typeset table.data-block-def-table {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
  table-layout: auto;
}

.md-typeset table.data-block-def-table th:nth-child(1),
.md-typeset table.data-block-def-table td.field-col {
  white-space: nowrap;
}

.md-typeset table.data-block-def-table col.msop-col-offset,
.md-typeset table.data-block-def-table col.msop-col-len {
  width: auto;
}

.md-typeset table.data-block-def-table col.msop-col-total {
  width: 1%;
}

.md-typeset table.data-block-def-table td.field-col {
  background-color: #fffde7;
}

[data-md-color-scheme="slate"] .md-typeset table.data-block-def-table td.field-col {
  background-color: #3d3822;
}

.md-typeset table.data-block-def-table td:nth-child(4) {
  text-align: left;
}

.md-typeset table.data-block-def-table th:nth-child(5),
.md-typeset table.data-block-def-table td[rowspan] {
  width: 1%;
  white-space: nowrap;
  padding-left: 0.35rem;
  padding-right: 0.35rem;
}

/* Data Block 结构表（双行表头，见 Airy 表10） */
.md-typeset table.data-block-table {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
}

.md-typeset table.data-block-table td:first-child,
.md-typeset table.data-block-table thead tr:nth-child(2) th:first-child {
  background-color: #f5f5f5;
  font-weight: 600;
}

[data-md-color-scheme="slate"] .md-typeset table.data-block-table td:first-child,
[data-md-color-scheme="slate"] .md-typeset table.data-block-table thead tr:nth-child(2) th:first-child {
  background-color: #3a3a3a;
}

/* Channel Data 示意表（见 Airy 表11） */
.md-typeset table.channel-data-table {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
}

.md-typeset table.channel-data-table--two-col {
  width: 100%;
  max-width: 28rem;
  table-layout: fixed;
}

.md-typeset table.channel-data-table--two-col col.channel-data-col-distance {
  width: 66.67%;
}

.md-typeset table.channel-data-table--two-col col.channel-data-col-reflectivity {
  width: 33.33%;
}

/* 宽表横向滚动（不压住右侧目录；见表12 等） */
.md-typeset .manual-table-scroll-wrap {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  margin: 0 0 1.25em;
  -webkit-overflow-scrolling: touch;
}

.md-typeset .manual-table-scroll-wrap > table {
  margin: 0;
}

/* 压缩块结构表（12 列合并，见 EM4 表12） */
.md-typeset .manual-table-scroll-wrap table.compression-block-table {
  width: max-content;
  min-width: 100%;
  table-layout: fixed;
  font-size: 0.85em;
}

.md-typeset .manual-table-scroll-wrap table.compression-block-table th,
.md-typeset .manual-table-scroll-wrap table.compression-block-table td {
  padding: 0.35rem 0.25rem;
}

.md-typeset .manual-table-scroll-wrap table.compression-block-table thead th {
  background-color: #eeeeee;
  font-weight: 700;
}

.md-typeset .manual-table-scroll-wrap table.compression-block-table col.cb-col-fixed {
  width: 3.25rem;
}

.md-typeset .manual-table-scroll-wrap table.compression-block-table col.cb-col-diff {
  width: 3rem;
}

.md-typeset .manual-table-scroll-wrap table.compression-block-table col.cb-col-ellipsis {
  width: 2rem;
}

.md-typeset .manual-table-scroll-wrap table.compression-block-table th,
.md-typeset .manual-table-scroll-wrap table.compression-block-table td {
  word-break: keep-all;
  overflow-wrap: normal;
}

[data-md-color-scheme="slate"] .md-typeset .manual-table-scroll-wrap table.compression-block-table thead th {
  background-color: #424242;
}

/* Airy 附录 D 通道测距表（双栏并排，见 Airy 表32） */
.md-typeset .manual-table-scroll-wrap table.airy-channel-table {
  width: 100%;
  table-layout: fixed;
  font-size: 0.85em;
}

.md-typeset .manual-table-scroll-wrap table.airy-channel-table th,
.md-typeset .manual-table-scroll-wrap table.airy-channel-table td {
  padding: 0.35rem 0.2rem;
  text-align: center;
  vertical-align: middle;
  word-break: keep-all;
}

.md-typeset .manual-table-scroll-wrap table.airy-channel-table thead th {
  background-color: #eeeeee;
  font-weight: 700;
}

[data-md-color-scheme="slate"] .md-typeset .manual-table-scroll-wrap table.airy-channel-table thead th {
  background-color: #424242;
}

/* DIFOP 数据包字段表（分组 rowspan，见 EM4 表13） */
.md-typeset .manual-table-scroll-wrap table.difop-packet-table {
  width: max-content;
  min-width: 100%;
  table-layout: fixed;
  font-size: 0.88em;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table col.difop-col-group {
  width: 8.5rem;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table col.difop-col-var {
  width: 12rem;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table col.difop-col-offset,
.md-typeset .manual-table-scroll-wrap table.difop-packet-table col.difop-col-len {
  width: 4.75rem;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table col.difop-col-content {
  width: 10rem;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table td.difop-group {
  font-weight: 600;
  vertical-align: middle;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table td.difop-content {
  text-align: left;
  vertical-align: middle;
  line-height: 1.45;
  white-space: normal;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table thead th {
  background-color: #eeeeee;
  font-weight: 700;
}

[data-md-color-scheme="slate"] .md-typeset .manual-table-scroll-wrap table.difop-packet-table thead th {
  background-color: #424242;
}

/* Airy 表12：序号 / 信息 / Offset 按内容收窄，说明列占剩余宽度 */
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table {
  table-layout: auto;
  width: 100%;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table col.difop-col-group,
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table col.difop-col-var,
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table col.difop-col-offset,
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table col.difop-col-len,
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table col.difop-col-content {
  width: auto;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table th:nth-child(1),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table th:nth-child(2),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table th:nth-child(3),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table td:nth-child(1),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table td:nth-child(2),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.airy-difop-layout-table td:nth-child(3) {
  width: 1%;
  white-space: nowrap;
}

/* Fairy 表13 等 4 列 DIFOP 表：信息列自适应换行，Offset/长度收窄，说明列占剩余宽度 */
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table {
  table-layout: auto;
  width: 100%;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table col.difop-col-var,
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table col.difop-col-offset,
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table col.difop-col-len,
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table col.difop-col-content {
  width: auto;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table th:nth-child(1),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table td:nth-child(1) {
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
  width: auto;
  max-width: 11em;
  vertical-align: middle;
}

.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table th:nth-child(2),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table th:nth-child(3),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table td:nth-child(2),
.md-typeset .manual-table-scroll-wrap table.difop-packet-table.fairy-difop-layout-table td:nth-child(3) {
  width: 1%;
  white-space: nowrap;
}

/* Fairy 表14 等 5 列 IMU 表：信息列自适应换行，Offset/长度收窄，说明/备注列左对齐换行 */
.md-typeset .manual-table-scroll-wrap table.packet-def-table.fairy-imu-layout-table {
  table-layout: auto;
  width: 100%;
}

.md-typeset .manual-table-scroll-wrap table.packet-def-table.fairy-imu-layout-table th:nth-child(1),
.md-typeset .manual-table-scroll-wrap table.packet-def-table.fairy-imu-layout-table td:nth-child(1) {
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
  width: auto;
  max-width: 11em;
  vertical-align: middle;
}

.md-typeset .manual-table-scroll-wrap table.packet-def-table.fairy-imu-layout-table th:nth-child(2),
.md-typeset .manual-table-scroll-wrap table.packet-def-table.fairy-imu-layout-table th:nth-child(3),
.md-typeset .manual-table-scroll-wrap table.packet-def-table.fairy-imu-layout-table td:nth-child(2),
.md-typeset .manual-table-scroll-wrap table.packet-def-table.fairy-imu-layout-table td:nth-child(3) {
  width: 1%;
  white-space: nowrap;
}

.md-typeset .manual-table-scroll-wrap table.packet-def-table.fairy-imu-layout-table td.difop-content {
  text-align: left;
  white-space: normal;
  line-height: 1.45;
}

/* 接插件引脚定义表（见 EM4 附录 A） */
.md-typeset table.connector-pin-table {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
  table-layout: fixed;
  border-collapse: collapse;
}

.md-typeset table.connector-pin-table th,
.md-typeset table.connector-pin-table td {
  text-align: center;
  vertical-align: middle;
  border: 1px solid #9e9e9e;
  padding: 0.45rem 0.75rem;
}

.md-typeset table.connector-pin-table thead th {
  background-color: #eeeeee;
  font-weight: 700;
}

.md-typeset table.connector-pin-table col.connector-col-pin {
  width: 4.5rem;
}

.md-typeset table.connector-pin-table col.connector-col-def {
  width: 9rem;
}

.md-typeset table.connector-pin-table col.connector-col-model {
  width: 7.5rem;
}

[data-md-color-scheme="slate"] .md-typeset table.connector-pin-table thead th {
  background-color: #424242;
}

/* 故障排查表（两列，见 EM4 表15） */
.md-typeset table.fault-troubleshoot-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
}

.md-typeset table.fault-troubleshoot-table col.fault-col-phenomenon {
  width: 32%;
}

.md-typeset table.fault-troubleshoot-table col.fault-col-solution {
  width: 68%;
}

.md-typeset table.fault-troubleshoot-table th,
.md-typeset table.fault-troubleshoot-table td {
  border: 1px solid #9e9e9e;
  padding: 0.5rem 0.75rem;
  vertical-align: top;
  text-align: left;
  line-height: 1.5;
}

.md-typeset table.fault-troubleshoot-table thead th {
  background-color: #eeeeee;
  font-weight: 700;
  vertical-align: middle;
  text-align: center;
}

[data-md-color-scheme="slate"] .md-typeset table.fault-troubleshoot-table thead th {
  background-color: #424242;
}

/* 规格参数分栏表（节标题灰底、四列/输出区两列，如 EM4 表2） */
.md-typeset table.manual-spec-grid-table {
  width: 100%;
  max-width: 100%;
  border-collapse: collapse;
  border: 1px solid #9e9e9e;
  margin: 0 0 0.5em;
}

.md-typeset table.manual-spec-grid-table th,
.md-typeset table.manual-spec-grid-table td {
  border: 1px solid #9e9e9e;
  padding: 0.5rem 0.75rem;
  vertical-align: middle;
}

.md-typeset table.manual-spec-grid-table tr.section-head th {
  background-color: #eeeeee;
  text-align: center;
  font-weight: 700;
}

.md-typeset table.manual-spec-grid-table td.spec-label {
  width: 18%;
  text-align: center;
  font-weight: 600;
}

.md-typeset table.manual-spec-grid-table td.spec-value {
  text-align: left;
}

.md-typeset table.manual-spec-grid-table .spec-subline {
  display: block;
  padding-left: 1.25em;
  margin-top: 0.15em;
}

.md-typeset table.manual-spec-grid-table .spec-note-line {
  display: block;
  margin-top: 0.35em;
}

[data-md-color-scheme="slate"] .md-typeset table.manual-spec-grid-table tr.section-head th {
  background-color: #424242;
}

/* 接线说明表（图文两列，如 Fairy 表7） */
.md-typeset table.manual-spec-grid-table.wiring-instruction-table {
  table-layout: fixed;
}

.md-typeset table.manual-spec-grid-table.wiring-instruction-table tr.section-head th:first-child,
.md-typeset table.manual-spec-grid-table.wiring-instruction-table td.wiring-desc {
  width: 50%;
  text-align: left;
  font-weight: 400;
  vertical-align: middle;
  line-height: 1.55;
}

.md-typeset table.manual-spec-grid-table.wiring-instruction-table tr.section-head th:last-child,
.md-typeset table.manual-spec-grid-table.wiring-instruction-table td.wiring-diagram {
  width: 50%;
  text-align: center;
  vertical-align: middle;
}

.md-typeset .spec-footnotes {
  margin-top: 0.5em;
  font-size: 0.85em;
  line-height: 1.55;
  color: var(--md-default-fg-color--light);
}

.md-typeset .spec-footnotes p {
  margin: 0.35em 0;
}

/* 表题 + 居中数据表（灰表头、横线分隔，如表1 FOV） */
.md-typeset p.manual-table-caption {
  text-align: center;
  font-weight: 700;
  margin: 0.75em auto 0.35em;
}

.md-typeset .manual-table-wrap {
  margin: 0 auto 1.25em;
  width: fit-content;
  max-width: 100%;
}

.md-typeset .manual-table-wrap table {
  margin: 0;
  width: 100%;
  border-collapse: collapse;
  border: 1px solid #bdbdbd;
}

.md-typeset .manual-table-wrap th,
.md-typeset .manual-table-wrap td {
  text-align: center;
  vertical-align: middle;
  padding: 0.45rem 1.25rem;
  border: 0;
  border-bottom: 1px solid #bdbdbd;
}

.md-typeset .manual-table-wrap thead th {
  background-color: #eeeeee;
  font-weight: 700;
  border-bottom: 1px solid #9e9e9e;
}

.md-typeset .manual-table-wrap tbody tr:last-child td {
  border-bottom: 0;
}

[data-md-color-scheme="slate"] .md-typeset .manual-table-wrap table {
  border-color: #616161;
}

[data-md-color-scheme="slate"] .md-typeset .manual-table-wrap thead th {
  background-color: #424242;
}

[data-md-color-scheme="slate"] .md-typeset .manual-table-wrap th,
[data-md-color-scheme="slate"] .md-typeset .manual-table-wrap td {
  border-bottom-color: #616161;
}

/* 配件清单表（序号/数量列收窄，见 Airy 表4） */
.md-typeset .manual-table-wrap table.accessories-table th:nth-child(1),
.md-typeset .manual-table-wrap table.accessories-table th:nth-child(4),
.md-typeset .manual-table-wrap table.accessories-table td:nth-child(1),
.md-typeset .manual-table-wrap table.accessories-table td:nth-child(4) {
  width: 1%;
  white-space: nowrap;
}

/* 引脚定义表（见 Airy 表5） */
.md-typeset .manual-table-wrap table.pin-def-table th:nth-child(1),
.md-typeset .manual-table-wrap table.pin-def-table th:nth-child(2),
.md-typeset .manual-table-wrap table.pin-def-table td:nth-child(1),
.md-typeset .manual-table-wrap table.pin-def-table td:nth-child(2) {
  width: 1%;
  white-space: nowrap;
}

/* 回波模式对照表（DIFOP Offset 列 rowspan，见 Airy 表2） */
.md-typeset table.echo-mode-table {
  width: max-content;
  max-width: 100%;
  margin: 0 auto 1.25em;
}

.md-typeset table.echo-mode-table th:nth-child(1),
.md-typeset table.echo-mode-table td:nth-child(1) {
  width: 1%;
  white-space: nowrap;
}

.md-typeset table.echo-mode-table th:nth-child(2),
.md-typeset table.echo-mode-table td:nth-child(2) {
  min-width: 5rem;
  white-space: nowrap;
}

/* 产品授时引脚定义表（双行表头，见 Airy 表3） */
.md-typeset table.timing-pin-table {
  width: 100%;
  max-width: 100%;
  margin: 0 auto 1.25em;
  table-layout: fixed;
}

.md-typeset table.timing-pin-table th:first-child,
.md-typeset table.timing-pin-table tbody td:first-child {
  white-space: nowrap;
  width: 7rem;
}

.md-typeset table.timing-pin-table tbody td:nth-child(2),
.md-typeset table.timing-pin-table tbody td:nth-child(3) {
  text-align: left;
  line-height: 1.45;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.md-typeset .manual-table-scroll-wrap table.timing-pin-table {
  min-width: 100%;
  margin: 0;
}

/* 航插线接口规格表（见 Airy 表6） */
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table {
  width: max-content;
  min-width: 100%;
  table-layout: auto;
  font-size: 0.9em;
}

.md-typeset .manual-table-scroll-wrap table.aviation-cable-table th:nth-child(1),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table th:nth-child(2),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table th:nth-child(5),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table th:nth-child(6),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table th:nth-child(7),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table td:nth-child(1),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table td:nth-child(2),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table td:nth-child(5),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table td:nth-child(6),
.md-typeset .manual-table-scroll-wrap table.aviation-cable-table td:nth-child(7) {
  width: 1%;
  white-space: nowrap;
}

.md-typeset .manual-table-scroll-wrap table.aviation-cable-table td:nth-child(3) {
  white-space: nowrap;
}

/* 网络配置表：端口号列 rowspan，整行分隔线对齐 */
.md-typeset .manual-table-wrap table.manual-network-table {
  table-layout: fixed;
}

.md-typeset .manual-table-wrap table.manual-network-table col.net-col-device {
  width: 88px;
}

.md-typeset .manual-table-wrap table.manual-network-table col.net-col-ip {
  width: 128px;
}

.md-typeset .manual-table-wrap table.manual-network-table col.net-col-port {
  width: 96px;
}

.md-typeset .manual-table-wrap table.manual-network-table th,
.md-typeset .manual-table-wrap table.manual-network-table td {
  text-align: center;
  vertical-align: middle;
  border-bottom: none;
  border-right: 1px solid #bdbdbd;
  line-height: 1.35;
}

/* 末列去右边框；不用 :last-child，避免 rowspan 行里末格不是第 5 列 */
.md-typeset .manual-table-wrap table.manual-network-table thead th:nth-child(5),
.md-typeset .manual-table-wrap table.manual-network-table tbody td:nth-child(5) {
  border-right: none;
}

.md-typeset .manual-table-wrap table.manual-network-table--four-col thead th:nth-child(4),
.md-typeset .manual-table-wrap table.manual-network-table--four-col tbody td:nth-child(4) {
  border-right: none;
}

.md-typeset .manual-table-wrap table.manual-network-table thead th {
  border-bottom: 1px solid #9e9e9e;
  padding: 0.5rem 0.65rem;
}

.md-typeset .manual-table-wrap table.manual-network-table tbody td:first-child,
.md-typeset .manual-table-wrap table.manual-network-table tbody td:nth-child(2) {
  white-space: nowrap;
}

.md-typeset .manual-table-wrap table.manual-network-table td[rowspan] {
  padding: 0;
  position: relative;
}

.md-typeset .manual-table-wrap table.manual-network-table .network-port-value {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.md-typeset .manual-table-wrap table.manual-network-table tbody tr:not(:last-child) > td:not([rowspan]) {
  border-bottom: 1px solid #bdbdbd;
}

[data-md-color-scheme="slate"] .md-typeset .manual-table-wrap table.manual-network-table tbody tr:not(:last-child) > td:not([rowspan]) {
  border-bottom-color: #616161;
}

[data-md-color-scheme="slate"] .md-typeset .manual-table-wrap table.manual-network-table th,
[data-md-color-scheme="slate"] .md-typeset .manual-table-wrap table.manual-network-table td {
  border-right-color: #616161;
}