/* Push Notify — subscription prompt, bell, shortcode button */

.pn-prompt,
.pn-bell,
.pn-subscribe-button,
.pn-toast {
	--pn-primary: #2271b1;
	--pn-bg: #ffffff;
	--pn-text: #1d2327;
	box-sizing: border-box;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

.pn-prompt *,
.pn-prompt *::before,
.pn-prompt *::after {
	box-sizing: border-box;
}

.pn-prompt {
	position: fixed;
	z-index: 2147483000;
	background: var(--pn-bg);
	color: var(--pn-text);
	font-size: 15px;
	line-height: 1.45;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.18), 0 2px 8px rgba(0, 0, 0, 0.08);
	border-radius: 12px;
	opacity: 0;
	transition: opacity 0.25s ease, transform 0.25s ease;
}

.pn-prompt.pn-show {
	opacity: 1;
}

/* Box */
.pn-box {
	width: 370px;
	max-width: calc(100vw - 24px);
	padding: 18px;
	display: flex;
	gap: 14px;
	align-items: flex-start;
}

.pn-pos-bottom-left { left: 16px; bottom: 16px; transform: translateY(12px); }
.pn-pos-bottom-right { right: 16px; bottom: 16px; transform: translateY(12px); }
.pn-pos-top-center { top: 16px; left: 50%; transform: translate(-50%, -12px); }
.pn-pos-center { top: 50%; left: 50%; transform: translate(-50%, -46%); }

.pn-pos-bottom-left.pn-show,
.pn-pos-bottom-right.pn-show { transform: translateY(0); }
.pn-pos-top-center.pn-show { transform: translate(-50%, 0); }
.pn-pos-center.pn-show { transform: translate(-50%, -50%); }

.pn-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.45);
	z-index: 2147482999;
}

/* Bar */
.pn-bar {
	left: 0;
	right: 0;
	border-radius: 0;
	padding: 12px 16px;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 14px;
}

.pn-bar-top { top: 0; }
.pn-bar-bottom { bottom: 0; }

.pn-bar .pn-content {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px 14px;
}

.pn-bar .pn-message { margin: 0; }
.pn-bar .pn-title { margin: 0; }
.pn-bar .pn-icon { width: 36px; height: 36px; }

/* Content */
.pn-icon {
	width: 52px;
	height: 52px;
	border-radius: 10px;
	flex: none;
	object-fit: cover;
}

.pn-content { flex: 1; min-width: 0; }

.pn-title {
	margin: 0 0 4px;
	font-size: 16px;
	font-weight: 700;
	color: inherit;
}

.pn-message {
	margin: 0 0 12px;
	color: inherit;
	opacity: 0.9;
}

.pn-topics {
	border: 0;
	margin: 0 0 12px;
	padding: 0;
}

.pn-topics-label {
	font-weight: 600;
	margin-bottom: 4px;
	padding: 0;
}

.pn-topics label {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin: 2px 12px 2px 0;
	cursor: pointer;
}

.pn-topics input { accent-color: var(--pn-primary); }

.pn-actions {
	display: flex;
	gap: 8px;
	justify-content: flex-end;
	flex-wrap: wrap;
}

.pn-btn,
.pn-subscribe-button {
	cursor: pointer;
	border-radius: 8px;
	padding: 9px 15px;
	font: inherit;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.2;
	border: 1px solid transparent;
	transition: filter 0.15s ease, opacity 0.15s ease;
}

.pn-btn-primary,
.pn-subscribe-button {
	background: var(--pn-primary);
	color: #fff;
}

.pn-btn-secondary {
	background: transparent;
	color: var(--pn-text);
	border-color: currentColor;
	opacity: 0.7;
}

.pn-btn:hover,
.pn-subscribe-button:hover { filter: brightness(1.08); }
.pn-btn-secondary:hover { opacity: 1; }

.pn-btn:focus-visible,
.pn-bell:focus-visible,
.pn-subscribe-button:focus-visible {
	outline: 3px solid var(--pn-primary);
	outline-offset: 2px;
}

.pn-subscribe-button[aria-pressed="true"] {
	background: transparent;
	color: var(--pn-primary);
	border-color: var(--pn-primary);
}

/* Bell */
.pn-bell {
	position: fixed;
	bottom: 20px;
	z-index: 2147482998;
	width: 52px;
	height: 52px;
	padding: 0;
	border-radius: 50%;
	border: 0;
	background: var(--pn-primary);
	color: #fff;
	box-shadow: 0 6px 20px rgba(0, 0, 0, 0.22);
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: transform 0.15s ease;
}

.pn-bell:hover { transform: scale(1.06); }
.pn-bell-bottom-right { right: 20px; }
.pn-bell-bottom-left { left: 20px; }

.pn-bell svg {
	width: 26px;
	height: 26px;
	fill: currentColor;
}

.pn-bell-subscribed::after {
	content: "";
	position: absolute;
	top: 9px;
	right: 9px;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: #00a32a;
	border: 2px solid #fff;
}

