/**
 * widget.css — Booking Widget Styles
 * ────────────────────────────────────────────────────────────
 * Castle Rock #2D3436 (primary) · Teal #00B894 (CTA)
 */

/* ═══════════════════════════════════════════════════════
   WIDGET CONTAINER
   ═══════════════════════════════════════════════════════ */
.hp-widget {
  background: var(--hp-white);
  border-radius: var(--hp-radius);
  box-shadow: var(--hp-shadow-lg);
  padding: 24px;
  width: 100%;
  max-width: 380px;
}

/* ═══════════════════════════════════════════════════════
   DURATION TOGGLE
   ═══════════════════════════════════════════════════════ */
.hp-widget-duration {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}
.hp-widget-dur-btn {
  flex: 1;
  padding: 10px 12px;
  border: 2px solid var(--hp-gray-200);
  border-radius: var(--hp-radius-sm);
  font-size: 14px;
  font-weight: 600;
  color: var(--hp-text);
  background: var(--hp-white);
  transition: all .15s;
}
.hp-widget-dur-btn:hover { border-color: var(--hp-gray-400); }
.hp-widget-dur-btn--active {
  border-color: var(--hp-cta);
  background: rgba(0,184,148,.06);
  color: var(--hp-cta);
}
.hp-widget-dur-mobile { display: none; }

/* ═══════════════════════════════════════════════════════
   PAX STEPPER
   ═══════════════════════════════════════════════════════ */
.hp-widget-date {
  margin-bottom: 16px;
}
.hp-widget-date-input {
  width: 100%;
  box-sizing: border-box;
  padding: 11px 12px;
  border: 1px solid var(--hp-border, #dcdcdc);
  border-radius: 10px;
  font: inherit;
  font-size: 15px;
  color: var(--hp-text);
  background: #fff;
  /* iOS zentriert type=date sonst nicht und schrumpft das Feld */
  -webkit-appearance: none;
  appearance: none;
  min-height: 44px;
}
.hp-widget-date-input:focus {
  outline: 2px solid var(--hp-cta);
  outline-offset: 1px;
  border-color: var(--hp-cta);
}

.hp-widget-pax {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
}
.hp-widget-pax-group {
  flex: 1;
}
.hp-widget-pax-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--hp-text-muted);
  margin-bottom: 6px;
}
.hp-widget-stepper {
  display: flex;
  align-items: center;
  border: 2px solid var(--hp-gray-200);
  border-radius: var(--hp-radius-sm);
  overflow: hidden;
}
.hp-widget-stepper-btn {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 600;
  color: var(--hp-text);
  background: var(--hp-gray-100);
  transition: background .12s;
  user-select: none;
}
.hp-widget-stepper-btn:hover { background: var(--hp-gray-200); }
.hp-widget-stepper-btn:disabled {
  opacity: .35;
  cursor: not-allowed;
}
.hp-widget-stepper-val {
  flex: 1;
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  min-width: 32px;
}

/* ═══════════════════════════════════════════════════════
   SUBMIT
   ═══════════════════════════════════════════════════════ */
.hp-widget-submit {
  display: block;
  width: 100%;
  padding: 14px 20px;
  background: var(--hp-cta) !important;
  color: var(--hp-white) !important;
  text-decoration: none !important;
  border: none;
  border-radius: var(--hp-radius-sm);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity .15s;
}
.hp-widget-submit:hover { opacity: .88; color: var(--hp-white) !important; }

/* ═══════════════════════════════════════════════════════
   RESULTS
   ═══════════════════════════════════════════════════════ */
.hp-widget-results {
  margin-top: 20px;
}
.hp-widget-results-loading {
  text-align: center;
  padding: 24px 0;
  color: var(--hp-text-muted);
  font-size: 14px;
}
.hp-widget-result-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--hp-gray-100);
}
.hp-widget-result-card:last-child { border-bottom: none; }
.hp-widget-result-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
}
.hp-widget-result-logo {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  object-fit: contain;
  flex-shrink: 0;
  background: var(--hp-gray-100);
  padding: 4px;
}
.hp-widget-result-info { min-width: 0; }
.hp-widget-result-name {
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hp-widget-result-via {
  font-size: 12px;
  color: var(--hp-text-muted);
}
.hp-widget-result-right {
  text-align: right;
  flex-shrink: 0;
}
.hp-widget-result-price {
  font-size: 18px;
  font-weight: 800;
  color: var(--hp-text);
}
.hp-widget-result-book {
  display: inline-block;
  margin-top: 4px;
  padding: 6px 16px;
  background: var(--hp-cta) !important;
  color: var(--hp-white) !important;
  text-decoration: none !important;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
  transition: opacity .15s;
}
.hp-widget-result-book:hover { opacity: .88; color: var(--hp-white) !important; }
.hp-widget-result-best {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--hp-cta);
  letter-spacing: .3px;
  margin-bottom: 2px;
}
.hp-widget-result-save {
  font-size: 11px;
  color: var(--hp-cta);
  font-weight: 600;
  margin-top: 2px;
}
.hp-widget-noresults {
  text-align: center;
  padding: 20px 0;
  color: var(--hp-text-muted);
  font-size: 14px;
}

