/* panel-settings-menu.css
 *
 * The account menu, opened from the email in the rail footer.
 *
 * Linked from panel.html rather than pasted into its inline <style>. The FLINT
 * tokens live on :root in that block, and :root is the document — so they
 * cascade into this file unchanged and nothing has to be duplicated here.
 * Every value below is a token for that reason; a literal hex in this file
 * would be the one thing that stops tracking the palette. */

.pxsm {
  position: fixed;
  z-index: var(--z-sheet);                 /* over the rail, which floats the column below
                                  the layout breakpoint */
  min-width: 208px;
  max-width: min(280px, calc(100vw - 16px));
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;

  border-radius: var(--r-card);
  /* No ground here (2026-09-22): .pxsm is in glass-surface.js's TARGETS as
     `bubble` — the reply bubble's glass, by request — and the component
     paints the frost, the ring and the drop. The --s-card / 18px blur that
     was here would only lose to it on document order. .ctx-menu is the same
     object and made the same move. */
}

.pxsm[hidden] { display: none; }

/* Who again, because the trigger naming them is usually what the menu is now
   covering. Mono and faint: it is a label, not an action. Both halves here —
   the name the rail had room for and the address it did not. */
.pxsm-head {
  font: 400 var(--fs-xs)/1.4 var(--mono);
  letter-spacing: .06em;
  color: var(--t-faint);
  padding: 8px 10px 9px;
  margin-bottom: 2px;
  border-bottom: 1px solid var(--hair);
  display: flex; align-items: center; gap: 9px;
  overflow: hidden;
}

/* Same construction as .auth-avatar in panel.html — the circle is the span and
   the picture only fills it, so the initial stands when the URL does not.
   Bigger than the rail's 22px because this row is two lines tall and a circle
   sized to one of them reads as a bullet. */
.pxsm-avatar {
  position: relative; flex: none;
  width: 28px; height: 28px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  background: var(--s-inter);
  box-shadow: inset 0 0 0 1px var(--hair);
  color: var(--t-meta);
  font-size: var(--fs-sm); letter-spacing: 0;
  user-select: none; -webkit-user-select: none;
}
.pxsm-avatar img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
  display: block;
}

/* min-width: 0 so the two labels inside can ellipsis. A flex item's floor is
   its content width by default, which for an address is the whole address. */
.pxsm-who { flex: 1; min-width: 0; }

