/**
 * VideoHub Theme Enhancements
 * Additional CSS for enhanced features
 */

/* ============================================
   DARK/LIGHT MODE TOGGLE
   ============================================ */
:root {
    --vh-transition-theme: 0.3s ease;
}

/* Light Mode Variables */
.vh-light-mode {
    --vh-primary: #6366f1;
    --vh-primary-dark: #4f46e5;
    --vh-secondary: #10b981;
    --vh-background: #f5f5f5;
    --vh-surface: #ffffff;
    --vh-surface-hover: #f0f0f0;
    --vh-text: #1a1a1a;
    --vh-text-muted: #666666;
    --vh-border: #e0e0e0;
}

.vh-light-mode .vh-header,
.vh-light-mode .vh-sidebar,
.vh-light-mode .vh-footer {
    background: var(--vh-surface);
    border-color: var(--vh-border);
}

.vh-light-mode .vh-search-input {
    background: var(--vh-background);
    border-color: var(--vh-border);
    color: var(--vh-text);
}

.vh-light-mode .vh-chip {
    background: var(--vh-surface);
    color: var(--vh-text);
}

.vh-light-mode .vh-chip.active {
    background: var(--vh-text);
    color: var(--vh-background);
}

.vh-light-mode .vh-video-card .vh-video-title {
    color: var(--vh-text);
}

/* Theme Toggle Button */
.vh-theme-toggle {
    position: relative;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 50%;
    color: var(--vh-text);
    cursor: pointer;
    transition: background var(--vh-transition);
}

.vh-theme-toggle:hover {
    background: var(--vh-surface-hover);
}

.vh-theme-toggle svg {
    width: 20px;
    height: 20px;
    transition: transform 0.3s ease;
}

.vh-theme-toggle .sun-icon {
    display: none;
}

.vh-theme-toggle .moon-icon {
    display: block;
}

.vh-light-mode .vh-theme-toggle .sun-icon {
    display: block;
}

.vh-light-mode .vh-theme-toggle .moon-icon {
    display: none;
}

/* ============================================
   SKELETON LOADING STATES
   ============================================ */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.vh-skeleton {
    background: linear-gradient(
        90deg,
        var(--vh-surface) 25%,
        var(--vh-surface-hover) 50%,
        var(--vh-surface) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--vh-card-radius);
}

.vh-skeleton-card {
    display: block;
}

.vh-skeleton-thumb {
    aspect-ratio: 16/9;
    border-radius: var(--vh-card-radius);
    margin-bottom: 12px;
}

.vh-skeleton-text {
    height: 14px;
    margin-bottom: 8px;
    border-radius: 4px;
}

.vh-skeleton-text.short {
    width: 60%;
}

.vh-skeleton-text.medium {
    width: 80%;
}

.vh-skeleton-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    flex-shrink: 0;
}

.vh-skeleton-row {
    display: flex;
    gap: 12px;
    padding: 12px 0;
}

/* Section header (used for multiple sections) */
.vh-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.vh-section-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--vh-text);
    display: flex;
    align-items: center;
    gap: 8px;
}

.vh-section-title svg {
    width: 24px;
    height: 24px;
    color: var(--vh-primary);
}

/* ============================================
   NETFLIX-STYLE HOVER ZOOM (DEFAULT)
   ============================================ */
.vh-video-grid {
    position: relative;
}

.vh-video-card {
    position: relative;
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                z-index 0s 0.3s,
                box-shadow 0.3s ease;
    transform-origin: center center;
    z-index: 1;
}

.vh-video-card:hover {
    transform: scale(var(--vh-hover-scale, 1.08));
    z-index: 50;
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                z-index 0s,
                box-shadow 0.3s ease;
}

.vh-video-card .vh-card-link {
    display: block;
    background: var(--vh-surface);
    border-radius: var(--vh-card-radius);
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.vh-video-card:hover .vh-card-link {
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.55),
                0 0 0 1px rgba(255, 255, 255, 0.1);
}

