/*
-------------------------------------------------------------|
---              Merchandise styles for SMG.              ---|
---                Coffee Creative Studio                 ---|
-------------------------------------------------------------|
Every rule is scoped to a body class added only in merchandise context
(inc/merchandise.php -> smg_merch_body_class). Nothing here can reach a
vehicle page, the showroom, or the site header/footer.

  .smg-merch                 merch archive, merch single, cart, checkout, account
  .smg-merch-archive-page    merchandise category archive only
  .smg-merch-single          single merchandise product only

Tokens come from smg.css :root — colours are not redeclared here.
-------------------------------------------------------------|
                                                       INDEX |
-------------------------------------------------------------|
- LOCAL TOKENS
- SHARED PIECES
- SHOP NAV BAR
- ARCHIVE HEADER
- ARCHIVE LAYOUT + SIDEBAR
- TOOLBAR
- PRODUCT GRID
- PRODUCT CARD
- PAGINATION
- EMPTY STATE
- SINGLE PRODUCT
- SINGLE: GALLERY
- SINGLE: SUMMARY
- SINGLE: TABS / RELATED
- CART / CHECKOUT / ACCOUNT
- RESPONSIVE
-------------------------------------------------------------|
*/

/*
-------------------------------------------------------------|
                                                LOCAL TOKENS |
-------------------------------------------------------------|
*/

body:not(.home).smg-merch #primary > :first-child:not(.smg_custom_banner) {
	margin-top: 0;
}

.smg-merch {
	--merch-gap: 34px;
	--merch-rule: var(--color-grey-light);
	--merch-muted: var(--color-grey-dark);
	--merch-tile: var(--color-grey-lightest);
	--merch-sidebar-width: 210px;
	--merch-media-width: 420px;
}

/*
-------------------------------------------------------------|
                                               SHARED PIECES |
-------------------------------------------------------------|
*/

.smg-merch .smg-merch-eyebrow {
	display:none;
	/* margin: 0 0 8px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--merch-muted); */
}

.smg-merch .woocommerce-breadcrumb {
	display:none;
	/* margin: 18px 0 0;
	font-size: var(--fontsize-body-small);
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--merch-muted); */
}

.smg-merch .woocommerce-breadcrumb a {
	color: var(--merch-muted);
	text-decoration: none;
}

.smg-merch .woocommerce-breadcrumb a:hover {
	color: var(--color-black);
	text-decoration: underline;
}

.smg-merch a:focus-visible,
.smg-merch button:focus-visible,
.smg-merch select:focus-visible,
.smg-merch input:focus-visible {
	outline: 2px solid var(--color-black);
	outline-offset: 2px;
}

/*
-------------------------------------------------------------|
                                                SHOP NAV BAR |
-------------------------------------------------------------|
*/

.smg-merch .smg-merch-shopnav {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 10px 25px;
	padding: 14px 0;
	border-bottom: 1px solid var(--merch-rule);
}

.smg-merch .smg-merch-shopnav__utils {
	display: flex;
	align-items: center;
	gap: 22px;
}

.smg-merch .smg-merch-shopnav__link {
	display: inline-block;
	padding: 2px 0;
	border-bottom: 2px solid transparent;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--color-black);
	text-decoration: none;
	transition: border-color 0.12s ease;
}

.smg-merch .smg-merch-shopnav__link:hover {
	border-bottom-color: var(--merch-rule);
}

.smg-merch .smg-merch-shopnav__link.is-current {
	border-bottom-color: var(--color-black);
}

.smg-merch .smg-merch-shopnav__cart {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	height: 32px;
	padding: 0 14px;
	border: 1px solid var(--color-black);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--color-black);
	text-decoration: none;
	transition: background-color 0.12s ease, color 0.12s ease;
}

.smg-merch .smg-merch-shopnav__cart:hover,
.smg-merch .smg-merch-shopnav__cart.is-current {
	background-color: var(--color-black);
	color: var(--color-white);
}

.smg-merch .smg-merch-shopnav__cart-count {
	min-width: 20px;
	height: 18px;
	padding: 0 5px;
	background-color: var(--merch-tile);
	color: var(--color-black);
	font-size: 10px;
	line-height: 18px;
	text-align: center;
	font-variant-numeric: tabular-nums;
	box-sizing: border-box;
}

