/* ============================================================================
   Hotel result card - new design, ported from:
   F:\CyprusParadise-NewDesigns\prototypes\search-results\ (index.html/styles.css)

   Scope: ONLY the hotel card markup used in _HotelCard.cshtml (the loop item
   in Views/Partials/SearchResults). Nothing else on this - or any other -
   page is touched.

   Everything here is namespaced under .cph-card ("Cyprus Paradise Hotel
   card") specifically so it cannot collide with the site's existing global
   CSS: every selector is either ".cph-*" (a class name not used anywhere
   else in the codebase) or a descendant of ".cph-card", and all of the
   prototype's colour/font tokens are re-declared as --cph-* custom
   properties scoped to .cph-card itself (not :root), so they can't leak
   into or be affected by anything else on the page. Lato and Montserrat
   (the prototype's fonts) are already loaded site-wide by
   Views/Partials/_HeadAssets.cshtml, so no extra font-loading is needed
   here.
   ============================================================================ */

.cph-card {
  /* Design tokens (see CyprusParadise-NewDesigns/assets/tokens/tokens.css) -
     scoped to this component only, deliberately not on :root. */
  --cph-primary: #02aaa9;
  --cph-primary-dark: #218887;
  --cph-primary-deep: #104443;
  --cph-primary-mist: #def6f5;
  --cph-gold: #febb02;
  --cph-coral: #f9706a;
  --cph-green: #23ae24;
  --cph-green-text: #008009;
  --cph-red-soft: #ffe7e8;
  --cph-urgency-text: #c23b4a;
  --cph-text: #3c4e5a;
  --cph-text-muted: #707070;
  --cph-ink: #141515;
  --cph-border: #d8e0e0;
  --cph-font: "Lato", "Segoe UI", sans-serif;
  --cph-font-display: "Montserrat", "Lato", sans-serif;

  box-sizing: border-box;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr) 216px;
  background: #fff;
  border: 1px solid var(--cph-border);
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(16, 68, 67, 0.08);
  overflow: hidden;
  font-family: var(--cph-font);
  color: var(--cph-text);
  line-height: 1.45;
  /* .hotel-card-wrapper (the v-for item wrapper in _SearchResultsContainer.cshtml) carries no
     spacing of its own - previously the old card's own "pb-4" Bootstrap class handled the gap
     between stacked cards, so replicate it here instead now that this card has no Bootstrap
     column wrapper. */
  margin-bottom: 24px;
}

.cph-card *,
.cph-card *::before,
.cph-card *::after {
  box-sizing: border-box;
}

.cph-card:hover {
  box-shadow: 0 10px 24px rgba(16, 68, 67, 0.14);
}

@media (max-width: 1140px) {
  .cph-card {
    grid-template-columns: 200px minmax(0, 1fr);
  }

  .cph-card__body {
    border-right: 0;
  }

  .cph-card__aside {
    grid-column: 1 / -1;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px 20px;
    border-left: 0;
    border-top: 1px solid #cfeceb;
  }

  .cph-price-block {
    margin-top: 0;
  }

  .cph-flash {
    flex: 0 0 100%;
    max-width: 100%;
    height: 28px;
  }

  .cph-pay-plan {
    flex: 1 1 220px;
  }

  .cph-card__aside .cph-btn {
    width: auto;
    min-width: 180px;
    margin-top: 0;
  }
}

