/* ====================================================== */
/* BİLEŞEN STİLLERİ (components.css) - ESKİ MODERN TASARIMA DÖNÜŞ */
/* ====================================================== */

/* Import CSS Variables */
@import url("variables.css");

/* === COMPONENT-SPECIFIC VARIABLES === */
:root {
  /* Kategori Renkleri */
  --category-color: #8b5cf6; /* Varsayılan kategori rengi */
}

/* === ESKİ MODERN İÇERİK KARTI (resources.php & index.php) === */
.content-card-wrapper {
  height: 100% !important;
}
.content-card-wrapper .content-card-link {
  text-decoration: none !important;
  color: inherit !important;
  display: block !important;
  height: 100% !important;
}
.content-card-wrapper .content-card-link .content-card {
  background: #ffffff !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  height: 100% !important;
  display: flex !important;
  flex-direction: column !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05) !important;
}

/* Premium content cards - Gradient border */
.content-card-wrapper .content-card-link .content-card.premium {
  border: 2px solid transparent !important;
  background: linear-gradient(white, white) padding-box,
              linear-gradient(135deg, #f59e0b, #ef4444) border-box !important;
}

/* Free content cards - Green accent */
.content-card-wrapper .content-card-link .content-card.free {
  border-color: #10B981 !important;
}

.content-card-wrapper .content-card-link .content-card:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1) !important;
  border-color: #8B5CF6 !important;
}

/* Premium hover state */
.content-card-wrapper .content-card-link .content-card.premium:hover {
  box-shadow: 0 8px 25px rgba(245, 158, 11, 0.2) !important;
  border-color: transparent !important;
}

/* Free hover state */
.content-card-wrapper .content-card-link .content-card.free:hover {
  border-color: #059669 !important;
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.15) !important;
}

.content-card .content-card-image-container {
  padding-top: 60% !important; /* Aspect Ratio */
  position: relative !important;
  background-color: #f4f7fa !important;
}
.content-card .content-card-image-container img,
.content-card .placeholder-image {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}
.content-card .placeholder-image {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 2.5rem !important;
  color: #cbd5e1 !important;
}

.content-card .content-card-badges {
  position: absolute !important;
  top: 1rem !important;
  left: 1rem !important;
  z-index: 1 !important;
}
.content-card .badge-premium {
  background: linear-gradient(135deg, #f59e0b, #ef4444) !important;
  color: #fff !important;
  padding: 0.4rem 0.8rem !important;
  border-radius: 50px !important;
  font-size: 0.75rem !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.3rem !important;
}

.content-card-body {
  padding: 1.5rem;
  flex-grow: 2;
}
.content-card-category {
  font-size: 0.8rem;
  font-weight: 600;
  color: #8b5cf6;
  margin-bottom: 0.5rem;
  display: block;
}
.content-card-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #1e293b;
  margin: 0;
}
.content-card-description {
  font-size: 0.95rem;
  color: #64748b;
  line-height: 1.6;
  margin-top: 0.5rem;
  /* Multi-line clamp for card descriptions (collapsed by default) */
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-line-clamp: 2; /* mobile: 2 lines */
}
@media (min-width: 992px) {
  .content-card-description { -webkit-line-clamp: 3; } /* desktop: 3 lines */
}
/* Expanded state shows full text */
.content-card.expanded .content-card-description {
  -webkit-line-clamp: unset;
  overflow: visible;
  text-overflow: clip;
}
/* Read more / less button */
.read-more-link {
  font-size: 0.9rem;
  color: #0d6efd;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  margin-top: 0.5rem;
  display: none; /* Hidden by default, shown only when needed */
}

