/* ============================================================
   VIDEOS PAGE — CLEAN, ORGANIZED, NO-VISUAL-CHANGE VERSION
   ============================================================ */
/* ----------------------------
   LAYOUT
----------------------------- */
.content {
  padding: 2rem 5vw 3rem;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
}
.hero {
  padding: 3rem 0 3rem 2rem;
  border-radius: 1.5rem;
  background: radial-gradient(circle at top left, #222 0, #111 40%, #050505 100%);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: space-between;
  align-content: center;
}
.hero h1 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}
/* ----------------------------
   TAGS + FILTER BANNER
----------------------------- */
.tag-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.18);
  cursor: pointer;
  margin: 3px 4px 0 0;
  transition: background .2s, border-color .2s;
  text-decoration: none;
}
.tag-chip:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.3);
}
.tag-chip-row {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
}
.filter-banner {
  margin: 20px 0 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}
/* ----------------------------
   SAVED FOR LATER / RECENTLY VIEWED CAROUSELS
----------------------------- */
.recently-watched {
  margin-top: 24px;
}
.recently-watched-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
}
.recently-watched-header h2 {
  font-size: 1.1rem;
  margin: 0;
  display: flex;
  gap: 4px;
  align-content: center;
}
.recently-watched-header h2 svg {
  stoke: var(--text);
  height: 18px;
  width: 18px;
	margin: auto 0;
}
#eyeOpen {
  width: 29px !important;
  height: 22px !important;
	margin: auto 0;
}
.rw-carousel {
  display: flex;
  gap: 1rem;
  padding-bottom: 6px;
  -webkit-overflow-scrolling: touch;
  flex-direction: column;
}
.rw-carousel::-webkit-scrollbar {
  height: 6px;
}
.rw-carousel::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.25);
  border-radius: 999px;
}
.rw-item {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 8px;
  width: 100%;
  cursor: pointer;
  display: flex;
  gap: 10px;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  text-align: left;
}
.rw-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 18px rgba(0, 150, 255, 0.3);
  border-color: rgba(0, 150, 255, 0.7);
}
.rw-thumb {
  border-radius: 7px;
  overflow: hidden;
  background: #000;
  width: 100%;
  max-width: 160px;
}
.rw-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 16/9;
}
.rw-title {
  font-size: .8rem;
  color: var(--text);
  padding: 0 2px 2px;
}
.rw-title p {
  color: var(--muted);
  font-size: 0.7rem;
  margin-top: 8px;
}
/* ----------------------------
   VIDEO LIST
----------------------------- */
.video-list {
  margin-top: 25px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
/* ----------------------------
   VIDEO CARD
----------------------------- */
.video-card-row {
  display: flex;
  gap: 20px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease, border-color 0.22s ease;
}
.video-card-row:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(0, 150, 255, 0.7);
  box-shadow: 0 0 22px rgba(0, 150, 255, 0.4);
  transform: translateY(-2px) scale(1.01);
}
.video-card-row.locked:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.16);
}
/* ----------------------------
   THUMBNAIL
----------------------------- */
.video-card-thumb {
  max-width: 40%;
  border-radius: 10px;
  background: #000;
	display: flex;
}
.video-card-thumb img.real-thumb {
  max-width: 100%;
  height: auto;
  object-fit: cover;
  pointer-events: none;
	flex: 1 1 auto;
	min-width: 0;
}
/* ============================================================
   UNIVERSAL VIDEO THUMBNAIL OVERLAY PROTECTION
   ============================================================ */