.smg-merch .smg-merch-shopnav__cart.has-items .smg-merch-shopnav__cart-count {
	background-color: var(--color-black);
	color: var(--color-white);
}

.smg-merch .smg-merch-shopnav__cart:hover .smg-merch-shopnav__cart-count,
.smg-merch .smg-merch-shopnav__cart.is-current .smg-merch-shopnav__cart-count {
	background-color: var(--color-white);
	color: var(--color-black);
}

/*
-------------------------------------------------------------|
                                              ARCHIVE HEADER |
-------------------------------------------------------------|
*/

.smg-merch .smg-merch-archive {
	padding: var(--spacing-tertiary) 0 var(--spacing-primary);
}

.smg-merch .smg-merch-archive__header {
	padding-bottom: var(--spacing-tertiary);
	margin-bottom: var(--spacing-secondary);
	border-bottom: 2px solid var(--color-black);
}

.smg-merch .smg-merch-archive__title {
	margin: 0;
	font-size: var(--fontsize-heading-secondary);
	font-weight: 800;
	line-height: 1;
	text-transform: none;
}

.smg-merch .smg-merch-archive__intro {
	max-width: 620px;
	margin-top: 15px;
	color: var(--merch-muted);
}

.smg-merch .smg-merch-archive__intro p:last-child {
	margin-bottom: 0;
}

/*
-------------------------------------------------------------|
                                    ARCHIVE LAYOUT + SIDEBAR |
-------------------------------------------------------------|
*/

.smg-merch .smg-merch-archive__layout {
	display: grid;
	grid-template-columns: var(--merch-sidebar-width) minmax(0, 1fr);
	gap: 60px;
	align-items: start;
}

.smg-merch .smg-merch-archive__main {
	min-width: 0;
}

.smg-merch .smg-merch-sidebar {
	position: sticky;
	top: 120px;
}

.smg-merch .smg-merch-nav__label {
	margin: 0 0 14px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--color-black);
}

.smg-merch .smg-merch-nav__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.smg-merch .smg-merch-nav__item > a {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 10px;
	padding: 11px 0 11px 14px;
	border-top: 1px solid var(--merch-rule);
	border-left: 2px solid transparent;
	font-size: 14px;
	line-height: 1.3;
	color: var(--color-black);
	text-decoration: none;
	transition: border-color 0.12s ease;
}

.smg-merch .smg-merch-nav__list--root .smg-merch-nav__item > a {
	border-top: 0;
}

.smg-merch .smg-merch-nav__item > a:hover {
	border-left-color: var(--merch-rule);
}

.smg-merch .smg-merch-nav__item.is-current > a {
	border-left-color: var(--color-black);
	font-weight: 700;
}

.smg-merch .smg-merch-nav__count {
	flex: 0 0 auto;
	font-size: 11px;
	font-weight: 400;
	color: var(--merch-muted);
	font-variant-numeric: tabular-nums;
}

.smg-merch .smg-merch-nav__list--depth-1 .smg-merch-nav__item > a {
	padding-left: 28px;
	font-size: 13px;
	color: var(--merch-muted);
}

.smg-merch .smg-merch-nav__list--depth-1 .smg-merch-nav__item.is-current > a {
	color: var(--color-black);
}

/*
-------------------------------------------------------------|
                                                     TOOLBAR |
-------------------------------------------------------------|
*/

.smg-merch .woocommerce-message a {
	line-height: 25px;
    margin-left: 10px;
}

.smg-merch .smg-merch-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 15px;
	padding-bottom: 18px;
	margin-bottom: var(--spacing-tertiary);
	border-bottom: 1px solid var(--merch-rule);
}

.smg-merch .smg-merch-toolbar .woocommerce-result-count {
	order: 1;
	margin: 0;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--merch-muted);
}

.smg-merch .smg-merch-toolbar .woocommerce-ordering {
	order: 2;
	margin: 0;
}

