/*
Theme Name: chantier-bleu
Template:   generatepress
Version:    1.0
*/


/* =============================================
   NAV OVERFLOW FIX
   Prevent nav items from wrapping at any desktop viewport width.
   ============================================= */
.main-navigation .main-nav ul li a {
    white-space: nowrap !important;
    font-size: 13px !important;
    padding-left: 10px !important;
    padding-right: 10px !important;
}

/* =============================================
   MOBILE HEADER BACKGROUND (Fix B-3)
   Match desktop header #1A56DB so logo reads cleanly.
   ============================================= */
@media (max-width: 1024px) {
    nav#mobile-header,
    .mobile-header-navigation,
    #mobile-header {
        background-color: #1A56DB !important;
    }
    nav#mobile-header button.menu-toggle {
        color: #EFF6FF !important;
    }
    nav#mobile-header .site-logo.mobile-header-logo img {
        max-height: 50px;
        width: auto;
    }
}

/* =============================================
   SEARCH FORM STYLING (Fix B-5)
   Override default browser appearance on all contexts.
   ============================================= */
.search-form input[type="search"],
.search-form .search-field {
    -webkit-appearance: none !important;
    appearance: none !important;
    background-color: #FFFFFF !important;
    color: #1F2937 !important;
    border: 1px solid #E5E7EB !important;
    border-radius: 3px 0 0 3px !important;
}

body .search-form .search-submit {
    background-color: #1A56DB !important;
    color: #EFF6FF !important;
    border: none !important;
    border-radius: 0 3px 3px 0 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    min-width: 44px !important;
    min-height: 36px !important;
    padding: 6px 12px !important;
    display: inline-block !important;
    visibility: visible !important;
    overflow: visible !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    cursor: pointer !important;
}

body .search-form .search-submit:hover,
body .search-form .search-submit:focus {
    background-color: #1346c0 !important;
    color: #EFF6FF !important;
}

/* Webkit search pseudo-elements: remove default decorations */
input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-results-button,
input[type="search"]::-webkit-search-results-decoration {
    -webkit-appearance: none;
    display: none;
}

/* =============================================
   FOOTER LINKS (Fix B-4/B-5)
   GP generates #ffffff bg — override to match GP option.
   ============================================= */
.footer-widgets,
#footer-widgets {
    background-color: #0C1B33 !important;
    color: #EFF6FF !important;
}

.footer-widgets a,
#footer-widgets a,
.footer-widgets .widget a {
    color: #EFF6FF !important;
    text-decoration: none;
}

.footer-widgets a:hover,
#footer-widgets a:hover {
    color: #BFDBFE !important;
    text-decoration: underline;
}

.footer-widgets .widget-title {
    color: #93C5FD !important;
}


/* =============================================
   WP BLOCK SEARCH WIDGET STYLING
   Gutenberg block search uses different classes than classic search form.
   ============================================= */
.wp-block-search__button,
button.wp-block-search__button,
.wp-element-button.wp-block-search__button {
    background-color: #1A56DB !important;
    color: #EFF6FF !important;
    border: none !important;
    border-radius: 0 3px 3px 0 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    min-width: 44px !important;
    min-height: 36px !important;
    padding: 6px 12px !important;
    display: inline-block !important;
    visibility: visible !important;
    overflow: visible !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    cursor: pointer !important;
}

.wp-block-search__button:hover,
button.wp-block-search__button:hover {
    background-color: #1346c0 !important;
    color: #EFF6FF !important;
}

.wp-block-search__input {
    -webkit-appearance: none !important;
    appearance: none !important;
    background-color: #FFFFFF !important;
    color: #1F2937 !important;
    border: 1px solid #E5E7EB !important;
    border-radius: 3px 0 0 3px !important;
}

/* =============================================
   MOBILE SEARCH FIELD WIDTH (Fix B-5)
   ============================================= */
@media (max-width: 768px) {
    .search-form .search-field {
        width: 100%;
        max-width: calc(100% - 60px);
        box-sizing: border-box;
    }

    body .search-form .search-submit {
        background-color: #1A56DB !important;
        color: #EFF6FF !important;
        -webkit-appearance: none !important;
        appearance: none !important;
        min-width: 44px !important;
        min-height: 36px !important;
        padding: 6px 12px !important;
        display: inline-block !important;
        visibility: visible !important;
        overflow: visible !important;
        font-size: 14px !important;
        line-height: 1.4 !important;
    }

    /* Mobile footer links */
    #footer-widgets a,
    .footer-widgets a,
    .footer-widgets .widget a {
        color: #EFF6FF !important;
        text-decoration: none;
    }

    /* Mobile widget links (sidebar collapsed to below content) */
    .widget a {
        color: #1A56DB;
        text-decoration: none;
    }
}

/* =============================================
   SITE INFO BAR
   ============================================= */
.site-info {
    background-color: #0C1B33 !important;
    color: #EFF6FF !important;
}

.site-info a {
    color: #93C5FD !important;
}
