body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background-color: #f5f7fa; display: flex; flex-direction: column; /* 垂直排列 */ justify-content: center; /* 整体垂直居中 */ align-items: center; /* 整体水平居中 */ min-height: 100vh; /* 确保垂直居中生效 */ margin: 0; }
.container { background: white; padding: 30px; border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); width: 100%; max-width: 500px; text-align: center; }
.hidden { display: none !important; }
.header { display: flex; flex-direction: column; gap: 15px; }

/* 品牌名称与鼓励语样式 (移出卡片，悬浮在背景顶部) */
.app-branding { text-align: center; margin-top: 50px; /* 把产品名拉下一点，防止太靠上 */ margin-bottom: 40px; /* 和下面的白色大卡片拉开明显的缝隙 */ max-width: 500px; /* 和主卡片保持大致宽度 */ }
.app-title { font-size: 36px; color: #4CAF50; margin: 0 0 15px 0; line-height: 1.2; letter-spacing: 2px; }
.app-subtitle { font-size: 20px; color: #888; font-weight: normal; letter-spacing: 1px; }
/* 【核心修改区】升级为有格调的护眼引用框 */
.app-quote { color: #555; /* 稍微深一点的文本颜色 */ font-size: 14px; background-color: #f1f8e9; /* 浅灰绿色背景，更护眼 */ padding: 20px; /* 增大内边距 */ border-radius: 8px; /* 圆角 */ border-left: 4px solid #8bc34a; /* 护眼绿边框保持 */ margin: 20px auto; /* 居中，上下加点间距 */ max-width: 90%; /* 保持内容包裹 */ text-align: left; /* 文字靠左，和边框对齐 */ box-shadow: 0 2px 5px rgba(0,0,0,0.05); /* 增加一点点阴影，更像一个框 */ }
.app-quote p { margin: 5px 0; font-style: italic; /* 斜体 */ }

select, input { font-size: 16px; padding: 10px; border-radius: 8px; border: 1px solid #ccc; outline: none;}
button { font-size: 16px; padding: 10px 15px; border-radius: 8px; border: none; cursor: pointer; transition: 0.2s; }
button:hover { opacity: 0.9; }

.primary-btn { background-color: #4CAF50; color: white; width: 100%; font-weight: bold;}
.secondary-btn { background-color: #ff9800; color: white; width: 100%;}
.text-btn { background: none; color: #666; font-size: 14px; text-decoration: underline; padding: 0;}
.action-btn { background-color: #e0e0e0; color: #333; margin: 5px; font-size: 14px;}
.icon-btn { font-size: 30px; background: none; margin-bottom: 10px; padding: 0;}
.mt-20 { margin-top: 20px; padding: 15px; font-size: 18px;}

/* 首页模式切换按钮间距优化 */
.mode-toggles { display: flex; flex-direction: column; gap: 15px; margin-top: 5px; }

.top-controls { display: flex; justify-content: space-between; margin-bottom: 20px; font-size: 14px; color: #888; }
.meaning-text { font-size: 18px; color: #444; margin-bottom: 20px; font-weight: 500;}
.large-word { font-size: 44px; font-weight: bold; color: #222; margin-bottom: 10px; letter-spacing: 2px; text-transform: lowercase;}

#spell-input { width: 85%; font-size: 24px; text-align: center; border: 2px solid #ddd; margin-bottom: 15px;}
#spell-input:focus { border-color: #4CAF50; }

#letter-bubbles { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 20px; min-height: 40px; }
.bubble { background-color: #e3f2fd; color: #1976d2; border: 2px solid #bbdefb; border-radius: 50%; width: 40px; height: 40px; font-size: 20px; font-weight: bold; display: flex; justify-content: center; align-items: center; cursor: pointer; user-select: none; box-shadow: 0 2px 4px rgba(0,0,0,0.1); }
.bubble:active { transform: scale(0.9); background-color: #bbdefb; }

.error-shake { animation: shake 0.5s; border-color: #f44336 !important; }
@keyframes shake { 0%, 100% { transform: translateX(0); } 25%, 75% { transform: translateX(-5px); } 50% { transform: translateX(5px); } }
#feedback-msg { margin-top: 10px; font-weight: bold; min-height: 24px;}

/* 登录注册相关样式 */
#auth-space input { width: 80%; margin-bottom: 15px; text-align: center;}
.auth-buttons { display: flex; gap: 10px; justify-content: center; margin-top: 10px;}
#auth-msg { margin-top: 15px; font-size: 14px; color: #f44336; min-height: 20px;}

/* 用户信息栏样式 (内嵌顶部) */
#user-bar { display: flex; justify-content: space-between; align-items: center; background-color: #f8f9fa; padding: 12px 20px; border-radius: 8px; margin-bottom: 25px; font-size: 14px; color: #333; font-weight: bold; border: 1px solid #eee; }
#user-bar.hidden { display: none !important; }
#user-bar div { display: flex; align-items: center; }
#learned-count { color: #4CAF50; font-size: 16px; margin-left: 5px;}
#logout-btn { color: #f44336; margin: 0; padding: 5px 10px; font-size: 14px; text-decoration: none; }
#logout-btn:hover { background-color: #ffebee; border-radius: 4px; }