/*
 * Medad — storefront refinement.
 * Load after medad-style and medad-display. Uses existing theme tokens/assets.
 * Screen-only: the CV builder, printable sheets and print styles remain untouched.
 * View-specific rules intentionally retain the existing mdd-view-* scopes.
 */

@media screen {
	body:not(.mdd-builder-page) {
		--mdd-store-radius: 24px;
		--mdd-store-radius-sm: 16px;
		--mdd-store-shadow: 0 2px 4px -2px rgba(0, 0, 0, .06), 0 16px 38px -28px rgba(0, 0, 0, .22);
		--mdd-store-shadow-hover: 0 4px 10px -6px rgba(0, 0, 0, .10), 0 24px 48px -28px rgba(0, 0, 0, .25);
	}

	/* Navigation: a quiet, opaque surface, clear destinations, comfortable targets. */
	:where(body:not(.mdd-builder-page)) .mdd-header {
		border-bottom-color: color-mix(in srgb, var(--mdd-border) 78%, var(--mdd-surface));
		box-shadow: none;
		transition: box-shadow .18s ease, border-color .18s ease;
	}
	:where(body:not(.mdd-builder-page)) .mdd-header.is-scrolled {
		border-bottom-color: var(--mdd-border);
		box-shadow: 0 8px 24px -20px rgba(0, 0, 0, .32);
	}
	:where(body:not(.mdd-builder-page)) .mdd-header-row { gap: clamp(10px, 1.5vw, 22px); padding-block: 6px; }
	:where(body:not(.mdd-builder-page)) .mdd-header-actions { gap: 6px; }
	:where(body:not(.mdd-builder-page)) .mdd-header .mdd-icon-btn {
		min-width: 44px; height: 44px; border-radius: 14px;
		transition: background-color .16s ease, color .16s ease;
	}
	:where(body:not(.mdd-builder-page)) .mdd-header .mdd-icon-btn[aria-expanded="true"] {
		background: color-mix(in srgb, var(--mdd-accent) 16%, var(--mdd-surface)); color: var(--mdd-accent-text);
	}
	:where(body:not(.mdd-builder-page)) .mdd-header-wa { min-height: 44px; border-radius: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-menu { gap: 4px; }
	:where(body:not(.mdd-builder-page)) .mdd-menu a { min-height: 44px; padding: 11px 14px; border-radius: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-menu .current-menu-item > a,
	:where(body:not(.mdd-builder-page)) .mdd-menu .current-menu-ancestor > a {
		background: color-mix(in srgb, var(--mdd-accent) 13%, var(--mdd-surface)); color: var(--mdd-accent-text);
	}
	:where(body:not(.mdd-builder-page)) .mdd-menu .sub-menu { border-radius: 18px; box-shadow: var(--mdd-store-shadow-hover); }
	:where(body:not(.mdd-builder-page)) .mdd-header-search { padding-block: 16px 20px; background: var(--mdd-surface-2); }
	:where(body:not(.mdd-builder-page)) .mdd-display-panel { padding: 18px; border-radius: 22px; box-shadow: var(--mdd-store-shadow-hover); }
	:where(body:not(.mdd-builder-page)) .mdd-seg { border-radius: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-seg button { border-radius: 10px; }
	:where(body:not(.mdd-builder-page)) .mdd-switch { min-height: 44px; }
	:where(body:not(.mdd-builder-page)) .mdd-nav-display { border-radius: 18px; padding: 16px; }

	/* Category navigation stays scrollable on touch and wraps on desktop. */
	:where(body:not(.mdd-builder-page)) .mdd-catbar { background: var(--mdd-bg); border-bottom-color: transparent; }
	:where(body:not(.mdd-builder-page)) .mdd-catbar ul { gap: 10px; padding-block: 12px; scroll-padding-inline: var(--mdd-gutter); }
	:where(body:not(.mdd-builder-page)) .mdd-catbar a {
		height: auto; min-height: 44px; padding-inline: 7px 16px;
		background: var(--mdd-surface); border-color: var(--mdd-border);
	}
	:where(body:not(.mdd-builder-page)) .mdd-catbar a.is-current { box-shadow: inset 0 0 0 1px var(--mdd-accent); font-weight: var(--mdd-fw-bold); }
	:where(body:not(.mdd-builder-page)) .mdd-catbar img { width: 30px; height: 30px; }
	:where(body:not(.mdd-builder-page)) .mdd-search { padding: 5px; padding-inline-start: 16px; border-radius: 18px; }
	:where(body:not(.mdd-builder-page)) .mdd-search input[type="search"] { min-height: 44px; }
	:where(body:not(.mdd-builder-page)) .mdd-search button { width: 46px; height: 44px; border-radius: 13px; }
	:where(body:not(.mdd-builder-page)) .mdd-suggest { border-radius: 18px; padding: 8px; box-shadow: var(--mdd-store-shadow-hover); }
	:where(body:not(.mdd-builder-page)) .mdd-suggest-item { min-height: 64px; padding: 10px; border-radius: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-suggest-all { min-height: 44px; }

	/* Catalog intro and controls: one readable rhythm rather than floating widgets. */
	:where(body:not(.mdd-builder-page)) .mdd-catalog { padding-top: clamp(24px, 3vw, 40px); padding-bottom: clamp(36px, 5vw, 64px); }
	:where(body:not(.mdd-builder-page)) .mdd-catalog-intro { position: relative; margin-bottom: 24px; padding-inline-start: 20px; }
	:where(body:not(.mdd-builder-page)) .mdd-catalog-intro::before {
		content: ""; position: absolute; inset-inline-start: 0; top: 5px; bottom: 5px; width: 4px; border-radius: 4px; background: var(--mdd-accent);
	}
	:where(body:not(.mdd-builder-page)) .mdd-catalog-intro :is(h1, h2, h3) { margin: 0 0 8px; font-size: var(--mdd-fs-3xl); line-height: 1.4; text-wrap: balance; }
	:where(body:not(.mdd-builder-page)) .mdd-catalog-intro p { margin: 0; max-width: 68ch; color: var(--mdd-muted); line-height: 1.8; }
	:where(body:not(.mdd-builder-page)) .mdd-catalog .mdd-toolbar {
		gap: 14px; margin-bottom: 14px; padding: 14px 16px;
		background: var(--mdd-surface); border: 1px solid var(--mdd-border); border-radius: 20px;
	}
	:where(body:not(.mdd-builder-page)) .mdd-found { display: inline-flex; align-items: center; gap: 8px; color: var(--mdd-text); }
	:where(body:not(.mdd-builder-page)) .mdd-found::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--mdd-accent); }
	:where(body:not(.mdd-builder-page)) .mdd-chips { padding-block: 2px; gap: 8px; }
	:where(body:not(.mdd-builder-page)) .mdd-chip { display: inline-flex; align-items: center; min-height: 44px; padding: 9px 16px; }
	:where(body:not(.mdd-builder-page)) .mdd-sort { min-width: 0; padding: 3px; padding-inline-start: 12px; border-radius: 14px; background: var(--mdd-surface-2); }
	:where(body:not(.mdd-builder-page)) .mdd-sort select { min-width: 0; max-width: 100%; min-height: 44px; padding-inline: 4px; color: var(--mdd-text); }
	:where(body:not(.mdd-builder-page)) .mdd-sort:focus-within { outline: 3px solid var(--mdd-accent); outline-offset: 2px; }
	:where(body:not(.mdd-builder-page)) .mdd-filterbar { align-items: flex-start; flex-wrap: wrap; gap: 14px 20px; margin: 0 0 24px; }
	:where(body:not(.mdd-builder-page)) .mdd-filters-row {
		flex-wrap: wrap; overflow: visible; gap: 8px; padding-block: 2px; margin-inline: 0;
		-webkit-mask-image: none; mask-image: none;
	}
	:where(body:not(.mdd-builder-page)) .mdd-fchip {
		min-height: 44px; padding: 9px 14px; border-style: solid;
		background: var(--mdd-surface); color: var(--mdd-muted); font-size: var(--mdd-fs-sm);
	}
	:where(body:not(.mdd-builder-page)) .mdd-fchip.is-on {
		background: color-mix(in srgb, var(--mdd-accent) 14%, var(--mdd-surface)); color: var(--mdd-text);
		box-shadow: inset 0 0 0 1px var(--mdd-accent);
	}
	:where(body:not(.mdd-builder-page)) .mdd-fchip.is-clear { color: var(--mdd-danger); border-color: color-mix(in srgb, var(--mdd-danger) 30%, var(--mdd-border)); }
	:where(body:not(.mdd-builder-page)) .mdd-catalog-views { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex: none; max-width: 100%; }
	:where(body:not(.mdd-builder-page)) .mdd-viewswitch { gap: 4px; padding: 5px; border-radius: 16px; background: var(--mdd-surface); max-width: 100%; }
	:where(body:not(.mdd-builder-page)) .mdd-viewswitch button {
		width: auto; height: auto; min-width: 44px; min-height: 44px; gap: 7px; padding: 10px 12px; border-radius: 11px;
		font-size: var(--mdd-fs-sm); font-weight: var(--mdd-fw-medium); line-height: 1.4; transition: background-color .16s ease, color .16s ease;
	}
	:where(body:not(.mdd-builder-page)) .mdd-viewswitch button[aria-pressed="true"] { font-weight: var(--mdd-fw-bold); box-shadow: 0 2px 6px -4px rgba(0, 0, 0, .3); }
	:where(body:not(.mdd-builder-page)) .mdd-view-label { display: inline; white-space: nowrap; }
	:where(body:not(.mdd-builder-page)) .mdd-view-caption { margin: 0; color: var(--mdd-muted); font-size: var(--mdd-fs-xs); line-height: 1.6; }
	:where(body:not(.mdd-builder-page)) .mdd-pagination { margin-top: 36px; }
	:where(body:not(.mdd-builder-page)) .mdd-pagination ul { gap: 8px; }
	:where(body:not(.mdd-builder-page)) .mdd-pagination :is(a, span).page-numbers { min-width: 46px; height: 46px; padding-inline: 14px; border-radius: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-pagination a:hover { border-color: var(--mdd-accent); background: color-mix(in srgb, var(--mdd-accent) 10%, var(--mdd-surface)); color: var(--mdd-text); }
	:where(body:not(.mdd-builder-page)) .mdd-empty { border-radius: var(--mdd-store-radius); padding-block: 48px; gap: 10px; }

	/* Classic cards: image, identity, secondary details, then an unmistakable price/CTA. */
	:where(body:not(.mdd-builder-page)) .mdd-grid { gap: clamp(14px, 1.8vw, 24px); align-items: stretch; }
	:where(body:not(.mdd-builder-page)) .mdd-card {
		min-width: 0; border-radius: var(--mdd-store-radius); border-color: var(--mdd-border);
		box-shadow: var(--mdd-store-shadow); background: var(--mdd-surface);
		transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
	}
	:where(body:not(.mdd-builder-page)) .mdd-card-media { background: var(--mdd-surface-2); border-bottom: 1px solid color-mix(in srgb, var(--mdd-border) 60%, transparent); }
	:where(body:not(.mdd-builder-page)) .mdd-card-media img { transition: transform .3s var(--mdd-ease-out); }
	:where(body:not(.mdd-builder-page)) .mdd-card-body { min-width: 0; padding: 18px; gap: 7px; }
	:where(body:not(.mdd-builder-page)) .mdd-card-title { font-size: var(--mdd-fs-lg); line-height: 1.5; overflow-wrap: anywhere; }
	:where(body:not(.mdd-builder-page)) .mdd-card-meta { line-height: 1.7; }
	:where(body:not(.mdd-builder-page)) .mdd-card-cat { display: block; color: var(--mdd-accent-text); font-size: var(--mdd-fs-xs); font-weight: var(--mdd-fw-medium); line-height: 1.7; }
	:where(body:not(.mdd-builder-page)) .mdd-card-desc { margin: 3px 0 0; line-height: 1.8; }
	:where(body:not(.mdd-builder-page)) .mdd-card-body > :nth-last-child(2) { margin-bottom: 0; }
	:where(body:not(.mdd-builder-page)) .mdd-card-state {
		display: inline-flex; align-items: center; align-self: flex-start; gap: 6px; margin: 0;
		font-size: var(--mdd-fs-xs); line-height: 1.6; font-weight: var(--mdd-fw-medium); color: var(--mdd-muted);
	}
	:where(body:not(.mdd-builder-page)) .mdd-card-state::before { content: ""; flex: none; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
	:where(body:not(.mdd-builder-page)) .mdd-card-state.is-available { color: var(--mdd-success); }
	:where(body:not(.mdd-builder-page)) .mdd-card-state.is-unavailable { color: var(--mdd-danger); }
	:where(body:not(.mdd-builder-page)) .mdd-card-buy {
		gap: 10px; padding-top: 14px; margin-top: auto; border-top-color: var(--mdd-border);
	}
	:where(body:not(.mdd-builder-page)) .mdd-card-pricebox { gap: 5px; }
	:where(body:not(.mdd-builder-page)) .mdd-card-pricebox .mdd-ptag { line-height: 1.4; row-gap: 3px; }
	:where(body:not(.mdd-builder-page)) .mdd-card-pricebox .mdd-amount-num { font-size: var(--mdd-fs-2xl); letter-spacing: 0; }
	:where(body:not(.mdd-builder-page)) .mdd-card-more { font-size: var(--mdd-fs-xs); line-height: 1.5; }
	:where(body:not(.mdd-builder-page)) .mdd-card-order {
		min-width: 44px; min-height: 44px; width: auto; height: auto; padding: 10px 14px; gap: 6px; border-radius: 13px;
		line-height: 1.4; text-align: center; box-shadow: none; flex-shrink: 0;
	}
	/* Restore the real label, not a generated substitute, after the original narrow-container rule. */
	:where(body:not(.mdd-builder-page)) .mdd-card-order span {
		position: static; width: auto; height: auto; overflow: visible; clip: auto; clip-path: none; white-space: normal;
	}
	:where(body:not(.mdd-builder-page)) .mdd-card-order.is-ask { background: var(--mdd-surface-2); color: var(--mdd-text); box-shadow: inset 0 0 0 1px var(--mdd-border); }
	:where(body:not(.mdd-builder-page)) .mdd-card-order:focus-visible { outline: 3px solid var(--mdd-text); outline-offset: 3px; }
	:where(body:not(.mdd-builder-page)) .mdd-card:focus-within { border-color: var(--mdd-accent); }
	:where(body:not(.mdd-builder-page)) .mdd-card .mdd-badge,
	:where(body:not(.mdd-builder-page)) .mdd-card .mdd-discount { top: 12px; padding: 4px 9px; border-radius: 9px; font-size: var(--mdd-fs-xs); }
	:where(body:not(.mdd-builder-page)) .mdd-card .mdd-badge { inset-inline-start: 12px; box-shadow: none; }
	:where(body:not(.mdd-builder-page)) .mdd-card .mdd-discount { inset-inline-end: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-card-rating { bottom: 12px; inset-inline-start: 12px; padding: 3px 9px; }

	/* Secondary quick view remains above the stretched product link (z-index: 1). */
	:where(body:not(.mdd-builder-page)) .mdd-card-peek {
		position: relative; z-index: 2; grid-area: peek; display: inline-flex; align-items: center; justify-content: center;
		gap: 7px; min-width: 44px; min-height: 44px; padding: 9px 12px; margin: 2px 0 0;
		border: 1px solid var(--mdd-border); border-radius: 12px; background: var(--mdd-surface-2); color: var(--mdd-muted);
		font: inherit; font-size: var(--mdd-fs-xs); font-weight: var(--mdd-fw-medium); line-height: 1.5; cursor: pointer;
		transition: border-color .16s ease, background-color .16s ease, color .16s ease;
	}
	:where(body:not(.mdd-builder-page)) .mdd-card-peek:hover { background: var(--mdd-surface); color: var(--mdd-text); border-color: var(--mdd-accent); }
	:where(body:not(.mdd-builder-page)) .mdd-card-peek:focus-visible { outline: 3px solid var(--mdd-text); outline-offset: 2px; }
	:where(body:not(.mdd-builder-page)) .mdd-card > template,
	:where(body:not(.mdd-builder-page)) .mdd-card-body > template { display: none !important; }

	@container (max-width: 240px) {
		:where(body:not(.mdd-builder-page)) .mdd-card-buy { flex-wrap: wrap; }
		:where(body:not(.mdd-builder-page)) .mdd-card-pricebox { flex: 1 1 100%; }
		:where(body:not(.mdd-builder-page)) .mdd-card-order { flex: 1 1 100%; width: 100%; }
	}

	/* Compact means denser, not non-actionable. PHP still decides whether an order CTA exists. */
	.mdd-view-compact .mdd-grid[data-mdd-view] { --mdd-cols: 5; gap: 16px; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card { border-radius: 18px; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-body { padding: 12px; gap: 5px; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-title { font-size: var(--mdd-fs-md); -webkit-line-clamp: 2; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-cat { font-size: var(--mdd-fs-xs); }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-buy { flex-wrap: wrap; padding-top: 9px; gap: 8px; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-pricebox { flex: 1 1 100%; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-ptag .mdd-amount-num { font-size: var(--mdd-fs-lg); }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-order { display: inline-flex; width: 100%; min-height: 44px; padding: 8px 10px; font-size: var(--mdd-fs-xs); }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-order span { position: static; width: auto; height: auto; overflow: visible; clip: auto; clip-path: none; white-space: normal; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-go { display: inline-flex; margin-inline-start: auto; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-peek { font-size: var(--mdd-fs-xs); min-height: 44px; padding-inline: 6px; }
	.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-state { font-size: var(--mdd-fs-xs); }

	/* List mode: a calm comparison row with a distinct purchasing column. */
	.mdd-view-list .mdd-grid[data-mdd-view] { grid-template-columns: minmax(0, 1fr); gap: 18px; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card { flex-direction: row; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-media {
		width: clamp(140px, 17vw, 200px); height: auto; aspect-ratio: 1; align-self: flex-start;
		margin: 18px; margin-inline-end: 0; border: 0; border-radius: 18px;
	}
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-body {
		display: grid; flex: 1; min-width: 0; grid-template-columns: minmax(0, 1fr) minmax(160px, 200px);
		grid-template-areas: "title buy" "meta buy" "cat buy" "state buy" "desc buy" "extra peek";
		column-gap: 24px; row-gap: 6px; align-content: start; padding: 22px;
	}
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-title { grid-area: title; font-size: var(--mdd-fs-xl); -webkit-line-clamp: 2; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-meta { grid-area: meta; white-space: normal; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-cat { grid-area: cat; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-state { grid-area: state; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-desc { grid-area: desc; display: block; margin-top: 3px; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-extra { grid-area: extra; display: grid; gap: 10px; margin-top: 6px; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-body > :nth-last-child(2) { margin-bottom: 0; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-buy {
		grid-area: buy; grid-row: auto; align-self: stretch; flex-direction: column; align-items: stretch; justify-content: center;
		margin: 0; padding: 8px 0; padding-inline-start: 22px; border-top: 0; border-inline-start: 1px solid var(--mdd-border); gap: 14px;
	}
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-peek { grid-area: peek; align-self: end; margin: 6px 0 0; margin-inline-start: 22px; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-order { min-height: 46px; width: 100%; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-order span { position: static; width: auto; height: auto; overflow: visible; clip: auto; clip-path: none; }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-ptag .mdd-amount-num { font-size: var(--mdd-fs-2xl); }
	.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-go { display: none; }
	:where(body:not(.mdd-builder-page)) .mdd-card-feats { gap: 6px; }
	:where(body:not(.mdd-builder-page)) .mdd-card-plans { gap: 7px; }
	:where(body:not(.mdd-builder-page)) .mdd-card-plans li { padding: 5px 10px; border-radius: 10px; flex-wrap: wrap; }

	/* Showcase: editorial two-column cards, complete feature summaries and visible actions. */
	.mdd-view-showcase .mdd-grid[data-mdd-view] { --mdd-cols: 2; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(20px, 2.4vw, 30px); }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card { border-radius: 28px; flex-direction: column; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-media {
		aspect-ratio: 4 / 3; margin: 16px 16px 0; border: 0; border-radius: 20px; background: var(--mdd-surface-2);
	}
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-media img { object-fit: contain; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-body { padding: 24px; gap: 9px; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-title { font-size: var(--mdd-fs-xl); line-height: 1.5; -webkit-line-clamp: 2; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-meta { white-space: normal; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-desc { display: block; margin-top: 4px; font-size: var(--mdd-fs-md); line-height: 1.85; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-extra { display: grid; gap: 12px; margin: 5px 0 10px; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-feats { gap: 8px; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-buy { padding-top: 18px; gap: 14px; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-ptag .mdd-amount-num { font-size: var(--mdd-fs-3xl); }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-order { display: inline-flex; min-height: 48px; padding-inline: 20px; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-order span { position: static; width: auto; height: auto; overflow: visible; clip: auto; clip-path: none; white-space: normal; }
	.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-peek { display: inline-flex; min-height: 44px; margin-top: 4px; }

	/* Product detail: a premium purchase card beside a generous reading panel. */
	:where(body:not(.mdd-builder-page)) .mdd-product { gap: clamp(24px, 3vw, 40px); padding-top: 30px; padding-bottom: 28px; }
	:where(body:not(.mdd-builder-page)) .mdd-pcard { border-radius: 28px; box-shadow: var(--mdd-store-shadow); }
	:where(body:not(.mdd-builder-page)) .mdd-pcard-media { background: var(--mdd-surface-2); }
	:where(body:not(.mdd-builder-page)) .mdd-pcard-body { padding: clamp(20px, 2vw, 28px); gap: 18px; }
	:where(body:not(.mdd-builder-page)) .mdd-pcard-cat {
		padding: 5px 12px; border: 1px solid color-mix(in srgb, var(--mdd-accent) 35%, var(--mdd-border)); border-radius: 999px;
		background: color-mix(in srgb, var(--mdd-accent) 9%, var(--mdd-surface)); color: var(--mdd-accent-text); line-height: 1.6;
	}
	:where(body:not(.mdd-builder-page)) .mdd-pcard-title { margin: -4px 0 0; font-size: var(--mdd-fs-2xl); line-height: 1.5; text-wrap: balance; }
	:where(body:not(.mdd-builder-page)) .mdd-pcard-rating { min-height: 44px; margin-top: -10px; }
	:where(body:not(.mdd-builder-page)) .mdd-pcard .mdd-share { width: 44px; height: 44px; top: 14px; inset-inline-end: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-facts { gap: 10px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-facts > div { padding: 12px; border-radius: 14px; border-color: color-mix(in srgb, var(--mdd-border) 75%, var(--mdd-surface)); }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-facts dd { margin-top: 5px; overflow-wrap: anywhere; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-plans legend { margin-bottom: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-plan-list { gap: 10px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-plan-box { min-height: 68px; padding-block: 13px; padding-inline-end: 14px; border-radius: 15px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-plan-name { min-width: 0; gap: 4px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-plan-name b { line-height: 1.7; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-plan input:checked + .mdd-plan-box { box-shadow: inset 0 0 0 1px var(--mdd-accent); }
	:where(body:not(.mdd-builder-page)) .mdd-pcard-price {
		gap: 8px 12px; padding: 16px; border-radius: 16px; background: var(--mdd-surface-2); border: 1px solid var(--mdd-border);
	}
	:where(body:not(.mdd-builder-page)) .mdd-pcard-price .mdd-amount-num { font-size: var(--mdd-fs-3xl); font-weight: var(--mdd-fw-heavy); }
	:where(body:not(.mdd-builder-page)) .mdd-pcard .mdd-btn { min-height: 46px; border-radius: 15px; }
	:where(body:not(.mdd-builder-page)) .mdd-pcard .mdd-order-btn { min-height: 54px; box-shadow: 0 8px 20px -14px var(--mdd-wa); }
	:where(body:not(.mdd-builder-page)) .mdd-pcard-note { padding: 2px 0; line-height: 1.8; }
	:where(body:not(.mdd-builder-page)) .mdd-pcard .mdd-earn { border-radius: 16px; padding: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-tablist { gap: 6px; padding: 5px; border: 1px solid var(--mdd-border); border-radius: 18px; background: var(--mdd-surface); margin-bottom: 18px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-tab { min-height: 48px; padding: 12px 18px; border: 0; margin: 0; border-radius: 13px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-tab.is-active { background: color-mix(in srgb, var(--mdd-accent) 14%, var(--mdd-surface)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--mdd-accent) 45%, var(--mdd-border)); }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-panel { padding: clamp(22px, 3vw, 36px); border-radius: 24px; box-shadow: var(--mdd-store-shadow); }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-lead { font-size: var(--mdd-fs-xl); line-height: 1.9; margin-bottom: 28px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-block + .mdd-block { margin-top: 30px; padding-top: 28px; border-top-style: solid; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-block-title { margin-bottom: 18px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-checklist { gap: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-checklist li { padding: 12px; border-radius: 14px; background: var(--mdd-surface-2); }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-infolist { gap: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-steps { gap: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-steps li { border-radius: 16px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-compare-wrap { border: 1px solid var(--mdd-border); border-radius: 16px; padding: 0; margin-inline: 0; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-compare :is(th, td) { padding: 14px 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-compare .mdd-btn { min-height: 44px; border-radius: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-product .mdd-compare tbody tr:last-child > * { border-bottom: 0; }
	:where(body:not(.mdd-builder-page)) .mdd-related { padding-top: 32px; }
	:where(body:not(.mdd-builder-page)) .mdd-orderbar { border-top-color: var(--mdd-border); }
	:where(body:not(.mdd-builder-page)) .mdd-orderbar .mdd-btn { min-height: 46px; border-radius: 14px; }

	/* Legacy displays: retain their distinctive geometry and JS transforms. */
	:where(body:not(.mdd-builder-page)) .mdd-showcase { --mdd-gap-x: 26px; row-gap: 32px; }
	:where(body:not(.mdd-builder-page)) .mdd-arch { padding-bottom: 10px; }
	:where(body:not(.mdd-builder-page)) .mdd-arch-name { margin-top: 18px; font-size: var(--mdd-fs-base); line-height: 1.6; }
	:where(body:not(.mdd-builder-page)) .mdd-arch-meta { gap: 6px 10px; margin-top: 8px; }
	:where(body:not(.mdd-builder-page)) .mdd-arch-dome { box-shadow: inset 0 -12px 24px -16px rgba(255, 255, 255, .10), 0 14px 24px -20px var(--mdd-glow); }
	:where(body:not(.mdd-builder-page)) .mdd-arch-dome::before { border-color: color-mix(in srgb, var(--mdd-accent) 28%, var(--mdd-ring)); }
	:where(body:not(.mdd-builder-page)) .mdd-showcase.is-poster { --mdd-gap-x: 24px; row-gap: 64px; }
	:where(body:not(.mdd-builder-page)) .mdd-poster { border-radius: 22px; box-shadow: var(--mdd-store-shadow); }
	:where(body:not(.mdd-builder-page)) .mdd-poster-screen { border-radius: 22px 22px 0 0; }
	:where(body:not(.mdd-builder-page)) .mdd-poster-bg { clip-path: inset(0 round 22px 22px 0 0); }
	:where(body:not(.mdd-builder-page)) .mdd-poster-bar { min-height: 60px; padding: 12px 16px; gap: 12px; border-radius: 0 0 22px 22px; box-shadow: none; }
	:where(body:not(.mdd-builder-page)) .mdd-poster-bar .mdd-poster-name { font-size: var(--mdd-fs-base); line-height: 1.6; }
	:where(body:not(.mdd-builder-page)) .mdd-poster-meta { bottom: 12px; left: 12px; right: 12px; gap: 6px; }
	:where(body:not(.mdd-builder-page)) .mdd-more-link { min-height: 44px; padding: 10px 18px; }
	:where(body:not(.mdd-builder-page)) .mdd-tilt-grid,
	:where(body:not(.mdd-builder-page)) .mdd-hovergrid,
	:where(body:not(.mdd-builder-page)) .mdd-wobble-grid { gap: clamp(18px, 2vw, 28px); }
	:where(body:not(.mdd-builder-page)) .mdd-tilt-card { padding: clamp(20px, 2vw, 28px); border-radius: 24px; border-color: var(--mdd-border); box-shadow: var(--mdd-store-shadow); }
	:where(body:not(.mdd-builder-page)) .mdd-tilt-media,
	:where(body:not(.mdd-builder-page)) .mdd-tilt-media img { border-radius: 17px; }
	:where(body:not(.mdd-builder-page)) .mdd-tilt-title { line-height: 1.5; }
	:where(body:not(.mdd-builder-page)) .mdd-tilt-foot { gap: 12px; flex-wrap: wrap; }
	:where(body:not(.mdd-builder-page)) .mdd-tilt-desc { line-height: 1.8; }
	:where(body:not(.mdd-builder-page)) .mdd-hl { border-radius: 28px; background: color-mix(in srgb, var(--mdd-accent) 12%, transparent); }
	:where(body:not(.mdd-builder-page)) .mdd-hcard { padding: 24px; gap: 16px; border-radius: 24px; box-shadow: var(--mdd-store-shadow); }
	:where(body:not(.mdd-builder-page)) .mdd-hcard-head { flex-wrap: wrap; }
	:where(body:not(.mdd-builder-page)) .mdd-hcard-img { width: 64px; height: 64px; border-radius: 17px; }
	:where(body:not(.mdd-builder-page)) .mdd-hcard-title { line-height: 1.5; letter-spacing: 0; }
	:where(body:not(.mdd-builder-page)) .mdd-hcard-foot { padding-top: 16px; gap: 12px; flex-wrap: wrap; }
	:where(body:not(.mdd-builder-page)) .mdd-wobble { border-radius: 26px; }
	:where(body:not(.mdd-builder-page)) .mdd-wobble-inner { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .10); }
	:where(body:not(.mdd-builder-page)) .mdd-wobble-title { line-height: 1.5; letter-spacing: 0; }
	:where(body:not(.mdd-builder-page)) .mdd-wobble-desc { line-height: 1.85; }
	:where(body:not(.mdd-builder-page)) .mdd-wobble-foot { gap: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-wobble-cta { min-height: 46px; justify-content: center; border-radius: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-xp-list { gap: 12px 20px; }
	:where(body:not(.mdd-builder-page)) .mdd-xp { gap: 14px; padding: 16px; border: 1px solid var(--mdd-border); border-radius: 20px; background: var(--mdd-surface); }
	:where(body:not(.mdd-builder-page)) .mdd-xp:hover,
	:where(body:not(.mdd-builder-page)) .mdd-xp:focus-within { box-shadow: var(--mdd-store-shadow); border-color: color-mix(in srgb, var(--mdd-accent) 55%, var(--mdd-border)); }
	:where(body:not(.mdd-builder-page)) .mdd-xp-img { width: 64px; height: 64px; border-radius: 16px; }
	:where(body:not(.mdd-builder-page)) .mdd-xp-title { line-height: 1.6; }
	:where(body:not(.mdd-builder-page)) .mdd-xp-open { min-height: 44px; border-radius: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-xp-open::after { border-radius: 20px; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-overlay { background: rgba(8, 10, 16, .58); }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-box { max-width: 580px; border-radius: 28px; max-height: min(92dvh, 900px); }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-close { width: 44px; height: 44px; top: 14px; inset-inline-end: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-hero { height: clamp(140px, 28dvh, 280px); }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-head { gap: 16px; padding: 24px 24px 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-title { font-size: var(--mdd-fs-xl); line-height: 1.5; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-cta { min-height: 46px; border-radius: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-body { padding: 8px 24px 28px; -webkit-mask-image: none; mask-image: none; scrollbar-width: thin; line-height: 1.9; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-body::-webkit-scrollbar { display: block; width: 6px; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-body::-webkit-scrollbar-thumb { background: var(--mdd-border); border-radius: 6px; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-plans li { padding: 12px; border-radius: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-xpm-plan-cta { min-height: 44px; padding-inline: 12px; }
	:where(body:not(.mdd-builder-page)) .mdd-stack-card { border-radius: 26px; box-shadow: var(--mdd-store-shadow-hover); }
	:where(body:not(.mdd-builder-page)) .mdd-stack-title { line-height: 1.5; }
	:where(body:not(.mdd-builder-page)) .mdd-stack-index { gap: 10px; }
	:where(body:not(.mdd-builder-page)) .mdd-stack-index a { min-height: 68px; padding: 12px 14px; border-radius: 18px; }
	:where(body:not(.mdd-builder-page)) .mdd-stack-index a[aria-current="true"] { border-color: var(--mdd-accent); background: color-mix(in srgb, var(--mdd-accent) 8%, var(--mdd-surface)); }
	:where(body:not(.mdd-builder-page)) :is(.mdd-tilt-cta, .mdd-hcard-cta, .mdd-stack-cta, .mdd-svc-cta, .mdd-cc-cta) { min-height: 44px; border-radius: 13px; padding: 9px 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-carousel-btn { min-width: 44px; min-height: 44px; border-radius: 14px; }
	:where(body:not(.mdd-builder-page)) .mdd-stack-controls {
		grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px;
		width: 100%; padding-top: 8px;
	}
	:where(body:not(.mdd-builder-page)) .mdd-stack-controls .mdd-icon-btn {
		min-width: 44px; height: 44px; border: 1px solid var(--mdd-border); border-radius: 13px; background: var(--mdd-surface);
	}
	:where(body:not(.mdd-builder-page)) .mdd-stack-controls .mdd-btn { min-height: 44px; border-radius: 13px; }
		:where(body:not(.mdd-builder-page)) .mdd-stack-controls .mdd-btn[aria-pressed="true"] {
			border-color: var(--mdd-accent); background: color-mix(in srgb, var(--mdd-accent) 13%, var(--mdd-surface)); color: var(--mdd-text);
		}
		:where(body:not(.mdd-builder-page)) .mdd-stackshelf:is(.is-paused, .is-manual-paused) .mdd-stack-index a[aria-current="true"]::after { animation-play-state: paused !important; }
		:where(body:not(.mdd-builder-page)) .mdd-stack-controls .is-prev { transform: rotate(180deg); }

		/* Fine-pointer feedback is restrained; no global transition or entrance hiding. */
	@media (hover: hover) and (pointer: fine) {
		:where(body:not(.mdd-builder-page)) .mdd-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--mdd-accent) 60%, var(--mdd-border)); box-shadow: var(--mdd-store-shadow-hover); }
		:where(body:not(.mdd-builder-page)) .mdd-card:hover .mdd-card-media img { transform: scale(1.025); }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card:hover { transform: none; }
	}

	@media (min-width: 1180px) {
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card { flex-direction: row; }
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-media { flex: 0 0 35%; align-self: flex-start; aspect-ratio: 1; margin: 20px; margin-inline-end: 0; }
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-body { flex: 1; padding: 24px 20px; }
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-buy { flex-wrap: wrap; }
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-order { flex: 1 1 auto; }
	}
		@media (max-width: 1100px) {
			.mdd-view-compact .mdd-grid[data-mdd-view] { --mdd-cols: 4; }
		}
		/* Keep the theme's existing 960px navigation boundary. */
		@media (min-width: 961px) {
			:where(body:not(.mdd-builder-page)) .mdd-menu > li > a { padding-inline: clamp(8px, 1vw, 14px); }
			.mdd-menu li.is-open > .sub-menu { opacity: 1; visibility: visible; transform: none; }
		}
		@media (max-width: 960px) {
			:where(body:not(.mdd-builder-page)) .mdd-header-row { gap: 6px; }
			:where(body:not(.mdd-builder-page)) .mdd-header-row > .mdd-brand { min-width: 0; flex-shrink: 1; }
			:where(body:not(.mdd-builder-page)) .mdd-header-row > .mdd-brand .mdd-brand-name { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
			:where(body:not(.mdd-builder-page)) .mdd-header-actions { flex-shrink: 0; }
			:where(body:not(.mdd-builder-page)) .mdd-header-wa { min-width: 44px; min-height: 44px; border-radius: 14px; }
			:where(body:not(.mdd-builder-page)) .mdd-nav-head { padding-bottom: 18px; margin-bottom: 12px; }
			:where(body:not(.mdd-builder-page)) .mdd-menu > li > a { min-height: 48px; padding: 12px 14px; }
		:where(body:not(.mdd-builder-page)) .mdd-submenu-toggle { width: 44px; height: 44px; }
		:where(body:not(.mdd-builder-page)) .mdd-nav .mdd-menu .sub-menu { border-radius: 0; box-shadow: none; }
	}
	@media (max-width: 900px) {
		:where(body:not(.mdd-builder-page)) .mdd-catalog-views { flex-basis: 100%; align-items: flex-start; }
		:where(body:not(.mdd-builder-page)) .mdd-filterbar { gap: 14px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-body { column-gap: 16px; padding: 18px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-buy { padding-inline-start: 16px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-peek { margin-inline-start: 16px; }
	}
	@media (max-width: 760px) {
		:where(body:not(.mdd-builder-page)) .mdd-product { gap: 24px; padding-top: 20px; }
		:where(body:not(.mdd-builder-page)) .mdd-pcard-body { padding: 22px; }
		:where(body:not(.mdd-builder-page)) .mdd-product .mdd-panel { padding: 22px; }
		.mdd-view-showcase .mdd-grid[data-mdd-view] { grid-template-columns: minmax(0, 1fr); }
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-media { aspect-ratio: 4 / 3; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card { flex-direction: row; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-media { width: 108px; height: auto; aspect-ratio: 1; margin: 14px; margin-inline-end: 0; border-radius: 15px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-body { display: flex; padding: 16px; gap: 7px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-title { font-size: var(--mdd-fs-lg); }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-desc { display: -webkit-box; -webkit-line-clamp: 2; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-extra { margin-top: 4px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-buy { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; padding: 12px 0 0; border-inline-start: 0; border-top: 1px solid var(--mdd-border); gap: 10px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-order { width: auto; flex: 1 1 auto; min-height: 44px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-peek { align-self: stretch; margin-inline-start: 0; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-head { flex-wrap: wrap; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-cta { width: 100%; justify-content: center; }
	}
	@media (max-width: 640px) {
		:where(body:not(.mdd-builder-page)) .mdd-card { border-radius: 20px; }
		:where(body:not(.mdd-builder-page)) .mdd-grid { gap: 12px; }
		:where(body:not(.mdd-builder-page)) .mdd-card-body { padding: 13px; gap: 6px; }
		:where(body:not(.mdd-builder-page)) .mdd-card-title { font-size: var(--mdd-fs-md); line-height: 1.6; }
		:where(body:not(.mdd-builder-page)) .mdd-card-buy { flex-wrap: wrap; gap: 10px; padding-top: 12px; }
		:where(body:not(.mdd-builder-page)) .mdd-card-pricebox { flex: 1 1 100%; }
		:where(body:not(.mdd-builder-page)) .mdd-card-pricebox .mdd-amount-num { font-size: var(--mdd-fs-xl); }
		:where(body:not(.mdd-builder-page)) .mdd-card-order { flex: 1 1 100%; width: 100%; padding: 9px; }
		:where(body:not(.mdd-builder-page)) .mdd-card-order span { position: static; width: auto; height: auto; overflow: visible; clip: auto; clip-path: none; white-space: normal; }
		:where(body:not(.mdd-builder-page)) .mdd-card .mdd-badge { top: 8px; inset-inline-start: 8px; padding: 2px 6px; max-width: calc(100% - 54px); }
		:where(body:not(.mdd-builder-page)) .mdd-card .mdd-discount { top: 8px; inset-inline-end: 8px; padding: 2px 6px; }
		:where(body:not(.mdd-builder-page)) .mdd-card-rating { bottom: 8px; inset-inline-start: 8px; }
		:where(body:not(.mdd-builder-page)) .mdd-catalog .mdd-toolbar { padding: 12px; border-radius: 18px; gap: 12px; }
		:where(body:not(.mdd-builder-page)) .mdd-chips { margin-inline: 0; padding-inline: 0; }
		:where(body:not(.mdd-builder-page)) .mdd-sort { max-width: 100%; }
		:where(body:not(.mdd-builder-page)) .mdd-filters-row { flex-basis: 100%; gap: 7px; }
		:where(body:not(.mdd-builder-page)) .mdd-fchip { min-height: 44px; padding: 8px 12px; }
		:where(body:not(.mdd-builder-page)) .mdd-catalog-views { width: 100%; }
		:where(body:not(.mdd-builder-page)) .mdd-viewswitch { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); width: 100%; gap: 3px; }
		:where(body:not(.mdd-builder-page)) .mdd-viewswitch button { flex-direction: column; min-width: 0; min-height: 58px; padding: 8px 4px; gap: 5px; font-size: var(--mdd-fs-xs); }
		:where(body:not(.mdd-builder-page)) .mdd-view-caption { text-align: start; }
		.mdd-view-compact .mdd-grid[data-mdd-view] { --mdd-cols: 3; gap: 10px; }
		.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-body { padding: 10px 8px; }
		.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-title { font-size: var(--mdd-fs-xs); }
		.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-order { min-height: 44px; padding: 8px 4px; gap: 4px; }
		.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-order .mdd-icon { width: 14px; height: 14px; }
		.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-peek { gap: 4px; }
		.mdd-view-compact .mdd-grid[data-mdd-view] .mdd-card-peek .mdd-icon { width: 14px; height: 14px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-media { width: 96px; margin: 12px; margin-inline-end: 0; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-body { padding: 14px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-body > :nth-last-child(2) { margin-bottom: 0; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-pricebox { flex-basis: auto; }
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-body { padding: 22px; }
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-buy { flex-wrap: wrap; }
		.mdd-view-showcase .mdd-grid[data-mdd-view] .mdd-card-order { flex-basis: 100%; width: 100%; }
		:where(body:not(.mdd-builder-page)) .mdd-grid.is-rail-m { gap: 14px; padding-block: 8px 18px; }
		:where(body:not(.mdd-builder-page)) .mdd-showcase.is-arch.is-rail-m .mdd-arch-name { font-size: var(--mdd-fs-md); }
		:where(body:not(.mdd-builder-page)) .mdd-showcase.is-poster.is-rail-m { padding-top: 62px; }
		:where(body:not(.mdd-builder-page)) .mdd-poster-bar { min-height: 54px; padding: 10px 14px; }
		:where(body:not(.mdd-builder-page)) .mdd-hcard { padding: 20px; }
		:where(body:not(.mdd-builder-page)) .mdd-tilt-card { padding: 20px; }
		:where(body:not(.mdd-builder-page)) .mdd-tilt-grid.is-rail-m { gap: 14px; padding-block: 8px 18px; }
		:where(body:not(.mdd-builder-page)) .mdd-wobble { --mdd-wobble-img: 118px; }
		:where(body:not(.mdd-builder-page)) .mdd-wobble-content { padding: 24px 20px; }
		:where(body:not(.mdd-builder-page)) .mdd-wobble-text { max-width: calc(100% - var(--mdd-wobble-img) + 12px); }
		:where(body:not(.mdd-builder-page)) .mdd-wobble-title { font-size: var(--mdd-fs-xl); }
		:where(body:not(.mdd-builder-page)) .mdd-wobble-cta { padding-inline: 12px; white-space: normal; }
		:where(body:not(.mdd-builder-page)) .mdd-xp { padding: 14px; grid-template-columns: 56px minmax(0, 1fr) auto; column-gap: 10px; }
		:where(body:not(.mdd-builder-page)) .mdd-xp-img { width: 56px; height: 56px; }
		:where(body:not(.mdd-builder-page)) .mdd-xp-open { padding-inline: 12px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm { padding: 10px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-box { max-width: none; height: auto; max-height: calc(100dvh - 20px); border-radius: 24px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-head { padding: 20px 18px 10px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-body { padding-inline: 18px; padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px)); }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-plans li { grid-template-columns: minmax(0, 1fr) auto; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-plan-cta { grid-column: 1 / -1; width: 100%; }
		:where(body:not(.mdd-builder-page)) .mdd-stack-card { border-radius: 22px; }
		:where(body:not(.mdd-builder-page)) .mdd-product .mdd-compare { min-width: 380px; }
		:where(body:not(.mdd-builder-page)) .mdd-product .mdd-compare :is(th, td) { padding: 12px 9px; }
	}
	@media (max-width: 380px) {
		.mdd-view-compact .mdd-grid[data-mdd-view] { --mdd-cols: 2; }
		:where(body:not(.mdd-builder-page)) .mdd-header-actions { gap: 2px; }
		:where(body:not(.mdd-builder-page)) .mdd-header .mdd-brand { gap: 6px; min-width: 0; }
		:where(body:not(.mdd-builder-page)) .mdd-header .mdd-brand-logo { max-width: 100px; }
		:where(body:not(.mdd-builder-page)) .mdd-product .mdd-panel { padding: 18px; }
		:where(body:not(.mdd-builder-page)) .mdd-pcard-body { padding: 18px; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-media { width: 76px; margin: 10px; margin-inline-end: 0; }
		.mdd-view-list .mdd-grid[data-mdd-view] .mdd-card-body { padding: 12px; }
		:where(body:not(.mdd-builder-page)) .mdd-stack-cta { width: auto; padding: 9px 10px; }
		:where(body:not(.mdd-builder-page)) .mdd-stack-cta span { position: static; width: auto; height: auto; overflow: visible; clip: auto; clip-path: none; white-space: normal; }
	}

	/* Short/landscape screens: the text region, rather than the entire dialog, scrolls.
	 * A compact image and wrapping header keep the order CTA above that scroll area. */
	@media (max-height: 600px) {
		:where(body:not(.mdd-builder-page)) .mdd-xpm { padding: 8px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-box { max-height: calc(100dvh - 16px); }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-hero { height: clamp(64px, 20dvh, 120px); }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-head { padding: 12px 18px 8px; gap: 8px 14px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-title { font-size: var(--mdd-fs-lg); }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-meta { font-size: var(--mdd-fs-xs); margin-bottom: 3px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-body { padding-top: 6px; }
	}
	@media (max-height: 360px) {
		:where(body:not(.mdd-builder-page)) .mdd-xpm-hero { height: 58px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-head { padding-block: 8px; }
		:where(body:not(.mdd-builder-page)) .mdd-xpm-close { top: 7px; }
	}

	/* Reduce motion also cancels legacy hover transforms, while preserving stack geometry. */
	@media (prefers-reduced-motion: reduce) {
		:where(body:not(.mdd-builder-page)) :is(.mdd-card, .mdd-card-media img, .mdd-card-order, .mdd-card-peek, .mdd-header, .mdd-arch-icon, .mdd-poster-icon, .mdd-tilt-card, .mdd-z, .mdd-wobble, .mdd-wobble-content, .mdd-hl, .mdd-stack-card) { transition: none !important; animation: none !important; }
		:where(body:not(.mdd-builder-page)) .mdd-card:hover,
		:where(body:not(.mdd-builder-page)) .mdd-card:hover .mdd-card-media img,
		:where(body:not(.mdd-builder-page)) .mdd-card-order:active,
		:where(body:not(.mdd-builder-page)) .mdd-tilt-card,
		:where(body:not(.mdd-builder-page)) .mdd-z,
		:where(body:not(.mdd-builder-page)) .mdd-wobble,
		:where(body:not(.mdd-builder-page)) .mdd-wobble-content { transform: none !important; }
		:where(body:not(.mdd-builder-page)) .mdd-arch:where(:hover, :focus-within) .mdd-arch-icon { transform: translateX(-50%) !important; }
		:where(body:not(.mdd-builder-page)) .mdd-poster:where(:hover, :focus-within) .mdd-poster-icon { transform: translate(-50%, -40%) !important; }
		:where(body:not(.mdd-builder-page)) .mdd-stack-index a[aria-current="true"]::after { animation: none !important; display: none; }
	}
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion :is(.mdd-card, .mdd-card-media img, .mdd-card-order, .mdd-card-peek, .mdd-arch-icon, .mdd-poster-icon, .mdd-tilt-card, .mdd-z, .mdd-wobble, .mdd-wobble-content, .mdd-hl, .mdd-stack-card) { transition: none !important; animation: none !important; }
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-card:hover,
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-card:hover .mdd-card-media img,
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-card-order:active,
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-tilt-card,
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-z,
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-wobble,
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-wobble-content { transform: none !important; }
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-arch:where(:hover, :focus-within) .mdd-arch-icon { transform: translateX(-50%) !important; }
	:where(body:not(.mdd-builder-page)).mdd-reduce-motion .mdd-poster:where(:hover, :focus-within) .mdd-poster-icon { transform: translate(-50%, -40%) !important; }
}
