/* ═══════════════════════════════════════════════════
   CRUISE SEARCH RESULT v3.0
   style.css üzerine ek - Sticky Filter + Infinite Scroll
═══════════════════════════════════════════════════ */

/* ═══ STICKY FILTER SIDEBAR ═══ */
.filters-sidebar-sticky {
    position: sticky;
    top: 80px; /* header yüksekliği kadar */
    max-height: calc(100vh - 100px);
    padding-bottom: 1rem;
    /* Özel scrollbar */
    scrollbar-width: thin;
    scrollbar-color: var(--slate-200) transparent;
}
.filters-sidebar-sticky::-webkit-scrollbar { width: 5px; }
.filters-sidebar-sticky::-webkit-scrollbar-track { background: transparent; }
.filters-sidebar-sticky::-webkit-scrollbar-thumb { background: var(--slate-200); border-radius: 4px; }
.filters-sidebar-sticky::-webkit-scrollbar-thumb:hover { background: var(--slate-300); }

/* Sticky header shadow on scroll */
.filter-card {
    position: relative;
    overflow: hidden;
}

.filter-card .filter-body {
    overflow-y: auto;
    max-height: calc(100vh - 180px);
    overflow-x: hidden;
}

/* ═══ FILTER CHECKS SCROLLABLE ═══ */
.filter-checks-scroll { max-height: 200px; overflow-y: auto; padding-right: .25rem; }
.filter-checks-scroll::-webkit-scrollbar { width: 4px; }
.filter-checks-scroll::-webkit-scrollbar-track { background: transparent; }
.filter-checks-scroll::-webkit-scrollbar-thumb { background: var(--slate-200); border-radius: 4px; }
.filter-checks-scroll::-webkit-scrollbar-thumb:hover { background: var(--slate-300); }
.filter-check.is-disabled { opacity: .35; pointer-events: none; }
.filter-title .filter-count-badge { font-size: .68rem; font-weight: 700; color: var(--primary); margin-left: .25rem; }
.filter-empty-msg { padding: .75rem .5rem; color: var(--slate-400); font-size: .82rem; text-align: center; font-style: italic; }

/* ═══ SKELETON ═══ */
.skeleton-shimmer {
    background: linear-gradient(90deg, var(--slate-100) 25%, rgba(255,255,255,.2) 50%, var(--slate-100) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius-md);
}
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

.tour-skeleton {
    background: var(--white);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    opacity: 0;
    animation: skelFadeIn .4s ease forwards;
}
@keyframes skelFadeIn { to { opacity: 1; } }
.tour-skeleton .skel-image { height: 200px; }
.tour-skeleton .skel-body { padding: 1.25rem; display: flex; flex-direction: column; gap: .65rem; }
.tour-skeleton .skel-line { height: 14px; }
.skel-w80 { width: 80%; } .skel-w60 { width: 60%; } .skel-w40 { width: 40%; }
.filter-skel-group { padding: 1rem 1.5rem; display: flex; flex-direction: column; gap: .6rem; }

/* ═══ NO RESULTS ═══ */
.no-results-box {
    text-align: center;
    padding: 4rem 2rem;
    background: var(--white);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-md);
    border: 2px dashed var(--slate-200);
}
.no-results-box i.icon { font-size: 3.5rem; color: var(--slate-300); margin-bottom: 1.25rem; display: block; }
.no-results-box h5 { color: var(--navy-deep); margin-bottom: .5rem; font-weight: 700; }
.no-results-box p { color: var(--slate-500); font-size: .9rem; margin-bottom: 1.5rem; }

/* ═══ INFINITE SCROLL ═══ */
.infinite-loader {
    display: none;
    text-align: center;
    padding: 2.5rem 1rem;
    grid-column: 1 / -1;
}
.infinite-loader .loader-spinner {
    width: 36px; height: 36px;
    border: 3px solid var(--slate-200);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spinLoader .7s linear infinite;
    margin: 0 auto .75rem;
}
@keyframes spinLoader { to { transform: rotate(360deg); } }
.infinite-loader span { font-size: .85rem; color: var(--slate-500); font-weight: 500; }

