/**
 * Canvas Club — FAQ accordion
 */

.cc-faq {
	overflow: hidden;
}

.cc-faq__splatter {
	position: absolute;
	right: 0px;
	bottom: 0px;
	transform: rotate(180deg);
	width: clamp(4rem, 10vw, 6.5rem);
	height: auto;
	pointer-events: none;
	z-index: 0;
}

.cc-faq__list {
	position: relative;
	z-index: 1;
	border-top: 1px solid #e0e0e0;
}

.cc-faq__item {
	border-bottom: 1px solid #e0e0e0;
}

.cc-faq__question-wrap {
	margin: 0;
}

.cc-faq__question {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	width: 100%;
	padding: 1.1rem 0;
	border: 0;
	background: transparent;
	text-align: left;
	cursor: pointer;
}

.cc-faq__icon {
	position: relative;
	flex-shrink: 0;
	width: 1rem;
	height: 1rem;
}

.cc-faq__icon::before,
.cc-faq__icon::after {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	background: var(--cc-navy);
	transform: translate(-50%, -50%);
	transition: transform 0.25s ease, opacity 0.25s ease;
}

.cc-faq__icon::before {
	width: 100%;
	height: 2px;
}

.cc-faq__icon::after {
	width: 2px;
	height: 100%;
}

.cc-faq__item.is-open .cc-faq__icon::after {
	transform: translate(-50%, -50%) rotate(90deg);
	opacity: 0;
}

.cc-faq__answer {
	display: grid;
	grid-template-rows: 0fr;
	transition: grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.cc-faq__item.is-open .cc-faq__answer {
	grid-template-rows: 1fr;
}

.cc-faq__answer-inner {
	overflow: hidden;
	min-height: 0;
}

.cc-faq__answer-inner .cc-text {
	padding: 0 0 1.1rem;
	margin: 0;
}

@media (prefers-reduced-motion: reduce) {
	.cc-faq__answer {
		transition: none;
	}

	.cc-faq__icon::before,
	.cc-faq__icon::after {
		transition: none;
	}
}

.cc-faq__question:focus-visible {
	outline: 2px solid var(--cc-purple);
	outline-offset: 2px;
}
