/**
 * סדרת וובינרים — פלטת מותג: #7699f2, #FB8255, #FB6965; רקע אפור־לבן; טיפוגרפיה: Rubik בלבד.
 */

.hpg-webinars-series {
	--hpg-w-orange: #fb8255;
	--hpg-w-coral: #fb6965;
	--hpg-w-blue: #7699f2;
	--hpg-w-blue-soft: #eef1f6;
	--hpg-w-blue-mid: #9db4f5;
	--hpg-w-bg: #eceef2;
	--hpg-w-card: #ffffff;
	--hpg-w-text: #1f2937;
	--hpg-w-muted: #64748b;
	position: relative;
	max-width: 1200px;
	margin: 0 auto;
	padding: 1.5rem 1rem 3rem;
	font-family: "Rubik", "Segoe UI", Tahoma, sans-serif;
	color: var(--hpg-w-text);
	background: linear-gradient(180deg, #fbfbfc 0%, #f1f3f6 42%, #e8eaef 100%);
	border-radius: 0 0 24px 24px;
	overflow: hidden;
}

/* קו עליון עדין (אפור־תכלת, ללא אפרסק) */
.hpg-webinars-series::before {
	content: "";
	position: absolute;
	top: 0;
	right: -5%;
	left: -5%;
	height: 72px;
	pointer-events: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 72' preserveAspectRatio='none'%3E%3Cpath d='M0,48 C280,12 520,62 780,28 C980,2 1100,38 1200,22 L1200,0 L0,0 Z' fill='%23e2e8f0' opacity='0.85'/%3E%3Cpath d='M0,58 C300,35 540,68 820,40 C980,28 1080,52 1200,45 L1200,0 L0,0 Z' fill='none' stroke='%237699f2' stroke-width='0.6' opacity='0.2'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: top center;
	background-size: 100% 72px;
	z-index: 0;
}

.hpg-webinars-series > * {
	position: relative;
	z-index: 1;
}

.hpg-webinars-hero {
	background: linear-gradient(145deg, #ffffff 0%, #f7f8fa 100%);
	border-radius: 16px;
	padding: 2rem 1.75rem;
	box-shadow: 0 6px 28px rgba(31, 41, 55, 0.06);
	margin-bottom: 1.25rem;
	border: 1px solid rgba(118, 153, 242, 0.18);
}

.hpg-webinars-hero__keys-slot {
	display: flex;
	justify-content: flex-start;
	margin: 0 0 1rem;
	width: 100%;
}

.hpg-webinars-hero__title {
	margin: 0 0 0.65rem;
	font-family: "Rubik", "Segoe UI", sans-serif;
	font-size: clamp(1.5rem, 3.4vw, 2.15rem);
	line-height: 1.22;
	font-weight: 900;
	color: var(--hpg-w-blue);
	letter-spacing: -0.02em;
}

.hpg-webinars-hero__lead {
	margin: 0 0 1.25rem;
	font-size: clamp(1.05rem, 2vw, 1.22rem);
	font-weight: 700;
	color: var(--hpg-w-orange);
	line-height: 1.45;
}

.hpg-webinars-hero__text {
	margin: 0;
}

.hpg-webinars-hero__chunk {
	margin: 0 0 1rem;
	line-height: 1.75;
	color: var(--hpg-w-muted);
	font-size: 1rem;
	font-weight: 400;
}

.hpg-webinars-hero__chunk:last-child {
	margin-bottom: 0;
}

.hpg-webinars-hero__chunk--intro {
	font-size: 1.05rem;
	color: var(--hpg-w-text);
}

.hpg-webinars-hero__em {
	font-weight: 700;
	color: var(--hpg-w-blue);
}

.hpg-webinars-hero__strong {
	font-weight: 800;
	color: var(--hpg-w-orange);
}

.hpg-webinars-hero__accent {
	font-weight: 700;
	color: var(--hpg-w-blue);
	font-size: 1.05rem;
}

.hpg-webinars-hero__chunk--closing {
	font-size: 0.98rem;
}

.hpg-webinars-hero__bigline {
	display: block;
	margin-top: 0.35rem;
	font-size: 1.12rem;
	font-weight: 700;
	color: var(--hpg-w-text);
	line-height: 1.45;
}

/* שורת יעד בלבד — רוחב מרוכז */
.hpg-webinars-stats-row {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	margin-bottom: 2rem;
	max-width: 640px;
	margin-left: auto;
	margin-right: auto;
}

.hpg-webinars-progress {
	text-align: center;
	padding: 1.35rem 1.15rem;
	background: #fff;
	border-radius: 14px;
	border: 1px solid rgba(118, 153, 242, 0.2);
	box-shadow: 0 4px 20px rgba(31, 41, 55, 0.05);
	margin-bottom: 0;
}

.hpg-webinars-progress__big {
	font-size: clamp(2rem, 5vw, 2.85rem);
	font-weight: 800;
	font-family: "Rubik", "Segoe UI", sans-serif;
	color: var(--hpg-w-blue);
	line-height: 1;
	font-variant-numeric: tabular-nums;
}

.hpg-webinars-progress__track {
	height: 12px;
	border-radius: 999px;
	background: #e8ecf2;
	margin: 0.85rem auto 0;
	max-width: 420px;
	overflow: hidden;
	box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.06);
}

.hpg-webinars-progress__fill {
	display: block;
	height: 100%;
	border-radius: inherit;
	background: linear-gradient(90deg, var(--hpg-w-blue) 0%, var(--hpg-w-orange) 72%, var(--hpg-w-coral) 100%);
	box-shadow: 0 0 12px rgba(118, 153, 242, 0.35);
	transition: width 0.6s ease;
}

.hpg-webinars-progress__sub {
	margin: 0.75rem 0 0;
	font-size: 0.9rem;
	color: var(--hpg-w-muted);
	font-weight: 500;
}

/* מפתחות — ברירת מחדל (אם יופיעו מחוץ לקומפקט) */
.hpg-webinars-keys {
	margin-bottom: 0;
	background: var(--hpg-w-card);
	border-radius: 14px;
	padding: 0;
	border: 1px solid rgba(118, 153, 242, 0.18);
	box-shadow: 0 4px 18px rgba(0, 0, 0, 0.04);
}

.hpg-webinars-keys__inner {
	display: flex;
	flex-direction: column;
	gap: 0.85rem;
	padding: 1rem 1.15rem;
}

.hpg-webinars-keys__balance {
	display: flex;
	align-items: flex-start;
	gap: 0.6rem;
}

.hpg-webinars-keys__icon {
	font-size: 1.35rem;
	line-height: 1;
	flex-shrink: 0;
}

.hpg-webinars-keys__heading {
	display: block;
	font-size: 0.95rem;
	font-weight: 700;
	color: var(--hpg-w-blue);
	margin-bottom: 0.2rem;
}

.hpg-webinars-keys__line {
	margin: 0;
	font-size: 0.82rem;
	line-height: 1.4;
	color: var(--hpg-w-muted);
	font-weight: 400;
}

.hpg-webinars-keys__cta {
	width: 100%;
}

.hpg-webinars-keys__upload {
	display: block;
	width: 100%;
	text-align: center;
	padding: 0.55rem 1rem;
	border-radius: 999px;
	background: var(--hpg-w-orange);
	color: #fff !important;
	border: none;
	font-weight: 600;
	cursor: pointer;
	text-decoration: none;
	font-size: 0.88rem;
	font-family: inherit;
	box-shadow: 0 2px 10px rgba(251, 130, 85, 0.28);
}

.hpg-webinars-keys__upload:hover {
	filter: brightness(1.04);
}

/* שבב מפתחות קטן בראש העמוד */
.hpg-webinars-keys--compact {
	background: rgba(118, 153, 242, 0.09);
	border: 1px solid rgba(118, 153, 242, 0.22);
	box-shadow: none;
	border-radius: 12px;
	max-width: 100%;
	align-self: flex-start;
}

.hpg-webinars-keys--compact .hpg-webinars-keys__inner {
	flex-direction: row;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-start;
	gap: 0.5rem 0.75rem;
	padding: 0.4rem 0.65rem;
}

.hpg-webinars-keys--compact .hpg-webinars-keys__balance {
	align-items: center;
	gap: 0.45rem;
	flex: 1 1 auto;
	min-width: 0;
}

.hpg-webinars-keys--compact .hpg-webinars-keys__icon {
	font-size: 1.1rem;
}

.hpg-webinars-keys--compact .hpg-webinars-keys__text {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0.08rem;
	text-align: right;
	min-width: 0;
}

.hpg-webinars-keys--compact .hpg-webinars-keys__heading {
	font-size: 0.78rem;
	font-weight: 700;
	margin: 0;
}

.hpg-webinars-keys--compact .hpg-webinars-keys__line {
	font-size: 0.72rem;
	margin: 0;
	line-height: 1.35;
}

.hpg-webinars-keys--compact .hpg-webinars-keys__cta {
	width: auto;
	flex: 0 0 auto;
}

.hpg-webinars-keys--compact .hpg-webinars-keys__upload {
	width: auto;
	display: inline-block;
	padding: 0.32rem 0.65rem;
	font-size: 0.72rem;
	font-weight: 700;
	box-shadow: 0 1px 6px rgba(251, 105, 101, 0.25);
}

@media (max-width: 520px) {
	.hpg-webinars-keys--compact .hpg-webinars-keys__inner {
		flex-direction: column;
		align-items: stretch;
		text-align: center;
	}

	.hpg-webinars-keys--compact .hpg-webinars-keys__balance {
		justify-content: center;
	}

	.hpg-webinars-keys--compact .hpg-webinars-keys__text {
		align-items: center;
		text-align: center;
	}

	.hpg-webinars-keys--compact .hpg-webinars-keys__upload {
		width: 100%;
	}
}

@media (max-width: 899px) {
	.hpg-webinars-keys:not(.hpg-webinars-keys--compact) .hpg-webinars-keys__inner {
		text-align: center;
	}

	.hpg-webinars-keys:not(.hpg-webinars-keys--compact) .hpg-webinars-keys__balance {
		justify-content: center;
	}
}

.hpg-webinars-section-title {
	font-family: "Rubik", "Segoe UI", sans-serif;
	font-size: 1.35rem;
	margin: 0 0 1rem;
	padding-bottom: 0.5rem;
	border-bottom: 2px solid rgba(118, 153, 242, 0.25);
	color: var(--hpg-w-blue);
	font-weight: 800;
}

.hpg-webinars-next {
	margin-bottom: 2rem;
}

.hpg-webinars-next--compact {
	max-width: 880px;
	margin-left: auto;
	margin-right: auto;
}

.hpg-webinars-next__card .hpg-webinar-card--featured {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 1rem 1.25rem;
	align-items: stretch;
	padding: 0;
	overflow: hidden;
	border-radius: 14px;
	box-shadow: 0 8px 28px rgba(30, 107, 184, 0.08);
	background: var(--hpg-w-card);
	border: 1px solid rgba(30, 107, 184, 0.1);
}

.hpg-webinars-next--compact .hpg-webinars-next__card .hpg-webinar-card--featured .hpg-webinar-card__body {
	padding: 0.85rem 1rem 1rem;
}

.hpg-webinars-next--compact .hpg-webinar-card--featured .hpg-webinar-card__title {
	font-size: 1.1rem;
	line-height: 1.3;
}

.hpg-webinars-next__card .hpg-webinar-card--featured .hpg-webinar-card__media {
	min-height: 0;
	max-height: 240px;
	aspect-ratio: 4 / 3;
}

.hpg-webinars-next__card .hpg-webinar-card--featured .hpg-webinar-card__media img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	object-position: center;
}

