@charset "utf-8";

/* 세무정보 비디오 스킨 */
.page-title {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 120px 0;
    color: #fff;
    text-align: center;
    position: relative;
}

.page-title::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(26,58,109,0.8), rgba(42,82,152,0.8));
}

.page-title .container {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.page-title h1 {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 15px;
}

.page-title p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 모바일 페이지 타이틀 */
.mobile-page-title {
    position: relative;
    height: 200px;
    overflow: hidden;
    text-align: center;
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.mobile-title-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('../../../assets/img/top/sub3-1-1.jpg');
    background-size: cover;
    background-position: center;
    z-index: 0;
    filter: brightness(0.7);
}

.mobile-title-content {
    position: relative;
    z-index: 1;
}

.mobile-page-title h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}

.mobile-title-desc {
    font-size: 1rem;
    opacity: 0.9;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

/* 필터 섹션 */
.tax-filter {
    padding: 40px 0;
    background: #f8f9fa;
}

.filter-buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
}

.filter-btn {
    padding: 12px 24px;
    background: #fff;
    color: #666;
    border: 1px solid #ddd;
    border-radius: 30px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background: #e9ecef;
    transform: translateY(-2px);
    color: #2a5298;
}

.filter-btn.active {
    background: #2a5298;
    color: #fff;
    border-color: #2a5298;
    box-shadow: 0 4px 8px rgba(42,82,152,0.2);
}

.filter-buttons-more .filter-btn {
  margin: 4px;
}

/* 세무정보 비디오 그리드 */
.video-grid {
    padding: 60px 0;
}

.videos-wrapper {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

.video-card {
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
    overflow: hidden;
    transition: transform 0.3s ease;
    height: 100%;
}

.video-card:hover {
    transform: translateY(-5px);
}

.video-thumbnail {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 비율 */
    overflow: hidden;
}

.video-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-card:hover .video-thumbnail img {
    transform: scale(1.05);
}

.video-play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2a5298;
    font-size: 24px;
    z-index: 2;
    transition: all 0.3s ease;
}

.video-card:hover .video-play-button {
    background: #2a5298;
    color: #fff;
}

.category-tag {
    display: inline-block;
    padding: 6px 12px;
    background: #f0f4ff;
    color: #2a5298;
    border-radius: 20px;
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.video-content {
    padding: 20px;
}

.video-content h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: #1a3a6d;
    margin-bottom: 10px;
    line-height: 1.4;
}

.video-content h3 a {
    color: #1a3a6d;
    text-decoration: none;
}

.video-content h3 a:hover {
    color: #2a5298;
}

.video-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #888;
    font-size: 0.9rem;
    border-top: 1px solid #eee;
    padding-top: 15px;
    margin-top: 15px;
}

.video-views {
    display: flex;
    align-items: center;
    gap: 5px;
}

.video-date {
    display: flex;
    align-items: center;
    gap: 5px;
}

.video-more {
    text-align: center;
    margin-top: 40px;
}

.more-button {
    padding: 15px 40px;
    background: transparent;
    border: 2px solid #2a5298;
    border-radius: 30px;
    color: #2a5298;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.more-button:hover {
    background: #2a5298;
    color: #fff;
}

/* 인기 동영상 섹션 */
.popular-videos {
    background: #f8f9fa;
    padding: 80px 0;
}

.popular-videos h2 {
    text-align: center;
    font-size: 2rem;
    color: #1a3a6d;
    margin-bottom: 40px;
}

.popular-list {
    max-width: 800px;
    margin: 0 auto;
}

.popular-item {
    display: flex;
    align-items: center;
    padding: 20px;
    background: #fff;
    border-radius: 10px;
    margin-bottom: 15px;
    text-decoration: none;
    color: #333;
    transition: transform 0.3s ease;
}

.popular-item:hover {
    transform: translateX(10px);
}

.popular-thumb {
    flex-shrink: 0;
    width: 120px;
    height: 68px;
    margin-right: 15px;
    border-radius: 5px;
    overflow: hidden;
    position: relative;
}

