/* Media Modal základní styly */
.media-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.media-modal-content {
    background: rgba(20, 20, 20, 0.95);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateY(-30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Video modal - větší */
.video-modal .media-modal-content {
    width: 80%;
    max-width: 900px;
}

/* Audio modal - standardní velikost */
.audio-modal .media-modal-content.standard-size {
    width: 600px;
    max-width: 90%;
}

/* Modal header */
.media-modal-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.media-modal-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 300;
}

.media-close-button {
    background: #ff0000;
    border: none;
    color: #fff;
    font-size: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.media-close-button:hover {
    transform: scale(1.1);
}

/* Modal body */
.media-modal-body {
    padding: 20px;
}

/* Video player styly */
#videoPlayer {
    width: 100%;
    border-radius: 10px;
    background: #000;
}

/* Audio player styly */
.equalizer-container {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

#equalizerCanvas {
    display: block;
}

.audio-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.audio-control-button {
    background: #ff8800;
    border: none;
    color: #fff;
    font-size: 24px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.audio-control-button:hover {
    transform: scale(1.1);
}

.audio-progress {
    flex: 1;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
}

.audio-progress-bar {
    height: 100%;
    width: 0%;
    background: #ff8800;
    transition: width 0.1s ease;
    border-radius: 4px;
}

/* Fade overlay pro zelený efekt */
.fade-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    opacity: 0;
    z-index: 9999;
    transition: opacity 2s ease-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Duchový obličej */
.ghost-face {
    width: 500px;
    height: 600px;
    position: relative;
    animation: ghostAppear 0.5s ease-out, ghostFloat 3s ease-in-out infinite;
}

@keyframes ghostAppear {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes ghostFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

.ghost-face svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 30px rgba(255, 255, 255, 0.8));
}

/* Responzivní design */
@media (max-width: 768px) {
    .video-modal .media-modal-content {
        width: 95%;
    }
    
    .audio-modal .media-modal-content.standard-size {
        width: 95%;
    }
    
    .media-modal-header {
        padding: 15px;
    }
    
    .media-modal-body {
        padding: 15px;
    }
}

/* Vylepšení pro menší displeje */
@media (max-width: 480px) {
    .media-modal-header h2 {
        font-size: 20px;
    }
    
    .media-close-button {
        width: 35px;
        height: 35px;
        font-size: 18px;
    }
    
    .audio-control-button {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
}
