/* ============================================
   ChatGPT Plus 充值系统 - Element UI 风格
   完全复刻 plus.aicheap.vip 样式
   ============================================ */

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

body, html {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

#app {
  font-family: Helvetica Neue, Helvetica, PingFang SC, Hiragino Sans GB, Microsoft YaHei, 微软雅黑, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: #2c3e50;
  text-align: center;
}

.full-height {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

/* ============ Header ============ */
.app-header {
  background-color: #409eff;
  color: #fff;
  padding: 0 20px;
  height: 60px;
  display: flex;
  align-items: center;
}

.app-header-row {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.header-flex-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

.header-left-content {
  display: flex;
  align-items: center;
}

.header-right-content {
  display: flex;
  align-items: center;
  gap: 15px;
}

.title-wrapper {
  display: flex;
  align-items: center;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  transition: opacity 0.3s ease;
}

.title-wrapper:hover {
  opacity: 0.85;
}

.header-icon {
  font-size: 24px;
  margin-right: 12px;
}

.text-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.main-title {
  font-size: 18px;
  font-weight: 700;
  white-space: nowrap;
}

.sub-title {
  font-size: 12px;
  color: #d0e0ff;
}

.nav-link {
  color: #fff;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 4px;
  transition: background-color 0.3s;
  font-size: 14px;
}

.nav-link:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.lang-btn {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  padding: 6px 12px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
  font-family: inherit;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.lang-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
}

/* ============ Main Content ============ */
.app-main {
  background-color: #e9eef3;
  color: #333;
  padding: 20px;
  flex: 1;
  overflow-x: hidden;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
}

.responsive-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.col-main {
  flex: 2;
  min-width: 300px;
}

.col-side {
  flex: 1;
  min-width: 280px;
}

/* ============ Card ============ */
.el-card {
  background: #fff;
  border-radius: 10px;
  border: 1px solid #ebeef5;
  box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.el-card__body {
  padding: 20px;
}

.recharge-card {
  min-height: 500px;
  height: auto;
  text-align: left;
  display: flex;
  flex-direction: column;
}

.card-header-wrapper {
  padding: 0 0 15px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  border-bottom: 1px solid #ebeef5;
  margin-bottom: 20px;
}

.card-title {
  font-size: 16px;
  font-weight: 700;
  color: #303133;
}

.card-title i {
  margin-right: 8px;
  color: #409eff;
}

.header-buttons {
  display: flex;
  gap: 8px;
}

.header-btn {
  border: none !important;
  padding: 8px 12px !important;
  font-size: 12px !important;
}

/* ============ Steps ============ */
.el-steps {
  display: flex;
  margin-bottom: 25px;
}

.el-step {
  flex: 1;
  position: relative;
}

.el-step__head {
  display: flex;
  align-items: center;
}

.el-step__line {
  flex: 1;
  height: 2px;
  background: #c0c4cc;
  margin: 0 10px;
}

.el-step:last-child .el-step__line {
  display: none;
}

.el-step__icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #c0c4cc;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
}

.el-step__head.is-process .el-step__icon {
  background: #409eff;
}

.el-step__head.is-success .el-step__icon {
  background: #67c23a;
}

.el-step__main {
  margin-top: 8px;
}

.el-step__title {
  font-size: 13px;
  color: #c0c4cc;
}

.el-step__title.is-process {
  color: #409eff;
  font-weight: 600;
}

.el-step__title.is-success {
  color: #67c23a;
}

/* ============ Form ============ */
.el-form-item {
  margin-bottom: 20px;
}

.el-form-item__label {
  display: block;
  font-size: 14px;
  color: #606266;
  margin-bottom: 8px;
  font-weight: 500;
}

.el-input {
  width: 100%;
  position: relative;
}

.el-input--prefix .el-input__inner {
  padding-left: 40px;
}

.el-input__prefix {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #c0c4cc;
}

.el-input__inner {
  width: 100%;
  height: 40px;
  padding: 0 15px;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  font-size: 14px;
  color: #606266;
  background: #fff;
  transition: border-color 0.2s;
}

.el-input__inner:focus {
  outline: none;
  border-color: #409eff;
}

.el-input__inner::placeholder {
  color: #c0c4cc;
}

.el-textarea {
  width: 100%;
}

.el-textarea__inner {
  width: 100%;
  padding: 10px 15px;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  font-size: 14px;
  color: #606266;
  background: #fff;
  resize: vertical;
  font-family: Monaco, Menlo, Consolas, monospace;
  line-height: 1.5;
  transition: border-color 0.2s;
}

.el-textarea__inner:focus {
  outline: none;
  border-color: #409eff;
}

/* ============ Buttons ============ */
.el-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  border-radius: 4px;
  border: 1px solid #dcdfe6;
  background: #fff;
  color: #606266;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

.el-button:hover {
  color: #409eff;
  border-color: #c6e2ff;
  background-color: #ecf5ff;
}

.el-button--primary {
  background-color: #409eff;
  border-color: #409eff;
  color: #fff;
}

.el-button--primary:hover {
  background-color: #66b1ff;
  border-color: #66b1ff;
  color: #fff;
}

.el-button--success {
  background-color: #67c23a;
  border-color: #67c23a;
  color: #fff;
}

.el-button--success:hover {
  background-color: #85ce61;
  border-color: #85ce61;
  color: #fff;
}

.el-button--warning {
  background-color: #e6a23c;
  border-color: #e6a23c;
  color: #fff;
}

.el-button--warning:hover {
  background-color: #ebb563;
  border-color: #ebb563;
  color: #fff;
}

.el-button--info {
  background-color: #909399;
  border-color: #909399;
  color: #fff;
}

.el-button--info:hover {
  background-color: #a6a9ad;
  border-color: #a6a9ad;
  color: #fff;
}

.el-button--large {
  padding: 12px 24px;
  font-size: 16px;
}

.el-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-block {
  width: 100%;
}

.btn-group {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.btn-group .el-button {
  flex: 1;
}

/* ============ Step Panels ============ */
.step-panel {
  display: none;
  animation: fadeIn 0.3s ease;
}

.step-panel.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============ Token Help Box ============ */
.token-help-box {
  margin: 0 0 20px 0;
  padding: 18px;
  background: linear-gradient(135deg, #fff5e6, #ffe6cc);
  border-left: 4px solid #ff9500;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(255, 149, 0, 0.15);
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 12px;
}

.token-help-item {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 6px;
  border: 1px solid #ffd699;
  transition: all 0.3s ease;
  flex: 1;
  min-width: 250px;
}

.token-help-item:hover {
  background-color: #fff;
  border-color: #ff9500;
  transform: translateX(5px);
  box-shadow: 0 2px 8px rgba(255, 149, 0, 0.2);
}

.token-help-item i {
  font-size: 18px;
  color: #ff9500;
  margin-right: 12px;
  width: 20px;
  text-align: center;
}

.token-help-link {
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  color: #606266;
}

a.token-help-link {
  color: #409eff;
}

a.token-help-link:hover {
  text-decoration: underline;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 149, 0, 0.4); }
  50% { box-shadow: 0 0 0 8px rgba(255, 149, 0, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 149, 0, 0); }
}

.pulse-animation {
  animation: pulse 2s ease-in-out infinite;
}

/* ============ Confirm Table ============ */
.confirm-table {
  margin-bottom: 20px;
}

.confirm-table table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid #ebeef5;
  border-radius: 4px;
  overflow: hidden;
}

.confirm-table tr {
  border-bottom: 1px solid #ebeef5;
}

.confirm-table tr:last-child {
  border-bottom: none;
}

.confirm-table td {
  padding: 14px 16px;
  font-size: 14px;
}

.confirm-table .label-cell {
  background: #f5f7fa;
  color: #909399;
  width: 140px;
}

.confirm-table .label-cell i {
  margin-right: 8px;
  color: #409eff;
}

.confirm-table .value-cell {
  color: #303133;
  font-weight: 500;
}

.confirm-table .value-cell.highlight {
  color: #409eff;
  font-weight: 600;
}

/* ============ Alert ============ */
.el-alert {
  padding: 12px 16px;
  border-radius: 4px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 20px;
}

.el-alert--warning {
  background-color: #fdf6ec;
  border: 1px solid #faecd8;
}

.el-alert--warning .el-alert__icon {
  color: #e6a23c;
}

.el-alert--warning .el-alert__title {
  color: #e6a23c;
}

.el-alert--success {
  background-color: #f0f9eb;
  border: 1px solid #e1f3d8;
}

.el-alert--error {
  background-color: #fef0f0;
  border: 1px solid #fde2e2;
}

.step-result {
  margin: 15px 0;
}

.alert {
  padding: 12px 16px;
  border-radius: 4px;
  font-size: 14px;
}

.alert-success {
  background-color: #f0f9eb;
  border: 1px solid #e1f3d8;
  color: #67c23a;
}

.alert-error {
  background-color: #fef0f0;
  border: 1px solid #fde2e2;
  color: #f56c6c;
}

/* ============ Result ============ */
#finalResult {
  text-align: center;
  padding: 40px 20px;
}

