/* Strikingly 风格 - 现代简洁 */

/* 未登录时隐藏主内容 */
body.auth-required .top-nav,
body.auth-required .main-content,
body.auth-required .page {
  display: none !important;
}

body.auth-required {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
}

body.auth-required .auth-modal {
  display: flex !important;
}

:root {
  --primary-purple: #6b4fbb;
  --primary-purple-dark: #5a3fa8;
  --primary-orange: #ff6b35;
  --bg-white: #ffffff;
  --bg-light: #f8f9fa;
  --bg-gray: #f5f5f5;
  --text-dark: #333333;
  --text-gray: #666666;
  --text-light: #999999;
  --border-color: #e5e5e5;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.16);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
}

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

body {
  font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg-light);
  color: var(--text-dark);
  font-size: 14px;
  line-height: 1.6;
}

/* 顶部导航 */
.top-nav {
  height: 60px;
  background: var(--primary-purple);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 32px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  font-weight: 600;
  font-size: 18px;
}

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

.nav-links {
  display: flex;
  gap: 8px;
}

.nav-link {
  color: rgba(255,255,255,0.8);
  text-decoration: none;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  transition: all 0.2s;
}

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

.nav-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.cost-badge {
  color: rgba(255,255,255,0.9);
  font-size: 13px;
}

.btn-upgrade {
  background: var(--primary-orange);
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-upgrade:hover {
  background: #e55a2b;
}

.user-avatar {
  width: 32px;
  height: 32px;
  background: rgba(255,255,255,0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* 主内容区 */
.main-content {
  margin-top: 60px;
  min-height: calc(100vh - 60px);
}

.page {
  display: none;
}

.page.active {
  display: block;
}

/* 首页 Hero */
.hero-section {
  text-align: center;
  padding: 48px 24px 32px;
  background: var(--bg-white);
}

.hero-title {
  font-size: 32px;
  font-weight: 600;
  color: var(--text-dark);
}

/* 快速创建区 - Strikingly 风格 */
.quick-create-box {
  max-width: 800px;
  margin: 0 auto;
  padding: 24px;
  background: linear-gradient(135deg, #f0f4ff 0%, #faf5ff 100%);
  border-radius: var(--radius-lg);
  border: 1px solid #e8e0f0;
}

.quick-create-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  color: var(--primary-purple);
  font-size: 18px;
  font-weight: 600;
}

.quick-icon {
  font-size: 22px;
}

/* 内联表单（初始状态） */
.quick-inline-form {
  display: flex;
  gap: 12px;
  align-items: center;
}

.quick-inline-form.hidden {
  display: none;
}

.quick-input-inline {
  flex: 1;
  padding: 14px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  background: white;
}

.quick-input-inline:focus {
  border-color: var(--primary-purple);
  box-shadow: 0 0 0 3px rgba(107, 79, 187, 0.1);
}

.quick-input-inline::placeholder {
  color: var(--text-light);
}

.btn-create-inline {
  padding: 14px 24px;
  background: linear-gradient(135deg, var(--primary-purple) 0%, #8b5cf6 100%);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-create-inline:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(107, 79, 187, 0.3);
}

.quick-input-group {
  margin-bottom: 16px;
}

.quick-input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  background: white;
}

.quick-input:focus {
  border-color: var(--primary-purple);
  box-shadow: 0 0 0 3px rgba(107, 79, 187, 0.1);
}

.quick-input::placeholder {
  color: var(--text-light);
}

.quick-textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 15px;
  font-family: inherit;
  resize: none;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  background: white;
}

.quick-textarea:focus {
  border-color: var(--primary-purple);
  box-shadow: 0 0 0 3px rgba(107, 79, 187, 0.1);
}

/* 展开表单样式 */
.expanded-form {
  display: none;
  animation: slideDown 0.3s ease;
}

.expanded-form.active {
  display: block;
}

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

/* 选项行 */
.options-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 16px;
}

.option-group {
  display: flex;
  flex-direction: column;
}

.option-group label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-dark);
  margin-bottom: 8px;
}