.hpg-webinars-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: 1.25rem;
}

.hpg-webinars-grid--past {
	margin-top: 0.5rem;
}

.hpg-webinar-card {
	position: relative;
	background: var(--hpg-w-card);
	border-radius: 14px;
	overflow: hidden;
	box-shadow: 0 6px 24px rgba(30, 107, 184, 0.07);
	display: flex;
	flex-direction: column;
	height: 100%;
	border: 1px solid rgba(30, 107, 184, 0.08);
}

.hpg-webinar-card__media {
	position: relative;
	overflow: hidden;
	background: #eef3f8;
	display: flex;
	align-items: center;
	justify-content: center;
}

/* סרט אלכסון "לא סופי" — פינת ה-inline-end (בעברית: שמאל למעלה של התמונה) */
.hpg-webinar-card__ribbon {
	position: absolute;
	top: 20px;
	inset-inline-end: -40px;
	inset-inline-start: auto;
	z-index: 4;
	width: 160px;
	padding: 6px 0;
	text-align: center;
	background: linear-gradient(135deg, #7699f2 0%, #5c7fd9 100%);
	color: #fff;
	font-size: 0.68rem;
	font-weight: 800;
	letter-spacing: 0.04em;
	transform: rotate(35deg);
	transform-origin: center;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
	pointer-events: none;
	line-height: 1.2;
}

.hpg-webinar-card__ribbon-text {
	display: block;
	padding: 0 0.25rem;
}

.hpg-webinar-card--grid .hpg-webinar-card__media,
.hpg-webinar-card--past .hpg-webinar-card__media {
	height: 160px;
}

.hpg-webinar-card__media img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	object-position: center;
	display: block;
}

