/* ============================================================
   花叔设计系统 · Build(11) × Information Architects(03)
   受众：专升本学生/家长 — 需要实用感与专业信任感
   色彩：oklch 教育靛蓝 + 炭墨黑 + 纯净白
   字体：Noto Serif SC (display) + 系统无衬线 (body)
   节奏：70%+ 留白 · 强字重层级 · 零装饰元素
   ============================================================ */

/* ---------- CSS 变量（Design Tokens） ---------- */
:root {
  /* 主色：教育靛蓝 oklch */
  --c-blue:       oklch(42% 0.18 258);
  --c-blue-dim:   oklch(55% 0.14 258);
  --c-blue-ghost: oklch(95% 0.04 258);
  --c-blue-line:  oklch(88% 0.07 258);

  /* 墨色层级 */
  --c-ink-900: oklch(12% 0.01 258);  /* 主标题 */
  --c-ink-700: oklch(28% 0.01 258);  /* 正文 */
  --c-ink-500: oklch(48% 0.01 258);  /* 次要文字 */
  --c-ink-300: oklch(68% 0.01 258);  /* 占位/禁用 */
  --c-ink-100: oklch(86% 0.01 258);  /* 分割线 */

  /* 背景 */
  --c-bg:       oklch(99% 0.005 258);
  --c-surface:  oklch(97% 0.008 258);
  --c-surface2: oklch(94.5% 0.012 258);

  /* 语义色 */
  --c-success: oklch(52% 0.16 155);
  --c-warn:    oklch(62% 0.18 65);
  --c-danger:  oklch(48% 0.20 20);

  /* 字体栈 */
  --font-display: "Noto Serif SC", "Source Han Serif SC", serif;
  --font-body:    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, sans-serif;
  --font-mono:    "JetBrains Mono", "Fira Code", "Cascadia Code", monospace;

  /* 尺寸系统（8pt 基线） */
  --s-1:  0.25rem;  /* 4px  */
  --s-2:  0.5rem;   /* 8px  */
  --s-3:  0.75rem;  /* 12px */
  --s-4:  1rem;     /* 16px */
  --s-5:  1.25rem;  /* 20px */
  --s-6:  1.5rem;   /* 24px */
  --s-8:  2rem;     /* 32px */
  --s-10: 2.5rem;   /* 40px */
  --s-12: 3rem;     /* 48px */
  --s-16: 4rem;     /* 64px */
  --s-20: 5rem;     /* 80px */
  --s-24: 6rem;     /* 96px */
  --s-32: 8rem;     /* 128px */

  /* 圆角（克制） */
  --r-sm:  3px;
  --r-md:  6px;
  --r-lg:  10px;

  /* 阴影（极其克制，仅用于浮层） */
  --shadow-sm: 0 1px 3px oklch(12% 0.01 258 / 0.08);
  --shadow-md: 0 4px 16px oklch(12% 0.01 258 / 0.10);
  --shadow-lg: 0 8px 32px oklch(12% 0.01 258 / 0.12);

  /* 过渡 */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-fast: 120ms;
  --dur-std:  220ms;
  --dur-slow: 380ms;

  /* 布局 */
  --max-content: 1120px;
  --max-prose:   720px;
  --nav-h:       60px;
}

