/*
Theme Name: faith & footnotes
Description: A custom block theme scaffolded by Studio Code.
Requires at least: 6.7
Tested up to: 6.9
Requires PHP: 7.2
Version: 0.1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: faith-footnotes
Tags: full-site-editing, block-patterns, block-styles, wide-blocks, accessibility-ready, style-variations
*/

/* WordPress inserts a margin-block-start equal to the block gap (24px unless
   theme.json sets styles.spacing.blockGap) between the template's top-level
   sections (header part, main, footer part) — a gap that exists even when no
   markup asks for it. Zero it so sections butt edge-to-edge and own their
   vertical rhythm via padding; this does not affect block gaps inside nested
   layouts. */
.wp-site-blocks > * + * {
	margin-block-start: 0;
}

/* With that gap gone, main carries its own vertical padding so templates this
   theme does not author (WooCommerce shop, product, cart…) still clear the
   header and footer. A descendant selector, not a child one: WooCommerce wraps
   the single-product main in an extra group. Templates built from full-bleed
   sections opt out with is-flush and let the sections own the rhythm. */
.wp-site-blocks main {
	padding-block: var(--wp--preset--spacing--60) var(--wp--preset--spacing--70);
}
.wp-site-blocks main.is-flush {
	padding-block: 0;
}

/* === tokens === */
:root {
	--site-bg: var(--wp--preset--color--background);
	--site-text: var(--wp--preset--color--text);
	--surface: var(--wp--preset--color--surface);
	--accent: var(--wp--preset--color--accent);
	--ochre: var(--wp--preset--color--ochre);
	--ink: #4a5133;
	--muted: rgba(74, 81, 51, 0.66);
	--border: rgba(74, 81, 51, 0.14);
	--card-lift: translateY(-4px);
}

/* === header === */
.site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	background: rgba(246, 240, 230, 0.9);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border-bottom: 1px solid var(--border);
	padding-top: 1rem;
	padding-bottom: 1rem;
}
.site-header .wp-block-site-title {
	font-family: var(--wp--preset--font-family--figtree);
	font-weight: 600;
	font-size: 1.3rem;
	letter-spacing: -0.01em;
}
.site-header .wp-block-site-title a {
	color: var(--site-text);
	text-decoration: none;
}
.site-nav .wp-block-navigation-item a {
	font-family: var(--wp--preset--font-family--poppins);
	font-size: 0.95rem;
	color: var(--site-text);
	text-decoration: none;
}
.site-nav .wp-block-navigation-item a:hover {
	color: var(--accent);
}

