body {
    font-family: "STHeiti", "Helvetica", "sans-serif";
    margin: 0; /* Remove default margin */
    padding-top: 50px; /* Space for the fixed top bar */
	height: 100%;
 }
 
button {
    white-space: nowrap; /* Prevents text from wrapping to the next line */
	cursor: pointer;
}

td img {
    vertical-align: middle; /* Ensures proper vertical alignment */
    display: inline-block; /* Better control over inline elements */
    margin: 0; /* Removes any default margins */
    padding: 0; /* Removes any default padding */
}

textarea {
    resize: none; 
}

/* Flexbox 布局控制 */
.page-container {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 50px); /* Subtract top bar height */
	
}

.main-content {
    flex: 1; /* 自动扩展剩余空间，推动 bottombar 到底部 */
	padding-top: 10px;
}

.content {
	width:100%;
	min-width: 1000px;
	max-width: 1300px;
}

#topbar {
    background-color: #81D8D0;
    height: 50px;
    width: 100%;
    position: fixed; /* Fixes the top bar */
    top: 0; /* Position it at the top */
    left: 0; /* Align to the left */
    z-index: 1000; /* Ensure it stays above other content */
}

#topbar table {
    max-width: 1300px; /* Maximum width for the table */
    /* Optional styling */
    width: auto; /* Adjust as necessary, can be left out if min/max are set */
    height: 50px; /* Match the height of the top bar */
    table-layout: fixed; /* Optional: To maintain consistent column widths */
}

#categorylist {
    font-size: 13px;
    width: 100%;
    background-color: white; /* Background color to avoid transparency */
}

.categoryspacer {
    width: 20px;
}

.category {
    font-size: 14px;
    position: relative; /* Needed for the pseudo-element */
    padding: 5px 0; /* Add some padding for spacing */
	transition: font-weight 0.3s ease; /* Smooth transition for font weight */
}
		
.category:hover {
	font-weight: bold; /* Make font bold on hover */
}

.category:hover::after {
    content: ''; /* Required for pseudo-element */
    display: block;
    width: 100%;
    height: 3px; /* Height of the bottom line */
    background-color: #81D8D0; /* Color of the bottom line */
    position: absolute;
    bottom: -3px; /* Position it below the text */
    left: 0;
}

.productlistimagebase {
    width: 20%; /* Each image occupies one-fourth of the row */
    padding: 5px; /* Add some padding around images */
    position: relative; /* Needed for the overlay */
    box-sizing: border-box; /* Ensure padding is included in width */
    overflow: hidden; /* Clip the overlay to the image boundaries */
	
}

.productlistimage {
   height:250px; background-position: center; background-repeat: no-repeat; background-size: cover;
   border-top-left-radius: 5px;
   border-top-right-radius: 5px;
   position: relative;
}

/* Overlay styling */
.overlay {
    color: #fff;
    position: absolute;
    bottom: 0px;
    left: 0px; /* Left margin */
    width: 100%; /* Full width minus left and right margins */
    height: 50px; /* Fixed height for the overlay */
    background-color: rgba(21, 168, 181, 0.95);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0; /* Start hidden */
    transition: opacity 0.3s ease; /* Smooth transition */
   
}

.productlistimagebase:hover .overlay {
    opacity: 1; /* Show overlay on hover */
}

/* Ensures the product list takes the full width of the container */
#productlist {
    margin: 0 auto; /* Center the table */
	font-size:13px;
}

.productlisttext {
    font-size: 14px;
    color: #666;
	background-color: #f7f7f7;
	padding: 5px;
	height: 30px !important;
	display: block;
}

.productlink a {
    color: #666;
}


a {
    text-decoration: none; /* Remove underline by default */
	color: black;
}

a:hover {
    text-decoration: underline; /* Add underline on hover */
}

.productlistprice {
    font-size: 18px;
    font-weight: bold;
	background-color: #f7f7f7;
	border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
	padding: 5px;
}

.crossprice{
	text-decoration: line-through; /* Apply strikethrough */
	font-size:12px;
	font-weight: normal;
}

.discountprice {
	color: #f53e3d !important;
}
		
#selectedcategory {
	font-size:14px;
	color: #666;
}
		
#productincart {
    background-color: #fa7070;
    color: #fff;
    font-size: 12px;
    border-radius: 50%;
    width: 25px;
    height: 25px;
    display: flex; /* Use flexbox */
    justify-content: center; /* Center horizontally */
    align-items: center; /* Center vertically */
    position: absolute;
    left: -25px;
    top: 10px;
    transition: background-color 0.3s, transform 0.3s; /* Add transition */
}
		
.clickable {
	cursor: pointer;
}

