/**
 * Decorrect WooCommerce — a kereső.
 *
 * Sizes are in px and em, never rem. Automatic.css sets
 * `html { font-size: 62.5% !important }` on this site, so 1rem is 10px here and
 * 16px everywhere else — a stylesheet that shipped rem would be two different
 * search bars depending on which site it landed on.
 *
 * Colours come through `--dcw-*` tokens with an ACSS variable as the first
 * fallback and a literal as the last, so the bar takes the site's palette where
 * there is one and still looks finished where there is not. Override the tokens
 * on `.dcw-search` to reskin the whole thing.
 *
 * The panel's two columns are a container query on the panel itself, not a
 * media query: a bar in a narrow sidebar gets one column on the widest screen,
 * and the full-screen sheet gets one column because it is 390px wide, not
 * because of what the stylesheet assumes about phones.
 */

.dcw-search {
	--dcw-ink: var(--primary, #111);
	--dcw-soft: #6b6b6b;
	--dcw-muted: #6f6f6f; /* 5.1:1 on white, 4.6:1 on the hover band: WCAG AA for text */
	--dcw-label: var(--dcw-muted);
	--dcw-accent: #b3161e;
	--dcw-line: #e6e6e6;
	--dcw-line-soft: #eee;
	--dcw-line-strong: #d9d9d9;
	--dcw-field-bg: #fff;
	--dcw-panel-bg: #fff;
	--dcw-band: #fafafa;
	--dcw-hover: #f6f6f6;
	--dcw-thumb-bg: var(--base-ultra-light, #f5f3ef);
	--dcw-thumb-ratio: 1;
	--dcw-thumb-fit: contain;
	--dcw-radius: 8px;
	--dcw-panel-radius: var(--dcw-radius);
	--dcw-panel-width: 100%;
	--dcw-field-height: 44px;
	--dcw-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);

	position: relative;
	display: block;
	box-sizing: border-box;
	width: 100%;
	max-width: var(--dcw-width, 100%);
	text-align: left;
}

.dcw-search--center {
	margin-inline: auto;
}

.dcw-search--right {
	margin-inline-start: auto;
}

.dcw-search *,
.dcw-search *::before,
.dcw-search *::after {
	box-sizing: border-box;
}

.dcw-search .screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.dcw-search [hidden] {
	display: none !important;
}

/* No bar with no ancestor stacking context to hide under: lifted over the
   backdrop instead. See search.js. */
.dcw-search.is-raised {
	z-index: 1001;
}

/* ---------------------------------------------------------------------------
 * 1. The field
 * ------------------------------------------------------------------------ */

.dcw-search__bar {
	display: flex;
	align-items: center;
	gap: 8px;
}

.dcw-search__form {
	position: relative;
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	gap: 10px;
	min-width: 0;
	height: var(--dcw-field-height);
	margin: 0;
	padding: 0 12px;
	background: var(--dcw-field-bg);
	border: 1px solid var(--dcw-line-strong);
	border-radius: var(--dcw-radius);
	transition: border-color 0.15s ease;
}

.dcw-search__form:focus-within,
.dcw-search.is-open .dcw-search__form {
	border-color: var(--dcw-ink);
}

.dcw-search__icon {
	position: relative;
	flex: 0 0 18px;
	width: 18px;
	height: 18px;
	color: var(--dcw-muted);
}

.dcw-search__icon svg {
	display: block;
	width: 100%;
	height: 100%;
}

.dcw-search .dcw-search__input {
	flex: 1 1 auto;
	width: 100%;
	min-width: 0;
	height: 100%;
	margin: 0;
	padding: 0;
	font: inherit;
	font-size: 15px;
	line-height: 1.4;
	color: var(--dcw-ink);
	background: transparent;
	/* Beaten otherwise by `input[type="search"]` rules in wp-admin and in some
	   themes, which are one specificity point above a bare class. */
	border: 0;
	border-radius: 0;
	outline: none;
	box-shadow: none;
	min-height: 0;
	-webkit-appearance: none;
	appearance: none;
}

.dcw-search .dcw-search__input:focus {
	outline: none;
	box-shadow: none;
}

.dcw-search .dcw-search__input::placeholder {
	color: var(--dcw-muted);
	opacity: 1;
}

/* The browser's own clear button would sit next to ours. */
.dcw-search .dcw-search__input::-webkit-search-decoration,
.dcw-search .dcw-search__input::-webkit-search-cancel-button,
.dcw-search .dcw-search__input::-webkit-search-results-button {
	display: none;
	-webkit-appearance: none;
	appearance: none;
}

/* "Törlés" as text on the dropdown, a round × on the sheet. */
.dcw-search .dcw-search__clear {
	flex: none;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 -4px 0 0;
	padding: 4px;
	font: inherit;
	font-size: 13px;
	line-height: 1;
	color: var(--dcw-soft);
	background: none;
	border: 0;
	border-radius: 2px;
	box-shadow: none;
	cursor: pointer;
	transition: color 0.15s ease;
}

.dcw-search .dcw-search__clear:hover,
.dcw-search .dcw-search__clear:focus-visible {
	color: var(--dcw-ink);
	background: none;
}

.dcw-search__clear-icon {
	display: none;
	width: 14px;
	height: 14px;
}

.dcw-search .dcw-search__back {
	display: none;
}

/* The magnifier becomes the spinner, so nothing in the row moves. */
.dcw-search.is-loading .dcw-search__icon svg {
	visibility: hidden;
}

.dcw-search.is-loading .dcw-search__icon::after {
	content: "";
	position: absolute;
	inset: 1px;
	border: 2px solid var(--dcw-line-strong);
	border-top-color: var(--dcw-ink);
	border-radius: 50%;
	animation: dcw-spin 0.6s linear infinite;
}

@keyframes dcw-spin {
	to {
		transform: rotate(360deg);
	}
}

@media (prefers-reduced-motion: reduce) {
	.dcw-search.is-loading .dcw-search__icon::after {
		animation-duration: 2.4s;
	}
}

/* ---------------------------------------------------------------------------
 * 2. The panel
 * ------------------------------------------------------------------------ */

.dcw-search__panel {
	position: absolute;
	z-index: 90;
	/* Measured from the field, so anything a site puts under the field inside
	   the wrapper does not push the panel down. */
	top: calc(var(--dcw-field-height) + 8px);
	right: 0;
	width: var(--dcw-panel-width);
	max-height: min(80vh, 680px);
	overflow-y: auto;
	overscroll-behavior: contain;
	container-type: inline-size;
	background: var(--dcw-panel-bg);
	border: 1px solid var(--dcw-line);
	border-radius: var(--dcw-panel-radius);
	box-shadow: var(--dcw-shadow);
	-webkit-overflow-scrolling: touch;
}

.dcw-search__col {
	display: flex;
	flex-direction: column;
	gap: 22px;
	min-width: 0;
	padding: 22px;
}

.dcw-search__section {
	display: flex;
	flex-direction: column;
	gap: 12px;
	min-width: 0;
}

.dcw-search__heading {
	margin: 0;
	font-size: 11px;
	font-weight: 500;
	line-height: 1.2;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--dcw-label);
}