@media (max-width: 860px) {
  .cph-card {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .cph-card__media,
  .cph-card__media img {
    min-height: 168px;
    height: 168px;
  }

  .cph-card__body {
    padding: 14px;
    border-right: 0;
  }

  .cph-card__top {
    flex-direction: column;
  }

  .cph-ta {
    align-items: flex-start;
    text-align: left;
  }

  .cph-card__name {
    font-size: 18px;
  }

  .cph-flight {
    grid-template-columns: 1fr;
  }

  .cph-flight__col--end {
    text-align: left;
  }

  .cph-flight__path {
    justify-content: flex-start;
  }

  .cph-card__aside {
    flex-direction: column;
    align-items: stretch;
  }

  .cph-price-block {
    margin-top: 0;
  }

  .cph-flash {
    align-self: flex-start;
    flex: 0 0 auto;
    width: auto;
    max-width: none;
    height: 24px;
    border-radius: 999px;
  }

  .cph-flash__mark {
    width: 24px;
  }

  .cph-flash__mark svg {
    width: 11px;
    height: 11px;
  }

  .cph-flash__time {
    flex: 0 0 auto;
    padding: 0 10px 0 6px;
    font-size: 10px;
  }
}

/* ---- Media (left column) ---- */

.cph-card__media {
  position: relative;
  overflow: hidden;
  background: #e7f2f2;
}

.cph-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 248px;
  max-width: 100%;
  object-fit: cover;
}

.cph-card__flags {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.cph-flag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #fff;
  background: var(--cph-primary-deep);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.02em;
  padding: 5px 8px;
  border-radius: 4px;
  line-height: 1;
}

.cph-flag svg {
  width: 12px;
  height: 12px;
}

/* label.icon is now an Our.Iconic icon rendered server-side to markup (an inline <svg> for most
   packages, an <i class="..."> icon-font tag for a few) and injected via v-html - style the
   wrapper as a fixed box and let whichever tag RenderIcon() produced fill it, rather than
   assuming one specific child element. */
.cph-flag__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.cph-flag__icon svg,
.cph-flag__icon img {
  display: block;
  width: 100%;
  height: 100%;
}

.cph-flag__icon i {
  font-size: 14px;
  line-height: 1;
}

.cph-flag--deal {
  background: var(--cph-green-text);
}

.cph-flag--tz {
  background: #c8102e;
  letter-spacing: 0.06em;
  font-size: 10px;
}

.cph-wish {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.94);
  color: var(--cph-primary-deep);
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(16, 68, 67, 0.12);
  display: grid;
  place-items: center;
  transition: transform 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.cph-wish svg {
  width: 20px;
  height: 20px;
}

.cph-wish:hover {
  color: var(--cph-urgency-text);
  transform: scale(1.06);
}

.cph-wish.is-on {
  color: var(--cph-urgency-text);
  background: #fff;
}

.cph-wish.is-on svg path {
  fill: var(--cph-urgency-text);
  stroke: var(--cph-urgency-text);
}

.cph-wish.is-pop {
  animation: cph-wish-pop 0.4s ease;
}

/* .cph-wish-burst / .cph-wish-tip are appended to <body> by hotelSearch.js's burstHearts()/
   showWishTip() (ported from the prototype's app.js), not descendants of .cph-card - so unlike
   everything else in this file they can't reach the --cph-* tokens above and use plain hex
   instead (--cph-urgency-text #c23b4a, --cph-primary-deep #104443, --cph-primary #02aaa9,
   --cph-green #23ae24). */
.cph-wish-burst {
  position: fixed;
  z-index: 80;
  width: 28px;
  height: 28px;
  margin: -14px 0 0 -14px;
  pointer-events: none;
  color: #c23b4a;
  filter: drop-shadow(0 2px 4px rgba(194, 59, 74, 0.35));
  animation: cph-wish-float 0.95s ease-out forwards;
}

.cph-wish-burst svg {
  display: block;
  width: 100%;
  height: 100%;
  transform: scale(var(--s, 1));
}

@keyframes cph-wish-pop {
  0% { transform: scale(1); }
  40% { transform: scale(1.28); }
  100% { transform: scale(1); }
}

@keyframes cph-wish-float {
  0% {
    opacity: 1;
    transform: translate(0, 0) scale(0.45);
  }
  55% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate(var(--dx), var(--dy)) scale(var(--s, 1));
  }
}

.cph-wish-tip {
  position: fixed;
  z-index: 85;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 8px;
  background: #fff;
  color: #104443;
  font-family: "Lato", "Segoe UI", sans-serif;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 8px 22px rgba(60, 78, 90, 0.18);
  transform: translate(-50%, 0);
  white-space: nowrap;
}

