/* Reset first, before anything else: many themes apply global `button`
   styles (color, width:100%, padding, box-shadow, border-radius) which were
   overriding our small round icon buttons and stretching them full-width /
   wrong color on all screen sizes. Strip that out; the specific .ppg-* button
   rules further down in this file re-apply our intended look and always win
   because they come later with the same specificity. */
.ppg-grid button,
.ppg-modal button,
.ppg-variation-popup button,
.ppg-toast button {
	all: unset;
	box-sizing: border-box !important;
	cursor: pointer;
	text-align: center;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

/* ---------- Grid ---------- */
.ppg-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
	gap: 20px;
	margin: 20px 0;
}

.ppg-card {
	background: #0d0d0d;
	border: 1px solid #232323;
	border-radius: 10px;
	overflow: hidden;
	cursor: pointer;
	transition: transform 0.2s ease, border-color 0.2s ease;
}

.ppg-card:hover {
	transform: translateY(-4px);
	border-color: #4a4a4a;
}

.ppg-card-image {
	position: relative;
	background: #ffffff;
	height: 220px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.ppg-card-image img {
	max-height: 90%;
	max-width: 80%;
	object-fit: contain;
}

.ppg-pdf-badge {
	position: absolute;
	top: 10px;
	right: 10px;
	font-size: 11px;
	letter-spacing: 1px;
	color: #555;
	border: 1px solid #ccc;
	padding: 2px 7px;
	border-radius: 3px;
	background: #fff;
}

.ppg-card-body {
	padding: 18px;
	color: #eaeaea;
}

.ppg-card-cat {
	font-size: 11px;
	letter-spacing: 1px;
	color: #8a8a8a;
	margin-bottom: 8px;
}

.ppg-card-title {
	font-size: 18px;
	line-height: 1.3;
	margin: 0 0 10px;
	color: #fff;
	font-weight: 600;
}

.ppg-card-lot {
	font-size: 12px;
	color: #999;
	margin-bottom: 14px;
	padding-bottom: 14px;
	border-bottom: 1px solid #222;
}

.ppg-card-footer {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 14px;
	color: #fff;
}

.ppg-arrow {
	border: 1px solid #444;
	border-radius: 50%;
	width: 26px;
	height: 26px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
}

/* ---------- Modal ---------- */
.ppg-modal-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.82);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 99999;
	padding: 20px;
}

.ppg-modal-overlay.active {
	display: flex;
}

.ppg-modal {
	background: #0d0d0d;
	width: 100%;
	max-width: 1050px;
	max-height: 90vh;
	display: grid;
	grid-template-columns: 1.4fr 1fr;
	border-radius: 12px;
	overflow: hidden;
	border: 1px solid #2a2a2a;
	position: relative;
}

.ppg-modal-left {
	padding: 24px;
	overflow-y: auto;
	border-right: 1px solid #222;
}

.ppg-modal-pdf-header {
	display: flex;
	justify-content: space-between;
	color: #999;
	font-size: 11px;
	letter-spacing: 1px;
	margin-bottom: 8px;
}

.ppg-modal-title-row {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0 0 16px;
}

.ppg-modal-title {
	color: #fff;
	font-size: 20px;
	margin: 0;
	font-weight: 600;
}

.ppg-pdf-tabs {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
}

