/* ============================================================
 * Zendip Fixes v1.2 — front-end CSS overrides
 * Focus: logo strictly header-only, buttons strictly two,
 * header height capped, hero padding-top safe.
 * No design changes beyond what is needed for these fixes.
 * ============================================================ */

/* ============================================================
 * 1 + 3. HEADER — logo left, menu right, clean spacing, max 80px
 * ============================================================ */
header.site-header,
.site-header,
.main-header,
#site-header,
header#masthead,
.header-wrap,
.zendip-header {
	min-height: 70px;
	max-height: 80px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 10px 24px;
	box-sizing: border-box;
}

/* Logo wrapper anchored LEFT */
.site-header .site-logo,
.site-header .custom-logo-link,
.site-header .site-branding,
.main-header .logo,
header .logo-wrap,
.zendip-header .site-logo {
	margin-right: auto;
	margin-left: 0;
	flex-shrink: 0;
	display: flex;
	align-items: center;
}

/* Cap header logo size — desktop */
.site-header .site-logo img,
.site-header .custom-logo,
.site-header .custom-logo-link img,
.site-header .site-branding img,
header .site-title img,
header img.logo,
.main-header .logo img,
.zendip-header .site-logo img,
.custom-logo,
.custom-logo-link img {
	max-width: 200px !important;
	max-height: 56px !important;
	width: auto !important;
	height: auto !important;
	object-fit: contain !important;
	display: block;
}

/* Hamburger / menu pinned RIGHT with clean spacing */
.site-header .menu-toggle,
.site-header #mobile-toggle,
.main-header .menu-toggle,
.mobile-menu-button,
.hamburger,
.zendip-header #mobile-toggle {
	margin-left: 16px;
	flex-shrink: 0;
}

/* ============================================================
 * 1 + 4. HERO — strip ANY logo image dropped inside the hero
 * ============================================================ */
.hero img.logo,
.hero img.site-logo,
.hero .custom-logo,
.hero .custom-logo-link,
.hero .site-logo,
.hero .site-branding,
.hero-section img.logo,
.hero-section .custom-logo,
.hero-section .custom-logo-link,
.hero-section .site-logo,
.hero-section .site-branding,
.page-hero img.logo,
.page-hero .custom-logo,
.site-hero img.logo,
section.hero img.logo,
section.hero .custom-logo,
section.hero .site-logo,
.hero img[src*="logo" i],
.hero img[alt*="logo" i],
.hero-section img[src*="logo" i],
.hero-section img[alt*="logo" i],
section.hero img[src*="logo" i],
section.hero img[alt*="logo" i],
.elementor-section.hero img[src*="logo" i],
.elementor-section.hero-section img[src*="logo" i] {
	display: none !important;
}

/* Hide an entire wrapper if it ONLY contains a logo image */
.hero figure:has(> img[src*="logo" i]),
.hero-section figure:has(> img[src*="logo" i]),
section.hero figure:has(> img[src*="logo" i]),
.hero .wp-block-image:has(> img[src*="logo" i]),
.hero-section .wp-block-image:has(> img[src*="logo" i]) {
	display: none !important;
}

/* Hero padding so sticky/fixed header never overlaps headline */
.hero,
.hero-section,
.page-hero,
.site-hero,
section.hero {
	padding-top: 90px !important;
}

/* ============================================================
 * 2. CTA BUTTONS — keep only 2, remove "Get Consultation" duplicate
 * ============================================================ */
.hero-buttons,
.hero-cta,
.hero-actions,
.hero .buttons,
.hero-section .cta-group,
.hero-section .hero-buttons {
	display: flex;
	gap: 16px;
	flex-wrap: wrap;
	align-items: center;
}

