/* ==========================================================================
   GOOGLE THEME FRONT - FINAL MASTER COPY (Multi-Color Active Bar)
   ========================================================================== */

/* =========================================
   1. FONTS & GLOBAL VARIABLES
   ========================================= */
@import url("https://fonts.googleapis.com/css2?family=Kantumruy+Pro:ital,wght@0,100..700;1,100..700&family=Krasar&family=Open+Sans:wght@400;500;600;700&display=swap");

:root {
  --font-primary: "Kantumruy Pro", "Open Sans", sans-serif;
  --color-primary: #1a73e8;
  --color-text-dark: #202124;
  --color-text-medium: #5f6368;
  --color-border: #e0e0e0;
  --color-bg-light: #f1f3f4;
  --color-bg-card: #ffffff;
}

/* FIX: PREVENT HORIZONTAL SCROLL on Body */
html, body {
  overflow-x: hidden !important;
  width: 100%;
}

body, h1, h2, h3, h4, h5, h6, p, a, span, div, li,
input, button, select, textarea, .btn, .form-control {
  font-family: var(--font-primary) !important;
}

h1, h2, h3, h4, h5, h6, .section-title {
  font-weight: 700 !important;
}

/* =========================================
   2. FOOTER
   ========================================= */
.footer-main-block {
  background-color: #690a18 !important;
  border-top: 1px solid var(--color-border);
}

/* =========================================
   3. PREMIUM CATEGORY CARDS
   ========================================= */
.category-card-premium {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 280px !important;
  min-height: 340px !important;
  padding: 0 !important;
  margin: 15px;
  background-color: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 20px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
  transition: all 0.4s ease;
  text-decoration: none !important;
  position: relative;
  overflow: hidden;
}

.category-card-premium:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(41, 63, 204, 0.15);
  border-color: rgba(41, 63, 204, 0.3);
}

.category-card-premium .category-icon-circle {
  border-radius: 12px !important;
  width: calc(100% - 32px) !important;
  height: 180px !important;
  margin: 16px 16px 0 16px !important;
  overflow: hidden !important;
  background-color: rgba(41, 63, 204, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s ease;
}

.category-card-premium:hover .category-icon-circle {
  background-color: #293fcc;
}

.category-card-premium .category-icon-circle img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: all 0.4s ease;
}

.category-card-premium:hover .category-icon-circle img {
  transform: scale(1.1);
}

.category-card-premium .category-title {
  margin-top: auto !important;
  padding: 15px 16px 5px 16px;
  font-size: 20px;
  font-weight: 700;
  color: #000;
  transition: color 0.3s ease;
}

.category-card-premium:hover .category-title {
  color: #293fcc;
}

.category-card-premium .category-see-more {
  margin-bottom: 16px !important;
  font-size: 14px;
  font-weight: 600;
  color: #888;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.3s ease;
}

.category-card-premium:hover .category-see-more {
  color: #293fcc;
}

.category-card-premium .category-see-more i {
  font-size: 12px;
  transition: transform 0.3s ease;
}

.category-card-premium:hover .category-see-more i {
  transform: translateX(5px);
}

/* =========================================
   4. NAV MENU ITEMS (GOOGLE COLOR BAR)
   ========================================= */

/* --- 4.1 Desktop & Global Styles --- */
.top-bar-main-block .nav-item .nav-link,
.top-bar-main-block .nav-item .nav-link.btn-primary,
.navbar-nav .nav-link {
    font-family: "Kantumruy Pro", sans-serif !important;
    font-weight: 700 !important;
    letter-spacing: 0.3px;
    font-size: 1rem !important;
    color: var(--color-text-dark) !important;
    
    /* FORCE ONE LINE (No Wrapping) */
    white-space: nowrap !important;
    
    /* Clean Styling */
    background-color: transparent !important;
    border-radius: 0 !important;
    padding: 10px 10px !important; 
    margin: 0 1px !important;
    position: relative; 
    transition: color 0.3s ease;
}

/* Hover State */
.top-bar-main-block .nav-item .nav-link:hover {
    color: var(--color-primary) !important;
    background-color: transparent !important;
}

/* --- THE ACTIVE STATE INDICATOR (DESKTOP) --- */
.top-bar-main-block .nav-item.active .nav-link,
.top-bar-main-block .nav-item .nav-link.active,
.navbar-nav .nav-link.active {
    color: var(--color-primary) !important;
    font-weight: 800 !important;
}

/* Create the GOOGLE COLOR BAR using ::after */
@media (min-width: 992px) {
    .top-bar-main-block .nav-item .nav-link::after {
        content: '';
        position: absolute;
        width: 0;
        height: 4px; /* Thickness */
        display: block;
        margin-top: 5px;
        right: 0;
        
        /* THE GOOGLE COLOR GRADIENT */
        background: linear-gradient(90deg, 
            #4285F4 0%, #4285F4 25%,  /* Blue */
            #EA4335 25%, #EA4335 50%, /* Red */
            #FBBC05 50%, #FBBC05 75%, /* Yellow */
            #34A853 75%, #34A853 100% /* Green */
        ) !important;
        
        transition: width 0.3s ease; 
        left: 0;
        bottom: 0; 
        margin: auto; 
    }

    /* Animate width on Hover */
    .top-bar-main-block .nav-item .nav-link:hover::after {
        width: 100%;
    }

    /* Keep width 100% on Active */
    .top-bar-main-block .nav-item.active .nav-link::after,
    .top-bar-main-block .nav-item .nav-link.active::after {
        width: 100% !important; 
    }
}

