/* Dynamic FAQ for Checkout - Frontend */

.dfc-checkout-faq {
	margin: 1em 0;
	position: relative;
	min-height: 20px;
}

.dfc-checkout-faq.dfc-loading {
	opacity: 0.7;
	pointer-events: none;
}

.dfc-checkout-faq.dfc-loading::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 24px;
	height: 24px;
	margin: -12px 0 0 -12px;
	border: 2px solid #ddd;
	border-top-color: #333;
	border-radius: 50%;
	animation: dfc-spin 0.6s linear infinite;
}

.dfc-faq-list {
	display: flex;
	flex-direction: column;
	gap: 0;
}

.dfc-faq-item {
	margin-bottom: 12px;
}

.dfc-faq-item:last-child {
	margin-bottom: 0;
}

/* Accordion */
.dfc-faq-details {
	margin: 0;
}

.dfc-faq-details summary {
	list-style: none;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 14px;
	font-family: Arial, sans-serif;
	font-weight: 500;
	font-size: 0.9em;
	line-height: 1.4;
	color: #1d2327;
	background: #fff;
	transition: background 0.15s ease;
	user-select: none;
	-webkit-tap-highlight-color: transparent;
}

.dfc-faq-details summary::-webkit-details-marker,
.dfc-faq-details summary::marker {
	display: none;
}

.dfc-faq-details summary:hover {
	background: #fff;
}

/* Tablet & mobile: question row background only; answers stay transparent */
@media (max-width: 1024px) {
	.dfc-faq-details summary {
		background: #f0f0f2;
	}
	.dfc-faq-details summary:hover {
		background: #f0f0f2;
	}
}

.dfc-faq-question-text {
	flex: 1;
	text-align: left;
}

.dfc-faq-question-text p {
	margin: 0;
}

.dfc-faq-chevron {
	flex-shrink: 0;
	width: 20px;
	height: 20px;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") center/contain no-repeat;
	transition: transform 0.2s ease;
}

.dfc-faq-details[open] .dfc-faq-chevron {
	transform: rotate(180deg);
}

/* Animated open/close – wrapper with max-height transition */
.dfc-faq-answer-wrap {
	overflow: hidden;
	max-height: 0;
	transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Large enough so long answers (many lines on mobile) are never cut off */
.dfc-faq-details[open] .dfc-faq-answer-wrap {
	max-height: 5000px;
}

.dfc-faq-answer {
	padding: 14px 0 10px 0;
	font-family: Arial, sans-serif;
	font-size: 0.9em;
	line-height: 1.6;
	color: #444;
	background: transparent;
}

.dfc-faq-answer a {
	color: #2271b1;
	text-decoration: underline;
}

.dfc-faq-answer a:hover {
	color: #135e96;
}

.dfc-faq-answer p:first-child {
	margin-top: 0;
}

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

.dfc-faq-empty {
	display: none;
}

/* Checkout Notes */
.dfc-checkout-notes {
	margin: 1em 0;
	position: relative;
	min-height: 0;
}

.dfc-notes-empty {
	display: none;
}

.dfc-notes-list {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.dfc-note-block {
	padding: 14px 16px;
	line-height: 1.5;
}

.dfc-note-block .dfc-note-inner p:first-child {
	margin-top: 0;
}

.dfc-note-block .dfc-note-inner p:last-child {
	margin-bottom: 0;
}

.dfc-note-block .dfc-note-inner a {
	color: inherit;
	text-decoration: underline;
}

/* Thank you page */
.dfc-thankyou-blocks {
	margin: 1em 0;
}

.dfc-thankyou-block {
	margin-bottom: 1.5em;
	padding: 1em 0;
	border-bottom: 1px solid #eee;
}

.dfc-thankyou-block:last-child {
	margin-bottom: 0;
	border-bottom: none;
}

@keyframes dfc-spin {
	to { transform: rotate(360deg); }
}