.ppg-pdf-tab {
	background: transparent !important;
	border: 1px solid #444 !important;
	color: #ccc !important;
	font-size: 12px !important;
	padding: 5px 12px !important;
	border-radius: 6px !important;
	transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.ppg-pdf-tab:hover {
	border-color: #777 !important;
	color: #fff !important;
}

.ppg-pdf-tab.active {
	background: #fff !important;
	border-color: #fff !important;
	color: #000 !important;
	font-weight: 600;
}

.ppg-pdf-frame-wrap {
	background: #fff;
	border-radius: 8px;
	overflow: hidden;
	height: 520px;
}

.ppg-pdf-frame-wrap iframe {
	width: 100%;
	height: 100%;
	border: 0;
}

.ppg-open-full {
	display: inline-block;
	margin-top: 14px;
	color: #ccc;
	text-decoration: none;
	font-size: 13px;
}

.ppg-open-full:hover {
	color: #fff;
}

.ppg-modal-right {
	padding: 28px 24px 24px;
	display: flex;
	flex-direction: column;
	color: #fff;
}

.ppg-modal-close {
	position: absolute !important;
	top: 14px !important;
	right: 14px !important;
	background: #1a1a1a !important;
	color: #fff !important;
	width: 32px !important;
	height: 32px !important;
	min-width: 32px !important;
	max-width: 32px !important;
	border-radius: 50% !important;
	font-size: 18px !important;
	line-height: 1 !important;
	z-index: 2;
}

.ppg-modal-close:hover {
	background: #2a2a2a !important;
}

.ppg-modal-image {
	background: #fff;
	border-radius: 8px;
	height: 180px;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 18px;
}

.ppg-modal-image img {
	max-height: 90%;
	max-width: 80%;
	object-fit: contain;
}

.ppg-modal-cat {
	font-size: 11px;
	color: #8a8a8a;
	letter-spacing: 1px;
	margin-bottom: 8px;
}

.ppg-modal-info h3 {
	margin: 0 0 12px;
	font-size: 19px;
	font-weight: 600;
}

.ppg-modal-price {
	font-size: 20px;
	font-weight: 700;
	margin-bottom: 24px;
}

.ppg-add-to-cart {
	display: block !important;
	width: 100% !important;
	background: #fff !important;
	color: #000 !important;
	padding: 14px !important;
	border-radius: 8px !important;
	font-weight: 600;
	font-size: 15px !important;
	margin-top: auto;
	transition: background 0.15s ease;
}

.ppg-add-to-cart:hover {
	background: #e6e6e6 !important;
}

.ppg-add-to-cart:disabled {
	opacity: 0.6;
	cursor: default;
}

.ppg-modal-disclaimer {
	text-align: center;
	font-size: 11px;
	color: #777;
	margin-top: 16px;
}

body.ppg-modal-open {
	overflow: hidden;
}

/* ---------- Variation (size picker) popup ---------- */
.ppg-variation-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.55);
	display: none;
	align-items: flex-end;
	justify-content: center;
	z-index: 100000;
}

.ppg-variation-overlay.active {
	display: flex;
}

.ppg-variation-popup {
	background: #fff;
	color: #111;
	width: 100%;
	max-width: 460px;
	border-radius: 14px 14px 0 0;
	padding: 20px 20px 28px;
	box-shadow: 0 -6px 30px rgba(0, 0, 0, 0.3);
	animation: ppg-slide-up 0.2s ease-out;
	box-sizing: border-box;
}

@keyframes ppg-slide-up {
	from { transform: translateY(30px); opacity: 0; }
	to   { transform: translateY(0); opacity: 1; }
}

.ppg-variation-header {
	display: flex;
	align-items: center;
	gap: 12px;
	position: relative;
	width: 100%;
}

