/* ============================================
   TALENT TOOLS VIDEOS - YOUTUBE STYLE DESIGN
   ============================================ */

/* Corporate Colors:
   - Primary Blue: #042D62
   - Hover Blue: #003853
   - Gold Accent: #FFD700
   - Light Background: #f9f9f9
   - Card Background: #ffffff
*/

/* ============================================
   PAGE TITLE SECTION
   ============================================ */
.page-title-section {
    text-align: center;
    margin-bottom: 2.5rem;
}

.page-main-title {
    font-size: 2.5rem;
    font-weight: 900;
    color: #042D62;
    margin-bottom: 0.5rem;
    text-align: center;
}

.page-subtitle {
    font-size: 1.1rem;
    color: #606060;
    font-weight: 500;
    margin-bottom: 0;
    text-align: center;
}

@media (max-width: 768px) {
    .page-main-title {
        font-size: 2rem;
    }

    .page-subtitle {
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .page-main-title {
        font-size: 1.6rem;
    }

    .page-subtitle {
        font-size: 0.95rem;
    }
}

/* ============================================
   SEARCH BAR SECTION
   ============================================ */
.search-bar-youtube {
    max-width: 700px;
    margin: 0 auto 2rem auto;
}

.search-bar-youtube .input-group {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-radius: 25px;
    overflow: hidden;
    background: white;
}

.search-bar-youtube input.form-control {
    border: 2px solid #042D62;
    border-right: none;
    padding: 14px 24px;
    font-size: 1.05rem;
    border-radius: 25px 0 0 25px;
}

.search-bar-youtube input.form-control:focus {
    border-color: #042D62;
    box-shadow: none;
    outline: none;
}

.search-bar-youtube .btn {
    background-color: #042D62;
    border: 2px solid #042D62;
    color: white;
    padding: 14px 30px;
    font-weight: 600;
    border-radius: 0 25px 25px 0;
    transition: all 0.3s ease;
}

.search-bar-youtube .btn:hover {
    background-color: #003853;
    border-color: #003853;
    transform: scale(1.02);
}

/* ============================================
   CATEGORY CHIPS/PILLS
   ============================================ */
.category-chips-container {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    margin-bottom: 3rem;
    padding: 0 20px;
}

.category-chip {
    background-color: #ffffff;
    color: #042D62;
    font-size: 1rem;
    font-weight: 600;
    border: 2px solid #042D62;
    border-radius: 25px;
    padding: 10px 24px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    display: inline-block;
}

.category-chip:hover {
    background-color: #042D62;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(4, 45, 98, 0.2);
}

.category-chip.active {
    background-color: #042D62;
    color: white;
    box-shadow: 0 4px 12px rgba(4, 45, 98, 0.3);
}

/* ============================================
   VIDEO GRID LAYOUT (YouTube-style)
   ============================================ */
.video-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-bottom: 3rem;
}

/* Responsive Grid */
@media (max-width: 1400px) {
    .video-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .video-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}

@media (max-width: 576px) {
    .video-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
}

/* ============================================
   VIDEO CARDS
   ============================================ */
.video-card-youtube {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: block;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.video-card-youtube:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    text-decoration: none;
}

/* ============================================
   VIDEO THUMBNAIL CONTAINER
   ============================================ */
.video-thumbnail-container {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    /* 16:9 Aspect Ratio */
    background-color: #000;
    overflow: hidden;
}

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

/* Play Overlay */
.play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background-color: rgba(4, 45, 98, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.video-card-youtube:hover .play-overlay {
    opacity: 1;
}

.play-overlay i {
    color: white;
    font-size: 24px;
    margin-left: 4px;
    /* Visual centering */
}

/* Category Badge on Thumbnail */
.video-thumbnail-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: rgba(0, 0, 0, 0.75);
    color: white;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 600;
    z-index: 2;
}

/* Duration Badge (opcional) */
.video-duration-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background-color: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* ============================================
   VIDEO INFO SECTION
   ============================================ */
.video-info {
    padding: 16px;
}

.video-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.8em;
}