.option-select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 14px;
  background: white;
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s;
}

.option-select:focus {
  border-color: var(--primary-purple);
}

/* 子域名输入 */
.option-group.full-width {
  grid-column: 1 / -1;
}

.subdomain-input-group {
  display: flex;
  align-items: center;
  gap: 0;
}

.subdomain-input {
  flex: 0 0 200px;
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}

.subdomain-input:focus {
  border-color: var(--primary-purple);
}

.subdomain-suffix {
  padding: 10px 14px;
  background: var(--bg-gray);
  border: 1px solid var(--border-color);
  border-left: none;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-size: 14px;
  color: var(--text-gray);
  white-space: nowrap;
}

.input-hint {
  font-size: 12px;
  color: var(--text-light);
  margin-top: 6px;
}

.input-hint.error {
  color: #e74c3c;
}

.input-hint.success {
  color: #27ae60;
}

.optional {
  font-weight: normal;
  color: var(--text-light);
  font-size: 12px;
}

/* 单选按钮组 */
.radio-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.radio-item {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.radio-item input[type="radio"] {
  width: 16px;
  height: 16px;
  accent-color: var(--primary-purple);
  cursor: pointer;
}

.radio-label {
  font-size: 14px;
  color: var(--text-dark);
}

/* 高级设置切换 */
.advanced-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--primary-purple);
  font-size: 13px;
  cursor: pointer;
  margin: 8px 0 16px;
  user-select: none;
}

.advanced-toggle:hover {
  text-decoration: underline;
}

#advancedArrow {
  font-size: 10px;
  transition: transform 0.2s;
}

#advancedArrow.rotated {
  transform: rotate(180deg);
}

/* 高级设置面板 */
.advanced-settings {
  display: none;
  padding: 20px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  border: 1px solid var(--border-color);
}

.advanced-settings.active {
  display: block;
}

/* 生成按钮 - 紫色渐变 */
.btn-create-full {
  width: 100%;
  padding: 14px 28px;
  background: linear-gradient(135deg, var(--primary-purple) 0%, #8b5cf6 100%);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-create-full:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(107, 79, 187, 0.3);
}

.btn-create-full:active {
  transform: translateY(0);
}

/* 响应式 */
@media (max-width: 768px) {
  .options-row {
    grid-template-columns: 1fr;
  }
}

/* 模板选择区 */
.template-section {
  padding: 32px 24px;
}

.template-hint {
  text-align: center;
  color: var(--text-gray);
  margin-bottom: 24px;
}

.template-layout {
  display: flex;
  gap: 24px;
  max-width: 1400px;
  margin: 0 auto;
}

/* 左侧分类 */
.category-sidebar {
  width: 180px;
  flex-shrink: 0;
}

.category-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  cursor: pointer;
  border-radius: var(--radius-md);
  transition: all 0.2s;
  color: var(--text-gray);
}

.category-item:hover {
  background: var(--bg-white);
  color: var(--text-dark);
}

.category-item.active {
  background: var(--bg-white);
  color: var(--primary-purple);
  font-weight: 500;
  box-shadow: var(--shadow-sm);
}

.category-icon {
  font-size: 18px;
}

.category-name {
  flex: 1;
}

.category-arrow {
  color: var(--primary-purple);
  opacity: 0;
  transition: opacity 0.2s;
}

.category-item.active .category-arrow {
  opacity: 1;
}

/* 模板网格 */
.template-grid-container {
  flex: 1;
}

.grid-title {
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 20px;
  color: var(--text-dark);
}

.template-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}

/* 模板卡片 */
.template-card {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: var(--shadow-sm);
}

.template-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.template-card-preview {
  position: relative;
  height: 220px;
  overflow: hidden;
}

.template-card-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.template-card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 60%, rgba(0,0,0,0.6) 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.3s;
}

.template-card:hover .template-card-overlay {
  opacity: 1;
}

.template-card-title {
  color: white;
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 4px;
}

.template-card-subtitle {
  color: rgba(255,255,255,0.8);
  font-size: 13px;
}

.template-card-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--primary-purple);
  color: white;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 500;
}

.template-card-actions {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  gap: 8px;
}

.template-action-btn {
  width: 36px;
  height: 36px;
  background: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s;
}

.template-action-btn:hover {
  transform: scale(1.1);
}

/* 生成表单页 */
.builder-container {
  max-width: 700px;
  margin: 0 auto;
  padding: 32px 24px;
}

.builder-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.btn-back {
  background: none;
  border: none;
  color: var(--text-gray);
  cursor: pointer;
  font-size: 14px;
}

.btn-back:hover {
  color: var(--primary-purple);
}

.builder-header h2 {
  font-size: 24px;
  font-weight: 600;
}

.form-card {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.selected-template {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: var(--bg-light);
  border-radius: var(--radius-md);
  margin-bottom: 24px;
}

.template-preview-small {
  width: 80px;
  height: 60px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: var(--radius-sm);
}

.selected-template .template-info {
  flex: 1;
}

.selected-template .template-name {
  font-weight: 600;
  display: block;
}

.selected-template .template-type {
  color: var(--text-light);
  font-size: 12px;
}

.btn-change {
  background: none;
  border: 1px solid var(--border-color);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-gray);
  cursor: pointer;
  font-size: 13px;
}

.btn-change:hover {
  border-color: var(--primary-purple);
  color: var(--primary-purple);
}

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

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: var(--text-dark);
}

.required {
  color: var(--primary-orange);
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
  font-family: inherit;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  border-color: var(--primary-purple);
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
}

/* 按钮样式 */
.btn-primary {
  background: var(--primary-orange);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background 0.2s;
}

.btn-primary:hover {
  background: #e55a2b;
}