/* ---------------------------------------------------------------------------
 * 3. The empty view
 * ------------------------------------------------------------------------ */

.dcw-search__discover {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
}

.dcw-search__discover > .dcw-search__col--aside {
	gap: 12px;
	background: var(--dcw-band);
	border-top: 1px solid var(--dcw-line-soft);
}

/* The recent searches are the sheet's; on a dropdown the field is right there. */
.dcw-search__section--recent {
	display: none;
}

.dcw-search__chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.dcw-search .dcw-search__chip {
	display: inline-flex;
	align-items: center;
	padding: 7px 12px;
	font-size: 14px;
	line-height: 1.2;
	color: var(--dcw-ink);
	text-decoration: none;
	background: var(--dcw-panel-bg);
	border: 1px solid var(--dcw-line-strong);
	box-shadow: none;
	transition: border-color 0.12s ease;
}

.dcw-search .dcw-search__chip:hover,
.dcw-search .dcw-search__chip:focus,
.dcw-search .dcw-search__chip.is-active {
	color: var(--dcw-ink);
	text-decoration: none;
	border-color: var(--dcw-ink);
	outline: none;
}

.dcw-search__section--browse {
	gap: 0;
}

.dcw-search__section--browse > .dcw-search__heading {
	margin-bottom: 10px;
}

.dcw-search__dot {
	flex: none;
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: var(--dcw-dot, var(--dcw-line-strong));
}

