/*
 * Admin redesign (Mint Mist): a deep green sidebar beside one rounded mint-grey panel, white cards lifted by a soft shadow, pill buttons
 * and chips. Loaded after Filament's CSS and the older theme layer, so every rule is scoped to
 * html.qp-rd and most need !important to win over them. Colours live in the tokens below.
 */
html.qp-rd {
  --rd-side: #1d1612;
  --rd-side-ink: #c8c0b9;
  --rd-side-muted: #8a817a;
  --rd-side-hover: rgba(255, 255, 255, .05);
  --rd-side-active: rgba(var(--primary-400), .16);
  --rd-canvas: #eef4f1;
  --rd-card: #ffffff;
  /* Every card, top-bar pill and popup: a 1px outline and a soft shadow that lift it off the panel. */
  --rd-border: #e1ebe6;
  --rd-shadow: 0 1px 2px rgba(16, 35, 28, .05), 0 4px 14px -6px rgba(16, 35, 28, .10);
  --rd-ink: #0f1f19;
  --rd-muted: #5f7169;
  --rd-line: #e7eeea;
  --rd-chip: #eef4f1;
  --rd-chip-hover: #e2ece7;
  --rd-field: #f2f7f4;
  --rd-row-hover: #f6faf8;
  --rd-cta: #0f2a20;
  --rd-cta-ink: #ffffff;
  /* The Dashboard Template theme colour (Filament's primary scale) and the text that reads on it. */
  --rd-accent: rgb(var(--primary-500));
  --rd-accent-ink: #fff;
  --rd-radius-panel: 28px;
  --rd-radius-card: 20px;
  --rd-radius-field: 14px;
  --sidebar-width: 15.5rem;
  --collapsed-sidebar-width: 4.75rem;
}
/* Dark Mint Mist: a near-black green panel, cards a step above it, the sidebar darkest. */
html.qp-rd.dark {
  --rd-side: #071a13;
  --rd-canvas: color-mix(in srgb, rgb(var(--primary-500)) 6%, #0c0c0c);
  --rd-card: color-mix(in srgb, rgb(var(--primary-500)) 7.5%, #121212);
  --rd-border: color-mix(in srgb, rgb(var(--primary-500)) 8%, #1c1c1c);
  --rd-side-active: rgba(255, 255, 255, .08);
  --rd-shadow: none;
  --rd-ink: color-mix(in srgb, rgb(var(--primary-500)) 4%, #eaeaea);
  --rd-muted: color-mix(in srgb, rgb(var(--primary-500)) 10%, #929292);
  --rd-line: color-mix(in srgb, rgb(var(--primary-500)) 8%, #1f1f1f);
  --rd-chip: color-mix(in srgb, rgb(var(--primary-500)) 8%, #191919);
  --rd-chip-hover: color-mix(in srgb, rgb(var(--primary-500)) 9%, #222222);
  --rd-field: color-mix(in srgb, rgb(var(--primary-500)) 8%, #161616);
  --rd-row-hover: color-mix(in srgb, rgb(var(--primary-500)) 8%, #161616);
  --rd-cta: #e7f0eb;
  --rd-cta-ink: #0f1f19;
}

/* ---- Page frame ------------------------------------------------------------ */

html.qp-rd .fi-body { background: var(--rd-side) !important; color: var(--rd-ink); }
html.qp-rd .fi-layout { background: var(--rd-side); }
html.qp-rd .fi-main-ctn {
  background: var(--rd-canvas);
  border: 1px solid transparent;
  border-radius: var(--rd-radius-panel);
  margin: 12px 12px 12px 0;
  min-height: calc(100vh - 24px);
  width: auto !important;
  min-width: 0;
}
@media (max-width: 1023px) {
  html.qp-rd .fi-main-ctn { margin: 8px; min-height: calc(100vh - 16px); border-radius: 22px; }
}
/* On desktop the rounded panel scrolls, not the window, so its scrollbar sits inside it. */
@media (min-width: 1024px) {
  html.qp-rd-app, html.qp-rd-app body { height: 100%; overflow: hidden; }
  html.qp-rd-app .fi-layout { height: 100vh; min-height: 0 !important; }
  html.qp-rd-app .fi-main-ctn {
    height: calc(100vh - 24px); min-height: 0; overflow-y: auto; overscroll-behavior: contain;
    scrollbar-width: thin; scrollbar-color: color-mix(in srgb, var(--rd-ink) 22%, transparent) transparent;
  }
}
html.qp-rd .fi-main { padding: 0 2rem 2rem !important; max-width: none !important; }
@media (max-width: 767px) { html.qp-rd .fi-main { padding: 0 1rem 1.5rem !important; } }
html.qp-rd .fi-page > section { padding-top: .75rem !important; row-gap: 1.5rem !important; }

/* ---- Top bar --------------------------------------------------------------- */

/* It stays at the top of the panel while the page scrolls (the panel scrolls on desktop, the window on phones). */
html.qp-rd .qp-rd-topbar {
  position: sticky; top: 0; z-index: 20; background: var(--rd-canvas) !important;
  border-radius: var(--rd-radius-panel) var(--rd-radius-panel) 0 0;
}
/* The Back pill sits just above the page title. */
html.qp-rd .qp-rd-title { display: flex; flex-direction: column; align-items: flex-start; gap: .75rem; }
html.qp-rd .fi-main-ctn { scroll-padding-top: calc(var(--rd-topbar-h, 0px) + 1rem); }
html.qp-rd .qp-rd-topbar > nav { background: transparent !important; box-shadow: none !important; border: 0 !important; height: auto !important; }
html.qp-rd .qp-rd-bar { display: flex; align-items: center; gap: .625rem; padding: 1.5rem 2rem .5rem; }
@media (max-width: 767px) { html.qp-rd .qp-rd-bar { padding: 1rem 1rem .25rem; gap: .5rem; } }
html.qp-rd .qp-rd-round,
html.qp-rd .qp-rd-bell .fi-icon-btn {
  flex: none; display: inline-flex; align-items: center; justify-content: center;
  width: 46px !important; height: 46px !important; border-radius: 9999px !important;
  background: var(--rd-card) !important; color: var(--rd-ink) !important; border: 1px solid var(--rd-border) !important; box-shadow: var(--rd-shadow); cursor: pointer;
  transition: background-color .15s;
}
html.qp-rd .qp-rd-round[hidden] { display: none; }
html.qp-rd .qp-rd-round:hover, html.qp-rd .qp-rd-bell .fi-icon-btn:hover { background: var(--rd-chip-hover) !important; }
html.qp-rd .qp-rd-round svg { width: 20px !important; height: 20px !important; }
html.qp-rd .qp-rd-bell .fi-icon-btn svg, html.qp-rd .qp-rd-bell .fi-icon-btn-icon { width: 20px !important; height: 20px !important; color: var(--rd-ink) !important; }
html.qp-rd .qp-rd-bell { flex: none; }
html.qp-rd .qp-rd-bell .fi-icon-btn-badge-ctn { top: 6px !important; inset-inline-start: auto !important; right: 8px !important; }

html.qp-rd .qp-rd-search {
  position: relative; flex: 1; min-width: 0; display: flex; align-items: center; gap: .625rem;
  height: 46px; padding: 0 .875rem 0 1.125rem; border-radius: 9999px; background: var(--rd-card); border: 1px solid var(--rd-border); box-shadow: var(--rd-shadow);
}
html.qp-rd .qp-rd-search-icon { display: inline-flex; color: var(--rd-muted); }
html.qp-rd .qp-rd-search-icon svg { width: 18px; height: 18px; }
html.qp-rd .qp-rd-search input {
  flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; box-shadow: none !important;
  font-size: .9375rem; color: var(--rd-ink); padding: 0;
}
html.qp-rd .qp-rd-search input::placeholder { color: var(--rd-muted); }
html.qp-rd .qp-rd-search input::-webkit-search-cancel-button { display: none; }
html.qp-rd .qp-rd-search kbd {
  flex: none; font: 500 .6875rem/1 ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--rd-muted);
  border: 1px solid var(--rd-line); border-radius: 6px; padding: .25rem .4rem;
}
@media (max-width: 767px) {
  html.qp-rd .qp-rd-search kbd, html.qp-rd .qp-rd-hide-sm { display: none !important; }
  html.qp-rd .qp-rd-round, html.qp-rd .qp-rd-bell .fi-icon-btn, html.qp-rd .qp-rd-search { width: 42px !important; height: 42px !important; }
  html.qp-rd .qp-rd-search { width: auto !important; }
}
html.qp-rd .qp-rd-results {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0; max-height: min(70vh, 32rem); overflow-y: auto;
  background: var(--rd-card); border-radius: 18px; padding: .5rem; z-index: 40;
  box-shadow: 0 18px 40px -12px rgba(22, 18, 16, .25), 0 0 0 1px var(--rd-line);
}
html.qp-rd .qp-rd-results[hidden] { display: none; }
html.qp-rd .qp-rd-results-group { padding: .5rem .75rem .25rem; font-size: .6875rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--rd-muted); }
html.qp-rd .qp-rd-hit { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding: .55rem .75rem; border-radius: 12px; color: var(--rd-ink); text-decoration: none; }
html.qp-rd .qp-rd-hit-label { font-size: .875rem; font-weight: 500; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
html.qp-rd .qp-rd-hit-meta { flex: none; font-size: .75rem; color: var(--rd-muted); max-width: 45%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
html.qp-rd .qp-rd-hit:hover, html.qp-rd .qp-rd-hit[aria-selected="true"] { background: var(--rd-chip); }
html.qp-rd .qp-rd-results-empty { padding: 1rem .75rem; font-size: .875rem; color: var(--rd-muted); }

html.qp-rd .qp-rd-cta {
  flex: none; display: inline-flex; align-items: center; gap: .5rem; height: 46px; padding: 0 1.375rem;
  border-radius: 9999px; background: var(--rd-cta); color: var(--rd-cta-ink); font-size: .9375rem; font-weight: 600;
  text-decoration: none; transition: opacity .15s;
}
html.qp-rd .qp-rd-cta:hover { opacity: .88; }
/* The older theme layer greys every svg; the CTA's icon follows the button's own ink. */
html.qp-rd .qp-rd-cta svg { width: 18px; height: 18px; color: inherit !important; stroke: currentColor !important; }
@media (max-width: 767px) { html.qp-rd .qp-rd-cta span { display: none; } html.qp-rd .qp-rd-cta { width: 46px; padding: 0; justify-content: center; } }

/* ---- Sidebar --------------------------------------------------------------- */

html.qp-rd .fi-sidebar { background: var(--rd-side) !important; border: 0 !important; box-shadow: none !important; }
html.qp-rd .fi-sidebar-header { background: transparent !important; border: 0 !important; box-shadow: none !important; height: 5rem !important; padding: 0 1.5rem !important; }
html.qp-rd .fi-sidebar-header .fi-icon-btn { display: none !important; }
html.qp-rd .fi-sidebar-header .fi-logo { color: #fff !important; font-size: 1.25rem !important; font-weight: 700 !important; letter-spacing: -.01em; }
html.qp-rd .fi-sidebar-nav { scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .14) transparent; }
html.qp-rd .fi-sidebar-nav { padding: .25rem 1rem 1rem !important; row-gap: .25rem !important; }
html.qp-rd .fi-sidebar-nav-groups { margin: 0 !important; row-gap: .125rem !important; }
html.qp-rd .fi-sidebar-group, html.qp-rd .fi-sidebar-group-items { row-gap: .125rem !important; }

/* Group headings read as items: icon, label, chevron. */
html.qp-rd .fi-sidebar-group-button { padding: .5rem .75rem !important; border-radius: 12px; column-gap: .75rem !important; }
html.qp-rd .fi-sidebar-group-button:hover { background: var(--rd-side-hover); }
/* Beats the older theme, which darkens the heading on hover for its light sidebar. */
html.qp-rd .fi-sidebar .fi-sidebar-group-button:hover .fi-sidebar-group-label,
html.qp-rd .fi-sidebar .fi-sidebar-group-button:hover .fi-sidebar-group-icon { color: #fff !important; }
html.qp-rd .fi-sidebar .fi-sidebar-group-label {
  text-transform: none !important; letter-spacing: 0 !important; font-size: .875rem !important; font-weight: 400 !important;
  color: var(--rd-side-ink) !important; line-height: 1.5rem !important;
}
html.qp-rd .fi-sidebar .fi-sidebar-group.fi-active > .fi-sidebar-group-button .fi-sidebar-group-label { color: #fff !important; font-weight: 400 !important; }
html.qp-rd .fi-sidebar .fi-sidebar-group-icon,
html.qp-rd .fi-sidebar .fi-sidebar-item-icon,
html.qp-rd .fi-sidebar .fi-dropdown-trigger svg { width: 20px !important; height: 20px !important; color: var(--rd-side-muted) !important; }
html.qp-rd .fi-sidebar .fi-sidebar-group.fi-active > .fi-sidebar-group-button .fi-sidebar-group-icon { color: #fff !important; }
html.qp-rd .fi-sidebar .fi-sidebar-group-collapse-button { width: 1.5rem; height: 1.5rem; }
html.qp-rd .fi-sidebar .fi-sidebar-group-collapse-button svg { width: 16px !important; height: 16px !important; color: var(--rd-side-muted) !important; }

html.qp-rd .fi-sidebar .fi-sidebar-item > a { padding: .5rem .75rem !important; border-radius: 12px !important; column-gap: .75rem !important; }
html.qp-rd .fi-sidebar .fi-sidebar-item-label { color: var(--rd-side-ink) !important; font-size: .875rem !important; font-weight: 400 !important; line-height: 1.5rem !important; }
html.qp-rd .fi-sidebar .fi-sidebar-item:not(.fi-sidebar-item-active) > a:hover { background: var(--rd-side-hover) !important; }
html.qp-rd .fi-sidebar .fi-sidebar-item:not(.fi-sidebar-item-active) > a:hover .fi-sidebar-item-label,
html.qp-rd .fi-sidebar .fi-sidebar-item:not(.fi-sidebar-item-active) > a:hover .fi-sidebar-item-icon { color: #fff !important; }
html.qp-rd .fi-sidebar .fi-sidebar-item-active > a { background: var(--rd-side-active) !important; box-shadow: none !important; }
html.qp-rd .fi-sidebar .fi-sidebar-item-active .fi-sidebar-item-label { color: #fff !important; font-weight: 400 !important; }
html.qp-rd .fi-sidebar .fi-sidebar-item-active .fi-sidebar-item-icon { color: #fff !important; }
/* Items inside a group sit under its label, without icons. */
html.qp-rd .fi-sidebar .fi-sidebar-group[data-group-label]:not([data-group-label=""]) .fi-sidebar-group-items { padding-inline-start: 1.25rem; }
html.qp-rd .fi-sidebar .fi-sidebar-group[data-group-label]:not([data-group-label=""]) .fi-sidebar-item-label { font-size: .8125rem !important; }

html.qp-rd .fi-sidebar .fi-badge {
  border-radius: 9999px !important; background: var(--rd-accent) !important; color: var(--rd-accent-ink) !important; box-shadow: 0 0 0 1px rgba(255, 255, 255, .14) !important;
  min-width: 1.5rem; justify-content: center; font-size: .6875rem !important; font-weight: 700 !important; padding: .1rem .45rem !important;
}
html.qp-rd .fi-sidebar .fi-badge * { color: var(--rd-accent-ink) !important; }

html.qp-rd .qp-rd-user {
  display: flex; align-items: center; gap: .625rem; padding: 1rem 1.25rem 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, .07);
}
html.qp-rd .qp-rd-avatar {
  flex: none; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 9999px;
  background: #c48a12; color: #fff; font-size: .75rem; font-weight: 700; letter-spacing: .02em;
}
html.qp-rd .qp-rd-user-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.15; }
html.qp-rd .qp-rd-user-name { color: #fff; font-size: .875rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
html.qp-rd .qp-rd-user-role { color: var(--rd-side-muted); font-size: .75rem; }
html.qp-rd .qp-rd-user-btn {
  flex: none; display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 9999px;
  color: var(--rd-side-muted); background: transparent; border: 0; cursor: pointer;
}
html.qp-rd .qp-rd-user-btn:hover { background: var(--rd-side-hover); color: #fff; }
html.qp-rd .qp-rd-user-btn svg { width: 18px; height: 18px; }
html.qp-rd .qp-rd-user-out { display: contents; }
html.qp-rd .qp-rd-when-dark { display: none; }
html.qp-rd.dark .qp-rd-when-dark { display: inline-flex; }
html.qp-rd.dark .qp-rd-when-light { display: none; }

/* Collapsed rail: icons only, the user's avatar and the theme switch stacked at the foot. */
@media (min-width: 1024px) {
  html.qp-rd .fi-sidebar:not(.fi-sidebar-open) .fi-sidebar-header { display: none !important; }
  html.qp-rd .fi-sidebar:not(.fi-sidebar-open) .fi-sidebar-nav { padding: 2.5rem .75rem 1rem !important; }
  html.qp-rd .fi-sidebar:not(.fi-sidebar-open) .qp-rd-user { flex-direction: column; padding: 1rem .5rem 1.25rem; }
  html.qp-rd .fi-sidebar:not(.fi-sidebar-open) .qp-rd-user-text,
  html.qp-rd .fi-sidebar:not(.fi-sidebar-open) .qp-rd-user-out { display: none; }
}
html.qp-rd .fi-sidebar-open .qp-rd-user-out { display: contents; }

/* A card inside another card (a table inside a list card, a section inside a section) has no outline or shadow of its own. */
html.qp-rd :is(.fi-section, .fi-ta-ctn, .fi-wi-stats-overview-stat, .fi-wi-chart, .fi-wi-widget, .fi-fo-tabs, .fi-card, .qp-rd-list-card) :is(.fi-section, .fi-ta-ctn, .fi-wi-stats-overview-stat, .fi-wi-chart, .fi-wi-widget, .fi-fo-tabs, .fi-card, .qp-rd-list-card) { border: 0 !important; box-shadow: none !important; }

/* The dashboard, file manager, tickets and other hand-drawn pages draw their own white boxes: their
   outline takes the same colour as the cards'. */
html.qp-rd:not(.dark) .fi-main .qp\:bg-white.qp\:border, html.qp-rd:not(.dark) dialog.qp\:bg-white.qp\:border { border-color: var(--rd-border) !important; }

/* Ticket page: a member whose account is deleted (badge plus date, and a note above the reply form). */
html.qp-rd .qp-rd-gone { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; margin-top: .25rem; color: var(--rd-muted); font-size: .8125rem; }
html.qp-rd .qp-rd-note {
  margin: 0 0 1rem; padding: .75rem 1rem; border-radius: var(--rd-radius-field); font-size: .875rem; line-height: 1.45;
  background: #fff7e6; color: #8a4b08; border: 1px solid #f6dfb4;
}
/* Their dark boxes (a neutral near-black) take the dark card colour too. */
html.qp-rd.dark .fi-main .qp\:bg-white, html.qp-rd.dark dialog.qp\:bg-white { background-color: var(--rd-card) !important; border-color: var(--rd-border) !important; }
html.qp-rd.dark .qp-rd-note { background: rgba(245, 158, 11, .1); color: #fbbf24; border-color: rgba(245, 158, 11, .25); }

/* ---- Page header ----------------------------------------------------------- */

html.qp-rd .fi-header-heading { font-size: 2rem !important; line-height: 1.15 !important; font-weight: 700 !important; letter-spacing: -.025em !important; color: var(--rd-ink) !important; }
html.qp-rd .fi-header-subheading { color: var(--rd-muted) !important; font-size: .9375rem !important; margin-top: .375rem !important; }
html.qp-rd .fi-breadcrumbs { display: none; }

/* ---- Cards: sections, tables, widgets, tabs ------------------------------- */

html.qp-rd .fi-section,
html.qp-rd .fi-ta-ctn,
html.qp-rd .fi-wi-stats-overview-stat,
html.qp-rd .fi-wi-chart,
html.qp-rd .fi-wi-widget,
html.qp-rd .fi-fo-tabs,
html.qp-rd .fi-card {
  background: var(--rd-card) !important; border: 1px solid var(--rd-border) !important; box-shadow: var(--rd-shadow) !important;
  border-radius: var(--rd-radius-card) !important; --tw-ring-shadow: 0 0 #0000 !important;
}
html.qp-rd .fi-section-header,
html.qp-rd .fi-ta-header,
html.qp-rd .fi-ta-header-ctn { background: transparent !important; border: 0 !important; }
html.qp-rd .fi-section-header { padding: 1.375rem 1.5rem .25rem !important; }
html.qp-rd .fi-section-content-ctn { border-top: 0 !important; }
html.qp-rd .fi-section-content { padding: 1rem 1.5rem 1.5rem !important; }
html.qp-rd .fi-section-header-heading { font-size: 1rem !important; font-weight: 600 !important; color: var(--rd-ink) !important; }
html.qp-rd .fi-section-header-description { color: var(--rd-muted) !important; }
html.qp-rd .fi-fo-tabs .fi-section { background: transparent !important; }
/* A section inside a tab (the user create/update modal): the tab gives the inset once, lined up with the tab buttons. */
html.qp-rd .fi-fo-tabs > .fi-fo-tabs-tab { padding: 1.25rem !important; }
html.qp-rd .fi-fo-tabs-tab .fi-section-header { padding: 0 0 .25rem !important; }
html.qp-rd .fi-fo-tabs-tab .fi-section-content { padding: 1rem 0 0 !important; }
/* Its edge is the field's edge now: overflow would cut the field's focus ring. */
html.qp-rd .fi-fo-tabs-tab .fi-section { overflow: visible !important; border-radius: 0 !important; }
/* In a modal the tabs are not a card of their own: no outline, and they line up with the modal's title and buttons. */
html.qp-rd .fi-modal-window .fi-fo-tabs { background: transparent !important; border: 0 !important; box-shadow: none !important; border-radius: 0 !important; }
html.qp-rd .fi-modal-window .fi-fo-tabs > .fi-tabs { padding-inline: 0 !important; padding-top: 0 !important; }
html.qp-rd .fi-modal-window .fi-fo-tabs > .fi-fo-tabs-tab { padding: 1.25rem 0 .25rem !important; }

/* Tables: quiet headings, hairline rows, no zebra. */
html.qp-rd .fi-ta-header-toolbar { padding: 1.25rem 1.375rem .75rem !important; border: 0 !important; }
html.qp-rd .fi-ta-content { border-top: 0 !important; padding: 0 1.375rem; }
html.qp-rd .fi-ta-filter-indicators { background: transparent !important; }
html.qp-rd .fi-ta-table { border-collapse: separate; }
html.qp-rd .fi-ta-table thead,
html.qp-rd .fi-ta-table thead tr { background: transparent !important; }
html.qp-rd .fi-ta-table > :not([hidden]) ~ :not([hidden]) { border-color: var(--rd-line) !important; }
html.qp-rd .fi-ta-table thead th { padding-top: .5rem !important; padding-bottom: .75rem !important; }
html.qp-rd .fi-ta-header-cell-label, html.qp-rd .fi-ta-header-cell button span { color: var(--rd-muted) !important; font-weight: 500 !important; font-size: .8125rem !important; }
html.qp-rd .fi-ta-table tbody { border-top: 1px solid var(--rd-line) !important; }
html.qp-rd .fi-ta-table tbody > tr { border-color: var(--rd-line) !important; }
html.qp-rd .fi-ta-row, html.qp-rd .fi-ta-row:nth-child(2n), html.qp-rd .fi-ta-row:nth-child(odd) { background: transparent !important; }
/* The sticky actions column keeps its own fill so rows scroll under it; it follows the row. */
html.qp-rd .fi-ta-table tr > td:last-child, html.qp-rd .fi-ta-table tr > th:last-child { background: var(--rd-card) !important; }
/* Row hover: the cells take the fill (a row's own background cannot be rounded), the end cells round it off. */
html.qp-rd .fi-ta-table { border-spacing: 0; }
html.qp-rd .fi-ta-table .fi-ta-row:hover > td { background: var(--rd-row-hover) !important; }
html.qp-rd .fi-ta-table .fi-ta-row > td:first-child { border-radius: 12px 0 0 12px; }
html.qp-rd .fi-ta-table .fi-ta-row > td:last-child { border-radius: 0 12px 12px 0; }
/* One row height: a shared minimum, and each table's tallest row once panel.js has measured it. */
html.qp-rd .fi-ta-table > tbody > tr > td { box-sizing: border-box; height: var(--qp-row-h, 3.125rem); }
html.qp-rd .fi-ta-text-item-label, html.qp-rd .fi-ta-cell { color: var(--rd-ink); }
html.qp-rd .fi-ta-footer, html.qp-rd .fi-ta-pagination { background: transparent !important; border-top: 0 !important; padding: 1rem 1.375rem 1.25rem !important; }
html.qp-rd .fi-ta-empty-state { background: transparent !important; }

/* ---- Buttons, badges, fields ---------------------------------------------- */

html.qp-rd .fi-btn { border-radius: 9999px !important; box-shadow: none !important; }
html.qp-rd .fi-btn.fi-color-primary,
html.qp-rd .fi-btn.fi-btn-color-primary { background: var(--rd-cta) !important; color: var(--rd-cta-ink) !important; --tw-ring-shadow: 0 0 #0000 !important; }
html.qp-rd .fi-btn.fi-color-primary:hover { opacity: .88; }
html.qp-rd .fi-btn.fi-color-primary .fi-btn-label, html.qp-rd .fi-btn.fi-color-primary svg { color: var(--rd-cta-ink) !important; }
html.qp-rd .fi-btn.fi-color-gray { background: var(--rd-chip) !important; --tw-ring-shadow: 0 0 #0000 !important; }
html.qp-rd .fi-btn.fi-color-gray:hover { background: var(--rd-chip-hover) !important; }
/* Toggle buttons (Default color mode, Seasonal background) are primary buttons too: only the picked one wears the CTA colour. */
html.qp-rd .fi-fo-toggle-buttons .fi-btn.fi-color-primary { background: var(--rd-chip) !important; color: var(--rd-ink) !important; }
html.qp-rd .fi-fo-toggle-buttons .fi-btn.fi-color-primary:hover { background: var(--rd-chip-hover) !important; opacity: 1; }
html.qp-rd .fi-fo-toggle-buttons .fi-btn.fi-color-primary .fi-btn-label,
html.qp-rd .fi-fo-toggle-buttons .fi-btn.fi-color-primary svg { color: var(--rd-ink) !important; }
html.qp-rd .fi-fo-toggle-buttons input:checked + .fi-btn.fi-color-primary { background: var(--rd-cta) !important; }
html.qp-rd .fi-fo-toggle-buttons input:checked + .fi-btn.fi-color-primary .fi-btn-label,
html.qp-rd .fi-fo-toggle-buttons input:checked + .fi-btn.fi-color-primary svg { color: var(--rd-cta-ink) !important; }
html.qp-rd .fi-fo-toggle-buttons input:focus-visible + .fi-btn { outline: 2px solid var(--rd-ink); outline-offset: 2px; }
/* Row actions read as quiet chips, whatever colour the action has. */
html.qp-rd .fi-ta-actions .fi-btn,
html.qp-rd .fi-ta-cell .fi-btn {
  background: var(--rd-chip) !important; color: var(--rd-ink) !important; --tw-ring-shadow: 0 0 #0000 !important;
  padding: .45rem .9rem !important; font-weight: 500 !important;
}
html.qp-rd .fi-ta-actions .fi-btn:hover, html.qp-rd .fi-ta-cell .fi-btn:hover { background: var(--rd-chip-hover) !important; }
html.qp-rd .fi-ta-actions .fi-btn .fi-btn-label, html.qp-rd .fi-ta-actions .fi-btn svg,
html.qp-rd .fi-ta-cell .fi-btn .fi-btn-label, html.qp-rd .fi-ta-cell .fi-btn svg { color: var(--rd-ink) !important; }
html.qp-rd .fi-ta-actions .fi-btn svg, html.qp-rd .fi-ta-cell .fi-btn svg { display: none; }
html.qp-rd .fi-ta-actions .fi-btn.fi-color-danger .fi-btn-label { color: #c2410c !important; }

html.qp-rd .fi-badge { border-radius: 9999px !important; --tw-ring-shadow: 0 0 #0000 !important; box-shadow: none !important; padding: .2rem .6rem !important; font-weight: 500 !important; }

html.qp-rd .fi-input-wrp {
  background: var(--rd-field) !important; border-radius: var(--rd-radius-field) !important;
  --tw-ring-shadow: 0 0 #0000 !important; box-shadow: none !important;
}
html.qp-rd .fi-input-wrp:focus-within { box-shadow: 0 0 0 2px color-mix(in srgb, var(--rd-ink) 22%, transparent) !important; }
html.qp-rd .fi-input-wrp input, html.qp-rd .fi-input-wrp select, html.qp-rd .fi-input-wrp textarea { background: transparent !important; }
html.qp-rd .fi-input, html.qp-rd .fi-select-input { padding-top: .7rem !important; padding-bottom: .7rem !important; }
/* The searchable select (Choices) takes the same height as the text and date fields. */
html.qp-rd .fi-input-wrp .choices__inner { padding-top: .7rem !important; padding-bottom: .7rem !important; min-height: 2.9rem; }
/* The list search reads as one long pill. */
html.qp-rd .fi-ta-search-field { flex: 1; }
html.qp-rd .fi-ta-search-field .fi-input-wrp { border-radius: 9999px !important; }
html.qp-rd .fi-ta-header-toolbar > .ms-auto { flex: 1; }
html.qp-rd .fi-fo-field-wrp-label span { color: var(--rd-ink) !important; font-weight: 500 !important; }
/* The sign-in card is always dark, so its labels and fields stay dark-styled whichever mode the panel is in. */
html.qp-rd body:has(.qp-login-bg) .fi-fo-field-wrp-label span, html.qp-rd body:has(.qp-login-bg) label span { color: #f4f4f5 !important; }
html.qp-rd body:has(.qp-login-bg) .fi-input-wrp { background: #09090b99 !important; }
html.qp-rd body:has(.qp-login-bg) .fi-input-wrp input { color: #f4f4f5 !important; caret-color: #f4f4f5; }
html.qp-rd body:has(.qp-login-bg) .fi-input-wrp input::placeholder { color: #a1a1aa !important; }
html.qp-rd body:has(.qp-login-bg) .fi-input-wrp input:-webkit-autofill { -webkit-text-fill-color: #f4f4f5 !important; -webkit-box-shadow: inset 0 0 0 1000px #18181b !important; caret-color: #f4f4f5; }

/* Tabs and pagination: pill groups, the current one filled. */
html.qp-rd .fi-tabs { background: transparent !important; box-shadow: none !important; --tw-ring-shadow: 0 0 #0000 !important; gap: .375rem !important; padding: 0 !important; }
/* Tabs at the top of a card keep room around them and a hairline under them. */
html.qp-rd .fi-tabs.fi-contained { padding: 1rem 1.25rem !important; border-bottom: 1px solid var(--rd-line) !important; gap: .5rem !important; }
html.qp-rd .fi-tabs-item { border-radius: 9999px !important; background: var(--rd-chip) !important; color: var(--rd-muted) !important; }
html.qp-rd .fi-tabs-item.fi-active { background: var(--rd-accent) !important; }
html.qp-rd .fi-tabs-item.fi-active .fi-tabs-item-label, html.qp-rd .fi-tabs-item.fi-active svg { color: var(--rd-accent-ink) !important; }
html.qp-rd .fi-pagination-items { border-radius: 9999px !important; box-shadow: none !important; --tw-ring-shadow: 0 0 #0000 !important; background: var(--rd-chip) !important; }
html.qp-rd .fi-pagination-item-button { border-radius: 9999px !important; }
html.qp-rd .fi-pagination-item.fi-active .fi-pagination-item-button { background: var(--rd-accent) !important; }
html.qp-rd .fi-pagination-item.fi-active .fi-pagination-item-label { color: var(--rd-accent-ink) !important; }

/* Modals and dropdowns follow the cards. */
html.qp-rd .fi-modal-window { background: var(--rd-card) !important; border: 1px solid var(--rd-border) !important; border-radius: 24px !important; }
html.qp-rd .fi-dropdown-panel { border-radius: 16px !important; background: var(--rd-card) !important; border: 1px solid var(--rd-border) !important; }

/* ---- Settings pages: back pill, sub-nav card beside the form --------------- */

html.qp-rd .qp-rd-back {
  display: inline-flex; align-items: center; gap: .375rem; padding: .45rem .95rem .45rem .7rem;
  border-radius: 9999px; background: var(--rd-card); border: 1px solid var(--rd-border); box-shadow: var(--rd-shadow); color: var(--rd-ink); font-size: .8125rem; font-weight: 500; text-decoration: none;
}
html.qp-rd .qp-rd-back:hover { background: var(--rd-chip-hover); }
html.qp-rd .qp-rd-back svg { width: 16px; height: 16px; }
html.qp-rd .qp-rd-split { display: grid; grid-template-columns: 15rem minmax(0, 1fr); gap: 1.5rem; align-items: start; }
/* Desktop: the side card spans both rows, the page header sits over the main column. The header row
   keeps its own height; the tall side card's extra height all goes to the main row. */
@media (min-width: 1024px) {
  html.qp-rd .qp-rd-split { grid-template-rows: auto 1fr; }
  html.qp-rd .qp-rd-split > .fi-header { grid-column: 2; grid-row: 1; }
  html.qp-rd .qp-rd-split > .qp-rd-subnav { grid-column: 1; grid-row: 1 / span 2; }
  html.qp-rd .qp-rd-split > .qp-rd-split-main { grid-column: 2; grid-row: 2; }
}
html.qp-rd .qp-rd-subnav {
  position: sticky; top: calc(var(--rd-topbar-h, 0px) + 1rem); display: flex; flex-direction: column; gap: .125rem; padding: .625rem;
  max-height: calc(100vh - var(--rd-topbar-h, 0px) - 2.5rem); overflow-y: auto; scrollbar-width: thin;
  background: var(--rd-card); border: 1px solid var(--rd-border); box-shadow: var(--rd-shadow); border-radius: var(--rd-radius-card);
}
html.qp-rd .qp-rd-subnav-item {
  padding: .6rem .875rem; border-radius: 12px; color: var(--rd-muted); font-size: .875rem; font-weight: 500; text-decoration: none;
}
html.qp-rd .qp-rd-subnav-item:hover { background: var(--rd-chip); color: var(--rd-ink); }
html.qp-rd .qp-rd-subnav-item.qp-rd-active { background: var(--rd-accent); color: var(--rd-accent-ink); }
@media (max-width: 1023px) {
  html.qp-rd .qp-rd-split { grid-template-columns: minmax(0, 1fr); }
  html.qp-rd .qp-rd-subnav { position: static; flex-direction: row; overflow-x: auto; scrollbar-width: none; }
  html.qp-rd .qp-rd-subnav-item { flex: none; white-space: nowrap; }
}

/* A dark theme colour (or "Dark") still reads on dark cards: a hairline ring around highlights. */
html.qp-rd.dark .fi-tabs-item.fi-active,
html.qp-rd.dark .fi-pagination-item.fi-active .fi-pagination-item-button,
html.qp-rd.dark .qp-rd-subnav-item.qp-rd-active { box-shadow: 0 0 0 1px rgba(255, 255, 255, .16) !important; }

/* ---- Date and date-time picker (public/js/admin/datepicker.js) ----------------- */

html.qp-rd .qp-dp-trigger {
  display: flex; align-items: center; justify-content: space-between; gap: .75rem; width: 100%; flex: 1 1 auto; min-width: 0;
  padding: .7rem .85rem; background: transparent; border: 0; color: var(--rd-ink); font-size: .875rem; line-height: 1.5rem; text-align: left; cursor: pointer;
}
html.qp-rd .qp-dp-trigger:disabled { cursor: not-allowed; opacity: .6; }
html.qp-rd .qp-dp-trigger:focus-visible { outline: none; }
html.qp-rd .qp-dp-trigger svg { width: 18px; height: 18px; flex: none; color: var(--rd-muted); }
html.qp-rd .qp-dp-empty { color: var(--rd-muted); }
html.qp-rd .qp-dp {
  position: fixed; z-index: 60; width: 19.5rem; padding: 1rem; border-radius: var(--rd-radius-card);
  background: var(--rd-card); color: var(--rd-ink); border: 1px solid var(--rd-line);
  box-shadow: 0 24px 48px -12px rgba(22, 18, 16, .25), 0 4px 12px rgba(22, 18, 16, .08); font-size: .875rem;
}
html.qp-rd .qp-dp button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
html.qp-rd .qp-dp select {
  appearance: none; -webkit-appearance: none; font: inherit; color: var(--rd-ink); background: var(--rd-field); border: 0;
  border-radius: 10px; padding: .35rem .6rem; cursor: pointer; outline: none; box-shadow: none;
}
html.qp-rd .qp-dp select:focus-visible { box-shadow: 0 0 0 2px var(--rd-accent); }
html.qp-rd .qp-dp-head { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: .75rem; }
html.qp-rd .qp-dp-title { display: flex; gap: .35rem; }
html.qp-rd .qp-dp-title select { font-weight: 600; background: transparent; padding: .3rem .45rem; }
html.qp-rd .qp-dp-title select:hover { background: var(--rd-chip); }
html.qp-rd .qp-dp-nav { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 9999px; background: var(--rd-chip) !important; }
html.qp-rd .qp-dp-nav:hover { background: var(--rd-chip-hover) !important; }
html.qp-rd .qp-dp-nav svg { width: 16px; height: 16px; }
html.qp-rd .qp-dp-week, html.qp-rd .qp-dp-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; }
html.qp-rd .qp-dp-week span { font-size: .72rem; font-weight: 600; color: var(--rd-muted); padding: .25rem 0 .4rem; }
html.qp-rd .qp-dp-day { height: 2.3rem; border-radius: 9999px; font-variant-numeric: tabular-nums; transition: background .12s; }
html.qp-rd .qp-dp-day:hover { background: var(--rd-chip) !important; }
html.qp-rd .qp-dp-out { color: var(--rd-muted) !important; opacity: .55; }
html.qp-rd .qp-dp-today { box-shadow: inset 0 0 0 1.5px var(--rd-accent); font-weight: 600; }
html.qp-rd .qp-dp-day.qp-dp-on, html.qp-rd .qp-dp-day.qp-dp-on:hover { background: var(--rd-accent) !important; color: var(--rd-accent-ink) !important; font-weight: 600; opacity: 1; }
html.qp-rd .qp-dp-time { display: flex; align-items: center; gap: .6rem; margin-top: .85rem; padding-top: .85rem; border-top: 1px solid var(--rd-line); }
html.qp-rd .qp-dp-time-label { color: var(--rd-muted); font-weight: 500; margin-right: auto; }
html.qp-rd .qp-dp-clock { display: flex; align-items: center; gap: .2rem; }
html.qp-rd .qp-dp-clock select { text-align: center; min-width: 2.75rem; font-variant-numeric: tabular-nums; }
html.qp-rd .qp-dp-colon { font-weight: 600; color: var(--rd-muted); }
html.qp-rd .qp-dp-ampm { display: flex; padding: 3px; border-radius: 9999px; background: var(--rd-field); }
html.qp-rd .qp-dp-ampm button { padding: .25rem .6rem; border-radius: 9999px; font-size: .75rem; font-weight: 600; color: var(--rd-muted) !important; }
html.qp-rd .qp-dp-ampm button.qp-dp-on { background: var(--rd-card) !important; color: var(--rd-ink) !important; box-shadow: 0 1px 3px rgba(22, 18, 16, .15); }
html.qp-rd .qp-dp-foot { display: flex; align-items: center; gap: .25rem; margin-top: .85rem; }
html.qp-rd .qp-dp-link { padding: .4rem .6rem; border-radius: 9999px; font-weight: 500; color: var(--rd-muted) !important; }
html.qp-rd .qp-dp-link:hover { background: var(--rd-chip) !important; color: var(--rd-ink) !important; }
html.qp-rd .qp-dp-done { margin-left: auto; padding: .45rem 1.1rem; border-radius: 9999px; font-weight: 600; background: var(--rd-cta) !important; color: var(--rd-cta-ink) !important; }
html.qp-rd.dark .qp-dp { box-shadow: 0 24px 48px -12px rgba(0, 0, 0, .6); }

/* ---- List pages (admin/table.ts listPage): search pill, chips, pills, footer ---------- */

html.qp-rd .qp-rd-list-card { background: var(--rd-card) !important; border: 1px solid var(--rd-border) !important; border-radius: var(--rd-radius-card) !important; box-shadow: var(--rd-shadow) !important; overflow: hidden; }
html.qp-rd .qp-rd-list-tools { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .625rem; padding: 1.375rem 1.375rem .75rem; }
html.qp-rd .qp-rd-list-search {
  flex: 1 1 16rem; display: flex; align-items: center; gap: .65rem; min-width: 0; height: 2.75rem; padding: 0 1.1rem;
  border-radius: 9999px; background: var(--rd-field); color: var(--rd-muted); cursor: text;
}
html.qp-rd .qp-rd-list-search:focus-within { box-shadow: 0 0 0 2px color-mix(in srgb, var(--rd-ink) 18%, transparent); }
html.qp-rd .qp-rd-list-search > svg { width: 18px; height: 18px; flex: none; }
html.qp-rd .qp-rd-list-search input { flex: 1; min-width: 0; height: 100%; border: 0 !important; background: transparent !important; box-shadow: none !important; outline: none; padding: 0 !important; font-size: .875rem !important; color: var(--rd-ink) !important; }
html.qp-rd .qp-rd-list-search input::placeholder { color: var(--rd-muted); }
html.qp-rd .qp-rd-list-clear { display: flex; color: var(--rd-muted); }
html.qp-rd .qp-rd-list-clear:hover { color: var(--rd-ink); }
html.qp-rd .qp-rd-chips { display: flex; flex-wrap: wrap; gap: .375rem; }
html.qp-rd .qp-rd-chip {
  display: inline-flex; align-items: center; gap: .4rem; height: 2.375rem; padding: 0 1.05rem; border-radius: 9999px;
  background: var(--rd-chip); color: var(--rd-muted); font-size: .8125rem; font-weight: 500; white-space: nowrap; transition: background .12s, color .12s;
}
html.qp-rd .qp-rd-chip:hover { background: var(--rd-chip-hover); color: var(--rd-ink); }
html.qp-rd .qp-rd-chip.qp-rd-chip-on, html.qp-rd .qp-rd-chip.qp-rd-chip-on:hover { background: var(--rd-cta); color: var(--rd-cta-ink); font-weight: 600; }
html.qp-rd .qp-rd-chip-count { font-size: .72rem; opacity: .7; font-variant-numeric: tabular-nums; }
html.qp-rd .qp-rd-list-filter { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 2.5rem; height: 2.5rem; border-radius: 9999px; border: 1px solid var(--rd-border); background: var(--rd-card); color: var(--rd-ink); cursor: pointer; transition: background-color .15s; }
html.qp-rd .qp-rd-list-filter:hover { background: var(--rd-chip-hover); }
html.qp-rd .qp-rd-list-filter.qp-rd-list-filter-on { background: var(--rd-cta); border-color: var(--rd-cta); color: var(--rd-cta-ink); }
html.qp-rd .qp-rd-list-filter svg { width: 18px; height: 18px; }
html.qp-rd .qp-rd-list-card .fi-ta-content { padding: 0 1.375rem; }
html.qp-rd .qp-rd-list-card .fi-ta-table thead th { padding-top: .75rem !important; }
html.qp-rd .qp-rd-list-card .fi-ta-table tbody > tr > td > div > .fi-ta-col-wrp > * > div,
html.qp-rd .qp-rd-list-card .fi-ta-cell .fi-ta-text, html.qp-rd .qp-rd-list-card .fi-ta-cell .fi-ta-icon { padding-top: .95rem !important; padding-bottom: .95rem !important; }
/* Checkboxes only while the Actions & filters panel (opened from the topbar's filter button) is open, or always
   on a list with a Delete button in its search row (toolbarDelete). */
@media (min-width: 1024px) {
  html.qp-rd .fi-page:not(.qp-rd-bulk-always) .qp-rd-list-wrap:not(.qp-rd-bulk-on) .fi-ta-selection-cell { display: none; }
  /* With the checkbox cell hidden, the next cell starts the row and takes the rounded corner. */
  html.qp-rd .fi-page:not(.qp-rd-bulk-always) .qp-rd-list-wrap:not(.qp-rd-bulk-on) .fi-ta-row > td.fi-ta-selection-cell:first-child + td { border-radius: 12px 0 0 12px; }
}
/* Sort arrows show on hover, and on the column the table is sorted by. */
html.qp-rd .fi-ta-header-cell:not([aria-sort]) .fi-ta-header-cell-sort-icon { opacity: 0; }
html.qp-rd .fi-ta-header-cell:hover .fi-ta-header-cell-sort-icon { opacity: 1; }

html.qp-rd .qp-rd-pill {
  display: inline-flex; align-items: center; gap: .4rem; padding: .2rem .65rem; border-radius: 9999px;
  font-size: .75rem; font-weight: 500; line-height: 1.25rem; white-space: nowrap;
}
html.qp-rd .qp-rd-pill::before { content: ''; width: 6px; height: 6px; border-radius: 9999px; background: currentColor; }
html.qp-rd .qp-rd-pill-success { background: #e6f6ec; color: #15803d; }
html.qp-rd .qp-rd-pill-danger { background: #fde7e7; color: #c62828; }
html.qp-rd .qp-rd-pill-warning { background: #fdf2d8; color: #a16207; }
html.qp-rd .qp-rd-pill-info { background: #e5effd; color: #1d4ed8; }
html.qp-rd .qp-rd-pill-primary { background: color-mix(in srgb, var(--rd-accent) 14%, transparent); color: var(--rd-ink); }
html.qp-rd .qp-rd-pill-gray { background: var(--rd-chip); color: var(--rd-muted); }
html.qp-rd.dark .qp-rd-pill-success { background: rgba(34, 197, 94, .14); color: #4ade80; }
html.qp-rd.dark .qp-rd-pill-danger { background: rgba(239, 68, 68, .15); color: #f87171; }
html.qp-rd.dark .qp-rd-pill-warning { background: rgba(234, 179, 8, .15); color: #facc15; }
html.qp-rd.dark .qp-rd-pill-info { background: rgba(59, 130, 246, .16); color: #60a5fa; }

html.qp-rd .qp-rd-pager { display: flex !important; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .75rem 1rem; }
html.qp-rd .qp-rd-pager .fi-pagination-overview { color: var(--rd-muted) !important; font-size: .875rem; font-weight: 400 !important; }
html.qp-rd .qp-rd-pager-end { display: flex; align-items: center; gap: .5rem; margin-left: auto; }
html.qp-rd .qp-rd-pager-end .col-start-2 { grid-column: auto; }
html.qp-rd .qp-rd-page-of { color: var(--rd-muted); font-size: .8125rem; margin-right: .25rem; }
html.qp-rd .qp-rd-page-btn {
  height: 2.25rem; padding: 0 1rem; border-radius: 9999px; background: var(--rd-chip); color: var(--rd-ink);
  font-size: .8125rem; font-weight: 500; transition: background .12s;
}
html.qp-rd .qp-rd-page-btn:hover:not(:disabled) { background: var(--rd-chip-hover); }
html.qp-rd .qp-rd-page-btn:disabled { opacity: .45; cursor: default; }
html.qp-rd .qp-rd-list-card .fi-ta-cell .fi-ta-text, html.qp-rd .qp-rd-list-card .fi-ta-cell .fi-ta-icon,
html.qp-rd .qp-rd-list-card .fi-ta-header-cell { padding-left: .6rem !important; padding-right: .6rem !important; }
html.qp-rd .qp-rd-list-card .fi-ta-actions-cell > div { padding-left: .5rem !important; padding-right: .25rem !important; }
html.qp-rd .qp-rd-list-card .fi-ta-actions { gap: .375rem !important; }
html.qp-rd .qp-rd-list-card .fi-ta-cell:first-of-type, html.qp-rd .qp-rd-list-card .fi-ta-header-cell:first-of-type { padding-left: 0 !important; }
html.qp-rd .qp-rd-avatar {
  display: inline-grid; place-items: center; width: 1.75rem; height: 1.75rem; flex: none; margin-right: .35rem; border-radius: 9999px;
  color: #fff; font-size: .625rem; font-weight: 700; letter-spacing: .02em;
}
/* Status badges in a list (Users' Active, Inactive, Staff) as the same dotted pills as boolean columns. */
html.qp-rd .qp-rd-list-card .fi-table-cell-status .fi-badge { border-radius: 9999px !important; box-shadow: none !important; --tw-ring-shadow: 0 0 #0000 !important; padding: .2rem .65rem !important; gap: .4rem !important; }
html.qp-rd .qp-rd-list-card .fi-table-cell-status .fi-badge::before { content: ''; width: 6px; height: 6px; border-radius: 9999px; background: currentColor; }
html.qp-rd .qp-rd-list-card .fi-ta-actions-cell > div { padding-top: .45rem !important; padding-bottom: .45rem !important; }
html.qp-rd .qp-rd-list-card .fi-ta-cell .fi-ta-text, html.qp-rd .qp-rd-list-card .fi-ta-cell .fi-ta-icon { padding-top: .8rem !important; padding-bottom: .8rem !important; }
html.qp-rd .qp-rd-list-card .fi-ta-col-wrp { padding-top: 0 !important; padding-bottom: 0 !important; }
html.qp-rd .qp-rd-list-card .fi-ta-cell .fi-ta-text, html.qp-rd .qp-rd-list-card .fi-ta-cell .fi-ta-icon { padding-top: .7rem !important; padding-bottom: .7rem !important; }
html.qp-rd .qp-rd-list-card .fi-ta-cell { padding-top: 0 !important; padding-bottom: 0 !important; }
/* The search pill is the field: the input inside it draws no box, border, ring or outline of its own. */
html.qp-rd .qp-rd-list-search input.fi-input,
html.qp-rd .qp-rd-list-search input.fi-input:focus,
html.qp-rd .qp-rd-list-search input.fi-input:focus-visible {
  border: 0 !important; border-radius: 0 !important; outline: none !important; box-shadow: none !important;
  --tw-ring-shadow: 0 0 #0000 !important; --tw-ring-offset-shadow: 0 0 #0000 !important; background: transparent !important;
}

/* Days before the date this one must follow (data-after) */
.qp-dp-day:disabled { opacity: .3; cursor: not-allowed; text-decoration: line-through; }
/* Side-by-side form sections (the Modules cards) share their row's height. */
html.qp-rd [data-qp-form-page] .col-\[--col-span-default\] > .fi-section { height: 100%; }
/* The confirm and notice popups (qp-dialogs.js) in the panel's own look: a rounded card on the
   theme tokens with pill buttons. "body" lifts these over the script's injected styles. */
html.qp-rd body .qp-dlg-backdrop { background: rgba(10, 22, 17, .45); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
html.qp-rd body .qp-dlg { max-width: 28rem; padding: 1.5rem; border: 1px solid var(--rd-border); border-radius: var(--rd-radius-card); background: var(--rd-card); color: var(--rd-ink); font-family: inherit; box-shadow: 0 24px 60px -18px rgba(16, 35, 28, .35); }
html.qp-rd body .qp-dlg-title { margin-bottom: .5rem; font-size: 1.0625rem; font-weight: 700; }
html.qp-rd body .qp-dlg-msg { color: var(--rd-muted); font-size: .875rem; line-height: 1.6; }
html.qp-rd body .qp-dlg-actions { margin-top: 1.5rem; gap: .625rem; }
html.qp-rd body .qp-dlg-btn { padding: .55rem 1.15rem; border: 1px solid var(--rd-border); border-radius: 999px; background: var(--rd-chip); color: var(--rd-ink); font: 600 .8125rem/1.4 inherit; }
html.qp-rd body .qp-dlg-btn:hover { background: var(--rd-chip-hover); }
html.qp-rd body .qp-dlg-btn:focus-visible { outline: 2px solid var(--rd-accent); }
html.qp-rd body .qp-dlg-btn.qp-primary { border-color: var(--rd-cta); background: var(--rd-cta); color: var(--rd-cta-ink); }
html.qp-rd body .qp-dlg-btn.qp-primary:hover { opacity: .9; }
html.qp-rd body .qp-dlg-btn.qp-danger { border-color: #dc2626; background: #dc2626; color: #fff; }
html.qp-rd body .qp-dlg-btn.qp-danger:hover { border-color: #b91c1c; background: #b91c1c; }
html.qp-rd.dark body .qp-dlg { box-shadow: 0 24px 60px -18px rgba(0, 0, 0, .7); }
html.qp-rd.dark body .qp-dlg-backdrop { background: rgba(0, 0, 0, .6); }
/* The member popup's own small dialogs (Email, Assign Package, Grant File, New Invoice, New Order):
   the same card, filled fields like the forms', pill buttons. */
html.qp-rd .qp-sub-backdrop { background: rgba(10, 22, 17, .45); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
html.qp-rd.dark .qp-sub-backdrop { background: rgba(0, 0, 0, .6); }
html.qp-rd .qp-sub { width: 100%; max-width: 28rem; padding: 1.5rem; border: 1px solid var(--rd-border); border-radius: var(--rd-radius-card); background: var(--rd-card); color: var(--rd-ink); box-shadow: 0 24px 60px -18px rgba(16, 35, 28, .35); }
html.qp-rd.dark .qp-sub { box-shadow: 0 24px 60px -18px rgba(0, 0, 0, .7); }
html.qp-rd .qp-sub-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
html.qp-rd .qp-sub-title { margin: 0; font-size: 1.0625rem; font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; }
html.qp-rd .qp-sub-x { flex: none; padding: .3rem; border-radius: 999px; color: var(--rd-muted); }
html.qp-rd .qp-sub-x:hover { background: var(--rd-chip); color: var(--rd-ink); }
html.qp-rd .qp-sub-body { display: grid; gap: 1rem; }
html.qp-rd .qp-sub-label { display: block; margin-bottom: .4rem; font-size: .8125rem; font-weight: 500; color: var(--rd-ink); }
html.qp-rd .qp-sub-field { display: block; width: 100%; padding: .7rem .85rem; border: 0; border-radius: var(--rd-radius-field); background: var(--rd-field); color: var(--rd-ink); font-size: .875rem; line-height: 1.5rem; outline: none; box-shadow: none; }
html.qp-rd .qp-sub-field::placeholder { color: var(--rd-muted); }
html.qp-rd .qp-sub-field:focus, html.qp-rd .qp-sub-field:focus-within { box-shadow: 0 0 0 2px color-mix(in srgb, var(--rd-ink) 22%, transparent); }
html.qp-rd .qp-sub-wrap { display: flex; padding: 0; }
html.qp-rd select.qp-sub-field { appearance: none; -webkit-appearance: none; padding-right: 2.5rem; cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%238a9a93' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 8 4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .85rem center; background-size: 18px; }
html.qp-rd .qp-sub-hint { margin-top: .4rem; font-size: .75rem; color: var(--rd-muted); }
html.qp-rd .qp-sub-menu { position: absolute; left: 0; right: 0; top: 100%; z-index: 10; margin-top: .35rem; max-height: 12rem; overflow-y: auto; padding: .35rem; border: 1px solid var(--rd-border); border-radius: 14px; background: var(--rd-card); box-shadow: 0 16px 40px -16px rgba(16, 35, 28, .35); }
html.qp-rd .qp-sub-menu button { display: block; width: 100%; padding: .5rem .65rem; border-radius: 10px; font-size: .8125rem; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
html.qp-rd .qp-sub-menu button:hover { background: var(--rd-row-hover); }
html.qp-rd .qp-sub-actions { display: flex; justify-content: flex-end; gap: .625rem; margin-top: 1.5rem; }
html.qp-rd .qp-sub-btn { flex: none; padding: .55rem 1.15rem; border: 1px solid var(--rd-border); border-radius: 999px; background: var(--rd-chip); color: var(--rd-ink); font-size: .8125rem; font-weight: 600; line-height: 1.4; }
html.qp-rd .qp-sub-btn:hover { background: var(--rd-chip-hover); }
html.qp-rd .qp-sub-btn.qp-primary { border-color: var(--rd-cta); background: var(--rd-cta); color: var(--rd-cta-ink); }
html.qp-rd .qp-sub-btn.qp-primary:hover { opacity: .9; }
/* In dark mode a thin line sets the panel off the sidebar; in light mode it stays transparent. */
html.qp-rd.dark .fi-main-ctn { border-color: rgba(255, 255, 255, .08); }
/* The other tables with hover rows (File Manager, the member modal's lists, Media picker): the same rounded
   strip. Rounded cells need separate borders, so the header keeps its line on its own cells. */
html.qp-rd .fm-table, html.qp-rd table:has(> tbody > tr[class*="hover:bg"]) { border-collapse: separate !important; border-spacing: 0; }
html.qp-rd table:has(> tbody > tr[class*="hover:bg"]) > thead th { border-bottom: 1px solid var(--rd-line); }
html.qp-rd tr[class*="hover:bg"]:hover { background: transparent !important; }
html.qp-rd tr[class*="hover:bg"]:hover > td, html.qp-rd .fm-row:hover > td { background: var(--rd-row-hover) !important; }
html.qp-rd tr[class*="hover:bg"] > td:first-child, html.qp-rd .fm-row > td:first-child { border-radius: 12px 0 0 12px; }
html.qp-rd tr[class*="hover:bg"] > td:last-child, html.qp-rd .fm-row > td:last-child { border-radius: 0 12px 12px 0; }
html.qp-rd .fm-table > tbody > tr > td, html.qp-rd table:has(> tbody > tr[class*="hover:bg"]) > tbody > tr > td { box-sizing: border-box; height: var(--qp-row-h, auto); }
/* Files table rows: a little air above and below each name. */
html.qp-rd .fm-table > tbody > tr > td { padding-top: 1rem; padding-bottom: 1rem; font-size: .875rem; }
html.qp-rd .fm-table .fm-sub { font-size: .75rem; }
html.qp-rd .fm-table .fm-tag { font-size: .625rem; }
html.qp-rd .fm-table .fm-icon:not(.fm-icon-file) { width: 22px; height: 18px; }
/* Its heading like the list pages': no dark strip or capitals, muted labels over one hairline. */
html.qp-rd .fm-table-wrap { border: 0 !important; border-radius: 0 !important; }
html.qp-rd .fm-table > thead > tr > th {
  padding-top: .6rem; padding-bottom: .8rem; background: transparent !important; border-bottom: 1px solid var(--rd-line) !important;
  text-transform: none; letter-spacing: 0; font-size: .8125rem; font-weight: 500; color: var(--rd-muted) !important;
}
/* An editable column (Download Packages' order box) keeps the row at the usual height. */
html.qp-rd .fi-ta-table .fi-ta-text-input { padding-top: .45rem !important; padding-bottom: .45rem !important; }
html.qp-rd .fi-ta-table .fi-ta-text-input .fi-input { height: 2.125rem; padding-top: .25rem !important; padding-bottom: .25rem !important; font-size: .875rem; }
/* A table's editable cell (Download Packages' Order) as a real field: filled, bordered, no number spinner. */
html.qp-rd .fi-ta-table .fi-ta-text-input .fi-input-wrp { background: var(--rd-card) !important; transition: border-color .15s, box-shadow .15s; border: 1px solid color-mix(in srgb, var(--rd-muted) 40%, transparent) !important; border-radius: 10px !important; box-shadow: none !important; --tw-ring-shadow: 0 0 #0000 !important; }
html.qp-rd .fi-ta-table .fi-ta-text-input .fi-input-wrp:hover { border-color: color-mix(in srgb, var(--rd-accent) 55%, transparent) !important; }
html.qp-rd .fi-ta-table .fi-ta-text-input .fi-input-wrp:focus-within { border-color: var(--rd-accent) !important; box-shadow: 0 0 0 3px rgba(var(--primary-500), .18) !important; }
html.qp-rd .fi-ta-table .fi-ta-text-input .fi-input { background: transparent !important; color: var(--rd-ink) !important; font-weight: 600; -moz-appearance: textfield; box-shadow: none !important; outline: none !important; --tw-ring-shadow: 0 0 #0000 !important; border-radius: 10px; }
html.qp-rd .fi-ta-table .fi-ta-text-input .fi-input::-webkit-outer-spin-button,
html.qp-rd .fi-ta-table .fi-ta-text-input .fi-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* An uploaded file (FilePond): a light chip in the theme colours, and the box only as tall as the file
   (the hidden drop area kept its height and left a blank strip under it). A list of several keeps its height. */
html.qp-rd .filepond--root:has(.filepond--item):not(:has(.filepond--item + .filepond--item)) { height: 2.75rem !important; margin-bottom: 0 !important; }
html.qp-rd .filepond--item-panel { background: var(--rd-chip) !important; }
html.qp-rd .filepond--item .filepond--file-info, html.qp-rd .filepond--item .filepond--file-status { color: var(--rd-ink) !important; }
html.qp-rd .filepond--item .filepond--file-info-sub { color: var(--rd-muted) !important; opacity: 1 !important; }
html.qp-rd .filepond--item .filepond--file-action-button { background: color-mix(in srgb, var(--rd-ink) 10%, transparent) !important; color: var(--rd-ink) !important; }
html.qp-rd .filepond--item .filepond--file-action-button:hover { background: color-mix(in srgb, var(--rd-ink) 18%, transparent) !important; }

/* Files and Media toolbars: the list pages' search bar and pill buttons. */
html.qp-rd .qp-rd-mtools { padding: 1.375rem 1.375rem .75rem !important; border-bottom: 0 !important; gap: .5rem .625rem !important; }
html.qp-rd .qp-rd-msearch { flex: 1 1 18rem; display: flex; align-items: center; gap: .5rem; min-width: 0; }
html.qp-rd .qp-rd-mtools .fi-btn,
html.qp-rd .qp-rd-mtools .qp-rd-mpill,
html.qp-rd .qp-rd-mtools select {
  height: 2.375rem !important; border: 0 !important; border-radius: 9999px !important; box-shadow: none !important;
  background: var(--rd-chip) !important; color: var(--rd-muted) !important; font-size: .8125rem !important; font-weight: 500 !important;
  padding-inline: 1.05rem !important; transition: background .12s, color .12s;
}
html.qp-rd .qp-rd-mtools select { padding-inline-end: 2.25rem !important; }
html.qp-rd .qp-rd-mtools .fi-btn:hover:not(:disabled), html.qp-rd .qp-rd-mtools select:hover { background: var(--rd-chip-hover) !important; color: var(--rd-ink) !important; }
html.qp-rd .qp-rd-mtools .fi-btn svg { color: currentColor !important; }
html.qp-rd .qp-rd-mtools .qp-rd-mgroup { display: inline-flex; align-items: stretch; gap: .15rem; padding: .2rem !important; }
html.qp-rd .qp-rd-mtools .qp-rd-mgroup > button { display: inline-flex; align-items: center; gap: .3rem; height: auto !important; padding: 0 .85rem !important; border-radius: 9999px !important; background: transparent !important; box-shadow: none !important; color: var(--rd-muted) !important; }
html.qp-rd .qp-rd-mtools .qp-rd-mgroup > button:hover { color: var(--rd-ink) !important; }
html.qp-rd .qp-rd-mtools .fi-btn.qp-rd-mon,
html.qp-rd .qp-rd-mtools .qp-rd-mgroup > button.qp-rd-mon,
html.qp-rd .qp-rd-mtools .qp-rd-mpill.qp-rd-mon { background: var(--rd-cta) !important; color: var(--rd-cta-ink) !important; font-weight: 600 !important; }
html.qp-rd .qp-rd-mtools .qp-rd-mpill.qp-rd-mon > button { color: var(--rd-cta-ink) !important; }
html.qp-rd .qp-rd-mtools .fi-file-manager-shortcut-badge { border-color: currentColor !important; color: inherit !important; opacity: .55; }
/* The theme paints Media and Files text fields and selects near-black in dark mode (html.dark .fi-media-manager-page input[type=text]); keep the pills. */
html.qp-rd.dark .qp-rd-mtools .qp-rd-list-search input[type="text"].fi-input,
html.qp-rd.dark .qp-rd-mtools .qp-rd-list-search input[type="text"].fi-input:focus,
html.qp-rd.dark .qp-rd-mtools .qp-rd-list-search input[type="text"].fi-input:focus-visible { background: transparent !important; color: var(--rd-ink) !important; border: 0 !important; outline: none !important; box-shadow: none !important; }
html.qp-rd.dark .qp-rd-mtools select:not(.fi-select-input) { background-color: var(--rd-chip) !important; color: var(--rd-muted) !important; }
html.qp-rd.dark .qp-rd-mtools select:not(.fi-select-input):hover { background-color: var(--rd-chip-hover) !important; color: var(--rd-ink) !important; }
/* Files: the folder path (Up, pill breadcrumb, counts) and the second toolbar row (view, filters, selection). */
html.qp-rd .qp-rd-fpath { display: flex; align-items: center; gap: .625rem; padding: 1.125rem 1.375rem 0; min-width: 0; }
html.qp-rd .qp-rd-fpath-up { display: inline-flex; align-items: center; justify-content: center; width: 2.125rem; height: 2.125rem; flex: none; border-radius: 9999px; background: var(--rd-chip); color: var(--rd-ink); transition: background .12s; }
html.qp-rd .qp-rd-fpath-up:hover:not(:disabled) { background: var(--rd-chip-hover); }
html.qp-rd .qp-rd-fpath-up:disabled { opacity: .35; cursor: default; }
html.qp-rd .qp-rd-fpath-trail { display: flex; align-items: center; gap: .2rem; flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: none; }
html.qp-rd .qp-rd-fpath-trail::-webkit-scrollbar { display: none; }
html.qp-rd .qp-rd-fpath-crumb { display: inline-flex; align-items: center; gap: .4rem; flex: none; max-width: 16rem; height: 2.125rem; padding: 0 .75rem; border-radius: 9999px; font-size: .875rem; font-weight: 500; color: var(--rd-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: background .12s, color .12s; }
html.qp-rd button.qp-rd-fpath-crumb:hover { background: var(--rd-chip); color: var(--rd-ink); }
html.qp-rd .qp-rd-fpath-crumb.qp-rd-fpath-on { background: var(--rd-chip); color: var(--rd-ink); font-weight: 600; }
html.qp-rd .qp-rd-fpath-crumb > span { overflow: hidden; text-overflow: ellipsis; }
html.qp-rd .qp-rd-fpath-folder { width: 15px; height: 15px; flex: none; color: #f59e0b; }
html.qp-rd .qp-rd-fpath-sep { width: 14px; height: 14px; flex: none; color: var(--rd-muted); opacity: .6; }
html.qp-rd .qp-rd-fpath-count { flex: none; font-size: .8125rem; color: var(--rd-muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
@media (max-width: 640px) { html.qp-rd .qp-rd-fpath-count { display: none; } }
html.qp-rd .qp-rd-mtools.qp-rd-mtools-sub { padding-top: 0 !important; padding-bottom: 1rem !important; }
html.qp-rd .qp-rd-fcreate { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin-inline-start: auto; }
html.qp-rd .qp-rd-fcreate .fi-btn { display: inline-flex; align-items: center; gap: .4rem; }
html.qp-rd .qp-rd-fgroup { display: inline-flex; flex-wrap: wrap; align-items: center; gap: .4rem; padding-inline-start: .625rem; border-inline-start: 1px solid var(--rd-line); }
html.qp-rd .qp-rd-fgroup .fi-btn,
html.qp-rd .qp-rd-mtools .fi-file-manager-toolbar-actions .fi-btn { display: inline-flex; align-items: center; gap: .35rem; }
/* Media: Delete (n) beside Select All once images are ticked. */
html.qp-rd .qp-rd-mtools .fi-btn.qp-rd-mdel { background: #dc2626 !important; color: #fff !important; font-weight: 600 !important; }
html.qp-rd .qp-rd-mtools .fi-btn.qp-rd-mdel:hover:not(:disabled) { background: #ef4444 !important; color: #fff !important; }

/* ---- Dashboard (admin/dashboard.ts): minimal widgets on the redesign tokens ---- */
html.qp-rd .qp-db { display: flex; flex-direction: column; gap: 1.25rem; }
html.qp-rd .qp-db-pagehead { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: .75rem; }
html.qp-rd .qp-db-updated { display: inline-flex; align-items: center; gap: .45rem; font-size: .78rem; color: var(--rd-muted); }
html.qp-rd .qp-db-card { background: var(--rd-card); border: 1px solid var(--rd-border); border-radius: var(--rd-radius-card); box-shadow: var(--rd-shadow); }
html.qp-rd .qp-db-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--rd-line); overflow: hidden; }
@media (min-width: 1024px) { html.qp-rd .qp-db-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
html.qp-rd .qp-db-stat { display: flex; flex-direction: column; gap: .3rem; padding: 1.15rem 1.35rem; background: var(--rd-card); transition: background .12s; }
html.qp-rd .qp-db-stat:hover { background: var(--rd-row-hover); }
html.qp-rd .qp-db-stat-label { display: inline-flex; align-items: center; gap: .45rem; font-size: .78rem; font-weight: 500; color: var(--rd-muted); }
html.qp-rd .qp-db-stat-icon { width: 15px; height: 15px; flex: none; }
html.qp-rd .qp-db-stat-value { font-size: 1.6rem; line-height: 1.15; font-weight: 650; letter-spacing: -.02em; color: var(--rd-ink); font-variant-numeric: tabular-nums; }
html.qp-rd .qp-db-stat-sub { font-size: .75rem; color: var(--rd-muted); font-variant-numeric: tabular-nums; }
html.qp-rd .qp-db-row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
@media (min-width: 1280px) { html.qp-rd .qp-db-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
html.qp-rd .qp-db-panel { position: relative; display: flex; flex-direction: column; gap: 1.1rem; padding: 1.35rem 1.5rem 1.15rem; min-width: 0; }
html.qp-rd .qp-db-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem 1rem; }
html.qp-rd .qp-db-title { display: inline-flex; align-items: center; gap: .4rem; font-size: 1rem; font-weight: 600; color: var(--rd-ink); letter-spacing: -.01em; }
html.qp-rd .qp-db-hint { display: inline-flex; color: var(--rd-muted); cursor: help; }
html.qp-rd .qp-db-hint svg { width: 15px; height: 15px; }
html.qp-rd .qp-db-controls { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
html.qp-rd .qp-db-select {
  height: 2rem; padding: 0 2rem 0 .85rem; border: 0; border-radius: 9999px; background-color: var(--rd-chip); color: var(--rd-ink);
  font-size: .78rem; font-weight: 500; cursor: pointer; box-shadow: none;
}
html.qp-rd .qp-db-select:hover { background-color: var(--rd-chip-hover); }
html.qp-rd .qp-db-select:focus { outline: none; box-shadow: 0 0 0 2px color-mix(in srgb, var(--rd-ink) 18%, transparent); }
html.qp-rd .qp-db-select-wide { max-width: 15rem; }
html.qp-rd .qp-db-seg { display: inline-flex; height: 2rem; padding: .2rem; gap: .15rem; border-radius: 9999px; background: var(--rd-chip); }
html.qp-rd .qp-db-seg button { padding: 0 .8rem; border-radius: 9999px; font-size: .78rem; font-weight: 500; color: var(--rd-muted); }
html.qp-rd .qp-db-seg button:hover { color: var(--rd-ink); }
html.qp-rd .qp-db-seg .qp-db-seg-on, html.qp-rd .qp-db-seg .qp-db-seg-on:hover { background: var(--rd-cta); color: var(--rd-cta-ink); font-weight: 600; }
html.qp-rd .qp-db-legend { display: inline-flex; align-items: center; gap: .35rem; font-size: .74rem; color: var(--rd-muted); }
html.qp-rd .qp-db-key { display: inline-block; width: .5rem; height: .5rem; border-radius: 9999px; flex: none; }
html.qp-rd .qp-db-legend .qp-db-key:not(:first-child) { margin-left: .5rem; }
html.qp-rd .qp-db-key-now { background: rgb(var(--primary-500)); }
html.qp-rd .qp-db-key-prev { background: var(--rd-muted); opacity: .6; }
html.qp-rd .qp-db-key-today { background: #10b981; }
html.qp-rd .qp-db-figs { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .9rem 1.75rem; }
html.qp-rd .qp-db-fig { display: flex; flex-direction: column; gap: .2rem; min-width: 0; }
html.qp-rd .qp-db-fig-label { font-size: .72rem; color: var(--rd-muted); white-space: nowrap; }
html.qp-rd .qp-db-fig-value { font-size: .95rem; font-weight: 600; color: var(--rd-ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
html.qp-rd .qp-db-fig-hero { margin-right: auto; }
html.qp-rd .qp-db-fig-hero .qp-db-fig-value { font-size: 1.75rem; line-height: 1.1; font-weight: 650; letter-spacing: -.02em; }
html.qp-rd .qp-db-chart { position: relative; height: 13.5rem; margin-top: auto; }
html.qp-rd .qp-db-chart svg { width: 100%; height: 100%; overflow: visible; }
html.qp-rd .qp-db-grid { stroke: var(--rd-line); stroke-width: 1; }
html.qp-rd .qp-db-axis { fill: var(--rd-muted); font-size: 8.5px; font-family: inherit; }
html.qp-rd .qp-db-month { cursor: pointer; user-select: none; }
html.qp-rd .qp-db-month-later { opacity: .5; }
html.qp-rd .qp-db-month-on { fill: var(--rd-ink); font-weight: 600; opacity: 1; }
html.qp-rd .qp-db-stop { stop-color: rgb(var(--primary-500)); }
html.qp-rd .qp-db-line { fill: none; stroke: rgb(var(--primary-500)); stroke-width: 2.25; stroke-linecap: round; }
html.qp-rd .qp-db-future { fill: none; stroke: rgb(var(--primary-500)); stroke-width: 1.5; stroke-dasharray: 3 4; opacity: .3; }
html.qp-rd .qp-db-prev { fill: none; stroke: var(--rd-muted); stroke-width: 1.5; stroke-dasharray: 4 4; opacity: .55; }
html.qp-rd .qp-db-cursor { stroke: var(--rd-muted); stroke-width: 1; stroke-dasharray: 2 3; opacity: .6; }
html.qp-rd .qp-db-pt { fill: rgb(var(--primary-500)); stroke: var(--rd-card); stroke-width: 1.5; }
html.qp-rd .qp-db-pt-on { stroke-width: 2.5; }
html.qp-rd .qp-db-pt-prev { fill: var(--rd-muted); stroke: var(--rd-card); stroke-width: 1.5; }
html.qp-rd .qp-db-tip {
  background: var(--rd-card); border: 1px solid var(--rd-border); border-radius: .75rem; box-shadow: 0 8px 24px rgb(0 0 0 / .12);
  font-size: .72rem; color: var(--rd-muted); pointer-events: none;
}
html.qp-rd .qp-db-chart-tip { position: absolute; top: -.25rem; transform: translateX(-50%); padding: .55rem .75rem; min-width: 10.5rem; transition: left .15s; }
html.qp-rd .qp-db-tip-head { display: flex; align-items: center; gap: .4rem; font-weight: 500; }
html.qp-rd .qp-db-tag { margin-left: auto; padding: 0 .4rem; border-radius: 9999px; background: var(--rd-chip); color: var(--rd-ink); font-size: .66rem; }
html.qp-rd .qp-db-tip-value { display: flex; align-items: baseline; gap: .5rem; margin-top: .15rem; }
html.qp-rd .qp-db-tip-value > span:first-child { font-size: .95rem; font-weight: 650; color: var(--rd-ink); font-variant-numeric: tabular-nums; }
html.qp-rd .qp-db-tip-change.qp-db-up { color: #10b981; }
html.qp-rd .qp-db-tip-note { margin-top: .2rem; font-size: .68rem; }
html.qp-rd .qp-db-float-tip { position: absolute; z-index: 30; transform: translate(-50%, -100%); padding: .3rem .6rem; color: var(--rd-ink); white-space: nowrap; }
html.qp-rd .qp-db-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem 1rem; padding-top: .85rem; border-top: 1px solid var(--rd-line); font-size: .74rem; color: var(--rd-muted); }
html.qp-rd .qp-db-foot strong { color: var(--rd-ink); font-weight: 600; }
/* Activity levels: the theme accent, stronger with more work. */
html.qp-rd .qp-db-l0 { background: var(--rd-chip); color: var(--rd-muted); }
html.qp-rd .qp-db-l1 { background: color-mix(in srgb, rgb(var(--primary-500)) 22%, var(--rd-chip)); color: var(--rd-ink); }
html.qp-rd .qp-db-l2 { background: color-mix(in srgb, rgb(var(--primary-500)) 45%, var(--rd-chip)); color: var(--rd-ink); }
html.qp-rd .qp-db-l3 { background: color-mix(in srgb, rgb(var(--primary-500)) 75%, var(--rd-chip)); color: #fff; }
html.qp-rd .qp-db-l4 { background: rgb(var(--primary-600)); color: #fff; }
html.qp-rd .qp-db-visual { margin-top: auto; }
html.qp-rd .qp-db-cal { display: flex; flex-direction: column; gap: .3rem; }
html.qp-rd .qp-db-cal-row { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .3rem; }
html.qp-rd .qp-db-cal-days span { text-align: center; font-size: .66rem; font-weight: 500; color: var(--rd-muted); padding-bottom: .1rem; }
html.qp-rd .qp-db-day { position: relative; display: flex; align-items: center; justify-content: center; gap: .3rem; height: 2rem; border-radius: .6rem; font-size: .74rem; font-weight: 500; font-variant-numeric: tabular-nums; cursor: default; transition: transform .1s; }
html.qp-rd .qp-db-day small { font-size: .62rem; font-weight: 600; opacity: .8; }
html.qp-rd .qp-db-day:not(.qp-db-day-out):hover { transform: translateY(-1px); }
html.qp-rd .qp-db-day-out { color: var(--rd-muted); opacity: .35; }
html.qp-rd .qp-db-today { box-shadow: inset 0 0 0 1.5px #10b981; }
html.qp-rd .qp-db-year { overflow-x: auto; }
html.qp-rd .qp-db-year-inner { min-width: 560px; }
html.qp-rd .qp-db-year-months { display: flex; justify-content: space-between; padding: 0 .1rem .35rem; font-size: .66rem; color: var(--rd-muted); }
html.qp-rd .qp-db-year-weeks { display: flex; gap: 2px; }
html.qp-rd .qp-db-year-week { display: flex; flex-direction: column; gap: 2px; flex: 1; }
html.qp-rd .qp-db-cell { width: 100%; aspect-ratio: 1; border-radius: 2px; }
html.qp-rd .qp-db-cell-out { visibility: hidden; }
html.qp-rd .qp-db-swatch { display: inline-block; width: .7rem; height: .7rem; border-radius: 3px; }

/* Dashboard period widgets: the range bar, KPI cards, bar charts, share lists, the package table and the placeholders. */
html.qp-rd .qp-db-seg a { display: inline-flex; align-items: center; padding: 0 .8rem; border-radius: 9999px; font-size: .78rem; font-weight: 500; color: var(--rd-muted); white-space: nowrap; }
html.qp-rd .qp-db-seg a:hover { color: var(--rd-ink); }
html.qp-rd .qp-db-seg a.qp-db-seg-on, html.qp-rd .qp-db-seg a.qp-db-seg-on:hover { background: var(--rd-cta); color: var(--rd-cta-ink); font-weight: 600; }
html.qp-rd .qp-db-seg button { white-space: nowrap; }
html.qp-rd .qp-db-range { display: flex; flex-direction: column; gap: .6rem; }
html.qp-rd .qp-db-range-main { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; }
html.qp-rd .qp-db-range .qp-db-seg { overflow-x: auto; max-width: 100%; }
html.qp-rd .qp-db-range-note { font-size: .78rem; font-weight: 500; color: var(--rd-ink); }
html.qp-rd .qp-db-range-note span { font-weight: 400; color: var(--rd-muted); }
html.qp-rd .qp-db-custom { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .5rem; }
html.qp-rd .qp-db-custom label { display: flex; flex-direction: column; gap: .2rem; font-size: .7rem; color: var(--rd-muted); }
html.qp-rd .qp-db-custom .qp-db-select { padding-right: .85rem; }
html.qp-rd .qp-db-apply { height: 2rem; padding: 0 1rem; border-radius: 9999px; background: var(--rd-cta); color: var(--rd-cta-ink); font-size: .78rem; font-weight: 600; }
html.qp-rd .qp-db-kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
@media (min-width: 768px) { html.qp-rd .qp-db-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1280px) { html.qp-rd .qp-db-kpis { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
html.qp-rd .qp-db-kpi { display: flex; flex-direction: column; gap: .35rem; padding: 1rem 1.15rem; min-width: 0; transition: background .12s; }
html.qp-rd .qp-db-kpi:hover { background: var(--rd-row-hover); }
html.qp-rd .qp-db-kpi-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: .25rem .5rem; }
html.qp-rd .qp-db-kpi .qp-db-stat-value { font-size: 1.4rem; }
html.qp-rd .qp-db-delta { padding: .05rem .45rem; border-radius: 9999px; font-size: .7rem; font-weight: 600; font-variant-numeric: tabular-nums; background: var(--rd-chip); color: var(--rd-muted); }
html.qp-rd .qp-db-delta-up { background: color-mix(in srgb, #10b981 14%, transparent); color: #059669; }
html.qp-rd .qp-db-delta-down { background: color-mix(in srgb, #ef4444 14%, transparent); color: #dc2626; }
html.qp-rd.dark .qp-db-delta-up { color: #34d399; }
html.qp-rd.dark .qp-db-delta-down { color: #f87171; }
html.qp-rd .qp-db-key-b { background: #f59e0b; }
html.qp-rd .qp-db-minis { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem 1.5rem; }
@media (min-width: 640px) { html.qp-rd .qp-db-minis { grid-template-columns: repeat(2, minmax(0, 1fr)); } html.qp-rd .qp-db-minis-1 { grid-template-columns: minmax(0, 1fr); } }
html.qp-rd .qp-db-mini { display: flex; flex-direction: column; gap: .45rem; min-width: 0; }
html.qp-rd .qp-db-mini-head { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; }
html.qp-rd .qp-db-mini-head h4 { font-size: .78rem; font-weight: 500; color: var(--rd-muted); }
html.qp-rd .qp-db-mini-head > span { font-size: 1rem; font-weight: 650; color: var(--rd-ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
html.qp-rd .qp-db-mini-head small { font-size: .7rem; font-weight: 500; color: var(--rd-muted); }
html.qp-rd .qp-db-mini-legend { margin-top: -.2rem; }
html.qp-rd .qp-db-bars { position: relative; }
html.qp-rd .qp-db-bars-plot { position: relative; display: flex; align-items: flex-end; gap: 2px; height: 5.5rem; padding-top: .9rem; border-bottom: 1px solid var(--rd-line); }
html.qp-rd .qp-db-bars-tall .qp-db-bars-plot { height: 7.5rem; }
html.qp-rd .qp-db-bars-max { position: absolute; top: 0; left: 0; font-size: .62rem; color: var(--rd-muted); font-variant-numeric: tabular-nums; }
html.qp-rd .qp-db-bar { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 1px; height: 100%; min-width: 0; cursor: default; }
html.qp-rd .qp-db-bar i { display: block; flex: 1; max-width: 1.4rem; border-radius: 3px 3px 0 0; background: rgb(var(--primary-500)); opacity: .8; transition: opacity .1s; }
html.qp-rd .qp-db-bar i.qp-db-bar-b { background: #f59e0b; }
html.qp-rd .qp-db-bar-thin { gap: 0; }
html.qp-rd .qp-db-bar-thin i { border-radius: 1px 1px 0 0; }
html.qp-rd .qp-db-bar-on i { opacity: 1; }
html.qp-rd .qp-db-bars-plot:hover .qp-db-bar:not(.qp-db-bar-on) i { opacity: .45; }
html.qp-rd .qp-db-bars-axis { position: relative; height: 1.1rem; font-size: .62rem; color: var(--rd-muted); }
html.qp-rd .qp-db-bars-axis span { position: absolute; top: .25rem; transform: translateX(-50%); white-space: nowrap; }
html.qp-rd .qp-db-bars-axis span:first-child:not(:only-child) { transform: none; left: 0 !important; }
html.qp-rd .qp-db-bars-axis span:last-child:not(:only-child) { transform: none; left: auto !important; right: 0; }
html.qp-rd .qp-db-bars-tip { position: absolute; z-index: 20; bottom: calc(100% - .5rem); transform: translateX(-50%); padding: .45rem .65rem; white-space: nowrap; }
html.qp-rd .qp-db-tip-line { color: var(--rd-ink); font-variant-numeric: tabular-nums; }
html.qp-rd .qp-db-skel { display: flex; flex-direction: column; gap: .75rem; padding: 1.35rem 1.5rem; }
html.qp-rd .qp-db-skel i { display: block; height: .8rem; border-radius: 9999px; background: var(--rd-chip); animation: qp-db-pulse 1.4s ease-in-out infinite; }
html.qp-rd .qp-db-skel i:nth-child(1) { width: 35%; }
html.qp-rd .qp-db-skel i:nth-child(2) { width: 60%; height: 1.4rem; }
html.qp-rd .qp-db-skel i:nth-child(3) { width: 100%; flex: 1; border-radius: .75rem; }
html.qp-rd .qp-db-skel-tiles { min-height: 9.5rem; }
html.qp-rd .qp-db-skel-kpi { min-height: 6.4rem; padding: 1rem 1.15rem; }
html.qp-rd .qp-db-skel-chart { min-height: 22rem; }
@keyframes qp-db-pulse { 50% { opacity: .45; } }
@media (prefers-reduced-motion: reduce) { html.qp-rd .qp-db-skel i { animation: none; } }
html.qp-rd .qp-db-failed { display: flex; align-items: center; justify-content: center; padding: 1.5rem; font-size: .8rem; color: var(--rd-muted); }
html.qp-rd .qp-signed-out { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem 1rem; margin: 0 0 1rem; padding: .75rem 1rem; border-radius: 1rem; background: #fef3c7; color: #78350f; font-size: .875rem; }
html.qp-rd .qp-signed-out a { display: inline-flex; align-items: center; height: 2.25rem; padding: 0 1rem; border-radius: 9999px; background: var(--rd-accent); color: var(--rd-accent-ink); font-weight: 600; text-decoration: none; }
html.qp-rd.dark .qp-signed-out { background: rgba(245, 158, 11, .14); color: #fcd34d; }

/* User Inspector: scan header, the two tab cards, finding cards and their account rows. */
.qp-ui { display: flex; flex-direction: column; gap: 1rem; }
.qp-ui-card { border-radius: .75rem; border: 1px solid rgb(229 231 235); background: #fff; padding: 1rem 1.125rem; }
html.dark .qp-ui-card { border-color: rgb(255 255 255 / .1); background: rgb(24 24 27); }
html.qp-rd .qp-ui-card { border-color: var(--rd-line); background: var(--rd-card); border-radius: var(--rd-radius-card, .75rem); }
.qp-ui-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem; }
.qp-ui-head-side { display: flex; align-items: center; gap: .625rem; flex: none; }
.qp-ui-title { font-size: .9375rem; font-weight: 700; }
.qp-ui-strong { font-size: .875rem; font-weight: 600; }
.qp-ui-muted { font-size: .8125rem; color: rgb(107 114 128); margin-top: .25rem; max-width: 48rem; }
.qp-ui-faint { font-size: .75rem; color: rgb(156 163 175); }
html.qp-rd .qp-ui-title, html.qp-rd .qp-ui-strong, html.qp-rd .qp-ui-tab-label { color: var(--rd-ink); }
html.qp-rd .qp-ui-muted, html.qp-rd .qp-ui-faint, html.qp-rd .qp-ui-email { color: var(--rd-muted); }
.qp-ui-tabs { display: grid; grid-template-columns: 1fr; gap: .75rem; }
@media (min-width: 640px) { .qp-ui-tabs { grid-template-columns: 1fr 1fr; } }
.qp-ui-tab { display: block; padding: 1rem 1.125rem; border-radius: .75rem; border: 1px solid rgb(229 231 235); background: #fff; transition: background .12s, border-color .12s; }
html.dark .qp-ui-tab { border-color: rgb(255 255 255 / .1); background: rgb(24 24 27); }
html.qp-rd .qp-ui-tab { border-color: var(--rd-line); background: var(--rd-card); }
html.qp-rd .qp-ui-tab:hover { background: var(--rd-row-hover); }
html.qp-rd .qp-ui-tab.qp-ui-tab-on { border-color: var(--rd-cta); box-shadow: inset 0 0 0 1px var(--rd-cta); }
.qp-ui-tab-row { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.qp-ui-tab-label { font-size: .875rem; font-weight: 600; }
.qp-ui-count { padding: .125rem .5rem; border-radius: 9999px; font-size: .6875rem; font-weight: 700; background: #d1fae5; color: #047857; white-space: nowrap; }
html.dark .qp-ui-count { background: rgb(6 78 59 / .5); color: #6ee7b7; }
.qp-ui-count.qp-ui-count-bad, html.dark .qp-ui-count.qp-ui-count-bad { background: #dc2626; color: #fff; }
.qp-ui-find { display: flex; flex-direction: column; gap: .625rem; }
html.qp-rd .qp-ui-find.qp-ui-bad { border-color: #fecaca; }
html.qp-rd .qp-ui-find.qp-ui-warn { border-color: #fde68a; }
html.qp-rd.dark .qp-ui-find.qp-ui-bad { border-color: rgb(127 29 29 / .6); }
html.qp-rd.dark .qp-ui-find.qp-ui-warn { border-color: rgb(120 53 15 / .6); }
.qp-ui-find-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; }
.qp-ui-wrap { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.qp-ui-wrap .qp-ui-muted { margin-top: 0; }
.qp-ui-accounts > .qp-ui-account + .qp-ui-account { border-top: 1px solid rgb(243 244 246); }
html.dark .qp-ui-accounts > .qp-ui-account + .qp-ui-account { border-top-color: rgb(255 255 255 / .05); }
html.qp-rd .qp-ui-accounts > .qp-ui-account + .qp-ui-account { border-top-color: var(--rd-line); }
.qp-ui-account { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; padding: .625rem 0; }
.qp-ui-min { min-width: 0; }
.qp-ui-user { font-size: .875rem; font-weight: 600; color: rgb(var(--primary-600, 37 99 235)); }
.qp-ui-user:hover { text-decoration: underline; }
.qp-ui-email { font-size: .75rem; color: rgb(156 163 175); margin-inline-start: .375rem; }
.qp-ui-evidence { font-size: .8125rem; display: flex; flex-direction: column; gap: .125rem; }
html.qp-rd .qp-ui-evidence { color: var(--rd-ink); }
.qp-ui-chip { padding: .125rem .375rem; border-radius: .25rem; background: rgb(243 244 246); color: rgb(75 85 99); }
html.qp-rd .qp-ui-chip { background: var(--rd-chip); color: var(--rd-ink); }
.qp-ui-empty { padding: 2rem; text-align: center; border-radius: .75rem; border: 1px solid #a7f3d0; background: #fff; }
html.dark .qp-ui-empty { border-color: rgb(6 78 59 / .4); background: rgb(24 24 27); }
html.qp-rd .qp-ui-empty { background: var(--rd-card); }
.qp-ui-empty-title { font-size: .875rem; font-weight: 600; }
html.qp-rd .qp-ui-empty-title { color: var(--rd-ink); }
.qp-ui-empty .qp-ui-muted { margin-inline: auto; }

/* In-place page switching (panel.js): the page being left fades while the next one loads, with a thin bar on top. */
html.qp-soft-busy main.fi-main { opacity: .55; pointer-events: none; transition: opacity .15s; }
html.qp-soft-busy body::before { content: ""; position: fixed; z-index: 60; top: 0; left: 0; height: 2px; width: 100%; background: rgb(var(--primary-500)); transform-origin: left; animation: qp-soft-bar 1.2s ease-out infinite; }
@keyframes qp-soft-bar { 0% { transform: scaleX(0); } 70% { transform: scaleX(.8); } 100% { transform: scaleX(.95); opacity: .4; } }
@media (prefers-reduced-motion: reduce) { html.qp-soft-busy body::before { animation: none; transform: scaleX(.6); } }

/* Updates (System): status banner, version boxes, upload and previous-version cards, all with rounded corners. */
.qp-up { display: flex; flex-direction: column; gap: 1.25rem; width: 100%; max-width: 48rem; }
.qp-up-card { border-radius: 20px; border: 1px solid rgb(229 231 235); background: #fff; padding: 1.25rem; }
html.dark .qp-up-card { border-color: rgb(255 255 255 / .1); background: rgb(24 24 27); }
html.qp-rd .qp-up-card { border-color: var(--rd-line); background: var(--rd-card); border-radius: var(--rd-radius-card, 20px); box-shadow: var(--rd-shadow); }
.qp-up-banner { border-radius: 14px; border: 1px solid #a7f3d0; background: #ecfdf5; color: #047857; padding: .75rem 1rem; }
html.dark .qp-up-banner { border-color: rgb(16 185 129 / .3); background: rgb(16 185 129 / .1); color: #6ee7b7; }
.qp-up-banner-title { display: flex; align-items: center; gap: .5rem; font-size: .875rem; font-weight: 600; }
.qp-up-banner-title svg { width: 1.25rem; height: 1.25rem; flex: none; }
.qp-up-banner-sub { margin-top: .25rem; font-size: .75rem; }
.qp-up-boxes { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 640px) { .qp-up-boxes { grid-template-columns: 1fr 1fr; } }
.qp-up-box { border-radius: 14px; border: 1px solid rgb(229 231 235); padding: 1rem; }
html.dark .qp-up-box { border-color: rgb(255 255 255 / .1); }
html.qp-rd .qp-up-box { border-color: var(--rd-line); }
.qp-up-row { margin-top: 1rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.qp-up-label { font-size: .8125rem; color: rgb(107 114 128); }
.qp-up-value { margin-top: .5rem; font-size: 1.5rem; line-height: 2rem; font-weight: 700; }
.qp-up-note { margin-top: .75rem; font-size: .8125rem; color: rgb(107 114 128); }
.qp-up-strong { font-size: .875rem; font-weight: 600; }
.qp-up-small { font-size: .75rem; color: rgb(107 114 128); }
.qp-up-title { font-size: 1rem; font-weight: 700; margin-bottom: .5rem; }
.qp-up-text { font-size: .875rem; line-height: 1.5; color: rgb(107 114 128); }
html.qp-rd .qp-up-value, html.qp-rd .qp-up-strong, html.qp-rd .qp-up-title { color: var(--rd-ink); }
html.qp-rd .qp-up-label, html.qp-rd .qp-up-note, html.qp-rd .qp-up-small, html.qp-rd .qp-up-text { color: var(--rd-muted); }
.qp-up-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.qp-up-cmd { margin-top: .75rem; border-radius: 12px; border: 1px solid rgb(229 231 235); background: rgb(249 250 251); padding: .5rem .75rem; font-size: .75rem; word-break: break-all; }
html.dark .qp-up-cmd { border-color: rgb(255 255 255 / .1); background: rgb(255 255 255 / .05); }
.qp-up-steps { margin: .5rem 0 .75rem; padding-left: 1.25rem; list-style: decimal; font-size: .875rem; line-height: 1.6; }
.qp-up-steps li { margin: .25rem 0; }
.qp-up-link { color: rgb(37 99 235); text-decoration: underline; }
html.dark .qp-up-link { color: rgb(96 165 250); }
html.qp-rd .qp-up-cmd { border-color: var(--rd-line); background: var(--rd-field); color: var(--rd-ink); }
.qp-up-actions { margin-top: 1rem; display: flex; align-items: center; gap: .75rem; }
.qp-up-copied { font-size: .8125rem; color: #059669; }
.qp-up-fields { display: grid; gap: .875rem; margin-top: .75rem; }
.qp-up-field { display: grid; gap: .25rem; }
.qp-up-input { width: 100%; border-radius: 10px; border: 1px solid rgb(209 213 219); background: transparent; padding: .5rem .75rem; font-size: .875rem; }
html.dark .qp-up-input { border-color: rgb(255 255 255 / .15); }
html.qp-rd .qp-up-input { border-color: var(--rd-border); background: var(--rd-field); color: var(--rd-ink); }
.qp-up-log { margin-top: .5rem; border-radius: 12px; border: 1px solid rgb(229 231 235); background: rgb(249 250 251); padding: .5rem .75rem; font-size: .75rem; line-height: 1.6; max-height: 16rem; overflow-y: auto; }
html.dark .qp-up-log { border-color: rgb(255 255 255 / .1); background: rgb(255 255 255 / .05); }
html.qp-rd .qp-up-log { border-color: var(--rd-line); background: var(--rd-field); color: var(--rd-ink); }
.qp-up-warn { margin-top: .5rem; color: #b45309; }
html.dark .qp-up-warn { color: #fbbf24; }
.qp-up-busy { margin-top: .75rem; }
.qp-up-busy::after { content: ''; display: inline-block; width: .75rem; height: .75rem; margin-left: .5rem; border-radius: 9999px; border: 2px solid currentColor; border-right-color: transparent; animation: qp-up-spin .8s linear infinite; vertical-align: -1px; }
@keyframes qp-up-spin { to { transform: rotate(360deg); } }
html.qp-rd .fi-btn.fi-color-gray.qp-up-btn { border-radius: 12px !important; background: var(--rd-card) !important; color: var(--rd-ink); box-shadow: inset 0 0 0 1px var(--rd-border) !important; }
html.qp-rd .fi-btn.fi-color-gray.qp-up-btn:hover { background: var(--rd-row-hover) !important; }
/* Legacy Import (admin/legacy-import.ts): the Updates page's cards, plus banner tones, the drop box, a progress bar and tables. */
.qp-up-banner.is-gray { border-color: rgb(229 231 235); background: rgb(249 250 251); color: rgb(55 65 81); }
.qp-up-banner.is-warn { border-color: #fde68a; background: #fffbeb; color: #b45309; }
.qp-up-banner.is-danger { border-color: #fecaca; background: #fef2f2; color: #b91c1c; }
html.dark .qp-up-banner.is-gray { border-color: rgb(255 255 255 / .1); background: rgb(255 255 255 / .05); color: rgb(209 213 219); }
html.dark .qp-up-banner.is-warn { border-color: rgb(245 158 11 / .3); background: rgb(245 158 11 / .1); color: #fbbf24; }
html.dark .qp-up-banner.is-danger { border-color: rgb(239 68 68 / .3); background: rgb(239 68 68 / .1); color: #fca5a5; }
html.qp-rd .qp-up-banner.is-gray { border-color: var(--rd-line); background: var(--rd-field); color: var(--rd-ink); }
.qp-up-spin::after { content: ''; display: inline-block; width: .75rem; height: .75rem; margin-left: .5rem; border-radius: 9999px; border: 2px solid currentColor; border-right-color: transparent; animation: qp-up-spin .8s linear infinite; vertical-align: -1px; }
.qp-up-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: .5rem; }
.qp-up-head .qp-up-title { margin-bottom: 0; }
.qp-up-buttons { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.qp-up-gap { margin-top: .75rem; }
.qp-up-break { word-break: break-all; }
.qp-up-grow { min-width: 0; flex: 1 1 12rem; }
.qp-up-ok { color: #059669; }
.qp-up-bad { color: #dc2626; }
html.dark .qp-up-ok { color: #34d399; }
html.dark .qp-up-bad { color: #f87171; }
.qp-up-list { display: grid; gap: .75rem; margin-top: .75rem; }
.qp-up-item { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1rem; }
.qp-up-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .875rem 1rem; margin-top: 1rem; }
@media (min-width: 640px) { .qp-up-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.qp-up-facts dd { margin-top: .125rem; }
.qp-up-progress { margin-top: .75rem; }
.qp-up-progress[hidden] { display: none; }
.qp-up-progress-head { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: .375rem; font-size: .75rem; color: rgb(107 114 128); }
.qp-up-bar { height: .5rem; border-radius: 9999px; background: rgb(243 244 246); overflow: hidden; }
.qp-up-bar > div { height: 100%; border-radius: 9999px; background: #10b981; transition: width .3s; }
html.dark .qp-up-bar { background: rgb(255 255 255 / .1); }
html.qp-rd .qp-up-progress-head { color: var(--rd-muted); }
html.qp-rd .qp-up-bar { background: var(--rd-field); }
html.qp-rd .qp-up-bar > div { background: var(--rd-accent); }
.qp-up-drop { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .375rem; margin-top: .875rem; padding: 2rem 1rem; border: 2px dashed rgb(209 213 219); border-radius: 16px; text-align: center; cursor: pointer; transition: border-color .15s, background-color .15s; }
.qp-up-drop > svg { width: 2rem; height: 2rem; color: #10b981; }
.qp-up-drop:hover, .qp-up-drop:focus-within, .qp-up-drop.is-over { border-color: #10b981; background: rgb(16 185 129 / .06); }
.qp-up-drop.has-file { border-style: solid; border-color: #10b981; }
.qp-up-drop-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
html.dark .qp-up-drop { border-color: rgb(255 255 255 / .2); }
html.qp-rd .qp-up-drop { border-color: var(--rd-border); }
html.qp-rd .qp-up-drop > svg { color: var(--rd-accent); }
html.qp-rd .qp-up-drop:hover, html.qp-rd .qp-up-drop:focus-within, html.qp-rd .qp-up-drop.is-over, html.qp-rd .qp-up-drop.has-file { border-color: var(--rd-accent); }
.qp-up-scroll { overflow-x: auto; margin-top: .5rem; }
.qp-up-table { width: 100%; border-collapse: collapse; font-size: .875rem; }
.qp-up-table th { padding: .375rem .75rem .375rem 0; border-bottom: 1px solid rgb(229 231 235); text-align: left; font-size: .75rem; font-weight: 500; color: rgb(107 114 128); }
.qp-up-table td { padding: .5rem .75rem .5rem 0; border-bottom: 1px solid rgb(243 244 246); vertical-align: top; }
.qp-up-table tr:last-child td { border-bottom: 0; }
html.dark .qp-up-table th, html.dark .qp-up-table td { border-color: rgb(255 255 255 / .08); }
html.qp-rd .qp-up-table th, html.qp-rd .qp-up-table td { border-color: var(--rd-line); }
html.qp-rd .qp-up-table th { color: var(--rd-muted); }
html.qp-rd .qp-up-table td { color: var(--rd-ink); }
/* API log and webhook bodies (admin/webhooks.ts): closed until clicked, long JSON scrolls inside the box. */
.qp-log-block { margin-top: 1rem; border-radius: 12px; border: 1px solid rgb(229 231 235); background: rgb(249 250 251); overflow: hidden; }
.qp-log-block > summary { display: flex; align-items: center; gap: .5rem; padding: .625rem .875rem; font-size: .875rem; font-weight: 500; cursor: pointer; list-style: none; user-select: none; }
.qp-log-block > summary::-webkit-details-marker { display: none; }
.qp-log-block > summary::before { content: ''; width: .45rem; height: .45rem; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); transition: transform .15s; opacity: .6; }
.qp-log-block[open] > summary::before { transform: rotate(45deg); }
.qp-log-block > pre { margin: 0; max-height: 22rem; overflow: auto; white-space: pre-wrap; word-break: break-all; font-size: .75rem; line-height: 1.6; padding: .75rem .875rem; border-top: 1px solid rgb(229 231 235); }
html.dark .qp-log-block, html.dark .qp-log-block > pre { border-color: rgb(255 255 255 / .1); background: rgb(255 255 255 / .05); }
html.qp-rd .qp-log-block, html.qp-rd .qp-log-block > pre { border-color: var(--rd-line); background: var(--rd-field); color: var(--rd-ink); }
/* A list's own Delete button at the end of its search row (table.ts toolbarDelete). */
html.qp-rd .qp-rd-list-delete { margin-left: auto; display: inline-flex; align-items: center; gap: .375rem; height: 2.25rem; padding: 0 .875rem; border-radius: 9999px; font-size: .8rem; font-weight: 600; border: 1px solid rgb(239 68 68 / .4); background: rgb(239 68 68 / .1); color: #dc2626; transition: background .15s; }
html.qp-rd .qp-rd-list-delete:hover:not(:disabled) { background: rgb(239 68 68 / .2); }
html.qp-rd .qp-rd-list-delete:disabled { border-color: var(--rd-line); background: transparent; color: var(--rd-muted, #9ca3af); cursor: not-allowed; }
html.qp-rd.dark .qp-rd-list-delete:not(:disabled) { color: #f87171; }

/* Utilities the admin uses that the prebuilt theme CSS left out (danger, warning and success colours and a few
   layout ones): without them the maintenance banner, the active Delete Selected button and backup errors had no colour. */
.qp\:bg-danger-50 { background-color: #fef2f2; }
.qp\:border-danger-200 { border-color: #fecaca; }
.qp\:border-danger-300 { border-color: #fca5a5; }
.qp\:text-danger-600 { color: #dc2626; }
.qp\:text-danger-800 { color: #991b1b; }
.qp\:border-danger-500\/40 { border-color: rgb(239 68 68 / .4); }
.qp\:bg-danger-500\/10 { background-color: rgb(239 68 68 / .1); }
.qp\:hover\:bg-danger-500\/20:hover { background-color: rgb(239 68 68 / .2); }
.dark .qp\:dark\:border-danger-800 { border-color: #991b1b; }
.dark .qp\:dark\:text-danger-400 { color: #f87171; }
.qp\:text-warning-600 { color: #d97706; }
.qp\:border-warning-500\/60 { border-color: rgb(245 158 11 / .6); }
.qp\:bg-warning-500\/10 { background-color: rgb(245 158 11 / .1); }
.qp\:text-success-600 { color: #059669; }
.qp\:text-emerald-400 { color: #34d399; }
.qp\:text-rose-400 { color: #fb7185; }
.qp\:whitespace-pre-line { white-space: pre-line; }
.qp\:align-top { vertical-align: top; }
.qp\:bg-transparent { background-color: transparent; }
.qp\:w-36 { width: 9rem; }
.qp\:scale-105 { scale: 1.05; }
