/*
Theme Name: Lownkey Blog
Theme URI: https://lownkey.com
Description: A lightweight Ollie child theme for the Lownkey technology blog, styled for a modern tutorial-blog reading experience.
Author: Lownkey
Author URI: https://lownkey.com
Template: ollie
Version: 1.4.0
Requires at least: 6.6
Requires PHP: 7.4
Text Domain: lownkey-blog
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
*/

:root {
	--lownkey-radius-sm: 10px;
	--lownkey-radius-md: 16px;
	--lownkey-radius-lg: 22px;
	--lownkey-shadow-card: 0 8px 28px rgb(15 23 42 / 7%);
	--lownkey-shadow-card-hover: 0 16px 40px rgb(15 23 42 / 12%);
	--lownkey-ease: 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

html {
	scroll-behavior: smooth;
}

body {
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

a {
	transition: color var(--lownkey-ease);
}

/* Header: search | brand | menu (Zento-like) */
.lownkey-header {
	position: sticky;
	top: 0;
	z-index: 100;
	border-bottom: 1px solid color-mix(in srgb, var(--wp--preset--color--border-light) 80%, transparent);
	background: color-mix(in srgb, var(--wp--preset--color--base) 90%, transparent) !important;
	backdrop-filter: blur(16px) saturate(1.15);
	-webkit-backdrop-filter: blur(16px) saturate(1.15);
}

.admin-bar .lownkey-header {
	top: 32px;
}

.lownkey-header__inner {
	display: grid !important;
	grid-template-columns: minmax(2.5rem, 1fr) auto minmax(16rem, 1.6fr);
	align-items: center;
	gap: 0.75rem 1rem;
	width: 100%;
}

.lownkey-header-search {
	justify-self: start;
}

.lownkey-header-brand {
	justify-self: center;
}

.lownkey-header-nav {
	justify-self: end;
	min-width: 0;
}

.lownkey-header-nav .wp-block-navigation__container {
	flex-wrap: nowrap !important;
	gap: 0.35rem 1rem !important;
}

.lownkey-header .wp-block-site-title a {
	color: var(--wp--preset--color--main);
	font-size: clamp(1.35rem, 2.4vw, 1.65rem);
	font-weight: 700;
	letter-spacing: -0.04em;
	text-decoration: none;
}

.lownkey-header .wp-block-search__button {
	min-width: 2.5rem;
	min-height: 2.5rem;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: transparent;
	color: var(--wp--preset--color--primary);
	box-shadow: none;
}

.lownkey-header .wp-block-search__button:hover,
.lownkey-header .wp-block-search__button:focus-visible {
	background: var(--wp--preset--color--primary-accent);
	color: var(--wp--preset--color--primary-alt);
}

.lownkey-header .wp-block-navigation__responsive-container-open {
	padding: 0.4rem 0.55rem;
	border: 1px solid var(--wp--preset--color--border-light);
	border-radius: 12px;
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--main);
}

.lownkey-header .wp-block-navigation__responsive-container-open:hover,
.lownkey-header .wp-block-navigation__responsive-container-open:focus-visible {
	border-color: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--primary);
}

.lownkey-header-nav .wp-block-navigation-item__content {
	white-space: nowrap;
	color: var(--wp--preset--color--main);
	font-family: var(--wp--preset--font-family--dm-sans), sans-serif;
	font-size: 0.9rem;
	font-weight: 600;
	letter-spacing: -0.01em;
	text-decoration: none;
}

.lownkey-header-nav .wp-block-navigation-item__content:hover,
.lownkey-header-nav .wp-block-navigation-item__content:focus-visible,
.lownkey-header-nav .current-menu-item .wp-block-navigation-item__content {
	color: var(--wp--preset--color--primary);
}

.lownkey-header-nav .wp-block-navigation__responsive-container.is-menu-open {
	padding: 1.5rem;
}

.lownkey-header-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item {
	margin: 0.35rem 0;
}

.lownkey-header-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
	font-size: 1.15rem;
	font-weight: 700;
}

/* Intro */
.lownkey-home-intro .wp-block-heading {
	letter-spacing: -0.035em;
	line-height: 1.12;
}

.lownkey-home-intro strong {
	color: var(--wp--preset--color--main);
	font-weight: 700;
}

