Files
YouTube-Revived/css/video.css
NanamiAdmin f6a861977c feat(video-page): add video player page with details and comments
Add new video player page with responsive layout, video details display, and comments section. Includes video player, channel info, like/dislike buttons, and interactive elements. Also add null checks in main script to prevent errors when elements are missing.
2026-02-11 21:46:48 +08:00

386 lines
6.0 KiB
CSS

.video-content-wrapper {
flex: 1;
display: flex;
flex-direction: column;
overflow-y: auto;
padding: 24px;
background-color: #121212;
}
.video-player {
width: 70%;
aspect-ratio: 16 / 9;
margin-bottom: 20px;
border-radius: 20px;
position: static;
border: 1px solid #000000;
overflow: hidden;
box-shadow: 0 2px 8px rgb(48, 48, 48);
padding: 1px;
background-color: #000000;
box-sizing: border-box;
}
.video-player video {
width: 100%;
height: 100%;
border-radius: 20px;
}
.video-info-container {
margin-left: 30px;
margin-right: 30px;
margin-bottom: 20px;
}
.video-title {
font-size: 20px;
font-weight: 600;
margin: 0 0 12px 0;
line-height: 1.4;
}
.video-channel-info {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 12px;
}
.channel-left {
display: flex;
align-items: center;
gap: 12px;
}
.channel-avatar {
width: 40px;
height: 40px;
border-radius: 50%;
background-color: #606060;
display: flex;
align-items: center;
justify-content: center;
overflow: hidden;
}
.channel-avatar img {
width: 100%;
height: 100%;
object-fit: cover;
}
.channel-avatar i {
font-size: 20px;
color: #ffffff;
}
.channel-details {
display: flex;
flex-direction: column;
}
.channel-name {
font-size: 16px;
font-weight: 600;
color: #ffffff;
}
.channel-subscribers {
font-size: 12px;
color: #aaaaaa;
}
.subscribe-btn {
background-color: #cc0000;
color: #ffffff;
border: none;
padding: 10px 16px;
border-radius: 18px;
font-size: 14px;
font-weight: 500;
cursor: pointer;
transition: background-color 0.2s;
}
.subscribe-btn:hover {
background-color: #ff0000;
}
.subscribe-btn.subscribed {
background-color: #272727;
color: #aaaaaa;
}
.subscribe-btn.subscribed:hover {
background-color: #3d3d3d;
}
.video-actions {
display: flex;
align-items: center;
gap: 8px;
margin-bottom: 12px;
}
.like-dislike-buttons {
display: flex;
background-color: #272727;
border-radius: 18px;
overflow: hidden;
}
.action-btn {
background-color: #272727;
color: #ffffff;
border: none;
padding: 8px 16px;
border-radius: 18px;
font-size: 14px;
font-weight: 500;
cursor: pointer;
display: flex;
align-items: center;
gap: 6px;
transition: background-color 0.2s;
}
.action-btn:hover {
background-color: #3d3d3d;
}
.like-btn {
border-radius: 18px 0 0 18px;
padding-right: 12px;
}
.dislike-btn {
border-radius: 0 18px 18px 0;
padding-left: 12px;
}
.like-btn i,
.dislike-btn i {
font-size: 16px;
}
.more-options {
position: relative;
}
.more-dropdown {
position: absolute;
top: 100%;
right: 0;
background-color: #272727;
border-radius: 12px;
padding: 8px 0;
min-width: 180px;
display: none;
z-index: 1000;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}
.more-dropdown.show {
display: block;
}
.more-item {
display: flex;
align-items: center;
gap: 12px;
padding: 10px 16px;
cursor: pointer;
color: #ffffff;
font-size: 14px;
}
.more-item:hover {
background-color: #3d3d3d;
}
.more-item i {
font-size: 16px;
color: #aaaaaa;
}
.video-stats {
display: flex;
gap: 12px;
font-size: 14px;
color: #aaaaaa;
margin-bottom: 12px;
}
.video-description {
background-color: #272727;
border-radius: 12px;
padding: 12px;
position: relative;
}
.description-toggle {
position: absolute;
top: 12px;
right: 12px;
width: 24px;
height: 24px;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
color: #ffffff;
}
.description-toggle:hover {
background-color: #3d3d3d;
border-radius: 50%;
}
.video-description p {
margin: 0;
font-size: 14px;
color: #ffffff;
line-height: 1.6;
max-height: 60px;
overflow: hidden;
display: -webkit-box;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
}
.video-description p.expanded {
max-height: none;
display: block;
}
.comments-section {
margin-left: 30px;
margin-right: 30px;
margin-bottom: 40px;
}
.comments-header {
font-size: 16px;
font-weight: 600;
color: #ffffff;
margin: 0 0 20px 0;
}
.add-comment {
display: flex;
gap: 12px;
margin-bottom: 24px;
}
.comment-avatar {
width: 40px;
height: 40px;
border-radius: 50%;
background-color: #606060;
display: flex;
align-items: center;
justify-content: center;
overflow: hidden;
flex-shrink: 0;
}
.comment-avatar img {
width: 100%;
height: 100%;
object-fit: cover;
}
.comment-avatar i {
font-size: 20px;
color: #ffffff;
}
.comment-input-container {
flex: 1;
}
.comment-input {
width: 100%;
background-color: transparent;
border: none;
border-bottom: 1px solid #303030;
color: #ffffff;
font-size: 14px;
padding: 8px 0;
outline: none;
}
.comment-input::placeholder {
color: #aaaaaa;
}
.comment-input:focus {
border-bottom-color: #ffffff;
}
.comments-list {
display: flex;
flex-direction: column;
gap: 20px;
}
.comment-item {
display: flex;
gap: 12px;
}
.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: #ffffff;
}
.comment-time {
font-size: 12px;
color: #aaaaaa;
}
.comment-text {
font-size: 14px;
color: #ffffff;
margin: 0 0 8px 0;
line-height: 1.5;
}
.comment-actions {
display: flex;
gap: 8px;
}
.comment-action-btn {
background: none;
border: none;
color: #aaaaaa;
cursor: pointer;
padding: 4px;
display: flex;
align-items: center;
gap: 4px;
font-size: 12px;
}
.comment-action-btn:hover {
color: #ffffff;
}
.comment-action-btn i {
font-size: 16px;
}