/*
 * /staff back-office styles (real-life#74, spec 20.2). Plain CSS served by
 * Propshaft, loaded with application.css by `stylesheet_link_tag :app`.
 * Reuses the brand variables defined in application.css.
 */

:root {
  --staff-success-bg: #eef4e6;
  --staff-success-ink: #2f4a1a;
  --staff-success-edge: #c9deb3;
  --staff-error-bg: #fdecec;
  --staff-error-ink: #9b1c1c;
  --staff-info-bg: #e8f0fb;
  --staff-info-ink: #1d4a85;
  --staff-warning-bg: #fdf3e1;
  --staff-warning-ink: #7a4b00;
  --staff-focus: #1c2b12;
}

.staff-header {
  /* The church's header color; what sits on it is white on a dark one and
     near black on a light one (--church-on-header, real-life#196). */
  background: var(--church-header, #304b3b);
  border-bottom: 1px solid var(--church-header-edge, #263c2f);
  color: var(--church-on-header, #fff);
}

.staff-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 16px;
  min-height: 64px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.staff-header__title {
  order: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  min-width: 0;
}

.staff-header__brand {
  display: block;
  height: 40px;
  width: auto;
}

/* With no logo, the church's name. */
.staff-header__brand--text {
  height: auto;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 40px;
  white-space: nowrap;
}

/* A tinted logo (real-life#196): the span is filled with the text color
   around it and the logo is its mask, so one file fits any header. The
   image inside is not seen; it gives the span its width and its name. */
.staff-logo-tint {
  display: inline-block;
  background-color: currentColor;
  -webkit-mask: var(--logo) center / contain no-repeat;
  mask: var(--logo) center / contain no-repeat;
}

.staff-logo-tint img {
  display: block;
  height: 100%;
  width: auto;
  opacity: 0;
}

.staff-header__label {
  background: var(--brand);
  color: var(--brand-ink);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 2px 10px;
  border-radius: 999px;
}

.staff-header__sign-out {
  margin: 0;
}

/* The account menu (owner, 21 November 2026): the avatar and first name
   are a button that opens a menu with the full name and Sign out. */
.staff-account {
  position: relative;
}

.staff-account__toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 4px 10px 4px 4px;
  border-radius: 999px;
  cursor: pointer;
  list-style: none;
}

.staff-account__toggle::-webkit-details-marker {
  display: none;
}

.staff-account__toggle:hover,
.staff-account[open] > .staff-account__toggle {
  background: color-mix(in srgb, var(--church-on-header, #fff) 14%, transparent);
}

.staff-account[open] .staff-nav__chevron {
  transform: rotate(180deg);
}

.staff-account__menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 50;
  min-width: 220px;
  padding: 6px;
  background: var(--surface);
  color: var(--ink);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
}

.staff-account__who {
  margin: 0;
  padding: 10px 12px 6px;
  font-weight: 700;
}

.staff-account__item {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.staff-account__item:hover {
  background: var(--canvas);
}

.staff-main {
  padding: 24px 0 72px; /* 48px top until 21 November 2026, then tightened twice (owner) */
}

.staff-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1.2;
  padding: 0 18px;
  min-height: 44px;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
}

.staff-button:disabled {
  opacity: 0.5;
  cursor: default;
}

/* CTA buttons: the secondary green, white text (theme, November 2026). */
.staff-button--primary {
  background: var(--church-button, #5e7f67);
  color: #fff;
  border-color: var(--church-button, #5e7f67);
}

/* Hover: the church's button color, 15% darker, so it follows the theme. */
.staff-button--primary:hover {
  background: color-mix(in srgb, var(--church-button, #5e7f67) 85%, #000);
  border-color: color-mix(in srgb, var(--church-button, #5e7f67) 85%, #000);
  color: #fff;
}

.staff-button--secondary {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--border);
}

.staff-button--secondary:hover {
  background: var(--canvas);
}

/* Every file field on /staff (owner, 23 November 2026): its button looks
   like a secondary button, not the browser's gray one. */
.staff input[type="file"] {
  font: inherit;
  font-size: 0.9rem;
  color: var(--ink-muted);
}

.staff input[type="file"]::file-selector-button {
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  min-height: 44px;
  padding: 0 18px;
  margin-right: 12px;
  cursor: pointer;
}

.staff input[type="file"]::file-selector-button:hover {
  background: var(--canvas);
}

.staff input:focus-visible,
.staff button:focus-visible,
.staff a:focus-visible {
  outline: 3px solid var(--staff-focus);
  outline-offset: 2px;
}

.staff-card {
  max-width: 400px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px 28px;
}

.staff-card__title {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}

.staff-card__body {
  color: var(--ink-muted);
  margin: 0 0 24px;
}

/* Room between field rows (owner, 23 November 2026: "a little more vertical
   spacing ... across the board"). */
.staff-form__field {
  margin-bottom: 24px;
}

.staff-form__label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 6px;
}

.staff-card input {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--ink-muted);
  border-radius: 10px;
  padding: 12px 14px;
}

.staff-card .staff-button--primary {
  width: 100%;
}

.staff-flash {
  margin: 0 0 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.staff-flash__item {
  margin: 0;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-size: 0.95rem;
  font-weight: 500;
}

.staff-flash__item--success {
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
  border-color: var(--brand);
}

.staff-flash__item--error {
  background: var(--staff-error-bg);
  color: var(--staff-error-ink);
  border-color: #f2b8b8;
}

.staff-dashboard__title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}

.staff-dashboard h2 {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0 0 12px;
}

.staff-dash__section,
.staff-pco-sync {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 24px;
  margin-bottom: 24px;
}

.staff-pco-sync__status {
  color: var(--ink-muted);
  margin: 0 0 16px;
}

.staff-pco-sync__result {
  color: var(--ink);
  font-weight: 600;
}

.staff-pco-sync form {
  margin: 0;
}

/* Dashboard sections (reworked November 2026). */
.staff-dashboard__title + .staff-dash__section {
  margin-top: 20px;
}

.staff-dash__heading {
  display: flex;
  align-items: center;
  gap: 8px;
}

.staff-dash__count {
  font-size: 0.85rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--church-button, #5e7f67);
  color: #fff;
}

.staff-dash__metric {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 12px;
  margin: -10px -12px;
  border-radius: 12px;
  color: inherit;
  text-decoration: none;
}

.staff-dash__metric:hover {
  background: var(--canvas);
}

.staff-dash__metric:hover .staff-dash__label {
  text-decoration: underline;
}

.staff-dash__value {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.1;
}

.staff-dash__label,
.staff-dash__sub,
.staff-dash__note,
.staff-dash__kicker {
  color: var(--ink-muted);
  font-size: 0.92rem;
}

.staff-dash__kicker {
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.78rem;
  font-weight: 700;
}

.staff-dash__note {
  margin: -6px 0 12px;
}

.staff-dash__person {
  font-weight: 600;
}

/* Staff header nav (real-life#77). Later content pages add their links. */
.staff-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* The header runs the full width with a few em on each side. The logo and
   the account share the top row, and the nav has its own row below, so new
   sections never push the account down. Sections are grouped under menus
   (sample B, owner 21 November 2026) so the row fits an iPad in portrait;
   on a narrower window it wraps, since a scrolling row would clip the
   menus. */
.staff-header .container {
  max-width: none;
  padding: 14px 2.5em 10px;
}

.staff-header .staff-nav {
  order: 3;
  flex-basis: 100%;
  flex-wrap: wrap;
  white-space: nowrap;
  margin: 0 -12px;
}

/* A group: its button opens a menu of its sections under it. */
.staff-nav__group {
  position: relative;
}

.staff-nav__toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  list-style: none;
}

.staff-nav__toggle::-webkit-details-marker {
  display: none;
}

.staff-nav__chevron {
  transition: transform 0.15s ease;
}

.staff-nav__group[open] .staff-nav__chevron {
  transform: rotate(180deg);
}

.staff-nav__menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 50;
  min-width: 220px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 6px;
  background: var(--surface);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
}

.staff-nav__link {
  color: var(--ink);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 8px;
}

.staff-nav__link:hover {
  background: var(--canvas);
}

.staff-nav__link[aria-current="page"] {
  background: var(--canvas);
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Habits page (real-life#77). */
.staff-habits__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}

.staff-habits__title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
  line-height: 1.1; /* the page line height (1.6) left ~12px of air above and below the title (owner, 21 November 2026) */
}

.staff-habits__note,
.staff-habits__empty {
  color: var(--ink-muted);
  margin: 0 0 24px;
}

.staff-habits__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.staff-habit {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 24px;
}

.staff-habit__title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0 0 6px;
}

.staff-habit__current {
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
  border: 1px solid var(--brand);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 2px 10px;
  border-radius: 999px;
}

.staff-habit__type,
.staff-habit__prompt {
  margin: 0 0 4px;
  color: var(--ink-muted);
}

.staff-habit__prompt--default {
  font-style: italic;
}

.staff-habit__actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.staff-habit__make-current {
  margin: 0;
}

/* Form cards (real-life#135): the window width with the header's side
   margins, and the fields side by side, three to a row from 1100px and two
   from 700px. Text areas take two columns; errors, loose hints and the buttons
   take a row. */
.staff-card--wide {
  max-width: none;
}

.staff-main > .staff-card--wide {
  margin: 0 2.5em;
}

/* Every /staff form in a wide card is one column, centered in the card, at
   most 48rem wide: each field gets its own row. */
.staff-card--wide .staff-form {
  display: grid;
  grid-template-columns: minmax(0, 48rem);
  justify-content: center;
}

@media (max-width: 699px) {
  .staff-main > .staff-card--wide {
    margin: 0;
  }
}

.staff-card textarea,
.staff-card select {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--ink-muted);
  border-radius: 10px;
  padding: 12px 14px;
}

.staff textarea:focus-visible,
.staff select:focus-visible {
  outline: 3px solid var(--staff-focus);
  outline-offset: 2px;
}

.staff-form__hint {
  color: var(--ink-muted);
  font-size: 0.85rem;
  margin: 6px 0 0;
}

.staff-form__readonly {
  display: inline-block;
  padding: 4px 0;
}

/* Form buttons follow the Mac: right-aligned to the fields, Cancel first,
   the main button last. */
.staff-form__actions {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: flex-end;
  margin-top: 16px;
}

/* A group of fields (the member picker, the passages of a plan day): a
   rounded frame, never the browser's square fieldset. */
.staff-form__fieldset {
  margin: 0;
  padding: 12px 16px 16px;
  border: 1px solid var(--border);
  border-radius: 14px;
}

.staff-form__fieldset > legend {
  padding: 0 6px;
}

.staff-card .staff-form__actions .staff-button--primary {
  width: auto;
}

@media (max-width: 640px) {
  .staff-habit {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .staff-main {
    padding: 12px 16px 48px;
  }

  .staff-main .container {
    padding: 0;
  }

  .staff-header .container {
    padding: 12px 16px 8px;
  }

  .staff-card {
    padding: 24px 20px;
  }

  .staff-header__brand {
    font-size: 1rem;
  }
}

/* Nav and sign out on the green header. */
.staff-header .staff-nav__link {
  color: var(--church-on-header, #fff);
}

.staff-header .staff-nav__link:hover,
.staff-header .staff-nav__link[aria-current="page"],
.staff-header .staff-nav__group[open] > .staff-nav__toggle {
  background: color-mix(in srgb, var(--church-on-header, #fff) 14%, transparent);
}

/* The group holding the current page reads like a current link. */
.staff-header .staff-nav__toggle.is-current {
  background: color-mix(in srgb, var(--church-on-header, #fff) 14%, transparent);
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Inside a menu: page-colored links on the white menu, 44px tall. */
.staff-header .staff-nav__menu .staff-nav__link {
  display: flex;
  align-items: center;
  min-height: 44px;
  box-sizing: border-box;
  padding: 10px 12px;
  color: var(--ink);
}

.staff-header .staff-nav__menu .staff-nav__link:hover {
  background: var(--canvas);
}

.staff-header .staff-nav__menu .staff-nav__link[aria-current="page"] {
  background: var(--canvas);
  font-weight: 700;
}

.staff-header .staff-button--secondary {
  background: transparent;
  color: var(--church-on-header, #fff);
  border-color: color-mix(in srgb, var(--church-on-header, #fff) 60%, transparent);
}

.staff-header .staff-button--secondary:hover {
  background: color-mix(in srgb, var(--church-on-header, #fff) 14%, transparent);
}

/* Habit form Type field and the Manage types dialog (real-life#95). */
.staff-type-field {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.staff-type-select {
  flex: 1;
  min-width: 0;
}

.staff-type-field .staff-button--secondary {
  flex-shrink: 0;
}

.staff-dialog {
  width: calc(100% - 32px);
  max-width: 560px;
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  padding: 24px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.staff-dialog::backdrop {
  background: rgba(28, 43, 18, 0.45);
}

.staff-dialog__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.staff-dialog__title {
  font-size: 1.3rem;
  font-weight: 800;
  margin: 0;
}

.staff-dialog__subtitle {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 12px;
}

.staff-dialog input,
.staff-dialog select {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--ink-muted);
  border-radius: 10px;
  padding: 10px 12px;
}

.staff-dialog input[type="hidden"] {
  display: none;
}

.staff-dialog .staff-button--primary {
  width: auto;
}

.staff-habit-types__list {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  border-top: 1px solid var(--border);
}

.staff-habit-types__empty {
  color: var(--ink-muted);
  margin: 0 0 20px;
}

.staff-habit-type {
  border-bottom: 1px solid var(--border);
  padding: 10px 0;
}

.staff-habit-type__show,
.staff-habit-type__edit {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
}

.staff-habit-type__show[hidden],
.staff-habit-type__edit[hidden] {
  display: none;
}

.staff-habit-type__name {
  font-weight: 600;
}

.staff-habit-type__key {
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.staff-habit-type__edit input[type="text"] {
  flex: 1 1 200px;
  width: auto;
}

.staff-habit-type__edit .staff-flash__item {
  flex-basis: 100%;
}

.staff-habit-type__actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

.staff-habit-type__delete {
  margin: 0;
}

.staff-habit-types__add {
  padding-top: 4px;
}

@media (max-width: 480px) {
  .staff-dialog {
    width: calc(100% - 32px);
    padding: 20px 16px;
  }

  .staff-type-field {
    flex-direction: column;
  }
}

.staff-form__hint--label {
  display: block;
  font-weight: 400;
  margin: 2px 0 0;
}

.staff-header__account {
  order: 2;
  /* The signed-in person next to Sign out (real-life#98). The group stays
     together and right-aligned when the header wraps. */
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.staff-header__avatar {
  display: block;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}

.staff-header__initials {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--church-on-header, #fff);
  background: color-mix(in srgb, var(--church-on-header, #fff) 20%, transparent);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1;
}

.staff-header__name {
  font-weight: 600;
  white-space: nowrap;
}

@media (max-width: 599px) {
  .staff-header__name {
    display: none;
  }
}

/* Planning Center sync spinner (real-life#99). */
.staff-spinner {
  display: inline-block;
  width: 1em;
  height: 1em;
  vertical-align: -0.15em;
  border: 2px solid var(--border);
  border-top-color: var(--brand-dark);
  border-radius: 50%;
  animation: staff-spin 0.8s linear infinite;
}

@keyframes staff-spin {
  to {
    transform: rotate(360deg);
  }
}

.staff-pco-sync__running {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  color: var(--ink);
  font-weight: 600;
}

.staff-pco-sync__running .staff-pco-sync__time {
  color: var(--ink-muted);
  font-weight: 400;
}

.staff-pco-sync__message {
  margin: 0 0 12px;
}

.staff-pco-sync__error {
  color: var(--staff-error-ink);
  font-size: 0.875rem;
  margin: -8px 0 16px;
}

.staff-pco-sync button[disabled] {
  cursor: not-allowed;
  opacity: 0.6;
}
/* A badge's emoji (real-life#180): beside its row at /staff/badges, and
   large on its page and beside its form. */
.staff-badge-emoji {
  flex: 0 0 auto;
  width: 40px;
  font-size: 1.5rem;
  line-height: 40px;
  text-align: center;
}

.staff-badge-emoji--large {
  width: 64px;
  font-size: 2.5rem;
  line-height: 64px;
}

.staff-short__form .staff-form__check {
  margin-top: 0;
  font-weight: 600;
}

.staff-short__form .staff-form__check input {
  width: 18px;
  height: 18px;
  accent-color: var(--church-header, #304b3b);
}

.staff-profile__earned {
  margin-left: auto;
  color: #5c5c61;
  font-size: 0.875rem;
}

.staff-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
}
/* real-life#130: a person Planning Center lists as inactive. */
.staff-badge--inactive {
  background: var(--staff-error-bg);
  color: var(--staff-error-ink);
  margin-left: 6px;
}

/* Sermons page (real-life#78): each sermon with its image, opens its edit page. */
.staff-sermons__list {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.staff-sermon {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 14px 10px 10px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
}

.staff-sermon--featured {
  border-color: var(--church-button, #5e7f67);
  box-shadow: 0 0 0 1px var(--church-button, #5e7f67);
}

.staff-sermon__link {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  color: inherit;
  text-decoration: none;
}

.staff-sermon__link:hover .staff-sermon__title {
  text-decoration: underline;
}

.staff-sermon__image {
  flex: 0 0 auto;
  width: 112px;
  height: 63px;
  border-radius: 8px;
  object-fit: cover;
  background: #1c1c1e;
}

.staff-sermon__image--empty {
  display: block;
  background: repeating-linear-gradient(135deg, #e5e5ea, #e5e5ea 6px, #f2f2f7 6px, #f2f2f7 12px);
}

.staff-sermon__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.staff-sermon__title {
  font-weight: 700;
}

.staff-sermon__meta,
.staff-sermon__passage {
  font-size: 0.9rem;
  color: var(--ink-muted);
}

/* An empty list (Media): a centered card that says what goes there. */
.staff-empty {
  margin: 24px 0 0;
  padding: 40px 24px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
}

/* Inside a card (a details page panel), the empty state drops its own frame. */
.staff-pco__panel .staff-empty {
  margin: 8px 0 0;
  padding: 24px 16px;
  border: 0;
  background: transparent;
}

.staff-empty__icon {
  width: 48px;
  height: 48px;
  color: var(--church-button, #5e7f67);
  margin-bottom: 4px;
}

.staff-empty__title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.staff-empty__body {
  margin: 0 0 8px;
  max-width: 34rem;
  color: var(--ink-muted);
}

/* The current image on the sermon edit page. */
.staff-sermon__current {
  display: block;
  max-width: 320px;
  border-radius: 10px;
  margin: 4px 0 8px;
}

@media (max-width: 599px) {
  .staff-sermon {
    flex-wrap: wrap;
  }

  .staff-sermon__image {
    width: 88px;
    height: 50px;
  }
}

/* Feed posts page (real-life#80). Rows reuse the Habits page styles. */
.staff-post__title {
  overflow-wrap: anywhere;
}

.staff-post__body {
  margin: 8px 0 0;
  overflow-wrap: anywhere;
}

/* Discuss on the sermon page (real-life#154, #173). Rows reuse the Habits
   page styles. */
.staff-discussion__header {
  margin-top: 32px;
  margin-bottom: 16px;
}

.staff-discussion__body {
  margin: 8px 0 0;
  overflow-wrap: anywhere;
  white-space: pre-line;
}

/* Bible plan days (real-life#175). The Days card has its buttons right of
   its title; a day row jumped to after a save clears the top of the window;
   a passage row is its text field with Remove beside it; and Remove day sits
   left of the form buttons. */
.staff-pco__panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 12px;
}

.staff-pco__panel-head .staff-pco__panel-title {
  margin: 0;
}

.staff-pco__panel-actions {
  display: flex;
  gap: 12px;
}

.staff-bible-plan-day {
  scroll-margin-top: 24px;
}

.staff-bible-plan-day--in-view {
  border-color: var(--brand);
}

.staff-passage-rows__list {
  display: grid;
  gap: 12px;
  margin: 12px 0;
}

.staff-passage-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.staff-passage-row[hidden] {
  display: none;
}

.staff-passage-row input[type="text"] {
  flex: 1;
  min-width: 0;
}

.staff-form__actions .staff-form__remove {
  margin-right: auto;
}

/* The first submit button of a form whose button row starts with a secondary
   submit: Enter in a text field uses it. Off screen, and out of the grid. */
.staff-form__default-submit {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Media page (real-life#82). Rows reuse the Habits page styles. */
.staff-card input[type="checkbox"] {
  width: auto;
  margin: 0;
}

.staff-form__check {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  font-size: 0.9rem;
}

.staff-media__filter {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 24px;
}

.staff-media__filter .staff-form__field,
.staff-media__filter .staff-form__actions {
  margin-bottom: 0;
}

.staff-media__filter input,
.staff-media__filter select {
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--ink-muted);
  border-radius: 10px;
  padding: 10px 12px;
}

.staff-media__filter input {
  min-width: 260px;
}

/* Tools page and Email templates. */

/* Tabs (layout B, owner 19 November 2026): an underlined row, the current
   tab in ink with a green underline. Scrolls sideways on a phone. */
.staff-emails__tabs {
  display: flex;
  gap: 2px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  /* The gray line under the tabs, drawn inside the box so the current
     tab's underline covers it without overflowing (no scroll bar). */
  box-shadow: inset 0 -1px 0 var(--border);
  margin: 20px 0 16px;
}

/* Right under a page title, the tabs sit close to it (owner, 21 November
   2026: less space under every page title). */
.staff-page-head + .staff-emails__tabs {
  margin-top: 4px;
}

.staff-emails__tabs::-webkit-scrollbar {
  display: none;
}

.staff-emails__tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 12px;
  border-bottom: 3px solid transparent;
  color: var(--ink-muted);
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
}

.staff-emails__tab:hover {
  color: var(--ink);
  text-decoration: none;
}

.staff-emails__tab[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--brand-dark);
}

.staff-tabs__count {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--border);
  color: var(--ink-muted);
}

.staff-emails__picker {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.staff-emails__frame {
  display: block;
  width: 100%;
  height: 760px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #f2f2f7;
}
/* Group details modal (Group digest emails). */

.staff-group {
  max-width: 640px;
}

.staff-group__image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 16px;
}

.staff-group__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin: 0 0 12px;
}

.staff-group__facts dt {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
}

.staff-group__facts dd {
  margin: 0;
  font-weight: 600;
}

.staff-group__description {
  margin: 0 0 20px;
  color: var(--ink-muted);
  white-space: pre-line;
}

.staff-group__members {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2px;
}

.staff-group__members li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  border-top: 1px solid var(--border);
}

.staff-group__avatar {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}

.staff-group__avatar--initials {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  background: var(--church-button, #5e7f67);
  color: #fff;
}

.staff-group__person {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.staff-group__name {
  font-weight: 600;
}

.staff-group__digest {
  flex: 0 0 auto;
}

/* Our team (real-life#103): a round photo or initials beside each entry. */
.staff-team-member {
  align-items: center;
}

.staff-team-member .staff-habit__main {
  flex: 1;
  min-width: 0;
}

.staff-team-member__photo {
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  background: #1c1c1e;
}

.staff-team-member__photo--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e5e5ea;
  color: #3a3a3c;
  font-weight: 600;
}
.staff-form__search {
  margin-bottom: 8px;
}

/* /staff Media (real-life#131): the whole card opens the view page; the
   title link stretches over the card and the Edit button sits above it. */
.staff-media__card {
  position: relative;
}

.staff-media__card:hover {
  border-color: var(--brand);
}

.staff-media__card-link {
  color: inherit;
  text-decoration: none;
}

.staff-media__card-link::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
}

.staff-media__card-link:focus-visible::after {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.staff-media__card .staff-habit__actions {
  position: relative;
  z-index: 1;
}

.staff-media__image {
  display: block;
  width: 100%;
  max-width: 480px;
  border-radius: var(--radius);
  margin: 0 0 16px;
}

.staff-media__tagline {
  font-weight: 600;
  margin: 0 0 8px;
}

.staff-media__videos {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
  word-break: break-all;
}

/* Full-width staff pages (real-life#133, #136): every /staff page runs the
   window width with the header's side margins instead of the 1040px column
   of the public site. */
.staff-main > .container {
  max-width: none;
  padding: 0 2.5em;
}

@media (max-width: 699px) {
  .staff-main > .container {
    padding: 0 20px;
  }
}

/* The dashboard tiles (real-life#133): one column on narrow windows; from
   1100px, App use beside Needs attention, the now cards in one row, and New
   in Planning Center beside the sync. */
/* List pages (real-life#138, owner decision 13 Nov 2026): every /staff card
   list is one full-width card per row, never narrow tiles. The pages run the
   window width (.staff-main > .container); .staff-habits__list stays a
   single column with the buttons on the right of each row. */

/* Planning Center pages (real-life#168): read-only lists and detail pages. */
.staff-pco__tabs {
  margin-bottom: 12px;
}

.staff-pco__card {
  /* Holds the card link's ::after (.staff-media__card-link), so a tap on the
     card opens it and the overlay stays inside the card, off the pager. */
  position: relative;
  justify-content: flex-start;
  align-items: center;
}

.staff-pco__card:hover {
  border-color: var(--brand);
}

.staff-pco__card .staff-habit__main {
  flex: 1 1 auto;
  min-width: 0;
}

.staff-pco__card .staff-habit__type a {
  /* Above the card link's overlay, so a name in the line opens its own page. */
  position: relative;
  z-index: 1;
}

.staff-pco__card .staff-habit__type {
  overflow-wrap: anywhere;
}

.staff-group__avatar--large {
  width: 64px;
  height: 64px;
  font-size: 1.25rem;
}

.staff-pco__facts {
  margin: 16px 0 24px;
}

.staff-pco__email {
  display: block;
  overflow-wrap: anywhere;
}

.staff-pco__section {
  margin-top: 28px;
}

.staff-pco__links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.staff-pco__links .staff-dash__sub {
  margin-left: 8px;
}

/* A person's /staff page (real-life#168): white cards on the gray page — the
   profile card, Contact and Details side by side, then household, groups,
   service teams and check-ins. */
.staff-pco__panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 24px;
  margin-bottom: 16px;
  min-width: 0;
}

.staff-pco__panels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.staff-pco__panels > .staff-pco__panel {
  margin-bottom: 0;
}

.staff-pco__hero {
  display: flex;
  align-items: center;
  gap: 20px;
}

.staff-pco__hero-text {
  min-width: 0;
}

/* A group's photo on its /staff page: a small banner beside the name, not
   the full width of the page. */
.staff-pco__hero-image {
  flex: 0 0 auto;
  width: 192px;
  max-width: 40%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 10px;
}

.staff-pco__panel-description {
  margin: 12px 0 0;
}

.staff-pco__hero .staff-habits__title {
  margin: 0;
}

.staff-pco__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 0;
}

.staff-pco__chip {
  font-size: 0.78rem;
  font-weight: 600;
  padding: 2px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--ink-muted);
}

.staff-pco__chip--brand {
  border-color: var(--brand);
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
}

.staff-pco__panel-title {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 12px;
}

.staff-pco__panel-lead {
  margin: 0 0 8px;
  font-weight: 600;
}

/* Label-and-value rows inside a card, one per line. */
.staff-pco__panel .staff-pco__facts {
  margin: 0;
}

.staff-pco__panel .staff-pco__facts > div {
  display: grid;
  grid-template-columns: minmax(120px, 40%) 1fr;
  gap: 12px;
  padding: 8px 0;
  border-top: 1px solid var(--border);
}

.staff-pco__panel .staff-pco__facts > div:first-child {
  border-top: 0;
  padding-top: 0;
}

.staff-pco__panel .staff-pco__facts dt {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
  padding-top: 2px;
}

.staff-pco__panel .staff-pco__facts dd {
  margin: 0;
  font-weight: 600;
  min-width: 0;
  overflow-wrap: anywhere;
}

/* A multi-line value (simple_format): its first line stays level with the label. */
.staff-pco__panel .staff-pco__facts dd p {
  margin: 0;
}

.staff-pco__panel .staff-pco__facts dd p + p {
  margin-top: 8px;
}

.staff-pco__panel .staff-pco__email + .staff-pco__email {
  margin-top: 6px;
}

.staff-pco__email-notes {
  display: block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--ink-muted);
}

.staff-pco__panel .staff-group__members li:first-child {
  border-top: 0;
}

/* A long list of people in a card flows into columns on wide screens. */
.staff-pco__panel--columns .staff-group__members {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
  column-gap: 24px;
}

.staff-pco__panel--columns .staff-group__members li {
  border-top: 0;
}

@media (max-width: 520px) {
  .staff-pco__panel {
    padding: 16px;
  }

  .staff-pco__hero {
    flex-wrap: wrap;
  }

  .staff-pco__hero-image {
    width: 100%;
    max-width: 100%;
  }

  .staff-pco__panel .staff-pco__facts > div {
    grid-template-columns: 1fr;
    gap: 2px;
  }
}

/* Mailjet and Sinch SMS pages under Tools (real-life#170). */
.staff-provider__status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 12px;
}

.staff-provider__status-bar .staff-dash__note {
  margin: 0;
}

.staff-provider__loading {
  min-height: 120px;
}

.staff-provider__stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  margin: 0 0 8px;
}

.staff-provider__stats > div {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
}

.staff-provider__stats dt {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
}

.staff-provider__stats dd {
  margin: 4px 0 0;
  font-size: 1.5rem;
  font-weight: 800;
}
/* An image's dimensions and file size, under it (sermon edit). */
.staff-sermon__image-info span + span::before {
  content: "· ";
}

.staff-sermon__image-info span[hidden] + span::before {
  content: none;
}

/* An action (Edit) at the right of a /staff page's hero card. */
.staff-pco__hero-actions {
  margin-left: auto;
  align-self: flex-start;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

/* A details page holds a record's actions (Edit, Remove and the like); a list
   row opens that page. Buttons left on a row (Move up and Move down, which
   order the list) sit above the row's link overlay. */
.staff-pco__card .staff-habit__actions {
  position: relative;
  z-index: 1;
}

/* A long Resi link wraps inside its card. */
.staff-media__video {
  overflow-wrap: anywhere;
}

/* Engagement email lists (real-life#177). The Add members page stacks one
   wide card per way to add. */
.staff-list-add + .staff-list-add {
  margin-top: 24px;
}

.staff-list-add__people {
  margin-top: 16px;
}

.staff-list-member {
  align-items: center;
}

/* The latest CSV import on a list's page. */
.staff-list-import__status {
  margin: 0 0 8px;
}

.staff-list-import__errors {
  color: var(--staff-error-ink);
}

/* The member picker of the New list form (spec 20.5): tabs to browse
   people, groups, service teams and households; a group opens to show
   who is in it; "On the new list" shows every picked person. */
.staff-picker {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.staff-picker__tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.staff-picker__tab {
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
}

.staff-picker__tab[aria-selected="true"] {
  background: var(--church-button, #5e7f67);
  border-color: var(--church-button, #5e7f67);
  color: #fff;
}

.staff-picker__browse,
.staff-picker__selected {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

/* The frame clips; the list inside scrolls, so the scrollbar stays inside
   the rounded corners. */
.staff-picker__browse {
  overflow: hidden;
}

.staff-picker__browse > .staff-picker__rows {
  max-height: 360px;
  overflow-y: auto;
}

.staff-picker__rows {
  list-style: none;
  margin: 0;
  padding: 0;
}

.staff-picker__rows--nested {
  border-top: 1px solid var(--border);
  background: #f7f9f8;
}

.staff-picker__rows--nested .staff-picker__row {
  padding-left: 40px;
}

.staff-picker__row,
.staff-picker__person {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
}

.staff-picker__rows > li:last-child > .staff-picker__row,
.staff-picker__rows > .staff-picker__row:last-child,
.staff-picker__chosen > .staff-picker__person:last-child {
  border-bottom: 0;
}

.staff-picker__source {
  border-bottom: 1px solid var(--border);
}

.staff-picker__source:last-child {
  border-bottom: 0;
}

.staff-picker__source .staff-picker__row {
  border-bottom: 0;
}

.staff-picker__source-toggle {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.staff-picker__chevron {
  display: inline-block;
  width: 12px;
  color: var(--ink-muted);
  transition: transform 0.15s ease;
}

.staff-picker__source-toggle[aria-expanded="true"] .staff-picker__chevron {
  transform: rotate(90deg);
}

.staff-picker__person-text {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 8px;
}

.staff-picker__person-name {
  font-weight: 600;
}

.staff-picker__person-email {
  font-size: 0.85rem;
  color: var(--ink-muted);
  overflow-wrap: anywhere;
}

.staff-picker__add {
  flex: 0 0 auto;
  padding: 4px 12px;
  font-size: 0.85rem;
}

.staff-picker__add[disabled] {
  opacity: 0.55;
  cursor: default;
}

.staff-picker__hint,
.staff-picker__empty {
  margin: 0;
  padding: 14px 12px;
  color: var(--ink-muted);
}

.staff-picker__left-out {
  margin: 0;
  padding: 8px 12px 10px 40px;
  font-size: 0.85rem;
  color: var(--ink-muted);
  background: #f7f9f8;
}

.staff-picker__selected-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}

.staff-picker__selected-title {
  margin: 0;
  font-size: 1rem;
}

.staff-picker__selected {
  overflow: hidden;
}

.staff-picker__chosen {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 320px;
  overflow-y: auto;
}

.staff-picker__link,
.staff-picker__remove {
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--church-button, #5e7f67);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.staff-picker__link:hover,
.staff-picker__remove:hover {
  text-decoration: underline;
}

/* Dashboard layout 3a (owner, 19 November 2026): the sync in the page head,
   one summary card (numbers, then what needs attention), then the newest
   people beside On Home now and Coming up. */
.staff-overview__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin-bottom: 20px;
}

.staff-overview__head .staff-dashboard__title {
  margin: 0;
}

.staff-overview__sync .staff-pco-sync {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px 12px;
  margin: 0;
  padding: 0;
  background: none;
  border: 0;
  box-shadow: none;
  font-size: 0.85rem;
}

.staff-overview__sync .staff-pco-sync__title {
  font-size: 0.85rem;
  font-weight: 700;
  margin: 0;
}

.staff-overview__sync .staff-pco-sync__status,
.staff-overview__sync .staff-pco-sync__message,
.staff-overview__sync .staff-pco-sync__error {
  margin: 0;
}

.staff-overview__sync .staff-pco-sync__button {
  min-height: 34px;
  padding: 0 12px;
  font-size: 0.82rem;
}

.staff-overview__summary {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-bottom: 24px;
}

.staff-overview__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.staff-dash__metric.staff-overview__stat {
  margin: 0;
  padding: 16px 20px;
  border-radius: 0;
  border-left: 1px solid var(--border);
}

.staff-overview__stat:first-child {
  border-left: 0;
}

.staff-overview__stat .staff-dash__value {
  font-size: 1.75rem;
}

.staff-overview__of {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink-muted);
}

.staff-overview__sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.staff-overview__alerts {
  list-style: none;
  margin: 0;
  padding: 0;
}

.staff-overview__alert,
.staff-overview__ok {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 12px 20px;
  font-weight: 600;
}

.staff-overview__alert {
  background: var(--staff-warning-bg);
  color: var(--staff-warning-ink);
  border-top: 1px solid #f0d9a8;
}

.staff-overview__alert a {
  color: inherit;
  text-decoration: underline;
}

.staff-overview__mark {
  flex: none;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--staff-warning-ink);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 800;
}

.staff-overview__ok {
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
  border-top: 1px solid var(--border);
}

.staff-overview__table-wrap {
  overflow-x: auto;
}

.staff-overview__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.staff-overview__table th {
  text-align: left;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-muted);
  padding: 0 12px 8px 0;
}

.staff-overview__table td {
  padding: 10px 12px 10px 0;
  border-top: 1px solid var(--border);
  vertical-align: baseline;
}

.staff-overview__muted {
  color: var(--ink-muted);
  white-space: nowrap;
}

.staff-overview__more {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin: 12px 0 0;
  font-size: 0.9rem;
  color: var(--ink-muted);
}

.staff-overview__more a {
  font-weight: 600;
}

.staff-overview__home {
  list-style: none;
  margin: 0;
  padding: 0;
}

.staff-overview__home li {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid var(--border);
}

.staff-overview__home li:first-child {
  border-top: 0;
  padding-top: 0;
}

.staff-overview__home li > div {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.staff-overview__thumb {
  width: 64px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
}

.staff-overview__thumb--label {
  display: grid;
  place-items: center;
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
  font-size: 0.78rem;
  font-weight: 800;
}

.staff-overview__title {
  font-weight: 600;
}

.staff-overview__day + .staff-overview__day {
  margin-top: 14px;
}

.staff-overview__day ul {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
}

.staff-overview__day li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 2px 12px;
  padding: 3px 0;
}

@media (max-width: 760px) {
  .staff-overview__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .staff-overview__stat:nth-child(3) {
    border-left: 0;
  }

  .staff-overview__stat:nth-child(n+3) {
    border-top: 1px solid var(--border);
  }

  .staff-overview__sync .staff-pco-sync {
    justify-content: flex-start;
  }
}

@media (max-width: 560px) {
  .staff-overview__wide {
    display: none;
  }
}

/* Filter rail lists (layout B, owner 19 November 2026): a rail of filters
   beside the results. Labels stay visible above each field, hints below;
   the results update as you type. On a phone the rail stacks on top and
   its extra filters fold under "More filters". */
.staff-rail-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.staff-rail-layout__results {
  display: block;
  min-width: 0;
}

.staff-rail.staff-pco__panel {
  position: sticky;
  top: 16px;
  display: grid;
  gap: 20px;
  padding: 20px;
  margin: 0;
}

.staff-rail__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}

.staff-rail__title {
  font-size: 1rem;
  margin: 0;
}

.staff-rail__clear {
  font-size: 0.88rem;
  font-weight: 600;
}

.staff-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.staff-field__label {
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0;
}

.staff-field__hint {
  font-size: 0.8rem;
  color: var(--ink-muted);
  margin: 0;
}

.staff-field__input {
  font: inherit;
  font-size: 1rem;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
  width: 100%;
}

.staff-field__input:focus {
  outline: 3px solid var(--brand);
  outline-offset: 0;
  border-color: var(--brand-dark);
}

.staff-rail__more {
  display: grid;
  gap: 20px;
}

.staff-rail__more[open] {
  display: grid;
}

.staff-rail__toggle {
  list-style: none;
  cursor: pointer;
}

.staff-rail__toggle::-webkit-details-marker {
  display: none;
}

.staff-rail__group {
  border: 0;
  margin: 0;
  padding: 0;
  min-width: 0;
  display: grid;
  gap: 2px;
}

.staff-rail__group + .staff-rail__group {
  margin-top: 20px;
}

.staff-rail__group legend {
  margin-bottom: 6px;
}

.staff-rail__group .staff-field__hint {
  margin: 0 0 4px;
}

.staff-rail__group .staff-field__hint:last-child {
  margin: 4px 0 0;
}

.staff-rail__option {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 0 10px;
  border-radius: 9px;
  cursor: pointer;
  font-size: 0.92rem;
}

.staff-rail__option:hover {
  background: var(--canvas);
}

.staff-rail__option input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--church-header, #304b3b);
  flex: none;
}

.staff-rail__option b {
  margin-left: auto;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink-muted);
}

.staff-chips {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.staff-chips__chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 6px 4px 12px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: 0.85rem;
  font-weight: 600;
}

.staff-chips__remove {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--canvas);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1;
}

.staff-chips__remove:hover {
  background: var(--border);
  text-decoration: none;
}

.staff-results {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 16px;
  margin: 0 0 10px;
}

.staff-results__count {
  margin: 0;
  font-weight: 700;
}

.staff-results__sort {
  font-size: 0.88rem;
  color: var(--ink-muted);
}

.staff-rows.staff-pco__panel {
  list-style: none;
  padding: 0;
  overflow: hidden;
}

.staff-row {
  position: relative;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  gap: 4px 14px;
  align-items: center;
  padding: 12px 20px;
  border-top: 1px solid var(--border);
}

.staff-row:first-child {
  border-top: 0;
}

.staff-row:hover {
  background: #fafafc;
}

.staff-row .staff-group__avatar {
  width: 40px;
  height: 40px;
}

.staff-row__main {
  min-width: 0;
}

.staff-row__title {
  font-size: 1rem;
  margin: 0;
}

.staff-row__link::after {
  content: "";
  position: absolute;
  inset: 0;
}

.staff-row__meta {
  margin: 2px 0 0;
  font-size: 0.86rem;
  color: var(--ink-muted);
  overflow-wrap: anywhere;
}

.staff-tag {
  justify-self: end;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 999px;
  white-space: nowrap;
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
}

.staff-tag--visitor {
  background: var(--staff-warning-bg);
  color: var(--staff-warning-ink);
}

.staff-tag--none {
  background: var(--canvas);
  color: var(--ink-muted);
}

@media (min-width: 861px) {
  .staff-rail__toggle {
    display: none;
  }
}

@media (max-width: 860px) {
  .staff-rail-layout {
    grid-template-columns: 1fr;
  }

  .staff-rail.staff-pco__panel {
    position: static;
  }

  .staff-rail__toggle {
    justify-self: start;
  }

  .staff-rail__more[open] .staff-rail__toggle {
    margin-bottom: 4px;
  }

  .staff-row {
    grid-template-columns: 40px minmax(0, 1fr);
  }

  .staff-row .staff-tag {
    grid-column: 2;
    justify-self: start;
  }
}

.staff-rail-pager {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 14px;
  font-size: 0.9rem;
}

.staff-rail-pager__left {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
}

.staff-rail-pager__count {
  color: var(--ink-muted);
}

.staff-rail-pager__pages .staff-rail-pager__show {
  min-width: 0;
  padding: 0 4px 0 0;
  font-weight: 400;
  color: var(--ink-muted);
}

.staff-rail-pager__pages {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.staff-rail-pager__pages a,
.staff-rail-pager__pages span {
  display: grid;
  place-items: center;
  min-width: 36px;
  height: 36px;
  padding: 0 8px;
  border-radius: 9px;
  font-weight: 600;
}

.staff-rail-pager__pages a:hover {
  background: var(--surface);
  text-decoration: none;
}

.staff-rail-pager__pages .staff-rail-pager__current {
  background: var(--church-header, #304b3b);
  color: #fff;
  font-weight: 700;
}

.staff-page-head {
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin-bottom: 6px; /* 16px until 21 November 2026 (owner: less under every page title) */
}

.staff-page-head__source {
  margin: 0;
  font-size: 0.85rem;
  color: var(--ink-muted);
}

.staff-rail-empty {
  text-align: center;
  padding: 40px 20px;
}

.staff-rail-empty h3 {
  margin: 0 0 6px;
  font-size: 1.05rem;
}

.staff-rail-empty p {
  margin: 0 0 14px;
  color: var(--ink-muted);
}

/* A person's page, layout B (owner, 19 November 2026): the profile card
   sits where the People filter rail sits; the household, groups, teams
   and check-ins fill the main column. */
.staff-profile.staff-rail-layout {
  grid-template-columns: 320px minmax(0, 1fr);
}

.staff-profile__card.staff-pco__panel {
  position: sticky;
  top: 16px;
  margin: 0;
  padding: 20px;
  display: grid;
  gap: 16px;
}

.staff-profile__who {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.staff-profile__name {
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 6px;
  overflow-wrap: anywhere;
}

.staff-profile__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
}

.staff-profile__tags .staff-tag {
  justify-self: auto;
}

.staff-profile__note {
  margin: 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--staff-warning-bg);
  color: var(--staff-warning-ink);
  font-size: 0.86rem;
  font-weight: 600;
}

.staff-pco__panel .staff-profile__facts > div {
  grid-template-columns: 1fr;
  gap: 2px;
}

.staff-profile__main {
  min-width: 0;
}

.staff-profile__main > .staff-pco__panel,
.staff-profile__pair {
  margin-bottom: 16px;
}

.staff-profile__pair {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 16px;
}

.staff-profile__pair .staff-pco__panel {
  margin: 0;
}

.staff-profile__links {
  list-style: none;
  margin: 0;
  padding: 0;
}

.staff-profile__links li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-top: 1px solid var(--border);
}

.staff-profile__links li:first-child {
  border-top: 0;
  padding-top: 0;
}

.staff-pco__panel-title .staff-tabs__count {
  vertical-align: 2px;
  margin-left: 4px;
}

@media (max-width: 860px) {
  .staff-profile.staff-rail-layout {
    grid-template-columns: 1fr;
  }

  .staff-profile__card.staff-pco__panel {
    position: static;
  }
}

/* Households rows (layout B): up to three faces of the household, overlapped. */
.staff-row:has(.staff-row__faces) {
  grid-template-columns: 76px minmax(0, 1fr) auto;
}

.staff-row__faces {
  display: flex;
}

.staff-row__faces .staff-group__avatar {
  width: 36px;
  height: 36px;
  border: 2px solid var(--surface);
  box-sizing: content-box;
}

.staff-row__faces .staff-group__avatar + .staff-group__avatar {
  margin-left: -14px;
}

/* A link inside a row whose whole area opens the record sits above that
   area, so it opens its own page. */
.staff-row__inner-link {
  position: relative;
  z-index: 1;
  color: var(--ink-muted);
  font-weight: 600;
}

@media (max-width: 860px) {
  .staff-row:has(.staff-row__faces) {
    grid-template-columns: 76px minmax(0, 1fr);
  }
}

/* People & Teams record pages: the tabs stay, with a trail of two parts at
   most under them (owner, 19 November 2026). */
.staff-page-head__section {
  margin: 0;
}

.staff-crumbs ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 8px;
  margin: -4px 0 16px;
  padding: 0;
  font-size: 0.92rem;
}

.staff-crumbs li + li::before {
  content: "/";
  margin-right: 8px;
  color: var(--ink-muted);
}

.staff-crumbs a {
  font-weight: 600;
}

.staff-crumbs [aria-current="page"] {
  color: var(--ink);
  font-weight: 600;
  overflow-wrap: anywhere;
}

.staff-household__section + .staff-household__section {
  margin-top: 20px;
}

.staff-household__section .staff-rows {
  margin-bottom: 0;
}

/* Our Church Team, layout B (owner, 19 November 2026). */
.staff-team__about {
  margin: -8px 0 0;
}

.staff-team__rows .staff-row {
  grid-template-columns: 24px 40px minmax(0, 1fr) auto;
}

.staff-team__position {
  font-weight: 700;
  color: var(--ink-muted);
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.staff-team__move {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 4px;
}

.staff-team__arrow-form {
  margin: 0;
}

.staff-team__arrow {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.staff-team__arrow:hover {
  background: var(--canvas);
}

.staff-team__arrow--off {
  color: #c4c4ca;
  border-color: transparent;
  background: none;
  cursor: default;
}

.staff-profile__actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.staff-profile__action-form {
  margin: 0;
}

.staff-form__optional {
  font-weight: 400;
  font-size: 0.8rem;
  color: var(--ink-muted);
  margin-left: 4px;
}

.staff-form__error {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--staff-error-ink);
}

.staff-team__toggle {
  padding: 0;
  font-weight: 600;
}

@media (max-width: 860px) {
  .staff-team__rows .staff-row {
    grid-template-columns: 24px 40px minmax(0, 1fr) auto;
  }

  .staff-team__rows .staff-row .staff-team__move {
    grid-column: auto;
  }
}

/* Groups, layout B (owner, 19 November 2026): rows with the group's photo,
   and the group's card with its photo across the top. */
.staff-row--thumb {
  grid-template-columns: 64px minmax(0, 1fr) auto;
}

.staff-row__thumb {
  width: 64px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
}

.staff-row__thumb--empty {
  display: grid;
  place-items: center;
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
  font-size: 0.75rem;
  font-weight: 800;
}

.staff-profile__image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 10px;
}

.staff-profile__label {
  font-size: 0.85rem;
  font-weight: 700;
  margin: 0 0 6px;
}

.staff-profile__description {
  margin: 0;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.staff-rail-empty--small {
  padding: 20px;
}

.staff-rail-empty--small p {
  margin: 0;
}

.staff-profile__main > .staff-household__section {
  margin-bottom: 20px;
}

@media (max-width: 860px) {
  .staff-row--thumb {
    grid-template-columns: 64px minmax(0, 1fr);
  }
}

/* Sermons, layout B (owner, 19 November 2026): 16:9 thumbnails in the rows
   and a line above the rows saying which sermon Home shows. */
.staff-row--wide-thumb {
  grid-template-columns: 96px minmax(0, 1fr) auto;
}

.staff-row--wide-thumb .staff-row__thumb {
  width: 96px;
  height: 54px;
}

.staff-home-note {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  margin: 0 0 14px;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
}

.staff-home-note__label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.staff-home-note a {
  font-weight: 700;
  color: inherit;
  text-decoration: underline;
}

.staff-home-note__hint {
  font-size: 0.85rem;
}

@media (max-width: 860px) {
  .staff-row--wide-thumb {
    grid-template-columns: 96px minmax(0, 1fr);
  }
}

.staff-profile__hint {
  margin: 0;
  font-size: 0.85rem;
  color: var(--ink-muted);
}

.staff-card--wide .staff-form__fieldset {
  display: grid;
  gap: 26px;
  padding: 16px 20px 20px;
}

.staff-card--wide .staff-form__fieldset > legend {
  font-size: 0.95rem;
}

.staff-discussion .staff-row {
  align-items: start;
}

/* A form's error summary (layout B forms). */
.staff-error-summary {
  border: 1px solid #f2b8b8;
  border-radius: 12px;
  background: var(--staff-error-bg);
  color: var(--staff-error-ink);
  padding: 14px 18px;
}

.staff-error-summary:focus {
  outline: 3px solid var(--staff-focus);
  outline-offset: 2px;
}

.staff-error-summary__title {
  font-size: 1rem;
  margin: 0 0 6px;
}

.staff-error-summary__list {
  margin: 0;
  padding-left: 1.1em;
}

.staff-error-summary__list a {
  color: inherit;
  text-decoration: underline;
}

.staff-form [aria-invalid="true"] {
  border-color: var(--staff-error-ink);
}

/* A form in sections (sermon edit, sample B, owner 19 November 2026): a
   side menu of the sections, the sections as cards, and a save bar that
   stays in view. On a phone the menu is a row above the form. */
.staff-form.staff-sections {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.staff-sections__menu.staff-pco__panel {
  position: sticky;
  top: 16px;
  margin: 0;
  padding: 14px;
}

.staff-sections__title {
  font-weight: 800;
  line-height: 1.3;
  margin: 2px 8px 10px;
  overflow-wrap: anywhere;
}

.staff-sections__menu ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2px;
}

.staff-sections__menu a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border-radius: 10px;
  color: var(--ink);
  font-weight: 600;
}

.staff-sections__menu a:hover {
  background: var(--canvas);
  text-decoration: none;
}

/* The current section in the church's accent color, not the success green
   (owner, 21 November 2026). */
.staff-sections__menu a[aria-current="true"],
.staff-sections__menu a[aria-current="true"]:hover {
  background: color-mix(in srgb, var(--brand) 28%, var(--surface));
  color: var(--ink);
}

.staff-sections__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--staff-warning-ink);
  visibility: hidden;
}

.staff-sections__dot.is-on {
  visibility: visible;
}

.staff-sections__foot {
  margin: 12px 8px 4px;
  font-size: 0.8rem;
  color: var(--ink-muted);
}

.staff-sections__main,
.staff-sections__fields {
  display: grid;
  gap: 16px;
  min-width: 0;
}

/* The rows of fields inside a section get the same room as a section's
   blocks (owner, 23 November 2026). */
.staff-sections__fields {
  gap: 26px;
}

.staff-sections__section.staff-pco__panel {
  margin: 0;
  padding: 22px 24px;
  display: grid;
  gap: 26px;
  scroll-margin-top: 16px;
}

.staff-sections__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}

.staff-sections__heading {
  font-size: 1.1rem;
  font-weight: 800;
  margin: 0;
}

.staff-sections__head .staff-sections__heading {
  margin-right: auto;
}

.staff-sections__lead {
  margin: -10px 0 0;
  font-size: 0.88rem;
  color: var(--ink-muted);
}

.staff-form__label--row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}

.staff-form__count {
  font-weight: 400;
  font-size: 0.78rem;
  color: var(--ink-muted);
  font-variant-numeric: tabular-nums;
}

.staff-savebar {
  position: sticky;
  bottom: 0;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.06);
}

.staff-savebar__status {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink-muted);
}

.staff-savebar__status.is-dirty {
  color: var(--staff-warning-ink);
}

.staff-savebar__actions {
  display: flex;
  gap: 10px;
  margin-left: auto;
}

.staff-sections .staff-sermon__upload-preview {
  max-width: 320px;
}

@media (max-width: 900px) {
  .staff-form.staff-sections {
    grid-template-columns: 1fr;
  }

  /* Narrow (an iPad in portrait; owner, 21 November 2026): the side menu
     is a one-line bar that sticks to the top of the window: the form's
     title, then a button naming the section in view, which opens the list
     of sections (staff/_sections_toggle). */
  .staff-sections__menu.staff-pco__panel {
    position: sticky;
    top: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 6px 6px 16px;
  }

  .staff-sections__menu .staff-sections__title {
    flex: 1;
    min-width: 0;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 1rem;
  }

  .staff-sections__menu .staff-sections__list,
  .staff-sections__menu .staff-sections__foot {
    display: none;
  }

  .staff-sections__toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    min-height: 44px;
    padding: 8px 14px;
    border: 0;
    border-radius: 10px;
    background: color-mix(in srgb, var(--brand) 28%, var(--surface));
    color: var(--ink);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
  }

  .staff-sections__menu.is-open .staff-nav__chevron {
    transform: rotate(180deg);
  }

  .staff-sections__menu ol {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 240px;
    padding: 6px;
    background: var(--surface);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
  }

  .staff-sections__menu.is-open ol {
    display: grid;
  }

  .staff-sections__menu a {
    min-height: 44px;
    box-sizing: border-box;
  }

  /* A jump lands its section's heading below the bar, not under it. */
  .staff-sections [data-form-sections-target~="section"] {
    scroll-margin-top: 72px;
  }
}

/* Wide: the side menu shows, so the bar's button does not. */
@media (min-width: 901px) {
  .staff-sections__toggle {
    display: none;
  }
}

/* The sectioned form's fields (owner, 19 November 2026: the fields had no
   styling outside .staff-card). The same look as the card forms: full width
   up to 48rem, 44px tall, a rounded border, a green focus ring. */
.staff-sections input[type="text"],
.staff-sections input[type="url"],
.staff-sections input[type="search"],
.staff-sections input[type="date"],
.staff-sections input[type="datetime-local"],
.staff-sections input[type="time"],
.staff-sections select,
.staff-sections textarea {
  width: 100%;
  min-height: 44px;
  font: inherit;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  padding: 10px 14px;
}

.staff-sections textarea {
  min-height: 160px;
  resize: vertical;
}

.staff-sections input:focus,
.staff-sections select:focus,
.staff-sections textarea:focus {
  outline: 3px solid var(--brand);
  outline-offset: 0;
  border-color: var(--brand-dark);
}

.staff-sections input[type="file"] {
  font: inherit;
  font-size: 0.9rem;
}

.staff-sections__section > .staff-form__field,
.staff-sections__section > .staff-sections__lead {
  max-width: 48rem;
}

.staff-sections__section .staff-form__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
}

.staff-sections .staff-form__label {
  margin: 0;
}

.staff-sections .staff-form__label--row {
  justify-content: flex-start;
  gap: 10px;
}

.staff-sections .staff-form__hint {
  margin: 0;
  font-size: 0.84rem;
}

.staff-sections .staff-form__check {
  margin-top: 4px;
  font-size: 0.9rem;
}

.staff-sections .staff-form__check input {
  width: 18px;
  height: 18px;
  accent-color: var(--church-header, #304b3b);
}

/* Dropdowns in layout B forms and filter rails: our own chevron, 16px in
   from the right edge, instead of the browser's (owner, 19 November 2026). */
.staff-sections select,
select.staff-field__input {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%236b6b70' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 12px 8px;
}

/* A sermon's video on its /staff page (owner, 19 November 2026). */
.staff-video__player {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  background: #1c1c1e;
}

.staff-video .staff-form__error {
  margin: 10px 0 0;
}

/* Saved and error messages (sample A, owner 19 November 2026): a banner at
   the top of the page content until it is closed. */
.staff-messages .staff-flash {
  margin: 0 0 20px;
}

.staff-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 12px 12px 16px;
  border-radius: 12px;
  border: 1px solid;
  font-weight: 600;
}

.staff-banner--ok {
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
  border-color: var(--staff-success-edge);
}

.staff-banner--error {
  background: var(--staff-error-bg);
  color: var(--staff-error-ink);
  border-color: #f2b8b8;
}

.staff-banner__icon {
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.8rem;
  font-weight: 800;
  color: #fff;
  background: #3f6b4b;
}

.staff-banner--error .staff-banner__icon {
  background: var(--staff-error-ink);
}

/* A banner inside a record page's section, between its head and its card. */
.staff-profile__notice {
  margin-bottom: 16px;
}

/* Information that needs no fixing (owner, 20 November 2026). */
.staff-banner--info {
  background: var(--staff-info-bg);
  color: var(--staff-info-ink);
  border-color: #c3d5ef;
}

.staff-banner--info .staff-banner__icon {
  background: var(--staff-info-ink);
  font-family: Georgia, serif;
  font-style: italic;
}

.staff-banner--info a {
  color: inherit;
  text-decoration: underline;
}

.staff-banner__text {
  margin: 0;
}

.staff-banner__close {
  margin-left: auto;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 1.1rem;
  cursor: pointer;
}

.staff-banner__close:hover {
  background: rgba(0, 0, 0, 0.06);
}

/* The banner's text keeps the old message class for its role; the banner
   draws the box. */
.staff-banner .staff-flash__item {
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  margin: 0;
}

/* Pop-ups (sample A, owner 19 November 2026): a centered pop-up on a dimmed
   page, at most 560px wide. The head has the title and a 36px × button; the
   body scrolls; the footer is a light band with the actions, the main one
   right-most. Always the light look. */
.staff-dialog {
  padding: 0;
  border: 0;
  border-radius: 16px;
  width: min(560px, calc(100vw - 32px));
  max-height: min(720px, calc(100dvh - 48px));
  overflow: hidden;
  background: var(--surface);
  color: var(--ink);
  color-scheme: light;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.28);
}

.staff-dialog[open] {
  display: flex;
  flex-direction: column;
}

.staff-dialog::backdrop {
  background: rgba(28, 28, 30, 0.45);
}

.staff-dialog > .staff-dialog__header {
  align-items: flex-start;
  margin: 0;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
}

.staff-dialog__title {
  font-size: 1.15rem;
  line-height: 1.3;
}

.staff-dialog__summary {
  margin: 2px 0 0;
  font-size: 0.85rem;
  color: var(--ink-muted);
}

.staff-dialog__close {
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
}

.staff-dialog__close:hover {
  background: var(--canvas);
}

.staff-dialog__body {
  padding: 18px 20px;
  overflow-y: auto;
  display: grid;
  gap: 14px;
}

.staff-dialog__body p {
  margin: 0;
}

.staff-dialog__footer {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  background: #fafafc;
}

.staff-dialog__footer form {
  margin: 0;
}

.staff-confirm.staff-dialog {
  width: min(480px, calc(100vw - 32px));
}

.staff-confirm__type {
  display: grid;
  gap: 6px;
}

.staff-button--danger {
  background: #b42318;
  border-color: #b42318;
  color: #fff;
}

.staff-button--danger:hover {
  background: #912018;
}

.staff-button--danger[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
}

/* A Remove button on a page: a red outline, left of the main action. */
.staff-button--danger-outline {
  background: var(--surface);
  border: 1px solid #f2b8b8;
  color: #b42318;
}

.staff-button--danger-outline:hover {
  background: var(--staff-error-bg);
}

/* Short forms, sample B (owner, 19 November 2026): a card for the record on
   the left that follows the fields, the form card on the right. Choices from
   a short list are tiles; "+ New" opens a small panel in place. */
.staff-short__lead {
  margin: -6px 0 16px;
}

.staff-short__record .staff-profile__name {
  overflow-wrap: anywhere;
}

.staff-short__shows {
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--canvas);
  /* The card is narrow: a long word or an address wraps inside the box
     and never pushes it wider than the card (real-life#219). */
  min-width: 0;
  overflow-wrap: anywhere;
}

.staff-short__shows p {
  margin: 4px 0 0;
  white-space: pre-line;
}

.staff-form.staff-short__form {
  margin: 0;
  padding: 24px 28px;
  display: grid;
  gap: 28px;
  max-width: none;
}

.staff-short__form > .staff-form__field,
.staff-short__form > .staff-short__fieldset {
  max-width: 40rem;
}

.staff-short__form .staff-form__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
}

