/*
 * Fins & Flies Theme Fixes
 * Eliminates white gaps, fixes Elementor spacing, hides CMS editor markup
 */

/* Kill ALL Elementor container/widget spacing */
.elementor-element.e-con {
    --padding-top: 0px !important;
    --padding-right: 0px !important;
    --padding-bottom: 0px !important;
    --padding-left: 0px !important;
    --margin-top: 0px !important;
    --margin-bottom: 0px !important;
    --gap: 0px !important;
    --container-widget-gap: 0px !important;
    padding: 0 !important;
    margin: 0 !important;
    gap: 0 !important;
}
.e-con {
    --gap: 0px !important;
    --container-widget-gap: 0px !important;
}
.elementor-widget-text-editor {
    margin-bottom: 0 !important;
}
.elementor-element.e-con > .elementor-element {
    margin-bottom: 0 !important;
}
.elementor-section .elementor-container {
    gap: 0 !important;
}
.elementor-widget:not(:last-child) {
    margin-bottom: 0 !important;
}
.elementor-element .elementor-widget-wrap {
    gap: 0 !important;
}
.elementor-section,
.elementor-top-section {
    margin-bottom: 0 !important;
}
.elementor .elementor-element.e-con > .e-con {
    margin: 0 !important;
}

/* Kill main wrapper padding */
.main {
    padding-bottom: 0 !important;
}

/* Ensure Elementor page wrapper has no gaps */
.elementor-page .main,
.elementor .elementor-inner,
.elementor .elementor-section-wrap {
    gap: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Hide CMS editor utility markup completely */
.pt-ss-utilities,
.pt-ss-utilities *,
.pt-ss-utilities::before,
.pt-ss-utilities::after {
    display: none !important;
    height: 0 !important;
    max-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    line-height: 0 !important;
    font-size: 0 !important;
    border: none !important;
}
.pt-add-classes,
.pt-ss-add-anchor {
    display: none !important;
}

/* Collapse empty paragraphs and line breaks */
p:empty {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 0 !important;
    height: 0 !important;
}
p > br:only-child {
    display: none !important;
}
.elementor-text-editor > p:empty {
    margin: 0 !important;
    padding: 0 !important;
    line-height: 0 !important;
    font-size: 0 !important;
    height: 0 !important;
    display: none !important;
}
.elementor-text-editor > p > br:only-child {
    display: none !important;
}
.text-editor > p:empty {
    display: none !important;
}
.text-editor > p > br:only-child {
    display: none !important;
}

/* Responsive images - prevent overflow */
img {
    max-width: 100%;
    height: auto;
}
.text-editor img[style*="display: none"] {
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Hover-based dropdown navigation */
@media (min-width: 768px) {
    .navbar-nav > li.dropdown:hover > .dropdown-menu {
        display: block;
        margin-top: 0;
    }
}
