/* Dashboard Specific Styles - Extending styles.css */
.dashboard-section .section-header {
  margin-bottom: 0;
}

/* Dashboard Layout */
.dashboard-section {
  padding: 5rem 0;
  min-height: 80vh;
}

@media (min-width: 1024px) {
  .dashboard-section {
    padding: 8rem 0;
  }
}

.dashboard-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .dashboard-layout {
    grid-template-columns: 280px 1fr;
    gap: 3rem;
  }
}

/* Dashboard Sidebar */
.dashboard-sidebar {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.05); /* Matching border style */
  border-radius: 1rem;
  padding: 1.5rem;
  height: fit-content;
  position: sticky;
  top: 100px;
}

@media (max-width: 1024px) {
  .dashboard-sidebar {
    display: block;
    position: relative;
    top: 0;
    width: 100%;
    margin-bottom: 2rem;
    z-index: 10;
  }
}

.user-profile-summary {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 1.5rem;
}

.user-avatar {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--primary), #059669);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #fff;
  font-size: 1.25rem;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.user-info h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.25rem;
}

.user-info .user-role {
  font-size: 0.75rem;
  color: var(--primary);
  background: rgba(52, 211, 153, 0.1);
  padding: 0.25rem 0.5rem;
  border-radius: 999px;
  display: inline-block;
}

.dashboard-menu {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dashboard-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  color: var(--text-muted);
  font-weight: 600;
  border-radius: 0.5rem;
  transition: all 0.3s;
}

.dashboard-link:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.dashboard-link.active {
  background: rgba(52, 211, 153, 0.1);
  color: var(--primary);
}

.dashboard-link i {
  width: 1.25rem;
  text-align: center;
}

/* Dashboard Content Area */
.dashboard-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

/* Welcome Card (Replacing the colorful banner with something more integrated) */
.dashboard-welcome {
  background: linear-gradient(to right, rgba(52, 211, 153, 0.1), transparent);
  border: 1px solid rgba(52, 211, 153, 0.2);
  border-radius: 1rem;
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.welcome-text h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #fff;
}

.welcome-text p {
  color: var(--text-muted);
}

/* Video Player Area */
.video-player-wrapper {
  background: #000;
  border-radius: 1rem;
  overflow: hidden;
  aspect-ratio: 16/9;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.video-title {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #fff;
}

.video-info {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  color: var(--text-muted);
  font-size: 0.875rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.video-description {
  color: var(--text-muted);
  line-height: 1.7;
  margin-top: 1.5rem;
}

/* Stats Cards for Training Dashboard */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 1rem;
}

.d-stat-card {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 1.5rem;
  border-radius: 1rem;
}

.d-stat-value {
  font-size: 2rem;
  font-weight: 900;
  color: #fff;
  margin-bottom: 0.25rem;
}

.d-stat-label {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Live Session Card */
.live-session-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 1rem;
  overflow: hidden;
  transition: all 0.3s ease;
  text-decoration: none;
  color: inherit;
}

@media (min-width: 768px) {
  .live-session-card {
    flex-direction: row;
    align-items: stretch;
    min-height: 180px;
  }
}

.live-session-card:hover {
  transform: translateY(-4px);
  border-color: rgba(52, 211, 153, 0.3);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.live-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  flex-shrink: 0;
  overflow: hidden;
}

@media (min-width: 768px) {
  .live-card-thumb {
    width: 320px;
    aspect-ratio: auto;
  }
}

.live-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.live-session-card:hover .live-thumb-img {
  transform: scale(1.05);
}

.live-card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s;
}

.live-session-card:hover .live-card-overlay {
  background: rgba(0, 0, 0, 0.2);
}

.play-btn-circle {
  width: 56px;
  height: 56px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.5rem;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  border: 1px solid rgba(255, 255, 255, 0.6);
}

.live-session-card:hover .play-btn-circle {
  transform: scale(1.1);
  background: var(--primary);
  border-color: var(--primary);
  color: #000;
}

.live-status-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.25rem 0.75rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  z-index: 2;
}

.status-replay {
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.status-live {
  background: #ef4444;
  color: #fff;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.4);
  animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
  0% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7);
  }
  70% {
    box-shadow: 0 0 0 6px rgba(239, 68, 68, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
  }
}

.live-card-content {
  flex: 1;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.live-card-header {
  margin-bottom: 1rem;
}

.live-date {
  font-size: 0.875rem;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: block;
}

.live-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.4;
  margin-bottom: 0.5rem;
}

.live-excerpt {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.instructor-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.instructor-avatar-xs {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--surface);
}

.instructor-name {
  font-size: 0.875rem;
  color: #fff;
  font-weight: 600;
}

.watch-btn-sm {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.3s;
}

.live-session-card:hover .watch-btn-sm {
  color: var(--primary);
}

/* Training Module List Designs */

.training-group {
  margin-bottom: 2rem;
}

.training-group-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
  padding-left: 0.5rem;
}

.training-instructor-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--primary);
  box-shadow: 0 0 10px rgba(52, 211, 153, 0.2);
}

.training-instructor-name {
  font-size: 1.125rem;
  font-weight: 700;
  color: #fff;
}

.training-module-card {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 1rem;
  overflow: hidden;
}

.track-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.2s;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.track-item:last-child {
  border-bottom: none;
}

.track-item:hover {
  background: rgba(255, 255, 255, 0.02);
}

.track-info {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex: 1;
}

.track-number {
  font-family: monospace;
  font-size: 1rem;
  color: var(--primary);
  font-weight: 700;
  width: 1.5rem;
  text-align: right;
  opacity: 0.8;
}

.track-title {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
}

.track-action {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-width: 140px;
  justify-content: flex-end;
}

.track-btn {
  font-size: 0.875rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.3s;
}

.track-item:hover .track-btn {
  color: #fff;
}

.progress-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.progress-text {
  font-size: 0.75rem;
  color: var(--primary);
  font-weight: 600;
}

.progress-track {
  width: 80px;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 2px;
}

/* Subscription Badge */
.badge-success {
  background: rgba(52, 211, 153, 0.15);
  color: var(--primary);
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 700;
  border: 1px solid rgba(52, 211, 153, 0.2);
}

/* Settings Page Styles */
.settings-form-group {
  margin-bottom: 1.5rem;
}

.settings-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.settings-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  color: #fff;
  font-family: inherit;
  transition: all 0.3s;
}

.settings-input:focus {
  outline: none;
  border-color: var(--primary);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.1);
}

.settings-input[readonly] {
  opacity: 0.7;
  cursor: not-allowed;
  background: rgba(0, 0, 0, 0.2);
}

.content-card {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 1rem;
}

.dashboard-blog-card-footer {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  margin-left: -1.5rem;
  margin-right: -1.5rem;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