.ppg-variation-thumb {
	width: 48px !important;
	height: 48px !important;
	flex: 0 0 48px !important;
	border: 1px solid #eee;
	border-radius: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.ppg-variation-thumb img {
	max-width: 90%;
	max-height: 90%;
	object-fit: contain;
}

.ppg-variation-heading {
	flex: 1 1 auto;
	min-width: 0;
}

.ppg-variation-heading h4 {
	margin: 0 0 2px;
	font-size: 16px;
	font-weight: 700;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.ppg-variation-heading span {
	font-size: 13px;
	color: #666;
}

.ppg-variation-close {
	display: flex !important;
	align-items: center;
	justify-content: center;
	background: #f2f2f2 !important;
	color: #111 !important;
	width: 30px !important;
	height: 30px !important;
	min-width: 30px !important;
	max-width: 30px !important;
	border-radius: 50% !important;
	font-size: 16px !important;
	line-height: 1 !important;
	flex: 0 0 30px !important;
}

.ppg-variation-close:hover {
	background: #e6e6e6 !important;
}

.ppg-variation-subtitle {
	margin: 16px 0 10px;
	font-size: 11px;
	letter-spacing: 1px;
	color: #999;
	text-transform: uppercase;
}

.ppg-variation-list {
	display: flex;
	flex-direction: column;
	gap: 10px;
	max-height: 320px;
	overflow-y: auto;
	width: 100%;
}

.ppg-variation-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	border: 1px solid #eee;
	border-radius: 8px;
	padding: 12px 14px;
	width: 100%;
	box-sizing: border-box;
}

.ppg-variation-label {
	font-weight: 600;
	font-size: 15px;
	flex: 1 1 auto;
}

.ppg-variation-price-cell {
	margin-left: auto;
	font-size: 14px;
	color: #444;
	flex: 0 0 auto;
	white-space: nowrap;
}

.ppg-variation-price-cell del {
	color: #aaa;
	margin-right: 6px;
}

.ppg-variation-add {
	display: flex !important;
	align-items: center;
	justify-content: center;
	background: #111 !important;
	color: #fff !important;
	width: 30px !important;
	height: 30px !important;
	min-width: 30px !important;
	max-width: 30px !important;
	border-radius: 50% !important;
	font-size: 16px !important;
	line-height: 1 !important;
	flex: 0 0 30px !important;
	transition: background 0.15s ease;
}

.ppg-variation-add:hover {
	background: #333 !important;
}

.ppg-variation-add:disabled {
	background: #ccc !important;
	cursor: default;
}

.ppg-variation-row.ppg-variation-out-of-stock {
	opacity: 0.5;
}

.ppg-variation-empty {
	font-size: 14px;
	color: #777;
	text-align: center;
	padding: 20px 0;
}

/* ---------- "Added to cart" toast ---------- */
.ppg-toast {
	position: fixed;
	left: 24px;
	bottom: 24px;
	z-index: 100001;
	display: flex;
	align-items: center;
	gap: 14px;
	background: #1a1a1a;
	color: #fff;
	padding: 14px 16px;
	border-radius: 10px;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
	transform: translateY(20px);
	opacity: 0;
	pointer-events: none;
	transition: transform 0.2s ease, opacity 0.2s ease;
	max-width: calc(100vw - 48px);
	box-sizing: border-box;
}

.ppg-toast.active {
	transform: translateY(0);
	opacity: 1;
	pointer-events: auto;
}

.ppg-toast-check {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	flex: 0 0 22px;
	border-radius: 50%;
	background: #2fa84f;
	color: #fff;
	font-size: 13px;
}

.ppg-toast-text {
	font-size: 14px;
	font-weight: 500;
	white-space: nowrap;
}

.ppg-toast-view-cart {
	background: #fff !important;
	color: #000 !important;
	font-size: 13px !important;
	font-weight: 600;
	padding: 8px 14px !important;
	border-radius: 6px !important;
	white-space: nowrap;
	flex: 0 0 auto;
	margin-left: 4px;
}

.ppg-toast-view-cart:hover {
	background: #e6e6e6 !important;
}

@media (max-width: 480px) {
	.ppg-toast {
		left: 12px;
		right: 12px;
		bottom: 12px;
		max-width: none;
	}
	.ppg-toast-text {
		white-space: normal;
	}
}

@media (max-width: 768px) {
	.ppg-modal {
		grid-template-columns: 1fr;
		overflow-y: auto;
		max-height: 95vh;
	}
	.ppg-modal-left {
		border-right: none;
		border-bottom: 1px solid #222;
	}
	.ppg-pdf-frame-wrap {
		height: 400px;
	}
}