.cph-wish-tip::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 50%;
  width: 10px;
  height: 10px;
  background: #fff;
  transform: translateX(-50%) rotate(45deg);
  box-shadow: -2px -2px 4px rgba(60, 78, 90, 0.06);
}

.cph-wish-tip a {
  color: #02aaa9;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cph-wish-tip__ok {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #23ae24 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3E%3Cpath stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round' d='M4 8.3 6.6 10.8 12 5'/%3E%3C/svg%3E") center / 12px no-repeat;
}

.cph-photos {
  position: absolute;
  left: 8px;
  bottom: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(20, 21, 21, 0.72);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 999px;
  padding: 4px 8px;
}

.cph-photos svg {
  width: 14px;
  height: 14px;
}

/* ---- Body (middle column) ---- */

.cph-card__body {
  padding: 14px 16px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-right: 1px solid var(--cph-border);
}

.cph-card__top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.cph-card__name {
  margin: 0;
  font-family: var(--cph-font-display);
  font-size: 18px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.cph-card__name a {
  color: var(--cph-primary);
  text-decoration: none;
}

.cph-card__name a:hover {
  color: var(--cph-primary-dark);
}

.cph-ta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0;
  flex-shrink: 0;
  text-align: right;
}

.cph-ta__brand {
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  color: #00aa6c;
}

.cph-ta__owl {
  width: 18px;
  height: 18px;
}

.cph-ta__row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
}

/* Real Tripadvisor rating badge, same CDN image/URL convention as getTripAdvisorImage()
   already used elsewhere in this project (_HotelCardHeader.cshtml) - not a custom-drawn dot
   row, so whatever Tripadvisor renders for this score is exactly what shows here. */
.cph-ta__rating {
  display: block;
  width: 110px;
  height: 20px;
}

.cph-ta__meta {
  font-size: 11px;
  color: var(--cph-text-muted);
  white-space: nowrap;
}

.cph-stars {
  color: var(--cph-gold);
  letter-spacing: 1px;
  font-size: 13px;
}

.cph-place {
  margin: 0;
  font-size: 13px;
  color: var(--cph-text-muted);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.cph-place a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 700;
  color: var(--cph-primary);
  text-decoration: none;
}

.cph-place a:hover {
  text-decoration: underline;
}

.cph-place svg {
  width: 13px;
  height: 13px;
}

.cph-place__dot {
  color: var(--cph-border);
}

.cph-room {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--cph-ink);
}

.cph-chip-board {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--cph-primary-mist);
  color: var(--cph-primary-deep);
  border-radius: 999px;
  padding: 3px 9px;
  font-size: 12px;
  font-weight: 700;
}

.cph-chip-board svg {
  width: 13px;
  height: 13px;
}

.cph-perks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 3px;
}

.cph-perk {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--cph-green-text);
}

.cph-perk::before {
  content: "";
  flex-shrink: 0;
  width: 14px;
  height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3E%3Cpath stroke='%23008009' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round' d='M3.2 8.4 6.3 11.4 12.8 4.6'/%3E%3C/svg%3E") center / 14px no-repeat;
}

.cph-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.cph-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 999px;
  padding: 4px 9px;
  line-height: 1.2;
  background: #fff;
  color: var(--cph-text);
  border: 1px solid var(--cph-border);
}

.cph-pill svg {
  width: 12px;
  height: 12px;
}

/* Same RenderIcon()-produced-markup handling as .cph-flag__icon above. */
.cph-pill__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 12px;
  height: 12px;
  flex-shrink: 0;
}

.cph-pill__icon svg,
.cph-pill__icon img {
  display: block;
  width: 100%;
  height: 100%;
}

.cph-pill__icon i {
  font-size: 12px;
  line-height: 1;
}

.cph-pill--teal {
  background: var(--cph-primary-mist);
  color: var(--cph-primary-deep);
  border: 1px solid #bfe8e6;
}