/* Topics strip — Zento "Trending topics" vibe */
.lownkey-topics-grid,
.lownkey-topics .wp-block-categories-list {
	display: grid !important;
	grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
	gap: 0.85rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.lownkey-topics-grid li,
.lownkey-topics .wp-block-categories-list li {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem;
	min-height: 3.5rem;
	margin: 0;
	padding: 0.85rem 1rem;
	border: 1px solid var(--wp--preset--color--border-light);
	border-radius: 14px;
	background: var(--wp--preset--color--base);
	box-shadow: var(--lownkey-shadow-card);
	color: var(--wp--preset--color--secondary);
	font-size: 0.78rem;
	font-weight: 600;
	transition: transform var(--lownkey-ease), box-shadow var(--lownkey-ease), border-color var(--lownkey-ease);
}

.lownkey-topics-grid a,
.lownkey-topics .wp-block-categories-list a {
	flex: 1;
	color: var(--wp--preset--color--main);
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-size: 0.95rem;
	font-weight: 700;
	letter-spacing: -0.02em;
	text-decoration: none;
}

.lownkey-topics-grid li:hover,
.lownkey-topics .wp-block-categories-list li:hover {
	border-color: color-mix(in srgb, var(--wp--preset--color--primary) 40%, var(--wp--preset--color--border-light));
	box-shadow: var(--lownkey-shadow-card-hover);
	transform: translateY(-3px);
}

.lownkey-topics-grid li:hover a,
.lownkey-topics .wp-block-categories-list li:hover a {
	color: var(--wp--preset--color--primary);
}

/* Hide empty Uncategorized if it appears with (0) */
.lownkey-topics .cat-item-1:has(a[href*="uncategorized"]) {
	display: none;
}

/* Featured card */
.lownkey-featured-card {
	overflow: hidden;
	border: 1px solid var(--wp--preset--color--border-light);
	box-shadow: var(--lownkey-shadow-card);
	transition: box-shadow var(--lownkey-ease), transform var(--lownkey-ease), border-color var(--lownkey-ease);
}

.lownkey-featured-card:hover {
	border-color: color-mix(in srgb, var(--wp--preset--color--primary) 30%, var(--wp--preset--color--border-light));
	box-shadow: var(--lownkey-shadow-card-hover);
	transform: translateY(-3px);
}

.lownkey-featured-card .wp-block-columns {
	align-items: stretch !important;
}

.lownkey-featured-card__media,
.lownkey-featured-card__media .wp-block-post-featured-image,
.lownkey-featured-card__media .wp-block-post-featured-image a {
	height: 100%;
	min-height: 260px;
	margin: 0;
}

.lownkey-featured-card__media .wp-block-post-featured-image img {
	display: block;
	width: 100%;
	height: 100%;
	min-height: 260px;
	object-fit: cover;
	border-radius: 0;
	transition: transform 480ms cubic-bezier(0.22, 1, 0.36, 1);
}

.lownkey-featured-card:hover .wp-block-post-featured-image img {
	transform: scale(1.04);
}

.lownkey-featured-card .wp-block-post-title a,
.lownkey-post-card .wp-block-post-title a {
	color: var(--wp--preset--color--main);
	text-decoration: none;
}

.lownkey-featured-card .wp-block-post-title a:hover,
.lownkey-post-card .wp-block-post-title a:hover {
	color: var(--wp--preset--color--primary);
}

.lownkey-featured-card .wp-block-post-excerpt,
.lownkey-post-card .wp-block-post-excerpt {
	color: var(--wp--preset--color--secondary);
}

/* Post cards */
.lownkey-post-card {
	overflow: hidden;
	border: 1px solid var(--wp--preset--color--border-light);
	box-shadow: var(--lownkey-shadow-card);
	transition: box-shadow var(--lownkey-ease), transform var(--lownkey-ease), border-color var(--lownkey-ease);
}

.lownkey-post-card:hover {
	border-color: color-mix(in srgb, var(--wp--preset--color--primary) 30%, var(--wp--preset--color--border-light));
	box-shadow: var(--lownkey-shadow-card-hover);
	transform: translateY(-4px);
}

.lownkey-post-card__media {
	position: relative;
	overflow: hidden;
}

.lownkey-post-card__media .wp-block-post-featured-image {
	margin: 0;
}

.lownkey-post-card__media .wp-block-post-featured-image img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 16 / 10;
	object-fit: cover;
	transition: transform 480ms cubic-bezier(0.22, 1, 0.36, 1);
}

