.iptv-hive-container {
    background: #1a1a1a;
    color: #fff;
    min-height: 100vh;
    padding: 20px;
}

.player-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.player-header h5 {color:#6528f7;}

.add-playlist-btn {
    background: #6528f7;
    color: #FFFFFF;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
}

.add-playlist-btn:hover {
    background: #722d80;
}

.main-content {
    display: flex;
    gap: 20px;
    height: 80vh;
}

.playlist-sidebar {
    width: 300px;
    background: #2d2d2d;
    border-radius: 8px;
    padding: 15px;
}

.video-container {
    flex: 1;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
}

#iptvPlayer {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.channel-list {
    margin-top: 15px;
    height: calc(100% - 60px);
    overflow-y: auto;
}

.channel-item {
    padding: 12px;
    margin: 8px 0;
    background: #3d3d3d;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.2s;
}

.channel-item:hover {
    background: #6528f7;
}

.playlist-form-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 1000;
}

.modal-content {
    position: relative;
    background: #2d2d2d;
    margin: 10% auto;
    padding: 25px;
    width: 400px;
    border-radius: 8px;
    animation: modalSlide 0.3s ease-out;
}

@keyframes modalSlide {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.modal-content form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.modal-content input {
    padding: 12px;
    background: #3d3d3d;
    border: 1px solid #4d4d4d;
    border-radius: 5px;
    color: #fff;
}

.modal-content button {
    background: #6528f7;
    color: #2d2d2d;
    border: none;
    padding: 12px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
}




/* Add error display styling */
.error-message {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #ff4444;
    color: white;
    padding: 15px;
    border-radius: 5px;
    z-index: 1000;
    max-width: 400px;
    word-break: break-word;
}



/* Loading overlay */
#loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 9999; /* Higher than modal */
    backdrop-filter: blur(5px);
}

.loading-spinner {
    border: 4px solid rgba(101, 40, 247, 0.2);
    border-top: 4px solid #6528f7;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

.loading-text {
    color: #6528f7;
    font-size: 1.2em;
    font-weight: bold;
    text-shadow: 0 0 10px rgba(101, 40, 247, 0.5);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Error message styling */
.error-message {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #ff4444;
    color: white;
    padding: 15px 25px;
    border-radius: 5px;
    z-index: 1001;
    max-width: 300px;
}


/* Video Player Enhancements */
#iptvPlayer {
    width: 100%;
    height: 100%;
    background: #000;
    transition: opacity 0.3s;
}

#iptvPlayer::-webkit-media-controls {
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
}

/* Channel List Scrollbar */
.channel-list::-webkit-scrollbar {
    width: 8px;
}

.channel-list::-webkit-scrollbar-track {
    background: #2d2d2d;
}

.channel-list::-webkit-scrollbar-thumb {
    background: #6528f7;
    border-radius: 4px;
}