#largeimage{
	width: 500px;
	padding: 5px;
	border-radius: 10px;
}
		
#productimage{
	width: 500px;
}
		
#product{
	width:100%;
	min-width: 1000px;
	max-width: 1300px;
}
		
.productname
{
	font-weight:bold;font-size:18px;
	color: #02123f;
}

.productID
{
	font-size:14px;
}
		
.productprice
{
	font-weight:bold;font-size:18px;
}
		
.productdescription
{
	font-size:15px;
	color:#4f4f4f;
}		
		
.addtocartbtn
{
	width:400px;
	height:40px;
	background-color: #fa7070;
	border: none; /* Remove default border */
	outline: none; /* Remove outline on focus */
	color: white;
	border-radius: 25px;
	transition: background-color 0.3s ease;		
}
		
.addtocartbtn:hover
{
	background-color: #fd5a5a;
}

.nextstep
{
	height:40px;
	background-color: #fa7070;
	border: none; /* Remove default border */
	outline: none; /* Remove outline on focus */
	color: white !important;
	border-radius: 25px;
	transition: background-color 0.3s ease;	
	padding-left: 20px;
	padding-right: 20px;
	width: 100px !important;
}

.nextstep:hover
{
	background-color: #fd5a5a;
}
		
.cartquantity
{
	font-size:15px;
}

	
.editquantity
{
	background-color:#e2e1e1;
	font-weight:bold;
	transition: background-color 0.3s ease;
	user-select: none;
	border-radius: 5px;
}
		
.editquantity:hover
{
	background-color:#999;
}
		
#displayquantity
{
	background-color:#e2e1e1;
}

/* Pagination styles */
.pagination {
	margin: 2px 0;
	text-align: right;
}

.page-btn {
	padding: 8px 12px;
	margin: 0 5px;
	border: 1px solid #ddd;
	background: #999;
	cursor: pointer;
	color: white;
	border-radius: 4px;
}

.page-btn.active {
	background: #f27372;
	color: white;
	border-color: #f27372;
}

.page-btn:hover:not(.active) {
	background: #f53e3d;
	border-color: #f53e3d;
}

.page-btn.disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

.page-info {
	text-align: center;
	margin: 10px 0;
	color: #666;
}

.photolist{
	border-radius: 5px;
}

.line {
    height: 1px;          /* Set height to 1 pixel */
    width: 100%;          /* Set width as needed (100% for full width) */
    background-color: #CCC; /* Change color as desired */
    margin: 10px 0;      /* Optional: Add vertical spacing */
}

.cart{
	width: 100%;
	max-width: 1300px;
	font-size:14px;
	padding:10px;
	color: #666;
}

.cart img{
	width:80px;
	border-radius: 5px;
}

.cart .productname{
	font-size: 14px;
	color: black;
}

.cart .PID{
	color: #666;
	font-size:12px;
}

.cart .sum{
	color: black;
}

.cart .sumPrice{
	font-weight:bold;
	color: black;
	font-size:18px;
}

.hiddensection{
	width: 100%;
	max-width: 1300px;
	font-size:14px;
	padding:10px;
	color: #666;
}

.formtable 
{
	padding:10px;
	width: 100%;
	max-width: 1300px;
	font-size:14px;
	color: #666;
}

.formtable .fieldtext
{
	padding-right:50px;
	padding-bottom:10px;
}

.formtable .header
{
	color:black;
	font-weight: bold;
}

.formtable input {
	padding: 5px;
	color: #666;
    width: 300px;
}

.formtable textarea {
	padding: 5px;
	color: #666;
    width: 300px;
    height: 50px;
}

.tips {
	padding: 5px;
	background-color: #ffffe6;
	border: 1px solid #ccc;
	font-size: 13px;
	width: 90%;
	max-width: 1300px;
	color: #666;
}

.tips  a {
    text-decoration: none; /* Remove underline by default */
}

.tips a:hover {
    text-decoration: underline; /* Add underline on hover */
}


.addToCartNotice {
	position: fixed;
    top: 100px;
	right: 0;
    transform: translateX(100%);
    height: 70px;
	width: 250px;
    background-color: #fa7070;
	z-index: 500;
	transition: transform 0.3s ease;	
	border-radius: 5px;
}
		
.addToCartNoticetable {
	color: #fff;
	font-size: 13px;
}
		
.addToCartNotice.open {
    transform: translateX(-20px);
}

.removecartbtn
{
	background-color: #999;
	border: none; /* Remove default border */
	outline: none; /* Remove outline on focus */
	color: white;
	border-radius: 25px;
	transition: background-color 0.3s ease;		
	padding-left: 10px;
	padding-right: 10px;
	cursor: pointer;
	
}
		
