/* 基础重置和变量 */
:root {
  --primary-color: #1890ff;
  --primary-dark: #096dd9;
  --primary-light: #40a9ff;
  --secondary-color: #6c757d;
  --success-color: #52c41a;
  --warning-color: #faad14;
  --error-color: #ff4d4f;
  --background-color: #f5f5f5;
  --surface-color: #ffffff;
  --text-primary: #262626;
  --text-secondary: #595959;
  --text-muted: #8c8c8c;
  --border-color: #d9d9d9;
  --border-light: #f0f0f0;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 4px 16px rgba(0, 0, 0, 0.08);
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 8px;
  --radius-xl: 12px;
  --transition: all 0.2s ease-in-out;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background-color: var(--background-color);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
}

/* 通用样式 */
.hidden {
  display: none !important;
}

.btn {
  padding: 8px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  background: var(--surface-color);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  position: relative;
  z-index: 1;
}

.btn:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.btn.primary {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
}

.btn.primary:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  color: white;
}

.btn.secondary {
  background: var(--secondary-color);
  border-color: var(--secondary-color);
  color: white;
  position: relative;
  z-index: 10;
  flex-shrink: 0;
  white-space: nowrap;
}

.btn.secondary:hover {
  background: #5a6268;
  border-color: #5a6268;
}

.btn.outline {
  background: transparent;
  border-color: var(--border-color);
  color: var(--text-secondary);
}

.btn.outline:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn.small {
  padding: 4px 8px;
  font-size: 12px;
}

.btn.large {
  padding: 12px 24px;
  font-size: 16px;
}

.btn.full-width {
  width: 100%;
}

.btn-icon {
  font-size: 16px;
}

/* 认证界面 */
.auth-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.auth-container {
  max-width: 800px;
  width: 100%;
}

.auth-card {
  background: var(--surface-color);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 40px 30px;
  text-align: center;
}

.auth-card .logo h1 {
  font-size: 32px;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 8px;
}

.auth-card .tagline {
  color: var(--text-secondary);
  margin-bottom: 30px;
  font-size: 16px;
}

.auth-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 30px;
}

.auth-btn {
  padding: 16px 20px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  background: var(--surface-color);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  width: 100%;
}

.auth-btn:hover {
  border-color: var(--primary-color);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.auth-btn .icon {
  font-size: 20px;
  width: 24px;
}

.auth-btn .text strong {
  display: block;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.auth-btn .text small {
  font-size: 12px;
  color: var(--text-muted);
}

.auth-btn.primary {
  border-color: var(--primary-color);
  background: rgba(24, 144, 255, 0.05);
}

.auth-btn.secondary {
  border-color: var(--secondary-color);
  background: rgba(108, 117, 125, 0.05);
}

.auth-btn.outline {
  border-color: var(--border-color);
  background: transparent;
}

/* 功能网格布局 - 修复文字颜色 */
.features-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 15px;
  margin-top: 20px;
}

.feature-item {
  text-align: center;
  padding: 15px 12px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.3);
  transition: var(--transition);
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  backdrop-filter: blur(10px);
}

.feature-item:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 1);
  box-shadow: var(--shadow-md);
}

.feature-item .feature-icon {
  font-size: 24px;
  margin-bottom: 8px;
  display: block;
}

.feature-item h3 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text-primary);
  line-height: 1.3;
}

.feature-item p {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.3;
  margin: 0;
}

/* 主界面 */
.main-section {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.main-header {
  background: var(--surface-color);
  border-bottom: 1px solid var(--border-color);
  padding: 0 20px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  position: relative;
  z-index: 100;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 25px;
}

.logo h2 {
  color: var(--primary-color);
  font-size: 18px;
  font-weight: 700;
}

.main-nav {
  display: flex;
  gap: 4px;
}

.nav-btn {
  padding: 8px 16px;
  border: none;
  background: none;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-radius: var(--radius-md);
  transition: var(--transition);
  position: relative;
  z-index: 1;
}

.nav-btn:hover {
  color: var(--primary-color);
  background: rgba(24, 144, 255, 0.05);
}

.nav-btn.active {
  color: var(--primary-color);
  background: rgba(24, 144, 255, 0.1);
  font-weight: 600;
}

.nav-btn.admin-only {
  background: rgba(245, 34, 45, 0.1);
  color: #f5222d;
}

.nav-btn.admin-only.active {
  background: rgba(245, 34, 45, 0.2);
}

/* 修复用户信息区域布局 */
.header-right {
  display: flex;
  align-items: center;
  margin-left: auto;
  position: relative;
  z-index: 100;
  min-width: 0;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--text-primary);
  max-width: none;
  min-width: fit-content;
  flex-shrink: 0;
  overflow: visible;
}

