.catalog-main {
    padding: 3rem 0 5rem;
    position: relative;
    min-height: 70vh;
}

.cosmic-catalog-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 10% 20%, rgba(138, 43, 226, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 90% 30%, rgba(77, 184, 255, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 50% 80%, rgba(255, 102, 178, 0.1) 0%, transparent 40%);
    z-index: -1;
}

.catalog-header {
    text-align: center;
    margin-bottom: 3rem;
}

.cosmic-title {
    font-size: 3rem;
    margin-bottom: 1rem;
    position: relative;
}

.title-glow {
    background: linear-gradient(45deg, var(--star-blue), var(--accent-pink));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(138, 43, 226, 0.3);
    animation: title-glow 3s ease-in-out infinite;
}

@keyframes title-glow {
    0%, 100% {
        text-shadow: 0 0 30px rgba(138, 43, 226, 0.3);
    }
    50% {
        text-shadow: 0 0 50px rgba(138, 43, 226, 0.5),
                     0 0 70px rgba(77, 184, 255, 0.3);
    }
}

.catalog-subtitle {
    font-size: 1.2rem;
    color: var(--text-gray);
    margin-bottom: 2rem;
}

.catalog-stats {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.stat-card {
    background: rgba(26, 26, 58, 0.7);
    border: 1px solid rgba(138, 43, 226, 0.2);
    border-radius: 15px;
    padding: 1.5rem 2rem;
    min-width: 150px;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.stat-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-purple);
    box-shadow: 0 10px 30px rgba(138, 43, 226, 0.2);
}

.stat-icon {
    display: block;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    animation: star-twinkle 3s ease-in-out infinite;
}

.stat-value {
    display: block;
    font-size: 2rem;
    font-weight: bold;
    color: var(--star-blue);
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-gray);
}

.catalog-controls {
    background: rgba(10, 10, 26, 0.8);
    border-radius: 20px;
    padding: 2rem;
    margin-bottom: 3rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
}

.search-box {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    position: relative;
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    color: var(--text-gray);
    z-index: 1;
}

.search-box input {
    flex: 1;
    padding: 1rem 1rem 1rem 3rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    color: var(--text-light);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent-purple);
    box-shadow: 0 0 0 3px rgba(138, 43, 226, 0.1),
                inset 0 0 20px rgba(255, 255, 255, 0.05);
    background: rgba(255, 255, 255, 0.12);
}

.btn-search {
    white-space: nowrap;
}

.filter-controls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-weight: 500;
    color: var(--text-light);
}

.cosmic-select {
    padding: 0.8rem 1rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: var(--text-light);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
    padding-right: 2.5rem;
}

.cosmic-select:focus {
    outline: none;
    border-color: var(--accent-purple);
    box-shadow: 0 0 0 3px rgba(138, 43, 226, 0.1);
    background-color: rgba(255, 255, 255, 0.12);
}

.cosmic-select:hover {
    border-color: rgba(138, 43, 226, 0.3);
}

.catalog-content {
    min-height: 400px;
}

.loading-container {
    text-align: center;
    padding: 4rem;
}

.cosmic-spinner {
    width: 60px;
    height: 60px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--accent-purple);
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    animation: cosmic-spin 1s linear infinite;
}

@keyframes cosmic-spin {
    to {
        transform: rotate(360deg);
    }
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.5;
    animation: star-twinkle 2s ease-in-out infinite;
}

.empty-state h3 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: var(--text-light);
}

.empty-state p {
    color: var(--text-gray);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.error-state {
    text-align: center;
    padding: 4rem 2rem;
}

.error-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    animation: error-pulse 2s ease-in-out infinite;
}

@keyframes error-pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.error-state h3 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: #ff4757;
}

.error-state p {
    color: var(--text-gray);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.pagination {
    margin-top: 3rem;
    text-align: center;
}

.pagination-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.pagination-btn {
    padding: 0.8rem 1.5rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: var(--text-light);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pagination-btn:hover:not(.disabled) {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--accent-purple);
    transform: translateY(-2px);
}

.pagination-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-numbers {
    display: flex;
    gap: 0.5rem;
}

.pagination-number {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text-light);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pagination-number:hover:not(.active) {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(138, 43, 226, 0.3);
}

.pagination-number.active {
    background: linear-gradient(45deg, var(--accent-purple), var(--accent-pink));
    color: white;
    border-color: transparent;
    box-shadow: 0 5px 15px rgba(138, 43, 226, 0.3);
}

.pagination-dots {
    display: flex;
    align-items: center;
    color: var(--text-gray);
    padding: 0 0.5rem;
}

.pagination-info {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin-top: 1rem;
}

/* Сетка новелл в каталоге */
.novels-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

@media (max-width: 768px) {
    .novels-grid {
        grid-template-columns: 1fr;
    }
    
    .catalog-stats {
        flex-direction: column;
        align-items: center;
    }
    
    .stat-card {
        width: 100%;
        max-width: 250px;
    }
    
    .filter-controls {
        grid-template-columns: 1fr;
    }
    
    .search-box {
        flex-direction: column;
    }
    
    .search-box input {
        width: 100%;
    }
    
    .cosmic-title {
        font-size: 2.2rem;
    }
}