/* 课堂作业收集台 · 样式 */
:root {
  --brand: #3157d5;
  --brand-d: #2444b5;
  --brand-soft: #edf2ff;
  --ink: #172238;
  --ink-2: #3e4c63;
  --muted: #5f6e86;
  --line: #e0e7f0;
  --line-strong: #cfd9e8;
  --surface: #fff;
  --surface-soft: #f8faff;
  --bg: #f5f7fb;
  --ok: #087f5b;
  --ok-soft: #e6fcf5;
  --warn: #b94f08;
  --warn-soft: #fff4e6;
  --bad: #c92a2a;
  --bad-soft: #fff5f5;
  --accent-blue: #3157d5;
  --accent-blue-soft: #edf2ff;
  --accent-violet: #6d4bd1;
  --accent-violet-soft: #f1edff;
  --accent-teal: #0b7f72;
  --accent-teal-soft: #e6f7f3;
  --accent-amber: #a85c08;
  --accent-amber-soft: #fff3df;
  --accent-rose: #b73f65;
  --accent-rose-soft: #ffedf3;
  --accent-sky: #1f78b4;
  --accent-sky-soft: #eaf5fd;
  --accent-cyan: #087c8d;
  --accent-cyan-soft: #e8f8fb;
  --accent-magenta: #8d3db5;
  --accent-magenta-soft: #f7ebfd;
  --accent-slate: #52657d;
  --accent-slate-soft: #eef2f7;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(23, 34, 56, .035), 0 18px 42px -30px rgba(23, 34, 56, .32);
  --shadow-hover: 0 4px 10px rgba(23, 34, 56, .04), 0 24px 52px -30px rgba(23, 34, 56, .38);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --font: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }

html, body { min-height: 100%; }
html { scroll-behavior: smooth; }

