/* Frontend Navbar Fixes for Flatly Theme */

/* Fix admin bar positioning when logged in */
.admin-nav-bar.navbar-fixed-top {
    position: relative !important;
    margin-bottom: 0 !important;
    z-index: 1000;
}

/* Remove margin-top from main navigation */
.navbar.navbar-default {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

/* Fix body padding when admin bar is present */
body {
    padding-top: 0 !important;
}

/* Ensure header section has proper spacing */
#header {
    margin-top: 0 !important;
    padding-top: 15px !important;
    padding-bottom: 15px !important;
    background: #fff;
    border-bottom: 1px rgba(0, 0, 0, 0.1) solid;
    z-index: 99;
}

/* Fix navigation bar positioning */
.navbar-fixed-top {
    position: relative !important;
    top: auto !important;
    right: auto !important;
    left: auto !important;
    z-index: auto !important;
}

/* Ensure proper spacing between admin bar and content */
.admin-nav-bar + * {
    margin-top: 0 !important;
}

/* Mobile responsive fixes */
@media (max-width: 767px) {
    #header {
        padding: 10px 15px !important;
    }
    
    #header h3 {
        font-size: 20px !important;
        margin-bottom: 5px !important;
    }
    
    #header .col-md-4 {
        text-align: left !important;
        margin-top: 10px;
    }
}

/* Additional spacing fixes */
.container-fluid,
.container {
    padding-top: 0 !important;
}

/* Fix any potential overlapping issues */
.main-content,
.page-content,
.content-wrapper {
    margin-top: 0 !important;
    padding-top: 0 !important;
}
