.intro-images-section {
    padding: 16px 0;
    border-bottom: 1px solid #f0f0f0;
}

.intro-images-slider {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 8px 0;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.intro-images-slider::-webkit-scrollbar {
    height: 4px;
}

.intro-images-slider::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 2px;
}

.intro-images-slider::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 2px;
}

.intro-images-slider::-webkit-scrollbar-thumb:hover {
    background: #999;
}

.intro-image-item {
    flex: 0 0 150px;
    height: 150px;
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    scroll-snap-align: start;
    cursor: pointer;
    transition: transform 0.2s;
}

.intro-image-item:hover {
    transform: scale(1.02);
}

.intro-image-item a {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.intro-image-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.intro-image-item:hover img {
    transform: scale(1.05);
}

.lightbox .lb-image {
    border: 0 !important;
}

/* 업체 소개 이미지 섹션 스타일 */
.intro-images-section {
    padding: 16px 0;
    border-bottom: 1px solid #f0f0f0;
}

.intro-images-slider {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 8px 0;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.intro-images-slider::-webkit-scrollbar {
    height: 4px;
}

.intro-images-slider::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 2px;
}

.intro-images-slider::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 2px;
}

.intro-images-slider::-webkit-scrollbar-thumb:hover {
    background: #999;
}

.intro-image-item {
    flex: 0 0 150px;
    height: 150px;
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    scroll-snap-align: start;
    cursor: pointer;
    transition: transform 0.2s;
}

.intro-image-item:hover {
    transform: scale(1.02);
}

.intro-image-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 반응형 대응 */
@media (max-width: 768px) {
    .modal-close {
        top: -40px;
        font-size: 20px;
    }

    .nav-btn {
        font-size: 20px;
        padding: 12px 15px;
    }

    .prev-btn {
        margin-left: -50px;
    }

    .next-btn {
        margin-right: -50px;
    }

    .modal-counter {
        bottom: -40px;
        font-size: 12px;
        padding: 6px 12px;
    }
}

.profile-view h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

/* 프로필 수정 페이지 스타일 */
.profile-edit-page {
    margin: 0 auto;
    background: #fff;
    min-height: 100vh;
    padding-bottom: 60px;
}

/* 상단 헤더 */
.profile-edit-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #fff;
    border-bottom: 1px solid #eee;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.back-button {
    background: none;
    border: none;
    font-size: 20px;
    color: #333;
    cursor: pointer;
    padding: 8px;
    margin: -8px;
}

.profile-edit-header h1 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    flex: 1;
    text-align: center;
}

.header-space {
    width: 36px;
}

/* 폼 섹션 */
.form-section {
    padding: 20px 16px;
    border-bottom: 8px solid #f5f5f5;
}

.form-section h3 {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 12px 0;
    color: #333;
}

.form-section .description {
    font-size: 13px;
    color: #666;
    margin-bottom: 16px;
}

/* 프로필 이미지 아이템 스타일 */
.profile-image-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    background: #f5f5f5;
    border: 1px solid #ddd;
    cursor: move;
    user-select: none;
}

/* 메인 이미지 레이블 */
.profile-image-item .main-label {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    text-align: center;
    font-size: 14px;
    padding: 4px 0;
}

/* 드래그 중인 아이템 스타일 */
.profile-image-item.ui-sortable-helper {
    cursor: grabbing;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    opacity: 0.9;
    transform: scale(1.05);
}

/* 드래그 플레이스홀더 스타일 */
.profile-image-item-placeholder {
    border: 2px dashed #999;
    border-radius: 8px;
    background-color: rgba(0, 0, 0, 0.1);
    aspect-ratio: 1;
    visibility: visible !important;
}

/* 이미지 그리드 */
.profile-images-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.image-upload-btn,
.image-item {
    aspect-ratio: 1;
    position: relative;
    border-radius: 12px;
    overflow: hidden;
}

.add-image-btn {
    width: 100%;
    height: 100%;
    border: 2px dashed #ddd;
    background: #f9f9f9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
    color: #666;
}

.add-image-btn:hover {
    background: #f5f5f5;
    border-color: #bbb;
}

