/* ==========================================================================
   Trip budget estimator (round 112). Two cards on the marketing shell:
   the trip on the left, the estimate on the right; stacked on a phone.
   Brand tokens only (main.css): ink, accent, bg-soft, muted, border.
   ========================================================================== */

.bg-wrap {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 18px;
  max-width: 980px;
  margin: 0 auto;
  align-items: start;
}
@media (max-width: 820px) {
  .bg-wrap { grid-template-columns: 1fr; }
}

.bg-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 20px 22px;
  box-shadow: 0 1px 3px rgba(20, 33, 61, 0.05);
}
.bg-card-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 14px;
}

.bg-field { display: block; margin-bottom: 16px; }
.bg-label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 7px;
}
.bg-hint { display: block; font-size: 12px; color: var(--muted); margin-top: 6px; min-height: 14px; }

.bg-input-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg-soft);
  padding: 0 12px;
  color: var(--muted);
}
.bg-input-wrap:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(var(--accent-rgb), 0.14); background: var(--bg); }
/* 44px minimum (round 122j). #bg-destination and #bg-flights measured 41
   -- they sit in .bg-input-wrap rather than a .bg-stepper, so the
   site-wide rule in main.css could not reach them. The wrap draws the
   visible field, so the height goes on the wrap and the input fills it. */
.bg-input-wrap { min-height: 44px; }
/* On the INPUT as well, not only the wrap: a tap on the wrap's padding
   does not focus the field, so the wrap's height buys the field nothing.
   The input is what has to be 44 tall. */
.bg-input-wrap input { min-height: 44px; }
.bg-input-wrap input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 12px 0;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  outline: none;
}
.bg-money .bg-rupee { font-weight: 700; color: var(--ink); }
.bg-input-wrap input[type="number"] { -moz-appearance: textfield; }
.bg-input-wrap input::-webkit-outer-spin-button, .bg-input-wrap input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.bg-two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; }
.bg-stepper { border: 1px solid var(--border); border-radius: 12px; background: var(--bg-soft); padding: 12px 12px 10px; }
.bg-stepper .bg-label { margin-bottom: 8px; }
.bg-stepper-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.bg-stepper-row output { font-family: var(--font-display); font-size: 26px; font-weight: 700; color: var(--ink); line-height: 1; }
.bg-stepper-wide { margin-bottom: 16px; }
.bg-stepper-wide .bg-stepper-row { gap: 12px; }
.bg-stepper-wide .bg-rooms-hint { flex: 1; margin: 0; }
.bg-stepper-ctl { display: flex; align-items: center; gap: 8px; }
.bg-stepper-ctl output { min-width: 44px; text-align: center; font-size: 20px; }
/* 44, not 34 (round 122j). These are the +/- buttons on the days and
   travellers steppers -- the controls somebody taps five or six times in
   a row -- and they were the smallest interactive targets on the page.
   Unlike the wordmark this one does grow visually, because a stepper
   button IS its hit area; the row is flex and centred, so the two grow
   symmetrically around the number between them. */
.bg-step {
  width: 44px; height: 44px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--accent-ink);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.bg-step:hover { border-color: var(--accent); }
.bg-step:disabled { opacity: 0.35; cursor: default; }

.bg-seg { display: flex; gap: 6px; padding: 5px; background: var(--bg-soft); border: 1px solid var(--border); border-radius: 14px; }
.bg-seg-btn {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 9px 6px;
  border: 0; border-radius: 10px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
}
.bg-seg-btn b { font-size: 14px; color: var(--ink); }
.bg-seg-btn small { font-size: 11px; }
.bg-seg-btn.is-on { background: var(--bg); box-shadow: 0 1px 3px rgba(20, 33, 61, 0.12); }
.bg-seg-btn.is-on b { color: var(--accent-ink); }

/* --- the estimate --- */
.bg-total {
  background: linear-gradient(135deg, var(--accent-dark) 0%, var(--accent) 100%);
  color: #fff;
  border-radius: 16px;
  padding: 20px 22px 16px;
  text-align: center;
}
.bg-total-kicker { display: block; font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.85; }
.bg-total-main { font-family: var(--font-display); font-size: 42px; font-weight: 800; letter-spacing: -0.02em; margin-top: 6px; line-height: 1.05; }
.bg-total-sub { font-size: 13px; opacity: 0.92; margin-top: 6px; }
.bg-total-sub b { font-weight: 700; }
.bg-range { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, 0.28); font-size: 13px; }
.bg-range > span { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.bg-range small { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.8; }
.bg-range-line { flex: 1; height: 2px; border-radius: 2px; background: rgba(255, 255, 255, 0.35); position: relative; }
.bg-range-line::after { content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: #fff; }

.bg-bar { display: flex; height: 12px; border-radius: 99px; overflow: hidden; background: var(--bg-soft); margin: 18px 0 10px; }
.bg-bar span { display: block; height: 100%; transition: width 0.3s ease; }
.bg-legend { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12px; color: var(--muted); }
.bg-legend i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 5px; vertical-align: 0; }

.bg-lines { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--border); }
.bg-lines li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.bg-lines .bg-line-name { display: flex; align-items: center; gap: 9px; color: var(--ink); font-weight: 600; min-width: 0; }
.bg-lines .bg-line-name i { flex: 0 0 9px; width: 9px; height: 9px; border-radius: 50%; }
.bg-lines .bg-line-amt { text-align: right; white-space: nowrap; }
.bg-lines .bg-line-amt b { display: block; color: var(--ink); font-weight: 700; }
.bg-lines .bg-line-amt small { color: var(--muted); font-size: 11px; }

/* category colours: the accent family plus two warm accents, all on-brand */
.bg-c-flights { background: #14213D; }
.bg-c-lodging { background: var(--accent); }
.bg-c-dining { background: var(--accent-bright); }
.bg-c-transit { background: #F2994A; }
.bg-c-activity { background: #2BB673; }
.bg-c-buffer { background: #C7CCD6; }

.bg-tip { margin-top: 16px; background: var(--accent-bg-soft); border: 1px solid rgba(var(--accent-rgb), 0.18); border-radius: 12px; padding: 12px 14px; }
.bg-tip-head { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent-ink); }
.bg-tip p { margin: 6px 0 0; font-size: 13.5px; line-height: 1.55; color: var(--ink); }

.bg-actions { margin-top: 18px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.bg-actions .btn-vivid { width: 100%; justify-content: center; text-align: center; }
.bg-foot { margin: 0; font-size: 12px; color: var(--muted); text-align: center; line-height: 1.5; }

/* Round 122r: 1.4.10 -- the card grid must be allowed to shrink. */
.bg-card { min-width: 0; }
.bg-card-title { overflow-wrap: anywhere; }
@media (max-width: 359px) {
  .bg-card { padding: 16px 14px; }
}
@media (max-width: 359px) {
  .bg-two { grid-template-columns: 1fr; } /* two 44px steppers no longer fit side by side */
}