/* ---------------------------------------------------------------------------
 * 4. Rows
 * ------------------------------------------------------------------------ */

.dcw-search .dcw-search__item {
	display: flex;
	align-items: center;
	min-width: 0;
	color: var(--dcw-ink);
	text-decoration: none;
	box-shadow: none;
	transition: background-color 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}

.dcw-search .dcw-search__item:focus {
	outline: none;
}

.dcw-search__name {
	min-width: 0;
	font-size: 14px;
	font-weight: 400;
	line-height: 1.3;
	color: inherit;
	overflow-wrap: anywhere;
}

/* The matched part of the name, marked up by the script. */
.dcw-search__name strong {
	font-weight: 600;
}

/* A browse link: a dot and a name. */
.dcw-search .dcw-search__item--browse {
	gap: 10px;
	padding: 6px 0;
}

.dcw-search .dcw-search__item--browse:hover,
.dcw-search .dcw-search__item--browse.is-active {
	color: var(--dcw-accent);
}

/* A term in a group: the name and how many products it holds. */
.dcw-search .dcw-search__item--term {
	justify-content: space-between;
	align-items: baseline;
	gap: 8px;
	padding: 6px 0;
}

.dcw-search .dcw-search__item--term:hover,
.dcw-search .dcw-search__item--term.is-active {
	color: var(--dcw-accent);
}

.dcw-search__count {
	flex: none;
	font-size: 12px;
	line-height: 1.3;
	color: var(--dcw-muted);
	white-space: nowrap;
}

/* A product: picture, name and grey line, prices. */
.dcw-search .dcw-search__item--product {
	--dcw-thumb-w: 40px;

	gap: 14px;
	margin: 0 -8px;
	padding: 8px;
}

.dcw-search .dcw-search__item--product:hover,
.dcw-search .dcw-search__item--product.is-active {
	color: var(--dcw-ink);
	background: var(--dcw-hover);
}

/* The featured variant: a card on the grey band. */
.dcw-search .dcw-search__item--card {
	--dcw-thumb-w: 48px;

	margin: 0;
	background: var(--dcw-panel-bg);
	border: 1px solid var(--dcw-line-soft);
}

.dcw-search .dcw-search__item--card:hover,
.dcw-search .dcw-search__item--card.is-active {
	background: var(--dcw-panel-bg);
	border-color: var(--dcw-ink);
}

.dcw-search__thumb {
	flex: none;
	display: flex;
	align-items: center;
	justify-content: center;
	width: var(--dcw-thumb-w, 40px);
	aspect-ratio: var(--dcw-thumb-ratio);
	overflow: hidden;
	background: var(--dcw-thumb-bg);
}

.dcw-search__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: 100%;
	object-fit: var(--dcw-thumb-fit);
}

.dcw-search__body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

/* A small label above the name (`badge`): a sale, a novelty. Outlined in the
   accent unless the site sets --dcw-badge-ink. */
.dcw-search__badge {
	align-self: flex-start;
	padding: 1px 6px;
	border: 1px solid currentColor;
	border-radius: 999px;
	font-size: 9px;
	font-weight: 600;
	line-height: 1.4;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	white-space: nowrap;
	color: var(--dcw-badge-ink, var(--dcw-accent));
}

.dcw-search__meta {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	line-height: 1.3;
	color: var(--dcw-soft);
}

.dcw-search__meta .dcw-search__dot {
	width: 8px;
	height: 8px;
}

.dcw-search__prices {
	display: flex;
	flex: none;
	flex-direction: column;
	align-items: flex-end;
	gap: 1px;
	text-align: right;
}

.dcw-search__price {
	font-size: 14px;
	font-weight: 400;
	line-height: 1.3;
	color: var(--dcw-ink);
	white-space: nowrap;
}

/* WooCommerce's own price markup, which is what `price` carries. */
.dcw-search__price del {
	margin-right: 6px;
	color: var(--dcw-muted);
	text-decoration: line-through;
}

.dcw-search__price ins {
	background: none;
	text-decoration: none;
}

.dcw-search__price .woocommerce-Price-amount {
	white-space: nowrap;
}

.dcw-search__note {
	font-size: 11px;
	line-height: 1.3;
	color: var(--dcw-accent);
	white-space: nowrap;
}