/* === photo grid & cards === */
.post-grid {
	--wp--style--block-gap: 1.75rem;
}
.post-grid .wp-block-post-template {
	gap: 1.75rem;
}
.photo-card {
	background: var(--surface);
	border-radius: 14px;
	padding: 1rem;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.photo-card:hover {
	transform: var(--card-lift);
	box-shadow: 0 14px 34px rgba(74, 81, 51, 0.12);
}
.photo-card .wp-block-post-featured-image {
	margin: 0;
}
.photo-card .wp-block-post-featured-image img {
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	border-radius: 10px;
	display: block;
}
.photo-card-meta {
	margin-top: 1rem;
}
.photo-card-cat {
	font-family: var(--wp--preset--font-family--poppins);
	font-size: 0.72rem;
	font-weight: 500;
	letter-spacing: 0.07em;
	text-transform: uppercase;
	color: var(--accent);
}
.photo-card .wp-block-post-title {
	margin-top: 0.45rem;
	font-family: var(--wp--preset--font-family--figtree);
	font-size: 1.15rem;
	font-weight: 600;
	line-height: 1.3;
}
.photo-card .wp-block-post-title a {
	color: var(--site-text);
	text-decoration: none;
}
.photo-card .wp-block-post-title a:hover {
	color: var(--accent);
}
.post-grid .wp-block-query-pagination {
	margin-top: 2.5rem;
	justify-content: center;
}

/* === archive & blog index headings === */
.archive-page {
	padding-top: 3rem;
}
.archive-heading {
	margin-bottom: 2.5rem;
}
.archive-heading h1, .archive-heading .wp-block-query-title {
	font-family: var(--wp--preset--font-family--figtree);
	font-weight: 600;
	margin: 0;
}
.archive-heading .wp-block-term-description {
	color: var(--muted);
	max-width: 55ch;
}

/* === single post === */
.single-post {
	padding-top: 3.5rem;
}
.single-hero-meta {
	margin-bottom: 2.5rem;
}
.single-cats a {
	font-family: var(--wp--preset--font-family--poppins);
	font-size: 0.75rem;
	font-weight: 500;
	letter-spacing: 0.07em;
	text-transform: uppercase;
	color: var(--accent);
	text-decoration: none;
}
.single-cats a:hover {
	text-decoration: underline;
}
.single-post .wp-block-post-title {
	margin-top: 0.9rem;
}
.single-byline {
	color: var(--muted);
	font-family: var(--wp--preset--font-family--poppins);
	font-size: 0.9rem;
}
.single-post .wp-block-post-featured-image img {
	border-radius: 14px;
}
.single-post .wp-block-post-content {
	font-family: var(--wp--preset--font-family--poppins);
	font-size: 1.05rem;
	line-height: 1.75;
}
.single-tags a {
	color: var(--muted);
	text-decoration: none;
}
.single-tags a:hover {
	color: var(--accent);
}
.single-post .wp-block-post-navigation-link {
	font-family: var(--wp--preset--font-family--poppins);
}

/* === footer === */
.site-footer {
	background: var(--surface);
	margin-top: 5rem;
	padding-top: 4.5rem;
	padding-bottom: 2.5rem;
}
.site-footer .wp-block-site-title {
	font-family: var(--wp--preset--font-family--figtree);
	font-weight: 600;
	font-size: 1.4rem;
}
.site-footer .wp-block-site-title a {
	color: var(--site-text);
	text-decoration: none;
}
.footer-note {
	color: var(--muted);
	max-width: 40ch;
	margin-top: 0.75rem;
}
.footer-heading {
	font-family: var(--wp--preset--font-family--poppins);
	font-weight: 500;
	font-size: 0.8rem;
	letter-spacing: 0.07em;
	text-transform: uppercase;
	color: var(--muted);
	margin: 0 0 0.9rem;
}
.site-footer .wp-block-columns {
	gap: 2.5rem;
}
.footer-nav {
	--wp--style--block-gap: 0;
}
.footer-nav .wp-block-navigation-item a {
	font-family: var(--wp--preset--font-family--poppins);
	font-size: 0.95rem;
	color: var(--site-text);
	text-decoration: none;
	padding: 0.22rem 0;
}
.footer-nav .wp-block-navigation-item a:hover {
	color: var(--accent);
}
.footer-rule {
	border-color: var(--border);
	margin-top: 3rem;
	margin-bottom: 1.75rem;
}
.footer-copy {
	color: var(--muted);
	font-size: 0.85rem;
}

/* === responsive === */
@media (max-width: 900px) {
	.post-grid .wp-block-post-template {
		grid-template-columns: repeat(2, 1fr);
		gap: 1.25rem;
	}
}
@media (max-width: 600px) {
	.post-grid .wp-block-post-template {
		grid-template-columns: 1fr;
		gap: 1.1rem;
	}
	.site-footer .wp-block-columns {
		flex-direction: column;
		gap: 2rem;
	}
}

/* === motion === */
@media (prefers-reduced-motion: reduce) {
	.photo-card {
		transition: none;
		transform: none;
	}
	.site-header {
		backdrop-filter: none;
	}
	html {
		scroll-behavior: auto;
	}
}

/* === shared eyebrow === */
.eyebrow {
	font-family: var(--wp--preset--font-family--poppins);
	font-size: 0.78rem;
	font-weight: 500;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--accent);
}

