/* Produktdetailseite (inc/product-detail.php). Eigenes Stylesheet, damit kein Theme-Rebuild nötig ist. */

/* ---------- Rechte Spalte: Flex statt nummeriertem Grid ---------- */

body.pdp-v2 div.product .product__summary {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	align-items: flex-start;
	align-content: flex-start;
}

body.pdp-v2 div.product .product__summary > * {
	flex: 0 0 100%;
	max-width: 100%;
	grid-row: auto;
	grid-column: auto;
	margin-left: 0;
}

body.pdp-v2 div.product .product__summary > .product_title { order: 1; flex: 1 1 0; min-width: 0; padding-right: 16px; margin-bottom: 12px; }
body.pdp-v2 div.product .product__summary > .product-details__brand { order: 2; flex: 0 0 162px; }
body.pdp-v2 div.product .product__summary > .woocommerce-product-details__short-description { order: 3; }
body.pdp-v2 div.product .product__summary > .woocommerce-product-rating { order: 4; }
body.pdp-v2 div.product .product__summary > .price { order: 5; }
body.pdp-v2 div.product .product__summary > .pdp-saving { order: 6; }
body.pdp-v2 div.product .product__summary > .legal-price-info { order: 8; flex: 0 1 auto; width: auto; }
body.pdp-v2 div.product .product__summary > .tiefstpreis { order: 8; }
body.pdp-v2 div.product .product__summary > .delivery-time-info { order: 10; flex: 0 1 auto; width: auto; }
body.pdp-v2 div.product .product__summary > .pdp-made-to-order { order: 10; flex: 0 1 auto; width: auto; }

/* Zeilenumbrüche: Rechtszeile und Lieferzeile beginnen jeweils neu. */
body.pdp-v2 div.product .product__summary::after,
body.pdp-v2 div.product .product__summary::before {
	content: "";
	flex: 0 0 100%;
	height: 0;
}

body.pdp-v2 div.product .product__summary::after { order: 7; }
body.pdp-v2 div.product .product__summary::before { order: 9; }
body.pdp-v2 div.product .product__summary > .product-weight { order: 11; }
body.pdp-v2 div.product .product__summary > .cart,
body.pdp-v2 div.product .product__summary > .single-configurator-button { order: 12; }
body.pdp-v2 div.product .product__summary > .pdp-cta-note { order: 13; }
body.pdp-v2 div.product .product__summary > .product-additional-info-sp { order: 14; }
body.pdp-v2 div.product .product__summary > .pdp-benefits { order: 15; }
body.pdp-v2 div.product .product__summary > .ppcp-messages { order: 16; }
body.pdp-v2 div.product .product__summary > .product-payments { order: 17; }
body.pdp-v2 div.product .product__summary > .pdp-consult { order: 18; }
body.pdp-v2 div.product .product__summary > .pdp-datasheet--summary { order: 19; }

/* Ersetzt durch Beratungsbox, Datenblatt-Karte und Bestpreis-Kachel. */
body.pdp-v2 div.product .product__summary:has(.pdp-consult) > .product-usps,
body.pdp-v2 div.product .product__summary > .data_sheet--summary,
body.pdp-v2 div.product .product__summary:has(.pdp-benefits) > .product-side-media,
body.pdp-v2 div.product .product__summary:has(.pdp-benefits) > .side_image {
	display: none !important;
}

/* Ohne Seitenbild bleiben die Siegel mobil unter der Galerie sichtbar. */
@media (max-width: 991.98px) {
	body.pdp-v2 .product:has(.trust_images--side) .trust_images:not(.trust_images--side) {
		display: flex;
	}
}

/* „Kauf auf Rechnung oder Raten …“ steckt in den Vorteils-Kacheln. */
body.pdp-v2 div.product .product__summary:has(.pdp-benefits) > .product-additional-info-sp {
	display: none;
}

/* Rabatt-Etikett auf dem Bild entfällt, wenn das Spar-Badge die Ersparnis nennt. */
.single-product div.product:has(.pdp-saving) .product-image__sale {
	display: none;
}

