/* Contenedor principal del stream y chat */
.mec-stream-container {
    display: flex;
    flex-wrap: wrap;
    /* En pantallas pequeñas se apilarán */
    width: 100%;
    background: #000;
    border-radius: 25px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    margin-bottom: 30px;
    font-family: Arial, sans-serif;
}

/* Sección de video */
.mec-stream-video {
    flex: 1 1 100%;
    width: 100%;
    position: relative;
    background: #111;
    /* Dark background so we know the container exists */
    border-radius: 25px;
    overflow: hidden;
    height: 0;
    padding-top: 56.25%;
    /* 16:9 Ratio */
    display: block !important;
    visibility: visible !important;
}



/* Base adjustment for desktop when not in column mode */
@media (min-width: 901px) {
    .mec-stream-video {
        flex: 1 1 500px;
        height: auto;
        padding-top: 0;
        aspect-ratio: 16 / 9;
    }
}

/* Si no hay chat, el video ocupa todo el espacio */
.mec-stream-no-chat .mec-stream-video {
    flex: 1 1 100%;
}

.mec-stream-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 25px;
    border: none;
    z-index: 10;
}

/* Sección del chat */
.mec-stream-chat {
    flex: 0 0 340px;
    /* Ancho fijo clásico de los chats de streaming */
    min-height: 400px;
    /* Evita que el chat quede aplastado en alturas raras */
    background: #191b1f;
    /* Color oscuro típico de chats en Kick/Twitch */
}

.mec-stream-chat iframe {
    width: 100%;
    height: 100%;
    display: block;
    border: none;
}

/* Responsividad: móviles y tablets en vertical */
@media (max-width: 900px) {
    .mec-stream-container {
        flex-direction: column;
    }

    .mec-stream-video {
        flex: 1 1 100%;
        width: 100%;
        height: 0;
        padding-top: 56.25%;
        /* Ensure 16:9 on mobile */
    }

    .mec-stream-chat {
        flex: 1 1 100%;
        width: 100%;
        height: 500px;
        /* En móviles el chat va debajo y necesita una altura fija */
    }
}

/*==================================================
  Offline State - Premium Design
==================================================*/
.mec-stream-offline {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 450px;
    /* Modern dark gradient background */
    background: linear-gradient(135deg, #0f1011 0%, #1a1c20 100%);
    text-align: center;
    border-radius: 25px;
    position: relative;
    overflow: hidden;
}

/* Subtle glowing background effect */
.mec-stream-offline::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(83, 252, 24, 0.05) 0%, rgba(0, 0, 0, 0) 60%);
    pointer-events: none;
}

.mec-stream-offline-content {
    background: rgba(25, 27, 31, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 40px 50px;
    border-radius: 25px;
    border: 1px solid rgba(83, 252, 24, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    z-index: 1;
    transform: translateY(0);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.mec-stream-offline-content:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(83, 252, 24, 0.15);
}

.mec-stream-offline-content h3 {
    color: #ffffff;
    margin: 0 0 15px 0;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.mec-stream-offline-content p {
    color: #a1a1aa;
    margin: 0 0 35px 0;
    font-size: 16px;
    line-height: 1.5;
}

.mec-stream-btn-follow {
    background: #53fc18;
    /* Kick Primary Green */
    color: #000000;
    padding: 14px 36px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 800;
    font-size: 16px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(83, 252, 24, 0.3);
}

.mec-stream-btn-follow:hover {
    background: #46db15;
    color: #000000;
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(83, 252, 24, 0.5);
}

/* Optional Pulse Animation on button */
@keyframes kickPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(83, 252, 24, 0.7);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(83, 252, 24, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(83, 252, 24, 0);
    }
}

.mec-stream-btn-follow {
    animation: kickPulse 2s infinite;
}