/**
 * Hamenagen Premium - שורטקוד [hm_premium_plans]
 * מצב בהיר/כהה: html[data-hm-theme] (כמו שאר האתר)
 */

/* === משתנים - מצב בהיר === */
html[data-hm-theme="light"] .hmp-plans-wrap {
	--hmp-brand: #cb1e53;
	--hmp-accent: #e8a317;
	--hmp-heading: #20215a;
	--hmp-text: #333333;
	--hmp-muted: #666666;
	--hmp-surface: #ffffff;
	--hmp-surface-soft: #f7f6ff;
	--hmp-border: rgba(32, 33, 90, 0.14);
	--hmp-shadow: 0 8px 28px rgba(32, 33, 90, 0.1);
	--hmp-btn-text-on-accent: #111111;
	--hmp-pro: #15803d;
	--hmp-con: #dc2626;
	--hmp-toast-bg: #20215a;
	--hmp-toast-text: #ffffff;
}

/* === משתנים - מצב כהה (ברירת מחדל) === */
html[data-hm-theme="dark"] .hmp-plans-wrap,
html:not([data-hm-theme]) .hmp-plans-wrap {
	--hmp-brand: #cb1e53;
	--hmp-accent: #e8a317;
	--hmp-heading: #ffffff;
	--hmp-text: #f5f5f7;
	--hmp-muted: rgba(245, 245, 247, 0.65);
	--hmp-surface: rgba(255, 255, 255, 0.06);
	--hmp-surface-soft: rgba(255, 255, 255, 0.04);
	--hmp-border: rgba(255, 255, 255, 0.14);
	--hmp-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
	--hmp-btn-text-on-accent: #111111;
	--hmp-pro: #4ade80;
	--hmp-con: #f87171;
	--hmp-toast-bg: #1e1e3a;
	--hmp-toast-text: #ffffff;
}

.hmp-plans-wrap {
	--hmp-font: "פולין", "Polin", sans-serif;
	--hmp-radius: 16px;
	--hmp-radius-pill: 999px;
	max-width: 1100px;
	margin: 0 auto;
	padding: 24px 16px;
	direction: rtl;
	color: var(--hmp-text);
	font-family: var(--hmp-font) !important;
	line-height: 1.5;
}

.hmp-plans-wrap,
.hmp-plans-wrap *,
.hmp-plans-wrap *::before,
.hmp-plans-wrap *::after {
	box-sizing: border-box;
}

.hmp-plans-wrap *,
.hmp-plans-wrap button,
.hmp-plans-wrap a {
	font-family: var(--hmp-font) !important;
}

.hmp-dev-banner {
	background: color-mix(in srgb, var(--hmp-accent) 14%, transparent);
	border: 1px solid color-mix(in srgb, var(--hmp-accent) 55%, transparent);
	border-radius: 10px;
	padding: 10px 14px;
	margin-bottom: 20px;
	text-align: center;
	font-size: 0.9rem;
	color: var(--hmp-text) !important;
}

.hmp-billing-toggle {
	display: flex;
	justify-content: center;
	gap: 8px;
	margin-bottom: 28px;
	flex-wrap: wrap;
}

/* === כפתורי מיתוג חודשי/שנתי - בידוד מלא === */
.hmp-plans-wrap button.hmp-billing-btn {
	-webkit-appearance: none !important;
	appearance: none !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 6px !important;
	margin: 0 !important;
	padding: 10px 20px !important;
	border: 1px solid var(--hmp-border) !important;
	border-radius: var(--hmp-radius-pill) !important;
	background: var(--hmp-surface) !important;
	color: var(--hmp-heading) !important;
	font-size: 0.95rem !important;
	font-weight: 600 !important;
	line-height: 1.3 !important;
	cursor: pointer !important;
	box-shadow: none !important;
	text-transform: none !important;
	letter-spacing: normal !important;
	min-height: 44px !important;
	transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease !important;
}