.content-card-footer {
  padding: 0 1.5rem 1.5rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid #eef2f7;
  margin-top: auto;
}
.footer-stats {
  display: flex;
  gap: 1rem;
  font-size: 0.85rem;
  color: #64748b;
}
.footer-arrow {
  background: #f1f5f9;
  color: #9ca3af;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}
.content-card:hover .footer-arrow {
  background: #8b5cf6;
  color: #fff;
  transform: translateX(5px);
}

/* === ESKİ MODERN KATEGORİ KARTI (categories.php & index.php) === */
.category-card-link {
  text-decoration: none !important;
}
.category-card-link .category-card {
  background: #fff !important;
  padding: 2rem !important;
  border-radius: 16px !important;
  text-align: center !important;
  border: 1px solid #eef2f7 !important;
  position: relative !important;
  overflow: hidden !important;
  transition: all 0.3s ease-in-out !important;
}
.category-card-link .category-card:hover {
  transform: translateY(-10px) !important;
  box-shadow: 0 20px 40px -15px rgba(0, 12, 51, 0.15) !important;
  border-color: transparent !important;
}

.category-card::after {
  content: "" !important;
  position: absolute !important;
  bottom: 0 !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  width: 0 !important;
  height: 4px !important;
  background: var(--category-color) !important;
  transition: width 0.4s ease !important;
}
.category-card:hover::after {
  width: 100% !important;
}

.category-card .category-card-icon {
  font-size: 2.5rem !important;
  color: var(--category-color) !important;
  margin-bottom: 1rem !important;
}
.category-card .category-card-title {
  font-size: 1.25rem !important;
  font-weight: 700 !important;
  color: #1e293b !important;
  margin: 0 0 0.25rem 0 !important;
}
.category-card .category-card-count {
  font-size: 0.9rem !important;
  color: #64748b !important;
  margin: 0 !important;
}

/* === MODERN KART TASARIMI (Eski Uyumluluk) === */
.modern-card {
  background: #fff;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: block;
  height: 100%;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

/* Premium modern cards */
.modern-card.premium {
  border: 2px solid transparent;
  background: linear-gradient(white, white) padding-box,
              linear-gradient(135deg, #f59e0b, #ef4444) border-box;
}

/* Free modern cards */
.modern-card.free {
  border-color: #10B981;
}

.modern-card:hover {
  text-decoration: none;
  color: inherit;
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  border-color: #8B5CF6;
}

/* Premium hover state */
.modern-card.premium:hover {
  box-shadow: 0 8px 25px rgba(245, 158, 11, 0.2);
  border-color: transparent;
}

/* Free hover state */
.modern-card.free:hover {
  border-color: #059669;
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.15);
}

/* === MODERN BADGES === */
.modern-badges {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.modern-badge {
  padding: 0.4rem 0.8rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.modern-badge.premium {
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff;
}

.modern-badge.featured {
  background: linear-gradient(135deg, #8b5cf6, #3b82f6);
  color: #fff;
}

/* === FAVORITE BUTTON === */
.favorite-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 2;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.favorite-btn:hover {
  background: rgba(255, 255, 255, 1);
  color: #ef4444;
  transform: scale(1.1);
}

.favorite-btn.favorited {
  background: #ef4444;
  color: #fff;
}

.favorite-btn.favorited:hover {
  background: #dc2626;
}

/* === CARD IMAGE === */
.card-image-wrapper {
  position: relative;
  height: 200px; /* Sabit yükseklik */
  overflow: hidden;
  background: #f8f9fa;
  border-radius: 16px 16px 0 0;
}

.card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.4s ease;
  border-radius: 16px 16px 0 0;
  display: block;
}

.modern-card:hover .card-image {
  transform: scale(1.02);
}

.card-body {
  padding: 1.5rem;
}

.card-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.card-description {
  font-size: 0.95rem;
  color: #64748b;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  padding-top: 1rem;
  border-top: 1px solid #eef2f7;
}

.card-category {
  color: #8b5cf6;
  font-weight: 600;
}

.card-date {
  color: #9ca3af;
}

/* components.css sonuna eklenecek rozet stilleri */
.content-card-badges {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  z-index: 2;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.28rem;
  max-width: calc(100% - 2.5rem);
}
.content-card-badges span {
  color: #fff;
  padding: 0.25rem 0.5rem;
  border-radius: 50px;
  font-size: clamp(0.6875rem, 0.62rem + 0.35vw, 0.8125rem);
  min-height: 1.375rem;
  line-height: 1.25;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  line-height: 1.1;
  white-space: nowrap;
}
.badge-premium {
  background: linear-gradient(135deg, #f59e0b, #ef4444);
}
.badge-free {
  background: linear-gradient(135deg, #10b981, #059669);
}
.badge-featured {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}
