/**
 * 秒杀活动样式 - 与拼团活动页面一致
 * @author cany(3808684706)
 */

.seckill-page {
  padding: 20px;
  min-height: 100%;
}

.el-container:nth-child(2) > .el-main {
  background: #fff;
  margin: 0;
  margin-top: calc(40px);
  border-radius: 0;
  padding: 0.24rem;
}

.page-header {
  margin-bottom: 24px;
}

.page-title {
  font-size: 22px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0 0 8px 0;
}

.page-subtitle {
  font-size: 14px;
  color: #8c8c8c;
  margin: 0;
}

/* ========== 活动分组区块 ========== */
.activity-section {
  margin-bottom: 32px;
  background: #fff;
  border-radius: 4px;
  /*padding: 24px;*/
}

.activity-section:last-child {
  margin-bottom: 0;
}

/* 活动头部 */
.activity-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
  padding-bottom: 16px;
  /*border-bottom: 1px solid #f0f2f5;*/
}

.activity-header-left {
  flex: 1;
  min-width: 0;
}

.activity-title {
  font-size: 24px;
  font-weight: 700;
  color: #181818;
  margin: 0 0 8px 0;
  line-height: 1.3;
}

.activity-desc {
  font-size: 14px;
  color: #4b5b76;
  margin: 0;
  line-height: 1.6;
  max-width: 600px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.rules-link {
  color: #0052d9;
  cursor: pointer;
  margin-left: 12px;
  white-space: nowrap;
}

.rules-link:hover {
  color: #0040b0;
  text-decoration: underline;
}

/* 活动头部右侧 - 倒计时 */
.activity-header-right {
  flex-shrink: 0;
  margin-left: 24px;
}

.countdown-box {
  display: flex;
  align-items: center;
  gap: 12px;
}

.countdown-label {
  font-size: 14px;
  color: #4b5b76;
  white-space: nowrap;
}

.countdown-timer {
  display: flex;
  align-items: center;
  gap: 4px;
}

.countdown-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #0052d9 0%, #0073fc 100%);
  color: #fff;
  border-radius: 4px;
  font-size: 18px;
  font-weight: 600;
  font-family: "DIN", "Roboto", "Arial", sans-serif;
}

.countdown-sep {
  color: #0052d9;
  font-size: 18px;
  font-weight: bold;
}

/* 加载状态 */
.loading-wrapper {
  text-align: center;
  padding: 60px 20px;
  background: #fff;
  border-radius: 4px;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid #0052d9;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 15px;
}

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

/* 活动列表 - 最多3列布局 */
.activity-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 1440px;
  margin: 0 auto;
}

/* ========== 活动卡片 - 与拼团一致 ========== */
.activity-card {
  background: #fff;
  border-radius: 4px;
  border: 1px solid #e1e6ef;
  overflow: hidden;
  position: relative;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  min-height: 300px;
  max-width: 460px;
  width: 100%;
  justify-self: center;
}

.activity-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  border-color: #d0d5de;
}

/* 卡片内容区 - 带背景图 */
.card-content {
  padding: 20px;
  background-image: url(/plugins/addon/cany_seckill/template/clientarea/pc/default/img/ac_bg.png);
  background-size: auto 160px;
  background-position: 100% 0;
  background-repeat: no-repeat;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 180px;
}

/* 卡片头部 */
.card-header {
  margin-bottom: 16px;
}

.card-title {
  font-size: 20px;
  line-height: 28px;
  font-weight: 700;
  color: #000;
  margin: 0 0 6px 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-decoration: none;
  transition: color 0.2s;
  width: 100%;
}

.card-title:hover {
  color: #0052d9;
}

.card-title i {
  font-size: 20px;
  font-weight: 700;
  font-style: normal;
  color: inherit;
  flex-shrink: 0;
  margin-left: 8px;
}

.card-subtitle {
  font-size: 12px;
  color: #97a3b7;
  margin: 0;
  line-height: 20px;
  display: inline-block;
}

