/* Rombo Spotify Popup — styled on the ROMBO design system.
   Ultramarine on cream, Helvetica, sharp corners, capsule buttons,
   no drop shadows, quiet motion.

   All selectors are scoped under #rsp-overlay and buttons carry explicit
   resets so theme styles (WordPress themes style bare <button>) can't
   bleed into the popup. */

#rsp-overlay {
	--rsp-blue: #130ABC;
	--rsp-blue-ink: #0E08A3;
	--rsp-paper: #F3F1EA;
	--rsp-ink: #1A1A1A;
	--rsp-muted: #6F6F6F;
	--rsp-rule: rgba(19, 10, 188, 0.15);
	--rsp-font: "Helvetica Neue ROMBO", "Helvetica Neue", Helvetica, Arial, sans-serif;
	--rsp-ease-quiet: cubic-bezier(0.22, 0.61, 0.36, 1);

	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	background: rgba(17, 17, 17, 0.55);
	opacity: 1;
	transition: opacity 220ms var(--rsp-ease-quiet);
}

#rsp-overlay.rsp-hidden {
	display: none;
	opacity: 0;
}

#rsp-overlay .rsp-popup {
	position: relative;
	width: 100%;
	max-width: 440px;
	/* dvh handles iOS Safari's collapsing URL bar; vh is the fallback */
	max-height: calc(100vh - 32px);
	max-height: calc(100dvh - 32px);
	overflow-y: auto;
	overscroll-behavior: contain;
	-webkit-overflow-scrolling: touch;
	background: var(--rsp-paper);
	color: var(--rsp-ink);
	border: 1px solid var(--rsp-blue);
	border-radius: 0;
	padding: 48px 40px 32px;
	text-align: center;
	font-family: var(--rsp-font);
	-webkit-font-smoothing: antialiased;
	animation: rsp-reveal 480ms var(--rsp-ease-quiet);
}

@keyframes rsp-reveal {
	from {
		transform: translateY(16px);
		opacity: 0;
	}
	to {
		transform: translateY(0);
		opacity: 1;
	}
}

/* --- Buttons: hard reset first, then style ------------------------------ */

#rsp-overlay .rsp-close,
#rsp-overlay .rsp-dismiss {
	appearance: none !important;
	-webkit-appearance: none !important;
	background: transparent !important;
	border: none !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	text-shadow: none !important;
	text-transform: none !important;
	letter-spacing: normal;
	margin: 0;
	padding: 0;
	min-height: 0;
	min-width: 0;
	line-height: 1;
	font-family: var(--rsp-font);
	cursor: pointer;
}

#rsp-overlay .rsp-close {
	position: absolute;
	top: 12px;
	right: 16px;
	padding: 4px;
	color: var(--rsp-blue);
	font-size: 26px;
	font-weight: 300;
	transition: color 120ms var(--rsp-ease-quiet);
}

#rsp-overlay .rsp-close:hover {
	color: var(--rsp-blue-ink);
}

#rsp-overlay .rsp-dismiss {
	display: block;
	margin: 20px auto 0;
	border-bottom: 1px solid currentColor !important;
	color: var(--rsp-muted);
	font-size: 13px;
	font-style: italic;
	line-height: 1.4;
	transition: color 120ms var(--rsp-ease-quiet);
}

#rsp-overlay .rsp-dismiss:hover {
	color: var(--rsp-ink);
	background: transparent !important;
}

/* --- Content ------------------------------------------------------------ */

#rsp-overlay .rsp-eyebrow {
	margin: 0 0 12px;
	font-size: 11px;
	font-weight: 400;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--rsp-blue);
	line-height: 1.2;
}

#rsp-overlay .rsp-title {
	margin: 0 0 12px;
	font-size: 28px;
	font-weight: 400;
	font-family: var(--rsp-font);
	letter-spacing: -0.025em;
	line-height: 1.05;
	color: var(--rsp-blue);
	text-wrap: balance;
}

#rsp-overlay .rsp-message {
	margin: 0 0 24px;
	font-size: 14px;
	line-height: 1.55;
	color: var(--rsp-ink);
}

#rsp-overlay .rsp-cover {
	display: block;
	width: 168px;
	margin: 0 auto 24px;
	border: 1px solid var(--rsp-rule);
	border-radius: 0;
	line-height: 0;
	transition: border-color 220ms var(--rsp-ease-quiet);
}

#rsp-overlay .rsp-cover:hover {
	border-color: var(--rsp-blue);
}

#rsp-overlay .rsp-cover img {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 0;
}

#rsp-overlay .rsp-note {
	margin: 12px 0 0;
	font-size: 12px;
	line-height: 1.4;
	color: var(--rsp-muted);
}

#rsp-overlay .rsp-embed {
	margin-bottom: 24px;
	border-top: 1px solid var(--rsp-rule);
	border-bottom: 1px solid var(--rsp-rule);
	padding: 16px 0;
}

#rsp-overlay .rsp-embed iframe {
	display: block;
	border: 0;
}

#rsp-overlay .rsp-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	background: var(--rsp-blue);
	color: var(--rsp-paper) !important;
	font-family: var(--rsp-font);
	font-size: 13px;
	font-weight: 400;
	letter-spacing: 0.06em;
	text-decoration: none !important;
	border: 1px solid var(--rsp-blue);
	border-radius: 999px;
	padding: 12px 28px;
	box-shadow: none;
	transition: background 220ms var(--rsp-ease-quiet), border-color 220ms var(--rsp-ease-quiet);
}

#rsp-overlay .rsp-button:hover {
	background: var(--rsp-blue-ink);
	border-color: var(--rsp-blue-ink);
	color: var(--rsp-paper) !important;
}

#rsp-overlay .rsp-button:focus-visible {
	outline: none;
	box-shadow: 0 0 0 2px var(--rsp-paper), 0 0 0 4px var(--rsp-blue);
}

#rsp-overlay .rsp-spotify-icon {
	flex: 0 0 auto;
}

/* --- Responsive ---------------------------------------------------------- */

/* Narrow screens (portrait phones) */
@media (max-width: 480px) {
	#rsp-overlay .rsp-popup {
		padding: 36px 24px 24px;
	}

	#rsp-overlay .rsp-title {
		font-size: 23px;
	}

	#rsp-overlay .rsp-cover {
		width: 144px;
	}
}

/* Short viewports (landscape phones): compress so the CTA stays reachable */
@media (max-height: 620px) {
	#rsp-overlay .rsp-popup {
		padding: 28px 28px 20px;
	}

	#rsp-overlay .rsp-cover {
		width: 96px;
		margin-bottom: 16px;
	}

	#rsp-overlay .rsp-eyebrow {
		margin-bottom: 8px;
	}

	#rsp-overlay .rsp-title {
		font-size: 22px;
		margin-bottom: 8px;
	}

	#rsp-overlay .rsp-message {
		margin-bottom: 16px;
	}

	#rsp-overlay .rsp-dismiss {
		margin-top: 14px;
	}
}

/* Very short viewports: drop the artwork entirely, keep the single CTA */
@media (max-height: 460px) {
	#rsp-overlay .rsp-cover,
	#rsp-overlay .rsp-embed {
		display: none;
	}

	#rsp-overlay .rsp-note {
		margin-top: 8px;
	}
}
