/* IHVN theme — small layer on top of theme.json. */

:root {
	--ihvn-radius: 10px;
	--ihvn-shadow: 0 1px 2px rgb(11 31 64 / 6%), 0 6px 20px rgb(11 31 64 / 6%);
	--ihvn-shadow-hover: 0 2px 4px rgb(11 31 64 / 8%), 0 14px 32px rgb(11 31 64 / 12%);
}

/* Accessibility helpers */
.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	white-space: nowrap;
}
.skip-link:focus {
	clip: auto; width: auto; height: auto;
	z-index: 1000; top: 0.5rem; left: 0.5rem;
	padding: 0.75rem 1rem;
	background: var(--wp--preset--color--white);
	color: var(--wp--preset--color--navy);
	font-weight: 700;
}
:where(a, button, input, select, textarea, summary):focus-visible {
	outline: 3px solid var(--wp--preset--color--green);
	outline-offset: 2px;
	border-radius: 2px;
}
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* Eyebrow labels */
.ihvn-eyebrow {
	font-size: 0.8125rem !important;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	margin-bottom: 0.5rem;
}

/* Header */
.ihvn-topbar p { margin: 0; }
.ihvn-topbar a { color: inherit; text-decoration: none; }
.ihvn-topbar a:hover { text-decoration: underline; }
.ihvn-header {
	position: sticky; top: 0; z-index: 50;
	border-bottom: 1px solid var(--wp--preset--color--border);
}
.ihvn-header .wp-block-site-logo img { height: auto; max-height: 64px; width: auto; }
.ihvn-header .wp-block-navigation a { color: var(--wp--preset--color--navy); }
.ihvn-header .wp-block-navigation a:hover { color: var(--wp--preset--color--blue); text-decoration: underline; text-underline-offset: 0.3em; }
.ihvn-header .wp-block-navigation__submenu-container {
	border: 1px solid var(--wp--preset--color--border) !important;
	border-radius: var(--ihvn-radius);
	box-shadow: var(--ihvn-shadow-hover);
	padding: 0.5rem 0 !important;
	min-width: 260px !important;
}
.ihvn-header .wp-block-navigation__submenu-container a {
	padding: 0.5rem 1.1rem !important;
	font-weight: 500;
}
@media (max-width: 781px) {
	.ihvn-topbar { display: none; }
	.ihvn-header-cta { display: none; }
	.ihvn-header .wp-block-site-logo img { max-height: 48px; }
}
@media (min-width: 600px) and (max-width: 1100px) {
	.ihvn-header .wp-block-navigation { gap: 1rem !important; font-size: 0.9375rem; }
}

/* Hero */
.ihvn-hero h1 { max-width: 18ch; }
.ihvn-hero .wp-block-cover__image-background { filter: saturate(0.9); }
.is-style-arrow .wp-block-button__link::after { content: " →"; }

/* Impact numbers */
.ihvn-stats__grid { gap: 2rem !important; }
.ihvn-stat__num {
	font-size: clamp(2.25rem, 5vw, 3.25rem);
	font-weight: 800;
	line-height: 1;
	letter-spacing: -0.02em;
	color: var(--wp--preset--color--green);
	margin: 0 0 0.5rem;
	font-variant-numeric: tabular-nums;
}
.ihvn-stat__label { margin: 0; opacity: 0.92; }
.ihvn-stats__note { opacity: 0.75; margin-top: 2rem !important; }

/* Cards */
.ihvn-card-grid { gap: 1.25rem !important; margin-top: var(--wp--preset--spacing--40) !important; }
.is-style-card {
	background: var(--wp--preset--color--white);
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--ihvn-radius);
	padding: 1.5rem 1.5rem 1.25rem;
	box-shadow: var(--ihvn-shadow);
	position: relative;
	transition: box-shadow 0.2s, transform 0.2s;
}
.is-style-card:hover { box-shadow: var(--ihvn-shadow-hover); transform: translateY(-2px); }
.is-style-card h3 { margin-top: 0; }
.is-style-card h3 a { color: var(--wp--preset--color--navy); text-decoration: none; }
/* Whole card is clickable via its heading link. */
.is-style-card h3 a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.is-style-card p:last-child { margin-bottom: 0; }
.ihvn-area { border-top: 4px solid var(--wp--preset--color--green); }
.ihvn-tag {
	display: inline-block;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--wp--preset--color--green-deep);
	background: #eef5df;
	padding: 0.2rem 0.6rem;
	border-radius: 99px;
	margin: 0 0 0.75rem;
}

/* News and archive cards */
.ihvn-news-card { display: flex; flex-direction: column; gap: 0.5rem; }
.ihvn-news-card .wp-block-post-featured-image { margin: 0 0 0.5rem; }
.ihvn-news-card .wp-block-post-featured-image img { border-radius: var(--ihvn-radius); object-fit: cover; }
.ihvn-news-card .wp-block-post-title { margin: 0; }
.ihvn-news-card .wp-block-post-title a:hover { text-decoration: underline; }
.ihvn-news-card .wp-block-post-excerpt { color: var(--wp--preset--color--muted); margin: 0; }
.ihvn-news-card .wp-block-post-excerpt__more-text { display: none; }
.ihvn-archive .wp-block-post-template { gap: 2.5rem 1.75rem !important; }
.wp-block-query-pagination { margin-top: var(--wp--preset--spacing--50); font-weight: 600; }

