/* Inbox Field Guide homepage (tasteskill build, version B).
   1. the :root block exactly as start.mjs css printed it (palette green-black-bone, type geist);
   2. the dealt faces, self-hosted (the production CSP allows no remote font);
   3. page CSS only where the kit says page CSS: inside a visual, one --p-h per card group, the fragments'
      placement (written here, not in style="" attributes, which the CSP blocks), and the client's mark. */

.ly-mark-ifg { display: inline-block; width: .78em; height: .78em; vertical-align: -.06em; margin-right: .06em; }
.ui-win__crumb > .ui-brand { width: 14px; height: 14px; }
.icon { width: 16px; height: 16px; flex: none; }

/* ---------------------------------------------------------------- hero: the diagnostic as one window (layout-v4.md, centred) */
.d-win { border-radius: 12px; overflow: hidden; font: 400 14px/1.4 var(--font-text); text-align: left; }
.d-win--dark { background: #121715; color: #e3e2da; box-shadow: 0 0 0 1px rgb(255 255 255 / .08), 0 30px 70px -30px rgb(0 0 0 / .8); }
.d-win__bar { display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 14px; border-bottom: 1px solid rgb(255 255 255 / .07); font-size: 13px; color: #a3a9a2; }
.d-win__bar b { color: #e3e2da; font-weight: 500; }
.d-win__bar .sp { flex: 1; }
.d-win__dots { display: flex; gap: 6px; } .d-win__dots i { width: 10px; height: 10px; border-radius: 50%; background: #3a423f; }
.d-win__body { display: grid; grid-template-columns: 250px 1fr; min-height: 420px; }
.inbox { border-right: 1px solid rgb(255 255 255 / .07); padding: 10px; display: grid; align-content: start; gap: 2px; }
.inbox .t { display: grid; grid-template-columns: 30px 1fr; gap: 1px 10px; padding: 9px 8px; border-radius: 8px; font-size: 13px; }
.inbox .t.is-on { background: rgb(255 255 255 / .07); }
.inbox .t i { grid-row: 1 / span 2; width: 30px; height: 30px; border-radius: 6px; display: grid; place-items: center; font: 500 12px/1 var(--font-mono); font-style: normal; color: #161c1a; background: #cdd6c6; }
.inbox .t b { font-weight: 500; color: #e3e2da; }
.inbox .t span { grid-column: 2; color: #a3a9a2; }
.convo { display: grid; min-width: 0; align-content: start; }
.d-chat { display: grid; gap: 8px; align-content: start; padding: 14px 18px; font-size: 14px; }
.d-msg { max-width: 86%; padding: 10px 14px; border-radius: 12px; line-height: 1.45; }
.d-msg--me { justify-self: end; background: #e3e2da; color: #161c1a; border-bottom-right-radius: 4px; }
.d-msg--bot { background: #232b28; color: #e9ece8; border-bottom-left-radius: 4px; }
.d-msg small { display: inline; margin-left: 8px; font-size: 13px; color: #a3a9a2; white-space: nowrap; }
.d-tool { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #a3a9a2; }
.d-tool::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #9fc7b8; }
.acts { display: flex; gap: 8px; }
.acts span { height: 30px; padding: 0 12px; border-radius: 6px; display: inline-flex; align-items: center; font-size: 13px; font-weight: 500; background: #e3e2da; color: #161c1a; }
.acts span + span { background: rgb(255 255 255 / .08); color: #e9ece8; }
/* below 1024 the window keeps its exchange alone (the answers column is the desktop's context) */
@media (max-width: 1023px) { .d-win__body { grid-template-columns: 1fr; } .inbox { display: none; } }
/* the hero's grey line at the ink's 7:1: the palette's muted reads 5.6:1 on the ground, under the bar for text people read */
.hero--centred .hero__lead { color: color-mix(in oklab, var(--ink) 86%, var(--bg)); }
@media (max-width: 639px) {
  .d-win__bar .sp ~ span { display: none; }
  .d-chat { font-size: 13px; padding: 12px 14px; }
  .d-msg small, .d-tool { display: none; }
}

/* ---------------------------------------------------------------- #guides: the app frame (sections-library.md, app-frame, the whole recipe) */
.app.ui { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); margin-top: var(--s-7); background: var(--u-bg); border: 1px solid var(--u-border); border-radius: var(--u-r); box-shadow: var(--u-shadow); }
.app > .app__pane { position: relative; min-width: 0; min-height: 0; overflow: hidden; }
.app > .app__pane + .app__pane { border-left: 1px solid var(--u-line); }
.app > .app__pane > .ui-panel { width: 100%; border: 0; border-radius: 0; box-shadow: none; }
.app > .app__pane::after { content: ""; position: absolute; inset: auto 0 0 0; height: 64px; background: linear-gradient(transparent, var(--u-bg)); pointer-events: none; }
@media (min-width: 1024px) and (max-width: 1279px) { .app.ui { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); } }
@media (max-width: 1023px) {
  .app.ui { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .app > .app__pane--list { max-height: 252px; }
  .app > .app__pane--list::after { display: none; }
  .app .ui-win__side { display: none; }
  .app .ui-win__body { grid-template-columns: minmax(0, 1fr); }
  .app > .app__pane + .app__pane { border-left: 0; border-top: 1px solid var(--u-line); }
}
@media (max-width: 639px) {
  .app.ui { grid-template-rows: minmax(0, 1fr); }
  .app > .app__pane--list { display: none; }
  .app > .app__pane + .app__pane { border-top: 0; }
}
#guides .app__pane--open > .ui-doc { width: 100%; }

/* ---------------------------------------------------------------- #symptoms: the 2x2 (one --p-h for the group; the fragments' places) */
#symptoms .panel { --p-h: 336px; }
#symptoms .c-junk .stage > .at-rise { --fit-max: 400px; --ax: max(24px, 50% - 200px); --ay: 56px; --ay-sm: 56px; }
#symptoms .c-bounce .stage > .at-rise { --fit-max: 340px; --ax: max(24px, 50% - 170px); --ay: 40px; --ay-sm: 32px; }
#symptoms .c-bounce .ui-checks__bar > i { --k: 0.4; }
#symptoms .c-restricted .stage > .at-rise { --fit-max: 400px; --ax: max(24px, 50% - 200px); --ay: 40px; --ay-sm: 24px; }
#symptoms .c-replies .stage > .at-rise { --fit-max: 380px; --ax: 32px; --ay: calc(100% - 180px); --ay-sm: calc(100% - 180px); }


/* ---------------------------------------------------------------- #routes: the split (text left, the hub diagram right) */
.route-facts { list-style: none; margin: var(--s-5) 0; padding: 0; display: grid; gap: var(--s-2); }
.route-facts li { padding-top: var(--s-2); border-top: 1px solid var(--line); }
#routes .frame--fill > .dg { position: absolute; inset: 0; }
/* a split whose picture runs down to the section's foot (.frame--fill): the frame's 5:4 is let go */
#routes .frame--fill { aspect-ratio: auto; }

/* ---------------------------------------------------------------- #tools: two cards and the marquee row */
#tools .panel { --p-h: 300px; }
#tools .stage > .at-corner { --ax: 32px; --ay: 32px; }
@media (min-width: 1024px) { #tools .c-headers .stage > .at-corner > .ui, #tools .c-handoff .stage > .at-corner > .ui { width: 460px; } }
#tools .result-row { margin-top: var(--s-6); }
#tools .result-row li { font-family: var(--font-mono); font-size: var(--t-body); }


/* ---------------------------------------------------------------- #placement: the labelled affiliate block and the drawing */
.ad-block { display: grid; gap: var(--s-3); margin-top: var(--s-3); }
.ad-block > .btn-row { margin-top: var(--s-2); align-items: center; gap: var(--s-5); }

/* ---------------------------------------------------------------- #statement (liquid-type) */
#statement .statement__line { margin-top: var(--s-6); max-width: 46ch; }
#statement .statement__line + p { margin-top: var(--s-5); }

/* ---------------------------------------------------------------- #faq on bg-band: the band keeps the section box (top-aligned, the system's padding) */
#faq.bg-band, #placement.bg-dots { padding-block: var(--padt) calc(var(--padb) + var(--bar, 0px)); align-content: start; }

/* ---------------------------------------------------------------- a phone */
@media (max-width: 639px) {
  /* the route list is the desktop's detail; the hub shows the routes */
  #placement { --hm: 2; }
  #routes .route-facts { display: none; }
  #routes .frame--fill { min-height: 300px; }
  /* the FAQ keeps one phone screen: one answer stays on the desktop (the funding line is also beside the Ad link above) */
  #faq .faq__item:nth-child(5) { display: none; }
  #guides .ui-doc__text:last-child, #symptoms .ui-search__foot { display: none; }
  .hero--centred .pill { width: 100%; justify-content: center; }
  #faq .t-lead { display: none; }
  /* the mocks' long lines wrap inside them at 342px */
}

/* ---------------------------------------------------------------- the two CSS grounds keep the system's section box at every width
   (backgrounds.css centres a grounded section and gives it a min-height of its own, which outranks system.css's box) */
@media (min-width: 640px) and (max-width: 1279px) {
  main > #placement.section, main > #faq.section { min-height: calc(var(--h, 1) * 100svh); display: flex; flex-direction: column; }
}
@media (max-width: 639px) {
  main > #placement.section, main > #faq.section { min-height: calc(var(--hm, var(--h, 1)) * 100lvh); display: grid; grid-template-rows: 1fr; align-content: stretch; }
  #symptoms .panel { --p-h: 168px; }
  #tools { --hm: 2; }
  #tools .panel { --p-h: 390px; }
}
/* a small laptop (1024x768): the 2x2 keeps its two screens */
@media (min-width: 1024px) and (max-width: 1279px) { #symptoms .panel { --p-h: 216px; } }

/* a tablet and a phone */
@media (max-width: 1023px) {
  /* the mocks' long lines wrap inside them */
  #tools .c-headers .ui-code__ln { white-space: pre-wrap; overflow-wrap: anywhere; }
  #symptoms .c-junk .ui-search__m { display: none; }
}
@media (min-width: 640px) and (max-width: 1023px) {
  /* the window narrower than the frame, so it reads as a window on the ground, never a band */
  .hero--centred .hero__window > .ly-piece { width: 76%; }
  #tools .panel { --p-h: calc(73.7svh - 400px); }
  #tools .stage > .at-corner { right: 24px; }
  #tools .stage > .at-corner > .ui { width: 100%; }
  #tools .c-handoff .ui-doc__note { display: none; }
  #symptoms .c-junk .ui-search__t { white-space: normal; }
  .faq > .faq__item { padding-block: calc(5.1svh - 28px); }
  /* the 2x2's second screen holds no heading: its two panels take the room the heading takes on the first */
  #symptoms .wrap > .grid:last-child .panel { --p-h: calc(119svh - 678px); }
}

/* ---------------------------------------------------------------- #placement: the vendor's report, shown as theirs (the site's caption rule outranks the kit's no-caption rule) */
.placement-shot { display: grid; gap: var(--s-3); align-content: center; margin: 0; }
.placement-win { border-radius: 12px; overflow: hidden; background: #121715; box-shadow: 0 0 0 1px rgb(255 255 255 / .08), 0 30px 70px -30px rgb(0 0 0 / .8); }
.placement-win__bar { display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 14px; border-bottom: 1px solid rgb(255 255 255 / .07); font-size: 13px; color: #a3a9a2; }
.placement-win__bar b { color: #e3e2da; font-weight: 500; flex: 1; }
.placement-win__tag { font: 500 12px/1 var(--font-mono); padding: 5px 8px; border-radius: 4px; background: rgb(159 199 184 / .14); color: var(--p-accent); }
.placement-win__img { display: block; background: #fff; }
.placement-win__img img { width: 100%; height: auto; }
.placement-shot figcaption { font-size: var(--t-small); line-height: 1.5; color: color-mix(in oklab, var(--ink) 78%, var(--bg)); max-width: 60ch; }
.placement-shot figcaption .link { margin-left: 4px; }
.ad-block__logo { width: 132px; height: auto; padding: 8px 10px; background: #fff; border-radius: var(--r-sm); }
@media (max-width: 639px) { .placement-shot { margin-top: var(--s-5); } }
