@charset "utf-8";

/* ------------------------------------------------------------
 * 1. 공통 유틸리티
------------------------------------------------------------ */
/* 폰트 */
.f-de { 
    font-family: 'Apple SD Gothic Neo', 'Malgun Gothic', '맑은 고딕', sans-serif;
}
.f-sm { font-size: 15px !important; }
.f-xs { font-size: 0.75rem !important; }
.btn-basic {
    padding-left: 0.5rem !important;
    padding-right: 0.5rem !important;
}

/* 스크랩 버튼 아이콘 색상 */
.btn-basic .fa-bookmark,
.btn-basic .fa-check-circle {
    color: #ff69b4;  /* 핑크색 */
}

.btn-basic .fa-question-circle {
    color: #6495ED;  /* 흐린 파란색 */
    opacity: 0.8;    /* 약간 투명하게 */
}

/* 텍스트 */
.text-break-all { word-break: break-all; }
.text-ellipsis {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 레이아웃 */
.nw-6 { min-width: 60px; }

/* ------------------------------------------------------------
 * 2. 게시글 보기
------------------------------------------------------------ */

/* 대표사진 */
.thumbnail-area {
    margin: 0 -15px 2rem -15px;
}

.thumbnail-area img {
    width: 100%;
    height: auto;
    display: block;
}

@media (min-width: 768px) {
    .thumbnail-area {
        margin: 0 auto 2rem;
        max-width: 800px;
    }
    
    .thumbnail-area img {
        width: 100%;
        height: auto;
    }
}

/* 게시글 제목 */
#bo_v_title {
    font-size: 1.8rem;
    font-weight: bold;
    line-height: 1.4;
    letter-spacing: -1px;
    margin: 1.5rem 0;  /* margin-bottom에서 상하단 여백으로 변경 */
}

/* 게시글 내용 */
#bo_v_con {
    min-height: 200px;
    word-break: break-all;
    overflow: hidden;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* 본문 내용에만 패딩 적용 */
#bo_v_con .view-content {
    padding-left: 15px;
    padding-right: 15px;
}

#bo_v_con img {
    max-width: 100%;
    height: auto;
}

/* 게시글 이미지 */
#bo_v_img {
    width: 100%;
    text-align: center;
    overflow: hidden;
}

#bo_v_img:after {
    display: block;
    visibility: hidden;
    clear: both;
    content: "";
}

#bo_v_img img { margin-bottom: 1.0rem; }

#imageViewModal .modal-xl {
    max-width: 90%;
}

#imageViewModal .modal-content {
    background-color: rgba(255,255,255,0.98);
}

#imageViewModal .modal-header {
    border: none;
    position: absolute;
    right: 0;
    z-index: 1;
}

#imageViewModal .close {
    font-size: 2rem;
    color: #000;
    text-shadow: none;
    opacity: 0.5;
}

#imageViewModal .close:hover {
    opacity: 1;
}

/* 모바일 모달창 중앙정렬 */
@media (max-width: 768px) {
    #imageViewModal .modal-dialog {
        margin: 0 auto;
    }
}

/* ------------------------------------------------------------
 * 3. 섹션 공통 스타일
------------------------------------------------------------ */
.card {
    border: 1px solid #edf2f7;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.card-header {
    padding: 1.25rem;
    background: linear-gradient(to right, #f8fafc, #ffffff);  /* 그라데이션 배경 */
    border-bottom: 2px solid #e2e8f0;  /* 더 진한 보더 */
}

.card-header h3 {
    font-size: 1.5rem;
    color: #2d3748;
    position: relative;
    padding-left: 1rem;
    display: inline-block;
}

.card-header h3::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 1.2em;
    background: #4a90e2;  /* 포인트 컬러 */
    border-radius: 2px;
}

.card-body {
    padding: 1.5rem;
}

