/* Student Dashboard Styles - TronMenders (based on community.css) */

body {
    background-color: #0a0a0a;
    color: #FFFFFF;
    font-family: 'Sora', sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Space Grotesk', sans-serif;
}

.font-space {
    font-family: 'Space Grotesk', sans-serif;
}

.glassmorphism {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Hide elements with CSS instead of inline styles */
.hidden {
    display: none !important;
}

.dashboard-card {
  background: linear-gradient(
    135deg,
    rgba(31, 41, 55, 0.8) 0%,
    rgba(17, 24, 39, 0.9) 100%
  );
  backdrop-filter: blur(10px);
  border: 1px solid rgba(34, 197, 94, 0.2);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.dashboard-card:hover {
  transform: translateY(-4px);
  border-color: rgba(34, 197, 94, 0.4);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1),
    0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.metric-card {
  background: linear-gradient(
    135deg,
    rgba(16, 185, 129, 0.1) 0%,
    rgba(5, 150, 105, 0.15) 100%
  );
  border-left: 4px solid #10b981;
}

/* Hero section specific styles matching theme documentation */
.hero-section {
  position: relative;
  overflow: hidden;
  background: linear-gradient(to bottom right,
    #111827,    /* gray-900 */
    #1f2937,    /* gray-800 */
    #000000);   /* black */
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: 16px;
  margin: 0 24px;
}

/* Hide any unwanted pseudo-elements or background graphics in hero section */
.hero-section *::before,
.hero-section *::after {
  display: none !important;
}

.hero-section::before,
.hero-section::after {
  display: none !important;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right,
    rgba(34, 197, 94, 0.05),  /* green-500/5 */
    rgba(59, 130, 246, 0.05)); /* blue-500/5 */
}

.hero-content {
  position: relative;
  z-index: 10;
  padding: 24px 24px;
}

@media (min-width: 768px) {
  .hero-content {
    padding: 32px 32px;
  }
}

/* Professional badge styling */
.professional-badge {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: 9999px;
  padding: 8px 16px;
  margin-bottom: 16px;
  display: inline-flex;
  align-items: center;
}

.professional-badge .pulse-dot {
  width: 8px;
  height: 8px;
  background-color: #10b981;
  border-radius: 50%;
  margin-right: 8px;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

/* Gradient text effect for hero titles */
.gradient-text {
  background: linear-gradient(to right, #ffffff, #d1d5db);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* Metric cards styling matching theme */
.metric-card-enhanced {
  background: rgba(31, 41, 55, 0.5);
  border: 1px solid #374151;
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  backdrop-filter: blur(4px);
  transition: all 0.3s ease;
}

.metric-card-enhanced.loading {
  opacity: 0.7;
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.metric-card-enhanced.loading .metric-number {
  background: linear-gradient(90deg, #374151, #4b5563, #374151);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

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

.metric-number {
  font-size: 24px;
  font-weight: bold;
  margin-bottom: 4px;
}

.metric-label {
  font-size: 12px;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Tab styling */
.tab-btn {
  cursor: pointer;
  position: relative;
  z-index: 20;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.tab-btn:hover {
  color: white !important;
  background-color: rgba(34, 197, 94, 0.1) !important;
}

.tab-btn.active {
  color: #4ade80 !important;
  border-bottom-color: #4ade80 !important;
}

/* Vertical Course Card Styling - Optimized for 4-column layout */
.course-card {
  min-height: 380px;
  max-height: 450px;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.course-card:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 197, 94, 0.5);
  box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.25),
              0 0 0 1px rgba(34, 197, 94, 0.1);
}

/* Course image container styling */
.course-card .course-image {
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(16, 185, 129, 0.1));
  border: 1px solid rgba(34, 197, 94, 0.2);
  transition: all 0.3s ease;
}

.course-card:hover .course-image {
  border-color: rgba(34, 197, 94, 0.4);
  box-shadow: 0 6px 12px rgba(34, 197, 94, 0.1);
}

/* Progress bar enhancements */
.course-progress-bar {
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 4px rgba(34, 197, 94, 0.2);
}

/* Course grid layout adjustments */
#my-courses-list {
  gap: 1.25rem;
  justify-items: center;
}

@media (min-width: 768px) {
  #my-courses-list {
    gap: 1.5rem;
  }
  
  .course-card {
    max-width: 340px;
  }
}

@media (min-width: 1024px) {
  .course-card {
    max-width: 300px;
  }
  
  #my-courses-list {
    gap: 1.25rem;
  }
}

@media (min-width: 1280px) {
  .course-card {
    max-width: 320px;
  }
  
  #my-courses-list {
    gap: 1.5rem;
  }
}

@media (min-width: 1536px) {
  .course-card {
    max-width: 360px;
  }
  
  #my-courses-list {
    gap: 1.75rem;
  }
}

/* Browse More Card styling */
.course-card.browse-more {
  border: 2px dashed rgba(75, 85, 99, 0.5);
  background: linear-gradient(135deg, 
    rgba(59, 130, 246, 0.05), 
    rgba(147, 51, 234, 0.05));
}

.course-card.browse-more:hover {
  border-color: rgba(34, 197, 94, 0.4);
  background: linear-gradient(135deg, 
    rgba(34, 197, 94, 0.05), 
    rgba(16, 185, 129, 0.05));
}

/* Ensure navigation tabs are perfectly centered with background */
.spa-nav-container {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  width: 100% !important;
  padding: 12px !important;
  margin: 0 auto !important;
  max-width: max-content !important;
  background: linear-gradient(135deg, rgba(31, 41, 55, 0.6) 0%, rgba(17, 24, 39, 0.8) 100%) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(34, 197, 94, 0.2) !important;
  border-radius: 16px !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3) !important;
}

.spa-nav-tabs {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 0.25rem !important;
  flex-wrap: wrap !important;
  margin: 0 auto !important;
  max-width: max-content !important;
}

/* Override any Tailwind spacing */
.spa-nav-tabs > * {
  margin: 0 !important;
}

.spa-nav-tabs > *:not(:last-child) {
  margin-right: 0.25rem !important;
}

/* Alternative centering method */
.spa-nav-container-alt {
  text-align: center !important;
  width: 100% !important;
}

.spa-nav-tabs-alt {
  display: inline-flex !important;
  gap: 0.25rem !important;
  text-align: center !important;
}

/* Fallback CSS when TailwindCSS doesn't load */
@media (max-width: 0) { /* This ensures it only applies if Tailwind fails */
  .hidden { display: none !important; }
  .md\:hidden { display: block !important; }
  .md\:flex { display: none !important; }
}

/* Ultra-Aggressive Mobile Menu Visibility */
@media (max-width: 767px) {
  /* Force mobile menu to be visible when JavaScript toggles it */
  #mobile-menu:not(.hidden) {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    width: 100% !important;
    background-color: rgba(31, 41, 55, 0.95) !important;
    border-top: 1px solid rgba(34, 197, 94, 0.2) !important;
    padding: 16px !important;
    z-index: 1000 !important;
  }
  
  /* Force all mobile menu links to be visible */
  #mobile-menu a {
    display: flex !important;
    align-items: center !important;
    padding: 12px 16px !important;
    color: #d1d5db !important;
    text-decoration: none !important;
    border-radius: 8px !important;
    margin-bottom: 8px !important;
    transition: all 0.2s !important;
    background-color: transparent !important;
  }
  
  #mobile-menu a:hover {
    background-color: rgba(34, 197, 94, 0.1) !important;
    color: white !important;
  }
  
  /* Force mobile menu icons to be visible */
  #mobile-menu svg {
    width: 20px !important;
    height: 20px !important;
    margin-right: 12px !important;
    color: inherit !important;
    fill: currentColor !important;
    stroke: currentColor !important;
  }
  
  /* Force mobile menu text to be visible */
  #mobile-menu span,
  #mobile-menu .text-white,
  #mobile-menu .text-gray-300 {
    color: #d1d5db !important;
    font-size: 16px !important;
    font-weight: 500 !important;
  }
  
  /* Force mobile menu button to be visible */
  #mobile-menu-button {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background-color: rgba(31, 41, 55, 0.8) !important;
    border: 1px solid rgba(34, 197, 94, 0.3) !important;
    border-radius: 8px !important;
    padding: 8px !important;
    color: white !important;
    width: 40px !important;
    height: 40px !important;
  }
  
  #mobile-menu-button svg {
    width: 24px !important;
    height: 24px !important;
    color: white !important;
    stroke: white !important;
    fill: none !important;
    stroke-width: 2 !important;
  }
}

