/* Video Player Styles - YouTube-like Design */


/* Video Player Container */

.video-player-container {
    padding: 24px 24px 0;
    background: #f8f9fa;
}

.video-player-wrapper {
    position: relative;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 12px;
}

.video-player {
    width: 100%;
    display: block;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    background: #000;
}


/* Video Controls */

.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
    padding: 20px 12px 8px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 10;
}

.video-player-wrapper:hover .video-controls,
.video-controls.show {
    opacity: 1;
}

.progress-bar-container {
    margin-bottom: 8px;
    cursor: pointer;
}

.progress-bar {
    position: relative;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    transition: height 0.2s;
}

.progress-bar-container:hover .progress-bar {
    height: 6px;
}

.progress-filled {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    background: #1a4d2e;
    border-radius: 2px;
    width: 0%;
    transition: width 0.1s linear;
}

.progress-handle {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 14px;
    height: 14px;
    background: #1a4d2e;
    border-radius: 50%;
    left: 0%;
    opacity: 0;
    transition: opacity 0.2s;
}

.progress-bar-container:hover .progress-handle {
    opacity: 1;
}

.controls-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.controls-left,
.controls-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.control-btn {
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 8px;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
    border-radius: 4px;
}

.control-btn:hover {
    transform: scale(1.1);
}

.play-btn {
    font-size: 20px;
}

.volume-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.volume-slider-container {
    width: 0;
    overflow: hidden;
    transition: width 0.3s ease;
}

.volume-container:hover .volume-slider-container {
    width: 80px;
}

.volume-slider {
    width: 80px;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    outline: none;
    border-radius: 2px;
    cursor: pointer;
    -webkit-appearance: none;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    background: #fff;
    border-radius: 50%;
    cursor: pointer;
}

.volume-slider::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: #fff;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

.time-display {
    color: #fff;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 4px;
}


/* Settings Menu */

.settings-menu,
.settings-submenu {
    position: absolute;
    bottom: 60px;
    right: 12px;
    background: rgba(28, 28, 28, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 8px;
    padding: 8px 0;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s ease;
    z-index: 100;
}

.settings-menu.show,
.settings-submenu.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.settings-item,
.submenu-item {
    padding: 10px 16px;
    color: #fff;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    transition: background 0.2s;
}

.settings-item:hover,
.submenu-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

.submenu-item.active {
    background: rgba(26, 77, 46, 0.3);
}

.settings-value {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.7);
}

.submenu-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 4px;
    color: #fff;
    font-weight: 600;
}

.back-btn {
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
}


/* Video Info Section */

.video-info-section {
    padding: 16px 0 12px;
}

.video-title {
    font-size: 20px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 8px;
    line-height: 1.3;
}

.video-stats {
    font-size: 14px;
    color: #606060;
    margin-bottom: 16px;
}

.video-actions-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e5e5e5;
    flex-wrap: wrap;
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: #f2f2f2;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    transition: all 0.2s;
}

.action-btn:hover {
    background: #e0e0e0;
}

.action-btn i {
    font-size: 16px;
}


/* Channel Info Section */

.channel-info-section {
    padding: 16px 0;
    border-bottom: 1px solid #e5e5e5;
}

.channel-details {
    display: flex;
    align-items: center;
    gap: 16px;
}

.channel-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.channel-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.channel-text {
    flex: 1;
}

.channel-name {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 2px;
}

.channel-subs {
    font-size: 13px;
    color: #606060;
    margin: 0;
}

.subscribe-btn {
    padding: 10px 24px;
    background: #064f8f;
    color: #fff;
    border: none;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.subscribe-btn:hover {
    background: #eca621;
}


/* Video Description Section */

.video-description-section {
    padding: 16px 0;
}

.description-toggle {
    background: #f2f2f2;
    border: none;
    width: 100%;
    padding: 12px 16px;
    border-radius: 8px;
    cursor: pointer;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: background 0.2s;
}

.description-toggle:hover {
    background: #e0e0e0;
}

.description-preview {
    font-size: 14px;
    color: #1a1a1a;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.toggle-text {
    font-size: 13px;
    font-weight: 600;
    color: #606060;
}

.description-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding: 0 16px;
}

.description-content.expanded {
    max-height: 2000px;
    padding: 16px;
    background: #f2f2f2;
    border-radius: 8px;
    margin-top: 12px;
}

.description-content p {
    font-size: 14px;
    line-height: 1.6;
    color: #1a1a1a;
    margin-bottom: 12px;
}

.description-content h4 {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 16px 0 8px;
}

.description-content ul {
    margin-left: 20px;
    margin-bottom: 12px;
}

.description-content li {
    font-size: 14px;
    line-height: 1.6;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.description-tags {
    color: #065fd4;
    font-size: 13px;
}


/* Comments Section */

.comments-section {
    padding: 24px 0;
}

.comments-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.comments-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
}

