/**
 * style-wedding-fair-front.css
 * 웨딩박람회 프론트 페이지 추가 스타일
 * 기존 style-expo.css 위에 추가되는 컴포넌트들
 */

/* ===================================
   Main Tabs (일정/사이트/갤러리)
   =================================== */
.wf-main-tabs {
    display: flex;
    justify-content: center;
    gap: 0;
    margin-bottom: 2.5rem;
    border-bottom: 2px solid var(--rose-gold-light, #e0c8c8);
}

.wf-main-tab {
    padding: 12px 28px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-secondary, #888);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: color 0.2s, border-color 0.2s;
}

.wf-main-tab i {
    margin-right: 6px;
}

.wf-main-tab:hover {
    color: var(--text-dark, #333);
}

.wf-main-tab.active {
    color: var(--rose-gold, #B76E79);
    border-bottom-color: var(--rose-gold, #B76E79);
}

/* ===================================
   사이트 그리드
   =================================== */
.wf-sites-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 24px;
}

.wf-site-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s, box-shadow 0.2s;
}

.wf-site-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.wf-site-screenshot {
    height: 200px;
    overflow: hidden;
    background: #f5f5f5;
}

.wf-site-screenshot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.wf-site-info {
    padding: 16px 20px;
}

.wf-site-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark, #333);
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wf-site-domain {
    font-size: 13px;
    color: var(--text-secondary, #888);
    margin-bottom: 8px;
}

.wf-site-domain i {
    margin-right: 4px;
}

.wf-site-desc {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.wf-site-stats {
    display: flex;
    gap: 16px;
    margin-bottom: 12px;
    font-size: 13px;
    color: var(--text-secondary, #888);
}

.wf-site-stats i {
    margin-right: 4px;
}

/* ===================================
   이미지 갤러리 그리드
   =================================== */
.wf-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.wf-gallery-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    background: #f5f5f5;
    cursor: pointer;
    aspect-ratio: 1;
}

.wf-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.wf-gallery-item:hover img {
    transform: scale(1.05);
}

.wf-gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 8px 10px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    font-size: 11px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    opacity: 0;
    transition: opacity 0.3s;
}

.wf-gallery-item:hover .wf-gallery-caption {
    opacity: 1;
}

/* ===================================
   Lightbox
   =================================== */
.wf-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.wf-lightbox.show {
    display: flex;
}

.wf-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
}

.wf-lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 4px;
}

.wf-lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: #fff;
    font-size: 32px;
    cursor: pointer;
    padding: 0 8px;
}

.wf-lightbox-caption {
    text-align: center;
    color: #ccc;
    font-size: 14px;
    margin-top: 12px;
}

/* ===================================
   이미지 에러 대체 표시 (404)
   =================================== */
.wf-img-error {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0ece8;
    color: var(--text-secondary, #aaa);
    min-height: 120px;
}

.wf-img-error::after {
    content: '\F3E1';
    font-family: 'bootstrap-icons';
    font-size: 3rem;
    opacity: 0.4;
}

.wf-gallery-item.wf-img-error {
    cursor: default;
}

.wf-gallery-item.wf-img-error .wf-gallery-caption {
    display: none;
}

.wf-site-screenshot.wf-img-error {
    height: 200px;
}

/* ===================================
   소스 정보
   =================================== */
.expo-source {
    font-size: 12px;
    color: var(--text-secondary, #aaa);
    margin-top: 6px;
}

.expo-source i {
    margin-right: 4px;
}

/* ===================================
   Responsive
   =================================== */
@media (max-width: 768px) {
    .wf-main-tabs {
        gap: 0;
    }

    .wf-main-tab {
        padding: 10px 16px;
        font-size: 13px;
    }

    .wf-sites-grid {
        grid-template-columns: 1fr;
    }

    .wf-gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 8px;
    }

    .wf-site-screenshot {
        height: 160px;
    }
}

@media (max-width: 480px) {
    .wf-main-tab {
        padding: 8px 12px;
        font-size: 12px;
    }

    .wf-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
