/* ============================================================================
   课务系统客户端 · 官网样式

   设计语言与客户端完全一致（同一份 tokens.css）：灰底 + 纯白浮面、
   「右下深影 + 左上白色高光」的成对柔和阴影、大圆角、纯色填充不使用装饰性渐变。
   ========================================================================== */

/* tokens.css 是按「桌面客户端」写的，官网要把它几处应用专有的默认值改回来 */
body {
  overflow-x: hidden;
  overflow-y: auto;
  user-select: auto;
  cursor: auto;
  line-height: 1.7;
}

.wrap {
  width: min(1140px, calc(100% - 44px));
  margin: 0 auto;
}

/* ── 顶部导航 ─────────────────────────────────────────────────────────── */

.nav {
  position: sticky;
  top: 0;
  z-index: 30;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.nav__inner {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 62px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}

.brand__logo {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  flex: none;
  display: grid;
  place-items: center;
  background: var(--brand);
  color: var(--brand-contrast);
  box-shadow: var(--shadow-xs);
}
.brand__logo::after {
  content: "";
  width: 11px;
  height: 11px;
  border-radius: 3px;
  border: 2px solid currentColor;
  opacity: 0.92;
}

.brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
  min-width: 0;
}
.brand__text strong {
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
}
.brand__text span {
  font-size: 11.5px;
  color: var(--text-mute);
  white-space: nowrap;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.nav__links > a {
  padding: 7px 12px;
  border-radius: var(--radius);
  font-size: 13.5px;
  color: var(--text-dim);
  text-decoration: none;
  transition: background var(--dur-fast) var(--ease-in-out), color var(--dur-fast) var(--ease-in-out);
}
.nav__links > a:hover {
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  color: var(--text);
}

/* ── 按钮 ─────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius);
  border: 0;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  color: var(--text);
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-out-quint), box-shadow var(--dur-fast) var(--ease-out-quint);
}
.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}
.btn:active {
  transform: translateY(0) scale(0.985);
  box-shadow: var(--shadow-inset);
}
.btn--brand {
  background: var(--brand);
  color: var(--brand-contrast);
}
.btn--sm {
  padding: 7px 13px;
  font-size: 12.5px;
}
.btn--lg {
  padding: 13px 24px;
  font-size: 15px;
  border-radius: var(--radius-md);
}
.btn--ghost {
  background: transparent;
  box-shadow: none;
  color: var(--text-dim);
}
.btn--ghost:hover {
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  color: var(--text);
}
.btn[aria-disabled="true"] {
  opacity: 0.55;
  pointer-events: none;
}
.btn .icon {
  width: 17px;
  height: 17px;
}

.icon-btn {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  color: var(--text-dim);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease-in-out), box-shadow var(--dur-fast) var(--ease-in-out);
}
.icon-btn:hover {
  color: var(--brand);
  box-shadow: var(--shadow-sm);
}
.icon-btn .icon {
  width: 18px;
  height: 18px;
}

.inline-form {
  display: inline-flex;
  margin: 0;
}

/* ── 登录态 ───────────────────────────────────────────────────────────── */

.userchip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  font-size: 12.5px;
  color: var(--text-dim);
  max-width: 220px;
}
.userchip .icon {
  width: 15px;
  height: 15px;
  color: var(--brand);
  flex: none;
}
.userchip b {
  color: var(--text);
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.userchip__tag {
  flex: none;
  padding: 1px 7px;
  border-radius: var(--radius-pill);
  background: var(--warn-tint);
  color: var(--warn);
  font-size: 11px;
  font-weight: 700;
}

/* ── 通用小构件 ───────────────────────────────────────────────────────── */

.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: var(--surface-2);
  box-shadow: var(--shadow-xs);
  font-size: 12.5px;
  color: var(--text-dim);
  white-space: nowrap;
}
.chip .icon {
  width: 15px;
  height: 15px;
}
.chip--ok {
  background: var(--ok-tint);
  color: var(--ok);
}
.chip--brand {
  background: var(--tint-brand);
  color: var(--brand-600);
}
.chip--muted {
  background: var(--surface-2);
  color: var(--text-mute);
}
[data-theme="dark"] .chip--brand {
  color: var(--brand);
}

.section {
  padding: 62px 0;
}
.section--tight {
  padding: 44px 0;
}

