/* =============================================================
   Biomarks – How It Works Widget  |  widget.css
   Matches the "From upload to insight in four steps" design.
   All rules are scoped to .bhiw-* to avoid theme conflicts.
   ============================================================= */

/* ── Google Fonts (same as the site) ─────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Instrument+Serif:ital@0;1&display=swap');

/* ── Section wrapper ─────────────────────────────────────── */
.bhiw-section {
	background-color: #f1f4fa;
	padding: 80px 60px;
	box-sizing: border-box;
}

/* ── Header ──────────────────────────────────────────────── */
.bhiw-header {
	margin-bottom: 52px;
}

.bhiw-eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: #44CECF;
	margin: 0 0 14px;
}

.bhiw-eyebrow::before {
	content: '';
	display: inline-block;
	width: 22px;
	height: 2px;
	background-color: #44CECF;
	border-radius: 1px;
	flex-shrink: 0;
}

.bhiw-heading {
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: clamp(34px, 4.5vw, 58px);
	font-weight: 800;
	letter-spacing: -2px;
	line-height: 1.03;
	color: #1a2e2c;
	margin: 0;
}

.bhiw-heading em {
	font-family: 'Instrument Serif', serif;
	font-style: italic;
	font-weight: 400;
	color: #44CECF;
	letter-spacing: -1px;
}

/* ── Grid ────────────────────────────────────────────────── */
.bhiw-grid {
	display: grid;
	grid-template-columns: repeat(var(--bhiw-cols, 4), 1fr);
	gap: 2px;
	border-radius: 18px;
	overflow: visible; /* let arrows pop out */
	position: relative;
}

/* ── Individual step wrapper (holds card + arrow) ──────── */
.bhiw-step-wrap {
	position: relative;
	display: flex;
	align-items: stretch;
}

/* ── Card ────────────────────────────────────────────────── */
.bhiw-card {
	background-color: #ffffff;
	border: 1.5px solid #e8efee;
	padding: 36px 28px;
	flex: 1;
	display: flex;
	flex-direction: column;
	transition: background-color 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
	text-decoration: none;
	color: inherit;
}

/* Round outer corners only */
.bhiw-step-wrap:first-child .bhiw-card { border-radius: 18px 0 0 18px; }
.bhiw-step-wrap:last-child  .bhiw-card { border-radius: 0 18px 18px 0; }

.bhiw-card:hover {
	background-color: #f8fffe;
	border-color: #44CECF;
	box-shadow: 0 12px 40px rgba(26, 158, 143, 0.1);
	z-index: 1;
}

.bhiw-card--linked { cursor: pointer; }

/* ── Step number ─────────────────────────────────────────── */
.bhiw-step-num {
	font-family: 'Instrument Serif', serif;
	font-style: italic;
	font-size: 52px;
	font-weight: 400;
	color: #cceeeb;
	line-height: 1;
	margin-bottom: 14px;
	display: block;
}

/* ── Icon box ────────────────────────────────────────────── */
.bhiw-icon-box {
	width: 52px;
	height: 52px;
	border-radius: 13px;
	background-color: #e6f7f5;
	border: 1.5px solid #cceeeb;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 24px;
	margin-bottom: 20px;
	flex-shrink: 0;
	line-height: 1;
}

.bhiw-icon-box svg {
	width: 24px;
	height: 24px;
}

/* ── Step title ──────────────────────────────────────────── */
.bhiw-step-title {
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-size: 17px;
	font-weight: 700;
	letter-spacing: -0.3px;
	color: #1a2e2c;
	margin: 0 0 10px;
	line-height: 1.3;
}

/* ── Step description ────────────────────────────────────── */
.bhiw-step-desc {
	font-size: 13.5px;
	font-weight: 400;
	line-height: 1.68;
	color: #6b8d8a;
	margin: 0;
}

/* ── Connector arrow ─────────────────────────────────────── */
.bhiw-arrow {
	position: absolute;
	right: -15px;
	top: 50%;
	transform: translateY(-50%);
	z-index: 2;
	pointer-events: none;
}

.bhiw-arrow-circle {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 30px;
	height: 30px;
	border-radius: 50%;
	background-color: #ffffff;
	border: 1.5px solid #cceeeb;
	font-size: 14px;
	color: #44CECF;
	line-height: 1;
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 1024px) {
	.bhiw-section {
		padding: 60px 32px;
	}
	.bhiw-grid {
		grid-template-columns: repeat(2, 1fr) !important;
	}
	.bhiw-step-wrap:nth-child(1) .bhiw-card { border-radius: 18px 0 0 0; }
	.bhiw-step-wrap:nth-child(2) .bhiw-card { border-radius: 0 18px 0 0; }
	.bhiw-step-wrap:nth-last-child(1) .bhiw-card { border-radius: 0 0 18px 0; }
	.bhiw-step-wrap:nth-last-child(2) .bhiw-card { border-radius: 0 0 0 18px; }
	/* Hide horizontal arrows on 2-col; add bottom ones via gap */
	.bhiw-arrow { display: none; }
}

@media (max-width: 600px) {
	.bhiw-section {
		padding: 48px 20px;
	}
	.bhiw-grid {
		grid-template-columns: 1fr !important;
		border-radius: 14px;
	}
	.bhiw-step-wrap .bhiw-card  { border-radius: 0 !important; }
	.bhiw-step-wrap:first-child .bhiw-card { border-radius: 14px 14px 0 0 !important; }
	.bhiw-step-wrap:last-child  .bhiw-card { border-radius: 0 0 14px 14px !important; }
	.bhiw-heading { letter-spacing: -1.5px; }
	.bhiw-arrow { display: none; }
}
