/* ============================================
   Tag Page Styles
   ============================================ */

/* Tag Hero Section */
.tag-hero-section {
  background: linear-gradient(135deg, #8b0a8f 0%, #06003c 100%);
  padding: 80px 1rem;
  position: relative;
  overflow: hidden;
}

.tag-hero-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.tag-hero-section>* {
  position: relative;
  z-index: 2;
}

.tag-hero-content {
  text-align: left;
  color: #ffffff;
  margin: 0 auto;
}

.tag-hero-main {
  display: flex;
  align-items: center;
  gap: 30px;
}

.tag-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 12px 24px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  margin-bottom: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.tag-badge i {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1rem;
}

.tag-title {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 0;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
  color: #ffffff;
}

.tag-description {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.6;
  margin-bottom: 30px;
  max-width: 800px;
  margin-right: auto;
}

.tag-stats {
  display: flex;
  justify-content: flex-end;
  gap: 30px;
  margin-left: auto;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  color: #ffffff;
}

.stat-label {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

/* Tag Posts Section */
.tag-posts-section {
  background: #f8f8f8;
  display: flex;
}

.tag-posts-content {
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  margin-bottom: 40px;
  display: flex;
  flex-wrap: wrap;
  flex: 1 1 70%;
}

.tag-posts-content .cards-container {
  flex: 1 1 33%;
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* Tag Posts Grid */
.tag-posts-grid {
  display: grid;
  gap: 40px;
}

/* Tag Post Card */
.tag-post-card {
  background: #ffffff;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(139, 10, 143, 0.1);
}

.tag-post-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(139, 10, 143, 0.2);
  border-color: rgba(139, 10, 143, 0.3);
}

.tag-post-card .post-image {
  position: relative;
  overflow: hidden;
}

.tag-post-card .post-image img {
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.tag-post-card:hover .post-image {
  transform: scale(1.1);
}

/* Tag Pagination */
.tag-pagination {
  margin-top: 60px;
  margin-bottom: 40px;
  text-align: center;
  position: relative;
}

.tag-pagination::before {
  content: "";
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, #8b0a8f, #a014b5);
}

.tag-pagination .page-numbers {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
  background: #ffffff;
  padding: 20px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(139, 10, 143, 0.1);
}

.tag-pagination .page-numbers li {
  display: flex;
}

.tag-pagination .page-numbers li a,
.tag-pagination .page-numbers li span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  height: 48px;
  padding: 0 16px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.tag-pagination .page-numbers li a {
  background: rgba(139, 10, 143, 0.05);
  color: #8b0a8f;
  border-color: rgba(139, 10, 143, 0.2);
}

.tag-pagination .page-numbers li a:hover {
  background: linear-gradient(135deg, #8b0a8f 0%, #a014b5 100%);
  color: #ffffff;
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 6px 20px rgba(139, 10, 143, 0.4);
  border-color: rgba(139, 10, 143, 0.3);
}

.tag-pagination .page-numbers li a:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(139, 10, 143, 0.2);
}

.tag-pagination .page-numbers li .current {
  background: linear-gradient(135deg, #8b0a8f 0%, #a014b5 100%);
  color: #ffffff;
  border-color: #8b0a8f;
  transform: scale(1.05);
}

.tag-pagination .page-numbers li .current::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg,
      rgba(255, 255, 255, 0.1) 0%,
      rgba(255, 255, 255, 0.05) 100%);
}

.tag-pagination .page-numbers li .prev,
.tag-pagination .page-numbers li .next {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  color: #8b0a8f;
  border: 2px solid rgba(139, 10, 143, 0.2);
  font-weight: 600;
  min-width: 56px;
  position: relative;
}

.tag-pagination .page-numbers li .prev::before,
.tag-pagination .page-numbers li .next::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg,
      rgba(139, 10, 143, 0.05) 0%,
      rgba(139, 10, 143, 0.02) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.tag-pagination .page-numbers li .prev:hover::before,
.tag-pagination .page-numbers li .next:hover::before {
  opacity: 1;
}

.tag-pagination .page-numbers li .prev:hover,
.tag-pagination .page-numbers li .next:hover {
  background: linear-gradient(135deg, #8b0a8f 0%, #a014b5 100%);
  color: #ffffff;
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 6px 20px rgba(139, 10, 143, 0.4);
  border-color: rgba(139, 10, 143, 0.3);
}

.tag-pagination .page-numbers li .dots {
  background: transparent !important;
  box-shadow: none !important;
  border: none !important;
  color: #6c757d !important;
  transform: none !important;
  cursor: default !important;
  padding: 0 8px;
}

.tag-pagination .page-numbers li .dots:hover {
  transform: none !important;
  background: transparent !important;
  color: #6c757d !important;
}

/* No Tag Posts */
.no-tag-posts {
  text-align: center;
  padding: 60px 40px;
  background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
  border: 2px solid rgba(139, 10, 143, 0.1);
}

.no-posts-icon {
  font-size: 4rem;
  color: #8b0a8f;
  margin-bottom: 30px;
}

.no-posts-title {
  font-size: 2rem;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 20px;
}

.no-posts-message {
  font-size: 1.1rem;
  color: #6c757d;
  margin-bottom: 40px;
  line-height: 1.6;
}

.no-posts-actions {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

/* Tag Sidebar */
.tag-sidebar {
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  padding: 30px;
  flex: 1 1 30%;
}

.sidebar-widget {
  margin-bottom: 40px;
}

.sidebar-widget:last-child {
  margin-bottom: 0;
}

.sidebar-widget .widget-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.sidebar-widget .widget-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: linear-gradient(90deg, #8b0a8f, #a014b5);
}

/* Tag Info Widget */
.tag-info-content {
  background: linear-gradient(135deg,
      rgba(139, 10, 143, 0.05) 0%,
      rgba(139, 10, 143, 0.02) 100%);
  padding: 20px;
  border: 1px solid rgba(139, 10, 143, 0.1);
}

.current-tag {
  display: flex;
  align-items: center;
  gap: 15px;
}

.tag-icon {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, #8b0a8f 0%, #a014b5 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 1.2rem;
}

.tag-details h4 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 5px;
}

.tag-details p {
  color: #6c757d;
  font-size: 0.9rem;
}

.tag-description-full {
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px solid rgba(139, 10, 143, 0.1);
}

.tag-description-full p {
  color: #6c757d;
  line-height: 1.6;
  font-size: 0.95rem;
}

/* Related Tags Widget */
.related-tags-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.related-tag-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 15px;
  background: #f8f9fa;
  text-decoration: none;
  transition: all 0.3s ease;
  color: #1a1a1a;
  border: 1px solid rgba(139, 10, 143, 0.1);
}

.related-tag-link:hover {
  background: linear-gradient(135deg, #8b0a8f 0%, #a014b5 100%);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(139, 10, 143, 0.3);
}

.tag-name {
  font-weight: 600;
  font-size: 0.95rem;
}

.tag-count {
  background: rgba(139, 10, 143, 0.1);
  color: #8b0a8f;
  padding: 2px 8px;
  font-size: 0.8rem;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 1px solid rgba(139, 10, 143, 0.2);
  position: relative;
}

.related-tag-link:hover .tag-count {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.3);
}

/* Popular Tags Widget */
.popular-tags-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.popular-tag-link {
  display: inline-block;
  padding: 6px 12px;
  background: rgba(139, 10, 143, 0.1);
  color: #8b0a8f;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 1px solid rgba(139, 10, 143, 0.2);
  position: relative;
}

.popular-tag-link:hover {
  background: #8b0a8f;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(139, 10, 143, 0.3);
}

/* Post Tags */
.post-tags {
  margin: 40px 0;
  padding: 30px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
}

.post-tags h4 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 20px;
}

.tags-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.tag-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  color: #8b0a8f;
  padding: 8px 16px;
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
  border: 1px solid rgba(139, 10, 143, 0.2);
}

.tag-item:hover {
  background: #8b0a8f;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(139, 10, 143, 0.3);
}

/* Tags Widget */
.tags-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag-link {
  display: inline-block;
  padding: 6px 12px;
  background: rgba(139, 10, 143, 0.1);
  color: #8b0a8f;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 1px solid rgba(139, 10, 143, 0.2);
  position: relative;
}

.tag-link:hover {
  background: #8b0a8f;
  color: #ffffff;
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(139, 10, 143, 0.3);
}