.hmp-plans-wrap button.hmp-billing-btn:hover {
	border-color: color-mix(in srgb, var(--hmp-brand) 45%, transparent) !important;
	color: var(--hmp-brand) !important;
}

.hmp-plans-wrap button.hmp-billing-btn.is-active {
	background: var(--hmp-accent) !important;
	border-color: var(--hmp-accent) !important;
	color: var(--hmp-btn-text-on-accent) !important;
	font-weight: 700 !important;
}

.hmp-plans-wrap button.hmp-billing-btn.is-active:hover {
	filter: brightness(1.06);
	color: var(--hmp-btn-text-on-accent) !important;
}

.hmp-save-badge {
	display: inline-block;
	font-size: 0.72rem;
	font-weight: 700;
	padding: 2px 8px;
	border-radius: var(--hmp-radius-pill);
	background: color-mix(in srgb, var(--hmp-heading) 12%, transparent);
	color: inherit;
}

html[data-hm-theme="dark"] .hmp-plans-wrap button.hmp-billing-btn.is-active .hmp-save-badge,
html:not([data-hm-theme]) .hmp-plans-wrap button.hmp-billing-btn.is-active .hmp-save-badge {
	background: rgba(0, 0, 0, 0.18);
}

.hmp-plans-grid {
	display: grid;
	gap: 20px;
}

.hmp-cols-1 {
	grid-template-columns: 1fr;
}

.hmp-cols-2 {
	grid-template-columns: repeat(2, 1fr);
}

.hmp-cols-3 {
	grid-template-columns: repeat(3, 1fr);
}

.hmp-cols-4 {
	grid-template-columns: repeat(4, 1fr);
}

.hmp-plans-grid.hmp-cols-1 {
	max-width: 520px;
	margin-inline: auto;
}