/* ---------- Reset & 基础 ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  font-size: 0.9375rem;      /* 15px */
  line-height: 1.7;
  color: var(--c-ink-700);
  background: var(--c-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* 核心规则：text-wrap: pretty（huashu 必选） */
p, h1, h2, h3, h4, li {
  text-wrap: pretty;
  overflow-wrap: break-word;
}

img, svg { display: block; max-width: 100%; }
a { color: var(--c-blue); text-decoration: none; transition: color var(--dur-fast); }
a:hover { color: var(--c-blue-dim); }
button { cursor: pointer; font-family: inherit; border: none; background: none; }

/* ---------- 导航 ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  padding: 0 var(--s-8);
  background: oklch(99% 0.005 258 / 0.92);
  backdrop-filter: blur(12px) saturate(180%);
  border-bottom: 1px solid var(--c-ink-100);
  z-index: 100;
  transition: box-shadow var(--dur-std) var(--ease-out);
}

.nav.scrolled {
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  max-width: var(--max-content);
  width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: var(--s-8);
}

.nav-brand {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--c-ink-900);
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

.nav-brand span {
  color: var(--c-blue);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--s-1);
  margin-left: auto;
  list-style: none;
}

.nav-links a {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-2) var(--s-3);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--c-ink-500);
  transition: color var(--dur-fast), background var(--dur-fast);
}

.nav-links a:hover {
  color: var(--c-ink-900);
  background: var(--c-surface2);
}

.nav-links a.active {
  color: var(--c-blue);
  background: var(--c-blue-ghost);
}

/* ---------- 主内容区 ---------- */
main {
  padding-top: var(--nav-h);
  min-height: 100vh;
}

.container {
  max-width: var(--max-content);
  margin: 0 auto;
  padding: 0 var(--s-8);
}

/* ---------- 英雄区（首页专属） ---------- */
.hero {
  padding: clamp(var(--s-20), 10vw, var(--s-32)) 0 clamp(var(--s-16), 8vw, var(--s-24));
  border-bottom: 1px solid var(--c-ink-100);
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-1) var(--s-3);
  background: var(--c-blue-ghost);
  border: 1px solid var(--c-blue-line);
  border-radius: 100px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--c-blue);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: var(--s-6);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 5.5vw, 4rem);
  font-weight: 700;
  line-height: 1.15;
  color: var(--c-ink-900);
  letter-spacing: -0.02em;
  max-width: 18ch;
}

.hero-title em {
  font-style: normal;
  color: var(--c-blue);
}

.hero-desc {
  margin-top: var(--s-5);
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--c-ink-500);
  max-width: 48ch;
}

.hero-actions {
  margin-top: var(--s-10);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-4);
}

/* ---------- 按钮系统 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: 0.625rem var(--s-5);
  border-radius: var(--r-md);
  font-size: 0.9375rem;
  font-weight: 500;
  line-height: 1;
  transition: all var(--dur-fast) var(--ease-out);
  white-space: nowrap;
}

.btn-primary {
  background: var(--c-blue);
  color: oklch(99% 0.005 258);
  box-shadow: 0 1px 2px oklch(42% 0.18 258 / 0.25);
}

.btn-primary:hover {
  background: oklch(38% 0.18 258);
  box-shadow: 0 4px 12px oklch(42% 0.18 258 / 0.30);
  transform: translateY(-1px);
  color: oklch(99% 0.005 258);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: none;
}

.btn-ghost {
  color: var(--c-ink-700);
  border: 1px solid var(--c-ink-100);
  background: var(--c-bg);
}

.btn-ghost:hover {
  border-color: var(--c-ink-300);
  background: var(--c-surface);
  color: var(--c-ink-900);
}

.btn-text {
  color: var(--c-blue);
  padding-left: 0;
  padding-right: 0;
}

.btn-text:hover {
  color: oklch(38% 0.18 258);
}

.btn-sm {
  padding: 0.375rem var(--s-3);
  font-size: 0.8125rem;
}

/* ---------- 数据统计条 ---------- */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0;
  border: 1px solid var(--c-ink-100);
  border-radius: var(--r-lg);
  overflow: hidden;
  margin: var(--s-16) 0;
  background: var(--c-surface);
}

.stat-item {
  padding: var(--s-8) var(--s-6);
  border-right: 1px solid var(--c-ink-100);
  transition: background var(--dur-fast);
}

.stat-item:last-child { border-right: none; }
.stat-item:hover { background: var(--c-bg); }

.stat-num {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 700;
  color: var(--c-blue);
  line-height: 1;
  letter-spacing: -0.02em;
}

.stat-label {
  margin-top: var(--s-2);
  font-size: 0.8125rem;
  color: var(--c-ink-500);
  font-weight: 400;
}

