/* Font families — Lato & Josefin Sans (matching main website) */
:root {
    --font-lato: 'Lato', sans-serif;
    --font-josefin: 'Josefin Sans', sans-serif;
}

body {
    font-family: 'Lato', sans-serif !important;
}

.font-lato {
    font-family: var(--font-lato) !important;
}

.font-josefin {
    font-family: var(--font-josefin) !important;
}

#page-content {
    font-family: 'Lato', sans-serif !important;
}

#page-content p,
#page-content span,
#page-content div,
#page-content a,
#page-content li,
#page-content td,
#page-content th,
#page-content label,
#page-content input,
#page-content textarea,
#page-content select,
#page-content button {
    font-family: 'Lato', sans-serif !important;
}

#page-content h1,
#page-content h2,
#page-content h3,
#page-content h4,
#page-content h5,
#page-content h6 {
    font-family: 'Josefin Sans', sans-serif !important;
}
.alert-danger, .alert-error {
    background-color: #f2dede;
    border-color: #eed3d7;
    color: #b94a48;
}
.table {
    font-size: 14px !important;
}
.table-bordered {
    border: 1px solid #EBEBEB;
}
.workshop-date-tabs {
    border: 1px solid #ddd;
    -webkit-border-radius: 4px;
    -moz-border-radius: 4px;
    border-radius: 4px;
    padding: 13px 13px 0px 13px;
}
.sticky-div {
    height: 560px;
    overflow: scroll;
}
.image-container img {
    max-width: 100%;
    height: auto;
  }

  .like-icon {
    color: black; /* Default color is black */
  }
  .like-icon.active {
    color: #1ab394 !important;
  }
  /* Remove outline when button is clicked */
  .btn:focus, .btn:active {
    outline: none !important;
    box-shadow: none !important;
  }
  .btn-fade:hover .fa {
    opacity: 0.8; /* Change icon opacity on hover */
  color: black;
  }
  .card-header {
    background-color: white !important;
    border: none !important;
  height:20px;
  }

  /* Add comment modal here */
  .comment {
    margin-bottom: 20px;
    padding: 15px;
    border: 1px solid #ccc;
    border-radius: 10px;
    display: flex;
  }
  .comment_icon{
    font-size: 50px;
    padding-right: 23px;
  }

  #style-4::-webkit-scrollbar
  {
      width: 5px;
      background-color: #F5F5F5;
  }

  #style-4::-webkit-scrollbar-thumb
  {
      background-color: #ECECEC;
  }
  .scroll{
    overflow-y: scroll;
    height: 214px;
  }

  /* subscribe Payment modal */
  .subcribe .modal-header {
    background-color: #f8f9fa;
    border-bottom: none;
  }
  .subcribe .modal-footer {
    border-top: none;
  }

  /* Customize QR code image */
  .subcribe .qr-code-img {
    max-width: 200px;
  }
  /* Customize colors */
  .subcribe .bg-bank-details {
    background-color: #e9ecef;
  }
  .subcribe .bg-qr-code {
    background-color: #dee2e6;
  }
  .like-icon-left{
    margin-left: -11px;
  }
  .comment img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    margin-right: 15px;
  }
  .remove_watchlist_btn {
    position: relative;
  }
  .text-navy {
    color: #1ab394 !important;
  }
  .font20 {
    font-size: 20px;
  }
  /* Loading spinner — amber brand color */
  .loading {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 4px solid #e5e7eb;
    border-top-color: #d97706;
    animation: loading 1s linear infinite;
    margin: 0 auto;
  }
  @keyframes loading {
    to {
      transform: rotate(360deg);
    }
  }

.font14{
  font-size: 14px !important;
}
.active_plan{
  background-color: #21ddb7 !important;
  color: #000;
}
.cursor-pointer{
  cursor: pointer;
}
.header_bg{
  background-color: #000 !important;
  color: #fff;
}
.btn-outline-secondary:hover {
  color: #000 !important;
  background-color: #6c757d;
  border-color: #6c757d;
}

