/* ─── EP FAQ — Frontend Styles ─────────────────────────────── */

.ep-faq {
	margin: 32px 0;
	max-width: 800px;
}

/* ─── Search ──────────────────────────────────────────────── */

.ep-faq-search {
	margin-bottom: 24px;
	position: relative;
}

.ep-faq-search-input {
	width: 100%;
	padding: 12px 16px 12px 44px;
	border: 1px solid #e5e7eb;
	border-radius: 8px;
	font-size: 15px;
	font-family: inherit;
	box-sizing: border-box;
	background: #fff;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.ep-faq-search-input:focus {
	outline: none;
	border-color: #b8963e;
	box-shadow: 0 0 0 3px rgba(184, 150, 62, 0.1);
}

.ep-faq-search-icon {
	position: absolute;
	left: 14px;
	top: 50%;
	transform: translateY(-50%);
	width: 20px;
	height: 20px;
	color: #9ca3af;
	pointer-events: none;
}

/* ─── Accordion Items ─────────────────────────────────────── */

.ep-faq-item {
	border: 1px solid #e5e7eb;
	border-radius: 8px;
	margin-bottom: 8px;
	overflow: hidden;
	background: #fff;
}

.ep-faq-question {
	display: flex;
	align-items: center;
	gap: 12px;
	width: 100%;
	padding: 16px 20px;
	background: #fff;
	border: none;
	cursor: pointer;
	text-align: left;
	font-size: 15px;
	font-weight: 600;
	color: #111827;
	font-family: inherit;
	line-height: 1.4;
	transition: background 0.15s;
}

.ep-faq-question:hover {
	background: #f9fafb;
}

.ep-faq-question[aria-expanded="true"] {
	border-bottom: 1px solid #f3f4f6;
}

.ep-faq-question-text {
	flex: 1;
}

/* ─── Accordion Icons ─────────────────────────────────────── */

.ep-faq-icon {
	flex-shrink: 0;
	width: 20px;
	height: 20px;
	color: #9ca3af;
	transition: transform 0.2s ease;
}

.ep-faq-icon-svg {
	width: 20px;
	height: 20px;
	display: block;
}

/* Chevron: rotate down when open */
.ep-faq-question[aria-expanded="true"] .ep-faq-icon {
	transform: rotate(180deg);
}

/* Plus/minus: hide horizontal line when open */
.ep-faq-question[aria-expanded="true"] .ep-faq-icon-h {
	opacity: 0;
}

/* Arrow: rotate 90deg when open */
[data-icon="arrow"] .ep-faq-question[aria-expanded="true"] .ep-faq-icon {
	transform: rotate(90deg);
}

/* ─── Answer ──────────────────────────────────────────────── */

.ep-faq-answer {
	padding: 0 20px;
}

.ep-faq-answer-content {
	padding: 16px 0;
	font-size: 15px;
	line-height: 1.7;
	color: #374151;
}

.ep-faq-answer-content p {
	margin: 0 0 12px;
}

.ep-faq-answer-content p:last-child {
	margin-bottom: 0;
}

.ep-faq-answer-content img {
	max-width: 100%;
	height: auto;
	border-radius: 4px;
}

.ep-faq-answer-content a {
	color: #b8963e;
	text-decoration: none;
}

.ep-faq-answer-content a:hover {
	text-decoration: underline;
}

/* ─── Voting ───���───────────────────────────────��──────────── */

.ep-faq-voting {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 12px 0 16px;
	border-top: 1px solid #f3f4f6;
	font-size: 13px;
}

.ep-faq-voting-label {
	color: #6b7280;
}

.ep-faq-vote {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 4px 12px;
	border: 1px solid #e5e7eb;
	border-radius: 16px;
	background: #fff;
	cursor: pointer;
	font-size: 13px;
	font-family: inherit;
	color: #374151;
	transition: background 0.15s, border-color 0.15s;
}

.ep-faq-vote--yes:hover {
	background: #dcfce7;
	border-color: #86efac;
}

.ep-faq-vote--no:hover {
	background: #fee2e2;
	border-color: #fca5a5;
}

.ep-faq-vote svg {
	width: 14px;
	height: 14px;
}

.ep-faq-voting-thanks {
	color: #4a8a5c;
	font-weight: 500;
}

/* ─── Related ─────────────────────────────────────────────── */

.ep-faq-related {
	padding: 8px 0 16px;
	font-size: 13px;
	color: #6b7280;
}

.ep-faq-related a {
	color: #b8963e;
	text-decoration: none;
}

.ep-faq-related a:hover {
	text-decoration: underline;
}

/* ─── Flat Layout ─��───────────────────────────────────────── */

.ep-faq--flat .ep-faq-item {
	border: none;
	border-bottom: 1px solid #f3f4f6;
	border-radius: 0;
	margin-bottom: 0;
}

.ep-faq--flat .ep-faq-item:last-child {
	border-bottom: none;
}

.ep-faq-question-flat {
	font-size: 16px;
	font-weight: 600;
	color: #111827;
	margin: 0 0 8px;
	padding-top: 20px;
}

.ep-faq-answer-flat {
	font-size: 15px;
	line-height: 1.7;
	color: #374151;
	padding-bottom: 20px;
}

.ep-faq-answer-flat p {
	margin: 0 0 12px;
}

.ep-faq-answer-flat p:last-child {
	margin-bottom: 0;
}

/* Two-column flat */
.ep-faq--cols-2 .ep-faq-list {
	display: grid;
	grid-template-columns: 1fr;
	gap: 0;
}

@media (min-width: 768px) {
	.ep-faq--cols-2 .ep-faq-list {
		grid-template-columns: repeat(2, 1fr);
		gap: 0 32px;
	}
}

/* ─── Grouped Layout ──────────────────────────────────────── */

.ep-faq-group {
	margin-bottom: 32px;
}

.ep-faq-group:last-child {
	margin-bottom: 0;
}

.ep-faq-group-title {
	font-size: 20px;
	font-weight: 700;
	color: #111827;
	margin: 0 0 16px;
	padding-bottom: 8px;
	border-bottom: 2px solid #e5e7eb;
}

/* ─── No Results ──────────────────────────────────────────── */

.ep-faq-no-results {
	text-align: center;
	padding: 32px;
	color: #9ca3af;
	font-size: 15px;
}

/* ─── Responsive ──────────────────────────────────────────── */

@media (max-width: 640px) {
	.ep-faq-question {
		padding: 14px 16px;
		font-size: 14px;
	}

	.ep-faq-answer-content {
		font-size: 14px;
	}

	.ep-faq-voting {
		flex-wrap: wrap;
	}
}