.staff-short__form .staff-form__label {
  margin: 0;
}

.staff-short__form .staff-form__label--row {
  justify-content: flex-start;
  gap: 10px;
}

.staff-short__form .staff-form__count {
  margin-left: auto;
}

.staff-short__form .staff-form__hint {
  margin: 0;
  font-size: 0.84rem;
}

.staff-short__form input[type="text"],
.staff-short__form input[type="number"],
.staff-short__form input[type="url"],
.staff-short__form input[type="email"],
.staff-short__form input[type="password"],
.staff-short__form input[type="tel"],
.staff-short__form input[type="date"],
.staff-short__form input[type="datetime-local"],
.staff-short__form input[type="time"],
.staff-short__form select,
.staff-short__form textarea,
.staff-new-type input[type="text"] {
  width: 100%;
  min-height: 44px;
  font: inherit;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  padding: 10px 14px;
}

.staff-short__form textarea {
  min-height: 110px;
  resize: vertical;
}

.staff-short__form input:focus,
.staff-short__form select:focus,
.staff-short__form textarea:focus,
.staff-new-type input:focus {
  outline: 3px solid var(--brand);
  outline-offset: 0;
  border-color: var(--brand-dark);
}

.staff-short__form select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%236b6b70' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.staff-short__form input.staff-short__number {
  max-width: 140px;
}

