/* assets/css/style.css - Dress Code Stack v2.2 (Elementor Flex Fix) */

/* Reset */
.dcs-cover-wrapper,
.dcs-cover-wrapper *,
.dcs-fullscreen-overlay,
.dcs-fullscreen-overlay * {
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ═══════════════════════════════════════════════════
   ELEMENTOR COMPATIBILITY
   The main issue: Elementor e-con flex containers 
   collapse children that use aspect-ratio or don't 
   have explicit height. Our fix uses padding-bottom 
   trick + these overrides.
   ═══════════════════════════════════════════════════ */

/* Force the shortcode widget to respect child dimensions */
.elementor-widget-shortcode .elementor-shortcode {
    display: block !important;
    width: 100% !important;
}

/* The cover wrapper MUST be display:flex and take full width */
.dcs-cover-wrapper {
    display: flex !important;
    flex-direction: row !important;
    width: 100% !important;
    min-height: 1px; /* Prevent collapse */
}

/* Prevent Elementor from overriding our flex layout */
.e-con .dcs-cover-wrapper,
.e-con-inner .dcs-cover-wrapper,
.elementor-widget .dcs-cover-wrapper {
    display: flex !important;
    flex-direction: row !important;
    flex-shrink: 0 !important;
    align-self: stretch !important;
}

/* Ensure the half cards maintain their square shape */
.dcs-cover-half {
    flex: 1 1 0% !important;
    min-width: 0 !important;
}

/* ═══════════════════════════════════════════════════
   FULLSCREEN OVERLAY
   ═══════════════════════════════════════════════════ */
.dcs-fullscreen-overlay {
    isolation: isolate;
}

/* When fullscreen is open, freeze EVERYTHING behind it */
body.dcs-fs-open {
    overflow: hidden !important;
    height: 100vh !important;
    height: 100dvh !important;
    touch-action: none;
    -webkit-overflow-scrolling: auto;
}
body.dcs-fs-open > *:not(.dcs-fullscreen-overlay) {
    pointer-events: none !important;
    user-select: none !important;
}

/* Swiper inside fullscreen */
.dcs-fullscreen-overlay .dcs-fs-swiper {
    position: relative !important;
    z-index: 5 !important;
    isolation: isolate;
    touch-action: pan-y !important;
    cursor: grab;
}
.dcs-fullscreen-overlay .dcs-fs-swiper:active {
    cursor: grabbing;
}

/* ═══════════════════════════════════════════════════
   TINY SCREENS: Stack vertically
   ═══════════════════════════════════════════════════ */
@media (max-width: 340px) {
    .dcs-cover-wrapper {
        flex-direction: column !important;
        align-items: center !important;
    }
    .dcs-cover-half {
        width: 100% !important;
        max-width: 240px !important;
    }
}