/* Compact video card styling */
.video-card {
  background: white;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease;
  overflow: hidden;
  position: relative;
  z-index: 1;
  contain: layout style size;
  border: 1px solid #f3f4f6;
}

.video-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
  transform: translateY(-1px);
  border-color: #e5e7eb;
}

.video-thumbnail {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  background: #f3f4f6;
  overflow: hidden;
  border-radius: 8px;
}

.video-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.video-card:hover .video-thumbnail img {
  transform: scale(1.05);
}

.video-duration {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
}

.video-play-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background: rgba(0, 0, 0, 0.8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 24px;
  opacity: 0.8;
  transition: all 0.3s ease;
  border: 3px solid rgba(255, 255, 255, 0.9);
}

.video-thumbnail:hover .video-play-overlay {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.1);
  background: rgba(0, 0, 0, 0.9);
}


.video-info {
  padding: 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.video-title {
  font-size: 15px;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 6px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.video-stats {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
  font-size: 13px;
  color: #6b7280;
}

.video-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  border-top: 1px solid #f3f4f6;
}

.action-btn {
  background: none;
  border: none;
  color: #6b7280;
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 3px 6px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.action-btn:hover {
  background: #f3f4f6;
  color: #374151;
}

.action-btn.liked {
  color: #ef4444;
}

.action-btn.favourited {
  color: #f59e0b;
}

/* Responsive grid adjustments */
@media (max-width: 768px) {
  .video-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  }
}


/* Search and filter improvements */
.search-input:focus {
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.filter-btn.active {
  background-color: #dbeafe !important;
  color: #2563eb !important;
}

/* Loading spinner (small) — amber brand color */
.loading-spinner {
  width: 24px;
  height: 24px;
  border: 2px solid #e5e7eb;
  border-top: 2px solid #d97706;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Pagination improvements */
.pagination-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: 0 2px;
  border: 1px solid #d1d5db;
  background: white;
  color: #374151;
  text-decoration: none;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.pagination-btn:hover {
  background: #f3f4f6;
  border-color: #9ca3af;
}

.pagination-btn.active {
  background: #3b82f6;
  border-color: #3b82f6;
  color: white;
}

.pagination-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Modal improvements */
[x-cloak] {
  display: none !important;
}

/* Vimeo iframe improvements */
.video-thumbnail iframe {
  width: 100% !important;
  height: 100% !important;
  border-radius: 8px;
}

/* Compact Grid layout */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
  padding: 0;
  margin: 0;
}

/* List view layout */
.video-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 0;
  margin: 0;
}

/* Grid view card styling */
.video-grid > .video-card {
  width: 100%;
  height: auto;
  min-height: 320px;
  display: flex;
  flex-direction: column;
}

/* List view card styling */
.video-list > .video-card {
  width: 100%;
  height: auto;
  min-height: 120px;
  display: flex;
  flex-direction: row;
  align-items: center;
}

.video-list > .video-card .video-thumbnail {
  width: 200px;
  height: 112px;
  flex-shrink: 0;
  margin-right: 1rem;
}

.video-list > .video-card .video-info {
  flex: 1;
  padding: 1rem;
  height: 100%;
}

.video-list > .video-card .video-title {
  font-size: 16px;
  margin-bottom: 0.5rem;
  -webkit-line-clamp: 1;
}

.video-list > .video-card .video-stats {
  margin-bottom: 0.5rem;
}

.video-list > .video-card .video-actions {
  padding-top: 0.5rem;
  margin-top: auto;
}

/* Compact video thumbnail styling */
.video-thumbnail {
  cursor: pointer;
  transition: transform 0.2s ease;
  border-radius: 6px;
  overflow: hidden;
}

.video-thumbnail:hover {
  transform: scale(1.01);
}

.video-thumbnail-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: all 0.3s ease;
  border-radius: 8px;
  display: block;
}

.video-thumbnail iframe,
.video-thumbnail object,
.video-thumbnail embed {
  position: absolute;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
  border: none;
  border-radius: 8px;
}

