.hnp-wrapper {
	--hnp-accent: #8b5cf6;
	--hnp-accent-glow: rgba(139, 92, 246, 0.45);
	--hnp-bg: #000;
	--hnp-ui: rgba(17, 17, 17, 0.94);
	--hnp-ui-border: rgba(255, 255, 255, 0.08);
	position: relative;
	width: 100%;
	max-width: 100%;
	background: var(--hnp-bg);
	font-family: "BPG Nino Medium Caps", 'HNP Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55);
	-webkit-font-smoothing: antialiased;
}

.hnp-video-container {
	position: relative;
	width: 100%;
	/* --hnp-aspect დინამიურად ეწერება ვიდეოს რეალური პროპორციით
	   (იხ. applyVideoAspect). ultrawide მასალაზე 16/9 კონტეინერი
	   ზედმეტ შავ ზოლებს ქმნიდა და პლეერი ძალიან მაღალი გამოდიოდა. */
	aspect-ratio: var(--hnp-aspect, 16 / 9);
	max-height: var(--hnp-max-height, 78vh);
	background-color: #000;
	background-size: cover;
	background-position: center center;
	background-repeat: no-repeat;
}

/* დაკვრის დაწყებისას background აღარ გვჭირდება */
.hnp-video-container.hnp-started {
	background-image: none !important;
}

.hnp-video {
	width: 100%;
	height: 100%;
	display: block;
	background: transparent;
}

/* poster ცალკე ფენად — ვიდეოს ზემოთ, კონტროლების ქვემოთ.
   ასე მას ვერც პირველი შავი კადრი და ვერც სხვა CSS წესი ფარავს. */
.hnp-poster {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background-size: cover;
	background-position: center center;
	background-repeat: no-repeat;
	background-color: #000;
	z-index: 1;
	pointer-events: none;
	opacity: 1;
	transition: opacity 0.25s ease;
}

.hnp-poster.hnp-poster-hidden {
	opacity: 0;
}

/* ---------- Top bar ---------- */

.hnp-top-bar {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
	padding: 22px 28px;
	background: linear-gradient(to bottom, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0) 100%);
	opacity: 0;
	transform: translateY(-6px);
	transition: opacity 0.28s ease, transform 0.28s ease;
	z-index: 6;
	pointer-events: none;
}

.hnp-video-container.hnp-show-ui .hnp-top-bar,
.hnp-video-container:not(.hnp-playing) .hnp-top-bar {
	opacity: 1;
	transform: translateY(0);
}

.hnp-top-left {
	display: flex;
	align-items: center;
	gap: 12px;
	min-width: 0;
}

.hnp-title-text {
	color: #fff;
	font-size: 19px;
	font-weight: 700;
	letter-spacing: 0.1px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	max-width: 55vw;
}

.hnp-badge {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	font-size: 10.5px;
	font-weight: 700;
	letter-spacing: 0.4px;
	padding: 4px 9px;
	border-radius: 4px;
	background: rgba(255, 255, 255, 0.12);
	color: #fff;
	border: 1px solid rgba(255, 255, 255, 0.15);
	white-space: nowrap;
}

.hnp-badge-hevc {
	background: rgba(139, 92, 246, 0.18);
	border-color: rgba(139, 92, 246, 0.4);
	color: #ff6a70;
}

.hnp-audio-indicator {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-size: 12px;
	font-weight: 500;
	color: rgba(255, 255, 255, 0.85);
	background: rgba(0, 0, 0, 0.35);
	border: 1px solid var(--hnp-ui-border);
	border-radius: 20px;
	padding: 5px 12px 5px 10px;
	white-space: nowrap;
}

.hnp-audio-indicator .hnp-pulse-dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: #2ecc71;
	animation: hnp-pulse 2s infinite;
	flex-shrink: 0;
}

@keyframes hnp-pulse {
	0% { box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.55); }
	70% { box-shadow: 0 0 0 6px rgba(46, 204, 113, 0); }
	100% { box-shadow: 0 0 0 0 rgba(46, 204, 113, 0); }
}

.hnp-audio-indicator b {
	color: #fff;
	font-weight: 700;
	letter-spacing: 0.3px;
}

/* ---------- Spinner ---------- */

/* სამი წერტილი, დაკვრის ღილაკის ადგილას (იგივე ოპტიკური აწევა).
   ცენტრში ყოველთვის ერთი რამ ჩანს: დაკვრისას ჩატვირთვაზე — წერტილები,
   პაუზაზე — ▷ ღილაკი. მოკლე (<0.4 წმ) ჩატვირთვაზე არაფერი ციმციმებს.
   ძველი რგოლი + „იტვირთება...": backups\2026-10-07-loading-dots */
