/**
 * VGM Category Page Styles
 * Prefix: vgmctgr-
 */

/* Variables */
:root {
    --vgm-gold: #F3DF70;
    --vgm-gold-light: #FFF6BF;
    --vgm-gold-dark: #E5D060;
    --vgm-brown: #8B7355;
    --vgm-gray: #6C757D;
    --vgm-gray-light: #F8F9FA;
    --vgm-border: #E9ECEF;
    --vgm-text: #2C3E50;
    --vgm-text-light: #6C757D;
}

/* Base */
.vgmctgr-wrapper {
    font-family: 'Be Vietnam Pro', sans-serif;
    color: var(--vgm-text);
    line-height: 1.6;
}

.vgmctgr-wrapper * {
    box-sizing: border-box;
}

/* Container */
.vgmctgr-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Category Header */
.vgmctgr-header {
    position: relative;
    padding: 60px 0 40px;
    margin-bottom: 40px;
    background: linear-gradient(135deg, var(--vgm-gray-light) 0%, white 100%);
    border-bottom: 1px solid var(--vgm-border);
}

.vgmctgr-header-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, var(--vgm-gold-light) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, var(--vgm-gold-light) 0%, transparent 50%);
    opacity: 0.3;
}

.vgmctgr-header-content {
    position: relative;
    z-index: 1;
}

/* Breadcrumbs */
.vgmctgr-breadcrumb {
    margin-bottom: 20px !important;
    font-size: 14px !important;
    color: #6C757D !important;
}

.vgmctgr-breadcrumb a {
    color: #6C757D !important;
    text-decoration: none !important;
    transition: color 0.3s;
}

.vgmctgr-breadcrumb a:hover {
    color: #E5D060 !important;
    text-decoration: none !important;
}

.vgmctgr-breadcrumb-sep {
    margin: 0 8px !important;
    color: #CCCCCC !important;
    display: inline-block !important;
}

.vgmctgr-breadcrumb-current {
    color: #8B7355 !important;
    font-weight: 500 !important;
}

/* Title & Description */
.vgmctgr-title {
    font-family: 'Playfair Display', serif;
    font-size: 48px;
    font-weight: 700;
    margin: 0 0 15px 0;
    color: var(--vgm-text);
    line-height: 1.2;
}

.vgmctgr-description {
    font-size: 18px;
    color: var(--vgm-text-light);
    margin: 0 0 20px 0;
    max-width: 700px;
    line-height: 1.6;
}

/* Meta Info */
.vgmctgr-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
}

.vgmctgr-count {
    display: inline-block;
    padding: 6px 16px;
    background: var(--vgm-gold);
    color: var(--vgm-brown);
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

/* View Toggle */
.vgmctgr-view-toggle {
    display: flex;
    gap: 5px;
    background: white;
    padding: 4px;
    border-radius: 8px;
    border: 1px solid var(--vgm-border);
}

.vgmctgr-view-btn {
    padding: 8px 12px;
    background: transparent;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    color: var(--vgm-text-light);
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vgmctgr-view-btn:hover {
    background: var(--vgm-gray-light);
}

.vgmctgr-view-btn.active {
    background: var(--vgm-gold);
    color: var(--vgm-brown);
}

/* Content Layout */
.vgmctgr-content {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 40px;
    margin-bottom: 60px;
}

/* Posts Grid */
.vgmctgr-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

/* Links - No underline */
.vgmctgr-post-link,
.vgmctgr-popular-content a,
.vgmctgr-subcats-list a,
.vgmctgr-tag,
.vgmctgr-breadcrumb a {
    text-decoration: none !important;
}

.vgmctgr-post-link:hover,
.vgmctgr-popular-content a:hover,
.vgmctgr-subcats-list a:hover,
.vgmctgr-tag:hover,
.vgmctgr-breadcrumb a:hover {
    text-decoration: none !important;
}

/* Post Card */
.vgmctgr-post-card {
    position: relative;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--vgm-border);
    transition: all 0.3s ease;
    cursor: pointer;
}

.vgmctgr-post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-color: var(--vgm-gold);
}

.vgmctgr-post-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

/* Post Image */
.vgmctgr-post-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: var(--vgm-gray-light);
}