.vh-video-card .vh-thumbnail-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: var(--vh-card-radius) var(--vh-card-radius) 0 0;
}

.vh-video-card .vh-thumbnail {
    transition: transform 0.3s ease;
}

.vh-video-card:hover .vh-thumbnail {
    transform: scale(1.02);
}

/* Netflix-style info reveal on hover */
.vh-video-card .vh-video-info {
    transition: background 0.3s ease, padding 0.3s ease;
}

.vh-video-card:hover .vh-video-info {
    background: var(--vh-surface);
}

/* Netflix-style play indicator on hover */
.vh-video-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border: 2px solid transparent;
    border-radius: var(--vh-card-radius);
    transition: border-color 0.3s ease;
    pointer-events: none;
    z-index: 2;
}

.vh-video-card:hover::after {
    border-color: var(--vh-primary);
}

/* First and last cards in row - adjust transform origin */
.vh-video-grid > .vh-video-card:first-child {
    transform-origin: left center;
}

.vh-video-grid > .vh-video-card:last-child {
    transform-origin: right center;
}

/* Disable hover zoom on touch devices */
@media (hover: none) and (pointer: coarse) {
    .vh-video-card:hover {
        transform: none;
        z-index: 1;
    }
    
    .vh-video-card:hover .vh-card-link {
        box-shadow: none;
    }
    
    .vh-video-card:hover::after {
        border-color: transparent;
    }
    
    .vh-video-card:hover .vh-thumbnail {
        transform: none;
    }
}

/* ============================================
   ENHANCED VIDEO CARD STYLES
   ============================================ */
/* Style: Overlay */
.vh-card-style-overlay .vh-video-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 40px 16px 16px;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.vh-card-style-overlay .vh-thumbnail-wrapper {
    aspect-ratio: 16/9;
}

.vh-card-style-overlay .vh-video-card {
    position: relative;
    overflow: hidden;
    border-radius: var(--vh-card-radius);
}

.vh-card-style-overlay .vh-video-card:hover .vh-video-info {
    opacity: 1;
}

.vh-card-style-overlay .vh-channel-avatar {
    display: none;
}

.vh-card-style-overlay .vh-video-title {
    color: white;
}

.vh-card-style-overlay .vh-video-meta {
    color: rgba(255,255,255,0.7);
}

/* Style: Horizontal */
.vh-card-style-horizontal .vh-video-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.vh-card-style-horizontal .vh-video-card {
    display: flex;
    gap: 16px;
}

.vh-card-style-horizontal .vh-thumbnail-wrapper {
    width: 320px;
    flex-shrink: 0;
}

.vh-card-style-horizontal .vh-video-info {
    padding: 0;
    flex: 1;
}

.vh-card-style-horizontal .vh-channel-avatar {
    display: none;
}

@media (max-width: 768px) {
    .vh-card-style-horizontal .vh-video-card {
        flex-direction: column;
    }
    
    .vh-card-style-horizontal .vh-thumbnail-wrapper {
        width: 100%;
    }
}

/* Style: Netflix (Enhanced - larger scale, sliding info panel) */
.vh-card-style-netflix .vh-video-grid {
    gap: 8px;
}

.vh-card-style-netflix .vh-video-card {
    overflow: visible;
}

.vh-card-style-netflix .vh-video-card:hover {
    transform: scale(1.15);
    z-index: 100;
}

.vh-card-style-netflix .vh-card-link {
    position: relative;
}

.vh-card-style-netflix .vh-video-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 12px;
    background: linear-gradient(transparent, var(--vh-surface) 30%);
    border-radius: 0 0 var(--vh-card-radius) var(--vh-card-radius);
    transform: translateY(100%);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                opacity 0.3s ease;
}

.vh-card-style-netflix .vh-video-card:hover .vh-video-info {
    transform: translateY(0);
    opacity: 1;
    background: var(--vh-surface);
    box-shadow: 0 8px 20px rgba(0,0,0,0.4);
}

.vh-card-style-netflix .vh-thumbnail-wrapper {
    border-radius: var(--vh-card-radius);
}