/* 접기/펼치기 버튼 */
.toggle-section {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

.toggle-section i {
    margin-right: 0.25rem;
}

/* ------------------------------------------------------------
 * 3-1. 기본 정보 섹션
------------------------------------------------------------ */
/* 아이콘 박스 */
.basic-info-section .icon-box {
    width: 45px;
    height: 45px;
    background: #f8f9fa;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.basic-info-section .icon-box i {
    font-size: 1.5rem;
    color: #495057;
}

/* 요리 기본정보 */
.basic-info-row {
    font-size: 1.3rem;
}

/* PC에서 라벨 영역 너비 설정 */
.basic-info-row .text-muted {
    width: 60px !important;
    margin-right: 10px !important;
    white-space: nowrap;
}

.info-label {
    font-size: 1.3rem;
    color: #6c757d;
}

.info-value {
    font-size: 1.4rem;
    color: #2d3748;
    font-weight: 500;
}

/* 요리 설명 텍스트 */
.recipe-desc-text {
    font-size: 1.4rem;
    line-height: 1.8;
    color: #333;
    word-break: keep-all;
    word-wrap: break-word;
    padding: 0.5rem 0;
}

/* 모바일 대응 */
@media (max-width: 767px) {
    .basic-info-row {
        justify-content: space-between;
        font-size: 1.2rem;
    }
    /* 준비시간, 요리시간 영역 50:50 설정 */
    .info-item {
        flex: 0 0 50% !important;
        max-width: 50%;
        padding: 0 5px;
    }
    /* 아이콘과 텍스트 영역 조정 */
    .basic-info-row .icon-box {
        width: 20px !important;
        height: auto !important;
        margin-right: 8px !important;
        background: none;
    }
    /* 모바일 라벨 영역 설정 유지 */
    .basic-info-row .text-muted {
        width: 60px !important;
        margin-right: 8px !important;
    }
    .info-label {
        font-size: 1.2rem;
    }
    .info-value {
        font-size: 1.3rem;
    }
    .recipe-desc-text {
        font-size: 1.3rem;
        line-height: 1.7;
    }
    /* 상위 여백 제거 */
    .basic-info-row > div {
        padding: 0 5px;
    }
}

/* ------------------------------------------------------------
 * 4. 재료 정보 섹션
------------------------------------------------------------ */
/* 재료 그룹 */
.material-group {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #edf2f7;
}
.material-group:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

/* 그룹 타이틀 */
.material-group h4 {
    font-size: 1.3rem;
    color: #2d3748;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #4a5568;
}

/* 인분 표시 및 변환 효과 */
.material-group .serving-text {
    position: relative;
    display: inline-block;
    font-size: 1.1rem;
}

.material-group .original-serving {
    position: relative;
    display: inline-block;
}

.material-group .serving-text.converted .original-serving {
    color: #a0aec0;
}

.material-group .serving-text.converted .original-serving:before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    border-top: 1px solid #e53e3e;
    transform: rotate(-5deg);
}

.material-group .convert-text {
    color: #2d3748;
    font-weight: 500;
}

/* 인분 조절 컨트롤 - 크기 축소 */
.serving-controls {
    margin-bottom: 1.25rem;  /* 여백 축소 */
}

.serving-controls .btn-light {
    border-radius: 50%;
    width: 36px;      /* 크기 축소 */
    height: 36px;     /* 크기 축소 */
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #e2e8f0;
    background-color: #fff;
    transition: all 0.2s ease;
}

.serving-controls .btn-light:hover {
    background-color: #f7fafc;
    border-color: #cbd5e0;
}

.serving-controls .btn-light:active {
    background-color: #edf2f7;
}

.serving-controls .current-serving {
    min-width: 70px;  /* 크기 축소 */
    text-align: center;
    font-size: 1.1rem;  /* 크기 축소 */
    color: #2d3748;
}

.serving-controls .serving-value {
    font-weight: 600;
    font-size: 1.25rem;  /* 크기 축소 */
    color: #4a5568;
}

.serving-controls .fa-lg {
    font-size: 1.5em;  /* 크기 축소 */
    color: #4299e1;
}

.serving-controls .reset-btn {
    padding: 0.35rem 0.75rem;  /* 패딩 축소 */
    font-size: 0.95rem;        /* 크기 축소 */
    font-weight: 500;
}

/* 재료 테이블 */
.material-table {
    margin-bottom: 1rem;
    border: none;
}

.material-table th,
.material-table td {
    padding: 0.75rem 1rem;
    vertical-align: middle;
    font-size: 1.2rem;    /* 기본 폰트 크기 증가 */
    line-height: 1.4;
    border: none;
    border-bottom: 1px solid #edf2f7;
}

.material-table th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;     /* 제목 강조 */
    font-size: 1.15rem;   /* 제목 폰트 크기 증가 */
}

.material-table tr:hover {
    background-color: #f8f9fa;
}

/* 재료 테이블 셀 너비 및 스타일 - 폰트 크기 증가 */
.material-name-cell { 
    width: 30%;
    color: #2d3748;
    font-weight: 500;
    font-size: 1.15rem;   /* 재료명 크기 증가 */
}

.material-amount-cell { 
   width: 12%; 
   text-align: right;
   color: #4a5568;
   font-weight: 600;
   font-size: 1.15rem;    /* 수량 크기 증가 */
}        

.material-unit-cell { 
   width: 12%; 
   text-align: left;
   color: #718096;
   font-size: 1.1rem;     /* 단위 크기 증가 */
}          

.material-gml-cell { 
   width: 12%; 
   text-align: right;
   color: #4a5568;
   font-weight: 600;
   font-size: 1.15rem;    /* 계량 크기 증가 */
}           

.material-gml-unit-cell { 
   width: 12%; 
   text-align: left;
   color: #718096;
   font-size: 1.1rem;     /* 계량 단위 크기 증가 */
}      

