/* ==========================================================================
   GESTURA AI - Student Dashboard Stylesheet
   ========================================================================== */

.dashboard-hero {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

/* Student Profile Banner */
.profile-card {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  position: relative;
  overflow: hidden;
}

.student-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.2), rgba(37, 99, 235, 0.4));
  border: 2px solid var(--cyan-core);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-family-tech);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--cyan-core);
  box-shadow: 0 0 15px var(--cyan-glow);
  flex-shrink: 0;
}

.profile-meta h2 {
  font-family: var(--font-family-tech);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.profile-meta .tvet-badge {
  font-size: 0.72rem;
  background: rgba(37, 99, 235, 0.25);
  color: var(--blue-neon);
  border: 1px solid rgba(56, 189, 248, 0.4);
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
}

.profile-meta .student-institute {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 0.2rem;
}

/* XP & Level Progress Bar */
.xp-container {
  margin-top: 0.8rem;
  width: 100%;
}

.xp-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  font-family: var(--font-family-tech);
  color: var(--text-secondary);
  margin-bottom: 0.3rem;
}

.xp-progress-bar-bg {
  width: 100%;
  height: 8px;
  background: rgba(15, 23, 42, 0.8);
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.xp-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--blue-electric), var(--cyan-core));
  border-radius: 4px;
  box-shadow: 0 0 8px var(--cyan-glow);
  transition: width 0.8s ease;
}

/* Quick Metrics Row */
.stats-overview-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.stat-widget {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.stat-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 240, 255, 0.1);
  color: var(--cyan-core);
  border: 1px solid rgba(0, 240, 255, 0.2);
}

.stat-icon.warning {
  background: rgba(245, 158, 11, 0.1);
  color: var(--warning);
  border-color: rgba(245, 158, 11, 0.3);
}

.stat-icon.success {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success);
  border-color: rgba(16, 185, 129, 0.3);
}

.stat-content .stat-val {
  font-family: var(--font-family-tech);
  font-size: 1.6rem;
  font-weight: 700;
  line-height: 1;
  color: var(--text-primary);
}

.stat-content .stat-label {
  font-size: 0.78rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.25rem;
}

/* Learning Modules Grid (Phase 1 + Future Roadmap) */
.modules-section {
  margin-bottom: 2.5rem;
}

.modules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 1.5rem;
}

.module-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  transition: var(--transition-normal);
}

.module-card.active-module {
  border-color: rgba(0, 240, 255, 0.45);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.1);
}

.module-card.roadmap-preview {
  opacity: 0.75;
  border-style: dashed;
}

.module-card:hover {
  transform: translateY(-4px);
  border-color: var(--cyan-core);
}

.module-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
}

.module-icon-wrap {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: rgba(37, 99, 235, 0.2);
  border: 1px solid rgba(56, 189, 248, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan-core);
}

.module-badge {
  font-family: var(--font-family-tech);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.2rem 0.6rem;
  border-radius: var(--pill-radius);
}

.module-badge.ready {
  background: rgba(16, 185, 129, 0.15);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.module-badge.roadmap {
  background: rgba(148, 163, 184, 0.15);
  color: var(--text-muted);
  border: 1px solid rgba(148, 163, 184, 0.25);
}

.module-title {
  font-family: var(--font-family-tech);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
}

.module-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin-bottom: 1.25rem;
  flex: 1;
}

.module-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 1rem;
}

.module-progress-info {
  font-size: 0.8rem;
  color: var(--cyan-core);
  font-family: var(--font-family-tech);
  font-weight: 600;
}

/* AC Components Master Status in Explore */
.components-master-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-top: 1rem;
}

.component-status-card {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.component-status-card:hover {
  background: rgba(20, 34, 68, 0.7);
  border-color: var(--cyan-core);
}

.comp-status-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.comp-status-name {
  font-family: var(--font-family-tech);
  font-weight: 700;
  font-size: 0.95rem;
}

.comp-pill {
  font-size: 0.65rem;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
}

.comp-pill.completed {
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
}

.comp-pill.pending {
  background: rgba(245, 158, 11, 0.2);
  color: var(--warning);
}

@media (max-width: 900px) {
  .dashboard-hero {
    grid-template-columns: 1fr;
  }
  .stats-overview-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .components-master-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 580px) {
  .stats-overview-grid {
    grid-template-columns: 1fr;
  }
  .components-master-list {
    grid-template-columns: 1fr;
  }
}
