/* TechBlog Grid Base */
.tbg-body {
	margin: 0;
	background: var(--tbg-light, #0f1115);
	color: #e5e7eb;
	font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

.tbg-body *,
.tbg-app * {
	box-sizing: border-box;
}

.tbg-body a {
	color: inherit;
	text-decoration: none;
}

.tbg-container {
	width: 100%;
	max-width: 1240px;
	margin: 0 auto;
	padding: 0 24px;
}

.tbg-narrow {
	max-width: 860px;
	margin: 0 auto;
}

/* Header */
.tbg-header {
	position: sticky;
	top: 0;
	z-index: 100;
	background: var(--tbg-dark, #0b0b0b);
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	min-height: 74px;
}

.tbg-logo {
	color: #fff;
	font-weight: 900;
	font-size: 1.35rem;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.tbg-logo img {
	max-height: 40px;
	width: auto;
	display: block;
}

.tbg-nav {
	display: flex;
	align-items: center;
	gap: 32px;
}

.tbg-nav a {
	color: #d1d5db;
	font-size: 0.8rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	transition: color 0.2s;
}

.tbg-nav a:hover {
	color: var(--tbg-accent, #f5b400);
}

.tbg-btn,
.tbg-nav a.tbg-btn {
	background: var(--tbg-accent, #f5b400);
	color: #000 !important;
	padding: 10px 22px;
	border-radius: 6px;
	font-weight: 800;
}

.tbg-nav a.tbg-btn:hover {
	filter: brightness(1.1);
}

.tbg-burger {
	display: none;
	background: none;
	border: 0;
	cursor: pointer;
	padding: 8px;
}

.tbg-burger span {
	display: block;
	width: 24px;
	height: 2px;
	background: #fff;
	margin: 5px 0;
	transition: 0.25s;
}

/* Hero */
.tbg-hero {
	position: relative;
	background: var(--tbg-dark, #0b0b0b);
	color: #fff;
	padding: 90px 0 100px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.tbg-hero.has-bg-image {
	background-color: var(--tbg-dark, #0b0b0b);
}

.tbg-eyebrow {
	display: inline-block;
	color: var(--tbg-accent, #f5b400);
	font-size: 0.78rem;
	font-weight: 800;
	letter-spacing: 0.28em;
	text-transform: uppercase;
	margin-bottom: 14px;
}

.tbg-hero h1 {
	font-size: clamp(2.4rem, 6vw, 4.8rem);
	line-height: 1.05;
	margin: 0 0 18px;
	font-weight: 900;
	text-transform: uppercase;
	letter-spacing: -0.02em;
	color: #fff;
}

.tbg-hero p {
	max-width: 650px;
	font-size: 1.15rem;
	color: #9ca3af;
	margin: 0;
	line-height: 1.6;
}

/* Section & Filters */
.tbg-section {
	padding: 60px 0 90px;
}

.tbg-filter {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	margin-bottom: 24px;
}

.tbg-filter__label {
	font-size: 0.75rem;
	font-weight: 800;
	letter-spacing: 0.15em;
	text-transform: uppercase;
	color: #9ca3af;
}

.tbg-cat {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 18px;
	border-radius: 999px;
	background: #1a1e26;
	border: 1px solid rgba(255, 255, 255, 0.08);
	color: #e5e7eb;
	font-weight: 700;
	font-size: 0.85rem;
	transition: 0.2s;
}

.tbg-cat b {
	background: rgba(255, 255, 255, 0.1);
	border-radius: 999px;
	font-size: 0.72rem;
	padding: 2px 7px;
	color: #fff;
}

.tbg-cat:hover {
	border-color: var(--tbg-accent, #f5b400);
	color: #fff;
}

.tbg-cat.is-active {
	background: var(--tbg-accent, #f5b400);
	color: #000;
	border-color: var(--tbg-accent, #f5b400);
}

.tbg-cat.is-active b {
	background: #000;
	color: #fff;
}

.tbg-count {
	font-size: 0.88rem;
	color: #9ca3af;
	margin: 0 0 24px;
}

.tbg-empty {
	text-align: center;
	padding: 60px 0;
	color: #9ca3af;
	font-size: 1.1rem;
}

/* Grid Cards */
.tbg-grid {
	display: grid;
	grid-template-columns: repeat(var(--tbg-cols-d, 3), minmax(0, 1fr));
	gap: 30px;
}

@media (max-width: 1024px) {
	.tbg-grid {
		grid-template-columns: repeat(var(--tbg-cols-t, 2), minmax(0, 1fr));
	}
}

@media (max-width: 640px) {
	.tbg-grid {
		grid-template-columns: repeat(var(--tbg-cols-m, 1), minmax(0, 1fr));
		gap: 20px;
	}
}

.tbg-card {
	background: #161922;
	border: 1px solid rgba(255, 255, 255, 0.07);
	border-radius: 12px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}

.tbg-card:hover {
	transform: translateY(-5px);
	border-color: rgba(245, 180, 0, 0.4);
	box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.tbg-card__img {
	position: relative;
	display: block;
	aspect-ratio: 16/10;
	overflow: hidden;
	background: #0f1115;
}

.tbg-card__img img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.4s;
}

.tbg-card:hover .tbg-card__img img {
	transform: scale(1.05);
}

.tbg-card__ph {
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, #1f242e, #11141a);
}

.tbg-badge {
	position: absolute;
	top: 14px;
	left: 14px;
	background: var(--tbg-accent, #f5b400);
	color: #000;
	font-size: 0.68rem;
	font-weight: 800;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	padding: 4px 10px;
	border-radius: 4px;
}

.tbg-card__body {
	padding: 22px;
	display: flex;
	flex-direction: column;
	flex: 1;
}

.tbg-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 12px;
	font-size: 0.78rem;
	color: #9ca3af;
	margin-bottom: 12px;
}

.tbg-meta span+span::before {
	content: "•";
	margin-right: 12px;
	color: #4b5563;
}

.tbg-card h3 {
	margin: 0 0 10px;
	font-size: 1.25rem;
	line-height: 1.35;
	font-weight: 800;
	color: #fff;
}

.tbg-card h3 a:hover {
	color: var(--tbg-accent, #f5b400);
}

.tbg-card p {
	margin: 0 0 18px;
	color: #9ca3af;
	font-size: 0.92rem;
	line-height: 1.6;
}

.tbg-more {
	margin-top: auto;
	padding-top: 14px;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
	font-weight: 800;
	font-size: 0.78rem;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: #fff;
}

.tbg-more span {
	color: var(--tbg-accent, #f5b400);
	display: inline-block;
	transition: transform 0.2s;
}

.tbg-more:hover span {
	transform: translateX(4px);
}

/* Pagination */
.tbg-pagination {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
	margin-top: 50px;
}

.tbg-pg {
	min-width: 42px;
	height: 42px;
	padding: 0 12px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 6px;
	background: #161922;
	border: 1px solid rgba(255, 255, 255, 0.1);
	color: #fff;
	font-weight: 700;
	transition: 0.2s;
}

a.tbg-pg:hover {
	background: var(--tbg-accent, #f5b400);
	color: #000;
	border-color: var(--tbg-accent, #f5b400);
}

.tbg-pg.is-active {
	background: var(--tbg-accent, #f5b400);
	border-color: var(--tbg-accent, #f5b400);
	color: #000;
}

.tbg-pg--dots {
	border: 0;
	background: none;
	color: #6b7280;
}

.tbg-app {
	transition: opacity 0.2s;
}

.tbg-app.is-loading {
	opacity: 0.4;
	pointer-events: none;
}

/* Single Post Specific Styles */
.tbg-single-page .tbg-hero--single {
	padding: 60px 0 50px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-crumbs {
	font-size: 0.85rem;
	color: #9ca3af;
	margin-bottom: 22px;
	display: flex;
	gap: 8px;
	align-items: center;
}

.tbg-crumbs a {
	color: #9ca3af;
}

.tbg-crumbs a:hover {
	color: var(--tbg-accent, #f5b400);
}

.tbg-single-badges {
	display: flex;
	gap: 8px;
	margin-bottom: 14px;
}

.tbg-single-badges .tbg-badge {
	position: static;
	display: inline-block;
}

.tbg-single-title {
	font-size: clamp(2rem, 4.5vw, 3.4rem);
	line-height: 1.15;
	font-weight: 900;
	margin: 0 0 24px;
	color: #fff;
}

.tbg-byline {
	display: flex;
	align-items: center;
	gap: 14px;
	flex-wrap: wrap;
}

.tbg-byline__avatar img {
	border-radius: 50%;
	display: block;
	border: 2px solid var(--tbg-accent, #f5b400);
}

.tbg-byline__info {
	display: flex;
	flex-direction: column;
}

.tbg-byline__author {
	font-weight: 800;
	font-size: 0.95rem;
	color: #fff;
}

.tbg-byline__date {
	font-size: 0.78rem;
	color: #9ca3af;
}

.tbg-byline__pill {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 10px;
	background: rgba(255, 255, 255, 0.06);
	border-radius: 999px;
	font-size: 0.78rem;
	color: var(--tbg-accent, #f5b400);
	font-weight: 700;
	margin-left: 6px;
}

.tbg-featured {
	margin: 0 0 40px;
	border-radius: 12px;
	overflow: hidden;
	border: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-featured img {
	width: 100%;
	height: auto;
	display: block;
}

.tbg-content {
	font-size: 1.12rem;
	line-height: 1.85;
	color: #d1d5db;
}

.tbg-content h1,
.tbg-content h2,
.tbg-content h3,
.tbg-content h4 {
	color: #fff;
	font-weight: 800;
	margin: 1.8em 0 0.6em;
}

.tbg-content h2 {
	font-size: 1.85rem;
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
	padding-bottom: 8px;
}

.tbg-content h3 {
	font-size: 1.4rem;
}

.tbg-content p {
	margin: 0 0 1.5em;
}

.tbg-content a {
	color: var(--tbg-accent, #f5b400);
	text-decoration: underline;
	text-underline-offset: 4px;
}

.tbg-content blockquote {
	margin: 2em 0;
	padding: 12px 24px;
	border-left: 4px solid var(--tbg-accent, #f5b400);
	background: #161922;
	border-radius: 0 8px 8px 0;
	color: #f3f4f6;
	font-style: italic;
}

.tbg-content pre {
	background: #07080a;
	border: 1px solid rgba(255, 255, 255, 0.1);
	padding: 20px;
	border-radius: 8px;
	overflow-x: auto;
	color: #f8fafc;
	font-size: 0.9rem;
}

.tbg-content code {
	background: #1f242e;
	padding: 2px 6px;
	border-radius: 4px;
	font-size: 0.9em;
	color: var(--tbg-accent, #f5b400);
}

.tbg-content pre code {
	background: none;
	padding: 0;
	color: inherit;
}

.tbg-content img {
	max-width: 100%;
	height: auto;
	border-radius: 8px;
}

.tbg-tags {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
	margin-top: 36px;
	padding-top: 24px;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-tags__label {
	font-size: 0.8rem;
	font-weight: 800;
	text-transform: uppercase;
	color: #9ca3af;
}

.tbg-tags a {
	font-size: 0.78rem;
	font-weight: 700;
	background: #1a1e26;
	border: 1px solid rgba(255, 255, 255, 0.1);
	padding: 4px 12px;
	border-radius: 999px;
	color: #e5e7eb;
}

.tbg-tags a:hover {
	background: var(--tbg-accent, #f5b400);
	color: #000;
	border-color: var(--tbg-accent, #f5b400);
}

.tbg-share {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin: 36px 0;
	padding: 24px;
	background: #161922;
	border-radius: 10px;
	border: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-share__label {
	font-size: 0.82rem;
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.1em;
	color: #fff;
}

.tbg-share__links {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.tbg-share-btn {
	background: #222733;
	color: #e5e7eb !important;
	border: 1px solid rgba(255, 255, 255, 0.06);
	padding: 8px 16px;
	border-radius: 6px;
	font-size: 0.8rem;
	font-weight: 700;
	cursor: pointer;
	transition: 0.2s;
}

.tbg-share-btn:hover {
	background: var(--tbg-accent, #f5b400);
	color: #000 !important;
}

.tbg-postnav {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 20px;
	margin: 40px 0;
}

.tbg-postnav__card {
	display: flex;
	flex-direction: column;
	padding: 20px;
	background: #161922;
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 8px;
	transition: 0.2s;
}

.tbg-postnav__card:hover {
	border-color: var(--tbg-accent, #f5b400);
	transform: translateY(-3px);
}

.tbg-postnav__card--next {
	text-align: right;
}

.tbg-postnav__dir {
	font-size: 0.72rem;
	font-weight: 800;
	letter-spacing: 0.15em;
	text-transform: uppercase;
	color: var(--tbg-accent, #f5b400);
	margin-bottom: 6px;
}

.tbg-postnav__ttl {
	color: #fff;
	font-size: 0.98rem;
	font-weight: 700;
}

.tbg-comments-wrapper {
	margin-top: 50px;
	padding-top: 36px;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-comments-wrapper #respond {
	background: #161922;
	padding: 24px;
	border-radius: 8px;
	border: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-comments-wrapper label {
	display: block;
	font-size: 0.85rem;
	font-weight: 700;
	margin-bottom: 6px;
	color: #d1d5db;
}

.tbg-comments-wrapper input[type="text"],
.tbg-comments-wrapper input[type="email"],
.tbg-comments-wrapper textarea {
	width: 100%;
	background: #0f1115;
	border: 1px solid rgba(255, 255, 255, 0.12);
	color: #fff;
	padding: 10px 14px;
	border-radius: 6px;
	margin-bottom: 16px;
	font-family: inherit;
}

.tbg-comments-wrapper input[type="submit"] {
	background: var(--tbg-accent, #f5b400);
	color: #000;
	border: 0;
	padding: 10px 24px;
	font-weight: 800;
	border-radius: 6px;
	cursor: pointer;
	text-transform: uppercase;
}

.tbg-related {
	margin-top: 70px;
	padding-top: 40px;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-related__heading {
	margin-bottom: 28px;
}

.tbg-related__heading h2 {
	font-size: 2rem;
	font-weight: 900;
	text-transform: uppercase;
	margin: 6px 0 0;
	color: #fff;
}

/* Footer */
.tbg-footer {
	background: var(--tbg-dark, #0b0b0b);
	color: #9ca3af;
	padding: 60px 0 0;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.tbg-footer__inner {
	display: flex;
	flex-wrap: wrap;
	gap: 32px;
	justify-content: space-between;
	align-items: flex-start;
}

.tbg-footer p {
	max-width: 360px;
	margin: 12px 0 0;
}

.tbg-footer__links {
	display: flex;
	flex-wrap: wrap;
	gap: 24px;
}

.tbg-footer__links a {
	color: #e5e7eb;
	font-weight: 700;
	font-size: 0.85rem;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

.tbg-footer__links a:hover {
	color: var(--tbg-accent, #f5b400);
}

.tbg-footer__copy {
	margin-top: 48px;
	padding: 22px 0;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
	font-size: 0.85rem;
	text-align: center;
}

/* Responsive Media Queries */
@media (max-width: 860px) {
	.tbg-burger {
		display: block;
	}

	.tbg-nav {
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		background: var(--tbg-dark, #0b0b0b);
		flex-direction: column;
		align-items: flex-start;
		gap: 0;
		padding: 12px 24px 24px;
		display: none;
		border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	}

	.tbg-nav.is-open {
		display: flex;
	}

	.tbg-nav a {
		padding: 12px 0;
		width: 100%;
	}

	.tbg-nav a.tbg-btn {
		width: auto;
		margin-top: 10px;
	}

	.tbg-hero {
		padding: 60px 0 70px;
	}

	.tbg-postnav {
		grid-template-columns: 1fr;
	}
}

/* =========================================================
   LIGHT-BACKGROUND FIX
   Dark text for everything that sits directly on the page
   background. Cards, hero, header, footer, share box and the
   comment form keep their own dark styling.
   ========================================================= */
.tbg-body {
	color: #1f2937;
}

/* Post content */
.tbg-content {
	color: #2b3340;
}

.tbg-content h1,
.tbg-content h2,
.tbg-content h3,
.tbg-content h4,
.tbg-content h5,
.tbg-content h6 {
	color: #0f1115;
}

.tbg-content h2 {
	border-bottom-color: rgba(0, 0, 0, 0.12);
}

.tbg-content strong,
.tbg-content b {
	color: #0f1115;
}

.tbg-content a {
	color: #b45309;
}

.tbg-content a:hover {
	color: #92400e;
}

.tbg-content li,
.tbg-content ul,
.tbg-content ol {
	color: #2b3340;
}

/* Tags row */
.tbg-tags {
	border-top-color: rgba(0, 0, 0, 0.12);
}

.tbg-tags__label {
	color: #4b5563;
}

/* Comments */
.tbg-comments-wrapper {
	border-top-color: rgba(0, 0, 0, 0.12);
	color: #1f2937;
}

.tbg-comments-wrapper h2,
.tbg-comments-wrapper h3,
.tbg-comments-wrapper .comment-reply-title,
.tbg-comments-wrapper .comments-title {
	color: #0f1115;
}

.tbg-comments-wrapper .comment-body,
.tbg-comments-wrapper .comment-content,
.tbg-comments-wrapper .comment-author,
.tbg-comments-wrapper .comment-metadata,
.tbg-comments-wrapper .logged-in-as,
.tbg-comments-wrapper .comment-notes {
	color: #374151;
}

.tbg-comments-wrapper .comment-metadata a,
.tbg-comments-wrapper .logged-in-as a {
	color: #b45309;
}

/* Comment form box is dark, so keep its text light */
.tbg-comments-wrapper #respond,
.tbg-comments-wrapper #respond .comment-reply-title,
.tbg-comments-wrapper #respond p,
.tbg-comments-wrapper #respond .logged-in-as,
.tbg-comments-wrapper #respond .comment-notes {
	color: #e5e7eb;
}

.tbg-comments-wrapper #respond a {
	color: var(--tbg-accent, #f5b400);
}

/* Related posts section */
.tbg-related {
	border-top-color: rgba(0, 0, 0, 0.12);
}

.tbg-related__heading h2 {
	color: #0f1115;
}

/* Listing page text sitting on the light background */
.tbg-filter__label,
.tbg-count,
.tbg-empty {
	color: #4b5563;
}

.tbg-pg--dots {
	color: #6b7280;
}