/* Scroll progress */
.scroll-info {
    display: none;
    text-align: center;
    padding: 1.5rem 0 .5rem;
    grid-column: 1 / -1;
}
.scroll-info-inner {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: .5rem;
}
.scroll-count { font-size: .82rem; color: var(--slate-500); font-weight: 500; }
.scroll-count strong { color: var(--navy-deep); font-weight: 700; }
.scroll-progress-track {
    width: 200px; height: 4px;
    background: var(--slate-200);
    border-radius: 4px;
    overflow: hidden;
}
.scroll-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--accent, var(--primary)));
    border-radius: 4px;
    transition: width .4s ease;
    width: 0;
}
.scroll-end-text {
    display: none;
    font-size: .78rem;
    color: var(--slate-400);
    font-weight: 500;
    padding-top: .15rem;
}

/* ═══ CARD ENHANCEMENTS ═══ */
.tour-card-listing {
    transition: transform .25s ease, box-shadow .25s ease;
}
.tour-card-listing:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}
.tour-card-image img {
    transition: transform .5s ease;
}
.tour-card-listing:hover .tour-card-image img {
    transform: scale(1.05);
}

/* Airline satırı */
.tour-card-airline {
    display: flex;
    align-items: center;
    gap: .35rem;
    font-size: .78rem;
    color: var(--slate-500);
    font-weight: 500;
    padding: .1rem 0;
}
.tour-card-airline i { color: var(--primary); font-size: .75rem; }

/* Meta ship */
.tour-card-meta .meta-ship { color: var(--primary); font-weight: 600; }

/* Fiyat 0 → Sorunuz */
.price-call {
    color: var(--primary) !important;
    font-size: 1rem !important;
    font-weight: 700;
}

