/* 인테리어 페이지 전용 CSS */
/* CSS 버전: 1.1.2 */

/* 전역 스타일 오버라이드 */
.interior-section {
    padding: 40px 0 100px !important;
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%) !important;
    min-height: 80vh !important;
    width: 100% !important;
}

.interior-section > .container-fluid {
    max-width: 100% !important;
    padding: 0 !important;
}

/* 공간 메뉴 네비게이션 */
.space-menu-nav {
    max-width: 1600px;
    margin: 0 auto 40px;
    padding: 0 20px;
    border-bottom: 2px solid #e9ecef;
}

.space-menu-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 20px 0;
    flex-wrap: wrap;
}

.space-menu-item {
    font-size: 18px;
    font-weight: 600;
    color: #6c757d;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.space-menu-item:hover {
    color: #0058a3;
    background: rgba(0, 88, 163, 0.05);
}

.space-menu-item.active {
    color: #0058a3;
    font-weight: 700;
    background: rgba(0, 88, 163, 0.1);
}

.space-menu-item .category-count {
    font-size: 0.85em;
    opacity: 0.7;
    margin-left: 4px;
    font-weight: 500;
}

.space-menu-item.active .category-count {
    opacity: 0.9;
    color: #0058a3;
}

.space-menu-divider {
    color: #dee2e6;
    font-size: 18px;
    font-weight: 300;
}

/* 메인 콘텐츠 */
.interior-main-content {
    max-width: 1600px !important;
    margin: 0 auto !important;
    padding: 0 20px !important;
}

/* 타이틀 섹션 */
.interior-title-section {
    text-align: center;
    margin-bottom: 10px;
}

.interior-main-title {
    font-size: 48px;
    font-weight: 900;
    color: #1a1a1a;
    margin: 0 0 15px 0;
}

.interior-slogan {
    font-size: 20px;
    font-weight: 500;
    color: #6c757d;
    font-style: italic;
    margin: 0;
    letter-spacing: 1px;
}

/* 상품군 메뉴 */
.product-category-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 50px;
    padding: 20px 0;
    border-bottom: 2px solid #e9ecef;
    flex-wrap: wrap;
}

.product-category-item {
    font-size: 16px;
    font-weight: 600;
    color: #495057;
    cursor: pointer;
    padding: 12px 24px;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    background: #ffffff;
    transition: all 0.3s ease;
    position: relative;
}

.product-category-item:hover {
    color: #0058a3;
    border-color: #0058a3;
    background: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 88, 163, 0.15);
}

.product-category-item.active {
    color: #ffffff;
    font-weight: 700;
    background: linear-gradient(135deg, #0058a3, #003d7a);
    border-color: #0058a3;
    box-shadow: 0 4px 15px rgba(0, 88, 163, 0.3);
}

.product-category-item.active:hover {
    background: linear-gradient(135deg, #003d7a, #002855);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 88, 163, 0.4);
}

.product-category-item .category-count {
    font-size: 0.85em;
    opacity: 0.7;
    margin-left: 4px;
    font-weight: 500;
}

.product-category-item.active .category-count {
    opacity: 0.9;
    color: #ffffff;
}

.product-category-divider {
    display: none;
}

/* 이미지 갤러리 섹션 */
.interior-gallery-section {
    display: grid !important;
    grid-template-columns: 1fr auto !important;
    gap: 30px !important;
    margin-bottom: 50px !important;
    align-items: start !important;
    position: relative !important;
}

.gallery-main-wrapper {
    position: relative;
    display: flex;
    align-items: stretch;
    gap: 20px;
}

.gallery-main-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0;
    position: relative;
}

.gallery-nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    padding: 0;
    background: #ffffff;
    border: 2px solid #e9ecef;
    border-radius: 50%;
    color: #0058a3;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
    align-self: center;
}

.gallery-nav-btn:hover {
    border-color: #0058a3;
    background: rgba(0, 88, 163, 0.05);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 88, 163, 0.15);
}

