/* Lab testing section: lab home, tests and packages, choose a lab, sample collection, review, sample journey, reports.
 * Builds on booking.css (site chrome, app bar, ticket, choices, ctabar). */

/* ------------------------------------------------------------- Shared bits */
.ptag { gap: 6px; }
.ptag .icon { width: 15px; height: 15px; flex: none; }
.ptag--gold { background: var(--gold-tint); color: var(--gold-ink); }
.ptag--green .icon { color: var(--green); }
.lt-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.lab-card { padding: clamp(20px, 2.4vw, 26px); border-radius: 24px; }
.lab-card + .lab-card { margin-top: 16px; }
.lab-card__title { font-size: 20px; letter-spacing: -0.01em; margin-bottom: 14px; }
.lab-lead { font-size: 17.5px; line-height: 1.55; color: var(--ink-2); margin-bottom: 14px; max-width: 64ch; }
.lab .bk-tiles + .lab-card, .lab .lt-tags + .bk-tiles { margin-top: 18px; }
.lab .bk-tiles + .lab-card { margin-top: 22px; }
.lab .legal-note { margin-top: 20px; }
.lab-chips { margin: 16px 0 4px; }
.lab-chips .chip { height: 44px; padding: 0 16px; font-size: 15.5px; }
.chip--x { height: 32px; padding: 0 10px 0 12px; gap: 4px; font-size: 14px; margin-left: 8px; vertical-align: middle; }
.chip--x .icon { width: 15px; height: 15px; }
.chip--radio { position: relative; cursor: pointer; }
.chip--radio input { position: absolute; opacity: 0; pointer-events: none; }
.chip--radio:has(input:checked) { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.chip--radio:has(input:focus-visible) { box-shadow: var(--focus); }
.lab-filters .fieldset + .fieldset { margin-top: 18px; }
.lab-filters .chips { margin: 0; padding: 0; }
.lab-filters .btn { margin-top: 22px; }
.ctabar__from { font-size: 13.5px; font-weight: 500; color: var(--muted); letter-spacing: 0; margin-right: 2px; }
.ctabar__price--name { min-width: 0; flex: 0 1 auto; max-width: 46%; }
.ctabar__price--name b { font-size: 19px; letter-spacing: -0.01em; line-height: 1.25; }
.ctabar__price--name + .btn { flex: 1 1 auto; padding-inline: 18px; }
.price__from { color: var(--muted); font-size: 13px; font-weight: 500; }

/* ------------------------------------------------------------- Lab home */
.lab-rx { margin-top: 16px; }
.lab-rx .next-appt__text b { font-size: 19px; }
.lab .bk-top + .lab-rx { margin-top: 16px; }
/* ------------------------------------------------------------- Test cards */
.lt-list { display: grid; gap: 16px; }
.lt-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 22px 20px 20px; background: #fff; border: 1px solid var(--line); border-radius: 24px; }
.lt-card__main { display: grid; gap: 10px; min-width: 0; }
.lt-card__name { font-size: 19.5px; letter-spacing: -0.01em; line-height: 1.3; }
.lt-card__name a:hover { color: var(--brand-dark); }
.lt-card__sub { color: var(--muted); font-size: 15.5px; line-height: 1.4; overflow-wrap: anywhere; }
.lt-price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; margin-top: 4px; }
.lt-price b { font-size: 23px; letter-spacing: -0.02em; }
.lt-price s { color: var(--muted); font-size: 15px; }
.lt-price small { color: var(--muted); font-size: 13.5px; }
.lt-price--lg b { font-size: 32px; }
.lt-add { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 104px; height: 48px; padding: 0 18px; border-radius: var(--pill); border: 1.5px solid var(--brand); background: #fff; color: var(--brand-dark); font-weight: 700; font-size: 16.5px; transition: background-color 0.15s, border-color 0.15s, color 0.15s; }
.lt-add .icon { width: 19px; height: 19px; stroke-width: 2.4; }
.lt-add:hover { background: var(--brand-tint); }
.lt-add.is-on { border-color: var(--green); background: var(--green-tint); color: var(--green); }
.lt-add:focus-visible { box-shadow: var(--focus); }
@media (min-width: 769px) and (max-width: 1024px) { .lt-list--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1025px) { .lt-list--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 380px) {
  .lt-card { grid-template-columns: 1fr; }
  .lt-card__cta { justify-self: start; }
}

/* Tests and packages */
.lab-search { display: grid; gap: 8px; }
.lab-search .field__label { font-size: 17px; font-weight: 700; color: var(--ink); }
.lab-search__input { height: 60px; border-radius: 18px; font-size: 17px; padding-inline: 18px; }
.lab-basket { padding: 22px; border-radius: 24px; display: grid; gap: 14px; }
.lab-basket__title { font-size: 19px; }
.lab-basket ul { display: grid; }
.lab-basket li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line-2); }
.lab-basket li > span { display: grid; gap: 2px; min-width: 0; }
.lab-basket li small { color: var(--muted); font-size: 14px; }
.lab-basket__total { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; color: var(--muted); }
.lab-basket__total b { color: var(--ink); font-size: 22px; }
.lab-basket__total small { font-size: 13px; color: var(--muted); font-weight: 500; }