/* -----------------------------------------------------------
   ANTI-SAVE THUMBNAIL OVERLAY (FINAL WORKING VERSION)
------------------------------------------------------------ */
.video-card-thumb, .rw-thumb {
  position: relative;
  overflow: hidden;
}
/* This MUST capture right-click so the user saves the 1×1 PNG */
.video-card-thumb img.overlay-protect, .rw-thumb img.overlay-protect {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* invisible but still right-clickable */
  opacity: 0;
  /* MUST be above the real thumbnail */
  z-index: 99;
  /* MUST allow right-click to target THIS image */
  pointer-events: auto;
}
/* Locked overlay */
.video-card-locked {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(2px);
  border-radius: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  z-index: 10;
  pointer-events: none;
}
/* ----------------------------
   VIDEO META
----------------------------- */
.video-card-meta {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.video-card-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
  color: #fff;
}
.video-card-desc {
  color: #ccc;
  font-size: 0.85rem;
  line-height: 1.45;
}
.video-card-duration {
  margin-right: 10px;
  font-size: 0.8rem;
  opacity: 0.65;
}
.video-card-remaining {
  line-height: 1rem;
  font-size: 0.8rem;
  color: rgba(0, 200, 120, 0.9) !important;
  white-space: nowrap;
}
/* In progress */
.video-card-remaining.is-in-progress {
  line-height: 1rem;
  font-size: 0.8rem;
  color: rgba(0, 200, 120, 0.9) !important;
  white-space: nowrap;
}
/* Completed */
.video-card-remaining.is-watched {
  color: rgba(0, 200, 120, 0.9) !important;
}
.video-card-extra {
  display: flex;
}
.video-card-actions {
  display: flex;
  gap: .5rem;
  margin-top: auto;
  flex-wrap: wrap;
}
/* ----------------------------
   BUTTONS
----------------------------- */
.btn.small {
  font-size: 13px;
  padding: 6px 14px;
	margin: auto 0;
	height: 2rem;
}
.btn.primary {
  background: #0a84ff;
  border-color: #0a84ff;
  color: #fff;
}
.btn.ghost {
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  color: #fff;
}
.video-action-buttons {
	display: flex;
	gap: .5rem;
}