.smg-merch .smg-merch-toolbar .woocommerce-ordering select,
.smg-merch .smg-merch-toolbar select.orderby {
	height: 42px;
	padding: 0 38px 0 14px;
	border: 1px solid var(--color-black);
	border-radius: 0;
	background-color: var(--color-white);
	background-image: linear-gradient(45deg, transparent 50%, var(--color-black) 50%), linear-gradient(135deg, var(--color-black) 50%, transparent 50%);
	background-position: calc(100% - 18px) 19px, calc(100% - 13px) 19px;
	background-size: 5px 5px, 5px 5px;
	background-repeat: no-repeat;
	-webkit-appearance: none;
	appearance: none;
	font-size: var(--fontsize-button);
	font-weight: 600;
	cursor: pointer;
}

.smg-merch .smg-merch-toolbar .woocommerce-notices-wrapper {
	order: 0;
	flex: 1 0 100%;
}

/*
-------------------------------------------------------------|
                                                PRODUCT GRID |
-------------------------------------------------------------|
*/

.smg-merch ul.products {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: var(--merch-gap);
	list-style: none;
	margin: 0;
	padding: 0;
}

.smg-merch ul.products::before,
.smg-merch ul.products::after {
	content: none;
	display: none;
}

.smg-merch ul.products li.product {
	width: auto;
	max-width: none;
	margin: 0;
	padding: 0;
	float: none;
	clear: none;
	list-style: none;
}

/* Related products run full width, so they can take a fourth column */
.smg-merch-single .related ul.products,
.smg-merch-single .up-sells ul.products {
	grid-template-columns: repeat(4, minmax(0, 1fr));
}

/*
-------------------------------------------------------------|
                                                PRODUCT CARD |
-------------------------------------------------------------|
*/

.smg-merch li.smg-merch-card {
	display: flex;
	flex-direction: column;
}

.smg-merch .smg-merch-card__link {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	color: inherit;
	text-decoration: none;
}

.smg-merch .smg-merch-card__media {
	position: relative;
	aspect-ratio: 1 / 1;
	background-color: var(--merch-tile);
	overflow: hidden;
}

.smg-merch .smg-merch-card__media img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: contain;
	padding: 12%;
	display: block;
	transition: transform 0.45s ease;
	box-sizing: border-box;
}

.smg-merch li.smg-merch-card:hover .smg-merch-card__media img {
	transform: scale(1.05);
}

.smg-merch .smg-merch-card__flag {
	position: absolute;
	top: 0;
	left: 0;
	z-index: 2;
	padding: 5px 11px;
	background-color: var(--color-black);
	color: var(--color-white);
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 0.1em;
	line-height: 1.6;
	text-transform: uppercase;
}

.smg-merch .smg-merch-card__flag--muted {
	background-color: var(--color-grey-normal);
}

.smg-merch .smg-merch-card__body {
	flex: 1 1 auto;
	padding: 16px 0 0;
}

.smg-merch .smg-merch-card__title {
	margin: 0 0 5px;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.35;
	text-transform: none;
	letter-spacing: 0;
}

.smg-merch .smg-merch-card__price,
.smg-merch .smg-merch-card__price .amount {
	font-size: 15px;
	font-weight: 600;
	color: var(--color-black);
}

.smg-merch .smg-merch-card__price del,
.smg-merch .smg-merch-card__price del .amount {
	margin-right: 6px;
	font-weight: 400;
	color: var(--color-grey-normal);
}

.smg-merch .smg-merch-card__price ins {
	text-decoration: none;
}

.smg-merch .smg-merch-card__actions {
	padding-top: 14px;
}

.smg-merch .smg-merch-card__actions .button {
	display: block;
	width: 100%;
	text-align: center;
}

.smg-merch .smg-merch-card__actions .added_to_cart {
	display: block;
	margin-top: 8px;
	font-size: var(--fontsize-body-small);
	text-align: center;
	color: var(--merch-muted);
}

/*
-------------------------------------------------------------|
                                                  PAGINATION |
-------------------------------------------------------------|
*/

.smg-merch .woocommerce-pagination {
	margin-top: var(--spacing-secondary);
	padding-top: var(--spacing-tertiary);
	border-top: 1px solid var(--merch-rule);
}

.smg-merch .woocommerce-pagination ul.page-numbers {
	display: flex;
	gap: 6px;
	list-style: none;
	margin: 0;
	padding: 0;
	border: 0;
}

