/* ECM Event RSVP — theme override layer
   Loaded only when "Force the plugin's button and popup styles" is on.

   Beaver Builder and PowerPack style every <button> and <a> on the site, which
   is what turns the RSVP button pale blue and puts a grey box behind the close
   cross. These rules restate the plugin's own values at a specificity the theme
   cannot reach. Nothing here is layout — only the properties themes overwrite. */

/* ---------- Buttons: the site gradient, always ---------- */

.ecm-rsvp .ecm-rsvp__btn,
.ecm-rsvp a.ecm-rsvp__btn,
.ecm-rsvp button.ecm-rsvp__btn,
.ecm-rsvp .ecm-rsvp__btn:link,
.ecm-rsvp .ecm-rsvp__btn:visited,
.ecm-rsvp .ecm-rsvp__btn:hover,
.ecm-rsvp .ecm-rsvp__btn:focus,
.ecm-rsvp .ecm-rsvp__btn:active {
	background-image: linear-gradient(90deg, var(--ecm-gold, #c8a653) 0%, rgb(0, 0, 0) 100%) !important;
	background-color: transparent !important;
	color: #ffffff !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	text-shadow: none !important;
	text-decoration: none !important;
	padding: 14px 30px !important;
	font-weight: 700 !important;
	line-height: 1.3 !important;
	text-transform: none !important;
	opacity: 1 !important;
}

.ecm-rsvp .ecm-rsvp__btn:hover,
.ecm-rsvp .ecm-rsvp__btn:focus {
	filter: brightness(1.15) !important;
}

/* ---------- Submit: cream face, black label ---------- */

.ecm-rsvp .ecm-rsvp__submit,
.ecm-rsvp button.ecm-rsvp__submit,
.ecm-rsvp .ecm-rsvp__submit:hover,
.ecm-rsvp .ecm-rsvp__submit:focus,
.ecm-rsvp .ecm-rsvp__submit:active {
	background-image: none !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	text-shadow: none !important;
	text-decoration: none !important;
	padding: 14px 34px !important;
	font-weight: 700 !important;
	text-transform: uppercase !important;
	letter-spacing: .06em !important;
	opacity: 1 !important;
}

/* ---------- Close: bare cross, top right ---------- */

.ecm-rsvp .ecm-rsvp__close,
.ecm-rsvp button.ecm-rsvp__close,
.ecm-rsvp .ecm-rsvp__close:hover,
.ecm-rsvp .ecm-rsvp__close:focus,
.ecm-rsvp .ecm-rsvp__close:active {
	background: none !important;
	background-color: transparent !important;
	background-image: none !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	padding: 0 !important;
	margin: 0 !important;
	min-width: 0 !important;
	min-height: 0 !important;
	width: 40px !important;
	height: 40px !important;
	line-height: 0 !important;
	color: #ffffff !important;
	text-shadow: none !important;
}

.ecm-rsvp .ecm-rsvp__close::before,
.ecm-rsvp .ecm-rsvp__close::after {
	content: none !important;
}

.ecm-rsvp .ecm-rsvp__close svg {
	display: block !important;
	width: 26px !important;
	height: 26px !important;
}

/* ---------- Popup ---------- */

.ecm-rsvp .ecm-rsvp__dialog {
	background-image: linear-gradient(90deg, var(--ecm-gold, #c8a653) 0%, rgb(0, 0, 0) 100%) !important;
	background-color: transparent !important;
	border: 4px solid #000000 !important;
	border-radius: 0 !important;
}

/* Every text node in the popup is white unless it sits on a light surface. */
.ecm-rsvp .ecm-rsvp__dialog,
.ecm-rsvp .ecm-rsvp__title,
.ecm-rsvp .ecm-rsvp__lead,
.ecm-rsvp .ecm-rsvp__hint,
.ecm-rsvp .ecm-rsvp__done,
.ecm-rsvp .ecm-rsvp__done p,
.ecm-rsvp .ecm-rsvp__done-message,
.ecm-rsvp .ecm-rsvp__field label,
.ecm-rsvp .ecm-rsvp__choices legend {
	color: #ffffff !important;
	text-shadow: none !important;
}

.ecm-rsvp .ecm-rsvp__title,
.ecm-rsvp .ecm-rsvp__lead,
.ecm-rsvp .ecm-rsvp__done,
.ecm-rsvp .ecm-rsvp__done-message {
	text-align: center !important;
}

.ecm-rsvp .ecm-rsvp__required {
	color: #f6eace !important;
}

/* ---------- Choices ---------- */

.ecm-rsvp .ecm-rsvp__choice {
	color: #ffffff !important;
	border-radius: 0 !important;
	box-shadow: none !important;
}

.ecm-rsvp .ecm-rsvp__choice:has(input:checked) {
	background: var(--ecm-gold, #c8a653) !important;
	color: #000000 !important;
}

/* Fallback for browsers without :has() — JS mirrors the state onto the label. */
.ecm-rsvp .ecm-rsvp__choice.is-checked {
	background: var(--ecm-gold, #c8a653) !important;
	border-color: #000000 !important;
	color: #000000 !important;
	font-weight: 700 !important;
}

.ecm-rsvp .ecm-rsvp__field input,
.ecm-rsvp .ecm-rsvp__field textarea {
	background: #ffffff !important;
	color: #000000 !important;
	border-radius: 2px !important;
	box-shadow: none !important;
}

/* ---------- Card ---------- */

.ecm-rsvp .ecm-rsvp__cancel,
.ecm-rsvp button.ecm-rsvp__cancel {
	background: none !important;
	background-image: none !important;
	border: 0 !important;
	box-shadow: none !important;
	padding: 0 !important;
	color: #000000 !important;
}