.material-note-cell { 
    width: 22%;
    color: #718096;
    font-size: 1.1rem;    /* 비고 크기 증가 */
}

/* 그룹 메모 */
.group-memo {
    margin-top: 0.50rem !important;
    padding: 1.25rem;
    background-color: #f8fafc;
    border-radius: 0.5rem;
    font-size: 1rem;
    border-left: 3px solid #e2e8f0;
    color: #718096;
    line-height: 1.6;
}

/* 재료 정보 */
.material-name-cell { width: 34%; }      /* 유지 */
.material-amount-cell { 
   width: 14%; 
   text-align: right;    /* 우측 정렬 */
}     
.material-unit-cell { 
   width: 15%;
   text-align: left;     /* 좌측 정렬 */
}       
.material-gml-cell { 
   width: 14%;
   text-align: right;    /* 우측 정렬 */
}        
.material-gml-unit-cell { 
   width: 12%;
   text-align: left;     /* 좌측 정렬 */
}   
.material-note-cell { width: 11%; }       /* 수정 */

/* 재료 테이블 모바일 스타일 */
@media (max-width: 768px) {
    .material-name-cell { width: 26% !important; }
    .material-amount-cell { width: 18% !important; }
    .material-unit-cell { width: 20% !important; }
    .material-gml-cell { width: 18% !important; }
    .material-gml-unit-cell { width: 18% !important; }
}

/* ------------------------------------------------------------
 * 5. 추가 정보 섹션
------------------------------------------------------------ */
.info-items {
    border-top: 1px solid #dee2e6;
}
.info-item {
    border-bottom: 1px solid #dee2e6;
}
.info-title .bg-light {
    font-weight: 500;
    font-size: 1.2rem;
}
.info-content {
    font-size: 1.2rem;
}
@media (max-width: 767.98px) {
    .info-title {
        min-width: 120px;
        flex: 0 0 35%;
    }
    .info-title .bg-light {
        background-color: #f8fafc !important;
        padding: 0.5rem 1rem;
        width: 100%;
    }
    .info-item .row {
        min-width: 100vw;
        display: flex;
        align-items: center;
    }
    .info-content {
        flex: 0 0 65%;
    }
}

/* ------------------------------------------------------------
 * 6. 사진 정보 섹션
------------------------------------------------------------ */

/* 6-1. 단계 번호 */
.step-number {
    position: absolute;
    top: 0;
    left: 0;
    background: rgba(255, 182, 193, 0.9);
    color: white;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding-left: 15px;
    font-size: 1.5rem;
    font-weight: bold;
    border-radius: 0 0 10px 0;
    z-index: 1;
}

.photo-content .step-number {
    position: relative;
    display: inline-block;
    margin-bottom: 0.5rem;
}

/* 6-2. 썸네일 관련 스타일 */
.additional-photos {
    display: grid;
    gap: 8px;
    margin-top: 10px;
}

.thumbnail-container {
    position: relative;
    padding-top: 100%;
    border-radius: 4px;
    overflow: hidden;
}

.thumbnail-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 썸네일 레이아웃 - 웹진형 */
.photo-webzine .additional-photos,
.photo-webzine-modal .additional-photos {
    width: 100%;
    grid-template-columns: repeat(4, 1fr);
    margin-left: 0;
}

/* 썸네일 레이아웃 - 갤러리형 */
.photo-gallery .additional-photos,
.photo-gallery-modal .additional-photos {
    width: 100%;
    grid-template-columns: repeat(8, 1fr);
    margin-left: 0;
}

/* 6-3. 레이아웃 보기 옵션 */
.view-options {
    display: flex;
    gap: 0.5rem;
}

.view-options .btn {
    padding: 0.375rem 0.75rem;
}

.view-options .btn.active {
    background-color: #3182ce !important;
    border-color: #3182ce !important;
    color: #fff;
}

/* 6-4. 기본 레이아웃 스타일 */
.photo-layout {
    display: none;
}

.photo-layout.active {
    display: block;
}

/* 6-5. 웹진형 레이아웃 */
.photo-webzine .webzine-item {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
    padding: 1.5rem 0.5rem;
    border-bottom: 1px solid #edf2f7;
}

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

.photo-webzine .photo-image {
    flex: 0 0 40%;
    max-width: 40%;
    position: relative;
}

.photo-webzine .photo-content {
    flex: 1;
    min-width: 0;
}

.photo-webzine .webzine-item.no-image {
    display: block;
    padding: 1.5rem 0.5rem;
}

.photo-webzine .webzine-item.no-image .photo-content {
    width: 100%;
    max-width: 100%;
}

/* 6-6. 갤러리형 레이아웃 */
.photo-gallery .photo-item {
    position: relative;
    margin-bottom: 2rem;
}