/* Hide any 3rd or later button in any hero CTA group */
.hero-buttons > a:nth-of-type(n+3),
.hero-buttons > button:nth-of-type(n+3),
.hero-cta > a:nth-of-type(n+3),
.hero-cta > button:nth-of-type(n+3),
.hero-actions > a:nth-of-type(n+3),
.hero-actions > button:nth-of-type(n+3),
.hero .buttons > a:nth-of-type(n+3),
.hero .buttons > button:nth-of-type(n+3),
.hero-section .cta-group > a:nth-of-type(n+3),
.hero-section .cta-group > button:nth-of-type(n+3) {
	display: none !important;
}

/* Belt-and-braces — JS marker class also hides the button */
.zendip-hide-cta { display: none !important; }

/* ============================================================
 * MOBILE
 * ============================================================ */
@media (max-width: 768px) {

	/* Header */
	header.site-header,
	.site-header,
	.main-header,
	#site-header,
	header#masthead,
	.header-wrap,
	.zendip-header {
		min-height: 64px;
		max-height: 80px;
		padding: 8px 16px;
	}

	/* Logo cap on mobile */
	.site-header .site-logo img,
	.site-header .custom-logo,
	.site-header .custom-logo-link img,
	.site-header .site-branding img,
	header .site-title img,
	header img.logo,
	.main-header .logo img,
	.zendip-header .site-logo img,
	.custom-logo,
	.custom-logo-link img {
		max-width: 140px !important;
		max-height: 48px !important;
	}

	/* Hero padding tightened a touch on phones but still safe */
	.hero,
	.hero-section,
	.page-hero,
	.site-hero,
	section.hero {
		padding-top: 80px !important;
	}

	/* CTAs stacked, full-width, 16px gap */
	.hero-buttons,
	.hero-cta,
	.hero-actions,
	.hero .buttons,
	.hero-section .cta-group,
	.hero-section .hero-buttons {
		flex-direction: column;
		width: 100%;
		gap: 16px;
	}

	.hero-buttons a,
	.hero-buttons button,
	.hero-cta a,
	.hero-cta button,
	.hero-actions .btn,
	.hero-actions a,
	.hero .buttons a,
	.hero-section .cta-group a {
		width: 100%;
		max-width: 360px;
		margin: 0 auto !important;
		text-align: center;
		display: block;
		box-sizing: border-box;
	}
}

/* ============================================================
 * LEGAL FOOTER FALLBACK BAR (unchanged from v1.1)
 * ============================================================ */