.lownkey-post-card:hover .wp-block-post-featured-image img {
	transform: scale(1.05);
}

/* Category chips */
.lownkey-category a {
	display: inline-flex;
	align-items: center;
	margin: 0 0.35rem 0.35rem 0;
	padding: 0.28rem 0.7rem;
	border-radius: 999px;
	background: var(--wp--preset--color--primary-accent);
	color: var(--wp--preset--color--primary-alt-accent);
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.04em;
	line-height: 1.2;
	text-decoration: none;
	text-transform: uppercase;
	transition: background var(--lownkey-ease), color var(--lownkey-ease);
}

.lownkey-category a:hover,
.lownkey-category a:focus-visible {
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--base);
}

.lownkey-category--overlay {
	position: absolute;
	top: 0.85rem;
	left: 0.85rem;
	z-index: 2;
	margin: 0;
}

.lownkey-category--overlay a {
	margin: 0;
	background: color-mix(in srgb, var(--wp--preset--color--base) 92%, transparent);
	box-shadow: 0 6px 18px rgb(15 23 42 / 12%);
	backdrop-filter: blur(8px);
}

.lownkey-tags a {
	display: inline-flex;
	margin: 0 0.4rem 0.4rem 0;
	padding: 0.25rem 0.65rem;
	border: 1px solid var(--wp--preset--color--border-light);
	border-radius: 999px;
	color: var(--wp--preset--color--secondary);
	font-size: 0.8rem;
	text-decoration: none;
}

.lownkey-tags a:hover {
	border-color: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--primary);
}

/* Article + sidebar */
.lownkey-article,
.lownkey-comments,
.lownkey-sidebar-card {
	border: 1px solid var(--wp--preset--color--border-light);
	box-shadow: var(--lownkey-shadow-card);
}

/* Comments */
.lownkey-comments .wp-block-comments-title {
	margin-bottom: 0.25rem;
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	letter-spacing: -0.02em;
}

.lownkey-comment {
	background: color-mix(in srgb, var(--wp--preset--color--tertiary) 70%, var(--wp--preset--color--base));
}

.lownkey-comment .wp-block-comment-author-name a,
.lownkey-comment .wp-block-comment-author-name {
	color: var(--wp--preset--color--main);
	font-weight: 700;
	text-decoration: none;
}

.lownkey-comment .wp-block-comment-date a,
.lownkey-comment .wp-block-comment-edit-link a,
.lownkey-comment .wp-block-comment-reply-link a {
	color: var(--wp--preset--color--secondary);
	text-decoration: none;
}

.lownkey-comment .wp-block-comment-reply-link a {
	display: inline-flex;
	margin-top: 0.15rem;
	padding: 0.2rem 0.55rem;
	border-radius: 999px;
	background: var(--wp--preset--color--primary-accent);
	color: var(--wp--preset--color--primary-alt-accent);
	font-weight: 600;
}

.lownkey-comment .wp-block-comment-reply-link a:hover {
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--base);
}

.lownkey-comment .wp-block-comment-content p {
	margin: 0.35rem 0 0;
	color: var(--wp--preset--color--secondary);
	line-height: 1.65;
}

.lownkey-comments .wp-block-comment > .wp-block-group > .wp-block-group.lownkey-comment,
.lownkey-comments .children .lownkey-comment {
	margin-left: 0;
}

.lownkey-comments .children {
	margin: 0.75rem 0 0 1.25rem;
	padding-left: 0.75rem;
	border-left: 2px solid var(--wp--preset--color--border-light);
	list-style: none;
}

.lownkey-comments-form,
.lownkey-comments .comment-respond {
	margin-top: 0.5rem;
	padding-top: 1.25rem;
	border-top: 1px solid var(--wp--preset--color--border-light);
}

.lownkey-comments .comment-reply-title,
.lownkey-comments #reply-title {
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-size: 1.15rem;
	font-weight: 700;
	letter-spacing: -0.02em;
}

