/* ============================================
   Featured Ads Carousel & Cards Styles
   ============================================ */

/* -------------------------------
   Carousel Container
-------------------------------- */
.featured-ads-section {
    background: linear-gradient(to bottom, #f9fafb, #ffffff);
    padding: 3rem 0;
}

.featured-swiper-container {
    position: relative;
    padding: 10px 0 50px 0;
    overflow: hidden;

}

.featured-swiper-container .swiper-slide {
    height: auto;
}

/* -------------------------------
   Featured Card Styles
-------------------------------- */
.featured-card {
    background: white;
    border-radius: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid #f3f4f6;
    overflow: hidden;

}

.featured-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border-color: #e0e7ff;
}

/* -------------------------------
   Image Container - FIXED
-------------------------------- */
.featured-card-image {
    position: relative;
    width: 100%;
    height: 180px;
    background-color: #f3f4f6;
    overflow: hidden;
    border-bottom: 1px solid #e5e7eb;
        
    
}

.featured-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.featured-card:hover .featured-card-image img {
    transform: scale(1.05);
}

/* Fallback when no image */
.featured-card-image .image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #eef2ff, #f5f3ff);
    display: flex;
    align-items: center;
    justify-content: center;

    
}

.featured-card-image .image-placeholder i {
    font-size: 3rem;
    color: #c7d2fe;
}

/* -------------------------------
   Badges
-------------------------------- */
.featured-badge {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.25rem 0.6rem;
    border-radius: 9999px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.category-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: linear-gradient(135deg, #4f46e5, #6366f1);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.25rem 0.6rem;
    border-radius: 9999px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.views-badge {
    position: absolute;
    bottom: 0.75rem;
    right: 0.75rem;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    color: white;
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* -------------------------------
   Card Content
-------------------------------- */
.featured-card-content {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.featured-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.25rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.featured-card-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s;
}

.featured-card-title a:hover {
    color: #4f46e5;
}

.featured-card-subtitle {
    font-size: 0.7rem;
    color: #4f46e5;
    margin-bottom: 0.5rem;
}

/* Subject Tags */
.subject-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    margin-bottom: 0.5rem;
}

.subject-tag {
    background-color: #eef2ff;
    color: #4f46e5;
    font-size: 0.65rem;
    padding: 0.2rem 0.5rem;
    border-radius: 9999px;
}

/* Info Rows */
.info-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.75rem;
    color: #6b7280;
}

.info-row i {
    width: 1rem;
    color: #818cf8;
}

.info-row .text-truncate {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Grade levels specific */
.grade-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.7rem;
    color: #4b5563;
}

.grade-row i {
    width: 1rem;
    color: #818cf8;
}

/* -------------------------------
   Card Footer
-------------------------------- */
.featured-card-footer {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid #f3f4f6;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.featured-date {
    font-size: 0.65rem;
    color: #9ca3af;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.featured-button {
    background-color: #eef2ff;
    color: #4f46e5;
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.4rem 0.8rem;
    border-radius: 0.5rem;
    transition: all 0.2s;
    text-decoration: none;
}

.featured-button:hover {
    background-color: #4f46e5;
    color: white;
}

/* -------------------------------
   Responsive Adjustments
-------------------------------- */
@media (max-width: 768px) {
    .featured-card-image {
        height: 160px;
    }
    
    .featured-card-title {
        font-size: 1rem;
    }
}

/* Boost Badge Animations */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

.animate-pulse {
    animation: pulse 1.5s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Boost Border Effects */
.ring-2 {
    box-shadow: 0 0 0 2px currentColor;
}

.ring-yellow-400 {
    --tw-ring-color: #fbbf24;
    box-shadow: 0 0 0 2px #fbbf24;
}

.ring-purple-400 {
    --tw-ring-color: #a855f7;
    box-shadow: 0 0 0 2px #a855f7;
}

.ring-red-400 {
    --tw-ring-color: #f87171;
    box-shadow: 0 0 0 2px #f87171;
}

/* Urgent Badge Glow Effect */
.urgent-glow {
    animation: glow 1s ease-in-out infinite alternate;
}

@keyframes glow {
    from {
        box-shadow: 0 0 5px #ef4444;
    }
    to {
        box-shadow: 0 0 20px #ef4444;
    }
}