/* Override any inline styles from Vimeo */
.video-thumbnail * {
  max-width: 100% !important;
  max-height: 100% !important;
}

/* Fix for Bootstrap responsive embed classes if present */
.video-thumbnail .embed-responsive {
  position: relative !important;
  width: 100% !important;
  height: 100% !important;
  padding-bottom: 0 !important;
}

.video-thumbnail .embed-responsive iframe {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
}

/* Ensure Vimeo player doesn't break layout */
.video-thumbnail [src*="vimeo"] {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
}

/* Hover effects for buttons */
.action-btn:hover i {
  transform: scale(1.1);
  transition: transform 0.2s ease;
}

/* Video info spacing for grid layout */
.video-info {
  padding: 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Force any absolutely positioned children to stay contained */
.video-card,
.video-thumbnail {
  isolation: isolate;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .video-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
  }

  .video-list > .video-card {
    flex-direction: column;
    min-height: auto;
  }

  .video-list > .video-card .video-thumbnail {
    width: 100%;
    height: 140px;
    margin-right: 0;
    margin-bottom: 0.5rem;
  }

  .video-list > .video-card .video-info {
    padding: 0.75rem;
  }
}

@media (max-width: 640px) {
  .video-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .video-card {
    min-height: auto;
  }
}

/* Folder card styling */
.folder-card {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  padding: 0.75rem;
  text-align: center;
  transition: all 0.2s ease;
  cursor: pointer;
}

.folder-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.folder-card i {
  font-size: 1.5rem;
  color: #f59e0b;
  margin-bottom: 0.5rem;
}

.folder-card .folder-name {
  font-size: 0.75rem;
  font-weight: 500;
  color: #374151;
  line-height: 1.2;
}

.folder-card .folder-count {
  font-size: 0.7rem;
  color: #6b7280;
  margin-top: 0.25rem;
}

/* Video count badge */
#video-count {
  font-size: 0.75rem;
  white-space: nowrap;
}

/* Search input improvements */
.search-input {
  transition: all 0.2s ease;
}

.search-input:focus {
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  border-color: #3b82f6;
}

/* Filter button improvements */
.filter-btn {
  transition: all 0.2s ease;
}

.filter-btn.active {
  background-color: #dbeafe !important;
  color: #2563eb !important;
}

/* Additional overflow protection */
.video-card * {
  box-sizing: border-box;
}

/* Ensure all content stays within bounds */
.video-card,
.video-card * {
  overflow: clip;
}

/* Report page specific styles */
.expiry-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.5rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
}

.plan-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.5rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
}

/* User avatar in reports */
.user-avatar {
  width: 2rem;
  height: 2rem;
  background-color: #dbeafe;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 0.75rem;
}

/* Responsive table improvements */
@media (max-width: 768px) {
  .table-responsive {
    font-size: 0.875rem;
  }

  .table-responsive th,
  .table-responsive td {
    padding: 0.5rem;
  }

  .user-avatar {
    width: 1.5rem;
    height: 1.5rem;
    margin-right: 0.5rem;
  }

  .expiry-badge,
  .plan-badge {
    font-size: 0.625rem;
    padding: 0.125rem 0.375rem;
  }
}

/* Print styles for reports */
@media print {
  .no-print {
    display: none !important;
  }

  .print-table {
    border-collapse: collapse !important;
    width: 100% !important;
  }

  .print-table th,
  .print-table td {
    border: 1px solid #000 !important;
    padding: 8px !important;
    font-size: 12px !important;
  }

  .print-header {
    border-bottom: 2px solid #000 !important;
    font-weight: bold !important;
  }
}

/* Dashboard specific styles */
.dashboard-kpi-card {
  background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.05) 100%);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.dashboard-kpi-card:before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0.1) 100%);
}

.dashboard-kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

/* Progress bars */
.progress-bar {
  transition: width 0.8s ease-in-out;
  animation: progressLoad 1.2s ease-in-out;
}

@keyframes progressLoad {
  0% { width: 0%; }
  100% { width: var(--progress-width); }
}