.popular-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.popular-thumb .play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 30px;
    height: 30px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2a5298;
    font-size: 12px;
}

.popular-content {
    flex-grow: 1;
}

.popular-title {
    font-size: 1.1rem;
    font-weight: 500;
    margin-bottom: 5px;
    color: #1a3a6d;
    line-height: 1.4;
}

.popular-meta {
    display: flex;
    color: #888;
    font-size: 0.8rem;
    gap: 10px;
}

.popular-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* 비디오 상세 페이지 */
.video-view {
    padding: 60px 0;
}

.video-view .container {
    max-width: 1000px;
}

.video-player {
    width: 100%;
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    padding-bottom: 56.25%;
}

.video-player iframe {
    position: absolute;
    top:0px; left:0px;
    width: 100%;
    height: 100%;
    border: none;
}

.video-header {
    margin-bottom: 30px;
}

.video-header .category-tag {
    margin-bottom: 15px;
}

.video-title {
    font-size: 2rem;
    color: #1a3a6d;
    margin-bottom: 20px;
    line-height: 1.3;
}

.video-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
    flex-wrap: wrap;
    gap: 10px;
}

.video-info .info-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.video-info .info-right {
    display: flex;
    gap: 15px;
    color: #888;
}

.video-info .info-right span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.video-description {
    margin: 30px 0;
    line-height: 1.7;
    color: #444;
}

.video-related {
    margin-top: 60px;
}

.video-related h3 {
    font-size: 1.5rem;
    color: #1a3a6d;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.related-videos {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

/* 반응형 스타일 */
@media (max-width: 1024px) {
    .video-title {
        font-size: 1.8rem;
    }
}

@media (max-width: 768px) {
    .page-title {
        padding: 80px 0;
    }

    .page-title h1 {
        font-size: 2rem;
    }

    .page-title p {
        font-size: 1rem;
    }

    .videos-wrapper {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }

    .popular-thumb {
        width: 80px;
        height: 45px;
    }

    .popular-title {
        font-size: 1rem;
    }

    .video-info {
        flex-direction: column;
        align-items: flex-start;
    }

    .video-info .info-left,
    .video-info .info-right {
        width: 100%;
    }

    .related-videos {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
}

@media (max-width: 480px) {
    .tax-filter {
      padding: 0;
    }

    .filter-btn {
        padding: 8px 16px;
        font-size: 0.9rem;
        font-size:10px;
    }

    .videos-wrapper {
        grid-template-columns: 1fr;
    }

    .video-title {
        font-size: 1.5rem;
    }

    .video-play-button {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }

    .related-videos {
        grid-template-columns: 1fr;
    }
}

/* 카테고리 */
.list-category { display: none; }
.list-wrap { width:100%; }
.list-btn-box { margin-bottom: 15px; }

/* 목록 공통 */
.list-wrap .list-container { margin-right:0; }
.list-none { margin:0px 0px 15px; padding:80px 0px; }
.list-page { margin-bottom:15px; }
.list-page .pagination { margin:0; }

/* 글쓰기 폼 스타일 */
.write-form {
    background: #fff;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.write-section-title {
    font-size: 1.4rem;
    color: #1a3a6d;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
    position: relative;
}

.write-section-title::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 80px;
    height: 3px;
    background: #2a5298;
}

.form-group {
    margin-bottom: 25px;
    position: relative;
    display: inherit !important;
}
.form-group input{
    width: 90%;
}

.form-group.focused label {
    color: #2a5298;
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 10px;
    color: #333;
    transition: color 0.3s ease;
}

.required-mark {
    color: #e74c3c;
    margin-left: 5px;
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: #f9fafb;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    border-color: #2a5298;
    box-shadow: 0 0 0 3px rgba(42,82,152,0.15);
    background-color: #fff;
    outline: none;
}

.form-help {
    font-size: 0.9rem;
    color: #666;
    margin-top: 8px;
}

.form-file {
    display: block;
    width: 100%;
    margin-top: 10px;
}

/* 썸네일 미리보기 */
.thumbnail-preview {
    margin: 15px 0;
    border-radius: 8px;
    overflow: hidden;
    max-width: 300px;
}

.thumbnail-preview img {
    width: 100%;
    height: auto;
}

.existing-file {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
    padding: 10px 15px;
    border-radius: 8px;
    margin-top: 10px;
}

.file-name {
    font-size: 0.9rem;
    color: #555;
}

.form-check {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 5px;
}

/* 버튼 스타일 */
.write-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 40px;
}