.pxsm-name {
  display: block;
  color: var(--t-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pxsm-name[hidden] { display: none; }

.pxsm-email {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pxsm-item {
  font: 400 var(--fs-base)/1.35 var(--sans);
  color: var(--t-body);
  text-align: left;
  background: none;
  border: none;
  border-radius: var(--r-md);         /* inside a 16px card — square outside, rounded in */
  padding: 9px 10px;
  cursor: pointer;
  transition: none;
}

.pxsm-item:hover,
.pxsm-item:focus-visible {
  color: var(--t-primary);
  background: var(--s-inter);
}

/* LEARN MORE, and the level it opens (panel-slidemenu.css has the level's
   rows). The row is a row of this menu with a chevron on its right saying
   there is more to it; the chevron is the only thing that marks it, since a
   row that reads "Learn more" already says most of it. */
.pxsm-more { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pxsm-chev { font: 400 var(--fs-body)/1 var(--sans); color: var(--t-faint); transform: translateY(-1px); }
.pxsm-more:hover .pxsm-chev { color: var(--t-secondary); }
/* Language: the one in use, quiet, on the right of the row. */
.pxsm-lang-now { color: var(--t-faint); font-size: var(--fs-sm); white-space: nowrap; }
.pxsm-lang:hover .pxsm-lang-now { color: var(--t-secondary); }

/* Sign out is destructive of local state, so it separates from the two that
   are not. No red — severity reads through weight here, the same way the cards
   and the badge carry it. */
.pxsm-danger {
  position: relative;
  margin-top: 7px;
  color: var(--t-secondary);
}
/* The rule sits above the row, not on it: a border-top squared the row's top
   corners when it lit up. */
.pxsm-danger::before {
  content: ""; position: absolute; left: 6px; right: 6px; top: -5px;
  height: 1px; background: var(--hair); pointer-events: none;
}

.pxsm-danger:hover,
.pxsm-danger:focus-visible { color: var(--bone); }

/* The trigger only reads as a control once there is an account behind it —
   pxInitSettingsMenu adds .is-menu, and removes it on sign-out. The picture
   gets the class for the cursor alone: it carries the same click and none of
   the ARIA, so there is no focus ring to draw on it. */
.auth-avatar.is-menu { cursor: pointer; }
.auth-who.is-menu { cursor: pointer; }
.auth-who .auth-email { transition: none; }
.auth-who:hover .auth-email,
.auth-who:focus-visible .auth-email { color: var(--t-primary); }

/* The hover box. Every other row that opens something in this panel lights a
   ground under itself — .pxsm-item, .set-nav-item, the rail's own rows — and
   this one only brightened its text, so the one control that opens a menu was
   the one that did not look pressable. Same --s-inter at the same 10px radius
   as those rows, which is why the geometry in panel.html was inset to match
   them. HELD while the menu is open: the row and the menu it opened are one
   object in two parts, exactly as .pxsm-more is with its flyout.

   A SOFT VERSION OF THIS WAS TRIED AND TAKEN BACK OUT: a blurred rect on a
   ::before, so the plate faded off at its edges instead of ending at them.
   It works and it is not what this panel is — every other row that marks
   itself here does so with a bounded wash, and one row answering the cursor
   with a glow made it the odd one out rather than the soft one. The rail's
   rows were briefly given the same treatment and came back for the same
   reason. If it is ever wanted again, the whole construction is in the
   history: a ::before at inset 6px 3px, rgba(--warm-rgb, .11), blur(6px),
   faded on opacity, under isolation with z-index -1 — and note that both
   this row and .session-head need their `overflow: hidden` dropped first,
   or the layer is clipped straight back to a hard edge. */
.auth-who.is-menu {
  transition: none;
}
/* Hover is --s-quiet, the same wash a session or tab row takes, because this
   is a row in the same list-shaped column and it was answering the cursor at
   more than twice the strength of everything above it. The OPEN state keeps
   --s-inter: hover is a pointer passing over, an expanded menu is a state the
   row is holding, and those two should not read alike. */
.auth-who.is-menu:hover,
.auth-who.is-menu:focus-visible { background: var(--s-quiet); }
/* The open state has to OUT-RANK hover, not just follow it. At (0,2,0) it
   lost to the (0,3,0) hover rule, so a row clicked open showed the lighter
   hover wash under the pointer and then stepped UP to --s-inter the moment
   the pointer left — the highlight getting stronger as you moved away from
   it. Matching .is-menu and sitting last, it holds one shade from the click
   until the menu closes. The text is held with it for the same reason. */
.auth-who.is-menu[aria-expanded="true"] { background: var(--s-inter); }
.auth-who[aria-expanded="true"] .auth-email { color: var(--t-primary); }
.auth-who[aria-expanded="true"] .auth-plan { color: var(--t-secondary); }

/* The plan, beside the name. No ring and no ground: the register of
   .set-plan-name, which is the same object in the settings pane and is also
   bare — a label in the machine's voice, set apart by case and tracking rather
   than by a box. The box was there to make a chip of it, and a chip reads as
   something to press. The padding went with the ring: it was shaping it. */
/* CENTRING IT TOOK TWO CORRECTIONS, one per axis, and neither is a nudge.
 *
   VERTICALLY it was 8.5px/1, and a line box exactly one em tall does not
   centre CAPITALS in itself: the box is ascent plus descent, the descent is
   empty for a run with no lowercase in it, and the caps therefore sit about a
   tenth of an em above the box's middle. align-items: center then centres the
   BOX, faithfully, and the letters ride high. The fix is to give it the line
   height the name beside it already has — at 1.5 both runs carry the same
   proportion of empty descent, so centring the boxes centres the letters, and
   the two agree by construction rather than by a measured offset that would
   be wrong again at the next font size. The row's height is unchanged; the
   22px avatar sets it and 12.75px does not reach it.

   HORIZONTALLY, letter-spacing is applied AFTER the last letter as well as
   between letters, so an uppercase label with .14em tracking carries an
   invisible .14em of itself on its right. Against the chevron that read as
   the plan sitting left of where its gap says it is. The negative margin
   gives exactly that much back — the value is tied to the tracking above and
   must move with it. */
.auth-plan {
  flex: none;
  font: 400 var(--fs-2xs)/1.5 var(--mono);
  letter-spacing: .14em;
  margin-right: -.14em;
  text-transform: uppercase;
  color: var(--t-faint);
  /* ...AND THE LAST PIXEL OF IT IS THIS, which matching the line-height could
     not buy. align-items: center centres the two BOXES, and a text box's
     baseline is not at its centre: it sits half-leading plus the ascent down
     from the top, which works out at .375 of the font size below the middle.
     That fraction is the same for both runs — same family, same line-height —
     but it is a fraction OF THE FONT SIZE, so the 11px name puts its baseline
     4.1px below the row's centre and the 8.5px plan puts its own 3.2px below,
     and the label floats a pixel high on a line it is supposed to share.
     1px down is that difference, and it is a nudge with an arithmetic behind
     it rather than a number that looked right: it moves with the two sizes
     above, and if either changes this wants recomputing. */
  position: relative;
  top: 1px;
  transition: none;
}
.auth-plan[hidden] { display: none; }
.auth-who:hover .auth-plan { color: var(--t-secondary); }

/* Says the row opens something. Points down at rest and flips while the menu
   is open — the trigger's own aria-expanded drives it, so the arrow cannot
   disagree with the menu. */
.auth-chev {
  flex: none;
  margin-left: auto;
  display: flex; align-items: center;
  color: var(--t-faint);
  transition: none;
}
.auth-who:hover .auth-chev { color: var(--t-secondary); }
.auth-who[aria-expanded="true"] .auth-chev { transform: rotate(180deg); color: var(--t-secondary); }

/* The menu slides in: the card rises into place, then its rows follow a beat
   apart. Keyframes rather than a transition because the menu is toggled with
   `hidden`, and an animation restarts every time display comes back.
 *
 * IT RUNS BOTTOM UP, and the trigger is why. The menu opens UPWARD out of the
 * rail footer (see pxPlaceSettingsMenu), so its LAST row is the one nearest
 * the row that was just clicked. Cascading from the top meant the motion
 * started at the far end and arrived back at the cursor, which reads as the
 * menu falling rather than being pulled out. nth-last-child is the whole of
 * it: the row by the pointer moves first and the rest follow away from it.
 * The head, which is the farthest and is a label rather than an action,
 * lands last. */
@keyframes pxsm-in {
  from { opacity: 0; transform: translateY(10px) scale(.98); }
  to   { opacity: 1; transform: none; }
}
@keyframes pxsm-row-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}
#pxSettingsMenu:not([hidden]) {
  transform-origin: bottom left;
  animation: pxsm-in var(--dur-1) var(--ease-out) both;
}
#pxSettingsMenu:not([hidden]) > * {
  animation: pxsm-row-in var(--dur-1) var(--ease-out) both;
}

@media (prefers-reduced-motion: reduce) {
  .auth-chev { transition: none; }
  #pxSettingsMenu:not([hidden]),
  #pxSettingsMenu:not([hidden]) > * { animation: none; }
}

.auth-email.is-menu {
  cursor: pointer;
  border-radius: var(--r-ctl);
  transition: none;
}

.auth-email.is-menu:hover { color: var(--t-primary); }
.auth-email.is-menu:focus-visible {
  outline: 1px solid var(--rim);
  outline-offset: 2px;
}

/* ---- usage popup ----------------------------------------------------
 * The budget bar used to stand in the rail whether or not anyone wanted it.
 * It is asked for now, so it gets a surface of its own. */

.pxpop {
  position: fixed;
  inset: 0;
  z-index: var(--z-popover);                 /* over the account menu that opened it */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
/* At 200% zoom a 320 px panel is 160 CSS px, and 24 px of margin plus the
   card's 16 px of padding left the content half of that. */
@media (max-width: 260px) {
  .pxpop { padding: 8px; }
  .pxpop .pxpop-card { padding: 10px; }
}

/* Artifact dialogs use the same modal backdrop as Settings. */
.pxpop, .px-artifact-dialog::backdrop {
  /* THE SCRIM IS BACK, reversing "No scrim (2026-09-22)", which read: "the
     card is glass over the page, exactly as the account menu that opened it
     is. The overlay stays as the click-catcher."
   *
     That was right about the MATERIAL and wrong about the STATE. A menu is
     transient and sits beside what it came out of, so glass alone places it.
     A dialog is modal — the panel behind it is locked (body.px-modal-open,
     and the document lock in panel.html) — and nothing said so: the rail and
     the conversation stayed at full strength behind a card that had taken the
     keyboard and the scroll away from them. Glass over live-looking panel is
     also the hardest case for the card to win, which is why .pxpop-card
     carries the panel's thickest frost at .52.

     Ink and a blur, which is the same pair .wheel-scrim.open lays under the
     send arc. --ink-rgb is the GROUND token, so this recedes the background
     toward whatever the theme's ground is — it darkens under the dark theme
     and veils pale under the light one, which is the same direction every
     other surface moves in each. A literal colour here would be a scrim the
     light theme cannot reach.

     THE BLUR IS 4px, NOT 14. The point is that the panel goes SOFT, not that
     it becomes a field of colour: the rail's rows and the conversation should
     still be recognisable as themselves, just out of focus — what is behind a
     dialog is context, and a smear says the panel stopped existing rather
     than that it stopped being the thing in hand. The dimming is doing the
     separating; the blur only takes the edge off the text so nothing behind
     competes for a read. 14px was well past legible and into featureless,
     which is also where it stops looking like glass and starts looking like
     a lens cap. Below ~3px it reads as a rendering fault rather than a
     choice. */
  background: rgba(var(--ink-rgb), .46);
  backdrop-filter: blur(4px) saturate(.92);
  -webkit-backdrop-filter: blur(4px) saturate(.92);
  animation: pxpop-in var(--dur-1) ease both;
}
/* On paper a veil of the page colour hides nothing, so the light theme dims
   with ink instead, as light interfaces do behind a dialog. */
:root[data-theme="light"] .pxpop, :root[data-theme="light"] .px-artifact-dialog::backdrop { background: rgba(var(--bone-rgb), .14); }

/* THE CARD KEEPS ITS OWN 20px, and at 4px above it that is not paying twice.
   A version of this dropped it — .pxpop has a backdrop-filter, so it is a
   BACKDROP ROOT and what the card samples is the scrim's output, which was
   the pills-over-.wheel-scrim argument in panel-wheel.css. That argument
   holds only while the scrim has actually done the blurring, and at 4px it
   has not: the card would be a .52 frost over a nearly sharp rail, with the
   list ghosting up through the form. The two are doing different jobs at
   different strengths — the scrim softens the panel, the card hides it — so
   both blurs stay. */

/* Toggled with `hidden`, so a keyframe rather than a transition — the same
   reason the account menu's entrance is one. */
@keyframes pxpop-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .pxpop, .px-artifact-dialog::backdrop { animation: none; }
}

.pxpop[hidden] { display: none; }

/* The backdrop is not a scroller, so a wheel over it goes straight to the
   document. Set while any dialog is open, cleared by pxCloseAllPopups.
   Belt and braces since panel.html locked the document outright — kept so the
   dialogs stay correct on their own terms if that ever changes. */
body.px-modal-open { overflow: hidden; }

.pxpop-card {
  width: 100%;
  /* Wide enough that the 24px padding on .pxpop is what sets the horizontal
     gap, not this cap. At 340 the card stopped short in a docked panel and
     left ~30px at the sides against 24px top and bottom — a border that was
     visibly not square. It only binds on a wide undocked window, where a
     460px column is the readable limit anyway. */
  max-width: 460px;
  padding: 16px;
  /* Settings outgrew the viewport once it held five sections. The popup
     centres its card, so without a ceiling and a scroller the card simply
     extended past both edges of a short panel with no way to reach the top —
     which is where Profile sits. */
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  /* Keeps the card's scroll to itself. Without this, reaching either end
     hands the remaining delta to the document and the panel moves behind the
     dialog. */
  overscroll-behavior: contain;
  /* Not --s-card alone. That token is a 5% wash meant to sit ON the panel
     ground and read as a raised surface; floating over a backdrop it left the
     rail legible straight through the form. The ink ground goes underneath it,
     near-solid, with the wash layered on so the card still reads as lit rather
     than as a hole cut in the panel. */
  background: linear-gradient(var(--s-card), var(--s-card)), rgba(var(--ink-rgb), .96);
  box-shadow: var(--lit-card), 0 18px 44px rgba(var(--ink-rgb), .6);
  border-radius: var(--r-card);
}

.pxpop-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: var(--scroll-gap);
}

.pxpop-title {
  font: 400 var(--fs-2xs)/1 var(--mono);
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--t-faint);
}

/* The icon button (panel-controls.css): the tool row's 28px square. */
.pxpop-close { margin-left: auto; font: 400 var(--fs-body)/1 var(--sans); }

/* The bar's own rules still come from the inline sheet; it only needs its rail
   spacing dropped now that it sits in a card. */
.pxpop-card .usage { margin: 0; }

