/* Shared finishing rules. Full-bleed scenes and the diagnostics assembly keep
   their own geometry; ordinary content uses one frame and one type hierarchy. */
:root {
  --yl-content: 1200px;
  --yl-edge: 24px;
  --yl-inset: max(24px, calc((100vw - 1200px) / 2));
  --yl-section: 96px;
  --yl-group: 48px;
  --yl-body: 16px;
  --finish-heading: clamp(40px, 4.4vw, 64px);
  --finish-dark-muted: #bcb8b0;
  --finish-light-muted: #56544f;
}

/* Do not apply a second inset inside an already padded Care section. */
#care.cf { padding: var(--yl-section) 0 calc(var(--yl-section) / 2) !important; }
#care .cf-wrap, #programs .pg-wrap {
  width: 100% !important;
  max-width: none !important;
  margin-inline: 0 !important;
  padding-inline: var(--yl-inset) !important;
}
#programs.pg { padding-block: calc(var(--yl-section) / 2) var(--yl-section); }
#myhealth { padding: var(--yl-section) var(--yl-inset); }
#myhealth .mh-connected { max-width: 1200px; margin-inline: auto; }
#about { padding: var(--yl-section) var(--yl-inset) calc(var(--yl-section) / 2); }
#arriving { padding: calc(var(--yl-section) / 2) var(--yl-inset); }
#faq { padding: calc(var(--yl-section) / 2) var(--yl-inset) var(--yl-section); }
#footer { padding: var(--yl-section) var(--yl-inset) max(32px, env(safe-area-inset-bottom)); }
#arriving .ar-wrap { max-width: 1200px; }

/* The earlier journey font shorthand omitted its font family. A valid shared
   shorthand prevents the individual sections falling back to different sizes. */
#care .cf-h, #programs .pg-h, #myhealth .mh-h,
#about h2, #arriving .ar-h, #faq .faq-h, #centre .ct-h {
  font: 300 var(--finish-heading)/1.08 var(--f-display) !important;
  letter-spacing: -.04em !important;
  text-wrap: balance;
}
#care .cf-head, #programs .pg-head { max-width: 760px; }
#care .cf-intro, #programs .pg-intro, #myhealth .mh-lead, #centre .ct-lead {
  font: 400 18px/1.65 var(--f-text);
  text-wrap: pretty;
}
#care .cf-intro, #programs .pg-intro { color: var(--finish-light-muted); }
#care .cf-list, #programs .pg-list { margin-top: var(--yl-group); }
#care .cf-t { font-size: 28px; line-height: 1.16; }
#care .cf-d { min-height: 3.2em; font-size: 16px; line-height: 1.6; color: #d2cec7; }
#care .cf-chips { gap: 8px; }
#care .cf-chip {
  min-height: 44px;
  height: auto;
  max-width: 100%;
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.4;
  text-align: left;
  white-space: normal;
  background: rgba(14,14,15,.78);
  border-color: rgba(233,228,218,.32);
}
#care .cf-register { min-height: 48px; }

/* Repeated card headings and copy start on the same rows. */
#programs .pg-card {
  display: grid;
  grid-template-rows: 44px minmax(2.3em, auto) 1fr;
  align-content: start;
  gap: 20px;
  min-width: 0;
  padding: 32px 24px;
}
#programs .pg-t {
  margin-top: 0 !important;
  padding-top: 12px;
  font: 400 28px/1.16 var(--f-display);
  letter-spacing: -.025em;
}
#programs .pg-d { margin-top: 0 !important; font-size: 16px; line-height: 1.65; color: var(--finish-light-muted); }
#programs .pg-note { color: var(--finish-light-muted); line-height: 1.6; }
#myhealth .mh-connected { gap: 40px 56px; padding-top: 32px; }
#myhealth .mh-connected p { font-size: 16px; line-height: 1.7; }
#myhealth :is(.mh-lead,.mh-cd,.mh-connected p,.mh-note) { color: var(--finish-dark-muted); }
#myhealth .mh-ct { font-size: 28px; line-height: 1.2; }
#myhealth .mh-cd { font-size: 16px; line-height: 1.65; }
#about .yl-about-grid { gap: 24px; }
#about article { grid-row: span 3; grid-template-rows: subgrid; }
#about article > p:last-child { font-size: 16px; line-height: 1.7; color: var(--finish-light-muted); }
#arriving .ar-t { font-size: 28px; font-weight: 400; line-height: 1.2; }
#arriving .ar-d { color: var(--finish-light-muted); }
#footer :is(.ft-group,.ft-nav a,address,.ft-policy-links a,.ft-copy) { color: var(--finish-light-muted); }
#footer .ft-nav a { font-size: 16px; line-height: 1.5; min-height: 44px; }
#footer address { font-size: 16px; line-height: 1.65; }
#footer .ft-policy-links a, #footer .ft-copy { font-size: 14px; }
#footer .ft-ch { color: var(--void); font-weight: 600; font-size: 16px; }
#quiet-story.da #beyond :is(.bh-d,.bh-note) { color: var(--finish-dark-muted); }