@media (max-width: 991.98px) {
	body.pdp-v2 div.product .product__summary > .product-details__brand {
		order: 0;
		flex: 0 0 100%;
		max-width: 140px;
		margin-bottom: 8px;
	}

	body.pdp-v2 div.product .product__summary > .product_title {
		flex: 0 0 100%;
		padding-right: 0;
	}
}

/* ---------- Kurzbeschreibung: Häkchen, „Fett – Zusatz“ ---------- */

body.pdp-v2 div.product .woocommerce-product-details__short-description ul {
	margin-bottom: 16px;
}

body.pdp-v2 div.product .woocommerce-product-details__short-description ul li {
	padding-left: 24px;
	line-height: 1.7;
	margin-bottom: 2px;
}

body.pdp-v2 div.product .woocommerce-product-details__short-description ul li::after {
	width: 15px;
	height: 15px;
	top: 6px;
	border-radius: 0;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2.5 8.5l3.5 3.5 7.5-8' fill='none' stroke='%231E1E1E' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center / contain;
}

body.pdp-v2 div.product .woocommerce-product-details__short-description li strong {
	font-weight: 600;
	color: #1e1e1e;
}

.pdp-usp-note {
	color: #8a8a8a;
}

/* ---------- Preis, Spar-Badge, Rechtszeile, Lieferzeit ---------- */

body.pdp-v2 div.product .product__summary > p.price {
	margin: 4px 0 8px;
	line-height: 1.15;
}

@media (min-width: 992px) {
	body.pdp-v2 div.product .product__summary > p.price {
		font-size: 30px;
	}
}

body.pdp-v2 div.product .product__summary > p.price del,
body.pdp-v2 div.product .product__summary > p.price del .amount {
	font-size: 16px;
	font-weight: 400;
	color: #9f9f9f;
	margin-left: 6px;
}

body.pdp-v2 div.product .product__summary > p.price ins {
	text-decoration: none;
}

.pdp-saving {
	display: inline-flex !important;
	flex: 0 0 auto !important;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 8px;
	margin: 0 0 10px;
	padding: 4px 10px 4px 30px;
	border: 1px solid #cfe7c0;
	border-radius: 6px;
	background: #f2f9ed url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='8' fill='%2343a047'/%3E%3Cpath d='M4.5 8.3l2.3 2.3 4.7-5' fill='none' stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat 9px center / 15px 15px;
	color: #2e7d32;
	font-size: 13px;
	line-height: 1.4;
}

.pdp-saving__percent {
	font-weight: 700;
}

.pdp-saving__until::before {
	content: "·";
	margin-right: 8px;
	color: #7cb36a;
}

body.pdp-v2 div.product .product__summary > .legal-price-info {
	white-space: normal;
	margin: 0 0 6px;
}

body.pdp-v2 div.product .product__summary > .legal-price-info p {
	display: inline;
	font-size: 12px;
}

body.pdp-v2 div.product .product__summary > .legal-price-info .tax-info::after {
	content: ",";
}

body.pdp-v2 div.product .product__summary > .legal-price-info .shipping-costs-info {
	white-space: normal;
}

body.pdp-v2 div.product .product__summary > .tiefstpreis {
	display: block;
	flex-basis: 100%;
	font-size: 12px;
	line-height: 16px;
	color: #9f9f9f;
	margin: -4px 0 6px;
}

body.pdp-v2 div.product .product__summary > .tiefstpreis .amount {
	color: inherit;
	font-weight: 400;
}

body.pdp-v2 div.product .product__summary > .delivery-time-info,
body.pdp-v2 div.product .product__summary > .pdp-made-to-order {
	font-size: 14px;
	line-height: 22px;
	color: #464646;
	margin: 2px 0 14px;
}