.result-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  margin: 0 auto 20px;
}

.result-icon.success {
  background-color: #f0f9eb;
  color: #67c23a;
}

.result-icon.error {
  background-color: #fef0f0;
  color: #f56c6c;
}

.result-title {
  font-size: 22px;
  font-weight: 700;
  color: #303133;
  margin-bottom: 10px;
}

.result-message {
  font-size: 14px;
  color: #909399;
}

/* ============ Support Info ============ */
.support-info {
  text-align: center;
  font-size: 12px;
  color: #909399;
  margin-top: 20px;
  padding: 12px;
  background-color: #f5f7fa;
  border-radius: 6px;
  border-left: 3px solid #409eff;
}

.support-info i {
  margin-right: 6px;
  color: #409eff;
}

.highlight-wechat {
  color: #e6a23c;
  font-weight: 700;
  background-color: #fdf6ec;
  padding: 2px 8px;
  border-radius: 4px;
  border: 1px solid #f5dab1;
}

/* ============ Log List ============ */
.log-list-wrapper {
  background-color: #f5f7fa;
  border-radius: 6px;
  border: 1px solid #dcdfe6;
  min-height: 300px;
  max-height: 400px;
  overflow-y: auto;
}

.log-list {
  padding: 15px;
  text-align: left;
}

