/* Libélula booker (scripts/booker.js, 9-oct-2026), third pass: Calendly's pattern in Libélula's materials.
   Screen 1 = calendar left, free times in a column right (a picked time splits into the time and "Next").
   Question screens = one quiet line with ← and the chosen time, then the questions, one button.
   The one expressive element: the chosen date set in Cormorant. Everything else stays quiet. */

.bk {
  --bk-paper: #fffdf8; --bk-line: #e6e0d2; --bk-forest: #2F4A3A; --bk-moss: #e9efe4; --bk-moss-hover: #dbe5d4;
  --bk-ink: #2b322b; --bk-soft: #6e746b; --bk-field: #f8f6f0;
  width: 100%; max-width: 640px; margin: 0 auto; color: var(--bk-ink); text-align: left;
}
.bk button, .bk input, .bk textarea { font-family: inherit; }
.bk :focus-visible { outline: 2px solid var(--bk-forest); outline-offset: 2px; }

.bk-card {
  background: var(--bk-paper); border: 1px solid var(--bk-line); border-radius: 16px;
  box-shadow: 0 20px 50px -34px rgba(31,42,34,.22);
}

/* ---------- screen 1: calendar | times ---------- */
.bk-card--time { padding: 0; }
.bk-time { display: grid; grid-template-columns: minmax(0, 1fr) 232px; }
.bk-cal { padding: 24px 24px 20px; }
.bk-slots { padding: 24px 20px 20px; border-left: 1px solid var(--bk-line); display: flex; flex-direction: column; min-height: 0; }