/* --- 4.2 MOBILE SPECIFIC (Left Bar Style) --- */
@media (max-width: 991px) {
    .top-bar-main-block .nav-item .nav-link {
        padding: 12px 20px !important;
        border-bottom: 1px solid #f1f3f4;
        white-space: normal !important; /* Allow wrap on mobile if needed */
    }

    /* Disable the bottom underline on mobile */
    .top-bar-main-block .nav-item .nav-link::after {
        display: none !important;
    }

    /* ACTIVE STATE: Left Border Bar */
    .top-bar-main-block .nav-item.active .nav-link,
    .top-bar-main-block .nav-item .nav-link.active,
    .navbar-nav .nav-link.active {
        background-color: #e8f0fe !important; 
        color: var(--color-primary) !important;
        border-left: 5px solid var(--color-primary) !important;
        padding-left: 15px !important;
    }
}

/* 4.3 Dropdown Items */
.dropdown-menu .dropdown-item {
    font-family: "Kantumruy Pro", sans-serif !important;
    font-weight: 400 !important;
    font-size: 0.95rem !important;
    padding: 10px 20px !important;
    white-space: nowrap !important; 
}
.dropdown-menu .dropdown-item:active,
.dropdown-menu .dropdown-item.active {
    background-color: var(--color-primary) !important;
    color: #fff !important;
}

/* 4.4 Fix Venom Button Font */
.venom-button,
.venom-button .venom-button-popup {
    font-family: "Google Sans", "Kantumruy Pro", "Krasar", sans-serif !important;
}

/* =========================================
   5. USER DROPDOWN (YOUR CODE)
   ========================================= */
.google-style-dropdown {
  width: 370px !important;
  padding: 15px !important;
  border-radius: 28px !important;
  border: none !important;
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.15) !important;
  background: #e9eef6 !important;
  margin-top: 15px !important;
  transform: translateX(-10px) !important;
}

.google-style-dropdown::before,
.google-style-dropdown::after {
  display: none !important;
}

.user-header-transparent {
  padding: 10px 0 15px !important;
  width: 100% !important;
  text-align: center !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  background: transparent !important;
  margin-bottom: 10px;
  box-sizing: border-box !important;
}

.user-avatar-container {
  margin: 0 auto 10px !important;
  display: flex;
  justify-content: center;
  width: 100%;
}

.google-user-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #fff;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.google-user-name {
  font-size: 1.2rem !important;
  font-weight: 700 !important;
  color: #1f1f1f;
  margin-bottom: 2px;
  width: 100%;
  text-align: center;
}

.google-user-email {
  font-size: 0.9rem;
  color: #5e5e5e;
  margin-bottom: 15px;
  width: 100%;
  text-align: center;
}

.manage-account-btn {
  display: inline-block;
  padding: 8px 20px;
  border: 1px solid #747775;
  border-radius: 20px;
  color: #1f1f1f !important;
  font-weight: 500;
  font-size: 0.85rem;
  text-decoration: none;
  transition: background 0.2s;
  background: transparent;
  margin: 0 auto;
}

.manage-account-btn:hover {
  background-color: rgba(0, 0, 0, 0.05);
}

.action-card-section {
  background: #fff !important;
  border-radius: 28px !important;
  overflow: hidden !important;
  list-style: none !important;
  padding: 0 !important;
  margin-bottom: 10px !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  width: 100%;
  display: block;
}

.menu-toggler {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 16px 20px;
  color: #1f1f1f !important;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s;
  background: #fff;
  border: none !important;
}

.menu-toggler:hover {
  background-color: #f8f9fa;
}

.arrow-chevron {
  border: solid #5f6368;
  border-width: 0 2px 2px 0;
  display: inline-block;
  padding: 3px;
  transform: rotate(45deg);
  transition: transform 0.3s ease;
}

.menu-toggler:not(.collapsed) .arrow-chevron {
  transform: rotate(-135deg);
  margin-top: 3px;
}

.menu-items-list {
  border-top: 1px solid #f1f3f4;
  background: #fff;
  padding: 0 !important;
  margin: 0 !important;
}

.google-menu-item {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 12px 24px;
  color: #1f1f1f !important;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.1s;
  border-bottom: 1px solid #f1f3f4;
}

.google-menu-item:hover {
  background-color: #f8f9fa;
}

.menu-items-list .google-menu-item:last-child {
  border-bottom: none;
}

.google-menu-item .icon-box {
  width: 24px;
  margin-right: 15px;
  text-align: center;
}

.google-menu-item .icon-box i {
  font-size: 1.1rem;
  color: #5f6368 !important;
  transition: color 0.1s;
}

.google-menu-item:hover .icon-box i {
  color: #1f1f1f !important;
}

.logout-item {
  display: flex !important;
  width: 100% !important;
  padding: 14px 24px !important;
  color: #d93025 !important;
  font-weight: 500;
  text-decoration: none;
  font-size: 0.95rem;
  transition: background 0.2s;
  border-top: 1px solid #f1f3f4;
  align-items: center;
  box-sizing: border-box !important;
  margin: 0 !important;
  border-radius: 0 0 16px 16px !important;
}

.logout-item:hover {
  background-color: #fce8e6 !important;
}

.logout-item i {
  margin-right: 15px;
  font-size: 1.1rem;
  width: 24px;
  text-align: center;
  color: #d93025 !important;
}

.google-footer-links {
  text-align: center !important;
  display: block !important;
  width: 100% !important;
  padding: 15px 0 5px;
  font-size: 0.75rem;
  color: #5f6368;
}

.google-footer-links a {
  color: #5f6368;
  text-decoration: none;
  margin: 0 8px;
  transition: color 0.2s;
}

.google-footer-links a:hover {
  color: #1f1f1f;
  text-decoration: underline;
}