.smg-merch .woocommerce-pagination ul.page-numbers li {
	margin: 0;
	border: 0;
}

.smg-merch .woocommerce-pagination .page-numbers {
	display: inline-block;
	min-width: 40px;
	height: 40px;
	padding: 0 10px;
	border: 1px solid var(--merch-rule);
	line-height: 38px;
	text-align: center;
	font-size: 14px;
	font-weight: 600;
	color: var(--color-black);
	text-decoration: none;
}

.smg-merch .woocommerce-pagination .page-numbers.current,
.smg-merch .woocommerce-pagination .page-numbers:hover {
	border-color: var(--color-black);
	background-color: var(--color-black);
	color: var(--color-white);
}

/*
-------------------------------------------------------------|
                                                 EMPTY STATE |
-------------------------------------------------------------|
*/

.smg-merch .smg-merch-empty {
	padding: var(--spacing-primary) var(--spacing-tertiary);
	border: 1px solid var(--merch-rule);
	text-align: center;
}

.smg-merch .smg-merch-empty p {
	margin-bottom: var(--spacing-tertiary);
	color: var(--merch-muted);
}

/*
-------------------------------------------------------------|
                                              SINGLE PRODUCT |
-------------------------------------------------------------|
*/

/*
 * Fixed media column rather than a fraction: the gallery keeps a sane physical
 * size on wide screens instead of scaling with the container, and the summary
 * takes whatever is left.
 */
body.smg-merch-single div.product.smg-merch-product {
	display: grid;
	grid-template-columns: minmax(0, var(--merch-media-width)) minmax(0, 1fr);
	gap: 60px;
	align-items: start;
	padding: var(--spacing-secondary) 0 var(--spacing-primary);
}

body.smg-merch-single .smg-merch-product__media {
	min-width: 0;
}

body.smg-merch-single .smg-merch-product__media img.zoomImg {
    background-color: var(--merch-tile);
}

body.smg-merch-single .smg-merch-product__summary {
	/* position: sticky; */
	/* top: 120px; */
	min-width: 0;
	width: auto !important;
	float: none;
	margin: 0;
}

body.smg-merch-single .smg-merch-product__extras {
	grid-column: 1 / -1;
	min-width: 0;
}

/*
-------------------------------------------------------------|
                                             SINGLE: GALLERY |
-------------------------------------------------------------|
*/

/*
 * The theme floats the gallery left with no width, which collapses it and
 * throws the zoom trigger next to the title. Reset it inside the grid.
 */
body.smg-merch-single div.product .woocommerce-product-gallery {
	position: relative;
	float: none;
	width: 100%;
	max-width: var(--merch-media-width);
	margin: 0;
	background-color: var(--merch-tile);
}

body.smg-merch-single div.product .woocommerce-product-gallery .woocommerce-product-gallery__wrapper {
	margin: 0;
}

body.smg-merch-single div.product .woocommerce-product-gallery__image img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: contain;
	padding: 7%;
	box-sizing: border-box;
}

body.smg-merch-single div.product .woocommerce-product-gallery .woocommerce-product-gallery__trigger {
	top: 12px;
	right: 12px;
	width: 36px;
	height: 36px;
	background-color: var(--color-white);
	border: 1px solid var(--merch-rule);
	line-height: 36px;
	text-align: center;
	text-decoration: none;
	font-size: 15px;
}

body.smg-merch-single div.product .woocommerce-product-gallery .flex-control-thumbs {
	display: grid;
	grid-template-columns: repeat(5, minmax(0, 1fr));
	gap: 8px;
	margin: 8px 0 0;
	padding: 0;
	background-color: var(--color-white);
}

body.smg-merch-single div.product .woocommerce-product-gallery .flex-control-thumbs li {
	width: auto;
	float: none;
	margin: 0;
	background-color: var(--merch-tile);
}

body.smg-merch-single div.product .woocommerce-product-gallery .flex-control-thumbs li img {
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: contain;
	padding: 8%;
	box-sizing: border-box;
}

body.smg-merch-single .onsale {
	position: absolute;
	top: 0;
	left: 0;
	z-index: 2;
	min-height: 0;
	min-width: 0;
	margin: 0;
	padding: 6px 13px;
	border-radius: 0;
	background-color: var(--color-black);
	color: var(--color-white);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.1em;
	line-height: 1.6;
	text-transform: uppercase;
}

