.customer-points-history-section {
  padding-top: clamp(48px, 8vw, 60px);
  padding-bottom: clamp(48px, 8vw, 60px);
  max-width: 1200px;
  margin: 0 auto;
}

.customer-points-history-block {
  margin: 0.5rem 0;
  position: relative;
  padding: 1rem 0;
  transition: all 0.3s ease;
}

.customer-points-history-container {
  max-width: 900px;
  margin: 0 auto;
  position: relative;
}

.customer-points-history-title {
  text-align: var(--title-alignment, center);
  font-weight: 900;
  margin-bottom: clamp(24px, 4vw, 48px);
  color: #222;
  font-family: Oswald, Arial, sans-serif;
  font-size: var(--title-font-size, clamp(2.5rem, 6vw, 4rem));
  letter-spacing: 0.02em;
}

/* 积分总额显示 */
.points-summary {
  padding: 1.5rem 0;
  margin-bottom: 2rem;
  text-align: center;
}

.points-label {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #666;
}

.points-value {
  font-size: 3rem;
  font-weight: 900;
  color: var(--points-color, #1976d2);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.points-number {
  font-size: 3rem;
  font-weight: 900;
}

.points-unit {
  font-size: 1.5rem;
  font-weight: 600;
  opacity: 0.8;
}

/* 积分历史记录 */
.points-history {
  padding: 0.5rem 0;
}

.history-title {
  font-size: clamp(1.1rem, 2.5vw, 1.7rem);
  font-weight: 700;
  margin: 1rem 0 0.5rem 0;
  color: #222;
  text-align: left;
}

.history-container {
  max-height: 350px;
  overflow-y: auto;
  /* 隐藏滚动条但保持滚动功能 */
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE and Edge */
}

.history-container::-webkit-scrollbar {
  display: none; /* Chrome, Safari and Opera */
}

.history-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  margin-bottom: 0.25rem;
  border-bottom: 1px solid #f0f0f0;
}



.history-item.earned .history-amount {
  color: #4caf50;
}

.history-item.spent .history-amount {
  color: #f44336;
}

.history-item.expired .history-amount {
  color: #ff9800;
}

.history-info {
  flex: 1;
}

.history-description {
  font-weight: 600;
  color: #333;
  margin-bottom: 0.25rem;
}

.history-date {
  font-size: 0.9rem;
  color: #666;
}

.history-order-no {
  font-size: 0.85rem;
  color: #888;
  margin-top: 0.2rem;
}

.history-extra-info {
  font-size: 0.8rem;
  color: #777;
  margin-top: 0.3rem;
  line-height: 1.3;
  opacity: 0.9;
}

.history-amount {
  font-weight: 700;
  font-size: 1.1rem;
}

.history-amount.positive {
  color: #4caf50;
}

.history-amount.negative {
  color: #f44336;
}

.history-amount.neutral {
  color: #ff9800;
}

/* 加载状态 */
.loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  color: #666;
}

.loading-spinner {
  width: 24px;
  height: 24px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid #1976d2;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 1rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading-text {
  font-size: 1rem;
  color: #666;
}

/* 错误状态 */
.error-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  border: 1px solid #ffcdd2;
  border-radius: 8px;
  background: #ffebee;
}

.error-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.error-text {
  font-size: 1rem;
  color: #f44336;
  margin-bottom: 1rem;
  text-align: center;
}

.retry-button {
  background: #1976d2;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 25px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.retry-button:hover {
  background: #1565c0;
  transform: scale(1.05);
}

/* 空状态 */
.customer-points-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 1rem;
  color: #666;
  border: 1px dashed rgba(0,0,0,0.06);
  border-radius: 10px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  box-shadow: 0 6px 18px rgba(13, 38, 59, 0.04);
}

.customer-points-empty__icon {
  font-size: 2.6rem;
  margin-bottom: 0.6rem;
  color: rgba(25,118,210,0.12);
}

.customer-points-empty__text {
  font-size: 1rem;
  color: #445; /* 更协调的色彩 */
  text-align: center;
  max-width: 420px;
}



/* 分页控件 */
.pagination-container {
  margin-top: 2rem;
  padding: 1rem 0;
}