.cph-pill--line {
  background: #fff;
  color: var(--cph-primary-deep);
  border: 1px solid var(--cph-primary);
}

.cph-pill--grey {
  background: #fff;
  color: var(--cph-text-muted);
  border: 1px solid var(--cph-border);
}

.cph-pill--hot {
  background: var(--cph-red-soft);
  color: var(--cph-urgency-text);
  border: 1px solid #f7c4c2;
}

.cph-flight {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--cph-border);
  border-radius: 10px;
  background: #f7fafa;
}

.cph-flight__label {
  display: block;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cph-text-muted);
}

.cph-flight__col {
  min-width: 0;
  font-size: 12px;
  color: var(--cph-text-muted);
}

.cph-flight__col strong {
  display: block;
  margin: 1px 0;
  font-size: 13px;
  color: var(--cph-ink);
}

.cph-flight__col--end {
  text-align: right;
}

.cph-flight__path {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--cph-primary);
}

.cph-flight__plane {
  display: grid;
  place-items: center;
}

.cph-flight__plane svg {
  width: 18px;
  height: 18px;
}

.cph-flight__bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 18px;
}

.cph-flight__bars i {
  display: block;
  width: 3px;
  border-radius: 2px;
  background: var(--cph-primary);
}

.cph-flight__bars i:nth-child(1) {
  height: 6px;
}
.cph-flight__bars i:nth-child(2) {
  height: 10px;
}
.cph-flight__bars i:nth-child(3) {
  height: 14px;
}
.cph-flight__bars i:nth-child(4) {
  height: 18px;
}

.cph-flight__bars--down i:nth-child(1) {
  height: 18px;
}
.cph-flight__bars--down i:nth-child(2) {
  height: 14px;
}
.cph-flight__bars--down i:nth-child(3) {
  height: 10px;
}
.cph-flight__bars--down i:nth-child(4) {
  height: 6px;
}

/* ---- Aside (right column - price/CTA) ---- */

.cph-card__aside {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  text-align: left;
  background: var(--cph-primary-mist);
  border-left: 1px solid #cfeceb;
}

/* TEMPORARY: flash-sale countdown badge - see the comment above saleClock() in
   hotelSearch.js for why this counts down from page load rather than a real
   sale-end date. */
.cph-flash {
  flex: 0 0 auto;
  width: 100%;
  height: 28px;
  margin: 0;
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid #c99400;
  border-radius: 10px;
  background: #fff;
}

.cph-flash__mark {
  display: grid;
  place-items: center;
  width: 26px;
  height: 100%;
  flex-shrink: 0;
  background: var(--cph-gold);
  color: var(--cph-primary-deep);
}

.cph-flash__mark svg {
  width: 13px;
  height: 13px;
}

.cph-flash__time {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3px 8px;
  font-family: var(--cph-font-display);
  font-size: 11px;
  font-weight: 800;
  color: var(--cph-primary-deep);
  letter-spacing: 0.02em;
}

/* Groups the stay/price/total lines and pushes itself (and everything after it -
   included/pay-plan/urgency/CTA) down to the bottom of the aside column, so a
   shorter card's price block lines up with a taller neighbour's instead of
   trailing right under the image. The optional .cph-flash badge above stays
   pinned to the top either way. */
.cph-price-block {
  margin-top: auto;
}

.cph-stay {
  margin: 0;
  font-size: 11px;
  color: var(--cph-text-muted);
}

.cph-price-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.cph-was {
  margin: 0;
  color: var(--cph-text-muted);
  text-decoration: line-through;
  font-size: 13px;
  font-weight: 600;
}

.cph-save {
  display: inline-flex;
  background: var(--cph-green);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  border-radius: 999px;
  padding: 2px 7px;
}

.cph-price {
  margin: 4px 0 0;
  font-family: BlinkMacSystemFont, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 32px;
  font-weight: 800;
  color: var(--cph-text);
  line-height: 0.92;
  white-space: nowrap;
}