/* =========================================
   6. USER DROPDOWN RESPONSIVE (YOUR CODE)
   ========================================= */
@media (max-width: 991px) {
  .profile-sidebar {
    padding: 20px !important;
    border-radius: 20px !important;
  }

  .user-profile {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-end !important;
    text-align: left !important;
    gap: 30px !important;
    padding-bottom: 28px !important;
    border-bottom: 1px solid #f1f3f4 !important;
  }

  .profile-sidebar .user-img img,
  .profile-sidebar img.img-fluid {
    width: 80px !important;
    height: 80px !important;
    min-width: 80px !important;
    min-height: 80px !important;
    margin: 0 !important;
  }

  .user-txt {
    text-align: left !important;
    width: auto !important;
  }

  .profile-sidebar .user-name {
    font-size: 1.2rem !important;
    margin-bottom: 4px !important;
  }

  .profile-sidebar .user-email {
    font-size: 0.9rem !important;
  }

  .profile-sidebar,
  .setting-block,
  .profile-about-block,
  .user-badges,
  .user-contact,
  .follow {
    padding: 25px 20px !important;
    width: 100% !important;
  }

  .profile-about-block .row > [class*="col-"],
  .user-contact .row > [class*="col-"] {
    width: 100% !important;
    flex: 0 0 100% !important;
    max-width: 100% !important;
    margin-bottom: 15px !important;
  }

  .mobile-bottom-bar .google-style-dropdown {
    position: fixed !important;
    bottom: 80px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 90vw !important;
    max-width: 360px !important;
    top: auto !important;
    margin-top: 0 !important;
    z-index: 9999;
    max-height: 70vh;
    overflow-y: auto;
    overflow-x: hidden !important;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

  .mobile-bottom-bar .google-style-dropdown::-webkit-scrollbar {
    display: none;
  }
}

/* =========================================================
   7. PROFILE PAGE STYLING (RESTORED PILLS + FIXED CARDS)
   ========================================================= */

/* --- A. Common Card Containers --- */
.profile-sidebar,
.profile-about-block,
.user-badges,
.user-contact,
.follow,
.setting-block,
.delete-account,
.plan-block,
.bookmark-block,
.refers-block,
.play-block {
  background-color: #ffffff !important;
  border: 1px solid #e0e0e0 !important;
  border-radius: 24px !important;
  padding: 30px !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05) !important;
  margin-bottom: 24px !important;
}

/* --- B. Sidebar & Pills (RESTORED) --- */
.profile-sidebar {
  position: sticky;
  top: 20px;
}

/* Force User Profile Center on Desktop */
@media (min-width: 992px) {
  .user-profile {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
    margin-bottom: 25px !important;
    padding-bottom: 20px !important;
    border-bottom: 1px solid #f1f3f4 !important;
  }

  .profile-sidebar .user-img img,
  .profile-sidebar img.img-fluid {
    width: 120px !important;
    height: 120px !important;
    min-width: 120px !important;
    min-height: 120px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 4px solid #fff !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    margin: 0 auto 15px !important;
  }
}

/* PILLS NAVIGATION */
.profile-sidebar .nav-tabs {
  border: none !important;
  gap: 8px !important;
  flex-direction: column !important;
  padding: 0 !important;
}

.profile-sidebar .nav-link {
  border: none !important;
  background-color: transparent !important;
  color: #5f6368 !important; /* Grey text */
  font-weight: 500 !important;
  padding: 12px 24px !important;
  border-radius: 50px !important; /* Pill Shape */
  text-align: left !important;
  display: flex !important;
  align-items: center !important;
  transition: all 0.2s ease !important;
  margin-bottom: 5px !important;
}

.profile-sidebar .nav-link i {
  margin-right: 15px !important;
  font-size: 1.1rem !important;
  color: #5f6368 !important;
  width: 24px;
  text-align: center;
  transition: color 0.2s ease;
}

/* Hover Effect */
.profile-sidebar .nav-link:hover {
  background-color: #f1f3f4 !important; /* Light Grey Hover */
  color: #202124 !important;
}
.profile-sidebar .nav-link:hover i {
  color: #202124 !important;
}

/* Active State */
.profile-sidebar .nav-link.active {
  background-color: #e8f0fe !important; /* Light Blue BG */
  color: #1967d2 !important; /* Blue Text */
  font-weight: 700 !important;
}
.profile-sidebar .nav-link.active i {
  color: #1967d2 !important;
}

/* --- C. About Me Cards (FIX: 100% Width & Equal Height) --- */
.about-user-lst {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 0 30px 0 !important;
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 20px !important;
}

.about-user-lst li {
  flex: 1 1 200px !important;
  width: 100% !important;
  background: #f8f9fa !important;
  border: 1px solid #e0e0e0 !important;
  border-radius: 16px !important;
  padding: 20px !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  min-height: 130px !important;
  font-weight: 600 !important;
  color: #202124 !important;
  transition: all 0.2s;
}

.about-user-lst li:hover {
  background: #fff !important;
  border-color: #1a73e8 !important;
  box-shadow: 0 4px 12px rgba(26, 115, 232, 0.1) !important;
  transform: translateY(-2px);
}

.about-user-lst li i {
  font-size: 24px !important;
  color: #1a73e8 !important;
  margin-bottom: 10px !important;
  display: block !important;
}

/* --- D. Contact Me Cards (FIX: Row Layout + Blue Circle) --- */
.user-contact .row {
  margin-left: -10px;
  margin-right: -10px;
  display: flex;
  flex-wrap: wrap;
}

.user-contact [class*="col-"] {
  padding-left: 10px;
  padding-right: 10px;
  margin-bottom: 20px;
  display: flex;
}