/*
-------------------------------------------------------------|
                                             SINGLE: SUMMARY |
-------------------------------------------------------------|
*/

body.smg-merch-single .product_title {
	margin: 0 0 12px;
	font-size: var(--fontsize-heading-tertiary);
	font-weight: 800;
	line-height: 1.1;
	text-transform: none;
}

body.smg-merch-single .smg-merch-product__summary p.price {
	margin: 0 0 var(--spacing-tertiary);
	padding-bottom: var(--spacing-tertiary);
	border-bottom: 1px solid var(--merch-rule);
	font-size: var(--fontsize-heading-quarternary);
	font-weight: 700;
	color: var(--color-black);
	line-height: 1.2;
}

body.smg-merch-single .smg-merch-product__summary p.price del,
body.smg-merch-single .smg-merch-product__summary p.price del .amount {
	margin-right: 8px;
	font-weight: 400;
	color: var(--color-grey-normal);
}

body.smg-merch-single .smg-merch-product__summary p.price ins {
	text-decoration: none;
}

body.smg-merch-single .woocommerce-product-details__short-description {
	margin-bottom: var(--spacing-tertiary);
	color: var(--merch-muted);
}

body.smg-merch-single .woocommerce-product-details__short-description p:last-child {
	margin-bottom: 0;
}