/* Shown only while the meter has nothing to show. :has() tracks renderBudget()'s
   own hidden state, so there is no second code path deciding the same thing. */
.usage-empty {
  display: none;
  font: 400 var(--fs-base)/1.5 var(--sans);
  color: var(--t-meta);
}

.pxpop-card:has(#usageMeter[hidden]) .usage-empty { display: block; }
/* ...but not under a load that failed: the error row says what happened, and
   "sign in and run something" is wrong for a signed-in account (F-037). */
.pxpop-card:has(#uvError:not([hidden])) .usage-empty { display: none; }

/* ---- all chats ---------------------------------------------------- */
/* The rail's overflow, a column view (panel-column-view.js) as Search is. The
   LIST scrolls rather than the column, so the title stays put above rows that
   move, and the bulk-delete foot stays under them.
   The 8px inset is the rail's own (.sessions), because these are the rail's
   rows: they carry their own margins and would otherwise sit against the
   card's edge in a way they never do in the rail. */
.search-view-col.all-card { overflow: hidden; }
.all-view .all-foot { padding: var(--scroll-gap) 16px 16px; }

.all-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: var(--scroll-pad) 8px;
}

/* Bulk delete: the can in the card's lower-left corner, and the checkbox it
   puts at the right of every row while it is on. */
.all-foot {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: var(--scroll-gap);
}

.all-trash {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  background: none;
  border: none;
  border-radius: var(--r-ctl);
  cursor: pointer;
}

.all-trash svg { width: 16px; height: 16px; stroke: var(--t-meta); }
.all-trash:hover { background: var(--s-inter); }
.all-trash:hover svg { stroke: var(--bone); }
.all-trash[aria-pressed="true"] { background: rgba(var(--danger-rgb), .12); }
.all-trash[aria-pressed="true"] svg { stroke: rgb(var(--danger-rgb)); }


.all-check {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 16px;
  height: 16px;
  margin-left: auto;
  /* Last in every row. A plain tab keeps an empty trailing slot (.tab-row::after)
     where a group's count would be, and without this its box landed in front of
     that slot, 22px left of every other row's. */
  order: 1;
  border-radius: var(--r-ctl-sm);
  box-shadow: inset 0 0 0 1.5px var(--t-faint);
}

.all-check svg { width: 11px; height: 11px; stroke: var(--ink); visibility: hidden; }
.all-check[aria-checked="true"] { background: var(--bone); box-shadow: none; }
.all-check[aria-checked="true"] svg { visibility: visible; }

/* ---- chat search --------------------------------------------------- */

/* "Search", in the rail's "new" rows between New group and Projects. Neither
   margin: New group has no bottom one and Projects no top one, so each row's
   own 10px padding is the gap, as between the others. */
.new-thread.search-btn { margin-top: 0; margin-bottom: 0; }

/* The whole column, on the ground .chat-loading-panel uses. What it covers is
   hidden as well as covered, so Tab can't walk into a composer nobody can see. */
.search-view {
  position: absolute; inset: 0; z-index: 4;
  display: flex; justify-content: center;
  background: var(--ink);
  outline: none;
}
.search-view[hidden] { display: none; }
.main.px-search-open > :not(#searchView) { visibility: hidden; }
/* The views panel-column-view.js builds: the same shell, the same rule. */
.main.px-colview-open > :not(.px-colview-on) { visibility: hidden; }
/* The body scrolls under a fixed head, its content 16px in from both edges as
   the find box and the citation graph's are. */
.px-colview-body {
  flex: 1; min-height: 0;
  overflow-y: auto; overscroll-behavior: contain;
  padding: 4px 16px 24px;
}
/* A head's actions sit at the right, beside ×: the first takes the slack the
   × would otherwise take. Every head reads TITLE ... [action] ×. */
.search-view-head > .pxpop-title + :not(.pxpop-close) { margin-left: auto; }
.search-view-head > .pxpop-title + :not(.pxpop-close) ~ .pxpop-close { margin-left: 0; }

.search-view-col {
  width: 100%; max-width: 720px; min-width: 0;
  display: flex; flex-direction: column;
  padding: 18px 14px 0;
}
.search-view-head { flex-shrink: 0; padding: 0 2px 0 16px; }
/* The rail's toggle hangs over this corner with the rail closed, so the ROW
   beside it makes room, as .main-top and the music view's top row do. Only
   that row: shifting the whole column put the box and the list 54px from the
   left and 30px from the right (2026-11-13). Everything under the head now
   sits the same distance from both edges. The title lands 54px in, where
   .main-top's does: 54px less the column's own 14px. */
.rail.collapsed ~ .main .search-view-head { padding-left: calc(54px - 14px); }

.find-box {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 16px 12px;
  padding: 0 12px;
  min-height: var(--ctl-h);
  background: var(--s-card);
  box-shadow: var(--lit-card);
  /* The controls' rounded rectangle, as every search bar is (2026-11-12): at
     this height --r-card drew a pill. The ground and edge come from glass
     (`field`, glass-surface.js), the composer's material. */
  border-radius: var(--r-ctl);
}

/* The box takes the focus ring, not the input: the glass is inside it and the
   two would otherwise draw two rectangles a pixel apart. */
.find-box:focus-within { box-shadow: var(--lit-card), 0 0 0 1px var(--rim); }

.find-glass {
  flex-shrink: 0;
  width: 14px; height: 14px;
  stroke: var(--t-faint);
}
.find-box:focus-within .find-glass { stroke: var(--t-secondary); }

.find-input {
  flex: 1;
  min-width: 0;
  padding: 8px 0;
  font: 400 var(--fs-lg)/1.45 var(--sans);
  color: var(--bone);
  background: none;
  border: none;
  outline: none;
}
.find-input::placeholder { color: var(--t-faint); }

.find-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  /* Room at the sides for a row's glass edge, which the scroller would clip;
     the shared scroll inset above and below. */
  padding: var(--scroll-pad) 10px;
}

/* What the list is showing and how much of the archive it read. In the rail's
   heading register, because it labels a list the way "Chats" does. */
.find-note {
  padding: 2px 8px 10px;
  font: 400 var(--fs-2xs)/1.5 var(--mono);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--t-faint);
}

/* A row here is NOT a .session-head. It is a search result: one click target,
   no chevron, no context menu, no thread list folding out underneath. Building
   it from the rail's row builders would have brought all four into a dialog
   whose single job is to get out of the way. */
.find-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  margin: 0 0 2px;
  /* A rail row's shape (2026-11-13): .session-head's padding and radius, and
     its glass on the focused row (glass-surface.css). */
  padding: 9px 8px;
  text-align: left;
  background: none;
  border: none;
  border-radius: var(--r-md);
  color: var(--t-secondary);
  cursor: pointer;
  transition: none;
}
.find-row:hover, .find-row:focus-visible {
  background: var(--s-quiet);
  color: var(--t-primary);
}

.find-glyph {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 14px; height: 20px;
  color: var(--t-faint);
}
.find-glyph svg { width: 13px; height: 13px; stroke: currentColor; }
.find-row:hover .find-glyph { color: var(--t-secondary); }

.find-main { flex: 1; min-width: 0; display: block; }

.find-name {
  display: block;
  /* The rail's row type: a chat's name reads the same here as there. */
  font: 400 var(--fs-body)/1.3 var(--serif);
  color: var(--t-primary);
  /* One line, clipped. The rail fades a long name against its own edge
     (railFadeObserver); in a 520px dialog an ellipsis is honest and needs no
     measurement — and there is no drag here for a gradient to survive. */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* The snippet that says why a row is in the list, and only ever drawn for a
   match the name does not already explain. Two lines at most: it is evidence,
   not a preview. */
.find-why {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 3px;
  font: 400 var(--fs-md)/1.5 var(--sans);
  color: var(--t-faint);
}

.find-meta {
  flex-shrink: 0;
  padding-top: 4px;
  font: 400 var(--fs-2xs)/1 var(--mono);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--t-faint);
}
/* --rim is the accent token — "live, contradiction, citation" in :root — and
   a live run is the first of those three. */
.find-meta.is-live { color: var(--rim); }

/* ---- settings ---------------------------------------------------- */

/* The settings half of .pxpop-card. Everything above stays as it is — the
   usage popup is a single short readout and has no business growing a rail.
 *
 * The card is a COLUMN whose middle row scrolls, rather than a card that
 * scrolls: the rail has to stay put while its pane moves, and a card-level
 * scroller would carry the rail off the top with the first section that is
 * taller than the dialog.
 *
 * A fixed height rather than a max: the four panes are wildly different
 * lengths (a segmented control against a plan ladder), and sized to content
 * the dialog would jump half a screen every time the rail was clicked. It
 * still yields to a short window, which is the case max-height was added for. */
.pxpop-card.set-card {
  max-width: 640px;
  height: min(560px, calc(100vh - 48px));
  max-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  /* What the nav asks (below): how wide the card is, not the window. */
  container: setcard / inline-size;
}