.photo-gallery .photo-image {
    position: relative;
    margin-bottom: 1rem;
}

.photo-gallery .photo-content {
    text-align: center;
    padding: 0 0.5rem;
}

/* 6-7. 텍스트형 레이아웃 */
.photo-text .text-item {
    padding: 1.5rem 0.5rem;
    border-bottom: 1px solid #edf2f7;
    font-size: 1.2rem;
}

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

/* 6-8. 텍스트 컨텐츠 스타일 */
.photo-name {
    font-size: 1.8rem;
    font-weight: normal;
    color: #000000;
    margin: 1rem 0 1rem 0.5rem;
    line-height: 1.5;
    text-align: left;
}

.photo-title {
    font-size: 1.3rem;
    color: #4a5568;
    margin-bottom: 0.75rem;
    line-height: 1.5;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.photo-desc {
    position: relative;
    background: linear-gradient(135deg, #e3f2fd 0%, #e0f7fa 100%);
    border-radius: 12px;
    padding: 1rem 1.2rem 1rem 3rem;
    margin: 1rem 0.5rem;
    font-size: 1.1rem;
    line-height: 1.6;
    color: #37474f;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    text-align: left;
}

.photo-desc::before {
    content: "";
    position: absolute;
    left: -10px;
    top: 15px;
    border-style: solid;
    border-width: 10px 10px 10px 0;
    border-color: transparent #e3f2fd transparent transparent;
}

.photo-desc::after {
    content: "\f0eb";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    position: absolute;
    left: 1rem;
    top: 1.1rem;
    color: #ffa726;
    font-size: 1.2rem;
}

.photo-desc:hover {
    background: linear-gradient(135deg, #d4e9fc 0%, #d0f2f5 100%);
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

/* 6-9. 컨트롤 버튼 */

/* 6-9-1. 컨트롤 컨테이너 */
.photo-controls {
    display: inline-flex;
    align-items: center;
    background: #f7fafc;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    gap: 0.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* 6-9-2. 버튼 공통 스타일 */
.photo-controls .btn-link {
   position: relative;
   min-width: 50px;
   height: 32px; 
   padding: 0 15px;
   border-radius: 6px;
   border: none;
   transition: all 0.3s ease;
   display: flex;
   align-items: center;
   justify-content: center;
   text-decoration: none !important;
   gap: 6px;
   color: #fff;
}

.photo-controls .btn-link:hover,
.photo-controls .btn-link:focus {
   text-decoration: none !important; 
}

/* 6-9-3. 플레이 버튼 */
.play-time {
    background: #4a5568;
}

.play-time:hover {
    background: #2d3748;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.play-time:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(74, 85, 104, 0.3);
}

.play-time i {
    color: white;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.play-time i.fa-play {
    margin-left: 2px;
}

/* 6-9-4. 영상 보기/감추기 버튼 */
.photo-controls .video-visibility-toggle {
   background: #ff8fb1;
   min-width: 100px;
}

.video-visibility-toggle:hover {
   background: #ff6b8b;
   transform: translateY(-1px);
   box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.video-visibility-toggle:focus {
   outline: none;
   box-shadow: 0 0 0 2px rgba(255, 182, 193, 0.3);
}

.video-visibility-toggle i {
   color: #fff;
}

.video-visibility-toggle.active {
   background: #ff4d79;
}

/* 6-10. 모달 관련 스타일 */
/* 6-10-1. 텍스트모드 비디오 */
.video-timer-wrapper.modal-text-mode {
   position: fixed !important;
   top: 0;
   left: 0;
   right: 0;
   z-index: 1060 !important;
   background: #000;
   width: 100%;
   margin: 0;
   padding: 0;
   box-shadow: none;
}

.modal.text-mode-active {
   display: block !important;
   align-items: initial !important;
}

.modal.text-mode-active .modal-dialog.modal-dialog-centered {
   position: relative !important;
   transform: none !important;
   margin: 10px auto !important;
}

/* 6-10-2. 모달 기본 스타일 */
#photoViewModal .modal-dialog {
   max-width: 80%;
   width: 1000px;
   margin: 40px auto;
}

#photoViewModal .modal-content {
   background-color: #ffffff;
   border: none;
   border-radius: 1rem;
   overflow: hidden;
}

#photoViewModal .modal-header {
   padding: 1rem 1.5rem;
   background: #f8fafc;
   border-bottom: 1px solid #edf2f7;
}

/* 6-10-3. 모달 레이아웃 옵션 */
.modal-view-options {
   display: flex;
   gap: 0.5rem;
}

.modal-view-options .btn {
   padding: 0.375rem 0.75rem;
}

.modal-view-options .btn.active {
   background-color: #3182ce !important;
   border-color: #3182ce !important;
   color: #fff;
}

/* 6-10-4. 모달 레이아웃 컨테이너 */
.photo-layout-modal {
   display: none;
   padding: 1.5rem;
}

.photo-layout-modal.active {
   display: block;
}

/* 6-10-5. 모달 웹진형 레이아웃 */
.photo-webzine-modal .webzine-item {
   display: flex;
   gap: 2rem;
   align-items: flex-start;
}

.photo-webzine-modal .photo-image {
   flex: 0 0 40%;
   max-width: 40%;
   position: relative;
}

.photo-webzine-modal .photo-content {
   flex: 1;
   padding: 0;
}

/* 6-10-6. 모달 갤러리형 레이아웃 */
/* 기본 레이아웃 */
.photo-gallery-modal .gallery-item {
   position: relative;
   text-align: center;
   padding: 1rem;
}

.photo-gallery-modal .photo-image {
   position: relative;
   margin-bottom: 1.5rem;
}

/* Swiper 관련 */
.photo-gallery-modal .swiper-slide {
   transition: opacity 0.3s ease;
   opacity: 0 !important;
   box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.photo-gallery-modal .swiper-slide-active {
   opacity: 1 !important;
   box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

.photo-gallery-modal .gallerySwiper {
   background-color: rgba(0,0,0,0.03);
   padding: 20px 0;
}

/* 제목과 컨트롤 영역 */
.photo-gallery-modal .photo-title {
   justify-content: flex-start;
}

.photo-gallery-modal .photo-title .photo-controls {
   display: inline-flex;
   align-items: center;
   background: #f7fafc;
   padding: 0.5rem 1rem;
   border-radius: 8px;
   box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
   gap: 0.5rem;
   font-size: 1.1rem;
   justify-content: flex-start;
}

/* 컨트롤 버튼 스타일 유지 */
.photo-gallery-modal .photo-controls .btn-link {
   position: relative;
   min-width: 50px;
   height: 32px;
   padding: 0 15px;
   border-radius: 6px;
   border: none;
   transition: all 0.3s ease;
   display: flex;
   align-items: center;
   justify-content: center;
}

.photo-gallery-modal .photo-controls .video-visibility-toggle {
   min-width: 100px;
}

/* 반응형 대응 */
@media (max-width: 768px) {
   .photo-gallery-modal .photo-title .photo-controls {
       padding: 0.4rem 0.75rem;
       font-size: 1rem;
   }
}

/* 6-10-7. 모달 텍스트형 레이아웃 */
.photo-text-modal .text-item {
   padding: 2rem;
   font-size: 1.2rem;
}

/* 6-10-8. Swiper 네비게이션 */
.swiper-button-next,
.swiper-button-prev {
   color: #4a5568;
}

.swiper-button-next:after,
.swiper-button-prev:after {
   font-size: 1.5rem;
}

.swiper-pagination-bullet {
   background: #cbd5e0;
}

.swiper-pagination-bullet-active {
   background: #4a5568;
}

/* 6-11-1. 데스크탑 */
@media (min-width: 800px) {
    .modal {
        padding-top: calc(50vh) !important; /* 웹진형/갤러리형 위치 조정 */
    }
    
    .modal.text-mode-active {
        padding-top: calc(56.25vh - 50px) !important;
    }
}

/* 6-11-2. 태블릿 & 모바일 공통 */
@media (max-width: 768px) {
  /* 카드 영역 */
  #photo-info-content.card-body {
      padding: 5px;
  }
  /* 순서 번호 */
  .step-number {
      width: 60px;
      height: 60px;
      font-size: 1.8rem;
  }
  /* 레이아웃 & 여백 */
  .photo-webzine .webzine-item,
  .photo-text .text-item {
      padding: 1.5rem 0;
  }
  .photo-gallery .photo-content {
      padding: 0;
  }
  /* 컨트롤 버튼 */
  .photo-controls {
      padding: 0.5rem 0.75rem;
      gap: 0.5rem;
  }
  .photo-controls .btn-link {
      min-width: 42px;
      height: 32px;
  }
  .photo-controls .video-visibility-toggle,
  .photo-controls .video-expand-toggle {
      min-width: 90px;
      font-size: 0.9rem;
  }
  .photo-controls .btn-link i {
      font-size: 0.9rem;
  }
  /* 모달 창 */
  #photoViewModal .modal-dialog {
      max-width: 100%;
      width: 100%;
      margin: 20px 0;
  }
  #photoViewModal .modal-content {
      border-radius: 0;
  }
  .photo-layout-modal {
      padding: 0;
  }
  .photo-webzine-modal .webzine-item,
  .photo-gallery-modal .gallery-item,
  .photo-text-modal .text-item {
      padding: 1rem 0;
  }
  
  /* 팝업 웹진형 이미지 영역 수정 */
  .photo-webzine-modal .photo-image {
      flex: 0 0 45%;
      max-width: 45%;
      display: block !important;
      position: relative;
  }
  
  /* 팝업 웹진형 이미지 스타일 */
  .photo-webzine-modal .photo-image img {
      width: 100%;
      height: auto;
      display: block !important;
      max-width: 100%;
  }
  
  /* Swiper 슬라이더 관련 스타일 수정 */
  .photo-webzine-modal .swiper-slide {
      overflow: visible !important;
  }
  
  .photo-webzine-modal .webzineSwiper {
      overflow: visible !important;
  }
  
  .photo-webzine-modal .swiper-wrapper {
      display: flex !important;
  }
  
  /* 슬라이더 내부 컨텐츠 표시 확인 */
  .photo-webzine-modal .swiper-slide-active {
      visibility: visible !important;
      opacity: 1 !important;
  }
  
  /* 텍스트 크기 */
  .photo-name { font-size: 1.5rem; }
  .photo-title { font-size: 1.5rem; }
  .photo-desc { font-size: 1.2rem; }
  /* 텍스트모드 비디오 */
  .video-timer-wrapper.modal-text-mode {
      padding: 0;
  }
  
  .modal {
      padding-top: calc(50vh) !important;
  }
  
  .modal.text-mode-active {
      padding-top: calc(56.25vw + 70px) !important;
  }
  
  .modal.text-mode-active .modal-dialog.modal-dialog-centered {
      margin: 0 5px !important;
  }
  
  /* 초기화 버튼 텍스트 숨기기 */
  .control-btn.reset-time .reset-text {
      display: none;
  }
  
  /* 아이콘 마진 제거 */
  .control-btn.reset-time .me-1 {
      margin-right: 0 !important;
  }
}

/* 6-11-3. 모바일 전용 */
@media (max-width: 480px) {
   /* 레이아웃 간격 */
   .photo-webzine .webzine-item,
   .photo-webzine-modal .webzine-item {
       gap: 0.75rem;
   }
   .photo-webzine .photo-image,
   .photo-webzine-modal .photo-image {
       flex: 0 0 40%;
       max-width: 40%;
   }
   /* 순서 번호 */
   .step-number {
       width: 30px;
       height: 30px;
       font-size: 1rem;
   }
   /* 컨트롤 영역 */
   .photo-controls {
       padding: 0.4rem 0.6rem;
       gap: 0.35rem;
   }
   /* 모바일에서도 버튼 텍스트 표시 */
   .view-options .btn span,
   .toggle-text {
       display: inline;
       font-size: 0.85rem;
   }
   .view-options .btn i {
       margin-right: 4px;
   }
}

/* ------------------------------------------------------------
* 7. 출처 정보 섹션
------------------------------------------------------------ */
.source-group {
   margin-bottom: 0.5rem;  /* 1rem -> 0.5rem */
   padding-bottom: 0.5rem; /* 1rem -> 0.5rem */
   border-bottom: 1px solid #edf2f7;
}
.source-group:last-child {
   margin-bottom: 0;
   padding-bottom: 0;
   border-bottom: none;
}
.source-row {
   display: flex;
   flex-wrap: nowrap;
   align-items: baseline;
   gap: 0.5rem;  /* 0.75rem -> 0.5rem */
   padding: 0.25rem 0;  /* 0.5rem -> 0.25rem */
}
.source-title {
   width: 30%;
   font-size: 1.1rem;
   color: #2d3748;
   font-weight: 500;
}
.source-content {
   display: flex;
   flex-wrap: wrap;
   align-items: center;
   gap: 0.5rem;  /* 0.75rem -> 0.5rem */
}
.source-name {
   font-size: 1.1rem;
   color: #4a5568;
}
.source-url {
   color: #4a5568;
   font-size: 1.1rem;
}
.source-url:hover {
   color: #2d3748;
}
.source-thanks {
   width: 100%;
   margin-top: 0.15rem;  /* 0.25rem -> 0.15rem */
   font-size: 1rem;
   color: #718096;
}

/* ------------------------------------------------------------
 * 8. 반응형 스타일
------------------------------------------------------------ */
@media (max-width: 768px) {
    /* 제목과 글자크기 버튼 */
    #bo_v header .d-flex.justify-content-between.align-items-center {
        flex-direction: column;
        align-items: flex-end !important;  /* 버튼들 우측 정렬 유지 */
    }

    #bo_v_title {
        font-size: 1.5rem;
        width: 100%;
        margin: 1rem 0;
    }

    /* 비고 아이콘 */
    .note-cell {
        position: relative;
    }
    
    .note-icon {
        cursor: pointer;
        color: #666;
        padding: 8px;
    }
    
    .note-icon:hover {
        color: #333;
    }

.material-table th,
.material-table td {
   padding: 0.5rem;
   font-size: 1.05rem;
}
    /* 사진 정보 헤더 */
    .card-header {
        padding: 1rem;
    }

    .card-header h3 {
        font-size: 1.3rem;
        margin-bottom: 1rem;
    }

    .view-options {
        flex-wrap: wrap;
        justify-content: flex-start;
        gap: 0.25rem;
    }

    /* 웹진형 레이아웃 유지 */
    .photo-webzine .webzine-item {
        flex-direction: row;
        gap: 1rem;
        padding: 1rem 0;
    }

    .photo-webzine .photo-image {
        flex: 0 0 45%;
        max-width: 45%;
    }

    .photo-webzine .photo-content {
        flex: 1;
        padding: 0;
    }

    /* 모달 */
    #photoViewModal .modal-dialog {
        margin: 0.5rem;
    }

    #photoViewModal .modal-header {
        padding: 0.75rem 1rem;
    }

    .modal-view-options {
        flex-wrap: wrap;
        gap: 0.25rem;
    }

    /* 모달 내 웹진형 유지 */
    .photo-webzine-modal .webzine-item {
        flex-direction: row;
        gap: 1rem;
    }

    .photo-webzine-modal .photo-image {
        flex: 0 0 45%;
        max-width: 45%;
    }
   
    /* 사진 설명 텍스트 */
    .photo-name { font-size: 1.3rem; }
    .photo-title { font-size: 1.1rem; }
    .photo-desc { font-size: 0.95rem; }

    /* 순서 숫자 크기 조정 */
    .step-number {
        width: 35px;
        height: 35px;
		font-size: 1.1rem;
    }
}

