.youtube-feed-container {
    width: 100%;
}

/* Grid Layout */
.youtube-feed-grid {
    display: grid;
    gap: 16px;
    /* Removed grid-template-columns to let Elementor controls handle it */
}

/* Carousel Layout */
.youtube-feed-carousel {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.youtube-feed-carousel::-webkit-scrollbar {
    display: none;
}

.youtube-feed-carousel .video-item {
    flex: 0 0 354px;
    margin-right: 16px;
}

/* Video Item */
.video-item {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.video-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

/* Video Link */
.video-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.video-link:hover {
    text-decoration: none;
    color: inherit;
}

/* Thumbnail */
.video-thumbnail {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Video Info */
.video-title {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    margin: 12px 12px 8px;
    color: #0f0f0f;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-description {
    font-size: 12px;
    line-height: 1.4;
    margin: 0 12px 12px;
    color: #606060;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Responsive */
@media (max-width: 768px) {
    .youtube-feed-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
    
    .youtube-feed-carousel .video-item {
        flex: 0 0 280px;
    }
}

@media (max-width: 480px) {
    .youtube-feed-grid {
        grid-template-columns: 1fr;
    }
    
    .youtube-feed-carousel .video-item {
        flex: 0 0 100%;
    }
}

/* Elementor Responsive Controls */
@media (max-width: 1024px) {
    .youtube-feed-grid[style*="grid-template-columns: repeat(6, 1fr)"] {
        grid-template-columns: repeat(4, 1fr) !important;
    }
    
    .youtube-feed-grid[style*="grid-template-columns: repeat(5, 1fr)"] {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 768px) {
    .youtube-feed-grid[style*="grid-template-columns: repeat(4, 1fr)"] {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    .youtube-feed-grid[style*="grid-template-columns: repeat(3, 1fr)"] {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 480px) {
    .youtube-feed-grid[style*="grid-template-columns: repeat(2, 1fr)"] {
        grid-template-columns: 1fr !important;
    }
}

/* YouTube Profile Widget Styles */
.youtube-profile-container {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.youtube-profile-container:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

/* Horizontal Layout */
.youtube-profile-horizontal {
    display: flex;
    align-items: center;
    gap: 20px;
}

.youtube-profile-horizontal .youtube-profile-avatar {
    flex-shrink: 0;
}

.youtube-profile-horizontal .youtube-profile-content {
    flex: 1;
}

/* Vertical Layout */
.youtube-profile-vertical {
    text-align: center;
    padding: 24px;
}

.youtube-profile-vertical .youtube-profile-avatar {
    margin: 0 auto 16px;
}

.youtube-profile-vertical .youtube-profile-stats {
    justify-content: center;
}

/* Compact Layout */
.youtube-profile-compact {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
}

.youtube-profile-compact .youtube-profile-avatar img {
    width: 48px !important;
    height: 48px !important;
}

.youtube-profile-compact .youtube-profile-name {
    font-size: 16px;
    margin: 0 0 4px;
}

.youtube-profile-compact .youtube-profile-stats {
    font-size: 12px;
}

/* Avatar */
.youtube-profile-avatar {
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.youtube-profile-avatar img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* Content */
.youtube-profile-content {
    flex: 1;
}

.youtube-profile-name {
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 8px;
    color: #0f0f0f;
    line-height: 1.3;
}

/* Stats */
.youtube-profile-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin: 0 0 12px;
    color: #606060;
    font-size: 14px;
}

.youtube-profile-stats .stat-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.youtube-profile-stats .stat-item:not(:last-child)::after {
    content: '•';
    margin-left: 8px;
    color: #ccc;
}

/* Description */
.youtube-profile-description {
    font-size: 14px;
    line-height: 1.5;
    margin: 0 0 16px;
    color: #606060;
}

/* Channel Link */
.youtube-profile-link {
    display: inline-block;
    padding: 8px 16px;
    background: #ff0000;
    color: #fff;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.youtube-profile-link:hover {
    background: #cc0000;
    color: #fff;
    text-decoration: none;
}

/* Responsive */
@media (max-width: 768px) {
    .youtube-profile-horizontal {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }
    
    .youtube-profile-stats {
        justify-content: center;
    }
    
    .youtube-profile-compact {
        padding: 8px;
    }
    
    .youtube-profile-compact .youtube-profile-avatar img {
        width: 40px !important;
        height: 40px !important;
    }
}

@media (max-width: 480px) {
    .youtube-profile-name {
        font-size: 18px;
    }
    
    .youtube-profile-stats {
        font-size: 12px;
        gap: 12px;
    }
    
    .youtube-profile-description {
        font-size: 13px;
    }
}
