/*
 * PGE-Tema – butik: vinkort, priser, produktside, kurv, kasse og konto.
 */

/* ---------- Beskeder ---------- */

.message-wrapper { margin: 0; padding-bottom: .5em; }
ul.message-wrapper { margin: 0 0 10px; padding: .75em 0; font-size: 1.1em; }
ul.message-wrapper li { list-style: none; }
.message-container a { margin: 0 15px 0 0; }
.message-container .button { margin: 0 0 0 15px; }

/* ---------- Vinkort ---------- */

.category-page-row { padding-top: 30px; }
.shop-container { }
.products { }
.box { position: relative; width: 100%; margin: 0 auto; }
.box a { display: inline-block; }
.box, .box-image, .box-text { transition: opacity .3s, transform .3s, background-color .3s; }
.box-image { position: relative; height: auto; margin: 0 auto; overflow: hidden; }
.box-image > div > a, .box-image > a { display: block; }
.box-image img { width: 100%; max-width: 100%; margin: 0 auto; }
/* Billeder der endnu ikke er hentet, fylder kortets bredde, så pladsen er reserveret (bredde/højde-attributterne giver højden). */
.product-small .box-image img[loading="lazy"]:not(.pge-loaded) { width: 100%; }
/* Produktbilleder er normalt kvadratiske. Er et billede uploadet i højformat (eller bredformat), passes det ind
   i samme kvadrat, så flasken ikke bliver større end de andre og kortet ikke højere. Kvadratiske billeder er uændrede.
   Bredden er den samme før og efter billedet er hentet, så siden ikke flytter sig. */