/* People */
.ihvn-person-card { text-align: center; }
.ihvn-person__photo img { border-radius: 50%; object-fit: cover; object-position: top; }
.ihvn-person-card .ihvn-person__photo { max-width: 180px; margin: 0 auto 1rem; }
.ihvn-person-card .wp-block-post-title { margin: 0; }
.ihvn-person__role { color: var(--wp--preset--color--muted); margin: 0.25rem 0 0; font-size: 0.9375rem; }
.ihvn-person__meta { color: var(--wp--preset--color--muted); margin: 0.25rem 0 0; }
.single-tm_team_member .ihvn-person__photo img { border-radius: var(--ihvn-radius); }
.single-tm_team_member .ihvn-person__role { font-size: 1.125rem; font-weight: 600; color: var(--wp--preset--color--blue); }

/* Inner page heading band */
.ihvn-page-head h1 { margin-top: 0.25rem; max-width: 24ch; }
.ihvn-crumb { margin: 0; color: var(--wp--preset--color--muted); }
.ihvn-crumb a { color: inherit; }

/* Partners as text chips */
.ihvn-partners {
	list-style: none;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0.75rem;
	margin: 1.25rem 0;
}
.ihvn-partners li {
	border: 1px solid var(--wp--preset--color--border);
	border-radius: 99px;
	padding: 0.5rem 1.1rem;
	font-weight: 600;
	color: var(--wp--preset--color--navy);
	background: var(--wp--preset--color--surface);
}

/* Media + text */
.ihvn-media-text .wp-block-media-text__media img { border-radius: var(--ihvn-radius); }
.ihvn-media-text .wp-block-media-text__content { padding: 0 var(--wp--preset--spacing--40) 0 0 !important; }
@media (max-width: 600px) {
	.ihvn-media-text .wp-block-media-text__content { padding: var(--wp--preset--spacing--30) 0 0 !important; }
}

/* Check list style */
.is-style-checks { list-style: none; padding-left: 0; }
.is-style-checks li { padding-left: 1.75rem; position: relative; margin-bottom: 0.4rem; }
.is-style-checks li::before {
	content: "";
	position: absolute; left: 0; top: 0.35em;
	width: 1.1rem; height: 1.1rem;
	border-radius: 50%;
	background: var(--wp--preset--color--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%230b1f40' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 70% no-repeat;
}

/* Footer */
.ihvn-footer h2 { margin-top: 0; }
.ihvn-footer-links { list-style: none; padding: 0; }
.ihvn-footer-links li { margin-bottom: 0.5rem; }
.ihvn-footer a { text-decoration: none; }
.ihvn-footer a:hover { text-decoration: underline; }

/* Legacy (WPBakery) content: keep it tidy and readable */
.wp-block-post-content img { max-width: 100%; height: auto; border-radius: 6px; }
.wp-block-post-content table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
.wp-block-post-content th, .wp-block-post-content td { border: 1px solid var(--wp--preset--color--border); padding: 0.6rem 0.75rem; text-align: left; vertical-align: top; }
.wp-block-post-content th { background: var(--wp--preset--color--surface); }
details.wp-block-details {
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--ihvn-radius);
	padding: 0.9rem 1.2rem;
	margin-bottom: 0.75rem;
}
details.wp-block-details summary { font-weight: 700; color: var(--wp--preset--color--navy); cursor: pointer; }
details.wp-block-details[open] summary { margin-bottom: 0.75rem; }

/* Forms (Contact Form 7, newsletter) */
.wp-block-post-content input:not([type="submit"]):not([type="checkbox"]):not([type="radio"]),
.wp-block-post-content select,
.wp-block-post-content textarea {
	width: 100%;
	padding: 0.7rem 0.85rem;
	border: 1px solid #9aa8bf;
	border-radius: 6px;
	font: inherit;
}
.wp-block-post-content input[type="submit"] {
	background: var(--wp--preset--color--navy);
	color: #fff;
	border: 0;
	border-radius: 6px;
	padding: 0.8rem 1.4rem;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
}

/* Legacy LabPeak boxes rendered by inc/legacy-shortcodes.php */
.ihvn-people-grid, .ihvn-post-cards {
	list-style: none;
	padding: 0;
	display: grid;
	gap: 2rem 1.5rem;
	margin: var(--wp--preset--spacing--40) 0;
}
.ihvn-people-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.ihvn-post-cards { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.ihvn-people-grid a { text-decoration: none; color: var(--wp--preset--color--navy); display: block; }
.ihvn-people-grid a:hover .ihvn-people-grid__name { text-decoration: underline; }
.ihvn-people-grid__photo {
	width: 100%; max-width: 180px; aspect-ratio: 1;
	object-fit: cover; object-position: top;
	border-radius: 50% !important;
	margin: 0 auto 0.75rem; display: block;
}
.ihvn-people-grid__name { display: block; font-weight: 700; font-size: 1.0625rem; }
.ihvn-people-grid .ihvn-person__role { display: block; }
.ihvn-post-cards img { width: 100%; aspect-ratio: 3/2; object-fit: cover; border-radius: var(--ihvn-radius); }
.ihvn-post-cards h3 { margin: 0.25rem 0 0; }
.ihvn-post-cards h3 a { color: var(--wp--preset--color--navy); text-decoration: none; }
.ihvn-post-cards h3 a:hover { text-decoration: underline; }
.ihvn-notice {
	background: var(--wp--preset--color--surface);
	border-left: 4px solid var(--wp--preset--color--green);
	padding: 1rem 1.25rem;
	border-radius: 6px;
}

/* Where we work: office cards */
.ihvn-offices { list-style: none; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.ihvn-offices li { border: 1px solid var(--wp--preset--color--border); border-top: 4px solid var(--wp--preset--color--green); border-radius: var(--ihvn-radius); padding: 1rem 1.25rem; }
.ihvn-offices strong { display: block; color: var(--wp--preset--color--navy); font-size: 1.0625rem; margin-bottom: 0.25rem; }
