/* ===== 27. 电脑宽屏 · PC 骨架（≥1024px）=====
   背景（2026-10-26 第二轮，老板否决了第一版）：
   第一版只把内容区 480→720 加宽，老板看完原话「你现在这个打开是手机版的宽度，
   不是 PC 版本的」。判断正确 —— 卡片单列 + 底栏贴底，本质还是手机界面放大。

   本轮改成「换骨架，不换内容」：
     底栏 .bottombar 本来就是 5 个 <button>（不是 <a>），显隐由
     router.js:786 的 html.dual-bottombar-visible 控制。
     ⇒ 只把它用 CSS 转成左侧竖排菜单，**JS / DOM 一行不改**，
       点击、路由、角标、录音中键、长按菜单全部照旧。

   为什么不用 transform 做居中：弹层用 translateY 做动画，改 transform 会
   造成打不开/关不掉（致命）。本文件全程不碰 transform 的 translateY。

   铁律：所有规则必须在 @media (min-width:1024px) 内 —— 手机端 0 影响。
*/

@media (min-width: 1024px) {
  :root {
    --pc-rail: 196px;      /* 左侧菜单宽度 */
    --pc-content: 880px;   /* 内容区上限 */
  }

  /* 外围衬底 */
  body {
    max-width: none;
    background: #EDEAE4;
  }

  #app {
    max-width: var(--pc-content);
    margin: 0 auto;
    background: var(--bg);
    height: 100dvh;
  }

  /* 底部留白归零：底栏已经不贴底了，再留 56px 会在页面底部留一条空白 */
  .page {
    padding-bottom: 0 !important;
  }

  /* ---------- 底栏 → 左侧竖排菜单 ---------- */
  html.dual-bottombar-visible body {
    padding-left: var(--pc-rail);
  }

  html.dual-bottombar-visible .bottombar {
    left: 0;
    top: 0;
    right: auto;
    bottom: 0;
    width: var(--pc-rail);
    max-width: none;
    height: 100dvh;
    margin: 0;
    padding: 0;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    border-top: none;
    box-shadow: 1px 0 0 rgba(60, 50, 40, .06), 8px 0 24px -18px rgba(60, 50, 40, .22);
  }

  /* 品牌区：底栏前面没有 DOM 可放，用伪元素补一行字样 */
  html.dual-bottombar-visible .bottombar::before {
    content: "竹星 AI";
    display: block;
    flex: 0 0 auto;
    height: 64px;
    line-height: 64px;
    padding: 0 20px;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: .4px;
    color: #2563EB;
    border-bottom: 1px solid #F1EEE8;
    margin-bottom: 8px;
  }

  html.dual-bottombar-visible .bottombar__tab {
    flex: 0 0 auto;
    width: 100%;
    height: 48px;
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    gap: 12px;
    padding: 0 20px;
    border-radius: 0;
  }

  html.dual-bottombar-visible .bottombar__lbl {
    font-size: 13.5px;
    line-height: 1;
    text-align: left;
  }

  /* 选中态指示：底部横条 → 左侧竖条 */
  html.dual-bottombar-visible .bottombar__tab.is-on::before {
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    width: 3px;
    height: 20px;
    border-radius: 0 3px 3px 0;
  }

  /* 中键话筒：手机上凸起 26px 是为了在底栏上跳出来；竖排后不再凸，收成方块 */
  html.dual-bottombar-visible .bottombar__tab--mic {
    justify-content: flex-start;
    padding-top: 0;
  }

  html.dual-bottombar-visible .bottombar__tab--mic .bottombar__ico {
    width: 30px;
    height: 30px;
    margin-top: 0;
    border-radius: 9px;
    box-shadow: none;
  }

  html.dual-bottombar-visible .bottombar__tab--mic .bottombar__ico svg {
    width: 18px;
    height: 18px;
  }

  html.dual-bottombar-visible .bottombar__tab--mic .bottombar__lbl {
    margin-top: 0;
  }

  /* 未读角标：从"图标上方"挪到图标右上角 */
  html.dual-bottombar-visible .bottombar__dot {
    top: 6px;
    left: 38px;
    right: auto;
  }

  html.dual-bottombar-visible .bottombar__dot.is-plain {
    top: 8px;
    left: 40px;
    right: auto;
  }

  /* ---------- FAB：跟着内容区右边缘，不要贴屏幕 ---------- */
  /* 底栏与 FAB 互斥（router.js:797 setDualFabVisible）：
     底栏在 → 有左侧菜单，要让 196px；底栏不在 → 内容全宽居中。 */
  .fab-group {
    left: auto;
    right: max(18px, calc((100% - var(--pc-content)) / 2 + 4px));
  }

  html.dual-bottombar-visible .fab-group {
    right: max(18px, calc((100% - var(--pc-rail) - var(--pc-content)) / 2 + 4px));
  }
}

/* 1440 以上：内容区再放宽一档，否则两侧留白过厚 */
@media (min-width: 1440px) {
  :root {
    --pc-content: 960px;
  }
}