.submit-button {
    padding: 15px 40px;
    background: #2a5298;
    color: #fff;
    border: none;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(42,82,152,0.2);
}

.submit-button:hover {
    background: #1a3a6d;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(42,82,152,0.3);
}

.cancel-button {
    padding: 15px 40px;
    background: #f8f9fa;
    color: #666;
    border: 1px solid #ddd;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.cancel-button:hover {
    background: #eee;
    color: #333;
}

/* ckeditor 스타일 조정 */
.cke_chrome {
    border-color: #ddd !important;
    border-radius: 8px !important;
    box-shadow: none !important;
}

.cke_top {
    border-bottom-color: #eee !important;
    background: #f9fafb !important;
    border-radius: 8px 8px 0 0 !important;
}

.cke_bottom {
    border-top-color: #eee !important;
    background: #f9fafb !important;
    border-radius: 0 0 8px 8px !important;
}

/* 반응형 스타일 */
@media (max-width: 768px) {
    .write-form {
        padding: 20px;
    }

    .submit-button,
    .cancel-button {
        padding: 12px 25px;
        font-size: 1rem;
    }

    .write-buttons {
        flex-direction: column;
    }

    .cancel-button {
        order: 2;
    }

    .submit-button {
        order: 1;
    }

    .form-group input{
      width: 80%;
    }
}

/* 카테고리 */
.list-category { display: none; }
.list-wrap { width:100%; }
.list-btn-box { margin-bottom: 15px; }

/* 목록 공통 */
.list-wrap .list-container { margin-right:0; }
.list-none { margin:0px 0px 15px; padding:80px 0px; }
.list-page { margin-bottom:15px; }
.list-page .pagination { margin:0; }

/* 입력 필드와 아이콘 */
.input-with-icon {
    position: relative;
}

.input-with-icon .form-input,
.input-with-icon .form-textarea {
    padding-left: 45px;
}

.input-with-icon i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.input-with-icon.focused i,
.form-group.focused .input-with-icon i {
    color: #2a5298;
}

/* 셀렉트 필드 스타일링 */
.select-wrapper {
    position: relative;
}

.select-wrapper .form-select {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 40px;
}

.select-wrapper i {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    pointer-events: none;
    transition: color 0.3s ease;
}

.form-group.focused .select-wrapper i {
    color: #2a5298;
}

