/**
 * Weddicious components (.wd-*).
 * Loaded on the front end and inside the block editor, so patterns look
 * the same while editing as they do on the live site.
 */

/* Tracked caps label (category, eyebrow) */
.wd-label {
	font-family: var(--wd-sans, 'DM Sans', sans-serif);
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--wd-bronze-deep, #7A4A30);
	margin-bottom: 0.75rem;
}

/* Standfirst under a post title */
.wd-standfirst {
	font-size: clamp(1.125rem, 2vw, 1.25rem);
	line-height: 1.6;
	color: var(--wd-body2, #4A3D35);
}

.wd-photo-credit {
	font-size: 0.875rem;
	color: var(--wd-taupe, #6B5B50);
}

/* Wordmark in text (footer, signatures) */
.wd-wordmark {
	font-family: var(--wd-script, 'Allura', cursive);
	font-weight: 400;
	line-height: 1;
	letter-spacing: 0;
	text-transform: none;
}

/* ---------------------------------------------------------------- *
 * Pull quote
 * ---------------------------------------------------------------- */
.wd-pullquote {
	border: 0;
	border-top: 1px solid var(--wd-espresso, #2B211C);
	border-bottom: 1px solid var(--wd-espresso, #2B211C);
	margin: 3rem 0;
	padding: 2.5rem 0;
	text-align: center;
}

.wd-pullquote p {
	font-family: var(--wd-display, 'Cormorant Garamond', serif);
	font-style: italic;
	font-weight: 500;
	font-size: clamp(1.625rem, 3.4vw, 2rem);
	line-height: 1.3;
	color: var(--wd-espresso, #2B211C);
	margin: 0 auto;
	max-width: 32ch;
}

.wd-pullquote cite {
	display: block;
	margin-top: 1rem;
	font-family: var(--wd-sans, 'DM Sans', sans-serif);
	font-style: normal;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--wd-bronze-deep, #7A4A30);
}

/* ---------------------------------------------------------------- *
 * Supplier credits
 * ---------------------------------------------------------------- */
.wd-credits {
	background: var(--wd-paper, #FFFDF9);
	border: 1px solid var(--wd-rule-soft, #E4DACB);
	border-radius: var(--wd-radius, 4px);
	padding: clamp(1.5rem, 4vw, 2.5rem);
	margin-top: 3rem;
}

.wd-credits h2,
.wd-credits h3 {
	font-size: clamp(1.5rem, 3vw, 1.75rem);
	margin: 0 0 1.25rem;
}

.wd-credits ul {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 0 2rem;
}

.wd-credits li {
	padding: 0.75rem 0;
	border-bottom: 1px solid var(--wd-rule, #DCD1C1);
	font-size: 0.9375rem;
	line-height: 1.5;
	margin: 0;
}

.wd-credits li strong {
	display: block;
	font-size: 0.6875rem;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--wd-taupe, #6B5B50);
	margin-bottom: 0.125rem;
}

/* ---------------------------------------------------------------- *
 * Call to action band (Submit your wedding)
 * ---------------------------------------------------------------- */
.wd-cta {
	background: var(--wd-linen, #EFE7DA);
	border-radius: var(--wd-radius, 4px);
	padding: clamp(2rem, 5vw, 3.5rem) clamp(1.5rem, 4vw, 2.5rem);
}

.wd-cta h2 {
	margin-top: 0;
}

.wd-cta .wd-cta__text {
	color: var(--wd-body2, #4A3D35);
	max-width: 52ch;
}

.wd-cta .wp-block-button__link,
.wd-cta .wp-element-button {
	background: var(--wd-bronze, #9F6241);
	color: var(--wd-paper, #FFFDF9);
}

.wd-cta .wp-block-button__link:hover,
.wd-cta .wp-element-button:hover {
	background: var(--wd-espresso, #2B211C);
	color: var(--wd-ivory, #F7F3EC);
}

/* ---------------------------------------------------------------- *
 * Typographic fallback covers
 * ---------------------------------------------------------------- */
.wd-cover {
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	width: 100%;
	height: 100%;
	min-height: 220px;
	aspect-ratio: 4 / 5;
	padding: clamp(1.25rem, 6%, 2.25rem);
	border-radius: var(--wd-radius, 4px);
	overflow: hidden;
	text-align: left;
}

.wd-cover__top {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 1rem;
}

.wd-cover__label {
	font-family: var(--wd-sans, 'DM Sans', sans-serif);
	font-size: 0.6875rem;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
}

.wd-cover__mark {
	font-family: var(--wd-display, 'Cormorant Garamond', serif);
	font-style: italic;
	font-size: 1.75rem;
	line-height: 1;
}

.wd-cover__title {
	font-family: var(--wd-display, 'Cormorant Garamond', serif);
	font-weight: 500;
	font-size: clamp(1.5rem, 3.2vw, 2.25rem);
	line-height: 1.1;
	display: -webkit-box;
	-webkit-line-clamp: 4;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.wd-cover--bronze { background: var(--wd-bronze, #9F6241); color: var(--wd-paper, #FFFDF9); }
.wd-cover--espresso { background: var(--wd-espresso, #2B211C); color: var(--wd-ivory, #F7F3EC); }
.wd-cover--espresso .wd-cover__label,
.wd-cover--espresso .wd-cover__mark { color: var(--wd-blush, #E8CFC4); }
.wd-cover--blush { background: var(--wd-blush, #E8CFC4); color: var(--wd-espresso, #2B211C); }
.wd-cover--sage { background: var(--wd-sage, #A9B39A); color: var(--wd-espresso, #2B211C); }

/* ---------------------------------------------------------------- *
 * Ad slots — reserved height prevents layout shift
 * ---------------------------------------------------------------- */
.wd-ad {
	margin: 2.5rem auto;
	text-align: center;
	clear: both;
}

.wd-ad__label {
	display: block;
	margin-bottom: 0.5rem;
	font-family: var(--wd-sans, 'DM Sans', sans-serif);
	font-size: 0.6875rem;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--wd-taupe, #6B5B50);
}

.wd-ad__unit { min-height: 250px; }
.wd-ad--leaderboard .wd-ad__unit { min-height: 90px; }
.wd-ad--sidebar .wd-ad__unit { min-height: 600px; }

@media (max-width: 689px) {
	.wd-ad--leaderboard .wd-ad__unit { min-height: 100px; }
}

/* ================================================================ *
 * Homepage (pattern: weddicious/homepage)
 * ================================================================ */
.wd-home {
	--wd-gap: clamp(1.25rem, 2.5vw, 2rem);
	max-width: 1280px;
	margin-inline: auto;
}

.wd-home > * + * {
	margin-top: clamp(4rem, 8vw, 6rem);
}

.wd-home .wp-block-post-template {
	list-style: none;
	margin: 0;
	padding: 0;
}

.wd-home .wp-block-post-featured-image {
	margin: 0 0 1rem;
}

.wd-home .wp-block-post-featured-image img,
.wd-home .wp-block-post-featured-image .wd-cover {
	border-radius: var(--wd-radius, 4px);
	object-fit: cover;
	width: 100%;
	transition: opacity 0.2s ease;
}

.wd-home .wp-block-post-featured-image a:hover img {
	opacity: 0.92;
}

.wd-home .wp-block-post-title {
	margin: 0;
}

.wd-home .wp-block-post-title a {
	color: var(--wd-espresso, #2B211C);
	text-decoration: none;
}

.wd-home .wp-block-post-title a:hover {
	color: var(--wd-bronze-deep, #7A4A30);
}

.wd-home .wp-block-post-excerpt {
	margin-top: 0.5rem;
	color: var(--wd-body2, #4A3D35);
	font-size: 0.9375rem;
	line-height: 1.6;
}

.wd-home .wp-block-post-excerpt__excerpt {
	margin: 0;
}

/* Category labels from post-terms: drop the parent "Blog" term and commas */
.wd-home .wp-block-post-terms.wd-label {
	display: flex;
	flex-wrap: wrap;
	gap: 0 0.9em;
	margin-bottom: 0.5rem;
}

.wd-home .wp-block-post-terms.wd-label a {
	color: var(--wd-bronze-deep, #7A4A30);
	text-decoration: none;
}

.wd-home .wp-block-post-terms__separator,
.wd-home .wp-block-post-terms.wd-label a[href$="/category/blog/"] {
	display: none;
}

/* Section header: title + "view all" on a rule */
.wd-section__head {
	border-bottom: 1px solid var(--wd-espresso, #2B211C);
	padding-bottom: 0.875rem;
	margin-bottom: 2rem;
	gap: 0.5rem 1.5rem;
}

.wd-section__head h2 {
	margin: 0;
}

.wd-section__more {
	margin: 0;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
}

.wd-section__more a {
	color: var(--wd-espresso, #2B211C);
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	min-height: 44px;
}

.wd-section__more a::after {
	content: "→";
	margin-left: 0.5em;
	letter-spacing: 0;
}

.wd-section__more a:hover {
	color: var(--wd-bronze-deep, #7A4A30);
}

/* Covers on the homepage: the title is already shown beside/below the card,
   so the cover shows its category label and a large monogram instead. */
.wd-home a { text-decoration: none; }

.wd-home .wd-cover__title {
	display: none;
}

.wd-home .wd-cover__top {
	flex-direction: column;
	align-items: flex-start;
	height: 100%;
}

.wd-home .wd-cover__mark {
	margin: auto;
	font-size: clamp(4.5rem, 9vw, 7.5rem);
	transform: translateY(-0.5rem);
}

/* ---- Hero ---- */
.wd-home-hero .wp-block-post-template > li {
	margin: 0;
}

.wd-hero {
	gap: clamp(1.5rem, 4vw, 3.5rem) !important;
	margin: 0;
}

.wd-hero .wp-block-post-featured-image {
	margin: 0;
}

.wd-hero .wd-cover {
	aspect-ratio: 4 / 3;
}

.wd-hero__title {
	font-size: clamp(2.25rem, 4.5vw, 3.5rem) !important;
	line-height: 1.05 !important;
	margin: 0 0 1rem !important;
}

.wd-hero .wd-standfirst {
	margin-bottom: 1.75rem;
}

.wp-block-read-more.wd-btn {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 0.875rem 1.75rem;
	background: var(--wd-espresso, #2B211C);
	color: var(--wd-ivory, #F7F3EC);
	border-radius: 2px;
	font-size: 0.8125rem;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	text-decoration: none;
	width: auto;
}

.wp-block-read-more.wd-btn:hover {
	background: var(--wd-bronze-deep, #7A4A30);
	color: var(--wd-paper, #FFFDF9);
}

/* ---- Card grids ---- */
.wd-cards .wp-block-post-template {
	display: grid;
	gap: 2.5rem var(--wd-gap);
	grid-template-columns: repeat(var(--wd-cols, 3), minmax(0, 1fr));
}

.wd-cards--4 { --wd-cols: 4; }
.wd-cards--3 { --wd-cols: 3; }

.wd-cards .wp-block-post-template > li {
	margin: 0;
}

.wd-cards .wp-block-post-title {
	font-size: clamp(1.25rem, 2vw, 1.5rem) !important;
	line-height: 1.2 !important;
}

@media (max-width: 999px) {
	.wd-cards--4 { --wd-cols: 2; }
}

@media (max-width: 689px) {
	.wd-cards--3 { --wd-cols: 1; }
	.wd-cards--4 { --wd-cols: 1; }
	.wd-cards .wp-block-post-featured-image img,
	.wd-cards .wd-cover { aspect-ratio: 4 / 3 !important; }
}

/* ---- Browse tiles ---- */
.wd-browse h2 {
	margin: 0 0 2rem;
}

.wd-tiles {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 1rem;
}

.wd-tiles li {
	margin: 0;
}

.wd-tiles a {
	box-sizing: border-box;
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 1rem;
	min-height: 112px;
	height: 100%;
	padding: 1.25rem 1.5rem;
	background: var(--wd-paper, #FFFDF9);
	border: 1px solid var(--wd-rule-soft, #E4DACB);
	border-radius: var(--wd-radius, 4px);
	font-family: var(--wd-display, 'Cormorant Garamond', serif);
	font-size: 1.5rem;
	font-weight: 500;
	line-height: 1.15;
	color: var(--wd-espresso, #2B211C);
	text-decoration: none;
	transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.wd-tiles a::after {
	content: "→";
	font-family: var(--wd-sans, 'DM Sans', sans-serif);
	font-size: 1rem;
	color: var(--wd-bronze-deep, #7A4A30);
	transition: transform 0.2s ease, color 0.2s ease;
}

.wd-tiles a:hover {
	background: var(--wd-espresso, #2B211C);
	border-color: var(--wd-espresso, #2B211C);
	color: var(--wd-ivory, #F7F3EC);
}

.wd-tiles a:hover::after {
	color: var(--wd-blush, #E8CFC4);
	transform: translateX(4px);
}

/* ---- Planning band (text-led list) ---- */
.wd-band {
	background: var(--wd-linen, #EFE7DA);
	border-radius: var(--wd-radius, 4px);
	padding: clamp(2rem, 5vw, 3.5rem) clamp(1.25rem, 4vw, 3rem);
}

.wd-list .wp-block-post-template {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0 var(--wd-gap, 2rem);
}

.wd-list .wp-block-post-template > li {
	display: grid;
	grid-template-columns: 112px minmax(0, 1fr);
	gap: 1.25rem;
	align-items: start;
	margin: 0;
	padding: 1.5rem 0;
	border-bottom: 1px solid var(--wd-rule, #DCD1C1);
}

.wd-list .wp-block-post-featured-image {
	margin: 0;
	width: 112px;
}

.wd-list .wp-block-post-featured-image img {
	aspect-ratio: 1 !important;
	height: auto !important;
}

.wd-list .wd-cover {
	aspect-ratio: 1;
	min-height: 0;
	padding: 0;
	align-items: center;
	justify-content: center;
}

.wd-list .wd-cover__label,
.wd-list .wd-cover__title {
	display: none;
}

.wd-list .wd-cover__top {
	justify-content: center;
}

.wd-list .wd-cover__mark {
	font-size: 2.75rem;
}

.wd-list .wp-block-post-title {
	font-size: clamp(1.25rem, 2vw, 1.4rem) !important;
	line-height: 1.2 !important;
}

.wd-list .wp-block-post-excerpt {
	font-size: 0.9375rem;
}

@media (max-width: 781px) {
	.wd-list .wp-block-post-template { grid-template-columns: 1fr; }
	.wd-list .wp-block-post-template > li { grid-template-columns: 84px minmax(0, 1fr); gap: 1rem; }
	.wd-list .wp-block-post-featured-image { width: 84px; }
	.wd-list .wd-cover__mark { font-size: 2rem; }
}

/* ---- About ---- */
.wd-about {
	border-top: 1px solid var(--wd-espresso, #2B211C);
	padding-top: 2.5rem;
	gap: clamp(1.5rem, 4vw, 4rem) !important;
}

.wd-about h2 {
	margin: 0;
}

.wd-about p {
	color: var(--wd-body2, #4A3D35);
}

.wd-social.wp-block-social-links {
	gap: 0.75rem;
	margin-top: 1.5rem;
}

.wd-social .wp-social-link {
	color: var(--wd-espresso, #2B211C) !important;
	background: transparent !important;
}

.wd-social .wp-social-link a {
	padding: 0.625rem;
	min-width: 44px;
	min-height: 44px;
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

.wd-social .wp-social-link:hover {
	color: var(--wd-bronze-deep, #7A4A30) !important;
}

@media (max-width: 689px) {
	.wd-tiles {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 0.625rem;
	}
	.wd-tiles a {
		min-height: 84px;
		padding: 0.875rem 1rem;
		font-size: 1.1875rem;
	}
}

/* Planning list rows when built with Blocksy query blocks */
.wd-list-item {
	gap: 1.25rem !important;
	margin: 0;
	padding: 1.25rem 0;
	border-bottom: 1px solid var(--wd-rule, #DCD1C1);
	align-items: flex-start;
}

.wd-list-item h3 {
	margin: 0 0 0.375rem;
}

/* ================================================================ *
 * Homepage built with Blocksy query blocks (blocksy/query,
 * blocksy/post-template, blocksy/dynamic-data) — markup verified on
 * the live site: .ct-query-template-grid > article.wp-block-post >
 * a.ct-dynamic-media img + h3.ct-dynamic-data a
 * ================================================================ */

/* Use the full site width (1190px) for the homepage, even when the
   page's Blocksy content width is "Narrow". */
.entry-content:has(> .wd-home) {
	--theme-block-wide-max-width: var(--theme-normal-container-max-width, 1190px);
	--wp--style--global--wide-size: var(--theme-normal-container-max-width, 1190px);
}

.wd-home .wp-block-blocksy-query .wp-block-post {
	margin: 0;
}

.wd-home .ct-dynamic-media {
	display: block;
	overflow: hidden;
	border-radius: var(--wd-radius, 4px);
}

.wd-home .ct-dynamic-media img {
	display: block;
	width: 100%;
	object-fit: cover;
	border-radius: var(--wd-radius, 4px);
	transition: opacity 0.2s ease;
}

.wd-home .ct-dynamic-media:hover img {
	opacity: 0.92;
}

/* Titles: espresso, no underline */
.wd-home .ct-dynamic-data a,
.wd-home h2 a,
.wd-home h3 a {
	color: var(--wd-espresso, #2B211C);
	text-decoration: none;
}

.wd-home .ct-dynamic-data a:hover,
.wd-home h2 a:hover,
.wd-home h3 a:hover {
	color: var(--wd-bronze-deep, #7A4A30);
}

.wd-home .ct-query-template-grid h3.ct-dynamic-data {
	margin: 1rem 0 0;
}

/* Hero: label, title and excerpt sit together */
.wd-hero .wp-block-column > * {
	margin-block: 0;
}

.wd-hero .wd-label {
	margin-bottom: 0.75rem;
}

.wd-hero .wd-hero__title,
.wd-hero h2.ct-dynamic-data {
	margin: 0 0 1.25rem !important;
}

.wd-hero div.wd-standfirst,
.wd-hero .ct-dynamic-data.wd-standfirst {
	font-size: clamp(1.0625rem, 1.6vw, 1.1875rem);
	line-height: 1.65;
	color: var(--wd-body2, #4A3D35);
	display: -webkit-box;
	-webkit-line-clamp: 4;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* Planning list rows */
.wd-list-item .ct-dynamic-media {
	aspect-ratio: 1;
}

.wd-list-item h3.ct-dynamic-data {
	margin: 0 0 0.375rem;
}

.wd-list-item div.ct-dynamic-data {
	font-size: 0.9375rem;
	line-height: 1.6;
	color: var(--wd-body2, #4A3D35);
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.wd-band .ct-query-template-grid {
	row-gap: 0 !important;
}

/* Blocksy grids: 4 → 2 → 1 columns, 3 → 1 */
@media (max-width: 999px) {
	.wd-home .ct-query-template-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
	}
}

@media (max-width: 689px) {
	.wd-home .ct-query-template-grid {
		grid-template-columns: minmax(0, 1fr) !important;
	}
}

/* ---- Blog-first homepage additions ---- */
.wd-home .wd-card-excerpt {
	margin-top: 0.5rem;
	font-size: 0.9375rem;
	line-height: 1.6;
	color: var(--wd-body2, #4A3D35);
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.wd-section__head h3 {
	margin: 0;
	font-size: clamp(1.5rem, 2.4vw, 1.75rem);
}

.wd-section__more a + a {
	margin-left: 1.5rem;
}

.wd-topics {
	gap: clamp(1.5rem, 3vw, 2.5rem) !important;
}

.wd-topics .wd-section__head {
	margin-bottom: 0.5rem;
}

.wd-list-item--compact {
	padding: 0.875rem 0;
	gap: 1rem !important;
	align-items: center;
}

.wd-list-item--compact h3.ct-dynamic-data {
	margin: 0;
}

.wd-inspiration .ct-dynamic-media {
	aspect-ratio: 1;
}

@media (max-width: 781px) {
	.wd-topics > .wp-block-column + .wp-block-column {
		margin-top: 2rem;
	}
}

.wd-cover,
.wd-cover * {
	text-decoration: none !important;
}