.set-body {
  flex: 1;
  min-height: 0;               /* or the pane's scroller never engages */
  display: flex;
  gap: 14px;
}

/* The `display: flex` above out-ranks the browser's own `[hidden]` rule, so
   without this an open memory file did not REPLACE the list, it sat under it:
   pxShowFileView hides #setBody, the body kept laying out at flex: 1, and the
   document got the half of the card the rail and its pane left over. Every
   other toggled block in this sheet carries this line for the same reason. */
.set-body[hidden] { display: none; }

/* NO LABEL IS EVER CUT (F-047, F-035). The rail was a fraction of the card
   (26%, 78 to 128 px) with each label ellipsed, and at a 320 or 400 px panel
   that cut Connectors, Appearance, Advanced and Experimental, and Research
   too once text spacing was raised. Now the rail is as wide as its longest
   label, and where the card is too narrow for a rail and a pane side by side
   (below 440 px, which is a docked 400 px panel) the sections become a
   wrapping row of tabs above the pane, every label whole. */
.set-nav {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  /* The divider is the rail's own edge (2026-10-22, by request): the same
     1px --hair line the sidebar's resize edge draws at rest. */
  border-right: 1px solid var(--hair);
  padding-right: 10px;
}

/* The register of .pxsm-item, because it is the same object: a row of a short
   list that switches what you are looking at. */
.set-nav-item {
  font: 400 var(--fs-base)/1.35 var(--sans);
  color: var(--t-secondary);
  text-align: left;
  background: none;
  border: none;
  border-radius: var(--r-md);
  padding: 9px 10px;
  cursor: pointer;
  white-space: nowrap;
  transition: none;
}

.set-nav-item:hover { color: var(--t-primary); background: var(--s-inter); }
.set-nav-item:focus-visible { outline: 1px solid var(--rim); outline-offset: -1px; }

/* Lit exactly as the rail's own current row is: the selected row is that
   row's glass (glass-surface.js TARGETS, glass-surface.css), so only the text
   colour is said here. */
.set-nav-item.on { color: var(--bone); }

.set-panes {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  /* Keeps the pane's scroll to itself, the same rule the card carried before
     it stopped being the scroller. */
  overscroll-behavior: contain;
  /* Room for the scrollbar so a long pane does not shift its own fields left
     the moment it overflows. Above and below, the shared scroll inset: the
     first and last rows rest clear of the head and the card's edge, and fade
     under both when scrolled. */
  padding-right: 2px;
  /* A field's focus ring is a 1px shadow OUTSIDE it, and a scroller clips on
     both axes, so with no room on the left the ring lost its left edge (the
     Instructions box read as cut off at its start). The 2px of room is given
     back with the margin, so the fields stay where they were. */
  padding-left: 2px;
  margin-left: -2px;
  padding-block: var(--scroll-pad);
}

.set-pane[hidden] { display: none; }
@container setcard (max-width: 440px) {
  .set-body { flex-direction: column; gap: var(--scroll-gap); }
  /* No rule under the tabs: the pane below them scrolls, and its fade is
     the edge (see --scroll-gap in panel.html). */
  .set-nav {
    flex: none; flex-direction: row; flex-wrap: wrap; gap: 2px;
    border-right: none; padding-right: 0;
  }
  /* A label wider than the whole row (200% zoom on a 320 px panel) breaks
     rather than running out of the card. */
  .set-nav-item { padding: 6px 9px; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
  .set-panes { flex: 1 1 0; min-height: 0; }
}



/* Every row after a pane's first, including the ones built into
   #setExperiments, which a plain `.set-row + .set-row` misses on both sides:
   the first experiment follows the intro row from inside the wrapper, and
   Motion blur follows the wrapper, not a row. */
.set-row + .set-row,
.set-row + #setExperiments > .set-row:first-child,
#setExperiments + .set-row,
.set-row + #setNotifyKinds > .set-row:first-child,
#setNotifyKinds + .set-row {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--hair);
}

/* The subheads are Newsreader (2026-10-22, by request): a section's name is
   asserted, not annotated, so it takes the serif rather than the mono caps
   the meta labels use. .set-title is the Usage pane's own heading. */
.set-label,
.set-title {
  display: block;
  font: 400 var(--fs-xl)/1.25 var(--serif);
  letter-spacing: -.005em;
  color: var(--t-primary);
  margin-bottom: 6px;
}

.set-help {
  font: 400 var(--fs-base)/1.5 var(--sans);
  color: var(--t-meta);
  margin-bottom: 11px;
}

/* A segmented control, not a <select>: three options with real consequences
   deserve to be visible at once rather than folded behind a click. */
.set-seg { display: flex; gap: 6px; }

/* A choice not offered to this account (Presence, D69). */
.set-opt[hidden] { display: none; }
.set-opt {
  flex: 1;
  font: 400 var(--fs-2xs)/1 var(--mono);
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--t-secondary);
  background: var(--s-inter);
  box-shadow: var(--lit-pill);
  border: none;
  border-radius: var(--r-ctl);
  height: var(--ctl-h); padding: 0 6px;
  cursor: pointer;
  transition: none;
}

.set-opt:hover { color: var(--bone); background: rgba(var(--warm-rgb), .16); }
.set-opt.on { color: var(--ink); background: var(--bone); box-shadow: none; }
/* An option this server cannot run yet (Advanced: hybrid recall). Shown so
   the setting's place is visible, never selectable. */
.set-opt:disabled,
.set-opt:disabled:hover { color: var(--t-faint); background: var(--s-inter); cursor: not-allowed; opacity: .55; }

/* Accent swatches: a radio group of colours. Each swatch shows ITS colour
   in the theme in force, whatever accent is chosen: --sw is the swatch's
   --accent-<name> from panel.html's accent section. The chosen one is
   ringed in the text colour with a gap of ground, the way a selected colour
   is marked anywhere; the ring is a shadow, not a border, so choosing does
   not move the row. */
.set-accent { display: flex; flex-wrap: wrap; gap: 4px; margin-left: -4px; }
.set-accent-sw {
  --sw: var(--accent-cyan);
  position: relative;
  width: var(--ctl-h); height: var(--ctl-h); padding: 0;
  border: 0; border-radius: 50%; background: transparent; cursor: pointer;
}
.set-accent-sw::after {
  content: ""; position: absolute; inset: 7px; border-radius: 50%;
  background: var(--sw);
  box-shadow: inset 0 0 0 1px rgba(var(--bone-rgb), .14);
  transition: box-shadow var(--dur-1) ease, transform var(--dur-1) ease;
}
.set-accent-sw:hover::after { transform: scale(1.08); }
.set-accent-sw.on::after { box-shadow: 0 0 0 2px var(--ink), 0 0 0 3.5px var(--bone); }
.set-accent-sw:focus-visible { outline: var(--focus-ring); outline-offset: 0; }
.set-accent-sw[data-accent-pref="grey"]     { --sw: var(--accent-grey); }
.set-accent-sw[data-accent-pref="sage"]     { --sw: var(--accent-sage); }
.set-accent-sw[data-accent-pref="lavender"] { --sw: var(--accent-lavender); }
.set-accent-sw[data-accent-pref="rose"]     { --sw: var(--accent-rose); }
.set-accent-sw[data-accent-pref="sand"]     { --sw: var(--accent-sand); }

/* The cost consequence, in the machine's own register. Sensitivity is the one
   setting here that spends money, so it says so rather than leaving it to be
   discovered on the usage bar. */
.set-note {
  margin-top: 10px;
  font: 400 var(--fs-sm)/1.6 var(--mono);
  color: var(--t-faint);
}

/* Profile + instructions fields. Stacked label-over-control: these questions
   are sentences ("What should Parallax call you?"), and a sentence beside an
   input wraps badly in a 400px side panel. */
.set-field { display: block; margin-top: 12px; }

.set-field > span {
  display: block;
  margin-bottom: 6px;
  font: 400 var(--fs-base)/1.4 var(--sans);
  color: var(--t-meta);
}

.set-input {
  width: 100%;
  display: block;
  font: 400 var(--fs-lg)/1.45 var(--sans);
  color: var(--bone);
  background: var(--s-card);
  box-shadow: var(--lit-card);
  border: none;
  border-radius: var(--r-card);
  padding: 10px 12px;
  outline: none;
}

.set-input:focus-visible { box-shadow: var(--lit-card), 0 0 0 1px var(--rim); }
.set-input::placeholder { color: var(--t-faint); }
.set-motion-blur { display: flex; align-items: center; gap: 12px; }
.set-motion-blur input { flex: 1; min-width: 0; accent-color: var(--t-primary); }
.set-motion-blur output { min-width: 4ch; text-align: right; color: var(--t-secondary); font-variant-numeric: tabular-nums; }