.section__head {
  text-align: center;
  margin-bottom: 34px;
}
.section__head h2 {
  margin: 0 0 8px;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.3px;
}
.section__head p {
  margin: 0;
  color: var(--text-dim);
  font-size: 14.5px;
}

/* ── Hero ─────────────────────────────────────────────────────────────── */

.hero {
  padding: 66px 0 54px;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 46px;
  align-items: center;
}

.hero__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.hero h1 {
  margin: 0 0 14px;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.8px;
}
.hero h1 em {
  font-style: normal;
  color: var(--brand);
}

.hero__desc {
  margin: 0 0 26px;
  font-size: 15.5px;
  color: var(--text-dim);
  max-width: 46ch;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.hero__meta {
  margin: 26px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}
.hero__meta div {
  display: flex;
  flex-direction: column;
}
.hero__meta dt {
  font-size: 11.5px;
  color: var(--text-mute);
}
.hero__meta dd {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.hero__note {
  margin: 14px 0 0;
  font-size: 12.5px;
  color: var(--text-mute);
}

code {
  font-family: var(--font-mono);
  font-size: 0.92em;
  padding: 1px 6px;
  border-radius: var(--radius-xs);
  background: var(--sunken);
  overflow-wrap: anywhere;
}

/* ── 纯 CSS 的客户端界面示意（不依赖截图文件，永远不会「图挂了」） ───── */

.mock {
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  padding: 10px;
  overflow: hidden;
}
.mock__win {
  border-radius: var(--radius-lg);
  background: var(--bg);
  overflow: hidden;
  box-shadow: var(--shadow-inset);
}

.mock__bar {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
}
.mock__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--text-mute);
  opacity: 0.5;
}
.mock__title {
  margin-left: 6px;
  font-size: 11.5px;
  color: var(--text-mute);
}

.mock__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.mock__top strong {
  font-size: 12.5px;
}
.mock__clock {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.mock__wx {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: var(--surface-2);
  font-size: 11.5px;
  color: var(--text-dim);
}
.mock__wx .icon {
  width: 14px;
  height: 14px;
}

.mock__body {
  padding: 16px 14px 18px;
  background: var(--sunken);
}
.mock__cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.mock__card {
  padding: 12px 12px 14px;
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  border-top: 3px solid var(--accent, var(--brand));
}
.mock__card i {
  display: block;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--accent, var(--brand)) 16%, var(--surface));
  margin-bottom: 9px;
}
.mock__card b {
  display: block;
  font-size: 12.5px;
  margin-bottom: 3px;
}
.mock__card small {
  display: block;
  font-size: 10.5px;
  color: var(--text-mute);
  line-height: 1.5;
}
.mock__card--kiosk {
  --accent: #0ea5e9;
}
.mock__card--random {
  --accent: #f59e0b;
}

.mock__nav {
  display: flex;
  justify-content: center;
  gap: 4px;
  padding: 9px 14px;
  background: var(--bg);
  border-top: 1px solid var(--line);
}
.mock__nav span {
  padding: 5px 11px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  color: var(--text-mute);
  background: var(--surface-2);
}
.mock__nav span[data-active="true"] {
  background: color-mix(in srgb, var(--brand) 14%, var(--surface-2));
  color: var(--text);
  font-weight: 700;
}

/* ── 特性卡片 ─────────────────────────────────────────────────────────── */

.grid3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.card {
  position: relative;
  padding: 22px 22px 24px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  transition: transform var(--dur) var(--ease-out-quint), box-shadow var(--dur) var(--ease-out-quint);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card__bar {
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: var(--accent, var(--brand));
  opacity: 0.85;
  transform: scaleX(0.24);
  transform-origin: left center;
  transition: transform var(--dur-slow) var(--ease-out-quint);
}
.card:hover .card__bar {
  transform: scaleX(1);
}

.card__icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  color: var(--accent, var(--brand));
  background: color-mix(in srgb, var(--accent, var(--brand)) 13%, var(--surface));
  box-shadow: var(--shadow-xs);
  margin-bottom: 14px;
}
.card__icon .icon {
  width: 22px;
  height: 22px;
}

.card h3 {
  margin: 0 0 6px;
  font-size: 16.5px;
  font-weight: 700;
}
.card p {
  margin: 0;
  font-size: 13.5px;
  color: var(--text-dim);
}

.card--kiosk {
  --accent: #0ea5e9;
}
.card--random {
  --accent: #f59e0b;
}
.card--security {
  --accent: #ef4444;
}
.card--usb {
  --accent: #8b5cf6;
}
.card--theme {
  --accent: #10b981;
}