.staff-short__fieldset {
  border: 0;
  margin: 0;
  padding: 0;
  min-width: 0;
}

.staff-short__fieldset > legend {
  margin-bottom: 6px;
}

.staff-short__actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

.staff-short__outside {
  display: none;
}

.staff-tiles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.staff-tile {
  position: relative;
  margin: 0;
}

.staff-tile input {
  position: absolute;
  inset: 0;
  opacity: 0;
  margin: 0;
  cursor: pointer;
}

.staff-tile span {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  background: var(--surface);
  font-weight: 600;
}

.staff-tile input:checked + span {
  border-color: var(--church-header, #304b3b);
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
  box-shadow: inset 0 0 0 1px var(--church-header, #304b3b);
}

.staff-tile input:focus-visible + span {
  outline: 3px solid var(--staff-focus);
  outline-offset: 2px;
}

.staff-new-type {
  display: grid;
  gap: 12px;
  margin-top: 10px;
  padding: 14px;
  border: 1px dashed #c9c9d0;
  border-radius: 12px;
}

.staff-new-type[hidden] {
  display: none;
}

.staff-new-type__fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 24px 12px;
}

.staff-new-type__actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.staff-new-type .staff-form__field {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.staff-linkbutton {
  font: inherit;
  font-weight: 600;
  color: var(--brand-dark);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

.staff-linkbutton:hover {
  text-decoration: underline;
}

.staff-row--plain {
  grid-template-columns: minmax(0, 1fr) auto;
}

/* Bible, layout B (owner, 19 November 2026): the reading form's passage in
   the record card, built from the book, chapter and verse fields; the
   chapter, first and last verse side by side; a plan's day rows with their
   tags, and the day that was just saved marked in green. */
.staff-bible-ref {
  font-weight: 600;
}

.staff-bible-ref__chapter:not(:empty)::before {
  content: " ";
}

.staff-bible-ref__start:not(:empty)::before {
  content: ":";
}

.staff-bible-ref__end:not(:empty)::before {
  content: "-";
}

.staff-bible-series:empty {
  display: none;
}

.staff-bible-verses {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.staff-short__form .staff-bible-verses .staff-form__field {
  flex: 0 1 160px;
}

.staff-short__form .staff-bible-verses__hint {
  margin-top: -12px;
}

.staff-bible-plan-day__markers {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.staff-row.staff-bible-plan-day--in-view {
  background: var(--staff-success-bg);
}

.staff-bible-days .staff-pco__panel-head {
  margin-bottom: 10px;
}

.staff-bible .staff-savebar__actions {
  flex-wrap: wrap;
}

.staff-savebar__actions .staff-form__remove {
  margin-right: auto;
}

@media (max-width: 860px) {
  .staff-bible-plan-day__markers {
    justify-content: flex-start;
  }
}

/* Engagement, layout B (owner, 19 November 2026): a list's page has a small
   filter row (status and search) above its member rows, each row with its
   status tag and Remove or Subscribe again; the new list form holds the
   member picker in the form card; the Add members page is the long form in
   sections, one card per way to add, each with its own button. */
.staff-rail-empty h2 {
  margin: 0 0 6px;
  font-size: 1.05rem;
}

.staff-email-list__name,
.staff-email-list__description {
  overflow-wrap: anywhere;
}

.staff-email-list__description {
  margin: 8px 0 0;
  white-space: pre-line;
}

.staff-email-list__members > .staff-pco__panel-title {
  margin-bottom: 12px;
}

.staff-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 12px 16px;
  margin: 0 0 14px;
}

.staff-filter-row__select {
  min-width: 170px;
  appearance: none;
  -webkit-appearance: none;
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%236b6b70' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.staff-filter-row__search {
  flex: 1 1 260px;
  max-width: 26rem;
}

.staff-list-member__side {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px 12px;
}

.staff-list-member__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.staff-short__form input[type="search"] {
  width: 100%;
  min-height: 44px;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  padding: 10px 14px;
}

.staff-short__form input[type="search"]:focus {
  outline: 3px solid var(--brand);
  outline-offset: 0;
  border-color: var(--brand-dark);
}

.staff-short__form > .staff-picker {
  max-width: none;
}

.staff-sections__list {
  margin: -6px 8px 10px;
  font-size: 0.88rem;
  color: var(--ink-muted);
  overflow-wrap: anywhere;
}

.staff-list-add__form {
  display: grid;
  gap: 26px;
}

.staff-list-add__form > .staff-form__field,
.staff-list-add__names {
  max-width: 40rem;
}

.staff-list-add__names {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 16px;
}

.staff-sections input[type="email"] {
  width: 100%;
  min-height: 44px;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  padding: 10px 14px;
}

.staff-list-add__people.staff-pco__panel {
  margin: 0;
  box-shadow: none;
  border: 1px solid var(--border);
}

.staff-list-add__empty {
  border: 1px dashed var(--border);
  border-radius: 12px;
}

.staff-list-bulk__count {
  margin: 8px 0 6px;
  font-size: 1.05rem;
}

@media (max-width: 860px) {
  .staff-list-member__side {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}

/* Tables, sample B (owner, 19 November 2026): check-ins as grouped rows.
   One card per event and day; its head has the event, the day and the
   count, then a small bar chart by location (name, bar, number). Under it
   the check-ins as rows: photo, name, the location tag and the time on the
   right in tabular figures. */
.staff-check-ins.staff-pco__panel {
  padding: 0;
  overflow: hidden;
  margin-bottom: 20px;
}

.staff-check-ins__head {
  display: grid;
  gap: 10px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.staff-check-ins__title {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px 12px;
}

.staff-check-ins__title h2,
.staff-check-ins__title h3,
.staff-check-ins__title h4 {
  margin: 0;
  font-size: 1.02rem;
  overflow-wrap: anywhere;
}

.staff-check-ins__when {
  font-size: 0.86rem;
  color: var(--ink-muted);
}

.staff-check-ins__bars {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.staff-check-ins__bar {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr) 40px;
  align-items: center;
  gap: 10px;
  font-size: 0.84rem;
}

.staff-check-ins__bar-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-check-ins__track {
  height: 8px;
  border-radius: 999px;
  background: var(--canvas);
  overflow: hidden;
}

.staff-check-ins__fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--brand-dark);
}

.staff-check-ins__bar b {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.staff-check-ins__rows {
  list-style: none;
  margin: 0;
  padding: 0;
}

.staff-row--check-in {
  grid-template-columns: 40px minmax(0, 1fr) auto 72px;
}

.staff-row--check-in.staff-row--check-in-plain {
  grid-template-columns: minmax(0, 1fr) auto 72px;
}

.staff-row--check-in-plain .staff-row__title {
  font-weight: 600;
}

/* The tag keeps its own column until the phone layout below. */
.staff-row--check-in .staff-tag {
  grid-column: auto;
  grid-row: auto;
  justify-self: end;
}

.staff-row__time {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-size: 0.88rem;
  color: var(--ink-muted);
  white-space: nowrap;
}

@media (max-width: 700px) {
  .staff-check-ins__bar {
    grid-template-columns: minmax(0, 1fr) 40px;
  }

  .staff-check-ins__track {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .staff-row--check-in {
    grid-template-columns: 40px minmax(0, 1fr) 64px;
  }

  .staff-row--check-in .staff-tag {
    grid-column: 2;
    grid-row: 2;
    justify-self: start;
  }

  .staff-row--check-in .staff-row__time {
    grid-column: 3;
    grid-row: 1;
  }

  .staff-row--check-in.staff-row--check-in-plain {
    grid-template-columns: minmax(0, 1fr) 64px;
  }

  .staff-row--check-in-plain .staff-tag {
    grid-column: 1;
  }

  .staff-row--check-in-plain .staff-row__time {
    grid-column: 2;
  }
}

/* Tags, more tones (layout B, owner 19 November 2026): red for a failure,
   blue while something runs, amber for something to look at. */
.staff-tag--error {
  background: var(--staff-error-bg);
  color: var(--staff-error-ink);
}

.staff-tag--info {
  background: var(--staff-info-bg);
  color: var(--staff-info-ink);
}

.staff-tag--warning {
  background: var(--staff-warning-bg);
  color: var(--staff-warning-ink);
}

/* Messages, sample A: the second line of an error, what to do next. */
.staff-banner__next {
  display: block;
  margin-top: 2px;
  font-weight: 400;
}

/* The dashboard's sync message takes the whole width of the page head. */
.staff-overview__sync .staff-pco-sync__message {
  flex-basis: 100%;
}

.staff-overview__sync .staff-pco-sync__message .staff-banner {
  margin: 0;
}

/* Rows with their own actions (Staff access, Group digests): the buttons
   sit above the row's link area. */
.staff-row--actions > form,
.staff-row__actions {
  position: relative;
  z-index: 1;
  margin: 0;
}

.staff-row__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.staff-row__actions form {
  margin: 0;
}

.staff-row__error {
  margin: 4px 0 0;
  font-size: 0.86rem;
  color: var(--staff-error-ink);
  overflow-wrap: anywhere;
}

@media (max-width: 860px) {
  .staff-row--actions.staff-row--plain {
    grid-template-columns: minmax(0, 1fr);
  }

  .staff-row--actions > form,
  .staff-row__actions {
    justify-self: start;
  }
}

/* Tables sample B: the sync log, one row per sync with its result tag
   first, then the start time, who started it and how long it took, what
   it copied, and the error in red when it failed. */
.staff-row--sync {
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: start;
}

.staff-row--sync .staff-tag {
  justify-self: start;
  grid-column: auto;
  margin-top: 2px;
}

.staff-row--sync .staff-row__title {
  font-weight: 600;
}

.staff-row--sync .staff-spinner {
  vertical-align: -2px;
}

@media (max-width: 860px) {
  .staff-row--sync {
    grid-template-columns: minmax(0, 1fr);
  }

  .staff-row--sync .staff-tag {
    grid-column: 1;
  }
}

/* Tools reports (Mailjet, Sinch SMS and the app's send log), tables
   sample B: the report's name in its own card, sections of day groups
   and rows, and the window counts as rows. */
.staff-provider__head.staff-pco__panel {
  margin-bottom: 20px;
}

.staff-provider__head .staff-dash__note {
  margin: 4px 0 0;
}

.staff-provider__section {
  margin: 28px 0;
}

.staff-provider__section > .staff-dash__note {
  margin: -4px 0 12px;
}

.staff-provider__windows.staff-pco__panel,
.staff-provider__days.staff-pco__panel {
  margin-bottom: 20px;
}

.staff-row--report .staff-row__title {
  font-weight: 600;
  overflow-wrap: anywhere;
}

/* Group digests: the all-groups switch in the side card. */
.staff-digests__all {
  display: grid;
  gap: 8px;
}

.staff-digests__all .staff-tag {
  margin-left: 6px;
  vertical-align: 1px;
}

.staff-digests__bulk-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.staff-digests__bulk-actions form {
  margin: 0;
}

/* Staff access: the side card holds the add forms, so it scrolls with the
   page instead of sticking. */
.staff-rail.staff-pco__panel.staff-access__side {
  position: static;
}

.staff-access__side .staff-short__form {
  padding: 0;
  gap: 14px;
  border: 0;
  box-shadow: none;
  background: none;
}

.staff-access__you {
  display: grid;
  gap: 8px;
}

.staff-access__you-tag {
  margin-left: 6px;
  vertical-align: 1px;
}

.staff-access__fixed-head {
  margin-top: 28px;
}

/* Email templates: the emails as rows beside the preview. */
.staff-emails__layout {
  grid-template-columns: 300px minmax(0, 1fr);
}

.staff-emails__row--current {
  background: var(--staff-success-bg);
}

.staff-emails__preview.staff-pco__panel {
  margin: 0;
  display: grid;
  gap: 16px;
}

.staff-emails__preview-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px 24px;
}

.staff-emails__preview-head .staff-pco__panel-title {
  margin: 0;
}

.staff-emails__picker {
  display: grid;
  gap: 6px;
  min-width: min(100%, 280px);
}

.staff-emails__picker .staff-form__hint {
  margin: 0;
}

@media (max-width: 860px) {
  .staff-emails__layout {
    grid-template-columns: 1fr;
  }
}

/* App use: the other lists in the side card, and when each person first
   signed in on the right of their row. */
.staff-app-use__lists ul {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  gap: 2px;
}

.staff-app-use__lists a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 10px;
  color: var(--ink);
  font-weight: 600;
}

.staff-app-use__lists a:hover {
  background: var(--canvas);
  text-decoration: none;
}

.staff-app-use__lists a[aria-current="page"] {
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
}

.staff-app-use__first {
  white-space: normal;
  text-align: right;
}

@media (max-width: 860px) {
  .staff-app-use__rows .staff-app-use__first {
    grid-column: 2;
    text-align: left;
  }
}

/* A media item's files (owner, 20 November 2026): the list, the upload rows
   with their progress bars, and the drop zone. */
.staff-media-files__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.staff-media-files__count {
  color: var(--ink-muted);
  font-size: 0.9rem;
}

.staff-media-files__queue {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.staff-media-files__upload {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.staff-media-files__upload.is-failed {
  border-color: var(--staff-error-ink);
  background: var(--staff-error-bg);
}

.staff-media-files__upload.is-failed .staff-media-files__upload-status {
  color: var(--staff-error-ink);
}

.staff-media-files__upload-main {
  flex: 1 1 260px;
  min-width: 0;
}

.staff-media-files__upload-name {
  margin: 0 0 6px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.staff-media-files__upload-size {
  color: var(--ink-muted);
  font-weight: 400;
  font-size: 0.86rem;
}

.staff-media-files__upload-status {
  margin: 6px 0 0;
}

.staff-media-files__upload-actions {
  display: flex;
  gap: 8px;
}

.staff-media-files__bar {
  display: block;
  width: 100%;
  height: 8px;
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  border-radius: 999px;
  background: var(--canvas);
  overflow: hidden;
}

.staff-media-files__bar::-webkit-progress-bar {
  background: var(--canvas);
  border-radius: 999px;
}

.staff-media-files__bar::-webkit-progress-value {
  background: var(--brand-dark);
  border-radius: 999px;
}

.staff-media-files__bar::-moz-progress-bar {
  background: var(--brand-dark);
  border-radius: 999px;
}

.staff-media-files__zone {
  margin-top: 14px;
  padding: 24px 16px;
  border: 2px dashed #c9c9d0;
  border-radius: 12px;
  text-align: center;
  display: grid;
  justify-items: center;
  gap: 8px;
}

.staff-media-files__zone.is-over {
  border-color: var(--brand-dark);
  background: var(--staff-success-bg);
}

.staff-media-files__zone-text {
  margin: 0;
}

.staff-media-files__zone .staff-form__hint {
  margin: 0;
}

.staff-button--small {
  min-height: 36px;
  padding: 6px 14px;
  font-size: 0.88rem;
}

.staff-button--icon {
  min-width: 36px;
  padding-inline: 0;
  justify-content: center;
}

/* A staff date field and its calendar pop-up (owner, 20 November 2026): the
   browser's own calendar icon is hidden and ours sits inside the field. */
.staff-date {
  position: relative;
  max-width: 18rem;
}

.staff-date input[type="date"] {
  padding-right: 48px;
}

.staff-date input[type="date"]::-webkit-calendar-picker-indicator {
  display: none;
}

.staff-date__button {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink-muted);
  cursor: pointer;
}

.staff-date__button:hover,
.staff-date__button[aria-expanded="true"] {
  background: var(--staff-success-bg);
  color: var(--brand-ink);
}

.staff-date__button:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 0;
}

.staff-calendar {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 20;
  width: 300px;
  max-width: 90vw;
  padding: 14px;
  background: var(--surface);
  color: var(--ink);
  color-scheme: light;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow), 0 12px 32px rgba(0, 0, 0, 0.12);
}

.staff-calendar__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.staff-calendar__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
}

.staff-calendar__nav {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}

.staff-calendar__nav:hover {
  background: var(--canvas);
}

.staff-calendar__grid {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.staff-calendar__grid th {
  padding: 4px 0 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.staff-calendar__grid td {
  padding: 2px;
  text-align: center;
}

.staff-calendar__day {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.92rem;
  cursor: pointer;
}

.staff-calendar__day:hover {
  background: var(--canvas);
}

.staff-calendar__day.is-outside {
  color: #a5a5ab;
}

.staff-calendar__day.is-today {
  box-shadow: inset 0 0 0 2px var(--brand-dark);
  font-weight: 700;
}

.staff-calendar__day.is-chosen,
.staff-calendar__day.is-chosen:hover {
  background: var(--brand);
  color: var(--brand-ink);
  font-weight: 700;
}

.staff-calendar__day:focus-visible,
.staff-calendar__nav:focus-visible,
.staff-calendar__link:focus-visible {
  outline: 3px solid var(--brand-dark);
  outline-offset: 1px;
}

.staff-calendar__foot {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
}

.staff-calendar__link {
  border: 0;
  background: transparent;
  color: var(--brand-ink);
  font: inherit;
  font-weight: 600;
  padding: 6px 8px;
  border-radius: 8px;
  cursor: pointer;
}

.staff-calendar__link:hover {
  background: var(--staff-success-bg);
}

.staff-media-files__upload.is-done {
  background: var(--staff-success-bg);
  border-color: transparent;
}

.staff-media-files__upload.is-done .staff-media-files__upload-status {
  color: var(--staff-success-ink);
  font-weight: 600;
}

.staff-media-files[aria-invalid="true"] .staff-media-files__zone {
  border-color: var(--staff-error-ink);
}

/* A media item's files as a grid of thumbnail cards (owner, 20 November
   2026). */
.staff-media-files__list {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
  gap: 14px;
}

.staff-media-files__list:empty {
  display: none;
}

.staff-media-file {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.staff-media-file__thumb {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 11px 11px 0 0;
  overflow: hidden;
  background: var(--canvas);
}

.staff-media-file__thumb--video {
  background: #000;
}

.staff-media-file__thumb-link {
  display: block;
  width: 100%;
  height: 100%;
}

.staff-media-file__image,
.staff-media-file__player {
  display: block;
  width: 100%;
  height: 100%;
}

.staff-media-file__image {
  object-fit: cover;
}

.staff-media-file__player {
  object-fit: contain;
}

.staff-media-file__tile {
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 8px;
  width: 100%;
  height: 100%;
  color: var(--ink-muted);
  text-decoration: none;
}

.staff-media-file__type {
  display: grid;
  place-items: center;
  min-width: 64px;
  height: 64px;
  padding: 0 10px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--brand-ink);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.staff-media-file__thumb--music .staff-media-file__type {
  background: var(--staff-success-bg);
}

.staff-media-file__open {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--brand-ink);
}

.staff-media-file__thumb-link:hover .staff-media-file__open {
  text-decoration: underline;
}

.staff-media-file__thumb-link:focus-visible {
  outline: 3px solid var(--brand-dark);
  outline-offset: -3px;
}

.staff-media-file__body {
  padding: 10px 12px 0;
  min-width: 0;
}

.staff-media-file__label {
  margin: 0;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.staff-media-file__meta {
  margin: 2px 0 0;
  color: var(--ink-muted);
  font-size: 0.82rem;
  overflow-wrap: anywhere;
}

.staff-media-file__audio {
  display: block;
  width: 100%;
  height: 36px;
  margin-top: 8px;
}

.staff-media-file__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 10px 12px 12px;
  margin-top: auto;
}

.staff-media-file__move {
  display: inline-flex;
  gap: 4px;
}

.staff-media-file__move-form {
  display: inline;
  margin: 0;
}

/* No Move earlier on the first file, no Move later on the last. */
.staff-media-file:first-child .staff-media-file__move .staff-media-file__move-form:first-child,
.staff-media-file:last-child .staff-media-file__move .staff-media-file__move-form:last-child {
  visibility: hidden;
}

.staff-media-file__rename {
  position: relative;
}

.staff-media-file__rename > summary {
  list-style: none;
  cursor: pointer;
}

.staff-media-file__rename > summary::-webkit-details-marker {
  display: none;
}

.staff-media-file__rename[open] > summary {
  background: var(--canvas);
}

.staff-media-file__rename-form {
  position: absolute;
  left: 0;
  bottom: calc(100% + 6px);
  z-index: 5;
  width: min(300px, 80vw);
  display: grid;
  gap: 8px;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.staff-media-file__rename-form .staff-field__input {
  width: 100%;
  min-height: 40px;
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  padding: 8px 12px;
}

.staff-media-file__rename-form .staff-field__input:focus {
  outline: 3px solid var(--brand);
  outline-offset: 0;
  border-color: var(--brand-dark);
}

.staff-media-file__rename-form .staff-button {
  justify-self: end;
}

/* The save bar on a short form (owner, 20 November 2026: the same floating
   bar as the edit pages, on New forms and the short edit forms). It runs
   the full width of the form card and stays at the bottom of the screen
   while the form is in view. */
.staff-short__form > .staff-short__savebar {
  margin: 4px -28px -24px;
  border-width: 1px 0 0;
  border-radius: 0 0 var(--radius) var(--radius);
}

/* Choosing a media item's card image from its own images (owner, 20
   November 2026): thumbnail tiles, the chosen one ringed in green. */
.staff-card-pick {
  border: 0;
  padding: 0;
  min-width: 0;
}

.staff-card-pick__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr));
  gap: 12px;
}

.staff-card-pick__option {
  position: relative;
  display: grid;
  gap: 6px;
  padding: 6px;
  border: 2px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  cursor: pointer;
}

.staff-card-pick__option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.staff-card-pick__option:has(input:checked) {
  border-color: var(--brand-dark);
  box-shadow: 0 0 0 3px var(--staff-success-bg);
}

.staff-card-pick__option:has(input:checked)::after {
  content: "✓";
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: var(--brand);
  color: var(--brand-ink);
  font-weight: 700;
}

.staff-card-pick__option:has(input:focus-visible) {
  outline: 3px solid var(--brand-dark);
  outline-offset: 2px;
}

.staff-card-pick__image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 8px;
  background: var(--canvas);
}

.staff-card-pick__name {
  font-size: 0.85rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}

/* Tiles stacked one per row, each with a second line (New newsletter's
   Start from, real-life#178). */
.staff-tiles--stack {
  display: grid;
  max-height: 420px;
  overflow-y: auto;
  padding: 2px;
}

.staff-tiles--stack .staff-tile span {
  display: block;
  width: 100%;
  padding: 10px 16px;
  line-height: 1.4;
}

.staff-tiles--stack .staff-tile small {
  font-weight: 500;
  color: var(--ink-muted);
}

/* The newsletter editor (real-life#178, sample A, owner 20 November 2026):
   a top bar, the subject card, then the blocks to add, the email itself and
   the chosen block's settings. */
.staff-nl__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  padding: 12px 16px;
  margin: 0 0 16px;
}

.staff-nl__bar-left,
.staff-nl__bar-right {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.staff-nl__delete {
  margin: 0;
}

.staff-nl__saved {
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--ink-muted);
}

.staff-nl__saved.is-saved {
  color: var(--staff-success-ink);
}

.staff-nl__saved.is-saved::before {
  content: "✓ ";
}

.staff-nl__saved.is-error {
  color: var(--staff-error-ink);
}

.staff-nl__seg {
  display: inline-flex;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: var(--surface);
}

.staff-nl__seg button,
.staff-nl__seg label span {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-muted);
  cursor: pointer;
}