/* ---------- 章节标题系统 ---------- */
.section {
  padding: clamp(var(--s-16), 6vw, var(--s-24)) 0;
}

.section + .section {
  border-top: 1px solid var(--c-ink-100);
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--s-4);
  margin-bottom: var(--s-10);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.375rem, 2.5vw, 1.875rem);
  font-weight: 700;
  color: var(--c-ink-900);
  letter-spacing: -0.015em;
}

.section-sub {
  font-size: 0.9375rem;
  color: var(--c-ink-500);
}

/* ---------- 快速入口网格 ---------- */
.entry-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: var(--s-4);
}

.entry-card {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--s-6);
  border: 1px solid var(--c-ink-100);
  border-radius: var(--r-lg);
  background: var(--c-bg);
  transition: border-color var(--dur-std) var(--ease-out),
              box-shadow var(--dur-std) var(--ease-out),
              transform var(--dur-std) var(--ease-spring);
  text-decoration: none;
  color: inherit;
}

.entry-card:hover {
  border-color: var(--c-blue-line);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  color: inherit;
}

.entry-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--r-md);
  background: var(--c-blue-ghost);
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  color: var(--c-blue);
}

.entry-card h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--c-ink-900);
  letter-spacing: -0.01em;
}

.entry-card p {
  font-size: 0.875rem;
  color: var(--c-ink-500);
  line-height: 1.6;
}

.entry-arrow {
  margin-top: auto;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--c-blue);
  display: flex;
  align-items: center;
  gap: var(--s-1);
  transition: gap var(--dur-fast);
}

.entry-card:hover .entry-arrow {
  gap: var(--s-2);
}

/* ---------- 搜索栏 ---------- */
.search-bar {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1.5px solid var(--c-ink-100);
  border-radius: var(--r-lg);
  background: var(--c-bg);
  overflow: hidden;
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
}

.search-bar:focus-within {
  border-color: var(--c-blue);
  box-shadow: 0 0 0 3px oklch(42% 0.18 258 / 0.12);
}

.search-bar input {
  flex: 1;
  padding: 0.75rem var(--s-4);
  font-size: 0.9375rem;
  font-family: inherit;
  border: none;
  outline: none;
  background: transparent;
  color: var(--c-ink-900);
}

.search-bar input::placeholder {
  color: var(--c-ink-300);
}

.search-bar button {
  padding: 0.75rem var(--s-5);
  background: var(--c-blue);
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  transition: background var(--dur-fast);
  white-space: nowrap;
}

.search-bar button:hover {
  background: oklch(38% 0.18 258);
}

/* ---------- 筛选器 ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  padding: var(--s-4) 0;
}

.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  padding: 0.3125rem var(--s-3);
  border: 1px solid var(--c-ink-100);
  border-radius: 100px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--c-ink-500);
  background: var(--c-bg);
  cursor: pointer;
  transition: all var(--dur-fast);
}

.filter-chip:hover {
  border-color: var(--c-blue-line);
  color: var(--c-blue);
  background: var(--c-blue-ghost);
}

.filter-chip.active {
  border-color: var(--c-blue);
  color: var(--c-blue);
  background: var(--c-blue-ghost);
}

.filter-select {
  padding: 0.375rem var(--s-3);
  border: 1px solid var(--c-ink-100);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-family: inherit;
  color: var(--c-ink-700);
  background: var(--c-bg);
  cursor: pointer;
  outline: none;
  transition: border-color var(--dur-fast);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2368768a' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: var(--s-8);
}

.filter-select:focus {
  border-color: var(--c-blue);
}

/* ---------- 数据表格 ---------- */
.data-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--c-ink-100);
  border-radius: var(--r-lg);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.data-table thead th {
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--c-ink-500);
  text-align: left;
  white-space: nowrap;
  border-bottom: 1px solid var(--c-ink-100);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.data-table thead th:first-child { border-radius: var(--r-lg) 0 0 0; }