.removecartbtn:hover
{
	background-color: #666;
}

/*image slider style*/
.slider {
    position: relative;
    width: 100%;
    height: 500px; /* 固定高度 */
    overflow: hidden;
}

.slide {
    min-width: 100%;
    box-sizing: border-box;
    height: 500px; /* 固定高度 */
}

.slide-image-container {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    background-color: #f5f5f5; /* 背景色填充空白 */
}

.slide-image {
    width: 100%;
    height: 100%;
    object-fit: cover; /* 使用 cover 來填充容器，保持比例 */
    object-position: center; /* 圖片居中 */
}

.slides {
    display: flex;
    transition: transform 0.5s ease;
    height: 100%;
}

.product-image-container {
    width: 100px;
    height: 100px; /* 縮圖固定高度 */
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #f5f5f5;
    border-radius: 5px;
}

.product-image {
   width: 100% !important; 
   height: 100% !important;
   object-fit: cover !important;
   object-position: center !important;
}

.thumbnail-container {
    width: 100%;
    height: 120px; /* 縮圖固定高度 */
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #f5f5f5;
    border-radius: 5px;
}

.thumbnail-image {
    width: 100%;
    height: 100%;
    object-fit: cover; /* 使用 cover 來填充容器 */
    object-position: center; /* 圖片居中 */
    transition: transform 0.3s ease;
}

.thumbnail-image:hover {
    transform: scale(1.05); /* 滑鼠懸停輕微放大 */
}

.photolist {
    border-radius: 5px;
    cursor: pointer;
}

.modal-open {
	overflow: hidden;
}

.modal {
	display: none;
	position: fixed;
	z-index: 1000;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	overflow: hidden; 
	background-color: rgba(0, 0, 0, 0.9);
}

.modal-content {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	height: 100%;
	width: 100%;
	position: relative;
}

.full-slider {
	position: relative;
	width: 100%;
	max-width: 90vw;
	height: 90vh;
	display: flex;
	align-items: center;
	justify-content: center;
}

.full-slides {
	display: flex;
	height: 100%;
	transition: transform 0.5s ease;
}

.full-slide {
	flex: 0 0 100%;
	display: flex;
	justify-content: center;
	align-items: center;
	height: 100%;
}

.full-slide img {
    max-height: 90vh;
    max-width: 90vw;
    object-fit: contain; /* 全屏時使用 contain 顯示完整圖片 */
    object-position: center;
}


.close {
	position: absolute;
	top: 20px;
	right: 35px;
	color: white;
	font-size: 35px;
	font-weight: bold;
	cursor: pointer;
	z-index: 1001;
}
	
.arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255, 255, 255, 0.8);
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    z-index: 10;
    font-size: 18px;
	color: #999;
}

.left-arrow {
    left: 10px;
}
        
.right-arrow {
    right: 10px;
}

.selected {
    outline: 2px solid #81D8D0;
    box-shadow: 0 0 5px rgba(129, 216, 208, 0.5);
}
	
#paymentfinish{
	padding: 10px;
	font-size:14px;
	padding-top:20px;
}

#paymentfinish .largeTitle
{
	font-size:24px;
	padding-bottom:20px;
}

#paymentfinish .refnum
{
	background-color: #f9f8bc;
	padding: 10px;
}

.emptyCart
{
	height:60px;
	font-size: 20px;
}

.relatedproduct
{
	padding-top: 30px;
	color: black;
	font-weight:bold;
	font-size: 16px;
}

#bottombar
{
	width: 100%;
	font-size:14px;
	color: #fff;
	height:80px;
	background-color: #c9c9c9;
}

#bottombar a
{
	color: #fff;
}

.terms
{
	font-size:14px;
	color: #666;
}

.termsheader
{
	font-size:16px;
	font-weight:bold;
}

.tracetextbox, .tracebtn {
    height: 30px; /* Set the same height */
    line-height: 30px; /* Center text vertically */
    padding: 0; /* Remove any default padding */
    margin: 0; /* Remove any default margin */
    box-sizing: border-box; /* Include padding and border in element's total width and height */
    font-size: 14px; /* Ensure consistent font size */
}

.tracebtn {
	cursor: pointer;
	width: 50px;
	font-size: 12px;
	background-color: #d8d6d6;
	border: none; /* Remove default border */
	outline: none; /* Remove outline on focus */
	transition: background-color 0.3s ease;	
}
	
.tracebtn:hover
{
	background-color: #ccc;
}

#currency
{
	cursor: pointer;
    color: #FFF;
    /* Remove borders and outline */
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
	background-color: #81D8D0; !important; /* Bootstrap green */
}