.zendip-legal-bar {
	background: #0A1F44;
	color: #E5E7EB;
	padding: 24px 20px;
	font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	font-size: 13px;
	line-height: 1.6;
}
.zendip-legal-bar-inner { max-width: 1200px; margin: 0 auto; text-align: center; }
.zendip-legal-bar-label {
	color: #C8A24B;
	font-weight: 600;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	font-size: 11px;
	margin-right: 8px;
}
.zendip-legal-bar a { color: #E5E7EB; text-decoration: none; margin: 0 4px; }
.zendip-legal-bar a:hover { color: #C8A24B; }
.zendip-sep { color: #4A5568; }
.zendip-legal-disclaimer {
	margin-top: 14px;
	color: #9CA3AF;
	font-size: 11px;
	line-height: 1.7;
	max-width: 900px;
	margin-left: auto;
	margin-right: auto;
}
@media (max-width: 600px) {
	.zendip-legal-bar a { display: inline-block; padding: 4px 0; }
}

/* ============================================================
 * v1.4 — Issue 7 case-study disclaimer + Issue 10 premium polish
 * ============================================================ */

/* Case-study disclaimer */
.zendip-case-disclaimer {
	background: #F8FAFC;
	border-top: 1px solid #E2E8F0;
	border-bottom: 1px solid #E2E8F0;
	padding: 24px 20px;
	margin: 32px 0 0;
}
.zendip-case-disclaimer-inner {
	max-width: 1100px;
	margin: 0 auto;
	color: #475569;
	font-size: 13px;
	line-height: 1.7;
	font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
.zendip-case-disclaimer strong { color: #0A1F44; margin-right: 6px; }

/* Stripe-safe statement on Stripe pages */
.zendip-stripe-safe {
	background: #F4F6FA;
	border-left: 4px solid #C8A24B;
	padding: 20px 24px;
	margin: 32px auto;
	max-width: 1100px;
	border-radius: 6px;
}
.zendip-stripe-safe-inner {
	color: #334155;
	font-size: 13px;
	line-height: 1.7;
	font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
.zendip-stripe-safe strong { color: #0A1F44; display: block; margin-bottom: 4px; font-size: 14px; }

/* ============================================================
 * Issue 10 — premium UI polish (small, surgical, no redesign)
 * ============================================================ */

/* Smoother type rendering site-wide */
body.zendip-fixes-active {
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

/* Header: subtle premium polish — backdrop blur on scroll, soft border */
body.zendip-fixes-active header.site-header,
body.zendip-fixes-active .site-header,
body.zendip-fixes-active .main-header,
body.zendip-fixes-active #site-header,
body.zendip-fixes-active header#masthead {
	border-bottom: 1px solid rgba(15, 23, 42, 0.06);
	background-color: rgba(255, 255, 255, 0.96);
	-webkit-backdrop-filter: saturate(140%) blur(8px);
	backdrop-filter: saturate(140%) blur(8px);
}

/* Tap targets minimum 44px (mobile UX) */
@media (max-width: 768px) {
	body.zendip-fixes-active a,
	body.zendip-fixes-active button {
		min-height: 44px;
	}
}

/* Footer phone & email rendering hygiene — Issue 6 polish */
body.zendip-fixes-active a[href^="tel:"],
body.zendip-fixes-active a[href^="mailto:"] {
	white-space: nowrap;
	color: inherit;
	text-decoration: none;
	transition: color 150ms ease;
}
body.zendip-fixes-active a[href^="tel:"]:hover,
body.zendip-fixes-active a[href^="mailto:"]:hover {
	color: #C8A24B;
	text-decoration: underline;
}

/* Strip stray quote/symbol artefacts that broken theme HTML can leave behind */
body.zendip-fixes-active .footer-contact,
body.zendip-fixes-active .site-footer .contact {
	letter-spacing: normal !important;
}

/* ============================================================
 * Final nav visibility fix — dark menu text on white header
 * ============================================================ */
body.zendip-fixes-active .site-header .main-nav > ul > li > a,
body.zendip-fixes-active header.site-header .main-nav > ul > li > a,
body.zendip-fixes-active .main-header .main-nav > ul > li > a,
body.zendip-fixes-active #site-header .main-nav > ul > li > a,
body.zendip-fixes-active header#masthead .main-nav > ul > li > a {
  color: #0A1F44 !important;
}
body.zendip-fixes-active .site-header .main-nav > ul > li > a:hover,
body.zendip-fixes-active header.site-header .main-nav > ul > li > a:hover,
body.zendip-fixes-active .main-header .main-nav > ul > li > a:hover,
body.zendip-fixes-active #site-header .main-nav > ul > li > a:hover,
body.zendip-fixes-active header#masthead .main-nav > ul > li > a:hover {
  color: #C8A24B !important;
}
@media (max-width: 768px) {
  body.zendip-fixes-active .site-header .main-nav.open a,
  body.zendip-fixes-active header.site-header .main-nav.open a {
    color: #FFFFFF !important;
  }
  body.zendip-fixes-active .site-header .main-nav.open .submenu a,
  body.zendip-fixes-active header.site-header .main-nav.open .submenu a {
    color: rgba(255,255,255,0.78) !important;
  }
}

/* ============================================================
 * Final mobile menu fix — keep dropdown below header, no hero overlap
 * ============================================================ */
@media (max-width: 768px) {
  body.zendip-fixes-active .site-header,
  body.zendip-fixes-active header.site-header {
    z-index: 1000 !important;
  }

  body.zendip-fixes-active .site-header .mobile-toggle span,
  body.zendip-fixes-active header.site-header .mobile-toggle span {
    background: #0A1F44 !important;
  }

  body.zendip-fixes-active .site-header .main-nav.open,
  body.zendip-fixes-active header.site-header .main-nav.open {
    position: fixed !important;
    top: 80px !important;
    left: 0 !important;
    right: 0 !important;
    bottom: auto !important;
    height: auto !important;
    max-height: calc(100vh - 80px) !important;
    overflow-y: auto !important;
    background: #0A1F44 !important;
    justify-content: flex-start !important;
    align-items: stretch !important;
    padding: 18px 32px 28px !important;
    z-index: 999 !important;
  }

  body.zendip-fixes-active .site-header .main-nav.open > ul,
  body.zendip-fixes-active header.site-header .main-nav.open > ul {
    gap: 0 !important;
  }

  body.zendip-fixes-active .site-header .main-nav.open > ul > li > a,
  body.zendip-fixes-active header.site-header .main-nav.open > ul > li > a {
    color: #FFFFFF !important;
    font-size: 18px !important;
    line-height: 1.35 !important;
    padding: 12px 0 !important;
  }

  body.zendip-fixes-active .site-header .main-nav.open .submenu,
  body.zendip-fixes-active header.site-header .main-nav.open .submenu {
    display: none !important;
  }
}

/* ============================================================
 * FINAL MOBILE HEADER/MENU REPAIR v1.8
 * Scope: mobile only. Keeps desktop untouched.
 * Fixes white header hamburger visibility and stable submenu layout.
 * ============================================================ */
@media (max-width: 768px) {
  html body .site-header,
  html body header.site-header,
  html body #site-header {
    background: #FFFFFF !important;
    min-height: 72px !important;
    max-height: none !important;
    height: auto !important;
    padding: 8px 16px !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 10000 !important;
    box-shadow: 0 1px 0 rgba(10,31,68,0.08) !important;
  }

  html body .site-header .container-wide,
  html body header.site-header .container-wide,
  html body #site-header .container-wide {
    width: 100% !important;
  }

  html body .site-header .header-inner,
  html body header.site-header .header-inner,
  html body #site-header .header-inner {
    min-height: 56px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 12px !important;
  }

  html body .site-header .site-logo,
  html body .site-header .custom-logo-link,
  html body header.site-header .site-logo,
  html body header.site-header .custom-logo-link {
    display: flex !important;
    align-items: center !important;
    color: #0A1F44 !important;
    margin: 0 !important;
    flex: 0 1 auto !important;
    max-width: calc(100% - 56px) !important;
  }

  html body .site-header .custom-logo,
  html body .site-header .custom-logo-link img,
  html body header.site-header .custom-logo,
  html body header.site-header .custom-logo-link img {
    max-width: 128px !important;
    max-height: 52px !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
  }

  html body .site-header .mobile-toggle,
  html body header.site-header .mobile-toggle,
  html body #site-header .mobile-toggle {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    padding: 10px !important;
    margin-left: auto !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    position: relative !important;
    z-index: 10002 !important;
  }

  html body .site-header .mobile-toggle span,
  html body header.site-header .mobile-toggle span,
  html body #site-header .mobile-toggle span {
    display: block !important;
    width: 26px !important;
    height: 2px !important;
    background: #0A1F44 !important;
    opacity: 1 !important;
    border-radius: 2px !important;
  }

  html body .site-header .mobile-toggle.active span,
  html body header.site-header .mobile-toggle.active span,
  html body #site-header .mobile-toggle.active span {
    background: #0A1F44 !important;
  }

  html body .site-header .header-cta,
  html body header.site-header .header-cta { display: none !important; }

  html body .site-header .main-nav,
  html body header.site-header .main-nav,
  html body #site-header .main-nav {
    display: none !important;
  }

  html body .site-header .main-nav.open,
  html body header.site-header .main-nav.open,
  html body #site-header .main-nav.open {
    display: block !important;
    position: fixed !important;
    top: 72px !important;
    left: 0 !important;
    right: 0 !important;
    bottom: auto !important;
    width: 100% !important;
    height: auto !important;
    max-height: calc(100vh - 72px) !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    background: #0A1F44 !important;
    padding: 14px 24px 22px !important;
    z-index: 10001 !important;
    box-shadow: 0 18px 40px rgba(0,0,0,0.22) !important;
  }

  html body .site-header .main-nav.open > ul,
  html body header.site-header .main-nav.open > ul,
  html body #site-header .main-nav.open > ul {
    display: flex !important;
    flex-direction: column !important;
    gap: 0 !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
  }

  html body .site-header .main-nav.open li,
  html body header.site-header .main-nav.open li,
  html body #site-header .main-nav.open li {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    position: static !important;
  }

  html body .site-header .main-nav.open > ul > li > a,
  html body header.site-header .main-nav.open > ul > li > a,
  html body #site-header .main-nav.open > ul > li > a {
    color: #FFFFFF !important;
    display: block !important;
    font-size: 17px !important;
    line-height: 1.35 !important;
    padding: 11px 0 !important;
    text-decoration: none !important;
  }

  html body .site-header .main-nav.open a::after,
  html body header.site-header .main-nav.open a::after,
  html body #site-header .main-nav.open a::after { display: none !important; }

  html body .site-header .main-nav.open .submenu,
  html body header.site-header .main-nav.open .submenu,
  html body #site-header .main-nav.open .submenu {
    display: block !important;
    position: static !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    background: rgba(255,255,255,0.06) !important;
    border: 0 !important;
    border-left: 2px solid #C8A24B !important;
    border-radius: 10px !important;
    box-shadow: none !important;
    min-width: 0 !important;
    width: 100% !important;
    margin: 2px 0 8px !important;
    padding: 6px 0 6px 14px !important;
  }

  html body .site-header .main-nav.open .submenu a,
  html body header.site-header .main-nav.open .submenu a,
  html body #site-header .main-nav.open .submenu a {
    color: rgba(255,255,255,0.84) !important;
    display: block !important;
    font-size: 14px !important;
    line-height: 1.35 !important;
    padding: 7px 0 !important;
    background: transparent !important;
  }

  html body .site-main,
  html body main.site-main {
    padding-top: 0 !important;
  }
}

