/* APK365 download popup + contact form */
.apk365-popup[hidden] {
	display: none !important;
}

.apk365-popup {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
}

.apk365-popup__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, 0.55);
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px);
}

.apk365-popup__dialog {
	position: relative;
	width: min(100%, 400px);
	background: #fff;
	border-radius: 20px;
	padding: 28px 24px 22px;
	box-shadow: 0 24px 48px rgba(15, 23, 42, 0.22);
	text-align: center;
	animation: apk365-pop 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes apk365-pop {
	from {
		opacity: 0;
		transform: translateY(16px) scale(0.96);
	}
	to {
		opacity: 1;
		transform: none;
	}
}

.apk365-popup__close {
	position: absolute;
	top: 10px;
	right: 12px;
	width: 36px;
	height: 36px;
	border: 0;
	background: transparent;
	font-size: 28px;
	line-height: 1;
	color: #64748b;
	cursor: pointer;
	border-radius: 8px;
}

.apk365-popup__close:hover,
.apk365-popup__close:focus {
	background: #f1f5f9;
	color: #0f172a;
	outline: none;
}

.apk365-popup__icon {
	margin: 0 auto 14px;
	width: 56px;
	height: 56px;
}

.apk365-popup__title {
	margin: 0 0 8px;
	font-size: 1.35rem;
	font-weight: 700;
	color: #0f172a;
	line-height: 1.3;
}

.apk365-popup__text {
	margin: 0 0 20px;
	font-size: 0.95rem;
	line-height: 1.55;
	color: #475569;
}

.apk365-popup__actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.apk365-popup__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 46px;
	padding: 10px 18px;
	border-radius: 12px;
	font-size: 0.95rem;
	font-weight: 600;
	text-decoration: none !important;
	border: 2px solid transparent;
	cursor: pointer;
	transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.apk365-popup__btn:hover {
	transform: translateY(-1px);
}

.apk365-popup__btn--primary {
	background: #1bbc9b;
	color: #fff !important;
	box-shadow: 0 8px 20px rgba(27, 188, 155, 0.35);
}

.apk365-popup__btn--primary:hover,
.apk365-popup__btn--primary:focus {
	background: #17a589;
	color: #fff !important;
}

.apk365-popup__btn--ghost {
	background: #f8fafc;
	color: #334155 !important;
	border-color: #e2e8f0;
}

.apk365-popup__btn--ghost:hover,
.apk365-popup__btn--ghost:focus {
	background: #f1f5f9;
}

.apk365-popup__note {
	margin: 14px 0 0;
	font-size: 0.75rem;
	color: #94a3b8;
	line-height: 1.4;
}

body.apk365-in-app .apk365-popup {
	display: none !important;
}

.apk365-contact-form label {
	font-weight: 600;
	font-size: 0.9rem;
}

.apk365-contact-form input,
.apk365-contact-form textarea {
	width: 100%;
	max-width: 520px;
	margin-top: 6px;
	padding: 10px 12px;
	border: 1px solid #cbd5e1;
	border-radius: 10px;
	font: inherit;
	box-sizing: border-box;
}

.apk365-contact-form input:focus,
.apk365-contact-form textarea:focus {
	outline: 2px solid #1bbc9b;
	border-color: #1bbc9b;
}

.apk365-toast {
	position: fixed;
	bottom: 24px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 100000;
	padding: 12px 20px;
	border-radius: 10px;
	color: #fff;
	font-weight: 600;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
	animation: apk365-pop 0.3s ease;
}

.apk365-toast--ok {
	background: #059669;
}

.apk365-toast--err {
	background: #dc2626;
}

/* Subtle modern polish for legal pages */
.entry .apk365-popup__btn {
	margin: 8px 0 16px;
}