.contact-user-block {
  display: flex !important;
  flex-direction: row !important; /* Row Layout */
  align-items: center !important;
  background: #f8f9fa !important;
  border: 1px solid #e0e0e0 !important;
  border-radius: 16px !important;
  padding: 15px !important;
  width: 100% !important;
  height: 100% !important;
  box-sizing: border-box !important;
}

.contact-user-block:hover {
  background: #fff !important;
  border-color: #1a73e8 !important;
  box-shadow: 0 4px 12px rgba(26, 115, 232, 0.1) !important;
  transform: translateY(-2px);
}

.contact-user-block .contact-icon {
  flex: 0 0 60px !important;
  width: 60px !important;
  margin-right: 15px !important;
  display: flex;
  justify-content: center;
  align-items: center;
}

.contact-user-block .contact-icon i {
  width: 45px !important;
  height: 45px !important;
  background-color: #e8f0fe !important; /* Blue Circle */
  border-radius: 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 20px !important;
  color: #1a73e8 !important;
}

.contact-user-block .contact-dtls {
  flex: 1 !important;
  text-align: left !important;
  overflow: hidden;
}

.contact-heading {
  font-size: 0.75rem !important;
  text-transform: uppercase;
  font-weight: 700 !important;
  color: #5f6368 !important;
  margin-bottom: 2px !important;
}

.contact-user-block a {
  font-size: 0.95rem !important;
  font-weight: 600 !important;
  color: #202124 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  display: block !important;
}

/* --- E. Other Visuals --- */
.about-heading,
.user-badge-heading,
.setting-block-heading,
.plans-heading,
.delete-heading,
.bookmark-heading,
.refers-heading,
.play-heading {
  font-weight: 700 !important;
  font-size: 1.25rem !important;
  color: #202124 !important;
  margin-bottom: 25px !important;
  padding-bottom: 0 !important;
  border-bottom: none !important;
}

/* --- F. Settings Form & Buttons --- */
.setting-block .form-control {
  background-color: #f1f3f4 !important;
  border: 1px solid transparent !important;
  border-radius: 12px !important;
  padding: 10px 16px !important;
  height: 50px !important;
}
.setting-block .form-control:focus {
  background-color: #fff !important;
  border-color: #1a73e8 !important;
  box-shadow: 0 0 0 4px rgba(26, 115, 232, 0.1) !important;
}
.update-btn,
.plan-btn {
  border-radius: 50px !important;
  padding: 10px 30px !important;
  background-color: #1a73e8 !important;
  border: none !important;
  color: #fff !important;
}
.user-img-btns {
  display: flex !important;
  gap: 15px !important;
  align-items: center !important;
}

/* --- G. Follow Me (FIX: Wrap, LinkedIn & Spacing) --- */
.follow .user-social ul {
  display: flex !important;
  flex-wrap: wrap !important; /* FIX: Prevents Horizontal Scroll */
  gap: 15px !important;
  padding: 0 !important;
  list-style: none !important;
  margin: 0 !important;
}

.follow .user-social ul li a {
  width: 45px !important;
  height: 45px !important;
  border-radius: 12px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: #f1f3f4 !important;
  color: #5f6368 !important;
  transition: all 0.2s !important;
  font-size: 1.2rem !important;
  text-decoration: none !important;
}

.follow .user-social ul li a:hover {
  background: #e8f0fe !important;
  color: #1a73e8 !important;
  transform: translateY(-3px);
}

/* SPECIFIC FIX: Handle LinkedIn icon class mismatch/alignment */
.follow .user-social ul li a i[class*="linked"] {
  display: inline-flex !important;
  justify-content: center !important;
  align-items: center !important;
  line-height: 1 !important;
  width: 100% !important;
  height: 100% !important;
}

/* --- H. Breadcrumbs --- */
.breadcrumb-main-block {
  position: relative;
  padding: 80px 0 80px;
  background-size: cover;
  background-position: center;
  background-color: #1a73e8;
  margin-bottom: 0px;
}
.breadcrumb-main-block .overlay-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1;
}
.breadcrumb-main-block .container {
  position: relative;
  z-index: 2;
}
.breadcrumb-title {
  color: #fff !important;
  font-size: 2.5rem !important;
  margin-bottom: 15px !important;
}
.breadcrumb {
  display: flex;
  justify-content: center;
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
}
.breadcrumb-item,
.breadcrumb-item a {
  color: #fff !important;
  text-decoration: none !important;
}
.breadcrumb-item.active {
  color: rgba(255, 255, 255, 0.8) !important;
}
/* =========================================================
   8. MOBILE PROFILE SIDEBAR: CHEVRON DROPDOWN (Final)
   ========================================================= */

/* Default: Hide the trigger on Desktop */
.mobile-tab-trigger {
    display: none;
}

