/* ==== Israel AI Trip Planner – v1.4.0 (fixed slider) ==== */
:root{--itp-surface:#fff;}
.israel-trip-planner-container.itp-modern{
  --itp-primary:#2463eb;            /* main accent */
  --itp-secondary:#22c55e;          /* day badge */
  --itp-muted:#6b7280;
  --itp-bg: linear-gradient(180deg, #f3f7ff 0%, #f9fbff 100%);
  font-family: system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif;
  background: var(--itp-bg);
  padding: 8px 12px 24px;
  border-radius: 16px;
}

/* ---------- Hero ---------- */
.itp-hero{ text-align:left; padding:24px 0; }
.itp-hero h2{
  margin:0 0 .35rem;
  font-size: clamp(28px, 4vw, 56px);
  line-height:1.1;
  color:#0f172a; letter-spacing:-.02em;
}
.itp-hero p{ margin:0; color:#475569; font-size:clamp(14px,1.6vw,18px); }

/* ---------- Grid & Cards ---------- */
.itp-grid{ display:grid; grid-template-columns: 2fr 1fr; gap:20px; }
@media (max-width: 900px){ .itp-grid{ grid-template-columns:1fr; } }

.itp-card{
  background:#fff; border-radius:16px; border:1px solid #eef2ff;
  box-shadow:0 10px 30px rgba(36,99,235,.06); padding:18px;
}
.itp-card h3{ margin:.25rem 0 1rem; color:#0f172a; font-size:20px; }

.itp-field{ margin-bottom:16px; }
.itp-field label{ display:block; font-weight:600; color:#111827; margin-bottom:6px; }
.itp-help{ margin:.25rem 0 .5rem; color:#6b7280; font-size:13px; }

/* ---------- Range + Number ---------- */
.itp-range{
  display:flex; gap:12px; align-items:center;
}
.itp-range input[type="number"]{
  width:90px; padding:8px 10px; border:1px solid #e5e7eb; border-radius:8px; background:#fff;
  font-weight:600; color:#111827;
}

/* Reset default UA styles so the track is visible everywhere */
.itp-range input[type="range"]{
  -webkit-appearance:none; appearance:none;
  width:100%; height:8px; flex:1;
  background:#e5e7eb!important;                /* visible full track */
  border-radius:999px; outline:none; cursor:pointer;
}

/* WebKit/Blink track + thumb */
.itp-range input[type="range"]::-webkit-slider-runnable-track{
  height:8px; background:#e5e7eb!important; border-radius:999px;
}
.itp-range input[type="range"]::-webkit-slider-thumb{
  -webkit-appearance:none; appearance:none;
  width:18px; height:18px; border-radius:50%;
  background:var(--itp-primary); border:2px solid #fff;
  box-shadow:0 2px 8px rgba(36,99,235,.35); margin-top:-5px; /* centers on track */
}

/* Firefox track + progress + thumb */
.itp-range input[type="range"]{ background:transparent; } /* FF needs transparent base */
.itp-range input[type="range"]::-moz-range-track{
  height:8px; background:#e5e7eb!important; border-radius:999px;
}
.itp-range input[type="range"]::-moz-range-progress{
  height:8px; background:rgba(36,99,235,.35); border-radius:999px;
}
.itp-range input[type="range"]::-moz-range-thumb{
  width:18px; height:18px; border-radius:50%;
  background:var(--itp-primary); border:2px solid #fff;
  box-shadow:0 2px 8px rgba(36,99,235,.35);
}

/* Focus/hover states */
.itp-range input[type="range"]:focus::-webkit-slider-thumb{ box-shadow:0 0 0 6px rgba(36,99,235,.15); }
.itp-range input[type="range"]:focus::-moz-range-thumb{ box-shadow:0 0 0 6px rgba(36,99,235,.15); }

/* ---------- Chips ---------- */
.itp-chips, .itp-budget{ display:flex; flex-wrap:wrap; gap:10px; }
.itp-chip{
  border:1px solid #dce7ff; background:#eef5ff; color:#0b3ea1;
  padding:8px 14px; border-radius:999px; cursor:pointer; font-weight:600; font-size:14px;
  transition:transform .15s;
}
.itp-chip:hover{ transform:translateY(-1px); }
.itp-chip.selected{ background:var(--itp-primary); color:#fff; border-color:transparent; box-shadow:0 5px 18px rgba(36,99,235,.25); }
.itp-chip-light{ background:#fff; color:#111827; border-color:#e5e7eb; }
.itp-chip-light.selected{ background:#111827; color:#fff; border-color:#111827; }

#interestsText{
  width:100%; margin-top:8px; padding:10px 12px; border:1px solid #e5e7eb; border-radius:12px; background:#fff;
}

/* ---------- Buttons ---------- */
.itp-actions-row{ display:flex; gap:10px; margin-top:8px; }
.itp-btn{
  background:var(--itp-primary); color:#fff; border:none; padding:12px 16px; border-radius:12px;
  cursor:pointer; font-weight:700; box-shadow:0 8px 22px rgba(36,99,235,.22);
}
.itp-btn.ghost{ background:#fff; color:#111827; border:1px solid #e5e7eb; box-shadow:none; }

/* ---------- Summary card ---------- */
.itp-summary .itp-summary-box{
  display:grid; grid-template-columns: 1fr 1fr; gap:10px; margin-bottom:10px;
}
.itp-summary-item{ background:#f8fafc; border:1px solid #e5e7eb; border-radius:12px; padding:10px; }
.itp-summary-label{ color:#6b7280; font-size:12px; }
.itp-summary-value{ font-weight:700; color:#0f172a; margin-top:2px; }
.itp-pills{ display:flex; flex-wrap:wrap; gap:8px; }
.itp-pill{ background:#eaf8ef; border:1px solid #c7f0d0; color:#046b2a; border-radius:999px; padding:6px 10px; font-weight:600; font-size:13px; }
.itp-tip-text{ color:#64748b; font-size:12px; margin-top:10px; }

/* ---------- Results + Export ---------- */
.itp-toolbar{ display:flex; gap:10px; margin:16px 0; }
.itp-btn-outline{ border:1px solid var(--itp-primary); background:#fff; color:var(--itp-primary); padding:10px 14px; border-radius:10px; cursor:pointer; font-weight:600; }
#itinerary-result{ margin-top:18px; }
#itinerary-result .loading{ padding:10px 12px; background:#fafafa; border:1px dashed #ddd; border-radius:8px; }
#itinerary-result .itp-error{ padding:10px 12px; background:#fff1f1; color:#b60000; border:1px solid #ffc7c7; border-radius:8px; }

/* ---------- Itinerary rendering ---------- */
.itp-title{ margin:8px 0; }
.itp-desc{ color:#444; }
.itp-cost{ background:#f6fff8; border:1px solid #e1ffe8; padding:8px 12px; border-radius:8px; display:inline-block; }
.itp-days{ display:grid; gap:14px; }
.itp-day-card{ border:1px solid #eee; border-radius:14px; padding:14px; background:#fff; box-shadow:0 2px 8px rgba(0,0,0,.03); }
.itp-day-header h4{ margin:.25rem 0 .35rem; }
.itp-day-badge{ display:inline-block; background:var(--itp-secondary); color:#fff; font-size:.85rem; padding:4px 10px; border-radius:999px; }
.itp-day-cost{ margin-top:6px; background:#f9fbff; border:1px solid #e7f0ff; color:#0a3d72; padding:6px 10px; border-radius:8px; display:inline-block; }
.itp-section{ margin-top:8px; }
.itp-section h5{ margin:.25rem 0 .35rem; }
.itp-list{ list-style:none; margin:0; padding:0; display:grid; gap:10px; }
.itp-list li{ border:1px solid #f0f0f0; border-radius:10px; padding:10px 12px; background:#fcfcfc; }
.itp-meta{ color:#666; font-size:.9rem; margin-top:2px; }
.itp-text{ margin-top:4px; }
.itp-tags{ margin-top:6px; display:flex; flex-wrap:wrap; gap:6px; }
.itp-tags span{ background:#eef6ff; border:1px solid #d8ebff; color:#0a3d72; border-radius:999px; padding:2px 8px; font-size:.85rem; }
.itp-tip{ margin-top:6px; font-style:italic; color:#5a5a5a; }
.itp-actions{ margin-top:6px; display:flex; gap:8px; align-items:center; }
.itp-map{ margin-top:8px; }

/* ---------- Print view ---------- */
@media print {
  .israel-trip-planner-container .itp-grid,
  .israel-trip-planner-container .itp-toolbar,
  .israel-trip-planner-container .itp-hero,
  .israel-trip-planner-container .itp-form { display:none !important; }
  .itp-day-card{ break-inside:avoid; page-break-inside:avoid; }
}