.hnp-spinner {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, calc(-50% - 14px));
	display: none;
	z-index: 5;
	pointer-events: none;
}

.hnp-video-container.hnp-buffering.hnp-playing .hnp-spinner {
	display: block;
	animation: hnp-spinner-in 0.2s ease 0.4s both;
}

/* რგოლის ელემენტი = შუა წერტილი, ::before/::after = გვერდითები */
.hnp-spinner-ring {
	position: relative;
	width: 10px;
	height: 10px;
	margin: 0 23px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 1px 6px rgba(0, 0, 0, 0.5);
	animation: hnp-dot 1.1s ease-in-out 0.18s infinite;
}
.hnp-spinner-ring::before,
.hnp-spinner-ring::after {
	content: "";
	position: absolute;
	top: 0;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 1px 6px rgba(0, 0, 0, 0.5);
	animation: hnp-dot 1.1s ease-in-out infinite;
}
.hnp-spinner-ring::before { left: -21px; }
.hnp-spinner-ring::after { left: 21px; animation-delay: 0.36s; }

.hnp-spinner-text { display: none; }

@keyframes hnp-dot {
	0%, 100% { opacity: 0.25; transform: translateY(0); }
	40% { opacity: 1; transform: translateY(-4px); }
}
@keyframes hnp-spinner-in { from { opacity: 0; } to { opacity: 1; } }

/* ჩატვირთვისას ▷/‖ ღილაკი ქრება იმავე მომენტში, როცა წერტილები ჩნდება */
.hnp-video-container.hnp-buffering.hnp-playing .hnp-big-play {
	animation: hnp-bp-yield 0.15s ease 0.4s forwards;
}
@keyframes hnp-bp-yield { to { opacity: 0; } }

@media (max-width: 768px) {
	.hnp-spinner { transform: translate(-50%, calc(-50% - 10px)); }
	.hnp-spinner-ring { width: 8px; height: 8px; margin: 0 18px; }
	.hnp-spinner-ring::before,
	.hnp-spinner-ring::after { width: 8px; height: 8px; }
	.hnp-spinner-ring::before { left: -17px; }
	.hnp-spinner-ring::after { left: 17px; }
}

@media (prefers-reduced-motion: reduce) {
	.hnp-spinner-ring,
	.hnp-spinner-ring::before,
	.hnp-spinner-ring::after { animation: none; opacity: 0.8; }
}

/* ---------- Big play button ---------- */

.hnp-big-play {
	position: absolute;
	z-index: 3;
	/* ქვედა კონტროლების ზოლი ვიზუალურ წონას ქვემოთ წევს და ღილაკი
	   ჩამოწეულად აღიქმება, თუმცა გეომეტრიულად ზუსტად შუაშია.
	   --hnp-play-nudge ამას ასწორებს — შესაცვლელად მხოლოდ ეს ციფრია. */
	--hnp-play-nudge: -14px;
	top: 50%;
	left: 50%;
	/* --hnp-play-nudge — ოპტიკური კორექცია; hover-ზეც იგივე ფორმულაა,
	   თორემ გადიდებისას ღილაკი ადგილს იცვლიდა. */
	transform: translate(-50%, calc(-50% + var(--hnp-play-nudge, 0px)));
	width: 76px;
	height: 76px;
	padding: 0;
	background: none;
	border: 0;
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: transform 0.18s cubic-bezier(.34,1.56,.64,1);
	z-index: 4;
	-webkit-tap-highlight-color: transparent;
}

.hnp-big-play:hover {
	transform: translate(-50%, calc(-50% + var(--hnp-play-nudge, 0px))) scale(1.08);
}

/* გაწყვეტილი სამკუთხედი ↔ პაუზის ნიშანი + იისფერი ნათება.
   მდგომარეობას JS ცვლის (hnp-bp-to-pause / hnp-bp-to-play, იხ. bindControls).
   ძველი მრგვალი ღილაკის ასლი: backups\2026-10-07-big-play-morph */
