/* ══════════════════════════════
   공통
══════════════════════════════ */
.cmfront-wrap, .cmfront-featured-wrap { max-width:1200px; margin:0 auto; font-family:inherit; }

/* ══ 강좌 카드 그리드 ══ */
.cmfront-course-grid {
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:20px; margin-top:16px;
}
.cmfront-course-card {
    border-radius:10px; overflow:hidden;
    box-shadow:0 2px 12px rgba(0,0,0,.08);
    transition:transform .25s, box-shadow .25s;
    background:#fff;
}
.cmfront-course-card:hover {
    transform:translateY(-5px);
    box-shadow:0 10px 30px rgba(0,0,0,.14);
}
.cmfront-card-link { text-decoration:none !important; color:inherit; display:block; }
.cmfront-card-thumb {
    position:relative; width:100%; aspect-ratio:4/3; overflow:hidden; background:#f0f4f8;
}
.cmfront-card-thumb img { width:100%; height:100%; object-fit:cover; transition:transform .3s; }
.cmfront-course-card:hover .cmfront-card-thumb img { transform:scale(1.05); }
.cmfront-thumb-ph { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:44px; }
.cmfront-card-cat {
    position:absolute; bottom:8px; left:8px;
    background:rgba(26,79,138,.88); color:#fff;
    font-size:11px; font-weight:700; padding:3px 10px; border-radius:20px;
}
.cmfront-card-body { padding:14px; }
.cmfront-card-title {
    font-size:14px; font-weight:700; color:#1d2327; margin:0 0 6px; line-height:1.4;
    display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden;
}
.cmfront-card-desc { font-size:12px; color:#999; margin:0 0 10px; line-height:1.5; }
.cmfront-card-footer { display:flex; align-items:center; justify-content:space-between; padding-top:10px; border-top:1px solid #f0f0f0; }
.cmfront-card-price { font-size:15px; font-weight:900; color:#1a4f8a; }
.cmfront-card-arrow { font-size:14px; color:#bbb; }

/* ══ 메인 강좌 섹션 ══ */
.cmfront-featured-title-wrap { text-align:center; margin-bottom:24px; }
.cmfront-featured-title { font-size:26px; font-weight:800; margin:0; }

/* 카테고리 탭 */
.cmfront-featured-tabs {
    display:flex; gap:10px; flex-wrap:wrap;
    margin-bottom:20px; justify-content:center;
}
.cmfront-ftab {
    padding:7px 20px; border:1px solid #ddd; border-radius:25px;
    font-size:13px; font-weight:600; color:#666;
    text-decoration:none !important; transition:.2s;
}
.cmfront-ftab:hover, .cmfront-ftab.active {
    background:#1a4f8a; color:#fff !important; border-color:#1a4f8a;
}
.cmfront-featured-more { text-align:center; margin-top:28px; }
.cmfront-more-btn {
    display:inline-block; padding:10px 30px;
    border:2px solid #1a4f8a; color:#1a4f8a !important;
    border-radius:25px; font-weight:700; font-size:14px;
    text-decoration:none !important; transition:.2s;
}
.cmfront-more-btn:hover { background:#1a4f8a; color:#fff !important; }

/* 목록 필터 */
.cmfront-filter-bar { margin-bottom:20px; }
.cmfront-search-input-wrap { display:flex; gap:8px; max-width:400px; margin-bottom:14px; }
.cmfront-search-input-wrap input { flex:1; padding:10px 14px; border:1px solid #ddd; border-radius:6px; font-size:14px; }
.cmfront-search-input-wrap button { padding:10px 20px; background:#1a4f8a; color:#fff; border:none; border-radius:6px; cursor:pointer; font-weight:600; }
.cmfront-cat-filter { display:flex; gap:8px; flex-wrap:wrap; }
.cmfront-cat-btn { padding:6px 16px; border:1px solid #ddd; border-radius:20px; font-size:13px; color:#555; text-decoration:none !important; transition:.2s; }
.cmfront-cat-btn:hover, .cmfront-cat-btn.active { background:#1a4f8a; color:#fff !important; border-color:#1a4f8a; }
.cmfront-result-count { color:#888; font-size:13px; margin:0 0 8px; }
.cmfront-empty { text-align:center; padding:60px 20px; color:#bbb; font-size:16px; }
.cmfront-pagination { display:flex; justify-content:center; gap:6px; margin-top:32px; }
.cmfront-page-btn { width:36px; height:36px; border:1px solid #ddd; border-radius:6px; display:flex; align-items:center; justify-content:center; text-decoration:none !important; color:#555; font-size:14px; }
.cmfront-page-btn.active { background:#1a4f8a; color:#fff !important; border-color:#1a4f8a; }

/* ══════════════════════════════
   강좌 상세 페이지
══════════════════════════════ */
.cmfront-detail-page { font-family:inherit; }

/* 목록으로 돌아가기 */
.cmfront-back-bar { margin:16px 0 10px; }
.cmfront-back-btn {
    display:inline-flex; align-items:center; gap:6px;
    color:#1a4f8a; font-size:13px; font-weight:600;
    text-decoration:none !important; padding:7px 16px;
    border:1px solid #c5ddf7; border-radius:20px;
    background:#f0f7ff; transition:.2s;
}
.cmfront-back-btn:hover { background:#1a4f8a; color:#fff !important; }

/* ① 풀와이드 히어로 */
.cmfront-hero-full {
    width:100vw;
    margin-left:calc(50% - 50vw);
    height:420px;
    background-size:cover;
    background-position:center;
    background-color:#1a3a5c;
    position:relative;
}
.cmfront-hero-overlay {
    position:absolute; inset:0;
    background:linear-gradient(to bottom, rgba(0,0,0,.3) 0%, rgba(0,0,0,.65) 100%);
    display:flex; align-items:center; justify-content:center;
}
.cmfront-hero-inner {
    text-align:center;
    color:#fff; max-width:800px; padding:0 30px;
}
.cmfront-hero-cat {
    display:inline-block; background:rgba(255,255,255,.2);
    padding:4px 14px; border-radius:20px; font-size:12px;
    font-weight:700; margin-bottom:12px; letter-spacing:1px;
}
.cmfront-hero-title { font-size:36px; font-weight:900; margin:0 0 8px; line-height:1.3; text-shadow:0 2px 8px rgba(0,0,0,.3); color:#ffffff !important; }
.cmfront-hero-reg { font-size:14px; opacity:.75; margin:0; }

/* ② 본문 레이아웃 */
.cmfront-detail-body {
    display:grid;
    grid-template-columns:1fr 300px;
    gap:40px;
    max-width:1100px;
    margin:48px auto;
    padding:0 20px;
    align-items:start;
}
.cmfront-detail-left { min-width:0; }

/* 섹션 */
.cmfront-detail-section { margin-bottom:36px; padding-bottom:36px; border-bottom:1px solid #eee; }
.cmfront-detail-section:last-child { border-bottom:none; }
.cmfront-section-title {
    font-size:18px; font-weight:800; color:#1a4f8a;
    margin:0 0 14px; padding-bottom:10px;
    border-bottom:2px solid #1a4f8a;
}
.cmfront-section-text { font-size:14px; color:#555; line-height:1.9; }
.cmfront-bullet-item { margin:4px 0; font-size:14px; color:#555; line-height:1.7; }

/* 미리보기 */
.cmfront-preview-player {
    border-radius:10px; overflow:hidden;
    background:#000; position:relative;
}
.cmfront-preview-player > div {
    position:relative; aspect-ratio:16/9;
    cursor:pointer; overflow:hidden;
}
.cmfront-preview-player img { width:100%; height:100%; object-fit:cover; display:block; }
.cmfront-play-btn {
    position:absolute; top:50%; left:50%; transform:translate(-50%,-50%);
    width:70px; height:70px; border-radius:50%;
    background:rgba(26,79,138,.85); color:#fff;
    font-size:26px; border:3px solid #fff;
    cursor:pointer; display:flex; align-items:center; justify-content:center;
    transition:.2s;
}
.cmfront-play-btn:hover { background:#1a4f8a; transform:translate(-50%,-50%) scale(1.08); }
.cmfront-preview-label { padding:10px 14px; font-size:13px; color:#888; background:#111; }
.cmfront-preview-img img { width:100%; border-radius:10px; }

/* 강사 카드 */
.cmfront-inst-card {
    display:flex; gap:20px; align-items:flex-start;
    background:#f8f9fa; border-radius:10px; padding:20px;
}
.cmfront-inst-photo {
    width:140px !important;
    height:170px !important;
    max-width:140px !important;
    border-radius:8px; object-fit:cover;
    flex:0 0 140px;
    box-shadow:4px 4px 12px rgba(0,0,0,.18);
}
.cmfront-inst-photo-ph {
    width:140px !important;
    height:170px !important;
    max-width:140px !important;
    border-radius:8px; background:#e0e0e0;
    display:flex; align-items:center; justify-content:center;
    font-size:40px; flex:0 0 140px;
    box-shadow:4px 4px 12px rgba(0,0,0,.18);
}
.cmfront-inst-info { flex:1; min-width:0; }
.cmfront-inst-info h3 { margin:0 0 8px; font-size:15px; font-weight:700; }
.cmfront-inst-certs { display:flex; flex-wrap:wrap; gap:4px; margin-bottom:8px; }
.cmfront-inst-cert { background:#e8f3ff; color:#1a6fa3; font-size:11px; font-weight:700; padding:2px 8px; border-radius:20px; }
.cmfront-inst-career p { font-size:13px; color:#666; margin:2px 0; }
.cmfront-inst-msg { font-size:13px; color:#888; font-style:italic; border-left:3px solid #1a4f8a; padding-left:12px; margin:10px 0 0; }

/* ③ 우측 사이드 카드 */
.cmfront-detail-right { align-self:start; }
.cmfront-side-card {
    border:1px solid #e0e0e0; border-radius:12px;
    background:#fff; overflow:hidden;
    box-shadow:0 4px 20px rgba(0,0,0,.08);
}
.cmfront-side-btns { padding:20px 20px 0; display:flex; flex-direction:column; gap:10px; }
.cmfront-apply-btn {
    display:block; width:100%; padding:14px;
    background:#1a4f8a; color:#fff !important;
    text-align:center; border-radius:8px; font-size:15px;
    font-weight:700; border:none; cursor:pointer;
    text-decoration:none !important; transition:.2s;
}
.cmfront-apply-btn:hover { background:#153e6e; }
.cmfront-studying-btn { background:#2e7d32; }
.cmfront-studying-btn:hover { background:#1b5e20; }
.cmfront-inquiry-btn {
    display:block; width:100%; padding:13px;
    background:#e53935; color:#fff !important;
    text-align:center; border-radius:8px; font-size:15px;
    font-weight:700; border:none; cursor:pointer;
    text-decoration:none !important; transition:.2s;
    box-sizing:border-box;
}
.cmfront-inquiry-btn:hover { background:#c62828; }

.cmfront-side-info { padding:16px 20px 20px; }
.cmfront-side-info-item {
    display:flex; flex-direction:column; gap:3px;
    padding:10px 0; border-bottom:1px solid #f0f0f0;
}
.cmfront-side-info-item:last-child { border-bottom:none; }
.cmfront-side-label { font-size:11px; color:#aaa; font-weight:600; text-transform:uppercase; letter-spacing:.5px; }
.cmfront-side-value { font-size:13px; color:#333; font-weight:600; line-height:1.4; }
.cmfront-price-val { font-size:18px; color:#1a4f8a; font-weight:900; }
.cmfront-enrolled-notice { text-align:center; font-size:12px; color:#2e7d32; font-weight:700; padding:0 0 14px; margin:0; }

/* ══ 모달 ══ */
.cmfront-modal {
    position:fixed; inset:0; background:rgba(0,0,0,.7);
    z-index:999999 !important;
    display:flex; align-items:flex-start; justify-content:center;
    padding-top:250px; overflow-y:auto;
}
.cmfront-modal-box {
    background:#fff; border-radius:14px;
    width:92vw; max-width:500px;
    padding:32px; position:relative;
    margin-bottom:40px;
}
.cmfront-modal-x {
    position:absolute; top:12px; right:14px;
    background:#e00; color:#fff; border:none;
    border-radius:50%; width:28px; height:28px;
    cursor:pointer; font-size:13px; line-height:1;
}

/* 신청 폼 스타일 */
.cmfront-apply-form h2 { margin:0 0 6px; font-size:20px; }
.cmfront-apply-subtitle { color:#888; font-size:13px; margin:0 0 20px; }
.cmfront-apply-price-box {
    background:#f0f7ff; border-radius:8px; padding:14px 16px;
    margin-bottom:20px; display:flex; justify-content:space-between; align-items:center;
}
.cmfront-apply-price-box span { color:#888; font-size:13px; }
.cmfront-apply-price-box strong { font-size:22px; font-weight:900; color:#1a4f8a; }
.cmfront-form-field { margin-bottom:14px; }
.cmfront-form-field label { display:block; font-size:12px; font-weight:700; color:#555; margin-bottom:5px; }
.cmfront-form-field input, .cmfront-form-field select {
    width:100%; padding:10px 12px; border:1px solid #ddd;
    border-radius:6px; font-size:14px; box-sizing:border-box;
}
.cmfront-form-submit {
    width:100%; padding:14px; background:#1a4f8a; color:#fff;
    border:none; border-radius:8px; font-size:15px;
    font-weight:700; cursor:pointer; margin-top:6px;
    transition:.2s;
}
.cmfront-form-submit:hover { background:#153e6e; }
.cmfront-form-note { font-size:12px; color:#aaa; text-align:center; margin-top:10px; }

/* ══ 반응형 ══ */
@media(max-width:1024px) {
    .cmfront-course-grid { grid-template-columns:repeat(3,1fr); }
}
@media(max-width:768px) {
    .cmfront-course-grid { grid-template-columns:repeat(2,1fr); }
    .cmfront-detail-body { grid-template-columns:1fr; padding:0 16px; }
    .cmfront-detail-right { order:-1; }
    .cmfront-side-card { position:static; }
    .cmfront-hero-full { height:280px; }
    .cmfront-hero-inner { padding:24px 20px; }
    .cmfront-hero-title { font-size:24px; }
    .cmfront-inst-card { flex-direction:column; }
}
@media(max-width:480px) {
    .cmfront-course-grid { grid-template-columns:1fr; }
}
