/* ==========================================================================
   Mijn recepten (/mijn-recepten). Sjabloon: page-mijn-recepten.php,
   script: assets/js/my-recipes.js. Laden na main.css en actions.css
   (tokens, .card, .card-grid, .btn, .btn-ghost, .breadcrumbs).
   Ontwerp: redesign/02-ontwerp/canvas/Bewaard.dc.html + Desktop-Bewaard.dc.html
   (zonder de lijstjes-chips: besluit één lijst).
   ========================================================================== */

/* ---------- 1. Kop ---------- */
.my-recipes { padding-bottom: var(--s-8); }

.my-recipes__head {
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding-top: 18px;
}
.my-recipes__head > * { margin: 0; }
.my-recipes__head .breadcrumbs [aria-current] { color: var(--c-text); }
.my-recipes__title.page-title { margin: 4px 0 0; font-size: 28px; line-height: 30px; }
.my-recipes__title:focus { outline: none; }
.my-recipes__title:focus-visible { outline: 2px solid var(--c-navy); outline-offset: 4px; border-radius: 4px; }
.my-recipes__count {
	min-height: 22px; /* geen verspringen als het aantal binnenkomt */
	font-size: 15px;
	line-height: 22px;
	color: var(--c-text);
}

/* ---------- 2. Raster ---------- */
.my-recipes__body { padding-top: 20px; }
.my-recipes__grid[hidden] { display: none; }

/* Laadkaarten: zelfde maat als een echte kaart, zacht pulserend. */
.my-recipes__skeleton .card__media,
.my-recipes__line {
	background: var(--c-placeholder);
	animation: my-recipes-pulse 1.4s ease-in-out infinite;
}
.my-recipes__line {
	display: block;
	height: 14px;
	border-radius: 7px;
}
.my-recipes__line + .my-recipes__line { margin-top: 4px; height: 16px; }
.my-recipes__line--short { width: 55%; height: 12px; }

@keyframes my-recipes-pulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.55; }
}

/* Kaart die net is toegevoegd (Ongedaan maken, deellink): even laten opkomen. */
.my-recipes__grid .card[data-mr-id] { animation: my-recipes-in 0.2s ease-out; }
@keyframes my-recipes-in {
	from { opacity: 0; transform: translateY(4px); }
	to { opacity: 1; transform: none; }
}

/* ---------- 3. Melding "Je recepten staan op dit apparaat" ---------- */
.my-recipes__notice {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin: 28px -4px 0; /* ontwerp: 12 px van de rand, raster 16 px */
	padding: 18px;
	border-radius: var(--r-lg);
	background: var(--c-soft);
}
.my-recipes__notice[hidden] { display: none; }
.my-recipes__notice-text { display: flex; flex-direction: column; gap: 6px; }
.my-recipes__notice-title {
	margin: 0;
	font-family: var(--f-sans);
	font-size: 15px;
	line-height: 21px;
	font-weight: 600;
	color: var(--c-ink);
}
.my-recipes__notice p {
	margin: 0;
	font-size: 14px;
	line-height: 1.55;
	color: var(--c-text);
}
.my-recipes__share.btn-ghost {
	width: 100%;
	height: 46px;
	font-size: 14px;
}
.my-recipes__share svg { width: 16px; height: 16px; }

/* ---------- 4. Leeg, fout, niet beschikbaar ---------- */
.my-recipes__state {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
	max-width: 520px;
	margin: 12px auto 0;
	padding: 36px 20px;
	border-radius: var(--r-lg);
	background: var(--c-soft);
	text-align: center;
}
.my-recipes__state[hidden] { display: none; }
.my-recipes__state > * { margin: 0; }
.my-recipes__state-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 64px;
	height: 64px;
	margin-bottom: 4px;
	border-radius: var(--r-pill);
	background: var(--c-blue);
	color: var(--c-navy);
}
.my-recipes__state-icon svg { width: 28px; height: 28px; }
.my-recipes__state-title { font-size: 22px; line-height: 26px; }
.my-recipes__state-text {
	max-width: 420px;
	font-size: 15px;
	line-height: 1.6;
	color: var(--c-text);
}
.my-recipes__state .btn { margin-top: 6px; }

/* ---------- 5. Desktop ---------- */
@media (min-width: 1024px) {
	.my-recipes { padding-bottom: var(--s-12); }
	.my-recipes__head { gap: 14px; padding-top: 40px; }
	.my-recipes__title.page-title { margin: 0; font-size: 44px; line-height: 46px; }
	.my-recipes__count { font-size: 16px; color: var(--c-muted); }
	.my-recipes__body { padding-top: 28px; }

	.my-recipes__notice {
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
		gap: 24px;
		margin: 40px 0 0;
		padding: 22px 28px;
	}
	.my-recipes__notice-text { gap: 4px; }
	.my-recipes__notice-title { font-size: 16px; }
	.my-recipes__notice p { font-size: 15px; }
	.my-recipes__mobile-only { display: none; }
	.my-recipes__share.btn-ghost { width: auto; flex-shrink: 0; padding: 0 22px; }

	.my-recipes__state { margin-top: 0; padding: 56px 40px; }
	.my-recipes__state-title { font-size: 28px; line-height: 32px; }
}

@media (prefers-reduced-motion: reduce) {
	.my-recipes__skeleton .card__media,
	.my-recipes__line,
	.my-recipes__grid .card[data-mr-id] { animation: none; }
}