/* Professional Mobile Menu Styling with Enhanced Visibility */
/* Ultra-aggressive mobile menu text visibility */
#mobile-menu * {
  color: #d1d5db !important;
  visibility: visible !important;
  opacity: 1 !important;
}

#mobile-menu a * {
  color: inherit !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/* Force mobile menu hamburger button to be ultra-visible */
#mobile-menu-button {
  background-color: #374151 !important;
  border: 2px solid #10b981 !important;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.5) !important;
}

/* Force mobile menu container to be ultra-visible */
#mobile-menu {
  background-color: rgba(31, 41, 55, 0.98) !important;
  border: 2px solid rgba(34, 197, 94, 0.5) !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5) !important;
}

/* Force all mobile menu links to have visible text */
#mobile-menu a span,
#mobile-menu a div,
#mobile-menu a {
  color: #e5e7eb !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8) !important;
}

/* Force logout button to be visible */
#mobile-menu .logout-btn {
  background-color: rgba(239, 68, 68, 0.2) !important;
  border: 1px solid rgba(239, 68, 68, 0.4) !important;
  color: #f87171 !important;
}

/* Force all SVG icons in mobile menu to be visible */
#mobile-menu svg {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  fill: none !important;
  stroke: currentColor !important;
  stroke-width: 2 !important;
}

