/* ============================================================
   MaxStudy · 样式层 N4.3.0
   ------------------------------------------------------------
   设计原则
   1. 一个强调色。全站只有 --accent 一种色相（紫罗兰），出现在主按钮、
      导航选中、链接和少量关键数字上；页面之间不换色，换色只让人分心。
   2. 颜色留给数据。红/黄/蓝/绿/黑五个象限色只用来标任务属性，
      和语义色（成功/警告/危险）一起构成唯一的彩色信息层。
   3. 层级靠留白与细线。卡片是「面 + 1px 线」，不用投影堆叠；
      投影只留给浮层与导航（它们真的浮在内容上）。
   4. 所有颜色只从变量取。组件里不出现写死的 #fff 或浅色底，
      深浅两套主题才可能真正一致（对比度由 _test/contrast.js 守）。
   5. 导航在顶栏。桌面是胶囊 + 滑动高亮，手机是浮起的底栏胶囊；
      两端共用同一套滑块逻辑（WB.syncNavGliders），不写两套高亮。
   ============================================================ */


/* ------------------------------------------------------------
   二、五象限色（与 JS 的 WB.PALETTE 同值）
   只用在「任务属于哪一格」这一件事上：方块、圆点、柱状图、占比条。
   ------------------------------------------------------------ */