.hnp-big-play .hnp-bp-svg {
	width: 64px;
	height: 64px;
	overflow: visible;
	filter: drop-shadow(0 1px 6px rgba(0, 0, 0, 0.55));
}
.hnp-bp-tri,
.hnp-bp-pause,
.hnp-bp-glow {
	transform-box: fill-box;
	transform-origin: center;
}
.hnp-bp-tri path {
	fill: none;
	stroke: currentColor;
	stroke-width: 1.7;
	stroke-linecap: round;
	stroke-linejoin: round;
	stroke-dasharray: 86 14;
	transition: stroke 0.2s ease;
}
.hnp-big-play:hover .hnp-bp-tri path { stroke: var(--hnp-accent); }
.hnp-bp-pause { opacity: 0; }
.hnp-bp-pause rect { fill: currentColor; }
.hnp-bp-glow { fill: var(--hnp-accent); opacity: 0; }

/* დაკვრა: ▷ → ‖, ნათება, შემდეგ ქრება */
.hnp-big-play.hnp-bp-to-pause .hnp-bp-tri { animation: hnp-bp-tri-out 0.3s ease forwards; }
.hnp-big-play.hnp-bp-to-pause .hnp-bp-pause { animation: hnp-bp-pause-in 0.3s ease 0.05s forwards, hnp-bp-fade-away 0.3s ease 0.75s forwards; }
/* პაუზა: ‖ → ▷, ნათება, ▷ რჩება */
.hnp-big-play.hnp-bp-to-play .hnp-bp-pause { animation: hnp-bp-pause-show 0.25s ease forwards, hnp-bp-pause-out 0.3s ease 0.45s forwards; }
.hnp-big-play.hnp-bp-to-play .hnp-bp-tri { opacity: 0; animation: hnp-bp-tri-in 0.35s cubic-bezier(.34,1.56,.64,1) 0.5s forwards; }
.hnp-big-play.hnp-bp-to-pause .hnp-bp-glow,
.hnp-big-play.hnp-bp-to-play .hnp-bp-glow { animation: hnp-bp-glow 0.6s ease-out; }

@keyframes hnp-bp-tri-out { to { opacity: 0; transform: scale(0.6) rotate(90deg); } }
@keyframes hnp-bp-tri-in { from { opacity: 0; transform: scale(0.6) rotate(-90deg); } to { opacity: 1; transform: none; } }
@keyframes hnp-bp-pause-in { from { opacity: 0; transform: scale(0.6) rotate(-90deg); } to { opacity: 1; transform: none; } }
@keyframes hnp-bp-pause-show { from { opacity: 0; transform: scale(0.8); } to { opacity: 1; transform: none; } }
@keyframes hnp-bp-pause-out { to { opacity: 0; transform: scale(0.6) rotate(90deg); } }
@keyframes hnp-bp-fade-away { from { opacity: 1; } to { opacity: 0; transform: scale(1.15); } }
@keyframes hnp-bp-glow { 0% { opacity: 0.55; transform: scale(0.4); } 100% { opacity: 0; transform: scale(1.6); } }

/* დაკვრისას ღილაკი ანიმაციას ასრულებს და მერე „ქრება" — display:none
   ანიმაციას ვერ აჩვენებდა. დაჭერას აღარ იჭერს: ვიდეოზე დაჭერა პაუზაა. */
.hnp-video-container.hnp-playing .hnp-big-play {
	pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
	.hnp-big-play .hnp-bp-tri,
	.hnp-big-play .hnp-bp-pause,
	.hnp-big-play .hnp-bp-glow { animation-duration: 0.01s !important; animation-delay: 0s !important; }
}

/* ---------- Toast ---------- */

.hnp-toast {
	position: absolute;
	top: 22px;
	left: 50%;
	transform: translate(-50%, -10px);
	background: rgba(17, 17, 17, 0.95);
	border: 1px solid var(--hnp-ui-border);
	color: #fff;
	font-size: 13px;
	font-weight: 600;
	padding: 9px 18px;
	border-radius: 24px;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.2s ease, transform 0.2s ease;
	z-index: 8;
	white-space: nowrap;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

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

.hnp-toast.hnp-toast-warning {
	white-space: normal;
	max-width: 320px;
	text-align: center;
	line-height: 1.45;
	font-weight: 600;
	background: rgba(46, 24, 8, 0.97);
	border-color: rgba(255, 159, 10, 0.4);
	color: #ffd9a0;
}

/* ---------- Bottom controls ---------- */

.hnp-controls {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	padding: 8px 24px 16px;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.88) 0%, rgba(0, 0, 0, 0.55) 50%, rgba(0, 0, 0, 0) 100%);
	opacity: 0;
	transform: translateY(10px);
	transition: opacity 0.28s ease, transform 0.28s ease;
	z-index: 6;
}

