from django import forms
from .models import Video, Category

class VideoUploadForm(forms.ModelForm):
    class Meta:
        model = Video
        fields = ['title', 'description', 'thumbnail', 'video_file', 'category', 'video_type']
        widgets = {
            'title': forms.TextInput(attrs={'class': 'form-control bg-dark text-white border-secondary', 'placeholder': 'Enter a catchy title'}),
            'description': forms.Textarea(attrs={'class': 'form-control bg-dark text-white border-secondary', 'placeholder': 'Describe your cosmic content', 'rows': 4}),
            'category': forms.Select(attrs={'class': 'form-select bg-dark text-white border-secondary'}),
            'video_type': forms.Select(attrs={'class': 'form-select bg-dark text-white border-secondary'}),
            'thumbnail': forms.FileInput(attrs={'class': 'form-control bg-dark text-white border-secondary'}),
            'video_file': forms.FileInput(attrs={'class': 'form-control bg-dark text-white border-secondary'}),
        }