.add-image-btn i {
    font-size: 24px;
}

.add-image-btn span {
    font-size: 13px;
}

.image-item {
    background: #f5f5f5;
    border: 1px solid #eee;
}

.image-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.image-item .main-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--primary-color);
    color: #fff;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
}

.image-item .delete-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 12px;
}

/* 폼 그룹 */
.form-group {
    margin-bottom: 20px;
}

.form-group:last-child {
    margin-bottom: 0;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 8px;
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    background: #fff;
    transition: border-color 0.2s;
}

.form-control:focus {
    border-color: var(--primary-color);
    outline: none;
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23333' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* 문자 수 카운트 */
.character-count {
    text-align: right;
    font-size: 12px;
    color: #999;
    margin-top: 4px;
}

/* 주소 입력 */
.address-input-wrapper {
    display: flex;
    gap: 8px;
}

.address-input-wrapper .form-control {
    flex: 1;
}

.btn-search-address {
    padding: 0 16px;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-search-address i {
    font-size: 14px;
}

/* 지도 미리보기 */
.map-preview {
    margin-top: 16px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #ddd;
}

/* 저장 버튼 */
.form-actions {
    padding: 16px;
    background: #fff;
}

.btn-save {
    width: 100%;
    padding: 14px;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-save:hover {
    background: #1e88e5;
}

.btn-save i {
    font-size: 18px;
}

/* 드래그 앤 드롭 플레이스홀더 */
.sortable-placeholder {
    border: 2px dashed var(--primary-color);
    background: #e3f2fd;
    border-radius: 12px;
    visibility: visible !important;
}

/* 반응형 디자인 */
@media (min-width: 481px) {
    .profile-edit-page {
        border-left: 1px solid #eee;
        border-right: 1px solid #eee;
    }

    .form-actions {
        border-left: 1px solid #eee;
        border-right: 1px solid #eee;
    }

    .profile-images-grid {}
}

@media (max-width: 360px) {
    .profile-images-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 로딩 스피너 */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.profile-view {
    padding: 20px 15px;
    background-color: #fff;
}

/* 프로필 헤더 스타일 추가/수정 부분 */
.profile-header {
    padding: 50px 0 0px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.profile-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-info-box {
    flex: 1;
    min-width: 0;
}

.profile-top-row {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-bottom: 6px;
}

.profile-name {
    display: flex;
    align-items: center;
    gap: 8px;
}

.category-badge {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
    flex-shrink: 0;
    width: fit-content;
}

.profile-info-box h2 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 편집 버튼 스타일 */
.edit-profile-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #f0f0f0;
    color: #333;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 13px;
    text-decoration: none;
}

.edit-profile-btn:hover {
    background: #e5e5e5;
    color: #333;
    text-decoration: none;
}

.edit-profile-btn i {
    font-size: 12px;
}

.profile-tabs {
    margin: 15px 0;
}

.profile-tabs .tab-item {
    font-size: 14px;
    text-decoration: none;
    color: #ddd;
    background: #e5e5e5;
    color: #6d6d6d;
    padding: 5px 15px;
    border-radius: 5px;
    font-weight: 500;
}

.profile-tabs .tab-item.active {
    background: #303030;
    color: #fbfbfb;
}

/* 게시글 수 스타일 */
.profile-stats {
    margin-top: 4px;
}

.profile-stats {
    display: flex;
    align-items: center;
    gap: 10px;
}

.profile-stats>span {
    color: #999;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.profile-stats i {
    font-size: 12px;
}

/* 좋아요/공유 버튼 스타일 */
.profile-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.like-button,
.share-button {
    background: none;
    border: none;
    font-size: 20px;
    color: #999;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.like-button:hover,
.share-button:hover {
    color: #666;
}

.like-button.liked {
    color: #ff4757;
}

.like-button.liked i {
    animation: likeAnimation 0.3s ease-in-out;
}

@keyframes likeAnimation {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}

/* 공유 팝업 스타일 */
.share-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.share-popup-content {
    background: #fff;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    padding: 20px;
}

.share-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.share-popup-header h3 {
    margin: 0;
    font-size: 18px;
}

.close-popup {
    background: none;
    border: none;
    font-size: 20px;
    color: #666;
    cursor: pointer;
}

.share-options {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.share-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    border: 1px solid #eee;
    border-radius: 5px;
    text-decoration: none;
    color: #333;
    transition: all 0.2s;
}

.share-option:hover {
    background: #f5f5f5;
}

.share-option img {
    width: 40px;
    height: 40px;
    margin-bottom: 8px;
}

.share-option span {
    font-size: 11px;
    text-align: center;
    font-weight: 500;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #555;
    margin-bottom: 10px;
}

.contact-item>i {
    min-width: 20px;
    text-align: center;
}

/* 후기 섹션 스타일 수정 */
.description-section,
.reviews-section {
    padding: 16px 0;
}


.rating-info {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 20px;
    font-size: 14px;
    color: #666;
}

.rating-info i {
    color: #ffa000;
}

/* 후기 아이템 수정 */
.review-items {
    margin-top: 20px;
}

.review-item {
    padding: 15px;
    background: #f3f3f3;
    border-radius: 10px;
    margin-bottom: 10px;
}

.reviewer-info {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.reviewer-avatar {
    width: 50px;
    height: 50px;
    background: #f5f5f5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 7px;
}

.reviewer-avatar i {
    font-size: 24px;
    color: #bbb;
}

.reviewer-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 100%;
}

.reviewer-details .review-date {
    font-size: 12px;
    color: #5d5d5d;
}

.reviewer-details {
    flex: 1;
}

.reviewer-details h4 {
    font-size: 14px;
    font-weight: 600;
    margin: 0;
    margin-bottom: 2px;
}

.reviewer-details .rating {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: #ffa000;
}

.more-button {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 13px;
    cursor: pointer;
    padding: 4px 8px;
}

.review-content {
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    margin-bottom: 12px;
}

/* 후기 이미지 스타일 수정 */
.review-images {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    overflow-x: auto;
}

.review-images img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

/* 스와이퍼 관련 스타일 추가 */
.swiper.profile-swiper {
    width: 100%;
    position: relative;
    overflow: visible;
    background: #f5f5f5;
}

/* 16:9 비율로 고정 (모든 디바이스 공통) */
.profile-swiper::before {
    content: '';
    display: block;
    width: 100%;
    padding-top: 51.25%; /* 16:9 비율 (9/16 * 100) */
}

.profile-swiper .swiper-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.profile-swiper .swiper-slide {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 15px;
}

.profile-swiper .img-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.profile-swiper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* 이미지 비율 유지하면서 컨테이너 채우기 */
    object-position: center; /* 이미지 중앙 정렬 */
}

/* 스와이퍼 페이지네이션 (점) 스타일 */
.profile-swiper .swiper-pagination {
    position: absolute;
    bottom: -35px !important;
    left: 0;
    width: 100%;
    text-align: center;
    z-index: 10;
}

.profile-swiper .swiper-pagination-bullet {
    width: 9px;
    height: 9px;
    display: inline-block;
    border-radius: 50%;
    background: #999;
    opacity: 0.4;
    margin: 0 4px;
}

.profile-swiper .swiper-pagination-bullet-active {
    opacity: 1;
    background: var(--primary-color);
}

.back-to-search {
    display: inline-block;
    margin-bottom: 15px;
    padding: 5px 12px;
    background-color: #f5f5f5;
    border: 1px solid #e7e7e7;
    border-radius: 3px;
    color: #525252;
    text-decoration: none;
    font-size: 13px;
    cursor: pointer;
}

.back-to-search i {
    margin-right: 5px;
    font-size: 11px;
    color: #848484;
}

.category-group {
    margin-bottom: 5px;
}

#profileEditForm .category-path-display,
#profileEditForm .help-text {
    font-size: 14px;
    color: #555;
}

/* 반응형 디자인 */
@media (max-width: 360px) {
    .profile-header {
        flex-wrap: wrap;
    }

    .profile-actions {
        width: 100%;
        justify-content: flex-end;
        margin-top: 8px;
    }
}

@media (max-width: 480px) {
    .profile-view {
        padding: 20px 15px;
    }
}