.btn-secondary {
  background: var(--bg-white);
  color: var(--text-dark);
  border: 1px solid var(--border-color);
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-secondary:hover {
  border-color: var(--primary-purple);
  color: var(--primary-purple);
}

.btn-danger {
  background: #fff;
  color: #dc3545;
  border: 1px solid #dc3545;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-danger:hover {
  background: #dc3545;
  color: white;
}

.btn-icon-only {
  width: 40px;
  height: 40px;
  background: var(--bg-white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.btn-icon-only:hover {
  border-color: var(--primary-purple);
  background: var(--bg-light);
}

/* 结果预览页 */
.result-container {
  padding: 24px;
  max-width: 1400px;
  margin: 0 auto;
}

.result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.result-info h2 {
  font-size: 20px;
  margin-bottom: 8px;
}

.result-meta {
  display: flex;
  gap: 20px;
  color: var(--text-gray);
  font-size: 13px;
}

.result-actions {
  display: flex;
  gap: 12px;
}

.preview-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: var(--bg-white);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  border: 1px solid var(--border-color);
  border-bottom: none;
}

.device-switcher {
  display: flex;
  gap: 8px;
}

.device-btn {
  background: none;
  border: 1px solid var(--border-color);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 13px;
  transition: all 0.2s;
}

.device-btn:hover,
.device-btn.active {
  background: var(--primary-purple);
  color: white;
  border-color: var(--primary-purple);
}

.btn-fullscreen {
  background: none;
  border: none;
  color: var(--text-gray);
  cursor: pointer;
  font-size: 13px;
}

.preview-wrapper {
  background: var(--bg-gray);
  border: 1px solid var(--border-color);
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  padding: 20px;
  min-height: 600px;
  display: flex;
  justify-content: center;
}

.preview-frame {
  background: white;
  box-shadow: var(--shadow-lg);
  transition: width 0.3s;
  overflow: hidden;
}

.preview-frame.desktop {
  width: 100%;
  max-width: 1200px;
}

.preview-frame.tablet {
  width: 768px;
}

.preview-frame.mobile {
  width: 375px;
}

.preview-frame iframe {
  width: 100%;
  height: 800px;
  border: none;
}

/* 我的网站页 */
.sites-container {
  padding: 32px 24px;
  max-width: 1400px;
  margin: 0 auto;
}

.sites-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.sites-header h2 {
  font-size: 24px;
  font-weight: 600;
}

.sites-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

.site-card {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s;
}

.site-card:hover {
  box-shadow: var(--shadow-md);
}

.site-card-preview {
  height: 180px;
  background: var(--bg-gray);
  position: relative;
}

.site-card-preview iframe {
  width: 200%;
  height: 200%;
  transform: scale(0.5);
  transform-origin: top left;
  pointer-events: none;
  border: none;
}

.site-card-info {
  padding: 16px;
}

.site-card-name {
  font-weight: 600;
  margin-bottom: 8px;
}

.site-card-meta {
  display: flex;
  gap: 16px;
  color: var(--text-light);
  font-size: 12px;
  margin-bottom: 12px;
}

.site-card-url {
  margin-bottom: 12px;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-card-url a {
  color: var(--primary-purple);
  text-decoration: none;
  transition: color 0.2s;
}

.site-card-url a:hover {
  color: var(--primary-purple-dark);
  text-decoration: underline;
}

.site-card-actions {
  display: flex;
  gap: 8px;
}

.site-card-actions button {
  flex: 1;
  padding: 8px;
  font-size: 12px;
}

/* 费用中心 */
.cost-container {
  padding: 32px 24px;
  max-width: 1000px;
  margin: 0 auto;
}

.cost-header h2 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 24px;
}

.cost-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.cost-card {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.cost-card-title {
  color: var(--text-gray);
  margin-bottom: 12px;
}

.cost-card-value {
  font-size: 32px;
  font-weight: 600;
  color: var(--primary-purple);
  margin-bottom: 12px;
}

.cost-card-subtitle {
  font-size: 12px;
  color: var(--text-light);
  margin-top: 8px;
}

.quota-bar {
  width: 100%;
  height: 8px;
  background: var(--bg-gray);
  border-radius: 4px;
  overflow: hidden;
}

.quota-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary-purple), var(--primary-orange));
  border-radius: 4px;
  transition: width 0.5s ease;
}

.plan-badge {
  display: inline-block;
  padding: 4px 12px;
  background: var(--primary-purple);
  color: white;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  margin-left: 12px;
}

.cost-header {
  display: flex;
  align-items: center;
  margin-bottom: 24px;
}

.quota-tips {
  margin-top: 24px;
  padding: 16px;
  background: #f0f4ff;
  border-radius: var(--radius-md);
  color: var(--text-gray);
  font-size: 14px;
}

/* 套餐升级区域 */
.upgrade-section {
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--border-color);
}

.upgrade-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--text-dark);
}

.pricing-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.pricing-card {
  background: white;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: box-shadow 0.2s;
}

.pricing-card:hover {
  box-shadow: var(--shadow-md);
}

.pricing-card.featured {
  border: 1px solid var(--border-color);
}

.pricing-header {
  padding: 20px;
  text-align: center;
  border-bottom: 1px solid var(--border-color);
}

.pricing-period {
  font-size: 14px;
  color: var(--text-gray);
  margin-bottom: 12px;
}

.pricing-price {
  font-size: 32px;
  font-weight: 700;
  color: var(--text-dark);
}

.pricing-features {
  padding: 20px;
}

.feature-item {
  display: flex;
  align-items: center;
  padding: 8px 0;
  font-size: 13px;
  color: var(--text-dark);
}

.feature-item .check {
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 8px;
  color: #2ed573;
  font-weight: bold;
}

.feature-item.disabled {
  color: var(--text-light);
}

.feature-item.disabled .check {
  color: #ddd;
}

