* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', sans-serif;
}

body {
    background-color: #0b0f19;
    color: #f8fafc;
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden; /* পুরো পেজের স্ক্রোল বন্ধ করার জন্য */
}

header {
    background: linear-gradient(135deg, #111827 0%, #0f1419 100%);
    padding: 18px 4%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #1f2937;
    height: 70px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    gap: 20px;
}

.logo-area { 
    display: flex; 
    align-items: center; 
    gap: 12px;
    transition: all 0.3s ease;
}

.header-logo {
    height: 70px;
    width: auto;
    object-fit: contain;
}

.logo-area h1 {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 1px;
}

.logo-area h1 span { 
    color: #f43f5e;
    text-shadow: 0 0 10px rgba(244, 63, 94, 0.5);
}

.live-icon { 
    color: #f43f5e; 
    font-size: 28px;
    filter: drop-shadow(0 0 6px rgba(244, 63, 94, 0.6));
}

.search-box { 
    position: relative; 
    width: 280px;
    transition: all 0.3s ease;
}

.search-box input {
    width: 100%;
    padding: 12px 18px 12px 45px;
    background-color: #1f2937;
    border: 2px solid #374151;
    border-radius: 50px;
    color: #fff;
    outline: none;
    transition: all 0.3s ease;
    font-size: 14px;
}

.search-box input::placeholder {
    color: #9ca3af;
}

.search-box input:focus { 
    border-color: #f43f5e;
    background-color: #2d3748;
    box-shadow: 0 0 12px rgba(244, 63, 94, 0.3);
}

.search-box i { 
    position: absolute; 
    left: 18px; 
    top: 50%; 
    transform: translateY(-50%); 
    color: #9ca3af;
    transition: color 0.3s ease;
    font-size: 16px;
}

.search-box input:focus ~ i {
    color: #f43f5e;
}

/* Login Navigation Button */
.login-nav-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: linear-gradient(135deg, #f43f5e 0%, #ec4899 100%);
    border: none;
    border-radius: 50px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(244, 63, 94, 0.3);
    white-space: nowrap;
}

.login-nav-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(244, 63, 94, 0.4);
}

.login-nav-btn:active {
    transform: translateY(0);
}

.login-nav-btn i {
    font-size: 16px;
}

.login-nav-btn.hidden {
    display: none;
}

/* User Profile */
.user-profile {
    position: relative;
    display: none;
}

.user-profile.visible {
    display: block;
}

.user-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f43f5e 0%, #ec4899 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(244, 63, 94, 0.3);
    overflow: hidden;
}

.user-avatar:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(244, 63, 94, 0.4);
}

.user-avatar i {
    font-size: 18px;
    color: #fff;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: 280px;
    background: linear-gradient(145deg, #111827 0%, #0f1419 100%);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(244, 63, 94, 0.1);
    border: 1px solid #1f2937;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 100;
}

.user-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-avatar-large {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f43f5e 0%, #ec4899 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

.user-avatar-large i {
    font-size: 22px;
    color: #fff;
}

.user-avatar-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow: hidden;
}

.user-name {
    font-size: 15px;
    font-weight: 600;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-email {
    font-size: 13px;
    color: #9ca3af;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dropdown-divider {
    height: 1px;
    background: #1f2937;
    margin: 15px 0;
}

.dropdown-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: transparent;
    border: none;
    border-radius: 10px;
    color: #d1d5db;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dropdown-item:hover {
    background: rgba(244, 63, 94, 0.1);
    color: #f43f5e;
}

.dropdown-item i {
    font-size: 16px;
    width: 20px;
    text-align: center;
}

@media (max-width: 768px) {
    .login-nav-btn span {
        display: none;
    }
    
    .login-nav-btn {
        padding: 10px;
        border-radius: 50%;
    }
    
    .user-dropdown {
        width: 260px;
        right: -10px;
    }
}

/* Main Dynamic Layout */
.main-layout {
    display: grid;
    grid-template-columns: 3fr 1.1fr;
    gap: 25px;
    padding: 20px 4%;
    flex: 1;
    height: calc(100vh - 70px);
    overflow: hidden;
}

/* Player Section */
.player-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
    justify-content: center;
    height: 100%;
}

.player-container-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
    width: 100%;
}

.player-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    background-color: #000;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(244, 63, 94, 0.1), 0 10px 30px rgba(0,0,0,0.8);
    border: 1px solid #1f2937;
    transition: all 0.3s ease;
}

.player-wrapper:hover {
    box-shadow: 0 25px 60px rgba(244, 63, 94, 0.15), 0 15px 40px rgba(0,0,0,0.8);
}

.player-blocker {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;
    background: transparent;
    cursor: default;
}

/* Player Controls Overlay */
.player-controls-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.player-wrapper:hover .player-controls-overlay,
.player-wrapper:active .player-controls-overlay {
    opacity: 1;
}

.control-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    pointer-events: auto;
    transition: all 0.25s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.control-btn:hover {
    background: rgba(244, 63, 94, 0.8);
    border-color: rgba(244, 63, 94, 0.9);
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(244, 63, 94, 0.4);
}

.control-btn:active {
    transform: scale(0.95);
}

/* Volume buttons specific */
.volume-down, .volume-up {
    width: 44px;
    height: 44px;
    font-size: 16px;
}

/* Rotate button - mobile only */
.rotate-btn {
    display: none;
}

/* Fullscreen state */
.player-wrapper.is-fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    border-radius: 0;
    aspect-ratio: auto;
}

