@charset "UTF-8";

.car {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
	font-family: 'Arial', sans-serif;
}

.product-container {
	max-width: 1000px;
	margin: 0 auto;
	background: white;
	padding: 2rem;
	border-radius: 8px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
	display: flex;
	gap: 2rem;
	align-items: center;
}

.product-img {
	width: 300px;
	height: 300px;
	object-fit: cover;
	border-radius: 8px;
}

.product-info {
	flex: 1;
}

.product-name {
	font-size: 2rem;
	color: #333;
	margin-bottom: 1rem;
}

.product-desc {
	color: #666;
	line-height: 1.6;
	margin-bottom: 1.5rem;
}

.product-price {
	font-size: 1.8rem;
	color: #e63946;
	font-weight: bold;
	margin-bottom: 1.5rem;
}

.buy-btn {
	padding: 1rem 2.5rem;
	background: #e63946;
	color: white;
	border: none;
	border-radius: 6px;
	font-size: 1.1rem;
	cursor: pointer;
	transition: background 0.3s;
}

.buy-btn:hover {
	background: #c1121f;
}

/* 弹窗遮罩层 */
.cart-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.5);
	display: none;
	justify-content: center;
	align-items: center;
	z-index: 999;
}

.cart-modal.active {
	display: flex;
}

/* 购物车弹窗 */
.cart-content {
	width: 90%;
	max-width: 600px;
	background: white;
	padding: 2rem;
	border-radius: 8px;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
	position: relative;
}

.close-cart {
	position: absolute;
	top: 1.5rem;
	right: 1.5rem;
	font-size: 1.5rem;
	cursor: pointer;
	color: #999;
	transition: color 0.3s;
}

.close-cart:hover {
	color: #e63946;
}

.cart-title {
	font-size: 1.6rem;
	color: #333;
	margin-bottom: 1.5rem;
	border-bottom: 2px solid #eee;
	padding-bottom: 0.5rem;
}

.address-form {
	background-color: #fff;
	border-radius: 12px;
	padding: 20px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.car-info {
	margin-bottom: 16px;
}

.info-label {
	display: block;
	font-size: 14px;
	color: #333;
	margin-bottom: 8px;
}

.info-name {
	width: 100%;
	padding: 10px;
	border: 1px solid #ddd;
	border-radius: 6px;
	font-size: 14px;
	outline: none;
}
.info-tel{
	width: 100%;
	padding: 10px;
	border: 1px solid #ddd;
	border-radius: 6px;
	font-size: 14px;
	outline: none;
}
.info-adr {
	width: 100%;
	padding: 10px;
	border: 1px solid #ddd;
	border-radius: 6px;
	font-size: 14px;
	outline: none;
}
.info-label::after {
    content: "*";
    color: red;
}

.info-input::placeholder {
	color: #aaaaff;
}

.cart-item {
	display: flex;
	align-items: center;
	padding: 1rem 0;
	border-bottom: 1px solid #eee;
}

.item-img {
	width: 80px;
	height: 80px;
	object-fit: cover;
	border-radius: 4px;
	margin-right: 1rem;
}

.item-info {
	flex: 1;
}

.item-name {
	font-size: 1.1rem;
	color: #333;
	margin-bottom: 0.3rem;
}

.item-price {
	color: #e63946;
	font-weight: bold;
}

.item-quantity {
	display: flex;
	align-items: center;
	margin: 0 1.5rem;
}

.quantity-btn {
	width: 30px;
	height: 30px;
	border: 1px solid #ddd;
	background: #f8f8f8;
	border-radius: 4px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}

.quantity-input {
	width: 50px;
	height: 30px;
	border: 1px solid #ddd;
	border-left: none;
	border-right: none;
	text-align: center;
	outline: none;
}

.item-subtotal {
	color: #333;
	font-weight: 600;
	margin: 0 1.5rem;
}

.cart-footer {
	margin-top: 1.5rem;
	text-align: right;
}

.total-price {
	font-size: 1.3rem;
	color: #e63946;
	font-weight: bold;
}

.checkout-btn {
	margin-top: 1rem;
	padding: 0.8rem 2rem;
	background: #2196f3;
	color: white;
	border: none;
	border-radius: 4px;
	cursor: pointer;
	font-size: 1rem;
	transition: background 0.3s;
}

.checkout-btn:hover {
	background: #1976d2;
}

.qr-code-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.5);
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s, visibility 0.3s;
}

.qr-code-modal.show {
	opacity: 1;
	visibility: visible;
}

.qr-code-content {
	background-color: #fff;
	border-radius: 12px;
	padding: 24px;
	width: 90%;
	max-width: 320px;
	text-align: center;
}

.qr-code-title {
	font-size: 18px;
	font-weight: 600;
	margin-bottom: 16px;
}

.qr-code-img {
	width: 200px;
	height: 200px;
	margin: 0 auto 16px;
	background-color: #f0f0f0;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 8px;
}

.qr-code-desc {
	font-size: 14px;
	color: #666;
	margin-bottom: 20px;
}

.close-btn {
	background-color: #e64340;
	color: #fff;
	border: none;
	border-radius: 6px;
	padding: 10px 20px;
	font-size: 14px;
	cursor: pointer;
	width: 100%;
}