/* ============================================================
   尊享会 — Premium Member System UI (2026)
   设计方向: 现代奢华 · 通透玻璃 · 柔和层次
   色系: 翡翠绿 × 琥珀金 × 冷灰白 × 深夜墨
   ============================================================ */

/* ===== CSS Variables ===== */
:root {
  /* Primary — emerald (翡翠) */
  --primary: #059669;
  --primary-dark: #047857;
  --primary-deep: #065f46;
  --primary-light: #34d399;
  --primary-bg: #ecfdf5;
  --primary-glow: rgba(16, 185, 129, .16);

  /* Accent — amber gold (琥珀金) */
  --accent: #f59e0b;
  --accent-dark: #b45309;
  --accent-light: #fef3c7;
  --accent-glow: rgba(245, 158, 11, .14);

  /* Rose — for special highlights */
  --rose: #f43f5e;
  --rose-light: #fff1f2;

  /* Neutrals — cool tones */
  --bg: #f6f7f9;
  --bg-card: #ffffff;
  --bg-subtle: #f1f3f5;
  --text: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --border: #e2e8f0;
  --border-light: #eef2f6;

  /* Semantic */
  --danger: #ef4444;
  --danger-light: #fef2f2;
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;

  /* Radius */
  --radius: 16px;
  --radius-sm: 12px;
  --radius-xs: 9px;
  --radius-full: 9999px;

  /* Shadows — soft layered depth */
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, .04);
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, .06), 0 1px 2px rgba(15, 23, 42, .04);
  --shadow: 0 4px 12px rgba(15, 23, 42, .06), 0 2px 4px rgba(15, 23, 42, .04);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, .08), 0 3px 8px rgba(15, 23, 42, .05);
  --shadow-lg: 0 16px 40px rgba(15, 23, 42, .1), 0 6px 16px rgba(15, 23, 42, .06);
  --shadow-xl: 0 24px 64px rgba(15, 23, 42, .14), 0 10px 24px rgba(15, 23, 42, .08);

  /* Motion */
  --ease: cubic-bezier(.4, 0, .2, 1);
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
  --transition: all .2s var(--ease);
  --transition-slow: all .35s var(--ease);
}

/* ===== Reset ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ===== Base ===== */
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans SC', 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  min-height: 100vh;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* 柔和的极光底色 */
  background-image:
    radial-gradient(1000px 520px at 0% -5%, rgba(16, 185, 129, .06) 0%, transparent 60%),
    radial-gradient(820px 420px at 100% 0%, rgba(245, 158, 11, .05) 0%, transparent 55%);
  background-attachment: fixed;
}

h1, h2, h3, .section-title, .brand, .profile-name, .teacher-name,
.announcement-title, .sub-panel-title, .modal-header h3 {
  letter-spacing: -.01em;
}

h1, h2, h3 {
  font-weight: 700;
  line-height: 1.3;
}

/* ===== Focus (a11y) ===== */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: var(--radius-xs);
}

button:focus:not(:focus-visible),
input:focus:not(:focus-visible) {
  outline: none;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ===== Selection ===== */
::selection { background: var(--primary-glow); color: var(--primary-deep); }

/* ===== Container ===== */
.container { max-width: 1120px; margin: 0 auto; padding: 0 20px; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 22px;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  font-family: inherit;
  letter-spacing: .01em;
  line-height: 1.4;
  position: relative;
  overflow: hidden;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

/* Ripple effect */
.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(255,255,255,.35) 0%, transparent 60%);
  opacity: 0;
  transition: opacity .3s;
}
.btn:active::after { opacity: 1; }

