﻿/*=============================================
    course-page.css - استایل مدرن برای صفحه دوره
    بر اساس قالب AppCo و منطبق با کد HTML داده شده
===============================================*/

/* ===== BASE STYLES (فقط لازم برای این صفحه) ===== */
.course-page {
    margin-top: 100px;
    margin-bottom: 50px;
    font-family: 'Open Sans', sans-serif;
    color: #707070;
}

.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 15px;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    color: #2c3e50;
}

a {
    text-decoration: none !important;
    transition: all 0.3s ease;
}

/* ===== PRE DEFINE CLASSES ===== */
.box-shadow {
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

    .box-shadow:hover {
        box-shadow: 0 15px 40px rgba(0,0,0,0.12);
    }

/* ===== HEADER دوره ===== */
.course-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    padding: 25px 35px;
    border-radius: 20px;
    margin-bottom: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

    .course-page-header h1 {
        font-size: 1.8rem;
        font-weight: 700;
        color: #2c3e50;
        margin-bottom: 10px;
    }

        .course-page-header h1 a {
            color: inherit;
        }

/* ===== BREADCRUMB ===== */
.breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
}

    .breadcrumb ul {
        display: flex;
        flex-wrap: wrap;
        list-style: none;
        padding: 0;
        margin: 0;
        gap: 8px;
    }

    .breadcrumb li {
        color: #95a5a6;
        font-size: 0.9rem;
    }

        .breadcrumb li a {
            color: #6730e3;
        }

        .breadcrumb li:not(:last-child)::after {
            content: '/';
            margin-right: 8px;
            color: #95a5a6;
        }

        .breadcrumb li.current span {
            color: #2c3e50;
            font-weight: 500;
        }

/* ===== لینک کوتاه ===== */
.course-shortlink {
    background: #f4f7fa;
    padding: 12px 25px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 15px;
}

    .course-shortlink .title {
        font-weight: 600;
        color: #2c3e50;
    }

    .course-shortlink .link {
        color: #6730e3;
        font-family: monospace;
        font-size: 1rem;
    }

.copy-btn {
    color: #6730e3;
    font-size: 1.2rem;
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0 5px;
}

    .copy-btn:hover {
        color: #9629e6;
        transform: scale(1.1);
    }

/* ===== بنر تخفیف ===== */
.short-description {
    background: #fff;
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 30px;
}

.center-banner img {
    width: 100%;
    border-radius: 15px;
}

/* ===== اطلاعات دوره (باکس جزئیات) ===== */
.course-details-layer {
    background: #fff;
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 30px;
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    align-items: center;
}

.course-price {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2c3e50;
    background: #f8f9fa;
    padding: 10px 25px;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.price-amount {
    color: #27ae60;
    background: rgba(39,174,96,0.1);
    padding: 5px 20px;
    border-radius: 30px;
    font-weight: 700;
}

.course-details-layer ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    margin: 0;
    padding: 0;
}

.course-details-layer li {
    color: #34495e;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
}

    .course-details-layer li i {
        color: #6730e3;
        font-size: 1.1rem;
    }

.blue-lbl {
    background: #6730e3;
    color: #fff;
    padding: 3px 15px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* ===== چیدمان اصلی و سایدبار ===== */
.main-content {
    width: calc(100% - 380px);
    float: right;
}

.sidebar-content {
    width: 350px;
    float: left;
    margin-right: 30px;
}

.clearfix::after {
    content: "";
    display: table;
    clear: both;
}

@media (max-width: 992px) {
    .main-content, .sidebar-content {
        width: 100%;
        float: none;
        margin: 0;
    }
}

/* ===== محتوای دوره (تصویر و توضیحات) ===== */
.course-content-layer {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
}

.img-layer img {
    width: 100%;
    border-radius: 20px;
    margin-bottom: 25px;
}

.course-content-text h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 20px;
}

.course-content-text h4 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: #34495e;
}

    .course-content-text h4 a {
        color: #6730e3;
        text-decoration: underline;
    }

.course-content-text p {
    font-size: 1.1rem;
    line-height: 1.9;
    color: #555;
    margin-bottom: 20px;
}

.course-info-btn-display-more {
    display: inline-block;
    background: #f4f7fa;
    padding: 8px 20px;
    border-radius: 30px;
    cursor: pointer;
    color: #6730e3;
    font-weight: 600;
}

