blob: 820c596075c9ea999cfe67eced19ef8b04cd5840 [file] [log] [blame]
2130105001e07a12025-06-09 18:00:40 +08001/* AuthStyle.css - 仅针对auth页面的样式,不影响其他页面 */
2
3/* 限定在.auth-wrapper内的样式才会生效 */
4.auth-wrapper {
5 /* 基础样式 */
6 --primary-color: #f9952f;
7 --primary-hover: #e08527;
8 --white: #ffffff;
9 --light-gray: #f5f5f5;
10 --dark-gray: #333333;
11 --error-color: #ff4d4f;
12
13 font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
14
15 /* 页面背景(仅影响.auth-wrapper内部) */
16 background-color: var(--light-gray);
17 background-image: linear-gradient(135deg, var(--primary-color) 0%, #f9c22f 100%);
18 background-size: 400% 400%;
19 min-height: 100vh;
20 display: flex;
21 justify-content: center;
22 align-items: center;
23 padding: 2rem;
24 animation: gradientBG 15s ease infinite;
25}
26
27@keyframes gradientBG {
28 0% { background-position: 0% 50%; }
29 50% { background-position: 100% 50%; }
30 100% { background-position: 0% 50%; }
31}
32
33/* 容器样式 */
34.auth-wrapper .auth-container {
35 width: 100%;
36 max-width: 500px;
37 animation: fadeIn 0.5s ease;
38}
39
40@keyframes fadeIn {
41 from { opacity: 0; transform: translateY(20px); }
42 to { opacity: 1; transform: translateY(0); }
43}
44
45.auth-wrapper .auth-header {
46 text-align: center;
47 margin-bottom: 2rem;
48 color: var(--white);
49}
50
51.auth-wrapper .auth-header h1 {
52 font-size: 2.5rem;
53 margin-bottom: 0.5rem;
54 text-shadow: 0 2px 4px rgba(0,0,0,0.1);
55}
56
57.auth-wrapper .auth-header p {
58 font-size: 1rem;
59 opacity: 0.9;
60}
61
62/* 卡片样式 */
63.auth-wrapper .auth-card {
64 background-color: var(--white);
65 border-radius: 10px;
66 box-shadow: 0 10px 30px rgba(0,0,0,0.1);
67 padding: 2rem;
68 transition: all 0.3s ease;
69}
70
71.auth-wrapper .auth-card:hover {
72 box-shadow: 0 15px 35px rgba(0,0,0,0.15);
73}
74
75/* 标签页样式 */
76.auth-wrapper .tabs {
77 display: flex;
78 position: relative;
79 margin-bottom: 2rem;
80 border-bottom: 1px solid #eee;
81}
82
83.auth-wrapper .tab-btn {
84 flex: 1;
85 padding: 0.75rem;
86 text-align: center;
87 background: none;
88 border: none;
89 font-size: 1rem;
90 font-weight: 600;
91 color: var(--dark-gray);
92 cursor: pointer;
93 transition: all 0.3s ease;
94 position: relative;
95}
96
97.auth-wrapper .tab-btn.active {
98 color: var(--primary-color);
99}
100
101.auth-wrapper .tab-indicator {
102 position: absolute;
103 bottom: -1px;
104 left: 0;
105 height: 3px;
106 width: 50%;
107 background-color: var(--primary-color);
108 transition: all 0.3s ease;
109}
110
111/* 表单样式 */
112.auth-wrapper .auth-form {
113 display: flex;
114 flex-direction: column;
115 gap: 1.5rem;
116}
117
118.auth-wrapper .form-group {
119 position: relative;
120}
121
122.auth-wrapper .form-group input {
123 width: 100%;
124 padding: 1rem;
125 border: 1px solid #ddd;
126 border-radius: 5px;
127 font-size: 1rem;
128 transition: all 0.3s ease;
129}
130
131.auth-wrapper .form-group input:focus {
132 border-color: var(--primary-color);
133 box-shadow: 0 0 0 2px rgba(249, 149, 47, 0.2);
134 outline: none;
135}
136
137.auth-wrapper .form-group.with-button {
138 display: flex;
139 gap: 0.5rem;
140}
141
142.auth-wrapper .form-group.with-button input {
143 flex: 1;
144}
145
146/* 按钮样式 */
147.auth-wrapper .submit-btn {
148 background-color: var(--primary-color);
149 color: white;
150 border: none;
151 padding: 1rem;
152 border-radius: 5px;
153 font-size: 1rem;
154 font-weight: 600;
155 cursor: pointer;
156 transition: all 0.3s ease;
157 height: 50px;
158 display: flex;
159 justify-content: center;
160 align-items: center;
161}
162
163.auth-wrapper .submit-btn:hover {
164 background-color: var(--primary-hover);
165 transform: translateY(-2px);
166}
167
168.auth-wrapper .submit-btn:active {
169 transform: translateY(0);
170}
171
172.auth-wrapper .code-btn {
173 background-color: var(--light-gray);
174 color: var(--dark-gray);
175 border: none;
176 padding: 0 1rem;
177 border-radius: 5px;
178 font-size: 0.9rem;
179 cursor: pointer;
180 transition: all 0.3s ease;
181 white-space: nowrap;
182}
183
184.auth-wrapper .code-btn:hover:not(:disabled) {
185 background-color: #e0e0e0;
186}
187
188.auth-wrapper .code-btn:disabled {
189 cursor: not-allowed;
190 opacity: 0.7;
191}
192
193/* 消息样式 */
194.auth-wrapper .message {
195 padding: 0.75rem 1rem;
196 border-radius: 5px;
197 margin-bottom: 1.5rem;
198 text-align: center;
199 transition: all 0.3s ease;
200}
201
202.auth-wrapper .message.error {
203 background-color: #fff2f0;
204 border: 1px solid var(--error-color);
205 color: var(--error-color);
206}
207
208/* 加载动画 */
209.auth-wrapper .spinner {
210 width: 20px;
211 height: 20px;
212 border: 3px solid rgba(255,255,255,0.3);
213 border-radius: 50%;
214 border-top-color: var(--white);
215 animation: spin 1s ease-in-out infinite;
216}
217
218@keyframes spin {
219 to { transform: rotate(360deg); }
220}
221
222/* 页脚样式 */
223.auth-wrapper .auth-footer {
224 text-align: center;
225 margin-top: 2rem;
226 color: var(--white);
227 font-size: 0.9rem;
228 opacity: 0.8;
229}
230
231/* 响应式设计 */
232@media (max-width: 600px) {
233 .auth-wrapper {
234 padding: 1rem;
235 }
236
237 .auth-wrapper .auth-card {
238 padding: 1.5rem;
239 }
240}