/* Email Finder page: the tool + tool info (templates/email-finder.php). Uses tokens from base.css only. */

/* Hero */
.ef-hero {
	position: relative;
	display: grid;
	gap: clamp(32px, 5vw, 72px);
	align-items: center;
	padding: clamp(40px, 7vw, 104px) var(--pad-x) clamp(48px, 7vw, 96px);
	overflow: hidden;
	isolation: isolate;
}
.ef-hero::before {
	content: '';
	position: absolute; inset: 0; z-index: -1;
	background:
		radial-gradient(60% 70% at 85% 20%, rgba(72, 117, 255, .16) 0%, rgba(72, 117, 255, 0) 70%),
		radial-gradient(50% 60% at 0% 100%, rgba(72, 117, 255, .08) 0%, rgba(72, 117, 255, 0) 70%),
		linear-gradient(180deg, #F7F9FF 0%, #FFFFFF 100%);
}
@media (min-width: 1024px) {
	.ef-hero { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); }
}
.ef-hero__copy { display: grid; gap: var(--s-5); justify-items: start; min-width: 0; }
.ef-hero h1 { font-size: var(--fs-hero); line-height: 1.05; letter-spacing: -.03em; }
.ef-hero__accent {
	background: linear-gradient(90deg, #2D5BFF 0%, #6A8DFF 100%);
	-webkit-background-clip: text; background-clip: text; color: transparent;
}
.ef-hero__lead { font-size: clamp(1.05rem, 1rem + .45vw, 1.3rem); color: var(--muted); max-width: 52ch; }

.ef-trust { display: flex; flex-wrap: wrap; gap: var(--s-3) var(--s-5); font-size: var(--fs-sm); font-weight: 500; color: var(--ink); }
.ef-trust li { display: inline-flex; align-items: center; gap: 8px; }
.ef-trust .icon { width: 18px; height: 18px; color: var(--success); flex: none; }

/* Tool card */
.hf-tool { display: grid; gap: var(--s-5); box-shadow: var(--shadow-lg); padding: clamp(16px, 2.5vw, 32px); min-width: 0; scroll-margin-top: calc(var(--header-h, 72px) + 16px); }
.hf-notice { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.hf-notice svg { width: 20px; height: 20px; flex: none; }

.hf-tabs {
	display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px;
	padding: 4px; border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--border);
}
.hf-tabs[hidden] { display: none; }
.hf-tab {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 44px; padding: 8px 10px; border-radius: var(--r-sm);
	font-weight: 600; font-size: .9375rem; color: var(--muted); line-height: 1.2; text-align: center;
	transition: background-color .2s var(--ease), color .2s var(--ease), box-shadow .2s var(--ease);
}
.hf-tab svg { width: 18px; height: 18px; flex: none; }
.hf-tab:hover { color: var(--ink); }
.hf-tab[aria-selected="true"] { background: var(--bg); color: var(--brand-strong); box-shadow: var(--shadow-sm); }
@media (max-width: 480px) {
	.hf-tab { flex-direction: column; gap: 4px; font-size: .8125rem; padding: 8px 4px; }
}

.hf-panel { border-radius: var(--r-sm); }
.hf-panel:focus-visible { outline-offset: 6px; }
.hf-panel[hidden] { display: none; }
.hf-form { display: grid; gap: var(--s-4); min-width: 0; }

/* Single / Bulk toggle */
.hf-mode {
	display: inline-grid; grid-template-columns: 1fr 1fr; justify-self: start; gap: 2px;
	padding: 3px; border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--border);
}
.hf-mode[hidden] { display: none; }
.hf-mode__opt {
	min-height: 36px; min-width: 76px; padding: 6px 16px; border-radius: var(--r-pill);
	font-size: var(--fs-sm); font-weight: 600; color: var(--muted);
	transition: background-color .2s var(--ease), color .2s var(--ease);
}
.hf-mode__opt:hover { color: var(--ink); }
.hf-mode__opt[aria-checked="true"] { background: var(--brand-strong); color: #fff; }

.hf-form__fields { display: grid; gap: var(--s-4); grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); }
.hf-form__fields--3 { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 480px) {
	.hf-form__fields--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.hf-form__fields--3 .field:last-child { grid-column: 1 / -1; }
}
.hf-single[hidden], .hf-bulk[hidden] { display: none; }