body.pdp-v2 div.product .product__summary > .delivery-time-info {
	padding-left: 28px;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23464646' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.5 6.5h11v9h-11zM13.5 9.5h4l3 3v3h-7z'/%3E%3Ccircle cx='6.5' cy='17.5' r='1.7'/%3E%3Ccircle cx='17' cy='17.5' r='1.7'/%3E%3C/svg%3E") no-repeat 0 center / 20px 20px;
}

body.pdp-v2 div.product .product__summary > .delivery-time-info .delivery-time-data {
	font-weight: 700;
}

body.pdp-v2 div.product .product__summary > .pdp-made-to-order {
	margin-left: 6px;
	color: #6f6f6f;
}

body.pdp-v2 div.product .product__summary > .pdp-made-to-order::before {
	content: "·";
	margin-right: 6px;
}

@media (max-width: 575.98px) {
	body.pdp-v2 div.product .product__summary > .delivery-time-info {
		margin-bottom: 0;
	}

	body.pdp-v2 div.product .product__summary > .pdp-made-to-order {
		flex-basis: 100%;
		margin-left: 0;
		padding-left: 28px;
	}

	body.pdp-v2 div.product .product__summary > .pdp-made-to-order::before {
		content: none;
	}
}

/* ---------- Hinweis unter dem Button ---------- */

.pdp-cta-note {
	margin: -2px 0 14px;
	font-size: 12.5px;
	line-height: 1.4;
	color: #7a7a7a;
	text-align: center;
}

.pdp-cta-note a {
	color: inherit;
	text-decoration: underline;
}

/* ---------- Vorteils-Kacheln ---------- */

.pdp-benefits {
	margin: 0 0 12px;
}

.pdp-benefits__title {
	margin: 0 0 8px;
	font-size: 14px;
	font-weight: 700;
	color: #1e1e1e;
}