.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon {
  width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.icon-sm { width: 15px; height: 15px; }
.icon-lg { width: 22px; height: 22px; }
.tone-blue { --tone: var(--accent-blue); --tone-soft: var(--accent-blue-soft); }
.tone-violet { --tone: var(--accent-violet); --tone-soft: var(--accent-violet-soft); }
.tone-teal { --tone: var(--accent-teal); --tone-soft: var(--accent-teal-soft); }
.tone-amber { --tone: var(--accent-amber); --tone-soft: var(--accent-amber-soft); }
.tone-rose { --tone: var(--accent-rose); --tone-soft: var(--accent-rose-soft); }
.tone-sky { --tone: var(--accent-sky); --tone-soft: var(--accent-sky-soft); }
.tone-cyan { --tone: var(--accent-cyan); --tone-soft: var(--accent-cyan-soft); }
.tone-magenta { --tone: var(--accent-magenta); --tone-soft: var(--accent-magenta-soft); }
.tone-slate { --tone: var(--accent-slate); --tone-soft: var(--accent-slate-soft); }
.icon-tile {
  width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center;
  flex: none; color: var(--tone, var(--brand)); background: var(--tone-soft, var(--brand-soft));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .45);
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(1100px 520px at 10% -10%, #e7edff 0%, rgba(231, 237, 255, 0) 62%),
    radial-gradient(900px 460px at 96% 0%, #e9f8f5 0%, rgba(233, 248, 245, 0) 56%),
    var(--bg);
  -webkit-font-smoothing: antialiased;
  font-size: 16px;
  line-height: 1.65;
}

a { color: var(--brand-d); text-decoration: none; }
a:hover { color: var(--brand); }
:focus-visible { outline: 3px solid rgba(49, 87, 213, .24); outline-offset: 3px; }
.skip-link {
  position: fixed; left: 16px; top: 10px; z-index: 1000; padding: 10px 14px;
  background: var(--ink); color: #fff; border-radius: 10px; transform: translateY(-160%);
  transition: transform .18s var(--ease);
}
.skip-link:focus { color: #fff; transform: translateY(0); }
::selection { background: #dbe6ff; color: var(--ink); }

h1, h2, h3 { margin: 0 0 .4em; line-height: 1.3; }
h1 { font-size: 26px; letter-spacing: -.025em; }
h2 { font-size: 18px; letter-spacing: -.015em; }
h3 { font-size: 16.5px; }
p { margin: 0 0 .7em; }

.wrap { width: min(1180px, 100% - 40px); margin: 0 auto; }
.main { padding: 30px 0 72px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.center { text-align: center; }
.right { text-align: right; }
.hide-sm { }
.pre { white-space: pre-wrap; }
.mt { margin-top: 26px; }
.inline { display: inline; margin: 0; }

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(249, 251, 255, .92);
  backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .8);
}
.topbar-inner { display: flex; align-items: center; gap: clamp(12px, 2vw, 24px); min-height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); flex: none; }
.brand:hover { color: var(--ink); }
.logo {
  width: 36px; height: 36px; border-radius: 11px; flex: none;
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 17px;
  background: linear-gradient(145deg, #547cf1, var(--brand-d));
  box-shadow: 0 9px 20px -11px rgba(36, 68, 181, .9);
  overflow: hidden;
}
.logo img { width: 100%; height: 100%; display: block; object-fit: cover; }
.logo-lg { width: 52px; height: 52px; border-radius: 15px; font-size: 24px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text b { font-size: 15.5px; letter-spacing: -.015em; }
.brand-text small { color: var(--muted); font-size: 11.5px; margin-top: 3px; }
.nav { display: flex; align-items: center; gap: 2px; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav-link {
  display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 6px 9px 6px 6px;
  border-radius: 10px; color: var(--ink-2); font-size: 13.5px; white-space: nowrap;
  transition: color .18s var(--ease), background .18s var(--ease), box-shadow .18s var(--ease);
}
.nav-link:hover { background: #eef3fb; color: var(--ink); }
.nav-link.is-active {
  background: #fff; color: var(--brand-d); font-weight: 650;
  box-shadow: inset 0 -2px 0 var(--brand), 0 4px 14px -10px rgba(49, 87, 213, .5);
}
.nav-icon {
  width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center;
  color: var(--tone, var(--brand)); background: var(--tone-soft, var(--brand-soft));
  transition: background .18s var(--ease), color .18s var(--ease), transform .18s var(--ease);
}
.nav-icon .icon { width: 16px; height: 16px; }
.nav-link:hover .nav-icon { transform: translateY(-1px); }
.nav-link.is-active .nav-icon { color: #fff; background: var(--brand); }
.userbox { margin-left: auto; display: flex; align-items: center; gap: 8px; flex: none; }
.user-chip {
  display: inline-flex; align-items: center; gap: 7px;
  background: #f3f5fa; border-radius: 999px; padding: 5px 12px; font-size: 13.5px; color: var(--ink-2);
}
.user-chip i { font-style: normal; font-size: 11px; color: var(--muted); border-left: 1px solid var(--line); padding-left: 7px; }

/* ---------- 账号菜单 ---------- */
.account-menu { position: relative; }
.account-trigger {
  display: flex; align-items: center; gap: 9px; min-height: 44px; padding: 5px 9px 5px 5px;
  list-style: none; border: 1px solid var(--line); border-radius: 13px; background: rgba(255, 255, 255, .86);
  color: var(--ink); cursor: pointer; user-select: none;
  transition: border-color .18s var(--ease), box-shadow .18s var(--ease), background .18s var(--ease);
}
.account-trigger::-webkit-details-marker { display: none; }
.account-trigger::marker { content: ""; }
.account-trigger:hover, .account-menu[open] .account-trigger {
  border-color: var(--line-strong); background: #fff; box-shadow: var(--shadow);
}
.account-avatar {
  width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand-d); font-size: 14px; font-weight: 700; flex: none;
}
.account-copy { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.account-copy b { max-width: 92px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13.5px; }
.account-copy small { color: var(--muted); font-size: 11px; margin-top: 2px; }
.account-caret {
  width: 7px; height: 7px; margin: 0 3px 3px 1px; border-right: 1.5px solid var(--muted);
  border-bottom: 1.5px solid var(--muted); transform: rotate(45deg); transition: transform .18s var(--ease);
}
.account-menu[open] .account-caret { transform: rotate(225deg); margin-bottom: -3px; }
.account-panel {
  position: absolute; right: 0; top: calc(100% + 10px); z-index: 50; width: min(276px, calc(100vw - 24px));
  padding: 8px; border: 1px solid var(--line); border-radius: 15px; background: #fff;
  box-shadow: 0 26px 60px -24px rgba(23, 34, 56, .45);
}
.account-panel-head { display: flex; flex-direction: column; gap: 2px; padding: 9px 11px 11px; border-bottom: 1px solid #eef2f7; margin-bottom: 5px; }
.account-panel-head span { color: var(--muted); font-size: 11.5px; }
.account-panel-head b { font-size: 13.5px; }
.account-action {
  width: 100%; display: flex; flex-direction: column; align-items: flex-start; gap: 1px;
  padding: 10px 11px; border: 0; border-radius: 10px; background: transparent; color: var(--ink);
  font-family: inherit; text-align: left; cursor: pointer;
}
.account-action > span { font-size: 13.5px; font-weight: 600; }
.account-action-main { display: flex; align-items: center; gap: 8px; }
.account-action-main .icon { width: 16px; height: 16px; color: var(--muted); }
.account-action:hover .account-action-main .icon { color: currentColor; }
.account-action i { color: var(--muted); font-size: 11.5px; font-style: normal; }
.account-action:hover { background: #f5f8fd; color: var(--brand-d); }
.account-logout:hover { background: var(--bad-soft); color: var(--bad); }
.account-menu form { margin: 0; }

/* ---------- 卡片 ---------- */
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 24px; margin-bottom: 20px;
}
.card.narrow { max-width: 620px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h1, .card-head h2 { margin: 0; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 40px; padding: 0 17px; border-radius: 11px; border: 1px solid transparent;
  font-size: 14px; font-family: inherit; font-weight: 600; cursor: pointer;
  background: #fff; color: var(--ink-2);
  transition: transform .18s var(--ease), background .18s var(--ease), border-color .18s var(--ease), box-shadow .18s var(--ease);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; filter: none; }
.btn-primary { background: linear-gradient(145deg, #3c68ea, var(--brand-d)); color: #fff; box-shadow: 0 10px 22px -13px rgba(36, 68, 181, .9); }
.btn-primary:hover { color: #fff; box-shadow: 0 14px 28px -13px rgba(36, 68, 181, .95); }
.btn-ghost { background: #fff; border-color: var(--line); color: var(--ink-2); }
.btn-ghost:hover { border-color: var(--line-strong); background: var(--surface-soft); }
.btn-ghost.danger { color: var(--bad); }
.btn-danger {
  color: #fff; background: var(--bad); border-color: var(--bad);
  box-shadow: 0 8px 18px -13px rgba(201, 42, 42, .8);
}
.btn-danger:hover { color: #fff; background: #b42323; border-color: #b42323; }
.btn-sm { min-height: 34px; padding: 0 12px; font-size: 12.5px; border-radius: 9px; }
.btn-block { width: 100%; min-height: 46px; font-size: 15px; }
.btn .icon { width: 16px; height: 16px; }

/* ---------- 表单 ---------- */
.stack > * + * { margin-top: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > label { font-size: 13px; color: var(--ink-2); font-weight: 500; }
.field-row { display: flex; gap: 14px; flex-wrap: wrap; }
.field-row .field { flex: 1 1 190px; }
.field-row .field.grow { flex: 3 1 380px; }
input:not([type]), input[type=text], input[type=password], input[type=number], input[type=datetime-local],
select, textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 11px; padding: 10px 12px;
  font-family: inherit; font-size: 14.5px; color: var(--ink); background: #fff;
  transition: border-color .18s var(--ease), box-shadow .18s var(--ease), background .18s var(--ease);
}
textarea { resize: vertical; line-height: 1.6; }
input:focus, select:focus, textarea:focus {
  outline: none; border-color: #8fa7f5; box-shadow: 0 0 0 3px rgba(49, 87, 213, .13); background: #fff;
}
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.filters select, .filters input { width: auto; min-width: 130px; }
.filters input { min-width: 190px; }

/* ---------- 徽标 ---------- */
.badge {
  display: inline-flex; align-items: center; height: 22px; padding: 0 9px; border-radius: 999px;
  font-size: 12px; font-weight: 600; white-space: nowrap;
}
.badge-gray { background: #f1f3f9; color: #7a879c; }
.badge-green { background: var(--ok-soft); color: var(--ok); }
.badge-blue { background: var(--brand-soft); color: var(--brand-d); }
.badge-amber { background: var(--warn-soft); color: var(--warn); }
.badge-red { background: var(--bad-soft); color: var(--bad); }
.chip {
  display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px;
  background: #f5f7fc; border-radius: 8px; font-size: 12.5px; color: var(--ink-2);
}
.chip .icon { width: 14px; height: 14px; }
.chip-blue { color: var(--accent-blue); background: var(--accent-blue-soft); }
.chip-violet { color: var(--accent-violet); background: var(--accent-violet-soft); }
.chip-teal { color: var(--accent-teal); background: var(--accent-teal-soft); }
.chip-amber { color: var(--accent-amber); background: var(--accent-amber-soft); }

/* ---------- 学生首页 ---------- */
.hero { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.hero h1 { margin-bottom: 6px; }
.hero p { margin: 0; }
.ring {
  position: relative; width: 104px; height: 104px; border-radius: 50%; flex: none;
  background: conic-gradient(#5c7cfa calc(var(--p) * 1%), #e9edf7 0);
  display: grid; place-items: center;
}
.ring > span {
  width: 82px; height: 82px; border-radius: 50%; background: #fff; display: flex;
  align-items: baseline; justify-content: center; padding-top: 26px;
  font-size: 23px; font-weight: 700; color: #2b3a55; letter-spacing: -.03em;
}
.ring i { font-style: normal; font-size: 12px; font-weight: 500; color: var(--muted); margin-left: 1px; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.task-card {
  display: flex; flex-direction: column; gap: 8px; padding: 20px; background: #fff;
  border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
  color: var(--ink); transition: .18s;
}
.task-card:hover { transform: translateY(-2px); border-color: #cdd8f0; box-shadow: 0 18px 34px -22px rgba(16, 24, 40, .45); color: var(--ink); }
.tc-head { display: flex; align-items: center; justify-content: space-between; }
.tc-idx {
  font-size: 12px; font-weight: 700; color: var(--brand-d); background: var(--brand-soft);
  border-radius: 7px; padding: 2px 8px; letter-spacing: .04em;
}
.task-card h3 { margin: 2px 0 0; font-size: 16px; }
.tc-brief {
  color: var(--muted); font-size: 13px; margin: 0; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden; min-height: 42px;
}
.tc-foot { display: flex; justify-content: space-between; gap: 10px; font-size: 12px; margin-top: auto; padding-top: 4px; }

/* ---------- 任务页 ---------- */
.crumbs {
  display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-bottom: 15px;
  font-size: 13px; color: var(--muted);
}
.crumbs a {
  display: inline-flex; align-items: center; min-height: 32px; padding: 3px 9px;
  border-radius: 8px; color: var(--ink-2); background: rgba(255, 255, 255, .7);
  border: 1px solid rgba(224, 231, 240, .85); transition: .18s var(--ease);
}
.crumbs a:hover { color: var(--brand-d); background: #fff; border-color: var(--line-strong); }
.crumbs a:first-child::before { content: "←"; margin-right: 5px; color: var(--brand); }
#main-content:focus { outline: none; }
.task-head h1 { margin: 10px 0 6px; }
.lead { color: var(--ink-2); font-size: 15px; }
.meta-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
#detail p { white-space: pre-wrap; color: var(--ink-2); font-size: 14px; margin: 0 0 .45em; }
#detail p.sec { font-weight: 600; color: var(--ink); margin: 1em 0 .3em; }
.lesson-tag {
  display: inline-block; background: var(--brand-soft); color: var(--brand-d);
  border-radius: 7px; padding: 2px 10px; font-size: 12.5px; font-weight: 600; margin: 2px 0 10px;
}

.dropzone {
  display: block; border: 1.5px dashed #c7d2e8; border-radius: 14px; background: #fbfcff;
  padding: 26px 18px; text-align: center; cursor: pointer; transition: .18s;
}
.dropzone:hover, .dropzone.is-over { border-color: var(--brand); background: #f2f6ff; }
.dropzone input[type=file] { display: none; }
.dz-inner { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.dz-plus {
  width: 40px; height: 40px; border-radius: 12px; background: var(--brand-soft); color: var(--brand-d);
  display: grid; place-items: center; font-size: 22px; margin-bottom: 4px;
}
.dz-plus .icon { width: 22px; height: 22px; }
.dz-inner b { font-size: 14.5px; font-weight: 600; }

.picked { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.picked li {
  display: flex; align-items: center; gap: 10px; background: #f8faff; border: 1px solid var(--line);
  border-radius: 10px; padding: 8px 12px; font-size: 13.5px;
}
.picked .nm { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.picked .rm { border: none; background: none; color: var(--muted); cursor: pointer; font-size: 17px; line-height: 1; padding: 2px 4px; }
.picked .rm:hover { color: var(--bad); }

.up-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.progress {
  position: relative; height: 26px; border-radius: 999px; background: #eef1f8; overflow: hidden;
}
.progress .bar { height: 100%; width: 0; background: linear-gradient(90deg, #5c7cfa, #3b5bdb); transition: width .2s; }
.progress span {
  position: absolute; inset: 0; display: grid; place-items: center; font-size: 12px; font-weight: 600; color: #43506a;
}
.hidden { display: none !important; }

.file-list { list-style: none; margin: 0; padding: 0; }
.file-row {
  display: flex; align-items: center; gap: 12px; padding: 10px 2px; border-bottom: 1px dashed var(--line);
}
.file-row:last-child { border-bottom: none; }
.file-ico {
  width: 34px; height: 34px; border-radius: 9px; background: #f2f5fc; color: #61708a;
  display: grid; place-items: center; font-size: 10px; font-weight: 700; flex: none;
}
.file-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.thumb { width: 60px; height: 44px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); flex: none; }

.history summary, details.card summary { cursor: pointer; font-weight: 600; font-size: 14px; color: var(--ink-2); }
.hist-list { list-style: none; padding: 0; margin: 12px 0 8px; }
.hist-list li { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px dashed var(--line); font-size: 13.5px; }
.hist-list li:last-child { border-bottom: none; }

.grade-card { display: flex; gap: 20px; align-items: flex-start; border-left: 4px solid var(--brand); }
.grade-mark {
  width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center;
  flex: none; color: var(--tone); background: var(--tone-soft);
}
.grade-mark .icon { width: 21px; height: 21px; }
.grade-score { font-size: 34px; font-weight: 700; color: var(--brand-d); line-height: 1; letter-spacing: -.03em; }
.grade-score i { font-style: normal; font-size: 13px; color: var(--muted); margin-left: 3px; font-weight: 500; }
.grade-body { flex: 1; }
.grade-body h3 { margin-bottom: 4px; }
.grade-body .pre { color: var(--ink-2); font-size: 14px; }
blockquote.note {
  margin: 0 0 14px; padding: 10px 14px; background: #f8faff; border-left: 3px solid #c9d4ea;
  border-radius: 0 8px 8px 0; color: var(--ink-2); font-size: 13.5px;
}

/* ---------- 统计 ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 20px; }
.stat {
  position: relative; display: flex; align-items: center; gap: 14px; min-height: 94px;
  padding: 18px; margin: 0; overflow: hidden;
}
.stat::after {
  content: ""; position: absolute; right: -30px; bottom: -48px; width: 112px; height: 112px;
  border-radius: 50%; background: radial-gradient(circle, rgba(49, 87, 213, .08), transparent 68%);
  pointer-events: none;
}
.stat > .icon-tile { position: relative; z-index: 1; width: 44px; height: 44px; border-radius: 13px; }
.stat > .icon-tile .icon { width: 21px; height: 21px; }
.stat-copy { position: relative; z-index: 1; display: flex; flex-direction: column; min-width: 0; }
.stat-copy b { display: block; font-size: 28px; letter-spacing: -.03em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.stat-copy span { color: var(--muted); font-size: 12.5px; }
.stat.is-alert .stat-copy b { color: var(--warn); }

.admin-intro {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(420px, .95fr);
  align-items: center; gap: 26px; padding: 28px 30px; overflow: hidden;
  background:
    radial-gradient(360px 220px at 96% 8%, rgba(109, 75, 209, .13), transparent 72%),
    radial-gradient(320px 220px at 62% 110%, rgba(11, 127, 114, .1), transparent 74%),
    #fff;
}
.admin-intro h1 { font-size: clamp(25px, 2.8vw, 34px); margin: 3px 0 7px; letter-spacing: -.03em; }
.admin-intro p { margin: 0; max-width: 580px; }
.quick-links { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.quick-link {
  display: flex; flex-direction: column; gap: 11px; min-height: 130px; padding: 15px;
  border: 1px solid var(--line); border-radius: 14px; background: rgba(255, 255, 255, .86);
  color: var(--ink); transition: transform .18s var(--ease), border-color .18s var(--ease), box-shadow .18s var(--ease);
}
.quick-link:hover {
  transform: translateY(-2px); color: var(--ink); border-color: var(--tone, var(--line-strong));
  box-shadow: var(--shadow-hover);
}
.quick-link > span:last-child { display: flex; flex-direction: column; gap: 2px; }
.quick-link b { font-size: 14px; }
.quick-link small { color: var(--muted); font-size: 11.5px; line-height: 1.45; }

.url-row { display: flex; gap: 10px; flex-wrap: wrap; }
.url-chip {
  font-family: ui-monospace, Consolas, monospace; font-size: 15px; padding: 10px 16px;
  border-radius: 10px; border: 1px dashed #c7d2e8; background: #fbfcff; color: var(--brand-d);
  cursor: pointer; transition: .15s;
}
.url-chip:hover { background: var(--brand-soft); border-style: solid; }

.prog-list { display: flex; flex-direction: column; gap: 12px; }
.prog-row { display: grid; grid-template-columns: minmax(160px, 1.2fr) 2fr auto; gap: 14px; align-items: center; }
.prog-name a { font-size: 13.5px; color: var(--ink-2); }
.prog-name a:hover { color: var(--brand-d); }
.prog-bar { height: 8px; border-radius: 999px; background: #eef1f8; overflow: hidden; }
.prog-bar i { display: block; height: 100%; background: linear-gradient(90deg, #74a5ff, #4c6ef5); border-radius: 999px; }
.prog-num { font-size: 12.5px; color: var(--ink-2); font-variant-numeric: tabular-nums; }

.simple-list { list-style: none; margin: 0; padding: 0; }
.simple-list li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: 13.5px; }
.simple-list li:last-child { border-bottom: none; }

/* ---------- 表格 ---------- */
.table { width: 100%; border-collapse: collapse; }
.table th {
  text-align: left; font-size: 12px; font-weight: 600; color: var(--muted);
  padding: 9px 10px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.table td { padding: 12px 10px; border-bottom: 1px solid #f1f4fa; font-size: 14px; vertical-align: middle; }
.table tbody tr:hover { background: #fafbff; }
.table .num { font-variant-numeric: tabular-nums; color: var(--ink-2); }
.table .w60 { width: 60px; }
.table td.right { white-space: nowrap; }
.empty-row td { color: var(--muted); font-size: 13px; text-align: center; border-bottom: none; }
.clamp { max-width: 420px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.table-wrap { width: 100%; overflow-x: auto; }

/* ---------- 学员账号 ---------- */
.section-title { display: flex; align-items: center; gap: 12px; }
.section-title h2 { margin: 0 0 2px; }
.section-title p { margin: 0; }
.import-workspace { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 16px; align-items: stretch; }
.import-main textarea { min-height: 172px; }
.label-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.label-row b { color: var(--brand-d); font-variant-numeric: tabular-nums; }
.import-guide {
  padding: 16px; border: 1px solid var(--line); border-radius: 14px;
  background: linear-gradient(145deg, #f8faff, #f5f9ff);
}
.import-guide > b { display: block; margin-bottom: 10px; font-size: 13px; }
.mini-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.mini-steps li { display: flex; align-items: flex-start; gap: 9px; }
.mini-steps li > span {
  width: 24px; height: 24px; border-radius: 8px; display: grid; place-items: center;
  flex: none; background: var(--brand); color: #fff; font-size: 11px; font-weight: 700;
}
.mini-steps li > div { display: flex; flex-direction: column; line-height: 1.4; }
.mini-steps b { font-size: 12.5px; }
.mini-steps small { color: var(--muted); font-size: 11px; }
.import-options { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.import-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding-top: 4px; }
.batch-result { border-color: #cce8df; }
.batch-head { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 14px; }
.batch-title { display: flex; align-items: center; gap: 12px; }
.batch-title h2 { margin: 1px 0 2px; }
.batch-title p { margin: 0; color: var(--muted); font-size: 12.5px; }
.batch-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.credential-cell { display: flex; align-items: center; gap: 10px; }
.credential-cell code {
  padding: 3px 7px; border-radius: 6px; background: #f3f6fb;
  font-size: 13px; color: var(--ink);
}
.copy-chip {
  display: inline-flex; align-items: center; gap: 4px; min-height: 30px; padding: 0 9px;
  border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink-2);
  font-family: inherit; font-size: 11.5px; cursor: pointer;
}
.copy-chip:hover { color: var(--brand-d); border-color: var(--line-strong); background: var(--surface-soft); }
.batch-footnote { margin: 10px 0 0; color: var(--muted); font-size: 11.5px; }
.account-actions { text-align: right; white-space: nowrap; }
.account-actions .btn + .btn, .account-actions form + form { margin-left: 5px; }
.account-table td { vertical-align: middle; }
.check-cell { width: 44px; text-align: center; }
.check-cell input {
  width: 18px; height: 18px; margin: 0; accent-color: var(--brand); cursor: pointer;
}
.bulk-toolbar {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  padding: 12px 14px; margin: 0 0 12px; border: 1px solid var(--line);
  border-radius: 13px; background: #f8faff;
}
.bulk-selection { display: flex; flex-direction: column; gap: 2px; }
.bulk-selection span { font-size: 13px; font-weight: 650; color: var(--ink); }
.bulk-selection small { color: var(--muted); font-size: 11.5px; }
.bulk-buttons { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }

/* ---------- 导出 ---------- */
.export-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; margin: 16px 0; }
.export-card {
  display: flex; flex-direction: column; gap: 4px; padding: 18px; border-radius: 14px;
  border: 1px solid var(--line); background: linear-gradient(180deg, #fbfcff, #fff); color: var(--ink);
}
.export-card:hover { border-color: #c7d2e8; color: var(--ink); transform: translateY(-1px); }
.export-card b { font-size: 15px; color: var(--brand-d); }
.export-card span { font-size: 12.5px; color: var(--muted); }
.code { background: #f2f5fc; padding: 1px 6px; border-radius: 6px; font-size: 13px; font-family: ui-monospace, Consolas, monospace; }

/* ---------- 登录 ---------- */
.login-body {
  min-height: 100vh;
  background:
    radial-gradient(760px 520px at 8% 8%, rgba(49, 87, 213, .17), transparent 68%),
    radial-gradient(700px 540px at 96% 92%, rgba(11, 127, 114, .12), transparent 70%),
    linear-gradient(135deg, #f7f9ff, #f3f7fc 52%, #f7fbfa);
}
.login-body .main { width: 100%; padding: 0; }
.login-shell {
  width: min(1180px, 100% - 40px); min-height: 100vh; margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(380px, 440px);
  gap: clamp(36px, 6vw, 90px); align-items: center; padding: 46px 0;
}
.login-story { position: relative; min-width: 0; }
.login-story::before {
  content: ""; position: absolute; width: 380px; height: 380px; left: -180px; top: 20%;
  border: 54px solid rgba(49, 87, 213, .05); border-radius: 50%; pointer-events: none;
}
.login-brand-line { position: relative; display: flex; align-items: center; gap: 14px; z-index: 1; }
.logo-login {
  width: 62px; height: 62px; border-radius: 18px;
  box-shadow: 0 18px 38px -20px rgba(10, 63, 125, .7), 0 0 0 6px rgba(255, 255, 255, .68);
}
.login-brand-line > div { display: flex; flex-direction: column; gap: 3px; line-height: 1.25; }
.login-brand-line b { font-size: 18px; letter-spacing: -.02em; }
.login-brand-line small { color: var(--muted); font-size: 12px; }
.login-copy { position: relative; z-index: 1; margin-top: 50px; }
.login-kicker {
  display: inline-flex; align-items: center; gap: 7px; padding: 6px 11px;
  border-radius: 9px; color: var(--brand-d); background: rgba(255, 255, 255, .72);
  border: 1px solid rgba(207, 217, 232, .85); font-size: 12px; font-weight: 650;
}
.login-copy h1 {
  max-width: 720px; margin: 18px 0 15px; font-size: clamp(38px, 4.4vw, 58px);
  line-height: 1.13; letter-spacing: -.055em;
}
.login-copy h1 em { color: var(--brand); font-style: normal; }
.login-copy p { max-width: 620px; color: var(--ink-2); font-size: 16px; line-height: 1.8; }
.login-features { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 28px; }
.login-feature {
  display: flex; align-items: center; gap: 10px; min-height: 76px; padding: 12px;
  border-radius: 14px; border: 1px solid rgba(224, 231, 240, .9);
  background: rgba(255, 255, 255, .68); backdrop-filter: blur(8px);
}
.login-feature > div { display: flex; flex-direction: column; min-width: 0; }
.login-feature b { font-size: 13px; }
.login-feature span { color: var(--muted); font-size: 11px; line-height: 1.45; }
.login-flow { display: flex; align-items: center; gap: 9px; margin-top: 20px; color: var(--muted); font-size: 12px; font-weight: 600; }
.login-flow i { width: 28px; height: 1px; background: linear-gradient(90deg, #b9c9e5, #dbe5f4); }

.auth-card { width: 100%; padding: 32px 30px; margin: 0; }
.login-auth { position: relative; overflow: hidden; border-radius: 24px; }
.login-auth::before {
  content: ""; position: absolute; width: 160px; height: 160px; right: -86px; top: -92px;
  border-radius: 50%; background: radial-gradient(circle, rgba(49, 87, 213, .13), transparent 68%);
  pointer-events: none;
}
.auth-head { position: relative; text-align: left; margin-bottom: 24px; display: flex; flex-direction: column; align-items: flex-start; gap: 5px; }
.auth-logo-small { width: 46px; height: 46px; border-radius: 13px; overflow: hidden; margin-bottom: 8px; box-shadow: 0 10px 22px -14px rgba(10, 63, 125, .8); }
.auth-logo-small img { width: 100%; height: 100%; display: block; object-fit: cover; }
.auth-eyebrow { color: var(--brand-d); font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.auth-head h2 { margin: 0; font-size: 28px; letter-spacing: -.03em; }
.auth-head p { margin: 0; font-size: 13px; color: var(--muted); }
.login-auth .pick-field select { min-height: 44px; }
.password-field { position: relative; }
.password-field input { padding-right: 62px; }
.password-toggle {
  position: absolute; right: 5px; top: 50%; transform: translateY(-50%);
  min-width: 52px; min-height: 36px; border: 0; border-radius: 8px; background: transparent;
  color: var(--muted); font-family: inherit; font-size: 12px; font-weight: 600; cursor: pointer;
}
.password-toggle:hover { color: var(--brand-d); background: var(--brand-soft); }
.login-submit { justify-content: space-between; width: 100%; min-height: 48px; padding: 0 16px 0 18px; }
.login-submit .icon { margin-left: auto; }
.auth-help {
  display: flex; align-items: flex-start; gap: 8px; margin-top: 18px; padding: 11px 12px;
  border-radius: 11px; background: #f7f9fd; color: var(--muted); font-size: 12px; line-height: 1.6;
}
.auth-help .icon { margin-top: 2px; color: var(--accent-sky); }
.auth-tip { text-align: left; color: var(--muted); font-size: 11.5px; margin: 14px 0 0; }

/* ---------- 提示 ---------- */
.flash {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 15px; border-radius: 12px; font-size: 13.5px; margin-bottom: 18px;
}
.flash-ok { background: var(--ok-soft); color: #087f5b; border: 1px solid #c3f0e3; }
.flash-err { background: var(--bad-soft); color: #c92a2a; border: 1px solid #ffd8d8; }
.flash-x { border: none; background: none; cursor: pointer; font-size: 18px; color: inherit; opacity: .55; line-height: 1; }
.flash-x:hover { opacity: 1; }
.state-banner {
  display: flex; align-items: flex-start; gap: 11px; margin-bottom: 18px;
  padding: 13px 15px; border: 1px solid; border-radius: 12px;
}
.state-banner > div { display: flex; flex-direction: column; gap: 2px; }
.state-banner b { font-size: 13.5px; }
.state-banner span { font-size: 12.5px; line-height: 1.55; }
.state-banner .link { font-weight: 700; margin-left: 4px; }
.state-warning { color: #7b4308; background: var(--accent-amber-soft); border-color: #f0d39d; }
.state-ok { color: #086553; background: var(--accent-teal-soft); border-color: #b9e4da; }
.account-state {
  display: flex; align-items: flex-start; gap: 11px; margin-top: 18px;
  padding: 14px; border: 1px solid; border-radius: 12px;
}
.account-state > div { display: flex; flex-direction: column; gap: 3px; }
.account-state b { font-size: 13.5px; }
.account-state span { font-size: 12.5px; line-height: 1.55; }

.empty { padding: 50px 20px; text-align: center; color: var(--muted); background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); }
.err-code { font-size: 52px; font-weight: 700; color: #dbe2f1; line-height: 1; }

.kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 14px; margin: 16px 0; }
.kv div { background: #f8faff; border-radius: 10px; padding: 12px 14px; }
.kv span { display: block; font-size: 12px; color: var(--muted); }
.kv b { font-size: 15px; }

.foot { border-top: 1px solid var(--line); padding: 18px 0 26px; color: var(--muted); font-size: 12.5px; }

/* ---------- 打印 ---------- */
.print-body { background: #fff; padding: 24px; }
.print-head { text-align: center; margin-bottom: 18px; }
.print-head h1 { font-size: 22px; margin-bottom: 4px; }
.print-head p { color: #666; font-size: 13px; }
.print-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.print-card { border: 1px solid #bbb; border-radius: 8px; padding: 10px 12px; font-size: 13px; }
.print-card b { display: block; font-size: 15px; margin-bottom: 6px; }
.pc-row { display: flex; justify-content: space-between; border-top: 1px dashed #ddd; padding-top: 3px; margin-top: 3px; }
.pc-row span { color: #666; }
.pc-row code { font-family: ui-monospace, Consolas, monospace; font-size: 14px; font-weight: 600; }

@media print {
  .topbar, .foot, .crumbs, .btn { display: none !important; }
  body { background: #fff; }
  .card { box-shadow: none; border: 1px solid #ddd; break-inside: avoid; }
  .print-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- 响应式 ---------- */
@media (max-width: 860px) {
  .hide-sm { display: none; }
  .login-shell {
    width: min(680px, 100% - 32px); min-height: auto; grid-template-columns: 1fr;
    gap: 26px; padding: 28px 0 38px;
  }
  .login-copy { margin-top: 32px; }
  .login-copy h1 { max-width: 620px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .admin-intro { grid-template-columns: 1fr; }
  .quick-links { max-width: 100%; }
  .import-workspace { grid-template-columns: 1fr; }
  .import-guide { order: -1; }
  .prog-row { grid-template-columns: 1fr auto; }
  .prog-bar { grid-column: 1 / -1; order: 3; }
  .hero { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 1050px) {
  .topbar-inner { flex-wrap: wrap; padding: 10px 0 8px; row-gap: 7px; }
  .nav { order: 3; flex-basis: 100%; width: 100%; padding-bottom: 2px; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .wrap { width: calc(100% - 24px); }
  .topbar-inner { height: auto; padding: 10px 0; flex-wrap: wrap; gap: 10px; }
  .brand { flex: 1 1 auto; min-width: 0; }
  .brand-text { min-width: 0; }
  .brand-text b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .nav {
    order: 3; width: 100%; overscroll-behavior-inline: contain;
    mask-image: linear-gradient(to right, #000 calc(100% - 18px), transparent);
  }
  .nav-link { min-height: 44px; padding: 8px 12px; }
  .brand-text b { font-size: 14.5px; }
  .brand-text small { max-width: 170px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .account-trigger { min-height: 44px; }
  .login-shell { width: calc(100% - 24px); padding: 20px 0 30px; gap: 20px; }
  .logo-login { width: 52px; height: 52px; border-radius: 15px; }
  .login-brand-line b { font-size: 16px; }
  .login-copy { margin-top: 26px; }
  .login-copy h1 { margin: 14px 0 10px; font-size: 32px; }
  .login-copy p { font-size: 14.5px; line-height: 1.7; }
  .login-features { gap: 8px; margin-top: 20px; }
  .login-feature {
    min-height: 92px; flex-direction: column; align-items: flex-start; gap: 7px; padding: 10px;
  }
  .login-feature .icon-tile { width: 32px; height: 32px; }
  .login-feature span { display: none; }
  .login-feature b { font-size: 12px; }
  .login-flow { display: none; }
  .auth-card { padding: 24px 20px; }
  .card { padding: 18px; border-radius: 16px; }
  .btn, .btn-sm { min-height: 44px; }
  .admin-intro { padding: 22px 18px; gap: 18px; }
  .quick-links { grid-template-columns: 1fr; }
  .quick-link { min-height: auto; flex-direction: row; align-items: center; }
  .import-options { grid-template-columns: 1fr; }
  .import-actions .btn { width: 100%; }
  .batch-head { flex-direction: column; align-items: flex-start; }
  .batch-head > .btn { width: 100%; }
  .batch-actions .btn { flex: 1 1 140px; }
  .bulk-toolbar { align-items: stretch; }
  .bulk-buttons { width: 100%; }
  .bulk-buttons .btn { flex: 1 1 140px; }
  .copy-chip { min-height: 40px; }
  .grid { grid-template-columns: 1fr; }
  .table { display: block; overflow-x: auto; white-space: nowrap; }
  .grade-card { flex-direction: column; gap: 8px; }
  .print-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 440px) {
  .brand-text small { display: none; }
  .account-copy b { max-width: 64px; }
  .account-copy small { font-size: 10px; }
  .stats { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}


/* ---------- 游客浏览（只读） ---------- */
.guest-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin: 0 0 18px; padding: 12px 15px; border-radius: 12px; font-size: 13px; line-height: 1.6;
  color: #7b4308; background: var(--accent-amber-soft); border: 1px solid #f0d39d;
}
.guest-bar strong { font-weight: 700; }
.guest-bar a { font-weight: 600; color: #b45309; white-space: nowrap; }
.guest-bar a:hover { color: #8a3f06; }

body.guest-mode form[method="post"] button[type="submit"]:not(.account-logout),
body.guest-mode form[method="post"] button.btn:not(.account-logout) { display: none !important; }
body.guest-mode form[method="post"] button[type="submit"] + .btn,
body.guest-mode .up-actions .btn { display: none !important; }
body.guest-mode .dropzone { cursor: not-allowed; }
body.guest-mode .dropzone .dz-inner b { color: var(--muted); }
body.guest-mode .dropzone::after {
  content: "游客浏览不能上传文件"; display: block; margin-top: 4px;
  font-size: 12px; color: var(--accent-amber);
}

.guest-link {
  display: flex; align-items: center; gap: 9px; margin-top: 14px; padding: 12px 14px;
  border: 1px dashed var(--line-strong); border-radius: 12px; color: var(--ink-2);
  font-size: 13.5px; transition: color .18s var(--ease), border-color .18s var(--ease), background .18s var(--ease);
}
.guest-link:hover { color: var(--brand-d); border-color: var(--brand); background: var(--brand-soft); }
.guest-link-dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--accent-amber);
  flex: none; box-shadow: 0 0 0 3px rgba(168, 92, 8, .14);
}
.guest-link-arrow { margin-left: auto; color: var(--muted); }


/* 游客模式下，这些入口不该出现 */
body.guest-mode .hero .btn { display: none !important; }
body.guest-mode .dropzone .dz-inner b,
body.guest-mode .dropzone .dz-inner .muted { display: none; }
body.guest-mode .dropzone .dz-inner .dz-plus { margin-bottom: 0; }
body.guest-mode .upload-form .up-actions,
body.guest-mode #uploadForm .up-actions { display: none !important; }


/* 游客入口：跟登录按钮同一个蓝 */
.guest-link {
  border: 1px solid #c7d6fb;
  border-style: solid;
  background: var(--brand-soft);
  color: var(--brand-d);
  font-weight: 600;
}
.guest-link:hover {
  border-color: var(--brand);
  background: #e0eaff;
  color: var(--brand-d);
}
.guest-link-dot { background: var(--brand); box-shadow: 0 0 0 3px rgba(49, 87, 213, .16); }
.guest-link-arrow { color: var(--brand); }


/* 游客模式：写操作的表单整块不显示，不只是藏按钮 */
body.guest-mode form[action$="/learn/note"],
body.guest-mode form[action$="/learn/progress"],
body.guest-mode form[action$="/upload"],
body.guest-mode form[action$="/board/post"],
body.guest-mode form[action*="/board/"][action$="/reply"],
body.guest-mode form[action$="/me/password"] {
  display: none !important;
}


/* 游客模式：写操作所在的整张卡片一起收起来，别留个空壳 */
body.guest-mode .card:has(form[action$="/board/post"]),
body.guest-mode .card:has(form[action$="/upload"]),
body.guest-mode .card:has(form[action$="/learn/note"]) {
  display: none !important;
}


/* 游客模式：练习题的选项可以看，但点不动 */
body.guest-mode #quizForm input,
body.guest-mode #quizForm label,
body.guest-mode #quizForm .opt { pointer-events: none !important; cursor: default !important; }
body.guest-mode #quizForm .opt { opacity: .72; }


/* 游客入口改成登录卡片底部一行小链接，不抢新版界面的样子 */
.guest-link {
  display: inline;
  color: var(--brand);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px dashed rgba(49, 87, 213, .5);
  padding-bottom: 1px;
}
.guest-link:hover { color: var(--brand-d); border-bottom-color: var(--brand-d); }
.guest-link-dot, .guest-link-arrow { display: none; }


/* ---- 游客提示条：放大、放宽、跟页面卡片一个呼吸节奏 ---- */
.guest-bar {
  display: flex; align-items: center; gap: 20px; flex-wrap: wrap;
  margin: 0 0 22px; padding: 20px 24px;
  border-radius: 16px;
  font-size: 14.5px; line-height: 1.8;
  color: #6b3a05;
  background: linear-gradient(135deg, #fffbf3 0%, #fff4e4 100%);
  border: 1px solid #f2d7ab;
  box-shadow: 0 1px 2px rgba(20, 30, 50, .03);
}
.guest-bar-text { flex: 1 1 320px; min-width: 0; }
.guest-bar strong { font-weight: 700; color: #b45309; }
.guest-bar a {
  flex: none; padding: 9px 20px; border-radius: 999px;
  font-weight: 600; font-size: 13.5px; color: #b45309; white-space: nowrap;
  background: #fff; border: 1px solid #f0c98a;
  transition: background .18s var(--ease), color .18s var(--ease), border-color .18s var(--ease);
}
.guest-bar a:hover { background: #b45309; color: #fff; border-color: #b45309; }

@media (max-width: 720px) {
  .guest-bar { padding: 16px 18px; font-size: 14px; border-radius: 14px; gap: 14px; margin-bottom: 18px; }
  .guest-bar a { width: 100%; text-align: center; }
}


/* ---- 登录页游客入口：跟"登录系统"同宽的描边按钮，明显一点 ---- */
.auth-card .guest-link,
a.guest-link {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; margin: 14px 0 0; padding: 13px 18px;
  border: 1.5px solid var(--brand); border-radius: 12px;
  background: #fff; color: var(--brand);
  font-size: 14.5px; font-weight: 600; text-decoration: none;
  transition: background .18s var(--ease), color .18s var(--ease), border-color .18s var(--ease);
}
.auth-card .guest-link:hover,
a.guest-link:hover { background: var(--brand-soft); color: var(--brand-d); border-color: var(--brand-d); }

@media (max-width: 720px) {
  .auth-card .guest-link, a.guest-link { padding: 12px 14px; font-size: 14px; }
}
