/* ===== Ficha del tour / Carrito / Checkout - TourPeruTravel ===== */
:root { --ft-navy: #0c1833; --ft-orange: #d4921f; --ft-gold: #f0c05a; --ft-green: #16a34a; --ft-text: #1f2937; --ft-muted: #6b7280; --ft-line: #e5e7eb; }
html.ft-lock, html.ft-lock body { overflow: hidden !important; }

/* Tarjetas: aviso "ver detalles" */
.package-card { cursor: pointer; }
.package-card .package-carousel { position: relative; }
.package-card .ft-hint { position: absolute; left: 50%; bottom: 14px; transform: translate(-50%, 8px); background: rgba(12,24,51, .85); color: #fff; font-size: 13px; font-weight: 600; padding: 7px 14px; border-radius: 999px; opacity: 0; transition: .25s; pointer-events: none; white-space: nowrap; z-index: 3; }
.package-card:hover .ft-hint { opacity: 1; transform: translate(-50%, 0); }
.package-card .carousel-image { transition: transform .5s ease; }
.package-card:hover .carousel-image.active { transform: scale(1.05); }
@media (hover: none) { .package-card .ft-hint { opacity: 1; transform: translate(-50%, 0); font-size: 12px; } }

/* Overlay + modal */
.ft-overlay { position: fixed; inset: 0; z-index: 100000; background: rgba(5, 10, 30, .72); backdrop-filter: blur(4px); display: flex; align-items: flex-start; justify-content: center; overflow-y: auto; padding: 32px 16px; opacity: 0; transition: opacity .25s; }
.ft-overlay.show { opacity: 1; }
.ft-modal { position: relative; width: 100%; max-width: 1120px; background: #fff; border-radius: 20px; overflow: hidden; box-shadow: 0 30px 80px rgba(0, 0, 0, .45); color: var(--ft-text); transform: translateY(20px); transition: transform .3s; text-align: left; }
.ft-overlay.show .ft-modal { transform: none; }
.ft-close { position: absolute; top: 14px; right: 14px; z-index: 5; width: 42px; height: 42px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); font-size: 28px; line-height: 1; cursor: pointer; box-shadow: 0 4px 14px rgba(0, 0, 0, .2); color: #111; }

/* Galería */
.ft-gallery { background: #0b0f24; }
.ft-main { position: relative; aspect-ratio: 16 / 7; overflow: hidden; }
.ft-main img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .5s; }
.ft-main img.on { opacity: 1; }
.ft-main::after { content: ""; position: absolute; inset: auto 0 0 0; height: 35%; background: linear-gradient(transparent, rgba(0, 0, 0, .45)); pointer-events: none; }
.ft-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .85); font-size: 30px; line-height: 1; cursor: pointer; color: #111; }
.ft-nav.prev { left: 14px; } .ft-nav.next { right: 14px; }
.ft-badge { position: absolute; top: 16px; left: 16px; z-index: 2; background: #ef4444; color: #fff; font-weight: 700; padding: 6px 12px; border-radius: 999px; font-size: 14px; }
.ft-thumbs { display: flex; gap: 8px; padding: 10px 14px; }
.ft-thumbs img { width: 84px; height: 56px; object-fit: cover; border-radius: 8px; cursor: pointer; opacity: .55; border: 2px solid transparent; transition: .2s; }
.ft-thumbs img.on, .ft-thumbs img:hover { opacity: 1; border-color: var(--ft-orange); }

/* Cuerpo */
.ft-body { display: grid; grid-template-columns: 1fr 340px; gap: 32px; padding: 28px 32px 36px; }
.ft-head h2 { font-size: 30px; margin: 0 0 8px; color: var(--ft-navy); line-height: 1.2; }
.ft-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--ft-muted); font-size: 14px; margin-bottom: 14px; }
.ft-desc { font-size: 16px; line-height: 1.65; margin: 0 0 14px; }
.ft-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.ft-chips span { background: #faf3e3; color: #9a4b00; font-size: 13px; padding: 6px 12px; border-radius: 999px; }

.ft-sec { border: 1px solid var(--ft-line); border-radius: 14px; margin-bottom: 10px; background: #fff; overflow: hidden; }
.ft-sec summary { list-style: none; cursor: pointer; padding: 15px 18px; font-weight: 700; font-size: 16px; display: flex; align-items: center; gap: 10px; color: var(--ft-navy); }
.ft-sec summary::-webkit-details-marker { display: none; }
.ft-sec summary:hover { background: #fafafa; }
.ft-ico { width: 26px; text-align: center; }
.ft-chev { margin-left: auto; font-size: 22px; transition: transform .2s; color: var(--ft-muted); }
.ft-sec[open] .ft-chev { transform: rotate(90deg); }
.ft-sec-body { padding: 0 18px 18px 54px; font-size: 15px; line-height: 1.6; }

.ft-list { margin: 0; padding: 0; list-style: none; }
.ft-list li { position: relative; padding: 4px 0 4px 24px; }
.ft-list li::before { content: "•"; position: absolute; left: 6px; color: var(--ft-orange); font-weight: 700; }
.ft-list.ok li::before { content: "✓"; color: var(--ft-green); left: 2px; }
.ft-list.no li::before { content: "✕"; color: #dc2626; left: 2px; }
.ft-list.warn li::before { content: "!"; color: #d97706; left: 6px; }

.ft-timeline { list-style: none; margin: 0; padding: 0; border-left: 2px dashed #fed7aa; }
.ft-timeline li { position: relative; padding: 0 0 14px 20px; }
.ft-timeline li::before { content: ""; position: absolute; left: -7px; top: 4px; width: 12px; height: 12px; border-radius: 50%; background: var(--ft-orange); box-shadow: 0 0 0 3px #fff3e0; }
.ft-time { display: inline-block; font-weight: 700; color: var(--ft-orange); font-size: 14px; }
.ft-timeline p { margin: 2px 0 0; }

.ft-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.ft-table th, .ft-table td { padding: 9px 10px; border-bottom: 1px solid var(--ft-line); text-align: left; }
.ft-table th { background: #f8fafc; color: var(--ft-muted); font-weight: 600; }
.ft-table small { color: var(--ft-green); font-weight: 600; }
.ft-note { font-size: 13px; color: var(--ft-muted); margin: 10px 0 0; }

.ft-reviews { background: linear-gradient(135deg, #fff7ed, #fffbeb); border-radius: 12px; padding: 16px; }
.ft-rev-head { display: flex; gap: 12px; align-items: flex-start; }
.ft-rev-head p { margin: 4px 0 0; font-size: 14px; color: var(--ft-muted); }
.ft-stars { color: #f59e0b; font-size: 22px; letter-spacing: 2px; white-space: nowrap; }
.ft-rev-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.ft-rev-btn { text-decoration: none; font-size: 14px; font-weight: 600; padding: 9px 14px; border-radius: 10px; color: #fff; }
.ft-rev-btn.video { background: var(--ft-navy); }
.ft-rev-btn.ta { background: #00aa6c; }
.ft-rev-btn.gg { background: #4285f4; }

/* Caja de reserva */
.ft-book { position: sticky; top: 16px; align-self: start; border: 1px solid var(--ft-line); border-radius: 18px; padding: 20px; box-shadow: 0 12px 30px rgba(12,24,51, .1); background: #fff; }
.ft-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin-bottom: 14px; }
.ft-price small { width: 100%; color: var(--ft-muted); }
.ft-price s { color: var(--ft-muted); font-size: 16px; }
.ft-price strong { font-size: 34px; color: var(--ft-orange); }
.ft-price span { color: var(--ft-muted); font-size: 13px; }
.ft-field { display: block; margin-bottom: 12px; }
.ft-field span { display: block; font-size: 13px; font-weight: 600; margin-bottom: 5px; color: #374151; }
.ft-field input, .ft-field textarea { width: 100%; box-sizing: border-box; padding: 11px 12px; border: 1px solid #d1d5db; border-radius: 10px; font: inherit; font-size: 15px; color: #111; background: #fff; }
.ft-field input:focus, .ft-field textarea:focus { outline: 2px solid #fdba74; border-color: var(--ft-orange); }
.err { border-color: #dc2626 !important; background: #fef2f2 !important; }
.ft-count { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid #f1f5f9; }
.ft-count small { display: block; color: var(--ft-muted); font-size: 12px; }
.ft-step { display: flex; align-items: center; gap: 10px; }
.ft-step button { width: 34px; height: 34px; border-radius: 50%; border: 1px solid #d1d5db; background: #fff; font-size: 20px; cursor: pointer; color: var(--ft-navy); }
.ft-step button:hover { border-color: var(--ft-orange); color: var(--ft-orange); }
.ft-step span { min-width: 18px; text-align: center; font-weight: 700; }
.ft-sum { margin: 14px 0; font-size: 14px; }
.ft-sum div, .ft-total, .ck-row { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; }
.ft-dsc { color: var(--ft-green); font-weight: 600; }
.ft-total { border-top: 1px solid var(--ft-line); margin-top: 6px; padding-top: 10px; font-size: 18px; font-weight: 800; color: var(--ft-navy); }
.ft-btn { display: block; width: 100%; padding: 14px; border-radius: 12px; font-size: 16px; font-weight: 700; cursor: pointer; margin-top: 10px; border: 0; transition: .2s; }
.ft-btn.primary { background: linear-gradient(135deg, var(--ft-orange), var(--ft-gold)); color: #1a1200; box-shadow: 0 8px 20px rgba(212,146,31, .35); }
.ft-btn.primary:hover { transform: translateY(-1px); }
.ft-btn.ghost { background: #fff; color: var(--ft-navy); border: 2px solid var(--ft-navy); }
.ft-btn.ghost:hover { background: var(--ft-navy); color: #fff; }
.ft-safe { font-size: 13px; color: var(--ft-green); line-height: 1.7; margin: 14px 0 6px; }
.ft-wa { display: block; text-align: center; font-size: 14px; color: #128c7e; font-weight: 600; text-decoration: none; margin-top: 6px; }

/* Botón flotante del carrito */
#tpt-cart-btn { position: fixed; left: 18px; bottom: 18px; z-index: 9999; width: 58px; height: 58px; border-radius: 50%; border: 0; background: var(--ft-navy); color: #fff; cursor: pointer; box-shadow: 0 10px 25px rgba(0, 0, 0, .3); display: none; align-items: center; justify-content: center; }
#tpt-cart-btn.has { display: flex; }
#tpt-cart-btn span { position: absolute; top: -4px; right: -4px; background: var(--ft-orange); color: #fff; font-size: 12px; font-weight: 800; min-width: 22px; height: 22px; border-radius: 11px; display: flex; align-items: center; justify-content: center; border: 2px solid #fff; }

/* Cajón del carrito */
.cd { position: fixed; inset: 0; z-index: 100000; background: rgba(5, 10, 30, .6); opacity: 0; transition: .25s; }
.cd.show { opacity: 1; }
.cd-panel { position: absolute; right: 0; top: 0; bottom: 0; width: min(420px, 100%); background: #fff; display: flex; flex-direction: column; transform: translateX(100%); transition: .3s; color: var(--ft-text); }
.cd.show .cd-panel { transform: none; }
.cd-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 20px; border-bottom: 1px solid var(--ft-line); }
.cd-head h3 { margin: 0; color: var(--ft-navy); }
.cd-head .cd-x { border: 0; background: none; font-size: 30px; cursor: pointer; }
.cd-list { flex: 1; overflow-y: auto; padding: 10px 20px; }
.cd-item { display: grid; grid-template-columns: 70px 1fr auto; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid #f1f5f9; }
.cd-item img { width: 70px; height: 54px; object-fit: cover; border-radius: 8px; }
.cd-item small { display: block; color: var(--ft-muted); font-size: 12px; margin: 2px 0; }
.cd-item b { color: var(--ft-orange); }
.cd-item button { border: 0; background: none; font-size: 18px; cursor: pointer; }
.cd-foot { padding: 16px 20px; border-top: 1px solid var(--ft-line); }
.cd-tot { display: flex; justify-content: space-between; font-size: 18px; color: var(--ft-navy); }
.cd-empty { padding: 40px 24px; text-align: center; color: var(--ft-muted); }

/* Checkout */
.ft-modal.ck { max-width: 920px; }
.ck-grid { display: grid; grid-template-columns: 1fr 320px; gap: 28px; padding: 30px; }
.ck-form h2 { margin: 0 0 16px; color: var(--ft-navy); }
.ck-check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; margin-top: 6px; }
.ck-check input { margin-top: 3px; }
.ck-check input.err { outline: 2px solid #dc2626; }
.ck-side { background: #f8fafc; border-radius: 16px; padding: 18px; align-self: start; }
.ck-side h3 { margin: 0 0 10px; color: var(--ft-navy); }
.ck-row { border-bottom: 1px solid var(--ft-line); padding: 10px 0; font-size: 14px; }
.ck-row small { display: block; color: var(--ft-muted); }
.ck-row b { white-space: nowrap; }

/* Aviso */
.ft-toast { position: fixed; left: 50%; bottom: 30px; transform: translate(-50%, 20px); background: var(--ft-navy); color: #fff; padding: 12px 20px; border-radius: 12px; z-index: 100001; opacity: 0; transition: .3s; font-weight: 600; box-shadow: 0 10px 30px rgba(0, 0, 0, .3); }
.ft-toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Responsive */
@media (max-width: 900px) {
  .ft-overlay { padding: 0; }
  .ft-modal { border-radius: 0; min-height: 100%; }
  .ft-main { aspect-ratio: 4 / 3; }
  .ft-body { grid-template-columns: 1fr; padding: 20px 16px 30px; gap: 20px; }
  .ft-head h2 { font-size: 24px; }
  .ft-sec-body { padding-left: 18px; }
  .ft-book { position: static; }
  .ck-grid { grid-template-columns: 1fr; padding: 20px 16px; }
}

.ck-ok { background: #ecfdf5; border: 1px solid #a7f3d0; border-radius: 12px; padding: 14px; margin-top: 12px; }
.ck-ok h3 { margin: 0 0 6px; color: #047857; }
#ck-pay-area .kr-embedded { margin-top: 12px; }

/* Reseñas reales */
.ft-scores { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 14px; }
.ft-score { flex: 1 1 200px; display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; align-items: center; background: #fff; border-radius: 12px; padding: 12px 14px; text-decoration: none; color: var(--ft-text); border: 1px solid var(--ft-line); }
.ft-score b { grid-row: span 3; font-size: 34px; color: var(--ft-navy); }
.ft-score span, .ft-score small { font-size: 13px; color: var(--ft-muted); }
.ft-score small { color: #00aa6c; font-weight: 600; }
.ft-bub { display: inline-flex; gap: 3px; }
.ft-bub i { width: 13px; height: 13px; border-radius: 50%; border: 2px solid #00aa6c; display: inline-block; }
.ft-bub i.on { background: #00aa6c; }
.ft-gstars { color: #fbbc04 !important; letter-spacing: 1px; font-size: 15px !important; }
.ft-revlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.ft-rev { display: block; background: #fff; border-radius: 12px; padding: 12px 14px; text-decoration: none; color: var(--ft-text); border: 1px solid var(--ft-line); transition: .2s; }
.ft-rev:hover { border-color: #00aa6c; transform: translateY(-2px); }
.ft-rev-top { display: flex; gap: 10px; align-items: center; margin-bottom: 6px; }
.ft-rev-top small { display: block; color: var(--ft-muted); font-size: 12px; }
.ft-av { width: 34px; height: 34px; border-radius: 50%; background: var(--ft-navy); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; }
.ft-rev p { margin: 8px 0 6px; font-weight: 600; font-size: 15px; }
.ft-src { font-size: 12px; color: #00aa6c; }