@media (max-width: 991px) {
    /* 1. HIDE TAB LIST BY DEFAULT */
    /* We use !important to override Bootstrap's default flex display */
    .profile-sidebar .nav-tabs {
        display: none !important; 
        flex-direction: column !important;
        background: #fff;
        border: 1px solid #e0e0e0;
        border-radius: 30px;
        margin-top: -0px;
        box-shadow: 0 4px 15px rgba(0,0,0,0.05);
        overflow: hidden;
        padding: 0;
        width: 100%;
        transition: all 0.3s ease;
    }

    /* 2. SHOW MENU (This matches your script's .toggle('show-menu')) */
    .profile-sidebar .nav-tabs.show-menu {
        display: flex !important;
        animation: fadeInDown 0.3s ease;
    }

    /* 3. THE TRIGGER BUTTON */
    .mobile-tab-trigger {
        display: flex;
        align-items: center;
        justify-content: space-between;
        background: #fff;
        padding: 15px 24px;
        border-radius: 30px;
        border: 1px solid #e0e0e0;
        box-shadow: 0 2px 5px rgba(0,0,0,0.05);
        cursor: pointer;
        margin-bottom: 0px;
        font-weight: 700;
        color: #202124;
        transition: all 0.3s ease;
    }
    
    .mobile-tab-trigger:hover {
        background-color: #f8f9fa;
    }

    /* 4. THE CHEVRON (CSS Arrow - Guaranteed Visibility) */
    /* This targets the <i class="chevron"></i> in your HTML */
    .mobile-tab-trigger .chevron {
        border: solid #5f6368;        /* Grey Color */
        border-width: 0 2px 2px 0;    /* Arrow Shape */
        display: inline-block;
        padding: 4px;                 /* Size of arrow */
        transform: rotate(45deg);     /* Point Down */
        transition: transform 0.3s ease;
        margin-left: 10px;
        margin-bottom: 3px;           /* Alignment fix */
    }
    
    /* 5. ACTIVE STATE (Rotates Arrow Up) */
    /* This matches your script's .toggle('active') */
    .mobile-tab-trigger.active .chevron {
        transform: rotate(-135deg);   /* Flip Up */
        border-color: #1a73e8;        /* Turn Blue */
        margin-top: 5px;              /* Alignment fix when flipped */
        margin-bottom: 0;
    }
    
    /* 6. TAB ITEMS STYLING */
    .profile-sidebar .nav-link {
        border-radius: 0 !important;
        border-bottom: 1px solid #f1f3f4 !important;
        margin: 0 !important;
        width: 100% !important;
        padding: 15px 20px !important;
        background: #fff !important;
    }
    
    .profile-sidebar .nav-link:last-child {
        border-bottom: none !important;
    }

    .profile-sidebar .nav-link:hover {
        background-color: #f8f9fa !important;
    }

    .profile-sidebar .nav-link.active {
        background-color: #e8f0fe !important;
        color: #1a73e8 !important;
        border-left: 4px solid #1a73e8 !important;
    }
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* =========================================================
   9. MOBILE HERO & BREADCRUMB & HEADER SLIDER ADJUSTMENTS
   ========================================================= */
@media (max-width: 768px) {
    
    /* 1. Shrink Hero Title & Subtitle */
    .leaderboard-hero-content h1.animate-item,
    .blog-hero-content h1.animate-item {
        font-size: 1.5rem !important;
        line-height: 1.3 !important;
        padding: 0 15px !important;
        margin-bottom: 10px !important;
    }

    .leaderboard-hero-content p.animate-item,
    .blog-hero-content p.animate-item {
        font-size: 0.95rem !important;
        padding: 0 20px !important;
        line-height: 1.5 !important;
        margin-bottom: 15px !important;
    }

    /* 2. Shrink the Trophy Icon */
    .hero-icon {
        font-size: 45px !important;
        margin-bottom: 12px !important;
    }

    /* 3. Adjust Breadcrumb Image for Mobile */
    .breadcrumb-main-block,
    .blog-hero-premium {
        padding: 60px 0 40px 0 !important; 
        background-position: center center !important; 
        background-size: cover !important;
        min-height: 200px !important;
    }
    
    /* 4. Fix Breadcrumb Links Size */
    .breadcrumb-item, 
    .breadcrumb-item a {
        font-size: 0.85rem !important;
    }
    
    .breadcrumb-title {
        font-size: 1.8rem !important;
        margin-bottom: 12px !important;
    }
    /* Reduce slider heading size */
    .slider-heading {
        font-size: 1.5rem !important;
    }
    .slider-subheading {
        font-size: 0.9rem !important;
    }
    .slider-image-fluid {
        display: none !important;
    }
    /* reduce side of breadcrumb text and hero text */
    .blog-hero-content h1,
    .leaderboard-hero-content h1 {
        font-size: 2.15rem !important;
    }
    .blog-hero-content p,
    .leaderboard-hero-content p {
        font-size: .9rem !important;
        padding-bottom: 30px !important;
    }
    .friends-hero-content h1,
    .friends-hero-title {
        font-size: 2.15rem !important;
    }
    .friends-hero-content p,
    .friends-hero-sub {
        font-size: .9rem !important;
    }

    .ff-hero-content h1,
    .ff-hero-title {
        font-size: 2.15rem !important;
    }
    .ff-hero-content p,
    .ff-hero-sub {
        font-size: .9rem !important;
    }
    /* Rearrange nav-pill on mobile */
    .btn-premium-action {
        font-size: 1rem !important;
        padding: 12px 18px 12px 18px !important;
    }   
    /* 1. Fix the Container */
    .friends-nav-container {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important; 
        justify-content: space-between !important;
        align-items: center !important;
        gap: 5px !important; 
        width: 100% !important;
        padding: 0 10px !important; 
        box-sizing: border-box !important;
        margin-bottom: 30px !important;
        overflow: visible !important; 
    }
    /* 2. Fix the Buttons (Allow shrinking) */
    .nav-pill-item {
        flex: 1 1 auto !important; 
        width: auto !important;
        min-width: 120px !important; 
        /* Reduce Size to Fit */
        padding: 10px 5px !important;
        font-size: 11px !important; 
        border-radius: 18px !important; 
        /* Layout inside the button */
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        gap: 4px !important;
    }

    /* 3. Adjust Icon Size */
    .nav-pill-item i {
        font-size: 12px !important;
        margin: 0 !important;
    }

    /* 4. Adjust Badge (The red '0') */
    .nav-pill-item .badge-count {
        font-size: 9px !important;
        padding: 1px 5px !important;
        margin-left: 2px !important;
    }

}
/* =========================================================
   10. MOBILE HOMEPAGE BANNERS FIX (Newsletter & Find Friend)
   ========================================================= */
@media (max-width: 768px) {

    /* --- 1. FIND FRIEND BANNER (Orange Card) --- */
    
    /* Main Container */
    .find-friend-main-block {
        padding: 10px 15px !important;
        margin: 10px 10px !important;
    }
    
    .custom-find-friend-banner {
        padding: 10px 10px !important;
        border-radius: 20px !important;
        min-height: auto !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
    }
    
    /* Content Wrapper */
    .ff-content {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        width: 100% !important;
        margin-bottom: 0 !important;
    }
    
    /* Heading - Allow wrapping naturally */
    .ff-heading {
        font-size: 16px !important;
        line-height: 1.4 !important;
        margin-bottom: 20px !important;
        white-space: normal !important;
        text-align: center !important;
        font-weight: 700 !important;
        padding: 0 5px !important;
        word-wrap: break-word !important;
    }

    /* Button Styling */
    .ff-btn {
        min-width: 160px !important;
        max-width: 220px !important;
        width: auto !important;
        display: inline-flex !important;
        justify-content: center !important;
        align-items: center !important;
        gap: 8px !important;
        border-radius: 50px !important;
        height: 44px !important;
        font-size: 14px !important;
        font-weight: 600 !important;
        padding: 0 24px !important;
        white-space: nowrap !important;
        text-decoration: none !important;
    }
    
    /* Hide images grid on mobile (already hidden via d-none d-lg-grid) */
    .ff-images-grid {
        display: none !important;
    }

    /* --- 2. NEWSLETTER BANNER (Purple Card) --- */

    /* Main Container */
    .newsletter-main-block {
        padding: 10px 15px !important;
        margin: 10px 10px !important;
    }
    
    .custom-newsletter-wrapper {
        padding: 20px 10px !important;
        border-radius: 20px !important;
        min-height: auto !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
    }

    /* Content Container */
    .newsletter-content {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        width: 100% !important;
        text-align: center !important;
    }

    /* Headings */
    .newsletter-heading {
        font-size: 20px !important;
        margin-bottom: 10px !important;
        text-align: center !important;
        font-weight: 700 !important;
        line-height: 1.3 !important;
    }

    .newsletter-sub {
        font-size: 14px !important;
        margin-bottom: 20px !important;
        text-align: center !important;
        display: block !important;
        line-height: 1.5 !important;
        opacity: 0.95 !important;
        padding: 0 10px !important;
    }

    /* Form: Stack Vertically */
    .custom-newsletter-form {
        display: flex !important;
        flex-direction: row !important;
        gap: 12px !important;
        width: 100% !important;
        max-width: 400px !important;
        margin: 0 auto !important;
    }

    .custom-newsletter-form input[type="email"] {
        width: 65% !important;
        height: 44px !important;
        font-size: 14px !important;
        text-align: left !important;
        padding: 0 16px !important;
        border-radius: 50px !important;
        border: 2px solid rgba(255, 255, 255, 0.3) !important;
    }

    .custom-newsletter-form button[type="submit"] {
        width: 35% !important;
        height: 44px !important;
        border-radius: 50px !important;
        font-size: 14px !important;
        font-weight: 600 !important;
        margin-top: 0 !important;
        padding: 0 24px !important;
    }
    
    /* Hide newsletter image on mobile (already hidden via d-none d-md-block) */
    .newsletter-img-wrapper {
        display: none !important;
    }
    
    /* Hide decorative circles on mobile */
    .newsletter-circle {
        display: none !important;
    }
}
/* =========================================
  11. MOBILE FIXES FOR QUIZ PAGE (FINAL CORRECTED)
   ========================================= */

@media (max-width: 991px) {
    
    /* --- 1. REDUCE PAGE PADDING --- */
    .quiz-question-main-block {
        padding-top: 20px !important;
        padding-bottom: 30px !important;
    }

    /* --- 2. TOP HEADER (Title & End Quiz Button) --- */
    .quiz-question-main-block > .container > .row:first-child {
        display: flex !important;
        justify-content: flex-end !important;
        margin-bottom: 15px !important;
    }
    
    .quiz-question-main-block > .container > .row:first-child .col-lg-9 {
        display: none !important;
    }
    
    .quiz-question-main-block > .container > .row:first-child .col-lg-3 {
        width: 100% !important;
        text-align: center !important;
        flex: 0 0 100% !important;
        padding: 0 !important;
    }
    
    /* --- "END QUIZ" BUTTON STYLES (Red Hover) --- */
    .back-btn {
        width: auto !important;
        min-width: 140px !important;
        padding: 8px 30px !important;
        border: 2px solid #e0e0e0 !important;
        border-radius: 24px !important;
        background-color: #fff !important;
        color: #333 !important;
        font-weight: 600 !important;
        transition: all 0.3s ease !important;
    }

    /* Red Background + White Text on Hover */
    .back-btn:hover,
    .back-btn:active,
    .back-btn:focus {
        background-color: #dc3545 !important; /* RED */
        color: #ffffff !important;            /* WHITE */
        border-color: #dc3545 !important;
    }

    /* --- 3. TOP CHIPS (Timer & Badge) --- */
    .question-top {
        padding: 15px !important;
        background: #f8f9fa !important;
        border-radius: 12px !important;
        margin-bottom: 20px !important;
    }

    .question-top .row {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 10px !important;
    }

    .question-top .col-lg-4 {
        width: 100% !important;
        text-align: center !important;
        margin-bottom: 0 !important;
    }

    .question-badge {
        font-size: 0.9rem !important;
        padding: 6px 16px !important;
        border-radius: 20px !important;
        background: #e9ecef !important;
        color: #495057 !important;
        display: inline-block !important;
    }

    .quiz-name {
        font-size: 1.1rem !important;
        font-weight: 700 !important;
        margin: 5px 0 !important;
    }

    .timer-container {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        background-color: #dc3545 !important;
        color: #fff !important;
        padding: 8px 20px !important;
        border-radius: 50px !important;
    }

    .timer-heading, .timer {
        color: #fff !important;
        margin: 0 !important;
        font-weight: 600 !important;
    }

    /* --- 4. OPTIONS (BLUE Style + Extra Left Padding) --- */
    .option-block .row {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        margin: 0 !important;
    }

    .option-block .row > div {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
    }

    .option-block label.btn.options {
        width: 100% !important;
        display: flex !important;
        align-items: center !important;
        text-align: left !important;
        /* INCREASED LEFT PADDING (25px) */
        padding: 15px 15px 15px 25px !important; 
        white-space: normal !important;
        
        /* RESTORED BLUE THEME COLORS */
        background-color: #ffffff !important;
        border: 2px solid #dadce0 !important;
        border-radius: 10px !important;
        color: #202124 !important;
        box-shadow: none !important;
        margin: 0 !important;
        height: auto !important;
    }

    .option-block label.btn.options input[type="radio"] {
        display: block !important;
        visibility: hidden !important;
        opacity: 1 !important;
        margin-right: 15px !important;
        width: 20px !important;
        height: 20px !important;
        flex-shrink: 0 !important;
        accent-color: #1a73e8 !important; /* BLUE RADIO */
    }

    /* SELECTED STATE (Blue Border + Light Blue BG) */
    .option-block label.btn.options:has(input:checked),
    .option-block label.btn.options.active {
        background-color: #e8f0fe !important; /* Light Blue */
        border-color: #1a73e8 !important;     /* Blue Border */
        color: #1967d2 !important;            /* Dark Blue Text */
        border-width: 2px !important;
    }

    /* --- 5. NAVIGATION BUTTONS (50/50 Layout) --- */
    .question-block > form > .row:last-child {
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        margin-top: 20px !important;
        padding-bottom: 30px !important;
    }

    .question-block > form > .row:last-child .col-lg-6:first-child {
        width: 50% !important;
        flex: 0 0 50% !important;
        padding-right: 8px !important;
        text-align: left !important;
    }

    .question-block > form > .row:last-child .col-lg-6:last-child {
        width: 50% !important;
        flex: 0 0 50% !important;
        padding-left: 8px !important;
        text-align: right !important;
    }

    .prev-btn, .next-btn, #submitBtn {
        width: 100% !important;
        padding: 12px 0 !important;
        border-radius: 8px !important;
        font-weight: 600 !important;
    }
}