.video-like-buttons {
	display: flex;
	gap: .5rem;
}
/* ----------------------------
   FAVORITES
----------------------------- */
.favorite-toggle {
  padding: 0;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.favorite-heart {
  font-size: 16px;
  opacity: 0.7;
}
.favorite-toggle--active .favorite-heart {
  color: #ff3b72;
  opacity: 1;
}
/* ----------------------------
   VIDEO MODAL
----------------------------- */
.video-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  padding: 40px 20px;
}
.video-modal--visible {
  display: flex;
}
.video-modal-inner {
  background: #111;
  border-radius: 12px;
  max-width: 900px;
  width: 100%;
  padding: 20px;
  position: relative;
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.4);
}
.video-modal-title {
  margin: 0 0 8px;
  font-size: 20px;
}
.video-modal-description {
  font-size: 14px;
  margin: 0 0 16px;
  opacity: .8;
}
.video-protect-wrapper video {
  width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
  box-shadow: 0 0 18px rgba(0, 150, 255, 0.35);
  transition: transform .22s ease, box-shadow .22s ease;
}
.video-protect-wrapper video:hover {
  transform: scale(1.01);
  box-shadow: 0 0 28px rgba(0, 150, 255, 0.6);
}
.video-modal-close {
  position: absolute;
  top: 10px;
  right: 14px;
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #fff;
}
/* ----------------------------
   SEGMENTED SORT CONTROL
----------------------------- */
.video-sort-wrapper {
  margin-top: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.video-sort-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.65;
}
.segmented-control {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
}
.segmented-control__option {
  padding: 6px 14px;
  font-size: 0.8rem;
  color: #e0e0e0;
  text-decoration: none;
  border-radius: 999px;
  transition: background .18s, color .18s, box-shadow .18s;
  white-space: nowrap;
}
.segmented-control__option:hover {
  background: rgba(255, 255, 255, 0.09);
}
.segmented-control__option--active {
  background: #f5f5f5;
  color: #000;
  font-weight: 600;
  box-shadow: 0 0 18px rgba(0, 0, 0, 0.45);
}
/* ----------------------------
   WATCH LATER
----------------------------- */
.btn.watch-later-toggle.watch-later-toggle--active {
  border-color: rgba(0, 200, 120, 0.6);
  background: rgba(0, 200, 120, 0.16);
}
.watch-later-toggle--active .watch-later-label::before {
  content: "✓ ";
}
/* ----------------------------
   PAGINATION
----------------------------- */
.pagination {
  margin-top: 40px;
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}
.pagination a {
  padding: 8px 14px;
  background: #eee;
  border-radius: 6px;
  text-decoration: none;
  color: #333;
  font-weight: 500;
}
.pagination a:hover {
  background: #ddd;
}
.pagination a.active {
  background: #0071e3;
  color: #fff;
}
.videos-two-col.videos-full-width .video-card-thumb {
  width: 60%;
  max-width: 360px;
}
.videos-two-col.videos-full-width {
  display: flex;
}
.videos-two-col.videos-full-width .videos-right {
  display: none;
}
.videos-two-col.videos-full-width .videos-left {
  width: 100%;
  max-width: 100%;
}
/* ----------------------------
   RESPONSIVE
----------------------------- */
@media (max-width: 780px) {
  .video-card-row {
    flex-direction: column;
  }
  .videos-two-col.videos-full-width .video-card-thumb {
    width: 100%;
    height: 200px;
  }
  .video-card-actions {
    flex-direction: column;
    width: 100%;
  }
  .video-card-actions .btn {
    width: 100%;
  }
  .rw-thumb img {
    height: 80px;
  }
  /* Sort bar mobile */
  .video-sort-wrapper {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    width: 100%;
  }
  .video-list {
    margin-top: 0;
  }
  .hero {
    padding: 1rem;
    flex-direction: column;
  }
  .videos-two-col {
    margin-top: 8px;
  }
  .videos-right {
    margin-top: 0 !important;
  }
  .video-card-thumb {max-width: 100%}
	
  .segmented-control {
    width: 100%;
    padding: 6px;
    gap: 6px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .segmented-control::-webkit-scrollbar {
    display: none;
  }
  .segmented-control__option {
    flex: 0 0 auto;
    padding: 10px 18px;
    font-size: 0.9rem;
  }
  .segmented-control__option--active {
    background: #fff;
    color: #000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  }
	.video-like-buttons {
		display: flex;
		gap: 10px;
	}
	.video-action-buttons {
		display: flex;
		gap: 10px;
	}
	.btn.small {
		padding: 8px 14px;
		height: 2.5rem;
	}
	.resume-btn {
		padding: 0!important;
	}
	.restart-btn {
		padding: 0!important;
	}
	
}
/* -------------------------------------------------
   THUMBNAIL CIRCULAR PROGRESS INDICATOR
-------------------------------------------------- */
.thumb-progress {
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 32px;
  height: 32px;
  z-index: 20;
}
.thumb-progress svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.thumb-progress circle {
  fill: none;
  stroke-width: 3px;
  stroke-linecap: round;
}
/* Background ring */
.thumb-progress circle.bg {
  stroke: rgba(255, 255, 255, 0.22);
}
/* Animated foreground ring */
.thumb-progress circle.fg {
  stroke: #ffffff;
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  transition: stroke-dashoffset .35s ease;
}
/* ============================================================
   TWO-COLUMN LAYOUT FOR VIDEOS PAGE (DESKTOP ONLY)
============================================================ */
.videos-two-col {
  display: flex;
  gap: 40px;
  align-items: flex-start;
  margin-top: 16px;
}
/* Left: video cards */
.videos-left {
  width: 70%;
  min-width: 0; /* prevents flex overflow */
}
/* Right: recently viewed */
.videos-right {
  width: 30%;
  min-width: 0;
  /*position: sticky;*/
  top: 90px; /* optional: keeps it visible while scrolling */
}
/* Make recently viewed sidebar look good */
.videos-right .recently-watched {
  margin-top: 22px !important;
}
/* ==============================================
   MOBILE & TABLET — revert to stacked layout
============================================== */
@media (max-width: 1020px) {
  .videos-two-col {
    flex-direction: column;
  }
  .videos-left, .videos-right {
    width: 100%;
  }
  .videos-right {
    position: static;
    margin-top: 40px;
  }
}
.processing-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  pointer-events: all;
}
.processing-overlay span {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .02em;
  color: #fff;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.75);
}

.favorite-toggle--active {
	border: 1px solid #ff3b72!important;
	background: rgba(255, 59, 114, .25)!important;
}