
	:root {
		--bg: #f7f8f7;
		--surface: #ffffff;
		--surface-2: #f3f5f4;
		--border: #e7eae8;
		--border-strong: #d5d9d7;
		--text: #0f172a;
		--text-muted: #64748b;
		--text-subtle: #94a3b8;
		--brand: #16a34a;
		--brand-strong: #15803d;
		--brand-soft: #dcfce7;
		--brand-soft-2: #f0fdf4;
		--danger: #ef4444;
		--danger-soft: #fee2e2;
		--protein: #3b82f6;
		--protein-soft: #dbeafe;
		--carbs: #f59e0b;
		--carbs-soft: #fef3c7;
		--fat: #f97316;
		--fat-soft: #ffedd5;
		--shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
		--shadow-md: 0 4px 16px rgba(15, 23, 42, 0.06);
		--radius-sm: 10px;
		--radius-md: 14px;
		--radius-lg: 18px;
	}

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

	body {
		margin: 0;
		font-family:
			-apple-system,
			BlinkMacSystemFont,
			'Inter',
			'Segoe UI',
			Roboto,
			'Helvetica Neue',
			sans-serif;
		background: var(--bg);
		color: var(--text);
		-webkit-font-smoothing: antialiased;
		-moz-osx-font-smoothing: grayscale;
	}

	button {
		font-family: inherit;
	}

	.app.svelte-12qhfyh {
		min-height: 100dvh;
		display: flex;
		flex-direction: column;
	}

	/* Sidebar (desktop only) */
	.sidebar.svelte-12qhfyh {
		display: none;
	}

	/* Top bar (mobile only) */
	.topbar.svelte-12qhfyh {
		background: var(--surface);
		border-bottom: 1px solid var(--border);
		padding: 12px 18px;
		position: sticky;
		top: 0;
		z-index: 10;
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: 12px;
	}

	.topbar-profile.svelte-12qhfyh {
		width: 36px;
		height: 36px;
		border-radius: 999px;
		background: var(--surface-2);
		color: var(--text-muted);
		display: inline-flex;
		align-items: center;
		justify-content: center;
		text-decoration: none;
		flex-shrink: 0;
		transition:
			background 0.15s,
			color 0.15s;
	}

	.topbar-profile.svelte-12qhfyh:hover,
	.topbar-profile.active.svelte-12qhfyh {
		background: var(--brand-soft);
		color: var(--brand-strong);
	}

	.brand.svelte-12qhfyh {
		display: inline-flex;
		align-items: center;
		gap: 10px;
		text-decoration: none;
		color: var(--text);
		font-weight: 700;
		letter-spacing: -0.01em;
	}

	.brand-mark.svelte-12qhfyh {
		width: 32px;
		height: 32px;
		border-radius: 9px;
		background: linear-gradient(135deg, #22c55e, #16a34a);
		color: white;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		box-shadow: 0 2px 8px rgba(22, 163, 74, 0.35);
	}

	.brand-mobile.svelte-12qhfyh .brand-mark:where(.svelte-12qhfyh) {
		width: 28px;
		height: 28px;
		border-radius: 8px;
	}

	.brand-text.svelte-12qhfyh {
		font-size: 0.95rem;
	}

	main.svelte-12qhfyh {
		flex: 1;
		padding: 18px 16px 96px;
	}

	.container.svelte-12qhfyh {
		max-width: 480px;
		margin: 0 auto;
		width: 100%;
	}

	/* Bottom nav (mobile) */
	.bottom-nav.svelte-12qhfyh {
		position: fixed;
		bottom: 0;
		left: 0;
		right: 0;
		background: var(--surface);
		border-top: 1px solid var(--border);
		display: flex;
		z-index: 10;
		padding-bottom: env(safe-area-inset-bottom, 0);
		box-shadow: 0 -2px 12px rgba(15, 23, 42, 0.04);
	}

	.bottom-nav.svelte-12qhfyh a:where(.svelte-12qhfyh) {
		flex: 1;
		display: flex;
		flex-direction: column;
		align-items: center;
		padding: 10px 0 12px;
		text-decoration: none;
		color: var(--text-subtle);
		gap: 4px;
		transition: color 0.15s;
	}

	.bottom-nav.svelte-12qhfyh a.active:where(.svelte-12qhfyh) {
		color: var(--brand);
	}

	.nav-label.svelte-12qhfyh {
		font-size: 0.68rem;
		font-weight: 600;
		letter-spacing: 0.01em;
	}

	.add-link.svelte-12qhfyh {
		position: relative;
	}

	.add-circle.svelte-12qhfyh {
		width: 44px;
		height: 44px;
		background: linear-gradient(135deg, #22c55e, #16a34a);
		color: white;
		border-radius: 50%;
		display: flex;
		align-items: center;
		justify-content: center;
		box-shadow: 0 4px 12px rgba(22, 163, 74, 0.4);
		transition: transform 0.15s;
		margin-top: -10px;
	}

	.add-link.svelte-12qhfyh:hover .add-circle:where(.svelte-12qhfyh),
	.add-link.active.svelte-12qhfyh .add-circle:where(.svelte-12qhfyh) {
		transform: scale(1.05);
	}

	.add-link.active.svelte-12qhfyh .nav-label:where(.svelte-12qhfyh) {
		color: var(--brand);
	}

	/* Desktop layout */
	@media (min-width: 900px) {
		.app.svelte-12qhfyh {
			display: grid;
			grid-template-columns: 248px 1fr;
			grid-template-rows: 1fr;
			min-height: 100dvh;
		}

		.topbar.svelte-12qhfyh {
			display: none;
		}

		.bottom-nav.svelte-12qhfyh {
			display: none;
		}

		.sidebar.svelte-12qhfyh {
			display: flex;
			flex-direction: column;
			gap: 24px;
			padding: 24px 18px;
			background: var(--surface);
			border-right: 1px solid var(--border);
			position: sticky;
			top: 0;
			height: 100dvh;
		}

		.sidebar.svelte-12qhfyh .brand:where(.svelte-12qhfyh) {
			padding: 4px 8px;
			font-size: 1rem;
		}

		.side-nav.svelte-12qhfyh {
			display: flex;
			flex-direction: column;
			gap: 4px;
		}

		.side-nav-link.svelte-12qhfyh {
			display: flex;
			align-items: center;
			gap: 12px;
			padding: 10px 12px;
			border-radius: 10px;
			text-decoration: none;
			color: var(--text-muted);
			font-size: 0.9rem;
			font-weight: 500;
			transition:
				background 0.15s,
				color 0.15s;
		}

		.side-nav-link.svelte-12qhfyh:hover {
			background: var(--surface-2);
			color: var(--text);
		}

		.side-nav-link.active.svelte-12qhfyh {
			background: var(--brand-soft);
			color: var(--brand-strong);
			font-weight: 600;
		}

		.sidebar-footer.svelte-12qhfyh {
			margin-top: auto;
			padding: 12px 14px;
			background: var(--surface-2);
			border-radius: var(--radius-md);
			display: flex;
			align-items: center;
			gap: 12px;
			text-decoration: none;
			color: inherit;
			transition:
				background 0.15s,
				box-shadow 0.15s;
		}

		.sidebar-footer.svelte-12qhfyh:hover,
		.sidebar-footer.active.svelte-12qhfyh {
			background: var(--brand-soft-2);
			box-shadow: var(--shadow-sm);
		}

		.profile-avatar.svelte-12qhfyh {
			width: 36px;
			height: 36px;
			border-radius: 999px;
			background: var(--brand);
			color: white;
			display: inline-flex;
			align-items: center;
			justify-content: center;
			flex-shrink: 0;
			box-shadow: 0 2px 8px rgba(22, 163, 74, 0.3);
		}

		.profile-info.svelte-12qhfyh {
			display: flex;
			flex-direction: column;
			gap: 1px;
			min-width: 0;
		}

		.footer-label.svelte-12qhfyh {
			font-size: 0.7rem;
			color: var(--text-subtle);
			text-transform: uppercase;
			letter-spacing: 0.06em;
			font-weight: 700;
		}

		.sidebar-footer.active.svelte-12qhfyh .footer-label:where(.svelte-12qhfyh) {
			color: var(--brand-strong);
		}

		.footer-value.svelte-12qhfyh {
			font-size: 0.88rem;
			font-weight: 700;
			color: var(--text);
		}

		main.svelte-12qhfyh {
			padding: 32px 40px 40px;
		}

		.container.svelte-12qhfyh {
			max-width: 1120px;
		}
	}

	@media (min-width: 1280px) {
		main.svelte-12qhfyh {
			padding: 40px 56px 56px;
		}
	}