.feature-item strong {
  color: var(--text-dark);
  margin-left: 4px;
}

.pricing-btn {
  display: block;
  width: calc(100% - 40px);
  margin: 0 20px 20px;
  padding: 12px;
  border: none;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

.pricing-btn.current {
  background: #f5f5f5;
  color: var(--text-light);
  cursor: default;
}

.pricing-btn.upgrade {
  background: #4a90e2;
  color: white;
}

.pricing-btn.upgrade:hover {
  background: #357abd;
}

.pricing-btn.upgrade.featured {
  background: var(--primary-purple);
}

.pricing-btn.upgrade.featured:hover {
  background: var(--primary-purple-dark);
}

@media (max-width: 1024px) {
  .pricing-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .pricing-cards {
    grid-template-columns: 1fr;
  }
}

/* 生成中页面 - Strikingly 风格 */
.generating-page {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: none;
  z-index: 2000;
  background: #f8f9fc;
}

.generating-page.active {
  display: flex;
}

/* 左侧信息栏 */
.generating-sidebar {
  width: 280px;
  background: white;
  padding: 24px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border-color);
}

.generating-logo {
  font-size: 18px;
  font-weight: 600;
  color: var(--primary-purple);
  margin-bottom: 32px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.generating-info {
  flex: 1;
}

.info-item {
  margin-bottom: 24px;
}

.info-item label {
  font-size: 12px;
  color: var(--text-light);
  display: block;
  margin-bottom: 4px;
}

.info-item p {
  font-size: 14px;
  color: var(--text-dark);
  margin: 0;
  line-height: 1.5;
}

.generating-status {
  color: var(--primary-purple);
  font-size: 13px;
  margin-bottom: 24px;
}

.status-text {
  display: block;
  margin-bottom: 4px;
}

.status-percent {
  font-weight: 600;
}

.btn-back-gen {
  background: none;
  border: none;
  color: var(--text-gray);
  font-size: 13px;
  cursor: pointer;
  text-align: left;
  padding: 8px 0;
}

.btn-back-gen:hover {
  color: var(--primary-purple);
}

/* 右侧预览骨架 */
.generating-preview {
  flex: 1;
  padding: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.skeleton-page {
  width: 100%;
  max-width: 900px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
  padding: 24px;
  position: relative;
}

/* 骨架元素 */
.skeleton-box {
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 4px;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 16px;
  border-bottom: 1px solid #f0f0f0;
  margin-bottom: 32px;
}

.skeleton-nav-links {
  display: flex;
  gap: 16px;
}

.skeleton-hero {
  text-align: center;
  padding: 48px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.skeleton-content {
  padding: 32px 0;
}

.skeleton-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.skeleton-card {
  padding: 16px;
  background: #fafafa;
  border-radius: 8px;
}

/* 分析提示弹窗 - 带进度条 */
.analyzing-popup {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: white;
  padding: 24px 40px;
  border-radius: 16px;
  box-shadow: 0 12px 48px rgba(0,0,0,0.15);
  min-width: 320px;
  text-align: center;
}

.analyzing-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 20px;
}

.analyzing-icon {
  font-size: 24px;
  animation: pulse 1.5s ease-in-out infinite;
}

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

.analyzing-text {
  font-size: 16px;
  font-weight: 500;
  color: var(--text-dark);
}

/* 进度条容器 */
.progress-bar-container {
  width: 100%;
  height: 8px;
  background: #e8e8e8;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 12px;
}

/* 进度条 */
.progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--primary-purple) 0%, #8b5cf6 50%, var(--primary-purple) 100%);
  background-size: 200% 100%;
  border-radius: 4px;
  transition: width 0.3s ease;
  animation: progressShimmer 2s linear infinite;
}

@keyframes progressShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* 进度百分比 */
.progress-percent {
  font-size: 14px;
  color: var(--primary-purple);
  font-weight: 600;
}