.set-area {
  resize: vertical;
  min-height: 88px;
  font-size: var(--fs-base);
  line-height: 1.6;
}

/* ---- Account (2026-11-09 revamp) ----
 *
 * A card for WHO, then the plan, the sign-in facts and the way out as rows.
 * The card's banner is the account's badge art (pxPaintAccount), faded into
 * the card so it reads as a wash behind the person rather than a picture
 * above them; --acct-a/b/c are that art's three colours, for the avatar ring. */
.acct-hero {
  --acct-a: var(--rim); --acct-b: var(--rim); --acct-c: var(--rim);
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "id id" "meta btn";
  align-items: center;
  gap: 14px 12px;
  padding: 70px 16px 16px;
  border-radius: var(--r-card);
  background: var(--s-card);
  box-shadow: var(--lit-card);
  overflow: hidden;
  isolation: isolate;
}
.acct-art {
  position: absolute; inset: 0 0 auto 0;
  width: 100%; height: 104px;
  object-fit: cover;
  z-index: -1;
  -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent);
          mask-image: linear-gradient(to bottom, #000 25%, transparent);
  opacity: .9;
}
.acct-id { grid-area: id; display: flex; align-items: flex-end; gap: 12px; min-width: 0; }

/* .auth-avatar's construction (the letter under the picture), larger, with a
   ring in the art's colours and a gap of card between ring and face. */
.acct-avatar {
  position: relative; flex: none;
  width: 56px; height: 56px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  font: 400 var(--fs-3xl)/1 var(--serif); color: var(--t-primary);
  background: var(--s-inter);
  box-shadow: 0 0 0 2px var(--ink), 0 0 0 4px var(--acct-a), 0 6px 18px rgba(0, 0, 0, calc(.3 * var(--shadow-k)));
  background-image: radial-gradient(circle at 30% 25%, color-mix(in srgb, var(--acct-b) 35%, transparent), transparent 70%);
  user-select: none; -webkit-user-select: none;
}
.acct-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }

.acct-who { min-width: 0; padding-bottom: 3px; }
.acct-name {
  font: 400 var(--fs-2xl)/1.2 var(--serif); letter-spacing: -.01em; color: var(--t-primary);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
/* The address wraps rather than being cut (F-047): which account this is is
   the one thing the hero must say whole. */
.acct-email {
  margin-top: 3px;
  font: 400 var(--fs-sm)/1.4 var(--mono); color: var(--t-meta);
  overflow-wrap: anywhere;
}
.acct-meta {
  grid-area: meta;
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px;
  font: 400 var(--fs-xs)/1.4 var(--mono); letter-spacing: .08em; text-transform: uppercase;
  color: var(--t-faint);
}
.acct-meta:empty { display: none; }
.acct-pill {
  color: var(--t-primary);
  border-radius: var(--r-ctl); padding: 3px 7px;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acct-a) 70%, transparent);
  background: color-mix(in srgb, var(--acct-a) 14%, transparent);
}
.acct-badge-btn { grid-area: btn; gap: 7px; }

/* Narrow panes: the button drops under the name rather than squeezing it. */
@container setpane (max-width: 330px) {
  .acct-hero { grid-template-columns: 1fr; grid-template-areas: "id" "meta" "btn"; }
  .acct-badge-btn { width: 100%; }
  .acct-leave { flex-direction: column; align-items: stretch; }
  .acct-leave .px-btn { width: 100%; }
}
.set-panes { container: setpane / inline-size; }

.acct-hero + .set-row { margin-top: 26px; }

/* Sign-in facts: a definition list, label left in the meta register, value
   right in the body's. */
.acct-facts { margin: 4px 0 0; display: flex; flex-direction: column; }
.acct-fact {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 38px;
  border-bottom: 1px solid var(--hair);
}
.acct-fact:last-child { border-bottom: none; }
.acct-fact dt { font: 400 var(--fs-base)/1.4 var(--sans); color: var(--t-meta); flex: none; }
.acct-fact dd { margin: 0; min-width: 0; font: 400 var(--fs-base)/1.4 var(--sans); color: var(--t-secondary); text-align: right; }
.acct-fact-id { display: flex; align-items: center; gap: 8px; }
.acct-fact-id code {
  min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font: 400 var(--fs-sm)/1.4 var(--mono); color: var(--t-meta);
}
.acct-copy { padding: 0 10px; }

/* The way out: the words and the button on one line where they fit. */
.acct-leave { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.acct-leave-text { min-width: 0; }
.acct-leave .set-help { margin-bottom: 0; }
.acct-leave .px-btn { flex: none; }


/* Plan — the ladder, and where on it this account sits.
 *
 * Three stacked rungs rather than a segmented control like Research
 * sensitivity: those three options are interchangeable and fit on one line,
 * where these carry a price, a sentence and a list each. A row that has to say
 * what it costs is not a segment. */
.set-plan { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }

/* What the account has left right now, above the tiers. Sits apart from them
   because it is a reading, not an option — the tiers describe the product and
   this describes today. */
.set-plan-standing {
  display: flex; flex-direction: column; gap: 8px;
  font: 400 var(--fs-md)/1.5 var(--sans); color: var(--t-meta);
  padding-bottom: 6px;
}
.set-plan-standing-top { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.set-plan-standing-when { margin-left: auto; font: 400 var(--fs-xs)/1.5 var(--mono); letter-spacing: .06em; color: var(--t-faint); }

/* What is left of the month's runs, as a bar that empties. */
.set-plan-meter {
  height: 4px; border-radius: 2px;
  background: rgba(var(--bone-rgb), .08);
  overflow: hidden;
}
.set-plan-meter i { display: block; height: 100%; border-radius: inherit; background: var(--rim); }

.set-plan-standing-n {
  font: 400 var(--fs-body)/1 var(--mono); color: var(--bone);
}

.set-plan-tier {
  background: var(--s-quiet);
  border-radius: var(--r-lg);
  padding: 13px 14px 14px;
}

/* The current rung is stated once, by weight, and again by the badge. The rest
   of the palette has no hue to spend on this — the card wash lifts and the
   name goes to full strength, which is the same move .set-opt.on makes. */
.set-plan-tier.is-current {
  background: var(--s-inter);
  box-shadow: var(--lit-card);
}

.set-plan-top { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }

/* panel-paywall.js's checkout handler appends its failure note to the BUTTON's
   parent, which here is this row rather than the block .paywall gives it. The
   wrap above plus a full-width basis is what makes that land as a line under
   the rung instead of squeezed in beside the price. Unreachable today — the
   button is disabled while upgrade_available is false — and left correct for
   the day it is not. */
.set-plan-top .pw-soon {
  flex: 0 0 100%;
  margin-top: 6px;
  font: 400 var(--fs-sm)/1.5 var(--sans);
  color: var(--t-faint);
}

.set-plan-name {
  font: 400 var(--fs-2xs)/1 var(--mono);
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--t-secondary);
}

.set-plan-tier.is-current .set-plan-name { color: var(--bone); }

.set-plan-price {
  font: 400 var(--fs-md)/1 var(--mono);
  color: var(--t-faint);
}

/* Pushed to the far edge, so "Current" and "Upgrade" land in the same place
   down the column whichever rung they are on. */
.set-plan-badge, .set-plan-go { margin-left: auto; flex-shrink: 0; }

.set-plan-badge {
  font: 400 var(--fs-2xs)/1 var(--mono); letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink); background: var(--bone);
  border-radius: var(--r-ctl); padding: 5px 9px;
}


/* The one control in this section now, so it is full width and reads as the
   action rather than as a chip on a row. Same palette moves as .set-plan-go,
   which it replaces — it is never disabled, because it opens a page rather
   than starting a checkout, so there is no server state that could make it
   dishonest. */
.set-plan-upgrade { width: 100%; margin-top: 10px; }

.set-plan-tag {
  margin-top: 7px;
  font: 400 var(--fs-md)/1.5 var(--sans);
  color: var(--t-meta);
}

.set-plan-lines {
  margin: 10px 0 0; padding: 0; list-style: none;
  font: 400 var(--fs-base)/1.55 var(--sans);
  color: var(--t-secondary);
  display: flex; flex-direction: column; gap: 4px;
}

/* A hairline dash rather than a bullet: these are limits, and a bulleted list
   of limits reads as a sales sheet. */
.set-plan-lines li { padding-left: 20px; position: relative; }
.set-plan-lines li::before {
  content: "—"; position: absolute; left: 0; color: var(--t-faint);
}

/* Proactive and memory, shown in both states. An off feature is struck rather
   than absent — a missing line reads as an oversight, a struck one reads as a
   decision. */
.set-plan-chips { display: flex; gap: 6px; margin-top: 9px; }

