/**
 * VIP Sales Plugin Styles
 *
 * @package VIP_Sales
 */

/* Product List Styles */
.vip-sales-product-list-wrapper {
	margin: 30px 0;
}

.vip-sales-product-list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 30px;
}

.vip-sales-no-products {
	text-align: center;
	padding: 60px 20px;
	color: #666;
	grid-column: 1 / -1;
}

.vip-sales-no-products p {
	margin: 0;
	font-size: 16px;
}

.vip-sales-columns-2 {
	grid-template-columns: repeat(2, 1fr);
}

.vip-sales-columns-3 {
	grid-template-columns: repeat(3, 1fr);
}

.vip-sales-columns-4 {
	grid-template-columns: repeat(4, 1fr);
}

.vip-sales-product-item {
	border: 1px solid #e8e8e8;
	border-radius: 8px;
	padding: 0;
	background: #fff;
	overflow: hidden;
	position: relative;
	display: flex;
	flex-direction: column;
}

.vip-sales-product-item:hover {
	border-color: #BDAD97;
}

/* Product Image Wrapper */
.vip-sales-product-image-wrapper {
	position: relative;
	overflow: hidden;
	background: #f8f9fa;
	aspect-ratio: 1 / 1;
}

.vip-sales-product-image {
	position: relative;
	width: 100%;
	height: 100%;
	overflow: hidden;
}

.vip-sales-product-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.vip-sales-product-overlay {
	display: none;
}

/* Badges */
.vip-sales-sale-badge,
.vip-sales-stock-badge,
.vip-sales-featured-badge {
	position: absolute;
	top: 12px;
	left: 12px;
	padding: 6px 12px;
	border-radius: 4px;
	font-size: 12px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	z-index: 2;
}

.vip-sales-sale-badge {
	background: #dc3545;
	color: #fff;
}

.vip-sales-stock-badge {
	background: #6c757d;
	color: #fff;
}

.vip-sales-featured-badge {
	background: #BDAD97;
	color: #fff;
}

.vip-sales-stock-out {
	background: #dc3545;
}

/* Product Info */
.vip-sales-product-info {
	padding: 20px;
	flex-grow: 1;
	display: flex;
	flex-direction: column;
}

.vip-sales-product-category {
	font-size: 12px;
	color: #6c757d;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 8px;
	font-weight: 600;
}

.vip-sales-product-title {
	margin: 0 0 12px 0;
	font-size: 18px;
	font-weight: 600;
	line-height: 1.4;
	min-height: 50px;
}

.vip-sales-product-title a {
	text-decoration: none;
	color: #333;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.vip-sales-product-title a:hover {
	color: #BDAD97;
}

/* Rating */
.vip-sales-product-rating {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 12px;
	font-size: 14px;
}

.vip-sales-stars {
	display: flex;
	gap: 2px;
}

.vip-sales-star {
	display: inline-block;
	width: 14px;
	height: 14px;
	background: #ddd;
	clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
}

.vip-sales-star-filled {
	background: #BDAD97;
}

.vip-sales-review-count {
	color: #6c757d;
	font-size: 13px;
}

