/* App shell: sidebar + main column as one centred block (like taniarascia.com); top bar + drawer on small screens. */

.wp-site-blocks {
	padding: 0;
}

.jb-shell {
	display: grid;
	grid-template-columns: 260px minmax(0, 1fr);
	max-width: 1376px;
	min-height: 100vh;
	margin-inline: auto;
}

.jb-chrome {
	position: relative;
}

.jb-topbar {
	display: none;
}

.jb-sidebar {
	position: sticky;
	top: 0;
	display: flex;
	flex-direction: column;
	gap: 1rem;
	height: 100vh;
	padding: 1.75rem 1.5rem;
	border-right: 1px solid var(--wp--preset--color--border);
	background: var(--wp--preset--color--bg);
	overflow-y: auto;
	box-sizing: border-box;
}

.jb-sidebar-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.jb-wordmark {
	color: var(--wp--preset--color--text);
	font-weight: 700;
	text-decoration: none;
}

.jb-wordmark:hover {
	color: var(--wp--preset--color--accent);
	text-decoration: none;
}

.jb-theme-toggle,
.jb-menu {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2rem;
	height: 2rem;
	border: 1px solid var(--wp--preset--color--border);
	border-radius: 6px;
	background: transparent;
	color: var(--wp--preset--color--text);
	cursor: pointer;
	font-size: 1rem;
}

.jb-theme-toggle:hover,
.jb-menu:hover {
	border-color: var(--wp--preset--color--accent);
}

.jb-theme-toggle .jb-sun,
:root[data-theme="light"] .jb-theme-toggle .jb-moon {
	display: none;
}

:root[data-theme="light"] .jb-theme-toggle .jb-sun {
	display: inline;
}

.jb-oneliner {
	margin: 0;
	padding-bottom: 1rem;
	border-bottom: 1px solid var(--wp--preset--color--border);
	color: var(--wp--preset--color--muted);
	font-size: var(--wp--preset--font-size--sm);
	line-height: 1.6;
}

/* A pixel icon inside a line of text, in the accent colour. */
.jb-inline-icon {
	display: inline-block;
	margin-left: 0.3em;
	vertical-align: -0.2em;
	color: var(--wp--preset--color--accent);
}

.jb-inline-icon svg {
	display: block;
	width: 1.15em;
	height: 1.15em;
	fill: currentColor;
}

.jb-nav {
	display: flex;
	flex-direction: column;
	gap: 0.15rem;
}

.jb-nav a {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	padding: 0.4rem 0.6rem;
	border-radius: 6px;
	color: var(--wp--preset--color--text);
	text-decoration: none;
	font-size: var(--wp--preset--font-size--sm);
}

.jb-nav a:hover,
.jb-nav a[aria-current="page"] {
	background: var(--wp--preset--color--surface);
	text-decoration: none;
}

.jb-nav a[aria-current="page"] {
	color: var(--wp--preset--color--accent);
}

.jb-nav-icon {
	display: inline-flex;
	flex: 0 0 auto;
}

.jb-nav-icon svg {
	width: 18px;
	height: 18px;
	fill: currentColor;
}

.jb-sidebar-foot {
	margin-top: auto;
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

.jb-social {
	display: flex;
	gap: 0.85rem;
}

.jb-social a {
	color: var(--wp--preset--color--muted);
	display: inline-flex;
}

.jb-social a:hover {
	color: var(--wp--preset--color--accent);
}

.jb-social svg {
	width: 16px;
	height: 16px;
	fill: currentColor;
}

.jb-small-links {
	display: flex;
	flex-wrap: wrap;
	gap: 0.25rem 0.75rem;
	font-size: var(--wp--preset--font-size--xs);
}

.jb-small-links a {
	color: var(--wp--preset--color--muted);
	text-decoration: none;
}

.jb-small-links a:hover {
	color: var(--wp--preset--color--accent);
}

.jb-main {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.jb-content {
	width: 100%;
	max-width: 1076px;
	padding: 3rem;
	box-sizing: border-box;
	flex: 1;
}

.jb-footer {
	max-width: calc(1076px - 6rem);
	margin: 0 3rem;
	padding: 2rem 0 3rem;
	border-top: 1px solid var(--wp--preset--color--border);
	font-size: var(--wp--preset--font-size--sm);
	color: var(--wp--preset--color--muted);
}

.jb-footer-links {
	display: flex;
	gap: 1.25rem;
}

.jb-footer-links a {
	color: var(--wp--preset--color--muted);
}

.jb-credit {
	margin: 0.75rem 0 0;
}

.jb-scrim {
	display: none;
}

@media (max-width: 899px) {
	.jb-shell {
		grid-template-columns: minmax(0, 1fr);
	}

	.jb-topbar {
		position: sticky;
		top: 0;
		z-index: 30;
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding: 0.75rem 1rem;
		border-bottom: 1px solid var(--wp--preset--color--border);
		background: var(--wp--preset--color--bg);
	}

	.jb-sidebar {
		position: fixed;
		top: 0;
		left: 0;
		z-index: 50;
		width: min(290px, 85vw);
		transform: translateX(-100%);
		visibility: hidden;
		transition: transform 0.2s ease, visibility 0.2s;
	}

	.jb-nav-open .jb-sidebar {
		transform: none;
		visibility: visible;
	}

	.jb-nav-open .jb-scrim {
		display: block;
		position: fixed;
		inset: 0;
		z-index: 40;
		background: rgb(0 0 0 / 0.5);
	}

	.jb-content {
		padding: 1.75rem 1rem;
	}

	.jb-footer {
		margin: 0 1rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	.jb-sidebar {
		transition: none;
	}
}