/* 태그 컨테이너 */
.tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.tag-item {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    background: #f0f4ff;
    color: #2a5298;
    border-radius: 20px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.tag-item i {
    margin-left: 8px;
    font-size: 0.8rem;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.tag-item i:hover {
    opacity: 1;
}

.tag-item:hover {
    background: #e0e8ff;
    transform: translateY(-2px);
}

/* 비디오 URL 미리보기 */
.video-url-preview {
    margin-top: 15px;
}

.video-preview-container {
    display: flex;
    align-items: center;
    background: #f8f9fa;
    border-radius: 8px;
    padding: 10px;
    border: 1px solid #eee;
}

.video-preview-thumbnail {
    position: relative;
    width: 120px;
    height: 68px;
    border-radius: 4px;
    overflow: hidden;
    margin-right: 15px;
    background: #eee;
}

.video-preview-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-preview-thumbnail.vimeo {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #1ab7ea;
    color: #fff;
}

.video-preview-thumbnail.vimeo i {
    font-size: 2rem;
}

.video-preview-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 30px;
    height: 30px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ff0000;
    font-size: 14px;
}

.video-preview-info {
    flex-grow: 1;
}

.video-preview-info p {
    margin: 0;
    color: #2a5298;
    font-size: 0.9rem;
}

/* 파일 업로드 영역 */
.file-upload-container {
    margin-top: 15px;
}

.file-upload-area {
    position: relative;
    border: 2px dashed #ddd;
    border-radius: 8px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
    margin-bottom: 15px;
    background: #fcfcfc;
}

.file-upload-area.highlight {
    border-color: #2a5298;
    background: #f0f4ff;
}

.file-upload-wrapper {
    position: relative;
}

.file-upload-message {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    color: #888;
}

.file-upload-message i {
    font-size: 3rem;
    color: #ddd;
    transition: color 0.3s ease;
}

.file-upload-area:hover .file-upload-message i {
    color: #2a5298;
}

.file-upload-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.file-preview {
    margin-top: 15px;
}

.file-preview-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 300px;
    margin: 0 auto;
}

.file-preview-item img {
    width: 100%;
    border-radius: 8px;
    margin-bottom: 10px;
}

.file-preview-icon {
    width: 60px;
    height: 60px;
    background: #f0f4ff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #2a5298;
    margin-bottom: 10px;
}

.file-preview-name {
    font-size: 0.9rem;
    color: #333;
    margin-bottom: 5px;
    word-break: break-all;
    text-align: center;
}

.file-preview-size {
    font-size: 0.8rem;
    color: #888;
}

/* 첨부파일 업로드 */
.attachment-upload {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 5px;
}

.file-upload-btn {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    background: #f0f4ff;
    color: #2a5298;
    border-radius: 30px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.file-upload-btn:hover {
    background: #2a5298;
    color: #fff;
}

.attachment-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.file-name {
    flex-grow: 1;
    color: #888;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.file-name.has-file {
    color: #2a5298;
    font-weight: 500;
}

/* 썸네일 미리보기 스타일 */
.current-thumbnail {
    margin-bottom: 20px;
}

.thumbnail-preview {
    position: relative;
    max-width: 300px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.thumbnail-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 10px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.thumbnail-preview:hover .thumbnail-overlay {
    opacity: 1;
}

.thumbnail-overlay .form-check {
    margin: 0;
    color: #fff;
}

.thumbnail-overlay .form-check input {
    margin-right: 5px;
}

/* 영상 보기 페이지 */
.view-nav {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    font-size: 0.95rem;
}

.view-nav-link {
    color: #666;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: color 0.3s ease;
}

.view-nav-link:hover {
    color: #2a5298;
}

.view-nav-sep {
    margin: 0 10px;
    color: #ddd;
}

.view-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 30px;
}

.view-main-content {
    overflow: hidden;
}

.view-sidebar {
    position: relative;
}

/* 비디오 상세 페이지 개선 */
.video-header-top {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.video-duration {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    background: #f0f4ff;
    color: #1a3a6d;
    border-radius: 20px;
    font-size: 0.85rem;
}

.video-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1a3a6d;
    margin-bottom: 20px;
    line-height: 1.3;
}

.video-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
    flex-wrap: wrap;
    gap: 15px;
}

