/* CSS voor header.php - Navigatie */
/* WordPress compatible header styles with high specificity */

/* WordPress admin bar adjustment */
body.admin-bar header.runhaar-header,
body.admin-bar .runhaar-header {
    top: 32px !important;
}

@media screen and (max-width: 782px) {
    body.admin-bar header.runhaar-header,
    body.admin-bar .runhaar-header {
        top: 46px !important;
    }
}

/* Header styling met extra hoge specificiteit voor WordPress */
.wp-site-blocks header.runhaar-header,
body.wp-embed-responsive header.runhaar-header,
body header.runhaar-header,
header.runhaar-header,
.runhaar-header {
    width: 100vw !important;
    height: 80px !important;
    min-height: 80px !important;
    max-height: 80px !important;
    display: flex !important;
    flex-direction: column !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    z-index: 999998 !important;
    background-color: white !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1) !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    outline: none !important;
}

.wp-site-blocks .runhaar-header-container,
body.wp-embed-responsive .runhaar-header-container,
body .runhaar-header-container,
.runhaar-header-container {
    width: 100vw !important;
    height: 80px !important;
    min-height: 80px !important;
    max-height: 80px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    outline: none !important;
}

.wp-site-blocks .runhaar-header-content,
body.wp-embed-responsive .runhaar-header-content,
body .runhaar-header-content,
.runhaar-header-content {
    max-width: 91.666667% !important;
    width: 91.666667% !important;
    height: 80px !important;
    min-height: 80px !important;
    max-height: 80px !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    outline: none !important;
}

body .runhaar-logo-container,
.runhaar-logo-container {
    display: flex !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
}