.vh-card-style-netflix .vh-channel-avatar {
    display: none;
}

/* Netflix play button overlay */
.vh-card-style-netflix .vh-thumbnail-wrapper::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23000'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E");
    background-size: 24px;
    background-position: 55% center;
    background-repeat: no-repeat;
}

.vh-card-style-netflix .vh-video-card:hover .vh-thumbnail-wrapper::after {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

/* ============================================
   ADVANCED SEARCH
   ============================================ */
.vh-search-advanced {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--vh-surface);
    border: 1px solid var(--vh-border);
    border-radius: 0 0 var(--vh-card-radius) var(--vh-card-radius);
    padding: 16px;
    display: none;
    z-index: 100;
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.vh-search-advanced.active {
    display: block;
}

.vh-search-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.vh-filter-group {
    flex: 1;
    min-width: 150px;
}

.vh-filter-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--vh-text-muted);
    margin-bottom: 8px;
    text-transform: uppercase;
}

.vh-filter-select {
    width: 100%;
    padding: 8px 12px;
    background: var(--vh-background);
    border: 1px solid var(--vh-border);
    border-radius: 8px;
    color: var(--vh-text);
    font-size: 0.875rem;
}

.vh-filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.vh-filter-chip {
    padding: 6px 12px;
    background: var(--vh-surface-hover);
    border: 1px solid var(--vh-border);
    border-radius: 16px;
    color: var(--vh-text);
    font-size: 0.8125rem;
    cursor: pointer;
    transition: all var(--vh-transition);
}

.vh-filter-chip:hover,
.vh-filter-chip.active {
    background: var(--vh-primary);
    border-color: var(--vh-primary);
    color: white;
}

/* ============================================
   KEYBOARD SHORTCUTS MODAL
   ============================================ */
.vh-shortcuts-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1100;
    padding: 20px;
}

.vh-shortcuts-modal.active {
    display: flex;
}

.vh-shortcuts-content {
    background: var(--vh-surface);
    border-radius: var(--vh-card-radius);
    padding: 24px;
    max-width: 500px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
}

.vh-shortcuts-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.vh-shortcuts-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.vh-shortcut-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--vh-border);
}

.vh-shortcut-key {
    display: flex;
    gap: 4px;
}

.vh-shortcut-key kbd {
    padding: 4px 8px;
    background: var(--vh-background);
    border: 1px solid var(--vh-border);
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.8125rem;
    min-width: 28px;
    text-align: center;
}

.vh-shortcut-desc {
    color: var(--vh-text-muted);
    font-size: 0.875rem;
}


/* ============================================
   NOTIFICATION TOAST SYSTEM
   ============================================ */
.vh-toast-container {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1200;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
}

.vh-toast {
    padding: 12px 24px;
    background: var(--vh-surface);
    color: var(--vh-text);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    font-size: 0.875rem;
    pointer-events: auto;
    animation: toastIn 0.3s ease, toastOut 0.3s ease 2.7s forwards;
}

@keyframes toastIn {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes toastOut {
    from {
        transform: translateY(0);
        opacity: 1;
    }
    to {
        transform: translateY(20px);
        opacity: 0;
    }
}

.vh-toast.success {
    border-left: 4px solid var(--vh-secondary);
}

.vh-toast.error {
    border-left: 4px solid #ef4444;
}

.vh-toast.info {
    border-left: 4px solid var(--vh-primary);
}

/* ============================================
   VIDEO QUALITY BADGE
   ============================================ */
.vh-quality-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 2px 6px;
    background: var(--vh-primary);
    color: white;
    font-size: 0.625rem;
    font-weight: 700;
    border-radius: 4px;
    text-transform: uppercase;
}

.vh-quality-badge.hd {
    background: #10b981;
}

.vh-quality-badge.fhd {
    background: #6366f1;
}

.vh-quality-badge.uhd {
    background: #f59e0b;
}

/* ============================================
   NEW VIDEO BADGE
   ============================================ */