.hnp-video-container.hnp-show-ui .hnp-controls,
.hnp-video-container:not(.hnp-playing) .hnp-controls {
	opacity: 1;
	transform: translateY(0);
}

.hnp-progress-row {
	position: relative;
	padding: 4px 2px 12px;
}

.hnp-progress {
	position: relative;
	height: 4px;
	border-radius: 2px;
	background: rgba(255, 255, 255, 0.22);
	cursor: pointer;
	transition: height 0.12s ease;
}

.hnp-progress:hover {
	height: 6px;
}

.hnp-progress-buffered,
.hnp-progress-played {
	position: absolute;
	top: 0;
	left: 0;
	height: 100%;
	border-radius: 2px;
}

.hnp-progress-buffered {
	background: rgba(255, 255, 255, 0.38);
	width: 0%;
}

.hnp-progress-played {
	background: var(--hnp-accent);
	width: 0%;
	box-shadow: 0 0 8px var(--hnp-accent-glow);
}

.hnp-progress-handle {
	position: absolute;
	top: 50%;
	left: 0%;
	width: 13px;
	height: 13px;
	border-radius: 50%;
	background: var(--hnp-accent);
	box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.25);
	transform: translate(-50%, -50%) scale(0);
	transition: transform 0.12s ease;
}

.hnp-progress:hover .hnp-progress-handle {
	transform: translate(-50%, -50%) scale(1);
}

.hnp-seek-tooltip {
	position: absolute;
	bottom: 20px;
	transform: translateX(-50%);
	background: rgba(10, 10, 10, 0.95);
	border: 1px solid var(--hnp-ui-border);
	color: #fff;
	font-size: 11.5px;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	padding: 4px 8px;
	border-radius: 4px;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.12s ease;
	white-space: nowrap;
}

.hnp-progress-row:hover .hnp-seek-tooltip {
	opacity: 1;
}

/* გადახვევის მინიატურა (thumbs/thumbs.vtt) — დროის ზემოთ */
.hnp-seek-thumb {
	position: absolute;
	bottom: 50px;
	transform: translateX(-50%);
	display: none;
	background-color: #000;
	background-repeat: no-repeat;
	border: 2px solid rgba(255, 255, 255, 0.9);
	border-radius: 6px;
	box-shadow: 0 6px 22px rgba(0, 0, 0, 0.6);
	pointer-events: none;
}

.hnp-progress-row:hover .hnp-seek-thumb.has-img {
	display: block;
}

.hnp-controls-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}

.hnp-controls-left,
.hnp-controls-right {
	display: flex;
	align-items: center;
	gap: 2px;
}

.hnp-btn {
	background: transparent;
	border: none;
	color: #fff;
	width: 38px;
	height: 38px;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	border-radius: 6px;
	opacity: 0.92;
	transition: opacity 0.15s ease, background 0.15s ease, transform 0.1s ease;
	position: relative;
	padding: 0;
}

.hnp-btn:hover {
	opacity: 1;
	background: rgba(255, 255, 255, 0.14);
}

.hnp-btn:active {
	transform: scale(0.92);
}

.hnp-btn svg {
	transition: transform 0.18s cubic-bezier(.34,1.56,.64,1);
}

.hnp-btn:hover svg {
	transform: scale(1.1);
}

.hnp-settings-btn:hover svg {
	transform: rotate(45deg);
}

.hnp-audio-btn:hover svg {
	transform: scale(1.1) rotate(-8deg);
}

.hnp-skip-label {
	position: absolute;
	bottom: 1px;
	right: 2px;
	font-size: 8px;
	font-weight: 800;
	pointer-events: none;
}

.hnp-volume {
	display: flex;
	align-items: center;
	gap: 2px;
}

.hnp-volume-slider {
	-webkit-appearance: none;
	width: 0;
	opacity: 0;
	transition: width 0.2s ease, opacity 0.2s ease, margin 0.2s ease;
	background: transparent;
	height: 4px;
	cursor: pointer;
	margin-left: 0;
}

.hnp-volume-slider::-webkit-slider-runnable-track {
	height: 4px;
	border-radius: 2px;
	background: rgba(255, 255, 255, 0.25);
}
.hnp-volume-slider::-webkit-slider-thumb {
	-webkit-appearance: none;
	width: 12px;
	height: 12px;
	border-radius: 50%;
	background: var(--hnp-accent);
	margin-top: -4px;
}
.hnp-volume-slider::-moz-range-track {
	height: 4px;
	border-radius: 2px;
	background: rgba(255, 255, 255, 0.25);
}
.hnp-volume-slider::-moz-range-thumb {
	width: 12px;
	height: 12px;
	border: none;
	border-radius: 50%;
	background: var(--hnp-accent);
}

