/* Modern Video Card System */
.vibe-videos-widget {
    --card-spacing: 15px;
    --card-radius: 8px;
    --card-bg: #ffffff;
    --card-text: #1a1a1a;
    --card-meta: #666666;
    --card-border: #e5e7eb;
    --card-hover: #f3f4f6;
    --header-padding: 15px;
    --animation-duration: 0.6s;
    margin-bottom: 2rem;
    position: relative;
}

.gc-widget-header {
    transition: background-color 0.3s ease;
    border-radius: 12px 12px 0 0;
}

.vibe-widget-content {
    background: var(--card-bg);
    border-radius: 0 0 12px 12px;
    padding: var(--card-spacing);
    box-shadow: 
        0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -1px rgba(0, 0, 0, 0.06),
        0 10px 15px -3px rgba(0, 0, 0, 0.05);
}

.vibe-widget-header-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.vibe-timeframe-selector {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.vibe-timeframe-btn {
    font-size: 0.875rem;
    padding: 4px 8px;
    border-radius: 4px;
    text-decoration: none;
    color: var(--card-meta);
    transition: all 0.2s ease;
    opacity: 0.7;
}

.vibe-timeframe-btn:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.05);
}

.vibe-timeframe-btn.active {
    opacity: 1;
    font-weight: 600;
    background: rgba(0, 0, 0, 0.1);
}

.vibe-widget-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--card-text);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.vibe-widget-title i {
    font-size: 1.25rem;
    opacity: 0.9;
}

/* Video Grid Layout */
.video-grid {
    display: grid;
    grid-template-columns: repeat(var(--columns-desktop, 3), minmax(0, 1fr));
    gap: var(--card-spacing);
}

/* Video Card Component */
.vibe-video-card {
    background: var(--card-bg);
    border-radius: var(--card-radius);
    overflow: hidden;
    box-shadow: 
        0 4px 6px -1px rgba(0,0,0,0.05),
        0 10px 15px -3px rgba(0,0,0,0.1);
    display: grid;
    grid-template-rows: auto auto auto;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--card-border);
}

.vibe-video-card:hover {
    transform: translateY(-4px);
    box-shadow: 
        0 10px 20px -5px rgba(0,0,0,0.1),
        0 20px 30px -10px rgba(0,0,0,0.15);
}

.vibe-video-thumb {
    position: relative;
    padding-top: 56.25%;
    background: #f0f0f0;
    overflow: hidden;
}

.vibe-video-thumb img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.vibe-video-thumb::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0);
    transition: background 0.3s ease;
    z-index: 1;
}

.vibe-video-thumb::after {
    content: '\f04b';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1a1a1a;
    font-size: 24px;
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 2;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.vibe-video-card:hover .vibe-video-thumb::before {
    background: rgba(0, 0, 0, 0.3);
}

.vibe-video-card:hover .vibe-video-thumb::after {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.vibe-video-thumb:hover::after {
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.vibe-video-badges {
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    z-index: 2;
    pointer-events: none;
}

.vibe-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    color: #fff;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.vibe-badge-campo {
    background: rgba(26, 86, 219, 0.85);
}

.vibe-badge-category {
    background: rgba(220, 38, 38, 0.85);
}

.vibe-video-info {
    padding: 12px;
    display: grid;
    grid-template-rows: auto auto auto;
    gap: 12px;
}

.vibe-video-title {
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
    font-weight: 600;
}

.vibe-video-title a {
    color: var(--card-text);
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-align: left;
}

.vibe-video-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--card-meta);
}

.vibe-video-owner {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 12px;
}

.vibe-video-owner img {
    width: 42px;
    height: 42px;
    border-radius: 8px;
    object-fit: cover;
    background: #f3f4f6;
    border: 2px solid #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s ease;
}

.vibe-video-owner:hover img {
    transform: scale(1.05);
}