.btnScrollToComments {
    background: #6730e3;
    color: #fff;
    border: none;
    padding: 12px 35px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    border: 2px solid #6730e3;
    transition: all 0.3s ease;
}

    .btnScrollToComments:hover {
        background: transparent;
        color: #6730e3;
    }

/* ===== لیست ویدیوها ===== */
.video-list-layer {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
}

.heading {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    border-bottom: 2px solid #f4f7fa;
    padding-bottom: 15px;
}

    .heading .bullet {
        width: 45px;
        height: 45px;
        background: #6730e3;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #fff;
        font-size: 1.2rem;
    }

    .heading h3 {
        margin: 0;
        font-size: 1.6rem;
        font-weight: 700;
    }

.course-time {
    margin-right: auto;
    background: #f4f7fa;
    padding: 8px 25px;
    border-radius: 50px;
    font-weight: 600;
    color: #2c3e50;
}

/* ===== پلیر ویدیو ===== */
.video-player-layer {
    margin-bottom: 25px;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.video-js {
    width: 100%;
    height: auto;
    aspect-ratio: 16/9;
    border-radius: 20px;
}

/* ===== آیتم‌های ویدیو ===== */
.video-items-layer {
    max-height: 600px;
    overflow-y: auto;
    padding-left: 5px;
}

    .video-items-layer::-webkit-scrollbar {
        width: 6px;
    }

    .video-items-layer::-webkit-scrollbar-track {
        background: #f4f7fa;
        border-radius: 10px;
    }

    .video-items-layer::-webkit-scrollbar-thumb {
        background: #6730e3;
        border-radius: 10px;
    }

.video-item {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #ecf0f1;
    transition: all 0.3s ease;
    cursor: pointer;
    border-radius: 10px;
    position: relative;
}

    .video-item:hover {
        background: #f8f9fa;
        transform: translateX(-5px);
        box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    }

    .video-item.alert-info {
        background: #e3f2fd;
        border: none;
        color: #0c5460;
    }

.video-num {
    width: 45px;
    height: 45px;
    background: #6730e3;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 20px;
    font-weight: 700;
    flex-shrink: 0;
}

.video-item ul {
    margin: 0;
    padding: 0;
    list-style: none;
    flex: 1;
}

.video-item h2 {
    font-size: 1.1rem;
    margin: 0;
    color: #2c3e50;
    font-weight: 600;
}

.course-time-left {
    margin-right: auto;
    background: #e9ecef;
    padding: 6px 20px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #555;
    flex-shrink: 0;
}

.video-description-layer {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    z-index: 10;
    width: 100%;
}

.video-item:hover .video-description-layer {
    display: block;
}

/* ===== بخش نظرات ===== */
.comments-layer {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
}

    .comments-layer .heading {
        border-bottom: 2px solid #f4f7fa;
        padding-bottom: 15px;
    }

    .comments-layer .alert {
        border-radius: 15px;
        padding: 15px 20px;
        margin-bottom: 25px;
    }

.alert-success {
    background-color: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

.alert-info {
    background-color: #d1ecf1;
    border-color: #bee5eb;
    color: #0c5460;
}

.comments-list-layer {
    margin-top: 25px;
}

.comment-item {
    display: flex;
    gap: 25px;
    padding: 25px;
    border-bottom: 1px solid #f4f7fa;
}

    .comment-item:last-child {
        border-bottom: none;
    }

.right-col img {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #f4f7fa;
}

.left-col {
    flex: 1;
}

    .left-col .heading {
        display: flex;
        justify-content: space-between;
        align-items: center;
        border: none;
        padding: 0;
        margin-bottom: 10px;
    }

        .left-col .heading h4 {
            font-size: 1.2rem;
            font-weight: 700;
            color: #2c3e50;
            margin: 0;
        }

        .left-col .heading span {
            color: #95a5a6;
            font-size: 0.9rem;
        }

.cm-text p {
    margin-bottom: 5px;
    line-height: 1.7;
    color: #555;
}

.btn-primary {
    background: #6730e3;
    border: none;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    color: #fff;
    cursor: pointer;
    border: 2px solid #6730e3;
    transition: all 0.3s ease;
}

    .btn-primary:hover {
        background: transparent;
        color: #6730e3;
    }

/* ===== سایدبار ===== */
.course-sidebar-banner {
    margin-bottom: 25px;
}

    .course-sidebar-banner img {
        width: 100%;
        border-radius: 20px;
        box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    }

/* ===== امتیازدهی ===== */
.ratings-layer {
    background: #fff;
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 30px;
}

.flex-with-border {
    border-bottom: 2px solid #f4f7fa;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

    .flex-with-border h3 {
        font-size: 1.3rem;
        margin: 0;
    }

.rating-items {
    margin-bottom: 15px;
}

.rating-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px 0;
    border-bottom: 1px dashed #ecf0f1;
}

    .rating-item:last-child {
        border: none;
    }

    .rating-item p {
        margin: 0;
        font-size: 0.95rem;
        color: #555;
        flex: 1;
    }

.rating-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.rating-holder {
    direction: ltr;
}

.c-rating button {
    background: none;
    border: none;
    color: #f1c40f;
    font-size: 1.2rem;
    cursor: default;
    padding: 0 2px;
}

.rate-style {
    font-weight: 700;
    color: #6730e3;
    background: rgba(103,48,227,0.1);
    padding: 5px 15px;
    border-radius: 30px;
    font-size: 0.95rem;
}

hr {
    border-top: 1px solid #ecf0f1;
    margin: 20px 0;
}

/* ===== اشتراک گذاری ===== */
.share-socials {
    background: #fff;
    border-radius: 20px;
    padding: 20px 25px;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

    .share-socials span {
        font-weight: 600;
        color: #2c3e50;
    }

    .share-socials a {
        width: 45px;
        height: 45px;
        background: #f4f7fa;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #6730e3;
        font-size: 1.2rem;
        transition: all 0.3s ease;
    }

        .share-socials a:hover {
            background: #6730e3;
            color: #fff;
            transform: translateY(-3px);
        }

/* ===== برچسب‌ها ===== */
.tags-layer {
    background: #fff;
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 30px;
}

    .tags-layer span {
        display: block;
        margin-bottom: 15px;
        font-weight: 600;
        color: #2c3e50;
    }

    .tags-layer a {
        display: inline-block;
        background: #f4f7fa;
        color: #555;
        padding: 6px 18px;
        border-radius: 30px;
        margin: 5px;
        font-size: 0.9rem;
        transition: all 0.3s ease;
    }

        .tags-layer a:hover {
            background: #6730e3;
            color: #fff;
        }

/* ===== دکمه پرسش سوال ===== */
.ask-question-button {
    display: block;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 15px 25px;
    border-radius: 50px;
    text-align: center;
    font-weight: 600;
    margin-bottom: 25px;
    transition: all 0.3s ease;
    border: none;
}

    .ask-question-button:hover {
        transform: translateY(-3px);
        box-shadow: 0 10px 30px rgba(102,126,234,0.4);
        color: #fff;
    }

/* ===== لینک‌های مفید ===== */
.section-aside {
    background: #fff;
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 30px;
}

    .section-aside .heading {
        border-bottom: 2px solid #f4f7fa;
        padding-bottom: 15px;
        margin-bottom: 20px;
        font-weight: 700;
        color: #2c3e50;
    }

.links-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.links-list li {
    margin-bottom: 12px;
}

.links-list a {
    color: #555;
    display: block;
    padding: 8px 0;
    border-bottom: 1px dashed #ecf0f1;
}

    .links-list a:hover {
        color: #6730e3;
        padding-right: 5px;
    }

/* ===== ریسپانسیو ===== */
@media (max-width: 768px) {
    .course-page-header {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }

        .course-page-header h1 {
            font-size: 1.4rem;
        }

    .breadcrumb ul {
        justify-content: center;
    }

    .course-details-layer ul {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }

    .course-price {
        width: 100%;
        justify-content: center;
    }

    .video-item {
        flex-wrap: wrap;
        gap: 10px;
    }

    .video-num {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }

    .video-item h2 {
        font-size: 1rem;
        width: calc(100% - 60px);
    }

    .course-time-left {
        margin-right: 55px;
        width: 100%;
        text-align: center;
    }

    .comment-item {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 15px;
    }

    .left-col .heading {
        flex-direction: column;
        gap: 5px;
    }

    .rating-item {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .share-socials {
        justify-content: center;
    }
}
