/* ============================================================
   student.css —— 学生端（登录页 + 学生主页）
   只用 style.css 的主题变量，换肤自动跟随
   ============================================================ */

/* ---------------- 学生主页 ---------------- */
.stu-body { background: var(--bg); }

/* 顶部：姓名 + 班级 + 操作（不吸顶，滚动时让位给下面的标签栏） */
.stu-top {
  background: var(--hero-grad);
  color: var(--on-primary);
  padding: 16px 16px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: relative;
  z-index: 30;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}
.stu-who { min-width: 0; }
.stu-name {
  font-size: 19px;
  font-weight: 700;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.stu-sub {
  font-size: 12px;
  opacity: 0.88;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.stu-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.stu-icon-btn {
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: transparent;
  color: var(--on-primary);
  font-size: 15px;
  cursor: pointer;
  line-height: 1;
}
.stu-icon-btn:active { background: rgba(255, 255, 255, 0.18); }
.stu-out-btn {
  height: 32px;
  padding: 0 12px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: transparent;
  color: var(--on-primary);
  font-size: 13px;
  cursor: pointer;
}
.stu-out-btn:active { background: rgba(255, 255, 255, 0.18); }

/* 标签：固定的两个入口（桌面居中，手机平分） */
.stu-tabs {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  gap: 8px;
  padding: 10px 16px;
  background: var(--card);
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  justify-content: center;
}
.stu-tab {
  flex: 0 1 220px;
  padding: 9px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--card-soft);
  color: var(--text-mid);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}
.stu-tab.active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--on-primary);
}

.stu-main { padding-bottom: 40px; }
/* 学生页里 parent-body 的左右留白已经在 .parent-body 里，这里不再叠加 */
.stu-main .parent-body { padding-top: 14px; }

.stu-flight-note {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--warn-light);
  border: 1px solid var(--border);
  font-size: 12.5px;
  line-height: 1.8;
  color: var(--warn-dark);
}

/* ---------------- 学生登录页 ---------------- */
.stu-login-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: var(--hero-grad);
}
.stu-login-card {
  width: 100%;
  max-width: 360px;
  background: var(--card);
  border-radius: 16px;
  padding: 28px 22px 22px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  text-align: center;
}
.stu-login-card .logo {
  width: 56px; height: 56px;
  margin: 0 auto 12px;
  border-radius: 16px;
  display: grid; place-items: center;
  font-size: 28px;
  background: var(--primary-light);
}
.stu-login-card h1 { font-size: 20px; margin-bottom: 4px; color: var(--text); }
.stu-login-card .hint {
  font-size: 12.5px;
  color: var(--text-light);
  line-height: 1.7;
  margin-bottom: 20px;
}
.stu-login-card .form-group { text-align: left; margin-bottom: 14px; }
.stu-login-card .form-group label {
  display: block;
  font-size: 13px;
  color: var(--text-mid);
  margin-bottom: 6px;
}
.stu-login-card .input {
  width: 100%;
  height: 46px;
  font-size: 16px;
  text-align: left;
}
.stu-login-card .btn-block { height: 46px; font-size: 16px; }

/* 6 位数字密码：字距拉开一点，念给孩子听更好认 */
#stuPass { letter-spacing: 2px; }

.stu-login-err {
  display: none;
  margin-bottom: 12px;
  padding: 9px 12px;
  border-radius: 8px;
  background: var(--danger-light);
  border: 1px solid var(--danger-border);
  color: var(--danger);
  font-size: 13px;
  line-height: 1.6;
  text-align: left;
}

.stu-login-foot {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px dashed var(--border);
  font-size: 12px;
  line-height: 1.8;
  color: var(--text-light);
  text-align: left;
}
.stu-login-foot a { color: var(--primary); }

@media (max-width: 560px) {
  .stu-top { padding: 14px 12px 12px; }
  .stu-name { font-size: 17px; }
  .stu-tabs { padding: 8px 12px; }
  .stu-tab { min-width: 0; flex: 1 1 0; font-size: 13.5px; }
}
