/* ═══════════════════════════════════════════════════════════════
   CATEGORÍA - DISEÑO PROFESIONAL TIPO FIGMA
   Archivo: /public/css/category.css
   ═══════════════════════════════════════════════════════════════ */

.category-page {
    padding-top: 90px;
    background: #fff;
}

/* Header de Categoría */
.category-header {
    background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%);
    padding: 40px 0 30px;
    border-bottom: 1px solid #e5e7eb;
}

.breadcrumb-nav {
    font-size: 13px;
    color: #666;
    margin-bottom: 16px;
}

.breadcrumb-nav a {
    color: #666;
    text-decoration: none;
}

.breadcrumb-nav a:hover {
    color: #ff6b35;
}

.breadcrumb-nav span {
    margin: 0 8px;
    color: #ccc;
}

.category-title {
    font-size: 36px;
    font-weight: 800;
    color: #111;
    margin-bottom: 8px;
}

.category-count {
    font-size: 14px;
    color: #666;
    margin: 0;
}

/* Container */
.category-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 60px;
}

.category-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 50px;
}

/* Posts Grid */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.post-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.post-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
    border-color: #ff6b35;
}

.post-image {
    display: block;
    aspect-ratio: 16/9;
    overflow: hidden;
}

.post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.post-card:hover .post-image img {
    transform: scale(1.05);
}

.post-content {
    padding: 20px;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    color: #999;
    margin-bottom: 12px;
}

.reading-time::before {
    content: '•';
    margin-right: 12px;
}

.post-title {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 12px;
}

.post-title a {
    color: #111;
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-card:hover .post-title a {
    color: #ff6b35;
}

.post-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 16px;
}

.read-more {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #ff6b35;
    text-decoration: none;
    transition: gap 0.3s ease;
}

.read-more:hover {
    gap: 10px;
}

.read-more svg {
    stroke: #ff6b35;
}

/* Paginación */
.pagination-wrapper {
    margin-top: 60px;
    text-align: center;
}

.pagination {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    padding: 0;
    margin: 0 0 16px 0;
}

.page-item {
    margin: 0;
}

.page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    color: #374151;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.page-arrow {
    min-width: 40px;
    padding: 0;
}

.page-link:hover {
    background: #f9fafb;
    border-color: #ff6b35;
    color: #ff6b35;
}

.page-item.active .page-link {
    background: #ff6b35;
    border-color: #ff6b35;
    color: #fff;
    font-weight: 700;
}

.page-item.disabled .page-link {
    background: #f9fafb;
    border-color: #e5e7eb;
    color: #d1d5db;
    cursor: not-allowed;
    pointer-events: none;
}

.pagination-info {
    font-size: 13px;
    color: #6b7280;
    margin-top: 8px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 80px 20px;
}

.empty-state svg {
    color: #d1d5db;
    margin-bottom: 24px;
}

.empty-state h3 {
    font-size: 24px;
    font-weight: 700;
    color: #111;
    margin-bottom: 12px;
}

.empty-state p {
    font-size: 16px;
    color: #666;
    margin-bottom: 24px;
}

.btn-home {
    display: inline-block;
    padding: 12px 24px;
    background: #ff6b35;
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: background 0.3s ease;
}

.btn-home:hover {
    background: #e55a25;
    color: #fff;
}

/* Sidebar */
.category-sidebar {
    position: sticky;
    top: 110px;
    align-self: start;
}

.sidebar-widget {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.sidebar-banner {
    padding: 16px;
    text-align: center;
}

.ad-label {
    display: block;
    font-size: 10px;
    color: #9ca3af;
    text-align: center;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.sidebar-banner img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.widget-title {
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 20px;
    color: #111;
}

.category-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-links li {
    border-bottom: 1px solid #e5e7eb;
}

.category-links li:last-child {
    border-bottom: none;
}

.category-links a {
    display: block;
    padding: 12px 0;
    color: #374151;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    padding-left: 20px;
}

.category-links a::before {
    content: '→';
    position: absolute;
    left: 0;
    color: #ff6b35;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.category-links a:hover {
    color: #ff6b35;
    padding-left: 24px;
}

.category-links a:hover::before {
    opacity: 1;
}

.category-links li.active a {
    color: #ff6b35;
    font-weight: 700;
}

/* Responsive */
@media (max-width: 1024px) {
    .category-layout {
        grid-template-columns: 1fr;
    }
    
    .category-sidebar {
        position: static;
        max-width: 600px;
        margin: 40px auto 0;
    }
}

@media (max-width: 768px) {
    .category-container {
        padding: 24px 20px;
    }
    
    .category-title {
        font-size: 28px;
    }
    
    .posts-grid {
        grid-template-columns: 1fr;
    }
    
    .pagination {
        flex-wrap: wrap;
    }
}

@media (max-width: 480px) {
    .category-header {
        padding: 24px 0 20px;
    }
    
    .category-title {
        font-size: 24px;
    }
    
    .category-container {
        padding: 20px 16px;
    }
    
    .page-link {
        min-width: 36px;
        height: 36px;
        font-size: 13px;
    }
}