.staff-nl__seg button[aria-pressed="true"],
.staff-nl__seg input:checked + span {
  background: var(--church-button, #5e7f67);
  color: #fff;
}

.staff-nl__seg label {
  position: relative;
  margin: 0;
}

.staff-nl__seg input {
  position: absolute;
  opacity: 0;
  inset: 0;
  margin: 0;
  cursor: pointer;
}

.staff-nl__seg input:focus-visible + span {
  outline: 3px solid var(--staff-focus);
  outline-offset: -3px;
}

.staff-nl__choice {
  border: 0;
  padding: 0;
  min-width: 0;
}

.staff-nl__subject {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 14px 20px;
  padding: 16px 20px;
  margin: 0 0 16px;
}

.staff-nl__subject .staff-form__field,
.staff-nl__inspector .staff-form__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
}

.staff-nl__subject .staff-field__input,
.staff-nl__inspector .staff-field__input {
  width: 100%;
  min-height: 44px;
  font: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  padding: 9px 12px;
}

.staff-nl__subject .staff-field__input:focus,
.staff-nl__inspector .staff-field__input:focus {
  outline: 3px solid var(--brand);
  outline-offset: 0;
  border-color: var(--brand-dark);
}

.staff-nl__grid {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr) 290px;
  gap: 16px;
  align-items: start;
}

@media (max-width: 1150px) {
  .staff-nl__grid {
    grid-template-columns: 190px minmax(0, 1fr);
  }

  .staff-nl__inspector {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .staff-nl__grid {
    grid-template-columns: 1fr;
  }
}

.staff-nl__palette,
.staff-nl__inspector {
  margin: 0;
  padding: 14px;
  position: sticky;
  top: 16px;
  display: grid;
  gap: 12px;
}

.staff-nl__side-title {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-muted);
}

.staff-nl__palette ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.staff-nl__palette button {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink);
  text-align: left;
  cursor: grab;
}

.staff-nl__palette button:hover {
  border-color: var(--brand-dark);
  background: var(--staff-success-bg);
}

.staff-nl__icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: var(--canvas);
  color: var(--church-header, #304b3b);
  font-size: 0.8rem;
  font-weight: 800;
}

.staff-nl__icon--heading::before { content: "H"; }
.staff-nl__icon--text::before { content: "¶"; }
.staff-nl__icon--image::before { content: "▣"; }
.staff-nl__icon--button::before { content: "▭"; }
.staff-nl__icon--divider::before { content: "—"; }
.staff-nl__icon--spacer::before { content: "↕"; }
.staff-nl__icon--social::before { content: "@"; }
.staff-nl__icon--logo::before { content: "◎"; }

.staff-nl__stage {
  min-width: 0;
  /* Room above the email for the first block's toolbars. */
  padding: 60px 12px 72px;
  border-radius: var(--radius);
  background: #e6e6eb;
  overflow-x: auto;
}

.staff-nl__email {
  width: 600px;
  max-width: 100%;
  margin: 0 auto;
  background: #fff;
  border-collapse: collapse;
  font-family: Helvetica, Arial, sans-serif;
  color: #222;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  transition: width 0.2s;
}

.staff-nl__email.is-phone {
  width: 375px;
}

.staff-nl__email.is-phone .nl-pad {
  padding-left: 18px !important;
  padding-right: 18px !important;
}

.staff-nl__email.is-phone .nl-half {
  width: 100% !important;
}

.staff-nl__email .nl-row > td {
  position: relative;
  outline: 2px solid transparent;
  outline-offset: -2px;
  cursor: pointer;
}

.staff-nl__email .nl-row:hover > td {
  outline-color: #cfe5b8;
}

.staff-nl__email .nl-row.is-on > td {
  outline-color: var(--brand-dark);
}

.staff-nl__email .nl-row:focus-visible {
  outline: none;
}

.staff-nl__email .nl-row:focus-visible > td {
  outline: 3px solid var(--staff-focus);
}

.staff-nl__email .nl-row.is-drop-before > td {
  box-shadow: inset 0 4px 0 var(--brand-dark);
}

.staff-nl__email img {
  max-width: 100%;
}

.staff-nl__email [contenteditable="true"] {
  cursor: text;
  outline: none;
}

.staff-nl__email .nl-row.is-on [contenteditable="true"]:focus {
  outline: 2px dashed var(--brand);
  outline-offset: 3px;
}

/* Above the chosen block, never over its text (owner, 20 November 2026). */
.staff-nl__tools,
.staff-nl__fmt {
  position: absolute;
  bottom: calc(100% + 6px);
  z-index: 3;
  display: flex;
  gap: 2px;
  padding: 3px;
  border-radius: 9px;
  font-family: var(--font);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
}