.btn-primary {
  background: linear-gradient(135deg, #10b981, var(--primary) 55%, var(--primary-dark));
  color: #fff;
  box-shadow: 0 2px 10px rgba(16, 185, 129, .28);
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(16, 185, 129, .36);
}
.btn-primary:active { transform: translateY(0); }

.btn-accent {
  background: linear-gradient(135deg, #fbbf24, var(--accent) 55%, var(--accent-dark));
  color: #fff;
  box-shadow: 0 2px 10px rgba(245, 158, 11, .26);
}
.btn-accent:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(245, 158, 11, .34);
}

.btn-danger { background: var(--danger); color: #fff; box-shadow: 0 2px 8px rgba(239, 68, 68, .22); }
.btn-danger:hover { background: #dc2626; transform: translateY(-1px); box-shadow: 0 6px 18px rgba(239, 68, 68, .3); }

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 1.5px solid var(--primary);
}
.btn-outline:hover {
  background: var(--primary);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
}
.btn-ghost:hover {
  background: var(--bg-subtle);
  color: var(--text);
  border-color: #cbd5e1;
}

.btn-sm { padding: 6px 14px; font-size: 13px; border-radius: var(--radius-xs); }
.btn-xs {
  padding: 4px 10px;
  font-size: 12px;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--primary);
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}
.btn-xs:hover { background: var(--primary-bg); border-color: var(--primary); }
.btn-full { width: 100%; }
.btn-success { background: var(--success); color: #fff; border: 1px solid var(--success); }
.btn-success:hover { background: #059669; }
.btn-warning { background: var(--warning); color: #fff; border: 1px solid var(--warning); }
.btn-warning:hover { background: var(--accent-dark); }
.btn-disabled { opacity: .5; cursor: not-allowed; pointer-events: none; }

/* ============================================================
   FORM ELEMENTS
   ============================================================ */
input, select, textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  background: var(--bg-card);
  transition: var(--transition);
  outline: none;
  line-height: 1.5;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-glow);
}
input::placeholder, textarea::placeholder {
  color: var(--text-muted);
}

label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.form-group { margin-bottom: 18px; }

/* ============================================================
   CARD
   ============================================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-slow);
}

/* ============================================================
   NAVBAR — 深翡翠渐变 + 玻璃
   ============================================================ */
.navbar {
  background: linear-gradient(135deg, #03251f 0%, #064e3b 50%, #047857 100%);
  color: #fff;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 20px rgba(3, 37, 31, .28);
  backdrop-filter: blur(12px) saturate(140%);
}
.navbar .brand {
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: .02em;
}
.navbar .brand::before {
  content: '';
  font-size: 18px;
}
.navbar .nav-right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.navbar .user-name {
  font-size: 13px;
  color: rgba(255,255,255,.85);
  font-weight: 500;
}
.btn-logout {
  background: rgba(255,255,255,.12);
  color: rgba(255,255,255,.92);
  border: 1px solid rgba(255,255,255,.16);
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-size: 13px;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
  backdrop-filter: blur(6px);
}
.btn-logout:hover {
  background: rgba(255,255,255,.22);
  transform: translateY(-1px);
}

/* ============================================================
   PAGE CONTENT
   ============================================================ */
.page-content { padding: 28px 5% 80px; }
.page-content .section-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--accent-dark);
}

/* Tab panels */
.member-tab-content,
.admin-tab-content {
  padding: 20px 5% 90px;
  min-height: calc(100vh - 56px);
}
.member-panel, .admin-panel { display: none; }
.member-panel.active, .admin-panel.active {
  display: block;
  animation: fadeSlideIn .35s var(--ease);
}
@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.panel-header {
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.panel-header .section-title { margin-bottom: 0; }

/* ============================================================
   BOTTOM TAB BAR — 玻璃 + 胶囊指示
   ============================================================ */
.bottom-tab-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-top: 1px solid rgba(15, 23, 42, .06);
  display: flex;
  z-index: 100;
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.bottom-tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8px 0 6px;
  gap: 2px;
  cursor: pointer;
  transition: var(--transition);
  color: var(--text-muted);
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  position: relative;
}
.bottom-tab svg { width: 22px; height: 22px; transition: var(--transition); }
.bottom-tab span {
  font-size: 11px;
  font-weight: 500;
  transition: var(--transition);
}
.bottom-tab.active { color: var(--primary); }
.bottom-tab.active span { font-weight: 700; }
/* Pill indicator */
.bottom-tab.active::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 50%;
  transform: translateX(-50%);
  width: 28px;
  height: 3px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--primary-light), var(--primary));
}
.bottom-tab:active { opacity: .7; }

/* ============================================================
   SECTION TITLE — 装饰条
   ============================================================ */
.section-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
}
.section-title::before {
  content: '';
  width: 4px;
  height: 18px;
  background: linear-gradient(to bottom, var(--primary-light), var(--primary));
  border-radius: 2px;
}

/* ============================================================
   PROFILE — centered avatar card
   ============================================================ */
.profile-user-card {
  text-align: center;
  margin-bottom: 24px;
  padding: 32px 0 20px;
}
.avatar-circle {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, #10b981, var(--primary));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  color: #fff;
  margin: 0 auto 14px;
  box-shadow: 0 8px 24px rgba(16, 185, 129, .3);
  border: 3px solid #fff;
}
.profile-name {
  font-size: 19px;
  font-weight: 800;
  background: linear-gradient(135deg, #f59e0b, #fbbf24, #f59e0b);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 4px;
}
.profile-date {
  font-size: 12px;
  color: var(--text-muted);
}
.info-card { margin-bottom: 14px; }

/* ===== Info Grid ===== */
.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 24px;
}
.info-item {
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  padding: 16px 12px;
  text-align: center;
  transition: var(--transition);
}
.info-item:hover { background: var(--primary-bg); }
.info-item .info-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
  font-weight: 500;
}
.info-item .info-value {
  font-size: 20px;
  font-weight: 800;
  color: var(--primary);
}

