/* 教学网附件（files.js）：课程页「公告与课件」和详情面板「附件」共用。归 M2 课程中心 Fomalhaut647。类名都带 fl- 前缀。 */
.fl { display: flex; flex-direction: column; gap: 2px; }
.fl-row { display: flex; align-items: center; gap: 6px; min-height: 36px; border-radius: var(--radius-sm); }
.fl-row:hover { background: var(--soft); }
.fl-main { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; padding: 6px 8px; color: var(--text); text-decoration: none; }
a.fl-main:hover { text-decoration: none; }
a.fl-main:hover .fl-name { color: var(--ink); text-decoration: underline; text-decoration-color: var(--faint); }
.fl-ext { flex: none; display: grid; place-items: center; width: 36px; height: 22px; border-radius: 6px; font-size: 10px; font-weight: 650;
  letter-spacing: .02em; color: var(--muted); background: var(--soft-2); font-variant-numeric: tabular-nums; }
/* 文件类型的小方块：颜色只用全站变量（docs/specs/web-design.md） */
.fl-ext.fl-pdf { color: var(--red); background: var(--red-soft); }
.fl-ext.fl-doc { color: var(--tint); background: var(--tint-soft); }
.fl-ext.fl-ppt { color: var(--orange); background: var(--t-chg-bg); }
.fl-ext.fl-xls { color: var(--green); background: var(--green-soft); }
.fl-name { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13.5px; }
.fl-size { flex: none; color: var(--faint); font-size: 12px; font-variant-numeric: tabular-nums; }
.fl-note { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--faint); font-size: 12px; }   /* 大文件到期清掉了：为什么只能去教学网下 */
a.fl-dl { display: grid; place-items: center; flex: none; width: 30px; height: 30px; margin-right: 4px; border-radius: 8px; color: var(--muted); }
a.fl-dl:hover { background: var(--soft-2); color: var(--ink); }
.fl-dl .ic { width: 16px; height: 16px; }
.fl-bb { flex: none; margin-right: 8px; font-size: 12.5px; white-space: nowrap; }
.fl-pics { display: flex; flex-wrap: wrap; gap: 8px; padding: 4px 0 6px; }
button.fl-pic { width: 96px; height: 72px; padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--soft); cursor: zoom-in; }
button.fl-pic:hover { border-color: var(--line-2); background: var(--soft); }
.fl-pic img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* 课程页的附件（fileList 的 chips）：一个附件一个带边框的小框，尺寸颜色照 docs/mockups/course-nav/README.md 第 2.2 节 */
.fl.fl-chips { flex-direction: row; flex-wrap: wrap; gap: 8px; }
.fl-chips > .fl-pics { flex-basis: 100%; padding: 0; }
.fl-chip { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; min-width: 0; height: 36px; padding: 0 12px 0 8px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--panel); color: var(--text); font-size: 13px; text-decoration: none; transition: background-color .15s, border-color .15s; }
a.fl-chip:hover { background: var(--soft); border-color: var(--line-2); color: var(--text); text-decoration: none; }
.fl-chip.is-off { color: var(--muted); }
.fl-chip .fl-ext { width: 32px; height: 20px; border-radius: 5px; color: #fff; background: #8a8a8e; font-size: 10px; font-weight: 700; }
.fl-chip .fl-ext.fl-pdf { color: #fff; background: #b8322a; }
.fl-chip .fl-ext.fl-ppt { color: #fff; background: #b4500f; }
.fl-chip .fl-ext.fl-doc { color: #fff; background: #2559ad; }
.fl-chip .fl-ext.fl-xls { color: #fff; background: #1d7a3e; }
.fl-chip .fl-name { font-size: 13px; }
.fl-chip .fl-size { color: var(--muted); }
.fl-bbtag { flex: none; color: var(--muted); font-size: 12px; }
/* 能在线看的：小框里面是「打开」的链接加右端的下载按钮。电脑上下载按钮盖在小框右端（左边一段渐变盖住大小），鼠标移上去、键盘选中时才出来；
   手机上没有悬停，下载按钮一直在，用一条竖线和小框隔开 */
.fl-chip.has-dl { position: relative; padding: 0; gap: 0; }
.fl-chip.has-dl:hover { background: var(--soft); border-color: var(--line-2); }
a.fl-chip-main { display: inline-flex; align-items: center; gap: 8px; min-width: 0; height: 100%; padding: 0 12px 0 8px; border-radius: 9px; color: var(--text); text-decoration: none; }
a.fl-chip-main:hover { color: var(--text); text-decoration: none; }
a.fl-chip-dl { position: absolute; top: 3px; right: 3px; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 7px; color: var(--muted);
  background: var(--soft); box-shadow: -14px 0 10px -2px var(--soft); opacity: 0; transition: opacity .15s, background-color .15s, color .15s; }
.fl-chip.has-dl:hover a.fl-chip-dl, a.fl-chip-dl:focus-visible { opacity: 1; }
a.fl-chip-dl:hover { background: var(--soft-2); color: var(--ink); }
.fl-chip-dl .ic { width: 16px; height: 16px; }
@media (hover: none) {
  a.fl-chip-main { padding-right: 10px; }
  a.fl-chip-dl { position: static; flex: none; width: 36px; height: 100%; border-left: 1px solid var(--line); border-radius: 0 9px 9px 0; background: none; box-shadow: none; opacity: 1; }
  a.fl-chip-dl:active { background: var(--soft); }
}

/* 大图：盖住整页（包括详情面板） */
.fl-big { position: fixed; inset: 0; z-index: 80; display: flex; align-items: center; justify-content: center; padding: 56px 16px 16px;
  background: rgba(17, 17, 19, .82); cursor: zoom-out; }   /* 不加淡入：浏览器窗口在后台时动画不跑，会停在半透明 */
.fl-big img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; background: #fff; box-shadow: 0 10px 40px rgba(0, 0, 0, .35); }
.fl-big-bar { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; gap: 6px; height: 52px; padding: 0 12px 0 18px; color: #fff; cursor: default; }
.fl-big-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.fl-big-bar .ibtn { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; color: rgba(255, 255, 255, .85); background: none; }
.fl-big-bar .ibtn:hover { background: rgba(255, 255, 255, .14); color: #fff; }
.fl-big-bar .ibtn .ic { width: 18px; height: 18px; }

/* 课程页「公告与课件」的一条 */
.fl-post + .fl-post { margin-top: 4px; padding-top: 10px; border-top: 1px solid var(--line); }
.fl-post-h { display: flex; align-items: baseline; gap: 10px; padding: 2px 0 4px; }
.fl-post-t { flex: 1; min-width: 0; font-size: 14px; font-weight: 550; color: var(--ink); overflow-wrap: anywhere; }
a.fl-post-t:hover { text-decoration: underline; text-decoration-color: var(--faint); }
.fl-post-d { flex: none; color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.fl-post .tag { align-self: center; }
.fl-post-add { flex: none; align-self: center; min-height: 0; padding: 2px 9px; border: 1px solid var(--line); border-radius: 999px; background: none;
  color: var(--link); font-size: 12.5px; font-weight: 400; white-space: nowrap; }
.fl-post-add:hover:not(:disabled) { border-color: var(--link); }
.fl-post-add:disabled { color: var(--muted); }
.fl-post-add.done { border-color: transparent; color: var(--muted); }
.fl-post .fl, .d-block .fl { margin: 0 -8px; }
.fl-post .fl-pics, .d-block .fl-pics { padding-left: 8px; }