.hnp-volume:hover .hnp-volume-slider,
.hnp-volume:focus-within .hnp-volume-slider {
	width: 72px;
	opacity: 1;
	margin-left: 6px;
}

.hnp-time {
	color: #fff;
	font-size: 13px;
	font-weight: 500;
	font-variant-numeric: tabular-nums;
	margin-left: 8px;
	opacity: 0.92;
	white-space: nowrap;
}

.hnp-time-sep {
	opacity: 0.55;
	margin: 0 4px;
}

.hnp-menu-wrap {
	position: relative;
}

.hnp-menu {
	position: absolute;
	bottom: 48px;
	right: 0;
	min-width: 226px;
	/* --hnp-menu-max JS-ით იწერება კონტეინერის რეალური სიმაღლიდან,
	   რომ მენიუ პლეერს ვერასოდეს გასცდეს. */
	max-height: var(--hnp-menu-max, 320px);
	overflow-y: auto;
	overscroll-behavior: contain;
	-webkit-overflow-scrolling: touch;
	background: var(--hnp-ui);
	backdrop-filter: blur(14px);
	-webkit-backdrop-filter: blur(14px);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 12px;
	box-shadow: 0 16px 44px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.03);
	display: none;
	color: #fff;
	font-size: 13px;
	padding: 6px 0;
	opacity: 0;
	transform: translateY(6px) scale(0.98);
	transition: opacity 0.16s ease, transform 0.16s cubic-bezier(.2,.9,.3,1.2);
}

.hnp-menu.hnp-open {
	display: block;
	opacity: 1;
	transform: translateY(0) scale(1);
}

.hnp-menu-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 11px 14px 10px;
	font-weight: 700;
	font-size: 12.5px;
	letter-spacing: 0.2px;
	border-bottom: 1px solid var(--hnp-ui-border);
	margin-bottom: 4px;
	color: rgba(255, 255, 255, 0.55);
	text-transform: uppercase;
	letter-spacing: 0.6px;
	font-size: 11px;
}

/* ---------- Audio / language menu items ---------- */

.hnp-audio-item {
	justify-content: flex-start;
	gap: 10px;
}

.hnp-audio-item-left {
	display: flex;
	align-items: center;
	gap: 10px;
	flex: 1;
	min-width: 0;
}

.hnp-lang-chip {
	flex-shrink: 0;
	width: 26px;
	height: 20px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 10px;
	font-weight: 800;
	letter-spacing: 0.2px;
	border-radius: 5px;
	background: rgba(255, 255, 255, 0.1);
	color: rgba(255, 255, 255, 0.75);
	border: 1px solid rgba(255, 255, 255, 0.12);
}

.hnp-audio-item.hnp-active .hnp-lang-chip {
	background: var(--hnp-accent);
	border-color: var(--hnp-accent);
	color: #fff;
}

.hnp-audio-item-label {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.hnp-radio-dot {
	flex-shrink: 0;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	border: 1.5px solid rgba(255, 255, 255, 0.3);
	position: relative;
	transition: border-color 0.15s ease;
}

.hnp-radio-dot::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--hnp-accent);
	transform: translate(-50%, -50%) scale(0);
	transition: transform 0.15s cubic-bezier(.34,1.56,.64,1);
}

.hnp-audio-item.hnp-active .hnp-radio-dot {
	border-color: var(--hnp-accent);
}

.hnp-audio-item.hnp-active .hnp-radio-dot::after {
	transform: translate(-50%, -50%) scale(1);
}

.hnp-audio-item.hnp-active::after {
	content: none;
}

.hnp-badge-instant {
	font-size: 9.5px;
	font-weight: 700;
	letter-spacing: 0.3px;
	color: #2ecc71;
	background: rgba(46, 204, 113, 0.14);
	border: 1px solid rgba(46, 204, 113, 0.3);
	padding: 2px 7px;
	border-radius: 10px;
}

.hnp-menu-item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 10px 14px;
	cursor: pointer;
	white-space: nowrap;
	font-weight: 500;
	transition: background 0.12s ease;
	border-left: 2.5px solid transparent;
}