.hpg-webinar-card__placeholder {
	width: 100%;
	height: 100%;
	min-height: 140px;
	background: linear-gradient(120deg, #e8f2fa 25%, #f0f7fc 50%, #e8f2fa 75%);
	background-size: 200% 100%;
}

.hpg-skeleton-pulse {
	animation: hpg-skel 1.2s ease-in-out infinite;
}

@keyframes hpg-skel {
	0% {
		opacity: 0.55;
	}
	50% {
		opacity: 1;
	}
	100% {
		opacity: 0.55;
	}
}

.hpg-skeleton-line {
	height: 14px;
	border-radius: 6px;
	background: #e2edf5;
	margin-bottom: 0.5rem;
}

.hpg-skeleton-line--short {
	width: 60%;
}

.hpg-webinar-card__body {
	padding: 1rem 1.1rem 1.25rem;
	flex: 1;
	display: flex;
	flex-direction: column;
}

.hpg-webinar-card__title {
	margin: 0 0 0.35rem;
	font-size: 1.05rem;
	line-height: 1.35;
	font-weight: 700;
}

.hpg-webinar-card__desc {
	margin: 0 0 0.65rem;
	font-size: 0.88rem;
	line-height: 1.55;
	color: var(--hpg-w-muted);
	font-weight: 400;
}

.hpg-webinar-card--featured .hpg-webinar-card__desc {
	font-size: 0.93rem;
	max-height: none;
}

.hpg-webinar-card__lecturer {
	margin: 0 0 0.5rem;
	font-size: 0.9rem;
	color: var(--hpg-w-blue);
	font-weight: 600;
}

.hpg-webinar-card__when {
	margin: 0 0 0.5rem;
	font-size: 0.88rem;
	color: var(--hpg-w-muted);
	display: flex;
	gap: 0.5rem;
	flex-wrap: wrap;
}

.hpg-webinar-card__lecturer-photo {
	margin: 0.25rem 0 0.5rem;
}

.hpg-webinar-card__lecturer-photo-inner {
	display: block;
	width: 52px;
	height: 52px;
	border-radius: 50%;
	overflow: hidden;
	border: 2px solid #fff;
	box-shadow: 0 2px 8px rgba(30, 107, 184, 0.15);
	flex-shrink: 0;
	background: #e8f2fa;
}

.hpg-webinar-card__lecturer-photo-inner img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	display: block;
}

