/* ============================================================
   becomingmiles Academy — استایل دوره‌ها (آرشیو + کارت)
   ============================================================ */

/* ===== سربرگ آرشیو ===== */
.bm-archive-head { margin-bottom: 28px; }
.bm-archive-head h1 { margin: 6px 0 4px; }
.bm-archive-count { color: var(--bm-text-sub); font-weight: 600; }

/* ===== چیدمان آرشیو (فیلتر کناری + شبکه) ===== */
.bm-archive-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 28px;
    align-items: start;
}

/* ===== فیلترها ===== */
.bm-filters { padding: 22px; position: sticky; top: calc(var(--bm-header-h) + 16px); }
.bm-filters-title { font-size: 1.1rem; margin-bottom: 18px; }
.bm-filter-group { margin-bottom: 20px; }
.bm-filter-group > label { display: block; font-weight: 700; margin-bottom: 10px; font-size: .95rem; }
.bm-filter-group input[type=search] {
    width: 100%; padding: 10px 14px;
    border: 1px solid var(--bm-border); border-radius: var(--bm-radius-sm);
    background: var(--bm-bg); color: var(--bm-text); font-family: inherit;
}
.bm-filter-cats { list-style: none; margin: 0; padding: 0; }
.bm-filter-cats li a {
    display: flex; justify-content: space-between;
    padding: 8px 10px; border-radius: var(--bm-radius-sm);
    color: var(--bm-text-sub); font-size: .92rem;
}
.bm-filter-cats li a:hover, .bm-filter-cats li.active a {
    background: color-mix(in srgb, var(--bm-primary) 10%, transparent);
    color: var(--bm-primary); font-weight: 700;
}
.bm-check { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; color: var(--bm-text-sub); cursor: pointer; }

/* ===== کارت دوره ===== */
.bm-course-card { overflow: hidden; display: flex; flex-direction: column; }
.bm-course-thumb { position: relative; display: block; aspect-ratio: 16/9; background: var(--bm-surface-2); overflow: hidden; }
.bm-course-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.bm-course-card:hover .bm-course-thumb img { transform: scale(1.05); }
.bm-course-thumb-ph { display: block; width: 100%; height: 100%; background: linear-gradient(135deg, var(--bm-surface-2), var(--bm-border)); }
.bm-course-badge { position: absolute; top: 12px; right: 12px; }

.bm-course-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.bm-course-cat { font-size: .8rem; color: var(--bm-primary); font-weight: 700; }
.bm-course-title { font-size: 1.08rem; margin: 0; line-height: 1.6; }
.bm-course-title a { color: var(--bm-text); }
.bm-course-title a:hover { color: var(--bm-primary); }

.bm-course-instructor { display: flex; align-items: center; gap: 8px; color: var(--bm-text-sub); font-size: .88rem; }
.bm-course-instructor img { border-radius: 50%; object-fit: cover; }

.bm-course-meta { display: flex; gap: 14px; color: var(--bm-text-sub); font-size: .85rem; }
.bm-course-rating { color: var(--bm-accent); font-weight: 700; }
.bm-course-rating small { color: var(--bm-text-mute); }

.bm-course-footer {
    margin-top: auto; padding-top: 14px;
    border-top: 1px solid var(--bm-border);
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.bm-course-price { font-weight: 800; color: var(--bm-text); font-size: 1.05rem; }
.bm-price-free { color: var(--bm-success); }
.bm-course-price del { color: var(--bm-text-mute); font-weight: 500; font-size: .85rem; margin-inline-start: 6px; }
.bm-course-btn { padding: 8px 16px; font-size: .85rem; }

/* ===== صفحه‌بندی ===== */
.bm-pagination { margin-top: 36px; text-align: center; }
.bm-pagination .page-numbers {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 42px; height: 42px; padding: 0 12px; margin: 0 3px;
    border: 1px solid var(--bm-border); border-radius: var(--bm-radius-sm);
    color: var(--bm-text); font-weight: 600;
}
.bm-pagination .page-numbers.current { background: var(--bm-primary); color: #fff; border-color: var(--bm-primary); }
.bm-pagination .page-numbers:hover { border-color: var(--bm-primary); color: var(--bm-primary); }
.bm-pagination .page-numbers.current:hover { color: #fff; }

.bm-empty { padding: 48px; text-align: center; color: var(--bm-text-sub); }

/* ===== ریسپانسیو ===== */
@media (max-width: 980px) {
    .bm-archive-layout { grid-template-columns: 1fr; }
    .bm-filters { position: static; }
}
