/* 태블릿 크기 */
@media (min-width: 481px) and (max-width: 768px) {
    .course-card.list-view .course-wrapper {
        padding: 16px;
    }
    
    .course-card.list-view .course-image {
        width: 120px;
        height: 90px;
        margin-right: 20px;
    }
    
    .course-card.list-view .course-name {
        font-size: 16px;
    }
    
    .course-card.list-view .course-meta {
        display: flex;
        flex-direction: column;
        gap: 4px;
        font-size: 12px;
    }
    
    .course-card.list-view .meta-item span:first-child {
        display: none; /* 아이콘만 숨김 */
    }
    
    .course-card.list-view .price-label {
        display: block;
        font-size: 11px;
    }
    
    .course-card.list-view .price-amount {
        font-size: 18px;
    }
    
    .course-card.list-view .btn-course {
        padding: 8px 14px;
        font-size: 12px;
    }
}

* { box-sizing: border-box; }

#container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px;
}
body{
	background : #fdfdfd;
}
.search-btn {
    position: absolute; 
    right: 5px; 
    top: 50%; 
    transform: translateY(-50%); 
    width: 40px; 
    height: 40px; 
    border: none; 
    background: transparent; 
    border-radius: 50%; 
    cursor: pointer; 
    display: flex;
    align-items: center; 
    justify-content: center;
    transition: all 0.3s ease;
}

.search-btn:hover {
    background: rgba(0, 102, 255, 0.1);
}

.btoom-bn-wrap {
	display : none !important;
}

.search-btn svg {
    width: 24px;
    height: 24px;
}

