/* Panel's lists, feed, people and the parts a place's page is made of, in the lobes' layer as all of Panel. Ported from
   pretorio-docs/design/components/pretorio.css, declaration by declaration, as base.css is: `.p-feed ol` is
   `.p-feed-list`, `.p-feed li` is `.p-feed-row`, `.p-event small` is `.p-event-sub`, and a switch, which the source
   draws as a button with `aria-checked`, is the checkbox itself, `.p-toggle`, drawn as the source draws its track. */

/* ---------- The other places, where the mock-ups lay the way back ---------- */
.p-crumbs { margin-bottom: calc(var(--s-5) * -1); min-width: 0; }
.p-crumbs-row { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-3); padding-bottom: var(--s-2); }
.p-crumbs-row .p-crumb--press { border: 0; background: transparent; padding: 0; margin: 0 0 0 -4px; color: var(--c-muted); font-size: var(--t-xs); font-weight: 550; cursor: pointer; }
.p-crumbs-row .p-crumb--press:hover { color: var(--c-ink); }
/* A row asleep (SCREEN-33): its words, quieter, and no press. */
.p-crumbs-row .p-crumb.p-muted { margin: 0; color: var(--c-faint) !important; cursor: default; }

/* ---------- Parts of a page, one under another ---------- */
.p-part + .p-part { margin-top: var(--s-5); }
/* A page of parts on a machine: the window lays the parts in a section of its own, and a list with the form its row
   opens in another under it. There each part keeps the reading width, a gutter, and half the gap above and below, so
   the gaps hold whichever section a part stands in. */
section > .p-part { width: 100%; max-width: calc(600px + 2 * var(--s-4)); margin-inline: auto; padding: calc(var(--s-5) / 2) var(--s-4); }
section > .p-part + .p-part { margin-top: 0; }

/* ---------- Showing data ---------- */
.p-feed { display: flex; flex-direction: column; gap: var(--s-3); }
.p-feed-head { font-size: var(--t-sm); font-weight: 600; }
.p-feed-list { padding: 6px 0; }
.p-feed-row { display: flex; justify-content: space-between; gap: var(--s-3); padding: 10px var(--s-4); animation: p-arrive .5s ease; }
.p-feed-row + .p-feed-row { box-shadow: 0 -1px 0 var(--c-hair); }
.p-feed-row strong { font-weight: 550; }
.p-feed-row > .p-st { flex: none; font-variant-numeric: tabular-nums; }
.p-event { display: flex; gap: var(--s-3); align-items: baseline; min-width: 0; line-height: 1.45; }
.p-event .p-led { transform: translateY(-2px); }
.p-event-sub { display: block; font-size: var(--t-xs); color: var(--c-muted); }
.p-avatar { width: 36px; height: 36px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--c-sunk); box-shadow: inset 0 0 0 1px var(--c-hair); color: var(--c-ink); font-size: 13px; font-weight: 600; letter-spacing: .01em; }
.p-avatar .p-icon { width: 18px; height: 18px; color: var(--c-muted); }
.p-badge { display: inline-flex; align-items: center; gap: 6px; min-height: 22px; padding: 0 9px; border-radius: var(--r-pill); background: var(--c-sunk); box-shadow: inset 0 0 0 1px var(--c-hair); font-size: 12px; font-weight: 550; color: var(--c-muted); white-space: nowrap; }
.p-badge--ok { color: var(--c-ok); background: color-mix(in srgb, var(--c-ok-glow) 10%, var(--c-module)); box-shadow: none; }
.p-badge--alert { color: var(--c-alert); background: color-mix(in srgb, var(--c-alert-glow) 10%, var(--c-module)); box-shadow: none; }
.p-badge--accent { background: var(--c-accent-soft); color: var(--c-accent); box-shadow: none; }
.p-lrow--press { cursor: pointer; }
.p-lrow--press:hover { background: var(--c-sunk); }
.p-lrow[aria-current] { background: var(--c-sunk); box-shadow: none; }
.p-lrow-open { display: flex; flex-direction: column; gap: var(--s-4); padding: var(--s-3) var(--s-4) var(--s-4); box-shadow: 0 1px 0 var(--c-hair); }
.p-lrow-open:last-child { box-shadow: none; }
.p-invoice { display: flex; flex-direction: column; gap: var(--s-3); min-width: 0; }
.p-invoice-title { font-weight: 600; }
.p-invoice + .p-btn { align-self: flex-start; }