.hnp-menu-item-badge {
	font-size: 10.5px;
	font-weight: 700;
	letter-spacing: 0.3px;
	padding: 2px 7px;
	border-radius: 10px;
	background: rgba(255, 255, 255, 0.1);
	color: rgba(255, 255, 255, 0.7);
	flex-shrink: 0;
}

.hnp-menu-item-badge-warn {
	background: rgba(255, 159, 10, 0.16);
	color: #ffb14d;
	border: 1px solid rgba(255, 159, 10, 0.35);
}

.hnp-item-unsupported {
	opacity: 0.55;
}

.hnp-item-unsupported:hover {
	opacity: 0.85;
}

.hnp-menu-item:hover {
	background: rgba(255, 255, 255, 0.08);
}

.hnp-menu-item.hnp-active {
	color: var(--hnp-accent);
	font-weight: 700;
	background: color-mix(in srgb, var(--hnp-accent) 12%, transparent);
	border-left-color: var(--hnp-accent);
}

.hnp-audio-item.hnp-active {
	color: #fff;
}

.hnp-menu-item.hnp-active::after {
	content: "\2713";
	margin-left: 10px;
}

.hnp-menu-value {
	opacity: 0.5;
	font-size: 12px;
	font-weight: 500;
}

.hnp-menu-back {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 9px 14px 11px;
	border-bottom: 1px solid var(--hnp-ui-border);
	margin-bottom: 4px;
	cursor: pointer;
	font-weight: 700;
	font-size: 12.5px;
}

.hnp-menu-back:hover {
	background: rgba(255, 255, 255, 0.08);
}

/* Double-tap seek feedback (touch devices) */
.hnp-seek-flash {
	position: absolute;
	top: 0;
	bottom: 0;
	width: 40%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	background: radial-gradient(circle, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 70%);
	opacity: 0;
	pointer-events: none;
	z-index: 3;
}

.hnp-seek-flash.hnp-left { left: 0; }
.hnp-seek-flash.hnp-right { right: 0; }

.hnp-seek-flash.hnp-flash {
	animation: hnp-flash 0.5s ease;
}

@keyframes hnp-flash {
	0% { opacity: 0; }
	30% { opacity: 1; }
	100% { opacity: 0; }
}

.hnp-video-container.hnp-hide-cursor {
	cursor: none;
}

/* ---------- Error overlay ---------- */

.hnp-fatal-error {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 10px;
	color: #fff;
	background: #050505;
	padding: 24px;
	text-align: center;
	z-index: 9;
}

.hnp-fatal-error-title {
	font-size: 15px;
	font-weight: 700;
}

.hnp-fatal-error-msg {
	font-size: 13px;
	color: rgba(255, 255, 255, 0.65);
	max-width: 420px;
	line-height: 1.5;
}

@media (max-width: 640px) {
	.hnp-title-text {
		font-size: 15px;
		max-width: 45vw;
	}
	.hnp-top-bar {
		padding: 14px 14px;
	}
	.hnp-badge, .hnp-audio-indicator {
		font-size: 9.5px;
		padding: 3px 7px;
	}
	.hnp-btn {
		width: 33px;
		height: 33px;
	}
	.hnp-time {
		font-size: 11px;
	}
	.hnp-controls {
		padding: 6px 10px 12px;
	}
	.hnp-menu {
		min-width: 170px;
	}
}

/* ---------- Mobile adaptations requested ---------- */
@media (max-width: 768px) {
	.hnp-big-play {
		width: 56px !important;
		height: 56px !important;
	}
	.hnp-big-play .hnp-bp-svg {
		width: 46px !important;
		height: 46px !important;
	}
	.hnp-rewind,
	.hnp-forward {
		display: none !important;
	}
	.hnp-pip,
	.hnp-screenshot {
		display: none !important;
	}
}

/* BPG Nino Medium Caps Strict Enforcement */
.hnp-wrapper,
.hnp-wrapper *,
.hnp-wrapper button,
.hnp-wrapper span,
.hnp-wrapper div,
.hnp-wrapper p,
.hnp-wrapper a {
	font-family: 'BPG Nino Medium Caps', 'BPG Nino', sans-serif !important;
}

/* Informational row in Settings - strictly unclickable */
.hnp-menu-info-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 10px 14px;
	font-size: 13px;
	color: #cbd5e1;
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
	pointer-events: none !important;
	user-select: none;
	cursor: default !important;
}

