/**
 * Collapse & Expand (Accordion)
 */

.esw-acc {
	width: 100%;
	box-sizing: border-box;
}

.esw-acc__item {
	box-sizing: border-box;
}

.esw-acc__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	margin: 0;
	padding: 1rem 0;
	text-align: left;
	cursor: pointer;
	font: inherit;
	background: none;
	border: none;
	color: inherit;
	box-sizing: border-box;
}

.esw-acc__title {
	flex: 1 1 auto;
	padding-right: 1rem;
	font-weight: 700;
}

/* Chevron */
.esw-acc__icon--chevron {
	position: relative;
	flex: 0 0 auto;
	display: inline-block;
	width: 1em;
	height: 1em;
	box-sizing: border-box;
}

.esw-acc__icon--chevron::before {
	content: "";
	position: absolute;
	left: 50%;
	top: 45%;
	width: 0.45em;
	height: 0.45em;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: translate(-50%, -50%) rotate(45deg);
	transition: transform 0.2s ease;
}

.esw-acc__item.is-open .esw-acc__icon--chevron::before {
	transform: translate(-50%, -30%) rotate(-135deg);
}

/* Plus / minus */
.esw-acc__icon--plus {
	position: relative;
	flex: 0 0 auto;
	display: inline-block;
	width: 1em;
	height: 1em;
}

.esw-acc__icon--plus::before,
.esw-acc__icon--plus::after {
	content: "";
	position: absolute;
	left: 50%;
	top: 50%;
	background: currentColor;
	transform: translate(-50%, -50%);
	transition: opacity 0.2s ease, transform 0.2s ease;
}

.esw-acc__icon--plus::before {
	width: 100%;
	height: 2px;
}

.esw-acc__icon--plus::after {
	width: 2px;
	height: 100%;
}

.esw-acc__item.is-open .esw-acc__icon--plus::after {
	opacity: 0;
	transform: translate(-50%, -50%) scaleY(0);
}

.esw-acc__icon--hidden {
	display: none !important;
}

.esw-acc__panel {
	overflow: hidden;
	box-sizing: border-box;
}

.esw-acc__panel[hidden] {
	display: none !important;
}

.esw-acc__panel-inner {
	padding-bottom: 1rem;
}

.esw-acc__inner {
	column-gap: 1.5rem;
}

.esw-acc__inner p:first-child {
	margin-top: 0;
}

.esw-acc__inner p:last-child {
	margin-bottom: 0;
}

.esw-acc__inner a {
	color: inherit;
	opacity: 0.85;
	text-decoration: none;
}

.esw-acc__inner a:hover {
	opacity: 1;
	text-decoration: underline;
}