/* Description */
.vip-sales-product-description {
	font-size: 14px;
	color: #6c757d;
	line-height: 1.6;
	margin-bottom: 16px;
	flex-grow: 1;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* Price */
.vip-sales-product-price {
	margin-bottom: 16px;
	font-size: 22px;
	font-weight: 700;
	color: #BDAD97;
	line-height: 1.2;
}

.vip-sales-product-price del {
	font-size: 16px;
	color: #999;
	font-weight: 400;
	margin-right: 8px;
}

.vip-sales-product-price ins {
	text-decoration: none;
	color: #dc3545;
}

/* Actions */
.vip-sales-product-actions {
	margin-top: auto;
}

/* Button Styles */
.vip-sales-btn {
	display: inline-block;
	padding: 12px 24px;
	border: none;
	border-radius: 4px;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	text-align: center;
	width: 100%;
}

.vip-sales-btn-primary {
	background-color: #BDAD97;
	color: #fff;
}

.vip-sales-btn-primary:hover {
	background-color: #887555;
	color: #fff;
}

.vip-sales-add-to-cart-form {
	margin: 0;
	width: 100%;
}

.vip-sales-btn-disabled {
	background-color: #ccc;
	color: #666;
	cursor: not-allowed;
	opacity: 0.6;
}

.vip-sales-btn-clear {
	background-color: #BDAD97;
	color: #fff;
}

.vip-sales-btn-clear:hover {
	background-color: #887555;
	color: #fff;
}

/* Cart Actions */
.vip-sales-cart-actions {
	margin-bottom: 20px;
	text-align: right;
}

.vip-sales-cart-actions .vip-sales-btn {
	width: auto;
	display: inline-block;
}

.vip-sales-btn-whatsapp {
	background-color: #BDAD97;
	color: #fff;
}

.vip-sales-btn-whatsapp:hover:not(.vip-sales-btn-disabled) {
	background-color: #887555;
	color: #fff;
}

.vip-sales-btn-email {
	background-color: #BDAD97;
	color: #fff;
}

.vip-sales-btn-email:hover:not(.vip-sales-btn-disabled) {
	background-color: #887555;
	color: #fff;
}

.vip-sales-btn-secondary {
	background-color: #BDAD97;
	color: #fff;
	border: 1px solid #BDAD97;
}

.vip-sales-btn-secondary:hover {
	background-color: #887555;
	color: #fff;
	border-color: #887555;
}

/* Contact Form Styles */
.vip-sales-contact-form {
	margin: 40px 0;
	padding: 30px;
	background: #f9f9f9;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
}

.vip-sales-heading {
	margin: 0 0 25px 0;
	font-size: 24px;
	font-weight: 600;
	color: #333;
	text-align: center;
}

.vip-sales-form-group {
	margin-bottom: 20px;
}

.vip-sales-form-group label {
	display: block;
	margin-bottom: 8px;
	font-weight: 600;
	color: #333;
}

.vip-sales-required::after {
	content: " *";
	color: #dc3232;
}

.vip-sales-input {
	width: 100%;
	padding: 12px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 14px;
	box-sizing: border-box;
}

.vip-sales-input:focus {
	outline: none;
	border-color: #BDAD97;
}

.vip-sales-checkbox-label {
	display: flex;
	align-items: flex-start;
	cursor: pointer;
}

.vip-sales-checkbox {
	margin-right: 10px;
	margin-top: 3px;
	width: 18px;
	height: 18px;
	cursor: pointer;
}

.vip-sales-form-actions {
	display: flex;
	gap: 15px;
	margin-top: 25px;
	flex-wrap: wrap;
}

.vip-sales-form-actions .vip-sales-btn {
	flex: 1;
	min-width: 200px;
}

/* Message Styles */
.vip-sales-message {
	display: none;
	padding: 15px 20px;
	margin-top: 20px;
	margin-bottom: 20px;
	border-radius: 4px;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.5;
	animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
	from {
		opacity: 0;
		transform: translateY(-10px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.vip-sales-message.success {
	background-color: #d4edda;
	border: 1px solid #c3e6cb;
	color: #155724;
}

.vip-sales-message.error {
	background-color: #f8d7da;
	border: 1px solid #f5c6cb;
	color: #721c24;
}

.vip-sales-message span {
	display: block;
}

/* Empty Cart Styles */
.vip-sales-empty-cart {
	text-align: center;
	padding: 40px 20px;
	margin: 40px 0;
}

.vip-sales-empty-cart-title {
	font-size: 24px;
	font-weight: 600;
	margin-bottom: 15px;
	color: #333;
}

.vip-sales-empty-cart-text {
	font-size: 16px;
	margin-bottom: 15px;
	color: #666;
}

.vip-sales-empty-cart a {
	color: #BDAD97;
	text-decoration: none;
	font-weight: 600;
}

.vip-sales-empty-cart a:hover {
	text-decoration: underline;
}

/* Hide default checkout button on cart page */
.woocommerce-cart .wc-proceed-to-checkout,
.woocommerce-cart .checkout-button {
	display: none !important;
}

/* Responsive Styles */
@media (max-width: 1200px) {
	.vip-sales-columns-4 {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 992px) {

	.vip-sales-columns-3,
	.vip-sales-columns-4 {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 768px) {
	.vip-sales-product-list {
		grid-template-columns: 1fr;
		gap: 20px;
	}

	.vip-sales-columns-2,
	.vip-sales-columns-3,
	.vip-sales-columns-4 {
		grid-template-columns: 1fr;
	}

	.vip-sales-product-item {
		border-radius: 8px;
	}

	.vip-sales-product-info {
		padding: 16px;
	}

	.vip-sales-product-title {
		font-size: 16px;
		min-height: auto;
	}

	.vip-sales-product-price {
		font-size: 20px;
	}

	.vip-sales-form-actions {
		flex-direction: column;
	}

	.vip-sales-form-actions .vip-sales-btn {
		width: 100%;
		min-width: auto;
	}


}

/* Variation Form Styles */
.vip-sales-variation-form {
	margin-top: 10px;
}

.vip-sales-variation-field {
	margin-bottom: 12px;
}

.vip-sales-variation-field label {
	display: block;
	margin-bottom: 6px;
	font-size: 13px;
	font-weight: 600;
	color: #333;
}

.vip-sales-variation-select {
	width: 100%;
	padding: 10px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 14px;
	background: #fff;
}

.vip-sales-variation-price {
	margin: 12px 0;
	padding: 10px;
	background: #f8f9fa;
	border-radius: 4px;
	font-weight: 600;
}

.vip-sales-variation-price-label {
	margin-right: 8px;
}

.vip-sales-variation-price-value {
	color: #BDAD97;
	font-size: 16px;
}

/* Floating Cart Bar */
.vip-sales-floating-cart {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	background: #fff;
	border-top: 2px solid #BDAD97;
	padding: 15px 20px;
	z-index: 9999;
}

.vip-sales-floating-cart-content {
	display: flex;
	align-items: center;
	justify-content: space-between;
	max-width: 1200px;
	margin: 0 auto;
}

.vip-sales-floating-cart-info {
	display: flex;
	align-items: center;
	gap: 15px;
	font-size: 16px;
}

.vip-sales-floating-cart-count {
	font-weight: 700;
	color: #BDAD97;
	font-size: 20px;
}

.vip-sales-floating-cart-text {
	color: #666;
}

.vip-sales-floating-cart-total {
	font-weight: 700;
	color: #BDAD97;
	font-size: 18px;
}

.vip-sales-floating-cart-actions {
	flex-shrink: 0;
}

.vip-sales-view-cart-btn {
	width: auto;
	padding: 10px 24px;
}

/* Topbar Styles */
.vip-sales-topbar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 20px;
	background: #fff;
	border: 1px solid #e8e8e8;
	border-radius: 8px;
	margin-bottom: 30px;
	flex-wrap: wrap;
	gap: 20px;
}

.vip-sales-topbar-left,
.vip-sales-topbar-right {
	display: flex;
	align-items: center;
	gap: 20px;
	flex-wrap: wrap;
}

.vip-sales-topbar-group {
	display: flex;
	align-items: center;
	gap: 10px;
}

.vip-sales-topbar-group label {
	font-size: 14px;
	font-weight: 600;
	color: #333;
	white-space: nowrap;
}

.vip-sales-topbar-select {
	padding: 8px 12px;
	border: 1px solid #e8e8e8;
	border-radius: 4px;
	font-size: 14px;
	background: #fff;
	color: #333;
	cursor: pointer;
	min-width: 150px;
}

.vip-sales-topbar-select:focus {
	outline: none;
	border-color: #BDAD97;
}

.vip-sales-view-buttons {
	display: flex;
	gap: 8px;
}

.vip-sales-view-btn {
	width: 40px;
	height: 40px;
	border: 1px solid #e8e8e8;
	background: #fff;
	border-radius: 4px;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 600;
	color: #333;
	transition: all 0.2s;
}

.vip-sales-view-btn:hover {
	border-color: #887555;
	color: #887555;
}

.vip-sales-view-btn.active {
	background: #BDAD97;
	border-color: #BDAD97;
	color: #fff;
}

/* Modal Styles */
.vip-sales-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 10000;
	display: flex;
	align-items: center;
	justify-content: center;
}

.vip-sales-modal-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.5);
	backdrop-filter: blur(2px);
}

.vip-sales-modal-content {
	position: relative;
	background: #fff;
	border-radius: 8px;
	max-width: 600px;
	width: 90%;
	max-height: 90vh;
	overflow-y: auto;
	z-index: 10001;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.vip-sales-modal-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 20px;
	border-bottom: 1px solid #e8e8e8;
}

.vip-sales-modal-title {
	margin: 0;
	font-size: 20px;
	font-weight: 600;
	color: #333;
}

.vip-sales-modal-close {
	background: none;
	border: none;
	font-size: 28px;
	color: #666;
	cursor: pointer;
	padding: 0;
	width: 32px;
	height: 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
	transition: color 0.2s;
}

.vip-sales-modal-close:hover {
	color: #BDAD97;
}

.vip-sales-modal-body {
	padding: 20px;
}

.vip-sales-loading,
.vip-sales-error {
	text-align: center;
	padding: 40px 20px;
	color: #666;
}

.vip-sales-error {
	color: #dc3545;
}

/* Modal Variation Form */
#vip-sales-modal-variation-form .vip-sales-variation-form {
	margin: 0;
}

#vip-sales-modal-variation-form .vip-sales-variation-field {
	margin-bottom: 20px;
}