.hnp-codec-tag {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 4px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.5px;
}
.hnp-tag-h264 {
	background: rgba(37, 99, 235, 0.25);
	color: #60a5fa !important;
	border: 1px solid rgba(96, 165, 250, 0.6);
}
.hnp-tag-hevc {
	background: rgba(220, 38, 38, 0.25);
	color: #f87171 !important;
	border: 1px solid rgba(248, 113, 113, 0.6);
}
.hnp-tag-av1 {
	background: rgba(22, 163, 74, 0.25);
	color: #4ade80 !important;
	border: 1px solid rgba(74, 222, 128, 0.6);
}
.hnp-tag-auto {
	background: rgba(255, 255, 255, 0.12);
	color: #94a3b8 !important;
}

/* Top bar codec badge colors */
.hnp-badge.hnp-badge-h264 {
	background: rgba(37, 99, 235, 0.9) !important;
	color: #ffffff !important;
	border: 1px solid #60a5fa !important;
}
.hnp-badge.hnp-badge-hevc {
	background: rgba(220, 38, 38, 0.9) !important;
	color: #ffffff !important;
	border: 1px solid #f87171 !important;
}
.hnp-badge.hnp-badge-av1 {
	background: rgba(22, 163, 74, 0.9) !important;
	color: #ffffff !important;
	border: 1px solid #4ade80 !important;
}

.hnp-video-container {
	overflow: hidden !important;
}
.hnp-video {
	transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), object-fit 0.25s ease !important;
}

/* ---------- მობილური ---------- */
@media (max-width: 768px) {
	.hnp-video-container {
		/* 16/9-ზე საგრძნობლად მაღალი — მენიუებს სივრცე რომ ჰქონდეთ.
		   შესაცვლელად მხოლოდ ეს ციფრია: 16 / 9 = ძველი,
		   16 / 11 = ახლანდელი, 16 / 12 = კიდევ უფრო მაღალი. */
		aspect-ratio: var(--hnp-mobile-aspect, 16 / 12) !important;
		max-height: none !important;
	}

	/* play ღილაკი ოპტიკურად ოდნავ მაღლა */
	.hnp-big-play {
		--hnp-play-nudge: -10px;
	}

	/* მენიუ კომპაქტური: ტელეფონზე 226px ეკრანის ნახევარზე მეტს იკავებდა */
	.hnp-menu {
		min-width: 210px;
		width: max-content;
		max-width: min(88vw, 340px);
		bottom: 44px;
		right: 0;
		font-size: 13px;
		padding: 4px 0;
		border-radius: 10px;
	}
	.hnp-menu-item,
	.hnp-menu-back {
		padding: 10px 14px;
		gap: 10px;
	}
	/* ენების სახელები აღარ უნდა ჩამოიჭრას */
	.hnp-audio-menu .hnp-menu-item,
	.hnp-audio-menu .hnp-menu-item span {
		white-space: nowrap;
		overflow: visible;
		text-overflow: clip;
		max-width: none;
	}

	/* კოდეკის ტეგი ორ ხაზად იშლებოდა და რიგს ამაღლებდა */
	.hnp-codec-tag {
		white-space: nowrap;
		font-size: 10.5px;
		padding: 2px 6px;
	}

	/* აუდიოს სია: ელემენტები ოდნავ უფრო მჭიდრო */
	.hnp-audio-menu .hnp-menu-item {
		padding: 8px 12px;
	}
}


/* ---------- პარამეტრების სათაური ---------- */
.hnp-menu-title {
	padding: 10px 14px 8px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.6px;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.5);
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
	margin-bottom: 4px;
}

/* ---------- კოდეკის ტეგი: ერთ ხაზში უნდა ჩაჯდეს ---------- */
.hnp-codec-tag {
	white-space: nowrap;
	font-size: 10px;
	line-height: 1.25;
	padding: 3px 7px;
	letter-spacing: 0;
}

@media (max-width: 768px) {
	.hnp-codec-tag { font-size: 9.5px; padding: 2px 6px; }
}


/* ---------- სრული ეკრანი ----------
   aspect-ratio და max-height აქ ხელს უშლიდა: კონტეინერი ეკრანის
   სიმაღლეს ვერ იკავებდა და კონტროლები შუაში რჩებოდა. */
.hnp-wrapper:fullscreen,
.hnp-wrapper:-webkit-full-screen {
	width: 100%;
	height: 100%;
	background: #000;
	display: flex;
	align-items: center;
	justify-content: center;
}

.hnp-wrapper:fullscreen .hnp-video-container,
.hnp-wrapper:-webkit-full-screen .hnp-video-container {
	aspect-ratio: auto !important;
	max-height: none !important;
	width: 100%;
	height: 100%;
}