.vgmctgr-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.vgmctgr-post-card:hover .vgmctgr-post-image img {
    transform: scale(1.08);
}

.vgmctgr-post-image-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--vgm-border);
}

/* Post Overlay */
.vgmctgr-post-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.7) 100%);
    display: flex;
    align-items: flex-end;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s;
}

.vgmctgr-post-card:hover .vgmctgr-post-overlay {
    opacity: 1;
}

.vgmctgr-read-more {
    color: white;
    font-size: 14px;
    font-weight: 500;
}

/* Post Content */
.vgmctgr-post-content {
    padding: 20px;
}

.vgmctgr-post-category {
    font-size: 11px;
    color: var(--vgm-text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
    display: inline-flex;
    align-items: center;
}

.vgmctgr-post-category::after {
    content: '';
    width: 20px;
    height: 1px;
    background: var(--vgm-gold);
    margin-left: 8px;
}

.vgmctgr-post-title {
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.3;
    margin: 0 0 12px 0;
    color: var(--vgm-text);
}

.vgmctgr-post-excerpt {
    font-size: 14px;
    color: var(--vgm-text-light);
    line-height: 1.6;
    margin: 0 0 15px 0;
}

/* Post Meta */
.vgmctgr-post-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: var(--vgm-text-light);
}

.vgmctgr-post-author {
    display: flex;
    align-items: center;
    gap: 8px;
}

.vgmctgr-post-author img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid var(--vgm-gold);
}

.vgmctgr-post-info {
    display: flex;
    align-items: center;
    gap: 6px;
}

.vgmctgr-post-sep {
    color: var(--vgm-border);
}

/* Bookmark Button */
.vgmctgr-bookmark-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: white;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.vgmctgr-post-card:hover .vgmctgr-bookmark-btn {
    opacity: 1;
    transform: scale(1);
}

.vgmctgr-bookmark-btn:hover {
    background: var(--vgm-gold);
}

.vgmctgr-bookmark-btn.active svg {
    fill: var(--vgm-gold);
    stroke: var(--vgm-gold);
}

/* List View */
.vgmctgr-posts-grid.list-view {
    grid-template-columns: 1fr;
}

.vgmctgr-posts-grid.list-view .vgmctgr-post-card {
    display: flex;
    height: auto;
}

.vgmctgr-posts-grid.list-view .vgmctgr-post-link {
    display: flex;
    width: 100%;
}

.vgmctgr-posts-grid.list-view .vgmctgr-post-image {
    width: 280px;
    height: 180px;
    flex-shrink: 0;
}

.vgmctgr-posts-grid.list-view .vgmctgr-post-content {
    flex: 1;
    padding: 25px 30px;
}

.vgmctgr-posts-grid.list-view .vgmctgr-post-title {
    font-size: 24px;
}

.vgmctgr-posts-grid.list-view .vgmctgr-post-excerpt {
    font-size: 15px;
    margin-bottom: 20px;
}

/* Banner */
.vgmctgr-banner-horizontal {
    grid-column: 1 / -1;
    background: var(--vgm-gray-light);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    min-height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vgmctgr-banner-placeholder {
    color: var(--vgm-text-light);
}

.vgmctgr-banner-placeholder p {
    margin: 0;
    font-weight: 500;
    font-size: 16px;
}

.vgmctgr-banner-placeholder small {
    display: block;
    margin-top: 5px;
    font-size: 11px;
}

/* Sidebar */
.vgmctgr-sidebar {
    position: sticky;
    top: 30px;
    max-height: calc(100vh - 60px);
    overflow-y: auto;
}

/* Widgets */
.vgmctgr-widget {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    border: 1px solid var(--vgm-border);
}

.vgmctgr-widget-title {
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--vgm-gold);
}

/* Category Info Widget */
.vgmctgr-widget-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
}

.vgmctgr-stat {
    text-align: center;
    padding: 15px;
    background: var(--vgm-gray-light);
    border-radius: 8px;
}

.vgmctgr-stat-number {
    display: block;
    font-size: 24px;
    font-weight: 700;
    color: var(--vgm-gold-dark);
    margin-bottom: 5px;
}

