/* ewamiller-compat: layout for legacy page-builder content */

/* Builder pages get the full content width (titles/sidebars are handled per page). */
.ewc-builder .site-content .content-area { width: 100%; }
.ewc-builder.separate-containers .inside-article,
.ewc-builder.one-container .site-content { padding-left: 0; padding-right: 0; }
.ewc-builder .entry-content:not(:first-child) { margin-top: 0; }
.ewc-builder .inside-article { padding-top: 20px; }

/* WPBakery grid */
.ewc-vc-row { --ewc-gap: 30px; display: flex; flex-wrap: wrap; margin: 0 calc(var(--ewc-gap) / -2) 35px; box-sizing: border-box; }
.ewc-vc-row--inner { margin-bottom: 0; }
.ewc-vc-col { box-sizing: border-box; flex: 0 0 var(--ewc-w, 100%); max-width: var(--ewc-w, 100%); padding: 0 calc(var(--ewc-gap) / 2); min-width: 0; }
.ewc-vc-col__inner > * + * { margin-top: 0; }
.ewc-vc-eqh > .ewc-vc-col { display: flex; flex-direction: column; }
.ewc-vc-eqh > .ewc-vc-col > .ewc-vc-col__inner { flex: 1; }
.ewc-vc-fullh { min-height: 100vh; }
.ewc-vc-place-middle { align-items: center; }
.ewc-vc-place-top { align-items: flex-start; }
.ewc-vc-place-bottom { align-items: flex-end; }
.ewc-vc-stretch { width: 100vw; max-width: 100vw; margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); }
.ewc-vc-stretch > .ewc-vc-col { padding: 0; }
.ewc-vc-text { margin-bottom: 35px; }
.ewc-vc-heading { margin: 0 0 20px; }
.ewc-vc-heading a { color: inherit; }
.ewc-vc-single-image { margin: 0 0 35px; }
.ewc-vc-img-wrap { display: inline-block; max-width: 100%; overflow: hidden; vertical-align: top; }
.ewc-vc-img-wrap img { display: block; max-width: 100%; height: auto; }
.ewc-vc-img-wrap[style*="aspect-ratio"] img { width: 100%; height: 100%; object-fit: cover; }
.ewc-vc-vc_box_rounded, .ewc-vc-vc_box_rounded img { border-radius: 4px; }
.ewc-vc-vc_box_circle, .ewc-vc-vc_box_circle img { border-radius: 50%; }
.ewc-align-center { text-align: center; }
.ewc-align-right { text-align: right; }
.ewc-align-left, .ewc-align-inline { text-align: left; }
.ewc-vc-btn-wrap { margin-bottom: 35px; }
.ewc-vc-btn { display: inline-block; background: var(--ewc-bg); color: var(--ewc-fg) !important; border-radius: 5px; padding: 14px 20px; line-height: 1.2; text-decoration: none !important; transition: filter .2s; }
.ewc-vc-btn:hover { filter: brightness(0.9); }
.ewc-vc-btn--xs { font-size: 11px; padding: 8px 12px; }
.ewc-vc-btn--sm { font-size: 12px; padding: 11px 16px; }
.ewc-vc-btn--lg { font-size: 16px; padding: 18px 25px; }
.ewc-vc-sep { margin: 20px auto 35px; height: 0; }
.ewc-align_left.ewc-vc-sep { margin-left: 0; }
.ewc-vc-tsep { display: flex; align-items: center; gap: 12px; margin-bottom: 35px; }
.ewc-vc-tsep__line { flex: 1; height: 0; }
.ewc-vc-tsep h4 { margin: 0; }
.ewc-vc-icon { margin-bottom: 35px; color: #5472d2; }
.ewc-vc-zigzag { height: 14px; margin: 0 auto 35px; background: linear-gradient(135deg, transparent 75%, var(--ewc-c) 75%) 0 50%/14px 14px repeat-x, linear-gradient(45deg, transparent 75%, var(--ewc-c) 75%) 0 50%/14px 14px repeat-x; }
.ewc-spacer { flex-basis: var(--ewc-w); }
@media (max-width: 767px) {
	.ewc-vc-col, .ewc-spb-row .ewc-vc-row--inner { flex-basis: 100% !important; max-width: 100%; }
	.ewc-vc-fullh { min-height: 0; }
}

/* Revolution slider replacement */
.ewc-rs { position: relative; width: 100%; overflow: hidden; background: #111; }
.ewc-rs__slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.2s ease; }
.ewc-rs__slide.is-active { opacity: 1; }
.ewc-rs__img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ewc-rs__caption { position: absolute; left: 50px; top: 50px; color: #fff; font-family: 'Merriweather', Georgia, serif; font-size: clamp(22px, calc(var(--ewc-fs) * 0.0694vw), calc(var(--ewc-fs) * 1px)); line-height: 1.2; text-shadow: 0 2px 12px rgba(0,0,0,.35); }
@media (max-width: 767px) { .ewc-rs__caption { left: 16px; top: 14px; } }

/* Galleries */
.ewc-gal { --ewc-cols: 3; --ewc-gap: 12px; }
.ewc-gal--grid { display: grid; grid-template-columns: repeat(var(--ewc-cols), minmax(0, 1fr)); gap: var(--ewc-gap); }
.ewc-gal--grid .ewc-gal__item img, .ewc-gal--grid .ewc-gal__item video { aspect-ratio: 1; object-fit: cover; }
.ewc-gal--masonry { column-count: var(--ewc-cols); column-gap: var(--ewc-gap); }
.ewc-gal--masonry .ewc-gal__item { break-inside: avoid; margin-bottom: var(--ewc-gap); }
.ewc-gal__item { margin: 0; }
.ewc-gal__item img, .ewc-gal__item video { display: block; width: 100%; height: auto; }
.ewc-gal__item a { display: block; transition: opacity .2s; }
.ewc-gal__item a:hover { opacity: .85; }
@media (max-width: 767px) { .ewc-gal { --ewc-cols: 2 !important; } }

/* Posts grid */
.ewc-posts { display: grid; grid-template-columns: repeat(var(--ewc-cols, 3), minmax(0, 1fr)); gap: 30px; }
.ewc-posts--masonry { align-items: start; }
.ewc-post { display: flex; flex-direction: column; background: #fff; border-radius: 3px; overflow: hidden; box-shadow: 0 0 10px rgba(0,0,0,.12); }
.ewc-post__thumb { position: relative; display: block; }
.ewc-post__thumb img { display: block; width: 100%; height: auto; aspect-ratio: 4/3; object-fit: cover; }
.ewc-post__badge { position: absolute; top: 15px; left: 15px; background: #00a5b7; color: #fff; font-size: 12px; padding: 2px 10px; border-radius: 999px; }
.ewc-post__body { padding: 20px 24px; flex: 1; }
.ewc-post__title { margin: 0 0 10px; font-size: 1.15em; line-height: 1.3; }
.ewc-post__title a { text-decoration: none; }
.ewc-post__excerpt { margin: 0 0 12px; font-size: .95em; }
.ewc-post__more { display: inline-block; font-size: .85em; font-weight: 600; text-transform: uppercase; text-decoration: none; padding: 4px 0; }
.ewc-post__meta { border-top: 1px solid #eaeaea; padding: 12px 24px; font-size: 12px; color: #777; }
.ewc-pager { display: flex; justify-content: space-between; gap: 20px; margin-top: 40px; }
@media (max-width: 767px) { .ewc-posts { grid-template-columns: 1fr; } }

/* Call to action */
.ewc-cta { position: relative; display: flex; overflow: hidden; color: #fff; text-decoration: none !important; min-height: 280px; }
.ewc-cta--classic { flex-direction: column; color: inherit; }
.ewc-cta__bg { position: absolute; inset: 0; background-size: cover; background-position: center; transition: transform 1.5s; }
.ewc-cta--classic .ewc-cta__bg { position: relative; min-height: 200px; }
.ewc-cta:hover .ewc-cta__bg { transform: scale(1.05); }
.ewc-cta__overlay { position: absolute; inset: 0; pointer-events: none; }
.ewc-cta__content { position: relative; z-index: 1; width: 100%; padding: 35px; box-sizing: border-box; }
.ewc-cta--classic .ewc-cta__content { background: #f7f7f7; color: #333; }
.ewc-cta__title { font-size: 1.75em; line-height: 1.2; margin-bottom: 15px; }
.ewc-cta__button { display: inline-block; margin-top: 15px; border: 2px solid currentColor; padding: 8px 18px; }

/* Flip box (fade) */
.ewc-flip { position: relative; display: block; height: 280px; overflow: hidden; text-decoration: none !important; }
.ewc-flip__side { position: absolute; inset: 0; background-size: cover; background-position: center; display: flex; transition: opacity .6s; }
.ewc-flip__a { background-color: #1abc9c; }
.ewc-flip__b { background-color: #4054b2; color: #fff; opacity: 0; }
.ewc-flip:hover .ewc-flip__b, .ewc-flip:focus .ewc-flip__b { opacity: 1; }
.ewc-flip__inner { padding: 35px; align-self: flex-start; }
.ewc-flip__a .ewc-flip__inner { align-self: flex-end; color: #fff; }
.ewc-flip__title { font-size: 1.6em; line-height: 1.2; margin-bottom: 10px; }
.ewc-flip__button { display: inline-block; margin-top: 12px; border: 2px solid currentColor; padding: 6px 14px; }

/* Post widgets */
.ewc-share { display: flex; flex-wrap: wrap; gap: 16px; }
.ewc-share a { color: #467ff7; line-height: 0; }
.ewc-postinfo__item + .ewc-postinfo__item::before { content: "·"; margin-right: .4em; }
.ewc-postnav { display: flex; justify-content: space-between; gap: 20px; }
.ewc-postnav a { display: flex; flex-direction: column; text-decoration: none; }
.ewc-postnav a:last-child { text-align: right; }

/* Element Pack 3D text */
.ewc-3d .elementor-heading-title { text-shadow: 1px 1px 0 var(--ewc-3d), 2px 2px 0 var(--ewc-3d), 3px 3px 0 var(--ewc-3d), 4px 4px 0 var(--ewc-3d), 5px 5px 0 var(--ewc-3d), 6px 6px 8px rgba(0,0,0,.25); }

/* Lightbox */
.ewc-lbx { position: fixed; inset: 0; z-index: 99999; background: rgba(0,0,0,.9); display: flex; align-items: center; justify-content: center; }
.ewc-lbx img { max-width: 92vw; max-height: 88vh; box-shadow: 0 10px 40px rgba(0,0,0,.5); }
.ewc-lbx button { position: absolute; background: none; border: 0; color: #fff; font-size: 40px; line-height: 1; padding: 16px; cursor: pointer; }
.ewc-lbx__close { top: 8px; right: 12px; }
.ewc-lbx__prev { left: 8px; top: 50%; transform: translateY(-50%); }
.ewc-lbx__next { right: 8px; top: 50%; transform: translateY(-50%); }

/* Old theme demo shortcodes */
.ewc-mks { margin-bottom: 1.5em; }