.bk-cal__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.bk-month { font-size: 15px; font-weight: 600; color: var(--bk-ink); }
.bk-arrows { display: flex; gap: 4px; }
.bk-mo {
  width: 32px; height: 32px; border-radius: 50%; border: 0; background: transparent; color: var(--bk-forest);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
}
.bk-mo svg, .bk-top__back svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.bk-mo:hover:not(:disabled) { background: var(--bk-moss); }
.bk-mo:disabled { color: #c9c6bc; cursor: default; }

.bk-grid { position: relative; --cell: 40px; --gap: 4px; --dowh: 30px; }
.bk-dow, .bk-days { display: grid; grid-template-columns: repeat(7, 1fr); position: relative; }
.bk-dow span { height: var(--dowh); display: flex; align-items: center; justify-content: center; font-size: 12px; color: var(--bk-soft); }
.bk-dow span.is-on { color: var(--bk-forest); font-weight: 600; }
.bk-dow span.is-on::before { content: ""; position: absolute; inset: 3px calc(50% - 22px); border-radius: 8px; background: #eef3ea; z-index: -1; }
.bk-dow span { position: relative; z-index: 0; }
.bk-days { row-gap: var(--gap); margin-top: 4px; }
.bk-day {
  width: var(--cell); height: var(--cell); margin: 0 auto; border: 0; border-radius: 10px; background: transparent;
  font-size: 14.5px; color: #bdbab0; display: inline-flex; align-items: center; justify-content: center; position: relative;
}
.bk-day.is-pad { visibility: hidden; }
.bk-day.is-free { background: var(--bk-moss); color: var(--bk-forest); font-weight: 600; cursor: pointer; transition: background .15s; }
.bk-day.is-free:hover { background: var(--bk-moss-hover); }
.bk-day.is-on, .bk-day.is-on:hover { background: var(--bk-forest); color: #fff; }   /* no halo: it spilled onto the next days (Matías, 9-oct) */
.bk-day.is-today::after { content: ""; position: absolute; bottom: 5px; left: 50%; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: currentColor; }
.bk-days.is-loading { opacity: .5; }
.bk-tz { position: relative; margin: 20px 0 0; }
.bk-tz__l { display: block; font-size: 13px; font-weight: 600; color: var(--bk-ink); margin-bottom: 6px; }
.bk-tzbtn {
  display: inline-flex; align-items: center; gap: 8px; max-width: 100%; padding: 6px 10px 6px 8px; margin-left: -8px;
  border: 0; border-radius: 8px; background: transparent; font-size: 13.5px; color: var(--bk-ink); cursor: pointer; text-align: left;
}
.bk-tzbtn:hover, .bk-tzbtn[aria-expanded="true"] { background: var(--bk-field); }
.bk-tzbtn svg { width: 16px; height: 16px; flex: 0 0 auto; fill: none; stroke: var(--bk-soft); stroke-width: 1.5; stroke-linecap: round; }
.bk-tzbtn .bk-tz__caret { stroke: var(--bk-forest); stroke-width: 2; width: 14px; height: 14px; }
.bk-tzbtn > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bk-tz__g { color: var(--bk-soft); font-variant-numeric: tabular-nums; }
.bk-tzpop {
  position: absolute; left: -8px; bottom: calc(100% + 6px); z-index: 20; width: 340px; max-width: calc(100vw - 32px);   /* opens upward, over the calendar: never cut off by the card */
  background: #fff; border: 1px solid var(--bk-line); border-radius: 12px; box-shadow: 0 18px 40px -16px rgba(31,42,34,.25);
  overflow: hidden;
}
.bk-tzsearch { position: relative; padding: 10px; border-bottom: 1px solid var(--bk-line); }
.bk-tzsearch svg { position: absolute; left: 22px; top: 50%; width: 16px; height: 16px; margin-top: -8px; fill: none; stroke: var(--bk-soft); stroke-width: 1.8; stroke-linecap: round; }
.bk-tzq {
  width: 100%; height: 40px; padding: 0 12px 0 36px; border: 1px solid var(--bk-line); border-radius: 8px; background: var(--bk-field);
  font-size: 15px; color: var(--bk-ink);
}
.bk-tzq:focus { outline: none; border-color: var(--bk-forest); background: #fff; }
.bk-tzlist { max-height: 264px; overflow-y: auto; padding: 6px; scrollbar-width: thin; }
.bk-tzopt {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; width: 100%; padding: 9px 10px;
  border: 0; border-radius: 7px; background: transparent; font-size: 14px; color: var(--bk-ink); cursor: pointer; text-align: left;
}
.bk-tzopt:hover, .bk-tzopt.is-act { background: #f4f1ea; }
.bk-tzopt.is-on { color: var(--bk-forest); font-weight: 600; }
.bk-tzempty { padding: 14px 10px; margin: 0; font-size: 14px; color: var(--bk-soft); }

.bk-slots__day { font-family: var(--font-display); white-space: nowrap; font-size: 21px; line-height: 1.15; color: var(--bk-ink); margin: 2px 0 16px; }
.bk-slots__list { display: grid; gap: 8px; max-height: 520px; overflow-y: auto; padding-right: 2px; scrollbar-width: thin; }   /* a whole day fits (Matías, 9-oct); only a very full day scrolls */
.bk-slot {
  height: 44px; border-radius: 8px; border: 1px solid #b9c7b4; background: transparent; width: 100%;
  font-size: 14.5px; font-weight: 600; color: var(--bk-forest); cursor: pointer; transition: border-color .15s, box-shadow .15s;
}
.bk-slot:hover { border-color: var(--bk-forest); box-shadow: inset 0 0 0 1px var(--bk-forest); }
.bk-slot-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.bk-slot.is-on { display: inline-flex; align-items: center; justify-content: center; background: #5d635b; border-color: #5d635b; color: #fff; }
.bk-slot-next { height: 44px; border-radius: 8px; border: 0; background: var(--bk-forest); color: #fff; font-size: 14.5px; font-weight: 600; cursor: pointer; }
.bk-slot-next:hover { background: #253c2f; }
.bk-empty { font-size: 14.5px; line-height: 1.6; color: var(--bk-soft); margin: 0; }
.bk-empty a, .bk-fail a { color: var(--bk-forest); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- question screens ----------
   One measuring system (Matías, 9-oct: "diseño impecable"). Spacing steps 4·8·10·16·20·24·28·32.
   Every control is 48px tall, 10px corners, the same cream with the same hairline; the button is 52px.
   Label → answer 10px, question → question 28px, last answer → button 36px, card padding 32px. */
.bk { --bk-ctl: #f5f2eb; --bk-ctl-line: #e9e3d6; --bk-ctl-hover: #efebe2; --bk-on-line: #c9d6c3; }
.bk-card:not(.bk-card--time) { padding: 24px 32px 32px; }
.bk-top { position: relative; display: flex; align-items: center; gap: 14px; padding-bottom: 20px; margin-bottom: 28px; }
.bk-top__bar { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; border-radius: 2px; background: var(--bk-line); overflow: hidden; }
.bk-top__bar i { display: block; height: 100%; background: var(--bk-forest); border-radius: 2px; transition: width .35s ease; }
.bk-top__back {
  width: 36px; height: 36px; flex: 0 0 auto; margin-left: -8px; border-radius: 50%; border: 0; background: transparent;
  color: var(--bk-forest); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; transition: background .15s;
}
.bk-top__back:hover { background: var(--bk-ctl); }
.bk-top__when { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.bk-top__when strong { font-family: var(--font-display); font-weight: 500; font-size: 21px; line-height: 1.15; color: var(--bk-ink); }
.bk-top__when span { font-size: 13px; line-height: 1.3; color: var(--bk-soft); }
.bk-top__of { margin-left: auto; align-self: flex-start; margin-top: 3px; font-size: 13px; color: var(--bk-soft); white-space: nowrap; font-variant-numeric: tabular-nums; }
.bk-h { font-family: var(--font-display); font-size: 27px; font-weight: 500; line-height: 1.15; letter-spacing: -.005em; color: var(--bk-ink); margin: 0 0 24px; outline: none; }
.bk-sub { margin: -18px 0 24px; font-size: 14.5px; line-height: 1.5; color: var(--bk-soft); }

.bk-body { display: grid; gap: 28px; grid-template-columns: minmax(0, 1fr); }   /* never stretched by a wide row */
.bk-field[hidden] { display: none; }
.bk-label { display: block; font-size: 15px; font-weight: 500; line-height: 1.45; color: var(--bk-ink); margin-bottom: 10px; }
.bk-opt { font-weight: 400; color: var(--bk-soft); font-size: 13.5px; white-space: nowrap; }
.bk-field input[type="text"], .bk-field input[type="email"], .bk-field input[type="tel"], .bk-field textarea {
  display: block; width: 100%; font-size: 16px; line-height: 1.4; color: var(--bk-ink);
  background: var(--bk-ctl); border: 1px solid var(--bk-ctl-line); border-radius: 10px;
  padding: 0 16px; height: 48px; transition: border-color .15s, background .15s, box-shadow .15s;
}
.bk-field textarea { height: auto; min-height: 96px; padding: 12px 16px; resize: none; overflow: hidden; line-height: 1.5; }
.bk-field input::placeholder, .bk-field textarea::placeholder { color: #a9a596; }
.bk-field input:hover, .bk-field textarea:hover { border-color: #ddd5c4; }
.bk-field input:focus, .bk-field textarea:focus { outline: none; border-color: var(--bk-forest); background: #fff; box-shadow: 0 0 0 3px rgba(47,74,58,.08); }

/* answers. One choice = a segmented control: ONE horizontal row in the control cream, the chosen one lifts out in
   white (track 12px corners, chip 8px = 12 − 4 padding, so the curves stay parallel). When the row doesn't fit it
   becomes option cards that fill the column like the text boxes, each with the mark people know: a circle for
   "pick one", a box for "pick several". The weight never changes on select, so nothing jumps. */
.bk-chips { gap: 4px; }
.bk-chips.is-seg { display: inline-flex; flex-wrap: nowrap; padding: 4px; background: var(--bk-ctl); border: 1px solid var(--bk-ctl-line); border-radius: 12px; }
.bk-chips.is-seg .bk-chip { flex: 1 0 auto; width: auto; min-height: 38px; justify-content: center; white-space: nowrap; min-width: 92px; padding: 0 20px; border-radius: 8px; }   /* never squeezed: if the row is too wide, fitChoices() switches to cards */
.bk-chips.is-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.bk-chips.is-cards.is-odd { grid-template-columns: minmax(0, 1fr); }
.bk-chip {
  display: flex; align-items: center; gap: 12px; width: 100%; min-height: 48px;
  border-radius: 10px; border: 1px solid transparent; background: transparent; text-align: left;
  font-size: 15px; font-weight: 500; line-height: 1.35; color: var(--bk-ink); cursor: pointer; transition: background .15s, color .15s, box-shadow .15s, border-color .15s;
}
.bk-chips.is-seg .bk-chip { color: #4d544c; }
.bk-chips.is-seg .bk-chip:hover:not(.is-on) { color: var(--bk-ink); background: rgba(255,255,255,.5); }
.bk-chips.is-cards .bk-chip { background: var(--bk-ctl); border-color: var(--bk-ctl-line); padding: 12px 16px; }
.bk-chips.is-cards .bk-chip:hover:not(.is-on) { background: var(--bk-ctl-hover); border-color: #ddd5c4; }
.bk-chip.is-on { background: #fff; color: var(--bk-forest); box-shadow: 0 1px 2px rgba(31,42,34,.07), 0 2px 8px rgba(31,42,34,.07); }
.bk-chips.is-cards .bk-chip.is-on { background: #fff; border-color: var(--bk-on-line); }
.bk-mark { display: none; flex: 0 0 auto; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid #b5b0a2; background: #fff; align-items: center; justify-content: center; transition: background .15s, border-color .15s, box-shadow .15s; }
.bk-chips.is-cards .bk-mark { display: inline-flex; }
.bk-chip[data-multi] .bk-mark { border-radius: 5px; }
.bk-mark svg { width: 12px; height: 12px; fill: none; stroke: #fff; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; visibility: hidden; }
.bk-chip.is-on .bk-mark { border-color: var(--bk-forest); background: var(--bk-forest); box-shadow: inset 0 0 0 3.5px #fff; }
.bk-chip[data-multi].is-on .bk-mark { box-shadow: none; }
.bk-chip[data-multi].is-on .bk-mark svg { visibility: visible; }

/* No / Yes questions together: one list, question left, answer right, a hairline between rows */
.bk-yn { display: grid; border-top: 1px solid var(--bk-line); }
.bk-field--yn { padding: 16px 0; border-bottom: 1px solid var(--bk-line); }
.bk-yn__row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; align-items: center; }
.bk-yn__row .bk-label { margin: 0; }
.bk-yn__row .bk-chips.is-seg .bk-chip { min-width: 64px; padding: 0 18px; }

.bk-check { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.55; color: var(--bk-soft); cursor: pointer; }
.bk-check input { width: 18px; height: 18px; margin: 2px 0 0; flex: 0 0 auto; accent-color: var(--bk-forest); cursor: pointer; }
.bk-err { margin: 8px 0 0; font-size: 13.5px; color: #9a4a35; }
.bk-field.has-err input, .bk-field.has-err textarea { border-color: #d3a594; }
.bk-field.has-err .bk-chips.is-seg { border-color: #d3a594; }
.bk-field.has-err .bk-chips.is-cards .bk-chip:not(.is-on) { border-color: #e3c2b6; }
.bk-note { margin: 0; padding: 12px 16px; border-radius: 10px; background: #f3ede1; font-size: 14px; color: var(--bk-ink); }

.bk-next {
  display: block; width: 100%; margin-top: 36px; height: 52px; border-radius: 10px; border: 0;
  background: var(--bk-forest); color: #fff; font-size: 15.5px; font-weight: 600; letter-spacing: .005em; cursor: pointer; transition: background .15s;
}
.bk-next:hover { background: #253c2f; }
.bk-fail { margin: 14px 0 0; font-size: 14px; line-height: 1.55; color: #9a4a35; }
.bk-fail[hidden] { display: none; }
.confirm__when { font-size: 15px !important; font-weight: 500; color: var(--jungle-deep) !important; margin-top: 16px !important; }

@media (prefers-reduced-motion: reduce) { .bk * { transition: none !important; } }

/* phone: one column; the section is already a card, so no second frame */
@media (max-width: 640px) {
  .discovery__booking > .calkind .calkind__btn { white-space: nowrap; padding: 10px 14px; font-size: 13.5px; }
  .bk-card { border: 0; border-radius: 0; background: transparent; box-shadow: none; }
  .bk-card:not(.bk-card--time) { padding: 0; }
  .bk-time { grid-template-columns: 1fr; }
  .bk-cal { padding: 0; }
  .bk-slots { padding: 20px 0 0; margin-top: 20px; border-left: 0; border-top: 1px solid var(--bk-line); }
  .bk-slots__list { max-height: none; grid-template-columns: 1fr 1fr; }
  .bk-slot-pick { grid-column: 1 / -1; }
  .bk-chips.is-cards { grid-template-columns: minmax(0, 1fr); }
  .bk-chips.is-seg .bk-chip { min-width: 0; padding: 0 14px; }   /* short rows still fit on a phone */
  .bk-yn__row { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .bk-yn__row .bk-chips.is-seg { justify-self: start; }
  .bk-h { font-size: 25px; }
  .bk-tzpop { left: 0; right: 0; width: auto; max-width: none; bottom: auto; top: calc(100% + 6px); }
  .bk-grid { --cell: 38px; }
}

/* tz rows: country first (9-oct) */
.bk-tzrow { display: flex; align-items: baseline; gap: 6px; min-width: 0; }
.bk-tzrow__c { flex: 0 0 auto; }
.bk-tzrow__city { color: var(--bk-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bk-tzopt .bk-tz__g { flex: 0 0 auto; }
.bk-nw { white-space: nowrap; }

/* pills: a long list of short answers, small, white, wrapping (Matías, 9-oct: "que no ocupen mucho") */
.bk-chips.is-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.bk-chips.is-pills .bk-chip {
  width: auto; min-height: 34px; padding: 0 14px; border-radius: 999px; background: #fff; border-color: var(--bk-ctl-line);
  font-size: 14px; color: #4d544c; box-shadow: none;
}
.bk-chips.is-pills .bk-chip:hover:not(.is-on) { border-color: #cfc6b3; color: var(--bk-ink); }
.bk-chips.is-pills .bk-chip.is-on { background: var(--bk-forest); border-color: var(--bk-forest); color: #fff; box-shadow: none; }

/* "Something else" opens a small box right under the pills */
.bk-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.bk-field--inline { margin-top: -18px; }
.bk-field--inline input[type="text"] { max-width: 320px; height: 40px; }