/* ============================================================
 * FINAL PREMIUM HEADER COLOR FIX v1.9
 * Scope: header/nav only. Keeps content, policies, addresses, and layout untouched.
 * Desktop + mobile: replaces flat white header with premium navy gradient.
 * ============================================================ */
html body .site-header,
html body header.site-header,
html body #site-header,
html body .main-header,
html body header#masthead,
body.zendip-fixes-active .site-header,
body.zendip-fixes-active header.site-header,
body.zendip-fixes-active #site-header,
body.zendip-fixes-active .main-header,
body.zendip-fixes-active header#masthead {
  background: linear-gradient(135deg, #071A36 0%, #0A1F44 52%, #142F5C 100%) !important;
  background-color: #0A1F44 !important;
  border-bottom: 1px solid rgba(200,162,75,0.22) !important;
  box-shadow: 0 8px 28px rgba(6,22,51,0.18) !important;
  -webkit-backdrop-filter: saturate(140%) blur(10px) !important;
  backdrop-filter: saturate(140%) blur(10px) !important;
}

html body .site-header .site-logo,
html body .site-header .custom-logo-link,
html body header.site-header .site-logo,
html body header.site-header .custom-logo-link,
html body #site-header .site-logo,
html body #site-header .custom-logo-link {
  color: #FFFFFF !important;
}