/* 宣传标语 */
.card-slogan {
  font-size: 13px;
  color: #FF6B6B;
  font-weight: 600;
  margin: 0 0 0 8px;
  line-height: 20px;
  display: inline-flex;
  align-items: center;
}

.card-slogan i {
  font-size: 14px;
  margin-right: 4px;
  color: #FFA500;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.8;
    transform: scale(1.1);
  }
}

/* 卡片内容体 */
.card-body {
  flex: 1;
}

/* 推荐配置 - 蓝色高亮 */
.config-highlight {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 12px;
}

.config-highlight-item {
  font-size: 20px;
  font-weight: 700;
  color: #0052d9;
  line-height: 28px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  max-height: 56px;
  word-break: break-all;
  cursor: default;
}

/* 配置描述tooltip样式 */
.el-tooltip__popper.is-light {
  background: #fff;
  border: 1px solid #e5e6eb;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  padding: 12px 16px;
  max-width: 400px;
  font-size: 14px;
  line-height: 22px;
  color: #4b5b76;
  word-break: break-all;
}

.el-tooltip__popper.is-light .popper__arrow {
  border-bottom-color: #e5e6eb;
}

.el-tooltip__popper.is-light .popper__arrow::after {
  border-bottom-color: #fff;
}

/* 附加信息 - 固定底部 */
.info-attach {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-top: auto;
  /*padding-top: 12px;*/
}

.info-attach-item {
  display: flex;
  align-items: center;
  font-size: 12px;
  line-height: 20px;
}

.info-attach-label {
  color: #97a3b7;
  background: #f5f7fa;
  padding: 0 8px;
  border-radius: 2px;
  margin-right: 12px;
  white-space: nowrap;
}

.info-attach-value {
  color: #181818;
}