/* 더 작은 화면에서의 추가 조정 */
@media (max-width: 480px) {
    .photo-webzine .webzine-item,
    .photo-webzine-modal .webzine-item {
        gap: 0.75rem;
    }

    .photo-webzine .photo-image,
    .photo-webzine-modal .photo-image {
        flex: 0 0 40%;
        max-width: 40%;
    }

    /* 순서 숫자 더 작게 */
    .step-number {
        width: 30px;
        height: 30px;
        font-size: 1rem;
    }

    /* 버튼 텍스트 숨김 */
    .view-options .btn span {
        display: none;
    }

    .view-options .btn i {
        margin: 0;
    }
}

/* ------------------------------------------------------------
 * 8-1. 태그 영역 스타일
------------------------------------------------------------ */
#tagSearchType {
    min-width: 50px;
    padding: 0.25rem 0.5rem;
    font-weight: bold;
}

.btn-group > .btn-sm {
    font-size: 0.875rem;
}

/* 모바일에서 버튼 간격 조정 */
@media (max-width: 575.98px) {
    .btn-group {
        gap: 0.1rem;
    }
    #tagSearchType {
        margin-left: 0.3rem;
        margin-right: 0.3rem;
    }
}

/* ------------------------------------------------------------
 * 9. 댓글 영역 스타일
------------------------------------------------------------ */
/* 게시판 댓글 : 작성자 표시 */
.by-writer { 
    background:#fbefef !important;
    border-top:1px solid #f6cece !important;
}

