/* ==========================================================================
   components/comparison-table.css — "Us vs. Them" Comparison Table
   Shared across pages. Desktop/tablet: real 3-column table. Mobile: the
   table collapses into a scroll-animated vertical timeline.
   Depends on: lp-base.css (.lp-container, .lp-eyebrow, .lp-section-title,
   .lp-fade-up, .lp-btn) — enqueue nextwave-lp-base alongside this file.
   ========================================================================== */

.cmp-table {
	background: #f8fafc;
	padding-block: 80px;
}

.cmp-table__header {
	text-align: center;
	margin-bottom: 52px;
}

.cmp-table__subtitle {
	font-size: 1rem;
	color: #6b7280;
	line-height: 1.7;
	max-width: 520px;
	margin-inline: auto;
}

/* Table wrapper */
.cmp-table__inner {
	background: #fff;
	border-radius: 16px;
	border: 1px solid #e5e7eb;
	overflow: hidden;
	box-shadow: 0 4px 24px rgba(0, 0, 0, .06);
}

/* Header row */
.cmp-table__thead {
	display: grid;
	grid-template-columns: 1fr 1.1fr 1.1fr;
}

.cmp-table__thead-cell {
	padding: 20px 24px;
	font-size: .9375rem;
	font-weight: 700;
	color: #fff;
}

.cmp-table__thead-cell--feature {
	background: #fff;
	color: transparent;
}

.cmp-table__thead-cell--nw {
	background: var(--nw-cyan);
	color: var(--nw-navy);
	text-align: center;
}

.cmp-table__thead-cell--typical {
	background: var(--nw-navy);
	text-align: center;
}

/* Data rows */
.cmp-table__row {
	display: grid;
	grid-template-columns: 1fr 1.1fr 1.1fr;
	border-top: 1px solid #e5e7eb;
	transition: background .18s ease;
}

.cmp-table__row:hover { background: #f8fafc; }

.cmp-table__cell {
	padding: 18px 24px;
	display: flex;
	align-items: flex-start;
	gap: 12px;
}

/* Feature cell */
.cmp-table__cell--feature {
	align-items: center;
}

.cmp-table__feat-icon {
	width: 34px;
	height: 34px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.cmp-table__feat-icon svg {
	width: 34px;
	height: 34px;
	stroke: var(--nw-cyan-text);
	fill: none;
}

.cmp-table__feat-label {
	font-size: .875rem;
	font-weight: 700;
	color: #0f172a;
	line-height: 1.35;
}

/* NW cell */
.cmp-table__cell--nw {
	border-left: 1px solid #e5e7eb;
}

.cmp-table__check {
	width: 22px;
	height: 22px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	margin-top: 1px;
}

.cmp-table__check svg {
	width: 22px;
	height: 22px;
	stroke: #16a34a;
	fill: none;
}

.cmp-table__cross {
	width: 22px;
	height: 22px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	margin-top: 1px;
}

.cmp-table__cross svg {
	width: 22px;
	height: 22px;
	stroke: #dc2626;
	fill: none;
}

/* Typical cell */
.cmp-table__cell--typical {
	border-left: 1px solid #e5e7eb;
}

.cmp-table__cell-text {
	font-size: .875rem;
	color: #374151;
	line-height: 1.55;
}

/* Bottom CTA bar */
.cmp-table__cta-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	padding: 22px 28px;
	margin-top: 28px;
	flex-wrap: wrap;
}

.cmp-table__cta-left {
	display: flex;
	align-items: center;
	gap: 16px;
}

.cmp-table__cta-icon {
	width: 52px;
	height: 52px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.cmp-table__cta-icon svg {
	width: 52px;
	height: 52px;
	color: var(--nw-cyan-text);
	fill: currentColor;
	stroke: none;
}

.cmp-table__cta-text strong {
	display: block;
	font-size: .9375rem;
	font-weight: 700;
	color: #0f172a;
	margin-bottom: 2px;
}

.cmp-table__cta-text span {
	font-size: .8125rem;
	color: #6b7280;
}

.cmp-table__cta-btn {
	background: #0f172a;
	border-color: #0f172a;
	color: #fff !important;
}

.cmp-table__cta-btn .lp-btn__icon {
	background: var(--nw-cyan);
	border: none;
	color: var(--nw-navy);
}

.cmp-table__cta-btn:hover {
	background: #1e293b;
	border-color: #1e293b;
	transform: translateY(-2px);
}

/* ── Responsive — tablet ─────────────────────────────────────────────────── */
@media (max-width: 1024px) {
	.cmp-table__thead,
	.cmp-table__row {
		grid-template-columns: 1.2fr 1fr 1fr;
	}
}

/* ── Responsive — mobile: table becomes a vertical timeline ─────────────── */
@media (max-width: 640px) {
	.cmp-table {
		padding-block: 32px;
	}

	.cmp-table__thead { display: none; }

	.cmp-table__inner {
		background: transparent;
		border: none;
		border-radius: 0;
		box-shadow: none;
		overflow: visible;
	}

	/* Timeline layout — feature icon becomes the dot marker on a connecting line */
	.cmp-table__tbody {
		margin-left: 20px;
	}

	.cmp-table__row.lp-fade-up {
		display: block;
		grid-template-columns: none;
		position: relative;
		padding: 0 0 32px 40px;
		border-top: none;
		opacity: 1;
		transform: none;
		transition: none;
	}

	.cmp-table__row:last-child { padding-bottom: 0; }

	.cmp-table__row:after {
		content: "";
		position: absolute;
		top: 26px;
		left: 0;
		width: 2px;
		height: 100%;
		background: var(--nw-navy);
		transform: translateX(-50%);
	}

	.cmp-table__row:last-child:after { display: none; }

	.cmp-table__cell {
		border-left: none !important;
		border-top: none;
		padding: 0;
		display: block;
	}

	.cmp-table__cell:first-child { border-top: none; }

	.cmp-table__cell--feature {
		margin-bottom: 10px;
	}

	.cmp-table__feat-icon {
		position: absolute;
		top: 0;
		left: 0;
		width: 34px;
		height: 34px;
		background: var(--nw-navy);
		border-radius: 50%;
		z-index: 1;
		transform: translateX(-50%) scale(0);
		transition: transform .35s cubic-bezier(.65,0,.35,1);
	}

	.cmp-table__feat-icon svg {
		width: 18px;
		height: 18px;
		stroke: var(--nw-cyan);
	}

	.cmp-table__feat-label,
	.cmp-table__cell--nw,
	.cmp-table__cell--typical {
		opacity: 0;
		transform: translateX(-12px);
		transition: opacity .35s cubic-bezier(.65,0,.35,1), transform .35s cubic-bezier(.65,0,.35,1);
	}

	.cmp-table__cell--nw,
	.cmp-table__cell--typical {
		display: flex;
		align-items: flex-start;
		gap: 10px;
		margin-bottom: 8px;
	}

	.cmp-table__cell--typical { margin-bottom: 0; }

	.cmp-table__row--in .cmp-table__feat-icon {
		transform: translateX(-50%) scale(1);
	}

	.cmp-table__row--in .cmp-table__feat-label,
	.cmp-table__row--in .cmp-table__cell--nw,
	.cmp-table__row--in .cmp-table__cell--typical {
		opacity: 1;
		transform: translateX(0);
	}

	.cmp-table__cta-bar {
		flex-direction: column;
		align-items: flex-start;
	}
}
