/* Single Post Infinite Scroll Styles */

/* Progress Bar */
.spis-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(0, 0, 0, 0.05);
    z-index: 9999;
}

.spis-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    width: 0%;
    transition: width 0.3s ease;
    box-shadow: 0 2px 10px rgba(102, 126, 234, 0.3);
}

/* Infinite Scroll Container */
.spis-infinite-container {
    position: relative;
    min-height: 200px;
    margin: 60px 0;
    padding-top: 40px;
    border-top: 1px solid #eaeaea;
}

/* Loader */
.spis-loader {
    text-align: center;
    padding: 40px 20px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.spis-loader.active {
    opacity: 1;
    transform: translateY(0);
}

.spis-spinner {
    margin: 0 auto 20px;
    width: 50px;
    height: 50px;
    position: relative;
}

.spis-dot1, .spis-dot2, .spis-dot3 {
    width: 15px;
    height: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    position: absolute;
    animation: spis-bounce 1.4s infinite ease-in-out both;
}

.spis-dot1 {
    top: 0;
    left: 0;
    animation-delay: -0.32s;
}

.spis-dot2 {
    top: 0;
    right: 0;
    animation-delay: -0.16s;
}

.spis-dot3 {
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

@keyframes spis-bounce {
    0%, 80%, 100% { 
        transform: scale(0);
    } 40% { 
        transform: scale(1.0);
    }
}

.spis-loading-text {
    font-size: 16px;
    color: #667eea;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Next Post Container */
.spis-next-post-container {
    position: relative;
}

/* Post animation */
.spis-next-post {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.spis-next-post.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Post Meta */
.spis-post-meta {
    margin: 20px 0;
    padding: 15px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    font-size: 14px;
    color: #666;
}

.spis-post-date,
.spis-post-author {
    display: inline-block;
    margin-right: 20px;
}

.spis-post-categories,
.spis-post-tags {
    margin: 10px 0;
}

.spis-category-link,
.spis-tag-link {
    display: inline-block;
    margin-right: 10px;
    margin-bottom: 5px;
    padding: 4px 12px;
    background: #f0f2f5;
    color: #666;
    border-radius: 15px;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
}

.spis-category-link:hover,
.spis-tag-link:hover {
    background: #e0e4e8;
    color: #333;
}

.spis-tags-label {
    font-weight: 600;
    margin-right: 10px;
}

/* End Message */
.spis-end-message {
    text-align: center;
    padding: 60px 20px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s ease;
}

.spis-end-message.active {
    opacity: 1;
    transform: translateY(0);
}

.spis-end-icon {
    font-size: 48px;
    margin-bottom: 20px;
    animation: spis-pulse 2s infinite;
}

@keyframes spis-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.spis-end-message h3 {
    font-size: 24px;
    color: #333;
    margin-bottom: 10px;
    font-weight: 700;
}

.spis-end-message p {
    color: #666;
    font-size: 16px;
    margin-bottom: 30px;
}

.spis-browse-all {
    display: inline-block;
    padding: 12px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.spis-browse-all:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    color: white;
}

/* Filter Controls */
.spis-filter-controls {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 10000;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

.spis-filter-header {
    margin-bottom: 10px;
    text-align: right;
}

.spis-filter-toggle {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 25px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.spis-filter-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.5);
}

.spis-filter-icon {
    font-size: 18px;
}

.spis-filter-content {
    background: white;
    border-radius: 15px;
    padding: 25px;
    width: 320px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
    display: none;
}

.spis-filter-content.active {
    opacity: 1;
    transform: translateY(0);
    display: block;
}

.spis-filter-group {
    margin-bottom: 25px;
}

.spis-filter-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
    font-size: 15px;
}

.spis-label-icon {
    font-size: 18px;
}

.spis-filter-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.spis-radio-option {
    display: flex;
    align-items: center;
    cursor: pointer;
    position: relative;
    padding-left: 35px;
    user-select: none;
}

.spis-radio-option input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.spis-radio-checkmark {
    position: absolute;
    left: 0;
    top: 0;
    height: 22px;
    width: 22px;
    background-color: #f0f2f5;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.spis-radio-option:hover .spis-radio-checkmark {
    background-color: #e0e4e8;
}

.spis-radio-option input:checked ~ .spis-radio-checkmark {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.spis-radio-checkmark:after {
    content: "";
    position: absolute;
    display: none;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: white;
}

.spis-radio-option input:checked ~ .spis-radio-checkmark:after {
    display: block;
}

.spis-option-label {
    color: #555;
    font-size: 14px;
    transition: color 0.3s ease;
}

.spis-radio-option input:checked ~ .spis-option-label {
    color: #667eea;
    font-weight: 600;
}

.spis-select-input {
    width: 100%;
    padding: 10px 15px;
    border: 2px solid #eaeaea;
    border-radius: 8px;
    font-size: 14px;
    color: #333;
    background: white;
    transition: all 0.3s ease;
}

.spis-select-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.spis-speed-control {
    display: flex;
    gap: 8px;
}

.spis-speed-btn {
    flex: 1;
    padding: 8px 10px;
    background: #f0f2f5;
    border: none;
    border-radius: 6px;
    color: #666;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.spis-speed-btn:hover {
    background: #e0e4e8;
}

.spis-speed-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
}

.spis-filter-actions {
    display: flex;
    gap: 10px;
    margin-top: 30px;
}

.spis-apply-filters,
.spis-reset-filters {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.spis-apply-filters {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.spis-apply-filters:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.spis-reset-filters {
    background: #f0f2f5;
    color: #666;
}

.spis-reset-filters:hover {
    background: #e0e4e8;
}

.spis-current-settings {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #eaeaea;
}

.spis-setting-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 14px;
}

.spis-setting-label {
    color: #666;
}

.spis-setting-value {
    color: #667eea;
    font-weight: 600;
}

/* Post Navigation Info */
.spis-post-navigation {
    position: fixed;
    bottom: 30px;
    left: 30px;
    background: white;
    padding: 15px 20px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    font-size: 14px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 9999;
    display: none;
}

.spis-post-navigation.active {
    opacity: 1;
    transform: translateY(0);
    display: block;
}

.spis-post-nav-label {
    color: #666;
    margin-bottom: 5px;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.spis-post-nav-title {
    color: #333;
    font-weight: 600;
    max-width: 300px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Notification */
.spis-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: white;
    padding: 15px 20px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    z-index: 10001;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    max-width: 350px;
}

.spis-notification.active {
    transform: translateX(0);
}

.spis-notification-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.spis-notification-icon {
    font-size: 20px;
}

.spis-notification-text {
    font-size: 14px;
    color: #333;
}

/* Responsive Design */
@media (max-width: 768px) {
    .spis-filter-controls {
        bottom: 20px;
        right: 20px;
        left: 20px;
    }
    
    .spis-filter-content {
        width: auto;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .spis-post-navigation {
        left: 20px;
        right: 20px;
        max-width: calc(100% - 40px);
    }
    
    .spis-filter-toggle {
        width: 100%;
        justify-content: center;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .spis-filter-content,
    .spis-post-navigation,
    .spis-notification {
        background: #2d2d2d;
        color: #f0f0f0;
    }
    
    .spis-filter-label,
    .spis-post-nav-title,
    .spis-notification-text {
        color: #f0f0f0;
    }
    
    .spis-setting-label,
    .spis-option-label {
        color: #aaa;
    }
    
    .spis-select-input {
        background: #3d3d3d;
        border-color: #444;
        color: #f0f0f0;
    }
    
    .spis-speed-btn {
        background: #3d3d3d;
        color: #aaa;
    }
    
    .spis-speed-btn:hover {
        background: #4d4d4d;
    }
    
    .spis-reset-filters {
        background: #3d3d3d;
        color: #aaa;
    }
    
    .spis-reset-filters:hover {
        background: #4d4d4d;
    }
}