/* ============================================================================================================================
   AN OPEN CONVERSATION GIVES THE OPEN EMAIL THE ROOM (R-1430 the newest, R-1432 any of them; owner 27 Nov 2026). NEW PACE ONLY — every rule starts with
   html[data-new-pace]; sizes on the scale (np-look-values.css). The fold itself: public/js/99zzzv-inbox-reading.js.
   ============================================================================================================================ */

/* the earlier emails, folded to one line above the open one; the later ones (.is-later), one line below it */
html[data-new-pace] .ibx-earlier{display:flex;align-items:center;gap:var(--np-space-2_5);width:100%;min-height:var(--np-h-control);margin:0 0 var(--np-space-2_5);
  padding:var(--np-space-1_5) var(--np-space-3_5) var(--np-space-1_5) var(--np-space-1_5);border:1px dashed var(--border2);border-radius:var(--np-round-pill);
  background:color-mix(in srgb,var(--card-solid) 70%,transparent);color:var(--text);font:600 var(--np-text-md)/1.3 var(--font);text-align:left;cursor:pointer}
html[data-new-pace] .ibx-earlier-n{flex:none;display:inline-flex;align-items:center;justify-content:center;min-width:var(--np-space-8);height:var(--np-space-8);
  padding:0 var(--np-space-2);border-radius:var(--np-round-pill);background:color-mix(in srgb,var(--fx-acc) 16%,transparent);color:var(--text);font:700 var(--np-text-sm)/1 var(--font)}
html[data-new-pace] .ibx-earlier-t{flex:none}
html[data-new-pace] .ibx-earlier-m{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--text3);font-weight:500}
html[data-new-pace] .ibx-earlier-m b{color:var(--fx-main);font-weight:700}
html[data-new-pace] .ibx-earlier.is-later{margin:var(--np-space-2_5) 0 0}
html[data-new-pace] .ibx-earlier.is-open{border-style:solid;color:var(--text2)}
html[data-new-pace] .ibx-earlier:focus-visible{outline:2px solid var(--fx-main);outline-offset:2px}
@media (hover:hover) and (pointer:fine){
  html[data-new-pace] .ibx-earlier:hover{border-color:var(--fx-main);background:var(--card-solid)}
}

/* a phone: the heading and the reply box would leave the email a short box if it only filled the screen, so there the email keeps
   its own big box (R-108's size) and the page scrolls — the heading slides away as you read down */
@media (max-width:860px){
  html[data-new-pace] #mb-read .mb-thread.solo:has(> :is(#mb-before,#mb-after) > .ibx-earlier){display:block}
  html[data-new-pace] #mb-read .mb-thread.solo:has(> :is(#mb-before,#mb-after) > .ibx-earlier) > #mb-open > .mb-msg.open > .mb-body{flex:none;height:clamp(340px,64vh,760px)}
}

/* the folded line says how many — the heading's "5 messages" would say it twice */
html[data-new-pace] #mb-read:has(:is(#mb-before,#mb-after) > .ibx-earlier:not(.is-open)) .mb-title > .pill.mute{display:none}

/* the list and the conversation take turns below 1280px (D-0455): while one is open, the chips and the search step aside for it,
   as they already do on a phone — Back brings them back */
@media (min-width:961px) and (max-width:1279px){
  html[data-new-pace] #mb-root:has(#mb-panes.reading) > #mb-tabs,html[data-new-pace] #mb-root:has(#mb-panes.reading) > #mb-toolbar{display:none}
  html[data-new-pace] #mb-root:has(#mb-panes.reading) > #mb-panes{margin-top:0}
}
