/* T079 - Blog index + single post.
 * The blog still used the legacy WorkScout look (titlebar hero, flat list).
 * Hide the hero and present the index as a card grid with a tile fallback,
 * plus readable prose on single posts. All posts untouched. */

body.blog #titlebar,
body.single-post #titlebar {
	display: none;
}

/* Index: the posts list becomes a 2-column card grid; the newest post is a
 * full-width featured card. */
body.blog .container.right-sidebar .eleven.columns > .padding-right {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 20px;
	align-items: start;
}

body.blog .post-container {
	display: flex;
	flex-direction: column;
	margin: 0;
	border: 1px solid var(--jf-line, #e2e7f0);
	border-radius: var(--jf-r-md, 12px);
	background: var(--jf-surface, #fff);
	overflow: hidden;
	transition: border-color .15s ease, box-shadow .15s ease;
}

body.blog .post-container:hover {
	border-color: var(--jf-brand, #07b1e5);
	box-shadow: 0 8px 20px rgba(11, 38, 104, .1);
}

/* Image/tile fallback band (posts here have no featured image). */
body.blog .post-container::before {
	content: "";
	display: block;
	height: 96px;
	background: linear-gradient(135deg, var(--jf-navy, #0b2668), var(--jf-action, #0369a1));
}

body.blog .post-container .post-content {
	display: block;
	padding: 18px;
}

body.blog .post-container .post-content h3 {
	margin: 0 0 8px;
	font-size: 19px;
	line-height: 1.35;
	font-weight: 700;
}

body.blog .post-container .post-content h3 a {
	color: var(--jf-navy, #0b2668);
	text-decoration: none;
}

body.blog .post-container .post-content h3 a:hover {
	text-decoration: underline;
}

body.blog .post-container .entry-meta {
	color: var(--jf-muted, #60708a);
	font-size: 13px;
}

body.blog .post-container .post-content p {
	margin: 8px 0 0;
	color: var(--jf-body, #3a4250);
	font-size: 15px;
	line-height: 1.6;
}

/* Newest post = featured. */
body.blog .post-container:first-child {
	grid-column: 1 / -1;
}

body.blog .post-container:first-child::before {
	height: 150px;
}

body.blog .post-container:first-child .post-content h3 {
	font-size: 24px;
}

/* Sidebar widgets as cards. */
body.blog .sidebar .widget-box {
	border-radius: var(--jf-r-md, 12px);
}

/* Pagination (when the blog grows past one page) -> shared look. */
body.blog .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 36px;
	height: 36px;
	padding: 0 8px;
	border: 1px solid var(--jf-line, #e2e7f0);
	border-radius: var(--jf-r-sm, 8px);
	background: var(--jf-surface, #fff);
	color: var(--jf-body, #3a4250);
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
}

body.blog .page-numbers.current {
	background: var(--jf-navy, #0b2668);
	border-color: var(--jf-navy, #0b2668);
	color: #fff;
}

/* Single post: readable prose. */
body.single-post .post-content {
	font-size: 17px;
	line-height: 1.75;
	color: var(--jf-body, #3a4250);
}

body.single-post .post-content h2,
body.single-post .post-content h3 {
	color: var(--jf-navy, #0b2668);
	line-height: 1.3;
}

body.single-post .post-content a {
	color: var(--jf-action, #0369a1);
}

@media (max-width: 900px) {
	body.blog .container.right-sidebar .eleven.columns > .padding-right {
		grid-template-columns: 1fr;
	}
}

/* ==========================================================================
 * T079 rework (lead QC): top spacing, equal-height cards, heading scale,
 * action-blue buttons; single-post prose (lists/table) + legacy sidebar off.
 * ========================================================================== */

/* 1. Top spacing under the (hidden) titlebar. */
body.blog .container.right-sidebar { padding-top: 40px; }

/* 2. Equal-height cards. */
body.blog .container.right-sidebar .eleven.columns > .padding-right { align-items: stretch; grid-auto-rows: 1fr; }
body.blog .post-container { height: 100%; }

/* 3. Heading scale. */
body.blog .post-container .post-content h3 { font-size: 18px; }
body.blog .post-container:first-child .post-content h3 { font-size: 24px; }

/* 4. Read More -> action blue (was vendor cyan). */
body.blog .post-container a.button {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 10px 18px;
	border: 0;
	border-radius: var(--jf-r-sm, 8px);
	background: var(--jf-action, #0369a1);
	color: #fff;
	font-weight: 600;
}
body.blog .post-container a.button:hover { background: var(--jf-action-hover, #075985); color: #fff; }
body.blog .post-container a.button:focus-visible { outline: none; box-shadow: var(--jf-focus, 0 0 0 3px rgba(7, 177, 229, .28)); }

/* Sidebar widget buttons (e.g. "Drop Us a Line") -> action blue. */
body.blog .sidebar a.button,
body.blog .sidebar input[type="submit"] {
	background: var(--jf-action, #0369a1);
	border: 0;
	border-radius: var(--jf-r-sm, 8px);
	color: #fff;
	font-weight: 600;
}
body.blog .sidebar a.button:hover,
body.blog .sidebar input[type="submit"]:hover { background: var(--jf-action-hover, #075985); color: #fff; }

/* 5. Single post: hide the legacy sidebar, widen the article, style prose. */
body.single-post .five.columns.sidebar { display: none; }
body.single-post .eleven.columns { width: 100%; }
body.single-post .post-content h2 { font-size: 24px; font-weight: 700; color: var(--jf-navy, #0b2668); margin: 30px 0 10px; }
body.single-post .post-content h3 { font-size: 20px; font-weight: 700; color: var(--jf-navy, #0b2668); margin: 24px 0 8px; }
body.single-post .post-content ul,
body.single-post .post-content ol { margin: 0 0 18px; padding-left: 22px; }
body.single-post .post-content li { margin: 6px 0; }
body.single-post .post-content blockquote { margin: 20px 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--jf-brand, #07b1e5); color: var(--jf-body, #3a4250); }
body.single-post .post-content table { width: 100%; border-collapse: collapse; border: 1px solid var(--jf-line, #e2e7f0); border-radius: var(--jf-r-sm, 8px); overflow: hidden; }
body.single-post .post-content th,
body.single-post .post-content td { padding: 10px 12px; border-bottom: 1px solid var(--jf-line, #e2e7f0); text-align: left; vertical-align: top; }
body.single-post .post-content th { background: var(--jf-neutral-wash, #eef1f5); font-weight: 700; }
body.single-post .post-content table tr:last-child td { border-bottom: 0; }

@media (max-width: 640px) {
	body.single-post .post-content table { display: block; width: 100%; overflow-x: auto; white-space: nowrap; }
}

/* T079 follow-up (QC): the vendor .post-content border drew a second frame
 * inside every card (duplicate frame); and the sidebar titles mixed 20px/24px.
 * Index: drop the inner frame (the .post-container is the frame). */
body.blog .post-container .post-content { border: 0; border-radius: 0; }

/* Sidebar heading sizes -> one scale. */
body.blog .sidebar .widget-title,
body.blog .sidebar .wp-block-heading,
body.blog .sidebar h3,
body.blog .sidebar h4 {
	font-size: 18px;
	font-weight: 700;
	color: var(--jf-navy, #0b2668);
}

/* ==========================================================================
   T079 lead rebuild: blog index is a real page (home.php) - topic chips,
   featured story, card grid, CTA. The legacy body.blog rules above are inert
   now that the WorkScout markup is gone; the single-post rules still apply.
   ========================================================================== */
.jfblog { padding: 40px 0 64px; background: var(--jf-page, #f7f9fc); }
.jfblog__wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }

.jfblog__topics { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 28px; }
.jfblog__chip {
	display: inline-flex; align-items: center; min-height: 36px; padding: 0 16px;
	border: 1px solid var(--jf-line-strong, #d4dce9); border-radius: 999px;
	background: var(--jf-surface, #fff); color: var(--jf-navy, #0b2668);
	font-size: 14px; font-weight: 600; text-decoration: none;
	transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.jfblog__chip:hover { border-color: var(--jf-action, #0369a1); color: var(--jf-action, #0369a1); }
.jfblog__chip:focus-visible { outline: none; box-shadow: var(--jf-focus, 0 0 0 3px rgba(7, 177, 229, .28)); }
.jfblog__chip.is-active { background: var(--jf-navy, #0b2668); border-color: var(--jf-navy, #0b2668); color: #fff; }

.jfblog__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }

.jfblog-card {
	display: flex; flex-direction: column; overflow: hidden; margin: 0;
	border: 1px solid var(--jf-line, #e2e7f0); border-radius: var(--jf-r-md, 12px);
	background: var(--jf-surface, #fff);
	transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.jfblog-card:hover { border-color: var(--jf-brand, #07b1e5); box-shadow: 0 10px 24px rgba(11, 38, 104, .1); transform: translateY(-2px); }

.jfblog-card__cover {
	position: relative; display: flex; align-items: center; justify-content: center;
	height: 160px; color: rgba(255, 255, 255, .9); overflow: hidden;
	background: linear-gradient(135deg, var(--jf-navy, #0b2668), var(--jf-action, #0369a1));
}
.jfblog-card__cover--employers { background: linear-gradient(135deg, var(--jf-action, #0369a1), var(--jf-brand, #07b1e5)); }
.jfblog-card__cover--job-seekers { background: linear-gradient(135deg, var(--jf-navy, #0b2668), #1e4fa8); }
.jfblog-card__cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.jfblog-card__icon { opacity: .55; }
.jfblog-card__label {
	position: absolute; left: 16px; bottom: 14px; padding: 4px 10px; border-radius: 999px;
	background: rgba(255, 255, 255, .16); color: #fff; font-size: 12px; font-weight: 700;
	letter-spacing: .04em; text-transform: uppercase; backdrop-filter: blur(2px);
}

.jfblog-card__body { display: flex; flex: 1; flex-direction: column; padding: 20px 22px 22px; }
.jfblog-card__meta { display: flex; gap: 8px; margin-bottom: 8px; font-size: 13px; color: var(--jf-muted, #64748b); }
.jfblog-card__title { margin: 0 0 10px; font-size: 19px; font-weight: 700; line-height: 1.3; }
.jfblog-card__title a { color: var(--jf-navy, #0b2668); text-decoration: none; }
.jfblog-card__title a:hover { color: var(--jf-action, #0369a1); }
.jfblog-card__title a:focus-visible { outline: none; box-shadow: var(--jf-focus, 0 0 0 3px rgba(7, 177, 229, .28)); }
.jfblog-card__excerpt { margin: 0 0 16px; font-size: 15px; line-height: 1.6; color: var(--jf-body, #3a4250); }
.jfblog-card__more { margin-top: auto; font-size: 14px; font-weight: 600; color: var(--jf-action, #0369a1); text-decoration: none; }
.jfblog-card__more:hover { text-decoration: underline; }

/* Featured (first post on page 1): full-width, cover beside the text. */
.jfblog-card--featured { grid-column: 1 / -1; flex-direction: row; }
.jfblog-card--featured .jfblog-card__cover { flex: 0 0 42%; height: auto; min-height: 280px; }
.jfblog-card--featured .jfblog-card__body { justify-content: center; padding: 32px 36px; }
.jfblog-card--featured .jfblog-card__title { font-size: 28px; }
.jfblog-card--featured .jfblog-card__excerpt { font-size: 16px; }

.jfblog__pagination { margin: 36px 0 0; }
.jfblog__pagination .nav-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; }
.jfblog__pagination .page-numbers {
	display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 12px;
	border: 1px solid var(--jf-line-strong, #d4dce9); border-radius: var(--jf-r-sm, 8px); background: #fff;
	color: var(--jf-navy, #0b2668); font-size: 14px; font-weight: 600; text-decoration: none;
}
.jfblog__pagination .page-numbers.current { background: var(--jf-navy, #0b2668); border-color: var(--jf-navy, #0b2668); color: #fff; }

.jfblog__empty { padding: 40px 0; text-align: center; color: var(--jf-body, #3a4250); }

.jfblog__cta {
	display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px;
	margin-top: 48px; padding: 28px 32px; border-radius: var(--jf-r-lg, 16px);
	background: var(--jf-navy, #0b2668); color: #fff;
}
.jfblog__cta h2 { margin: 0 0 4px; font-size: 22px; line-height: 1.3; font-weight: 700; color: #fff; }
.jfblog__cta p { margin: 0; font-size: 15px; color: rgba(255, 255, 255, .85); }
.jfblog__cta-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.jfblog__btn {
	display: inline-flex; align-items: center; min-height: 44px; padding: 0 22px; border-radius: var(--jf-r-sm, 8px);
	border: 1px solid rgba(255, 255, 255, .6); color: #fff; font-size: 15px; font-weight: 600; text-decoration: none;
}
.jfblog__btn:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.jfblog__btn--primary { background: #fff; border-color: #fff; color: var(--jf-navy, #0b2668); }
.jfblog__btn--primary:hover { background: #eaf2fb; color: var(--jf-navy, #0b2668); }
.jfblog__btn:focus-visible { outline: none; box-shadow: var(--jf-focus, 0 0 0 3px rgba(7, 177, 229, .28)); }

@media (max-width: 1023px) {
	.jfblog__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
	.jfblog { padding: 24px 0 48px; }
	.jfblog__grid { grid-template-columns: 1fr; gap: 20px; }
	.jfblog-card--featured { flex-direction: column; }
	.jfblog-card--featured .jfblog-card__cover { flex: none; min-height: 0; height: 160px; }
	.jfblog-card--featured .jfblog-card__body { padding: 20px 22px 22px; }
	.jfblog-card--featured .jfblog-card__title { font-size: 22px; }
	.jfblog__cta { padding: 24px 20px; }
}