.hpg-webinar-card__reg {
	margin: auto 0 0.75rem;
	font-size: 0.82rem;
	color: var(--hpg-w-muted);
}

.hpg-webinar-register-wrap {
	display: inline-block;
}

.hpg-webinar-register-wrap--no-keys {
	cursor: help;
}

.hpg-webinar-card__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.45rem;
	position: relative;
	z-index: 2;
}

.hpg-webinar-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.45rem 0.75rem;
	border-radius: 10px;
	font-size: 0.82rem;
	font-weight: 600;
	text-decoration: none;
	border: 1px solid #e2e8f0;
	background: #fff;
	color: var(--hpg-w-text);
	cursor: pointer;
	font-family: inherit;
	line-height: 1.2;
	position: relative;
	z-index: 2;
	touch-action: manipulation;
}

.hpg-webinar-btn--primary {
	background: var(--hpg-w-orange);
	color: #fff !important;
	border-color: var(--hpg-w-orange);
}

.hpg-webinar-btn--primary:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

.hpg-webinar-btn--meet {
	border-color: rgba(30, 107, 184, 0.35);
	color: var(--hpg-w-blue);
}

.hpg-webinar-btn--done {
	background: #e8f4fc;
	color: var(--hpg-w-blue);
	border-color: rgba(30, 107, 184, 0.45);
	cursor: default;
}

.hpg-webinar-card--skeleton .hpg-webinar-card__soon {
	margin: 0.5rem 0 0;
	font-weight: 700;
	color: var(--hpg-w-muted);
}

.hpg-webinars-divider {
	display: flex;
	align-items: center;
	gap: 1rem;
	margin: 3rem 0 1.5rem;
}

.hpg-webinars-divider__line {
	flex: 1;
	height: 2px;
	background: linear-gradient(90deg, transparent, rgba(30, 107, 184, 0.35), transparent);
}

.hpg-webinars-divider__label {
	font-weight: 800;
	font-size: 1.1rem;
	color: var(--hpg-w-muted);
	white-space: nowrap;
}

.hpg-webinars-past__empty {
	text-align: center;
	color: var(--hpg-w-muted);
	padding: 1rem;
}

.hpg-webinar-msg {
	margin-top: 0.35rem;
	font-size: 0.85rem;
	color: var(--hpg-w-orange);
	min-height: 1.2em;
}

@media (max-width: 768px) {
	.hpg-webinars-next__card .hpg-webinar-card--featured {
		grid-template-columns: 1fr;
	}
}