.lownkey-comments .comment-form label {
	display: block;
	margin-bottom: 0.35rem;
	color: var(--wp--preset--color--main);
	font-size: 0.85rem;
	font-weight: 600;
}

.lownkey-comments .comment-form-comment,
.lownkey-comments .comment-form-author,
.lownkey-comments .comment-form-email,
.lownkey-comments .comment-form-url {
	margin-bottom: 1rem;
}

.lownkey-comments .comment-form input[type="text"],
.lownkey-comments .comment-form input[type="email"],
.lownkey-comments .comment-form input[type="url"],
.lownkey-comments .comment-form textarea {
	width: 100%;
	max-width: 100%;
	padding: 0.75rem 0.9rem;
	border: 1px solid var(--wp--preset--color--border-light);
	border-radius: 12px;
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--main);
	font: inherit;
	transition: border-color var(--lownkey-ease), box-shadow var(--lownkey-ease);
}

.lownkey-comments .comment-form input[type="text"]:focus,
.lownkey-comments .comment-form input[type="email"]:focus,
.lownkey-comments .comment-form input[type="url"]:focus,
.lownkey-comments .comment-form textarea:focus {
	border-color: var(--wp--preset--color--primary);
	outline: none;
	box-shadow: 0 0 0 3px color-mix(in srgb, var(--wp--preset--color--primary) 18%, transparent);
}

.lownkey-comments .comment-form textarea {
	min-height: 140px;
	resize: vertical;
}

.lownkey-comments .comment-form .form-submit {
	margin-top: 0.5rem;
	margin-bottom: 0;
}

.lownkey-comments .comment-form .submit,
.lownkey-comments .wp-block-button__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.7rem 1.25rem;
	border: 0;
	border-radius: 999px;
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--base);
	cursor: pointer;
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-size: 0.95rem;
	font-weight: 700;
	line-height: 1.2;
	transition: background var(--lownkey-ease), transform var(--lownkey-ease);
}

.lownkey-comments .comment-form .submit:hover,
.lownkey-comments .wp-block-button__link:hover {
	background: var(--wp--preset--color--primary-alt);
	transform: translateY(-1px);
}

.lownkey-comments .logged-in-as,
.lownkey-comments .comment-notes {
	color: var(--wp--preset--color--secondary);
	font-size: 0.85rem;
}

.lownkey-sidebar-column .lownkey-sidebar {
	position: sticky;
	top: 5.5rem;
}

.admin-bar .lownkey-sidebar-column .lownkey-sidebar {
	top: calc(5.5rem + 32px);
}

.lownkey-sidebar-card {
	overflow: hidden;
}

.lownkey-sidebar-title {
	margin: 0 0 0.15rem;
	padding-bottom: 0.7rem;
	border-bottom: 2px solid color-mix(in srgb, var(--wp--preset--color--primary) 22%, var(--wp--preset--color--border-light));
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-weight: 700;
	letter-spacing: -0.02em;
}

.lownkey-sidebar-about__role {
	margin: 0;
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-weight: 700;
	letter-spacing: -0.01em;
}

/* Topics index — numbered rows + count pill */
.lownkey-category-list,
.lownkey-sidebar-topics .wp-block-categories-list {
	counter-reset: lownkey-topic;
	margin: 0;
	padding: 0;
	list-style: none;
}

.lownkey-category-list li,
.lownkey-sidebar-topics .wp-block-categories-list li {
	counter-increment: lownkey-topic;
	display: flex;
	align-items: center;
	gap: 0.65rem;
	margin: 0;
	padding: 0.7rem 0;
	border-bottom: 1px solid color-mix(in srgb, var(--wp--preset--color--border-light) 85%, transparent);
	color: var(--wp--preset--color--secondary);
	font-size: 0.8rem;
	font-weight: 600;
}

.lownkey-category-list li:last-child,
.lownkey-sidebar-topics .wp-block-categories-list li:last-child {
	border-bottom: 0;
	padding-bottom: 0;
}

.lownkey-category-list li::before,
.lownkey-sidebar-topics .wp-block-categories-list li::before {
	content: counter(lownkey-topic);
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 1.55rem;
	height: 1.55rem;
	border-radius: 999px;
	background: var(--wp--preset--color--primary-accent);
	color: var(--wp--preset--color--primary-alt-accent);
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-size: 0.72rem;
	font-weight: 700;
	line-height: 1;
}

