/**
 * FAQ Accordion widget styles.
 *
 * Figma references:
 * https://www.figma.com/design/UFbyQSXqjJ3fkYXo3ORgO7/Wellenreiten-2026-Handoff-Ext--Copy-?node-id=70-13914
 * https://www.figma.com/design/UFbyQSXqjJ3fkYXo3ORgO7/Wellenreiten-2026-Handoff-Ext--Copy-?node-id=70-14088
 *
 * 'Archivo' (Figma's heading font) is not enqueued anywhere else in the
 * theme, so it is loaded as a dependency of this stylesheet (see
 * functions.php); body copy reuses the theme's --font-family stack.
 */
.wrfq-section {
	--wrfq-heading-font: 'Archivo', var(--font-family, 'Source Sans 3'), Arial, Helvetica, sans-serif;
	--wrfq-body-font: var(--font-family, 'Source Sans 3'), Arial, Helvetica, sans-serif;
	--wrfq-text-primary: #171717;
	--wrfq-text-secondary: #404040;
	--wrfq-text-tertiary: #525252;
	--wrfq-brand: #0f4c81;
	--wrfq-brand-50: #ebf5f5;
	--wrfq-brand-300: #99c5f1;
	--wrfq-border: #e5e5e5;
	--wrfq-border-open: #0e0e0e;
	--wrfq-icon-bg: #fafafa;
}

.wrfq-wrap {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 40px;
	width: 100%;
	max-width: 1090px;
	margin: 0 auto;
	box-sizing: border-box;
	padding-left: 15px;
	padding-right: 15px;
}

.wrfq-header {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
	text-align: center;
	max-width: 752px;
}

.wrfq-badge {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	height: 26px;
	background: var(--wrfq-brand-50);
	border: 1px solid var(--wrfq-brand-300);
	border-radius: 16px;
	padding: 2px 8px 2px 6px;
}

.wrfq-badge__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 20px;
	font-size: 14px;
	color: var(--wrfq-brand);
}

/**
 * Whether Icons_Manager::render_icon() outputs an icon-font <i> glyph
 * or an inline <svg> depends on the specific icon chosen, not just the
 * library — this one (info-circle, swapped in to dodge a PHP warning
 * from 'circle-question') renders as <svg>, which fills the 20px badge
 * box by default instead of sitting as a smaller 14px glyph inside it.
 */
.wrfq-badge__icon svg {
	width: 14px;
	height: 14px;
	fill: currentColor;
}

.wrfq-badge__text {
	font: 500 14px/20px var(--wrfq-body-font);
	color: var(--wrfq-brand);
	white-space: nowrap;
}

.wrfq-title {
	margin: 0;
	font: 700 36px/44px var(--wrfq-heading-font);
	letter-spacing: -0.02em;
	color: var(--wrfq-text-primary);
}

.wrfq-intro {
	margin: 0;
	font: 400 18px/28px var(--wrfq-body-font);
	color: var(--wrfq-text-tertiary);
}

.wrfq-items {
	display: flex;
	flex-direction: column;
	gap: 16px;
	width: 100%;
}

.wrfq-item {
	background: #ffffff;
	border: 1px solid var(--wrfq-border);
	border-radius: 8px;
}

.wrfq-item[open] {
	border-color: var(--wrfq-border-open);
}

.wrfq-item__question {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	padding: 12px 20px 12px 24px;
	cursor: pointer;
	list-style: none;
}

.wrfq-item__question::-webkit-details-marker {
	display: none;
}

.wrfq-item__question-text {
	font: 700 24px/32px var(--wrfq-heading-font);
	letter-spacing: -0.02em;
	color: var(--wrfq-text-primary);
}

.wrfq-item__icon {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 48px;
	width: 48px;
	height: 48px;
	border-radius: 10px;
	background: var(--wrfq-icon-bg);
	color: var(--wrfq-text-primary);
	font-size: 24px;
}

.wrfq-item__icon-plus,
.wrfq-item__icon-minus {
	position: absolute;
	inset: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

/* Elementor renders these as inline <svg>, which fills the 48px icon
   box by default instead of sitting as a smaller 24px glyph inside it. */
.wrfq-item__icon-plus svg,
.wrfq-item__icon-minus svg {
	width: 24px;
	height: 24px;
	fill: currentColor;
}

.wrfq-item__icon-minus {
	display: none;
}

.wrfq-item[open] .wrfq-item__icon-plus {
	display: none;
}

.wrfq-item[open] .wrfq-item__icon-minus {
	display: inline-flex;
}

.wrfq-item__answer {
	padding: 0 68px 20px 24px;
	font: 400 18px/28px var(--wrfq-body-font);
	color: var(--wrfq-text-secondary);
}

.wrfq-item__answer p {
	margin: 0 0 18px;
}

.wrfq-item__answer p:last-child {
	margin-bottom: 0;
}

.wrfq-item__answer strong,
.wrfq-item__answer b {
	font-weight: 700;
}

@media (max-width: 640px) {
	.wrfq-title {
		font-size: 28px;
		line-height: 34px;
	}

	.wrfq-item__question-text {
		font-size: 20px;
		line-height: 26px;
	}

	.wrfq-item__answer {
		padding-right: 24px;
	}
}