html body .site-header .main-nav > ul > li > a,
html body header.site-header .main-nav > ul > li > a,
html body #site-header .main-nav > ul > li > a,
html body .main-header .main-nav > ul > li > a,
html body header#masthead .main-nav > ul > li > a,
body.zendip-fixes-active .site-header .main-nav > ul > li > a,
body.zendip-fixes-active header.site-header .main-nav > ul > li > a,
body.zendip-fixes-active #site-header .main-nav > ul > li > a,
body.zendip-fixes-active .main-header .main-nav > ul > li > a,
body.zendip-fixes-active header#masthead .main-nav > ul > li > a {
  color: #FFFFFF !important;
}

html body .site-header .main-nav > ul > li > a:hover,
html body header.site-header .main-nav > ul > li > a:hover,
html body #site-header .main-nav > ul > li > a:hover,
html body .main-header .main-nav > ul > li > a:hover,
html body header#masthead .main-nav > ul > li > a:hover,
body.zendip-fixes-active .site-header .main-nav > ul > li > a:hover,
body.zendip-fixes-active header.site-header .main-nav > ul > li > a:hover,
body.zendip-fixes-active #site-header .main-nav > ul > li > a:hover,
body.zendip-fixes-active .main-header .main-nav > ul > li > a:hover,
body.zendip-fixes-active header#masthead .main-nav > ul > li > a:hover {
  color: #C8A24B !important;
}