/* ============================================================
   ANNOUNCEMENT
   ============================================================ */
.announcement-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 16px 24px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 10px;
  transition: var(--transition);
}
.announcement-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.announcement-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--rose);
}
.announcement-content {
  font-size: 15px;
  line-height: 1.85;
  color: var(--text-secondary);
  white-space: pre-wrap;
  word-break: break-word;
}
.announcement-time {
  font-size: 12px;
  color: var(--text-muted);
  text-align: right;
}

/* ============================================================
   TEACHER CARDS — 清新通透
   ============================================================ */
.teacher-list { display: flex; flex-direction: column; gap: 12px; }
.teacher-card {
  display: flex;
  gap: 16px;
  align-items: center;
  background: linear-gradient(135deg, #ecfdf5 0%, #ffffff 55%, #fffbeb 100%);
  border: 1px solid rgba(16, 185, 129, .14);
  border-radius: var(--radius);
  padding: 18px 16px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  color: inherit;
  position: relative;
}
.teacher-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  border-color: rgba(16, 185, 129, .3);
}
.teacher-card:active { transform: translateY(0); }

.teacher-avatar {
  width: 68px;
  height: 68px;
  border-radius: 18px;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--primary-light), var(--primary));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: #fff;
  overflow: hidden;
  box-shadow: 0 6px 16px rgba(16, 185, 129, .24);
  border: 2px solid #fff;
}
.teacher-avatar img { width: 100%; height: 100%; object-fit: cover; }
.teacher-info { flex: 1; min-width: 0; }
.teacher-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 6px;
}
/* 高亮整卡 — 金框 + 金光铺满 */
.teacher-card.highlighted-card {
  border-color: rgba(251, 191, 36, .55) !important;
  box-shadow: 0 0 16px rgba(251, 191, 36, .18), 0 0 32px rgba(245, 158, 11, .1);
  position: relative;
  overflow: hidden;
}
/* 斜向金光扫过 — 光柱划过，金色永久保留 */
.teacher-card.highlighted-card::before {
  content: '';
  position: absolute;
  top: -80%; left: -150%;
  width: 150%; height: 260%;
  background: linear-gradient(90deg,
    transparent 0%,
    transparent 85%,
    rgba(255, 240, 150, .5) 90%,
    #ffd700 95%,
    rgba(255, 240, 150, .5) 100%
  );
  transform: skewX(-18deg);
  animation: sweepIn 1.8s ease-in-out 1 forwards;
  pointer-events: none;
  z-index: 0;
}
.teacher-card.highlighted-card::after {
  content: '';
  position: absolute;
  top: -80%; left: -150%;
  width: 150%; height: 260%;
  background: linear-gradient(90deg,
    rgba(255, 215, 0, .15) 0%,
    rgba(255, 200, 50, .2) 50%,
    rgba(255, 220, 100, .18) 100%
  );
  transform: skewX(-18deg);
  animation: sweepStay 1.8s ease-in-out 1 forwards;
  pointer-events: none;
  z-index: 0;
}
.teacher-card.highlighted-card > * {
  position: relative;
  z-index: 1;
}
@keyframes sweepIn {
  0% { left: -150%; }
  100% { left: 5%; }
}
@keyframes sweepStay {
  0% { left: -150%; }
  100% { left: -5%; }
}

.teacher-name.highlighted {
  font-weight: 800;
  color: #dc2626;
}

/* 金色极品铭牌 */
.highlight-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, #ffd700 0%, #ff8c00 50%, #ffd700 100%);
  padding: 2px 6px;
  border-radius: 5px;
  margin-left: 4px;
  vertical-align: super;
  text-shadow: 0 1px 2px rgba(0,0,0,.3);
  box-shadow: 0 1px 4px rgba(255, 140, 0, .4);
  animation: badgeGlow 2s ease-in-out infinite;
  letter-spacing: 1px;
  line-height: 1;
}
@keyframes badgeGlow {
  0%, 100% { box-shadow: 0 1px 4px rgba(255, 140, 0, .4); }
  50% { box-shadow: 0 1px 8px rgba(255, 200, 0, .7), 0 0 12px rgba(255, 140, 0, .3); }
}