.vgmctgr-stat-label {
    font-size: 12px;
    color: var(--vgm-text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Subcategories */
.vgmctgr-subcats-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.vgmctgr-subcats-list li {
    padding: 10px 0;
    border-bottom: 1px solid var(--vgm-border);
}

.vgmctgr-subcats-list li:last-child {
    border-bottom: none;
}

.vgmctgr-subcats-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-decoration: none;
    color: var(--vgm-text);
    transition: color 0.3s;
}

.vgmctgr-subcats-list a:hover {
    color: var(--vgm-gold-dark);
}

.vgmctgr-subcat-count {
    color: var(--vgm-text-light);
    font-size: 13px;
}

/* Popular Posts */
.vgmctgr-popular-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.vgmctgr-popular-item {
    display: flex;
    gap: 15px;
    padding: 12px 0;
    border-bottom: 1px solid var(--vgm-border);
}

.vgmctgr-popular-item:last-child {
    border-bottom: none;
}

.vgmctgr-popular-number {
    width: 30px;
    height: 30px;
    background: var(--vgm-gold);
    color: var(--vgm-brown);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
}

.vgmctgr-popular-content {
    flex: 1;
}

.vgmctgr-popular-content h4 {
    margin: 0 0 5px 0;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
}

.vgmctgr-popular-content a {
    text-decoration: none;
    color: var(--vgm-text);
    transition: color 0.3s;
}

.vgmctgr-popular-content a:hover {
    color: var(--vgm-gold-dark);
}

.vgmctgr-popular-date {
    font-size: 12px;
    color: var(--vgm-text-light);
}

/* Tags Cloud */
.vgmctgr-tags-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.vgmctgr-tag {
    padding: 6px 12px;
    background: var(--vgm-gray-light);
    color: var(--vgm-text);
    border-radius: 20px;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.3s;
}

.vgmctgr-tag:hover {
    background: var(--vgm-gold);
    color: var(--vgm-brown);
    transform: translateY(-2px);
}

/* No Posts */
.vgmctgr-no-posts {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
}

.vgmctgr-no-posts h2 {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    margin-bottom: 15px;
}

.vgmctgr-no-posts p {
    color: var(--vgm-text-light);
    margin-bottom: 30px;
}

.vgmctgr-back-home {
    display: inline-block;
    padding: 12px 30px;
    background: var(--vgm-gold);
    color: var(--vgm-brown);
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    transition: transform 0.3s;
}

.vgmctgr-back-home:hover {
    transform: translateY(-2px);
}

/* Pagination */
.vgmctgr-pagination {
    grid-column: 1 / -1;
    margin-top: 50px;
}

.vgmctgr-pagination ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.vgmctgr-pagination li {
    display: inline-block;
}

.vgmctgr-pagination a,
.vgmctgr-pagination span {
    display: block;
    padding: 10px 16px;
    background: white;
    border: 1px solid var(--vgm-border);
    border-radius: 8px;
    color: var(--vgm-text);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s;
}

.vgmctgr-pagination a:hover {
    background: var(--vgm-gold);
    border-color: var(--vgm-gold);
    color: var(--vgm-brown);
}

.vgmctgr-pagination .current span {
    background: var(--vgm-gold);
    border-color: var(--vgm-gold);
    color: var(--vgm-brown);
    font-weight: 600;
}

.vgmctgr-pagination .dots span {
    border: none;
    background: transparent;
}

/* Responsive */
@media (max-width: 1200px) {
    .vgmctgr-content {
        grid-template-columns: 1fr;
    }
    
    .vgmctgr-sidebar {
        /* Show sidebar on tablet/mobile but below content */
        margin-top: 40px;
    }
}

@media (max-width: 768px) {
    .vgmctgr-title {
        font-size: 32px;
    }
    
    .vgmctgr-description {
        font-size: 16px;
    }
    
    .vgmctgr-posts-grid {
        grid-template-columns: 1fr;
    }
    
    .vgmctgr-posts-grid.list-view .vgmctgr-post-card {
        flex-direction: column;
    }
    
    .vgmctgr-posts-grid.list-view .vgmctgr-post-link {
        flex-direction: column;
    }
    
    .vgmctgr-posts-grid.list-view .vgmctgr-post-image {
        width: 100%;
        height: 200px;
    }
    
    .vgmctgr-view-toggle {
        display: none;
    }
    
    .vgmctgr-meta {
        justify-content: center;
    }
}