.data-table thead th:last-child  { border-radius: 0 var(--r-lg) 0 0; }

.data-table tbody tr {
  border-bottom: 1px solid var(--c-ink-100);
  transition: background var(--dur-fast);
}

.data-table tbody tr:last-child { border-bottom: none; }

.data-table tbody tr:hover { background: var(--c-surface); }

.data-table tbody td {
  padding: var(--s-4);
  color: var(--c-ink-700);
  vertical-align: top;
}

.data-table tbody td:first-child {
  font-weight: 500;
  color: var(--c-ink-900);
}

/* ---------- 卡片列表（学校/专业） ---------- */
.card-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--c-ink-100);
  border-radius: var(--r-lg);
  overflow: hidden;
}

.card-item {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-3) var(--s-4);
  border-bottom: 1px solid var(--c-ink-100);
  background: var(--c-bg);
  cursor: pointer;
  transition: background var(--dur-fast);
}

.card-item:last-child { border-bottom: none; }
.card-item:hover { background: var(--c-surface); }

.card-item.expanded { background: var(--c-surface); }

.card-item-main {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: var(--s-2);
  flex-wrap: wrap;
}

.card-item-main h3 {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--c-ink-900);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
  flex-shrink: 0;
}

.card-item-main .meta-info {
  font-size: 0.8125rem;
  color: var(--c-ink-500);
  white-space: nowrap;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 1px var(--s-2);
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.5;
}

.badge-blue   { background: var(--c-blue-ghost); color: var(--c-blue); }
.badge-gray   { background: var(--c-surface2);   color: var(--c-ink-500); }
.badge-green  { background: oklch(92% 0.06 155);  color: oklch(35% 0.14 155); }
.badge-amber  { background: oklch(93% 0.08 80);   color: oklch(38% 0.16 65); }
.badge-purple { background: oklch(93% 0.06 290);  color: oklch(38% 0.16 290); }

.card-toggle {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--c-ink-100);
  color: var(--c-ink-300);
  font-size: 0.6875rem;
  transition: all var(--dur-std) var(--ease-spring);
  flex-shrink: 0;
}

.card-item:hover .card-toggle {
  border-color: var(--c-blue-line);
  color: var(--c-blue);
}

.card-item.expanded .card-toggle {
  transform: rotate(180deg);
  background: var(--c-blue);
  border-color: var(--c-blue);
  color: white;
}

/* 展开详情 */
.card-detail {
  display: none;
  padding: 0 var(--s-4) var(--s-4);
  background: var(--c-surface);
  border-bottom: 1px solid var(--c-ink-100);
}

.card-detail.open { display: block; }

/* 展开详情 — 三行紧凑卡片 */
.detail-cards {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding: var(--s-3) 0;
}

.detail-card {
  border: 1px solid var(--c-ink-100);
  border-radius: var(--r-md);
  padding: var(--s-3) var(--s-4);
  background: var(--c-bg);
  transition: background var(--dur-fast);
}

.detail-card:hover { background: var(--c-surface); }

.detail-card-row {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  flex-wrap: wrap;
  min-height: 1.6em;
}

.detail-card-row + .detail-card-row { margin-top: var(--s-1); }

.detail-card-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--c-ink-900);
  margin-right: var(--s-1);
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: var(--s-4);
  padding: var(--s-5) 0;
  border-top: 1px solid var(--c-ink-100);
}

.detail-item label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--c-ink-300);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  display: block;
  margin-bottom: var(--s-1);
}

.detail-item .val {
  font-size: 0.9375rem;
  color: var(--c-ink-900);
  font-weight: 500;
}

.detail-item .val.price {
  font-family: var(--font-display);
  color: var(--c-blue);
  font-size: 1.125rem;
}

/* 考试科目标签 */
.subject-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin-top: var(--s-3);
}

.subject-tag {
  padding: var(--s-1) var(--s-3);
  border: 1px solid var(--c-ink-100);
  border-radius: 100px;
  font-size: 0.8125rem;
  color: var(--c-ink-700);
  background: var(--c-bg);
}