/* 게시판 댓글 : 버튼 영역 */
.cmt-btn ul { 
    list-style: none; 
    margin: 0; 
    display: flex;
    align-items: center;
}

.cmt-btn ul > li { 
    float: left; 
    font-size: 15px;
    padding: 0 10px; 
    position: relative;
}

.cmt-btn ul > li::before { 
    float: left; 
    color: #ccc; 
    content: "|"; 
    margin-left: -12px;
}

.cmt-btn ul > li:first-child::before, 
.cmt-btn ul > li.no-bar::before { 
    content: ""; 
    margin-left: 0; 
}

.cmt-btn ul > li > a { 
    float: left;
    color: #888;
    white-space: nowrap;    
}

/* 댓글 쓰기폼 */
#bo_vc_w {
    max-width: var(--theme-width, 1100px);
    margin: 0 auto;
    padding: 0 var(--theme-padding, 15px);
}

.cmt-form {
    width: 100%;
}

/* 입력폼 그룹 스타일 */
.cmt-form .input-group {
    display: flex !important;
    align-items: stretch !important;
    width: 100% !important;
}

.cmt-form #wr_content { 
    resize: none;
    min-height: 100px;
    width: 100% !important;
    flex: 1 !important;
}

.cmt-form .input-group-append {
    display: flex !important;
    width: auto !important;
    margin-left: -1px !important;
}