#vip-sales-modal-variation-form .vip-sales-variation-field label {
	display: block;
	margin-bottom: 8px;
	font-weight: 600;
	color: #333;
}

#vip-sales-modal-variation-form .vip-sales-variation-select {
	width: 100%;
	padding: 10px;
	border: 1px solid #e8e8e8;
	border-radius: 4px;
	font-size: 14px;
}

/* Notification Popup */
.vip-sales-notification-popup {
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	background: rgba(0, 0, 0, 0.85);
	color: #fff;
	padding: 20px 30px;
	border-radius: 8px;
	z-index: 10002;
	text-align: center;
	box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
	display: none;
	min-width: 300px;
	backdrop-filter: blur(4px);
}

.vip-sales-notification-popup.vip-sales-show {
	animation: vipSalesFadeIn 0.3s ease-out forwards;
}

.vip-sales-notification-content {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
}

.vip-sales-notification-icon {
	font-size: 32px;
	margin-bottom: 5px;
}

.vip-sales-notification-message {
	font-size: 16px;
	font-weight: 500;
	line-height: 1.5;
}

.vip-sales-notification-popup.success .vip-sales-notification-icon {
	color: #887555;
}

.vip-sales-notification-popup.error .vip-sales-notification-icon {
	color: #dc3545;
}

@keyframes vipSalesFadeIn {
	from {
		opacity: 0;
		transform: translate(-50%, -40%);
	}

	to {
		opacity: 1;
		transform: translate(-50%, -50%);
	}
}


#vip-sales-modal-variation-form .vip-sales-variation-price {
	margin: 20px 0;
	padding: 15px;
	background: #f8f9fa;
	border-radius: 4px;
}

#vip-sales-modal-variation-form .vip-sales-variation-add-btn {
	width: 100%;
	margin-bottom: 10px;
}

@media (max-width: 768px) {
	.vip-sales-floating-cart-content {
		flex-direction: column;
		gap: 15px;
		text-align: center;
	}

	.vip-sales-floating-cart-info {
		flex-direction: column;
		gap: 8px;
	}

	.vip-sales-view-cart-btn {
		width: 100%;
	}

	.vip-sales-topbar {
		flex-direction: column;
		align-items: stretch;
	}

	.vip-sales-topbar-left,
	.vip-sales-topbar-right {
		width: 100%;
		justify-content: space-between;
	}

	.vip-sales-modal-content {
		width: 95%;
		max-height: 95vh;
	}
}