:root {
  --xo-purple: #2a0758;
  --xo-purple-2: #4b098c;
  --xo-magenta: #d1007f;
  --xo-orange: #ff6a00;
  --xo-gold: #ffb000;
  --xo-cream: #f5f1e8;
  --xo-card: #fffaf2;
  --xo-white: #ffffff;
  --xo-ink: #24172f;
  --xo-muted: #72677c;
  --xo-line: #eadfce;
  --xo-success-bg: #f2fbf4;
  --xo-success-text: #147a2e;
  --xo-success-line: rgba(22, 163, 74, .35);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(194, 24, 122, .24), transparent 34rem),
    radial-gradient(circle at top right, rgba(255, 122, 26, .26), transparent 30rem),
    var(--xo-cream);
  color: var(--xo-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.demo-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 34px 18px 60px;
}

.demo-intro {
  text-align: center;
  margin: 0 auto 22px;
  max-width: 820px;
}

.demo-logo {
  width: 86px;
  height: auto;
  margin-bottom: 12px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--xo-magenta);
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: 12px;
  font-weight: 900;
}

.demo-intro h1 {
  margin: 0 0 10px;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.05;
  color: var(--xo-purple);
}

.demo-intro p:last-child {
  margin: 0 auto;
  max-width: 680px;
  color: var(--xo-muted);
  font-size: 17px;
}

.xo-widget {
  overflow: hidden;
  border: 1px solid rgba(43, 23, 79, .12);
  border-radius: 32px;
  background: var(--xo-white);
  box-shadow: 0 28px 90px rgba(43, 23, 79, .20);
}

.xo-hero {
  position: relative;
  padding: 30px;
  color: white;
  background: linear-gradient(135deg, #250052 0%, #5a0794 34%, #d1007f 68%, #ff6a00 100%);
}

.xo-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 88% 16%, rgba(255, 255, 255, .24), transparent 14rem);
  pointer-events: none;
}

.xo-hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
}

.xo-brand {
  display: flex;
  gap: 16px;
  align-items: center;
}

.xo-logo {
  width: 70px;
  height: 70px;
  object-fit: contain;
  border-radius: 22px;
  background: rgba(255, 255, 255, .95);
  padding: 7px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .18);
}

.xo-kicker {
  margin: 0 0 6px;
  color: #ffe7c8;
  text-transform: uppercase;
  letter-spacing: .13em;
  font-size: 12px;
  font-weight: 900;
}

.xo-title {
  margin: 0;
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.12;
  max-width: 720px;
}

/* Badlands Tour Company is a DBA of My XO Adventures, and guests who arrived
   from badlandstourcompany.com told Daniel they were confused to land on a page
   branded My XO Adventures. Saying it out loud beats hiding it: the card charge
   and every email say My XO Adventures regardless, so a guest told nothing HERE
   is not spared the confusion, only made to meet it later, alone, holding a
   receipt with the wrong name on it. */
.xo-dba {
  margin: 8px 0 0;
  color: #ffe7c8;
  font-size: 13px;
  line-height: 1.5;
  max-width: 560px;
  opacity: .9;
}

.xo-quick {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
  min-width: 230px;
}

.xo-chip {
  border: 1px solid rgba(255, 255, 255, .28);
  background: rgba(255, 255, 255, .13);
  color: white;
  border-radius: 999px;
  padding: 9px 12px;
  font-size: 13px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.xo-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(340px, .75fr);
}

.xo-main {
  min-width: 0;
  padding: 30px;
  background: linear-gradient(180deg, #ffffff, #fffaf2);
}

.xo-summary {
  padding: 30px;
  background: #fbf3e8;
  border-left: 1px solid var(--xo-line);
}

.xo-section {
  margin: 0 0 24px;
}

.xo-section-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: end;
  margin-bottom: 12px;
}

.xo-section h2 {
  margin: 0;
  font-size: 20px;
  color: var(--xo-purple);
}

.xo-helper {
  margin: 4px 0 0;
  color: var(--xo-muted);
  font-size: 14px;
}

.xo-dates {
  display: block;
  width: 100%;
  overflow-x: auto;
  padding-bottom: 4px;
}

/* Calendar */

