adamtobegreat commited on
Commit
063db2e
·
verified ·
1 Parent(s): 6d8dea9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +22 -14
app.py CHANGED
@@ -126,13 +126,24 @@ with gr.Blocks(
126
  }
127
 
128
  /* ====== 標題與副標題 ====== */
129
- #main-title {
 
 
 
 
 
130
  text-align: center;
131
- margin: 0 auto;
 
 
 
 
 
 
132
  }
 
133
  #sub-title {
134
- text-align: center;
135
- margin-top: -10px;
136
  font-size: 14px;
137
  color: #666;
138
  letter-spacing: 0.5px;
@@ -151,7 +162,7 @@ with gr.Blocks(
151
  letter-spacing: 0.3px;
152
  }
153
 
154
- /* ====== 手機版(窄螢幕)時 logo 與標題自適應 ====== */
155
  @media (max-width: 768px) {
156
  #logo-top {
157
  position: static;
@@ -168,7 +179,6 @@ with gr.Blocks(
168
  }
169
  """
170
  ) as demo:
171
- # logo 顯示
172
  if logo_base64:
173
  gr.HTML(f"""
174
  <div id="logo-top">
@@ -176,17 +186,15 @@ with gr.Blocks(
176
  </div>
177
  """)
178
 
179
- # 主標題 + 副標題
180
- gr.Markdown("""
181
- <h1 id='main-title'>👨‍💼 我是小智,您的金融好幫手 🫰</h1>
182
- <p id='sub-title'>Powered by Gemini & LangChain</p>
 
183
  """)
184
 
185
- # 你的主要內容(Chatbot、按鈕...)放這裡
186
- # ...
187
-
188
  # 底部版權列
189
- gr.HTML("<div id='footer'>© Fintech Assistant — 僅方便業務,非官方授權</div>")
190
 
191
 
192
  with gr.Row():
 
126
  }
127
 
128
  /* ====== 標題與副標題 ====== */
129
+ #main-title-wrapper {
130
+ display: flex;
131
+ flex-direction: column;
132
+ align-items: center; /* 水平置中 */
133
+ justify-content: center; /* 垂直置中(若需要) */
134
+ width: 100%;
135
  text-align: center;
136
+ margin-top: 20px;
137
+ }
138
+
139
+ #main-title {
140
+ font-size: 28px;
141
+ font-weight: bold;
142
+ margin: 0;
143
  }
144
+
145
  #sub-title {
146
+ margin-top: -6px;
 
147
  font-size: 14px;
148
  color: #666;
149
  letter-spacing: 0.5px;
 
162
  letter-spacing: 0.3px;
163
  }
164
 
165
+ /* ====== 手機版自適應 ====== */
166
  @media (max-width: 768px) {
167
  #logo-top {
168
  position: static;
 
179
  }
180
  """
181
  ) as demo:
 
182
  if logo_base64:
183
  gr.HTML(f"""
184
  <div id="logo-top">
 
186
  </div>
187
  """)
188
 
189
+ gr.HTML("""
190
+ <div id="main-title-wrapper">
191
+ <h1 id='main-title'>👨‍💼 我是小智,您的金融好幫手 🫰</h1>
192
+ <p id='sub-title'>Powered by Gemini & LangChain</p>
193
+ </div>
194
  """)
195
 
 
 
 
196
  # 底部版權列
197
+ gr.HTML("<div id='footer'>© Fintech Assistant — 僅方便業務使用,非官方授權</div>")
198
 
199
 
200
  with gr.Row():