/* Library Headers & Filters */
.library-header { 
    display: flex; justify-content: space-between; align-items: flex-end; 
    margin-bottom: 40px; border-bottom: 1px solid var(--border-color); 
    padding-bottom: 20px; 
}

.page-title { margin: 0 0 10px; color: var(--text-main); }
.page-subtitle { margin: 0; color: var(--text-muted); }

.pe-tabs { 
    background: var(--bg-subtle); 
    padding: 4px; border-radius: 8px; display: inline-flex; 
}
.pe-tab { 
    padding: 8px 16px; border-radius: 6px; border: none; 
    background: transparent; cursor: pointer; font-weight: 600; 
    color: var(--text-muted); 
}
.pe-tab.active { 
    background: var(--bg-surface); 
    color: var(--primary); 
    box-shadow: 0 2px 4px var(--shadow-color); 
}

/* Library Grid (Folder/Tool Cards) */
.library-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); 
    gap: 20px; 
}

.lib-card { 
    background: var(--bg-surface); 
    border: 1px solid var(--border-color); 
    border-radius: 12px; padding: 20px; 
    display: block; transition: 0.2s; 
}
.lib-card:hover { 
    border-color: var(--primary); 
    transform: translateY(-3px); 
    box-shadow: 0 4px 12px var(--shadow-color);
}

.lib-card-header { display: flex; justify-content: space-between; margin-bottom: 15px; }

.lib-icon { 
    width: 40px; height: 40px; 
    background: var(--bg-subtle); 
    color: var(--primary); 
    border-radius: 8px; 
    display: flex; align-items: center; justify-content: center; 
    font-weight: bold; 
}

.lib-badge { 
    background: var(--bg-subtle); 
    color: var(--text-muted);
    padding: 4px 10px; border-radius: 20px; 
    font-size: 0.75rem; height: fit-content; 
}

.lib-card-body h3 { margin: 0 0 10px; color: var(--text-main); }
.lib-meta { 
    display: flex; justify-content: space-between; 
    font-size: 0.9rem; color: var(--text-muted); font-weight: 500; 
}
.lib-meta span:last-child { color: var(--primary); }