/* ─── Travel Product Detail — Scoped Styles ───────────────────────────────
   Loaded only on com_travel / travelproduct view (see template index.php).
   Extracted from components/com_travel/tmpl/travelproduct/{default,sppage}.php */

/* Helix compiles `.body-innerwrapper { overflow-x: hidden }` which creates a
   scroll container and breaks `position: sticky`. `clip` still prevents
   horizontal overflow but does NOT create a scroll container, so sticky works. */
.body-innerwrapper { overflow-x: clip; }

html { scroll-behavior: smooth; }

/* ─── Hero gallery ──────────────────────────────────────────────────────── */
.tp-detail .hero-gallery-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 1.5rem;
}
@media (min-width: 768px) {
    .tp-detail .hero-gallery-grid {
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: repeat(2, 180px);
    }
    .tp-detail .hero-gallery-grid .hero-main { grid-column: span 2; grid-row: span 2; }
    .tp-detail .hero-gallery-grid .hero-thumb { display: block; }
}
.tp-detail .hero-thumb { display: none; position: relative; overflow: hidden; cursor: pointer; }
.tp-detail .hero-main { position: relative; overflow: hidden; cursor: pointer; }
.tp-detail .hero-main img, .tp-detail .hero-thumb img {
    width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease;
}
.tp-detail .hero-main:hover img, .tp-detail .hero-thumb:hover img { transform: scale(1.05); }
.tp-detail .hero-overlay-btns {
    position: absolute; bottom: 12px; left: 12px;
    display: flex; flex-wrap: wrap; gap: 8px; z-index: 2;
}
.tp-detail .hero-overlay-btn {
    background: rgba(15,23,42,0.8); color: #fff; font-size: 0.875rem; font-weight: 600;
    padding: 6px 14px; border-radius: 999px; border: 1px solid rgba(255,255,255,0.2);
    backdrop-filter: blur(4px); display: inline-flex; align-items: center; gap: 6px;
    transition: background 0.2s; text-decoration: none;
}
.tp-detail .hero-overlay-btn:hover { background: rgba(15,23,42,1); color: #fff; }
.tp-detail .hero-overlay-btn i.text-accent { color: #f59e0b; }

/* ─── Tag pills ─────────────────────────────────────────────────────────── */
.tp-detail .tag-pill {
    display: inline-flex; align-items: center;
    font-size: 0.875rem; font-weight: 600; padding: 4px 12px; border-radius: 4px;
}
.tp-detail .tag-pill--secondary {
    background: #f1f5f9; color: #475569; border: 1px solid #e2e8f0;
}

/* ─── Section cards ─────────────────────────────────────────────────────── */
/* .tp-detail .section-card {
    background: #fff; padding: 1.5rem; border-radius: 12px;
    border: 1px solid #e2e8f0; margin-bottom: 2rem;
}
@media (min-width: 640px) { .tp-detail .section-card { padding: 2rem; } } */
.tp-detail .section-title {
    font-size: 1.5rem; font-weight: 700; color: #0f172a;
    border-left: 4px solid #f59e0b; padding-left: 0.75rem;
    margin-bottom: 1.5rem; line-height: 1.3;
}

/* ─── Plan cards ────────────────────────────────────────────────────────── */
.tp-detail .plan-card {
    border: 1px solid #e2e8f0; border-radius: 12px; padding: 16px;
    background: #fff; transition: border-color 0.2s, box-shadow 0.2s;
    display: flex; flex-direction: column; gap: 16px; position: relative;
}
@media (min-width: 640px) { .tp-detail .plan-card { padding: 20px; } }
@media (min-width: 768px) {
    .tp-detail .plan-card { flex-direction: row; justify-content: space-between; align-items: center; }
    .tp-detail .plan-card .plan-info { width: 70%; }
    .tp-detail .plan-card .plan-side { width: 30%; }
}
.tp-detail .plan-card:hover {
    border-color: #1e3a8a;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -2px rgba(0,0,0,0.1);
}
.tp-detail .plan-card.popular { border: 2px solid #fbbf24; background: rgba(255,251,235,0.2); }
.tp-detail .popular-badge {
    position: absolute; top: -12px; right: 16px;
    background: #f59e0b; color: #172554; font-weight: 700;
    font-size: 0.875rem; padding: 2px 10px; border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}
.tp-detail .plan-info > * + * { margin-top: 8px; }
.tp-detail .plan-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tp-detail .plan-index {
    flex-shrink: 0; background: #dbeafe; color: #1e3a8a;
    font-size: 14px; font-weight: 700; padding: 2px 8px; border-radius: 4px;
}
.tp-detail .plan-card.popular .plan-index { background: #f59e0b; color: #172554; }
.tp-detail .plan-info h3 { font-size: 16px; font-weight: 700; color: #0f172a; margin: 0; }
.tp-detail .plan-dates {
    display: inline-block; font-size: 14px; color: #475569; font-weight: 500;
    background: #f1f5f9; padding: 4px 12px; border-radius: 8px;
}
/* Icon is an <img>, so `color` can't tint it — the popular variant is a separate
   SVG file picked in the template. Keep it aligned with the text baseline. */
.tp-detail .plan-dates-icon { width: 16px; height: 16px; margin-right: 6px; vertical-align: -3px; display: inline; }
.tp-detail .plan-card.popular .plan-dates { background: rgba(254,243,199,0.6); }
.tp-detail .plan-desc { font-size: 16px; color: #475569; }
.tp-detail .plan-desc ul, .tp-detail .plan-desc ol { padding-left: 20px; margin: 0; }
.tp-detail .plan-desc ul { list-style: disc; }
.tp-detail .plan-desc li + li { margin-top: 6px; }
.tp-detail .plan-desc p:last-child { margin-bottom: 0; }
.tp-detail .plan-side {
    display: flex; flex-direction: row; justify-content: space-between; align-items: center; gap: 8px;
    width: 100%; border-top: 1px solid #e2e8f0; padding-top: 12px;
}
@media (min-width: 768px) {
    .tp-detail .plan-side {
        flex-direction: column; justify-content: space-between; align-items: flex-end;
        text-align: right; border-top: 0; padding-top: 0;
    }
}
/* custom-2.css styles bare .price-tag at 1.7rem/700/#002569; children inherit it,
   which blows up the "from" label. Reset at the container instead of fighting it
   on every descendant. */
.tp-detail .price-tag { font-size: 14px; font-weight: 400; color: #475569; line-height: 1.3; }
.tp-detail .price-label { display: block; font-size: 14px; font-weight: 400; color: #64748b; }
.tp-detail .price-row { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; justify-content: flex-start; }
@media (min-width: 768px) { .tp-detail .price-row { justify-content: flex-end; } }
.tp-detail .price-current { font-size: 20px; font-weight: 800; color: #1e3a8a; white-space: nowrap; }
@media (min-width: 640px) { .tp-detail .price-current { font-size: 24px; } }
.tp-detail .price-current .price-up { font-size: 14px; font-weight: 400; color: #64748b; }
.tp-detail .price-original { color: #94a3b8; white-space: nowrap; }
.tp-detail .plan-cta {
    display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
    background: #1e3a8a; color: #fff; font-weight: 700; font-size: 16px;
    padding: 10px 16px; border-radius: 8px; text-decoration: none; transition: background 0.2s;
}
.tp-detail .plan-cta:hover { background: #172554; color: #fff; }
.tp-detail .plan-card.popular .plan-cta { background: #f59e0b; color: #172554; }
.tp-detail .plan-card.popular .plan-cta:hover { background: #d97706; }

/* ─── FAQ accordion ─────────────────────────────────────────────────────── */
.tp-detail .faq-item { border: 1px solid #e2e8f0; border-radius: 8px; overflow: hidden; margin-bottom: 0.75rem; padding: 0; }
.tp-detail .faq-toggle {
    width: 100%; display: flex; justify-content: space-between; align-items: center;
    padding: 1rem; background: #f8fafc; border: none; cursor: pointer;
    font-weight: 600; color: #1e293b; font-size: 1rem; text-align: left; transition: background 0.2s;
}
.tp-detail .faq-toggle:hover { background: #f1f5f9; }
.tp-detail .faq-toggle i.faq-chevron { color: #94a3b8; flex-shrink: 0; transition: transform 0.2s; }
.tp-detail .faq-toggle.open i.faq-chevron { transform: rotate(180deg); }
.tp-detail .faq-content {
    display: none; padding: 1rem; color: #475569; font-size: 1rem;
    border-top: 1px solid #e2e8f0; line-height: 1.7;
}
.tp-detail .faq-content.show { display: block; }

/* ─── Sticky sidebar ────────────────────────────────────────────────────── */
.tp-detail .sidebar-widget {
    position: sticky; top: 90px;
    background: #fff; padding: 1.5rem; border-radius: 12px;
    border: 1px solid #e2e8f0; box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}
.tp-detail .sidebar-price-label { font-size: 0.875rem; color: #64748b; }
.tp-detail .sidebar-price-value { font-size: 2rem; font-weight: 800; color: #1e3a5f; }
.tp-detail .sidebar-cta {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%; background: #1e3a5f; color: #fff; font-weight: 700;
    padding: 14px; border-radius: 8px; text-decoration: none; transition: background 0.2s; font-size: 1rem;
}
.tp-detail .sidebar-cta:hover { background: #162d4a; color: #fff; }
.tp-detail .whatsapp-btn {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%; border: 1px solid #10b981; color: #047857;
    font-weight: 600; padding: 10px; border-radius: 8px; text-decoration: none; transition: background 0.2s;
}
.tp-detail .whatsapp-btn:hover { background: #ecfdf5; color: #047857; }

/* ─── Hotel cards ───────────────────────────────────────────────────────── */
.tp-detail .hotel-card {
    border: 1px solid #e2e8f0; border-radius: 12px; overflow: hidden;
    background: #fff; transition: box-shadow 0.2s; position: relative;
    display: flex; flex-direction: column; height: 100%;
}
.tp-detail .hotel-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.tp-detail .hotel-card img { width: 100%; height: 192px; object-fit: cover; }
.tp-detail .hotel-card-body { padding: 1rem; flex: 1; display: flex; flex-direction: column; gap: 0.35rem; }
.tp-detail .hotel-card-name-row { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.tp-detail .hotel-card-name-row h3 { margin: 0; font-size: 0.95rem; font-weight: 700; color: #1a1a1a; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; min-width: 0; }
.tp-detail .hotel-card-stars { color: #f5a623; font-size: 0.8rem; white-space: nowrap; flex-shrink: 0; }
.tp-detail .hotel-card-remarks { font-size: 0.8rem; color: #555; line-height: 1.45; }
.tp-detail .hotel-card-remarks i { color: #f5a623; margin-right: 0.3rem; }
.tp-detail .hotel-card-address { font-size: 0.78rem; color: #888; display: flex; align-items: flex-start; gap: 0.3rem; line-height: 1.4; }
.tp-detail .hotel-card-address i { color: #f5a623; margin-top: 0.15rem; flex-shrink: 0; }
.tp-detail .hotel-card-map-link { color: #e07b00; font-weight: 600; text-decoration: none; margin-left: 0.25rem; white-space: nowrap; position: relative; z-index: 2; }
.tp-detail .hotel-card-map-link:hover { text-decoration: underline; }

/* ─── Related / Recently viewed cards ───────────────────────────────────── */
.tp-detail .rv-card {
    border: 1px solid #e2e8f0; border-radius: 12px; overflow: hidden;
    background: #fff; transition: box-shadow 0.2s; position: relative;
}
.tp-detail .rv-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.tp-detail .rv-card img { width: 100%; height: 176px; object-fit: cover; }
.tp-detail .rv-badge {
    position: absolute; top: 8px; left: 8px;
    background: rgba(15,23,42,0.8); color: #fff;
    font-size: 0.75rem; padding: 2px 10px; border-radius: 4px;
}
.tp-detail .rv-badge--recommended {
    background: #ea580c;
}

/* ─── Carousel headers + round nav buttons ──────────────────────────────── */
.tp-detail .tp-carousel-head {
    display: flex; justify-content: space-between; align-items: center;
    gap: 1rem; margin-bottom: 1.25rem;
}
.tp-detail .tp-carousel-nav { display: flex; gap: 8px; flex-shrink: 0; }
.tp-detail .tp-carousel-btn {
    width: 36px; height: 36px; border-radius: 50%;
    border: 1px solid #e2e8f0; background: #fff; color: #334155;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; transition: border-color .2s, color .2s, box-shadow .2s;
    font-size: 0.8rem; padding: 0;
}
.tp-detail .tp-carousel-btn:hover { border-color: #1e3a5f; color: #1e3a5f; box-shadow: 0 2px 8px rgba(30,58,95,.15); }
.tp-detail .tp-carousel-btn.swiper-button-disabled { opacity: .35; pointer-events: none; }

/* ─── Package highlights card (#highlights) ─────────────────────────────── */
/* .tp-detail .tp-highlights-card { background: #fff; padding: 16px; border: 1px solid #e2e8f0; border-radius: 12px; } */
/* @media (min-width: 640px) { .tp-detail .tp-highlights-card { padding: 24px; } } */
.tp-detail .tp-highlights-card > .section-title { margin-bottom: 1rem; }
.tp-detail .tp-highlights-list {
    display: flex; flex-direction: column; gap: 12px;
    margin: 0; padding: 0; list-style: none;
    font-size: 16px; color: #334155;
}
.tp-detail .tp-highlights-list li { display: flex; align-items: flex-start; gap: 10px; }
.tp-detail .tp-highlights-list li i { color: #1e3a8a; margin-top: 4px; flex-shrink: 0; }

/* ─── Mobile bottom bar ─────────────────────────────────────────────────── */
.tp-detail .mobile-bottom-bar {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 5000;
    background: #fff; border-top: 1px solid #e2e8f0; padding: 12px 16px;
    box-shadow: 0 -4px 16px rgba(0,0,0,0.12);
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
@media (min-width: 1024px) { .tp-detail .mobile-bottom-bar { display: none; } }

/* ─── Media lightbox modal ──────────────────────────────────────────────── */
.tp-media-modal {
    position: fixed; inset: 0; z-index: 9999;
    display: flex; align-items: center; justify-content: center;
}
.tp-media-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.88); }
.tp-media-box {
    position: relative; z-index: 1;
    width: min(90vw, 1280px); max-height: 88vh;
    display: flex; flex-direction: column;
}
.tp-media-close {
    position: absolute; top: -44px; right: 0;
    background: transparent; border: none; color: #fff;
    font-size: 2.25rem; cursor: pointer; line-height: 1; padding: 0 8px;
}
.tp-media-close:hover { color: #f59e0b; }
.tp-media-main {
    background: #000; border-radius: 8px; overflow: hidden;
    aspect-ratio: 16/9; display: flex; align-items: center;
    justify-content: center; position: relative;
}
.tp-media-main img { width: 100%; height: 100%; object-fit: contain; }
.tp-media-main iframe { width: 100%; height: 100%; border: none; }
.tp-media-main video { width: 100%; height: 100%; object-fit: contain; background: #000; }
.tp-media-nav {
    position: absolute; top: 50%; transform: translateY(-50%);
    background: transparent; border: none; color: #fff;
    font-size: 2.5rem; width: 48px; height: 72px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; border-radius: 4px; z-index: 2; transition: background 0.2s; padding: 0;
}
.tp-media-prev { left: -60px; }
.tp-media-next { right: -60px; }
.tp-media-nav:hover { background: rgba(0,0,0,0.9); }
@media (max-width: 767px) {
    .tp-media-box { width: 100vw; }
    .tp-media-prev { left: 8px; }
    .tp-media-next { right: 8px; }
}
.tp-media-strip {
    display: flex; gap: 6px; margin-top: 10px;
    overflow-x: auto; padding: 4px 0;
    scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.3) transparent;
}
.tp-media-strip::-webkit-scrollbar { height: 4px; }
.tp-media-strip::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.3); border-radius: 2px; }
.tp-media-strip-thumb {
    flex-shrink: 0; width: 72px; height: 48px; border-radius: 4px; overflow: hidden;
    cursor: pointer; border: 2px solid transparent; transition: border-color 0.2s;
    background: #1e293b; display: flex; align-items: center; justify-content: center;
}
.tp-media-strip-thumb.active { border-color: #f59e0b; }
.tp-media-strip-thumb img { width: 100%; height: 100%; object-fit: cover; }
.tp-media-strip-icon { color: #fff; font-size: 1.25rem; }
.view-travelproduct .sp-scroll-up {
    bottom: 120px;
}