/* ⚠️ NO min-width HERE, and that is the whole mobile fix. This used to pin the
   calendar to 720px, with the media queries below only relaxing it to 680px and
   then 640px — i.e. the narrower the screen, the more the calendar overflowed.
   .xo-dates has overflow-x:auto, so it did not break the page; it just meant a
   guest on a 390px phone saw four of seven weekday columns and had to drag the
   calendar sideways to pick a date. It was equally wrong between 901px and
   1100px, where the two-column grid leaves the main column around 550px and a
   720px calendar cannot fit either. Sizing from the container instead of a
   fixed floor kills the whole family of overflow bugs at every width. */
.xo-calendar {
  width: 100%;
  min-width: 0;
  background: linear-gradient(180deg, #fffdf9 0%, #fff8f0 100%);
  border: 1px solid #f1dfca;
  border-radius: 28px;
  padding: 26px;
  box-shadow:
    0 10px 30px rgba(39, 16, 61, .06),
    inset 0 1px 0 rgba(255, 255, 255, .8);
}

.xo-calendar-head {
  display: grid;
  grid-template-columns: 56px 1fr 56px;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
}

.xo-calendar-head strong {
  text-align: center;
  white-space: nowrap;
  font-size: 34px;
  font-weight: 900;
  color: #25123d;
  letter-spacing: -.03em;
}

.xo-calendar-nav {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  border: 1px solid #ead9c7;
  background: rgba(255, 255, 255, .9);
  color: var(--xo-purple);
  font-size: 30px;
  font-weight: 900;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

.xo-calendar-nav:hover {
  transform: translateY(-1px);
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(44, 16, 63, .08);
}

.xo-calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.xo-calendar-weekdays span {
  text-align: center;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 900;
  color: #76698a;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.xo-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
}

.xo-calendar-cell {
  min-width: 0;
  min-height: 118px;
  border: 1px solid #eadfd1;
  border-radius: 24px;
  background: rgba(255, 255, 255, .78);
  color: var(--xo-ink);
  padding: 12px;
  text-align: left;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.xo-calendar-cell:hover {
  transform: translateY(-2px);
}

.xo-calendar-cell.empty {
  background: transparent;
  border: none;
  box-shadow: none;
  cursor: default;
}

.xo-calendar-cell.available {
  background:
    radial-gradient(circle at top right, rgba(22, 163, 74, .14), transparent 45%),
    var(--xo-success-bg);
  border-color: var(--xo-success-line);
  cursor: pointer;
}

.xo-calendar-cell.available:hover {
  box-shadow: 0 12px 24px rgba(54, 128, 62, .12);
}

.xo-calendar-cell.sold-out {
  background: linear-gradient(180deg, rgba(247, 242, 236, .92), rgba(242, 236, 228, .92));
  color: #8b8196;
  opacity: .78;
}

.xo-calendar-cell.active {
  opacity: 1;
  border: 2px solid var(--xo-magenta);
  background:
    radial-gradient(circle at top right, rgba(209, 0, 127, .10), transparent 40%),
    #fffafd;
  box-shadow: 0 14px 28px rgba(209, 0, 127, .14);
}

.xo-calendar-day {
  display: block;
  font-size: 30px;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 14px;
  color: var(--xo-purple);
}

.xo-calendar-cell.available .xo-calendar-day {
  color: var(--xo-success-text);
}

.xo-calendar-cell.sold-out .xo-calendar-day {
  color: #8f849d;
}

.xo-calendar-status {
  display: inline-block;
  width: auto;
  max-width: 100%;
  white-space: nowrap;
  border-radius: 999px;
  padding: 7px 9px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.1;
  text-align: center;
  background: rgba(255, 255, 255, .85);
}

.xo-calendar-cell.available .xo-calendar-status {
  background: rgba(66, 160, 71, .12);
  color: #2f7d32;
}

.xo-calendar-cell.active .xo-calendar-status {
  background: var(--xo-magenta);
  color: #ffffff;
  font-size: 10px;
}

.xo-calendar-cell.sold-out .xo-calendar-status {
  background: rgba(255, 255, 255, .75);
  color: #7f758d;
}

/* Discount / surcharge price badges */
.xo-calendar-cell.has-discount .xo-calendar-status {
  background: rgba(22, 163, 74, .18);
  color: #15803d;
}
.xo-calendar-cell.has-surcharge .xo-calendar-status {
  background: rgba(234, 88, 12, .12);
  color: #c2410c;
}

/* Form */

.xo-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.xo-field {
  margin: 0 0 16px;
}

.xo-field.full {
  grid-column: 1 / -1;
}

.xo-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 900;
  color: var(--xo-purple);
}

.xo-label em {
  color: var(--xo-magenta);
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.xo-input,
.xo-select,
.xo-textarea {
  width: 100%;
  border: 1px solid var(--xo-line);
  border-radius: 16px;
  background: white;
  color: var(--xo-ink);
  padding: 14px 15px;
  font-size: 15px;
  outline: none;
}

.xo-input:focus,
.xo-select:focus,
.xo-textarea:focus {
  border-color: var(--xo-magenta);
  box-shadow: 0 0 0 4px rgba(209, 0, 127, .10);
}

.xo-textarea {
  resize: vertical;
  min-height: 92px;
}

.xo-addon {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  border: 1px solid var(--xo-line);
  border-radius: 20px;
  background: white;
  padding: 15px;
}

.xo-addon input {
  width: 20px;
  height: 20px;
  accent-color: var(--xo-magenta);
  margin-top: 2px;
}

.xo-addon strong {
  display: block;
  color: var(--xo-purple);
}

.xo-addon span {
  display: block;
  color: var(--xo-muted);
  margin-top: 3px;
  font-size: 14px;
}

.xo-phone-row {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 10px;
}

.xo-country {
  padding-left: 10px;
  padding-right: 10px;
}

.xo-hidden {
  display: none !important;
}

/* Summary */

.xo-summary-card {
  position: sticky;
  top: 18px;
  border: 1px solid rgba(43, 23, 79, .12);
  border-radius: 26px;
  background: white;
  padding: 22px;
  box-shadow: 0 18px 46px rgba(43, 23, 79, .12);
}

.xo-summary-card h2 {
  margin: 0 0 14px;
  font-size: 22px;
  color: var(--xo-purple);
}

.xo-mini-tour {
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(43, 23, 79, .08), rgba(242, 153, 74, .12));
  padding: 14px;
  margin-bottom: 14px;
}

.xo-mini-tour strong {
  display: block;
  color: var(--xo-purple);
}

.xo-mini-tour span {
  color: var(--xo-muted);
  font-size: 13px;
}

.xo-row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 10px 0;
  border-bottom: 1px solid #f0e7dc;
  font-size: 15px;
}

.xo-row span:first-child {
  color: var(--xo-muted);
}

.xo-row strong,
.xo-row span:last-child {
  color: var(--xo-ink);
  font-weight: 900;
  text-align: right;
}

.xo-row.total {
  margin-top: 4px;
  padding-top: 16px;
  border-bottom: 0;
  font-size: 24px;
  color: var(--xo-purple);
}

.xo-row.total span {
  color: var(--xo-purple);
  font-weight: 950;
}

.xo-btn {
  width: 100%;
  border: 0;
  border-radius: 18px;
  background: linear-gradient(135deg, #6a00a8, var(--xo-magenta) 54%, var(--xo-orange));
  color: white;
  font-weight: 950;
  padding: 17px 18px;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 0 16px 34px rgba(160, 39, 115, .28);
  margin-top: 18px;
}

.xo-btn:hover {
  filter: brightness(1.03);
  transform: translateY(-1px);
}

.xo-note {
  margin: 14px 0 0;
  color: var(--xo-muted);
  font-size: 13px;
  line-height: 1.45;
  background: #fff4df;
  border: 1px solid #ffd7a2;
  border-radius: 12px;
  padding: 9px 11px;
}

.xo-success,
.xo-error {
  margin-top: 16px;
  border-radius: 18px;
  padding: 15px;
  line-height: 1.45;
}

.xo-success {
  background: #e8f6ec;
  border: 1px solid #b7dfc2;
}

.xo-error {
  background: #fff1f1;
  border: 1px solid #f3b6b6;
}

.xo-alert {
  margin: 10px 0;
  padding: 11px 12px;
  border: 1px solid #f1b8b8;
  border-radius: 14px;
  background: #fff2f2;
  color: #7c2d2d;
  font-weight: 800;
  font-size: 13px;
}

/* Responsive */

@media (max-width: 1100px) {
  .xo-calendar-grid {
    gap: 8px;
  }

  .xo-calendar-cell {
    min-height: 112px;
    padding: 10px;
  }

  .xo-calendar-status {
    font-size: 11px;
  }
}

@media (max-width: 900px) {
  .xo-hero-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .xo-quick {
    justify-content: flex-start;
  }

  .xo-grid {
    grid-template-columns: 1fr;
  }

  .xo-summary {
    border-left: 0;
    border-top: 1px solid var(--xo-line);
  }

  .xo-form-grid {
    grid-template-columns: 1fr;
  }

  .xo-calendar {
    padding: 18px 14px;
  }

  .xo-calendar-grid,
  .xo-calendar-weekdays {
    gap: 8px;
  }

  /* The widest status is "Call to book". Left as nowrap it sets the floor for
     every column, so it wraps to two lines here instead of widening the grid. */
  .xo-calendar-status {
    white-space: normal;
    padding: 4px 6px;
    font-size: 10px;
  }

  .xo-calendar-head strong {
    font-size: 24px;
  }

  .xo-calendar-nav {
    width: 44px;
    height: 44px;
    font-size: 24px;
  }

  .xo-calendar-cell {
    min-height: 88px;
    padding: 8px 6px;
    border-radius: 14px;
    align-items: center;
    text-align: center;
  }

  .xo-calendar-day {
    font-size: 20px;
    margin-bottom: 6px;
  }
}

@media (max-width: 560px) {
  .demo-shell {
    padding: 18px 10px 40px;
  }

  .xo-main,
  .xo-summary,
  .xo-hero {
    padding: 20px;
  }

  .xo-phone-row {
    grid-template-columns: 1fr;
  }

  /* Seven columns on a 360px phone: ~320px of page, minus 20px of calendar
     padding and 24px of gaps, leaves about 39px a cell. A day number fits at
     this size. A "$1,144" or "Call to book" pill does not, so the status keeps
     its text in the DOM for screen readers and for the accessible name of the
     button, and renders as a coloured dot. The colours are the ones the pill
     already used, so nothing new is introduced, and the cell background and
     day-number colour still carry the state as well — the dot is a third
     signal, not the only one. The price is not lost: tapping a date shows it
     in the summary panel, which is where a guest confirms it anyway. */
  .xo-calendar {
    padding: 12px 10px;
    border-radius: 18px;
  }

  .xo-calendar-grid,
  .xo-calendar-weekdays {
    gap: 4px;
  }

  .xo-calendar-weekdays span {
    font-size: 10px;
    letter-spacing: 0;
  }

  .xo-calendar-cell {
    min-height: 52px;
    padding: 6px 2px;
    border-radius: 10px;
    justify-content: center;
  }

  .xo-calendar-day {
    font-size: 15px;
    margin-bottom: 4px;
  }

  .xo-calendar-status {
    width: 8px;
    height: 8px;
    min-width: 8px;
    padding: 0;
    font-size: 0;
    line-height: 0;
    border-radius: 999px;
  }

  /* ⚠️ THE PILL COLOURS CANNOT BE REUSED AS DOT COLOURS. Every one of them is a
     10-18% tint over a pale cell, which reads fine behind dark pill TEXT and is
     invisible as an 8px disc — sold-out's is literally white. So the dot gets a
     solid version of the same hue. Ordered so the more specific state wins on
     equal specificity: a day that is `available has-surcharge` shows the
     surcharge colour, and a selected day shows magenta over everything. */
  .xo-calendar-cell.available .xo-calendar-status {
    background: #16a34a;
  }

  .xo-calendar-cell.has-discount .xo-calendar-status {
    background: #15803d;
  }

  .xo-calendar-cell.has-surcharge .xo-calendar-status {
    background: #ea580c;
  }

  .xo-calendar-cell.sold-out .xo-calendar-status {
    background: #b3a9c0;
  }

  .xo-calendar-cell.active .xo-calendar-status {
    background: var(--xo-magenta);
  }

  .xo-calendar-cell.active {
    border-width: 2px;
  }
}