/*
Theme Name: Mike's Child Theme
Theme URI: https://olliewp.com
Description: This is Mike's custom child theme.
Author: Mike McAlister
Author URI: https://olliewp.com
Template:     ollie
Version: 1.0.0
License:      GNU General Public License v2 or later
License URI:  http://www.gnu.org/licenses/gpl-2.0.html
Tags:         blog, portfolio, entertainment, grid-layout, one-column, two-columns, three-columns, four-columns, block-patterns, block-styles, custom-logo, custom-menu, editor-style, featured-images, full-site-editing, full-width-template, rtl-language-support, style-variations, template-editing, theme-options, translation-ready, wide-blocks
Text Domain: ollie-child
*/

html {
  scroll-behavior: smooth;
}

.wp-block-navigation:not(.has-background) .wp-block-navigation__responsive-container.is-menu-open {
    background-color: var(--wp--preset--color--custom-pink);
}

.wp-block-navigation__responsive-container-close svg, .wp-block-navigation__responsive-container-open svg {
	fill: var(--wp--preset--color--custom-pink);
}

.wp-block-navigation:not(.has-background) .wp-block-navigation__responsive-container.is-menu-open {
	.wp-block-navigation__responsive-container-close svg, .wp-block-navigation__responsive-container-open svg {
		fill: var(--wp--preset--color--custom-schwarz);
	}
}

.is-scrolled {
        .wp-block-navigation__responsive-container-close svg, .wp-block-navigation__responsive-container-open svg {
                fill: var(--wp--preset--color--custom-schwarz);
        }
}

.wp-block-navigation.is-filled .wp-block-navigation__responsive-container-open svg {
	fill: var(--wp--preset--color--custom-schwarz);
}

/* 1. The Base Rule (checks if 1st or 2nd child is a cover) */
body:not(.wp-admin):has(.entry-content > .wp-block-cover:is(:first-child, :nth-child(2))) header:has(>.is-position-sticky) {
    position: fixed;
    top: calc(0px + var(--wp-admin--admin-bar--height, 0px));
    z-index: 100;
    transition: background-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

/* 2. The Override Rule (same target logic, but chaining .is-scrolled) */
body:not(.wp-admin):has(.entry-content > .wp-block-cover:is(:first-child, :nth-child(2))) header.is-scrolled:has(>.is-position-sticky) .has-custom-pink-color {
    color: var(--wp--preset--color--custom-schwarz) !important;
}
