/**
 * Anelli Certificate — etichetta e popup
 */

.single-product .entry-summary .price-single {
	align-items: center;
	flex-wrap: wrap;
	gap: 10px 14px;
}

.single-product .entry-summary .price-single .price {
	width: auto;
	flex: 0 1 auto;
}

.anelli-cert-tag {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	padding: 4px 6px 4px 10px;
	border: 1px solid #d96e40;
	background: transparent;
	color: #d96e40;
	font-family: inherit;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.06em;
	line-height: 1.2;
	text-transform: uppercase;
	cursor: pointer;
	appearance: none;
	-webkit-appearance: none;
	white-space: nowrap;
	flex: 0 0 auto;
	transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.anelli-cert-tag:hover,
.anelli-cert-tag:focus-visible {
	background: rgba(217, 110, 64, 0.12);
	color: #d96e40;
	outline: none;
}

.anelli-cert-tag__gia {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: #fff;
	padding: 2px 5px;
	line-height: 0;
	flex: 0 0 auto;
}

.anelli-cert-tag__gia img {
	display: block;
	height: 18px;
	width: auto;
}

.anelli-cert-modal {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: none;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.anelli-cert-modal.is-open {
	display: flex;
}

.anelli-cert-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.55);
}

.anelli-cert-modal__panel {
	position: relative;
	z-index: 2;
	width: min(520px, 100%);
	max-height: min(92vh, 900px);
	overflow: auto;
	background: #fff;
	padding: 28px 24px 32px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.anelli-cert-modal__close {
	position: absolute;
	top: 12px;
	right: 14px;
	border: 0;
	background: none;
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
	color: #666;
}

.anelli-cert-modal__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px 14px;
	flex-wrap: wrap;
	margin: 0 32px 14px 0;
}

.anelli-cert-modal__title {
	margin: 0;
	flex: 1 1 200px;
	font-size: 22px;
	font-weight: 500;
	letter-spacing: 0.02em;
	color: var(--gray-dark, #1a1a1a);
}

.anelli-cert-modal__gia {
	display: inline-flex;
	align-items: center;
	flex: 0 0 auto;
	line-height: 0;
}

.anelli-cert-modal__gia img {
	display: block;
	height: 26px;
	width: auto;
}

.anelli-cert-modal__intro {
	margin: 0 0 20px;
	font-size: 14px;
	line-height: 1.6;
	color: #555;
}

.anelli-cert-form__row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
}

.anelli-cert-form__field {
	margin-bottom: 14px;
}

.anelli-cert-form__field label {
	display: block;
	margin-bottom: 6px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: #666;
}

.anelli-cert-form__field input[type="text"],
.anelli-cert-form__field input[type="email"],
.anelli-cert-form__field input[type="tel"] {
	width: 100%;
	padding: 11px 12px;
	border: 1px solid #ddd;
	background: #fff;
	font-family: inherit;
	font-size: 14px;
	line-height: 1.4;
	color: #1a1a1a;
	box-sizing: border-box;
}

.anelli-cert-form__field input:focus {
	outline: none;
	border-color: var(--theme-color, #63512d);
}

.anelli-cert-form__channel {
	margin: 4px 0 16px;
	padding: 0;
	border: 0;
}

.anelli-cert-form__channel legend {
	margin: 0 0 10px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: #666;
}

.anelli-cert-choice {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-right: 18px;
	font-size: 14px;
	color: #1a1a1a;
	cursor: pointer;
}

.anelli-cert-form__privacy {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	margin: 4px 0 18px;
	font-size: 12px;
	line-height: 1.5;
	color: #666;
	cursor: pointer;
}

.anelli-cert-form__privacy input {
	margin-top: 3px;
	flex-shrink: 0;
}

.anelli-cert-form__submit {
	display: block;
	width: 100%;
	min-height: 48px;
	padding: 14px 20px;
	border: 1px solid var(--gray-dark, #1a1a1a);
	background: var(--gray-dark, #1a1a1a);
	color: #fff;
	font-family: inherit;
	font-size: 12px;
	font-weight: 500;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	cursor: pointer;
	transition: background 0.25s ease, border-color 0.25s ease, opacity 0.25s ease;
	appearance: none;
	-webkit-appearance: none;
}

.anelli-cert-form__submit:hover:not(:disabled) {
	background: var(--theme-color, #63512d);
	border-color: var(--theme-color, #63512d);
}

.anelli-cert-form__submit:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

.anelli-cert-form__message {
	margin: 14px 0 0;
	font-size: 13px;
	line-height: 1.5;
}

.anelli-cert-form__message--error {
	color: #c62828;
}

.anelli-cert-success {
	padding: 12px 4px 4px;
	text-align: center;
}

.anelli-cert-success__title {
	margin: 0 0 10px;
	font-size: 16px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: #2e7d32;
}

.anelli-cert-success__text {
	margin: 0;
	font-size: 14px;
	line-height: 1.7;
	color: #444;
}

body.anelli-cert-modal-open {
	overflow: hidden;
}

@media (max-width: 767px) {
	.anelli-cert-form__row {
		grid-template-columns: 1fr;
	}

	.anelli-cert-modal__panel {
		padding: 24px 18px 28px;
	}

	.anelli-cert-modal__head {
		margin-right: 36px;
		gap: 8px 12px;
	}

	.anelli-cert-modal__title {
		font-size: 18px;
		flex-basis: 160px;
	}

	.anelli-cert-modal__gia img {
		height: 22px;
	}

	.anelli-cert-tag {
		font-size: 13px;
		padding: 5px 8px;
		gap: 8px;
		letter-spacing: 0.04em;
		width: 100%;
		justify-content: center;
		box-sizing: border-box;
	}

	.anelli-cert-tag__gia {
		padding: 2px 5px;
	}

	.anelli-cert-tag__gia img {
		height: 20px;
	}
}