.cmt-form .input-group-append .btn { 
    height: 100px !important;
    white-space: nowrap !important;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
}

/* 체크박스 영역 */
.custom-checkbox {
    width: auto !important;
}

/* 별점 관련 스타일 */
.star-rating {
    display: inline-flex;
    align-items: center;
    margin-right: 1rem;
}

.star-rating .stars {
    color: #ff9900;
    margin-right: 0.5rem;
}

.star-rating .score {
    font-weight: bold;
    color: #666;
}

.star-select {
    position: relative;
}

.star-select select {
    padding-left: 2rem;
}

.star-select:before {
    content: "★";
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: #ff9900;
    pointer-events: none;
}

.comment-stars {
    color: #ff9900;
    margin-right: 0.5rem;
    font-size: 1.1em;
}

/* 토글 버튼 스타일 */
.toggle-btn.active {
    color: #ff4500 !important;
    font-weight: bold;
}

/* 댓글 내용 영역 */
.cmt-content {
    padding: 15px;
    background: #fff;
}

/* 기본 댓글 영역 */
#bo_vc {
    max-width: var(--theme-width, 1100px);
    margin: 0 auto;
    padding: 0 var(--theme-padding, 15px);
}

/* 나만보기/공지 댓글 스타일 */
.notice-comment {
    background-color: #fff8dc !important;
    border-left: 3px solid #ffd700 !important;
    margin-top: 1rem !important;
    padding: 0.5rem !important;
}

