/* Blog and Header Styling */

/* Header fixes */
.site-header,
.elementor-location-header {
    position: relative;
    z-index: 999;
    width: 100%;
}

.elementor-nav-menu--main .elementor-nav-menu {
    display: flex;
    flex-wrap: wrap;
}

/* Blog image styling */
.blog-content img,
.featured-image,
.wp-post-image,
.entry-content img {
    max-width: 100%;
    max-height: 40vh;
    height: auto;
    display: block;
    margin: 0 auto 20px;
    object-fit: cover;
}

/* Blog content styling */
.blog-content {
    margin: 20px 0;
    line-height: 1.6;
}

.blog-content p {
    margin-bottom: 1em;
}

/* Fix for Elementor sections */
.elementor-section {
    width: 100%;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .elementor-nav-menu--dropdown {
        width: 100%;
    }
}

/* Main site header fixes */
body {
    /* Prevent duplicate headers from causing scrolling issues */
    padding-top: 0 !important;
    margin-top: 0 !important;
}

/* Hide duplicate headers */
header:not(:first-of-type),
.site-header:not(:first-of-type),
.elementor-location-header:not(:first-of-type) {
    display: none !important;
}

/* Fix for Autoblogtesting334 title */
.site-title, 
h1.elementor-heading-title {
    margin: 0;
    padding: 10px 0;
}

/* Fix navigation menu duplication */
.elementor-nav-menu li a[href="/"],
.elementor-nav-menu li a[href="/my-books"],
.elementor-nav-menu li a[href="/blog"] {
    /* Show only the first instance of each link */
    display: inline-block;
}

.elementor-nav-menu li a[href="/"]:not(:first-of-type),
.elementor-nav-menu li a[href="/my-books"]:not(:first-of-type),
.elementor-nav-menu li a[href="/blog"]:not(:first-of-type) {
    display: none;
}

/* Fix for the main navigation */
.elementor-nav-menu--main {
    width: auto;
}

/* Ensure the header is properly contained */
.elementor-section-wrap {
    width: 100%;
} 