.user-info span {
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex-shrink: 1;
  min-width: 0;
}

/* 主要内容 */
.main-content {
  flex: 1;
  padding: 24px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.module {
  display: none;
}

.module.active {
  display: block;
  animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.module-header {
  margin-bottom: 24px;
}

.module-header h1 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.module-header p {
  color: var(--text-secondary);
  font-size: 16px;
}

.module-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.email-count {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 500;
}

/* 当前邮箱横幅 */
.current-email-banner {
  background: var(--primary-color);
  color: white;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
}

.current-email-banner .email-address {
  font-family: monospace;
  background: rgba(255, 255, 255, 0.2);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
}

/* 邮箱生成器 */
.email-generator {
  background: var(--surface-color);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
}

.current-email {
  margin-bottom: 24px;
}

.current-email label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
  font-size: 14px;
}

.email-display {
  display: flex;
  gap: 12px;
  align-items: center;
}

#emailDisplay {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 500;
  background: var(--background-color);
  color: var(--text-primary);
  font-family: monospace;
}

#emailDisplay:focus {
  outline: none;
  border-color: var(--primary-color);
}

.email-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.tips {
  margin-top: 24px;
  padding: 16px;
  background: rgba(24, 144, 255, 0.05);
  border-radius: var(--radius-md);
  border-left: 4px solid var(--primary-color);
}

.tips h4 {
  margin-bottom: 8px;
  color: var(--text-primary);
}

.tips ul {
  list-style: none;
  font-size: 14px;
  color: var(--text-secondary);
}

.tips li {
  margin-bottom: 6px;
  padding-left: 16px;
  position: relative;
}

.tips li:before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--primary-color);
}

/* 自定义邮箱表单 */
.custom-email-form {
  background: var(--surface-color);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
  font-size: 14px;
}

.input-with-suffix {
  display: flex;
  align-items: center;
  max-width: 400px;
}

#customPrefix {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  border-right: none;
  font-size: 14px;
  font-family: monospace;
}

#customPrefix:focus {
  outline: none;
  border-color: var(--primary-color);
}

.suffix {
  padding: 12px 16px;
  background: var(--background-color);
  border: 1px solid var(--border-color);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  font-family: monospace;
}

.input-help {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

.feature-comparison {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--border-light);
}

.feature-comparison h3 {
  margin-bottom: 16px;
  font-size: 18px;
  color: var(--text-primary);
}

.comparison-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.comparison-item {
  padding: 24px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  background: var(--background-color);
  position: relative;
  transition: var(--transition);
}

.comparison-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.comparison-item.featured {
  border: 2px solid var(--primary-color);
  transform: scale(1.02);
}

.badge {
  position: absolute;
  top: -10px;
  right: 20px;
  background: var(--primary-color);
  color: white;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.comparison-item h4 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.price {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary-color);
  margin: 10px 0;
}

.comparison-item ul {
  list-style: none;
  font-size: 14px;
  margin-bottom: 20px;
}

.comparison-item li {
  margin-bottom: 8px;
  color: var(--text-secondary);
}

/* 邮件转发设置 */
.forward-settings {
  background: var(--surface-color);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
}

.checkbox-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  font-weight: 500;
  color: var(--text-primary);
}

.checkbox-label input {
  margin-right: 8px;
}

.advanced-settings {
  margin-top: 24px;
  padding: 20px;
  background: rgba(24, 144, 255, 0.03);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.advanced-settings h4 {
  margin-bottom: 16px;
  color: var(--text-primary);
  font-size: 16px;
}

/* 设置模块 */
.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.setting-card {
  background: var(--surface-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
}

.setting-card h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.setting-content {
  font-size: 14px;
  color: var(--text-secondary);
}

.info-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-light);
}

.info-item:last-child {
  border-bottom: none;
}

.info-item label {
  font-weight: 500;
  color: var(--text-primary);
}

.info-item span {
  color: var(--text-secondary);
}

.email-address {
  font-family: monospace;
  background: var(--background-color);
  padding: 2px 6px;
  border-radius: var(--radius-sm);
}

.data-actions, .debug-actions, .security-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