.log-item {
  font-size: 13px;
  color: #606266;
  margin: 0 0 8px 0;
  line-height: 1.6;
  padding: 6px 0;
  border-bottom: 1px dashed #ebeef5;
}

.log-item:last-child {
  border-bottom: none;
}

.log-time {
  color: #909399;
  margin-right: 8px;
}

/* ============ Footer ============ */
.app-footer {
  background-color: #303133;
  color: #fff;
  padding: 15px 20px;
  text-align: center;
}

.footer-text {
  font-size: 13px;
  color: #909399;
  margin: 0;
}

/* ============ Dialog ============ */
.el-dialog__wrapper {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  overflow: auto;
  margin: 0;
  z-index: 2001;
  display: flex;
  align-items: center;
  justify-content: center;
}

.v-modal {
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  opacity: 0.5;
  background: #000;
  z-index: 2000;
}

.el-dialog {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  max-width: 90%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}

.el-dialog__header {
  padding: 15px 20px;
  border-bottom: 1px solid #ebeef5;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.el-dialog__title {
  font-size: 16px;
  font-weight: 600;
  color: #303133;
}

.el-dialog__title i {
  margin-right: 8px;
}

.el-dialog__headerbtn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 20px;
  color: #909399;
  padding: 0;
}

.el-dialog__headerbtn:hover {
  color: #409eff;
}

.el-dialog__body {
  padding: 20px;
  overflow-y: auto;
  max-height: 60vh;
}

.el-dialog__footer {
  padding: 15px 20px;
  border-top: 1px solid #ebeef5;
  text-align: right;
}

