/* Faculty Detail Page Styles */

/* Article Hierarchy Styles */
.article-content {
  margin-bottom: 2rem;
}

.article-child {
  border-left: 4px solid #007bff;
  transition: all 0.3s ease;
}

.article-child:hover {
  border-left-color: #0056b3;
  transform: translateX(5px);
}

.article-nested {
  border-left: 4px solid #6c757d;
  margin-left: 1rem;
  transition: all 0.3s ease;
}

.article-nested:hover {
  border-left-color: #545b62;
  transform: translateX(5px);
}

/* Card Enhancements */
.card-border {
  border: 1px solid #e9ecef;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  cursor: pointer;
}

.card-border:hover {
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
}

.card-img {
  position: relative;
  overflow: hidden;
  height: 200px;
}

.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.card-border:hover .card-img img {
  transform: scale(1.05);
}

.card-body {
  /*padding: 1.5rem;*/
}

.card-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.card-title a {
  color: #2c3e50;
  text-decoration: none;
  transition: color 0.3s ease;
}

.card-title a:hover {
  color: black;
}

.card-text {
  color: #666;
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 1rem;
}

/* Article Meta Information */
.article-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.85rem;
}

.article-meta .text-muted {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.article-meta i {
  font-size: 0.8rem;
}

/* Badge Styles */
.badge {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-weight: 500;
  transition: transform 0.2s ease;
}

.badge.bg-primary {
  background-color: #007bff !important;
}

.badge.bg-secondary {
  background-color: #6c757d !important;
}

.badge.bg-info {
  background-color: #17a2b8 !important;
}

.badge.bg-light {
  background-color: #f8f9fa !important;
  color: #495057 !important;
}

/* Hierarchy Visual Indicators */
.child-articles {
  position: relative;
  padding-top: 1rem;
}

.child-articles::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #007bff 0%, #6c757d 100%);
  border-radius: 1px;
}

/* Nested Article Indentation */
.article-nested {
  position: relative;
}

.article-nested::before {
  content: '';
  position: absolute;
  left: -1rem;
  top: 50%;
  width: 0.5rem;
  height: 2px;
  background-color: #6c757d;
  transform: translateY(-50%);
}

/* Responsive Design */
@media (max-width: 768px) {
  .card-img {
    height: 150px;
  }

  .card-body {
    padding: 1rem;
  }

  .card-title {
    font-size: 1rem;
  }

  .article-nested {
    margin-left: 0.5rem;
  }

  .article-nested::before {
    left: -0.5rem;
    width: 0.25rem;
  }
}

/* Empty State Styling */
.text-center.py-5 {
  background: #f8f9fa;
  border-radius: 12px;
  border: 2px dashed #dee2e6;
}

.text-center.py-5 i {
  color: #adb5bd;
}

/* Tab Content Enhancements */
.tab-pane {
  animation: fadeIn 0.3s ease-in-out;
}

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

/* Article Type Indicators */
.article-main {
  border-left: 4px solid #28a745;
}

.article-main .badge {
  background-color: #28a745 !important;
}

/* Enhanced Card Hover Effects */
.card-border:hover .card-img::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(0, 123, 255, 0.1) 0%, rgba(108, 117, 125, 0.1) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.card-border:hover .card-img::after {
  opacity: 1;
}

/* Article Content Preview */
.card-text {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Loading State */
.article-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  color: #6c757d;
}

.article-loading i {
  animation: spin 1s linear infinite;
  margin-right: 0.5rem;
}

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

/* Fade-in Animation for Articles */
.fade-in {
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Enhanced Interactive States */
.card-border:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Article Hierarchy Connectors */
.article-child::after {
  content: '';
  position: absolute;
  left: -4px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, #007bff 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.article-child:hover::after {
  opacity: 1;
}

/* Enhanced Badge Interactions */
.badge:hover {
  transform: scale(1.05);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Article Content Truncation */
.card-text {
  position: relative;
}



/* Responsive Enhancements */
@media (max-width: 576px) {
  .card-border {
    margin-bottom: 1rem;
  }

  .article-meta {
    flex-direction: column;
    align-items: flex-start;
  }

  .badge {
    font-size: 0.7rem;
    padding: 0.2rem 0.4rem;
  }
}