/* 邮件容器 */
.email-container {
  background: var(--surface-color);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  overflow: hidden;
}

.empty-state {
  padding: 60px 40px;
  text-align: center;
  color: var(--text-muted);
}

.empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.empty-state h3 {
  font-size: 18px;
  margin-bottom: 8px;
  color: var(--text-secondary);
}

.empty-state p {
  font-size: 14px;
}

.hint {
  font-size: 12px !important;
  color: var(--text-muted) !important;
  margin-top: 8px !important;
  font-style: italic;
}

.email-item {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-light);
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.email-item:hover {
  background: rgba(24, 144, 255, 0.02);
}

.email-item:last-child {
  border-bottom: none;
}

.email-item.read {
  background: var(--background-color);
  opacity: 0.8;
}

.email-item.unread {
  background: var(--surface-color);
  border-left: 3px solid var(--primary-color);
}

.email-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.email-from {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 14px;
}

.email-time {
  color: var(--text-muted);
  font-size: 12px;
}

.email-subject {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
  font-size: 16px;
}

.email-preview {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* 系统管理样式 */
.admin-dashboard {
  background: var(--surface-color);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--background-color);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--border-light);
}

.stat-icon {
  font-size: 32px;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-color);
  color: white;
  border-radius: var(--radius-md);
}

.stat-info {
  flex: 1;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.stat-label {
  font-size: 14px;
  color: var(--text-muted);
}

.admin-actions {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.accounts-management {
  margin-top: 32px;
}

.accounts-management h3 {
  margin-bottom: 16px;
  font-size: 20px;
  color: var(--text-primary);
}

.table-container {
  background: var(--surface-color);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  overflow: hidden;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border-light);
}

th {
  background: var(--background-color);
  font-weight: 600;
  color: var(--text-primary);
  font-size: 14px;
}

td {
  font-size: 14px;
  color: var(--text-secondary);
}

tr:last-child td {
  border-bottom: none;
}

.role-badge {
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
}

.role-badge.user {
  background: rgba(24, 144, 255, 0.1);
  color: var(--primary-color);
}

.role-badge.protected {
  background: rgba(82, 196, 26, 0.1);
  color: var(--success-color);
}

.role-badge.admin {
  background: rgba(245, 34, 45, 0.1);
  color: var(--error-color);
}

/* 模态框 */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal-content {
  background: var(--surface-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}

.modal-content.large {
  max-width: 800px;
}

.modal-content.auth-modal {
  max-width: 400px;
}

.close {
  position: absolute;
  top: 16px;
  right: 20px;
  font-size: 24px;
  cursor: pointer;
  color: var(--text-muted);
  transition: var(--transition);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  z-index: 10;
}

.close:hover {
  color: var(--text-primary);
  background: var(--background-color);
}

/* 认证模态框样式 */
.auth-modal-header {
  text-align: center;
  padding: 32px 32px 0;
}

.auth-modal-header h2 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.auth-modal-header p {
  color: var(--text-secondary);
  font-size: 14px;
}

.auth-form {
  padding: 24px 32px 32px;
}

.auth-form .form-group {
  margin-bottom: 20px;
}

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 12px;
  font-size: 16px;
  color: var(--text-muted);
  z-index: 1;
}

.auth-form input {
  width: 100%;
  padding: 12px 16px 12px 40px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 14px;
  transition: var(--transition);
  background: var(--surface-color);
}

.auth-form input:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);
}

.auth-links {
  text-align: center;
  margin-top: 20px;
}

.auth-links a {
  color: var(--primary-color);
  text-decoration: none;
  font-size: 14px;
  transition: var(--transition);
}

.auth-links a:hover {
  text-decoration: underline;
}

/* 角色管理表单 */
.role-form {
  padding: 24px 32px 32px;
}

.form-select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 14px;
  background: var(--surface-color);
  color: var(--text-primary);
}

.form-select:focus {
  outline: none;
  border-color: var(--primary-color);
}

/* 邮件详情 */
.email-detail {
  padding: 32px;
}

.email-detail-content h2 {
  font-size: 24px;
  margin-bottom: 16px;
  color: var(--text-primary);
  padding: 0;
}

.email-meta {
  background: var(--background-color);
  padding: 16px;
  border-radius: var(--radius-md);
  margin-bottom: 20px;
}

.email-meta p {
  margin-bottom: 8px;
  font-size: 14px;
}

.email-meta p:last-child {
  margin-bottom: 0;
}