/* Test page */
.lab-measures > div { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; }
.lab-measures > div + div { border-top: 1px solid var(--line-2); }
.lab-measures dt { color: var(--ink-2); font-size: 16.5px; flex: none; }
.lab-measures dd { font-weight: 700; text-align: right; font-size: 16.5px; overflow-wrap: anywhere; }
.lab-measures--list { display: grid; gap: 10px; margin-bottom: 12px; }
.lab-measures--list li { display: flex; gap: 10px; align-items: flex-start; font-size: 16.5px; }
.lab-measures--list .icon { width: 18px; height: 18px; color: var(--green); margin-top: 3px; flex: none; }
.lab-buy { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 22px; border-radius: 24px; }
.lab-buy .btn { flex: 1 1 auto; max-width: 260px; }

/* ------------------------------------------------------------- Choose a lab */
.lab-sum { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 20px 22px; border-radius: 22px; background: var(--surface-2); border-color: transparent; font-size: 17px; }
.lab-sum > span { min-width: 0; line-height: 1.4; }
.lab-sum small { display: block; color: var(--muted); font-size: 15px; margin-top: 2px; }
.lab-sum .link-btn { flex: none; font-weight: 700; }
.lab-opts { display: grid; gap: 14px; margin-top: 16px; }
.lab-opt { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: start; padding: 22px; background: #fff; border: 1px solid var(--line); border-radius: 24px; cursor: pointer; transition: border-color 0.15s, background-color 0.15s; }
.lab-opt input { position: absolute; opacity: 0; pointer-events: none; }
.lab-opt:hover { border-color: #d6c8bb; }
.lab-opt:has(input:checked) { border: 2px solid var(--brand); background: var(--brand-tint); padding: 21px; }
.lab-opt:has(input:focus-visible) { box-shadow: var(--focus); }
.lab-opt.is-off { opacity: 0.6; cursor: not-allowed; }
.lab-opt--static { cursor: default; }
.lab-opt__info { display: grid; gap: 8px; min-width: 0; }
.lab-opt__name { font-size: 19px; letter-spacing: -0.01em; }
.lab-opt__meta { color: var(--muted); font-size: 15.5px; line-height: 1.45; }
.lab-opt__missing { display: flex; gap: 6px; align-items: flex-start; color: var(--muted); font-size: 14px; }
.lab-opt__missing .icon { width: 16px; height: 16px; margin-top: 2px; flex: none; }
.lab-opt__price { display: grid; justify-items: end; text-align: right; line-height: 1.2; }
.lab-opt__price b { font-size: 24px; letter-spacing: -0.02em; }
.lab-opt__price small { color: var(--muted); font-size: 14px; }
.lab-av { width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; flex: none; background: #e7f0eb; color: #24563c; font-weight: 800; font-size: 20px; letter-spacing: 0.02em; }
.lab-av--sm { width: 52px; height: 52px; border-radius: 15px; font-size: 17px; }
.lab-pick { padding: 22px 24px; border-radius: 24px; }
.lab-pick .lab-card__title { margin-bottom: 12px; }
.lab-pick .sum-rows { font-size: 16px; gap: 12px; }
@media (max-width: 480px) {
  .lab-opt { gap: 12px; padding: 18px 16px; }
  .lab-opt:has(input:checked) { padding: 17px 15px; }
  .lab-av { width: 48px; height: 48px; border-radius: 14px; font-size: 16px; }
  .lab-opt__price b { font-size: 20px; }
  .lab-opt__price small { font-size: 13px; }
  .lab-sum { align-items: flex-start; }
}

/* ------------------------------------------------------------- Sample collection */
.lab-addr { display: flex; align-items: center; gap: 16px; padding: 20px; border-radius: 24px; }
.lab-addr .next-appt__icon { width: 56px; height: 56px; }
.lab-addr .next-appt__icon .icon { width: 24px; height: 24px; }
.lab-addr__text { flex: 1; display: grid; gap: 2px; min-width: 0; line-height: 1.45; }
.lab-addr__text b { font-size: 18px; }
.lab-addr__text span, .lab-addr__text small { color: var(--muted); font-size: 15.5px; overflow-wrap: anywhere; }
.lab-addr .link-btn { flex: none; font-weight: 700; align-self: flex-start; }
.lab-note { margin-top: 16px; }
.lab-windows { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* Sample slip: the visit ticket in green */
.ticket--lab .tk__head { background: #e7f0eb; }
.ticket--lab .tk__kind { color: #24563c; }
.ticket--lab .tk__status--draft { color: #24563c; }

/* ------------------------------------------------------------- Booked: sample journey */
.bk-done--muted .bk-done__icon { background: var(--surface-2); color: var(--muted); }
.journey { display: grid; }
.journey__step { position: relative; display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 16px; padding-bottom: 22px; }
.journey__step:last-child { padding-bottom: 0; }
.journey__step:not(:last-child)::before { content: ''; position: absolute; left: 25px; top: 54px; bottom: 2px; width: 3px; border-radius: 3px; background: var(--line); }
.journey__step.is-done:not(:last-child)::before { background: var(--green); }
.journey__dot { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--muted); border: 1.5px solid var(--line); }
.journey__dot .icon { width: 22px; height: 22px; }
.journey__step.is-done .journey__dot { background: var(--green); border-color: var(--green); color: #fff; }
.journey__step.is-done .journey__dot .icon { stroke-width: 3; }
.journey__step.is-now .journey__dot { background: var(--gold-tint); border: 2px solid var(--gold); color: var(--gold-ink); box-shadow: 0 0 0 6px rgba(184, 137, 66, 0.12); }
.journey__text { display: grid; gap: 4px; padding-top: 4px; min-width: 0; }
.journey__text b { font-size: 18px; letter-spacing: -0.01em; }
.journey__text span { color: var(--muted); font-size: 15.5px; line-height: 1.5; }
.journey__step.is-todo .journey__text b { color: var(--ink-2); font-weight: 600; }
.lab-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* ------------------------------------------------------------- Reports */
.lab-rows { display: grid; gap: 14px; }
.lab-rows--progress { margin-top: 18px; }
.lab-reports { margin-top: 28px; }
.lab-reports .section__title { margin-bottom: 14px; }
.lab-reports .demo-note { margin-bottom: 14px; }
.lab-row { display: flex; align-items: center; gap: 18px; padding: 20px 22px; border-radius: 24px; transition: border-color 0.15s, box-shadow 0.15s; }
.lab-row:hover { border-color: #dccfc2; box-shadow: var(--shadow); }
.lab-row__icon { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--brand-tint); color: var(--brand); }
.lab-row__icon .icon { width: 26px; height: 26px; }
.lab-row__text { flex: 1; display: grid; gap: 6px; justify-items: start; min-width: 0; }
.lab-row__text b { font-size: 19px; letter-spacing: -0.01em; line-height: 1.3; }
.lab-row__text > span:not(.ptag) { color: var(--muted); font-size: 15.5px; line-height: 1.45; }
.lab-row__text .ptag { white-space: normal; border-radius: 12px; }
.lab-row__chev { width: 22px; height: 22px; color: var(--muted); flex: none; }
.lab-desk-cta { margin-top: 28px; }
@media (min-width: 1025px) { .lab-rows { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; } }

/* One report */
.lab-sample-banner { margin-bottom: 16px; }
.lab-summary { display: flex; align-items: center; gap: 18px; padding: 22px; border-radius: 24px; }
.lab-summary > span:last-child { display: grid; gap: 4px; min-width: 0; }
.lab-summary b { font-size: 21px; line-height: 1.3; letter-spacing: -0.01em; }
.lab-summary > span:last-child > span { color: var(--muted); font-size: 15px; line-height: 1.5; }
.lab-summary__icon { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--green-tint); color: var(--green); }
.lab-summary__icon .icon { width: 30px; height: 30px; stroke-width: 2.6; }
.lab-summary.is-out .lab-summary__icon { background: var(--gold-tint); color: var(--gold-ink); }
.lab-vals { display: grid; gap: 14px; margin-top: 16px; }
.lab-val { padding: 22px; border-radius: 24px; }
.lab-val__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; }
.lab-val__head > span:first-child { display: grid; gap: 4px; min-width: 0; }
.lab-val__code { font-size: 20px; }
.lab-val__name { color: var(--ink-2); font-size: 16px; }
.lab-val__value { white-space: nowrap; }
.lab-val__value b { font-size: 30px; letter-spacing: -0.02em; }
.lab-val__value small { color: var(--ink-2); font-size: 15px; }
.lab-val.is-out .lab-val__value b { color: var(--gold-ink); }
.lab-bar { position: relative; height: 14px; margin: 20px 0 10px; border-radius: var(--pill); background: var(--surface-2); }
.lab-bar__band { position: absolute; left: 25%; width: 50%; top: 0; bottom: 0; background: var(--green-tint); }
.lab-bar__dot { position: absolute; top: 50%; width: 24px; height: 24px; border-radius: 50%; transform: translate(-50%, -50%); background: var(--green); border: 3px solid #fff; box-shadow: 0 0 0 2px var(--green); }
.lab-val.is-out .lab-bar__dot { background: var(--gold); box-shadow: 0 0 0 2px var(--gold); }
.lab-bar__labels { display: flex; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 14.5px; }
.lab-bar__flag { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 6px; color: var(--gold-ink); font-weight: 700; font-size: 14.5px; }
.lab-bar__flag .icon { width: 16px; height: 16px; }
.lab-val__prev { color: var(--ink-2); margin-top: 10px; font-size: 15.5px; }
.lab-about { display: grid; gap: 14px; }
.lab-about .lab-card__title { margin-bottom: 0; }
.lab-about__rows > div { display: flex; justify-content: space-between; gap: 14px; padding: 9px 0; border-top: 1px solid var(--line-2); font-size: 15px; }
.lab-about__rows dt { color: var(--muted); }
.lab-about__rows dd { font-weight: 600; text-align: right; overflow-wrap: anywhere; }

/* Malayalam: longer words in buttons and tags */
.lab :lang(ml) .lt-add, .lab .lt-add:lang(ml) { font-size: 15px; padding-inline: 14px; }
:lang(ml) .lab-concerns .spec__name { font-size: 12.5px; }
/* Eight concerns in a 4-up or 8-up grid; Malayalam phones get 3 columns (longer words) and all nine. */
.lab-concerns .spec:nth-child(9) { display: none; }
@media (max-width: 768px) {
  :lang(ml) .lab-concerns { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  :lang(ml) .lab-concerns .spec:nth-child(9) { display: flex; }
}
/* Full-width buttons can wrap (Malayalam labels are long). */
.lab .btn--block { white-space: normal; line-height: 1.3; padding-block: 8px; }

/* ------------------------------------------------------------- Revised designs */
/* Test cards with the price and Add button on one bottom row (lab home). */
.lt-card--foot { grid-template-columns: 1fr; }
.lt-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.lt-card__foot .lt-price { margin-top: 0; }

/* Health packages with photos */
.lt-pkgs { display: grid; gap: 16px; }
.lt-pkg { display: grid; padding: 0; overflow: hidden; border-radius: 24px; transition: border-color 0.15s, box-shadow 0.15s; }
.lt-pkg:hover { border-color: #dccfc2; box-shadow: var(--shadow); }
.lt-pkg__img { display: block; width: 100%; height: auto; aspect-ratio: 760 / 409; object-fit: cover; background: var(--surface-2); }
.lt-pkg__body { display: grid; gap: 10px; padding: 20px 22px 22px; }
.lt-pkg__name { font-size: 19.5px; letter-spacing: -0.01em; }
.lt-pkg .lt-price { margin-top: 2px; }
@media (min-width: 769px) and (max-width: 1024px) { .lt-pkgs { grid-template-columns: repeat(3, minmax(0, 1fr)); } .lab-opts--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1025px) { .lt-pkgs, .lab-opts--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.lab-opts--3 { margin-top: 0; }

/* Test page: labs that do this test */
.lab-at { margin-top: 18px; }
.lab-at li { display: flex; align-items: center; gap: 14px; padding: 12px 0; }
.lab-at li + li { border-top: 1px solid var(--line-2); }
.lab-at li > span:not(.lab-av) { flex: 1; display: grid; gap: 2px; min-width: 0; }
.lab-at li b { font-size: 17.5px; }
.lab-at li small { color: var(--muted); font-size: 14.5px; line-height: 1.4; }
.lab-at .lab-av { width: 56px; height: 56px; border-radius: 16px; font-size: 18px; }
.lab-at__price { font-size: 20px !important; flex: none; }

/* Booked: booking number on the slip, actions */
.ticket--lab .tk__num { color: #24563c; }
.lab-code .tk__tokentext > span { line-height: 1.45; }
.lab-actions { display: grid; gap: 14px; justify-items: start; }
.lab-actions__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; width: 100%; }
.lab-actions__grid .btn { --h: 52px; padding-inline: 12px; gap: 6px; white-space: normal; line-height: 1.25; }
.lab-cancel { font-weight: 700; }
.lab-sum--change { margin-bottom: 4px; }

/* Reports: privacy note */
.lab-private { margin-top: 22px; background: var(--surface-2); }
.lab-private .icon { color: var(--muted); }
@media (max-width: 480px) {
  .lab-chips { gap: 6px; }
  .lab-chips .chip { padding: 0 12px; font-size: 15px; }
  .lab-at .lab-av { width: 48px; height: 48px; border-radius: 14px; font-size: 16px; }
}

/* ------------------------------------------------------------- Desktop designs */
@media (min-width: 1025px) {
  .lt-list--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lab-listlayout .lab-search { margin-bottom: 18px; }
  .lab-rows--progress { grid-template-columns: 1fr; }
  .lab-actions__grid { grid-template-columns: 1fr; }
  .lab-actions__grid .btn { --h: 56px; font-size: 16px; }
  .lab-actions { gap: 16px; }
  .lab-at .lab-av { width: 52px; height: 52px; border-radius: 15px; font-size: 17px; }
  .lab-listlayout .bk-filters legend { margin-top: 2px; }
}
/* Basket bar under the list (desktop) */
.lab-inline-basket { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 18px; padding: 18px 22px; border-radius: 22px; }
.lab-inline-basket__text { display: grid; gap: 2px; min-width: 0; }
.lab-inline-basket__text b { font-size: 24px; letter-spacing: -0.02em; }
.lab-inline-basket__text small { color: var(--muted); font-size: 15px; }
@media (min-width: 1025px) {
  /* Three tags fit on one line in the three-across cards */
  .lt-card--foot .lt-tags { gap: 6px; }
  .lt-card--foot .ptag { padding-inline: 8px; font-size: 12.5px; }
}