/* ---------- 空状态 ---------- */
.empty-state {
  text-align: center;
  padding: var(--s-20) var(--s-8);
  color: var(--c-ink-300);
}

.empty-state .empty-icon {
  font-size: 2.5rem;
  margin-bottom: var(--s-4);
  display: block;
}

.empty-state p {
  font-size: 0.9375rem;
}

/* ---------- 加载状态 ---------- */
.skeleton {
  border-radius: var(--r-sm);
  background: linear-gradient(
    90deg,
    var(--c-surface2) 0%,
    var(--c-ink-100) 50%,
    var(--c-surface2) 100%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ---------- 分页 ---------- */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  padding: var(--s-8) 0;
}

.page-btn {
  min-width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  padding: 0 var(--s-2);
  border: 1px solid var(--c-ink-100);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--c-ink-500);
  background: var(--c-bg);
  cursor: pointer;
  transition: all var(--dur-fast);
}

.page-btn:hover:not(:disabled) {
  border-color: var(--c-blue-line);
  color: var(--c-blue);
  background: var(--c-blue-ghost);
}

.page-btn.active {
  background: var(--c-blue);
  border-color: var(--c-blue);
  color: white;
}

.page-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.page-info {
  font-size: 0.875rem;
  color: var(--c-ink-300);
}

/* ---------- 工具栏 ---------- */
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--s-3);
  padding: var(--s-4) 0;
  border-bottom: 1px solid var(--c-ink-100);
  margin-bottom: var(--s-4);
}

.toolbar-left {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  flex-wrap: wrap;
}

.toolbar-right {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}

.result-count {
  font-size: 0.875rem;
  color: var(--c-ink-500);
}

.result-count strong {
  color: var(--c-ink-900);
  font-weight: 600;
}

/* ---------- 页脚 ---------- */
footer {
  padding: var(--s-12) 0;
  border-top: 1px solid var(--c-ink-100);
  margin-top: var(--s-16);
}

.footer-inner {
  max-width: var(--max-content);
  margin: 0 auto;
  padding: 0 var(--s-8);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: var(--s-4);
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--c-ink-900);
}

.footer-note {
  font-size: 0.8125rem;
  color: var(--c-ink-300);
}

/* ---------- 通知 Toast ---------- */
.toast-container {
  position: fixed;
  bottom: var(--s-6);
  right: var(--s-6);
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  z-index: 999;
  pointer-events: none;
}