.staff-nl__tools {
  right: 8px;
  background: var(--church-header, #304b3b);
}

/* The formatting bar sits just under the text it formats (owner, 20
   November 2026): the block toolbar is above, and the email can be
   narrower than both side by side. It wraps at the Phone width. */
.staff-nl__fmt {
  left: 12px;
  top: calc(100% + 6px);
  bottom: auto;
  max-width: calc(100% - 24px);
  flex-wrap: wrap;
  background: #fff;
  border: 1px solid var(--border);
}

.staff-nl__tools button,
.staff-nl__fmt button,
.staff-nl__grip {
  display: grid;
  place-items: center;
  min-width: 32px;
  height: 32px;
  padding: 0 6px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
}

.staff-nl__tools button,
.staff-nl__grip {
  color: #fff;
}

.staff-nl__tools button:hover,
.staff-nl__grip:hover {
  background: rgba(255, 255, 255, 0.15);
}

.staff-nl__tools button:disabled {
  opacity: 0.35;
  cursor: default;
}

.staff-nl__grip {
  cursor: grab;
}

.staff-nl__fmt button {
  color: var(--ink);
}

.staff-nl__fmt button:hover {
  background: var(--canvas);
}

.staff-nl__tools-name {
  align-self: center;
  padding: 0 8px 0 6px;
  color: #cfe5b8;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.staff-nl__thumb {
  display: block;
  width: 100%;
  border-radius: 8px;
}

.staff-nl__upload {
  justify-self: start;
  cursor: pointer;
}

.staff-nl__preview {
  width: min(720px, 96vw);
}

.staff-nl__preview .staff-dialog__header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.staff-nl__preview .staff-dialog__title {
  margin-right: auto;
}

.staff-nl__preview-body {
  background: #e6e6eb;
  padding: 16px;
  overflow: auto;
}

.staff-nl__preview iframe {
  display: block;
  height: 70vh;
  max-width: 100%;
  margin: 0 auto;
  border: 0;
  background: #fff;
  transition: width 0.2s;
}

/* The newsletter logo on Engagement settings, on the green it sits on. */
.staff-engagement__logo {
  padding: 18px;
  border-radius: 10px;
  background: var(--church-header, #304b3b);
}

.staff-engagement__logo img {
  display: block;
  max-height: 60px;
  width: auto;
  margin: 0 auto;
}

.staff-nl__undo {
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-weight: 700;
  color: var(--brand-ink);
  text-decoration: underline;
  cursor: pointer;
}

/* A message on the editor sits in the page's 16px rhythm, between the top
   bar and the subject card; an empty slot takes no room. */
.staff-nl__notice {
  margin: 0 0 16px;
}

.staff-nl__notice:empty {
  display: none;
}

/* Text only screen readers hear. */
.staff-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* The newsletter steps (real-life#179, steps sample A, owner 20 November
   2026): To, Content, Test and Send across the top; the current step is
   filled, a finished one has a check. */
.staff-nl-steps {
  margin: 0 0 16px;
  padding: 8px;
}

.staff-nl-steps ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 6px;
  overflow-x: auto;
}

.staff-nl-steps li {
  flex: 1 1 0;
  min-width: 150px;
}

.staff-nl-steps__step {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 8px 12px;
  border-radius: 10px;
  color: var(--ink-muted);
  text-decoration: none;
}

.staff-nl-steps__step:hover {
  background: var(--canvas);
}

.staff-nl-steps__step[aria-current="step"] {
  background: var(--staff-success-bg);
}

.staff-nl-steps__n {
  flex: none;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid #c9c9d0;
  background: var(--surface);
  font-weight: 800;
  color: var(--ink-muted);
}

.staff-nl-steps__step.is-done .staff-nl-steps__n {
  border-color: var(--brand-dark);
  background: var(--brand);
  color: var(--brand-ink);
}

.staff-nl-steps__step[aria-current="step"] .staff-nl-steps__n {
  border-color: var(--church-header, #304b3b);
  background: var(--church-header, #304b3b);
  color: #fff;
}

.staff-nl-steps__text b {
  display: block;
  color: var(--ink);
  font-size: 0.92rem;
}

.staff-nl-steps__text small {
  font-size: 0.78rem;
}

.staff-nl-step {
  margin: 0;
  padding: 22px 24px;
  display: grid;
  gap: 14px;
}

.staff-nl-step__title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
}

.staff-nl-step__lead {
  margin: -8px 0 0;
  max-width: 42rem;
  color: var(--ink-muted);
}

.staff-nl-step__field {
  max-width: 32rem;
}

.staff-nl-step .staff-field__input {
  width: 100%;
  min-height: 44px;
  font: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  padding: 9px 12px;
}

.staff-nl-step .staff-field__input:focus {
  outline: 3px solid var(--brand);
  outline-offset: 0;
  border-color: var(--brand-dark);
}

.staff-nl-step__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.staff-nl-stepbar {
  margin-top: 16px;
}

.staff-nl-lists,
.staff-nl-when {
  display: grid;
  gap: 8px;
  max-width: 42rem;
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}

.staff-nl-option {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 10px 14px;
  border: 1px solid #c9c9d0;
  border-radius: 12px;
  background: var(--surface);
  cursor: pointer;
}

.staff-nl-option input {
  flex: none;
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--church-header, #304b3b);
}

.staff-nl-option:has(input:checked) {
  border-color: var(--church-header, #304b3b);
  background: var(--staff-success-bg);
}

.staff-nl-option:has(input:focus-visible) {
  outline: 3px solid var(--staff-focus);
  outline-offset: 2px;
}

.staff-nl-option__text {
  min-width: 0;
}

.staff-nl-option__text b {
  display: block;
}

.staff-nl-option__text small {
  display: block;
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.staff-nl-option__count {
  margin-left: auto;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.staff-nl-lists__total {
  margin: 0;
  font-weight: 700;
}

.staff-nl-when__later {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
  padding: 4px 0 0 46px;
}

.staff-nl-when__later .staff-form__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  min-width: 180px;
}

.staff-nl-facts {
  max-width: 42rem;
}

/* Engagement settings (owner, 20 November 2026): the form, and beside it a
   live preview of the real email template with these settings. */
.staff-settings-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 460px);
  gap: 16px;
  align-items: start;
}

@media (max-width: 980px) {
  .staff-settings-layout {
    grid-template-columns: 1fr;
  }
}

.staff-settings-preview {
  margin: 0;
  padding: 16px;
  display: grid;
  gap: 12px;
  position: sticky;
  top: 16px;
}

.staff-settings-preview__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px 12px;
}

.staff-settings-preview__inbox {
  margin: 0;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 0.88rem;
  display: grid;
  gap: 2px;
}

.staff-settings-preview__inbox span {
  color: var(--ink-muted);
}

.staff-settings-preview__frame {
  display: block;
  width: 100%;
  height: 560px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #f2f2f7;
}

/* Toolbars beside the email (owner, 20 November 2026): formatting on the
   left of the chosen block, the block toolbar on its right, both outside
   the email so they never cover it. When the editing area is too narrow
   for that, they stay above (tools) and below (formatting) the block. */
.staff-nl__stage {
  container-type: inline-size;
}

@container (min-width: 920px) {
  .staff-nl__email .staff-nl__tools,
  .staff-nl__email .staff-nl__fmt {
    top: 0;
    bottom: auto;
    max-width: none;
  }

  /* The block toolbar: a column of buttons with their words. */
  .staff-nl__email .staff-nl__tools {
    left: calc(100% + 12px);
    right: auto;
    flex-direction: column;
    flex-wrap: nowrap;
    min-width: 128px;
    padding: 6px;
  }

  .staff-nl__email .staff-nl__tools button,
  .staff-nl__email .staff-nl__grip {
    justify-content: start;
    grid-auto-flow: column;
    gap: 8px;
    padding: 0 10px;
    height: 36px;
  }

  .staff-nl__email .staff-nl__tool-word {
    display: inline;
    font-weight: 600;
  }

  /* The formatting bar: two columns of buttons. */
  .staff-nl__email .staff-nl__fmt {
    left: auto;
    right: calc(100% + 12px);
    display: grid;
    grid-template-columns: repeat(2, minmax(56px, auto));
    padding: 6px;
  }

  .staff-nl__email .staff-nl__fmt button {
    height: 36px;
    padding: 0 10px;
  }
}

/* The words beside the block tool icons show only beside the email. */
.staff-nl__tool-word {
  display: none;
}

/* The gray hint of an empty heading or text block in the editor. */
.staff-nl__email [data-hint]:empty::before {
  content: attr(data-hint);
  color: #9a9aa0;
  font-style: normal;
  font-weight: 400;
}

/* Beside the email (owner, 20 November 2026): both toolbars centered on
   the chosen block; the formatting buttons each have a border and never
   wrap their words. */
@container (min-width: 920px) {
  .staff-nl__email .staff-nl__tools,
  .staff-nl__email .staff-nl__fmt {
    top: 50%;
    transform: translateY(-50%);
  }

  .staff-nl__email .staff-nl__fmt {
    grid-template-columns: repeat(2, auto);
    gap: 6px;
    padding: 8px;
  }

  .staff-nl__email .staff-nl__fmt button {
    border: 1px solid var(--border);
    border-radius: 8px;
    white-space: nowrap;
    min-width: 64px;
  }

  .staff-nl__email .staff-nl__fmt button:hover {
    border-color: var(--brand-dark);
  }
}

/* A hint under a checkbox, lined up with the box's label. */
.staff-form__hint--indent {
  margin: 2px 0 0 26px;
}

/* The test recipient picker (owner, 20 November 2026): chosen addresses
   as chips, then a search of the church's people with a list under it. */
.staff-picker__chips {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.staff-picker__chips:empty {
  display: none;
}

.staff-picker__chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 36px;
  padding: 0 4px 0 12px;
  border: 1px solid var(--staff-success-edge);
  border-radius: 999px;
  background: var(--staff-success-bg);
  color: var(--staff-success-ink);
  font-size: 0.88rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.staff-picker__remove {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 1.1rem;
  cursor: pointer;
}

.staff-picker__remove:hover {
  background: rgba(0, 0, 0, 0.08);
}

.staff-picker__box {
  position: relative;
}

.staff-picker__list {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 10;
  max-height: 280px;
  overflow-y: auto;
  margin: 0;
  padding: 6px;
  list-style: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow), 0 12px 32px rgba(0, 0, 0, 0.12);
}

.staff-picker__option {
  display: grid;
  gap: 1px;
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
}

.staff-picker__option span {
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.staff-picker__option[aria-selected="true"],
.staff-picker__option:hover {
  background: var(--staff-success-bg);
}

.staff-picker__empty {
  padding: 8px 10px;
  color: var(--ink-muted);
  font-size: 0.88rem;
}

/* A newsletter row's send time (owner, 20 November 2026). */
.staff-newsletters__when {
  color: var(--ink);
  font-weight: 600;
}

/* "That time has passed": under the date and time, full width. */
.staff-nl-when__error {
  order: 3;
  flex-basis: 100%;
  margin: 0;
}

/* The Message step of a text (owner, 20 November 2026): the text on the
   left, the length and cost panel on the right, staying in view. */
.staff-sms {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 340px);
  gap: 24px;
  align-items: start;
}

@media (max-width: 860px) {
  .staff-sms {
    grid-template-columns: 1fr;
  }
}

.staff-sms__write {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.staff-sms__write .staff-form__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
}

.staff-sms__body {
  min-height: 150px;
  resize: vertical;
  line-height: 1.5;
}

.staff-sms__panel {
  position: sticky;
  top: 16px;
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fafafc;
}

.staff-sms__meter {
  display: flex;
  gap: 4px;
}

.staff-sms__meter span {
  position: relative;
  flex: 1;
  height: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
}

.staff-sms__meter i {
  position: absolute;
  inset: 0 auto 0 0;
  background: var(--brand-dark);
}

.staff-sms__meter.is-unicode i {
  background: #c58b1c;
}

.staff-sms__facts dd {
  font-variant-numeric: tabular-nums;
}

.staff-sms__bubble {
  max-width: 100%;
  margin: 6px 0 0;
  padding: 10px 14px;
  border-radius: 18px 18px 18px 6px;
  background: #e9e9ee;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.staff-sms__bubble-end {
  color: var(--ink-muted);
}

.staff-sms__costly {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid #f1d7a6;
  border-radius: 12px;
  background: var(--staff-warning-bg);
  color: var(--staff-warning-ink);
}

.staff-sms__costly p {
  margin: 0;
}

.staff-sms__costly-lead {
  font-weight: 700;
}

.staff-sms__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.staff-sms__chip {
  display: inline-grid;
  place-items: center;
  min-width: 34px;
  height: 34px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid #f1d7a6;
  font-size: 1.05rem;
}

.staff-sms__costly .staff-button {
  justify-self: start;
}

.staff-sms__rate {
  max-width: 12rem;
}

.staff-sms__costly[hidden] {
  display: none;
}

/* An element with the hidden attribute is hidden, whatever display its own
   class sets (owner, 20 November 2026: the schedule fields and the costly
   characters box showed when hidden). */
.staff [hidden] {
  display: none !important;
}

/* A canceled newsletter or text (owner, 20 November 2026): gray, not red,
   since nothing went wrong. */
.staff-tag--canceled {
  background: #e4e4ea;
  color: #3f3f45;
}

/* Newsletter and text rows (owner, 20 November 2026): the title, the
   message as body text, then the activity as labeled facts after a gap,
   with more room around each row. */
.staff-rows .staff-row:has(.staff-msg-row) {
  padding-top: 16px;
  padding-bottom: 16px;
  align-items: start;
}

.staff-msg-row__preview {
  margin: 4px 0 0;
  max-width: 60rem;
  color: var(--ink);
  font-size: 0.95rem;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.staff-msg-row__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  margin: 10px 0 0;
  font-size: 0.84rem;
}

.staff-msg-row__facts div {
  display: flex;
  gap: 6px;
}

.staff-msg-row__facts dt {
  color: var(--ink-muted);
}

.staff-msg-row__facts dd {
  margin: 0;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.staff-msg-row__facts .is-strong dd {
  font-weight: 700;
}

/* The Engagement overview (sample D, owner 20 November 2026). */
.staff-eng {
  display: grid;
  gap: 16px;
}

.staff-eng__summary {
  margin: 0;
  padding: 0;
  overflow: hidden;
}

.staff-eng__stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
}

.staff-eng__stat {
  display: grid;
  gap: 2px;
  align-content: start;
  padding: 18px 20px;
  border-left: 1px solid var(--border);
}

.staff-eng__stat:first-child {
  border-left: 0;
}

@media (max-width: 860px) {
  .staff-eng__stat {
    border-left: 0;
    border-top: 1px solid var(--border);
  }

  .staff-eng__stat:first-child {
    border-top: 0;
  }
}

.staff-eng__stat b {
  font-size: 1.9rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.staff-eng__stat b.staff-eng__when {
  font-size: 1.15rem;
  line-height: 1.4;
}

.staff-eng__stat small {
  color: var(--ink-muted);
  font-size: 0.82rem;
}

.staff-eng__attn {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 12px 20px;
  border-top: 1px solid #f1d7a6;
  background: var(--staff-warning-bg);
  color: var(--staff-warning-ink);
  font-weight: 600;
  font-size: 0.9rem;
}

.staff-eng__attn-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--staff-warning-ink);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
}

.staff-eng__attn a {
  margin-left: auto;
  color: inherit;
}