.lownkey-category-list a,
.lownkey-sidebar-topics .wp-block-categories-list a {
	flex: 1;
	min-width: 0;
	color: var(--wp--preset--color--main);
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-size: 0.95rem;
	font-weight: 700;
	letter-spacing: -0.015em;
	text-decoration: none;
}

.lownkey-category-list a:hover,
.lownkey-sidebar-topics .wp-block-categories-list a:hover {
	color: var(--wp--preset--color--primary);
}

.lownkey-category-list li,
.lownkey-sidebar-topics .wp-block-categories-list li {
	/* Count text after the link becomes a soft badge look via spacing */
	justify-content: flex-start;
}

.lownkey-sidebar-topics .wp-block-categories-list li {
	font-variant-numeric: tabular-nums;
}

.lownkey-sidebar-topics .cat-item-1:has(a[href*="uncategorized"]) {
	display: none;
}

/* Recent posts — image + title + date rows */
.lownkey-recent-posts.wp-block-latest-posts {
	margin: 0;
	padding: 0;
	list-style: none;
}

.lownkey-recent-posts.wp-block-latest-posts li {
	display: grid;
	grid-template-columns: 72px minmax(0, 1fr);
	grid-template-areas:
		"thumb title"
		"thumb date";
	column-gap: 0.85rem;
	row-gap: 0.2rem;
	align-items: start;
	clear: both;
	margin: 0;
	padding: 0.8rem 0;
	border-bottom: 1px solid color-mix(in srgb, var(--wp--preset--color--border-light) 85%, transparent);
	overflow: visible;
}

.lownkey-recent-posts.wp-block-latest-posts li:first-child {
	padding-top: 0.15rem;
}

.lownkey-recent-posts.wp-block-latest-posts li:last-child {
	border-bottom: 0;
	padding-bottom: 0;
}

.lownkey-recent-posts .wp-block-latest-posts__featured-image,
.lownkey-recent-posts .wp-block-latest-posts__featured-image.alignleft {
	grid-area: thumb;
	float: none;
	margin: 0;
	overflow: hidden;
	border-radius: 12px;
}

.lownkey-recent-posts .wp-block-latest-posts__featured-image a {
	display: block;
	line-height: 0;
}

.lownkey-recent-posts .wp-block-latest-posts__featured-image img {
	display: block;
	width: 72px !important;
	max-width: 72px !important;
	height: 72px !important;
	max-height: 72px !important;
	object-fit: cover;
	transition: transform 360ms cubic-bezier(0.22, 1, 0.36, 1);
}

.lownkey-recent-posts li:hover .wp-block-latest-posts__featured-image img {
	transform: scale(1.05);
}

.lownkey-recent-posts .wp-block-latest-posts__post-title {
	grid-area: title;
	align-self: end;
	color: var(--wp--preset--color--main);
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-size: 0.95rem;
	font-weight: 700;
	letter-spacing: -0.015em;
	line-height: 1.3;
	text-decoration: none;
}

.lownkey-recent-posts .wp-block-latest-posts__post-title:hover {
	color: var(--wp--preset--color--primary);
}

.lownkey-recent-posts .wp-block-latest-posts__post-date {
	grid-area: date;
	align-self: start;
	margin: 0;
	color: var(--wp--preset--color--secondary);
	font-size: 0.78rem;
	font-weight: 500;
}

@media (prefers-reduced-motion: reduce) {
	.lownkey-recent-posts .wp-block-latest-posts__featured-image img {
		transition: none;
	}

	.lownkey-recent-posts li:hover .wp-block-latest-posts__featured-image img {
		transform: none;
	}
}

/* Group styles */
.wp-block-group.is-style-tech-card {
	height: 100%;
	padding: clamp(1.125rem, 2vw, 1.5rem);
	border: 1px solid var(--wp--preset--color--border-light);
	border-radius: var(--lownkey-radius-md);
	background: var(--wp--preset--color--base);
	box-shadow: var(--lownkey-shadow-card);
	transition: border-color var(--lownkey-ease), box-shadow var(--lownkey-ease), transform var(--lownkey-ease);
}