.cph-price small {
  font-size: 0.68em;
  font-weight: 800;
  vertical-align: baseline;
  line-height: 1;
}

/* The "pp" suffix is the second <small> - shrink it further, but only when there
   really are two (formatTotalPrice() emits just the one "£" <small> on its own,
   and that one should stay at the larger ccy size above). */
.cph-price small:last-child:not(:only-of-type) {
  font-size: 0.5em;
  font-weight: 700;
}

.cph-total {
  margin: 3px 0 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--cph-text);
}

.cph-pay-plan {
  margin: 8px 0 0;
  font-size: 12px;
  font-weight: 700;
  color: var(--cph-text);
  line-height: 1.4;
}

.cph-pay-plan strong {
  color: var(--cph-primary-deep);
}

.cph-pay-plan .cph-text-btn {
  display: block;
  margin: 4px 0 0;
  font-size: 12px;
}

.cph-included {
  margin: 8px 0 0;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--cph-green-text);
}

.cph-included svg,
.cph-urgency svg,
.cph-btn svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.cph-urgency {
  margin: 2px 0 0;
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--cph-urgency-text);
  font-size: 12px;
  font-weight: 800;
}

.cph-card__aside .cph-btn {
  width: 100%;
  margin-top: 8px;
  min-height: 40px;
  gap: 6px;
}

/* Hover/focus tooltip - same interaction as the prototype's .atol/.atol__tip
   (a pure-CSS :hover/:focus reveal, not Bootstrap's JS tooltip plugin, since
   this card's list is re-rendered by Vue and a JS tooltip would need
   re-initialising on every render). Copy and the atol-footer.png badge are the
   same ones the previous, pre-redesign card used (_HotelCardPrice.cshtml). */
.cph-atol {
  position: relative;
  margin: 8px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: help;
}