.staff-eng__kinds {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

@media (max-width: 1000px) {
  .staff-eng__kinds {
    grid-template-columns: 1fr;
  }
}

/* A column, so a card stretched to its row's height can pin its chart to
   the bottom: the charts of a row then sit on one line (owner, 23 November
   2026). */
.staff-eng__kind {
  margin: 0;
  padding: 18px 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.staff-eng__kind > .staff-chart:last-child,
.staff-eng__kind > .staff-eng__charts:last-child {
  margin-top: auto;
}

/* The Check-ins card's two charts, one at a time: the segmented control's
   checked radio says which, so the card is as tall as the other two. */
.staff-eng__charts {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.staff-eng__charts-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
}

/* The picked chart's button is the primary color, like a primary button. */
.staff-eng__charts .staff-nl__seg input:checked + span {
  background: var(--church-button, #5e7f67);
  color: #fff;
}

.staff-eng__charts:has(input[value="check_ins"]:checked) [data-chart="headcounts"],
.staff-eng__charts:has(input[value="headcounts"]:checked) [data-chart="check_ins"] {
  display: none;
}

.staff-eng__big {
  font-size: 1.8rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.staff-eng__sub,
.staff-eng__untracked {
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.staff-eng__untracked {
  margin: 2px 0 0;
}

.staff-eng__latest {
  margin: 8px 0 0;
  font-size: 0.88rem;
}

.staff-eng__latest .staff-dash__kicker {
  display: block;
}

.staff-eng__lists {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

@media (max-width: 860px) {
  .staff-eng__lists {
    grid-template-columns: 1fr;
  }
}

.staff-eng__list {
  margin: 0;
  padding: 0;
  overflow: hidden;
}

.staff-eng__list-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px 16px;
  padding: 16px 20px 6px;
}

.staff-eng__list .staff-rows {
  margin: 0;
}

.staff-eng__row {
  padding-top: 14px;
  padding-bottom: 14px;
  align-items: start;
}

.staff-eng__empty {
  margin: 0;
  padding: 12px 20px 20px;
  color: var(--ink-muted);
}

/* A small bar chart (StaffChartsHelper): one series in the brand green. */
.staff-chart {
  position: relative;
  margin: 10px 0 0;
}

.staff-chart svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.staff-chart__grid {
  stroke: #ececf0;
  stroke-width: 1;
}

.staff-chart__axis {
  fill: var(--ink-muted);
  font-family: var(--font);
  font-size: 10px;
}

.staff-chart__bar {
  fill: var(--chart-color, var(--brand-dark, #6f9e43));
  pointer-events: none;
}

.staff-chart__bar.is-on {
  filter: brightness(0.82);
}

.staff-chart__hit {
  fill: transparent;
}

.staff-chart__tip {
  position: absolute;
  z-index: 5;
  transform: translate(-50%, calc(-100% - 6px));
  padding: 6px 9px;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  font-size: 0.78rem;
  white-space: nowrap;
  pointer-events: none;
}

/* The Sermons overview (sample D, owner 20 November 2026): this week's
   sermon beside its first-7-days chart, and the recent sermons table. */
.staff-serm__week {
  margin: 0;
  padding: 18px 20px;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 16px 28px;
  align-items: start;
}

@media (max-width: 900px) {
  .staff-serm__week {
    grid-template-columns: 1fr;
  }
}

.staff-serm__week-main {
  display: flex;
  gap: 16px;
  align-items: start;
  min-width: 0;
}

.staff-serm__image {
  flex: none;
  width: 140px;
  aspect-ratio: 16 / 9;
  max-width: 100%;
  object-fit: cover;
  border-radius: 10px;
}

@media (max-width: 560px) {
  .staff-serm__week-main {
    flex-direction: column;
  }

  .staff-serm__image {
    width: 100%;
  }
}

.staff-serm__week-text {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.staff-serm__title {
  margin: 0;
  font-size: 1.3rem;
  line-height: 1.3;
  text-wrap: balance;
}

.staff-serm__facts {
  margin-top: 8px;
}

.staff-serm__recent {
  margin: 0;
  padding: 0 0 8px;
  overflow: hidden;
}

.staff-serm__recent .staff-overview__table-wrap {
  padding: 4px 20px 8px;
}

.staff-serm__table th:not(:first-child),
.staff-serm__table td:not(:first-child) {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.staff-serm__date {
  display: block;
  color: var(--ink-muted);
  font-size: 0.82rem;
}

/* The People & Teams overview (sample D, owner 20 November 2026): a meter
   under each How people connect number, and horizontal bars for check-ins by
   location, service teams and membership. One series in the brand green. */
.staff-ppl__meter {
  display: block;
  height: 8px;
  margin: 6px 0 2px;
  border-radius: 999px;
  background: var(--canvas);
  overflow: hidden;
}

.staff-ppl__meter i,
.staff-ppl__track i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--chart-color, var(--brand-dark, #6f9e43));
}

.staff-ppl__bars {
  list-style: none;
  margin: 0;
  padding: 4px 0 14px;
}

.staff-ppl__bar {
  display: grid;
  grid-template-columns: minmax(0, 11rem) minmax(0, 1fr) 3.5rem;
  gap: 10px;
  align-items: center;
  padding: 6px 20px;
  font-size: 0.88rem;
}

.staff-ppl__bar-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-ppl__track {
  height: 10px;
  border-radius: 999px;
  background: var(--canvas);
  overflow: hidden;
}

.staff-ppl__bar b {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.staff-ppl__table-wrap {
  padding: 4px 20px 12px;
}

.staff-ppl__table td:nth-child(2),
.staff-ppl__table th:nth-child(2) {
  text-align: right;
  padding-right: 24px;
  font-variant-numeric: tabular-nums;
}

.staff-serm__title-link {
  color: var(--ink);
  text-decoration: none;
}

.staff-serm__title-link:hover {
  text-decoration: underline;
}

/* The Habits overview (sample D, owner 20 November 2026): the current habit
   beside this week's strip (people per day, like the app's week strip). */
.staff-hab__today {
  margin: 0;
  padding: 18px 20px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 16px 28px;
  align-items: start;
}

@media (max-width: 900px) {
  .staff-hab__today {
    grid-template-columns: 1fr;
  }
}

.staff-hab__today-text {
  display: grid;
  gap: 6px;
  justify-items: start;
  min-width: 0;
}

.staff-hab__prompt {
  margin: 4px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--canvas);
  font-size: 0.9rem;
}

.staff-hab__week {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.staff-hab__day {
  display: grid;
  gap: 4px;
  justify-items: center;
  color: var(--ink-muted);
  font-size: 0.78rem;
}

.staff-hab__day b {
  min-height: 1.2em;
  color: var(--ink);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
}

.staff-hab__day.is-today {
  color: var(--ink);
  font-weight: 700;
}

.staff-hab__col {
  position: relative;
  width: 100%;
  height: 86px;
  border-radius: 8px;
  background: var(--canvas);
  overflow: hidden;
}

.staff-hab__col i {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 8px 8px 0 0;
  background: var(--chart-color, var(--brand-dark, #6f9e43));
}

.staff-hab__day.is-future .staff-hab__col {
  background: repeating-linear-gradient(45deg, var(--canvas), var(--canvas) 4px, var(--surface) 4px, var(--surface) 8px);
}

.staff-hab__chart {
  padding: 0 20px;
}

/* The dashboard, layout A (owner, 20 November 2026): a note under each
   summary number, an action at the end of each attention row, a tile per
   area with a 12-week sparkline in the brand green, and On Home now, Coming
   up and New in Planning Center side by side. */
.staff-overview__note {
  color: var(--ink-muted);
  font-size: 0.82rem;
}

.staff-overview__alert .staff-overview__act {
  margin-left: auto;
  white-space: nowrap;
}

.staff-dash-areas {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

@media (max-width: 1000px) {
  .staff-dash-areas {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .staff-dash-areas {
    grid-template-columns: 1fr;
  }
}

.staff-dash-area {
  margin: 0;
  padding: 16px 20px 14px;
  display: grid;
  gap: 2px;
  align-content: start;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.staff-dash-area--link:hover {
  box-shadow: 0 0 0 2px var(--brand-dark), var(--shadow);
}

.staff-dash-area--link:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 2px;
}

.staff-dash-area__top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}

.staff-dash-area__go {
  color: var(--brand-dark);
  font-size: 0.8rem;
  font-weight: 600;
}

.staff-dash-area__go::after {
  content: " →";
}

.staff-dash-area__big {
  font-size: 1.7rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.staff-dash-area__unit {
  font-size: 0.88rem;
}

.staff-dash-area__note {
  color: var(--ink-muted);
  font-size: 0.8rem;
}

.staff-spark {
  display: block;
  width: 100%;
  height: 34px;
  margin-top: 8px;
}

.staff-spark rect {
  fill: var(--chart-color, var(--brand-dark, #6f9e43));
}

.staff-overview__bottom {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  align-items: start;
}

@media (max-width: 1000px) {
  .staff-overview__bottom {
    grid-template-columns: 1fr;
  }
}

.staff-overview__bottom .staff-dash__section {
  margin: 0;
  min-width: 0;
}

.staff-overview__day li .staff-tag {
  margin-left: 4px;
}

/* The Bible overview (sample A, owner 20 November 2026): a card per plan
   with where readers stop, and the same chart on a plan's page. */
.staff-bib__plan-title {
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.3;
  text-wrap: balance;
}

.staff-bib__chart-label {
  margin-top: 12px;
}

.staff-bib__reach {
  display: grid;
  gap: 4px;
}

/* Bible Today A and Plans A (owner, 20 November 2026): the week ahead with
   a blue info line, When it shows on a reading's page, and a plan row's
   small Where readers stop chart. */
.staff-bib__week {
  margin-bottom: 20px;
}

.staff-bib__days {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

@media (max-width: 900px) {
  .staff-bib__days {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.staff-bib__day {
  display: grid;
  gap: 2px;
  align-content: start;
  min-width: 0;
  padding: 12px 14px;
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}

.staff-bib__day:first-child {
  border-left: 0;
}

.staff-bib__day.is-today {
  background: var(--staff-success-bg);
}

.staff-bib__day-ref {
  color: var(--ink);
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.staff-bib__day-ref:hover {
  text-decoration: underline;
}

.staff-bib__day .staff-eng__sub {
  overflow-wrap: anywhere;
}

.staff-bib__day-count {
  font-size: 0.82rem;
}

.staff-bib__info {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 12px 20px;
  border-top: 1px solid var(--border);
  background: var(--staff-info-bg);
  color: var(--staff-info-ink);
  font-size: 0.9rem;
  font-weight: 600;
}

.staff-bib__info-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--staff-info-ink);
  color: #fff;
  font-family: Georgia, serif;
  font-style: italic;
  font-size: 0.78rem;
}

.staff-bib__info a {
  margin-left: auto;
  color: inherit;
}

.staff-bib__showings {
  padding-bottom: 12px;
}

.staff-bib__dates {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
}

.staff-bib__dates li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
  font-size: 0.92rem;
}

.staff-bib__dates li:first-child {
  border-top: 0;
}

.staff-bib__dates li.is-today {
  font-weight: 700;
}

.staff-bib__row-reach {
  max-width: 260px;
  margin-top: 8px;
}

.staff-bib__row-reach .staff-spark {
  height: 30px;
  margin-top: 0;
}

.staff-bib__row-tags {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

/* The Media and Feed posts overviews (sample A, owner 20 November 2026):
   recently added items as thumbnails, and a post's first week as a small
   chart in its row. */
.staff-med__thumbs {
  list-style: none;
  margin: 0;
  padding: 4px 20px 16px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 760px) {
  .staff-med__thumbs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.staff-med__thumbs li {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.staff-med__thumb-link {
  display: grid;
  gap: 4px;
  color: var(--ink);
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none;
}

.staff-med__thumb-link:hover .staff-med__thumb-title {
  text-decoration: underline;
}

.staff-med__thumb {
  width: 100%;
  max-width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 10px;
}

.staff-med__thumb--empty {
  display: grid;
  place-items: center;
  background: var(--canvas);
  color: var(--ink-muted);
  font-size: 0.75rem;
  font-weight: 700;
}

.staff-med__thumb-title {
  overflow-wrap: anywhere;
}

.staff-pst__week {
  width: 150px;
}

.staff-pst__week .staff-spark {
  width: 140px;
  height: 28px;
  margin-top: 0;
}

/* Subject colors (option B, owner 20 November 2026): each subject keeps
   one chart color on every page, set by a staff-tone class on the card, with
   a small swatch before the card title. Checked with the dataviz validator
   (adjacent pairs pass for color vision deficiency); every chart keeps its
   title, so color never labels alone. Amber and red stay for attention and
   errors and are never a chart color.
   green: people (new people, membership, app use). It is the church accent
   (--brand-dark, real-life#198), so it is another color under another
   theme; the four below stay as they are.
   teal: belonging (groups, service teams)
   coral: attendance (check-ins)
   blue: watching and reading (sermons, media, posts, emails and texts)
   violet: practice (habits, Bible, prayer) */
.staff-tone--green {
  --chart-color: var(--brand-dark, #6f9e43);
}

.staff-tone--teal {
  --chart-color: #1a9a8a;
}

.staff-tone--coral {
  --chart-color: #d0704a;
}

.staff-tone--blue {
  --chart-color: #2f74c0;
}

.staff-tone--violet {
  --chart-color: #7a5cc8;
}

.staff-tone > .staff-dash__kicker:first-child::before,
.staff-tone .staff-eng__list-head > .staff-pco__panel-title::before,
.staff-tone .staff-dash-area__top > .staff-dash__kicker::before,
.staff-tone .staff-hab__today-text > .staff-dash__kicker:first-child::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 8px;
  border-radius: 3px;
  background: var(--chart-color);
  vertical-align: 0;
}

/* A sent or canceled newsletter's Send step (owner, 20 November 2026): the
   email as it went out, at its full height. */
.staff-nl-sent {
  margin-top: 16px;
  padding: 0;
  overflow: hidden;
}

.staff-nl-sent .staff-pco__panel-head {
  padding: 16px 20px;
}

.staff-nl-sent__body {
  padding: 16px;
  background: #e6e6eb;
  overflow-x: auto;
}

.staff-nl-sent__body iframe {
  display: block;
  width: 600px;
  max-width: 100%;
  height: 640px;
  margin: 0 auto;
  border: 0;
  border-radius: 8px;
  background: #fff;
}

/* The Badges overview (sample B, owner 20 November 2026): Close to a badge,
   the earned-recently list, and the groups of the by-badge bars. A row's
   subject color sets its swatch and bar. */
.staff-bdg__close,
.staff-bdg__recent {
  list-style: none;
  margin: 0;
  padding: 0 0 8px;
}

.staff-bdg__close li {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 12px 20px;
  border-top: 1px solid var(--border);
}

.staff-bdg__close li:first-child,
.staff-bdg__recent li:first-child {
  border-top: 0;
}

.staff-bdg__close-text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.staff-bdg__close-text b::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 8px;
  border-radius: 3px;
  background: var(--chart-color);
}

.staff-bdg__count {
  font-size: 1.3rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.staff-bdg__emoji {
  font-size: 1.2rem;
  text-align: center;
}

.staff-bdg__recent li {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px 20px;
  border-top: 1px solid var(--border);
  font-size: 0.92rem;
}

.staff-bdg__group {
  margin: 0;
  padding: 10px 20px 0;
  color: var(--ink-muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

@media (max-width: 600px) {
  .staff-bdg__close li {
    grid-template-columns: 32px minmax(0, 1fr) auto;
  }

  .staff-bdg__close li a {
    grid-column: 2 / -1;
  }
}

/* A summary number that opens who and what it counts (the Badges overview,
   owner 20 November 2026). */
a.staff-eng__stat--link {
  color: inherit;
  text-decoration: none;
}

a.staff-eng__stat--link:hover {
  background: var(--canvas);
}

a.staff-eng__stat--link:hover .staff-dash__kicker {
  color: var(--ink);
  text-decoration: underline;
}

a.staff-eng__stat--link:focus-visible {
  outline: 3px solid var(--staff-focus);
  outline-offset: -3px;
}

/* The Badges lists (owner, 20 November 2026; UX pass): a badge as a chip in
   its subject color, a summary strip with a chart, chips that filter, and
   rows grouped by day or month. */
.staff-bdg-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px 3px 6px;
  border: 1px solid color-mix(in srgb, var(--chart-color, var(--brand-dark, #6f9e43)) 35%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--chart-color, var(--brand-dark, #6f9e43)) 12%, var(--surface));
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
}

.staff-bdg-chip__emoji {
  font-size: 1rem;
  line-height: 1;
}

.staff-bdg-chip b {
  color: var(--ink-muted);
  font-variant-numeric: tabular-nums;
}

a.staff-bdg-chip:hover {
  background: color-mix(in srgb, var(--chart-color, var(--brand-dark, #6f9e43)) 22%, var(--surface));
}

a.staff-bdg-chip.is-current {
  border-color: var(--chart-color, var(--church-header, #304b3b));
  box-shadow: inset 0 0 0 1px var(--chart-color, var(--church-header, #304b3b));
}

.staff-bdg-chip--all {
  --chart-color: #6b6b70;
  padding-left: 12px;
}

.staff-bdg-sum {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 12px 28px;
  align-items: center;
  margin: 0 0 16px;
  padding: 18px 20px;
}

@media (max-width: 760px) {
  .staff-bdg-sum {
    grid-template-columns: 1fr;
  }
}

.staff-bdg-sum__numbers {
  display: grid;
  gap: 4px;
  align-content: start;
}

.staff-bdg-sum__numbers .staff-dash__kicker {
  margin: 0;
}

.staff-bdg-sum__close {
  margin-top: 8px;
  font-size: 0.88rem;
}

.staff-bdg-sum__spread {
  padding: 0;
}

.staff-bdg-sum__spread .staff-ppl__bar {
  padding: 5px 0;
}

.staff-bdg-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 16px;
}

.staff-bdg-days {
  padding: 0;
  overflow: hidden;
}

.staff-bdg-days__day {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 10px 20px;
  border-top: 1px solid var(--border);
  background: var(--canvas);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.staff-bdg-days section:first-child .staff-bdg-days__day {
  border-top: 0;
}

.staff-bdg-days .staff-rows {
  margin: 0;
}

.staff-bdg-row {
  align-items: center;
}

.staff-bdg-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 0;
  position: relative;
  z-index: 1;
}

.staff-bdg-row__count {
  color: var(--ink-muted);
  font-size: 0.85rem;
  white-space: nowrap;
}

.staff-bdg-row__count b {
  color: var(--ink);
  font-size: 1.2rem;
  font-variant-numeric: tabular-nums;
}

/* Badge art (owner, 20 November 2026): the Sensa emoji SVGs in
   public/badges, set at the size each page asks for, aligned with the
   text beside them. */
.staff-badge-art {
  display: inline-block;
  flex: none;
  vertical-align: -0.2em;
  object-fit: contain;
}

img.staff-badge-emoji {
  width: 40px;
  height: 40px;
}

img.staff-badge-emoji--large {
  width: 72px;
  height: 72px;
}

.staff-ppl__bar-name .staff-badge-art,
.staff-bdg-chip .staff-badge-art {
  margin-right: 2px;
}

/* Staff access: the people who can sign in, above the addresses (owner,
   20 November 2026). */
.staff-access__people {
  margin-bottom: 28px;
}

/* Newsletter templates (sample A, owner 20 November 2026): the New
   newsletter gallery of starters and saved templates, each card with a
   sketch of its blocks; the Templates tab rows; Save as template in the
   editor's bar. */
.staff-nl-new__intro {
  margin: 0 0 8px;
  padding: 18px 20px;
}

.staff-nl-new__group {
  margin-top: 20px;
}

.staff-nl-new__empty {
  margin: 0;
  padding: 16px 20px;
  color: var(--ink-muted);
}

.staff-nl-gallery {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 16px;
}

.staff-nl-gallery form {
  margin: 0;
  height: 100%;
}

.staff-nl-card {
  display: grid;
  gap: 6px;
  align-content: start;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 12px;
  border: 0;
  font: inherit;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.staff-nl-card:hover {
  box-shadow: 0 0 0 2px var(--brand-dark), var(--shadow);
}

.staff-nl-card:focus-visible {
  outline: 3px solid var(--staff-focus);
  outline-offset: 2px;
}

.staff-nl-card__thumb {
  display: grid;
  padding: 10px;
  border-radius: 10px;
  background: #e6e6eb;
}

.staff-nl-card__name {
  font-weight: 700;
}

.staff-nl-sketch {
  display: grid;
  gap: 5px;
  align-content: start;
  min-height: 150px;
  padding: 8px;
  border-radius: 6px;
  background: #fff;
}

.staff-nl-sketch i {
  display: block;
  border-radius: 3px;
}

.staff-nl-sketch__header { height: 18px; background: var(--church-header, #304b3b); }
.staff-nl-sketch__heading { height: 8px; width: 70%; background: #1c1c1e; }
.staff-nl-sketch__line { height: 5px; background: #c9c9cf; }
.staff-nl-sketch__line--short { width: 60%; }
.staff-nl-sketch__image { height: 30px; background: #dfe8d6; }
.staff-nl-sketch__button { height: 12px; width: 40%; justify-self: center; border-radius: 999px !important; background: var(--church-button, #5e7f67); }
.staff-nl-sketch__divider { height: 1px; background: #e3e3e8; }
.staff-nl-sketch__social { height: 8px; width: 30%; justify-self: center; background: #c9c9cf; }
.staff-nl-sketch__footer { height: 6px; width: 50%; justify-self: center; margin-top: 4px; background: #e3e3e8; }

.staff-nl-tpl-row {
  grid-template-columns: 88px minmax(0, 1fr) auto;
}

.staff-nl-tpl-row__thumb .staff-nl-sketch {
  min-height: 96px;
  padding: 6px;
  gap: 3px;
  border: 1px solid var(--border);
}

.staff-nl-tpl-row__rename {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 0 0 4px;
}

.staff-nl-tpl-row__rename .staff-field__input {
  max-width: 320px;
}

.staff-nl-save-tpl {
  position: relative;
}

.staff-nl-save-tpl summary {
  list-style: none;
}

.staff-nl-save-tpl summary::-webkit-details-marker {
  display: none;
}

.staff-nl-save-tpl__form {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 20;
  display: grid;
  gap: 6px;
  width: min(320px, 80vw);
  margin: 0;
  padding: 14px;
}

/* Tools > Configuration (real-life#188). Its password and email fields look
   like the other fields of a sectioned form. */
.staff-sections input[type="password"],
.staff-sections input[type="email"] {
  width: 100%;
  min-height: 44px;
  font: inherit;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  padding: 10px 14px;
}

/* A secret: the field, and inside it on the right an eye button that shows
   the value as text and hides it again (secret_field_controller.js). */
.staff-secret {
  position: relative;
}

.staff-secret input {
  padding-right: 52px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.staff-secret__button {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink-muted);
  cursor: pointer;
}

.staff-secret__button:hover,
.staff-secret__button[aria-pressed="true"] {
  background: var(--staff-success-bg);
  color: var(--brand-ink);
}

.staff-secret__button:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 0;
}

.staff-secret__eye-off,
.staff-secret__button[aria-pressed="true"] .staff-secret__eye {
  display: none;
}

.staff-secret__button[aria-pressed="true"] .staff-secret__eye-off {
  display: block;
}

.staff-config .staff-config__time {
  max-width: 14rem;
}

/* The Theme dropdown: wide enough for its longest option, no wider. */
.staff-config .staff-config__theme-select {
  max-width: 18rem;
}

.staff-config .staff-config__lines {
  min-height: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.92rem;
}

.staff-config__color {
  width: 72px;
  height: 44px;
  padding: 4px;
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  background: var(--surface);
  cursor: pointer;
}

.staff-config__check {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  font-weight: 600;
}

.staff-config__check input {
  width: 20px;
  height: 20px;
  accent-color: var(--brand-dark);
}

.staff-config__history {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* The logo and the mark beside their file fields (real-life#196): the logo
   on the header color it will sit on, the mark on the page color. */
.staff-config__upload {
  margin: 0;
}

.staff-config__thumb {
  display: inline-flex;
  align-items: center;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: 10px;
}

.staff-config__thumb--logo {
  background: var(--thumb-header, var(--church-header, #304b3b));
}

.staff-config__thumb--logo img {
  display: block;
  height: 44px;
  width: auto;
  max-width: 100%;
}

.staff-config__thumb--mark {
  background: var(--canvas);
}

/* The versions for dark backgrounds sit on one (real-life#219). */
.staff-config__thumb--dark {
  background: #1c1c1e;
  border-color: #1c1c1e;
}

.staff-config__thumb--mark img {
  display: block;
  width: 56px;
  height: 56px;
  object-fit: contain;
}

/* Colors and logo, laid out (owner, 21 November 2026): the logo and the
   mark side by side; a line; then the theme and colors beside the preview.
   Room between fields: 28px between blocks, 10px inside an image field. */
.staff-config__brand {
  display: grid;
  gap: 28px;
  min-width: 0;
}

.staff-config__images {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px 40px;
  align-items: start;
}

.staff-config__image-col,
.staff-config__theme-fields {
  display: grid;
  gap: 24px;
  min-width: 0;
}

.staff-sections__section .staff-config__image {
  gap: 10px;
}

/* The file field, with Remove at its right. */
.staff-config__file {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
}

.staff-config__file input[type="file"] {
  flex: 1 1 14rem;
  min-width: 0;
}

.staff-config .staff-config__file .staff-button {
  width: auto;
}

.staff-config__brand .staff-config__theme {
  padding-top: 28px;
  border-top: 1px solid var(--border);
}

/* The three colors of a mode in one row. */
.staff-config__swatches {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px 24px;
  align-items: start;
}

.staff-config__mode .staff-config__mode-hint {
  margin: -6px 0 14px;
}

@media (max-width: 560px) {
  .staff-config__swatches {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Colors and logo on Tools > Configuration (real-life#192): the fields on
   the left, and on the right a preview that stays in view, with a Light /
   Dark switch above it. One column on a narrow screen. */
.staff-config__theme {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 340px);
  gap: 24px 32px;
  align-items: start;
}

.staff-config__mode {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}

.staff-config__mode-title {
  margin: 0 0 12px;
  padding: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink);
}

.staff-config__preview-col {
  position: sticky;
  top: 16px;
}

/* "Preview", then one row under it: Web / App on the left and Light / Dark
   on the right, both the segmented control of the newsletter editor
   (.staff-nl__seg). */
.staff-config__preview-head {
  margin-bottom: 10px;
}

.staff-config__switches {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.staff-theme-preview {
  --preview-canvas: #f2f2f7;
  --preview-card: #ffffff;
  --preview-ink: #1c1c1e;
  --preview-muted: #6b6b70;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--preview-canvas);
}

.staff-theme-preview.is-dark {
  --preview-canvas: #000000;
  --preview-card: #1c1c1e;
  --preview-ink: #ffffff;
  --preview-muted: #a1a1a6;
}

/* The two mockups: Web (a small /staff page) shows unless App is chosen. */
.staff-theme-preview__app,
.staff-theme-preview.is-app .staff-theme-preview__web {
  display: none;
}

.staff-theme-preview.is-app .staff-theme-preview__app {
  display: block;
}

.staff-theme-preview__header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--preview-header);
}

.staff-theme-preview__header {
  color: var(--preview-on-header, #ffffff);
}

.staff-theme-preview__logo {
  display: inline-block;
  height: 28px;
}

.staff-theme-preview__logo img {
  display: block;
  height: 100%;
  width: auto;
}

.staff-theme-preview__name {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 28px;
}

.staff-theme-preview [hidden] {
  display: none;
}

.staff-theme-preview__label {
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--preview-brand);
  color: #1c2b12;
  font-size: 0.7rem;
  font-weight: 700;
}

.staff-theme-preview__nav,
.staff-theme-preview__tabs {
  display: flex;
  gap: 14px;
  padding: 0 16px;
  background: var(--preview-card);
  border-bottom: 1px solid color-mix(in srgb, var(--preview-ink) 12%, transparent);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--preview-muted);
}

.staff-theme-preview__nav span,
.staff-theme-preview__tabs span {
  padding: 9px 0 7px;
  border-bottom: 2px solid transparent;
}

.staff-theme-preview__nav .is-current {
  color: var(--preview-ink);
  border-bottom-color: var(--preview-brand);
}

.staff-theme-preview__body {
  padding: 14px;
}

.staff-theme-preview__card {
  display: grid;
  justify-items: start;
  gap: 10px;
  padding: 14px;
  border-radius: 12px;
  background: var(--preview-card);
  color: var(--preview-ink);
}

.staff-theme-preview__row,
.staff-theme-preview__line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
}

.staff-theme-preview__line {
  padding-top: 8px;
  border-top: 1px solid color-mix(in srgb, var(--preview-ink) 10%, transparent);
}

.staff-theme-preview__chip {
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--preview-brand);
  color: #1c2b12;
  font-size: 0.72rem;
  font-weight: 700;
}

.staff-theme-preview__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
}

.staff-theme-preview__text {
  margin: 0;
  font-size: 0.85rem;
  color: var(--preview-muted);
}

.staff-theme-preview__bar {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--preview-ink) 12%, transparent);
}

.staff-theme-preview__bar span {
  display: block;
  width: 62%;
  height: 100%;
  border-radius: 999px;
  background: var(--preview-brand);
}

.staff-theme-preview__button {
  padding: 7px 12px;
  border-radius: 9px;
  background: var(--preview-button);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 600;
  text-align: center;
}

.staff-theme-preview__button--wide {
  justify-self: stretch;
  padding: 10px 14px;
  font-size: 0.9rem;
}

.staff-theme-preview__link {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--preview-button);
}

/* The phone: narrower, rounded, with the app's top bar and tab bar. */
.staff-theme-preview__phone {
  width: min(250px, 100%);
  margin: 16px auto;
  padding: 12px 12px 0;
  overflow: hidden;
  border: 6px solid color-mix(in srgb, var(--preview-ink) 80%, #808080);
  border-radius: 28px;
  background: var(--preview-canvas);
}

.staff-theme-preview__appbar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 2px 12px;
  color: var(--preview-ink);
}

.staff-theme-preview__mark {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--preview-header);
}

.staff-theme-preview.is-dark .staff-theme-preview__mark {
  background: #ffffff;
}

/* An uploaded mark is the square's mask, as the app draws it. */
.staff-theme-preview__mark.has-mark {
  border-radius: 0;
  -webkit-mask: var(--mark) center / contain no-repeat;
  mask: var(--mark) center / contain no-repeat;
}

.staff-theme-preview__wordmark {
  font-size: 1rem;
  font-weight: 700;
}

.staff-theme-preview__tabs {
  justify-content: space-between;
  gap: 6px;
  margin: 12px -12px 0;
  padding: 0 12px;
  border-top: 1px solid color-mix(in srgb, var(--preview-ink) 12%, transparent);
  border-bottom: 0;
  background: var(--preview-canvas);
  font-size: 0.65rem;
}

.staff-theme-preview__tabs .is-current {
  color: var(--preview-ink);
}

@media (max-width: 900px) {
  .staff-config__theme,
  .staff-config__images {
    grid-template-columns: minmax(0, 1fr);
  }

  .staff-config__preview-col {
    position: static;
  }
}

/* Tools > Check-in matching (real-life#197). The amber line in a card of
   its own above the rows; in the pop-up, sections with room between them,
   suggestions with Add at the right, and the search results as a list of
   names to pick. Colors come from the church's configured colors. */
.staff-match__attn.staff-pco__panel {
  padding: 0;
  overflow: hidden;
  margin: 0 0 16px;
}

.staff-match__attn .staff-eng__attn {
  border-top: 0;
}

.staff-match__dialog.staff-dialog {
  padding: 0;
}

.staff-match__dialog .staff-dialog__header {
  margin: 0;
  padding: 20px 20px 0;
}

.staff-match__section {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.staff-match__section + .staff-match__section {
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.staff-match__section .staff-dialog__subtitle {
  margin: 0;
}

.staff-match__suggest {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
}

.staff-match__suggest:first-of-type {
  border-top: 0;
}

.staff-match__suggest[hidden] {
  display: none;
}

.staff-match__suggest > div {
  flex: 1;
  min-width: 0;
}

.staff-match__suggest .staff-button {
  width: auto;
  flex: none;
}

.staff-match__picked {
  display: grid;
  gap: 2px;
}

.staff-match__dialog input[type="checkbox"] {
  width: 18px;
  height: 18px;
  flex: none;
  accent-color: var(--church-header, #304b3b);
}

.staff-match__results {
  display: grid;
  gap: 2px;
}

.staff-match__result {
  display: block;
  width: 100%;
  min-height: 44px;
  padding: 8px 10px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--church-button, #5e7f67);
  font: inherit;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.staff-match__result:hover,
.staff-match__result:focus-visible {
  background: var(--canvas);
}

/* People & Teams > Rooms (real-life#199): the room pop-up. The form wraps
   the head, the fields and the footer, so it is the column that lets the
   fields scroll. Short fields sit two to a row; Remove sits at the left of
   the footer. */
.staff-room-dialog__form {
  display: flex;
  flex-direction: column;
  min-height: 0;
  margin: 0;
}

.staff-room-dialog .staff-dialog__header {
  align-items: flex-start;
  margin: 0;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
}

.staff-room-dialog__pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.staff-room-dialog__rule {
  display: grid;
  gap: 10px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.staff-room-dialog .staff-form__check {
  margin-top: 0;
}

.staff-room-dialog .staff-form__check input {
  width: 18px;
  height: 18px;
  flex: none;
  accent-color: var(--church-header, #304b3b);
}

.staff-room-dialog__remove {
  margin-right: auto;
}

@media (max-width: 480px) {
  .staff-room-dialog__pair {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The check-in station of an event (real-life#204; sample D, owner 21
   November 2026): the top (back to the event, title, counts, Show the
   code), then find and check in on the left beside who is here as room
   cards. One column on a phone, the search first. */
.staff-station__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  margin-bottom: 16px;
}

.staff-station__title {
  flex: 1 1 260px;
  min-width: 0;
}

.staff-station__back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 32px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--church-header, #304b3b);
  text-decoration: none;
}

.staff-station__back:hover {
  text-decoration: underline;
}

.staff-station__heading {
  margin: 0;
  font-size: 1.5rem;
  line-height: 1.15;
}

.staff-station__title .staff-row__meta {
  margin: 2px 0 0;
}

.staff-station__counts {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 20px;
}

.staff-station__count {
  display: grid;
  margin: 0;
  line-height: 1.15;
}

.staff-station__count strong {
  font-size: 1.5rem;
}

.staff-station__count span,
.staff-station__updated {
  color: var(--ink-muted);
  font-size: 0.8rem;
}

.staff-station__updated {
  margin: 0;
  align-self: end;
}

.staff-station {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.staff-station__side {
  display: grid;
  gap: 16px;
}

.staff-station__card-title {
  margin: 0;
  padding: 0;
  font-size: 1.05rem;
  font-weight: 700;
}

.staff-station__find .staff-field__label {
  display: block;
  margin-bottom: 6px;
}

.staff-station__search {
  min-height: 56px;
  font-size: 1.2rem;
  border-width: 2px;
  border-color: var(--church-header, #304b3b);
}

.staff-station__find .staff-field__hint {
  margin: 6px 0 0;
}

.staff-station__results {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.staff-station__results:empty {
  display: none;
}

.staff-station__chip {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  min-height: 44px;
  padding: 10px 14px;
  border: 0;
  border-radius: 999px;
  background: var(--canvas);
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.staff-station__chip:hover,
.staff-station__chip:focus-visible {
  background: color-mix(in srgb, var(--brand) 28%, var(--surface));
}

.staff-station__chip--pickup {
  background: var(--church-header, #304b3b);
  color: var(--church-on-header, #fff);
}

.staff-station__chip--pickup:hover,
.staff-station__chip--pickup:focus-visible {
  background: color-mix(in srgb, var(--church-header, #304b3b) 85%, #000);
}

.staff-station__chip-name {
  font-weight: 700;
}

.staff-station__chip-meta {
  opacity: 0.8;
}

.staff-station__row input[type="checkbox"] {
  width: 22px;
  height: 22px;
  margin: 2px 0 0;
  flex: none;
  accent-color: var(--church-header, #304b3b);
}

.staff-station__care {
  display: grid;
  gap: 2px;
  margin: 6px 0 0;
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--staff-warning-bg);
  color: var(--staff-warning-ink);
  font-size: 0.88rem;
}

.staff-station__care div {
  display: flex;
  flex-wrap: wrap;
  gap: 0 6px;
}

.staff-station__care dt {
  font-weight: 600;
}

.staff-station__care dd {
  margin: 0;
}

.staff-station__actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.staff-station__here > .staff-pco__panel-title {
  margin: 0 0 12px;
}

/* One room per row at every width (owner, 22 November 2026). */
.staff-station__rooms {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.staff-station__room {
  margin: 0;
}

.staff-station__room-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
}

.staff-station__group-title {
  margin: 0;
  font-size: 1rem;
}

.staff-station__room-count {
  margin-left: auto;
  color: var(--ink-muted);
  font-size: 0.88rem;
}

.staff-station__room-count strong {
  color: var(--ink);
}

.staff-station__meter {
  height: 8px;
  margin-top: 8px;
  border-radius: 999px;
  background: var(--canvas);
  overflow: hidden;
}

.staff-station__meter i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: #d0704a;
}

.staff-station__preview {
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.9rem;
}

.staff-station__preview li {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 0;
  border-top: 1px solid var(--border);
}

.staff-station__preview li > span:first-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-station__preview strong {
  font-size: 0.85rem;
  letter-spacing: 0.04em;
}

.staff-station__open {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--church-header, #304b3b);
}

.staff-station__all {
  margin: 0 0 12px;
  font-weight: 600;
}

.staff-station__room .staff-rows {
  margin-top: 8px;
}

/* The button that picks the room the station shows first, under the room's
   head and over its rows. */
.staff-station__default {
  display: flex;
  margin-top: 12px;
}

.staff-station__default .staff-button {
  min-height: 44px;
}

.staff-station__row {
  align-items: flex-start;
  gap: 12px;
}

@media (min-width: 1100px) {
  .staff-station {
    grid-template-columns: minmax(300px, 420px) minmax(0, 1fr);
  }
}

/* The check-in code screen (real-life#204): no staff chrome, the QR as
   large as the screen allows, for a screen at the door. */
.staff-screen__main {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}

.staff-screen__back {
  position: fixed;
  top: calc(12px + env(safe-area-inset-top, 0px));
  left: calc(12px + env(safe-area-inset-left, 0px));
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--surface, #fff);
  box-shadow: var(--shadow);
  color: var(--ink-muted);
  font-weight: 600;
  text-decoration: none;
}

.staff-screen__back:hover,
.staff-screen__back:focus-visible {
  color: var(--ink, #1c1c1e);
}

.staff-screen__code {
  display: grid;
  justify-items: center;
  gap: 12px;
  text-align: center;
}

.staff-screen__title {
  margin: 0;
  font-size: clamp(1.75rem, 5vw, 3rem);
  line-height: 1.1;
  color: var(--church-header, #304b3b);
}

.staff-screen__hint {
  margin: 0;
  color: var(--ink-muted);
  font-size: clamp(1rem, 2.5vw, 1.5rem);
}

.staff-screen__qr {
  width: min(80vw, 70vh);
  padding: 16px;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

.staff-screen__qr svg {
  display: block;
  width: 100%;
  height: auto;
}

/* The Check-ins list (sample A, owner 21 November 2026; folded, option 3):
   a row per event and day that opens in place, the page's first one open.
   The row: event, day, check-ins, first time, change on last time and the
   top places. Open: the check-ins by location as coral bars in two columns,
   then the names in columns by location. */
.staff-ci-card {
  padding: 0;
}

.staff-ci-card + .staff-ci-card {
  margin-top: 8px;
}

.staff-ci-card__summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 12px 20px;
  border-radius: var(--radius);
  cursor: pointer;
  list-style: none;
}

.staff-ci-card__summary::-webkit-details-marker {
  display: none;
}

.staff-ci-card__summary:hover {
  background: color-mix(in srgb, var(--canvas) 60%, var(--surface));
}

.staff-ci-card__summary:focus-visible {
  outline: 2px solid var(--church-header, #304b3b);
  outline-offset: 2px;
}

.staff-ci-card__head {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 14px;
}

.staff-ci-card__title {
  font-size: 1.05rem;
  font-weight: 700;
}

.staff-ci-card__day,
.staff-ci-card__change,
.staff-ci-card__time,
.staff-ci-card__more,
.staff-ci-card__places {
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.staff-ci-card__stats {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 16px;
  margin-left: auto;
  font-size: 0.88rem;
}

.staff-ci-card__stats strong {
  font-size: 1.05rem;
  font-variant-numeric: tabular-nums;
}

.staff-ci-card__places {
  flex-basis: 100%;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-ci-card__fold[open] .staff-ci-card__places {
  display: none;
}

.staff-ci-card__chevron {
  flex: none;
  color: var(--ink-muted);
  transition: transform 0.15s ease;
}

.staff-ci-card__fold[open] .staff-ci-card__chevron {
  transform: rotate(180deg);
}

.staff-ci-card__body {
  padding: 4px 20px 20px;
}

.staff-ci-card__bars {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 8px 40px;
}

.staff-ci-card__bar {
  display: grid;
  grid-template-columns: minmax(0, 150px) minmax(0, 1fr) 36px;
  gap: 10px;
  align-items: center;
  font-size: 0.85rem;
}

.staff-ci-card__bar-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-ci-card__track {
  height: 8px;
  border-radius: 999px;
  background: var(--canvas);
  overflow: hidden;
}

.staff-ci-card__fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: #d0704a;
}

.staff-ci-card__bar b {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.staff-ci-card__names {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px 24px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.staff-ci-card__place-title {
  margin: 0 0 6px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.staff-ci-card__place ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2px;
  font-size: 0.9rem;
}

.staff-ci-card__place li {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-height: 28px;
}

.staff-ci-card__person {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
  font-weight: 500;
  text-decoration: none;
}

.staff-ci-card__person:hover {
  text-decoration: underline;
}

.staff-ci-card__all {
  margin-top: 16px;
}

.staff-ci-rooms {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 600;
  color: var(--church-header, #304b3b);
}

@media (max-width: 600px) {
  .staff-ci-card__stats {
    margin-left: 0;
  }

  .staff-ci-card__bars {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The check-in code screen with the event's image (real-life#210; samples
   Code A and Code B, owner 22 November 2026). A tall screen stacks image,
   title and code; a wide one puts the image and title beside the code. Both
   keep the code large and the whole screen free of scrolling. */
.staff-screen__about,
.staff-screen__words {
  display: grid;
  justify-items: center;
  gap: 12px;
}

.staff-screen__image {
  display: block;
  width: min(72vw, 44vh);
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.staff-screen__code--image {
  gap: 20px;
}

.staff-screen__code--image .staff-screen__about {
  gap: 20px;
}

.staff-screen__code--image .staff-screen__qr {
  width: min(80vw, 42vh);
}

@media (orientation: landscape) and (min-width: 700px) {
  .staff-screen__code--image {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    justify-items: stretch;
    gap: 48px;
    width: 100%;
    max-width: 1400px;
    padding-inline: 32px;
    box-sizing: border-box;
    text-align: left;
  }

  .staff-screen__code--image .staff-screen__about,
  .staff-screen__code--image .staff-screen__words {
    justify-items: start;
  }

  .staff-screen__code--image .staff-screen__image {
    width: 100%;
    max-height: 56vh;
  }

  .staff-screen__code--image .staff-screen__qr {
    width: min(46vw, 78vh);
  }
}

/* The image picker (real-life#210; sample A, owner 22 November 2026): a
   large pop-up, Upload and Library as the segmented control in its head, the
   tiles or the drop area on the canvas color, and the chosen image's details
   in a white panel on the right. One column under 800px, the details under
   the tiles. */
.staff-picker.staff-dialog {
  width: min(1080px, calc(100vw - 32px));
  max-width: none;
  height: min(740px, calc(100dvh - 48px));
  max-height: none;
}

.staff-picker__layout {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  margin: 0;
}

.staff-dialog > .staff-picker__layout > .staff-dialog__header {
  align-items: center;
  flex-wrap: wrap;
  margin: 0;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.staff-picker .staff-dialog__close {
  width: 44px;
  height: 44px;
}

.staff-picker__heading {
  flex: 1;
  min-width: 12rem;
}

.staff-picker__tabs button {
  min-height: 44px;
  padding: 0 18px;
  font-size: 0.95rem;
}

.staff-picker__tabs button:focus-visible {
  outline: 3px solid var(--staff-focus);
  outline-offset: -3px;
}

.staff-picker__body {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  background: var(--canvas);
}

.staff-picker__main {
  min-width: 0;
  overflow-y: auto;
  padding: 16px 20px;
  display: grid;
  align-content: start;
  gap: 16px;
}

.staff-picker__pane {
  display: grid;
  gap: 14px;
}

.staff-picker__filters {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 220px);
  gap: 12px;
  align-items: start;
}

.staff-picker .staff-field {
  display: grid;
  gap: 6px;
}

.staff-picker__count {
  margin: 0 0 12px;
  font-size: 0.85rem;
  color: var(--ink-muted);
}

.staff-picker__grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.staff-picker__tile {
  position: relative;
  display: grid;
  gap: 2px;
  width: 100%;
  padding: 4px 4px 8px;
  border: 2px solid transparent;
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.staff-picker__tile:hover {
  border-color: var(--ink-muted);
}

.staff-picker__tile:focus-visible {
  outline: 3px solid var(--staff-focus);
  outline-offset: 2px;
}

.staff-picker__tile[aria-pressed="true"] {
  border-color: var(--church-header, #304b3b);
  background: color-mix(in srgb, var(--brand) 22%, var(--surface));
}

.staff-picker__thumb {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 8px;
  background: var(--canvas);
}

.staff-picker__tile-name,
.staff-picker__tile-meta {
  padding: 0 4px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.staff-picker__tile-name {
  margin-top: 4px;
  font-size: 0.85rem;
  font-weight: 600;
}

.staff-picker__tile-meta {
  font-size: 0.78rem;
  color: var(--ink-muted);
}

.staff-picker__check {
  position: absolute;
  top: 10px;
  right: 10px;
  display: none;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: var(--church-header, #304b3b);
  color: var(--church-on-header, #fff);
}

.staff-picker__tile[aria-pressed="true"] .staff-picker__check {
  display: flex;
}

.staff-picker__pager {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
}

.staff-picker__pager .staff-rail-pager__count {
  margin-right: auto;
}

.staff-picker__empty {
  border-radius: var(--radius);
  background: var(--surface);
}

.staff-picker__drop {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 48px 20px;
  border: 2px dashed var(--ink-muted);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--church-header, #304b3b);
  text-align: center;
}

.staff-picker__drop--over {
  border-color: var(--church-header, #304b3b);
  background: color-mix(in srgb, var(--brand) 22%, var(--surface));
}

.staff-picker__drop-title {
  font-weight: 700;
  color: var(--ink);
}

.staff-picker.staff-dialog .staff-picker__file {
  width: auto;
  max-width: 100%;
  min-height: 44px;
  padding: 8px 10px;
  border: 1px solid var(--ink-muted);
}

.staff-picker__details {
  min-width: 0;
  overflow-y: auto;
  padding: 16px 20px;
  background: var(--surface);
}

.staff-picker__detail {
  display: grid;
  gap: 12px;
}

.staff-picker__preview {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  border-radius: 10px;
  background: var(--canvas);
}

.staff-picker__name {
  margin: 0;
  font-size: 0.95rem;
  overflow-wrap: anywhere;
}

.staff-picker__facts {
  margin: 0;
  display: grid;
  gap: 6px;
  font-size: 0.85rem;
}

.staff-picker__facts > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.staff-picker__facts dt {
  color: var(--ink-muted);
}

.staff-picker__facts dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}

.staff-picker__uses {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
  display: grid;
  gap: 4px;
  font-size: 0.85rem;
  overflow-wrap: anywhere;
}

.staff-picker__note,
.staff-picker__nothing {
  margin: 0;
  font-size: 0.85rem;
  color: var(--ink-muted);
}

@media (max-width: 800px) {
  /* One scroll for the whole pop-up, the actions always in reach. */
  .staff-picker__layout {
    overflow-y: auto;
  }

  .staff-picker__body {
    flex: none;
    grid-template-columns: minmax(0, 1fr);
  }

  .staff-picker .staff-dialog__footer {
    position: sticky;
    bottom: 0;
  }

  .staff-picker__main,
  .staff-picker__details {
    overflow-y: visible;
  }

  .staff-picker__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .staff-picker__filters {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Six digits under the QR code, to type into the app on a phone that cannot
   scan. */
.staff-screen__typed-code {
  margin: 16px 0 0;
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--ink-muted);
  text-align: center;
}

.staff-screen__typed-code strong {
  color: var(--ink);
  font-size: clamp(1.5rem, 3.5vw, 2.25rem);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

/* The station (real-life#211): pickups adults made in the app, above the
   rooms, until staff close each with Got it; and a row's actions, Check out
   then Undo, 44px tall, wrapping under the name on a phone. */
.staff-station__pickups {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}

.staff-station__pickups-title {
  margin: 0;
  font-size: 1rem;
}

.staff-station__row-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.staff-station__row-actions form {
  margin: 0;
}

/* Who is here, fixed after the owner's iPad screenshot (22 November 2026):
   the name was squeezed into the 40px avatar column of a list row, the
   count dropped under a long room name, and rows were padded twice.

   - A station row has no avatar: the name takes the width, the actions sit
     at its right. Inside a room's card the row uses the card's own padding.
   - The room's name wraps beside its count, which stays at the top right.
   - Who is here is a container: when it is narrow (an iPad in portrait
     beside the search, or a phone) a row's actions go under the name, at
     the left, so the name is never squeezed. */
.staff-station__here {
  container-type: inline-size;
  min-width: 0;
}

.staff-station__row {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px 16px;
}

.staff-station__room .staff-station__row,
.staff-station__pickups .staff-station__row {
  padding: 12px 0;
}

.staff-station__room .staff-rows,
.staff-station__pickups .staff-rows {
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--border);
}

.staff-station__room .staff-station__row:last-child,
.staff-station__pickups .staff-station__row:last-child {
  padding-bottom: 0;
}

.staff-station__room .staff-station__row:hover,
.staff-station__pickups .staff-station__row:hover {
  background: transparent;
}

.staff-station__room-head {
  flex-wrap: nowrap;
  align-items: baseline;
}

.staff-station__group-title {
  flex: 1 1 auto;
  min-width: 0;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.staff-station__room-head .staff-tag,
.staff-station__room-count {
  flex: none;
  margin-left: 0;
  white-space: nowrap;
}

@container (max-width: 480px) {
  .staff-station__row {
    grid-template-columns: minmax(0, 1fr);
  }

  .staff-station__row-actions {
    justify-content: flex-start;
  }
}

/* The search beside who is here, only from 1100px (an iPad in landscape):
   an iPad in portrait, up to 1032px wide, stacks them, with the search a
   full-width card on top (owner, 22 November 2026). The search takes at
   most 40% (420px at most). */
@media (min-width: 1100px) {
  .staff-station {
    grid-template-columns: minmax(280px, min(420px, 40%)) minmax(0, 1fr);
  }
}

/* The 6-digit lock of the check-in code screen (real-life#211): the two
   pop-ups. The digits are large and evenly spaced, for a tablet on a stand;
   "Forgot them? Sign out" sits apart, at the left of the footer. */
.staff-kiosk .staff-dialog__header {
  align-items: flex-start;
  margin: 0;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
}

.staff-kiosk .staff-field {
  display: grid;
  gap: 6px;
}

.staff-kiosk .staff-kiosk__code input {
  min-height: 56px;
  font-size: 1.6rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.3em;
}

.staff-kiosk__forgot {
  margin-right: auto;
}

.staff-kiosk .staff-kiosk__code input {
  padding-right: 60px;
}

.staff-kiosk__code .staff-secret__button {
  top: 6px;
  right: 6px;
  width: 44px;
  height: 44px;
}

/* Staff sign-in, the code step (real-life#211): the digits large and evenly
   spaced, then Send a new code and Use a different email under the form. */
.staff-card .staff-card__code {
  min-height: 56px;
  font-size: 1.6rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.3em;
  text-align: center;
}

.staff-card__more {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 20px;
}

.staff-card__more form {
  margin: 0;
}

.staff-card__more a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* The station's two columns start on one line (owner, 22 November 2026):
   each has a heading of the same height, then its first card. "All rooms"
   sits at the right of the Who is here heading, not on a line of its own
   that pushed the room's card down. */
.staff-station__side > .staff-pco__panel-title,
.staff-station__here > .staff-pco__panel-title {
  margin: 0 0 12px;
  line-height: 1.5;
}

.staff-station__side > .staff-pco__panel-title {
  margin-bottom: -4px;
}

.staff-station__here {
  position: relative;
}

.staff-station__all {
  position: absolute;
  top: -10px;
  right: 0;
  margin: 0;
}

.staff-station__all a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

/* The row the station's search linked to (#check_in_<uuid>; owner, 22
   November 2026): tinted and rounded, never a line on one side. :target
   covers a plain page load; found_row_controller.js gives the row the class
   after a Turbo visit and each time the frame reloads. The padding and the
   opposite margin put the tint around the text without moving it. */
.staff-station__row:target,
.staff-station__row.staff-station__row--found,
.staff-station__room .staff-station__row:target:hover,
.staff-station__room .staff-station__row.staff-station__row--found:hover {
  background: color-mix(in srgb, var(--brand) 22%, var(--surface));
}

.staff-station__room .staff-station__row:target,
.staff-station__room .staff-station__row.staff-station__row--found {
  margin: 0 -10px;
  padding: 12px 10px;
  border-radius: 10px;
  scroll-margin-top: 16px;
}

/* A small Edit button at the right of a record page's trail (owner, 22
   November 2026): the trail and the button share one row. */
.staff-crumbs-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: -4px 0 16px;
}

.staff-crumbs-row .staff-crumbs ol {
  margin: 0;
}

.staff-crumbs-row__edit {
  flex: none;
}

/* Delete, left of Edit (real-life#216). */
.staff-crumbs-row__actions {
  display: flex;
  flex: none;
  align-items: center;
  gap: 8px;
}

.staff-crumbs-row__form {
  margin: 0;
}

/* An image field filled by the image picker (an event's edit form, owner
   22 November 2026): the picture now, at a size that shows it whole
   without filling the card, then the button that opens the picker with
   Remove beside it. */
.staff-image-field__now {
  display: grid;
  gap: 6px;
  max-width: 420px;
}

.staff-image-field__now .staff-profile__image {
  display: block;
}

.staff-image-field__none {
  margin: 0;
  color: var(--ink-muted);
}

.staff-image-field__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
}

.staff-short__form .staff-image-field {
  gap: 10px;
}

/* A date and a time side by side under one legend (an event's Starts and
   Ends, real-life#214); the time goes under the date on a narrow card. */
.staff-when {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
}

.staff-short__form .staff-when .staff-form__field {
  flex: 0 1 200px;
}

/* The History card of a record page (staff/_ownership, real-life#214): who
   owns the record, then its change log as plain rows that use the card's
   padding, not their own. */
.staff-history__owner {
  margin: 0;
  color: var(--ink-muted);
}

.staff-history__log {
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.staff-history__log .staff-row {
  padding-inline: 0;
}

.staff-history__log .staff-row:hover {
  background: none;
}

.staff-history__earlier {
  margin-top: 8px;
}

.staff-profile__main > .staff-household__section + .staff-history {
  margin-top: 20px;
}

/* Date and time fields on iPad and iPhone (owner's iPad screenshot, 22
   November 2026). Safari there draws them as its own control: as wide as it
   likes whatever width is set, with the value centered, so a date ran under
   the time beside it. Without the system look they are sized and aligned
   like every other field; a tap still opens the system picker. */
.staff input[type="date"],
.staff input[type="time"],
.staff input[type="datetime-local"] {
  -webkit-appearance: none;
  appearance: none;
  display: block;
  box-sizing: border-box;
  min-width: 0;
  max-width: 100%;
  text-align: left;
}

.staff input[type="date"]::-webkit-date-and-time-value,
.staff input[type="time"]::-webkit-date-and-time-value,
.staff input[type="datetime-local"]::-webkit-date-and-time-value {
  min-height: 1.5em;
  text-align: left;
}

.staff-when > .staff-form__field,
.staff-when .staff-date {
  min-width: 0;
}

/* The station's top (owner, 22 November 2026; flawless-ui-ux layout pass):
   the page-head pattern, a title block at the left and its one action at
   the right, centered on the block. The counts are the block's last line,
   one sentence in the muted meta style with the numbers in ink, so they
   read as a summary of the event and not as a third block. On a phone the
   button goes under the block, full width. */
.staff-station__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  margin-bottom: 24px;
}

.staff-station__title {
  flex: 1 1 280px;
  min-width: 0;
}

.staff-station__summary {
  display: flex;
  flex-wrap: wrap;
  gap: 0 6px;
  margin: 6px 0 0;
  font-size: 0.92rem;
  color: var(--ink-muted);
}

.staff-station__summary strong {
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.staff-station__summary > span + span::before {
  content: "·";
  margin-right: 6px;
}

.staff-station__summary .staff-station__updated {
  align-self: auto;
  font-size: inherit;
}

.staff-station__kiosk {
  flex: none;
}

@media (max-width: 560px) {
  .staff-station__kiosk {
    width: 100%;
    justify-content: center;
  }
}

/* Nobody checked in: no search, and who is here takes the page. */
@media (min-width: 1100px) {
  .staff-station.staff-station--empty {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Tools > Group meetings (real-life#209): the Meeting link choice in a
   group's row, its label above the dropdown. */
.staff-meetings__link {
  display: grid;
  gap: 2px;
  min-width: 13.5rem;
}

.staff-meetings__link-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--staff-muted, #6b6b70);
}

/* Choose a church (real-life#219): a staff member of several churches picks
   one after the sign-in code. Each church is a full-width button in the
   sign-in card. */
.staff-church-pick {
  display: grid;
  gap: 10px;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.staff-church-pick__form {
  margin: 0;
}

.staff-church-pick__church {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 56px;
  padding: 10px 16px;
  border: 1px solid #c7c7cc;
  border-radius: 10px;
  background: #ffffff;
  color: #1c1c1e;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.staff-church-pick__church:hover {
  background: #f2f2f7;
}

.staff-church-pick__church:focus-visible {
  outline: 2px solid #1c1c1e;
  outline-offset: 2px;
}

.staff-church-pick__text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.staff-church-pick__name {
  font-weight: 600;
  overflow-wrap: anywhere;
}

.staff-church-pick__city {
  color: #6b6b70;
  font-size: 0.875rem;
}

/* A person's areas on Tools > Staff access (real-life#219): each area is a
   checkbox with its name and, under it, what it opens. */
.staff-access__area {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-height: 44px;
  padding: 6px 0;
}

.staff-access__area span {
  display: grid;
  gap: 2px;
}

.staff-access__area small {
  color: #6b6b70;
  font-size: 0.875rem;
  font-weight: 400;
}

/* Setup pages above the churches (real-life#219): first run, onboarding and
   the owner's Churches page. They reuse the staff cards, forms, steps and
   rows; only what those lack is here. */
.staff-onboarding__heading {
  margin: 8px 0 0;
  font-size: 1.0625rem;
  font-weight: 700;
}

/* A step not reached yet: plain text, not a link. */
.staff-onboarding__later {
  color: #6b6b70;
  cursor: default;
}

.staff-onboarding__later:hover {
  background: transparent;
}

.staff-onboarding__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.staff-onboarding__finish {
  margin: 0;
}

/* Stacked tiles whose choice needs a line of explanation (real-life#219: a
   person's role, how a church's people get here): the note sits under the
   tile's name, smaller. */
.staff-tiles--notes .staff-tile small {
  display: block;
  margin-top: 2px;
  font-size: 0.84rem;
  font-weight: 400;
}

/* The Planning Center import (real-life#219, layout A with the "Your
   import" card): the parts as one bordered checklist in the order they
   import. Each row: the box, the name with its note under it, the
   "Needed by" tag when it is locked, and its count in Planning Center,
   right-aligned in tabular figures. */
.staff-short__form > .staff-import__fieldset {
  max-width: 48rem;
}

.staff-import__parts {
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
  border: 1px solid #c9c9d0;
  border-radius: 10px;
  overflow: hidden;
}

.staff-import__part {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px 0 0;
}

.staff-import__part + .staff-import__part {
  border-top: 1px solid var(--border);
}

.staff-import__label {
  flex: 1;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-height: 44px;
  padding: 10px 0 10px 14px;
  cursor: pointer;
}

.staff-import__label input {
  flex: none;
  width: 18px;
  height: 18px;
  margin: 3px 0 0;
  accent-color: var(--church-header, #304b3b);
}

.staff-import__label:has(input:disabled) {
  cursor: default;
}

.staff-import__text {
  display: grid;
  gap: 2px;
}

.staff-import__name {
  font-weight: 600;
}

.staff-import__note {
  color: var(--ink-muted);
  font-size: 0.84rem;
}

/* The "Needed by" tag: a third line under the note, at the left (owner,
   23 November 2026). A long list of parts wraps inside it. */
.staff-import__lock {
  justify-self: start;
  margin-top: 4px;
  white-space: normal;
  border-radius: 10px;
  line-height: 1.35;
}

.staff-import__lock[hidden] {
  display: none;
}

.staff-import__count {
  flex: none;
  min-width: 4.5ch;
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.staff-import__said:empty {
  display: none;
}

@media (max-width: 699px) {
  .staff-import__part {
    flex-wrap: wrap;
    padding-bottom: 10px;
  }

  .staff-import__label {
    flex-basis: 100%;
    padding-bottom: 0;
  }

  .staff-import__count {
    margin-left: auto;
  }
}

/* The run: where it stands, then a row per part. */
.staff-import__run {
  display: grid;
  gap: 16px;
}

.staff-import__status,
.staff-import__rest {
  display: grid;
  gap: 10px;
  padding: 18px 20px;
}

.staff-import__status-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.staff-import__status-title {
  margin: 0;
  font-size: 1.0625rem;
  font-weight: 700;
}

.staff-import__bar {
  width: 100%;
  height: 10px;
  border: 0;
  border-radius: 999px;
  overflow: hidden;
  background: var(--border);
  accent-color: var(--brand-dark);
}

.staff-import__bar::-webkit-progress-bar {
  background: var(--border);
}

.staff-import__bar::-webkit-progress-value {
  background: var(--brand-dark);
}

.staff-import__bar::-moz-progress-bar {
  background: var(--brand-dark);
}

.staff-import__skipped {
  margin-top: 8px;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--canvas);
  font-size: 0.9rem;
}

.staff-import__skipped-title {
  margin: 0 0 4px;
  font-weight: 600;
}

.staff-import__skipped ul {
  margin: 0;
  padding-left: 18px;
}

/* A provider key in a short form (Connect Planning Center, real-life#219):
   as wide as the key fields of Tools > Configuration (48rem), so a
   64-character Application ID shows whole, and in the same fixed-width
   type as the secret beside it. */
.staff-short__form > .staff-form__field--key {
  max-width: 48rem;
}

.staff-short__form input.staff-import__key {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* The import shows it is working (owner, 23 November 2026): the sync
   spinner inside the Running tags. */
.staff-import__live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.staff-import__live .staff-spinner {
  width: 12px;
  height: 12px;
  margin: 0;
}


/* Needs attention, folded (owner, 23 November 2026): one row with the
   count and how many are very important, and a chevron at the right that
   rolls the items down. The whole row is the button. The items keep their
   own row look; the very important ones come first, with a tag. */
.staff-overview__fold-head {
  cursor: pointer;
  list-style: none;
  min-height: 48px;
  box-sizing: border-box;
}

.staff-overview__fold-head::-webkit-details-marker {
  display: none;
}

.staff-overview__fold-head:hover {
  background: #fbecd0;
}

.staff-overview__fold-head:focus-visible {
  outline: 2px solid var(--staff-warning-ink);
  outline-offset: -4px;
}

.staff-overview__fold-hint {
  margin-left: auto;
  font-weight: 600;
  text-decoration: underline;
}

.staff-overview__fold-hint::after {
  content: attr(data-closed);
}

.staff-overview__fold[open] .staff-overview__fold-hint::after {
  content: attr(data-open);
}

.staff-overview__chevron {
  flex: none;
}

.staff-overview__fold[open] .staff-overview__chevron {
  transform: rotate(180deg);
}

.staff-overview__fold .staff-overview__alert:not(.staff-overview__fold-head) {
  font-weight: 500;
}

.staff-overview__important {
  margin-right: 6px;
  background: var(--staff-warning-ink);
  color: #ffffff;
  vertical-align: 1px;
}

/* Tools > Planning Center, Keys and settings (real-life#219): the key
   fields as wide as Configuration's, so a 64-character ID shows whole; the
   actions at the bottom right, Test connection then Save. */
.staff-pco-keys > .staff-form__field {
  max-width: 48rem;
}

.staff-pco-keys__actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* The nightly sync's time on the Planning Center card (real-life#219):
   the time and its Save on one row. */
.staff-form.staff-short__form.staff-pco-time {
  padding: 0;
  gap: 0;
}

.staff-pco-time__row {
  display: flex;
  gap: 8px;
}

.staff-pco-time__row input {
  flex: 1;
  min-width: 0;
}

.staff-pco-sync__off {
  white-space: nowrap;
}

/* Add person and Upload a CSV, at the right of the People page title
   (real-life#219). */
.staff-people__add {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-left: auto;
}

/* Merge two people (real-life#219): whose value stays, one row a field. */
.staff-merge {
  overflow-x: auto;
}

.staff-merge__table {
  width: 100%;
  border-collapse: collapse;
}

.staff-merge__table th,
.staff-merge__table td {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  text-align: left;
  vertical-align: middle;
}

.staff-merge__table thead th {
  border-top: 0;
}

.staff-merge__table tbody th {
  width: 160px;
  color: var(--ink-muted);
  font-weight: 600;
}

.staff-merge__pick {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  cursor: pointer;
}

.staff-merge__same {
  color: var(--ink-muted);
}

/* A file field in a short form reads like Configuration's. */
.staff-short__form input[type="file"] {
  font: inherit;
  font-size: 0.9rem;
}

/* A merged Tools tab's pages (owner, 23 November 2026): the segmented
   control, as links, under the tab row. */
.staff-tools__pages {
  margin: -4px 0 20px;
}

.staff-nl__seg a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 12px;
  color: var(--ink-muted);
  font-weight: 600;
  font-size: 0.85rem;
  text-decoration: none;
}

.staff-nl__seg a + a {
  border-left: 1px solid var(--border);
}

.staff-nl__seg a:hover {
  background: rgba(0, 0, 0, 0.04);
}

.staff-nl__seg a[aria-current="page"] {
  background: var(--church-button, #5e7f67);
  color: #fff;
}

.staff-nl__seg a[aria-current="page"] .staff-tabs__count {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.staff-nl__seg a:focus-visible {
  outline: 3px solid var(--staff-focus);
  outline-offset: -3px;
}

/* Who is in a group, on its form (real-life#219, layout A): a row per
   person, their name, Leader / Member and Take out. */
.staff-group-people {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  border-top: 1px solid var(--border);
}

.staff-group-people__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.staff-group-people__who {
  flex: 1 1 14rem;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.staff-group-people__who small {
  color: var(--ink-muted);
  font-size: 0.85rem;
  overflow-wrap: anywhere;
}

.staff-group-people__out {
  margin: 0;
  white-space: nowrap;
}

.staff-group-people__adding {
  margin: 10px 0 0;
}

button.staff-chips__remove {
  border: 0;
  padding: 0;
  font: inherit;
  cursor: pointer;
}

/* A name box with a list to pick from (Add people, Add someone): no browser
   arrow, the design record's rule for our own chevrons. */
.staff-short__form input[list]::-webkit-calendar-picker-indicator {
  display: none !important;
}

/* The people picker (owner, 23 November 2026: design A, the one way /staff
   picks people): a search box with a magnifier, the matches under it with a
   photo or initials, the typed part marked and a line of detail; picks as
   chips with the photo; one person as a card with Change. */
.staff-people-picker .staff-picker__chips {
  margin: 0 0 10px;
}

.staff-people-picker__box {
  max-width: 640px;
}

.staff-people-picker__icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ink-muted);
  pointer-events: none;
}

.staff-form input.staff-people-picker__input[type="text"] {
  width: 100%;
  padding-left: 42px;
}

.staff-picker__chip--person {
  padding-left: 4px;
  gap: 8px;
}

.staff-picker__chip--person .staff-group__avatar,
.staff-picker__chip--person [data-part="avatar"] {
  width: 26px;
  height: 26px;
  font-size: 0.65rem;
  flex: none;
}

.staff-people-picker__option {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding: 6px 10px;
}

.staff-people-picker__option .staff-group__avatar {
  flex: none;
}

.staff-people-picker__who {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.staff-people-picker__who b {
  font-weight: 600;
}

.staff-people-picker__who mark {
  background: var(--staff-success-bg);
  color: inherit;
  border-radius: 3px;
}

.staff-people-picker__who small,
.staff-people-picker__option .staff-people-picker__who small {
  color: var(--ink-muted);
  font-size: 0.85rem;
  overflow-wrap: break-word;
}

.staff-people-picker__option[aria-disabled="true"] {
  cursor: default;
  opacity: 0.6;
}

.staff-people-picker__option[aria-disabled="true"]:hover {
  background: transparent;
}

.staff-people-picker__keys {
  margin-top: 4px;
  padding: 8px 10px 4px;
  border-top: 1px solid var(--border);
  color: var(--ink-muted);
  font-size: 0.8rem;
}

.staff-people-picker__one {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 640px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  margin: 0 0 10px;
}

.staff-people-picker__one[hidden] {
  display: none;
}

/* An open picker list sits over the floating save bar, and scrolls into
   view above it. */
.staff-people-picker:focus-within {
  position: relative;
  z-index: 6;
}

.staff-people-picker .staff-picker__list {
  scroll-margin-bottom: 96px;
}

.staff-people-picker__why {
  align-self: flex-start;
  margin-top: 4px;
}

/* The message picker's muted option text is for its address line only. */
.staff-picker__option.staff-people-picker__option .staff-people-picker__who {
  color: var(--ink);
  font-size: 0.95rem;
}

.staff-picker__option.staff-people-picker__option .staff-group__avatar--initials {
  color: #fff;
  font-size: 0.75rem;
}

.staff-picker__option.staff-people-picker__option .staff-people-picker__why {
  color: var(--ink-muted);
  font-size: 0.75rem;
}

.staff-people-picker__who mark {
  background: #e3efd2;
  padding: 0 1px;
}

/* Serving (real-life#219, spec 28.8; owner, 23 November 2026: design B, the
   schedule grid). The month bar: the month, the team filter, the months
   either side and Ask. The grid scrolls sideways in its own box on a narrow
   screen, the position column staying in view. A cell is its status: green
   accepted, blue asked, gray not asked yet, amber declined (never red: a
   decline is not an error), dashed open. */
.staff-serving__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  margin: 0 0 16px;
}

.staff-serving__month {
  margin: 0;
  font-size: 1.3rem;
  flex: 0 0 auto;
}

.staff-serving__teams {
  flex-wrap: wrap;
}

.staff-serving__months {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

.staff-serving__spacer {
  flex: 1;
}

.staff-serving__scroll {
  overflow-x: auto;
  padding: 0;
}

.staff-serving__grid {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  min-width: 720px;
}

.staff-serving__grid th,
.staff-serving__grid td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: middle;
  font-size: 0.88rem;
}

.staff-serving__grid thead th {
  background: var(--canvas, #f7f7f9);
  white-space: nowrap;
}

.staff-serving__grid thead th small {
  display: block;
  color: var(--ink-muted);
  font-weight: 500;
}

.staff-serving__grid thead a {
  font-weight: 700;
}

.staff-serving__pos {
  position: sticky;
  left: 0;
  z-index: 1;
  min-width: 140px;
  background: var(--surface);
  font-weight: 600;
}

.staff-serving__team th {
  background: var(--canvas, #f7f7f9);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.staff-serving__cell {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 4px 8px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}

a.staff-serving__cell:hover {
  text-decoration: none;
  filter: brightness(0.97);
}

.staff-serving__cell--accepted { background: var(--staff-success-bg); color: var(--staff-success-ink); }
.staff-serving__cell--asked { background: var(--staff-info-bg); color: var(--staff-info-ink); }
.staff-serving__cell--scheduled { background: #f2f2f7; color: var(--ink); border-color: var(--border); }
.staff-serving__cell--declined { background: var(--staff-warning-bg); color: var(--staff-warning-ink); }
.staff-serving__cell--open { border: 1px dashed #aeaeb2; color: var(--ink-muted); font-weight: 500; background: var(--surface); }

.staff-serving__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  flex: none;
}

.staff-serving__legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  font-size: 0.88rem;
  color: var(--ink);
}

.staff-serving__legend li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.staff-serving__swatch {
  min-height: 18px;
  width: 26px;
  padding: 0 6px;
}

.staff-serving__state {
  display: inline-flex;
  min-height: 26px;
  font-size: 0.8rem;
  margin-left: auto;
}

/* The cell's pop-up: the team's people to pick from. */
.staff-serving-slot__team {
  border: 0;
  margin: 0 0 16px;
  padding: 0;
}

.staff-serving-slot__choice {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 10px;
  cursor: pointer;
}

.staff-serving-slot__choice:hover,
.staff-serving-slot__choice:has(input:checked) {
  background: var(--staff-success-bg);
}

.staff-serving-slot__choice.is-away {
  opacity: 0.6;
  cursor: default;
}

.staff-serving-slot__choice.is-away:hover {
  background: transparent;
}

.staff-serving-slot__who {
  display: flex;
  flex-direction: column;
}

.staff-serving-slot__who small {
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.staff-serving-slot__note {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--staff-warning-bg);
  color: var(--staff-warning-ink);
}

.staff-serving-slot__clear {
  margin-right: auto;
}

/* A plan's page: panel heads with a small button, the order of service and
   who is serving. */
.staff-serving__panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.staff-serving__panel-head .staff-pco__panel-title {
  margin: 0;
}

.staff-serving__order {
  list-style: none;
  margin: 0;
  padding: 0;
}

.staff-serving__item {
  display: grid;
  grid-template-columns: 52px 78px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: baseline;
  padding: 10px 0;
  border-top: 1px solid var(--border);
}

.staff-serving__clock,
.staff-serving__len {
  font-variant-numeric: tabular-nums;
  color: var(--ink-muted);
  font-size: 0.9rem;
}

.staff-serving__kind {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.staff-serving__what {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.staff-serving__what small {
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.staff-serving__team-name {
  font-size: 0.95rem;
  margin: 12px 0 4px;
}

.staff-serving__who {
  list-style: none;
  margin: 0;
  padding: 0;
}

.staff-serving__who li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
}

.staff-serving__pos-name {
  width: 120px;
  color: var(--ink-muted);
  font-size: 0.9rem;
}

.staff-serving__positions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
}

/* The order of service form and a team's positions: a row per item. */
.staff-serving__order-form {
  padding: 24px 28px 0;
}

.staff-serving__rows {
  list-style: none;
  margin: 12px 0 14px;
  padding: 0;
}

.staff-serving__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px 12px;
  padding: 12px 0;
  border-top: 1px solid var(--border);
}

.staff-serving__row .staff-form__field {
  margin: 0;
}

.staff-serving__move {
  display: flex;
  gap: 4px;
}

.staff-serving__f-kind { flex: 0 1 130px; }
.staff-serving__f-song { flex: 1 1 180px; }
.staff-serving__f-title { flex: 2 1 200px; }
.staff-serving__f-detail { flex: 1 1 160px; }
.staff-serving__f-min { flex: 0 0 90px; }

.staff-serving__row--position {
  align-items: center;
}

.staff-serving__remove {
  margin: 0 0 10px;
  white-space: nowrap;
}

.staff-serving__row--position .staff-serving__remove {
  margin: 0;
}

.staff-serving__savebar {
  margin: 8px -28px 0;
  border-width: 1px 0 0;
  border-radius: 0 0 var(--radius) var(--radius);
}

.staff-serving__search {
  flex: 0 1 320px;
}

.staff-serving-slot .staff-dialog__header {
  align-items: flex-start;
  margin: 0;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
}

.staff-serving-slot__choice input[type="radio"] {
  flex: none;
  width: 20px;
  height: 20px;
  margin: 0;
}

.staff-short__form button[data-action="serving-order#add"] {
  width: auto;
  align-self: flex-start;
}

/* The Planning Center card's two buttons side by side (owner, 23 November
   2026): Turn sync on (or off), then Sync, the main one right-most. */
.staff-pco-sync-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.staff-pco-sync-actions form {
  margin: 0;
}

.staff-pco-sync-actions .staff-button {
  width: auto;
}

/* New list: "Add a whole group, team or household", folded by default with a
   chevron at the top right (owner, 23 November 2026). */
.staff-picker-fold {
  padding: 0;
}

.staff-picker-fold__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 52px;
  padding: 8px 16px;
  border-radius: 14px;
  cursor: pointer;
  list-style: none;
}

.staff-picker-fold__summary::-webkit-details-marker {
  display: none;
}

.staff-picker-fold__summary:hover {
  background: color-mix(in srgb, var(--canvas) 60%, var(--surface));
}

.staff-picker-fold__summary .staff-form__label {
  margin: 0;
}

.staff-picker-fold__chevron {
  flex: none;
  color: var(--ink-muted);
  transition: transform 0.15s ease;
}

.staff-picker-fold[open] .staff-picker-fold__chevron {
  transform: rotate(180deg);
}

.staff-picker-fold__body {
  padding: 0 16px 16px;
}

.staff-picker-fold__body > .staff-form__hint {
  margin: 0;
}

/* Tick members and remove them at once (owner, 23 November 2026): a bar
   above the list with Select all and Remove selected, and a box at the start
   of each row. */
.staff-bulk-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 0 0 10px;
  padding: 10px 16px;
}

.staff-bulk-bar__all {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
}

.staff-bulk-bar__all input,
.staff-list-member__tick {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--church-header, #304b3b);
  cursor: pointer;
  flex: none;
}

.staff-row--plain.staff-list-member {
  grid-template-columns: 18px minmax(0, 1fr) auto;
}

/* A record card whose one action is its main one (an email list's Add
   members; owner, 23 November 2026): the button spans the card. */
.staff-profile__actions--one .staff-button {
  flex: 1 1 auto;
}
