/* slo-site-header */
/* slo-site-header widget */

/*
 * Sticky header. Sticky can't escape its parent, so it goes on the itecho-core
 * header template's root (.elementor-<id>), which sits directly in the page
 * wrapper. The template container carries the "slo-header-wrap" class.
 */
.elementor:has(> .slo-header-wrap) {
	position: sticky;
	top: var(--wp-admin--admin-bar--height, 0px);
	z-index: 100;
}

/* Below 600px the WP admin bar scrolls away, so stick to the very top. */
@media (max-width: 600px) {
	.elementor:has(> .slo-header-wrap) {
		top: 0;
	}
}

/*
 * In-page anchors (#why-sri-lanka, …) land exactly at the header's bottom edge.
 * site-header.js keeps --slo-header-offset equal to the sticky header's bottom
 * (admin bar included); 81px is the desktop header height before JS runs.
 */
html:has(slo-site-header) {
	scroll-padding-top: var(--slo-header-offset, calc(var(--wp-admin--admin-bar--height, 0px) + 81px));
}

slo-site-header {
	display: block;
	position: relative;
	border-bottom: 1px solid var(--line);
	background: var(--surface);
	font-family: var(--font-sans);
}

/* Same grid as boxed sections and the Hero copy: 1280px + 40px gutters (20px mobile). */
.slo-header__bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	box-sizing: content-box;
	max-width: var(--max);
	margin: 0 auto;
	padding: 14px 40px;
}

@media (max-width: 767px) {
	.slo-header__bar {
		padding: 14px 20px;
	}
}

.slo-header__links {
	display: flex;
	align-items: center;
	gap: 4px 30px;
	margin: 0;
	padding: 0;
	list-style: none;
}

body .slo-header__link {
	padding: 12px 0;
	font-size: 16px;
	font-weight: 500;
	color: var(--ink);
	text-decoration: none;
	background-image: linear-gradient(var(--forest), var(--forest));
	background-repeat: no-repeat;
	background-position: 0 calc(100% - 8px);
	background-size: 0 2px;
	transition: background-size .2s ease, color .15s ease;
}

body .slo-header__link:hover {
	color: var(--forest);
	background-size: 100% 2px;
}

.slo-header__burger {
	display: none;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 1px solid var(--line);
	border-radius: 12px;
	background: var(--surface);
	color: var(--ink);
	cursor: pointer;
}

.slo-header__burger:hover {
	background: var(--paper);
	color: var(--ink);
}

.slo-header__burger .slo-icon--close,
.slo-header__burger[aria-expanded="true"] .slo-icon--menu {
	display: none;
}

.slo-header__burger[aria-expanded="true"] .slo-icon--close {
	display: block;
}

.slo-header__mobile {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 8px 20px 20px;
	border-top: 1px solid var(--line);
	background: var(--surface);
}

.slo-header__mobile[hidden] {
	display: none;
}

.slo-header__mobile ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

.slo-header__mobile li a {
	display: block;
	padding: 12px 0;
	border-bottom: 1px solid #F0ECE2;
	font-size: 17px;
	font-weight: 600;
	color: var(--ink);
	text-decoration: none;
}

.slo-header__mobile li:last-child a {
	border-bottom: 0;
}

@media (max-width: 960px) {
	.slo-header__links,
	.slo-header__cta {
		display: none;
	}

	.slo-header__burger {
		display: inline-flex;
	}
}

@media (min-width: 961px) {
	.slo-header__mobile {
		display: none !important; /* Never show the drawer on desktop, even if left open. */
	}
}

@media (prefers-reduced-motion: reduce) {
	.slo-header__link {
		transition: none;
	}
}

/* slo-site-footer */
/* slo-site-footer widget (Forest). The template's container supplies the background. */

.slo-footer {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 6fr) minmax(0, 3fr) minmax(0, 3fr);
	gap: clamp(56px, 6vw, 88px) clamp(32px, 5vw, 80px);
	font-family: var(--font-sans);
	color: #FFFFFF;
}

.slo-footer__brand .slo-brand {
	gap: 14px;
}

.slo-footer__brand .slo-brand__top {
	font-size: 24px;
}

.slo-footer__brand .slo-brand__bottom {
	font-size: 14px;
}

.slo-footer__blurb {
	max-width: 420px;
	margin: 28px 0 0;
	font-size: clamp(17px, 1.4vw, 19px);
	line-height: 1.6;
	color: rgba(255, 255, 255, .76);
}

.slo-footer__heading {
	margin: 0 0 20px;
	font-family: var(--font-mono);
	font-size: 12px;
	font-weight: 500;
	line-height: 1.3;
	letter-spacing: .14em;
	text-transform: uppercase;
	color: var(--lagoon);
}

.slo-footer__links {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 14px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.slo-footer__links li {
	margin: 0;
}

body .slo-footer__links a {
	display: inline-block;
	padding: 2px 0 4px;
	background: linear-gradient(var(--saffron), var(--saffron)) left 100% / 0 2px no-repeat;
	font-size: 18px;
	line-height: 1.3;
	letter-spacing: -.01em;
	font-weight: 700;
	text-decoration: none;
	color: #FFFFFF;
	transition: background-size .35s var(--ease);
}

body .slo-footer__links a:hover,
body .slo-footer__links a:focus-visible {
	background-size: 100% 2px;
	color: #FFFFFF;
}

.slo-footer__copy {
	grid-column: 1 / span 2;
	align-self: center;
	margin: 0;
	font-size: 14px;
	line-height: 1.5;
	color: rgba(255, 255, 255, .64);
}

.slo-footer .slo-footer__top {
	grid-column: 3;
	justify-self: start;
	display: inline-flex;
	align-items: center;
	gap: 10px;
	height: 42px;
	padding: 0 8px 0 18px;
	border: 1px solid rgba(255, 255, 255, .2);
	border-radius: var(--r-pill);
	background: none;
	font: inherit;
	font-size: 14px;
	font-weight: 700;
	color: #FFFFFF;
	cursor: pointer;
	transition: background .25s ease, border-color .25s ease;
}

.slo-footer__top span {
	display: grid;
	place-items: center;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: var(--saffron);
	color: var(--ink);
	transition: transform .3s var(--ease);
}

.slo-footer__top .slo-icon {
	transform: rotate(-90deg);
}

.slo-footer .slo-footer__top:hover {
	border-color: rgba(255, 255, 255, .4);
	background: rgba(255, 255, 255, .08);
	color: #FFFFFF;
}

.slo-footer__top:hover span {
	transform: translateY(-3px);
}

@media (max-width: 900px) {
	.slo-footer {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.slo-footer__brand,
	.slo-footer__copy {
		grid-column: 1 / -1;
	}

	.slo-footer .slo-footer__top {
		grid-column: 1;
	}

	.slo-footer__copy {
		order: 9;
	}
}

@media (prefers-reduced-motion: reduce) {
	body .slo-footer__links a,
	.slo-footer .slo-footer__top,
	.slo-footer__top span {
		transition: none;
	}

	.slo-footer__top:hover span {
		transform: none;
	}
}