body.smg-merch-single .stock {
	margin: 0 0 15px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

body.smg-merch-single form.cart {
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
	gap: 10px;
	margin: 0 0 var(--spacing-tertiary);
}

body.smg-merch-single form.cart.variations_form {
	display: block;
}

body.smg-merch-single form.cart .quantity {
	flex: 0 0 auto;
	margin: 0;
}

body.smg-merch-single form.cart .quantity input.qty {
	width: 78px;
	height: 45px;
	padding: 0 8px;
	border: 1px solid var(--color-black) !important;
	border-radius: 0;
	text-align: center;
	font-size: 15px !important;
	font-weight: 600;
	box-sizing: border-box;
}

body.smg-merch-single form.cart button.single_add_to_cart_button {
	flex: 1 1 200px;
}

body.smg-merch-single form.cart .woocommerce-variation-add-to-cart {
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
	gap: 10px;
}

body.smg-merch-single form.cart table.variations {
	width: 100%;
	margin: 0 0 var(--spacing-tertiary);
	border: 0;
}

body.smg-merch-single form.cart table.variations tr,
body.smg-merch-single form.cart table.variations th,
body.smg-merch-single form.cart table.variations td {
	display: block;
	width: 100%;
	padding: 0;
	border: 0;
	text-align: left;
}

body.smg-merch-single form.cart table.variations th label {
	display: block;
	margin-bottom: 6px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

body.smg-merch-single form.cart table.variations td {
	margin-bottom: 15px;
}

body.smg-merch-single form.cart table.variations select {
	width: 100%;
	height: 45px;
	padding: 0 14px;
	border: 1px solid var(--color-black);
	border-radius: 0;
	background-color: var(--color-white);
	font-size: var(--fontsize-button);
	font-weight: 600;
}

body.smg-merch-single .reset_variations {
	display: inline-block;
	margin-top: 4px;
	font-size: 12px;
	color: var(--merch-muted);
}

body.smg-merch-single .product_meta {
	padding-top: var(--spacing-tertiary);
	border-top: 1px solid var(--merch-rule);
	font-size: 12px;
	color: var(--merch-muted);
}

body.smg-merch-single .product_meta > span {
	display: block;
	margin-bottom: 4px;
}

body.smg-merch-single .product_meta a {
	color: var(--merch-muted);
	text-decoration: underline;
}

body.smg-merch-single .product_meta a:hover {
	color: var(--color-black);
}

body.smg-merch-single .smg-merch-product__back {
	margin: var(--spacing-tertiary) 0 0;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

body.smg-merch-single .smg-merch-product__back a {
	color: var(--color-black);
	text-decoration: none;
	border-bottom: 1px solid var(--color-black);
	padding-bottom: 2px;
}

/*
-------------------------------------------------------------|
                                        SINGLE: TABS/RELATED |
-------------------------------------------------------------|
*/

body.smg-merch-single .woocommerce-tabs {
	padding-top: var(--spacing-secondary);
	border-top: 2px solid var(--color-black);
}

body.smg-merch-single .woocommerce-tabs ul.tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 25px;
	margin: 0 0 var(--spacing-tertiary);
	padding: 0;
	list-style: none;
}

body.smg-merch-single .woocommerce-tabs ul.tabs li {
	margin: 0;
	padding: 0;
}

body.smg-merch-single .woocommerce-tabs ul.tabs li a {
	display: inline-block;
	padding: 0 0 6px;
	border-bottom: 2px solid transparent;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--merch-muted);
	text-decoration: none;
}

body.smg-merch-single .woocommerce-tabs ul.tabs li.active a {
	border-bottom-color: var(--color-black);
	color: var(--color-black);
}

body.smg-merch-single .woocommerce-tabs .panel {
	max-width: 720px;
}

body.smg-merch-single .woocommerce-tabs .panel h2 {
	font-size: var(--fontsize-heading-quarternary);
}

body.smg-merch-single .related,
body.smg-merch-single .up-sells {
	padding-top: var(--spacing-secondary);
	margin-top: var(--spacing-secondary);
	border-top: 1px solid var(--merch-rule);
}

body.smg-merch-single .related > h2,
body.smg-merch-single .up-sells > h2 {
	margin: 0 0 var(--spacing-tertiary);
	font-size: var(--fontsize-heading-quarternary);
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.02em;
}

/*
-------------------------------------------------------------|
                                CART / CHECKOUT / ACCOUNT |
-------------------------------------------------------------|
*/

.smg-merch.woocommerce-cart .site-main,
.smg-merch.woocommerce-checkout .site-main,
.smg-merch.woocommerce-account .site-main {
	padding: var(--spacing-secondary) 0 var(--spacing-primary);
}

/* Nav sits above the block content on these pages */
.smg-merch.woocommerce-cart .smg-merch-shopnav,
.smg-merch.woocommerce-checkout .smg-merch-shopnav,
.smg-merch.woocommerce-account .smg-merch-shopnav {
	margin-bottom: var(--spacing-tertiary);
}

/* Block cart / checkout inputs — borders only, layout left alone */
.smg-merch .wc-block-components-text-input input[type="text"],
.smg-merch .wc-block-components-text-input input[type="email"],
.smg-merch .wc-block-components-text-input input[type="tel"],
.smg-merch .wc-block-components-text-input input[type="number"],
.smg-merch .wc-block-components-textarea,
.smg-merch .wc-block-components-select__select,
.smg-merch .wc-block-components-combobox-control input.components-combobox-control__input,
.smg-merch .wc-blocks-components-select__select {
	border: 1px solid var(--color-grey-light) !important;
	border-radius: 0 !important;
	box-shadow: none;
}

.smg-merch .wc-block-components-text-input.is-active input,
.smg-merch .wc-block-components-text-input input:focus,
.smg-merch .wc-block-components-textarea:focus,
.smg-merch .wc-block-components-select__select:focus,
.smg-merch .wc-blocks-components-select__select:focus {
	border-color: var(--color-black);
	box-shadow: 0 0 0 1px var(--color-black);
	outline: none;
}

.smg-merch .wc-block-components-panel,
.smg-merch .wc-block-components-totals-wrapper,
.smg-merch .wc-block-cart-items,
.smg-merch .wc-block-components-radio-control__option {
	border-color: var(--color-grey-light);
}

.smg-merch .wc-block-components-radio-control-accordion-option,
.smg-merch .wc-block-components-shipping-rates-control__package {
	border: 1px solid var(--color-grey-light);
	border-radius: 0;
}

.smg-merch .woocommerce-message,
.smg-merch .woocommerce-info,
.smg-merch .woocommerce-error {
	border-top-color: var(--color-black);
	border-radius: 0;
}

/*
-------------------------------------------------------------|
                                                  RESPONSIVE |
-------------------------------------------------------------|
*/

@media screen and (max-width: 1100px) {

	.smg-merch {
		--merch-media-width: 380px;
	}

	.smg-merch .smg-merch-archive__layout {
		gap: 40px;
	}

	body.smg-merch-single div.product.smg-merch-product {
		gap: 45px;
	}
}

@media screen and (max-width: 900px) {

	/* Category sidebar becomes a scrolling chip row above the grid */
	.smg-merch .smg-merch-archive__layout {
		grid-template-columns: minmax(0, 1fr);
		gap: var(--spacing-tertiary);
	}

	.smg-merch .smg-merch-sidebar {
		position: static;
	}

	.smg-merch .smg-merch-nav__label {
		display: none;
	}

	.smg-merch .smg-merch-nav {
		display: flex;
		gap: 8px;
		overflow-x: auto;
		padding-bottom: 6px;
		scrollbar-width: none;
	}

	.smg-merch .smg-merch-nav::-webkit-scrollbar {
		display: none;
	}

	.smg-merch .smg-merch-nav__list {
		display: flex;
		flex: 0 0 auto;
		gap: 8px;
	}

	.smg-merch .smg-merch-nav__list--depth-1 {
		display: none;
	}

	.smg-merch .smg-merch-nav__item > a,
	.smg-merch .smg-merch-nav__list--root .smg-merch-nav__item > a {
		white-space: nowrap;
		padding: 0 16px;
		height: 38px;
		line-height: 36px;
		border: 1px solid var(--merch-rule);
		align-items: center;
	}

	.smg-merch .smg-merch-nav__item.is-current > a {
		border-color: var(--color-black);
		background-color: var(--color-black);
		color: var(--color-white);
	}

	.smg-merch .smg-merch-nav__item.is-current .smg-merch-nav__count {
		color: var(--color-white);
	}

	/* Product stays two-column here — gallery just narrows */
	.smg-merch {
		--merch-media-width: 300px;
	}

	body.smg-merch-single div.product.smg-merch-product {
		gap: 30px;
	}

	body.smg-merch-single .smg-merch-product__summary {
		position: static;
	}
}

@media screen and (max-width: 768px) {

	.smg-merch ul.products,
	.smg-merch-single .related ul.products,
	.smg-merch-single .up-sells ul.products {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 20px;
	}

	/* Below tablet the two-column product finally stacks */
	body.smg-merch-single div.product.smg-merch-product {
		grid-template-columns: minmax(0, 1fr);
		gap: var(--spacing-tertiary);
		padding-top: var(--spacing-tertiary);
	}

	.smg-merch {
		--merch-media-width: 100%;
	}

	body.smg-merch-single div.product .woocommerce-product-gallery {
		max-width: 420px;
	}

	.smg-merch .smg-merch-archive__title {
		font-size: var(--fontsize-heading-tertiary);
	}

	.smg-merch .smg-merch-archive__header {
		margin-bottom: var(--spacing-tertiary);
	}

	.smg-merch .smg-merch-toolbar {
		flex-direction: column;
		align-items: stretch;
	}

	.smg-merch .smg-merch-toolbar .woocommerce-ordering select {
		width: 100%;
	}

	.smg-merch .smg-merch-shopnav {
		gap: 10px 15px;
	}

	.smg-merch .smg-merch-shopnav__utils {
		gap: 15px;
	}
}

@media screen and (max-width: 480px) {

	.smg-merch .smg-merch-card__title,
	.smg-merch .smg-merch-card__price,
	.smg-merch .smg-merch-card__price .amount {
		font-size: 14px;
	}

	.smg-merch .smg-merch-shopnav {
		justify-content: space-between;
	}

	.smg-merch .smg-merch-shopnav__link {
		font-size: 10px;
		letter-spacing: 0.08em;
	}

	body.smg-merch-single form.cart .quantity input.qty,
	body.smg-merch-single form.cart button.single_add_to_cart_button {
		flex: 1 1 100%;
		width: 100%;
	}
}

@media (prefers-reduced-motion: reduce) {

	.smg-merch .smg-merch-card__media img,
	.smg-merch .smg-merch-nav__item > a,
	.smg-merch .smg-merch-shopnav__cart {
		transition: none;
	}

	.smg-merch li.smg-merch-card:hover .smg-merch-card__media img {
		transform: none;
	}
}