/* ==========================================================================
   职教通学习资源门户 —— 全局样式
   颜色规范：
     主蓝 #1A73E8  深蓝 #0D47A1  中蓝 #1565C0  边框 #E3E8EF
     文字灰 #5F6B7A  浅灰 #94A3B8  正文灰 #64748B  深色 #1E293B
     页脚深蓝 #182134  云币橙 #E65100  浅底 #F8FAFC  选中底 #EEF4FF
     悬停底 #EFF6FF  页面底 #F0F4F8  分隔线 #EEF2F7
   ========================================================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  background-color: #F0F4F8;
  color: #1E293B;
  font-size: 14px;
}

a { text-decoration: none; color: inherit; cursor: pointer; }
img { display: block; border: none; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }
ul, ol { list-style: none; }

/* ==========================================================================
   顶部导航栏（页面通用部分）
   高度 72px，背景白色，底部 1px #E3E8EF 实线，内容宽 1200px 居中
   ========================================================================== */
.site-header {
  width: 100%;
  height: 72px;
  background-color: #ffffff;
  border-bottom: 1px solid #E3E8EF;
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  width: 1200px;
  height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
}
/* 左侧品牌区 */
.brand {
  display: flex;
  align-items: center;
  height: 72px;
}
.brand img { width: 42px; height: 42px; margin-right: 10px; }
.brand .brand-name { font-size: 20px; color: #1A73E8; font-weight: 600; }
/* 中间导航栏 */
.nav { display: flex; align-items: center; height: 72px; margin-left: auto; }
.nav-item {
  display: flex;
  align-items: center;
  height: 72px;
  padding: 0 16px;
  font-size: 15px;
  color: #5F6B7A;
}
.nav-item:hover { color: #1A73E8; }
.nav-item.active {
  color: #ffffff;
  background-color: #1A73E8;
}
/* 右侧登录区 */
.auth {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: 24px;
}
.auth .btn-login,
.auth .btn-register {
  width: 60px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  border-radius: 4px;
}
.auth .btn-login {
  color: #1A73E8;
  border: 1px solid #1A73E8;
  background: transparent;
}
.auth .btn-register {
  color: #ffffff;
  background: linear-gradient(to right, #1A73E8, #0D47A1);
}
.auth .nickname {
  font-size: 14px;
  color: #1E293B;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.auth .btn-logout {
  width: 60px;
  height: 36px;
  color: #5F6B7A;
  border: 1px solid #E3E8EF;
  background: #ffffff;
  border-radius: 4px;
  font-size: 14px;
}
.auth .btn-logout:hover { color: #1A73E8; border-color: #1A73E8; }

/* ==========================================================================
   横幅区（各页面通用）
   全宽，高 336px，上下内边距 48px，水平渐变背景
   ========================================================================== */
.banner {
  width: 100%;
  min-height: 336px;
  padding: 48px 0;
  background: linear-gradient(90deg, #1A73E8 0%, #0D47A1 50%, #1565C0 100%);
  display: flex;
  align-items: center;
}
.banner-inner {
  width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.banner-left { flex: 1; }
.banner-left .banner-title {
  font-size: 34px;
  color: #ffffff;
  font-weight: bold;
  margin-bottom: 14px;
  line-height: 1.3;
}
.banner-left .banner-desc {
  font-size: 15px;
  color: #ffffff;
  line-height: 1.8;
  opacity: 0.95;
}
.banner-actions { display: flex; gap: 16px; margin-top: 26px; }
.banner-actions .banner-btn {
  height: 44px;
  padding: 0 26px;
  font-size: 15px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.banner-btn.primary { background: #ffffff; color: #1A73E8; }
.banner-btn.secondary { background: transparent; color: #ffffff; border: 1px solid #ffffff; }
.banner-right .banner-img {
  width: 420px;
  height: 240px;
  object-fit: cover;
  margin-left: 40px;
  border-radius: 8px;
}

/* ==========================================================================
   底部信息栏（页面通用部分）
   全宽，高 232px，背景 #182134，四栏布局
   ========================================================================== */
.site-footer {
  width: 100%;
  background-color: #182134;
}
.footer-inner {
  width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  padding: 40px 0 28px;
}
.footer-col { min-width: 180px; }
.footer-col h4 {
  font-size: 15px;
  color: #ffffff;
  font-weight: bold;
  margin-bottom: 16px;
}
.footer-col p,
.footer-col a {
  display: block;
  font-size: 13px;
  color: #94A3B8;
  line-height: 2;
}
.footer-col a:hover { color: #ffffff; }
.footer-col .brand-name { font-size: 18px; color: #ffffff; font-weight: bold; margin-bottom: 10px; }
.footer-col .brand-desc { max-width: 280px; line-height: 1.9; }
.footer-bottom {
  width: 1200px;
  margin: 0 auto;
  padding: 16px 0 20px;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  text-align: center;
  font-size: 13px;
  color: #94A3B8;
}

/* ==========================================================================
   通用容器与标题
   ========================================================================== */
.container { width: 1200px; margin: 0 auto; }
.section-title {
  display: flex;
  align-items: center;
  font-size: 24px;
  color: #1E293B;
  font-weight: bold;
  padding-left: 12px;
  position: relative;
}
.section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 24px;
  background-color: #1A73E8;
  border-radius: 2px;
}
.section-title .sub { font-size: 13px; color: #94A3B8; font-weight: normal; margin-left: 12px; }

/* 空状态 / 错误提示 */
.empty-state {
  padding: 60px 0;
  text-align: center;
  color: #94A3B8;
  font-size: 14px;
}
.toast {
  position: fixed;
  top: 90px;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 24px;
  background: #1E293B;
  color: #fff;
  font-size: 14px;
  border-radius: 6px;
  z-index: 999;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  opacity: 0;
  transition: opacity 0.25s;
  pointer-events: none;
}
.toast.show { opacity: 1; }

/* ==========================================================================
   首页
   ========================================================================== */
/* 快捷服务 */
.services {
  margin-top: 32px;
}
.services-list {
  display: flex;
  justify-content: space-between;
  gap: 20px;
}
.service-card {
  width: 389px;
  height: 118px;
  background: #ffffff;
  border-radius: 10px;
  box-shadow: 0 4px 16px rgba(24, 33, 52, 0.08);
  display: flex;
  align-items: center;
  padding: 22px 18px;
}
.service-card img { width: 52px; height: 52px; margin-right: 16px; flex-shrink: 0; }
.service-card .service-title { font-size: 16px; color: #1E293B; font-weight: bold; margin-bottom: 6px; }
.service-card .service-desc { font-size: 12px; color: #64748B; line-height: 1.5; }

/* 热门资源 */
.hot-resources { margin-top: 40px; }
.hot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.hot-head .section-title { font-size: 24px; }
.hot-head .hot-sub { font-size: 13px; color: #94A3B8; }
.hot-list {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}
.hot-card {
  width: 585px;
  height: 160px;
  display: flex;
  background: #ffffff;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(24, 33, 52, 0.06);
}
.hot-card .hot-img { width: 200px; height: 100%; object-fit: cover; flex-shrink: 0; }
.hot-card .hot-body { flex: 1; padding: 16px 18px; display: flex; flex-direction: column; }
.hot-card .hot-name { font-size: 17px; color: #1E293B; font-weight: bold; margin-bottom: 8px; }
.hot-card .hot-desc {
  font-size: 13px;
  color: #64748B;
  line-height: 1.6;
  flex: 1;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.hot-card .hot-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}
.hot-card .hot-price { color: #E65100; font-size: 15px; font-weight: bold; }
.hot-card .hot-stats { color: #94A3B8; font-size: 12px; }
.hot-card .hot-stats span { margin-left: 12px; }

/* 数据统计条 */
.statistics { margin: 40px auto 60px; }
.stat-list { display: flex; justify-content: space-between; gap: 20px; }
.stat-card {
  flex: 1;
  background: #ffffff;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(24, 33, 52, 0.06);
  padding: 28px 0;
  text-align: center;
}
.stat-card .stat-num { font-size: 30px; color: #1A73E8; font-weight: bold; margin-bottom: 6px; }
.stat-card .stat-label { font-size: 13px; color: #64748B; }

/* ==========================================================================
   资源中心
   ========================================================================== */
.resource-main { display: flex; gap: 20px; margin: 32px auto 48px; }
/* 左侧筛选栏 */
.filter-panel {
  width: 220px;
  background: #ffffff;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(24, 33, 52, 0.06);
  height: fit-content;
}
.filter-panel .filter-title {
  font-size: 16px;
  color: #1E293B;
  font-weight: bold;
  padding: 16px 18px 12px;
}
.filter-item {
  display: flex;
  align-items: center;
  padding: 12px 18px;
  font-size: 14px;
  color: #5F6B7A;
  cursor: pointer;
  border-left: 3px solid transparent;
}
.filter-item:hover { background: #F8FAFC; }
.filter-item.active {
  color: #1A73E8;
  background-color: #EEF4FF;
  border-left: 3px solid #1A73E8;
}
/* 右侧资源列表 */
.resource-panel {
  flex: 1;
  width: 960px;
  background: #ffffff;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(24, 33, 52, 0.06);
  padding: 20px 20px 24px;
}
.resource-panel .panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.resource-panel .panel-title { font-size: 18px; color: #1E293B; font-weight: bold; }
.resource-panel .panel-count { font-size: 13px; color: #94A3B8; }
/* 排序栏 */
.sort-bar { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.sort-btn {
  padding: 6px 14px;
  font-size: 13px;
  color: #64748B;
  background-color: #F8FAFC;
  border: 1px solid #E3E8EF;
  border-radius: 4px;
}
.sort-btn:hover { color: #1A73E8; border-color: #1A73E8; }
.sort-btn.active { background-color: #1A73E8; color: #ffffff; border-color: #1A73E8; }
.sort-hint {
  font-size: 12px;
  color: #94A3B8;
  margin-bottom: 16px;
  padding: 8px 12px;
  background: #F8FAFC;
  border-radius: 4px;
}
/* 资源卡片 */
.resource-grid { display: flex; flex-wrap: wrap; gap: 16px; }
.resource-card {
  width: 298px;
  margin-bottom: 16px;
  background: #ffffff;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(24, 33, 52, 0.06);
}
.resource-card .card-cover { position: relative; height: 150px; overflow: hidden; }
.resource-card .card-cover img { width: 100%; height: 100%; object-fit: cover; }
.resource-card .card-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 10px;
  background-color: #1A73E8;
  color: #ffffff;
  font-size: 12px;
  border-radius: 4px;
}
.resource-card .card-body { padding: 12px 14px 14px; }
.resource-card .card-title { font-size: 15px; color: #1E293B; font-weight: bold; margin-bottom: 6px; }
.resource-card .card-desc {
  font-size: 12px;
  color: #64748B;
  line-height: 1.5;
  margin-bottom: 10px;
  height: 36px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.resource-card .card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.resource-card .card-price { font-size: 16px; color: #E65100; font-weight: bold; }
.resource-card .card-stats { font-size: 12px; color: #94A3B8; }
.resource-card .card-stats span { margin-left: 10px; }
.resource-card .btn-download {
  display: block;
  width: 100%;
  height: 34px;
  line-height: 32px;
  text-align: center;
  color: #1A73E8;
  border: 1px solid #1A73E8;
  border-radius: 4px;
  font-size: 14px;
  background: transparent;
}
.resource-card .btn-download:hover { background: #EEF4FF; }

/* ==========================================================================
   帮助中心
   ========================================================================== */
.help-main { margin: 32px auto 48px; }
.help-panel {
  width: 1200px;
  background: #ffffff;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(24, 33, 52, 0.06);
  padding: 28px 32px 36px;
}
.help-panel .panel-title { font-size: 22px; color: #1E293B; font-weight: bold; padding-left: 12px; position: relative; }
.help-panel .panel-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 22px;
  background-color: #1A73E8;
  border-radius: 2px;
}
.help-panel .panel-sub { font-size: 13px; color: #94A3B8; margin: 6px 0 8px 12px; }
.guide-item {
  display: flex;
  padding: 20px 0;
  border-bottom: 1px solid #EEF2F7;
  cursor: pointer;
}
.guide-item:last-child { border-bottom: none; }
.guide-item img { width: 200px; height: 130px; object-fit: cover; margin-right: 24px; flex-shrink: 0; border-radius: 6px; }
.guide-item .guide-title { font-size: 17px; color: #1E293B; font-weight: bold; margin-bottom: 10px; }
.guide-item .guide-title:hover { color: #1A73E8; }
.guide-item .guide-desc { font-size: 14px; color: #64748B; line-height: 1.7; margin-bottom: 10px; }
.guide-item .guide-tips { font-size: 12px; color: #94A3B8; }

/* ==========================================================================
   学科分类
   ========================================================================== */
.subject-main { margin: 32px auto 48px; }
.subject-panel {
  width: 1200px;
  background: #ffffff;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(24, 33, 52, 0.06);
  padding: 24px 28px 32px;
}
.subject-panel .panel-title { font-size: 22px; color: #1E293B; font-weight: bold; padding-left: 12px; position: relative; }
.subject-panel .panel-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 22px;
  background-color: #1A73E8;
  border-radius: 2px;
}
.subject-panel .panel-sub { font-size: 13px; color: #94A3B8; margin: 6px 0 20px 12px; }
.subject-tabs { display: flex; gap: 20px; margin-bottom: 24px; }
.subject-tab {
  width: 360px;
  height: 92px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: #F8FAFC;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  cursor: pointer;
}
.subject-tab .tab-title { font-size: 16px; color: #1E293B; font-weight: bold; }
.subject-tab .tab-desc { font-size: 13px; color: #94A3B8; margin-top: 4px; }
.subject-tab:hover { background-color: #EFF6FF; }
.subject-tab:hover .tab-title { color: #1A73E8; }
.subject-tab.active {
  background: linear-gradient(to right, #1A73E8, #0D47A1);
  border-color: transparent;
}
.subject-tab.active .tab-title { color: #ffffff; }
.subject-tab.active .tab-desc { color: rgba(255, 255, 255, 0.85); }
/* 图墙 */
.subject-wall { display: flex; flex-wrap: wrap; gap: 16px; }
.subject-card { width: 360px; margin-bottom: 16px; background: #ffffff; border-radius: 8px; overflow: hidden; }
.subject-card img { width: 360px; height: 160px; object-fit: cover; }
.subject-card .subject-name { padding: 12px 14px; font-size: 14px; color: #1E293B; }

/* ==========================================================================
   关于我们
   ========================================================================== */
.about-main { margin: 32px auto 48px; }
.about-cards { display: flex; gap: 20px; }
.about-card {
  width: 580px;
  background: #ffffff;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(24, 33, 52, 0.06);
  padding: 28px 24px;
}
.about-card .about-title { font-size: 20px; color: #1E293B; font-weight: bold; margin-bottom: 14px; padding-bottom: 10px; border-bottom: 1px solid #EEF2F7; }
.about-card .about-text { font-size: 15px; color: #64748B; line-height: 1.9; margin-bottom: 10px; }
/* 联系我们 */
.contact-area {
  margin-top: 20px;
  background: linear-gradient(to right, #1A73E8, #0D47A1);
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(24, 33, 52, 0.08);
  padding: 26px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.contact-area .contact-left .contact-title { font-size: 18px; color: #ffffff; font-weight: bold; margin-bottom: 6px; }
.contact-area .contact-left .contact-desc { font-size: 13px; color: rgba(255, 255, 255, 0.85); }
.contact-area .contact-email {
  padding: 10px 22px;
  background: #ffffff;
  color: #1A73E8;
  border-radius: 6px;
  font-size: 14px;
}

/* ==========================================================================
   登录 / 注册
   ========================================================================== */
.auth-page {
  width: 100%;
  min-height: calc(100vh - 72px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 0;
}
.auth-box {
  width: 440px;
  background: #ffffff;
  border: 1px solid #E3E8EF;
  border-radius: 8px;
  padding: 32px 34px 34px;
  box-shadow: 0 4px 20px rgba(24, 33, 52, 0.08);
}
.auth-box .auth-title {
  font-size: 24px;
  color: #1A73E8;
  text-align: center;
  font-weight: bold;
  margin-bottom: 28px;
}
.form-item { margin-bottom: 16px; }
.form-item label { display: block; font-size: 14px; color: #1E293B; margin-bottom: 6px; }
.form-item input {
  width: 100%;
  height: 42px;
  padding: 0 12px;
  font-size: 14px;
  color: #1E293B;
  border: 1px solid #E3E8EF;
  border-radius: 4px;
  outline: none;
}
.form-item input:focus { border-color: #1A73E8; }
.form-error { font-size: 12px; color: #E65100; margin-top: 4px; display: none; }
.form-item.error input { border-color: #E65100; }
.form-item.error .form-error { display: block; }
.auth-submit {
  width: 100%;
  height: 44px;
  background: #1A73E8;
  color: #ffffff;
  font-size: 15px;
  border-radius: 4px;
  margin-top: 8px;
}
.auth-submit:hover { background: #0D47A1; }
.auth-links {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
  font-size: 13px;
}
.auth-links a { color: #1A73E8; }
.auth-links a:hover { text-decoration: underline; }
