/* ==========================================================================
   OIB Header Nav — flat bar, brand left | menu CENTER | CTA RIGHT
   ========================================================================== */

.oib-nav,
.oib-nav * {
	box-sizing: border-box;
}

.oib-nav {
	font-family: var(--oib-font, "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif);
	background-color: #ffffff;
	border-bottom: 1px solid #eef0f2;
	width: 100%;
	z-index: 100;
	-webkit-font-smoothing: antialiased;
}

/* ---- Fixed-on-scroll ----
   Pin the entire Elementor widget wrapper (`.oib-nav-sticky-yes` is added by
   the widget's `prefix_class` when Sticky is on). `position: fixed` is more
   reliable than `sticky` because Elementor's nested `.elementor-widget-container`
   ancestors often have `overflow: hidden`/`transform`, which break sticky.
   A JS-injected `.oib-nav-spacer` sibling reserves the same height so page
   content doesn't slide under the bar. */
.oib-nav-sticky-yes.elementor-widget-oib_header_nav {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	width: 100%;
	z-index: 1000;
}

.oib-nav-spacer {
	display: block;
	width: 100%;
	flex-shrink: 0;
}

/* Subtle elevation only when scrolled past the top (class added by JS) */
.oib-nav--sticky {
	transition: box-shadow 0.25s ease, background-color 0.25s ease;
}

.oib-nav.is-scrolled {
	box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04), 0 6px 20px -16px rgba(15, 23, 42, 0.18);
}

/* ---- 3-column grid: brand | menu | cta ---- */
.oib-nav__inner {
	position: relative;
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	align-items: center;
	column-gap: 24px;
	margin: 0 auto;
	padding: 22px 40px;
}

.oib-nav__inner--narrow { max-width: 1080px; }
.oib-nav__inner--wide   { max-width: 1280px; }
.oib-nav__inner--full   { max-width: 100%; }

/* The nav + panel use `display: contents` so their children become direct
   grid items of .oib-nav__inner — the <ul> lands in col 2, the CTA in col 3. */
.oib-nav__menu-wrap,
.oib-nav__panel {
	display: contents;
}

/* ---- Brand (col 1) ---- */
.oib-nav__brand-link {
	display: inline-flex;
	align-items: center;
	text-decoration: none !important;
	color: inherit;
	justify-self: start;
	background: none !important;
	border: 0 !important;
	padding: 0 !important;
	box-shadow: none !important;
	grid-column: 1;
}

.oib-nav__brand {
	font-size: 22px;
	font-weight: 700;
	letter-spacing: -0.01em;
	color: #0f172a;
	line-height: 1;
}

.oib-nav__brand-img {
	display: block;
	max-height: 36px;
	width: auto;
	border: 0;
}

/* ---- Menu list (col 2, centered) ---- */
.oib-nav__menu {
	grid-column: 2;
	display: flex;
	align-items: center;
	gap: 48px;
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
	justify-self: center;
}

.oib-nav__item {
	display: flex;
	align-items: center;
	margin: 0 !important;
	padding: 0 !important;
	background: none !important;
	border: 0 !important;
	list-style: none !important;
}

.oib-nav__link {
	position: relative;
	display: inline-block;
	color: #0f172a;
	text-decoration: none !important;
	font-size: 16px;
	font-weight: 500;
	line-height: 1.2;
	padding: 6px 0 8px;
	background: none !important;
	border: 0 !important;
	box-shadow: none !important;
	transition: color 0.18s ease;
}

.oib-nav__link:hover,
.oib-nav__link:focus-visible {
	color: #7E5D74;
	outline: none;
	text-decoration: none !important;
}

.oib-nav__link.is-active {
	color: #7E5D74;
	font-weight: 600;
}

.oib-nav__link.is-active::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 3px;
	border-radius: 2px;
	background-color: #7E5D74;
}

/* ---- CTA (col 3, right) ---- */
.oib-nav__cta {
	grid-column: 3;
	justify-self: end;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background-color: #7E5D74;
	color: #ffffff !important;
	font-size: 15px;
	font-weight: 600;
	line-height: 1;
	padding: 15px 28px;
	border-radius: 14px;
	text-decoration: none !important;
	border: 0 !important;
	box-shadow: none;
	transition:
		background-color 0.18s ease,
		transform 0.18s ease,
		box-shadow 0.18s ease;
	white-space: nowrap;
}

