/* ============================================================
   상품 비교 — 데스크톱 Wanted DS 클론
   디자인: Compare Page.dc.html (e45238f0)
   네임스페이스: cw- (css/wanted-ds.css의 --ws 토큰 사용)
   모바일(<768px)은 기존 8스텝 퍼널 유지 (하단에 원본 이식)
   ============================================================ */

.cw-stage { background: var(--ws-bg, #fff); min-height: 70vh; }
.cw-main {
  /* 헤더(.kh-top: 1240 + 좌우 40)와 좌우 정렬 통일 */
  max-width: 1240px; margin: 0 auto; padding: 32px 40px 88px;
  font-family: 'Pretendard', -apple-system, system-ui, sans-serif;
  color: var(--ws-text-normal, #474d57);
}
.cw-main *, .cw-main *::before, .cw-main *::after { box-sizing: border-box; }
.cw-main button { font-family: inherit; cursor: pointer; }

/* ── 타이틀 ── */
.cw-head { display: flex; align-items: flex-end; justify-content: space-between; margin: 0 0 20px; }
.cw-head-txt { display: flex; flex-direction: column; gap: 6px; }
.cw-head h1 { margin: 0; font-size: 24px; font-weight: 700; color: var(--ws-text-strong, #14161a); letter-spacing: -0.02em; }
.cw-head p { margin: 0; font-size: 14px; color: var(--ws-text-alternative, #6d7582); }
.cw-btn-outline {
  height: 32px; padding: 0 14px; border: 1px solid var(--ws-line, rgba(0, 0, 0, 0.12));
  border-radius: 8px; background: var(--ws-bg, #fff);
  font-size: 13px; font-weight: 600; color: var(--ws-text-normal, #474d57); white-space: nowrap;
}
.cw-btn-outline:hover { background: var(--ws-fill, #f2f4f7); }

/* ── 추천 배너 ── */
.cw-banner {
  border: 1px solid var(--blue-90, #C6D8FF); background: var(--blue-99, #F7F9FF);
  border-radius: 16px; padding: 20px 24px; margin: 0 0 24px;
  display: flex; flex-direction: column; gap: 16px;
}
.cw-banner-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.cw-banner-title { font-size: 17px; font-weight: 700; color: var(--ws-text-strong, #14161a); white-space: nowrap; }
.cw-chip-row { display: flex; gap: 6px; flex-wrap: wrap; }
.cw-chip {
  height: 28px; padding: 0 12px; border-radius: 999px; white-space: nowrap;
  border: 1px solid var(--ws-line, rgba(0, 0, 0, 0.12)); background: var(--ws-bg, #fff);
  font-size: 12.5px; font-weight: 600; color: var(--ws-text-alternative, #6d7582);
  transition: background 0.12s ease;
}
.cw-chip:hover { background: var(--ws-fill, #f2f4f7); }
.cw-chip.active {
  background: var(--ws-text-strong, #14161a); color: #fff; border-color: var(--ws-text-strong, #14161a);
}
.cw-banner-hint { font-size: 12px; color: var(--ws-text-assistive, #9099a4); white-space: nowrap; }

.cw-rec-card {
  display: flex; align-items: center; gap: 16px;
  background: var(--ws-bg, #fff); border: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06));
  border-radius: 12px; padding: 14px 16px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06), 0 0 1px rgba(0, 0, 0, 0.1);
}
.cw-rec-img {
  width: 104px; height: 70px; border-radius: 10px; flex: none;
  background-size: cover; background-position: center; background-color: var(--ws-fill, #f2f4f7);
}
.cw-rec-body { display: flex; flex-direction: column; gap: 5px; flex: 1; min-width: 0; }
.cw-rec-head { display: flex; align-items: center; gap: 8px; min-width: 0; }
.cw-badge {
  display: inline-flex; align-items: center; flex: none; height: 20px; padding: 0 8px;
  border-radius: 999px; background: var(--ws-primary, #3366FF); color: #fff;
  font-size: 11px; font-weight: 700; white-space: nowrap;
}
.cw-badge.xs { height: 17px; padding: 0 6px; font-size: 10px; }
.cw-rec-name { font-size: 15px; font-weight: 700; color: var(--ws-text-strong, #14161a); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cw-rec-reasons { font-size: 13px; color: var(--ws-text-neutral, #474d57); }
.cw-rec-caveat { font-size: 12px; color: #B7791F; }
.cw-rec-actions { display: flex; align-items: center; gap: 8px; flex: none; }
.cw-btn-text {
  height: 40px; padding: 0 12px; border: none; background: transparent;
  font-size: 14px; font-weight: 600; color: var(--ws-text-alternative, #6d7582); white-space: nowrap;
  text-decoration: none; display: inline-flex; align-items: center; justify-content: center;
}
.cw-btn-text:hover { color: var(--ws-text-strong, #14161a); }
.cw-btn-text.center { width: 100%; height: 32px; font-size: 13px; }
.cw-btn-solid {
  height: 40px; padding: 0 18px; border: none; border-radius: 10px;
  background: var(--ws-primary, #3366FF); color: #fff;
  font-size: 14px; font-weight: 600; white-space: nowrap;
}
.cw-btn-solid:hover { background: var(--ws-primary-strong, #2b5be0); }
.cw-btn-solid.full { width: 100%; }
.cw-rec-others { margin: 0; font-size: 12px; color: var(--ws-text-assistive, #9099a4); }

/* ── 툴바 ── */
.cw-toolbar { display: flex; align-items: center; justify-content: space-between; margin: 0 0 12px; }
.cw-legend { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ws-text-alternative, #6d7582); }
.cw-legend-dot {
  width: 12px; height: 12px; border-radius: 3px; flex: none;
  background: var(--blue-95, #EBF0FF); border: 1px solid var(--blue-90, #C6D8FF);
}
.cw-diff { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--ws-text-neutral, #474d57); }
.cw-switch {
  width: 40px; height: 24px; border: none; border-radius: 999px; position: relative;
  background: var(--ws-fill-strong, #d9dee4); transition: background 0.15s ease; padding: 0;
}
.cw-switch.on { background: var(--ws-primary, #3366FF); }
.cw-switch-knob {
  position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2); transition: transform 0.15s ease;
}
.cw-switch.on .cw-switch-knob { transform: translateX(16px); }
@media (prefers-reduced-motion: reduce) { .cw-switch, .cw-switch-knob { transition: none; } }
.cw-diff-note { font-size: 12px; color: var(--ws-text-assistive, #9099a4); }

/* ── 비교 테이블 ── */
.cw-table {
  border: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06));
  border-radius: 16px; overflow: hidden; background: var(--ws-bg, #fff);
}
.cw-header-row, .cw-row { display: grid; grid-template-columns: 132px repeat(4, minmax(0, 1fr)); }
.cw-row { border-top: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06)); }
.cw-corner { padding: 18px 16px; display: flex; align-items: flex-end; font-size: 12px; color: var(--ws-text-assistive, #9099a4); }

.cw-hcell {
  padding: 16px 14px 14px; border-left: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06));
  display: flex; flex-direction: column; gap: 8px; min-width: 0;
}
.cw-himg-wrap { position: relative; }
.cw-himg {
  width: 100%; height: 132px; border-radius: 12px;
  background-size: cover; background-position: center; background-color: var(--ws-fill, #f2f4f7);
}
.cw-hremove {
  position: absolute; top: 8px; right: 8px; width: 32px; height: 32px; border-radius: 50%;
  border: none; background: rgba(23, 23, 25, 0.55); color: #fff;
  display: flex; align-items: center; justify-content: center; padding: 0; font-size: 13px;
}
.cw-hremove:hover { background: rgba(23, 23, 25, 0.75); }
.cw-hname-wrap { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cw-hname { font-size: 14px; font-weight: 700; color: var(--ws-text-strong, #14161a); line-height: 1.35; }
.cw-hloc { font-size: 12px; color: var(--ws-text-alternative, #6d7582); }

.cw-add-slot {
  border: 1.5px dashed var(--ws-line, rgba(0, 0, 0, 0.12)); border-radius: 12px;
  min-height: 196px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px; padding: 12px;
}
.cw-add-plus {
  width: 36px; height: 36px; border-radius: 50%; background: var(--ws-fill, #f2f4f7);
  display: flex; align-items: center; justify-content: center;
  color: var(--ws-text-alternative, #6d7582); font-size: 20px; font-weight: 500;
}
.cw-add-label { font-size: 13px; color: var(--ws-text-alternative, #6d7582); }
.cw-restore-list { display: flex; flex-direction: column; gap: 4px; align-items: center; }
.cw-restore-chip {
  height: 28px; padding: 0 12px; border-radius: 999px; max-width: 100%;
  border: 1px solid var(--ws-line, rgba(0, 0, 0, 0.12)); background: var(--ws-bg, #fff);
  font-size: 12px; font-weight: 600; color: var(--ws-text-alternative, #6d7582);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cw-restore-chip:hover { background: var(--ws-fill, #f2f4f7); }

.cw-label {
  padding: 14px 16px; background: var(--ws-bg-alt, #F7F8FA);
  display: flex; align-items: center; font-size: 13px; font-weight: 500;
  color: var(--ws-text-alternative, #6d7582);
}
.cw-label.dim { color: var(--ws-text-assistive, #9099a4); }
.cw-cell {
  padding: 14px 12px; border-left: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06));
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; text-align: center; min-width: 0;
}
.cw-cell.best { background: var(--blue-95, #EBF0FF); }
.cw-cell-strike { font-size: 12px; color: var(--ws-text-assistive, #9099a4); text-decoration: line-through; }
.cw-cell-main-row { display: flex; align-items: center; gap: 6px; justify-content: center; flex-wrap: wrap; }
.cw-cell-disc { font-size: 13px; color: #E0492F; font-weight: 700; }
.cw-cell-main { font-size: 14px; font-weight: 500; color: var(--ws-text-strong, #14161a); word-break: keep-all; }
.cw-cell-main.bold { font-weight: 700; }
.cw-cell-main.dim { color: var(--ws-text-assistive, #9099a4); }
.cw-cell-sub { font-size: 12px; color: var(--ws-text-alternative, #6d7582); }
.cw-ox-yes { color: var(--ws-primary, #3366FF); font-size: 16px; font-weight: 700; }
.cw-ox-no { color: var(--ws-text-disable, #c4c9d0); font-size: 14px; }

.cw-collapsed-cell {
  grid-column: 2 / -1; border-left: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06));
  padding: 10px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--ws-bg-alt, #F7F8FA); font-size: 12px; color: var(--ws-text-alternative, #6d7582);
}
.cw-collapsed .cw-label { padding: 12px 16px; }

.cw-cta-row .cw-label { background: var(--ws-bg-alt, #F7F8FA); }
.cw-cta-cell {
  padding: 16px 14px; border-left: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06));
  display: flex; flex-direction: column; gap: 6px; align-items: stretch;
}

/* ── 빈 상태/스켈레톤 (기존 클래스 재사용) ── */
.compare-skeleton { padding: 24px 0; }
.skeleton-table { border: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06)); border-radius: 16px; overflow: hidden; }
.skeleton-header-row, .skeleton-row { display: grid; grid-template-columns: 132px repeat(3, 1fr); }
.skeleton-row { border-top: 1px solid var(--ws-line-alt, rgba(0, 0, 0, 0.06)); }
.skeleton-cell {
  height: 56px; margin: 10px; border-radius: 8px;
  background: linear-gradient(90deg, #F2F4F6 25%, #fff 50%, #F2F4F6 75%);
  background-size: 200% 100%; animation: cwSkeleton 1.5s infinite;
}
.skeleton-header-row .skeleton-cell { height: 150px; }
@keyframes cwSkeleton { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .skeleton-cell { animation: none; } }

.compare-empty {
  display: none; flex-direction: column; align-items: center; gap: 10px;
  padding: 80px 20px; text-align: center;
}
.compare-empty-icon { color: var(--ws-text-assistive, #9099a4); }
.compare-empty-title { margin: 0; font-size: 18px; font-weight: 700; color: var(--ws-text-strong, #14161a); }
.compare-empty-description { margin: 0; font-size: 14px; color: var(--ws-text-alternative, #6d7582); line-height: 1.6; }
.compare-empty-btn {
  margin-top: 8px; height: 40px; padding: 0 20px; border-radius: 10px;
  background: var(--ws-primary, #3366FF); color: #fff; font-size: 14px; font-weight: 600;
  display: inline-flex; align-items: center; text-decoration: none;
}

/* ── 반응형: 모바일은 퍼널이 담당 ── */
@media (max-width: 767px) {
  .cw-main { padding: 20px 16px 100px; }
  .cw-head h1 { font-size: 20px; }
}

/* ============================================================
   이하: 모바일 8스텝 퍼널 (구 compare.css 섹션 10 원본 이식)
   ============================================================ */

/* ============================================
   10. 모바일 전용 퍼널 레이아웃 (슬라이드 방식)
   ============================================ */

/* 모바일 전용 컨테이너 (JS에서 동적 생성) */
.compare-mobile-layout {
    display: none;
}

/* 모바일 퍼널 컨테이너 */
.compare-mobile-funnel {
    display: none;
}

/* 모바일 퍼널 헤더 (진행 바) */
.compare-funnel-header {
    padding: 16px 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.compare-funnel-progress-container {
    flex: 1;
    height: 6px;
    background: var(--compare-line-weak);
    border-radius: 10px;
    margin-right: 12px;
    overflow: hidden;
}

.compare-funnel-progress-bar {
    height: 100%;
    background: var(--compare-blue);
    width: 16.66%;
    transition: width 0.4s cubic-bezier(0.2, 0, 0, 1);
    border-radius: 10px;
}

.compare-funnel-step-indicator {
    font-size: 14px;
    font-weight: 600;
    color: var(--compare-text-tertiary);
    font-family: 'Pretendard', -apple-system, sans-serif;
    white-space: nowrap;
}

.compare-funnel-step-indicator .current {
    color: var(--compare-blue);
}

/* 퍼널 스텝 */
.compare-funnel-step {
    display: none;
    animation: compareFadeIn 0.4s cubic-bezier(0.2, 0, 0, 1);
}

.compare-funnel-step.active {
    display: block;
}

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

/* 스텝 제목 */
.compare-funnel-step-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--compare-text-primary);
    margin: 0 0 6px 0;
    line-height: 1.35;
    letter-spacing: -0.02em;
}

.compare-funnel-step-subtitle {
    font-size: 15px;
    color: var(--compare-text-tertiary);
    margin: 0 0 24px 0;
}

/* 이미지 슬라이드용 카드 그리드 */
.compare-funnel-images {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.compare-funnel-image-card {
    position: relative;
}

.compare-funnel-image-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 1/1;
    border-radius: 16px;
    overflow: hidden;
    background: var(--compare-bg-grouped);
}

.compare-funnel-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.compare-funnel-remove-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: all 0.15s ease;
}

.compare-funnel-remove-btn:active {
    transform: scale(0.9);
    background: rgba(0, 0, 0, 0.7);
}

.compare-funnel-remove-btn svg path {
    stroke: white;
}

.compare-funnel-card-name {
    margin-top: 10px;
    font-size: 14px;
    font-weight: 600;
    color: var(--compare-text-primary);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-align: center;
}

/* 리스트형 비교 섹션 */
.compare-funnel-list {
    background: var(--compare-bg-white);
    border-radius: 16px;
    box-shadow: var(--compare-shadow-card);
    overflow: hidden;
}

.compare-funnel-list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    border-bottom: 1px solid var(--compare-line-weak);
}

.compare-funnel-list-item:last-child {
    border-bottom: none;
}

.compare-funnel-list-label {
    font-size: 14px;
    color: var(--compare-text-tertiary);
    flex-shrink: 0;
    max-width: 100px;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.compare-funnel-list-value {
    font-size: 16px;
    font-weight: 600;
    color: var(--compare-text-primary);
    text-align: right;
    flex: 1;
    margin-left: 12px;
}

.compare-funnel-list-value.best {
    color: var(--compare-blue);
}

.compare-funnel-list-value.best::after {
    content: ' ✓';
    font-weight: 700;
}

/* 편의시설 태그형 아이템 */
.compare-funnel-list-item.tags-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
}

.compare-funnel-list-item.tags-item .compare-funnel-list-label {
    max-width: 100%;
}

.compare-funnel-list-item.tags-item .compare-funnel-list-value {
    width: 100%;
    margin-left: 0;
    text-align: left;
}

.compare-funnel-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.compare-funnel-tag {
    display: inline-block;
    padding: 5px 10px;
    background: var(--compare-bg-grouped);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    color: var(--compare-text-secondary);
}

/* 모바일 퍼널 - 편의시설 최다 강조 */
.compare-funnel-list-item.best-amenities {
    background: linear-gradient(135deg, #F0F7FF 0%, #E8F3FF 100%);
    border-radius: 12px;
    margin: 0 -16px;
    padding: 16px;
}

.compare-funnel-list-item.best-amenities .compare-funnel-list-label {
    color: var(--compare-blue);
    font-weight: 600;
}

.compare-funnel-list-item.best-amenities .best-indicator {
    color: var(--compare-blue);
    font-weight: 700;
    margin-left: 4px;
}

.compare-funnel-list-item.best-amenities .compare-funnel-tag {
    background: var(--compare-blue-light);
    color: var(--compare-blue);
    font-weight: 600;
}

/* 하단 퍼널 액션 바 (고정) */
.compare-funnel-action-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 12px 16px;
    padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px) + var(--app-safe-bottom, 0px));
    background: var(--compare-bg-white);
    display: flex;
    gap: 12px;
}

.compare-funnel-btn {
    height: 52px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    font-family: 'Pretendard', -apple-system, sans-serif;
    cursor: pointer;
    border: none;
    transition: all 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.compare-funnel-btn-prev {
    width: 52px;
    flex-shrink: 0;
    background: var(--compare-bg-grouped);
    color: var(--compare-text-primary);
}

.compare-funnel-btn-prev:active {
    transform: scale(0.96);
    background: var(--compare-line-weak);
}

.compare-funnel-btn-next {
    flex: 1;
    background: var(--compare-blue);
    color: white;
}

.compare-funnel-btn-next:active {
    transform: scale(0.96);
    background: var(--compare-blue-dark);
}

.compare-funnel-btn-next.primary-action {
    background: var(--compare-blue);
}

/* 퍼널 컨텐츠 영역 패딩 (고정 바 높이 고려) */
.compare-funnel-content {
    padding-bottom: 80px;
}

@media (max-width: 767px) {
    /*
     * 모바일에서는 퍼널 레이아웃 사용
     * JS에서 isMobile() 체크로 renderMobileFunnelLayout()이 호출됨
     */

    /* compare 페이지 전용 content-section 패딩 오버라이드 (좌우 16px 균일) */
    .content-section:has(.compare-container) {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }

    /* 모바일에서 .compare-table 컨테이너 스타일 제거 */
    .compare-table {
        background: transparent;
        border-radius: 0;
        box-shadow: none;
    }

    /* 모바일에서 헤더 공유 버튼 및 설명 숨김 */
    .compare-header-actions {
        display: none;
    }

    .compare-description {
        display: none;
    }

    /* 모바일 퍼널 레이아웃 표시 */
    .compare-mobile-funnel {
        display: block;
    }

    /* 기존 세로 스크롤 레이아웃은 숨김 (퍼널로 대체) */
    .compare-mobile-layout {
        display: none;
    }

    /* 상단 이미지 영역 */
    .compare-mobile-images {
        display: flex;
        gap: 12px;
        padding: 16px;
        background: var(--compare-bg-white);
        border-radius: 16px;
        margin-bottom: 16px;
        box-shadow: var(--compare-shadow-card);
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
    }

    .compare-mobile-image-card {
        flex: 1;
        min-width: calc(50% - 6px);
        max-width: calc(50% - 6px);
        scroll-snap-align: start;
        position: relative;
    }

    .compare-mobile-image-card .compare-product-image {
        width: 100%;
        aspect-ratio: 1/1;
        background-size: cover;
        background-position: center;
        border-radius: 12px;
    }

    .compare-mobile-image-card .compare-product-remove {
        position: absolute;
        top: 8px;
        right: 8px;
        width: 32px;
        height: 32px;
        border-radius: 50%;
        background: rgba(0, 0, 0, 0.5);
        border: none;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 2;
    }

    .compare-mobile-image-card .compare-product-remove svg {
        width: 16px;
        height: 16px;
    }

    .compare-mobile-image-card .compare-product-remove svg path {
        stroke: white;
    }

    .compare-mobile-product-name,
    .compare-mobile-card-name {
        margin-top: 10px;
        font-size: 14px;
        font-weight: 600;
        color: var(--compare-text-primary);
        line-height: 1.4;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-align: center;
    }

    /* 이미지 래퍼 */
    .compare-mobile-image-wrap {
        position: relative;
        width: 100%;
        aspect-ratio: 1/1;
        border-radius: 12px;
        overflow: hidden;
    }

    .compare-mobile-image {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    /* 삭제 버튼 */
    .compare-mobile-remove {
        position: absolute;
        top: 8px;
        right: 8px;
        width: 28px;
        height: 28px;
        border-radius: 50%;
        background: rgba(0, 0, 0, 0.5);
        border: none;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 2;
        transition: all 0.15s ease;
    }

    .compare-mobile-remove:active {
        transform: scale(0.9);
        background: rgba(0, 0, 0, 0.7);
    }

    .compare-mobile-remove svg path {
        stroke: white;
    }

    /* 비교 항목 카드 */
    .compare-mobile-section {
        background: var(--compare-bg-white);
        border-radius: 16px;
        margin-bottom: 12px;
        box-shadow: var(--compare-shadow-card);
        overflow: hidden;
    }

    .compare-mobile-section-header,
    .compare-mobile-section-title {
        padding: 14px 16px;
        background: var(--compare-bg-grouped);
        font-size: 13px;
        font-weight: 600;
        color: var(--compare-text-secondary);
        border-bottom: 1px solid var(--compare-line-weak);
    }

    .compare-mobile-section-content {
        padding: 0;
    }

    .compare-mobile-item {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 14px 16px;
        border-bottom: 1px solid var(--compare-line-weak);
    }

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

    .compare-mobile-item-label {
        font-size: 14px;
        color: var(--compare-text-tertiary);
        flex-shrink: 0;
        max-width: 80px;
        display: -webkit-box;
        -webkit-line-clamp: 1;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .compare-mobile-item-value {
        font-size: 15px;
        font-weight: 600;
        color: var(--compare-text-primary);
        text-align: right;
        flex: 1;
        margin-left: 12px;
    }

    /* 더 좋은 값 강조 */
    .compare-mobile-item-value.best-value {
        color: var(--compare-blue);
    }

    .compare-mobile-item-value.best-value::after {
        content: ' ✓';
        color: var(--compare-blue);
        font-weight: 700;
    }

    /* 가격 강조 */
    .compare-mobile-price {
        font-size: 17px;
        font-weight: 700;
        color: var(--compare-text-primary);
    }

    .compare-mobile-price.best-value {
        color: var(--compare-blue);
    }

    .compare-mobile-discount-rate {
        color: var(--compare-error);
        font-size: 14px;
        font-weight: 700;
        margin-right: 6px;
    }

    .compare-mobile-original-price {
        font-size: 13px;
        color: var(--compare-text-placeholder);
        text-decoration: line-through;
        display: block;
        margin-top: 4px;
    }

    /* 편의시설 항목 (태그 포함) */
    .compare-mobile-item-tags {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .compare-mobile-item-tags .compare-mobile-item-label {
        max-width: 100%;
    }

    .compare-mobile-item-tags .compare-mobile-item-value {
        width: 100%;
        margin-left: 0;
        text-align: left;
    }

    /* 편의시설 태그 (모바일) */
    .compare-mobile-tags {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
        justify-content: flex-start;
    }

    .compare-mobile-tags .compare-tag,
    .compare-mobile-tag {
        font-size: 11px;
        padding: 4px 8px;
        background: var(--compare-bg-grouped);
        color: var(--compare-text-secondary);
        border-radius: 6px;
    }

    /* 하단 고정 액션 바 */
    .compare-mobile-action-bar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 1000;
        padding: 12px 16px;
        padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px) + var(--app-safe-bottom, 0px));
        background: var(--compare-bg-white);
        border-top: 1px solid var(--compare-line-weak);
        box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
        display: flex;
        gap: 10px;
    }

    .compare-mobile-action-btn {
        flex: 1;
        padding: 14px 16px;
        border-radius: 12px;
        font-size: 15px;
        font-weight: 600;
        text-align: center;
        text-decoration: none;
        cursor: pointer;
        transition: all 0.15s ease;
        font-family: 'Pretendard', -apple-system, sans-serif;
    }

    .compare-mobile-action-btn.primary,
    .compare-mobile-action-primary {
        background: var(--compare-blue);
        color: white;
        border: none;
    }

    .compare-mobile-action-btn.primary:active,
    .compare-mobile-action-primary:active {
        background: var(--compare-blue-dark);
        transform: scale(0.98);
    }

    .compare-mobile-action-btn.secondary,
    .compare-mobile-action-share {
        background: var(--compare-bg-grouped);
        color: var(--compare-text-primary);
        border: none;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        flex: 0 0 auto;
        padding: 14px 20px;
    }

    .compare-mobile-action-btn.secondary:active,
    .compare-mobile-action-share:active {
        background: var(--compare-line-weak);
        transform: scale(0.98);
    }

    .compare-mobile-action-share svg {
        flex-shrink: 0;
    }

    /* 페이지 하단 여백은 .compare-funnel-content에서 처리 */

    /* 빈 상태 모바일 최적화 */
    .compare-empty {
        padding: 60px 20px 120px;
    }
}

/* ============================================
 * 슬라이드 7: 추천 결과 스타일 (토스 디자인)
 * ============================================ */

.compare-funnel-recommendation {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* 추천 1위 카드 (토스 스타일) */
.compare-recommend-winner-card {
    background: linear-gradient(135deg, #E8F3FF 0%, #D6EBFF 100%);
    border: 2px solid var(--compare-blue);
    border-radius: 20px;
    padding: 24px 20px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 100, 255, 0.15);
}

.compare-recommend-badge {
    position: absolute;
    top: 0;
    right: 20px;
    background: linear-gradient(135deg, var(--compare-blue) 0%, #3182F6 100%);
    color: white;
    font-size: 12px;
    font-weight: 700;
    padding: 8px 14px;
    border-radius: 0 0 12px 12px;
    box-shadow: 0 4px 12px rgba(0, 100, 255, 0.3);
}

.compare-recommend-winner-content {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 28px;
}

.compare-recommend-winner-image {
    width: 88px;
    height: 88px;
    border-radius: 16px;
    object-fit: cover;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    border: 3px solid white;
}

.compare-recommend-winner-info {
    flex: 1;
}

.compare-recommend-winner-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--compare-text-primary);
    margin-bottom: 8px;
    line-height: 1.35;
}

.compare-recommend-winner-score {
    font-size: 14px;
    color: var(--compare-text-secondary);
    display: flex;
    align-items: baseline;
    gap: 4px;
}

.compare-recommend-winner-score .score-value {
    font-size: 32px;
    font-weight: 800;
    color: var(--compare-blue);
    line-height: 1;
}

/* 점수 breakdown (토스 스타일) */
.compare-recommend-breakdown {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 100, 255, 0.15);
}

.breakdown-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 10px;
    font-size: 13px;
    backdrop-filter: blur(4px);
}

.breakdown-label {
    color: var(--compare-text-secondary);
    font-weight: 500;
}

.breakdown-value {
    font-weight: 700;
    color: var(--compare-blue);
}

/* 전체 순위 리스트 */
.compare-recommend-ranking-list {
    background: var(--compare-bg-white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--compare-shadow-card);
}

.compare-recommend-ranking-item {
    display: flex;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid var(--compare-line-weak);
    transition: background 0.15s ease;
}

.compare-recommend-ranking-item:last-child {
    border-bottom: none;
}

.compare-recommend-ranking-item.winner {
    background: linear-gradient(90deg, #E8F3FF 0%, transparent 100%);
}

.ranking-position {
    width: 40px;
    font-size: 20px;
    flex-shrink: 0;
}

.ranking-name {
    flex: 1;
    font-size: 15px;
    font-weight: 600;
    color: var(--compare-text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-right: 12px;
}

.ranking-score {
    font-size: 14px;
    font-weight: 700;
    color: var(--compare-blue);
    flex-shrink: 0;
    background: #E8F3FF;
    padding: 4px 10px;
    border-radius: 20px;
}

.compare-recommend-empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--compare-text-tertiary);
    font-size: 15px;
}

/* ============================================
 * 슬라이드 8: 상품 선택 스타일
 * ============================================ */

.compare-funnel-selection {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.compare-selection-card {
    display: flex;
    align-items: center;
    padding: 18px 16px;
    background: var(--compare-bg-white);
    border: 2px solid var(--compare-line-normal);
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    min-height: 96px;
}

.compare-selection-card:active {
    transform: scale(0.98);
}

.compare-selection-card.selected {
    border-color: var(--compare-blue);
    background: linear-gradient(135deg, #F0F7FF 0%, #E8F3FF 100%);
    box-shadow: 0 4px 16px rgba(0, 100, 255, 0.12);
}

.compare-selection-card.recommended {
    border-color: var(--compare-blue);
}

.compare-selection-radio {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.compare-selection-image {
    width: 68px;
    height: 68px;
    border-radius: 14px;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid var(--compare-line-weak);
}

.compare-selection-info {
    flex: 1;
    min-width: 0;
    margin-left: 14px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.compare-selection-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--compare-text-primary);
    line-height: 1.4;
    word-break: keep-all;
    text-align: left;
}

.compare-selection-price {
    font-size: 15px;
    font-weight: 600;
    color: var(--compare-text-secondary);
    text-align: left;
}

/* 추천 배지 */
.compare-selection-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: white;
    background: linear-gradient(135deg, #0064FF 0%, #3182F6 100%);
    padding: 6px 12px;
    border-radius: 20px;
    margin-left: 8px;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 100, 255, 0.25);
}

.compare-selection-check {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--compare-line-normal);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-left: 14px;
    transition: all 0.2s ease;
}

.compare-selection-check svg {
    opacity: 0;
    transition: opacity 0.2s ease;
}

.compare-selection-check svg path {
    stroke: white;
}

.compare-selection-card.selected .compare-selection-check {
    background: linear-gradient(135deg, #0064FF 0%, #3182F6 100%);
    box-shadow: 0 2px 8px rgba(0, 100, 255, 0.3);
}

.compare-selection-card.selected .compare-selection-check svg {
    opacity: 1;
}

/* ============================================
   가격 비공개 마스킹 스타일
   ============================================ */

/* 데스크톱 테이블 - 가격 비공개 */
.compare-price-masked {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--compare-text-tertiary, #8B95A1);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.compare-masked-lock {
    flex-shrink: 0;
    color: var(--compare-text-tertiary, #8B95A1);
}

.compare-masked-dots {
    color: var(--compare-text-tertiary, #8B95A1);
}

.compare-price-masked-hint {
    font-size: 12px;
    color: var(--compare-text-placeholder, #B0B8C1);
    margin-top: 4px;
}

/* 모바일 퍼널 - 가격 비공개 */
.compare-funnel-masked {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--compare-text-tertiary, #8B95A1);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.compare-funnel-masked .compare-masked-lock {
    flex-shrink: 0;
}

.compare-funnel-list-value.masked {
    color: var(--compare-text-tertiary, #8B95A1) !important;
    font-weight: 500 !important;
}

/* best 하이라이트가 masked와 겹치지 않도록 */
.compare-funnel-list-value.masked.best {
    color: var(--compare-text-tertiary, #8B95A1) !important;
    background: none !important;
}

/* ============ 투어 신청 모달 (TourRequest 모듈 — syncleai-gpt.css 이식) ============ */
:root {
  --cwm-bg: #fff;
  --cwm-fg: #14161a;
  --cwm-fg-secondary: rgba(0, 0, 0, 0.8);
  --cwm-fg-muted: rgba(0, 0, 0, 0.4);
  --cwm-fg-onbrand: #fff;
  --cwm-bg-card: #F7F8FA;
  --cwm-surface-04: rgba(0, 0, 0, 0.04);
  --cwm-border: rgba(0, 0, 0, 0.12);
  --cwm-border-strong: rgba(0, 0, 0, 0.2);
  --cwm-red: #E0492F;
  --cwm-r-8: 8px;
  --cwm-r-12: 12px;
  --cwm-r-16: 16px;
  --cwm-shadow-lg: 0 24px 48px rgba(0, 0, 0, 0.2);
}
.modal-overlay {
  position: fixed; inset: 0; z-index: 70; background: rgba(0, 0, 0, 0.42);
  display: flex; align-items: center; justify-content: center; padding: 20px;
  opacity: 0; transition: opacity 0.25s ease;
}
.modal-overlay.active { opacity: 1; }
.modal-content.tour-request-modal {
  background: var(--cwm-bg); border-radius: var(--cwm-r-16); width: 100%; max-width: 420px;
  max-height: 88vh; overflow-y: auto; box-shadow: var(--cwm-shadow-lg);
  transform: translateY(16px) scale(0.98); transition: transform 0.25s cubic-bezier(0.32, 0.72, 0, 1);
}
.modal-overlay.active .tour-request-modal { transform: none; }
@media (prefers-reduced-motion: reduce) {
  .modal-overlay, .modal-content.tour-request-modal { transition: none; }
}
.tour-request-modal .modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 20px 12px;
}
.tour-request-modal .modal-header h3 { margin: 0; font-size: 18px; font-weight: 700; color: var(--cwm-fg); }
.tour-request-modal .modal-close {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border: none; border-radius: var(--cwm-r-8);
  background: transparent; color: var(--cwm-fg-muted);
}
.tour-request-modal .modal-close:hover { background: var(--cwm-surface-04); }
.tour-request-modal .modal-body { padding: 0 20px 20px; }
.tour-request-modal .modal-info-box {
  display: flex; align-items: center; gap: 8px; padding: 10px 12px; margin-bottom: 16px;
  border-radius: var(--cwm-r-12); background: var(--cwm-bg-card);
  font-size: 13px; color: var(--cwm-fg-secondary);
}
.tour-request-modal .form-group { margin-bottom: 14px; }
.tour-request-modal .form-group label {
  display: block; margin-bottom: 6px; font-size: 13px; font-weight: 600; color: var(--cwm-fg);
}
.tour-request-modal .required { color: var(--cwm-red); }
.tour-request-modal .optional { color: var(--cwm-fg-muted); font-weight: 400; }
.tour-request-modal .toss-input, .tour-request-modal .toss-select {
  width: 100%; box-sizing: border-box; height: 44px; padding: 0 12px;
  border: 1px solid var(--cwm-border); border-radius: var(--cwm-r-12); background: var(--cwm-bg);
  font-family: inherit; font-size: 14px; color: var(--cwm-fg); outline: none;
}
.tour-request-modal textarea.toss-input { height: auto; padding: 10px 12px; resize: none; }
.tour-request-modal .toss-input:focus, .tour-request-modal .toss-select:focus { border-color: var(--cwm-border-strong); }
.tour-request-modal .modal-actions { display: flex; gap: 8px; margin-top: 18px; }
.tour-request-modal .btn-secondary {
  flex: 1; height: 44px; border: 1px solid var(--cwm-border); border-radius: var(--cwm-r-12);
  background: var(--cwm-bg); font-size: 14px; font-weight: 600; color: var(--cwm-fg);
}
.tour-request-modal .btn-secondary:hover { background: var(--cwm-surface-04); }
.tour-request-modal .btn-primary {
  flex: 2; height: 44px; border: none; border-radius: var(--cwm-r-12);
  background: var(--cwm-fg); color: var(--cwm-fg-onbrand); font-size: 14px; font-weight: 600;
}
.tour-request-modal .btn-primary:hover { opacity: 0.88; }
.tour-request-modal .btn-primary:disabled { opacity: 0.45; cursor: default; }
@media (max-width: 880px) {
  .modal-overlay { align-items: flex-end; padding: 0; }
  .modal-content.tour-request-modal {
    max-width: none; border-radius: 20px 20px 0 0; max-height: 92vh;
    transform: translateY(100%);
  }
  .modal-overlay.active .tour-request-modal { transform: none; }
}