.private-comment {
    background-color: #f0f8ff !important;
    border-left: 3px solid #1e90ff !important;
    margin-top: 0.5rem !important;
    padding: 0.5rem !important;
}

/* 댓글폼 애니메이션 */
.bo_vc_w {
    transition: all 0.3s ease-in-out;
}

/* 반응형 처리 */
@media (max-width: 991px) {
    #bo_vc_w {
        padding: 0 10px;
    }
}

@media (max-width: 767px) {
    .cmt-form .input-group {
        display: flex !important;
        flex-direction: row !important;
    }

    .cmt-form #wr_content {
        width: 100% !important;
        flex: 1 !important;
    }

    .cmt-form .input-group-append {
        width: auto !important;
        margin-left: -1px !important;
        margin-top: 0 !important;
    }

    .cmt-form .input-group-append .btn {
        height: 100px !important;
        width: auto !important;
    }
}

@media (max-width: 575px) {
    .cmt-box {
        border-right: 0 !important;
    }
    #bo_vc_w .cmt-box {
        border-left: 0 !important;
        border-radius: 0 !important;
    }
    #bo_vc_login {
        border-left: 0 !important;
        border-right: 0 !important;
        border-radius: 0 !important;
    }

    /* 체크박스 영역 여백 조정 */
    .custom-checkbox {
        margin-right: 1rem !important;
    }
}

/* 별점 요약 */
.rating-summary {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

/* ------------------------------------------------------------
 * 10. 모달 공통 스타일
------------------------------------------------------------ */
/* 모달 백드롭 배경색 설정 */
.modal-backdrop {
    background-color: rgba(0, 0, 0, 0.3); /* 검은색 배경에 30% 불투명도 */
}

.modal-backdrop.show {
    opacity: 0.3;
}

/* 스크랩 모달창 스타일 */
#scrapStatusModal .modal-content,
#scrapHelpModal .modal-content {
    background-color: #ffffff;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
}

/* ------------------------------------------------------------
 * 11. 모달 내부 콘텐츠 스타일 격리
------------------------------------------------------------ */
/* 본문 내 재료 사진 영역 스타일 보존 */
#bo_v_con .material-photos-container {
    margin-bottom: 1.5rem;
}

#bo_v_con .material-photo-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) !important;
    gap: 10px !important;
}

#bo_v_con .material-photo-item {
    position: relative !important;
    padding-top: 100% !important;
    overflow: hidden !important;
    border-radius: 4px !important;
    cursor: pointer !important;
}

#bo_v_con .material-photo-item img {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
}

/* 모달 콘텐츠 스타일 격리 */
#bo_v_con .material-edit-modal .modal-dialog {
    background: #fff !important;
}

#bo_v_con .material-edit-modal .modal-body,
#bo_v_con .material-view-modal .modal-body {
    min-height: auto !important;
    word-break: normal !important;
    overflow: visible !important;
    background: #fff !important;
}

#bo_v_con .material-edit-modal .nav-tabs,
#bo_v_con .material-view-modal .nav-tabs {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    border-bottom: 2px solid #edf2f7 !important;
    background: #fff !important;
    margin-bottom: 1.5rem !important;
    position: relative !important;
}

#bo_v_con .material-edit-modal .nav-item,
#bo_v_con .material-view-modal .nav-item {
    display: inline-block !important;
    width: auto !important;
    flex: 0 0 auto !important;
    margin-bottom: 0 !important;
}

/* 모바일 대응 */
@media (max-width: 767px) {
    #bo_v_con .material-photo-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)) !important;
    }

    #bo_v_con .material-edit-modal .modal-content,
    #bo_v_con .material-view-modal .modal-content {
        background: #fff !important;
    }
}
