/* Hide prices for roles with hide_prices enabled */

/* Product pages */
body.se-hide-prices .woocommerce-Price-amount,
body.se-hide-prices .woocommerce-Price-currencySymbol,
body.se-hide-prices .product-price,
body.se-hide-prices .price {
	display: none !important;
}

/* Cart page - hide only price/subtotal columns, not the products */
body.se-hide-prices table.shop_table th.product-price,
body.se-hide-prices table.shop_table td.product-price,
body.se-hide-prices table.shop_table th.product-subtotal,
body.se-hide-prices table.shop_table td.product-subtotal {
	display: none !important;
}

/* Hide subtotal, tax, total, discount rows in cart */
body.se-hide-prices tr.cart-subtotal,
body.se-hide-prices tr.tax-rate,
body.se-hide-prices tr.tax-total,
body.se-hide-prices tr.fee,
body.se-hide-prices tr.order-total {
	display: none !important;
}

/* Hide "Subtotal" text in checkout table header */
body.se-hide-prices .woocommerce-checkout-review-order-table th.product-total {
	display: none !important;
}

/* Checkout page - hide product prices but show products */
body.se-hide-prices .woocommerce-review-order-table .product-total {
	display: none !important;
}

/* Hide product price text in checkout table */
body.se-hide-prices .woocommerce-review-order-table td.product-total,
body.se-hide-prices .woocommerce-review-order-table th.product-total {
	display: none !important;
}

/* Adjust product name column to full width when price is hidden */
body.se-hide-prices .woocommerce-review-order-table .product-name {
	display: block !important;
	width: 100% !important;
}

/* Keep product items visible but hide their amounts */
body.se-hide-prices .woocommerce-review-order-table tr:has(.product-name) {
	display: table-row !important;
}

/* Hide entire cart totals section when prices are hidden */
body.se-hide-prices .e-cart-totals,
body.se-hide-prices .cart-collaterals,
body.se-hide-prices .cart_totals,
body.se-hide-prices .e-cart__column-end {
	display: none !important;
}

/* Make cart table full width when totals are hidden */
body.se-hide-prices .e-cart__column-start {
	width: 100% !important;
	max-width: 100% !important;
	flex: 0 0 100% !important;
}

body.se-hide-prices .e-cart__container {
	grid-template-columns: 1fr !important;
}

body.se-hide-prices .e-cart-layout-two-column .e-cart__container {
	display: block !important;
}

body.se-hide-prices .woocommerce-cart-form,
body.se-hide-prices .e-shop-table {
	width: 100% !important;
	max-width: 100% !important;
}

/* Make product thumbnails larger when prices are hidden */
body.se-hide-prices .product-thumbnail {
	width: 150px !important;
}

body.se-hide-prices .product-thumbnail img {
	width: 150px !important;
	height: 150px !important;
	max-width: 150px !important;
	object-fit: cover;
}

/* Show the extra checkout button when prices are hidden and cart has items */
body.se-hide-prices:not(.woocommerce-cart-empty) #extrcartbtn {
	display: block !important;
}

/* Hide the extra checkout button when prices are visible (default state) */
body:not(.se-hide-prices) #extrcartbtn {
	display: none !important;
}

/* Hide "Gå til kassen" button when cart is empty and prices are hidden */
body.se-hide-prices.woocommerce-cart-empty #extrcartbtn {
	display: none !important;
}

/* Change "Kurv total" to "Kurv" text using CSS as fallback */
body.se-hide-prices .cart_totals h2 {
	font-size: 0;
	line-height: 0;
	height: 0;
	overflow: hidden;
}

body.se-hide-prices .cart_totals h2::before {
	content: 'Kurv';
	font-size: 1.5em;
	line-height: 1.5;
	display: inline-block;
}




