/* 团队页 · 从 public/exact/team.html 内联 <style> 忠实移植(仅页面结构 9-127,
   modal 段沿用共享 TeamModal,默认隐藏不入 diff),整段 scope 进 .team-page 防冲突。
   依赖 design-restraint.css 的全局 .stat(padding 24/28 + border-right)——与镜像 restraint.css 一致。 */
.team-page {
  /* ─── 团队信息卡(深色 banner · 上标题行 + 下统计行)─── */
  .team-top { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; margin-bottom: 24px; align-items: stretch; }

  .team-banner {
    background: var(--accent-black);
    color: var(--accent-white);
    padding: 22px 28px 24px;
    position: relative;
    border: 1px solid var(--accent-black);
    border-radius: var(--r-md);
  }

  /* ─── 团队动态卡(贴 banner 右边)─── */
  .team-feed { background: var(--surface); border: 1px solid var(--border-faint); border-radius: var(--r-md); padding: 16px 18px; display: flex; flex-direction: column; min-width: 0; }
  .team-feed .h { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
  .team-feed .h h3 { font-size: 13.5px; font-weight: 600; margin: 0; }
  .team-feed .h .ct { font-family: var(--font-mono); font-size: 10.5px; color: var(--black-alpha-48); }
  .team-feed .h .more { margin-left: auto; font-family: var(--font-mono); font-size: 11px; color: var(--heat); text-decoration: none; cursor: pointer; }
  .team-feed .feed-list { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; max-height: 240px; padding-right: 4px; scrollbar-width: thin; }
  .team-feed .feed-list::-webkit-scrollbar { width: 4px; }
  .team-feed .feed-list::-webkit-scrollbar-thumb { background: var(--border-faint); border-radius: 2px; }
  .team-feed .feed-item { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 10px; align-items: start; }
  .team-feed .feed-item .av { width: 24px; height: 24px; border-radius: 50%; background: var(--background-lighter); border: 1px solid var(--border-faint); display: grid; place-items: center; font-size: 11px; font-weight: 600; color: var(--accent-black); }
  .team-feed .feed-item .txt { font-size: 12.5px; line-height: 1.45; color: var(--accent-black); min-width: 0; }
  .team-feed .feed-item .txt .who { font-weight: 600; }
  .team-feed .feed-item .txt .act { color: var(--black-alpha-56); margin: 0 3px; }
  .team-feed .feed-item .txt .obj { color: var(--heat); }
  .team-feed .feed-item .txt .obj-money { color: var(--accent-forest); font-variant-numeric: tabular-nums; font-family: var(--font-mono); }
  .team-feed .feed-item .ts { font-family: var(--font-mono); font-size: 10.5px; color: var(--black-alpha-48); margin-top: 2px; letter-spacing: .02em; }
  /* 4 个装订线小十字(2 个 pseudo + 2 个 span)*/
  .team-banner::before, .team-banner::after,
  .team-banner > .corner-tr, .team-banner > .corner-bl {
    content: ''; position: absolute; width: 14px; height: 14px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 21' fill='%23e8e8e8'%3E%3Cpath d='M10.5 4C10.5 7.31371 7.81371 10 4.5 10H0.5V11H4.5C7.81371 11 10.5 13.6863 10.5 17V21H11.5V17C11.5 13.6863 14.1863 11 17.5 11H21.5V10H17.5C14.1863 10 11.5 7.31371 11.5 4V0H10.5V4Z'/%3E%3C/svg%3E") no-repeat center;
    background-size: contain; pointer-events: none;
  }
  .team-banner::before  { top: -7px;    left: -7px; }
  .team-banner::after   { bottom: -7px; right: -7px; }
  .team-banner > .corner-tr { top: -7px;    right: -7px; }
  .team-banner > .corner-bl { bottom: -7px; left: -7px; }

  /* 第 1 行:标题 + 主操作 */
  .banner-head { display: flex; align-items: flex-start; gap: 20px; }
  .banner-id { flex: 1; min-width: 0; }
  .banner-id .lbl { font-family: var(--font-mono); font-size: 10.5px; color: rgba(255,255,255,.55); letter-spacing: .06em; text-transform: uppercase; }
  .banner-id .nm { font-size: 22px; font-weight: 700; letter-spacing: -.012em; margin-top: 4px; display: flex; align-items: baseline; gap: 10px; }
  .banner-id .nm .tag { font-size: 10.5px; font-family: var(--font-mono); padding: 2px 8px; background: rgba(255,255,255,.12); border-radius: var(--r-pill); letter-spacing: .04em; font-weight: 500; }
  .banner-id .meta { font-size: 12px; color: rgba(255,255,255,.5); margin-top: 6px; font-family: var(--font-mono); letter-spacing: .02em; }
  .banner-actions { display: flex; gap: 8px; flex-shrink: 0; }
  .banner-actions .btn { background: var(--accent-white); color: var(--accent-black); border-color: var(--accent-white); }
  .banner-actions .btn:hover { background: var(--background-base); }
  .banner-actions .btn-ghost { background: transparent; color: var(--accent-white); border: 1px solid rgba(255,255,255,.25); }
  .banner-actions .btn-ghost:hover { background: rgba(255,255,255,.08); color: var(--accent-white); }

  /* 分隔线 */
  .banner-divider { height: 1px; background: rgba(255,255,255,.1); margin: 20px 0 18px; }

  /* 第 2 行:4 列统计 */
  .banner-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
  .banner-stats .stat { min-width: 0; }
  .banner-stats .stat .lbl { font-family: var(--font-mono); font-size: 10.5px; color: rgba(255,255,255,.55); letter-spacing: .06em; text-transform: uppercase; }
  .banner-stats .stat .v { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -.012em; margin-top: 6px; }
  /* color 必须显式写,否则会被 restraint.css 全局 .stat .v 的 color: var(--accent-black) 覆盖成黑字 */
  .banner-stats .stat .v { color: var(--accent-white); }
  .banner-stats .stat .v.warn { color: #FFB870; }
  .banner-stats .stat .sub { font-size: 11px; color: rgba(255,255,255,.5); margin-top: 4px; font-family: var(--font-mono); letter-spacing: .02em; }

  /* ─── 主体两栏 ─── */
  .team-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; align-items: start; }

  .pane { background: var(--surface); border: 1px solid var(--border-faint); border-radius: var(--r-md); padding: 20px; margin-bottom: 16px; }
  .pane h3 { font-size: 14px; font-weight: 600; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
  .pane h3 .ct { font-family: var(--font-mono); font-size: 11px; color: var(--black-alpha-48); font-weight: 400; }
  .pane h3 .spacer { margin-left: auto; }

  /* ─── 成员表 ─── */
  .members-table .av { width: 32px; height: 32px; border-radius: 50%; background: var(--background-lighter); display: inline-grid; place-items: center; font-weight: 600; font-size: 13px; color: var(--accent-black); border: 1px solid var(--border-faint); }
  .members-table .who { display: flex; align-items: center; gap: 10px; }
  .members-table .nm { font-weight: 500; font-size: 13.5px; line-height: 1.2; }
  .members-table .em { font-size: 11.5px; color: var(--black-alpha-48); font-family: var(--font-mono); }
  .members-table .role-pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--r-pill); font-size: 11px; font-weight: 500; }
  .members-table .role-pill .dot { width: 6px; height: 6px; border-radius: 50%; }
  .members-table .role-super { background: var(--heat-12); color: var(--heat); }
  .members-table .role-super .dot { background: var(--heat); }
  .members-table .role-admin { background: rgba(30,64,175,.1); color: #1E40AF; }
  .members-table .role-admin .dot { background: #1E40AF; }
  .members-table .role-member { background: var(--background-lighter); color: var(--black-alpha-56); }
  .members-table .role-member .dot { background: var(--black-alpha-56); }
  .members-table .quota-cell { font-variant-numeric: tabular-nums; font-family: var(--font-mono); font-size: 12px; }
  .members-table .quota-cell .lbl { color: var(--black-alpha-48); }
  .members-table .quota-cell .v { color: var(--accent-black); font-weight: 600; }
  .members-table .used-bar { width: 80px; height: 4px; background: var(--background-lighter); border-radius: 2px; overflow: hidden; margin-top: 4px; }
  .members-table .used-bar > span { display: block; height: 100%; background: var(--heat); }
  .members-table .used-bar > span.ok { background: var(--accent-forest); }
  .members-table .used-bar > span.warn { background: #B45309; }
  .members-table .acts { display: flex; gap: 4px; justify-content: flex-end; }
  .members-table .icon-btn-sm { width: 28px; height: 28px; display: inline-grid; place-items: center; border: 1px solid var(--border-faint); border-radius: var(--r-sm); background: var(--surface); cursor: pointer; color: var(--black-alpha-56); transition: all var(--t-base); }
  .members-table .icon-btn-sm:hover { color: var(--heat); border-color: var(--heat-20); }
  .members-table .icon-btn-sm svg { width: 14px; height: 14px; }
  .members-table .icon-btn-sm.danger:hover { color: var(--accent-crimson); border-color: var(--accent-crimson); }
  .members-table tr.pending td { opacity: .65; }
  .members-table tr.pending .nm::after { content: '· 待激活'; font-size: 11px; color: var(--black-alpha-48); margin-left: 6px; font-weight: 400; font-family: var(--font-mono); }

  /* ─── 角色权限矩阵 ─── */
  .perm-table { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--surface); border: 1px solid var(--border-muted); border-radius: var(--r-md); overflow: hidden; font-size: 12.5px; }
  .perm-table th, .perm-table td { padding: 8px 10px; border-bottom: 0; }
  .perm-table th { border-bottom: 1px solid var(--border-muted); background: var(--background-lighter); font-family: var(--font-mono); font-size: 10.5px; font-weight: 500; color: var(--black-alpha-48); letter-spacing: .04em; text-transform: uppercase; text-align: left; }
  .perm-table th:not(:first-child), .perm-table td:not(:first-child) { text-align: center; }
  .perm-table tbody td:first-child { color: var(--accent-black); }
  .perm-table .yes { color: var(--accent-forest); font-weight: 600; }
  .perm-table .no { color: var(--black-alpha-32); }
}