.hf-bulk { display: grid; gap: var(--s-4); min-width: 0; }
.hf-bulk .field textarea { min-height: 112px; font-size: .9375rem; line-height: 1.5; }
.hf-bulk code { font-size: .8125rem; padding: 1px 6px; border-radius: 4px; background: var(--surface); border: 1px solid var(--border); color: var(--ink); overflow-wrap: anywhere; }
.hf-file input[type="file"] { min-height: 48px; padding: 8px; font-size: var(--fs-sm); cursor: pointer; max-width: 100%; }
.hf-file input[type="file"]::file-selector-button {
	margin-right: 12px; padding: 8px 14px; border: 1px solid var(--border); border-radius: var(--r-pill);
	background: var(--bg); color: var(--ink); font: inherit; font-weight: 600; cursor: pointer;
}
.hf-bulk__err:empty { display: none; }
.hf-bulk__count {
	display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: var(--r-md);
	background: var(--brand-soft); color: var(--ink); font-size: var(--fs-sm); font-weight: 600;
}
.hf-bulk__count svg { width: 18px; height: 18px; flex: none; color: var(--brand-strong); }

.hf-form__submit { width: 100%; }

.hf-tool__note { display: flex; align-items: flex-start; gap: 8px; font-size: var(--fs-sm); color: var(--muted); }
.hf-tool__note svg { width: 18px; height: 18px; flex: none; margin-top: 1px; color: var(--brand-strong); }
.hf-tool__note--locked {
	padding: 12px 16px; border-radius: var(--r-md); background: var(--brand-soft); color: var(--ink); font-weight: 500;
}

/* How it works */
.ef-steps { display: grid; gap: clamp(16px, 2vw, 24px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.ef-step { display: grid; gap: var(--s-3); align-content: start; }
.ef-step p { color: var(--text); }
.ef-step__top { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--s-2); }
.ef-step__num { font-size: 2rem; font-weight: 800; color: var(--muted); opacity: .35; letter-spacing: -.02em; line-height: 1; }

/* Methods (alternating rows) */
.ef-methods__list { display: grid; gap: clamp(48px, 7vw, 104px); }
.ef-method { display: grid; gap: clamp(24px, 4vw, 72px); align-items: center; }
.ef-method__copy { display: grid; gap: var(--s-4); justify-items: start; position: relative; max-width: 54ch; }
.ef-method__num { font-size: var(--fs-sm); font-weight: 700; letter-spacing: .08em; color: var(--brand-strong); }
.ef-method__copy p { color: var(--text); font-size: clamp(1rem, .96rem + .25vw, 1.15rem); }
.ef-method__media {
	border-radius: var(--r-xl); overflow: hidden; border: 1px solid var(--border);
	box-shadow: var(--shadow-md); background: var(--surface);
}
.ef-method__media img { width: 100%; height: auto; aspect-ratio: 551 / 310; object-fit: cover; }
@media (min-width: 1024px) {
	.ef-method { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); }
	.ef-method:nth-child(even) .ef-method__copy { order: 2; }
	.ef-method:nth-child(even) .ef-method__media { order: 1; }
	.ef-method:nth-child(odd) .ef-method__copy { justify-self: end; }
}
.ef-link {
	display: inline-flex; align-items: center; gap: 6px; min-height: 44px;
	font-weight: 600; text-decoration: none; color: var(--brand-strong);
}
.ef-link .icon { width: 18px; height: 18px; transition: transform .2s var(--ease); }
.ef-link:hover .icon { transform: translateX(3px); }
.ef-center { display: flex; justify-content: center; margin-top: clamp(32px, 4vw, 48px); }

/* What you get */
.ef-get { display: grid; gap: var(--s-3); align-content: start; }
.ef-get h3 { margin-top: var(--s-2); }

