/*
 * Tactile pass (Jake approved Dec 3 2026; canvas https://claude.ai/artifact/1PJS7BsxYDQ6hySh2JJiyz, round 2).
 * Used sparingly:
 * - a faint powder-coat grain on the colored rounded cards only (Jake, Dec 3 evening: not the page background, not buttons)
 * - a few percent of light falloff on the colored cards and bands (never the plain page sections, so no banding)
 * - touchable edges on pill buttons, rounded cards and content photos
 * - two gobos (out-of-frame shadows): meadow stems across the home Planting card, a sprig rising into the footer
 * Gobo shadows are tone-on-tone: one light warm tone, multiplied, so yellow goes deeper gold and cream deeper cream.
 * One sun: both plates (assets/gobos) lean the same way. Gobo cards carry the class has-gobo-meadow / has-gobo-sprig.
 */

/* Grain: only on the colored rounded cards (bento cards, footer cards, the Planting card and the like).
   Jake, Dec 3 evening: "Remove the texture on the page background and keep it on the cards",
   not on the buttons, "just some of the UI in a subtle way".
   It replaces a fixed full-screen speck layer that sat over everything.
   The specks are a layer above the card's own color and below its content, so text, buttons,
   fields and photos inside the card stay clean.
   Left out: photo cards (a background image and no background color), white cards, full-width bands. */
.wp-block-group.has-background[style*="border-radius:20px"]:not(.alignfull):is([style*="background-color"], [class*="-background-color"]):not([style*="background-color:#fcfcfc"], [style*="background-color:#ffffff"]) {
	position: relative;
	isolation: isolate;
}

.wp-block-group.has-background[style*="border-radius:20px"]:not(.alignfull):is([style*="background-color"], [class*="-background-color"]):not([style*="background-color:#fcfcfc"], [style*="background-color:#ffffff"])::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	border-radius: inherit;
	pointer-events: none;
	background: url("../gobos/grain-alpha.png") repeat 0 0 / 256px 256px;
}

@media print {
	.wp-block-group.has-background[style*="border-radius:20px"]::after {
		display: none;
	}
}

/* Light falloff: brighter at the upper left, a touch deeper at the bottom, in the surface's own color. */
.wp-block-group.has-primary-background-color,
.wp-block-group.has-primary-alt-background-color,
.wp-block-group.has-background[style*="background-color:#fff5d6"],
.wp-block-group.has-background[style*="background-color:#ffefbf"],
.wp-block-group.has-background[style*="background-color:#fff1c9"] {
	background-image:
		radial-gradient(120% 90% at 15% 0%, rgba(255, 255, 255, 0.32) 0%, rgba(255, 255, 255, 0) 55%),
		linear-gradient(180deg, rgba(132, 91, 38, 0) 55%, rgba(132, 91, 38, 0.06) 100%);
}

/* Footer: one surface with one falloff (audit item 7, Dec 3 2026).
   The footer part (DB template part 928) is three full-width yellow rows. Each row drew its own
   falloff, so a line showed where the rows meet. The footer paints the yellow and the falloff once,
   and the rows are see-through. The !important is needed to beat the preset class's own !important.
   The sprig row stops isolating so its multiply shadow lands on the footer's yellow; the footer
   isolates instead, so the shadow still blends with the footer only. */
footer.wp-block-template-part {
	isolation: isolate;
	background-color: var(--wp--preset--color--primary);
	background-image:
		radial-gradient(120% 90% at 15% 0%, rgba(255, 255, 255, 0.32) 0%, rgba(255, 255, 255, 0) 55%),
		linear-gradient(180deg, rgba(132, 91, 38, 0) 55%, rgba(132, 91, 38, 0.06) 100%);
}

footer.wp-block-template-part > .wp-block-group.has-primary-background-color {
	background-color: transparent !important;
	background-image: none;
}

footer.wp-block-template-part > .has-gobo-sprig {
	isolation: auto;
}