/* A second, quieter line under the note: a deposit, a levy. */
.dcw-search__extra {
	font-size: 11px;
	line-height: 1.3;
	color: var(--dcw-muted);
	white-space: nowrap;
}

/* ---------------------------------------------------------------------------
 * 5. The results view
 * ------------------------------------------------------------------------ */

.dcw-search__grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
}

.dcw-search__grid > .dcw-search__col {
	gap: 18px;
	padding: 18px 22px;
}

.dcw-search__grid > .dcw-search__col--aside {
	border-top: 1px solid var(--dcw-line-soft);
}

.dcw-search__grid .dcw-search__section {
	gap: 0;
}

.dcw-search__grid .dcw-search__heading {
	margin-bottom: 8px;
}

.dcw-search__grid .dcw-search__item--product + .dcw-search__item--product {
	margin-top: 4px;
}

.dcw-search__none,
.dcw-search__corrected {
	font-size: 14px;
	line-height: 1.4;
	color: var(--dcw-soft);
}

.dcw-search__none {
	padding: 8px 0;
}

/* "Címke alapján: …" over products that matched by tag rather than by name. */
.dcw-search__via {
	margin: -2px 0 6px;
	font-size: 12px;
	line-height: 1.3;
	color: var(--dcw-muted);
}

.dcw-search__corrected {
	padding: 14px 22px 0;
}

.dcw-search__empty {
	padding: 26px 22px;
	font-size: 14px;
	line-height: 1.4;
	text-align: center;
	color: var(--dcw-soft);
}

.dcw-search__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 14px 22px;
	background: var(--dcw-band);
	border-top: 1px solid var(--dcw-line-soft);
}

.dcw-search__hint {
	font-size: 12px;
	line-height: 1.3;
	color: var(--dcw-muted);
}

.dcw-search .dcw-search__more {
	margin-left: auto;
	padding: 0 0 1px;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.3;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--dcw-ink);
	text-decoration: none;
	background: none;
	border-bottom: 1px solid currentColor;
	box-shadow: none;
	transition: color 0.12s ease;
}

.dcw-search .dcw-search__more:hover,
.dcw-search .dcw-search__more:focus,
.dcw-search .dcw-search__more.is-active {
	color: var(--dcw-accent);
	text-decoration: none;
	outline: none;
}

.dcw-search__more-short {
	display: none;
}

.dcw-search__arrow {
	margin-left: 0.4em;
}

/* ---------------------------------------------------------------------------
 * 6. Two columns, once the panel has room for them
 * ------------------------------------------------------------------------ */

@container (min-width: 560px) {
	.dcw-search__discover {
		grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
	}

	.dcw-search__discover > .dcw-search__col--aside {
		border-top: 0;
		border-left: 1px solid var(--dcw-line-soft);
	}

	.dcw-search__grid {
		grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
	}

	.dcw-search__grid.is-single {
		grid-template-columns: minmax(0, 1fr);
	}

	.dcw-search__grid > .dcw-search__col--aside {
		border-top: 0;
		border-left: 1px solid var(--dcw-line-soft);
	}
}

/* ---------------------------------------------------------------------------
 * 7. The backdrop
 * ------------------------------------------------------------------------ */

/* Outside the bar, so it cannot read the bar's tokens. */
.dcw-search-backdrop {
	position: fixed;
	inset: 0;
	z-index: 1000;
	background: rgba(17, 17, 17, 0.35);
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.15s ease, visibility 0.15s ease;
}

.dcw-search-backdrop.is-visible {
	opacity: 1;
	visibility: visible;
}

/* ---------------------------------------------------------------------------
 * 8. The full-screen sheet
 *
 * Below the `sheet` width the open bar leaves the page layout and covers the
 * screen: back button and field on top, the panel filling the rest. The
 * selectors carry three classes because site CSS that fits the bar into a
 * header (`.header__search .dcw-search`) is two, and loads later.
 * ------------------------------------------------------------------------ */

html.dcw-search-lock,
html.dcw-search-lock body {
	overflow: hidden;
}

.dcw-search.is-open.is-sheet {
	position: fixed;
	top: 0;
	right: 0;
	bottom: auto;
	left: 0;
	z-index: 100000;
	display: flex;
	flex-direction: column;
	width: auto;
	max-width: none;
	height: 100%;
	height: 100dvh;
	margin: 0;
	background: var(--dcw-panel-bg);
}

