/* Custom Page Template Full Width Styles */
.ych-fullwidth-template #content-fullwidth {
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

.ych-fullwidth-template #primary-fullwidth {
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

.ych-fullwidth-template .site-main-fullwidth {
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* Override default padding/margin on theme's default content wrapper in full-width mode */
.ych-fullwidth-template #content.site-content {
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
}

/* Enable overflow-x: hidden on body to prevent horizontal scrollbars on breakout full-width sections */
body.ych-fullwidth-template {
    overflow-x: hidden;
}

/* Gutenberg block alignment rules (breakout layouts) */
.alignfull {
    width: 100vw !important;
    max-width: 100vw !important;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw !important;
    margin-right: -50vw !important;
}

.alignwide {
    width: 85vw !important;
    max-width: 1400px !important;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -42.5vw !important;
    margin-right: -42.5vw !important;
}

/* Reset alignments if we are inside the custom full-width template already, where parent has no container */
.ych-fullwidth-template .alignfull,
.ych-fullwidth-template .alignwide {
    width: 100% !important;
    max-width: 100% !important;
    left: 0 !important;
    right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* Constrain boxed/non-aligned elements inside full-width page templates */
.ych-fullwidth-template .site-main-fullwidth>*:not(.alignfull):not(.alignwide):not(.ych-slider),
.ych-fullwidth-template .alignnone:not(.ych-slider) {
    max-width: 1200px;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    box-sizing: border-box !important;
    width: 100% !important;
}

/* YCH Slider: 100% edge-to-edge full width inside full-width page template */
.ych-fullwidth-template .ych-slider,
.ych-fullwidth-template .site-main-fullwidth>.ych-slider {
    width: var(--ych-slider-width, 100%) !important;
    max-width: var(--ych-slider-max-width, 100%) !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: auto !important;
    margin-right: auto !important;
}