/**
 * Open Order System - Optimierte Bestätigungsseite
 *
 * CSS-Variablen für Theme-Anpassung:
 * --lbite-color-primary: Hauptfarbe (Standard: #0073aa)
 * --lbite-color-secondary: Sekundärfarbe (Standard: #23282d)
 * --lbite-color-accent: Akzentfarbe für Erfolg (Standard: #00a32a)
 * --lbite-color-background: Hintergrund (Standard: #f8f9fa)
 * --lbite-color-border: Rahmenfarbe (Standard: #e0e0e0)
 * --lbite-border-radius: Eckenradius (Standard: 8px)
 *
 * @package OpenOrderSystem
 */

/* WooCommerce Standard-Elemente ausblenden */
.woocommerce-order-received .woocommerce-notice,
.woocommerce-order-received .woocommerce-thankyou-order-received,
.woocommerce-order-received > p:first-of-type,
.woocommerce-order-details,
.woocommerce-customer-details,
.woocommerce-order-overview,
.woocommerce-thankyou-order-details,
.woocommerce-table--order-details,
.wc-block-order-confirmation-summary,
.wc-block-order-confirmation-totals,
.wc-block-order-confirmation-downloads,
.wc-block-order-confirmation-billing-address,
.wc-block-order-confirmation-shipping-address,
.wc-block-order-confirmation-additional-information,
ul.woocommerce-order-overview,
section.woocommerce-order-details,
section.woocommerce-customer-details,
.woocommerce-order-received .woocommerce > p {
	display: none;
}

/* Main Container */
.lbite-thankyou-optimized {
	max-width: 500px;
	margin: 0 auto;
	padding: 30px 20px;
	text-align: center;
}

.lbite-thankyou-optimized * {
	box-sizing: border-box;
}

/* Logo */
.lbite-thankyou-logo {
	text-align: center;
	margin-bottom: 30px;
}

.lbite-thankyou-logo img {
	max-width: 150px;
	height: auto;
	display: inline-block;
}

/* Success Section */
.lbite-thankyou-success {
	margin-bottom: 30px;
	text-align: center;
}

.lbite-thankyou-icon-wrapper {
	text-align: center;
	margin-bottom: 15px;
}