.filter-section {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.selected-categories {
    margin-bottom: 20px;
    min-height: 45px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.selected-label {
    font-size: 14px;
    color: #666;
    margin-right: 10px;
    font-weight: 500;
}

.category-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: #0066ff;
    color: white;
    border-radius: 20px;
    font-size: 14px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { 
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.category-tag .remove-tag {
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s;
    margin-left: 4px;
}

.category-tag .remove-tag:hover {
    opacity: 1;
}

.no-selection {
    color: #999;
    font-size: 14px;
    font-style: italic;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.category-item {
    position: relative;
}

.category-checkbox {
    position: absolute;
    opacity: 0;
}

.category-label {
    display: block;
    padding: 12px 16px;
    background: white;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    color: #495057;
    user-select: none;
}

.category-label:hover {
    border-color: #0066ff;
    background: #f0f7ff;
}

.category-checkbox:checked + .category-label {
    background: #0066ff;
    color: white;
    border-color: #0066ff;
    font-weight: 600;
}

.category-checkbox:checked + .category-label::after {
    content: '✓';
    position: absolute;
    top: 5px;
    right: 8px;
    font-size: 12px;
}

.filter-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.btn-filter {
    padding: 12px 40px;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-reset {
    background: #868e96;
    color: white;
}

.btn-reset:hover {
    background: #495057;
}

.btn-search {
    background: #0066ff;
    color: white;
}

.btn-search:hover {
    background: #0052cc;
}

.course-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.course-title {
    font-size: 24px;
    font-weight: 700;
    color: #212529;
}

.course-count {
    color: #0066ff;
}

.view-options {
    display: flex;
    gap: 5px;
    align-items: center;
    background: #f1f3f5;
    padding: 4px;
    border-radius: 8px;
}

.btn-view {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: none;
    background: transparent;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    color: #868e96;
}

.btn-view:hover {
    background: rgba(0, 102, 255, 0.1);
    color: #0066ff;
}

.btn-view.active {
    background: white;
    color: #0066ff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn-view svg {
    width: 20px;
    height: 20px;
}

.course-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

/* 리스트 뷰 스타일 */
.course-container.list-view {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.course-card.list-view {
    border-radius: 0;
    border-bottom: 1px solid #e9ecef;
    box-shadow: none;
    transition: background-color 0.2s ease;
}

.course-card.list-view:first-child {
    border-top: 1px solid #e9ecef;
}

.course-card.list-view:hover {
    transform: none;
    box-shadow: none;
    background-color: #f8f9fa;
}

/* 리스트 뷰에서 wrapper가 한 줄로 */
.course-card.list-view .course-wrapper {
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 20px;
}

.course-card.list-view .course-image {
    width: 200px;
    height: 150px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    margin-right: 30px;
}

.course-card.list-view .course-body {
    flex: 1;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 0;
}

.course-card.list-view .course-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.course-card.list-view .course-name {
    font-size: 18px;
    font-weight: 600;
    min-height: auto;
    margin-bottom: 0;
    -webkit-line-clamp: 1;
}

.course-card.list-view .course-meta {
    display: flex;
    flex-direction: row;
    gap: 25px;
    padding-bottom: 0;
    border-bottom: none;
    margin-bottom: 0;
}

.course-card.list-view .meta-item {
    font-size: 14px;
    color: #6c757d;
}

.course-card.list-view .course-footer {
    margin-top: 0;
    flex-direction: row;
    align-items: center;
    gap: 30px;
}

.course-card.list-view .course-price {
    align-items: flex-end;
    text-align: right;
}

.course-card.list-view .price-amount {
    font-size: 24px;
}

.course-card.list-view .course-actions {
    flex-direction: column;
    gap: 8px;
}

.course-card.list-view .btn-course {
    padding: 10px 24px;
    font-size: 14px;
    white-space: nowrap;
}

.course-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    cursor: pointer;
}

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

/* 그리드 뷰에서는 wrapper가 세로 배치 */
.course-wrapper {
    display: flex;
    flex-direction: column;
}

.course-image {
    position: relative;
    width: 100%;
    height: 200px;
    background: #f1f3f5;
    overflow: hidden;
}

.course-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.course-badges {
    position: absolute;
    top: 12px;
    left: 12px;
    display: flex;
    gap: 6px;
}

.badge {
    padding: 4px 10px;
    background: rgba(0,0,0,0.7);
    color: white;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.badge-best {
    background: #ff6b6b;
}

.badge-new {
    background: #51cf66;
}

.course-body {
    padding: 20px;
}

.course-info {
    display: flex;
    flex-direction: column;
}

.course-name {
    font-size: 16px;
    font-weight: 600;
    color: #212529;
    margin-bottom: 12px;
    line-height: 1.4;
    min-height: 44px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.course-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f1f3f5;
    margin-bottom: 12px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #868e96;
}

.meta-icon {
    width: 16px;
    text-align: center;
    color: #adb5bd;
}

.course-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.course-price {
    display: flex;
    flex-direction: column;
}

.price-label {
    font-size: 12px;
    color: #868e96;
    margin-bottom: 2px;
}

.price-amount {
    font-size: 20px;
    font-weight: 700;
    color: #0066ff;
}

.course-actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.btn-course {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
    text-decoration: none;
}

.btn-apply {
    background: #0066ff;
    color: white;
    border: none;
}

.btn-apply:hover {
    background: #0052cc;
}

.btn-preview {
    background: white;
    color: #495057;
    border: 1px solid #dee2e6;
}

.btn-preview:hover {
    background: #f8f9fa;
}

.empty-state {
    text-align: center;
    padding: 80px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.empty-icon {
    font-size: 64px;
    color: #dee2e6;
    margin-bottom: 30px;
}

.empty-message {
    font-size: 18px;
    color: #495057;
    font-weight: 500;
}

@media (max-width: 768px) {
    .category-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }
    
    .course-container {
        grid-template-columns: 1fr;
    }
	
    .course-card.list-view .course-wrapper {
        flex-direction: row;
        padding: 15px;
        align-items: flex-start;
    }
    
    .course-card.list-view .course-image {
        width: 100px;
        height: 75px;
        margin-right: 15px;
        border-radius: 6px;
    }
    
    .course-card.list-view .course-body {
        flex: 1;
        flex-direction: column;
        padding: 0;
        gap: 10px;
    }
    
    .course-card.list-view .course-info {
        width: 100%;
    }
    
    .course-card.list-view .course-name {
        font-size: 15px;
        -webkit-line-clamp: 2;
        display: -webkit-box;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    
    .course-card.list-view .course-meta {
        display: none; /* 모바일에서는 메타 정보 숨김 */
    }
    
    .course-card.list-view .course-footer {
        width: 100%;
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-end;
        gap: 10px;
    }
    
    .course-card.list-view .course-price {
        align-items: flex-start;
    }
    
    .course-card.list-view .price-label {
        display: none; /* 모바일에서는 라벨 숨김 */
    }
    
    .course-card.list-view .price-amount {
        font-size: 16px;
        font-weight: 700;
    }
    
    .course-card.list-view .course-actions {
        flex-direction: row;
        gap: 6px;
    }
    
    .course-card.list-view .btn-course {
        padding: 6px 10px;
        font-size: 11px;
    }
    
    .course-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .course-title {
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .course-card.list-view .course-wrapper {
        padding: 12px;
    }
    
    .course-card.list-view .course-image {
        width: 80px;
        height: 60px;
        margin-right: 12px;
    }
    
    .course-card.list-view .course-name {
        font-size: 14px;
        font-weight: 600;
        margin-bottom: 8px;
    }
    
    .course-card.list-view .course-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .course-card.list-view .course-price {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .course-card.list-view .price-amount {
        font-size: 15px;
    }
    
    .course-card.list-view .course-actions {
        display: flex;
        flex-direction: row;
        gap: 8px;
        width: 100%;
    }
    
    .course-card.list-view .btn-course {
        flex: 1;
        padding: 8px 12px;
        font-size: 12px;
    }
    
    /* 필터 섹션 모바일 최적화 */
    .filter-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .btn-filter {
        width: 100%;
    }
}