/* Single Multimedia Light Theme (Revised) */

.cn-single-media-light {
    background-color: #f8f9fa;
    padding-bottom: 60px;
    font-family: 'Vazirmatn', sans-serif;
    color: #333;
}

.cn-single-media-light .cn-breadcrumb {
    padding: 20px 0;
    font-size: 13px;
    color: #666;
}

.cn-single-media-light .cn-breadcrumb a {
    color: #666;
    text-decoration: none;
}

.cn-single-media-light .cn-breadcrumb a:hover {
    color: #0B192C;
}

.cn-active-crumb {
    color: #333;
    font-weight: 700;
}

/* Layout Grid */
.cn-media-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 30px;
    align-items: start;
}

/* Main Content Column */
.cn-media-main-col {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    overflow: hidden;
}

/* Player Box */
.cn-media-player-box {
    width: 100%;
    background: #000;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Iframes (Aparat / Youtube) */
.cn-media-player-box iframe {
    width: 100% !important;
    aspect-ratio: 16 / 9;
    display: block;
    border: none;
}

/* WordPress Native Video Player (.wp-video) */
.cn-media-player-box .wp-video {
    width: 100% !important;
    height: auto !important;
    margin: 0 !important;
}

.cn-media-player-box .wp-video .mejs-container {
    width: 100% !important;
    height: auto !important;
    padding-top: 56.25%; /* Force 16:9 Aspect Ratio */
    position: relative;
}

.cn-media-player-box .wp-video .mejs-container video,
.cn-media-player-box .wp-video .mejs-container iframe,
.cn-media-player-box .wp-video .mejs-container .mejs-mediaelement {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    object-fit: contain; /* Prevents portrait videos from stretching */
}

/* Mock Player */
.cn-mock-player {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}
.cn-mock-player::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.2);
}
.cn-play-btn-real {
    position: relative;
    z-index: 2;
    color: rgba(255, 255, 255, 0.9);
    font-size: 80px;
    cursor: pointer;
    transition: transform 0.2s, color 0.2s;
    filter: drop-shadow(0 4px 10px rgba(0,0,0,0.5));
}
.cn-play-btn-real:hover {
    transform: scale(1.1);
    color: #fff;
}

/* Description Box */
.cn-media-desc-box {
    padding: 30px;
}

.cn-media-meta-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    font-size: 14px;
    color: #666;
    margin-bottom: 20px;
}

.cn-meta-cat {
    color: #D32F2F;
    font-weight: 700;
}

.cn-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}
.cn-meta-item i {
    font-size: 16px;
    color: #888;
}

.cn-box-heading-large {
    font-size: 26px;
    font-weight: 800;
    color: #0B192C;
    margin: 0 0 25px 0;
    line-height: 1.5;
}

.cn-box-heading {
    font-size: 18px;
    font-weight: 800;
    color: #0B192C;
    margin: 0 0 15px 0;
}

.cn-mt-4 { margin-top: 30px; }

.cn-desc-content {
    font-size: 16px;
    line-height: 1.8;
    color: #555;
    text-align: justify;
}

.cn-desc-content img,
.cn-desc-content iframe,
.cn-desc-content video {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 20px 0;
}

.cn-desc-content iframe {
    aspect-ratio: 16/9;
}

/* Tags Pills */
.cn-tags-pill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.cn-tag-pill {
    background: #f0f2f5;
    color: #555;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px;
    text-decoration: none;
    transition: background 0.2s;
}

.cn-tag-pill:hover {
    background: #e4e6e9;
    color: #0B192C;
}

/* Sidebar Boxes */
.cn-media-sidebar-col {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.cn-sidebar-box {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    overflow: hidden;
}

.cn-sb-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.cn-sb-title {
    font-size: 16px;
    font-weight: 800;
    color: #0B192C;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Playlist Items */
.cn-playlist-items {
    max-height: 500px;
    overflow-y: auto;
}

.cn-pl-item {
    display: flex;
    gap: 12px;
    padding: 15px 20px;
    border-bottom: 1px solid #f5f5f5;
    text-decoration: none;
    transition: background 0.2s;
}

.cn-pl-item:hover {
    background: #f9f9f9;
}

.cn-pl-item.active {
    background: #f0f4f8;
}

.cn-pl-img {
    width: 100px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

.cn-pl-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cn-pl-playing {
    position: absolute;
    inset: 0;
    background: rgba(211, 47, 47, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 24px;
}

.cn-pl-info {
    flex: 1;
}

.cn-pl-title {
    font-size: 13px;
    color: #333;
    font-weight: 700;
    line-height: 1.4;
    margin: 0;
}

/* Responsive */
@media (max-width: 992px) {
    .cn-media-layout { grid-template-columns: 1fr; }
}