.wp-block-group.is-style-tech-card:hover {
	border-color: var(--wp--preset--color--primary);
	box-shadow: var(--lownkey-shadow-card-hover);
	transform: translateY(-4px);
}

.wp-block-group.is-style-tech-note,
.wp-block-group.is-style-tech-warning,
.wp-block-group.is-style-tech-tip {
	padding: 1rem 1.25rem;
	border-radius: 0 var(--lownkey-radius-sm) var(--lownkey-radius-sm) 0;
}

.wp-block-group.is-style-tech-note {
	border-left: 4px solid var(--wp--preset--color--primary);
	background: var(--wp--preset--color--primary-accent);
}

.wp-block-group.is-style-tech-warning {
	border-left: 4px solid #d97706;
	background: #fffbeb;
}

.wp-block-group.is-style-tech-tip {
	border-left: 4px solid #059669;
	background: #ecfdf5;
}

/* Code blocks */
pre.wp-block-code,
pre.wp-block-code.lownkey-code {
	position: relative;
	overflow: hidden;
	margin: 1.75rem 0;
	padding: 0;
	border: 1px solid #1e293b;
	border-radius: 16px;
	background:
		radial-gradient(120% 80% at 100% 0%, rgb(37 99 235 / 18%), transparent 55%),
		linear-gradient(180deg, #111827 0%, #0b1220 100%);
	box-shadow: 0 14px 36px rgb(15 23 42 / 22%);
	color: #e5e7eb;
	tab-size: 4;
}

.lownkey-code-toolbar {
	display: flex;
	align-items: center;
	gap: 0.65rem;
	min-height: 2.6rem;
	padding: 0.55rem 0.85rem;
	border-bottom: 1px solid rgb(148 163 184 / 18%);
	background: color-mix(in srgb, #0f172a 88%, #1e293b);
}

.lownkey-code-dots {
	display: inline-flex;
	gap: 0.35rem;
}

.lownkey-code-dots i {
	display: block;
	width: 0.55rem;
	height: 0.55rem;
	border-radius: 999px;
	background: #475569;
}

.lownkey-code-dots i:nth-child(1) {
	background: #f87171;
}

.lownkey-code-dots i:nth-child(2) {
	background: #fbbf24;
}

.lownkey-code-dots i:nth-child(3) {
	background: #34d399;
}

.lownkey-code-label {
	flex: 1;
	color: #94a3b8;
	font-family: var(--wp--preset--font-family--urbanist), sans-serif;
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.lownkey-code-body {
	display: grid;
	grid-template-columns: 1fr;
	overflow-x: auto;
	scrollbar-width: thin;
	scrollbar-color: #475569 transparent;
}

.lownkey-code-body.has-line-numbers {
	grid-template-columns: auto 1fr;
}

.lownkey-code-body::-webkit-scrollbar {
	height: 8px;
}

.lownkey-code-body::-webkit-scrollbar-thumb {
	border-radius: 999px;
	background: #475569;
}

.lownkey-code-lines {
	padding: 1.15rem 0 1.3rem 0.95rem;
	border-right: 1px solid rgb(148 163 184 / 12%);
	color: #64748b;
	font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
	font-size: 0.8125rem;
	line-height: 1.75;
	text-align: right;
	user-select: none;
	white-space: pre;
}

pre.wp-block-code code,
pre.wp-block-code code.hljs {
	display: block;
	overflow: visible;
	padding: 1.15rem 1.2rem 1.3rem;
	background: transparent;
	font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
	font-size: 0.875rem;
	line-height: 1.75;
	color: #e2e8f0;
}

.lownkey-code-body.has-line-numbers code {
	padding-left: 0.95rem;
}

.lownkey-copy-code {
	margin-left: auto;
	padding: 0.3rem 0.7rem;
	border: 1px solid rgb(148 163 184 / 28%);
	border-radius: 999px;
	background: rgb(30 41 59 / 85%);
	color: #e2e8f0;
	cursor: pointer;
	font: 600 0.72rem/1.2 var(--wp--preset--font-family--dm-sans), sans-serif;
	letter-spacing: 0.02em;
	transition: background var(--lownkey-ease), border-color var(--lownkey-ease), color var(--lownkey-ease), transform var(--lownkey-ease);
}

.lownkey-copy-code:hover,
.lownkey-copy-code:focus-visible {
	border-color: #93c5fd;
	background: #2563eb;
	color: #fff;
	transform: translateY(-1px);
}

.lownkey-copy-code.is-copied {
	border-color: #34d399;
	background: #065f46;
	color: #ecfdf5;
}

.lownkey-copy-code:focus-visible {
	outline: 2px solid #60a5fa;
	outline-offset: 2px;
}

/* Highlight.js tokens — tuned to the Lownkey dark window */
.hljs-comment,
.hljs-quote {
	color: #94a3b8;
	font-style: italic;
}

.hljs-keyword,
.hljs-selector-tag,
.hljs-literal,
.hljs-section,
.hljs-link {
	color: #c4b5fd;
}

.hljs-string,
.hljs-doctag,
.hljs-regexp,
.hljs-template-variable {
	color: #86efac;
}

.hljs-number,
.hljs-bullet,
.hljs-symbol {
	color: #fbbf24;
}

.hljs-title,
.hljs-title.function_,
.hljs-name,
.hljs-attr,
.hljs-attribute {
	color: #7dd3fc;
}

.hljs-built_in,
.hljs-type,
.hljs-params,
.hljs-variable,
.hljs-template-tag {
	color: #fda4af;
}

.hljs-meta,
.hljs-meta .hljs-keyword,
.hljs-meta .hljs-string {
	color: #fdba74;
}

.hljs-addition {
	color: #86efac;
	background: rgb(16 185 129 / 12%);
}

.hljs-deletion {
	color: #fda4af;
	background: rgb(244 63 94 / 12%);
}

.hljs-emphasis {
	font-style: italic;
}

.hljs-strong {
	font-weight: 700;
}

:not(pre) > code {
	padding: 0.12em 0.42em;
	border: 1px solid color-mix(in srgb, var(--wp--preset--color--primary) 18%, var(--wp--preset--color--border-light));
	border-radius: 6px;
	background: var(--wp--preset--color--primary-accent);
	color: #1d4ed8;
	font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
	font-size: 0.88em;
	font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
	.lownkey-copy-code {
		transition: none;
	}

	.lownkey-copy-code:hover,
	.lownkey-copy-code:focus-visible {
		transform: none;
	}
}

.wp-block-post-content a {
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
}

.wp-block-post-content img {
	border-radius: var(--lownkey-radius-sm);
}

.wp-block-query-pagination a {
	text-decoration: none;
	font-weight: 600;
}

@media (max-width: 960px) {
	.lownkey-header-nav .wp-block-navigation-item__content {
		font-size: 0.82rem;
	}

	.lownkey-header-nav .wp-block-navigation__container {
		gap: 0.25rem 0.7rem !important;
	}
}

@media (max-width: 781px) {
	.admin-bar .lownkey-header {
		top: 46px;
	}

	.lownkey-header__inner {
		grid-template-columns: auto 1fr auto;
	}

	.lownkey-featured-card__media,
	.lownkey-featured-card__media .wp-block-post-featured-image,
	.lownkey-featured-card__media .wp-block-post-featured-image a,
	.lownkey-featured-card__media .wp-block-post-featured-image img {
		min-height: 200px;
	}

	.lownkey-sidebar-column .lownkey-sidebar {
		position: static;
	}

	.lownkey-article,
	.lownkey-comments {
		padding: 1.25rem !important;
	}

	.wp-block-post-title {
		overflow-wrap: anywhere;
	}
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	.lownkey-featured-card,
	.lownkey-post-card,
	.lownkey-topics-grid li,
	.lownkey-topics .wp-block-categories-list li,
	.wp-block-group.is-style-tech-card,
	.lownkey-post-card .wp-block-post-featured-image img,
	.lownkey-featured-card .wp-block-post-featured-image img,
	a {
		transition: none;
	}

	.lownkey-featured-card:hover,
	.lownkey-post-card:hover,
	.lownkey-topics-grid li:hover,
	.lownkey-topics .wp-block-categories-list li:hover,
	.wp-block-group.is-style-tech-card:hover {
		transform: none;
	}

	.lownkey-post-card:hover .wp-block-post-featured-image img,
	.lownkey-featured-card:hover .wp-block-post-featured-image img {
		transform: none;
	}
}
