/* Org admin -- the page parts org admin draws and the host portal doesn't.
 *
 * Loaded right after hosts_web/css/hosts_web.css (shared_web/assets.py, base.html), so these
 * rules keep the place in the cascade they had as that file's last part; the org_admin
 * split (docs/plans/org-admin-app-split.md) moved them here unchanged. The rules of the
 * design system (Design Standards -> Tokens) hold here as in hosts_web.css: every literal
 * is a token, siblings are spaced with gap, one breakpoint at 768px.
 */

/* Pathminder Admin's Home (org_admin/home.html; mockups/admin/screen-admin-home.html):
   each part after the key numbers is a section title over its list, 12px apart, 30px
   under what's above it (the page's 22px gap, and 8). The count beside the title is in
   the muted ink. */
.hp-orghome__part { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; }
.hp-orghome__title { margin: 0; font: var(--type-section) var(--font-display); color: var(--color-ink-strong); }
.hp-orghome__count { color: var(--color-ink-muted); }

/* A page head with one action on the H1's row, design-system's Record lists head
   (Settings › Users and permissions, org_admin/users.html;
   mockups/admin/screen-admin-members.html; app-designer's answer to Q77, f95f85d6): the
   kicker, 6px over the H1; the action at the row's end, centred on the H1, 22px clear of
   it; the line 9px under the row. On a phone the action is the page's width, 9px under
   the H1, and the line 9px under it. A grid, with the gaps as its own empty tracks, so
   each gap is the mock's and no sibling needs a margin. */
.hp-actionhead {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto var(--gap-glyph) auto var(--gap-chip) auto;
  grid-template-areas:
    "kicker kicker"
    ". ."
    "title action"
    ". ."
    "sub sub";
  column-gap: var(--gap-group);
  align-items: center;
}
.hp-actionhead__kicker { grid-area: kicker; }
.hp-actionhead__title { grid-area: title; margin: 0; min-width: 0; }
.hp-actionhead__action { grid-area: action; }
.hp-actionhead__sub { grid-area: sub; }

@media (max-width: 767px) {
  .hp-actionhead {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto var(--gap-glyph) auto var(--gap-chip) auto var(--gap-chip) auto;
    grid-template-areas:
      "kicker"
      "."
      "title"
      "."
      "action"
      "."
      "sub";
  }
}

/* A record page's tabs and their panel (A meeting, org_admin/meeting.html;
   mockups/admin/screen-admin-meeting.html): the tabs 22px under the head on a hairline the
   width of the page, the panel 22px under them, as the mock draws them. */
.hp-recordview { display: flex; flex-direction: column; gap: var(--gap-group); }
.hp-recordtabs { border-bottom: 1px solid var(--color-line-card); }

/* Settings › Branding's Preview (org_admin/_branding_preview.html;
   mockups/admin/screen-admin-settings-branding.html): a card, its title over the finder's
   navbar (in the organization's theme) and its scope labels, 16px under the page's line
   (the page's gap, and 6 less). The navbar keeps its place in the flow, never sticky. */
.hp-brandpreview {
  margin-top: calc(16px - var(--gap-group));
  background: var(--color-surface-card);
  border: 1px solid var(--color-line-card);
  border-radius: var(--radius-card);
}
.hp-brandpreview__title { margin: 0; padding: 18px 22px 12px; font: var(--type-card-title) var(--font-text); color: var(--color-ink-strong); }
.hp-brandpreview__frame { border-top: 1px solid var(--color-line-row); }
.hp-brandpreview__frame .pm-navbar { position: static; }
.hp-brandpreview__scopes { display: flex; flex-wrap: wrap; gap: var(--gap-chip); padding: 16px 22px 18px; }
@media (max-width: 767px) {
  .hp-brandpreview__title { padding: 18px 16px 12px; }
}
