/* Repuestos Rojas: the newsletter's signup (rr-tienda/boletin.php). Two places:
 * the navy footer (.rr-boletin--pie) and a card under the shop's products
 * (.rr-boletin--tienda), which follows the light and dark themes' colors. */

.rr-boletin {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
	gap: 14px 32px;
	align-items: start;
}

.rr-boletin h2 {
	margin: 0 0 4px;
	font-size: 1.15rem;
}

.rr-boletin__texto p {
	margin: 0;
}

.rr-boletin__form {
	display: grid;
	gap: 10px;
	margin: 0;
}

.rr-boletin__fila {
	display: flex;
	gap: 8px;
}

.rr-boletin__fila input {
	flex: 1;
	min-width: 0;
	min-height: 44px;
	padding: 0 14px;
	border: 1px solid var(--rr-input-border, var(--rr-border));
	border-radius: var(--rr-btn-radius, 8px);
	background: var(--rr-input-bg, #fff);
	color: var(--rr-input-text, var(--rr-text));
	font: inherit;
}

.rr-boletin__fila .rr-btn {
	flex: none;
	min-height: 44px;
}

.rr-boletin__extra {
	display: grid;
	gap: 8px;
}

.rr-boletin__form.is-js:not(.is-open) .rr-boletin__extra {
	display: none;
}

.rr-boletin__pills {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	margin: 0;
	padding: 0;
	border: 0;
}

.rr-boletin__pills legend {
	float: left;
	margin-right: 4px;
	padding: 0;
	font-size: .86rem;
	font-weight: 600;
}

.rr-boletin small {
	font-weight: 400;
	opacity: .8;
}

.rr-boletin__pills label {
	position: relative;
	cursor: pointer;
}

.rr-boletin__pills input {
	position: absolute;
	opacity: 0;
	inset: 0;
	margin: 0;
	cursor: pointer;
}

.rr-boletin__pills span {
	display: inline-block;
	padding: 5px 12px;
	border: 1px solid var(--rr-border);
	border-radius: 999px;
	font-size: .86rem;
	line-height: 1.3;
	transition: background-color .15s, border-color .15s, color .15s;
}

.rr-boletin__pills input:checked + span {
	border-color: var(--rr-primary);
	background: var(--rr-primary);
	color: var(--rr-on-primary, #fff);
}

.rr-boletin__pills input:focus-visible + span,
.rr-boletin__fila input:focus-visible {
	outline: 2px solid var(--rr-link, var(--rr-primary));
	outline-offset: 2px;
}

.rr-boletin__marca {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px 10px;
	margin: 0;
	font-size: .86rem;
}

.rr-boletin__marca label {
	font-weight: 600;
}

.rr-boletin__marca input {
	flex: 1;
	min-width: 180px;
	min-height: 36px;
	padding: 0 12px;
	border: 1px solid var(--rr-input-border, var(--rr-border));
	border-radius: 8px;
	background: var(--rr-input-bg, #fff);
	color: var(--rr-input-text, var(--rr-text));
	font: inherit;
}

.rr-boletin__legal {
	margin: 0;
	font-size: .8rem;
	opacity: .85;
}

.rr-boletin__aviso {
	margin: 0;
	padding: 10px 14px;
	border-radius: 10px;
	background: rgba(217, 45, 32, .12);
	font-size: .92rem;
	font-weight: 600;
}

.rr-boletin__aviso.is-ok {
	background: rgba(15, 138, 95, .14);
}

.rr-boletin__form.is-sending {
	opacity: .65;
	pointer-events: none;
}

.rr-boletin__form.is-done :is(.rr-boletin__fila, .rr-boletin__extra, .rr-boletin__legal) {
	display: none;
}

/* The footer: navy in both themes. */
.rr-boletin--pie {
	margin: -8px 0 40px;
	padding: 0 0 36px;
	border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.rr-boletin--pie h2 {
	color: #fff;
}

.rr-boletin--pie .rr-boletin__fila input,
.rr-boletin--pie .rr-boletin__marca input {
	border-color: rgba(255, 255, 255, .28);
	background: rgba(255, 255, 255, .08);
	color: #fff;
}

.rr-boletin--pie input::placeholder {
	color: #a9b8de;
	opacity: 1;
}

.rr-boletin--pie .rr-boletin__pills span {
	border-color: rgba(255, 255, 255, .3);
	color: #dfe7fb;
}

.rr-boletin--pie .rr-boletin__pills input:checked + span {
	border-color: #fff;
	background: #fff;
	color: #0a1a5c;
}

.rr-boletin--pie .rr-boletin__pills input:focus-visible + span,
.rr-boletin--pie .rr-boletin__fila input:focus-visible {
	outline-color: #fff;
}

.rr-boletin--pie .rr-boletin__legal a {
	text-decoration: underline;
}

.rr-boletin--pie .rr-boletin__aviso {
	background: rgba(255, 120, 110, .18);
	color: #fff;
}

.rr-boletin--pie .rr-boletin__aviso.is-ok {
	background: rgba(125, 226, 180, .18);
}

/* Under the shop's products. */
.rr-boletin--tienda {
	margin-top: 40px;
	padding: clamp(18px, 3vw, 28px);
	border: 1px solid var(--rr-border);
	border-radius: var(--rr-radius-lg, 16px);
	background: var(--rr-surface-2);
	color: var(--rr-text);
}

.rr-boletin--tienda h2 {
	color: var(--rr-heading);
}

.rr-boletin--tienda .rr-boletin__pills span {
	background: var(--rr-surface, #fff);
}

/* The box to tick in the consult and the quote form. */
.rr-boletin__check label {
	display: flex;
	gap: 8px;
	align-items: flex-start;
	font-weight: 400;
}

.rr-boletin__check input {
	margin-top: .25em;
}

@media (max-width: 860px) {
	.rr-boletin {
		grid-template-columns: minmax(0, 1fr);
	}
}

@media (max-width: 420px) {
	.rr-boletin__fila {
		flex-direction: column;
	}
}
