/* ==========================================================
   EXTREME LEVEL ASTROLOGY E-BOOK ANIMATIONS & THEME CSS
   ========================================================== */

/* 1. Magical Rotating Gradient Background for Breadcrumb */
.ebook-breadcrumb {
    background: linear-gradient(135deg, #2b1055 0%, #7597de 100%);
    position: relative;
    overflow: hidden;
}

.ebook-breadcrumb::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 215, 0, 0.2) 0%, transparent 70%);
    animation: cosmicSpin 12s linear infinite;
}

@keyframes cosmicSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.animated-heading {
    color: #fff;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.6), 0 0 40px rgba(103, 58, 183, 0.8);
    animation: headingGlow 3s ease-in-out infinite alternate;
}

@keyframes headingGlow {
    0% { transform: scale(1); text-shadow: 0 0 10px rgba(255, 215, 0, 0.4); }
    100% { transform: scale(1.03); text-shadow: 0 0 25px rgba(255, 215, 0, 0.9), 0 0 50px rgba(103, 58, 183, 0.8); }
}

/* 2. Extreme 3D Floating & Glowing Cards */
.ebook-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(103, 58, 183, 0.12);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    margin-bottom: 35px;
    overflow: hidden;
    border: 2px solid rgba(103, 58, 183, 0.15);
    position: relative;
    animation: cardFloatIdle 4s ease-in-out infinite alternate;
}

.ebook-card:nth-child(even) {
    animation-delay: 2s;
}

@keyframes cardFloatIdle {
    0% { transform: translateY(0); }
    100% { transform: translateY(-6px); }
}

.ebook-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 45px rgba(103, 58, 183, 0.35), 0 0 20px rgba(255, 193, 7, 0.4);
    border-color: #ffc107;
}

/* 3. Extreme Pulsing Platform Badge */
.badge-platform-tag {
    position: absolute;
    top: 12px;
    left: 12px;
    background: linear-gradient(45deg, #673ab7, #e91e63);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 30px;
    z-index: 2;
    box-shadow: 0 4px 15px rgba(233, 30, 99, 0.5);
    animation: badgePulse 2s infinite;
}

@keyframes badgePulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(233, 30, 99, 0.7); }
    70% { transform: scale(1.05); box-shadow: 0 0 0 10px rgba(233, 30, 99, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(233, 30, 99, 0); }
}

/* 4. Glowing Video Preview Button with Ripple */
.btn-preview-video {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    color: #fff;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    z-index: 3;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.btn-preview-video:hover {
    background: #ffc107;
    color: #111;
    transform: scale(1.2) rotate(15deg);
    box-shadow: 0 0 20px #ffc107;
}

/* 5. Dynamic Image Zoom & Shine Loop */
.ebook-img-box {
    height: 240px;
    overflow: hidden;
    position: relative;
    background: radial-gradient(circle, #fcfcfc 0%, #ececec 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.ebook-img-box img {
    max-height: 85%;
    max-width: 85%;
    object-fit: contain;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.ebook-card:hover .ebook-img-box img {
    transform: scale(1.12) rotate(2deg);
}

/* Shine overlay effect on image hover */
.ebook-img-box::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%);
    transform: rotate(30deg) translate(-100%, -100%);
    transition: transform 0.7s ease-in-out;
}

.ebook-card:hover .ebook-img-box::after {
    transform: rotate(30deg) translate(100%, 100%);
}

/* Book Body Details */
.ebook-body {
    padding: 24px;
}

.ebook-title {
    font-size: 16px;
    font-weight: 700;
    color: #222;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 44px;
    text-decoration: none;
    transition: color 0.3s;
}

.ebook-title:hover {
    color: #673ab7;
    text-shadow: 0 0 5px rgba(103, 58, 183, 0.3);
}

.price-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.price-new {
    font-size: 20px;
    font-weight: 900;
    color: #e91e63;
    text-shadow: 0 2px 5px rgba(233, 30, 99, 0.2);
}

.price-old {
    font-size: 13px;
    text-decoration: line-through;
    color: #999;
}

.stats-row {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #555;
    margin-bottom: 15px;
    border-top: 1px dashed #e0e0e0;
    border-bottom: 1px dashed #e0e0e0;
    padding: 10px 0;
}

/* 6. Original Sidebar & Recent Items Design (Untouched layout, clean styling) */
.sidebar-category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-category-list li {
    padding: 8px 0;
    border-bottom: 1px dashed #eee;
}

.sidebar-category-list li a {
    color: #555;
    text-decoration: none;
    transition: 0.3s;
}

.sidebar-category-list li.active a,
.sidebar-category-list li a:hover {
    color: #673ab7;
    font-weight: bold;
    padding-left: 5px;
}

.recent-item {
    display: flex;
    gap: 10px;
    margin-bottom: 12px;
    align-items: center;
    border-bottom: 1px solid #f1f1f1;
    padding-bottom: 8px;
    transition: 0.3s;
}

.recent-item:hover {
    transform: translateX(5px);
}

.recent-item img {
    width: 45px;
    height: 45px;
    object-fit: cover;
    border-radius: 6px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
}

.recent-item-title {
    font-size: 13px;
    color: #333;
    font-weight: 600;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-decoration: none;
}

.recent-item-title:hover {
    color: #673ab7;
}

/* 7. Glow & Shine Utility classes */
.border-left-gold {
    border-left: 5px solid #ffc107 !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.text-purple {
    color: #673ab7 !important;
}

.badge-purple {
    background: linear-gradient(45deg, #673ab7, #9c27b0);
    color: #fff;
    font-size: 13px;
    padding: 6px 14px;
    border-radius: 20px;
    box-shadow: 0 3px 10px rgba(103, 58, 183, 0.4);
}

.btn-glow {
    background: linear-gradient(135deg, #673ab7, #e91e63);
    color: #fff;
    border: none;
    box-shadow: 0 6px 20px rgba(103, 58, 183, 0.4);
    transition: 0.4s;
    border-radius: 30px;
    padding: 8px 20px;
}

.btn-glow:hover {
    background: linear-gradient(135deg, #5e33a8, #d81b60);
    color: #fff;
    box-shadow: 0 8px 25px rgba(233, 30, 99, 0.6);
    transform: translateY(-3px);
}

.pulse-anim {
    animation: iconPulse 1.5s infinite alternate;
}

@keyframes iconPulse {
    0% { transform: scale(1); filter: drop-shadow(0 0 2px rgba(255,193,7,0.5)); }
    100% { transform: scale(1.2); filter: drop-shadow(0 0 12px rgba(255,193,7,0.9)); color: #ffc107; }
}

/* 8. Extreme Glowing Pagination */
.modern-pagination li a, .modern-pagination li span {
    border-radius: 50px !important;
    margin: 0 4px;
    border: none;
    color: #673ab7;
    font-weight: 700;
    padding: 10px 18px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(103, 58, 183, 0.08);
    transition: all 0.3s ease;
}

.modern-pagination li a:hover {
    background: #673ab7;
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(103, 58, 183, 0.3);
}

.modern-pagination li.as_active a, .modern-pagination li.active a {
    background: linear-gradient(135deg, #673ab7, #e91e63) !important;
    color: #fff !important;
    box-shadow: 0 6px 20px rgba(233, 30, 99, 0.4);
    transform: scale(1.05);
}