.video-metadata {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.video-date {
    font-size: 0.9rem;
    color: #606060;
}

.video-category-badge {
    background-color: #042D62;
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* ============================================
   PAGINATION
   ============================================ */
.pagination-youtube {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 3rem;
    flex-wrap: wrap;
}

.pagination-youtube .page-link {
    background-color: white;
    color: #042D62;
    border: 2px solid #042D62;
    border-radius: 8px;
    padding: 10px 16px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.pagination-youtube .page-link:hover {
    background-color: #042D62;
    color: white;
    transform: scale(1.05);
}

.pagination-youtube .page-item.active .page-link {
    background-color: #042D62;
    color: white;
    border-color: #042D62;
}

.pagination-youtube .page-item.disabled .page-link {
    background-color: #f0f0f0;
    color: #999;
    border-color: #ddd;
}

/* ============================================
   SEARCH RESULTS INFO
   ============================================ */
.search-results-info {
    text-align: center;
    margin-bottom: 2rem;
    padding: 16px;
    background-color: #f9f9f9;
    border-radius: 12px;
    border-left: 4px solid #FFD700;
}

.search-results-info strong {
    color: #042D62;
}

.search-results-info a {
    color: #042D62;
    font-weight: 600;
    text-decoration: underline;
}

.search-results-info a:hover {
    color: #003853;
}

/* ============================================
   EMPTY STATE
   ============================================ */
.empty-state {
    text-align: center;
    padding: 80px 20px;
}

.empty-state i {
    font-size: 80px;
    color: #042D62;
    margin-bottom: 20px;
}

.empty-state h3 {
    color: #042D62;
    margin-bottom: 10px;
}

.empty-state p {
    color: #606060;
    font-size: 1.1rem;
}

/* ============================================
   HOVER VIDEO PREVIEW (Opcional)
   ============================================ */
.video-hover-preview {
    position: relative;
}

.video-hover-preview video {
    transition: transform 0.3s ease;
}

.video-card-youtube:hover .video-hover-preview video {
    transform: scale(1.05);
}

/* ============================================
   LOADING SKELETON (Opcional)
   ============================================ */
.video-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* ============================================
   MOBILE OPTIMIZATIONS
   ============================================ */
@media (max-width: 576px) {
    .search-bar-youtube {
        margin-bottom: 1.5rem;
    }

    .search-bar-youtube input.form-control {
        padding: 12px 18px;
        font-size: 1rem;
    }

    .search-bar-youtube .btn {
        padding: 12px 20px;
    }

    .category-chips-container {
        gap: 8px;
        margin-bottom: 2rem;
    }

    .category-chip {
        font-size: 0.9rem;
        padding: 8px 18px;
    }

    .video-title {
        font-size: 1rem;
    }

    .video-info {
        padding: 12px;
    }
}

/* ============================================
   VIDEO PLAYER PAGE (SHOW.BLADE.PHP)
   ============================================ */

/* Video Player Card */
.video-player-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

/* Video Player Container */
.video-player-container {
    position: relative;
    width: 100%;
    background-color: #000;
}

.video-player {
    width: 100%;
    height: auto;
    display: block;
    max-height: 70vh;
}

/* Video Player Info Section */
.video-player-info {
    padding: 24px;
}

.video-player-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
    line-height: 1.3;
}

/* Video Metadata */
.video-player-metadata {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e0e0e0;
}

.metadata-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.badge-category {
    background-color: #042D62;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.95rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.video-date-info {
    color: #606060;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Description Box */
.video-description-box {
    background-color: #f9f9f9;
    border-radius: 12px;
    padding: 20px;
    border-left: 4px solid #042D62;
}

.description-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #042D62;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.description-content {
    color: #333;
    font-size: 1rem;
    line-height: 1.6;
}

/* ============================================
   RELATED VIDEOS SIDEBAR
   ============================================ */

.related-videos-section {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 20px;
}

.related-videos-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #042D62;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #042D62;
    display: flex;
    align-items: center;
    gap: 8px;
}

.related-videos-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Related Video Item */
.related-video-item {
    display: flex;
    gap: 12px;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
    border-radius: 8px;
    padding: 8px;
}

.related-video-item:hover {
    background-color: #f9f9f9;
    transform: translateX(4px);
}

/* Related Video Thumbnail */
.related-video-thumbnail {
    position: relative;
    width: 168px;
    min-width: 168px;
    height: 94px;
    border-radius: 8px;
    overflow: hidden;
    background-color: #000;
}

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

/* Related Play Overlay */
.related-play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background-color: rgba(4, 45, 98, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.related-video-item:hover .related-play-overlay {
    opacity: 1;
}

.related-play-overlay i {
    color: white;
    font-size: 18px;
    margin-left: 2px;
}

/* Related Category Badge */
.related-category-badge {
    position: absolute;
    top: 6px;
    left: 6px;
    background-color: rgba(0, 0, 0, 0.75);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
}

/* Related Video Info */
.related-video-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.related-video-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 6px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.related-video-date {
    font-size: 0.85rem;
    color: #606060;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Breadcrumb Styling */
.breadcrumb {
    background-color: transparent;
    padding: 0;
    margin-bottom: 1rem;
}

.breadcrumb-item a {
    color: #042D62;
    font-weight: 600;
    transition: color 0.3s ease;
}

.breadcrumb-item a:hover {
    color: #003853;
}

.breadcrumb-item.active {
    color: #606060;
}

/* Button Styling */
.btn-outline-primary {
    color: #042D62;
    border-color: #042D62;
    font-weight: 600;
}

.btn-outline-primary:hover {
    background-color: #042D62;
    border-color: #042D62;
    color: white;
}

/* ============================================
   RESPONSIVE - VIDEO PLAYER PAGE
   ============================================ */

@media (max-width: 991px) {
    .related-videos-section {
        position: static;
        margin-top: 2rem;
    }

    .video-player-title {
        font-size: 1.3rem;
    }
}

@media (max-width: 768px) {
    .video-player-info {
        padding: 16px;
    }

    .video-player-title {
        font-size: 1.2rem;
    }

    .related-video-thumbnail {
        width: 140px;
        min-width: 140px;
        height: 79px;
    }

    .related-video-title {
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .video-player {
        max-height: 50vh;
    }

    .video-player-title {
        font-size: 1.1rem;
    }

    .video-player-metadata {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .metadata-left {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .related-video-item {
        flex-direction: column;
    }

    .related-video-thumbnail {
        width: 100%;
        height: auto;
        padding-top: 56.25%;
        /* 16:9 */
        position: relative;
    }

    .related-video-thumbnail img,
    .related-video-thumbnail video {
        position: absolute;
        top: 0;
        left: 0;
    }

    .video-description-box {
        padding: 16px;
    }
}