.q-red{--q-base:#d92d20;--q-soft:#fdecea;--q-line:#f6d1cd;--q-ink:#96221a}
.q-yellow{--q-base:#df9b00;--q-soft:#fdf3e6;--q-line:#f0dcc0;--q-ink:#7c3206}
.q-blue{--q-base:#175cd3;--q-soft:#eaf1fe;--q-line:#cadcf8;--q-ink:#12459c}
.q-green{--q-base:#067647;--q-soft:#e7f6ee;--q-line:#c3e6d4;--q-ink:#05583a}
.q-black{--q-base:#475467;--q-soft:#f2f4f7;--q-line:#dfe3e9;--q-ink:#333c4c}
html[data-theme="dark"] .nav-glider{border-color:rgba(167,139,250,.42)}
html[data-theme="dark"] .q-red{--q-soft:rgba(217,45,32,.16);--q-line:rgba(217,45,32,.36);--q-ink:#ffb3ad}
html[data-theme="dark"] .q-yellow{--q-base:#e0a53a;--q-soft:rgba(181,71,8,.18);--q-line:rgba(240,187,98,.34);--q-ink:#f5c98a}
html[data-theme="dark"] .q-blue{--q-soft:rgba(23,92,211,.18);--q-line:rgba(138,182,255,.32);--q-ink:#a8c8ff}
html[data-theme="dark"] .q-green{--q-soft:rgba(6,118,71,.2);--q-line:rgba(74,211,154,.3);--q-ink:#8ce8bd}
html[data-theme="dark"] .q-black{--q-soft:rgba(120,140,170,.16);--q-line:rgba(120,140,170,.32);--q-ink:#c6d0e0}

/* ------------------------------------------------------------
   三、基础
   ------------------------------------------------------------ */
*{box-sizing:border-box}
html,body{margin:0;padding:0}
html{-webkit-text-size-adjust:100%}
html{background:var(--bg)}
body{
  /* 底色交给 html，body 透明，两层光才能垫在内容下面而不糊住内容 */
  background:transparent;
  color:var(--ink);
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue","PingFang SC","Hiragino Sans GB","Microsoft YaHei",sans-serif;
  font-size:13.5px;line-height:1.65;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  -webkit-tap-highlight-color:transparent;
}
/* 环境雾与跟手光：两层负 z-index 的伪元素垫在内容下面。
   雾负责「这一页是什么颜色」，光负责「鼠标在哪」—— 卡片是半透明的，
   所以这两层会从玻璃里透出来，这是 Aero 质感的来源，不是为了好看加的装饰。 */
body::before{
  content:"";position:fixed;inset:0;z-index:-2;pointer-events:none;
  background:
    radial-gradient(920px 540px at 6% -14%,var(--aura),transparent 62%),
    radial-gradient(780px 440px at 100% -8%,var(--aura),transparent 58%);
}
/* 跟手光：115px 的小亮斑，只在指针贴着的那一小块提亮 —— 是「氛围」，不是「手电筒」 */
body::after{
  content:"";position:fixed;inset:0;z-index:-1;pointer-events:none;
  background:radial-gradient(115px circle at var(--mx,50%) var(--my,0%),var(--spot),transparent 66%);
  opacity:0;transition:opacity .5s ease;
}
body.pointer-on::after{opacity:1}
:root{--spot:rgba(255,255,255,.25)}
html[data-theme="dark"]{--spot:rgba(255,255,255,.03)}
.shell{position:relative}

img{max-width:100%;height:auto;display:block}
/* 图标与行的对齐：SVG 是 inline 元素时默认坐在基线上，会比文字低一截。
   统一成 block，交给 flex 居中；中文字形的视觉中心略低于行盒中心，
   所以再补 0.5px 的位移，肉眼才「严格齐平」。 */
svg{display:block}
.btn>svg,.nav button>svg,.mobar-nav button>svg,.card-title>svg,.pm-row>svg,
.set-row>svg,.td-done-btn>svg,.ov-head>svg,.ov-ico>svg,.gd-hrow>svg,
.gd-answer>svg,.gd-pc-txt>svg,.search-clear>svg,.icon-btn>svg,.ph-nav>svg,
.pf-name-row>svg,.badge>svg,.ai-tag>svg,.gd-pc-steps i>svg{
  position:relative;top:.5px;
}
button,input,select,textarea{font-family:inherit;font-size:13.5px;color:inherit}
button{cursor:pointer;background:none;border:0;padding:0}
a{color:var(--accent-ink);text-decoration:none}
a:hover{text-decoration:underline}
.num{font-variant-numeric:tabular-nums;font-feature-settings:"tnum"}
::selection{background:rgba(69,69,216,.18)}
:focus-visible{outline:2px solid var(--accent);outline-offset:2px;border-radius:7px}

*::-webkit-scrollbar{width:10px;height:10px}
*::-webkit-scrollbar-thumb{background:var(--line);border-radius:7px;border:3px solid transparent;background-clip:content-box}
*::-webkit-scrollbar-thumb:hover{background:var(--ink-4);background-clip:content-box}
*::-webkit-scrollbar-track{background:transparent}

/* ------------------------------------------------------------
   四、骨架
   ------------------------------------------------------------ */
.shell{min-height:100vh}

/* 顶栏：两层，都住在同一条悬浮胶囊里。
   完整层 = 品牌 / 胶囊导航 / 同步 + 主题 + 账号；
   极简层 = 图标 LOGO / 当前页图标 / 头像（游客→登录）。
   条子的宽高由 WB.bar 量出真实像素后写成内联样式，两层再交叉淡出，
   所以「收起」是一次真实的尺寸动画，而不是把内容藏起来。 */
.appbar{
  position:sticky;top:0;z-index:40;
  padding:10px 20px 14px;
  /* 半透明渐隐而不是一块实底：实底会把这层与页面环境光切成一条横向台阶 */
  background:linear-gradient(180deg,var(--bar) 0%,var(--bar) 46%,transparent 100%);
}
.appbar-in{
  position:relative;
  /* JS 会写成 px；没写之前先按内容撑开，避免首帧塌成 0 宽 */
  width:-moz-fit-content;width:fit-content;
  height:48px;margin:0 auto;
  border-radius:999px;
  /* 收起时完整层只是 opacity:0，还在布局里量得到 873px 的宽度 ——
     不裁掉它，页面会凭空多出一条横向滚动条（正文比视口宽 40 多像素）。 */
  overflow:hidden;
  background:var(--surface);
  background-image:none;
  border:1px solid var(--line);
  -webkit-backdrop-filter:none;
  backdrop-filter:none;
  box-shadow:var(--shadow-soft);
  /* 展开时立刻长回来（延迟 0）；收起时的延迟写在 .min 里 */
  transition:width .34s cubic-bezier(.22,.7,.3,1);
}
.bar-full{
  position:absolute;left:0;top:0;height:100%;
  display:flex;align-items:center;gap:8px 14px;
  padding:0 8px 0 12px;
  width:-moz-max-content;width:max-content;
  transition:opacity .18s ease .09s,transform .32s cubic-bezier(.22,.7,.3,1);
}
.bar-mini{
  position:absolute;left:50%;top:0;height:100%;
  display:flex;align-items:center;gap:4px;
  padding:0 5px 0 5px;
  width:-moz-max-content;width:max-content;
  opacity:0;pointer-events:none;
  transform:translate(-50%,-3px);
  transition:opacity .16s ease,transform .32s cubic-bezier(.22,.7,.3,1);
}
/* 收起：先让完整层淡掉，再收宽度（不然文字会从胶囊边缘溢出来走一段）。
   ⚠️ 高度保持不变：顶栏是 sticky 且在文档流里，高度一变下面的内容会跳 8px，
   那正好是用户最讨厌的「抖一下」。所以只动宽度。 */
.appbar-in.min{
  transition:width .3s cubic-bezier(.22,.7,.3,1) .1s;
}
.appbar-in.snap{transition:none}
.appbar-in.min .bar-full{opacity:0;pointer-events:none;transform:translateX(-8px);transition:opacity .12s ease,transform .3s}
.appbar-in.min .bar-mini{opacity:1;pointer-events:auto;transform:translate(-50%,0);transition:opacity .2s ease .14s,transform .32s cubic-bezier(.22,.7,.3,1) .1s}

.brand{display:flex;align-items:center;gap:10px;flex:none;min-width:0}
/* 品牌标记不跟页面换色：它是「这是哪个产品」，不是「这是哪一页」 */
.brand-badge{
  width:32px;height:32px;border-radius:10px;flex:none;
  /* LOGO B：深色小方块 + 紫蓝渐变环 + 白勾。方块是底板，标记本身是环与那一笔 */
  background:linear-gradient(150deg,#1b2540 0%,#080d17 100%);
  border:1px solid rgba(255,255,255,.11);
  box-shadow:none;
  display:flex;align-items:center;justify-content:center;
}
/* 极简层尺寸统一在下面「品牌标记：极简层与完整层同一款」那一段定义，
   这里不再重复写一遍 —— 两份同名规则只会让改尺寸的人改错地方。 */
.brand-txt{min-width:0}
.brand-txt b{display:block;font-size:13.5px;font-weight:var(--fw7);letter-spacing:.01em;color:var(--ink)}
.brand-txt span{display:block;font-size:11px;color:var(--ink-4);letter-spacing:.08em;margin-top:2px}

/* 极简层的页面图标行：收起状态下也能直接切页，当前页用一块浅色底标出来。
   图标等宽（26px），所以不需要滑块 —— 一排小方块里有一块被点亮就够了。 */
.mini-nav{display:flex;align-items:center;gap:1px;flex:none}
.mini-nav button{
  display:inline-flex;align-items:center;justify-content:center;
  width:27px;height:27px;border-radius:7px;
  color:var(--ink-3);background:transparent;
  transition:color var(--dur),background var(--dur);
}
.mini-nav button svg{width:14px;height:14px}
.mini-nav button:hover{color:var(--ink);background:var(--accent-soft)}
.mini-nav button.on{color:var(--accent-ink);background:var(--accent-soft);border:1px solid var(--accent-line)}
.mini-sep{width:1px;height:16px;margin:0 1px;background:var(--line);flex:none}
.mini-user,.mini-login{
  display:inline-flex;align-items:center;justify-content:center;flex:none;
  height:28px;border-radius:999px;
}
.mini-user{width:28px;padding:0;border:1px solid var(--line);background:var(--surface)}
.mini-user .av.av-sm{width:23px;height:23px;font-size:11px;border:0}
.mini-login{padding:0 11px;font-size:12px;font-weight:var(--fw6);color:var(--accent-ink);
  background:var(--accent-soft);border:1px solid var(--accent-line)}

/* 胶囊导航：选中项用一块滑动的圆角高亮（glider），位移由 JS 量出来。
   导航住在悬浮条里，所以自己不再画一层胶囊（两层胶囊会显得很闷），
   只保留滑块——滑块移动本身就是位置反馈。 */
.nav{
  position:relative;display:inline-flex;align-items:center;gap:2px;flex:none;
  padding:4px;border-radius:999px;
  background:transparent;border:1px solid transparent;
}
.nav-glider{
  position:absolute;top:4px;left:0;width:0;height:calc(100% - 8px);
  border-radius:999px;background:var(--accent-glide);
  border:1px solid #c9bdf7;
  box-shadow:none;
  opacity:0;pointer-events:none;
  transition:transform .3s cubic-bezier(.23,1,.32,1),width .3s cubic-bezier(.23,1,.32,1),opacity .2s;
}
.nav-glider.snap{transition:none}
.nav button{
  position:relative;z-index:1;
  display:inline-flex;align-items:center;gap:7px;
  height:34px;padding:0 13px;border-radius:999px;
  color:var(--ink-3);font-size:13.5px;font-weight:var(--fw6);white-space:nowrap;
  transition:color var(--dur);
}
.nav button svg{width:15px;height:15px;flex:none;opacity:.85;transition:opacity var(--dur),color var(--dur)}
.nav button:hover{color:var(--ink)}
.nav button:hover svg{opacity:1}
.nav button.active{color:var(--accent-ink);font-weight:var(--fw7)}
.nav button.active svg{opacity:1;color:var(--accent-ink)}

.appbar-actions{margin-left:auto;display:flex;align-items:center;gap:8px;flex:none}

/* 账号：顶栏唯一入口（侧栏已取消）。窄屏只留头像 */
.user-chip{
  display:flex;align-items:center;gap:8px;flex:none;
  height:36px;padding:0 10px 0 3px;border-radius:999px;
  background:var(--surface);border:1px solid var(--line);
  transition:background var(--dur),border-color var(--dur);
}
.user-chip:hover,.user-chip.active{background:var(--surface-2);border-color:var(--accent-line)}
.user-chip .su-txt{min-width:0;text-align:left;display:block}
.user-chip .su-txt b{display:block;font-size:12px;font-weight:var(--fw65);color:var(--ink);line-height:1.35;max-width:96px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.user-chip .su-txt span{display:block;font-size:11px;color:var(--ink-4);line-height:1.35;max-width:96px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

.main{width:100%;max-width:1160px;margin:0 auto;padding:0 32px 64px}

/* ------------------------------------------------------------
   五、顶栏（贴在内容上方，滚动时保留上下文）
   ------------------------------------------------------------ */
/* ------------------------------------------------------------
   五、页头（标题 + 本页动作）
   ------------------------------------------------------------ */
.page-head{
  position:relative;
  display:flex;align-items:flex-end;gap:12px;flex-wrap:wrap;
  padding:22px 0 14px;
}
.ph-txt{flex:1;min-width:0}
.page-head h1{font-size:21px;line-height:1.25;margin:0;font-weight:var(--fw7);letter-spacing:-.5px;color:var(--ink)}
.page-head p{margin:3px 0 0;font-size:13.5px;color:var(--ink-4);line-height:1.5}
/* 页头不再挂「这页是干什么的」一句解释，空着的时候不能留一条空白 */
.page-head p:empty{display:none}
.page-actions{display:none;align-items:center;gap:8px;flex:none}
body[data-page="today"] .page-actions{display:flex}

/* 页头「更多」：把长期规划 / 同步 / 账号这些次要入口折进一张小卡片 */
.page-menu{
  position:absolute;right:0;top:calc(100% - 4px);z-index:50;
  min-width:216px;padding:6px;
  background:var(--surface);border:1px solid var(--line);
  border-radius:10px;box-shadow:var(--shadow-pop);
}
.pm-row{
  display:flex;align-items:center;gap:9px;width:100%;
  padding:9px 10px;border-radius:7px;text-align:left;
  background:transparent;border:0;
  font:inherit;font-size:13.5px;font-weight:var(--fw6);color:var(--ink-2);
}
.pm-row:hover{background:var(--surface-2);color:var(--ink)}
.pm-row svg{flex:none;color:var(--ico)}
.pm-row span{flex:none}
.pm-row em{
  flex:1;text-align:right;font-style:normal;font-size:11px;font-weight:var(--fw5);
  color:var(--ink-4);white-space:nowrap;
}

/* 主题：顶栏只放一个方块（登录页仍是那个双态长条开关）。
   方块里太阳与月亮叠着，切换时一个转出去、一个转进来 —— 比换图标更像「天亮了」。
   跟随系统时这个按钮整块收起：顶栏能点的东西越少，越不容易误触；
   三档选择在「我的 → 外观」，那里有文字说明，不用在顶栏猜。 */
.theme-btn{
  position:relative;flex:none;
  width:34px;height:34px;border-radius:7px;padding:0;
  background:var(--surface-2);border:1px solid var(--line);
  transition:width .3s cubic-bezier(.22,.7,.3,1),border-width .3s,
             opacity .2s ease,transform .3s cubic-bezier(.22,.7,.3,1),
             background var(--dur),border-color var(--dur);
}
.theme-btn:hover{background:var(--surface-3);border-color:var(--accent-line)}
.theme-btn{touch-action:pan-y}
.tb-face{position:absolute;inset:0;display:flex;align-items:center;justify-content:center}
/* 图标由 JS 按「当前主题」整颗替换（七档各一个）。因此不需要原来那套
   「太阳淡出、月亮转进来」的双图交叉，只留一次进场动画。
   首屏 JS 还没跑时 HTML 里是两个占位图标，把第二个藏掉，别叠在一起。 */
.tb-face svg{position:absolute;animation:tbIcoIn .26s cubic-bezier(.34,1.28,.6,1)}
.tb-face svg + svg{display:none}
@keyframes tbIcoIn{
  from{opacity:0;transform:scale(.7) rotate(-18deg)}
  to{opacity:1;transform:none}
}
html[data-theme="dark"] .theme-btn{background:#141d2c;border-color:#2a3547}
/* 每档一个标志色：暖色档偏橙、冷色档偏青、星空靛、银河紫 */
.theme-btn[data-theme-icon="auto"] .tb-face{color:var(--ink-2)}
.theme-btn[data-theme-icon="light"] .tb-face{color:#d98324}
.theme-btn[data-theme-icon="dark"] .tb-face{color:#67e8f9}
.theme-btn[data-theme-icon="starry"] .tb-face{color:#a5b4fc}
.theme-btn[data-theme-icon="sky"] .tb-face{color:#0ea5e9}
.theme-btn[data-theme-icon="cartoony"] .tb-face{color:#f59e0b}
.theme-btn[data-theme-icon="galaxy"] .tb-face{color:#c084fc}
/* 主题按钮在所有档位下都常显：它除了「换深浅」还要承担「向右拖出七档」，
   跟随系统时收起来就等于把七档入口藏了。 */

/* 登录页与顶栏现在是同一颗方块按钮（.theme-btn），轨道开关已撤掉。 */

/* 悬浮说明：只在有指针的设备上出现，触屏不打扰 */
[data-tip]{position:relative}
@media (hover:hover){
  [data-tip]:hover::after{
    content:attr(data-tip);
    position:absolute;left:50%;top:calc(100% + 10px);
    transform:translateX(-50%) translateY(-3px);
    background:linear-gradient(150deg,rgba(23,26,36,.98),rgba(31,41,55,.98));
    color:#e9edf5;border:1px solid rgba(255,255,255,.1);
    border-radius:7px;padding:6px 10px;
    font-size:12px;font-weight:var(--fw5);line-height:1.4;white-space:nowrap;
    box-shadow:0 16px 34px -14px rgba(76,60,220,.55);
    opacity:0;pointer-events:none;z-index:60;
    animation:tipIn .16s ease .18s forwards;
  }
  [data-tip]:hover::before{
    content:"";position:absolute;left:50%;top:calc(100% + 5px);
    transform:translateX(-50%);
    border:5px solid transparent;border-bottom-color:rgba(23,26,36,.98);
    opacity:0;pointer-events:none;z-index:60;
    animation:tipIn .16s ease .18s forwards;
  }
}
@keyframes tipIn{to{opacity:1;transform:translateX(-50%) translateY(0)}}

/* 同步状态：一个点 + 两个字，不抢注意力 */
/* 药丸外面这层只负责挂说明：药丸自己的 ::before 是那个圆点，
   data-tip 写上去的话，悬停时箭头会顶掉圆点（看着像圆点跳到第二行） */
.sync-wrap{display:inline-flex;align-items:center;flex:none}
.sync-pill{
  display:inline-flex;align-items:center;gap:6px;
  font-size:12px;font-weight:var(--fw6);padding:0 9px;height:24px;border-radius:999px;
  background:var(--surface-2);color:var(--ink-3);border:1px solid var(--line-2);
}
.sync-pill::before{content:"";width:5px;height:5px;border-radius:50%;background:currentColor;flex:none}
.sync-ok{background:var(--green-bg);color:var(--green);border-color:var(--green-line)}
.sync-busy{background:var(--sky-bg);color:var(--sky);border-color:var(--sky-line)}
.sync-err{background:var(--red-bg);color:var(--red);border-color:var(--red-line)}
.sync-off{background:var(--amber-bg);color:var(--amber);border-color:var(--amber-line)}
.sync-busy::before{animation:pulse 1.4s ease-in-out infinite}
@keyframes pulse{0%,100%{opacity:1}50%{opacity:.3}}

/* 切页：只做「淡入」，不碰位移与模糊。
   opacity 不参与排版计算，所以慢一点点也不会让内容抖；
   180–220ms 是「不生硬」和「不拖手」之间的那段。 */
.panel{display:none}
.panel.active{display:block;animation:pageIn .22s cubic-bezier(.26,.62,.32,1) both}
@keyframes pageIn{from{opacity:0}to{opacity:1}}
/* 页头（标题 + 副标题）跟着一起淡入，否则面板在淡、标题在硬切，看着像两个不同步的部件 */
.page-head.fade-in{animation:pageIn .24s cubic-bezier(.26,.62,.32,1) both}
@media (prefers-reduced-motion: reduce){
  .panel.active,.page-head.fade-in{animation:none}
}

/* ------------------------------------------------------------
   六、通用组件
   ------------------------------------------------------------ */
/* Aero 玻璃：最上层是极淡的主题色雾（一页一个色相，靠这层「染」出来而不是描边），
   下面是半透明的玻璃面 + 背景模糊。拆成 color / image 两行，浮层才好单独把雾去掉。 */
.card,.quiet-card,.collapse-card,.wk-card,.gd-pc,.set-list,.gate-card,.modal{
  /* 不要在这里再铺一层 background-color: 半透明白重复叠两三次，alpha 会从 .52
     一路乘到 .77，背后那层主题色雾就被糊死了 —— 换任何皮肤都只是一块白板。
     玻璃的厚度只由下面这一条渐变决定。 */
  background-color:transparent;
  /* 卡片里不再铺「页面色雾」：那层雾是给 body::before 的（一页一个色相），
     铺到玻璃上就等于在玻璃前面又糊了一张色纸 —— 皮肤再怎么换也透不出来。
     玻璃只负责「半透明 + 模糊 + 高光」，颜色交给它背后的页面。 */
  background-image:linear-gradient(168deg,var(--glass-a) 0%,var(--glass-b) 100%);
  border:1px solid var(--glass-line);
  -webkit-backdrop-filter:blur(26px) saturate(185%);
  backdrop-filter:blur(26px) saturate(185%);
  box-shadow:var(--glass-shadow);
}
.gate-card,.modal{box-shadow:var(--glass-shadow),var(--shadow-modal)}
.card,.quiet-card,.collapse-card,.wk-card,.gd-pc,.gate-card,.modal{position:relative}
/* 顶部 1px 高光：玻璃的边缘会把上面的光收成一条细线，少了它就只是一块半透明色块 */
.card::after,.quiet-card::after,.collapse-card::after,
.wk-card::after,.gd-pc::after,.gate-card::after,.modal::after{
  content:"";position:absolute;left:12px;right:12px;top:0;height:1px;
  background:linear-gradient(90deg,transparent,var(--glass-hi),transparent);
  pointer-events:none;border-radius:inherit;
}

.card{
  border-radius:var(--r);
  padding:16px 18px;margin-bottom:14px;
}
.card-title{
  display:flex;align-items:center;gap:8px;min-width:0;
  font-weight:var(--fw65);font-size:13.5px;line-height:1.4;
  margin:0 0 12px;color:var(--ink);
}
.card-title svg{flex:none;width:15px;height:15px;color:var(--ico)}
/* 说明文字吃掉剩余宽度并在超长时省略，右边那颗按钮永远不挤出卡片
   （以前 spacer 是 flex:0 1 auto 且没有 min-width:0，窄栏下按钮会被顶到卡片外） */
.card-title .spacer{
  margin-left:auto;flex:1 1 auto;min-width:0;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
  font-weight:var(--fw4);font-size:12px;color:var(--ink-4);text-align:right;
}
.card-title>.btn,.card-title>.mini-btn{flex:none}
/* V4.4.3 起标题后面那行解释撤了（进教程），原来靠 .spacer 的 flex:1 把按钮顶到右边。
   没有解释时按钮自己吃下 auto 外边距，位置不变。有 spacer 时剩余宽度已被 spacer 吃掉，
   这行不会多出间隙。 */
.card-title>.btn:last-child{margin-left:auto}

/* 更轻的卡：空态、说明、次级信息 */
.quiet-card{
  border-radius:var(--r);
  padding:14px 16px;margin-bottom:12px;
  background:var(--inset);
  border-color:var(--inset-line);
  box-shadow:var(--inset-shadow);
  -webkit-backdrop-filter:none;
  backdrop-filter:none;
}
.quiet-card .card-title{font-size:13.5px;margin-bottom:10px}

/* 需要被看见但不该是主色的块（复习提醒 / 判卷结果） */
.focus-card{
  background:var(--surface);border:1px solid var(--accent-line);
  -webkit-backdrop-filter:none;backdrop-filter:none;
  box-shadow:none;
  border-radius:var(--r);padding:14px 16px;margin-bottom:12px;
}
.focus-card .card-title{color:var(--accent-ink)}
.focus-card .card-title svg{color:var(--accent-ink)}
.focus-card.focus-mini{padding:12px 14px}

.collapse-card{
  border-radius:var(--r);
  padding:4px 18px;margin-bottom:14px;
}
.collapse-head{
  width:100%;display:flex;align-items:center;justify-content:space-between;gap:10px;
  background:transparent;font:inherit;font-weight:var(--fw6);font-size:13.5px;
  color:var(--ink-2);min-height:44px;padding:0;text-align:left;
}
.collapse-head:hover{color:var(--ink)}
.collapse-head .chev{font-size:12px;color:var(--ink-4);font-weight:var(--fw6);flex:none}
.collapse-body{padding:2px 0 14px;display:flex;flex-direction:column;gap:12px}
.collapse-body>div{background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);padding:14px 16px}

/* 按钮 */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:6px;
  border:1px solid transparent;border-radius:var(--r-sm);
  padding:0 14px;height:36px;font-size:13.5px;font-weight:var(--fw6);
  background:var(--surface-2);color:var(--ink-2);
  white-space:nowrap;
  transition:background var(--dur),border-color var(--dur),color var(--dur),transform .08s,filter var(--dur);
}
.btn:active{transform:translateY(1px)}
.btn[disabled]{opacity:.45;cursor:not-allowed;transform:none}
.btn svg{flex:none;width:14px;height:14px}
.btn-brand{
  background:var(--accent);color:var(--on-accent);
  border-color:transparent;
  box-shadow:none;
}
html[data-theme="dark"] .btn-brand{color:#0f1420;box-shadow:none}
.btn-brand:hover{
  filter:brightness(1.05);transform:translateY(-1px);
  box-shadow:0 0 0 3px var(--accent-wash);
}
.btn-brand:active{transform:none;box-shadow:none}
.btn-red{background:var(--red);color:var(--on-accent);box-shadow:none}
.btn-red:hover{filter:brightness(1.08)}
.btn-ghost{background:var(--surface);border-color:var(--line);color:var(--ink-2)}
.btn-ghost:hover{background:var(--surface-2);border-color:var(--accent-line);color:var(--ink)}
.btn-sm{height:30px;padding:0 10px;font-size:12px;border-radius:7px;gap:5px}
.btn-sm svg{width:13px;height:13px}
.btn-block{width:100%}
.btn-on{background:var(--accent-soft);color:var(--accent-ink);border-color:var(--accent-line)}
/* 表单里的辅助动作（AI 认题）：浅主题底，一眼看出不是「保存」 */
.nb-photo-btn{background:var(--accent-soft);color:var(--accent-ink);border-color:var(--accent-line);font-weight:var(--fw6)}
.nb-photo-btn:hover{background:var(--accent-line);color:var(--accent-ink)}
.btn-on:hover{filter:none;border-color:var(--accent)}

/* 主操作按钮里的勾：hover 时把它重新「画」一遍，点下去更有回应感。
   只描边不下沉，避免像加载中的抖动。 */
.btn-draw svg path{stroke-dasharray:26}
.btn-draw:hover svg{animation:popIcon .5s cubic-bezier(.34,1.4,.64,1)}
.btn-draw:hover svg path{animation:drawCheck .6s cubic-bezier(.5,0,.25,1) both}
@keyframes drawCheck{0%{stroke-dashoffset:26}60%{stroke-dashoffset:0}100%{stroke-dashoffset:0}}
@keyframes popIcon{0%{transform:scale(1)}40%{transform:scale(1.22)}100%{transform:scale(1)}}

.icon-btn{
  background:transparent;border-radius:7px;padding:0;
  width:30px;height:30px;color:var(--ink-4);
  display:inline-flex;align-items:center;justify-content:center;flex:none;
  transition:background var(--dur),color var(--dur);
}
.icon-btn:hover{background:var(--surface-2);color:var(--ink-2)}
.icon-btn.danger:hover{background:var(--red-bg);color:var(--red)}
.icon-btn.confirming{background:var(--red-fill);color:var(--on-accent);width:auto;padding:0 9px;font-size:12px;font-weight:var(--fw7)}

/* 徽章 */
.badge{
  display:inline-flex;align-items:center;gap:4px;
  font-size:11px;font-weight:var(--fw65);line-height:1.6;
  padding:1px 7px;border-radius:999px;white-space:nowrap;
}
.badge-done{background:var(--green-bg);color:var(--green)}
.badge-idle{background:var(--surface-3);color:var(--ink-3)}
.badge-temp{background:var(--amber-bg);color:var(--amber)}
.badge-overdue{background:var(--red-bg);color:var(--red)}

/* 表单 */
.form-row{display:flex;flex-direction:column;gap:6px;margin-bottom:14px}
.form-2col{display:grid;grid-template-columns:1fr 1fr;grid-gap:10px;gap:10px}
.field{display:flex;flex-direction:column;gap:6px;min-width:0;margin-bottom:14px}
.field label,.form-row label{font-size:12px;color:var(--ink-3);font-weight:var(--fw6)}
.field .hint,.form-row .hint{font-weight:var(--fw4);color:var(--ink-4)}
input[type=text],input[type=number],input[type=date],input[type=email],
input[type=password],input[type=tel],input[type=time],select,textarea,.input{
  width:100%;border:1px solid var(--field-line);background:var(--surface);
  border-radius:var(--r-sm);padding:0 11px;height:36px;
  outline:none;color:var(--ink);
  transition:border-color var(--dur),background var(--dur);
}
textarea{height:auto;min-height:72px;padding:8px 11px;resize:vertical;line-height:1.65}
input::placeholder,textarea::placeholder{color:var(--ink-4)}
input:hover,select:hover,textarea:hover{border-color:var(--accent-line)}
input:focus,select:focus,textarea:focus{border-color:var(--accent);background:var(--surface)}
select{
  appearance:none;-webkit-appearance:none;
  background-image:linear-gradient(45deg,transparent 50%,var(--ink-3) 50%),linear-gradient(135deg,var(--ink-3) 50%,transparent 50%);
  background-position:calc(100% - 16px) 50%,calc(100% - 11px) 50%;
  background-size:5px 5px,5px 5px;background-repeat:no-repeat;
  padding-right:30px;
}
input[type=date],input[type=time]{padding-right:8px}

.seg{
  display:flex;gap:2px;background:var(--surface-2);border-radius:var(--r-sm);
  padding:3px;margin-bottom:16px;border:1px solid var(--line-2);
}
.seg button{
  flex:1;border:0;background:transparent;border-radius:7px;
  padding:0 6px;height:30px;font-size:13.5px;font-weight:var(--fw6);color:var(--ink-3);
  transition:background var(--dur),color var(--dur);
}
.seg button:hover{color:var(--ink-2)}
.seg button.on{background:var(--raise);color:var(--ink);box-shadow:0 1px 3px rgba(16,20,30,.14)}
.seg-mini{
  display:inline-flex;gap:2px;background:var(--surface-2);
  border-radius:7px;padding:2px;border:1px solid var(--line-2);
  margin:0;flex:none;
}
.seg-mini button{
  border:0;background:transparent;border-radius:7px;
  padding:0 9px;height:26px;font-size:12px;font-weight:var(--fw6);color:var(--ink-3);
  transition:background var(--dur),color var(--dur);
}
.seg-mini button:hover{color:var(--ink-2)}
.seg-mini button.on{background:var(--raise);color:var(--ink);box-shadow:0 1px 3px rgba(16,20,30,.14)}
.seg-mini button.on.ok{background:var(--green-fill);color:var(--on-accent)}
.seg-mini button.on.bad{background:var(--red-fill);color:var(--on-accent)}

.tiny{font-size:12px;color:var(--ink-4);line-height:1.6}
.tiny.attn{color:var(--amber)}
.muted{color:var(--ink-2);font-size:13.5px}
.empty{
  color:var(--ink-3);font-size:13.5px;text-align:center;
  padding:22px 14px;line-height:1.8;
}
.skeleton{
  background:var(--surface-3);
  border-radius:7px;height:13px;margin-bottom:8px;
  animation:sk 1.2s ease-in-out infinite;
}
@keyframes sk{0%,100%{opacity:.55}50%{opacity:1}}

.banner{
  display:none;align-items:flex-start;gap:9px;
  border-radius:var(--r-sm);padding:10px 13px;font-size:13.5px;margin-bottom:14px;
  background:var(--red-bg);border:1px solid var(--red-line);color:var(--red);line-height:1.6;
}
.banner.show{display:flex}
.banner .btn{margin-left:auto;flex:none}

/* ------------------------------------------------------------
   七、本周计划 · 总体
   ------------------------------------------------------------ */
.plan-hero{padding:16px 18px}
.ph-top{display:flex;align-items:center;gap:10px}
.ph-nav{
  width:28px;height:28px;flex:none;border-radius:7px;
  border:1px solid var(--line);background:var(--surface);color:var(--ink-3);
  font-size:15px;line-height:1;
  transition:background var(--dur),color var(--dur);
}
.ph-nav:hover{background:var(--surface-2);color:var(--ink)}
.ph-nav:disabled{opacity:.35;cursor:default}
.ph-nav:disabled:hover{background:var(--surface);color:var(--ink-3)}
/* 周报翻周：和计划页用同一种翻页钮；「回到本周」是一条低调的文字链 */
.wk-back{font-size:12px;color:var(--accent-ink);padding:0 2px}
.ph-week{flex:1;min-width:0;text-align:center}
.ph-week b{display:block;font-size:15px;font-weight:var(--fw65);color:var(--ink);font-variant-numeric:tabular-nums}
.ph-week span{display:block;font-size:12px;color:var(--ink-4);margin-top:1px}
.ph-chip{
  font-size:11px;font-weight:var(--fw65);padding:2px 9px;border-radius:999px;flex:none;
  background:var(--surface-2);color:var(--ink-3);border:1px solid var(--line);
}
.ph-chip.pending{background:var(--amber-bg);color:var(--amber);border-color:var(--amber-line)}
.ph-chip.late{background:var(--red-bg);color:var(--red);border-color:var(--red-line)}
.ph-chip.ok{background:var(--green-bg);color:var(--green);border-color:var(--green-line)}

.ph-stats{
  display:grid;grid-template-columns:repeat(5,1fr);
  margin-top:14px;padding-top:14px;border-top:1px solid var(--line-2);
}
.ph-stat{text-align:center;min-width:0;padding:0 4px}
.ph-stat+.ph-stat{border-left:1px solid var(--line-2)}
.ph-stat b{display:block;font-size:21px;font-weight:var(--fw65);line-height:1.2;color:var(--ink);letter-spacing:-.4px}
.ph-stat span{display:block;font-size:11px;color:var(--ink-4);margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

/* ------------------------------------------------------------
   八、本周计划 · 长期规划
   ------------------------------------------------------------ */
.stage-row{
  display:grid;grid-template-columns:24px minmax(0,1.5fr) minmax(0,1fr) auto;
  align-items:center;grid-gap:12px;gap:12px;
  background:var(--inset);border:1px solid var(--inset-line);box-shadow:var(--inset-shadow);border-radius:var(--r-sm);
  padding:10px 12px;margin-top:8px;
}
.sr-idx{
  width:22px;height:22px;border-radius:7px;flex:none;
  background:var(--q-soft);color:var(--q-ink);
  border:1px solid var(--q-line);
  font-size:11px;font-weight:var(--fw7);line-height:20px;text-align:center;
}
.sr-main{min-width:0}
.sr-main b{display:block;font-size:13.5px;font-weight:var(--fw65);color:var(--ink);margin-bottom:1px}
.sr-goal{display:block;font-size:12px;color:var(--ink-3);line-height:1.5;overflow:hidden;text-overflow:ellipsis}
.sr-now{display:block;font-size:11px;color:var(--ink-4);margin-top:2px}
.sr-prog{min-width:0;display:flex;align-items:center;gap:8px}
.sr-bar{flex:1;height:4px;border-radius:7px;background:var(--track);overflow:hidden;min-width:40px}
.sr-bar i{display:block;height:100%;border-radius:7px;background:linear-gradient(90deg,var(--q-base),var(--q-ink));opacity:.9}
.sr-prog span{flex:none;font-size:11px;color:var(--ink-4);white-space:nowrap}
.sr-acts{display:flex;gap:6px;flex:none}
.sr-acts .btn{height:28px;font-size:12px;padding:0 9px}

/* 一个长期规划 = 一个分组，阶段行与子目标都缩进在组内 */
.long-group{margin-top:12px}
.long-group:first-of-type{margin-top:10px}
.lg-head{
  display:grid;grid-template-columns:minmax(0,1.5fr) minmax(0,1fr) auto;
  align-items:center;grid-gap:12px;gap:12px;
  padding:0 2px 8px;
}
.lg-main{min-width:0}
.lg-main b{display:block;font-size:13.5px;font-weight:var(--fw65);color:var(--ink)}
.lg-empty{
  font-size:12px;color:var(--ink-4);background:var(--surface-2);
  border:1px dashed var(--line);border-radius:var(--r-sm);padding:9px 12px;
}
.stage-row.is-done .sr-main b{color:var(--ink-3);text-decoration:line-through;text-decoration-thickness:1px}

/* 阶段子目标：只勾选与删除，不进计划表 */
.sub-list{margin:6px 0 0 34px;display:flex;flex-direction:column;gap:4px}
/* 规划级子目标（不挂具体阶段）：靠左一档，和阶段内的清单区分开 */
.sub-list-lg{margin-left:0}
.sub-row{
  display:flex;align-items:center;gap:8px;
  background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-xs);
  padding:5px 8px;font-size:12px;color:var(--ink-2);
}
/* 子目标 = 挂在阶段下的固定目标：一行里是「名 + 频率」，完成情况看计划表，
   所以这里没有勾选框（以前那个勾只代表「标记达成」，和排期是两套口径）。 */
.sub-dot{width:6px;height:6px;flex:none;border-radius:50%;background:var(--line)}
.sub-name{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sub-freq{flex:none;font-size:11px;color:var(--ink-4);font-variant-numeric:tabular-nums}
.sub-row .mini-btn{margin-top:0;opacity:.4}
.sub-row:hover .mini-btn{opacity:1}

/* 小图标按钮进入「确认删?」时要长出宽度，否则文字溢出 */
.mini-btn.confirming{
  width:auto;padding:0 6px;opacity:1;
  background:var(--red-bg);color:var(--red);font-size:11px;font-weight:var(--fw65);
}

/* 只在打印里出现 */
.print-only{display:none}

/* ------------------------------------------------------------
   九、本周计划 · 计划表
   ------------------------------------------------------------ */
.pb-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:14px}
.pb-title{display:flex;align-items:center;gap:8px;min-width:0}
.pb-title h2{font-size:15px;font-weight:var(--fw65);margin:0;color:var(--ink)}
.pb-mode{
  font-size:11px;font-weight:var(--fw65);padding:1px 8px;border-radius:999px;
  background:var(--surface-2);color:var(--ink-3);border:1px solid var(--line);flex:none;
}
.pb-mode.edit{background:var(--accent-soft);color:var(--accent-ink);border-color:var(--accent-line)}
.pb-mode.check{background:var(--green-bg);color:var(--green);border-color:var(--green-line)}
.pb-hint{flex:1;min-width:0;font-size:12px;color:var(--ink-4)}
.pb-actions{display:flex;gap:6px;flex:none;flex-wrap:wrap}

/* 待办池 */
.pool{display:flex;flex-direction:column;gap:8px;margin-bottom:14px}
.pool-sec{background:var(--inset);border:1px solid var(--inset-line);box-shadow:var(--inset-shadow);border-radius:var(--r-sm);padding:9px 11px 8px}
.pool-head{display:flex;align-items:center;gap:8px;margin-bottom:7px}
.pool-title{font-size:12px;font-weight:var(--fw65);color:var(--ink-2)}
.pool-add{
  width:22px;height:22px;flex:none;border-radius:7px;border:1px dashed var(--line);
  margin-left:auto;                 /* 池子标题旁的解释撤了，加号自己贴右边 */
  background:var(--surface);color:var(--ink-3);font-size:13.5px;line-height:1;
}
.pool-add:hover{border-color:var(--accent);color:var(--accent-ink);background:var(--accent-soft)}
.pool-row{display:flex;align-items:flex-start;gap:6px;overflow-x:auto;padding-bottom:2px}
.pool-empty{font-size:12px;color:var(--ink-4);padding:4px 2px}
.pool-done{
  flex:none;width:132px;border-radius:var(--r-sm);border:1px dashed var(--line);
  background:var(--surface);padding:7px 9px;display:flex;flex-direction:column;gap:1px;
}
.pool-done span{font-size:12px;font-weight:var(--fw6);color:var(--ink-3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pool-done small{font-size:11px;color:var(--green)}

/* 方块 */
.pblock{
  flex:none;width:132px;position:relative;cursor:grab;user-select:none;
  border-radius:var(--r-sm);border:1px solid var(--q-line);background:var(--q-soft);
  padding:6px 8px 6px 10px;
  transition:border-color var(--dur),transform .1s,box-shadow var(--dur),opacity var(--dur);
}
.pblock::before{
  content:"";position:absolute;left:0;top:0;bottom:0;width:2px;
  border-radius:var(--r-sm) 0 0 var(--r-sm);background:var(--q-base);
}
.pblock::after{   /* 顶部 1px 高光：让色块有一点厚度，不再像贴纸 */
  content:"";position:absolute;left:6px;right:6px;top:0;height:1px;
  border-radius:0 0 2px 2px;background:rgba(255,255,255,.35);
}
html[data-theme="dark"] .pblock::after{background:rgba(255,255,255,.14)}
.pblock:hover{border-color:var(--q-base);transform:translateY(-1px);
  box-shadow:0 3px 10px -6px rgba(16,20,30,.35)}
.pblock.dragging{opacity:.4;cursor:grabbing;transform:none;box-shadow:none}
.pblock.selected{outline:2px solid var(--accent);outline-offset:1px}
.pblock-name{
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;
  font-size:12px;font-weight:var(--fw6);color:var(--q-ink);line-height:1.4;word-break:break-word;
}
.pblock-meta{display:flex;align-items:center;gap:4px;margin-top:2px;font-size:11px;color:var(--q-ink);opacity:.75;white-space:nowrap;overflow:hidden}
.pblock-meta .dot-sep{opacity:.45}
/* 方块右上角的工具条：修改 + 删除。
   以前只有删除一颗，现在多了修改，两颗挤在一起会盖住名字第一行，
   所以收进一个 flex 容器，悬停才整体淡入。 */
.pblock-tools{
  position:absolute;top:3px;right:3px;z-index:4;
  display:flex;align-items:center;gap:2px;
  opacity:0;transition:opacity var(--dur);
}
.pblock:hover .pblock-tools{opacity:1}
/* 触屏没有悬停：藏起来就等于「改不了」。这类设备上直接把工具条显出来。 */
@media (hover:none){
  .pblock-tools{opacity:.85}
}
.pblock-edit,.pblock-del{
  width:15px;height:15px;flex:none;border-radius:7px;border:0;padding:0;
  background:transparent;color:var(--q-ink);opacity:.55;font-size:11px;line-height:1;
  display:inline-flex;align-items:center;justify-content:center;
}
.pblock-edit svg{width:9px;height:9px}
.pblock-edit:hover,.pblock-del:hover{opacity:1;background:var(--q-base);color:var(--on-accent)}
.pblock.done{--q-base:#067647;--q-soft:#e7f6ee;--q-line:#c3e6d4;--q-ink:#05583a}
html[data-theme="dark"] .pblock.done{--q-soft:rgba(6,118,71,.18);--q-line:rgba(74,211,154,.3);--q-ink:#8ce8bd}
.pblock.done .pblock-name{text-decoration:line-through;text-decoration-thickness:1px;opacity:.8}
.pblock.is-temp{border-style:dashed}
.pblock.locked-day{opacity:.55;cursor:not-allowed}
.pblock.locked-day:hover{transform:none;box-shadow:none;border-color:var(--q-line)}

/* 完成小勾：骑在右上角，一眼看出「这块做完了」 */
.pblock-done{
  position:absolute;top:-7px;right:-7px;width:17px;height:17px;border-radius:50%;
  background:var(--green-fill);color:var(--on-accent);display:flex;align-items:center;justify-content:center;
  box-shadow:0 1px 4px rgba(16,20,30,.25);z-index:2;
}
.pblock-done svg{width:9px;height:9px;display:block}

/* 检查模式：没打勾的高亮（红色描边 + 呼吸），点它弹三个去处 */
.pblock.ck{border-color:var(--red);box-shadow:0 0 0 3px var(--red-bg);cursor:pointer}
.pblock.ck:hover{border-color:var(--red)}
html[data-theme="dark"] .pblock.ck{border-color:var(--red-line);box-shadow:0 0 0 3px var(--red-bg)}
@media (prefers-reduced-motion: no-preference){
  .pblock.ck{animation:ckPulse 1.6s ease-in-out infinite}
  @keyframes ckPulse{
    0%,100%{box-shadow:0 0 0 3px var(--red-bg)}
    50%{box-shadow:0 0 0 5px var(--red-bg)}
  }
}

/* 固定目标叠层：还剩几次就叠几层 */
.pstack{position:relative;flex:none;padding-right:3px;padding-bottom:3px}
.pstack>.pblock{position:relative;z-index:2}
.pstack::before,.pstack::after{content:"";position:absolute;inset:0;border-radius:var(--r-sm);background:var(--q-soft);border:1px solid var(--q-line)}
.pstack::before{transform:translate(1px,1px);z-index:1;opacity:.9}
.pstack::after{transform:translate(2px,2px);z-index:0;opacity:.6}
.pstack-count{
  position:absolute;right:-3px;top:-6px;z-index:3;min-width:16px;height:16px;padding:0 4px;
  border-radius:7px;background:var(--q-base);color:var(--on-accent);font-size:11px;font-weight:var(--fw7);line-height:16px;text-align:center;
}

/* 表格 */
.grid-scroll{overflow-x:auto;padding-bottom:4px}
.plan-grid{border-collapse:separate;border-spacing:0;width:100%;min-width:860px;table-layout:fixed}
.plan-grid th,.plan-grid td{border-right:1px solid var(--line-2);border-bottom:1px solid var(--line-2);vertical-align:top}
.plan-grid th:first-child,.plan-grid td:first-child{width:92px;border-left:1px solid var(--line-2)}
.plan-grid thead th{
  background:var(--surface-2);font-size:12px;font-weight:var(--fw6);color:var(--ink-2);
  padding:6px 4px;text-align:center;
}
.plan-grid thead th.today{background:var(--accent-soft);color:var(--accent-ink)}
.plan-grid thead th:first-child{font-size:11px;color:var(--ink-4);font-weight:var(--fw5);border-top-left-radius:var(--r-sm)}
.plan-grid thead th:last-child{border-top-right-radius:var(--r-sm)}
.plan-grid thead th .dnum{display:block;font-size:11px;color:var(--ink-4);font-weight:var(--fw4);margin-top:1px}
.slot-col{background:var(--surface-2);padding:6px 5px}
.mini-btn{
  width:18px;height:18px;border-radius:7px;border:0;background:transparent;
  color:var(--ink-4);font-size:11px;line-height:1;padding:0;margin-top:3px;
  opacity:.55;
}
.slot-col:hover .mini-btn{opacity:1}
@media (min-width:901px){ .slot-col .mini-btn{opacity:0} .slot-col:hover .mini-btn{opacity:1} }
.mini-btn:hover{background:var(--red-bg);color:var(--red)}
.slot-time{
  display:block;font-size:11px;font-weight:var(--fw65);color:var(--ink-2);
  font-variant-numeric:tabular-nums;border-radius:7px;padding:1px 3px;margin:-1px -3px;
}
.slot-time:hover{background:var(--surface-3)}
.slot-cap{display:block;font-size:11px;color:var(--ink-4);margin-top:2px}
.slot-cell{padding:4px;min-height:64px;position:relative}
.slot-cell.today{background:var(--accent-wash)}
.slot-cell.over{background:var(--accent-soft)}
.slot-cell.over-cap{background:var(--red-bg)}
.slot-list{display:flex;flex-direction:column;gap:3px;min-height:52px}
.slot-list .pblock{width:100%;cursor:grab}
/* 时长文字：格子窄（最窄的列不到 130px），「2 小时 30 分 / 4 小时」放不下会被裁掉。
   所以允许换行，并去掉 nowrap 的隐患。 */
.slot-used{display:block;text-align:right;font-size:11px;color:var(--ink-4);margin-top:2px;
  opacity:.85;line-height:1.35;overflow-wrap:anywhere;white-space:nowrap}
/* 有把手的格子左侧让出了一条槽，格子可用宽度窄了，
   右对齐的时长文字会被右边框裁掉最后一个字 → 改成左对齐。
   但左对齐会压到左边的把手，所以整块文字往右挪 16px。 */
.slot-cell.has-handle .slot-used{text-align:left;padding-left:16px}
/* 合并后的上限另起一行。深色主题下 10px + 低透明度根本看不清，
   所以用 ink-3 而不是 ink-4，透明度也留足。 */
.slot-used em{display:block;font-style:normal;font-size:10.5px;color:var(--ink-3);
  opacity:.9;margin-top:1px;letter-spacing:.2px}
/* 合并后格子会变高，把时长文字推到方块下面而不是压住 */
.slot-cell.merged-top .slot-used,.slot-cell.merged-bot .slot-used{margin-top:3px}

/* 弹窗表单里的阶段草稿 */
.field-2{display:grid;grid-template-columns:1fr 1fr;grid-gap:10px;gap:10px}
.field-2 .field{margin-bottom:0}
.draft-stage{border:1px solid var(--line);border-radius:var(--r-sm);background:var(--surface-2);padding:10px;margin-bottom:8px}
.ds-top{display:flex;align-items:center;gap:7px;margin-bottom:8px}
.ds-idx{width:19px;height:19px;border-radius:7px;background:var(--accent-soft);color:var(--accent-ink);font-size:11px;font-weight:var(--fw7);line-height:19px;text-align:center}
.ds-title{flex:1;font-size:12px;font-weight:var(--fw6);color:var(--ink-2)}
.ds-top .icon-btn{width:24px;height:24px}
.stage-add{
  width:100%;border:1px dashed var(--line);background:transparent;color:var(--ink-3);
  border-radius:var(--r-sm);min-height:32px;font:inherit;font-size:12px;font-weight:var(--fw6);
}
.stage-add:hover{border-color:var(--accent);color:var(--accent-ink)}
.draft-stage .input{height:32px;font-size:13.5px}

/* ------------------------------------------------------------
   十、今日（手机端）
   ------------------------------------------------------------ */
.td-hero{padding:16px}
.td-hero-top{display:flex;align-items:center;justify-content:space-between;gap:10px}
.td-hero-top b{font-size:15px;font-weight:var(--fw65);color:var(--ink)}
.td-hero-nums{display:grid;grid-template-columns:repeat(3,1fr);margin-top:14px}
.td-hero-nums>div{text-align:center;min-width:0}
.td-hero-nums>div+div{border-left:1px solid var(--line-2)}
.td-hero-nums b{display:block;font-size:21px;font-weight:var(--fw65);line-height:1.15;color:var(--ink);letter-spacing:-.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.td-hero-nums b.sm{font-size:15px}
.td-hero-nums span{display:block;font-size:11px;color:var(--ink-4);margin-top:2px}
.td-bar{height:4px;border-radius:7px;background:var(--track);overflow:hidden;margin-top:14px}
.td-bar i{display:block;height:100%;border-radius:7px;background:var(--accent);transition:width .5s ease}
.td-hero-sub{margin-top:7px;font-size:11px;color:var(--ink-4)}

.td-list{display:flex;flex-direction:column;gap:7px}
.td-row{
  display:flex;align-items:center;gap:10px;cursor:pointer;
  background:var(--card);border:1px solid var(--line);
  border-left:3px solid var(--q-base);
  border-radius:var(--r-sm);padding:10px 12px;
  transition:background var(--dur),transform .1s;
}
.td-row:active{transform:scale(.995)}
.td-check{
  width:20px;height:20px;flex:none;border-radius:50%;
  border:1.5px solid var(--q-line);background:var(--surface);
  display:flex;align-items:center;justify-content:center;color:var(--green-fill);
}
.td-check svg{width:12px;height:12px}
.td-main{flex:1;min-width:0}
.td-main b{display:block;font-size:13.5px;font-weight:var(--fw6);color:var(--ink);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.td-main span{display:block;font-size:11px;color:var(--ink-4);margin-top:1px}
.td-tag{font-size:11px;font-weight:var(--fw65);color:var(--q-ink);opacity:.75;flex:none}
.td-row.done{background:var(--surface-2);opacity:.72}
.td-row.done .td-check{background:var(--green-fill);border-color:var(--green-fill);color:var(--on-accent)}
.td-row.done .td-main b{text-decoration:line-through;text-decoration-thickness:1px}
.td-done-btn{
  display:flex;align-items:center;gap:6px;width:100%;
  margin:18px 0 8px;padding:0;background:transparent;border:0;
  font:inherit;font-size:12px;font-weight:var(--fw6);color:var(--ink-4);text-align:left;
}
.td-done-btn svg{width:13px;height:13px;flex:none;color:var(--green)}
.td-done-btn span{flex:1;min-width:0}
.td-done-btn em{font-style:normal;font-weight:var(--fw6);color:var(--accent-ink);flex:none}
.td-empty{
  padding:26px 16px;text-align:center;font-size:13.5px;color:var(--ink-4);
  background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);line-height:1.8;
}

/* ------------------------------------------------------------
   十一、周报
   ------------------------------------------------------------ */
.wh-card{padding:18px 18px 16px}
.wh-top{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;flex-wrap:wrap;margin-bottom:16px}
.wh-nav{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.wk-lbl{font-size:13.5px;font-weight:var(--fw6);color:var(--ink-2);font-variant-numeric:tabular-nums}
.wh-score{display:flex;align-items:baseline;gap:10px;flex:none}
.wk-grade{font-size:13.5px;font-weight:var(--fw6);color:var(--ink-3)}
/* 用 inline-flex + baseline 对齐：百分号跟数字同一条基线，
   不再出现「40 与 % 之间空一截、% 悬在半空」 */
.wk-score{
  display:inline-flex;align-items:baseline;gap:1px;
  font-size:32px;font-weight:var(--fw65);line-height:1;color:var(--ink);
  letter-spacing:-1px;font-variant-numeric:tabular-nums;
}
.wk-score i{font-size:12px;font-weight:var(--fw5);margin-left:0;font-style:normal;color:var(--ink-4);line-height:1}

.wk-kpis{display:grid;grid-template-columns:repeat(6,1fr);border-top:1px solid var(--line-2);padding-top:14px}
.wk-kpi{min-width:0;padding:0 10px}
.wk-kpi:first-child{padding-left:0}
.wk-kpi+.wk-kpi{border-left:1px solid var(--line-2)}
.wk-kpi b{display:block;font-size:21px;line-height:1.2;color:var(--ink);font-weight:var(--fw65);letter-spacing:-.4px;white-space:nowrap}
.wk-kpi b i{font-size:11px;font-weight:var(--fw5);font-style:normal;color:var(--ink-4);margin-left:1px}
.wk-kpi>span{display:block;font-size:11px;color:var(--ink-3);margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.wk-kpi em{display:block;font-size:11px;font-style:normal;margin-top:2px;color:var(--ink-4);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

.wk-grid{display:grid;grid-template-columns:1fr;grid-gap:14px;gap:14px}
.wk-card{
  border-radius:var(--r);
  padding:18px 20px;min-width:0;
}
.wk-card>.card-title{margin-bottom:16px;font-size:13.5px}
.wk-card>.card-title svg{width:15px;height:15px}

/* 图表按比例缩放：限宽避免在 1160 的卡片里被拉到三百多像素高 */
.chart-scroll{overflow-x:auto;-webkit-overflow-scrolling:touch}
.chart-scroll>svg{max-width:820px;margin:0 auto;display:block}

/* 逐日投入：柱高 = 当天分钟数，颜色 = 象限 */
/* 逐日投入：柱子做细（16px），色块之间留 2px 缝。
   以前柱宽铺满 76px 且段与段紧贴，七根柱子像七条厚色带，看不出「一天由几块组成」。
   细柱 + 缝隙之后，堆叠关系一眼可数；细柱放不下的信息交给 title 悬停。 */
.wk-chart{
  display:grid;grid-template-columns:repeat(7,1fr);gap:10px;
  height:172px;padding-top:4px;border-bottom:1px solid var(--line-2);
}
.wk-day{display:flex;flex-direction:column;justify-content:flex-end;height:100%;min-width:0;text-align:center}
.wk-bar{
  display:flex;flex-direction:column-reverse;flex:1 1 auto;
  width:16px;margin:0 auto;min-height:0;gap:2px;
  background:transparent;border-radius:0;
}
.wk-bar i{
  display:block;width:100%;flex:none;border-radius:3px;
  background:var(--seg,var(--accent));
  box-shadow:inset 0 1px 0 rgba(255,255,255,.34),0 1px 2px rgba(10,16,28,.12);
}
.wk-bar i:last-child{border-radius:4px 4px 3px 3px}
.wk-dnum{font-size:11.5px;font-weight:var(--fw65);color:var(--ink-3);margin-bottom:6px;min-height:15px}
.wk-day.today .wk-dnum{color:var(--accent-ink)}
.wk-day.today .wk-dlbl{color:var(--accent-ink);font-weight:var(--fw6)}
.wk-dlbl{font-size:11px;color:var(--ink-4);margin-top:8px;white-space:nowrap}
.wk-legend{
  display:flex;flex-wrap:wrap;gap:5px 14px;margin-top:14px;padding-top:12px;
  border-top:1px solid var(--line-2);font-size:11px;color:var(--ink-3);
}
.wk-legend span{display:inline-flex;align-items:center;gap:5px}
.wk-legend i{width:8px;height:8px;border-radius:7px;display:inline-block;flex:none}

/* 四象限占比 */
.q-row{
  display:grid;grid-template-columns:minmax(0,1fr) auto;grid-gap:4px 10px;gap:4px 10px;
  align-items:center;padding:9px 0;font-size:12px;
  border-bottom:1px solid var(--line-2);
}
.q-row:last-of-type{border-bottom:0}
.q-name{grid-column:1;grid-row:1;color:var(--ink-2);min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.q-val{grid-column:2;grid-row:1;text-align:right;font-weight:var(--fw65);color:var(--ink);font-size:13.5px}
.q-bar{grid-column:1 / -1;grid-row:2;height:6px;border-radius:7px;background:var(--track);overflow:hidden}
.q-bar i{display:block;height:100%;border-radius:7px;background:linear-gradient(90deg,var(--q-base),var(--q-ink));opacity:.9}

/* 错题复习 */
.rv-stats{display:grid;grid-template-columns:repeat(3,1fr)}
.rv-stats>div{text-align:center;padding:0 6px;min-width:0}
.rv-stats>div+div{border-left:1px solid var(--line-2)}
.rv-stats b{display:block;font-size:21px;font-weight:var(--fw65);line-height:1.2;color:var(--ink)}
.rv-stats span{display:block;font-size:11px;color:var(--ink-4);margin-top:2px}

/* 复盘四栏 */
.kpt-row{display:flex;flex-direction:column;gap:4px;margin-bottom:10px}
.kpt-row label{font-size:12px;font-weight:var(--fw6);color:var(--ink-3)}
.kpt-row input{height:34px;font-size:13.5px}
.wk-note-acts{margin-top:12px}
.wk-more{margin-top:14px}

/* 累计数据 / 近 14 天 / 热力 */
.bh-stats{display:grid;grid-template-columns:repeat(5,1fr);margin-bottom:4px}
.bh-item{text-align:center;min-width:0;padding:0 6px}
.bh-item+.bh-item{border-left:1px solid var(--line-2)}
.bh-item b{display:block;font-size:21px;line-height:1.2;color:var(--ink);font-weight:var(--fw65);letter-spacing:-.3px}
.bh-item span{display:block;font-size:11px;color:var(--ink-4);margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.bh-sec{padding-top:14px;border-top:1px solid var(--line-2);margin-top:14px}
.bh-title{display:flex;align-items:center;gap:7px;font-weight:var(--fw6);font-size:12px;margin-bottom:10px;color:var(--ink-2);flex-wrap:wrap}
.bh-title .spacer{font-weight:var(--fw4);font-size:11px;color:var(--ink-4);margin-left:auto}
.bh-chart{width:100%;height:130px;display:block}
.bh-empty{background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);padding:11px 13px;font-size:12px;color:var(--ink-4);line-height:1.7}

.heat-grid{display:grid;grid-template-columns:repeat(14,1fr);grid-gap:3px;gap:3px;max-width:420px}
.heat-grid i{aspect-ratio:1;border-radius:7px;background:var(--track);display:block}
/* ⚠️ 等级类必须带 .heat-grid 前缀：`.heat-grid i` 是 (0,1,1)，
   而 `.heat-c1` 只有 (0,1,0) —— 不加前缀时 background 会被上一条盖掉，
   整块热力图永远是同一种灰（学生端周报一直是这个毛病，这里是修它）。 */
.heat-grid .heat-c0{background:var(--track)}
.heat-grid .heat-c1{background:var(--accent);opacity:.24}
.heat-grid .heat-c2{background:var(--accent);opacity:.44}
.heat-grid .heat-c3{background:var(--accent);opacity:.68}
.heat-grid .heat-c4{background:var(--accent);opacity:1}

/* 试卷情况：图表与结论 */
.bd-sub{font-size:12px;font-weight:var(--fw65);color:var(--ink-3);margin:16px 0 8px}
.bd-legend{display:flex;flex-wrap:wrap;gap:5px 14px;font-size:12px;color:var(--ink-2);margin-top:11px}
.bd-legend span{display:inline-flex;align-items:center;gap:5px}
.bd-legend i{width:8px;height:8px;border-radius:7px;display:inline-block;flex:none}
.bd-legend b{font-weight:var(--fw65);color:var(--ink)}
.bd-list{margin:0;padding-left:17px;display:flex;flex-direction:column;gap:6px;font-size:13.5px;line-height:1.75;color:var(--ink-2)}
.bd-advice li::marker{color:var(--accent);font-weight:var(--fw7)}
.bd-stats{display:grid;grid-template-columns:repeat(4,1fr);grid-gap:8px;gap:8px;margin-bottom:12px}
.bd-stat{background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);padding:9px 10px;min-width:0}
.bd-stat b{display:block;font-size:21px;font-weight:var(--fw65);line-height:1.2;color:var(--ink);letter-spacing:-.3px}
.bd-stat span{display:block;font-size:11px;color:var(--ink-4);margin-top:2px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.bd-stat.warn b{color:var(--amber)}
.bd-stat.bad b{color:var(--red)}
.bd-bar-row{display:grid;grid-template-columns:64px minmax(0,1fr) 48px;grid-gap:3px 8px;gap:3px 8px;align-items:center;font-size:12px}
.bd-bar-name{color:var(--ink-2);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.bd-bar{height:6px;border-radius:7px;background:var(--track);overflow:hidden;min-width:0}
.bd-bar i{display:block;height:100%;border-radius:7px;background:var(--accent)}
.bd-bar-val{text-align:right;font-weight:var(--fw65);color:var(--ink)}
.bd-bar-sub{grid-column:2 / 4;font-size:11px;color:var(--ink-4);line-height:1.5}
.bd-card svg line.bd-grid{stroke:var(--line)}
.bd-card svg text.bd-axis{fill:var(--ink-4)}

/* 手机端二级内容：概览默认只留一行摘要，展开才看细节 */
.ov-head{
  display:flex;align-items:center;gap:10px;width:100%;
  padding:1px 0;background:transparent;border:0;text-align:left;
}
.ov-ico{flex:none;display:inline-flex;color:var(--ink-3)}
.ov-ico svg{width:15px;height:15px}
.ov-main{flex:1;min-width:0}
.ov-main b{display:block;font-size:13.5px;font-weight:var(--fw65);color:var(--ink);line-height:1.4}
.ov-main span{display:block;font-size:12px;color:var(--ink-4);margin-top:1px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ov-chev{flex:none;font-size:12px;font-weight:var(--fw6);color:var(--accent-ink)}
.ov-fold .ov-body{margin-top:12px}
.ov-fold:not(.open) .ov-body{display:none}

/* ------------------------------------------------------------
   十二、错题本 / 试卷（分栏）
   ------------------------------------------------------------ */
.split{display:grid;grid-template-columns:320px minmax(0,1fr);grid-gap:14px;gap:14px;align-items:start}
.split-main{min-width:0}
.split-add{display:none}
.split-head{display:flex;align-items:center;gap:8px;margin-bottom:11px;flex-wrap:wrap;min-height:30px}
.split-head b{font-size:15px;font-weight:var(--fw65);color:var(--ink)}
.split-head .spacer{flex:1}
.split-head .seg-mini{margin-left:auto}

/* ------------------------------------------------------------
   搜索框（错题本 / 试卷）
   胶囊容器 + 右侧圆形按钮。整块只吃令牌，深浅两套主题自动跟随；
   按钮的 hover 上浮 / 按下回弹是这套控件的识别点，别删。
   输入框放在 #nbList / #paList 之外（静态 DOM），重渲染才不会丢焦点。
   ------------------------------------------------------------ */
.search-box{
  display:flex;align-items:center;gap:9px;
  width:100%;max-width:340px;height:44px;
  padding:0 6px 0 14px;margin-bottom:16px;
  /* 底色用 --surface 而不是 --surface-2：浅色下 --surface-2 和页底几乎同色，
     整个框会「陷」进背景里，只剩一圈线 */
  background:var(--surface);border:1px solid var(--line);border-radius:999px;
  position:relative;
  transition:background var(--dur),border-color var(--dur),box-shadow var(--dur);
}
.search-box:focus-within{
  border-color:var(--accent-line);
  box-shadow:0 0 0 3px var(--accent-wash);
}
.search-ico{flex:none;display:inline-flex;color:var(--ico);transition:color var(--dur)}
.search-box:focus-within .search-ico{color:var(--accent-ink)}
.search-input{
  flex:1 1 auto;min-width:0;border:0;background:none;outline:none;
  color:var(--ink);font-family:inherit;font-size:13.5px;line-height:1.4;
  padding:0 44px 0 0;
  -webkit-appearance:none;appearance:none;
}
.search-input::placeholder{color:var(--ink-4);opacity:1}
.search-input::-webkit-search-cancel-button,
.search-input::-webkit-search-decoration{-webkit-appearance:none;display:none}
.search-btn{
  position:absolute;right:5px;top:50%;
  width:34px;height:34px;border:0;border-radius:50%;padding:0;
  background:var(--accent);color:var(--on-accent);
  display:inline-flex;align-items:center;justify-content:center;
  transform:translateY(-50%);
  transition:transform .28s cubic-bezier(.23,1,.32,1),box-shadow .28s ease,filter var(--dur);
}
.search-btn:hover{
  transform:translateY(calc(-50% - 2px));
  box-shadow:0 9px 18px -6px rgba(69,69,216,.5);
  filter:brightness(1.07);
}
.search-btn:active{transform:translateY(-50%);box-shadow:none;filter:brightness(.96)}
/* 深色下 --accent-grad 是中等饱和紫，白字只有 4.1:1，换成浅紫底 + 深字 */
html[data-theme="dark"] .search-btn{background:var(--accent);color:#11131a}
html[data-theme="dark"] .search-btn:hover{box-shadow:0 9px 18px -8px rgba(0,0,0,.9);filter:brightness(1.05)}
.search-clear{
  position:absolute;right:42px;top:50%;transform:translateY(-50%);
  width:22px;height:22px;border:0;border-radius:50%;padding:0;
  background:var(--surface-3);color:var(--ink-3);
  display:inline-flex;align-items:center;justify-content:center;
  transition:background var(--dur),color var(--dur),transform var(--dur);
}
.search-clear:hover{background:var(--line);color:var(--ink);transform:translateY(-50%) scale(1.06)}
mark{background:var(--accent-soft);color:var(--accent-ink);border-radius:7px;padding:0 1px}
@media (max-width:900px){
  .search-box{max-width:none}
}

.nb-item{
  background:linear-gradient(160deg,var(--glass-a),var(--glass-b));
  border:1px solid var(--glass-line);border-radius:var(--r-sm);
  box-shadow:0 1px 0 rgba(255,255,255,.5) inset,0 10px 22px -20px rgba(26,34,56,.5);
  padding:11px 13px;margin-bottom:7px;cursor:pointer;
  transition:background var(--dur),border-color var(--dur);
}
.nb-item:hover{background:var(--surface-2)}
.nb-item.on{border-color:var(--accent-line);background:var(--accent-soft)}
.nb-top{display:flex;align-items:center;gap:7px;flex-wrap:wrap;margin-bottom:2px}
.nb-title{font-size:13.5px;font-weight:var(--fw6);color:var(--ink);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%}
.nb-meta{font-size:11px;color:var(--ink-4);line-height:1.6}
.nb-mastery{display:flex;align-items:center;gap:8px;font-size:11px;color:var(--ink-3);flex-wrap:wrap;margin-top:5px}
.nb-detail{padding:16px 18px}
.nb-dtitle{font-size:15px;font-weight:var(--fw65);margin:0 0 3px;color:var(--ink);line-height:1.4}
.nb-actions{display:flex;gap:8px;align-items:center;margin-top:12px;flex-wrap:wrap}
.nb-actions .tiny{flex:1;min-width:140px}
.kv{display:flex;gap:10px;padding:6px 0;border-bottom:1px solid var(--line-2);font-size:13.5px}
.kv:last-child{border-bottom:0}
.kv .k{flex:none;width:64px;color:var(--ink-4);font-size:12px}
.kv .v{flex:1;min-width:0;color:var(--ink-2)}

.mastery-bar{display:inline-flex;gap:2px}
.mastery-bar i{width:11px;height:4px;border-radius:7px;background:var(--track);display:block}
.mastery-bar i.on{background:var(--accent)}
.mastery-txt{font-weight:var(--fw6)}
.mastery-txt.m1,.mastery-txt.m2{color:var(--red)}
.mastery-txt.m3{color:var(--amber)}
.mastery-txt.m4,.mastery-txt.m5{color:var(--green)}

/* 今天要复习 */
.due-list{display:flex;flex-direction:column;gap:5px}
.due-item{
  display:flex;align-items:center;gap:8px;
  background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-xs);
  padding:7px 9px;font-size:12px;cursor:pointer;
  transition:background var(--dur),border-color var(--dur);
}
.due-item:hover{border-color:var(--accent-line);background:var(--surface-2)}
.due-item b{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:var(--fw5);color:var(--ink)}
.due-sub{flex:none;font-size:11px;background:var(--surface-2);border:1px solid var(--line-2);border-radius:7px;padding:0 5px;color:var(--ink-3)}

/* 照片 */
.photo-drop{
  border:1px dashed var(--line);border-radius:var(--r-sm);
  padding:16px 12px;text-align:center;background:var(--surface-2);
  cursor:pointer;transition:border-color var(--dur),background var(--dur);
}
.photo-drop:hover{border-color:var(--accent);background:var(--accent-soft)}
/* 文件正拖到框上方：整块高亮 + 虚线变实线，松手前的反馈要够明确 */
.photo-drop.is-drag{
  border-style:solid;border-color:var(--accent);
  background:var(--accent-soft);
  box-shadow:0 0 0 3px var(--accent-line) inset;
}
.photo-drop svg{color:var(--ico);margin:0 auto 6px}
.photo-drop-main{font-size:13.5px;font-weight:var(--fw6);color:var(--ink-2)}
.photo-thumbs{display:grid;grid-template-columns:repeat(auto-fill,minmax(76px,1fr));grid-gap:7px;gap:7px;margin-top:9px}
.photo-thumbs:empty{display:none}
.photo-thumbs .ph{position:relative;border-radius:var(--r-xs);overflow:hidden;border:1px solid var(--line);aspect-ratio:3/4;background:var(--surface-2)}
.photo-thumbs .ph img{width:100%;height:100%;object-fit:cover}
.photo-thumbs .ph button{
  position:absolute;top:3px;right:3px;background:rgba(0,0,0,.6);color:var(--on-accent);
  width:20px;height:20px;border-radius:7px;font-size:11px;line-height:1;padding:0;
}

/* 试卷：类型分段 + 列表分数 */
.type-pick{
  display:grid;grid-template-columns:1fr 1fr;grid-gap:3px;gap:3px;
  background:var(--surface-2);border:1px solid var(--line-2);
  border-radius:var(--r-sm);padding:3px;margin-bottom:14px;
}
.type-card{
  border:0;background:transparent;border-radius:7px;
  height:30px;font-size:12px;font-weight:var(--fw6);color:var(--ink-3);
  transition:background var(--dur),color var(--dur);
}
.type-card:hover{color:var(--ink-2)}
.type-card.sel{background:var(--raise);color:var(--ink);box-shadow:0 1px 3px rgba(16,20,30,.14)}

.pa-row{display:flex;align-items:center;gap:14px}
.pa-bd{flex:1;min-width:0}
.pa-title{display:flex;align-items:center;gap:6px;margin-bottom:2px;min-width:0}
.pa-title b{font-size:13.5px;font-weight:var(--fw6);color:var(--ink);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.pa-title .lv-badge{flex:none}
.pa-meta{font-size:11px;color:var(--ink-4);line-height:1.5;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pa-sc{
  flex:none;display:flex;align-items:baseline;gap:3px;
  padding-left:13px;border-left:1px solid var(--line-2);
  min-width:96px;justify-content:flex-end;
}
.pa-sc b{font-size:21px;font-weight:var(--fw65);letter-spacing:-.6px;line-height:1}
.pa-sc span{font-size:11px;color:var(--ink-4)}
.pa-sc em{font-style:normal;font-size:11px;font-weight:var(--fw6);opacity:.9}

.lv-badge{
  display:inline-flex;align-items:center;gap:4px;font-weight:var(--fw65);font-size:12px;
  padding:1px 8px;border-radius:999px;line-height:1.7;
}
.lv-badge[data-size="sm"]{font-size:11px;padding:0 6px}
.lv-Aplus,.lv-A{background:var(--green-bg);color:var(--green)}
.lv-Aminus{background:var(--amber-bg);color:var(--amber)}
.lv-C{background:var(--red-bg);color:var(--red)}

.score-line{display:flex;align-items:baseline;gap:8px;margin:8px 0}
.score-line .big{font-size:32px;font-weight:var(--fw65);letter-spacing:-.8px;line-height:1}
.score-line .of{font-size:12px;color:var(--ink-4)}
.rate-bar{height:5px;border-radius:7px;background:var(--track);overflow:hidden;margin:8px 0 9px}
.rate-bar i{display:block;height:100%;border-radius:7px;transition:width .5s ease}

.analysis-box{
  background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);
  padding:12px 14px;font-size:13.5px;line-height:1.8;color:var(--ink-2);
}
.analysis-box b{color:var(--ink);font-weight:var(--fw65)}
.analysis-box ul{margin:6px 0 0;padding-left:17px}
.analysis-box li{margin-bottom:3px}
.ai-box{
  background:var(--inset);border:1px solid var(--inset-line);
  border-radius:var(--r-sm);padding:13px 14px;font-size:13.5px;
  line-height:1.8;color:var(--ink-2);white-space:pre-wrap;
  max-height:420px;overflow:auto;margin-top:8px;
}
.ai-tag{
  display:inline-flex;align-items:center;gap:5px;
  font-size:11px;font-weight:var(--fw65);color:var(--accent-ink);
  background:var(--accent-soft);border:1px solid var(--accent-line);
  border-radius:999px;padding:1px 9px;margin:10px 0 0;
}
.ai-hint{margin-top:8px;line-height:1.6}

/* ------------------------------------------------------------
   十三、拍照判卷
   ------------------------------------------------------------ */
.pc-note{display:none}
.gd-pc{
  border-radius:var(--r);
  padding:16px 18px;margin-bottom:14px;
}
.gd-pc-main{display:flex;align-items:center;gap:11px}
.gd-pc-ico{
  width:36px;height:36px;border-radius:var(--r-sm);flex:none;
  background:var(--accent-soft);color:var(--accent-ink);
  border:1px solid var(--accent-line);
  display:flex;align-items:center;justify-content:center;
}
.gd-pc-txt{min-width:0}
.gd-pc-txt b{display:block;font-size:13.5px;font-weight:var(--fw65);color:var(--ink);margin-bottom:1px}
.gd-pc-txt span{display:block;font-size:12px;color:var(--ink-3);line-height:1.6}
.gd-pc-steps{
  display:flex;gap:8px;flex-wrap:wrap;margin:14px 0 0;padding:12px 0 0;
  border-top:1px solid var(--line-2);list-style:none;
}
.gd-pc-steps li{
  display:flex;align-items:center;gap:6px;font-size:12px;color:var(--ink-2);
  background:var(--inset);border-radius:var(--r-xs);padding:5px 10px;
}
.gd-pc-steps i{
  font-style:normal;font-size:11px;font-weight:var(--fw7);color:var(--ink-3);
  background:var(--surface);border:1px solid var(--line);
  width:16px;height:16px;border-radius:50%;
  display:flex;align-items:center;justify-content:center;flex:none;
}
.gd-pc-state{display:flex;align-items:center;gap:7px;font-size:12px;color:var(--ink-4);margin-top:12px;line-height:1.6}
.gph-dot{width:6px;height:6px;border-radius:50%;flex:none;display:inline-block;background:var(--ink-4)}
.gph-dot.ok{background:var(--green)}
.gph-dot.bad{background:var(--amber)}
.gd-empty{font-size:12px;color:var(--ink-4);line-height:1.8;padding:2px 0 4px}

.gd-answer{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:10px}
.gd-ans-row{
  display:flex;align-items:center;gap:8px;flex-wrap:wrap;
  background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);
  padding:7px 10px;margin-top:8px;font-size:12px;
}
.gd-ans-row svg{color:var(--ico);flex:none}
.gd-ans-row .an{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:var(--fw6);color:var(--ink)}
.gd-ans-row select{height:28px;padding:0 24px 0 7px;font-size:12px;width:auto;min-width:56px}

.gd-list{display:flex;flex-direction:column;gap:8px}
.gd-item{
  background:var(--inset);border:1px solid var(--inset-line);
  border-left:3px solid transparent;border-radius:var(--r-sm);padding:10px 12px;
}
.gd-item.bad{background:var(--red-bg);border-color:var(--red-line);border-left-color:var(--red)}
.gd-item.good{opacity:.75}
.gd-head{display:flex;align-items:center;gap:8px;margin-bottom:6px;flex-wrap:wrap}
.gd-head b{font-size:13.5px;font-weight:var(--fw65);color:var(--ink)}
.gd-head .spacer{flex:1}
.gd-seg{background:var(--surface)}
.gd-seg button{min-width:40px}
.gd-body .kv{padding:4px 0;font-size:12px;border-color:var(--line-2)}
.gd-body .k{width:60px}
.gd-body select{height:30px;font-size:12px;max-width:200px}
.gd-think{margin-top:6px}
.gd-think summary{
  cursor:pointer;font-size:12px;font-weight:var(--fw6);color:var(--accent-ink);
  padding:5px 0;list-style:none;
}
.gd-think summary::-webkit-details-marker{display:none}
.gd-think summary::before{content:'▸ ';font-size:11px}
.gd-think[open] summary::before{content:'▾ '}
.gd-think .think-body{
  background:var(--surface);border:1px solid var(--line-2);border-radius:var(--r-xs);
  padding:10px 12px;font-size:12px;line-height:1.8;color:var(--ink-2);white-space:pre-wrap;
}

.gd-hist{display:flex;flex-direction:column}
.gd-hrow{
  display:flex;align-items:center;gap:10px;
  padding:10px 0;border-bottom:1px solid var(--line-2);font-size:13.5px;
}
.gd-hrow:last-child{border-bottom:0}
.gd-hrow .gh-ico{
  width:30px;height:30px;border-radius:var(--r-xs);flex:none;
  display:flex;align-items:center;justify-content:center;
  background:var(--surface-2);color:var(--ink-4);
}
.gd-hrow .gh-main{flex:1;min-width:0}
.gd-hrow .gh-main b{display:block;font-size:13.5px;font-weight:var(--fw6);color:var(--ink);line-height:1.5}
.gd-hrow .gh-main span{display:block;font-size:11px;color:var(--ink-4);line-height:1.5}
.gd-hrow .gh-num{flex:none}

/* ------------------------------------------------------------
   十四、我的
   ------------------------------------------------------------ */
.pf-card{
  display:flex;align-items:center;gap:16px;padding:18px;
  background:var(--surface);
  border-color:var(--accent-line);
}
html[data-theme="dark"] .pf-card{background:var(--surface)}
.pf-av{
  position:relative;flex:none;border-radius:50%;
  background:none;border:0;line-height:0;
}
.pf-av.is-drag{outline:2px solid var(--accent);outline-offset:3px}
.pf-av-cam{
  position:absolute;right:-2px;bottom:-2px;width:22px;height:22px;border-radius:50%;
  background:var(--surface);border:1px solid var(--line);color:var(--ink-3);
  display:flex;align-items:center;justify-content:center;
}
.pf-av-cam svg{width:13px;height:13px}
.pf-av:hover .pf-av-cam{border-color:var(--accent-line);color:var(--accent-ink)}
.pf-main{flex:1;min-width:0}
.pf-name-row{display:flex;align-items:center;gap:4px}
.pf-name-row b{font-size:21px;font-weight:var(--fw65);color:var(--ink);line-height:1.35;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pf-edit-btn{width:26px;height:26px;opacity:.5}
.pf-edit-btn:hover{opacity:1}
.pf-edit{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.pf-edit input{height:32px;font-size:13.5px;max-width:180px;flex:1;min-width:110px}
.pf-mail{font-size:12px;color:var(--ink-4);margin-top:1px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pf-reset{flex:none;width:auto;padding:0 9px;font-size:11px;color:var(--ink-4)}
.pf-reset:hover{color:var(--red);background:var(--red-bg)}

/* 头像：三处共用 */
.av{
  display:inline-flex;align-items:center;justify-content:center;flex:none;
  border-radius:50%;background:var(--accent-soft);color:var(--accent-ink);
  font-weight:var(--fw65);overflow:hidden;
  border:1px solid var(--accent-line);
}
.av img{width:100%;height:100%;object-fit:cover;border-radius:50%}
.av.av-sm{width:30px;height:30px;font-size:13.5px}
.av.av-lg{width:52px;height:52px;font-size:21px}

/* 设置区：一整块玻璃板，双列，各部分之间只用 1px 细线分开。
   以前每部分各是一张圆角卡，一屏七个圆角，反而不知道该从哪里读起。 */
.set-board{
  display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  border-radius:var(--r);overflow:hidden;
  background-color:var(--glass-a);
  background-image:none;
  border:1px solid var(--glass-line);
  -webkit-backdrop-filter:none;
  backdrop-filter:none;
  box-shadow:var(--glass-shadow);
}
.set-col{display:flex;flex-direction:column;min-width:0}
.set-col + .set-col{border-left:1px solid var(--line)}
.set-sec{padding:13px 0 2px;margin:0;min-width:0}
.set-sec + .set-sec{border-top:1px solid var(--line)}
.set-title{font-size:11px;font-weight:var(--fw65);color:var(--ink-4);padding:0 18px 6px;letter-spacing:.04em}
.set-list{border-radius:0;overflow:visible}
/* 行铺满整列、文字内缩 18px：hover 的高亮能贴到列的边上，
   同时不需要负 margin —— 负 margin 会让内容宽度算错（AI 模型名会被压成「Dee…」）。 */
.set-row{
  display:flex;align-items:center;gap:12px;width:100%;text-align:left;
  background:transparent;border:0;border-bottom:1px solid var(--line-2);
  padding:11px 18px;min-height:44px;font:inherit;font-size:13.5px;color:var(--ink);
}
.set-row:last-child{border-bottom:0}
button.set-row{cursor:pointer;transition:background var(--dur)}
button.set-row:hover{background:var(--surface-2)}
.set-row .k{flex:none;font-weight:var(--fw5);color:var(--ink)}
.set-row .seg-mini{margin-left:auto}
.set-row .v{flex:1;min-width:0;text-align:right;color:var(--ink-4);font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.set-row.danger .k{color:var(--red)}
/* 操作留痕：一条一行，左文右时间；长文案要能换行，不能撑破设置栏 */
.set-row.log-row{align-items:flex-start}
.set-row.log-row .k{flex:1 1 auto;min-width:0;white-space:normal;line-height:1.55;font-size:12px}
.set-row.log-row .v{flex:none;margin-left:8px;white-space:nowrap}
button.set-row.danger:hover{background:var(--red-bg)}

.ai-model-row .k{flex:1;min-width:0;display:flex;align-items:center;gap:7px}
.ai-mname{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ai-model-row .ai-tag{
  flex:none;font-size:11px;font-weight:var(--fw65);border-radius:7px;padding:0 5px;margin:0;
  background:var(--surface-2);color:var(--ink-3);border:1px solid var(--line);
}
.ai-model-row .ai-tag-fast{background:var(--accent-soft);color:var(--accent-ink);border-color:var(--accent-line)}
.ai-model-row.on{background:var(--accent-soft)}
.ai-model-row.on .k{color:var(--accent-ink);font-weight:var(--fw6)}
.ai-stats{margin-top:8px;padding:0 3px;line-height:1.75;color:var(--ink-4);font-size:11px}
.ai-stats b{color:var(--ink-2);font-weight:var(--fw65)}

/* ------------------------------------------------------------
   十五、登录
   ------------------------------------------------------------ */
.gate{
  position:relative;min-height:100vh;
  display:flex;flex-direction:column;align-items:center;justify-content:center;
  padding:52px 18px 44px;
  /* 登录页固定用品牌紫：它不属于任何一个 Tab，
     跟着 body[data-page] 变会出现「从青色页退出 → 登录页是青的」。 */
  --accent:#4f46e5;--accent-2:#a855f7;--accent-ink:#3f35b8;
  --accent-soft:#eef0ff;--accent-glide:#e7e6fd;--accent-line:#dcdcfb;
  --accent-grad:linear-gradient(135deg,#4f46e5 0%,#7c3aed 100%);
  --fog-a:rgba(79,70,229,.13); --fog-b:rgba(124,58,237,.12);
  --glow:rgba(79,70,229,.5);--aura:rgba(79,70,229,.12);
  --accent-wash:rgba(79,70,229,.08);
}
html[data-theme="dark"] .gate{
  --accent:#a5a0ff;--accent-2:#d8b4fe;--accent-ink:#c7c2ff;
  --accent-soft:rgba(129,120,248,.18);--accent-glide:rgba(165,160,255,.2);
  --accent-line:rgba(165,160,255,.28);
  --accent-grad:linear-gradient(135deg,#8b80ff 0%,#c084fc 100%);
  --fog-a:rgba(139,128,255,.09); --fog-b:rgba(192,132,252,.05);
  --glow:rgba(129,120,248,.55);--aura:rgba(165,160,255,.16);
}
/* 一团很淡的紫光把卡片托起来。不用整屏遮罩——这是入口页，不是弹窗。 */
.gate::before{
  content:"";position:absolute;left:50%;top:-160px;width:760px;height:540px;
  transform:translateX(-50%);pointer-events:none;
  background:radial-gradient(closest-side,rgba(124,92,245,.22),transparent 72%);
}
html[data-theme="dark"] .gate::before{background:radial-gradient(closest-side,rgba(139,92,246,.32),transparent 72%)}

.gate-top{
  width:100%;max-width:404px;margin-bottom:12px;padding:0 4px;
  display:flex;align-items:center;justify-content:space-between;gap:12px;
}
.gate-wordmark{font-size:11px;font-weight:var(--fw7);letter-spacing:.18em;color:var(--ink-4)}

.gate-card{
  position:relative;width:100%;max-width:404px;
  border-radius:10px;padding:30px 28px 26px;
  box-shadow:var(--shadow-modal);
}
/* 卡片顶边一道渐变细线，呼应品牌色，又不至于变成一整块紫 */
.gate-card::after{
  content:"";position:absolute;left:26px;right:26px;top:-1px;height:1px;
  background:linear-gradient(90deg,transparent,var(--accent),transparent);opacity:.75;
}
.gate-head{text-align:center;margin-bottom:20px}
.gb-mark{
  width:52px;height:52px;border-radius:10px;margin:0 auto 14px;
  /* 同一个标记的完整形态：这里放得下环，所以环 + 勾一起出现 */
  background:linear-gradient(150deg,#1b2540 0%,#080d17 100%);
  border:1px solid rgba(255,255,255,.11);
  display:flex;align-items:center;justify-content:center;
  box-shadow:none;
}
.gate-head h2{margin:0;font-size:21px;font-weight:var(--fw7);letter-spacing:-.3px;color:var(--ink)}
.gb-sub{margin:6px 0 0;font-size:13.5px;color:var(--ink-4)}

.gate-msg{
  border-radius:10px;padding:9px 12px;font-size:12px;margin-bottom:13px;
  line-height:1.6;display:none;
}
.gate-msg.show{display:block}
.gate-msg.err{background:var(--red-bg);color:var(--red)}
.gate-msg.ok{background:var(--green-bg);color:var(--green)}
.gate-msg.info{background:var(--sky-bg);color:var(--sky)}

/* 表单：输入框是「凹槽」，聚焦时抬起并亮边 —— 与卡片保持同一套层次 */
.gate .seg{margin-bottom:18px}
.gate .form-row{margin-bottom:12px;gap:0}
.gate .form-row label{display:block;font-size:12px;font-weight:var(--fw6);color:var(--ink-3);margin-bottom:6px}
/* 登录门的字段与应用内 input 同一套长相：白底 + 1px 描边 + 聚焦亮边。
   只保留高度这一档差异（44 = 主操作页的手要够得着，36 = 卡片里够用），
   以前这里是无边框的填充底，用户从登录页进到应用里会觉得「换了个软件」。 */
.gate input{
  height:44px;border-radius:7px;font-size:13.5px;padding:0 12px;
}
.gate input:hover{border-color:var(--accent-line)}
.gate input:focus{border-color:var(--accent);box-shadow:0 0 0 4px var(--accent-wash)}
.gate .code-row{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-gap:8px;gap:8px;align-items:center}
.gate #btnGetCode{height:44px;border-radius:7px;padding:0 14px;font-size:13.5px;flex:none}
.gate .btn-block{height:44px;border-radius:7px;font-size:13.5px;font-weight:var(--fw65)}
.gate .gate-guest .btn-block{
  height:42px;font-size:13.5px;
  background:var(--glass-a);border:1px solid var(--field-line);
  box-shadow:0 1px 0 var(--glass-hi) inset;
}
.gate .gate-guest .btn-block:hover{background:var(--accent-soft);border-color:var(--accent-line);color:var(--accent-ink)}
.gate .gate-or{margin:18px 0 12px}
/* 版本通道：一个折叠下拉。默认只露「正在用」，展开才列快照 ——
   稳定版是救急用的，不该和登录按钮抢注意力。
   展开靠原生 <details>：不依赖脚本执行，任何环境点一下都开。 */
.ver-pick{position:relative;display:flex;justify-content:center;margin:16px 0 0}
.ver-cur{
  display:inline-flex;align-items:center;gap:7px;
  height:30px;padding:0 11px;border-radius:999px;
  font-size:12px;color:var(--accent-ink);
  border:1px solid var(--accent-line);background:var(--accent-soft);
  cursor:pointer;list-style:none;user-select:none;
  -webkit-tap-highlight-color:transparent;
  transition:color var(--dur),border-color var(--dur),background var(--dur);
}
/* summary 自带的三角标记要去掉，这颗胶囊本身已经是触发器 */
.ver-cur::-webkit-details-marker{display:none}
.ver-cur::marker{content:""}
.ver-cur:hover{border-color:var(--accent)}
.ver-cur .vo-k{font-weight:var(--fw6)}
.ver-cur .vo-v{font-size:11px;letter-spacing:.03em;opacity:.82}
.vc-chev{opacity:.7;transition:transform .2s ease}
.ver-pick[open] .vc-chev,
.ver-pick.open .vc-chev{transform:rotate(180deg)}
.ver-menu{
  position:absolute;left:50%;bottom:calc(100% + 8px);transform:translateX(-50%);
  width:252px;padding:6px;border-radius:10px;z-index:24;
  /* 不透明底：这块盖在登录卡上，玻璃底会让底下的「或者 / 游客入口」透出来 */
  background:var(--surface);
  border:1px solid var(--line);
  box-shadow:0 18px 40px -20px rgba(10,14,22,.55);
}
.ver-item{
  display:block;padding:8px 10px;border-radius:10px;text-decoration:none;
  color:var(--ink-2);font-size:12px;
  transition:background var(--dur),color var(--dur);
}
.ver-item:hover{background:var(--surface-2);color:var(--ink)}
.ver-item.on{background:var(--accent-soft);color:var(--accent-ink)}
.ver-item .vi-main{display:flex;align-items:center;gap:7px}
.ver-item .vo-k{font-weight:var(--fw65)}
.ver-item .vo-v{font-size:11px;opacity:.75}
.ver-item em{display:block;font-style:normal;margin-top:2px;font-size:11px;color:var(--ink-4)}
.ver-item.on em{color:var(--accent-ink);opacity:.8}
/* 卡片比视口高时，居中对齐会把顶部推出屏幕（flex 的经典问题） */
@media (max-height:720px){
  .gate{justify-content:flex-start;padding-top:28px}
}

/* ------------------------------------------------------------
   十六、浮层
   ------------------------------------------------------------ */
.modal-mask{
  position:fixed;inset:0;background:rgba(8,12,20,.58);
  backdrop-filter:none;-webkit-backdrop-filter:none;
  display:none;align-items:center;justify-content:center;
  padding:16px;z-index:80;overflow:auto;
}
.modal-mask.show{display:flex}
.modal{
  border-radius:var(--r-lg);padding:20px 22px;width:100%;max-width:480px;
  box-shadow:var(--shadow-modal);
  max-height:88vh;overflow:auto;
  overscroll-behavior:contain;
}
.modal h3{margin:0 0 4px;font-size:15px;font-weight:var(--fw65)}
/* 弹窗顶那句「这功能是怎么设计的」已经搬进新手教程，标题直接接表单了，
   这里补回一段间距，否则标题贴着第一个输入框。 */
.modal h3 + .field,.modal h3 + .field-2,.modal h3 + .modal-actions{margin-top:12px}
/* 子目标弹窗要在标题下说清「这是哪个阶段下的」，这行是上下文，不是说明 */
.dlg-where{margin:0 0 12px;font-size:12px;color:var(--ink-4)}
/* 固定目标的「日期」：周系七个可多选的星期按钮 / 月系一个「几号」下拉 */
.day-pick{display:flex;gap:6px;flex-wrap:wrap}
.day-pick button{
  width:36px;height:32px;padding:0;border-radius:8px;cursor:pointer;
  border:1px solid var(--line);background:var(--surface);color:var(--ink-3);
  font-size:12px;font-weight:var(--fw5);
}
.day-pick button:hover{border-color:var(--accent-line);color:var(--accent-ink)}
.day-pick button.on{background:var(--accent);border-color:var(--accent);color:var(--on-accent)}
.day-pick button:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.modal .intro{margin:0 0 14px;font-size:12px;color:var(--ink-4);line-height:1.6}
.modal .muted{font-size:13.5px;line-height:1.75;color:var(--ink-2);margin:0 0 14px}
.modal .danger-title{color:var(--red);margin-bottom:8px}
.modal-actions{display:flex;gap:8px;margin-top:18px}
.modal-actions .btn{flex:1}
#planDialog .modal{max-width:520px}

/* 录入浮层：桌面上是居中对话框，手机上是底部升起的面板。
   表单搬进来时不再套 .card（浮层本身就是那张卡），所以这里只管内部节奏。 */
.sheet-modal{
  max-width:560px;width:100%;padding:0 22px 22px;
  /* 浮层是「贴着脸的一层纸」，太透会读到背后的色块，反而看不清字 */
  --glass-a:rgba(255,255,255,.975);
  --glass-b:rgba(255,255,255,.94);
  --glass-line:rgba(255,255,255,.9);
  --spot:transparent;
}
html[data-theme="dark"] .sheet-modal{
  --glass-a:rgba(24,33,48,.975);
  --glass-b:rgba(18,25,38,.94);
  --glass-line:rgba(255,255,255,.09);
}
/* 浮层不要主题色雾：大面积淡色会显得脏，色相留给按钮与边线 */
.sheet-modal,.modal{background-image:none}
/* 浮层里第一段说明与表单之间留一口气 */
.sheet-modal .ai-hint{margin:2px 0 12px}
.sheet-modal #gdAnswerList{margin-bottom:4px}
.sheet-head{
  display:flex;align-items:flex-start;gap:12px;
  padding:20px 0 14px;margin-bottom:16px;
  border-bottom:1px solid var(--line-2);
}
.sh-txt{flex:1;min-width:0}
.sheet-head h3{margin:0;font-size:21px;font-weight:var(--fw65);letter-spacing:-.2px}
.sheet-head .intro{margin:3px 0 0;font-size:12px;color:var(--ink-4);line-height:1.55}
.sheet-x{
  flex:none;width:32px;height:32px;border-radius:10px;
  background:var(--surface-2);border:1px solid var(--line-2);color:var(--ink-3);
}
.sheet-x:hover{background:var(--surface-3);color:var(--ink)}
.sheet-modal .type-pick{margin-top:0}
.sheet-modal .photo-drop{margin-bottom:10px}
body.sheet-open{overflow:hidden}

/* 判卷入口卡（只在手机出现；桌面用 gd-pc 说明） */
.gd-entry{display:none}
.gd-entry-main{display:flex;align-items:center;gap:11px;margin-bottom:12px}

/* 折叠链接（我的页模型列表、手机端次级内容共用） */
.fold-more{
  display:flex;align-items:center;justify-content:space-between;gap:8px;
  width:100%;margin-top:8px;padding:9px 11px;
  background:var(--surface-2);border:1px solid var(--line-2);border-radius:var(--r-xs);
  font:inherit;font-size:12px;font-weight:var(--fw6);color:var(--ink-2);text-align:left;
  transition:border-color var(--dur),background var(--dur),color var(--dur);
}
.fold-more:hover{border-color:var(--accent-line);background:var(--surface);color:var(--ink)}
.fold-more .chev{flex:none;font-size:11px;font-weight:var(--fw6);color:var(--accent-ink)}

.toast{
  position:fixed;left:50%;bottom:calc(24px + env(safe-area-inset-bottom));
  transform:translate(-50%,10px);opacity:0;pointer-events:none;
  background:var(--toast-bg);color:var(--on-accent);border-radius:var(--r-sm);
  padding:9px 15px;font-size:13.5px;font-weight:var(--fw5);
  max-width:calc(100vw - 40px);text-align:center;z-index:120;
  transition:opacity .2s,transform .2s;
  box-shadow:var(--shadow-toast);
}
.toast.show{opacity:1;transform:translate(-50%,0)}

.ai-prog{
  position:fixed;left:50%;bottom:24px;transform:translateX(-50%);z-index:95;
  display:flex;align-items:center;gap:13px;
  padding:11px 18px 11px 12px;
  background:var(--surface);border:1px solid var(--line);
  border-radius:10px;
  box-shadow:var(--shadow-modal);
  max-width:calc(100vw - 32px);
}
.ai-prog::before{
  content:"";position:absolute;inset:-4px;border-radius:22px;pointer-events:none;
  background:linear-gradient(120deg,rgba(139,92,246,.32),rgba(34,211,238,.2));
  opacity:.22;z-index:-1;filter:blur(14px);
}
.ai-prog .ap-txt{min-width:0}
.ai-prog .ap-txt b{display:block;font-size:13.5px;font-weight:var(--fw65);color:var(--ink);line-height:1.4}
.ai-prog .ap-txt span{display:block;font-size:11px;color:var(--ink-4);margin-top:1px;line-height:1.4}

/* 三环 loader：三圈同时转、相位错开，看起来像「在搜 / 在算」而不是干等 */
.wifi-loader{
  position:relative;width:46px;height:46px;flex:none;
  display:flex;align-items:center;justify-content:center;
  --wl-front:var(--accent);
  --wl-back:var(--track);
}
.wifi-loader svg{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}
.wifi-loader circle{
  fill:none;stroke-width:6px;stroke-linecap:round;stroke-linejoin:round;
  transform:rotate(-100deg);transform-origin:center;
}
.wifi-loader circle.back{stroke:var(--wl-back)}
.wifi-loader circle.front{stroke:var(--wl-front)}
.wifi-loader .circle-outer{width:44px;height:44px}
.wifi-loader .circle-middle{width:31px;height:31px}
.wifi-loader .circle-inner{width:18px;height:18px}
.wifi-loader .circle-outer circle{stroke-dasharray:62.75 188.25}
.wifi-loader .circle-middle circle{stroke-dasharray:42.5 127.5}
.wifi-loader .circle-inner circle{stroke-dasharray:22 66}
.wifi-loader .circle-outer circle.back{animation:wlOuter 1.8s ease infinite .3s}
.wifi-loader .circle-outer circle.front{animation:wlOuter 1.8s ease infinite .15s}
.wifi-loader .circle-middle circle.back{animation:wlMiddle 1.8s ease infinite .25s}
.wifi-loader .circle-middle circle.front{animation:wlMiddle 1.8s ease infinite .1s}
.wifi-loader .circle-inner circle.back{animation:wlInner 1.8s ease infinite .2s}
.wifi-loader .circle-inner circle.front{animation:wlInner 1.8s ease infinite .05s}
.wifi-loader.sm{width:22px;height:22px}
.wifi-loader.sm .circle-outer{width:21px;height:21px}
.wifi-loader.sm .circle-middle{width:15px;height:15px}
.wifi-loader.sm .circle-inner{width:9px;height:9px}
.wifi-loader.sm circle{stroke-width:9px}

@keyframes wlOuter{
  0%{stroke-dashoffset:25} 25%{stroke-dashoffset:0}
  65%{stroke-dashoffset:301} 80%{stroke-dashoffset:276} 100%{stroke-dashoffset:276}
}
@keyframes wlMiddle{
  0%{stroke-dashoffset:17} 25%{stroke-dashoffset:0}
  65%{stroke-dashoffset:204} 80%{stroke-dashoffset:187} 100%{stroke-dashoffset:187}
}
@keyframes wlInner{
  0%{stroke-dashoffset:9} 25%{stroke-dashoffset:0}
  65%{stroke-dashoffset:106} 80%{stroke-dashoffset:97} 100%{stroke-dashoffset:97}
}

/* 行内加载提示（判卷检测模型能力这类） */
.inline-load{display:inline-flex;align-items:center;gap:8px;font-size:12px;color:var(--ink-3)}

/* ------------------------------------------------------------
   十七、手机端
   ------------------------------------------------------------ */
.mobar{display:none}

@media (max-width:900px){
  /* 顶栏与页面选择合成了一条底部胶囊：手机上不再保留顶部悬浮条，
     正文能多出整整 60px —— 一屏里最贵的就是「今天要做什么」。 */
  .appbar{display:none}

  .main{padding:0 14px calc(80px + env(safe-area-inset-bottom));max-width:none}
  .page-head{padding:16px 0 12px;gap:10px;align-items:center}
  .page-head h1{font-size:21px}
  .page-head p{font-size:12px}
  /* 手机没有「本周计划」页，今日页这两个入口是唯一能新建任务的地方 */
  .page-actions{order:3;width:100%;gap:8px;display:flex}
  body:not([data-page="today"]) .page-actions{display:none}
  .page-actions .btn{flex:1;height:36px;font-size:13.5px;border-radius:10px}

  /* 页头：标题与主操作同一行，次要入口收进「更多」 */
  .page-head{align-items:center;gap:8px}
  .page-actions{order:0;width:auto;margin-left:auto;gap:6px;display:flex}
  body:not([data-page="today"]) .page-actions{display:none}
  .page-actions .btn{flex:none;height:36px;padding:0 12px;font-size:13.5px;border-radius:10px}
  .page-actions .page-more{
    width:36px;height:36px;border:1px solid var(--line);background:var(--surface);
    border-radius:10px;color:var(--ink-3);
  }

  /* 胶囊悬浮条：一条永远可见的小胶囊 + 展开时向上浮起的页面胶囊。
     收起时不挡正文；展开用 opacity/transform 浮起，不撑高不推内容。 */
  .mobar{
    display:block;position:fixed;left:0;right:0;bottom:0;z-index:78;
    padding:0 12px calc(9px + env(safe-area-inset-bottom));
    pointer-events:none;
  }
  .mobar-wrap{position:relative;display:flex;justify-content:center}
  .mobar-pill{
    pointer-events:auto;
    display:flex;align-items:center;gap:3px;
    height:50px;padding:0 6px 0 9px;border-radius:999px;
    background-color:var(--glass-a);
    background-image:none;
    border:1px solid var(--glass-line);
    -webkit-backdrop-filter:none;
    backdrop-filter:none;
    box-shadow:0 1px 0 var(--glass-hi) inset,0 16px 34px -18px rgba(10,14,22,.55);
  }
  .mobar-logo{
    display:inline-flex;align-items:center;justify-content:center;flex:none;
    width:30px;height:30px;border-radius:10px;
    background:linear-gradient(150deg,#1b2540 0%,#080d17 100%);
    border:1px solid rgba(255,255,255,.11);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.13);
  }
  /* 页面图标行：底栏只有这一排（没有「先展开再选」的第二层），
     具体排布在文件末尾的手机底栏段落里统一给 */
  .mobar-nav{display:flex;align-items:center}
  .mobar-nav button{
    position:relative;z-index:1;background:transparent;
    display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;
    padding:6px 1px;min-height:50px;border-radius:10px;
    color:var(--ink-4);font-size:11px;font-weight:var(--fw6);
    transition:color var(--dur);
  }
  .mobar-nav button svg{width:19px;height:19px}
  .mobar-nav button.on{color:var(--accent-ink)}
  .mobar-user{display:inline-flex;align-items:center;justify-content:center;
    width:32px;height:32px;border-radius:999px;flex:none;padding:0;
    border:1px solid var(--line);background:var(--surface)}
  .mobar-user .av.av-sm{width:26px;height:26px;font-size:11px;border:0}
  .mobar-login{
    height:32px;padding:0 12px;border-radius:999px;flex:none;
    font-size:12px;font-weight:var(--fw6);color:var(--accent-ink);
    background:var(--accent-soft);border:1px solid var(--accent-line);
  }
  .card{padding:13px 14px;border-radius:var(--r-sm);margin-bottom:10px}
  .quiet-card{padding:12px 13px;margin-bottom:10px}
  .wk-card{padding:14px 15px}
  .form-2col,.field-2{grid-template-columns:1fr}
  /* 提示条 / AI 进度也抬到底栏胶囊之上，别被那一条挡住 */
  .toast{bottom:calc(74px + env(safe-area-inset-bottom))}
  .ai-prog{bottom:calc(74px + env(safe-area-inset-bottom));left:12px;right:12px;transform:none;max-width:none}

  /* 分栏只剩一栏：录入搬到浮层，页面本身只有列表与详情 */
  .split{grid-template-columns:1fr}
  /* 底栏胶囊高 50 + 下方 9px 留白（约 59~64px）：向上让位的数值必须大于它，
     否则「传题 / 记成绩」这颗悬浮按钮会被底栏压住一半（实测曾重叠 18px） */
  .split-add{
    display:flex;align-items:center;gap:6px;
    position:fixed;right:16px;bottom:calc(80px + env(safe-area-inset-bottom));z-index:75;
    background:var(--accent);color:var(--on-accent);border:0;border-radius:999px;
    padding:0 18px;height:44px;font-size:13.5px;font-weight:var(--fw65);
    box-shadow:var(--shadow-toast);
  }

  /* 计划页：竖屏只保留「今天」的可用性靠今日页，表格横向滚动 */
  .ph-stats{grid-template-columns:repeat(3,1fr);row-gap:12px}
  .ph-stat:nth-child(4){border-left:0}
  /* 卡标题里有按钮时，说明文字让位，标题不被挤成两行 */
  .card-title{flex-wrap:wrap}
  .card-title .spacer{display:none}
  .card-title .btn{margin-left:auto}
  .stage-row{grid-template-columns:22px minmax(0,1fr);gap:7px 10px}
  .sr-prog,.sr-acts{grid-column:1 / -1}
  .sr-acts{justify-content:flex-end}
  .pb-actions{width:100%}
  .pb-actions .btn{flex:1}
  .pb-hint{order:3;flex-basis:100%}

  .wh-top{margin-bottom:12px}
  .wk-score{font-size:32px}
  .wk-kpis{grid-template-columns:repeat(3,1fr);row-gap:12px}
  .wk-kpi{padding:0 8px}
  .wk-kpi:nth-child(4){border-left:0}
  .wk-kpi b{font-size:21px}
  .wk-chart{height:130px;gap:5px}
  .wk-bar{max-width:34px}
  .wk-card{padding:14px 15px}
  .heat-grid{grid-template-columns:repeat(14,1fr);max-width:none}

  .bd-stats{grid-template-columns:1fr 1fr}
  .bd-bar-row{grid-template-columns:56px minmax(0,1fr) 44px}
  .bh-stats{grid-template-columns:repeat(3,1fr);row-gap:12px}
  .bh-item:nth-child(4){border-left:0}

  .gd-pc-steps{flex-direction:column;gap:5px}

  .set-board{grid-template-columns:minmax(0,1fr)}
  .set-col + .set-col{border-left:0;border-top:1px solid var(--line)}
  .set-sec{padding:12px 0 2px}
  .set-title{padding:0 14px 6px}
  .set-row{padding:11px 14px}
  /* 手机固定底栏，「导航位置：顶部 / 左侧」在这里没有效果，别摆一个点了没反应的开关 */
  .dock-row{display:none}
  .pf-card{padding:15px}
  .set-row{padding:10px 12px;font-size:13.5px}

  /* 浮层：贴底升起，顶部圆角。这样拇指够得着，也不挡输入法 */
  .modal-mask{align-items:flex-end;padding:0;overflow:hidden}
  .modal{
    border-radius:20px 20px 0 0;max-width:none;width:100%;max-height:92vh;
    padding:0 16px calc(16px + env(safe-area-inset-bottom));
    animation:sheetUp .3s cubic-bezier(.23,1,.32,1) both;
  }
  @keyframes sheetUp{from{transform:translateY(26px);opacity:.5}to{transform:none;opacity:1}}
  .sheet-modal{padding:0 16px calc(16px + env(safe-area-inset-bottom))}
  .sheet-head{padding:16px 0 12px;margin-bottom:14px}
  .sheet-head h3{font-size:15px}
  .sheet-modal input,.sheet-modal select{height:42px;font-size:13.5px}
  /* 登录页在手机上贴顶排：上下那两段「什么也没有」的留白直接去掉，
     卡片顶到第一屏里，键盘弹起来也还看得见输入框。 */
  .gate{
    margin:0;min-height:100vh;justify-content:flex-start;
    padding:12px 14px calc(14px + env(safe-area-inset-bottom));
  }
  .gate-top{margin-bottom:10px}
  .gate-card{max-width:none;padding:22px 18px 20px;border-radius:22px}
  .gb-mark{width:46px;height:46px;border-radius:10px;margin-bottom:10px}
  .gate-head{margin-bottom:14px}
  .gate-head h2{font-size:21px}
  .gb-sub{margin-top:4px}
  .gate .seg{margin-bottom:14px}
  .gate .form-row{margin-bottom:10px}
  .gd-entry{display:block}
  .gd-entry .btn-block{height:42px}
}
@media (max-width:420px){
  .wk-kpis{grid-template-columns:1fr 1fr}
  .wk-kpi:nth-child(odd){border-left:0}
  .td-hero-nums b{font-size:21px}
  .td-hero-nums b.sm{font-size:13.5px}
}

/* ------------------------------------------------------------
   十八、电脑端：只留查看，一切需要拍照 / 录入的入口都收在手机
   ------------------------------------------------------------ */
@media (min-width:901px){
  /* 电脑端不提供拍照上传：浮层里的照片区与「AI 认题」一起收起，
     手工录入照常可用 —— 输入在浮层里，只是没有相机那一段。 */
  .split{grid-template-columns:minmax(0,1fr)}
  .photo-drop,.photo-thumbs,.pa-photo-row,.nb-photo-btn{display:none !important}
  .pc-note{display:block}
  .gd-entry{display:none !important}
}

/* ------------------------------------------------------------
   十九、打印：只打印计划表本身
   ------------------------------------------------------------ */
@media print{
  .appbar,.mobar,.page-actions,.split-add,.pb-actions,.pb-head,.pool,
  .toast,.ai-prog,.sync-pill,.theme-btn,.modal-mask,#errBanner,.mini-btn{display:none !important}
  html,body{background:#fff}
  .main{padding:0;max-width:none}
  .panel{display:none !important}
  .panel.active{display:block !important}
  /* 周计划页只留表格：总体卡、长期规划、待办池都不上台面 */
  body[data-page="board"] #panel-board>#boardSummary,
  body[data-page="board"] #panel-board>#boardLong{display:none !important}
  .print-only{display:block;font-size:13.5px;font-weight:var(--fw7);color:#000;margin:0 0 8px}
  #boardPlan>.card{border:0;box-shadow:none;padding:0;background:#fff}
  .grid-scroll{overflow:visible}
  .plan-grid{min-width:0;table-layout:auto}
  .card,.wk-card,.plan-hero{border-color:#c9cdd6 !important;box-shadow:none !important}
  .plan-grid th,.plan-grid td{border-color:#c9cdd6 !important}
  .pblock,.stage-row,.sub-row{break-inside:avoid;page-break-inside:avoid}
  /* 四象限色是计划表的语义，必须打进纸里（默认会被浏览器省掉背景色） */
  .pblock,th,td,.slot-col{-webkit-print-color-adjust:exact;print-color-adjust:exact}
}

/* 切主题的过渡
   ------------------------------------------------------------
   只让「颜色类」属性参与，并且全站统一时长、统一缓动、同一时刻开始。
   之所以以前是「一刀切关掉过渡」，是因为组件各自带着 .15s / .3s 的过渡，
   底色会瞬变而按钮慢慢爬 → 看着像按钮慢半拍。统一时长就解决了这个不同步。
   transform 等布局/运动属性刻意不参与，否则 hover 上浮会被拖成 0.32s。 */
html.theme-fading *,
html.theme-fading *::before,
html.theme-fading *::after{
  transition-property:background-color,border-color,color,fill,stroke,box-shadow,outline-color !important;
  transition-duration:.32s !important;
  transition-timing-function:cubic-bezier(.4,0,.2,1) !important;
  transition-delay:0s !important;
}
@media (prefers-reduced-motion: reduce){
  html.theme-fading *,html.theme-fading *::before,html.theme-fading *::after{
    transition-duration:0s !important;
  }
}

/* [hidden] 必须真正隐藏：UA 的 display:none 会被任何作者样式的 display 覆盖 */
/* ============================================================
   V3.1.0 · 游客模式 / 手机版体验 / 开发者备忘录
   ============================================================ */

/* ---------- 登录页的游客入口 ---------- */
.gate-guest{margin-top:16px}
.gate-or{display:flex;align-items:center;gap:10px;margin:0 0 12px;color:var(--ink-4);font-size:11px}
.gate-or::before,.gate-or::after{content:"";flex:1;height:1px;background:var(--line)}
.gate-link{
  display:block;width:100%;margin-top:10px;padding:6px 0;
  border:0;background:transparent;color:var(--accent);cursor:pointer;
  font:inherit;font-size:12px;font-weight:var(--fw6);
}
.gate-link:hover{text-decoration:underline}

/* ---------- 顶栏：模式标记 ---------- */
.guest-pill{
  flex:none;font-size:11px;font-weight:var(--fw65);padding:3px 9px;border-radius:999px;
  background:var(--accent-soft);color:var(--accent-ink);border:1px solid var(--accent-line);
  white-space:nowrap;cursor:pointer;
}
.guest-pill:hover{background:var(--accent-line)}

/* ---------- 我的页：改名区（名字只是名字，不再兼开发者入口） ---------- */
.pf-edit-wrap{min-width:0;flex:1}

/* ---------- 开发者备忘录 ---------- */
.dev-card{margin-top:14px;border:1px dashed var(--accent-line)}
.dev-grid{display:grid;grid-template-columns:1fr 1fr;grid-gap:12px;gap:12px}
.dev-col{background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);padding:11px 12px}
.dev-col-head{
  display:flex;align-items:center;gap:7px;
  font-size:12px;font-weight:var(--fw7);color:var(--ink-2);margin-bottom:8px;
}
.dev-col-head b{
  min-width:17px;height:17px;padding:0 5px;border-radius:7px;
  background:var(--accent-soft);color:var(--accent-ink);
  font-size:11px;line-height:17px;text-align:center;
}
.dev-list{list-style:none;margin:0 0 8px;padding:0;display:flex;flex-direction:column;gap:5px}
.dev-item{
  display:flex;align-items:flex-start;gap:6px;
  background:var(--card);border:1px solid var(--line);border-radius:7px;
  padding:7px 8px;
}
.dev-txt{flex:1;min-width:0;font-size:12px;line-height:1.55;color:var(--ink);word-break:break-word}
.dev-del{flex:none;width:22px;height:22px;opacity:.35}
.dev-item:hover .dev-del{opacity:.8}
.dev-empty{font-size:12px;color:var(--ink-4);padding:6px 2px 8px}
.dev-add{display:flex;gap:6px}
.dev-input{
  flex:1;min-width:0;height:30px;padding:0 9px;font:inherit;font-size:12px;
  color:var(--ink);background:var(--card);
  border:1px solid var(--line);border-radius:7px;
}
.dev-input:focus{outline:none;border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-soft)}
.dev-add .btn{flex:none;height:30px;padding:0 10px;font-size:12px}
.dev-foot{margin-top:10px;font-size:11px;color:var(--ink-4);line-height:1.6}

/* ---------- 演示模式的固定结论 ---------- */
.ai-demo{
  border-left:3px solid var(--accent-line);
  margin-bottom:14px;
}
.ai-demo .card-title{gap:7px}
.ai-demo .card-title svg{color:var(--ico);flex:none}
.ai-demo-body{margin-top:8px}
.ai-demo-body p{
  margin:0 0 9px;font-size:13.5px;line-height:1.75;color:var(--ink-2);
  text-align:justify;
}
.ai-demo-body p:last-child{margin-bottom:0}
.ai-off-note{
  font-size:12px;line-height:1.7;color:var(--ink-3);
  background:var(--surface-2);border-radius:var(--r-sm);padding:10px 12px;
}

/* ---------- 手机端：不显示模式胶囊以外的装饰 ---------- */
@media (max-width:900px){
  .dev-grid{grid-template-columns:1fr}
}
@media (max-width:900px) and (min-width:0px){
  .guest-pill{font-size:11px;padding:2px 7px}
}


/* ================= 容器适配：小红书小工具 / 旧内核基线 =================
   ① 看图、复制：容器禁 window.open 与剪贴板，改成站内遮罩与可选文本；
   ② 安全区：容器通过 JS 注入 --host-*，没有容器时这几条规则整体不生效；
   ③ Flex gap：Chrome 61 认识 gap 属性但 Flex 里不生效，靠 host.js 的实际布局
      检测挂 html.no-flex-gap，下面这批规则把 gap 换成子项单边 margin（基线层）。
      检测到支持时类名不挂，规则全部不生效，现代内核看到的还是 gap。 */

/* ---- ① 看图 ---- */
.zoom-mask{position:fixed;top:0;right:0;bottom:0;left:0;z-index:130;display:none;
  align-items:center;justify-content:center;background:rgba(10,12,18,.88);padding:14px}
.zoom-mask.show{display:flex}
.zoom-img{max-width:100%;max-height:100%;border-radius:var(--r-sm)}

/* ---- ① 复制（容器禁剪贴板） ---- */
.copy-mask{position:fixed;top:0;right:0;bottom:0;left:0;z-index:130;display:none;
  align-items:center;justify-content:center;background:rgba(10,12,18,.55);padding:18px}
.copy-mask.show{display:flex}
.copy-card{width:100%;max-width:560px;background:var(--surface);border-radius:var(--r);padding:16px}
.copy-head{font-size:13.5px;font-weight:var(--fw65);color:var(--ink);margin-bottom:9px}
.copy-area{width:100%;height:190px;resize:none;border:1px solid var(--line);border-radius:var(--r-sm);
  padding:10px;font-size:13.5px;line-height:1.6;color:var(--ink-2);background:var(--surface-2);
  font-family:inherit;-webkit-user-select:text;user-select:text}
.copy-foot{display:flex;align-items:center;justify-content:space-between;margin-top:10px}

/* ---- ② 安全区（仅容器内生效） ---- */
body.in-xhs .main{padding-top:var(--host-top,0px)}
body.in-xhs .appbar-in{padding-top:calc(10px + var(--host-top,0px));padding-right:calc(32px + var(--host-right,0px))}
@media (max-width:900px){
  body.in-xhs .main{padding-bottom:calc(80px + var(--host-bottom, env(safe-area-inset-bottom, 0px)))}
  body.in-xhs .appbar-in{padding-top:calc(8px + var(--host-top,0px));padding-right:calc(14px + var(--host-right,0px))}
  body.in-xhs .mobar{padding-bottom:calc(9px + var(--host-bottom, env(safe-area-inset-bottom, 0px)))}
  body.in-xhs .toast{bottom:calc(40px + var(--host-bottom, env(safe-area-inset-bottom, 0px)))}
  /* 计划表在窄屏要靠惯性滚动才顺手 */
  .grid-scroll{-webkit-overflow-scrolling:touch}
}

/* ---- ③ Flex gap 基线（html.no-flex-gap 时生效） ---- */
html.no-flex-gap .ai-prog > * + *{margin-left:8px}
html.no-flex-gap .bd-legend > * + *{margin-left:14px}
html.no-flex-gap .bd-list > * + *{margin-top:6px}
html.no-flex-gap .bh-title > * + *{margin-left:7px}
html.no-flex-gap .brand > * + *{margin-left:9px}
html.no-flex-gap .card-title > * + *{margin-left:8px}
html.no-flex-gap .collapse-head > * + *{margin-left:10px}
html.no-flex-gap .dev-col-head > * + *{margin-left:7px}
html.no-flex-gap .dev-item > * + *{margin-left:6px}
html.no-flex-gap .ds-top > * + *{margin-left:7px}
html.no-flex-gap .due-item > * + *{margin-left:8px}
html.no-flex-gap .field > * + *{margin-top:5px}
html.no-flex-gap .gate-or > * + *{margin-left:10px}
html.no-flex-gap .gd-ans-row > * + *{margin-left:8px}
html.no-flex-gap .gd-answer > * + *{margin-left:8px}
html.no-flex-gap .gd-head > * + *{margin-left:8px}
html.no-flex-gap .gd-hrow > * + *{margin-left:10px}
html.no-flex-gap .gd-pc-state > * + *{margin-left:7px}
html.no-flex-gap .gd-pc-steps > * + *{margin-left:8px}
html.no-flex-gap .gd-pc-steps li > * + *{margin-left:6px}
html.no-flex-gap .kv > * + *{margin-left:10px}
html.no-flex-gap .modal-actions > * + *{margin-left:8px}
html.no-flex-gap .nav button > * + *{margin-left:7px}
html.no-flex-gap .nb-actions > * + *{margin-left:8px}
html.no-flex-gap .nb-mastery > * + *{margin-left:8px}
html.no-flex-gap .nb-top > * + *{margin-left:7px}
html.no-flex-gap .pa-sc > * + *{margin-left:3px}
html.no-flex-gap .pa-title > * + *{margin-left:6px}
html.no-flex-gap .page-head > * + *{margin-left:10px}
html.no-flex-gap .pb-actions > * + *{margin-left:6px}
html.no-flex-gap .pb-title > * + *{margin-left:8px}
html.no-flex-gap .pblock-meta > * + *{margin-left:4px}
html.no-flex-gap .pf-edit > * + *{margin-left:6px}
html.no-flex-gap .pool-done > * + *{margin-top:1px}
html.no-flex-gap .pool-head > * + *{margin-left:8px}
html.no-flex-gap .pool-row > * + *{margin-left:6px}
html.no-flex-gap .score-line > * + *{margin-left:8px}
html.no-flex-gap .seg > * + *{margin-left:2px}
html.no-flex-gap .set-row > * + *{margin-left:12px}
html.no-flex-gap .appbar-in > * + *{margin-left:18px}
html.no-flex-gap .user-chip > * + *{margin-left:8px}
html.no-flex-gap .slot-list > * + *{margin-top:3px}
html.no-flex-gap .split-head > * + *{margin-left:8px}
/* 搜索框同样靠 gap 排版。只给输入框补左边距：清空按钮与圆形按钮是绝对定位，
   给它们加 margin 会把位置推歪。 */
html.no-flex-gap .search-input{margin-left:9px}
html.no-flex-gap .sr-acts > * + *{margin-left:6px}
html.no-flex-gap .sub-row > * + *{margin-left:8px}
html.no-flex-gap .td-done-btn > * + *{margin-left:6px}
html.no-flex-gap .ov-head > * + *{margin-left:10px}
html.no-flex-gap .pm-row > * + *{margin-left:9px}
html.no-flex-gap .td-row > * + *{margin-left:10px}
html.no-flex-gap .wh-nav > * + *{margin-left:8px}
html.no-flex-gap .wh-score > * + *{margin-left:10px}
html.no-flex-gap .wh-top > * + *{margin-left:14px}
html.no-flex-gap .wk-legend > * + *{margin-left:14px}

/* ==================== V5 积分体系 ==================== */

/* 积分页主题族：金色（钱的感觉），与周报的橙拉开距离 */
body[data-page="points"]{
  --accent:#ca8a04; --accent-2:#eab308; --accent-ink:#a16207;
  --accent-soft:#fdf7e3; --accent-glide:#faf0c8; --accent-line:#f0e2a4;
  /* 渐变两端都要压得住白字：最亮端 #a16207 对白字 4.84:1 */
  --accent-grad:linear-gradient(135deg,#8a5a06 0%,#a16207 100%);
  --fog-a:rgba(202,138,4,.13); --fog-b:rgba(234,179,8,.11);
  --glow:rgba(202,138,4,.42); --aura:rgba(234,179,8,.12);
  --accent-wash:rgba(202,138,4,.07);
}
html[data-theme="dark"] body[data-page="points"]{
  --accent:#fde047; --accent-2:#facc15; --accent-ink:#fef3b0;
  --accent-soft:rgba(234,179,8,.15); --accent-glide:rgba(250,204,21,.18); --accent-line:rgba(253,224,71,.28);
  --accent-grad:linear-gradient(135deg,#eab308 0%,#fde047 100%);
  --fog-a:rgba(250,204,21,.06); --fog-b:rgba(253,224,71,.04);
  --glow:rgba(250,204,21,.4); --aura:rgba(250,204,21,.08);
  --accent-wash:rgba(250,204,21,.07);
}

/* ---- 余额卡：余额 → 门槛进度 → 三个数字，一屏读完 ---- */
.pt-hero{position:relative}
.pt-head{display:flex;align-items:flex-start;gap:12px}
.pt-balance{display:flex;align-items:baseline;gap:8px;min-width:0}
.pt-num{font-size:32px;font-weight:var(--fw7);color:var(--ink);letter-spacing:-1px;line-height:1;font-variant-numeric:tabular-nums}
.pt-unit{font-size:12px;color:var(--ink-3);white-space:nowrap}
.pt-head .ph-chip{margin-left:auto;flex:none}
.pt-track{height:4px;border-radius:7px;background:var(--track);overflow:hidden;margin:16px 0 7px}
.pt-track i{display:block;height:100%;border-radius:7px;background:var(--accent)}
.pt-scale{display:flex;justify-content:space-between;gap:12px;font-size:11px;color:var(--ink-4)}
.pt-kpis{display:flex;margin-top:16px;padding-top:14px;border-top:1px solid var(--line-2)}
.pt-kpi{flex:1;min-width:0}
.pt-kpi + .pt-kpi{border-left:1px solid var(--line-2);padding-left:14px;margin-left:14px}
.pt-kpi b{display:block;font-size:21px;font-weight:var(--fw7);color:var(--ink);font-variant-numeric:tabular-nums}
.pt-kpi span{display:block;font-size:11px;color:var(--ink-3);margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.pt-cta{width:100%;margin-top:14px}

/* ---- 结算卡 ---- */
.pt-settle .card-title{margin-bottom:10px}
.pt-settle.is-done{border-color:var(--green-line)}
.pt-settle.is-done .card-title{color:var(--green)}
.pt-settle-grid{display:flex;gap:10px;flex-wrap:wrap}
.pt-set-cell{
  flex:1;min-width:100px;background:var(--inset);border:1px solid var(--inset-line);
  border-radius:var(--r-sm);padding:10px 12px;text-align:center;
}
.pt-set-cell b{display:block;font-size:21px;font-weight:var(--fw7);color:var(--ink)}
.pt-set-cell span{font-size:11px;color:var(--ink-3)}
.pt-set-note{margin:12px 0;font-size:13.5px;line-height:1.7;color:var(--ink-2)}

/* ---- 明细 ---- */
.pt-list{margin-top:4px}
.pt-row{
  display:flex;align-items:center;gap:10px;padding:9px 2px;
  border-bottom:1px solid var(--line-2);
}
.pt-row:last-child{border-bottom:0}
.pt-dot{flex:none;width:8px;height:8px;border-radius:50%;background:var(--ink-4)}
.pt-dot.up{background:var(--green)}
.pt-dot.down{background:var(--red)}
.pt-main{flex:1;min-width:0}
.pt-main b{font-size:13.5px;font-weight:var(--fw6);color:var(--ink)}
.pt-main span{display:block;font-size:12px;color:var(--ink-3);margin-top:1px;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pt-main time{display:block;font-size:11px;color:var(--ink-4);margin-top:1px}
.pt-amt{flex:none;font-size:13.5px;font-weight:var(--fw7)}
.pt-amt.up{color:var(--green)}
.pt-amt.down{color:var(--red)}

/* ---- 提案 ---- */
.pt-proposal-form{display:flex;flex-direction:column;gap:8px;align-items:flex-start}
.pt-proposal-form textarea{width:100%}
.pt-proposals{margin-top:10px;display:flex;flex-direction:column;gap:8px}
.pt-proposal{background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);padding:10px 12px}
.pt-proposal.adopted{opacity:.75}
.pt-proposal p{margin:0;font-size:13.5px;line-height:1.6;color:var(--ink)}
.pt-proposal-foot{display:flex;align-items:center;gap:8px;margin-top:7px}
.pt-proposal-foot time{font-size:11px;color:var(--ink-4)}
.pt-proposal-foot .mini-btn{margin-left:auto}
.pt-proposal-tag{font-size:11px;font-weight:var(--fw6);color:var(--green)}

/* ---- 检查模式进度条 ---- */
.ck-progress{
  position:relative;height:22px;border-radius:999px;background:var(--red-bg);
  margin:2px 0 12px;overflow:hidden;
}
.ck-progress i{
  position:absolute;top:0;left:0;bottom:0;border-radius:999px;
  background:var(--green);opacity:.28;transition:width .3s;
}
.ck-progress span{
  position:relative;z-index:1;display:flex;align-items:center;justify-content:center;
  height:100%;font-size:12px;font-weight:var(--fw6);color:var(--ink-2);
}

/* ---- 检查弹窗：三个去处 ---- */
.ck-title{margin-bottom:2px}
.ck-choices{display:flex;gap:9px;margin-top:14px}
.ck-choice{
  flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;
  min-height:74px;border-radius:var(--r);border:1px solid var(--line);
  background:var(--surface-2);color:var(--ink);cursor:pointer;
  transition:border-color var(--dur),background var(--dur),transform .1s;
}
.ck-choice:hover{border-color:var(--accent-line);background:var(--accent-soft);transform:translateY(-1px)}
.ck-choice b{font-size:13.5px;font-weight:var(--fw6)}
.ck-choice span{font-size:11px;color:var(--ink-3)}
.ck-choice.ok{min-height:74px;width:74px;flex:none}
.ck-choice.ok svg{width:20px;height:20px;color:var(--green)}
.ck-choice.warn:hover{border-color:var(--red-line);background:var(--red-bg)}

/* ---- 周总结 + 周加分 ---- */
.wk-sum-card{border-color:var(--green-line)}
.wk-sum-grid{display:flex;gap:10px;flex-wrap:wrap;margin-bottom:14px}
.wk-sum-cell{
  flex:1;min-width:100px;background:var(--inset);border:1px solid var(--inset-line);
  border-radius:var(--r-sm);padding:10px 12px;text-align:center;
}
.wk-sum-cell b{display:block;font-size:21px;font-weight:var(--fw7);color:var(--ink)}
.wk-sum-cell span{font-size:11px;color:var(--ink-3)}
.wk-bonus{background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);padding:12px 14px}
.wk-bonus-head{font-size:13.5px;font-weight:var(--fw6);color:var(--ink);margin-bottom:9px}
.wk-bonus-head span{font-weight:var(--fw4);font-size:12px;color:var(--ink-3);margin-left:6px}
.wk-bonus-row{display:flex;gap:8px}
.wk-bonus-row .input{flex:1}
.wk-bonus-hint{display:block;margin-top:8px;font-size:11px;color:var(--ink-4)}

/* ---- 试卷页 · 积分规则（电脑端） ---- */
.pa-rules .pr-head{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-bottom:10px}
.pa-rules .pr-head .seg{margin-bottom:0;min-width:150px}
.pr-subs{display:flex;gap:5px;flex-wrap:wrap}
.pr-sub{
  border:1px solid var(--line);background:var(--surface-2);border-radius:999px;
  padding:4px 11px;font-size:12px;font-weight:var(--fw5);color:var(--ink-3);cursor:pointer;
  transition:all var(--dur);
}
.pr-sub:hover{color:var(--ink)}
.pr-sub.on{background:var(--accent-soft);border-color:var(--accent-line);color:var(--accent-ink)}
.pr-rows{display:flex;flex-direction:column;gap:7px}
.pr-row{
  display:flex;align-items:center;gap:11px;background:var(--inset);
  border:1px solid var(--inset-line);border-radius:var(--r-sm);padding:7px 12px;
}
.pr-idx{
  flex:none;width:20px;height:20px;border-radius:7px;text-align:center;line-height:19px;
  font-size:11px;font-weight:var(--fw7);color:var(--ink-3);
  background:var(--surface);border:1px solid var(--line);
}
/* 一档一行、只调上限：左边是档位区间，中间一条滑块，右边是多少分 */
.pr-band{display:flex;align-items:center;gap:10px;flex:1;min-width:0}
.pr-range{flex:none;min-width:92px;font-size:12px;font-weight:var(--fw6);color:var(--ink);font-variant-numeric:tabular-nums}
.pr-band input[type="range"]{flex:1;min-width:70px;accent-color:var(--accent);height:18px}
.pr-band input[type="range"]:disabled{opacity:.35}
.pr-pts{display:flex;align-items:center;gap:5px;flex:none}
.pr-pts .input{width:64px;text-align:center;padding:5px 6px}
.pr-pts span{font-size:11px;color:var(--ink-3)}
.pr-foot{display:flex;align-items:center;gap:9px;margin-top:11px;flex-wrap:wrap}
@media (max-width:900px){
  .pa-rules{display:none}   /* 规则区只放电脑端，手机改用默认档 */
}

/* ---- 错题页 · 一个月没传的提醒 ---- */
.nb-nag{
  display:flex;align-items:center;gap:12px;margin-bottom:12px;
  border-color:var(--red-line);background:var(--red-bg);
}
.nb-nag-main{flex:1;min-width:0}
.nb-nag-main b{display:block;font-size:13.5px;font-weight:var(--fw6);color:var(--red)}
.nb-nag-main span{font-size:12px;color:var(--ink-2)}
.nb-nag-acts{display:flex;gap:7px;flex:none}

@media (max-width:900px){
  .pt-num{font-size:32px}
  .ck-choices{flex-direction:column}
  .ck-choice{min-height:56px;flex-direction:row;justify-content:flex-start;gap:10px;padding:0 14px}
  .ck-choice.ok{width:100%;min-height:56px;justify-content:center}
  .ck-choice span{margin-left:auto}
  .nb-nag{flex-direction:column;align-items:stretch}
  .nb-nag-acts{justify-content:flex-end}
}

[hidden]{display:none !important}

/* 尊重系统的「减少动态效果」 */
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{animation-duration:.001s !important;transition-duration:.001s !important}
}

/* ------------------------------------------------------------
   二十、宽屏 / 全屏：把内容铺开
   ------------------------------------------------------------
   笔记本外接显示器或按 F11 之后，1160px 的窄列会让两侧空出大片留白，
   卡片也只能一张一张往下排。这里按视口宽度铺开：先放宽容器，
   再把「一条一条」的列表改成 2 列、超宽屏 3 列。
   ⚠️ 列表项是等高的行（错题 / 试卷 / 今日任务），才适合做流式多列；
      图表、四象限、计划表这类有固定形状的块一律不掺和。 */
/* 全屏双栏：断点按「全屏后的真实视口」定，不是按显示器尺寸。
   1280×720 的笔记本全屏后视口约 1264，原来卡在 1440 断点外面 ——
   所以用户点了全屏却还是单列。这里 1200 就双栏，1560 放宽容器。 */
@media (min-width:1200px){
  /* 全屏 = 把宽度用起来。但「小屏电脑」和「2K/4K」要分开对待：
     1280~1536 的笔记本本来就没多少横向空间，再按 8vw 留白等于白扔掉
     100px 内容宽度 —— 用户的原话是「小屏的电脑，屏幕两侧不必留空间」。
     所以 1200 起只留 32px，1560 以上才按视口比例留白。 */
  .main{max-width:none;padding:0 32px 72px}
  html[data-dock="left"] .main{padding-left:32px}
  .wk-kpis{gap:0}
}
@media (min-width:1560px){
  .main{padding:0 clamp(40px,8vw,320px) 72px}
  /* 左侧贴靠时扣掉 88px 竖条，左右视觉留白才相等 */
  html[data-dock="left"] .main{padding-left:clamp(20px,calc(8vw - 84px),240px)}
}

/* ============================================================
   二十一、Beta4.coming soon · 登录改版 / 手机底栏 / 提示与引导
   ============================================================ */

/* ---------- 登录卡：LOGO 与底板一起缩放 ---------- */
/* 以前是「52px 底板 + 28px 定死图标」，换到大卡片上像贴了一张小贴纸。
   现在图标吃满容器（留 9px 内边距），方块多大环就多大。 */
.gb-mark{padding:9px}
.gb-mark svg{width:100%;height:100%;display:block}

/* ---------- 登录页：选项行与备选入口 ---------- */
.gate-links{
  display:flex;align-items:center;justify-content:center;gap:8px;
  margin:14px 0 0;font-size:12px;color:var(--ink-4);
}
.gate-links i{font-style:normal;opacity:.5}
.link-btn{
  background:none;border:0;padding:2px 0;font:inherit;font-size:12px;
  color:var(--accent-ink);font-weight:var(--fw6);cursor:pointer;
  transition:opacity var(--dur);
}
.link-btn:hover{text-decoration:underline}
.gate-alt{margin:12px 0 0;text-align:center;font-size:12px;color:var(--ink-4);line-height:1.7}
/* 注册的密码 / 确认密码并排：两栏各 6 位，并排不会挤 */
.gate .form-2col{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px}
.gate .form-2col .form-row{margin-bottom:12px}
@media (max-width:430px){.gate .form-2col{grid-template-columns:minmax(0,1fr)}}

/* ---------- 品牌标记：极简层与完整层同一款 ---------- */
/* 「收起后 LOGO 变成一个圆圈」是因为极简层只画了那一笔，没有环。
   现在两层共用完整形态，只缩尺寸，形状不变。 */
.brand-badge{overflow:hidden}
.brand-badge svg{display:block}
.brand-badge.mini{width:28px;height:28px;border-radius:7px;padding:4px}
.bar-full .brand-badge{padding:5px}

/* ---------- 手机底栏：一排常驻图标，不分两级 ---------- */
@media (max-width:900px){
  .mobar{padding:0 10px calc(8px + env(safe-area-inset-bottom))}
  .mobar-pill{
    width:100%;max-width:none;height:56px;
    gap:0;padding:0 7px;justify-content:space-between;
  }
  .mobar-logo{width:26px;height:26px;padding:3px;border-radius:7px}
  .mobar-logo svg{width:100%;height:100%}
  /* 页面图标直接铺开：不再等用户点开一层 */
  .mobar-nav{
    position:static;flex:1;min-width:0;
    display:flex;align-items:center;justify-content:center;
    gap:0;padding:0;border:0;border-radius:0;
    background:none;box-shadow:none;
    -webkit-backdrop-filter:none;backdrop-filter:none;
    opacity:1;transform:none;pointer-events:auto;transition:none;
  }
  .mobar-nav .nav-glider{display:none}
  /* 固定一格：之前 flex:1 均分整条，屏幕一宽图标就被拉得很散。
     40px 格配 20px 图标，等于每边留 10px 空白、相邻图标边缘还差 20px，
     看着就是一排稀稀拉拉的图标。收到 34px 格 + 22px 图标：
     边缘间距 12px，视觉上连成一组而不是散在一条线上。 */
  .mobar-nav button{
    flex:0 0 34px;min-width:0;
    height:40px;min-height:0;padding:0;gap:0;border-radius:8px;
    color:var(--ink-3);
  }
  .mobar-nav button svg{width:22px;height:22px}
  /* 极简：只留图标。底栏空间要留给「五个页面都能一指点到」 */
  .mobar-nav button span{display:none}
  .mobar-nav button:hover{background:transparent}
  .mobar-nav button.on{color:var(--accent-ink);background:var(--accent-soft)}
  .mobar-sep{width:1px;height:20px;margin:0 3px;background:var(--line);flex:none}
  @media (max-width:360px){.mobar-logo{display:none}}
  /* 底栏贴着屏幕下沿：气泡只能朝上弹，否则整块出屏 */
  .mobar [data-tip]:hover::after{top:auto;bottom:calc(100% + 8px)}
  .mobar [data-tip]:hover::before{display:none}
}

/* ---------- 切主题：手机上不做逐元素过渡 ---------- */
/* 全站 600+ 节点同时过渡 background-color / box-shadow，手机上会掉到个位数帧率，
   看起来就是「卡成 PPT」。手机只让页面底色做一次短过渡，其余直接换。 */
@media (max-width:900px),(pointer:coarse){
  html.theme-fading *,
  html.theme-fading *::before,
  html.theme-fading *::after{transition:none !important}
  html.theme-fading{transition:background-color .16s linear !important}
}

/* ---------- 新手导览：聚光灯挖洞 + 指到控件上的气泡 ---------- */
/* 以前是一张居中的说明卡，讲完用户还得自己去屏幕上找对应的按钮。
   现在洞挖在控件上、气泡贴着它，箭头指着它 —— 文字和位置是同一件事。 */
.tour{position:fixed;inset:0;z-index:92;display:none}
.tour.show{display:block}
.tour-hole{
  position:fixed;left:-999px;top:-999px;width:0;height:0;
  border-radius:12px;pointer-events:none;
  /* 一圈超大的外阴影把屏幕铺暗，中间自然留出洞口：
     比拿四个 div 拼遮罩稳，窗口怎么缩放都不会漏缝。 */
  box-shadow:0 0 0 9999px rgba(8,11,18,.62),0 0 0 1px rgba(255,255,255,.3) inset;
  transition:left .26s cubic-bezier(.22,.7,.3,1),top .26s cubic-bezier(.22,.7,.3,1),
    width .26s cubic-bezier(.22,.7,.3,1),height .26s cubic-bezier(.22,.7,.3,1);
}
.tour-tip{
  position:fixed;left:-999px;top:-999px;
  padding:13px 15px 14px;border-radius:14px;
  background:var(--surface);border:1px solid var(--line);
  box-shadow:0 26px 60px -30px rgba(0,0,0,.75);
  /* 教程现在承担全部功能说明，单步文字比以前长：小屏上宁可让气泡自己滚，
     也不能让「下一步」被挤出屏幕。 */
  max-height:calc(100vh - 24px);overflow:auto;overscroll-behavior:contain;
  transition:left .22s cubic-bezier(.22,.7,.3,1),top .22s cubic-bezier(.22,.7,.3,1);
}
.tour-arrow{
  position:absolute;left:20px;top:-7px;width:0;height:0;
  border-left:7px solid transparent;border-right:7px solid transparent;
  border-bottom:7px solid var(--surface);
}
.tour-tip.is-above .tour-arrow{border-bottom:0;border-top:7px solid var(--surface)}
.tour-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:7px}
.tour-step{font-size:11px;font-weight:var(--fw65);letter-spacing:.1em;color:var(--ink-4);font-variant-numeric:tabular-nums}
.tour-skip{
  padding:3px 9px;border-radius:7px;cursor:pointer;
  border:1px solid var(--line);background:transparent;
  font-size:11.5px;color:var(--ink-3);
}
.tour-skip:hover{color:var(--accent-ink);border-color:var(--accent-line);background:var(--accent-soft)}
.tour-skip:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.tour-tip h3{margin:0 0 6px;font-size:14.5px;font-weight:var(--fw65);letter-spacing:-.1px;color:var(--ink)}
.tour-tip p{margin:0;font-size:12.5px;line-height:1.85;color:var(--ink-2)}
.tour-foot{display:flex;align-items:center;justify-content:flex-end;gap:10px;margin-top:13px}
/* 十几步的进度用「4 / 13」这行数字表达，圆点一行挤不下也看不出是哪一步 */
.tour-btns{display:flex;gap:6px}
@media (prefers-reduced-motion:reduce){
  .tour-hole,.tour-tip{transition:none}
}

/* ---------- 开发者模式：退出登录 / 本地账号标记 ---------- */
.dev-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:11px}
.dev-local-tag{
  display:inline-flex;align-items:center;gap:5px;margin-left:8px;vertical-align:middle;
  font-size:11px;font-weight:var(--fw65);padding:2px 7px;border-radius:999px;
  color:var(--accent-ink);background:var(--accent-soft);border:1px solid var(--accent-line);
}

/* ---------- 周五~周日：两张计划表并排在同一条流水里 ---------- */
/* 第二张（下周）用主色描边，一眼能分出「上面在收尾、下面在提前排」 */
.plan-card + .plan-card{margin-top:12px}
.plan-card-2{border-color:var(--accent-line);box-shadow:var(--glass-shadow),0 0 0 1px var(--accent-line) inset}
.plan-card-2 .pb-title h2{color:var(--accent-ink)}

/* ---------- 顶栏：电脑端窗口再窄也不换形态 ---------- */
/* 唯一会变的是内部间距：装不下时收紧 gap 与按钮内边距，
   品牌文字、页面标签、同步、主题、头像一个都不少 —— 形态是固定的。 */
.appbar-in.tight .bar-full{gap:5px 8px;padding:0 6px 0 9px}
.appbar-in.tight .bar-full .nav{gap:1px}
.appbar-in.tight .bar-full .nav button{padding:0 9px;gap:5px}
.appbar-in.tight .bar-full .brand{gap:7px}

/* ============================================================
   二十二、V4.0.0 · 全屏双栏（左：整体数据 / 右：具体内容）
   ------------------------------------------------------------
   每个页面在宽屏下拆成两栏：
     左 = 概览（大数字、统计、列表）    右 = 具体（详情、表格、表单）
   窄屏不参与：两栏容器退化成 display:contents，子元素按原 DOM 顺序流动，
   手机端与原来一模一样（这一点是这套方案能一次覆盖 8 个页面的原因）。
   ============================================================ */
.pcol-l,.pcol-r{display:contents}

@media (min-width:1200px){
  .panel.active{
    display:grid;
    grid-template-columns:minmax(0,.86fr) minmax(0,1.14fr);
    gap:16px;align-items:start;
  }
  /* 复盘页的两栏装在 .rv-body 里（它自己是 display:contents），
     所以 .pcol-* 不是 .panel.active 的直接子元素 —— 这两条选择器必须带上它，
     否则整页会退化成「四张卡各占一格」的 2×2。 */
  .panel.active>.pcol-l,
  .panel.active>.pcol-r,
  .panel.active>.rv-body>.pcol-l,
  .panel.active>.rv-body>.pcol-r{
    display:flex;flex-direction:column;gap:12px;
    min-width:0;                 /* 子项里的表格 / 长串不许顶破网格 */
  }
  /* 栏内每块自己不留底边距：间距统一由 gap 给，免得叠成双倍 */
  .panel.active .pcol-l>*,
  .panel.active .pcol-r>*{margin-bottom:0}

  /* 比例按内容分配：列表要宽度 → 左略宽；计划表 7 列 → 右更宽 */
  #panel-notebook.active,
  #panel-papers.active{grid-template-columns:minmax(0,.94fr) minmax(0,1.06fr)}
  #panel-board.active{grid-template-columns:minmax(0,400px) minmax(0,1fr)}
  #panel-weekly.active{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
  #panel-mine.active{grid-template-columns:minmax(0,.78fr) minmax(0,1.22fr)}
  #panel-points.active{grid-template-columns:minmax(0,.82fr) minmax(0,1.18fr)}

  /* 左栏窄，卡片标题里那句说明先省略，别把标题挤成竖排 */
  .panel.active .pcol-l .card-title{flex-wrap:nowrap;white-space:nowrap}
  .panel.active .pcol-l .card-title .spacer{
    min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
  }
  /* 计划表在双栏里只有半屏：7 列放得下就不用横向滚动 */
  .plan-grid{min-width:780px}

  /* 详情栏没选中任何条目时的占位：空一栏在宽屏上很显眼。
     只给一圈虚线，不填底 —— 填了底就是一块很抢眼的白板，比"空"更难看。 */
  #nbDetail:empty::before,
  #paDetail:empty::before{
    content:"从左边选一条，详情显示在这里";
    display:flex;align-items:center;justify-content:center;
    min-height:240px;border:1px dashed var(--field-line);border-radius:var(--r);
    color:var(--ink-4);font-size:13.5px;letter-spacing:.02em;
  }

  /* 列表回到单列：它现在住在一栏里，再分两列每条就只剩 200px */
  #nbList,#paList,.td-list{display:block}
  #nbList>.nb-item,#paList>.nb-item{height:auto}
  /* 详情只占右栏，列表始终在左 —— 双栏的意义就是边看边挑 */
  .split{display:block}
  .split-main{min-width:0}
}

/* 手机端维持原样：两栏透明层不产生任何盒子 */
@media (max-width:900px){
  .pcol-l,.pcol-r{display:contents}
}

/* ============================================================
   二十三、V4.1.0 · 导航贴靠（顶部 / 左侧）
   ------------------------------------------------------------
   顶部 = 原来那条胶囊，逻辑不动；
   左侧 = 固定竖条：默认只露图标（64px），鼠标靠近横向展开到 212px 露出文字。
   只在 ≥901 的电脑端生效 —— 手机没有「靠近」这回事，底栏本来就在手边。
   ============================================================ */
@media (min-width:901px){

  /* 竖条本身：不再占据文档流顶部，改成贴在左边垂直居中 */
  html[data-dock="left"] .appbar{
    position:fixed;left:12px;top:50%;transform:translateY(-50%);
    z-index:40;padding:0;background:none;width:auto;
  }
  html[data-dock="left"] .appbar-in{
    /* 宽度归 CSS 管：JS 在左侧模式下一律不写内联宽度（见 WB.bar.sync） */
    width:64px;height:auto;max-height:calc(100vh - 40px);
    border-radius:22px;overflow:visible;
    transition:width .28s cubic-bezier(.22,.7,.3,1);
  }
  html[data-dock="left"] .appbar-in:hover,
  html[data-dock="left"] .appbar-in.kbd-open{width:212px}

  /* 两层交叉淡入在竖排里没有意义：极简层直接不参与 */
  html[data-dock="left"] .bar-mini{display:none}
  html[data-dock="left"] .bar-full{
    position:static;display:flex;flex-direction:column;align-items:stretch;
    width:100%;height:auto;padding:11px 8px;gap:6px;
    opacity:1;transform:none;pointer-events:auto;
    transition:none;
  }

  /* 品牌：收起时只剩那个方块，展开才出字。
     ⚠️ gap 也要跟着变：只把文字 max-width 从 0 放到 150、gap 却仍是 0，
        方块和「MaxStudy」会贴在一起，看起来就像字压在图标上。 */
  html[data-dock="left"] .bar-full .brand{
    justify-content:center;gap:0;padding:3px 0 9px;margin-bottom:2px;
    border-bottom:1px solid var(--line);
    transition:gap .28s cubic-bezier(.22,.7,.3,1);
  }
  html[data-dock="left"] .appbar-in:hover .bar-full .brand,
  html[data-dock="left"] .appbar-in.kbd-open .bar-full .brand{gap:10px}
  html[data-dock="left"] .brand-txt{
    max-width:0;opacity:0;overflow:hidden;white-space:nowrap;
    transition:max-width .28s cubic-bezier(.22,.7,.3,1),opacity .18s ease;
  }
  /* 展开只有两个入口：指针悬停（:hover）与键盘 Tab（.kbd-open）。
     ⚠️ 不能挂 :focus-within：鼠标点一下任意按钮，焦点就留在竖条里，
        此后鼠标移到页面别处它也不会收回 —— 这正是「不离开窗口就收不起来」的原因。
     ⚠️ 也不能挂 :has(:focus-visible)：脚本设的焦点在部分 Chrome 版本上也判为
        focus-visible，鼠标点完照样卡住。所以「用户是不是刚按了 Tab」由 JS 记，
        见 core.js 的 WB.bar.init —— 这件事只有事件能可靠判断。 */
  html[data-dock="left"] .appbar-in:hover .brand-txt,
  html[data-dock="left"] .appbar-in.kbd-open .brand-txt{max-width:150px;opacity:1}

  /* 导航：竖排、每一项等宽；文字用 max-width 收起（行高不变，不会抖） */
  html[data-dock="left"] .bar-full .nav{
    flex-direction:column;align-items:stretch;gap:2px;width:100%;
  }
  html[data-dock="left"] .nav-glider{
    left:4px;top:0;width:calc(100% - 8px);height:0;
    transition:transform .3s cubic-bezier(.23,1,.32,1),height .3s cubic-bezier(.23,1,.32,1),opacity .2s;
  }
  html[data-dock="left"] .bar-full .nav button{
    width:100%;height:40px;justify-content:flex-start;gap:0;padding:0 11px;
    border-radius:7px;
  }
  html[data-dock="left"] .bar-full .nav button>svg{flex:none}
  html[data-dock="left"] .bar-full .nav button>span{
    max-width:0;opacity:0;overflow:hidden;white-space:nowrap;
    margin-left:0;transition:max-width .28s cubic-bezier(.22,.7,.3,1),opacity .16s ease,margin-left .28s;
  }
  html[data-dock="left"] .appbar-in:hover .nav button>span,
  html[data-dock="left"] .appbar-in.kbd-open .nav button>span{
    max-width:130px;opacity:1;margin-left:10px;
  }

  /* 右侧那组（同步 / 主题 / 头像）竖着排到底部 */
  html[data-dock="left"] .bar-full .appbar-actions{
    flex-direction:column;align-items:center;gap:7px;
    width:100%;margin-top:4px;padding-top:9px;border-top:1px solid var(--line);
  }
  html[data-dock="left"] .bar-full .sync-wrap{display:flex;justify-content:center}

  /* 底部三件（同步 / 主题 / 头像）收起时全压成圆：
     竖条只有 64px 宽，而 .user-chip 里那两行字最宽 96px、
     .sync-pill 还有「已同步 · 2 分钟前」这种长文案 —— 不压掉就横向溢出，
     压在导航图标上，看起来就是「文字重叠」。展开态再放回来。 */
  html[data-dock="left"] .appbar-in .sync-pill{
    width:22px;height:22px;padding:0;gap:0;
    justify-content:center;font-size:0;overflow:hidden;
  }
  html[data-dock="left"] .appbar-in .user-chip{
    width:34px;height:34px;padding:2px;gap:0;
    justify-content:center;overflow:hidden;
  }
  html[data-dock="left"] .appbar-in .user-chip .su-txt{
    max-width:0;opacity:0;overflow:hidden;white-space:nowrap;
    transition:max-width .28s cubic-bezier(.22,.7,.3,1),opacity .16s ease;
  }
  html[data-dock="left"] .appbar-in:hover .sync-pill,
  html[data-dock="left"] .appbar-in.kbd-open .sync-pill{
    width:auto;height:24px;padding:0 9px;gap:6px;font-size:12px;
  }
  html[data-dock="left"] .appbar-in:hover .user-chip,
  html[data-dock="left"] .appbar-in.kbd-open .user-chip{
    width:auto;height:36px;padding:0 10px 0 3px;gap:8px;
  }
  html[data-dock="left"] .appbar-in:hover .user-chip .su-txt,
  html[data-dock="left"] .appbar-in.kbd-open .user-chip .su-txt{
    max-width:96px;opacity:1;
  }

  /* 内容让位：竖条固定住了，不再占文档流的 72px */
  html[data-dock="left"] .shell{padding-left:88px;padding-top:18px}
  html[data-dock="left"] .appbar{padding-right:0}

  /* 竖条展开时压在正文上方是正常的（临时浮出），但别挡到点击以外的东西 */
  html[data-dock="left"] .appbar-in{box-shadow:0 1px 0 var(--glass-hi) inset,0 18px 44px -26px rgba(16,20,30,.6)}

  /* 竖排滑块「首帧直接到位」：这一跳必须没有过渡，
     否则切到左侧的第一次定位会从水平位置滑下来，还会卡在中间 */
  html[data-dock="left"] .nav-glider.snap{transition:none !important}

  /* 主题按钮在竖条里保持常显：这里没有第二个开关可以替代它，
     所以不跟顶栏的「极简态才露」那套走 */
  html[data-dock="left"] .theme-btn{
    width:34px;border-width:1px;opacity:1;pointer-events:auto;transform:none;margin-left:0;
  }

  /* 展开时用户名 / 邮箱要在条内截断，不许顶到胶囊外面 */
  html[data-dock="left"] .bar-full{overflow:hidden}
  html[data-dock="left"] .bar-full .user-chip .su-txt{min-width:0;flex:1 1 auto;overflow:hidden}
  html[data-dock="left"] .bar-full .user-chip .su-txt b,
  html[data-dock="left"] .bar-full .user-chip .su-txt span{max-width:100%}
}

/* 手机端：贴靠偏好一律不生效，底栏照旧 */
@media (max-width:900px){
  html[data-dock="left"] .shell{padding-left:0;padding-top:0}
}

/* ---------- 设置页：主题预览格 ---------- */
.set-row-block{flex-direction:column;align-items:flex-start;gap:9px}
.set-row-block .k{font-size:13.5px}
.theme-pick{display:flex;gap:8px;flex-wrap:wrap}
.tpick{
  display:flex;flex-direction:column;align-items:center;gap:4px;
  width:63px;padding:4px;border-radius:7px;
  border:1px solid var(--field-line);background:var(--surface);
  cursor:pointer;transition:border-color var(--dur),box-shadow var(--dur),transform .12s;
}
.tpick:hover{border-color:var(--accent);transform:translateY(-1px)}
.tpick.on{border-color:var(--accent);box-shadow:0 0 0 2px var(--accent-soft)}
.tp-prev{
  display:block;width:100%;height:34px;border-radius:7px;
  position:relative;
  /* 边框改成内阴影：浅色底（尤其「跟随系统」左半边接近纯白）上，
     1px 的深色 border 会读成一道深色竖条，看起来像画错了。 */
  border:0;box-shadow:inset 0 0 0 1px rgba(20,25,40,.06);
  background-size:cover;background-position:center;
}
/* 每档一个图标，压在预览色块中间：光看色块分不清「星空」和「银河」 */
.tp-ico{
  position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);
  width:16px;height:16px;
}
.tp-auto .tp-ico,.tp-light .tp-ico{color:#33405a}
.tp-sky .tp-ico{color:#1a5c8a}
.tp-cartoony .tp-ico{color:#8a4b12}
.tp-dark .tp-ico,.tp-starry .tp-ico,.tp-galaxy .tp-ico{color:#e8eeff}
.tp-name{font-size:11px;color:var(--ink-3);line-height:1.3;white-space:nowrap}
.tpick.on .tp-name{color:var(--accent-ink);font-weight:var(--fw6)}

/* 七张预览：和图谱同源，不用图片文件（也就不会「预览和真选了不一样」） */
/* 跟随系统：斜切的「昼 → 夜」。
   原来左右各一半，缩略图只有 32px 高，那条 50% 的分界会读成一根深色竖条，
   看着像画歪了一笔。改成 135° 斜切，一眼就是「白天到晚上自动切」。 */
.tp-auto{background-image:linear-gradient(135deg,#eef3fb 0 46%,#1b2234 54% 100%)}
.tp-light{background-image:linear-gradient(160deg,#ffffff 0%,#eef2fa 100%)}
.tp-dark{background-image:linear-gradient(160deg,#1d2436 0%,#0b101c 100%)}
.tp-starry{
  background-color:#070b18;
  background-image:
    radial-gradient(1px 1px at 18% 26%,#fff,transparent),
    radial-gradient(1px 1px at 42% 62%,#dfe8ff,transparent),
    radial-gradient(1.5px 1.5px at 66% 22%,#fff,transparent),
    radial-gradient(1px 1px at 82% 58%,#cfe0ff,transparent),
    radial-gradient(1px 1px at 30% 84%,#fff,transparent),
    linear-gradient(160deg,#1a2a63 0%,#070b18 70%);
}
.tp-sky{
  background-color:#dbebfb;
  background-image:
    radial-gradient(38% 46% at 22% 26%,rgba(255,255,255,.96) 0%,rgba(255,255,255,0) 70%),
    radial-gradient(30% 34% at 62% 18%,rgba(255,255,255,.9) 0%,rgba(255,255,255,0) 72%),
    radial-gradient(46% 40% at 76% 62%,rgba(255,255,255,.85) 0%,rgba(255,255,255,0) 74%),
    linear-gradient(180deg,#c9e2fb 0%,#eef7ff 100%);
}
.tp-cartoony{
  background-color:#fff6e9;
  background-image:
    radial-gradient(40% 46% at 24% 24%,rgba(255,190,110,.95) 0%,rgba(255,190,110,0) 72%),
    radial-gradient(36% 40% at 74% 20%,rgba(255,158,196,.88) 0%,rgba(255,158,196,0) 74%),
    radial-gradient(44% 44% at 82% 74%,rgba(140,222,208,.8) 0%,rgba(140,222,208,0) 74%),
    linear-gradient(160deg,#fff3dd 0%,#ffeaf1 60%,#eef7ff 100%);
}
.tp-galaxy{
  background-color:#06040f;
  background-image:
    radial-gradient(56% 52% at 26% 22%,rgba(126,86,255,.92) 0%,rgba(126,86,255,0) 72%),
    radial-gradient(48% 46% at 80% 66%,rgba(196,92,220,.8) 0%,rgba(196,92,220,0) 74%),
    radial-gradient(1px 1px at 36% 34%,#fff,transparent),
    radial-gradient(1.4px 1.4px at 66% 56%,#fff,transparent),
    radial-gradient(1px 1px at 52% 80%,#e9e6ff,transparent),
    linear-gradient(200deg,#1a1145 0%,#08061c 70%);
}


/* 主题格：七档。以前五张靠 58px 硬宽挤在一行，现在改成自适应列，
   窄了就 3 列、宽了就 4 列，永远不会出现「最后一行吊着一张」。 */
/* 主题格：固定五列。七档排成「第一行 5 个 + 第二行 2 个」，
   右下角补一块「敬请期待」占位 —— 用 auto-fill 时列数会跟着面板宽度走，
   同一屏在 4+3 / 5+2 / 3+3+1 之间乱跳，看着像每次都在丢一个。 */
.theme-pick{display:grid;grid-template-columns:repeat(5,1fr);gap:6px}
.tpick{width:auto;padding:3px}
.tp-prev{height:32px}
.tp-name{font-size:11px}
/* 占位块：虚线、不可点，和真选项区分开 */
.tpick.is-soon{border-style:dashed;cursor:default;opacity:.72}
.tpick.is-soon:hover{border-color:var(--field-line);transform:none}
.tp-soon{
  background-image:linear-gradient(160deg,var(--surface-2) 0%,var(--inset) 100%);
  position:relative;
}
.tp-soon::after{
  content:"＋";position:absolute;inset:0;display:flex;align-items:center;justify-content:center;
  font-size:13px;color:var(--ink-4);
}


/* ============================================================
   二十四、V4.2.0 · 拖动贴靠
   ------------------------------------------------------------
   整条顶栏都能抓：往窗口左缘 / 上缘一拖，松手就贴过去（阈值见 core.js 的 zoneAt）。
   落点区只在拖动中出现，fixed 定位 + pointer-events:none，不占位也不吃点击。
   顶栏关掉文字选中：否则从品牌名上按下会先选出一片蓝底，看着像坏了。
   ============================================================ */
.appbar-in{user-select:none;-webkit-user-select:none}
.appbar-in .brand{cursor:grab}
body.dock-drag,body.dock-drag *{cursor:grabbing !important}
body.dock-drag{user-select:none;-webkit-user-select:none}

.dock-zones{position:fixed;inset:0;z-index:38;pointer-events:none}
/* 未命中：只有一条淡虚线框 + 一枚清楚的小标签；
   命中：填上主色淡底、虚线转实线。
   透明度不写在容器上 —— 整块降透明度会把标签一起变淡，压在正文上就读不出来了。 */
.dz{
  position:absolute;display:flex;align-items:center;justify-content:center;
  border:1.5px dashed var(--accent);border-radius:10px;
  background:transparent;
  transition:background-color .16s ease,border-color .16s ease;
}
.dz span{
  padding:5px 9px;border-radius:7px;white-space:nowrap;
  background:var(--bar);color:var(--accent-ink);
  font-size:12px;font-weight:var(--fw5);letter-spacing:.06em;
  box-shadow:0 0 0 1px var(--accent-line) inset;
}
.dz.hit{background:var(--accent-soft);border-color:var(--accent);border-style:solid}
/* 顶部条只占一薄层：整条盖下来会把页头标题也框进去，看着像页面坏了。
   标签贴左端，避开居中的顶栏胶囊 —— 那儿正好是它自己。 */
.dz-top{left:6px;right:6px;top:6px;height:62px;justify-content:flex-start;padding-left:16px}
/* 左侧条宽度只覆盖页边距：再宽就压到正文第一个字了 */
.dz-left{left:6px;top:80px;bottom:6px;width:60px}


/* 手机：底栏本来就在手边，没有贴靠可拖；横向滑动要留给切页手势 */
@media (max-width:900px){
  .dock-zones{display:none !important}
  .appbar-in .brand{cursor:default}
}

/* ============================================================
   L4.5 卡片与徽章（js/cards.js）
   ------------------------------------------------------------
   等级色是「跨主题固定」的：R 灰蓝 / SR 蓝 / SSR 紫 / UR 金。
   这些颜色是稀有度的语义，不能跟着每页的主题色族变 ——
   UR 在积分页是金色，换个页面变青色，收集感就散了。
   ============================================================ */
.cc-hub{position:relative}
.cc-hub-top{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.cc-ticket{display:flex;align-items:center;gap:10px;min-width:0}
.cc-ticket svg{color:var(--accent-ink);flex:none}
.cc-ticket-num{display:flex;align-items:baseline;gap:6px}
.cc-ticket-num b{font-size:32px;font-weight:var(--fw65);line-height:1;color:var(--ink);font-variant-numeric:tabular-nums}
.cc-ticket-num span{font-size:12px;color:var(--ink-3)}
.cc-hub-btns{margin-left:auto;display:flex;gap:8px;flex:none}

.cc-daily{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin-top:14px}
.cc-task{
  display:flex;gap:7px;align-items:flex-start;padding:9px 10px;border-radius:10px;
  background:var(--inset);box-shadow:inset 0 0 0 1px var(--line);
  transition:background-color .2s,box-shadow .2s;
}
.cc-task-box{
  flex:none;width:15px;height:15px;margin-top:1px;border-radius:7px;
  display:flex;align-items:center;justify-content:center;
  font-size:11px;font-weight:var(--fw7);color:var(--on-accent);
  box-shadow:inset 0 0 0 1px var(--line-2);
}
.cc-task-txt{min-width:0;display:flex;flex-direction:column;gap:2px}
.cc-task-txt b{font-size:12px;font-weight:var(--fw5);color:var(--ink-2);line-height:1.35}
.cc-task.is-on{background:var(--accent-wash);box-shadow:inset 0 0 0 1px var(--accent-line)}
.cc-task.is-on .cc-task-box{background:var(--accent)}
.cc-task.is-on .cc-task-txt b{color:var(--accent-ink)}

/* ---------- 图鉴 ---------- */
.cc-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(88px,1fr));gap:9px}
.cc-item{
  position:relative;display:block;padding:0;border:0;cursor:pointer;
  aspect-ratio:3/4;border-radius:7px;overflow:hidden;
  background:var(--inset);
  box-shadow:inset 0 0 0 1px var(--line-2);
  transition:transform .18s ease,box-shadow .18s ease;
}
.cc-item:hover{transform:translateY(-2px);box-shadow:inset 0 0 0 1px var(--g),0 10px 22px -14px var(--g)}
.cc-item:focus-visible{outline:2px solid var(--g);outline-offset:2px}
.cc-pic{position:absolute;inset:0;display:block}
.cc-pic img{width:100%;height:100%;object-fit:cover;display:block}
.cc-tag{
  position:absolute;left:5px;top:5px;z-index:2;
  padding:1.5px 5px;border-radius:7px;
  font-size:11px;font-weight:var(--fw7);letter-spacing:.04em;line-height:1.5;
  color:var(--on-accent);background:var(--g);box-shadow:0 2px 6px -2px rgba(0,0,0,.5);
}
.cc-count{
  position:absolute;right:5px;top:5px;z-index:2;
  padding:1px 5px;border-radius:7px;font-size:11px;font-weight:var(--fw6);
  color:var(--on-accent);background:rgba(0,0,0,.45);
}
.cc-name{
  position:absolute;left:0;right:0;bottom:0;z-index:2;
  padding:12px 6px 5px;font-size:11px;font-weight:var(--fw5);color:var(--on-accent);
  background:linear-gradient(transparent,rgba(8,10,16,.72));
  text-align:center;letter-spacing:.04em;
}
/* 未获得：降饱和 + 压暗，名字打问号。图照常加载，只是看不清 —— 收集欲来自「快看清了」 */
.cc-item.is-locked .cc-pic img{filter:saturate(.12) brightness(.5) contrast(.9);opacity:.75}
.cc-item.is-locked{box-shadow:inset 0 0 0 1px var(--line)}
.cc-item.is-locked .cc-tag{opacity:.55}

/* 等级色 */
.g-r{--g:#7c8497}
.g-sr{--g:#2f6feb}
.g-ssr{--g:#8b5cf6}
.g-ur{--g:#d99b32}
/* X：唯一一张「金里带火」的色 —— 再往上没有等级了，就不再往紫里走 */
.g-x{--g:#ff8a3c}
html[data-theme="dark"] .g-r{--g:#98a1b4}
html[data-theme="dark"] .g-sr{--g:#6aa2ff}
html[data-theme="dark"] .g-ssr{--g:#b18cff}
html[data-theme="dark"] .g-ur{--g:#f0b64a}
html[data-theme="dark"] .g-x{--g:#ffab63}
.cc-item.g-ssr{box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--g) 45%,transparent)}
.cc-item.g-ur{box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--g) 55%,transparent)}

/* 徽章墙（.cc-badges / .cc-badge*）在 V4.4.3 随着 100 枚图鉴一起下线：
   页面上只留一张统计卡，全部徽章进弹层，旧的竖向列表样式不再有任何引用。 */

/* ---------- 弹层 ---------- */
body.cc-lock{overflow:hidden}
.cc-modal{
  position:fixed;inset:0;z-index:120;
  display:flex;align-items:center;justify-content:center;padding:20px;
  /* 内容比视口高时自己滚：弹层是 fixed 铺满的，不给 overflow 就只能被裁掉 */
  overflow:auto;
  background:rgba(9,11,17,.6);
  -webkit-backdrop-filter:blur(14px) saturate(120%);
  backdrop-filter:blur(14px) saturate(120%);
  animation:ccFade .18s ease both;
}
.cc-modal.leaving{animation:ccFadeOut .18s ease both}
/* 卡片详情：叠在抽卡结果上面的一层。
   独立成层是为了「关掉详情还能接着看十连里的下一张」——
   以前它直接替换整个弹层内容，关一次连结果一起没了。 */
.cc-detail{
  position:fixed;inset:0;z-index:10;
  display:flex;align-items:center;justify-content:center;
  padding:20px;overflow:auto;
  background:rgba(9,11,17,.55);
  -webkit-backdrop-filter:blur(10px) saturate(120%);
  backdrop-filter:blur(10px) saturate(120%);
  animation:ccDetailIn .22s cubic-bezier(.22,.7,.3,1) both;
}
.cc-detail.leaving{animation:ccFadeOut .16s ease both}
@keyframes ccDetailIn{from{opacity:0}to{opacity:1}}
@keyframes ccFade{from{opacity:0}to{opacity:1}}
@keyframes ccFadeOut{from{opacity:1}to{opacity:0}}
.cc-x{
  position:absolute;right:14px;top:14px;z-index:5;
  width:32px;height:32px;border-radius:50%;border:0;cursor:pointer;
  display:flex;align-items:center;justify-content:center;
  font-size:13.5px;color:var(--on-accent);background:rgba(255,255,255,.14);
}
.cc-x:hover{background:rgba(255,255,255,.24)}
.cc-x:focus-visible{outline:2px solid #fff;outline-offset:2px}

/* ---------- 抽卡结果 ---------- */
.cc-draw{
  position:relative;
  /* 宽度交给 flex 的 basis/shrink 算，不要写 width:100%：
     width:100% + padding 会把盒子顶出视口右边，真机上是「十连第 4 列被切一半」。
     min-width:0 是保命的：不写它，网格会按「最小内容宽度」把盒子撑出去。 */
  flex:0 1 560px;width:auto;max-width:100%;min-width:0;
  padding:26px 22px 20px;border-radius:20px;
  background-color:transparent;
  background-image:linear-gradient(168deg,var(--glass-a) 0%,var(--glass-b) 100%);
  -webkit-backdrop-filter:blur(26px) saturate(185%);
  backdrop-filter:blur(26px) saturate(185%);
  border:1px solid var(--glass-line);
  box-shadow:var(--glass-shadow),0 40px 80px -40px rgba(0,0,0,.72);
  animation:ccRise .32s cubic-bezier(.2,.9,.3,1) both;
}
@keyframes ccRise{from{opacity:0;transform:translateY(22px) scale(.97)}to{opacity:1;transform:none}}
.cc-draw-head{text-align:center;margin-bottom:16px}
.cc-draw-head b{display:block;font-size:15px;font-weight:var(--fw65);color:var(--ink)}
.cc-draw-head span{display:block;margin-top:3px;font-size:12px;color:var(--ink-4)}
.cc-draw-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(64px,1fr));gap:9px}
.cc-draw.is-multi .cc-draw-grid{grid-template-columns:repeat(5,minmax(0,1fr))}
.cc-draw-item{
  position:relative;padding:0;border:0;cursor:pointer;aspect-ratio:3/4;
  border-radius:10px;overflow:hidden;background:var(--inset);
  box-shadow:0 0 0 1px color-mix(in srgb,var(--g) 60%,transparent),0 12px 26px -16px var(--g);
  animation:ccCardIn .4s cubic-bezier(.2,.9,.3,1) both;
}
@keyframes ccCardIn{from{opacity:0;transform:translateY(16px) scale(.9)}to{opacity:1;transform:none}}
.cc-draw-grid .cc-draw-item:nth-child(2){animation-delay:.05s}
.cc-draw-grid .cc-draw-item:nth-child(3){animation-delay:.1s}
.cc-draw-grid .cc-draw-item:nth-child(4){animation-delay:.15s}
.cc-draw-grid .cc-draw-item:nth-child(5){animation-delay:.2s}
.cc-draw-grid .cc-draw-item:nth-child(6){animation-delay:.25s}
.cc-draw-grid .cc-draw-item:nth-child(7){animation-delay:.3s}
.cc-draw-grid .cc-draw-item:nth-child(8){animation-delay:.35s}
.cc-draw-grid .cc-draw-item:nth-child(9){animation-delay:.4s}
.cc-draw-grid .cc-draw-item:nth-child(10){animation-delay:.45s}
.cc-draw-item.g-ssr,.cc-draw-item.g-ur{box-shadow:0 0 0 1.5px var(--g),0 0 30px -8px var(--g),0 16px 34px -18px var(--g)}
.cc-new{
  position:absolute;left:0;right:0;bottom:0;z-index:3;
  padding:3px 0;font-size:11px;font-weight:var(--fw7);letter-spacing:.1em;
  text-align:center;color:var(--on-accent);background:var(--g);
}

/* ---------- 卡片详情 + 3D ---------- */
.cc-stage{
  position:relative;display:flex;flex-direction:column;align-items:center;gap:16px;
  animation:ccRise .34s cubic-bezier(.2,.9,.3,1) both;
}
.cc-tilt{perspective:1100px;perspective-origin:50% 50%;touch-action:none}
.cc-plate{
  position:relative;width:min(74vw,300px);aspect-ratio:3/4;border-radius:10px;
  overflow:hidden;transform-style:preserve-3d;
  transform:rotateX(var(--rx,0deg)) rotateY(var(--ry,0deg));
  box-shadow:
    var(--sx,0px) var(--sy,0px) 46px -18px rgba(0,0,0,.62),
    0 0 0 1px color-mix(in srgb,var(--g) 55%,transparent),
    0 0 46px -14px var(--g);
  transition:transform .5s cubic-bezier(.2,.8,.3,1),box-shadow .5s ease;
}
/* 指针在卡上移动时不能有过渡：每帧设值 + transition 会让卡「拖着」跟不上手 */
.cc-plate.is-live{transition:transform 0s,box-shadow .28s ease}
.cc-plate .cc-shot{position:absolute;inset:0;transform:translateZ(22px)}
.cc-plate .cc-shot img{width:100%;height:100%;object-fit:cover;display:block}
.cc-shine{
  position:absolute;inset:0;pointer-events:none;opacity:0;
  background:radial-gradient(circle at var(--mx,50%) var(--my,50%),
    rgba(255,255,255,.62) 0%,rgba(255,255,255,.14) 26%,transparent 56%);
  mix-blend-mode:screen;
  transition:opacity .3s ease;
  transform:translateZ(30px);
}
.cc-plate.is-3d:hover .cc-shine,.cc-plate.is-live .cc-shine{opacity:1}
.cc-frame{
  position:absolute;inset:0;pointer-events:none;transform:translateZ(12px);
  border-radius:10px;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.28),inset 0 1px 0 rgba(255,255,255,.5);
}
/* 高等级卡常驻一道斜向扫光（不用 JS，纯 CSS 循环，reduced-motion 下关掉） */
.cc-plate.g-sr::before,.cc-plate.g-ssr::before,.cc-plate.g-ur::before{
  content:"";position:absolute;inset:-40%;
  background:linear-gradient(104deg,transparent 38%,rgba(255,255,255,.34) 48%,rgba(255,255,255,.06) 55%,transparent 62%);
  transform:translateZ(34px);pointer-events:none;
  animation:ccSweep 5.2s ease-in-out infinite;
}
@keyframes ccSweep{
  0%,64%{transform:translate3d(-38%,0,34px) rotate(0.001deg)}
  88%,100%{transform:translate3d(38%,0,34px) rotate(0.001deg)}
}
.cc-quote{
  position:absolute;left:0;right:0;bottom:0;transform:translateZ(46px);
  padding:30px 16px 16px;
  background:linear-gradient(transparent,rgba(6,8,14,.78) 62%);
}
.cc-quote span{
  display:block;font-size:13.5px;line-height:1.6;font-weight:var(--fw5);
  color:var(--on-accent);text-shadow:0 1px 12px rgba(0,0,0,.5);
}
.cc-info{text-align:center;max-width:320px}
.cc-info-top{display:flex;align-items:center;justify-content:center;gap:8px}
.cc-info-top b{font-size:15px;font-weight:var(--fw65);color:var(--on-accent);letter-spacing:.04em}
.cc-grade{
  padding:1px 7px;border-radius:7px;font-size:11px;font-weight:var(--fw7);
  letter-spacing:.06em;color:var(--on-accent);background:var(--g);
}
.cc-info p{margin:6px 0 0;font-size:12px;line-height:1.6;color:rgba(255,255,255,.82);text-shadow:0 1px 8px rgba(0,0,0,.5)}

/* 窄屏：日期任务条压成一行一条，卡片网格保持 4 列 */
@media (max-width:640px){
  .cc-daily{grid-template-columns:1fr}
  .cc-daily .cc-task{padding:8px 10px}
  .cc-hub-btns{margin-left:0;width:100%}
  .cc-hub-btns .btn{flex:1 1 auto}
  .cc-modal{padding:14px}
  .cc-draw.is-multi .cc-draw-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
  .cc-plate{width:min(82vw,300px)}
}
@media (prefers-reduced-motion:reduce){
  .cc-modal,.cc-draw,.cc-stage,.cc-draw-item{animation:none}
  .cc-plate.g-sr::before,.cc-plate.g-ssr::before,.cc-plate.g-ur::before{animation:none;opacity:0}
  .cc-plate,.cc-plate.is-live{transition:none}
}

/* ---------- 抽卡记录 ---------- */
.cc-log{max-height:52vh;overflow:auto;margin-top:4px;
  -webkit-mask-image:linear-gradient(180deg,#000 0,#000 calc(100% - 14px),transparent);
  mask-image:linear-gradient(180deg,#000 0,#000 calc(100% - 14px),transparent)}
.cc-log-row{
  display:flex;align-items:center;gap:8px;padding:7px 2px;
  border-bottom:1px solid var(--line);font-size:12.5px;
}
.cc-log-row:last-child{border-bottom:0}
.cc-log-dot{width:7px;height:7px;border-radius:50%;flex:none;background:var(--g,#7c8497)}
.cc-log-row b{flex:1;min-width:0;font-weight:var(--fw6);color:var(--ink);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cc-log-g{font-size:10px;font-weight:var(--fw7);letter-spacing:.03em;color:var(--g,#7c8497);flex:none}
.cc-log-row .cc-new{position:static;margin:0;padding:0 4px;font-size:9px}
/* 抽到 X 时结果卡上的「成就」角标：金色，与 NEW 同一位置 */
.cc-new.cc-ach{background:linear-gradient(135deg,#f7c05a,#ff8a3c);color:#231000}
.cc-log-row em{font-style:normal;font-size:11px;color:var(--ink-4);
  font-variant-numeric:tabular-nums;flex:none}
/* 特别成就：跟 100 枚徽章同一套格子，但用金色区分「运气」这一档 */
.cc-bdgroup.is-extra{margin-top:14px;padding-top:10px;border-top:1px solid var(--line)}
.cc-bd.is-extra.is-on{--accent:#d99b32}
.cc-bd.is-extra .cc-bd-ico{color:var(--g,#8b8f9c)}

/* ---------- X 卡：海上日出 ----------
   整张卡是画出来的，没有图片。分层（天 / 星 / 光晕 / 太阳 / 云 / 海 / 反光 / 浪 / 鸥）
   各自带一点动画，叠起来就是「光一直在变」。
   卡片倾斜时只有远处的天和近处的浪按不同深度错位，太阳保持平面 ——
   太阳是远景，跟着转反而假。 */
.cc-sun{position:absolute;inset:0;overflow:hidden;background:#0a0a1a}
/* 不加 preserve-3d，子层的 translateZ 会被压平 —— 视差就成了假的 */
.cc-plate.is-scene .cc-shot,
.cc-plate.is-scene .cc-sun{transform-style:preserve-3d}
.cc-sun span{position:absolute;display:block}

.cs-sky{
  inset:0;
  background:
    radial-gradient(120% 62% at 50% 60%,
      rgba(255,170,90,.55) 0%, rgba(255,120,60,.20) 38%, rgba(255,120,60,0) 64%),
    linear-gradient(180deg,#100828 0%,#2a1140 24%,#6a2346 46%,#b8452f 60%,
      #e8792f 70%,#ffc266 79%,#ffe7b0 85%,#fff3d0 100%);
  transform:translateZ(-12px);
}
.cs-stars{
  inset:0 0 42% 0;
  background-image:
    radial-gradient(1.4px 1.4px at 16% 18%,rgba(255,255,255,.95),transparent),
    radial-gradient(1.2px 1.2px at 32% 9%,rgba(255,255,255,.8),transparent),
    radial-gradient(1.6px 1.6px at 58% 15%,rgba(255,255,255,.9),transparent),
    radial-gradient(1.1px 1.1px at 74% 7%,rgba(255,255,255,.75),transparent),
    radial-gradient(1.3px 1.3px at 88% 20%,rgba(255,255,255,.85),transparent),
    radial-gradient(1px 1px at 44% 26%,rgba(255,255,255,.6),transparent);
  opacity:.9;
  animation:csTwinkle 7s ease-in-out infinite;
  transform:translateZ(-8px);
}
.cs-halo{
  left:50%;top:47%;width:130%;aspect-ratio:1;
  margin-left:-65%;margin-top:-65%;
  background:radial-gradient(circle,
    rgba(255,244,205,.80) 0%, rgba(255,186,102,.42) 22%, rgba(255,140,70,.16) 42%, transparent 64%);
  filter:blur(2px);
  animation:csBreath 7.5s ease-in-out infinite;
}
/* 太阳压在海平线上：中心略高于海面，下缘刚好贴住那条亮线。
   画成「半个太阳掉进海里」是日落，不是日出。 */
.cs-disc{
  left:50%;top:48%;width:13%;aspect-ratio:1;border-radius:50%;
  margin-left:-6.5%;margin-top:-6.5%;
  background:radial-gradient(circle at 50% 38%,#fffef8 0%,#fff0b8 38%,#ffc163 72%,#ff8f33 100%);
  box-shadow:0 0 10px 3px rgba(255,196,110,.75), 0 0 34px 12px rgba(255,156,64,.34);
  animation:csRise 9s ease-in-out infinite alternate;
}
.cs-cloud{
  height:5%;border-radius:50%;
  background:linear-gradient(90deg,transparent,rgba(255,196,150,.55),rgba(255,220,180,.28),transparent);
  filter:blur(2.5px);
}
.cs-cloud.c1{left:-22%;top:33%;width:82%;opacity:.85;animation:csDrift 26s linear infinite}
.cs-cloud.c2{left:16%;top:24%;width:72%;height:4.2%;opacity:.6;animation:csDrift 34s linear infinite reverse}
.cs-cloud.c3{left:-10%;top:43%;width:60%;height:3%;opacity:.5;animation:csDrift 42s linear infinite}
/* 海：紧贴太阳下缘开始，顶端一条亮线就是海平线 */
.cs-sea{
  left:0;right:0;top:54.5%;bottom:0;
  background:
    linear-gradient(180deg,rgba(120,56,64,.95) 0%,rgba(46,28,52,.97) 34%,#0b0a1c 100%);
  transform:translateZ(6px);
}
.cs-sea::before{
  content:'';position:absolute;left:0;right:0;top:0;height:1.5px;
  background:linear-gradient(90deg,transparent 6%,rgba(255,226,168,.9) 50%,transparent 94%);
}
.cs-sea::after{
  content:'';position:absolute;left:0;right:0;top:0;height:26%;
  background:linear-gradient(180deg,rgba(255,168,96,.22),transparent);
}
/* 水面反光：三团大小不一的光斑顺着水面散开，再压一层细横纹。
   之前用过实心梯形 + clip-path —— 模糊之后仍然是一条「修在海里的路」。 */
.cs-glint{
  left:50%;top:54.5%;width:42%;height:40%;
  margin-left:-21%;
  background:
    radial-gradient(38% 16% at 50% 6%,rgba(255,242,198,.95),rgba(255,196,120,0) 72%),
    radial-gradient(30% 20% at 46% 26%,rgba(255,212,150,.62),rgba(255,170,100,0) 74%),
    radial-gradient(34% 22% at 55% 46%,rgba(255,196,132,.38),rgba(255,160,90,0) 76%),
    radial-gradient(26% 20% at 49% 70%,rgba(255,170,110,.18),transparent 78%);
  filter:blur(4px);mix-blend-mode:screen;opacity:.9;
  animation:csGlint 5.2s ease-in-out infinite;
  transform:translateZ(12px);
}
.cs-glint::after{
  content:'';position:absolute;inset:0;
  background:repeating-linear-gradient(180deg,rgba(255,248,220,.55) 0 1px,rgba(255,248,220,0) 1px 7px);
  -webkit-mask-image:linear-gradient(180deg,#000 0%,rgba(0,0,0,.5) 40%,transparent 82%);
  mask-image:linear-gradient(180deg,#000 0%,rgba(0,0,0,.5) 40%,transparent 82%);
  opacity:.55;
}
.cs-wave{
  left:-4%;right:-4%;
  background:
    repeating-linear-gradient(180deg,rgba(255,214,175,.22) 0 1px,rgba(255,255,255,0) 1px 5px),
    linear-gradient(90deg,rgba(255,150,90,.10),rgba(120,170,210,.14),rgba(255,150,90,.10));
  transform:translateZ(18px);
}
.cs-wave.w1{top:62%;height:12%;opacity:.5;animation:csFlow 11s linear infinite}
.cs-wave.w2{top:78%;height:12%;opacity:.32;animation:csFlow 15s linear infinite reverse}
.cs-birds{
  right:12%;top:26%;width:17%;color:rgba(24,12,24,.72);
  animation:csFly 16s ease-in-out infinite;
}
.cs-birds svg{width:100%;height:auto;display:block}

@keyframes csTwinkle{0%,100%{opacity:.9}50%{opacity:.45}}
@keyframes csBreath{0%,100%{opacity:.85;transform:scale(1)}50%{opacity:1;transform:scale(1.06)}}
@keyframes csRise{from{transform:translateY(1.6%)}to{transform:translateY(-1.6%)}}
@keyframes csDrift{from{transform:translateX(-12%)}to{transform:translateX(24%)}}
@keyframes csGlint{0%,100%{opacity:.75;transform:translateZ(12px) scaleX(.9)}50%{opacity:1;transform:translateZ(12px) scaleX(1.08)}}
@keyframes csFlow{from{background-position:0 0}to{background-position:0 60px}}
@keyframes csFly{0%,100%{transform:translate(0,0)}50%{transform:translate(-8px,-4px)}}

/* 卡片边框：X 的金边自己会呼吸，其他等级是静止的 */
.cc-plate.g-x{box-shadow:
  var(--sx,0px) var(--sy,0px) 46px -18px rgba(0,0,0,.62),
  0 0 0 1px rgba(255,171,99,.75),
  0 0 60px -10px rgba(255,140,60,.65);
}
.cc-plate.g-x::before{
  content:'';position:absolute;inset:0;z-index:3;pointer-events:none;border-radius:inherit;
  background:linear-gradient(115deg,transparent 34%,rgba(255,236,190,.30) 48%,transparent 62%);
  background-size:220% 220%;
  animation:csSheen 6.5s ease-in-out infinite;
}
@keyframes csSheen{0%,100%{background-position:120% 0}50%{background-position:-40% 0}}
@media (prefers-reduced-motion:reduce){
  .cc-sun span{animation:none !important}
  .cc-plate.g-x::before{animation:none;opacity:0}
}

/* 没抽到的卡：压掉颜色让人一眼看出「还没得到」，但**不模糊** ——
   模糊等于连画面都看不到，收藏册就变成了「一墙灰块」。
   图鉴缩略图那边才做剪影，详情层要能看清画的是什么。 */
/* 未获得：降饱和但仍要「看得出画的是什么」，太灰会让人以为图没加载 */
.cc-shot.is-locked img{filter:saturate(.62) brightness(.92) contrast(.98)}
.cc-lock-tag{
  position:absolute;left:0;right:0;top:0;z-index:4;
  padding:6px 0;text-align:center;
  font-size:10.5px;font-weight:var(--fw6);letter-spacing:.14em;
  color:rgba(255,255,255,.9);background:rgba(12,16,24,.42);
  transform:translateZ(28px);
}

/* 光影的第二层：光从指针那一侧来，对面就该暗下去。
   只加一块白色光斑的话，在本身就亮的日出图上几乎看不出来 ——
   真正让人感觉到「卡是立起来的」是暗角在动，不是高光在动。 */
.cc-plate::after{
  content:"";position:absolute;inset:0;pointer-events:none;
  transform:translateZ(32px);opacity:0;transition:opacity .3s ease;
  background:radial-gradient(circle at var(--mx,50%) var(--my,50%),
    transparent 26%,rgba(4,6,12,.12) 58%,rgba(4,6,12,.42) 100%);
}
.cc-plate.is-3d:hover::after,.cc-plate.is-live::after{opacity:1}

/* 网格与卡片同样要 min-width:0：flex 子项的默认值 auto 会让它们按内容撑开 */
.cc-draw-grid{min-width:0}
.cc-draw-item{min-width:0;width:100%}

/* 图鉴分段：每段一个等级点 + 收集进度。45 张平铺太长，分段后
   高等级那几行短、低等级那几行长，本身就构成一条进度曲线。 */
.cc-group + .cc-group{margin-top:14px}
.cc-group-t{
  display:flex;align-items:center;gap:6px;margin:0 0 7px;
  font-size:11px;font-weight:var(--fw65);letter-spacing:.08em;color:var(--ink-3);
}
.cc-group-t .cc-dot{width:6px;height:6px;border-radius:2px;background:var(--g);flex:none}
.cc-group-t em{margin-left:auto;font-style:normal;font-weight:var(--fw4);font-size:11px;color:var(--ink-4)}

/* ============================================================
   L5 版本切换的过场
   ------------------------------------------------------------
   各版本是独立文档，文档之间没法做 CSS 过渡，所以拆成两半：
   旧页把幕布盖上（html.ver-leave）→ 跳转 → 新页首帧先盖着，
   两帧后揭开（html.ver-arrive 移除）。两半用同一个元素、同一个时长，
   看起来就是一镜到底，而不是「白闪一下」。
   以后新增任何版本，只要带这个元素 + 首帧那段脚本，就自动继承同一套特效。
   ============================================================ */
.ver-veil{
  position:fixed;inset:0;z-index:9000;
  background:var(--bg);
  opacity:0;pointer-events:none;
  transition:opacity .2s ease;
}
html.ver-leave .ver-veil,
html.ver-arrive .ver-veil{opacity:1}
@media (prefers-reduced-motion:reduce){
  .ver-veil{transition:none}
}

/* ---------- 概率说明（写真实的，不藏） ---------- */
.cc-odds{
  display:flex;flex-wrap:wrap;align-items:center;gap:6px 13px;
  margin-top:12px;padding-top:11px;border-top:1px solid var(--line);
}
.cc-odd{
  display:inline-flex;align-items:center;gap:5px;
  font-size:11px;letter-spacing:.02em;color:var(--ink-3);
}
.cc-odd b{font-weight:var(--fw6);color:var(--ink-2);font-variant-numeric:tabular-nums}
.cc-odd .cc-dot{width:6px;height:6px;border-radius:2px;background:var(--g);flex:none}

/* ---------- 分解（在卡片详情层里，所以按钮要按深底做） ---------- */
.cc-conv{display:flex;flex-wrap:wrap;gap:7px;justify-content:center;margin-top:13px}
.cc-conv.is-ask{flex-direction:column;gap:10px}
.cc-conv p{margin:0;font-size:11.5px;line-height:1.6;text-align:center;color:rgba(255,255,255,.82);text-shadow:0 1px 8px rgba(0,0,0,.5)}
.cc-conv p b{color:rgba(255,255,255,.92);font-weight:var(--fw5)}
.cc-conv-btns{display:flex;gap:7px;justify-content:center;flex-wrap:wrap}
.cc-btn{
  padding:6px 13px;border-radius:8px;border:1px solid rgba(255,255,255,.16);
  background:rgba(255,255,255,.1);color:rgba(255,255,255,.92);
  font-size:11.5px;font-weight:var(--fw5);cursor:pointer;
  transition:background-color .18s ease,border-color .18s ease;
}
.cc-btn:hover{background:rgba(255,255,255,.17)}
.cc-btn:focus-visible{outline:2px solid #fff;outline-offset:2px}
.cc-btn-main{background:var(--accent);border-color:transparent;color:#fff}
.cc-btn-main:hover{background:var(--accent)}

/* ---------- 已分解：灰掉 + 一条横带，点开只提示、不预览 ---------- */
.cc-item.is-gone .cc-pic img{filter:saturate(.08) brightness(.56)}
.cc-gone-tag{
  position:absolute;left:0;right:0;top:50%;transform:translateY(-50%);z-index:3;
  padding:2px 0;text-align:center;
  font-size:9.5px;letter-spacing:.14em;color:rgba(255,255,255,.86);
  background:rgba(8,11,18,.66);
}
@media (prefers-reduced-motion:reduce){
  .cc-btn{transition:none}
}

/* ============================================================
   积分页 · 三张统计卡 + 两个图鉴弹层
   ------------------------------------------------------------
   左列从「券 + 任务 + 45 张图鉴墙 + 6 枚徽章墙」收成三张卡：
   券、卡片、徽章各自只报一个数，细看进弹层。
   100 枚徽章平铺在页面上没人看得完，也不该看得完。
   ============================================================ */
.cc-stat{margin-bottom:14px}
.cc-stat-row{display:flex;align-items:center;gap:11px}
.cc-stat-ico{
  flex:none;width:34px;height:34px;border-radius:10px;
  display:flex;align-items:center;justify-content:center;
  color:var(--accent-ink);background:var(--accent-soft);
  box-shadow:inset 0 0 0 1px var(--accent-line);
}
.cc-stat-txt{min-width:0;flex:1 1 auto;display:flex;flex-direction:column;gap:3px}
.cc-stat-txt b{
  font-size:21px;font-weight:var(--fw65);line-height:1;color:var(--ink);
  font-variant-numeric:tabular-nums;
}
.cc-stat-txt b i{font-style:normal;font-size:12.5px;font-weight:var(--fw4);color:var(--ink-4)}
.cc-stat-txt em{font-style:normal;font-size:11.5px;line-height:1.4;color:var(--ink-3)}

/* 想要的那枚：进度常驻，不藏在弹层里 —— 目标要天天看得见才有用 */
.cc-want{margin-top:12px;padding-top:11px;border-top:1px solid var(--line)}
.cc-want-top{display:flex;align-items:baseline;gap:7px;font-size:11px;color:var(--ink-4)}
.cc-want-top b{font-size:12.5px;font-weight:var(--fw6);color:var(--ink)}
.cc-want-top em{
  margin-left:auto;font-style:normal;font-variant-numeric:tabular-nums;
  font-size:11.5px;color:var(--accent-ink);
}
.cc-want-bar{
  display:block;height:5px;border-radius:3px;margin-top:7px;
  overflow:hidden;background:var(--line-2);
}
.cc-want-bar i{display:block;height:100%;border-radius:3px;background:var(--accent);transition:width .3s ease}
.cc-want-bar.is-on i{background:var(--accent)}
.cc-want-sub{margin:7px 0 0;font-size:11px;line-height:1.55;color:var(--ink-4)}
.cc-want-empty{
  margin:12px 0 0;padding-top:11px;border-top:1px solid var(--line);
  font-size:11.5px;line-height:1.65;color:var(--ink-4);
}

/* ---------- 弹层 ---------- */
.cc-panel{
  position:relative;width:100%;max-width:860px;max-height:84vh;overflow:auto;
  padding:22px 22px 26px;border-radius:18px;
  background:var(--surface);border:1px solid var(--line);
  box-shadow:0 40px 80px -40px rgba(0,0,0,.72);
  animation:ccRise .3s cubic-bezier(.2,.9,.3,1) both;
}
.cc-panel-head{margin-bottom:16px;padding-right:36px}
.cc-panel-head b{display:block;font-size:15px;font-weight:var(--fw65);color:var(--ink)}
.cc-panel-head span{display:block;margin-top:3px;font-size:11.5px;line-height:1.5;color:var(--ink-4)}
/* 弹层是浅色面板，默认那颗白 ✕ 会消失，得按面板换色 */
.cc-panel .cc-x{color:var(--ink-3);background:var(--inset);box-shadow:inset 0 0 0 1px var(--line)}
.cc-panel .cc-x:hover{color:var(--accent-ink);background:var(--accent-soft)}

/* ---------- 徽章图鉴 ---------- */
.cc-bdgroup + .cc-bdgroup{margin-top:16px}
.cc-bdgroup-t{display:flex;align-items:baseline;gap:8px;margin:0 0 8px}
.cc-bdgroup-t b{font-size:12.5px;font-weight:var(--fw6);color:var(--ink)}
.cc-bdgroup-t span{font-size:11px;color:var(--ink-4)}
.cc-bdgroup-t em{
  margin-left:auto;font-style:normal;font-size:11px;
  color:var(--ink-3);font-variant-numeric:tabular-nums;
}
/* 固定 10 列：每个系列正好 10 档，一屏一组，不能拆成 9+1 */
.cc-bdgrid{display:grid;grid-template-columns:repeat(10,minmax(0,1fr));gap:8px}
.cc-bd{
  position:relative;display:flex;flex-direction:column;align-items:center;gap:3px;
  padding:9px 6px 7px;border-radius:10px;cursor:pointer;
  background:var(--inset);border:1px solid var(--line);
  color:var(--ink-4);text-align:center;
  transition:background-color .18s ease,border-color .18s ease,color .18s ease;
}
.cc-bd:hover{border-color:var(--accent-line);color:var(--ink-2)}
.cc-bd:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.cc-bd-ico{display:flex;color:inherit}
.cc-bd-name{
  max-width:100%;font-size:11px;font-weight:var(--fw5);color:var(--ink-2);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
.cc-bd-num{font-size:10px;color:var(--ink-4);font-variant-numeric:tabular-nums}
.cc-bd-bar{display:block;width:100%;height:3px;border-radius:2px;overflow:hidden;background:var(--line-2)}
.cc-bd-bar i{display:block;height:100%;border-radius:2px;background:var(--ink-4)}
.cc-bd.is-on{background:var(--accent-wash);border-color:var(--accent-line);color:var(--accent-ink)}
.cc-bd.is-on .cc-bd-name{color:var(--accent-ink)}
.cc-bd.is-on .cc-bd-bar i{background:var(--accent)}
.cc-bd.is-want{border-color:var(--accent);box-shadow:0 0 0 1px var(--accent)}
.cc-bd-flag{
  position:absolute;right:-5px;top:-7px;
  padding:1px 5px;border-radius:5px;
  font-size:9px;font-weight:var(--fw7);letter-spacing:.04em;
  color:#fff;background:var(--accent);
}

@media (max-width:640px){
  .cc-panel{padding:16px 14px 20px;max-height:88vh;border-radius:14px}
  .cc-bdgrid{grid-template-columns:repeat(5,minmax(0,1fr));gap:7px}
  .cc-stat-txt b{font-size:19px}
}
@media (prefers-reduced-motion:reduce){
  .cc-want-bar i,.cc-bd{transition:none}
  .cc-panel{animation:none}
}

/* ============================================================
   二十五、V4.4.3 · 日期 / 时间选择控件
   ------------------------------------------------------------
   日期：自绘日历浮层（不依赖原生面板），造型比着浏览器默认面板做：
         ‹ 2026 年 11 月 ›  +  一二三四五六日  +  6×7 格子。
         点标题切到年月面板，翻年、点月，再回到日子。
   时间：HH : MM 两个大数字，滚轮 / 上下拖动一次走一格。
   ⚠️ 浮层挂在 body 上（position:fixed）：弹窗自己有 overflow:auto，
      挂在输入框里会被裁掉下半截。
   ============================================================ */

/* ---------- 日期输入 ---------- */
.pk-wrap{position:relative;display:block;min-width:0}
.pk-wrap .pk-input{
  padding-right:34px;cursor:pointer;
  font-variant-numeric:tabular-nums;letter-spacing:.01em;
}
.pk-wrap:hover .pk-ico{color:var(--accent-ink);background:var(--accent-wash)}
.pk-ico{
  position:absolute;right:5px;top:50%;transform:translateY(-50%);
  width:26px;height:26px;border-radius:8px;
  display:flex;align-items:center;justify-content:center;
  color:var(--ink-4);pointer-events:none;
  transition:color var(--dur),background var(--dur);
}
.pk-ico svg{display:block}

/* ---------- 日期浮层 ---------- */
.pk-pop{
  position:fixed;left:0;top:0;z-index:220;
  width:292px;padding:10px 10px 8px;box-sizing:border-box;
  border-radius:16px;border:1px solid var(--line);
  /* 日历要能读：卡片玻璃是 .44 透明度，浮层照着来会透出背后的表单文字，
     所以这里用实色表面，只留 1px 高光与投影做层次（和浏览器默认面板一致）。 */
  background:var(--surface);
  box-shadow:0 18px 44px rgba(12,16,28,.20),0 2px 6px rgba(12,16,28,.08),
    inset 0 1px 0 rgba(255,255,255,.7);
  animation:pkIn .14s ease both;
}
html[data-theme="dark"] .pk-pop{
  box-shadow:0 20px 50px rgba(0,0,0,.55),0 2px 8px rgba(0,0,0,.4),
    inset 0 1px 0 rgba(255,255,255,.06);
}
@keyframes pkIn{from{opacity:0}to{opacity:1}}
.pk-head{display:flex;align-items:center;gap:2px;padding:0 0 6px}
.pk-nav{
  width:28px;height:28px;flex:none;border:0;background:transparent;border-radius:9px;
  display:flex;align-items:center;justify-content:center;color:var(--ink-3);cursor:pointer;
  transition:background var(--dur),color var(--dur);
}
.pk-nav:hover{background:var(--surface-2);color:var(--ink)}
.pk-nav:disabled{opacity:.3;cursor:default}
.pk-title{
  flex:1;min-width:0;height:28px;border:0;background:transparent;border-radius:9px;
  font:inherit;font-size:13.5px;font-weight:var(--fw6);color:var(--ink);cursor:pointer;
  font-variant-numeric:tabular-nums;
}
.pk-title:hover{background:var(--surface-2)}
.pk-dow{display:grid;grid-template-columns:repeat(7,1fr);margin-bottom:2px}
.pk-dow span{text-align:center;font-size:11px;line-height:22px;color:var(--ink-4);font-weight:var(--fw5)}
.pk-days{display:grid;grid-template-columns:repeat(7,1fr);gap:2px}
.pk-day{
  position:relative;height:32px;border:0;background:transparent;border-radius:9px;
  font:inherit;font-size:13px;color:var(--ink);cursor:pointer;
  font-variant-numeric:tabular-nums;transition:background var(--dur),color var(--dur);
}
.pk-day:hover{background:var(--surface-2)}
.pk-day:focus-visible{outline:2px solid var(--accent);outline-offset:-2px}
.pk-day.out{color:var(--ink-4);opacity:.5}
.pk-day.today{color:var(--accent-ink);font-weight:var(--fw65)}
.pk-day.today::after{
  content:"";position:absolute;left:50%;bottom:4px;width:4px;height:4px;border-radius:50%;
  background:var(--accent);transform:translateX(-50%);
}
.pk-day.sel,.pk-day.sel:hover{background:var(--accent);color:#fff;font-weight:var(--fw65)}
.pk-day.sel::after{background:#fff}
.pk-foot{display:flex;justify-content:flex-end;margin-top:7px;padding-top:7px;border-top:1px solid var(--line-2)}
.pk-today{
  height:28px;padding:0 11px;border-radius:8px;cursor:pointer;
  border:1px solid var(--line);background:var(--surface);color:var(--ink-2);
  font:inherit;font-size:12px;font-weight:var(--fw5);
}
.pk-today:hover{border-color:var(--accent-line);color:var(--accent-ink);background:var(--accent-wash)}
.pk-yhead{display:flex;align-items:center;gap:2px;padding:0 0 8px}
.pk-yhead b{flex:1;text-align:center;font-size:13.5px;font-weight:var(--fw6);font-variant-numeric:tabular-nums}
.pk-months{display:grid;grid-template-columns:repeat(3,1fr);gap:6px;padding-bottom:4px;outline:none}
.pk-mon{
  height:40px;border:0;border-radius:10px;background:transparent;cursor:pointer;
  font:inherit;font-size:13px;color:var(--ink-2);font-variant-numeric:tabular-nums;
  transition:background var(--dur),color var(--dur);
}
.pk-mon:hover{background:var(--surface-2);color:var(--ink)}
.pk-mon.sel,.pk-mon.sel:hover{background:var(--accent-soft);color:var(--accent-ink);font-weight:var(--fw6)}

/* 窄屏：不跟输入框，居中来一块 —— 贴在底部会被手机键盘顶飞 */
@media (max-width:620px){
  .pk-pop.is-center{
    left:50% !important;top:50% !important;
    transform:translate(-50%,-50%);
    width:min(324px,calc(100vw - 28px));
    box-shadow:0 22px 60px rgba(0,0,0,.40);
  }
}

/* ---------- 时间输入 ---------- */
.tm-native{
  position:absolute !important;
  width:1px !important;height:1px !important;
  padding:0 !important;margin:0 !important;border:0 !important;
  opacity:0;pointer-events:none;
}
.tm-wrap{
  display:flex;align-items:center;justify-content:center;gap:0;
  height:52px;padding:0 6px;box-sizing:border-box;
  border:1px solid var(--field-line);border-radius:var(--r-sm);
  background:var(--surface);user-select:none;-webkit-user-select:none;
  transition:border-color var(--dur),background var(--dur);
}
.tm-wrap:hover{border-color:var(--accent-line)}
.tm-field{
  display:flex;align-items:center;justify-content:center;
  padding:0 10px;height:40px;border-radius:11px;cursor:ns-resize;
  touch-action:none;outline:none;
  transition:background var(--dur),box-shadow var(--dur);
}
.tm-field:hover{background:var(--surface-2)}
.tm-field.on,.tm-field.on:hover{background:var(--accent-soft);box-shadow:inset 0 0 0 1px var(--accent-line)}
.tm-field:focus-visible{box-shadow:inset 0 0 0 2px var(--accent)}
.tm-num{
  font-size:29px;line-height:1;font-weight:var(--fw65);color:var(--ink);
  font-variant-numeric:tabular-nums;letter-spacing:.02em;
}
.tm-field.on .tm-num{color:var(--accent-ink)}
.tm-colon{
  font-size:25px;font-weight:var(--fw6);color:var(--ink-4);
  transform:translateY(-2px);font-variant-numeric:tabular-nums;
}
@media (max-width:430px){
  .tm-field{padding:0 7px}
  .tm-num{font-size:26px}
}

/* ============================================================
   二十六、V4.4.3 · 宽屏铺满 + 二级内容提到一级
   ------------------------------------------------------------
   以前 >1700 把容器锁在 1680，2K / 4K 全屏时两侧各空掉近 1/5。
   现在只留视口比例边距：左右各 8vw（宽屏下限 40px、上限 320px），
   内容宽度永远占视口 84% 左右，正好落在你说的 7%~10% 之间。
   左侧贴靠时再做一次扣减，让左右视觉留白相等。
   ============================================================ */


/* ---------- 周报：折叠的「更多本周内容」在宽屏直接摊开 ----------
   它本来就是这页的正文（四象限 / 复盘 / 笔记 / 总评），
   只在窄屏收起来 —— 宽屏右栏本来就有地方，藏起来只会留下一片空白。 */
@media (min-width:1200px){
  .wk-more{border:0;background:none;box-shadow:none;padding:0}
  .wk-more::after{display:none}
  .wk-more .collapse-head{display:none}
  /* 四块排成 2×2：一条竖着摞下来会有 1300px，反而把右栏拉得比左栏长一倍 */
  /* 宽屏就是全部展开：没有折叠头（见上一行 display:none），下面这块一直铺成 2×2。
     这里必须带 !important —— [hidden]{display:none!important} 的优先级比它低，
     靠的就是这条把 collapsed 状态顶掉；写成 :not([hidden]) 反而会让宽屏只剩空栏。 */
  .wk-more .collapse-body{display:grid !important;grid-template-columns:1fr 1fr;padding:0;gap:12px}
  .wk-more .collapse-body>div{background:var(--inset);border:1px solid var(--inset-line);border-radius:var(--r-sm);padding:14px 16px}
  /* 两列之后每块只有 270~500px：标题和右侧说明挤一行会把「本周复盘」拆成两行，
     说明文字也会被省略号切断。这里让说明自己占一行，标题就能完整显示。 */
  .wk-more .collapse-body .card-title{flex-wrap:wrap;row-gap:3px}
  .wk-more .collapse-body .card-title .spacer{flex:1 1 100%;text-align:left;white-space:normal;line-height:1.5}
  /* 统计条同样：5 列在 270px 里每列只剩 50px，标签必然被截 */
  .wk-more .bh-stats{grid-template-columns:repeat(3,1fr);row-gap:10px}
  .wk-more .bh-item span{white-space:normal;line-height:1.35}
}

/* ---------- 长名字不再动不动就被省略号切掉 ----------
   双栏里每一栏都比以前宽，再单行截断就浪费了；这里只放宽有代表性的几处。 */
@media (min-width:1200px){
  .nb-title{
    display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;
    white-space:normal;line-height:1.45;
  }
  .pa-title{flex-wrap:wrap;row-gap:3px}
  .pa-title b{white-space:normal;line-height:1.45}
  .pa-meta{white-space:normal}
  .set-row .v{white-space:normal;line-height:1.5}
  .ai-mname{white-space:normal;line-height:1.4}
  /* 模型名不折行。GLM 的名字里带空格（"GLM 5.3 Flash"），宽屏下被
     「推荐 / 可读图 / 使用中」三个标签一挤就断成两行，比省略号还难看。
     真挤的时候让标签换行 —— 标签是加分项，名字是必须完好的。 */
  .ai-model-row .k{flex-wrap:wrap;row-gap:4px}
  .ai-model-row .ai-mname{white-space:nowrap;line-height:1.4}
  .q-name{white-space:normal;line-height:1.45}
}

/* ---------- 错题本右栏：没选中时的复习节奏 ---------- */
.rv7-card .rv7{display:grid;grid-template-columns:repeat(7,1fr);gap:7px;padding:12px 0 4px}
.rv7-day{
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;
  padding:9px 0 8px;border-radius:10px;
  background:var(--inset);border:1px solid var(--inset-line);
  box-shadow:var(--inset-shadow);
}
.rv7-day b{font-size:16px;font-weight:var(--fw65);color:var(--ink);line-height:1}
.rv7-day span{font-size:10.5px;color:var(--ink-4);line-height:1}
.rv7-day.zero b{color:var(--ink-4);opacity:.55}
.rv7-day.today{background:var(--accent-soft);border-color:var(--accent-line)}
.rv7-day.today b{color:var(--accent-ink)}
.rv7-day.today span{color:var(--accent-ink);font-weight:var(--fw6)}
.rv7-foot{
  display:flex;align-items:center;gap:5px;flex-wrap:wrap;
  font-size:11.5px;color:var(--ink-4);
  margin-top:9px;padding-top:9px;border-top:1px solid var(--line-2);
}
.rv7-foot .spacer{flex:1}
.rv7-foot b.warn{color:var(--red)}
.rv7-date{margin-left:auto;font-size:11px;color:var(--ink-4);font-variant-numeric:tabular-nums}
.rv7-recent{margin-top:12px}

/* ---------- 我的：左栏学习数据 ---------- */
.mine-stats .ms-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px 14px;margin-top:12px}
.ms-cell b{display:block;font-size:25px;font-weight:var(--fw65);line-height:1.1;letter-spacing:-.6px;color:var(--ink)}
.ms-cell b i{font-style:normal;font-size:13px;font-weight:var(--fw5);color:var(--ink-4);letter-spacing:0}
.ms-cell span{display:block;font-size:11.5px;color:var(--ink-4);margin-top:4px}
.ms-bar{height:6px;margin-top:15px;border-radius:4px;overflow:hidden;background:var(--inset);border:1px solid var(--inset-line)}
.ms-bar i{display:block;height:100%;border-radius:4px;background:var(--accent)}
.ms-foot{font-size:11.5px;color:var(--ink-4);margin-top:8px}
.ms-foot b{color:var(--ink-2);font-weight:var(--fw6)}
/* 深色下强调色是浅紫，白字压不住：选中日反色用深底 */
html[data-theme="dark"] .pk-day.sel,
html[data-theme="dark"] .pk-day.sel:hover{color:#0d1520}
html[data-theme="dark"] .pk-day.sel::after{background:#0d1520}

/* 2K 以上：计划表左栏不再是 400px 的窄条，长期规划的名字能完整读 */
@media (min-width:1700px){
  #panel-board.active{grid-template-columns:minmax(0,470px) minmax(0,1fr)}
}
/* ============================================================
   二十五、家长端（与学生端同版本，不再单独编号）
   ------------------------------------------------------------
   只读界面。颜色一律走 --accent 一族（body[data-page="parent*"]
   在 theme.css 里注入），这里不写死任何色值。
   ============================================================ */

/* ---------- 登录门的身份卡 ---------- */
.gate-role{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:2px 0 14px}
.gr-card{
  display:flex;align-items:center;gap:9px;
  padding:9px 11px;border-radius:12px;text-align:left;
  border:1px solid var(--field-line);background:var(--surface);
  cursor:pointer;transition:border-color var(--dur),box-shadow var(--dur),transform .12s;
}
.gr-card:hover{border-color:var(--accent);transform:translateY(-1px)}
.gr-card.on{border-color:var(--accent);box-shadow:0 0 0 2px var(--accent-soft);background:var(--accent-soft)}
.gr-ico{
  width:30px;height:30px;flex:none;border-radius:9px;
  display:inline-flex;align-items:center;justify-content:center;
  background:var(--surface-2);color:var(--ink-3);
}
.gr-card.on .gr-ico{background:var(--accent);color:var(--on-accent)}
.gr-txt{display:flex;flex-direction:column;gap:1px;min-width:0}
.gr-txt b{font-size:12.5px;font-weight:var(--fw6);color:var(--ink);line-height:1.3}
.gr-txt em{font-size:10.5px;font-style:normal;color:var(--ink-4);white-space:nowrap}
.gr-card.on .gr-txt b{color:var(--accent-ink)}

/* ---------- 家长端通用块 ---------- */
.pg-name{display:flex;align-items:center;gap:8px;font-size:12.5px;color:var(--ink-3)}
.pg-name b{font-size:14px;color:var(--ink);font-weight:var(--fw6)}
.pg-chip{
  display:inline-flex;align-items:center;gap:4px;padding:1px 7px;border-radius:8px;
  font-size:11px;background:var(--accent-soft);color:var(--accent-ink);font-weight:var(--fw6);
}
/* 与上周 / 上月比较：涨是好事用绿，跌用红（学习场景，不是股票） */
.pg-delta{font-size:11px;font-weight:var(--fw6)}
.pg-delta.up{color:var(--green)}
.pg-delta.down{color:var(--red)}
.pg-delta.flat{color:var(--ink-4)}

/* 每周一行：周次 · 完成率条 · 数字 */
.pg-row{display:flex;align-items:center;gap:9px;padding:6px 0;border-bottom:1px solid var(--line)}
.pg-row:last-child{border-bottom:0}
.pg-row-w{width:86px;flex:none;font-size:11.5px;color:var(--ink-3)}
.pg-row-bar{flex:1;height:7px;border-radius:4px;background:var(--inset);overflow:hidden}
.pg-row-bar i{display:block;height:100%;border-radius:4px;background:var(--accent)}
.pg-row-v{width:96px;flex:none;text-align:right;font-size:11.5px;color:var(--ink-2)}
.pg-row-v b{font-weight:var(--fw7);color:var(--ink)}

/* 明细表：时间 · 事项 · 分数 */
.pg-table{width:100%;border-collapse:collapse;font-size:12px}
.pg-table th{
  text-align:left;font-weight:var(--fw6);font-size:11px;color:var(--ink-4);
  padding:0 8px 6px;border-bottom:1px solid var(--line);white-space:nowrap;
}
.pg-table td{padding:7px 8px;border-bottom:1px solid var(--line);color:var(--ink-2)}
.pg-table tr:last-child td{border-bottom:0}
.pg-table td.num{text-align:right;font-variant-numeric:tabular-nums}
.pg-table .plus{color:var(--green);font-weight:var(--fw6)}
.pg-table .minus{color:var(--red);font-weight:var(--fw6)}
.pg-scroll{max-height:430px;overflow:auto;margin:0 -4px}
/* 空态不再另立一套：直接用全站共享的 .empty（同一个字号 / 内边距 / 颜色）。
   家长端以前自己写了个 12px 的小号版本，同一句「还没有成绩」在两张卡里
   排出来不一样高。 */

/* 大考成绩：一行一次考试，各科用色块点 */
.pg-exam{display:flex;align-items:center;gap:10px;padding:8px 0;border-bottom:1px solid var(--line)}
.pg-exam:last-child{border-bottom:0}
.pg-exam-main{flex:1;min-width:0}
.pg-exam-main b{font-size:12.5px;color:var(--ink);font-weight:var(--fw6)}
/* ⚠️ 只挑直接子级：里面那个 <span class="pg-delta"> 也是 span，
   用后代选择器会把涨跌数字也变成块级，掉到第三行去。 */
.pg-exam-main>span{display:block;font-size:11px;color:var(--ink-4);margin-top:1px}
.pg-exam-rate{font-size:15px;font-weight:var(--fw7);color:var(--accent-ink);font-variant-numeric:tabular-nums}

/* 家长端不做编辑，工具条一律不出现 */
body[data-page^="parent"] .pblock-tools{display:none}

/* 家长端按钮渐变（放在 styles.css 而不是 theme.css：
   theme.css 里不许出现 --accent-grad，v3 有断言钉着；
   points 页的先例也是写在这里）。 */
body[data-page="parentOverview"]{--accent-grad:linear-gradient(135deg,#3730a3 0%,#6366f1 100%)}
body[data-page="parentExam"]{--accent-grad:linear-gradient(135deg,#312e81 0%,#4f46e5 100%)}
body[data-page="parentPoints"]{--accent-grad:linear-gradient(135deg,#5b21b6 0%,#7c3aed 100%)}
body[data-page="parentAccount"]{--accent-grad:linear-gradient(135deg,#1e3a8a 0%,#2563eb 100%)}
html[data-theme="dark"] body[data-page="parentOverview"]{--accent-grad:linear-gradient(135deg,#6366f1 0%,#a5b4fc 100%)}
html[data-theme="dark"] body[data-page="parentExam"]{--accent-grad:linear-gradient(135deg,#818cf8 0%,#c7d2fe 100%)}
html[data-theme="dark"] body[data-page="parentPoints"]{--accent-grad:linear-gradient(135deg,#a78bfa 0%,#ddd6fe 100%)}
html[data-theme="dark"] body[data-page="parentAccount"]{--accent-grad:linear-gradient(135deg,#60a5fa 0%,#bfdbfe 100%)}

/* 家长端的列表行。不复用学生的 .sub-row：那套类名被测试用
   querySelectorAll('.sub-row') 数子目标，两边混用会让断言数错数。 */
.pg-item{display:flex;align-items:center;gap:8px;padding:7px 0;border-bottom:1px solid var(--line);font-size:12.5px}
/* 设置行里的 ✕ 用 .mini-btn 那颗图标，但要给足点击面积：
   计划方格里的 18px 是「嵌在方块里的小角标」，这里是行尾唯一的操作。 */
.pg-item .mini-btn{width:24px;height:24px;margin-top:0;opacity:.75}
.pg-item .mini-btn:hover{opacity:1}
.pg-item.on{background:var(--accent-soft);border-radius:8px;padding-left:8px;padding-right:8px}
/* 「我的」页顶部的身份条：头像 + 名字 + 邮箱 + 版本徽章，一行读完 */
.pg-me{display:flex;align-items:center;gap:10px;min-width:0}
.pg-me-txt{display:flex;flex-direction:column;min-width:0;line-height:1.35}
.pg-me-txt b{font-size:14px;color:var(--ink);font-weight:var(--fw7)}
.pg-me-txt span{font-size:12px;color:var(--ink-4);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pg-me>.pg-chip{margin-left:auto;flex:none}
.pg-item:last-child{border-bottom:0}
.pg-item-t{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--ink-2)}
.pg-item-v{flex:none;font-size:11.5px;color:var(--ink-4);font-variant-numeric:tabular-nums}
.pg-dot{width:6px;height:6px;flex:none;border-radius:50%;background:var(--accent);opacity:.55}

/* ============================================================
   二十六、复盘双 tab / 自由计划 / 小菜单 / 主题浮层 / 打印
   ============================================================ */

/* ---------- 复盘：周报 / 大复盘 ---------- */
.rv-tabs{
  display:inline-flex;align-items:center;gap:2px;
  padding:3px;border-radius:11px;background:var(--inset);
  border:1px solid var(--inset-line);
  margin:2px 0 12px;
}
.rv-tab{
  border:0;background:transparent;color:var(--ink-3);
  font-size:12.5px;font-weight:var(--fw6);padding:5px 14px;border-radius:8px;
  transition:background var(--dur),color var(--dur);
}
.rv-tab.on{background:var(--surface);color:var(--accent-ink);box-shadow:0 1px 3px rgba(16,20,30,.08)}
.rv-body{display:contents}
@media (min-width:1200px){
  #panel-weekly.active > .rv-tabs{grid-column:1/-1;justify-self:start}
}

/* 大复盘：一科一对（优点 / 缺点），缺点必须按科写 */
.br-cap{font-size:11px;font-weight:var(--fw6);color:var(--ink-4);margin:2px 0 8px;letter-spacing:.02em}
.br-pair{
  display:grid;grid-template-columns:52px 1fr 1fr;gap:8px;align-items:end;
  padding:6px 0;border-bottom:1px solid var(--line);
}
.br-pair:last-of-type{border-bottom:0}
.br-sub{font-size:12.5px;color:var(--ink-2);padding-bottom:8px;font-weight:var(--fw6)}
.br-acts{margin-top:10px;border-top:1px solid var(--line);padding-top:6px}
@media (max-width:720px){
  .br-pair{grid-template-columns:1fr;gap:4px}
  .br-sub{padding-bottom:0}
}

/* ---------- 自由计划 ---------- */
.free-wrap{margin-top:12px}
.free-count{margin-left:auto;font-size:11px;color:var(--ink-4)}
.free-row{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:8px}
.free-card{
  padding:9px 10px;border-radius:var(--r-md);
  background:var(--surface-2);border:1px solid var(--line);
  border-left:3px solid var(--q-base,var(--accent));
}
.free-card.is-done{opacity:.62}
.free-top{display:flex;align-items:center;gap:6px}
.free-top b{flex:1;min-width:0;font-size:12.5px;font-weight:var(--fw6);color:var(--ink);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.free-bar{height:5px;border-radius:3px;background:var(--inset);margin:7px 0 6px;overflow:hidden}
.free-bar i{display:block;height:100%;border-radius:3px;background:var(--q-base,var(--accent))}
.free-foot{display:flex;align-items:center;justify-content:space-between;gap:6px}
.free-foot .num{font-size:11.5px;color:var(--ink-3);font-variant-numeric:tabular-nums}
.free-ok{font-size:11px;color:var(--green);font-weight:var(--fw6)}
.free-card .mini-btn{opacity:.4}
.free-card:hover .mini-btn{opacity:1}

/* ---------- 小菜单（点方块 / 点格子） ---------- */
.ctx-menu{
  position:fixed;z-index:82;min-width:150px;padding:5px;
  border-radius:12px;background:var(--surface);border:1px solid var(--line);
  box-shadow:0 18px 44px -22px rgba(0,0,0,.6);
}
.ctx-item{
  display:block;width:100%;text-align:left;
  padding:7px 10px;border:0;border-radius:8px;background:transparent;
  font-size:12.5px;color:var(--ink-2);
}
.ctx-item:hover{background:var(--accent-soft);color:var(--accent-ink)}
.ctx-item.danger{color:var(--red)}
.ctx-item.danger:hover{background:var(--red-bg);color:var(--red)}
.ctx-sep{display:block;height:1px;margin:4px 6px;background:var(--line)}

/* ---------- 主题浮层：向右拖按钮拉出来 ---------- */
.theme-pop{
  position:fixed;z-index:82;padding:8px;border-radius:14px;
  background:var(--surface);border:1px solid var(--line);
  box-shadow:0 22px 52px -26px rgba(0,0,0,.6);
  max-width:calc(100vw - 16px);
  /* 进出都走同一对过渡：起手略微上移 + 缩小，落定时回到原位。
     位移只有 6px —— 面板是贴在按钮下面的，飞太远反而像另一个浮层。
     200ms 是「看得见但不挡路」的长度，与 JS 里的 EXIT 常量对齐。 */
  opacity:0;transform:translateY(-6px) scale(.96);
  transition:opacity .18s ease,transform .22s cubic-bezier(.22,.7,.3,1);
  will-change:opacity,transform;
}
.theme-pop.show{opacity:1;transform:none}
.theme-pop .theme-pick{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;
  width:min(320px,calc(100vw - 32px))}
.theme-pop .tpick{width:100%}
.theme-pop .tp-prev{height:30px}
/* 面板开着时按钮的悬停气泡必须让位：箭头正好压在面板上 */
[data-theme-switch][aria-expanded="true"]::after,
[data-theme-switch][aria-expanded="true"]::before{display:none !important}
/* 面板打开期间顶栏别自动收起，否则按钮跑了、面板悬在半空 */
body.theme-pop-open .appbar{pointer-events:auto}

/* ---------- 家长端：空态与小组标题 ---------- */
.pg-guard{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:16px}
.pg-guard-t{font-size:13px;color:var(--ink-3)}
.pg-sub{margin:12px 0 4px;font-size:11px;font-weight:var(--fw6);color:var(--ink-4)}

/* ---------- 家长端：总体页三条趋势 ---------- */
/* 只有三样东西：一个大数、一句它在说什么、一根涨跌。图表不画坐标轴 ——
   家长看的是「比上次好还是差」，不是读图。 */
.ov-head{display:flex;align-items:baseline;gap:8px;flex-wrap:wrap;margin:2px 0 14px}
.ov-big{font-size:27px;line-height:1;font-weight:var(--fw7);color:var(--ink);font-variant-numeric:tabular-nums}
.ov-big i{font-style:normal;font-size:13px;font-weight:var(--fw6);color:var(--ink-4);margin-left:1px}
.ov-sub{font-size:11.5px;color:var(--ink-4)}
.ov-head .pg-delta{margin-left:auto}
.ov-bars{display:flex;align-items:flex-end;gap:8px;padding:0 2px}
.ov-bar{flex:1;min-width:0;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:3px}
.ov-bar i{
  display:block;width:100%;max-width:38px;border-radius:5px 5px 2px 2px;
  background:linear-gradient(180deg,var(--accent) 0%,var(--accent-glide) 100%);
  transition:opacity var(--dur);
}
.ov-bar:hover i{opacity:.82}
.ov-bar.is-neg i{background:linear-gradient(180deg,var(--red) 0%,var(--red-bg) 100%)}
/* 正负双向柱：零线固定在中线，上面长正、下面长负 */
.ov-z{position:relative;width:100%;height:92px;flex:none}
.ov-z::after{content:'';position:absolute;left:0;right:0;top:50%;height:1px;background:var(--line)}
.ov-z-top,.ov-z-bot{display:flex;height:50%;overflow:hidden}
.ov-z-top{align-items:flex-end}
.ov-z-bot{align-items:flex-start}
.ov-z-top i,.ov-z-bot i{
  display:block;width:100%;max-width:38px;margin:0 auto;
  background:linear-gradient(180deg,var(--accent) 0%,var(--accent-glide) 100%);
}
.ov-z-top i{border-radius:5px 5px 0 0}
.ov-z-bot i{border-radius:0 0 2px 2px;background:linear-gradient(180deg,var(--red-bg) 0%,var(--red) 100%)}
.ov-bar.is-z{align-items:center}
.ov-bar-v{font-size:10.5px;color:var(--ink-3);font-variant-numeric:tabular-nums;white-space:nowrap}
.ov-bar.is-neg .ov-bar-v{color:var(--red)}
.ov-bar-x{font-size:10px;color:var(--ink-4);font-variant-numeric:tabular-nums;white-space:nowrap}

/* ---------- 假期工作表：一天一张小表，时间逐天 ---------- */
/* 每天的时段是这一天自己的（10/1 出门、10/3 在家），所以不做跨天的大表格。
   每一行左边是时间、右边是事；时间是**引导**，不显示容量、不算超额。 */
.hol-prog{font-size:11.5px;color:var(--ink-3);font-variant-numeric:tabular-nums}
/* 一天一张，宽度给到 300px 才放得下「时间 + 事项 + 加号」；
   屏幕窄就单列，宽就并排两三张。 */
.hol-days{
  display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));
  gap:10px;margin-top:10px;
}
.hol-srows{margin-top:5px}
.hol-srow{display:flex;gap:7px;padding:3px 0;border-top:1px solid var(--line)}
.hol-srow-t{
  flex:0 0 auto;width:78px;display:flex;align-items:center;gap:2px;
  padding-top:1px;
}
.hol-srow-tm{
  font-size:10.5px;color:var(--ink-3);font-variant-numeric:tabular-nums;
  white-space:nowrap;padding:1px 3px;margin:-1px -1px;border-radius:5px;
  transition:background var(--dur),color var(--dur);
}
.hol-srow-tm:hover{background:var(--surface-3);color:var(--ink)}
.hol-srow-t .mini-btn{width:14px;height:14px;font-size:9px;opacity:0;margin-top:0}
.hol-srow:hover .mini-btn,.hol-srow-t .mini-btn:focus-visible{opacity:.8}
@media (hover:none){ .hol-srow-t .mini-btn{opacity:.4} }
.hol-srow-b{flex:1;min-width:0;display:flex;flex-direction:column;gap:1px}
/* 空行的 +：平时淡着，鼠标进这一行才亮 —— 一屏几十条虚线框会变成马赛克 */
.hol-plus{
  align-self:flex-start;height:18px;margin:1px 0 2px;padding:0 7px;
  border:1px dashed var(--field-line);border-radius:6px;background:transparent;
  color:var(--ink-4);font-size:12px;line-height:16px;opacity:0;
  transition:opacity var(--dur),color var(--dur),border-color var(--dur),background var(--dur);
}
.hol-srow-b.is-empty .hol-plus{opacity:.45}
.hol-srow:hover .hol-plus,.hol-plus:focus-visible{opacity:1}
.hol-plus:hover{color:var(--accent-ink);border-color:var(--accent);background:var(--accent-wash)}
@media (hover:none){ .hol-plus{opacity:.5} }
.hol-pool-mini{margin-top:6px;border-top:1px dashed var(--line);padding-top:5px}
.hol-pool-t{font-size:11px;color:var(--ink-4);margin-bottom:3px}
.hol-day{
  display:flex;flex-direction:column;gap:5px;
  padding:8px 9px 7px;border-radius:var(--r-md);
  background:var(--surface-2);border:1px solid var(--line);
}
.hol-day.today{border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-wash)}
/* 整段排开之后，跨周假期里会有已经过去的那几天：压暗一档，
   免得空着的日期卡看起来像「加载失败」 */
.hol-day.is-past{opacity:.55}
.hol-day.is-past .hol-day-head b{color:var(--ink-3)}
.hol-day-head{display:flex;align-items:center;gap:5px;flex-wrap:wrap;min-height:18px}
.hol-day-head b{font-size:12.5px;font-weight:var(--fw6);color:var(--ink);font-variant-numeric:tabular-nums}
.hol-day-cnt{font-size:11px;color:var(--ink-4);font-variant-numeric:tabular-nums;margin-left:auto}
.hol-row-add{
  height:20px;padding:0 6px;border-radius:6px;
  border:1px dashed var(--field-line);background:transparent;
  color:var(--ink-4);font-size:10.5px;line-height:18px;
  transition:color var(--dur),border-color var(--dur),background var(--dur);
}
.hol-row-add:hover{color:var(--accent-ink);border-color:var(--accent);background:var(--accent-wash)}
/* 时段弹窗标题里的日期：改的是哪一天，必须在标题里一眼看到 */
.dlg-day{font-size:11.5px;color:var(--ink-4);font-weight:var(--fw5);margin-left:6px}
.hol-wd{font-size:11px;color:var(--ink-4)}
.hol-tag{
  font-style:normal;font-size:10px;line-height:1.6;padding:0 5px;border-radius:5px;
  background:var(--accent-soft);color:var(--accent-ink);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%;
}
.hol-tag.now{background:var(--accent);color:var(--surface)}
.hol-list{display:flex;flex-direction:column}
.hol-item{display:flex;align-items:center;gap:6px;padding:3px 0}
.hol-item + .hol-item{border-top:1px solid var(--line)}
/* 圆点勾选框：与计划方块里的 ✓ 是同一套语义，形状不同是因为这里没有「块」 */
.hol-check{
  flex:0 0 auto;width:17px;height:17px;padding:0;border-radius:50%;
  border:1.5px solid var(--field-line);background:var(--surface);
  display:inline-flex;align-items:center;justify-content:center;
  color:transparent;transition:background var(--dur),border-color var(--dur),color var(--dur);
}
.hol-check svg{width:11px;height:11px;display:block}
.hol-check:hover{border-color:var(--accent)}
.hol-item.done .hol-check{background:var(--accent);border-color:var(--accent);color:var(--surface)}
.hol-name{flex:1;min-width:0;font-size:12.5px;color:var(--ink-2);overflow-wrap:anywhere}
.hol-item.done .hol-name{color:var(--ink-4);text-decoration:line-through}
/* 删除按钮平时半隐：手机上不会 hover，压到 0 就永远删不掉 */
.hol-item .mini-btn{width:24px;height:24px;margin-top:0;opacity:.35}
.hol-item:hover .mini-btn,.hol-item .mini-btn:focus-visible{opacity:1}
.hol-add{
  align-self:flex-start;margin-top:2px;
  height:28px;padding:0 9px;border-radius:7px;
  border:1px dashed var(--field-line);background:transparent;color:var(--ink-4);
  font-size:12px;line-height:26px;
  transition:color var(--dur),border-color var(--dur),background var(--dur);
}
.hol-add:hover{color:var(--accent-ink);border-color:var(--accent);background:var(--accent-wash)}
.hol-new{display:flex;align-items:center;gap:5px;margin-top:2px}
.hol-new .input{flex:1;min-width:0;height:30px;font-size:12px;padding:0 8px}
.hol-new .mini-btn{width:24px;height:24px;margin-top:0}

/* 计划表表头里的假期角标：不动列宽，只在日期上压一个小标记 */
.plan-grid th.is-hol{background:var(--accent-soft)}
.plan-grid th .th-hol{
  display:inline-block;font-style:normal;font-size:9px;line-height:1.5;
  padding:0 3px;margin-left:3px;border-radius:4px;vertical-align:1px;
  background:var(--accent);color:var(--surface);
}
.ph-chip.hol-chip{background:var(--accent-soft);color:var(--accent-ink);border-color:var(--accent-line)}
/* 周选择行右侧的「假期」小按钮：地方假从这里进，不占正文位置 */
.ph-hol{
  margin-left:auto;flex:none;
  height:26px;padding:0 9px;border-radius:7px;
  border:1px solid var(--line);background:var(--surface);color:var(--ink-3);
  font-size:11.5px;font-weight:var(--fw6);
  transition:color var(--dur),border-color var(--dur),background var(--dur);
}
.ph-hol:hover{color:var(--accent-ink);border-color:var(--accent);background:var(--accent-wash)}
/* 假期的出处：内置写「国务院办公厅」，自定义写「自定义 · 地区 · 公告」 */
.hol-src{
  margin:2px 0 0;font-size:11px;color:var(--ink-4);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
.hol-rows{margin-top:14px;border-top:1px solid var(--line);padding-top:8px}
.hol-row{display:flex;align-items:center;gap:8px;padding:6px 0;border-bottom:1px solid var(--line)}
.hol-row:last-child{border-bottom:0}
.hol-row-t{flex:1;min-width:0;display:flex;flex-direction:column;gap:1px}
.hol-row-t b{font-size:12.5px;color:var(--ink);font-weight:var(--fw6)}
.hol-row-t em{font-style:normal;font-size:11px;color:var(--ink-4);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.hol-row .mini-btn{width:24px;height:24px;margin-top:0;opacity:.5}
.hol-row:hover .mini-btn{opacity:1}

/* ---------- 打印选择 ---------- */
.print-sizes{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:12px 0 4px}
.print-opt{
  display:flex;flex-direction:column;align-items:flex-start;gap:4px;
  padding:10px;border-radius:12px;text-align:left;
  border:1px solid var(--field-line);background:var(--surface);
  transition:border-color var(--dur),box-shadow var(--dur);
}
.print-opt:hover{border-color:var(--accent)}
.print-opt.on{border-color:var(--accent);box-shadow:0 0 0 2px var(--accent-soft);background:var(--accent-soft)}
.print-opt b{font-size:12.5px;color:var(--ink);font-weight:var(--fw6)}
.print-opt em{font-size:11px;font-style:normal;color:var(--ink-4)}
.po-prev{display:block;width:100%;height:44px;border-radius:6px;margin-bottom:4px;
  border:1px solid var(--line);background:var(--inset);position:relative;overflow:hidden}
.po-prev::after{content:'';position:absolute;border-radius:3px}
.po-a4::after{left:6%;right:6%;top:22%;bottom:22%;background:var(--surface);
  box-shadow:inset 0 0 0 1px var(--line)}
.po-a5::after{left:6%;right:6%;top:12%;height:38%;background:var(--surface);
  box-shadow:inset 0 0 0 1px var(--line)}

/* ---------- 导航页面设置（我的 · 设置区） ----------
   底栏是多选，所以容器要能换行；.seg-mini 本身是 nowrap 的单选条。 */
.seg-mini.seg-wrap{flex-wrap:wrap;justify-content:flex-end;max-width:100%}
.seg-mini.seg-wrap button{padding:0 8px}
/* 竖排行里的分段控件不要吃 .set-row .seg-mini 的 margin-left:auto ——
   column 方向下它会把控件推到右边，缩进看着像缩错了一级。 */
.set-row-block .seg-mini{margin-left:0}

/* ---------- 时间段临时合并（跨时段借时间） ----------
   表格外面套一层 wrap：连线要画在表格上，又要跟着表格一起横向滚动，
   所以定位的参照物是「表格自己」而不是滚动容器。 */
.plan-grid-wrap{position:relative;display:inline-block;min-width:780px;vertical-align:top}
.merge-layer{
  position:absolute;left:0;top:0;width:100%;height:100%;
  overflow:visible;pointer-events:none;z-index:3;
}
.merge-path{
  fill:none;stroke:var(--accent);stroke-width:2;stroke-linecap:round;
  opacity:.85;
}
/* 正在拉的那条线用虚线：实线是「已经合并」的既定状态 */
.merge-draft{stroke-dasharray:5 4;opacity:.9}
/* 可合并的格子：光标是十字（提示「这里可以借时间」） */
.slot-cell.mergeable{cursor:crosshair}
/* 拉线期间全站禁止选中：否则浏览器会拉出一片蓝色文本选区，
   看起来就像「连线变成了选中」，而且会盖住正在画的那条虚线。 */
body.wb-merging,body.wb-merging *{
  user-select:none!important;-webkit-user-select:none!important;
  cursor:crosshair!important;
}
/* 连线把手：贴在格子右下角的一小竖条，三个点表示「可以拎起来」。
   它是唯一能发起拉线的入口 —— 格子里的方块铺满整格且是 draggable 的，
   在方块上按住拖会变成 HTML5 原生拖方块，抢走指针事件。
   放右下角：右上角是方块自己的「修改/删除」按钮（.pblock-tools），
   放那儿会互相遮挡。 */
.merge-handle{
  position:absolute;right:1px;bottom:1px;z-index:4;
  width:11px;height:30px;
  display:flex;flex-direction:column;justify-content:center;align-items:center;gap:2.5px;
  border-radius:5px;cursor:grab;touch-action:none;
  background:var(--accent-soft);
  border:1px solid var(--accent-line);
  opacity:.8;transition:opacity .15s,background .15s;
  /* 把手上不能选中文字、也不能被浏览器当成可拖拽对象 */
  user-select:none;-webkit-user-select:none;-webkit-user-drag:none;
}
.merge-handle:hover{opacity:1;background:var(--accent-line)}
.merge-handle:active{cursor:grabbing}
.merge-handle i{
  display:block;width:3px;height:3px;border-radius:50%;
  background:var(--accent-ink);opacity:.8;
}
/* 连线把手：贴在格子左缘的一小竖条，三个点表示「可以拎起来」。
   它是唯一能发起拉线的入口 —— 格子里的方块铺满整格且是 draggable 的，
   在方块上按住拖会变成 HTML5 原生拖方块，抢走指针事件。
   放左缘是因为连线的语义是「上下两格接成一段」，竖线天然在侧面。 */
.merge-handle{
  position:absolute;left:2px;top:50%;transform:translateY(-50%);z-index:4;
  width:12px;height:32px;
  display:flex;flex-direction:column;justify-content:center;align-items:center;gap:2.5px;
  border-radius:6px;cursor:grab;touch-action:none;
  background:var(--accent-soft);
  border:1px solid var(--accent-line);
  opacity:.85;transition:opacity .15s,background .15s;
  /* 把手上不能选中文字、也不能被浏览器当成可拖拽对象 */
  user-select:none;-webkit-user-select:none;-webkit-user-drag:none;
}

/* 已合并的上下两格：边框连成一段，中间的横线去掉 */
.slot-cell.merged-top{border-bottom-color:transparent}
.slot-cell.merged-bot{border-top-color:transparent}
.slot-cell.merged-top,.slot-cell.merged-bot{background:var(--accent-soft)}
/* 合并态里格子底色和把手一样深，把手换个亮色才看得见 */
.slot-cell.merged-top .merge-handle,
.slot-cell.merged-bot .merge-handle{
  background:var(--surface);border-color:var(--accent);
}
.slot-cell.merged-top .merge-handle i,
.slot-cell.merged-bot .merge-handle i{background:var(--accent-ink);opacity:1}
/* ⇅ 角标放左上角：那里没有内容（方块从把手槽右侧起铺）。
   放右下角会压住时长文字的第二行「上限 4 小时」。 */
.slot-merge-mark{
  position:absolute;left:2px;top:1px;font-size:11px;line-height:1;
  color:var(--accent-ink);opacity:.85;pointer-events:none;
}
/* 有把手的格子：方块列表左侧留出一条专属槽位，让开把手的位置。
   只给 .slot-list 加，不动格子本身的 padding ——
   否则右对齐的时长文字(.slot-used)也会被挤窄，文字会被裁掉。
   （不用 :has()，老浏览器不支持） */
.slot-cell.has-handle .slot-list{padding-left:18px}
/* 连线把手：贴在格子左缘的一小竖条，三个点表示「可以拎起来」。
   它是唯一能发起拉线的入口 —— 格子里的方块铺满整格且是 draggable 的，
   在方块上按住拖会变成 HTML5 原生拖方块，抢走指针事件。
   放左缘是因为连线的语义是「上下两格接成一段」，竖线天然在侧面。 */
.merge-handle{
  position:absolute;left:2px;top:50%;transform:translateY(-50%);z-index:4;
  width:12px;height:32px;
  display:flex;flex-direction:column;justify-content:center;align-items:center;gap:2.5px;
  border-radius:6px;cursor:grab;touch-action:none;
  background:var(--accent-soft);
  border:1px solid var(--accent-line);
  opacity:.85;transition:opacity .15s,background .15s;
  /* 把手上不能选中文字、也不能被浏览器当成可拖拽对象 */
  user-select:none;-webkit-user-select:none;-webkit-user-drag:none;
}
/* 端侧互斥：电脑端只给电脑端的选项，手机端只给手机端的。
   不这么做的话，用户在电脑上把「手机首屏」改成今日，换到手机上毫无变化
   —— 因为偏好存在 localStorage，本来就不跨设备。 */
.nav-mb{display:none}
@media (max-width:900px){
  .nav-pc{display:none}
  .nav-mb{display:flex}
}


/* ============================================================
   二十七、打印（两套排列）
   ------------------------------------------------------------
   必须放在文件最后：前面 2617 行的 .pcol-*{display:contents} 与
   2648 的 .plan-grid{min-width:780px} 都在后面，按顺序会把这里的规则盖掉。
   ============================================================ */
@media print{
  html,body{background:#fff !important}
  /* 色雾与跟手光在纸上是两块脏底 */
  body::before,body::after{display:none !important}
  .appbar,.mobar,.page-actions,.split-add,.pb-actions,.pb-head,.pool,.pool-add,
  .toast,.ai-prog,.sync-pill,.theme-btn,.theme-pop,.ctx-menu,.modal-mask,#errBanner,
  .mini-btn,.pblock-tools,.ck-progress,.plan-card-2,.free-wrap,.rv-tabs,.page-head,
  /* 假期表不上纸：纸面只留那张按时间段排的工作表，多印一张会把行高挤扁 */
  .hol-card,
  .print-sizes{display:none !important}
  .main{padding:0;max-width:none}
  .panel{display:none !important}
  .panel.active{display:block !important}
  /* 真正生效的左栏隐藏：#boardSummary/#boardLong 在 .pcol-l 里面，
     旧那条 #panel-board>#boardSummary 勾不到任何东西（字符串留着，v3 有断言） */
  body[data-page="board"] #panel-board>.pcol-l{display:none !important}
  body[data-page="board"] #panel-board>#boardSummary,
  body[data-page="board"] #panel-board>#boardLong{display:none !important}

  .print-only{display:block;font-weight:var(--fw7);color:#000;margin:0 0 3mm}
  #boardPlan>.card{border:0;box-shadow:none;padding:0;background:#fff}
  .grid-scroll{overflow:visible;padding:0}
  .plan-grid{width:100%;min-width:0;table-layout:fixed;border-collapse:collapse}
  .plan-grid tr{break-inside:avoid;page-break-inside:avoid}
  .plan-grid th,.plan-grid td{border-color:#c9cdd6 !important}
  .pblock,.stage-row,.sub-row{break-inside:avoid;page-break-inside:avoid}
  /* 深色主题直接打印会整页黑底：四象限色条 --q-base 保留，其余一律压回浅色 */
  .pblock{--q-soft:#f4f6fb !important;--q-line:#c9cdd6 !important;--q-ink:#151a24 !important}
  .pblock.done{--q-soft:#e7f6ee !important;--q-line:#c3e6d4 !important;--q-ink:#05583a !important}
  .pblock::after{display:none !important}
  .pblock.ck{box-shadow:none !important;animation:none !important}
  .pblock.locked-day{opacity:1 !important}
  .plan-grid thead th{background:#f4f6fa !important;color:#111 !important}
  .slot-col{background:#f4f6fa !important}
  .slot-time,.slot-cap{color:#333 !important}
  .pblock,th,td,.slot-col{-webkit-print-color-adjust:exact;print-color-adjust:exact}

  /* 铺满一张 A4（横向）：字号照着 A4 放，行高由 JS 按行数算 */
  body.print-a4 .plan-grid td{height:var(--print-row-h,30mm)}
  body.print-a4 .print-only{font-size:13pt}
  body.print-a4 .plan-grid th{font-size:8.5pt;padding:1.2mm .5mm}
  body.print-a4 .plan-grid th .dnum{font-size:7.5pt}
  body.print-a4 .slot-col{width:22mm}
  body.print-a4 .slot-time{font-size:8.5pt}
  body.print-a4 .slot-cap{font-size:7.5pt}
  body.print-a4 .pblock{padding:.8mm 1.2mm}
  body.print-a4 .pblock-name{font-size:9pt;line-height:1.25}
  body.print-a4 .pblock-meta{font-size:7.5pt}

  /* 半张 A4（210×148）：一列只有 25mm，容量说明与第二条 meta 全部让位 */
  body.print-a5 .plan-grid td{height:var(--print-row-h,23mm)}
  body.print-a5 .print-only{font-size:10pt}
  body.print-a5 .plan-grid th{font-size:7pt;padding:.8mm .3mm}
  body.print-a5 .plan-grid th .dnum{font-size:6.5pt}
  body.print-a5 .slot-col{width:18mm}
  body.print-a5 .slot-time{font-size:7pt}
  body.print-a5 .slot-cap{display:none !important}
  /* 半张只有 136mm 高，一格里塞三块就会顶到第二页：把每一块压到最小 */
  body.print-a5 .slot-cell{padding:.6mm}
  body.print-a5 .slot-list{gap:.5mm}
  body.print-a5 .pblock{padding:.5mm .7mm}
  body.print-a5 .pblock-name{font-size:7pt;line-height:1.15}
  body.print-a5 .pblock-meta{font-size:6pt;line-height:1.1;margin-top:0}
  body.print-a5 .pblock-meta span:nth-child(n+2){display:none}
}

/* 打印时卡片不留外边距：多出 14px 就会把最后一行挤到第二页 */
@media print{
  #boardPlan>.card{margin:0 !important}
  .panel.active>.pcol,.panel.active>.rv-body{margin:0 !important}
}

/* 大复盘的得分条要同时放「得分/满分 · 得分率 · 班排」，96px 会折成两行 */
#brSubjects .pg-row-v{width:auto;white-space:nowrap}

/* ================= 感谢名单 =================
   登录页底部。只有「主动勾选愿意上榜」的 VIP 才会出现，
   所以它大多数时候是空的 —— 空则整块 hidden，不留一条空线。 */
.wall-thank{margin:16px auto 0;max-width:520px;text-align:center}
.wt-title{font-size:11.5px;color:var(--ink-3);letter-spacing:.04em;margin-bottom:8px}
.wt-list{display:flex;flex-wrap:wrap;justify-content:center;gap:6px}
.wt-chip{
  display:inline-flex;align-items:center;gap:4px;
  padding:3px 9px;border-radius:999px;
  font-size:12px;color:var(--ink-2);
  background:var(--accent-soft);border:1px solid var(--line);
}
.wt-chip i{font-style:normal;font-size:10px;color:var(--accent-ink);opacity:.85}

/* ---------- 登录后的常驻名单条 ----------
   不走 fixed：正文右侧放一块浮层，在任何一屏宽度下都会压住内容。
   这里占一条 40px 高的横带，横向可滑，页面切换时它始终在。
   免费版才显示，判定在 core.js 的 renderVipWall 里。 */
.home-wall{
  display:flex;align-items:center;gap:10px;
  max-width:1160px;margin:12px auto 0;padding:8px 14px;
  border-radius:999px;
  background:var(--accent-soft);border:1px solid var(--line);
}
.home-wall[hidden]{display:none}
.hw-label{flex:none;font-size:11.5px;color:var(--ink-3);white-space:nowrap}
.hw-list{display:flex;gap:6px;overflow-x:auto;flex:1;min-width:0;scrollbar-width:none}
.hw-list::-webkit-scrollbar{display:none}
.hw-list .wt-chip{flex:none}
.hw-x{flex:none;border:0;background:transparent;color:var(--ink-3);font-size:11.5px;cursor:pointer;padding:2px 4px}
.hw-x:hover{color:var(--ink-2)}
@media (max-width:900px){
  .home-wall{margin:10px 12px 0;padding:7px 11px}
}

/* ================= 问 AI（VIP）=================
   只有一栏：上面是对话，下面是输入框。高度用视口算，
   这样输入框永远贴在屏幕底部附近，不用滚到底才能打字。 */
#panel-ask{grid-template-columns:1fr}
.ask-wrap{display:flex;flex-direction:column;gap:10px;height:calc(100vh - 220px);min-height:320px}
.ask-list{flex:1;overflow-y:auto;display:flex;flex-direction:column;gap:9px;padding:2px 2px 6px}
.ask-row{display:flex}
.ask-me{justify-content:flex-end}
.ask-b{
  max-width:min(76%,600px);padding:9px 12px;border-radius:13px;
  font-size:13.5px;line-height:1.72;white-space:pre-wrap;word-break:break-word;
}
.ask-me .ask-b{
  background:var(--accent-soft);border:1px solid var(--accent-line);color:var(--accent-ink);
  border-bottom-right-radius:5px;
}
.ask-ai .ask-b{
  background:var(--surface-2);border:1px solid var(--line);color:var(--ink-2);
  border-bottom-left-radius:5px;
}
.ask-dots{color:var(--ink-3);animation:askBlink 1.2s ease-in-out infinite}
@keyframes askBlink{50%{opacity:.45}}
.ask-empty{margin:auto;text-align:center;padding:26px 10px}
.ask-empty-t{font-size:15px;color:var(--ink-2);margin-bottom:14px}
.ask-chips{display:flex;flex-wrap:wrap;gap:8px;justify-content:center}
.ask-chip{
  padding:7px 13px;border-radius:999px;font-size:12.5px;cursor:pointer;
  background:var(--surface-2);border:1px solid var(--line);color:var(--ink-2);
  transition:border-color var(--dur),background var(--dur),color var(--dur);
}
.ask-chip:hover{border-color:var(--accent);background:var(--accent-soft);color:var(--accent-ink)}
.ask-input{display:flex;gap:8px;align-items:flex-end}
/* resize:none —— 全局 textarea 是 resize:vertical，浏览器会在右下角画一个
   默认色的拖拽三角，在深色底上就是一小块脏点（看着像乱码）。
   这页的高度本来就跟内容自动长（max-height 130），不需要手动拖。 */
.ask-input textarea{flex:1;min-height:46px;max-height:130px;resize:none}
.ask-input .btn{flex:none;height:44px}
.ask-foot{display:flex;align-items:center;justify-content:space-between;gap:10px}
.ask-tip{font-size:11.5px;color:var(--ink-3)}
.ask-lock{
  max-width:520px;margin:10px auto;padding:26px 24px;text-align:center;
  border-radius:16px;background:var(--surface-2);border:1px solid var(--line);
}
.ask-lock-t{font-size:16px;font-weight:var(--fw65);color:var(--ink);margin-bottom:8px}
.ask-lock p{margin:0 0 16px;font-size:13px;line-height:1.75;color:var(--ink-3)}
@media (max-width:900px){
  .ask-wrap{height:calc(100vh - 240px)}
  .ask-b{max-width:88%}
  .ask-foot .ask-tip{display:none}
}

/* 会员特权清单：写在「我的」里，用户点开就知道买的是什么 */
.vip-perks{list-style:none;margin:0 0 10px;padding:0;display:grid;gap:6px}
.vip-perks li{
  display:flex;flex-direction:column;gap:2px;
  padding:8px 10px;border-radius:9px;
  background:var(--accent-soft);border:1px solid var(--line);
}
.vip-perks b{font-size:12.5px;font-weight:650;color:var(--ink)}
.vip-perks span{font-size:11.5px;color:var(--ink-3);line-height:1.45}

/* 小屏：名单只留两行，多了会把游客入口挤到屏幕外 */
@media (max-width:900px){
  .wt-list{max-height:52px;overflow:hidden}
  .vip-perks li{padding:7px 9px}
}

/* ================= 人机验证（Cloudflare Turnstile）=================
   widget 本身是 300×65 的 iframe，这里只负责居中与占位。
   ⚠️ 必须显式写 [hidden]{display:none}：上面那条 display:flex
   会盖掉 hidden 属性自带的 display:none，验证框就藏不住了。 */
.gate-captcha{
  margin:14px auto 6px;
  display:flex;justify-content:center;
  /* 预留高度：不预留的话，验证框一出现整页往下跳，
     正在输入密码的人会丢焦点（手机上还会把键盘顶掉） */
  min-height:66px;
}
.gate-captcha[hidden]{display:none}
.gate-captcha .cap-loading{
  font-size:12px;color:var(--ink-3);
  display:flex;align-items:center;justify-content:center;
}
.gate-captcha .cap-fail{
  font-size:12px;color:var(--ink-3);text-align:center;
  display:flex;flex-direction:column;align-items:center;gap:4px;
}
.gate-captcha.cap-ok{min-height:66px}

@media (max-width:400px){
  .gate-captcha{margin:10px auto 4px}
}