/* ========== 卡片底部 ========== */
.card-footer {
  padding: 0;
  width: 100%;
  background: linear-gradient(86deg, #f7faff 5.22%, #f5f9ff 71.3%);
  border-top: 1px solid rgba(0, 82, 217, 0.1);
}

.card-footer-inner {
  padding: 8px 16px;
}

/* 标签和价格行 */
.tag-price-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

/* 标签区 */
.tag-group {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  min-height: 18px;
}

.tag-item {
  font-size: 12px;
  padding: 0 3px;
  border-radius: 2px;
  white-space: nowrap;
  line-height: 16px;
  height: 18px;
  display: inline-flex;
  align-items: center;
}

.tag-discount {
  background: #fff;
  border: 1px solid #ffcfd0;
  color: #f64041;
  min-width: 39px;
  justify-content: center;
}

.tag-first {
  background: linear-gradient(90deg, #ff5800 0%, #ff7a00 100%);
  color: #fff;
  border: none;
  padding: 0 6px;
}

.tag-normal {
  background: #fff;
  border: 1px solid #d6dbe3;
  color: #4b5b76;
}

/* 价格区 */
.price-section {
  text-align: right;
  flex-shrink: 0;
}

.price-current {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
}

.price-label {
  font-size: 12px;
  color: #97a3b7;
  margin-right: 2px;
}

.price-integer {
  font-size: 24px;
  font-weight: 700;
  color: #f64041;
  line-height: 1;
}

.price-decimal {
  font-size: 14px;
  font-weight: 700;
  color: #f64041;
}

.price-unit {
  font-size: 12px;
  color: #f64041;
  margin-left: 2px;
}

.price-average {
  font-size: 11px;
  color: #97a3b7;
  margin-left: 6px;
}

.price-original {
  font-size: 12px;
  color: #97a3b7;
  margin-top: 2px;
} 

.price-original .value {
  text-decoration: line-through;
}

/* ========== 进度条和按钮 ========== */
.progress-btn-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  border-top: 1px solid rgba(0, 82, 217, 0.05);
}

.progress-section {
  flex: 1;
  margin-right: 16px;
}

.progress-bar {
  height: 4px;
  background: #e8ecf2;
  border-radius: 2px;
  overflow: hidden;
  position: relative;
  margin-bottom: 4px;
}

.progress-bar-inner {
  height: 100%;
  background: linear-gradient(90deg, #0052d9 0%, #4d91ff 100%);
  border-radius: 2px;
  transition: width 0.3s ease;
  position: relative;
}

.progress-bar-text {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 10px;
  color: #fff;
}

.progress-desc {
  font-size: 12px;
  color: #97a3b7;
  line-height: 20px;
}

/* 秒杀按钮 */
.btn-seckill {
  background: linear-gradient(90deg, #ff7e57 0%, #ff5825 100%);
  color: #fff;
  border: none;
  border-radius: 2px;
  padding: 7px 20px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  line-height: 22px;
}

.btn-seckill:hover {
  background: linear-gradient(90deg, #ff6d40 0%, #f6501d 100%);
}

.btn-seckill.btn-active {
  background: linear-gradient(90deg, #ff7e57 0%, #ff5825 100%);
}

.btn-seckill.btn-active:hover {
  background: linear-gradient(90deg, #ff6d40 0%, #f6501d 100%);
}

.btn-seckill.btn-preheat {
  background: #fff;
  color: #0052d9;
  border: 1px solid #0052d9;
}

.btn-seckill.btn-preheat:hover {
  background: #f7faff;
}

.btn-seckill.btn-disabled {
  background: #f5f7fa;
  color: #97a3b7;
  cursor: not-allowed;
}

.btn-seckill.btn-disabled:hover {
  background: #f5f7fa;
}

/* ========== 空状态 ========== */
.empty-state {
  text-align: center;
  padding: 80px 20px;
  background: #fff;
  border-radius: 4px;
}

.empty-icon {
  font-size: 64px;
  color: #dcdfe6;
  margin-bottom: 20px;
}

.empty-text {
  font-size: 16px;
  color: #909399;
}

/* ========== 弹窗样式 ========== */
.confirm-content {
  line-height: 1.8;
  color: #4b5b76;
  font-size: 14px;
  text-align: center;
}

.confirm-icon {
  font-size: 56px;
  margin-bottom: 16px;
}

.confirm-content h3 {
  font-size: 20px;
  color: #181818;
  margin: 0 0 24px 0;
  font-weight: 600;
}

.confirm-product {
  background: #f8fafc;
  padding: 16px;
  border-radius: 8px;
  margin-bottom: 16px;
  text-align: left;
}

.confirm-product .name {
  font-size: 15px;
  font-weight: 500;
  color: #181818;
  margin-bottom: 8px;
}

.confirm-product .config {
  font-size: 13px;
  color: #4b5b76;
  margin-bottom: 12px;
}

.confirm-product .price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 12px;
  border-top: 1px dashed #e1e6ef;
}

.confirm-product .price-label {
  color: #4b5b76;
  font-size: 14px;
}

.confirm-product .price-value {
  color: #f64041;
  font-size: 22px;
  font-weight: 600;
}

.confirm-tip {
  font-size: 13px;
  color: #8c8c8c;
}

/* 成功弹窗 */
.success-content {
  text-align: center;
}

.success-icon {
  font-size: 64px;
  margin-bottom: 16px;
}

.success-content h3 {
  font-size: 22px;
  color: #181818;
  margin: 0 0 24px 0;
  font-weight: 600;
}

.success-product {
  background: #f0fff4;
  padding: 16px;
  border-radius: 8px;
  margin-bottom: 16px;
}

.success-product .name {
  font-size: 15px;
  font-weight: 500;
  color: #181818;
  margin-bottom: 12px;
}

.success-product .price-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.success-product .price-label {
  color: #4b5b76;
  font-size: 14px;
}

.success-product .price-value {
  color: #00a870;
  font-size: 26px;
  font-weight: 600;
}

.expire-countdown {
  padding: 16px;
  background: #fff8f0;
  border-radius: 8px;
  border: 1px solid #ffe4cc;
}

.expire-countdown p {
  color: #4b5b76;
  font-size: 14px;
  margin: 0;
  line-height: 1.8;
}

.expire-time {
  color: #f64041;
  font-size: 20px;
  font-weight: 600;
  margin: 0 4px;
}

/* 弹窗按钮样式 */
.dialog-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

.dialog-footer .el-button {
  padding: 8px 24px;
  font-size: 14px;
  border-radius: 3px;
}

.dialog-footer .el-button--default {
  border-color: #dcdfe6;
  color: #4b5b76;
}

.dialog-footer .el-button--default:hover {
  border-color: #0052d9;
  color: #0052d9;
  background: #fff;
}

.dialog-footer .el-button--primary {
  background: #0052d9;
  border-color: #0052d9;
}

.dialog-footer .el-button--primary:hover {
  background: #0040b0;
  border-color: #0040b0;
}

.dialog-footer .el-button--danger {
  background: #f64041;
  border-color: #f64041;
}

.dialog-footer .el-button--danger:hover {
  background: #e63030;
  border-color: #e63030;
}

/* 余额不足引导充值弹窗 */
.recharge-guide-content {
  text-align: center;
  padding: 20px 0;
}

.recharge-guide-content .guide-icon {
  margin-bottom: 20px;
}

.recharge-guide-content .guide-line1 {
  font-size: 18px;
  font-weight: 600;
  color: #303133;
  margin-bottom: 12px;
}

.recharge-guide-content .guide-line2 {
  font-size: 14px;
  color: #606266;
  margin: 0;
}

/* 规则弹窗 */
.rules-content {
  font-size: 14px;
  color: #4b5b76;
  line-height: 1.8;
}

.rules-content h4 {
  color: #181818;
  margin: 16px 0 8px;
}

.rules-content ul {
  margin: 8px 0;
  padding-left: 20px;
}

.rules-content li {
  margin: 4px 0;
}

/* 响应式适配 */

/* 中等屏幕 - 2列 */
@media screen and (max-width: 1200px) {
  .activity-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    max-width: 960px;
  }
}

/* 小屏幕/平板 - 2列紧凑 */
@media screen and (max-width: 960px) {
  .activity-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    max-width: 100%;
    padding: 0 12px;
  }

  .activity-card {
    max-width: 100%;
    min-height: auto;
  }
}

/* 手机端 - 1列 */
@media screen and (max-width: 768px) {
  .seckill-page {
    padding: 12px;
  }

  /* 活动分组区块响应式 */
  .activity-section {
    padding: 16px;
    margin-bottom: 20px;
  }

  .activity-header {
    flex-direction: column;
    gap: 16px;
  }

  .activity-header-right {
    margin-left: 0;
  }

  .activity-title {
    font-size: 20px;
  }

  .activity-desc {
    -webkit-line-clamp: 3;
    line-clamp: 3;
  }

  .countdown-box {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .countdown-item {
    min-width: 32px;
    height: 32px;
    font-size: 16px;
  }

  .activity-list {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 0;
  }

  .activity-card {
    max-width: 100%;
  }

  .card-content {
    padding: 16px;
    background-size: auto 150px;
    min-height: 150px;
  }

  .card-header {
    margin-bottom: 12px;
  }

  .card-title {
    font-size: 18px;
    line-height: 26px;
  }

  .card-slogan {
    font-size: 13px;
    line-height: 20px;
    margin: 4px 0 3px 0;
  }

  .card-slogan i {
    font-size: 14px;
    margin-right: 4px;
  }

  .config-highlight-item {
    font-size: 16px;
    line-height: 24px;
  }

  .info-attach {
    gap: 8px 16px;
    flex-direction: row;
  }

  .info-attach-item {
    width: auto;
  }

  .card-footer-inner {
    padding: 8px;
  }

  .tag-price-row {
    flex-direction: column;
    gap: 8px;
  }

  .price-section {
    text-align: left;
  }

  .price-current {
    justify-content: flex-start;
  }

  .progress-btn-row {
    padding: 8px;
    flex-direction: column;
    gap: 12px;
  }

  .progress-section {
    margin-right: 0;
    width: 100%;
  }

  .btn-seckill {
    width: 100%;
    padding: 10px 20px;
  }
}

/* ========== 秒杀弹窗样式优化 ========== */
.seckill-dialog .el-dialog__body {
  padding: 16px 20px;
}

.seckill-dialog .confirm-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.seckill-dialog .confirm-content h3 {
  font-size: 18px;
  margin: 0 0 16px 0;
}

.seckill-dialog .confirm-product {
  padding: 12px;
  margin-bottom: 12px;
}

.seckill-dialog .confirm-tip {
  margin: 0;
}

/* 成功弹窗优化 */
.success-dialog .el-dialog__body {
  padding: 16px 20px;
}

.success-dialog .success-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.success-dialog .success-content h3 {
  font-size: 18px;
  margin: 0 0 16px 0;
}

.success-dialog .success-product {
  padding: 12px;
  margin-bottom: 12px;
}

.success-dialog .success-product .name {
  margin-bottom: 8px;
}

.success-dialog .success-product .price-value {
  font-size: 22px;
}

.success-dialog .expire-countdown {
  padding: 12px;
}

.success-dialog .expire-countdown p {
  line-height: 1.6;
}

.success-dialog .expire-time {
  font-size: 18px;
}

/* ========== 手机端响应式样式 ========== */
@media screen and (max-width: 768px) {
  /* 页面整体 */
  .seckill-page {
    padding: 12px;
  }
  
  .page-header {
    margin-bottom: 16px;
  }
  
  .page-title {
    font-size: 18px;
  }
  
  /* 活动区块 */
  .activity-section {
    padding: 16px;
    margin-bottom: 20px;
  }
  
  .activity-header {
    flex-direction: column;
    gap: 12px;
  }
  
  .activity-title {
    font-size: 18px;
  }
  
  .countdown-box {
    flex-wrap: wrap;
  }
  
  .countdown-item {
    min-width: 30px;
    height: 30px;
    font-size: 14px;
  }
  
  /* 弹窗通用样式 */
  .seckill-dialog .el-dialog__body,
  .success-dialog .el-dialog__body,
  .rules-dialog .el-dialog__body {
    padding: 12px 16px;
  }
  
  .seckill-dialog .confirm-icon,
  .success-dialog .success-icon {
    font-size: 40px;
    margin-bottom: 8px;
  }
  
  .seckill-dialog .confirm-content h3,
  .success-dialog .success-content h3 {
    font-size: 16px;
    margin: 0 0 12px 0;
  }
  
  .seckill-dialog .confirm-product,
  .success-dialog .success-product {
    padding: 10px;
    margin-bottom: 10px;
  }
  
  .seckill-dialog .confirm-product .name,
  .success-dialog .success-product .name {
    font-size: 14px;
  }
  
  .seckill-dialog .confirm-product .price-value,
  .success-dialog .success-product .price-value {
    font-size: 18px;
  }
  
  /* 弹窗按钮 */
  .dialog-footer {
    flex-direction: column-reverse;
    gap: 8px;
  }
  
  .dialog-footer .el-button {
    width: 100%;
    margin-left: 0 !important;
  }
  
  /* 规则弹窗 */
  .rules-dialog .rules-content {
    font-size: 13px;
    line-height: 1.7;
  }
  
  /* 充值引导弹窗 */
  .recharge-guide-content {
    padding: 12px 0;
  }
  
  .recharge-guide-content .guide-icon i {
    font-size: 40px !important;
  }
  
  .recharge-guide-content .guide-line1 {
    font-size: 16px;
  }
  
  .recharge-guide-content .guide-line2 {
    font-size: 13px;
  }
}