/* Sources (dark) */
.ef-sources { background: radial-gradient(80% 100% at 50% 0%, #1B2B6B 0%, var(--ink) 70%); }
.ef-source {
	display: grid; gap: var(--s-4); align-content: start;
	padding: clamp(20px, 2.5vw, 32px); border-radius: var(--r-lg);
	background: rgba(255, 255, 255, .04); border: 1px solid rgba(255, 255, 255, .1);
}
.ef-source .icon-tile { background: rgba(72, 117, 255, .16); color: color-mix(in srgb, var(--brand) 50%, var(--bg)); }
.ef-source p { color: rgba(255, 255, 255, .72); }

/* Use cases */
.ef-uses { gap: clamp(24px, 3vw, 40px); }
.ef-use { display: grid; gap: var(--s-3); align-content: start; padding-top: var(--s-5); border-top: 2px solid var(--border); }
.ef-use .icon-tile { margin-bottom: var(--s-2); }

/* Compare methods */
.ef-compare { display: grid; gap: clamp(16px, 2vw, 24px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); align-items: stretch; }
.ef-way { display: grid; gap: var(--s-3); align-content: start; }
.ef-way__how { color: var(--muted); }
.ef-way ul { display: grid; gap: var(--s-3); margin-top: var(--s-3); padding-top: var(--s-4); border-top: 1px solid var(--border); }
.ef-way li { display: flex; gap: 10px; align-items: flex-start; color: var(--ink); font-size: .9375rem; }
.ef-way li svg { width: 20px; height: 20px; flex: none; margin-top: 2px; }
.ef-way li.is-yes svg { color: var(--success); }
.ef-way li.is-no svg { color: var(--danger); }
.ef-way--best { border: 2px solid var(--brand-strong); box-shadow: var(--shadow-md); }
.ef-way--best .badge { justify-self: start; }

/* FAQ */
.ef-faq .faq details p { margin-top: 0; }


/* Find email: name + domain + optional LinkedIn link (4 fields) */
.hf-form__fields--4 { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 480px) {
	.hf-form__fields--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.hf-form__fields--4 .field:nth-child(3), .hf-form__fields .field--wide { grid-column: 1 / -1; }
}
.hf-form__fields--2 { grid-template-columns: minmax(0, 1fr); }

/* "Paid plans" note on Domain search and Verify tabs */
.hf-paid-note { display: flex; gap: var(--s-2); align-items: flex-start; margin-top: var(--s-3); font-size: var(--fs-sm); color: var(--muted); }
.hf-paid-note svg { width: 16px; height: 16px; flex: none; margin-top: 3px; color: var(--brand-strong); }
.hf-paid-note[hidden] { display: none; }

/* ---------- Members: live tool ---------- */
.hf-shared[hidden] { display: none; }
/* Domain search filters: job title + decision makers (seniority), side by side when there is room */
.hf-filters { display: grid; gap: var(--s-4); grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); }
.hf-cost {
	display: flex; align-items: flex-start; gap: 8px; padding: 10px 14px; border-radius: var(--r-md);
	background: var(--brand-soft); color: var(--ink); font-size: var(--fs-sm); font-weight: 600; line-height: 1.45;
}
.hf-cost svg { width: 18px; height: 18px; flex: none; margin-top: 1px; color: var(--brand-strong); }
.hf-form__error[hidden], .hf-confirm[hidden], .hf-alert[hidden], .hf-bulk__count[hidden] { display: none; }

/* Submit: loading state (button is disabled while a request runs) */
.hf-form__submit.is-loading { opacity: .8; }
.hf-form__submit.is-loading svg { display: none; }
.hf-form__submit.is-loading::before {
	content: ""; width: 18px; height: 18px; flex: none; border-radius: 50%;
	border: 2px solid rgba(255, 255, 255, .45); border-top-color: #fff; animation: hf-spin .8s linear infinite;
}
@keyframes hf-spin { to { transform: rotate(360deg); } }

/* Bulk confirm */
.hf-confirm {
	display: grid; gap: var(--s-3); padding: var(--s-4); border-radius: var(--r-md);
	border: 1px solid var(--border); border-left: 4px solid var(--warning); background: var(--bg);
	font-size: var(--fs-sm); color: var(--ink);
}
.hf-confirm__actions { display: flex; flex-wrap: wrap; gap: var(--s-2); }

/* Inline alert in the tool card (same text as the toast, plus a link or button) */
.hf-alert {
	display: flex; align-items: flex-start; gap: var(--s-3); padding: 12px 16px; border-radius: var(--r-md);
	background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--brand-strong);
	color: var(--ink); font-size: var(--fs-sm);
}
.hf-alert__icon { width: 20px; height: 20px; flex: none; margin-top: 1px; color: var(--brand-strong); }
.hf-alert__body { display: grid; gap: 8px; justify-items: start; min-width: 0; }
.hf-alert__link { font-weight: 600; color: var(--brand-strong); }
.hf-alert__btn { min-height: 40px; padding: 8px 16px; font-size: var(--fs-sm); }
.hf-alert--error { border-left-color: var(--danger); }
.hf-alert--error .hf-alert__icon { color: var(--danger); }
.hf-alert--warning { border-left-color: var(--warning); }
.hf-alert--warning .hf-alert__icon { color: var(--warning); }
.hf-alert--success { border-left-color: var(--success); }
.hf-alert--success .hf-alert__icon { color: var(--success); }