.pagination-controls {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.pagination-info {
  font-size: 0.9rem;
  color: #666;
  text-align: center;
}

.pagination-buttons {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.pagination-btn {
  padding: 0.5rem 0.75rem;
  border: 1px solid #ddd;
  background: white;
  color: #333;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s ease;
  min-width: 40px;
  text-align: center;
}

.pagination-btn:hover {
  background: #f5f5f5;
  border-color: #bbb;
}

.pagination-btn.active {
  background: #1976d2;
  color: white;
  border-color: #1976d2;
}

.pagination-btn.active:hover {
  background: #1565c0;
  border-color: #1565c0;
}

.pagination-btn.prev-btn,
.pagination-btn.next-btn {
  padding: 0.5rem 1rem;
  font-weight: 600;
}

.pagination-ellipsis {
  color: #999;
  font-weight: 500;
  padding: 0 0.5rem;
}

/* 登录提示 */
.login-prompt {
  padding: 2rem 1.5rem;
  text-align: center;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  background: #fafafa;
}

.login-icon {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  opacity: 0.7;
}

.login-title {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #333;
}

.login-description {
  font-size: 1.1rem;
  color: #666;
  margin-bottom: 2rem;
  line-height: 1.6;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

.login-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.login-button {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.login-button.primary {
  background: #1976d2;
  color: white;
}

.login-button.primary:hover {
  background: #1565c0;
  transform: scale(1.05);
}

.login-button.secondary {
  background: transparent;
  color: #1976d2;
  border-color: #1976d2;
}

.login-button.secondary:hover {
  background: #1976d2;
  color: white;
  transform: scale(1.05);
}

/* 新增样式 */
.newC.section {
  width: 100%;
}

.newC.section .container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* 响应式设计 */
@media (max-width: 1024px) {
  .customer-points-history-block {
    padding: 0.75rem 0;
  }
  
  .customer-points-history-title {
    margin-bottom: clamp(20px, 3vw, 32px);
  }
  
  .points-summary {
    padding: 1.25rem 0;
    margin-bottom: 1.75rem;
  }
  
  .history-container {
    max-height: 320px;
  }
  
  .pagination-buttons {
    gap: 0.25rem;
  }
  
  .pagination-btn {
    padding: 0.4rem 0.6rem;
    font-size: 0.85rem;
    min-width: 35px;
  }
}

@media (max-width: 768px) {
  .customer-points-history-block {
    padding: 0.75rem 0;
  }
  
  .customer-points-history-title {
    font-size: clamp(1.5rem, 7vw, 2.5rem);
    margin-bottom: clamp(16px, 3vw, 24px);
  }
  
  .points-summary {
    padding: 1rem 0;
    margin-bottom: 1.5rem;
  }
  
  .points-history {
    padding: 0.25rem 0;
  }
  
  .login-prompt {
    padding: 1.5rem 1rem;
  }
  
  .points-value {
    font-size: 2.5rem;
  }
  
  .points-number {
    font-size: 2.5rem;
  }
  
  .history-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .history-amount {
    align-self: flex-end;
  }
  
  .login-title {
    font-size: 1.5rem;
  }
  
  .login-description {
    font-size: 1rem;
  }
  
  .login-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .login-button {
    width: 100%;
    max-width: 200px;
  }
  
  .pagination-controls {
    gap: 0.75rem;
  }
  
  .pagination-info {
    font-size: 0.8rem;
  }
  
  .pagination-buttons {
    gap: 0.25rem;
  }
  
  .pagination-btn {
    padding: 0.4rem 0.5rem;
    font-size: 0.8rem;
    min-width: 32px;
  }
  
  .pagination-btn.prev-btn,
  .pagination-btn.next-btn {
    padding: 0.4rem 0.75rem;
  }
}

@media (max-width: 480px) {
  .customer-points-history-block {
    padding: 0.5rem 0;
  }
  
  .customer-points-history-title {
    font-size: clamp(1.2rem, 6vw, 1.8rem);
    margin-bottom: clamp(12px, 2vw, 20px);
  }
  
  .points-summary {
    padding: 0.75rem 0;
    margin-bottom: 1rem;
  }
  
  .points-history {
    padding: 0.125rem 0;
  }
  
  .login-prompt {
    padding: 1rem 0.5rem;
  }
  
  .points-value {
    font-size: 2rem;
  }
  
  .points-number {
    font-size: 2rem;
  }
  
  .history-title {
    font-size: 1.3rem;
  }
  
  .login-title {
    font-size: 1.3rem;
  }
  
  .login-description {
    font-size: 0.9rem;
  }
  
  .login-icon {
    font-size: 3rem;
  }
  
  .pagination-container {
    margin-top: 1.5rem;
    padding: 0.75rem 0;
  }
  
  .pagination-controls {
    gap: 0.5rem;
  }
  
  .pagination-info {
    font-size: 0.75rem;
    line-height: 1.3;
  }
  
  .pagination-buttons {
    gap: 0.2rem;
  }
  
  .pagination-btn {
    padding: 0.35rem 0.4rem;
    font-size: 0.75rem;
    min-width: 30px;
  }
  
  .pagination-btn.prev-btn,
  .pagination-btn.next-btn {
    padding: 0.35rem 0.6rem;
    font-size: 0.75rem;
  }
}