.pn-bell-denied { opacity: 0.6; }

.pn-bell-panel {
	bottom: 84px;
	width: 300px;
	max-width: calc(100vw - 32px);
	padding: 14px;
}

.pn-bell-panel-bottom-left { left: 20px; }
.pn-bell-panel-bottom-right { right: 20px; }

/* Toast */
.pn-toast {
	position: fixed;
	left: 50%;
	bottom: 24px;
	transform: translate(-50%, 20px);
	opacity: 0;
	transition: opacity 0.3s ease, transform 0.3s ease;
	background: #1d2327;
	color: #fff;
	padding: 11px 16px;
	border-radius: 8px;
	font-size: 14px;
	line-height: 1.4;
	z-index: 2147483001;
	max-width: calc(100vw - 32px);
	box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.pn-toast.pn-show {
	opacity: 1;
	transform: translate(-50%, 0);
}

/* Position: bottom centre */
.pn-pos-bottom-center { left: 50%; bottom: 20px; transform: translate(-50%, 12px); }
.pn-pos-bottom-center.pn-show { transform: translate(-50%, 0); }

/* ---------- Templates (Push Notify › Modelos do convite) ---------- */

/* Faixa colorida */
.pn-theme-faixa { border-top: 5px solid var(--pn-primary); border-radius: 10px; }

/* Destaque central */
.pn-theme-destaque.pn-box { flex-direction: column; align-items: center; text-align: center; width: 410px; padding: 28px 24px 22px; border-radius: 18px; }
.pn-theme-destaque .pn-icon { width: 76px; height: 76px; border-radius: 18px; }
.pn-theme-destaque .pn-title { font-size: 20px; margin-bottom: 6px; }
.pn-theme-destaque .pn-message { margin-bottom: 18px; }
.pn-theme-destaque .pn-actions { justify-content: center; }
.pn-theme-destaque .pn-actions .pn-btn { flex: 1; padding: 11px 15px; }

/* Escuro elegante */
.pn-theme-escuro { border-radius: 16px; box-shadow: 0 14px 44px rgba(0, 0, 0, 0.45); }
.pn-theme-escuro .pn-icon { border-radius: 50%; }
.pn-theme-escuro .pn-btn-secondary { border-color: rgba(255, 255, 255, 0.35); }

/* Minimalista */
.pn-theme-minimo.pn-box { width: auto; max-width: min(620px, calc(100vw - 24px)); padding: 8px 10px 8px 12px; align-items: center; gap: 10px; border-radius: 40px; }
.pn-theme-minimo .pn-icon { width: 34px; height: 34px; border-radius: 50%; }
.pn-theme-minimo .pn-content { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; }
.pn-theme-minimo .pn-title { margin: 0; font-size: 15px; }
.pn-theme-minimo .pn-message { display: none; }
.pn-theme-minimo .pn-btn { border-radius: 30px; padding: 7px 14px; }

/* Barra no topo */
.pn-theme-barra .pn-btn-primary { background: #fff; color: var(--pn-primary); }
.pn-theme-barra .pn-btn-secondary { color: inherit; border-color: rgba(255, 255, 255, 0.6); }
.pn-theme-barra .pn-icon { border-radius: 8px; }

/* Close X (optional, always on when the deny button is hidden) */
.pn-close { position: absolute; top: 6px; right: 8px; background: transparent; border: 0; color: inherit; font: 22px/1 Arial, sans-serif; opacity: 0.55; cursor: pointer; padding: 4px 6px; border-radius: 6px; }
.pn-close:hover, .pn-close:focus-visible { opacity: 1; outline: 2px solid var(--pn-primary); outline-offset: 0; }
.pn-box:has(.pn-close) .pn-content { padding-right: 18px; }
.pn-bar .pn-close, .pn-theme-minimo .pn-close { position: static; padding-right: 2px; }
.pn-theme-destaque .pn-close { top: 10px; right: 12px; }

/* Mobile */
@media (max-width: 600px) {
	.pn-box.pn-pos-bottom-left,
	.pn-box.pn-pos-bottom-right,
	.pn-box.pn-pos-top-center {
		left: 12px;
		right: 12px;
		width: auto;
		max-width: none;
	}

	.pn-box.pn-pos-top-center,
	.pn-box.pn-pos-top-center.pn-show,
	.pn-box.pn-pos-bottom-center,
	.pn-box.pn-pos-bottom-center.pn-show { transform: none; }

	.pn-box.pn-pos-bottom-center { left: 12px; right: 12px; bottom: 12px; max-width: none; }
	.pn-theme-minimo.pn-box { border-radius: 16px; }

	.pn-bar { flex-direction: column; align-items: stretch; text-align: center; }
	.pn-bar .pn-content { justify-content: center; }
	.pn-actions .pn-btn { flex: 1; }
}

@media (prefers-reduced-motion: reduce) {
	.pn-prompt,
	.pn-toast,
	.pn-bell { transition: none; }
}