.teacher-meta-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.meta-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 8px;
  min-width: 2.6em;
  background: rgba(255, 255, 255, .75);
  border: 1px solid rgba(16, 185, 129, .16);
  border-radius: var(--radius-full);
  font-size: 11px;
  color: var(--primary-dark);
  font-weight: 600;
  white-space: nowrap;
  transition: var(--transition);
  flex-shrink: 0;
}
.teacher-card:hover .meta-tag {
  background: rgba(255, 255, 255, .95);
  border-color: rgba(16, 185, 129, .3);
}

.fee-card {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, var(--accent-light), #fff7ed);
  border: 1px solid #fcd34d;
  border-radius: var(--radius-xs);
  padding: 6px 16px;
  margin: 0 6px 4px;
  box-shadow: 0 1px 4px rgba(245, 158, 11, .14);
  cursor: pointer;
  font-family: inherit;
  transition: var(--transition);
}
.fee-card:hover {
  background: linear-gradient(135deg, #fde68a, #fef3c7);
  box-shadow: 0 4px 14px rgba(245, 158, 11, .24);
  transform: translateY(-1px);
}
.fee-card:active { transform: translateY(0); }
.fee-label { font-size: 16px; color: var(--accent-dark); font-weight: 700; }
.fee-price { font-size: 16px; font-weight: 700; color: var(--accent); }

.teacher-arrow {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  flex-shrink: 0;
  background: rgba(255, 255, 255, .7);
  border: 1px solid rgba(16, 185, 129, .18);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 16px;
  transition: var(--transition);
}
.teacher-card:hover .teacher-arrow {
  background: var(--primary-bg);
  color: var(--primary);
  border-color: var(--primary-light);
  transform: translateX(3px);
}

/* ============================================================
   CUSTOMER SERVICE CARDS
   ============================================================ */
.cs-contact-card {
  display: flex;
  gap: 14px;
  align-items: center;
  background: linear-gradient(135deg, var(--primary-bg) 0%, #f0fdf4 100%);
  border: 1px solid rgba(16, 185, 129, .16);
  border-radius: var(--radius);
  padding: 16px 18px;
  cursor: pointer;
  transition: var(--transition);
}
.cs-contact-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.cs-contact-card:active { transform: translateY(0); }

.cs-contact-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  flex-shrink: 0;
  background: linear-gradient(135deg, #10b981, var(--primary-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 14px rgba(16, 185, 129, .26);
}
.cs-contact-icon svg { width: 22px; height: 22px; color: #fff; }
.cs-contact-info { flex: 1; min-width: 0; }
.cs-contact-title { font-size: 15px; font-weight: 700; color: var(--primary-deep); }
.cs-contact-desc { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.cs-contact-arrow {
  width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
  background: rgba(255, 255, 255, .7); border: 1px solid rgba(16, 185, 129, .16);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary); font-size: 18px; font-weight: 700;
  transition: var(--transition);
}
.cs-contact-card:hover .cs-contact-arrow {
  background: rgba(255, 255, 255, .95);
  transform: translateX(2px);
}

.cs-alt-card {
  display: flex; gap: 14px; align-items: center;
  margin-top: 10px;
  background: linear-gradient(135deg, #eef2ff 0%, #f5f3ff 100%);
  border: 1px solid rgba(99, 102, 241, .14);
  border-radius: var(--radius);
  padding: 16px 18px;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-xs);
}
.cs-alt-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.cs-alt-card:active { transform: translateY(0); }
.cs-alt-icon {
  width: 46px; height: 46px; border-radius: 14px; flex-shrink: 0;
  background: linear-gradient(135deg, #818cf8, #6366f1);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 14px rgba(99, 102, 241, .26);
}
.cs-alt-icon svg { width: 22px; height: 22px; color: #fff; }
.cs-alt-info { flex: 1; min-width: 0; }
.cs-alt-title { font-size: 15px; font-weight: 700; color: #4338ca; }
.cs-alt-desc { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.cs-alt-arrow {
  width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
  background: rgba(255, 255, 255, .7); border: 1px solid rgba(99, 102, 241, .16);
  display: flex; align-items: center; justify-content: center;
  color: #6366f1; font-size: 18px; font-weight: 700;
  transition: var(--transition);
}
.cs-alt-card:hover .cs-alt-arrow { transform: translateX(2px); }

/* ============================================================
   AD MARQUEE
   ============================================================ */
.ad-marquee {
  flex: 1; min-width: 0;
  display: flex; align-items: center;
  height: 18px;
}
.ad-marquee-clip {
  flex: 1; min-width: 0; overflow: hidden;
  line-height: 18px;
}
.ad-marquee-inner {
  white-space: nowrap;
  font-size: 15px; font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 50%, #fbbf24 100%);
  padding: 2px 12px;
  border-radius: 6px;
  text-shadow: 0 1px 2px rgba(0,0,0,.25);
  line-height: 1.4;
  will-change: transform;
  letter-spacing: .02em;
  display: inline-block;
}

/* ============================================================
   TEACHER DETAIL PAGE
   ============================================================ */
.teacher-detail-header { margin-bottom: 32px; }
.teacher-meta { flex: 1; }
.teacher-meta h1 {
  font-size: 26px;
  font-weight: 800;
  color: var(--primary-deep);
  margin-bottom: 16px;
  text-align: center;
}
.meta-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}
.meta-item {
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  padding: 14px 8px;
  text-align: center;
  transition: var(--transition);
}
.meta-item:hover { background: var(--primary-bg); }
.meta-item .meta-label { font-size: 12px; color: var(--text-muted); font-weight: 500; }
.meta-item .meta-val {
  font-size: 17px;
  font-weight: 800;
  color: var(--primary);
  margin-top: 4px;
}
.course-box {
  background: var(--primary-bg);
  border: 1px solid rgba(16, 185, 129, .14);
  border-radius: var(--radius-sm);
  padding: 18px;
  font-size: 16px;
  line-height: 1.8;
  color: var(--primary-deep);
  font-weight: 600;
  text-align: left;
}

/* Back navigation */
.back-card {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  margin-bottom: 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  color: var(--primary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  box-shadow: var(--shadow-xs);
  transition: var(--transition);
}
.back-card:hover {
  box-shadow: var(--shadow);
  background: var(--primary-bg);
  transform: translateX(-2px);
}
.back-card svg { width: 18px; height: 18px; }
.back-card-nav {
  background: rgba(255, 255, 255, .12) !important;
  border: 1px solid rgba(255, 255, 255, .18) !important;
  color: #fff !important;
  padding: 6px 14px !important;
  margin-bottom: 0 !important;
  box-shadow: none !important;
  backdrop-filter: blur(8px);
  border-radius: var(--radius-xs) !important;
}
.back-card-nav svg { width: 16px; height: 16px; }
.back-card-nav:hover {
  background: rgba(255, 255, 255, .2) !important;
  box-shadow: none !important;
  color: #fff !important;
  transform: none;
}

/* Photo gallery */
.photo-gallery { display: flex; flex-direction: column; gap: 14px; margin-bottom: 32px; }
.photo-gallery img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}
.photo-gallery img:hover { box-shadow: var(--shadow-md); transform: scale(1.01); }

.video-section { margin-bottom: 32px; }
.video-section h3 { font-size: 17px; font-weight: 700; margin-bottom: 16px; color: var(--text); }
.video-wrapper {
  background: #000;
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 800px;
}
.video-wrapper video { width: 100%; display: block; }
.video-placeholder {
  background: var(--bg-subtle);
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 60px;
  text-align: center;
  color: var(--text-muted);
}

/* ============================================================
   ADMIN SECTIONS
   ============================================================ */
.admin-section {
  margin-bottom: 32px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border-light);
}
.admin-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

/* ===== Sub Tabs ===== */
.sub-tabs {
  display: flex;
  gap: 2px;
  border-bottom: 1px solid var(--border-light);
  margin: 12px 0 16px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  justify-content: center;
}
.sub-tab {
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  font-family: inherit;
  transition: var(--transition);
  white-space: nowrap;
  border-radius: 4px 4px 0 0;
}
.sub-tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
  font-weight: 700;
  background: var(--primary-bg);
}
.sub-tab:hover { color: var(--primary); background: rgba(16, 185, 129, .05); }

.sub-panel { display: none; }
.sub-panel.active { display: block; animation: fadeSlideIn .3s var(--ease); }
.sub-panel-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
}

/* ============================================================
   STATISTICS CARDS — 渐变描边
   ============================================================ */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}
.stats-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 20px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: var(--shadow-xs);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}
.stats-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  border-radius: 0 2px 2px 0;
}
.stats-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }

.stats-card-active::before { background: linear-gradient(to bottom, #34d399, var(--primary)); }
.stats-card-total::before { background: linear-gradient(to bottom, #fbbf24, var(--accent)); }
.stats-card-new::before { background: linear-gradient(to bottom, #818cf8, #6366f1); }
.stats-card-balance::before { background: linear-gradient(to bottom, #fbbf24, var(--warning)); }
.stats-card-purchase-count::before { background: linear-gradient(to bottom, #f87171, #ef4444); }
.stats-card-purchase-amount::before { background: linear-gradient(to bottom, #fb923c, #f97316); }

.stats-icon {
  width: 46px;
  height: 46px;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 20px;
}
.stats-icon svg { width: 22px; height: 22px; }
.stats-card-active .stats-icon { background: var(--primary-bg); color: var(--primary); }
.stats-card-total .stats-icon { background: var(--accent-light); color: var(--accent-dark); }
.stats-card-new .stats-icon { background: #eef2ff; color: #6366f1; }
.stats-card-balance .stats-icon { background: var(--warning-light); color: var(--warning); }
.stats-card-purchase-count .stats-icon { background: var(--rose-light); color: #f43f5e; }
.stats-card-purchase-amount .stats-icon { background: #fff7ed; color: #f97316; }

.stats-info { flex: 1; min-width: 0; }
.stats-value {
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.1;
  margin-bottom: 3px;
  font-variant-numeric: tabular-nums;
}
.stats-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}

@media (max-width: 900px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .stats-card { padding: 16px 14px; gap: 12px; }
  .stats-value { font-size: 22px; }
}
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .stats-card { padding: 14px 12px; flex-direction: column; text-align: center; gap: 8px; }
  .stats-icon { width: 36px; height: 36px; }
  .stats-value { font-size: 20px; }
}

/* ============================================================
   TABLES — 清爽无斑马纹
   ============================================================ */
.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 12px;
}

.data-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.data-table {
  white-space: nowrap;
}
.data-table th, .data-table td {
  padding: 12px 14px;
  text-align: left;
  font-size: 13px;
  border-bottom: 1px solid var(--border-light);
}
.data-table th {
  background: #f8fafc;
  font-weight: 600;
  color: var(--text-secondary);
  font-size: 12px;
  text-transform: none;
  letter-spacing: .02em;
}
.data-table tbody tr { transition: background .15s ease; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover td { background: var(--primary-bg); }
.data-table tbody tr:hover td:first-child {
  box-shadow: inset 3px 0 0 var(--primary);
}

.review-table th, .review-table td { white-space: nowrap; }

.status-active {
  background: var(--success-light);
  color: var(--success);
  padding: 2px 10px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
}
.status-used {
  background: var(--bg-subtle);
  color: var(--text-muted);
  padding: 2px 10px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
}
.status-banned {
  background: var(--danger);
  color: #fff;
  padding: 2px 10px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
}

.action-btns { display: flex; gap: 6px; flex-wrap: wrap; }

/* Status badges */
.status-badge {
  display: inline-block;
  padding: 3px 12px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.status-shown { background: var(--success-light); color: var(--success); }
.status-hidden { background: var(--bg-subtle); color: var(--text-muted); border: 1px solid var(--border); }
.status-pending { background: var(--warning-light); color: var(--accent-dark); }
.status-approved { background: var(--success-light); color: var(--success); }
.status-banned { background: var(--danger-light); color: var(--danger); }
.status-active { background: var(--success-light); color: var(--success); }
.status-used { background: var(--bg-subtle); color: var(--text-muted); }

/* ============================================================
   RECHARGE PANEL
   ============================================================ */
.recharge-panel { max-width: 480px; width: 100%; margin: 0 auto; }
.recharge-select { margin-bottom: 16px; }
.recharge-amount { margin-bottom: 20px; }
.recharge-confirm { font-size: 15px; }

/* ============================================================
   MODALS — 圆角玻璃
   ============================================================ */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .4);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.modal-overlay.show { display: flex; }

.modal {
  background: var(--bg-card);
  border-radius: 20px;
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 500px;
  max-height: 85vh;
  overflow-y: auto;
  animation: modalIn .25s var(--ease-spring);
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(.95) translateY(12px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.modal-header h3 { font-size: 17px; font-weight: 700; color: var(--text); }
.modal-close {
  width: 32px;
  height: 32px;
  border: none;
  background: var(--bg-subtle);
  border-radius: 50%;
  cursor: pointer;
  font-size: 18px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.modal-close:hover {
  background: var(--border);
  color: var(--text);
  transform: rotate(90deg);
}
.modal-body { padding: 24px; }
.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border-light);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* ============================================================
   PASSWORD SECTION
   ============================================================ */
.password-section { margin-top: 0; }
.password-form { display: flex; flex-direction: column; gap: 0; }
.password-form .form-group { flex: 1; min-width: 100%; margin-bottom: 16px; }

/* ============================================================
   LOGIN LOGS
   ============================================================ */
.login-log-section { margin-top: 16px; }
.login-log-list { display: flex; flex-direction: column; gap: 0; }
.login-log-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
  font-size: 13px;
}
.login-log-item:last-child { border-bottom: none; }
.log-index {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary-bg);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}
.log-time {
  flex: 1;
  color: var(--text-secondary);
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.log-ip {
  color: var(--text-muted);
  font-size: 12px;
  font-family: 'SF Mono', 'Cascadia Code', 'Consolas', monospace;
  flex-shrink: 0;
}

/* ============================================================
   MEMBER PICKER (RECHARGE)
   ============================================================ */
.member-picker { position: relative; }
.member-picker input[type="text"] {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--text);
  background: var(--bg-card);
  outline: none;
  transition: var(--transition);
}
.member-picker input[type="text"]:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-glow);
}
.member-picker input[type="text"]::placeholder { color: var(--text-muted); font-size: 13px; }

.picker-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  box-shadow: var(--shadow-md);
  max-height: 220px;
  overflow-y: auto;
  z-index: 100;
}
.picker-option {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 14px;
  cursor: pointer;
  transition: background .15s;
  border-bottom: 1px solid var(--border-light);
}
.picker-option:last-child { border-bottom: none; }
.picker-option:hover { background: var(--primary-bg); }
.picker-option strong { font-size: 14px; color: var(--text); }
.picker-option-info { font-size: 12px; color: var(--text-muted); }
.picker-hint { padding: 12px 14px; font-size: 13px; color: var(--text-muted); text-align: center; }

.picker-selected {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: var(--primary-bg);
  border: 1px solid rgba(16, 185, 129, .24);
  border-radius: var(--radius-sm);
}
.picker-sel-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.picker-sel-info strong { font-size: 14px; color: var(--text); }
.picker-sel-detail { font-size: 12px; color: var(--text-muted); }
.picker-clear-btn { flex-shrink: 0; min-width: auto; padding: 4px 10px; font-size: 18px; line-height: 1; }

/* ============================================================
   SEARCH BARS
   ============================================================ */
.member-search-bar { margin-bottom: 12px; }
.member-search-bar input {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--text);
  background: var(--bg-card);
  outline: none;
  transition: var(--transition);
}
.member-search-bar input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-glow);
}
.member-search-bar input::placeholder { color: var(--text-muted); }

/* ============================================================
   PAGINATION
   ============================================================ */
.pagination-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 14px;
  padding: 8px 0;
}
.pagination-bar button:disabled {
  opacity: .4;
  cursor: not-allowed;
}

/* ============================================================
   INVITE BOX
   ============================================================ */
.invite-box {
  background: linear-gradient(135deg, var(--primary-bg) 0%, var(--accent-light) 100%);
  border: 1px solid rgba(16, 185, 129, .14);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 24px;
}

/* ============================================================
   EMPTY STATE — illustrated
   ============================================================ */
.empty-state {
  text-align: center;
  padding: 64px 20px;
  color: var(--text-muted);
}
.empty-state .empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: .4;
  filter: grayscale(.4);
}
.empty-state p {
  font-size: 14px;
  font-weight: 500;
}

/* ============================================================
   LIGHTBOX
   ============================================================ */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .92);
  z-index: 300;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(12px);
}
.lightbox.show { display: flex; }
.lightbox img {
  max-width: 92%;
  max-height: 92%;
  border-radius: var(--radius);
  box-shadow: var(--shadow-xl);
}

/* ============================================================
   REVIEWS
   ============================================================ */
.review-section { margin-bottom: 32px; }
.review-form {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}
.rating-group { display: flex; gap: 24px; margin-bottom: 20px; flex-wrap: wrap; }
.rating-item { flex: 1; min-width: 140px; }
.rating-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.star-rating { display: flex; gap: 4px; }
.star-rating .star {
  font-size: 26px;
  cursor: pointer;
  color: var(--border);
  transition: color .12s ease, transform .15s var(--ease-spring);
  user-select: none;
  line-height: 1;
}
.star-rating .star:hover { transform: scale(1.2); }
.star-rating .star.active { color: #f59e0b; filter: drop-shadow(0 1px 3px rgba(245, 158, 11, .35)); }
.star-rating .star.hover-preview { color: #fbbf24; }

.review-textarea {
  width: 100%;
  min-height: 80px;
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  background: var(--bg-card);
  resize: vertical;
  transition: var(--transition);
  outline: none;
}
.review-textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-glow);
}
.review-submit-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
}

.review-list { display: flex; flex-direction: column; gap: 12px; }
.review-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow-xs);
  transition: var(--transition);
}
.review-card:hover { box-shadow: var(--shadow); }
.review-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.review-user {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.review-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #10b981, var(--primary));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: #fff;
  flex-shrink: 0;
}
.review-time { font-size: 12px; color: var(--text-muted); }
.review-stars { display: flex; gap: 16px; margin-bottom: 8px; flex-wrap: wrap; }
.review-stars-label { font-size: 12px; color: var(--text-muted); }
.review-stars-item { display: flex; align-items: center; gap: 4px; font-size: 12px; }
.review-stars-item .mini-star { color: #f59e0b; font-size: 14px; }
.review-stars-item .mini-star.dim { color: var(--border); }
.review-comment-text {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-secondary);
  white-space: pre-wrap;
  word-break: break-word;
  font-weight: 500;
}
.review-count-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 12px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
}
.review-count-pending { background: var(--warning-light); color: var(--accent-dark); }
.review-count-approved { background: var(--success-light); color: var(--success); }

