/* 全局重置 & 健康光源高端浅色主题 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "PingFang SC", "Helvetica Neue", Arial, sans-serif;
}
body {
  padding-top: 50px;
  background: linear-gradient(180deg, #f8fafc 0%, #f0f7ff 100%);
  background-attachment: fixed;
  color: #333;
  font-size: 14px;
  padding-bottom: 60px;
  /* 优化字体渲染 */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a {
  text-decoration: none;
  color: inherit;
  transition: color 0.3s ease;
}
ul {
  list-style: none;
}

/* 头部优化 */
.header {
  background: linear-gradient(90deg, #2b7cff, #5fa0ff);
  color: #fff;
  height: 50px;
  font-size: 16px;
  font-weight: 500;
  box-shadow: 0 2px 10px rgba(43, 124, 255, 0.15);
  position: fixed;  /* 改成 fixed */
  top: 0;
  left: 0;
  right: 0;
  z-index: 999;  /* 提高层级，确保在最上面 */
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 15px;
}

/* 左边返回按钮 */
.back-btn {
  color: #fff;
  font-size: 18px;
  text-decoration: none;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  transition: background 0.3s ease;
}
.back-btn:hover {
  background: rgba(255,255,255,0.2);
}

/* 中间标题（绝对居中） */
.header-title {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-size: 16px;
  font-weight: 500;
}

/* 右边充值按钮 */
.header .add-btn {
  color: #fff;
  font-size: 16px;
  text-decoration: none;
  margin-left: auto;
}

/* 底部导航优化 */
.footer-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 55px;
  background: #fff;
  display: flex;
  box-shadow: 0 -2px 10px rgba(0, 43, 124, 0.06);
  z-index: 99;
}
.footer-nav a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: #666;
  text-decoration: none;
  transition: color 0.3s ease;
}
.footer-nav a.active {
  color: #2b7cff;
}
.footer-nav a:hover {
  color: #2b7cff;
}
.footer-nav a::before {
  font-size: 20px;
  margin-bottom: 4px;
  transition: transform 0.3s ease;
}
.footer-nav a:hover::before {
  transform: scale(1.1);
}
.footer-nav a:nth-child(1)::before { content: "🏠"; }
.footer-nav a:nth-child(2)::before { content: "📚"; }
.footer-nav a:nth-child(3)::before { content: "🛒"; }
.footer-nav a:nth-child(4)::before { content: "👤"; }

/* 通用容器 */
.container {
  padding: 15px;
  max-width: 1200px;
  margin: 0 auto;
}

/* 通用区块 */
.section {
  margin-bottom: 20px;
}
.section-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 12px;
  padding-left: 10px;
  border-left: 3px solid #2b7cff;
  color: #222;
}

/* 卡片通用优化 */
.card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 25px rgba(43, 124, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.8);
  padding: 15px;
  transition: box-shadow 0.3s ease;
}
.card:hover {
  box-shadow: 0 12px 30px rgba(43, 124, 255, 0.1);
}

/* 产品项（列表/购物车共用）优化 */
.pro-item {
  display: flex;
  background: #fff;
  border-radius: 16px;
  padding: 15px;
  margin-bottom: 12px;
  box-shadow: 0 8px 25px rgba(43, 124, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.8);
  align-items: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.pro-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(43, 124, 255, 0.1);
}
.pro-item img {
  width: 90px;
  height: 90px;
  object-fit: cover;
  border-radius: 12px;
  margin-right: 15px;
  transition: transform 0.3s ease;
}
.pro-item:hover img {
  transform: scale(1.05);
}
.pro-info {
  flex: 1;
}
.pro-info h3 {
  font-size: 16px;
  color: #222;
  margin-bottom: 6px;
  font-weight: 500;
  line-height: 1.3;
}
.pro-info p {
  font-size: 13px;
  color: #666;
  margin-bottom: 6px;
  line-height: 1.4;
}
.pro-price {
  font-size: 18px;
  color: #ff6b35;
  font-weight: bold;
}

/* 按钮优化 */
.btn {
  display: inline-block;
  padding: 8px 16px;
  background: linear-gradient(90deg, #2b7cff, #4d94ff);
  color: #fff;
  border-radius: 20px;
  font-size: 14px;
  border: none;
  cursor: pointer;
  box-shadow: 0 6px 15px rgba(43, 124, 255, 0.25);
  transition: all 0.3s ease;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(43, 124, 255, 0.3);
}
.btn:active {
  transform: translateY(0);
}
.btn-block {
  display: block;
  width: 100%;
  text-align: center;
}

/* 兼容老浏览器 */
.ie-fallback .card {
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  border: 1px solid #eee;
}
.ie-fallback .btn {
  background: #2b7cff;
  box-shadow: none;
}
.ie-fallback .pro-item {
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  border: 1px solid #eee;
}
div.error, div.message, li.error {
    background: #ffffcc;
    border: 1px solid #000;
    color: #000000;
    font-family: Arial, Helvetica, sans-serif;
    font-weight: normal;
    margin: 10px auto;
    padding: 3px;
    text-align: left;
    vertical-align: bottom;
}
div.error, li.error {
    border: 2px solid red;
}