body .runhaar-logo-container img,
.runhaar-logo-container img {
    width: 150px !important;
    height: 50px !important;
    max-height: 50px !important;
    object-fit: contain !important;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Navigation styling with WordPress compatibility */
.wp-site-blocks .runhaar-navigation,
body.wp-embed-responsive .runhaar-navigation,
body .runhaar-navigation,
.runhaar-navigation,
nav.runhaar-navigation {
    display: flex !important;
    gap: 30px !important;
    align-items: center !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
    border: none !important;
    outline: none !important;
}

/* Navigation links with MAXIMUM WordPress theme override */
html body header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link,
html body .runhaar-header nav.runhaar-navigation a.runhaar-nav-link,
html .runhaar-header nav.runhaar-navigation a.runhaar-nav-link,
.runhaar-header nav.runhaar-navigation a.runhaar-nav-link,
.wp-site-blocks .runhaar-nav-link,
body.wp-embed-responsive .runhaar-nav-link,
body .runhaar-nav-link,
.runhaar-nav-link,
nav.runhaar-navigation .runhaar-nav-link,
nav.runhaar-navigation a.runhaar-nav-link,
header nav a.runhaar-nav-link {
    color: #2a2a4e !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    transition: color 0.2s ease !important;
    margin: 0 !important;
    padding: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    height: 80px !important;
    font-family: system-ui, -apple-system, sans-serif !important;
    font-size: 1rem !important;
    border: none !important;
    outline: none !important;
    background: none !important;
    box-shadow: none !important;
    text-transform: none !important;
    letter-spacing: normal !important;
    line-height: 1.5 !important;
}

/* Hover and active states with MAXIMUM WordPress compatibility */
html body header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link:hover,
html body .runhaar-header nav.runhaar-navigation a.runhaar-nav-link:hover,
html .runhaar-header nav.runhaar-navigation a.runhaar-nav-link:hover,
.runhaar-header nav.runhaar-navigation a.runhaar-nav-link:hover,
html body header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link.active,
html body .runhaar-header nav.runhaar-navigation a.runhaar-nav-link.active,
html .runhaar-header nav.runhaar-navigation a.runhaar-nav-link.active,
.runhaar-header nav.runhaar-navigation a.runhaar-nav-link.active,
.wp-site-blocks .runhaar-nav-link:hover,
body.wp-embed-responsive .runhaar-nav-link:hover,
body .runhaar-nav-link:hover,
.runhaar-nav-link:hover,
nav.runhaar-navigation .runhaar-nav-link:hover,
nav.runhaar-navigation a.runhaar-nav-link:hover,
header nav a.runhaar-nav-link:hover,
.wp-site-blocks .runhaar-nav-link.active,
body.wp-embed-responsive .runhaar-nav-link.active,
body .runhaar-nav-link.active,
.runhaar-nav-link.active,
nav.runhaar-navigation .runhaar-nav-link.active,
nav.runhaar-navigation a.runhaar-nav-link.active,
header nav a.runhaar-nav-link.active {
    color: #F15A24 !important;
    background: none !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    text-decoration: none !important;
}

/* Contact button with WordPress theme override */
.wp-site-blocks .runhaar-contact-button,
body.wp-embed-responsive .runhaar-contact-button,
body .runhaar-contact-button,
.runhaar-contact-button,
a.runhaar-contact-button {
    background-color: #F15A24 !important;
    color: white !important;
    padding: 12px 24px !important;
    border-radius: 6px !important;
    text-decoration: none !important;
    font-weight: 600 !important;
    transition: all 0.2s ease !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: none !important;
    margin: 0 !important;
    font-family: system-ui, -apple-system, sans-serif !important;
    font-size: 16px !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
    min-height: 44px !important;
    height: 44px !important;
    box-sizing: border-box !important;
    outline: none !important;
    box-shadow: none !important;
}

.wp-site-blocks .runhaar-contact-button:hover,
body.wp-embed-responsive .runhaar-contact-button:hover,
body .runhaar-contact-button:hover,
.runhaar-contact-button:hover,
a.runhaar-contact-button:hover {
    background-color: #d4491e !important;
    color: white !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
}

/* Contact container styling */
.contact-container {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
}

/* Hide mobile contact on desktop */
.contact-container.mobile-contact {
    display: none !important;
}

/* Show desktop contact on desktop */
.contact-container.desktop-contact {
    display: flex !important;
}

/* WordPress theme and block editor compatibility */
.wp-block-navigation,
.wp-block-navigation ul,
.wp-block-navigation li,
.wp-block-navigation a {
    all: unset !important;
}

/* Override common WordPress theme conflicts */
.runhaar-header * {
    box-sizing: border-box !important;
}

/* Remove body margin - hero section should be directly under header */
body {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Add margin only to main content sections, not hero */
.about-section,
.services-section,
.projects-section,
main,
.content,
.wp-block-post-content {
    margin-top: 80px !important;
}

/* WordPress admin bar adjustments for content, not body */
body.admin-bar .about-section,
body.admin-bar .services-section,
body.admin-bar .projects-section,
body.admin-bar main,
body.admin-bar .content,
body.admin-bar .wp-block-post-content {
    margin-top: 112px !important;
}

@media screen and (max-width: 782px) {
    body.admin-bar .about-section,
    body.admin-bar .services-section,
    body.admin-bar .projects-section,
    body.admin-bar main,
    body.admin-bar .content,
    body.admin-bar .wp-block-post-content {
        margin-top: 126px !important;
    }
}

/* NUCLEAR OPTION - Maximum specificity for navigation styling */
html body.wp-admin-bar-show header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link,
html body.wp-embed-responsive header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link,
html body.home header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link,
html body.page header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link,
html body header.runhaar-header .runhaar-navigation a.runhaar-nav-link,
html body .runhaar-header .runhaar-navigation a.runhaar-nav-link,
body header.runhaar-header nav a.runhaar-nav-link,
body .runhaar-header nav a.runhaar-nav-link,
.runhaar-header a[class*="runhaar-nav"],
.runhaar-navigation a[href*="ons-verhaal"],
.runhaar-navigation a[href*="ons-werk"], 
.runhaar-navigation a[href*="wat-doen-wij"],
.runhaar-navigation a[href*="onze-partners"],
.runhaar-navigation a[href*="restauratie"],
.runhaar-navigation a[href*="veelgestelde-vragen"] {
    color: #2a2a4e !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    font-family: system-ui, -apple-system, sans-serif !important;
    font-size: 1rem !important;
    background-color: transparent !important;
    background-image: none !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    text-shadow: none !important;
    text-transform: none !important;
    letter-spacing: normal !important;
    word-spacing: normal !important;
    line-height: 1.5 !important;
    vertical-align: baseline !important;
    cursor: pointer !important;
}

html body.wp-admin-bar-show header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link:hover,
html body.wp-embed-responsive header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link:hover,
html body.home header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link:hover,
html body.page header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link:hover,
html body header.runhaar-header .runhaar-navigation a.runhaar-nav-link:hover,
html body .runhaar-header .runhaar-navigation a.runhaar-nav-link:hover,
body header.runhaar-header nav a.runhaar-nav-link:hover,
body .runhaar-header nav a.runhaar-nav-link:hover,
.runhaar-header a[class*="runhaar-nav"]:hover,
.runhaar-navigation a[href*="ons-verhaal"]:hover,
.runhaar-navigation a[href*="ons-werk"]:hover,
.runhaar-navigation a[href*="wat-doen-wij"]:hover,
.runhaar-navigation a[href*="onze-partners"]:hover,
.runhaar-navigation a[href*="restauratie"]:hover,
.runhaar-navigation a[href*="veelgestelde-vragen"]:hover,
html body.wp-admin-bar-show header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link.active,
html body.wp-embed-responsive header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link.active,
html body.home header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link.active,
html body.page header.runhaar-header nav.runhaar-navigation a.runhaar-nav-link.active,
html body header.runhaar-header .runhaar-navigation a.runhaar-nav-link.active,
html body .runhaar-header .runhaar-navigation a.runhaar-nav-link.active,
body header.runhaar-header nav a.runhaar-nav-link.active,
body .runhaar-header nav a.runhaar-nav-link.active,
.runhaar-header a[class*="runhaar-nav"].active,
.runhaar-navigation a[href*="ons-verhaal"].active,
.runhaar-navigation a[href*="ons-werk"].active,
.runhaar-navigation a[href*="wat-doen-wij"].active,
.runhaar-navigation a[href*="onze-partners"].active,
.runhaar-navigation a[href*="restauratie"].active,
.runhaar-navigation a[href*="veelgestelde-vragen"].active {
    color: #F15A24 !important;
    text-decoration: none !important;
    background-color: transparent !important;
    background-image: none !important;
    border: none !important;
    box-shadow: none !important;
    text-shadow: none !important;
}

/* Inline style override using CSS custom properties */
.runhaar-nav-link {
    --nav-color: #2a2a4e;
    --nav-hover-color: #F15A24;
}

/* Ensure hero section starts at top */
.hero-section {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Last resort - style attribute override simulation */
.runhaar-navigation a {
    color: #2a2a4e !important;
}

.runhaar-navigation a:hover,
.runhaar-navigation a.active {
    color: #F15A24 !important;
}

/* ========== MOBILE RESPONSIVE STYLES ========== */

/* Mobile menu button (hamburger) - Hidden by default */
.mobile-menu-toggle {
    display: none !important;
    background: none !important;
    border: none !important;
    font-size: 1.5rem !important;
    color: #2a2a4e !important;
    cursor: pointer !important;
    padding: 0.5rem !important;
    z-index: 1000001 !important;
}

/* Mobile breakpoint */
@media (max-width: 968px) {
    /* Show hamburger button on mobile */
    .mobile-menu-toggle {
        display: block !important;
    }
    
    /* Hide desktop navigation on mobile */
    .runhaar-navigation {
        position: fixed !important;
        top: 80px !important;
        left: -100% !important;
        width: 100vw !important;
        height: calc(100vh - 80px) !important;
        background-color: white !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: flex-start !important;
        padding: 2rem 1rem !important;
        gap: 1.5rem !important;
        transition: left 0.3s ease !important;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1) !important;
        overflow-y: auto !important;
    }
    
    /* Show navigation when menu is open */
    .runhaar-navigation.mobile-menu-open {
        left: 0 !important;
    }
    
    /* Mobile navigation links styling */
    .runhaar-navigation a.runhaar-nav-link {
        font-size: 1.2rem !important;
        padding: 1rem 2rem !important;
        text-align: center !important;
        width: 100% !important;
        max-width: 300px !important;
        border-bottom: 1px solid #f3f4f6 !important;
    }
    
    /* Hide desktop contact on mobile */
    .contact-container.desktop-contact {
        display: none !important;
    }
    
    /* Show mobile contact inside navigation */
    .contact-container.mobile-contact {
        display: inline-flex !important;
        margin-top: 1rem !important;
        width: auto !important;
        max-width: 300px !important;
    }
    
    /* Adjust header content for mobile */
    .runhaar-header-content {
        justify-content: space-between !important;
        padding: 0 1rem !important;
    }
    
    /* Smaller logo on mobile */
    .runhaar-logo-container img {
        width: 120px !important;
        height: 40px !important;
    }
}

/* Smaller mobile breakpoint */
@media (max-width: 480px) {
    .runhaar-header-content {
        padding: 0 0.5rem !important;
    }
    
    .runhaar-logo-container img {
        width: 100px !important;
        height: 35px !important;
    }
    
    .runhaar-navigation a.runhaar-nav-link {
        font-size: 1.1rem !important;
        padding: 0.8rem 1.5rem !important;
    }
}

/* Body scroll lock when menu is open */
body.mobile-menu-open {
    overflow: hidden !important;
}

/* ========== DROPDOWN MENU STYLES ========== */

/* Dropdown container - volledige header hoogte */
.dropdown-container {
    position: relative !important;
    display: inline-flex !important;
    align-items: center !important;
    height: 80px !important;
}

/* Dropdown trigger styling - volledige hoogte */
.dropdown-trigger {
    display: inline-flex !important;
    align-items: center !important;
    gap: 0.5rem !important;
    cursor: pointer !important;
    height: 80px !important;
    padding: 0 !important;
}

/* Dropdown arrow styling */
.dropdown-arrow {
    font-size: 0.75rem !important;
    transition: transform 0.3s ease !important;
    color: inherit !important;
}

/* Rotate arrow when dropdown is open */
.dropdown-container:hover .dropdown-arrow {
    transform: rotate(180deg) !important;
}

/* Dropdown menu - volledige breedte met paarse lijn */
.dropdown-menu {
    display: block !important;
    position: fixed !important;
    top: 80px !important;
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
    transform: translateY(-10px) !important;
    background-color: white !important;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1) !important;
    border-top: 3px solid #2a2a4e !important;
    padding: 2rem 0 !important;
    margin: 0 !important;
    z-index: 1000 !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity 0.3s ease, transform 0.3s ease !important;
}

/* Show dropdown on hover with animation */
.dropdown-container:hover .dropdown-menu {
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: translateY(0) !important;
}

/* Dropdown content wrapper - begrensd binnen logo en contact knop */
.dropdown-content {
    width: 91.666667% !important;
    max-width: 91.666667% !important;
    margin: 0 auto !important;
    display: flex !important;
    gap: 2rem !important;
    justify-content: flex-start !important;
    align-items: center !important;
    flex-wrap: wrap !important;
}

/* Dropdown items */
.dropdown-menu .dropdown-item {
    display: inline-block !important;
    padding: 0.75rem 1.5rem !important;
    color: #2a2a4e !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    font-family: system-ui, -apple-system, sans-serif !important;
    font-size: 1rem !important;
    transition: all 0.2s ease !important;
    white-space: nowrap !important;
}

/* Dropdown divider */
.dropdown-divider {
    width: 100% !important;
    height: 1px !important;
    background-color: #e5e7eb !important;
    margin: 0.5rem 0 !important;
}

/* Dropdown subtitle */
.dropdown-subtitle {
    width: 100% !important;
    padding: 0.5rem 1.5rem !important;
    color: #6b7280 !important;
    font-size: 0.875rem !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    font-family: system-ui, -apple-system, sans-serif !important;
}

/* Dropdown item hover */
.dropdown-menu .dropdown-item:hover {
    color: #F15A24 !important;
    background-color: transparent !important;
}

/* Active dropdown trigger */
.dropdown-trigger.active {
    color: #F15A24 !important;
}

/* Mobile dropdown styles */
@media (max-width: 968px) {
    .dropdown-container {
        width: 100% !important;
        max-width: 300px !important;
    }
    
    .dropdown-trigger {
        font-size: 1.2rem !important;
        padding: 1rem 2rem !important;
        text-align: center !important;
        width: 100% !important;
        border-bottom: 1px solid #f3f4f6 !important;
    }
    
    /* Mobile dropdown menu - positioned differently */
    .dropdown-menu {
        position: static !important;
        transform: none !important;
        box-shadow: none !important;
        border-radius: 0 !important;
        margin-top: 0 !important;
        padding: 0 !important;
        background-color: #f9fafb !important;
        width: 100% !important;
    }
    
    /* Always show dropdown on mobile (no hover needed) */
    .dropdown-container:hover .dropdown-menu,
    .dropdown-container .dropdown-menu {
        display: block !important;
    }
    
    .dropdown-menu .dropdown-item {
        padding: 0.75rem 2.5rem !important;
        font-size: 1rem !important;
        border-bottom: 1px solid #e5e7eb !important;
    }
    
    .dropdown-divider {
        margin: 0.25rem 0 !important;
        background-color: #d1d5db !important;
    }
    
    .dropdown-subtitle {
        padding: 0.75rem 2.5rem !important;
        font-size: 0.8rem !important;
        background-color: #f3f4f6 !important;
    }
    
    .dropdown-menu .dropdown-item:hover {
        background-color: #e5e7eb !important;
    }
}