/* ============================================================
   TOAST — 居中玻璃
   ============================================================ */
.toast-backdrop {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, .12);
  z-index: 9998;
  opacity: 0;
  transition: opacity .25s ease;
  pointer-events: none;
}
.toast-backdrop.show { opacity: 1; pointer-events: auto; }

.toast {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  padding: 18px 32px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .02em;
  z-index: 9999;
  opacity: 0;
  transition: opacity .25s ease, transform .3s var(--ease-spring);
  box-shadow: var(--shadow-lg);
  max-width: 80vw;
  text-align: center;
  pointer-events: none;
  backdrop-filter: blur(12px);
}
.toast.show { opacity: 1; transform: translate(-50%, -50%) scale(1.02); }
.toast.success {
  background: rgba(16, 185, 129, .92);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .2);
}
.toast.error {
  background: rgba(239, 68, 68, .92);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .2);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* ===== Toggle Switch ===== */
.toggle-switch {
  position: relative; display: inline-block; width: 44px; height: 24px; flex-shrink: 0; vertical-align: middle;
}
.toggle-switch.small { width: 36px; height: 20px; }
.toggle-switch input { display: none; }
.toggle-slider {
  position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  background: #cbd5e1; border-radius: 24px; cursor: pointer;
  transition: background .3s ease;
}
.toggle-slider::before {
  content: ''; position: absolute; top: 2px; left: 2px;
  width: 20px; height: 20px; border-radius: 50%;
  background: #fff; transition: transform .25s ease;
  box-shadow: 0 1px 3px rgba(15, 23, 42, .2);
}
.toggle-switch input:checked + .toggle-slider { background: var(--primary); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(20px); }
.toggle-switch.small input:checked + .toggle-slider::before { transform: translateX(14px); }
.toggle-switch.small .toggle-slider::before { width: 16px; height: 16px; top: 2px; left: 2px; }

