/* Base Styles & Custom Variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Roboto, Arial, sans-serif;
}

body {
    background-color: #0c0c0e;
    color: #fff;
    padding-bottom: 50px;
}

/* Header UI */
.stream-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 4%;
    background-color: #121214;
    border-bottom: 1px solid #1f1f23;
}

.back-btn {
    color: #aaa;
    text-decoration: none;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.2s;
}

.back-btn:hover {
    color: #fff;
}

.logo {
    font-size: 22px;
    font-weight: bold;
    color: #e50914;
}

/* Page Layout Grid */
.stream-container {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
    max-width: 1600px;
    margin: 30px auto 0 auto;
    padding: 0 4%;
}

/* Video Player Styles */
.player-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    background-color: #000;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.player-container video {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Custom Video Player Controls Overlay */
.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.95), transparent);
    padding: 20px 15px 10px 15px;
    opacity: 0.8; /* Would typically switch dynamically with JavaScript on hover */
    transition: opacity 0.3s;
}

.progress-bar-container {
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
    margin-bottom: 15px;
    cursor: pointer;
    position: relative;
}

.progress-bar {
    width: 35%; /* Mock progress width */
    height: 100%;
    background-color: #e50914;
    border-radius: 2px;
}

.controls-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.controls-left, .controls-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.controls-buttons button {
    background: none;
    border: none;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    transition: color 0.2s, transform 0.1s;
}

.controls-buttons button:hover {
    color: #e50914;
    transform: scale(1.1);
}

.volume-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.volume-slider {
    width: 70px;
    accent-color: #e50914;
    cursor: pointer;
}

.time-display {
    font-size: 13px;
    color: #ccc;
}

/* Movie Details Section */
.movie-details {
    margin-top: 25px;
    border-bottom: 1px solid #1f1f23;
    padding-bottom: 25px;
}

.title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.title-row h1 {
    font-size: 32px;
    font-weight: 700;
}

.action-buttons {
    display: flex;
    gap: 12px;
}

.action-btn {
    background-color: #1f1f23;
    border: none;
    color: #eee;
    padding: 10px 18px;
    border-radius: 20px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.2s;
}

.action-btn:hover {
    background-color: #2f2f36;
    color: #fff;
}

.meta-tags {
    margin: 15px 0;
    display: flex;
    gap: 10px;
}

.tag {
    font-size: 12px;
    padding: 3px 8px;
    background-color: #1a1a1e;
    border-radius: 4px;
    color: #aaa;
}

.tag.rating {
    background-color: rgba(245, 197, 24, 0.15);
    color: #f5c518;
    font-weight: bold;
}

.synopsis-box {
    font-size: 15px;
    line-height: 1.6;
    color: #ccc;
}

.credits {
    margin-top: 15px;
    font-size: 14px;
    color: #999;
}
.credits strong { color: #eee; }

/* Discussion / Comments Section */
.comments-section {
    margin-top: 30px;
}

.comments-section h3 {
    margin-bottom: 20px;
    font-size: 18px;
}

.comment-input-block {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.user-avatar, .comment-avatar {
    width: 40px;
    height: 40px;
    background-color: #333;
    border-radius: 50%;
    background-size: cover;
    flex-shrink: 0;
}

.user-avatar {
    background-image: url('https://images.unsplash.com/photo-1535713875002-d1d0cf377fde?w=100');
}

.input-wrapper {
    display: flex;
    flex-grow: 1;
    gap: 10px;
}

.input-wrapper input {
    flex-grow: 1;
    background-color: #121214;
    border: 1px solid #27272a;
    border-radius: 6px;
    padding: 0 15px;
    color: #fff;
    font-size: 14px;
}

.input-wrapper input:focus {
    outline: 1px solid #e50914;
}

.comment-submit {
    background-color: #e50914;
    color: #fff;
    border: none;
    padding: 0 20px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
}

.comment-item {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.comment-content h4 {
    font-size: 14px;
    margin-bottom: 5px;
}

.comment-content h4 span {
    font-size: 11px;
    color: #666;
    margin-left: 8px;
    font-weight: normal;
}

.comment-content p {
    font-size: 14px;
    color: #bbb;
    line-out: 1.4;
}

/* Sidebar Up Next Recommendations */
.sidebar-recommendations h2 {
    font-size: 18px;
    margin-bottom: 20px;
}

.rec-card {
    display: flex;
    gap: 12px;
    margin-bottom: 18px;
    cursor: pointer;
    background-color: #121214;
    padding: 8px;
    border-radius: 6px;
    transition: transform 0.2s, background-color 0.2s;
}

.rec-card:hover {
    transform: translateX(4px);
    background-color: #1a1a1e;
}

.rec-thumbnail {
    position: relative;
    width: 120px;
    aspect-ratio: 16/9;
    border-radius: 4px;
    overflow: hidden;
    flex-shrink: 0;
}

.rec-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.duration {
    position: absolute;
    bottom: 4px;
    right: 4px;
    background-color: rgba(0,0,0,0.8);
    font-size: 10px;
    padding: 2px 4px;
    border-radius: 2px;
}

.rec-info h3 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.rec-info p {
    font-size: 12px;
    color: #888;
    margin-bottom: 4px;
}

.rec-match {
    font-size: 11px;
    color: #46d369; /* Green streaming score indicator */
    font-weight: bold;
}

/* Responsive Breakdown */
@media (max-width: 1024px) {
    .stream-container {
        grid-template-columns: 1fr; /* Sidebar drops below player on tablets/phones */
    }
}