/* Force FontAwesome icons in mobile menu to be visible */
#mobile-menu i {
  display: inline-block !important;
  visibility: visible !important;
  opacity: 1 !important;
  color: inherit !important;
}

/* Force desktop navigation visibility on larger screens */
@media (min-width: 768px) {
  .hidden.md\:flex {
    display: flex !important;
    align-items: center;
    gap: 8px;
  }
  
  .hidden.md\:flex a {
    padding: 8px 16px;
    border-radius: 8px;
    color: #d1d5db;
    text-decoration: none;
    transition: all 0.2s;
  }
  
  .hidden.md\:flex a:hover {
    background: rgba(34, 197, 94, 0.1);
    color: white;
  }
  
  #mobile-menu-button {
    display: none !important;
  }
}

/* Fallback text and icon visibility when TailwindCSS fails */
body {
  color: #ffffff !important;
  background-color: #111827 !important;
}

/* Ensure all text is visible */
h1, h2, h3, h4, h5, h6, p, span, div, a, button, li, td, th, label {
  color: inherit !important;
}

/* Specific text color overrides */
.text-white { color: #ffffff !important; }
.text-gray-300 { color: #d1d5db !important; }
.text-gray-400 { color: #9ca3af !important; }
.text-green-400 { color: #4ade80 !important; }
.text-blue-400 { color: #60a5fa !important; }
.text-purple-400 { color: #c084fc !important; }
.text-yellow-400 { color: #facc15 !important; }
.text-red-400 { color: #f87171 !important; }
.text-orange-400 { color: #fb923c !important; }
.text-indigo-400 { color: #818cf8 !important; }

/* Background colors */
.bg-gray-900 { background-color: #111827 !important; }
.bg-gray-800 { background-color: #1f2937 !important; }
.bg-gray-700 { background-color: #374151 !important; }

/* FontAwesome icons visibility */
i.fas, i.far, i.fab {
  color: inherit !important;
}

/* Ensure main content is visible */
main {
  color: #ffffff !important;
}

/* Header visibility */
header {
  background-color: rgba(31, 41, 55, 0.95) !important;
  border-bottom: 1px solid rgba(34, 197, 94, 0.2) !important;
}

/* Navigation text visibility */
nav a {
  color: #d1d5db !important;
}

/* Button visibility */
button {
  color: #ffffff !important;
}

/* Form elements visibility */
input, select, textarea {
  color: #ffffff !important;
  background-color: #374151 !important;
  border: 1px solid #4b5563 !important;
}

/* Card backgrounds */
.glassmorphism,
.bg-gradient-to-br {
  background: rgba(31, 41, 55, 0.8) !important;
  border: 1px solid rgba(34, 197, 94, 0.3) !important;
}

/* Ensure navigation links are clickable */
.nav-link-enhanced {
  position: relative;
  z-index: 10;
}

/* Dashboard card styles */
.dashboard-card {
  background: rgba(31, 41, 55, 0.8) !important;
  border: 1px solid rgba(34, 197, 94, 0.3) !important;
  backdrop-filter: blur(10px);
}