/* 响应式 */
@media (max-width: 768px) {
  .generating-page {
    flex-direction: column;
  }
  
  .generating-sidebar {
    width: 100%;
    padding: 16px;
  }
  
  .skeleton-cards {
    grid-template-columns: 1fr;
  }
}

/* 保留小型 spinner 用于其他地方 */
.loading-spinner {
  width: 48px;
  height: 48px;
  border: 3px solid var(--border-color);
  border-top-color: var(--primary-purple);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 20px;
}

.loading-spinner.small {
  width: 24px;
  height: 24px;
  border-width: 2px;
  margin: 0 auto 12px;
}

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

/* 弹窗 */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}

.modal-overlay.active {
  display: flex;
}

.modal-content {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  width: 90%;
  max-width: 480px;
  max-height: 90vh;
  overflow: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
  font-size: 18px;
  font-weight: 600;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  color: var(--text-light);
  cursor: pointer;
}

.modal-body {
  padding: 24px;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 16px 24px;
  border-top: 1px solid var(--border-color);
}

.translate-info {
  background: var(--bg-light);
  padding: 16px;
  border-radius: var(--radius-md);
  margin-bottom: 20px;
}

.translate-info p {
  margin: 4px 0;
  color: var(--text-gray);
}

.translate-progress,
.translate-result {
  display: none;
  text-align: center;
  padding: 20px;
}

.translate-progress.active,
.translate-result.active {
  display: block;
}

.success-text {
  color: #22c55e;
  font-weight: 500;
  margin-bottom: 8px;
}

/* 响应式 */
@media (max-width: 1024px) {
  .template-layout {
    flex-direction: column;
  }
  
  .category-sidebar {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }
  
  .category-item {
    padding: 8px 12px;
  }
  
  .category-arrow {
    display: none;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  
  .quick-create-form {
    flex-direction: column;
  }
  
  .template-grid {
    grid-template-columns: 1fr;
  }
  
  .form-row {
    grid-template-columns: 1fr;
  }
  
  .cost-cards {
    grid-template-columns: 1fr;
  }
  
  .result-header {
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
  }
}


/* ============ 认证相关样式 ============ */

/* 认证弹窗 */
.auth-modal {
  max-width: 400px;
}

.auth-error {
  color: #e53935;
  font-size: 14px;
  margin-bottom: 16px;
  min-height: 20px;
}

.auth-switch {
  text-align: center;
  margin-top: 16px;
  color: #666;
  font-size: 14px;
}

.auth-switch a {
  color: #4f46e5;
  text-decoration: none;
}

.auth-switch a:hover {
  text-decoration: underline;
}

.btn-full {
  width: 100%;
  padding: 12px;
  font-size: 16px;
}

.confirm-hint {
  color: #666;
  font-size: 14px;
  margin-bottom: 16px;
  text-align: center;
}

/* 用户菜单 */
.user-menu {
  position: fixed;
  top: 60px;
  right: 20px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  min-width: 200px;
  z-index: 1000;
  display: none;
  overflow: hidden;
}

.user-menu.active {
  display: block;
}

.user-menu-header {
  padding: 16px;
  background: #f8f9fa;
  border-bottom: 1px solid #eee;
}

.user-menu-header span {
  display: block;
}

#userMenuName {
  font-weight: 600;
  color: #333;
}

#userMenuEmail {
  font-size: 12px;
  color: #666;
  margin-top: 4px;
}

.user-menu-divider {
  height: 1px;
  background: #eee;
}

.user-menu-item {
  display: block;
  padding: 12px 16px;
  color: #333;
  text-decoration: none;
  transition: background 0.2s;
}

.user-menu-item:hover {
  background: #f5f5f5;
}

.user-menu-item.logout {
  color: #e53935;
}

/* 用户头像样式 */
.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.2s;
}

.user-avatar:hover {
  transform: scale(1.05);
}

/* 点击外部关闭用户菜单 */
.user-menu-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 999;
}