.wp-block-group.has-bark-background-color {
	background-image: radial-gradient(120% 110% at 18% 0%, rgba(255, 236, 190, 0.09) 0%, rgba(255, 236, 190, 0) 55%);
}

/* Rounded cards: a light top lip and a faint lower edge. */
.wp-block-group.has-background[style*="border-radius:20px"]:not(.alignfull) {
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), inset 0 -1px 0 rgba(132, 91, 38, 0.1);
}

.wp-block-group.has-bark-background-color[style*="border-radius:20px"] {
	box-shadow: inset 0 1px 0 rgba(255, 236, 190, 0.14), inset 0 -1px 0 rgba(0, 0, 0, 0.25);
}

/* Pill buttons and the subscribe buttons: a soft top light and a pressed lower edge.
   Not the footer's legal links (b33-legal-link): they are text links (Jake, Dec 3 evening). */
.wp-block-button:not(.is-style-outline):not(.b33-legal-link) > .wp-block-button__link,
body .gform_wrapper.gform-theme.gform-theme--orbital:is(#gform_wrapper_7, #gform_wrapper_8, #gform_wrapper_9) .gform_button {
	background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.38) 0%, rgba(255, 255, 255, 0) 55%, rgba(132, 91, 38, 0.07) 100%);
	box-shadow:
		inset 0 1px 0 rgba(255, 255, 255, 0.8),
		inset 0 -1px 0 rgba(132, 91, 38, 0.22),
		0 1px 1px rgba(72, 50, 22, 0.08),
		0 3px 8px -4px rgba(72, 50, 22, 0.28);
}

/* Content photos: sit on the page, not pasted on it. */
main .wp-block-image.has-custom-border img {
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6), 0 8px 18px -12px rgba(72, 50, 22, 0.4);
}

/* Gobos. */
.has-gobo-meadow,
.has-gobo-sprig {
	position: relative;
	isolation: isolate;
	overflow: hidden;
}

.has-gobo-meadow::before,
.has-gobo-sprig::before {
	content: "";
	position: absolute;
	inset: -4%;
	z-index: 1;
	pointer-events: none;
	background: #e2cfa4;
	mix-blend-mode: multiply;
	opacity: 0.7;
	-webkit-mask-repeat: no-repeat;
	mask-repeat: no-repeat;
}

.has-gobo-meadow::before {
	-webkit-mask-image: url("../gobos/gobo-meadow.webp");
	mask-image: url("../gobos/gobo-meadow.webp");
	-webkit-mask-size: 170%;
	mask-size: 170%;
	-webkit-mask-position: 40% 0%;
	mask-position: 40% 0%;
}

.has-gobo-sprig::before {
	-webkit-mask-image: url("../gobos/gobo-sprig.webp");
	mask-image: url("../gobos/gobo-sprig.webp");
	-webkit-mask-size: auto 135%;
	mask-size: auto 135%;
	-webkit-mask-position: 0% 100%;
	mask-position: 0% 100%;
}

/* In the footer the sprig sits on the first row, which clips it. A cut shadow at the row's lower
   edge read as a line in the gutters, so the sprig fades out over the row's last 48px instead.
   The sprig plate keeps its size and place; the box runs 4% past the row (inset -4%). */
footer.wp-block-template-part > .has-gobo-sprig::before {
	-webkit-mask-image: url("../gobos/gobo-sprig.webp"), linear-gradient(to top, transparent 3.7%, #000 calc(3.7% + 48px));
	mask-image: url("../gobos/gobo-sprig.webp"), linear-gradient(to top, transparent 3.7%, #000 calc(3.7% + 48px));
	-webkit-mask-size: auto 135%, 100% 100%;
	mask-size: auto 135%, 100% 100%;
	-webkit-mask-position: 0% 100%, 0 0;
	mask-position: 0% 100%, 0 0;
	-webkit-mask-repeat: no-repeat;
	mask-repeat: no-repeat;
	-webkit-mask-composite: source-in;
	mask-composite: intersect;
}
