/* ==========================================================================
   FAQ.CSS — The Law Office of Jimmy Cha, APC.
   Frequently Asked Questions (/faq). Map the page ID to 'faq' in functions.php.
   Hero · grouped accordion · CTA (final-cta + form-placeholder from component.css).

   NOTE: the docx and wireframe contain no FAQ content (page card only). The Q&A
   here is drafted from approved site facts as working content — client to finalize.
   ========================================================================== */

@keyframes jcFadeUp {
	from { opacity: 0; transform: translateY(28px); }
	to   { opacity: 1; transform: none; }
}

/* ==========================================================================
   HERO
   ========================================================================== */
.faq-hero {
	position: relative;
	overflow: hidden;
	background: var(--ink);
	border-bottom: 1px solid var(--crimson-dim);
}
.faq-hero-inner {
	position: relative;
	z-index: 1;
	max-width: 820px;
	margin-inline: auto;
	text-align: center;
	padding-block: 96px 72px;
}
.faq-hero-eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-family: var(--font-mono);
	font-size: 11px;
	font-weight: 500;
	letter-spacing: 2.5px;
	text-transform: uppercase;
	color: var(--gold);
	padding: 9px 18px;
	border: 1px solid var(--gold-dim);
	border-radius: 50px;
	background: var(--gold-dim);
	margin-bottom: 22px;
	animation: jcFadeUp 0.7s ease both;
}
.faq-hero-title {
	font-size: clamp(32px, 4.6vw, 52px);
	font-weight: 700;
	color: var(--warm-white);
	line-height: 1.1;
	letter-spacing: -0.4px;
	margin-bottom: 18px;
	animation: jcFadeUp 0.7s ease 0.08s both;
}
.faq-hero-title em {
	font-style: italic;
	background: var(--grad-crimson);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
}
.faq-hero-sub {
	font-size: clamp(16px, 2vw, 19px);
	color: var(--silver-light);
	max-width: 640px;
	margin: 0 auto 28px;
	animation: jcFadeUp 0.7s ease 0.16s both;
}
.faq-hero-actions {
	display: flex;
	justify-content: center;
	flex-wrap: wrap;
	gap: 16px;
	margin-bottom: 22px;
	animation: jcFadeUp 0.7s ease 0.24s both;
}

/* Category filter chips (hero) */
.faq-filters {
	display: flex;
	justify-content: center;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 6px;
	animation: jcFadeUp 0.7s ease 0.24s both;
}

/* ==========================================================================
   FAQ BODY — grouped accordion
   ========================================================================== */
.faq-body {
	background: var(--ink);
}
.faq-wrap {
	max-width: 920px;
	margin-inline: auto;
}
.faq-group {
	margin-bottom: 52px;
}
.faq-group:last-child {
	margin-bottom: 0;
}
.faq-group-title {
	font-size: clamp(22px, 3vw, 30px);
	color: var(--warm-white);
	margin-bottom: 20px;
	padding-bottom: 14px;
	border-bottom: 1px solid var(--gunmetal);
}
.faq-list {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

/* Accordion item */
.faq-item {
	border: 1px solid var(--gunmetal);
	border-radius: var(--radius-lg);
	background: var(--grad-surface);
	overflow: hidden;
	transition: border-color 0.3s ease;
}
.faq-item.is-open {
	border-color: rgba(166, 24, 44, 0.4);
}
.faq-q {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	width: 100%;
	text-align: left;
	padding: 22px 26px;
	font-family: var(--font-display);
	font-size: clamp(17px, 2vw, 20px);
	font-weight: 600;
	color: var(--warm-white);
	line-height: 1.3;
	cursor: pointer;
	transition: color 0.2s ease;
}
.faq-q:hover {
	color: var(--crimson-light);
}
.faq-q-icon {
	flex-shrink: 0;
	display: grid;
	place-items: center;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	font-size: 13px;
	color: var(--crimson-light);
	background: rgba(166, 24, 44, 0.12);
	border: 1px solid rgba(166, 24, 44, 0.25);
	transition: transform 0.35s ease, background 0.3s ease, color 0.3s ease;
}
.faq-item.is-open .faq-q-icon {
	transform: rotate(180deg);
	background: var(--grad-crimson);
	border-color: transparent;
	color: #fff;
}
/* Collapsible answer */
.faq-a {
	max-height: 0;
	overflow: hidden;
	transition: max-height 0.4s ease;
}
.faq-item.is-open .faq-a {
	max-height: 600px;
}
.faq-a-inner {
	padding: 0 26px 24px;
	font-size: 15.5px;
	color: var(--silver-light);
	line-height: 1.75;
}
.faq-a-inner .faq-note {
	display: block;
	margin-top: 10px;
	font-family: var(--font-mono);
	font-size: 12px;
	letter-spacing: 0.3px;
	color: var(--gray-300);
}

/* Category filtering — hide non-matching questions and empty groups */
.faq-item.is-hidden,
.faq-group.is-hidden {
	display: none;
}

/* When JS is unavailable, show all answers (progressive enhancement) */
html:not(.js) .faq-a {
	max-height: none;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 680px) {
	.faq-hero-inner {
		padding-block: 68px 52px;
	}
	.faq-hero-actions .btn {
		width: 100%;
	}
	.faq-q {
		padding: 18px 18px;
	}
	.faq-a-inner {
		padding: 0 18px 20px;
	}
}
