// 售后归档阶段 - 完整样式

// ==================== 基础样式 ====================
.stage-aftercare-container {
  padding: 12px;
  background: #f5f5f5;
  min-height: 100vh;
}

// 加载状态
.loading-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;

  .spinner {
    width: 40px;
    height: 40px;
    margin-bottom: 16px;

    .spinner-circle {
      width: 100%;
      height: 100%;
      border: 3px solid rgba(var(--primary-rgb, 56, 128, 255), 0.2);
      border-top-color: var(--primary-color, #3880ff);
      border-radius: 50%;
      animation: spin 0.8s linear infinite;
    }
  }

  p {
    color: var(--medium-color, #666);
    font-size: 14px;
  }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

// 卡片样式
.card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  margin-bottom: 16px;
  overflow: hidden;

  .card-header {
    padding: 16px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;

    .card-title-wrapper {
      display: flex;
      align-items: center;
      gap: 12px;
      width: 100%;
      justify-content: space-between;
    }

    .card-title {
      display: flex;
      align-items: center;
      gap: 8px;
      font-size: 16px;
      font-weight: 600;
      color: var(--dark-color, #222);
      margin: 0;

      .icon {
        width: 20px;
        height: 20px;
        flex-shrink: 0;
      }
    }

    .generated-info {
      font-size: 11px;
      color: var(--medium-color, #666);
    }
  }

  .card-content {
    padding: 16px;
  }
}

// 徽章样式
.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;

  &.badge-success {
    background: rgba(45, 211, 111, 0.1);
    color: #2dd36f;
  }

  &.badge-warning {
    background: rgba(255, 196, 9, 0.1);
    color: #ffc409;
  }

  &.badge-danger {
    background: rgba(235, 68, 90, 0.1);
    color: #eb445a;
  }

  &.badge-primary {
    background: rgba(56, 128, 255, 0.1);
    color: #3880ff;
  }

  &.badge-medium {
    background: rgba(146, 148, 151, 0.1);
    color: #929497;
  }
}

// 按钮样式
.btn {
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;

  .icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
  }

  &:disabled {
    opacity: 0.5;
    cursor: not-allowed;
  }

  &.btn-primary {
    background: var(--primary-color, #3880ff);
    color: white;

    &:hover:not(:disabled) {
      background: darken(#3880ff, 10%);
    }
  }

  &.btn-success {
    background: var(--success-color, #2dd36f);
    color: white;

    &:hover:not(:disabled) {
      background: darken(#2dd36f, 10%);
    }
  }

  &.btn-light {
    background: #f5f5f5;
    color: var(--dark-color, #222);

    &:hover:not(:disabled) {
      background: #e0e0e0;
    }
  }

  &.btn-outline {
    background: white;
    color: var(--primary-color, #3880ff);
    border: 2px solid var(--primary-color, #3880ff);

    &:hover:not(:disabled) {
      background: var(--primary-color, #3880ff);
      color: white;
    }
  }

  &.btn-block {
    width: 100%;
  }

  &.btn-large {
    padding: 16px 24px;
    font-size: 15px;
  }
}

// 空状态
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--medium-color, #666);

  .icon-large {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    opacity: 0.3;
  }

  p {
    margin: 0 0 12px 0;
    font-size: 14px;

    &.hint {
      font-size: 12px;
      opacity: 0.8;
    }
  }
}

// ==================== Tab导航 ====================
.tab-navigation {
  position: sticky;
  top: 0;
  z-index: 100;
  background: white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  margin: -12px -12px 16px -12px;
  padding: 0;

  .tab-buttons {
    display: flex;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;

    &::-webkit-scrollbar {
      display: none;
    }

    .tab-btn {
      flex: 1;
      min-width: 80px;
      padding: 12px 8px;
      border: none;
      background: white;
      color: var(--medium-color, #666);
      font-size: 13px;
      font-weight: 500;
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 4px;
      cursor: pointer;
      transition: all 0.3s;
      border-bottom: 3px solid transparent;

      .icon {
        width: 20px;
        height: 20px;
      }

      &.active {
        color: var(--primary-color, #3880ff);
        border-bottom-color: var(--primary-color, #3880ff);
        font-weight: 600;
      }

      &:hover:not(.active) {
        background: #f5f5f5;
      }

      &:active {
        transform: scale(0.95);
      }
    }
  }
}

// ==================== 概览Section ====================
.overview-section {
  // 已归档卡片
  .archived-card {
    background: linear-gradient(135deg, #2dd36f, #28ba62);

    .card-content {
      padding: 32px 20px;
    }

    .archived-status {
      text-align: center;
      color: white;

      .icon-large {
        width: 64px;
        height: 64px;
        margin: 0 auto 16px;
      }

      h3 {
        font-size: 20px;
        margin: 0 0 12px 0;
      }

      p {
        margin: 4px 0;
        font-size: 14px;
        opacity: 0.9;
      }
    }
  }

  // 完成度卡片
  .completion-card {
    .circular-progress {
      display: flex;
      justify-content: center;
      padding: 20px;
      margin-bottom: 20px;

      .progress-ring {
        transform: rotate(-90deg);

        .progress-ring-circle-bg {
          opacity: 0.3;
        }

        .progress-ring-circle {
          stroke-dasharray: 439.6;
          stroke-dashoffset: 0;
          transition: stroke-dashoffset 0.8s ease;
          stroke-linecap: round;
          filter: drop-shadow(0 0 6px rgba(45, 211, 111, 0.5));
        }
      }

      .progress-text {
        font-size: 28px;
        font-weight: 700;
        fill: var(--dark-color, #222);
        transform: rotate(90deg);
        transform-origin: center;
      }
    }

    .key-metrics {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 12px;

      .metric-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
        padding: 12px;
        background: #f5f5f5;
        border-radius: 8px;
        transition: all 0.3s;

        &:hover {
          background: #e0e0e0;
          transform: translateY(-2px);
        }

        .metric-icon {
          font-size: 24px;
        }

        .metric-info {
          text-align: center;

          .metric-label {
            font-size: 11px;
            color: var(--medium-color, #666);
            margin-bottom: 4px;
          }

          .metric-value {
            font-size: 16px;
            font-weight: 700;
            color: var(--dark-color, #222);
          }
        }
      }
    }
  }

  // 快捷操作卡片
  .quick-actions-card {
    .action-grid {
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 12px;

      .action-card {
        background: white;
        border: 2px solid #e0e0e0;
        border-radius: 12px;
        padding: 16px;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
        cursor: pointer;
        transition: all 0.3s;
        text-align: center;

        &:hover:not(:disabled) {
          border-color: var(--primary-color, #3880ff);
          transform: translateY(-2px);
          box-shadow: 0 4px 12px rgba(56, 128, 255, 0.15);
        }

        &:active:not(:disabled) {
          transform: translateY(0);
        }

        &:disabled {
          opacity: 0.5;
          cursor: not-allowed;
        }

        .action-icon {
          font-size: 32px;
          margin-bottom: 4px;
        }

        .action-title {
          font-size: 14px;
          font-weight: 600;
          color: var(--dark-color, #222);
        }

        .action-desc {
          font-size: 12px;
          color: var(--medium-color, #666);
        }

        .action-badge {
          margin-top: 4px;
          padding: 4px 10px;
          border-radius: 10px;
          font-size: 11px;
          font-weight: 600;
          background: #f5f5f5;
          color: var(--dark-color, #222);

          &.badge-success {
            background: #2dd36f;
            color: white;
          }
        }

        .action-hint {
          font-size: 10px;
          color: var(--warning-color, #ffc409);
          margin-top: 4px;
        }
      }
    }
  }

  // Product概览卡片
  .products-overview-card {
    .products-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
      gap: 12px;

      .product-summary-card {
        background: #f5f5f5;
        border-radius: 8px;
        padding: 12px;
        text-align: center;

        .product-header {
          margin-bottom: 8px;

          .product-icon {
            font-size: 32px;
            margin-bottom: 8px;
          }

          .product-name {
            font-size: 13px;
            font-weight: 600;
            color: var(--dark-color, #222);
          }
        }

        .product-rating {
          display: flex;
          justify-content: center;
          gap: 2px;

          .star-small {
            font-size: 14px;
            color: #e0e0e0;

            &.filled {
              color: var(--warning-color, #ffc409);
            }
          }
        }
      }
    }
  }
}

// ==================== 尾款Section ====================
.payment-section {
  .payment-overview-card {
    .payment-stats {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 16px;
      margin-bottom: 20px;

      .stat-item {
        text-align: center;

        .stat-label {
          font-size: 12px;
          color: var(--medium-color, #666);
          margin-bottom: 8px;
        }

        .stat-value {
          font-size: 20px;
          font-weight: 700;

          &.primary {
            color: var(--primary-color, #3880ff);
          }

          &.success {
            color: var(--success-color, #2dd36f);
          }

          &.warning {
            color: var(--warning-color, #ffc409);
          }
        }
      }
    }

    .payment-progress {
      margin-bottom: 16px;

      .progress-bar {
        width: 100%;
        height: 8px;
        background: #e0e0e0;
        border-radius: 4px;
        overflow: hidden;
        margin-bottom: 8px;

        .progress-fill {
          height: 100%;
          background: linear-gradient(90deg, #2dd36f, #28ba62);
          border-radius: 4px;
          transition: width 0.6s ease;
        }
      }

      .progress-label {
        font-size: 12px;
        color: var(--medium-color, #666);
        text-align: center;
      }
    }

    .alert {
      padding: 12px;
      border-radius: 8px;
      display: flex;
      align-items: center;
      gap: 12px;
      font-size: 13px;

      &.alert-warning {
        background: rgba(255, 196, 9, 0.1);
        border: 1px solid var(--warning-color, #ffc409);
        color: var(--dark-color, #222);

        .icon {
          color: var(--warning-color, #ffc409);
          width: 24px;
          height: 24px;
          flex-shrink: 0;
        }
      }
    }
  }

  // Product分摊
  .product-breakdown-card {
    .breakdown-list {
      .breakdown-item {
        padding: 12px;
        background: #f5f5f5;
        border-radius: 8px;
        margin-bottom: 12px;

        &:last-child {
          margin-bottom: 0;
        }

        .breakdown-header {
          display: flex;
          justify-content: space-between;
          align-items: center;
          margin-bottom: 8px;

          .breakdown-name {
            font-size: 14px;
            font-weight: 600;
            color: var(--dark-color, #222);
          }
        }

        .breakdown-amounts {
          display: flex;
          justify-content: space-between;
          margin-bottom: 8px;
          font-size: 13px;

          .amount-total {
            font-weight: 600;
            color: var(--dark-color, #222);
          }

          .amount-paid {
            color: var(--success-color, #2dd36f);
          }
        }

        .breakdown-progress {
          .progress-bar-small {
            height: 6px;
            background: #e0e0e0;
            border-radius: 3px;
            overflow: hidden;

            .progress-fill {
              height: 100%;
              background: var(--success-color, #2dd36f);
              transition: width 0.6s ease;
            }
          }
        }
      }
    }
  }

  // 支付凭证
  .vouchers-card {
    .count-badge {
      display: inline-block;
      padding: 2px 8px;
      border-radius: 10px;
      font-size: 11px;
      font-weight: 600;
      background: var(--primary-color, #3880ff);
      color: white;
      margin-left: 8px;
    }

    .vouchers-list {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
      gap: 12px;
      margin-bottom: 16px;

      .voucher-item {
        background: #f5f5f5;
        border-radius: 8px;
        overflow: hidden;
        transition: all 0.3s;

        &:hover {
          box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
          transform: translateY(-2px);
        }

        .voucher-image {
          position: relative;
          width: 100%;
          aspect-ratio: 1;
          background: white;
          cursor: pointer;

          img {
            width: 100%;
            height: 100%;
            object-fit: cover;
          }

          .delete-btn {
            position: absolute;
            top: 6px;
            right: 6px;
            width: 28px;
            height: 28px;
            border: none;
            background: rgba(235, 68, 90, 0.9);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s;
            padding: 0;

            &:hover {
              background: var(--danger-color, #eb445a);
              transform: scale(1.1);
            }

            .icon {
              width: 16px;
              height: 16px;
              color: white;
            }
          }
        }

        .voucher-info {
          padding: 10px;

          .voucher-amount {
            margin-bottom: 6px;

            .amount-input {
              width: 100%;
              padding: 6px 8px;
              border: 1px solid #e0e0e0;
              border-radius: 6px;
              font-size: 14px;
              font-weight: 600;
              color: var(--primary-color, #3880ff);

              &:focus {
                outline: none;
                border-color: var(--primary-color, #3880ff);
              }
            }

            .amount-text {
              font-size: 16px;
              font-weight: 700;
              color: var(--primary-color, #3880ff);
            }
          }

          .voucher-method {
            font-size: 12px;
            color: var(--dark-color, #222);
            margin-bottom: 4px;
          }

          .voucher-time {
            font-size: 11px;
            color: var(--medium-color, #666);
            margin-bottom: 4px;
          }

          .voucher-product {
            font-size: 11px;
            color: var(--primary-color, #3880ff);
            margin-bottom: 6px;
          }

          .ocr-badge {
            display: flex;
            align-items: center;
            gap: 6px;
            padding: 4px 8px;
            background: rgba(56, 128, 255, 0.1);
            border-radius: 6px;
            font-size: 10px;
            color: var(--primary-color, #3880ff);
            font-weight: 600;

            .confidence {
              background: var(--primary-color, #3880ff);
              color: white;
              padding: 2px 6px;
              border-radius: 4px;
            }
          }
        }
      }
    }

    .upload-section {
      margin-top: 16px;
    }
  }
}

// ==================== 评价Section ====================
.feedback-section {
  .feedback-form-card {
    .rating-section {
      margin-bottom: 24px;

      .rating-label {
        display: block;
        margin-bottom: 12px;
        font-size: 15px;
        font-weight: 600;
        color: var(--dark-color, #222);

        .required {
          color: var(--danger-color, #eb445a);
        }
      }

      .stars-large {
        display: flex;
        justify-content: center;
        gap: 12px;
        margin-bottom: 16px;

        .star-icon {
          width: 44px;
          height: 44px;
          color: #e0e0e0;
          cursor: pointer;
          transition: all 0.2s;

          &.active {
            color: var(--warning-color, #ffc409);
            filter: drop-shadow(0 2px 4px rgba(255, 196, 9, 0.5));
          }

          &:hover {
            transform: scale(1.15);
          }

          &:active {
            transform: scale(0.95);
          }
        }
      }

      .rating-text {
        text-align: center;
        font-size: 16px;
        font-weight: 600;
        color: var(--dark-color, #222);
      }
    }

    .dimensions-section {
      margin-bottom: 24px;

      .section-subtitle {
        font-size: 14px;
        font-weight: 600;
        color: var(--dark-color, #222);
        margin: 0 0 16px 0;
      }

      .dimension-item {
        margin-bottom: 16px;

        label {
          display: block;
          margin-bottom: 8px;
          font-size: 13px;
          color: var(--dark-color, #222);
        }

        .stars {
          display: flex;
          gap: 6px;

          .star-icon {
            width: 28px;
            height: 28px;
            color: #e0e0e0;
            cursor: pointer;
            transition: all 0.2s;

            &.active {
              color: var(--warning-color, #ffc409);
            }

            &:hover {
              transform: scale(1.1);
            }
          }
        }
      }
    }

    .recommendation-section {
      margin-bottom: 24px;

      .checkbox-item {
        display: flex;
        align-items: center;
        gap: 8px;
        margin-bottom: 12px;
        cursor: pointer;

        .checkbox-input {
          width: 18px;
          height: 18px;
          cursor: pointer;
        }

        .checkbox-label {
          font-size: 14px;
          color: var(--dark-color, #222);
        }
      }

      .nps-section {
        margin-top: 12px;

        label {
          display: block;
          margin-bottom: 12px;
          font-size: 13px;
          color: var(--dark-color, #222);
        }

        .nps-scale {
          display: flex;
          gap: 6px;
          flex-wrap: wrap;

          .nps-btn {
            flex: 1;
            min-width: 36px;
            padding: 10px;
            border: 2px solid #e0e0e0;
            background: white;
            border-radius: 8px;
            font-size: 14px;
            font-weight: 600;
            color: var(--medium-color, #666);
            cursor: pointer;
            transition: all 0.3s;

            &.active {
              background: var(--primary-color, #3880ff);
              border-color: var(--primary-color, #3880ff);
              color: white;
            }

            &:hover:not(.active) {
              border-color: var(--primary-color, #3880ff);
              color: var(--primary-color, #3880ff);
            }
          }
        }
      }
    }

    .form-group {
      margin-bottom: 20px;

      .form-label {
        display: block;
        margin-bottom: 8px;
        font-size: 14px;
        font-weight: 600;
        color: var(--dark-color, #222);
      }

      .form-textarea {
        width: 100%;
        padding: 12px;
        border: 1px solid #e0e0e0;
        border-radius: 8px;
        font-size: 14px;
        font-family: inherit;
        resize: vertical;

        &:focus {
          outline: none;
          border-color: var(--primary-color, #3880ff);
        }

        &::placeholder {
          color: var(--medium-color, #666);
        }
      }
    }
  }

  .feedback-result-card {
    .result-rating {
      text-align: center;
      margin-bottom: 24px;

      .stars-display {
        display: flex;
        justify-content: center;
        gap: 8px;
        margin-bottom: 12px;

        .star-icon-large {
          width: 40px;
          height: 40px;
          color: #e0e0e0;

          &.active {
            color: var(--warning-color, #ffc409);
          }
        }
      }

      .rating-score {
        font-size: 32px;
        font-weight: 700;
        color: var(--dark-color, #222);
        margin-bottom: 8px;
      }

      .rating-time {
        font-size: 12px;
        color: var(--medium-color, #666);
      }
    }

    .dimensions-chart {
      margin-bottom: 24px;

      .section-subtitle {
        font-size: 14px;
        font-weight: 600;
        color: var(--dark-color, #222);
        margin: 0 0 16px 0;
      }

      .dimension-bars {
        .bar-item {
          display: flex;
          align-items: center;
          gap: 12px;
          margin-bottom: 16px;

          .bar-label {
            min-width: 80px;
            font-size: 13px;
            color: var(--dark-color, #222);
          }

          .bar-track {
            flex: 1;
            height: 24px;
            background: #f5f5f5;
            border-radius: 12px;
            overflow: hidden;
            position: relative;

            .bar-fill {
              height: 100%;
              background: linear-gradient(90deg, #3880ff, #5598ff);
              border-radius: 12px;
              transition: width 0.8s ease;
              box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.3);
            }
          }

          .bar-value {
            min-width: 30px;
            text-align: center;
            font-size: 14px;
            font-weight: 600;
            color: var(--primary-color, #3880ff);
          }
        }
      }
    }

    .comment-box,
    .improvement-box {
      padding: 16px;
      background: #f5f5f5;
      border-radius: 8px;
      margin-bottom: 16px;

      .section-subtitle {
        font-size: 14px;
        font-weight: 600;
        color: var(--dark-color, #222);
        margin: 0 0 12px 0;
      }

      p {
        margin: 0;
        line-height: 1.6;
        color: var(--medium-color, #666);
        font-size: 14px;
      }
    }

    .recommendation-result {
      .recommend-badge {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
        padding: 16px;
        background: linear-gradient(135deg, #2dd36f, #28ba62);
        border-radius: 12px;
        color: white;
        font-size: 15px;
        font-weight: 600;

        .nps-score {
          background: rgba(255, 255, 255, 0.3);
          padding: 4px 12px;
          border-radius: 12px;
          font-size: 14px;
        }
      }
    }
  }
}

// ==================== 复盘Section ====================
.retrospective-section {
  .empty-retro-card {
    .empty-state {
      text-align: center;
      padding: 60px 20px;

      .icon-large {
        width: 80px;
        height: 80px;
        color: var(--medium-color, #666);
        margin-bottom: 20px;
      }

      p {
        color: var(--medium-color, #666);
        margin-bottom: 12px;
        font-size: 14px;

        &.hint {
          font-size: 12px;
          color: var(--medium-color, #666);
          opacity: 0.8;
        }
      }
    }
  }

  .summary-card {
    .summary-text {
      padding: 16px;
      background: #f5f5f5;
      border-radius: 8px;
      margin-bottom: 20px;
      font-size: 14px;
      line-height: 1.6;
      color: var(--dark-color, #222);
    }

    .highlights-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
      gap: 16px;
      margin-bottom: 24px;

      .highlight-section,
      .challenge-section {
        h4 {
          font-size: 14px;
          font-weight: 600;
          color: var(--dark-color, #222);
          margin: 0 0 12px 0;
        }

        ul {
          margin: 0;
          padding-left: 20px;

          li {
            margin-bottom: 8px;
            font-size: 13px;
            line-height: 1.5;
            color: var(--medium-color, #666);
          }
        }
      }
    }

    .lessons-section,
    .recommendations-section {
      margin-bottom: 20px;

      h4 {
        font-size: 14px;
        font-weight: 600;
        color: var(--dark-color, #222);
        margin: 0 0 12px 0;
      }

      ul {
        margin: 0;
        padding-left: 20px;

        li {
          margin-bottom: 8px;
          font-size: 13px;
          line-height: 1.5;
          color: var(--medium-color, #666);
        }
      }
    }
  }

  .efficiency-card {
    .grade-badge {
      padding: 6px 16px;
      border-radius: 20px;
      font-size: 16px;
      font-weight: 700;
      letter-spacing: 1px;

      &.grade-a {
        background: var(--success-color, #2dd36f);
        color: white;
      }

      &.grade-b {
        background: var(--primary-color, #3880ff);
        color: white;
      }

      &.grade-c {
        background: var(--warning-color, #ffc409);
        color: var(--dark-color, #222);
      }

      &.grade-d,
      &.grade-f {
        background: var(--danger-color, #eb445a);
        color: white;
      }
    }

    .efficiency-score {
      display: flex;
      gap: 24px;
      align-items: center;
      margin-bottom: 24px;

      .score-circle {
        position: relative;
        flex-shrink: 0;

        .score-ring {
          transform: rotate(-90deg);

          .ring-bg {
            opacity: 0.2;
          }

          .ring-progress {
            stroke-dasharray: 376.8;
            stroke-dashoffset: 0;
            transition: stroke-dashoffset 0.8s ease;
            stroke-linecap: round;
            filter: drop-shadow(0 0 4px currentColor);
          }
        }

        .score-label {
          position: absolute;
          top: 50%;
          left: 50%;
          transform: translate(-50%, -50%);
          text-align: center;

          .score-number {
            font-size: 32px;
            font-weight: 700;
            color: var(--dark-color, #222);
            line-height: 1;
          }

          .score-text {
            font-size: 12px;
            color: var(--medium-color, #666);
            margin-top: 4px;
          }
        }
      }

      .efficiency-breakdown {
        flex: 1;

        .breakdown-item {
          display: flex;
          align-items: center;
          gap: 12px;
          margin-bottom: 12px;

          &:last-child {
            margin-bottom: 0;
          }

          .item-label {
            min-width: 70px;
            font-size: 13px;
            color: var(--dark-color, #222);
          }

          .item-bar {
            flex: 1;
            height: 8px;
            background: #e0e0e0;
            border-radius: 4px;
            overflow: hidden;

            .bar-fill {
              height: 100%;
              background: linear-gradient(90deg, #3880ff, #5598ff);
              border-radius: 4px;
              transition: width 0.6s ease;
            }
          }

          .item-value {
            min-width: 40px;
            text-align: right;
            font-size: 13px;
            font-weight: 600;
            color: var(--primary-color, #3880ff);
          }
        }
      }
    }

    .stage-comparison {
      margin-top: 24px;

      .subsection-title {
        font-size: 14px;
        font-weight: 600;
        color: var(--dark-color, #222);
        margin: 0 0 16px 0;
      }

      .stages-list {
        .stage-item {
          background: #f5f5f5;
          border-radius: 8px;
          padding: 12px;
          margin-bottom: 12px;
          border-left: 4px solid var(--success-color, #2dd36f);

          &.delayed {
            border-left-color: var(--danger-color, #eb445a);
          }

          &:last-child {
            margin-bottom: 0;
          }

          .stage-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 8px;

            .stage-name {
              font-size: 14px;
              font-weight: 600;
              color: var(--dark-color, #222);
            }
          }

          .stage-details {
            display: flex;
            gap: 16px;
            font-size: 12px;
            color: var(--medium-color, #666);
            margin-bottom: 6px;

            .efficiency-badge {
              color: var(--primary-color, #3880ff);
              font-weight: 600;
            }
          }

          .delay-reason {
            font-size: 12px;
            color: var(--danger-color, #eb445a);
            background: rgba(235, 68, 90, 0.1);
            padding: 6px 10px;
            border-radius: 6px;
            margin-top: 8px;
          }
        }
      }
    }

    .bottlenecks-section {
      margin-top: 24px;

      .subsection-title {
        font-size: 14px;
        font-weight: 600;
        color: var(--dark-color, #222);
        margin: 0 0 16px 0;
      }

      .bottlenecks-list {
        .bottleneck-item {
          background: #f5f5f5;
          border-radius: 8px;
          padding: 14px;
          margin-bottom: 12px;
          border-left: 4px solid var(--warning-color, #ffc409);

          &.severity-high {
            border-left-color: var(--danger-color, #eb445a);
            background: rgba(235, 68, 90, 0.05);
          }

          &:last-child {
            margin-bottom: 0;
          }

          .bottleneck-header {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-bottom: 8px;

            .severity-icon {
              font-size: 20px;
            }

            .bottleneck-stage {
              flex: 1;
              font-size: 14px;
              font-weight: 600;
              color: var(--dark-color, #222);
            }
          }

          .bottleneck-issue {
            font-size: 13px;
            color: var(--dark-color, #222);
            margin-bottom: 8px;
            padding-left: 30px;
          }

          .bottleneck-suggestion {
            font-size: 12px;
            color: var(--primary-color, #3880ff);
            padding: 8px 12px;
            background: rgba(56, 128, 255, 0.1);
            border-radius: 6px;
            margin-left: 30px;
          }
        }
      }
    }
  }
}

// ==================== 响应式适配 ====================
@media (max-width: 768px) {
  .overview-section {
    .key-metrics {
      grid-template-columns: 1fr;
    }
  }

  .payment-section {
    .payment-stats {
      grid-template-columns: 1fr;
    }

    .vouchers-card .vouchers-list {
      grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }
  }

  .feedback-section {
    .rating-section .stars-large {
      gap: 8px;

      .star-icon {
        width: 36px;
        height: 36px;
      }
    }
  }

  .retrospective-section {
    .summary-card .highlights-grid {
      grid-template-columns: 1fr;
    }

    .efficiency-card .efficiency-score {
      flex-direction: column;
      align-items: center;
      gap: 20px;
    }
  }
}

@media (max-width: 480px) {
  .tab-navigation .tab-buttons .tab-btn {
    min-width: 70px;
    padding: 10px 6px;
    font-size: 12px;

    .icon {
      width: 18px;
      height: 18px;
    }
  }

  .overview-section {
    .completion-card .circular-progress .progress-ring {
      width: 140px;
      height: 140px;

      .progress-text {
        font-size: 24px;
      }
    }

    .quick-actions-card .action-grid {
      grid-template-columns: 1fr;

      .action-card {
        padding: 14px;

        .action-icon {
          font-size: 28px;
        }
      }
    }

    .products-overview-card .products-grid {
      grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
  }

  .payment-section {
    .vouchers-card .vouchers-list {
      grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
  }

  .feedback-section {
    .nps-section .nps-scale {
      .nps-btn {
        min-width: 32px;
        padding: 8px;
        font-size: 13px;
      }
    }

    .dimension-bars .bar-item {
      .bar-label {
        min-width: 70px;
        font-size: 12px;
      }

      .bar-track {
        height: 20px;
      }

      .bar-value {
        font-size: 13px;
      }
    }
  }

  .retrospective-section {
    .efficiency-card {
      .efficiency-score .score-circle {
        .score-ring {
          width: 120px;
          height: 120px;
        }

        .score-label .score-number {
          font-size: 28px;
        }
      }

      .stage-comparison .stages-list .stage-item {
        padding: 10px;

        .stage-header .stage-name {
          font-size: 13px;
        }

        .stage-details {
          flex-direction: column;
          gap: 4px;
        }
      }
    }
  }
}