.oib-nav__cta:hover,
.oib-nav__cta:focus-visible {
	background-color: #6A4960;
	transform: translateY(-1px);
	box-shadow: 0 8px 18px -8px rgba(126, 93, 116, 0.55);
	outline: none;
	color: #ffffff !important;
}

.oib-nav__cta:active {
	transform: translateY(0);
}

/* ---- Hamburger (hidden on desktop) ---- */
.oib-nav__toggle {
	display: none;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
	width: 40px;
	height: 40px;
	background: transparent;
	border: 1px solid #eef0f2;
	border-radius: 10px;
	padding: 0 10px;
	cursor: pointer;
	transition: background-color 0.2s ease;
	grid-column: 3;
	justify-self: end;
}

.oib-nav__toggle:hover { background: rgba(15, 23, 42, 0.05); }

.oib-nav__toggle-bar {
	display: block;
	height: 2px;
	width: 100%;
	background-color: #0f172a;
	border-radius: 2px;
	transition: transform 0.25s ease, opacity 0.2s ease;
}

.oib-nav__toggle[aria-expanded="true"] .oib-nav__toggle-bar:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}
.oib-nav__toggle[aria-expanded="true"] .oib-nav__toggle-bar:nth-child(2) {
	opacity: 0;
}
.oib-nav__toggle[aria-expanded="true"] .oib-nav__toggle-bar:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
	.oib-nav__menu  { gap: 32px; }
	.oib-nav__inner { padding: 18px 24px; }
}

@media (max-width: 960px) {
	/* Switch to 2-column: brand | toggle */
	.oib-nav__inner {
		grid-template-columns: 1fr auto;
		padding: 14px 20px;
	}

	/* Switch wrappers back to normal block flow on mobile */
	.oib-nav__menu-wrap { display: block; grid-column: auto; }
	.oib-nav__panel {
		display: block;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		background: #ffffff;
		border-top: 1px solid #eef0f2;
		box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
		padding: 8px 16px 18px;
		transform: translateY(-8px);
		opacity: 0;
		visibility: hidden;
		pointer-events: none;
		transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s linear 0.22s;
		z-index: 50;
	}

	.oib-nav__toggle {
		display: flex;
		grid-column: 2;
	}

	.oib-nav__toggle[aria-expanded="true"] ~ .oib-nav__panel,
	.oib-nav__panel.is-open {
		transform: translateY(0);
		opacity: 1;
		visibility: visible;
		pointer-events: auto;
		transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s;
	}

	.oib-nav__menu {
		grid-column: auto;
		justify-self: stretch;
		flex-direction: column;
		align-items: stretch;
		gap: 0;
	}

	.oib-nav__item {
		width: 100%;
		border-bottom: 1px solid #f1f3f5 !important;
	}

	.oib-nav__item:last-child { border-bottom: 0 !important; }

	.oib-nav__link {
		width: 100%;
		padding: 14px 4px;
		font-size: 16px;
	}

	.oib-nav__link.is-active::after { display: none; }

	.oib-nav__cta {
		grid-column: auto;
		justify-self: stretch;
		width: 100%;
		margin-top: 10px;
		padding: 14px 22px;
	}
}

@media (max-width: 480px) {
	.oib-nav__brand     { font-size: 20px; }
	.oib-nav__brand-img { max-height: 32px; }
	.oib-nav__inner     { padding: 12px 16px; }
}

/* ==========================================================================
   A11y / motion
   ========================================================================== */
.oib-nav__brand-link:focus-visible,
.oib-nav__link:focus-visible,
.oib-nav__cta:focus-visible,
.oib-nav__toggle:focus-visible {
	box-shadow: 0 0 0 3px rgba(126, 93, 116, 0.35);
}

@media (prefers-reduced-motion: reduce) {
	.oib-nav__link,
	.oib-nav__cta,
	.oib-nav__toggle-bar,
	.oib-nav__panel {
		transition: none !important;
	}
	.oib-nav__cta:hover { transform: none; }
}