@media (max-width: 768px) {
  .meta-grid { grid-template-columns: repeat(4, 1fr); gap: 8px; }
  .meta-item { padding: 10px 6px; }
  .data-table { font-size: 12px; }
  .data-table th, .data-table td { padding: 8px 10px; }
  .password-form { flex-direction: column; }
  .toolbar { flex-direction: column; align-items: stretch; }
  .section-title { font-size: 16px; }
  .navbar { padding: 0; }
  .teacher-meta h1 { font-size: 22px; }
  .sub-tab { padding: 8px 12px; font-size: 12px; }
}

@media (max-width: 480px) {
  .info-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .info-item { padding: 12px 10px; }
  .info-item .info-value { font-size: 16px; }
  .page-content { padding: 16px 4% 80px; }
  .member-tab-content,
  .admin-tab-content { padding: 14px 4% 90px; }
  .stats-card { padding: 14px 12px; }
  .stats-value { font-size: 20px; }
  .modal { max-width: 92vw; border-radius: var(--radius) var(--radius) 0 0; }
  .modal-header { padding: 16px 18px; }
  .modal-body { padding: 18px; }
  .modal-footer { padding: 14px 18px; }
  .navbar .brand { font-size: 15px; }
  .btn-logout { padding: 5px 12px; font-size: 12px; }
}

/* ===== 紧凑操作按钮 — 管理表格 ===== */
.data-table .action-btns .btn {
  padding: 3px 8px;
  font-size: 11px;
  white-space: nowrap;
  letter-spacing: 0;
}

/* ===== 去掉数字输入框的上下箭头 ===== */
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type="number"] {
  -moz-appearance: textfield;
}
