/**
 * Food26 Recipe Box: the save buttons' two icons and the saved message (decision 0007; html/index.html .save-toast).
 *
 * A save button prints both icons; aria-pressed="true" (set by assets/js/recipe-box.js) shows the filled one. The
 * buttons' own look is their widget's (Recipe Grid, Recipe Header). Colours read the Food26 Design Scheme with the
 * design's values as fallbacks.
 */

[data-food26-save] .food26-save__off,
[data-food26-save] .food26-save__on {
	display: contents;
}

[data-food26-save] .food26-save__on,
[data-food26-save][aria-pressed="true"] .food26-save__off {
	display: none;
}

[data-food26-save][aria-pressed="true"] .food26-save__on {
	display: contents;
}

.food26-save__off svg,
.food26-save__on svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
}

/* The saved message: a dark pill at the foot of the window. */
.food26-save-toast {
	position: fixed;
	bottom: 24px;
	left: 50%;
	z-index: 9990;
	display: flex;
	align-items: center;
	gap: 12px;
	box-sizing: border-box;
	max-width: calc(100% - 32px);
	padding: 12px 14px 12px 20px;
	font-weight: 600;
	line-height: 1.7;
	color: #fff;
	background-color: var(--inoforest-custom-dark, #22150f);
	border-radius: 999px;
	box-shadow: 0 18px 44px rgba(43, 26, 18, 0.12);
	translate: -50% 0;
}

[dir="rtl"] .food26-save-toast {
	padding: 12px 20px 12px 14px;
	translate: 50% 0;
}

.food26-save-toast[hidden] {
	display: none;
}

.food26-save-toast svg {
	flex: none;
	width: 1.2rem;
	height: 1.2rem;
	fill: var(--inoforest-custom-primary-on-dark, #f2a58c);
}

.food26-save-toast.is-failed svg {
	display: none;
}

.food26-save-toast a {
	padding: 6px 14px;
	font-size: 0.875rem;
	font-weight: 700;
	line-height: 1.7;
	color: var(--inoforest-color-heading, #2b1a12);
	white-space: nowrap;
	text-decoration: none;
	background-color: #fff;
	border-radius: 999px;
	transition: color 0.3s ease, background-color 0.3s ease;
}

.food26-save-toast a:is(:hover, :focus-visible) {
	color: #fff;
	background-color: var(--inoforest-color-primary, #b23a1e);
}

.food26-save-toast.is-failed a {
	display: none;
}

@media (max-width: 767px) {
	.food26-save-toast {
		bottom: 16px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.food26-save-toast a {
		transition: none;
	}
}