@media (max-width: 900px) {

	.hmp-cols-3,
	.hmp-cols-4 {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 600px) {
	.hmp-plans-grid {
		grid-template-columns: 1fr !important;
	}
}

.hmp-plan-card {
	position: relative;
	background: var(--hmp-surface);
	border: 1px solid var(--hmp-border);
	border-radius: var(--hmp-radius);
	padding: 24px 20px;
	display: flex;
	flex-direction: column;
	gap: 14px;
	box-shadow: var(--hmp-shadow);
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.hmp-plan--featured {
	border-color: color-mix(in srgb, var(--hmp-accent) 70%, transparent);
	box-shadow: 0 0 0 1px color-mix(in srgb, var(--hmp-accent) 55%, transparent), var(--hmp-shadow);
}

.hmp-plan-badge {
	position: absolute;
	top: 12px;
	left: 12px;
	background: var(--hmp-accent);
	color: var(--hmp-btn-text-on-accent);
	font-size: 0.75rem;
	font-weight: 700;
	padding: 4px 10px;
	border-radius: var(--hmp-radius-pill);
	line-height: 1.2;
}

.hmp-plan-tier {
	font-size: 0.8rem;
	color: var(--hmp-brand);
	font-weight: 700;
}

.hmp-plan-title {
	margin: 0 !important;
	padding: 0 !important;
	font-size: 1.35rem !important;
	font-weight: 700 !important;
	color: var(--hmp-heading) !important;
	line-height: 1.25 !important;
}

.hmp-plan-desc {
	margin: 0;
	color: var(--hmp-muted) !important;
	font-size: 0.95rem;
	line-height: 1.5;
}

.hmp-plan-prices {
	min-height: 48px;
}

.hmp-price-block {
	display: none;
	align-items: baseline;
	gap: 6px;
	flex-wrap: wrap;
}

.hmp-plans-wrap[data-hmp-default="monthly"] .hmp-price-block[data-period="monthly"],
.hmp-plans-wrap[data-hmp-period="monthly"] .hmp-price-block[data-period="monthly"],
.hmp-plans-wrap[data-hmp-default="yearly"]:not([data-hmp-period="monthly"]) .hmp-price-block[data-period="yearly"],
.hmp-plans-wrap[data-hmp-period="yearly"] .hmp-price-block[data-period="yearly"] {
	display: flex;
}

.hmp-price-old {
	text-decoration: line-through;
	color: var(--hmp-muted) !important;
	font-size: 0.95rem;
}

.hmp-price-current {
	font-size: 2rem;
	font-weight: 800;
	line-height: 1;
	color: var(--hmp-heading) !important;
}

.hmp-price-suffix {
	color: var(--hmp-muted) !important;
	font-size: 0.9rem;
}

.hmp-plan-list {
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

.hmp-plan-list li {
	position: relative;
	padding-right: 22px;
	margin-bottom: 8px;
	font-size: 0.92rem;
	line-height: 1.45;
	color: var(--hmp-text) !important;
}

.hmp-plan-list--pros li::before {
	content: "✓";
	position: absolute;
	right: 0;
	color: var(--hmp-pro);
	font-weight: 700;
}

.hmp-plan-list--cons li::before {
	content: "✕";
	position: absolute;
	right: 0;
	color: var(--hmp-con);
	font-weight: 700;
}

.hmp-plan-actions {
	margin-top: auto;
	padding-top: 8px;
}

/* === כפתורי רכישה / התחברות - בידוד מלא === */
.hmp-plans-wrap button.hmp-plan-btn,
.hmp-plans-wrap a.hmp-plan-btn {
	-webkit-appearance: none !important;
	appearance: none !important;
	display: block !important;
	width: 100% !important;
	text-align: center !important;
	margin: 0 !important;
	padding: 12px 16px !important;
	border-radius: 12px !important;
	border: none !important;
	background: var(--hmp-accent) !important;
	color: var(--hmp-btn-text-on-accent) !important;
	font-size: 1rem !important;
	font-weight: 700 !important;
	line-height: 1.35 !important;
	cursor: pointer !important;
	text-decoration: none !important;
	box-shadow: none !important;
	text-transform: none !important;
	letter-spacing: normal !important;
	min-height: 48px !important;
	transition: filter 0.2s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease !important;
}

.hmp-plans-wrap button.hmp-plan-btn:hover:not(:disabled),
.hmp-plans-wrap a.hmp-plan-btn:hover {
	filter: brightness(1.06);
	color: var(--hmp-btn-text-on-accent) !important;
	text-decoration: none !important;
}

.hmp-plans-wrap button.hmp-plan-btn:disabled {
	opacity: 0.55 !important;
	cursor: not-allowed !important;
	filter: none !important;
}

.hmp-plans-wrap a.hmp-plan-btn--login,
.hmp-plans-wrap button.hmp-plan-btn--login {
	background: transparent !important;
	border: 2px solid var(--hmp-accent) !important;
	color: var(--hmp-accent) !important;
}

html[data-hm-theme="light"] .hmp-plans-wrap a.hmp-plan-btn--login,
html[data-hm-theme="light"] .hmp-plans-wrap button.hmp-plan-btn--login {
	color: #9a7010 !important;
	border-color: #c99212 !important;
}

.hmp-plans-wrap a.hmp-plan-btn--login:hover,
.hmp-plans-wrap button.hmp-plan-btn--login:hover:not(:disabled) {
	background: color-mix(in srgb, var(--hmp-accent) 12%, transparent) !important;
	filter: none !important;
}

.hmp-empty {
	text-align: center;
	padding: 24px;
	color: var(--hmp-muted) !important;
}

.hmp-toast {
	position: fixed;
	bottom: 24px;
	left: 50%;
	transform: translateX(-50%);
	background: var(--hmp-toast-bg);
	color: var(--hmp-toast-text);
	padding: 12px 20px;
	border-radius: 10px;
	z-index: 99999;
	max-width: 90vw;
	text-align: center;
	font-family: var(--hmp-font) !important;
	font-size: 0.95rem;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}