/* ==================================================================
   大总管课堂 classroom.html —— 独立样式，仅本页引用
   沿用站点既有变量（--ink / --red / --f-display / --line ...）
   ================================================================== */

/* ---------- Hero 顶部统计 ---------- */
.cls-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 44px;
  margin-top: 38px;
  padding-top: 26px;
  border-top: 1px solid rgba(255, 255, 255, .12);
}
.cls-stat b {
  display: block;
  font-family: var(--f-display);
  font-size: 30px;
  line-height: 1;
  color: #fff;
  font-weight: 700;
}
.cls-stat span {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  letter-spacing: .06em;
  color: rgba(232, 230, 228, .52);
}

/* ---------- Hero 右侧 SVG ---------- */
.csvg { width: 100%; max-width: 540px; margin-left: auto; }
.csvg svg { width: 100%; height: auto; display: block; }
.cv-screen {
  fill: rgba(255, 255, 255, .045);
  stroke: rgba(255, 255, 255, .16);
}
.cv-play {
  fill: var(--red);
  animation: cvPulse 3.6s ease-in-out infinite;
}
.cv-tri { fill: #fff; }
.cv-ring {
  fill: none;
  stroke: rgba(237, 53, 18, .55);
  animation: cvRing 3.6s ease-out infinite;
  transform-origin: center;
}
.cv-bar-bg { fill: rgba(255, 255, 255, .14); }
.cv-bar-fg { fill: var(--red); animation: cvBar 7s ease-in-out infinite; }
.cv-row { fill: rgba(255, 255, 255, .06); stroke: rgba(255, 255, 255, .1); }
.cv-rowdot { fill: rgba(255, 255, 255, .24); animation: cvDot 4.5s ease-in-out infinite; }
.cv-t1 { fill: #fff; font-family: var(--f-display); font-size: 24px; font-weight: 700; }
.cv-t2 { fill: rgba(232, 230, 228, .42); font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .14em; }
.cv-lb { fill: rgba(232, 230, 228, .55); font-family: var(--f-body); font-size: 12px; }
.cv-hr { stroke: rgba(255, 255, 255, .1); }

@keyframes cvPulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: .82; }
}
@keyframes cvRing {
  0%   { opacity: .8; transform: scale(.9); }
  70%  { opacity: 0;  transform: scale(1.5); }
  100% { opacity: 0;  transform: scale(1.5); }
}
@keyframes cvBar {
  0%, 8%   { width: 18px; }
  55%      { width: 118px; }
  88%,100% { width: 118px; opacity: 1; }
}
@keyframes cvDot {
  0%, 100% { fill: rgba(255, 255, 255, .22); }
  45%      { fill: var(--red); }
}

/* ---------- 学习区：播放器 + 目录 ---------- */
.cls { background: var(--paper-2); }
.cls__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 34px;
  align-items: start;
}

/* 播放器 */
.stage {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  box-shadow: var(--shadow-1);
}
.stage__box {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #0F0E10;
  overflow: hidden;
}
.stage__box video,
.stage__box iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  background: #000;
  object-fit: contain;
}
.stage__empty {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 24px;
  text-align: center;
  color: rgba(255, 255, 255, .5);
}
.stage__ico {
  position: relative;
  width: 66px;
  height: 66px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .2);
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}
.stage__ico::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 50%;
  border: 1px solid rgba(237, 53, 18, .5);
  animation: stRing 3.4s ease-out infinite;
}
@keyframes stRing {
  0%   { opacity: .9; transform: scale(1); }
  75%  { opacity: 0;  transform: scale(1.42); }
  100% { opacity: 0;  transform: scale(1.42); }
}
.stage__ico svg { width: 22px; height: 22px; fill: var(--red); margin-left: 3px; }
.stage__empty b {
  font-family: var(--f-display);
  font-size: 17px;
  font-weight: 700;
  color: #fff;
}
.stage__empty span { font-size: 12.5px; letter-spacing: .02em; }

.stage__meta { padding: 24px 26px 26px; }
.stage__no {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .1em;
  color: var(--red);
}
.stage__title {
  margin: 9px 0 0;
  font-family: var(--f-display);
  font-size: 21px;
  font-weight: 700;
  line-height: 1.45;
  color: var(--ink);
}
.stage__desc {
  margin-top: 10px;
  font-size: 14.5px;
  line-height: 1.8;
  color: var(--slate);
}
.stage__tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.stage__tag {
  padding: 4px 11px;
  font-size: 12px;
  color: var(--slate);
  border: 1px solid var(--line);
  border-radius: 100px;
  background: var(--paper-2);
}

