Create style.css
Browse files- public/style.css +108 -0
public/style.css
ADDED
|
@@ -0,0 +1,108 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
|
| 2 |
+
body {
|
| 3 |
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
|
| 4 |
+
background-color: #f7f8fa; margin: 0; display: flex; flex-direction: column; height: 100vh; overflow: hidden;
|
| 5 |
+
}
|
| 6 |
+
|
| 7 |
+
header {
|
| 8 |
+
background: linear-gradient(135deg, #ff4757, #ff6b81);
|
| 9 |
+
color: white; padding: 15px; text-align: center; font-weight: bold;
|
| 10 |
+
font-size: 1.1rem; letter-spacing: 0.5px;
|
| 11 |
+
box-shadow: 0 2px 10px rgba(255, 71, 87, 0.3);
|
| 12 |
+
z-index: 10;
|
| 13 |
+
}
|
| 14 |
+
|
| 15 |
+
#chat-box {
|
| 16 |
+
flex: 1; overflow-y: auto; padding: 15px; display: flex;
|
| 17 |
+
flex-direction: column; gap: 12px; scroll-behavior: smooth;
|
| 18 |
+
background-image: radial-gradient(#e0e0e0 0.5px, transparent 0.5px);
|
| 19 |
+
background-size: 20px 20px;
|
| 20 |
+
}
|
| 21 |
+
|
| 22 |
+
/* Tin nhắn chung */
|
| 23 |
+
.msg {
|
| 24 |
+
max-width: 85%; padding: 12px 16px; border-radius: 18px;
|
| 25 |
+
font-size: 15px; line-height: 1.5; word-wrap: break-word;
|
| 26 |
+
position: relative; animation: fadeIn 0.3s ease;
|
| 27 |
+
}
|
| 28 |
+
@keyframes fadeIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
|
| 29 |
+
|
| 30 |
+
.user {
|
| 31 |
+
background: linear-gradient(135deg, #ff6b81, #ff4757);
|
| 32 |
+
color: white; align-self: flex-end; border-bottom-right-radius: 4px;
|
| 33 |
+
box-shadow: 0 3px 8px rgba(255, 71, 87, 0.2);
|
| 34 |
+
}
|
| 35 |
+
|
| 36 |
+
.bot {
|
| 37 |
+
background-color: white; color: #1c1e21; align-self: flex-start;
|
| 38 |
+
border-bottom-left-radius: 4px; box-shadow: 0 2px 5px rgba(0,0,0,0.05);
|
| 39 |
+
}
|
| 40 |
+
|
| 41 |
+
/* Hệ thống Nút bấm */
|
| 42 |
+
.btn-select, .btn-category {
|
| 43 |
+
display: inline-block; width: auto; min-width: 100px;
|
| 44 |
+
padding: 10px 18px; border-radius: 25px; margin: 6px 4px 2px 0;
|
| 45 |
+
cursor: pointer; font-weight: bold; font-size: 13px;
|
| 46 |
+
transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
|
| 47 |
+
text-align: center; border: none;
|
| 48 |
+
}
|
| 49 |
+
|
| 50 |
+
.btn-red { background: #ff4757; color: white; box-shadow: 0 3px 6px rgba(255, 71, 87, 0.2); }
|
| 51 |
+
.btn-green { background: #2ecc71; color: white; box-shadow: 0 3px 6px rgba(46, 204, 113, 0.2); }
|
| 52 |
+
|
| 53 |
+
/* Tìm class này trong code CSS của Đạt nhen */
|
| 54 |
+
.btn-category {
|
| 55 |
+
display: inline-block;
|
| 56 |
+
padding: 2px 10px; /* Giảm padding (trên-dưới 2px, trái-phải 10px) */
|
| 57 |
+
min-width: 40px; /* Giảm độ rộng tối thiểu xuống */
|
| 58 |
+
height: 28px; /* Cố định chiều cao cho nút tròn đều */
|
| 59 |
+
line-height: 24px; /* Căn giữa chữ theo chiều dọc */
|
| 60 |
+
border-radius: 15px; /* Giữ độ bo tròn */
|
| 61 |
+
text-align: center;
|
| 62 |
+
font-size: 13px; /* Chỉnh cỡ chữ vừa phải */
|
| 63 |
+
margin: 3px; /* Khoảng cách giữa các nút */
|
| 64 |
+
border: 1px solid #ff4757; /* Màu viền đỏ của Đạt */
|
| 65 |
+
background: white;
|
| 66 |
+
color: #ff4757;
|
| 67 |
+
cursor: pointer;
|
| 68 |
+
}
|
| 69 |
+
|
| 70 |
+
/* Thêm hiệu ứng khi di chuột vào cho chuyên nghiệp */
|
| 71 |
+
.btn-category:hover {
|
| 72 |
+
background: #ff4757;
|
| 73 |
+
color: white;
|
| 74 |
+
}
|
| 75 |
+
|
| 76 |
+
.btn-select:active, .btn-category:active { transform: scale(0.92); opacity: 0.9; }
|
| 77 |
+
|
| 78 |
+
/* Khu vực nhập liệu */
|
| 79 |
+
#input-area {
|
| 80 |
+
background: white; padding: 12px 15px; display: flex;
|
| 81 |
+
align-items: center; gap: 10px; border-top: 1px solid #eee;
|
| 82 |
+
padding-bottom: env(safe-area-inset-bottom);
|
| 83 |
+
}
|
| 84 |
+
|
| 85 |
+
input {
|
| 86 |
+
flex: 1; height: 45px; border: 1px solid #f1f2f6; background: #f8f9fa;
|
| 87 |
+
border-radius: 22px; padding: 0 20px; font-size: 16px; outline: none;
|
| 88 |
+
transition: all 0.3s;
|
| 89 |
+
}
|
| 90 |
+
input:focus { border-color: #ff4757; background: #fff; box-shadow: 0 0 0 3px rgba(255, 71, 87, 0.1); }
|
| 91 |
+
|
| 92 |
+
button#send-btn {
|
| 93 |
+
background: #ff4757; color: white; border: none;
|
| 94 |
+
width: 45px; height: 45px; border-radius: 50%; cursor: pointer;
|
| 95 |
+
display: flex; align-items: center; justify-content: center;
|
| 96 |
+
transition: 0.3s;
|
| 97 |
+
}
|
| 98 |
+
button#send-btn:hover { transform: scale(1.05) rotate(-5deg); }
|
| 99 |
+
|
| 100 |
+
/* Hiệu ứng đang gõ */
|
| 101 |
+
.typing { font-style: italic; color: #999; font-size: 13px; padding-left: 5px; }
|
| 102 |
+
|
| 103 |
+
/* Form chốt đơn */
|
| 104 |
+
.msg-form {
|
| 105 |
+
background: #fff; border: 2px solid #ff4757; padding: 15px;
|
| 106 |
+
border-radius: 15px; margin: 10px 0; clear: both;
|
| 107 |
+
}
|
| 108 |
+
.msg-form input { margin-bottom: 8px; border: 1px solid #ddd; }
|