/* =========================================
   12. CUSTOM UI IMPROVEMENTS (Discover Page)
   ========================================= */

/* 1. Floating Edit Button (Top Right) */
.quiz-edit-icon {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 10;
    width: 40px;
    height: 40px;
    background-color: #ffffff;   /* Normal: White Background */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    color: #FF0000;              /* Normal: Red Icon */
    text-decoration: none;
    border: 1px solid #ffffff;   /* Normal: White Border (invisible) */
}

/* Hover State */
.quiz-edit-icon:hover {
    background-color: #ffffff;   /* Hover: Keep White Background */
    color: #FF0000;              /* Hover: Keep Red Icon */
    border: 2px solid #ff9f43;   /* Hover: Add Orange Border */
    transform: scale(1.1);       /* Slight Zoom Effect */
    cursor: pointer;
}

/* 2. Fee Chip Style (Free/Paid) */
.fee-chip {
    display: inline-block;
    padding: 6px 16px;
    border: 1px solid #ff9f43; /* Orange Border */
    color: #ff9f43;
    border-radius: 50px;
    font-weight: 600;
    font-size: 14px;
    background: transparent;
    transition: all 0.3s ease;
}

.fee-chip i {
    margin-right: 5px;
}

/* 3. Card Positioning Fix */
/* This ensures the absolute position of the edit button stays inside the card */
.discover-block {
    position: relative !important;
}
/* =========================================================
   13. MOBILE DISCOVER PAGE FIXES (FINAL)
   ========================================================= */