.sort-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #606060;
    padding: 8px;
}

.add-comment {
    display: flex;
    gap: 16px;
    margin-bottom: 32px;
}

.add-comment input {
    flex: 1;
    border: none;
    border-bottom: 1px solid #e5e5e5;
    padding: 8px 0;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
    background: transparent;
}

.add-comment input:focus {
    border-bottom-color: #1a4d2e;
}

.comment {
    display: flex;
    gap: 16px;
    margin-bottom: 24px;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.comment-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.comment-content {
    flex: 1;
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.comment-author {
    font-size: 13px;
    font-weight: 600;
    color: #1a1a1a;
}

.comment-time {
    font-size: 12px;
    color: #606060;
}

.comment-text {
    font-size: 14px;
    line-height: 1.6;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.comment-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.comment-action-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 13px;
    color: #606060;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.2s;
}

.comment-action-btn:hover {
    background: #f2f2f2;
}


/* Suggested Videos Section */

.suggested-videos-section {
    padding-left: 24px;
}

.suggested-videos-header {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e5e5e5;
}

.suggested-videos-header .nav-tab {
    padding: 6px 12px;
    font-size: 13px;
    height: auto;
}

.suggested-video-item {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s;
    padding: 8px;
    border-radius: 8px;
}

.suggested-video-item:hover {
    background: #f2f2f2;
}

.suggested-thumbnail {
    position: relative;
    width: 168px;
    height: 94px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    background: #f2f2f2;
}

.suggested-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.suggested-duration {
    position: absolute;
    bottom: 4px;
    right: 4px;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.suggested-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.suggested-title {
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 4px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.suggested-channel,
.suggested-meta {
    font-size: 12px;
    color: #606060;
    margin: 0;
    line-height: 1.4;
}


/* Header Logo on Watch Page */

.header-logo a {
    font-size: 20px;
    font-weight: 700;
    color: #1a4d2e;
    text-decoration: none;
    letter-spacing: 2px;
}


/* Sidebar Collapsed State - Match home page styling */

.sidebar.collapsed {
    width: 72px;
}

.sidebar.collapsed .sidebar-logo {
    opacity: 0;
    width: 0;
    margin: 0;
}

.sidebar.collapsed .sidebar-section-title {
    opacity: 0;
    height: 0;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.sidebar.collapsed .sidebar-menu span {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

.sidebar.collapsed .sidebar-divider {
    opacity: 0;
    height: 0;
    margin: 8px 0;
}

.sidebar.collapsed .sidebar-header {
    padding: 18px 14px;
    justify-content: center;
}

.sidebar.collapsed .sidebar-menu {
    padding: 0 4px;
}

.sidebar.collapsed .sidebar-menu a {
    justify-content: center;
    padding: 0;
    width: 64px;
    margin: 0 auto 4px;
}

.sidebar.collapsed .sidebar-menu a.active::before {
    display: none;
}

.sidebar.collapsed .sidebar-menu i {
    margin-right: 0;
    font-size: 22px;
}

.sidebar.collapsed+.main-content {
    margin-left: 72px;
}


/* Responsive Styles */

@media (max-width: 1024px) {
    .video-player-container {
        padding: 16px 16px 0;
    }
    .suggested-videos-section {
        padding-left: 0;
        margin-top: 24px;
    }
    .suggested-video-item {
        padding: 4px;
    }
}

@media (max-width: 768px) {
    .video-player-container {
        padding: 0;
    }
    .video-player-wrapper {
        border-radius: 0;
    }
    .video-title {
        font-size: 16px;
    }
    .action-btn {
        padding: 6px 12px;
        font-size: 13px;
    }
    .channel-details {
        gap: 12px;
    }
    .channel-avatar {
        width: 40px;
        height: 40px;
    }
    .channel-name {
        font-size: 14px;
    }
    .subscribe-btn {
        padding: 8px 16px;
        font-size: 13px;
    }
    .suggested-videos-section {
        padding: 0 16px;
    }
    .suggested-thumbnail {
        width: 140px;
        height: 79px;
    }
    .suggested-title {
        font-size: 13px;
    }
    .control-btn {
        font-size: 16px;
        padding: 6px;
    }
    .time-display {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .video-actions-bar {
        gap: 4px;
    }
    .action-btn {
        padding: 6px 10px;
        font-size: 12px;
    }
    .action-btn span {
        display: none;
    }
    .action-btn i {
        margin: 0;
    }
    .comment {
        gap: 12px;
    }
    .comment-avatar {
        width: 32px;
        height: 32px;
    }
    .suggested-video-item {
        flex-direction: column;
        gap: 8px;
    }
    .suggested-thumbnail {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }
    .volume-container:hover .volume-slider-container {
        width: 0;
    }
    .volume-slider-container {
        display: none;
    }
}