/* Design tokens */
:root {
	--cip-ink: #17243a;
	--cip-muted: #697687;
	--cip-line: #e7ebef;
	--cip-red: #d31f39;
	--cip-shell: 1140px;
}

/* Shared shell */
.cip-shell-header *,
.cip-shell-footer *,
.cip-mobile-sticky * {
	box-sizing: border-box;
}

.cip-shell-header,
.cip-shell-footer {
	color: var(--cip-ink);
	font-family: inherit;
}

.cip-shell-header a,
.cip-shell-footer a {
	color: inherit;
	text-decoration: none;
}

.cip-shell-container {
	width: min(var(--cip-shell), calc(100% - 32px));
	margin-inline: auto;
}

.cip-shell-header .cip-svg-icon {
	width: 18px;
	height: 18px;
}

/* Toolbar */
.cip-shell-tools {
	height: 42px;
	border-bottom: 1px solid var(--cip-line);
	background: #fafbfc;
}

.cip-shell-tools__inner {
	display: flex;
	align-items: center;
	gap: 22px;
	height: 100%;
	font-size: 11px;
}

.cip-tool {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	white-space: nowrap;
}

.cip-tool:hover {
	color: var(--cip-red);
}

.cip-tool--phone {
	margin-right: auto;
	color: var(--cip-red);
	font-weight: 700;
}

.cip-tool--phone b {
	direction: ltr;
	font-size: 13px;
}

.cip-search {
	display: flex;
	width: 240px;
	height: 31px;
}

.cip-search input {
	min-width: 0;
	flex: 1;
	padding: 0 11px;
	border: 1px solid #e3e7eb;
	border-left: 0;
	border-radius: 0 7px 7px 0;
	background: #fff;
	font: inherit;
	outline: 0;
}

.cip-search button {
	display: grid;
	width: 38px;
	border: 0;
	border-radius: 7px 0 0 7px;
	background: var(--cip-red);
	color: #fff;
	place-items: center;
	cursor: pointer;
}

.cip-search .cip-svg-icon {
	width: 16px;
	height: 16px;
	stroke-width: 2;
}

/* Main header */
.cip-shell-main {
	position: relative;
	height: 118px;
	border-bottom: 1px solid #eff1f3;
	background: rgba(255, 255, 255, .98);
}

.cip-shell-main__inner {
	display: flex;
	align-items: center;
	gap: 26px;
	height: 100%;
}

.cip-brand,
.cip-shell-main .custom-logo-link {
	width: 156px;
	flex: 0 0 156px;
}

.cip-brand img,
.cip-shell-main .custom-logo {
	display: block;
	width: 100%;
	height: auto;
}

.cip-menu-toggle {
	display: none;
}

.cip-shell-header .cip-consult {
	padding: 10px 24px;
	border-radius: 11px;
	background: var(--cip-red);
	color: #fff;
	font-size: 12px;
	font-weight: 800;
}

/* Primary navigation */
.cip-primary-nav {
	flex: 1;
	align-self: stretch;
}

.cip-menu {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 30px;
	height: 100%;
	margin: 0;
	padding: 0;
	list-style: none;
}

.cip-menu > li {
	display: flex;
	align-items: center;
	height: 100%;
}

.cip-menu > li > a,
.cip-menu__button {
	display: flex;
	align-items: center;
	gap: 6px;
	min-height: 44px;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--cip-ink);
	font: 600 12px/1.7 var(--cip-font-family);
	cursor: pointer;
}

.cip-menu > li > a:hover,
.cip-menu__button:hover,
.cip-menu__button[aria-expanded="true"] {
	color: var(--cip-red);
}

.cip-menu__button .cip-chevron {
	width: 13px;
	height: 13px;
	transition: transform .18s;
}

.cip-menu__button[aria-expanded="true"] .cip-chevron {
	transform: rotate(180deg);
}

.cip-nav-icon,
.cip-mobile-sticky {
	display: none;
}

/* Services mega menu */
.cip-mega {
	position: absolute;
	z-index: 30;
	top: 100%;
	right: 50%;
	display: grid;
	grid-template-columns: 270px 1fr;
	width: min(1200px, calc(100vw - 32px));
	height: 376px;
	padding: 14px;
	transform: translateX(50%);
	border: 1px solid var(--cip-line);
	border-radius: 0 0 14px 14px;
	background: #fff;
	box-shadow: 0 14px 34px rgba(16, 34, 51, .11);
}

.cip-mega[hidden],
.cip-guide[hidden] {
	display: none;
}

.cip-mega__tabs {
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding-left: 12px;
	border-left: 1px solid #edf0f2;
}

.cip-mega__tabs button {
	display: flex;
	align-items: center;
	gap: 9px;
	min-height: 58px;
	padding: 7px 9px;
	border: 1px solid #edf0f2;
	border-radius: 14px;
	background: #f7f9fb;
	color: var(--cip-ink);
	font: 700 13px/1.6 var(--cip-font-family);
	text-align: right;
	cursor: pointer;
}

.cip-mega__tabs button:hover,
.cip-mega__tabs button.is-active {
	background: #fff1f3;
	color: #c71934;
}