.cph-atol__logo {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.cph-atol__label {
  font-size: 11px;
  font-weight: 800;
  color: var(--cph-green-text);
  border-bottom: 1px dotted currentColor;
}

.cph-atol__tip {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  z-index: 6;
  width: 200px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--cph-primary-deep);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.45;
  text-transform: none;
  letter-spacing: 0;
  box-shadow: 0 10px 22px rgba(60, 78, 90, 0.22);
  transform: translateX(-50%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

.cph-atol__tip::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -5px;
  width: 10px;
  height: 10px;
  background: var(--cph-primary-deep);
  transform: translateX(-50%) rotate(45deg);
}

.cph-atol:hover .cph-atol__tip,
.cph-atol:focus .cph-atol__tip,
.cph-atol:focus-visible .cph-atol__tip {
  opacity: 1;
  visibility: visible;
}

/* ---- Shared button/text-link styles (scoped copies of the prototype's
   .btn/.btn--primary/.text-btn - not the site's own .btn, which is
   Bootstrap's and must not be touched) ---- */

.cph-btn {
  border: 0;
  border-radius: 10px;
  padding: 10px 16px;
  min-height: 48px;
  font-weight: 700;
  font-family: var(--cph-font);
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition:
    transform 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease;
}

.cph-btn--primary {
  background: linear-gradient(180deg, #14b8b6, var(--cph-primary));
  color: #fff;
  box-shadow: 0 8px 18px rgba(2, 170, 169, 0.28);
}

.cph-btn--primary:hover {
  background: var(--cph-primary-dark);
  transform: translateY(-1px);
  color: #fff;
}

/* Gold CTA variant - stacked on top of .cph-btn--primary (same as the prototype's
   .btn--primary.btn--gold) for the card's booking button and each modal's main
   "continue" action; plain .cph-btn--primary stays teal everywhere else. */
.cph-btn--primary.cph-btn--gold {
  background: var(--cph-gold);
  color: var(--cph-primary-deep);
  box-shadow: inset 0 0 0 1px #c99400;
}

.cph-btn--primary.cph-btn--gold:hover {
  background: #f0b000;
  color: var(--cph-primary-deep);
  box-shadow: inset 0 0 0 1px #b88600;
}

.cph-text-btn {
  border: 0;
  background: none;
  color: var(--cph-primary);
  font: inherit;
  font-family: var(--cph-font);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  padding: 0;
}

.cph-text-btn:hover {
  text-decoration: underline;
}

/* ============================================================================
   Hotel card popups - "View hotel offers" / "View flight times" / "View
   payment details" on the card above open _HotelOffersModal.cshtml /
   _FlightDetailsModal.cshtml / _PaymentDetailsModal.cshtml. Same prototype
   source as the card itself (CyprusParadise-NewDesigns/prototypes/
   search-results/styles.css: .modal / .ticket / .offer- / .pay- / .banner /
   .schedule / .step), rebuilt on top of Bootstrap 5's modal JS instead of
   that prototype's native <dialog> - only .modal/.fade/data-bs-* keep doing
   the actual open/close/backdrop work, every visual rule below is new.

   These three modals are NOT descendants of .cph-card (Bootstrap renders
   them as siblings in _SearchResultsContainer.cshtml), so the --cph-* tokens
   .cph-card declares can't reach them - .cph-modal redeclares the identical
   set itself so the shared .cph-btn/.cph-text-btn/.cph-stars/.cph-ta__*
   rules above still resolve correctly inside a modal. */
.cph-modal {
  --cph-primary: #02aaa9;
  --cph-primary-dark: #218887;
  --cph-primary-deep: #104443;
  --cph-primary-mist: #def6f5;
  --cph-gold: #febb02;
  --cph-coral: #f9706a;
  --cph-green: #23ae24;
  --cph-green-text: #008009;
  --cph-red-soft: #ffe7e8;
  --cph-urgency-text: #c23b4a;
  --cph-text: #3c4e5a;
  --cph-text-muted: #707070;
  --cph-ink: #141515;
  --cph-border: #d8e0e0;
  --cph-font: "Lato", "Segoe UI", sans-serif;
  --cph-font-display: "Montserrat", "Lato", sans-serif;

  border: 0;
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(16, 68, 67, 0.2);
  font-family: var(--cph-font);
  color: var(--cph-text);
  overflow: hidden;
}

.cph-modal *,
.cph-modal *::before,
.cph-modal *::after {
  box-sizing: border-box;
}

.cph-modal--wide,
.cph-modal--offer {
  max-width: 760px;
}

.cph-modal__head,
.cph-modal__foot {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 22px;
  margin: 0;
}

.cph-modal__foot {
  align-items: center;
  border-top: 1px solid #e7eeee;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}

.cph-modal__foot--split {
  justify-content: space-between;
}

.cph-modal__title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-family: var(--cph-font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--cph-primary-deep);
}

.cph-modal__title svg {
  width: 22px;
  height: 22px;
  color: var(--cph-ink);
  flex-shrink: 0;
}

.cph-modal--offer .cph-modal__title {
  color: var(--cph-primary-deep);
  font-size: 22px;
}

.cph-modal__sub {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--cph-text-muted);
}

.cph-modal__x {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border: 0;
  border-radius: 50%;
  background: #eef1f1;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  color: var(--cph-text);
}

.cph-modal__x:hover {
  background: #e4e8e8;
}

.cph-modal__body {
  padding: 0 22px 8px;
  max-height: min(58vh, 520px);
  overflow: auto;
}

.cph-modal__hint {
  margin: 0;
  font-size: 13px;
  color: var(--cph-text-muted);
}

.cph-modal__actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cph-modal__actions .cph-btn {
  min-height: 44px;
  width: auto;
  margin-top: 0;
}

.cph-btn--ghost-dark {
  background: #fff;
  color: var(--cph-primary-deep);
  box-shadow: inset 0 0 0 1px var(--cph-border);
}

.cph-banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #dff6e1;
  color: var(--cph-green-text);
  border: 1px solid #c8e8cc;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 14px;
  margin: 16px 0;
  line-height: 1.45;
}