.gallery-nav-btn i {
    font-size: 28px;
    font-weight: 700;
}

.gallery-main-image {
    flex: 1;
    overflow: hidden;
    border-radius: 16px 16px 0 0;
    background: #f8f9fa;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    min-height: 500px;
    max-height: 70vh; /* 뷰포트 높이의 70%로 제한하여 스크롤 방지 */
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.main-image {
    width: 100%;
    height: 100%;
    max-height: 70vh; /* 뷰포트 높이의 70%로 제한 */
    object-fit: contain; /* 이미지 비율 유지하면서 컨테이너에 맞춤 */
    display: block;
    border-radius: 16px 16px 0 0;
    transition: transform 0.3s ease;
}

.main-image:hover {
    transform: scale(1.02);
}

.gallery-main-container {
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    background: #ffffff;
}

/* 썸네일 갤러리 */
.gallery-thumbnails-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    height: 100%;
    align-self: stretch;
}

.gallery-thumbnails-wrapper .gallery-nav-next {
    position: absolute;
    right: -60px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    height: 50px;
}

.gallery-thumbnails {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-height: 700px;
    overflow-y: auto;
    padding: 10px 5px;
    scroll-behavior: smooth;
}

.gallery-thumbnails::-webkit-scrollbar {
    width: 8px;
}

.gallery-thumbnails::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.gallery-thumbnails::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #0058a3, #003d7a);
    border-radius: 10px;
    transition: background 0.3s ease;
}

.gallery-thumbnails::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #003d7a, #002855);
}

/* 스크롤 인디케이터 */
.scroll-indicator {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 30px;
    display: none;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.8));
    backdrop-filter: blur(5px);
    border-radius: 0 0 20px 20px;
    color: #0058a3;
    font-size: 20px;
    pointer-events: none;
    z-index: 10;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.scroll-indicator-top {
    top: 0;
    border-radius: 0 0 20px 20px;
}

.scroll-indicator-bottom {
    bottom: 0;
    border-radius: 20px 20px 0 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.95));
}

.thumbnail-item {
    width: 200px;
    height: 150px;
    min-height: 150px;
    max-height: 150px;
    overflow: hidden;
    border-radius: 12px;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #f8f9fa;
    aspect-ratio: 4 / 3;
    display: flex;
    align-items: center;
    justify-content: center;
}

.thumbnail-item:hover {
    border-color: #0058a3;
    transform: scale(1.05);
}

.thumbnail-item.active {
    border-color: #0058a3;
    border-width: 4px;
    box-shadow: 0 6px 20px rgba(0, 88, 163, 0.4);
    transform: scale(1.08);
    position: relative;
}

.thumbnail-item.active::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border: 2px solid #0058a3;
    border-radius: 12px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.thumbnail-img {
    width: 100%;
    height: 100%;
    min-height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    flex-shrink: 0;
}

/* 이미지 설명 섹션 (갤러리 내부) */
.image-description-section {
    background: #ffffff;
    border-radius: 0 0 16px 16px;
    padding: 25px 30px;
    margin-top: 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    border-top: 1px solid #e9ecef;
}

.image-title {
    font-size: 28px;
    font-weight: 800;
    color: #1a1a1a;
    margin: 0 0 15px 0;
}

.image-description {
    font-size: 18px;
    color: #4a5568;
    line-height: 1.8;
    margin: 0 0 20px 0;
}

