/**
 * Tags Page Styles
 *
 * CSS for the wallpaper theme tags page
 *
 * @package Wallpaper
 * @since 1.0.0
 */

/* -----------------------------------------------------------------------------
 * Container & Layout
 * -------------------------------------------------------------------------- */
.tags-container-fluid {
    width: 100%;
    padding: 20px;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
    max-width: 1700px;
    margin: 0 auto;
}

.tags-main-content {
    width: 100%;
}

.tags-header {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

.tags-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 15px;
}

.tags-header::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #4f46e5, #ec4899);
    border-radius: 2px;
    margin: 15px auto 0;
}

.tags-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #333;
    position: relative;
    display: inline-block;
    margin: 0;
}

.tags-header .tags-title {
    text-align: left;
}

.tags-description {
    font-size: 1.1rem;
    color: #666;
    max-width: 700px;
    margin: 10px auto 0;
}

/* Tags search */
.tags-search {
    position: relative;
    min-width: 280px;
}

#tag-search-input {
    width: 100%;
    padding: 10px 15px;
    padding-right: 50px;
    border-radius: 30px;
    border: 2px solid #e5e7eb;
    font-size: 0.95rem;
    outline: none;
    transition: all 0.3s ease;
}

#tag-search-input:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2);
}

#tag-search-button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: #f0f0f0;
    border: none;
    border-radius: 50%;
    color: #444;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

#tag-search-button:hover {
    background: #e0e0e0;
    transform: translateY(-50%) scale(1.05);
}

/* Tags section */
.tags-section {
    background-color: #fff;
    border-radius: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    padding: 30px;
    margin-bottom: 40px;
}

.alphabet-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 25px;
    justify-content: center;
}

.alphabet-nav a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: #f3f4f6;
    color: #4b5563;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.alphabet-nav a:hover, 
.alphabet-nav a.active {
    background-color: #4f46e5;
    color: white;
}

.letter-group {
    margin-bottom: 30px;
    animation: fadeIn 0.5s ease;
}

.letter-heading {
    font-size: 1.8rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 2px solid #f3f4f6;
    position: relative;
}

.letter-heading::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, #4f46e5, #ec4899);
}

.tags-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.tag-item {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    background-color: #f3f4f6;
    border-radius: 30px;
    color: #4b5563;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.tag-item:hover {
    background-color: #4f46e5;
    color: white;
    transform: translateY(-2px);
}

.tag-item.featured-tag {
    background: #f5f3ff;
    color: #4f46e5;
    box-shadow: 0 2px 4px rgba(79, 70, 229, 0.1);
    border: 1px solid rgba(79, 70, 229, 0.2);
}

.tag-item.featured-tag:hover {
    background: #ebe9ff;
    transform: translateY(-2px);
    box-shadow: 0 3px 6px rgba(79, 70, 229, 0.15);
}

.tag-item.featured-tag .tag-count {
    background-color: rgba(79, 70, 229, 0.1);
}

.tag-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.1);
    color: inherit;
    border-radius: 20px;
    padding: 2px 8px;
    font-size: 0.8rem;
    margin-left: 8px;
}

.tag-item:hover .tag-count {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Sidebar */
.tags-sidebar {
    width: 100%;
}

.sidebar-section {
    background-color: #fff;
    border-radius: 24px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    padding: 25px;
    margin-bottom: 30px;
    position: sticky;
    top: 30px;
}

.sidebar-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 25px;
    text-align: center;
    position: relative;
}

.sidebar-section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #4f46e5, #ec4899);
    border-radius: 2px;
    margin: 10px auto 0;
}

/* Featured Tags Section */
.featured-tags-section {
    margin-bottom: 30px;
    background: #ffffff;
    border: 1px solid #f0f0f0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.featured-tags-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.featured-tag-item {
    display: inline-flex;
    align-items: center;
    padding: 8px 15px;
    background: #f5f3ff;
    color: #4f46e5;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 1px 2px rgba(79, 70, 229, 0.1);
    border: 1px solid rgba(79, 70, 229, 0.15);
}

.featured-tag-item:hover {
    background: #ebe9ff;
    transform: translateY(-2px);
    box-shadow: 0 2px 4px rgba(79, 70, 229, 0.15);
}

.featured-tag-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(79, 70, 229, 0.1);
    color: inherit;
    border-radius: 20px;
    padding: 2px 8px;
    font-size: 0.8rem;
    margin-left: 8px;
}

/* Popular Tags */
.popular-tags-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.popular-tag-item {
    display: inline-flex;
    align-items: center;
    padding: 8px 15px;
    background-color: #f3f4f6;
    border-radius: 30px;
    color: #4b5563;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.popular-tag-item.is-featured {
    background: #f5f3ff;
    color: #4f46e5;
    box-shadow: 0 1px 2px rgba(79, 70, 229, 0.1);
    border: 1px solid rgba(79, 70, 229, 0.15);
}

.popular-tag-item:hover {
    background-color: #4f46e5;
    color: white;
    transform: translateY(-2px);
}

.popular-tag-item.is-featured:hover {
    background: #ebe9ff;
    transform: translateY(-2px);
    box-shadow: 0 2px 4px rgba(79, 70, 229, 0.15);
}

.popular-tag-item.is-featured .popular-tag-count {
    background-color: rgba(79, 70, 229, 0.1);
}

.popular-tag-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.1);
    color: inherit;
    border-radius: 20px;
    padding: 2px 8px;
    font-size: 0.8rem;
    margin-left: 8px;
}

.popular-tag-item:hover .popular-tag-count {
    background-color: rgba(255, 255, 255, 0.2);
}

/* For when no tags are found */
.no-tags {
    text-align: center;
    padding: 50px 20px;
    color: #6b7280;
}

.no-tags h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #374151;
}

.no-tags p {
    font-size: 1.1rem;
    margin-bottom: 25px;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive design */
@media (max-width: 1200px) {
    .tags-grid {
        gap: 10px;
    }
}

@media (max-width: 992px) {
    .tags-section {
        padding: 25px;
    }
    
    .alphabet-nav {
        gap: 6px;
    }
    
    .alphabet-nav a {
        width: 32px;
        height: 32px;
    }
    
    .letter-heading {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .tags-container-fluid {
        grid-template-columns: 1fr;
    }
    
    .tags-header-row {
        flex-direction: column;
        align-items: stretch;
    }
    
    .tags-search {
        width: 100%;
    }
    
    .tags-header .tags-title {
        text-align: center;
    }
    
    .alphabet-nav {
        gap: 5px;
    }
    
    .alphabet-nav a {
        width: 30px;
        height: 30px;
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .tags-section {
        padding: 20px;
        border-radius: 16px;
    }
    
    .tags-title {
        font-size: 2rem;
    }
    
    .letter-heading {
        font-size: 1.4rem;
    }
    
    .alphabet-nav {
        gap: 4px;
    }
    
    .alphabet-nav a {
        width: 28px;
        height: 28px;
        font-size: 0.85rem;
    }
    
    .tag-item, .popular-tag-item, .featured-tag-item {
        padding: 6px 12px;
        font-size: 0.9rem;
    }
    
    .tag-count, .popular-tag-count, .featured-tag-count {
        padding: 1px 6px;
        font-size: 0.75rem;
    }
} 