.pdp-benefits__list {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.pdp-benefits__item {
	margin: 0;
	padding: 0;
}

.pdp-benefits__item::before,
.pdp-benefits__item::after {
	content: none !important;
}

.pdp-benefits__item > a,
.pdp-benefits__item > div {
	display: flex;
	flex-direction: column;
	height: 100%;
	padding: 8px 10px;
	border: 1px solid #ececec;
	border-top: 2px solid #0f2337;
	border-radius: 4px;
	background: #fafafa;
	color: #464646;
	text-decoration: none;
}

.pdp-benefits__item > a:hover {
	border-color: #f59100;
}

.pdp-benefits__item strong {
	font-size: 13px;
	line-height: 1.3;
	color: #1e1e1e;
}

.pdp-benefits__item span {
	font-size: 12px;
	line-height: 1.3;
	color: #8a8a8a;
}

@media (max-width: 767.98px) {
	.pdp-benefits__list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

/* ---------- Zahlungs-Logos ---------- */

body.pdp-v2 div.product .product__summary > .product-payments {
	justify-content: flex-start;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 14px;
}

body.pdp-v2 div.product .product__summary > .product-payments img {
	height: 30px;
}

/* ---------- Beratungsbox ---------- */

.pdp-consult {
	display: grid;
	grid-template-columns: 60px minmax(0, 1fr) auto;
	align-items: center;
	gap: 6px 14px;
	padding: 14px 16px;
	border: 1px solid #dfe8ef;
	border-radius: 8px;
	background: #f2f6f9;
}

.pdp-consult__avatar {
	position: relative;
	width: 60px;
	height: 60px;
	border-radius: 50%;
	overflow: hidden;
	background: #fff;
	box-shadow: 0 0 0 2px #fff, 0 1px 4px rgba(0, 0, 0, 0.12);
}

/* Hochformat-Freisteller: Kreis zeigt Kopf und Schultern, Kopf liegt oben im Bild. */
.pdp-consult__avatar img {
	position: absolute;
	top: -1px;
	left: 50%;
	width: 104px !important;
	max-width: none !important;
	height: auto !important;
	transform: translateX(-50%);
}

.pdp-consult__body p {
	margin: 0;
}

.pdp-consult__title {
	font-size: 15px;
	font-weight: 700;
	color: #1e1e1e;
	line-height: 1.3;
}

.pdp-consult__text {
	font-size: 12.5px;
	color: #6f6f6f;
	line-height: 1.4;
}

.pdp-consult__contact {
	display: flex;
	flex-wrap: wrap;
	gap: 2px 16px;
	margin-top: 4px !important;
	font-size: 13px;
}

.pdp-consult__contact a {
	color: #464646;
	text-decoration: none;
	white-space: nowrap;
}

.pdp-consult__contact a:hover {
	color: #f59100;
}

.pdp-consult .pdp-consult__button {
	white-space: nowrap;
	padding: 8px 16px;
	font-size: 14px;
}

@media (max-width: 575.98px) {
	.pdp-consult {
		grid-template-columns: 60px minmax(0, 1fr);
	}

	.pdp-consult .pdp-consult__button {
		grid-column: 1 / -1;
		width: 100%;
		text-align: center;
	}
}

/* ---------- Datenblatt als Karte ---------- */

.pdp-datasheet--gallery {
	position: relative;
	left: 25%;
	width: 75%;
	margin-top: 12px;
}

.pdp-datasheet--summary {
	margin-top: 12px;
}

@media (min-width: 992px) {
	body.pdp-v2 div.product .product__summary > .pdp-datasheet--summary {
		display: none;
	}
}

@media (max-width: 991.98px) {
	.pdp-datasheet--gallery {
		display: none !important;
	}
}

.pdp-datasheet {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 14px;
	border: 1px solid #e3e3e3;
	border-radius: 6px;
	background: #fff;
	color: #464646;
	text-decoration: none;
	min-height: 0;
}

.pdp-datasheet:hover {
	border-color: #f59100;
}

.pdp-datasheet span {
	width: auto;
}

.pdp-datasheet__icon {
	flex: 0 0 36px;
	width: 36px;
	height: 36px;
	border-radius: 6px;
	background: #f3f3f3 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23464646' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V8z'/%3E%3Cpath d='M14 3v5h5M9 13h6M9 17h6'/%3E%3C/svg%3E") no-repeat center / 20px 20px;
}

.pdp-datasheet__text {
	flex: 1 1 auto;
	display: flex;
	flex-direction: column;
	min-width: 0;
	text-align: left;
}

.pdp-datasheet__text strong {
	font-size: 14px;
	color: #1e1e1e;
}

.pdp-datasheet__text small {
	font-size: 12px;
	color: #8a8a8a;
}

.pdp-datasheet__action {
	flex: 0 0 auto;
	padding-left: 20px;
	font-size: 13px;
	font-weight: 600;
	color: #1e1e1e;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231E1E1E' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 4v11M7 10l5 5 5-5M5 20h14'/%3E%3C/svg%3E") no-repeat 0 center / 15px 15px;
}

/* ---------- Siegel + Shop-Bewertung unter der Galerie ---------- */

.pdp-trust {
	position: relative;
	left: 25%;
	width: 75%;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 16px;
	margin-top: 12px;
}

.pdp-trust .trust_images {
	width: auto;
	left: auto;
	margin: 0;
}

.pdp-rating {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	line-height: 1.35;
	color: #464646;
}

.pdp-rating__text {
	display: flex;
	flex-direction: column;
}

.pdp-rating__text strong {
	color: #1e1e1e;
}

.pdp-rating__text small {
	font-size: 12px;
	color: #8a8a8a;
}

.pdp-rating__stars {
	position: relative;
	display: inline-block;
	font-size: 15px;
	line-height: 1;
	letter-spacing: 1px;
	color: #d9d9d9;
	white-space: nowrap;
}

.pdp-rating__stars::before {
	content: "★★★★★";
}

.pdp-rating__stars > span {
	position: absolute;
	top: 0;
	left: 0;
	overflow: hidden;
	color: #f59100;
}

.pdp-rating__stars > span::before {
	content: "★★★★★";
}

@media (max-width: 991.98px) {
	.pdp-trust {
		left: auto;
		width: 100%;
		margin-top: 8px;
	}
}