.vibe-video-owner a {
    color: var(--card-text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.vibe-video-owner a:hover {
    color: #2563eb;
}

.vibe-video-stats {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 8px;
}

.vibe-video-stat {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #666;
    font-size: 13px;
    font-weight: 500;
}

.vibe-video-stat i {
    font-size: 14px;
}

/* List Layout Specific */
.vibe-video-card.list-layout {
    grid-template-columns: 200px 1fr;
    grid-template-rows: 1fr;
    height: 140px;
}

.vibe-video-card.list-layout .vibe-video-thumb {
    width: 100%;
    height: 100%;
    position: relative;
    border-radius: 0px !important;
}

.vibe-video-card.list-layout .vibe-video-info {
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 8px;
    padding: 12px;
}

.vibe-video-card.list-layout .vibe-video-owner {
    border: none;
    padding: 0;
}

.vibe-video-card.list-layout .vibe-video-stats {
    padding: 0;
}

.vibe-video-card.list-layout .vibe-video-title {
    font-size: 14px;
    line-height: 1.3;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vibe-video-card.list-layout .vibe-video-owner {
    margin-top: auto;
}

.vibe-video-card.list-layout .vibe-video-owner img {
    width: 28px;
    height: 28px;
}

/* Grid Layout Specific */
.video-grid .vibe-video-badges {
    top: 8px;
    left: 8px;
    right: 8px;
}

/* Swiper Styles */
.video-swiper-container {
    position: relative;
    padding: 0 25px;
    margin: 0 -25px;
}

.video-swiper {
    position: relative;
    width: 100%;
    height: auto;
    overflow: hidden;
}

.video-swiper .swiper-wrapper {
    display: flex;
    width: 100%;
    height: auto;
    box-sizing: border-box;
    align-items: stretch;
}

.video-swiper .swiper-slide {
    height: auto;
    flex-shrink: 0;
    width: calc(100% / var(--slides-per-view, 3));
    position: relative;
    padding: 8px;
    box-sizing: border-box;
}

.video-swiper .vibe-video-card {
    height: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    background: var(--card-bg);
    border-radius: var(--card-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.video-swiper .vibe-video-thumb {
    position: relative;
    padding-top: 56.25%;
    width: 100%;
    background: #f0f0f0;
    flex-shrink: 0;
    overflow: hidden;
}

.video-swiper .vibe-video-badges {
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    z-index: 2;
}

.video-swiper .vibe-video-thumb img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-swiper .vibe-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 12px;
    z-index: 2;
}

.video-swiper .swiper-button-prev,
.video-swiper .swiper-button-next {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    color: var(--card-text);
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: calc(36%);
    transform: translateY(-50%);
    z-index: 10;
    cursor: pointer;
    transition: all 0.2s ease;
}

.video-swiper .swiper-button-prev {
    left: 0;
}

.video-swiper .swiper-button-next {
    right: 0;
}

.video-swiper .swiper-button-prev:after,
.video-swiper .swiper-button-next:after {
    font-size: 14px;
    font-weight: bold;
    color: #333;
}

.video-swiper .swiper-button-prev:hover,
.video-swiper .swiper-button-next:hover {
    background: rgba(255, 255, 255, 1);
    transform: translateY(-50%) scale(1.1);
}

.video-swiper .swiper-pagination {
    position: relative;
    bottom: auto;
    left: auto;
    right: auto;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 15px;
    width: 100%;
}

.video-swiper .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    margin: 0;
    border-radius: 50%;
    background: var(--card-meta);
    opacity: 0.5;
    cursor: pointer;
    transition: all 0.2s ease;
}

.video-swiper .swiper-pagination-bullet-active {
    opacity: 1;
    background: var(--card-text);
    transform: scale(1.2);
}

/* Like Button Styles */
.vibe-like-button {
    position: relative;
}

.vibe-like-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 1px solid #dee2e6;
    border-radius: 50px;
    padding: 6px 12px;
    font-size: 13px;
    font-weight: 500;
    color: #495057;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    position: relative;
    overflow: hidden;
}

.vibe-like-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.6), transparent);
    transition: left 0.6s;
}

