/* Scoped copy of prototypy-koszyka/styles.css (.config-summary / .config-details / .details-groups). */

/*
 * Cart table product chrome: 66×84 thumbnail, name beside, configuration under
 * the name. Mini-cart keeps Kadence markup (floated thumbnail) — do not restyle
 * ul.cart_list with .ed-ccd-product.
 */
body .ed-ccd-product {
	display: grid;
	grid-template-columns: 66px minmax(0, 1fr);
	column-gap: 14px;
	align-items: start;
	min-width: 0;
}

body .ed-ccd-product__link {
	display: grid;
	grid-column: 1 / -1;
	grid-template-columns: 66px minmax(0, 1fr);
	column-gap: 14px;
	align-items: start;
	min-width: 0;
	color: inherit;
	text-decoration: none;
}

body .ed-ccd-product__media {
	grid-column: 1;
}

body .ed-ccd-product__media,
body .ed-ccd-product__media img {
	display: block;
	width: 66px;
	height: 84px;
	max-width: 66px;
	object-fit: cover;
	object-position: center;
}

body .ed-ccd-product__name {
	grid-column: 2;
	min-width: 0;
	color: #1a202c;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.35;
}

body .ed-ccd-product__link:hover .ed-ccd-product__name {
	text-decoration: underline;
}

body .ed-ccd-product > :not(.ed-ccd-product__link):not(.ed-ccd-product__media):not(.ed-ccd-product__remove) {
	grid-column: 2;
	min-width: 0;
}

.woocommerce-cart-form table.shop_table.cart th.product-thumbnail,
.woocommerce-cart-form table.shop_table.cart td.product-thumbnail,
.woocommerce-cart-form table.shop_table.cart th.product-remove,
.woocommerce-cart-form table.shop_table.cart td.product-remove {
	display: none;
}

/*
 * Woo mobile shop_table_responsive: td::before = data-title (“Produkt”) and
 * text-align:right !important. Hide the label; keep the name left like desktop.
 * × sits at the far right of the name cell (mini-cart), not over the thumbnail.
 */
.woocommerce-cart-form table.shop_table.cart td.product-name {
	position: relative;
	padding-right: 36px;
	text-align: left !important;
}

.woocommerce-cart-form table.shop_table.cart td.product-name .ed-ccd-product__remove {
	position: absolute;
	top: 8px;
	right: 8px;
	left: auto;
	z-index: 2;
	transform: none;
}

.woocommerce-cart-form table.shop_table.cart td.product-name::before {
	content: none;
	display: none;
}

/*
 * Flatten chrome in the name cell so the image floats and the stack sits under
 * the title (same name→config gap as mini-cart), not below the 84px image row.
 */
.woocommerce-cart-form table.shop_table.cart td.product-name > .ed-ccd-product,
.woocommerce-cart-form table.shop_table.cart td.product-name > .ed-ccd-product .ed-ccd-product__link {
	display: contents;
}

.woocommerce-cart-form table.shop_table.cart td.product-name .ed-ccd-product__media {
	float: left;
	margin: 0 14px 0 0;
}

.woocommerce-cart-form table.shop_table.cart td.product-name .ed-ccd-product__name {
	display: block;
}

.woocommerce-cart-form table.shop_table.cart td.product-name > .ed-ccd-stack {
	box-sizing: border-box;
	width: calc(100% - 66px - 14px);
	max-width: calc(100% - 66px - 14px);
	margin-left: calc(66px + 14px);
}

/*
 * Mini-cart thumbnail is float:left (Kadence: 50px + 8px gap). Keep the stack
 * in the text column like before the chrome override.
 */
.woocommerce ul.cart_list li .ed-ccd-stack,
.woocommerce ul.product_list_widget li .ed-ccd-stack {
	box-sizing: border-box;
	width: calc(100% - 50px - 8px);
	max-width: calc(100% - 50px - 8px);
	margin-left: calc(50px + 8px);
}

/*
 * One column for highlights + details. Same name→config gap on cart and mini-cart.
 */