.cph-banner svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 2px;
}

.cph-banner__lead {
  display: block;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.3;
}

.cph-banner__sub {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.35;
}

/* ---- Hotel offers modal ---- */

.cph-offer-place {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 6px 0 0;
  font-size: 13px;
  color: var(--cph-text-muted);
}

.cph-offer-place svg {
  width: 14px;
  height: 14px;
  color: var(--cph-primary);
}

.cph-offer-place__dot {
  color: var(--cph-border);
}

.cph-offer-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(220px, 0.9fr);
  gap: 22px;
  align-items: stretch;
  min-width: 0;
}

.cph-offer-stay {
  margin: 0 0 4px;
}

.cph-offer-stay strong {
  display: block;
  font-size: 15px;
  color: var(--cph-ink);
}

.cph-offer-stay span {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  color: var(--cph-text-muted);
}

.cph-offer-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.cph-offer-row {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #e7eeee;
  font-size: 14px;
  font-weight: 700;
  color: var(--cph-primary-deep);
  min-width: 0;
}

.cph-offer-row span:nth-child(2) {
  min-width: 0;
  overflow-wrap: anywhere;
}

.cph-offer-row.is-perk {
  color: var(--cph-green-text);
  font-weight: 800;
}

.cph-offer-row__icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--cph-primary-mist);
  color: var(--cph-primary);
}

.cph-offer-row.is-perk .cph-offer-row__icon {
  color: var(--cph-primary);
}

.cph-offer-row__icon svg {
  width: 18px;
  height: 18px;
}

.cph-offer-media {
  position: relative;
  min-height: 280px;
}

.cph-offer-media img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 280px;
  object-fit: cover;
  border-radius: 12px;
}

.cph-offer-ta {
  position: absolute;
  left: 12px;
  bottom: 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  background: #fff;
  border-radius: 10px;
  padding: 8px 10px;
  box-shadow: 0 8px 20px rgba(60, 78, 90, 0.18);
}

/* ---- Flight times modal ---- */

.cph-ticket {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px;
  margin-bottom: 14px;
  border: 1px solid var(--cph-border);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.cph-ticket:last-child {
  margin-bottom: 0;
}

.cph-ticket__main {
  min-width: 0;
  padding: 16px 20px 18px;
}

.cph-ticket__dir {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--cph-primary-dark);
}

.cph-ticket__dir svg {
  width: 16px;
  height: 16px;
}

.cph-ticket__route {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 110px minmax(0, 1fr);
  align-items: start;
  gap: 12px 16px;
}

.cph-ticket__city {
  min-width: 0;
}

.cph-ticket__time {
  display: block;
  font-family: var(--cph-font-display);
  font-size: 26px;
  font-weight: 700;
  color: var(--cph-ink);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.cph-ticket__air {
  display: block;
  margin-top: 6px;
  font-size: 14px;
  font-weight: 700;
  color: var(--cph-text);
  line-height: 1.3;
}

.cph-ticket__iata {
  color: var(--cph-text-muted);
  font-weight: 700;
}

.cph-ticket__date {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 400;
  color: var(--cph-text-muted);
}

.cph-ticket__city--arr {
  text-align: right;
}

.cph-ticket__mid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding-top: 8px;
  min-width: 0;
}

.cph-ticket__dur {
  font-size: 12px;
  font-weight: 700;
  color: var(--cph-text-muted);
}

.cph-ticket__line {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 18px;
  color: var(--cph-primary);
  background: repeating-linear-gradient(90deg, var(--cph-border) 0 5px, transparent 5px 9px) center / 100% 1px no-repeat;
}

.cph-ticket__line svg {
  width: 16px;
  height: 16px;
  background: #fff;
  padding: 0 4px;
}

.cph-ticket__stop {
  display: inline-block;
  border-radius: 999px;
  padding: 2px 8px;
  background: #eef1f1;
  color: var(--cph-text);
  font-size: 11px;
  font-weight: 700;
}