.dcw-search.is-sheet .dcw-search__bar {
	flex: none;
	padding: 8px 12px 12px 8px;
	padding-top: calc(8px + env(safe-area-inset-top, 0px));
	border-bottom: 1px solid var(--dcw-line);
}

.dcw-search.is-sheet .dcw-search__back {
	display: flex;
	flex: none;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: 0;
	padding: 0;
	color: var(--dcw-ink);
	background: none;
	border: 0;
	box-shadow: none;
	cursor: pointer;
}

.dcw-search.is-sheet .dcw-search__back svg {
	width: 22px;
	height: 22px;
}

.dcw-search.is-sheet .dcw-search__form {
	height: 44px;
	padding: 0 6px 0 12px;
	border-color: var(--dcw-ink);
}

/* 16px or iOS zooms the page in when the field takes focus. */
.dcw-search.is-sheet .dcw-search__input {
	font-size: 16px;
}

.dcw-search.is-sheet .dcw-search__clear {
	width: 32px;
	height: 32px;
	margin: 0;
	padding: 0;
	color: #4a4a4a;
	background: var(--dcw-line-soft);
	border-radius: 50%;
}

.dcw-search.is-sheet .dcw-search__clear:hover {
	background: var(--dcw-line);
}

.dcw-search.is-sheet .dcw-search__clear-text {
	display: none;
}

.dcw-search.is-sheet .dcw-search__clear-icon {
	display: block;
}

.dcw-search.is-open.is-sheet .dcw-search__panel {
	position: static;
	flex: 1 1 auto;
	width: auto;
	min-height: 0;
	max-height: none;
	border: 0;
	border-radius: 0;
	box-shadow: none;
}

/* The empty view, one column. */
.dcw-search.is-sheet .dcw-search__discover > .dcw-search__col {
	gap: 20px;
	padding: 20px 16px;
}

.dcw-search.is-sheet .dcw-search__discover > .dcw-search__col--aside {
	gap: 10px;
	padding: 16px 16px calc(16px + env(safe-area-inset-bottom, 0px));
}

.dcw-search.is-sheet .dcw-search__section--recent {
	display: flex;
	gap: 0;
}

.dcw-search.is-sheet .dcw-search__section--recent > .dcw-search__heading {
	margin-bottom: 4px;
}

.dcw-search__recent {
	display: flex;
	align-items: center;
	border-bottom: 1px solid #f0f0f0;
}

.dcw-search .dcw-search__recent-term {
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	gap: 12px;
	min-width: 0;
	min-height: 44px;
	font-size: 15px;
	color: var(--dcw-ink);
	text-decoration: none;
	box-shadow: none;
}

.dcw-search .dcw-search__recent-term.is-active,
.dcw-search .dcw-search__recent-term:hover {
	color: var(--dcw-accent);
}

.dcw-search__recent-term svg {
	flex: none;
	width: 16px;
	height: 16px;
	color: var(--dcw-muted);
}

.dcw-search__recent-term .dcw-search__name {
	font-size: 15px;
}

.dcw-search .dcw-search__recent-remove {
	display: flex;
	flex: none;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: 0 -12px 0 0;
	padding: 0;
	color: var(--dcw-muted);
	background: none;
	border: 0;
	box-shadow: none;
	cursor: pointer;
}

.dcw-search__recent-remove svg {
	width: 16px;
	height: 16px;
}

.dcw-search.is-sheet .dcw-search__chip {
	min-height: 40px;
	padding: 0 14px;
	font-size: 15px;
}

.dcw-search.is-sheet .dcw-search__section--browse > .dcw-search__heading {
	margin-bottom: 6px;
}

.dcw-search.is-sheet .dcw-search__item--browse {
	gap: 12px;
	min-height: 48px;
	padding: 0;
	border-bottom: 1px solid #f0f0f0;
}

.dcw-search.is-sheet .dcw-search__item--browse .dcw-search__dot {
	width: 10px;
	height: 10px;
}

.dcw-search.is-sheet .dcw-search__item--browse .dcw-search__name,
.dcw-search.is-sheet .dcw-search__item--term .dcw-search__name {
	flex: 1 1 auto;
	font-size: 15px;
}