/* ═══════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .hp-widget {
    max-width: 100%;
  }
  .hp-widget-dur-desktop { display: none; }
  .hp-widget-dur-mobile  { display: inline; }
}
@media (max-width: 400px) {
  .hp-widget { padding: 16px; }
  .hp-widget-pax { gap: 10px; }
}

/* ═══════════════════════════════════════════════════════
   KINDER-ALTERSGRENZEN — Info-Pille + Zeile in der Karte
   Aus HoponRome portiert (16.09.2026), Farbvariablen auf
   Edinburghs Tokens umgestellt, Kartenklasse hp-rcard-*.
   ═══════════════════════════════════════════════════════ */
.hp-widget-info {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  margin-left: 4px;
  color: var(--hp-cta);
  cursor: pointer;
  vertical-align: -3px;
  position: relative;
  border-radius: 50%;
  transition: color 0.15s ease, background 0.15s ease;
}
.hp-widget-info[aria-expanded="true"] {
  color: #fff;
  background: var(--hp-cta);
  outline: none;
}
.hp-widget-info svg { display: block; }
.hp-widget-info:focus-within .hp-widget-popover {
  display: block;
}
.hp-widget-popover {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  width: 280px;
  max-width: calc(100vw - 32px);
  background: #fff;
  color: var(--hp-text);
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18), 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 14px 16px;
  z-index: 50;
  text-align: left;
  font-size: 0.85rem;
  line-height: 1.5;
  font-weight: 400;
  white-space: normal;
  cursor: default;
}
.hp-widget-popover::before {
  content: "";
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 7px solid transparent;
  border-bottom-color: #fff;
}
.hp-widget-info:focus-within .hp-widget-popover {
  display: block;
}
.hp-widget-popover-title {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 4px;
  color: var(--hp-text);
}
.hp-widget-popover-intro {
  display: block;
  color: #555;
  margin-bottom: 10px;
}
.hp-widget-popover-list {
  display: block;
  border-top: 1px solid #eee;
  margin-bottom: 8px;
}
.hp-widget-popover-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 6px 0;
  border-bottom: 1px solid #f1f1f1;
}
.hp-widget-popover-row:last-child { border-bottom: none; }
.hp-widget-popover-op {
  font-weight: 600;
  color: var(--hp-text);
}
.hp-widget-popover-age {
  font-variant-numeric: tabular-nums;
  color: var(--hp-cta-hover);
  font-weight: 600;
  white-space: nowrap;
}
.hp-widget-popover-foot {
  display: block;
  color: #777;
  font-size: 0.78rem;
  margin-top: 4px;
}
.hp-widget-popover {
    left: 0;
    transform: none;
    width: min(280px, calc(100vw - 40px));
  }
.hp-widget-popover::before { left: 9px; transform: none; }
.hp-rcard-childage {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 8px 0 4px;
  font-size: 0.78rem;
  color: #666;
  line-height: 1.3;
}
.hp-rcard-childage svg {
  flex-shrink: 0;
  color: #999;
}
.hp-rcard--best .hp-rcard-childage {
  margin-bottom: 10px;
}

/* Freikontingent fuer Kinder — dieselbe Zeilenform wie die Altersspanne,
   aber in der CTA-Farbe: das ist ein Vorteil, kein Kleingedrucktes. */
.hp-rcard-childfree {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 2px 0 4px;
  font-size: 0.78rem;
  color: var(--hp-cta);
  line-height: 1.3;
}
.hp-rcard-childfree svg {
  flex-shrink: 0;
}
.hp-rcard--best .hp-rcard-childfree {
  margin-bottom: 10px;
}