html body .site-header .mobile-toggle span,
html body header.site-header .mobile-toggle span,
html body #site-header .mobile-toggle span,
body.zendip-fixes-active .site-header .mobile-toggle span,
body.zendip-fixes-active header.site-header .mobile-toggle span,
body.zendip-fixes-active #site-header .mobile-toggle span {
  background: #FFFFFF !important;
}

html body .site-header .mobile-toggle.active span,
html body header.site-header .mobile-toggle.active span,
html body #site-header .mobile-toggle.active span,
body.zendip-fixes-active .site-header .mobile-toggle.active span,
body.zendip-fixes-active header.site-header .mobile-toggle.active span,
body.zendip-fixes-active #site-header .mobile-toggle.active span {
  background: #FFFFFF !important;
}

html body .site-header .header-cta,
html body header.site-header .header-cta,
html body #site-header .header-cta {
  background: #C8A24B !important;
  color: #071A36 !important;
  border-color: #C8A24B !important;
}

html body .site-header .header-cta:hover,
html body header.site-header .header-cta:hover,
html body #site-header .header-cta:hover {
  background: #E5C77B !important;
  color: #071A36 !important;
}

@media (max-width: 768px) {
  html body .site-header,
  html body header.site-header,
  html body #site-header,
  body.zendip-fixes-active .site-header,
  body.zendip-fixes-active header.site-header,
  body.zendip-fixes-active #site-header {
    background: linear-gradient(135deg, #071A36 0%, #0A1F44 52%, #142F5C 100%) !important;
    background-color: #0A1F44 !important;
    border-bottom: 1px solid rgba(200,162,75,0.22) !important;
    box-shadow: 0 8px 24px rgba(6,22,51,0.20) !important;
  }

  html body .site-header .site-logo,
  html body .site-header .custom-logo-link,
  html body header.site-header .site-logo,
  html body header.site-header .custom-logo-link,
  html body #site-header .site-logo,
  html body #site-header .custom-logo-link {
    color: #FFFFFF !important;
  }

  html body .site-header .main-nav.open,
  html body header.site-header .main-nav.open,
  html body #site-header .main-nav.open,
  body.zendip-fixes-active .site-header .main-nav.open,
  body.zendip-fixes-active header.site-header .main-nav.open,
  body.zendip-fixes-active #site-header .main-nav.open {
    background: linear-gradient(180deg, #071A36 0%, #0A1F44 100%) !important;
    border-top: 1px solid rgba(200,162,75,0.22) !important;
  }
}
