
/* Pagination Container */
#recent-posts-paginator,
#other-paginator,
#paginator,
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 50px !important;
    gap: 20px;
    height: 120px; /* Increased height for larger buttons */
    padding-bottom: 20px;
    
    position: relative; /* For Canvas positioning */
    background: transparent !important; /* Ensure no box visible */
}

/* String Effect Canvas */
.pagination-string-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1; /* Behind buttons (buttons need z-index > 1) */
    pointer-events: none;
}

/* Base Button Style */
.page-number,
.extend {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 65px; /* Increased from 45px */
    height: 65px; /* Increased from 45px */
    border-radius: 50%;
    background: #fff;
    color: #555;
    text-decoration: none;
    font-size: 18px; /* Larger font */
    font-weight: 600;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); /* Bouncy spring effect */
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    border: none;
    outline: none;
    position: relative;
    margin: 0 !important; /* Override default margin */
    z-index: 5; /* Ensure above canvas */
}

/* Remove underline */
#recent-posts-paginator a,
#other-paginator a {
    text-decoration: none;
    border-bottom: none;
}

/* Hover state for non-active items */
.page-number:not(.current):hover,
.extend:hover {
    background: #f8f9fa;
    color: #333;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.1);
}

/* Fan-out Effect Classes (Applied by JS) */

/* visual center (hovered or current) */
.pagination-dist-0 {
    transform: scale(1.3);
    z-index: 10;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* The Active Page (State) - Color only */
.page-number.current {
    background: linear-gradient(135deg, #2c3e50, #4ca1af);
    color: white;
    /* Remove static sizing/scale from here, let dist classes handle it */
    pointer-events: none; /* Keep it unclickable */
    border: none;
}

/* If current page is NOT the visual center (e.g. hovering elsewhere), 
   it should still keep its color but abide by the dist scale */

/* Immediate Neighbors (Distance 1) */
.pagination-dist-1 {
    transform: scale(1.1);
    background: #fdfdfd;
    z-index: 5;
    opacity: 0.95;
}

/* Second Neighbors (Distance 2) */
.pagination-dist-2 {
    transform: scale(0.95);
    opacity: 0.8;
    z-index: 4;
}

/* Far Neighbors */
.pagination-dist-3 {
    transform: scale(0.8);
    opacity: 0.6;
    z-index: 3;
}

/* Next/Prev buttons special handling */
.extend.prev,
.extend.next {
    width: auto;
    padding: 0 20px;
    border-radius: 25px;
    font-size: 14px;
    letter-spacing: 1px;
    background: rgba(255,255,255,0.8);
    /* Prevent them from participating in the scale dance if we want,
       OR let them participate. Usually they are separate. 
       For now, let's keep them somewhat independent or just basic hover. */
    transform: scale(1) !important; /* Force reset if JS tries to scale them */
}

.extend.prev:hover,
.extend.next:hover {
    background: #fff;
    transform: scale(1.05) !important;
}