/* ============ History ============ */
.history-header {
  display: grid;
  grid-template-columns: 1.2fr 1.5fr 1fr 1fr;
  gap: 8px;
  padding: 12px;
  background: #f5f7fa;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  color: #909399;
  margin-bottom: 10px;
}

.history-header-item {
  text-align: center;
}

.history-item {
  display: grid;
  grid-template-columns: 1.2fr 1.5fr 1fr 1fr;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid #ebeef5;
  font-size: 13px;
  color: #606266;
}

.history-item:last-child {
  border-bottom: none;
}

.history-value {
  text-align: center;
  word-break: break-all;
}

.history-result {
  text-align: center;
  color: #67c23a;
  font-weight: 500;
}

.history-empty {
  text-align: center;
  padding: 40px;
  color: #909399;
}

/* ============ Query Page ============ */
.query-nav a {
  color: #409eff;
  text-decoration: none;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 20px;
  font-size: 14px;
}

.query-nav a:hover {
  text-decoration: underline;
}

.results-table-wrapper {
  overflow-x: auto;
}

.results-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.results-table th {
  background: #f5f7fa;
  padding: 12px;
  text-align: center;
  color: #909399;
  font-weight: 600;
  border-bottom: 1px solid #ebeef5;
}

.results-table td {
  padding: 12px;
  text-align: center;
  color: #606266;
  border-bottom: 1px solid #ebeef5;
}

.status-badge {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
}

.status-valid {
  background: #f0f9eb;
  color: #67c23a;
}

.status-used {
  background: #f5f7fa;
  color: #909399;
}

.status-disabled {
  background: #fef0f0;
  color: #f56c6c;
}

.status-expired {
  background: #fdf6ec;
  color: #e6a23c;
}

.status-notfound {
  background: #f5f7fa;
  color: #c0c4cc;
}

.results-stats {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
}

.stat-item {
  flex: 1;
  background: #fff;
  padding: 16px;
  border-radius: 8px;
  text-align: center;
  border: 1px solid #ebeef5;
}

.stat-label {
  font-size: 12px;
  color: #909399;
  display: block;
}

.stat-value {
  font-size: 28px;
  font-weight: 700;
  color: #303133;
  margin-top: 6px;
  display: block;
}

.results-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
  flex-wrap: wrap;
}

.tab-btn {
  padding: 10px 20px;
  border-radius: 4px;
  border: 1px solid #dcdfe6;
  background: #fff;
  cursor: pointer;
  font-size: 13px;
  font-family: inherit;
  transition: all 0.2s;
  color: #606266;
}

.tab-btn:hover {
  color: #409eff;
  border-color: #c6e2ff;
}

.tab-btn.active {
  background: #409eff;
  color: #fff;
  border-color: #409eff;
}

/* ============ Responsive ============ */
@media (max-width: 768px) {
  .text-container {
    display: none;
  }

  .header-icon {
    margin-right: 0;
  }

  .responsive-row {
    flex-direction: column;
  }

  .col-main, .col-side {
    flex: none;
    width: 100%;
  }

  .col-side {
    margin-top: 20px;
  }

  .recharge-card {
    min-height: auto;
  }

  .card-header-wrapper {
    gap: 10px;
  }

  .header-btn {
    font-size: 11px !important;
    padding: 6px 8px !important;
  }

  .btn-group {
    flex-direction: column;
  }

  .token-help-box {
    flex-direction: column;
  }

  .token-help-item {
    min-width: auto;
  }

  .confirm-table .label-cell {
    width: 100px;
  }

  .el-dialog {
    width: 95% !important;
    max-width: none;
  }

  .history-header,
  .history-item {
    grid-template-columns: 1fr 1fr;
  }

  .history-header-item:nth-child(3),
  .history-header-item:nth-child(4),
  .history-item > *:nth-child(3),
  .history-item > *:nth-child(4) {
    display: none;
  }

  .results-stats {
    flex-wrap: wrap;
  }

  .stat-item {
    min-width: calc(50% - 10px);
  }
}