.hf-tool__note--confirm {
	flex-wrap: wrap; align-items: center; padding: 12px 16px; border-radius: var(--r-md);
	background: var(--brand-soft); color: var(--ink); font-weight: 500;
}
.hf-tool__note--confirm span { flex: 1 1 200px; }
.hf-tool__note--confirm .btn { min-height: 40px; padding: 8px 16px; font-size: var(--fs-sm); }
.hf-tool__note--confirm svg { margin-top: 0; }

/* ---------- Results panel (full width, under the hero) ---------- */
.hf-results {
	display: grid; gap: var(--s-4); padding: clamp(24px, 4vw, 48px) var(--pad-x);
	background: var(--surface); border-top: 1px solid var(--border); scroll-margin-top: calc(var(--header-h) + 8px);
}
.hf-results[hidden] { display: none; }
.hf-results__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: var(--s-4); }
.hf-results__titles { display: grid; gap: 4px; min-width: 0; }
.hf-results h2 { font-size: var(--fs-h3); }
.hf-results h2:focus { outline: none; }
.hf-results h2:focus-visible { outline: 3px solid var(--brand); outline-offset: 4px; border-radius: 4px; }
.hf-results__summary { font-size: var(--fs-sm); color: var(--text); font-weight: 500; }
.hf-results__actions { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.hf-icon-down { transform: rotate(90deg); }

.hf-progress { display: grid; gap: 6px; }
.hf-progress[hidden] { display: none; }
.hf-progress__bar { width: 100%; height: 8px; border: 0; border-radius: var(--r-pill); overflow: hidden; background: var(--border); appearance: none; }
.hf-progress__bar::-webkit-progress-bar { background: var(--border); border-radius: var(--r-pill); }
.hf-progress__bar::-webkit-progress-value { background: var(--brand-strong); border-radius: var(--r-pill); }
.hf-progress__bar::-moz-progress-bar { background: var(--brand-strong); }
.hf-progress__text { font-size: var(--fs-sm); color: var(--muted); }

/* Two-table pattern: header table + body table sharing one colgroup.
   The body scroll wrap has a rounded top; the dark container shows through its corners. */
.hf-table {
	--hf-min: 640px;
	border-radius: var(--r-lg); background: var(--ink); overflow: hidden;
	border: 1px solid var(--ink); box-shadow: var(--shadow-sm);
}
.hf-table__head { overflow: hidden; padding-right: var(--hf-sbw, 0px); }
.hf-table__t { width: 100%; min-width: var(--hf-min); table-layout: fixed; border-collapse: collapse; }
.hf-table__head th {
	padding: 12px 16px; text-align: left; font-size: .8125rem; font-weight: 600; letter-spacing: .02em;
	color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hf-table__wrap {
	max-height: min(70vh, 720px); overflow: auto;
	background: var(--bg); border-radius: var(--r-md) var(--r-md) 0 0;
}
.hf-table__wrap:focus-visible { outline: 3px solid var(--brand); outline-offset: -3px; }
/* Real header for screen readers, zero height on screen */
.hf-table__srhead th { height: 0; padding: 0; border: 0; overflow: hidden; font-size: 0; line-height: 0; }
.hf-table__body td {
	padding: 12px 16px; vertical-align: top; border-top: 1px solid var(--border);
	font-size: .9375rem; color: var(--ink); overflow-wrap: anywhere;
}
.hf-table__body tbody tr:first-child td { border-top: 0; }
.hf-table__body tbody tr:hover td { background: var(--surface); }
.hf-input { color: var(--text); }
.hf-empty { color: var(--muted); font-size: var(--fs-sm); }
.hf-note, .hf-sub { display: block; color: var(--muted); font-size: var(--fs-sm); }

.hf-email { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.hf-email__value { font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.hf-copy {
	display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 4px 10px;
	border: 1px solid var(--border); border-radius: var(--r-pill); background: var(--bg);
	font-size: .8125rem; font-weight: 600; color: var(--ink); cursor: pointer;
	transition: border-color .2s var(--ease), color .2s var(--ease);
}
.hf-copy svg { width: 14px; height: 14px; flex: none; }
.hf-copy:hover { border-color: var(--brand-strong); color: var(--brand-strong); }
.hf-copy:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
.hf-copy.is-done { border-color: var(--success); color: #067647; }
@media (pointer: coarse) { .hf-copy { min-height: 40px; padding: 6px 14px; } }

/* LinkedIn profile link: icon button in the table column, icon + text under a single Find result */
.hf-table--wide { --hf-min: 760px; }
.hf-li {
	display: inline-flex; align-items: center; justify-content: center; gap: 6px;
	min-width: 32px; min-height: 32px; padding: 4px; border: 1px solid var(--border); border-radius: var(--r-pill);
	background: var(--bg); color: var(--brand-strong); font-size: .8125rem; font-weight: 600; text-decoration: none;
	transition: border-color .2s var(--ease), color .2s var(--ease);
}
.hf-li svg { width: 16px; height: 16px; flex: none; }
.hf-li:hover { border-color: var(--brand-strong); }
.hf-li:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
.hf-li--text { margin-top: 6px; padding: 4px 12px 4px 10px; }
@media (pointer: coarse) { .hf-li { min-width: 40px; min-height: 40px; } }

.hf-score { display: grid; gap: 4px; max-width: 72px; }
.hf-score__num { font-weight: 600; font-variant-numeric: tabular-nums; }
.hf-score__bar { height: 4px; border-radius: var(--r-pill); background: var(--border); overflow: hidden; }
.hf-score__fill { display: block; height: 100%; background: var(--brand-strong); }

/* Status chip: icon + text, never colour alone */
.hf-chip {
	display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: var(--r-pill);
	font-size: .8125rem; font-weight: 600; line-height: 1.3; white-space: nowrap; border: 1px solid transparent;
}
.hf-chip svg { width: 14px; height: 14px; flex: none; }
.hf-chip--valid { background: #ECFDF3; color: #067647; border-color: #ABEFC6; }
.hf-chip--risky { background: #FFFAEB; color: #B54708; border-color: #FEDF89; }
.hf-chip--invalid { background: #FEF3F2; color: #B42318; border-color: #FECDCA; }
.hf-chip--unknown, .hf-chip--none, .hf-chip--skipped { background: var(--surface); color: var(--muted); border-color: var(--border); }

/* Mobile: stacked cards */
@media (max-width: 767px) {
	.hf-table { background: transparent; border: 0; box-shadow: none; overflow: visible; border-radius: 0; }
	.hf-table__head { display: none; }
	.hf-table__wrap { max-height: none; overflow: visible; background: transparent; border-radius: 0; }
	.hf-table__t { min-width: 0; }
	.hf-table__body, .hf-table__body tbody, .hf-table__body tr, .hf-table__body td { display: block; width: 100%; }
	.hf-table__body colgroup, .hf-table__srhead { display: none; }
	.hf-table__body tbody { display: grid; gap: var(--s-3); }
	.hf-table__body tr {
		padding: var(--s-4); border: 1px solid var(--border); border-radius: var(--r-lg);
		background: var(--bg); box-shadow: var(--shadow-sm);
	}
	.hf-table__body tbody tr:hover td { background: transparent; }
	.hf-table__body td {
		display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: var(--s-3); align-items: start;
		padding: 8px 0; border-top: 1px solid var(--border);
	}
	.hf-table__body tr td:first-child { border-top: 0; padding-top: 0; }
	.hf-table__body tr td:last-child { padding-bottom: 0; }
	.hf-table__body td.hf-cell--linkedin.is-empty { display: none; }
	.hf-table__body td::before {
		content: attr(data-label); font-size: .75rem; font-weight: 600; letter-spacing: .04em;
		text-transform: uppercase; color: var(--muted); padding-top: 3px;
	}
	.hf-results__actions { width: 100%; }
	.hf-results__actions .btn { flex: 1 1 auto; }
}
