/*
 * Corrected and Improved Styles for MercyOTT Video List
 * Version: 1.5.1
 * - MODIFIED: Added horizontal padding to the video grid on mobile devices.
 */

/* Import Poppins font from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;700&display=swap');

/* ... (most styles are unchanged) ... */
.mv-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 20px;
    align-items: stretch;
}
.mv-horizontal-wrapper {
    position: relative;
    margin: 0;
}
.mv-horizontal {
    display: flex;
    overflow-x: auto;
    gap: 15px;
    padding: 10px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}
.mv-horizontal::-webkit-scrollbar { display: none; }
.mv-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background-color: rgba(255, 255, 255, 0.5) !important;
    background-image: none !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    width: 44px;
    height: 44px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    transition: background-color 0.2s ease, opacity 0.2s ease;
    opacity: 0;
}
.mv-horizontal-wrapper:hover .mv-arrow {
    opacity: 1;
}
.mv-arrow:hover {
    background-color: rgba(0, 0, 0, 0.8) !important;
}
.mv-arrow svg {
    width: 24px;
    height: 24px;
    stroke: white !important;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.7));
}
.mv-arrow-prev { left: 15px; }
.mv-arrow-next { right: 15px; }
.mv-item {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    height: 100%;
}
.mv-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.09);
}
.mv-horizontal .mv-item {
    flex: 0 0 200px;
    width: 200px;
}
.mv-thumb {
    cursor: pointer;
    width: 100%;
    position: relative;
    background-color: #f0f0f0;
}
.mv-thumb::before,
.mv-thumb::after {
    display: none !important;
    content: "" !important;
    background: none !important;
    background-image: none !important;
    border: none !important;
    box-shadow: none !important;
}
.mv-thumb img {
    width: 100%;
    height: auto;
    display: block;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}
.mv-info {
    padding: 10px 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.mv-grid .mv-title, .mv-horizontal .mv-title,
.mv-grid .mv-meta, .mv-horizontal .mv-meta {
    color: #333 !important;
}
.mv-grid .mv-title,
.mv-horizontal .mv-title {
    font-family: 'Poppins', sans-serif;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.45;
    text-transform: none;
    min-height: 37.7px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    white-space: normal;
}
.mv-meta {
    font-family: 'Poppins', sans-serif;
    font-size: 13px;
    margin-top: 0;
    padding-top: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- MODIFIED --- Responsive Layout */
@media (max-width: 768px) {
    .mv-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 15px;
        /* MODIFIED: Added 15px padding on the left and right */
        padding: 0 15px;
    }
    .mv-arrow {
        opacity: 1;
        width: 36px;
        height: 36px;
    }
    .mv-arrow svg {
        width: 20px;
        height: 20px;
    }
    .mv-horizontal-wrapper { margin: 0; }
    .mv-arrow-prev { left: 5px; }
    .mv-arrow-next { right: 5px; }
    .mv-horizontal { padding: 10px 5px; }
}
@media (max-width: 480px) {
    .mv-grid { 
        grid-template-columns: 1fr !important; 
        /* The padding from the 768px rule above will apply here too */
    }
    .mv-horizontal .mv-item { flex-basis: 160px; }
    .mv-grid .mv-title,
    .mv-horizontal .mv-title {
        font-size: 12px;
        min-height: 34.8px;
    }
}

/* Modal Styles */
.mv-modal {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 99999;
    display: none;
    padding: 15px;
    box-sizing: border-box;
}
.mv-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90vw;
    max-width: 800px;
    background: #000;
}
.mv-player-container {
    width: 100%;
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
}
#clappr-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
#mv-close {
    position: absolute;
    top: -40px; right: -5px;
    color: #fff;
    background: transparent;
    border: 0;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    padding: 5px;
    line-height: 1;
}
#mv-close:hover { color: #ccc; }