/* ── 三步 ─────────────────────────────────────────────────────────────── */

.steps {
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}
.step {
  padding: 22px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.step::before {
  counter-increment: step;
  content: counter(step);
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--brand);
  color: var(--brand-contrast);
  font-weight: 700;
  font-size: 13.5px;
  margin-bottom: 12px;
}
.step h3 {
  margin: 0 0 6px;
  font-size: 15.5px;
}
.step p {
  margin: 0;
  font-size: 13.5px;
  color: var(--text-dim);
}

/* ── 下载区块 ─────────────────────────────────────────────────────────── */

.download {
  padding: 34px;
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1.2fr auto;
  gap: 28px;
  align-items: center;
}
.download h2 {
  margin: 0 0 8px;
  font-size: 24px;
  font-weight: 700;
}
.download__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.download__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: stretch;
  min-width: 220px;
}
.download__hint {
  margin: 0;
  font-size: 12px;
  color: var(--text-mute);
  text-align: center;
}

.notes {
  margin-top: 22px;
  padding: 20px 24px;
  border-radius: var(--radius-lg);
  background: var(--surface-2);
  box-shadow: var(--shadow-xs);
}
.notes > strong {
  display: block;
  margin-bottom: 10px;
  font-size: 14px;
}
.notes ul {
  margin: 0;
  padding-left: 20px;
  color: var(--text-dim);
  font-size: 13.5px;
}
.notes li {
  margin-bottom: 5px;
}
.notes li::marker {
  color: var(--brand);
}
.notes p {
  margin: 0 0 8px;
  color: var(--text-dim);
  font-size: 13.5px;
}

/* ── 面板 / 常见问题 ──────────────────────────────────────────────────── */

.panel {
  padding: 26px 30px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.panel h3 {
  margin: 0 0 12px;
  font-size: 17px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.panel h3 .icon {
  width: 18px;
  height: 18px;
  color: var(--brand);
}
.panel ul {
  margin: 0;
  padding-left: 20px;
  color: var(--text-dim);
  font-size: 13.8px;
}
.panel li {
  margin-bottom: 6px;
}

.admin-hint p {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  color: var(--text-dim);
  font-size: 13.8px;
}

.faq__item {
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  margin-bottom: 10px;
  overflow: hidden;
}
.faq__item summary {
  padding: 14px 18px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.faq__item summary::-webkit-details-marker {
  display: none;
}
.faq__item summary::before {
  content: "+";
  flex: none;
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--tint-brand);
  color: var(--brand-600);
  font-weight: 700;
  font-size: 14px;
  transition: transform var(--dur) var(--ease-out-quint);
}
.faq__item[open] summary::before {
  content: "−";
  transform: rotate(180deg);
}
.faq__item p {
  margin: 0;
  padding: 0 18px 16px 48px;
  color: var(--text-dim);
  font-size: 13.5px;
}

/* ── 页脚 ─────────────────────────────────────────────────────────────── */

.footer {
  margin-top: 40px;
  padding: 30px 0 40px;
  border-top: 1px solid var(--line);
  color: var(--text-mute);
  font-size: 12.5px;
}
.footer__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
}
.footer a {
  color: var(--text-dim);
  text-decoration: none;
}
.footer a:hover {
  color: var(--brand);
}

/* ── 空下载状态 ───────────────────────────────────────────────────────── */

.empty {
  padding: 22px 24px;
  border-radius: var(--radius-lg);
  background: var(--warn-tint);
  color: var(--text);
  font-size: 13.5px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.empty .icon {
  width: 20px;
  height: 20px;
  color: var(--warn);
  flex: none;
  margin-top: 2px;
}

/* ── 响应式 ───────────────────────────────────────────────────────────── */

@media (max-width: 980px) {
  .hero__grid {
    grid-template-columns: 1fr;
    gap: 34px;
  }
  .grid3 {
    grid-template-columns: 1fr;
  }
  .download {
    grid-template-columns: 1fr;
  }
  .download__actions {
    min-width: 0;
  }
  .nav__links > a:not(.nav__keep):not(.btn) {
    display: none;
  }
}

@media (max-width: 560px) {
  .wrap {
    width: calc(100% - 32px);
  }
  .section {
    padding: 44px 0;
  }
  .mock__cards {
    grid-template-columns: 1fr;
  }
  .brand__text span {
    display: none;
  }
}