.set-plan-chip {
  font: 400 var(--fs-2xs)/1 var(--mono); letter-spacing: .12em; text-transform: uppercase;
  color: var(--t-faint); background: none;
  box-shadow: inset 0 0 0 1px var(--hair);
  border-radius: var(--r-ctl); padding: 5px 8px;
  text-decoration: line-through;
  text-decoration-color: var(--t-faint);
}

.set-plan-chip.on {
  color: var(--t-secondary);
  box-shadow: inset 0 0 0 1px var(--rim);
  text-decoration: none;
}

.set-plan-soon, .set-plan-empty {
  margin-top: 4px;
  font: 400 var(--fs-md)/1.6 var(--sans);
  color: var(--t-faint);
}

.set-plan-empty strong { color: var(--t-secondary); font-weight: 400; }

.set-memory { display:flex; flex-direction:column; margin-top:10px; }
.set-memory-skeleton { display:flex; flex-direction:column; gap:13px; }
/* Shape only: the ground, the light and the radius are the shared skeleton rule's (panel.html). */
.set-memory-skeleton i { display:block; height:10px; width:92%; }
.set-memory-skeleton i:nth-child(3n + 1) { width:65%; }
.set-memory-skeleton i:nth-child(3n) { width:45%; }
.set-memory-skeleton-card { display:flex; flex-direction:column; gap:12px; padding:18px 14px; border-radius:var(--r-card); background:rgba(var(--warm-rgb),.035); }
.set-file-skeleton { flex:1 1 0; min-height:0; overflow:hidden; padding:18px 8px; }
.set-file-skeleton i:first-child { height:20px; width:55%; margin-bottom:18px; }
.set-file-skeleton i:nth-child(5) { margin-top:20px; }

@media (prefers-reduced-motion: reduce) {
  .pxsm-item, .auth-who .auth-email, .auth-who.is-menu, .auth-plan,
  .auth-email.is-menu, .set-opt { transition: none; }
}

.auth-who:focus-visible { outline: 1px solid var(--rim); outline-offset: -3px; }

/* A document replaces the settings body, including its navigation rail. */
/* The plan card's material (2026-09-22): a glass `bubble` in glass-surface.js's
   TARGETS beside .set-plan-tier, at its 12px radius. No ground or hover here —
   the component paints both, and a rule left here would only lose to it. */
.set-mem-row { position:relative; margin:7px 0; border-radius:var(--r-lg); }
.set-mem-file { display:flex; flex-direction:column; align-items:flex-start; gap:6px; width:100%; min-width:0; text-align:left; border:0; border-radius:var(--r-lg); background:none; padding:11px 38px 12px 12px; cursor:pointer; color:var(--t-primary); white-space:normal; }
.set-mem-file:focus-visible { outline:1px solid var(--rim); outline-offset:2px; }
.set-mem-category { margin-top:20px; }
.set-mem-heading { margin:0 12px 9px; font:500 var(--fs-md)/1.5 var(--sans); color:var(--t-secondary); }
.set-mem-filename { display:block; width:100%; font:500 var(--fs-lg)/1.5 var(--sans); overflow-wrap:anywhere; white-space:normal; }
.set-mem-description { font:400 var(--fs-md)/1.55 var(--sans); color:var(--t-meta); overflow-wrap:anywhere; white-space:normal; }
.set-mem-date { font:400 var(--fs-xs)/1.5 var(--sans); color:var(--t-faint); }
.set-mem-date:empty, .set-mem-description:empty { display:none; }
.set-mem-delete { position:absolute; top:7px; right:6px; width:28px; height:28px; display:grid; place-items:center; border:0; border-radius:var(--r-ctl); color:var(--t-meta); background:transparent; cursor:pointer; opacity:0; pointer-events:none; transition:opacity var(--dur-1) ease, background var(--dur-1) ease; }
.set-mem-row:hover .set-mem-delete, .set-mem-row:focus-within .set-mem-delete { opacity:1; pointer-events:auto; }
.set-mem-delete:hover, .set-mem-delete:focus-visible { background:rgba(var(--danger-rgb),.12); color:var(--t-primary); }
@media (hover:none) { .set-mem-delete { opacity:1; pointer-events:auto; } }
@media (prefers-reduced-motion:reduce) { .set-mem-delete { transition:none; } }
.set-mem-suggest { margin-top:10px; padding:12px 14px; border-radius:var(--r-card); background:rgba(var(--warm-rgb),.035); }
.set-mem-suggest h3 { margin:0 0 4px; font:500 var(--fs-md)/1.5 var(--sans); color:var(--t-secondary); }
.set-mem-suggest p { margin:0 0 8px; font:400 var(--fs-md)/1.55 var(--sans); color:var(--t-meta); }
.set-mem-change { display:flex; gap:8px; align-items:flex-start; margin:6px 0; font:400 var(--fs-md)/1.55 var(--sans); color:var(--t-primary); overflow-wrap:anywhere; }
.set-mem-change input { margin-top:3px; flex:none; }
.set-mem-change del { color:var(--t-meta); text-decoration:none; }
.set-mem-change .set-mem-to { display:block; color:var(--t-secondary); }
.set-mem-suggest-actions { display:flex; gap:6px; margin-top:8px; }
.set-mem-suggest .set-mem-from { margin:0 0 2px; color:var(--t-secondary); }
/* The nightly tidy-up (panel-memory-tidy.js): what it changed, with Undo. */
.set-mem-tidy { margin-top:10px; padding:12px 14px; border-radius:var(--r-card); background:rgba(var(--warm-rgb),.035); }
.set-mem-tidy h3 { margin:0 0 4px; font:500 var(--fs-md)/1.5 var(--sans); color:var(--t-secondary); }
.set-mem-tidy p { margin:0 0 8px; font:400 var(--fs-md)/1.55 var(--sans); color:var(--t-meta); }
.set-mem-tidy-item { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:4px 0; font:400 var(--fs-md)/1.5 var(--sans); color:var(--t-primary); }
.set-mem-tidy-undone { color:var(--t-meta); font-size:var(--fs-sm); }
.set-file { display:flex; flex:1 1 0; min-height:0; flex-direction:column; gap:var(--scroll-gap); overflow:hidden; }
.set-file[hidden], .set-file [hidden] { display:none; }
.set-file-head, .set-file-toolbar, .set-file-foot { display:flex; flex-shrink:0; align-items:center; gap:8px; }
.set-file-head { padding-bottom:10px; border-bottom:1px solid var(--hair); }
.set-file-path { flex:1; min-width:0; overflow-wrap:anywhere; font:500 var(--fs-base)/1.4 var(--sans); color:var(--t-secondary); }
.set-file-meta { display:grid; gap:5px; }
.set-file-meta .set-input { padding:0 8px; font-size:var(--fs-md); }
.set-file-state { margin-left:auto; color:var(--t-faint); font:400 var(--fs-xs)/1.4 var(--sans); }
/* The document scrolls between the toolbar and the foot with no rule at
   either end: its fade is the edge, as in the chat (--scroll-gap, panel.html). */
.set-file-body, .set-file-preview { flex:1 1 0; min-height:0; width:100%; padding:var(--scroll-pad) 8px; overflow:auto; overscroll-behavior:contain; color:var(--t-body); background:none; border:0; }
.set-file-body { resize:none; font:400 var(--fs-md)/1.7 var(--mono); }
.set-file-preview { font:400 var(--fs-lg)/1.75 var(--sans); overflow-wrap:anywhere; }
.set-file-preview h1 { font-size:var(--fs-3xl); font-weight:500; }
.set-file-preview h2 { font-size:var(--fs-body); font-weight:500; margin-top:22px; }
.set-file-preview a { color:var(--t-primary); }
.set-file-foot { padding-top:0; }
/* F-021: the head, the Edit | Preview row and the footer wrap rather than
   run off the card ("SAVE CH…" at a 400 px panel), and a button wider than
   the whole card (200% zoom) breaks its words instead of being cut. */
.set-file-head, .set-file-toolbar, .set-file-foot { flex-wrap:wrap; }
.set-file .px-btn { max-width:100%; height:auto; min-height:var(--ctl-h); padding-block:4px; white-space:normal; line-height:1.3; text-align:center; }
.set-file-save { margin-left:auto; }
.set-file-revisions { max-height:110px; overflow:auto; display:flex; gap:6px; flex-wrap:wrap; }
/* "Why do I know this?" (memory step 2): a quiet word after each line of the
   rendered file, shown on hover or focus (always where there is no hover),
   and the card it opens over Settings. */