/* ---------- Inputs ---------- */
.p-form { border: 0; margin: 0; min-inline-size: 0; }
.p-form:not(.p-mod) { padding: 0; }
.p-field > label { display: block; }
.p-field select { appearance: none; -webkit-appearance: none; padding-right: var(--s-6); background-image: linear-gradient(45deg, transparent 50%, var(--c-muted) 50%), linear-gradient(135deg, var(--c-muted) 50%, transparent 50%); background-position: calc(100% - 19px) 50%, calc(100% - 14px) 50%; background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; }
.p-switch { display: flex; justify-content: space-between; align-items: center; gap: var(--s-3); min-height: var(--press); width: 100%; border: 0; background: transparent; padding: 0; text-align: left; font-weight: 550; cursor: pointer; }
.p-switch small { display: block; margin-top: 2px; font-size: var(--t-xs); font-weight: 450; color: var(--c-muted); line-height: 1.45; }
.p-toggle { appearance: none; -webkit-appearance: none; flex: none; width: 40px; height: 24px; margin: 0; border-radius: var(--r-pill); background: var(--c-idle); position: relative; transition: background-color .2s; cursor: pointer; }
.p-toggle::after { content: ''; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(14,20,36,.25); transition: transform .2s cubic-bezier(.3,.7,.4,1); }
.p-toggle:checked { background: var(--c-accent); }
.p-toggle:checked::after { transform: translateX(16px); }

@keyframes p-arrive { from { opacity: 0; transform: translateY(-4px); } }

/* ---------- The line above a place (SCREEN-7) ----------
   One fold of Panel's at the head of an app, a place's page and the frame's bar: its press the three dots, under it a
   module that floats, the rows a press high, the fields each under its words with a sunk key beside, the themes a
   segmented choice, the language a fold of choices of one. Its root holds no container, so it stands in a row. */