/* Default: Hide Mobile Filters on Desktop */
.mobile-filter-container {
    display: none !important;
}

@media (max-width: 991px) {
    
    /* 1. HIDE OLD SIDEBAR (Removes Duplication) */
    .explore-categories {
        display: none !important;
    }

    /* 2. SHOW NEW MOBILE FILTER CONTAINER */
    .mobile-filter-container {
        display: flex !important;
        flex-wrap: wrap !important; /* Critical: Allows items to stack */
        gap: 10px !important;
        margin-bottom: 20px !important;
        width: 100% !important;
        position: relative;
        z-index: 20; 
    }

    /* 3. ROW 1: SEARCH BAR (Force Full Width) */
    .mobile-filter-container .search-input {
        flex: 0 0 100% !important; /* 100% width forced */
        width: 100% !important;
        max-width: 100% !important;
        margin-bottom: 5px !important;
        order: 1; /* Ensure it's first */
    }

    /* 4. ROW 2: FILTERS (Share Space Equally) */
    .mobile-filter-group {
        flex: 1 1 0 !important; /* Grow evenly */
        width: 0 !important;    /* Allows text truncation to work */
        position: relative;     /* Anchor for dropdown */
        order: 2;               /* Ensure they are second */
    }

    /* 5. TRIGGER BUTTON STYLING */
    .mobile-filter-trigger {
        display: flex;
        align-items: center;
        justify-content: space-between;
        background: #fff;
        padding: 0 12px;
        border-radius: 12px;
        border: 1px solid #dadce0;
        box-shadow: 0 1px 2px rgba(0,0,0,0.05);
        height: 48px;
        font-size: 0.85rem;
        font-weight: 600;
        color: #3c4043;
        white-space: nowrap;
        overflow: hidden;
    }

    .mobile-filter-trigger span {
        overflow: hidden;
        text-overflow: ellipsis;
        margin-right: 5px;
    }

    /* Active State (Blue Border) */
    .mobile-filter-trigger.has-selection {
        border: 2px solid #1a73e8;
        background-color: #f8fbff;
        color: #1a73e8;
    }

    /* Chevron Icon */
    .mobile-filter-trigger .chevron {
        border: solid #5f6368;
        border-width: 0 2px 2px 0;
        display: inline-block;
        padding: 3px;
        transform: rotate(45deg);
        flex-shrink: 0;
    }

    .mobile-filter-trigger.has-selection .chevron {
        border-color: #1a73e8;
    }

    /* 6. DROPDOWN LIST (Floats on Top) */
    .mobile-filter-list {
        display: none; /* Hidden by default */
        position: absolute;
        top: 55px;
        left: 0;
        min-width: 250px;
        max-width: 90vw;
        background: #fff;
        border: 1px solid #e0e0e0;
        border-radius: 12px;
        padding: 8px 0;
        box-shadow: 0 10px 30px rgba(0,0,0,0.15);
        z-index: 9999 !important; /* Critical: Sit on top of quiz cards */
    }

    /* Show State (Toggled by JS) */
    .mobile-filter-list.show-filter {
        display: block !important;
    }

    /* Floating Label (Categories/Price/Type) */
    .mobile-top-label {
        display: none;
        position: absolute;
        top: -9px;
        left: 10px;
        font-size: 0.65rem;
        font-weight: 700;
        color: #1a73e8;
        background: #fff;
        padding: 0 4px;
        z-index: 5;
    }

    /* Dropdown Items */
    .mobile-filter-list ul { padding: 0; margin: 0; list-style: none; }
    .mobile-filter-list li a, 
    .mobile-filter-list .form-check-label {
        display: flex;
        justify-content: space-between;
        padding: 12px 16px;
        color: #3c4043;
        font-size: 0.9rem;
        border-bottom: 1px solid #f1f3f4;
        text-decoration: none;
        align-items: center;
    }
    
    .mobile-filter-list li:last-child a { border-bottom: none; }
    
    .mobile-filter-list li.active a {
        background-color: #e8f0fe;
        color: #1a73e8;
        font-weight: 600;
    }
}
/* =========================================
   14. ADMIN EXAM GENERATOR STYLES
   ========================================= */

