Gitlab@Informatics

Skip to content
Snippets Groups Projects
Commit 072f1ceb authored by 65160260's avatar 65160260
Browse files

Edit style.css

parent a5ad21e3
No related branches found
No related tags found
No related merge requests found
...@@ -14,7 +14,7 @@ body { ...@@ -14,7 +14,7 @@ body {
padding: 20px; padding: 20px;
box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1); box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
border-radius: 10px; border-radius: 10px;
text-align: center; /* ทำให้เนื้อหาใน container อยู่ตรงกลาง */ text-align: center;
} }
/* หัวข้อ */ /* หัวข้อ */
...@@ -25,8 +25,9 @@ h2 { ...@@ -25,8 +25,9 @@ h2 {
/* ตารางสินค้า */ /* ตารางสินค้า */
.table-container { .table-container {
width: 80%; /* จำกัดความกว้างของตาราง */ width: 80%;
margin: auto; /* จัดให้อยู่ตรงกลาง */ margin: auto;
overflow-x: auto; /* ป้องกันการล้นของตาราง */
} }
table { table {
...@@ -40,7 +41,7 @@ table, th, td { ...@@ -40,7 +41,7 @@ table, th, td {
} }
th, td { th, td {
padding: 10px; padding: 12px;
text-align: center; text-align: center;
} }
...@@ -49,37 +50,18 @@ th { ...@@ -49,37 +50,18 @@ th {
color: white; color: white;
} }
/* ฟอร์ม */ /* ปุ่มเพิ่ม-ลดจำนวนสินค้า */
form { .qty-btn {
text-align: center; padding: 5px 10px;
margin: 20px 0; background-color: #007BFF;
}
input, button {
padding: 10px;
margin: 5px;
border: 1px solid #ccc;
border-radius: 5px;
}
button {
background-color: #28a745;
color: white; color: white;
border: none;
cursor: pointer; cursor: pointer;
border-radius: 5px;
} }
button:hover { .qty-btn:hover {
background-color: #218838; background-color: #0056b3;
}
/* ลิงก์ */
a {
text-decoration: none;
color: #007BFF;
}
a:hover {
text-decoration: underline;
} }
/* ปุ่มลบ */ /* ปุ่มลบ */
...@@ -92,44 +74,22 @@ a:hover { ...@@ -92,44 +74,22 @@ a:hover {
color: darkred; color: darkred;
} }
/* ตะกร้าสินค้า */ /* ปุ่มชำระเงิน */
.cart-container { .checkout-container {
max-width: 600px; text-align: center;
margin: auto; margin-top: 20px;
}
.cart-container table {
width: 100%;
}
.cart-container th, .cart-container td {
padding: 10px;
}
/* ปุ่มเพิ่ม-ลดจำนวนสินค้า */
.qty-btn {
padding: 5px 10px;
background-color: #007BFF;
color: white;
border: none;
cursor: pointer;
border-radius: 5px;
}
.qty-btn:hover {
background-color: #0056b3;
} }
/* ปุ่มชำระเงิน */
.checkout-btn { .checkout-btn {
display: block; display: inline-block;
width: 100%; width: auto;
text-align: center;
background-color: #ffc107; background-color: #ffc107;
padding: 10px; padding: 12px 20px;
border-radius: 5px; border-radius: 5px;
font-size: 18px; font-size: 18px;
color: black; color: black;
font-weight: bold;
text-decoration: none;
} }
.checkout-btn:hover { .checkout-btn:hover {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment