/*
 Theme Name: Teehee Divi Child
 Theme URI: https://teeheeasia.com/
 Description: Site-specific customizations for Teehee on Divi.
 Author: Teehee
 Template: Divi
 Version: 1.0.0
 Text Domain: teehee-divi-child
*/

/* Keep the Divi Toolbox off-canvas panel fully inside every viewport. */
body.dtb_mobile #mobile_menu {
	right: 0 !important;
	width: clamp(288px, 20vw, 350px) !important;
	max-width: 100vw !important;
	box-sizing: border-box;
	overscroll-behavior: contain;
}

body.dtb_mobile #mobile_menu > li > a {
	display: flex;
	align-items: center;
	min-height: 44px;
	padding-inline: 24px !important;
	box-sizing: border-box;
	font-size: 20px !important;
	line-height: 1.25 !important;
}

.mobile_menu_bar[role="button"]:focus-visible {
	outline: 2px solid #eabd00;
	outline-offset: 4px;
}

/* Divi 5 drops the D4 alignment class from the homepage clients CTA wrapper. */
body.home .et_pb_button_module_wrapper.et_pb_button_0_wrapper {
	text-align: center;
}

/* The responsive poster stays above the video until playback actually starts. */
.home .teehee-home-hero-poster,
.home .teehee-home-hero-video {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	object-fit: cover;
}

.home .teehee-home-hero-poster {
	display: block;
	z-index: 2;
	pointer-events: none;
}

.home .teehee-home-hero-poster[hidden] {
	display: none;
}

.home .teehee-home-hero-poster img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
}

.home .teehee-home-hero-video {
	z-index: 1;
}

@media (max-width: 980px) {
	body.dtb_mobile #mobile_menu {
		width: min(82vw, 350px) !important;
	}
}

@media (max-width: 767px) {
	.home .et_pb_fullwidth_header_0 .et_pb_fullwidth_header_overlay {
		background-color: rgba(0, 0, 0, 0.15) !important;
	}
}

@media (max-width: 480px) {
	body.dtb_mobile #mobile_menu {
		width: 82vw !important;
		min-width: 0 !important;
	}

	body.dtb_mobile #mobile_menu > li > a {
		padding-inline: 22px !important;
		font-size: 18px !important;
	}
}


/* codex-project-hero-logo-center: Divi 5 portfolio hero alignment */
body.single-project .et_pb_fullwidth_header .header-content > img.header-logo {
    display: block;
    align-self: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
    max-width: 100%;
    height: auto;
}