.lbite-thankyou-icon-svg {
	width: 60px;
	height: 60px;
	color: var(--lbite-color-accent, #00a32a);
	display: inline-block;
}

.lbite-thankyou-success h1 {
	margin: 0 0 10px 0;
	font-size: 28px;
	color: var(--lbite-color-secondary, #23282d);
	text-align: center;
}

.lbite-thankyou-greeting {
	font-size: 18px;
	color: #666;
	margin: 0;
	text-align: center;
}

/* Pickup Number */
.lbite-thankyou-pickup-number {
	background: var(--lbite-color-primary, #0073aa);
	color: #fff;
	padding: 25px 30px;
	border-radius: calc(var(--lbite-border-radius, 8px) + 4px);
	margin-bottom: 30px;
	text-align: center;
}

.lbite-pickup-label {
	display: block;
	font-size: 14px;
	opacity: 0.9;
	margin-bottom: 8px;
}

.lbite-pickup-number {
	display: block;
	font-size: 52px;
	font-weight: bold;
	letter-spacing: 8px;
	line-height: 1.2;
}

/* Details Section */
.lbite-thankyou-details {
	display: flex;
	flex-direction: column;
	gap: 15px;
	margin-bottom: 30px;
}

.lbite-thankyou-detail {
	display: flex;
	align-items: flex-start;
	gap: 15px;
	text-align: left;
	padding: 15px 20px;
	background: var(--lbite-color-background, #f8f9fa);
	border-radius: var(--lbite-border-radius, 8px);
}

.lbite-detail-icon-svg {
	width: 24px;
	height: 24px;
	color: var(--lbite-color-primary, #0073aa);
	flex-shrink: 0;
	margin-top: 2px;
}

.lbite-detail-content {
	flex: 1;
}

.lbite-detail-label {
	display: block;
	font-size: 11px;
	color: #888;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 2px;
}

.lbite-detail-value {
	display: block;
	font-size: 16px;
	font-weight: 600;
	color: var(--lbite-color-secondary, #23282d);
}

.lbite-detail-sub {
	display: block;
	font-size: 14px;
	color: #666;
	margin-top: 3px;
}

/* Google Maps Link */
a.lbite-maps-link {
	color: var(--lbite-color-primary, #0073aa);
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

a.lbite-maps-link:hover {
	text-decoration: underline;
}

.lbite-external-link-icon {
	width: 12px;
	height: 12px;
	flex-shrink: 0;
}

/* Order Section */
.lbite-thankyou-order {
	text-align: left;
	margin-bottom: 30px;
	padding: 20px;
	background: #fff;
	border: 1px solid var(--lbite-color-border, #e0e0e0);
	border-radius: var(--lbite-border-radius, 8px);
}

.lbite-thankyou-order h3 {
	margin: 0 0 15px 0;
	font-size: 16px;
	font-weight: 600;
	color: var(--lbite-color-secondary, #23282d);
	text-align: left;
}

.lbite-order-items {
	width: 100%;
	border-collapse: collapse;
	border: none;
}

.lbite-order-items tbody tr {
	border-bottom: 1px solid var(--lbite-color-border, #e0e0e0);
}

.lbite-order-items tbody tr:last-child {
	border-bottom: 1px solid var(--lbite-color-border, #e0e0e0);
}

.lbite-order-items td {
	padding: 12px 8px;
	vertical-align: top;
	border: none;
}

.lbite-item-qty {
	width: 35px;
	color: #888;
	font-weight: 500;
	text-align: left;
}

.lbite-item-name {
	text-align: left;
	color: var(--lbite-color-secondary, #23282d);
}

.lbite-item-meta {
	display: block;
	font-size: 12px;
	color: #888;
	margin-top: 4px;
	font-style: italic;
}

.lbite-item-total {
	text-align: right;
	white-space: nowrap;
	font-weight: 500;
	color: var(--lbite-color-secondary, #23282d);
}

.lbite-order-items tfoot tr {
	border: none;
}

.lbite-order-items tfoot td {
	padding: 8px;
	border: none;
}

.lbite-subtotal-row td {
	color: #666;
	font-size: 14px;
	padding-top: 12px;
}

.lbite-subtotal-row td:last-child {
	text-align: right;
}

.lbite-fee-row td,
.lbite-coupon-row td,
.lbite-shipping-row td,
.lbite-tax-row td {
	color: #666;
	font-size: 14px;
}

.lbite-fee-row td:last-child,
.lbite-coupon-row td:last-child,
.lbite-shipping-row td:last-child,
.lbite-tax-row td:last-child {
	text-align: right;
}

.lbite-coupon-row td:last-child {
	color: var(--lbite-color-accent, #00a32a);
}

.lbite-total-row td {
	font-size: 18px;
	padding-top: 12px;
	border-top: 2px solid var(--lbite-color-secondary, #23282d);
}

.lbite-total-row td:first-child {
	text-align: left;
}

.lbite-total-row td:last-child {
	text-align: right;
}

/* Footer */
.lbite-thankyou-footer {
	padding-top: 20px;
	border-top: 1px solid var(--lbite-color-border, #e0e0e0);
	color: #888;
	font-size: 14px;
	text-align: center;
}

.lbite-thankyou-footer p {
	margin: 5px 0;
}

/* Print Button */
.lbite-thankyou-print-btn-wrap {
	text-align: center;
	margin-bottom: 20px;
}

.lbite-print-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: none;
	border: 1px solid var(--lbite-color-border, #e0e0e0);
	border-radius: var(--lbite-border-radius, 8px);
	padding: 10px 18px;
	font-size: 14px;
	color: #666;
	cursor: pointer;
	transition: border-color 0.2s, color 0.2s;
}

.lbite-print-btn:hover {
	background-color: var(--lbite-color-primary, #0073aa);
	border-color: var(--lbite-color-primary, #0073aa);
	color: #fff;
}

/* Drucklayout – visibility-Ansatz damit verschachtelte Eltern nicht versteckt werden */
@media print {
	body * {
		visibility: hidden !important;
	}

	.lbite-thankyou-optimized,
	.lbite-thankyou-optimized * {
		visibility: visible !important;
	}

	.lbite-thankyou-optimized {
		position: absolute;
		top: 0;
		left: 0;
		width: 100%;
		max-width: 100%;
		padding: 20px;
		margin: 0;
	}

	.lbite-thankyou-print-btn-wrap {
		display: none !important;
		visibility: hidden !important;
	}
}

/* Responsive */
@media (max-width: 480px) {
	.lbite-thankyou-optimized {
		padding: 20px 15px;
	}

	.lbite-pickup-number {
		font-size: 40px;
		letter-spacing: 5px;
	}

	.lbite-thankyou-success h1 {
		font-size: 24px;
	}
}
