/* ============================================================
   Reset & Base
   ============================================================ */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: 'Helvetica Neue', Helvetica, 'PingFang SC', 'Hiragino Sans GB',
    'Microsoft YaHei', '微软雅黑', Arial, sans-serif;
  background: #0f0f23;
  min-height: 100vh;
}

/* ============================================================
   Shared background/shapes
   ============================================================ */
.gradient-bg {
  position: relative;
  min-height: 100vh;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  overflow: hidden;
}
.bg-shapes { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.shape {
  position: absolute; border-radius: 50%;
  background: rgba(255,255,255,.07);
  animation: drift 20s linear infinite;
}
.shape-1 { width: 350px; height: 350px; top: -80px; left: -100px; }
.shape-2 { width: 220px; height: 220px; bottom: -50px; right: -60px; animation-duration: 25s; }
.shape-3 { width: 160px; height: 160px; top: 45%; left: 65%; animation-duration: 18s; animation-direction: reverse; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
@keyframes drift {
  0% { transform: translate(0, 0) rotate(0deg); }
  100% { transform: translate(40px, -40px) rotate(360deg); }
}

/* ============================================================
   User Top Bar
   ============================================================ */
.user-topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(255,255,255,.15);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255,255,255,.2);
  box-shadow: 0 2px 20px rgba(0,0,0,.08);
}
.topbar-content {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px; height: 52px;
}
.topbar-left { display: flex; align-items: center; }
.topbar-logo { font-size: 16px; font-weight: 600; color: rgba(255,255,255,.9); letter-spacing: 1px; }
.topbar-right { display: flex; align-items: center; gap: 12px; }
.user-name { font-size: 14px; color: rgba(255,255,255,.95); font-weight: 500; }
/* 登录/注册按钮 - 毛玻璃风格，融入页面 */
.topbar-auth-btn {
  background: rgba(255,255,255,.2) !important;
  border: 1px solid rgba(255,255,255,.35) !important;
  color: #fff !important;
  backdrop-filter: blur(8px);
  border-radius: 20px !important;
  padding: 6px 20px !important;
  font-size: 13px !important;
  font-weight: 500;
  transition: all .25s !important;
}
.topbar-auth-btn:hover {
  background: rgba(255,255,255,.35) !important;
  border-color: rgba(255,255,255,.55) !important;
  transform: translateY(-1px);
}
.topbar-auth-btn.el-button--primary {
  background: rgba(255,255,255,.85) !important;
  border-color: rgba(255,255,255,.9) !important;
  color: #667eea !important;
  font-weight: 600;
}
.topbar-auth-btn.el-button--primary:hover {
  background: #fff !important;
  color: #5a6fd6 !important;
}
/* 退出按钮 */
.topbar-logout-btn {
  background: transparent !important;
  border: 1px solid rgba(255,255,255,.3) !important;
  color: rgba(255,255,255,.75) !important;
  border-radius: 20px !important;
  padding: 6px 18px !important;
  font-size: 13px !important;
  transition: all .25s !important;
}
.topbar-logout-btn:hover {
  background: rgba(255,255,255,.15) !important;
  border-color: rgba(255,255,255,.5) !important;
  color: #fff !important;
}

/* ============================================================
   Auth Dialogs（登录/注册 - 紫色渐变风格）
   ============================================================ */