.set-mem-why { margin-left:6px; height:20px; padding:0 6px; font:400 var(--fs-xs)/1 var(--sans); color:var(--t-faint); background:none; border:0; border-radius:var(--r-ctl); cursor:pointer; opacity:0; vertical-align:baseline; transition:opacity var(--dur-1) ease; }
.set-file-preview li:hover > .set-mem-why, .set-file-preview p:hover > .set-mem-why, .set-mem-why:focus-visible { opacity:1; }
.set-mem-why:hover, .set-mem-why:focus-visible { color:var(--t-primary); background:rgba(var(--warm-rgb),.08); }
.set-mem-why:focus-visible { outline:1px solid var(--rim); outline-offset:1px; }
@media (hover:none) { .set-mem-why { opacity:1; } }
@media (prefers-reduced-motion:reduce) { .set-mem-why { transition:none; } }
.set-why-pop { z-index:var(--z-drop); }
.set-why-card { max-width:400px; }
.set-why-line { margin:0 0 10px; padding-left:10px; border-left:2px solid var(--hair); font:400 var(--fs-lg)/1.55 var(--sans); color:var(--t-primary); overflow-wrap:anywhere; }
.set-why-source { margin:0 0 4px; font:400 var(--fs-base)/1.55 var(--sans); color:var(--t-secondary); overflow-wrap:anywhere; }
.set-why-dates { margin:0 0 10px; font:400 var(--fs-sm)/1.5 var(--sans); color:var(--t-meta); }
.set-why-dates:empty { display:none; }
.set-why-earlier[hidden] { display:none; }
.set-why-sub { margin:6px 0; font:400 var(--fs-2xs)/1 var(--mono); letter-spacing:.18em; text-transform:uppercase; color:var(--t-faint); }
.set-why-earlier ul { margin:0 0 10px; padding-left:16px; font:400 var(--fs-md)/1.5 var(--sans); color:var(--t-meta); overflow-wrap:anywhere; }
.set-why-actions { display:flex; flex-wrap:wrap; gap:6px; }
@media(max-height:550px) { .set-file-meta { grid-template-columns:1fr 1fr; } .set-file-meta #setDocDescription { grid-column:1 / -1; } .set-file { gap:5px; } }

@media(max-width:380px) {
  /* The path takes a line of its own under the two buttons, which wrap too
     when even they do not fit side by side (200% zoom). */
  .set-file-path { order:1; flex:1 1 100%; }
  #setDocDownload { margin-left:auto; }
}

/* ---- the usage wall -------------------------------------------------------
 * The session ran out while somebody was using it. Fired on the edge by
 * panel-usage.js; a panel that merely opens spent gets the band above the
 * composer instead. panel-limit.js fills both squares.
 *
 * It rides the .pxpop shell above, so the scrim, the 4px blur, the background
 * lock, Escape and the backdrop click are inherited and not restated. Only the
 * card is different, and only in size.
 */

/* ~3/4 OF THE PANEL, which is a proportion and not a width — hence vh/vw
 * rather than the 460px .pxpop-card carries. This dialog is the one surface
 * that has to read as having taken the panel over: it is reporting that the
 * thing in hand has stopped, and a 460px card centred in a wide undocked
 * window would read as a passing notice.
 *
 * The floor matters as much as the proportion. In a docked side panel (~400px)
 * 75vw is ~300px and the two squares would be unreadable columns, so it takes
 * whichever is larger of the proportion and what the content needs, still
 * bounded by the viewport less .pxpop's 24px gutters.
 */
.lim-card-shell {
  width: max(75vw, min(340px, 100vw - 48px));
  max-width: min(720px, 100vw - 48px);
  max-height: 75vh;
  display: flex;
  flex-direction: column;
  gap: var(--scroll-gap);
  padding: 22px;
  /* .pxpop-card is the scroller for every other dialog; here .lim-grid is, so
     the headline and "I understand" stay put. Left at auto the card would
     scroll too, and a wheel over the squares would move whichever of the two
     had room — a dialog that scrolls in two places at once. */
  overflow-y: hidden;
}

.lim-head { flex-shrink: 0; }

/* BIG, per the brief, and in the serif — every other headline in this panel is
 * (.pw-title, .modal-message, .set-plan-name), so a sans one here would read as
 * a system error rather than as Parallax saying something.
 *
 * MUCH bigger since 2026-09-27, on request: 19-27px was sized to keep the
 * sentence off a third line in a docked panel, which protected the layout at the
 * cost of the one thing on this surface that has to land first. It is allowed to
 * wrap now — clamp() still scales it with the viewport so a 400px panel gets the
 * bottom of the range rather than an overflow, and .lim-head does not scroll, so
 * extra lines push the squares down inside .lim-grid instead of off the card.
 * 1.1 line-height because display sizes need less leading than body text, and
 * the negative tracking is what stops a large serif reading as loose. */
.lim-title {
  font: 400 clamp(27px, 6.6vw, 42px)/1.1 var(--serif);
  color: var(--t-primary);
  letter-spacing: -.02em;
}

/* The server's own sentence under the headline, when the refusal carried one —
 * which pool ran out, what the allowance is, and what is NOT affected. Body
 * sans at reading size, because unlike the headline it is a paragraph to be
 * read rather than a statement to be seen; and capped in measure, since at the
 * card's full width a two-line sentence under a 42px headline reads as a
 * subtitle rather than as prose. */
.lim-detail {
  margin-top: 10px;
  max-width: 52ch;
  font: 400 var(--fs-lg)/1.6 var(--sans);
  color: var(--t-body);
}
.lim-detail[hidden] { display: none; }

/* The countdown, directly under the headline. Mono micro-caps is what this
 * panel uses for a standing fact about time (.pw-resets, .usage-resets), and
 * repainted on its own 30s ticker so it never rebuilds the squares. */
.lim-resets {
  margin-top: 9px;
  font: 400 var(--fs-xs)/1.5 var(--mono); letter-spacing: .12em; text-transform: uppercase;
  color: var(--t-meta);
}

/* THE TWO SQUARES. Side by side when there is room and stacked when there is
 * not — in a docked side panel two columns would be ~150px each, which is
 * narrower than the feature list needs, so stacking is the honest default and
 * the two-column layout is what a wider window earns. Equal columns, because
 * neither square is subordinate: that is the whole point of the pairing.
 *
 * This is the scroller, not the card, so the headline and "I understand" stay
 * put while a long feature list moves — a dismiss that scrolls off the bottom
 * of a modal is how somebody ends up pressing Escape to find out whether it
 * works. */
.lim-grid {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-block: var(--scroll-pad);
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  align-content: start;
}
@media (min-width: 560px) {
  .lim-grid { grid-template-columns: 1fr 1fr; }
}
/* Nothing above them on the ladder, so there is no offer square. The
 * alternative takes the width rather than sitting beside a gap. */
.lim-solo .lim-grid { grid-template-columns: 1fr; }
.lim-solo .lim-offer-host { display: none; }

/* One square. The card ground and a rim spine, which is how this panel marks a
 * standing block of its own — the same pair .paywall carries, so the offer here
 * and the wall a free account meets elsewhere read as one component. */
.lim-card {
  height: 100%;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border-radius: var(--r-card);
  background: var(--s-card);
  box-shadow: var(--lit-card);
  border-left: 2px solid var(--rim);
}

/* The skeleton, while GET /plan is in flight on a sleeping Render instance.
 * It holds the grid open at roughly the offer's height so the alternative does
 * not jump sideways when the answer lands. No spinner: this is a second of
 * waiting inside a dialog that has already said everything urgent. */
.lim-wait { min-height: 190px; opacity: .5; box-shadow: none; border-left-color: transparent; }

.lim-card-title {
  font: 400 var(--fs-xl)/1.3 var(--serif);
  color: var(--t-primary);
}

/* The price, in the panel's mono, directly under the tier name. */
.lim-price {
  font: 500 var(--fs-sm)/1 var(--mono); letter-spacing: .08em;
  color: var(--t-secondary);
}

.lim-card-sub { font: 400 var(--fs-base)/1.5 var(--sans); color: var(--t-body); }

.lim-unlocks { margin: 4px 0 0; padding-left: 16px; }
.lim-unlocks li {
  font: 400 var(--fs-base)/1.5 var(--sans); color: var(--t-secondary); margin-bottom: 5px;
}
.lim-unlocks li::marker { color: var(--rim); }

/* Pinned to the bottom of the square, so the button sits on the same line as
 * the one beside it whatever the feature list does. */
.lim-card-foot { margin-top: auto; padding-top: 12px; }

/* The one loud control on this surface, and it has earned it: the wall's whole
 * purpose past the explanation is this button. Still not bone-filled — nothing
 * in this panel is any more — so it carries the interactive ground at full
 * width against a dismiss that is smaller, quieter and 9px of mono. It is
 * deliberately NOT added to the lit `:is()` lists in glass-surface.css: the
 * hierarchy inside this card is already unambiguous, and those lists are the
 * panel's global statement about what a primary control is. */
.lim-go {
  background: var(--s-inter); box-shadow: var(--lit-pill);
  font: 500 var(--fs-sm)/1 var(--mono); letter-spacing: .1em; text-transform: uppercase;
  color: var(--t-strong);
}
.lim-go:hover:not(:disabled) { background: rgba(var(--warm-rgb),.16); color: var(--bone); }
/* Disabled has to look deliberate rather than broken, with the reason spelled
 * out under it — the same treatment .pw-upgrade:disabled gets. */
.lim-go:disabled { color: var(--t-faint); cursor: not-allowed; }
.lim-soon { margin-top: 8px; font: 400 var(--fs-md)/1.45 var(--sans); color: var(--t-meta); }

/* The alternative. The instruction is the part that has to land from across the
 * room, so it takes the serif and the joke follows it in the quieter sans — one
 * paragraph, two voices, which is what the lines are written as.
 *
 * IT FILLS THE BOX, on request and for a reason worth keeping: the square beside
 * it is a priced feature list that ends where the list ends, and a single
 * sentence sitting at the top of an equal-sized card with air underneath read as
 * the lesser of the two options. `flex: 1` takes the slack off .lim-card's column
 * and the type goes up with it — at 13px the text filled about a third of the
 * height it had been given.
 *
 * Centred VERTICALLY rather than top-aligned, since a line that fills its box is
 * the box's content and not a label on it; the lines vary from one sentence to
 * four, and anchoring short ones to the top reopened the gap this closes. */
.lim-alt-body {
  flex: 1;
  display: flex; flex-direction: column; justify-content: center;
  font: 400 var(--fs-body)/1.65 var(--sans); color: var(--t-secondary);
}
.lim-alt-lead {
  font: 400 clamp(17px, 2.3vw, 21px)/1.35 var(--serif); color: var(--t-primary);
  letter-spacing: -.01em;
}
.lim-alt-rest { color: var(--t-body); }

/* "Off I go!" — the cheerful dismiss, in the alternatives square's own foot so it
 * lands on the upgrade button's baseline. .lim-go's geometry EXACTLY, because
 * that is what "aligned with" means here: same padding, same font, same radius,
 * full width. What differs is weight of light — the quiet ground and secondary
 * ink of a dismiss rather than the lit ground of the offer — so the two read as
 * a pair without this one competing for the press. */
.lim-off {
  background: var(--s-quiet); box-shadow: var(--lit-pill);
  /* The panel's button type at .lim-go's line height, so the box is the same. */
  font: 400 var(--fs-2xs)/11px var(--mono); letter-spacing: .18em; text-transform: uppercase;
  color: var(--t-secondary);
}
.lim-off:hover { background: rgba(var(--warm-rgb),.16); color: var(--bone); }

/* "I understand". Right-aligned, outside the scroller, and the quietest control
 * on the card: it acknowledges rather than does anything, and the offer beside
 * it is the action. */
.lim-foot { flex-shrink: 0; display: flex; justify-content: flex-end; }

/* Connectors (panel-connectors.js), after Claude's: a list of rows (logo,
   name over a one-line description or the connected state, a button on the
   right) and a connector's detail in its place. */
.set-row + #setConnectors { margin-top: 18px; }
.cn-list { display: flex; flex-direction: column; border-radius: var(--r-card); background: var(--s-card); box-shadow: var(--lit-card); overflow: hidden; }
/* THE NAME IS NEVER SQUEEZED OUT (F-020). The name and status keep at least
   150 px; when the buttons leave less (an expired row's Reconnect and
   Disconnect, a 320 px panel, 200% zoom) they wrap to a line of their own
   under the name, at the right, instead of taking the name's width. */
.cn-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 10px 10px 10px; }
.cn-row > .cn-main { flex: 1 1 150px; }
.cn-row > .cn-main + * { margin-left: auto; }
/* The row's buttons are one group, so an expired row's two move together. */
.cn-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; max-width: 100%; }
.cn-actions > .px-btn { max-width: 100%; }
.cn-row + .cn-row { border-top: 1px solid var(--hair); }
.cn-main {
  display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0;
  border: none; background: none; padding: 0; text-align: left; color: inherit; font: inherit; cursor: pointer;
}
.cn-row.is-soon .cn-main { cursor: default; }
.cn-row.is-soon .cn-name { color: var(--t-secondary); }
.cn-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
/* A service name wraps rather than being cut (F-035: raised text spacing cut
   "Google Calendar"); the line under it is the one that may ellipse. */