/* Match the secondary page to the homepage content edges. */
.yl-detail-page .dd-wrap { width: min(1200px, calc(100% - 48px)); }
.yl-detail-page .yl-site-header { max-width: none; padding-inline: var(--yl-inset); gap: 24px; }
.yl-detail-page .yl-primary-nav { gap: clamp(12px, 1.2vw, 20px); }
.yl-detail-page .yl-header-logo { width: 168px; }
.yl-detail-page .yl-primary-nav a { font-size: 13px; }
.yl-detail-page .yl-header-register { font-size: 13px; }
.yl-detail-page .dd-kicker { font-size: 12px; line-height: 1.5; letter-spacing: .04em; text-transform: none; }
.yl-detail-page .dd-hero-grid { gap: 56px; }
.yl-detail-page .dd-lead { font-size: 18px; color: var(--finish-dark-muted); }
.yl-detail-page .dd-section-head>p:last-child,
.yl-detail-page .dd-pathway-summary, .yl-detail-page .dd-difference li,
.yl-detail-page .dd-addon-copy>p:first-child,
.yl-detail-page .dd-next p:not(.dd-kicker) { font-size: 16px; line-height: 1.7; color: var(--finish-dark-muted); }
.yl-detail-page .dd-facts dd, .yl-detail-page .dd-price small,
.yl-detail-page .dd-note, .yl-detail-page .dd-brief-note,
.yl-detail-page .dd-focus, .yl-detail-page .dd-footer>p,
.yl-detail-page .dd-footer>div { font-size: 14px; line-height: 1.6; color: var(--finish-dark-muted); }
.yl-detail-page .dd-nav a { font-size: 14px; }
.yl-detail-page .dd-nav > .dd-wrap { width: 100%; padding-inline: var(--yl-inset); }
.yl-detail-page .dd-text-button { min-height: 44px; font-size: 14px; }
.yl-detail-page .dd-button { font-size: 14px; }
.yl-detail-page .dd-addon-title h3 { overflow-wrap: break-word; }
.yl-detail-page .dd-breadcrumb { display: inline-flex; align-items: center; min-height: 44px; font-size: 14px; }
.yl-detail-page .dd-price s { color: #bcb8b0; }
.yl-detail-page #diagnostic-addons .dd-addon-copy>p:first-child,
.yl-detail-page #diagnostic-addons .dd-section-head>p:last-child,
.yl-detail-page #stations .dd-station-overview,
.yl-detail-page #stations .dd-covered-grid dd { font-size: 16px; line-height: 1.7; color: var(--finish-dark-muted); }
.yl-detail-page #stations .dd-covered-grid dt { font-size: 16px; }
.yl-detail-page #stations .dd-brief-note,
.yl-detail-page #stations .dd-assessment-guidance { font-size: 14px; line-height: 1.65; color: var(--finish-dark-muted); }
.yl-detail-page #stations .ht-tabs button { font-size: 14px; }
.yl-detail-page .dd-station-nav a { min-height: 44px; font-size: 13px; color: var(--finish-dark-muted); }
.yl-detail-page .dd-station-nav a[aria-selected=true] { color: var(--void); }
.yl-detail-page .dd-station-controls>p { font-size: 14px; color: var(--finish-dark-muted); }
.yl-detail-page .dd-station-controls button { width: 44px; height: 44px; }
.dd-tour-toggle svg { display: block; width: 18px; height: 18px; margin: auto; }

/* Readable forms avoid Safari zooming into small text inputs. */
.reg input:not([type=checkbox]):not([type=radio]), .reg select, .reg textarea,
.enq input:not([type=checkbox]):not([type=radio]), .enq select, .enq textarea { font-size: 16px !important; }
.reg .field label, .reg .enq-set legend { font-size: 14px; }
.reg .check label, .reg .enq-chip span { font-size: 13px; line-height: 1.55; }
.care-detail-description { font-size: 16px; }
.care-detail-includes li { font-size: 15px; line-height: 1.6; }
.care-detail-note { font-size: 14px; color: var(--finish-dark-muted); }

/* The journey stays compact while providing a comfortable touch target. */
.yl-journey { max-width: calc(100% - 24px); background: rgba(14,14,15,.86); visibility: hidden; transition: opacity .35s ease, transform .5s ease, visibility .35s; }
.yl-journey.is-on { visibility: visible; }
.yl-journey a { min-height: 44px; height: auto; font-size: 14px; color: #e0dbd2; }
.yl-journey a i { font-size: 12px; color: #c9c4ba; }
.yl-journey a[aria-current="step"] i { color: #56544f; }
.yl-skip {
  position: fixed; top: 12px; left: 12px; z-index: 10000;
  transform: translateY(-200%); padding: 14px 20px; border-radius: 12px;
  background: var(--gold); color: var(--void); font: 500 16px/1.4 var(--f-text);
}
.yl-skip:focus { transform: none; }
#programs :focus-visible, #about :focus-visible, #arriving :focus-visible, #faq :focus-visible, #footer :focus-visible { outline-color: var(--void); }

/* Legal reading columns stay narrow; their navigation shares the page frame. */
body:has(.legal-header), body:has(.confirmation) { --edge: var(--yl-inset); }
body:has(.legal-header) { font-size: 16px; }
.legal-header { gap: 16px; }
.legal-header .back { font-size: 14px; }
.legal-footer, .updated { font-size: 14px; color: #bcb8b0; }
body:has(.confirmation) main { padding-inline: var(--yl-inset); }
body:has(.confirmation) footer { font-size: 14px; color: #d1ccc3; }

@media (max-width: 1240px) {
  .yl-detail-page .yl-site-header { gap: 0 20px; }
  .yl-detail-page .yl-primary-nav { gap: 24px; }
}
@media (max-width: 1023px) {
  #care .cf-list { grid-template-columns: 1fr !important; }
  #care .cf-tile, #care .cf-tile:first-child {
    width: 100% !important; max-width: 560px !important;
    margin-inline: auto !important; min-height: 540px !important; aspect-ratio: auto !important;
  }
  #about article { grid-row: auto; grid-template-rows: auto auto auto; }
  .yl-detail-page .dd-hero-grid { gap: 32px; }
}
@media (max-width: 759px) {
  :root { --yl-section: 72px; --yl-group: 32px; --finish-heading: 40px; }
  #care .cf-intro, #programs .pg-intro, #myhealth .mh-lead, #centre .ct-lead { font-size: 16px; }
  #care .cf-t { font-size: 26px; }
  #care .cf-body { padding: 24px; }
  #care .cf-tile, #care .cf-tile:first-child { min-height: 540px !important; }
  #programs .pg-card { grid-template-rows: 40px auto 1fr; padding: 24px; gap: 20px; }
  #programs .pg-t { padding-top: 0; font-size: 26px; }
  #programs .pg-foot { gap: 24px; }
  #centre { padding-top: 72px; }
  html #centre .ct-inner { padding-inline: var(--yl-inset); padding-bottom: 24px; }
  #myhealth .mh-connected { gap: 32px; }
  #myhealth .mh-connected article { padding-left: 0; }
  #myhealth .mh-connected-mark { position: static; margin-bottom: 12px; font-size: 12px; }
  #myhealth .mh-connected h3 { font-size: 25px; }
  #myhealth .mh-ct { font-size: 26px; }
  #about h2 { margin-bottom: 32px; }
  #arriving .ar-t { font-size: 26px; }
  #footer .ft-main { gap: 40px; }
  #footer .ft-cols { gap: 28px; }
  #footer .ft-bottom { gap: 16px; }
  .yl-journey a { padding-inline: 10px; gap: 6px; font-size: 13px; }
  .yl-detail-page .yl-primary-nav { margin-inline: -24px; padding-inline: 24px; }
  .yl-detail-page .yl-header-logo { width: 144px; }
  .yl-detail-page .yl-header-register { font-size: 12px; padding-inline: 12px; min-height: 44px; }
  .yl-detail-page .dd-hero-grid { gap: 24px; }
  .yl-detail-page .dd-lead { font-size: 16px; }
  .yl-detail-page .dd-facts { gap: 24px 16px; }
  .yl-detail-page .dd-facts dt { font-size: 24px; }
  .yl-detail-page .dd-pathway { padding: 24px; }
  .yl-detail-page .dd-pathway-top { flex-wrap: wrap; gap: 8px; }
  .yl-detail-page .dd-pathway-top .dd-kicker, .yl-detail-page .dd-selected { font-size: 12px; }
  .yl-detail-page .dd-addon-copy { padding-left: 0; }
  .yl-detail-page .dd-addon-title { padding-left: 32px; }
}
@media (max-width: 374px) {
  :root { --finish-heading: 36px; }
  #care .cf-body { padding-inline: 20px; }
  .yl-detail-page .yl-header-logo { width: 112px; }
  .yl-detail-page .yl-header-register { font-size: 11px; padding-inline: 10px; }
}
@media (prefers-reduced-motion: no-preference) {
  html.js .pg [data-pg], html.js .ar [data-ar] { transition-duration: .65s, .8s; }
}
@media (forced-colors: active) {
  .yl-skip, #care .cf-chip, .yl-journey { border: 1px solid ButtonText; }
}