.hnp-wrapper:fullscreen .hnp-video,
.hnp-wrapper:-webkit-full-screen .hnp-video {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.hnp-wrapper:fullscreen .hnp-poster,
.hnp-wrapper:-webkit-full-screen .hnp-poster {
	background-size: contain;
}

/* იგივე, თუ fullscreen კონტეინერზეა და არა wrapper-ზე */
.hnp-video-container:fullscreen,
.hnp-video-container:-webkit-full-screen {
	aspect-ratio: auto !important;
	max-height: none !important;
	width: 100%;
	height: 100%;
}

/* ---------- სქროლბარი დიზაინის ფერებში ----------
   ეპიზოდების სია და პარამეტრების/აუდიოს მენიუ — Windows-ის ღია
   სტანდარტული სქროლბარის ნაცვლად თხელი, მომრგვალებული, accent ფერის. */
.hnp-wrapper {
	--hnp-scroll-thumb: rgba(255, 255, 255, 0.26);
	--hnp-scroll-thumb-hover: var(--hnp-accent, #8b5cf6);
}
@supports (color: color-mix(in srgb, red, blue)) {
	.hnp-wrapper {
		--hnp-scroll-thumb: color-mix(in srgb, var(--hnp-accent, #8b5cf6) 55%, rgba(255, 255, 255, 0.12));
	}
}

/* Chrome, Edge, Opera, Safari */
.hnp-wrapper .hnp-menu::-webkit-scrollbar,
.hnp-wrapper .hnp-ep-list::-webkit-scrollbar {
	width: 10px;
	height: 10px;
}
.hnp-wrapper .hnp-menu::-webkit-scrollbar-track,
.hnp-wrapper .hnp-ep-list::-webkit-scrollbar-track {
	background: transparent;
	margin: 8px 0;
}
.hnp-wrapper .hnp-menu::-webkit-scrollbar-thumb,
.hnp-wrapper .hnp-ep-list::-webkit-scrollbar-thumb {
	min-height: 40px;
	border: 3px solid transparent;
	border-radius: 999px;
	background-color: var(--hnp-scroll-thumb);
	background-clip: padding-box;
}
.hnp-wrapper .hnp-menu::-webkit-scrollbar-thumb:hover,
.hnp-wrapper .hnp-ep-list::-webkit-scrollbar-thumb:hover,
.hnp-wrapper .hnp-menu::-webkit-scrollbar-thumb:active,
.hnp-wrapper .hnp-ep-list::-webkit-scrollbar-thumb:active {
	border-width: 2px;
	background-color: var(--hnp-scroll-thumb-hover);
}
.hnp-wrapper .hnp-menu::-webkit-scrollbar-button,
.hnp-wrapper .hnp-ep-list::-webkit-scrollbar-button {
	display: none;
}
.hnp-wrapper .hnp-menu::-webkit-scrollbar-corner,
.hnp-wrapper .hnp-ep-list::-webkit-scrollbar-corner {
	background: transparent;
}

/* Firefox. Chrome 121+-ში ეს თვისებები webkit-ის სტილს გადაწერდა,
   ამიტომ ჩაირთვება მხოლოდ ::-webkit-scrollbar-ის არმქონე ბრაუზერში. */
@supports not selector(::-webkit-scrollbar) {
	.hnp-wrapper .hnp-menu,
	.hnp-wrapper .hnp-ep-list {
		scrollbar-width: thin;
		scrollbar-color: var(--hnp-scroll-thumb) transparent;
	}
}

/* ტელევიზორი (Tizen/webOS, კლასს player.js ამატებს): დაბინდული ფონი (backdrop-filter) ძველ TV-ბრაუზერში
   მენიუს ქართულ ტექსტს ფარავდა (სრული ეკრანის გარეშე). ფონი ისედაც თითქმის გაუმჭვირვალეა. */
.hnp-tv,
.hnp-tv * {
	-webkit-backdrop-filter: none !important;
	backdrop-filter: none !important;
}

/* ტელევიზორი (3.7.17): მენიუში ჩანდა მხოლოდ ნახევრად გამჭვირვალე ტექსტი (.hnp-menu-value) — TV-ბრაუზერი მას ცალკე
   ფენად ხატავს. დანარჩენ ტექსტსაც იგივე პირობა: opacity < 1. სრულ ეკრანზე ისედაც ჩანდა. */
.hnp-tv .hnp-menu *:not(.hnp-menu-value) {
	opacity: 0.999;
}