/* 目录 */
.toc {
  display: flex;
  flex-direction: column;
  max-height: 668px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: var(--shadow-1);
  overflow: hidden;
}
.toc__hd {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 17px 20px;
  border-bottom: 1px solid var(--line);
}
.toc__hd b {
  font-family: var(--f-display);
  font-size: 15.5px;
  font-weight: 700;
  color: var(--ink);
}
.toc__hd span {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--slate-l);
}
.toc__bd { overflow-y: auto; padding: 4px 0 12px; }
.toc__bd::-webkit-scrollbar { width: 6px; }
.toc__bd::-webkit-scrollbar-thumb { background: #DAD7D3; border-radius: 3px; }
.toc__bd::-webkit-scrollbar-track { background: transparent; }

.toc__g {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 15px 20px 7px;
  font-size: 11.5px;
  letter-spacing: .07em;
  color: var(--slate-l);
}
.toc__g::before {
  content: "";
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--red);
  flex: none;
}

.toc__i {
  position: relative;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  padding: 9px 20px 9px 20px;
  font: inherit;
  text-align: left;
  color: var(--ink-3);
  background: none;
  border: 0;
  cursor: pointer;
  transition: background .18s ease;
}
.toc__i::before {
  content: "";
  position: absolute;
  left: 0; top: 9px; bottom: 9px;
  width: 2px;
  background: var(--red);
  opacity: 0;
  transition: opacity .18s ease;
}
.toc__i:hover { background: var(--paper); }
.toc__i.is-on { background: var(--red-soft); }
.toc__i.is-on::before { opacity: 1; }
.toc__i.is-on .toc__t { color: var(--red); font-weight: 600; }
.toc__n {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--slate-l);
}
.toc__t { font-size: 13.5px; line-height: 1.55; }
.toc__d {
  font-family: var(--f-mono);
  font-size: 10.5px;
  color: var(--slate-l);
  white-space: nowrap;
}
.toc__i.is-soon .toc__d { color: #B9B5B0; }
.toc__i.is-soon .toc__t { color: var(--slate); }

/* ---------- 学习路径卡片 ---------- */
.tgrid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  margin-top: 54px;
}
.tcard {
  display: flex;
  flex-direction: column;
  padding: 28px 26px 22px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: transform .26s ease, box-shadow .26s ease, border-color .26s ease;
}
.tcard:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-2);
  border-color: #D7D4D0;
}
.tcard__no {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .1em;
  color: var(--red);
}
.tcard h3 {
  margin: 11px 0 0;
  font-family: var(--f-display);
  font-size: 19px;
  font-weight: 700;
  line-height: 1.45;
  color: var(--ink);
}
.tcard p {
  flex: 1 1 auto;            /* 卡片等高：让简介吸收剩余空间，进度条与脚注底部对齐 */
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--slate);
}
.tcard__bar {
  height: 3px;
  margin-top: 20px;
  border-radius: 2px;
  background: var(--line-2);
  overflow: hidden;
}
.tcard__bar i {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--red), var(--red-2));
  transition: width .8s ease;
}
.tcard__ft {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--line-2);
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--slate-l);
}

/* ---------- 上传提示条（管理员可见，普通访客也能读懂） ---------- */
.upnote {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  margin-top: 44px;
  padding: 22px 24px;
  background: var(--paper);
  border: 1px dashed var(--line);
  border-radius: var(--r);
}
.upnote b { font-size: 13.5px; color: var(--ink-2); }
.upnote p { margin: 0; font-size: 13px; line-height: 1.8; color: var(--slate); }
.upnote code {
  font-family: var(--f-mono);
  font-size: 12px;
  padding: 1px 6px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 3px;
  color: var(--red-2);
}

/* ---------- 响应式 ---------- */
@media (max-width: 1080px) {
  .cls__grid { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .toc { max-height: 460px; }
  .tgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .csvg { margin: 0 auto; }
}
@media (max-width: 700px) {
  .cls-stats { gap: 26px 34px; }
  .cls-stat b { font-size: 24px; }
  .stage__meta { padding: 18px 18px 20px; }
  .stage__title { font-size: 18px; }
  .stage__desc { font-size: 13.5px; }
  .tgrid { grid-template-columns: minmax(0, 1fr); gap: 16px; margin-top: 36px; }
  .tcard { padding: 22px 20px 18px; }
  .toc { max-height: 400px; }
  .toc__i { padding-left: 16px; padding-right: 16px; }
  .toc__hd { padding: 15px 16px; }
  .upnote { padding: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .cv-play, .cv-ring, .cv-bar-fg, .cv-rowdot, .stage__ico::before { animation: none; }
}
