/*
Theme Name: Peaceful Sleep
Theme URI:
Author: Abstract Marketing
Author URI:
Description:
Requires at least: 7.0
Tested up to: 7.0
Requires PHP: 7.4
Version: 1.0.5
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: peaceful-sleep
Tags: full-site-editing
*/

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
}

iframe {
	display: block;
}

:where(input:not(:is([type='button'], [type='submit'])), select, textarea) {
	font: inherit
}

:where(input:not(:is([type='button'], [type='submit'])), select, textarea) {
	background-color: var(--wp--preset--color--base);
	border: 1px solid #bbb;
	border-radius: 4px;
	color: var(--wp--preset--color--contrast);
	font-family: inherit;
	font-size: var(--wp--preset--font-size--small);
	font-weight: 400;
	line-height: 1.5;
	padding: var(--wp--preset--spacing--30) var(--wp--preset--spacing--40);
	width: 100%;
}

:where(input:focus, textarea:focus, select:focus) {
	outline: 2px solid var(--wp--preset--color--primary);
}

:where(input[type='checkbox'], input[type='image'], input[type='radio']) {
	width: auto;
}

::placeholder {
	color: var(--wp--preset--color--contrast);
	opacity: 0.5;
}

.is-style-outline:is(:hover, :focus) .wp-block-button__link:not(.has-background) {
	background-color: rgb(0 0 0 / .1);
}

.entry-content {
	container-type: inline-size;
}

.entry-content :is(.alignleft, .alignright) {
	margin-block-end: 1em;
}

.entry-content :is(.alignleft, .alignright):first-child + * {
	margin-top: 0;
}

@container (width < 600px) {
	.entry-content .wp-block-image:is(.alignright, .alignleft) {
		float: none !important;
		margin: 0 0 1.5rem;
		width: 100%;
		text-align: center;
	}

	.entry-content .wp-block-image:is(.alignright, .alignleft) img {
		max-height: 400px;
		width: auto !important;
		display: inline-block !important;
	}
}

.wp-site-blocks {
	display: grid;
	grid-template-rows: auto 1fr auto;
	grid-template-columns: 100%;
	min-height: 100%;
}

.wp-site-blocks > * {
	margin: 0;
}

.site-header:has(.is-sticky) {
	position: sticky;
	top: 0;
	z-index: 10;
	box-shadow: 0 0 9px #0001;
}

.admin-bar .site-header:has(.is-sticky) {
	top: 40px;
}

@media (min-width: 782px) {
	.admin-bar .site-header:has(.is-sticky) {
		top: 32px;
	}
}

.has-modal-open :is(.site-header, .site-header__inner) {
	-webkit-backdrop-filter: unset !important;
	backdrop-filter: unset !important;
}

.wp-block-breadcrumbs li {
	max-width: 200px;
	display: inline-block;
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
}

.linked-group {
	position: relative;
	overflow: hidden;
	transition: transform .2s;

	&:hover {
		transform: translateY(-5px);
	}

	a::after {
		content: '';
		position: absolute;
		inset: -500px 0;
		z-index: 1;
	}
}

.site-header {
    position: sticky;
    top: -44px;
    z-index: 100;
}

@media (max-width: 991px) {
    .site-header__main {
        display: flex;
        
        .wp-block-site-logo {
            text-align: left;
            width: 100%;
            
            img {
                width: 130px;
            }
        }
        
        button svg {
            width: 48px;
            height: 48px;
        }
    }
}

@media (min-width: 992px) {
    .site-header {
        top: -232px;
    }
}

@media (min-width: 992px) {
    .wp-block-navigation__submenu-container {
        border-radius: 10px !important;
        overflow: hidden !important;

        & span {
            text-transform: capitalize !important;
            letter-spacing: 0;
        }

        & li:hover {
            color: var(--wp--preset--color--primary)
        }
    }
}