/* 1. BLUE INFO BOX */
.placeholder-box {
    border: 2px dashed #4e73df;
    border-radius: 15px;
    color: #4e73df;
    background-color: #f0f4ff;
    padding: 40px 20px;
    text-align: center;
    font-weight: 600;
    margin: 15px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.placeholder-box i {
    font-size: 30px;
    margin-bottom: 10px;
}

/* 2. ROW LAYOUT (Prevent Jumping) */
.criteria-row {
    border: 1px solid #b0b3b8; /* Darker border for visibility */
    border-left: 5px solid #4e73df; /* Blue accent */
    border-radius: 8px;
    background-color: #fff;
    transition: all 0.3s ease;
    margin-bottom: 14px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.criteria-row:hover {
    box-shadow: 0 5px 14px rgba(0,0,0,0.1);
}

/* FIX: Only align items to the top INSIDE the criteria row */
/* If you use global .align-items-center { align-items: flex-start !important }, it breaks the Footer alignment */
.criteria-row .row {
    align-items: flex-start !important; 
    padding-top: 5px;
}

/* Wrapper to stack Select + Badge vertically */
.topic-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Badge Container - Fixed height prevents jumping */
.avail-badge-container {
    min-height: 20px; 
    margin-top: 4px;
    line-height: 1;
}

/* 3. TYPOGRAPHY OVERRIDES */

/* Topic Dropdown */
select.topic-select {
    font-size: 14px !important;
    font-weight: 600 !important; /* Made slightly bolder for readability */
    color: #2e3e50 !important;
    height: 45px !important;
}

/* Dropdown Options */
.select2-results__option {
    font-size: 15px;
    font-weight: 500;
    color: #2e3e50;
}

/* Input Fields */
.count-input {
    font-size: 16px !important;
    font-weight: 600 !important;
    height: 45px !important;
    text-align: center;
}

/* Qty Label */
.input-group-text {
    font-weight: normal !important;
    /* FIX: 'none' is invalid CSS for background-color. Use 'transparent' */
    background-color: transparent !important; 
    font-size: 14px;
    color: #444 !important;
    border: none !important;
}
/* =========================================
   15. NAVIGATION LAYERING FIXES (FINAL SAFE)
   ========================================= */

/* 1. Force Mobile Bottom Bar Above Content */
.mobile-bottom-bar {
    position: fixed !important;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 99999 !important;
}

/* 2. Ensure Dropdown Menus Float Over Everything */
.dropdown-menu {
    z-index: 100000 !important;
}

/* 3. Push Breadcrumb Back (So menus float over it) */
#breadcrumb, 
.breadcrumb-main-block {
    z-index: 1 !important;
    position: relative !important;
}