.p-line-root { display: flex; justify-content: flex-end; color: var(--c-ink); font-style: normal; font-weight: 450; font-size: var(--t-sm); line-height: 1.45; font-family: var(--font-body); font-optical-sizing: auto; font-feature-settings: 'cv11', 'ss01'; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
.p-line-root *, .p-line-root *::before, .p-line-root *::after { box-sizing: border-box; }
.p-line { flex: none; }
.p-line > .p-fold-press { list-style: none; color: var(--c-muted); }
.p-line[open] > .p-fold-press { color: var(--c-ink); }
.p-line-panel { position: absolute; top: calc(100% + var(--s-2)); right: 0; z-index: 8; width: min(300px, calc(100vw - var(--s-5))); max-height: min(70vh, 560px); overflow-y: auto; display: grid; gap: var(--s-3); padding: var(--s-2); border-radius: var(--r-module); background: var(--c-module); box-shadow: inset 0 0 0 1px var(--c-hair), var(--c-float); animation: p-pop .16s ease-out; }
.p-line-rows { display: grid; gap: 2px; }
.p-line-row { min-height: var(--press); margin: 0; padding: 0 var(--s-3); display: flex; align-items: center; justify-content: space-between; gap: var(--s-2); border: 0; border-radius: var(--r-nub); background: transparent; color: var(--c-ink); font: inherit; font-weight: 500; text-align: left; text-decoration: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.p-line-row:hover { background: var(--c-sunk); }
.p-line-row > .p-icon { width: 18px; height: 18px; color: var(--c-faint); }
.p-line-panel .p-line-row--end { color: var(--c-alert); }
.p-line-panel .p-line-row--out { color: var(--c-accent); justify-content: flex-start; }
.p-line-domain { margin-left: auto; font-size: var(--t-xs); color: var(--c-muted); }
.p-line-field { margin: 0; padding: 0 var(--s-1); border: 0; min-width: 0; display: grid; gap: 6px; }
.p-line-label { font-size: var(--t-xs); font-weight: 550; color: var(--c-muted); }
.p-line-take { display: flex; gap: var(--s-2); min-width: 0; }
.p-line-input { flex: 1; min-width: 0; min-height: var(--press); margin: 0; padding: 0 var(--s-3); display: flex; align-items: center; justify-content: space-between; gap: var(--s-2); border: 0; border-radius: var(--r-inner); background: var(--c-module); color: var(--c-ink); box-shadow: inset 0 0 0 1px var(--c-hair-strong), var(--c-lift); font: inherit; font-weight: 450; cursor: text; }
.p-line-input:focus { outline: none; box-shadow: inset 0 0 0 1px var(--c-accent), 0 0 0 3px var(--c-accent-soft); }
.p-line-press { flex: none; width: var(--press); min-height: var(--press); margin: 0; padding: 0; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: var(--r-inner); background: var(--c-sunk); color: var(--c-ink); box-shadow: inset 0 0 0 1px var(--c-hair); cursor: pointer; -webkit-tap-highlight-color: transparent; }
.p-line-press:hover { background: color-mix(in srgb, var(--c-sunk) 90%, var(--c-ink)); }
.p-line-press > .p-icon { width: 18px; height: 18px; }
.p-line-fold { position: relative; flex: 1; min-width: 0; }
.p-line-fold > .p-line-input { list-style: none; cursor: pointer; }
.p-line-fold > .p-line-input::-webkit-details-marker { display: none; }
.p-line-fold > .p-line-input > .p-icon { width: 18px; height: 18px; color: var(--c-muted); }
.p-line-fold[open] > .p-line-input { box-shadow: inset 0 0 0 1px var(--c-accent), 0 0 0 3px var(--c-accent-soft); }
.p-line-choices { margin: var(--s-1) 0 0; padding: 4px; list-style: none; border-radius: var(--r-inner); background: var(--c-sunk); box-shadow: inset 0 0 0 1px var(--c-hair); }
.p-line-choice { min-height: 40px; padding: 0 var(--s-3); display: flex; align-items: center; gap: var(--s-3); border-radius: var(--r-nub); cursor: pointer; }
.p-line-choice:hover { background: var(--c-module); }
.p-line-radio { appearance: none; -webkit-appearance: none; flex: none; width: 18px; height: 18px; margin: 0; border-radius: 50%; background: var(--c-module); box-shadow: inset 0 0 0 1.5px var(--c-hair-strong); cursor: pointer; }
.p-line-radio:checked { box-shadow: inset 0 0 0 5px var(--c-accent); }
.p-line-radio:checked + span { font-weight: 550; }
.p-line-themes { display: flex; margin: 0 var(--s-1); }
.p-line-panel > .p-code { margin: 0 var(--s-1); }
.p-site { display: contents; }
.p-around-hold { position: fixed; top: max(var(--s-3), env(safe-area-inset-top, 0px)); right: max(var(--s-3), env(safe-area-inset-right, 0px)); z-index: 9; }
.p-around > .p-line > .p-fold-press { background: var(--c-module); box-shadow: inset 0 0 0 1px var(--c-hair), var(--c-lift); }
.p-around > .p-line > .p-fold-press:hover, .p-around > .p-line[open] > .p-fold-press { background: var(--c-sunk); }
.p-around-who { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2); padding: var(--s-1) var(--s-3) 0; min-width: 0; }
.p-around-name { font-weight: 550; overflow-wrap: anywhere; }
.p-around-places { padding-bottom: var(--s-2); box-shadow: inset 0 -1px 0 var(--c-hair); }

/* The head of an app and of a place's page: the way back at the start, the line at the end. */
.p-app-top { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s-3); min-width: 0; }
.p-app-top > :first-child { flex: 1; min-width: 0; }
.p-place-page { padding: var(--s-3) var(--s-4) 0; }
.p-place-page > .p-app-top { max-width: 600px; margin: 0 auto; }
/* A place's parts, each laid by the window in its slot, one column under the head's row, as a section of the window's
   holds them. */
.p-place-parts { margin: 0 calc(-1 * var(--s-4)); min-width: 0; }
.p-place-parts > .p-part { width: 100%; max-width: calc(600px + 2 * var(--s-4)); margin-inline: auto; padding: calc(var(--s-5) / 2) var(--s-4); }
.p-place-parts > .p-part + .p-part { margin-top: 0; }
.p-list--in { margin-left: var(--s-5); }
