/* ============================================================
   Help Center (single FAQ) styles — standalone, no Tailwind JIT
   Reuses theme's naviti-* CSS variables when available.
   ============================================================ */

:root {
	--help-max-width: 1200px;
	--help-card-radius: 14px;
	--help-border: 1px solid var(--nvi-color-naviti-stroke-weakest, #e6e8ed);
	--help-text: var(--nvi-color-naviti-primary, #1f2937);
	--help-muted: var(--nvi-color-naviti-weaker, #6b7280);
	--help-strong: var(--nvi-color-naviti-strong, #0d1321);
	--help-brand: var(--nvi-color-naviti-brand-strong, #1552e3);
	--help-bg-soft: #f5f6f8;
	--help-bg-accent: #eff5ff;
}

/* ---------- Hero ---------- */
.help-hero {
	background: linear-gradient(180deg, #fbfcff 0%, #ffffff 100%);
	padding: 56px 16px 48px;
	border-bottom: 1px solid #e6e8ed;
}
.help-hero__inner {
	max-width: 860px;
	margin: 0 auto;
}
.help-hero__eyebrow {
	display: inline-block;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--help-brand);
	margin: 0 0 12px;
}
.help-hero__title {
	font-size: clamp(1.75rem, 3.5vw, 2.375rem);
	font-weight: 700;
	color: var(--help-strong);
	margin: 0 0 16px;
	line-height: 1.2;
}
.help-hero__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
	font-size: 0.875rem;
	color: var(--help-muted);
}
.help-hero__meta span {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

/* ---------- 2-column layout ---------- */
.help-layout {
	max-width: var(--help-max-width);
	margin: 0 auto;
	padding: 48px 16px 32px;
	display: grid;
	grid-template-columns: 1fr;
	gap: 40px;
}
@media (min-width: 1024px) {
	.help-layout {
		grid-template-columns: 260px 1fr;
		gap: 56px;
	}
}

/* ---------- Sidebar ---------- */
.help-sidebar { display: none; }
@media (min-width: 1024px) { .help-sidebar { display: block; } }
.help-sidebar__sticky {
	position: sticky;
	top: 32px;
	display: flex;
	flex-direction: column;
	gap: 32px;
}
.help-sidebar__section-title {
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--help-muted);
	margin: 0 0 12px;
}

/* TOC */
.help-toc__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
	font-size: 0.875rem;
	border-left: 2px solid var(--nvi-color-naviti-stroke-weakest, #e6e8ed);
}
.help-toc__list li { padding-left: 12px; position: relative; }
.help-toc__list a {
	display: block;
	color: var(--help-muted);
	text-decoration: none;
	line-height: 1.45;
	transition: color 0.15s;
}
.help-toc__list a:hover,
.help-toc__list a.is-active {
	color: var(--help-brand);
	font-weight: 500;
}
.help-toc__list li.is-h3 { padding-left: 24px; font-size: 0.8125rem; }

/* Category nav (other FAQs of same category) */
.help-nav__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 8px;
	font-size: 0.875rem;
}
.help-nav__list a {
	display: block;
	color: var(--help-muted);
	text-decoration: none;
	padding: 4px 0;
	line-height: 1.4;
}
.help-nav__list a:hover { color: var(--help-brand); }
.help-nav__list a.is-current {
	color: var(--help-strong);
	font-weight: 600;
}

/* ============================================================
   Article content (.help-article) — pro typography + rhythm.
   Defensive !important overrides are targeted at Gutenberg's
   inline styles (margin-top:var(--wp--preset--spacing--*)) which
   otherwise break the vertical rhythm of this layout.
   ============================================================ */

.help-article {
	color: var(--help-text);
	line-height: 1.75;
	font-size: 1.0625rem;
	font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
	-webkit-font-smoothing: antialiased;
}
.help-article > *:not(.help-feedback) { max-width: 780px; }

/* Headings ---------------------------------------------------- */
.help-article h2 {
	font-size: 1.625rem !important;
	font-weight: 700 !important;
	color: var(--help-strong) !important;
	line-height: 1.25 !important;
	margin: 56px 0 20px !important;
	padding: 4px 0 4px 18px !important;
	border-left: 4px solid var(--help-brand);
	border-bottom: 0 !important;
	scroll-margin-top: 32px;
	letter-spacing: -0.01em;
}
.help-article h2:first-child { margin-top: 0 !important; }

/* Heading icon (emoji → SVG swap) */
.help-heading-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	margin-right: 10px;
	vertical-align: -6px;
	color: var(--help-brand);
	flex-shrink: 0;
}
.help-heading-icon svg {
	width: 22px;
	height: 22px;
}
.help-article h3 .help-heading-icon {
	width: 22px;
	height: 22px;
	vertical-align: -5px;
	margin-right: 8px;
}
.help-article h3 .help-heading-icon svg {
	width: 18px;
	height: 18px;
}

.help-article h3 {
	font-size: 1.1875rem !important;
	font-weight: 600 !important;
	color: var(--help-strong) !important;
	margin: 36px 0 14px !important;
	scroll-margin-top: 32px;
	line-height: 1.4;
}

/* Lead paragraph (first paragraph of the article) ------------- */
.help-article > p:first-of-type {
	font-size: 1.1875rem;
	line-height: 1.65;
	color: var(--help-strong);
	font-weight: 400;
	margin-bottom: 28px;
}

/* Paragraphs -------------------------------------------------- */
.help-article p {
	margin: 0 0 18px !important;
}

/* Unordered lists --------------------------------------------- */
.help-article ul,
.help-article ul.wp-block-list {
	list-style: none !important;
	padding: 0 !important;
	margin: 12px 0 24px !important;
}
.help-article ul li {
	position: relative;
	padding: 2px 0 2px 28px !important;
	margin-bottom: 8px !important;
	line-height: 1.6;
	list-style: none !important;
}
.help-article ul li::before {
	content: "";
	position: absolute;
	left: 8px;
	top: 14px;
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--help-brand);
}
.help-article ul ul,
.help-article ul ul.wp-block-list {
	margin: 8px 0 8px !important;
}
.help-article ul ul li::before {
	background: var(--help-muted);
	width: 5px;
	height: 5px;
}

/* Ordered lists → stepper ------------------------------------ */
.help-article ol,
.help-article ol.wp-block-list {
	list-style: none !important;
	counter-reset: help-step;
	padding: 0 !important;
	margin: 20px 0 28px !important;
	display: flex;
	flex-direction: column;
	gap: 18px;
}
.help-article ol > li {
	counter-increment: help-step;
	position: relative;
	padding: 4px 0 4px 48px !important;
	min-height: 32px;
	line-height: 1.6;
	list-style: none !important;
}
.help-article ol > li::marker { content: none !important; }
.help-article ol > li::before {
	content: counter(help-step);
	position: absolute;
	left: 0;
	top: 0;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	background: var(--help-brand);
	color: #fff;
	font-weight: 600;
	font-size: 0.9375rem;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}
/* Nested UL inside an OL step — keep blue dots, just tighter */
.help-article ol ul { margin: 8px 0 4px !important; }

/* Inline text ------------------------------------------------- */
.help-article a {
	color: var(--help-brand);
	text-decoration: underline;
	text-underline-offset: 3px;
	text-decoration-thickness: 1px;
	text-decoration-color: rgba(21, 82, 227, 0.35);
	transition: text-decoration-color 0.15s;
}
.help-article a:hover { text-decoration-color: var(--help-brand); }
.help-article strong {
	color: var(--help-strong);
	font-weight: 600;
	background: linear-gradient(transparent 60%, rgba(21, 82, 227, 0.10) 60%);
	padding: 0 2px;
}
.help-article em { color: var(--help-strong); }

/* Separators (hide — headings already give enough rhythm) ---- */
.help-article hr,
.help-article .naviti-separator,
.help-article .wp-block-separator {
	display: none !important;
}

/* Blockquote → callout --------------------------------------- */
.help-article blockquote,
.help-article .wp-block-quote {
	margin: 28px 0 !important;
	padding: 20px 24px !important;
	border-left: 4px solid var(--help-brand);
	background: var(--help-bg-accent);
	color: var(--help-strong);
	border-radius: 0 10px 10px 0;
	font-style: normal !important;
}
.help-article blockquote p:last-child { margin-bottom: 0 !important; }

/* Code -------------------------------------------------------- */
.help-article code {
	background: #0d1321;
	color: #e6e8ed;
	padding: 2px 6px;
	border-radius: 5px;
	font-size: 0.9em;
	font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}
.help-article pre {
	background: #0d1321;
	color: #e6e8ed;
	padding: 18px 20px;
	border-radius: 10px;
	overflow-x: auto;
	line-height: 1.55;
	font-size: 0.9375rem;
	margin: 20px 0;
}
.help-article pre code {
	background: transparent;
	padding: 0;
	border-radius: 0;
}

/* Tables ------------------------------------------------------ */
.help-article table {
	width: 100%;
	border-collapse: collapse;
	margin: 24px 0;
	font-size: 0.9375rem;
}
.help-article th,
.help-article td {
	padding: 12px 16px;
	text-align: left;
	border-bottom: var(--help-border);
}
.help-article th {
	font-weight: 600;
	color: var(--help-strong);
	background: var(--help-bg-soft);
	border-bottom: 2px solid var(--help-brand);
}

/* Images ------------------------------------------------------ */
.help-article img,
.help-article .wp-block-image img {
	max-width: 100%;
	height: auto;
	border-radius: 10px;
	box-shadow: 0 2px 16px rgba(13, 19, 33, 0.08);
	margin: 16px 0;
}
.help-article figure { margin: 24px 0; }
.help-article figcaption {
	font-size: 0.875rem;
	color: var(--help-muted);
	text-align: center;
	margin-top: 10px;
}

/* ---------- Feedback / was-this-helpful block ---------- */
.help-feedback {
	max-width: 780px;
	margin-top: 48px;
	padding: 24px 28px;
	background: var(--help-bg-soft);
	border-radius: 12px;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}
.help-feedback__q {
	font-size: 0.9375rem;
	font-weight: 600;
	color: var(--help-strong);
	margin: 0;
}
.help-feedback__actions { display: flex; gap: 8px; }
.help-feedback__btn {
	padding: 8px 16px;
	border: var(--help-border);
	border-radius: 8px;
	background: #fff;
	font-size: 0.875rem;
	font-weight: 500;
	color: var(--help-strong);
	cursor: pointer;
	font-family: inherit;
	transition: all 0.15s;
}
.help-feedback__btn:hover {
	border-color: var(--help-brand);
	color: var(--help-brand);
}

/* ---------- Hero back-link + subtitle (category archive) ---------- */
.help-hero__back {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-size: 0.875rem;
	font-weight: 500;
	color: var(--help-brand);
	text-decoration: none;
	margin-bottom: 16px;
}
.help-hero__back:hover { text-decoration: underline; }
.help-hero__subtitle {
	font-size: 1.0625rem;
	color: var(--help-muted);
	margin: 8px 0 0;
	line-height: 1.55;
}

/* ---------- Category archive listing ---------- */
.help-cat-archive {
	max-width: 860px;
	margin: 0 auto;
	padding: 48px 16px 80px;
}
.help-cat-archive__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 0;
	border: var(--help-border);
	border-radius: var(--help-card-radius);
	overflow: hidden;
	background: #fff;
}
.help-cat-archive__item + .help-cat-archive__item {
	border-top: var(--help-border);
}
.help-cat-archive__link {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 18px 24px;
	text-decoration: none;
	color: var(--help-strong);
	font-size: 1rem;
	font-weight: 500;
	transition: background 0.15s, color 0.15s;
}
.help-cat-archive__link:hover {
	background: var(--help-bg-accent);
	color: var(--help-brand);
}
.help-cat-archive__link svg {
	flex-shrink: 0;
	color: var(--help-muted);
	transition: color 0.15s, transform 0.15s;
}
.help-cat-archive__link:hover svg {
	color: var(--help-brand);
	transform: translateX(3px);
}

/* ---------- Category archive — card container (no hover lift) ---------- */
.hcat-card { cursor: default; }
.hcat-card:hover {
	transform: none;
	box-shadow: 0 1px 2px rgba(13, 19, 33, 0.04);
	border-color: #e6e8ed;
}

/* ---------- Related: next / previous FAQ ---------- */
.help-related {
	max-width: var(--help-max-width);
	margin: 24px auto 0;
	padding: 24px 16px 64px;
	display: grid;
	grid-template-columns: 1fr;
	gap: 16px;
}
@media (min-width: 768px) {
	.help-related { grid-template-columns: 1fr 1fr; }
}
.help-related__link {
	display: flex;
	flex-direction: column;
	gap: 4px;
	padding: 20px 24px;
	border: var(--help-border);
	border-radius: var(--help-card-radius);
	text-decoration: none;
	background: #fff;
	transition: border-color 0.15s, transform 0.15s;
}
.help-related__link:hover {
	border-color: var(--help-brand);
	transform: translateY(-2px);
}
.help-related__link--next { text-align: right; align-items: flex-end; }
.help-related__label {
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--help-muted);
}
.help-related__title {
	font-size: 1rem;
	font-weight: 600;
	color: var(--help-strong);
	line-height: 1.4;
}