.cph-ticket__stop.is-direct {
  background: #dff6e1;
  color: var(--cph-green-text);
}

.cph-ticket__stub {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 14px 12px;
  text-align: center;
  background: #f4fafa;
  border-left: 1px dashed #c5d6d6;
}

.cph-ticket__stub::before,
.cph-ticket__stub::after {
  content: "";
  position: absolute;
  left: -8px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--cph-border);
}

.cph-ticket__stub::before {
  top: -8px;
}

.cph-ticket__stub::after {
  bottom: -8px;
}

.cph-ticket__flight-label {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cph-text-muted);
}

.cph-ticket__no {
  font-family: var(--cph-font-display);
  font-size: 16px;
  font-weight: 800;
  color: var(--cph-primary);
  line-height: 1.1;
}

/* ---- Payment plan modal ---- */

.cph-pay-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin: 0 0 8px;
  padding: 12px 14px;
  background: var(--cph-primary-mist);
  border-radius: 10px;
  color: var(--cph-primary-dark);
  font-weight: 700;
}

.cph-pay-total strong {
  font-family: var(--cph-font-display);
  font-size: 22px;
  font-weight: 800;
  color: var(--cph-primary-deep);
}

.cph-schedule {
  list-style: none;
  margin: 0;
  padding: 0;
}

.cph-step {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #e7eeee;
}

.cph-step__n {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--cph-primary-mist);
  color: var(--cph-primary-deep);
  font-size: 14px;
  font-weight: 800;
}

.cph-step.is-now .cph-step__n {
  background: var(--cph-primary);
  color: #fff;
}

.cph-step strong {
  display: block;
  font-size: 14px;
  color: var(--cph-ink);
}

.cph-step span {
  font-size: 12px;
  color: var(--cph-text-muted);
}

.cph-step__amt {
  text-align: right;
}

.cph-step__amt strong {
  font-size: 15px;
}

.cph-pay-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin: 14px 0 8px;
  font-size: 12px;
  color: var(--cph-text-muted);
}

.cph-pay-note svg {
  width: 14px;
  height: 14px;
  color: var(--cph-green-text);
  flex-shrink: 0;
  margin-top: 1px;
}

.cph-pay-trust {
  margin: 4px 22px 0;
  padding: 16px 0 8px;
  border-top: 1px solid #e7eeee;
  text-align: center;
}

.cph-pay-trust__title {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cph-primary);
}

.cph-pay-trust__secured {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0;
  color: var(--cph-green-text);
}

.cph-pay-trust__secured svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.cph-pay-trust__secured span {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  font-size: 11px;
  font-weight: 700;
  text-align: left;
}

.cph-pay-trust__secured strong {
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

@media (max-width: 600px) {
  .cph-offer-layout {
    grid-template-columns: 1fr;
  }

  .cph-offer-media {
    order: -1;
    max-width: none;
    min-height: 0;
  }

  .cph-offer-media img {
    min-height: 0;
    height: 200px;
  }

  .cph-offer-ta {
    left: 10px;
    bottom: 10px;
    padding: 7px 9px;
  }

  .cph-ticket {
    grid-template-columns: 1fr;
  }

  .cph-ticket__time {
    font-size: 22px;
  }

  .cph-ticket__route {
    grid-template-columns: minmax(0, 1fr) 72px minmax(0, 1fr);
    gap: 8px;
  }

  .cph-ticket__stub {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 12px;
    border-left: 0;
    border-top: 1px dashed #b7d4d3;
    padding: 12px;
  }

  .cph-ticket__stub::before,
  .cph-ticket__stub::after {
    top: -8px;
    bottom: auto;
  }

  .cph-ticket__stub::before {
    left: -8px;
  }

  .cph-ticket__stub::after {
    left: auto;
    right: -8px;
  }

  .cph-modal__foot--split {
    flex-direction: column;
    align-items: stretch;
  }

  .cph-modal__actions {
    justify-content: flex-end;
  }
}
