/* Helpline Travels — "Find Your Perfect Package" widget. Every rule is scoped to .hps / .hps-host. */
.hps {
  --hps-navy: #0b1f4d;
  --hps-blue: #0033a0;
  --hps-orange: #ff6600;
  --hps-orange-2: #ff8a1f;
  --hps-ink: #1f2a44;
  --hps-muted: #5b6785;
  --hps-line: #dfe5f0;
  --hps-soft: #eef3fb;
  --hps-red: #e11d2e;
  --hps-green: #16a34a;
  font-family: "Segoe UI", Arial, sans-serif;
  color: var(--hps-ink);
  text-align: left;
  line-height: 1.35;
}
.hps *, .hps *::before, .hps *::after { box-sizing: border-box; }
.hps .hps-i { width: 20px; height: 20px; flex: none; display: block; }
.hps .hps-sr {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Host containers: the existing hero box and mobile card keep their position and spacing;
   the widget's own card replaces their decoration. */
.hero-bg.hps-host { background: transparent; padding: 0; box-shadow: none; animation: none; border-radius: 26px; }
.card-box.hps-host { background: transparent; padding: 0; box-shadow: none; }

/* Card */
.hps .hps-card {
  display: grid;
  grid-template-columns: minmax(0, 1.32fr) minmax(0, 1fr);
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  border-radius: 26px;
  box-shadow: 0 24px 60px rgba(11, 31, 77, .16), 0 2px 6px rgba(11, 31, 77, .06);
  border: 1px solid rgba(255, 255, 255, .8);
  overflow: hidden;
}
.hps.hps--compact .hps-card { grid-template-columns: 1fr; }

/* Left: search */
.hps .hps-search { position: relative; padding: 38px 36px 92px 40px; min-width: 0; }
.hps .hps-head { position: relative; padding-left: 22px; margin-bottom: 30px; }
.hps .hps-head::before {
  content: ""; position: absolute; left: 0; top: 4px; bottom: 4px; width: 6px; border-radius: 6px;
  background: linear-gradient(180deg, var(--hps-orange), var(--hps-orange-2));
}
.hps .hps-title {
  margin: 0; font-size: clamp(26px, 2.9vw, 40px); line-height: 1.12; font-weight: 800;
  letter-spacing: -.02em; color: var(--hps-navy); padding-right: 64px;
}
.hps .hps-sub { margin: 8px 0 0; font-size: clamp(15px, 1.4vw, 19px); font-style: italic; color: var(--hps-muted); }
.hps .hps-plane { position: absolute; right: 0; top: 18px; width: 150px; height: 78px; color: var(--hps-navy); opacity: .85; pointer-events: none; }

/* Tabs */
.hps .hps-tabs {
  display: inline-flex; gap: 6px; padding: 6px; margin-bottom: 26px; max-width: 100%;
  background: var(--hps-soft); border: 1px solid var(--hps-line); border-radius: 999px;
}
.hps .hps-tabs .hps-tab {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  width: auto; height: auto; min-height: 48px; padding: 10px 26px; margin: 0;
  font: 700 16px/1.2 "Segoe UI", Arial, sans-serif; color: var(--hps-navy);
  background: transparent; border: 2px solid transparent; border-radius: 999px; cursor: pointer;
  transition: background .2s, color .2s, box-shadow .2s, border-color .2s; white-space: nowrap;
}
.hps .hps-tabs .hps-tab .hps-i { width: 22px; height: 22px; }
.hps .hps-tabs .hps-tab:hover { background: #fff; }
.hps .hps-tabs .hps-tab.is-active {
  color: #fff; background: linear-gradient(135deg, #12357f, var(--hps-navy));
  border-color: var(--hps-orange); box-shadow: 0 8px 18px rgba(11, 31, 77, .25), 0 0 0 3px rgba(255, 102, 0, .14);
}
.hps .hps-tabs .hps-tab:focus-visible { outline: 3px solid rgba(255, 102, 0, .55); outline-offset: 2px; }

/* Fields */
.hps .hps-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 22px; }
.hps .hps-field {
  position: relative; display: flex; align-items: center; min-width: 0; height: 56px;
  background: #fff; border: 1.5px solid var(--hps-line); border-radius: 14px;
  box-shadow: 0 2px 6px rgba(11, 31, 77, .04); transition: border-color .2s, box-shadow .2s;
}
.hps .hps-field:hover { border-color: #c4cfe3; }
.hps .hps-field:focus-within { border-color: var(--hps-blue); box-shadow: 0 0 0 4px rgba(0, 51, 160, .12); }
.hps .hps-field > .hps-i { position: absolute; left: 16px; color: var(--hps-navy); pointer-events: none; }
.hps .hps-field .hps-input {
  width: 100%; height: 100%; margin: 0; padding: 0 44px 0 50px; border: 0; border-radius: 14px;
  background: transparent; box-shadow: none; outline: none;
  font: 500 16px/1.2 "Segoe UI", Arial, sans-serif; color: var(--hps-ink);
  -webkit-appearance: none; appearance: none; min-width: 0; text-overflow: ellipsis;
}
.hps .hps-field input.hps-input { padding-right: 16px; }
.hps .hps-field .hps-input::placeholder { color: #4a5675; opacity: 1; }
.hps .hps-field select.hps-input { cursor: pointer; }
.hps .hps-field select.hps-input option:disabled { color: #a3acc0; }
.hps .hps-field input[type="search"]::-webkit-search-cancel-button { cursor: pointer; }
.hps .hps-chev { position: absolute; right: 14px; color: var(--hps-navy); pointer-events: none; }

/* CTA */
.hps .hps-cta {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  width: min(100%, 460px); height: 58px; margin: 30px auto 0; padding: 0 28px;
  font: 800 20px/1 "Segoe UI", Arial, sans-serif; color: #fff; letter-spacing: .01em;
  background: linear-gradient(90deg, var(--hps-orange-2), var(--hps-orange) 55%, #f25700);
  border: 0; border-radius: 999px; cursor: pointer;
  box-shadow: 0 12px 24px rgba(255, 102, 0, .32); transition: transform .15s, box-shadow .2s, filter .2s;
}
.hps .hps-cta .hps-i { width: 24px; height: 24px; stroke-width: 2.4; }
.hps .hps-cta:hover { transform: translateY(-1px); box-shadow: 0 16px 30px rgba(255, 102, 0, .4); filter: saturate(1.08); }
.hps .hps-cta:active { transform: translateY(0); }
.hps .hps-cta:focus-visible { outline: 3px solid rgba(0, 51, 160, .5); outline-offset: 3px; }
.hps .hps-hint { min-height: 20px; margin: 10px 0 0; text-align: center; font-size: 14px; color: var(--hps-muted); }

.hps .hps-hills {
  position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 84px; color: #dbe9f7; pointer-events: none;
}

/* Right: live departures */
.hps .hps-live {
  position: relative; padding: 38px 30px 30px; min-width: 0;
  background: linear-gradient(180deg, #f7faff, #f1f6fd);
  border-left: 1px solid var(--hps-line);
}
.hps .hps-live-head { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 22px; }
.hps .hps-live-ico { color: var(--hps-orange); }
.hps .hps-live-ico .hps-i { width: 38px; height: 38px; stroke-width: 2; }
.hps .hps-live-title { margin: 0; font-size: 26px; line-height: 1.15; font-weight: 800; color: var(--hps-navy); letter-spacing: -.01em; }
.hps .hps-live-sub { margin: 4px 0 0; font-size: 16px; font-style: italic; color: var(--hps-muted); }
.hps .hps-live-list { list-style: none; margin: 0; padding: 0 6px 0 0; display: grid; gap: 14px; max-height: 480px; overflow-y: auto; scrollbar-gutter: stable; }
.hps .hps-dep {
  display: flex; gap: 14px; padding: 10px; text-decoration: none; color: inherit;
  background: #fff; border: 1px solid var(--hps-line); border-radius: 16px;
  box-shadow: 0 4px 14px rgba(11, 31, 77, .06); transition: transform .15s, box-shadow .2s, border-color .2s;
}
.hps .hps-live-list > li { animation: hpsLiveCardIn .55s cubic-bezier(.2,.8,.2,1) both; }
.hps .hps-live-list > li:nth-child(2) { animation-delay: .1s; }
.hps .hps-live-list > li:nth-child(3) { animation-delay: .2s; }
@keyframes hpsLiveCardIn {
  from { opacity: 0; transform: translateX(24px) scale(.97); }
  to { opacity: 1; transform: translateX(0) scale(1); }
}
.hps .hps-dep-img img { transition: transform .5s ease; }
.hps .hps-dep:hover .hps-dep-img img { transform: scale(1.07); }
@media (prefers-reduced-motion: reduce) {
  .hps .hps-live-list > li { animation: none; }
  .hps .hps-dep-img img { transition: none; }
}
.hps .hps-dep:hover { transform: translateY(-2px); border-color: #c8d4ea; box-shadow: 0 10px 24px rgba(11, 31, 77, .12); }
.hps .hps-dep:focus-visible { outline: 3px solid rgba(255, 102, 0, .55); outline-offset: 2px; }
.hps .hps-dep.is-soldout { opacity: .82; }
.hps .hps-dep-img {
  flex: none; width: 136px; height: 104px; border-radius: 12px; overflow: hidden;
  background: linear-gradient(135deg, #cfe3f7, #e9f2fb);
}
.hps .hps-dep-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hps .hps-dep-body { display: flex; flex-direction: column; justify-content: center; gap: 7px; min-width: 0; flex: 1; }
.hps .hps-dep-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.hps .hps-dep-title {
  font-size: 18px; line-height: 1.2; font-weight: 800; color: var(--hps-navy);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.hps .hps-badge {
  flex: none; display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 700; white-space: nowrap;
}
.hps .hps-badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.hps .hps-badge--ok { color: #fff; background: var(--hps-green); }
.hps .hps-badge--ok::before { background: #fff; }
.hps .hps-badge--pending { color: #8a4b00; background: #fff1d6; }
.hps .hps-badge--soldout { color: #fff; background: #6b7280; }
.hps .hps-badge--soldout::before { background: #fff; }
.hps .hps-dep-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 6px; font-size: 13.5px; color: var(--hps-muted); }
.hps .hps-dep-meta .hps-i { width: 15px; height: 15px; }
.hps .hps-dep-meta b { color: var(--hps-ink); }
.hps .hps-interest { display: inline-flex; align-items: center; gap: 7px; color: #7a4a08; font-size: 12px; font-weight: 700; }
.hps .hps-interest-dot { width: 8px; height: 8px; border-radius: 50%; background: #f59e0b; box-shadow: 0 0 0 0 rgba(245,158,11,.45); animation: hpsInterestPulse 1.8s ease-out infinite; }
@keyframes hpsInterestPulse { 70% { box-shadow: 0 0 0 7px rgba(245,158,11,0); } 100% { box-shadow: 0 0 0 0 rgba(245,158,11,0); } }
.hps .hps-dot { opacity: .6; }
.hps .hps-from { white-space: nowrap; }
.hps .hps-dep-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; }
.hps .hps-slots {
  display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px; border-radius: 999px;
  font-size: 15px; font-weight: 800; color: var(--hps-red); background: #fde8ea;
}
.hps .hps-slots .hps-i { width: 18px; height: 18px; color: var(--hps-navy); }
.hps .hps-slots--none { color: #4b5563; background: #eceff3; }
.hps .hps-urgency {
  display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 800; color: #b23c00; background: #ffe7c7;
}
.hps .hps-urgency::before { content: "\1F525"; margin-right: 4px; font-size: 11px; }
.hps .hps-live-all {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; font-size: 15px; font-weight: 700;
  color: var(--hps-blue); text-decoration: none;
}
.hps .hps-live-all .hps-i { width: 18px; height: 18px; }
.hps .hps-live-all:hover { color: var(--hps-orange); }
.hps .hps-empty {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px;
  padding: 34px 18px; background: #fff; border: 1.5px dashed #c8d4ea; border-radius: 18px;
}
.hps .hps-empty-ico { display: grid; place-items: center; width: 58px; height: 58px; border-radius: 50%; background: var(--hps-soft); color: var(--hps-blue); }
.hps .hps-empty-ico .hps-i { width: 28px; height: 28px; }
.hps .hps-empty-title { margin: 8px 0 0; font-size: 17px; font-weight: 800; color: var(--hps-navy); }
.hps .hps-empty-text { margin: 0; font-size: 14px; color: var(--hps-muted); }

/* Tablet */
@media (max-width: 1100px) {
  .hps .hps-search { padding: 32px 26px 86px 30px; }
  .hps .hps-live { padding: 32px 22px 26px; }
  .hps .hps-tabs .hps-tab { padding: 10px 18px; font-size: 15px; }
  .hps .hps-dep-img { width: 104px; height: 92px; }
  .hps .hps-dep-title { font-size: 16px; }
  .hps .hps-plane { width: 110px; height: 58px; }
  .hps .hps-title { padding-right: 70px; }
}
@media (max-width: 900px) {
  .hps .hps-card { grid-template-columns: 1fr; }
  .hps .hps-live { border-left: 0; border-top: 1px solid var(--hps-line); }
  .hps .hps-live-list { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
}

/* Mobile */
@media (max-width: 600px) {
  .hps .hps-card { border-radius: 20px; }
  .hps .hps-search { padding: 24px 16px 44px; }
  .hps .hps-hint:empty { min-height: 0; margin: 0; }
  .hps .hps-head { padding-left: 16px; margin-bottom: 20px; }
  .hps .hps-head::before { width: 5px; }
  .hps .hps-title { font-size: 26px; padding-right: 0; }
  .hps .hps-sub { font-size: 15px; }
  .hps .hps-plane { display: none; }
  .hps .hps-tabs { display: flex; width: 100%; margin-bottom: 18px; }
  .hps .hps-tabs .hps-tab { flex: 1 1 0; min-width: 0; padding: 10px 8px; gap: 7px; font-size: 14px; white-space: normal; text-align: center; }
  .hps .hps-tabs .hps-tab .hps-i { width: 19px; height: 19px; }
  .hps .hps-grid { grid-template-columns: 1fr; gap: 12px; }
  .hps .hps-field { height: 52px; }
  .hps .hps-field .hps-input { font-size: 16px; }
  .hps .hps-cta { width: 100%; height: 54px; margin-top: 20px; font-size: 18px; }
  .hps .hps-hills { height: 40px; }
  .hps .hps-live { padding: 24px 14px 20px; }
  .hps .hps-live-ico .hps-i { width: 32px; height: 32px; }
  .hps .hps-live-title { font-size: 22px; }
  .hps .hps-live-sub { font-size: 14px; }
  .hps .hps-live-list { grid-template-columns: 1fr; gap: 12px; }
  .hps .hps-dep { gap: 12px; padding: 8px; }
  .hps .hps-dep-img { width: 96px; height: 92px; }
  .hps .hps-dep-top { flex-direction: column; gap: 5px; }
  .hps .hps-dep-title { font-size: 16px; }
  .hps .hps-slots { font-size: 14px; padding: 4px 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .hps .hps-cta, .hps .hps-dep, .hps .hps-tabs .hps-tab, .hps .hps-field { transition: none; }
  .hps .hps-interest-dot { animation: none; }
}

/* ---------------- Search results page (package-search.php) ---------------- */
.hps-results-page { background: #f4f7fc; padding-bottom: 56px; }
.hps-results-hero {
  padding: 34px 16px;
  background: linear-gradient(180deg, #cfeaf7 0%, #e3f3fb 60%, #f4f7fc 100%);
}
.hps-results-wrap { max-width: 1200px; margin: 0 auto; }
.hps-results-page .hps--compact .hps-search { padding-bottom: 58px; }
.hps-results-page .hps--compact .hps-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.hps.hps-results { padding: 28px 16px 0; }
.hps .hps-results-head { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 14px; margin-bottom: 22px; }
.hps .hps-results-title { margin: 0; font-size: 28px; font-weight: 800; color: var(--hps-navy); }
.hps .hps-results-count { margin: 4px 0 10px; color: var(--hps-muted); font-size: 15px; }
.hps .hps-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; }
.hps .hps-chips li { padding: 5px 12px; border-radius: 999px; background: #fff; border: 1px solid var(--hps-line); font-size: 13.5px; font-weight: 600; color: var(--hps-navy); }
.hps .hps-switch { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; color: var(--hps-blue); text-decoration: none; }
.hps .hps-switch .hps-i { width: 18px; height: 18px; }
.hps .hps-switch:hover { color: var(--hps-orange); }
.hps .hps-rgrid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 22px; }
.hps .hps-rcard {
  display: flex; flex-direction: column; background: #fff; border: 1px solid var(--hps-line); border-radius: 18px;
  overflow: hidden; box-shadow: 0 6px 18px rgba(11, 31, 77, .07); transition: transform .15s, box-shadow .2s;
}
.hps .hps-rcard:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(11, 31, 77, .12); }
.hps .hps-rcard.is-muted { opacity: .8; }
.hps .hps-rcard-img { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: linear-gradient(135deg, #cfe3f7, #e9f2fb); }
.hps .hps-rcard-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.hps .hps-rcard-img .hps-badge { position: absolute; top: 12px; left: 12px; box-shadow: 0 2px 8px rgba(0, 0, 0, .15); }
.hps .hps-rcard-img .hps-badge--pending { background: #fff4dc; }
.hps .hps-rcard-body { display: flex; flex-direction: column; gap: 8px; padding: 16px 18px 18px; flex: 1; }
.hps .hps-rcard-title { margin: 0; font-size: 18px; line-height: 1.25; font-weight: 800; }
.hps .hps-rcard-title a { color: var(--hps-navy); text-decoration: none; }
.hps .hps-rcard-title a:hover { color: var(--hps-orange); }
.hps .hps-rcard-meta { display: flex; align-items: center; gap: 7px; margin: 0; font-size: 14px; color: var(--hps-muted); }
.hps .hps-rcard-meta .hps-i { width: 16px; height: 16px; color: var(--hps-navy); }
.hps .hps-rcard-note { margin: 0; font-size: 12.5px; color: #8a4b00; }
.hps .hps-rcard-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 10px; border-top: 1px solid #eef1f6; }
.hps .hps-price { font-size: 20px; font-weight: 800; color: var(--hps-orange); }
.hps .hps-price small { font-size: 12.5px; font-weight: 600; color: var(--hps-muted); }
.hps .hps-rbtn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 16px;
  border-radius: 999px; font-size: 14.5px; font-weight: 800; text-decoration: none; text-align: center;
  color: #fff; background: linear-gradient(135deg, #12357f, var(--hps-navy));
}
.hps .hps-rbtn:hover { color: #fff; background: var(--hps-orange); }
.hps .hps-rbtn.is-off { color: #4b5563; background: #eceff3; font-size: 13px; }
.hps .hps-empty--wide { padding: 48px 20px; }
.hps .hps-empty-link { margin-top: 8px; font-weight: 700; color: var(--hps-blue); }
.hps .hps-pager { display: flex; justify-content: center; align-items: center; gap: 18px; margin-top: 30px; font-weight: 600; color: var(--hps-muted); }
.hps .hps-pager a { color: var(--hps-blue); text-decoration: none; font-weight: 800; }
@media (max-width: 1100px) {
  .hps-results-page .hps--compact .hps-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .hps-results-hero { padding: 18px 12px; }
  .hps-results-page .hps--compact .hps-grid { grid-template-columns: 1fr; }
  .hps.hps-results { padding: 20px 12px 0; }
  .hps .hps-results-title { font-size: 23px; }
  .hps .hps-rgrid { grid-template-columns: 1fr; gap: 16px; }
}