.toast {
  padding: var(--s-3) var(--s-5);
  background: var(--c-ink-900);
  color: var(--c-bg);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  box-shadow: var(--shadow-lg);
  pointer-events: auto;
  animation: toast-in var(--dur-std) var(--ease-spring) forwards;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(10px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ---------- 响应式 ---------- */
@media (max-width: 768px) {
  :root { --nav-h: 52px; }

  .nav { padding: 0 var(--s-4); }
  .container { padding: 0 var(--s-4); }

  .nav-links a span { display: none; }  /* 小屏只显示图标 */

  .stats-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats-row .stat-item:nth-child(2) { border-right: none; }
  .stats-row .stat-item:nth-child(3) { border-top: 1px solid var(--c-ink-100); }

  .card-toggle {
    width: 20px;
    height: 20px;
    font-size: 0.6rem;
  }

  .entry-grid {
    grid-template-columns: 1fr;
  }

  .data-table thead th,
  .data-table tbody td {
    padding: var(--s-3);
  }

  .filter-bar { gap: var(--s-2); }

  .toolbar {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 480px) {
  :root { --nav-h: 48px; }

  .hero-title { font-size: 1.875rem; }
  .btn { padding: 0.5625rem var(--s-4); font-size: 0.875rem; }
  .stats-row { grid-template-columns: repeat(2, 1fr); }

  .stat-item { padding: var(--s-5) var(--s-4); }
  .stat-num { font-size: 1.375rem; }
  .stat-label { font-size: 0.75rem; }

  .card-item { padding: var(--s-2) var(--s-3); }
  .card-item-main h3 { font-size: 0.875rem; max-width: 140px; }
  .card-item-main .meta-info { font-size: 0.75rem; }

  .card-detail { padding: 0 var(--s-4) var(--s-4); }

  .section { padding: var(--s-10) 0; }
  .section-header { margin-bottom: var(--s-6); }
  .section-title { font-size: 1.125rem; }

  .filter-chip { font-size: 0.75rem; padding: 0.25rem var(--s-2); }
  .search-bar input { padding: 0.5625rem var(--s-3); font-size: 0.875rem; }
  .search-bar button { padding: 0.5625rem var(--s-3); font-size: 0.8125rem; }

  .data-table { font-size: 0.8125rem; }
  .data-table thead th,
  .data-table tbody td { padding: var(--s-2) var(--s-3); }

  .result-row { padding: var(--s-3); font-size: 0.8125rem; }
  .result-row .school-name { font-size: 0.875rem; }
  .result-row .price-val { font-size: 0.875rem; }

  .filter-panel { font-size: 0.8125rem; }
  .filter-panel-head { padding: var(--s-3) var(--s-4); }
  .filter-group { padding: var(--s-3) var(--s-4); }

  .fav-btn { width: 24px; height: 24px; font-size: 0.75rem; }
  .card-toggle { width: 24px; height: 24px; font-size: 0.6875rem; }

  .toast-container { bottom: var(--s-3); right: var(--s-3); }
  .toast { padding: var(--s-2) var(--s-4); font-size: 0.8125rem; }

  .entry-card { padding: var(--s-4); }
  .entry-card h3 { font-size: 0.9375rem; }
  .entry-card p { font-size: 0.8125rem; }

  .nav-links a { padding: var(--s-1) var(--s-2); }
}

@media (max-width: 380px) {
  .result-col-head { display: none; }
  .result-row {
    grid-template-columns: 1fr auto;
    gap: var(--s-1);
    padding: var(--s-3);
  }
  .result-row .school-name { font-size: 0.8125rem; }
  .result-row .col-hide { display: none; }
  .result-row .col-subj { display: none; }

  .data-table thead { display: none; }
  .card-detail .data-table-wrap {
    border: none;
    border-radius: 0;
    margin: 0 !important;
  }
  .card-detail .data-table tbody tr {
    display: block;
    padding: var(--s-2) var(--s-3);
    border: 1px solid var(--c-ink-100);
    border-radius: var(--r-md);
    margin-bottom: var(--s-2);
    background: var(--c-bg);
  }
  .card-detail .data-table tbody td {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: var(--s-1) 0;
    border-bottom: none;
    gap: var(--s-2);
    font-size: 0.8125rem;
  }
  .card-detail .data-table tbody td::before {
    content: attr(data-label);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--c-ink-300);
    white-space: nowrap;
    flex-shrink: 0;
  }
  .card-detail .data-table tbody td:first-child {
    font-weight: 500;
    color: var(--c-ink-900);
  }
}


/* ---------- 页面入场动画 ---------- */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.animate-in {
  animation: fade-up var(--dur-slow) var(--ease-out) both;
}

.animate-in:nth-child(2) { animation-delay: 60ms; }
.animate-in:nth-child(3) { animation-delay: 120ms; }
.animate-in:nth-child(4) { animation-delay: 180ms; }

/* ---------- 辅助类 ---------- */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border-width: 0;
}

.text-blue   { color: var(--c-blue); }
.text-muted  { color: var(--c-ink-500); }
.text-small  { font-size: 0.875rem; }
.font-num    { font-family: var(--font-display); font-variant-numeric: tabular-nums; }
.monospace   { font-family: var(--font-mono); font-size: 0.875em; }

/* 分割线 */
.divider {
  height: 1px;
  background: var(--c-ink-100);
  margin: var(--s-8) 0;
}