.product-small .box-image img.krp { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; }
.box-text { position: relative; width: 100%; padding-top: .7em; padding-bottom: 1.4em; font-size: .9em; }
@media (max-width: 549px) { .box-text { font-size: 85%; } }
.box-text h1, .box-text h2, .box-text h3, .box-text h4, .box-text h5, .box-text h6, .box-text a:not(.button) { line-height: 1.3; margin-top: .1em; margin-bottom: .1em; }
.box-text p { margin-top: .1em; margin-bottom: .1em; }
.box-text .button { margin-top: 1em; }
.box-text.text-center { padding-left: 10px; padding-right: 10px; }
.has-shadow .box-text { padding-left: 1.2em; padding-right: 1.2em; }
.product-small .box-image::before { }
.image-tools { padding: 5px; position: absolute; }
/* På telefoner og tablets er der ingen musemarkør: vis værktøjerne altid */
@media only screen and (max-device-width: 1024px) { .image-tools { opacity: 1 !important; } }
.image-tools a:last-child { margin-bottom: 0; }
.image-tools a.button { display: block; }
.image-tools.bottom.left { padding: 0 0 5px 5px; }
.image-tools.top.right { padding: 5px 5px 0 0; }
.image-tools .grid-tools, .grid-tools { display: flex; width: 100%; padding: 0 !important; margin-bottom: -1px; -webkit-backface-visibility: hidden; backface-visibility: hidden; white-space: nowrap; }
.grid-tools a { display: block; width: 100%; padding: .4em 0 .5em; font-size: .85em; font-weight: 700; text-overflow: ellipsis; text-transform: uppercase; color: #f1f1f1; background-color: var(--fs-color-primary); opacity: .95; }
.out-of-stock-label { position: absolute; top: 40%; left: 0; right: 0; padding: 20px 0; font-weight: 700; text-align: center; text-transform: uppercase; color: #333; background: rgba(255, 255, 255, .9); opacity: .9; }

.price-wrapper .price { display: block; }
.price { line-height: 1; }
.product-info .price { margin: .5em 0; font-size: 1.5em; font-weight: bolder; }
span.amount { white-space: nowrap; font-weight: 700; color: #111; }
.dark .price, .dark span.amount { color: #fff; }
.header-cart-title span.amount { color: currentColor; }
del span.amount { margin-right: .3em; font-weight: 400; opacity: .6; }
ins { text-decoration: none; }
ul.product_list_widget li del span.amount { }

/* ---------- Sideinddeling ---------- */

.nav-pagination > li { margin: 0; }
.nav-pagination > li > span, .nav-pagination > li > a {
	display: block;
	min-width: 2.25em;
	height: 2.25em;
	padding: 0 7px;
	line-height: 2em;
	font-size: 1.1em;
	font-weight: bolder;
	text-align: center;
	vertical-align: top;
	border: 2px solid currentColor;
	border-radius: 99px;
	transition: all .3s;
}
.nav-pagination > li i { top: -1px; font-size: 1.2em; vertical-align: middle; }
.nav-pagination > li > .current, .nav-pagination > li > span:hover, .nav-pagination > li > a:hover { color: #fff; background-color: var(--fs-color-primary); border-color: var(--fs-color-primary); }
ul.page-numbers.nav-pagination { display: block; padding: 0; list-style: none; }
ul.page-numbers.nav-pagination > li { display: inline-block; margin: 0 .4em; }
ul.page-numbers.nav-pagination > li:first-child { margin-left: 0; }
ul.page-numbers.nav-pagination > li:last-child { margin-right: 0; }
.woocommerce-pagination ul.page-numbers.nav-pagination > li { margin-left: 0; }
ul.page-numbers.nav-pagination > li > a { color: currentColor; }
.woocommerce-pagination { }
.links > li > a { text-transform: none; }

/* ---------- Antal-vælger ---------- */

.quantity { display: inline-flex; opacity: 1; vertical-align: top; white-space: nowrap; }
.quantity + .button { margin-right: 0; }
.quantity .button.minus { border-right: 0 !important; border-top-right-radius: 0 !important; border-bottom-right-radius: 0 !important; }
.quantity .button.plus { border-left: 0 !important; border-top-left-radius: 0 !important; border-bottom-left-radius: 0 !important; }
.quantity .minus, .quantity .plus { padding-left: .4em; padding-right: .4em; margin: 0; }
.quantity input { display: inline-block; margin: 0; padding-left: 0; padding-right: 0; vertical-align: top; }
.quantity input[type="number"] { width: 2.5em; max-width: 2.5em; font-size: 1em; text-align: center; border-radius: 0 !important; -webkit-appearance: textfield; -moz-appearance: textfield; appearance: textfield; }
.quantity input[type="number"]::-webkit-outer-spin-button, .quantity input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
@media (max-width: 549px) { .quantity input[type="number"] { width: 2em; } }

/* ---------- Produktside ---------- */

.custom-product-page { padding-top: 0; }
.product-images.mb-half { margin-bottom: 0; }
.woocommerce-product-gallery__image img { width: 100%; }
.product-title-container { }
.product-title { }
h1.product-title { }
.product-price-container { }
.add-to-cart-container { }
form.cart { display: flex; flex-wrap: wrap; gap: 1em; margin-bottom: 1.3em; }
form.cart > * { flex: 1 1 100%; margin: 0; }
form.cart > .quantity { flex: 0 0 auto; }
form.cart > .button, form.cart > button { flex: 1 0 auto; }
form.cart .button { margin: 0; }
.single_add_to_cart_button { }
p.stock { margin-bottom: 1.3em; }
p.in-stock { color: var(--fs-color-success); }
p.out-of-stock, .stock.out-of-stock { color: var(--fs-color-alert); }
.product_meta { margin-bottom: 1em; font-size: .8em; }
.product_meta > span { display: block; padding: 5px 0; border-top: 1px dotted #ddd; }
.product-section { border-top: 1px solid #ececec; }
.product-section-title { margin: 0; }
.up-sells, .related { }

/* Faner */
.tabbed-content { display: flex; flex-flow: row wrap; }
.tabbed-content .nav, .tabbed-content .tab-panels { width: 100%; }
.woocommerce-tabs.container { padding-left: 0; padding-right: 0; }
.nav-line > li > a { position: relative; }
.nav-line > li > a::before { content: " "; position: absolute; top: 0; left: 50%; width: 100%; height: 3px; background-color: var(--fs-color-primary); opacity: 0; transform: translateX(-50%); transition: all .3s; }
.nav-line > li.active > a::before, .nav-line > li:hover > a::before { opacity: 1; }
.product-tabs { margin-bottom: 0; }
.nav-uppercase.product-tabs > li > a { font-weight: bolder; }
.nav.product-tabs > li { margin: 0 .7em; }
.nav.product-tabs > li > a { font-size: .8em; }
.tab-panels { padding-top: 1em; }
.tab-panels .entry-content { padding: 0; }
.tab-panels .panel:not(.active) { display: block; height: 0; padding: 0; overflow: hidden; opacity: 0; visibility: hidden; }
.tab-panels .panel.active { display: block !important; }
@media (max-width: 549px) {
	.small-nav-collapse > li { width: 100%; margin: 0 !important; }
	.small-nav-collapse > li a { display: block; width: 100%; }
}

/* ---------- Mini-kurv ---------- */

.cart-popup-title .heading-font { display: block; font-size: 1.125em; line-height: 1.2; }
.cart-popup-inner { display: flex; flex-direction: column; }
.off-canvas-cart .cart-popup-inner { text-align: left; }
.off-canvas-cart .cart-popup-inner--sticky { padding-bottom: 0; }
.cart-popup-inner--sticky .widget_shopping_cart,
.cart-popup-inner--sticky .widget_shopping_cart_content,
.cart-popup-inner--sticky ul.product_list_widget { display: flex; flex: 1 1 0%; flex-direction: column; }
ul.product_list_widget { margin: 0 0 30px; padding: 0; }
ul.product_list_widget li { position: relative; min-height: 80px; margin: 0; padding: 10px 30px 5px 75px; line-height: 1.33; list-style: none; overflow: hidden; vertical-align: top; }
ul.product_list_widget li + li { border-top: 1px solid #ececec; }
ul.product_list_widget li > a:not(.remove) { display: block; margin-bottom: 5px; padding: 0; overflow: hidden; text-overflow: ellipsis; line-height: 1.3; }
ul.product_list_widget li a.remove { position: absolute; top: 10px; right: 0; }
ul.product_list_widget li dl { margin: 0; font-size: .7em; line-height: 1; }
ul.product_list_widget li img { position: absolute; top: 10px; left: 0; width: 60px; height: 60px; margin-bottom: 5px; object-fit: cover; object-position: 50% 50%; }
ul.product_list_widget li .quantity { display: block; margin: 0; font-size: .85em; opacity: .6; }
.ux-mini-cart-qty { display: flex; gap: 4px; align-items: center; justify-content: space-between; margin: 3px -30px 0 0; }
.ux-mini-cart-footer { margin: 0 -30px; padding: 10px 30px 30px; }
.widget_shopping_cart p.total { display: flex; gap: 15px; justify-content: space-between; margin: 0 0 .5em; padding: 10px 0; text-align: center; border-top: 1px solid #ececec; border-bottom: 2px solid #ececec; }
/* Knapperne står fast i bunden af kurven – kun når skærmen er høj nok */
@media (min-height: 500px) {
	.off-canvas-cart .cart-popup-inner--sticky { min-height: 100vh; min-height: 100dvh; }
	.cart-popup-inner--sticky .ux-mini-cart-footer { position: sticky; bottom: 0; background-color: #fff; border-top: 1px solid #f1f1f1; }
	.cart-popup-inner--sticky .ux-mini-cart-footer .woocommerce-mini-cart__total:first-child { border-top: 0; }
}
.widget_shopping_cart .buttons { margin: 0; }
.widget_shopping_cart .buttons .button { width: 100%; margin: .5em 0 0; }
.widget_shopping_cart .button.checkout { background-color: var(--fs-color-secondary); }
a.remove, a.icon-remove { display: block; width: 24px; height: 24px; line-height: 19px !important; font-size: 15px !important; font-weight: 700; text-align: center; color: #ccc; border: 2px solid currentColor; border-radius: 100%; }
a.remove:hover, a.icon-remove:hover { color: #111; }
.ux-mini-cart-empty { gap: 30px; padding: 15px 0; }
.woocommerce-mini-cart__empty-message { margin: 0; text-align: center; }

/* ---------- Kurv ---------- */

.shop_table thead th, .cart_totals thead th, .shop_table .order-total th, .shop_table .order-total td { border-width: 3px; }
.shop_table th:last-child, .shop_table td:last-child { text-align: right; }
.shop_table .cart_item td { padding-top: 15px; padding-bottom: 15px; }
.shop_table .product-thumbnail { width: 90px; min-width: 60px; max-width: 90px; }
.shop_table .product-remove { padding-left: 0; padding-right: 0; }
.shop_table .actions { padding: 30px 0 15px; border: 0; }
.shop_table .actions .button { margin: 0 1em 1em 0; }
.shop_table ul li, .checkout ul li { margin: 0; list-style: none; }
.cart-auto-refresh button[name="update_cart"] { display: none; }
.cart_totals tbody th { font-weight: 400; text-transform: none; letter-spacing: 0; }
.cart_totals > h2 { display: none; }
.cart_totals .button { display: block; min-width: 100%; margin-right: 0; }
.cart_totals .wc-proceed-to-checkout { margin: 1.5em 0; }
.cart-sidebar .widget-title { margin-bottom: 15px; padding-bottom: 10px; font-size: .95em; border-bottom: 3px solid #ececec; }

/* Levering: måderne står under hinanden i deres egen lille tabel */
.shop_table td.shipping__inner { padding: 0; font-size: 1em; line-height: 1.3; border: 0; }
.shipping__table { margin: 0; }
.shipping__table--multiple, .shipping__table--multiple tbody, .shipping__table--multiple tr, .shipping__table--multiple th, .shipping__table--multiple td { display: block; }
.shipping__table--multiple { text-align: left; }
.shipping__table--multiple th { border: 0; }
.shipping__table--multiple td { padding-left: 0; }
ul.shipping__list { margin: 0; padding: 0 .2em; }
li.shipping__list_item { display: flex; align-items: center; min-height: 2em; margin: 0; list-style: none; }
tr.shipping input { margin-top: -2px; margin-bottom: 0; }
.shipping__list_item input { margin: -2px 10px 0 0; }
.shipping__table--multiple .shipping__list_label, .shipping__table--multiple .woocommerce-shipping-calculator, .shipping__table--multiple .woocommerce-shipping-destination { text-align: left; }
.shipping__list_label { flex: 1; margin: 0; padding: .5em 0; font-weight: 400; opacity: .8; }
.shipping__list_item input:checked + .shipping__list_label { font-weight: 700; opacity: 1; }
.woocommerce-shipping-destination, .shipping-calculator-button { font-size: .9em; }
.woocommerce-shipping-calculator { margin-top: .5em; margin-bottom: 0; }
.shipping-calculator-form { margin: 5px 0 0; padding: 15px 15px 10px; background-color: rgba(0, 0, 0, .03); border-radius: 5px; }

@media (max-width: 849px) {
	.shop_table { font-size: .9em; }
	.shop_table .product-name { min-width: 80px; }
	.shop_table .product-remove { position: relative; width: 0; }
	.shop_table .product-remove a.remove { position: absolute; top: 10px; left: 0; line-height: 18px !important; font-size: 18px !important; }
	.shop_table .mobile-product-price { margin: .5em 0; }
	.shipping__table--multiple th { width: 50%; }
}
@media (max-width: 549px) {
	.shop_table .product-price, .shop_table .product-subtotal { display: none; }
	.product-quantity { text-align: right; }
	.sm-touch-scroll { overflow: auto; -webkit-overflow-scrolling: touch; }
}

/* ---------- Kasse ---------- */

form.checkout h3 { padding-top: 10px; font-size: 1.1em; font-weight: bolder; text-transform: uppercase; overflow: hidden; }
form.checkout h3#ship-to-different-address { padding-top: 0; }
#ship-to-different-address label { display: inline-block; margin-right: 10px; font-weight: 400; text-transform: none; }
.form-row-wide { clear: both; }
@media (min-width: 550px) {
	.form-row-first, .form-row-last { float: left; width: 48%; }
	.form-row-first { margin-right: 4%; }
}
input.input-checkbox, .form-row input.input-checkbox { display: inline-block; margin: 0 8px 0 4px; }
#billing_address_2_field > label, #shipping_address_2_field > label { width: 0; overflow: hidden; white-space: nowrap; opacity: 0; }
.woocommerce-billing-fields { padding-top: 15px; border-top: 2px solid #ddd; }
.shop_table tfoot th { font-size: 85%; text-transform: inherit; letter-spacing: 0; }
ul.payment_methods li { margin: 0; list-style: none; }
ul.payment_methods li + li { padding-top: 7px; border-top: 1px solid #ececec; }
.payment_methods .payment_box p { margin-bottom: .5em; font-size: .9em; }
#place_order { width: 100%; margin-right: 0; padding-top: .5em; padding-bottom: .5em; font-size: 1.2em; line-height: 1.2; white-space: normal; }
.woocommerce-privacy-policy-text { font-size: 85%; }
.woocommerce-privacy-policy-text p { margin-bottom: .5em; }

/* Landevælger (select2) ser ud som de øvrige rullelister */
.select2-container { margin-bottom: 1em; text-align: left; }
.select2-container .select2-selection--single {
	height: 2.507em;
	max-width: 100%;
	margin-bottom: -4px;
	padding: 0 1.4em 0 .75em;
	vertical-align: middle;
	font-size: .97em;
	line-height: 2.507em;
	color: #333;
	background-color: #fff;
	background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
	background-position: right .45em top 50%;
	background-repeat: no-repeat;
	background-size: auto 16px;
	border: 1px solid #ddd;
	border-radius: 0;
	box-shadow: inset 0 -1.4em 1em 0 rgba(0, 0, 0, .02);
}
.select2-container .select2-selection--single .select2-selection__rendered { padding: 0; line-height: inherit; }
.select2-container--default .select2-selection--single .select2-selection__arrow { width: 30px; height: 2.507em; }
.select2-container--default .select2-selection--single .select2-selection__arrow b { border-color: transparent; }
@media (max-width: 849px) { .select2-container .select2-selection--single { font-size: 1rem; } }
@media (max-width: 549px) { #billing_address_2_field > label, #shipping_address_2_field > label { display: none; } }
.woocommerce-invalid input, .woocommerce-invalid select { border-color: var(--fs-color-alert); }
/* Mens kurv, kasse eller en linje i kurv-skuffen opdateres: området dæmpes og får et ventehjul. */
.woocommerce-cart .cart_totals:has(.blockUI), .woocommerce-cart .woocommerce-cart-form:has(.blockUI), .woocommerce-checkout-review-order:has(.blockUI), .woocommerce-mini-cart-item:has(.blockUI) { opacity: .5; }
.woocommerce-cart .cart_totals .blockUI.blockOverlay, .woocommerce-cart .woocommerce-cart-form .blockUI.blockOverlay, .woocommerce-checkout-review-order .blockUI.blockOverlay, .woocommerce-mini-cart-item .blockUI.blockOverlay { background-color: transparent !important; opacity: .5 !important; }
.woocommerce-cart .cart_totals .blockUI.blockOverlay::before, .woocommerce-cart .woocommerce-cart-form .blockUI.blockOverlay::before, .woocommerce-checkout-review-order .blockUI.blockOverlay::before, .woocommerce-mini-cart-item .blockUI.blockOverlay::before { content: ""; position: absolute; top: 50%; left: 50%; display: block; width: 30px; height: 30px; margin-top: -.5em; margin-left: -.5em; font-size: 2em; line-height: 1; text-align: center; pointer-events: none; border: 3px solid rgba(0, 0, 0, .1); border-left-color: var(--fs-color-primary); border-radius: 50%; animation: spin .6s linear infinite; }

/* ---------- Konto og login ---------- */

.account-container, .my-account { }
.woocommerce-form-login .button, .woocommerce-form-register .button { margin-bottom: 0; }
.lost_password { font-size: .9em; }
.woocommerce-MyAccount-navigation ul { margin: 0; list-style: none; }
.woocommerce-MyAccount-navigation li { margin: 0; list-style: none; border-bottom: 1px solid #ececec; }
.woocommerce-MyAccount-navigation li a { display: block; padding: 10px 0; }
.woocommerce-MyAccount-navigation li.is-active a { font-weight: 700; color: #111; }

/* ---------- Besparelse på produktsiden ---------- */

.pge-savings { display: inline-block; width: fit-content; max-width: 75%; margin: 10px 0 16px; padding: 8px 12px; background: #f6efe1; border-left: 4px solid #9a762c; border-radius: 4px; box-sizing: border-box; }
.pge-savings-line { font-size: 14px; line-height: 1.4; color: #1a2f5a; }
.pge-savings-line + .pge-savings-line { margin-top: 4px; }
.pge-save-amount { font-weight: 700; color: #8b0000; }

/* Efter "Tilføj til kurv" med AJAX: knappen skjules, og linket "Se kurv" vises i stedet. */
.add_to_cart_button.added { display: none; }
a.added_to_cart { display: inline-block; padding: 10px 0; font-size: .9em; font-weight: 700; text-transform: uppercase; }
a.added_to_cart::after { content: " \2192"; }
form.cart a.added_to_cart.wc-forward, .message-container .wc-forward { display: none; }