.cn-name { font: 500 var(--fs-lg)/1.25 var(--sans); color: var(--t-primary); overflow-wrap: anywhere; }
.cn-main:hover .cn-name { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--t-faint); }
.cn-row.is-soon .cn-main:hover .cn-name { text-decoration: none; }
.cn-sub { font: 400 var(--fs-md)/1.35 var(--sans); color: var(--t-meta); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.cn-on { color: var(--t-secondary); }
/* The dot is keyed to the state by colour AND shape (F-033): a filled dot in
   --ok for a working connection, a diamond in the warning light for one that
   needs the person (expired, revoked, rate limited, failing), a faint hollow
   ring for none. The words beside it say the state in every case. */
.cn-on::before { content: ""; display: inline-block; box-sizing: border-box; width: 7px; height: 7px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; }
.cn-on[data-state="ok"]::before { background: rgb(var(--ok-rgb)); }
.cn-on[data-state="warn"] { color: var(--warn-text); }
.cn-on[data-state="warn"]::before { border-radius: 1px; transform: rotate(45deg); background: rgb(var(--warn-rgb)); }
.cn-on[data-state="off"]::before { border: 1px solid var(--t-faint); }
.cn-soon { flex: none; font: 400 var(--fs-2xs)/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--t-faint); padding-right: 4px; }
.cn-heading { margin: 22px 0 8px; font: 400 var(--fs-2xs)/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--t-faint); }
/* Thirty-odd apps: a filter on top, then Connected and one section per kind. */
.cn-filter { width: 100%; margin: 0 0 4px; }
.cn-section[hidden], .cn-row[hidden], .cn-none[hidden] { display: none; }
.cn-none { margin: 16px 2px; font-size: var(--fs-sm); color: var(--t-secondary); }

.cn-back { margin-bottom: 18px; }
.cn-hero { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.cn-hero > .cn-text { flex: 1 1 150px; }
.cn-hero > .cn-text + * { margin-left: auto; }
.cn-title { font: 400 var(--fs-3xl)/1.2 var(--serif); color: var(--t-primary); }
.cn-hero .cn-sub { white-space: normal; overflow-wrap: anywhere; }
.cn-block { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--hair); }
.cn-k { font: 400 var(--fs-2xs)/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--t-faint); margin-bottom: 10px; }
.cn-access { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 7px; }
.cn-access li { position: relative; padding-left: 20px; font: 400 var(--fs-base)/1.45 var(--sans); color: var(--t-body); }
.cn-access li::before { content: "✓"; position: absolute; left: 2px; color: var(--t-meta); }
.cn-block .set-help a { color: var(--t-secondary); text-decoration: underline; text-underline-offset: 2px; }
.cn-block .set-help a:hover { color: var(--t-primary); }
.cn-form { display: flex; gap: 8px; align-items: center; }
.cn-form .set-input { flex: 1; min-width: 0; font-family: var(--mono); font-size: var(--fs-md); }
.cn-note:empty { display: none; }
.cn-foot { margin-top: 22px; font: 400 var(--fs-md)/1.5 var(--sans); color: var(--t-faint); }
.cn-foot a { color: var(--t-meta); text-decoration: underline; text-underline-offset: 2px; }

/* Episodes (memory step 3): the dated tier, collapsed under the files. */
.set-mem-episodes { margin-top:14px; }
.set-mem-episodes > summary { cursor:pointer; font:500 var(--fs-md)/1.5 var(--sans); color:var(--t-secondary); }
.set-mem-episodes > summary:focus-visible { outline:2px solid var(--focus, currentColor); outline-offset:2px; border-radius:var(--r-ctl-sm); }
.set-mem-episode { padding:8px 0; border-top:1px solid rgba(var(--warm-rgb),.08); }
.set-mem-episode-text { font:400 var(--fs-base)/1.5 var(--sans); color:var(--t-primary); overflow-wrap:anywhere; }
.set-mem-episode-meta { font:400 var(--fs-sm)/1.5 var(--sans); color:var(--t-meta); }
.set-mem-episode-actions { display:flex; flex-wrap:wrap; gap:6px; margin-top:4px; }

/* Settings → Notifications: the kinds, quieted while the master switch is off.
   The words step down a text token; the glass pills are left alone, because an
   opacity on their wrapper would flatten what their backdrop refracts (the same
   rule as a disabled button: quiet, not gone). Still clickable. */
.set-dim .set-label { color: var(--t-secondary); }
.set-dim .set-help { color: var(--t-faint); }
