/* FootGoal page blocks: layout for pages converted from WPBakery (see footgoal-page-blocks.php) */

/* Rows and columns: 30px gutters like WPBakery; a row's --fg-gap overrides them */
.fg-row {
	display: flex;
	flex-wrap: wrap;
	box-sizing: border-box;
	margin-left: calc(var(--fg-gap, 30px) / -2);
	margin-right: calc(var(--fg-gap, 30px) / -2);
}
.fg-col {
	box-sizing: border-box;
	width: 100%;
	min-width: 0;
	padding-left: calc(var(--fg-gap, 30px) / 2);
	padding-right: calc(var(--fg-gap, 30px) / 2);
}
@media (min-width: 768px) {
	.fg-col { width: var(--fg-w, 100%); }
}
.fg-col-inner { box-sizing: border-box; }
.fg-place-middle { align-items: center; }
.fg-place-bottom { align-items: flex-end; }

/* Full-width rows: the background spans the window; content stays in the page column
   unless the row also stretches its content. The theme's content wrappers clip overflow at
   the page column (footgoal-adsense.php, with !important), so they let it through here;
   #wrapper and #page-container still clip at the window edge. */
.fg-html-page #content,
.fg-html-page #content-wrapper { overflow: visible !important; }
.fg-stretch {
	margin-left: calc(50% - 50vw);
	margin-right: calc(50% - 50vw);
	padding-left: calc(50vw - 50% - var(--fg-gap, 30px) / 2);
	padding-right: calc(50vw - 50% - var(--fg-gap, 30px) / 2);
}
.fg-stretch.fg-stretch-content { padding-left: 0; padding-right: 0; }
.fg-no-gap > .fg-col { padding-left: 0; padding-right: 0; }

/* Show/hide by screen size (WPBakery's vc_hidden-* breakpoints) */
@media (max-width: 767px) { .fg-hide-xs { display: none !important; } }
@media (min-width: 768px) and (max-width: 991px) { .fg-hide-sm { display: none !important; } }
@media (min-width: 992px) and (max-width: 1199px) { .fg-hide-md { display: none !important; } }
@media (min-width: 1200px) { .fg-hide-lg { display: none !important; } }

/* Content elements: WPBakery spaced them 35px apart */
.fg-text,
.fg-image,
.fg-cta,
.fg-posts { margin-bottom: 35px; }
.fg-heading { margin-top: 0; }
.fg-heading a { color: inherit; text-decoration: none; }
.fg-image img { max-width: 100%; height: auto; }
.fg-image-center { text-align: center; }
.fg-image-right { text-align: right; }
.fg-cta { padding: 24px; border-radius: 8px; background: #f3f6f9; }
.fg-btn {
	display: inline-block;
	padding: 10px 22px;
	border-radius: 6px;
	background: #01324b;
	color: #fff !important;
	font-weight: 600;
	text-decoration: none !important;
}

/* [footgoal_posts]: card grid, at most --fg-cols across and never narrower than 220px a card,
   so a grid in a narrow column falls back to fewer columns */
.fg-posts {
	--fg-cols: 3;
	display: grid;
	gap: 20px;
	grid-template-columns: repeat(auto-fill, minmax(max(220px, calc((100% - (var(--fg-cols) - 1) * 20px) / var(--fg-cols))), 1fr));
}
.fg-posts-1 { --fg-cols: 1; }
.fg-posts-2 { --fg-cols: 2; }
.fg-posts-4 { --fg-cols: 4; }
.fg-post-card {
	overflow: hidden;
	border: 1px solid #e5e9ee;
	border-radius: 10px;
	background: #fff;
	transition: box-shadow 0.2s;
}
.fg-post-card:hover { box-shadow: 0 6px 18px rgba(1, 50, 75, 0.12); }
.fg-post-link { display: flex; flex-direction: column; height: 100%; color: inherit !important; text-decoration: none !important; }
.fg-post-thumb { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
.fg-post-body { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px 16px; }
.fg-post-cat { color: #1d6fb8; font-size: 11px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.fg-post-title { color: #111827; font-size: 15px; font-weight: 700; line-height: 1.35; }
.fg-post-date { color: #6b7280; font-size: 12px; }