.email-body {
  background: var(--surface-color);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 20px;
  max-height: 400px;
  overflow-y: auto;
}

.email-body pre {
  white-space: pre-wrap;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-primary);
}

/* 管理员邮件显示样式 */
.email-account-info {
    margin-bottom: 8px;
}

.account-badge {
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    font-size: 11px;
    font-weight: 600;
    background: var(--background-color);
    border: 1px solid var(--border-color);
}

.account-badge.admin {
    background: rgba(245, 34, 45, 0.1);
    color: var(--error-color);
    border-color: rgba(245, 34, 45, 0.2);
}

.account-badge.user {
    background: rgba(24, 144, 255, 0.1);
    color: var(--primary-color);
    border-color: rgba(24, 144, 255, 0.2);
}

.account-badge.guest {
    background: rgba(108, 117, 125, 0.1);
    color: var(--secondary-color);
    border-color: rgba(108, 117, 125, 0.2);
}

.html-content {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-primary);
}

.html-content img {
  max-width: 100%;
  height: auto;
}

/* 消息提示 */
.message-toast {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  font-weight: 600;
  z-index: 1001;
  transform: translateX(400px);
  opacity: 0;
  transition: all 0.3s ease-in-out;
  max-width: 300px;
  box-shadow: var(--shadow-lg);
  font-size: 14px;
}

.message-toast.show {
  transform: translateX(0);
  opacity: 1;
}

.message-toast.success {
  background: var(--success-color);
  color: white;
}

.message-toast.error {
  background: var(--error-color);
  color: white;
}

.message-toast.warning {
  background: var(--warning-color);
  color: white;
}

/* 密码要求提示样式 */
.password-requirements {
    margin-top: 16px;
    padding: 12px;
    background: rgba(24, 144, 255, 0.05);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--primary-color);
}

.password-requirements small {
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.4;
}

/* 密码强度指示器 */
.password-strength {
    margin-top: 8px;
    height: 4px;
    border-radius: 2px;
    background: var(--border-light);
    overflow: hidden;
}

.password-strength-bar {
    height: 100%;
    width: 0%;
    transition: var(--transition);
}

.password-strength.weak .password-strength-bar {
    background: var(--error-color);
    width: 33%;
}

.password-strength.medium .password-strength-bar {
    background: var(--warning-color);
    width: 66%;
}

.password-strength.strong .password-strength-bar {
    background: var(--success-color);
    width: 100%;
}

.password-feedback {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .main-header {
    padding: 0 16px;
    flex-direction: column;
    height: auto;
    padding: 12px 16px;
    gap: 12px;
  }
  
  .header-left {
    flex-direction: column;
    gap: 12px;
    width: 100%;
  }
  
  .main-nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 4px;
  }
  
  .main-content {
    padding: 16px;
  }
  
  .auth-card {
    padding: 24px;
  }
  
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  
  .email-display {
    flex-direction: column;
  }
  
  .settings-grid {
    grid-template-columns: 1fr;
  }
  
  .comparison-grid {
    grid-template-columns: 1fr;
  }
  
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .data-actions,
  .debug-actions {
    flex-direction: column;
  }
  
  .module-actions {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .current-email-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  
  /* 响应式用户信息区域 */
  .user-info {
    justify-content: flex-end;
    width: 100%;
  }
  
  .user-info span {
    max-width: 150px;
  }
}

@media (max-width: 480px) {
  .auth-card {
    padding: 20px;
  }
  
  .module-header h1 {
    font-size: 24px;
  }
  
  .email-generator,
  .custom-email-form,
  .setting-card,
  .forward-settings,
  .admin-dashboard {
    padding: 20px;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .modal {
    padding: 10px;
  }
  
  .modal-content {
    margin: 10px;
  }
  
  .feature-item {
    min-height: 100px;
    padding: 10px 8px;
  }
  
  .feature-item .feature-icon {
    font-size: 22px;
  }
  
  .feature-item h3 {
    font-size: 13px;
  }
  
  .feature-item p {
    font-size: 11px;
  }
  
  table {
    font-size: 12px;
  }
  
  th, td {
    padding: 8px 12px;
  }
  
  /* 超小屏幕用户信息区域 */
  .user-info span {
    max-width: 120px;
    font-size: 12px;
  }
  
  .user-info {
    gap: 8px;
  }
  
  .btn.secondary {
    padding: 6px 12px;
    font-size: 12px;
  }
}