/* V2 customer pages share a compact account layout without changing shop V1. */
.customer-portal {
	max-width: 1240px;
	margin: 0 auto;
	padding: 28px 20px 64px;
	color: #252525;
}
.customer-portal__breadcrumbs {
	margin: 0 0 18px;
	font-size: 13px;
	color: #606060;
}
.customer-portal__breadcrumbs a { color: inherit; }
.customer-portal__heading {
	margin: 0 0 8px;
	font-size: 32px;
	line-height: 1.2;
	font-weight: 650;
}
.customer-portal__intro {
	max-width: 760px;
	margin: 0 0 26px;
	color: #555;
	line-height: 1.55;
}
.customer-portal__grid {
	display: grid;
	grid-template-columns: repeat(3,minmax(0,1fr));
	gap: 14px;
}
.customer-portal__panel {
	min-width: 0;
	padding: 20px;
	background: #fff;
	border: 1px solid #dededb;
	border-radius: 4px;
}
.customer-portal__panel h2,
.customer-portal__panel h3 {
	margin: 0 0 10px;
	font-size: 18px;
	line-height: 1.3;
}
.customer-portal__panel p { margin: 0 0 12px; color: #555; line-height: 1.5; }
.customer-portal__actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 24px; }
.customer-portal__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 42px;
	padding: 9px 16px;
	border: 1px solid #b9d8ed;
	border-radius: 4px;
	background: #d4eafa;
	color: #202020;
	font: inherit;
	text-decoration: none;
	cursor: pointer;
}
.customer-portal__button:hover,
.customer-portal__button:focus { background: #bdddf3; color: #111; }
.customer-portal__button--primary { background: #f5c832; border-color: #e6b91d; }
.customer-portal__button--primary:hover,
.customer-portal__button--primary:focus { background: #ecc02b; }
.customer-portal__button--quiet { background: #fff; border-color: #c8c8c5; }
.customer-portal__button--danger { background: #fff; border-color: #c35b52; color: #8e241d; }
.customer-portal__button[disabled] { cursor: not-allowed; opacity: .55; }
.customer-portal__form-grid {
	display: grid;
	grid-template-columns: repeat(2,minmax(0,1fr));
	gap: 14px;
}
.customer-portal__field { display: grid; gap: 6px; margin: 0 0 14px; }
.customer-portal__field label { font-weight: 600; }
.customer-portal__field input,
.customer-portal__field textarea,
.customer-portal__field select {
	width: 100%;
	min-height: 42px;
	padding: 9px 11px;
	border: 1px solid #bdbdb9;
	border-radius: 3px;
	background: #fff;
	color: #222;
	font: inherit;
}
.customer-portal__field textarea { min-height: 96px; resize: vertical; }
.customer-portal__notice {
	margin: 0 0 18px;
	padding: 12px 14px;
	border-left: 4px solid #3b8a62;
	background: #eef7f1;
}
.customer-portal__notice--error { border-color: #b54036; background: #fff1ef; }
.customer-portal__table-wrap { width: 100%; overflow-x: auto; }
.customer-portal__table { width: 100%; border-collapse: collapse; }
.customer-portal__table th,
.customer-portal__table td { padding: 12px 10px; border-bottom: 1px solid #e1e1df; text-align: left; vertical-align: top; }
.customer-portal__table th { font-weight: 650; background: #f7f7f5; }
.customer-portal__wishlist-list { display: grid; gap: 18px; }
.customer-portal__wishlist { border-top: 1px solid #d9d9d6; padding-top: 18px; }
.customer-portal__wishlist-title { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.customer-portal__product-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; margin-top: 14px; }
.customer-portal__product {
	display: grid;
	grid-template-columns: 96px minmax(0,1fr);
	gap: 14px;
	align-items: center;
	padding: 12px;
	border: 1px solid #e1e1df;
	border-radius: 4px;
	background: #fff;
}
.customer-portal__product img { display: block; width: 96px; height: 96px; object-fit: contain; }
.customer-portal__product h3 { margin: 0 0 6px; font-size: 16px; }
.customer-portal__muted { color: #666; font-size: 14px; }
.customer-portal__price { font-weight: 700; }
.customer-portal__discount { color: #c23232; }
.customer-portal__cart-note { margin-top: 14px; color: #5b5b5b; font-size: 14px; }
.customer-portal__request-list { display: grid; gap: 14px; }
.customer-portal__request-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.customer-portal__request-heading p { margin: 0; color: #666; }
.customer-portal__status { display: inline-block; padding: 6px 10px; border-radius: 3px; background: #f1f1ed; white-space: nowrap; }
.customer-portal__review-form { display: grid; gap: 8px; max-width: 680px; }
.customer-portal__review-form label { font-weight: 600; }
.customer-portal__review-form textarea { width: 100%; min-height: 72px; padding: 9px 11px; border: 1px solid #bdbdb9; border-radius: 3px; background: #fff; color: #222; font: inherit; }
.customer-portal__employee-checkout { max-width: 900px; }
.customer-portal__definition-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px 24px; margin: 18px 0 24px; }
.customer-portal__definition-list div { min-width: 0; }
.customer-portal__definition-list dt { color: #666; font-size: 13px; }
.customer-portal__definition-list dd { margin: 3px 0 0; overflow-wrap: anywhere; }
.customer-portal__original-price { color: #656565; text-decoration: line-through; font-size: 14px; }
.customer-portal__discount-callout { color: #a52626; font-weight: 650; }

/* Retain the server-validated V2 cart data while arranging each product like
   a compact catalogue row: image, chosen options and controls stay together. */
.customer-portal-cart {
	float: none !important;
	width: 100% !important;
	max-width: 1240px;
	margin: 0 auto;
	padding: 20px;
}
.customer-portal-cart > div:first-child {
	float: none !important;
	width: 100% !important;
	margin: 8px 0 20px !important;
}
.customer-portal-cart .customer-portal-cart__item {
	float: none !important;
	width: 100% !important;
	margin: 0 0 14px !important;
	padding: 0 !important;
}
.customer-portal-cart .customer-portal-cart__item > div:first-child {
	display: grid !important;
	grid-template-columns: minmax(150px,220px) minmax(0,1fr);
	align-items: center;
	float: none !important;
	width: 100% !important;
	background: #fff !important;
	border: 1px solid #dededb !important;
	border-radius: 4px;
	overflow: hidden;
}
.customer-portal-cart .customer-portal-cart__item > div:first-child > .col-lg-3,
.customer-portal-cart .customer-portal-cart__item > div:first-child > .col-lg-9 {
	float: none !important;
	width: auto !important;
	min-width: 0;
}
.customer-portal-cart .customer-portal-cart__item > div:first-child > .col-lg-3 {
	padding: 16px !important;
	border-right: 0 !important;
}
.customer-portal-cart .customer-portal-cart__item > div:first-child > .col-lg-9 {
	padding: 18px 20px !important;
}
.customer-portal-cart .customer-portal-cart__item [role="img"] {
	float: none !important;
	width: 100% !important;
	height: 190px !important;
	margin: 0 !important;
	background-position: center !important;
	background-size: contain !important;
}
.customer-portal-cart .customer-portal-cart__item .product-name {
	min-height: 0 !important;
	padding: 0 0 12px !important;
	font-size: 22px !important;
	line-height: 1.3 !important;
	border-bottom: 1px solid #e1e1df !important;
}
.customer-portal-cart .customer-portal-cart__item .product-name a { color: #252525; text-decoration: none; }
.customer-portal-cart #load-checkout-cart-summary {
	float: none !important;
	width: min(100%,520px) !important;
	margin: 18px 0 22px auto;
	padding: 16px 18px;
	border: 1px solid #dededb;
	border-radius: 4px;
	background: #fff;
	font-size: 17px !important;
}
.customer-portal-cart .customer-portal__discount-callout { display: flex; flex-wrap: wrap; gap: 4px; }

/* Native details keeps the account menu usable with mouse, touch and keyboard. */
.customer-account-menu { position: relative; }
.customer-account-menu > summary { list-style: none; cursor: pointer; }
.customer-account-menu > summary::-webkit-details-marker { display: none; }
.customer-account-menu__popover {
	position: absolute;
	right: 0;
	top: 100%;
	z-index: 1200;
	width: min(300px,calc(100vw - 24px));
	padding: 12px;
	border: 1px solid #dededb;
	border-radius: 5px;
	background: #fff;
	box-shadow: 0 8px 24px rgba(0,0,0,.16);
}
.customer-account-menu__greeting { padding: 8px 10px 12px; font-weight: 650; }
.customer-account-menu__popover a {
	display: block;
	padding: 10px;
	border-top: 1px solid #e3e3e0;
	color: #282828;
	text-decoration: none;
}
.customer-account-menu__popover a:hover,
.customer-account-menu__popover a:focus { background: #f4f4f1; }

/* On desktop the menu opens on hover like the reference design; the native
   disclosure still preserves click, keyboard and touch behavior. */
@media (hover: hover) and (pointer: fine) {
	.customer-account-menu:hover > .customer-account-menu__popover,
	.customer-account-menu:focus-within > .customer-account-menu__popover { display: block; }
}

@media (max-width: 900px) {
	.customer-portal__grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 640px) {
	/* The mobile account icon sits on the left side of the compact header. Anchor
	   its flyout to that icon so the bounded popover stays inside the viewport. */
	.customer-account-menu__popover { left: 0; right: auto; }
	.customer-portal { padding: 20px 14px 48px; }
	.customer-portal__heading { font-size: 26px; }
	.customer-portal__grid,
	.customer-portal__form-grid,
	.customer-portal__product-list { grid-template-columns: 1fr; }
	.customer-portal__panel { padding: 16px; }
	.customer-portal__product { grid-template-columns: 76px minmax(0,1fr); }
	.customer-portal__product img { width: 76px; height: 76px; }
	.customer-portal__table th,
	.customer-portal__table td { padding: 9px 7px; }
	.customer-portal__request-heading { display: block; }
	.customer-portal__status { margin-top: 10px; white-space: normal; }
	.customer-portal__definition-list { grid-template-columns: 1fr; }
	/* Preserve a visible thumbnail without letting the legacy desktop grid widen
	   the document on phones; product text and its controls take the remaining space. */
	.customer-portal-cart { padding: 16px 12px 34px; }
	.customer-portal-cart .customer-portal-cart__item > div:first-child {
		grid-template-columns: 94px minmax(0,1fr);
		align-items: start;
	}
	.customer-portal-cart .customer-portal-cart__item > div:first-child > .col-lg-3 { padding: 10px !important; }
	.customer-portal-cart .customer-portal-cart__item > div:first-child > .col-lg-9 { padding: 12px !important; }
	.customer-portal-cart .customer-portal-cart__item [role="img"] { height: 112px !important; }
	.customer-portal-cart .customer-portal-cart__item .product-name { font-size: 18px !important; }
	.customer-portal-cart #load-checkout-cart-summary { width: 100% !important; padding: 14px; }
}
