diff --git a/public/static/css/chatbot.css b/public/static/css/chatbot.css index 7495fd9..cfa56e3 100644 --- a/public/static/css/chatbot.css +++ b/public/static/css/chatbot.css @@ -207,7 +207,7 @@ } /* Responsive styles */ -@media (max-width: 768px) { +@media (max-width: 768px) { #chat-window { right: 16px; bottom: 140px; @@ -216,5 +216,69 @@ .chat-icon-container { right: 16px; bottom: 78px; - } + } +} + +@media (max-width: 576px) { + #chat-window { + right: 16px; + bottom: calc(128px + env(safe-area-inset-bottom, 0px)); + width: min(330px, calc(100vw - 48px)); + height: min(440px, 62dvh); + border-radius: 14px; + } + + .chat-icon-container { + right: 16px; + bottom: calc(70px + env(safe-area-inset-bottom, 0px)); + } + + #chat-icon { + width: 46px; + height: 46px; + } + + #chat-icon i { + font-size: 21px; + } + + .chat-header { + padding: 11px 12px; + } + + .chat-header h3 { + font-size: 15px; + } + + #chat-messages { + padding: 10px; + gap: 8px; + } + + .message { + margin-bottom: 6px; + } + + .message-bubble { + max-width: 88%; + padding: 8px 10px; + font-size: 13px; + } + + .chat-input { + padding: 10px; + } + + #user-message { + min-width: 0; + padding: 8px 11px; + font-size: 13px; + } + + #send-message { + width: 36px; + height: 36px; + margin-left: 8px; + flex: 0 0 36px; + } } diff --git a/templates/base.html b/templates/base.html index e25f069..4437ead 100644 --- a/templates/base.html +++ b/templates/base.html @@ -10,7 +10,7 @@ - + {% block extra_css %}{% endblock %} @@ -184,7 +184,7 @@

Statistical assistant

- + - + diff --git a/tests/test_main_routes.py b/tests/test_main_routes.py index 56f9a0b..68d4798 100644 --- a/tests/test_main_routes.py +++ b/tests/test_main_routes.py @@ -11,8 +11,8 @@ def test_home_page(self, client): response = client.get('/') assert response.status_code == 200 assert b'statistical' in response.data.lower() or b'model' in response.data.lower() - assert b'chatbot.js?v=20260725.1' in response.data - assert b'chatbot.css?v=20260725.1' in response.data + assert b'chatbot.js?v=20260725.2' in response.data + assert b'chatbot.css?v=20260725.2' in response.data def test_analysis_form_page(self, client): """Test that the analysis form page loads.""" response = client.get('/analysis-form')