/* ============================================
   COLA HOME FIXES - Height, Overlay, Layout
   ============================================ */

/* FIX: Remove height constraints from .cola-home-page */
.cola-home-page,
#cola-app.cola-home-page {
    height: auto !important;
    min-height: auto !important;
    max-height: none !important;
    overflow: visible !important;
}

/* FIX: Remove height constraints from .main_body */
.cola-home-page .main_body {
    height: auto !important;
    min-height: auto !important;
    max-height: none !important;
    overflow: visible !important;
}

/* FIX: Disable overlay background */
#nb-live-bg {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    height: 0 !important;
    width: 0 !important;
    position: absolute !important;
    left: -9999px !important;
}

/* FIX: Ensure header is always visible - HIGHEST PRIORITY */
.site-header,
header#masthead,
#masthead,
header.site-header {
    display: flex !important;
    opacity: 1 !important;
    visibility: visible !important;
    position: relative !important;
    z-index: 100 !important;
}

body.cola-home-template #masthead,
body.cola-home-template .site-header,
body.cola-home-template header#masthead,
body.cola-home-template header.site-header {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    z-index: 100 !important;
}

/* Override inline styles - MUST come after base rules */
#masthead[style*="display: none"],
.site-header[style*="display: none"],
header#masthead[style*="display: none"],
body.cola-home-template #masthead[style*="display: none"],
body.cola-home-template .site-header[style*="display: none"] {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* FIX: Ensure footer is always visible - HIGHEST PRIORITY */
footer.nembien-footer,
footer.site-footer,
footer {
    display: block !important;
    position: static !important;
    order: 999999 !important; /* Highest order to ensure footer is always last */
    margin-top: auto !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100% !important;
    z-index: 10 !important;
    flex-shrink: 0 !important;
    clear: both !important;
}

body.cola-home-template > footer,
body.cola-home-template footer.nembien-footer,
body.cola-home-template footer.site-footer,
body.cola-home-template footer {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: static !important;
    order: 999999 !important; /* Highest order to ensure footer is always last */
    margin-top: auto !important;
    width: 100% !important;
    z-index: 10 !important;
    flex-shrink: 0 !important;
    clear: both !important;
}

/* Override inline styles - MUST come after base rules */
footer[style*="display: none"],
footer.nembien-footer[style*="display: none"],
body.cola-home-template footer[style*="display: none"] {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* FIX: Hide footer if incorrectly placed inside #cola-app */
body.cola-home-template #cola-app footer,
body.cola-home-template #cola-app footer.nembien-footer,
body.cola-home-template .cola-home-page footer {
    display: none !important;
}

/* FIX: Hide other footers */
.fy-footer,
.cola-footer,
.footerbar {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}