/* Activity feed items */
.activity-item {
  transition: all 0.2s ease;
  position: relative;
}

.activity-item:hover {
  transform: translateX(4px);
}

.activity-icon {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

/* Chart containers */
.chart-container {
  position: relative;
  transition: all 0.3s ease;
}

.chart-container:hover {
  transform: scale(1.02);
}

/* Alert cards */
.alert-card {
  transition: all 0.2s ease;
  position: relative;
}

.alert-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Responsive dashboard adjustments */
@media (max-width: 768px) {
  .dashboard-kpi-card {
    padding: 1rem;
  }

  .dashboard-kpi-card h3 {
    font-size: 1.5rem;
  }

  .chart-container {
    padding: 0.75rem;
  }

  .activity-item,
  .alert-card {
    padding: 0.75rem;
  }
}

/* Dashboard grid responsive */
@media (max-width: 640px) {
  .dashboard-grid-mobile {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* Loading states */
.loading-shimmer {
  background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Skeleton video card */
.skeleton-card {
  background: white;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  border: 1px solid #f3f4f6;
}

.skeleton-thumbnail {
  width: 100%;
  aspect-ratio: 16/9;
  background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.skeleton-line {
  height: 14px;
  border-radius: 4px;
  background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.skeleton-line-short {
  width: 60%;
}

.skeleton-line-medium {
  width: 80%;
}

.skeleton-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

/* Branded pulse loader */
.branded-loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.branded-loader-icon {
  width: 48px;
  height: 48px;
  color: #d97706;
  animation: pulse-breathe 2s ease-in-out infinite;
}

@keyframes pulse-breathe {
  0%, 100% { opacity: 0.4; transform: scale(0.95); }
  50% { opacity: 1; transform: scale(1.05); }
}

.branded-loader-text {
  color: #6b7280;
  font-size: 14px;
  font-weight: 500;
}

/* Content fade-in */
.fade-in {
  animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Dashboard specific button styles */
.dashboard-action-btn {
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.dashboard-action-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.dashboard-action-btn:active {
  transform: translateY(0);
}

/* Quick stat cards */
.quick-stat-card {
  transition: all 0.2s ease;
  cursor: pointer;
}

.quick-stat-card:hover {
  background-color: #f8fafc;
  transform: scale(1.02);
}

/* Enhanced shadows for depth */
.dashboard-card-shadow {
  box-shadow:
    0 1px 3px rgba(0,0,0,0.12),
    0 1px 2px rgba(0,0,0,0.24);
}

.dashboard-card-shadow:hover {
  box-shadow:
    0 3px 6px rgba(0,0,0,0.16),
    0 3px 6px rgba(0,0,0,0.23);
}

/* Date range indicator */
.date-range-indicator {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  animation: fadeInUp 0.5s ease-out;
}
@media (max-width: 767px) {
  .hide-on-mobile {
    display: none !important;
  }
}

/* Show on large screens */
@media (min-width: 768px) {
  .hide-on-mobile {
    display: block !important;
  }
}
@media screen and (max-width: 870px) and (min-width: 430px) {
  .video-grid > .video-card {
    min-height: 370px;
  }
}

@media screen and (max-width: 400px) and (min-width: 300px) {
  .video-grid > .video-card {
    min-height: 300px;
  }
}
@media (max-width: 640px) {
  .text-xl.text-sm, .text-lg.text-sm {
    font-size: 1rem !important; /* 16px */
    line-height: 1.25rem !important;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@media (max-width: 640px) {
  .search-filter-mobile-stack {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 0.75rem !important;
  }
  .search-filter-mobile-stack .search-col {
    width: 100% !important;
    max-width: 100% !important;
  }
  .search-filter-mobile-stack .sort-view-col {
    width: 100% !important;
    justify-content: space-between !important;
    gap: 0.5rem !important;
  }
  .search-filter-mobile-stack .sort-view-col select {
    width: 50% !important;
    min-width: 120px;
  }
  .search-filter-mobile-stack .sort-view-col .flex {
    width: auto !important;
  }
}