/*
Theme Name: Aufo
Text Domain: aufo
Description: WordPress block theme for Audito formulė, UAB — Tabloid Print design system (Fraunces / Inter / JetBrains Mono on a cream paper background with bordeaux accents). Built as a native Gutenberg FSE theme: design tokens in theme.json, templates/, parts/, patterns/.
Version: 0.2.0
Requires at least: 6.5
Tested up to: 6.8
Requires PHP: 8.1
License: MIT
*/

/* Tabloid Print — design system. Everything is also expressed in
 * theme.json (which is the source of truth for the editor). The CSS
 * below covers the body-level rules that FSE blocks cannot reach
 * (page background grid, custom utility classes used by patterns).
 */
:root {
	--aufo-gutter: clamp(1.25rem, 4vw, 2.5rem);
	--aufo-section-y: clamp(3rem, 6vw, 6rem);
	--aufo-rule: var(--wp--preset--color--rule, #C8C0AB);
	--aufo-paper: var(--wp--preset--color--paper, #EDE7D8);
}

html,
body {
	margin: 0;
	padding: 0;
}

body {
	background-color: var(--aufo-paper);
	background-image: radial-gradient(circle at 1px 1px, rgba(13, 20, 22, 0.05) 1px, transparent 0);
	background-size: 18px 18px;
	background-attachment: fixed;
	/* Viewport-bleed bands (below) are wider than the client area by the
	 * scrollbar width — clip the overhang instead of showing an
	 * horizontal scrollbar. */
	overflow-x: clip;
}

/* Newspaper-rule utility (used by header / patterns for double borders). */
.aufo-rule-double {
	border-style: double;
	border-width: 4px 0;
}

/* Wide inner padding (full-bleed bands reach the viewport edges). */
.aufo-full-bleed {
	margin-left: calc(-1 * var(--aufo-gutter));
	margin-right: calc(-1 * var(--aufo-gutter));
}

/* Service-article CTA band: escape the constrained post-content column
 * (main caps it at 1240px) and span the actual viewport edge to edge.
 * 100vw includes the scrollbar; body{overflow-x:clip} hides the overhang.
 * !important + doubled class beats core's
 * ".has-global-padding ... > .alignfull { margin: 0 }". */
.wp-block-group.tb-cta--bleed.tb-cta--bleed {
	width: 100vw;
	margin-left: calc(50% - 50vw) !important;
	margin-right: calc(50% - 50vw) !important;
}

/* Header / footer container rows (alignwide in a constrained group):
 * span --wide and keep the gutter inset, like .container in the
 * concept (max-width:var(--wide); margin:0 auto; padding:0 var(--gutter)). */
.site-header > .alignwide,
.site-footer > .alignwide {
	padding-left: var(--aufo-gutter);
	padding-right: var(--aufo-gutter);
}

/* CTA band button (paper on bordeaux): hover flips to ink, per the
 * concept (.tb-cta .btn:hover). WP palette classes ship with
 * !important, so the override needs it too; without this the button
 * is frozen on hover (palette classes beat both the theme.json
 * global hover and any normal-specificity rule). */
.tb-cta .wp-block-button__link:hover,
.tb-cta .wp-block-button__link:focus {
	background-color: var(--wp--preset--color--ink) !important;
	border-color: var(--wp--preset--color--ink) !important;
	color: var(--wp--preset--color--paper) !important;
}

/* Services grid: equal card heights. Columns already stretch to the
 * tallest sibling; make the card fill its column so the borders align. */
.tb-services .wp-block-column {
	display: flex;
	flex-direction: column;
}

.tb-services .tb-card {
	flex-grow: 1;
	/* Flex column so the content group can fill the leftover height and
	 * the "Plačiau" link (margin-top:auto) pins to the card bottom —
	 * links line up across cards regardless of description length. */
	display: flex;
	flex-direction: column;
}

.tb-services .tb-card > .wp-block-group {
	flex-grow: 1;
	display: flex;
	flex-direction: column;
}

/* The "Plačiau" link row must not stretch as a flex item: its red
 * underline belongs to the text width, not the full card width. */
.tb-services .tb-card > .wp-block-group > p:last-child {
	align-self: flex-start;
}

/* ISO certifications grid: equal card heights — same trick as the
 * services grid: the column becomes a flex container and the card
 * grows to fill it, so all four borders line up. */
.tb-iso .wp-block-column {
	display: flex;
	flex-direction: column;
}

.tb-iso .wp-block-column > .wp-block-group {
	flex-grow: 1;
}

/* News grid: same visual rhythm as services-grid, no images. The grid
 * layout on post-template lays out cards in equal cells; each card uses
 * flex column so the "Skaityti toliau →" link pins to the card bottom. */
.tb-news-query .wp-block-post-template {
	display: grid !important;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: var(--wp--preset--spacing--40, 1.5rem);
}

.tb-news-query .tb-news-card {
	display: flex;
	flex-direction: column;
	height: 100%;
}

.tb-news-query .tb-news-card > p:last-child {
	align-self: flex-start;
}

/* "Skaityti toliau →" is a real wp:read-more link in the news-grid
 * pattern — it must carry the same monospace, uppercase, red-underline
 * treatment as the previous static anchor and pin to the card bottom. */
.tb-news-query .wp-block-read-more {
	font-family: var(--wp--preset--font-family--jetbrains-mono, ui-monospace, monospace);
	font-size: 0.75rem;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wp--preset--color--ink, #0D1416);
	border-bottom: 2px solid var(--wp--preset--color--accent, #B83A2E);
	padding-bottom: 0.25rem;
	margin-top: auto;
	margin-bottom: 0;
	display: inline-block;
	align-self: flex-start;
	width: auto;
	max-width: 100%;
	text-decoration: none;
}

.tb-news-query .wp-block-read-more:hover {
	color: var(--wp--preset--color--accent, #B83A2E);
}

/* Breadcrumb: monospace uppercase strip above the page title on news
 * archive and single posts. Links in accent red, separators muted,
 * current page in primary ink. Border-bottom ties it to the hero
 * block underneath without an extra divider block in markup. */
.tb-breadcrumb {
	font-family: var(--wp--preset--font-family--jetbrains-mono, ui-monospace, monospace);
	font-size: 0.75rem;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wp--preset--color--ink-soft, #4a4642);
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.4em;
	line-height: 1.2;
}

.tb-breadcrumb a {
	color: var(--wp--preset--color--accent, #B83A2E);
	text-decoration: none;
}

.tb-breadcrumb a:hover {
	text-decoration: underline;
	text-decoration-thickness: 2px;
	text-underline-offset: 4px;
}

.tb-breadcrumb .tb-breadcrumb-sep {
	color: var(--wp--preset--color--ink-soft, #4a4642);
	opacity: 0.6;
}

.tb-breadcrumb .tb-breadcrumb-current {
	color: var(--wp--preset--color--ink, #0D1416);
	/* Truncation happens in PHP (first 3 words + …) so the current
	 * page label can wrap onto a second line on narrow viewports
	 * without being clipped mid-word. */
	max-width: none;
	white-space: normal;
}

/* Auto-increment the "— 00" counter per post. tb-news-num content is
 * overwritten by CSS via ::before so the markup can stay a static
 * placeholder; only the visible counter advances 01..04 (or whatever
 * the loop yields). */
.tb-news-query {
	counter-reset: tb-news;
}

.tb-news-num {
	display: var(--tb-news-num-display, inline-block);
}

.tb-news-num::before {
	counter-increment: tb-news;
	content: "— " counter(tb-news, decimal-leading-zero);
}

/* Stack to one column on phones. Two columns hold from desktop down
 * to ~600px so card excerpts stay readable. */
@media (max-width: 600px) {
	.tb-news-query .wp-block-post-template {
		grid-template-columns: minmax(0, 1fr) !important;
	}
}

/* Contact form (CF7, /kontaktai/): Bootstrap-style controls. Labels
 * sit above full-width boxed inputs with a focus ring; the submit is
 * a solid primary button. Ring/button use the site accent instead of
 * Bootstrap blue — the rest follows Bootstrap v5 metrics
 * (.375rem/.75rem padding, .375rem radius, .25rem focus ring). */
.wpcf7-form p {
	margin: 0 0 1rem;
}

/* Bootstrap forms live in a grid column, not the full row — cap the
 * form so wide (post-1240px) page content doesn't stretch the
 * controls edge to edge. */
.wpcf7-form {
	max-width: 40rem;
}

.wpcf7-form label {
	display: block;
	margin-bottom: 0.5rem;
}

.wpcf7-form .wpcf7-form-control {
	box-sizing: border-box;
	display: block;
	width: 100%;
	padding: 0.375rem 0.75rem;
	font-size: 1rem;
	font-weight: 400;
	line-height: 1.5;
	color: var(--wp--preset--color--ink);
	background-color: #fff;
	background-clip: padding-box;
	border: 1px solid #ced4da;
	border-radius: 0.375rem;
	transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.wpcf7-form .wpcf7-form-control:focus {
	border-color: var(--wp--preset--color--accent);
	box-shadow: 0 0 0 0.25rem rgba(184, 58, 46, 0.25);
	outline: 0;
}

.wpcf7-form textarea.wpcf7-form-control {
	min-height: 8rem;
	resize: vertical;
}

.wpcf7-form .wpcf7-submit {
	display: inline-block;
	width: auto;
	padding: 0.375rem 0.75rem;
	font-size: 1rem;
	line-height: 1.5;
	color: #fff;
	background-color: var(--wp--preset--color--accent);
	border: 1px solid var(--wp--preset--color--accent);
	border-radius: 0.375rem;
	cursor: pointer;
	transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out;
}

.wpcf7-form .wpcf7-submit:hover,
.wpcf7-form .wpcf7-submit:focus {
	color: #fff;
	background-color: var(--wp--preset--color--ink);
	border-color: var(--wp--preset--color--ink);
}

/* Skip-to-content link is provided by WordPress core
 * (wp_body_open → the_skip_link): visually hidden, localized, and
 * pointing at the existing #wp--skip-link--target anchor. */

/* Contact modal (HTML5 <dialog>, rendered by inc/modal.php from
 * wp_footer, triggered by [data-aufo-modal-open]). Native dialog:
 * - hidden by default (no `open` attr)
 * - ::backdrop pseudo for the dim layer
 * - ESC handled natively by .close()
 * - graceful no-JS fallback: trigger href="/kontaktai/"
 */
.aufo-modal {
	border: 2px solid #0D1416;
	padding: 0;
	background: var(--wp--preset--color--paper, #EDE7D8);
	color: var(--wp--preset--color--ink, #0D1416);
	max-width: 720px;
	width: calc(100% - 2rem);
	font-family: var(--wp--preset--font-family--inter, sans-serif);
}

.aufo-modal::backdrop {
	background: rgba(13, 20, 22, 0.7);
}

.aufo-modal__inner {
	padding: var(--wp--preset--spacing--50, 2rem) var(--wp--preset--spacing--50, 2rem) var(--wp--preset--spacing--40, 1.5rem);
}

.aufo-modal__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 1rem;
	margin-bottom: var(--wp--preset--spacing--40, 1.5rem);
	border-bottom: 1px solid #0D1416;
	padding-bottom: var(--wp--preset--spacing--30, 1rem);
}

/* Kicker stacks above the title; the close button stays top-right
 * as the second flex child. */
.aufo-modal__headtext {
	flex: 1;
	min-width: 0;
}

.aufo-modal__head h2,
.aufo-modal__title {
	margin: 0;
	font-family: var(--wp--preset--font-family--fraunces, serif);
	font-size: 1.5rem;
	font-weight: 700;
	line-height: 1.15;
	letter-spacing: -0.01em;
	color: inherit;
}

.aufo-modal__kicker {
	margin: 0 0 var(--wp--preset--spacing--30, 1rem);
	font-family: var(--wp--preset--font-family--jetbrains-mono, monospace);
	font-size: 0.7rem;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--wp--preset--color--accent, #B83A2E);
}

.aufo-modal__close {
	background: transparent;
	border: 0;
	font-size: 1.75rem;
	line-height: 1;
	cursor: pointer;
	padding: 0.25rem 0.5rem;
	color: inherit;
	font-family: inherit;
}

.aufo-modal__close:hover,
.aufo-modal__close:focus {
	background: rgba(13, 20, 22, 0.08);
}

.aufo-modal .wpcf7-form {
	max-width: none;
}

/* CF7 honeypot/validation status messages: keep them readable inside
 * the modal (no extra max-width from .wpcf7-form selector above). */
.aufo-modal .wpcf7-form .wpcf7-not-valid-tip {
	font-size: 0.8125rem;
}

/* ---------------------------------------------------------------
 * Check lists (service pages): bordeaux ✓ bullets.
 * Applied via the tb-checklist className on wp:list blocks.
 * --------------------------------------------------------------- */
.tb-checklist {
	list-style: none;
	margin-left: 0;
	padding-left: 0;
}

.tb-checklist > li {
	position: relative;
	padding-left: 1.6em;
}

.tb-checklist > li::before {
	content: "✓";
	position: absolute;
	left: 0;
	top: 0;
	color: var(--wp--preset--color--accent, #B83A2E);
	font-weight: 700;
}

/* ---------------------------------------------------------------
 * Services list widget (/paslaugos/)
 * Native wp:list with thumbnail figure + text group per <li>.
 * --------------------------------------------------------------- */
.aufo-svc-list {
	list-style: none;
	margin-left: 0;
	padding-left: 0;
}

.aufo-svc-list > li {
	display: grid;
	grid-template-columns: minmax(180px, 260px) 1fr;
	gap: var(--wp--preset--spacing--40, 1.5rem) var(--wp--preset--spacing--50, 2rem);
	align-items: start;
	padding: clamp(1.5rem, 3vw, 2.5rem) 0;
	border-top: 4px double var(--wp--preset--color--ink, #0D1416);
}

.aufo-svc-list > li:first-child {
	border-top: 0;
}

.aufo-svc-list .wp-block-image {
	margin: 0;
}

.aufo-svc-list .aufo-svc-item {
	display: flex;
	flex-direction: column;
}

.aufo-svc-list .aufo-svc-item h3 {
	margin: 0 0 0.5rem;
}

.aufo-svc-list .aufo-svc-item h3 a {
	color: inherit;
	text-decoration: none;
}

.aufo-svc-list .aufo-svc-item h3 a:hover,
.aufo-svc-list .aufo-svc-item h3 a:focus {
	color: var(--wp--preset--color--accent, #B83A2E);
	text-decoration: underline;
	text-decoration-thickness: 2px;
	text-underline-offset: 3px;
}

.aufo-svc-list .aufo-svc-more a {
	color: inherit;
	text-decoration: none;
	border-bottom: 2px solid var(--wp--preset--color--accent, #B83A2E);
	padding-bottom: 2px;
}

.aufo-svc-list .aufo-svc-more a:hover,
.aufo-svc-list .aufo-svc-more a:focus {
	background: var(--wp--preset--color--accent, #B83A2E);
	color: var(--wp--preset--color--paper, #EDE7D8);
}

@media (max-width: 600px) {
	.aufo-svc-list > li {
		grid-template-columns: 1fr;
	}
}

/* ---------------------------------------------------------------
 * Service page hero (child pages of /paslaugos/)
 * --------------------------------------------------------------- */
.aufo-svc-hero {
	border-bottom: 2px solid var(--wp--preset--color--ink, #0D1416);
	padding: var(--wp--preset--spacing--50, 2rem) 0 var(--wp--preset--spacing--70, 4rem);
}

.aufo-svc-kicker {
	font-family: var(--wp--preset--font-family--jetbrains-mono, monospace);
	font-size: 0.75rem;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--wp--preset--color--accent, #B83A2E);
}

/* ---------------------------------------------------------------
 * LQIP: tiny blurred JPEG previews as figure background-image.
 * Images keep loading normally; the preview hides the flash of
 * empty background on slow connections. Editor-safe: style.css is
 * also registered as an editor style.
 * --------------------------------------------------------------- */
.aufo-lqip {
	background-repeat: no-repeat;
	background-position: center;
	background-size: cover;
}

.aufo-lqip-hero {
	background-image: url("data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAA4KCw0LCQ4NDA0QDw4RFiQXFhQUFiwgIRokNC43NjMuMjI6QVNGOj1OPjIySGJJTlZYXV5dOEVmbWVabFNbXVn/2wBDAQ8QEBYTFioXFypZOzI7WVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVlZWVn/wAARCAASACADASIAAhEBAxEB/8QAGQAAAwEBAQAAAAAAAAAAAAAAAAMEAgUG/8QAHBAAAgIDAQEAAAAAAAAA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QACEQMRAD8A0LdHdmLMQuTgYzVqKBNpB5IPXGKS24Q/U01rjy5nXbnnPX2pKyVxu70CYAPwOMUUjv5h3YxRUPcpH//Z");
}

/* ---------------------------------------------------------------
 * Yoast breadcrumbs
 * --------------------------------------------------------------- */
.yoast-breadcrumbs {
	font-family: var(--wp--preset--font-family--jetbrains-mono, monospace);
	font-size: 0.7rem;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wp--preset--color--ink-mute, #6E6A5E);
	margin-bottom: var(--wp--preset--spacing--50, 2rem);
}

.yoast-breadcrumbs a {
	color: inherit;
	text-decoration: none;
}

.yoast-breadcrumbs a:hover,
.yoast-breadcrumbs a:focus {
	color: var(--wp--preset--color--accent, #B83A2E);
	text-decoration: underline;
	text-decoration-thickness: 2px;
	text-underline-offset: 3px;
}

/* ---------------------------------------------------------------
 * Anchor correction: headings targeted by in-page links (#turinys)
 * must land below the sticky admin bar (32px) when logged in.
 * --------------------------------------------------------------- */
.wp-block-heading[id],
.aufo-anchor {
	scroll-margin-top: 3.5rem;
}

@media (prefers-reduced-motion: no-preference) {
	html {
		scroll-behavior: smooth;
	}
}

/* ---------------------------------------------------------------
 * CookieYes banner: brand link colours. The plugin ships default
 * blue (#1863DC) links inside notice/preference copy; accent on
 * paper passes AA (≈5.9:1) and keeps the banner in the palette.
 * --------------------------------------------------------------- */
.cky-notice-des a,
.cky-preference-content-wrapper a,
.cky-accordion-header-des a,
.cky-gpc-wrapper .cky-gpc-desc a {
	color: var(--wp--preset--color--accent, #B83A2E) !important;
	text-decoration-color: currentColor !important;
}

/* ---------------------------------------------------------------
 * Footer link lists (— Paslaugos / — Kontaktai): no bullets, no
 * indent, so item text sits flush with the column's left edge —
 * exactly like the — Rekvizitai paragraph above it.
 * Applied via the tb-footer-links className on wp:list blocks.
 * --------------------------------------------------------------- */
.tb-footer-links {
	list-style: none;
	margin-left: 0;
	padding-left: 0;
}

.tb-footer-links > li {
	margin: 0;
}

/* Header top bar (current date + "— Nuo 2003 m."): newspaper
 * furniture — hidden on phones where it only crowds the logo row.
 * Applied via the tb-topbar className on the header group. */
@media (max-width: 600px) {
	/* !important: core's .wp-block-group.is-layout-flex display:flex ties
	 * on specificity and loads late enough to win the cascade tie. */
	.tb-topbar {
		display: none !important;
	}
}

/* Front page: restore the root side gutter on phones/tablets. The
 * front-page template zeroes main's padding (the hero band bleeds
 * edge to edge there), which pushes section text to the viewport
 * edge on narrow screens — services/about/news sections carry no
 * inner gutters of their own. The alignfull hero escapes back out
 * with negative margins, keeping its band on the viewport edge. */
@media (max-width: 782px) {
	main.tb-front-main {
		padding-left: var(--wp--style--root--padding-left, 1.5rem) !important;
		padding-right: var(--wp--style--root--padding-right, 1.5rem) !important;
	}

	main.tb-front-main > .alignfull {
		margin-left: calc(-1 * var(--wp--style--root--padding-left, 1.5rem)) !important;
		margin-right: calc(-1 * var(--wp--style--root--padding-right, 1.5rem)) !important;
	}
}

/* /paslaugos/: the shared services-grid pattern renders without its
 * section header (— 01 / Mūsų paslaugos + intro) — the page keeps its
 * own lead and goes straight to the cards. The front page keeps the
 * full header. */
body.page-id-6 .tb-services .tb-services-header {
	display: none;
}

/* Mobile (<=782px): stack the footer columns vertically and halve the
 * header height. Footer grid keeps its 3 columns at every wider width
 * (Rekvizitai / Paslaugos / Kontaktai sit side by side on tablet+);
 * the header logo row drops from ~192px to ~96px by halving the
 * padding and the site-logo size. */
@media (max-width: 782px) {
	.site-footer > .alignwide {
		display: block !important;
	}

	.site-footer > .alignwide > * {
		width: 100%;
	}

	.site-footer > .alignwide > * + * {
		margin-top: 32px;
	}

	.site-header {
		padding-top: 8px !important;
		padding-bottom: 8px !important;
	}

	.site-header .wp-block-group.alignwide:not(.tb-topbar) {
		padding-top: 4px !important;
		padding-bottom: 4px !important;
	}

	/* Mobile: drop the column dividers that the desktop 2/3-column
	 * grid relies on. Once columns stack vertically, the right
	 * border of a sibling becomes a stray vertical rule sitting
	 * beside the next paragraph (see Image #56, #60). Quote-style
	 * blocks keep their accent left rule — that one is a deliberate
	 * pull-quote marker, not a column divider. */
	.tb-hero .wp-block-columns {
		gap: var(--wp--preset--spacing--40, 1.5rem) !important;
	}

	.tb-hero .wp-block-columns > .wp-block-column:first-child {
		border-right: 0 !important;
		padding-right: 0 !important;
		padding-left: 0 !important;
	}

	.tb-features > .wp-block-columns {
		border-left: 0 !important;
		border-right: 0 !important;
	}

	.tb-features > .wp-block-columns > .wp-block-column {
		border-right: 0 !important;
		padding-left: 0 !important;
		padding-right: 0 !important;
	}

	/* Drop the heavy red double rule framing about-stats on phones
	 * (Image #59): the four stat columns stack, so the box frame
	 * stops carrying the section and starts looking like a clipped
	 * border. The inner 1px column rules are already removed by the
	 * rule above (they share the same .wp-block-columns target). */
	.tb-section-ink {
		border-top: 0 !important;
		border-bottom: 0 !important;
	}

	/* Image #61/#62/#63: the navigation overlay's close (×) button
	 * defaults to the very viewport corner (absolute top:0 right:0
	 * inside the fixed inset:0 container). Pin it to the exact spot
	 * the hamburger occupies in the header: 53px down (8px header
	 * padding + logo row geometry) and 44px from the right edge
	 * (24px site-header gutter + 20px logo-row padding). */
	.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-close {
		top: 53px;
		right: 44px;
	}

	/* Slab the quote group in hero explicitly so the user can keep
	 * it; everything else gets stripped. */
	.tb-hero .wp-block-group[style*="border-left"] {
		padding-left: var(--wp--preset--spacing--30, 1rem) !important;
	}

	/* Compress the vertical rhythm of every section inside <main>.
	 * The desktop preset (--wp--preset--spacing--80 ≈ 3.5rem) makes
	 * a tall page feel like a print spread; on phones the same
	 * padding eats most of the fold between sections. Cap at
	 * ~2rem. */
	main > .wp-block-group,
	main > .wp-block-section,
	main > section {
		padding-top: var(--wp--preset--spacing--50, 2rem) !important;
		padding-bottom: var(--wp--preset--spacing--50, 2rem) !important;
	}

	/* Inner templates (page / single / archive / search): the same
	 * radical compression the front-page sections got, scoped with
	 * :not(.tb-front-main) so the approved front-page rhythm stays
	 * untouched. Breadcrumb row, title row, content wrapper, query
	 * loop and the tags/prev-next tail are all direct children of
	 * <main>, so one rule compresses every inner page at once.
	 * Full-bleed bands (.alignfull, e.g. the CTA banner) keep the
	 * 2rem padding from the generic rule above — they are colored
	 * slabs, not text blocks. */
	main:not(.tb-front-main) {
		margin-top: var(--wp--preset--spacing--20, 0.5rem) !important;
	}

	main:not(.tb-front-main) > .wp-block-group:not(.alignfull),
	main:not(.tb-front-main) > .wp-block-post-content,
	main:not(.tb-front-main) > .wp-block-query {
		padding-top: var(--wp--preset--spacing--30, 1rem) !important;
		padding-bottom: var(--wp--preset--spacing--30, 1rem) !important;
		margin-top: 0 !important;
		margin-bottom: 0 !important;
	}

	/* Seeded page content carries desktop-scale paddings on its
	 * top-level sections (tb-news / tb-services ship 6rem, the
	 * service hero 4rem bottom) and the Yoast breadcrumb row keeps
	 * a 2rem bottom margin — on a phone both read as dead air
	 * between the title and the first real content. */
	.entry-content > section,
	.entry-content > .wp-block-group {
		padding-top: var(--wp--preset--spacing--40, 1.5rem) !important;
		padding-bottom: var(--wp--preset--spacing--40, 1.5rem) !important;
		margin-top: 0 !important;
		margin-bottom: 0 !important;
	}

	.entry-content .yoast-breadcrumbs {
		margin-bottom: var(--wp--preset--spacing--20, 0.5rem) !important;
	}

	/* Single post: pull the date row up under the display title and
	 * tighten the prev/next row the same way (both are small-type
	 * flex rows nested one level inside a direct-child group). */
	main > .wp-block-group > .wp-block-group.has-small-font-size {
		margin-top: var(--wp--preset--spacing--30, 1rem) !important;
	}

	/* Archive teasers: 2rem padding + 2rem margin between stacked
	 * cards doubles the gap on a phone. */
	main .wp-block-post-template > article {
		padding-bottom: var(--wp--preset--spacing--30, 1rem) !important;
		margin-bottom: var(--wp--preset--spacing--30, 1rem) !important;
	}

	/* Image #71: the close (×) now sits at the hamburger's spot
	 * (53px down, 44px from the right), so the menu items follow
	 * the same inset: the × anchors 44px off the inner overlay
	 * wrapper's right edge, and the nav list shares that edge —
	 * 44px of list padding puts the items' right border exactly
	 * under the ×, and 84px of headroom clears the button instead
	 * of colliding with PAGRINDINIS. */
	.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container {
		padding-top: 84px;
		padding-right: 44px;
	}
}