.vh-new-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 4px 8px;
    background: #ef4444;
    color: white;
    font-size: 0.625rem;
    font-weight: 700;
    border-radius: 4px;
    text-transform: uppercase;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* ============================================
   STATS DASHBOARD WIDGET (Admin)
   ============================================ */
.vh-stats-widget {
    background: var(--vh-surface);
    border-radius: var(--vh-card-radius);
    padding: 20px;
    margin-bottom: 20px;
}

.vh-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.vh-stat-card {
    background: var(--vh-background);
    border-radius: 8px;
    padding: 16px;
    text-align: center;
}

.vh-stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--vh-primary);
}

.vh-stat-label {
    font-size: 0.875rem;
    color: var(--vh-text-muted);
    margin-top: 4px;
}

/* ============================================
   SCROLL TO TOP BUTTON
   ============================================ */
.vh-scroll-top {
    position: fixed;
    bottom: 100px;
    right: 20px;
    width: 44px;
    height: 44px;
    background: var(--vh-primary);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 90;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.vh-scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

.vh-scroll-top:hover {
    background: var(--vh-primary-dark);
    transform: translateY(-2px);
}

.vh-scroll-top svg {
    width: 20px;
    height: 20px;
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .vh-header,
    .vh-sidebar,
    .vh-footer,
    .vh-bottom-nav,
    .vh-scroll-top,
    .vh-mini-player {
        display: none !important;
    }
    
    .vh-main {
        margin: 0 !important;
        padding: 0 !important;
    }
}

/* ============================================
   REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .vh-skeleton {
        animation: none;
        background: var(--vh-surface-hover);
    }
}

/* ============================================
   PULL TO REFRESH
   ============================================ */
.vh-pull-indicator {
    position: fixed;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: var(--vh-surface);
    border-radius: 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    z-index: 1100;
    opacity: 0;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.vh-pull-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--vh-border);
    border-top-color: var(--vh-primary);
    border-radius: 50%;
}

.vh-pull-spinner.spinning {
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.vh-pull-text {
    font-size: 0.875rem;
    color: var(--vh-text);
}

/* ============================================
   BLUR-UP IMAGE LOADING
   ============================================ */
.vh-blur-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, var(--vh-surface) 0%, var(--vh-surface-hover) 100%);
    animation: shimmer 1.5s infinite;
    z-index: 1;
}

.vh-blur-loading {
    filter: blur(10px);
    transform: scale(1.05);
    transition: filter 0.3s ease, transform 0.3s ease;
}

.vh-blur-loaded {
    filter: blur(0);
    transform: scale(1);
}

/* ============================================
   FAVORITES BUTTON
   ============================================ */
.vh-favorite-btn {
    position: absolute;
    top: 8px;
    left: 8px;
    width: 36px;
    height: 36px;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease, background 0.2s ease, transform 0.2s ease;
    z-index: 5;
}

.vh-video-card:hover .vh-favorite-btn {
    opacity: 1;
}

.vh-favorite-btn:hover {
    background: #ef4444;
    transform: scale(1.1);
}

.vh-favorite-btn.favorited {
    opacity: 1;
    background: #ef4444;
}

.vh-favorite-btn svg {
    width: 18px;
    height: 18px;
}

.vh-favorite-btn.favorited svg {
    fill: white;
}

/* Favorites Section */
.vh-favorites-section {
    margin-bottom: 40px;
}

.vh-favorites-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

/* ============================================
   SWIPE NAVIGATION FEEDBACK
   ============================================ */