.info-left {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.info-right {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.info-item {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #666;
    font-size: 0.9rem;
}

/* 소셜 공유 버튼 */
.social-share {
    position: relative;
}

.share-toggle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f0f4ff;
    color: #2a5298;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.share-toggle:hover {
    background: #e0e8ff;
}

.share-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    padding: 10px;
    margin-top: 10px;
    display: flex;
    gap: 10px;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.share-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.share-dropdown a {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.share-dropdown a:hover {
    transform: scale(1.1);
}

.share-facebook {
    background: #3b5998;
}

.share-twitter {
    background: #1da1f2;
}

.share-kakaotalk {
    background: #fee500;
    color: #000 !important;
}

.share-link {
    background: #2a5298;
}

/* 태그 */
.video-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 20px 0;
}

.video-tag {
    display: inline-block;
    padding: 6px 12px;
    background: #f8f9fa;
    color: #2a5298;
    border-radius: 20px;
    font-size: 0.85rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.video-tag:hover {
    background: #e0e8ff;
    transform: translateY(-2px);
}

/* 영상 설명 */
.video-description {
    margin: 40px 0;
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    position: relative;
}

.section-heading {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1a3a6d;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.description-content {
    color: #555;
    line-height: 1.7;
    font-size: 1rem;
}

/* 첨부파일 */
.attachments {
    margin: 30px 0;
}

.attachments-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.attachment-item {
    margin-bottom: 10px;
}

.attachment-link {
    display: flex;
    align-items: center;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    transition: background 0.3s ease;
}

.attachment-link:hover {
    background: #f0f4ff;
}

.attachment-link i {
    font-size: 1.5rem;
    margin-right: 15px;
    color: #2a5298;
}

.attachment-info {
    flex-grow: 1;
}

.attachment-name {
    display: block;
    font-weight: 500;
    margin-bottom: 5px;
}

.attachment-meta {
    display: flex;
    gap: 15px;
    font-size: 0.85rem;
    color: #888;
}

.attachment-download {
    color: #2a5298;
    font-size: 1.2rem;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.attachment-link:hover .attachment-download {
    opacity: 1;
}

/* 이전/다음 글 네비게이션 */
.post-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin: 40px 0;
    width: 100%;
    overflow: hidden;
}

.prev-post,
.next-post {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s ease;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.empty {
    background: transparent;
}

.prev-post:hover,
.next-post:hover {
    background: #f0f4ff;
    transform: translateY(-2px);
}

.prev-post i,
.next-post i {
    font-size: 1.5rem;
    color: #2a5298;
    flex-shrink: 0;
}

.prev-post i {
    margin-right: 15px;
}

.next-post i {
    margin-left: 15px;
}

.nav-content {
    flex-grow: 1;
    min-width: 0;
    overflow: hidden;
}

.label, .nav-label {
    display: block;
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 5px;
}

.title, .nav-title {
    display: block;
    font-weight: 500;
    color: #1a3a6d;
    font-size: 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

/* 버튼 영역 */
.post-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 30px 0;
}

.post-buttons-left,
.post-buttons-right {
    display: flex;
    gap: 10px;
}

.btn-view {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-list {
    background: #f8f9fa;
    color: #666;
    border: 1px solid #ddd;
}

.btn-list:hover {
    background: #f0f0f0;
    color: #555;
}

.btn-modify {
    background: #2a5298;
    color: #fff;
}

.btn-modify:hover {
    background: #1a3a6d;
}

.btn-delete {
    background: #e74c3c;
    color: #fff;
}

.btn-delete:hover {
    background: #c0392b;
}

.btn-write {
    background: #27ae60;
    color: #fff;
}

.btn-write:hover {
    background: #219955;
}

/* 사이드바 영역 */
.sidebar-heading {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1a3a6d;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

/* 영상 출처 정보 */
.video-source {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
}

.source-content {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.source-platform {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    padding: 10px 15px;
    border-radius: 8px;
}

.source-platform.youtube {
    background: #f0f0f0;
    color: #ff0000;
}

.source-platform.vimeo {
    background: #f0f0f0;
    color: #1ab7ea;
}

.source-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #2a5298;
    text-decoration: none;
    padding: 8px 0;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

.source-link:hover {
    color: #1a3a6d;
    text-decoration: underline;
}

/* 관련 영상 목록 */
.related-videos-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.related-video-item {
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.related-video-item:hover {
    transform: translateY(-3px);
}

.related-video-link {
    display: flex;
    text-decoration: none;
    color: #333;
}

.related-thumbnail {
    position: relative;
    width: 120px;
    height: 68px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.related-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.related-video-item:hover .related-thumbnail img {
    transform: scale(1.05);
}

.related-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 30px;
    height: 30px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2a5298;
    font-size: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.related-info {
    padding: 0 0 0 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.related-title {
    font-size: 0.95rem;
    font-weight: 500;
    color: #333;
    line-height: 1.4;
    margin: 0 0 5px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-meta {
    display: flex;
    color: #888;
    font-size: 0.8rem;
    gap: 10px;
}

.related-views {
    display: flex;
    align-items: center;
    gap: 5px;
}

.empty-related {
    padding: 30px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: center;
    color: #888;
}

/* 반응형 스타일 */
@media (max-width: 991px) {
    .view-content-wrapper {
        grid-template-columns: 1fr;
    }

    .view-sidebar {
        order: -1;
    }

    .video-source {
        margin-bottom: 20px;
    }

    .related-videos-list {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 15px;
    }

    .related-video-link {
        flex-direction: column;
    }

    .related-thumbnail {
        width: 100%;
        height: 140px;
        margin-bottom: 10px;
    }

    .related-info {
        padding: 10px;
    }
}

@media (max-width: 768px) {
    .video-title {
        font-size: 1.5rem;
    }

    .video-info {
        flex-direction: column;
        align-items: flex-start;
    }

    .info-right {
        width: 100%;
        justify-content: space-between;
    }

    .post-navigation {
        grid-template-columns: 1fr;
    }

    .post-buttons {
        flex-direction: column;
        gap: 15px;
    }

    .post-buttons-left,
    .post-buttons-right {
        width: 100%;
        justify-content: center;
    }

    .post-buttons-right {
        flex-wrap: wrap;
    }

    .related-videos-list {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

@media (max-width: 576px) {
    .related-videos-list {
        grid-template-columns: 1fr;
    }

    .video-header-top {
        flex-direction: column;
        align-items: flex-start;
    }

    .attachments-list .attachment-link {
        flex-wrap: wrap;
    }

    .attachment-info {
        width: 100%;
        margin: 10px 0;
    }

    .attachment-meta {
        flex-direction: column;
        gap: 5px;
    }
}

/* 카테고리 */
.list-category { display: none; }
.list-wrap { width:100%; }
.list-btn-box { margin-bottom: 15px; }

/* 목록 공통 */
.list-wrap .list-container { margin-right:0; }
.list-none { margin:0px 0px 15px; padding:80px 0px; }
.list-page { margin-bottom:15px; }
.list-page .pagination { margin:0; }

/* 댓글 영역 디자인 */
.video-comments {
    margin-top: 50px;
    border-top: 1px solid #eee;
    padding-top: 40px;
}

.comments-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.comments-title {
    font-size: 1.2rem;
    color: #1a3a6d;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.comments-count {
    background: #f0f4ff;
    color: #2a5298;
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 0.9rem;
}

.comments-sort {
    display: flex;
    align-items: center;
    gap: 15px;
}

.sort-label {
    color: #888;
    font-size: 0.9rem;
}

.sort-options {
    display: flex;
    gap: 10px;
}

.sort-option {
    background: none;
    border: none;
    padding: 5px 10px;
    font-size: 0.9rem;
    cursor: pointer;
    color: #666;
    border-radius: 15px;
    transition: all 0.3s ease;
}

.sort-option:hover,
.sort-option.active {
    background: #f0f4ff;
    color: #2a5298;
}

/* 댓글 목록 */
.comment-list {
    margin-bottom: 30px;
}

.comment-item {
    padding: 20px 0;
    border-bottom: 1px solid #f0f0f0;
}

.comment-item:last-child {
    border-bottom: none;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
}

.comment-author {
    display: flex;
    align-items: center;
    gap: 10px;
}

.author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    background: #f0f4ff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2a5298;
    font-weight: 500;
}

.author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.author-info {
    display: flex;
    flex-direction: column;
}

.author-name {
    font-weight: 500;
    color: #333;
    margin-bottom: 2px;
}

.comment-date {
    font-size: 0.8rem;
    color: #888;
}

.comment-actions {
    display: flex;
    gap: 10px;
}

.comment-action {
    background: none;
    border: none;
    padding: 5px;
    color: #888;
    font-size: 0.85rem;
    cursor: pointer;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.comment-action:hover {
    color: #2a5298;
}

.comment-content {
    margin-bottom: 15px;
    color: #444;
    line-height: 1.6;
    font-size: 0.95rem;
}

.reply-tag {
    display: inline-block;
    padding: 3px 8px;
    background: #f0f4ff;
    color: #2a5298;
    border-radius: 4px;
    font-size: 0.85rem;
    margin-right: 8px;
    margin-bottom: 5px;
}

.comment-footer {
    display: flex;
    align-items: center;
    gap: 15px;
}

.comment-reactions {
    display: flex;
    gap: 10px;
}

.reaction-btn {
    background: #f8f9fa;
    border: none;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 5px;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
}

.reaction-btn:hover {
    background: #f0f4ff;
    color: #2a5298;
}

.reaction-btn.active {
    background: #f0f4ff;
    color: #2a5298;
}

.reply-btn {
    background: none;
    border: none;
    padding: 5px;
    color: #888;
    font-size: 0.85rem;
    cursor: pointer;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.reply-btn:hover {
    color: #2a5298;
}

/* 대댓글 영역 */
.replies {
    margin-left: 50px;
    border-left: 2px solid #f0f4ff;
    padding-left: 20px;
    margin-top: 15px;
}

.reply-item {
    padding: 15px 0;
    border-bottom: 1px solid #f0f0f0;
}

.reply-item:last-child {
    border-bottom: none;
}

/* 댓글 작성 폼 */
.comment-form-wrapper {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    margin-top: 30px;
}

.comment-form-header {
    margin-bottom: 15px;
}

.comment-form-title {
    font-size: 1.1rem;
    color: #1a3a6d;
    font-weight: 600;
    margin-bottom: 10px;
}

.comment-form {
    display: flex;
    flex-direction: column;
}

.comment-input-wrapper {
    margin-bottom: 15px;
    position: relative;
}

.comment-textarea {
    width: 100%;
    min-height: 120px;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    resize: vertical;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background-color: #fff;
}

.comment-textarea:focus {
    border-color: #2a5298;
    box-shadow: 0 0 0 3px rgba(42,82,152,0.1);
    outline: none;
}

.comment-length-info {
    position: absolute;
    right: 10px;
    top: 10px;
    background: rgba(255, 255, 255, 0.8);
    padding: 3px 8px;
    border-radius: 15px;
    font-size: 0.8rem;
    color: #666;
}

.comment-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.option-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #666;
    font-size: 0.9rem;
}

.option-checkbox {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.option-label {
    cursor: pointer;
}

.comment-submit {
    align-self: flex-end;
    background: #2a5298;
    color: #fff;
    border: none;
    padding: 10px 25px;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.comment-submit:hover {
    background: #1a3a6d;
    transform: translateY(-2px);
}

.comment-input-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

.comment-input {
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background-color: #fff;
}

.comment-input:focus {
    border-color: #2a5298;
    box-shadow: 0 0 0 3px rgba(42,82,152,0.1);
    outline: none;
}

.comment-error {
    color: #e74c3c;
    font-size: 0.85rem;
    margin-top: 5px;
}

.comment-input.error,
.comment-textarea.error {
    border-color: #e74c3c;
}

.comment-captcha {
    margin-bottom: 15px;
    background: #fff;
    border-radius: 8px;
    padding: 15px;
    border: 1px solid #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 10px;
}

.captcha-image {
    background: #f0f4ff;
    padding: 10px;
    border-radius: 8px;
}

.captcha-refresh {
    background: none;
    border: none;
    color: #2a5298;
    font-size: 0.9rem;
    cursor: pointer;
    padding: 5px 10px;
    transition: color 0.3s ease;
}

.captcha-refresh:hover {
    color: #1a3a6d;
    text-decoration: underline;
}

/* 댓글 로그인 안내 */
.comment-login-notice {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    margin-top: 30px;
}

.login-notice-icon {
    font-size: 2.5rem;
    color: #ddd;
    margin-bottom: 15px;
}

.login-notice-text {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.5;
}

.login-notice-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.login-btn {
    padding: 10px 25px;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.login-primary {
    background: #2a5298;
    color: #fff;
}

.login-primary:hover {
    background: #1a3a6d;
}

.login-secondary {
    background: #fff;
    color: #666;
    border: 1px solid #ddd;
}

.login-secondary:hover {
    background: #f5f5f5;
}

/* 댓글 없음 상태 */
.no-comments {
    text-align: center;
    padding: 50px 20px;
    color: #888;
}

.no-comments-icon {
    font-size: 3rem;
    color: #ddd;
    margin-bottom: 15px;
}

.no-comments-text {
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.no-comments-subtext {
    font-size: 0.9rem;
    color: #aaa;
}

/* 모바일 반응형 */
@media (max-width: 768px) {
    .comments-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .comment-input-row {
        grid-template-columns: 1fr;
    }

    .comment-header {
        flex-direction: column;
        gap: 10px;
    }

    .replies {
        margin-left: 20px;
        padding-left: 15px;
    }

    .login-notice-buttons {
        flex-direction: column;
    }
}

/* 애니메이션 효과 */
.comment-item, .reply-item {
    transform: translateY(0);
    opacity: 1;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.comment-item, .reply-item {
    animation: fadeIn 0.5s ease;
}

/* 호버 효과 개선 */
.comment-item:hover, .reply-item:hover {
    background-color: #fafafa;
    transition: background-color 0.3s ease;
}

/* 작성자 이름에 대한 추가 스타일 */
.author-name {
    position: relative;
    display: inline-block;
}

.author-name:after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #2a5298;
    transition: width 0.3s ease;
}

.author-name:hover:after {
    width: 100%;
}

/* 댓글 입력창 포커스 효과 */
.comment-textarea:focus {
    border-color: #2a5298;
    box-shadow: 0 0 10px rgba(42,82,152,0.15);
    transform: translateY(-2px);
    transition: all 0.3s ease;
}

/* 버튼 애니메이션 */
.comment-submit, .login-btn {
    position: relative;
    overflow: hidden;
}

.comment-submit:before, .login-btn:before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.5s, height 0.5s;
}

.comment-submit:hover:before, .login-btn:hover:before {
    width: 300px;
    height: 300px;
}

/* 댓글 글자수 카운터 스타일 */
#char_cnt {
    font-size: 0.8rem;
    color: #888;
    transition: color 0.3s ease;
}

#char_cnt.limit {
    color: #e74c3c;
}

/* 필터 버튼 관련 스타일 (baseline list.skin.php 인라인 스타일 복원) */
.filter-buttons-wrapper {
    position: relative;
    margin-bottom: 20px;
    background-color: #f9f9f9;
    border-radius: 10px;
    padding: 15px;
}

.filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    width: 100%;
}

.filter-btn {
    flex: 1 1 0;
    min-width: 0;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 8px 8px;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    max-width: 120px;
}

.filter-btn.active {
    background-color: #1a2a3a;
    color: white;
    border-color: #1a2a3a;
}

.filter-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 3px 5px rgba(0,0,0,0.15);
}

.filter-toggle-container {
    width: 100%;
    margin-top: 10px;
    text-align: center;
}

.filter-toggle-btn {
    background: transparent;
    color: #1a2a3a;
    padding: 8px 15px;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.filter-toggle-btn i {
    margin-right: 5px;
    transition: transform 0.3s ease;
}

.filter-toggle-btn:hover {
    background-color: #f5f5f5;
}

.filter-toggle-btn.active i {
    transform: rotate(180deg);
}

.filter-buttons-more {
    margin-top: 0px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    width: 100%;
}
