/**
 * Gallery page — match Sophia Pro demo layout.
 * https://demo-sophia-pro.wpcustomthemes.com/gallery/
 */

body.sophia-gallery-pro-page .wp-block-post-title,
body.sophia-gallery-pro-page .entry-title {
	display: none !important;
}

body.sophia-gallery-pro-page {
	background-color: var(--wp--preset--color--body-background, #fdf6f2) !important;
	position: relative;
}

body.sophia-gallery-pro-page.page::before {
	background-image: var(--wp--preset--gradient--gradient-bg-color) !important;
	content: '';
	display: block;
	height: 50%;
	left: 0;
	position: absolute;
	top: 0;
	width: 100%;
	z-index: -1;
}

body.sophia-gallery-pro-page .wp-site-blocks,
body.sophia-gallery-pro-page .wp-site-blocks main {
	background: transparent !important;
}

body.sophia-gallery-pro-page .wp-block-post-content,
body.sophia-gallery-pro-page .entry-content.wp-block-post-content {
	max-width: none !important;
	padding-inline: 0 !important;
	width: 100%;
}

body.sophia-gallery-pro-page .wp-block-post-content > .alignfull,
body.sophia-gallery-pro-page .wp-block-post-content > .wp-block-section.alignfull,
body.sophia-gallery-pro-page .wp-block-post-content > .gallery-tabs-frontend.alignfull,
body.sophia-gallery-pro-page .wp-block-post-content > .wp-block-dot-pattern.alignfull,
body.sophia-gallery-pro-page .wp-block-post-content > .wp-cta-section.alignfull {
	box-sizing: border-box;
	margin-inline: calc(50% - 50vw);
	max-width: 100vw;
	padding-inline: 0 !important;
	width: 100vw;
}

body.sophia-gallery-pro-page .wp-block-post-content > .alignfull.is-layout-constrained,
body.sophia-gallery-pro-page .wp-block-post-content > .wp-block-section.alignfull.is-layout-constrained,
body.sophia-gallery-pro-page .wp-block-post-content > .gallery-tabs-frontend.alignfull.is-layout-constrained {
	max-width: 100vw !important;
}

body.sophia-gallery-pro-page .wp-block-post-content .alignwide {
	box-sizing: border-box;
	margin-inline: auto;
	max-width: var(--wp--style--global--wide-size, 1320px);
	width: 100%;
}

body.sophia-gallery-pro-page.page-template-page-gallery .wp-site-blocks main,
body.sophia-gallery-pro-page.page-template-page-no-title .wp-site-blocks main {
	margin-top: 0;
	padding-top: 0 !important;
}

body.sophia-gallery-pro-page .wp-site-blocks main {
	padding-bottom: var(--wp--custom--spacing--main-block-gap, clamp(56px, 5.5vw, 91px));
}

body.sophia-gallery-pro-page .wp-block-post-content > .wp-block-section:has(.wp-block-float-shape) + .wp-block-section,
body.sophia-gallery-pro-page .wp-block-post-content > .wp-cta-section + .wp-block-section {
	margin-top: 0;
}

body.sophia-gallery-pro-page .wp-block-post-content > .wp-cta-section.wp-block-section {
	padding-bottom: 0 !important;
	padding-top: 0 !important;
}

/* CTA parity — match landing-sophia-pro-parity.css on gallery page. */
body.sophia-gallery-pro-page .wp-cta-section.is-style-padding-0 {
	padding: 0 !important;
}

body.sophia-gallery-pro-page .wp-cta-section.has-chocolate-dim-background-color {
	background-color: var(--wp--preset--color--chocolate-dim, #bd6230) !important;
}

body.sophia-gallery-pro-page .wp-cta-section.is-style-padding-0 .wp-block-media-text {
	align-items: stretch !important;
	grid-template-columns: 30% auto !important;
}

body.sophia-gallery-pro-page .wp-cta-section.is-style-padding-0 .wp-block-media-text > .wp-block-media-text__media {
	align-self: stretch !important;
	display: block;
	height: 100% !important;
	margin: 0;
	min-height: 100%;
	overflow: hidden;
}

body.sophia-gallery-pro-page .wp-cta-section.is-style-padding-0 .wp-block-media-text > .wp-block-media-text__media img {
	display: block;
	height: 100% !important;
	min-height: 100%;
	object-fit: cover;
	vertical-align: top;
	width: 100% !important;
}

body.sophia-gallery-pro-page .wp-cta-section .wp-block-media-text__content {
	align-self: center !important;
	max-width: 860px;
	padding-bottom: 0;
	padding-left: var(--wp--custom--spacing--outer, clamp(24px, 4vw, 42px));
	padding-right: var(--wp--custom--spacing--outer, clamp(24px, 4vw, 42px));
	padding-top: 0;
}

body.sophia-gallery-pro-page .wp-cta-section.has-chocolate-dim-background-color .wp-block-button.is-style-outline .wp-block-button__link {
	background-color: transparent !important;
	border: 1px solid var(--wp--preset--color--light, #fff) !important;
	color: var(--wp--preset--color--light, #fff) !important;
}

body.sophia-gallery-pro-page .wp-cta-section.has-chocolate-dim-background-color .wp-block-button.is-style-outline .wp-block-button__link:hover,
body.sophia-gallery-pro-page .wp-cta-section.has-chocolate-dim-background-color .wp-block-button.is-style-outline .wp-block-button__link:focus {
	background-color: var(--wp--preset--color--link-color, #954e26) !important;
	border-color: var(--wp--preset--color--link-color, #954e26) !important;
	color: var(--wp--preset--color--light, #fff) !important;
}

@media screen and (min-width: 782px) {
	body.sophia-gallery-pro-page .wp-cta-section .media-on-left .wp-block-media-text__content {
		padding-right: 15%;
	}
}

@media (max-width: 781px) {
	body.sophia-gallery-pro-page .wp-cta-section .wp-block-media-text {
		grid-template-columns: 100% !important;
	}

	body.sophia-gallery-pro-page .wp-cta-section .media-on-right .wp-block-media-text__content {
		padding-top: var(--wp--preset--spacing--40, 2.5rem);
	}
}