.vh-swipe-hint {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    padding: 16px;
    background: var(--vh-surface);
    border-radius: var(--vh-card-radius);
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.vh-swipe-hint.left {
    left: 20px;
}

.vh-swipe-hint.right {
    right: 20px;
}

.vh-swipe-hint.active {
    opacity: 1;
}

.vh-swipe-hint svg {
    width: 24px;
    height: 24px;
    color: var(--vh-primary);
}

/* ============================================
   TOUCH FEEDBACK
   ============================================ */
@media (hover: none) and (pointer: coarse) {
    .vh-video-card {
        -webkit-tap-highlight-color: transparent;
    }
    
    .vh-video-card:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
    
    .vh-watch-later-btn,
    .vh-favorite-btn {
        opacity: 1;
    }
}

/* ============================================
   IN-FEED WIDGET AREA
   ============================================ */
.vh-in-feed-widget {
    grid-column: 1 / -1;
    padding: 20px;
    background: var(--vh-surface);
    border-radius: var(--vh-card-radius);
    border: 1px solid var(--vh-border);
    margin: 10px 0;
}

.vh-in-feed-widget .vh-widget {
    margin: 0;
}

.vh-in-feed-widget .vh-widget-title {
    margin-bottom: 12px;
}

/* ============================================
   HISTORY & LIKED VIDEOS PANELS
   ============================================ */
.vh-panel-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Account for WordPress admin bar on overlay */
body.admin-bar .vh-panel-overlay {
    top: 32px;
}

@media screen and (max-width: 782px) {
    body.admin-bar .vh-panel-overlay {
        top: 46px;
    }
}

.vh-panel-overlay.active {
    opacity: 1;
    visibility: visible;
}

.vh-panel {
    position: fixed;
    top: 0;
    right: -400px;
    width: 400px;
    max-width: 90vw;
    height: 100%;
    background: var(--vh-surface, #1a1a1a);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    transition: right 0.3s ease;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.3);
}

/* Account for WordPress admin bar */
body.admin-bar .vh-panel {
    top: 32px;
    height: calc(100% - 32px);
}

/* For mobile WordPress admin bar (height changes to 46px) */
@media screen and (max-width: 782px) {
    body.admin-bar .vh-panel {
        top: 46px;
        height: calc(100% - 46px);
    }
}

.vh-panel.active {
    right: 0;
}

.vh-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--vh-border, #333);
}

.vh-panel-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--vh-text, #fff);
}

.vh-panel-title svg {
    opacity: 0.8;
}

.vh-panel-close {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 50%;
    color: var(--vh-text, #fff);
    cursor: pointer;
    transition: background 0.2s ease;
}

.vh-panel-close:hover {
    background: var(--vh-surface-hover, #333);
}

.vh-panel-close svg {
    width: 20px;
    height: 20px;
}

.vh-panel-content {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
}

.vh-panel-empty {
    padding: 40px 20px;
    text-align: center;
    color: var(--vh-text-muted, #888);
    font-size: 14px;
}

.vh-panel-item {
    display: flex;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--vh-text, #fff);
    transition: background 0.2s ease;
}

.vh-panel-item:hover {
    background: var(--vh-surface-hover, #333);
}

.vh-panel-thumb {
    position: relative;
    width: 120px;
    min-width: 120px;
    aspect-ratio: 16/9;
    border-radius: 6px;
    overflow: hidden;
    background: #000;
}

.vh-panel-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.vh-panel-thumb .vh-duration {
    position: absolute;
    bottom: 4px;
    right: 4px;
    padding: 2px 6px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 4px;
    font-size: 11px;
    color: #fff;
}

.vh-thumb-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #333 0%, #222 100%);
}

.vh-panel-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.vh-panel-item-title {
    margin: 0 0 6px 0;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vh-panel-meta {
    font-size: 12px;
    color: var(--vh-text-muted, #888);
}

.vh-panel-footer {
    padding: 12px 20px;
    border-top: 1px solid var(--vh-border, #333);
}

.vh-btn-secondary {
    width: 100%;
    padding: 10px 16px;
    background: transparent;
    border: 1px solid var(--vh-border, #444);
    border-radius: 6px;
    color: var(--vh-text, #fff);
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.vh-btn-secondary:hover {
    background: var(--vh-surface-hover, #333);
    border-color: var(--vh-text-muted, #666);
}

@media (max-width: 480px) {
    .vh-panel {
        width: 100%;
        max-width: 100%;
        right: -100%;
    }
    
    .vh-panel-thumb {
        width: 100px;
        min-width: 100px;
    }
}
