/* === Popular Sidebar Container === */
.popular-sidebar {
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(16px);
    padding: 5px;
    border-radius: 7px;
    width: 100%;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.25);
  }

  .sidebar-title {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: #fff;
  }

  /* === Tabs === */
  .sidebar-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
  }

  .tab-btn {
    flex: 1;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.08);
    border: none;
    color: #ccc;
    font-weight: 300;
    cursor: pointer;
    border-radius: 5px;
    transition: 0.3s;
  }

  .tab-btn.active {
    background: #620000;
    color: #fff;
  }

  /* === Tab Content Wrapper === */
  .tab-content-wrapper {
    max-height: 500px;
    overflow-y: auto;
  }

  .tab-content {
    display: none;
  }

  .tab-content.active {
    display: block;
  }



/* === Sidebar Card Layout === */
.sidebar-card {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 7px 14px;
    margin-bottom: 10px;
    transition: background 0.3s;
  }

  .sidebar-card:hover {
    background: rgba(255, 255, 255, 0.08);
  }

  /* .sidebar-card .rank {
    font-size: 14px;
    font-weight: bold;
    color: #ccc;
    width: 20px;
  } */

  .sidebar-card .card-thumbnail img {
    width: 60px;
    height: 80px;
    object-fit: cover;
    object-position: top;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  }

  .sidebar-card .card-info {
    flex: 1;
    min-width: 0;
  }

  .sidebar-card .card-info .title {
    font-weight: 600;
    font-size: 13px;
    color: #fff;
    line-height: 1.3;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .sidebar-card .card-info .genres {
    font-size: 12px;
    color: #aaa;
    margin-bottom: 4px;
  }

  .sidebar-card .card-info .rating {
    font-size: 12px;
    color: #FFD700;
  }

  .sidebar-card .card-info .rating .star {
    font-size: 14px;
    margin-right: 3px;
  }

  .sidebar-card .rating {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: #FFD700;
  }

  .sidebar-card .rating-number {
    color: #ccc;
    font-weight: 500;
    margin-left: 5px;
    font-size: 12px;
  }


  .tab-content-wrapper {
    max-height: 700px;
    overflow-y: auto;

    /* ✅ Smooth scrolling on macOS/Windows */
    scroll-behavior: smooth;
  }

  /* === Custom Scrollbar === */
  .tab-content-wrapper::-webkit-scrollbar {
    width: 0px;

  }

  .tab-content-wrapper::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
  }

  .tab-content-wrapper::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.085);
    border-radius: 10px;
    transition: background 0.3s;
  }

  .tab-content-wrapper::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.25);
  }


  /* === Spinner for Tab Loading === */
.sidebar-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 0;
    color: #ccc;
    font-size: 14px;
    font-weight: 300;
    opacity: 0.8;
  }

  .spinner {
    width: 32px;
    height: 32px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top: 4px solid #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 10px;
    backdrop-filter: blur(4px);
    box-shadow: 0 0 6px rgba(255, 255, 255, 0.05);
  }

  @keyframes spin {
    to {
      transform: rotate(360deg);
    }
  }

  .loading-text {
    font-size: 13px;
    color: #ccc;
    text-shadow: 0 0 2px rgba(255, 255, 255, 0.1);
  }