.vibe-like-btn:hover::before {
    left: 100%;
}

.vibe-like-btn:hover {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    border-color: #0056b3;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

.vibe-like-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0, 123, 255, 0.2);
}

/* Liked state */
.vibe-like-btn.liked {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border-color: #28a745;
    color: white;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.3);
}

.vibe-like-btn.liked:hover {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    border-color: #dc3545;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.vibe-like-btn.liked i {
    animation: likeHeartbeat 0.6s ease;
}

@keyframes likeHeartbeat {
    0% { transform: scale(1); }
    30% { transform: scale(1.3); }
    60% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Like count styling */
.vibe-like-btn .like-count {
    font-weight: 600;
    font-size: 12px;
    min-width: 16px;
    text-align: center;
}

/* Icon styling */
.vibe-like-btn i {
    font-size: 14px;
    transition: transform 0.2s ease;
}

.vibe-like-btn:hover i {
    transform: scale(1.1);
}

/* Views stat styling */
.vibe-video-stat:not(.vibe-like-button) {
    background: rgba(0, 0, 0, 0.05);
    padding: 4px 8px;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.vibe-video-stat:not(.vibe-like-button):hover {
    background: rgba(0, 0, 0, 0.1);
}

.vibe-video-stat i.fa-eye {
    color: #6c757d;
}

/* Loading state */
.vibe-like-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}

.vibe-like-btn:disabled::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Trending Badge */
.gc-trend-hot {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
    background: rgba(0,0,0,0.7);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.gc-trending-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    width: 100%;
    height: 100%;
}

.gc-trending-badge i {
    font-size: 14px;
    color: #fff;
    line-height: 1;
}

.gc-trending-badge span {
    font-size: 12px;
    color: #fff;
    font-weight: bold;
    line-height: 1;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.gc-trend-hot[data-position="1"] {
    background: linear-gradient(135deg, #ffd700 0%, #ffa500 100%);
}

.gc-trend-hot[data-position="2"] {
    background: linear-gradient(135deg, #c0c0c0 0%, #a9a9a9 100%);
}

.gc-trend-hot[data-position="3"] {
    background: linear-gradient(135deg, #cd7f32 0%, #b87333 100%);
}

/* Responsive Styles */
@media (max-width: 1200px) {
    .video-grid {
        grid-template-columns: repeat(var(--columns-tablet, 2), minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .video-grid {
        grid-template-columns: repeat(var(--columns-mobile, 1), minmax(0, 1fr));
        gap: 20px;
    }

    .vibe-video-card.list-layout {
        grid-template-columns: 155px 1fr;
        height: 100px;
    }

    .vibe-video-card.list-layout .vibe-video-info {
        padding: 8px;
    }

    .gc-trend-hot {
        width: 32px;
        height: 32px;
        top: 8px;
        right: 8px;
    }

    .gc-trending-badge i {
        font-size: 12px;
    }

    .gc-trending-badge span {
        font-size: 11px;
    }

    .vibe-video-thumb::after {
        width: 44px;
        height: 44px;
        font-size: 18px;
    }

    .vibe-video-owner img {
        width: 28px;
        height: 28px;
    }

    .vibe-video-owner a {
        font-size: 12px;
    }

    .vibe-video-stats {
        gap: 10px;
    }
    
    .vibe-like-btn {
        padding: 5px 10px;
        font-size: 12px;
    }
    
    .vibe-like-btn i {
        font-size: 13px;
    }
    
    .vibe-like-btn .like-count {
        font-size: 11px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .video-grid .vibe-video-card {
        transition: none;
        opacity: 1;
        transform: none;
    }

    .vibe-video-thumb::after {
        transition: none;
    }
} 