/* === home hero === */
.home-hero {
	text-align: center;
	padding-top: 5.5rem;
	padding-bottom: 3rem;
}
.home-eyebrow {
	justify-content: center;
	margin-bottom: 1.5rem;
}
.home-title {
	margin: 0;
	color: var(--site-text);
}
.home-lead {
	max-width: 56ch;
	margin: 1.4rem auto 2rem;
	color: var(--muted);
}
.home-hero .wp-block-buttons {
	justify-content: center;
}
.home-feature {
	margin-top: 2.5rem;
}
.home-feature img {
	border-radius: 16px;
}

/* === home intro === */
.home-intro {
	padding-top: 3.5rem;
	padding-bottom: 1rem;
}
.home-intro-text {
	max-width: 60ch;
	margin-inline: auto;
	text-align: center;
	font-size: 1.12rem;
	line-height: 1.8;
	color: var(--site-text);
}

/* === categories === */
.home-cats {
	padding-top: 2.5rem;
}
.section-title {
	font-size: 1.75rem;
	margin: 0 0 2rem;
	color: var(--site-text);
}
.home-cats .wp-block-columns {
	gap: 1.5rem;
}
.cat-card {
	background: var(--surface);
	border-radius: 14px;
	padding: 1.75rem;
	height: 100%;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.cat-card:hover {
	transform: var(--card-lift);
	box-shadow: 0 14px 34px rgba(74, 81, 51, 0.1);
}
.cat-card h3 {
	font-size: 1.2rem;
	margin: 0 0 0.6rem;
}
.cat-card p {
	color: var(--muted);
	font-size: 0.95rem;
	margin: 0;
}
.cat-link {
	margin-top: 1.2rem;
}
.cat-link a {
	font-family: var(--wp--preset--font-family--poppins);
	font-weight: 500;
	font-size: 0.82rem;
	letter-spacing: 0.07em;
	text-transform: uppercase;
	color: var(--accent);
	text-decoration: none;
}
.cat-link a:hover {
	text-decoration: underline;
}

/* === home cta === */
.home-cta {
	background: var(--surface);
	margin-top: 5.5rem;
	padding-top: 5.5rem;
	padding-bottom: 5.5rem;
	text-align: center;
}
.home-cta-title {
	font-size: 2rem;
	margin: 0;
	color: var(--site-text);
}
.home-cta-text {
	max-width: 52ch;
	margin: 1rem auto 1.75rem;
	color: var(--muted);
}
.home-cta .wp-block-buttons {
	justify-content: center;
}

/* === blog intro === */
.blog-intro {
	text-align: center;
	padding-top: 5rem;
	padding-bottom: 2.5rem;
}
.blog-eyebrow {
	justify-content: center;
	margin-bottom: 1.25rem;
}
.blog-title {
	margin: 0;
	color: var(--site-text);
}
.blog-lead {
	max-width: 52ch;
	margin: 1.1rem auto 0;
	color: var(--muted);
}
.blog-grid-wrap {
	padding-bottom: 4rem;
}

/* hero titles: size the big display headline via CSS (the display preset does
   not survive serialization on these one-off page headings) */
.home-title, .blog-title, .about-title {
	font-size: clamp(2.25rem, 5.5vw, 4.25rem);
	line-height: 1.12;
	letter-spacing: -0.02em;
}

/* grids that sit directly in a template <main> (no inset wrapper) need the
   root gutter so cards don't touch the viewport edge */
.archive-page .post-grid, .blog-index .post-grid {
	padding-inline: var(--wp--style--root--padding-left);
}

/* === about === */
.about-hero {
	padding-top: 5rem;
	padding-bottom: 2.5rem;
}
.about-eyebrow {
	margin-bottom: 1.25rem;
}
.about-title {
	margin: 0 0 1rem;
	color: var(--site-text);
}
.about-lead {
	max-width: 60ch;
	font-size: 1.15rem;
	line-height: 1.8;
	color: var(--muted);
}
.about-columns {
	padding-top: 1rem;
	gap: 2.75rem;
}
.about-photo img {
	border-radius: 14px;
}
.about-columns .wp-block-column > p {
	color: var(--site-text);
}
.cat-card:hover,
.photo-card:hover {
	transition-duration: 0.3s;
}