.cip-icon {
	display: grid;
	width: 38px;
	height: 38px;
	flex: 0 0 38px;
	border-radius: 11px;
	place-items: center;
}

.cip-icon .cip-svg-icon {
	width: 20px;
	height: 20px;
}

.cip-icon--bank { color: #008d88; background: #dff3f0; }
.cip-icon--company { color: #6850cf; background: #eee9ff; }
.cip-icon--income { color: #d78525; background: #fff0e0; }
.cip-icon--communications { color: #168bbf; background: #e6f3ff; }
.cip-icon--transfer { color: #cf4c73; background: #fde8ed; }

.cip-mega__content {
	padding: 4px 28px;
	overflow: auto;
}

.cip-mega__content h2 {
	margin: 0 0 14px;
	padding-bottom: 12px;
	border-bottom: 1px solid #edf0f2;
	font-size: 14px;
}

.cip-links {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0 28px;
}

.cip-links a {
	min-height: 44px;
	padding: 11px 4px;
	border-bottom: 1px solid #edf0f2;
	color: #526171;
	font-size: 12.5px;
}

.cip-links a:hover {
	background: #fafbfc;
	color: var(--cip-red);
}

/* Guide submenu */
.cip-guide {
	position: absolute;
	z-index: 31;
	top: calc(100% - 29px);
	display: grid;
	gap: 6px;
	width: 320px;
	padding: 9px;
	border: 1px solid var(--cip-line);
	border-radius: 12px;
	background: #fff;
	box-shadow: 0 12px 30px rgba(16, 34, 51, .1);
}

.cip-guide a {
	padding: 12px;
	border: 1px solid #edf0f2;
	border-radius: 9px;
	background: #f7f9fb;
	font-size: 12px;
}

.cip-guide a:hover {
	border-color: #f0cfd5;
	background: #fff1f3;
	color: var(--cip-red);
}

/* Footer */
.cip-shell-footer {
	padding-top: 44px;
	border-top: 1px solid var(--cip-line);
	background: #fff;
}

.cip-footer-grid {
	display: grid;
	grid-template-columns: 1.4fr .8fr .9fr 1.2fr;
	gap: 44px;
}

.cip-shell-footer section {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
}

.cip-shell-footer h2 {
	margin: 0 0 11px;
	font-size: 13px;
}

.cip-shell-footer p,
.cip-shell-footer section > a {
	margin: 0 0 7px;
	color: #606b78;
	font-size: 10.5px;
	line-height: 1.9;
}

.cip-shell-footer .cip-brand,
.cip-shell-footer .custom-logo-link {
	display: block;
	width: 182px;
	margin-bottom: 12px;
}

.cip-shell-footer .cip-brand img,
.cip-shell-footer .custom-logo {
	display: block;
	width: 100%;
	height: auto;
}

.cip-shell-footer strong {
	margin: 5px 0 10px;
	font-size: 11px;
}

.cip-trust {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 9px;
	width: 100%;
}

.cip-trust a {
	display: grid;
	height: 78px;
	padding: 9px;
	border: 1px solid #e1e6ed;
	border-radius: 9px;
	place-items: center;
}

.cip-trust a:hover {
	border-color: var(--cip-red);
}

.cip-trust img {
	display: block;
	max-width: 100%;
	max-height: 55px;
	object-fit: contain;
}

.cip-footer-warning {
	margin-top: 25px;
	padding: 13px 0;
	border-top: 1px solid var(--cip-line);
	color: #7b8490;
	font-size: 9.5px;
}

/* Desktop interaction area */
@media (min-width: 1025px) {
	.cip-menu__item--services {
		position: static;
	}

	.cip-mega {
		top: calc(100% - 1px);
	}

	.cip-mega__tabs button {
		transition: background-color .14s, color .14s, border-color .14s;
	}

	.cip-mega__tabs button:hover {
		border-color: #f0cfd5;
	}

	.cip-menu__item--services > .cip-menu__button {
		position: relative;
	}

	.cip-menu__item--services > .cip-menu__button::after {
		position: absolute;
		top: 100%;
		right: -12px;
		left: -12px;
		height: 38px;
		content: "";
	}
}

/* Tablet and mobile navigation */
@media (max-width: 1024px) {
	.cip-shell-tools {
		height: 38px;
	}

	.cip-shell-tools__inner {
		justify-content: space-between;
	}

	.cip-tool--desktop,
	.cip-search {
		display: none;
	}

	.cip-tool--phone {
		margin: 0;
	}

	.cip-shell-main {
		height: 76px;
	}

	.cip-shell-main__inner {
		justify-content: space-between;
	}

	.cip-brand,
	.cip-shell-main .custom-logo-link {
		width: 145px;
		flex-basis: 145px;
	}

	.cip-consult {
		display: none;
	}

	.cip-menu-toggle {
		display: grid;
		order: 3;
		align-content: center;
		gap: 4px;
		width: 42px;
		height: 42px;
		padding: 8px;
		border: 0;
		background: transparent;
		cursor: pointer;
	}

	.cip-menu-toggle span {
		display: block;
		width: 24px;
		height: 2px;
		margin: auto;
		border-radius: 2px;
		background: var(--cip-ink);
	}

	.cip-menu-toggle b {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip: rect(0, 0, 0, 0);
	}

	.cip-primary-nav {
		position: absolute;
		z-index: 40;
		top: 100%;
		right: 0;
		left: 0;
		display: none;
		height: calc(100vh - 114px);
		overflow: auto;
		border-top: 1px solid var(--cip-line);
		background: #fff;
	}

	.cip-primary-nav.is-open {
		display: block;
	}

	.cip-menu {
		display: block;
		width: min(680px, 100%);
		height: auto;
		margin: auto;
		padding: 12px;
	}

	.cip-menu > li {
		display: block;
		height: auto;
		border-bottom: 1px solid #edf0f2;
	}

	.cip-menu > li > a,
	.cip-menu__button {
		display: grid;
		grid-template-columns: 28px 1fr auto;
		gap: 9px;
		width: 100%;
		min-height: 50px;
		justify-content: space-between;
		font-size: 13px;
		text-align: right;
	}

	.cip-nav-icon {
		display: grid;
		width: 28px;
		height: 28px;
		flex: 0 0 28px;
		border-radius: 8px;
		background: #fff1f3;
		color: #c71934;
		place-items: center;
	}

	.cip-nav-icon .cip-svg-icon {
		width: 16px;
		height: 16px;
	}

	.cip-menu > li > a > .cip-nav-icon + span,
	.cip-menu__button > .cip-nav-icon + span {
		justify-self: start;
	}

	.cip-menu__button > .cip-chevron {
		grid-column: 3;
	}

	.cip-menu__item--services > .cip-menu__button .cip-nav-icon {
		background: #f4f0ff;
		color: #6850cf;
	}

	.cip-menu__item--guide > .cip-menu__button .cip-nav-icon {
		background: #fff1f3;
		color: #c71934;
	}

	.cip-mega {
		position: static;
		display: block;
		width: 100%;
		height: auto;
		padding: 0 0 12px;
		transform: none;
		border: 0;
		border-radius: 0;
		box-shadow: none;
	}

	.cip-mega__tabs {
		padding: 0;
		border: 0;
	}

	.cip-mega__tabs button {
		min-height: 52px;
	}

	.cip-mega__content {
		padding: 10px;
	}

	.cip-links {
		grid-template-columns: 1fr;
	}

	.cip-guide {
		position: static;
		width: 100%;
		padding: 0 0 10px;
		border: 0;
		box-shadow: none;
	}

	.cip-footer-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.cip-shell-footer {
		padding-bottom: 16px;
	}
}

/* Mobile shell */
@media (max-width: 767px) {
	.cip-shell-container {
		width: min(520px, calc(100% - 24px));
	}

	.cip-shell-tools__inner {
		gap: 8px;
	}

	.cip-tool {
		overflow: hidden;
		font-size: 9px;
	}

	.cip-tool span {
		overflow: hidden;
		white-space: nowrap;
		text-overflow: ellipsis;
	}

	.cip-tool--phone span {
		display: none;
	}

	.cip-brand,
	.cip-shell-main .custom-logo-link {
		width: 132px;
		flex-basis: 132px;
	}

	body.home {
		padding-bottom: 72px;
	}

	.home .cip-shell-footer {
		display: none;
	}

	.home .cip-mobile-sticky {
		position: fixed;
		z-index: 60;
		right: 0;
		bottom: 0;
		left: 0;
		display: grid;
		grid-template-columns: repeat(5, minmax(0, 1fr));
		align-items: stretch;
		height: 68px;
		padding: 5px max(7px, env(safe-area-inset-right)) calc(5px + env(safe-area-inset-bottom)) max(7px, env(safe-area-inset-left));
		border-top: 1px solid #e8ebee;
		background: rgba(255, 255, 255, .98);
		box-shadow: 0 -5px 18px rgba(17, 35, 51, .07);
	}

	.cip-mobile-sticky a,
	.cip-mobile-sticky button {
		display: flex;
		min-width: 0;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		gap: 3px;
		border: 0;
		border-radius: 10px;
		background: transparent;
		color: #6f7a84;
		font-size: 10px;
		font-weight: 500;
		text-decoration: none;
		cursor: pointer;
	}

	.cip-mobile-sticky a.is-active {
		background: #fff1f3;
		color: #c71934;
	}

	.cip-mobile-sticky .cip-svg-icon {
		width: 20px;
		height: 20px;
	}
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	.cip-menu__button .cip-chevron,
	.cip-mega__tabs button {
		transition: none;
	}
}

/* WooCommerce containment: legacy galleries and hidden Gravity Forms fields
 * must not widen RTL product pages beyond the viewport. */
.single-product .woocommerce-product-gallery,
.single-product .elementor-add-to-cart {
	max-width: 100%;
	overflow-x: clip;
}

.single-product .gform_wrapper.gravity-theme .gfield.gfield_visibility_hidden {
	position: fixed !important;
	top: 0;
	left: 0 !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip-path: inset(50%);
}