body .ed-ccd-stack {
	display: grid;
	min-width: 0;
	margin-top: 6px;
	text-align: left;
}

body .ed-ccd.config-summary {
	display: grid;
	gap: 8px;
	margin: 0;
	text-align: left;
}

body .ed-ccd.config-summary p,
body .ed-ccd .details-groups p {
	margin: 0;
	padding: 0;
	color: #555a56;
	font-size: 12px;
	font-weight: 400;
	line-height: 1.5;
	text-align: left;
}

body .ed-ccd.config-summary p strong {
	font-weight: 700;
	color: #2d3748;
}

body .ed-ccd.config-details {
	margin-top: 13px;
	border-top: 1px dashed #cbd5e0;
	color: #2d3748;
	line-height: 1.5;
}

body .ed-ccd.config-details summary {
	display: list-item;
	padding: 10px 0 0;
	margin: 0;
	color: #2b6cb0;
	font-size: 12px;
	font-weight: 800;
	line-height: 1.5;
	text-align: left;
	cursor: pointer;
	list-style-position: inside;
}

body .ed-ccd.config-details summary span {
	color: #718096;
	font-weight: 600;
}

body .ed-ccd.config-details[open] summary {
	margin-bottom: 10px;
}

body .ed-ccd .details-groups {
	display: grid;
	gap: 10px;
	padding: 12px;
	border-radius: 6px;
	background: #f7fafc;
}

body .ed-ccd .details-groups section {
	display: grid;
	gap: 8px;
}

body .ed-ccd .details-groups section + section {
	padding-top: 10px;
	border-top: 1px solid #d8dad6;
}

body .ed-ccd .details-groups h3,
body .ed-ccd .details-groups .ed-ccd-section-title {
	margin: 0;
	padding: 0;
	color: #2d3748;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.08em;
	line-height: 1.5;
	text-align: left;
	text-transform: uppercase;
}

body .ed-ccd .details-groups .woocommerce-Price-amount,
body .ed-ccd .details-groups .amount {
	font-size: inherit;
	font-weight: inherit;
}

/*
 * Thank-you / My Account: same groups as the cart dropdown, always expanded.
 * Extra <br> is an email kses fallback (Outlook / Woo email_improvements).
 */
body .ed-ccd-order {
	text-align: left;
}

body .ed-ccd-order br {
	display: none;
}

/*
 * Checkout order summary: Kadence inline CSS sets
 * `.woocommerce-checkout-review-order-table tr td { text-align: right }`
 * and the name is a text node (no Flux wrap on this storefront). Pin left +
 * cart title weight. Do not add padding-left — there is no thumbnail in the cell.
 */
.woocommerce-checkout .woocommerce-checkout-review-order .woocommerce-checkout-review-order-table tr.cart_item td.product-name {
	font-size: 14px;
	font-weight: 700;
	line-height: 1.35;
	color: #1a202c;
	text-align: left;
}

body.flux-checkout .flux-cart-image.flux-cart-image--checkout,
body.flux-checkout .flux-cart-image.flux-cart-image--checkout img {
	width: 66px;
	height: 84px;
	max-width: 66px;
	object-fit: cover;
	object-position: center;
}

/*
 * Thank-you / My Account: title (link or Flux heading) only — leave × qty
 * and .ed-ccd-order alone.
 */
body.woocommerce-order-received table.shop_table td.product-name > a,
body.woocommerce-view-order table.shop_table td.product-name > a,
body.woocommerce-account table.shop_table td.product-name > a {
	font-size: 14px;
	font-weight: 700;
	line-height: 1.35;
	color: #1a202c;
	text-decoration: none;
}

body.woocommerce-order-received table.shop_table td.product-name > a:hover,
body.woocommerce-view-order table.shop_table td.product-name > a:hover,
body.woocommerce-account table.shop_table td.product-name > a:hover {
	color: #2b6cb0;
	text-decoration: underline;
}

body .flux-cart-order-item__info-name {
	font-size: 14px;
	font-weight: 700;
	line-height: 1.35;
	color: #1a202c;
}