/* Rehberli badge */
.badge-guide {
    background: linear-gradient(135deg, #059669, #10b981);
    color: var(--white);
    padding: .25rem .6rem;
    border-radius: var(--radius-full);
    font-size: .7rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: .25rem;
}

/* Date chip more */
.date-chip.more {
    background: var(--primary-soft, rgba(0,105,255,.08)) !important;
    color: var(--primary) !important;
    font-weight: 700 !important;
    border-color: transparent !important;
}
.date-chip.more:hover {
    background: var(--primary) !important;
    color: var(--white) !important;
}

/* Favorite active */
.tour-card-favorite.active { color: #ef4444 !important; }
.tour-card-favorite.active i { color: #ef4444; }

/* ═══ DATES POPUP ═══ */
.dates-popup-overlay {
    position: fixed; inset: 0;
    background: rgba(15,23,42,.6);
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    z-index: 1060;
    display: none;
    align-items: center; justify-content: center;
    padding: 1rem;
}
.dates-popup-overlay.show { display: flex; animation: fadeIn .2s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.dates-popup {
    background: var(--white);
    border-radius: var(--radius-2xl);
    max-width: 580px; width: 100%;
    max-height: 80vh;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,.25);
    display: flex; flex-direction: column;
    animation: popupSlideUp .3s ease;
}
@keyframes popupSlideUp { from { opacity:0; transform:translateY(16px); } to { opacity:1; transform:translateY(0); } }

.dates-popup-header { display: flex; align-items: center; gap: 1rem; padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--slate-100); }
.dates-popup-thumb { width: 64px; height: 64px; border-radius: var(--radius-lg); overflow: hidden; flex-shrink: 0; }
.dates-popup-thumb img { width: 100%; height: 100%; object-fit: cover; }
.dates-popup-info { flex: 1; }
.dates-popup-info h4 { font-size: .95rem; font-weight: 700; color: var(--navy-deep); margin: 0 0 .25rem; }
.dates-popup-meta { display: flex; gap: 1rem; font-size: .8rem; color: var(--slate-500); }
.dates-popup-meta span { display: flex; align-items: center; gap: .25rem; }
.dates-popup-meta i { color: var(--primary); }
.dates-popup-close { background: var(--slate-100); border: none; width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--slate-500); cursor: pointer; transition: var(--transition-fast); }
.dates-popup-close:hover { background: var(--slate-200); color: var(--navy-deep); }
.dates-popup-body { padding: 1.25rem 1.5rem; overflow-y: auto; }
.dates-popup-label { font-size: .78rem; font-weight: 700; color: var(--slate-500); text-transform: uppercase; letter-spacing: .05em; margin-bottom: .75rem; }
.dates-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(145px, 1fr)); gap: .5rem; }
.date-card-popup {
    border: 2px solid var(--slate-200);
    border-radius: var(--radius-lg);
    padding: .75rem;
    cursor: pointer;
    transition: all .2s ease;
    text-align: center;
}
.date-card-popup:hover { border-color: var(--primary); transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.date-card-popup.selected { border-color: var(--primary); background: var(--primary-soft, rgba(0,105,255,.08)); }
.date-card-popup .dc-date { font-weight: 700; font-size: .85rem; color: var(--navy-deep); margin-bottom: .15rem; }
.date-card-popup .dc-price { font-size: .82rem; font-weight: 700; color: var(--primary); }
.date-card-popup .dc-price-ask { color: var(--slate-400); font-style: italic; }
.date-card-popup .dc-night { font-size: .7rem; color: var(--slate-400); }
.date-card-popup .dc-stock { font-size: .7rem; margin-top: .2rem; display: flex; align-items: center; justify-content: center; gap: .2rem; }
.dc-stock.critical { color: var(--coral, #f43f5e); }
.dc-stock.limited { color: var(--warning, #f59e0b); }
.dc-stock.available { color: var(--success, #10b981); }
.dates-popup-footer { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.5rem; border-top: 1px solid var(--slate-100); }
.dates-popup-selected { font-size: .82rem; color: var(--slate-500); }
.dates-popup-selected strong { color: var(--navy-deep); }
.dates-popup-btn { display: inline-flex; align-items: center; gap: .4rem; padding: .6rem 1.5rem; background: var(--navy-deep); color: var(--white); border: none; border-radius: var(--radius-full); font-size: .85rem; font-weight: 700; cursor: pointer; transition: all .2s ease; }
.dates-popup-btn:hover { background: var(--primary); transform: translateY(-1px); }

/* ═══ OFFCANVAS ═══ */
.filter-offcanvas .offcanvas-footer { display: flex; gap: .75rem; padding: 1rem 1.25rem; border-top: 1px solid var(--slate-100); }
.filter-offcanvas .offcanvas-footer .btn { flex: 1; }

/* ═══ LIST VIEW ═══ */
.tours-grid.list-view { grid-template-columns: 1fr; }
.tours-grid.list-view .tour-card-listing { display: grid; grid-template-columns: 280px 1fr; }
.tours-grid.list-view .tour-card-image { height: 100%; min-height: 220px; }
.tours-grid.list-view .tour-card-image img { height: 100%; }
@media (max-width: 991.98px) {
    .tours-grid.list-view .tour-card-listing { grid-template-columns: 1fr; }
    .tours-grid.list-view .tour-card-image { min-height: auto; }
    .filters-sidebar-sticky { position: static; max-height: none; overflow: visible; }
}

/* ═══════════════════════════════════════════════════
   CRUISE SEARCH — tc-* KARTI UYUM EKLERİ
   search-results.css + style.css ile birlikte kullanılır
═══════════════════════════════════════════════════ */

/* ── Skeleton: tc-img yüksekliği ── */
.tour-skeleton .tc-img {
    aspect-ratio: 16 / 10;
    min-height: 180px;
    border-radius: var(--r-lg, 12px) var(--r-lg, 12px) 0 0;
}
.tour-skeleton .tc-body {
    padding: 1rem 1.1rem;
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

/* ── tc-img link overlay ── */
.tc-img { position: relative; }
.tc-img-link {
    position: absolute;
    inset: 0;
    z-index: 1;
}

/* ── tc-fav (favori) buton ── */
.tc-fav {
    position: absolute;
    top: 12px; right: 12px;
    z-index: 5;
    background: rgba(255,255,255,.92);
    backdrop-filter: blur(6px);
    border: none;
    width: 34px; height: 34px;
    border-radius: 50%;
    display: grid; place-items: center;
    cursor: pointer;
    color: var(--ink-mute, #94a3b8);
    transition: all .2s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,.12);
}
.tc-fav:hover,
.tc-fav.active { color: #ef4444; }
.tc-fav [data-lucide] { width: 16px; height: 16px; }

/* ── active-filter chips (JS renderActiveBar) ── */
.active-filter {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #fff;
    border: 1.5px solid var(--orange, #FF5A36);
    color: var(--orange-dark, #c2410c);
    padding: 5px 9px 5px 12px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all .2s ease;
}
.active-filter:hover { background: var(--orange, #FF5A36); color: #fff; }
.active-filter [data-lucide], .active-filter .bi { width: 13px; height: 13px; }

/* ── filter-tag (ay / gece / özellik butonları) ── */
.filter-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--bg-soft, #f8fafc);
    border: 1.5px solid var(--line, #e2e8f0);
    color: var(--ink-2, #475569);
    padding: 6px 12px;
    border-radius: 100px;
    font-size: 12.5px;
    font-weight: 700;
    cursor: pointer;
    transition: all .2s ease;
    margin: 2px;
}
.filter-tag:hover { border-color: var(--orange, #FF5A36); color: var(--orange, #FF5A36); }
.filter-tag.active {
    background: var(--orange, #FF5A36);
    border-color: var(--orange, #FF5A36);
    color: #fff;
}
.filter-tag [data-lucide] { width: 13px; height: 13px; }

/* ── filter-check (checkbox satırı — JS renderCB) ── */
.filter-check {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: var(--ink-2, #475569);
    transition: background .15s ease;
}
.filter-check:hover { background: var(--bg-soft, #f8fafc); }
.filter-check input[type="checkbox"] {
    width: 15px; height: 15px;
    accent-color: var(--orange, #FF5A36);
    cursor: pointer;
    flex-shrink: 0;
}
.filter-check .checkmark { display: none; } /* native checkbox kullanıyoruz */
.filter-check .label-text { flex: 1; }
.filter-check .count {
    font-size: 11px;
    font-weight: 600;
    color: var(--ink-soft, #94a3b8);
    background: var(--bg-mute, #f1f5f9);
    padding: 2px 6px;
    border-radius: 100px;
}
.filter-check:has(input:checked) { color: var(--ink, #0f172a); font-weight: 700; }
.filter-check:has(input:checked) .count {
    background: var(--orange-soft, #fff0eb);
    color: var(--orange-dark, #c2410c);
}
.filter-check.is-disabled { opacity: .35; pointer-events: none; }

/* ── Scroll info ── */
.scroll-info { padding: 1.25rem 0 .5rem; }
.scroll-info-inner { display: inline-flex; flex-direction: column; align-items: center; gap: .4rem; }
.scroll-count { font-size: .82rem; color: var(--ink-mute, #94a3b8); font-weight: 600; }
.scroll-count strong { color: var(--ink, #0f172a); }
.scroll-progress-track { width: 180px; height: 4px; background: var(--line, #e2e8f0); border-radius: 4px; overflow: hidden; }
.scroll-progress-bar { height: 100%; background: var(--orange, #FF5A36); border-radius: 4px; transition: width .4s ease; width: 0; }
.scroll-end-text { display: none; font-size: .78rem; color: var(--ink-soft, #94a3b8); font-weight: 600; }
.scroll-end-text [data-lucide] { width: 13px; height: 13px; }

/* ── Infinite loader ── */
.infinite-loader { display: none; text-align: center; padding: 2rem 1rem; }
.infinite-loader .loader-spinner {
    width: 32px; height: 32px;
    border: 3px solid var(--line, #e2e8f0);
    border-top-color: var(--orange, #FF5A36);
    border-radius: 50%;
    animation: spinLoader .7s linear infinite;
    margin: 0 auto .6rem;
}
@keyframes spinLoader { to { transform: rotate(360deg); } }
.infinite-loader span { font-size: .84rem; color: var(--ink-mute, #94a3b8); font-weight: 600; }

/* ── No results ── */
.no-results-box {
    text-align: center;
    padding: 3.5rem 2rem;
    background: #fff;
    border-radius: var(--r-lg, 12px);
    border: 2px dashed var(--line, #e2e8f0);
}
.no-results-box .icon { font-size: 3rem; color: var(--line, #e2e8f0); margin-bottom: 1rem; display: block; }
.no-results-box .icon [data-lucide] { width: 48px; height: 48px; }
.no-results-box h5 { color: var(--ink, #0f172a); font-weight: 800; margin-bottom: .4rem; }
.no-results-box p { color: var(--ink-mute, #94a3b8); font-size: .9rem; margin-bottom: 1.25rem; }

/* ── Liste görünümü: results-grid.is-list ── */
.results-grid.is-list { grid-template-columns: 1fr !important; }
.results-grid.is-list .tour-card { flex-direction: row !important; }
.results-grid.is-list .tc-img {
    width: 300px !important;
    flex-shrink: 0;
    aspect-ratio: auto !important;
    min-height: 100% !important;
    border-radius: var(--r-lg, 12px) 0 0 var(--r-lg, 12px) !important;
}
.results-grid.is-list .tc-body { flex: 1; }
@media (max-width: 767px) {
    .results-grid.is-list .tour-card { flex-direction: column !important; }
    .results-grid.is-list .tc-img { width: 100% !important; aspect-ratio: 16/10 !important; min-height: auto !important; border-radius: var(--r-lg, 12px) var(--r-lg, 12px) 0 0 !important; }
}