/* Rotated state for mobile */
.player-wrapper.is-rotated {
    transform: rotate(90deg);
    transform-origin: center center;
    width: 100vh;
    height: 100vw;
    position: fixed;
    top: 50%;
    left: 50%;
    margin-top: -50vw;
    margin-left: -50vh;
    z-index: 9999;
    border-radius: 0;
}

/* Mobile specific styles */
@media (max-width: 768px) {
    .control-btn {
        width: 42px;
        height: 42px;
        font-size: 15px;
    }
    
    .volume-down, .volume-up {
        width: 38px;
        height: 38px;
        font-size: 14px;
    }
    
    .rotate-btn {
        display: flex;
    }
    
    .player-controls-overlay {
        gap: 15px;
    }
}

/* Hide rotate button on desktop */
@media (min-width: 769px) {
    .rotate-btn {
        display: none !important;
    }
}

/* VideoJS & Iframe Fluid Layout */
.video-js, #iframe-player {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    border: none;
    display: none;
}

.video-js.vjs-has-started {
    display: block !important;
}

.now-playing {
    font-size: 18px;
    color: #e5e7eb;
    padding-left: 60px;
    font-weight: 500;
    letter-spacing: 0.4px;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.now-playing i {
    color: #f43f5e;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Navigation Buttons Styling */
.nav-btn {
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    color: white;
    border: 2px solid #374151;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
    pointer-events: auto;
    z-index: 10;
}

.nav-btn:hover {
    background: linear-gradient(135deg, #f43f5e 0%, #ec4899 100%);
    border-color: #f43f5e;
    transform: scale(1.08) translateY(-2px);
    box-shadow: 0 8px 20px rgba(244, 63, 94, 0.4);
}

/* Sidebar Section */
.sidebar-section {
    background: linear-gradient(180deg, #111827 0%, #0f1419 100%);
    border-radius: 16px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    border: 1px solid #1f2937;
    height: 100%;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.list-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #f1f5f9;
    letter-spacing: 0.5px;
}

/* Playlist Tabs */
.playlist-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.playlist-tab {
    padding: 10px 18px;
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    border: 2px solid #374151;
    color: #d1d5db;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.playlist-tab:hover {
    border-color: #f43f5e;
    color: #fff;
    transform: translateY(-2px);
}

.playlist-tab.active {
    background: linear-gradient(135deg, #f43f5e 0%, #ec4899 100%);
    border-color: #f43f5e;
    color: #fff;
    box-shadow: 0 6px 15px rgba(244, 63, 94, 0.3);
}

.live-dot {
    width: 10px;
    height: 10px;
    background-color: #10b981;
    border-radius: 50%;
    animation: blink 1.5s infinite;
    box-shadow: 0 0 6px rgba(16, 185, 129, 0.6);
}

@keyframes blink {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 1; }
}

.channel-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
    overflow-y: auto;
    flex: 1;
    padding-right: 8px;
}

.channel-list::-webkit-scrollbar { 
    width: 8px; 
}

.channel-list::-webkit-scrollbar-track {
    background: rgba(31, 41, 55, 0.5);
    border-radius: 10px;
}

.channel-list::-webkit-scrollbar-thumb { 
    background: linear-gradient(180deg, #f43f5e 0%, #ec4899 100%);
    border-radius: 10px;
    transition: background 0.3s ease;
}

.channel-list::-webkit-scrollbar-thumb:hover {
    background: #f43f5e;
}

/* Channel Item */
.channel-item {
    display: flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    padding: 14px 16px;
    border-radius: 12px;
    cursor: pointer;
    border: 1px solid #374151;
    transition: all 0.3s ease;
    position: relative;
}

.channel-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background-color: transparent;
    border-radius: 12px 0 0 12px;
    transition: background-color 0.3s ease;
}

.channel-item:hover, .channel-item.active {
    border-color: #f43f5e;
    background: linear-gradient(135deg, #1f3a3a 0%, #1a1f2e 100%);
    box-shadow: 0 8px 20px rgba(244, 63, 94, 0.15);
    transform: translateX(4px);
}

.channel-item.active::before {
    background-color: #f43f5e;
}

.channel-item:hover .img-box {
    border-color: #f43f5e;
    box-shadow: 0 0 12px rgba(244, 63, 94, 0.3);
}

.img-box {
    min-width: 60px;
    max-width: 60px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 2px solid #374151;
    padding: 4px;
    transition: all 0.3s ease;
}
.img-box img { 
    width: 100%; 
    height: 100%; 
    object-fit: contain; 
    padding: 2px;
    background-color: #0b0f19;
    border-radius: 8px;
}

.channel-item h4 { 
    font-size: 15px; 
    font-weight: 600; 
    flex: 1; 
    color: #f3f4f6;
    letter-spacing: 0.3px;
    transition: color 0.3s ease;
}

.channel-item:hover h4, .channel-item.active h4 {
    color: #fff;
}

.play-now-icon { 
    color: #9ca3af; 
    font-size: 16px;
    transition: all 0.3s ease;
}

.channel-item:hover .play-now-icon, .channel-item.active .play-now-icon { 
    color: #f43f5e;
    transform: scale(1.2);
}

.loading { 
    text-align: center; 
    color: #9ca3af; 
    margin-top: 50px;
    font-size: 15px;
    font-weight: 500;
}

.loading i {
    color: #f43f5e;
    margin-right: 8px;
}

/* Responsive */
@media (max-width: 1024px) {
    body { overflow-y: auto; height: auto; }
    .main-layout { grid-template-columns: 1fr; height: auto; overflow: visible; padding: 10px; }
    .player-container-wrapper { gap: 5px; }
    .nav-btn { width: 35px; height: 35px; font-size: 14px; }
    .now-playing { padding-left: 40px; }
    .sidebar-section { height: 450px; }
}