.dcw-search.is-sheet .dcw-search__item--browse::after,
.dcw-search.is-sheet .dcw-search__item--term::after {
	content: "›";
	flex: none;
	font-size: 18px;
	line-height: 1;
	color: var(--dcw-muted);
}

.dcw-search.is-sheet .dcw-search__item--card {
	--dcw-thumb-w: 44px;

	gap: 12px;
}

/* The results view, one column, with the button pinned under it. */
.dcw-search.is-sheet .dcw-search__corrected {
	padding: 14px 16px 0;
}

.dcw-search.is-sheet .dcw-search__grid > .dcw-search__col {
	gap: 16px;
	padding: 16px 16px 8px;
}

.dcw-search.is-sheet .dcw-search__grid > .dcw-search__col--aside {
	padding-top: 4px;
	padding-bottom: 16px;
	border: 0;
}

.dcw-search.is-sheet .dcw-search__grid .dcw-search__heading {
	margin-bottom: 4px;
}

.dcw-search.is-sheet .dcw-search__grid .dcw-search__item--product {
	--dcw-thumb-w: 44px;

	gap: 12px;
	margin: 0;
	padding: 10px 0;
	border-bottom: 1px solid #f0f0f0;
}

.dcw-search.is-sheet .dcw-search__grid .dcw-search__item--product + .dcw-search__item--product {
	margin-top: 0;
}

.dcw-search.is-sheet .dcw-search__grid .dcw-search__item--product .dcw-search__name {
	font-size: 15px;
}

.dcw-search.is-sheet .dcw-search__item--term {
	align-items: center;
	min-height: 48px;
	padding: 0;
	border-bottom: 1px solid #f0f0f0;
}

/* At least as tall as the sheet, so a short answer still has the button at
   the bottom of the screen; a long one scrolls with the button stuck there. */
.dcw-search.is-sheet .dcw-search__results {
	display: flex;
	flex-direction: column;
	min-height: 100%;
}

.dcw-search.is-sheet .dcw-search__foot {
	position: sticky;
	bottom: 0;
	margin-top: auto;
	padding: 12px 16px calc(24px + env(safe-area-inset-bottom, 0px));
	background: var(--dcw-panel-bg);
	border-top: 1px solid var(--dcw-line);
}

.dcw-search.is-sheet .dcw-search__hint,
.dcw-search.is-sheet .dcw-search__more-long {
	display: none;
}

.dcw-search.is-sheet .dcw-search__more-short {
	display: inline;
}

.dcw-search.is-sheet .dcw-search__more {
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	justify-content: center;
	height: 52px;
	margin: 0;
	padding: 0 16px;
	font-size: 14px;
	color: #fff;
	background: var(--dcw-ink);
	border: 0;
}

.dcw-search.is-sheet .dcw-search__more:hover,
.dcw-search.is-sheet .dcw-search__more.is-active {
	color: #fff;
	opacity: 0.9;
}

/*
 * A touch screen keeps `:hover` on whatever was last tapped, and the sheet
 * opens under the finger that tapped the field, so without this the row that
 * happens to land there turns red as if it were chosen. The keyboard cursor
 * (`.is-active`) still marks rows.
 */
@media (hover: none) {
	.dcw-search .dcw-search__item--browse:hover:not(.is-active),
	.dcw-search .dcw-search__item--term:hover:not(.is-active),
	.dcw-search .dcw-search__recent-term:hover:not(.is-active) {
		color: var(--dcw-ink);
	}

	.dcw-search .dcw-search__item--product:hover:not(.is-active) {
		background: none;
	}

	.dcw-search .dcw-search__item--card:hover:not(.is-active) {
		background: var(--dcw-panel-bg);
		border-color: var(--dcw-line-soft);
	}

	.dcw-search .dcw-search__chip:hover:not(.is-active) {
		border-color: var(--dcw-line-strong);
	}
}

/* ---------------------------------------------------------------------------
 * 9. Narrow screens, when the sheet is switched off
 * ------------------------------------------------------------------------ */

@media (max-width: 600px) {
	.dcw-search__panel {
		max-height: min(70vh, 560px);
	}

	/* 16px or iOS zooms the page in when the field takes focus. */
	.dcw-search .dcw-search__input {
		font-size: 16px;
	}
}