.auth-dialog {
  border-radius: 20px !important;
  overflow: hidden;
  background: #fff !important;
  box-shadow: 0 20px 60px rgba(102, 126, 234, .3), 0 0 0 1px rgba(102, 126, 234, .1) !important;
}
.auth-dialog .el-dialog__header {
  margin: 0;
  padding: 0;
}
.auth-dialog .el-dialog__body {
  padding: 28px 36px 32px;
}
.auth-dialog-header {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 16px 0 8px;
  color: #303133; font-size: 18px; font-weight: 700; letter-spacing: 2px;
}
.auth-dialog-icon { font-size: 24px; }
/* 关闭按钮 */
.auth-dialog .el-dialog__close {
  color: #999;
  font-size: 18px;
  font-weight: 700;
}
.auth-dialog .el-dialog__close:hover { color: #666; }
/* 表单 */
.auth-dialog .el-form-item__label {
  color: #555; font-weight: 600; font-size: 14px;
}
.auth-dialog .el-input__wrapper {
  border-radius: 10px;
  box-shadow: 0 0 0 1px #e0e0e0;
  transition: all .3s;
}
.auth-dialog .el-input__wrapper:hover {
  box-shadow: 0 0 0 1px #667eea;
}
.auth-dialog .el-input__wrapper.is-focus {
  box-shadow: 0 0 0 2px rgba(102,126,234,.3);
}
/* 提交按钮 */
.auth-submit-btn {
  width: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  border: none !important;
  color: #fff !important;
  border-radius: 12px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  letter-spacing: 4px;
  height: 46px;
  transition: all .3s;
  box-shadow: 0 4px 16px rgba(102,126,234,.35);
}
.auth-submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(102,126,234,.5);
}
.auth-submit-btn:active { transform: translateY(0); }
/* 切换链接 */
.auth-dialog-footer { margin-top: 6px; }
.auth-switch { margin-top: 14px; text-align: center; font-size: 13px; color: #999; }
.auth-switch a { color: #667eea; text-decoration: none; font-weight: 600; transition: all .2s; }
.auth-switch a:hover { color: #764ba2; text-decoration: underline; }

/* ============================================================
   Need Login Dialog
   ============================================================ */
.need-login-content { text-align: center; padding: 16px 0 4px; }
.need-login-text { font-size: 15px; color: #666; margin-bottom: 24px; line-height: 1.6; }
.need-login-actions { display: flex; gap: 16px; justify-content: center; }
.need-login-actions .auth-submit-btn { width: auto; padding: 12px 36px; }
.auth-outline-btn {
  padding: 12px 36px;
  background: #fff !important;
  border: 2px solid #667eea !important;
  color: #667eea !important;
  border-radius: 12px !important;
  font-size: 16px !important;
  font-weight: 600;
  letter-spacing: 4px;
  transition: all .3s;
}
.auth-outline-btn:hover {
  background: rgba(102,126,234,.06) !important;
  border-color: #764ba2 !important;
  color: #764ba2 !important;
}
/* 忘记密码 */
.auth-forgot { margin-top: 6px; text-align: right; font-size: 13px; }
.auth-forgot a { color: #999; text-decoration: none; transition: all .2s; }
.auth-forgot a:hover { color: #667eea; text-decoration: underline; }
.forgot-tip { text-align: center; font-size: 13px; color: #909399; margin-bottom: 8px; }

/* ============================================================
   Profile Page（个人中心）
   ============================================================ */
.profile-card { max-width: 780px; }
.profile-layout { display: flex; gap: 0; margin-top: 12px; min-height: 260px; }
/* 左侧菜单 */
.profile-menu {
  width: 160px; flex-shrink: 0;
  border-right: 1px solid #f0f0f0;
  padding-right: 0;
}
.profile-menu-item {
  padding: 14px 20px; font-size: 14px; color: #606266;
  cursor: pointer; border-radius: 8px 0 0 8px;
  transition: all .2s; margin-bottom: 4px;
}
.profile-menu-item:hover { background: #f5f0ff; color: #667eea; }
.profile-menu-item.active {
  background: linear-gradient(135deg, rgba(102,126,234,.1), rgba(118,75,162,.08));
  color: #667eea; font-weight: 600;
}
.profile-menu-item.disabled {
  color: #ccc; cursor: not-allowed;
}
.profile-menu-item.disabled:hover { background: transparent; color: #ccc; }
/* 右侧内容 */
.profile-body {
  flex: 1; padding: 0 0 0 32px; min-width: 0;
}
.profile-section-title {
  font-size: 17px; font-weight: 600; color: #303133;
  margin-bottom: 18px; text-align: center;
}
.quota-display {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  padding: 16px 0;
}
.quota-label { font-size: 15px; color: #606266; }
.quota-value {
  font-size: 32px; font-weight: 700;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.quota-value.quota-low {
  background: linear-gradient(135deg, #f56c6c 0%, #e74c3c 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

/* ============================================================
   Home Page
   ============================================================ */
.home-page {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  overflow: hidden;
}
.home-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 40px 24px;
}
.hero-icon {
  font-size: 80px;
  margin-bottom: 20px;
  animation: float 3s ease-in-out infinite;
}
.home-content h1 {
  font-size: 44px; font-weight: 800; color: #fff;
  margin-bottom: 16px; letter-spacing: 3px;
  text-shadow: 0 2px 12px rgba(0,0,0,.2);
}
.hero-desc {
  font-size: 18px; color: rgba(255,255,255,.8);
  margin-bottom: 40px; line-height: 1.6;
}
.home-content .el-button--large {
  padding: 14px 52px; font-size: 18px; border-radius: 50px;
  box-shadow: 0 4px 24px rgba(0,0,0,.25); transition: transform .2s;
}
.home-content .el-button--large:hover {
  transform: translateY(-2px) scale(1.03);
}

/* ============================================================
   Wizard Page
   ============================================================ */
.wizard-page {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  overflow: hidden;
}

/* --- Step bar --- */
.wizard-step-bar { display: none; }
.wizard-step-bar-old {
  position: relative;
  z-index: 3;
  flex-shrink: 0;
  display: flex;
  justify-content: center;
  padding: 28px 24px 16px;
  padding-top: 80px;  /* 顶栏高度 52px + 原有 28px */
}
.step-bar-wrap {
  display: inline-flex;
  align-items: center;
  padding: 14px 32px;
  background: rgba(255,255,255,.12);
  backdrop-filter: blur(12px);
  border-radius: 50px;
  box-shadow: 0 4px 20px rgba(0,0,0,.08);
}
.step-bar { display: flex; align-items: center; }
.step-wrapper { display: flex; align-items: center; }
.step-item {
  display: flex; flex-direction: column; align-items: center;
  padding: 0 18px; cursor: pointer; transition: all 0.3s;
}
.step-number {
  display: flex; width: 36px; height: 36px; font-size: 15px;
  font-weight: 700; color: rgba(255,255,255,.6);
  border: 2px solid rgba(255,255,255,.3);
  border-radius: 50%; align-items: center; justify-content: center;
  transition: all 0.3s; background: transparent;
}
.step-item.active .step-number {
  color: #667eea; background: #fff; border-color: #fff;
  box-shadow: 0 2px 12px rgba(255,255,255,.35);
}
.step-item.completed .step-number {
  color: #fff; background: #52c41a; border-color: #52c41a;
}
.step-label {
  margin-top: 5px; font-size: 12px;
  color: rgba(255,255,255,.5); white-space: nowrap;
}
.step-item.active .step-label { font-weight: 600; color: #fff; }
.step-item.completed .step-label { color: rgba(255,255,255,.8); }
.step-connector {
  width: 44px; height: 2px;
  background: rgba(255,255,255,.12); transition: all 0.3s;
}
.step-connector.active { background: rgba(255,255,255,.45); }

/* --- Step content --- */
.wizard-body {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 24px 30px;
  min-height: 0;
}
.step-panel {
  width: 100%;
  max-width: 960px;
}
.step-panel-card {
  background: rgba(255,255,255,.96);
  border-radius: 20px;
  padding: 36px 44px;
  box-shadow: 0 8px 40px rgba(0,0,0,.1);
}
.step-header { margin-bottom: 24px; text-align: center; }
.step-header h2 { font-size: 24px; font-weight: 700; color: #303133; margin: 0 0 8px; }
.step-header p { font-size: 14px; color: #909399; margin: 0; }

/* --- Navigation buttons --- */
.wizard-nav {
  position: relative;
  z-index: 3;
  flex-shrink: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 960px;
  padding: 0 24px 32px;
  margin: 0 auto;
}
.wizard-nav .nav-right { display: flex; gap: 12px; margin-left: auto; }
.nav-btn-glass {
  background: rgba(255,255,255,.15) !important;
  border: 1px solid rgba(255,255,255,.25) !important;
  color: #fff !important;
  backdrop-filter: blur(8px);
  border-radius: 50px !important;
  padding: 12px 36px !important;
  font-size: 16px !important;
  transition: all .25s !important;
}
.nav-btn-glass:hover {
  background: rgba(255,255,255,.25) !important;
  transform: translateY(-1px);
}
.nav-btn-glass.is-disabled {
  background: rgba(255,255,255,.06) !important;
  border-color: rgba(255,255,255,.1) !important;
  color: rgba(255,255,255,.3) !important;
}

/* ============================================================
   Case Category Bar
   ============================================================ */
.case-category-bar {
  display: flex; align-items: center;
  margin-bottom: 20px; padding: 14px 20px;
  background: linear-gradient(135deg, rgba(102,126,234,.06), rgba(118,75,162,.06));
  border-radius: 14px;
}
.case-category-left { width: 260px; flex-shrink: 0; }
.case-category-center { flex: 1; text-align: center; }
.case-category-right { width: 260px; flex-shrink: 0; text-align: right; }
/* 起诉/执行 radio-button 美化 */
.case-category-center .el-radio-button__inner {
  border-radius: 10px !important;
  border: 2px solid rgba(102,126,234,.25) !important;
  background: #fff !important;
  color: #667eea !important;
  padding: 10px 28px !important;
  font-size: 15px !important;
  font-weight: 600;
  transition: all .3s;
  box-shadow: none !important;
}
.case-category-center .el-radio-button:first-child .el-radio-button__inner {
  border-right: 2px solid rgba(102,126,234,.25) !important;
  margin-right: 6px;
}
.case-category-center .el-radio-button__inner:hover {
  border-color: #764ba2 !important;
  background: rgba(102,126,234,.06) !important;
}
.case-category-center .el-radio-button.is-active .el-radio-button__inner {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  border-color: transparent !important;
  color: #fff !important;
  box-shadow: 0 4px 14px rgba(102,126,234,.4) !important;
}
/* 案件类型下拉 - 渐变实色外框 */
.case-type-select .el-input__wrapper {
  border-radius: 10px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  box-shadow: 0 3px 16px rgba(102,126,234,.4), 0 0 0 3px rgba(102,126,234,.2);
  transition: all .3s;
}
.case-type-select .el-input__wrapper:hover {
  background: linear-gradient(135deg, #5a6fd6 0%, #6a42a0 100%) !important;
  box-shadow: 0 4px 20px rgba(102,126,234,.5), 0 0 0 3px rgba(102,126,234,.3);
  transform: translateY(-1px);
}
.case-type-select .el-input__wrapper.is-focus {
  background: #fff !important;
  box-shadow: 0 0 0 3px #667eea, 0 0 0 6px rgba(102,126,234,.2), 0 4px 20px rgba(102,126,234,.2);
}
.case-type-select .el-input__inner {
  color: #fff !important;
  font-weight: 600;
}
.case-type-select .el-input__inner::placeholder {
  color: #000 !important;
}
.case-type-select .el-select__placeholder {
  color: #000 !important;
}
.case-type-select .el-input__wrapper.is-focus .el-input__inner {
  color: #667eea !important;
}
.case-type-select .el-input__wrapper.is-focus .el-input__inner::placeholder {
  color: #000 !important;
}
.case-type-select .el-input__wrapper.is-focus .el-select__placeholder {
  color: #000 !important;
}
/* 下拉箭头变白 */
.case-type-select .el-input__suffix-inner .el-select__caret {
  color: #667eea !important;
}
.case-type-select .el-input__wrapper.is-focus .el-input__suffix-inner .el-select__caret {
  color: #667eea !important;
}
/* wizard body 去掉步骤条后的顶部留白 */
.wizard-body { padding-top: 28px; }

/* ============================================================
   Case Type Grid
   ============================================================ */
.case-type-grid { display: flex; flex-direction: column; gap: 20px; }
.case-category { width: 100%; }
.category-title {
  display: flex; align-items: center; gap: 8px;
  margin: 0 0 12px; font-size: 17px; font-weight: 600; color: #303133;
}
.category-icon { font-size: 20px; }
.case-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.case-card {
  padding: 18px; cursor: pointer; background: #fff;
  border: 2px solid #e8e8e8; border-radius: 12px; transition: all .25s;
}
.case-card:hover {
  border-color: #667eea; transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(102,126,234,.15);
}
.case-card.selected {
  background: linear-gradient(135deg, rgba(102,126,234,.06), rgba(118,75,162,.06));
  border-color: #667eea;
  box-shadow: 0 4px 16px rgba(102,126,234,.22);
}
.case-card h4 { margin: 0 0 6px; font-size: 15px; font-weight: 600; color: #303133; }
.case-card p { margin: 0; font-size: 13px; line-height: 1.5; color: #999; }

/* ============================================================
   Upload
   ============================================================ */
.upload-section { max-width: 520px; margin: 0 auto; }
.upload-area {
  padding: 44px 28px; text-align: center; background: #fafafa;
  border: 2px dashed #d9d9d9; border-radius: 14px; transition: all .3s;
}
.upload-area:hover { background: #f3f0ff; border-color: #667eea; }
.upload-area.is-dragover { background: #f3f0ff; border-color: #667eea; }
.upload-hint { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.upload-icon-large { font-size: 52px; }
.upload-hint p { margin: 0; font-size: 15px; color: #606266; }
.upload-tip { font-size: 13px !important; color: #bbb !important; }
.file-show-info {
  display: flex; align-items: center; justify-content: center;
  gap: 12px; padding: 18px; background: #f0f5ff;
  border-radius: 10px; font-size: 15px; color: #303133;
}

/* --- Uploaded files list (below upload area) --- */
.uploaded-files {
  margin-top: 14px;
}
.uploaded-file-item {
  background: #f7f8fc;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 8px;
}
.uploaded-file-item:last-child { margin-bottom: 0; }
.file-name-row {
  display: flex; align-items: center;
  gap: 8px;
}
.file-icon { font-size: 18px; flex-shrink: 0; }
.file-name {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-size: 14px; color: #303133;
}
.file-remove-btn {
  flex-shrink: 0; cursor: pointer;
  width: 22px; height: 22px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%; font-size: 13px; color: #999;
  transition: all .2s;
}
.file-remove-btn:hover { background: #f56c6c; color: #fff; }
.file-type-row {
  margin-top: 8px; padding-left: 26px;
}
.file-type-select { width: 180px; }
.generate-section { margin-top: 22px; text-align: center; }

/* ============================================================
   Progress
   ============================================================ */
.progress-section { padding: 22px; margin-top: 22px; background: #fafafa; border-radius: 10px; }
.progress-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-size: 15px; }
.progress-title { color: #303133; }
.progress-percent { font-weight: 700; color: #667eea; font-size: 17px; }
.progress-tip { margin: 10px 0 0; font-size: 13px; color: #999; text-align: center; }
.progress-id { margin: 6px 0 0; font-size: 12px; color: #bbb; text-align: center; }

/* ============================================================
   Result Files
   ============================================================ */
.files-empty { padding: 40px; color: #bbb; text-align: center; }
.generated-files { display: flex; flex-direction: column; gap: 12px; }
.file-card {
  display: flex; align-items: center; padding: 16px 18px; background: #fafafa;
  border: 1px solid #eee; border-radius: 12px; transition: all .25s;
}
.file-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,.06); border-color: #667eea; }
.file-icon { margin-right: 14px; font-size: 34px; }
.file-info { flex: 1; }
.file-info h4 { margin: 0 0 3px; font-size: 15px; color: #303133; }
.file-size { font-size: 13px; color: #999; }
.file-actions { display: flex; gap: 8px; }
.result-actions {
  display: flex; justify-content: space-between;
  padding-top: 20px; margin-top: 24px; border-top: 1px solid #f0f0f0;
}

/* ============================================================
   Preview Dialog
   ============================================================ */
.preview-content { padding: 8px; }
.preview-filename { margin-bottom: 10px; font-size: 14px; font-weight: 500; color: #333; }
.preview-loading {
  display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 40px;
}
.preview-loading p { margin-top: 12px; color: #667eea; font-size: 14px; }
.preview-iframe {
  width: 100%; height: 600px; border: 1px solid #eee; border-radius: 10px;
}
.preview-fallback {
  display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 40px; color: #999;
}
.preview-fallback p { margin-bottom: 16px; }

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
.loading-spinner {
  width: 40px; height: 40px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #667eea;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
