/* The shared back office frame and pieces (crm-shell.js). Round 3: brain/builds/2026-10-24-ravn-back-office-mocks/round3-today.html.
   Every colour, the radius and both faces are --sh-* tokens. These defaults are round 3's "Ink, light"; a model's data-look /
   data-mode blocks set them (crm-appointments.css for Ravn). Flat: no shadows, glows, blurs or gradients; the selected row is grey.
   Rules sit under .sh-frame so they win over the model's own resets and never reach another screen. */
:root { --sh-bg: #fff; --sh-ground: #f4f4f2; --sh-ink: #121211; --sh-muted: #75756f; --sh-line: #e8e8e4; --sh-hover: #ececea;
  --sh-radius: 10px; --sh-display: serif; --sh-ui: system-ui, sans-serif; --sh-err: #8e2a17;
  --sh-mail-paper: #fefefe; --sh-mail-ink: #1b1b1a; }   /* walk 5: an email is light in every look, as it is sent */
/* the page kit's tokens (27 Oct, for Saltvig and KERNE): steps of the look's ink and panel, set on the frame so they follow a model's own
   --sh-ink and --sh-bg. A model's look block may set any of them (Ravn maps them to its own values in crm-appointments.css). */
.sh-frame { --sh-quiet: color-mix(in srgb, var(--sh-ink) 64%, var(--sh-bg)); --sh-rule: color-mix(in srgb, var(--sh-ink) 14%, transparent);
  --sh-rule-strong: color-mix(in srgb, var(--sh-ink) 28%, transparent); --sh-press: color-mix(in srgb, var(--sh-ink) 6%, transparent);
  --sh-track: color-mix(in srgb, var(--sh-ink) 8%, transparent); --sh-accent: var(--sh-ink); --sh-sel-bg: var(--sh-accent);
  --sh-sel-ink: var(--sh-bg); --sh-side: var(--sh-ground); }

.sh-frame { display: grid; grid-template-columns: 224px minmax(0, 1fr); min-height: 100vh; background: var(--sh-ground); color: var(--sh-ink); }
.sh-frame, .sh-frame *, .sh-frame *::before, .sh-frame *::after { box-sizing: border-box; }
.sh-frame .sh-i { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.sh-frame :focus-visible { outline: 2px solid var(--sh-ink); outline-offset: 2px; }

/* the sidebar, on the ground */
.sh-frame .sh-side { min-width: 0; }
.sh-frame .sh-side__in { position: sticky; top: 0; height: 100vh; min-height: 520px; display: flex; flex-direction: column; padding: 18px 12px 14px; }
.sh-frame .sh-brand { margin: 0; padding: 0 10px; min-height: 36px; display: flex; align-items: center; font: 700 25px/1 var(--sh-display); color: var(--sh-ink); overflow-wrap: anywhere; }
.sh-frame .sh-brand img { display: block; max-width: 180px; max-height: 44px; object-fit: contain; object-position: left center; }
.sh-frame .sh-nav { margin-top: 18px; display: grid; gap: 1px; }
.sh-frame .sh-nav__a { display: flex; align-items: center; gap: 10px; height: 32px; padding: 0 10px; border-radius: 7px; font: 500 14px/1 var(--sh-ui); color: color-mix(in srgb, var(--sh-ink) 80%, var(--sh-ground)); text-decoration: none; }
.sh-frame .sh-nav__a .sh-i { color: var(--sh-muted); }
.sh-frame .sh-nav__a:hover { background: color-mix(in srgb, var(--sh-hover) 60%, var(--sh-ground)); }
.sh-frame .sh-nav__a[aria-current] { background: var(--sh-hover); color: var(--sh-ink); }
.sh-frame .sh-nav__a[aria-current] .sh-i { color: var(--sh-ink); }
.sh-frame .sh-count { margin-left: auto; font: 500 12px/1 var(--sh-ui); font-style: normal; font-variant-numeric: tabular-nums; color: var(--sh-muted); }
.sh-frame .sh-side__foot { margin-top: auto; display: grid; gap: 10px; }
.sh-frame .sh-me { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; font: inherit; color: inherit; text-align: left; background: none; border: 0; border-radius: 8px; }
.sh-frame button.sh-me { cursor: pointer; }
.sh-frame button.sh-me:hover { background: color-mix(in srgb, var(--sh-hover) 60%, var(--sh-ground)); }
.sh-frame .sh-me__t { flex: 1; min-width: 0; }
.sh-frame .sh-me b { display: block; font: 600 13px/1.25 var(--sh-ui); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-me small { display: block; font: 400 12px/1.3 var(--sh-ui); color: var(--sh-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-me .sh-i { width: 14px; height: 14px; color: var(--sh-muted); }
.sh-frame .sh-made { margin: 0; padding: 0 10px; display: grid; font: 400 11.5px/1.5 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-made a { color: inherit; text-decoration: none; justify-self: start; }
.sh-frame .sh-made a:hover { color: var(--sh-ink); }
.sh-frame .sh-made a.sh-sig { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; } .sh-frame .sh-sig img { display: block; height: 13px; width: auto; }
.sh-frame[data-mode="dark"] .sh-sig img { filter: invert(1); }

/* Find a client: a quiet field under the brand, its matches in a list under it */
.sh-frame .sh-find { position: relative; margin: 14px 0 0; display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 8px 0 10px; color: var(--sh-muted); background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: 8px; }
.sh-frame .sh-find .sh-i { width: 14px; height: 14px; }
.sh-frame .sh-find input[type] { flex: 1; width: auto; min-width: 0; min-height: 0; height: 100%; padding: 0; font: 400 13px/1 var(--sh-ui); color: var(--sh-ink); background: none; border: 0; border-radius: 0; outline: 0; -webkit-appearance: none; appearance: none; }
.sh-frame .sh-find input::placeholder { color: var(--sh-muted); opacity: 1; }
.sh-frame .sh-find input::-webkit-search-cancel-button { display: none; }
.sh-frame .sh-find:focus-within { outline: 2px solid var(--sh-ink); outline-offset: 1px; }
.sh-frame .sh-find kbd { flex: none; padding: 0 5px; font: 500 11px/17px var(--sh-ui); color: var(--sh-muted); border: 1px solid var(--sh-line); border-radius: 4px; }
.sh-frame .sh-find:focus-within kbd { visibility: hidden; }
.sh-frame .sh-find__l { position: absolute; z-index: 20; top: calc(100% + 4px); left: 0; width: 280px; margin: 0; padding: 4px; display: grid; gap: 1px; list-style: none; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.sh-frame .sh-find__l[hidden] { display: none; }
.sh-frame .sh-find__o { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 6px 8px; border-radius: 7px; cursor: pointer; }
.sh-frame .sh-find__o:hover, .sh-frame .sh-find__o[aria-selected="true"] { background: var(--sh-hover); }
.sh-frame .sh-find__t { min-width: 0; display: grid; }
.sh-frame .sh-find__t b { font: 600 13px/1.3 var(--sh-ui); color: var(--sh-ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-find__t small { font: 400 12px/1.3 var(--sh-ui); color: var(--sh-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-find__none { padding: 10px 8px; font: 400 13px/1.3 var(--sh-ui); color: var(--sh-muted); }

/* the page: a white inset panel; the document scrolls, the sidebar stays */
.sh-frame .sh-panel { min-width: 0; min-height: calc(100vh - 16px); margin: 8px 8px 8px 0; display: flex; flex-direction: column; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: calc(var(--sh-radius) + 2px); overflow: clip; }
.sh-frame .sh-bar { flex: none; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; min-height: 54px; padding: 8px 20px; border-bottom: 1px solid var(--sh-line); }   /* polish 3: 54, the height with Studio's two-line note and Save, so the bar is one height on every tab (it was 52 or 53.4: a 1 px hop) */
.sh-frame .sh-bar__t { margin: 0; font: 600 14px/1.3 var(--sh-ui); color: var(--sh-ink); }
.sh-frame .sh-bar__sub { font: 400 14px/1.3 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-bar__end { margin-left: auto; display: flex; align-items: center; gap: 8px; min-width: 0; }
.sh-frame .sh-ptop, .sh-frame .sh-pfoot, .sh-frame .sh-tabs { display: none; }

/* menus: the person's (viewing as, sign out), and the phone's More */
/* ponytail: the native popover; a browser without it (Safari < 17) never opens the menus. Polish 2: the look sits on the menu itself, not
   only while it is open, so it keeps its own box while it closes (the browser's black square corners showed for a moment) */
.sh-frame .sh-menu { display: none; margin: 0; padding: 6px; min-width: 200px; gap: 1px; overflow: visible; color: var(--sh-ink); background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); font: 400 14px/1.4 var(--sh-ui); }
.sh-frame .sh-menu:popover-open { display: grid; height: max-content; align-content: start; }   /* iOS 18: without these it takes the window's height, and the rows share it out */
.sh-frame .sh-memenu { position: fixed; inset: auto auto 76px 12px; }
.sh-frame .sh-more { position: fixed; inset: auto 8px calc(72px + env(safe-area-inset-bottom)) auto; }
.sh-frame .sh-menu__a { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 12px; border-radius: 7px; color: inherit; text-decoration: none; }
.sh-frame .sh-menu__a .sh-i { color: var(--sh-muted); }
.sh-frame .sh-menu__a:hover, .sh-frame .sh-menu__a[aria-current] { background: var(--sh-hover); }
.sh-frame .sh-menu .sh-btn { width: 100%; height: 40px; justify-content: flex-start; }
.sh-frame .sh-menu .sh-btn[aria-current] { background: var(--sh-hover); }
.sh-frame .sh-menu__h { margin: 0; padding: 8px 12px 4px; font: 500 12px/1.3 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-menu__hr { margin: 5px 0; border: 0; border-top: 1px solid var(--sh-line); }
/* Ravn polish (26 Oct): the menus open from their button (fade and a short rise, a little scale), and close the same way back */
.sh-frame .sh-menu { opacity: 0; transform: translateY(6px) scale(0.97); transition: opacity 140ms ease, transform 180ms cubic-bezier(0.2, 0.9, 0.3, 1), overlay 180ms allow-discrete, display 180ms allow-discrete; }
.sh-frame .sh-menu:popover-open { opacity: 1; transform: none; }
@starting-style { .sh-frame .sh-menu:popover-open { opacity: 0; transform: translateY(6px) scale(0.97); } }
.sh-frame .sh-memenu { transform-origin: 24px 100%; min-width: 248px; }
.sh-frame :is(.sh-me, .sh-ptop__me).is-open { background: var(--sh-hover); }   /* the button stays pressed while its menu is open */
.sh-frame .sh-more { transform-origin: 100% 100%; }
/* a person in the menu: their face, their name over one quiet line, a tick on the one you're viewing as */
.sh-frame .sh-menu .sh-menu__p { height: auto; min-height: 48px; gap: 10px; padding: 6px 10px; font-weight: 400; text-align: left; }
.sh-frame .sh-menu__t { flex: 1; min-width: 0; display: grid; gap: 1px; }
.sh-frame .sh-menu__t b { font: 600 13.5px/1.25 var(--sh-ui); }
.sh-frame .sh-menu__t small { font: 400 12px/1.3 var(--sh-ui); color: var(--sh-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-menu__p > .sh-i { width: 16px; height: 16px; color: var(--sh-ink); }
.sh-frame .sh-menu .sh-btn:focus-visible { outline: none; background: var(--sh-hover); }

/* the pieces */
.sh-frame .sh-av { width: var(--sh-av, 32px); height: var(--sh-av, 32px); flex: none; display: inline-grid; place-items: center; object-fit: cover; border-radius: 50%; background: var(--sh-hover); color: var(--sh-ink); font: 600 calc(var(--sh-av, 32px) * 0.36)/1 var(--sh-ui); letter-spacing: 0.02em; }
.sh-frame .sh-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 34px; padding: 0 14px; font: 600 13.5px/1 var(--sh-ui); white-space: nowrap; text-decoration: none; border: 1px solid transparent; border-radius: 8px; cursor: pointer; }
.sh-frame .sh-btn .sh-i { width: 14px; height: 14px; }
.sh-frame .sh-btn--primary { color: var(--sh-bg); background: var(--sh-ink); }
.sh-frame .sh-btn--primary:hover { background: color-mix(in srgb, var(--sh-ink) 86%, var(--sh-bg)); }
.sh-frame .sh-btn--plain { color: var(--sh-ink); background: var(--sh-bg); border-color: color-mix(in srgb, var(--sh-ink) 16%, var(--sh-bg)); }
.sh-frame .sh-btn--quiet { padding: 0 10px; color: var(--sh-ink); background: none; }
.sh-frame :is(.sh-btn--plain, .sh-btn--quiet):hover { background: var(--sh-hover); }
.sh-frame .sh-btn:disabled { opacity: 0.5; cursor: progress; }
/* every control answers the hand: colours ease, a press sinks a little (Ravn polish) */
.sh-frame :is(.sh-btn, .sh-nav__a, .sh-menu__a, .sh-me, .sh-tab, .sh-row, .sh-card) { transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease, transform 120ms ease; }
.sh-frame .sh-btn:active:not(:disabled) { transform: scale(0.97); }
.sh-frame :is(.sh-nav__a, .sh-me):active { transform: scale(0.985); }
/* the full-screen sheet (a new booking): over everything, its own bar with Close; it slides up when it opens and down when it closes */
html.sh-locked { overflow: hidden; }
.sh-frame .sh-sheet { --sh-sheet-w: 1080px; position: fixed; inset: 0; z-index: 100; display: grid; grid-template-rows: auto minmax(0, 1fr); background: var(--sh-bg); color: var(--sh-ink); }
.sh-frame .sh-sheet.is-in { animation: sh-sheet-in 260ms cubic-bezier(0.2, 0.9, 0.3, 1); }
.sh-frame .sh-sheet.is-out { animation: sh-sheet-out 200ms cubic-bezier(0.4, 0, 1, 1) forwards; }
@keyframes sh-sheet-in { from { opacity: 0; transform: translateY(24px); } }
@keyframes sh-sheet-out { to { opacity: 0; transform: translateY(24px); } }
.sh-frame .sh-sheet__hd { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; padding: 10px max(24px, calc((100% - var(--sh-sheet-w)) / 2 + 24px)) 10px max(32px, calc((100% - var(--sh-sheet-w)) / 2 + 32px)); border-bottom: 1px solid var(--sh-line); }   /* the title lines up with the sheet's content (--sh-sheet-w, 1080 px; a wider sheet sets the variable) */
.sh-frame .sh-sheet__ht h2 { margin: 0; font: 600 17px/1.3 var(--sh-ui); }
.sh-frame .sh-sheet__ht p { margin: 2px 0 0; font: 400 13px/1.35 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-sheet__x { flex: none; width: 40px; height: 40px; padding: 0; border-radius: 10px; }   /* flex: none (27 Oct walk): a long title squeezed Close to 29 px, and to 18 with the demo switch's room on a phone */
.sh-frame .sh-sheet__x .sh-i { width: 18px; height: 18px; }
.sh-frame .sh-sheet__b { overflow-y: auto; overscroll-behavior: contain; }
/* a page or a detail that has just changed rises in */
.sh-frame .sh-enter { animation: sh-rise 220ms cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes sh-rise { from { opacity: 0; transform: translateY(4px); } }
/* something inside the same page (a settings tab's content, Today | All requests) fades: no movement, so nothing around it jumps */
.sh-frame .sh-fade { animation: sh-fade 180ms ease; }
@keyframes sh-fade { from { opacity: 0; } }
/* a scrollbar that comes and goes between a short and a long page would shift everything sideways; keep its room */
html:has(.sh-frame) { scrollbar-gutter: stable; }
/* the sidebar's current page: its grey slides to the page you open (glide) */
.sh-frame .sh-nav.sh-glides > .sh-glide { background: var(--sh-hover); border-radius: 7px; }
.sh-frame .sh-nav.sh-glides > .sh-nav__a[aria-current] { background: none; }
/* a card that opens presses in a little */
.sh-frame .sh-card.sh-click:active { transform: scale(0.99); }
/* the marker that slides under the pressed item of a switch, or the current tab */
.sh-frame .sh-glides { position: relative; isolation: isolate; }
.sh-frame .sh-glides > [data-l]::after { content: attr(data-l); display: block; height: 0; overflow: hidden; visibility: hidden; font-weight: 600; pointer-events: none; }
.sh-frame .sh-glide { position: absolute; top: 0; left: 0; z-index: -1; pointer-events: none; opacity: 0; transition: transform 240ms cubic-bezier(0.2, 0.9, 0.3, 1), width 240ms cubic-bezier(0.2, 0.9, 0.3, 1), height 240ms ease; }
.sh-frame .sh-open { max-width: 100%; margin: 0; padding: 0; font: inherit; color: inherit; text-align: left; background: none; border: 0; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-click { cursor: pointer; }

.sh-frame .sh-card { min-width: 0; display: flex; flex-direction: column; overflow: hidden; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.sh-frame .sh-card.sh-click:hover { border-color: color-mix(in srgb, var(--sh-ink) 16%, var(--sh-bg)); }
.sh-frame .sh-card__pic { display: block; width: 100%; height: 150px; object-fit: cover; background: var(--sh-hover); }
.sh-frame .sh-card__b { min-width: 0; display: grid; gap: 6px; padding: 14px 16px; }
.sh-frame .sh-card__t { min-width: 0; display: block; font: 600 15px/1.3 var(--sh-ui); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-card__k { margin: 0; display: flex; align-items: center; gap: 8px; font: 600 12.5px/1.3 var(--sh-ui); color: color-mix(in srgb, var(--sh-ink) 80%, var(--sh-bg)); }
.sh-frame .sh-card__k em { margin-left: auto; font-style: normal; font-weight: 500; color: var(--sh-muted); }
.sh-frame .sh-card__k .sh-i { width: 14px; height: 14px; }
.sh-frame .sh-card__hd { min-width: 0; display: flex; align-items: center; gap: 12px; }
.sh-frame .sh-card__ht { flex: 1; min-width: 0; display: grid; gap: 1px; }
.sh-frame .sh-card__hd .sh-card__sub { font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-card__end { flex: none; align-self: start; font-size: 12.5px; color: var(--sh-muted); font-variant-numeric: tabular-nums; }
.sh-frame .sh-card__foot { margin: 0; display: flex; align-items: center; gap: 7px; padding: 10px 16px; font-size: 12.5px; color: var(--sh-muted); border-top: 1px solid var(--sh-line); }
.sh-frame .sh-card__foot .sh-i { width: 14px; height: 14px; }
.sh-frame .sh-card__sub { margin: 0; font-size: 13px; color: var(--sh-muted); }
.sh-frame .sh-card__f { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding-top: 4px; }
.sh-frame .sh-meta { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; font-size: 13px; color: var(--sh-muted); }
.sh-frame .sh-meta > span { min-width: 0; display: inline-flex; align-items: center; gap: 6px; }
.sh-frame .sh-meta .sh-i { width: 14px; height: 14px; }

.sh-frame .sh-row { min-width: 0; display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px; }
.sh-frame .sh-row.sh-click:hover { background: var(--sh-hover-soft); }
.sh-frame .sh-row[aria-current] { background: var(--sh-hover); }
.sh-frame .sh-row__lead { flex: none; display: flex; }
.sh-frame .sh-row__m { flex: 1; min-width: 0; display: grid; gap: 1px; }
.sh-frame .sh-row__t { min-width: 0; display: block; font: 600 13.5px/1.3 var(--sh-ui); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-row__sub { font-size: 13px; color: var(--sh-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-row__end { flex: none; display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--sh-muted); }

.sh-frame .sh-band { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 10px 16px; font-size: 13.5px; color: var(--sh-muted); border: 1px dashed color-mix(in srgb, var(--sh-ink) 16%, var(--sh-bg)); border-radius: var(--sh-radius); }
.sh-frame .sh-band b { font-weight: 600; color: var(--sh-ink); }

/* figures and charts (Insights v2): a tile, a spark, a bar chart. Ink only; the gridlines are the hairline; text never wears the mark's colour */
.sh-frame .sh-tile { min-width: 0; display: grid; gap: 6px; align-content: start; padding: 16px 18px; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.sh-frame .sh-tile__l { margin: 0; font: 600 13px/1.3 var(--sh-ui); color: color-mix(in srgb, var(--sh-ink) 80%, var(--sh-bg)); }
.sh-frame .sh-tile__v { margin: 0; font: 600 30px/1.1 var(--sh-ui); letter-spacing: -0.015em; color: var(--sh-ink); white-space: nowrap; }
.sh-frame .sh-tile__c { margin: 0; display: flex; gap: 5px; font: 400 12.5px/1.35 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-tile__c b { font-weight: 600; color: var(--sh-ink); }
.sh-frame .sh-tile__c[data-dir="flat"] b { font-weight: 500; color: var(--sh-muted); }
.sh-frame .sh-tile__ar { font-weight: 600; color: var(--sh-ink); }
.sh-frame .sh-tile__s { margin: 0; font: 400 13px/1.4 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-spark { display: block; width: 100%; height: 28px; margin-top: 6px; overflow: visible; }
.sh-frame .sh-spark polyline { fill: none; stroke: var(--sh-ink); stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; }
.sh-frame .sh-bars { position: relative; width: 100%; height: 220px; }
.sh-frame .sh-bars__svg { position: absolute; top: 0; left: 0; display: block; overflow: visible; }   /* insights v3: the box sets the size, so the chart can grow with its card */
.sh-frame .sh-bars__grid { stroke: var(--sh-line); stroke-width: 1; }
.sh-frame .sh-bars__t { font: 400 11.5px var(--sh-ui); fill: var(--sh-muted); font-variant-numeric: tabular-nums; }
.sh-frame .sh-bars__bar { fill: var(--sh-ink); }
.sh-frame .sh-bars__hit { fill: transparent; }
.sh-frame .sh-bars, .sh-frame .sh-bars * { cursor: default; }   /* walk 2: a bar explains itself in its tooltip; nothing suggests a click it doesn't have */
.sh-frame .sh-bars__g:hover .sh-bars__bar, .sh-frame .sh-bars__g.is-on .sh-bars__bar { fill: var(--sh-muted); }
.sh-frame .sh-bars__g:focus { outline: none; }
.sh-frame .sh-bars__g:focus-visible .sh-bars__hit { stroke: var(--sh-ink); stroke-width: 1; }
/* insights v3: the bar's tooltip, flat (a hairline box, ink text; no shadow, no tint) */
.sh-frame .sh-tip { position: absolute; z-index: 2; display: grid; gap: 2px; width: max-content; max-width: 240px; padding: 8px 10px; font: 400 12.5px/1.4 var(--sh-ui); color: var(--sh-ink); background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); pointer-events: none; white-space: nowrap; }
.sh-frame .sh-tip[hidden] { display: none; }
.sh-frame .sh-tip b { font-weight: 600; }
.sh-frame .sh-tip span { color: var(--sh-muted); white-space: normal; }
.sh-frame .sh-tip span:nth-of-type(1) { color: var(--sh-ink); white-space: nowrap; }

/* the phone: the page fills the screen, the brand and the person on top, four tabs at the bottom */
@media (max-width: 900px) {
  .sh-frame { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; background: var(--sh-bg); padding-bottom: calc(72px + env(safe-area-inset-bottom)); }   /* the tab bar (65 px) never hides the end of the page */
  .sh-frame .sh-side { display: none; }
  .sh-frame .sh-ptop { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px 4px; }
  .sh-frame .sh-ptop .sh-brand { padding: 0; font-size: 24px; }
  .sh-frame .sh-ptop__me { display: flex; padding: 0; background: none; border: 0; border-radius: 50%; cursor: pointer; }
  .sh-frame .sh-panel { min-height: 0; margin: 0; border: 0; border-radius: 0; }
  .sh-frame .sh-bar { padding: 8px 16px; }
  .sh-frame .sh-pfoot { display: block; padding: 16px; border-top: 1px solid var(--sh-line); }
  .sh-frame .sh-pfoot .sh-made { padding: 0; justify-items: center; text-align: center; }
  .sh-frame .sh-pfoot .sh-made a { justify-self: center; }
  .sh-frame .sh-tabs { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 80; padding: 6px 8px max(8px, env(safe-area-inset-bottom)); background: var(--sh-bg); border-top: 1px solid var(--sh-line); }
  .sh-frame .sh-tab { display: grid; justify-items: center; align-content: center; gap: 3px; min-height: 50px; padding: 0; font: 500 11px/1.2 var(--sh-ui); color: var(--sh-muted); text-decoration: none; background: none; border: 0; cursor: pointer; }
  .sh-frame .sh-tab { position: relative; }
  .sh-frame .sh-tab .sh-i { width: 22px; height: 22px; }
  .sh-frame .sh-tab .sh-count { position: absolute; top: 3px; left: calc(50% + 7px); min-width: 16px; height: 16px; padding: 0 4px; display: grid; place-items: center; margin: 0; font: 600 10px/1 var(--sh-ui); color: var(--sh-bg); background: var(--sh-ink); border-radius: 8px; }
  .sh-frame .sh-tab[aria-current] { font-weight: 600; color: var(--sh-ink); }
  .sh-frame .sh-memenu { inset: 52px 12px auto auto; }
  .sh-frame .sh-menu { max-height: calc(100dvh - 140px); overflow-y: auto; overscroll-behavior: contain; }
  .sh-frame .sh-bars { height: 180px; }
  .sh-frame .sh-tile__v { font-size: 26px; }
}

/* reduced motion: everything still works, nothing moves */
@media (prefers-reduced-motion: reduce) {
  .sh-frame *, .sh-frame *::before, .sh-frame *::after { animation: none !important; transition-duration: 0ms !important; }
}

/* ---------- The page kit (27 Oct): the pieces every back office's pages draw with, moved here from crm-appointments.css so Saltvig
   (bookings) and KERNE (price estimates) use the same ones as Ravn. The class names keep their first name, ap- (they began in the
   appointments model); the rules and their order are Ravn's, on the --sh-* tokens. The base (links, headings, focus); pages (.ap-page);
   Settings: .ap-settings, .ap-tabs/.ap-stabs, .ap-set, .ap-hgrid/.ap-hcol/.ap-hcard, .ap-sf, .ap-seg, .ap-field, .ap-form, .ap-b,
   .ap-switch, .ap-box, .ap-list; Look: .ap-looks/.ap-live; Emails: .ap-ems/.ap-em; Insights v3: .ap-ins*, .ap-meter, .ap-flow, .ap-jr,
   .ap-adv, .ap-tbl, .ap-nr, .ap-wd. A model's page loads its own file after this one, so its rules win at equal weight. ---------- */
.sh-frame { font: 400 15px/1.5 var(--sh-ui); -webkit-font-smoothing: antialiased; }
.sh-frame *, .sh-frame *::before, .sh-frame *::after { box-sizing: border-box; }
.sh-frame a { color: inherit; }
.sh-frame :where(h1, h2, h3, h4, p, ul, ol, dl, dd, blockquote) { margin: 0; padding: 0; }
.sh-frame :where(ul, ol) { list-style: none; }
.sh-frame :where(h1, h2, h3, h4) { font-weight: 400; }
.sh-frame :focus-visible { outline: 2px solid var(--sh-ink); outline-offset: 2px; }
.sh-frame ::selection { background: var(--sh-ink); color: var(--sh-bg); }
.sh-frame .ap-data { font-family: var(--sh-ui); font-variant-numeric: tabular-nums; font-size: 0.92em; }
.ap-note { font-size: 13px; color: var(--sh-quiet); }
.ap-box { border: 1px solid var(--sh-rule-strong); background: var(--sh-bg); display: flex; flex-direction: column; min-width: 0; }
.ap-box__hd { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--sh-rule); font-size: 12px; font-weight: 700; }
.ap-box__r { font-family: var(--sh-ui); font-weight: 500; color: var(--sh-quiet); }
.ap-box__bd { padding: 18px; flex: 1; display: grid; gap: 14px; align-content: start; min-width: 0; }
.ap-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.sh-frame .ap-b { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; font: 700 14px/1 var(--sh-ui); letter-spacing: 0.03em; text-decoration: none; color: var(--sh-ink); background: transparent; border: 1.5px solid var(--sh-ink); border-radius: 0; cursor: pointer; }
.sh-frame .ap-b:hover { background: var(--sh-press); }
.sh-frame .ap-b--primary { background: var(--sh-ink); color: var(--sh-bg); }
.sh-frame .ap-b--primary:hover { background: color-mix(in srgb, var(--sh-ink) 82%, var(--sh-bg)); }
.sh-frame .ap-b--quiet { border-color: transparent; text-decoration: underline; text-underline-offset: 4px; padding: 0 8px; }
.sh-frame .ap-b--quiet:hover { background: transparent; }
.sh-frame .ap-b:disabled { opacity: 0.5; cursor: progress; }
.ap-msg { font-size: 14px; min-height: 0; }
.ap-msg:empty { display: none; }
.ap-msg.is-err { color: var(--sh-err); }
.ap-form { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px 16px; padding: 18px; border: 1px solid var(--sh-rule-strong); }
.ap-form__wide { grid-column: 1 / -1; }
.ap-field { display: grid; gap: 6px; min-width: 0; align-content: start; }
.ap-field__l { font-size: 12px; font-weight: 700; color: var(--sh-quiet); }
.sh-frame :is(input:not([type="checkbox"]), select, textarea) { width: 100%; min-height: 44px; padding: 8px 10px; font: 400 15px/1.4 var(--sh-ui); color: var(--sh-ink); background: var(--sh-bg); border: 1.5px solid var(--sh-ink); border-radius: 0; }
.sh-frame textarea { resize: vertical; }
.sh-frame :is(input, textarea):disabled { border-style: dashed; color: var(--sh-quiet); }
.ap-tabs { display: flex; gap: 28px; border-bottom: 1px solid var(--sh-rule-strong); overflow-x: auto; }
.ap-tabs a { padding: 12px 0; font-weight: 700; text-decoration: none; color: var(--sh-quiet); border-bottom: 3px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.ap-tabs a[aria-current] { color: var(--sh-ink); border-bottom-color: var(--sh-ink); }
.ap-page { padding: 24px 28px 40px; display: grid; gap: 20px; align-content: start; min-width: 0; }
.ap-form--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 0; border: 0; }
.ap-form--add { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; align-items: end; padding: 0; border: 0; }
.sh-frame .ap-switch { display: inline-flex; align-items: center; gap: 12px; min-height: 44px; padding: 0; font: 600 15px/1.3 var(--sh-ui); color: var(--sh-ink); background: none; border: 0; cursor: pointer; text-align: left; }
.ap-switch__k { position: relative; width: 44px; height: 24px; flex: none; border: 1.5px solid var(--sh-ink); background: var(--sh-bg); }
.ap-switch__k::after { content: ""; position: absolute; top: 3px; left: 3px; width: 15px; height: 15px; background: var(--sh-ink); transition: transform 120ms ease; }
.ap-switch[aria-checked="true"] .ap-switch__k { background: var(--sh-ink); }
.ap-switch[aria-checked="true"] .ap-switch__k::after { background: var(--sh-bg); transform: translateX(20px); }
@media (prefers-reduced-motion: reduce) {
  .ap-switch__k::after { transition: none; }
}
@media (max-width: 900px) {
  .ap-page { padding: 20px 16px 32px; }
  .ap-form--2, .ap-form--add { grid-template-columns: 1fr; }
  .ap-tabs { gap: 18px; }
  .ap-form { grid-template-columns: 1fr 1fr; }
  .ap-actions .ap-b { flex: 1 1 140px; }
  .ap-actions .ap-b--primary { flex-basis: 100%; }
}
@media (max-width: 420px) {
  .ap-form { grid-template-columns: 1fr; }
}
.ap-seg { display: inline-flex; border: 1.5px solid var(--sh-ink); }
.sh-frame .ap-seg__b { min-height: 36px; padding: 0 14px; font: 700 13px/1 var(--sh-ui); color: var(--sh-ink); background: var(--sh-bg); border: 0; border-right: 1px solid var(--sh-rule-strong); cursor: pointer; }
.sh-frame .ap-seg__b:last-child { border-right: 0; }
.sh-frame .ap-seg__b[aria-pressed="true"] { background: var(--sh-ink); color: var(--sh-bg); }
.ap-seg--full { display: grid; grid-template-columns: 1fr 1fr; }
.ap-page__hd { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.ap-looks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.sh-frame label.ap-b { position: relative; cursor: pointer; }
.sh-frame label.ap-b:focus-within { outline: 2px solid var(--sh-ink); outline-offset: 2px; }
@media (max-width: 900px) {
  .ap-form--slot { grid-template-columns: 1fr 1fr; }
  .ap-looks { grid-template-columns: 1fr 1fr; }
}
.ap-list { display: grid; overflow: hidden; border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.sh-frame .ap-list > .sh-row { padding: 12px 16px; border-radius: 0; }
.sh-frame .ap-list > .sh-row + .sh-row { border-top: 1px solid var(--sh-line); }
.sh-frame .ap-list .sh-btn { height: 30px; padding: 0 12px; font-size: 13px; }
.sh-frame .ap-b { min-height: 40px; padding: 0 16px; font: 600 14px/1 var(--sh-ui); letter-spacing: 0; border: 1px solid color-mix(in srgb, var(--sh-ink) 16%, var(--sh-bg)); border-radius: 8px; }
.sh-frame .ap-b--primary { border-color: var(--sh-ink); }
.sh-frame .ap-b--quiet { border-color: transparent; text-decoration: none; }
.sh-frame .ap-b--quiet:hover { background: var(--sh-press); }
.sh-frame :is(input:not([type="checkbox"]), select, textarea) { border: 1px solid color-mix(in srgb, var(--sh-ink) 20%, var(--sh-bg)); border-radius: 8px; }
.ap-box { border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.ap-box__hd { font-size: 13px; font-weight: 600; letter-spacing: 0; text-transform: none; border-bottom-color: var(--sh-line); }
.ap-field__l { font-size: 12.5px; font-weight: 500; letter-spacing: 0; text-transform: none; }
.ap-form { border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
@media (max-width: 900px) {
  .sh-frame .ap-b { min-height: 44px; }
}
.ap-seg { display: inline-flex; gap: 2px; padding: 2px; border: 1px solid var(--sh-line); border-radius: 9px; background: var(--sh-bg); }
.ap-seg.ap-seg--full { display: grid; grid-template-columns: 1fr 1fr; }
.sh-frame .ap-seg__b { min-height: 30px; padding: 0 12px; font: 500 13px/1 var(--sh-ui); color: var(--sh-muted); background: none; border: 0; border-radius: 7px; }
.sh-frame .ap-seg__b:hover { color: var(--sh-ink); }
.sh-frame .ap-seg__b[aria-pressed="true"] { color: var(--sh-ink); background: var(--sh-hover); font-weight: 600; }
.ap-tabs { gap: 24px; border-bottom: 0; box-shadow: inset 0 -1px var(--sh-line); overflow-y: hidden; overscroll-behavior-x: contain; scrollbar-width: none; }
.ap-tabs::-webkit-scrollbar { display: none; }
.ap-tabs a { padding: 10px 0; margin-bottom: 0; font-size: 14px; font-weight: 500; border-bottom-width: 2px; }
.ap-tabs a[aria-current] { font-weight: 600; }
.ap-form--slot { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ap-form__t { font-weight: 600; }
@media (max-width: 900px) {
  .ap-form--slot { grid-template-columns: 1fr 1fr; }
}
.ap-settings { gap: 0; padding-top: 12px; }
.ap-settings > .ap-note:first-child { padding: 12px 0 8px; }
.ap-set { min-width: 0; display: grid; gap: 16px; padding: 28px 0 32px; border-top: 1px solid var(--sh-line); }
.ap-settings > .ap-set:first-child, .ap-settings > .ap-note:first-child + .ap-set { border-top: 0; }
.ap-set__hd { display: grid; gap: 4px; }
.ap-set__hd h2 { font: 600 17px/1.3 var(--sh-ui); letter-spacing: -0.005em; }
.ap-set__hd .ap-note { max-width: 64ch; font-size: 14px; }
.ap-set__bd { min-width: 0; display: grid; gap: 14px; align-content: start; }
.ap-set__bd > .ap-form { padding: 20px; border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.ap-settings .ap-form { display: flex; flex-wrap: wrap; }
.ap-settings .ap-form > * { flex: 1 1 280px; min-width: 0; }
.ap-settings .ap-form > .ap-form__wide { flex-basis: 100%; }
.ap-settings .ap-field > .ap-note { max-width: 64ch; }
.ap-set__line { font-size: 14.5px; }
.ap-set__bd > :is(.ap-actions, .ap-seg) { display: flex; justify-self: start; }
.sh-frame .ap-switch__k { border: 1px solid color-mix(in srgb, var(--sh-ink) 24%, var(--sh-bg)); border-radius: 12px; background: var(--sh-hover); }
.sh-frame .ap-switch__k::after { top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: var(--sh-bg); }
.sh-frame .ap-switch[aria-checked="true"] .ap-switch__k { border-color: var(--sh-ink); background: var(--sh-ink); }
.ap-switch:not([aria-checked="true"]) .ap-switch__k::after { background: var(--sh-muted); }
.ap-looks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.ap-look { position: relative; min-width: 0; display: grid; gap: 10px; align-content: start; }
.ap-live { position: relative; overflow: hidden; aspect-ratio: var(--lw) / var(--lh); background: var(--sh-ground); border: 1px solid var(--sh-line); border-radius: 10px; }
.ap-live > .sh-frame { position: absolute; top: 0; left: 0; width: calc(var(--lw) * 1px); height: calc(var(--lh) * 1px); min-height: 0; grid-template-rows: minmax(0, 1fr); overflow: hidden; transform: scale(var(--k, 0.2)); transform-origin: 0 0; pointer-events: none; }
.ap-live .sh-frame .sh-side__in { position: static; height: 100%; min-height: 0; }
.ap-live .sh-frame .sh-panel { min-height: 0; }
.ap-look:hover .ap-live { border-color: color-mix(in srgb, var(--sh-ink) 28%, var(--sh-bg)); }
.ap-look:has(.ap-look__b[aria-pressed="true"]) .ap-live, .ap-look:has(.ap-look__b:focus-visible) .ap-live { outline: 2px solid var(--sh-ink); outline-offset: 2px; }
.sh-frame .ap-look__b { display: grid; gap: 1px; padding: 0 2px; font: inherit; text-align: left; color: var(--sh-ink); background: none; border: 0; cursor: pointer; }
.sh-frame .ap-look__b:focus-visible { outline: 0; }
.ap-look__b::before { content: ""; position: absolute; inset: 0; border-radius: 10px; }
.ap-look__b b { display: flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; }
.ap-look__b .ap-note { font-size: 13px; }
.ap-look__b .sh-i { width: 15px; height: 15px; }
@media (max-width: 900px) {
  .ap-settings { padding-top: 4px; }
  .ap-set { padding: 22px 0 26px; }
  .ap-set__bd > .ap-form { padding: 16px; }
  .ap-looks { grid-template-columns: 1fr 1fr; gap: 14px 12px; }
  .ap-live > .sh-frame { grid-template-rows: auto minmax(0, 1fr); }
}
.ap-settings > .ap-stabs { margin-top: 4px; }
.ap-stab { min-width: 0; display: grid; }
.ap-stab > .ap-set:first-child { border-top: 0; }
.ap-hgrid { min-width: 0; display: grid; gap: 16px; align-items: start; }
@media (min-width: 1240px) {
  .ap-hgrid { grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); }
}
.ap-hcol { min-width: 0; display: grid; gap: 16px; align-content: start; }
.ap-hcard { min-width: 0; display: grid; gap: 16px; align-content: start; padding: 20px 22px; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.ap-hcard__hd { display: grid; gap: 4px; }
.ap-hcard__t { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 30px; }
.ap-hcard h3 { font: 600 15px/1.3 var(--sh-ui); letter-spacing: -0.003em; }
.ap-hcard__hd .ap-note { max-width: 64ch; font-size: 13.5px; line-height: 1.5; }
.sh-frame .ap-hcard__t .sh-btn { height: 30px; padding: 0 10px; font-size: 13px; }
@media (max-width: 1239px) {
  .ap-hcol { display: contents; }
  .ap-hcard--wk { order: -2; }
}
@media (max-width: 900px) {
  .ap-hcard { padding: 16px; }
}
.ap-sf { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 16px; }
.ap-sf__w { grid-column: 1 / -1; min-width: 0; }
.ap-field__f { display: flex; justify-content: space-between; gap: 12px; }
.ap-count { margin-left: auto; font-size: 13px; color: var(--sh-muted); font-variant-numeric: tabular-nums; }
@media (max-width: 600px) {
  .ap-sf { grid-template-columns: 1fr; }
}
.ap-ems { display: grid; gap: 28px; }
.ap-em { min-width: 0; display: grid; gap: 10px; }
.ap-em__hd { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.ap-em__hd > div { min-width: 0; display: grid; gap: 2px; }
.ap-em__t { font: 600 15px/1.35 var(--sh-ui); }
.ap-em__hd .ap-note { font-size: 13.5px; }
.ap-em__hd .ap-b { flex: none; }
.ap-em__pv { min-width: 0; display: grid; gap: 8px; }
/* the mail window (Saltvig's, walk 3: every model's Settings › Emails, KERNE's too): from, to, subject, then the email in full, two to a row when wide */
.bk-ems { grid-template-columns: repeat(auto-fit, minmax(min(560px, 100%), 1fr)); gap: 28px 24px; align-items: start; }
.bk-mw { min-width: 0; border: 1px solid var(--sh-line); border-radius: var(--sh-radius); overflow: hidden; }
.bk-mw .bk-mw__hd { display: grid; padding: 4px 16px; border-bottom: 1px solid var(--sh-line); }
.bk-mw__hd > div { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 12px; padding: 7px 0; font-size: 13px; }
.bk-mw__hd > div + div { border-top: 1px solid var(--sh-line); }
.bk-mw__hd dt { color: var(--sh-muted); }
.bk-mw__hd dd { min-width: 0; color: var(--sh-ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bk-mw__hd dd b { font-weight: 600; }
.bk-mw__b .crm-mailpv { margin: 0; max-height: none; border: 0; border-radius: 0; }
.bk-ems > .ap-em:not(:has(.crm-mailpv)) { grid-column: 1 / -1; }
.ap-sent { font-size: 13px; color: var(--sh-ink); text-align: right; white-space: nowrap; }
.ap-sent--off { color: var(--sh-muted); }
@media (max-width: 900px) {
  .ap-ems { gap: 24px; }
  .ap-em__hd { flex-wrap: wrap; }
  .sh-frame .sh-row:has(.ap-sent) { flex-wrap: wrap; }
  .sh-frame .sh-row__end:has(.ap-sent) { flex-basis: 100%; padding-left: 52px; }
  .ap-sent { min-width: 0; white-space: normal; overflow-wrap: anywhere; text-align: left; }
}
.ap-seg__n { font-size: 11.5px; font-weight: 500; color: var(--sh-muted); font-variant-numeric: tabular-nums; }
.ap-ins { gap: 32px; }
.ap-ins__hd { display: grid; gap: 14px; }
.ap-ins__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr)); gap: 32px 40px; align-items: start; }
.ap-ins__col { display: grid; gap: 28px; align-content: start; }
.ap-ins__big { font: 600 48px/1.05 var(--sh-ui); letter-spacing: -0.02em; }
.ap-ins__rate { font-size: 14px; color: var(--sh-muted); }
.ap-meter { display: block; width: 100%; height: 6px; overflow: hidden; background: var(--sh-line); border-radius: 3px; }
.ap-meter i { display: block; height: 100%; background: var(--sh-ink); border-radius: 3px; }
.ap-ins__sec { display: grid; gap: 10px; }
.ap-ins__h { font: 600 13px/1.3 var(--sh-ui); color: color-mix(in srgb, var(--sh-ink) 80%, var(--sh-bg)); }
.sh-frame .ap-ins__row .sh-row__end { width: 300px; display: grid; grid-template-columns: minmax(0, 1fr) 44px; gap: 14px; }
.ap-ins__line { font-size: 15px; color: var(--sh-ink); font-variant-numeric: tabular-nums; }
.ap-ins__line b { font-weight: 600; }
.ap-ins__v { white-space: nowrap; }
.ap-ins__pct { text-align: right; font-weight: 600; color: var(--sh-ink); font-variant-numeric: tabular-nums; }
.ap-ins__n { font: 600 28px/1.15 var(--sh-ui); letter-spacing: -0.01em; }
.ap-ins__l { font-size: 13px; color: color-mix(in srgb, var(--sh-ink) 80%, var(--sh-bg)); }
.ap-flow { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.ap-flow__r { display: grid; grid-template-columns: minmax(0, 168px) minmax(0, 1fr) auto; align-items: center; gap: 14px; font-size: 14px; }
.ap-flow__l { color: var(--sh-ink); overflow-wrap: anywhere; }
.ap-flow__n { min-width: 2ch; text-align: right; font-weight: 600; color: var(--sh-ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
.ap-ins__pair { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 0; }
.ap-ins__pair dd { margin: 4px 0 0; font-variant-numeric: tabular-nums; }
.ap-ins__adv { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 15px; line-height: 1.45; color: var(--sh-ink); }
.ap-ins__help [data-prose] { max-width: 64ch; }
@media (max-width: 900px) {
  .ap-ins { gap: 26px; }
  .ap-ins__big { font-size: 34px; }
  .sh-frame .ap-ins__row .sh-row__end { width: 120px; grid-template-columns: minmax(0, 1fr) 36px; gap: 10px; }
  .sh-frame .ap-ins__row .sh-row__sub { white-space: normal; }
}
.ap-ins__top { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 12px 24px; }   /* walk 2: the switch keeps its place whatever the line's length */
.ap-ins__lead { display: grid; gap: 2px; }
.ap-ins__vs { font-size: 13px; color: var(--sh-ink); }
.ap-ins__tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.ap-ins__duo, .ap-ins__one { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; align-items: stretch; }
@media (min-width: 1240px) {
  .ap-ins__duo { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); }
}
@media (max-width: 1239px) {
  .ap-ins__tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .ap-ins__tiles { grid-template-columns: minmax(0, 1fr); }
}
.ap-ins__card { min-width: 0; display: flex; flex-direction: column; gap: 16px; padding: 18px 20px 20px; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.ap-ins__ch { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 8px 16px; }
.ap-ins__cht { display: grid; gap: 2px; min-width: 0; }
/* 27 Oct walk: a card head never reflows between states. From 601 px the title and its line take the room and the switch keeps its place on
   the right; on a phone the switch always has its own line under them (whatever the line's length); a line that changes is SH.ins.steady */
@media (min-width: 601px) {
  .ap-ins__ch { flex-wrap: nowrap; }
  .ap-ins__ch > .ap-ins__cht { flex: 1 1 auto; }
  .ap-ins__ch > :not(.ap-ins__cht) { flex: none; }
}
@media (max-width: 600px) {
  .ap-ins__ch > .ap-ins__cht { flex: 1 1 100%; }
}
.sh-steady { display: grid; }
.sh-steady > span { grid-area: 1 / 1; }
.ap-ins__card .ap-ins__h { font-size: 15px; color: var(--sh-ink); }
.ap-ins__chart { min-width: 0; flex: 1; display: flex; flex-direction: column; min-height: 220px; }
.ap-ins__chart > .sh-bars { flex: 1; height: auto; min-height: 220px; }
.ap-ins__card > .ap-ins__acts:last-child { margin-top: auto; }
.ap-ins__say { max-width: 70ch; font: 500 18px/1.4 var(--sh-ui); color: var(--sh-ink); text-wrap: pretty; }
.ap-ins__none { font-size: 15px; color: var(--sh-ink); }
.ap-ins__ansl { color: var(--sh-ink); }
.ap-ins__ans .ap-note { margin-top: 2px; font-size: 13px; }
.ap-ins__auto { padding-top: 4px; }
.ap-jrs { display: grid; gap: 14px; }
.ap-jr { display: grid; grid-template-columns: minmax(0, 88px) minmax(0, 1fr) 3ch 4ch; align-items: center; gap: 12px; font-size: 14px; }
.ap-jr .ap-meter { height: 10px; border-radius: 3px; }
.ap-jr__n { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.ap-jr__p { text-align: right; font-size: 13px; color: var(--sh-muted); font-variant-numeric: tabular-nums; }
.ap-ins__acts { display: grid; gap: 8px; }
.ap-ins__acts { gap: 0; border-top: 1px solid var(--sh-line); }
.ap-ins__act { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; min-height: 52px; padding: 8px 0; font-size: 14px; border-bottom: 1px solid var(--sh-line); }
.ap-ins__act:last-child { border-bottom: 0; padding-bottom: 0; }
.ap-ins__act:not(:has(button)) { color: var(--sh-muted); }
.ap-ins__adv { display: grid; border-top: 1px solid var(--sh-line); }
.ap-adv { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; min-height: 56px; padding: 10px 0; font-size: 15px; line-height: 1.45; color: var(--sh-ink); border-bottom: 1px solid var(--sh-line); }
.ap-adv:last-child { border-bottom: 0; padding-bottom: 0; }
.ap-adv p { max-width: 90ch; }
.ap-ins__style .ap-flow { flex: 1; align-content: space-between; }
.ap-ins__by .ap-tbl { flex: 1; }
.ap-wds { flex: 1; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.ap-wd { display: grid; grid-template-rows: auto minmax(120px, 1fr) auto; justify-items: center; gap: 8px; font-size: 13px; }
.ap-wd__d { color: var(--sh-muted); }
.ap-wd__bar { width: 100%; height: 100%; display: flex; align-items: flex-end; justify-content: center; }
.ap-wd__o { position: relative; width: min(100%, 36px); display: flex; align-items: flex-end; overflow: hidden; border: 1px solid var(--sh-rule-strong); border-radius: 4px; }
.ap-wd__o i { display: block; width: 100%; background: var(--sh-ink); }
.ap-wd__p { font-weight: 600; font-variant-numeric: tabular-nums; }
.ap-wd.is-closed .ap-wd__p { font-weight: 400; color: var(--sh-muted); }
.ap-tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.ap-tbl th { padding: 0 10px 8px; font-size: 12.5px; font-weight: 500; text-align: left; color: var(--sh-muted); border-bottom: 1px solid var(--sh-line); }
.ap-tbl td { padding: 10px; border-bottom: 1px solid var(--sh-line); font-variant-numeric: tabular-nums; }
.ap-tbl :is(th, td):first-child { padding-left: 0; }
.ap-tbl tr:last-child td { border-bottom: 0; }
.ap-tbl__r:hover td { background: var(--sh-hover-soft); }
.ap-tbl__who { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.ap-tbl__n { white-space: nowrap; }
.ap-tbl__use { display: grid; grid-template-columns: minmax(48px, 1fr) 4ch; align-items: center; gap: 10px; }
.ap-nr { display: block; width: 100%; height: 14px; }
.ap-nr__new { fill: var(--sh-rule-strong); }
.ap-nr__ret { fill: var(--sh-ink); }
.ap-nr__gap { stroke: var(--sh-bg); stroke-width: 2px; }
.ap-nr__sw--new { background: var(--sh-rule-strong); }
.ap-nr__sw--ret { background: var(--sh-ink); }
.ap-nr__key { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 14px; }
.ap-nr__key li { display: flex; align-items: center; gap: 8px; }
.ap-nr__key b { font-weight: 600; font-variant-numeric: tabular-nums; }
.ap-nr__sw { width: 10px; height: 10px; border-radius: 2px; }
.ap-nr__tr { display: grid; gap: 6px; }
.ap-ins__one .ap-nr__tr { max-width: 640px; }
.ap-nr__sp { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; }
.ap-nr__sp .sh-spark { margin: 0; }
.ap-nr__e { font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.ap-list.ap-ins__regs { border: 0; border-radius: 0; overflow: visible; }
.sh-frame .ap-ins__regs > .sh-row { padding: 8px 0; }
.ap-nr__reg { display: grid; gap: 2px; padding-top: 4px; }
@media (max-width: 900px) {
  .ap-ins__card { padding: 16px; }
  .ap-ins__top { grid-template-columns: minmax(0, 1fr); }
  .ap-ins__top .ap-seg { width: 100%; }
  .ap-ins__top .ap-seg__b { flex: 1; }
  .ap-tbl thead { display: none; }
  .ap-tbl, .ap-tbl tbody, .ap-tbl tr, .ap-tbl td { display: block; }
  .ap-tbl tr { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; padding: 10px 0; border-bottom: 1px solid var(--sh-line); }
  .ap-tbl tr:last-child { border-bottom: 0; }
  .ap-tbl td { padding: 0; border: 0; }
  .ap-tbl td:first-child { grid-column: 1 / -1; padding-bottom: 4px; }
  .ap-tbl td:last-child { grid-column: 1 / -1; }
  .ap-tbl td[data-th]::before { content: attr(data-th); display: block; margin-bottom: 2px; font-size: 12px; color: var(--sh-muted); }
  .ap-wds { gap: 3px; }
  .ap-wd { font-size: 12px; }
}
.ap-seg.sh-glides > .sh-glide { background: var(--sh-hover); border-radius: 7px; }
.sh-frame .ap-seg.sh-glides > .ap-seg__b[aria-pressed="true"] { background: none; }
.sh-frame .ap-seg__b { position: relative; transition: color 150ms ease; }
.ap-tabs.sh-glides > .sh-glide { box-sizing: border-box; border-bottom: 2px solid var(--sh-ink); }
.sh-frame .ap-tabs.sh-glides > a[aria-current] { border-bottom-color: transparent; }
.sh-frame .ap-tabs a { transition: color 150ms ease; }
@media (hover: hover) { .sh-frame .ap-tabs a:not([aria-current]):hover { color: var(--sh-ink); } }   /* 27 Oct walk (lane B): a tab answers the pointer, the text only (no fill) */
.sh-frame .ap-switch__k { transition: background-color 180ms ease, border-color 180ms ease; }
.sh-frame .ap-switch__k::after { transition: transform 220ms cubic-bezier(0.3, 0.9, 0.3, 1), background-color 180ms ease; }
.sh-frame .ap-switch:active .ap-switch__k::after { width: 19px; }
.sh-frame .ap-switch[aria-checked="true"]:active .ap-switch__k::after { transform: translateX(17px); }
.sh-frame :is(input:not([type=checkbox]):not([type=radio]):not([type=file]), select, textarea) { transition: border-color 150ms ease, background-color 150ms ease; }
.sh-frame .ap-live { transition: transform 160ms ease, outline-color 160ms ease; }
.sh-frame .ap-look:active .ap-live { transform: scale(0.985); }

/* ---------- Today's pieces and the demo switch (27 Oct, moved from crm-appointments.css when Saltvig's Today needed them; Ravn's values on
   the --sh-* tokens): a section with its heading and count (.ap-sec), a quiet line when a list is empty (.ap-quiet), a heading inside a list
   (.ap-sr__h), and where the demo's Guest/Customer | Owner switch (crm.js) sits. ---------- */
.ap-sec { min-width: 0; display: grid; gap: 10px; align-content: start; }
.ap-sec__hd { min-height: 28px; display: flex; align-items: center; gap: 8px; padding: 0 2px; font: 600 12.5px/1.3 var(--sh-ui); color: color-mix(in srgb, var(--sh-ink) 80%, var(--sh-bg)); }
.sh-frame .ap-sec__hd .sh-count { margin-left: 0; }
.sh-frame .ap-sec__hd .sh-btn { margin-left: auto; height: 28px; padding: 0 8px; font-size: 12.5px; font-weight: 500; color: var(--sh-muted); }
.sh-frame .ap-sec__hd .sh-btn:hover { color: var(--sh-ink); }
.ap-quiet { display: flex; align-items: center; gap: 8px; padding: 12px 16px; font-size: 13px; color: var(--sh-muted); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.ap-quiet .sh-i { width: 14px; height: 14px; }
.ap-sr__h { margin: 0; display: flex; align-items: center; gap: 8px; padding: 12px 16px 4px; font: 600 12.5px/1.3 var(--sh-ui); color: color-mix(in srgb, var(--sh-ink) 80%, var(--sh-bg)); }
.ap-sr__h:not(:first-child) { margin-top: 4px; border-top: 1px solid var(--sh-line); }
.ap-sr__h--new::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--sh-ink); }
.sh-frame .ap-sr__h .sh-count { margin-left: 0; }
.sh-frame .ap-list > .ap-sr__h + .sh-row { border-top: 0; }
/* the demo's switch: at the foot of the sidebar on the ground; on the phone in the top bar beside the avatar (it scrolls away with it); never
   over the page, the tabs or a sheet */
@media (min-width: 901px) {
  html:has(.sh-frame) .demo-pill { left: 12px; right: auto; bottom: 14px; }
  html:has(.demo-pill) .sh-frame .sh-side__in { padding-bottom: 70px; }
}
@media (max-width: 900px) {
  html:has(.sh-frame) .demo-pill { position: absolute; top: 9px; right: 58px; bottom: auto; }
  html:has(.sh-frame) .demo-pill a { min-height: 30px; padding: 0 11px; }
  /* the switch is out of the flow, so the name keeps its own room and wraps: a long name never slides under it */
  html:has(.demo-pill) .sh-frame .sh-ptop { min-height: 48px; }
  html:has(.demo-pill) .sh-frame .sh-ptop .sh-brand { max-width: calc(100vw - 222px); }
}
/* 27 Oct walk (Ravn's New booking → Cancel: the switch blinked away and back): it stays where it is, still and visible, while a sheet is
   open, over the sheet; the sheet's foot keeps its own left edge clear of it, and on the phone the sheet's title keeps clear of it */
html.sh-locked .demo-pill { z-index: 101; }
/* 27 Oct walk (lane B): in dark mode the switch is dark and flat too (it was a bright white pill): the panel's near-black, a hairline,
   the current side light as a dark page's primary button is */
html:has(#app > .sh-frame[data-mode="dark"]) .demo-pill { background: #161615; border-color: rgb(255 255 255 / 0.16); }
html:has(#app > .sh-frame[data-mode="dark"]) .demo-pill a { color: #d9d8d3; }
html:has(#app > .sh-frame[data-mode="dark"]) .demo-pill a[aria-current="page"] { background: #f0efeb; color: #121211; }
html:has(#app > .sh-frame[data-mode="dark"]) .demo-pill a:focus-visible { outline-color: #f0efeb; }
@media (min-width: 901px) {
  html:has(.demo-pill) .sh-sheet .ap-wi__ft { padding-left: max(0px, calc(176px - max(32px, (100vw - var(--sh-sheet-w)) / 2 + 32px))); }
}
/* on a phone the switch sits at the top right of the page (absolute, it scrolls away with the page); over a sheet it keeps that place,
   and the sheet's header makes a top row for it: Close at the right of that row, the title and its line under it at full width (27 Oct
   walk: "New booking" ran into the switch and the line was cut) */
@media (max-width: 900px) {
  html:has(.demo-pill) .sh-frame .sh-sheet__hd { position: relative; padding-top: 54px; }
  html:has(.demo-pill) .sh-frame .sh-sheet__x { position: absolute; top: 7px; right: 10px; }
  html:has(.demo-pill) .sh-frame .sh-sheet__ht { min-width: 0; padding-right: 0; }
}

/* ---------- A sheet's form (27 Oct, lifted from crm-appointments.css: Ravn's New booking, now every model's): steps, each its title on
   the left and its fields across the rest (.ap-wi__st, .ap-wi__f; .ap-wi__w spans the row); choices flat (.ap-wi__c, .ap-wi__t: a hairline,
   grey with an ink edge when pressed); the foot (.ap-wi__ft: a note, the actions, the line) sticky at the sheet's bottom. ---------- */
.ap-wi { min-width: 0; display: grid; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.ap-wi .ap-wi__hd { margin: 0; padding: 16px 22px; font: 600 15px/1.3 var(--sh-ui); border-bottom: 1px solid var(--sh-line); }
.ap-wi__st { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 12px 24px; padding: 18px 22px; border-bottom: 1px solid var(--sh-line); }
.ap-wi__st > h3 { margin: 0; font: 600 13.5px/1.3 var(--sh-ui); color: var(--sh-ink); }
.ap-wi__f { min-width: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 16px; }
.ap-wi__when { min-width: 0; display: grid; gap: 14px; }
.ap-wi__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ap-wi__ft2 { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 30px; }
.sh-frame .ap-wi__ft2 .sh-btn { height: 30px; font-size: 13px; }
.ap-wi__times { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; }
.sh-frame .ap-wi__c, .sh-frame .ap-wi__t { min-height: 38px; padding: 0 14px; font: 500 13.5px/1.2 var(--sh-ui); color: var(--sh-ink); background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: 8px; cursor: pointer; }
.sh-frame .ap-wi__t { min-height: 42px; text-align: left; font-variant-numeric: tabular-nums; }
@media (hover: hover) {
  .sh-frame .ap-wi__c:hover, .sh-frame .ap-wi__t:hover { background: var(--sh-hover); }
}
/* a tap on the phone leaves no grey behind */
.sh-frame .ap-wi__c[aria-pressed="true"], .sh-frame .ap-wi__t[aria-pressed="true"] { border-color: var(--sh-ink); background: var(--sh-hover); font-weight: 600; }
.ap-wi__pair { display: grid; grid-template-columns: repeat(2, minmax(0, 240px)); gap: 14px 16px; }
.ap-wi [hidden] { display: none; }
.ap-wi__fixed { margin: 0; min-height: 44px; display: flex; align-items: center; font-size: 15px; }
.ap-wi__ft { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; padding: 16px 22px; }
.ap-wi__ft > .ap-note { flex: 1 1 280px; margin: 0; }
.ap-wi__ft > .ap-msg { flex-basis: 100%; }
@media (max-width: 1000px) {
  .ap-wi__st { grid-template-columns: minmax(0, 1fr); }
  .ap-wi__f { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .ap-wi__f, .ap-wi__pair, .ap-wi__times { grid-template-columns: minmax(0, 1fr); }
  .ap-wi .ap-wi__hd, .ap-wi__st, .ap-wi__ft { padding-inline: 16px; }
  .ap-wi__ft > .ap-actions { width: 100%; }
}
.ap-wi__f > .ap-wi__w { grid-column: 1 / -1; }
.sh-frame :is(.ap-wi__c, .ap-wi__t) { transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease, transform 120ms ease; }
.sh-frame .ap-wi__c:active:not(:disabled) { transform: scale(0.97); }
.sh-frame .ap-wi__t:active { transform: scale(0.985); }
/* in the sheet: the form fills it at a reading width in the middle; the primary action stays at the foot */
.sh-sheet__b { display: flex; flex-direction: column; }
.sh-sheet .ap-wi { flex: 1; display: flex; flex-direction: column; width: 100%; max-width: var(--sh-sheet-w); margin: 0 auto; padding: 8px 32px 0; background: none; border: 0; border-radius: 0; }
.sh-sheet .ap-wi__st { grid-template-columns: 200px minmax(0, 1fr); gap: 14px 32px; padding: 28px 0; }
.sh-sheet .ap-wi__st > h3 { font-size: 15px; padding-top: 2px; }
.sh-sheet .ap-wi__st:last-of-type { border-bottom: 0; }
.sh-sheet .ap-wi__ft { position: sticky; bottom: 0; margin-top: auto; padding: 16px 0 20px; background: var(--sh-bg); border-top: 1px solid var(--sh-line); }
@media (max-width: 1000px) {
  .sh-sheet .ap-wi__st { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 22px 0; }
}
@media (max-width: 900px) {
  .sh-frame .sh-sheet__hd { min-height: 56px; padding: 8px 10px 8px 16px; padding-top: max(8px, env(safe-area-inset-top)); }
  .sh-sheet .ap-wi { padding: 0 16px; }
  .sh-sheet .ap-wi__ft { padding-bottom: max(16px, env(safe-area-inset-bottom)); }
}

/* ---------- One hover rule (27 Oct walk: a grey block on some free days and not others). Only what does something on a click gets a hover
   and the hand; every one of a kind gets the same; a hover never changes a size; with no mouse there is none (a tap leaves no grey).
   Two kinds: a row or a cell (a list row, a table row, a calendar day, a free time) takes --sh-hover-soft, the grey Ravn's rows use; a
   large area (a calendar lane or a free stretch of a day) takes --sh-hover-area, the faint wash Ravn's calendar lanes use. Mark them
   .sh-cell or .sh-area; a cell that can't be clicked (shut, taken) has neither. ---------- */
.sh-frame { --sh-hover-soft: color-mix(in srgb, var(--sh-hover) 55%, var(--sh-bg)); --sh-hover-area: color-mix(in srgb, var(--sh-ink) 2%, var(--sh-bg)); }
.sh-frame :is(.sh-cell, .sh-area) { cursor: pointer; transition: background-color 150ms ease; }
@media (hover: hover) {
  .sh-frame .sh-cell:hover { background: var(--sh-hover-soft); }
  .sh-frame .sh-area:hover { background: var(--sh-hover-area); }
}

/* ---------- The shell's own controls (27 Oct walk): SH.date, SH.dates, SH.time, SH.select, SH.check, SH.pick, SH.integrations; SH.liveSite
   draws the .ap-web window below. A trigger looks like the page's fields (44 px, a 1 px line, radius 8) with an icon before and a chevron
   after; its popover is the menu's box (a hairline, the panel colour, no shadow) and opens like it (a fade, a 4 px rise, 0.98 → 1, 160 ms).
   The chosen thing is ink; a range or the row under the pointer is the one hover grey. Nothing here changes size between states. ---------- */
.sh-frame { --sh-field: color-mix(in srgb, var(--sh-ink) 20%, var(--sh-bg)); }
.sh-ctlw { position: relative; display: inline-flex; min-width: 0; max-width: 100%; vertical-align: middle; }
.ap-field > .sh-ctlw, .ap-wi__f > .sh-ctlw, .ap-sf > .sh-ctlw { display: flex; width: 100%; }
.sh-frame .sh-ctl { position: relative; display: flex; align-items: center; gap: 9px; width: 100%; min-width: 0; min-height: 44px; margin: 0; padding: 0 12px; font: 400 15px/1.3 var(--sh-ui); color: var(--sh-ink); text-align: left; background: var(--sh-bg); border: 1px solid var(--sh-field); border-radius: 8px; cursor: pointer; transition: border-color 150ms ease, background-color 150ms ease; }
.sh-frame .sh-ctl > .sh-i { width: 16px; height: 16px; color: var(--sh-muted); }
.sh-frame .sh-ctl > .sh-i:last-child:not(:first-child) { margin-left: auto; }
@media (hover: hover) { .sh-frame .sh-ctl:hover { border-color: color-mix(in srgb, var(--sh-ink) 40%, var(--sh-bg)); } }
.sh-frame .sh-ctl.is-open, .sh-frame .sh-ctl:focus-within { border-color: var(--sh-ink); }
.sh-frame .sh-ctl:focus-visible { outline: 2px solid var(--sh-ink); outline-offset: 1px; }
.sh-frame .sh-ctl:disabled, .sh-frame .sh-ctlw.is-off .sh-ctl { color: var(--sh-muted); border-style: dashed; cursor: default; }
.sh-frame .sh-ctl__v { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-variant-numeric: tabular-nums; }
.sh-frame .sh-ctl__v.is-ph { color: var(--sh-muted); }
.sh-frame .sh-ctl__ar { flex: none; color: var(--sh-muted); }
.sh-frame .sh-ctl__n { flex: none; color: var(--sh-muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.sh-frame .sh-ctl__n[hidden], .sh-frame .sh-ctl__lead[hidden] { display: none; }
.sh-frame .sh-ctl__lead { display: flex; flex: none; }
.sh-frame .sh-ctl--sel .sh-ctl__v { flex: 1; }
.sh-frame .sh-ctl--sel > .sh-i:last-child { margin-left: 0; }
/* the time: a real text field inside the same box (typing works), the field's own border off */
.sh-frame .sh-ctl--time { cursor: text; }
.sh-frame .sh-ctl--time input.sh-ctl__in { flex: 1; width: 100%; min-width: 0; min-height: 0; height: 42px; padding: 0; font: 400 15px/1 var(--sh-ui); font-variant-numeric: tabular-nums; color: var(--sh-ink); background: none; border: 0; border-radius: 0; outline: 0; }

/* the popover box: on the element itself, so it keeps its box while it closes (polish 2) */
.sh-frame .sh-pop { position: fixed; inset: auto; margin: 0; padding: 6px; max-width: calc(100vw - 16px); max-height: min(420px, calc(100vh - 16px)); overflow: auto; overscroll-behavior: contain;
  color: var(--sh-ink); background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); font: 400 14px/1.4 var(--sh-ui);
  opacity: 0; transform: translateY(4px) scale(0.98); transition: opacity 110ms ease, transform 110ms ease, overlay 110ms allow-discrete, display 110ms allow-discrete; }
.sh-frame .sh-pop:popover-open { opacity: 1; transform: none; transition: opacity 140ms ease, transform 160ms cubic-bezier(0.23, 1, 0.32, 1), overlay 160ms allow-discrete, display 160ms allow-discrete; }   /* opens in 160 ms, closes quicker */
.sh-frame .sh-pop[data-instant] { transition: none; }
@starting-style { .sh-frame .sh-pop:popover-open:not([data-instant]) { opacity: 0; transform: translateY(4px) scale(0.98); } }
.sh-frame .sh-pop--cal { padding: 0; max-height: none; overflow: visible; }
.sh-frame .sh-pop--list { padding: 0; overflow: hidden; }

/* a list of choices (SH.select, SH.time): rows on the panel, the one under the pointer or the keys grey, the chosen one ticked */
.sh-frame .sh-lb { margin: 0; padding: 4px; display: grid; gap: 1px; max-height: min(320px, calc(100vh - 120px)); overflow-y: auto; overscroll-behavior: contain; list-style: none; outline: 0; }
.sh-frame .sh-lb__o { display: flex; align-items: center; gap: 10px; min-height: 38px; padding: 5px 10px; border-radius: 7px; cursor: pointer; user-select: none; }
.sh-frame .sh-lb__o.is-at { background: var(--sh-hover); }
.sh-frame .sh-lb:focus-visible .sh-lb__o.is-at { outline: 1px solid var(--sh-ink); outline-offset: -1px; }
.sh-frame .sh-lb__t { flex: 1; min-width: 0; display: grid; gap: 1px; font-variant-numeric: tabular-nums; }
.sh-frame .sh-lb__t b { font: 500 14px/1.3 var(--sh-ui); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-lb__t small { font: 400 12.5px/1.3 var(--sh-ui); color: var(--sh-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-lb__o > .sh-i { width: 15px; height: 15px; color: var(--sh-ink); visibility: hidden; }
.sh-frame .sh-lb__o[aria-selected="true"] > .sh-i { visibility: visible; }
.sh-frame .sh-lb__o[aria-selected="true"] .sh-lb__t b { font-weight: 600; }
.sh-frame .sh-lb__pic { width: 28px; height: 28px; flex: none; object-fit: cover; border-radius: 6px; background: var(--sh-ground); }
.sh-frame .sh-ctl .sh-lb__pic { width: 22px; height: 22px; border-radius: 5px; }
.sh-frame .sh-lb__gap { background: none; }
.sh-room { flex: none; pointer-events: none; }
.sh-frame .sh-dot { width: 9px; height: 9px; flex: none; margin: 0 2px; border-radius: 50%; background: var(--c, var(--sh-ink)); }

/* the calendar (SH.date, SH.dates): Airbnb's host calendar, flat. Round days 40 px; the chosen ink; a range a grey band; taken nights
   struck through; today a small dot. Two months side by side, arrows at the outer corners */
.sh-frame .sh-cal { position: relative; padding: 14px 16px 12px; }
.sh-frame .sh-cal__ms { display: grid; grid-auto-flow: column; grid-auto-columns: 280px; gap: 32px; }
.sh-frame .sh-cal__t { margin: 0; height: 32px; display: flex; align-items: center; justify-content: center; font: 600 14px/1 var(--sh-ui); }
.sh-frame .sh-cal__nav { position: absolute; top: 14px; width: 32px; height: 32px; padding: 0; border-radius: 8px; color: var(--sh-ink); }
.sh-frame .sh-cal__nav:first-child { left: 12px; }
.sh-frame .sh-cal__nav:nth-child(2) { right: 12px; }
.sh-frame .sh-cal__nav:disabled { opacity: 0.3; cursor: default; }
.sh-frame .sh-cal__g { margin-top: 8px; display: grid; }
.sh-frame .sh-cal__w, .sh-frame .sh-cal__r { display: grid; grid-template-columns: repeat(7, 40px); }
.sh-frame .sh-cal__w span { height: 28px; display: grid; place-items: center; font: 500 11.5px/1 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-cal__r { height: 40px; }
.sh-frame .sh-cal__d { position: relative; isolation: isolate; width: 40px; height: 40px; padding: 0; display: grid; place-items: center; font: 500 13.5px/1 var(--sh-ui); font-variant-numeric: tabular-nums; color: var(--sh-ink); background: none; border: 0; cursor: pointer; }
.sh-frame .sh-cal__d > span { position: relative; z-index: 1; }
.sh-frame .sh-cal__d::before { content: ""; position: absolute; inset: 2px; z-index: -1; border-radius: 50%; transition: background-color 120ms ease; }
@media (hover: hover) { .sh-frame .sh-cal__d:not([aria-disabled]):hover::before { background: var(--sh-hover-soft); } }
.sh-frame .sh-cal__d:focus { outline: 0; }
.sh-frame .sh-cal__d:focus-visible::before { outline: 2px solid var(--sh-ink); outline-offset: -1px; }
.sh-frame .sh-cal__d[aria-current="date"]::after { content: ""; position: absolute; bottom: 7px; left: 50%; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: currentColor; }
.sh-frame .sh-cal__d[aria-disabled] { color: color-mix(in srgb, var(--sh-ink) 30%, var(--sh-bg)); cursor: default; }
.sh-frame .sh-cal__d.is-tk > span, .sh-frame .sh-cal__lg s { text-decoration: line-through; text-decoration-thickness: 1px; }
.sh-frame .sh-cal__d.is-tk[aria-disabled] { color: color-mix(in srgb, var(--sh-ink) 38%, var(--sh-bg)); }   /* a taken night that can still be the departure stays ink, struck */
/* the band: full cell width between the ends, half a cell on the inner side of each end, so it runs without a gap */
.sh-frame .sh-cal__d.is-band { background: var(--sh-hover); }
.sh-frame .sh-cal__d.is-from { background: linear-gradient(to right, transparent 50%, var(--sh-hover) 50%); }
.sh-frame .sh-cal__d.is-to { background: linear-gradient(to left, transparent 50%, var(--sh-hover) 50%); }
.sh-frame .sh-cal__d[aria-selected="true"] { color: var(--sh-bg); }
.sh-frame .sh-cal__d[aria-selected="true"]::before { background: var(--sh-ink); }
.sh-frame .sh-cal__d[aria-selected="true"].is-tk { color: var(--sh-bg); }
.sh-frame .sh-cal__ft { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 36px; margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--sh-line); }
.sh-frame .sh-cal__st { margin: 0; font: 400 13px/1.35 var(--sh-ui); color: var(--sh-ink); font-variant-numeric: tabular-nums; }
.sh-frame .sh-cal__lg { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--sh-muted); white-space: nowrap; }
.sh-frame .sh-cal__lg[hidden] { display: none; }
.sh-frame .sh-cal__lg s { color: color-mix(in srgb, var(--sh-ink) 38%, var(--sh-bg)); font-variant-numeric: tabular-nums; }
/* a phone (≤ 600 px): the panel is docked to the screen's bottom, full width, rounded on top only, above the home bar (crm-shell.js
   place); it rises 12 px as it opens. Lists show more rows here. */
@media (max-width: 600px) {
  .sh-frame .sh-pop.is-up { max-width: none; max-height: min(78vh, calc(100vh - 96px)); padding-bottom: env(safe-area-inset-bottom); border-width: 1px 0 0; border-radius: 16px 16px 0 0; overflow: auto; transform: translateY(12px); }
  .sh-frame .sh-pop.is-up:popover-open { transform: none; }
  @starting-style { .sh-frame .sh-pop.is-up:popover-open:not([data-instant]) { opacity: 0; transform: translateY(12px); } }
  .sh-frame .sh-pop.is-up .sh-lb { max-height: min(56vh, 420px); padding: 8px; }
  .sh-frame .sh-pop.is-up .sh-lb__o { min-height: 46px; }
}
@media (max-width: 639px) {
  .sh-frame .sh-cal { padding: 12px 10px 10px; }
  .sh-frame .sh-cal__ms { grid-auto-columns: minmax(0, 1fr); }
  .sh-frame .sh-cal__w, .sh-frame .sh-cal__r { grid-template-columns: repeat(7, minmax(0, 1fr)); }
  .sh-frame .sh-cal__r { height: 44px; }
  .sh-frame .sh-cal__d { width: 100%; height: 44px; }
  .sh-frame .sh-cal__d::before { inset: 2px calc(50% - 20px); }
}

/* the check (SH.check): a rounded square; ticked, it fills with ink and the tick draws itself once (is-drawn) */
.sh-frame .sh-chk { display: inline-flex; align-items: flex-start; gap: 10px; min-height: 24px; margin: 0; padding: 0; font: inherit; color: var(--sh-ink); text-align: left; background: none; border: 0; cursor: pointer; }
.sh-frame .sh-chk__b { position: relative; width: 20px; height: 20px; flex: none; margin-top: 1px; display: grid; place-items: center; border: 1px solid var(--sh-field); border-radius: 6px; background: var(--sh-bg); transition: background-color 150ms ease, border-color 150ms ease, transform 120ms ease; }
.sh-frame .sh-chk__b svg { width: 14px; height: 14px; fill: none; stroke: var(--sh-bg); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; opacity: 0; }
.sh-frame .sh-chk__b path { stroke-dasharray: 16; stroke-dashoffset: 0; }
.sh-frame .sh-chk[aria-checked="true"] .sh-chk__b { background: var(--sh-ink); border-color: var(--sh-ink); }
.sh-frame .sh-chk[aria-checked="true"] .sh-chk__b svg { opacity: 1; }
.sh-frame .sh-chk.is-drawn .sh-chk__b path { animation: sh-tick 220ms cubic-bezier(0.3, 0.8, 0.3, 1) both; }
@keyframes sh-tick { from { stroke-dashoffset: 16; } }
@media (hover: hover) { .sh-frame .sh-chk:hover .sh-chk__b { border-color: color-mix(in srgb, var(--sh-ink) 45%, var(--sh-bg)); } }
.sh-frame .sh-chk:active .sh-chk__b { transform: scale(0.95); }
.sh-frame .sh-chk:focus-visible { outline: 0; }
.sh-frame .sh-chk:focus-visible .sh-chk__b { outline: 2px solid var(--sh-ink); outline-offset: 2px; }
.sh-frame .sh-chk:disabled { cursor: default; color: var(--sh-muted); }
.sh-frame .sh-chk__t { display: grid; gap: 2px; padding-top: 1px; }
@media (pointer: coarse) { .sh-frame .sh-chk { padding: 10px 0; } }   /* a finger-sized target on a phone (the box stays 20 px) */
.sh-frame .sh-chk__t b { font: 400 14.5px/1.4 var(--sh-ui); }
.sh-frame .sh-chk__t small { font: 400 13px/1.4 var(--sh-ui); color: var(--sh-muted); }

/* choosing with pictures (SH.pick): cards with a photo, or chips with a face; the round check on the right is empty until chosen */
.sh-frame .sh-pick { display: grid; gap: 12px; min-width: 0; }
.sh-frame .sh-pick--card { grid-template-columns: repeat(auto-fill, minmax(min(180px, 100%), 1fr)); }
.sh-frame .sh-pick--chip { display: flex; flex-wrap: wrap; gap: 8px; }
.sh-frame .sh-pick__i { position: relative; min-width: 0; margin: 0; padding: 0; font: inherit; color: var(--sh-ink); text-align: left; background: var(--sh-bg); border: 1px solid var(--sh-line); cursor: pointer; transition: border-color 150ms ease, background-color 150ms ease, transform 120ms ease; }
.sh-frame .sh-pick__t { min-width: 0; display: grid; gap: 1px; }
.sh-frame .sh-pick__t b { font: 600 14px/1.3 var(--sh-ui); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-pick__t small { font: 400 12.5px/1.35 var(--sh-ui); color: var(--sh-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-frame .sh-pick__k { width: 22px; height: 22px; flex: none; display: grid; place-items: center; color: var(--sh-bg); background: var(--sh-bg); border: 1px solid var(--sh-field); border-radius: 50%; transition: background-color 150ms ease, border-color 150ms ease; }
.sh-frame .sh-pick__k .sh-i { width: 13px; height: 13px; stroke-width: 2.2; opacity: 0; }
.sh-frame .sh-pick__i[aria-pressed="true"] .sh-pick__k { background: var(--sh-ink); border-color: var(--sh-ink); }
.sh-frame .sh-pick__i[aria-pressed="true"] .sh-pick__k .sh-i { opacity: 1; }
.sh-frame .sh-pick__i.is-drawn[aria-pressed="true"] .sh-pick__k path { stroke-dasharray: 24; animation: sh-tick2 220ms cubic-bezier(0.3, 0.8, 0.3, 1) both; }
@keyframes sh-tick2 { from { stroke-dashoffset: 24; } }
@media (hover: hover) { .sh-frame .sh-pick__i:hover { border-color: color-mix(in srgb, var(--sh-ink) 30%, var(--sh-bg)); } }
.sh-frame .sh-pick__i[aria-pressed="true"] { border-color: var(--sh-ink); }
.sh-frame .sh-pick__i:focus-visible { outline: 2px solid var(--sh-ink); outline-offset: 2px; }
.sh-frame .sh-pick--card .sh-pick__i { display: grid; gap: 10px; padding: 6px 6px 12px; border-radius: 12px; }
.sh-frame .sh-pick--card .sh-pick__i:active { transform: scale(0.985); }
.sh-frame .sh-pick--card .sh-pick__t { padding: 0 6px; }
.sh-frame .sh-pick__ph { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 8px; background: var(--sh-ground); }
.sh-frame .sh-pick__ph img { display: block; width: 100%; height: 100%; object-fit: cover; }
.sh-frame .sh-pick__ph .sh-pick__k { position: absolute; top: 8px; right: 8px; }
.sh-frame .sh-pick--chip .sh-pick__i { display: inline-flex; align-items: center; gap: 10px; min-height: 42px; padding: 5px 10px 5px 5px; border-radius: 999px; }
.sh-frame .sh-pick--chip .sh-pick__i:active { transform: scale(0.97); }
.sh-frame .sh-pick--chip .sh-pick__t b { font-size: 14px; font-weight: 500; }
.sh-frame .sh-pick--chip .sh-pick__i[aria-pressed="true"] .sh-pick__t b { font-weight: 600; }

/* Integrations (SH.integrations): Linear's settings rows. The tool's mark in a hairline square, what it does for you, its state on the right */
.sh-frame .sh-ints { margin: 0; padding: 0; display: grid; list-style: none; border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.sh-frame .sh-int { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; align-items: center; gap: 14px 16px; min-height: 72px; padding: 14px 18px; }
.sh-frame .sh-int + .sh-int { border-top: 1px solid var(--sh-line); }
.sh-frame .sh-int:has(> :nth-child(4)) { grid-template-columns: 40px minmax(0, 1fr) auto auto; }
.sh-frame .sh-int__m { width: 40px; height: 40px; display: grid; place-items: center; overflow: hidden; color: var(--sh-ink); background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: 9px; }
.sh-frame .sh-int__m .sh-i { width: 18px; height: 18px; }
.sh-frame .sh-int__m img { width: 24px; height: 24px; object-fit: contain; }
.sh-frame .sh-int__t { min-width: 0; display: grid; gap: 2px; }
.sh-frame .sh-int__t b { font: 600 14.5px/1.3 var(--sh-ui); }
.sh-frame .sh-int__t small { font: 400 13.5px/1.45 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-int__s { display: grid; justify-items: end; gap: 2px; text-align: right; }
.sh-frame .sh-int__st { display: inline-flex; align-items: center; gap: 7px; font: 500 13px/1.3 var(--sh-ui); color: var(--sh-muted); white-space: nowrap; }
.sh-frame .sh-int--connected .sh-int__st { color: var(--sh-ink); }
.sh-frame .sh-int__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--sh-ink); }
.sh-frame .sh-int__s small { font: 400 12.5px/1.3 var(--sh-ui); color: var(--sh-muted); }
@media (max-width: 600px) {
  .sh-frame .sh-int, .sh-frame .sh-int:has(> :nth-child(4)) { grid-template-columns: 40px minmax(0, 1fr); padding: 14px 16px; }
  .sh-frame .sh-int__s, .sh-frame .sh-int > :nth-child(4) { grid-column: 2; justify-items: start; justify-self: start; text-align: left; }
}

/* the live website (SH.liveSite; Ravn's Settings › Studio, polish 3): a plain browser window (grey dots, the address) around the real site,
   scaled to the card; it fades in once the site says it's ready */
.ap-web .ap-hcard__t { flex-wrap: wrap; }
.ap-web__ctl { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.sh-frame .ap-web__ctl .ap-b { min-height: 34px; padding: 0 12px; font-size: 13px; }
.ap-web { overflow: hidden; padding-bottom: 0; }
.ap-web__win { min-width: 0; margin: 0 -22px; border-top: 1px solid var(--sh-line); }
.ap-web__bar { display: flex; align-items: center; gap: 14px; height: 38px; padding: 0 6px 0 14px; border-bottom: 1px solid var(--sh-line); }
.ap-web__dots { display: flex; gap: 6px; }
.ap-web__dots i { width: 9px; height: 9px; border-radius: 50%; background: color-mix(in srgb, var(--sh-ink) 16%, var(--sh-bg)); }
.ap-web__url { min-width: 0; flex: 1; overflow: hidden; padding: 4px 12px; font-size: 12.5px; color: var(--sh-muted); white-space: nowrap; text-overflow: ellipsis; background: var(--sh-ground); border-radius: 6px; }
.ap-web__view { position: relative; display: grid; justify-items: center; background: var(--sh-ground); }
.ap-web__view[data-mode="mobile"] { padding: 20px 0; }
.ap-web__wait { position: absolute; inset: 0; display: grid; place-items: center; font-size: 13px; color: var(--sh-muted); }
.ap-web__stage { position: relative; overflow: hidden; width: calc(var(--fw, 1280) * var(--k, 0.4) * 1px); height: calc(var(--fh, 800) * var(--k, 0.4) * 1px); }
.ap-web__view[data-mode="mobile"] .ap-web__stage { border: 1px solid var(--sh-line); border-radius: 18px; }
.ap-web__stage iframe { position: absolute; top: 0; left: 0; width: calc(var(--fw, 1280) * 1px); height: calc(var(--fh, 800) * 1px); border: 0; background: var(--sh-bg); transform: scale(var(--k, 0.4)); transform-origin: 0 0; visibility: hidden; opacity: 0; transition: opacity 260ms ease; }
.ap-web__stage[data-ready] iframe { visibility: visible; opacity: 1; }
@media (max-width: 900px) {
  .ap-web__win { margin: 0 -16px; }
}

/* a number field: no spinner arrows (the keys still step it); the browser's own control, flat (27 Oct walk) */
.sh-frame input[type="number"] { -moz-appearance: textfield; appearance: textfield; }
.sh-frame input[type="number"]::-webkit-inner-spin-button, .sh-frame input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }

/* ---------- What happened (walk 2, lifted from Saltvig's enquiry, crm-bookings.css; SH.tl): one row per step on hairlines, a dot (filled:
   done, a ring: still to come, grey: skipped), who in a quiet word, what, when and how it stands; an email opens under its row. ---------- */
.sh-tl { display: grid; margin: 0; padding: 0; list-style: none; }
.sh-tl__i { position: relative; display: grid; grid-template-columns: 14px minmax(0, 1fr); gap: 12px; padding: 10px 0; border-top: 1px solid var(--sh-line); }
.sh-tl__i:first-child { border-top: 0; padding-top: 2px; }
.sh-tl__dot { width: 8px; height: 8px; margin-top: 6px; border-radius: 50%; background: var(--sh-ink); }
.sh-tl__i.is-todo .sh-tl__dot { background: none; box-shadow: inset 0 0 0 1.5px var(--sh-ink); }
.sh-tl__i.is-skip .sh-tl__dot { background: var(--sh-line); }
.sh-tl__b { min-width: 0; display: grid; gap: 4px; }
.sh-tl__h { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; margin: 0; }
.sh-tl__who { flex: none; min-width: 72px; font: 500 12.5px/1.4 var(--sh-ui); color: var(--sh-muted); }
.sh-tl__x { flex: 1 1 200px; min-width: 0; font: 600 14px/1.4 var(--sh-ui); color: var(--sh-ink); }
.sh-tl__i.is-skip .sh-tl__x, .sh-tl__i.is-todo .sh-tl__x { font-weight: 500; color: color-mix(in srgb, var(--sh-ink) 72%, var(--sh-bg)); }
.sh-tl__m { flex: none; display: inline-flex; gap: 10px; margin-left: auto; font-size: 12.5px; color: var(--sh-muted); font-variant-numeric: tabular-nums; }
.sh-tl__st { color: var(--sh-ink); font-weight: 500; }
.sh-tl__i.is-skip .sh-tl__st, .sh-tl__i.is-todo .sh-tl__st { color: var(--sh-muted); }
.sh-tl__d { max-width: 72ch; margin: 0; font-size: 13.5px; color: color-mix(in srgb, var(--sh-ink) 80%, var(--sh-bg)); }
.sh-tl__d > summary { cursor: pointer; font-size: 13.5px; color: var(--sh-ink); }
.sh-tl__full { margin-top: 10px; }
.sh-tl__i .ap-actions { margin-top: 2px; }
.sh-tl__more { padding: 8px 0 0 26px; border-top: 1px solid var(--sh-line); }

/* walk 2 (Qasim: "you see half the mail and can't scroll"): an email preview reads in full, wherever it is shown; the page scrolls, never a box */
.sh-frame :is(.crm-mailpv, .wf-mailpv) { max-height: none; overflow-x: auto; }

/* walk 5 (28 Oct): Settings › Emails as a studio (SH.studio). One email at a time: the bar, the writer beside the email itself, Recent emails.
   Flat and calm: hairlines, the look's own ink and radius, no tints, glows or shadows. The email is drawn by the kit (light, as it is sent). */
.sh-es { container-type: inline-size; min-width: 0; display: grid; gap: 16px; }
.sh-es__bar { position: relative; z-index: 4; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; min-height: 62px; padding: 10px 12px; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.sh-es__pick { flex: 0 1 280px; min-width: 210px; }
.sh-es__pick .sh-ctl { width: 100%; }
.sh-es__meta { min-width: 0; display: flex; align-items: center; gap: 4px 14px; flex-wrap: wrap; }
.sh-es__auto { min-width: 0; display: flex; align-items: center; gap: 8px; margin: 0; font-size: 13.5px; color: var(--sh-muted); }
.sh-es__auto b { font-weight: 500; color: var(--sh-ink); white-space: nowrap; }
.sh-es__dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--sh-ink); }
.sh-es__dot.is-off { background: none; border: 1.5px solid var(--sh-rule-strong); }
.sh-es__sep { width: 1px; height: 16px; flex: none; background: var(--sh-line); }
.sh-frame .sh-es__when { min-width: 0; display: inline-flex; align-items: center; gap: 4px; height: 30px; padding: 0 6px; margin-left: -6px; font: 400 13.5px/1.2 var(--sh-ui); color: var(--sh-muted); text-align: left; background: none; border: 0; border-radius: 6px; cursor: pointer; transition: color 150ms ease, background-color 150ms ease; }
.sh-frame .sh-es__when .sh-i { width: 13px; height: 13px; opacity: 0.7; }
.sh-frame .sh-es__when:hover { color: var(--sh-ink); background: var(--sh-hover); }
.sh-frame .sh-es__when--plain { cursor: default; }
.sh-frame .sh-es__when--plain:hover { color: var(--sh-muted); background: none; }
.sh-es__acts { margin-left: auto; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.sh-es__dirty { display: inline-flex; align-items: center; gap: 7px; padding-right: 4px; font-size: 13px; color: var(--sh-muted); white-space: nowrap; }
.sh-es__dirty i { width: 7px; height: 7px; border-radius: 50%; background: var(--sh-ink); }
.sh-es__dirty[hidden], .sh-frame .sh-es__acts .sh-btn[hidden] { display: none; }
.sh-frame .sh-es__acts .sh-btn { height: 36px; }
.sh-frame .sh-es__save:disabled { opacity: 1; color: var(--sh-muted); background: var(--sh-track); cursor: default; }   /* nothing to save: a calm track, not a faded slab */
.sh-frame .sh-es__st { margin: -6px 2px 0; font-size: 13.5px; color: var(--sh-muted); }
.sh-es__st:empty { display: none; }
.sh-es__st.is-err { color: var(--sh-err); }
.sh-es__cols { min-width: 0; display: grid; gap: 16px; align-items: start; }
@container (min-width: 940px) {
  .sh-es__cols { grid-template-columns: minmax(340px, 5fr) minmax(0, 7fr); gap: 16px; }
  .sh-es__l { position: sticky; top: var(--es-top, 16px); }   /* the writer follows the email; the bar stays put (Qasim, 28 Oct). A tall column scrolls to its foot, then stays */
}
/* the writer */
.sh-es__l { min-width: 0; display: grid; gap: 10px; }
.sh-es__card { min-width: 0; display: grid; gap: 16px; padding: 20px; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.sh-es__lh { display: grid; gap: 4px; }
.sh-es__k { margin: 0; font: 600 11.5px/1.3 var(--sh-ui); letter-spacing: 0.06em; text-transform: uppercase; color: var(--sh-muted); }
.sh-es__lh h3 { margin: 2px 0 0; font: 600 18px/1.25 var(--sh-ui); letter-spacing: -0.01em; }
.sh-es__ai { display: grid; gap: 8px; padding: 12px 12px 10px 14px; border: 1px solid var(--sh-rule-strong); border-radius: var(--sh-radius); transition: border-color 150ms ease; }
.sh-es__ai:focus-within { border-color: var(--sh-ink); }
.sh-es__al { font: 500 12.5px/1.3 var(--sh-ui); color: var(--sh-muted); }
.sh-frame .sh-es__ai textarea { min-height: 70px; padding: 0; font-size: 15px; line-height: 1.5; background: none; border: 0; border-radius: 0; resize: none; outline: 0; }
.sh-es__af { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.sh-es__n { font: 400 12px/1 var(--sh-ui); font-variant-numeric: tabular-nums; color: var(--sh-muted); }
.sh-frame .sh-es__go { height: 38px; padding: 0 16px; }
.sh-es__tv, .sh-es__ed { border-top: 1px solid var(--sh-line); }
.sh-es__tvh, .sh-es__edh { width: 100%; min-height: 48px; display: flex; align-items: center; gap: 10px; padding: 12px 0 0; font: 600 14px/1.3 var(--sh-ui); color: var(--sh-ink); text-align: left; background: none; border: 0; cursor: pointer; }
.sh-es__tvh .sh-i:last-child, .sh-es__edh .sh-i:last-child { margin-left: auto; color: var(--sh-muted); transition: transform 180ms cubic-bezier(0.23, 1, 0.32, 1); }
.sh-es__tvh[aria-expanded="true"] .sh-i:last-child, .sh-es__edh[aria-expanded="true"] .sh-i:last-child { transform: rotate(180deg); }
.sh-es__edh .sh-i:first-child { color: var(--sh-muted); }
.sh-es__tsum { margin-left: auto; min-width: 0; font-weight: 400; font-size: 13px; color: var(--sh-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sh-es__tsum + .sh-i { margin-left: 0 !important; }
.sh-es__tvb, .sh-es__edb { display: grid; gap: 14px; padding: 14px 0 4px; }
.sh-es__tvb[hidden], .sh-es__edb[hidden], .sh-es__srow[hidden], .sh-es__line[hidden] { display: none; }
.sh-es__tone.ap-seg { display: grid; grid-template-columns: repeat(auto-fit, minmax(104px, 1fr)); }
.sh-frame .sh-es__tone .ap-seg__b { min-height: 34px; white-space: nowrap; }
.sh-frame .sh-es__voice, .sh-frame .sh-es__sample { min-height: 0; line-height: 1.5; resize: vertical; }
.sh-frame .sh-es__adds { justify-self: start; height: 32px; padding: 0 8px 0 4px; font-weight: 500; color: var(--sh-muted); }
.sh-frame .sh-es__adds:hover { color: var(--sh-ink); }
.sh-es__line { display: flex; align-items: center; gap: 9px; min-height: 44px; padding: 6px 6px 6px 12px; font-size: 13.5px; color: var(--sh-ink); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); }
.sh-es__line > span { flex: 1; min-width: 0; }
.sh-es__line .sh-i { color: var(--sh-ink); }
.sh-es__line.is-err { color: var(--sh-err); border-color: color-mix(in srgb, var(--sh-err) 40%, var(--sh-bg)); }
.sh-frame .sh-es__undo { height: 32px; text-decoration: underline; text-underline-offset: 3px; }
.sh-es__more { display: flex; gap: 8px; }
.sh-frame .sh-es__more input { flex: 1; min-width: 0; min-height: 42px; }
.sh-frame .sh-es__mb { width: 42px; height: 42px; padding: 0; flex: none; }
.sh-frame .sh-es__mb:has(> :not(svg)) { width: auto; padding: 0 14px; }
.sh-es__mf { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.sh-frame .sh-es__chip { height: 28px; padding: 0 9px; font: 500 12.5px/1 var(--sh-ui); color: var(--sh-ink); background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: 6px; cursor: pointer; transition: border-color 150ms ease, transform 120ms ease; }
.sh-frame .sh-es__chip:hover { border-color: var(--sh-rule-strong); }
.sh-frame .sh-es__chip:active { transform: scale(0.97); }
.sh-frame .sh-es__std { justify-self: start; height: 32px; padding: 0 4px; font-weight: 500; color: var(--sh-muted); text-decoration: underline; text-underline-offset: 3px; }
.sh-frame .sh-es__edb textarea { line-height: 1.5; }
.sh-es__live { padding: 0 2px; }
.sh-es__locked { gap: 8px; }
.sh-es__locked p:last-child { font-size: 14.5px; line-height: 1.55; color: var(--sh-ink); }
/* the email, as it is sent */
.sh-es__pv { min-width: 0; display: grid; grid-template-rows: auto auto 1fr; background: var(--sh-bg); border: 1px solid var(--sh-line); border-radius: var(--sh-radius); overflow: hidden; }
.sh-es__pvh { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 12px 12px 20px; }
.sh-es__pvh h3 { font: 600 15px/1.3 var(--sh-ui); }
.sh-es__pvc { display: flex; align-items: center; gap: 6px; }
.sh-frame .sh-es__full { width: 34px; padding: 0; }
.sh-frame .sh-es__sl { display: flex; gap: 12px; align-items: baseline; min-width: 0; padding: 11px 20px; font-size: 13.5px; border-top: 1px solid var(--sh-line); border-bottom: 1px solid var(--sh-line); }
.sh-es__sl span { flex: none; color: var(--sh-muted); }
.sh-es__subj { min-width: 0; font-weight: 600; overflow-wrap: anywhere; }
.sh-es__stage { min-width: 0; display: flex; justify-content: center; align-items: flex-start; padding: 24px 20px 28px; background: color-mix(in srgb, var(--sh-ink) 4%, var(--sh-bg)); }   /* the panel, a step down: --sh-ground is a model's sidebar (KERNE's is dark) */
.sh-es__mail { width: 100%; max-width: 680px; min-width: 0; background: var(--sh-mail-paper); border: 1px solid transparent; border-radius: min(var(--sh-radius), 8px); overflow: hidden; }   /* the stage's edge frames it; the kit draws its own card */
.sh-es__stage[data-mode="mobile"] .sh-es__mail { width: 375px; max-width: 100%; border-radius: 22px; border-color: var(--sh-rule-strong); }
.sh-frame .sh-es__mail :is(.crm-mailpv, .wf-mailpv) { display: block; margin: 0; max-height: none; border: 0; border-radius: 0; }
.sh-es__mail > :is(.wf-pv__text, .crm-muted, .crm-fine, .ap-note) { margin: 0; padding: 20px; font-size: 14px; white-space: pre-wrap; color: var(--sh-mail-ink); }
.sh-es__mail.is-new { animation: sh-es-new 260ms cubic-bezier(0.23, 1, 0.32, 1); }
@keyframes sh-es-new { from { opacity: 0.35; } }
/* Recent emails, and the full list in View history */
.sh-es__recent { gap: 8px; }
.sh-es__tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
@media (min-width: 601px) { .sh-es__tbl :is(th, td):first-child { width: 48%; } .sh-es__tbl :is(th, td):nth-child(2) { width: 26%; } }
.sh-es__tbl th { padding: 6px 12px 8px 0; font: 500 12.5px/1.3 var(--sh-ui); color: var(--sh-muted); text-align: left; border-bottom: 1px solid var(--sh-line); }
.sh-es__tbl td { padding: 10px 12px 10px 0; border-bottom: 1px solid var(--sh-line); vertical-align: middle; }
.sh-es__tbl tbody tr:last-child td { border-bottom: 0; }
.sh-es__wh { display: flex; align-items: center; gap: 10px; min-width: 0; }   /* in a wrapper: a flex cell leaves the table, and its hairline stops short */
.sh-es__wt { min-width: 0; display: flex; align-items: baseline; gap: 4px 12px; flex-wrap: wrap; }
.sh-es__wt b { font-weight: 600; }
.sh-es__wt small { font-size: 13px; color: var(--sh-muted); overflow-wrap: anywhere; }
.sh-es__at { white-space: nowrap; font-variant-numeric: tabular-nums; color: var(--sh-quiet); }
.sh-es__ok span { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.sh-es__ok i { width: 7px; height: 7px; border-radius: 50%; background: var(--sh-ink); }
.sh-es__tbl :is(th, td):last-child { padding-right: 0; width: 1%; }
.sh-es__hb { width: min(100% - 48px, 1032px); margin: 24px auto 40px; display: grid; gap: 16px; }
.sh-es__hf { display: flex; align-items: center; gap: 12px; }
.sh-es__hf .sh-ctlw { min-width: 260px; }
.sh-es__hl { display: grid; gap: 8px; }
.sh-es__fullb { display: grid; grid-template-rows: auto 1fr; min-height: 100%; background: color-mix(in srgb, var(--sh-ink) 4%, var(--sh-bg)); }
.sh-es__fullc { display: flex; justify-content: center; padding: 14px 16px 0; }
.sh-es__stage--full { padding: 20px 16px 48px; }
@media (max-width: 900px) {
  .sh-es__pick { flex: 1 1 100%; }
  .sh-es__acts { margin-left: 0; width: 100%; justify-content: flex-start; }
  .sh-es__acts .sh-es__save { margin-left: auto; }
}
@media (max-width: 600px) {
  .sh-es__bar { padding: 12px; }
  .sh-es__card { padding: 16px; }
  .sh-es__stage { padding: 16px 10px 20px; }
  .sh-es__pvh { padding: 12px 12px 12px 16px; }
  .sh-frame .sh-es__sl { padding: 10px 16px; }
  .sh-es__tbl thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .sh-es__tbl tr { display: grid; grid-template-columns: max-content minmax(0, 1fr) auto; gap: 2px 0; padding: 10px 0; border-bottom: 1px solid var(--sh-line); }
  .sh-es__tbl tbody tr:last-child { border-bottom: 0; }
  .sh-es__tbl td { padding: 0; border: 0; }
  .sh-es__who { grid-column: 1 / 3; }
  .sh-es__ok { grid-column: 3; grid-row: 1; align-self: center; }
  .sh-es__what, .sh-es__at { grid-row: 2; font-size: 13px; color: var(--sh-muted); }
  .sh-es__what { grid-column: 1; padding-left: 38px !important; }
  .sh-es__at { grid-column: 2 / 4; }
  .sh-es__at::before { content: "·"; margin: 0 6px; }
  .sh-es__hb { width: calc(100% - 32px); margin-top: 16px; }
  .sh-es__hf .sh-ctlw { min-width: 0; flex: 1; }
}
.ap-set--emails > .ap-set__bd { display: grid; gap: 28px; }