.image-hashtags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hashtag {
    display: inline-block;
    padding: 8px 16px;
    background: linear-gradient(135deg, rgba(0, 88, 163, 0.1), rgba(0, 61, 122, 0.1));
    color: #0058a3;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

/* 관련 상품 섹션 */
.related-products-section {
    background: #ffffff;
    border-radius: 16px;
    padding: 40px;
    margin-bottom: 50px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.related-products-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.related-products-title {
    font-size: 24px;
    font-weight: 800;
    color: #1a1a1a;
    margin: 0;
}

.related-products-buttons {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.related-products-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    background: linear-gradient(135deg, #0058a3, #003d7a);
    color: #ffffff;
    text-decoration: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 88, 163, 0.3);
}

.related-products-btn:hover {
    background: linear-gradient(135deg, #003d7a, #002855);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 88, 163, 0.4);
}

.related-products-btn.recommended-btn {
    background: linear-gradient(135deg, rgba(0, 88, 163, 0.1), rgba(0, 61, 122, 0.1));
    color: #0058a3;
    border: 2px solid #0058a3;
    box-shadow: 0 4px 15px rgba(0, 88, 163, 0.15);
}

.related-products-btn.recommended-btn:hover {
    background: linear-gradient(135deg, #0058a3, #003d7a);
    color: #ffffff;
    border-color: #0058a3;
}

.related-products-btn i {
    font-size: 18px;
    transition: transform 0.3s ease;
}

.related-products-btn:hover i {
    transform: translateX(5px);
}

.related-products-content {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.related-products-subtitle {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    padding-bottom: 15px;
    border-bottom: 2px solid #e9ecef;
}

.recommended-products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.recommended-product-card {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.recommended-product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 88, 163, 0.15);
    border-color: #0058a3;
}

.recommended-product-image {
    width: 100%;
    aspect-ratio: 1 / 1; /* 정사각형 비율 */
    overflow: hidden;
    background: #f8f9fa;
    position: relative;
}

.recommended-product-image .product-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.recommended-product-card:hover .product-image {
    transform: scale(1.1);
}

.recommended-product-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.recommended-product-name {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.recommended-product-price {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.recommended-product-price .price-label {
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.recommended-product-price .price-amount {
    font-size: 18px;
    font-weight: 700;
    color: #0058a3;
}


/* 하단 인테리어 썸네일 섹션 */
.interior-thumbnails-section {
    margin-top: 60px;
}

.thumbnails-section-title {
    font-size: 28px;
    font-weight: 800;
    color: #1a1a1a;
    margin: 0 0 30px 0;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.space-name-highlight {
    display: inline-block;
    padding: 8px 20px;
    background: linear-gradient(135deg, #0058a3, #003d7a);
    color: #ffffff;
    border-radius: 25px;
    font-weight: 900;
    box-shadow: 0 4px 15px rgba(0, 88, 163, 0.3);
    position: relative;
}

.space-name-highlight::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 25px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), transparent);
    pointer-events: none;
}

.thumbnails-title-text {
    color: #4a5568;
    font-weight: 600;
}

.interior-thumbnails-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.interior-thumbnail-item {
    display: block;
    overflow: hidden;
    border-radius: 16px;
    background: #f8f9fa;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    aspect-ratio: 4 / 3;
}

.interior-thumbnail-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.thumbnail-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.interior-thumbnail-item:hover .thumbnail-image {
    transform: scale(1.1);
}

/* 반응형 디자인 */
@media (max-width: 1200px) {
    .interior-gallery-section {
        grid-template-columns: 1fr;
    }

    .gallery-thumbnails-wrapper {
        order: -1;
        margin-bottom: 20px;
        width: 100%;
        padding-right: 60px;
    }
    
    .gallery-thumbnails-wrapper .gallery-nav-next {
        right: 10px;
        top: 50%;
        transform: translateY(-50%);
    }

    .gallery-thumbnails {
        flex-direction: row;
        max-height: none;
        overflow-x: auto;
        overflow-y: hidden;
        padding: 10px 5px;
    }

    .thumbnail-item {
        width: 160px;
        height: 120px;
        flex-shrink: 0;
        aspect-ratio: 4 / 3;
    }

    .scroll-indicator {
        display: none !important;
    }

    .gallery-main-image {
        border-radius: 16px;
    }

    .main-image {
        border-radius: 16px;
    }

    .image-description-section {
        border-radius: 0 0 16px 16px;
    }
}

@media (max-width: 991px) {
    .interior-section {
        padding: 30px 0 80px;
    }

    .interior-main-title {
        font-size: 36px;
    }

    .interior-slogan {
        font-size: 18px;
    }

    .gallery-main-image {
        min-height: 400px;
    }

    .image-description-section {
        padding: 25px 30px;
    }

    .image-title {
        font-size: 24px;
    }

    .related-products-section {
        padding: 30px;
    }

    .related-products-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .related-products-buttons {
        width: 100%;
        flex-direction: column;
        gap: 10px;
    }

    .related-products-btn {
        width: 100%;
        justify-content: center;
    }

    .related-products-content {
        gap: 20px;
    }
    
    .related-products-subtitle {
        font-size: 18px;
    }
    
    .recommended-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .recommended-product-image {
        height: 180px;
    }
    
    .recommended-product-info {
        padding: 15px;
    }
    
    .recommended-product-name {
        font-size: 15px;
    }
    
    .recommended-product-price .price-amount {
        font-size: 16px;
    }


    .interior-thumbnails-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .space-menu-wrapper {
        gap: 10px;
    }

    .space-menu-item {
        font-size: 16px;
        padding: 6px 12px;
    }

    .space-menu-divider {
        font-size: 16px;
    }

    .interior-main-title {
        font-size: 32px;
    }

    .interior-slogan {
        font-size: 16px;
    }

    .product-category-nav {
        gap: 8px;
    }

    .product-category-item {
        font-size: 14px;
        padding: 10px 20px;
        border-radius: 20px;
    }

    .gallery-main-wrapper {
        flex-direction: column;
        gap: 15px;
    }

    .gallery-nav-btn {
        width: 45px;
        height: 45px;
    }

    .gallery-nav-btn i {
        font-size: 24px;
    }

    .gallery-main-image {
        min-height: 350px;
    }

    .gallery-thumbnails {
        width: 100%;
        flex-direction: row;
        overflow-x: auto;
    }

    .thumbnail-item {
        width: 140px;
        height: 105px;
        aspect-ratio: 4 / 3;
    }

    .image-description-section {
        padding: 20px;
    }

    .image-title {
        font-size: 22px;
    }

    .image-description {
        font-size: 16px;
    }

    .related-products-section {
        padding: 25px;
    }

    .related-products-title {
        font-size: 20px;
    }

    .related-products-subtitle {
        font-size: 18px;
    }
    
    .recommended-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .recommended-product-image {
        height: 180px;
    }
    
    .recommended-product-info {
        padding: 15px;
    }
    
    .recommended-product-name {
        font-size: 15px;
    }
    
    .recommended-product-price .price-amount {
        font-size: 16px;
    }

    .interior-thumbnails-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .interior-section {
        padding: 20px 0 60px;
    }

    .space-menu-wrapper {
        padding: 15px 0;
    }

    .space-menu-item {
        font-size: 14px;
    }

    .interior-main-title {
        font-size: 28px;
    }

    .interior-slogan {
        font-size: 14px;
    }

    .product-category-item {
        font-size: 13px;
        padding: 8px 16px;
        border-radius: 18px;
    }

    .gallery-main-image {
        min-height: 300px;
    }

    .image-description-section {
        padding: 18px;
    }

    .image-title {
        font-size: 20px;
    }

    .image-description {
        font-size: 15px;
    }

    .related-products-section {
        padding: 20px;
    }

    .recommended-products-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .recommended-product-image {
        height: 160px;
    }
    
    .recommended-product-info {
        padding: 12px;
    }
    
    .recommended-product-name {
        font-size: 14px;
    }
    
    .recommended-product-price .price-amount {
        font-size: 15px;
    }

    .thumbnails-section-title {
        font-size: 24px;
        flex-direction: column;
        gap: 10px;
    }

    .space-name-highlight {
        padding: 6px 16px;
        font-size: 22px;
    }

    .thumbnails-title-text {
        font-size: 22px;
    }
}

